@supernova-studio/client 0.47.30 → 0.47.32
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/index.d.mts +190 -190
- package/dist/index.d.ts +190 -190
- package/dist/index.js +10 -5
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +10 -5
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
- package/src/api/conversion/documentation/documentation-group-v1-to-dto.ts +5 -1
- package/src/api/conversion/documentation/documentation-page-v1-to-dto.ts +5 -2
- package/src/api/dto/elements/documentation/group-v2.ts +1 -1
- package/src/api/dto/elements/documentation/page-v2.ts +1 -2
package/package.json
CHANGED
|
@@ -54,9 +54,13 @@ export function elementGroupsToDocumentationGroupFixedConfigurationDTOV1(
|
|
|
54
54
|
>(pages, groups, getDtoDefaultItemConfigurationV1);
|
|
55
55
|
|
|
56
56
|
return fixedGroups.map(group => {
|
|
57
|
+
const configuration = documentationItemConfigurationToDTOV1(group.data?.configuration);
|
|
58
|
+
|
|
57
59
|
return {
|
|
58
60
|
...elementGroupToDocumentationGroupStructureDTOV1(group, childrenIdsMap),
|
|
59
|
-
|
|
61
|
+
// backward compatibility with custom doc exporters, anyway these groups will not be shown, so we can adjust title
|
|
62
|
+
title: configuration.isHidden && !group.meta.name.startsWith("_") ? "_" + group.meta.name : group.meta.name,
|
|
63
|
+
configuration,
|
|
60
64
|
};
|
|
61
65
|
});
|
|
62
66
|
}
|
|
@@ -49,16 +49,19 @@ function documentationPageToDTOV1(page: DocumentationPageV1, pagePathMap: Map<st
|
|
|
49
49
|
|
|
50
50
|
if (path.startsWith("/")) path = path.substring(1);
|
|
51
51
|
|
|
52
|
+
const configuration = documentationItemConfigurationToDTOV1(page.data.configuration);
|
|
53
|
+
|
|
52
54
|
return {
|
|
53
55
|
id: page.id,
|
|
54
56
|
designSystemVersionId: page.designSystemVersionId,
|
|
55
57
|
persistentId: page.persistentId,
|
|
56
58
|
shortPersistentId: page.shortPersistentId,
|
|
57
|
-
|
|
59
|
+
// backward compatibility with custom doc exporters, anyway these pages will not be shown, so we can adjust title
|
|
60
|
+
title: configuration.isHidden && !page.meta.name.startsWith("_") ? "_" + page.meta.name : page.meta.name,
|
|
58
61
|
blocks: page.data.blocks,
|
|
59
62
|
slug: page.slug,
|
|
60
63
|
userSlug: page.userSlug,
|
|
61
|
-
configuration
|
|
64
|
+
configuration,
|
|
62
65
|
createdAt: page.createdAt,
|
|
63
66
|
updatedAt: page.updatedAt,
|
|
64
67
|
path: path,
|
|
@@ -42,7 +42,7 @@ export const DTOCreateDocumentationGroupInput = z.object({
|
|
|
42
42
|
|
|
43
43
|
// Group properties
|
|
44
44
|
title: z.string(),
|
|
45
|
-
configuration: DTODocumentationItemConfigurationV2.optional(),
|
|
45
|
+
configuration: DTODocumentationItemConfigurationV2.partial().optional(),
|
|
46
46
|
|
|
47
47
|
// Group placement properties
|
|
48
48
|
afterPersistentId: z.string().uuid().nullish(),
|
|
@@ -33,7 +33,6 @@ export const DTODocumentationHierarchyV2 = z.object({
|
|
|
33
33
|
|
|
34
34
|
export type DTODocumentationHierarchyV2 = z.infer<typeof DTODocumentationHierarchyV2>;
|
|
35
35
|
|
|
36
|
-
|
|
37
36
|
//
|
|
38
37
|
// Write
|
|
39
38
|
//
|
|
@@ -44,7 +43,7 @@ export const DTOCreateDocumentationPageInputV2 = z.object({
|
|
|
44
43
|
|
|
45
44
|
// Page properties
|
|
46
45
|
title: z.string(),
|
|
47
|
-
configuration: DTODocumentationItemConfigurationV2.optional(),
|
|
46
|
+
configuration: DTODocumentationItemConfigurationV2.partial().optional(),
|
|
48
47
|
|
|
49
48
|
// Page placement properties
|
|
50
49
|
parentPersistentId: z.string().uuid(),
|