@supernova-studio/model 1.6.6 → 1.6.7

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
@@ -4380,7 +4380,7 @@ var DocumentationPageDependencies = z114.object({
4380
4380
  propertyPersistentIds: z114.set(z114.string()),
4381
4381
  themePersistentIds: z114.set(z114.string()),
4382
4382
  documentationPagePersistentIds: z114.set(z114.string()),
4383
- storybookEntriesStoryIds: z114.set(z114.string())
4383
+ storybookEntriesStoryIds: z114.array(z114.string())
4384
4384
  });
4385
4385
 
4386
4386
  // src/dsm/documentation/page.ts
@@ -5252,7 +5252,13 @@ var ExportDestinationsMapUpdate = z157.object({
5252
5252
  });
5253
5253
 
5254
5254
  // src/export/pipeline.ts
5255
- var PipelineEventType = z158.enum(["OnVersionReleased", "OnHeadChanged", "OnSourceUpdated", "None"]);
5255
+ var PipelineEventType = z158.enum([
5256
+ "OnVersionReleased",
5257
+ "OnHeadChanged",
5258
+ "OnSourceUpdated",
5259
+ "OnDocumentationPublished",
5260
+ "None"
5261
+ ]);
5256
5262
  var PipelineDestinationGitType = z158.enum(["Github", "Gitlab", "Bitbucket", "Azure"]);
5257
5263
  var PipelineDestinationExtraType = z158.enum(["WebhookUrl", "S3", "Documentation"]);
5258
5264
  var PipelineDestinationType = z158.union([PipelineDestinationGitType, PipelineDestinationExtraType]);
@@ -5595,7 +5601,7 @@ var WorkspaceInviteEmailData = z172.object({
5595
5601
  });
5596
5602
 
5597
5603
  // src/events/base.ts
5598
- import { z as z175 } from "zod";
5604
+ import { z as z176 } from "zod";
5599
5605
 
5600
5606
  // src/events/data-source-imported.ts
5601
5607
  import { z as z173 } from "zod";
@@ -5614,48 +5620,61 @@ var EventVersionReleased = z174.object({
5614
5620
  versionId: z174.string()
5615
5621
  });
5616
5622
 
5623
+ // src/events/documentation-published.ts
5624
+ import { z as z175 } from "zod";
5625
+ var EventDocumentationPublished = z175.object({
5626
+ type: z175.literal("DocumentationPublished"),
5627
+ workspaceId: z175.string(),
5628
+ designSystemId: z175.string(),
5629
+ versionId: z175.string()
5630
+ });
5631
+
5617
5632
  // src/events/base.ts
5618
- var Event = z175.discriminatedUnion("type", [EventVersionReleased, EventDataSourceImported]);
5633
+ var Event = z176.discriminatedUnion("type", [
5634
+ EventVersionReleased,
5635
+ EventDataSourceImported,
5636
+ EventDocumentationPublished
5637
+ ]);
5619
5638
 
5620
5639
  // src/export/export-runner/export-context.ts
