@flamingo-stack/openframe-frontend-core 0.0.776 → 0.0.777
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/case-study-card-FMH622O5.cjs +25 -0
- package/dist/{chunk-2AZAJ7RK.cjs → chunk-3PCSEZNZ.cjs} +53 -53
- package/dist/{chunk-R3JX4MXD.cjs → chunk-3ZLPYEL5.cjs} +10 -10
- package/dist/{chunk-3V27UHSH.cjs → chunk-4JZDJ34E.cjs} +17 -17
- package/dist/{chunk-DGFDBPO7.cjs → chunk-5GJM7VRR.cjs} +1 -94
- package/dist/{chunk-E64HPPRH.cjs → chunk-5PK22JP7.cjs} +50 -50
- package/dist/{chunk-57B5RUYD.cjs → chunk-64KBI5MI.cjs} +2 -2
- package/dist/{chunk-BDYI6HBT.cjs → chunk-7LJSGOWS.cjs} +18 -16
- package/dist/{chunk-ASMNNSUQ.cjs → chunk-7PNRXJX2.cjs} +3 -3
- package/dist/{chunk-2YB4X5WT.cjs → chunk-ALA4KHTE.cjs} +6 -6
- package/dist/{chunk-VFZFCRAL.cjs → chunk-AQXKXZWB.cjs} +4 -4
- package/dist/{chunk-OTZQP53Y.cjs → chunk-BDDOC425.cjs} +8 -8
- package/dist/{chunk-VFUMM6JC.cjs → chunk-BEMGJDXI.cjs} +2 -2
- package/dist/{chunk-HY6BCZH7.cjs → chunk-BNUZKBNV.cjs} +3 -3
- package/dist/{chunk-MYHS4W2H.cjs → chunk-CGQ7CL62.cjs} +213 -1647
- package/dist/{chunk-L55XLH5A.cjs → chunk-DOM5CUEY.cjs} +33 -31
- package/dist/{chunk-IXZNBDXT.cjs → chunk-G2N7INFT.cjs} +28 -28
- package/dist/{chunk-XN6LXMH5.cjs → chunk-HXLOCZMG.cjs} +595 -591
- package/dist/{chunk-CZIMISAR.cjs → chunk-JB2SEF6Q.cjs} +7 -7
- package/dist/{chunk-2MF547RG.cjs → chunk-JMFF3L3T.cjs} +28 -26
- package/dist/{chunk-LJT2KRE2.cjs → chunk-KLTUTZBO.cjs} +24 -24
- package/dist/{chunk-EHJE3UWZ.cjs → chunk-LBGAHB6X.cjs} +20 -20
- package/dist/{chunk-OJLZ7PGO.cjs → chunk-LGNJTSKB.cjs} +37 -35
- package/dist/{chunk-MWH5ZTMB.cjs → chunk-LU2DGST4.cjs} +97 -95
- package/dist/chunk-MQPTOJMF.cjs +1504 -0
- package/dist/{chunk-XXJL5GY3.cjs → chunk-OJZBZH56.cjs} +3 -3
- package/dist/{chunk-XT5WEHFM.cjs → chunk-QIATO42V.cjs} +3 -3
- package/dist/{chunk-RB7VLVMD.cjs → chunk-R6BKQKIF.cjs} +9 -7
- package/dist/{chunk-NWZSYG4S.cjs → chunk-S3YDUX2I.cjs} +114 -112
- package/dist/{chunk-DDXQGTWB.cjs → chunk-SDZG7VV7.cjs} +5 -5
- package/dist/{chunk-V3W56L2D.cjs → chunk-SIDDZZKL.cjs} +38 -38
- package/dist/chunk-SZHDXXMK.cjs +102 -0
- package/dist/{chunk-AMVI5VXM.cjs → chunk-T47VAUYR.cjs} +91 -89
- package/dist/{chunk-F65RSJVV.cjs → chunk-T7NDPPLF.cjs} +23 -21
- package/dist/{chunk-5P4TDV7V.cjs → chunk-TUAATMUE.cjs} +5 -93
- package/dist/{chunk-KM2TVQCH.cjs → chunk-TZP7PSPG.cjs} +249 -243
- package/dist/{chunk-WAQPW4CB.cjs → chunk-U5VQFKRZ.cjs} +6 -6
- package/dist/{chunk-24OYQQZC.cjs → chunk-UW6AOF42.cjs} +22 -22
- package/dist/chunk-V4FXUIMH.cjs +92 -0
- package/dist/{chunk-2JRSYWFP.cjs → chunk-VXAKQRV7.cjs} +5 -5
- package/dist/{chunk-UM6HFGTI.cjs → chunk-VY3NGJRH.cjs} +53 -51
- package/dist/{chunk-LNCBN4BL.cjs → chunk-WCSWWVPF.cjs} +2 -2
- package/dist/{chunk-6HY2NH7D.cjs → chunk-WMZIBRTR.cjs} +2 -2
- package/dist/{chunk-5QP3K2CE.cjs → chunk-XEYL6AFZ.cjs} +9 -9
- package/dist/{chunk-YFTQ2ALU.cjs → chunk-XVAVQ4BK.cjs} +116 -82
- package/dist/{chunk-Z5KX56TK.cjs → chunk-Y6MQBLTZ.cjs} +4 -4
- package/dist/{cloud-tenants-QFE6QMR5.cjs → cloud-tenants-EUH42CCL.cjs} +27 -24
- package/dist/components/case-studies/index.cjs +45 -41
- package/dist/components/chat/index.cjs +21 -17
- package/dist/components/contact/index.cjs +28 -25
- package/dist/components/docs/index.cjs +31 -28
- package/dist/components/embeds/index.cjs +28 -25
- package/dist/components/faq/index.cjs +29 -26
- package/dist/components/features/index.cjs +28 -24
- package/dist/components/help-center-pages/index.cjs +131 -127
- package/dist/components/index.cjs +94 -90
- package/dist/components/meeting-scheduler/index.cjs +95 -92
- package/dist/components/navigation/index.cjs +30 -27
- package/dist/components/navigation/nav-panel.d.ts.map +1 -1
- package/dist/components/navigation/nav-panel.js +47 -13
- package/dist/components/onboarding-guides/index.cjs +30 -27
- package/dist/components/product-demo/index.cjs +38 -35
- package/dist/components/related-content/index.cjs +15 -12
- package/dist/components/tickets/index.cjs +33 -30
- package/dist/components/ui/index.cjs +28 -24
- package/dist/{devices-SFJDLXSW.cjs → devices-WL3I23EE.cjs} +28 -25
- package/dist/{embeddable-chat-XZUWAK4W.cjs → embeddable-chat-KEWUGQIF.cjs} +99 -95
- package/dist/hooks/index.cjs +12 -10
- package/dist/index.cjs +36 -30
- package/dist/{knowledge-SAK3ZGCO.cjs → knowledge-O3PXUX73.cjs} +28 -25
- package/dist/{logs-CYBGMFA5.cjs → logs-XODCXWYI.cjs} +35 -32
- package/dist/{policies-XXDOICWF.cjs → policies-CQACBIKK.cjs} +31 -28
- package/dist/{remote-session-TC3BZDBZ.cjs → remote-session-TGM2OTTV.cjs} +12 -10
- package/dist/{scripts-C5T2AQPA.cjs → scripts-QMM6SEB5.cjs} +34 -31
- package/dist/{software-update-XU5AI4TP.cjs → software-update-CCCKS4ZE.cjs} +31 -28
- package/dist/{tickets-board-YT25IX3O.cjs → tickets-board-FB5AGLJD.cjs} +16 -14
- package/dist/{video-file-player-6ZFOZFER.cjs → video-file-player-SIJW5UWU.cjs} +3 -2
- package/package.json +1 -1
- package/src/components/navigation/nav-panel.tsx +74 -14
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true});"use client";
|
|
2
|
+
"use client";
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
var _chunkMQPTOJMFcjs = require('./chunk-MQPTOJMF.cjs');
|
|
7
|
+
require('./chunk-3ZLPYEL5.cjs');
|
|
8
|
+
require('./chunk-SETFUCZA.cjs');
|
|
9
|
+
require('./chunk-S5C3OZCO.cjs');
|
|
10
|
+
require('./chunk-4IYNDV3G.cjs');
|
|
11
|
+
require('./chunk-3LW5TD54.cjs');
|
|
12
|
+
require('./chunk-7PNRXJX2.cjs');
|
|
13
|
+
require('./chunk-NTPX5GXI.cjs');
|
|
14
|
+
require('./chunk-TUAATMUE.cjs');
|
|
15
|
+
require('./chunk-5GJM7VRR.cjs');
|
|
16
|
+
require('./chunk-E76ONBKF.cjs');
|
|
17
|
+
require('./chunk-UJ7AXHRZ.cjs');
|
|
18
|
+
require('./chunk-XFRBEXQN.cjs');
|
|
19
|
+
require('./chunk-TF5D5MNO.cjs');
|
|
20
|
+
require('./chunk-V45KLJQP.cjs');
|
|
21
|
+
require('./chunk-65VVJSQZ.cjs');
|
|
22
|
+
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
exports.CaseStudyCard = _chunkMQPTOJMFcjs.CaseStudyCard; exports.CaseStudyCardSkeleton = _chunkMQPTOJMFcjs.CaseStudyCardSkeleton;
|
|
@@ -3,51 +3,51 @@
|
|
|
3
3
|
|
|
4
4
|
|
|
5
5
|
|
|
6
|
-
var
|
|
6
|
+
var _chunkBDDOC425cjs = require('./chunk-BDDOC425.cjs');
|
|
7
7
|
|
|
8
8
|
|
|
9
9
|
|
|
10
10
|
|
|
11
11
|
|
|
12
|
-
var
|
|
12
|
+
var _chunk4JZDJ34Ecjs = require('./chunk-4JZDJ34E.cjs');
|
|
13
13
|
|
|
14
14
|
|
|
15
15
|
|
|
16
|
-
var
|
|
16
|
+
var _chunk7LJSGOWScjs = require('./chunk-7LJSGOWS.cjs');
|
|
17
17
|
|
|
18
18
|
|
|
19
19
|
|
|
20
20
|
|
|
21
21
|
|
|
22
22
|
|
|
23
|
-
var
|
|
23
|
+
var _chunkHXLOCZMGcjs = require('./chunk-HXLOCZMG.cjs');
|
|
24
24
|
|
|
25
25
|
|
|
26
|
-
var
|
|
26
|
+
var _chunkSIDDZZKLcjs = require('./chunk-SIDDZZKL.cjs');
|
|
27
27
|
|
|
28
28
|
|
|
29
29
|
|
|
30
30
|
|
|
31
31
|
|
|
32
|
-
var
|
|
32
|
+
var _chunkS3YDUX2Icjs = require('./chunk-S3YDUX2I.cjs');
|
|
33
33
|
|
|
34
34
|
|
|
35
35
|
|
|
36
36
|
|
|
37
37
|
|
|
38
|
-
var
|
|
38
|
+
var _chunkTZP7PSPGcjs = require('./chunk-TZP7PSPG.cjs');
|
|
39
39
|
|
|
40
40
|
|
|
41
41
|
|
|
42
42
|
|
|
43
|
-
var
|
|
43
|
+
var _chunkOJZBZH56cjs = require('./chunk-OJZBZH56.cjs');
|
|
44
44
|
|
|
45
45
|
|
|
46
46
|
var _chunk7DNL734Scjs = require('./chunk-7DNL734S.cjs');
|
|
47
47
|
|
|
48
48
|
|
|
49
49
|
|
|
50
|
-
var
|
|
50
|
+
var _chunk7PNRXJX2cjs = require('./chunk-7PNRXJX2.cjs');
|
|
51
51
|
|
|
52
52
|
|
|
53
53
|
var _chunkUJ7AXHRZcjs = require('./chunk-UJ7AXHRZ.cjs');
|
|
@@ -225,7 +225,7 @@ function useDocsResolveLink(sourceId, resolveLinkEndpoint) {
|
|
|
225
225
|
return _react.useCallback.call(void 0,
|
|
226
226
|
async (href, currentPath) => {
|
|
227
227
|
try {
|
|
228
|
-
const response = await
|
|
228
|
+
const response = await _chunk7PNRXJX2cjs.contentFetch.call(void 0, resolvedResolveLinkEndpoint, {
|
|
229
229
|
method: "POST",
|
|
230
230
|
headers: { "Content-Type": "application/json" },
|
|
231
231
|
body: JSON.stringify({ link: href, currentPath, source: sourceId })
|
|
@@ -251,9 +251,9 @@ function useDocsResolveLink(sourceId, resolveLinkEndpoint) {
|
|
|
251
251
|
function scrollToContent() {
|
|
252
252
|
const article = document.querySelector("article");
|
|
253
253
|
if (article) {
|
|
254
|
-
|
|
254
|
+
_chunkOJZBZH56cjs.scrollElementIntoView.call(void 0, article, { headerOffset: _chunkOJZBZH56cjs.HUB_HEADER_OFFSET_PX });
|
|
255
255
|
} else {
|
|
256
|
-
|
|
256
|
+
_chunkOJZBZH56cjs.scrollElementIntoView.call(void 0, document.documentElement);
|
|
257
257
|
}
|
|
258
258
|
}
|
|
259
259
|
function findFirstDocPath(folder) {
|
|
@@ -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 (!_chunkHXLOCZMGcjs.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, () => ( _chunkS3YDUX2Icjs.DEFAULT_FOLDER_INDEX_FILE));
|
|
363
|
+
const cleanInitialPath = _chunkS3YDUX2Icjs.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 = _chunkS3YDUX2Icjs.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(_chunkS3YDUX2Icjs.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(_chunkS3YDUX2Icjs.getDocAncestorNodeIds.call(void 0, parentPath)));
|
|
413
413
|
}
|
|
414
414
|
setExternalNavCount((n) => n + 1);
|
|
415
415
|
}
|
|
@@ -423,7 +423,7 @@ function useDocumentTree(config, initialPath) {
|
|
|
423
423
|
try {
|
|
424
424
|
setIsLoadingStructure(true);
|
|
425
425
|
setError(null);
|
|
426
|
-
const response = await
|
|
426
|
+
const response = await _chunk7PNRXJX2cjs.contentFetch.call(void 0, structureEndpoint);
|
|
427
427
|
if (!response.ok) {
|
|
428
428
|
throw new Error("Failed to load documentation structure");
|
|
429
429
|
}
|
|
@@ -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(_chunkS3YDUX2Icjs.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);
|
|
@@ -450,7 +450,7 @@ function useDocumentTree(config, initialPath) {
|
|
|
450
450
|
}
|
|
451
451
|
}
|
|
452
452
|
} else {
|
|
453
|
-
setError(
|
|
453
|
+
setError(_chunk7PNRXJX2cjs.apiErrorMessage.call(void 0, payload, "Failed to load documentation structure"));
|
|
454
454
|
}
|
|
455
455
|
} catch (err) {
|
|
456
456
|
console.error("Error fetching documentation structure:", err);
|
|
@@ -462,7 +462,7 @@ function useDocumentTree(config, initialPath) {
|
|
|
462
462
|
const fetchContent = async (path) => {
|
|
463
463
|
try {
|
|
464
464
|
setIsLoadingContent(true);
|
|
465
|
-
const response = await
|
|
465
|
+
const response = await _chunk7PNRXJX2cjs.contentFetch.call(void 0, `${contentEndpoint}?path=${encodeURIComponent(path)}`);
|
|
466
466
|
if (path !== lastFetchedPath.current) return;
|
|
467
467
|
if (!response.ok) {
|
|
468
468
|
if (response.status === 404) {
|
|
@@ -474,7 +474,7 @@ function useDocumentTree(config, initialPath) {
|
|
|
474
474
|
setContent(null);
|
|
475
475
|
return;
|
|
476
476
|
}
|
|
477
|
-
const probe =
|
|
477
|
+
const probe = _chunkS3YDUX2Icjs.findDocNodeByPath.call(void 0, _chunkS3YDUX2Icjs.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) {
|
|
@@ -483,7 +483,7 @@ function useDocumentTree(config, initialPath) {
|
|
|
483
483
|
setContent(null);
|
|
484
484
|
return;
|
|
485
485
|
}
|
|
486
|
-
setError(
|
|
486
|
+
setError(_chunk7PNRXJX2cjs.apiErrorMessage.call(void 0, errorPayload, "Documentation file not found"));
|
|
487
487
|
setContent(null);
|
|
488
488
|
return;
|
|
489
489
|
}
|
|
@@ -501,7 +501,7 @@ function useDocumentTree(config, initialPath) {
|
|
|
501
501
|
}
|
|
502
502
|
setContent(doc);
|
|
503
503
|
} else {
|
|
504
|
-
setError(
|
|
504
|
+
setError(_chunk7PNRXJX2cjs.apiErrorMessage.call(void 0, payload, "Failed to load content"));
|
|
505
505
|
setContent(null);
|
|
506
506
|
}
|
|
507
507
|
} catch (err) {
|
|
@@ -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 = _chunkS3YDUX2Icjs.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 = _chunkS3YDUX2Icjs.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(_chunkS3YDUX2Icjs.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(_chunkS3YDUX2Icjs.getDocAncestorNodeIds.call(void 0, node.path.substring(0, lastSlash))));
|
|
587
587
|
}
|
|
588
588
|
}
|
|
589
589
|
lastFetchedPath.current = null;
|
|
@@ -598,9 +598,9 @@ 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 : _chunkS3YDUX2Icjs.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;
|
|
605
605
|
}
|
|
606
606
|
const scrollAfterNav = () => {
|
|
@@ -608,7 +608,7 @@ function useDocumentTree(config, initialPath) {
|
|
|
608
608
|
setTimeout(() => {
|
|
609
609
|
const el = document.getElementById(anchor.substring(1));
|
|
610
610
|
if (el) {
|
|
611
|
-
|
|
611
|
+
_chunkOJZBZH56cjs.scrollElementIntoView.call(void 0, el, { headerOffset: _chunkOJZBZH56cjs.HUB_HEADER_OFFSET_PX });
|
|
612
612
|
} else {
|
|
613
613
|
scrollToContent();
|
|
614
614
|
}
|
|
@@ -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 = _chunkS3YDUX2Icjs.stripFolderIndexFromPath.call(void 0, path.replace(/\/$/, "").split("#")[0], folderIndexFile);
|
|
666
|
+
return _nullishCoalesce(_chunkS3YDUX2Icjs.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 = _chunkS3YDUX2Icjs.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 } = _chunk4JZDJ34Ecjs.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 = _chunk7LJSGOWScjs.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([_chunkS3YDUX2Icjs.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;
|
|
@@ -795,10 +795,10 @@ function DocViewerContent({
|
|
|
795
795
|
const containerBgStyle = colorPalette.containerBackground !== "transparent" ? { backgroundColor: colorPalette.containerBackground } : {};
|
|
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
|
-
const inner = /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { style: { ...bgStyle, ...containerBgStyle }, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
799
|
-
synced && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
798
|
+
const inner = /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { style: { ...bgStyle, ...containerBgStyle }, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSIDDZZKLcjs.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, _chunkHXLOCZMGcjs.DataSyncLine, { sync: _optionalChain([content, 'optionalAccess', _19 => _19.sync]), loading: !content && (isLoadingContent || isLoadingStructure) }),
|
|
800
800
|
showAIChat && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
801
|
-
|
|
801
|
+
_chunk7LJSGOWScjs.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
|
+
_chunk4JZDJ34Ecjs.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
|
+
_chunk4JZDJ34Ecjs.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
|
+
_chunk4JZDJ34Ecjs.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, _chunkHXLOCZMGcjs.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
|
|
@@ -903,14 +903,14 @@ var MARKDOWN_SKELETON_BLOCKS = [
|
|
|
903
903
|
{ kind: "p", lines: 3 },
|
|
904
904
|
{ kind: "p", lines: 4 }
|
|
905
905
|
];
|
|
906
|
-
var MARKDOWN_SKELETON_H2_CLASS = _chunk65VVJSQZcjs.cn.call(void 0,
|
|
907
|
-
var MARKDOWN_SKELETON_P_CLASS = _chunk65VVJSQZcjs.cn.call(void 0,
|
|
906
|
+
var MARKDOWN_SKELETON_H2_CLASS = _chunk65VVJSQZcjs.cn.call(void 0, _chunkTZP7PSPGcjs.MARKDOWN_H2_CLASS, _chunkTZP7PSPGcjs.TEXT_SIZE_PRESETS.default.h2);
|
|
907
|
+
var MARKDOWN_SKELETON_P_CLASS = _chunk65VVJSQZcjs.cn.call(void 0, _chunkTZP7PSPGcjs.MARKDOWN_PARAGRAPH_CLASS, _chunkTZP7PSPGcjs.TEXT_SIZE_PRESETS.default.p);
|
|
908
908
|
function MarkdownSkeleton({
|
|
909
909
|
region = true
|
|
910
910
|
} = {}) {
|
|
911
911
|
return (
|
|
912
912
|
// The renderer's root class, and its box (no margin of its own, like the rendered body): the document's first fold.
|
|
913
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkWEANWBJHcjs.LoadingRegion, { label: "Loading the document", announce: region, className:
|
|
913
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkWEANWBJHcjs.LoadingRegion, { label: "Loading the document", announce: region, className: _chunkTZP7PSPGcjs.MARKDOWN_RENDERER_CLASS, children: MARKDOWN_SKELETON_BLOCKS.map(
|
|
914
914
|
(block, i) => block.kind === "h2" ? (
|
|
915
915
|
// biome-ignore lint/suspicious/noArrayIndexKey: skeleton blocks never reorder
|
|
916
916
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "h2", { className: MARKDOWN_SKELETON_H2_CLASS, "aria-hidden": true, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkXFRBEXQNcjs.TextLineSkeleton, { type: "inherit", as: "span", className: "w-1/3" }) }, i)
|
|
@@ -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, _chunkXFRBEXQNcjs.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, _chunkHXLOCZMGcjs.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, _chunkBDDOC425cjs.PdfViewer, { src: content.fileUrl, fileName: content.fileName }) : defaultFallbackRenderer(content, handlers);
|
|
961
|
+
var defaultGoogleSheetRenderer = (content, handlers) => content.externalUrl ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBDDOC425cjs.GoogleSheetsViewer, { externalUrl: content.externalUrl, fileName: content.fileName }) : defaultFallbackRenderer(content, handlers);
|
|
962
|
+
var defaultFigmaRenderer = (content, handlers) => content.externalUrl ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkHXLOCZMGcjs.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
|
+
_chunkBDDOC425cjs.FileDownloadCard,
|
|
965
965
|
{
|
|
966
966
|
fileName: content.fileName,
|
|
967
967
|
mimeType: content.mimeType,
|
|
@@ -3,12 +3,12 @@
|
|
|
3
3
|
|
|
4
4
|
|
|
5
5
|
|
|
6
|
-
var
|
|
6
|
+
var _chunk7PNRXJX2cjs = require('./chunk-7PNRXJX2.cjs');
|
|
7
7
|
|
|
8
8
|
|
|
9
9
|
|
|
10
10
|
|
|
11
|
-
var
|
|
11
|
+
var _chunkTUAATMUEcjs = require('./chunk-TUAATMUE.cjs');
|
|
12
12
|
|
|
13
13
|
// src/utils/color-analysis.ts
|
|
14
14
|
var DESIGN_PALETTE = [
|
|
@@ -243,13 +243,13 @@ function getSemanticColor(semanticName, platform) {
|
|
|
243
243
|
}
|
|
244
244
|
function getPlatformConfig(platform) {
|
|
245
245
|
const currentPlatform = platform || getCurrentPlatform();
|
|
246
|
-
const isDarkTheme =
|
|
246
|
+
const isDarkTheme = _chunkTUAATMUEcjs.PLATFORM_THEME === "dark";
|
|
247
247
|
return {
|
|
248
248
|
platform: currentPlatform,
|
|
249
|
-
accentColor:
|
|
249
|
+
accentColor: _chunkTUAATMUEcjs.getPlatformAccentColor.call(void 0, currentPlatform),
|
|
250
250
|
isDarkTheme,
|
|
251
251
|
isLightTheme: !isDarkTheme,
|
|
252
|
-
brandName:
|
|
252
|
+
brandName: _chunkTUAATMUEcjs.getPlatformDisplayName.call(void 0, currentPlatform)
|
|
253
253
|
};
|
|
254
254
|
}
|
|
255
255
|
function usePlatformColors(platform) {
|
|
@@ -276,7 +276,7 @@ function hexToRgb2(hex) {
|
|
|
276
276
|
return { r: n >> 16 & 255, g: n >> 8 & 255, b: n & 255 };
|
|
277
277
|
}
|
|
278
278
|
function rgbToHex(r, g, b) {
|
|
279
|
-
const to = (n) =>
|
|
279
|
+
const to = (n) => _chunk7PNRXJX2cjs.clamp.call(void 0, Math.round(n), 0, 255).toString(16).padStart(2, "0");
|
|
280
280
|
return `#${to(r)}${to(g)}${to(b)}`;
|
|
281
281
|
}
|
|
282
282
|
var HOVER_DARKEN_STEP = 10;
|
|
@@ -310,8 +310,8 @@ function rgbToHsl(r, g, b) {
|
|
|
310
310
|
return { h: Math.round(h), s: Math.round(s * 100), l: Math.round(l * 100) };
|
|
311
311
|
}
|
|
312
312
|
function hslToRgb(h, s, l) {
|
|
313
|
-
const sn =
|
|
314
|
-
const ln =
|
|
313
|
+
const sn = _chunk7PNRXJX2cjs.clamp.call(void 0, s, 0, 100) / 100;
|
|
314
|
+
const ln = _chunk7PNRXJX2cjs.clamp.call(void 0, l, 0, 100) / 100;
|
|
315
315
|
const hn = (h % 360 + 360) % 360;
|
|
316
316
|
if (sn === 0) {
|
|
317
317
|
const v = Math.round(ln * 255);
|
|
@@ -368,11 +368,11 @@ function ProvideFromServer({
|
|
|
368
368
|
enabled,
|
|
369
369
|
children
|
|
370
370
|
}) {
|
|
371
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, Provide, { icons:
|
|
371
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, Provide, { icons: _chunk7PNRXJX2cjs.useAgentIdentities.call(void 0, endpoint, enabled), children });
|
|
372
372
|
}
|
|
373
373
|
function AgentIdentityProvider({
|
|
374
374
|
icons,
|
|
375
|
-
endpoint =
|
|
375
|
+
endpoint = _chunk7PNRXJX2cjs.AGENT_IDENTITIES_API_PATH,
|
|
376
376
|
enabled = true,
|
|
377
377
|
children
|
|
378
378
|
}) {
|
|
@@ -1,10 +1,10 @@
|
|
|
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 _chunkS3YDUX2Icjs = require('./chunk-S3YDUX2I.cjs');
|
|
5
5
|
|
|
6
6
|
|
|
7
|
-
var
|
|
7
|
+
var _chunkTZP7PSPGcjs = require('./chunk-TZP7PSPG.cjs');
|
|
8
8
|
|
|
9
9
|
|
|
10
10
|
|
|
@@ -14,7 +14,7 @@ var _chunkKM2TVQCHcjs = require('./chunk-KM2TVQCH.cjs');
|
|
|
14
14
|
|
|
15
15
|
|
|
16
16
|
|
|
17
|
-
var
|
|
17
|
+
var _chunkOJZBZH56cjs = require('./chunk-OJZBZH56.cjs');
|
|
18
18
|
|
|
19
19
|
|
|
20
20
|
|
|
@@ -71,7 +71,7 @@ function HorizontalSectionNav({
|
|
|
71
71
|
className: _chunk65VVJSQZcjs.cn.call(void 0, HORIZONTAL_NAV_CLASS, STICKY_SECTION_NAV_HEIGHT_CLASS, className),
|
|
72
72
|
children: [
|
|
73
73
|
brand && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: HORIZONTAL_BRAND_CLASS, children: brand }),
|
|
74
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
74
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkTZP7PSPGcjs.ScrollShadow, { axis: "horizontal", className: "min-w-0 flex-1", scrollClassName: HORIZONTAL_ROW_CLASS, children: sections.map((section) => {
|
|
75
75
|
const active = activeSection === section.id;
|
|
76
76
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
77
77
|
_chunkV45KLJQPcjs.next_link_default,
|
|
@@ -232,7 +232,7 @@ function useSectionNavigation(sections, options) {
|
|
|
232
232
|
if (!targetElement) return;
|
|
233
233
|
isScrollingFromClick.current = true;
|
|
234
234
|
setActiveSection(sectionId);
|
|
235
|
-
|
|
235
|
+
_chunkOJZBZH56cjs.scrollElementIntoView.call(void 0, targetElement, { headerOffset: offset });
|
|
236
236
|
setTimeout(() => {
|
|
237
237
|
isScrollingFromClick.current = false;
|
|
238
238
|
}, 500);
|
|
@@ -285,13 +285,13 @@ var SCROLL_OFFSET = 100;
|
|
|
285
285
|
var ID_SEPARATOR = "\n";
|
|
286
286
|
var LINE_TOLERANCE_PX = 1;
|
|
287
287
|
function currentHashId() {
|
|
288
|
-
return
|
|
288
|
+
return _chunkOJZBZH56cjs.normalizeHashFragment.call(void 0, window.location.hash).slice(1);
|
|
289
289
|
}
|
|
290
290
|
function activeChildAnchor(section) {
|
|
291
|
-
return _nullishCoalesce(_optionalChain([section, 'access', _10 => _10.querySelector, 'call', _11 => _11(`[${
|
|
291
|
+
return _nullishCoalesce(_optionalChain([section, 'access', _10 => _10.querySelector, 'call', _11 => _11(`[${_chunkOJZBZH56cjs.ACTIVE_ANCHOR_ATTRIBUTE}][id]`), 'optionalAccess', _12 => _12.id]), () => ( null));
|
|
292
292
|
}
|
|
293
293
|
function hashIsWithin(section) {
|
|
294
|
-
return section.contains(
|
|
294
|
+
return section.contains(_chunkOJZBZH56cjs.getHashTargetElement.call(void 0, currentHashId()));
|
|
295
295
|
}
|
|
296
296
|
function hashForSection(sectionId) {
|
|
297
297
|
const section = document.getElementById(sectionId);
|
|
@@ -299,7 +299,7 @@ function hashForSection(sectionId) {
|
|
|
299
299
|
return _nullishCoalesce(activeChildAnchor(section), () => ( (hashIsWithin(section) ? currentHashId() : sectionId)));
|
|
300
300
|
}
|
|
301
301
|
function resolveScroller(firstSection) {
|
|
302
|
-
const container = firstSection ?
|
|
302
|
+
const container = firstSection ? _chunkOJZBZH56cjs.getScrollableAncestor.call(void 0, firstSection) : null;
|
|
303
303
|
if (container) {
|
|
304
304
|
return {
|
|
305
305
|
target: container,
|
|
@@ -329,8 +329,8 @@ function useScrollSpy(sections, options = {}) {
|
|
|
329
329
|
if (!targetElement) return;
|
|
330
330
|
isScrollingFromClick.current = true;
|
|
331
331
|
setActiveSection(sectionId);
|
|
332
|
-
if (syncHash)
|
|
333
|
-
|
|
332
|
+
if (syncHash) _chunkOJZBZH56cjs.replaceLocationHash.call(void 0, _nullishCoalesce(activeChildAnchor(targetElement), () => ( sectionId)));
|
|
333
|
+
_chunkOJZBZH56cjs.scrollElementIntoView.call(void 0, targetElement, { headerOffset });
|
|
334
334
|
setTimeout(() => {
|
|
335
335
|
isScrollingFromClick.current = false;
|
|
336
336
|
}, 800);
|
|
@@ -346,7 +346,7 @@ function useScrollSpy(sections, options = {}) {
|
|
|
346
346
|
const scrollTop = scroller.scrollTop();
|
|
347
347
|
const viewportTop = scroller.viewportTop();
|
|
348
348
|
const sectionTop = (element) => element.getBoundingClientRect().top - viewportTop + scrollTop;
|
|
349
|
-
const reached = (element) => scrollTop + Math.max(headerOffset,
|
|
349
|
+
const reached = (element) => scrollTop + Math.max(headerOffset, _chunkOJZBZH56cjs.declaredScrollMarginTop.call(void 0, element)) + LINE_TOLERANCE_PX >= sectionTop(element);
|
|
350
350
|
const first = document.getElementById(_nullishCoalesce(sectionIds[0], () => ( "")));
|
|
351
351
|
let currentSection = _nullishCoalesce(sectionIds[0], () => ( ""));
|
|
352
352
|
const scrollHeight = scroller.scrollHeight();
|
|
@@ -369,16 +369,16 @@ function useScrollSpy(sections, options = {}) {
|
|
|
369
369
|
setActiveSection((prev) => prev !== active ? active : prev);
|
|
370
370
|
if (!syncHash) return;
|
|
371
371
|
if (fromScroll) {
|
|
372
|
-
|
|
372
|
+
_chunkOJZBZH56cjs.replaceLocationHash.call(void 0, isAboveFirst ? null : hashForSection(currentSection));
|
|
373
373
|
return;
|
|
374
374
|
}
|
|
375
|
-
if (restoredChecked.current || !
|
|
376
|
-
const target =
|
|
375
|
+
if (restoredChecked.current || !_chunkOJZBZH56cjs.isScrollSyncedHash.call(void 0, )) return;
|
|
376
|
+
const target = _chunkOJZBZH56cjs.getHashTargetElement.call(void 0, currentHashId());
|
|
377
377
|
const tracked = sectionIds.some((id) => _nullishCoalesce(_optionalChain([document, 'access', _17 => _17.getElementById, 'call', _18 => _18(id), 'optionalAccess', _19 => _19.contains, 'call', _20 => _20(target)]), () => ( false)));
|
|
378
378
|
if (!target || !tracked) return;
|
|
379
379
|
restoredChecked.current = true;
|
|
380
380
|
const section = isAboveFirst ? null : document.getElementById(currentSection);
|
|
381
|
-
if (!_optionalChain([section, 'optionalAccess', _21 => _21.contains, 'call', _22 => _22(target)]))
|
|
381
|
+
if (!_optionalChain([section, 'optionalAccess', _21 => _21.contains, 'call', _22 => _22(target)])) _chunkOJZBZH56cjs.scrollElementIntoView.call(void 0, target, { headerOffset, behavior: "instant" });
|
|
382
382
|
};
|
|
383
383
|
let scrollTimer;
|
|
384
384
|
const throttledScroll = () => {
|
|
@@ -398,7 +398,7 @@ function useScrollSpy(sections, options = {}) {
|
|
|
398
398
|
// src/components/navigation/multi-level-navigation.tsx
|
|
399
399
|
var _lucidereact = require('lucide-react');
|
|
400
400
|
|
|
401
|
-
var DEFAULT_FOLDER_INDEX_FILE2 =
|
|
401
|
+
var DEFAULT_FOLDER_INDEX_FILE2 = _chunkS3YDUX2Icjs.DEFAULT_FOLDER_INDEX_FILE;
|
|
402
402
|
var NAV_LIST_CLASS = "space-y-2";
|
|
403
403
|
var NAV_ITEM_CLASS = "space-y-1";
|
|
404
404
|
var NAV_ROW_FRAME_CLASS = "relative w-full rounded-lg border transition-all duration-150";
|