@fern-api/fdr-sdk 1.2.42-54880bfeac → 1.2.42-6d01f91096

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (90) hide show
  1. package/dist/js/client/FdrClient.js +0 -1
  2. package/dist/js/client/FdrClient.js.map +1 -1
  3. package/dist/js/client/FdrClient.mjs +0 -1
  4. package/dist/js/client/FdrClient.mjs.map +1 -1
  5. package/dist/js/converters/index.js +0 -9
  6. package/dist/js/converters/index.js.map +1 -1
  7. package/dist/js/converters/index.mjs +0 -9
  8. package/dist/js/converters/index.mjs.map +1 -1
  9. package/dist/js/index.js +0 -10
  10. package/dist/js/index.js.map +1 -1
  11. package/dist/js/index.mjs +0 -10
  12. package/dist/js/index.mjs.map +1 -1
  13. package/dist/js/navigation/index.js +0 -9
  14. package/dist/js/navigation/index.js.map +1 -1
  15. package/dist/js/navigation/index.mjs +0 -9
  16. package/dist/js/navigation/index.mjs.map +1 -1
  17. package/dist/js/navigation/ledger-root-builder.js +36 -212
  18. package/dist/js/navigation/ledger-root-builder.js.map +1 -1
  19. package/dist/js/navigation/ledger-root-builder.mjs +36 -212
  20. package/dist/js/navigation/ledger-root-builder.mjs.map +1 -1
  21. package/dist/js/orpc-client.js +0 -1
  22. package/dist/js/orpc-client.js.map +1 -1
  23. package/dist/js/orpc-client.mjs +0 -1
  24. package/dist/js/orpc-client.mjs.map +1 -1
  25. package/dist/navigation/__test__/ledger-root-builder.metadataPreservation.test.js +4 -109
  26. package/dist/navigation/__test__/ledger-root-builder.metadataPreservation.test.js.map +1 -1
  27. package/dist/navigation/__test__/ledger-root-builder.rootChildOrder.test.js +0 -102
  28. package/dist/navigation/__test__/ledger-root-builder.rootChildOrder.test.js.map +1 -1
  29. package/dist/navigation/__test__/ledger-root-builder.skipSlugApiReference.test.js +0 -276
  30. package/dist/navigation/__test__/ledger-root-builder.skipSlugApiReference.test.js.map +1 -1
  31. package/dist/navigation/ledger-root-builder.d.ts.map +1 -1
  32. package/dist/navigation/ledger-root-builder.js +47 -312
  33. package/dist/navigation/ledger-root-builder.js.map +1 -1
  34. package/dist/navigation/utils/index.d.ts +0 -1
  35. package/dist/navigation/utils/index.d.ts.map +1 -1
  36. package/dist/navigation/utils/index.js +0 -1
  37. package/dist/navigation/utils/index.js.map +1 -1
  38. package/dist/orpc-client/docs-ledger/contract.d.ts +0 -9
  39. package/dist/orpc-client/docs-ledger/contract.d.ts.map +1 -1
  40. package/dist/orpc-client/docs-ledger/contract.js +0 -1
  41. package/dist/orpc-client/docs-ledger/contract.js.map +1 -1
  42. package/dist/tsconfig.tsbuildinfo +1 -1
  43. package/dist/types/navigation/ledger-root-builder.d.ts.map +1 -1
  44. package/dist/types/navigation/utils/index.d.ts +0 -1
  45. package/dist/types/navigation/utils/index.d.ts.map +1 -1
  46. package/dist/types/orpc-client/docs-ledger/contract.d.ts +0 -9
  47. package/dist/types/orpc-client/docs-ledger/contract.d.ts.map +1 -1
  48. package/package.json +1 -1
  49. package/dist/navigation/__test__/ledger-root-builder.crossProductDedup.test.d.ts +0 -2
  50. package/dist/navigation/__test__/ledger-root-builder.crossProductDedup.test.d.ts.map +0 -1
  51. package/dist/navigation/__test__/ledger-root-builder.crossProductDedup.test.js +0 -267
  52. package/dist/navigation/__test__/ledger-root-builder.crossProductDedup.test.js.map +0 -1
  53. package/dist/navigation/__test__/ledger-root-builder.ledgerParity.test.d.ts +0 -2
  54. package/dist/navigation/__test__/ledger-root-builder.ledgerParity.test.d.ts.map +0 -1
  55. package/dist/navigation/__test__/ledger-root-builder.ledgerParity.test.js +0 -306
  56. package/dist/navigation/__test__/ledger-root-builder.ledgerParity.test.js.map +0 -1
  57. package/dist/navigation/__test__/ledger-root-builder.sidebarDepth.test.d.ts +0 -2
  58. package/dist/navigation/__test__/ledger-root-builder.sidebarDepth.test.d.ts.map +0 -1
  59. package/dist/navigation/__test__/ledger-root-builder.sidebarDepth.test.js +0 -273
  60. package/dist/navigation/__test__/ledger-root-builder.sidebarDepth.test.js.map +0 -1
  61. package/dist/navigation/__test__/ledger-root-builder.skipSlugGroupOrdering.test.d.ts +0 -2
  62. package/dist/navigation/__test__/ledger-root-builder.skipSlugGroupOrdering.test.d.ts.map +0 -1
  63. package/dist/navigation/__test__/ledger-root-builder.skipSlugGroupOrdering.test.js +0 -234
  64. package/dist/navigation/__test__/ledger-root-builder.skipSlugGroupOrdering.test.js.map +0 -1
  65. package/dist/navigation/__test__/ledger-root-builder.skipSlugSiblingSection.test.d.ts +0 -2
  66. package/dist/navigation/__test__/ledger-root-builder.skipSlugSiblingSection.test.d.ts.map +0 -1
  67. package/dist/navigation/__test__/ledger-root-builder.skipSlugSiblingSection.test.js +0 -360
  68. package/dist/navigation/__test__/ledger-root-builder.skipSlugSiblingSection.test.js.map +0 -1
  69. package/dist/navigation/utils/__test__/syntheticSectionPath.test.d.ts +0 -2
  70. package/dist/navigation/utils/__test__/syntheticSectionPath.test.d.ts.map +0 -1
  71. package/dist/navigation/utils/__test__/syntheticSectionPath.test.js +0 -29
  72. package/dist/navigation/utils/__test__/syntheticSectionPath.test.js.map +0 -1
  73. package/dist/navigation/utils/syntheticSectionPath.d.ts +0 -13
  74. package/dist/navigation/utils/syntheticSectionPath.d.ts.map +0 -1
  75. package/dist/navigation/utils/syntheticSectionPath.js +0 -20
  76. package/dist/navigation/utils/syntheticSectionPath.js.map +0 -1
  77. package/dist/types/navigation/__test__/ledger-root-builder.crossProductDedup.test.d.ts +0 -2
  78. package/dist/types/navigation/__test__/ledger-root-builder.crossProductDedup.test.d.ts.map +0 -1
  79. package/dist/types/navigation/__test__/ledger-root-builder.ledgerParity.test.d.ts +0 -2
  80. package/dist/types/navigation/__test__/ledger-root-builder.ledgerParity.test.d.ts.map +0 -1
  81. package/dist/types/navigation/__test__/ledger-root-builder.sidebarDepth.test.d.ts +0 -2
  82. package/dist/types/navigation/__test__/ledger-root-builder.sidebarDepth.test.d.ts.map +0 -1
  83. package/dist/types/navigation/__test__/ledger-root-builder.skipSlugGroupOrdering.test.d.ts +0 -2
  84. package/dist/types/navigation/__test__/ledger-root-builder.skipSlugGroupOrdering.test.d.ts.map +0 -1
  85. package/dist/types/navigation/__test__/ledger-root-builder.skipSlugSiblingSection.test.d.ts +0 -2
  86. package/dist/types/navigation/__test__/ledger-root-builder.skipSlugSiblingSection.test.d.ts.map +0 -1
  87. package/dist/types/navigation/utils/__test__/syntheticSectionPath.test.d.ts +0 -2
  88. package/dist/types/navigation/utils/__test__/syntheticSectionPath.test.d.ts.map +0 -1
  89. package/dist/types/navigation/utils/syntheticSectionPath.d.ts +0 -13
  90. package/dist/types/navigation/utils/syntheticSectionPath.d.ts.map +0 -1