5621
- import { z as z176 } from "zod";
5622
- var ExportJobDocumentationContext = z176.object({
5623
- isSingleVersionDocs: z176.boolean(),
5624
- versionSlug: z176.string(),
5640
+ import { z as z177 } from "zod";
5641
+ var ExportJobDocumentationContext = z177.object({
5642
+ isSingleVersionDocs: z177.boolean(),
5643
+ versionSlug: z177.string(),
5625
5644
  environment: PublishedDocEnvironment
5626
5645
  });
5627
- var ExportJobContext = z176.object({
5628
- apiUrl: z176.string(),
5629
- accessToken: z176.string(),
5630
- designSystemId: z176.string(),
5631
- designSystemName: z176.string(),
5632
- exporterId: z176.string(),
5633
- versionId: z176.string(),
5634
- brandId: z176.string().optional(),
5635
- themeId: z176.string().optional(),
5636
- themePersistentIds: z176.string().array().optional(),
5637
- previewMode: z176.boolean().optional(),
5638
- exporterName: z176.string(),
5646
+ var ExportJobContext = z177.object({
5647
+ apiUrl: z177.string(),
5648
+ accessToken: z177.string(),
5649
+ designSystemId: z177.string(),
5650
+ designSystemName: z177.string(),
5651
+ exporterId: z177.string(),
5652
+ versionId: z177.string(),
5653
+ brandId: z177.string().optional(),
5654
+ themeId: z177.string().optional(),
5655
+ themePersistentIds: z177.string().array().optional(),
5656
+ previewMode: z177.boolean().optional(),
5657
+ exporterName: z177.string(),
5639
5658
  documentation: ExportJobDocumentationContext.optional()
5640
5659
  });
5641
- var ExportJobExporterConfiguration = z176.object({
5642
- exporterPackageUrl: z176.string(),
5660
+ var ExportJobExporterConfiguration = z177.object({
5661
+ exporterPackageUrl: z177.string(),
5643
5662
  exporterPropertyValues: ExporterConfigurationPropertyValue.array(),
5644
5663
  exporterPropertyValuesV2: ExporterPropertyValueMap.optional()
5645
5664
  });
5646
5665
 
5647
5666
  // src/export/export-runner/exporter-payload.ts
5648
- import { z as z177 } from "zod";
5649
- var ExporterFunctionPayload = z177.object({
5650
- exportJobId: z177.string(),
5651
- exportContextId: z177.string(),
5652
- designSystemId: z177.string(),
5653
- workspaceId: z177.string()
5667
+ import { z as z178 } from "zod";
5668
+ var ExporterFunctionPayload = z178.object({
5669
+ exportJobId: z178.string(),
5670
+ exportContextId: z178.string(),
5671
+ designSystemId: z178.string(),
5672
+ workspaceId: z178.string()
5654
5673
  });
5655
5674
 
5656
5675
  // src/export/export-jobs.ts
5657
- import { z as z178 } from "zod";
5658
- var ExportJobDestinationType = z178.enum([
5676
+ import { z as z179 } from "zod";
5677
+ var ExportJobDestinationType = z179.enum([
5659
5678
  "s3",
5660
5679
  "webhookUrl",
5661
5680
  "github",
@@ -5664,30 +5683,30 @@ var ExportJobDestinationType = z178.enum([
5664
5683
  "gitlab",
5665
5684
  "bitbucket"
5666
5685
  ]);
5667
- var ExportJobStatus = z178.enum(["InProgress", "Success", "Failed", "Timeout"]);
5668
- var ExportJobLogEntryType = z178.enum(["success", "info", "warning", "error", "user"]);
5669
- var ExportJobLogEntry = z178.object({
5670
- id: z178.string().optional(),
5671
- time: z178.coerce.date(),
5686
+ var ExportJobStatus = z179.enum(["InProgress", "Success", "Failed", "Timeout"]);
5687
+ var ExportJobLogEntryType = z179.enum(["success", "info", "warning", "error", "user"]);
5688
+ var ExportJobLogEntry = z179.object({
5689
+ id: z179.string().optional(),
5690
+ time: z179.coerce.date(),
5672
5691
  type: ExportJobLogEntryType,
5673
- message: z178.string()
5692
+ message: z179.string()
5674
5693
  });
5675
- var ExportJobPullRequestDestinationResult = z178.object({
5676
- pullRequestUrl: z178.string()
5694
+ var ExportJobPullRequestDestinationResult = z179.object({
5695
+ pullRequestUrl: z179.string()
5677
5696
  });
5678
- var ExportJobS3DestinationResult = z178.object({
5679
- bucket: z178.string(),
5680
- urlPrefix: z178.string().optional(),
5681
- path: z178.string(),
5682
- files: z178.array(z178.string()),
5683
- url: nullishToOptional(z178.string()),
5684
- urls: nullishToOptional(z178.string().array())
5697
+ var ExportJobS3DestinationResult = z179.object({
5698
+ bucket: z179.string(),
5699
+ urlPrefix: z179.string().optional(),
5700
+ path: z179.string(),
5701
+ files: z179.array(z179.string()),
5702
+ url: nullishToOptional(z179.string()),
5703
+ urls: nullishToOptional(z179.string().array())
5685
5704
  });
5686
- var ExportJobDocsDestinationResult = z178.object({
5687
- url: z178.string()
5705
+ var ExportJobDocsDestinationResult = z179.object({
5706
+ url: z179.string()
5688
5707
  });
5689
- var ExportJobResult = z178.object({
5690
- error: z178.string().optional(),
5708
+ var ExportJobResult = z179.object({
5709
+ error: z179.string().optional(),
5691
5710
  s3: nullishToOptional(ExportJobS3DestinationResult),
5692
5711
  github: nullishToOptional(ExportJobPullRequestDestinationResult),
5693
5712
  azure: nullishToOptional(ExportJobPullRequestDestinationResult),
@@ -5696,24 +5715,24 @@ var ExportJobResult = z178.object({
5696
5715
  sndocs: nullishToOptional(ExportJobDocsDestinationResult),
5697
5716
  logs: nullishToOptional(ExportJobLogEntry.array())
5698
5717
  });
5699
- var ExportJob = z178.object({
5700
- id: z178.string(),
5701
- createdAt: z178.coerce.date(),
5702
- finishedAt: z178.coerce.date().optional(),
5703
- designSystemId: z178.string(),
5704
- designSystemVersionId: z178.string(),
5705
- workspaceId: z178.string(),
5706
- scheduleId: z178.string().nullish(),
5707
- exporterId: z178.string(),
5708
- brandId: z178.string().optional(),
5709
- themeId: z178.string().optional(),
5710
- themePersistentIds: z178.string().array().optional(),
5711
- estimatedExecutionTime: z178.number().optional(),
5718
+ var ExportJob = z179.object({
5719
+ id: z179.string(),
5720
+ createdAt: z179.coerce.date(),
5721
+ finishedAt: z179.coerce.date().optional(),
5722
+ designSystemId: z179.string(),
5723
+ designSystemVersionId: z179.string(),
5724
+ workspaceId: z179.string(),
5725
+ scheduleId: z179.string().nullish(),
5726
+ exporterId: z179.string(),
5727
+ brandId: z179.string().optional(),
5728
+ themeId: z179.string().optional(),
5729
+ themePersistentIds: z179.string().array().optional(),
5730
+ estimatedExecutionTime: z179.number().optional(),
5712
5731
  status: ExportJobStatus,
5713
5732
  result: ExportJobResult.optional(),
5714
- createdByUserId: z178.string().optional(),
5733
+ createdByUserId: z179.string().optional(),
5715
5734
  exporterPropertyValues: ExporterPropertyValueMap.optional(),
5716
- previewMode: z178.boolean().optional(),
5735
+ previewMode: z179.boolean().optional(),
5717
5736
  // Destinations
5718
5737
  ...ExportDestinationsMap.shape
5719
5738
  });
@@ -5727,36 +5746,36 @@ var ExportJobFindByFilter = ExportJob.pick({
5727
5746
  themeId: true,
5728
5747
  brandId: true
5729
5748
  }).extend({
5730
- destinations: z178.array(ExportJobDestinationType),
5749
+ destinations: z179.array(ExportJobDestinationType),
5731
5750
  docsEnvironment: PublishedDocEnvironment
5732
5751
  }).partial();
5733
5752
 
5734
5753
  // src/export/exporter-list-query.ts
5735
- import { z as z179 } from "zod";
5736
- var ExporterType2 = z179.enum(["documentation", "code"]);
5737
- var ListExporterQuery = z179.object({
5738
- limit: z179.number().optional(),
5739
- offset: z179.number().optional(),
5754
+ import { z as z180 } from "zod";
5755
+ var ExporterType2 = z180.enum(["documentation", "code"]);
5756
+ var ListExporterQuery = z180.object({
5757
+ limit: z180.number().optional(),
5758
+ offset: z180.number().optional(),
5740
5759
  type: ExporterType2.optional(),
5741
- search: z179.string().optional()
5760
+ search: z180.string().optional()
5742
5761
  });
5743
5762
 
5744
5763
  // src/export/exporter-workspace-membership-role.ts
5745
- import { z as z180 } from "zod";
5746
- var ExporterWorkspaceMembershipRole = z180.enum(["Owner", "OwnerArchived", "User"]);
5764
+ import { z as z181 } from "zod";
5765
+ var ExporterWorkspaceMembershipRole = z181.enum(["Owner", "OwnerArchived", "User"]);
5747
5766
 
5748
5767
  // src/export/exporter-workspace-membership.ts
5749
- import { z as z181 } from "zod";
5750
- var ExporterWorkspaceMembership = z181.object({
5751
- id: z181.string(),
5752
- workspaceId: z181.string(),
5753
- exporterId: z181.string(),
5768
+ import { z as z182 } from "zod";
5769
+ var ExporterWorkspaceMembership = z182.object({
5770
+ id: z182.string(),
5771
+ workspaceId: z182.string(),
5772
+ exporterId: z182.string(),
5754
5773
  role: ExporterWorkspaceMembershipRole
5755
5774
  });
5756
5775
 
5757
5776
  // src/feature-flags/feature-flags.ts
5758
- import { z as z182 } from "zod";
5759
- var FlaggedFeature = z182.enum([
5777
+ import { z as z183 } from "zod";
5778
+ var FlaggedFeature = z183.enum([
5760
5779
  "FigmaImporterV2",
5761
5780
  "DisableImporter",
5762
5781
  "VariablesOrder",
@@ -5767,20 +5786,20 @@ var FlaggedFeature = z182.enum([
5767
5786
  "TypographyUseFontStyle",
5768
5787
  "FigmaImporterV3"
5769
5788
  ]);
5770
- var FeatureFlagMap = z182.record(FlaggedFeature, z182.boolean());
5771
- var FeatureFlag = z182.object({
5772
- id: z182.string(),
5789
+ var FeatureFlagMap = z183.record(FlaggedFeature, z183.boolean());
5790
+ var FeatureFlag = z183.object({
5791
+ id: z183.string(),
5773
5792
  feature: FlaggedFeature,
5774
- createdAt: z182.coerce.date(),
5775
- enabled: z182.boolean(),
5776
- designSystemId: z182.string().optional()
5793
+ createdAt: z183.coerce.date(),
5794
+ enabled: z183.boolean(),
5795
+ designSystemId: z183.string().optional()
5777
5796
  });
5778
5797
 
5779
5798
  // src/integrations/external-oauth-request.ts
5780
- import { z as z184 } from "zod";
5799
+ import { z as z185 } from "zod";
5781
5800
 
5782
5801
  // src/integrations/oauth-providers.ts
5783
- import { z as z183 } from "zod";
5802
+ import { z as z184 } from "zod";
5784
5803
  var OAuthProviderNames = /* @__PURE__ */ ((OAuthProviderNames2) => {
5785
5804
  OAuthProviderNames2["Figma"] = "figma";
5786
5805
  OAuthProviderNames2["Azure"] = "azure";
@@ -5789,128 +5808,128 @@ var OAuthProviderNames = /* @__PURE__ */ ((OAuthProviderNames2) => {
5789
5808
  OAuthProviderNames2["Bitbucket"] = "bitbucket";
5790
5809
  return OAuthProviderNames2;
5791
5810
  })(OAuthProviderNames || {});
5792
- var OAuthProviderSchema = z183.nativeEnum(OAuthProviderNames);
5811
+ var OAuthProviderSchema = z184.nativeEnum(OAuthProviderNames);
5793
5812
  var OAuthProvider = OAuthProviderSchema.enum;
5794
5813
 
5795
5814
  // src/integrations/external-oauth-request.ts
5796
- var ExternalOAuthRequest = z184.object({
5797
- id: z184.string(),
5815
+ var ExternalOAuthRequest = z185.object({
5816
+ id: z185.string(),
5798
5817
  provider: OAuthProviderSchema,
5799
- userId: z184.string(),
5800
- state: z184.string(),
5801
- createdAt: z184.coerce.date()
5818
+ userId: z185.string(),
5819
+ state: z185.string(),
5820
+ createdAt: z185.coerce.date()
5802
5821
  });
5803
5822
 
5804
5823
  // src/integrations/git.ts
5805
- import { z as z185 } from "zod";
5806
- var GitObjectsQuery = z185.object({
5807
- organization: z185.string().optional(),
5824
+ import { z as z186 } from "zod";
5825
+ var GitObjectsQuery = z186.object({
5826
+ organization: z186.string().optional(),
5808
5827
  // Azure Organization | Bitbucket Workspace slug | Gitlab Group | Github Account (User or Organization)
5809
- project: z185.string().optional(),
5828
+ project: z186.string().optional(),
5810
5829
  // Only for Bitbucket and Azure
5811
- repository: z185.string().optional(),
5830
+ repository: z186.string().optional(),
5812
5831
  // For all providers. For Gitlab, it's called "project".
5813
- branch: z185.string().optional(),
5832
+ branch: z186.string().optional(),
5814
5833
  // For all providers.
5815
- user: z185.string().optional()
5834
+ user: z186.string().optional()
5816
5835
  // Gitlab user
5817
5836
  });
5818
- var GitOrganization = z185.object({
5819
- id: z185.string(),
5820
- name: z185.string(),
5821
- url: z185.string(),
5822
- slug: z185.string()
5837
+ var GitOrganization = z186.object({
5838
+ id: z186.string(),
5839
+ name: z186.string(),
5840
+ url: z186.string(),
5841
+ slug: z186.string()
5823
5842
  });
5824
- var GitProject = z185.object({
5825
- id: z185.string(),
5826
- name: z185.string(),
5827
- url: z185.string(),
5828
- slug: z185.string()
5843
+ var GitProject = z186.object({
5844
+ id: z186.string(),
5845
+ name: z186.string(),
5846
+ url: z186.string(),
5847
+ slug: z186.string()
5829
5848
  });
5830
- var GitRepository = z185.object({
5831
- id: z185.string(),
5832
- name: z185.string(),
5833
- url: z185.string(),
5834
- slug: z185.string(),
5849
+ var GitRepository = z186.object({
5850
+ id: z186.string(),
5851
+ name: z186.string(),
5852
+ url: z186.string(),
5853
+ slug: z186.string(),
5835
5854
  /**
5836
5855
  * Can be undefined when:
5837
5856
  * - there are no branches in the repository yet
5838
5857
  * - Git provider doesn't expose this information on a repository via their API
5839
5858
  */
5840
- defaultBranch: z185.string().optional()
5859
+ defaultBranch: z186.string().optional()
5841
5860
  });
5842
- var GitBranch = z185.object({
5843
- name: z185.string(),
5844
- lastCommitId: z185.string()
5861
+ var GitBranch = z186.object({
5862
+ name: z186.string(),
5863
+ lastCommitId: z186.string()
5845
5864
  });
5846
5865
 
5847
5866
  // src/integrations/oauth-token.ts
5848
- import { z as z186 } from "zod";
5849
- var IntegrationTokenSchemaOld = z186.object({
5850
- id: z186.string(),
5867
+ import { z as z187 } from "zod";
5868
+ var IntegrationTokenSchemaOld = z187.object({
5869
+ id: z187.string(),
5851
5870
  provider: OAuthProviderSchema,
5852
- scope: z186.string(),
5853
- userId: z186.string(),
5854
- accessToken: z186.string(),
5855
- refreshToken: z186.string(),
5856
- expiresAt: z186.coerce.date(),
5857
- externalUserId: z186.string().nullish()
5871
+ scope: z187.string(),
5872
+ userId: z187.string(),
5873
+ accessToken: z187.string(),
5874
+ refreshToken: z187.string(),
5875
+ expiresAt: z187.coerce.date(),
5876
+ externalUserId: z187.string().nullish()
5858
5877
  });
5859
5878
 
5860
5879
  // src/integrations/workspace-oauth-requests.ts
5861
- import { z as z187 } from "zod";
5862
- var WorkspaceOAuthRequestSchema = z187.object({
5863
- id: z187.string(),
5864
- workspaceId: z187.string(),
5880
+ import { z as z188 } from "zod";
5881
+ var WorkspaceOAuthRequestSchema = z188.object({
5882
+ id: z188.string(),
5883
+ workspaceId: z188.string(),
5865
5884
  provider: OAuthProviderSchema,
5866
- userId: z187.string(),
5867
- createdAt: z187.coerce.date()
5885
+ userId: z188.string(),
5886
+ createdAt: z188.coerce.date()
5868
5887
  });
5869
5888
 
5870
5889
  // src/npm/npm-package.ts
5871
- import { z as z188 } from "zod";
5872
- var AnyRecord = z188.record(z188.any());
5890
+ import { z as z189 } from "zod";
5891
+ var AnyRecord = z189.record(z189.any());
5873
5892
  var NpmPackageVersionDist = AnyRecord.and(
5874
- z188.object({
5875
- tarball: z188.string()
5893
+ z189.object({
5894
+ tarball: z189.string()
5876
5895
  })
5877
5896
  );
5878
5897
  var NpmPackageVersion = AnyRecord.and(
5879
- z188.object({
5898
+ z189.object({
5880
5899
  dist: NpmPackageVersionDist
5881
5900
  })
5882
5901
  );
5883
5902
  var NpmPackage = AnyRecord.and(
5884
- z188.object({
5885
- _id: z188.string(),
5886
- name: z188.string(),
5903
+ z189.object({
5904
+ _id: z189.string(),
5905
+ name: z189.string(),
5887
5906
  // e.g. "latest": "1.2.3"
5888
- "dist-tags": z188.record(z188.string(), z188.string()),
5907
+ "dist-tags": z189.record(z189.string(), z189.string()),
5889
5908
  // "1.2.3": {...}
5890
- versions: z188.record(NpmPackageVersion)
5909
+ versions: z189.record(NpmPackageVersion)
5891
5910
  })
5892
5911
  );
5893
5912
 
5894
5913
  // src/npm/npm-proxy-token-payload.ts
5895
- import { z as z189 } from "zod";
5896
- var NpmProxyTokenPayload = z189.object({
5897
- npmProxyRegistryConfigId: z189.string()
5914
+ import { z as z190 } from "zod";
5915
+ var NpmProxyTokenPayload = z190.object({
5916
+ npmProxyRegistryConfigId: z190.string()
5898
5917
  });
5899
5918
 
5900
5919
  // src/tokens/personal-access-token.ts
5901
- import { z as z190 } from "zod";
5902
- var PersonalAccessToken = z190.object({
5903
- id: z190.string(),
5904
- userId: z190.string(),
5905
- workspaceId: z190.string().optional(),
5906
- designSystemId: z190.string().optional(),
5920
+ import { z as z191 } from "zod";
5921
+ var PersonalAccessToken = z191.object({
5922
+ id: z191.string(),
5923
+ userId: z191.string(),
5924
+ workspaceId: z191.string().optional(),
5925
+ designSystemId: z191.string().optional(),
5907
5926
  workspaceRole: WorkspaceRoleSchema.optional(),
5908
- name: z190.string(),
5909
- hidden: z190.boolean(),
5910
- token: z190.string(),
5911
- scope: z190.string().optional(),
5912
- createdAt: z190.coerce.date(),
5913
- expireAt: z190.coerce.date().optional()
5927
+ name: z191.string(),
5928
+ hidden: z191.boolean(),
5929
+ token: z191.string(),
5930
+ scope: z191.string().optional(),
5931
+ createdAt: z191.coerce.date(),
5932
+ expireAt: z191.coerce.date().optional()
5914
5933
  });
5915
5934
  export {
5916
5935
  Address,
@@ -6099,6 +6118,7 @@ export {
6099
6118
  Entity,
6100
6119
  Event,
6101
6120
  EventDataSourceImported,
6121
+ EventDocumentationPublished,
6102
6122
  EventVersionReleased,
6103
6123
  ExportDestinationsMap,
6104
6124
  ExportDestinationsMapUpdate,