emdash 0.14.0 → 0.16.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/{adapters-9DybjTO6.d.mts → adapters-C4yd_UJR.d.mts} +1 -1
- package/dist/{adapters-9DybjTO6.d.mts.map → adapters-C4yd_UJR.d.mts.map} +1 -1
- package/dist/{allowed-origins-CDdG-4Gd.mjs → allowed-origins-D0fFk9a6.mjs} +2 -2
- package/dist/{allowed-origins-CDdG-4Gd.mjs.map → allowed-origins-D0fFk9a6.mjs.map} +1 -1
- package/dist/api/route-utils.d.mts +3 -3
- package/dist/api/route-utils.mjs +15 -15
- package/dist/api/schemas/index.d.mts +2 -2
- package/dist/api/schemas/index.mjs +3 -3
- package/dist/{api-BMLZuwM4.mjs → api-BNKqxyFX.mjs} +560 -56
- package/dist/api-BNKqxyFX.mjs.map +1 -0
- package/dist/{api-tokens-eYymBhIT.mjs → api-tokens-ucpcNXDt.mjs} +2 -2
- package/dist/{api-tokens-eYymBhIT.mjs.map → api-tokens-ucpcNXDt.mjs.map} +1 -1
- package/dist/{apply-v4DBgjPw.mjs → apply-BOPaD-s9.mjs} +17 -17
- package/dist/{apply-v4DBgjPw.mjs.map → apply-BOPaD-s9.mjs.map} +1 -1
- package/dist/astro/index.d.mts +10 -10
- package/dist/astro/index.d.mts.map +1 -1
- package/dist/astro/index.mjs +53 -5
- package/dist/astro/index.mjs.map +1 -1
- package/dist/astro/middleware/auth.d.mts +9 -9
- package/dist/astro/middleware/auth.mjs +6 -6
- package/dist/astro/middleware/auth.mjs.map +1 -1
- package/dist/astro/middleware/redirect.mjs +4 -4
- package/dist/astro/middleware/request-context.mjs +3 -3
- package/dist/astro/middleware/request-context.mjs.map +1 -1
- package/dist/astro/middleware/setup.mjs +1 -1
- package/dist/astro/middleware.d.mts.map +1 -1
- package/dist/astro/middleware.mjs +377 -75
- package/dist/astro/middleware.mjs.map +1 -1
- package/dist/astro/routes/api/admin/allowed-domains/_domain_.mjs +5 -5
- package/dist/astro/routes/api/admin/allowed-domains/index.mjs +5 -5
- package/dist/astro/routes/api/admin/api-tokens/_id_.mjs +4 -4
- package/dist/astro/routes/api/admin/api-tokens/index.mjs +5 -5
- package/dist/astro/routes/api/admin/bylines/_id_/index.d.mts.map +1 -1
- package/dist/astro/routes/api/admin/bylines/_id_/index.mjs +14 -17
- package/dist/astro/routes/api/admin/bylines/_id_/index.mjs.map +1 -1
- package/dist/astro/routes/api/admin/bylines/_id_/translations.d.mts +9 -0
- package/dist/astro/routes/api/admin/bylines/_id_/translations.d.mts.map +1 -0
- package/dist/astro/routes/api/admin/bylines/_id_/translations.mjs +70 -0
- package/dist/astro/routes/api/admin/bylines/_id_/translations.mjs.map +1 -0
- package/dist/astro/routes/api/admin/bylines/index.d.mts.map +1 -1
- package/dist/astro/routes/api/admin/bylines/index.mjs +25 -16
- package/dist/astro/routes/api/admin/bylines/index.mjs.map +1 -1
- package/dist/astro/routes/api/admin/comments/_id_/status.mjs +10 -10
- package/dist/astro/routes/api/admin/comments/_id_.mjs +5 -5
- package/dist/astro/routes/api/admin/comments/bulk.mjs +8 -8
- package/dist/astro/routes/api/admin/comments/counts.mjs +5 -5
- package/dist/astro/routes/api/admin/comments/index.mjs +8 -8
- 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 +4 -4
- package/dist/astro/routes/api/admin/oauth-clients/index.mjs +4 -4
- package/dist/astro/routes/api/admin/plugins/_id_/disable.mjs +33 -32
- package/dist/astro/routes/api/admin/plugins/_id_/disable.mjs.map +1 -1
- package/dist/astro/routes/api/admin/plugins/_id_/enable.mjs +33 -32
- package/dist/astro/routes/api/admin/plugins/_id_/enable.mjs.map +1 -1
- package/dist/astro/routes/api/admin/plugins/_id_/index.mjs +32 -31
- package/dist/astro/routes/api/admin/plugins/_id_/index.mjs.map +1 -1
- package/dist/astro/routes/api/admin/plugins/_id_/uninstall.mjs +32 -31
- package/dist/astro/routes/api/admin/plugins/_id_/uninstall.mjs.map +1 -1
- package/dist/astro/routes/api/admin/plugins/_id_/update.mjs +34 -32
- package/dist/astro/routes/api/admin/plugins/_id_/update.mjs.map +1 -1
- package/dist/astro/routes/api/admin/plugins/index.mjs +32 -31
- package/dist/astro/routes/api/admin/plugins/index.mjs.map +1 -1
- package/dist/astro/routes/api/admin/plugins/marketplace/_id_/icon.mjs +3 -3
- package/dist/astro/routes/api/admin/plugins/marketplace/_id_/index.mjs +32 -31
- package/dist/astro/routes/api/admin/plugins/marketplace/_id_/index.mjs.map +1 -1
- package/dist/astro/routes/api/admin/plugins/marketplace/_id_/install.mjs +34 -32
- package/dist/astro/routes/api/admin/plugins/marketplace/_id_/install.mjs.map +1 -1
- package/dist/astro/routes/api/admin/plugins/marketplace/index.mjs +32 -31
- package/dist/astro/routes/api/admin/plugins/marketplace/index.mjs.map +1 -1
- package/dist/astro/routes/api/admin/plugins/registry/_id_/uninstall.d.mts +8 -0
- package/dist/astro/routes/api/admin/plugins/registry/_id_/uninstall.d.mts.map +1 -0
- package/dist/astro/routes/api/admin/plugins/registry/_id_/uninstall.mjs +59 -0
- package/dist/astro/routes/api/admin/plugins/registry/_id_/uninstall.mjs.map +1 -0
- package/dist/astro/routes/api/admin/plugins/registry/_id_/update.d.mts +8 -0
- package/dist/astro/routes/api/admin/plugins/registry/_id_/update.d.mts.map +1 -0
- package/dist/astro/routes/api/admin/plugins/registry/_id_/update.mjs +85 -0
- package/dist/astro/routes/api/admin/plugins/registry/_id_/update.mjs.map +1 -0
- package/dist/astro/routes/api/admin/plugins/registry/artifact.d.mts +8 -0
- package/dist/astro/routes/api/admin/plugins/registry/artifact.d.mts.map +1 -0
- package/dist/astro/routes/api/admin/plugins/registry/artifact.mjs +301 -0
- package/dist/astro/routes/api/admin/plugins/registry/artifact.mjs.map +1 -0
- package/dist/astro/routes/api/admin/plugins/registry/install.d.mts.map +1 -1
- package/dist/astro/routes/api/admin/plugins/registry/install.mjs +51 -32
- package/dist/astro/routes/api/admin/plugins/registry/install.mjs.map +1 -1
- package/dist/astro/routes/api/admin/plugins/updates.d.mts.map +1 -1
- package/dist/astro/routes/api/admin/plugins/updates.mjs +45 -32
- package/dist/astro/routes/api/admin/plugins/updates.mjs.map +1 -1
- package/dist/astro/routes/api/admin/themes/marketplace/_id_/index.mjs +32 -31
- package/dist/astro/routes/api/admin/themes/marketplace/_id_/index.mjs.map +1 -1
- package/dist/astro/routes/api/admin/themes/marketplace/_id_/thumbnail.mjs +3 -3
- package/dist/astro/routes/api/admin/themes/marketplace/index.mjs +32 -31
- package/dist/astro/routes/api/admin/themes/marketplace/index.mjs.map +1 -1
- 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 +5 -5
- package/dist/astro/routes/api/admin/users/_id_/send-recovery.mjs +3 -3
- package/dist/astro/routes/api/admin/users/index.mjs +5 -5
- package/dist/astro/routes/api/auth/dev-bypass.mjs +5 -5
- package/dist/astro/routes/api/auth/invite/accept.mjs +2 -2
- package/dist/astro/routes/api/auth/invite/complete.mjs +9 -9
- package/dist/astro/routes/api/auth/invite/index.mjs +6 -6
- package/dist/astro/routes/api/auth/invite/register-options.mjs +8 -8
- package/dist/astro/routes/api/auth/logout.mjs +3 -3
- package/dist/astro/routes/api/auth/magic-link/send.mjs +8 -8
- package/dist/astro/routes/api/auth/magic-link/verify.mjs +3 -3
- package/dist/astro/routes/api/auth/me.mjs +5 -5
- package/dist/astro/routes/api/auth/mode.mjs +1 -1
- package/dist/astro/routes/api/auth/oauth/_provider_/callback.mjs +3 -3
- package/dist/astro/routes/api/auth/oauth/_provider_/callback.mjs.map +1 -1
- package/dist/astro/routes/api/auth/oauth/_provider_.mjs +2 -2
- package/dist/astro/routes/api/auth/oauth/_provider_.mjs.map +1 -1
- package/dist/astro/routes/api/auth/passkey/_id_.mjs +5 -5
- package/dist/astro/routes/api/auth/passkey/index.mjs +2 -2
- package/dist/astro/routes/api/auth/passkey/options.mjs +10 -10
- package/dist/astro/routes/api/auth/passkey/register/options.mjs +8 -8
- package/dist/astro/routes/api/auth/passkey/register/verify.mjs +9 -9
- package/dist/astro/routes/api/auth/passkey/verify.mjs +9 -9
- package/dist/astro/routes/api/auth/signup/complete.mjs +9 -9
- package/dist/astro/routes/api/auth/signup/request.mjs +8 -8
- package/dist/astro/routes/api/auth/signup/verify.mjs +2 -2
- package/dist/astro/routes/api/comments/_collection_/_contentId_/index.mjs +11 -11
- 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_/discard-draft.mjs.map +1 -1
- package/dist/astro/routes/api/content/_collection_/_id_/duplicate.mjs +3 -3
- package/dist/astro/routes/api/content/_collection_/_id_/duplicate.mjs.map +1 -1
- package/dist/astro/routes/api/content/_collection_/_id_/permanent.mjs +3 -3
- package/dist/astro/routes/api/content/_collection_/_id_/preview-url.mjs +9 -9
- package/dist/astro/routes/api/content/_collection_/_id_/publish.mjs +6 -6
- package/dist/astro/routes/api/content/_collection_/_id_/publish.mjs.map +1 -1
- package/dist/astro/routes/api/content/_collection_/_id_/restore.mjs +3 -3
- package/dist/astro/routes/api/content/_collection_/_id_/restore.mjs.map +1 -1
- package/dist/astro/routes/api/content/_collection_/_id_/revisions.mjs +3 -3
- package/dist/astro/routes/api/content/_collection_/_id_/schedule.mjs +6 -6
- package/dist/astro/routes/api/content/_collection_/_id_/schedule.mjs.map +1 -1
- package/dist/astro/routes/api/content/_collection_/_id_/terms/_taxonomy_.mjs +10 -9
- package/dist/astro/routes/api/content/_collection_/_id_/terms/_taxonomy_.mjs.map +1 -1
- package/dist/astro/routes/api/content/_collection_/_id_/translations.mjs +3 -3
- package/dist/astro/routes/api/content/_collection_/_id_/translations.mjs.map +1 -1
- package/dist/astro/routes/api/content/_collection_/_id_/unpublish.mjs +3 -3
- package/dist/astro/routes/api/content/_collection_/_id_/unpublish.mjs.map +1 -1
- package/dist/astro/routes/api/content/_collection_/_id_.mjs +6 -6
- package/dist/astro/routes/api/content/_collection_/_id_.mjs.map +1 -1
- package/dist/astro/routes/api/content/_collection_/index.mjs +6 -6
- package/dist/astro/routes/api/content/_collection_/trash.mjs +6 -6
- package/dist/astro/routes/api/dashboard.mjs +7 -7
- package/dist/astro/routes/api/dev/emails.mjs +3 -3
- package/dist/astro/routes/api/import/probe.d.mts +3 -3
- package/dist/astro/routes/api/import/probe.mjs +10 -10
- package/dist/astro/routes/api/import/wordpress/analyze.mjs +3 -3
- package/dist/astro/routes/api/import/wordpress/execute.d.mts +9 -9
- package/dist/astro/routes/api/import/wordpress/execute.mjs +9 -8
- package/dist/astro/routes/api/import/wordpress/execute.mjs.map +1 -1
- package/dist/astro/routes/api/import/wordpress/media.mjs +8 -8
- package/dist/astro/routes/api/import/wordpress/prepare.mjs +8 -8
- package/dist/astro/routes/api/import/wordpress/prepare.mjs.map +1 -1
- package/dist/astro/routes/api/import/wordpress/rewrite-url-helpers.d.mts +11 -1
- package/dist/astro/routes/api/import/wordpress/rewrite-url-helpers.d.mts.map +1 -1
- package/dist/astro/routes/api/import/wordpress/rewrite-url-helpers.mjs +17 -1
- package/dist/astro/routes/api/import/wordpress/rewrite-url-helpers.mjs.map +1 -1
- package/dist/astro/routes/api/import/wordpress/rewrite-urls.d.mts.map +1 -1
- package/dist/astro/routes/api/import/wordpress/rewrite-urls.mjs +9 -9
- package/dist/astro/routes/api/import/wordpress/rewrite-urls.mjs.map +1 -1
- package/dist/astro/routes/api/import/wordpress-plugin/analyze.d.mts +1 -1
- package/dist/astro/routes/api/import/wordpress-plugin/analyze.mjs +10 -10
- package/dist/astro/routes/api/import/wordpress-plugin/execute.d.mts +1 -1
- package/dist/astro/routes/api/import/wordpress-plugin/execute.mjs +11 -11
- package/dist/astro/routes/api/import/wordpress-plugin/execute.mjs.map +1 -1
- package/dist/astro/routes/api/manifest.mjs +4 -4
- package/dist/astro/routes/api/mcp.mjs +29 -29
- package/dist/astro/routes/api/mcp.mjs.map +1 -1
- package/dist/astro/routes/api/media/_id_/confirm.mjs +6 -6
- package/dist/astro/routes/api/media/_id_.mjs +6 -6
- 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 +7 -7
- package/dist/astro/routes/api/media/upload-url.mjs.map +1 -1
- package/dist/astro/routes/api/media.mjs +8 -8
- package/dist/astro/routes/api/menus/_name_/items/_id_.mjs +7 -7
- package/dist/astro/routes/api/menus/_name_/items.mjs +7 -7
- package/dist/astro/routes/api/menus/_name_/reorder.mjs +7 -7
- package/dist/astro/routes/api/menus/_name_/translations.mjs +7 -7
- package/dist/astro/routes/api/menus/_name_.mjs +7 -7
- package/dist/astro/routes/api/menus/index.mjs +7 -7
- package/dist/astro/routes/api/oauth/authorize.mjs +6 -6
- package/dist/astro/routes/api/oauth/device/authorize.mjs +6 -6
- package/dist/astro/routes/api/oauth/device/code.mjs +9 -9
- package/dist/astro/routes/api/oauth/device/token.mjs +8 -8
- package/dist/astro/routes/api/oauth/register.mjs +3 -3
- package/dist/astro/routes/api/oauth/token/refresh.mjs +6 -6
- package/dist/astro/routes/api/oauth/token/revoke.mjs +6 -6
- package/dist/astro/routes/api/oauth/token.mjs +6 -6
- package/dist/astro/routes/api/openapi.json.mjs +3 -3
- package/dist/astro/routes/api/openapi.json.mjs.map +1 -1
- package/dist/astro/routes/api/plugins/_pluginId_/_...path_.mjs +4 -4
- package/dist/astro/routes/api/redirects/404s/index.mjs +8 -8
- package/dist/astro/routes/api/redirects/404s/index.mjs.map +1 -1
- package/dist/astro/routes/api/redirects/404s/summary.mjs +8 -8
- package/dist/astro/routes/api/redirects/404s/summary.mjs.map +1 -1
- package/dist/astro/routes/api/redirects/_id_.mjs +9 -9
- package/dist/astro/routes/api/redirects/_id_.mjs.map +1 -1
- package/dist/astro/routes/api/redirects/index.mjs +9 -9
- package/dist/astro/routes/api/redirects/index.mjs.map +1 -1
- 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 +32 -31
- package/dist/astro/routes/api/schema/collections/_slug_/fields/_fieldSlug_.mjs.map +1 -1
- package/dist/astro/routes/api/schema/collections/_slug_/fields/index.mjs +32 -31
- package/dist/astro/routes/api/schema/collections/_slug_/fields/index.mjs.map +1 -1
- package/dist/astro/routes/api/schema/collections/_slug_/fields/reorder.mjs +32 -31
- package/dist/astro/routes/api/schema/collections/_slug_/fields/reorder.mjs.map +1 -1
- package/dist/astro/routes/api/schema/collections/_slug_/index.mjs +32 -31
- package/dist/astro/routes/api/schema/collections/_slug_/index.mjs.map +1 -1
- package/dist/astro/routes/api/schema/collections/index.mjs +32 -31
- package/dist/astro/routes/api/schema/collections/index.mjs.map +1 -1
- package/dist/astro/routes/api/schema/index.mjs +6 -6
- package/dist/astro/routes/api/schema/index.mjs.map +1 -1
- package/dist/astro/routes/api/schema/orphans/_slug_.mjs +32 -31
- package/dist/astro/routes/api/schema/orphans/_slug_.mjs.map +1 -1
- package/dist/astro/routes/api/schema/orphans/index.mjs +32 -31
- package/dist/astro/routes/api/schema/orphans/index.mjs.map +1 -1
- package/dist/astro/routes/api/search/enable.mjs +9 -9
- package/dist/astro/routes/api/search/index.mjs +8 -8
- package/dist/astro/routes/api/search/rebuild.mjs +9 -9
- package/dist/astro/routes/api/search/stats.mjs +6 -6
- package/dist/astro/routes/api/search/suggest.mjs +8 -8
- package/dist/astro/routes/api/sections/_slug_.mjs +8 -8
- package/dist/astro/routes/api/sections/_slug_.mjs.map +1 -1
- package/dist/astro/routes/api/sections/index.mjs +8 -8
- package/dist/astro/routes/api/sections/index.mjs.map +1 -1
- package/dist/astro/routes/api/settings/email.mjs +4 -4
- package/dist/astro/routes/api/settings.mjs +10 -10
- package/dist/astro/routes/api/setup/admin-verify.mjs +10 -10
- package/dist/astro/routes/api/setup/admin.mjs +9 -9
- package/dist/astro/routes/api/setup/dev-bypass.mjs +22 -22
- package/dist/astro/routes/api/setup/dev-reset.mjs +2 -2
- package/dist/astro/routes/api/setup/index.mjs +22 -22
- package/dist/astro/routes/api/setup/status.mjs +4 -4
- package/dist/astro/routes/api/snapshot.mjs +6 -6
- package/dist/astro/routes/api/snapshot.mjs.map +1 -1
- package/dist/astro/routes/api/taxonomies/_name_/terms/_slug_/translations.mjs +11 -10
- package/dist/astro/routes/api/taxonomies/_name_/terms/_slug_/translations.mjs.map +1 -1
- package/dist/astro/routes/api/taxonomies/_name_/terms/_slug_.mjs +11 -10
- package/dist/astro/routes/api/taxonomies/_name_/terms/_slug_.mjs.map +1 -1
- package/dist/astro/routes/api/taxonomies/_name_/terms/index.mjs +11 -10
- package/dist/astro/routes/api/taxonomies/_name_/terms/index.mjs.map +1 -1
- package/dist/astro/routes/api/taxonomies/index.mjs +11 -10
- package/dist/astro/routes/api/taxonomies/index.mjs.map +1 -1
- package/dist/astro/routes/api/themes/preview.mjs +5 -5
- package/dist/astro/routes/api/typegen.mjs +5 -5
- package/dist/astro/routes/api/well-known/auth.mjs +1 -1
- package/dist/astro/routes/api/well-known/oauth-authorization-server.mjs +2 -2
- package/dist/astro/routes/api/well-known/oauth-protected-resource.mjs +2 -2
- package/dist/astro/routes/api/widget-areas/_name_/reorder.mjs +6 -6
- package/dist/astro/routes/api/widget-areas/_name_/widgets/_id_.mjs +8 -8
- package/dist/astro/routes/api/widget-areas/_name_/widgets.mjs +8 -8
- package/dist/astro/routes/api/widget-areas/_name_.mjs +5 -5
- package/dist/astro/routes/api/widget-areas/index.mjs +8 -8
- package/dist/astro/routes/api/widget-components.mjs +3 -3
- package/dist/astro/routes/robots.txt.mjs +5 -5
- package/dist/astro/routes/sitemap-_collection_.xml.d.mts.map +1 -1
- package/dist/astro/routes/sitemap-_collection_.xml.mjs +58 -13
- package/dist/astro/routes/sitemap-_collection_.xml.mjs.map +1 -1
- package/dist/astro/routes/sitemap.xml.mjs +6 -6
- package/dist/astro/types.d.mts +20 -12
- package/dist/astro/types.d.mts.map +1 -1
- package/dist/auth/providers/github.d.mts +1 -1
- package/dist/auth/providers/google.d.mts +1 -1
- package/dist/{authorize-BlyCH-96.mjs → authorize-Bn4S4DUT.mjs} +2 -2
- package/dist/{authorize-BlyCH-96.mjs.map → authorize-Bn4S4DUT.mjs.map} +1 -1
- package/dist/byline-BDylH_m4.mjs +404 -0
- package/dist/byline-BDylH_m4.mjs.map +1 -0
- package/dist/{bylines-BdUP8NuI.d.mts → bylines-B2_XmnSU.d.mts} +73 -28
- package/dist/bylines-B2_XmnSU.d.mts.map +1 -0
- package/dist/bylines-B7TFEvFf.mjs +118 -0
- package/dist/bylines-B7TFEvFf.mjs.map +1 -0
- package/dist/bylines-n6nykUyI.mjs +174 -0
- package/dist/bylines-n6nykUyI.mjs.map +1 -0
- package/dist/{cache-CXCpjWiL.mjs → cache-BcI1yUjR.mjs} +2 -2
- package/dist/{cache-CXCpjWiL.mjs.map → cache-BcI1yUjR.mjs.map} +1 -1
- package/dist/{challenge-store-CJ0OOHOr.mjs → challenge-store-Dng1SxKT.mjs} +1 -1
- package/dist/{challenge-store-CJ0OOHOr.mjs.map → challenge-store-Dng1SxKT.mjs.map} +1 -1
- package/dist/{chunks-DyGtu1Bv.mjs → chunks-cYG4SnIP.mjs} +2 -2
- package/dist/{chunks-DyGtu1Bv.mjs.map → chunks-cYG4SnIP.mjs.map} +1 -1
- package/dist/cli/index.mjs +68 -30
- package/dist/cli/index.mjs.map +1 -1
- package/dist/client/cf-access.d.mts +1 -1
- package/dist/client/index.d.mts +1 -1
- package/dist/client/index.mjs +1 -1
- package/dist/client/index.mjs.map +1 -1
- package/dist/{comment-Dd9MI82-.mjs → comment-C76G-9tz.mjs} +2 -2
- package/dist/{comment-Dd9MI82-.mjs.map → comment-C76G-9tz.mjs.map} +1 -1
- package/dist/{comments-koGI0FrK.mjs → comments-CCxFFGY1.mjs} +3 -3
- package/dist/{comments-koGI0FrK.mjs.map → comments-CCxFFGY1.mjs.map} +1 -1
- package/dist/{components-mZem7pbe.mjs → components-Dx3DM0gg.mjs} +1 -1
- package/dist/{components-mZem7pbe.mjs.map → components-Dx3DM0gg.mjs.map} +1 -1
- package/dist/config-CVssduLe.mjs.map +1 -1
- package/dist/{content-D6YG26WG.mjs → content-8voQNTXX.mjs} +3 -3
- package/dist/{content-D6YG26WG.mjs.map → content-8voQNTXX.mjs.map} +1 -1
- package/dist/{context-qF8d3IPR.mjs → context-B7qiYrz2.mjs} +10 -10
- package/dist/context-B7qiYrz2.mjs.map +1 -0
- package/dist/{cron-H8eJ46dv.mjs → cron-Bd3b3iuj.mjs} +1 -1
- package/dist/{cron-H8eJ46dv.mjs.map → cron-Bd3b3iuj.mjs.map} +1 -1
- package/dist/{dashboard-BmWSIUwY.mjs → dashboard-BeaFSPpx.mjs} +4 -4
- package/dist/{dashboard-BmWSIUwY.mjs.map → dashboard-BeaFSPpx.mjs.map} +1 -1
- package/dist/db/index.d.mts +3 -3
- package/dist/db/index.mjs +1 -1
- package/dist/db/libsql.d.mts +1 -1
- package/dist/db/postgres.d.mts +1 -1
- package/dist/db/sqlite.d.mts +1 -1
- package/dist/db/sqlite.mjs +1 -1
- package/dist/{db-errors-CGN9kJfo.mjs → db-errors-BiYqoX-n.mjs} +14 -2
- package/dist/db-errors-BiYqoX-n.mjs.map +1 -0
- package/dist/{default-Dbs22Gg4.mjs → default-BvTAYCzx.mjs} +1 -1
- package/dist/{default-Dbs22Gg4.mjs.map → default-BvTAYCzx.mjs.map} +1 -1
- package/dist/{device-flow-BqJRxa0Q.mjs → device-flow-B9oG8PwP.mjs} +4 -4
- package/dist/{device-flow-BqJRxa0Q.mjs.map → device-flow-B9oG8PwP.mjs.map} +1 -1
- package/dist/{email-console-Dmp5Q-P2.mjs → email-console-CubRll9q.mjs} +1 -1
- package/dist/email-console-CubRll9q.mjs.map +1 -0
- package/dist/{error-tSQWIl5U.mjs → error-ChfADBuu.mjs} +19 -9
- package/dist/error-ChfADBuu.mjs.map +1 -0
- package/dist/errors-9P_FDrJ_.mjs +17 -0
- package/dist/errors-9P_FDrJ_.mjs.map +1 -0
- package/dist/{escape-B8bdIryO.mjs → escape-Cg6kMELH.mjs} +1 -1
- package/dist/{escape-B8bdIryO.mjs.map → escape-Cg6kMELH.mjs.map} +1 -1
- package/dist/{fts-manager-B633C-kQ.mjs → fts-manager-C_b-4x8u.mjs} +2 -2
- package/dist/{fts-manager-B633C-kQ.mjs.map → fts-manager-C_b-4x8u.mjs.map} +1 -1
- package/dist/{import-CNfLOgDE.mjs → import-DG80rC_I.mjs} +3 -3
- package/dist/{import-CNfLOgDE.mjs.map → import-DG80rC_I.mjs.map} +1 -1
- package/dist/{index-BV8iJ-6s.d.mts → index-BPZFAcgE.d.mts} +384 -123
- package/dist/index-BPZFAcgE.d.mts.map +1 -0
- package/dist/{index-D2gvztOP.d.mts → index-CC42STEm.d.mts} +3 -3
- package/dist/{index-D2gvztOP.d.mts.map → index-CC42STEm.d.mts.map} +1 -1
- package/dist/index.d.mts +17 -17
- package/dist/index.mjs +53 -52
- package/dist/{load-QzYRpVN3.mjs → load-CLFRjk9r.mjs} +2 -2
- package/dist/{load-QzYRpVN3.mjs.map → load-CLFRjk9r.mjs.map} +1 -1
- package/dist/{loader-Cs6-Bqe6.mjs → loader-D-vIJjfY.mjs} +86 -46
- package/dist/loader-D-vIJjfY.mjs.map +1 -0
- package/dist/{manifest-schema-HCtSh4Jq.mjs → manifest-schema-Czqf0TLu.mjs} +1 -1
- package/dist/{manifest-schema-HCtSh4Jq.mjs.map → manifest-schema-Czqf0TLu.mjs.map} +1 -1
- package/dist/media/index.d.mts +1 -1
- package/dist/media/local-runtime.d.mts +11 -11
- package/dist/media/local-runtime.mjs +4 -4
- package/dist/{media-Dg7he9uK.mjs → media-CKQd8AYU.mjs} +2 -2
- package/dist/media-CKQd8AYU.mjs.map +1 -0
- package/dist/{media-allowlist-B8EX01DH.mjs → media-allowlist-BNloC69x.mjs} +1 -1
- package/dist/{media-allowlist-B8EX01DH.mjs.map → media-allowlist-BNloC69x.mjs.map} +1 -1
- package/dist/{menus-X4Z-eBA1.mjs → menus-C-nWT5Tu.mjs} +42 -17
- package/dist/menus-C-nWT5Tu.mjs.map +1 -0
- package/dist/{menus-DOzIecHi.mjs → menus-arUNspyU.mjs} +2 -2
- package/dist/menus-arUNspyU.mjs.map +1 -0
- package/dist/mime-KV5TqkMN.mjs.map +1 -1
- package/dist/{mode-DPRPvJYm.mjs → mode-CaaiebZI.mjs} +1 -1
- package/dist/{mode-DPRPvJYm.mjs.map → mode-CaaiebZI.mjs.map} +1 -1
- package/dist/{oauth-authorization-62GmpGIH.mjs → oauth-authorization-CTMeVfvj.mjs} +4 -4
- package/dist/{oauth-authorization-62GmpGIH.mjs.map → oauth-authorization-CTMeVfvj.mjs.map} +1 -1
- package/dist/{oauth-clients-D_B0_-Bz.mjs → oauth-clients-eJCbkVSG.mjs} +1 -1
- package/dist/oauth-clients-eJCbkVSG.mjs.map +1 -0
- package/dist/{oauth-state-store-DpsZViTu.mjs → oauth-state-store-vOSdOeGe.mjs} +1 -1
- package/dist/{oauth-state-store-DpsZViTu.mjs.map → oauth-state-store-vOSdOeGe.mjs.map} +1 -1
- package/dist/{oauth-user-lookup-meyS2oB1.mjs → oauth-user-lookup-3JwsVw6N.mjs} +1 -1
- package/dist/{oauth-user-lookup-meyS2oB1.mjs.map → oauth-user-lookup-3JwsVw6N.mjs.map} +1 -1
- package/dist/options-BL4X94qY.mjs.map +1 -1
- package/dist/{options-Cq64Wx0O.d.mts → options-DhV-gwJb.d.mts} +4 -4
- package/dist/options-DhV-gwJb.d.mts.map +1 -0
- package/dist/page/index.d.mts +2 -2
- package/dist/{parse-BFTPon-J.mjs → parse-DHbXfvxO.mjs} +2 -2
- package/dist/{parse-BFTPon-J.mjs.map → parse-DHbXfvxO.mjs.map} +1 -1
- package/dist/{passkey-config-Cg86_ISa.mjs → passkey-config-BloQOT3y.mjs} +1 -1
- package/dist/{passkey-config-Cg86_ISa.mjs.map → passkey-config-BloQOT3y.mjs.map} +1 -1
- package/dist/{placeholder-D3cFCU9y.d.mts → placeholder-KCkkCtgQ.d.mts} +1 -1
- package/dist/{placeholder-D3cFCU9y.d.mts.map → placeholder-KCkkCtgQ.d.mts.map} +1 -1
- package/dist/plugin-types.d.mts +1 -1
- package/dist/plugin-utils.d.mts +25 -10
- package/dist/plugin-utils.d.mts.map +1 -1
- package/dist/plugin-utils.mjs +11 -10
- package/dist/plugin-utils.mjs.map +1 -1
- package/dist/plugins/adapt-sandbox-entry.d.mts +9 -9
- package/dist/plugins/adapt-sandbox-entry.d.mts.map +1 -1
- package/dist/plugins/adapt-sandbox-entry.mjs +26 -15
- package/dist/plugins/adapt-sandbox-entry.mjs.map +1 -1
- package/dist/{preview-C1LOEbWZ.mjs → preview-D4z0WONU.mjs} +2 -2
- package/dist/{preview-C1LOEbWZ.mjs.map → preview-D4z0WONU.mjs.map} +1 -1
- package/dist/{public-url-CseXl9Fv.mjs → public-url-CUWWFME2.mjs} +1 -1
- package/dist/{public-url-CseXl9Fv.mjs.map → public-url-CUWWFME2.mjs.map} +1 -1
- package/dist/{query-axZmO6Tn.mjs → query-7m6-l0f_.mjs} +27 -17
- package/dist/query-7m6-l0f_.mjs.map +1 -0
- package/dist/{rate-limit-t5CVjCO6.mjs → rate-limit-D8RAXN8b.mjs} +2 -2
- package/dist/{rate-limit-t5CVjCO6.mjs.map → rate-limit-D8RAXN8b.mjs.map} +1 -1
- package/dist/{redirect-DGRsLO2I.mjs → redirect-BINiRYq4.mjs} +1 -1
- package/dist/{redirect-DGRsLO2I.mjs.map → redirect-BINiRYq4.mjs.map} +1 -1
- package/dist/{redirect-DkaDxq8e.mjs → redirect-CjfDGrTd.mjs} +2 -2
- package/dist/{redirect-DkaDxq8e.mjs.map → redirect-CjfDGrTd.mjs.map} +1 -1
- package/dist/{redirects-Dmj6KRU3.mjs → redirects-COMLwsV5.mjs} +19 -5
- package/dist/redirects-COMLwsV5.mjs.map +1 -0
- package/dist/{redirects-D1fdd68T.mjs → redirects-CowoEHdE.mjs} +3 -3
- package/dist/{redirects-D1fdd68T.mjs.map → redirects-CowoEHdE.mjs.map} +1 -1
- package/dist/{registry-BnCeHYsf.mjs → registry-Cyp-dx6J.mjs} +4 -4
- package/dist/{registry-BnCeHYsf.mjs.map → registry-Cyp-dx6J.mjs.map} +1 -1
- package/dist/request-cache-dzCt8TZB.mjs.map +1 -1
- package/dist/request-context.mjs.map +1 -1
- package/dist/{request-meta-CLCwSQOS.mjs → request-meta-C_Cjii-T.mjs} +2 -2
- package/dist/{request-meta-CLCwSQOS.mjs.map → request-meta-C_Cjii-T.mjs.map} +1 -1
- package/dist/resolve-D6sM-SgF.mjs +143 -0
- package/dist/resolve-D6sM-SgF.mjs.map +1 -0
- package/dist/{runner-DcfZewkO.d.mts → runner-DSQBurMS.d.mts} +8 -5
- package/dist/runner-DSQBurMS.d.mts.map +1 -0
- package/dist/{runner-DdnQIwz_.mjs → runner-Drnvs96u.mjs} +491 -188
- package/dist/runner-Drnvs96u.mjs.map +1 -0
- package/dist/runtime.d.mts +10 -10
- package/dist/runtime.mjs +2 -2
- package/dist/{schema-BmqagCwG.mjs → schema-CI9mYPX3.mjs} +4 -4
- package/dist/{schema-BmqagCwG.mjs.map → schema-CI9mYPX3.mjs.map} +1 -1
- package/dist/{search-CPrvO5u8.mjs → search-DKz_mGBP.mjs} +4 -4
- package/dist/{search-CPrvO5u8.mjs.map → search-DKz_mGBP.mjs.map} +1 -1
- package/dist/{secrets-6pgZyq0K.mjs → secrets-rPdhEBkD.mjs} +1 -1
- package/dist/{secrets-6pgZyq0K.mjs.map → secrets-rPdhEBkD.mjs.map} +1 -1
- package/dist/{sections-Cm-zb-gZ.mjs → sections-DBbCDIAT.mjs} +3 -3
- package/dist/{sections-Cm-zb-gZ.mjs.map → sections-DBbCDIAT.mjs.map} +1 -1
- package/dist/seed/index.d.mts +2 -2
- package/dist/seed/index.mjs +16 -16
- package/dist/seo/index.d.mts +1 -1
- package/dist/{seo-DRq9-EPP.mjs → seo-BGCyDlkb.mjs} +2 -2
- package/dist/{seo-DRq9-EPP.mjs.map → seo-BGCyDlkb.mjs.map} +1 -1
- package/dist/{seo-BoR4wCUh.mjs → seo-Dq707mNQ.mjs} +5 -3
- package/dist/seo-Dq707mNQ.mjs.map +1 -0
- package/dist/{service-vByySp-2.mjs → service-B0H7U1Y9.mjs} +3 -3
- package/dist/{service-vByySp-2.mjs.map → service-B0H7U1Y9.mjs.map} +1 -1
- package/dist/{settings-xQKsWnzQ.mjs → settings-BSXRtTzk.mjs} +3 -3
- package/dist/settings-BSXRtTzk.mjs.map +1 -0
- package/dist/{settings-CBBj7HUd.mjs → settings-DfwNyQkf.mjs} +3 -3
- package/dist/{settings-CBBj7HUd.mjs.map → settings-DfwNyQkf.mjs.map} +1 -1
- package/dist/{setup-BGAJ2uXs.mjs → setup-Cf_TyOv5.mjs} +2 -2
- package/dist/{setup-BGAJ2uXs.mjs.map → setup-Cf_TyOv5.mjs.map} +1 -1
- package/dist/{setup-complete-C6ZCLhKo.mjs → setup-complete-MzzN9u0b.mjs} +1 -1
- package/dist/{setup-complete-C6ZCLhKo.mjs.map → setup-complete-MzzN9u0b.mjs.map} +1 -1
- package/dist/{setup-nonce-CY1gQiAU.mjs → setup-nonce-DXuriHsg.mjs} +1 -1
- package/dist/{setup-nonce-CY1gQiAU.mjs.map → setup-nonce-DXuriHsg.mjs.map} +1 -1
- package/dist/{site-url-D-M4Fd8O.mjs → site-url-xkhw1tcz.mjs} +1 -1
- package/dist/{site-url-D-M4Fd8O.mjs.map → site-url-xkhw1tcz.mjs.map} +1 -1
- package/dist/{ssrf-DzFN_qV-.mjs → ssrf-MZ-zrG6-.mjs} +1 -1
- package/dist/{ssrf-DzFN_qV-.mjs.map → ssrf-MZ-zrG6-.mjs.map} +1 -1
- package/dist/storage/local.d.mts +1 -1
- package/dist/storage/local.mjs +1 -1
- package/dist/storage/local.mjs.map +1 -1
- package/dist/storage/s3.d.mts +1 -1
- package/dist/storage/s3.mjs +1 -1
- package/dist/storage/s3.mjs.map +1 -1
- package/dist/{taxonomies-Dc0mzlms.mjs → taxonomies-4vx0nmMr.mjs} +4 -4
- package/dist/{taxonomies-Dc0mzlms.mjs.map → taxonomies-4vx0nmMr.mjs.map} +1 -1
- package/dist/{taxonomies-Cn9UpaR2.mjs → taxonomies-CcvrMLbR.mjs} +8 -43
- package/dist/taxonomies-CcvrMLbR.mjs.map +1 -0
- package/dist/{taxonomy-wPfusMK9.mjs → taxonomy-zqGQUqgu.mjs} +3 -3
- package/dist/{taxonomy-wPfusMK9.mjs.map → taxonomy-zqGQUqgu.mjs.map} +1 -1
- package/dist/{tokens-DILYNZMi.mjs → tokens-N8otWMmj.mjs} +1 -1
- package/dist/{tokens-DILYNZMi.mjs.map → tokens-N8otWMmj.mjs.map} +1 -1
- package/dist/{transport-fw-mKJzT.mjs → transport-B6CHddbu.mjs} +1 -1
- package/dist/{transport-fw-mKJzT.mjs.map → transport-B6CHddbu.mjs.map} +1 -1
- package/dist/{transport-GeXlLscf.d.mts → transport-C2MGqtL6.d.mts} +1 -1
- package/dist/{transport-GeXlLscf.d.mts.map → transport-C2MGqtL6.d.mts.map} +1 -1
- package/dist/{trusted-proxy-CJhQIk65.mjs → trusted-proxy-97pajC2f.mjs} +1 -1
- package/dist/{trusted-proxy-CJhQIk65.mjs.map → trusted-proxy-97pajC2f.mjs.map} +1 -1
- package/dist/{types-CwXMEPRr.mjs → types-B0bmgwMG.mjs} +2 -2
- package/dist/types-B0bmgwMG.mjs.map +1 -0
- package/dist/{types-Dz9CGX_d.mjs → types-Cd9UCu3t.mjs} +1 -1
- package/dist/{types-Dz9CGX_d.mjs.map → types-Cd9UCu3t.mjs.map} +1 -1
- package/dist/{types-DmxPPXGf.d.mts → types-CkDSF81F.d.mts} +1 -1
- package/dist/{types-DmxPPXGf.d.mts.map → types-CkDSF81F.d.mts.map} +1 -1
- package/dist/{types-BWhaSS7U.d.mts → types-CpUuGcd5.d.mts} +1 -1
- package/dist/{types-BWhaSS7U.d.mts.map → types-CpUuGcd5.d.mts.map} +1 -1
- package/dist/{types-DFowNO60.d.mts → types-D599-ruj.d.mts} +1 -1
- package/dist/{types-DFowNO60.d.mts.map → types-D599-ruj.d.mts.map} +1 -1
- package/dist/{types-B05e2naf.d.mts → types-DGHWRQgr.d.mts} +3 -3
- package/dist/{types-B05e2naf.d.mts.map → types-DGHWRQgr.d.mts.map} +1 -1
- package/dist/{types-CzvJd1ND.d.mts → types-DaYDYW6g.d.mts} +14 -1
- package/dist/types-DaYDYW6g.d.mts.map +1 -0
- package/dist/{types-C1KKK4VP.d.mts → types-DaqNzqVt.d.mts} +16 -1
- package/dist/{types-C1KKK4VP.d.mts.map → types-DaqNzqVt.d.mts.map} +1 -1
- package/dist/{types-DW1l0gCv.d.mts → types-Dgo6y-Ut.d.mts} +1 -1
- package/dist/{types-DW1l0gCv.d.mts.map → types-Dgo6y-Ut.d.mts.map} +1 -1
- package/dist/{types-Cb2UCDJg.d.mts → types-bYmRn_Uy.d.mts} +1 -1
- package/dist/{types-Cb2UCDJg.d.mts.map → types-bYmRn_Uy.d.mts.map} +1 -1
- package/dist/{user-Dr1bOCqS.mjs → user-hUSOaIJy.mjs} +2 -2
- package/dist/{user-Dr1bOCqS.mjs.map → user-hUSOaIJy.mjs.map} +1 -1
- package/dist/{utils-_F-rWBTN.mjs → utils-C3wTAP-P.mjs} +1 -1
- package/dist/{utils-_F-rWBTN.mjs.map → utils-C3wTAP-P.mjs.map} +1 -1
- package/dist/{validate-BpQGsmd7.d.mts → validate-DQtHw9NT.d.mts} +5 -5
- package/dist/{validate-BpQGsmd7.d.mts.map → validate-DQtHw9NT.d.mts.map} +1 -1
- package/dist/{validate-DlFxcVVK.mjs → validate-IGltez8n.mjs} +2 -2
- package/dist/{validate-DlFxcVVK.mjs.map → validate-IGltez8n.mjs.map} +1 -1
- package/dist/{validation-BiFJqUp5.mjs → validation-Bmymau7y.mjs} +6 -6
- package/dist/{validation-BiFJqUp5.mjs.map → validation-Bmymau7y.mjs.map} +1 -1
- package/dist/version-BTc87L3L.mjs +7 -0
- package/dist/{version-DNmQakZO.mjs.map → version-BTc87L3L.mjs.map} +1 -1
- package/dist/{widgets-B9j_yzlk.mjs → widgets-yHQa4c6c.mjs} +3 -3
- package/dist/widgets-yHQa4c6c.mjs.map +1 -0
- package/dist/{zod-generator-DSyz01KE.mjs → zod-generator-B80aap1J.mjs} +2 -2
- package/dist/{zod-generator-DSyz01KE.mjs.map → zod-generator-B80aap1J.mjs.map} +1 -1
- package/package.json +12 -10
- package/src/api/error.ts +18 -3
- package/src/api/errors.ts +8 -0
- package/src/api/handlers/bylines.ts +161 -0
- package/src/api/handlers/content.ts +125 -43
- package/src/api/handlers/index.ts +8 -0
- package/src/api/handlers/marketplace.ts +27 -5
- package/src/api/handlers/oauth-clients.ts +1 -1
- package/src/api/handlers/registry.ts +622 -5
- package/src/api/handlers/seo.ts +16 -1
- package/src/api/handlers/snapshot.ts +1 -1
- package/src/api/openapi/document.ts +1 -1
- package/src/api/schemas/bylines.ts +46 -0
- package/src/astro/integration/index.ts +27 -1
- package/src/astro/integration/routes.ts +10 -0
- package/src/astro/integration/runtime.ts +20 -1
- package/src/astro/integration/virtual-modules.ts +19 -2
- package/src/astro/integration/vite-config.ts +2 -2
- package/src/astro/middleware/auth.ts +7 -7
- package/src/astro/middleware/request-context.ts +1 -1
- package/src/astro/middleware.ts +35 -20
- package/src/astro/public-plugin-api-routes.ts +41 -0
- package/src/astro/routes/api/admin/bylines/[id]/index.ts +3 -12
- package/src/astro/routes/api/admin/bylines/[id]/translations.ts +99 -0
- package/src/astro/routes/api/admin/bylines/index.ts +22 -11
- package/src/astro/routes/api/admin/plugins/[id]/update.ts +1 -0
- package/src/astro/routes/api/admin/plugins/marketplace/[id]/install.ts +6 -1
- package/src/astro/routes/api/admin/plugins/registry/[id]/uninstall.ts +51 -0
- package/src/astro/routes/api/admin/plugins/registry/[id]/update.ts +83 -0
- package/src/astro/routes/api/admin/plugins/registry/artifact.ts +388 -0
- package/src/astro/routes/api/admin/plugins/registry/install.ts +7 -1
- package/src/astro/routes/api/admin/plugins/updates.ts +43 -6
- package/src/astro/routes/api/admin/themes/marketplace/index.ts +1 -1
- package/src/astro/routes/api/auth/oauth/[provider]/callback.ts +2 -2
- package/src/astro/routes/api/auth/oauth/[provider].ts +2 -2
- package/src/astro/routes/api/content/[collection]/[id]/discard-draft.ts +2 -2
- package/src/astro/routes/api/content/[collection]/[id]/duplicate.ts +2 -2
- package/src/astro/routes/api/content/[collection]/[id]/publish.ts +2 -2
- package/src/astro/routes/api/content/[collection]/[id]/restore.ts +2 -2
- package/src/astro/routes/api/content/[collection]/[id]/schedule.ts +2 -2
- package/src/astro/routes/api/content/[collection]/[id]/terms/[taxonomy].ts +6 -6
- package/src/astro/routes/api/content/[collection]/[id]/translations.ts +1 -1
- package/src/astro/routes/api/content/[collection]/[id]/unpublish.ts +2 -2
- package/src/astro/routes/api/content/[collection]/[id].ts +6 -6
- package/src/astro/routes/api/import/wordpress/execute.ts +1 -1
- package/src/astro/routes/api/import/wordpress/prepare.ts +2 -2
- package/src/astro/routes/api/import/wordpress/rewrite-url-helpers.ts +22 -0
- package/src/astro/routes/api/import/wordpress/rewrite-urls.ts +8 -5
- package/src/astro/routes/api/import/wordpress-plugin/execute.ts +2 -2
- package/src/astro/routes/api/media/upload-url.ts +1 -1
- package/src/astro/routes/api/redirects/404s/index.ts +3 -3
- package/src/astro/routes/api/redirects/404s/summary.ts +1 -1
- package/src/astro/routes/api/redirects/[id].ts +3 -3
- package/src/astro/routes/api/redirects/index.ts +2 -2
- package/src/astro/routes/api/schema/collections/[slug]/fields/[fieldSlug].ts +4 -4
- package/src/astro/routes/api/schema/collections/[slug]/fields/index.ts +2 -6
- package/src/astro/routes/api/schema/collections/[slug]/fields/reorder.ts +1 -1
- package/src/astro/routes/api/schema/collections/[slug]/index.ts +6 -6
- package/src/astro/routes/api/schema/collections/index.ts +4 -4
- package/src/astro/routes/api/schema/index.ts +1 -1
- package/src/astro/routes/api/schema/orphans/[slug].ts +1 -1
- package/src/astro/routes/api/schema/orphans/index.ts +1 -1
- package/src/astro/routes/api/sections/[slug].ts +3 -3
- package/src/astro/routes/api/sections/index.ts +2 -2
- package/src/astro/routes/sitemap-[collection].xml.ts +114 -14
- package/src/astro/types.ts +18 -0
- package/src/auth/rate-limit.ts +1 -1
- package/src/auth/trusted-proxy.ts +1 -1
- package/src/bylines/index.ts +154 -55
- package/src/cli/commands/init.ts +4 -8
- package/src/client/index.ts +1 -1
- package/src/components/InlinePortableTextEditor.tsx +5 -1
- package/src/components/inline-code-block.tsx +343 -0
- package/src/config/secrets.ts +3 -3
- package/src/content/converters/portable-text-to-prosemirror.ts +35 -11
- package/src/database/connection.ts +3 -10
- package/src/database/errors.ts +14 -0
- package/src/database/index.ts +3 -1
- package/src/database/migrations/006_taxonomy_defs.ts +1 -1
- package/src/database/migrations/014_draft_revisions.ts +6 -6
- package/src/database/migrations/040_byline_i18n.ts +497 -0
- package/src/database/migrations/runner.ts +33 -22
- package/src/database/repositories/audit.ts +2 -2
- package/src/database/repositories/byline.ts +320 -50
- package/src/database/repositories/media.ts +2 -2
- package/src/database/repositories/menu.ts +1 -1
- package/src/database/repositories/options.ts +3 -3
- package/src/database/repositories/plugin-storage.ts +3 -3
- package/src/database/repositories/types.ts +13 -0
- package/src/database/types.ts +15 -0
- package/src/emdash-runtime.ts +493 -20
- package/src/i18n/config.ts +1 -1
- package/src/i18n/resolve.ts +152 -0
- package/src/index.ts +9 -0
- package/src/loader.ts +134 -60
- package/src/mcp/server.ts +3 -3
- package/src/media/mime.ts +1 -1
- package/src/page/absolute-url.ts +1 -1
- package/src/plugin-utils.ts +23 -0
- package/src/plugins/adapt-sandbox-entry.ts +45 -40
- package/src/plugins/email-console.ts +1 -1
- package/src/plugins/index.ts +1 -0
- package/src/plugins/marketplace.ts +1 -1
- package/src/plugins/sandbox/index.ts +1 -0
- package/src/plugins/sandbox/noop.ts +11 -3
- package/src/plugins/sandbox/types.ts +28 -0
- package/src/query.ts +41 -7
- package/src/registry/config.ts +1 -1
- package/src/request-cache.ts +3 -3
- package/src/request-context.ts +1 -1
- package/src/settings/index.ts +4 -4
- package/src/storage/local.ts +1 -1
- package/src/storage/s3.ts +3 -3
- package/src/utils/db-errors.ts +24 -0
- package/src/widgets/index.ts +1 -1
- package/dist/api-BMLZuwM4.mjs.map +0 -1
- package/dist/byline-D09BaS4j.mjs +0 -220
- package/dist/byline-D09BaS4j.mjs.map +0 -1
- package/dist/bylines-BTM2xtP8.mjs +0 -113
- package/dist/bylines-BTM2xtP8.mjs.map +0 -1
- package/dist/bylines-BdUP8NuI.d.mts.map +0 -1
- package/dist/connection-2igzM-AT.mjs +0 -57
- package/dist/connection-2igzM-AT.mjs.map +0 -1
- package/dist/context-qF8d3IPR.mjs.map +0 -1
- package/dist/db-errors-CGN9kJfo.mjs.map +0 -1
- package/dist/email-console-Dmp5Q-P2.mjs.map +0 -1
- package/dist/error-tSQWIl5U.mjs.map +0 -1
- package/dist/index-BV8iJ-6s.d.mts.map +0 -1
- package/dist/loader-Cs6-Bqe6.mjs.map +0 -1
- package/dist/media-Dg7he9uK.mjs.map +0 -1
- package/dist/menus-DOzIecHi.mjs.map +0 -1
- package/dist/menus-X4Z-eBA1.mjs.map +0 -1
- package/dist/oauth-clients-D_B0_-Bz.mjs.map +0 -1
- package/dist/options-Cq64Wx0O.d.mts.map +0 -1
- package/dist/query-axZmO6Tn.mjs.map +0 -1
- package/dist/redirects-Dmj6KRU3.mjs.map +0 -1
- package/dist/runner-DcfZewkO.d.mts.map +0 -1
- package/dist/runner-DdnQIwz_.mjs.map +0 -1
- package/dist/seo-BoR4wCUh.mjs.map +0 -1
- package/dist/settings-xQKsWnzQ.mjs.map +0 -1
- package/dist/taxonomies-Cn9UpaR2.mjs.map +0 -1
- package/dist/types-CwXMEPRr.mjs.map +0 -1
- package/dist/types-CzvJd1ND.d.mts.map +0 -1
- package/dist/version-DNmQakZO.mjs +0 -7
- package/dist/widgets-B9j_yzlk.mjs.map +0 -1
- /package/dist/{api-tokens-D3C9v02m.mjs → api-tokens-iPIHAY8N.mjs} +0 -0
- /package/dist/{ssrf-CTul4uQi.mjs → ssrf-BIcd-aXW.mjs} +0 -0
- /package/dist/{types-Db67HHlU.mjs → types-1NNkmTIn.mjs} +0 -0
|
@@ -1,75 +1,75 @@
|
|
|
1
|
-
import { r as runMigrations } from "../runner-
|
|
2
|
-
import { createRequestMetrics, getRequestContext, runWithContext } from "../request-context.mjs";
|
|
3
|
-
import { createRecorder, flushRecorder, isInstrumentationEnabled, kyselyLogOption } from "../database/instrumentation.mjs";
|
|
4
|
-
import "../connection-2igzM-AT.mjs";
|
|
1
|
+
import { r as runMigrations } from "../runner-Drnvs96u.mjs";
|
|
5
2
|
import { t as validateIdentifier } from "../validate-VPnKoIzW.mjs";
|
|
6
3
|
import { o as isSqlite } from "../dialect-helpers-BKCvISIQ.mjs";
|
|
7
4
|
import { i as setI18nConfig } from "../config-CVssduLe.mjs";
|
|
8
|
-
import { _ as
|
|
9
|
-
import { r as RevisionRepository } from "../content-
|
|
5
|
+
import { _ as definePlugin, f as PluginRouteRegistry, g as resolveExclusiveHooks, h as createHookPipeline, p as EmailPipeline, v as after } from "../menus-C-nWT5Tu.mjs";
|
|
6
|
+
import { r as RevisionRepository } from "../content-8voQNTXX.mjs";
|
|
10
7
|
import "../base64-CqR-7kqF.mjs";
|
|
11
|
-
import "../types-
|
|
12
|
-
import { t as MediaRepository } from "../media-
|
|
13
|
-
import "../user-
|
|
14
|
-
import "../taxonomy-
|
|
15
|
-
import "../comment-
|
|
8
|
+
import "../types-B0bmgwMG.mjs";
|
|
9
|
+
import { t as MediaRepository } from "../media-CKQd8AYU.mjs";
|
|
10
|
+
import "../user-hUSOaIJy.mjs";
|
|
11
|
+
import "../taxonomy-zqGQUqgu.mjs";
|
|
12
|
+
import "../comment-C76G-9tz.mjs";
|
|
16
13
|
import { t as OptionsRepository } from "../options-BL4X94qY.mjs";
|
|
17
|
-
import "../context-
|
|
18
|
-
import "../menus-
|
|
19
|
-
import "../redirect-
|
|
20
|
-
import "../byline-
|
|
14
|
+
import "../context-B7qiYrz2.mjs";
|
|
15
|
+
import "../menus-arUNspyU.mjs";
|
|
16
|
+
import "../redirect-CjfDGrTd.mjs";
|
|
17
|
+
import "../byline-BDylH_m4.mjs";
|
|
21
18
|
import { t as normalizeMediaValue } from "../normalize-CN5kRSMC.mjs";
|
|
22
19
|
import "../placeholder-LqmHqvBw.mjs";
|
|
23
|
-
import "../seo-
|
|
24
|
-
import { $ as
|
|
20
|
+
import "../seo-BGCyDlkb.mjs";
|
|
21
|
+
import { $ as handleContentGetIncludingTrashed, B as handleMediaUpdate, G as handleContentCompare, H as handleRevisionList, I as handleMediaCreate, J as handleContentCreate, K as handleContentCountScheduled, L as handleMediaDelete, Q as handleContentGet, R as handleMediaGet, S as PluginStateRepository, U as handleRevisionRestore, V as handleRevisionGet, X as handleContentDiscardDraft, Y as handleContentDelete, Z as handleContentDuplicate, _ as loadBundleFromR2, at as handleContentSchedule, ct as handleContentUnschedule, et as handleContentList, it as handleContentRestore, lt as handleContentUpdate, nt as handleContentPermanentDelete, ot as handleContentTranslations, q as handleContentCountTrashed, rt as handleContentPublish, s as normalizeRegistryConfig, st as handleContentUnpublish, tt as handleContentListTrashed, ut as validateRev, z as handleMediaList } from "../api-BNKqxyFX.mjs";
|
|
22
|
+
import { createRequestMetrics, getRequestContext, runWithContext } from "../request-context.mjs";
|
|
25
23
|
import { n as requestCached } from "../request-cache-dzCt8TZB.mjs";
|
|
26
|
-
import "../dashboard-
|
|
24
|
+
import "../dashboard-BeaFSPpx.mjs";
|
|
27
25
|
import { n as hashString } from "../hash-DlUxGhQS.mjs";
|
|
28
|
-
import { t as FTSManager } from "../fts-manager-
|
|
29
|
-
import { n as SchemaRegistry } from "../registry-
|
|
30
|
-
import {
|
|
31
|
-
import "../
|
|
32
|
-
import "../
|
|
33
|
-
import "../
|
|
34
|
-
import "../
|
|
35
|
-
import
|
|
36
|
-
import "../settings-
|
|
37
|
-
import "../
|
|
38
|
-
import "../
|
|
39
|
-
import
|
|
40
|
-
import "../
|
|
41
|
-
import "../
|
|
42
|
-
import "../
|
|
43
|
-
import "../
|
|
44
|
-
import "../
|
|
45
|
-
import "../
|
|
46
|
-
import
|
|
47
|
-
import "../
|
|
48
|
-
import {
|
|
49
|
-
import
|
|
50
|
-
import "../
|
|
51
|
-
import { n as
|
|
52
|
-
import
|
|
53
|
-
import "../
|
|
54
|
-
import "../
|
|
55
|
-
import "../
|
|
56
|
-
import "../
|
|
57
|
-
import "../
|
|
58
|
-
import "../
|
|
59
|
-
import "../
|
|
60
|
-
import "../
|
|
26
|
+
import { t as FTSManager } from "../fts-manager-C_b-4x8u.mjs";
|
|
27
|
+
import { n as SchemaRegistry } from "../registry-Cyp-dx6J.mjs";
|
|
28
|
+
import { createRecorder, flushRecorder, isInstrumentationEnabled, kyselyLogOption } from "../database/instrumentation.mjs";
|
|
29
|
+
import { r as getDb } from "../loader-D-vIJjfY.mjs";
|
|
30
|
+
import "../schema-CI9mYPX3.mjs";
|
|
31
|
+
import "../zod-generator-B80aap1J.mjs";
|
|
32
|
+
import "../seo-Dq707mNQ.mjs";
|
|
33
|
+
import "../sections-DBbCDIAT.mjs";
|
|
34
|
+
import { o as invalidateSiteSettingsCache } from "../settings-BSXRtTzk.mjs";
|
|
35
|
+
import "../settings-DfwNyQkf.mjs";
|
|
36
|
+
import "../resolve-D6sM-SgF.mjs";
|
|
37
|
+
import "../taxonomies-CcvrMLbR.mjs";
|
|
38
|
+
import "../taxonomies-4vx0nmMr.mjs";
|
|
39
|
+
import { r as normalizeManifestRoute } from "../manifest-schema-Czqf0TLu.mjs";
|
|
40
|
+
import "../types-1NNkmTIn.mjs";
|
|
41
|
+
import "../ssrf-MZ-zrG6-.mjs";
|
|
42
|
+
import "../error-ChfADBuu.mjs";
|
|
43
|
+
import "../parse-DHbXfvxO.mjs";
|
|
44
|
+
import "../redirects-COMLwsV5.mjs";
|
|
45
|
+
import "../setup-Cf_TyOv5.mjs";
|
|
46
|
+
import { a as invalidateUrlPatternCache } from "../query-7m6-l0f_.mjs";
|
|
47
|
+
import "../import-DG80rC_I.mjs";
|
|
48
|
+
import { t as getTrustedProxyHeaders } from "../trusted-proxy-97pajC2f.mjs";
|
|
49
|
+
import { n as sanitizeHeadersForSandbox, t as extractRequestMeta } from "../request-meta-C_Cjii-T.mjs";
|
|
50
|
+
import "../ssrf-BIcd-aXW.mjs";
|
|
51
|
+
import { n as CronExecutor } from "../cron-Bd3b3iuj.mjs";
|
|
52
|
+
import { r as devConsoleEmailDeliver, t as DEV_CONSOLE_EMAIL_PLUGIN_ID } from "../email-console-CubRll9q.mjs";
|
|
53
|
+
import "../utils-C3wTAP-P.mjs";
|
|
54
|
+
import "../tokens-N8otWMmj.mjs";
|
|
55
|
+
import "../preview-D4z0WONU.mjs";
|
|
56
|
+
import "../bylines-n6nykUyI.mjs";
|
|
57
|
+
import "../widgets-yHQa4c6c.mjs";
|
|
58
|
+
import "../apply-BOPaD-s9.mjs";
|
|
59
|
+
import "../load-CLFRjk9r.mjs";
|
|
60
|
+
import "../search-DKz_mGBP.mjs";
|
|
61
61
|
import "../index.mjs";
|
|
62
|
-
import { n as VERSION, t as COMMIT } from "../version-
|
|
63
|
-
import { t as getAuthMode } from "../mode-
|
|
64
|
-
import { t as cleanupExpiredChallenges } from "../challenge-store-
|
|
65
|
-
import { a as validateEncryptionKeyAtStartup } from "../secrets-
|
|
62
|
+
import { n as VERSION, t as COMMIT } from "../version-BTc87L3L.mjs";
|
|
63
|
+
import { t as getAuthMode } from "../mode-CaaiebZI.mjs";
|
|
64
|
+
import { t as cleanupExpiredChallenges } from "../challenge-store-Dng1SxKT.mjs";
|
|
65
|
+
import { a as validateEncryptionKeyAtStartup } from "../secrets-rPdhEBkD.mjs";
|
|
66
66
|
import { Kysely, sql } from "kysely";
|
|
67
67
|
import { defineMiddleware } from "astro:middleware";
|
|
68
68
|
import virtualConfig from "virtual:emdash/config";
|
|
69
69
|
import { createDialect, createRequestScopedDb } from "virtual:emdash/dialect";
|
|
70
70
|
import { mediaProviders } from "virtual:emdash/media-providers";
|
|
71
71
|
import { plugins } from "virtual:emdash/plugins";
|
|
72
|
-
import
|
|
72
|
+
import * as virtualSandboxRunnerModule from "virtual:emdash/sandbox-runner";
|
|
73
73
|
import { sandboxedPlugins } from "virtual:emdash/sandboxed-plugins";
|
|
74
74
|
import { createStorage } from "virtual:emdash/storage";
|
|
75
75
|
import { createKyselyAdapter } from "@emdash-cms/auth/adapters/kysely";
|
|
@@ -484,6 +484,15 @@ var EmDashRuntime = class EmDashRuntime {
|
|
|
484
484
|
return sandboxRunner;
|
|
485
485
|
}
|
|
486
486
|
/**
|
|
487
|
+
* Whether the sandbox bypass mode (sandbox: false) is active.
|
|
488
|
+
* Marketplace install/update handlers use this to skip the
|
|
489
|
+
* SANDBOX_NOT_AVAILABLE gate, since the bypass path loads
|
|
490
|
+
* marketplace plugins in-process via syncMarketplacePlugins().
|
|
491
|
+
*/
|
|
492
|
+
isSandboxBypassed() {
|
|
493
|
+
return this.runtimeDeps.sandboxBypassed === true;
|
|
494
|
+
}
|
|
495
|
+
/**
|
|
487
496
|
* Tick the cron system from request context (piggyback mode).
|
|
488
497
|
* Call this from middleware on each request to ensure cron tasks
|
|
489
498
|
* execute even when no dedicated scheduler is available.
|
|
@@ -548,6 +557,10 @@ var EmDashRuntime = class EmDashRuntime {
|
|
|
548
557
|
*/
|
|
549
558
|
async syncMarketplacePlugins() {
|
|
550
559
|
if (!this.config.marketplace) return;
|
|
560
|
+
if (this.runtimeDeps.sandboxBypassed) {
|
|
561
|
+
await this.syncMarketplacePluginsBypassed();
|
|
562
|
+
return;
|
|
563
|
+
}
|
|
551
564
|
await this.syncSandboxedSourcePlugins("marketplace");
|
|
552
565
|
}
|
|
553
566
|
/**
|
|
@@ -564,8 +577,8 @@ var EmDashRuntime = class EmDashRuntime {
|
|
|
564
577
|
/**
|
|
565
578
|
* Internal: reconcile in-memory sandboxed-plugin state with the
|
|
566
579
|
* `_plugin_state` table for the given source tier. Shared
|
|
567
|
-
* implementation behind
|
|
568
|
-
*
|
|
580
|
+
* implementation behind {@link syncMarketplacePlugins} and
|
|
581
|
+
* {@link syncRegistryPlugins}.
|
|
569
582
|
*
|
|
570
583
|
* Each source tier has its own key set in `${source}PluginKeys` so a
|
|
571
584
|
* sync for one tier doesn't invalidate the other.
|
|
@@ -649,6 +662,117 @@ var EmDashRuntime = class EmDashRuntime {
|
|
|
649
662
|
}
|
|
650
663
|
}
|
|
651
664
|
/**
|
|
665
|
+
* Remove a plugin from the in-memory pipeline lists by ID.
|
|
666
|
+
* Mutates allPipelinePlugins and configuredPlugins in place.
|
|
667
|
+
*/
|
|
668
|
+
removePluginFromLists(pluginId) {
|
|
669
|
+
const allIdx = this.allPipelinePlugins.findIndex((p) => p.id === pluginId);
|
|
670
|
+
if (allIdx !== -1) this.allPipelinePlugins.splice(allIdx, 1);
|
|
671
|
+
const configIdx = this.configuredPlugins.findIndex((p) => p.id === pluginId);
|
|
672
|
+
if (configIdx !== -1) this.configuredPlugins.splice(configIdx, 1);
|
|
673
|
+
}
|
|
674
|
+
/**
|
|
675
|
+
* Sync marketplace plugin metadata in sandbox: false bypass mode.
|
|
676
|
+
*
|
|
677
|
+
* In bypass mode the noop runner can't load plugins, but admin pages,
|
|
678
|
+
* widgets, and route metadata still need to refresh in-process when an
|
|
679
|
+
* admin installs/updates/uninstalls a marketplace plugin. Otherwise the
|
|
680
|
+
* admin UI shows stale data until the server restarts.
|
|
681
|
+
*
|
|
682
|
+
* Hooks and routes still won't execute under bypass (matches the
|
|
683
|
+
* cold-start bypass behavior in loadMarketplacePluginsBypassed).
|
|
684
|
+
*
|
|
685
|
+
* Known limitation: bypass plugins are loaded via `import(dataUrl)`,
|
|
686
|
+
* which Node's ESM cache keys on the full URL. Updates create fresh
|
|
687
|
+
* module objects, but old ones remain cached for the worker's lifetime.
|
|
688
|
+
* In practice this is a few KB per update — only matters for sites with
|
|
689
|
+
* very frequent marketplace updates running long-lived processes. The
|
|
690
|
+
* fix would be vm.SourceTextModule for explicit lifecycle management.
|
|
691
|
+
*/
|
|
692
|
+
async syncMarketplacePluginsBypassed() {
|
|
693
|
+
if (!this.storage) return;
|
|
694
|
+
try {
|
|
695
|
+
const marketplaceStates = await new PluginStateRepository(this.db).getMarketplacePlugins();
|
|
696
|
+
const desired = /* @__PURE__ */ new Map();
|
|
697
|
+
for (const state of marketplaceStates) {
|
|
698
|
+
this.pluginStates.set(state.pluginId, state.status);
|
|
699
|
+
if (state.status === "active") this.enabledPlugins.add(state.pluginId);
|
|
700
|
+
else this.enabledPlugins.delete(state.pluginId);
|
|
701
|
+
if (state.status !== "active") continue;
|
|
702
|
+
desired.set(state.pluginId, state.marketplaceVersion ?? state.version);
|
|
703
|
+
}
|
|
704
|
+
const toRemove = [];
|
|
705
|
+
for (const pluginId of marketplaceManifestCache.keys()) if (!desired.has(pluginId)) toRemove.push(pluginId);
|
|
706
|
+
for (const pluginId of toRemove) {
|
|
707
|
+
const resolved = this.allPipelinePlugins.find((p) => p.id === pluginId);
|
|
708
|
+
if (resolved) try {
|
|
709
|
+
const deactivateHook = resolved.hooks?.["plugin:deactivate"];
|
|
710
|
+
if (deactivateHook) {
|
|
711
|
+
const handler = typeof deactivateHook === "function" ? deactivateHook : deactivateHook.handler;
|
|
712
|
+
if (typeof handler === "function") await handler({ pluginId }, {});
|
|
713
|
+
}
|
|
714
|
+
} catch (err) {
|
|
715
|
+
console.warn(`[emdash] plugin:deactivate hook failed for ${pluginId}:`, err);
|
|
716
|
+
}
|
|
717
|
+
marketplaceManifestCache.delete(pluginId);
|
|
718
|
+
sandboxedRouteMetaCache.delete(pluginId);
|
|
719
|
+
this.removePluginFromLists(pluginId);
|
|
720
|
+
this.enabledPlugins.delete(pluginId);
|
|
721
|
+
}
|
|
722
|
+
const { adaptSandboxEntry } = await import("../plugins/adapt-sandbox-entry.mjs");
|
|
723
|
+
const newPlugins = [];
|
|
724
|
+
for (const [pluginId, version] of desired) {
|
|
725
|
+
const bundle = await loadBundleFromR2(this.storage, pluginId, version);
|
|
726
|
+
if (!bundle) {
|
|
727
|
+
console.warn(`EmDash: Marketplace plugin ${pluginId}@${version} not found in R2`);
|
|
728
|
+
continue;
|
|
729
|
+
}
|
|
730
|
+
marketplaceManifestCache.set(pluginId, {
|
|
731
|
+
id: bundle.manifest.id,
|
|
732
|
+
version: bundle.manifest.version,
|
|
733
|
+
admin: bundle.manifest.admin
|
|
734
|
+
});
|
|
735
|
+
if (bundle.manifest.routes.length > 0) {
|
|
736
|
+
const routeMetaMap = /* @__PURE__ */ new Map();
|
|
737
|
+
for (const entry of bundle.manifest.routes) {
|
|
738
|
+
const normalized = normalizeManifestRoute(entry);
|
|
739
|
+
routeMetaMap.set(normalized.name, { public: normalized.public === true });
|
|
740
|
+
}
|
|
741
|
+
sandboxedRouteMetaCache.set(pluginId, routeMetaMap);
|
|
742
|
+
} else sandboxedRouteMetaCache.delete(pluginId);
|
|
743
|
+
const existing = this.allPipelinePlugins.find((p) => p.id === pluginId);
|
|
744
|
+
if (existing && existing.version === bundle.manifest.version) continue;
|
|
745
|
+
if (existing) this.removePluginFromLists(pluginId);
|
|
746
|
+
try {
|
|
747
|
+
const pluginModule = await import(`data:text/javascript;base64,${Buffer.from(bundle.backendCode).toString("base64")}`);
|
|
748
|
+
const adapted = adaptSandboxEntry(pluginModule.default ?? pluginModule, {
|
|
749
|
+
id: bundle.manifest.id,
|
|
750
|
+
version: bundle.manifest.version,
|
|
751
|
+
entrypoint: "",
|
|
752
|
+
capabilities: bundle.manifest.capabilities ?? [],
|
|
753
|
+
allowedHosts: bundle.manifest.allowedHosts ?? [],
|
|
754
|
+
storage: bundle.manifest.storage ?? {},
|
|
755
|
+
adminPages: bundle.manifest.admin?.pages,
|
|
756
|
+
adminWidgets: bundle.manifest.admin?.widgets?.map((w) => ({
|
|
757
|
+
id: w.id,
|
|
758
|
+
title: w.title,
|
|
759
|
+
size: w.size === "full" || w.size === "half" || w.size === "third" ? w.size : void 0
|
|
760
|
+
}))
|
|
761
|
+
});
|
|
762
|
+
newPlugins.push(adapted);
|
|
763
|
+
this.allPipelinePlugins.push(adapted);
|
|
764
|
+
this.configuredPlugins.push(adapted);
|
|
765
|
+
this.enabledPlugins.add(adapted.id);
|
|
766
|
+
} catch (error) {
|
|
767
|
+
console.error(`EmDash: Failed to load marketplace plugin ${pluginId}@${version} in-process:`, error);
|
|
768
|
+
}
|
|
769
|
+
}
|
|
770
|
+
if (toRemove.length > 0 || newPlugins.length > 0) await this.rebuildHookPipeline();
|
|
771
|
+
} catch (error) {
|
|
772
|
+
console.error("EmDash: Failed to sync marketplace plugins (bypass):", error);
|
|
773
|
+
}
|
|
774
|
+
}
|
|
775
|
+
/**
|
|
652
776
|
* Create and initialize the runtime
|
|
653
777
|
*/
|
|
654
778
|
static async create(deps, timings) {
|
|
@@ -696,6 +820,7 @@ var EmDashRuntime = class EmDashRuntime {
|
|
|
696
820
|
} catch {}
|
|
697
821
|
});
|
|
698
822
|
const allPipelinePlugins = [...deps.plugins];
|
|
823
|
+
const bypassedPluginsList = [];
|
|
699
824
|
if (import.meta.env.DEV) try {
|
|
700
825
|
const devConsolePlugin = definePlugin({
|
|
701
826
|
id: DEV_CONSOLE_EMAIL_PLUGIN_ID,
|
|
@@ -726,6 +851,26 @@ var EmDashRuntime = class EmDashRuntime {
|
|
|
726
851
|
} catch (error) {
|
|
727
852
|
console.warn("[comments] Failed to register default moderator:", error);
|
|
728
853
|
}
|
|
854
|
+
if (deps.sandboxBypassed && deps.sandboxedPluginEntries.length > 0) {
|
|
855
|
+
if (typeof navigator !== "undefined" && typeof navigator.userAgent === "string" && navigator.userAgent.includes("Cloudflare-Workers")) throw new Error("sandbox: false is not supported in Cloudflare Workers. Remove the sandbox: false option or use the Cloudflare sandbox runner.");
|
|
856
|
+
console.info("EmDash: Sandbox disabled (sandbox: false). Sandboxed plugins will run in-process without isolation.");
|
|
857
|
+
const bypassedPlugins = await EmDashRuntime.loadBypassedPlugins(deps.sandboxedPluginEntries);
|
|
858
|
+
for (const plugin of bypassedPlugins) {
|
|
859
|
+
allPipelinePlugins.push(plugin);
|
|
860
|
+
bypassedPluginsList.push(plugin);
|
|
861
|
+
const status = pluginStates.get(plugin.id);
|
|
862
|
+
if (status === void 0 || status === "active") enabledPlugins.add(plugin.id);
|
|
863
|
+
}
|
|
864
|
+
}
|
|
865
|
+
if (deps.sandboxBypassed && deps.config.marketplace && storage) {
|
|
866
|
+
const marketplaceBypassed = await EmDashRuntime.loadMarketplacePluginsBypassed(db, storage);
|
|
867
|
+
for (const plugin of marketplaceBypassed) {
|
|
868
|
+
allPipelinePlugins.push(plugin);
|
|
869
|
+
bypassedPluginsList.push(plugin);
|
|
870
|
+
const status = pluginStates.get(plugin.id);
|
|
871
|
+
if (status === void 0 || status === "active") enabledPlugins.add(plugin.id);
|
|
872
|
+
}
|
|
873
|
+
}
|
|
729
874
|
const enabledPluginList = allPipelinePlugins.filter((p) => enabledPlugins.has(p.id));
|
|
730
875
|
const pipelineFactoryOptions = {
|
|
731
876
|
db,
|
|
@@ -733,8 +878,8 @@ var EmDashRuntime = class EmDashRuntime {
|
|
|
733
878
|
siteInfo
|
|
734
879
|
};
|
|
735
880
|
const pipeline = createHookPipeline(enabledPluginList, pipelineFactoryOptions);
|
|
736
|
-
const sandboxedPlugins = await phase("rt.sandbox", "Sandboxed plugins", () => EmDashRuntime.loadSandboxedPlugins(deps, db));
|
|
737
|
-
if (deps.config.marketplace && storage) await phase("rt.market", "Marketplace plugins", () => EmDashRuntime.loadInstalledSandboxedPlugins("marketplace", db, storage, deps, sandboxedPlugins));
|
|
881
|
+
const sandboxedPlugins = await phase("rt.sandbox", "Sandboxed plugins", () => EmDashRuntime.loadSandboxedPlugins(deps, db, storage));
|
|
882
|
+
if (deps.config.marketplace && storage && !deps.sandboxBypassed) await phase("rt.market", "Marketplace plugins", () => EmDashRuntime.loadInstalledSandboxedPlugins("marketplace", db, storage, deps, sandboxedPlugins));
|
|
738
883
|
if (deps.config.experimental?.registry && storage) await phase("rt.registry", "Registry plugins", () => EmDashRuntime.loadInstalledSandboxedPlugins("registry", db, storage, deps, sandboxedPlugins));
|
|
739
884
|
const mediaProviders = /* @__PURE__ */ new Map();
|
|
740
885
|
const mediaProviderEntries = deps.mediaProviderEntries ?? [];
|
|
@@ -792,7 +937,7 @@ var EmDashRuntime = class EmDashRuntime {
|
|
|
792
937
|
return new EmDashRuntime({
|
|
793
938
|
db,
|
|
794
939
|
storage,
|
|
795
|
-
configuredPlugins: deps.plugins,
|
|
940
|
+
configuredPlugins: [...deps.plugins, ...bypassedPluginsList],
|
|
796
941
|
sandboxedPlugins,
|
|
797
942
|
sandboxedPluginEntries: deps.sandboxedPluginEntries,
|
|
798
943
|
hooks: pipeline,
|
|
@@ -859,9 +1004,9 @@ var EmDashRuntime = class EmDashRuntime {
|
|
|
859
1004
|
}
|
|
860
1005
|
})();
|
|
861
1006
|
if (collectionCount.count === 0 && !setupDone) {
|
|
862
|
-
const { applySeed } = await import("../apply-
|
|
863
|
-
const { loadSeed } = await import("../load-
|
|
864
|
-
const { validateSeed } = await import("../validate-
|
|
1007
|
+
const { applySeed } = await import("../apply-BOPaD-s9.mjs").then((n) => n.n);
|
|
1008
|
+
const { loadSeed } = await import("../load-CLFRjk9r.mjs").then((n) => n.r);
|
|
1009
|
+
const { validateSeed } = await import("../validate-IGltez8n.mjs").then((n) => n.n);
|
|
865
1010
|
const seed = await loadSeed();
|
|
866
1011
|
if (validateSeed(seed).valid) {
|
|
867
1012
|
await applySeed(db, seed, { onConflict: "skip" });
|
|
@@ -892,17 +1037,73 @@ var EmDashRuntime = class EmDashRuntime {
|
|
|
892
1037
|
return storage;
|
|
893
1038
|
}
|
|
894
1039
|
/**
|
|
1040
|
+
* Load sandboxed plugin entries as trusted in-process plugins.
|
|
1041
|
+
* Used by the sandbox: false debugging escape hatch.
|
|
1042
|
+
*
|
|
1043
|
+
* Imports each plugin's bundled ESM code via a data URL, adapts it
|
|
1044
|
+
* with adaptSandboxEntry, and returns ResolvedPlugin objects ready
|
|
1045
|
+
* to be merged into the pipeline plugin list.
|
|
1046
|
+
*/
|
|
1047
|
+
static async loadBypassedPlugins(entries) {
|
|
1048
|
+
const { adaptSandboxEntry } = await import("../plugins/adapt-sandbox-entry.mjs");
|
|
1049
|
+
const plugins = [];
|
|
1050
|
+
for (const entry of entries) try {
|
|
1051
|
+
const pluginModule = await import(`data:text/javascript;base64,${Buffer.from(entry.code).toString("base64")}`);
|
|
1052
|
+
const pluginDef = pluginModule.default ?? pluginModule;
|
|
1053
|
+
const adminPages = entry.adminPages?.map((p) => ({
|
|
1054
|
+
path: p.path,
|
|
1055
|
+
label: p.label ?? p.path,
|
|
1056
|
+
icon: p.icon
|
|
1057
|
+
}));
|
|
1058
|
+
const adminWidgets = entry.adminWidgets?.map((w) => {
|
|
1059
|
+
const size = w.size === "full" || w.size === "half" || w.size === "third" ? w.size : void 0;
|
|
1060
|
+
return {
|
|
1061
|
+
id: w.id,
|
|
1062
|
+
title: w.title,
|
|
1063
|
+
size
|
|
1064
|
+
};
|
|
1065
|
+
});
|
|
1066
|
+
const resolved = adaptSandboxEntry(pluginDef, {
|
|
1067
|
+
id: entry.id,
|
|
1068
|
+
version: entry.version,
|
|
1069
|
+
entrypoint: "",
|
|
1070
|
+
capabilities: entry.capabilities,
|
|
1071
|
+
allowedHosts: entry.allowedHosts,
|
|
1072
|
+
storage: entry.storage,
|
|
1073
|
+
adminPages,
|
|
1074
|
+
adminWidgets
|
|
1075
|
+
});
|
|
1076
|
+
plugins.push(resolved);
|
|
1077
|
+
console.log(`EmDash: Loaded plugin ${entry.id}:${entry.version} in-process (sandbox bypassed)`);
|
|
1078
|
+
} catch (error) {
|
|
1079
|
+
console.error(`EmDash: Failed to load sandboxed plugin ${entry.id} in-process:`, error);
|
|
1080
|
+
}
|
|
1081
|
+
return plugins;
|
|
1082
|
+
}
|
|
1083
|
+
/**
|
|
895
1084
|
* Load sandboxed plugins using SandboxRunner
|
|
896
1085
|
*/
|
|
897
|
-
static async loadSandboxedPlugins(deps, db) {
|
|
1086
|
+
static async loadSandboxedPlugins(deps, db, mediaStorage) {
|
|
898
1087
|
if (sandboxedPluginCache.size > 0) return sandboxedPluginCache;
|
|
899
|
-
if (!deps.sandboxEnabled
|
|
900
|
-
if (!sandboxRunner && deps.createSandboxRunner) sandboxRunner = deps.createSandboxRunner({
|
|
1088
|
+
if (!deps.sandboxEnabled) return sandboxedPluginCache;
|
|
1089
|
+
if (!sandboxRunner && deps.createSandboxRunner) sandboxRunner = deps.createSandboxRunner({
|
|
1090
|
+
db,
|
|
1091
|
+
mediaStorage: mediaStorage ? {
|
|
1092
|
+
upload: (opts) => mediaStorage.upload({
|
|
1093
|
+
key: opts.key,
|
|
1094
|
+
body: opts.body,
|
|
1095
|
+
contentType: opts.contentType
|
|
1096
|
+
}),
|
|
1097
|
+
delete: (key) => mediaStorage.delete(key)
|
|
1098
|
+
} : void 0
|
|
1099
|
+
});
|
|
901
1100
|
if (!sandboxRunner) return sandboxedPluginCache;
|
|
902
1101
|
if (!sandboxRunner.isAvailable()) {
|
|
903
|
-
console.
|
|
1102
|
+
console.warn("EmDash: Plugin sandbox is configured but not available on this platform. Sandboxed plugins will not be loaded. If using @emdash-cms/sandbox-workerd/sandbox, ensure workerd is installed.");
|
|
904
1103
|
return sandboxedPluginCache;
|
|
905
1104
|
}
|
|
1105
|
+
if (deps.sandboxedPluginEntries.length === 0) return sandboxedPluginCache;
|
|
1106
|
+
if (deps.sandboxBypassed) return sandboxedPluginCache;
|
|
906
1107
|
for (const entry of deps.sandboxedPluginEntries) {
|
|
907
1108
|
const pluginKey = `${entry.id}:${entry.version}`;
|
|
908
1109
|
if (sandboxedPluginCache.has(pluginKey)) continue;
|
|
@@ -941,7 +1142,18 @@ var EmDashRuntime = class EmDashRuntime {
|
|
|
941
1142
|
* demand after install / update / uninstall handlers.
|
|
942
1143
|
*/
|
|
943
1144
|
static async loadInstalledSandboxedPlugins(source, db, storage, deps, cache) {
|
|
944
|
-
if (!sandboxRunner && deps.createSandboxRunner) sandboxRunner = deps.createSandboxRunner({
|
|
1145
|
+
if (!sandboxRunner && deps.createSandboxRunner) sandboxRunner = deps.createSandboxRunner({
|
|
1146
|
+
db,
|
|
1147
|
+
mediaStorage: {
|
|
1148
|
+
upload: (opts) => storage.upload({
|
|
1149
|
+
key: opts.key,
|
|
1150
|
+
body: opts.body,
|
|
1151
|
+
contentType: opts.contentType
|
|
1152
|
+
}),
|
|
1153
|
+
delete: (key) => storage.delete(key)
|
|
1154
|
+
}
|
|
1155
|
+
});
|
|
1156
|
+
if (deps.sandboxBypassed) return;
|
|
945
1157
|
if (!sandboxRunner || !sandboxRunner.isAvailable()) return;
|
|
946
1158
|
const keySet = source === "marketplace" ? marketplacePluginKeys : registryPluginKeys;
|
|
947
1159
|
try {
|
|
@@ -982,6 +1194,72 @@ var EmDashRuntime = class EmDashRuntime {
|
|
|
982
1194
|
} catch {}
|
|
983
1195
|
}
|
|
984
1196
|
/**
|
|
1197
|
+
* Cold-start: load marketplace plugins in bypass mode (sandbox: false).
|
|
1198
|
+
*
|
|
1199
|
+
* Each active marketplace bundle is read, evaluated via data URL, adapted
|
|
1200
|
+
* with adaptSandboxEntry, and returned as a ResolvedPlugin. The caller is
|
|
1201
|
+
* responsible for merging these into allPipelinePlugins / configuredPlugins
|
|
1202
|
+
* BEFORE the hook pipeline is created, so hooks and routes register in
|
|
1203
|
+
* the trusted pipeline.
|
|
1204
|
+
*
|
|
1205
|
+
* Also caches manifest and route metadata so admin UI / getManifest() work.
|
|
1206
|
+
*
|
|
1207
|
+
* Returns ResolvedPlugins to be merged into the pipeline.
|
|
1208
|
+
*/
|
|
1209
|
+
static async loadMarketplacePluginsBypassed(db, storage) {
|
|
1210
|
+
const resolved = [];
|
|
1211
|
+
try {
|
|
1212
|
+
const marketplacePlugins = await new PluginStateRepository(db).getMarketplacePlugins();
|
|
1213
|
+
if (marketplacePlugins.length === 0) return resolved;
|
|
1214
|
+
console.info("EmDash: Sandbox disabled (sandbox: false). Marketplace plugins will run in-process without isolation.");
|
|
1215
|
+
const { adaptSandboxEntry } = await import("../plugins/adapt-sandbox-entry.mjs");
|
|
1216
|
+
for (const plugin of marketplacePlugins) {
|
|
1217
|
+
if (plugin.status !== "active") continue;
|
|
1218
|
+
const version = plugin.marketplaceVersion ?? plugin.version;
|
|
1219
|
+
try {
|
|
1220
|
+
const bundle = await loadBundleFromR2(storage, plugin.pluginId, version);
|
|
1221
|
+
if (!bundle) {
|
|
1222
|
+
console.warn(`EmDash: Marketplace plugin ${plugin.pluginId}@${version} not found in R2`);
|
|
1223
|
+
continue;
|
|
1224
|
+
}
|
|
1225
|
+
marketplaceManifestCache.set(plugin.pluginId, {
|
|
1226
|
+
id: bundle.manifest.id,
|
|
1227
|
+
version: bundle.manifest.version,
|
|
1228
|
+
admin: bundle.manifest.admin
|
|
1229
|
+
});
|
|
1230
|
+
if (bundle.manifest.routes.length > 0) {
|
|
1231
|
+
const routeMeta = /* @__PURE__ */ new Map();
|
|
1232
|
+
for (const entry of bundle.manifest.routes) {
|
|
1233
|
+
const normalized = normalizeManifestRoute(entry);
|
|
1234
|
+
routeMeta.set(normalized.name, { public: normalized.public === true });
|
|
1235
|
+
}
|
|
1236
|
+
sandboxedRouteMetaCache.set(plugin.pluginId, routeMeta);
|
|
1237
|
+
}
|
|
1238
|
+
const pluginModule = await import(`data:text/javascript;base64,${Buffer.from(bundle.backendCode).toString("base64")}`);
|
|
1239
|
+
const adapted = adaptSandboxEntry(pluginModule.default ?? pluginModule, {
|
|
1240
|
+
id: bundle.manifest.id,
|
|
1241
|
+
version: bundle.manifest.version,
|
|
1242
|
+
entrypoint: "",
|
|
1243
|
+
capabilities: bundle.manifest.capabilities ?? [],
|
|
1244
|
+
allowedHosts: bundle.manifest.allowedHosts ?? [],
|
|
1245
|
+
storage: bundle.manifest.storage ?? {},
|
|
1246
|
+
adminPages: bundle.manifest.admin?.pages,
|
|
1247
|
+
adminWidgets: bundle.manifest.admin?.widgets?.map((w) => ({
|
|
1248
|
+
id: w.id,
|
|
1249
|
+
title: w.title,
|
|
1250
|
+
size: w.size === "full" || w.size === "half" || w.size === "third" ? w.size : void 0
|
|
1251
|
+
}))
|
|
1252
|
+
});
|
|
1253
|
+
resolved.push(adapted);
|
|
1254
|
+
console.log(`EmDash: Loaded marketplace plugin ${plugin.pluginId}@${version} in-process (sandbox bypassed)`);
|
|
1255
|
+
} catch (error) {
|
|
1256
|
+
console.error(`EmDash: Failed to load marketplace plugin ${plugin.pluginId} in-process:`, error);
|
|
1257
|
+
}
|
|
1258
|
+
}
|
|
1259
|
+
} catch {}
|
|
1260
|
+
return resolved;
|
|
1261
|
+
}
|
|
1262
|
+
/**
|
|
985
1263
|
* Resolve exclusive hook selections on startup.
|
|
986
1264
|
*
|
|
987
1265
|
* Delegates to the shared resolveExclusiveHooks() in hooks.ts.
|
|
@@ -1147,6 +1425,7 @@ var EmDashRuntime = class EmDashRuntime {
|
|
|
1147
1425
|
return {
|
|
1148
1426
|
version: VERSION,
|
|
1149
1427
|
commit: COMMIT,
|
|
1428
|
+
astroVersion: this.config.astroVersion,
|
|
1150
1429
|
hash: manifestHash,
|
|
1151
1430
|
collections: manifestCollections,
|
|
1152
1431
|
plugins: manifestPlugins,
|
|
@@ -1259,7 +1538,7 @@ var EmDashRuntime = class EmDashRuntime {
|
|
|
1259
1538
|
if (this.hooks.hasHooks("content:beforeSave")) processedData = (await this.hooks.runContentBeforeSave(body.data, collection, true)).content;
|
|
1260
1539
|
processedData = await this.runSandboxedBeforeSave(processedData, collection, true);
|
|
1261
1540
|
processedData = await this.normalizeMediaFields(collection, processedData);
|
|
1262
|
-
const { validateContentData } = await import("../validation-
|
|
1541
|
+
const { validateContentData } = await import("../validation-Bmymau7y.mjs");
|
|
1263
1542
|
const validation = await validateContentData(this.db, collection, processedData, { partial: false });
|
|
1264
1543
|
if (!validation.ok) return {
|
|
1265
1544
|
success: false,
|
|
@@ -1275,7 +1554,7 @@ var EmDashRuntime = class EmDashRuntime {
|
|
|
1275
1554
|
return result;
|
|
1276
1555
|
}
|
|
1277
1556
|
async handleContentUpdate(collection, id, body) {
|
|
1278
|
-
const { ContentRepository } = await import("../content-
|
|
1557
|
+
const { ContentRepository } = await import("../content-8voQNTXX.mjs").then((n) => n.n);
|
|
1279
1558
|
const repo = new ContentRepository(this.db);
|
|
1280
1559
|
const resolvedItem = await repo.findByIdOrSlug(collection, id);
|
|
1281
1560
|
const resolvedId = resolvedItem?.id ?? id;
|
|
@@ -1302,7 +1581,7 @@ var EmDashRuntime = class EmDashRuntime {
|
|
|
1302
1581
|
if (this.hooks.hasHooks("content:beforeSave")) processedData = (await this.hooks.runContentBeforeSave(bodyWithoutRev.data, collection, false)).content;
|
|
1303
1582
|
processedData = await this.runSandboxedBeforeSave(processedData, collection, false);
|
|
1304
1583
|
processedData = await this.normalizeMediaFields(collection, processedData);
|
|
1305
|
-
const { validateContentData } = await import("../validation-
|
|
1584
|
+
const { validateContentData } = await import("../validation-Bmymau7y.mjs");
|
|
1306
1585
|
const validation = await validateContentData(this.db, collection, processedData, { partial: true });
|
|
1307
1586
|
if (!validation.ok) return {
|
|
1308
1587
|
success: false,
|
|
@@ -1842,6 +2121,24 @@ function createPublicMediaUrlResolver(storage) {
|
|
|
1842
2121
|
return (key) => resolvePublicMediaUrl(storage, key);
|
|
1843
2122
|
}
|
|
1844
2123
|
|
|
2124
|
+
//#endregion
|
|
2125
|
+
//#region src/astro/public-plugin-api-routes.ts
|
|
2126
|
+
function pluginRouteNotFound() {
|
|
2127
|
+
return {
|
|
2128
|
+
success: false,
|
|
2129
|
+
error: {
|
|
2130
|
+
code: "NOT_FOUND",
|
|
2131
|
+
message: "Plugin route not found"
|
|
2132
|
+
}
|
|
2133
|
+
};
|
|
2134
|
+
}
|
|
2135
|
+
function createPublicPluginApiRouteHandler(runtime) {
|
|
2136
|
+
return async (pluginId, method, path, request) => {
|
|
2137
|
+
if (runtime.getPluginRouteMeta(pluginId, path)?.public !== true) return pluginRouteNotFound();
|
|
2138
|
+
return runtime.handlePluginApiRoute(pluginId, method, path, request);
|
|
2139
|
+
};
|
|
2140
|
+
}
|
|
2141
|
+
|
|
1845
2142
|
//#endregion
|
|
1846
2143
|
//#region src/astro/middleware.ts
|
|
1847
2144
|
/**
|
|
@@ -1888,14 +2185,16 @@ function getPlugins() {
|
|
|
1888
2185
|
* Build runtime dependencies from virtual modules
|
|
1889
2186
|
*/
|
|
1890
2187
|
function buildDependencies(config) {
|
|
2188
|
+
const sandboxModule = virtualSandboxRunnerModule;
|
|
1891
2189
|
return {
|
|
1892
2190
|
config,
|
|
1893
2191
|
plugins: getPlugins(),
|
|
1894
2192
|
createDialect,
|
|
1895
2193
|
createStorage,
|
|
1896
|
-
sandboxEnabled,
|
|
2194
|
+
sandboxEnabled: sandboxModule.sandboxEnabled,
|
|
2195
|
+
sandboxBypassed: sandboxModule.sandboxBypassed ?? false,
|
|
1897
2196
|
sandboxedPluginEntries: sandboxedPlugins || [],
|
|
1898
|
-
createSandboxRunner,
|
|
2197
|
+
createSandboxRunner: sandboxModule.createSandboxRunner,
|
|
1899
2198
|
mediaProviderEntries: mediaProviders || []
|
|
1900
2199
|
};
|
|
1901
2200
|
}
|
|
@@ -2027,7 +2326,7 @@ const onRequest = defineMiddleware(async (context, next) => {
|
|
|
2027
2326
|
if (!setupVerified) {
|
|
2028
2327
|
const t0 = performance.now();
|
|
2029
2328
|
try {
|
|
2030
|
-
const { getDb } = await import("../loader-
|
|
2329
|
+
const { getDb } = await import("../loader-D-vIJjfY.mjs").then((n) => n.i);
|
|
2031
2330
|
await (await getDb()).selectFrom("_emdash_migrations").selectAll().limit(1).execute();
|
|
2032
2331
|
setupVerified = true;
|
|
2033
2332
|
} catch {
|
|
@@ -2047,6 +2346,7 @@ const onRequest = defineMiddleware(async (context, next) => {
|
|
|
2047
2346
|
const runtime = await getRuntime(config, initSubTimings);
|
|
2048
2347
|
setupVerified = true;
|
|
2049
2348
|
locals.emdash = {
|
|
2349
|
+
handlePublicPluginApiRoute: createPublicPluginApiRouteHandler(runtime),
|
|
2050
2350
|
collectPageMetadata: runtime.collectPageMetadata.bind(runtime),
|
|
2051
2351
|
collectPageFragments: runtime.collectPageFragments.bind(runtime),
|
|
2052
2352
|
getPublicMediaUrl: createPublicMediaUrlResolver(runtime.storage)
|
|
@@ -2148,6 +2448,7 @@ const onRequest = defineMiddleware(async (context, next) => {
|
|
|
2148
2448
|
handleRevisionGet: runtime.handleRevisionGet.bind(runtime),
|
|
2149
2449
|
handleRevisionRestore: runtime.handleRevisionRestore.bind(runtime),
|
|
2150
2450
|
handlePluginApiRoute: runtime.handlePluginApiRoute.bind(runtime),
|
|
2451
|
+
handlePublicPluginApiRoute: createPublicPluginApiRouteHandler(runtime),
|
|
2151
2452
|
getPluginRouteMeta: runtime.getPluginRouteMeta.bind(runtime),
|
|
2152
2453
|
getMediaProvider: runtime.getMediaProvider.bind(runtime),
|
|
2153
2454
|
getMediaProviderList: runtime.getMediaProviderList.bind(runtime),
|
|
@@ -2164,6 +2465,7 @@ const onRequest = defineMiddleware(async (context, next) => {
|
|
|
2164
2465
|
getManifest: runtime.getManifest.bind(runtime),
|
|
2165
2466
|
invalidateUrlPatternCache,
|
|
2166
2467
|
getSandboxRunner: runtime.getSandboxRunner.bind(runtime),
|
|
2468
|
+
isSandboxBypassed: runtime.isSandboxBypassed.bind(runtime),
|
|
2167
2469
|
syncMarketplacePlugins: runtime.syncMarketplacePlugins.bind(runtime),
|
|
2168
2470
|
syncRegistryPlugins: runtime.syncRegistryPlugins.bind(runtime),
|
|
2169
2471
|
setPluginStatus: runtime.setPluginStatus.bind(runtime)
|