@supernova-studio/model 0.58.20 → 0.58.22

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
@@ -851,6 +851,12 @@ function chunkedArray(array, chunkSize) {
851
851
  }
852
852
  return result;
853
853
  }
854
+ function recordToMap(record) {
855
+ const map = /* @__PURE__ */ new Map();
856
+ for (const [k, v] of Object.entries(record))
857
+ map.set(k, v);
858
+ return map;
859
+ }
854
860
 
855
861
  // src/utils/content-loader-instruction.ts
856
862
  import { z as z34 } from "zod";
@@ -1831,6 +1837,7 @@ var PageBlockCodeLanguage = z40.enum([
1831
1837
  ]);
1832
1838
  var PageBlockAlignment = z40.enum(["Left", "Center", "Stretch", "Right"]);
1833
1839
  var PageBlockThemeType = z40.enum(["Override", "Comparison"]);
1840
+ var PageBlockTokenNameFormat = z40.enum(["Name", "GroupAndName", "FullPath", "CustomProperty"]);
1834
1841
  var PageBlockAssetType = z40.enum(["image", "figmaFrame"]);
1835
1842
  var PageBlockTilesAlignment = z40.enum(["Center", "FrameHeight"]);
1836
1843
  var PageBlockTilesLayout = z40.enum(["C8", "C7", "C6", "C5", "C4", "C3", "C2", "C1", "C1_75"]);
@@ -1905,6 +1912,7 @@ var PageBlockFigmaFrameProperties = z40.object({
1905
1912
  })
1906
1913
  ),
1907
1914
  alignment: PageBlockTilesAlignment,
1915
+ previewContainerHeight: nullishToOptional(z40.number()),
1908
1916
  layout: PageBlockTilesLayout,
1909
1917
  backgroundColor: nullishToOptional(ColorTokenInlineData),
1910
1918
  showTitles: z40.boolean()
@@ -1936,8 +1944,17 @@ var PageBlockFigmaComponentBlockConfig = z40.object({
1936
1944
  showPropertyList: nullishToOptional(z40.boolean()),
1937
1945
  previewOrderIds: nullishToOptional(z40.array(z40.string())),
1938
1946
  previewContainerSize: nullishToOptional(z40.enum(["Centered", "NaturalHeight"])),
1947
+ previewContainerHeight: nullishToOptional(z40.number()),
1939
1948
  backgroundColor: nullishToOptional(ColorTokenInlineData)
1940
1949
  });
