@flamingo-stack/openframe-frontend-core 0.0.739 → 0.0.740

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 (65) hide show
  1. package/dist/build/export-map.json +1 -1
  2. package/dist/{chunk-WMKNZI4G.cjs → chunk-2Y5Y4FLM.cjs} +22 -22
  3. package/dist/{chunk-ENCAIAMY.cjs → chunk-3ZIQOYNX.cjs} +3 -3
  4. package/dist/{chunk-UI3HROSI.cjs → chunk-4RLGLB45.cjs} +33 -33
  5. package/dist/{chunk-FL6UO7IR.cjs → chunk-5SVOGLNK.cjs} +2 -2
  6. package/dist/{chunk-DTLHY2ZF.cjs → chunk-7UIQPMBJ.cjs} +11 -11
  7. package/dist/{chunk-UYP3G6PB.cjs → chunk-BDA5F6RM.cjs} +2 -2
  8. package/dist/{chunk-S2CA5WE4.cjs → chunk-CWRVTQUO.cjs} +9 -1
  9. package/dist/{chunk-CUDTMCXK.cjs → chunk-D5KEWWLW.cjs} +13 -13
  10. package/dist/{chunk-UXFJXIUT.cjs → chunk-EKGL5K5K.cjs} +2 -2
  11. package/dist/{chunk-V2ZFH42N.cjs → chunk-HYBMADYO.cjs} +3 -3
  12. package/dist/{chunk-Q7GG3WC5.cjs → chunk-LLAC2UZ3.cjs} +5 -5
  13. package/dist/{chunk-EGN4I5Q7.cjs → chunk-SWR22DOZ.cjs} +134 -46
  14. package/dist/{chunk-TF7J6VXG.cjs → chunk-UW3YXDC4.cjs} +9 -9
  15. package/dist/{chunk-SB4VWA5V.cjs → chunk-VC4IV3AY.cjs} +70 -70
  16. package/dist/{chunk-RGFT3P3L.cjs → chunk-VU4CKUJW.cjs} +55 -55
  17. package/dist/{chunk-NX6JQT25.cjs → chunk-ZLTCQKTD.cjs} +4 -4
  18. package/dist/{cloud-tenants-QSFSO3PA.cjs → cloud-tenants-PVXDI5MU.cjs} +3 -3
  19. package/dist/components/case-studies/index.cjs +11 -11
  20. package/dist/components/chat/index.cjs +2 -2
  21. package/dist/components/contact/index.cjs +4 -4
  22. package/dist/components/docs/index.cjs +7 -7
  23. package/dist/components/embeds/index.cjs +4 -4
  24. package/dist/components/faq/index.cjs +5 -5
  25. package/dist/components/features/index.cjs +3 -3
  26. package/dist/components/help-center-pages/index.cjs +53 -53
  27. package/dist/components/index.cjs +39 -33
  28. package/dist/components/meeting-scheduler/index.cjs +17 -17
  29. package/dist/components/navigation/index.cjs +6 -6
  30. package/dist/components/onboarding-guides/index.cjs +5 -5
  31. package/dist/components/product-demo/index.cjs +6 -6
  32. package/dist/components/shared/legal-document/index.d.ts +2 -1
  33. package/dist/components/shared/legal-document/index.d.ts.map +1 -1
  34. package/dist/components/shared/legal-document/index.js +10 -2
  35. package/dist/components/shared/legal-document/legal-document-page.d.ts +35 -23
  36. package/dist/components/shared/legal-document/legal-document-page.d.ts.map +1 -1
  37. package/dist/components/shared/legal-document/legal-document-page.js +27 -10
  38. package/dist/components/shared/legal-document/use-legal-docs.d.ts +7 -3
  39. package/dist/components/shared/legal-document/use-legal-docs.d.ts.map +1 -1
  40. package/dist/components/shared/legal-document/use-legal-docs.js +7 -0
  41. package/dist/components/shared/legal-document/use-legal-documents.d.ts +31 -0
  42. package/dist/components/shared/legal-document/use-legal-documents.d.ts.map +1 -0
  43. package/dist/components/shared/legal-document/use-legal-documents.js +67 -0
  44. package/dist/components/tickets/index.cjs +8 -8
  45. package/dist/components/ui/index.cjs +3 -3
  46. package/dist/{devices-C7XLWJFC.cjs → devices-TWEA7XOR.cjs} +4 -4
  47. package/dist/index.cjs +11 -7
  48. package/dist/{knowledge-3QKWTOE7.cjs → knowledge-4GQDBNQB.cjs} +3 -3
  49. package/dist/{logs-JXD75NR4.cjs → logs-EVU6GJHZ.cjs} +11 -11
  50. package/dist/{policies-ZPN53PFQ.cjs → policies-OZUEA5YS.cjs} +7 -7
  51. package/dist/{software-update-CRSIBS3K.cjs → software-update-BLIVYOY2.cjs} +6 -6
  52. package/dist/utils/index.cjs +8 -0
  53. package/dist/utils/index.d.ts +1 -0
  54. package/dist/utils/index.d.ts.map +1 -1
  55. package/dist/utils/index.js +1 -0
  56. package/dist/utils/legal-documents.d.ts +18 -0
  57. package/dist/utils/legal-documents.d.ts.map +1 -0
  58. package/dist/utils/legal-documents.js +8 -0
  59. package/package.json +1 -1
  60. package/src/components/shared/legal-document/index.ts +8 -0
  61. package/src/components/shared/legal-document/legal-document-page.tsx +83 -44
  62. package/src/components/shared/legal-document/use-legal-docs.ts +18 -3
  63. package/src/components/shared/legal-document/use-legal-documents.ts +113 -0
  64. package/src/utils/index.ts +1 -0
  65. package/src/utils/legal-documents.ts +21 -0
