Skip to content

Sites images#185

Merged
brianorwhatever merged 4 commits into
mainfrom
sites-images
May 15, 2026
Merged

Sites images#185
brianorwhatever merged 4 commits into
mainfrom
sites-images

Conversation

@brianorwhatever
Copy link
Copy Markdown
Contributor

No description provided.

brianorwhatever and others added 4 commits May 14, 2026 22:04
Renames the `siteImages` table to `siteAssets` so a site can carry sub-pages,
stylesheets, scripts, and fonts alongside images. Public URL stays at
`/_assets/<filename>` on each site host. Allowed content types now include
text/html, text/css, application/javascript, application/json, text/plain,
application/wasm, woff/woff2 — plus the existing image types.

- schema: `siteImages` → `siteAssets`, drops unused `kind` field
- convex: siteImages.ts → siteAssets.ts; functions renamed accordingly
- http route: /api/sites/resolve-image → /resolve-asset
- server.ts: resolveSiteImageUrl → resolveSiteAssetUrl; path unchanged
- UI: SiteImages → SiteAssets with type-aware icons; copy says "Files"
- inspectSiteImages dev helper dropped along with the table

Greenfield rename — no data migration needed since the only existing rows
were test uploads on this branch.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
# Conflicts:
#	convex/_generated/api.d.ts
#	convex/dev.ts
#	convex/http.ts
#	convex/schema.ts
#	convex/sitesHttp.ts
#	server.ts
#	src/pages/SiteDetail.tsx
Browser uploads via presigned PUT need CORS on the Railway Bucket
(allowed any origin, PUT/GET/HEAD). Adds a one-shot script to apply
the CORSConfiguration and corrects the .env.example endpoint hint to
match Railway's actual hostname pattern (t3.storageapi.dev).

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@brianorwhatever brianorwhatever merged commit 6336146 into main May 15, 2026
4 of 6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant