@loczer/storefront-sdk 0.185.0 → 0.187.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.
@@ -26,6 +26,13 @@ export declare const storefrontFulfillmentModeSchema: z.ZodEnum<{
26
26
  delivery: "delivery";
27
27
  }>;
28
28
  export type StorefrontFulfillmentMode = z.infer<typeof storefrontFulfillmentModeSchema>;
29
+ export declare const STOREFRONT_HERO_MODES: readonly ["current_booking_hero", "booking_bar_overlay_hero", "vertical_marquee_hero"];
30
+ export declare const storefrontHeroModeSchema: z.ZodEnum<{
31
+ current_booking_hero: "current_booking_hero";
32
+ booking_bar_overlay_hero: "booking_bar_overlay_hero";
33
+ vertical_marquee_hero: "vertical_marquee_hero";
34
+ }>;
35
+ export type StorefrontHeroMode = z.infer<typeof storefrontHeroModeSchema>;
29
36
  export declare const storefrontSettingsSchema: z.ZodObject<{
30
37
  status: z.ZodEnum<{
31
38
  unpublished: "unpublished";
@@ -163,6 +170,11 @@ export declare const storefrontFaqSchema: z.ZodObject<{
163
170
  }, z.core.$strip>;
164
171
  export type StorefrontFaq = z.infer<typeof storefrontFaqSchema>;
165
172
  export declare const storefrontContentSchema: z.ZodObject<{
173
+ heroMode: z.ZodDefault<z.ZodEnum<{
174
+ current_booking_hero: "current_booking_hero";
175
+ booking_bar_overlay_hero: "booking_bar_overlay_hero";
176
+ vertical_marquee_hero: "vertical_marquee_hero";
177
+ }>>;
166
178
  tagline: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
167
179
  value: z.ZodString;
168
180
  updatedAt: z.ZodCoercedDate<unknown>;
@@ -475,6 +487,11 @@ export declare const storefrontConfigurationSchema: z.ZodObject<{
475
487
  };
476
488
  }, unknown>>;
477
489
  content: z.ZodOptional<z.ZodObject<{
490
+ heroMode: z.ZodDefault<z.ZodEnum<{
491
+ current_booking_hero: "current_booking_hero";
492
+ booking_bar_overlay_hero: "booking_bar_overlay_hero";
493
+ vertical_marquee_hero: "vertical_marquee_hero";
494
+ }>>;
478
495
  tagline: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
479
496
  value: z.ZodString;
480
497
  updatedAt: z.ZodCoercedDate<unknown>;
@@ -1 +1 @@
1
- {"version":3,"file":"storefrontSchemas.d.ts","sourceRoot":"","sources":["../src/storefrontSchemas.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAwBvB,eAAO,MAAM,wBAAwB;;;;;kBAO1B,CAAA;AACX,eAAO,MAAM,iCAAiC;;;;;mBAE5C,CAAA;AA0CF,eAAO,MAAM,sBAAsB;;;EAAuC,CAAA;AAC1E,MAAM,MAAM,gBAAgB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,sBAAsB,CAAC,CAAA;AAErE,eAAO,MAAM,4BAA4B;;;EAAqE,CAAA;AAC9G,MAAM,MAAM,sBAAsB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,4BAA4B,CAAC,CAAA;AAEjF,eAAO,MAAM,+BAA+B;;;EAAiC,CAAA;AAC7E,MAAM,MAAM,yBAAyB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,+BAA+B,CAAC,CAAA;AAIvF,eAAO,MAAM,wBAAwB;;;;;;;;;;;;;;;;;;;;;;;;;;iBAQnC,CAAA;AACF,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,wBAAwB,CAAC,CAAA;AAEzE,eAAO,MAAM,oBAAoB;;;;;;;;;;;;;;;;iBAgB/B,CAAA;AACF,MAAM,MAAM,cAAc,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,oBAAoB,CAAC,CAAA;AAEjE,eAAO,MAAM,yBAAyB;;;;;;;iBAIpC,CAAA;AACF,MAAM,MAAM,mBAAmB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,yBAAyB,CAAC,CAAA;AAE3E,eAAO,MAAM,uBAAuB;;;;;;;;;;;;iBAIlC,CAA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K,CAAC,OAAO,6BAA6B,CAAC,CAAA;AAEnF,eAAO,MAAM,uBAAuB;;;;;iBAElC,CAAA;AACF,MAAM,MAAM,iBAAiB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,uBAAuB,CAAC,CAAA;AAEvE,eAAO,MAAM,6BAA6B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAQxC,CAAA;AACF,MAAM,MAAM,uBAAuB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,6BAA6B,CAAC,CAAA"}
@@ -32,15 +32,19 @@ var r = n.string().trim().regex(/^\+[1-9]\d{1,14}$/, { message: "Invalid phone n
32
32
  }, d = n.preprocess((e) => {
33
33
  let t = a.safeParse(e);
34
34
  return t.success ? Object.fromEntries(Object.entries(t.data).map(([e, t]) => [e, u(t.value)])) : e;
35
- }, c), f = n.string().regex(/^[0-9]{4}-[0-9]{2}-[0-9]{2}$/), p = t, m = n.enum(["unpublished", "published"]), h = n.enum(["auto_approve_when_possible", "manual_approval_required"]), g = n.enum(["pickup", "delivery"]), _ = t.shape.availabilityDisplay, v = n.object({
35
+ }, c), f = n.string().regex(/^[0-9]{4}-[0-9]{2}-[0-9]{2}$/), p = t, m = n.enum(["unpublished", "published"]), h = n.enum(["auto_approve_when_possible", "manual_approval_required"]), g = n.enum(["pickup", "delivery"]), _ = [
36
+ "current_booking_hero",
37
+ "booking_bar_overlay_hero",
38
+ "vertical_marquee_hero"
39
+ ], v = n.enum(_), y = t.shape.availabilityDisplay, b = n.object({
36
40
  status: m,
37
41
  checkoutMode: h,
38
- availabilityDisplay: _,
42
+ availabilityDisplay: y,
39
43
  enabled: n.boolean(),
40
44
  fulfillmentModes: n.array(g).min(1),
41
45
  deliveryDisabledReason: n.string().trim().default(""),
42
46
  sameDayCutoff: e
43
- }), y = n.object({
47
+ }), x = n.object({
44
48
  id: n.string().min(1),
45
49
  slug: n.string().min(1).optional(),
46
50
  name: n.string().min(1),
@@ -56,15 +60,15 @@ var r = n.string().trim().regex(/^\+[1-9]\d{1,14}$/, { message: "Invalid phone n
56
60
  city: n.string().min(1).optional(),
57
61
  country: n.string().min(1).optional(),
58
62
  gpsCoordinates: n.tuple([n.number(), n.number()]).optional()
59
- }), b = n.object({
63
+ }), S = n.object({
60
64
  name: n.string().min(1).optional(),
61
65
  workspaceLanguage: n.enum(["fr", "en"]).optional(),
62
66
  languages: n.array(n.string().min(1)).optional()
63
- }), x = n.object({
67
+ }), C = n.object({
64
68
  id: n.string().min(1),
65
69
  question: o,
66
70
  answer: o
67
- }), S = n.object({
71
+ }), w = n.object({
68
72
  id: n.string().min(1),
69
73
  enabled: n.boolean().default(!0),
70
74
  showOnEachVisit: n.boolean().default(!1),
@@ -74,11 +78,12 @@ var r = n.string().trim().regex(/^\+[1-9]\d{1,14}$/, { message: "Invalid phone n
74
78
  subtitle: a.optional(),
75
79
  message: d.optional(),
76
80
  imageIds: n.array(n.string().min(1)).default([])
77
- }), C = n.object({
78
- general: n.array(x).default([]),
79
- deliveries: n.array(x).default([]),
80
- booking: n.array(x).default([])
81
- }), w = n.object({
81
+ }), T = n.object({
82
+ general: n.array(C).default([]),
83
+ deliveries: n.array(C).default([]),
84
+ booking: n.array(C).default([])
85
+ }), E = n.object({
86
+ heroMode: v.default("current_booking_hero"),
82
87
  tagline: a.optional(),
83
88
  logoSquareImageId: n.string().min(1).optional(),
84
89
  logoWideImageId: n.string().min(1).optional(),
@@ -89,23 +94,23 @@ var r = n.string().trim().regex(/^\+[1-9]\d{1,14}$/, { message: "Invalid phone n
89
94
  whatsappPhone2Enabled: n.boolean().default(!1),
90
95
  whatsappMessage: a.optional(),
91
96
  showWhatsappFloatingButton: n.boolean().default(!0),
92
- modalMessages: n.array(S).default([]),
93
- faq: C.default({
97
+ modalMessages: n.array(w).default([]),
98
+ faq: T.default({
94
99
  general: [],
95
100
  deliveries: [],
96
101
  booking: []
97
102
  })
98
- }), T = n.object({
103
+ }), D = n.object({
99
104
  enabled: n.boolean(),
100
105
  showRecentReviewsOnStorefront: n.boolean()
101
- }), E = n.object({ reviews: T.optional() }), D = n.object({
106
+ }), O = n.object({ reviews: D.optional() }), k = n.object({
102
107
  storeSlug: n.string().min(1),
103
- workspace: b.optional(),
104
- shop: y,
105
- settings: v,
108
+ workspace: S.optional(),
109
+ shop: x,
110
+ settings: b,
106
111
  bookingEngine: p,
107
- content: w.optional(),
108
- modules: E.optional()
112
+ content: E.optional(),
113
+ modules: O.optional()
109
114
  });
110
115
  //#endregion
111
- export { h as storefrontCheckoutModeSchema, D as storefrontConfigurationSchema, w as storefrontContentSchema, x as storefrontFaqItemSchema, C as storefrontFaqSchema, g as storefrontFulfillmentModeSchema, c as storefrontLocalizedRichTextSchema, S as storefrontModalMessageSchema, E as storefrontModulesSchema, T as storefrontReviewsModuleSchema, s as storefrontRichTextSchema, v as storefrontSettingsSchema, y as storefrontShopSchema, m as storefrontStatusSchema, b as storefrontWorkspaceSchema };
116
+ export { _ as STOREFRONT_HERO_MODES, h as storefrontCheckoutModeSchema, k as storefrontConfigurationSchema, E as storefrontContentSchema, C as storefrontFaqItemSchema, T as storefrontFaqSchema, g as storefrontFulfillmentModeSchema, v as storefrontHeroModeSchema, c as storefrontLocalizedRichTextSchema, w as storefrontModalMessageSchema, O as storefrontModulesSchema, D as storefrontReviewsModuleSchema, s as storefrontRichTextSchema, b as storefrontSettingsSchema, x as storefrontShopSchema, m as storefrontStatusSchema, S as storefrontWorkspaceSchema };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@loczer/storefront-sdk",
3
- "version": "0.185.0",
3
+ "version": "0.187.0",
4
4
  "publishConfig": {
5
5
  "access": "public",
6
6
  "registry": "https://registry.npmjs.org/"