dineway 0.2.9 → 0.2.10
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 +3 -3
- package/dist/api/schemas/index.d.mts +1 -1
- package/dist/{api-C7JRPcb8.mjs → api-CD8BB0ZV.mjs} +5 -5
- package/dist/{apply-DHT0l398.mjs → apply-qf-XwOhN.mjs} +9 -9
- package/dist/astro/index.d.mts +2 -2
- package/dist/astro/index.mjs +2 -2
- package/dist/astro/middleware/auth.d.mts +2 -2
- package/dist/astro/middleware/auth.mjs +2 -2
- package/dist/astro/middleware/setup.mjs +1 -1
- package/dist/astro/middleware.mjs +29 -29
- package/dist/astro/routes/api/admin/briefing.mjs +4 -4
- package/dist/astro/routes/api/admin/byline-fields/_slug_/usage.mjs +2 -2
- package/dist/astro/routes/api/admin/byline-fields/_slug_.mjs +2 -2
- package/dist/astro/routes/api/admin/byline-fields/index.mjs +2 -2
- package/dist/astro/routes/api/admin/byline-fields/reorder.mjs +2 -2
- package/dist/astro/routes/api/admin/bylines/_id_/index.mjs +5 -5
- package/dist/astro/routes/api/admin/bylines/_id_/translations.mjs +5 -5
- package/dist/astro/routes/api/admin/bylines/index.mjs +5 -5
- package/dist/astro/routes/api/admin/context/_id_/history.mjs +8 -8
- package/dist/astro/routes/api/admin/context/_id_/index.mjs +8 -8
- package/dist/astro/routes/api/admin/context/_id_/review.mjs +8 -8
- package/dist/astro/routes/api/admin/context/_id_/supersede.mjs +8 -8
- package/dist/astro/routes/api/admin/context/diff.mjs +8 -8
- package/dist/astro/routes/api/admin/context/index.mjs +8 -8
- package/dist/astro/routes/api/admin/context/stale.mjs +8 -8
- package/dist/astro/routes/api/admin/hitl-requests/_id_/index.mjs +9 -9
- package/dist/astro/routes/api/admin/hitl-requests/_id_/resolve.mjs +9 -9
- package/dist/astro/routes/api/admin/hitl-requests/index.mjs +9 -9
- package/dist/astro/routes/api/admin/hooks/exclusive/_hookName_.mjs +8 -8
- package/dist/astro/routes/api/admin/plugins/_id_/disable.mjs +18 -18
- package/dist/astro/routes/api/admin/plugins/_id_/enable.mjs +18 -18
- package/dist/astro/routes/api/admin/plugins/_id_/index.mjs +16 -16
- package/dist/astro/routes/api/admin/plugins/_id_/uninstall.mjs +18 -18
- package/dist/astro/routes/api/admin/plugins/_id_/update.mjs +18 -18
- package/dist/astro/routes/api/admin/plugins/index.mjs +16 -16
- package/dist/astro/routes/api/admin/plugins/marketplace/_id_/index.mjs +16 -16
- package/dist/astro/routes/api/admin/plugins/marketplace/_id_/install.mjs +18 -18
- package/dist/astro/routes/api/admin/plugins/marketplace/index.mjs +16 -16
- package/dist/astro/routes/api/admin/plugins/updates.mjs +16 -16
- package/dist/astro/routes/api/admin/review-requests/_id_/resolve.mjs +7 -7
- package/dist/astro/routes/api/admin/review-requests/index.mjs +7 -7
- package/dist/astro/routes/api/admin/themes/marketplace/_id_/index.mjs +16 -16
- package/dist/astro/routes/api/admin/themes/marketplace/index.mjs +16 -16
- package/dist/astro/routes/api/admin/users/_id_/disable.mjs +1 -1
- package/dist/astro/routes/api/admin/users/_id_/index.mjs +1 -1
- package/dist/astro/routes/api/auth/invite/complete.mjs +2 -2
- package/dist/astro/routes/api/auth/invite/register-options.mjs +1 -1
- package/dist/astro/routes/api/auth/mode.mjs +1 -1
- package/dist/astro/routes/api/auth/passkey/options.mjs +1 -1
- package/dist/astro/routes/api/auth/passkey/register/options.mjs +1 -1
- package/dist/astro/routes/api/auth/passkey/register/verify.mjs +2 -2
- package/dist/astro/routes/api/auth/passkey/verify.mjs +2 -2
- package/dist/astro/routes/api/auth/signup/complete.mjs +2 -2
- package/dist/astro/routes/api/content/_collection_/_id_/terms/_taxonomy_.mjs +1 -1
- package/dist/astro/routes/api/health.mjs +1 -1
- package/dist/astro/routes/api/import/probe.mjs +2 -2
- package/dist/astro/routes/api/import/wordpress/analyze.mjs +2 -2
- package/dist/astro/routes/api/import/wordpress/execute.d.mts +2 -2
- package/dist/astro/routes/api/import/wordpress/execute.mjs +13 -13
- package/dist/astro/routes/api/import/wordpress/media.d.mts +2 -2
- package/dist/astro/routes/api/import/wordpress/prepare.mjs +9 -9
- package/dist/astro/routes/api/import/wordpress/rewrite-urls.d.mts +2 -2
- package/dist/astro/routes/api/import/wordpress/rewrite-urls.mjs +9 -9
- package/dist/astro/routes/api/import/wordpress-plugin/analyze.mjs +4 -4
- package/dist/astro/routes/api/import/wordpress-plugin/execute.d.mts +2 -2
- package/dist/astro/routes/api/import/wordpress-plugin/execute.mjs +14 -14
- package/dist/astro/routes/api/manifest.mjs +2 -2
- package/dist/astro/routes/api/mcp.mjs +36 -36
- package/dist/astro/routes/api/menus/_name_/items/_id_.mjs +9 -9
- package/dist/astro/routes/api/menus/_name_/items.mjs +9 -9
- package/dist/astro/routes/api/menus/_name_/reorder.mjs +9 -9
- package/dist/astro/routes/api/menus/_name_/translations.mjs +9 -9
- package/dist/astro/routes/api/menus/_name_.mjs +9 -9
- package/dist/astro/routes/api/menus/index.mjs +9 -9
- package/dist/astro/routes/api/oauth/authorize.mjs +1 -1
- package/dist/astro/routes/api/oauth/device/authorize.mjs +1 -1
- package/dist/astro/routes/api/oauth/device/code.mjs +1 -1
- package/dist/astro/routes/api/oauth/device/token.mjs +1 -1
- package/dist/astro/routes/api/oauth/token/refresh.mjs +1 -1
- package/dist/astro/routes/api/oauth/token/revoke.mjs +1 -1
- package/dist/astro/routes/api/oauth/token.mjs +2 -2
- package/dist/astro/routes/api/openapi.json.mjs +1 -1
- package/dist/astro/routes/api/redirects/_id_.mjs +8 -8
- package/dist/astro/routes/api/redirects/index.mjs +8 -8
- package/dist/astro/routes/api/schema/collections/_slug_/fields/_fieldSlug_.mjs +16 -16
- package/dist/astro/routes/api/schema/collections/_slug_/fields/index.mjs +16 -16
- package/dist/astro/routes/api/schema/collections/_slug_/fields/reorder.mjs +16 -16
- package/dist/astro/routes/api/schema/collections/_slug_/index.mjs +16 -16
- package/dist/astro/routes/api/schema/collections/index.mjs +16 -16
- package/dist/astro/routes/api/schema/index.mjs +3 -3
- package/dist/astro/routes/api/schema/orphans/_slug_.mjs +16 -16
- package/dist/astro/routes/api/schema/orphans/index.mjs +16 -16
- package/dist/astro/routes/api/sections/_slug_.mjs +8 -8
- package/dist/astro/routes/api/sections/index.mjs +8 -8
- package/dist/astro/routes/api/settings.mjs +8 -8
- package/dist/astro/routes/api/setup/admin-verify.mjs +3 -3
- package/dist/astro/routes/api/setup/admin.mjs +1 -1
- package/dist/astro/routes/api/setup/dev-bypass.mjs +6 -6
- package/dist/astro/routes/api/setup/index.mjs +7 -7
- package/dist/astro/routes/api/setup/status.mjs +1 -1
- package/dist/astro/routes/api/snapshot.mjs +1 -1
- package/dist/astro/routes/api/taxonomies/_name_/terms/_slug_/translations.mjs +10 -10
- package/dist/astro/routes/api/taxonomies/_name_/terms/_slug_.mjs +10 -10
- package/dist/astro/routes/api/taxonomies/_name_/terms/index.mjs +10 -10
- package/dist/astro/routes/api/taxonomies/index.mjs +10 -10
- package/dist/astro/routes/api/typegen.mjs +3 -3
- package/dist/astro/routes/api/well-known/auth.mjs +2 -2
- package/dist/astro/routes/api/widget-areas/_name_/reorder.mjs +8 -8
- 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 +8 -8
- package/dist/astro/routes/api/widget-areas/index.mjs +8 -8
- package/dist/astro/types.d.mts +2 -2
- package/dist/{briefing-Cl70iEH5.mjs → briefing-CFzam-BE.mjs} +1 -1
- package/dist/{briefing-GFhLTLJo.mjs → briefing-Cv2LqGVN.mjs} +2 -2
- package/dist/{byline-fields-EiCArEIw.d.mts → byline-fields-BsWnSt2u.d.mts} +24 -24
- package/dist/{byline-fields-BKzA0fJU.mjs → byline-fields-sE9SQsDR.mjs} +1 -1
- package/dist/{byline-registry-Ba54M74c.mjs → byline-registry-BLgrU3dA.mjs} +1 -1
- package/dist/{byline-BJa1MyKB.mjs → byline-v4kKt4I0.mjs} +2 -2
- package/dist/{bylines-kixFoaRV.mjs → bylines-BKBCEwd1.mjs} +2 -2
- package/dist/{bylines-B53Saxdb.mjs → bylines-C8ugKJ2i.mjs} +1 -1
- package/dist/cli/index.mjs +7 -7
- package/dist/cli/plugin-kit.d.mts +2 -2
- package/dist/client/index.d.mts +2 -2
- package/dist/{content-refresh-BmkilU5M.mjs → content-refresh-CLMQRcgP.mjs} +1 -1
- package/dist/{context-BQ8O8pqD.mjs → context-CwDkm8os.mjs} +2 -2
- package/dist/{context-DT0tIsfw.mjs → context-DyEG-k2A.mjs} +2 -2
- package/dist/{device-flow-BKKeobcV.mjs → device-flow-BWV1ZxXW.mjs} +1 -1
- package/dist/{field-defs-cache-CiXP3eO3.mjs → field-defs-cache-BBsAQm7W.mjs} +1 -1
- package/dist/{hitl-requests-01Xe2FfD.mjs → hitl-requests-BhyCwUO7.mjs} +1 -1
- package/dist/{hitl-route-helpers-vdROIary.mjs → hitl-route-helpers-Dg6bo7c6.mjs} +1 -1
- package/dist/{import-C-zxnT89.mjs → import-BPQs0pH4.mjs} +1 -1
- package/dist/index.d.mts +3 -3
- package/dist/index.mjs +25 -25
- package/dist/{jsonld-gtuFB5dA.d.mts → jsonld-B-cQE9w9.d.mts} +1 -1
- package/dist/{mcp-reviewed-executor-BCR-Pgtg.mjs → mcp-reviewed-executor-CrszK61Z.mjs} +1 -1
- package/dist/media/local-runtime.d.mts +2 -2
- package/dist/{menus-LYALU2Mf.mjs → menus-DWPsv6p3.mjs} +1 -1
- package/dist/{oauth-authorization-CX7aa8Ph.mjs → oauth-authorization-fiXxn7FY.mjs} +1 -1
- package/dist/page/index.d.mts +3 -3
- package/dist/plugin-utils.d.mts +2 -2
- package/dist/plugins/adapt-sandbox-entry.d.mts +2 -2
- package/dist/{plugins-B7-4Okii.mjs → plugins-mHPWInmx.mjs} +1 -1
- package/dist/{public-url-D85-Z75C.d.mts → public-url-CDPGkO9J.d.mts} +1 -1
- package/dist/{query-C_m8sn-S.mjs → query-BGxz5wby.mjs} +5 -5
- package/dist/{query-DNczixZr.mjs → query-DDvG2G6h.mjs} +1 -1
- package/dist/{registry-SEJqFliS.mjs → registry-BlVA2gpN.mjs} +2 -2
- package/dist/runtime.d.mts +2 -2
- package/dist/{schema-Dk_N31V4.mjs → schema-C457D4_h.mjs} +1 -1
- package/dist/seed/index.mjs +6 -6
- package/dist/{site-context-qU_bKUMe.mjs → site-context-Boxwy7OY.mjs} +2 -2
- package/dist/{taxonomies-DuhGjBa8.mjs → taxonomies-BbC4z9PY.mjs} +1 -1
- package/dist/{taxonomies-WVnFki0o.mjs → taxonomies-sgdAKC-b.mjs} +1 -1
- package/dist/{transaction-0LEAAy8R.mjs → transaction-Chz7SBGr.mjs} +1 -0
- package/dist/{types-DGwUpjba.d.mts → types-B0FjqDWk.d.mts} +240 -4
- package/dist/ui/server-runtime.d.mts +4 -4
- package/dist/ui/server-runtime.mjs +5 -5
- package/dist/version-DYBm3PuU.mjs +6 -0
- package/dist/{zod-generator-Cr3SiHsc.mjs → zod-generator-DJdduinu.mjs} +140 -2
- package/package.json +2 -2
- package/dist/version-B1dQFnul.mjs +0 -6
- /package/dist/{allowed-origins-oVgzR3X5.mjs → allowed-origins-VLgv2PL1.mjs} +0 -0
- /package/dist/{challenge-store-DtdQHXf5.mjs → challenge-store-BMkL2kmt.mjs} +0 -0
- /package/dist/{mode-DqpBaEOy.mjs → mode-DPC7segX.mjs} +0 -0
- /package/dist/{session-user-CYjNeJoD.mjs → session-user-BwliEFp0.mjs} +0 -0
- /package/dist/{setup-complete-DcAQzVsB.mjs → setup-complete-PvF8I7Oh.mjs} +0 -0
|
@@ -2667,6 +2667,31 @@ type SiteContextType = (typeof SITE_CONTEXT_TYPES)[number];
|
|
|
2667
2667
|
//#endregion
|
|
2668
2668
|
//#region src/site-context/briefing.d.ts
|
|
2669
2669
|
type SiteBriefingScopeType = "site" | "collection" | "content" | "plugin" | "plugin_extension" | "taxonomy" | "menu";
|
|
2670
|
+
type SiteBriefingSectionStatus = "included" | "omitted" | "not_available";
|
|
2671
|
+
interface SiteBriefingInput {
|
|
2672
|
+
scope?: string;
|
|
2673
|
+
since?: string;
|
|
2674
|
+
contextTypes?: string[];
|
|
2675
|
+
includeStale?: boolean;
|
|
2676
|
+
format?: "json" | "text";
|
|
2677
|
+
tokenBudget?: number;
|
|
2678
|
+
activityLimit?: number;
|
|
2679
|
+
}
|
|
2680
|
+
interface SiteBriefingPermissions {
|
|
2681
|
+
canReadContent: boolean;
|
|
2682
|
+
canReadSchema: boolean;
|
|
2683
|
+
canReadSettings: boolean;
|
|
2684
|
+
canReadPlugins: boolean;
|
|
2685
|
+
}
|
|
2686
|
+
interface SiteBriefingAssemblerOptions {
|
|
2687
|
+
db: Kysely<Database>;
|
|
2688
|
+
storage?: Storage | null;
|
|
2689
|
+
configuredPlugins?: ResolvedPlugin[];
|
|
2690
|
+
sandboxedPluginEntries?: SandboxedPluginEntry[];
|
|
2691
|
+
marketplaceUrl?: string;
|
|
2692
|
+
permissions?: Partial<SiteBriefingPermissions>;
|
|
2693
|
+
now?: Date;
|
|
2694
|
+
}
|
|
2670
2695
|
interface ParsedSiteBriefingScope {
|
|
2671
2696
|
type: SiteBriefingScopeType;
|
|
2672
2697
|
scope: string;
|
|
@@ -2677,6 +2702,205 @@ interface ParsedSiteBriefingScope {
|
|
|
2677
2702
|
taxonomyId?: string;
|
|
2678
2703
|
menuId?: string;
|
|
2679
2704
|
}
|
|
2705
|
+
interface SiteBriefingCollection {
|
|
2706
|
+
slug: string;
|
|
2707
|
+
label: string;
|
|
2708
|
+
labelSingular?: string;
|
|
2709
|
+
description?: string;
|
|
2710
|
+
supports: string[];
|
|
2711
|
+
hasSeo: boolean;
|
|
2712
|
+
urlPattern?: string;
|
|
2713
|
+
comments: {
|
|
2714
|
+
enabled: boolean;
|
|
2715
|
+
moderation: string;
|
|
2716
|
+
closedAfterDays: number;
|
|
2717
|
+
autoApproveUsers: boolean;
|
|
2718
|
+
};
|
|
2719
|
+
fields: SiteBriefingField[];
|
|
2720
|
+
}
|
|
2721
|
+
interface SiteBriefingField {
|
|
2722
|
+
slug: string;
|
|
2723
|
+
label: string;
|
|
2724
|
+
type: string;
|
|
2725
|
+
required: boolean;
|
|
2726
|
+
unique: boolean;
|
|
2727
|
+
searchable: boolean;
|
|
2728
|
+
translatable: boolean;
|
|
2729
|
+
referenceCollection?: string;
|
|
2730
|
+
}
|
|
2731
|
+
interface SiteBriefingActivity {
|
|
2732
|
+
id: string;
|
|
2733
|
+
actionType: string;
|
|
2734
|
+
subjectType: string;
|
|
2735
|
+
subjectId: string | null;
|
|
2736
|
+
relatedSubjectType: string | null;
|
|
2737
|
+
relatedSubjectId: string | null;
|
|
2738
|
+
sourceType: string | null;
|
|
2739
|
+
sourceName: string | null;
|
|
2740
|
+
resultStatus: string;
|
|
2741
|
+
scope: string;
|
|
2742
|
+
summary: string;
|
|
2743
|
+
actorType: string;
|
|
2744
|
+
actorId: string;
|
|
2745
|
+
detail: Record<string, unknown> | null;
|
|
2746
|
+
createdAt: string;
|
|
2747
|
+
}
|
|
2748
|
+
interface SiteBriefingContextEntry {
|
|
2749
|
+
id: string;
|
|
2750
|
+
scope: string;
|
|
2751
|
+
contextType: SiteContextType;
|
|
2752
|
+
title: string;
|
|
2753
|
+
body: string;
|
|
2754
|
+
policyKey: string | null;
|
|
2755
|
+
supersedesId: string | null;
|
|
2756
|
+
version: number;
|
|
2757
|
+
validUntil: string | null;
|
|
2758
|
+
reviewedAt: string | null;
|
|
2759
|
+
tags: string[];
|
|
2760
|
+
updatedAt: string;
|
|
2761
|
+
}
|
|
2762
|
+
interface SiteBriefingContextGroup {
|
|
2763
|
+
contextType: SiteContextType;
|
|
2764
|
+
items: SiteBriefingContextEntry[];
|
|
2765
|
+
}
|
|
2766
|
+
interface SiteBriefingStaleWarning {
|
|
2767
|
+
id: string;
|
|
2768
|
+
scope: string;
|
|
2769
|
+
contextType: SiteContextType;
|
|
2770
|
+
title: string;
|
|
2771
|
+
policyKey: string | null;
|
|
2772
|
+
validUntil: string | null;
|
|
2773
|
+
reviewedAt: string | null;
|
|
2774
|
+
updatedAt: string;
|
|
2775
|
+
}
|
|
2776
|
+
interface SiteBriefingPlugin {
|
|
2777
|
+
id: string;
|
|
2778
|
+
name: string;
|
|
2779
|
+
version: string;
|
|
2780
|
+
status: string;
|
|
2781
|
+
capabilities: string[];
|
|
2782
|
+
hasAdminPages: boolean;
|
|
2783
|
+
hasDashboardWidgets: boolean;
|
|
2784
|
+
hasHooks: boolean;
|
|
2785
|
+
}
|
|
2786
|
+
interface SiteBriefingSettings {
|
|
2787
|
+
title?: string;
|
|
2788
|
+
tagline?: string;
|
|
2789
|
+
url?: string;
|
|
2790
|
+
timezone?: string;
|
|
2791
|
+
dateFormat?: string;
|
|
2792
|
+
postsPerPage?: number;
|
|
2793
|
+
branding: {
|
|
2794
|
+
logoConfigured: boolean;
|
|
2795
|
+
faviconConfigured: boolean;
|
|
2796
|
+
};
|
|
2797
|
+
socialChannels: string[];
|
|
2798
|
+
seo: {
|
|
2799
|
+
titleSeparator?: string;
|
|
2800
|
+
defaultOgImageConfigured: boolean;
|
|
2801
|
+
robotsTxtConfigured: boolean;
|
|
2802
|
+
googleVerificationConfigured: boolean;
|
|
2803
|
+
bingVerificationConfigured: boolean;
|
|
2804
|
+
};
|
|
2805
|
+
}
|
|
2806
|
+
interface SiteBriefingReviewRequest {
|
|
2807
|
+
id: string;
|
|
2808
|
+
status: "pending" | "approved" | "rejected";
|
|
2809
|
+
scope: string;
|
|
2810
|
+
collection: string;
|
|
2811
|
+
entryId: string;
|
|
2812
|
+
actionType: string;
|
|
2813
|
+
riskReason: string | null;
|
|
2814
|
+
summary: string | null;
|
|
2815
|
+
liveRevisionId: string | null;
|
|
2816
|
+
draftRevisionId: string | null;
|
|
2817
|
+
reviewedRev: string;
|
|
2818
|
+
actionHash: string;
|
|
2819
|
+
requestedByActorType: string;
|
|
2820
|
+
requestedByActorId: string;
|
|
2821
|
+
createdAt: string;
|
|
2822
|
+
updatedAt: string;
|
|
2823
|
+
}
|
|
2824
|
+
interface SiteBriefingSection<T> {
|
|
2825
|
+
status: SiteBriefingSectionStatus;
|
|
2826
|
+
reason?: string;
|
|
2827
|
+
data: T;
|
|
2828
|
+
truncated?: boolean;
|
|
2829
|
+
tokenEstimate: number;
|
|
2830
|
+
}
|
|
2831
|
+
interface SiteBriefing {
|
|
2832
|
+
kind: "site_briefing";
|
|
2833
|
+
generatedAt: string;
|
|
2834
|
+
scope: {
|
|
2835
|
+
requested: string;
|
|
2836
|
+
resolved: string;
|
|
2837
|
+
type: SiteBriefingScopeType;
|
|
2838
|
+
ancestors: string[];
|
|
2839
|
+
collection?: string;
|
|
2840
|
+
contentId?: string;
|
|
2841
|
+
pluginId?: string;
|
|
2842
|
+
taxonomyId?: string;
|
|
2843
|
+
menuId?: string;
|
|
2844
|
+
};
|
|
2845
|
+
since: string | null;
|
|
2846
|
+
contextTypes: string[];
|
|
2847
|
+
tokenBudget: number;
|
|
2848
|
+
tokenEstimate: number;
|
|
2849
|
+
truncated: boolean;
|
|
2850
|
+
packing: Array<{
|
|
2851
|
+
section: keyof SiteBriefing["sections"];
|
|
2852
|
+
priority: number;
|
|
2853
|
+
status: SiteBriefingSectionStatus;
|
|
2854
|
+
truncated: boolean;
|
|
2855
|
+
reason?: string;
|
|
2856
|
+
}>;
|
|
2857
|
+
sections: {
|
|
2858
|
+
schema: SiteBriefingSection<{
|
|
2859
|
+
collections: SiteBriefingCollection[];
|
|
2860
|
+
currentCollection?: SiteBriefingCollection;
|
|
2861
|
+
}>;
|
|
2862
|
+
contextEntries: SiteBriefingSection<{
|
|
2863
|
+
groups: SiteBriefingContextGroup[];
|
|
2864
|
+
scopes: string[];
|
|
2865
|
+
}>;
|
|
2866
|
+
activity: SiteBriefingSection<{
|
|
2867
|
+
scopes: string[];
|
|
2868
|
+
items: SiteBriefingActivity[];
|
|
2869
|
+
}>;
|
|
2870
|
+
plugins: SiteBriefingSection<{
|
|
2871
|
+
active: SiteBriefingPlugin[];
|
|
2872
|
+
}>;
|
|
2873
|
+
settings: SiteBriefingSection<SiteBriefingSettings | null>;
|
|
2874
|
+
staleWarnings: SiteBriefingSection<{
|
|
2875
|
+
scopes: string[];
|
|
2876
|
+
items: SiteBriefingStaleWarning[];
|
|
2877
|
+
}>;
|
|
2878
|
+
reviewRequests: SiteBriefingSection<{
|
|
2879
|
+
scopes: string[];
|
|
2880
|
+
items: SiteBriefingReviewRequest[];
|
|
2881
|
+
}>;
|
|
2882
|
+
};
|
|
2883
|
+
}
|
|
2884
|
+
declare class SiteBriefingAssembler {
|
|
2885
|
+
private readonly db;
|
|
2886
|
+
private readonly storage;
|
|
2887
|
+
private readonly configuredPlugins;
|
|
2888
|
+
private readonly sandboxedPluginEntries;
|
|
2889
|
+
private readonly marketplaceUrl?;
|
|
2890
|
+
private readonly permissions;
|
|
2891
|
+
private readonly now;
|
|
2892
|
+
constructor(options: SiteBriefingAssemblerOptions);
|
|
2893
|
+
assemble(input?: SiteBriefingInput): Promise<SiteBriefing>;
|
|
2894
|
+
private loadSchemaSection;
|
|
2895
|
+
private loadAllCollections;
|
|
2896
|
+
private loadContextEntriesSection;
|
|
2897
|
+
private loadActivitySection;
|
|
2898
|
+
private loadPluginSection;
|
|
2899
|
+
private loadSettingsSection;
|
|
2900
|
+
private loadStaleWarningsSection;
|
|
2901
|
+
private loadReviewRequestsSection;
|
|
2902
|
+
private canIncludeActivity;
|
|
2903
|
+
}
|
|
2680
2904
|
//#endregion
|
|
2681
2905
|
//#region src/site-context/review-payload.d.ts
|
|
2682
2906
|
interface ContentReviewHandlers {
|
|
@@ -2984,6 +3208,18 @@ declare class SchemaRegistry {
|
|
|
2984
3208
|
*/
|
|
2985
3209
|
declare function getCollectionInfo(slug: string): Promise<Collection | null>;
|
|
2986
3210
|
//#endregion
|
|
3211
|
+
//#region src/schema/zod-generator.d.ts
|
|
3212
|
+
/**
|
|
3213
|
+
* Validate data against a collection's schema
|
|
3214
|
+
*/
|
|
3215
|
+
declare function validateContent(collection: CollectionWithFields, data: unknown): {
|
|
3216
|
+
success: true;
|
|
3217
|
+
data: unknown;
|
|
3218
|
+
} | {
|
|
3219
|
+
success: false;
|
|
3220
|
+
errors: z$1.ZodError;
|
|
3221
|
+
};
|
|
3222
|
+
//#endregion
|
|
2987
3223
|
//#region src/sections/types.d.ts
|
|
2988
3224
|
/**
|
|
2989
3225
|
* Section source types
|
|
@@ -4183,14 +4419,14 @@ declare const pluginManifestSchema: z$1.ZodObject<{
|
|
|
4183
4419
|
string: "string";
|
|
4184
4420
|
number: "number";
|
|
4185
4421
|
boolean: "boolean";
|
|
4186
|
-
json: "json";
|
|
4187
4422
|
file: "file";
|
|
4423
|
+
json: "json";
|
|
4188
4424
|
slug: "slug";
|
|
4189
|
-
text: "text";
|
|
4190
|
-
select: "select";
|
|
4191
4425
|
image: "image";
|
|
4192
4426
|
datetime: "datetime";
|
|
4427
|
+
text: "text";
|
|
4193
4428
|
integer: "integer";
|
|
4429
|
+
select: "select";
|
|
4194
4430
|
multiSelect: "multiSelect";
|
|
4195
4431
|
portableText: "portableText";
|
|
4196
4432
|
reference: "reference";
|
|
@@ -7367,4 +7603,4 @@ interface PluginManifest {
|
|
|
7367
7603
|
admin: PluginAdminConfig;
|
|
7368
7604
|
}
|
|
7369
7605
|
//#endregion
|
|
7370
|
-
export { PluginMcpReversibility as $, EmailPipeline as $a, GuestAccessExpectedScope as $i, AppliedSnapshotMeta as $n, AssignmentActorType as $o, SessionCleanupResult as $r, SearchOptions as $t, PageMetadataLinkRel as A, CreateSectionInput as Aa, AfterCallback as Ai, getBylineBySlug as An, handleContentPermanentDelete as Ao, BuiltContentReleasePayload as Ar, ParseResult as As, isStandardPluginDefinition as At, PluginDefinition as B, handleMediaCreate as Ba, ResolvePathResult as Bi, UpdateMenuInput as Bn, image as Bo, createPluginManager as Br, FieldDescriptor as Bs, PublicationReleasePolicy as Bt, ModerationDecision as C, PortableTextTextBlock as Ca, invalidateCollectionCache as Ci, getTermsForEntries as Cn, handleContentDelete as Co, CreateWorkflowAssignmentInput as Cr, WhereValue$1 as Cs, StandardHookHandler as Ct, PageMetadataContribution as D, ProseMirrorNode as Da, invalidateSchemaObjectCache as Di, TaxonomyTermRow as Dn, handleContentGetIncludingTrashed as Do, CreateHandoffSnapshotInput as Dr, DinewayDatabaseError as Ds, StorageCollection as Dt, PageFragmentHandler as E, ProseMirrorMark as Ea, invalidateObjectCache as Ei, TaxonomyTerm as En, handleContentGet as Eo, ResumeHandoffSnapshotInput as Er, DatabaseConfig as Es, StandardRouteHandler as Et, PluginAdminExports as F, getCollectionInfo as Fa, ContentEntry as Fi, CreateMenuItemInput as Fn, handleContentUnpublish as Fo, createNodeSandboxRunner as Fr, apiSuccess as Fs, PublicationReadinessPolicyFinding as Ft, PluginMcpCommandTool as G, RevisionListResponse as Ga, getEditMeta as Gi, getComments as Gn, PortableTextBlock$1 as Go, ValidatedPluginManifest as Gr, getSearchStats as Gt, PluginManifest as H, handleMediaGet as Ha, TranslationsResult as Hi, GetCommentsOptions as Hn, FieldUIHints as Ho, PluginSecretStatus as Hr, ManifestResponse as Hs, currentTimestamp as Ht, PluginAdminPage as I, SchemaError as Ia, DinewayCollections as Ii, Menu as In, handleContentUnschedule as Io, NoopSandboxRunner as Ir, handleError as Is, PublicationReadinessPolicyTarget as It, PluginMcpPiiClass as J, handleRevisionList as Ja, CMSAnnotation as Ji, getSiteSetting as Jn, Relation as Jo, definePlugin as Jr, searchCollection as Jt, PluginMcpConfig as K, RevisionResponse as Ka, getTranslations as Ki, getPluginSetting as Kn, ContentReference as Ko, pluginManifestSchema as Kr, getSuggestions as Kt, PluginAuthMethod as L, SchemaRegistry as La, EditFieldMeta as Li, MenuItem as Ln, handleContentUpdate as Lo, SandboxNotAvailableError as Lr, ApiContext as Ls, PublicationReadinessResult as Lt, PluginActor as M, Section as Ma, CacheHint as Mi, getMenu as Mn, handleContentRestore as Mo, PublicationReleasePolicyDisposition as Mr, parseBody as Ms, PublicationPolicyOverride as Mt, PluginActorType as N, SectionSource as Na, CollectionFilter as Ni, getMenus as Nn, handleContentSchedule as No, buildStableActionHash as Nr, parseQuery as Ns, PublicationReadinessBlocker as Nt, PageMetadataEvent as O, getSection as Oa, invalidateTaxonomyObjectCache as Oi, UpdateTermInput as On, handleContentList as Oo, HandoffSnapshot as Or, Element as Os, StorageCollectionConfig as Ot, PluginAdminConfig as P, UpdateSectionInput as Pa, CollectionResult as Pi, CreateMenuInput as Pn, handleContentTranslations as Po, NodeSandboxRunner as Pr, apiError as Ps, PublicationReadinessPolicyBlocker as Pt, PluginMcpResourceContent as Q, PluginRouteError as Qa, createNoop as Qi, renderPreviewToolbar as Qn, AssignmentActorRef as Qo, FileSessionDatabaseFactoryOptions as Qr, SearchConfig as Qt, PluginCapability as R, MediaListResponse as Ra, EntryResult as Ri, MenuItemType as Rn, portableText as Ro, createNoopSandboxRunner as Rr, ContentListResponse as Rs, PublicationReadinessWarning as Rt, MediaUploadEvent as S, PortableTextSpan as Sa, invalidateBylineObjectCache as Si, getTerm as Sn, handleContentCreate as So, AssignmentService as Sr, WhereRange as Ss, StandardHookEntry as St, PageFragmentEvent as T, ProseMirrorDocument as Ta, invalidateMenuObjectCache as Ti, TaxonomyDef as Tn, handleContentDuplicate as To, HandoffSnapshotStore as Tr, getDb as Ts, StandardRouteEntry as Tt, PluginMcpAuthorization as U, handleMediaList as Ua, getDinewayCollection as Ui, GetCommentsResult as Un, FileValue as Uo, PluginSecretStore as Ur, extractPlainText as Ut, PluginHooks as V, handleMediaDelete as Va, TranslationSummary as Vi, UpdateMenuItemInput as Vn, FieldDefinition as Vo, createReviewedPluginMcpCommandExecutor as Vr, ListResponse as Vs, PublicationReleasePreparationTarget as Vt, PluginMcpCommandPreview as W, handleMediaUpdate as Wa, getDinewayEntry as Wi, getCommentCount as Wn, ImageValue as Wo, PluginSecretStoreOptions as Wr, extractSearchableFields as Wt, PluginMcpQueryTool as X, generateManifest as Xa, FieldAnnotation as Xi, setSiteSettings as Xn, UpdateRelationInput as Xo, createFilePreviewMiddleware as Xr, FTSManager as Xt, PluginMcpPiiPolicy as Y, handleRevisionRestore as Ya, EditProxy as Yi, getSiteSettings as Yn, RelationRepository as Yo, FilePreviewMiddlewareConfig as Yr, searchWithDb as Yt, PluginMcpResource as Z, SandboxedPluginEntry as Za, createEditable as Zi, PreviewToolbarConfig as Zn, Assignment as Zo, FileSessionDatabaseFactory as Zr, CollectionSearchOptions as Zt, HookName as _, PortableTextCodeBlock as _a, CacheNamespace as _i, getEntriesByTerm as _n, StorageDescriptor as _o, parseContentId as _r, MediaRepository as _s, ResolvedHook as _t, CommentAfterModerateEvent as a, VerifyGuestAccessTokenResult as aa, SessionOpenOrCreateOptions as ai, getWidgetArea as an, SandboxOptions as ao, renderPreviewLoadingPage as ar, MarkAssignmentsOverdueInput as as, PluginRouteApiTokenPolicy as at, LogAccess as b, PortableTextLinkMark as ba, contentNamespace as bi, getTaxonomyDefs as bn, handleContentCountScheduled as bo, AssignmentActionInput as br, EntryData as bs, ResolvedPluginMcpConfig as bt, CommentBeforeCreateHandler as c, verifyGuestAccessToken as ca, buildPreviewSignatureHeader as ci, CreateWidgetAreaInput as cn, SandboxedPlugin as co, isPreviewRequest as cr, SiteActivityActorType as cs, PluginRouteMethod as ct, ContentAccess as d, isSafeHref as da, signPreviewUrl as di, ReorderWidgetsInput as dn, PluginMcpTargetAuthorizer$1 as do, getPreviewUrl as dr, SiteActivitySourceType as ds, PluginRouteTargetContext as dt, GuestAccessTokenClaims as ea, SessionDatabaseFactory as ei, SearchResponse as en, HookPipeline as eo, ApplySnapshotToDatabaseOptions as er, AssignmentListQuery as es, PluginMcpRiskFactor as et, ContentDeleteEvent as f, sanitizeHref as fa, verifyPreviewSignature as fi, UpdateWidgetInput as fn, DinewayConfig as fo, GeneratePreviewTokenOptions as fr, SiteActivityTimelineQuery as fs, PluginStorageConfig as ft, HookConfig as g, prosemirrorToPortableText as ga, isI18nEnabled as gi, WidgetType as gn, S3StorageConfig as go, generatePreviewToken as gr, MediaItem$1 as gs, PublicPageContext as gt, FieldWidgetConfig as h, portableTextToProsemirror as ha, getI18nConfig as hi, WidgetComponentDef as hn, LocalStorageConfig as ho, VerifyPreviewTokenResult as hr, CreateMediaInput as hs, PortableTextBlockField as ht, CommentAfterCreateHandler as i, VerifyGuestAccessTokenOptions as ia, SessionOpenOptions as ii, Suggestion as in, SandboxEmailSendCallback as io, Snapshot as ir, CreateAssignmentInput as is, PluginRoute as it, PagePlacement as j, GetSectionsOptions as ja, after as ji, getEntriesByByline as jn, handleContentPublish as jo, PublicationReleasePolicyContribution as jr, isParseError as js, PublicationAuthorizationService as jt, PageMetadataHandler as k, getSections as ka, isObjectCacheActive as ki, getByline as kn, handleContentListTrashed as ko, SiteAuthTokenContext as kr, OptionsRepository as ks, StoredComment as kt, CommentModerateEvent as l, RateLimitResult as la, defaultPreviewSidecarClient as li, CreateWidgetInput as ln, SerializedRequest as lo, GetPreviewUrlOptions as lr, SiteActivityRepository as ls, PluginRouteTargetAuthorizationRequest as lt, ContentPublishStateChangeEvent as m, hashString as ma, getFallbackChain as mi, WidgetArea as mn, getStoredConfig as mo, VerifyPreviewTokenOptions as mr, RevisionRepository as ms, PortableTextBlockConfig as mt, CollectionCommentSettings as n, IssueGuestAccessTokenOptions as na, SessionDatabaseInfo as ni, SearchStats as nn, createHookPipeline as no, dropSessionDatabaseTables as nr, AssignmentRepository as ns, PluginMcpTool as nt, CommentAfterModerateHandler as o, hashGuestAccessToken as oa, PreviewSidecarClient as oi, getWidgetAreas as on, SandboxRunner as oo, isBlockedInPreview as or, CreateSiteActivityInput as os, PluginRouteAuthorization as ot, ContentHookEvent as p, computeContentHash as pa, I18nConfig as pi, Widget as pn, PluginDescriptor as po, PreviewTokenPayload as pr, PublicComment as ps, PluginTargetScope as pt, PluginMcpExecutionContext as q, handleRevisionGet as qa, resolveDinewayPath as qi, getPluginSettings as qn, CreateRelationInput as qo, runPluginMigrations as qr, search as qt, CommentAfterCreateEvent as r, IssuedGuestAccessToken as ra, SessionDatabaseLimitError as ri, SuggestOptions as rn, SandboxEmailMessage as ro, getAppliedSnapshotMeta as rr, AssignmentStatus as rs, PluginMigration as rt, CommentBeforeCreateEvent as s, issueGuestAccessToken as sa, PreviewSidecarSignature as si, getWidgetComponents as sn, SandboxRunnerFactory as so, getPreviewToken as sr, SiteActivity as ss, PluginRouteBodyMode as st, BreadcrumbItem as t, GuestAccessTokenConfigurationError as ta, SessionDatabaseHandle as ti, SearchResult as tn, HookResult as to, applySnapshotToDatabase as tr, AssignmentPriority as ts, PluginMcpRiskLevel as tt, CommentModerateHandler as u, checkRateLimit as ua, parsePreviewSignatureHeader as ui, PropDef as un, PluginMcpRegistry as uo, buildPreviewUrl as ur, SiteActivityResultStatus as us, PluginRouteTargetAuthorizer as ut, HttpAccess as v, PortableTextHtmlBlock as va, CachedQueryOptions as vi, getEntryTerms as vn, handleContentAuthors as vo, verifyPreviewToken as vr, ContentRepository as vs, ResolvedPlugin as vt, PageFragmentContribution as w, PortableTextUnknownBlock as wa, invalidateCommentObjectCache as wi, CreateTermInput as wn, handleContentDiscardDraft as wo, HandoffResumeResult as wr, dinewayLoader as ws, StandardPluginDefinition as wt, MediaAccess as x, PortableTextMarkDef as xa, contentNamespaces as xi, getTaxonomyTerms as xn, handleContentCountTrashed as xo, AssignmentListInput as xr, EntryFilter as xs, RouteContext as xt, KVAccess as y, PortableTextImageBlock as ya, cachedQuery as yi, getTaxonomyDef as yn, handleContentCompare as yo, AssignmentAccessContext as yr, CollectionFilter$1 as ys, ResolvedPluginHooks as yt, PluginContext as z, MediaResponse as za, InferCollectionData as zi, ReorderMenuItemsInput as zn, reference as zo, PluginManager as zr, ContentResponse as zs, PublicationReceipt as zt };
|
|
7606
|
+
export { PluginMcpReversibility as $, SiteBriefingAssembler as $a, GuestAccessExpectedScope as $i, AppliedSnapshotMeta as $n, RelationRepository as $o, SessionCleanupResult as $r, SearchOptions as $t, PageMetadataLinkRel as A, CreateSectionInput as Aa, AfterCallback as Ai, getBylineBySlug as An, handleContentGet as Ao, BuiltContentReleasePayload as Ar, DatabaseConfig as As, isStandardPluginDefinition as At, PluginDefinition as B, MediaResponse as Ba, ResolvePathResult as Bi, UpdateMenuInput as Bn, handleContentUnschedule as Bo, createPluginManager as Br, handleError as Bs, PublicationReleasePolicy as Bt, ModerationDecision as C, PortableTextTextBlock as Ca, invalidateCollectionCache as Ci, getTermsForEntries as Cn, handleContentCompare as Co, CreateWorkflowAssignmentInput as Cr, CollectionFilter$1 as Cs, StandardHookHandler as Ct, PageMetadataContribution as D, ProseMirrorNode as Da, invalidateSchemaObjectCache as Di, TaxonomyTermRow as Dn, handleContentDelete as Do, CreateHandoffSnapshotInput as Dr, WhereValue$1 as Ds, StorageCollection as Dt, PageFragmentHandler as E, ProseMirrorMark as Ea, invalidateObjectCache as Ei, TaxonomyTerm as En, handleContentCreate as Eo, ResumeHandoffSnapshotInput as Er, WhereRange as Es, StandardRouteHandler as Et, PluginAdminExports as F, validateContent as Fa, ContentEntry as Fi, CreateMenuItemInput as Fn, handleContentPublish as Fo, createNodeSandboxRunner as Fr, isParseError as Fs, PublicationReadinessPolicyFinding as Ft, PluginMcpCommandTool as G, handleMediaUpdate as Ga, getEditMeta as Gi, getComments as Gn, FieldDefinition as Go, ValidatedPluginManifest as Gr, ListResponse as Gs, getSearchStats as Gt, PluginManifest as H, handleMediaDelete as Ha, TranslationsResult as Hi, GetCommentsOptions as Hn, portableText as Ho, PluginSecretStatus as Hr, ContentListResponse as Hs, currentTimestamp as Ht, PluginAdminPage as I, getCollectionInfo as Ia, DinewayCollections as Ii, Menu as In, handleContentRestore as Io, NoopSandboxRunner as Ir, parseBody as Is, PublicationReadinessPolicyTarget as It, PluginMcpPiiClass as J, handleRevisionGet as Ja, CMSAnnotation as Ji, getSiteSetting as Jn, ImageValue as Jo, definePlugin as Jr, searchCollection as Jt, PluginMcpConfig as K, RevisionListResponse as Ka, getTranslations as Ki, getPluginSetting as Kn, FieldUIHints as Ko, pluginManifestSchema as Kr, ManifestResponse as Ks, getSuggestions as Kt, PluginAuthMethod as L, SchemaError as La, EditFieldMeta as Li, MenuItem as Ln, handleContentSchedule as Lo, SandboxNotAvailableError as Lr, parseQuery as Ls, PublicationReadinessResult as Lt, PluginActor as M, Section as Ma, CacheHint as Mi, getMenu as Mn, handleContentList as Mo, PublicationReleasePolicyDisposition as Mr, Element as Ms, PublicationPolicyOverride as Mt, PluginActorType as N, SectionSource as Na, CollectionFilter as Ni, getMenus as Nn, handleContentListTrashed as No, buildStableActionHash as Nr, OptionsRepository as Ns, PublicationReadinessBlocker as Nt, PageMetadataEvent as O, getSection as Oa, invalidateTaxonomyObjectCache as Oi, UpdateTermInput as On, handleContentDiscardDraft as Oo, HandoffSnapshot as Or, dinewayLoader as Os, StorageCollectionConfig as Ot, PluginAdminConfig as P, UpdateSectionInput as Pa, CollectionResult as Pi, CreateMenuInput as Pn, handleContentPermanentDelete as Po, NodeSandboxRunner as Pr, ParseResult as Ps, PublicationReadinessPolicyBlocker as Pt, PluginMcpResourceContent as Q, SiteBriefing as Qa, createNoop as Qi, renderPreviewToolbar as Qn, Relation as Qo, FileSessionDatabaseFactoryOptions as Qr, SearchConfig as Qt, PluginCapability as R, SchemaRegistry as Ra, EntryResult as Ri, MenuItemType as Rn, handleContentTranslations as Ro, createNoopSandboxRunner as Rr, apiError as Rs, PublicationReadinessWarning as Rt, MediaUploadEvent as S, PortableTextSpan as Sa, invalidateBylineObjectCache as Si, getTerm as Sn, handleContentAuthors as So, AssignmentService as Sr, ContentRepository as Ss, StandardHookEntry as St, PageFragmentEvent as T, ProseMirrorDocument as Ta, invalidateMenuObjectCache as Ti, TaxonomyDef as Tn, handleContentCountTrashed as To, HandoffSnapshotStore as Tr, EntryFilter as Ts, StandardRouteEntry as Tt, PluginMcpAuthorization as U, handleMediaGet as Ua, getDinewayCollection as Ui, GetCommentsResult as Un, reference as Uo, PluginSecretStore as Ur, ContentResponse as Us, extractPlainText as Ut, PluginHooks as V, handleMediaCreate as Va, TranslationSummary as Vi, UpdateMenuItemInput as Vn, handleContentUpdate as Vo, createReviewedPluginMcpCommandExecutor as Vr, ApiContext as Vs, PublicationReleasePreparationTarget as Vt, PluginMcpCommandPreview as W, handleMediaList as Wa, getDinewayEntry as Wi, getCommentCount as Wn, image as Wo, PluginSecretStoreOptions as Wr, FieldDescriptor as Ws, extractSearchableFields as Wt, PluginMcpQueryTool as X, handleRevisionRestore as Xa, FieldAnnotation as Xi, setSiteSettings as Xn, ContentReference as Xo, createFilePreviewMiddleware as Xr, FTSManager as Xt, PluginMcpPiiPolicy as Y, handleRevisionList as Ya, EditProxy as Yi, getSiteSettings as Yn, PortableTextBlock$1 as Yo, FilePreviewMiddlewareConfig as Yr, searchWithDb as Yt, PluginMcpResource as Z, generateManifest as Za, createEditable as Zi, PreviewToolbarConfig as Zn, CreateRelationInput as Zo, FileSessionDatabaseFactory as Zr, CollectionSearchOptions as Zt, HookName as _, PortableTextCodeBlock as _a, CacheNamespace as _i, getEntriesByTerm as _n, PluginDescriptor as _o, parseContentId as _r, PublicComment as _s, ResolvedHook as _t, CommentAfterModerateEvent as a, VerifyGuestAccessTokenResult as aa, SessionOpenOrCreateOptions as ai, getWidgetArea as an, HookResult as ao, renderPreviewLoadingPage as ar, AssignmentPriority as as, PluginRouteApiTokenPolicy as at, LogAccess as b, PortableTextLinkMark as ba, contentNamespace as bi, getTaxonomyDefs as bn, S3StorageConfig as bo, AssignmentActionInput as br, MediaItem$1 as bs, ResolvedPluginMcpConfig as bt, CommentBeforeCreateHandler as c, verifyGuestAccessToken as ca, buildPreviewSignatureHeader as ci, CreateWidgetAreaInput as cn, SandboxEmailSendCallback as co, isPreviewRequest as cr, CreateAssignmentInput as cs, PluginRouteMethod as ct, ContentAccess as d, isSafeHref as da, signPreviewUrl as di, ReorderWidgetsInput as dn, SandboxRunnerFactory as do, getPreviewUrl as dr, SiteActivity as ds, PluginRouteTargetContext as dt, GuestAccessTokenClaims as ea, SessionDatabaseFactory as ei, SearchResponse as en, SiteBriefingContextEntry as eo, ApplySnapshotToDatabaseOptions as er, UpdateRelationInput as es, PluginMcpRiskFactor as et, ContentDeleteEvent as f, sanitizeHref as fa, verifyPreviewSignature as fi, UpdateWidgetInput as fn, SandboxedPlugin as fo, GeneratePreviewTokenOptions as fr, SiteActivityActorType as fs, PluginStorageConfig as ft, HookConfig as g, prosemirrorToPortableText as ga, isI18nEnabled as gi, WidgetType as gn, DinewayConfig as go, generatePreviewToken as gr, SiteActivityTimelineQuery as gs, PublicPageContext as gt, FieldWidgetConfig as h, portableTextToProsemirror as ha, getI18nConfig as hi, WidgetComponentDef as hn, PluginMcpTargetAuthorizer$1 as ho, VerifyPreviewTokenResult as hr, SiteActivitySourceType as hs, PortableTextBlockField as ht, CommentAfterCreateHandler as i, VerifyGuestAccessTokenOptions as ia, SessionOpenOptions as ii, Suggestion as in, HookPipeline as io, Snapshot as ir, AssignmentListQuery as is, PluginRoute as it, PagePlacement as j, GetSectionsOptions as ja, after as ji, getEntriesByByline as jn, handleContentGetIncludingTrashed as jo, PublicationReleasePolicyContribution as jr, DinewayDatabaseError as js, PublicationAuthorizationService as jt, PageMetadataHandler as k, getSections as ka, isObjectCacheActive as ki, getByline as kn, handleContentDuplicate as ko, SiteAuthTokenContext as kr, getDb as ks, StoredComment as kt, CommentModerateEvent as l, RateLimitResult as la, defaultPreviewSidecarClient as li, CreateWidgetInput as ln, SandboxOptions as lo, GetPreviewUrlOptions as lr, MarkAssignmentsOverdueInput as ls, PluginRouteTargetAuthorizationRequest as lt, ContentPublishStateChangeEvent as m, hashString as ma, getFallbackChain as mi, WidgetArea as mn, PluginMcpRegistry as mo, VerifyPreviewTokenOptions as mr, SiteActivityResultStatus as ms, PortableTextBlockConfig as mt, CollectionCommentSettings as n, IssueGuestAccessTokenOptions as na, SessionDatabaseInfo as ni, SearchStats as nn, PluginRouteError as no, dropSessionDatabaseTables as nr, AssignmentActorRef as ns, PluginMcpTool as nt, CommentAfterModerateHandler as o, hashGuestAccessToken as oa, PreviewSidecarClient as oi, getWidgetAreas as on, createHookPipeline as oo, isBlockedInPreview as or, AssignmentRepository as os, PluginRouteAuthorization as ot, ContentHookEvent as p, computeContentHash as pa, I18nConfig as pi, Widget as pn, SerializedRequest as po, PreviewTokenPayload as pr, SiteActivityRepository as ps, PluginTargetScope as pt, PluginMcpExecutionContext as q, RevisionResponse as qa, resolveDinewayPath as qi, getPluginSettings as qn, FileValue as qo, runPluginMigrations as qr, search as qt, CommentAfterCreateEvent as r, IssuedGuestAccessToken as ra, SessionDatabaseLimitError as ri, SuggestOptions as rn, EmailPipeline as ro, getAppliedSnapshotMeta as rr, AssignmentActorType as rs, PluginMigration as rt, CommentBeforeCreateEvent as s, issueGuestAccessToken as sa, PreviewSidecarSignature as si, getWidgetComponents as sn, SandboxEmailMessage as so, getPreviewToken as sr, AssignmentStatus as ss, PluginRouteBodyMode as st, BreadcrumbItem as t, GuestAccessTokenConfigurationError as ta, SessionDatabaseHandle as ti, SearchResult as tn, SandboxedPluginEntry as to, applySnapshotToDatabase as tr, Assignment as ts, PluginMcpRiskLevel as tt, CommentModerateHandler as u, checkRateLimit as ua, parsePreviewSignatureHeader as ui, PropDef as un, SandboxRunner as uo, buildPreviewUrl as ur, CreateSiteActivityInput as us, PluginRouteTargetAuthorizer as ut, HttpAccess as v, PortableTextHtmlBlock as va, CachedQueryOptions as vi, getEntryTerms as vn, getStoredConfig as vo, verifyPreviewToken as vr, RevisionRepository as vs, ResolvedPlugin as vt, PageFragmentContribution as w, PortableTextUnknownBlock as wa, invalidateCommentObjectCache as wi, CreateTermInput as wn, handleContentCountScheduled as wo, HandoffResumeResult as wr, EntryData as ws, StandardPluginDefinition as wt, MediaAccess as x, PortableTextMarkDef as xa, contentNamespaces as xi, getTaxonomyTerms as xn, StorageDescriptor as xo, AssignmentListInput as xr, MediaRepository as xs, RouteContext as xt, KVAccess as y, PortableTextImageBlock as ya, cachedQuery as yi, getTaxonomyDef as yn, LocalStorageConfig as yo, AssignmentAccessContext as yr, CreateMediaInput as ys, ResolvedPluginHooks as yt, PluginContext as z, MediaListResponse as za, InferCollectionData as zi, ReorderMenuItemsInput as zn, handleContentUnpublish as zo, PluginManager as zr, apiSuccess as zs, PublicationReceipt as zt };
|
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import { D as PageMetadataContribution,
|
|
1
|
+
import { D as PageMetadataContribution, Gi as getEditMeta, Gn as getComments, Ia as getCollectionInfo, Mn as getMenu, Ui as getDinewayCollection, Yn as getSiteSettings, _s as PublicComment, an as getWidgetArea, fa as sanitizeHref, gt as PublicPageContext, pn as Widget, xn as getTaxonomyTerms } from "../types-B0FjqDWk.mjs";
|
|
2
2
|
import "../types-BFeoAIHl.mjs";
|
|
3
3
|
import { _ as MediaValue, c as EmbedResult, l as ImageEmbed, s as EmbedOptions } from "../placeholder-C6ZjZcmJ.mjs";
|
|
4
4
|
import "../runner-Bcy5w0vj.mjs";
|
|
5
5
|
import "../index-DybFmYtZ.mjs";
|
|
6
6
|
import "../types-S9VIopdY.mjs";
|
|
7
7
|
import { x as MediaReference } from "../validate-YiX3rly5.mjs";
|
|
8
|
-
import "../byline-fields-
|
|
8
|
+
import "../byline-fields-BsWnSt2u.mjs";
|
|
9
9
|
import "../types-BsTXSvKG.mjs";
|
|
10
|
-
import { t as getPublicOrigin } from "../public-url-
|
|
11
|
-
import { a as generateSiteSeoContributions, c as ResolvedPageMetadata, d as renderPageMetadata, f as resolvePageMetadata, i as generateBaseSeoContributions, l as createSha256CspHash, o as renderFragments } from "../jsonld-
|
|
10
|
+
import { t as getPublicOrigin } from "../public-url-CDPGkO9J.mjs";
|
|
11
|
+
import { a as generateSiteSeoContributions, c as ResolvedPageMetadata, d as renderPageMetadata, f as resolvePageMetadata, i as generateBaseSeoContributions, l as createSha256CspHash, o as renderFragments } from "../jsonld-B-cQE9w9.mjs";
|
|
12
12
|
import { getPageRuntime } from "../page/index.mjs";
|
|
13
13
|
import { t as getMediaProvider } from "../provider-loader-Db-pJFu3.mjs";
|
|
14
14
|
|
|
@@ -7,16 +7,16 @@ import "../media-B4m-cnmj.mjs";
|
|
|
7
7
|
import "../comment-B88XcvU1.mjs";
|
|
8
8
|
import "../options-DQPTH5n0.mjs";
|
|
9
9
|
import "../request-cache-CBFjCwSt.mjs";
|
|
10
|
-
import "../content-refresh-
|
|
10
|
+
import "../content-refresh-CLMQRcgP.mjs";
|
|
11
11
|
import "../fts-manager-Zo9uhGel.mjs";
|
|
12
|
-
import "../registry-
|
|
12
|
+
import "../registry-BlVA2gpN.mjs";
|
|
13
13
|
import { n as buildRenderMediaUrl } from "../url-guoXQQcV.mjs";
|
|
14
14
|
import { i as getSiteSettings } from "../settings-SVDAB7_W.mjs";
|
|
15
|
-
import { t as getCollectionInfo } from "../query-
|
|
15
|
+
import { t as getCollectionInfo } from "../query-DDvG2G6h.mjs";
|
|
16
16
|
import "../resolve-B6BpqwAR.mjs";
|
|
17
|
-
import { a as getTaxonomyTerms } from "../taxonomies-
|
|
17
|
+
import { a as getTaxonomyTerms } from "../taxonomies-sgdAKC-b.mjs";
|
|
18
18
|
import { n as sanitizeHref } from "../url-D282S1Zw.mjs";
|
|
19
|
-
import { r as getEditMeta, t as getDinewayCollection } from "../query-
|
|
19
|
+
import { r as getEditMeta, t as getDinewayCollection } from "../query-BGxz5wby.mjs";
|
|
20
20
|
import "../comment-reaction-Ckn6vCmB.mjs";
|
|
21
21
|
import { i as getComments, t as getMenu } from "../menus-oYfViqfE.mjs";
|
|
22
22
|
import { t as getWidgetArea } from "../widgets-DyGcotPM.mjs";
|
|
@@ -4,14 +4,152 @@ import { z } from "zod";
|
|
|
4
4
|
|
|
5
5
|
//#region src/schema/zod-generator.ts
|
|
6
6
|
var zod_generator_exports = /* @__PURE__ */ __exportAll({
|
|
7
|
+
generateFieldSchema: () => generateFieldSchema,
|
|
7
8
|
generateSchemaHash: () => generateSchemaHash,
|
|
8
9
|
generateTypeScript: () => generateTypeScript,
|
|
9
10
|
generateTypesFile: () => generateTypesFile,
|
|
10
|
-
|
|
11
|
+
generateZodSchema: () => generateZodSchema,
|
|
12
|
+
getCachedSchema: () => getCachedSchema,
|
|
13
|
+
uniqueInterfaceNames: () => uniqueInterfaceNames,
|
|
14
|
+
validateContent: () => validateContent
|
|
11
15
|
});
|
|
12
16
|
/** Pattern to split on underscores, hyphens, and spaces for PascalCase conversion */
|
|
13
17
|
const PASCAL_CASE_SPLIT_PATTERN = /[_\-\s]+/;
|
|
14
18
|
/**
|
|
19
|
+
* Generate a Zod schema from a collection's field definitions
|
|
20
|
+
*
|
|
21
|
+
* This allows runtime validation of content based on dynamically
|
|
22
|
+
* defined schemas stored in the database.
|
|
23
|
+
*/
|
|
24
|
+
function generateZodSchema(collection) {
|
|
25
|
+
const shape = {};
|
|
26
|
+
for (const field of collection.fields) shape[field.slug] = generateFieldSchema(field);
|
|
27
|
+
return z.object(shape);
|
|
28
|
+
}
|
|
29
|
+
/**
|
|
30
|
+
* Generate Zod schema for a single field
|
|
31
|
+
*/
|
|
32
|
+
function generateFieldSchema(field) {
|
|
33
|
+
let schema = getBaseSchema(field.type, field);
|
|
34
|
+
if (field.validation) schema = applyValidation(schema, field);
|
|
35
|
+
if (!field.required) schema = schema.nullish();
|
|
36
|
+
if (field.defaultValue !== void 0) schema = schema.default(field.defaultValue);
|
|
37
|
+
return schema;
|
|
38
|
+
}
|
|
39
|
+
/**
|
|
40
|
+
* Get base Zod schema for a field type
|
|
41
|
+
*/
|
|
42
|
+
function getBaseSchema(type, field) {
|
|
43
|
+
switch (type) {
|
|
44
|
+
case "string":
|
|
45
|
+
case "text":
|
|
46
|
+
case "slug": return z.string();
|
|
47
|
+
case "url": return z.string().url();
|
|
48
|
+
case "number": return z.number();
|
|
49
|
+
case "integer": return z.number().int();
|
|
50
|
+
case "boolean": return z.preprocess((value) => value === 0 || value === 1 ? Boolean(value) : value, z.boolean());
|
|
51
|
+
case "datetime": return z.iso.datetime({
|
|
52
|
+
offset: true,
|
|
53
|
+
local: true
|
|
54
|
+
}).or(z.iso.date());
|
|
55
|
+
case "select": {
|
|
56
|
+
const options = field.validation?.options;
|
|
57
|
+
if (options && options.length > 0) {
|
|
58
|
+
const [first, ...rest] = options;
|
|
59
|
+
return z.enum([first, ...rest]);
|
|
60
|
+
}
|
|
61
|
+
return z.string();
|
|
62
|
+
}
|
|
63
|
+
case "multiSelect": {
|
|
64
|
+
const multiOptions = field.validation?.options;
|
|
65
|
+
if (multiOptions && multiOptions.length > 0) {
|
|
66
|
+
const [first, ...rest] = multiOptions;
|
|
67
|
+
return z.array(z.enum([first, ...rest]));
|
|
68
|
+
}
|
|
69
|
+
return z.array(z.string());
|
|
70
|
+
}
|
|
71
|
+
case "portableText": return z.array(z.object({
|
|
72
|
+
_type: z.string(),
|
|
73
|
+
_key: z.string().optional()
|
|
74
|
+
}).passthrough());
|
|
75
|
+
case "image": return z.object({
|
|
76
|
+
id: z.string(),
|
|
77
|
+
src: z.string().optional(),
|
|
78
|
+
alt: z.string().optional(),
|
|
79
|
+
width: z.number().optional(),
|
|
80
|
+
height: z.number().optional(),
|
|
81
|
+
provider: z.string().optional(),
|
|
82
|
+
previewUrl: z.string().optional(),
|
|
83
|
+
meta: z.record(z.string(), z.unknown()).optional()
|
|
84
|
+
});
|
|
85
|
+
case "file": return z.object({
|
|
86
|
+
id: z.string(),
|
|
87
|
+
src: z.string().optional(),
|
|
88
|
+
filename: z.string().optional(),
|
|
89
|
+
mimeType: z.string().optional(),
|
|
90
|
+
size: z.number().optional(),
|
|
91
|
+
provider: z.string().optional(),
|
|
92
|
+
meta: z.record(z.string(), z.unknown()).optional()
|
|
93
|
+
});
|
|
94
|
+
case "reference": return z.string();
|
|
95
|
+
case "json": return z.unknown();
|
|
96
|
+
default: return z.unknown();
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
/**
|
|
100
|
+
* Apply validation rules to a schema
|
|
101
|
+
*/
|
|
102
|
+
function applyValidation(schema, field) {
|
|
103
|
+
const validation = field.validation;
|
|
104
|
+
if (!validation) return schema;
|
|
105
|
+
if (schema instanceof z.ZodString) {
|
|
106
|
+
let strSchema = schema;
|
|
107
|
+
if (validation.minLength !== void 0) strSchema = strSchema.min(validation.minLength);
|
|
108
|
+
if (validation.maxLength !== void 0) strSchema = strSchema.max(validation.maxLength);
|
|
109
|
+
if (validation.pattern) strSchema = strSchema.regex(new RegExp(validation.pattern));
|
|
110
|
+
return strSchema;
|
|
111
|
+
}
|
|
112
|
+
if (schema instanceof z.ZodNumber) {
|
|
113
|
+
let numSchema = schema;
|
|
114
|
+
if (validation.min !== void 0) numSchema = numSchema.min(validation.min);
|
|
115
|
+
if (validation.max !== void 0) numSchema = numSchema.max(validation.max);
|
|
116
|
+
return numSchema;
|
|
117
|
+
}
|
|
118
|
+
return schema;
|
|
119
|
+
}
|
|
120
|
+
/**
|
|
121
|
+
* Schema cache to avoid regenerating schemas on every request
|
|
122
|
+
*/
|
|
123
|
+
const schemaCache = /* @__PURE__ */ new Map();
|
|
124
|
+
/**
|
|
125
|
+
* Get or generate a cached schema for a collection
|
|
126
|
+
*/
|
|
127
|
+
function getCachedSchema(collection, version) {
|
|
128
|
+
const cacheKey = collection.slug;
|
|
129
|
+
const cached = schemaCache.get(cacheKey);
|
|
130
|
+
if (cached && (!version || cached.version === version)) return cached.schema;
|
|
131
|
+
const schema = generateZodSchema(collection);
|
|
132
|
+
schemaCache.set(cacheKey, {
|
|
133
|
+
schema,
|
|
134
|
+
version: version || collection.updatedAt
|
|
135
|
+
});
|
|
136
|
+
return schema;
|
|
137
|
+
}
|
|
138
|
+
/**
|
|
139
|
+
* Validate data against a collection's schema
|
|
140
|
+
*/
|
|
141
|
+
function validateContent(collection, data) {
|
|
142
|
+
const result = getCachedSchema(collection).safeParse(data);
|
|
143
|
+
if (result.success) return {
|
|
144
|
+
success: true,
|
|
145
|
+
data: result.data
|
|
146
|
+
};
|
|
147
|
+
return {
|
|
148
|
+
success: false,
|
|
149
|
+
errors: result.error
|
|
150
|
+
};
|
|
151
|
+
}
|
|
152
|
+
/**
|
|
15
153
|
* Generate TypeScript interface from field definitions
|
|
16
154
|
* Used by CLI `dineway types` to generate types
|
|
17
155
|
*/
|
|
@@ -158,4 +296,4 @@ function uniqueInterfaceNames(collections) {
|
|
|
158
296
|
}
|
|
159
297
|
|
|
160
298
|
//#endregion
|
|
161
|
-
export { uniqueInterfaceNames as n,
|
|
299
|
+
export { zod_generator_exports as i, uniqueInterfaceNames as n, validateContent as r, generateTypeScript as t };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "dineway",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.10",
|
|
4
4
|
"description": "Agentic Website builder for restaurants — structured content meets AI via the Model Context Protocol",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"publishConfig": {
|
|
@@ -387,8 +387,8 @@
|
|
|
387
387
|
"ulidx": "^2.4.1",
|
|
388
388
|
"upng-js": "^2.1.0",
|
|
389
389
|
"zod": "^4.4.1",
|
|
390
|
-
"@dineway-ai/auth": "^0.2.4",
|
|
391
390
|
"@dineway-ai/admin": "^0.2.4",
|
|
391
|
+
"@dineway-ai/auth": "^0.2.4",
|
|
392
392
|
"@dineway-ai/gutenberg-to-portable-text": "^0.2.2"
|
|
393
393
|
},
|
|
394
394
|
"optionalDependencies": {
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|