1950
+ var PageBlockTokenBlockConfig = z40.object({
1951
+ tokenNameFormat: nullishToOptional(PageBlockTokenNameFormat),
1952
+ tokenNameCustomPropertyId: nullishToOptional(z40.string())
1953
+ });
1954
+ var PageBlockAssetBlockConfig = z40.object({
1955
+ showSearch: nullishToOptional(z40.boolean()),
1956
+ showAssetDescription: nullishToOptional(z40.boolean())
1957
+ });
1941
1958
  var PageBlockSelectedFigmaComponent = z40.object({
1942
1959
  figmaComponentId: z40.string(),
1943
1960
  selectedComponentProperties: z40.string().array()
@@ -1968,7 +1985,9 @@ var PageBlockGuideline = z40.object({
1968
1985
  type: z40.string(),
1969
1986
  imageAlt: nullishToOptional(z40.string()),
1970
1987
  imageCaption: nullishToOptional(z40.string()),
1971
- imageAlignment: nullishToOptional(PageBlockAlignment)
1988
+ imageAlignment: nullishToOptional(PageBlockAlignment),
1989
+ openLightbox: nullishToOptional(z40.boolean()),
1990
+ isBordered: nullishToOptional(z40.boolean())
1972
1991
  });
1973
1992
  var PageBlockBaseV1 = z40.object({
1974
1993
  persistentId: z40.string(),
@@ -1995,6 +2014,8 @@ var PageBlockBaseV1 = z40.object({
1995
2014
  asset: nullishToOptional(PageBlockAsset),
1996
2015
  alignment: nullishToOptional(PageBlockAlignment),
1997
2016
  imageAlt: nullishToOptional(z40.string()),
2017
+ openLightbox: nullishToOptional(z40.boolean()),
2018
+ isBordered: nullishToOptional(z40.boolean()),
1998
2019
  // Shortcuts block
1999
2020
  shortcuts: nullishToOptional(z40.array(PageBlockShortcut)),
2000
2021
  // Guidelines
@@ -2016,10 +2037,13 @@ var PageBlockBaseV1 = z40.object({
2016
2037
  // Tables
2017
2038
  tableProperties: nullishToOptional(PageBlockTableProperties),
2018
2039
  columnId: nullishToOptional(z40.string()),
2019
- // Token spreadsheet
2040
+ // Design tokens
2020
2041
  theme: nullishToOptional(PageBlockTheme),
2021
2042
  swatches: nullishToOptional(PageBlockSwatch.array()),
2022
2043
  blacklistedElementProperties: nullishToOptional(z40.array(z40.string())),
2044
+ tokenBlockConfig: nullishToOptional(PageBlockTokenBlockConfig),
2045
+ // (Vector) assets
2046
+ assetBlockConfig: nullishToOptional(PageBlockAssetBlockConfig),
2023
2047
  // Figma components
2024
2048
  figmaComponentsBlockConfig: nullishToOptional(PageBlockFigmaComponentBlockConfig),
2025
2049
  selectedFigmaComponent: nullishToOptional(PageBlockSelectedFigmaComponent),
@@ -2339,7 +2363,6 @@ var PageBlockImageAlignment = z44.enum(["Left", "Center", "Stretch"]);
2339
2363
  var PageBlockTableCellAlignment = z44.enum(["Left", "Center", "Right"]);
2340
2364
  var PageBlockPreviewContainerSize = z44.enum(["Centered", "NaturalHeight"]);
2341
2365
  var PageBlockThemeDisplayMode = z44.enum(["Split", "Override"]);
2342
- var PageBlockTokenNameFormat = z44.enum(["Name", "GroupAndName", "FullPath", "CustomProperty"]);
2343
2366
  var PageBlockTokenValueFormat = z44.enum(["ResolvedValue", "ReferenceName", "NoValue"]);
2344
2367
  var PageBlockImageResourceReference = z44.object({
2345
2368
  resourceId: z44.string(),
@@ -2588,7 +2611,9 @@ var PageBlockItemTableImageNode = z44.object({
2588
2611
  caption: PageBlockItemImageValue.shape.caption,
2589
2612
  alt: PageBlockItemImageValue.shape.alt,
2590
2613
  value: PageBlockItemImageValue.shape.value,
2591
- alignment: PageBlockItemImageValue.shape.alignment
2614
+ alignment: PageBlockItemImageValue.shape.alignment,
2615
+ openLightbox: PageBlockItemImageValue.shape.openLightbox,
2616
+ isBordered: PageBlockItemImageValue.shape.isBordered
2592
2617
  });
2593
2618
  var PageBlockItemTableNode = z44.discriminatedUnion("type", [
2594
2619
  PageBlockItemTableRichTextNode,
@@ -5805,6 +5830,7 @@ export {
5805
5830
  PageBlockAlignment,
5806
5831
  PageBlockAppearanceV2,
5807
5832
  PageBlockAsset,
5833
+ PageBlockAssetBlockConfig,
5808
5834
  PageBlockAssetComponent,
5809
5835
  PageBlockAssetEntityMeta,
5810
5836
  PageBlockAssetType,
@@ -5927,6 +5953,7 @@ export {
5927
5953
  PageBlockThemeType,
5928
5954
  PageBlockTilesAlignment,
5929
5955
  PageBlockTilesLayout,
5956
+ PageBlockTokenBlockConfig,
5930
5957
  PageBlockTokenNameFormat,
5931
5958
  PageBlockTokenValueFormat,
5932
5959
  PageBlockTypeV1,
@@ -6126,6 +6153,7 @@ export {
6126
6153
  pickLatestSnapshots,
6127
6154
  promiseWithTimeout,
6128
6155
  publishedDocEnvironments,
6156
+ recordToMap,
6129
6157
  removeCommentSpans,
6130
6158
  sleep,
6131
6159
  slugRegex,