emdash 0.25.1 → 0.26.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/api/route-utils.d.mts +3 -3
- package/dist/api/route-utils.mjs +11 -11
- package/dist/{api-D2_sbavn.mjs → api-BMfveMoB.mjs} +15 -15
- package/dist/{api-D2_sbavn.mjs.map → api-BMfveMoB.mjs.map} +1 -1
- package/dist/{apply-Bk2mAuLn.mjs → apply--IVNSdXn.mjs} +18 -16
- package/dist/apply--IVNSdXn.mjs.map +1 -0
- package/dist/astro/index.d.mts +7 -7
- package/dist/astro/index.mjs +2 -1
- package/dist/astro/index.mjs.map +1 -1
- package/dist/astro/middleware/auth.d.mts +7 -7
- package/dist/astro/middleware/auth.mjs +2 -2
- package/dist/astro/middleware/redirect.mjs +4 -4
- package/dist/astro/middleware.d.mts +1 -1
- package/dist/astro/middleware.mjs +85 -85
- package/dist/astro/middleware.mjs.map +1 -1
- package/dist/astro/routes/api/admin/allowed-domains/_domain_.mjs +3 -3
- package/dist/astro/routes/api/admin/allowed-domains/index.mjs +3 -3
- package/dist/astro/routes/api/admin/api-tokens/_id_.mjs +2 -2
- package/dist/astro/routes/api/admin/api-tokens/index.mjs +3 -3
- package/dist/astro/routes/api/admin/byline-fields/_slug_/usage.mjs +3 -3
- package/dist/astro/routes/api/admin/byline-fields/_slug_.mjs +4 -4
- package/dist/astro/routes/api/admin/byline-fields/index.mjs +4 -4
- package/dist/astro/routes/api/admin/byline-fields/reorder.mjs +4 -4
- package/dist/astro/routes/api/admin/bylines/_id_/index.mjs +10 -10
- package/dist/astro/routes/api/admin/bylines/_id_/translations.mjs +10 -10
- package/dist/astro/routes/api/admin/bylines/index.mjs +10 -10
- package/dist/astro/routes/api/admin/comments/_id_/status.mjs +8 -8
- package/dist/astro/routes/api/admin/comments/_id_.mjs +6 -6
- package/dist/astro/routes/api/admin/comments/bulk.mjs +7 -7
- package/dist/astro/routes/api/admin/comments/counts.mjs +6 -6
- package/dist/astro/routes/api/admin/comments/index.mjs +7 -7
- package/dist/astro/routes/api/admin/hooks/exclusive/_hookName_.mjs +4 -4
- package/dist/astro/routes/api/admin/hooks/exclusive/index.mjs +3 -3
- package/dist/astro/routes/api/admin/oauth-clients/_id_.mjs +3 -3
- package/dist/astro/routes/api/admin/oauth-clients/index.mjs +3 -3
- package/dist/astro/routes/api/admin/plugins/_id_/disable.mjs +28 -28
- package/dist/astro/routes/api/admin/plugins/_id_/enable.mjs +28 -28
- package/dist/astro/routes/api/admin/plugins/_id_/index.mjs +28 -28
- package/dist/astro/routes/api/admin/plugins/_id_/uninstall.mjs +28 -28
- package/dist/astro/routes/api/admin/plugins/_id_/update.mjs +28 -28
- package/dist/astro/routes/api/admin/plugins/index.mjs +28 -28
- package/dist/astro/routes/api/admin/plugins/marketplace/_id_/icon.mjs +3 -3
- package/dist/astro/routes/api/admin/plugins/marketplace/_id_/index.mjs +28 -28
- package/dist/astro/routes/api/admin/plugins/marketplace/_id_/install.mjs +28 -28
- package/dist/astro/routes/api/admin/plugins/marketplace/index.mjs +28 -28
- package/dist/astro/routes/api/admin/plugins/registry/_id_/uninstall.mjs +28 -28
- package/dist/astro/routes/api/admin/plugins/registry/_id_/update.mjs +29 -29
- package/dist/astro/routes/api/admin/plugins/registry/artifact.mjs +28 -28
- package/dist/astro/routes/api/admin/plugins/registry/install.mjs +29 -29
- package/dist/astro/routes/api/admin/plugins/updates.mjs +28 -28
- package/dist/astro/routes/api/admin/themes/marketplace/_id_/index.mjs +28 -28
- package/dist/astro/routes/api/admin/themes/marketplace/_id_/thumbnail.mjs +3 -3
- package/dist/astro/routes/api/admin/themes/marketplace/index.mjs +28 -28
- package/dist/astro/routes/api/admin/users/_id_/disable.mjs +2 -2
- package/dist/astro/routes/api/admin/users/_id_/enable.mjs +2 -2
- package/dist/astro/routes/api/admin/users/_id_/index.mjs +3 -3
- package/dist/astro/routes/api/admin/users/_id_/send-recovery.mjs +2 -2
- package/dist/astro/routes/api/admin/users/index.mjs +3 -3
- package/dist/astro/routes/api/auth/dev-bypass.mjs +3 -3
- package/dist/astro/routes/api/auth/invite/accept.mjs +2 -2
- package/dist/astro/routes/api/auth/invite/complete.mjs +3 -3
- package/dist/astro/routes/api/auth/invite/index.mjs +3 -3
- package/dist/astro/routes/api/auth/invite/register-options.mjs +3 -3
- package/dist/astro/routes/api/auth/logout.mjs +2 -2
- package/dist/astro/routes/api/auth/magic-link/send.mjs +4 -4
- package/dist/astro/routes/api/auth/magic-link/verify.mjs +2 -2
- package/dist/astro/routes/api/auth/me.mjs +4 -4
- package/dist/astro/routes/api/auth/passkey/_id_.mjs +3 -3
- package/dist/astro/routes/api/auth/passkey/index.mjs +2 -2
- package/dist/astro/routes/api/auth/passkey/options.mjs +4 -4
- package/dist/astro/routes/api/auth/passkey/register/options.mjs +3 -3
- package/dist/astro/routes/api/auth/passkey/register/verify.mjs +3 -3
- package/dist/astro/routes/api/auth/passkey/verify.mjs +3 -3
- package/dist/astro/routes/api/auth/signup/complete.mjs +3 -3
- package/dist/astro/routes/api/auth/signup/request.mjs +4 -4
- package/dist/astro/routes/api/auth/signup/verify.mjs +2 -2
- package/dist/astro/routes/api/comments/_collection_/_contentId_/index.mjs +7 -7
- package/dist/astro/routes/api/comments/_collection_/_contentId_/reactions.mjs +7 -7
- package/dist/astro/routes/api/content/_collection_/_id_/compare.mjs +3 -3
- package/dist/astro/routes/api/content/_collection_/_id_/discard-draft.mjs +3 -3
- package/dist/astro/routes/api/content/_collection_/_id_/duplicate.mjs +3 -3
- package/dist/astro/routes/api/content/_collection_/_id_/permanent.mjs +3 -3
- package/dist/astro/routes/api/content/_collection_/_id_/preview-url.mjs +4 -4
- package/dist/astro/routes/api/content/_collection_/_id_/publish.mjs +4 -4
- package/dist/astro/routes/api/content/_collection_/_id_/restore.mjs +3 -3
- package/dist/astro/routes/api/content/_collection_/_id_/revisions.mjs +3 -3
- package/dist/astro/routes/api/content/_collection_/_id_/schedule.mjs +4 -4
- package/dist/astro/routes/api/content/_collection_/_id_/terms/_taxonomy_.mjs +9 -9
- package/dist/astro/routes/api/content/_collection_/_id_/translations.mjs +3 -3
- package/dist/astro/routes/api/content/_collection_/_id_/unpublish.mjs +3 -3
- package/dist/astro/routes/api/content/_collection_/_id_.mjs +4 -4
- package/dist/astro/routes/api/content/_collection_/authors.mjs +3 -3
- package/dist/astro/routes/api/content/_collection_/index.mjs +4 -4
- package/dist/astro/routes/api/content/_collection_/trash.mjs +4 -4
- package/dist/astro/routes/api/dashboard.mjs +8 -8
- package/dist/astro/routes/api/dev/emails.mjs +2 -2
- package/dist/astro/routes/api/import/probe.d.mts +2 -2
- package/dist/astro/routes/api/import/probe.mjs +4 -4
- package/dist/astro/routes/api/import/wordpress/analyze.mjs +3 -3
- package/dist/astro/routes/api/import/wordpress/execute.d.mts +7 -7
- package/dist/astro/routes/api/import/wordpress/execute.mjs +9 -9
- package/dist/astro/routes/api/import/wordpress/media.d.mts +7 -7
- package/dist/astro/routes/api/import/wordpress/media.mjs +4 -4
- package/dist/astro/routes/api/import/wordpress/prepare.mjs +6 -6
- package/dist/astro/routes/api/import/wordpress/rewrite-urls.mjs +5 -5
- package/dist/astro/routes/api/import/wordpress-plugin/analyze.mjs +4 -4
- package/dist/astro/routes/api/import/wordpress-plugin/execute.mjs +7 -7
- package/dist/astro/routes/api/manifest.mjs +3 -3
- package/dist/astro/routes/api/mcp.mjs +34 -34
- package/dist/astro/routes/api/media/_id_/confirm.mjs +4 -4
- package/dist/astro/routes/api/media/_id_.mjs +4 -4
- package/dist/astro/routes/api/media/file/_...key_.mjs +2 -2
- package/dist/astro/routes/api/media/providers/_providerId_/_itemId_.mjs +3 -3
- package/dist/astro/routes/api/media/providers/_providerId_/index.mjs +3 -3
- package/dist/astro/routes/api/media/providers/index.mjs +3 -3
- package/dist/astro/routes/api/media/upload-url.mjs +4 -4
- package/dist/astro/routes/api/media.mjs +5 -5
- package/dist/astro/routes/api/menus/_name_/items/_id_.mjs +6 -6
- package/dist/astro/routes/api/menus/_name_/items.mjs +6 -6
- package/dist/astro/routes/api/menus/_name_/reorder.mjs +6 -6
- package/dist/astro/routes/api/menus/_name_/translations.mjs +6 -6
- package/dist/astro/routes/api/menus/_name_.mjs +6 -6
- package/dist/astro/routes/api/menus/index.mjs +6 -6
- package/dist/astro/routes/api/oauth/device/authorize.mjs +3 -3
- package/dist/astro/routes/api/oauth/device/code.mjs +4 -4
- package/dist/astro/routes/api/oauth/device/token.mjs +4 -4
- package/dist/astro/routes/api/oauth/register.mjs +2 -2
- package/dist/astro/routes/api/oauth/token/refresh.mjs +3 -3
- package/dist/astro/routes/api/oauth/token/revoke.mjs +3 -3
- package/dist/astro/routes/api/oauth/token.mjs +2 -2
- package/dist/astro/routes/api/openapi.json.mjs +2 -2
- package/dist/astro/routes/api/plugins/_pluginId_/_...path_.mjs +3 -3
- package/dist/astro/routes/api/redirects/404s/index.mjs +6 -6
- package/dist/astro/routes/api/redirects/404s/summary.mjs +6 -6
- package/dist/astro/routes/api/redirects/_id_.mjs +7 -7
- package/dist/astro/routes/api/redirects/index.mjs +7 -7
- package/dist/astro/routes/api/revisions/_revisionId_/index.mjs +3 -3
- package/dist/astro/routes/api/revisions/_revisionId_/restore.mjs +3 -3
- package/dist/astro/routes/api/schema/collections/_slug_/fields/_fieldSlug_.mjs +28 -28
- package/dist/astro/routes/api/schema/collections/_slug_/fields/index.mjs +28 -28
- package/dist/astro/routes/api/schema/collections/_slug_/fields/reorder.mjs +28 -28
- package/dist/astro/routes/api/schema/collections/_slug_/index.mjs +28 -28
- package/dist/astro/routes/api/schema/collections/index.mjs +28 -28
- package/dist/astro/routes/api/schema/index.mjs +6 -6
- package/dist/astro/routes/api/schema/orphans/_slug_.mjs +28 -28
- package/dist/astro/routes/api/schema/orphans/index.mjs +28 -28
- package/dist/astro/routes/api/search/enable.mjs +7 -7
- package/dist/astro/routes/api/search/index.mjs +6 -6
- package/dist/astro/routes/api/search/rebuild.mjs +7 -7
- package/dist/astro/routes/api/search/stats.mjs +6 -6
- package/dist/astro/routes/api/search/suggest.mjs +6 -6
- package/dist/astro/routes/api/sections/_slug_.mjs +6 -6
- package/dist/astro/routes/api/sections/index.mjs +6 -6
- package/dist/astro/routes/api/settings/email.mjs +4 -4
- package/dist/astro/routes/api/settings.mjs +9 -9
- package/dist/astro/routes/api/setup/admin-verify.mjs +3 -3
- package/dist/astro/routes/api/setup/admin.mjs +3 -3
- package/dist/astro/routes/api/setup/dev-bypass.mjs +17 -17
- package/dist/astro/routes/api/setup/dev-reset.mjs +2 -2
- package/dist/astro/routes/api/setup/index.mjs +18 -18
- package/dist/astro/routes/api/setup/status.mjs +3 -3
- package/dist/astro/routes/api/snapshot.mjs +3 -3
- package/dist/astro/routes/api/taxonomies/_name_/terms/_slug_/translations.mjs +9 -9
- package/dist/astro/routes/api/taxonomies/_name_/terms/_slug_.mjs +9 -9
- package/dist/astro/routes/api/taxonomies/_name_/terms/index.mjs +9 -9
- package/dist/astro/routes/api/taxonomies/index.mjs +9 -9
- package/dist/astro/routes/api/themes/preview.mjs +3 -3
- package/dist/astro/routes/api/typegen.mjs +5 -5
- package/dist/astro/routes/api/widget-areas/_name_/reorder.mjs +4 -4
- package/dist/astro/routes/api/widget-areas/_name_/widgets/_id_.mjs +6 -6
- package/dist/astro/routes/api/widget-areas/_name_/widgets.mjs +6 -6
- package/dist/astro/routes/api/widget-areas/_name_.mjs +5 -5
- package/dist/astro/routes/api/widget-areas/index.mjs +6 -6
- package/dist/astro/routes/api/widget-components.mjs +2 -2
- package/dist/astro/routes/robots.txt.mjs +5 -5
- package/dist/astro/routes/sitemap-_collection_.xml.mjs +10 -9
- package/dist/astro/routes/sitemap-_collection_.xml.mjs.map +1 -1
- package/dist/astro/routes/sitemap.xml.mjs +5 -5
- package/dist/astro/types.d.mts +7 -7
- package/dist/{authorize-CuxZ0i2t.mjs → authorize-BZnOGJFo.mjs} +2 -2
- package/dist/{authorize-CuxZ0i2t.mjs.map → authorize-BZnOGJFo.mjs.map} +1 -1
- package/dist/{byline-C-YajfV7.mjs → byline-LL8lyqdb.mjs} +6 -6
- package/dist/{byline-C-YajfV7.mjs.map → byline-LL8lyqdb.mjs.map} +1 -1
- package/dist/{bylines-D4KADDAi.mjs → bylines-BmJ7Vg7J.mjs} +4 -4
- package/dist/{bylines-D4KADDAi.mjs.map → bylines-BmJ7Vg7J.mjs.map} +1 -1
- package/dist/{bylines-CPc_q2Vd.mjs → bylines-DE47vP8d.mjs} +5 -5
- package/dist/{bylines-CPc_q2Vd.mjs.map → bylines-DE47vP8d.mjs.map} +1 -1
- package/dist/{cache-C35VWD5D.mjs → cache-D9jF5bYw.mjs} +2 -2
- package/dist/{cache-C35VWD5D.mjs.map → cache-D9jF5bYw.mjs.map} +1 -1
- package/dist/{chunks-BHgcHh2C.mjs → chunks-OCG163rN.mjs} +2 -2
- package/dist/{chunks-BHgcHh2C.mjs.map → chunks-OCG163rN.mjs.map} +1 -1
- package/dist/cli/index.mjs +16 -16
- package/dist/{comment-BDx50EX5.mjs → comment-D9BLDpZI.mjs} +3 -3
- package/dist/{comment-BDx50EX5.mjs.map → comment-D9BLDpZI.mjs.map} +1 -1
- package/dist/{comment-reaction-Gv_pgfI3.mjs → comment-reaction-Drl9SkNu.mjs} +2 -2
- package/dist/{comment-reaction-Gv_pgfI3.mjs.map → comment-reaction-Drl9SkNu.mjs.map} +1 -1
- package/dist/{comments-CXHuQ6jI.mjs → comments-BjJ9SKGU.mjs} +3 -3
- package/dist/{comments-CXHuQ6jI.mjs.map → comments-BjJ9SKGU.mjs.map} +1 -1
- package/dist/{content-B43-YrIq.mjs → content-ncUWWjna.mjs} +4 -4
- package/dist/{content-B43-YrIq.mjs.map → content-ncUWWjna.mjs.map} +1 -1
- package/dist/{context-BW3N7wyt.mjs → context-C_g-iJVA.mjs} +7 -7
- package/dist/{context-BW3N7wyt.mjs.map → context-C_g-iJVA.mjs.map} +1 -1
- package/dist/{dashboard-FIe0S512.mjs → dashboard-CotyqQrW.mjs} +4 -4
- package/dist/{dashboard-FIe0S512.mjs.map → dashboard-CotyqQrW.mjs.map} +1 -1
- package/dist/db/index.d.mts +2 -2
- package/dist/db/index.mjs +1 -1
- package/dist/{error-DXnK2wF4.mjs → error-rVGiqWDt.mjs} +2 -2
- package/dist/{error-DXnK2wF4.mjs.map → error-rVGiqWDt.mjs.map} +1 -1
- package/dist/{field-defs-cache-CYYx8xlG.mjs → field-defs-cache-ljXzJCfc.mjs} +2 -2
- package/dist/{field-defs-cache-CYYx8xlG.mjs.map → field-defs-cache-ljXzJCfc.mjs.map} +1 -1
- package/dist/{fts-manager-DW_NR-Fs.mjs → fts-manager-BbCCbEKA.mjs} +2 -2
- package/dist/{fts-manager-DW_NR-Fs.mjs.map → fts-manager-BbCCbEKA.mjs.map} +1 -1
- package/dist/{index-Cz6_JBL3.d.mts → index-BRNabKrx.d.mts} +36 -11
- package/dist/index-BRNabKrx.d.mts.map +1 -0
- package/dist/{index-qbL02uhs.d.mts → index-Dt0OKJB4.d.mts} +2 -2
- package/dist/{index-qbL02uhs.d.mts.map → index-Dt0OKJB4.d.mts.map} +1 -1
- package/dist/index.d.mts +8 -8
- package/dist/index.mjs +38 -38
- package/dist/{load-DMFi4n1p.mjs → load-DMjXghbZ.mjs} +2 -2
- package/dist/{load-DMFi4n1p.mjs.map → load-DMjXghbZ.mjs.map} +1 -1
- package/dist/{loader-DrpofRon.mjs → loader-BA_zhkS_.mjs} +81 -18
- package/dist/loader-BA_zhkS_.mjs.map +1 -0
- package/dist/{manifest-schema-BOfPXse0.mjs → manifest-schema-kPGX7VS-.mjs} +3 -1
- package/dist/manifest-schema-kPGX7VS-.mjs.map +1 -0
- package/dist/media/local-runtime.d.mts +7 -7
- package/dist/media/local-runtime.mjs +5 -5
- package/dist/{media-BjKxjzk8.mjs → media-C5t_eCnk.mjs} +2 -2
- package/dist/{media-BjKxjzk8.mjs.map → media-C5t_eCnk.mjs.map} +1 -1
- package/dist/{menus-8O6xNcYW.mjs → menus-CBb6UrMU.mjs} +3 -3
- package/dist/{menus-8O6xNcYW.mjs.map → menus-CBb6UrMU.mjs.map} +1 -1
- package/dist/{menus-CxqJ-z-N.mjs → menus-CYH09a41.mjs} +50 -68
- package/dist/menus-CYH09a41.mjs.map +1 -0
- package/dist/{object-cache-SEb2IM4Z.mjs → object-cache-CHbHv83-.mjs} +8 -4
- package/dist/object-cache-CHbHv83-.mjs.map +1 -0
- package/dist/{options-BvClpP5Q.d.mts → options-41nCWqi9.d.mts} +2 -2
- package/dist/{options-BvClpP5Q.d.mts.map → options-41nCWqi9.d.mts.map} +1 -1
- package/dist/page/index.d.mts +5 -2
- package/dist/page/index.d.mts.map +1 -1
- package/dist/page/index.mjs +3 -2
- package/dist/page/index.mjs.map +1 -1
- package/dist/{parse-DqMWHQ8x.mjs → parse-BwAdS7FZ.mjs} +2 -2
- package/dist/{parse-DqMWHQ8x.mjs.map → parse-BwAdS7FZ.mjs.map} +1 -1
- package/dist/plugin-types.d.mts +4 -2
- package/dist/plugin-types.d.mts.map +1 -1
- package/dist/plugin-utils.d.mts +7 -7
- package/dist/plugins/adapt-sandbox-entry.d.mts +7 -7
- package/dist/plugins/adapt-sandbox-entry.mjs +1 -1
- package/dist/{query-34pfm02Q.mjs → query-BpQb-blG.mjs} +14 -14
- package/dist/{query-34pfm02Q.mjs.map → query-BpQb-blG.mjs.map} +1 -1
- package/dist/{rate-limit-CBQK4ygJ.mjs → rate-limit-Dap6HMNM.mjs} +2 -2
- package/dist/{rate-limit-CBQK4ygJ.mjs.map → rate-limit-Dap6HMNM.mjs.map} +1 -1
- package/dist/{redirect-C1KVGYWe.mjs → redirect-_M0trWoo.mjs} +2 -2
- package/dist/{redirect-C1KVGYWe.mjs.map → redirect-_M0trWoo.mjs.map} +1 -1
- package/dist/{redirects-DgnypVir.mjs → redirects-w0V9vj_j.mjs} +3 -3
- package/dist/{redirects-DgnypVir.mjs.map → redirects-w0V9vj_j.mjs.map} +1 -1
- package/dist/{registry-3aOAS4My.mjs → registry-g8yYt4cC.mjs} +4 -4
- package/dist/{registry-3aOAS4My.mjs.map → registry-g8yYt4cC.mjs.map} +1 -1
- package/dist/{runner-CEtq-6Sm.d.mts → runner-BbR3DfrL.d.mts} +2 -2
- package/dist/{runner-CEtq-6Sm.d.mts.map → runner-BbR3DfrL.d.mts.map} +1 -1
- package/dist/{runner-BsquExlK.mjs → runner-DPdt_Wpa.mjs} +250 -178
- package/dist/runner-DPdt_Wpa.mjs.map +1 -0
- package/dist/runtime.d.mts +7 -7
- package/dist/runtime.mjs +2 -2
- package/dist/{schema-BGwx8AQY.mjs → schema-DoLd3j2e.mjs} +5 -5
- package/dist/{schema-BGwx8AQY.mjs.map → schema-DoLd3j2e.mjs.map} +1 -1
- package/dist/{search-Gl747zMP.mjs → search-BR0ZeZmh.mjs} +4 -4
- package/dist/{search-Gl747zMP.mjs.map → search-BR0ZeZmh.mjs.map} +1 -1
- package/dist/{sections-C-umuuLj.mjs → sections-5J2YJPqJ.mjs} +3 -3
- package/dist/{sections-C-umuuLj.mjs.map → sections-5J2YJPqJ.mjs.map} +1 -1
- package/dist/seed/index.d.mts +2 -2
- package/dist/seed/index.mjs +15 -15
- package/dist/{seo-BNzkiK_W.mjs → seo-DKeXHkzE.mjs} +3 -3
- package/dist/{seo-BNzkiK_W.mjs.map → seo-DKeXHkzE.mjs.map} +1 -1
- package/dist/{service-CQHK_10l.mjs → service-BbO2s8gT.mjs} +2 -2
- package/dist/{service-CQHK_10l.mjs.map → service-BbO2s8gT.mjs.map} +1 -1
- package/dist/{settings-fPSR6dJa.mjs → settings-BMNr9Dmi.mjs} +3 -3
- package/dist/{settings-fPSR6dJa.mjs.map → settings-BMNr9Dmi.mjs.map} +1 -1
- package/dist/{settings-C4tXRYiG.mjs → settings-DJeki-97.mjs} +4 -4
- package/dist/{settings-C4tXRYiG.mjs.map → settings-DJeki-97.mjs.map} +1 -1
- package/dist/{taxonomies-DbAtL6m4.mjs → taxonomies-CM_fUqLU.mjs} +5 -4
- package/dist/taxonomies-CM_fUqLU.mjs.map +1 -0
- package/dist/{taxonomies-n8w72lLQ.mjs → taxonomies-D13i2ctt.mjs} +75 -20
- package/dist/taxonomies-D13i2ctt.mjs.map +1 -0
- package/dist/{taxonomy-BBUlGug5.mjs → taxonomy-BU0LjdVb.mjs} +4 -4
- package/dist/{taxonomy-BBUlGug5.mjs.map → taxonomy-BU0LjdVb.mjs.map} +1 -1
- package/dist/{types-h2Cwbzi2.d.mts → types-BYnDBVwe.d.mts} +24 -5
- package/dist/{types-h2Cwbzi2.d.mts.map → types-BYnDBVwe.d.mts.map} +1 -1
- package/dist/{types-CmI1OyQg.mjs → types-CZgK3EMW.mjs} +2 -2
- package/dist/{types-CmI1OyQg.mjs.map → types-CZgK3EMW.mjs.map} +1 -1
- package/dist/{types-B-gIxFCE.d.mts → types-xIfVRNLp.d.mts} +38 -1
- package/dist/types-xIfVRNLp.d.mts.map +1 -0
- package/dist/{user-JAuc8VUf.mjs → user-DkG2jKCp.mjs} +3 -3
- package/dist/{user-JAuc8VUf.mjs.map → user-DkG2jKCp.mjs.map} +1 -1
- package/dist/{validate-Va_An3qb.d.mts → validate-CG0V0wNR.d.mts} +2 -2
- package/dist/{validate-Va_An3qb.d.mts.map → validate-CG0V0wNR.d.mts.map} +1 -1
- package/dist/{validate-BzXHWnkV.mjs → validate-CuJ1Ps9j.mjs} +2 -2
- package/dist/{validate-BzXHWnkV.mjs.map → validate-CuJ1Ps9j.mjs.map} +1 -1
- package/dist/{validation-B6DKPTtU.mjs → validation-CwUfTdGF.mjs} +5 -5
- package/dist/{validation-B6DKPTtU.mjs.map → validation-CwUfTdGF.mjs.map} +1 -1
- package/dist/version-BoNBItP_.mjs +7 -0
- package/dist/{version-DHdCA24u.mjs.map → version-BoNBItP_.mjs.map} +1 -1
- package/dist/{widgets-C2RbFN0G.mjs → widgets-BfOZ-ajY.mjs} +2 -2
- package/dist/{widgets-C2RbFN0G.mjs.map → widgets-BfOZ-ajY.mjs.map} +1 -1
- package/dist/{zod-generator-xEHODMJf.mjs → zod-generator-gFsRuNNy.mjs} +6 -3
- package/dist/zod-generator-gFsRuNNy.mjs.map +1 -0
- package/package.json +5 -5
- package/src/api/handlers/taxonomies.ts +5 -1
- package/src/astro/integration/virtual-modules.ts +15 -0
- package/src/astro/routes/sitemap-[collection].xml.ts +5 -4
- package/src/components/EmDashHead.astro +23 -3
- package/src/components/JsonLdScript.astro +9 -0
- package/src/database/migrations/036_i18n_menus_and_taxonomies.ts +16 -0
- package/src/database/migrations/046_media_usage_index.ts +115 -0
- package/src/database/migrations/047_restore_taxonomy_parent_index.ts +29 -0
- package/src/database/migrations/runner.ts +4 -0
- package/src/database/repositories/media-usage.ts +444 -0
- package/src/database/types.ts +39 -0
- package/src/emdash-runtime.ts +61 -52
- package/src/index.ts +3 -0
- package/src/loader.ts +110 -31
- package/src/media/usage/extractor.ts +302 -0
- package/src/media/usage/types.ts +46 -0
- package/src/object-cache/index.ts +8 -2
- package/src/page/metadata.ts +23 -3
- package/src/plugin-types.ts +10 -0
- package/src/plugins/define-plugin.ts +14 -5
- package/src/plugins/hooks.ts +53 -65
- package/src/plugins/index.ts +5 -0
- package/src/plugins/manager.ts +22 -0
- package/src/plugins/manifest-schema.ts +2 -0
- package/src/plugins/types.ts +35 -3
- package/src/schema/zod-generator.ts +9 -1
- package/src/seed/apply.ts +6 -0
- package/src/taxonomies/index.ts +121 -18
- package/dist/apply-Bk2mAuLn.mjs.map +0 -1
- package/dist/index-Cz6_JBL3.d.mts.map +0 -1
- package/dist/loader-DrpofRon.mjs.map +0 -1
- package/dist/manifest-schema-BOfPXse0.mjs.map +0 -1
- package/dist/menus-CxqJ-z-N.mjs.map +0 -1
- package/dist/object-cache-SEb2IM4Z.mjs.map +0 -1
- package/dist/runner-BsquExlK.mjs.map +0 -1
- package/dist/taxonomies-DbAtL6m4.mjs.map +0 -1
- package/dist/taxonomies-n8w72lLQ.mjs.map +0 -1
- package/dist/types-B-gIxFCE.d.mts.map +0 -1
- package/dist/version-DHdCA24u.mjs +0 -7
- package/dist/zod-generator-xEHODMJf.mjs.map +0 -1
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import "../../options-
|
|
2
|
-
import "../../types-
|
|
3
|
-
import "../../types-
|
|
1
|
+
import "../../options-41nCWqi9.mjs";
|
|
2
|
+
import "../../types-xIfVRNLp.mjs";
|
|
3
|
+
import "../../types-BYnDBVwe.mjs";
|
|
4
4
|
import "../../byline-fields-KD3JFRuH.mjs";
|
|
5
|
-
import "../../index-
|
|
6
|
-
import "../../runner-
|
|
7
|
-
import "../../index-
|
|
5
|
+
import "../../index-BRNabKrx.mjs";
|
|
6
|
+
import "../../runner-BbR3DfrL.mjs";
|
|
7
|
+
import "../../index-Dt0OKJB4.mjs";
|
|
8
8
|
import "../../types-CUsXGRVj.mjs";
|
|
9
|
-
import "../../validate-
|
|
9
|
+
import "../../validate-CG0V0wNR.mjs";
|
|
10
10
|
import { EmDashHandlers } from "../types.mjs";
|
|
11
11
|
import { User } from "@emdash-cms/auth";
|
|
12
12
|
import * as astro from "astro";
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import "../../after-B1IIdH3Y.mjs";
|
|
2
2
|
import "../../base64-CmWvODNW.mjs";
|
|
3
|
-
import "../../types-
|
|
4
|
-
import { t as apiError } from "../../error-
|
|
3
|
+
import "../../types-CZgK3EMW.mjs";
|
|
4
|
+
import { t as apiError } from "../../error-rVGiqWDt.mjs";
|
|
5
5
|
import { n as getPublicOrigin } from "../../public-url-CTVqgMmg.mjs";
|
|
6
6
|
import { t as getAuthMode } from "../../mode-BB0F8xTC.mjs";
|
|
7
7
|
import { t as resolveSessionUser } from "../../session-user-B8aLtKAH.mjs";
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import "../../dialect-helpers-DRI5pyY3.mjs";
|
|
2
2
|
import "../../base64-CmWvODNW.mjs";
|
|
3
|
-
import "../../types-
|
|
4
|
-
import { t as RedirectRepository } from "../../redirect-
|
|
5
|
-
import { a as setCachedRedirects, i as matchCachedPatterns, n as getCachedRedirects } from "../../cache-
|
|
6
|
-
import { a as getDb } from "../../loader-
|
|
3
|
+
import "../../types-CZgK3EMW.mjs";
|
|
4
|
+
import { t as RedirectRepository } from "../../redirect-_M0trWoo.mjs";
|
|
5
|
+
import { a as setCachedRedirects, i as matchCachedPatterns, n as getCachedRedirects } from "../../cache-D9jF5bYw.mjs";
|
|
6
|
+
import { a as getDb } from "../../loader-BA_zhkS_.mjs";
|
|
7
7
|
import { n as isTerminalStatus } from "../../status-vUK0SA17.mjs";
|
|
8
8
|
import { defineMiddleware } from "astro:middleware";
|
|
9
9
|
|
|
@@ -1,57 +1,57 @@
|
|
|
1
|
-
import { i as runMigrations, t as MIGRATION_RACE_WAIT_MS } from "../runner-
|
|
1
|
+
import { i as runMigrations, t as MIGRATION_RACE_WAIT_MS } from "../runner-DPdt_Wpa.mjs";
|
|
2
2
|
import { t as validateIdentifier } from "../validate-VPnKoIzW.mjs";
|
|
3
3
|
import { o as isSqlite } from "../dialect-helpers-DRI5pyY3.mjs";
|
|
4
4
|
import { i as setI18nConfig } from "../config-CVssduLe.mjs";
|
|
5
|
-
import { _ as resolveExclusiveHooks, g as createHookPipeline, m as EmailPipeline, p as PluginRouteRegistry, t as getMenu, v as definePlugin } from "../menus-
|
|
5
|
+
import { _ as resolveExclusiveHooks, g as createHookPipeline, m as EmailPipeline, p as PluginRouteRegistry, t as getMenu, v as definePlugin } from "../menus-CYH09a41.mjs";
|
|
6
6
|
import { t as after } from "../after-B1IIdH3Y.mjs";
|
|
7
7
|
import { createRequestMetrics, getRequestContext, runWithContext } from "../request-context.mjs";
|
|
8
|
-
import "../object-cache-
|
|
9
|
-
import { r as RevisionRepository, t as ContentRepository } from "../content-
|
|
8
|
+
import "../object-cache-CHbHv83-.mjs";
|
|
9
|
+
import { r as RevisionRepository, t as ContentRepository } from "../content-ncUWWjna.mjs";
|
|
10
10
|
import "../base64-CmWvODNW.mjs";
|
|
11
|
-
import "../types-
|
|
12
|
-
import { t as MediaRepository } from "../media-
|
|
13
|
-
import "../user-
|
|
14
|
-
import "../taxonomy-
|
|
15
|
-
import "../comment-
|
|
11
|
+
import "../types-CZgK3EMW.mjs";
|
|
12
|
+
import { t as MediaRepository } from "../media-C5t_eCnk.mjs";
|
|
13
|
+
import "../user-DkG2jKCp.mjs";
|
|
14
|
+
import "../taxonomy-BU0LjdVb.mjs";
|
|
15
|
+
import "../comment-D9BLDpZI.mjs";
|
|
16
16
|
import { t as OptionsRepository } from "../options-DTTML-Tx.mjs";
|
|
17
|
-
import "../context-
|
|
18
|
-
import "../menus-
|
|
19
|
-
import "../redirect-
|
|
17
|
+
import "../context-C_g-iJVA.mjs";
|
|
18
|
+
import "../menus-CBb6UrMU.mjs";
|
|
19
|
+
import "../redirect-_M0trWoo.mjs";
|
|
20
20
|
import { i as setRequestCacheEntry, r as requestCached } from "../request-cache-KCNHp_RJ.mjs";
|
|
21
21
|
import "../byline-registry-BOjqDOim.mjs";
|
|
22
22
|
import { n as initWithLock, t as createInitLock } from "../init-lock-6b309ZrF.mjs";
|
|
23
|
-
import "../field-defs-cache-
|
|
24
|
-
import "../byline-
|
|
23
|
+
import "../field-defs-cache-ljXzJCfc.mjs";
|
|
24
|
+
import "../byline-LL8lyqdb.mjs";
|
|
25
25
|
import { n as normalizeMediaValue } from "../normalize-CeglrBT9.mjs";
|
|
26
26
|
import "../enrich-BQ0mxJRs.mjs";
|
|
27
|
-
import "../seo-
|
|
27
|
+
import "../seo-DKeXHkzE.mjs";
|
|
28
28
|
import { n as isMissingTableError } from "../db-errors-CK46D-ly.mjs";
|
|
29
|
-
import { $ as handleContentGet, B as handleMediaUpdate, G as handleContentAuthors, H as handleRevisionList, I as handleMediaCreate, J as handleContentCountTrashed, K as handleContentCompare, L as handleMediaDelete, Q as handleContentDuplicate, R as handleMediaGet, S as PluginStateRepository, U as handleRevisionRestore, V as handleRevisionGet, X as handleContentDelete, Y as handleContentCreate, Z as handleContentDiscardDraft, _ as loadBundleFromR2, at as handleContentRestore, ct as handleContentUnpublish, dt as validateRev, et as handleContentGetIncludingTrashed, it as handleContentPublish, lt as handleContentUnschedule, nt as handleContentListTrashed, ot as handleContentSchedule, q as handleContentCountScheduled, rt as handleContentPermanentDelete, s as normalizeRegistryConfig, st as handleContentTranslations, tt as handleContentList, ut as handleContentUpdate, z as handleMediaList } from "../api-
|
|
30
|
-
import "../dashboard-
|
|
29
|
+
import { $ as handleContentGet, B as handleMediaUpdate, G as handleContentAuthors, H as handleRevisionList, I as handleMediaCreate, J as handleContentCountTrashed, K as handleContentCompare, L as handleMediaDelete, Q as handleContentDuplicate, R as handleMediaGet, S as PluginStateRepository, U as handleRevisionRestore, V as handleRevisionGet, X as handleContentDelete, Y as handleContentCreate, Z as handleContentDiscardDraft, _ as loadBundleFromR2, at as handleContentRestore, ct as handleContentUnpublish, dt as validateRev, et as handleContentGetIncludingTrashed, it as handleContentPublish, lt as handleContentUnschedule, nt as handleContentListTrashed, ot as handleContentSchedule, q as handleContentCountScheduled, rt as handleContentPermanentDelete, s as normalizeRegistryConfig, st as handleContentTranslations, tt as handleContentList, ut as handleContentUpdate, z as handleMediaList } from "../api-BMfveMoB.mjs";
|
|
30
|
+
import "../dashboard-CotyqQrW.mjs";
|
|
31
31
|
import { n as hashString } from "../hash-DrvzIXcz.mjs";
|
|
32
|
-
import { t as FTSManager } from "../fts-manager-
|
|
33
|
-
import { n as SchemaRegistry } from "../registry-
|
|
32
|
+
import { t as FTSManager } from "../fts-manager-BbCCbEKA.mjs";
|
|
33
|
+
import { n as SchemaRegistry } from "../registry-g8yYt4cC.mjs";
|
|
34
34
|
import { createRecorder, flushRecorder, isInstrumentationEnabled, kyselyLogOption } from "../database/instrumentation.mjs";
|
|
35
|
-
import { a as getDb } from "../loader-
|
|
36
|
-
import "../schema-
|
|
37
|
-
import "../zod-generator-
|
|
35
|
+
import { a as getDb } from "../loader-BA_zhkS_.mjs";
|
|
36
|
+
import "../schema-DoLd3j2e.mjs";
|
|
37
|
+
import "../zod-generator-gFsRuNNy.mjs";
|
|
38
38
|
import "../seo-BkhuuaaE.mjs";
|
|
39
|
-
import "../sections-
|
|
39
|
+
import "../sections-5J2YJPqJ.mjs";
|
|
40
40
|
import { r as singleFlightCached, t as createSingleFlightCache } from "../single-flight-cache-Cdfkic3t.mjs";
|
|
41
|
-
import { i as getSiteSettings, o as invalidateSiteSettingsCache } from "../settings-
|
|
42
|
-
import "../settings-
|
|
41
|
+
import { i as getSiteSettings, o as invalidateSiteSettingsCache } from "../settings-DJeki-97.mjs";
|
|
42
|
+
import "../settings-BMNr9Dmi.mjs";
|
|
43
43
|
import "../resolve-C7I0qiR0.mjs";
|
|
44
|
-
import { a as getTaxonomyDefs, o as getTaxonomyTerms } from "../taxonomies-
|
|
45
|
-
import "../taxonomies-
|
|
46
|
-
import { r as normalizeManifestRoute } from "../manifest-schema-
|
|
44
|
+
import { a as getTaxonomyDefs, o as getTaxonomyTerms } from "../taxonomies-D13i2ctt.mjs";
|
|
45
|
+
import "../taxonomies-CM_fUqLU.mjs";
|
|
46
|
+
import { r as normalizeManifestRoute } from "../manifest-schema-kPGX7VS-.mjs";
|
|
47
47
|
import "../types-BvbeGEtr.mjs";
|
|
48
48
|
import "../ssrf-BRKb343l.mjs";
|
|
49
|
-
import "../error-
|
|
50
|
-
import "../parse-
|
|
49
|
+
import "../error-rVGiqWDt.mjs";
|
|
50
|
+
import "../parse-BwAdS7FZ.mjs";
|
|
51
51
|
import "../redirects-Dcbuisoj.mjs";
|
|
52
52
|
import "../byline-fields-eyJMblSr.mjs";
|
|
53
53
|
import "../status-vUK0SA17.mjs";
|
|
54
|
-
import { a as invalidateUrlPatternCache } from "../query-
|
|
54
|
+
import { a as invalidateUrlPatternCache } from "../query-BpQb-blG.mjs";
|
|
55
55
|
import "../import-Bb1T9WJS.mjs";
|
|
56
56
|
import { t as getTrustedProxyHeaders } from "../trusted-proxy-DZY5WCn2.mjs";
|
|
57
57
|
import { n as sanitizeHeadersForSandbox, t as extractRequestMeta } from "../request-meta-CmS1tDFf.mjs";
|
|
@@ -61,14 +61,14 @@ import { r as devConsoleEmailDeliver, t as DEV_CONSOLE_EMAIL_PLUGIN_ID } from ".
|
|
|
61
61
|
import "../utils-B7A57fm9.mjs";
|
|
62
62
|
import "../tokens-LeuXF9gG.mjs";
|
|
63
63
|
import "../preview-DKGCt2_p.mjs";
|
|
64
|
-
import "../comment-reaction-
|
|
65
|
-
import "../bylines-
|
|
66
|
-
import { n as getWidgetAreas } from "../widgets-
|
|
67
|
-
import "../apply
|
|
68
|
-
import "../load-
|
|
69
|
-
import "../search-
|
|
64
|
+
import "../comment-reaction-Drl9SkNu.mjs";
|
|
65
|
+
import "../bylines-DE47vP8d.mjs";
|
|
66
|
+
import { n as getWidgetAreas } from "../widgets-BfOZ-ajY.mjs";
|
|
67
|
+
import "../apply--IVNSdXn.mjs";
|
|
68
|
+
import "../load-DMjXghbZ.mjs";
|
|
69
|
+
import "../search-BR0ZeZmh.mjs";
|
|
70
70
|
import "../index.mjs";
|
|
71
|
-
import { n as VERSION, t as COMMIT } from "../version-
|
|
71
|
+
import { n as VERSION, t as COMMIT } from "../version-BoNBItP_.mjs";
|
|
72
72
|
import { t as getAuthMode } from "../mode-BB0F8xTC.mjs";
|
|
73
73
|
import { t as cleanupExpiredChallenges } from "../challenge-store-LhiqMccz.mjs";
|
|
74
74
|
import { a as validateEncryptionKeyAtStartup } from "../secrets-BSf9pRRY.mjs";
|
|
@@ -925,9 +925,9 @@ var EmDashRuntime = class EmDashRuntime {
|
|
|
925
925
|
const seedHolder = getSeedHolder();
|
|
926
926
|
try {
|
|
927
927
|
await initWithLock(seedHolder.lock, () => seedHolder.done.has(seedKey) ? true : void 0, async () => {
|
|
928
|
-
const { applySeed } = await import("../apply
|
|
929
|
-
const { loadSeed } = await import("../load-
|
|
930
|
-
const { validateSeed } = await import("../validate-
|
|
928
|
+
const { applySeed } = await import("../apply--IVNSdXn.mjs").then((n) => n.n);
|
|
929
|
+
const { loadSeed } = await import("../load-DMjXghbZ.mjs").then((n) => n.r);
|
|
930
|
+
const { validateSeed } = await import("../validate-CuJ1Ps9j.mjs").then((n) => n.n);
|
|
931
931
|
const seed = await loadSeed();
|
|
932
932
|
if (validateSeed(seed).valid) {
|
|
933
933
|
await applySeed(db, seed, { onConflict: "skip" });
|
|
@@ -1663,7 +1663,7 @@ var EmDashRuntime = class EmDashRuntime {
|
|
|
1663
1663
|
if (this.hooks.hasHooks("content:beforeSave")) processedData = (await this.hooks.runContentBeforeSave(body.data, collection, true)).content;
|
|
1664
1664
|
processedData = await this.runSandboxedBeforeSave(processedData, collection, true);
|
|
1665
1665
|
processedData = await this.normalizeMediaFields(collection, processedData);
|
|
1666
|
-
const { validateContentData } = await import("../validation-
|
|
1666
|
+
const { validateContentData } = await import("../validation-CwUfTdGF.mjs");
|
|
1667
1667
|
const validation = await validateContentData(this.db, collection, processedData, { partial: false });
|
|
1668
1668
|
if (!validation.ok) return {
|
|
1669
1669
|
success: false,
|
|
@@ -1679,7 +1679,7 @@ var EmDashRuntime = class EmDashRuntime {
|
|
|
1679
1679
|
return result;
|
|
1680
1680
|
}
|
|
1681
1681
|
async handleContentUpdate(collection, id, body) {
|
|
1682
|
-
const { ContentRepository } = await import("../content-
|
|
1682
|
+
const { ContentRepository } = await import("../content-ncUWWjna.mjs").then((n) => n.n);
|
|
1683
1683
|
const repo = new ContentRepository(this.db);
|
|
1684
1684
|
const resolvedItem = await repo.findByIdOrSlug(collection, id, body.locale);
|
|
1685
1685
|
const resolvedId = resolvedItem?.id ?? id;
|
|
@@ -1706,7 +1706,7 @@ var EmDashRuntime = class EmDashRuntime {
|
|
|
1706
1706
|
if (this.hooks.hasHooks("content:beforeSave")) processedData = (await this.hooks.runContentBeforeSave(bodyWithoutRev.data, collection, false)).content;
|
|
1707
1707
|
processedData = await this.runSandboxedBeforeSave(processedData, collection, false);
|
|
1708
1708
|
processedData = await this.normalizeMediaFields(collection, processedData);
|
|
1709
|
-
const { validateContentData } = await import("../validation-
|
|
1709
|
+
const { validateContentData } = await import("../validation-CwUfTdGF.mjs");
|
|
1710
1710
|
const validation = await validateContentData(this.db, collection, processedData, { partial: true });
|
|
1711
1711
|
if (!validation.ok) return {
|
|
1712
1712
|
success: false,
|
|
@@ -1812,10 +1812,14 @@ var EmDashRuntime = class EmDashRuntime {
|
|
|
1812
1812
|
return result;
|
|
1813
1813
|
}
|
|
1814
1814
|
async handleContentSchedule(collection, id, scheduledAt) {
|
|
1815
|
-
|
|
1815
|
+
const result = await handleContentSchedule(this.db, collection, id, scheduledAt);
|
|
1816
|
+
if (result.success && result.data) this.runAfterScheduleHooks(contentItemToRecord(result.data.item), collection);
|
|
1817
|
+
return result;
|
|
1816
1818
|
}
|
|
1817
1819
|
async handleContentUnschedule(collection, id) {
|
|
1818
|
-
|
|
1820
|
+
const result = await handleContentUnschedule(this.db, collection, id);
|
|
1821
|
+
if (result.success && result.data) this.runAfterUnscheduleHooks(contentItemToRecord(result.data.item), collection);
|
|
1822
|
+
return result;
|
|
1819
1823
|
}
|
|
1820
1824
|
async handleContentCountScheduled(collection) {
|
|
1821
1825
|
return handleContentCountScheduled(this.db, collection);
|
|
@@ -2093,12 +2097,29 @@ var EmDashRuntime = class EmDashRuntime {
|
|
|
2093
2097
|
}).catch((err) => console.error(`EmDash: Sandboxed plugin ${pluginId} afterDelete error:`, err));
|
|
2094
2098
|
}
|
|
2095
2099
|
}
|
|
2096
|
-
|
|
2100
|
+
runDeferredContentHook(name, content, collection) {
|
|
2101
|
+
const label = name.slice(8);
|
|
2097
2102
|
after(async () => {
|
|
2098
|
-
if (this.hooks.hasHooks(
|
|
2099
|
-
|
|
2103
|
+
if (this.hooks.hasHooks(name)) try {
|
|
2104
|
+
switch (name) {
|
|
2105
|
+
case "content:afterPublish":
|
|
2106
|
+
await this.hooks.runContentAfterPublish(content, collection);
|
|
2107
|
+
break;
|
|
2108
|
+
case "content:afterUnpublish":
|
|
2109
|
+
await this.hooks.runContentAfterUnpublish(content, collection);
|
|
2110
|
+
break;
|
|
2111
|
+
case "content:afterRestore":
|
|
2112
|
+
await this.hooks.runContentAfterRestore(content, collection);
|
|
2113
|
+
break;
|
|
2114
|
+
case "content:afterSchedule":
|
|
2115
|
+
await this.hooks.runContentAfterSchedule(content, collection);
|
|
2116
|
+
break;
|
|
2117
|
+
case "content:afterUnschedule":
|
|
2118
|
+
await this.hooks.runContentAfterUnschedule(content, collection);
|
|
2119
|
+
break;
|
|
2120
|
+
}
|
|
2100
2121
|
} catch (err) {
|
|
2101
|
-
console.error(
|
|
2122
|
+
console.error(`EmDash ${label} hook error:`, err);
|
|
2102
2123
|
}
|
|
2103
2124
|
const tasks = [];
|
|
2104
2125
|
for (const [pluginKey, plugin] of this.sandboxedPlugins) {
|
|
@@ -2106,53 +2127,32 @@ var EmDashRuntime = class EmDashRuntime {
|
|
|
2106
2127
|
if (!pluginId || !this.isPluginEnabled(pluginId)) continue;
|
|
2107
2128
|
tasks.push((async () => {
|
|
2108
2129
|
try {
|
|
2109
|
-
await plugin.invokeHook(
|
|
2130
|
+
await plugin.invokeHook(name, {
|
|
2110
2131
|
content,
|
|
2111
2132
|
collection
|
|
2112
2133
|
});
|
|
2113
2134
|
} catch (err) {
|
|
2114
|
-
console.error(`EmDash: Sandboxed plugin ${pluginId}
|
|
2135
|
+
console.error(`EmDash: Sandboxed plugin ${pluginId} ${label} error:`, err);
|
|
2115
2136
|
}
|
|
2116
2137
|
})());
|
|
2117
2138
|
}
|
|
2118
2139
|
await Promise.allSettled(tasks);
|
|
2119
2140
|
});
|
|
2120
2141
|
}
|
|
2142
|
+
runAfterPublishHooks(content, collection) {
|
|
2143
|
+
this.runDeferredContentHook("content:afterPublish", content, collection);
|
|
2144
|
+
}
|
|
2121
2145
|
runAfterUnpublishHooks(content, collection) {
|
|
2122
|
-
|
|
2123
|
-
for (const [pluginKey, plugin] of this.sandboxedPlugins) {
|
|
2124
|
-
const [pluginId] = pluginKey.split(":");
|
|
2125
|
-
if (!pluginId || !this.isPluginEnabled(pluginId)) continue;
|
|
2126
|
-
plugin.invokeHook("content:afterUnpublish", {
|
|
2127
|
-
content,
|
|
2128
|
-
collection
|
|
2129
|
-
}).catch((err) => console.error(`EmDash: Sandboxed plugin ${pluginId} afterUnpublish error:`, err));
|
|
2130
|
-
}
|
|
2146
|
+
this.runDeferredContentHook("content:afterUnpublish", content, collection);
|
|
2131
2147
|
}
|
|
2132
2148
|
runAfterRestoreHooks(content, collection) {
|
|
2133
|
-
|
|
2134
|
-
|
|
2135
|
-
|
|
2136
|
-
|
|
2137
|
-
|
|
2138
|
-
|
|
2139
|
-
|
|
2140
|
-
for (const [pluginKey, plugin] of this.sandboxedPlugins) {
|
|
2141
|
-
const [pluginId] = pluginKey.split(":");
|
|
2142
|
-
if (!pluginId || !this.isPluginEnabled(pluginId)) continue;
|
|
2143
|
-
tasks.push((async () => {
|
|
2144
|
-
try {
|
|
2145
|
-
await plugin.invokeHook("content:afterRestore", {
|
|
2146
|
-
content,
|
|
2147
|
-
collection
|
|
2148
|
-
});
|
|
2149
|
-
} catch (err) {
|
|
2150
|
-
console.error(`EmDash: Sandboxed plugin ${pluginId} afterRestore error:`, err);
|
|
2151
|
-
}
|
|
2152
|
-
})());
|
|
2153
|
-
}
|
|
2154
|
-
await Promise.allSettled(tasks);
|
|
2155
|
-
});
|
|
2149
|
+
this.runDeferredContentHook("content:afterRestore", content, collection);
|
|
2150
|
+
}
|
|
2151
|
+
runAfterScheduleHooks(content, collection) {
|
|
2152
|
+
this.runDeferredContentHook("content:afterSchedule", content, collection);
|
|
2153
|
+
}
|
|
2154
|
+
runAfterUnscheduleHooks(content, collection) {
|
|
2155
|
+
this.runDeferredContentHook("content:afterUnschedule", content, collection);
|
|
2156
2156
|
}
|
|
2157
2157
|
async handleSandboxedRoute(plugin, path, request) {
|
|
2158
2158
|
const routeName = path.replace(LEADING_SLASH_PATTERN, "");
|
|
@@ -2818,7 +2818,7 @@ const onRequest = defineMiddleware(async (context, next) => {
|
|
|
2818
2818
|
if (!isSetupVerified() && !context.isPrerendered) {
|
|
2819
2819
|
const t0 = performance.now();
|
|
2820
2820
|
try {
|
|
2821
|
-
const { getDb } = await import("../loader-
|
|
2821
|
+
const { getDb } = await import("../loader-BA_zhkS_.mjs").then((n) => n.o);
|
|
2822
2822
|
await (await getDb()).selectFrom("_emdash_migrations").selectAll().limit(1).execute();
|
|
2823
2823
|
markSetupVerified();
|
|
2824
2824
|
} catch (error) {
|