@coveo/thermidor-schema 1.0.0-beta.23 → 1.0.0-beta.24

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.
@@ -975,6 +975,7 @@ export declare const NextActionsBarActionsSchema: z.ZodObject<{
975
975
  }, z.core.$strict>;
976
976
  export type NextActionsBarActions = z.infer<typeof NextActionsBarActionsSchema>;
977
977
  export declare const BundleDisplayStateSchema: z.ZodObject<{
978
+ heading: z.ZodOptional<z.ZodString>;
978
979
  tiers: z.ZodArray<z.ZodObject<{
979
980
  description: z.ZodString;
980
981
  label: z.ZodString;
@@ -1371,6 +1372,7 @@ export declare const BundleDisplaySchema: z.ZodObject<{
1371
1372
  component: z.ZodLiteral<"BundleDisplay">;
1372
1373
  id: z.ZodString;
1373
1374
  state: z.ZodOptional<z.ZodObject<{
1375
+ heading: z.ZodOptional<z.ZodString>;
1374
1376
  tiers: z.ZodArray<z.ZodObject<{
1375
1377
  description: z.ZodString;
1376
1378
  label: z.ZodString;
@@ -1993,6 +1995,7 @@ export declare const ComponentContractsSchema: z.ZodDiscriminatedUnion<[z.ZodObj
1993
1995
  component: z.ZodLiteral<"BundleDisplay">;
1994
1996
  id: z.ZodString;
1995
1997
  state: z.ZodOptional<z.ZodObject<{
1998
+ heading: z.ZodOptional<z.ZodString>;
1996
1999
  tiers: z.ZodArray<z.ZodObject<{
1997
2000
  description: z.ZodString;
1998
2001
  label: z.ZodString;
@@ -2597,6 +2600,21 @@ export type DynamicAction = z.infer<typeof DynamicActionSchema>;
2597
2600
  * untouched. The resolved shape a renderer actually reads is the `XxxProps` type.
2598
2601
  */
2599
2602
  export declare const BundleDisplayPropsSchema: z.ZodObject<{
2603
+ heading: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
2604
+ path: z.ZodString;
2605
+ }, z.core.$strict>, z.ZodObject<{
2606
+ call: z.ZodString;
2607
+ args: z.ZodRecord<z.ZodString, z.ZodAny>;
2608
+ returnType: z.ZodDefault<z.ZodEnum<{
2609
+ any: "any";
2610
+ array: "array";
2611
+ boolean: "boolean";
2612
+ number: "number";
2613
+ object: "object";
2614
+ string: "string";
2615
+ void: "void";
2616
+ }>>;
2617
+ }, z.core.$strip>]>>;
2600
2618
  tiers: z.ZodUnion<readonly [z.ZodArray<z.ZodObject<{
2601
2619
  description: z.ZodString;
2602
2620
  label: z.ZodString;
@@ -3085,7 +3103,7 @@ export declare const NumericFacetPropsSchema: z.ZodObject<{
3085
3103
  void: "void";
3086
3104
  }>>;
3087
3105
  }, z.core.$strip>]>;
3088
- domain: z.ZodUnion<readonly [z.ZodOptional<z.ZodObject<{
3106
+ domain: z.ZodOptional<z.ZodUnion<readonly [z.ZodOptional<z.ZodObject<{
3089
3107
  max: z.ZodOptional<z.ZodNumber>;
3090
3108
  min: z.ZodOptional<z.ZodNumber>;
3091
3109
  }, z.core.$strict>>, z.ZodObject<{
@@ -3102,7 +3120,7 @@ export declare const NumericFacetPropsSchema: z.ZodObject<{
3102
3120
  string: "string";
3103
3121
  void: "void";
3104
3122
  }>>;
3105
- }, z.core.$strip>]>;
3123
+ }, z.core.$strip>]>>;
3106
3124
  }, z.core.$strip>;
3107
3125
  export declare const PageSizePropsSchema: z.ZodObject<{
3108
3126
  pageSize: z.ZodUnion<readonly [z.ZodNumber, z.ZodObject<{
@@ -469,6 +469,7 @@ export const NextActionsBarActionsSchema = z.strictObject({
469
469
  selectSearchOption: SelectSearchOptionSchema,
470
470
  });
471
471
  export const BundleDisplayStateSchema = z.strictObject({
472
+ heading: z.string().optional(),
472
473
  tiers: z.array(BundleTierSchema),
473
474
  });
474
475
  export const ComparisonTableSchema = z.looseObject({
@@ -711,6 +712,7 @@ export const DynamicActionSchema = z.object({
711
712
  * untouched. The resolved shape a renderer actually reads is the `XxxProps` type.
712
713
  */
713
714
  export const BundleDisplayPropsSchema = z.object({
715
+ heading: DynamicStringSchema.optional(),
714
716
  tiers: z.union([BundleDisplayStateSchema.shape['tiers'], DataBindingSchema, FunctionCallSchema]),
715
717
  });
716
718
  export const CartPropsSchema = z.object({});
@@ -787,7 +789,9 @@ export const NumericFacetPropsSchema = z.object({
787
789
  hasActiveValues: DynamicBooleanSchema,
788
790
  canShowMoreValues: DynamicBooleanSchema,
789
791
  canShowLessValues: DynamicBooleanSchema,
790
- domain: z.union([NumericFacetStateSchema.shape['domain'], DataBindingSchema, FunctionCallSchema]),
792
+ domain: z
793
+ .union([NumericFacetStateSchema.shape['domain'], DataBindingSchema, FunctionCallSchema])
794
+ .optional(),
791
795
  });
792
796
  export const PageSizePropsSchema = z.object({
793
797
  pageSize: DynamicNumberSchema,
@@ -3628,6 +3628,7 @@ export declare const NextActionsBarActionsSchema: z.ZodObject<{
3628
3628
  }>;
3629
3629
  export type NextActionsBarActions = z.infer<typeof NextActionsBarActionsSchema>;
3630
3630
  export declare const BundleDisplayStateSchema: z.ZodObject<{
3631
+ heading: z.ZodOptional<z.ZodString>;
3631
3632
  tiers: z.ZodArray<z.ZodObject<{
3632
3633
  description: z.ZodString;
3633
3634
  label: z.ZodString;
@@ -3660,6 +3661,7 @@ export declare const BundleDisplayStateSchema: z.ZodObject<{
3660
3661
  total: number;
3661
3662
  }>, "many">;
3662
3663
  }, "strict", z.ZodTypeAny, {
3664
+ heading?: string | undefined;
3663
3665
  tiers: {
3664
3666
  description: string;
3665
3667
  label: string;
@@ -3670,6 +3672,7 @@ export declare const BundleDisplayStateSchema: z.ZodObject<{
3670
3672
  total: number;
3671
3673
  }[];
3672
3674
  }, {
3675
+ heading?: string | undefined;
3673
3676
  tiers: {
3674
3677
  description: string;
3675
3678
  label: string;
@@ -6091,6 +6094,7 @@ export declare const BundleDisplaySchema: z.ZodObject<{
6091
6094
  component: z.ZodLiteral<"BundleDisplay">;
6092
6095
  id: z.ZodString;
6093
6096
  state: z.ZodOptional<z.ZodObject<{
6097
+ heading: z.ZodOptional<z.ZodString>;
6094
6098
  tiers: z.ZodArray<z.ZodObject<{
6095
6099
  description: z.ZodString;
6096
6100
  label: z.ZodString;
@@ -6123,6 +6127,7 @@ export declare const BundleDisplaySchema: z.ZodObject<{
6123
6127
  total: number;
6124
6128
  }>, "many">;
6125
6129
  }, "strict", z.ZodTypeAny, {
6130
+ heading?: string | undefined;
6126
6131
  tiers: {
6127
6132
  description: string;
6128
6133
  label: string;
@@ -6133,6 +6138,7 @@ export declare const BundleDisplaySchema: z.ZodObject<{
6133
6138
  total: number;
6134
6139
  }[];
6135
6140
  }, {
6141
+ heading?: string | undefined;
6136
6142
  tiers: {
6137
6143
  description: string;
6138
6144
  label: string;
@@ -6148,6 +6154,7 @@ export declare const BundleDisplaySchema: z.ZodObject<{
6148
6154
  component: z.ZodLiteral<"BundleDisplay">;
6149
6155
  id: z.ZodString;
6150
6156
  state: z.ZodOptional<z.ZodObject<{
6157
+ heading: z.ZodOptional<z.ZodString>;
6151
6158
  tiers: z.ZodArray<z.ZodObject<{
6152
6159
  description: z.ZodString;
6153
6160
  label: z.ZodString;
@@ -6180,6 +6187,7 @@ export declare const BundleDisplaySchema: z.ZodObject<{
6180
6187
  total: number;
6181
6188
  }>, "many">;
6182
6189
  }, "strict", z.ZodTypeAny, {
6190
+ heading?: string | undefined;
6183
6191
  tiers: {
6184
6192
  description: string;
6185
6193
  label: string;
@@ -6190,6 +6198,7 @@ export declare const BundleDisplaySchema: z.ZodObject<{
6190
6198
  total: number;
6191
6199
  }[];
6192
6200
  }, {
6201
+ heading?: string | undefined;
6193
6202
  tiers: {
6194
6203
  description: string;
6195
6204
  label: string;
@@ -6205,6 +6214,7 @@ export declare const BundleDisplaySchema: z.ZodObject<{
6205
6214
  component: z.ZodLiteral<"BundleDisplay">;
6206
6215
  id: z.ZodString;
6207
6216
  state: z.ZodOptional<z.ZodObject<{
6217
+ heading: z.ZodOptional<z.ZodString>;
6208
6218
  tiers: z.ZodArray<z.ZodObject<{
6209
6219
  description: z.ZodString;
6210
6220
  label: z.ZodString;
@@ -6237,6 +6247,7 @@ export declare const BundleDisplaySchema: z.ZodObject<{
6237
6247
  total: number;
6238
6248
  }>, "many">;
6239
6249
  }, "strict", z.ZodTypeAny, {
6250
+ heading?: string | undefined;
6240
6251
  tiers: {
6241
6252
  description: string;
6242
6253
  label: string;
@@ -6247,6 +6258,7 @@ export declare const BundleDisplaySchema: z.ZodObject<{
6247
6258
  total: number;
6248
6259
  }[];
6249
6260
  }, {
6261
+ heading?: string | undefined;
6250
6262
  tiers: {
6251
6263
  description: string;
6252
6264
  label: string;
@@ -13720,6 +13732,7 @@ export declare const ComponentContractsSchema: z.ZodDiscriminatedUnion<"componen
13720
13732
  component: z.ZodLiteral<"BundleDisplay">;
13721
13733
  id: z.ZodString;
13722
13734
  state: z.ZodOptional<z.ZodObject<{
13735
+ heading: z.ZodOptional<z.ZodString>;
13723
13736
  tiers: z.ZodArray<z.ZodObject<{
13724
13737
  description: z.ZodString;
13725
13738
  label: z.ZodString;
@@ -13752,6 +13765,7 @@ export declare const ComponentContractsSchema: z.ZodDiscriminatedUnion<"componen
13752
13765
  total: number;
13753
13766
  }>, "many">;
13754
13767
  }, "strict", z.ZodTypeAny, {
13768
+ heading?: string | undefined;
13755
13769
  tiers: {
13756
13770
  description: string;
13757
13771
  label: string;
@@ -13762,6 +13776,7 @@ export declare const ComponentContractsSchema: z.ZodDiscriminatedUnion<"componen
13762
13776
  total: number;
13763
13777
  }[];
13764
13778
  }, {
13779
+ heading?: string | undefined;
13765
13780
  tiers: {
13766
13781
  description: string;
13767
13782
  label: string;
@@ -13777,6 +13792,7 @@ export declare const ComponentContractsSchema: z.ZodDiscriminatedUnion<"componen
13777
13792
  component: z.ZodLiteral<"BundleDisplay">;
13778
13793
  id: z.ZodString;
13779
13794
  state: z.ZodOptional<z.ZodObject<{
13795
+ heading: z.ZodOptional<z.ZodString>;
13780
13796
  tiers: z.ZodArray<z.ZodObject<{
13781
13797
  description: z.ZodString;
13782
13798
  label: z.ZodString;
@@ -13809,6 +13825,7 @@ export declare const ComponentContractsSchema: z.ZodDiscriminatedUnion<"componen
13809
13825
  total: number;
13810
13826
  }>, "many">;
13811
13827
  }, "strict", z.ZodTypeAny, {
13828
+ heading?: string | undefined;
13812
13829
  tiers: {
13813
13830
  description: string;
13814
13831
  label: string;
@@ -13819,6 +13836,7 @@ export declare const ComponentContractsSchema: z.ZodDiscriminatedUnion<"componen
13819
13836
  total: number;
13820
13837
  }[];
13821
13838
  }, {
13839
+ heading?: string | undefined;
13822
13840
  tiers: {
13823
13841
  description: string;
13824
13842
  label: string;
@@ -13834,6 +13852,7 @@ export declare const ComponentContractsSchema: z.ZodDiscriminatedUnion<"componen
13834
13852
  component: z.ZodLiteral<"BundleDisplay">;
13835
13853
  id: z.ZodString;
13836
13854
  state: z.ZodOptional<z.ZodObject<{
13855
+ heading: z.ZodOptional<z.ZodString>;
13837
13856
  tiers: z.ZodArray<z.ZodObject<{
13838
13857
  description: z.ZodString;
13839
13858
  label: z.ZodString;
@@ -13866,6 +13885,7 @@ export declare const ComponentContractsSchema: z.ZodDiscriminatedUnion<"componen
13866
13885
  total: number;
13867
13886
  }>, "many">;
13868
13887
  }, "strict", z.ZodTypeAny, {
13888
+ heading?: string | undefined;
13869
13889
  tiers: {
13870
13890
  description: string;
13871
13891
  label: string;
@@ -13876,6 +13896,7 @@ export declare const ComponentContractsSchema: z.ZodDiscriminatedUnion<"componen
13876
13896
  total: number;
13877
13897
  }[];
13878
13898
  }, {
13899
+ heading?: string | undefined;
13879
13900
  tiers: {
13880
13901
  description: string;
13881
13902
  label: string;
@@ -19952,6 +19973,25 @@ export type DynamicAction = z.infer<typeof DynamicActionSchema>;
19952
19973
  * untouched. The resolved shape a renderer actually reads is the `XxxProps` type.
19953
19974
  */
19954
19975
  export declare const BundleDisplayPropsSchema: z.ZodObject<{
19976
+ heading: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodObject<{
19977
+ path: z.ZodString;
19978
+ }, "strict", z.ZodTypeAny, {
19979
+ path: string;
19980
+ }, {
19981
+ path: string;
19982
+ }>, z.ZodObject<{
19983
+ call: z.ZodString;
19984
+ args: z.ZodRecord<z.ZodString, z.ZodAny>;
19985
+ returnType: z.ZodDefault<z.ZodEnum<["string", "number", "boolean", "array", "object", "any", "void"]>>;
19986
+ }, "strip", z.ZodTypeAny, {
19987
+ call: string;
19988
+ args: Record<string, any>;
19989
+ returnType: "any" | "array" | "boolean" | "number" | "object" | "string" | "void";
19990
+ }, {
19991
+ call: string;
19992
+ args: Record<string, any>;
19993
+ returnType?: "any" | "array" | "boolean" | "number" | "object" | "string" | "void" | undefined;
19994
+ }>]>>;
19955
19995
  tiers: z.ZodUnion<[z.ZodArray<z.ZodObject<{
19956
19996
  description: z.ZodString;
19957
19997
  label: z.ZodString;
@@ -20002,6 +20042,13 @@ export declare const BundleDisplayPropsSchema: z.ZodObject<{
20002
20042
  returnType?: "any" | "array" | "boolean" | "number" | "object" | "string" | "void" | undefined;
20003
20043
  }>]>;
20004
20044
  }, "strip", z.ZodTypeAny, {
20045
+ heading?: string | {
20046
+ path: string;
20047
+ } | {
20048
+ call: string;
20049
+ args: Record<string, any>;
20050
+ returnType: "any" | "array" | "boolean" | "number" | "object" | "string" | "void";
20051
+ } | undefined;
20005
20052
  tiers: {
20006
20053
  description: string;
20007
20054
  label: string;
@@ -20018,6 +20065,13 @@ export declare const BundleDisplayPropsSchema: z.ZodObject<{
20018
20065
  returnType: "any" | "array" | "boolean" | "number" | "object" | "string" | "void";
20019
20066
  };
20020
20067
  }, {
20068
+ heading?: string | {
20069
+ path: string;
20070
+ } | {
20071
+ call: string;
20072
+ args: Record<string, any>;
20073
+ returnType?: "any" | "array" | "boolean" | "number" | "object" | "string" | "void" | undefined;
20074
+ } | undefined;
20021
20075
  tiers: {
20022
20076
  description: string;
20023
20077
  label: string;
@@ -21130,7 +21184,7 @@ export declare const NumericFacetPropsSchema: z.ZodObject<{
21130
21184
  args: Record<string, any>;
21131
21185
  returnType?: "any" | "array" | "boolean" | "number" | "object" | "string" | "void" | undefined;
21132
21186
  }>]>;
21133
- domain: z.ZodUnion<[z.ZodOptional<z.ZodObject<{
21187
+ domain: z.ZodOptional<z.ZodUnion<[z.ZodOptional<z.ZodObject<{
21134
21188
  max: z.ZodOptional<z.ZodNumber>;
21135
21189
  min: z.ZodOptional<z.ZodNumber>;
21136
21190
  }, "strict", z.ZodTypeAny, {
@@ -21157,7 +21211,7 @@ export declare const NumericFacetPropsSchema: z.ZodObject<{
21157
21211
  call: string;
21158
21212
  args: Record<string, any>;
21159
21213
  returnType?: "any" | "array" | "boolean" | "number" | "object" | "string" | "void" | undefined;
21160
- }>]>;
21214
+ }>]>>;
21161
21215
  }, "strip", z.ZodTypeAny, {
21162
21216
  field: string | {
21163
21217
  path: string;
@@ -471,6 +471,7 @@ export const NextActionsBarActionsSchema = z.strictObject({
471
471
  selectSearchOption: SelectSearchOptionSchema,
472
472
  });
473
473
  export const BundleDisplayStateSchema = z.strictObject({
474
+ heading: z.string().optional(),
474
475
  tiers: z.array(BundleTierSchema),
475
476
  });
476
477
  export const ComparisonTableSchema = z.looseObject({
@@ -713,6 +714,7 @@ export const DynamicActionSchema = z.object({
713
714
  * untouched. The resolved shape a renderer actually reads is the `XxxProps` type.
714
715
  */
715
716
  export const BundleDisplayPropsSchema = z.object({
717
+ heading: DynamicStringSchema.optional(),
716
718
  tiers: z.union([BundleDisplayStateSchema.shape['tiers'], DataBindingSchema, FunctionCallSchema]),
717
719
  });
718
720
  export const CartPropsSchema = z.object({});
@@ -789,7 +791,9 @@ export const NumericFacetPropsSchema = z.object({
789
791
  hasActiveValues: DynamicBooleanSchema,
790
792
  canShowMoreValues: DynamicBooleanSchema,
791
793
  canShowLessValues: DynamicBooleanSchema,
792
- domain: z.union([NumericFacetStateSchema.shape['domain'], DataBindingSchema, FunctionCallSchema]),
794
+ domain: z
795
+ .union([NumericFacetStateSchema.shape['domain'], DataBindingSchema, FunctionCallSchema])
796
+ .optional(),
793
797
  });
794
798
  export const PageSizePropsSchema = z.object({
795
799
  pageSize: DynamicNumberSchema,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@coveo/thermidor-schema",
3
- "version": "1.0.0-beta.23",
3
+ "version": "1.0.0-beta.24",
4
4
  "description": "Zod and TypeScript projections of the Thermidor JSON Schema contract.",
5
5
  "homepage": "https://github.com/coveo-platform/thermidor-schema#readme",
6
6
  "bugs": {
@@ -16,6 +16,10 @@
16
16
  "type": "string",
17
17
  "const": "BundleDisplay"
18
18
  },
19
+ "heading": {
20
+ "$ref": "https://schema.thermidor.coveo.com/definitions/data-binding.schema.json",
21
+ "description": "The optional bundle heading, bound to /state/<id>/heading."
22
+ },
19
23
  "tiers": {
20
24
  "$ref": "https://schema.thermidor.coveo.com/definitions/data-binding.schema.json",
21
25
  "description": "The tiered bundle layout, bound to /state/<id>/tiers via a { \"path\": ... } Data_Binding."
@@ -38,6 +42,10 @@
38
42
  "type": "object",
39
43
  "required": ["tiers"],
40
44
  "properties": {
45
+ "heading": {
46
+ "type": "string",
47
+ "description": "Shopper-facing title displayed above the bundle tiers. Renderers omit the heading when it is absent."
48
+ },
41
49
  "tiers": {
42
50
  "type": "array",
43
51
  "description": "Ordered list of bundle tiers to render.",