@flamingo-stack/openframe-frontend-core 0.0.686 → 0.0.687
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/{chunk-QTXDXHMD.cjs → chunk-3ADAUFKK.cjs} +22 -22
- package/dist/{chunk-QTXDXHMD.cjs.map → chunk-3ADAUFKK.cjs.map} +1 -1
- package/dist/{chunk-2G2CB7ZZ.js → chunk-3IANMZFS.js} +5 -5
- package/dist/{chunk-WJX3ZSOE.cjs → chunk-3RNG4MJN.cjs} +33 -33
- package/dist/{chunk-WJX3ZSOE.cjs.map → chunk-3RNG4MJN.cjs.map} +1 -1
- package/dist/{chunk-ASBBGP36.js → chunk-4GQ7VWAR.js} +5 -5
- package/dist/{chunk-II5GVLTN.cjs → chunk-4THS6V3I.cjs} +5 -5
- package/dist/{chunk-II5GVLTN.cjs.map → chunk-4THS6V3I.cjs.map} +1 -1
- package/dist/{chunk-WFH52OVQ.js → chunk-A2ZP6WX4.js} +5 -5
- package/dist/{chunk-U6JC3RS2.js → chunk-APLL2BVR.js} +2 -2
- package/dist/{chunk-4LBCUBVL.cjs → chunk-BZKDFMZM.cjs} +45 -45
- package/dist/{chunk-4LBCUBVL.cjs.map → chunk-BZKDFMZM.cjs.map} +1 -1
- package/dist/{chunk-ZS3YCJYY.cjs → chunk-CDCUUEL4.cjs} +4 -4
- package/dist/{chunk-ZS3YCJYY.cjs.map → chunk-CDCUUEL4.cjs.map} +1 -1
- package/dist/{chunk-MZAZUSPQ.cjs → chunk-CKQ4ZBDN.cjs} +10 -10
- package/dist/{chunk-MZAZUSPQ.cjs.map → chunk-CKQ4ZBDN.cjs.map} +1 -1
- package/dist/{chunk-NINO3PI7.js → chunk-DGOUPZJ7.js} +2 -2
- package/dist/{chunk-RBCMBRI7.cjs → chunk-DYNWIHFU.cjs} +26 -26
- package/dist/{chunk-RBCMBRI7.cjs.map → chunk-DYNWIHFU.cjs.map} +1 -1
- package/dist/{chunk-PG65AE3I.js → chunk-ENIABTA5.js} +3 -3
- package/dist/{chunk-3NIZ2VLQ.js → chunk-GXKAWMDT.js} +2 -2
- package/dist/{chunk-N3I53B5W.cjs → chunk-HHNKNOZU.cjs} +3 -3
- package/dist/{chunk-N3I53B5W.cjs.map → chunk-HHNKNOZU.cjs.map} +1 -1
- package/dist/{chunk-C5TFPMOM.js → chunk-IR6PWTCL.js} +4 -4
- package/dist/{chunk-QOH45QSE.js → chunk-JSXNOXZQ.js} +3 -3
- package/dist/{chunk-SI77HF4U.cjs → chunk-LL35WZZS.cjs} +3 -3
- package/dist/chunk-LL35WZZS.cjs.map +1 -0
- package/dist/{chunk-MHTB67ZH.js → chunk-LROQXUFX.js} +2 -2
- package/dist/{chunk-GETQTNRV.cjs → chunk-QRZ5LS6A.cjs} +22 -22
- package/dist/{chunk-GETQTNRV.cjs.map → chunk-QRZ5LS6A.cjs.map} +1 -1
- package/dist/{chunk-4RJQMOQW.js → chunk-R4MKXLRJ.js} +6 -6
- package/dist/{chunk-3DO76UAB.cjs → chunk-RHBFZC6F.cjs} +15 -15
- package/dist/{chunk-3DO76UAB.cjs.map → chunk-RHBFZC6F.cjs.map} +1 -1
- package/dist/{chunk-RKH7DEDF.cjs → chunk-RVO77GSL.cjs} +10 -10
- package/dist/{chunk-RKH7DEDF.cjs.map → chunk-RVO77GSL.cjs.map} +1 -1
- package/dist/{chunk-IELOPDTA.js → chunk-S6SGPLA4.js} +3 -3
- package/dist/{chunk-LCOMNQLX.js → chunk-SFY2E5DG.js} +3 -3
- package/dist/{chunk-JBJZL5PI.js → chunk-SQQQVVV2.js} +3 -3
- package/dist/{chunk-YPXXXX6R.js → chunk-SR2C5SJJ.js} +3 -3
- package/dist/chunk-SR2C5SJJ.js.map +1 -0
- package/dist/{chunk-IBUFFKAK.cjs → chunk-T32BTPL5.cjs} +339 -339
- package/dist/{chunk-IBUFFKAK.cjs.map → chunk-T32BTPL5.cjs.map} +1 -1
- package/dist/{chunk-RSMAVO2Z.js → chunk-W4CHRA6G.js} +2 -2
- package/dist/{chunk-UBXEETWQ.cjs → chunk-WIUDKYAQ.cjs} +71 -71
- package/dist/{chunk-UBXEETWQ.cjs.map → chunk-WIUDKYAQ.cjs.map} +1 -1
- package/dist/{chunk-P4SBHO7U.cjs → chunk-WMOELYDL.cjs} +10 -10
- package/dist/{chunk-P4SBHO7U.cjs.map → chunk-WMOELYDL.cjs.map} +1 -1
- package/dist/{chunk-AF4XOURN.cjs → chunk-XEESEFGT.cjs} +3 -3
- package/dist/{chunk-AF4XOURN.cjs.map → chunk-XEESEFGT.cjs.map} +1 -1
- package/dist/components/case-studies/index.cjs +14 -14
- package/dist/components/case-studies/index.js +3 -3
- package/dist/components/chat/approval-batch-message.d.ts.map +1 -1
- package/dist/components/chat/index.cjs +2 -2
- package/dist/components/chat/index.js +1 -1
- package/dist/components/chat/tool-execution-display.d.ts.map +1 -1
- package/dist/components/contact/index.cjs +4 -4
- package/dist/components/contact/index.js +3 -3
- package/dist/components/docs/index.cjs +7 -7
- package/dist/components/docs/index.js +6 -6
- package/dist/components/embeds/index.cjs +4 -4
- package/dist/components/embeds/index.js +3 -3
- package/dist/components/faq/index.cjs +4 -4
- package/dist/components/faq/index.js +3 -3
- package/dist/components/features/index.cjs +3 -3
- package/dist/components/features/index.js +2 -2
- package/dist/components/help-center-pages/index.cjs +73 -73
- package/dist/components/help-center-pages/index.js +14 -14
- package/dist/components/index.cjs +40 -40
- package/dist/components/index.js +13 -13
- package/dist/components/meeting-scheduler/index.cjs +25 -25
- package/dist/components/meeting-scheduler/index.js +2 -2
- package/dist/components/navigation/index.cjs +6 -6
- package/dist/components/navigation/index.js +5 -5
- package/dist/components/onboarding-guides/index.cjs +6 -6
- package/dist/components/onboarding-guides/index.js +5 -5
- package/dist/components/tickets/index.cjs +7 -7
- package/dist/components/tickets/index.js +6 -6
- package/dist/components/ui/index.cjs +3 -3
- package/dist/components/ui/index.js +2 -2
- package/dist/index.cjs +7 -7
- package/dist/index.js +6 -6
- package/package.json +1 -1
- package/src/components/chat/approval-batch-message.tsx +3 -1
- package/src/components/chat/tool-execution-display.tsx +2 -1
- package/dist/chunk-SI77HF4U.cjs.map +0 -1
- package/dist/chunk-YPXXXX6R.js.map +0 -1
- /package/dist/{chunk-2G2CB7ZZ.js.map → chunk-3IANMZFS.js.map} +0 -0
- /package/dist/{chunk-ASBBGP36.js.map → chunk-4GQ7VWAR.js.map} +0 -0
- /package/dist/{chunk-WFH52OVQ.js.map → chunk-A2ZP6WX4.js.map} +0 -0
- /package/dist/{chunk-U6JC3RS2.js.map → chunk-APLL2BVR.js.map} +0 -0
- /package/dist/{chunk-NINO3PI7.js.map → chunk-DGOUPZJ7.js.map} +0 -0
- /package/dist/{chunk-PG65AE3I.js.map → chunk-ENIABTA5.js.map} +0 -0
- /package/dist/{chunk-3NIZ2VLQ.js.map → chunk-GXKAWMDT.js.map} +0 -0
- /package/dist/{chunk-C5TFPMOM.js.map → chunk-IR6PWTCL.js.map} +0 -0
- /package/dist/{chunk-QOH45QSE.js.map → chunk-JSXNOXZQ.js.map} +0 -0
- /package/dist/{chunk-MHTB67ZH.js.map → chunk-LROQXUFX.js.map} +0 -0
- /package/dist/{chunk-4RJQMOQW.js.map → chunk-R4MKXLRJ.js.map} +0 -0
- /package/dist/{chunk-IELOPDTA.js.map → chunk-S6SGPLA4.js.map} +0 -0
- /package/dist/{chunk-LCOMNQLX.js.map → chunk-SFY2E5DG.js.map} +0 -0
- /package/dist/{chunk-JBJZL5PI.js.map → chunk-SQQQVVV2.js.map} +0 -0
- /package/dist/{chunk-RSMAVO2Z.js.map → chunk-W4CHRA6G.js.map} +0 -0
|
@@ -5,7 +5,7 @@ var _chunkDMXI5D2Qcjs = require('./chunk-DMXI5D2Q.cjs');
|
|
|
5
5
|
|
|
6
6
|
|
|
7
7
|
|
|
8
|
-
var
|
|
8
|
+
var _chunkT32BTPL5cjs = require('./chunk-T32BTPL5.cjs');
|
|
9
9
|
|
|
10
10
|
|
|
11
11
|
var _chunkXF5TJ4P2cjs = require('./chunk-XF5TJ4P2.cjs');
|
|
@@ -17,7 +17,7 @@ var _chunkJU6SBF3Ccjs = require('./chunk-JU6SBF3C.cjs');
|
|
|
17
17
|
|
|
18
18
|
|
|
19
19
|
|
|
20
|
-
var
|
|
20
|
+
var _chunkLL35WZZScjs = require('./chunk-LL35WZZS.cjs');
|
|
21
21
|
|
|
22
22
|
|
|
23
23
|
|
|
@@ -54,7 +54,7 @@ function FaqAccordion({ items, defaultOpenIds = [] }) {
|
|
|
54
54
|
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
|
|
55
55
|
"div",
|
|
56
56
|
{
|
|
57
|
-
id:
|
|
57
|
+
id: _chunkLL35WZZScjs.faqItemAnchor.call(void 0, item.id),
|
|
58
58
|
className: "scroll-mt-24 transition-colors hover:bg-ods-bg-hover",
|
|
59
59
|
children: [
|
|
60
60
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
|
|
@@ -147,7 +147,7 @@ function groupFaqsBySection(faqs) {
|
|
|
147
147
|
}
|
|
148
148
|
let group = byName.get(name);
|
|
149
149
|
if (!group) {
|
|
150
|
-
group = { section: name, slug:
|
|
150
|
+
group = { section: name, slug: _chunkLL35WZZScjs.faqSectionSlug.call(void 0, name), items: [] };
|
|
151
151
|
byName.set(name, group);
|
|
152
152
|
}
|
|
153
153
|
group.items.push(item);
|
|
@@ -200,7 +200,7 @@ function GroupedFaqList({
|
|
|
200
200
|
}, [slugKey]);
|
|
201
201
|
const [hashTarget, setHashTarget] = _react.useState.call(void 0, null);
|
|
202
202
|
_react.useEffect.call(void 0, () => {
|
|
203
|
-
const refresh = () => setHashTarget(
|
|
203
|
+
const refresh = () => setHashTarget(_chunkLL35WZZScjs.parseFaqHash.call(void 0, window.location.hash));
|
|
204
204
|
refresh();
|
|
205
205
|
window.addEventListener("hashchange", refresh);
|
|
206
206
|
return () => window.removeEventListener("hashchange", refresh);
|
|
@@ -251,7 +251,7 @@ function GroupedFaqList({
|
|
|
251
251
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "space-y-10", children: groups.map((group) => {
|
|
252
252
|
const key = groupKey(group);
|
|
253
253
|
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "section", { id: _nullishCoalesce(group.slug, () => ( void 0)), className: "scroll-mt-24 space-y-4", children: [
|
|
254
|
-
group.section && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, CategoryHeading, { className:
|
|
254
|
+
group.section && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, CategoryHeading, { className: _chunkLL35WZZScjs.SECTION_HEADING_CLASS, children: group.section }),
|
|
255
255
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
256
256
|
FaqAccordion,
|
|
257
257
|
{
|
|
@@ -292,7 +292,7 @@ function FaqSection({
|
|
|
292
292
|
const { data, isLoading, error } = _chunkDMXI5D2Qcjs.useSelfFetch.call(void 0, url, { initialData });
|
|
293
293
|
const faqs = _react.useMemo.call(void 0, () => _nullishCoalesce(_optionalChain([data, 'optionalAccess', _14 => _14.faqs]), () => ( [])), [_optionalChain([data, 'optionalAccess', _15 => _15.faqs])]);
|
|
294
294
|
const groups = _react.useMemo.call(void 0, () => faqs.length > 0 ? groupFaqsBySection(faqs) : [], [faqs]);
|
|
295
|
-
const headingNode = heading === void 0 ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "h2", { className:
|
|
295
|
+
const headingNode = heading === void 0 ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "h2", { className: _chunkLL35WZZScjs.SECTION_HEADING_CLASS, children: DEFAULT_HEADING_TEXT }) : heading;
|
|
296
296
|
if (error) return null;
|
|
297
297
|
if (!isLoading && faqs.length === 0) return null;
|
|
298
298
|
if (isLoading && faqs.length === 0) {
|
|
@@ -334,7 +334,7 @@ function FaqDocumentPage({
|
|
|
334
334
|
label: _nullishCoalesce(_optionalChain([backButton, 'optionalAccess', _16 => _16.label]), () => ( "Back to home")),
|
|
335
335
|
onClick: () => router.push(_nullishCoalesce(_optionalChain([backButton, 'optionalAccess', _17 => _17.href]), () => ( "/")))
|
|
336
336
|
};
|
|
337
|
-
const inner = /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
337
|
+
const inner = /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkT32BTPL5cjs.PageLayout, { title, subtitle, backButton: backCfg, titleSize: "h1", titleWrap: true, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
338
338
|
FaqSection,
|
|
339
339
|
{
|
|
340
340
|
initialFaqs,
|
|
@@ -347,7 +347,7 @@ function FaqDocumentPage({
|
|
|
347
347
|
minResults
|
|
348
348
|
}
|
|
349
349
|
) });
|
|
350
|
-
return shell ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
350
|
+
return shell ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkT32BTPL5cjs.PageShell, { children: inner }) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "page-shell-content", children: inner });
|
|
351
351
|
}
|
|
352
352
|
|
|
353
353
|
|
|
@@ -355,4 +355,4 @@ function FaqDocumentPage({
|
|
|
355
355
|
|
|
356
356
|
|
|
357
357
|
exports.FaqAccordion = FaqAccordion; exports.FaqSection = FaqSection; exports.FaqDocumentPage = FaqDocumentPage;
|
|
358
|
-
//# sourceMappingURL=chunk-
|
|
358
|
+
//# sourceMappingURL=chunk-WMOELYDL.cjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["/home/runner/work/openframe-oss-lib/openframe-oss-lib/openframe-frontend-core/dist/chunk-P4SBHO7U.cjs","../src/components/faq/faq-section.tsx","../src/components/faq-accordion.tsx","../src/components/faq/json-ld.ts","../src/components/faq/faq-document-page.tsx"],"names":["useState","jsx"],"mappings":"AAAA,6rBAAY;AACZ;AACE;AACF,wDAA6B;AAC7B;AACE;AACA;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AAC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AAA;AAC8B,IAAA;AACsB,IAAA;AACpD,EAAA;AAGsD,EAAA;AACvD,IAAA;AAAA,IAAA;AACC,MAAA;AACS,MAAA;AACT,MAAA;AACA,MAAA;AACA,MAAA;AACA,MAAA;AACA,MAAA;AACA,MAAA;AAAA,IAAA;AAEJ,EAAA;AAG8C,EAAA;AAClD;AJ2PoF;AACA;AACA;AACA;AACA;AACA","file":"/home/runner/work/openframe-oss-lib/openframe-oss-lib/openframe-frontend-core/dist/chunk-P4SBHO7U.cjs","sourcesContent":[null,"'use client';\n\nimport type React from 'react';\nimport { useCallback, useEffect, useMemo, useRef, useState } from 'react';\nimport { useScrollToHash } from '../../hooks/use-scroll-to-hash';\nimport { useSelfFetch } from '../../hooks/use-self-fetch';\nimport type { Faq } from '../../types/faq';\nimport { cn } from '../../utils/cn';\nimport { serializeJsonLd } from '../../utils/common';\nimport { faqSectionSlug, parseFaqHash, type FaqHashTarget } from '../../utils/faq-anchor';\nimport { navigateSamePageHash, STICKY_HEADER_OFFSET_PX } from '../../utils/same-page-hash-nav';\nimport { buildSuggestionUrl } from '../../utils/suggestion-url';\nimport { FaqAccordion, type FaqItem } from '../faq-accordion';\nimport { SECTION_HEADING_CLASS } from '../layout/page-heading';\nimport { buildFaqJsonLdFromFaqs, type FaqSchemaOptions } from './json-ld';\n\nexport interface FaqSectionProps {\n /**\n * SSR hydrate. When provided, the hook skips the first client fetch (per\n * useSelfFetch contract). The consuming server page resolves FAQs then drills\n * them into this prop — the lib never re-fetches what the host already gated on.\n */\n initialFaqs?: Faq[];\n /** Both required together for entity-attached FAQs; partial → bare /api/faqs. */\n entityType?: string;\n entityId?: number | string;\n /**\n * Heading node above the grouped list. `undefined` → default\n * `<h2>`\"Frequently Asked Questions\". `null` → no heading (the host page\n * owns the `<h1>`, as the standalone /faqs surface does). A React node lets a\n * platform drill its own <PageHeading> without the lib referencing platform\n * state. Also drives category nesting so the document outline stays correct:\n * `null` → categories render `<h2>` (directly under the page `<h1>`);\n * otherwise categories render `<h3>` beneath this heading.\n */\n heading?: React.ReactNode | null;\n /** Inject FAQPage schema.org JSON-LD as a <script>. Off by default so embeds\n * don't emit duplicate schema. */\n emitJsonLd?: boolean;\n /** Overrides for the JSON-LD's name/description/url. */\n jsonLd?: FaqSchemaOptions;\n className?: string;\n /** Maps to /api/faqs `?count=` (the 5-tier fill target). Absent → param\n * not sent (server default applies). */\n minResults?: number;\n /** Fetch-URL prefix for third-party embeds / reverse proxies\n * ('' = same-origin relative). */\n apiBaseUrl?: string;\n}\n\nconst DEFAULT_HEADING_TEXT = 'Frequently Asked Questions';\n\n/** URL composition shared with RelatedContentSection (`buildSuggestionUrl`)\n * — byte-identical to the historical `buildFaqsUrl` output when\n * `minResults`/`apiBaseUrl` are absent. */\nfunction buildFaqsUrl(entityType?: string, entityId?: number | string, minResults?: number, apiBaseUrl = ''): string {\n return buildSuggestionUrl('/api/faqs', { apiBaseUrl, entityType, entityId, count: minResults });\n}\n\ninterface FaqGroup {\n /** null → the uncategorized bucket: no heading, no jump pill, rendered last. */\n section: string | null;\n slug: string | null;\n items: FaqItem[];\n}\n\n/** Group FAQs by `faq.section`, preserving the server's first-seen\n * (display_order) order for BOTH the section order and the rows within each\n * section. The uncategorized bucket (blank/missing section) sinks to the end\n * since it renders without a heading. Items carry NO badge here — the `<h2>`\n * IS the category, so a per-row chip would be redundant. */\nfunction groupFaqsBySection(faqs: Faq[]): FaqGroup[] {\n // A Map iterates in insertion order, which is exactly the first-seen section\n // order this function promises — so the Map IS the ordering, and no parallel\n // array of names (plus a lookup that has to assert the key back) is needed.\n const byName = new Map<string, FaqGroup>();\n let uncategorized: FaqGroup | null = null;\n for (const faq of faqs) {\n const item: FaqItem = { id: faq.id, question: faq.question, answer: faq.answer };\n const name = faq.section?.trim();\n if (!name) {\n if (!uncategorized) uncategorized = { section: null, slug: null, items: [] };\n uncategorized.items.push(item);\n continue;\n }\n let group = byName.get(name);\n if (!group) {\n group = { section: name, slug: faqSectionSlug(name), items: [] };\n byName.set(name, group);\n }\n group.items.push(item);\n }\n const groups = [...byName.values()];\n if (uncategorized) groups.push(uncategorized);\n return groups;\n}\n\n/** Map key for the uncategorized bucket — `group.slug` is null for it, so\n * every per-group map (default-open ids, accordion keys) uses this sentinel\n * to keep the lookup typed. */\nconst UNCATEGORIZED_KEY = '__uncategorized__';\nconst groupKey = (g: FaqGroup): string => g.slug ?? UNCATEGORIZED_KEY;\n\n/**\n * Grouped FAQ layout: a category jump-nav above stacked `<h2>` category\n * sections (each its own accordion). Isolated into its own component so the\n * scroll-spy hooks only mount in grouped mode — `FaqSection`'s own hooks stay\n * unconditional.\n *\n * The pills are real `<a href=\"#slug\">` anchors (crawlable in-page links,\n * deep-linkable, work without JS); the click handler upgrades the jump to the\n * cancellation-proof `scrollElementIntoView` tween and syncs the URL hash.\n */\nfunction GroupedFaqList({\n groups,\n categoryHeadingAs,\n}: {\n groups: FaqGroup[];\n /** Heading tag for each category, so the document outline nests correctly\n * under whatever owns the heading above this block: `h2` on the standalone\n * page (the page owns the `<h1>`), `h3` beneath an embed's `<h2>` title.\n * The VISUAL is `SECTION_HEADING_CLASS` either way, so categories look\n * identical on every surface. */\n categoryHeadingAs: 'h2' | 'h3';\n}) {\n const CategoryHeading = categoryHeadingAs;\n const navGroups = useMemo(() => groups.filter(g => g.slug), [groups]);\n const [activeSlug, setActiveSlug] = useState<string | null>(navGroups[0]?.slug ?? null);\n // Identity-stable key for the section set so the observer re-binds only when\n // the categories actually change (not on every parent re-render).\n const slugKey = navGroups.map(g => g.slug).join('|');\n // Latest `navGroups` for the scroll-spy observer below, which re-observes on\n // `slugKey` (the section SET) and must not re-run when the array is merely\n // rebuilt with the same slugs.\n const navGroupsRef = useRef(navGroups);\n useEffect(() => {\n navGroupsRef.current = navGroups;\n });\n\n // Scroll-spy: mark the pill for the category currently at the top of the\n // viewport. rootMargin drops the trigger line just below the sticky header\n // and ignores the bottom ~55% so \"active\" is the section being read, not the\n // next one peeking in.\n useEffect(() => {\n if (navGroupsRef.current.length < 2) return undefined;\n const tops = new Map<string, number>();\n const observer = new IntersectionObserver(\n entries => {\n for (const entry of entries) {\n const id = (entry.target as HTMLElement).id;\n if (entry.isIntersecting) tops.set(id, entry.boundingClientRect.top);\n else tops.delete(id);\n }\n let bestId: string | null = null;\n let bestTop = Number.POSITIVE_INFINITY;\n for (const [id, top] of tops) {\n if (top < bestTop) {\n bestTop = top;\n bestId = id;\n }\n }\n if (bestId) setActiveSlug(bestId);\n },\n { rootMargin: `-${STICKY_HEADER_OFFSET_PX}px 0px -55% 0px`, threshold: 0 },\n );\n for (const group of navGroupsRef.current) {\n const el = group.slug ? document.getElementById(group.slug) : null;\n if (el) observer.observe(el);\n }\n return () => observer.disconnect();\n // slugKey encodes the section set; re-observe only when it changes.\n }, [slugKey]);\n\n // ─── Hash dispatch — `/faqs#faq-item-<id>` or `/faqs#faq-<section-slug>` ──\n // Tracks the current hash so:\n // 1. an item-kind hash seeds `defaultOpenIds` on the matching accordion\n // (auto-expands the cited question);\n // 2. either kind triggers the cancellation-proof tween scroll with the\n // sticky-header offset (native browser hash scroll runs once, ignores\n // our offset — re-running the tween puts the target in the right spot).\n // Listens to `hashchange` so back/forward replays the same behavior. SSR-\n // safe: initial null state matches the server render; the first effect\n // tick on the client updates it.\n const [hashTarget, setHashTarget] = useState<FaqHashTarget | null>(null);\n useEffect(() => {\n const refresh = () => setHashTarget(parseFaqHash(window.location.hash));\n refresh();\n window.addEventListener('hashchange', refresh);\n return () => window.removeEventListener('hashchange', refresh);\n }, []);\n\n // Per-group default-open set when the hash points at an item. The map key\n // matches `groupKey(group)` so the render-time lookup is O(1) per group.\n const defaultOpenByGroupKey = useMemo(() => {\n if (hashTarget?.kind !== 'item') return null;\n const targetId = hashTarget.rawId;\n const result = new Map<string, (string | number)[]>();\n for (const group of groups) {\n const hit = group.items.find(i => String(i.id) === targetId);\n if (hit) result.set(groupKey(group), [hit.id]);\n }\n return result.size > 0 ? result : null;\n }, [groups, hashTarget]);\n\n // Accordion is uncontrolled — `defaultOpenIds` is only consumed at mount,\n // so a new item hash needs a remount to honor it. Keying off the item-id\n // suffix triggers exactly the remount we need (and stays stable when the\n // hash points at a section, so category navigation never disturbs the\n // accordion's open state).\n const accordionKeySuffix = hashTarget?.kind === 'item' ? `item:${hashTarget.rawId}` : 'default';\n\n // Unified scroll-to-hash: rAF-polls for the target row (outlasts the SWR self-fetch\n // + Radix accordion expand) and re-fires on `hashchange` — including the synthetic\n // event `navigateSamePageHash` dispatches for a SOFT same-page chat-card nav (a\n // host-router `pushState` fires no `hashchange`). The ready-dep keys off BOTH the\n // loaded `groups` (so a deep-link / refresh scrolls once the self-fetched list\n // mounts) AND `hashTarget` (so a soft nav re-runs the scroll AFTER the re-render\n // that remounts + opens the cited row, landing on its FINAL expanded position\n // instead of racing the uncontrolled accordion's key-remount — the bare-`hashchange`\n // listener alone fires before the remount and lands on the stale closed position).\n const scrollDep =\n `${groups.length}|` +\n (hashTarget?.kind === 'item'\n ? `item:${hashTarget.rawId}`\n : hashTarget?.kind === 'section'\n ? `section:${hashTarget.slug}`\n : 'none');\n useScrollToHash(scrollDep, { headerOffset: STICKY_HEADER_OFFSET_PX });\n\n // A section hash also lights up its category pill; item hashes leave the pills\n // untouched so deep-linking a question never disturbs scroll-spy state.\n //\n // Adjusted while rendering (React's prop-sync pattern) rather than from an\n // effect: the pills below read `activeSlug` in THIS render, so an effect\n // painted the OLD pill lit and then re-rendered to move the highlight. The\n // initial value matches `hashTarget`'s own initial `null`, so a mount is a\n // no-op here exactly as the effect's first run was.\n const [pillSyncedHash, setPillSyncedHash] = useState(hashTarget);\n if (pillSyncedHash !== hashTarget) {\n setPillSyncedHash(hashTarget);\n if (hashTarget?.kind === 'section') setActiveSlug(hashTarget.slug);\n }\n\n // Category pill click. `navigateSamePageHash` owns the entire transition:\n // replaceState → synthetic `hashchange` → `scrollElementIntoView` tween\n // with `STICKY_HEADER_OFFSET_PX` so the section heading lands BELOW the\n // sticky category nav on the FIRST tween (covers the same-target\n // re-click case, where the `hashTarget` effect at L214 is a no-op\n // because the state reference is equal). For DIFFERENT-target clicks\n // the helper's synthetic `hashchange` re-fires that effect, which\n // re-scrolls with the same offset and cancels this tween (singleton)\n // — both paths land at the same position. The effect is still\n // required for back/forward + direct URL edits, where the helper\n // isn't in the call chain.\n //\n // `history: 'replace'` matches the pre-helper behavior: category pills\n // are a TOC, not a navigation step, so the Back button leaves the\n // FAQ page in one step regardless of how many categories the user\n // clicked through.\n const handleJump = useCallback((e: React.MouseEvent<HTMLAnchorElement>, slug: string) => {\n e.preventDefault();\n navigateSamePageHash('#' + slug, {\n headerOffset: STICKY_HEADER_OFFSET_PX,\n history: 'replace',\n });\n }, []);\n\n return (\n <div className=\"space-y-8\">\n {navGroups.length > 1 && (\n <nav aria-label=\"FAQ categories\" className=\"flex flex-wrap gap-2\">\n {navGroups.map(group => {\n const isActive = group.slug === activeSlug;\n return (\n <a\n key={group.slug}\n href={`#${group.slug}`}\n aria-current={isActive ? 'true' : undefined}\n onClick={e => handleJump(e, group.slug as string)}\n className={cn(\n 'rounded-full border px-4 py-2 transition-colors text-h6',\n isActive\n ? 'border-ods-text-primary bg-ods-card text-ods-text-primary'\n : 'border-ods-border bg-ods-card text-ods-text-secondary hover:border-ods-text-secondary hover:text-ods-text-primary',\n )}\n >\n {group.section}\n </a>\n );\n })}\n </nav>\n )}\n <div className=\"space-y-10\">\n {groups.map(group => {\n const key = groupKey(group);\n return (\n <section key={key} id={group.slug ?? undefined} className=\"scroll-mt-24 space-y-4\">\n {group.section && <CategoryHeading className={SECTION_HEADING_CLASS}>{group.section}</CategoryHeading>}\n <FaqAccordion\n // Re-key on item-hash changes so the remount picks up the new\n // `defaultOpenIds` (the accordion is uncontrolled). Stable for\n // section hashes — category navigation doesn't disturb state.\n key={`${key}:${accordionKeySuffix}`}\n items={group.items}\n defaultOpenIds={defaultOpenByGroupKey?.get(key)}\n />\n </section>\n );\n })}\n </div>\n </div>\n );\n}\n\nfunction FaqSkeleton() {\n return (\n <div className=\"animate-pulse space-y-8\">\n <div className=\"h-12 w-2/3 rounded bg-ods-border md:h-14\" />\n <div className=\"w-full divide-y divide-ods-border overflow-hidden rounded-md border border-ods-border bg-transparent\">\n {Array.from({ length: 8 }).map((_, idx) => (\n <div key={idx} className=\"flex items-center justify-between gap-6 px-6 py-4 md:gap-10\">\n <div className=\"h-6 w-5/6 rounded bg-ods-border\" />\n <div className=\"size-6 rounded bg-ods-border\" />\n </div>\n ))}\n </div>\n </div>\n );\n}\n\ninterface FaqsResponse {\n faqs: Faq[];\n}\n\n/**\n * The FAQ display surface — ONE rendering on every host: the list grouped by\n * `faq.section` (each category a heading + its own accordion, with a category\n * jump-nav once there are 2+ categories). There is no flat/ungrouped mode and\n * no page-vs-embedded shell fork; the standalone /faqs page and every embed\n * render through this single path, so they cannot drift.\n *\n * - Standalone /faqs page: pass `initialFaqs` (SSR) + `heading={null}` (the\n * page owns the <h1>) + `emitJsonLd` with `jsonLd` overrides for SEO.\n * - Per-entity embed: pass `entityType` + `entityId` (no `initialFaqs`); the\n * hook self-fetches `GET /api/faqs`, and `heading` is this block's own <h2>.\n *\n * CONTRACT: the consuming app MUST implement `GET /api/faqs`. On a fetch error\n * (or zero FAQs) the component renders nothing so the host page isn't\n * disfigured. The host always supplies the page shell — this renders a bare\n * <section>.\n */\nexport function FaqSection({\n initialFaqs,\n entityType,\n entityId,\n heading,\n emitJsonLd = false,\n jsonLd,\n className,\n minResults,\n apiBaseUrl = '',\n}: FaqSectionProps) {\n const url = buildFaqsUrl(entityType, entityId, minResults, apiBaseUrl);\n // Memoized — useSelfFetch re-syncs on [initialData]; a fresh per-render\n // wrapper object would setState-loop under re-rendering parents.\n const initialData = useMemo<FaqsResponse | undefined>(\n () => (initialFaqs ? { faqs: initialFaqs } : undefined),\n [initialFaqs],\n );\n const { data, isLoading, error } = useSelfFetch<FaqsResponse>(url, { initialData });\n\n // Memoised because the `??` fallback minted a NEW array on every\n // render, which made the memo below re-run every time — i.e. do nothing.\n const faqs = useMemo(() => data?.faqs ?? [], [data?.faqs]);\n // Grouped before the early returns so the hook order stays stable.\n const groups = useMemo(() => (faqs.length > 0 ? groupFaqsBySection(faqs) : []), [faqs]);\n\n // `undefined` → default <h2> title; `null` → the host page owns the <h1>, so\n // no title renders here. `heading === null` also makes the category headings\n // <h2> (directly under the page <h1>); otherwise they nest as <h3>.\n const headingNode =\n heading === undefined ? <h2 className={SECTION_HEADING_CLASS}>{DEFAULT_HEADING_TEXT}</h2> : heading;\n\n // Degrade silently — never show an error banner or an empty section shell\n // where FAQs would be (host pages and the standalone surface both rely on it).\n if (error) return null;\n if (!isLoading && faqs.length === 0) return null;\n if (isLoading && faqs.length === 0) {\n return (\n <div className={className}>\n <FaqSkeleton />\n </div>\n );\n }\n\n const schema = emitJsonLd ? buildFaqJsonLdFromFaqs(faqs, jsonLd) : null;\n\n return (\n <>\n <section className={className ?? 'space-y-10'}>\n {headingNode}\n <GroupedFaqList groups={groups} categoryHeadingAs={heading === null ? 'h2' : 'h3'} />\n </section>\n {schema && (\n <script\n type=\"application/ld+json\"\n // serializeJsonLd, NOT raw JSON.stringify — FAQ answers are\n // admin-entered; an embedded \"</script>\" must not break the tag.\n dangerouslySetInnerHTML={{ __html: serializeJsonLd(schema) }}\n />\n )}\n </>\n );\n}\n","'use client';\n\nimport { useState } from 'react';\nimport { cn } from '../utils/cn';\nimport { faqItemAnchor } from '../utils/faq-anchor';\nimport { Chevron02DownIcon } from './icons-v2-generated/arrows/chevron-02-down-icon';\n\nexport interface FaqItem {\n id: number | string;\n question: string;\n answer: string;\n}\n\ninterface FaqAccordionProps {\n items: FaqItem[];\n defaultOpenIds?: (number | string)[];\n}\n\nexport function FaqAccordion({ items, defaultOpenIds = [] }: FaqAccordionProps) {\n const [openSet, setOpenSet] = useState<Set<string | number>>(new Set(defaultOpenIds));\n\n const toggle = (id: string | number) => {\n setOpenSet(prev => {\n const next = new Set(prev);\n if (next.has(id)) next.delete(id);\n else next.add(id);\n return next;\n });\n };\n\n return (\n <div className=\"divide-y divide-ods-border overflow-hidden rounded-md border border-ods-border bg-transparent\">\n {items.map(item => {\n const isOpen = openSet.has(item.id);\n\n return (\n <div\n key={item.id}\n // Per-row anchor — chat citation chips (`/faqs#faq-item-<id>`) land\n // here via native browser hash scroll AND via `FaqSection`'s tween\n // dispatch. `scroll-mt-24` keeps the row header below the 96px\n // sticky nav offset (matches `<section>`'s scroll-margin for\n // category anchors).\n id={faqItemAnchor(item.id)}\n className=\"scroll-mt-24 transition-colors hover:bg-ods-bg-hover\"\n >\n {/* Header */}\n <div\n role=\"button\"\n tabIndex={0}\n onClick={() => toggle(item.id)}\n onKeyDown={e => {\n if (e.key === 'Enter' || e.key === ' ') {\n e.preventDefault();\n toggle(item.id);\n }\n }}\n aria-expanded={isOpen}\n className=\"flex w-full cursor-pointer items-center gap-6 px-6 py-4 text-left transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-ods-focus md:gap-10\"\n >\n <h3 className=\"min-w-0 flex-1 break-words\">{item.question}</h3>\n <Chevron02DownIcon\n aria-hidden=\"true\"\n size={24}\n className={cn(\n 'shrink-0 text-ods-text-primary transition-transform duration-300',\n isOpen && 'rotate-180',\n )}\n />\n </div>\n {/* Content wrapper. Collapses with the grid 1fr->0fr transition the\n rest of the design system uses (see AnnouncementBar) rather than\n an animated max-height: measuring `scrollHeight` needed a hook\n PER ROW, which meant calling hooks inside `items.map` — the hook\n order then changed whenever `items` did. Grid needs no\n measurement, and it animates correctly when an answer's height\n changes after mount. */}\n <div\n className=\"grid transition-[grid-template-rows,opacity] duration-300 ease-in-out motion-reduce:transition-none\"\n style={{ gridTemplateRows: isOpen ? '1fr' : '0fr', opacity: isOpen ? 1 : 0 }}\n >\n {/* break-words: FAQ answers render as plain text, so a long URL or\n token has no wrap opportunity — and the row is overflow-hidden,\n which would CLIP it past the viewport on mobile. Mirrors the\n markdown-renderer overflow-wrap fix. */}\n <div className=\"overflow-hidden\">\n <div className=\"break-words px-6 pb-4 text-ods-text-primary text-h4\">{item.answer}</div>\n </div>\n </div>\n </div>\n );\n })}\n </div>\n );\n}\n","/**\n * Pure FAQ JSON-LD builder. No React, no client-only deps — safe to import from\n * Server Components via the `./components/faq` subpath export. (Do NOT import\n * through the root `./components` barrel — that barrel is `\"use client\"` and\n * dragging it into a Server Component would force the client graph into the\n * server.)\n *\n * The hub used to harcode `name`/`description` here for OpenMSP; in the lib we\n * accept overrides so every embedder can supply its own platform branding.\n */\nimport type { Faq } from '../../types/faq';\n\nexport interface FaqSchemaOptions {\n name?: string;\n description?: string;\n url?: string;\n}\n\nconst DEFAULT_NAME = 'Frequently Asked Questions';\nconst DEFAULT_DESCRIPTION = 'Answers to common questions.';\n\nexport function baseFaqSchema(opts: FaqSchemaOptions = {}) {\n return {\n '@context': 'https://schema.org',\n '@type': 'FAQPage',\n name: opts.name ?? DEFAULT_NAME,\n description: opts.description ?? DEFAULT_DESCRIPTION,\n ...(opts.url ? { url: opts.url } : {}),\n } as const;\n}\n\nexport function buildFaqJsonLdFromFaqs(faqs: Faq[], opts: FaqSchemaOptions = {}) {\n return {\n ...baseFaqSchema(opts),\n mainEntity: faqs.map(faq => ({\n '@type': 'Question',\n name: faq.question,\n acceptedAnswer: {\n '@type': 'Answer',\n text: faq.answer,\n },\n })),\n } as const;\n}\n","'use client';\n\n/**\n * FaqDocumentPage — the full `/faqs` page with chrome, so embedders drop in\n * ONE component instead of hand-assembling `PageShell` + `PageLayout` around\n * the bare `<FaqSection>`. Mirrors `LegalDocumentPage` / `DevSectionPage`: the\n * page-level layout lives in the lib, the host page is a thin wrapper that\n * passes only config + the SSR-resolved data.\n *\n * HERO: the title + subtitle route through the canonical (frozen) `PageLayout`\n * `TitleBlock` with `titleSize=\"h1\"` — the unified Help Center header (the\n * `TitleBlock` element is always an `<h1>`; `titleSize` only sets its typography,\n * here `text-h1`). The page owns that `<h1>`, so `<FaqSection heading={null}>`\n * nests its category headings as `<h2>`/`<h3>` (the SEO-recommended FAQ document\n * outline).\n *\n * DATA: pass `initialFaqs` (SSR-resolved, platform-scoped) so `FaqSection`\n * skips its client self-fetch — the standalone page's static platform-only\n * contract. Omit it for embeds that want the self-fetching `/api/faqs`\n * suggestion-fill instead.\n */\n\nimport { useRouter } from '../../embed-shims/next-navigation';\nimport type { Faq } from '../../types/faq';\nimport { PageShell, PageLayout } from '../ui';\nimport { FaqSection } from './faq-section';\nimport type { FaqSchemaOptions } from './json-ld';\n\nexport interface FaqDocumentPageProps {\n /** Page title (frozen `PageLayout` `TitleBlock`). Default \"Frequently Asked Questions\". */\n title?: string;\n /** Subtitle under the title. */\n subtitle?: string;\n /** Back-button config — same pattern as `DevSectionPage` / `LegalDocumentPage`.\n * Pass `false` to hide. Default `{ label: 'Back to home', href: '/' }`. */\n backButton?: { label?: string; href?: string } | false;\n /** Render the standalone `<PageShell>` (own `<main>` + bg + max-width). Default\n * true. Pass false when the host layout already provides the page container\n * (e.g. openframe-frontend's `AppLayout` `<main>`) — only the padding box\n * renders, avoiding a nested `<main>`. */\n shell?: boolean;\n /** SSR-hydrate `FaqSection` (skips the client fetch — the platform-only\n * contract for the standalone page). Omit for self-fetching embeds. */\n initialFaqs?: Faq[];\n /** Emit FAQPage schema.org JSON-LD (forwarded to `FaqSection`). Off by\n * default so embeds don't emit duplicate schema. */\n emitJsonLd?: boolean;\n /** JSON-LD name/description/url overrides (forwarded to `FaqSection`). */\n jsonLd?: FaqSchemaOptions;\n /** Base URL `FaqSection` appends `/api/faqs` to (reverse-proxy embedders). */\n apiBaseUrl?: string;\n /** Optional entity scoping forwarded to `FaqSection`. */\n entityType?: string;\n entityId?: number | string;\n /** Minimum FAQ count before the section renders (forwarded to `FaqSection`). */\n minResults?: number;\n}\n\nexport function FaqDocumentPage({\n title = 'Frequently Asked Questions',\n subtitle,\n backButton,\n initialFaqs,\n emitJsonLd,\n jsonLd,\n apiBaseUrl,\n entityType,\n entityId,\n minResults,\n shell = true,\n}: FaqDocumentPageProps) {\n const router = useRouter();\n\n // Back-button config — mirrors LegalDocumentPage / DevSectionPage. Hide\n // entirely when the caller passes `false` (embed-mode where the host owns\n // nav chrome).\n const backCfg =\n backButton === false\n ? undefined\n : {\n label: backButton?.label ?? 'Back to home',\n onClick: () => router.push(backButton?.href ?? '/'),\n };\n\n const inner = (\n <PageLayout title={title} subtitle={subtitle} backButton={backCfg} titleSize=\"h1\" titleWrap>\n <FaqSection\n initialFaqs={initialFaqs}\n heading={null}\n emitJsonLd={emitJsonLd}\n jsonLd={jsonLd}\n apiBaseUrl={apiBaseUrl}\n entityType={entityType}\n entityId={entityId}\n minResults={minResults}\n />\n </PageLayout>\n );\n\n return shell ? <PageShell>{inner}</PageShell> : <div className=\"page-shell-content\">{inner}</div>;\n}\n"]}
|
|
1
|
+
{"version":3,"sources":["/home/runner/work/openframe-oss-lib/openframe-oss-lib/openframe-frontend-core/dist/chunk-WMOELYDL.cjs","../src/components/faq/faq-section.tsx","../src/components/faq-accordion.tsx","../src/components/faq/json-ld.ts","../src/components/faq/faq-document-page.tsx"],"names":["useState","jsx"],"mappings":"AAAA,6rBAAY;AACZ;AACE;AACF,wDAA6B;AAC7B;AACE;AACA;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACA;AACA;AACA;AACF,wDAA6B;AAC7B;AACE;AACA;AACA;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACA;AChCA,8BAAkE;ADkClE;AACA;AEpCA;AA6CY,+CAAA;AA7BL,SAAS,YAAA,CAAa,EAAE,KAAA,EAAO,eAAA,EAAiB,CAAC,EAAE,CAAA,EAAsB;AAC9E,EAAA,MAAM,CAAC,OAAA,EAAS,UAAU,EAAA,EAAI,6BAAA,IAAmC,GAAA,CAAI,cAAc,CAAC,CAAA;AAEpF,EAAA,MAAM,OAAA,EAAS,CAAC,EAAA,EAA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;AAGN,IAAA;AACF,EAAA;AAEJ;AAEuB;AAGjB,EAAA;AAAe,oBAAA;AACA,oBAAA;AAGwC,sBAAA;AACH,sBAAA;AAGpD,IAAA;AACF,EAAA;AAEJ;AAuB2B;AACzB,EAAA;AACA,EAAA;AACA,EAAA;AACA,EAAA;AACa,EAAA;AACb,EAAA;AACA,EAAA;AACA,EAAA;AACa,EAAA;AACK;AACmD,EAAA;AAGjD,EAAA;AAC2B,IAAA;AACjC,IAAA;AACd,EAAA;AACkF,EAAA;AAIzB,EAAA;AAEwB,EAAA;AAMxC,EAAA;AAIvB,EAAA;AAC0B,EAAA;AACR,EAAA;AAG7B,IAAA;AAGP,EAAA;AAEmE,EAAA;AAI/D,EAAA;AACG,oBAAA;AAAA,MAAA;AAC8D,sBAAA;AACjE,IAAA;AAEEA,IAAAA;AAAC,MAAA;AAAA,MAAA;AACM,QAAA;AAGsD,QAAA;AAAA,MAAA;AAC7D,IAAA;AAEJ,EAAA;AAEJ;ADlGoF;AACA;AItO9E;AA5B0B;AACtB,EAAA;AACR,EAAA;AACA,EAAA;AACA,EAAA;AACA,EAAA;AACA,EAAA;AACA,EAAA;AACA,EAAA;AACA,EAAA;AACA,EAAA;AACQ,EAAA;AACe;AACE,EAAA;AAQnB,EAAA;AAC8B,IAAA;AACsB,IAAA;AACpD,EAAA;AAGsD,EAAA;AACvD,IAAA;AAAA,IAAA;AACC,MAAA;AACS,MAAA;AACT,MAAA;AACA,MAAA;AACA,MAAA;AACA,MAAA;AACA,MAAA;AACA,MAAA;AAAA,IAAA;AAEJ,EAAA;AAG8C,EAAA;AAClD;AJ2PoF;AACA;AACA;AACA;AACA;AACA","file":"/home/runner/work/openframe-oss-lib/openframe-oss-lib/openframe-frontend-core/dist/chunk-WMOELYDL.cjs","sourcesContent":[null,"'use client';\n\nimport type React from 'react';\nimport { useCallback, useEffect, useMemo, useRef, useState } from 'react';\nimport { useScrollToHash } from '../../hooks/use-scroll-to-hash';\nimport { useSelfFetch } from '../../hooks/use-self-fetch';\nimport type { Faq } from '../../types/faq';\nimport { cn } from '../../utils/cn';\nimport { serializeJsonLd } from '../../utils/common';\nimport { faqSectionSlug, parseFaqHash, type FaqHashTarget } from '../../utils/faq-anchor';\nimport { navigateSamePageHash, STICKY_HEADER_OFFSET_PX } from '../../utils/same-page-hash-nav';\nimport { buildSuggestionUrl } from '../../utils/suggestion-url';\nimport { FaqAccordion, type FaqItem } from '../faq-accordion';\nimport { SECTION_HEADING_CLASS } from '../layout/page-heading';\nimport { buildFaqJsonLdFromFaqs, type FaqSchemaOptions } from './json-ld';\n\nexport interface FaqSectionProps {\n /**\n * SSR hydrate. When provided, the hook skips the first client fetch (per\n * useSelfFetch contract). The consuming server page resolves FAQs then drills\n * them into this prop — the lib never re-fetches what the host already gated on.\n */\n initialFaqs?: Faq[];\n /** Both required together for entity-attached FAQs; partial → bare /api/faqs. */\n entityType?: string;\n entityId?: number | string;\n /**\n * Heading node above the grouped list. `undefined` → default\n * `<h2>`\"Frequently Asked Questions\". `null` → no heading (the host page\n * owns the `<h1>`, as the standalone /faqs surface does). A React node lets a\n * platform drill its own <PageHeading> without the lib referencing platform\n * state. Also drives category nesting so the document outline stays correct:\n * `null` → categories render `<h2>` (directly under the page `<h1>`);\n * otherwise categories render `<h3>` beneath this heading.\n */\n heading?: React.ReactNode | null;\n /** Inject FAQPage schema.org JSON-LD as a <script>. Off by default so embeds\n * don't emit duplicate schema. */\n emitJsonLd?: boolean;\n /** Overrides for the JSON-LD's name/description/url. */\n jsonLd?: FaqSchemaOptions;\n className?: string;\n /** Maps to /api/faqs `?count=` (the 5-tier fill target). Absent → param\n * not sent (server default applies). */\n minResults?: number;\n /** Fetch-URL prefix for third-party embeds / reverse proxies\n * ('' = same-origin relative). */\n apiBaseUrl?: string;\n}\n\nconst DEFAULT_HEADING_TEXT = 'Frequently Asked Questions';\n\n/** URL composition shared with RelatedContentSection (`buildSuggestionUrl`)\n * — byte-identical to the historical `buildFaqsUrl` output when\n * `minResults`/`apiBaseUrl` are absent. */\nfunction buildFaqsUrl(entityType?: string, entityId?: number | string, minResults?: number, apiBaseUrl = ''): string {\n return buildSuggestionUrl('/api/faqs', { apiBaseUrl, entityType, entityId, count: minResults });\n}\n\ninterface FaqGroup {\n /** null → the uncategorized bucket: no heading, no jump pill, rendered last. */\n section: string | null;\n slug: string | null;\n items: FaqItem[];\n}\n\n/** Group FAQs by `faq.section`, preserving the server's first-seen\n * (display_order) order for BOTH the section order and the rows within each\n * section. The uncategorized bucket (blank/missing section) sinks to the end\n * since it renders without a heading. Items carry NO badge here — the `<h2>`\n * IS the category, so a per-row chip would be redundant. */\nfunction groupFaqsBySection(faqs: Faq[]): FaqGroup[] {\n // A Map iterates in insertion order, which is exactly the first-seen section\n // order this function promises — so the Map IS the ordering, and no parallel\n // array of names (plus a lookup that has to assert the key back) is needed.\n const byName = new Map<string, FaqGroup>();\n let uncategorized: FaqGroup | null = null;\n for (const faq of faqs) {\n const item: FaqItem = { id: faq.id, question: faq.question, answer: faq.answer };\n const name = faq.section?.trim();\n if (!name) {\n if (!uncategorized) uncategorized = { section: null, slug: null, items: [] };\n uncategorized.items.push(item);\n continue;\n }\n let group = byName.get(name);\n if (!group) {\n group = { section: name, slug: faqSectionSlug(name), items: [] };\n byName.set(name, group);\n }\n group.items.push(item);\n }\n const groups = [...byName.values()];\n if (uncategorized) groups.push(uncategorized);\n return groups;\n}\n\n/** Map key for the uncategorized bucket — `group.slug` is null for it, so\n * every per-group map (default-open ids, accordion keys) uses this sentinel\n * to keep the lookup typed. */\nconst UNCATEGORIZED_KEY = '__uncategorized__';\nconst groupKey = (g: FaqGroup): string => g.slug ?? UNCATEGORIZED_KEY;\n\n/**\n * Grouped FAQ layout: a category jump-nav above stacked `<h2>` category\n * sections (each its own accordion). Isolated into its own component so the\n * scroll-spy hooks only mount in grouped mode — `FaqSection`'s own hooks stay\n * unconditional.\n *\n * The pills are real `<a href=\"#slug\">` anchors (crawlable in-page links,\n * deep-linkable, work without JS); the click handler upgrades the jump to the\n * cancellation-proof `scrollElementIntoView` tween and syncs the URL hash.\n */\nfunction GroupedFaqList({\n groups,\n categoryHeadingAs,\n}: {\n groups: FaqGroup[];\n /** Heading tag for each category, so the document outline nests correctly\n * under whatever owns the heading above this block: `h2` on the standalone\n * page (the page owns the `<h1>`), `h3` beneath an embed's `<h2>` title.\n * The VISUAL is `SECTION_HEADING_CLASS` either way, so categories look\n * identical on every surface. */\n categoryHeadingAs: 'h2' | 'h3';\n}) {\n const CategoryHeading = categoryHeadingAs;\n const navGroups = useMemo(() => groups.filter(g => g.slug), [groups]);\n const [activeSlug, setActiveSlug] = useState<string | null>(navGroups[0]?.slug ?? null);\n // Identity-stable key for the section set so the observer re-binds only when\n // the categories actually change (not on every parent re-render).\n const slugKey = navGroups.map(g => g.slug).join('|');\n // Latest `navGroups` for the scroll-spy observer below, which re-observes on\n // `slugKey` (the section SET) and must not re-run when the array is merely\n // rebuilt with the same slugs.\n const navGroupsRef = useRef(navGroups);\n useEffect(() => {\n navGroupsRef.current = navGroups;\n });\n\n // Scroll-spy: mark the pill for the category currently at the top of the\n // viewport. rootMargin drops the trigger line just below the sticky header\n // and ignores the bottom ~55% so \"active\" is the section being read, not the\n // next one peeking in.\n useEffect(() => {\n if (navGroupsRef.current.length < 2) return undefined;\n const tops = new Map<string, number>();\n const observer = new IntersectionObserver(\n entries => {\n for (const entry of entries) {\n const id = (entry.target as HTMLElement).id;\n if (entry.isIntersecting) tops.set(id, entry.boundingClientRect.top);\n else tops.delete(id);\n }\n let bestId: string | null = null;\n let bestTop = Number.POSITIVE_INFINITY;\n for (const [id, top] of tops) {\n if (top < bestTop) {\n bestTop = top;\n bestId = id;\n }\n }\n if (bestId) setActiveSlug(bestId);\n },\n { rootMargin: `-${STICKY_HEADER_OFFSET_PX}px 0px -55% 0px`, threshold: 0 },\n );\n for (const group of navGroupsRef.current) {\n const el = group.slug ? document.getElementById(group.slug) : null;\n if (el) observer.observe(el);\n }\n return () => observer.disconnect();\n // slugKey encodes the section set; re-observe only when it changes.\n }, [slugKey]);\n\n // ─── Hash dispatch — `/faqs#faq-item-<id>` or `/faqs#faq-<section-slug>` ──\n // Tracks the current hash so:\n // 1. an item-kind hash seeds `defaultOpenIds` on the matching accordion\n // (auto-expands the cited question);\n // 2. either kind triggers the cancellation-proof tween scroll with the\n // sticky-header offset (native browser hash scroll runs once, ignores\n // our offset — re-running the tween puts the target in the right spot).\n // Listens to `hashchange` so back/forward replays the same behavior. SSR-\n // safe: initial null state matches the server render; the first effect\n // tick on the client updates it.\n const [hashTarget, setHashTarget] = useState<FaqHashTarget | null>(null);\n useEffect(() => {\n const refresh = () => setHashTarget(parseFaqHash(window.location.hash));\n refresh();\n window.addEventListener('hashchange', refresh);\n return () => window.removeEventListener('hashchange', refresh);\n }, []);\n\n // Per-group default-open set when the hash points at an item. The map key\n // matches `groupKey(group)` so the render-time lookup is O(1) per group.\n const defaultOpenByGroupKey = useMemo(() => {\n if (hashTarget?.kind !== 'item') return null;\n const targetId = hashTarget.rawId;\n const result = new Map<string, (string | number)[]>();\n for (const group of groups) {\n const hit = group.items.find(i => String(i.id) === targetId);\n if (hit) result.set(groupKey(group), [hit.id]);\n }\n return result.size > 0 ? result : null;\n }, [groups, hashTarget]);\n\n // Accordion is uncontrolled — `defaultOpenIds` is only consumed at mount,\n // so a new item hash needs a remount to honor it. Keying off the item-id\n // suffix triggers exactly the remount we need (and stays stable when the\n // hash points at a section, so category navigation never disturbs the\n // accordion's open state).\n const accordionKeySuffix = hashTarget?.kind === 'item' ? `item:${hashTarget.rawId}` : 'default';\n\n // Unified scroll-to-hash: rAF-polls for the target row (outlasts the SWR self-fetch\n // + Radix accordion expand) and re-fires on `hashchange` — including the synthetic\n // event `navigateSamePageHash` dispatches for a SOFT same-page chat-card nav (a\n // host-router `pushState` fires no `hashchange`). The ready-dep keys off BOTH the\n // loaded `groups` (so a deep-link / refresh scrolls once the self-fetched list\n // mounts) AND `hashTarget` (so a soft nav re-runs the scroll AFTER the re-render\n // that remounts + opens the cited row, landing on its FINAL expanded position\n // instead of racing the uncontrolled accordion's key-remount — the bare-`hashchange`\n // listener alone fires before the remount and lands on the stale closed position).\n const scrollDep =\n `${groups.length}|` +\n (hashTarget?.kind === 'item'\n ? `item:${hashTarget.rawId}`\n : hashTarget?.kind === 'section'\n ? `section:${hashTarget.slug}`\n : 'none');\n useScrollToHash(scrollDep, { headerOffset: STICKY_HEADER_OFFSET_PX });\n\n // A section hash also lights up its category pill; item hashes leave the pills\n // untouched so deep-linking a question never disturbs scroll-spy state.\n //\n // Adjusted while rendering (React's prop-sync pattern) rather than from an\n // effect: the pills below read `activeSlug` in THIS render, so an effect\n // painted the OLD pill lit and then re-rendered to move the highlight. The\n // initial value matches `hashTarget`'s own initial `null`, so a mount is a\n // no-op here exactly as the effect's first run was.\n const [pillSyncedHash, setPillSyncedHash] = useState(hashTarget);\n if (pillSyncedHash !== hashTarget) {\n setPillSyncedHash(hashTarget);\n if (hashTarget?.kind === 'section') setActiveSlug(hashTarget.slug);\n }\n\n // Category pill click. `navigateSamePageHash` owns the entire transition:\n // replaceState → synthetic `hashchange` → `scrollElementIntoView` tween\n // with `STICKY_HEADER_OFFSET_PX` so the section heading lands BELOW the\n // sticky category nav on the FIRST tween (covers the same-target\n // re-click case, where the `hashTarget` effect at L214 is a no-op\n // because the state reference is equal). For DIFFERENT-target clicks\n // the helper's synthetic `hashchange` re-fires that effect, which\n // re-scrolls with the same offset and cancels this tween (singleton)\n // — both paths land at the same position. The effect is still\n // required for back/forward + direct URL edits, where the helper\n // isn't in the call chain.\n //\n // `history: 'replace'` matches the pre-helper behavior: category pills\n // are a TOC, not a navigation step, so the Back button leaves the\n // FAQ page in one step regardless of how many categories the user\n // clicked through.\n const handleJump = useCallback((e: React.MouseEvent<HTMLAnchorElement>, slug: string) => {\n e.preventDefault();\n navigateSamePageHash('#' + slug, {\n headerOffset: STICKY_HEADER_OFFSET_PX,\n history: 'replace',\n });\n }, []);\n\n return (\n <div className=\"space-y-8\">\n {navGroups.length > 1 && (\n <nav aria-label=\"FAQ categories\" className=\"flex flex-wrap gap-2\">\n {navGroups.map(group => {\n const isActive = group.slug === activeSlug;\n return (\n <a\n key={group.slug}\n href={`#${group.slug}`}\n aria-current={isActive ? 'true' : undefined}\n onClick={e => handleJump(e, group.slug as string)}\n className={cn(\n 'rounded-full border px-4 py-2 transition-colors text-h6',\n isActive\n ? 'border-ods-text-primary bg-ods-card text-ods-text-primary'\n : 'border-ods-border bg-ods-card text-ods-text-secondary hover:border-ods-text-secondary hover:text-ods-text-primary',\n )}\n >\n {group.section}\n </a>\n );\n })}\n </nav>\n )}\n <div className=\"space-y-10\">\n {groups.map(group => {\n const key = groupKey(group);\n return (\n <section key={key} id={group.slug ?? undefined} className=\"scroll-mt-24 space-y-4\">\n {group.section && <CategoryHeading className={SECTION_HEADING_CLASS}>{group.section}</CategoryHeading>}\n <FaqAccordion\n // Re-key on item-hash changes so the remount picks up the new\n // `defaultOpenIds` (the accordion is uncontrolled). Stable for\n // section hashes — category navigation doesn't disturb state.\n key={`${key}:${accordionKeySuffix}`}\n items={group.items}\n defaultOpenIds={defaultOpenByGroupKey?.get(key)}\n />\n </section>\n );\n })}\n </div>\n </div>\n );\n}\n\nfunction FaqSkeleton() {\n return (\n <div className=\"animate-pulse space-y-8\">\n <div className=\"h-12 w-2/3 rounded bg-ods-border md:h-14\" />\n <div className=\"w-full divide-y divide-ods-border overflow-hidden rounded-md border border-ods-border bg-transparent\">\n {Array.from({ length: 8 }).map((_, idx) => (\n <div key={idx} className=\"flex items-center justify-between gap-6 px-6 py-4 md:gap-10\">\n <div className=\"h-6 w-5/6 rounded bg-ods-border\" />\n <div className=\"size-6 rounded bg-ods-border\" />\n </div>\n ))}\n </div>\n </div>\n );\n}\n\ninterface FaqsResponse {\n faqs: Faq[];\n}\n\n/**\n * The FAQ display surface — ONE rendering on every host: the list grouped by\n * `faq.section` (each category a heading + its own accordion, with a category\n * jump-nav once there are 2+ categories). There is no flat/ungrouped mode and\n * no page-vs-embedded shell fork; the standalone /faqs page and every embed\n * render through this single path, so they cannot drift.\n *\n * - Standalone /faqs page: pass `initialFaqs` (SSR) + `heading={null}` (the\n * page owns the <h1>) + `emitJsonLd` with `jsonLd` overrides for SEO.\n * - Per-entity embed: pass `entityType` + `entityId` (no `initialFaqs`); the\n * hook self-fetches `GET /api/faqs`, and `heading` is this block's own <h2>.\n *\n * CONTRACT: the consuming app MUST implement `GET /api/faqs`. On a fetch error\n * (or zero FAQs) the component renders nothing so the host page isn't\n * disfigured. The host always supplies the page shell — this renders a bare\n * <section>.\n */\nexport function FaqSection({\n initialFaqs,\n entityType,\n entityId,\n heading,\n emitJsonLd = false,\n jsonLd,\n className,\n minResults,\n apiBaseUrl = '',\n}: FaqSectionProps) {\n const url = buildFaqsUrl(entityType, entityId, minResults, apiBaseUrl);\n // Memoized — useSelfFetch re-syncs on [initialData]; a fresh per-render\n // wrapper object would setState-loop under re-rendering parents.\n const initialData = useMemo<FaqsResponse | undefined>(\n () => (initialFaqs ? { faqs: initialFaqs } : undefined),\n [initialFaqs],\n );\n const { data, isLoading, error } = useSelfFetch<FaqsResponse>(url, { initialData });\n\n // Memoised because the `??` fallback minted a NEW array on every\n // render, which made the memo below re-run every time — i.e. do nothing.\n const faqs = useMemo(() => data?.faqs ?? [], [data?.faqs]);\n // Grouped before the early returns so the hook order stays stable.\n const groups = useMemo(() => (faqs.length > 0 ? groupFaqsBySection(faqs) : []), [faqs]);\n\n // `undefined` → default <h2> title; `null` → the host page owns the <h1>, so\n // no title renders here. `heading === null` also makes the category headings\n // <h2> (directly under the page <h1>); otherwise they nest as <h3>.\n const headingNode =\n heading === undefined ? <h2 className={SECTION_HEADING_CLASS}>{DEFAULT_HEADING_TEXT}</h2> : heading;\n\n // Degrade silently — never show an error banner or an empty section shell\n // where FAQs would be (host pages and the standalone surface both rely on it).\n if (error) return null;\n if (!isLoading && faqs.length === 0) return null;\n if (isLoading && faqs.length === 0) {\n return (\n <div className={className}>\n <FaqSkeleton />\n </div>\n );\n }\n\n const schema = emitJsonLd ? buildFaqJsonLdFromFaqs(faqs, jsonLd) : null;\n\n return (\n <>\n <section className={className ?? 'space-y-10'}>\n {headingNode}\n <GroupedFaqList groups={groups} categoryHeadingAs={heading === null ? 'h2' : 'h3'} />\n </section>\n {schema && (\n <script\n type=\"application/ld+json\"\n // serializeJsonLd, NOT raw JSON.stringify — FAQ answers are\n // admin-entered; an embedded \"</script>\" must not break the tag.\n dangerouslySetInnerHTML={{ __html: serializeJsonLd(schema) }}\n />\n )}\n </>\n );\n}\n","'use client';\n\nimport { useState } from 'react';\nimport { cn } from '../utils/cn';\nimport { faqItemAnchor } from '../utils/faq-anchor';\nimport { Chevron02DownIcon } from './icons-v2-generated/arrows/chevron-02-down-icon';\n\nexport interface FaqItem {\n id: number | string;\n question: string;\n answer: string;\n}\n\ninterface FaqAccordionProps {\n items: FaqItem[];\n defaultOpenIds?: (number | string)[];\n}\n\nexport function FaqAccordion({ items, defaultOpenIds = [] }: FaqAccordionProps) {\n const [openSet, setOpenSet] = useState<Set<string | number>>(new Set(defaultOpenIds));\n\n const toggle = (id: string | number) => {\n setOpenSet(prev => {\n const next = new Set(prev);\n if (next.has(id)) next.delete(id);\n else next.add(id);\n return next;\n });\n };\n\n return (\n <div className=\"divide-y divide-ods-border overflow-hidden rounded-md border border-ods-border bg-transparent\">\n {items.map(item => {\n const isOpen = openSet.has(item.id);\n\n return (\n <div\n key={item.id}\n // Per-row anchor — chat citation chips (`/faqs#faq-item-<id>`) land\n // here via native browser hash scroll AND via `FaqSection`'s tween\n // dispatch. `scroll-mt-24` keeps the row header below the 96px\n // sticky nav offset (matches `<section>`'s scroll-margin for\n // category anchors).\n id={faqItemAnchor(item.id)}\n className=\"scroll-mt-24 transition-colors hover:bg-ods-bg-hover\"\n >\n {/* Header */}\n <div\n role=\"button\"\n tabIndex={0}\n onClick={() => toggle(item.id)}\n onKeyDown={e => {\n if (e.key === 'Enter' || e.key === ' ') {\n e.preventDefault();\n toggle(item.id);\n }\n }}\n aria-expanded={isOpen}\n className=\"flex w-full cursor-pointer items-center gap-6 px-6 py-4 text-left transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-ods-focus md:gap-10\"\n >\n <h3 className=\"min-w-0 flex-1 break-words\">{item.question}</h3>\n <Chevron02DownIcon\n aria-hidden=\"true\"\n size={24}\n className={cn(\n 'shrink-0 text-ods-text-primary transition-transform duration-300',\n isOpen && 'rotate-180',\n )}\n />\n </div>\n {/* Content wrapper. Collapses with the grid 1fr->0fr transition the\n rest of the design system uses (see AnnouncementBar) rather than\n an animated max-height: measuring `scrollHeight` needed a hook\n PER ROW, which meant calling hooks inside `items.map` — the hook\n order then changed whenever `items` did. Grid needs no\n measurement, and it animates correctly when an answer's height\n changes after mount. */}\n <div\n className=\"grid transition-[grid-template-rows,opacity] duration-300 ease-in-out motion-reduce:transition-none\"\n style={{ gridTemplateRows: isOpen ? '1fr' : '0fr', opacity: isOpen ? 1 : 0 }}\n >\n {/* break-words: FAQ answers render as plain text, so a long URL or\n token has no wrap opportunity — and the row is overflow-hidden,\n which would CLIP it past the viewport on mobile. Mirrors the\n markdown-renderer overflow-wrap fix. */}\n <div className=\"overflow-hidden\">\n <div className=\"break-words px-6 pb-4 text-ods-text-primary text-h4\">{item.answer}</div>\n </div>\n </div>\n </div>\n );\n })}\n </div>\n );\n}\n","/**\n * Pure FAQ JSON-LD builder. No React, no client-only deps — safe to import from\n * Server Components via the `./components/faq` subpath export. (Do NOT import\n * through the root `./components` barrel — that barrel is `\"use client\"` and\n * dragging it into a Server Component would force the client graph into the\n * server.)\n *\n * The hub used to harcode `name`/`description` here for OpenMSP; in the lib we\n * accept overrides so every embedder can supply its own platform branding.\n */\nimport type { Faq } from '../../types/faq';\n\nexport interface FaqSchemaOptions {\n name?: string;\n description?: string;\n url?: string;\n}\n\nconst DEFAULT_NAME = 'Frequently Asked Questions';\nconst DEFAULT_DESCRIPTION = 'Answers to common questions.';\n\nexport function baseFaqSchema(opts: FaqSchemaOptions = {}) {\n return {\n '@context': 'https://schema.org',\n '@type': 'FAQPage',\n name: opts.name ?? DEFAULT_NAME,\n description: opts.description ?? DEFAULT_DESCRIPTION,\n ...(opts.url ? { url: opts.url } : {}),\n } as const;\n}\n\nexport function buildFaqJsonLdFromFaqs(faqs: Faq[], opts: FaqSchemaOptions = {}) {\n return {\n ...baseFaqSchema(opts),\n mainEntity: faqs.map(faq => ({\n '@type': 'Question',\n name: faq.question,\n acceptedAnswer: {\n '@type': 'Answer',\n text: faq.answer,\n },\n })),\n } as const;\n}\n","'use client';\n\n/**\n * FaqDocumentPage — the full `/faqs` page with chrome, so embedders drop in\n * ONE component instead of hand-assembling `PageShell` + `PageLayout` around\n * the bare `<FaqSection>`. Mirrors `LegalDocumentPage` / `DevSectionPage`: the\n * page-level layout lives in the lib, the host page is a thin wrapper that\n * passes only config + the SSR-resolved data.\n *\n * HERO: the title + subtitle route through the canonical (frozen) `PageLayout`\n * `TitleBlock` with `titleSize=\"h1\"` — the unified Help Center header (the\n * `TitleBlock` element is always an `<h1>`; `titleSize` only sets its typography,\n * here `text-h1`). The page owns that `<h1>`, so `<FaqSection heading={null}>`\n * nests its category headings as `<h2>`/`<h3>` (the SEO-recommended FAQ document\n * outline).\n *\n * DATA: pass `initialFaqs` (SSR-resolved, platform-scoped) so `FaqSection`\n * skips its client self-fetch — the standalone page's static platform-only\n * contract. Omit it for embeds that want the self-fetching `/api/faqs`\n * suggestion-fill instead.\n */\n\nimport { useRouter } from '../../embed-shims/next-navigation';\nimport type { Faq } from '../../types/faq';\nimport { PageShell, PageLayout } from '../ui';\nimport { FaqSection } from './faq-section';\nimport type { FaqSchemaOptions } from './json-ld';\n\nexport interface FaqDocumentPageProps {\n /** Page title (frozen `PageLayout` `TitleBlock`). Default \"Frequently Asked Questions\". */\n title?: string;\n /** Subtitle under the title. */\n subtitle?: string;\n /** Back-button config — same pattern as `DevSectionPage` / `LegalDocumentPage`.\n * Pass `false` to hide. Default `{ label: 'Back to home', href: '/' }`. */\n backButton?: { label?: string; href?: string } | false;\n /** Render the standalone `<PageShell>` (own `<main>` + bg + max-width). Default\n * true. Pass false when the host layout already provides the page container\n * (e.g. openframe-frontend's `AppLayout` `<main>`) — only the padding box\n * renders, avoiding a nested `<main>`. */\n shell?: boolean;\n /** SSR-hydrate `FaqSection` (skips the client fetch — the platform-only\n * contract for the standalone page). Omit for self-fetching embeds. */\n initialFaqs?: Faq[];\n /** Emit FAQPage schema.org JSON-LD (forwarded to `FaqSection`). Off by\n * default so embeds don't emit duplicate schema. */\n emitJsonLd?: boolean;\n /** JSON-LD name/description/url overrides (forwarded to `FaqSection`). */\n jsonLd?: FaqSchemaOptions;\n /** Base URL `FaqSection` appends `/api/faqs` to (reverse-proxy embedders). */\n apiBaseUrl?: string;\n /** Optional entity scoping forwarded to `FaqSection`. */\n entityType?: string;\n entityId?: number | string;\n /** Minimum FAQ count before the section renders (forwarded to `FaqSection`). */\n minResults?: number;\n}\n\nexport function FaqDocumentPage({\n title = 'Frequently Asked Questions',\n subtitle,\n backButton,\n initialFaqs,\n emitJsonLd,\n jsonLd,\n apiBaseUrl,\n entityType,\n entityId,\n minResults,\n shell = true,\n}: FaqDocumentPageProps) {\n const router = useRouter();\n\n // Back-button config — mirrors LegalDocumentPage / DevSectionPage. Hide\n // entirely when the caller passes `false` (embed-mode where the host owns\n // nav chrome).\n const backCfg =\n backButton === false\n ? undefined\n : {\n label: backButton?.label ?? 'Back to home',\n onClick: () => router.push(backButton?.href ?? '/'),\n };\n\n const inner = (\n <PageLayout title={title} subtitle={subtitle} backButton={backCfg} titleSize=\"h1\" titleWrap>\n <FaqSection\n initialFaqs={initialFaqs}\n heading={null}\n emitJsonLd={emitJsonLd}\n jsonLd={jsonLd}\n apiBaseUrl={apiBaseUrl}\n entityType={entityType}\n entityId={entityId}\n minResults={minResults}\n />\n </PageLayout>\n );\n\n return shell ? <PageShell>{inner}</PageShell> : <div className=\"page-shell-content\">{inner}</div>;\n}\n"]}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } } function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; }"use client";
|
|
2
2
|
|
|
3
3
|
|
|
4
|
-
var
|
|
4
|
+
var _chunkT32BTPL5cjs = require('./chunk-T32BTPL5.cjs');
|
|
5
5
|
|
|
6
6
|
|
|
7
7
|
|
|
@@ -56,7 +56,7 @@ function DetailPageSkeleton({
|
|
|
56
56
|
] }, section))
|
|
57
57
|
] });
|
|
58
58
|
if (bare) return content;
|
|
59
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
59
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkT32BTPL5cjs.PageLayout, { showHeader: false, className: "mx-auto max-w-[1280px] bg-ods-bg px-6 py-6 md:px-20 md:py-10", children: content });
|
|
60
60
|
}
|
|
61
61
|
|
|
62
62
|
// src/components/shared/article-author-byline.tsx
|
|
@@ -137,4 +137,4 @@ function ArticleAuthorByline({
|
|
|
137
137
|
|
|
138
138
|
|
|
139
139
|
exports.DetailPageSkeleton = DetailPageSkeleton; exports.ArticleAuthorByline = ArticleAuthorByline;
|
|
140
|
-
//# sourceMappingURL=chunk-
|
|
140
|
+
//# sourceMappingURL=chunk-XEESEFGT.cjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["/home/runner/work/openframe-oss-lib/openframe-oss-lib/openframe-frontend-core/dist/chunk-AF4XOURN.cjs","../src/components/shared/detail-page-skeleton.tsx","../src/components/shared/article-author-byline.tsx"],"names":["jsxs","jsx"],"mappings":"AAAA,6rBAAY;AACZ;AACE;AACF,wDAA6B;AAC7B;AACE;AACA;AACA;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACA;ACCQ,+CAAA;AATD,SAAS,kBAAA,CAAmB;AAAA,EACjC,gBAAA,EAAkB,CAAA;AAAA,EAClB,iBAAA,EAAmB,IAAA;AAAA,EACnB,KAAA,EAAO;AACT,EAAA,EAA6B,CAAC,CAAA,EAAG;AAC/B,EAAA,MAAM,QAAA,kBACJ,8BAAA,KAAC,EAAA,EAAI,SAAA,EAAU,uCAAA,EAEb,QAAA,EAAA;AAAA,oBAAA,6BAAA,KAAC,EAAA,EAAI,SAAA,EAAU,4BAAA,EACb,QAAA,kBAAA,6BAAA,KAAC,EAAA,EAAI,SAAA,EAAU,oDAAA,CAAoD,EAAA,CACrE,CAAA;AAAA,oBAGA,8BAAA,KAAC,EAAA,EAAI,SAAA,EAAU,6BAAA,EACb,QAAA,EAAA;AAAA,sBAAA,6BAAA,KAAC,EAAA,EAAI,SAAA,EAAU,+BAAA,CAA+B,CAAA;AAAA,sBAC9C,6BAAA,KAAC,EAAA,EAAI,SAAA,EAAU,+BAAA,CAA+B,CAAA;AAAA,sBAC9C,6BAAA,KAAC,EAAA,EAAI,SAAA,EAAU,+BAAA,CAA+B;AAAA,IAAA,EAAA,CAChD,CAAA;AAAA,oBAGA,6BAAA;AAAA,MAAC,KAAA;AAAA,MAAA;AAAA,QACC,SAAA,EAAW,CAAA,8BAAA,EAAiC,eAAe,CAAA,2DAAA,CAAA;AAAA,QAE1D,QAAA,EAAA,KAAA,CAAM,IAAA,CAAK,EAAE,MAAA,EAAQ,gBAAgB,CAAC,CAAA,CAAE,GAAA,CAAI,CAAC,CAAA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EAAA,OAAA,CACH,EAAA,EAEA,OAAA,CAEJ,CAAA;AAAA,YACC,UAAA,mBACCD,8BAAAA,MAAC,EAAA,EAAK,SAAA,EAAU,+EAAA,EACd,QAAA,EAAA;AAAA,8BAAAC,6BAAAA,qBAAC,EAAA,EAAS,SAAA,EAAU,UAAA,CAAU,CAAA;AAAA,cAC7B;AAAA,YAAA,EAAA,CACH;AAAA,UAAA,EAAA,CAEJ,CAAA;AAAA,UACC,SAAA,mBAAYA,6BAAAA,GAAC,EAAA,EAAE,SAAA,EAAU,uDAAA,EAAyD,QAAA,EAAA,SAAA,CAAS,CAAA;AAAA,UAC3F,aAAA,kBACCA,6BAAAA,GAAC,EAAA,EAAE,SAAA,EAAU,qEAAA,EAAuE,QAAA,EAAA,aAAA,CAAa,EAAA,EAC/F,YAAA,kBACFA,6BAAAA,GAAC,EAAA,EAAE,SAAA,EAAU,4DAAA,EAA8D,QAAA,EAAA,YAAA,CAAY,EAAA,EACrF;AAAA,QAAA,EAAA,CACN;AAAA,MAAA;AAAA,IAAA;AAAA,EACF,CAAA;AAEJ;AFjCA;AACA;AACE;AACA;AACF,mGAAC","file":"/home/runner/work/openframe-oss-lib/openframe-oss-lib/openframe-frontend-core/dist/chunk-AF4XOURN.cjs","sourcesContent":[null,"'use client';\n\nimport { PageLayout } from '../layout/page-layout';\n\nexport interface DetailPageSkeletonProps {\n metadataColumns?: number; // Number of metadata grid columns (default 4)\n showImageGallery?: boolean; // Show horizontal image gallery (default true)\n /** Render only the skeleton blocks, WITHOUT the self-contained page wrapper\n * — the caller supplies its own (e.g. `<PageShell>`) so the loading state\n * matches the loaded page's width, padding, and min-height. Default false\n * (self-contained `<PageLayout>` at the hub article width). */\n bare?: boolean;\n}\n\nexport function DetailPageSkeleton({\n metadataColumns = 4,\n showImageGallery = true,\n bare = false,\n}: DetailPageSkeletonProps = {}) {\n const content = (\n <div className=\"animate-pulse space-y-6 md:space-y-10\">\n {/* Title Block */}\n <div className=\"flex w-full flex-col gap-6\">\n <div className=\"h-16 w-full max-w-3xl rounded bg-ods-card md:h-20\"></div>\n </div>\n\n {/* Category Tags Skeleton */}\n <div className=\"flex w-full flex-wrap gap-2\">\n <div className=\"h-8 w-32 rounded bg-ods-card\"></div>\n <div className=\"h-8 w-28 rounded bg-ods-card\"></div>\n <div className=\"h-8 w-36 rounded bg-ods-card\"></div>\n </div>\n\n {/* Metadata Grid Skeleton */}\n <div\n className={`grid grid-cols-1 md:grid-cols-${metadataColumns} w-full overflow-hidden rounded-md border border-ods-border`}\n >\n {Array.from({ length: metadataColumns }).map((_, i) => (\n <div key={i} className=\"border-b border-ods-border bg-ods-card p-4 last:border-r-0 md:border-b-0 md:border-r\">\n <div className=\"mb-2 h-6 w-24 rounded bg-ods-border\"></div>\n <div className=\"h-5 w-20 rounded bg-ods-border\"></div>\n </div>\n ))}\n </div>\n\n {/* Image Gallery Skeleton */}\n {showImageGallery && (\n <div className=\"flex w-full gap-6 overflow-x-auto\">\n {[1, 2, 3, 4, 5].map(i => (\n <div key={i} className=\"h-[200px] w-[240px] shrink-0 rounded-md border border-ods-border bg-ods-card\"></div>\n ))}\n </div>\n )}\n\n {/* Featured Image Skeleton (for case studies) */}\n {!showImageGallery && <div className=\"aspect-[2560/1366] w-full rounded-md bg-ods-card\"></div>}\n\n {/* Content Sections Skeleton */}\n {[1, 2, 3].map(section => (\n <div key={section} className=\"space-y-6\">\n <div className=\"h-16 w-64 rounded bg-ods-card\"></div>\n <div className=\"space-y-3\">\n <div className=\"h-6 w-full rounded bg-ods-card\"></div>\n <div className=\"h-6 w-full rounded bg-ods-card\"></div>\n <div className=\"h-6 w-4/5 rounded bg-ods-card\"></div>\n </div>\n </div>\n ))}\n </div>\n );\n if (bare) return content;\n return (\n <PageLayout showHeader={false} className=\"mx-auto max-w-[1280px] bg-ods-bg px-6 py-6 md:px-20 md:py-10\">\n {content}\n </PageLayout>\n );\n}\n","'use client';\n\n/**\n * Shared \"author byline\" card used by article-shaped detail pages\n * (blog post, product release, onboarding guide, investor update).\n *\n * MOVED from the hub so any consuming app can embed it; hub call sites\n * import it directly and pass their platform-aware copy explicitly\n * (`fallbackBio={defaultAuthorFallbackBio()}` from the hub's app-config).\n *\n * Embed-readiness contract:\n * - `Link` / `Image` render through the embed-shims (plain `<a>` / `<img>`\n * in non-Next hosts; the real Next primitives once the host registers\n * them at app init).\n * - The avatar is proxied through the OPTIONAL ambient `ChatRuntime`\n * (`endpoints.imageProxyUrlPrefix`, same config `useProxiedImageUrl`\n * reads) — when no runtime is mounted the raw URL renders as-is, so the\n * component never throws outside a provider. Hosts can also inject\n * `proxyImageUrl` to bypass the runtime entirely.\n * - `fallbackBio` is a PLAIN prop (no app-config import): the lib has no\n * platform awareness; pass copy or leave it absent to render nothing.\n *\n * Render order: avatar → name + job title + date → bio (when present).\n * Returns null when `author` is empty (no card rendered).\n */\n\nimport { Calendar, User } from 'lucide-react';\nimport { useChatRuntime } from '../../contexts/chat-runtime-context';\nimport Image from '../../embed-shims/next-image';\nimport Link from '../../embed-shims/next-link';\nimport { cn } from '../../utils/cn';\nimport { formatBioText, formatDateWithTimezone } from '../../utils/format';\nimport { getProxiedImageUrl } from '../../utils/image-proxy';\n\nexport interface ArticleAuthorBylineProps {\n /** Author display name. Required — block is hidden when null/empty. */\n author: string | null;\n /** Avatar URL. Falls back to a placeholder when null. */\n avatar?: string | null;\n /** Optional bio paragraph rendered below the name. */\n bio?: string | null;\n /** Optional job title rendered immediately under the name. */\n jobTitle?: string | null;\n /** Optional published date (ISO string or Date). Rendered next to the name. */\n publishedAt?: string | Date | null;\n /** Optional link target for the author name (e.g. the author page). */\n href?: string | null;\n /**\n * Fallback paragraph when `bio` is empty. Plain copy — the lib has no\n * platform/config awareness, so hosts that want a branded default\n * (\"Contributing author on the {platform} platform\") pass it explicitly\n * (the hub wrapper derives it from `getAppConfig()`). Absent/null ⇒\n * nothing renders below the name when `bio` is empty.\n */\n fallbackBio?: string | null;\n /** Avatar size variant. `md` = 56px (default), `lg` = 64px. */\n size?: 'md' | 'lg';\n /**\n * Host-injected avatar-URL mapper. Wins over the ambient-runtime proxy\n * resolution. Use when the host proxies images outside the `ChatRuntime`\n * config (e.g. a bespoke CDN rewrite).\n */\n proxyImageUrl?: (url: string) => string;\n className?: string;\n}\n\nfunction formatDate(value: string | Date): string {\n // A published date is a content date: UTC-pinned through the one renderer, so\n // the server and every client agree on the day (React #418).\n return formatDateWithTimezone(value, null, 'long');\n}\n\nexport function ArticleAuthorByline({\n author,\n avatar,\n bio,\n jobTitle,\n publishedAt,\n href,\n fallbackBio,\n size = 'md',\n proxyImageUrl,\n className,\n}: ArticleAuthorBylineProps) {\n // Optional runtime — `useChatRuntime` returns null outside a provider, so\n // the byline works in bare embeds (raw avatar URL) and proxies whenever the\n // host mounted a runtime with `imageProxyUrlPrefix` (the hub always does).\n const runtime = useChatRuntime();\n if (!author) return null;\n\n const proxiedAvatar = avatar\n ? proxyImageUrl\n ? proxyImageUrl(avatar)\n : (getProxiedImageUrl(avatar, {\n proxyPrefix: runtime?.endpoints.imageProxyUrlPrefix,\n skipDomains: runtime?.endpoints.imageProxySkipDomains,\n directHttps: true,\n }) ?? avatar)\n : '';\n\n // Class-driven sizing (md = 56px, lg = 64px). The numeric pair feeds only\n // the Image element's intrinsic width/height attributes (required by the\n // Next image shim) — layout comes from the classes.\n const avatarSizeClass = size === 'lg' ? 'w-16 h-16' : 'w-14 h-14';\n const avatarIconClass = size === 'lg' ? 'w-8 h-8' : 'w-7 h-7';\n const avatarDim = size === 'lg' ? 64 : 56;\n const formattedBio = formatBioText(bio ?? null);\n const dateLabel = publishedAt ? formatDate(publishedAt) : '';\n\n return (\n <div\n className={cn(\n 'rounded-lg border border-ods-border bg-ods-card p-6',\n 'flex flex-col items-start gap-4 md:flex-row',\n className,\n )}\n >\n {/* Avatar */}\n <div className=\"flex-shrink-0\">\n {avatar ? (\n <Image\n src={proxiedAvatar || avatar}\n alt={author}\n width={avatarDim}\n height={avatarDim}\n className={cn('rounded-full border-2 border-ods-border object-cover', avatarSizeClass)}\n />\n ) : (\n <div\n className={cn(\n 'flex items-center justify-center rounded-full border-2 border-ods-border bg-ods-bg',\n avatarSizeClass,\n )}\n >\n <User className={cn('text-ods-text-secondary', avatarIconClass)} />\n </div>\n )}\n </div>\n\n {/* Name + meta + bio */}\n <div className=\"min-w-0 flex-1\">\n <div className=\"flex flex-wrap items-baseline gap-x-3 gap-y-1\">\n <h3 className=\"text-ods-text-primary text-h5\">\n {href ? (\n <Link href={href} className=\"transition-colors hover:text-ods-accent\">\n {author}\n </Link>\n ) : (\n author\n )}\n </h3>\n {dateLabel && (\n <span className=\"text-body-sm inline-flex items-center gap-1 font-body text-ods-text-secondary\">\n <Calendar className=\"h-3 w-3\" />\n {dateLabel}\n </span>\n )}\n </div>\n {jobTitle && <p className=\"text-body-sm mt-0.5 font-body text-ods-text-secondary\">{jobTitle}</p>}\n {formattedBio ? (\n <p className=\"text-body-md mt-2 font-body leading-relaxed text-ods-text-secondary\">{formattedBio}</p>\n ) : fallbackBio ? (\n <p className=\"text-body-md mt-2 font-body italic text-ods-text-secondary\">{fallbackBio}</p>\n ) : null}\n </div>\n </div>\n );\n}\n"]}
|
|
1
|
+
{"version":3,"sources":["/home/runner/work/openframe-oss-lib/openframe-oss-lib/openframe-frontend-core/dist/chunk-XEESEFGT.cjs","../src/components/shared/detail-page-skeleton.tsx","../src/components/shared/article-author-byline.tsx"],"names":["jsxs","jsx"],"mappings":"AAAA,6rBAAY;AACZ;AACE;AACF,wDAA6B;AAC7B;AACE;AACA;AACA;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACA;ACCQ,+CAAA;AATD,SAAS,kBAAA,CAAmB;AAAA,EACjC,gBAAA,EAAkB,CAAA;AAAA,EAClB,iBAAA,EAAmB,IAAA;AAAA,EACnB,KAAA,EAAO;AACT,EAAA,EAA6B,C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EAAA,EAAE,SAAA,EAAU,qEAAA,EAAuE,QAAA,EAAA,aAAA,CAAa,EAAA,EAC/F,YAAA,kBACFA,6BAAAA,GAAC,EAAA,EAAE,SAAA,EAAU,4DAAA,EAA8D,QAAA,EAAA,YAAA,CAAY,EAAA,EACrF;AAAA,QAAA,EAAA,CACN;AAAA,MAAA;AAAA,IAAA;AAAA,EACF,CAAA;AAEJ;AFjCA;AACA;AACE;AACA;AACF,mGAAC","file":"/home/runner/work/openframe-oss-lib/openframe-oss-lib/openframe-frontend-core/dist/chunk-XEESEFGT.cjs","sourcesContent":[null,"'use client';\n\nimport { PageLayout } from '../layout/page-layout';\n\nexport interface DetailPageSkeletonProps {\n metadataColumns?: number; // Number of metadata grid columns (default 4)\n showImageGallery?: boolean; // Show horizontal image gallery (default true)\n /** Render only the skeleton blocks, WITHOUT the self-contained page wrapper\n * — the caller supplies its own (e.g. `<PageShell>`) so the loading state\n * matches the loaded page's width, padding, and min-height. Default false\n * (self-contained `<PageLayout>` at the hub article width). */\n bare?: boolean;\n}\n\nexport function DetailPageSkeleton({\n metadataColumns = 4,\n showImageGallery = true,\n bare = false,\n}: DetailPageSkeletonProps = {}) {\n const content = (\n <div className=\"animate-pulse space-y-6 md:space-y-10\">\n {/* Title Block */}\n <div className=\"flex w-full flex-col gap-6\">\n <div className=\"h-16 w-full max-w-3xl rounded bg-ods-card md:h-20\"></div>\n </div>\n\n {/* Category Tags Skeleton */}\n <div className=\"flex w-full flex-wrap gap-2\">\n <div className=\"h-8 w-32 rounded bg-ods-card\"></div>\n <div className=\"h-8 w-28 rounded bg-ods-card\"></div>\n <div className=\"h-8 w-36 rounded bg-ods-card\"></div>\n </div>\n\n {/* Metadata Grid Skeleton */}\n <div\n className={`grid grid-cols-1 md:grid-cols-${metadataColumns} w-full overflow-hidden rounded-md border border-ods-border`}\n >\n {Array.from({ length: metadataColumns }).map((_, i) => (\n <div key={i} className=\"border-b border-ods-border bg-ods-card p-4 last:border-r-0 md:border-b-0 md:border-r\">\n <div className=\"mb-2 h-6 w-24 rounded bg-ods-border\"></div>\n <div className=\"h-5 w-20 rounded bg-ods-border\"></div>\n </div>\n ))}\n </div>\n\n {/* Image Gallery Skeleton */}\n {showImageGallery && (\n <div className=\"flex w-full gap-6 overflow-x-auto\">\n {[1, 2, 3, 4, 5].map(i => (\n <div key={i} className=\"h-[200px] w-[240px] shrink-0 rounded-md border border-ods-border bg-ods-card\"></div>\n ))}\n </div>\n )}\n\n {/* Featured Image Skeleton (for case studies) */}\n {!showImageGallery && <div className=\"aspect-[2560/1366] w-full rounded-md bg-ods-card\"></div>}\n\n {/* Content Sections Skeleton */}\n {[1, 2, 3].map(section => (\n <div key={section} className=\"space-y-6\">\n <div className=\"h-16 w-64 rounded bg-ods-card\"></div>\n <div className=\"space-y-3\">\n <div className=\"h-6 w-full rounded bg-ods-card\"></div>\n <div className=\"h-6 w-full rounded bg-ods-card\"></div>\n <div className=\"h-6 w-4/5 rounded bg-ods-card\"></div>\n </div>\n </div>\n ))}\n </div>\n );\n if (bare) return content;\n return (\n <PageLayout showHeader={false} className=\"mx-auto max-w-[1280px] bg-ods-bg px-6 py-6 md:px-20 md:py-10\">\n {content}\n </PageLayout>\n );\n}\n","'use client';\n\n/**\n * Shared \"author byline\" card used by article-shaped detail pages\n * (blog post, product release, onboarding guide, investor update).\n *\n * MOVED from the hub so any consuming app can embed it; hub call sites\n * import it directly and pass their platform-aware copy explicitly\n * (`fallbackBio={defaultAuthorFallbackBio()}` from the hub's app-config).\n *\n * Embed-readiness contract:\n * - `Link` / `Image` render through the embed-shims (plain `<a>` / `<img>`\n * in non-Next hosts; the real Next primitives once the host registers\n * them at app init).\n * - The avatar is proxied through the OPTIONAL ambient `ChatRuntime`\n * (`endpoints.imageProxyUrlPrefix`, same config `useProxiedImageUrl`\n * reads) — when no runtime is mounted the raw URL renders as-is, so the\n * component never throws outside a provider. Hosts can also inject\n * `proxyImageUrl` to bypass the runtime entirely.\n * - `fallbackBio` is a PLAIN prop (no app-config import): the lib has no\n * platform awareness; pass copy or leave it absent to render nothing.\n *\n * Render order: avatar → name + job title + date → bio (when present).\n * Returns null when `author` is empty (no card rendered).\n */\n\nimport { Calendar, User } from 'lucide-react';\nimport { useChatRuntime } from '../../contexts/chat-runtime-context';\nimport Image from '../../embed-shims/next-image';\nimport Link from '../../embed-shims/next-link';\nimport { cn } from '../../utils/cn';\nimport { formatBioText, formatDateWithTimezone } from '../../utils/format';\nimport { getProxiedImageUrl } from '../../utils/image-proxy';\n\nexport interface ArticleAuthorBylineProps {\n /** Author display name. Required — block is hidden when null/empty. */\n author: string | null;\n /** Avatar URL. Falls back to a placeholder when null. */\n avatar?: string | null;\n /** Optional bio paragraph rendered below the name. */\n bio?: string | null;\n /** Optional job title rendered immediately under the name. */\n jobTitle?: string | null;\n /** Optional published date (ISO string or Date). Rendered next to the name. */\n publishedAt?: string | Date | null;\n /** Optional link target for the author name (e.g. the author page). */\n href?: string | null;\n /**\n * Fallback paragraph when `bio` is empty. Plain copy — the lib has no\n * platform/config awareness, so hosts that want a branded default\n * (\"Contributing author on the {platform} platform\") pass it explicitly\n * (the hub wrapper derives it from `getAppConfig()`). Absent/null ⇒\n * nothing renders below the name when `bio` is empty.\n */\n fallbackBio?: string | null;\n /** Avatar size variant. `md` = 56px (default), `lg` = 64px. */\n size?: 'md' | 'lg';\n /**\n * Host-injected avatar-URL mapper. Wins over the ambient-runtime proxy\n * resolution. Use when the host proxies images outside the `ChatRuntime`\n * config (e.g. a bespoke CDN rewrite).\n */\n proxyImageUrl?: (url: string) => string;\n className?: string;\n}\n\nfunction formatDate(value: string | Date): string {\n // A published date is a content date: UTC-pinned through the one renderer, so\n // the server and every client agree on the day (React #418).\n return formatDateWithTimezone(value, null, 'long');\n}\n\nexport function ArticleAuthorByline({\n author,\n avatar,\n bio,\n jobTitle,\n publishedAt,\n href,\n fallbackBio,\n size = 'md',\n proxyImageUrl,\n className,\n}: ArticleAuthorBylineProps) {\n // Optional runtime — `useChatRuntime` returns null outside a provider, so\n // the byline works in bare embeds (raw avatar URL) and proxies whenever the\n // host mounted a runtime with `imageProxyUrlPrefix` (the hub always does).\n const runtime = useChatRuntime();\n if (!author) return null;\n\n const proxiedAvatar = avatar\n ? proxyImageUrl\n ? proxyImageUrl(avatar)\n : (getProxiedImageUrl(avatar, {\n proxyPrefix: runtime?.endpoints.imageProxyUrlPrefix,\n skipDomains: runtime?.endpoints.imageProxySkipDomains,\n directHttps: true,\n }) ?? avatar)\n : '';\n\n // Class-driven sizing (md = 56px, lg = 64px). The numeric pair feeds only\n // the Image element's intrinsic width/height attributes (required by the\n // Next image shim) — layout comes from the classes.\n const avatarSizeClass = size === 'lg' ? 'w-16 h-16' : 'w-14 h-14';\n const avatarIconClass = size === 'lg' ? 'w-8 h-8' : 'w-7 h-7';\n const avatarDim = size === 'lg' ? 64 : 56;\n const formattedBio = formatBioText(bio ?? null);\n const dateLabel = publishedAt ? formatDate(publishedAt) : '';\n\n return (\n <div\n className={cn(\n 'rounded-lg border border-ods-border bg-ods-card p-6',\n 'flex flex-col items-start gap-4 md:flex-row',\n className,\n )}\n >\n {/* Avatar */}\n <div className=\"flex-shrink-0\">\n {avatar ? (\n <Image\n src={proxiedAvatar || avatar}\n alt={author}\n width={avatarDim}\n height={avatarDim}\n className={cn('rounded-full border-2 border-ods-border object-cover', avatarSizeClass)}\n />\n ) : (\n <div\n className={cn(\n 'flex items-center justify-center rounded-full border-2 border-ods-border bg-ods-bg',\n avatarSizeClass,\n )}\n >\n <User className={cn('text-ods-text-secondary', avatarIconClass)} />\n </div>\n )}\n </div>\n\n {/* Name + meta + bio */}\n <div className=\"min-w-0 flex-1\">\n <div className=\"flex flex-wrap items-baseline gap-x-3 gap-y-1\">\n <h3 className=\"text-ods-text-primary text-h5\">\n {href ? (\n <Link href={href} className=\"transition-colors hover:text-ods-accent\">\n {author}\n </Link>\n ) : (\n author\n )}\n </h3>\n {dateLabel && (\n <span className=\"text-body-sm inline-flex items-center gap-1 font-body text-ods-text-secondary\">\n <Calendar className=\"h-3 w-3\" />\n {dateLabel}\n </span>\n )}\n </div>\n {jobTitle && <p className=\"text-body-sm mt-0.5 font-body text-ods-text-secondary\">{jobTitle}</p>}\n {formattedBio ? (\n <p className=\"text-body-md mt-2 font-body leading-relaxed text-ods-text-secondary\">{formattedBio}</p>\n ) : fallbackBio ? (\n <p className=\"text-body-md mt-2 font-body italic text-ods-text-secondary\">{fallbackBio}</p>\n ) : null}\n </div>\n </div>\n );\n}\n"]}
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});"use client";
|
|
2
2
|
|
|
3
3
|
|
|
4
|
-
var
|
|
4
|
+
var _chunk3ADAUFKKcjs = require('../../chunk-3ADAUFKK.cjs');
|
|
5
5
|
|
|
6
6
|
|
|
7
7
|
|
|
8
8
|
|
|
9
9
|
|
|
10
10
|
|
|
11
|
-
var
|
|
11
|
+
var _chunkT32BTPL5cjs = require('../../chunk-T32BTPL5.cjs');
|
|
12
12
|
require('../../chunk-GQWM3ECA.cjs');
|
|
13
13
|
require('../../chunk-TON3YCCW.cjs');
|
|
14
14
|
|
|
@@ -21,7 +21,7 @@ require('../../chunk-PTFE5WKP.cjs');
|
|
|
21
21
|
|
|
22
22
|
|
|
23
23
|
|
|
24
|
-
var
|
|
24
|
+
var _chunkLL35WZZScjs = require('../../chunk-LL35WZZS.cjs');
|
|
25
25
|
require('../../chunk-IJUQQTMV.cjs');
|
|
26
26
|
require('../../chunk-SADRZ4YI.cjs');
|
|
27
27
|
|
|
@@ -93,9 +93,9 @@ function ShareExperienceSection({
|
|
|
93
93
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "h3", { className: "text-h2", children: howItWorksTitle }),
|
|
94
94
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-h4", children: howItWorksBody })
|
|
95
95
|
] }),
|
|
96
|
-
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
|
|
96
|
+
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkT32BTPL5cjs.BenefitCardGrid, { columns: 4, children: [
|
|
97
97
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
98
|
-
|
|
98
|
+
_chunkT32BTPL5cjs.BenefitCard,
|
|
99
99
|
{
|
|
100
100
|
icon: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "flex h-12 w-12 items-center justify-center rounded-md border border-ods-border bg-ods-bg p-2", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk5R4QMTMLcjs.G2Icon, { width: 24, height: 24 }) }),
|
|
101
101
|
title: "G2",
|
|
@@ -104,7 +104,7 @@ function ShareExperienceSection({
|
|
|
104
104
|
}
|
|
105
105
|
),
|
|
106
106
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
107
|
-
|
|
107
|
+
_chunkT32BTPL5cjs.BenefitCard,
|
|
108
108
|
{
|
|
109
109
|
icon: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "flex h-12 w-12 items-center justify-center rounded-md border border-ods-border bg-ods-bg p-2", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk5R4QMTMLcjs.CapterraIcon, { width: 24, height: 24 }) }),
|
|
110
110
|
title: "Capterra",
|
|
@@ -113,7 +113,7 @@ function ShareExperienceSection({
|
|
|
113
113
|
}
|
|
114
114
|
),
|
|
115
115
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
116
|
-
|
|
116
|
+
_chunkT32BTPL5cjs.BenefitCard,
|
|
117
117
|
{
|
|
118
118
|
icon: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "flex h-12 w-12 items-center justify-center rounded-md border border-ods-border bg-ods-bg p-2", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk5R4QMTMLcjs.TrustpilotIcon, { width: 24, height: 24 }) }),
|
|
119
119
|
title: "TrustPilot",
|
|
@@ -122,7 +122,7 @@ function ShareExperienceSection({
|
|
|
122
122
|
}
|
|
123
123
|
),
|
|
124
124
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
125
|
-
|
|
125
|
+
_chunkT32BTPL5cjs.BenefitCard,
|
|
126
126
|
{
|
|
127
127
|
icon: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "flex h-12 w-12 items-center justify-center rounded-md border border-ods-border bg-ods-bg p-2", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk5R4QMTMLcjs.GetAppIcon, { width: 24, height: 24 }) }),
|
|
128
128
|
title: "GetApp",
|
|
@@ -131,7 +131,7 @@ function ShareExperienceSection({
|
|
|
131
131
|
}
|
|
132
132
|
)
|
|
133
133
|
] }),
|
|
134
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
134
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3ADAUFKKcjs.ContactForm, { ...DEFAULT_CONTACT_FORM_PROPS, ...contactFormProps })
|
|
135
135
|
] }) })
|
|
136
136
|
] });
|
|
137
137
|
}
|
|
@@ -141,10 +141,10 @@ function ShareExperienceSection({
|
|
|
141
141
|
function EntityQuotesPanel({ quotes, className }) {
|
|
142
142
|
if (!quotes || quotes.length === 0) return null;
|
|
143
143
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
144
|
-
|
|
144
|
+
_chunkT32BTPL5cjs.StackedRowsPanel,
|
|
145
145
|
{
|
|
146
146
|
className,
|
|
147
|
-
title: `${
|
|
147
|
+
title: `${_chunkT32BTPL5cjs.ENTITY_QUOTES_TITLE} \xB7 ${quotes.length}`,
|
|
148
148
|
rows: quotes.map((q) => ({
|
|
149
149
|
id: q.key,
|
|
150
150
|
columns: [
|
|
@@ -170,7 +170,7 @@ function EntityQuotesPanel({ quotes, className }) {
|
|
|
170
170
|
function QuoteCardsStrip({ quotes, className }) {
|
|
171
171
|
if (quotes.length === 0) return null;
|
|
172
172
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
173
|
-
|
|
173
|
+
_chunkLL35WZZScjs.CardsStrip,
|
|
174
174
|
{
|
|
175
175
|
className,
|
|
176
176
|
showTitle: false,
|
|
@@ -185,8 +185,8 @@ function QuoteCardsStrip({ quotes, className }) {
|
|
|
185
185
|
onPointerLeave: ctx.isTouch ? void 0 : () => ctx.onDeactivate(ctx.cardKey),
|
|
186
186
|
className: "relative shrink-0 rounded-md border-ods-border bg-ods-card p-[var(--spacing-system-sf)] shadow-none hover:border-ods-border-hover",
|
|
187
187
|
children: [
|
|
188
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
189
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
188
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkT32BTPL5cjs.PersonCell, { size: "lg", name: `"${quote.text}"`, secondary: quote.attribution, avatarUrl: quote.logoUrl }),
|
|
189
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkLL35WZZScjs.CardHitLayer, { href: quote.href, label: `${quote.text}, ${quote.attribution}`, decorative: ctx.isClone })
|
|
190
190
|
]
|
|
191
191
|
},
|
|
192
192
|
ctx.cardKey
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import {
|
|
3
3
|
ContactForm
|
|
4
|
-
} from "../../chunk-
|
|
4
|
+
} from "../../chunk-JSXNOXZQ.js";
|
|
5
5
|
import {
|
|
6
6
|
BenefitCard,
|
|
7
7
|
BenefitCardGrid,
|
|
8
8
|
ENTITY_QUOTES_TITLE,
|
|
9
9
|
PersonCell,
|
|
10
10
|
StackedRowsPanel
|
|
11
|
-
} from "../../chunk-
|
|
11
|
+
} from "../../chunk-LROQXUFX.js";
|
|
12
12
|
import "../../chunk-L2SLFCXP.js";
|
|
13
13
|
import "../../chunk-BJXDHKUX.js";
|
|
14
14
|
import {
|
|
@@ -21,7 +21,7 @@ import "../../chunk-HLCJPRXP.js";
|
|
|
21
21
|
import {
|
|
22
22
|
CardHitLayer,
|
|
23
23
|
CardsStrip
|
|
24
|
-
} from "../../chunk-
|
|
24
|
+
} from "../../chunk-SR2C5SJJ.js";
|
|
25
25
|
import "../../chunk-JNUL3ZWK.js";
|
|
26
26
|
import "../../chunk-XXMHLZ3Y.js";
|
|
27
27
|
import {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"approval-batch-message.d.ts","sourceRoot":"","sources":["../../../src/components/chat/approval-batch-message.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,OAAO,CAAC;AAU5C,OAAO,KAAK,EACV,oBAAoB,EACpB,aAAa,EAEb,oBAAoB,EAErB,MAAM,SAAS,CAAC;AAGjB,MAAM,WAAW,yBAA0B,SAAQ,cAAc,CAAC,cAAc,CAAC;IAC/E,IAAI,EAAE,oBAAoB,CAAC,MAAM,CAAC,CAAC;IACnC,MAAM,CAAC,EAAE,oBAAoB,CAAC,QAAQ,CAAC,CAAC;IACxC,SAAS,CAAC,EAAE,CAAC,SAAS,CAAC,EAAE,MAAM,KAAK,IAAI,GAAG,OAAO,GAAG,OAAO,CAAC,IAAI,GAAG,OAAO,CAAC,CAAC;IAC7E,QAAQ,CAAC,EAAE,CAAC,SAAS,CAAC,EAAE,MAAM,KAAK,IAAI,GAAG,OAAO,GAAG,OAAO,CAAC,IAAI,GAAG,OAAO,CAAC,CAAC;IAC5E;;;;OAIG;IACH,aAAa,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IAChC,qGAAqG;IACrG,cAAc,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC/B;;;;OAIG;IACH,mBAAmB,CAAC,EAAE,OAAO,CAAC;IAC9B;;;;;OAKG;IACH,aAAa,CAAC,EAAE,aAAa,CAAC;IAC9B;;;;;;OAMG;IACH,OAAO,CAAC,EAAE,oBAAoB,CAAC;IAC/B;;;;OAIG;IACH,iBAAiB,CAAC,EAAE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