@flamingo-stack/openframe-frontend-core 0.0.782 → 0.0.783
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-QV4GHAWN.cjs → chunk-3PKORICR.cjs} +42 -42
- package/dist/{chunk-N7QNWHJA.cjs → chunk-62TMGBRO.cjs} +1 -1
- package/dist/{chunk-GFRKNUJZ.cjs → chunk-6NEWJ6I2.cjs} +13 -13
- package/dist/{chunk-YX7X5QQN.cjs → chunk-AFSVWR3X.cjs} +10 -10
- package/dist/{chunk-IZKEWQJN.cjs → chunk-APO7GMZQ.cjs} +2 -2
- package/dist/{chunk-I7LRZR4Q.cjs → chunk-BAJB3JF3.cjs} +3 -3
- package/dist/{chunk-JGKPEGZN.cjs → chunk-H3RHAN6B.cjs} +35 -35
- package/dist/{chunk-C5UUWXHE.cjs → chunk-KRXHRL3W.cjs} +41 -41
- package/dist/{chunk-2EXD2RSC.cjs → chunk-LGISRUGF.cjs} +2 -2
- package/dist/{chunk-VZUV2FCP.cjs → chunk-PQSTPJQQ.cjs} +2 -2
- package/dist/{chunk-C42BXIY7.cjs → chunk-RL45AU2C.cjs} +11 -11
- package/dist/{chunk-A4YUTS6Q.cjs → chunk-THOGSAFH.cjs} +78 -78
- package/dist/{chunk-MDGDL3C7.cjs → chunk-URFAMWCA.cjs} +5 -5
- package/dist/{chunk-7DKDVJMR.cjs → chunk-WHNI4QTG.cjs} +3 -3
- package/dist/{chunk-LTF6UDGO.cjs → chunk-WS7IDGEL.cjs} +4 -4
- package/dist/{chunk-VH3KQSI2.cjs → chunk-XKDJ5ISQ.cjs} +3 -3
- package/dist/{chunk-ISB7LW3D.cjs → chunk-YU23M33V.cjs} +28 -28
- package/dist/{cloud-tenants-LXKEG5N4.cjs → cloud-tenants-QYW3MPPP.cjs} +3 -3
- package/dist/components/case-studies/index.cjs +12 -12
- package/dist/components/chat/embeddable-chat.js +120 -98
- package/dist/components/chat/index.cjs +2 -2
- package/dist/components/contact/index.cjs +4 -4
- package/dist/components/docs/index.cjs +7 -7
- package/dist/components/embeds/index.cjs +4 -4
- package/dist/components/faq/index.cjs +5 -5
- package/dist/components/features/index.cjs +3 -3
- package/dist/components/help-center-pages/index.cjs +58 -58
- package/dist/components/index.cjs +33 -33
- package/dist/components/meeting-scheduler/index.cjs +26 -26
- package/dist/components/navigation/index.cjs +6 -6
- package/dist/components/onboarding-guides/index.cjs +5 -5
- package/dist/components/product-demo/index.cjs +12 -12
- package/dist/components/tickets/index.cjs +8 -8
- package/dist/components/ui/index.cjs +3 -3
- package/dist/{devices-PYJRYIQN.cjs → devices-DMMMEO2B.cjs} +4 -4
- package/dist/{embeddable-chat-7MSM62UC.cjs → embeddable-chat-OSSPL7L4.cjs} +120 -98
- package/dist/index.cjs +7 -7
- package/dist/{knowledge-R4H2ZDX2.cjs → knowledge-XQQXVV6C.cjs} +3 -3
- package/dist/{logs-YWL6NK24.cjs → logs-BHKMDCBP.cjs} +11 -11
- package/dist/{policies-3COFYSKB.cjs → policies-5IY7QUED.cjs} +7 -7
- package/dist/{scripts-72EJDICT.cjs → scripts-ZQXRBGVK.cjs} +8 -8
- package/dist/{software-update-PPUVCLPO.cjs → software-update-RGFRYL3N.cjs} +6 -6
- package/package.json +1 -1
- package/src/components/chat/embeddable-chat.tsx +21 -4
|
@@ -3,24 +3,24 @@
|
|
|
3
3
|
|
|
4
4
|
|
|
5
5
|
|
|
6
|
-
var
|
|
6
|
+
var _chunkWHNI4QTGcjs = require('./chunk-WHNI4QTG.cjs');
|
|
7
7
|
|
|
8
8
|
|
|
9
9
|
|
|
10
10
|
|
|
11
11
|
|
|
12
|
-
var
|
|
12
|
+
var _chunkLGISRUGFcjs = require('./chunk-LGISRUGF.cjs');
|
|
13
13
|
|
|
14
14
|
|
|
15
15
|
|
|
16
|
-
var
|
|
16
|
+
var _chunkPQSTPJQQcjs = require('./chunk-PQSTPJQQ.cjs');
|
|
17
17
|
|
|
18
18
|
|
|
19
19
|
|
|
20
20
|
|
|
21
21
|
|
|
22
22
|
|
|
23
|
-
var
|
|
23
|
+
var _chunkTHOGSAFHcjs = require('./chunk-THOGSAFH.cjs');
|
|
24
24
|
|
|
25
25
|
|
|
26
26
|
var _chunkTS6TISIFcjs = require('./chunk-TS6TISIF.cjs');
|
|
@@ -29,7 +29,7 @@ var _chunkTS6TISIFcjs = require('./chunk-TS6TISIF.cjs');
|
|
|
29
29
|
|
|
30
30
|
|
|
31
31
|
|
|
32
|
-
var
|
|
32
|
+
var _chunk62TMGBROcjs = require('./chunk-62TMGBRO.cjs');
|
|
33
33
|
|
|
34
34
|
|
|
35
35
|
|
|
@@ -354,13 +354,13 @@ function toDocContent(value, requestedPath) {
|
|
|
354
354
|
function toDataSync(value) {
|
|
355
355
|
if (!isRecord(value)) return void 0;
|
|
356
356
|
const source = readString(value, "source");
|
|
357
|
-
if (!
|
|
357
|
+
if (!_chunkTHOGSAFHcjs.isDataSyncSource.call(void 0, source)) return void 0;
|
|
358
358
|
return { source, syncedAt: _nullishCoalesce(readString(value, "syncedAt"), () => ( null)) };
|
|
359
359
|
}
|
|
360
360
|
function useDocumentTree(config, initialPath) {
|
|
361
361
|
const { structureEndpoint, contentEndpoint, baseRoute } = config;
|
|
362
|
-
const folderIndexFile = _nullishCoalesce(config.folderIndexFile, () => (
|
|
363
|
-
const cleanInitialPath =
|
|
362
|
+
const folderIndexFile = _nullishCoalesce(config.folderIndexFile, () => ( _chunk62TMGBROcjs.DEFAULT_FOLDER_INDEX_FILE));
|
|
363
|
+
const cleanInitialPath = _chunk62TMGBROcjs.stripFolderIndexFromPath.call(void 0, _optionalChain([initialPath, 'optionalAccess', _4 => _4.replace, 'call', _5 => _5(/\/$/, "")]) || "", folderIndexFile);
|
|
364
364
|
const [structure, setStructure] = _react.useState.call(void 0, []);
|
|
365
365
|
const [selectedPath, setSelectedPath] = _react.useState.call(void 0, cleanInitialPath);
|
|
366
366
|
const [content, setContent] = _react.useState.call(void 0, null);
|
|
@@ -386,12 +386,12 @@ function useDocumentTree(config, initialPath) {
|
|
|
386
386
|
} else if (pathname.startsWith(`${normalizedBaseRoute}/`)) {
|
|
387
387
|
pathFromUrl = pathname.substring(`${normalizedBaseRoute}/`.length);
|
|
388
388
|
}
|
|
389
|
-
pathFromUrl =
|
|
389
|
+
pathFromUrl = _chunk62TMGBROcjs.stripFolderIndexFromPath.call(void 0, pathFromUrl, folderIndexFile);
|
|
390
390
|
if (pathFromUrl !== selectedPathRef.current) {
|
|
391
391
|
setSelectedPath(pathFromUrl);
|
|
392
392
|
if (pathFromUrl) {
|
|
393
393
|
const parentPath = pathFromUrl.includes("/") ? pathFromUrl.substring(0, pathFromUrl.lastIndexOf("/")) : pathFromUrl;
|
|
394
|
-
setExpandedNodes(new Set(
|
|
394
|
+
setExpandedNodes(new Set(_chunk62TMGBROcjs.getDocAncestorNodeIds.call(void 0, parentPath)));
|
|
395
395
|
}
|
|
396
396
|
setTimeout(() => {
|
|
397
397
|
scrollToContent();
|
|
@@ -409,7 +409,7 @@ function useDocumentTree(config, initialPath) {
|
|
|
409
409
|
setSelectedPath(cleanInitialPath);
|
|
410
410
|
if (cleanInitialPath) {
|
|
411
411
|
const parentPath = cleanInitialPath.includes("/") ? cleanInitialPath.substring(0, cleanInitialPath.lastIndexOf("/")) : cleanInitialPath;
|
|
412
|
-
setExpandedNodes(new Set(
|
|
412
|
+
setExpandedNodes(new Set(_chunk62TMGBROcjs.getDocAncestorNodeIds.call(void 0, parentPath)));
|
|
413
413
|
}
|
|
414
414
|
setExternalNavCount((n) => n + 1);
|
|
415
415
|
}
|
|
@@ -434,7 +434,7 @@ function useDocumentTree(config, initialPath) {
|
|
|
434
434
|
if (cleanInitialPath) {
|
|
435
435
|
const pathForExpansion = cleanInitialPath.includes(".") ? cleanInitialPath.substring(0, cleanInitialPath.lastIndexOf("/")) : cleanInitialPath;
|
|
436
436
|
if (pathForExpansion) {
|
|
437
|
-
setExpandedNodes(new Set(
|
|
437
|
+
setExpandedNodes(new Set(_chunk62TMGBROcjs.getDocAncestorNodeIds.call(void 0, pathForExpansion)));
|
|
438
438
|
}
|
|
439
439
|
} else if (nodes.length > 0) {
|
|
440
440
|
const hasRootReadme = nodes.some((node) => node.type === "file" && node.path === folderIndexFile);
|
|
@@ -474,7 +474,7 @@ function useDocumentTree(config, initialPath) {
|
|
|
474
474
|
setContent(null);
|
|
475
475
|
return;
|
|
476
476
|
}
|
|
477
|
-
const probe =
|
|
477
|
+
const probe = _chunk62TMGBROcjs.findDocNodeByPath.call(void 0, _chunk62TMGBROcjs.stripFolderIndexFromPath.call(void 0, path, folderIndexFile), structure);
|
|
478
478
|
const probeIsNoReadmeFolder = !!probe && probe.type === "folder" && !probe.hasReadme;
|
|
479
479
|
const preStructureFolderLike = structure.length === 0 && !path.endsWith(".md");
|
|
480
480
|
if (probeIsNoReadmeFolder || preStructureFolderLike) {
|
|
@@ -533,7 +533,7 @@ function useDocumentTree(config, initialPath) {
|
|
|
533
533
|
if (selectedPath === "") {
|
|
534
534
|
pathToFetch = folderIndexFile;
|
|
535
535
|
} else {
|
|
536
|
-
const node =
|
|
536
|
+
const node = _chunk62TMGBROcjs.findDocNodeByPath.call(void 0, selectedPath, structure);
|
|
537
537
|
if (node && node.type === "folder" && !node.hasReadme) {
|
|
538
538
|
const firstDocPath = findFirstDocPath(node);
|
|
539
539
|
if (!firstDocPath) {
|
|
@@ -574,16 +574,16 @@ function useDocumentTree(config, initialPath) {
|
|
|
574
574
|
if (node.type === "folder") {
|
|
575
575
|
setExpandedNodes((prev) => {
|
|
576
576
|
if (prev.has(node.id)) {
|
|
577
|
-
const ancestorIds =
|
|
577
|
+
const ancestorIds = _chunk62TMGBROcjs.getDocAncestorNodeIds.call(void 0, node.path);
|
|
578
578
|
ancestorIds.pop();
|
|
579
579
|
return new Set(ancestorIds);
|
|
580
580
|
}
|
|
581
|
-
return new Set(
|
|
581
|
+
return new Set(_chunk62TMGBROcjs.getDocAncestorNodeIds.call(void 0, node.path));
|
|
582
582
|
});
|
|
583
583
|
} else {
|
|
584
584
|
const lastSlash = node.path.lastIndexOf("/");
|
|
585
585
|
if (lastSlash > 0) {
|
|
586
|
-
setExpandedNodes(new Set(
|
|
586
|
+
setExpandedNodes(new Set(_chunk62TMGBROcjs.getDocAncestorNodeIds.call(void 0, node.path.substring(0, lastSlash))));
|
|
587
587
|
}
|
|
588
588
|
}
|
|
589
589
|
lastFetchedPath.current = null;
|
|
@@ -598,7 +598,7 @@ function useDocumentTree(config, initialPath) {
|
|
|
598
598
|
const hashIndex = path.indexOf("#");
|
|
599
599
|
const anchor = hashIndex !== -1 ? path.substring(hashIndex) : "";
|
|
600
600
|
const cleanPath = path.replace(/\/$/, "").split("#")[0];
|
|
601
|
-
const pathForSelection = anchor && _optionalChain([options, 'optionalAccess', _6 => _6.fromInternalLink]) && cleanPath === "" ? selectedPathRef.current :
|
|
601
|
+
const pathForSelection = anchor && _optionalChain([options, 'optionalAccess', _6 => _6.fromInternalLink]) && cleanPath === "" ? selectedPathRef.current : _chunk62TMGBROcjs.stripFolderIndexFromPath.call(void 0, cleanPath, folderIndexFile);
|
|
602
602
|
if (anchor && _optionalChain([options, 'optionalAccess', _7 => _7.fromInternalLink]) && pathForSelection === selectedPathRef.current) {
|
|
603
603
|
_chunkOJZBZH56cjs.navigateSamePageHash.call(void 0, anchor, { headerOffset: _chunkOJZBZH56cjs.HUB_HEADER_OFFSET_PX });
|
|
604
604
|
return;
|
|
@@ -662,15 +662,15 @@ function useDocumentTree(config, initialPath) {
|
|
|
662
662
|
return docNavigation.register({
|
|
663
663
|
baseRoute: normalizedBaseRoute,
|
|
664
664
|
findNodeByPath: (path) => {
|
|
665
|
-
const clean =
|
|
666
|
-
return _nullishCoalesce(
|
|
665
|
+
const clean = _chunk62TMGBROcjs.stripFolderIndexFromPath.call(void 0, path.replace(/\/$/, "").split("#")[0], folderIndexFile);
|
|
666
|
+
return _nullishCoalesce(_chunk62TMGBROcjs.findDocNodeByPath.call(void 0, clean, structure), () => ( null));
|
|
667
667
|
},
|
|
668
668
|
selectNode
|
|
669
669
|
});
|
|
670
670
|
}, [docNavigation, normalizedBaseRoute, structure, selectNode, folderIndexFile]);
|
|
671
671
|
const isEmptyFolder = _react.useMemo.call(void 0, () => {
|
|
672
672
|
if (!selectedPath || structure.length === 0) return false;
|
|
673
|
-
const node =
|
|
673
|
+
const node = _chunk62TMGBROcjs.findDocNodeByPath.call(void 0, selectedPath, structure);
|
|
674
674
|
return !!node && node.type === "folder" && !node.hasReadme && !findFirstDocPath(node);
|
|
675
675
|
}, [selectedPath, structure]);
|
|
676
676
|
return {
|
|
@@ -753,14 +753,14 @@ function DocViewerContent({
|
|
|
753
753
|
},
|
|
754
754
|
docPath
|
|
755
755
|
);
|
|
756
|
-
const { activeSection, handleSectionClick } =
|
|
756
|
+
const { activeSection, handleSectionClick } = _chunkLGISRUGFcjs.useScrollSpy.call(void 0, _optionalChain([content, 'optionalAccess', _11 => _11.sections]));
|
|
757
757
|
const docNav = useDocNavigation();
|
|
758
758
|
const router = _chunk7DNL734Scjs.useRouter.call(void 0, );
|
|
759
759
|
const backCfg = backButton === false ? null : {
|
|
760
760
|
label: _nullishCoalesce(_optionalChain([backButton, 'optionalAccess', _12 => _12.label]), () => ( "Back to home")),
|
|
761
761
|
onClick: () => router.push(_nullishCoalesce(_optionalChain([backButton, 'optionalAccess', _13 => _13.href]), () => ( "/")))
|
|
762
762
|
};
|
|
763
|
-
const docSearch =
|
|
763
|
+
const docSearch = _chunkPQSTPJQQcjs.useDocSearch.call(void 0, {
|
|
764
764
|
source: chatSource,
|
|
765
765
|
baseRoute,
|
|
766
766
|
searchEndpoint,
|
|
@@ -784,7 +784,7 @@ function DocViewerContent({
|
|
|
784
784
|
onResolveLink: resolveLink
|
|
785
785
|
});
|
|
786
786
|
}, [content, renderContent, navigateToDoc, sourceId, resolveLink]);
|
|
787
|
-
const selectedNodeDocType = selectedPath && structure.length > 0 ? _optionalChain([
|
|
787
|
+
const selectedNodeDocType = selectedPath && structure.length > 0 ? _optionalChain([_chunk62TMGBROcjs.findDocNodeByPath.call(void 0, selectedPath, structure), 'optionalAccess', _14 => _14.documentType]) : void 0;
|
|
788
788
|
const activeDocType = _nullishCoalesce(_optionalChain([content, 'optionalAccess', _15 => _15.documentType]), () => ( selectedNodeDocType));
|
|
789
789
|
const isMarkdownContent = !activeDocType || activeDocType === "markdown";
|
|
790
790
|
const showStickyNav = isMarkdownContent;
|
|
@@ -796,9 +796,9 @@ function DocViewerContent({
|
|
|
796
796
|
const defaultEmptyText = structure.length > 0 ? "Select a document from the sidebar to view" : "No documents yet. Add content from the admin panel.";
|
|
797
797
|
const resolvedEmptyText = emptyStateText || defaultEmptyText;
|
|
798
798
|
const inner = /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { style: { ...bgStyle, ...containerBgStyle }, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkTS6TISIFcjs.PageLayout, { title, subtitle, titleSize: "h1", titleWrap: true, backButton: _nullishCoalesce(backCfg, () => ( void 0)), children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex w-full flex-col gap-10", children: [
|
|
799
|
-
synced && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
799
|
+
synced && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkTHOGSAFHcjs.DataSyncLine, { sync: _optionalChain([content, 'optionalAccess', _19 => _19.sync]), loading: !content && (isLoadingContent || isLoadingStructure) }),
|
|
800
800
|
showAIChat && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
801
|
-
|
|
801
|
+
_chunkPQSTPJQQcjs.DocSearchBar,
|
|
802
802
|
{
|
|
803
803
|
placeholder: `Search ${_optionalChain([sidebarLabel, 'optionalAccess', _20 => _20.toLowerCase, 'call', _21 => _21()]) || "documents"}...`,
|
|
804
804
|
query: docSearch.query,
|
|
@@ -819,7 +819,7 @@ function DocViewerContent({
|
|
|
819
819
|
!error && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex flex-1 flex-col items-start gap-6 content-lg:flex-row content-lg:gap-10", children: [
|
|
820
820
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "w-full content-lg:w-[320px] content-lg:shrink-0", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "content-lg:sticky content-lg:top-20", children: [
|
|
821
821
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, PersistentMobileDropdown, { isLoading: false, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
822
|
-
|
|
822
|
+
_chunkLGISRUGFcjs.MobileNavigationDropdown,
|
|
823
823
|
{
|
|
824
824
|
nodes: structure,
|
|
825
825
|
selectedPath,
|
|
@@ -833,7 +833,7 @@ function DocViewerContent({
|
|
|
833
833
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, PersistentSidebar, { isLoading: false, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "hidden content-lg:block", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-4", children: [
|
|
834
834
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "h3", { className: "font-semibold text-ods-text-secondary text-h5", children: sidebarLabel }),
|
|
835
835
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
836
|
-
|
|
836
|
+
_chunkLGISRUGFcjs.MultiLevelNavigation,
|
|
837
837
|
{
|
|
838
838
|
nodes: structure,
|
|
839
839
|
selectedPath,
|
|
@@ -872,7 +872,7 @@ function DocViewerContent({
|
|
|
872
872
|
showStickyNav && content && stickyNavSections.length > 0 && !isLoadingContent && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "hidden content-lg:block", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "sticky top-24", children: [
|
|
873
873
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "h3", { className: ON_THIS_PAGE_HEADING_CLASS, children: ON_THIS_PAGE_LABEL }),
|
|
874
874
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
875
|
-
|
|
875
|
+
_chunkLGISRUGFcjs.StickySectionNav,
|
|
876
876
|
{
|
|
877
877
|
sections: stickyNavSections,
|
|
878
878
|
activeSection,
|
|
@@ -887,7 +887,7 @@ function DocViewerContent({
|
|
|
887
887
|
) })
|
|
888
888
|
] })
|
|
889
889
|
] }) }) });
|
|
890
|
-
return shell ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
890
|
+
return shell ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkTHOGSAFHcjs.PageShell, { contentClassName: `${bgClass} ${className}`, children: inner }) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: `page-shell-content ${bgClass} ${className}`.trim(), children: inner });
|
|
891
891
|
}
|
|
892
892
|
|
|
893
893
|
// src/components/docs/skeletons.tsx
|
|
@@ -949,7 +949,7 @@ function EmbedSkeleton({ documentType, region = true } = {}) {
|
|
|
949
949
|
] }),
|
|
950
950
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "flex w-full items-center gap-2 content-sm:w-auto", children: Array.from({ length: buttonCount }).map((_, i) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkNNNRN4OFcjs.UnifiedSkeleton, { className: "h-10 w-full flex-1 rounded content-sm:w-32 content-sm:flex-initial" }, i)) })
|
|
951
951
|
] }),
|
|
952
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
952
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkTHOGSAFHcjs.EmbedLoadingSkeleton, { region: false })
|
|
953
953
|
] });
|
|
954
954
|
}
|
|
955
955
|
|
|
@@ -957,11 +957,11 @@ function EmbedSkeleton({ documentType, region = true } = {}) {
|
|
|
957
957
|
|
|
958
958
|
var DEFAULT_TITLE = "Documents";
|
|
959
959
|
var defaultFallbackRenderer = () => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "py-16 text-center", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-ods-text-secondary", children: "Unsupported document type" }) });
|
|
960
|
-
var defaultPdfRenderer = (content, handlers) => content.fileUrl ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
961
|
-
var defaultGoogleSheetRenderer = (content, handlers) => content.externalUrl ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
962
|
-
var defaultFigmaRenderer = (content, handlers) => content.externalUrl ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
960
|
+
var defaultPdfRenderer = (content, handlers) => content.fileUrl ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkWHNI4QTGcjs.PdfViewer, { src: content.fileUrl, fileName: content.fileName }) : defaultFallbackRenderer(content, handlers);
|
|
961
|
+
var defaultGoogleSheetRenderer = (content, handlers) => content.externalUrl ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkWHNI4QTGcjs.GoogleSheetsViewer, { externalUrl: content.externalUrl, fileName: content.fileName }) : defaultFallbackRenderer(content, handlers);
|
|
962
|
+
var defaultFigmaRenderer = (content, handlers) => content.externalUrl ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkTHOGSAFHcjs.FigmaEmbed, { url: content.externalUrl, title: content.fileName, loading: "eager" }) : defaultFallbackRenderer(content, handlers);
|
|
963
963
|
var defaultFileRenderer = (content) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
964
|
-
|
|
964
|
+
_chunkWHNI4QTGcjs.FileDownloadCard,
|
|
965
965
|
{
|
|
966
966
|
fileName: content.fileName,
|
|
967
967
|
mimeType: content.mimeType,
|
|
@@ -1,21 +1,21 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { newObj[key] = obj[key]; } } } newObj.default = obj; return newObj; } } 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 _chunkURFAMWCAcjs = require('./chunk-URFAMWCA.cjs');
|
|
5
5
|
|
|
6
6
|
|
|
7
7
|
|
|
8
8
|
|
|
9
9
|
|
|
10
10
|
|
|
11
|
-
var
|
|
11
|
+
var _chunkAFSVWR3Xcjs = require('./chunk-AFSVWR3X.cjs');
|
|
12
12
|
|
|
13
13
|
|
|
14
14
|
|
|
15
15
|
var _chunkYXZOP726cjs = require('./chunk-YXZOP726.cjs');
|
|
16
16
|
|
|
17
17
|
|
|
18
|
-
var
|
|
18
|
+
var _chunkAPO7GMZQcjs = require('./chunk-APO7GMZQ.cjs');
|
|
19
19
|
|
|
20
20
|
|
|
21
21
|
|
|
@@ -28,7 +28,7 @@ var _chunkIZKEWQJNcjs = require('./chunk-IZKEWQJN.cjs');
|
|
|
28
28
|
|
|
29
29
|
|
|
30
30
|
|
|
31
|
-
var
|
|
31
|
+
var _chunkTHOGSAFHcjs = require('./chunk-THOGSAFH.cjs');
|
|
32
32
|
|
|
33
33
|
|
|
34
34
|
|
|
@@ -40,7 +40,7 @@ var _chunkCBKXU77Hcjs = require('./chunk-CBKXU77H.cjs');
|
|
|
40
40
|
|
|
41
41
|
|
|
42
42
|
|
|
43
|
-
var
|
|
43
|
+
var _chunk62TMGBROcjs = require('./chunk-62TMGBRO.cjs');
|
|
44
44
|
|
|
45
45
|
|
|
46
46
|
|
|
@@ -153,7 +153,7 @@ var TicketActionFailure = class extends Error {
|
|
|
153
153
|
function useTicketActions(options) {
|
|
154
154
|
const queryClient = _reactquery.useQueryClient.call(void 0, );
|
|
155
155
|
const ticketActionEndpoint = _nullishCoalesce(_chunkUJ7AXHRZcjs.useRequiredChatRuntime.call(void 0, ).endpoints.ticketActionUrl, () => ( TICKET_ACTION_ENDPOINT));
|
|
156
|
-
const ticketLive =
|
|
156
|
+
const ticketLive = _chunkAPO7GMZQcjs.useOptionalTicketLive.call(void 0, );
|
|
157
157
|
const notifyTicketCreated = _optionalChain([ticketLive, 'optionalAccess', _ => _.notifyTicketCreated]);
|
|
158
158
|
const { prependOptimistic, removeOptimistic, removeTicketFromCache, toast: toast2, onSupportSystemDown } = options;
|
|
159
159
|
const formInFlightRef = _react.useRef.call(void 0, null);
|
|
@@ -666,7 +666,7 @@ function TicketOpenForm({ onSubmit, isSubmitting, supportSystemDown }) {
|
|
|
666
666
|
clear();
|
|
667
667
|
}
|
|
668
668
|
};
|
|
669
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkODDUGLYFcjs.Card, { className: "p-6", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "form", { onSubmit: handleSubmit, className: "flex flex-col gap-6 md:flex-row", ...
|
|
669
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkODDUGLYFcjs.Card, { className: "p-6", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "form", { onSubmit: handleSubmit, className: "flex flex-col gap-6 md:flex-row", ..._chunk62TMGBROcjs.HUBSPOT_DO_NOT_COLLECT_FORM_PROPS, children: [
|
|
670
670
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "min-w-0 flex-1 md:max-w-md", children: [
|
|
671
671
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "h2", { className: "mb-2 text-ods-text-primary text-h2", children: "Need Support?" }),
|
|
672
672
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-ods-text-secondary text-h6", children: "Can't find what you're looking for? Submit a support ticket below \u2014 we'll follow up shortly." }),
|
|
@@ -691,7 +691,7 @@ function TicketOpenForm({ onSubmit, isSubmitting, supportSystemDown }) {
|
|
|
691
691
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { children: [
|
|
692
692
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkOMTH355Icjs.Label, { htmlFor: "ticket-content", className: "mb-1", children: "Your Message" }),
|
|
693
693
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
694
|
-
|
|
694
|
+
_chunkTHOGSAFHcjs.Textarea,
|
|
695
695
|
{
|
|
696
696
|
id: "ticket-content",
|
|
697
697
|
placeholder: "Describe your issue or question in detail...",
|
|
@@ -821,7 +821,7 @@ function TicketLinkedDeliveryCard({ clickup, className }) {
|
|
|
821
821
|
dateClosed: clickup.date_closed,
|
|
822
822
|
clickupUrl: _nullishCoalesce(clickup.clickup_url, () => ( ""))
|
|
823
823
|
};
|
|
824
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: `${_chunkODDUGLYFcjs.CONTENT_CARD_SKELETON_FRAME_CLASS} ${_nullishCoalesce(className, () => ( ""))}`, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
824
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: `${_chunkODDUGLYFcjs.CONTENT_CARD_SKELETON_FRAME_CLASS} ${_nullishCoalesce(className, () => ( ""))}`, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkAFSVWR3Xcjs.DeliveryRow, { item, href: clickup.delivery_href, caption: "Linked delivery" }) });
|
|
825
825
|
}
|
|
826
826
|
|
|
827
827
|
// src/components/tickets/ticket-reply-composer.tsx
|
|
@@ -903,13 +903,13 @@ function TicketReplyComposer({
|
|
|
903
903
|
}
|
|
904
904
|
)
|
|
905
905
|
] }),
|
|
906
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
907
|
-
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
|
|
908
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
909
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
906
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkTHOGSAFHcjs.AlertDialog, { open: closeDialogOpen, onOpenChange: setCloseDialogOpen, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkTHOGSAFHcjs.AlertDialogContent, { className: "border-ods-border bg-ods-card", children: [
|
|
907
|
+
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkTHOGSAFHcjs.AlertDialogHeader, { children: [
|
|
908
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkTHOGSAFHcjs.AlertDialogTitle, { className: "text-ods-text-primary", children: "Close this ticket?" }),
|
|
909
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkTHOGSAFHcjs.AlertDialogDescription, { className: "text-ods-text-secondary", children: "Add an optional resolution note below. You can reopen the ticket later if needed." })
|
|
910
910
|
] }),
|
|
911
911
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
912
|
-
|
|
912
|
+
_chunkTHOGSAFHcjs.Textarea,
|
|
913
913
|
{
|
|
914
914
|
value: resolution,
|
|
915
915
|
onChange: (e) => setResolution(e.target.value),
|
|
@@ -919,9 +919,9 @@ function TicketReplyComposer({
|
|
|
919
919
|
className: "mt-2"
|
|
920
920
|
}
|
|
921
921
|
),
|
|
922
|
-
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
|
|
922
|
+
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkTHOGSAFHcjs.AlertDialogFooter, { children: [
|
|
923
923
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
924
|
-
|
|
924
|
+
_chunkTHOGSAFHcjs.AlertDialogCancel,
|
|
925
925
|
{
|
|
926
926
|
disabled: busy,
|
|
927
927
|
className: "border-ods-border bg-transparent text-ods-text-primary hover:bg-ods-border",
|
|
@@ -929,7 +929,7 @@ function TicketReplyComposer({
|
|
|
929
929
|
}
|
|
930
930
|
),
|
|
931
931
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
932
|
-
|
|
932
|
+
_chunkTHOGSAFHcjs.AlertDialogAction,
|
|
933
933
|
{
|
|
934
934
|
onClick: () => void confirmClose(),
|
|
935
935
|
disabled: busy,
|
|
@@ -994,7 +994,7 @@ function TicketTimelinePanel({ ticket }) {
|
|
|
994
994
|
const identity = _chunk7OJMOG34cjs.useChatIdentity.call(void 0, );
|
|
995
995
|
const externalId = isOptimistic(ticket) ? null : ticket.external_id;
|
|
996
996
|
const { engagements, isLoading } = useTicketEngagements(externalId, !!externalId);
|
|
997
|
-
const live =
|
|
997
|
+
const live = _chunkAPO7GMZQcjs.useOptionalTicketLive.call(void 0, );
|
|
998
998
|
const setOpenTicketId = _optionalChain([live, 'optionalAccess', _25 => _25.setOpenTicketId]);
|
|
999
999
|
const markRead = _optionalChain([live, 'optionalAccess', _26 => _26.markRead]);
|
|
1000
1000
|
const markReadDebounceRef = _react.useRef.call(void 0, null);
|
|
@@ -1033,7 +1033,7 @@ function TicketTimelinePanel({ ticket }) {
|
|
|
1033
1033
|
const customerName = (isViewerTheCustomer ? viewerName : null) || ticketCustomerName || viewerName || _optionalChain([identity, 'access', _40 => _40.user, 'optionalAccess', _41 => _41.email]) || "You";
|
|
1034
1034
|
const customerAvatar = isViewerTheCustomer ? _nullishCoalesce(_optionalChain([identity, 'access', _42 => _42.user, 'optionalAccess', _43 => _43.avatarUrl]), () => ( void 0)) : void 0;
|
|
1035
1035
|
if (isLoading) {
|
|
1036
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: `${TICKET_FEED_FRAME} ${TICKET_FEED_HEIGHT}`, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkA3UZFFR3cjs.LoadingRegion, { label: "Loading messages", className: TICKET_FEED_INNER, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkMGEUZRNQcjs.LoadingItems, { count: TICKET_FEED_SKELETON_ROWS, children: () => /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1036
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: `${TICKET_FEED_FRAME} ${TICKET_FEED_HEIGHT}`, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkA3UZFFR3cjs.LoadingRegion, { label: "Loading messages", className: TICKET_FEED_INNER, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkMGEUZRNQcjs.LoadingItems, { count: TICKET_FEED_SKELETON_ROWS, children: () => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk62TMGBROcjs.ChatMessageRow, { loading: true, displayName: "", body: "", "data-loading-item": true }) }) }) });
|
|
1037
1037
|
}
|
|
1038
1038
|
if (bodyTurns.length === 0 && engagements.length === 0) {
|
|
1039
1039
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
@@ -1052,7 +1052,7 @@ function TicketTimelinePanel({ ticket }) {
|
|
|
1052
1052
|
const isResolution = turn.startsWith("[Resolution]");
|
|
1053
1053
|
const text = isResolution ? turn.replace(/^\[Resolution\]\s*/, "") : turn;
|
|
1054
1054
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1055
|
-
|
|
1055
|
+
_chunk62TMGBROcjs.ChatMessageRow,
|
|
1056
1056
|
{
|
|
1057
1057
|
"data-loading-item": true,
|
|
1058
1058
|
displayName: customerName,
|
|
@@ -1082,14 +1082,14 @@ function TicketTimelinePanel({ ticket }) {
|
|
|
1082
1082
|
}
|
|
1083
1083
|
const engAttachments = mapEngagementAttachments(eng.attachments);
|
|
1084
1084
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1085
|
-
|
|
1085
|
+
_chunk62TMGBROcjs.ChatMessageRow,
|
|
1086
1086
|
{
|
|
1087
1087
|
"data-loading-item": true,
|
|
1088
1088
|
displayName: author,
|
|
1089
1089
|
avatarUrl: avatarSrc,
|
|
1090
1090
|
timeLabel: eng.createdAt ? _chunkBE4OUWTAcjs.formatRelativeTime.call(void 0, eng.createdAt) : null,
|
|
1091
1091
|
body: stripAttachmentsPreamble(_nullishCoalesce(eng.body, () => ( ""))),
|
|
1092
|
-
footer: engAttachments.length > 0 ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "mt-2", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1092
|
+
footer: engAttachments.length > 0 ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "mt-2", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkTHOGSAFHcjs.TicketAttachmentsList, { attachments: engAttachments, size: "compact" }) }) : null
|
|
1093
1093
|
},
|
|
1094
1094
|
eng.id
|
|
1095
1095
|
);
|
|
@@ -1194,7 +1194,7 @@ var TICKET_ROW_FRAME_CLASS = "border-b border-ods-border last:border-b-0";
|
|
|
1194
1194
|
var TICKET_ROW_OUTER_CLASS = "scroll-mt-24";
|
|
1195
1195
|
function TicketRow(props) {
|
|
1196
1196
|
if (_chunkMGEUZRNQcjs.useLoadingScope.call(void 0, ) || props.loading) {
|
|
1197
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { id: props.id, className: TICKET_ROW_OUTER_CLASS, ..._chunkMGEUZRNQcjs.loadingItemProps.call(void 0, props), children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: TICKET_ROW_FRAME_CLASS, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1197
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { id: props.id, className: TICKET_ROW_OUTER_CLASS, ..._chunkMGEUZRNQcjs.loadingItemProps.call(void 0, props), children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: TICKET_ROW_FRAME_CLASS, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk62TMGBROcjs.ChatTicketItem, { loading: true }) }) });
|
|
1198
1198
|
}
|
|
1199
1199
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, TicketRowLoaded, { ...props });
|
|
1200
1200
|
}
|
|
@@ -1249,7 +1249,7 @@ function TicketRowLoaded({
|
|
|
1249
1249
|
};
|
|
1250
1250
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { ref: rowRef, id, className: TICKET_ROW_OUTER_CLASS, ..._chunkMGEUZRNQcjs.loadingItemProps.call(void 0, markers), children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, Collapsible, { open: expanded && !optimistic, className: TICKET_ROW_FRAME_CLASS, children: [
|
|
1251
1251
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1252
|
-
|
|
1252
|
+
_chunk62TMGBROcjs.ChatTicketItem,
|
|
1253
1253
|
{
|
|
1254
1254
|
ticket: tileData,
|
|
1255
1255
|
onClick: optimistic ? void 0 : handleClick,
|
|
@@ -1343,7 +1343,7 @@ function TicketCenterAuthed({
|
|
|
1343
1343
|
const toggleRow = _react.useCallback.call(void 0, (id) => {
|
|
1344
1344
|
setExpandedTicketId((prev) => prev === id ? null : id);
|
|
1345
1345
|
}, []);
|
|
1346
|
-
const syncInPage =
|
|
1346
|
+
const syncInPage = _chunkAFSVWR3Xcjs.usePageDataSync.call(void 0, sync, isLoading);
|
|
1347
1347
|
const merged = [...optimisticTickets, ...tickets];
|
|
1348
1348
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1349
1349
|
TicketCenterView,
|
|
@@ -1360,7 +1360,7 @@ function TicketCenterAuthed({
|
|
|
1360
1360
|
TicketRow,
|
|
1361
1361
|
{
|
|
1362
1362
|
"data-loading-item": true,
|
|
1363
|
-
id:
|
|
1363
|
+
id: _chunk62TMGBROcjs.devSectionAnchorId.call(void 0, "ticket", ticket.external_id),
|
|
1364
1364
|
ticket,
|
|
1365
1365
|
expanded: expandedTicketId === ticket.id,
|
|
1366
1366
|
onToggle: toggleRow,
|
|
@@ -1379,7 +1379,7 @@ function TicketCenterAuthed({
|
|
|
1379
1379
|
function TicketCenterPending({
|
|
1380
1380
|
region = true
|
|
1381
1381
|
} = {}) {
|
|
1382
|
-
const syncInPage =
|
|
1382
|
+
const syncInPage = _chunkAFSVWR3Xcjs.usePageDataSync.call(void 0, null, true);
|
|
1383
1383
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk7OJMOG34cjs.LoadingFallback, { label: "Loading tickets", status: region, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1384
1384
|
TicketCenterView,
|
|
1385
1385
|
{
|
|
@@ -1442,7 +1442,7 @@ function TicketListHeader({
|
|
|
1442
1442
|
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex items-center justify-between gap-3", children: [
|
|
1443
1443
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-ods-text-secondary text-h5", children: "Your Current Tickets" }),
|
|
1444
1444
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex items-center gap-3 text-ods-text-secondary text-h6", children: [
|
|
1445
|
-
sync !== void 0 && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1445
|
+
sync !== void 0 && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkTHOGSAFHcjs.DataSyncLine, { sync, loading: syncLoading, inline: true }),
|
|
1446
1446
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { inert: !onRefresh || void 0, "aria-hidden": !onRefresh || void 0, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1447
1447
|
_chunkFLS6DZENcjs.Button,
|
|
1448
1448
|
{
|
|
@@ -1477,7 +1477,7 @@ function HelpCenterCard(props) {
|
|
|
1477
1477
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, HelpCenterCardLoaded, { ...props });
|
|
1478
1478
|
}
|
|
1479
1479
|
function HelpCenterCardSkeleton({ id, ...props }) {
|
|
1480
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { id, className: HELP_CENTER_ROW_CLASS, "aria-hidden": true, ..._chunkMGEUZRNQcjs.loadingItemProps.call(void 0, props), children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: HELP_CENTER_SUMMARY_PAD_CLASS, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1480
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { id, className: HELP_CENTER_ROW_CLASS, "aria-hidden": true, ..._chunkMGEUZRNQcjs.loadingItemProps.call(void 0, props), children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: HELP_CENTER_SUMMARY_PAD_CLASS, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkAFSVWR3Xcjs.DevCardRowContent, { loading: true, title: "", subtitle: "", description: "", rightBadges: null }) }) });
|
|
1481
1481
|
}
|
|
1482
1482
|
function HelpCenterCardLoaded({
|
|
1483
1483
|
ticket,
|
|
@@ -1516,7 +1516,7 @@ function HelpCenterCardLoaded({
|
|
|
1516
1516
|
});
|
|
1517
1517
|
return () => cancelAnimationFrame(raf);
|
|
1518
1518
|
}, [isExpanded]);
|
|
1519
|
-
const live =
|
|
1519
|
+
const live = _chunkAPO7GMZQcjs.useOptionalTicketLive.call(void 0, );
|
|
1520
1520
|
const unreadCount = !optimistic && ticket.external_id && _optionalChain([live, 'optionalAccess', _64 => _64.unreadByTicket, 'access', _65 => _65[ticket.external_id]]) || 0;
|
|
1521
1521
|
const rightBadges = /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
|
|
1522
1522
|
unreadCount > 0 && // Only rows with unread replies carry it; the row's loading form draws the status badge alone.
|
|
@@ -1571,7 +1571,7 @@ function HelpCenterCardLoaded({
|
|
|
1571
1571
|
"aria-expanded": isExpandable ? isExpanded : void 0,
|
|
1572
1572
|
"aria-controls": isExpanded ? `help-center-drawer-${ticket.id}` : void 0,
|
|
1573
1573
|
children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: _chunkMGEUZRNQcjs.cn.call(void 0, "block", HELP_CENTER_SUMMARY_PAD_CLASS), children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1574
|
-
|
|
1574
|
+
_chunkAFSVWR3Xcjs.DevCardRowContent,
|
|
1575
1575
|
{
|
|
1576
1576
|
title,
|
|
1577
1577
|
subtitle,
|
|
@@ -1652,7 +1652,7 @@ function HelpCenterCreateFormBody({
|
|
|
1652
1652
|
subjectError && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { id: "help-center-subject-error", className: "mt-1 text-ods-error text-h6", children: subjectError })
|
|
1653
1653
|
] });
|
|
1654
1654
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1655
|
-
|
|
1655
|
+
_chunkURFAMWCAcjs.ContactForm,
|
|
1656
1656
|
{
|
|
1657
1657
|
rescue: null,
|
|
1658
1658
|
title: "Open a new ticket",
|
|
@@ -1696,13 +1696,13 @@ function HelpCenterList({ toast: toast2 = _chunkCBKXU77Hcjs.toast, backButton, t
|
|
|
1696
1696
|
const searchParams = _chunk7DNL734Scjs.useSearchParams.call(void 0, );
|
|
1697
1697
|
const router = _chunk7DNL734Scjs.useRouter.call(void 0, );
|
|
1698
1698
|
const pathname = _chunk7DNL734Scjs.usePathname.call(void 0, );
|
|
1699
|
-
const search = searchParams.get(
|
|
1699
|
+
const search = searchParams.get(_chunk62TMGBROcjs.DEV_SECTION_PARAM_KEYS.search) || "";
|
|
1700
1700
|
const status = searchParams.get("status") || "all";
|
|
1701
|
-
const ticketParam = searchParams.get(
|
|
1701
|
+
const ticketParam = searchParams.get(_chunk62TMGBROcjs.TICKET_OPEN_PARAM) || "";
|
|
1702
1702
|
const page = _chunkBLH2SFOOcjs.positiveInt.call(void 0, searchParams.get("page"), 1);
|
|
1703
1703
|
if (identity.isLoading) {
|
|
1704
1704
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1705
|
-
|
|
1705
|
+
_chunkAFSVWR3Xcjs.DevSectionPage,
|
|
1706
1706
|
{
|
|
1707
1707
|
sectionKey: "tickets",
|
|
1708
1708
|
backButton,
|
|
@@ -1714,7 +1714,7 @@ function HelpCenterList({ toast: toast2 = _chunkCBKXU77Hcjs.toast, backButton, t
|
|
|
1714
1714
|
);
|
|
1715
1715
|
}
|
|
1716
1716
|
if (identity.authTier === "anon" || !_optionalChain([identity, 'access', _66 => _66.user, 'optionalAccess', _67 => _67.email])) {
|
|
1717
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1717
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkAFSVWR3Xcjs.DevSectionPage, { sectionKey: "tickets", backButton, title, shell, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1718
1718
|
_chunkYXZOP726cjs.EmptyState,
|
|
1719
1719
|
{
|
|
1720
1720
|
type: "generic",
|
|
@@ -1766,8 +1766,8 @@ function HelpCenterListAuthed({
|
|
|
1766
1766
|
const setOpenTicket = _react.useCallback.call(void 0,
|
|
1767
1767
|
(externalId) => {
|
|
1768
1768
|
const params = new URLSearchParams(searchParams.toString());
|
|
1769
|
-
if (externalId) params.set(
|
|
1770
|
-
else params.delete(
|
|
1769
|
+
if (externalId) params.set(_chunk62TMGBROcjs.TICKET_OPEN_PARAM, externalId);
|
|
1770
|
+
else params.delete(_chunk62TMGBROcjs.TICKET_OPEN_PARAM);
|
|
1771
1771
|
const qs = params.toString();
|
|
1772
1772
|
router.replace(qs ? `${pathname}?${qs}` : pathname, { scroll: false });
|
|
1773
1773
|
},
|
|
@@ -1845,7 +1845,7 @@ function HelpCenterListAuthed({
|
|
|
1845
1845
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkFLS6DZENcjs.Button, { type: "button", variant: "accent", onClick: () => refetch(), children: "Retry" })
|
|
1846
1846
|
] }),
|
|
1847
1847
|
!error && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "w-full", children: isLoading || !hasResults && isFetching ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, HelpCenterRowsFrame, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkMGEUZRNQcjs.LoadingItems, { count: pageSize, children: () => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, HelpCenterCard, { ticket: null, "data-loading-item": true }) }) }) : !hasResults ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1848
|
-
|
|
1848
|
+
_chunkAFSVWR3Xcjs.ListEmptyState,
|
|
1849
1849
|
{
|
|
1850
1850
|
isFiltered: hasActiveFilters,
|
|
1851
1851
|
filtered: {
|
|
@@ -1868,7 +1868,7 @@ function HelpCenterListAuthed({
|
|
|
1868
1868
|
HelpCenterCard,
|
|
1869
1869
|
{
|
|
1870
1870
|
"data-loading-item": true,
|
|
1871
|
-
id:
|
|
1871
|
+
id: _chunk62TMGBROcjs.devSectionAnchorId.call(void 0, "ticket", ticket.external_id),
|
|
1872
1872
|
ticket,
|
|
1873
1873
|
expanded: expandedTicketId === ticket.id,
|
|
1874
1874
|
onToggle: toggleRow,
|
|
@@ -1885,7 +1885,7 @@ function HelpCenterListAuthed({
|
|
|
1885
1885
|
)) }) }),
|
|
1886
1886
|
!error && totalPages > 1 && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkYXZOP726cjs.UnifiedPagination, { currentPage: page, totalPages })
|
|
1887
1887
|
] });
|
|
1888
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1888
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkAFSVWR3Xcjs.DevSectionPage, { sectionKey: "tickets", backButton, title, shell, preControls: form, children: body });
|
|
1889
1889
|
}
|
|
1890
1890
|
function HelpCenterRowsFrame({ children }) {
|
|
1891
1891
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "w-full overflow-clip rounded-[6px] border border-ods-border bg-ods-card", children });
|
|
@@ -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 _chunk62TMGBROcjs = require('./chunk-62TMGBRO.cjs');
|
|
5
5
|
|
|
6
6
|
|
|
7
7
|
var _chunkE2ZZOYSMcjs = require('./chunk-E2ZZOYSM.cjs');
|
|
@@ -396,7 +396,7 @@ function useScrollSpy(sections, options = {}) {
|
|
|
396
396
|
// src/components/navigation/multi-level-navigation.tsx
|
|
397
397
|
var _lucidereact = require('lucide-react');
|
|
398
398
|
|
|
399
|
-
var DEFAULT_FOLDER_INDEX_FILE2 =
|
|
399
|
+
var DEFAULT_FOLDER_INDEX_FILE2 = _chunk62TMGBROcjs.DEFAULT_FOLDER_INDEX_FILE;
|
|
400
400
|
var NAV_LIST_CLASS = "space-y-2";
|
|
401
401
|
var NAV_ITEM_CLASS = "space-y-1";
|
|
402
402
|
var NAV_ROW_FRAME_CLASS = "relative w-full rounded-lg border transition-all duration-150";
|
|
@@ -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 _chunkTHOGSAFHcjs = require('./chunk-THOGSAFH.cjs');
|
|
5
5
|
|
|
6
6
|
|
|
7
7
|
|
|
@@ -72,7 +72,7 @@ function DocSearchBar({
|
|
|
72
72
|
renderResult
|
|
73
73
|
}) {
|
|
74
74
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
75
|
-
|
|
75
|
+
_chunkTHOGSAFHcjs.SearchInput,
|
|
76
76
|
{
|
|
77
77
|
placeholder,
|
|
78
78
|
value: query,
|