diff --git a/.changeset/admin-content-filters.md b/.changeset/admin-content-filters.md deleted file mode 100644 index 7c5cc4782..000000000 --- a/.changeset/admin-content-filters.md +++ /dev/null @@ -1,6 +0,0 @@ ---- -"emdash": minor -"@emdash-cms/admin": minor ---- - -Add status, author, and date-range filtering to the admin content list (#1288). The content list API gains `authorId`, `dateField`, `dateFrom`, and `dateTo` query params (all additive and optional), and a new `GET /_emdash/api/content/{collection}/authors` endpoint lists the distinct authors of a collection's content (gated on `content:read`). Filtering runs server-side, so it works across the whole collection rather than only the loaded page. diff --git a/.changeset/byline-content-filter.md b/.changeset/byline-content-filter.md deleted file mode 100644 index f00eb41e8..000000000 --- a/.changeset/byline-content-filter.md +++ /dev/null @@ -1,15 +0,0 @@ ---- -"emdash": minor ---- - -Add content filtering by byline credit. `getEmDashCollection` now accepts a reserved `byline` key in `where` that returns entries credited to a byline in any position, including co-authored entries where the byline is a secondary credit. This makes author archive pages possible without querying the database directly. Pass a single byline translation group or an array to match any of several. - -```ts -const byline = await getBylineBySlug("jane-doe"); -const { entries } = await getEmDashCollection("posts", { - where: { byline: byline.translationGroup ?? byline.id }, - orderBy: { published_at: "desc" }, -}); -``` - -A `getEntriesByByline(collection, byline, options)` helper wraps the same filter, mirroring `getEntriesByTerm`. diff --git a/.changeset/content-references-schema.md b/.changeset/content-references-schema.md deleted file mode 100644 index 857f6a56d..000000000 --- a/.changeset/content-references-schema.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"emdash": minor ---- - -Add content-reference database schema: `_emdash_relations` (relationship-type definitions, row-per-locale) and `_emdash_content_references` (directed, locale-agnostic edges between content entries linked by `translation_group`). Additive, forward-only migration `043`; no existing tables change. Groundwork for reference fields — no field type, API, or admin UI yet. diff --git a/.changeset/fix-admin-locale-edit.md b/.changeset/fix-admin-locale-edit.md deleted file mode 100644 index 5204fe4b7..000000000 --- a/.changeset/fix-admin-locale-edit.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"@emdash-cms/admin": patch ---- - -Forward `locale` query param through admin content edit route, content list navigation links, and API client to resolve correct i18n variant for slug-based lookups (#1242) diff --git a/.changeset/fix-core-locale-write.md b/.changeset/fix-core-locale-write.md deleted file mode 100644 index ea65edb1c..000000000 --- a/.changeset/fix-core-locale-write.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"emdash": patch ---- - -Read `?locale=` in content write routes (DELETE, publish, unpublish, discard-draft, schedule, unschedule) and forward it to `handleContentGet` for locale-aware slug resolution (#1242) diff --git a/.changeset/fix-flat-taxonomy-term-description.md b/.changeset/fix-flat-taxonomy-term-description.md deleted file mode 100644 index 8208341e3..000000000 --- a/.changeset/fix-flat-taxonomy-term-description.md +++ /dev/null @@ -1,11 +0,0 @@ ---- -"emdash": patch ---- - -`getTaxonomyTerms()` now returns the term `description` for flat -(non-hierarchical) taxonomies (#1419) - -The query already fetched the `data` column, but the non-hierarchical branch -dropped it when mapping rows to `TaxonomyTerm` — only hierarchical taxonomies -(via `buildTree`) parsed the description. Descriptions set in the admin UI are -now returned for both kinds of taxonomies. diff --git a/.changeset/fix-seed-default-locale.md b/.changeset/fix-seed-default-locale.md deleted file mode 100644 index cf0fc46d4..000000000 --- a/.changeset/fix-seed-default-locale.md +++ /dev/null @@ -1,12 +0,0 @@ ---- -"emdash": patch ---- - -Fix seed CLI hardcoding `en` as the default locale (#1421) - -`emdash export-seed` now emits a top-level `defaultLocale` for single-locale -projects, and `emdash seed` (`applySeed`) honors it when backfilling the locale -of menus, taxonomies, and content rows that omit an explicit `locale`. Previously -an `export-seed` → `seed` round-trip silently rewrote a non-`en` default locale -(e.g. `de`) to `en`, since the CLI runs outside the Astro runtime and the -fallback collapsed to `en`. Projects whose default locale is `en` are unaffected. diff --git a/.changeset/fix-taxonomy-dialog-scroll.md b/.changeset/fix-taxonomy-dialog-scroll.md deleted file mode 100644 index ad1275ecf..000000000 --- a/.changeset/fix-taxonomy-dialog-scroll.md +++ /dev/null @@ -1,10 +0,0 @@ ---- -"@emdash-cms/admin": patch ---- - -Fix taxonomy term edit dialog overflow with many locales (#1269) - -Adds `max-h-[85vh] flex flex-col` to the `TermFormDialog` and makes its body -scrollable with `flex-1 overflow-y-auto`, keeping the header and footer pinned. -This prevents the Cancel/Update buttons from falling off-screen when the -Translations panel lists a large number of locales. diff --git a/.changeset/fix-term-hydration-locale.md b/.changeset/fix-term-hydration-locale.md deleted file mode 100644 index 1ee9e157d..000000000 --- a/.changeset/fix-term-hydration-locale.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"emdash": patch ---- - -Fix `getEmDashEntry` / `getEmDashCollection` hydrating taxonomy terms in the request-context or default locale instead of the entry's resolved locale (#1441). When querying with an explicit `locale` (or via a localized route), `entry.data.terms` could return default-locale term variants even though the content row was correctly localized. Term hydration now uses the same resolved locale as the content query. diff --git a/.changeset/forms-submit-response-envelope.md b/.changeset/forms-submit-response-envelope.md deleted file mode 100644 index 2fa3d8e76..000000000 --- a/.changeset/forms-submit-response-envelope.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"@emdash-cms/plugin-forms": patch ---- - -Fixes enhanced form submissions so standard EmDash plugin API responses wrapped in `{ data }` show the configured success message instead of the generic error state. diff --git a/.changeset/html-block-toolbar.md b/.changeset/html-block-toolbar.md deleted file mode 100644 index 312bb50cc..000000000 --- a/.changeset/html-block-toolbar.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"@emdash-cms/admin": patch ---- - -Add a visible WYSIWYG toolbar button for inserting HTML blocks, matching the existing `/html` shortcut. diff --git a/.changeset/responsive-images.md b/.changeset/responsive-images.md deleted file mode 100644 index 3fad7e0fe..000000000 --- a/.changeset/responsive-images.md +++ /dev/null @@ -1,13 +0,0 @@ ---- -"emdash": minor ---- - -Generate responsive `srcset`s for media rendered with the `Image` and Portable Text image components. EmDash now routes locally/R2-stored media through Astro's configured image service (`astro:assets`) -- the Cloudflare Images binding on Workers, sharp on Node -- producing width-appropriate candidates and modern formats (e.g. WebP) instead of a single full-size ``. - -This works automatically: - -- Media served from a configured storage `publicUrl` (R2 custom domain, S3/CDN) is authorized and optimized. -- Same-origin proxied media (local storage, or R2 without a public URL) is optimized when `siteUrl` is set; the matching `image.remotePatterns` entry is registered for you, scoped to the media route. -- In `astro dev` it works out of the box without configuration. - -When optimization isn't possible (no image service available, an unauthorized host, or unknown dimensions) the components fall back to a plain ``, so existing sites keep rendering exactly as before. No template changes are required. diff --git a/.changeset/scheduled-publishing-driver.md b/.changeset/scheduled-publishing-driver.md deleted file mode 100644 index 51a66399d..000000000 --- a/.changeset/scheduled-publishing-driver.md +++ /dev/null @@ -1,33 +0,0 @@ ---- -"emdash": minor -"@emdash-cms/cloudflare": minor ---- - -Drive scheduled publishing from a real heartbeat instead of request side effects (#1303). - -Content scheduled via the admin now actually transitions to `published` when its time arrives. Previously nothing promoted the row — `status` stayed `scheduled` and `published_at` stayed null forever. - -A new sweep (`publishDueContent`) promotes due content and runs alongside the existing cron tick and system cleanup: - -- **Node / single-process:** the timer-based scheduler already drives it — no action needed. -- **Cloudflare Workers:** a `scheduled()` handler driven by a Cron Trigger now runs the sweep. The request-driven `PiggybackScheduler` is gone, so there are no maintenance side effects on visitor requests. - -`@emdash-cms/cloudflare` ships a Worker entry that wraps Astro's handler with the `scheduled()` handler (`@emdash-cms/cloudflare/worker`, plus `createScheduledHandler()` for hand-assembled Workers). When a cache provider is configured, the handler also purges edge-cache tags for whatever it published, so stale snapshots produced before the scheduled time are evicted. - -**Migration for existing Cloudflare sites.** New sites get this from the templates. Existing deployments must update two files: - -```ts -// src/worker.ts -export { default, PluginBridge } from "@emdash-cms/cloudflare/worker"; -``` - -```jsonc -// wrangler.jsonc -"triggers": { "crons": ["* * * * *"] } -``` - -Without the Cron Trigger, scheduled publishing and plugin cron do not run on Workers. - -Scheduled publishing matches manual publishing exactly: it fires `content:afterPublish` hooks (search indexing, webhooks, syndication), and records the _scheduled_ time as `published_at` on first publication rather than the (later) sweep time. The sweep claims each row atomically before promoting it, so an entry unscheduled or rescheduled just before its time is never published, and overlapping sweeps can't double-publish. Local `astro dev` keeps running the timer-driven sweep even under the Cloudflare adapter (where production relies on the Cron Trigger). - -Each tick promotes at most 100 items per collection (a large backlog drains over successive ticks) so a single Worker invocation can't exhaust its CPU/subrequest budget, and edge-cache tags are purged incrementally after each collection's batch rather than only at the end. On Node, the maintenance interval is capped at 60s so scheduled-publish latency matches the Cloudflare Cron Trigger cadence instead of lagging up to five minutes when no plugin cron is due. diff --git a/.changeset/whole-buses-repair.md b/.changeset/whole-buses-repair.md deleted file mode 100644 index fa9ff0967..000000000 --- a/.changeset/whole-buses-repair.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"@emdash-cms/admin": patch ---- - -Fixes nested-list serialization in the Portable Text editor. `convertList` now recurses into nested `bulletList`/`orderedList` children and emits each block with the correct `level` value, so Tab-indented list items in the editor round-trip through `onChange` as real nested portable-text blocks instead of being flattened to a single top-level list with every item at `level: 1`. diff --git a/fixtures/perf-site/CHANGELOG.md b/fixtures/perf-site/CHANGELOG.md index 5c5779a02..e0b3e15fa 100644 --- a/fixtures/perf-site/CHANGELOG.md +++ b/fixtures/perf-site/CHANGELOG.md @@ -1,5 +1,13 @@ # @emdash-cms/fixture-perf-site +## 0.0.18 + +### Patch Changes + +- Updated dependencies [[`e96587f`](https://github.com/emdash-cms/emdash/commit/e96587f8ff393939355d3d643a322fe7b2c07c86), [`023893a`](https://github.com/emdash-cms/emdash/commit/023893a0fa966b95aad4ff533fc2966b3e3dfe03), [`f41092b`](https://github.com/emdash-cms/emdash/commit/f41092bd847f1eb161034f1d2c67976e8473e794), [`cedfcc5`](https://github.com/emdash-cms/emdash/commit/cedfcc527d47131baaa5dcfb29fb7b4a966265d5), [`c63f9ca`](https://github.com/emdash-cms/emdash/commit/c63f9ca56a8fc0cf4e1843887291fee0d78d89a2), [`61ea3c9`](https://github.com/emdash-cms/emdash/commit/61ea3c9fee5b0f11974895a278d8297c56abec0b), [`a4c2af2`](https://github.com/emdash-cms/emdash/commit/a4c2af20ee27fef891290a442f7a20d4db64600d), [`850c1b7`](https://github.com/emdash-cms/emdash/commit/850c1b7e23eb1b083c0fcb753762effa1d3a207a), [`c39789c`](https://github.com/emdash-cms/emdash/commit/c39789c383e94125d8874a516988c7d9ca6f5484)]: + - emdash@0.19.0 + - @emdash-cms/cloudflare@0.19.0 + ## 0.0.17 ### Patch Changes diff --git a/fixtures/perf-site/package.json b/fixtures/perf-site/package.json index 41b541b4b..192f48344 100644 --- a/fixtures/perf-site/package.json +++ b/fixtures/perf-site/package.json @@ -1,6 +1,6 @@ { "name": "@emdash-cms/fixture-perf-site", - "version": "0.0.17", + "version": "0.0.18", "private": true, "type": "module", "description": "Fixture site for query-count perf snapshots. Runs under sqlite+node or d1+cloudflare based on EMDASH_FIXTURE_TARGET.", diff --git a/infra/blog-demo/CHANGELOG.md b/infra/blog-demo/CHANGELOG.md index 11f1f68b2..dc6e8bf2a 100644 --- a/infra/blog-demo/CHANGELOG.md +++ b/infra/blog-demo/CHANGELOG.md @@ -1,5 +1,14 @@ # @emdash-cms/perf-demo-site +## 0.0.18 + +### Patch Changes + +- Updated dependencies [[`e96587f`](https://github.com/emdash-cms/emdash/commit/e96587f8ff393939355d3d643a322fe7b2c07c86), [`023893a`](https://github.com/emdash-cms/emdash/commit/023893a0fa966b95aad4ff533fc2966b3e3dfe03), [`f41092b`](https://github.com/emdash-cms/emdash/commit/f41092bd847f1eb161034f1d2c67976e8473e794), [`cedfcc5`](https://github.com/emdash-cms/emdash/commit/cedfcc527d47131baaa5dcfb29fb7b4a966265d5), [`c63f9ca`](https://github.com/emdash-cms/emdash/commit/c63f9ca56a8fc0cf4e1843887291fee0d78d89a2), [`61ea3c9`](https://github.com/emdash-cms/emdash/commit/61ea3c9fee5b0f11974895a278d8297c56abec0b), [`a4c2af2`](https://github.com/emdash-cms/emdash/commit/a4c2af20ee27fef891290a442f7a20d4db64600d), [`298895d`](https://github.com/emdash-cms/emdash/commit/298895de11562d4a2e9864da91d961fd4ff1eeda), [`850c1b7`](https://github.com/emdash-cms/emdash/commit/850c1b7e23eb1b083c0fcb753762effa1d3a207a), [`c39789c`](https://github.com/emdash-cms/emdash/commit/c39789c383e94125d8874a516988c7d9ca6f5484)]: + - emdash@0.19.0 + - @emdash-cms/plugin-forms@0.2.4 + - @emdash-cms/cloudflare@0.19.0 + ## 0.0.17 ### Patch Changes diff --git a/infra/blog-demo/package.json b/infra/blog-demo/package.json index b0d41197b..0af503cba 100644 --- a/infra/blog-demo/package.json +++ b/infra/blog-demo/package.json @@ -1,6 +1,6 @@ { "name": "@emdash-cms/perf-demo-site", - "version": "0.0.17", + "version": "0.0.18", "private": true, "type": "module", "scripts": { diff --git a/infra/cache-demo/CHANGELOG.md b/infra/cache-demo/CHANGELOG.md index 3b7b791b6..100c1507c 100644 --- a/infra/cache-demo/CHANGELOG.md +++ b/infra/cache-demo/CHANGELOG.md @@ -1,5 +1,14 @@ # @emdash-cms/cache-demo-site +## 0.0.18 + +### Patch Changes + +- Updated dependencies [[`e96587f`](https://github.com/emdash-cms/emdash/commit/e96587f8ff393939355d3d643a322fe7b2c07c86), [`023893a`](https://github.com/emdash-cms/emdash/commit/023893a0fa966b95aad4ff533fc2966b3e3dfe03), [`f41092b`](https://github.com/emdash-cms/emdash/commit/f41092bd847f1eb161034f1d2c67976e8473e794), [`cedfcc5`](https://github.com/emdash-cms/emdash/commit/cedfcc527d47131baaa5dcfb29fb7b4a966265d5), [`c63f9ca`](https://github.com/emdash-cms/emdash/commit/c63f9ca56a8fc0cf4e1843887291fee0d78d89a2), [`61ea3c9`](https://github.com/emdash-cms/emdash/commit/61ea3c9fee5b0f11974895a278d8297c56abec0b), [`a4c2af2`](https://github.com/emdash-cms/emdash/commit/a4c2af20ee27fef891290a442f7a20d4db64600d), [`298895d`](https://github.com/emdash-cms/emdash/commit/298895de11562d4a2e9864da91d961fd4ff1eeda), [`850c1b7`](https://github.com/emdash-cms/emdash/commit/850c1b7e23eb1b083c0fcb753762effa1d3a207a), [`c39789c`](https://github.com/emdash-cms/emdash/commit/c39789c383e94125d8874a516988c7d9ca6f5484)]: + - emdash@0.19.0 + - @emdash-cms/plugin-forms@0.2.4 + - @emdash-cms/cloudflare@0.19.0 + ## 0.0.17 ### Patch Changes diff --git a/infra/cache-demo/package.json b/infra/cache-demo/package.json index 3f5803ac2..f4a43b49a 100644 --- a/infra/cache-demo/package.json +++ b/infra/cache-demo/package.json @@ -1,6 +1,6 @@ { "name": "@emdash-cms/cache-demo-site", - "version": "0.0.17", + "version": "0.0.18", "private": true, "type": "module", "scripts": { diff --git a/packages/admin/CHANGELOG.md b/packages/admin/CHANGELOG.md index e4352a953..17b9957da 100644 --- a/packages/admin/CHANGELOG.md +++ b/packages/admin/CHANGELOG.md @@ -1,5 +1,29 @@ # @emdash-cms/admin +## 0.19.0 + +### Minor Changes + +- [#1442](https://github.com/emdash-cms/emdash/pull/1442) [`e96587f`](https://github.com/emdash-cms/emdash/commit/e96587f8ff393939355d3d643a322fe7b2c07c86) Thanks [@ascorbic](https://github.com/ascorbic)! - Add status, author, and date-range filtering to the admin content list ([#1288](https://github.com/emdash-cms/emdash/issues/1288)). The content list API gains `authorId`, `dateField`, `dateFrom`, and `dateTo` query params (all additive and optional), and a new `GET /_emdash/api/content/{collection}/authors` endpoint lists the distinct authors of a collection's content (gated on `content:read`). Filtering runs server-side, so it works across the whole collection rather than only the loaded page. + +### Patch Changes + +- [#1307](https://github.com/emdash-cms/emdash/pull/1307) [`cedfcc5`](https://github.com/emdash-cms/emdash/commit/cedfcc527d47131baaa5dcfb29fb7b4a966265d5) Thanks [@emdashbot](https://github.com/apps/emdashbot)! - Forward `locale` query param through admin content edit route, content list navigation links, and API client to resolve correct i18n variant for slug-based lookups ([#1242](https://github.com/emdash-cms/emdash/issues/1242)) + +- [#1417](https://github.com/emdash-cms/emdash/pull/1417) [`7e70abc`](https://github.com/emdash-cms/emdash/commit/7e70abcc1434dc2fd94c1f51c8c8c76acc9aa536) Thanks [@emdashbot](https://github.com/apps/emdashbot)! - Fix taxonomy term edit dialog overflow with many locales ([#1269](https://github.com/emdash-cms/emdash/issues/1269)) + + Adds `max-h-[85vh] flex flex-col` to the `TermFormDialog` and makes its body + scrollable with `flex-1 overflow-y-auto`, keeping the header and footer pinned. + This prevents the Cancel/Update buttons from falling off-screen when the + Translations panel lists a large number of locales. + +- [#1440](https://github.com/emdash-cms/emdash/pull/1440) [`783e663`](https://github.com/emdash-cms/emdash/commit/783e66365d5800e01ab445cbb411237240ff2ab4) Thanks [@diogoascarneiro](https://github.com/diogoascarneiro)! - Add a visible WYSIWYG toolbar button for inserting HTML blocks, matching the existing `/html` shortcut. + +- [#1142](https://github.com/emdash-cms/emdash/pull/1142) [`157237d`](https://github.com/emdash-cms/emdash/commit/157237d6b3db0301f059534c9390bdef0a02b0cf) Thanks [@OrangeManLi](https://github.com/OrangeManLi)! - Fixes nested-list serialization in the Portable Text editor. `convertList` now recurses into nested `bulletList`/`orderedList` children and emits each block with the correct `level` value, so Tab-indented list items in the editor round-trip through `onChange` as real nested portable-text blocks instead of being flattened to a single top-level list with every item at `level: 1`. + +- Updated dependencies []: + - @emdash-cms/blocks@0.19.0 + ## 0.18.0 ### Patch Changes diff --git a/packages/admin/package.json b/packages/admin/package.json index 239ac945f..87295f89a 100644 --- a/packages/admin/package.json +++ b/packages/admin/package.json @@ -1,6 +1,6 @@ { "name": "@emdash-cms/admin", - "version": "0.18.0", + "version": "0.19.0", "description": "Admin UI for EmDash CMS", "type": "module", "main": "dist/index.js", diff --git a/packages/auth-atproto/CHANGELOG.md b/packages/auth-atproto/CHANGELOG.md index ffad17451..c322e3fc4 100644 --- a/packages/auth-atproto/CHANGELOG.md +++ b/packages/auth-atproto/CHANGELOG.md @@ -1,5 +1,12 @@ # @emdash-cms/auth-atproto +## 0.2.15 + +### Patch Changes + +- Updated dependencies []: + - @emdash-cms/auth@0.19.0 + ## 0.2.14 ### Patch Changes diff --git a/packages/auth-atproto/package.json b/packages/auth-atproto/package.json index 7ae424eab..1f4a97c84 100644 --- a/packages/auth-atproto/package.json +++ b/packages/auth-atproto/package.json @@ -1,6 +1,6 @@ { "name": "@emdash-cms/auth-atproto", - "version": "0.2.14", + "version": "0.2.15", "description": "AT Protocol / Atmosphere authentication provider for EmDash CMS", "type": "module", "main": "src/auth.ts", diff --git a/packages/auth/CHANGELOG.md b/packages/auth/CHANGELOG.md index 5ef3b524d..3cde60f24 100644 --- a/packages/auth/CHANGELOG.md +++ b/packages/auth/CHANGELOG.md @@ -1,5 +1,7 @@ # @emdash-cms/auth +## 0.19.0 + ## 0.18.0 ## 0.17.2 diff --git a/packages/auth/package.json b/packages/auth/package.json index df5ab981d..14479edc6 100644 --- a/packages/auth/package.json +++ b/packages/auth/package.json @@ -1,6 +1,6 @@ { "name": "@emdash-cms/auth", - "version": "0.18.0", + "version": "0.19.0", "description": "Passkey-first authentication for EmDash", "type": "module", "main": "dist/index.mjs", diff --git a/packages/blocks/CHANGELOG.md b/packages/blocks/CHANGELOG.md index 640ad3af1..883157dc0 100644 --- a/packages/blocks/CHANGELOG.md +++ b/packages/blocks/CHANGELOG.md @@ -1,5 +1,7 @@ # @emdash-cms/blocks +## 0.19.0 + ## 0.18.0 ## 0.17.2 diff --git a/packages/blocks/package.json b/packages/blocks/package.json index 5261899f8..b991d6f43 100644 --- a/packages/blocks/package.json +++ b/packages/blocks/package.json @@ -1,6 +1,6 @@ { "name": "@emdash-cms/blocks", - "version": "0.18.0", + "version": "0.19.0", "description": "Declarative plugin UI blocks for EmDash CMS", "type": "module", "main": "dist/index.js", diff --git a/packages/cloudflare/CHANGELOG.md b/packages/cloudflare/CHANGELOG.md index 564fbf10b..9e722b395 100644 --- a/packages/cloudflare/CHANGELOG.md +++ b/packages/cloudflare/CHANGELOG.md @@ -1,5 +1,42 @@ # @emdash-cms/cloudflare +## 0.19.0 + +### Minor Changes + +- [#1312](https://github.com/emdash-cms/emdash/pull/1312) [`c39789c`](https://github.com/emdash-cms/emdash/commit/c39789c383e94125d8874a516988c7d9ca6f5484) Thanks [@ascorbic](https://github.com/ascorbic)! - Drive scheduled publishing from a real heartbeat instead of request side effects ([#1303](https://github.com/emdash-cms/emdash/issues/1303)). + + Content scheduled via the admin now actually transitions to `published` when its time arrives. Previously nothing promoted the row — `status` stayed `scheduled` and `published_at` stayed null forever. + + A new sweep (`publishDueContent`) promotes due content and runs alongside the existing cron tick and system cleanup: + - **Node / single-process:** the timer-based scheduler already drives it — no action needed. + - **Cloudflare Workers:** a `scheduled()` handler driven by a Cron Trigger now runs the sweep. The request-driven `PiggybackScheduler` is gone, so there are no maintenance side effects on visitor requests. + + `@emdash-cms/cloudflare` ships a Worker entry that wraps Astro's handler with the `scheduled()` handler (`@emdash-cms/cloudflare/worker`, plus `createScheduledHandler()` for hand-assembled Workers). When a cache provider is configured, the handler also purges edge-cache tags for whatever it published, so stale snapshots produced before the scheduled time are evicted. + + **Migration for existing Cloudflare sites.** New sites get this from the templates. Existing deployments must update two files: + + ```ts + // src/worker.ts + export { default, PluginBridge } from "@emdash-cms/cloudflare/worker"; + ``` + + ```jsonc + // wrangler.jsonc + "triggers": { "crons": ["* * * * *"] } + ``` + + Without the Cron Trigger, scheduled publishing and plugin cron do not run on Workers. + + Scheduled publishing matches manual publishing exactly: it fires `content:afterPublish` hooks (search indexing, webhooks, syndication), and records the _scheduled_ time as `published_at` on first publication rather than the (later) sweep time. The sweep claims each row atomically before promoting it, so an entry unscheduled or rescheduled just before its time is never published, and overlapping sweeps can't double-publish. Local `astro dev` keeps running the timer-driven sweep even under the Cloudflare adapter (where production relies on the Cron Trigger). + + Each tick promotes at most 100 items per collection (a large backlog drains over successive ticks) so a single Worker invocation can't exhaust its CPU/subrequest budget, and edge-cache tags are purged incrementally after each collection's batch rather than only at the end. On Node, the maintenance interval is capped at 60s so scheduled-publish latency matches the Cloudflare Cron Trigger cadence instead of lagging up to five minutes when no plugin cron is due. + +### Patch Changes + +- Updated dependencies [[`e96587f`](https://github.com/emdash-cms/emdash/commit/e96587f8ff393939355d3d643a322fe7b2c07c86), [`023893a`](https://github.com/emdash-cms/emdash/commit/023893a0fa966b95aad4ff533fc2966b3e3dfe03), [`f41092b`](https://github.com/emdash-cms/emdash/commit/f41092bd847f1eb161034f1d2c67976e8473e794), [`cedfcc5`](https://github.com/emdash-cms/emdash/commit/cedfcc527d47131baaa5dcfb29fb7b4a966265d5), [`c63f9ca`](https://github.com/emdash-cms/emdash/commit/c63f9ca56a8fc0cf4e1843887291fee0d78d89a2), [`61ea3c9`](https://github.com/emdash-cms/emdash/commit/61ea3c9fee5b0f11974895a278d8297c56abec0b), [`a4c2af2`](https://github.com/emdash-cms/emdash/commit/a4c2af20ee27fef891290a442f7a20d4db64600d), [`850c1b7`](https://github.com/emdash-cms/emdash/commit/850c1b7e23eb1b083c0fcb753762effa1d3a207a), [`c39789c`](https://github.com/emdash-cms/emdash/commit/c39789c383e94125d8874a516988c7d9ca6f5484)]: + - emdash@0.19.0 + ## 0.18.0 ### Minor Changes diff --git a/packages/cloudflare/package.json b/packages/cloudflare/package.json index c4c1b6643..71a8f30a1 100644 --- a/packages/cloudflare/package.json +++ b/packages/cloudflare/package.json @@ -1,6 +1,6 @@ { "name": "@emdash-cms/cloudflare", - "version": "0.18.0", + "version": "0.19.0", "description": "Cloudflare adapters for EmDash - D1, R2, Access, and Worker Loader sandbox", "type": "module", "main": "dist/index.mjs", diff --git a/packages/core/CHANGELOG.md b/packages/core/CHANGELOG.md index 19993d00f..39e588d01 100644 --- a/packages/core/CHANGELOG.md +++ b/packages/core/CHANGELOG.md @@ -1,5 +1,90 @@ # emdash +## 0.19.0 + +### Minor Changes + +- [#1442](https://github.com/emdash-cms/emdash/pull/1442) [`e96587f`](https://github.com/emdash-cms/emdash/commit/e96587f8ff393939355d3d643a322fe7b2c07c86) Thanks [@ascorbic](https://github.com/ascorbic)! - Add status, author, and date-range filtering to the admin content list ([#1288](https://github.com/emdash-cms/emdash/issues/1288)). The content list API gains `authorId`, `dateField`, `dateFrom`, and `dateTo` query params (all additive and optional), and a new `GET /_emdash/api/content/{collection}/authors` endpoint lists the distinct authors of a collection's content (gated on `content:read`). Filtering runs server-side, so it works across the whole collection rather than only the loaded page. + +- [#1439](https://github.com/emdash-cms/emdash/pull/1439) [`023893a`](https://github.com/emdash-cms/emdash/commit/023893a0fa966b95aad4ff533fc2966b3e3dfe03) Thanks [@ascorbic](https://github.com/ascorbic)! - Add content filtering by byline credit. `getEmDashCollection` now accepts a reserved `byline` key in `where` that returns entries credited to a byline in any position, including co-authored entries where the byline is a secondary credit. This makes author archive pages possible without querying the database directly. Pass a single byline translation group or an array to match any of several. + + ```ts + const byline = await getBylineBySlug("jane-doe"); + const { entries } = await getEmDashCollection("posts", { + where: { byline: byline.translationGroup ?? byline.id }, + orderBy: { published_at: "desc" }, + }); + ``` + + A `getEntriesByByline(collection, byline, options)` helper wraps the same filter, mirroring `getEntriesByTerm`. + +- [#1367](https://github.com/emdash-cms/emdash/pull/1367) [`f41092b`](https://github.com/emdash-cms/emdash/commit/f41092bd847f1eb161034f1d2c67976e8473e794) Thanks [@MA2153](https://github.com/MA2153)! - Add content-reference database schema: `_emdash_relations` (relationship-type definitions, row-per-locale) and `_emdash_content_references` (directed, locale-agnostic edges between content entries linked by `translation_group`). Additive, forward-only migration `043`; no existing tables change. Groundwork for reference fields — no field type, API, or admin UI yet. + +- [#1438](https://github.com/emdash-cms/emdash/pull/1438) [`850c1b7`](https://github.com/emdash-cms/emdash/commit/850c1b7e23eb1b083c0fcb753762effa1d3a207a) Thanks [@ascorbic](https://github.com/ascorbic)! - Generate responsive `srcset`s for media rendered with the `Image` and Portable Text image components. EmDash now routes locally/R2-stored media through Astro's configured image service (`astro:assets`) -- the Cloudflare Images binding on Workers, sharp on Node -- producing width-appropriate candidates and modern formats (e.g. WebP) instead of a single full-size ``. + + This works automatically: + - Media served from a configured storage `publicUrl` (R2 custom domain, S3/CDN) is authorized and optimized. + - Same-origin proxied media (local storage, or R2 without a public URL) is optimized when `siteUrl` is set; the matching `image.remotePatterns` entry is registered for you, scoped to the media route. + - In `astro dev` it works out of the box without configuration. + + When optimization isn't possible (no image service available, an unauthorized host, or unknown dimensions) the components fall back to a plain ``, so existing sites keep rendering exactly as before. No template changes are required. + +- [#1312](https://github.com/emdash-cms/emdash/pull/1312) [`c39789c`](https://github.com/emdash-cms/emdash/commit/c39789c383e94125d8874a516988c7d9ca6f5484) Thanks [@ascorbic](https://github.com/ascorbic)! - Drive scheduled publishing from a real heartbeat instead of request side effects ([#1303](https://github.com/emdash-cms/emdash/issues/1303)). + + Content scheduled via the admin now actually transitions to `published` when its time arrives. Previously nothing promoted the row — `status` stayed `scheduled` and `published_at` stayed null forever. + + A new sweep (`publishDueContent`) promotes due content and runs alongside the existing cron tick and system cleanup: + - **Node / single-process:** the timer-based scheduler already drives it — no action needed. + - **Cloudflare Workers:** a `scheduled()` handler driven by a Cron Trigger now runs the sweep. The request-driven `PiggybackScheduler` is gone, so there are no maintenance side effects on visitor requests. + + `@emdash-cms/cloudflare` ships a Worker entry that wraps Astro's handler with the `scheduled()` handler (`@emdash-cms/cloudflare/worker`, plus `createScheduledHandler()` for hand-assembled Workers). When a cache provider is configured, the handler also purges edge-cache tags for whatever it published, so stale snapshots produced before the scheduled time are evicted. + + **Migration for existing Cloudflare sites.** New sites get this from the templates. Existing deployments must update two files: + + ```ts + // src/worker.ts + export { default, PluginBridge } from "@emdash-cms/cloudflare/worker"; + ``` + + ```jsonc + // wrangler.jsonc + "triggers": { "crons": ["* * * * *"] } + ``` + + Without the Cron Trigger, scheduled publishing and plugin cron do not run on Workers. + + Scheduled publishing matches manual publishing exactly: it fires `content:afterPublish` hooks (search indexing, webhooks, syndication), and records the _scheduled_ time as `published_at` on first publication rather than the (later) sweep time. The sweep claims each row atomically before promoting it, so an entry unscheduled or rescheduled just before its time is never published, and overlapping sweeps can't double-publish. Local `astro dev` keeps running the timer-driven sweep even under the Cloudflare adapter (where production relies on the Cron Trigger). + + Each tick promotes at most 100 items per collection (a large backlog drains over successive ticks) so a single Worker invocation can't exhaust its CPU/subrequest budget, and edge-cache tags are purged incrementally after each collection's batch rather than only at the end. On Node, the maintenance interval is capped at 60s so scheduled-publish latency matches the Cloudflare Cron Trigger cadence instead of lagging up to five minutes when no plugin cron is due. + +### Patch Changes + +- [#1307](https://github.com/emdash-cms/emdash/pull/1307) [`cedfcc5`](https://github.com/emdash-cms/emdash/commit/cedfcc527d47131baaa5dcfb29fb7b4a966265d5) Thanks [@emdashbot](https://github.com/apps/emdashbot)! - Read `?locale=` in content write routes (DELETE, publish, unpublish, discard-draft, schedule, unschedule) and forward it to `handleContentGet` for locale-aware slug resolution ([#1242](https://github.com/emdash-cms/emdash/issues/1242)) + +- [#1420](https://github.com/emdash-cms/emdash/pull/1420) [`c63f9ca`](https://github.com/emdash-cms/emdash/commit/c63f9ca56a8fc0cf4e1843887291fee0d78d89a2) Thanks [@swissky](https://github.com/swissky)! - `getTaxonomyTerms()` now returns the term `description` for flat + (non-hierarchical) taxonomies ([#1419](https://github.com/emdash-cms/emdash/issues/1419)) + + The query already fetched the `data` column, but the non-hierarchical branch + dropped it when mapping rows to `TaxonomyTerm` — only hierarchical taxonomies + (via `buildTree`) parsed the description. Descriptions set in the admin UI are + now returned for both kinds of taxonomies. + +- [#1426](https://github.com/emdash-cms/emdash/pull/1426) [`61ea3c9`](https://github.com/emdash-cms/emdash/commit/61ea3c9fee5b0f11974895a278d8297c56abec0b) Thanks [@MA2153](https://github.com/MA2153)! - Fix seed CLI hardcoding `en` as the default locale ([#1421](https://github.com/emdash-cms/emdash/issues/1421)) + + `emdash export-seed` now emits a top-level `defaultLocale` for single-locale + projects, and `emdash seed` (`applySeed`) honors it when backfilling the locale + of menus, taxonomies, and content rows that omit an explicit `locale`. Previously + an `export-seed` → `seed` round-trip silently rewrote a non-`en` default locale + (e.g. `de`) to `en`, since the CLI runs outside the Astro runtime and the + fallback collapsed to `en`. Projects whose default locale is `en` are unaffected. + +- [#1445](https://github.com/emdash-cms/emdash/pull/1445) [`a4c2af2`](https://github.com/emdash-cms/emdash/commit/a4c2af20ee27fef891290a442f7a20d4db64600d) Thanks [@ascorbic](https://github.com/ascorbic)! - Fix `getEmDashEntry` / `getEmDashCollection` hydrating taxonomy terms in the request-context or default locale instead of the entry's resolved locale ([#1441](https://github.com/emdash-cms/emdash/issues/1441)). When querying with an explicit `locale` (or via a localized route), `entry.data.terms` could return default-locale term variants even though the content row was correctly localized. Term hydration now uses the same resolved locale as the content query. + +- Updated dependencies [[`e96587f`](https://github.com/emdash-cms/emdash/commit/e96587f8ff393939355d3d643a322fe7b2c07c86), [`cedfcc5`](https://github.com/emdash-cms/emdash/commit/cedfcc527d47131baaa5dcfb29fb7b4a966265d5), [`7e70abc`](https://github.com/emdash-cms/emdash/commit/7e70abcc1434dc2fd94c1f51c8c8c76acc9aa536), [`783e663`](https://github.com/emdash-cms/emdash/commit/783e66365d5800e01ab445cbb411237240ff2ab4), [`157237d`](https://github.com/emdash-cms/emdash/commit/157237d6b3db0301f059534c9390bdef0a02b0cf)]: + - @emdash-cms/admin@0.19.0 + - @emdash-cms/auth@0.19.0 + - @emdash-cms/gutenberg-to-portable-text@0.19.0 + ## 0.18.0 ### Patch Changes diff --git a/packages/core/package.json b/packages/core/package.json index 3edcc67d7..4070a93ed 100644 --- a/packages/core/package.json +++ b/packages/core/package.json @@ -1,6 +1,6 @@ { "name": "emdash", - "version": "0.18.0", + "version": "0.19.0", "description": "Astro-native CMS with WordPress migration support", "type": "module", "main": "dist/index.mjs", diff --git a/packages/create-emdash/CHANGELOG.md b/packages/create-emdash/CHANGELOG.md index 237217ef7..f4067949b 100644 --- a/packages/create-emdash/CHANGELOG.md +++ b/packages/create-emdash/CHANGELOG.md @@ -1,5 +1,7 @@ # create-emdash +## 0.19.0 + ## 0.18.0 ## 0.17.2 diff --git a/packages/create-emdash/package.json b/packages/create-emdash/package.json index f19ddedba..f36d64f7b 100644 --- a/packages/create-emdash/package.json +++ b/packages/create-emdash/package.json @@ -1,6 +1,6 @@ { "name": "create-emdash", - "version": "0.18.0", + "version": "0.19.0", "description": "Create a new EmDash CMS project", "type": "module", "bin": "./dist/index.mjs", diff --git a/packages/gutenberg-to-portable-text/CHANGELOG.md b/packages/gutenberg-to-portable-text/CHANGELOG.md index 0e26870a8..85113ed6f 100644 --- a/packages/gutenberg-to-portable-text/CHANGELOG.md +++ b/packages/gutenberg-to-portable-text/CHANGELOG.md @@ -1,5 +1,7 @@ # @emdash-cms/gutenberg-to-portable-text +## 0.19.0 + ## 0.18.0 ## 0.17.2 diff --git a/packages/gutenberg-to-portable-text/package.json b/packages/gutenberg-to-portable-text/package.json index fabab5460..e0eee26f7 100644 --- a/packages/gutenberg-to-portable-text/package.json +++ b/packages/gutenberg-to-portable-text/package.json @@ -1,6 +1,6 @@ { "name": "@emdash-cms/gutenberg-to-portable-text", - "version": "0.18.0", + "version": "0.19.0", "description": "Convert WordPress Gutenberg blocks to Portable Text", "type": "module", "main": "dist/index.mjs", diff --git a/packages/plugins/embeds/CHANGELOG.md b/packages/plugins/embeds/CHANGELOG.md index 2eddc6972..fd3466364 100644 --- a/packages/plugins/embeds/CHANGELOG.md +++ b/packages/plugins/embeds/CHANGELOG.md @@ -1,5 +1,12 @@ # @emdash-cms/plugin-embeds +## 0.1.23 + +### Patch Changes + +- Updated dependencies []: + - @emdash-cms/blocks@0.19.0 + ## 0.1.22 ### Patch Changes diff --git a/packages/plugins/embeds/package.json b/packages/plugins/embeds/package.json index ca3cb3394..05c27ba53 100644 --- a/packages/plugins/embeds/package.json +++ b/packages/plugins/embeds/package.json @@ -1,6 +1,6 @@ { "name": "@emdash-cms/plugin-embeds", - "version": "0.1.22", + "version": "0.1.23", "description": "Embed blocks for EmDash CMS - YouTube, Vimeo, Twitter, Bluesky, Mastodon, and more", "type": "module", "main": "src/index.ts", diff --git a/packages/plugins/forms/CHANGELOG.md b/packages/plugins/forms/CHANGELOG.md index 4908d5a43..842c619c9 100644 --- a/packages/plugins/forms/CHANGELOG.md +++ b/packages/plugins/forms/CHANGELOG.md @@ -1,5 +1,11 @@ # @emdash-cms/plugin-forms +## 0.2.4 + +### Patch Changes + +- [#1395](https://github.com/emdash-cms/emdash/pull/1395) [`298895d`](https://github.com/emdash-cms/emdash/commit/298895de11562d4a2e9864da91d961fd4ff1eeda) Thanks [@jcheese1](https://github.com/jcheese1)! - Fixes enhanced form submissions so standard EmDash plugin API responses wrapped in `{ data }` show the configured success message instead of the generic error state. + ## 0.2.3 ### Patch Changes diff --git a/packages/plugins/forms/package.json b/packages/plugins/forms/package.json index 3b2b666df..8847cb04e 100644 --- a/packages/plugins/forms/package.json +++ b/packages/plugins/forms/package.json @@ -1,6 +1,6 @@ { "name": "@emdash-cms/plugin-forms", - "version": "0.2.3", + "version": "0.2.4", "description": "Forms plugin for EmDash CMS - build forms, collect submissions, send notifications", "type": "module", "main": "src/index.ts", diff --git a/packages/workerd/CHANGELOG.md b/packages/workerd/CHANGELOG.md index dec42ce73..7cb835031 100644 --- a/packages/workerd/CHANGELOG.md +++ b/packages/workerd/CHANGELOG.md @@ -1,5 +1,12 @@ # @emdash-cms/sandbox-workerd +## 0.1.7 + +### Patch Changes + +- Updated dependencies [[`e96587f`](https://github.com/emdash-cms/emdash/commit/e96587f8ff393939355d3d643a322fe7b2c07c86), [`023893a`](https://github.com/emdash-cms/emdash/commit/023893a0fa966b95aad4ff533fc2966b3e3dfe03), [`f41092b`](https://github.com/emdash-cms/emdash/commit/f41092bd847f1eb161034f1d2c67976e8473e794), [`cedfcc5`](https://github.com/emdash-cms/emdash/commit/cedfcc527d47131baaa5dcfb29fb7b4a966265d5), [`c63f9ca`](https://github.com/emdash-cms/emdash/commit/c63f9ca56a8fc0cf4e1843887291fee0d78d89a2), [`61ea3c9`](https://github.com/emdash-cms/emdash/commit/61ea3c9fee5b0f11974895a278d8297c56abec0b), [`a4c2af2`](https://github.com/emdash-cms/emdash/commit/a4c2af20ee27fef891290a442f7a20d4db64600d), [`850c1b7`](https://github.com/emdash-cms/emdash/commit/850c1b7e23eb1b083c0fcb753762effa1d3a207a), [`c39789c`](https://github.com/emdash-cms/emdash/commit/c39789c383e94125d8874a516988c7d9ca6f5484)]: + - emdash@0.19.0 + ## 0.1.6 ### Patch Changes diff --git a/packages/workerd/package.json b/packages/workerd/package.json index e0ebff328..99c1abac8 100644 --- a/packages/workerd/package.json +++ b/packages/workerd/package.json @@ -1,6 +1,6 @@ { "name": "@emdash-cms/sandbox-workerd", - "version": "0.1.6", + "version": "0.1.7", "description": "workerd-based plugin sandbox for EmDash on Node.js", "type": "module", "main": "dist/index.mjs", diff --git a/packages/x402/CHANGELOG.md b/packages/x402/CHANGELOG.md index 54fface7e..82a7dba92 100644 --- a/packages/x402/CHANGELOG.md +++ b/packages/x402/CHANGELOG.md @@ -1,5 +1,7 @@ # @emdash-cms/x402 +## 0.19.0 + ## 0.18.0 ## 0.17.2 diff --git a/packages/x402/package.json b/packages/x402/package.json index 726b3c6b3..b2e8d7a37 100644 --- a/packages/x402/package.json +++ b/packages/x402/package.json @@ -1,6 +1,6 @@ { "name": "@emdash-cms/x402", - "version": "0.18.0", + "version": "0.19.0", "description": "x402 payment protocol integration for Astro sites", "license": "MIT", "repository": {