@vedhae/cms-schema 4.2.15 → 4.2.16

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.
@@ -1,19 +1,19 @@
1
1
  import { z } from "zod";
2
2
  export declare const CustomerReviewSchema: z.ZodObject<{
3
3
  name: z.ZodString;
4
- date: z.ZodString;
4
+ date: z.ZodOptional<z.ZodString>;
5
5
  stars: z.ZodNumber;
6
6
  review: z.ZodString;
7
7
  }, "strip", z.ZodTypeAny, {
8
- date: string;
9
8
  name: string;
10
9
  stars: number;
11
10
  review: string;
11
+ date?: string | undefined;
12
12
  }, {
13
- date: string;
14
13
  name: string;
15
14
  stars: number;
16
15
  review: string;
16
+ date?: string | undefined;
17
17
  }>;
18
18
  export type CustomerReview = z.infer<typeof CustomerReviewSchema>;
19
19
  /**
@@ -57,19 +57,19 @@ export declare const ProductSchema: z.ZodEffects<z.ZodObject<{
57
57
  ingredients: z.ZodArray<z.ZodTuple<[z.ZodString, z.ZodString], null>, "many">;
58
58
  reviews: z.ZodOptional<z.ZodArray<z.ZodObject<{
59
59
  name: z.ZodString;
60
- date: z.ZodString;
60
+ date: z.ZodOptional<z.ZodString>;
61
61
  stars: z.ZodNumber;
62
62
  review: z.ZodString;
63
63
  }, "strip", z.ZodTypeAny, {
64
- date: string;
65
64
  name: string;
66
65
  stars: number;
67
66
  review: string;
67
+ date?: string | undefined;
68
68
  }, {
69
- date: string;
70
69
  name: string;
71
70
  stars: number;
72
71
  review: string;
72
+ date?: string | undefined;
73
73
  }>, "many">>;
74
74
  active: z.ZodBoolean;
75
75
  order: z.ZodNumber;
@@ -106,10 +106,10 @@ export declare const ProductSchema: z.ZodEffects<z.ZodObject<{
106
106
  discountPercent?: number | undefined;
107
107
  priceSubText?: string | undefined;
108
108
  reviews?: {
109
- date: string;
110
109
  name: string;
111
110
  stars: number;
112
111
  review: string;
112
+ date?: string | undefined;
113
113
  }[] | undefined;
114
114
  }, {
115
115
  title: string;
@@ -142,10 +142,10 @@ export declare const ProductSchema: z.ZodEffects<z.ZodObject<{
142
142
  discountPercent?: number | undefined;
143
143
  priceSubText?: string | undefined;
144
144
  reviews?: {
145
- date: string;
146
145
  name: string;
147
146
  stars: number;
148
147
  review: string;
148
+ date?: string | undefined;
149
149
  }[] | undefined;
150
150
  }>, {
151
151
  title: string;
@@ -178,10 +178,10 @@ export declare const ProductSchema: z.ZodEffects<z.ZodObject<{
178
178
  discountPercent?: number | undefined;
179
179
  priceSubText?: string | undefined;
180
180
  reviews?: {
181
- date: string;
182
181
  name: string;
183
182
  stars: number;
184
183
  review: string;
184
+ date?: string | undefined;
185
185
  }[] | undefined;
186
186
  }, {
187
187
  title: string;
@@ -214,10 +214,10 @@ export declare const ProductSchema: z.ZodEffects<z.ZodObject<{
214
214
  discountPercent?: number | undefined;
215
215
  priceSubText?: string | undefined;
216
216
  reviews?: {
217
- date: string;
218
217
  name: string;
219
218
  stars: number;
220
219
  review: string;
220
+ date?: string | undefined;
221
221
  }[] | undefined;
222
222
  }>;
223
223
  export type Product = z.infer<typeof ProductSchema>;
@@ -2,7 +2,7 @@ import { z } from "zod";
2
2
  import { ImageAssetSchema } from "./image.schema.js";
3
3
  export const CustomerReviewSchema = z.object({
4
4
  name: z.string().min(1),
5
- date: z.string().min(1),
5
+ date: z.string().optional(),
6
6
  stars: z.number().min(0).max(5),
7
7
  review: z.string().min(1),
8
8
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vedhae/cms-schema",
3
- "version": "4.2.15",
3
+ "version": "4.2.16",
4
4
  "type": "module",
5
5
  "main": "./dist/index.js",
6
6
  "types": "./dist/index.d.ts",