@supernova-studio/client 0.17.0 → 0.19.1

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.mjs CHANGED
@@ -982,7 +982,12 @@ var PageBlockItemDividerValue = z34.object({});
982
982
  var PageBlockItemEmbedValue = z34.object({
983
983
  value: z34.string().optional(),
984
984
  caption: z34.string().optional(),
985
- height: z34.number().optional()
985
+ height: z34.number().optional(),
986
+ openGraph: z34.object({
987
+ title: z34.string().optional(),
988
+ description: z34.string().optional(),
989
+ imageUrl: z34.string().optional()
990
+ }).optional()
986
991
  });
987
992
  var PageBlockItemFigmaNodeValue = z34.object({
988
993
  selectedPropertyIds: z34.array(z34.string()).optional(),
@@ -2608,19 +2613,29 @@ var DesignSystemVersionRoom = Entity.extend({
2608
2613
  });
2609
2614
  var DesignSystemVersionRoomInitialState = z119.object({
2610
2615
  pages: z119.array(DocumentationPageV2),
2611
- groups: z119.array(ElementGroup),
2612
- deletedPagePersistentIds: z119.array(z119.string()),
2613
- deletedGroupPersistentIds: z119.array(z119.string())
2616
+ groups: z119.array(ElementGroup)
2614
2617
  });
2615
2618
  var DesignSystemVersionRoomUpdate = DesignSystemVersionRoomInitialState.extend({
2616
- deletedPagePersistentIds: z119.array(z119.string()),
2617
- deletedGroupPersistentIds: z119.array(z119.string())
2619
+ deletedPageIds: z119.array(z119.string()),
2620
+ deletedGroupIds: z119.array(z119.string())
2618
2621
  });
2619
2622
  var DocumentationPageRoom = Entity.extend({
2620
2623
  designSystemVersionId: z120.string(),
2621
2624
  documentationPageId: z120.string(),
2622
2625
  liveblocksId: z120.string()
2623
2626
  });
2627
+ var PageBlockEditorModel = z120.object({
2628
+ id: z120.string(),
2629
+ data: PageBlockDataV2
2630
+ });
2631
+ var DocumentationPageRoomRoomUpdate = z120.object({
2632
+ page: DocumentationPageV2,
2633
+ pageParent: ElementGroup
2634
+ });
2635
+ var DocumentationPageRoomInitialState = DocumentationPageRoomRoomUpdate.extend({
2636
+ pageBlocks: z120.array(PageBlockEditorModel),
2637
+ blockDefinitions: z120.array(PageBlockDefinition)
2638
+ });
2624
2639
  var RoomTypeEnum = /* @__PURE__ */ ((RoomTypeEnum2) => {
2625
2640
  RoomTypeEnum2["DocumentationPage"] = "documentation-page";
2626
2641
  RoomTypeEnum2["DesignSystemVersion"] = "design-system-version";
@@ -3455,7 +3470,8 @@ function documentationPageToStructureDTOV2(page, pagePathMap) {
3455
3470
  userSlug: page.userSlug,
3456
3471
  createdAt: page.createdAt,
3457
3472
  updatedAt: page.updatedAt,
3458
- path
3473
+ path,
3474
+ type: "Page"
3459
3475
  };
3460
3476
  }
3461
3477
 
@@ -3493,7 +3509,8 @@ function elementGroupToDocumentationGroupStructureDTO(group, childrenIdsMap) {
3493
3509
  childrenIds,
3494
3510
  isRoot: !group.parentPersistentId,
3495
3511
  groupBehavior: group.data?.behavior ?? "Group",
3496
- shortPersistentId: group.shortPersistentId
3512
+ shortPersistentId: group.shortPersistentId,
3513
+ type: "Group"
3497
3514
  };
3498
3515
  }
3499
3516
  function calculateChildrenIdsMap(elements, groups) {
@@ -3574,7 +3591,8 @@ var DTODocumentationGroupStructure = ElementGroup.omit({
3574
3591
  isRoot: z126.boolean(),
3575
3592
  childrenIds: z126.array(z126.string()),
3576
3593
  groupBehavior: DocumentationGroupBehavior,
3577
- shortPersistentId: z126.string()
3594
+ shortPersistentId: z126.string(),
3595
+ type: z126.literal("Group")
3578
3596
  });
3579
3597
  var DTODocumentationGroup = DTODocumentationGroupStructure.extend({
3580
3598
  configuration: DocumentationItemConfiguration
@@ -3597,6 +3615,13 @@ var DTOUpdateDocumentationGroupInput = z126.object({
3597
3615
  title: z126.string().optional(),
3598
3616
  configuration: DocumentationItemConfiguration.optional()
3599
3617
  });
3618
+ var DTOMoveDocumentationGroupInput = z126.object({
3619
+ // Identifier of the group to update
3620
+ id: z126.string().uuid(),
3621
+ // Group placement properties
3622
+ afterPersistentId: z126.string().uuid(),
3623
+ parentPersistentId: z126.string().uuid()
3624
+ });
3600
3625
  var DTODuplicateDocumentationGroupInput = z126.object({
3601
3626
  // Identifier of the group to duplicate from
3602
3627
  id: z126.string(),
@@ -3606,6 +3631,17 @@ var DTODuplicateDocumentationGroupInput = z126.object({
3606
3631
  afterPersistentId: z126.string().uuid().optional(),
3607
3632
  parentPersistentId: z126.string().uuid()
3608
3633
  });
3634
+ var DTOCreateDocumentationTabGroupInput = z126.object({
3635
+ // New group persistent id
3636
+ persistentId: z126.string().uuid(),
3637
+ // Page that will become first tab of the tab group
3638
+ fromPageId: z126.string(),
3639
+ tabName: z126.string()
3640
+ });
3641
+ var DTODeleteDocumentationTabGroupInput = z126.object({
3642
+ // Deleted group id
3643
+ id: z126.string()
3644
+ });
3609
3645
  var DTODeleteDocumentationGroupInput = z126.object({
3610
3646
  // Identifier
3611
3647
  id: z126.string(),
@@ -3614,21 +3650,28 @@ var DTODeleteDocumentationGroupInput = z126.object({
3614
3650
  });
3615
3651
 
3616
3652
  // src/api/dto/elements/documentation/group-action.ts
3653
+ var SuccessPayload = z127.object({
3654
+ success: z127.literal(true)
3655
+ });
3617
3656
  var DTODocumentationGroupCreateActionOutputV2 = z127.object({
3618
3657
  type: z127.literal("DocumentationGroupCreate"),
3619
- output: DTODocumentationGroup
3658
+ output: SuccessPayload
3620
3659
  });
3621
3660
  var DTODocumentationGroupUpdateActionOutputV2 = z127.object({
3622
3661
  type: z127.literal("DocumentationGroupUpdate"),
3623
- output: DTODocumentationGroup
3662
+ output: SuccessPayload
3663
+ });
3664
+ var DTODocumentationGroupMoveActionOutputV2 = z127.object({
3665
+ type: z127.literal("DocumentationGroupMove"),
3666
+ output: SuccessPayload
3624
3667
  });
3625
3668
  var DTODocumentationGroupDuplicateActionOutputV2 = z127.object({
3626
3669
  type: z127.literal("DocumentationGroupDuplicate"),
3627
- output: DTODocumentationGroup
3670
+ output: SuccessPayload
3628
3671
  });
3629
3672
  var DTODocumentationGroupDeleteActionOutputV2 = z127.object({
3630
3673
  type: z127.literal("DocumentationGroupDelete"),
3631
- output: z127.string()
3674
+ output: SuccessPayload
3632
3675
  });
3633
3676
  var DTODocumentationGroupCreateActionInputV2 = z127.object({
3634
3677
  type: z127.literal("DocumentationGroupCreate"),
@@ -3638,6 +3681,10 @@ var DTODocumentationGroupUpdateActionInputV2 = z127.object({
3638
3681
  type: z127.literal("DocumentationGroupUpdate"),
3639
3682
  input: DTOUpdateDocumentationGroupInput
3640
3683
  });
3684
+ var DTODocumentationGroupMoveActionInputV2 = z127.object({
3685
+ type: z127.literal("DocumentationGroupMove"),
3686
+ input: DTOMoveDocumentationGroupInput
3687
+ });
3641
3688
  var DTODocumentationGroupDuplicateActionInputV2 = z127.object({
3642
3689
  type: z127.literal("DocumentationGroupDuplicate"),
3643
3690
  input: DTODuplicateDocumentationGroupInput
@@ -3647,181 +3694,164 @@ var DTODocumentationGroupDeleteActionInputV2 = z127.object({
3647
3694
  input: DTODeleteDocumentationGroupInput
3648
3695
  });
3649
3696
 
3650
- // src/api/dto/elements/documentation/group-bulk-action.ts
3651
- import { z as z128 } from "zod";
3652
- var DTODocumentationGroupBulkActionOutputV2 = z128.object({
3653
- created: z128.array(DTODocumentationGroup),
3654
- updated: z128.array(DTODocumentationGroup),
3655
- deleted: z128.array(z128.string())
3656
- });
3657
- var DTODocumentationGroupBulkActionInputV2 = z128.object({
3658
- create: z128.array(DTOCreateDocumentationGroupInput).optional(),
3659
- update: z128.array(DTOUpdateDocumentationGroupInput).optional(),
3660
- duplicate: z128.array(DTODuplicateDocumentationGroupInput).optional(),
3661
- delete: z128.array(z128.string()).optional()
3662
- });
3663
-
3664
3697
  // src/api/dto/elements/documentation/page-actions-v2.ts
3665
- import { z as z130 } from "zod";
3698
+ import { z as z129 } from "zod";
3666
3699
 
3667
3700
  // src/api/dto/elements/documentation/page-v2.ts
3668
- import { z as z129 } from "zod";
3701
+ import { z as z128 } from "zod";
3669
3702
  var DTODocumentationPageStructureV2 = DocumentationPageV2.omit({
3670
3703
  data: true,
3671
3704
  meta: true,
3672
3705
  parentPersistentId: true,
3673
3706
  sortOrder: true
3674
3707
  }).extend({
3675
- title: z129.string(),
3676
- path: z129.string()
3708
+ title: z128.string(),
3709
+ path: z128.string(),
3710
+ type: z128.literal("Page")
3677
3711
  });
3678
3712
  var DTODocumentationPageV2 = DTODocumentationPageStructureV2.extend({
3679
3713
  configuration: DocumentationItemConfiguration
3680
3714
  });
3681
- var DTODocumentationHierarchyV2 = z129.object({
3682
- pages: z129.array(DTODocumentationPageStructureV2),
3683
- groups: z129.array(DTODocumentationGroupStructure)
3715
+ var DTODocumentationHierarchyV2 = z128.object({
3716
+ pages: z128.array(DTODocumentationPageStructureV2),
3717
+ groups: z128.array(DTODocumentationGroupStructure)
3684
3718
  });
3685
- var DTOCreateDocumentationPageInputV2 = z129.object({
3719
+ var DTOCreateDocumentationPageInputV2 = z128.object({
3686
3720
  // Identifier
3687
- persistentId: z129.string().uuid(),
3721
+ persistentId: z128.string().uuid(),
3688
3722
  // Page properties
3689
- title: z129.string(),
3723
+ title: z128.string(),
3690
3724
  configuration: DocumentationItemConfiguration.optional(),
3691
3725
  // Page placement properties
3692
- parentPersistentId: z129.string().uuid(),
3693
- afterPersistentId: z129.string().uuid().optional()
3726
+ parentPersistentId: z128.string().uuid(),
3727
+ afterPersistentId: z128.string().uuid().optional()
3694
3728
  });
3695
- var DTOUpdateDocumentationPageInputV2 = z129.object({
3729
+ var DTOUpdateDocumentationPageInputV2 = z128.object({
3696
3730
  // Identifier of the group to update
3697
- id: z129.string(),
3731
+ id: z128.string(),
3698
3732
  // Page properties
3699
- title: z129.string().optional(),
3700
- configuration: DocumentationItemConfiguration.optional(),
3733
+ title: z128.string().optional(),
3734
+ configuration: DocumentationItemConfiguration.optional()
3735
+ });
3736
+ var DTOMoveDocumentationPageInputV2 = z128.object({
3737
+ // Identifier of the group to update
3738
+ id: z128.string(),
3701
3739
  // Page placement properties
3702
- parentPersistentId: z129.string().optional(),
3703
- afterPersistentId: z129.string().optional()
3740
+ parentPersistentId: z128.string().uuid(),
3741
+ afterPersistentId: z128.string().uuid()
3704
3742
  });
3705
- var DTODuplicateDocumentationPageInputV2 = z129.object({
3743
+ var DTODuplicateDocumentationPageInputV2 = z128.object({
3706
3744
  // Identifier of the page to duplicate from
3707
- id: z129.string(),
3745
+ id: z128.string(),
3708
3746
  // New page persistent id
3709
- persistentId: z129.string().uuid(),
3747
+ persistentId: z128.string().uuid(),
3710
3748
  // Page placement properties
3711
- parentPersistentId: z129.string().uuid(),
3712
- afterPersistentId: z129.string().uuid().optional()
3749
+ parentPersistentId: z128.string().uuid(),
3750
+ afterPersistentId: z128.string().uuid().optional()
3713
3751
  });
3714
- var DTODeleteDocumentationPageInputV2 = z129.object({
3752
+ var DTODeleteDocumentationPageInputV2 = z128.object({
3715
3753
  // Identifier
3716
- id: z129.string()
3754
+ id: z128.string()
3717
3755
  });
3718
3756
 
3719
3757
  // src/api/dto/elements/documentation/page-actions-v2.ts
3720
- var DTODocumentationPageCreateActionOutputV2 = z130.object({
3721
- type: z130.literal("DocumentationPageCreate"),
3722
- output: DTODocumentationPageV2
3758
+ var SuccessPayload2 = z129.object({
3759
+ success: z129.literal(true)
3723
3760
  });
3724
- var DTODocumentationPageUpdateActionOutputV2 = z130.object({
3725
- type: z130.literal("DocumentationPageUpdate"),
3726
- output: DTODocumentationPageV2
3761
+ var DTODocumentationPageCreateActionOutputV2 = z129.object({
3762
+ type: z129.literal("DocumentationPageCreate"),
3763
+ output: SuccessPayload2
3727
3764
  });
3728
- var DTODocumentationPageDuplicateActionOutputV2 = z130.object({
3729
- type: z130.literal("DocumentationPageDuplicate"),
3730
- output: DTODocumentationPageV2
3765
+ var DTODocumentationPageUpdateActionOutputV2 = z129.object({
3766
+ type: z129.literal("DocumentationPageUpdate"),
3767
+ output: SuccessPayload2
3731
3768
  });
3732
- var DTODocumentationPageDeleteActionOutputV2 = z130.object({
3733
- type: z130.literal("DocumentationPageDelete"),
3734
- output: z130.string()
3769
+ var DTODocumentationPageMoveActionOutputV2 = z129.object({
3770
+ type: z129.literal("DocumentationPageMove"),
3771
+ output: SuccessPayload2
3735
3772
  });
3736
- var DTODocumentationPageCreateActionInputV2 = z130.object({
3737
- type: z130.literal("DocumentationPageCreate"),
3773
+ var DTODocumentationPageDuplicateActionOutputV2 = z129.object({
3774
+ type: z129.literal("DocumentationPageDuplicate"),
3775
+ output: SuccessPayload2
3776
+ });
3777
+ var DTODocumentationPageDeleteActionOutputV2 = z129.object({
3778
+ type: z129.literal("DocumentationPageDelete"),
3779
+ output: SuccessPayload2
3780
+ });
3781
+ var DTODocumentationPageCreateActionInputV2 = z129.object({
3782
+ type: z129.literal("DocumentationPageCreate"),
3738
3783
  input: DTOCreateDocumentationPageInputV2
3739
3784
  });
3740
- var DTODocumentationPageUpdateActionInputV2 = z130.object({
3741
- type: z130.literal("DocumentationPageUpdate"),
3785
+ var DTODocumentationPageUpdateActionInputV2 = z129.object({
3786
+ type: z129.literal("DocumentationPageUpdate"),
3742
3787
  input: DTOUpdateDocumentationPageInputV2
3743
3788
  });
3744
- var DTODocumentationPageDuplicateActionInputV2 = z130.object({
3745
- type: z130.literal("DocumentationPageDuplicate"),
3789
+ var DTODocumentationPageMoveActionInputV2 = z129.object({
3790
+ type: z129.literal("DocumentationPageMove"),
3791
+ input: DTOMoveDocumentationPageInputV2
3792
+ });
3793
+ var DTODocumentationPageDuplicateActionInputV2 = z129.object({
3794
+ type: z129.literal("DocumentationPageDuplicate"),
3746
3795
  input: DTODuplicateDocumentationPageInputV2
3747
3796
  });
3748
- var DTODocumentationPageDeleteActionInputV2 = z130.object({
3749
- type: z130.literal("DocumentationPageDelete"),
3797
+ var DTODocumentationPageDeleteActionInputV2 = z129.object({
3798
+ type: z129.literal("DocumentationPageDelete"),
3750
3799
  input: DTODeleteDocumentationPageInputV2
3751
3800
  });
3752
3801
 
3753
- // src/api/dto/elements/documentation/page-bulk-action-v2.ts
3754
- import { z as z131 } from "zod";
3755
- var DTODocumentationPageBulkActionOutputV2 = z131.object({
3756
- created: z131.array(DTODocumentationPageV2),
3757
- updated: z131.array(DTODocumentationPageV2),
3758
- deleted: z131.array(z131.string())
3759
- });
3760
- var DTODocumentationPageBulkActionInputV2 = z131.object({
3761
- create: z131.array(DTOCreateDocumentationPageInputV2).optional(),
3762
- update: z131.array(DTOUpdateDocumentationPageInputV2).optional(),
3763
- duplicate: z131.array(DTODuplicateDocumentationPageInputV2).optional(),
3764
- delete: z131.array(DTODeleteDocumentationPageInputV2).optional()
3765
- });
3766
-
3767
3802
  // src/api/dto/elements/documentation/page-v1.ts
3768
- import { z as z132 } from "zod";
3803
+ import { z as z130 } from "zod";
3769
3804
  var DocumentationPageV1DTO = DocumentationPageV1.omit({
3770
3805
  data: true,
3771
3806
  meta: true,
3772
3807
  parentPersistentId: true,
3773
3808
  sortOrder: true
3774
3809
  }).extend(DocumentationPageV1.shape.data.shape).extend({
3775
- title: z132.string(),
3776
- path: z132.string()
3810
+ title: z130.string(),
3811
+ path: z130.string()
3777
3812
  });
3778
3813
 
3779
3814
  // src/api/dto/elements/elements-action-v2.ts
3780
- import { z as z133 } from "zod";
3781
- var DTOElementActionOutput = z133.discriminatedUnion("type", [
3815
+ import { z as z131 } from "zod";
3816
+ var DTOElementActionOutput = z131.discriminatedUnion("type", [
3782
3817
  // Documentation pages
3783
3818
  DTODocumentationPageCreateActionOutputV2,
3784
3819
  DTODocumentationPageUpdateActionOutputV2,
3820
+ DTODocumentationPageMoveActionOutputV2,
3785
3821
  DTODocumentationPageDuplicateActionOutputV2,
3786
3822
  DTODocumentationPageDeleteActionOutputV2,
3787
3823
  // Documentation groups
3788
3824
  DTODocumentationGroupCreateActionOutputV2,
3789
3825
  DTODocumentationGroupUpdateActionOutputV2,
3826
+ DTODocumentationGroupMoveActionOutputV2,
3790
3827
  DTODocumentationGroupDuplicateActionOutputV2,
3791
3828
  DTODocumentationGroupDeleteActionOutputV2
3792
3829
  ]);
3793
- var DTOElementActionInput = z133.discriminatedUnion("type", [
3830
+ var DTOElementActionInput = z131.discriminatedUnion("type", [
3794
3831
  // Documentation pages
3795
3832
  DTODocumentationPageCreateActionInputV2,
3796
3833
  DTODocumentationPageUpdateActionInputV2,
3834
+ DTODocumentationPageMoveActionInputV2,
3797
3835
  DTODocumentationPageDuplicateActionInputV2,
3798
3836
  DTODocumentationPageDeleteActionInputV2,
3799
3837
  // Documentation groups
3800
3838
  DTODocumentationGroupCreateActionInputV2,
3801
3839
  DTODocumentationGroupUpdateActionInputV2,
3840
+ DTODocumentationGroupMoveActionInputV2,
3802
3841
  DTODocumentationGroupDuplicateActionInputV2,
3803
3842
  DTODocumentationGroupDeleteActionInputV2
3804
3843
  ]);
3805
3844
 
3806
- // src/api/dto/elements/elements-bulk-action-v2.ts
3807
- import { z as z134 } from "zod";
3808
- var DTOElementsBulkActionOutputV2 = z134.object({
3809
- documentationPages: DTODocumentationPageBulkActionOutputV2
3810
- });
3811
- var DTOElementsBulkActionInputV2 = z134.object({
3812
- documentationPages: DTODocumentationPageBulkActionInputV2
3813
- });
3814
-
3815
3845
  // src/api/payloads/documentation/block-definitions.ts
3816
- import { z as z135 } from "zod";
3817
- var DTOGetBlockDefinitionsOutput = z135.object({
3818
- definitions: z135.array(PageBlockDefinition)
3846
+ import { z as z132 } from "zod";
3847
+ var DTOGetBlockDefinitionsOutput = z132.object({
3848
+ definitions: z132.array(PageBlockDefinition)
3819
3849
  });
3820
3850
 
3821
3851
  // src/api/payloads/liveblocks/auth.ts
3822
- import { z as z136 } from "zod";
3823
- var DTOLiveblocksAuthRequest = z136.object({
3824
- room: z136.string()
3852
+ import { z as z133 } from "zod";
3853
+ var DTOLiveblocksAuthRequest = z133.object({
3854
+ room: z133.string()
3825
3855
  });
3826
3856
 
3827
3857
  // src/yjs/design-system-content/documentation-hierarchy.ts
@@ -3874,9 +3904,23 @@ function getGroupsYMap(doc) {
3874
3904
  }
3875
3905
 
3876
3906
  // src/yjs/design-system-content/item-configuration.ts
3907
+ import { z as z134 } from "zod";
3908
+ var DTODocumentationPageRoomHeaderData = z134.object({
3909
+ title: z134.string(),
3910
+ configuration: DocumentationItemConfiguration
3911
+ });
3912
+ var DTODocumentationPageRoomHeaderDataUpdate = z134.object({
3913
+ title: z134.string().optional(),
3914
+ configuration: DocumentationItemConfiguration.omit({ header: true }).extend({ header: DocumentationItemHeader.partial() }).optional()
3915
+ });
3877
3916
  function itemConfigurationToYjs(yDoc, item) {
3878
3917
  yDoc.transact((trx) => {
3879
- const header = item.header;
3918
+ const { title, configuration } = item;
3919
+ const header = configuration?.header;
3920
+ if (title !== void 0) {
3921
+ const headerYMap = trx.doc.getMap("itemTitle");
3922
+ headerYMap.set("title", title);
3923
+ }
3880
3924
  if (header) {
3881
3925
  const headerYMap = trx.doc.getMap("itemHeader");
3882
3926
  header.description !== void 0 && headerYMap.set("description", header.description);
@@ -3889,13 +3933,14 @@ function itemConfigurationToYjs(yDoc, item) {
3889
3933
  header.showCoverText !== void 0 && headerYMap.set("showCoverText", header.showCoverText);
3890
3934
  header.minHeight !== void 0 && headerYMap.set("minHeight", header.minHeight);
3891
3935
  }
3892
- if (item.showSidebar !== void 0) {
3936
+ if (configuration?.showSidebar !== void 0) {
3893
3937
  const configYMap = trx.doc.getMap("itemConfiguration");
3894
- configYMap.set("showSidebar", item.showSidebar);
3938
+ configYMap.set("showSidebar", configuration.showSidebar);
3895
3939
  }
3896
3940
  });
3897
3941
  }
3898
3942
  function yjsToItemConfiguration(yDoc) {
3943
+ const title = yDoc.getMap("itemTitle").get("title");
3899
3944
  const headerYMap = yDoc.getMap("itemHeader");
3900
3945
  const rawHeader = {
3901
3946
  description: headerYMap.get("description"),
@@ -3913,20 +3958,19 @@ function yjsToItemConfiguration(yDoc) {
3913
3958
  showSidebar: configYMap.get("showSidebar"),
3914
3959
  header: rawHeader
3915
3960
  };
3916
- return DocumentationItemConfiguration.parse(rawConfig);
3961
+ return {
3962
+ title: z134.string().parse(title),
3963
+ configuration: DocumentationItemConfiguration.parse(rawConfig)
3964
+ };
3917
3965
  }
3918
3966
 
3919
3967
  // src/yjs/docs-editor/model/block.ts
3920
- import { z as z137 } from "zod";
3921
- var PageBlockEditorModel = z137.object({
3922
- id: z137.string(),
3923
- data: PageBlockDataV2
3924
- });
3968
+ var PageBlockEditorModel2 = PageBlockEditorModel;
3925
3969
 
3926
3970
  // src/yjs/docs-editor/model/page.ts
3927
- import { z as z138 } from "zod";
3928
- var DocumentationPageEditorModel = z138.object({
3929
- blocks: z138.array(PageBlockEditorModel)
3971
+ import { z as z135 } from "zod";
3972
+ var DocumentationPageEditorModel = z135.object({
3973
+ blocks: z135.array(PageBlockEditorModel2)
3930
3974
  });
3931
3975
 
3932
3976
  // src/yjs/docs-editor/prosemirror/schema.ts
@@ -7559,7 +7603,7 @@ var blocks = [
7559
7603
 
7560
7604
  // src/yjs/docs-editor/prosemirror-to-blocks.ts
7561
7605
  import { yXmlFragmentToProsemirrorJSON } from "y-prosemirror";
7562
- import { z as z139 } from "zod";
7606
+ import { z as z136 } from "zod";
7563
7607
  function yDocToPage(yDoc, definitions) {
7564
7608
  return yXmlFragmentToPage(yDoc.getXmlFragment("default"), definitions);
7565
7609
  }
@@ -7571,7 +7615,7 @@ function prosemirrorDocToPage(prosemirrorDoc, definitions) {
7571
7615
  const definitionsById = mapByUnique2(definitions, (d) => d.id);
7572
7616
  return {
7573
7617
  blocks: (prosemirrorDoc.content ?? []).map((prosemirrorNode) => {
7574
- const definitionId = getProsemirrorAttribute(prosemirrorNode, "definitionId", z139.string());
7618
+ const definitionId = getProsemirrorAttribute(prosemirrorNode, "definitionId", z136.string());
7575
7619
  if (!definitionId) {
7576
7620
  console.warn(
7577
7621
  `definitionId on ${prosemirrorNode.type} is required to be interpreted as a block, skipping node`
@@ -7613,7 +7657,7 @@ function parseAsRichText(prosemirrorNode, definition, property) {
7613
7657
  if (!id)
7614
7658
  return null;
7615
7659
  const variantId = getProsemirrorBlockVariantId(prosemirrorNode);
7616
- const calloutType = parseCalloutType(getProsemirrorAttribute(prosemirrorNode, "type", z139.string().optional()));
7660
+ const calloutType = parseCalloutType(getProsemirrorAttribute(prosemirrorNode, "type", z136.string().optional()));
7617
7661
  return {
7618
7662
  // TODO Artem: indent
7619
7663
  id,
@@ -7713,8 +7757,8 @@ function parseRichTextAttribute(mark) {
7713
7757
  case "code":
7714
7758
  return { type: "Code" };
7715
7759
  case "link":
7716
- const itemId = getProsemirrorAttribute(mark, "itemId", z139.string().optional());
7717
- const href = getProsemirrorAttribute(mark, "href", z139.string().optional());
7760
+ const itemId = getProsemirrorAttribute(mark, "itemId", z136.string().optional());
7761
+ const href = getProsemirrorAttribute(mark, "href", z136.string().optional());
7718
7762
  return {
7719
7763
  type: "Link",
7720
7764
  openInNewWindow: mark.attrs?.target !== "_self",
@@ -7729,7 +7773,7 @@ function parseAsTable(prosemirrorNode, definition, property) {
7729
7773
  if (!id)
7730
7774
  return null;
7731
7775
  const variantId = getProsemirrorBlockVariantId(prosemirrorNode);
7732
- const hasBorder = getProsemirrorAttribute(prosemirrorNode, "hasBorder", z139.boolean().optional()) !== false;
7776
+ const hasBorder = getProsemirrorAttribute(prosemirrorNode, "hasBorder", z136.boolean().optional()) !== false;
7733
7777
  const tableChild = prosemirrorNode.content?.find((c) => c.type === "table");
7734
7778
  if (!tableChild) {
7735
7779
  return emptyTable(id, variantId, 0);
@@ -7775,9 +7819,9 @@ function parseAsTableCell(prosemirrorNode) {
7775
7819
  const id = getProsemirrorBlockId(prosemirrorNode);
7776
7820
  if (!id)
7777
7821
  return null;
7778
- const textAlign = getProsemirrorAttribute(prosemirrorNode, "textAlign", z139.string().optional());
7822
+ const textAlign = getProsemirrorAttribute(prosemirrorNode, "textAlign", z136.string().optional());
7779
7823
  let columnWidth;
7780
- const columnWidthArray = getProsemirrorAttribute(prosemirrorNode, "colwidth", z139.array(z139.number()).optional());
7824
+ const columnWidthArray = getProsemirrorAttribute(prosemirrorNode, "colwidth", z136.array(z136.number()).optional());
7781
7825
  if (columnWidthArray) {
7782
7826
  columnWidth = columnWidthArray[0];
7783
7827
  }
@@ -7811,7 +7855,7 @@ function parseAsTableNode(prosemirrorNode) {
7811
7855
  value: parseRichText(prosemirrorNode.content ?? [])
7812
7856
  };
7813
7857
  case "image":
7814
- const url = getProsemirrorAttribute(prosemirrorNode, "src", z139.string().optional());
7858
+ const url = getProsemirrorAttribute(prosemirrorNode, "src", z136.string().optional());
7815
7859
  if (!url)
7816
7860
  return null;
7817
7861
  return {
@@ -7905,7 +7949,7 @@ function parseAsCustomBlock(prosemirrorNode, definition) {
7905
7949
  };
7906
7950
  }
7907
7951
  function parseBlockItems(prosemirrorNode, definition) {
7908
- const itemsString = getProsemirrorAttribute(prosemirrorNode, "items", z139.string());
7952
+ const itemsString = getProsemirrorAttribute(prosemirrorNode, "items", z136.string());
7909
7953
  if (!itemsString)
7910
7954
  return null;
7911
7955
  const itemsJson = JSON.parse(itemsString);
@@ -7917,11 +7961,11 @@ function parseBlockItems(prosemirrorNode, definition) {
7917
7961
  }
7918
7962
  function parseAppearance(prosemirrorNode) {
7919
7963
  const appearance = {};
7920
- const columns = getProsemirrorAttribute(prosemirrorNode, "columns", z139.number().optional());
7964
+ const columns = getProsemirrorAttribute(prosemirrorNode, "columns", z136.number().optional());
7921
7965
  if (columns) {
7922
7966
  appearance.numberOfColumns = columns;
7923
7967
  }
7924
- const backgroundColor = getProsemirrorAttribute(prosemirrorNode, "backgroundColor", z139.string().optional());
7968
+ const backgroundColor = getProsemirrorAttribute(prosemirrorNode, "backgroundColor", z136.string().optional());
7925
7969
  if (backgroundColor) {
7926
7970
  const parsedColor = PageBlockColorV2.safeParse(JSON.parse(backgroundColor));
7927
7971
  if (parsedColor.success) {
@@ -8012,13 +8056,13 @@ function valueSchemaForPropertyType(type) {
8012
8056
  }
8013
8057
  }
8014
8058
  function getProsemirrorBlockId(prosemirrorNode) {
8015
- const id = getProsemirrorAttribute(prosemirrorNode, "id", z139.string());
8059
+ const id = getProsemirrorAttribute(prosemirrorNode, "id", z136.string());
8016
8060
  if (!id)
8017
8061
  console.warn(`Prosemirror attribute "id" on ${prosemirrorNode.type} is required`);
8018
8062
  return id;
8019
8063
  }
8020
8064
  function getProsemirrorBlockVariantId(prosemirrorNode) {
8021
- return getProsemirrorAttribute(prosemirrorNode, "variantId", nullishToOptional(z139.string()));
8065
+ return getProsemirrorAttribute(prosemirrorNode, "variantId", nullishToOptional(z136.string()));
8022
8066
  }
8023
8067
  function getProsemirrorAttribute(prosemirrorNode, attributeName, validationSchema) {
8024
8068
  const parsedAttr = validationSchema.safeParse(prosemirrorNode.attrs?.[attributeName]);
@@ -8045,30 +8089,34 @@ export {
8045
8089
  BlockParsingUtils,
8046
8090
  DTOCreateDocumentationGroupInput,
8047
8091
  DTOCreateDocumentationPageInputV2,
8092
+ DTOCreateDocumentationTabGroupInput,
8048
8093
  DTODeleteDocumentationGroupInput,
8049
8094
  DTODeleteDocumentationPageInputV2,
8095
+ DTODeleteDocumentationTabGroupInput,
8050
8096
  DTODesignSystem,
8051
8097
  DTODocumentationGroup,
8052
- DTODocumentationGroupBulkActionInputV2,
8053
- DTODocumentationGroupBulkActionOutputV2,
8054
8098
  DTODocumentationGroupCreateActionInputV2,
8055
8099
  DTODocumentationGroupCreateActionOutputV2,
8056
8100
  DTODocumentationGroupDeleteActionInputV2,
8057
8101
  DTODocumentationGroupDeleteActionOutputV2,
8058
8102
  DTODocumentationGroupDuplicateActionInputV2,
8059
8103
  DTODocumentationGroupDuplicateActionOutputV2,
8104
+ DTODocumentationGroupMoveActionInputV2,
8105
+ DTODocumentationGroupMoveActionOutputV2,
8060
8106
  DTODocumentationGroupStructure,
8061
8107
  DTODocumentationGroupUpdateActionInputV2,
8062
8108
  DTODocumentationGroupUpdateActionOutputV2,
8063
8109
  DTODocumentationHierarchyV2,
8064
- DTODocumentationPageBulkActionInputV2,
8065
- DTODocumentationPageBulkActionOutputV2,
8066
8110
  DTODocumentationPageCreateActionInputV2,
8067
8111
  DTODocumentationPageCreateActionOutputV2,
8068
8112
  DTODocumentationPageDeleteActionInputV2,
8069
8113
  DTODocumentationPageDeleteActionOutputV2,
8070
8114
  DTODocumentationPageDuplicateActionInputV2,
8071
8115
  DTODocumentationPageDuplicateActionOutputV2,
8116
+ DTODocumentationPageMoveActionInputV2,
8117
+ DTODocumentationPageMoveActionOutputV2,
8118
+ DTODocumentationPageRoomHeaderData,
8119
+ DTODocumentationPageRoomHeaderDataUpdate,
8072
8120
  DTODocumentationPageStructureV2,
8073
8121
  DTODocumentationPageUpdateActionInputV2,
8074
8122
  DTODocumentationPageUpdateActionOutputV2,
@@ -8077,15 +8125,15 @@ export {
8077
8125
  DTODuplicateDocumentationPageInputV2,
8078
8126
  DTOElementActionInput,
8079
8127
  DTOElementActionOutput,
8080
- DTOElementsBulkActionInputV2,
8081
- DTOElementsBulkActionOutputV2,
8082
8128
  DTOGetBlockDefinitionsOutput,
8083
8129
  DTOLiveblocksAuthRequest,
8130
+ DTOMoveDocumentationGroupInput,
8131
+ DTOMoveDocumentationPageInputV2,
8084
8132
  DTOUpdateDocumentationGroupInput,
8085
8133
  DTOUpdateDocumentationPageInputV2,
8086
8134
  DocumentationPageEditorModel,
8087
8135
  DocumentationPageV1DTO,
8088
- PageBlockEditorModel,
8136
+ PageBlockEditorModel2 as PageBlockEditorModel,
8089
8137
  blockDefinitionForBlock,
8090
8138
  blockToProsemirrorNode,
8091
8139
  buildDocPagePublishPaths,