@parra/parra-js-sdk 0.3.549 → 0.3.552

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.
@@ -841,12 +841,22 @@ export interface CreateDesignSystemRequestBody {
841
841
  version?: string | null;
842
842
  description?: string | null;
843
843
  }
844
+ export declare enum ThemeCornerRadiusStyle {
845
+ rounded = "rounded",
846
+ circle = "circle",
847
+ square = "square"
848
+ }
844
849
  export interface ThemeStyles {
845
850
  primary_color_key?: string | null;
846
851
  secondary_color_key?: string | null;
847
852
  tertiary_color_key?: string | null;
848
853
  accent_color_key?: string | null;
849
- corner_radius_style?: string | null;
854
+ success_color_key?: string | null;
855
+ warning_color_key?: string | null;
856
+ danger_color_key?: string | null;
857
+ info_color_key?: string | null;
858
+ neutral_color_key?: string | null;
859
+ corner_radius_style?: ThemeCornerRadiusStyle | null;
850
860
  }
851
861
  export interface ThemeStub {
852
862
  id: string;
@@ -875,6 +885,12 @@ export interface DesignSystem {
875
885
  tenant_id: string;
876
886
  themes: Array<ThemeStub>;
877
887
  }
888
+ export declare enum DesignTokenType {
889
+ color = "color",
890
+ component = "component",
891
+ spacing = "spacing",
892
+ radius = "radius"
893
+ }
878
894
  export interface ColorValue {
879
895
  hex_value?: string;
880
896
  }
@@ -899,7 +915,7 @@ export interface CreateDesignTokenRequestBody {
899
915
  is_deprecated?: boolean;
900
916
  is_active?: boolean;
901
917
  theme_id: string;
902
- type: string;
918
+ type: DesignTokenType;
903
919
  }
904
920
  export interface DesignToken {
905
921
  id: string;
@@ -913,7 +929,7 @@ export interface DesignToken {
913
929
  is_deprecated?: boolean;
914
930
  is_active?: boolean;
915
931
  theme_id: string;
916
- type: string;
932
+ type: DesignTokenType;
917
933
  tenant_id: string;
918
934
  }
919
935
  export interface CreateThemeRequestBody {
@@ -936,11 +952,6 @@ export interface Theme {
936
952
  is_default: boolean;
937
953
  styles?: ThemeStyles | null;
938
954
  }
939
- export declare enum ThemeCornerRadiusStyle {
940
- rounded = "rounded",
941
- circle = "circle",
942
- square = "square"
943
- }
944
955
  export interface UpdateThemeRequestBody {
945
956
  name?: string;
946
957
  key?: string;
@@ -950,6 +961,11 @@ export interface UpdateThemeRequestBody {
950
961
  secondary_color_key?: string | null;
951
962
  tertiary_color_key?: string | null;
952
963
  accent_color_key?: string | null;
964
+ success_color_key?: string | null;
965
+ warning_color_key?: string | null;
966
+ danger_color_key?: string | null;
967
+ info_color_key?: string | null;
968
+ neutral_color_key?: string | null;
953
969
  corner_radius_style?: ThemeCornerRadiusStyle | null;
954
970
  }
955
971
  export declare enum ShareAssetType {
@@ -5418,6 +5434,9 @@ declare class ParraAPI {
5418
5434
  getDesignSystemById: (tenant_id: string, design_system_id: string, options?: Options) => Promise<DesignSystem>;
5419
5435
  updateDesignSystemById: (tenant_id: string, design_system_id: string, body?: UpdateDesignSystemRequestBody, options?: Options) => Promise<DesignSystem>;
5420
5436
  deleteDesignSystemById: (tenant_id: string, design_system_id: string, options?: Options) => Promise<Response>;
5437
+ listDesignTokensForDesignSystem: (tenant_id: string, design_system_id: string, query?: {
5438
+ type?: string;
5439
+ }, options?: Options) => Promise<Array<DesignToken>>;
5421
5440
  createTokenForDesignSystem: (tenant_id: string, design_system_id: string, body: CreateDesignTokenRequestBody, options?: Options) => Promise<DesignToken>;
5422
5441
  getDesignTokenById: (tenant_id: string, design_token_id: string, options?: Options) => Promise<DesignToken>;
5423
5442
  updateDesignTokenById: (tenant_id: string, design_token_id: string, body?: UpdateDesignTokenRequestBody, options?: Options) => Promise<DesignToken>;
package/dist/ParraAPI.js CHANGED
@@ -11,8 +11,8 @@ var __assign = (this && this.__assign) || function () {
11
11
  return __assign.apply(this, arguments);
12
12
  };
13
13
  Object.defineProperty(exports, "__esModule", { value: true });
14
- exports.CampaignActionType = exports.CardItemDisplayType = exports.CardItemType = exports.QuestionKind = exports.QuestionType = exports.SubmitCommentReviewStatus = exports.CommentReviewStatus = exports.FeedChannelType = exports.ReactionType = exports.FeedItemType = exports.SocialAccountType = exports.CreatorUpdateGiveawayCriteria = exports.CreatorUpdateChannelType = exports.CreatorUpdateStatus = exports.CreatorUpdateVisibilityType = exports.CreatorUpdateTopic = exports.LessonType = exports.AttachmentType = exports.ChannelMemberRole = exports.ChannelMemberType = exports.ChatChannelStatus = exports.ChatChannelType = exports.BillingSourceType = exports.ApplePurchaseType = exports.ApplePurchaseEnvironment = exports.PurchaseEnvironment = exports.PurchasePlatform = exports.PurchaseStatus = exports.PurchaseType = exports.PaywallIapType = exports.AppPaywallType = exports.ShareAssetType = exports.ThemeCornerRadiusStyle = exports.SubscriptionStatus = exports.Interval = exports.Currency = exports.FeedbackFormFieldType = exports.ContentCardActionType = exports.IdentityType = exports.PolicyDocumentType = exports.AppleSsoScope = exports.DomainStatus = exports.DomainType = exports.ApplicationType = exports.ReleaseType = exports.ReleaseStatus = exports.TicketIconType = exports.TicketPriority = exports.TicketStatus = exports.TicketType = void 0;
15
- exports.PolicyDocumentVersionStatus = exports.PolicyDocumentStatus = exports.MailTemplateStatus = exports.MailTemplateVersionStatus = exports.MailTemplateType = exports.TenantUserMetricType = exports.IntegrationScope = exports.IntegrationConnectionStatus = exports.IntegrationType = exports.ConnectedAppConnectionStatus = exports.ConnectedAppType = exports.TenantOnboardingGoal = exports.DashboardChecklistItemStatus = exports.DashboardChecklistItemType = exports.RefreshTokenRotationType = exports.RefreshTokenExpirationType = exports.JwtAlgorithm = exports.GrantType = exports.ClientType = exports.PasswordlessStrategy = exports.SsoProvider = exports.SettingsItemType = exports.ApnsPushType = exports.ApnsEnvironment = exports.ChannelType = exports.AppVersionStatus = exports.TicketDisplayStatus = exports.UserNoteStatus = exports.TicketLinkType = exports.BoardType = exports.TemplateType = exports.CampaignStatus = exports.CampaignActionDisplayType = void 0;
14
+ exports.CardItemDisplayType = exports.CardItemType = exports.QuestionKind = exports.QuestionType = exports.SubmitCommentReviewStatus = exports.CommentReviewStatus = exports.FeedChannelType = exports.ReactionType = exports.FeedItemType = exports.SocialAccountType = exports.CreatorUpdateGiveawayCriteria = exports.CreatorUpdateChannelType = exports.CreatorUpdateStatus = exports.CreatorUpdateVisibilityType = exports.CreatorUpdateTopic = exports.LessonType = exports.AttachmentType = exports.ChannelMemberRole = exports.ChannelMemberType = exports.ChatChannelStatus = exports.ChatChannelType = exports.BillingSourceType = exports.ApplePurchaseType = exports.ApplePurchaseEnvironment = exports.PurchaseEnvironment = exports.PurchasePlatform = exports.PurchaseStatus = exports.PurchaseType = exports.PaywallIapType = exports.AppPaywallType = exports.ShareAssetType = exports.DesignTokenType = exports.ThemeCornerRadiusStyle = exports.SubscriptionStatus = exports.Interval = exports.Currency = exports.FeedbackFormFieldType = exports.ContentCardActionType = exports.IdentityType = exports.PolicyDocumentType = exports.AppleSsoScope = exports.DomainStatus = exports.DomainType = exports.ApplicationType = exports.ReleaseType = exports.ReleaseStatus = exports.TicketIconType = exports.TicketPriority = exports.TicketStatus = exports.TicketType = void 0;
15
+ exports.PolicyDocumentVersionStatus = exports.PolicyDocumentStatus = exports.MailTemplateStatus = exports.MailTemplateVersionStatus = exports.MailTemplateType = exports.TenantUserMetricType = exports.IntegrationScope = exports.IntegrationConnectionStatus = exports.IntegrationType = exports.ConnectedAppConnectionStatus = exports.ConnectedAppType = exports.TenantOnboardingGoal = exports.DashboardChecklistItemStatus = exports.DashboardChecklistItemType = exports.RefreshTokenRotationType = exports.RefreshTokenExpirationType = exports.JwtAlgorithm = exports.GrantType = exports.ClientType = exports.PasswordlessStrategy = exports.SsoProvider = exports.SettingsItemType = exports.ApnsPushType = exports.ApnsEnvironment = exports.ChannelType = exports.AppVersionStatus = exports.TicketDisplayStatus = exports.UserNoteStatus = exports.TicketLinkType = exports.BoardType = exports.TemplateType = exports.CampaignStatus = exports.CampaignActionDisplayType = exports.CampaignActionType = void 0;
16
16
  var TicketType;
17
17
  (function (TicketType) {
18
18
  TicketType["bug"] = "bug";
@@ -136,6 +136,13 @@ var ThemeCornerRadiusStyle;
136
136
  ThemeCornerRadiusStyle["circle"] = "circle";
137
137
  ThemeCornerRadiusStyle["square"] = "square";
138
138
  })(ThemeCornerRadiusStyle || (exports.ThemeCornerRadiusStyle = ThemeCornerRadiusStyle = {}));
139
+ var DesignTokenType;
140
+ (function (DesignTokenType) {
141
+ DesignTokenType["color"] = "color";
142
+ DesignTokenType["component"] = "component";
143
+ DesignTokenType["spacing"] = "spacing";
144
+ DesignTokenType["radius"] = "radius";
145
+ })(DesignTokenType || (exports.DesignTokenType = DesignTokenType = {}));
139
146
  var ShareAssetType;
140
147
  (function (ShareAssetType) {
141
148
  ShareAssetType["creatorUpdate"] = "creator_update";
@@ -731,6 +738,10 @@ var ParraAPI = /** @class */ (function () {
731
738
  if (options === void 0) { options = {}; }
732
739
  return _this.http.execute(__assign({ path: "".concat(_this.options.baseUrl, "/v1/tenants/").concat(tenant_id, "/brand/design-systems/").concat(design_system_id), method: "delete" }, options));
733
740
  };
741
+ this.listDesignTokensForDesignSystem = function (tenant_id, design_system_id, query, options) {
742
+ if (options === void 0) { options = {}; }
743
+ return _this.http.execute(__assign({ path: "".concat(_this.options.baseUrl, "/v1/tenants/").concat(tenant_id, "/brand/design-systems/").concat(design_system_id, "/tokens"), method: "get", query: query }, options));
744
+ };
734
745
  this.createTokenForDesignSystem = function (tenant_id, design_system_id, body, options) {
735
746
  if (options === void 0) { options = {}; }
736
747
  return _this.http.execute(__assign({ path: "".concat(_this.options.baseUrl, "/v1/tenants/").concat(tenant_id, "/brand/design-systems/").concat(design_system_id, "/tokens"), method: "post", body: JSON.stringify(body), headers: {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@parra/parra-js-sdk",
3
- "version": "0.3.549",
3
+ "version": "0.3.552",
4
4
  "description": "",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",