@supernova-studio/client 0.48.34 → 0.48.36
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/package.json
CHANGED
|
@@ -1,12 +1,11 @@
|
|
|
1
1
|
import {
|
|
2
|
+
DocumentationGroupV1,
|
|
2
3
|
DocumentationItemConfigurationV1,
|
|
3
4
|
DocumentationItemConfigurationV2,
|
|
4
|
-
DocumentationGroupV1,
|
|
5
5
|
DocumentationPageV1,
|
|
6
6
|
DocumentationPageV2,
|
|
7
7
|
ElementGroup,
|
|
8
8
|
mapByUnique,
|
|
9
|
-
slugify,
|
|
10
9
|
} from "@supernova-studio/model";
|
|
11
10
|
|
|
12
11
|
type GroupLike = {
|
|
@@ -32,13 +31,13 @@ export function buildDocPagePublishPaths(
|
|
|
32
31
|
const parentChain = calculateElementParentChain(page.parentPersistentId, groupPersistentIdToGroupMap);
|
|
33
32
|
|
|
34
33
|
let pathV1 = `${page.userSlug || page.slug}.html`;
|
|
35
|
-
let pathV2 = `${
|
|
34
|
+
let pathV2 = `${page.slug}-${page.shortPersistentId}`;
|
|
36
35
|
|
|
37
36
|
for (const parent of parentChain) {
|
|
38
37
|
if (!parent.parentPersistentId) continue;
|
|
39
38
|
|
|
40
|
-
pathV1 = `${parent.userSlug || parent.slug}/${pathV1}`;
|
|
41
|
-
pathV2 = `${
|
|
39
|
+
pathV1 = `${parent.userSlug || parent.slug || "root"}/${pathV1}`;
|
|
40
|
+
pathV2 = `${parent.slug || "root"}/${pathV2}`;
|
|
42
41
|
}
|
|
43
42
|
|
|
44
43
|
pathV1 = `/${pathV1}`;
|