@@ -8,7 +8,7 @@ var _chunkII4QMH26cjs = require('./chunk-II4QMH26.cjs');
8
8
  var _chunkKHXZFLINcjs = require('./chunk-KHXZFLIN.cjs');
9
9
 
10
10
 
11
- var _chunkSB4VWA5Vcjs = require('./chunk-SB4VWA5V.cjs');
11
+ var _chunkVC4IV3AYcjs = require('./chunk-VC4IV3AY.cjs');
12
12
  require('./chunk-O67V3HJR.cjs');
13
13
  require('./chunk-3HPB4H4C.cjs');
14
14
  require('./chunk-DSVNFRY5.cjs');
@@ -21,7 +21,7 @@ require('./chunk-A6P6DHEZ.cjs');
21
21
  require('./chunk-MZ4KBSH7.cjs');
22
22
  require('./chunk-KLI4OSRA.cjs');
23
23
  require('./chunk-YUMFVQIN.cjs');
24
- require('./chunk-S2CA5WE4.cjs');
24
+ require('./chunk-CWRVTQUO.cjs');
25
25
 
26
26
 
27
27
  var _chunkBV5WZVOPcjs = require('./chunk-BV5WZVOP.cjs');
@@ -1905,7 +1905,7 @@ function KnowledgeScreen(_props) {
1905
1905
  const cast = _chunkII4QMH26cjs.useProductDemoCast.call(void 0, );
1906
1906
  const fixture = _react.useMemo.call(void 0, () => buildKnowledgeFixture(cast), [cast]);
1907
1907
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "h-full bg-ods-bg", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1908
- _chunkSB4VWA5Vcjs.KnowledgeBaseArticleView,
1908
+ _chunkVC4IV3AYcjs.KnowledgeBaseArticleView,
1909
1909
  {
1910
1910
  ...fixture.article,
1911
1911
  content: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBV5WZVOPcjs.SimpleMarkdownRenderer, { content: fixture.content, textSize: "compact" })
@@ -16,7 +16,7 @@ var _chunkKHXZFLINcjs = require('./chunk-KHXZFLIN.cjs');
16
16
 
17
17
 
18
18
 
19
- var _chunkSB4VWA5Vcjs = require('./chunk-SB4VWA5V.cjs');
19
+ var _chunkVC4IV3AYcjs = require('./chunk-VC4IV3AY.cjs');
20
20
  require('./chunk-O67V3HJR.cjs');
21
21
  require('./chunk-3HPB4H4C.cjs');
22
22
  require('./chunk-DSVNFRY5.cjs');
@@ -31,7 +31,7 @@ require('./chunk-KLI4OSRA.cjs');
31
31
  require('./chunk-YUMFVQIN.cjs');
32
32
 
33
33
 
34
- var _chunkS2CA5WE4cjs = require('./chunk-S2CA5WE4.cjs');
34
+ var _chunkCWRVTQUOcjs = require('./chunk-CWRVTQUO.cjs');
35
35
  require('./chunk-BV5WZVOP.cjs');
36
36
  require('./chunk-GABDE3FM.cjs');
37
37
  require('./chunk-3RFQPQ7Z.cjs');
@@ -1886,7 +1886,7 @@ function entry(logId, minutesAgo, severity, toolType, device2, summary) {
1886
1886
  id: logId,
1887
1887
  logId,
1888
1888
  timestamp: displayTime(_chunkKHXZFLINcjs.demoMinutesAgo.call(void 0, minutesAgo)),
1889
- status: { label: severity, variant: _chunkSB4VWA5Vcjs.logSeverityVariant.call(void 0, severity) },
1889
+ status: { label: severity, variant: _chunkVC4IV3AYcjs.logSeverityVariant.call(void 0, severity) },
1890
1890
  source: { name: toolType, toolType },
1891
1891
  device: device2,
1892
1892
  description: { title: summary }
@@ -1958,13 +1958,13 @@ var NO_FILTERS = {};
1958
1958
  var ACTION_COLUMNS = ["copy", "quickView", "open"];
1959
1959
  var BESIDE_DRAWER_HIDDEN = [...ACTION_COLUMNS, "tool", "source"];
1960
1960
  var logHref = () => "#";
1961
- var copyAction = () => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSB4VWA5Vcjs.LogCopyIconButton, {});
1961
+ var copyAction = () => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkVC4IV3AYcjs.LogCopyIconButton, {});
1962
1962
  function LogsScreen({ compact = false }) {
1963
1963
  const [dock, setDock] = _react.useState.call(void 0, null);
1964
1964
  const selected = LOGS_FIXTURE_SELECTED;
1965
1965
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex h-full bg-ods-bg", children: [
1966
1966
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "min-w-0 flex-1 overflow-clip", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1967
- _chunkSB4VWA5Vcjs.LogsPageView,
1967
+ _chunkVC4IV3AYcjs.LogsPageView,
1968
1968
  {
1969
1969
  showHeader: false,
1970
1970
  className: "p-[var(--spacing-system-l)]",
@@ -1972,7 +1972,7 @@ function LogsScreen({ compact = false }) {
1972
1972
  onSearchChange: noop,
1973
1973
  onOpenFilters: noop,
1974
1974
  children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1975
- _chunkSB4VWA5Vcjs.LogsTableView,
1975
+ _chunkVC4IV3AYcjs.LogsTableView,
1976
1976
  {
1977
1977
  logs: LOGS_FIXTURE_ENTRIES,
1978
1978
  facets: LOGS_FIXTURE_FACETS,
@@ -1986,8 +1986,8 @@ function LogsScreen({ compact = false }) {
1986
1986
  )
1987
1987
  }
1988
1988
  ) }),
