chopme-frontend-common 1.0.37 → 1.0.39

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.
@@ -0,0 +1,6 @@
1
+ import { z } from "zod";
2
+ export declare const createRestaurantRatingSchema: z.ZodObject<{
3
+ rating: z.ZodNumber;
4
+ comment: z.ZodString;
5
+ }, z.core.$strip>;
6
+ export type CreateRestaurantRatingDto = z.infer<typeof createRestaurantRatingSchema>;
@@ -0,0 +1,13 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.createRestaurantRatingSchema = void 0;
4
+ const zod_1 = require("zod");
5
+ exports.createRestaurantRatingSchema = zod_1.z.object({
6
+ rating: zod_1.z
7
+ .number({
8
+ error: "Rating is required",
9
+ })
10
+ .min(1, "Rating must be at least 1")
11
+ .max(5, "Rating cannot be greater than 5"),
12
+ comment: zod_1.z.string().trim().min(1, "Comment is required"),
13
+ });
@@ -2,3 +2,4 @@ export * from "./create-client.dto";
2
2
  export * from "./email-password-login.dto";
3
3
  export * from "./update-address.dto";
4
4
  export * from "./find-restaurant.dto";
5
+ export * from './create-rating.dto';
@@ -18,3 +18,4 @@ __exportStar(require("./create-client.dto"), exports);
18
18
  __exportStar(require("./email-password-login.dto"), exports);
19
19
  __exportStar(require("./update-address.dto"), exports);
20
20
  __exportStar(require("./find-restaurant.dto"), exports);
21
+ __exportStar(require("./create-rating.dto"), exports);
@@ -3,6 +3,7 @@ export type IMenu = {
3
3
  id: string;
4
4
  name: string;
5
5
  restaurantId: string;
6
+ restaurantSlug: string;
6
7
  category: ICategoryEntity;
7
8
  description?: string;
8
9
  coverImage?: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "chopme-frontend-common",
3
- "version": "1.0.37",
3
+ "version": "1.0.39",
4
4
  "description": "",
5
5
  "main": "build/index.js",
6
6
  "types": "build/index.d.ts",