@aglyn/aglyn 1.0.0-beta.229 → 1.0.0-beta.231

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.
Files changed (123) hide show
  1. package/package.json +11 -11
  2. package/src/lib/app-utils/analytics-events.d.ts +18 -0
  3. package/src/lib/app-utils/analytics-events.js +2 -0
  4. package/src/lib/app-utils/analytics-events.js.map +1 -1
  5. package/src/lib/app-utils/crm.d.ts +14 -1
  6. package/src/lib/app-utils/crm.js +19 -2
  7. package/src/lib/app-utils/crm.js.map +1 -1
  8. package/src/lib/app-utils/docs-help.generated.d.ts +111 -9
  9. package/src/lib/app-utils/docs-help.generated.js +272 -3
  10. package/src/lib/app-utils/docs-help.generated.js.map +1 -1
  11. package/src/lib/app-utils/docs-index.generated.js +810 -61
  12. package/src/lib/app-utils/docs-index.generated.js.map +1 -1
  13. package/src/lib/app-utils/host-status.d.ts +85 -0
  14. package/src/lib/app-utils/host-status.js +115 -0
  15. package/src/lib/app-utils/host-status.js.map +1 -0
  16. package/src/lib/app-utils/lockdown.js +1 -1
  17. package/src/lib/app-utils/lockdown.js.map +1 -1
  18. package/src/lib/app-utils/media-filter.d.ts +136 -0
  19. package/src/lib/app-utils/media-filter.js +400 -0
  20. package/src/lib/app-utils/media-filter.js.map +1 -0
  21. package/src/lib/app-utils/mobile-push.d.ts +98 -0
  22. package/src/lib/app-utils/mobile-push.js +97 -0
  23. package/src/lib/app-utils/mobile-push.js.map +1 -0
  24. package/src/lib/app-utils/notification-push.d.ts +38 -0
  25. package/src/lib/app-utils/notification-push.js +54 -0
  26. package/src/lib/app-utils/notification-push.js.map +1 -0
  27. package/src/lib/app-utils/notifications.d.ts +7 -0
  28. package/src/lib/app-utils/notifications.js.map +1 -1
  29. package/src/lib/app-utils/organizations.js +5 -2
  30. package/src/lib/app-utils/organizations.js.map +1 -1
  31. package/src/lib/app-utils/plan-entitlements.js +20 -0
  32. package/src/lib/app-utils/plan-entitlements.js.map +1 -1
  33. package/src/lib/app-utils/plugin-host-events.generated.d.ts +1 -1
  34. package/src/lib/app-utils/plugin-host-events.generated.js +164 -0
  35. package/src/lib/app-utils/plugin-host-events.generated.js.map +1 -1
  36. package/src/lib/app-utils/plugin-release-flags.generated.d.ts +1 -1
  37. package/src/lib/app-utils/plugin-release-flags.generated.js +7 -0
  38. package/src/lib/app-utils/plugin-release-flags.generated.js.map +1 -1
  39. package/src/lib/app-utils/realm-host-surface.generated.js +3 -0
  40. package/src/lib/app-utils/realm-host-surface.generated.js.map +1 -1
  41. package/src/lib/app-utils/release-flags.js +6 -2
  42. package/src/lib/app-utils/release-flags.js.map +1 -1
  43. package/src/lib/app-utils/scope-tokens.d.ts +16 -1
  44. package/src/lib/app-utils/scope-tokens.js +15 -1
  45. package/src/lib/app-utils/scope-tokens.js.map +1 -1
  46. package/src/lib/app-utils/site-journey.d.ts +143 -0
  47. package/src/lib/app-utils/site-journey.js +282 -0
  48. package/src/lib/app-utils/site-journey.js.map +1 -0
  49. package/src/lib/app-utils/site-list-query.d.ts +47 -0
  50. package/src/lib/app-utils/site-list-query.js +142 -0
  51. package/src/lib/app-utils/site-list-query.js.map +1 -0
  52. package/src/lib/app-utils/site-wide-outbox.d.ts +95 -0
  53. package/src/lib/app-utils/site-wide-outbox.js +117 -0
  54. package/src/lib/app-utils/site-wide-outbox.js.map +1 -0
  55. package/src/lib/app-utils/transfer-launcher-context.d.ts +6 -0
  56. package/src/lib/app-utils/transfer-launcher-context.js.map +1 -1
  57. package/src/lib/app-utils/upload-inspection.js +7 -0
  58. package/src/lib/app-utils/upload-inspection.js.map +1 -1
  59. package/src/lib/app-utils/webhook-delivery.js +4 -1
  60. package/src/lib/app-utils/webhook-delivery.js.map +1 -1
  61. package/src/lib/foundation/definitions/org-billing.types.d.ts +24 -0
  62. package/src/lib/foundation/definitions/org-billing.types.js.map +1 -1
  63. package/src/lib/foundation/definitions/organization.types.d.ts +18 -7
  64. package/src/lib/foundation/definitions/organization.types.js.map +1 -1
  65. package/src/lib/foundation/definitions/write-deny-coverage.util.d.ts +4 -1
  66. package/src/lib/foundation/definitions/write-deny-coverage.util.js +12 -2
  67. package/src/lib/foundation/definitions/write-deny-coverage.util.js.map +1 -1
  68. package/src/lib/plugin-manager/enabled-plugins.js +4 -2
  69. package/src/lib/plugin-manager/enabled-plugins.js.map +1 -1
  70. package/src/lib/plugin-manager/feature-plugins.d.ts +173 -0
  71. package/src/lib/plugin-manager/feature-plugins.js +62 -1
  72. package/src/lib/plugin-manager/feature-plugins.js.map +1 -1
  73. package/src/lib/plugin-manager/first-party-plugins.generated.js +251 -2
  74. package/src/lib/plugin-manager/first-party-plugins.generated.js.map +1 -1
  75. package/src/lib/plugin-manager/plugin-ai-capabilities.d.ts +192 -0
  76. package/src/lib/plugin-manager/plugin-ai-capabilities.js +157 -0
  77. package/src/lib/plugin-manager/plugin-ai-capabilities.js.map +1 -0
  78. package/src/lib/plugin-manager/plugin-checkout-extras.d.ts +168 -0
  79. package/src/lib/plugin-manager/plugin-checkout-extras.js +172 -0
  80. package/src/lib/plugin-manager/plugin-checkout-extras.js.map +1 -0
  81. package/src/lib/plugin-manager/plugin-contributions.d.ts +7 -0
  82. package/src/lib/plugin-manager/plugin-contributions.js +1 -1
  83. package/src/lib/plugin-manager/plugin-contributions.js.map +1 -1
  84. package/src/lib/plugin-manager/plugin-domain-events.d.ts +138 -0
  85. package/src/lib/plugin-manager/plugin-domain-events.js +148 -0
  86. package/src/lib/plugin-manager/plugin-domain-events.js.map +1 -0
  87. package/src/lib/plugin-manager/plugin-events.d.ts +51 -0
  88. package/src/lib/plugin-manager/plugin-events.js +4 -0
  89. package/src/lib/plugin-manager/plugin-events.js.map +1 -1
  90. package/src/lib/plugin-manager/plugin-fulfillment-providers.d.ts +101 -0
  91. package/src/lib/plugin-manager/plugin-fulfillment-providers.js +83 -0
  92. package/src/lib/plugin-manager/plugin-fulfillment-providers.js.map +1 -0
  93. package/src/lib/plugin-manager/plugin-permissions.js +21 -5
  94. package/src/lib/plugin-manager/plugin-permissions.js.map +1 -1
  95. package/src/lib/plugin-manager/plugin-person-records.d.ts +90 -0
  96. package/src/lib/plugin-manager/plugin-person-records.js +26 -0
  97. package/src/lib/plugin-manager/plugin-person-records.js.map +1 -1
  98. package/src/lib/plugin-manager/plugin-product-catalog.d.ts +204 -0
  99. package/src/lib/plugin-manager/plugin-product-catalog.js +43 -0
  100. package/src/lib/plugin-manager/plugin-product-catalog.js.map +1 -0
  101. package/src/lib/plugin-manager/plugin-shipment-records.d.ts +210 -0
  102. package/src/lib/plugin-manager/plugin-shipment-records.js +63 -0
  103. package/src/lib/plugin-manager/plugin-shipment-records.js.map +1 -0
  104. package/src/lib/plugin-manager/plugin-shipping-rates.d.ts +151 -0
  105. package/src/lib/plugin-manager/plugin-shipping-rates.js +62 -0
  106. package/src/lib/plugin-manager/plugin-shipping-rates.js.map +1 -0
  107. package/src/lib/plugin-manager/plugin-sms-messaging.d.ts +103 -0
  108. package/src/lib/plugin-manager/plugin-sms-messaging.js +39 -0
  109. package/src/lib/plugin-manager/plugin-sms-messaging.js.map +1 -0
  110. package/src/lib/plugin-manager/plugin-stock-levels.d.ts +81 -0
  111. package/src/lib/plugin-manager/plugin-stock-levels.js +32 -0
  112. package/src/lib/plugin-manager/plugin-stock-levels.js.map +1 -0
  113. package/src/lib/plugin-manager/plugin-tax-profile.d.ts +154 -0
  114. package/src/lib/plugin-manager/plugin-tax-profile.js +56 -0
  115. package/src/lib/plugin-manager/plugin-tax-profile.js.map +1 -1
  116. package/src/lib/plugin-manager/plugin-theme-font-catalog.d.ts +59 -0
  117. package/src/lib/plugin-manager/plugin-theme-font-catalog.js +40 -0
  118. package/src/lib/plugin-manager/plugin-theme-font-catalog.js.map +1 -0
  119. package/src/lib/plugin-manager/plugin-tracking-pages.d.ts +55 -0
  120. package/src/lib/plugin-manager/plugin-tracking-pages.js +76 -0
  121. package/src/lib/plugin-manager/plugin-tracking-pages.js.map +1 -0
  122. package/src/lib/plugin-manager/realm-host-aglyn.generated.js +3 -0
  123. package/src/lib/plugin-manager/realm-host-aglyn.generated.js.map +1 -1