@@ -1,360 +0,0 @@
1
- import { describe, expect, it } from "vitest";
2
- import * as FernNavigation from "../index.js";
3
- import { buildFullRootFromSegments } from "../ledger-root-builder.js";
4
- /**
5
- * Tests for the case where a section with skipUrlSlug (section="") sits inside
6
- * a sidebarGroup alongside sibling sections. The `childIndex` metadata field
7
- * (set by `walkNavSubTrees` on the write side) distinguishes these from true
8
- * root-section wrappers (direct sidebarRoot children with no childIndex).
9
- *
10
- * Without the fix, the builder treats ANY section="" segment as a root wrapper,
11
- * incorrectly nesting all depth-0 siblings under it and producing spurious
12
- * breadcrumb entries (e.g. "Introduction > Echo" instead of just "Echo").
13
- *
14
- * Real-world repro: mangopay-ledger-test, where the "Introduction" section
15
- * has skipUrlSlug (slug == tab slug) and shares a sidebarGroup with ~10 peer
16
- * sections (Users, Echo, SCA, Payouts, …).
17
- */
18
- function detail(opts) {
19
- return {
20
- id: opts.id,
21
- displayName: opts.name,
22
- icon: null,
23
- sortOrder: 0,
24
- hidden: false,
25
- viewers: [],
26
- orphaned: false,
27
- featureFlags: [],
28
- metadata: { slug: opts.slug, default: false, pointsTo: opts.pointsTo }
29
- };
30
- }
31
- function seg(opts) {
32
- return {
33
- segmentId: opts.segmentHash,
34
- segmentHash: opts.segmentHash,
35
- section: opts.section,
36
- locale: "en",
37
- sortOrder: opts.sortOrder ?? 0,
38
- hidden: false,
39
- metadata: {
40
- type: opts.type,
41
- ...(opts.title != null ? { title: opts.title } : {}),
42
- ...(opts.childIndex != null ? { childIndex: opts.childIndex } : {}),
43
- ...(opts.sidebarDepth != null ? { sidebarDepth: opts.sidebarDepth } : {})
44
- },
45
- product: null,
46
- version: null,
47
- variant: null,
48
- tab: opts.tab ?? null
49
- };
50
- }
51
- function markdownRoute(fullPath, title, pageId) {
52
- return { type: "markdown", fullPath, hidden: false, metadata: { title, pageId } };
53
- }
54
- function buildRoot(opts) {
55
- return buildFullRootFromSegments({
56
- basePath: opts.basePath,
57
- title: "Test",
58
- segments: opts.segments,
59
- navBySegment: opts.navBySegment
60
- });
61
- }
62
- function findSectionNodes(root) {
63
- const sections = [];
64
- FernNavigation.traverseDF(root, (node) => {
65
- if (node.type === "section") {
66
- sections.push(node);
67
- }
68
- });
69
- return sections;
70
- }
71
- function findSidebarRootChildren(root) {
72
- let sidebarChildren = [];
73
- FernNavigation.traverseDF(root, (node) => {
74
- if (node.type === "sidebarRoot" && sidebarChildren.length === 0) {
75
- sidebarChildren = [...node.children];
76
- }
77
- });
78
- return sidebarChildren;
79
- }
80
- describe("buildFullRootFromSegments — skipUrlSlug sibling sections are NOT adopted as root-section children", () => {
81
- // Reproduces the mangopay-ledger-test bug: "Introduction" (section="",
82
- // childIndex=0) shares a sidebarGroup with "Echo" and "Users".
83
- // Without the fix, "Echo" and "Users" are incorrectly nested inside
84
- // "Introduction", adding a spurious "Introduction" breadcrumb to every
85
- // page under Echo and Users.
86
- const tab = detail({
87
- id: "t-guides",
88
- name: "Guides",
89
- slug: "guides",
90
- pointsTo: "guides/e-wallet-system"
91
- });
92
- const tabRoot = seg({
93
- segmentHash: "s-tabroot",
94
- section: "",
95
- type: "tabRoot",
96
- tab
97
- });
98
- // "Introduction" section with skipUrlSlug — its slug matches the tab slug,
99
- // so the write side assigns section="" with childIndex=0 (from walkNavSubTrees).
100
- const introSection = seg({
101
- segmentHash: "s-intro",
102
- section: "",
103
- type: "section",
104
- title: "Introduction",
105
- sortOrder: 1,
106
- childIndex: 0,
107
- tab
108
- });
109
- // Sibling sections — these should NOT be nested inside Introduction.
110
- const echoSection = seg({
111
- segmentHash: "s-echo",
112
- section: "echo",
113
- type: "section",
114
- title: "Echo",
115
- sortOrder: 2,
116
- childIndex: 1,
117
- tab
118
- });
119
- const usersSection = seg({
120
- segmentHash: "s-users",
121
- section: "users",
122
- type: "section",
123
- title: "Users",
124
- sortOrder: 3,
125
- childIndex: 2,
126
- tab
127
- });
128
- const segments = [tabRoot, introSection, echoSection, usersSection];
129
- const navBySegment = new Map([
130
- ["s-tabroot", []],
131
- ["s-intro", [markdownRoute("guides/e-wallet-system", "E-wallet system", "pg-ewallet")]],
132
- [
133
- "s-echo",
134
- [
135
- markdownRoute("guides/echo", "Mangopay Echo", "pg-echo"),
136
- markdownRoute("guides/echo/reconciliation", "Reconciliation", "pg-recon")
137
- ]
138
- ],
139
- ["s-users", [markdownRoute("guides/users/types", "Types", "pg-user-types")]]
140
- ]);
141
- it("sections with childIndex remain siblings, not nested under section='' segment", () => {
142
- const root = buildRoot({ basePath: "", segments, navBySegment });
143
- const sections = findSectionNodes(root);
144
- const introSec = sections.find((s) => s.title === "Introduction");
145
- const echoSec = sections.find((s) => s.title === "Echo");
146
- const usersSec = sections.find((s) => s.title === "Users");
147
- expect(introSec).toBeDefined();
148
- expect(echoSec).toBeDefined();
149
- expect(usersSec).toBeDefined();
150
- // Echo and Users must NOT be children of Introduction.
151
- const introChildren = (introSec?.children ?? [])
152
- .filter((c) => c.type === "section")
153
- .map((c) => c.title);
154
- expect(introChildren).not.toContain("Echo");
155
- expect(introChildren).not.toContain("Users");
156
- // All three should be at the sidebar root level (possibly inside sidebarGroups).
157
- const sidebarChildren = findSidebarRootChildren(root);
158
- const topLevelTitles = [];
159
- for (const child of sidebarChildren) {
160
- if (child.type === "section") {
161
- topLevelTitles.push(child.title);
162
- }
163
- else if (child.type === "sidebarGroup") {
164
- for (const gc of child.children) {
165
- if (gc.type === "section") {
166
- topLevelTitles.push(gc.title);
167
- }
168
- }
169
- }
170
- }
171
- expect(topLevelTitles).toContain("Introduction");
172
- expect(topLevelTitles).toContain("Echo");
173
- expect(topLevelTitles).toContain("Users");
174
- });
175
- it("breadcrumb for a page inside Echo does NOT include Introduction", () => {
176
- const root = buildRoot({ basePath: "", segments, navBySegment });
177
- FernNavigation.utils.mutableUpdatePointsTo(root);
178
- const found = FernNavigation.utils.findNode(root, FernNavigation.Slug("guides/echo"));
179
- expect(found.type).toBe("found");
180
- if (found.type !== "found") {
181
- return;
182
- }
183
- const breadcrumbTitles = found.breadcrumb.map((b) => b.title);
184
- expect(breadcrumbTitles).toContain("Echo");
185
- expect(breadcrumbTitles).not.toContain("Introduction");
186
- });
187
- it("breadcrumb for a page inside Users does NOT include Introduction", () => {
188
- const root = buildRoot({ basePath: "", segments, navBySegment });
189
- FernNavigation.utils.mutableUpdatePointsTo(root);
190
- const found = FernNavigation.utils.findNode(root, FernNavigation.Slug("guides/users/types"));
191
- expect(found.type).toBe("found");
192
- if (found.type !== "found") {
193
- return;
194
- }
195
- const breadcrumbTitles = found.breadcrumb.map((b) => b.title);
196
- expect(breadcrumbTitles).toContain("Users");
197
- expect(breadcrumbTitles).not.toContain("Introduction");
198
- });
199
- });
200
- describe("buildFullRootFromSegments — nested subsections with sidebarDepth are not promoted to root level", () => {
201
- // Regression guard: when multiple skip-slug sections share sec="" and one
202
- // contains nested subsections (sidebarDepth > 0), the nested subsections
203
- // must stay under their parent — not be emitted as additional root children.
204
- // Without the fix, sections with sidebarDepth > 0 bypassed the adoption
205
- // skip (which only checked depth == null), causing duplication.
206
- const tab = detail({
207
- id: "t-docs",
208
- name: "Docs",
209
- slug: "docs",
210
- pointsTo: "docs/getting-started"
211
- });
212
- it("subsections with sidebarDepth > 0 stay nested under their parent skip-slug section", () => {
213
- const root = buildRoot({
214
- basePath: "",
215
- segments: [
216
- seg({
217
- segmentHash: "s-gs",
218
- section: "",
219
- type: "section",
220
- title: "Getting Started",
221
- sortOrder: 0,
222
- childIndex: 0,
223
- sidebarDepth: 0,
224
- tab
225
- }),
226
- seg({
227
- segmentHash: "s-dt",
228
- section: "",
229
- type: "section",
230
- title: "Dev Tools",
231
- sortOrder: 2,
232
- childIndex: 1,
233
- sidebarDepth: 0,
234
- tab
235
- }),
236
- seg({
237
- segmentHash: "s-cap",
238
- section: "",
239
- type: "section",
240
- title: "Capabilities",
241
- sortOrder: 4,
242
- childIndex: 2,
243
- sidebarDepth: 0,
244
- tab
245
- }),
246
- // Nested under Capabilities — these must NOT appear at root level
247
- seg({
248
- segmentHash: "s-parsing",
249
- section: "parsing",
250
- type: "section",
251
- title: "Parsing",
252
- sortOrder: 5,
253
- childIndex: 0,
254
- sidebarDepth: 1,
255
- tab
256
- }),
257
- seg({
258
- segmentHash: "s-extraction",
259
- section: "extraction",
260
- type: "section",
261
- title: "Extraction",
262
- sortOrder: 6,
263
- childIndex: 1,
264
- sidebarDepth: 1,
265
- tab
266
- })
267
- ],
268
- navBySegment: new Map([
269
- ["s-gs", [markdownRoute("docs/getting-started", "Intro", "pg-intro")]],
270
- ["s-dt", [markdownRoute("docs/dev-tools", "CLI", "pg-cli")]],
271
- ["s-cap", []],
272
- ["s-parsing", [markdownRoute("docs/parsing/overview", "Parsing Overview", "pg-parse")]],
273
- ["s-extraction", [markdownRoute("docs/extraction/overview", "Extraction Overview", "pg-extract")]]
274
- ])
275
- });
276
- const sidebarChildren = findSidebarRootChildren(root);
277
- const topLevelTitles = [];
278
- for (const child of sidebarChildren) {
279
- if (child.type === "section") {
280
- topLevelTitles.push(child.title);
281
- }
282
- else if (child.type === "sidebarGroup") {
283
- for (const gc of child.children) {
284
- if (gc.type === "section") {
285
- topLevelTitles.push(gc.title);
286
- }
287
- }
288
- }
289
- }
290
- // Only the three skip-slug root sections should appear at top level
291
- expect(topLevelTitles).toEqual(["Getting Started", "Dev Tools", "Capabilities"]);
292
- // Parsing and Extraction must be children of Capabilities, not root
293
- const sections = findSectionNodes(root);
294
- const capSec = sections.find((s) => s.title === "Capabilities");
295
- expect(capSec).toBeDefined();
296
- const capChildTitles = (capSec?.children ?? [])
297
- .filter((c) => c.type === "section")
298
- .map((c) => c.title);
299
- expect(capChildTitles).toContain("Parsing");
300
- expect(capChildTitles).toContain("Extraction");
301
- });
302
- });
303
- describe("buildFullRootFromSegments — true root-section wrappers (no childIndex) still work", () => {
304
- // Regression guard: when a section has section="" WITHOUT childIndex,
305
- // it IS a true root wrapper and should adopt depth-0 children.
306
- const tab = detail({
307
- id: "t-docs",
308
- name: "Docs",
309
- slug: "docs",
310
- pointsTo: "docs/overview/intro"
311
- });
312
- it("adopts depth-0 children when childIndex is absent", () => {
313
- const root = buildRoot({
314
- basePath: "",
315
- segments: [
316
- // True root section wrapper (no childIndex)
317
- seg({
318
- segmentHash: "s-root",
319
- section: "",
320
- type: "section",
321
- title: "Overview",
322
- tab
323
- }),
324
- seg({
325
- segmentHash: "s-gs",
326
- section: "get-started",
327
- type: "section",
328
- title: "Get Started",
329
- sortOrder: 1,
330
- tab
331
- }),
332
- seg({
333
- segmentHash: "s-adv",
334
- section: "advanced",
335
- type: "section",
336
- title: "Advanced",
337
- sortOrder: 2,
338
- tab
339
- })
340
- ],
341
- navBySegment: new Map([
342
- ["s-root", [markdownRoute("docs/overview/intro", "Intro", "pg-intro")]],
343
- ["s-gs", [markdownRoute("docs/overview/get-started/setup", "Setup", "pg-setup")]],
344
- ["s-adv", [markdownRoute("docs/overview/advanced/tips", "Tips", "pg-tips")]]
345
- ])
346
- });
347
- const sections = findSectionNodes(root);
348
- const overviewSec = sections.find((s) => s.title === "Overview");
349
- expect(overviewSec).toBeDefined();
350
- // Child sections should be nested under Overview (root wrapper behavior)
351
- const childTitles = (overviewSec?.children ?? [])
352
- .filter((c) => c.type === "section")
353
- .map((c) => c.title);
354
- expect(childTitles).toContain("Get Started");
355
- expect(childTitles).toContain("Advanced");
356
- // 3 total sections (Overview + Get Started + Advanced), not duplicated
357
- expect(sections.length).toBe(3);
358
- });
359
- });
360
- //# sourceMappingURL=ledger-root-builder.skipSlugSiblingSection.test.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"ledger-root-builder.skipSlugSiblingSection.test.js","sourceRoot":"","sources":["../../../src/navigation/__test__/ledger-root-builder.skipSlugSiblingSection.test.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,EAAE,EAAE,EAAE,MAAM,QAAQ,CAAC;AAE9C,OAAO,KAAK,cAAc,MAAM,aAAa,CAAC;AAC9C,OAAO,EAAE,yBAAyB,EAAE,MAAM,2BAA2B,CAAC;AAEtE;;;;;;;;;;;;;GAaG;AAEH,SAAS,MAAM,CAAC,IAAmE;IAC/E,OAAO;QACH,EAAE,EAAE,IAAI,CAAC,EAAE;QACX,WAAW,EAAE,IAAI,CAAC,IAAI;QACtB,IAAI,EAAE,IAAI;QACV,SAAS,EAAE,CAAC;QACZ,MAAM,EAAE,KAAK;QACb,OAAO,EAAE,EAAE;QACX,QAAQ,EAAE,KAAK;QACf,YAAY,EAAE,EAAE;QAChB,QAAQ,EAAE,EAAE,IAAI,EAAE,IAAI,CAAC,IAAI,EAAE,OAAO,EAAE,KAAK,EAAE,QAAQ,EAAE,IAAI,CAAC,QAAQ,EAAE;KACzE,CAAC;AACN,CAAC;AAaD,SAAS,GAAG,CAAC,IAAa;IACtB,OAAO;QACH,SAAS,EAAE,IAAI,CAAC,WAAW;QAC3B,WAAW,EAAE,IAAI,CAAC,WAAW;QAC7B,OAAO,EAAE,IAAI,CAAC,OAAO;QACrB,MAAM,EAAE,IAAI;QACZ,SAAS,EAAE,IAAI,CAAC,SAAS,IAAI,CAAC;QAC9B,MAAM,EAAE,KAAK;QACb,QAAQ,EAAE;YACN,IAAI,EAAE,IAAI,CAAC,IAAI;YACf,GAAG,CAAC,IAAI,CAAC,KAAK,IAAI,IAAI,CAAC,CAAC,CAAC,EAAE,KAAK,EAAE,IAAI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CAAC,CAAC;gBACjF,CAAC,OAAO,EAAE,CAAC,aAAa,CAAC,6BAA6B,EAAE,MAAM,EAAE,SAAS,CAAC,CAAC,CAAC;aAC/E,CAAC;SACL,CAAC,CAAC;QAEH,MAAM,QAAQ,GAAG,gBAAgB,CAAC,IAAI,CAAC,CAAC;QACxC,MAAM,WAAW,GAAG,QAAQ,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,KAAK,KAAK,UAAU,CAAC,CAAC;QACjE,MAAM,CAAC,WAAW,CAAC,CAAC,WAAW,EAAE,CAAC;QAElC,yEAAyE;QACzE,MAAM,WAAW,GAAG,CAAC,WAAW,EAAE,QAAQ,IAAI,EAAE,CAAC;aAC5C,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,IAAI,KAAK,SAAS,CAAC;aACnC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAE,CAAgC,CAAC,KAAK,CAAC,CAAC;QACzD,MAAM,CAAC,WAAW,CAAC,CAAC,SAAS,CAAC,aAAa,CAAC,CAAC;QAC7C,MAAM,CAAC,WAAW,CAAC,CAAC,SAAS,CAAC,UAAU,CAAC,CAAC;QAE1C,uEAAuE;QACvE,MAAM,CAAC,QAAQ,CAAC,MAAM,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;IACpC,CAAC,CAAC,CAAC;AACP,CAAC,CAAC,CAAC"}
@@ -1,2 +0,0 @@
1
- export {};
2
- //# sourceMappingURL=syntheticSectionPath.test.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"syntheticSectionPath.test.d.ts","sourceRoot":"","sources":["../../../../src/navigation/utils/__test__/syntheticSectionPath.test.ts"],"names":[],"mappings":""}
@@ -1,29 +0,0 @@
1
- import { describe, expect, it } from "vitest";
2
- import { stripSyntheticSegments } from "../syntheticSectionPath";
3
- describe("stripSyntheticSegments", () => {
4
- it("strips a single synthetic segment", () => {
5
- expect(stripSyntheticSegments("api-reference/~0")).toBe("api-reference");
6
- });
7
- it("strips multiple synthetic segments", () => {
8
- expect(stripSyntheticSegments("a/~0/b/~1/c")).toBe("a/b/c");
9
- });
10
- it("returns empty string for an entirely synthetic path", () => {
11
- expect(stripSyntheticSegments("~0/~1")).toBe("");
12
- });
13
- it("preserves non-numeric tilde slugs", () => {
14
- expect(stripSyntheticSegments("a/~beta/c")).toBe("a/~beta/c");
15
- });
16
- it("preserves a path with no synthetic segments", () => {
17
- expect(stripSyntheticSegments("api-reference/direct-card-payins")).toBe("api-reference/direct-card-payins");
18
- });
19
- it("handles empty string", () => {
20
- expect(stripSyntheticSegments("")).toBe("");
21
- });
22
- it("handles large childIndex values", () => {
23
- expect(stripSyntheticSegments("parent/~999/child")).toBe("parent/child");
24
- });
25
- it("preserves tilde in the middle of a segment", () => {
26
- expect(stripSyntheticSegments("a/foo~bar/c")).toBe("a/foo~bar/c");
27
- });
28
- });
29
- //# sourceMappingURL=syntheticSectionPath.test.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"syntheticSectionPath.test.js","sourceRoot":"","sources":["../../../../src/navigation/utils/__test__/syntheticSectionPath.test.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,EAAE,EAAE,EAAE,MAAM,QAAQ,CAAC;AAC9C,OAAO,EAAE,sBAAsB,EAAE,MAAM,yBAAyB,CAAC;AAEjE,QAAQ,CAAC,wBAAwB,EAAE,GAAG,EAAE;IACpC,EAAE,CAAC,mCAAmC,EAAE,GAAG,EAAE;QACzC,MAAM,CAAC,sBAAsB,CAAC,kBAAkB,CAAC,CAAC,CAAC,IAAI,CAAC,eAAe,CAAC,CAAC;IAC7E,CAAC,CAAC,CAAC;IAEH,EAAE,CAAC,oCAAoC,EAAE,GAAG,EAAE;QAC1C,MAAM,CAAC,sBAAsB,CAAC,aAAa,CAAC,CAAC,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;IAChE,CAAC,CAAC,CAAC;IAEH,EAAE,CAAC,qDAAqD,EAAE,GAAG,EAAE;QAC3D,MAAM,CAAC,sBAAsB,CAAC,OAAO,CAAC,CAAC,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;IACrD,CAAC,CAAC,CAAC;IAEH,EAAE,CAAC,mCAAmC,EAAE,GAAG,EAAE;QACzC,MAAM,CAAC,sBAAsB,CAAC,WAAW,CAAC,CAAC,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC;IAClE,CAAC,CAAC,CAAC;IAEH,EAAE,CAAC,6CAA6C,EAAE,GAAG,EAAE;QACnD,MAAM,CAAC,sBAAsB,CAAC,kCAAkC,CAAC,CAAC,CAAC,IAAI,CAAC,kCAAkC,CAAC,CAAC;IAChH,CAAC,CAAC,CAAC;IAEH,EAAE,CAAC,sBAAsB,EAAE,GAAG,EAAE;QAC5B,MAAM,CAAC,sBAAsB,CAAC,EAAE,CAAC,CAAC,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;IAChD,CAAC,CAAC,CAAC;IAEH,EAAE,CAAC,iCAAiC,EAAE,GAAG,EAAE;QACvC,MAAM,CAAC,sBAAsB,CAAC,mBAAmB,CAAC,CAAC,CAAC,IAAI,CAAC,cAAc,CAAC,CAAC;IAC7E,CAAC,CAAC,CAAC;IAEH,EAAE,CAAC,4CAA4C,EAAE,GAAG,EAAE;QAClD,MAAM,CAAC,sBAAsB,CAAC,aAAa,CAAC,CAAC,CAAC,IAAI,CAAC,aAAa,CAAC,CAAC;IACtE,CAAC,CAAC,CAAC;AACP,CAAC,CAAC,CAAC"}
@@ -1,13 +0,0 @@
1
- /**
2
- * Synthetic section-path segments disambiguate skipUrlSlug nodes in the
3
- * flat ledger segment model. When a node shares its parent's slug
4
- * (skipUrlSlug), the publish transform assigns a section path like
5
- * `parent/~3` instead of `parent`. The read side (ledger-root-builder)
6
- * strips these synthetic components when computing URL slugs so they
7
- * never appear in rendered navigation.
8
- */
9
- /** Prefix for synthetic section-path segments. */
10
- export declare const SKIP_URL_SLUG_PREFIX = "~";
11
- /** Strip synthetic `~<n>` path components used for skipUrlSlug disambiguation. */
12
- export declare function stripSyntheticSegments(section: string): string;
13
- //# sourceMappingURL=syntheticSectionPath.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"syntheticSectionPath.d.ts","sourceRoot":"","sources":["../../../src/navigation/utils/syntheticSectionPath.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,kDAAkD;AAClD,eAAO,MAAM,oBAAoB,MAAM,CAAC;AAKxC,kFAAkF;AAClF,wBAAgB,sBAAsB,CAAC,OAAO,EAAE,MAAM,GAAG,MAAM,CAK9D"}
@@ -1,20 +0,0 @@
1
- /**
2
- * Synthetic section-path segments disambiguate skipUrlSlug nodes in the
3
- * flat ledger segment model. When a node shares its parent's slug
4
- * (skipUrlSlug), the publish transform assigns a section path like
5
- * `parent/~3` instead of `parent`. The read side (ledger-root-builder)
6
- * strips these synthetic components when computing URL slugs so they
7
- * never appear in rendered navigation.
8
- */
9
- /** Prefix for synthetic section-path segments. */
10
- export const SKIP_URL_SLUG_PREFIX = "~";
11
- /** Pattern matching a synthetic segment: the prefix followed by one or more digits. */
12
- const SYNTHETIC_SEGMENT_RE = /^~\d+$/;
13
- /** Strip synthetic `~<n>` path components used for skipUrlSlug disambiguation. */
14
- export function stripSyntheticSegments(section) {
15
- return section
16
- .split("/")
17
- .filter((part) => !SYNTHETIC_SEGMENT_RE.test(part))
18
- .join("/");
19
- }
20
- //# sourceMappingURL=syntheticSectionPath.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"syntheticSectionPath.js","sourceRoot":"","sources":["../../../src/navigation/utils/syntheticSectionPath.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,kDAAkD;AAClD,MAAM,CAAC,MAAM,oBAAoB,GAAG,GAAG,CAAC;AAExC,uFAAuF;AACvF,MAAM,oBAAoB,GAAG,QAAQ,CAAC;AAEtC,kFAAkF;AAClF,MAAM,UAAU,sBAAsB,CAAC,OAAe;IAClD,OAAO,OAAO;SACT,KAAK,CAAC,GAAG,CAAC;SACV,MAAM,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,CAAC,oBAAoB,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;SAClD,IAAI,CAAC,GAAG,CAAC,CAAC;AACnB,CAAC"}
@@ -1,2 +0,0 @@
1
- export {};
2
- //# sourceMappingURL=ledger-root-builder.crossProductDedup.test.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"ledger-root-builder.crossProductDedup.test.d.ts","sourceRoot":"","sources":["../../../../src/navigation/__test__/ledger-root-builder.crossProductDedup.test.ts"],"names":[],"mappings":""}
@@ -1,2 +0,0 @@
1
- export {};
2
- //# sourceMappingURL=ledger-root-builder.ledgerParity.test.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"ledger-root-builder.ledgerParity.test.d.ts","sourceRoot":"","sources":["../../../../src/navigation/__test__/ledger-root-builder.ledgerParity.test.ts"],"names":[],"mappings":""}
@@ -1,2 +0,0 @@
1
- export {};
2
- //# sourceMappingURL=ledger-root-builder.sidebarDepth.test.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"ledger-root-builder.sidebarDepth.test.d.ts","sourceRoot":"","sources":["../../../../src/navigation/__test__/ledger-root-builder.sidebarDepth.test.ts"],"names":[],"mappings":""}
@@ -1,2 +0,0 @@
1
- export {};
2
- //# sourceMappingURL=ledger-root-builder.skipSlugGroupOrdering.test.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"ledger-root-builder.skipSlugGroupOrdering.test.d.ts","sourceRoot":"","sources":["../../../../src/navigation/__test__/ledger-root-builder.skipSlugGroupOrdering.test.ts"],"names":[],"mappings":""}
@@ -1,2 +0,0 @@
1
- export {};
2
- //# sourceMappingURL=ledger-root-builder.skipSlugSiblingSection.test.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"ledger-root-builder.skipSlugSiblingSection.test.d.ts","sourceRoot":"","sources":["../../../../src/navigation/__test__/ledger-root-builder.skipSlugSiblingSection.test.ts"],"names":[],"mappings":""}
@@ -1,2 +0,0 @@
1
- export {};
2
- //# sourceMappingURL=syntheticSectionPath.test.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"syntheticSectionPath.test.d.ts","sourceRoot":"","sources":["../../../../../src/navigation/utils/__test__/syntheticSectionPath.test.ts"],"names":[],"mappings":""}
@@ -1,13 +0,0 @@
1
- /**
2
- * Synthetic section-path segments disambiguate skipUrlSlug nodes in the
3
- * flat ledger segment model. When a node shares its parent's slug
4
- * (skipUrlSlug), the publish transform assigns a section path like
5
- * `parent/~3` instead of `parent`. The read side (ledger-root-builder)
6
- * strips these synthetic components when computing URL slugs so they
7
- * never appear in rendered navigation.
8
- */
9
- /** Prefix for synthetic section-path segments. */
10
- export declare const SKIP_URL_SLUG_PREFIX = "~";
11
- /** Strip synthetic `~<n>` path components used for skipUrlSlug disambiguation. */
12
- export declare function stripSyntheticSegments(section: string): string;
13
- //# sourceMappingURL=syntheticSectionPath.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"syntheticSectionPath.d.ts","sourceRoot":"","sources":["../../../../src/navigation/utils/syntheticSectionPath.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,kDAAkD;AAClD,eAAO,MAAM,oBAAoB,MAAM,CAAC;AAKxC,kFAAkF;AAClF,wBAAgB,sBAAsB,CAAC,OAAO,EAAE,MAAM,GAAG,MAAM,CAK9D"}