@supernova-studio/model 0.2.2 → 0.4.0
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 +2795 -698
- package/dist/index.d.ts +2795 -698
- package/dist/index.js +171 -30
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +175 -34
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
- package/src/dsm/elements/data/documentation-block-v2.ts +219 -42
package/dist/index.mjs
CHANGED
|
@@ -874,27 +874,31 @@ import { z as z33 } from "zod";
|
|
|
874
874
|
var PageBlockLinkType = z33.enum(["DocumentationItem", "PageHeading", "Url"]);
|
|
875
875
|
var PageBlockImageType = z33.enum(["Upload", "Asset", "FigmaFrame"]);
|
|
876
876
|
var PageBlockImageAlignment = z33.enum(["Left", "Center", "Stretch"]);
|
|
877
|
+
var PageBlockTableCellAlignment = z33.enum(["Left", "Center", "Right"]);
|
|
877
878
|
var PageBlockAppearanceV2 = z33.object({
|
|
878
879
|
itemBackgroundColor: ColorValue
|
|
879
880
|
});
|
|
880
|
-
var
|
|
881
|
+
var PageBlockItemUntypedValue = z33.object({
|
|
881
882
|
value: z33.any()
|
|
882
883
|
}).and(z33.record(z33.any()));
|
|
883
|
-
var
|
|
884
|
-
|
|
885
|
-
|
|
886
|
-
|
|
887
|
-
|
|
888
|
-
|
|
889
|
-
caption: z33.string().optional(),
|
|
890
|
-
height: z33.number().optional()
|
|
884
|
+
var PageBlockLinkV2 = z33.object({
|
|
885
|
+
type: PageBlockLinkType,
|
|
886
|
+
documentationItemId: z33.string().optional(),
|
|
887
|
+
pageHeadingId: z33.string().optional(),
|
|
888
|
+
url: z33.string().optional(),
|
|
889
|
+
openInNewTab: z33.boolean().optional()
|
|
891
890
|
});
|
|
892
|
-
var
|
|
893
|
-
|
|
891
|
+
var PageBlockItemV2 = z33.object({
|
|
892
|
+
id: z33.string(),
|
|
893
|
+
linksTo: PageBlockLinkV2.optional(),
|
|
894
|
+
props: z33.record(PageBlockItemUntypedValue)
|
|
894
895
|
});
|
|
895
|
-
var
|
|
896
|
-
|
|
897
|
-
|
|
896
|
+
var PageBlockDataV2 = z33.object({
|
|
897
|
+
packageId: z33.string(),
|
|
898
|
+
variantId: z33.string().optional(),
|
|
899
|
+
indentLevel: z33.number(),
|
|
900
|
+
appearance: PageBlockAppearanceV2.optional(),
|
|
901
|
+
items: z33.array(PageBlockItemV2)
|
|
898
902
|
});
|
|
899
903
|
var PageBlockItemImageReference = z33.object({
|
|
900
904
|
type: PageBlockImageType,
|
|
@@ -906,30 +910,141 @@ var PageBlockItemImageReference = z33.object({
|
|
|
906
910
|
frameId: z33.string()
|
|
907
911
|
}).optional()
|
|
908
912
|
});
|
|
913
|
+
var PageBlockItemAssetValue = z33.object({
|
|
914
|
+
selectedPropertyIds: z33.array(z33.string()).optional(),
|
|
915
|
+
showSearch: z33.boolean().optional(),
|
|
916
|
+
previewContainerSize: z33.enum(["Centered", "NaturalHeight"]).optional(),
|
|
917
|
+
backgroundColor: z33.string().optional(),
|
|
918
|
+
value: z33.array(
|
|
919
|
+
z33.object({
|
|
920
|
+
entityId: z33.string(),
|
|
921
|
+
entityType: z33.enum(["Asset", "AssetGroup"])
|
|
922
|
+
})
|
|
923
|
+
)
|
|
924
|
+
});
|
|
925
|
+
var PageBlockItemAssetPropertyValue = z33.object({
|
|
926
|
+
value: z33.array(z33.string())
|
|
927
|
+
});
|
|
928
|
+
var PageBlockItemBooleanValue = z33.object({
|
|
929
|
+
value: z33.boolean()
|
|
930
|
+
});
|
|
931
|
+
var PageBlockItemCodeValue = z33.object({
|
|
932
|
+
format: PageBlockCodeLanguage.optional(),
|
|
933
|
+
caption: z33.string().optional(),
|
|
934
|
+
value: z33.string()
|
|
935
|
+
});
|
|
936
|
+
var PageBlockItemSandboxValue = z33.object({
|
|
937
|
+
showCode: z33.boolean().optional(),
|
|
938
|
+
backgroundColor: z33.string().optional(),
|
|
939
|
+
alignPreview: z33.enum(["Left", "Center"]).optional(),
|
|
940
|
+
value: z33.string()
|
|
941
|
+
});
|
|
942
|
+
var PageBlockItemColorValue = z33.record(z33.any());
|
|
943
|
+
var PageBlockItemComponentValue = z33.object({
|
|
944
|
+
selectedPropertyIds: z33.array(z33.string()).optional(),
|
|
945
|
+
value: z33.array(
|
|
946
|
+
z33.object({
|
|
947
|
+
entityId: z33.string(),
|
|
948
|
+
entityType: z33.enum(["Component", "ComponentGroup"])
|
|
949
|
+
})
|
|
950
|
+
)
|
|
951
|
+
});
|
|
952
|
+
var PageBlockItemComponentPropertyValue = z33.object({
|
|
953
|
+
value: z33.string()
|
|
954
|
+
});
|
|
955
|
+
var PageBlockItemDividerValue = z33.object({});
|
|
956
|
+
var PageBlockItemEmbedValue = z33.object({
|
|
957
|
+
value: z33.string().optional(),
|
|
958
|
+
caption: z33.string().optional(),
|
|
959
|
+
height: z33.number().optional()
|
|
960
|
+
});
|
|
909
961
|
var PageBlockItemImageValue = z33.object({
|
|
910
962
|
alt: z33.string().optional(),
|
|
911
963
|
caption: z33.string().optional(),
|
|
912
964
|
alignment: PageBlockImageAlignment.optional(),
|
|
913
965
|
value: PageBlockItemImageReference.optional()
|
|
914
966
|
});
|
|
915
|
-
var
|
|
916
|
-
|
|
917
|
-
documentationItemId: z33.string().optional(),
|
|
918
|
-
pageHeadingId: z33.string().optional(),
|
|
919
|
-
url: z33.string().optional(),
|
|
920
|
-
openInNewTab: z33.boolean().optional()
|
|
967
|
+
var PageBlockItemMarkdownValue = z33.object({
|
|
968
|
+
value: z33.string()
|
|
921
969
|
});
|
|
922
|
-
var
|
|
970
|
+
var PageBlockItemMultiRichTextValue = z33.object({
|
|
971
|
+
value: PageBlockText.array()
|
|
972
|
+
});
|
|
973
|
+
var PageBlockItemMultiSelectValue = z33.object({
|
|
974
|
+
value: z33.array(z33.string())
|
|
975
|
+
});
|
|
976
|
+
var PageBlockItemNumberValue = z33.object({
|
|
977
|
+
value: z33.number()
|
|
978
|
+
});
|
|
979
|
+
var PageBlockItemRichTextValue = z33.object({
|
|
980
|
+
value: PageBlockText,
|
|
981
|
+
calloutType: PageBlockCalloutType.optional()
|
|
982
|
+
});
|
|
983
|
+
var PageBlockItemSingleSelectValue = z33.object({
|
|
984
|
+
value: z33.string()
|
|
985
|
+
});
|
|
986
|
+
var PageBlockItemStorybookValue = z33.object({
|
|
987
|
+
caption: z33.string().optional(),
|
|
988
|
+
height: z33.number().optional(),
|
|
989
|
+
showAddons: z33.boolean().optional(),
|
|
990
|
+
value: z33.string()
|
|
991
|
+
});
|
|
992
|
+
var PageBlockItemTextValue = z33.object({
|
|
993
|
+
value: z33.string()
|
|
994
|
+
});
|
|
995
|
+
var PageBlockItemTokenValue = z33.object({
|
|
996
|
+
selectedPropertyIds: z33.array(z33.string()).optional(),
|
|
997
|
+
selectedThemeIds: z33.array(z33.string()).optional(),
|
|
998
|
+
value: z33.array(
|
|
999
|
+
z33.object({
|
|
1000
|
+
entityId: z33.string(),
|
|
1001
|
+
entityType: z33.enum(["Token", "TokenGroup"])
|
|
1002
|
+
})
|
|
1003
|
+
)
|
|
1004
|
+
});
|
|
1005
|
+
var PageBlockItemTokenPropertyValue = z33.object({
|
|
1006
|
+
selectedPropertyIds: z33.array(z33.string()).optional(),
|
|
1007
|
+
selectedThemeIds: z33.array(z33.string()).optional(),
|
|
1008
|
+
value: z33.array(z33.string())
|
|
1009
|
+
});
|
|
1010
|
+
var PageBlockItemTokenTypeValue = z33.object({
|
|
1011
|
+
value: z33.array(DesignTokenType)
|
|
1012
|
+
});
|
|
1013
|
+
var PageBlockItemUrlValue = z33.object({
|
|
1014
|
+
value: z33.string()
|
|
1015
|
+
});
|
|
1016
|
+
var PageBlockItemTableRichTextNode = z33.object({
|
|
1017
|
+
type: z33.literal("RichText"),
|
|
1018
|
+
value: PageBlockItemRichTextValue.shape.value
|
|
1019
|
+
});
|
|
1020
|
+
var PageBlockItemTableMultiRichTextNode = z33.object({
|
|
1021
|
+
type: z33.literal("MultiRichText"),
|
|
1022
|
+
value: PageBlockItemMultiRichTextValue.shape.value
|
|
1023
|
+
});
|
|
1024
|
+
var PageBlockItemTableImageNode = z33.object({
|
|
1025
|
+
type: z33.literal("Image"),
|
|
1026
|
+
value: PageBlockItemImageValue.shape.value
|
|
1027
|
+
});
|
|
1028
|
+
var PageBlockItemTableNode = z33.discriminatedUnion("type", [
|
|
1029
|
+
PageBlockItemTableRichTextNode,
|
|
1030
|
+
PageBlockItemTableMultiRichTextNode,
|
|
1031
|
+
PageBlockItemTableImageNode
|
|
1032
|
+
]);
|
|
1033
|
+
var PageBlockItemTableCell = z33.object({
|
|
923
1034
|
id: z33.string(),
|
|
924
|
-
|
|
925
|
-
|
|
1035
|
+
nodes: z33.array(PageBlockItemTableNode),
|
|
1036
|
+
columnWidth: z33.number().optional(),
|
|
1037
|
+
alignment: PageBlockTableCellAlignment
|
|
926
1038
|
});
|
|
927
|
-
var
|
|
928
|
-
|
|
929
|
-
|
|
930
|
-
|
|
931
|
-
|
|
932
|
-
|
|
1039
|
+
var PageBlockItemTableRow = z33.object({
|
|
1040
|
+
cells: z33.array(PageBlockItemTableCell)
|
|
1041
|
+
});
|
|
1042
|
+
var PageBlockItemTableValue = z33.object({
|
|
1043
|
+
highlightHeaderColumn: z33.boolean().optional(),
|
|
1044
|
+
highlightHeaderRow: z33.boolean().optional(),
|
|
1045
|
+
showBorder: z33.boolean().optional(),
|
|
1046
|
+
width: z33.number().optional(),
|
|
1047
|
+
value: z33.array(PageBlockItemTableRow)
|
|
933
1048
|
});
|
|
934
1049
|
|
|
935
1050
|
// src/dsm/elements/data/documentation-page-v1.ts
|
|
@@ -2950,19 +3065,45 @@ export {
|
|
|
2950
3065
|
PageBlockFrameOrigin,
|
|
2951
3066
|
PageBlockImageAlignment,
|
|
2952
3067
|
PageBlockImageType,
|
|
2953
|
-
|
|
3068
|
+
PageBlockItemAssetPropertyValue,
|
|
3069
|
+
PageBlockItemAssetValue,
|
|
3070
|
+
PageBlockItemBooleanValue,
|
|
3071
|
+
PageBlockItemCodeValue,
|
|
3072
|
+
PageBlockItemColorValue,
|
|
3073
|
+
PageBlockItemComponentPropertyValue,
|
|
3074
|
+
PageBlockItemComponentValue,
|
|
3075
|
+
PageBlockItemDividerValue,
|
|
3076
|
+
PageBlockItemEmbedValue,
|
|
2954
3077
|
PageBlockItemImageReference,
|
|
2955
3078
|
PageBlockItemImageValue,
|
|
2956
|
-
|
|
2957
|
-
|
|
2958
|
-
|
|
2959
|
-
|
|
3079
|
+
PageBlockItemMarkdownValue,
|
|
3080
|
+
PageBlockItemMultiRichTextValue,
|
|
3081
|
+
PageBlockItemMultiSelectValue,
|
|
3082
|
+
PageBlockItemNumberValue,
|
|
3083
|
+
PageBlockItemRichTextValue,
|
|
3084
|
+
PageBlockItemSandboxValue,
|
|
3085
|
+
PageBlockItemSingleSelectValue,
|
|
3086
|
+
PageBlockItemStorybookValue,
|
|
3087
|
+
PageBlockItemTableCell,
|
|
3088
|
+
PageBlockItemTableImageNode,
|
|
3089
|
+
PageBlockItemTableMultiRichTextNode,
|
|
3090
|
+
PageBlockItemTableNode,
|
|
3091
|
+
PageBlockItemTableRichTextNode,
|
|
3092
|
+
PageBlockItemTableRow,
|
|
3093
|
+
PageBlockItemTableValue,
|
|
3094
|
+
PageBlockItemTextValue,
|
|
3095
|
+
PageBlockItemTokenPropertyValue,
|
|
3096
|
+
PageBlockItemTokenTypeValue,
|
|
3097
|
+
PageBlockItemTokenValue,
|
|
3098
|
+
PageBlockItemUntypedValue,
|
|
3099
|
+
PageBlockItemUrlValue,
|
|
2960
3100
|
PageBlockItemV2,
|
|
2961
3101
|
PageBlockLinkPreview,
|
|
2962
3102
|
PageBlockLinkType,
|
|
2963
3103
|
PageBlockLinkV2,
|
|
2964
3104
|
PageBlockRenderCodeProperties,
|
|
2965
3105
|
PageBlockShortcut,
|
|
3106
|
+
PageBlockTableCellAlignment,
|
|
2966
3107
|
PageBlockTableColumn,
|
|
2967
3108
|
PageBlockTableProperties,
|
|
2968
3109
|
PageBlockText,
|