overengineeringstudio / overengineeringstudio/effect-utils
notion-react: add coverage for media caption + file_upload
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 82
- Forks
- 2
- Avg merge
- 1d 8h
- Merged PRs (30d)
- 121
Description
Part of v0.1 block-coverage epic (see context/notion-block-coverage/).
Problem
Image / Video / Audio / File / Pdf components (components/blocks.tsx) only project { url } as { type: 'external', external: { url } }. Missing:
- caption (rich_text) — lossy for any page imported from Notion.
- file_upload variant — the 2026-era successor to internal file uploads; should be pluggable without schema churn.
Deliverables
- components/props.ts: extend MediaProps with caption?: ReactNode and fileUploadId?: string.
- components/blocks.tsx + renderer/host-config.ts: emit caption: rich_text[] and { type: 'file_upload', file_upload: { id } } envelope when fileUploadId is set; keep url->external path.
- web/blocks.tsx: already renders image caption — extend to video/audio/file/pdf.
- E2E: extend Image test to cover caption; add Video, Audio, File, Pdf round-trips.
Acceptance
- Round-trip preserves caption.
- file_upload path works against a live upload id (or is at least unit-tested for payload shape).
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with components/props.ts, components/blocks.tsx, and renderer/host-config.ts to trace MediaProps and the existing URL-to-external payload. Then inspect web/blocks.tsx and the existing Image E2E test before extending coverage to video, audio, file, and PDF. Done means captions survive round-trips and the file_upload payload shape is tested or works with a live upload id.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- react, typescript
- Domain
- frontend
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 62/100