@@ -15,6 +15,7 @@
15
15
  * limitations under the License.
16
16
  */
17
17
  import type { OrgPermissions } from '../app-utils/org-permissions';
18
+ import type { ReleaseFlagKey } from '../app-utils/release-flags';
18
19
  import type { SeoAuditReport } from '../app-utils/seo-audit';
19
20
  import type { SeoListingFieldKey } from '../app-utils/seo-listing-fields';
20
21
  import type { AglynOrgBilling, OrgFeatureFlags } from '../foundation';
@@ -583,6 +584,16 @@ export declare const CONSOLE_WIDGET_SLOTS: {
583
584
  readonly orgDashboard: "orgDashboard";
584
585
  /** Host dashboard commerce summary. Props: hostId, org. */
585
586
  readonly commerceGlance: "commerceGlance";
587
+ /**
588
+ * A site's Analytics page, below its own traffic cards (AGL-3605): a
589
+ * section of analytics a plugin computes from what the site records — a
590
+ * funnel, say. Props: hostId, orgId (the workspace, or undefined while it
591
+ * loads).
592
+ *
593
+ * A section rather than a glance, so a widget here owns a whole card: its
594
+ * own range picker, its own plan answer and its own empty state.
595
+ */
596
+ readonly hostAnalytics: "hostAnalytics";
586
597
  /** Org Data page body. Props: orgId, org. */
587
598
  readonly orgData: "orgData";
588
599
  /** Besigner functions (ƒx) panel. Props: hostId. */
@@ -732,6 +743,18 @@ export declare const CONSOLE_WIDGET_SLOTS: {
732
743
  * widget.
733
744
  */
734
745
  readonly hostTheme: "hostTheme";
746
+ /**
747
+ * Inside the theme editor's Typography card (AGL-3656): the control that
748
+ * chooses the site's fonts. Props: {@link ConsoleThemeEditorFontsZoneProps}
749
+ * — the site, the editor's draft, and `updateDraft`, which changes the
750
+ * draft as any of the editor's own controls does.
751
+ *
752
+ * A widget here edits the draft and never writes: the editor's Save keeps
753
+ * the change and Discard drops it, with the preview beside it following
754
+ * every step. With no widget the editor offers its own short list of
755
+ * fonts, so a workspace without a fonts plugin can still choose one.
756
+ */
757
+ readonly themeEditorFonts: "themeEditorFonts";
735
758
  /**
736
759
  * The staff overview, among its platform-wide cards (AGL-3080). No props:
737
760
  * the overview is about the platform, not one org, so a widget here reads
@@ -978,6 +1001,15 @@ export declare const CONSOLE_WIDGET_SLOTS: {
978
1001
  * person decides.
979
1002
  */
980
1003
  readonly sitePackageItemPreview: "sitePackageItemPreview";
1004
+ /**
1005
+ * The media library, beside its Upload media and New folder actions and
1006
+ * again in its empty state (AGL-3602): another way to add a file. Props:
1007
+ * {@link ConsoleMediaLibraryZoneProps}. The `hostScreens` contract — a
1008
+ * widget runs its own flow and writes nothing through the library — with
1009
+ * one door back: `onCreated`, which the widget calls with the assets it
1010
+ * added so the library shows them, selected.
1011
+ */
1012
+ readonly mediaLibrary: "mediaLibrary";
981
1013
  };
982
1014
  export type ConsoleWidgetSlot = (typeof CONSOLE_WIDGET_SLOTS)[keyof typeof CONSOLE_WIDGET_SLOTS];
983
1015
  /** What the `besignerPageProperties` zone hands each widget (AGL-3475). */
@@ -1018,6 +1050,23 @@ export type ConsoleHostTemplatesZoneProps = ConsoleHostScreensZoneProps;
1018
1050
  export type ConsoleHostLayoutsZoneProps = ConsoleHostScreensZoneProps;
1019
1051
  /** See {@link ConsoleHostTemplatesZoneProps}. */
1020
1052
  export type ConsoleHostComponentsZoneProps = ConsoleHostScreensZoneProps;
1053
+ /** What the `mediaLibrary` zone hands each widget (AGL-3602). */
1054
+ export interface ConsoleMediaLibraryZoneProps {
1055
+ /**
1056
+ * The site whose library is open; for the organization's library, the site
1057
+ * on screen when there is one (a site's Media tab, a picker opened for a
1058
+ * site), else `null`.
1059
+ */
1060
+ hostId: string | null;
1061
+ /** The org the library belongs to; `undefined` while it resolves. */
1062
+ orgId: string | undefined;
1063
+ /** Which library is open: a site's own, or the organization's. */
1064
+ library: 'host' | 'org';
1065
+ /** The folder open in the library, where new files land; `null` for none. */
1066
+ folderId: string | null;
1067
+ /** Hands the library the assets a widget added, to show and select them. */
1068
+ onCreated: (mediaIds: readonly string[]) => void;
1069
+ }
1021
1070
  /** What the `orgSites` zone hands each widget (AGL-2911). */
1022
1071
  export interface ConsoleOrgSitesZoneProps {
1023
1072
  /** Always `null`: the zone belongs to the organization, not to one site. */
@@ -1294,6 +1343,18 @@ export interface ConsoleHostThemeZoneProps {
1294
1343
  */
1295
1344
  proposeDraft: (theme: HostTheme, key: string) => void;
1296
1345
  }
1346
+ /** What the `themeEditorFonts` zone hands each widget (AGL-3656). */
1347
+ export interface ConsoleThemeEditorFontsZoneProps {
1348
+ /** The site whose theme is being edited; `null` on an editor that names none. */
1349
+ hostId: string | null;
1350
+ /** The editor's draft: the saved theme with every unsaved edit on it. */
1351
+ draft: HostTheme;
1352
+ /**
1353
+ * Changes the draft. The updater gets the draft as it is when the change
1354
+ * applies, so two edits in one tick both land.
1355
+ */
1356
+ updateDraft: (updater: (draft: HostTheme) => HostTheme) => void;
1357
+ }
1297
1358
  /**
1298
1359
  * The zones on the STAFF pages (AGL-2939): the staff overview, the staff org
1299
1360
  * page, its detail zone, and the staff user page.
@@ -1516,8 +1577,56 @@ export interface ConsoleWidget {
1516
1577
  * part of it. Absent without an upsell, for the reason `permission` gives.
1517
1578
  */
1518
1579
  featureFlag?: keyof OrgFeatureFlags;
1580
+ /**
1581
+ * Mount this widget as its own upsell when the ONLY thing missing is the
1582
+ * plan entitlement (AGL-3601).
1583
+ *
1584
+ * Without it a widget whose `featureFlag` the plan lacks is absent, as
1585
+ * above. With it, the shell still mounts it — with `entitled={false}` and
1586
+ * an `upgrade` prop ({@link ConsoleWidgetUpgrade}) — but only when every
1587
+ * other gate passes (the reader's permission, the plugin being on for this
1588
+ * workspace and this site) and the missing flag is one an add-on this
1589
+ * workspace can buy switches on. Where nothing can be bought the widget
1590
+ * stays absent, so the widget never has to decide that itself.
1591
+ *
1592
+ * The widget owns what it draws in that state, and must not open the
1593
+ * feature: the shell has decided the plan does not include it.
1594
+ */
1595
+ showWhenNotEntitled?: boolean;
1596
+ /**
1597
+ * The release flag this widget is behind, which the shell resolves from the
1598
+ * flags it already loads for every page (AGL-3601) — staff bypass applied,
1599
+ * as the server's own doors apply it. The widget is absent while the flag
1600
+ * is off for this workspace, and while the flags have not settled, so a
1601
+ * control is never drawn and then taken away.
1602
+ *
1603
+ * For a widget that would otherwise have to ask a server door whether its
1604
+ * feature exists before it draws anything.
1605
+ */
1606
+ releaseFlag?: ReleaseFlagKey;
1519
1607
  Component: ComponentType<any>;
1520
1608
  }
1609
+ /**
1610
+ * Where a widget mounted by {@link ConsoleWidget.showWhenNotEntitled} sends a
1611
+ * reader to buy what it lacks. The shell builds it, so no extension supplies a
1612
+ * URL the console's own chrome then renders.
1613
+ */
1614
+ export interface ConsoleWidgetUpgrade {
1615
+ /** The workspace's Billing page, at the section that sells add-ons. */
1616
+ billingHref: string;
1617
+ /** Whether the reader may buy it (`billing.manage`). */
1618
+ canManageBilling: boolean;
1619
+ }
1620
+ /**
1621
+ * The props the shell adds to a widget that declared
1622
+ * {@link ConsoleWidget.showWhenNotEntitled}, beside its zone's own.
1623
+ * `entitled` is `true` when the plan includes the feature, and `upgrade`
1624
+ * is present only when it is `false`.
1625
+ */
1626
+ export interface ConsoleWidgetEntitlementProps {
1627
+ entitled?: boolean;
1628
+ upgrade?: ConsoleWidgetUpgrade;
1629
+ }
1521
1630
  /**
1522
1631
  * Console half of the pattern: everything a feature contributes to the
1523
1632
  * console shell. Declarative — the shell owns rendering and applies the
@@ -1678,6 +1787,46 @@ export interface ConsoleStaffPage {
1678
1787
  ownsSubtree?: boolean;
1679
1788
  Component: ComponentType<ConsoleStaffPageProps>;
1680
1789
  }
1790
+ /** What the console's generic public route hands a public page. */
1791
+ export interface ConsolePublicPageProps {
1792
+ /** The plugin that registered the page, the URL's first segment after `/kiosk`. */
1793
+ pluginId: PluginId;
1794
+ /** The page's own path, as it registered it (`/display`). */
1795
+ path: string;
1796
+ }
1797
+ /**
1798
+ * A full-screen console page that needs NO staff session (AGL-3608): served
1799
+ * at `/kiosk/{pluginId}{path}` by the console's generic public route, outside
1800
+ * the workspace shell, with only the console theme around it.
1801
+ *
1802
+ * The case is a device a business sets down in front of the public — a
1803
+ * screen facing a customer, a sign-in tablet at a front desk — which is
1804
+ * nobody's console session and must never become one. The shell draws no
1805
+ * nav, no workspace, no org switcher and no plugin providers here, and the
1806
+ * route loads this one plugin's console bundle and nothing else.
1807
+ *
1808
+ * Neither the extension's `featureFlag` nor its `permission` applies: there is
1809
+ * no member to ask. The page proves itself to its own API routes — a pairing
1810
+ * code exchanged for a device token, say — and every read it makes must be
1811
+ * refused server-side without that proof. Treat everything the page renders
1812
+ * as visible to whoever is standing in front of the device.
1813
+ *
1814
+ * The plugin also declares each path in its manifest as
1815
+ * `contributes.console.publicRoutes`, which is what lets the route load the
1816
+ * bundle only for a path that exists. First-party plugins only: the route
1817
+ * reads the console's generated manifest, never a marketplace install.
1818
+ */
1819
+ export interface ConsolePublicPage {
1820
+ /**
1821
+ * The path beneath `/kiosk/{pluginId}`, with its leading slash
1822
+ * (`/display`). Matched exactly. It is in URLs saved on devices — treat it
1823
+ * as persisted.
1824
+ */
1825
+ path: string;
1826
+ /** The browser tab's title, which is also what a home-screen shortcut shows. */
1827
+ title: string;
1828
+ Component: ComponentType<ConsolePublicPageProps>;
1829
+ }
1681
1830
  export interface ConsoleExtension {
1682
1831
  pluginId: PluginId;
1683
1832
  displayName: string;
@@ -1763,6 +1912,12 @@ export interface ConsoleExtension {
1763
1912
  * Neither `featureFlag` nor `permission` applies to them.
1764
1913
  */
1765
1914
  staffPages?: readonly ConsoleStaffPage[];
1915
+ /**
1916
+ * Full-screen pages that need no staff session (AGL-3608) — see
1917
+ * {@link ConsolePublicPage}. Neither `featureFlag` nor `permission` applies
1918
+ * to them.
1919
+ */
1920
+ publicPages?: readonly ConsolePublicPage[];
1766
1921
  /**
1767
1922
  * App-level providers the shell mounts around every console page
1768
1923
  * (AGL-419) — e.g. the marketplace plugin's AI-assist provider.
@@ -1888,6 +2043,24 @@ export declare function listConsoleStaffPages(enabledPluginIds?: readonly Plugin
1888
2043
  * symptom — the same rule {@link resolveConsolePluginPage} applies to paths.
1889
2044
  */
1890
2045
  export declare function resolveConsoleStaffPage(id: string, enabledPluginIds?: readonly PluginId[]): ConsoleStaffPageEntry | undefined;
2046
+ /** A public page flattened with its owning extension's id. */
2047
+ export interface ConsolePublicPageEntry extends ConsolePublicPage {
2048
+ pluginId: PluginId;
2049
+ }
2050
+ /** `pos-display`, `/pos-display/` and `/pos-display` all name `/pos-display`. */
2051
+ export declare function normalizeConsolePublicPath(path: string): string;
2052
+ /** Every registered public page, in registration order. */
2053
+ export declare function listConsolePublicPages(enabledPluginIds?: readonly PluginId[]): ConsolePublicPageEntry[];
2054
+ /**
2055
+ * The public page at `/kiosk/{pluginId}{path}` (AGL-3608), or `undefined`.
2056
+ *
2057
+ * Scoped to the ONE plugin the URL names, because the registry is a
2058
+ * session-wide union (AGL-758): a device that once loaded another plugin
2059
+ * must not have that plugin answer a path in this one's namespace. Two
2060
+ * extensions of the same plugin claiming one path resolve to nothing and
2061
+ * say so, the rule {@link resolveConsoleStaffPage} applies to ids.
2062
+ */
2063
+ export declare function resolveConsolePublicPage(pluginId: PluginId, path: string): ConsolePublicPageEntry | undefined;
1891
2064
  /** Widgets registered for a slot, across every extension (AGL-419). */
1892
2065
  export declare function listConsoleWidgets(slot: string, enabledPluginIds?: readonly PluginId[]): Array<{
1893
2066
  extension: ConsoleExtension;
@@ -117,6 +117,15 @@ import { _ as _extends } from "@swc/helpers/_/_extends";
117
117
  * row, no heading) when no widget survives the gates.
118
118
  */ orgDashboard: 'orgDashboard',
119
119
  /** Host dashboard commerce summary. Props: hostId, org. */ commerceGlance: 'commerceGlance',
120
+ /**
121
+ * A site's Analytics page, below its own traffic cards (AGL-3605): a
122
+ * section of analytics a plugin computes from what the site records — a
123
+ * funnel, say. Props: hostId, orgId (the workspace, or undefined while it
124
+ * loads).
125
+ *
126
+ * A section rather than a glance, so a widget here owns a whole card: its
127
+ * own range picker, its own plan answer and its own empty state.
128
+ */ hostAnalytics: 'hostAnalytics',
120
129
  /** Org Data page body. Props: orgId, org. */ orgData: 'orgData',
121
130
  /** Besigner functions (ƒx) panel. Props: hostId. */ besignerFunctions: 'besignerFunctions',
122
131
  /**
@@ -270,6 +279,17 @@ import { _ as _extends } from "@swc/helpers/_/_extends";
270
279
  * widget.
271
280
  */ hostTheme: 'hostTheme',
272
281
  /**
282
+ * Inside the theme editor's Typography card (AGL-3656): the control that
283
+ * chooses the site's fonts. Props: {@link ConsoleThemeEditorFontsZoneProps}
284
+ * — the site, the editor's draft, and `updateDraft`, which changes the
285
+ * draft as any of the editor's own controls does.
286
+ *
287
+ * A widget here edits the draft and never writes: the editor's Save keeps
288
+ * the change and Discard drops it, with the preview beside it following
289
+ * every step. With no widget the editor offers its own short list of
290
+ * fonts, so a workspace without a fonts plugin can still choose one.
291
+ */ themeEditorFonts: 'themeEditorFonts',
292
+ /**
273
293
  * The staff overview, among its platform-wide cards (AGL-3080). No props:
274
294
  * the overview is about the platform, not one org, so a widget here reads
275
295
  * what its plugin holds across every workspace through its own staff
@@ -483,7 +503,15 @@ import { _ as _extends } from "@swc/helpers/_/_extends";
483
503
  * or its value list. The widget reads nothing it is not handed beyond what
484
504
  * its preview always reads, and never writes: the import writes, after the
485
505
  * person decides.
486
- */ sitePackageItemPreview: 'sitePackageItemPreview'
506
+ */ sitePackageItemPreview: 'sitePackageItemPreview',
507
+ /**
508
+ * The media library, beside its Upload media and New folder actions and
509
+ * again in its empty state (AGL-3602): another way to add a file. Props:
510
+ * {@link ConsoleMediaLibraryZoneProps}. The `hostScreens` contract — a
511
+ * widget runs its own flow and writes nothing through the library — with
512
+ * one door back: `onCreated`, which the widget calls with the assets it
513
+ * added so the library shows them, selected.
514
+ */ mediaLibrary: 'mediaLibrary'
487
515
  };
488
516
  /**
489
517
  * The zones on the STAFF pages (AGL-2939): the staff overview, the staff org
@@ -746,6 +774,39 @@ function matchNavItemHref(navItem, itemHref, href) {
746
774
  }
747
775
  return matches[0];
748
776
  }
777
+ /** `pos-display`, `/pos-display/` and `/pos-display` all name `/pos-display`. */ export function normalizeConsolePublicPath(path) {
778
+ return `/${String(path != null ? path : '').split('/').filter(Boolean).join('/')}`;
779
+ }
780
+ /** Every registered public page, in registration order. */ export function listConsolePublicPages(enabledPluginIds) {
781
+ return listConsoleExtensions(enabledPluginIds).flatMap((extension)=>{
782
+ var _extension_publicPages;
783
+ return ((_extension_publicPages = extension.publicPages) != null ? _extension_publicPages : []).map((page)=>_extends({}, page, {
784
+ path: normalizeConsolePublicPath(page.path),
785
+ pluginId: extension.pluginId
786
+ }));
787
+ });
788
+ }
789
+ /**
790
+ * The public page at `/kiosk/{pluginId}{path}` (AGL-3608), or `undefined`.
791
+ *
792
+ * Scoped to the ONE plugin the URL names, because the registry is a
793
+ * session-wide union (AGL-758): a device that once loaded another plugin
794
+ * must not have that plugin answer a path in this one's namespace. Two
795
+ * extensions of the same plugin claiming one path resolve to nothing and
796
+ * say so, the rule {@link resolveConsoleStaffPage} applies to ids.
797
+ */ export function resolveConsolePublicPage(pluginId, path) {
798
+ if (!pluginId) return undefined;
799
+ const wanted = normalizeConsolePublicPath(path);
800
+ if (wanted === '/') return undefined;
801
+ const matches = listConsolePublicPages([
802
+ pluginId
803
+ ]).filter((page)=>page.path === wanted);
804
+ if (matches.length > 1) {
805
+ console.error(`[aglyn] public page "/kiosk/${pluginId}${wanted}" is registered more ` + 'than once; refusing to guess which one to serve.');
806
+ return undefined;
807
+ }
808
+ return matches[0];
809
+ }
749
810
  /** Widgets registered for a slot, across every extension (AGL-419). */ export function listConsoleWidgets(slot, enabledPluginIds) {
750
811
  const out = [];
751
812
  for (const extension of listConsoleExtensions(enabledPluginIds)){