1989
- !compact && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { ref: setDock, className: "relative w-[calc(400px+var(--spacing-system-m))] shrink-0", children: dock && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSB4VWA5Vcjs.AppLayoutDrawerContainerContext.Provider, { value: dock, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1990
- _chunkSB4VWA5Vcjs.LogDrawer,
1989
+ !compact && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { ref: setDock, className: "relative w-[calc(400px+var(--spacing-system-m))] shrink-0", children: dock && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkVC4IV3AYcjs.AppLayoutDrawerContainerContext.Provider, { value: dock, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1990
+ _chunkVC4IV3AYcjs.LogDrawer,
1991
1991
  {
1992
1992
  docked: true,
1993
1993
  isOpen: true,
@@ -1999,12 +1999,12 @@ function LogsScreen({ compact = false }) {
1999
1999
  { label: "Log ID", value: selected.logId },
2000
2000
  {
2001
2001
  label: "Source",
2002
- value: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSB4VWA5Vcjs.ToolBadge, { toolType: _chunkS2CA5WE4cjs.normalizeToolTypeWithFallback.call(void 0, selected.source.toolType) })
2002
+ value: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkVC4IV3AYcjs.ToolBadge, { toolType: _chunkCWRVTQUOcjs.normalizeToolTypeWithFallback.call(void 0, selected.source.toolType) })
2003
2003
  },
2004
- { label: "Device", value: _chunkSB4VWA5Vcjs.logSourceLabels.call(void 0, selected.device).deviceName }
2004
+ { label: "Device", value: _chunkVC4IV3AYcjs.logSourceLabels.call(void 0, selected.device).deviceName }
2005
2005
  ],
2006
2006
  deviceCard: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
2007
- _chunkSB4VWA5Vcjs.DeviceCard,
2007
+ _chunkVC4IV3AYcjs.DeviceCard,
2008
2008
  {
2009
2009
  ...LOGS_FIXTURE_DEVICE,
2010
2010
  actions: {
@@ -10,7 +10,7 @@ var _chunkKHXZFLINcjs = require('./chunk-KHXZFLIN.cjs');
10
10
 
11
11
 
12
12
 
13
- var _chunkSB4VWA5Vcjs = require('./chunk-SB4VWA5V.cjs');
13
+ var _chunkVC4IV3AYcjs = require('./chunk-VC4IV3AY.cjs');
14
14
  require('./chunk-O67V3HJR.cjs');
15
15
  require('./chunk-3HPB4H4C.cjs');
16
16
  require('./chunk-DSVNFRY5.cjs');
@@ -23,7 +23,7 @@ require('./chunk-A6P6DHEZ.cjs');
23
23
  require('./chunk-MZ4KBSH7.cjs');
24
24
  require('./chunk-KLI4OSRA.cjs');
25
25
  require('./chunk-YUMFVQIN.cjs');
26
- require('./chunk-S2CA5WE4.cjs');
26
+ require('./chunk-CWRVTQUO.cjs');
27
27
  require('./chunk-BV5WZVOP.cjs');
28
28
  require('./chunk-GABDE3FM.cjs');
29
29
  require('./chunk-3RFQPQ7Z.cjs');
@@ -1891,14 +1891,14 @@ var POLICIES = [
1891
1891
  policy("policy-local-admins", "No local admins", "No everyday account is a local administrator.", false, 0)
1892
1892
  ];
1893
1893
  var POLICIES_FIXTURE = {
1894
- summary: _chunkSB4VWA5Vcjs.computePolicySummary.call(void 0, POLICIES),
1894
+ summary: _chunkVC4IV3AYcjs.computePolicySummary.call(void 0, POLICIES),
1895
1895
  rows: POLICIES.map((item) => ({
1896
1896
  id: item.id,
1897
1897
  name: item.name,
1898
1898
  description: item.description,
1899
1899
  critical: item.critical,
1900
1900
  severityLabel: item.critical ? "Critical" : "Low",
1901
- status: _chunkSB4VWA5Vcjs.getPolicyTableStatus.call(void 0, item),
1901
+ status: _chunkVC4IV3AYcjs.getPolicyTableStatus.call(void 0, item),
1902
1902
  actions: [
1903
1903
  { label: "Policy Details", onClick: noop },
1904
1904
  { label: "Delete Policy", onClick: noop }
@@ -1912,16 +1912,16 @@ var POLICIES_FIXTURE = {
1912
1912
  var _jsxruntime = require('react/jsx-runtime');
1913
1913
  function PoliciesScreen({ compact = false }) {
1914
1914
  const table = /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1915
- _chunkSB4VWA5Vcjs.PoliciesTable,
1915
+ _chunkVC4IV3AYcjs.PoliciesTable,
1916
1916
  {
1917
1917
  rows: POLICIES_FIXTURE.rows,
1918
1918
  rowAsLink: true,
1919
- rightSlot: compact ? void 0 : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSB4VWA5Vcjs.DataTable.RowCount, {}),
1919
+ rightSlot: compact ? void 0 : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkVC4IV3AYcjs.DataTable.RowCount, {}),
1920
1920
  emptyMessage: "No policies found."
1921
1921
  }
1922
1922
  );
1923
1923
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex h-full flex-col gap-[var(--spacing-system-l)] bg-ods-bg p-[var(--spacing-system-l)]", children: [
1924
- !compact && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSB4VWA5Vcjs.PolicySummaryCards, { summary: POLICIES_FIXTURE.summary, now: POLICIES_FIXTURE.now }),
1924
+ !compact && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkVC4IV3AYcjs.PolicySummaryCards, { summary: POLICIES_FIXTURE.summary, now: POLICIES_FIXTURE.now }),
1925
1925
  table
1926
1926
  ] });
1927
1927
  }
@@ -15,7 +15,7 @@ var _chunkKHXZFLINcjs = require('./chunk-KHXZFLIN.cjs');
15
15
 
16
16
 
17
17
 
18
- var _chunkSB4VWA5Vcjs = require('./chunk-SB4VWA5V.cjs');
18
+ var _chunkVC4IV3AYcjs = require('./chunk-VC4IV3AY.cjs');
19
19
  require('./chunk-O67V3HJR.cjs');
20
20
  require('./chunk-3HPB4H4C.cjs');
21
21
 
@@ -30,7 +30,7 @@ require('./chunk-A6P6DHEZ.cjs');
30
30
  require('./chunk-MZ4KBSH7.cjs');
31
31
  require('./chunk-KLI4OSRA.cjs');
32
32
  require('./chunk-YUMFVQIN.cjs');
33
- require('./chunk-S2CA5WE4.cjs');
33
+ require('./chunk-CWRVTQUO.cjs');
34
34
  require('./chunk-BV5WZVOP.cjs');
35
35
  require('./chunk-GABDE3FM.cjs');
36
36
  require('./chunk-3RFQPQ7Z.cjs');
@@ -1926,12 +1926,12 @@ function StaticPackageField({ value }) {
1926
1926
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1927
1927
  _chunkDSVNFRY5cjs.Autocomplete,
1928
1928
  {
1929
- label: _chunkSB4VWA5Vcjs.PACKAGE_SEARCH_LABEL,
1929
+ label: _chunkVC4IV3AYcjs.PACKAGE_SEARCH_LABEL,
1930
1930
  labelVariant: "large",
1931
1931
  options: value ? [{ value: value.id, label: value.name, description: _nullishCoalesce(value.description, () => ( void 0)) }] : [],
1932
1932
  value: _nullishCoalesce(_optionalChain([value, 'optionalAccess', _ => _.id]), () => ( null)),
1933
1933
  onChange: noop,
1934
- placeholder: _chunkSB4VWA5Vcjs.PACKAGE_SEARCH_PLACEHOLDER
1934
+ placeholder: _chunkVC4IV3AYcjs.PACKAGE_SEARCH_PLACEHOLDER
1935
1935
  }
1936
1936
  );
1937
1937
  }
@@ -1945,7 +1945,7 @@ function SoftwareUpdateScreen({ compact = false }) {
1945
1945
  [fixture.devices, fixture.selectedIds]
1946
1946
  );
1947
1947
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "h-full bg-ods-bg pt-[var(--spacing-system-l)]", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "h-full", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1948
- _chunkSB4VWA5Vcjs.SoftwareActionForm,
1948
+ _chunkVC4IV3AYcjs.SoftwareActionForm,
1949
1949
  {
1950
1950
  action: fixture.action,
1951
1951
  showHeader: false,
@@ -1957,7 +1957,7 @@ function SoftwareUpdateScreen({ compact = false }) {
1957
1957
  initialValues: fixture.initialValues,
1958
1958
  renderPackageSearch,
1959
1959
  renderDevicePicker: () => /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
1960
- _chunkSB4VWA5Vcjs.DeviceSelector,
1960
+ _chunkVC4IV3AYcjs.DeviceSelector,
1961
1961
  {
1962
1962
  devices: selected,
1963
1963
  loading: false,
@@ -85083,6 +85083,12 @@ function captureFormRescueEvent(event, properties) {
85083
85083
  }
85084
85084
  }
85085
85085
 
85086
+ // src/utils/legal-documents.ts
85087
+ var LEGAL_DOCUMENT_TYPES = ["privacy", "terms", "payment", "license", "security"];
85088
+ function isLegalDocumentType(value) {
85089
+ return LEGAL_DOCUMENT_TYPES.includes(value);
85090
+ }
85091
+
85086
85092
  // src/utils/doc-tree-nav.ts
85087
85093
  var DEFAULT_FOLDER_INDEX_FILE = "README.md";
85088
85094
  var DEFAULT_FOLDER_INDEX = DEFAULT_FOLDER_INDEX_FILE;
@@ -85953,6 +85959,7 @@ exports.HUB_HEADER_OFFSET_PX = HUB_HEADER_OFFSET_PX;
85953
85959
  exports.HUMANITY_SIGNAL_KEYS = HUMANITY_SIGNAL_KEYS;
85954
85960
  exports.ICON_REGISTRY = ICON_REGISTRY;
85955
85961
  exports.IMAGE_FILE_ACCEPT = IMAGE_FILE_ACCEPT;
85962
+ exports.LEGAL_DOCUMENT_TYPES = LEGAL_DOCUMENT_TYPES;
85956
85963
  exports.LOCATION_HASH_SYNC_EVENT = LOCATION_HASH_SYNC_EVENT;
85957
85964
  exports.MAX_MONTH_OFFSET = MAX_MONTH_OFFSET;
85958
85965
  exports.MEDIA_FILE_ACCEPT = MEDIA_FILE_ACCEPT;
@@ -86212,6 +86219,7 @@ exports.isGenericDomain = isGenericDomain;
86212
86219
  exports.isGenericWebsiteDomain = isGenericWebsiteDomain;
86213
86220
  exports.isHumanitySignalKey = isHumanitySignalKey;
86214
86221
  exports.isImageMedia = isImageMedia;
86222
+ exports.isLegalDocumentType = isLegalDocumentType;
86215
86223
  exports.isListedSchedulingName = isListedSchedulingName;
86216
86224
  exports.isLocalUrl = isLocalUrl;
86217
86225
  exports.isOSPlatform = isOSPlatform;
@@ -73,6 +73,7 @@ export { buildSuggestionUrl, type SuggestionUrlOptions } from './suggestion-url'
73
73
  export { DEFAULT_CONTENT_SUFFIXES, makeComposeContentUrl, buildDefaultHref, type ContentHrefOptions, type ComposeContentUrl, type ComposedContentUrl, } from './content-href';
74
74
  export * from './humanity-signals';
75
75
  export * from './form-rescue';
76
+ export * from './legal-documents';
76
77
  export * from './doc-path-utils';
77
78
  export * from './doc-tree-nav';
78
79
  export * from './tree-builder';
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/utils/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,EAAE,EAAE,MAAM,MAAM,CAAC;AAK1B,OAAO,EACL,cAAc,EACd,wBAAwB,EACxB,yBAAyB,EACzB,gBAAgB,EAChB,gBAAgB,EAChB,UAAU,EACV,qBAAqB,GACtB,MAAM,qBAAqB,CAAC;AAI7B,OAAO,EAAE,UAAU,EAAE,YAAY,EAAE,WAAW,EAAE,WAAW,EAAE,mBAAmB,EAAE,MAAM,UAAU,CAAC;AACnG,cAAc,gBAAgB,CAAC;AAC/B,cAAc,qBAAqB,CAAC;AACpC,OAAO,EAAE,WAAW,EAAE,WAAW,EAAE,gBAAgB,EAAE,MAAM,SAAS,CAAC;AACrE,OAAO,EACL,sBAAsB,EACtB,yBAAyB,EACzB,sBAAsB,EACtB,yBAAyB,EACzB,KAAK,yBAAyB,EAC9B,KAAK,uBAAuB,EAC5B,KAAK,2BAA2B,GACjC,MAAM,yBAAyB,CAAC;AAEjC,OAAO,EAAE,cAAc,EAAE,MAAM,2DAA2D,CAAC;AAC3F,OAAO,EACL,sBAAsB,EACtB,kBAAkB,EAClB,iBAAiB,EACjB,iBAAiB,EACjB,mBAAmB,EACnB,gBAAgB,EAChB,KAAK,aAAa,EAClB,WAAW,EAGX,oBAAoB,EACpB,QAAQ,EACR,QAAQ,EACR,gBAAgB,EAChB,iBAAiB,GAClB,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EACL,YAAY,EACZ,KAAK,EACL,oBAAoB,EACpB,cAAc,EACd,SAAS,EACT,wBAAwB,EACxB,eAAe,EACf,KAAK,EACL,IAAI,EACJ,eAAe,GAChB,MAAM,UAAU,CAAC;AAClB,OAAO,EAAE,YAAY,EAAE,MAAM,i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E,MAAM,kBAAkB,CAAC;AACjD,cAAc,gBAAgB,CAAC;AAC/B,cAAc,aAAa,CAAC;AAC5B,cAAc,cAAc,CAAC;AAC7B,cAAc,iBAAiB,CAAC"}
@@ -231,6 +231,7 @@ import {
231
231
  } from "./content-href.js";
232
232
  export * from "./humanity-signals.js";
233
233
  export * from "./form-rescue.js";
234
+ export * from "./legal-documents.js";
234
235
  export * from "./doc-path-utils.js";
235
236
  export * from "./doc-tree-nav.js";
236
237
  export * from "./tree-builder.js";
@@ -0,0 +1,18 @@
1
+ /**
2
+ * The types of legal document a hub can publish, each with a page of its own
3
+ * (`/api/legal/<type>`, `<LegalDocumentPage docType>`).
4
+ *
5
+ * WHICH of them are published, and each one's title, version and effective
6
+ * date, is the hub's answer at run time (`GET /api/legal`, `useLegalDocuments`).
7
+ * This list exists for a host that must know every possible page before it
8
+ * runs: a statically exported app prerenders one legal page per type here and
9
+ * links only the ones the hub's list says are published.
10
+ *
11
+ * Pure and server-safe. The hub's own list of legal documents carries exactly
12
+ * these types.
13
+ */
14
+ export declare const LEGAL_DOCUMENT_TYPES: readonly ["privacy", "terms", "payment", "license", "security"];
15
+ export type LegalDocumentType = (typeof LEGAL_DOCUMENT_TYPES)[number];
16
+ /** True for a type a host has a page for (one of {@link LEGAL_DOCUMENT_TYPES}). */
17
+ export declare function isLegalDocumentType(value: string): value is LegalDocumentType;
18
+ //# sourceMappingURL=legal-documents.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"legal-documents.d.ts","sourceRoot":"","sources":["../../src/utils/legal-documents.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AACH,eAAO,MAAM,oBAAoB,iEAAkE,CAAC;AAEpG,MAAM,MAAM,iBAAiB,GAAG,CAAC,OAAO,oBAAoB,CAAC,CAAC,MAAM,CAAC,CAAC;AAEtE,mFAAmF;AACnF,wBAAgB,mBAAmB,CAAC,KAAK,EAAE,MAAM,GAAG,KAAK,IAAI,iBAAiB,CAE7E"}
@@ -0,0 +1,8 @@
1
+ const LEGAL_DOCUMENT_TYPES = ["privacy", "terms", "payment", "license", "security"];
2
+ function isLegalDocumentType(value) {
3
+ return LEGAL_DOCUMENT_TYPES.includes(value);
4
+ }
5
+ export {
6
+ LEGAL_DOCUMENT_TYPES,
7
+ isLegalDocumentType
8
+ };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@flamingo-stack/openframe-frontend-core",
3
- "version": "0.0.739",
3
+ "version": "0.0.740",
4
4
  "description": "Shared design system and components for all Flamingo platforms",
5
5
  "type": "module",
6
6
  "sideEffects": [
@@ -8,7 +8,15 @@
8
8
 
9
9
  export {
10
10
  LegalDocumentPage,
11
+ legalDocumentStampLabel,
11
12
  type LegalDocumentPageProps,
12
13
  type LegalDocumentMarkdownRendererProps,
13
14
  } from './legal-document-page';
14
15
  export { useLegalDocs, type LegalDocument, type UseLegalDocsOptions, type UseLegalDocsReturn } from './use-legal-docs';
16
+ export {
17
+ useLegalDocuments,
18
+ toLegalDocumentSummaries,
19
+ type LegalDocumentSummary,
20
+ type UseLegalDocumentsOptions,
21
+ type UseLegalDocumentsReturn,
22
+ } from './use-legal-documents';
@@ -25,6 +25,7 @@ import { FaqSection, pageFaqProps, type PageFaqSlot } from '../../faq/faq-sectio
25
25
  import { PageShell, PageLayout } from '../../ui';
26
26
  import { RichMarkdownRenderer } from '../../ui/markdown';
27
27
  import { useLegalDocs, type LegalDocument } from './use-legal-docs';
28
+ import { useLegalDocuments } from './use-legal-documents';
28
29
 
29
30
  export interface LegalDocumentMarkdownRendererProps {
30
31
  content: string;
@@ -34,25 +35,24 @@ export interface LegalDocumentMarkdownRendererProps {
34
35
 
35
36
  export interface LegalDocumentPageProps {
36
37
  /** Document type identifier — drives the default API endpoint
37
- * `/api/legal/<docType>` AND the error-log prefix. Common values:
38
- * `'privacy'`, `'terms'`. Embedders may use any string. */
38
+ * `/api/legal/<docType>` AND the error-log prefix. One of the types the
39
+ * host's list answers (`useLegalDocuments`). */
39
40
  docType: string;
40
- /** Heading text (e.g. "Privacy Policy", "Terms of Service"). */
41
- title: string;
42
- /** Fallback subtitle shown when no `lastUpdated` date is available
43
- * (e.g. "Our privacy policy and data protection practices"). */
44
- fallbackDescription: string;
45
- /** Email shown in the error + empty-state copy
46
- * (e.g. `'privacy@openframe.io'`, `'legal@openframe.io'`). */
47
- contactEmail: string;
48
- /** Prompt shown above the contact link in the error state
49
- * (e.g. "For privacy-related questions, please contact:"). */
50
- errorContactPrompt: string;
51
- /** Title for the error block (e.g. "Unable to load privacy policy"). */
52
- errorTitle: string;
53
- /** Sentence shown when the API returns no document
54
- * (e.g. "Privacy policy content is not available at this time."). */
55
- emptyStateMessage: string;
41
+ /** Heading text. Default: the title the served document carries, so a host
42
+ * that shows whatever the list holds states no per-document copy. */
43
+ title?: string;
44
+ /** Subtitle shown when the document states neither a version nor a date. */
45
+ fallbackDescription?: string;
46
+ /** Email shown in the error + empty-state copy. Absent: no contact line. */
47
+ contactEmail?: string;
48
+ /** Prompt shown above the contact link in the error state.
49
+ * Default "For questions about this document, please contact:". */
50
+ errorContactPrompt?: string;
51
+ /** Title for the error block. Default "Unable to load <title>". */
52
+ errorTitle?: string;
53
+ /** Sentence shown when the API returns no document.
54
+ * Default "<title> is not available at this time.". */
55
+ emptyStateMessage?: string;
56
56
  /** SSR-prepared document, if available. */
57
57
  initialData?: LegalDocument | null;
58
58
  /** SSR-prepared formatted "Last Updated" label. Stable across hydration. */
@@ -66,29 +66,52 @@ export interface LegalDocumentPageProps {
66
66
  * to hide. Default `{ label: 'Back to home', href: '/' }`. */
67
67
  backButton?: { label?: string; href?: string } | false;
68
68
  /**
69
- * The page's own FAQ block: the topic the page is about (stated by the host,
70
- * never read from its address) and where the host serves the FAQs. Rendered
71
- * after the page's content, inside its container. Absent: no FAQ block.
69
+ * The hub's list of legal documents (`GET /api/legal`). Given it, the page
70
+ * takes the document's title and FAQ topic from the list, so a host passes
71
+ * only the type and its endpoints and states nothing per document; the title
72
+ * then names the document even when its text fails to load.
72
73
  */
73
- faq?: PageFaqSlot;
74
+ documentsEndpoint?: string;
75
+ /**
76
+ * The page's own FAQ block: the topic the page is about and where the host
77
+ * serves the FAQs. Rendered after the page's content, inside its container.
78
+ * Without a `topic`, the topic is the one the list (`documentsEndpoint`)
79
+ * gives the document. Absent, or no topic known: no FAQ block.
80
+ */
81
+ faq?: PageFaqSlot | Omit<PageFaqSlot, 'topic'>;
74
82
  /** Render the standalone `<PageShell>`. Default true. Pass false when the host
75
83
  * layout already provides the page container — only the padding box renders,
76
84
  * avoiding a nested `<main>`. */
77
85
  shell?: boolean;
78
86
  }
79
87
 
88
+ /**
89
+ * "Version 1.0 · Effective October 14, 2026" for a document that states them;
90
+ * null for one that states neither. One wording for every legal surface.
91
+ */
92
+ export function legalDocumentStampLabel(
93
+ doc: Pick<LegalDocument, 'version' | 'effectiveDate'> | null | undefined,
94
+ ): string | null {
95
+ const parts = [
96
+ doc?.version ? `Version ${doc.version}` : null,
97
+ doc?.effectiveDate ? `Effective ${doc.effectiveDate}` : null,
98
+ ].filter((part): part is string => part !== null);
99
+ return parts.length > 0 ? parts.join(' \u00b7 ') : null;
100
+ }
101
+
80
102
  export function LegalDocumentPage({
81
103
  docType,
82
- title,
83
- fallbackDescription,
104
+ title: titleProp,
105
+ fallbackDescription = '',
84
106
  contactEmail,
85
- errorContactPrompt,
86
- errorTitle,
87
- emptyStateMessage,
107
+ errorContactPrompt = 'For questions about this document, please contact:',
108
+ errorTitle: errorTitleProp,
109
+ emptyStateMessage: emptyStateMessageProp,
88
110
  initialData = null,
89
111
  initialLastUpdatedLabel = null,
90
112
  apiEndpoint,
91
113
  MarkdownRenderer = RichMarkdownRenderer,
114
+ documentsEndpoint,
92
115
  backButton,
93
116
  faq,
94
117
  shell = true,
@@ -107,13 +130,25 @@ export function LegalDocumentPage({
107
130
  onClick: () => router.push(backButton?.href ?? '/'),
108
131
  };
109
132
 
133
+ const { documents } = useLegalDocuments({ apiEndpoint: documentsEndpoint, enabled: Boolean(documentsEndpoint) });
134
+ const listed = documents.find(doc => doc.docType === docType);
135
+ const title = titleProp ?? data?.title ?? listed?.title ?? 'Legal document';
136
+ const faqTopic = faq && 'topic' in faq ? faq.topic : listed?.faqTopic;
137
+ const faqSlot = faq && faqTopic ? { ...faq, topic: faqTopic } : null;
138
+ const errorTitle = errorTitleProp ?? `Unable to load ${title}`;
139
+ const emptyStateMessage = emptyStateMessageProp ?? `${title} is not available at this time.`;
140
+
110
141
  const fallbackLastUpdatedLabel = data?.lastSynced != null ? formatLegalDate(data.lastSynced) : null;
111
142
  const effectiveLastUpdatedLabel = initialLastUpdatedLabel ?? fallbackLastUpdatedLabel;
112
143
 
113
144
  // Subtitle routes through the frozen `PageLayout` `TitleBlock` (text-h2 title
114
- // + subtitle) — unified header across all help-center pages. Shows the
115
- // last-updated date when known, else the fallback description.
116
- const subtitle = effectiveLastUpdatedLabel ? `Last Updated: ${effectiveLastUpdatedLabel}` : fallbackDescription;
145
+ // + subtitle) — unified header across all help-center pages. A document that
146
+ // states its own version and effective date shows those (they are what a
147
+ // reader agreed to); one that states neither shows when it was last read
148
+ // from its source, else the fallback description.
149
+ const subtitle =
150
+ legalDocumentStampLabel(data) ??
151
+ (effectiveLastUpdatedLabel ? `Last Updated: ${effectiveLastUpdatedLabel}` : fallbackDescription);
117
152
 
118
153
  const inner = (
119
154
  <PageLayout title={title} subtitle={subtitle} backButton={backCfg} titleSize="h1" titleWrap>
@@ -144,32 +179,36 @@ export function LegalDocumentPage({
144
179
  <p className="mb-2 text-ods-error">{errorTitle}</p>
145
180
  <p className="text-ods-error text-h6">{error}</p>
146
181
  </div>
147
- <div className="text-ods-text-secondary">
148
- <p>{errorContactPrompt}</p>
149
- <Link href={`mailto:${contactEmail}`} className="text-ods-accent hover:underline">
150
- {contactEmail}
151
- </Link>
152
- </div>
182
+ {contactEmail && (
183
+ <div className="text-ods-text-secondary">
184
+ <p>{errorContactPrompt}</p>
185
+ <Link href={`mailto:${contactEmail}`} className="text-ods-accent hover:underline">
186
+ {contactEmail}
187
+ </Link>
188
+ </div>
189
+ )}
153
190
  </div>
154
191
  ) : data ? (
155
192
  <MarkdownRenderer content={data.content} sectionIds={data.sections || []} demoteMarkdownH1ToH2 />
156
193
  ) : (
157
194
  <div className="py-16 text-center text-ods-text-secondary">
158
195
  <p className="text-h4">{emptyStateMessage}</p>
159
- <p className="mt-2">
160
- Please contact{' '}
161
- <Link href={`mailto:${contactEmail}`} className="text-ods-accent hover:underline">
162
- {contactEmail}
163
- </Link>{' '}
164
- for more information.
165
- </p>
196
+ {contactEmail && (
197
+ <p className="mt-2">
198
+ Please contact{' '}
199
+ <Link href={`mailto:${contactEmail}`} className="text-ods-accent hover:underline">
200
+ {contactEmail}
201
+ </Link>{' '}
202
+ for more information.
203
+ </p>
204
+ )}
166
205
  </div>
167
206
  )}
168
207
  </article>
169
208
  </div>
170
209
  </div>
171
210
  </div>
172
- {faq && <FaqSection {...pageFaqProps(faq)} />}
211
+ {faqSlot && <FaqSection {...pageFaqProps(faqSlot)} />}
173
212
  </PageLayout>
174
213
  );
175
214
 
@@ -24,6 +24,10 @@ export interface LegalDocument {
24
24
  githubSha: string | null;
25
25
  sections: Array<{ id: string; title: string; level: number }>;
26
26
  docType: string;
27
+ /** The version the document states for itself ("1.0"); null when it states none. */
28
+ version: string | null;
29
+ /** The day that version takes effect, as the document words it; null when it states none. */
30
+ effectiveDate: string | null;
27
31
  meta: {
28
32
  sectionsCount: number;
29
33
  contentLength: number;
@@ -111,6 +115,8 @@ function toLegalDocument(payload: unknown, docType: string): LegalDocument | nul
111
115
  githubSha: typeof githubSha === 'string' ? githubSha : null,
112
116
  sections,
113
117
  docType: readString(payload, 'docType') ?? docType,
118
+ version: readString(payload, 'version') ?? null,
119
+ effectiveDate: readString(payload, 'effectiveDate') ?? null,
114
120
  meta: {
115
121
  sectionsCount: typeof sectionsCount === 'number' ? sectionsCount : sections.length,
116
122
  contentLength: typeof contentLength === 'number' ? contentLength : content.length,
@@ -122,9 +128,9 @@ function toLegalDocument(payload: unknown, docType: string): LegalDocument | nul
122
128
  /**
123
129
  * Hook to fetch a legal document.
124
130
  * @param docType — short identifier for the document (drives the
125
- * default endpoint path AND the error-log prefix). Common values:
126
- * `'privacy'` (SECURITY.md), `'terms'` (LICENSE). Embedders may use
127
- * any string — the hook treats it as opaque.
131
+ * default endpoint path AND the error-log prefix). The valid values are
132
+ * the ones the host's list endpoint answers (`useLegalDocuments`); the
133
+ * hook treats it as opaque.
128
134
  */
129
135
  export function useLegalDocs(docType: string, options: UseLegalDocsOptions = {}): UseLegalDocsReturn {
130
136
  const { initialData = null, apiEndpoint } = options;
@@ -183,6 +189,15 @@ export function useLegalDocs(docType: string, options: UseLegalDocsOptions = {})
183
189
  try {
184
190
  const response = await contentFetch(effectiveEndpoint);
185
191
 
192
+ // 404: the hub has no published text for this document yet (a legal
193
+ // file is published only once it states its version and effective
194
+ // date). That is "not available", not a failure: no data, no error.
195
+ if (response.status === 404) {
196
+ if (!isCurrent()) return;
197
+ setData(null);
198
+ return;
199
+ }
200
+
186
201
  if (!response.ok) {
187
202
  throw new Error(`Failed to fetch ${docType} document: ${response.status} ${response.statusText}`);
188
203
  }