@deallony/shared 1.2.37 → 1.2.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.
@@ -20,11 +20,18 @@ export declare const PaymentGateways: {
20
20
  readonly ar: "بايميرا";
21
21
  };
22
22
  };
23
+ readonly WALLET_BALANCE: {
24
+ readonly value: "wallet_balance";
25
+ readonly name: {
26
+ readonly en: "Wallet Balance";
27
+ readonly ar: "رصيد المحفظة";
28
+ };
29
+ };
23
30
  };
24
31
  export declare const PaymentGatewayValues: [string, ...string[]];
25
32
  export type PaymentGateway = (typeof PaymentGatewayValues)[number];
26
33
  export declare const PaymentGatewayOptions: {
27
- value: "sham_cash_api" | "sham_cash_manual" | "paymera";
34
+ value: "sham_cash_api" | "sham_cash_manual" | "paymera" | "wallet_balance";
28
35
  name: {
29
36
  readonly en: "Sham Cash";
30
37
  readonly ar: "شام كاش";
@@ -34,5 +41,8 @@ export declare const PaymentGatewayOptions: {
34
41
  } | {
35
42
  readonly en: "Paymera";
36
43
  readonly ar: "بايميرا";
44
+ } | {
45
+ readonly en: "Wallet Balance";
46
+ readonly ar: "رصيد المحفظة";
37
47
  };
38
48
  }[];
@@ -11,6 +11,10 @@ exports.PaymentGateways = {
11
11
  name: { en: "Sham Cash (Manual)", ar: "شام كاش (يدوي)" },
12
12
  },
13
13
  PAYMERA: { value: "paymera", name: { en: "Paymera", ar: "بايميرا" } },
14
+ WALLET_BALANCE: {
15
+ value: "wallet_balance",
16
+ name: { en: "Wallet Balance", ar: "رصيد المحفظة" },
17
+ },
14
18
  };
15
19
  exports.PaymentGatewayValues = Object.values(exports.PaymentGateways).map((g) => g.value);
16
20
  exports.PaymentGatewayOptions = Object.values(exports.PaymentGateways).map((g) => ({
@@ -2,8 +2,8 @@ import { z } from "zod";
2
2
  export declare const eventBaseSchema: z.ZodObject<{
3
3
  lat: z.ZodNullable<z.ZodOptional<z.ZodCoercedNumber<unknown>>>;
4
4
  long: z.ZodNullable<z.ZodOptional<z.ZodCoercedNumber<unknown>>>;
5
- start_date: z.ZodNullable<z.ZodOptional<z.ZodCoercedDate<unknown>>>;
6
- end_date: z.ZodNullable<z.ZodOptional<z.ZodCoercedDate<unknown>>>;
5
+ start_date: z.ZodNullable<z.ZodOptional<z.ZodISODateTime>>;
6
+ end_date: z.ZodNullable<z.ZodOptional<z.ZodISODateTime>>;
7
7
  is_published: z.ZodOptional<z.ZodBoolean>;
8
8
  slug: z.ZodString;
9
9
  wedding: z.ZodObject<{
@@ -37,8 +37,8 @@ export declare const eventBaseSchema: z.ZodObject<{
37
37
  export declare const createEventSchema: z.ZodObject<{
38
38
  lat: z.ZodNullable<z.ZodOptional<z.ZodCoercedNumber<unknown>>>;
39
39
  long: z.ZodNullable<z.ZodOptional<z.ZodCoercedNumber<unknown>>>;
40
- start_date: z.ZodNullable<z.ZodOptional<z.ZodCoercedDate<unknown>>>;
41
- end_date: z.ZodNullable<z.ZodOptional<z.ZodCoercedDate<unknown>>>;
40
+ start_date: z.ZodNullable<z.ZodOptional<z.ZodISODateTime>>;
41
+ end_date: z.ZodNullable<z.ZodOptional<z.ZodISODateTime>>;
42
42
  is_published: z.ZodOptional<z.ZodBoolean>;
43
43
  slug: z.ZodString;
44
44
  wedding: z.ZodObject<{
@@ -72,8 +72,8 @@ export declare const createEventSchema: z.ZodObject<{
72
72
  export declare const updateEventSchema: z.ZodObject<{
73
73
  lat: z.ZodNullable<z.ZodOptional<z.ZodCoercedNumber<unknown>>>;
74
74
  long: z.ZodNullable<z.ZodOptional<z.ZodCoercedNumber<unknown>>>;
75
- start_date: z.ZodNullable<z.ZodOptional<z.ZodCoercedDate<unknown>>>;
76
- end_date: z.ZodNullable<z.ZodOptional<z.ZodCoercedDate<unknown>>>;
75
+ start_date: z.ZodNullable<z.ZodOptional<z.ZodISODateTime>>;
76
+ end_date: z.ZodNullable<z.ZodOptional<z.ZodISODateTime>>;
77
77
  is_published: z.ZodOptional<z.ZodBoolean>;
78
78
  slug: z.ZodString;
79
79
  wedding: z.ZodObject<{
@@ -108,8 +108,8 @@ export declare const updateEventSchema: z.ZodObject<{
108
108
  export declare const saveEventSchema: z.ZodObject<{
109
109
  lat: z.ZodNullable<z.ZodOptional<z.ZodCoercedNumber<unknown>>>;
110
110
  long: z.ZodNullable<z.ZodOptional<z.ZodCoercedNumber<unknown>>>;
111
- start_date: z.ZodNullable<z.ZodOptional<z.ZodCoercedDate<unknown>>>;
112
- end_date: z.ZodNullable<z.ZodOptional<z.ZodCoercedDate<unknown>>>;
111
+ start_date: z.ZodNullable<z.ZodOptional<z.ZodISODateTime>>;
112
+ end_date: z.ZodNullable<z.ZodOptional<z.ZodISODateTime>>;
113
113
  is_published: z.ZodOptional<z.ZodBoolean>;
114
114
  slug: z.ZodString;
115
115
  wedding: z.ZodObject<{
@@ -8,8 +8,8 @@ const events_1 = require("../../constants/events");
8
8
  exports.eventBaseSchema = zod_1.z.object({
9
9
  lat: zod_1.z.coerce.number().optional().nullable(),
10
10
  long: zod_1.z.coerce.number().optional().nullable(),
11
- start_date: zod_1.z.coerce.date().optional().nullable(),
12
- end_date: zod_1.z.coerce.date().optional().nullable(),
11
+ start_date: zod_1.z.iso.datetime().optional().nullable(),
12
+ end_date: zod_1.z.iso.datetime().optional().nullable(),
13
13
  is_published: zod_1.z.boolean().optional(),
14
14
  slug: zod_1.z.string().trim().min(1).max(255),
15
15
  wedding: EventWedding_schema_1.saveEventWeddingSchema,
@@ -1,4 +1,4 @@
1
- import { z } from 'zod';
1
+ import { z } from "zod";
2
2
  export declare const attendanceStatusValues: readonly ["attending", "not_attending", "maybe"];
3
3
  export declare const eventRsvpBaseSchema: z.ZodObject<{
4
4
  event_id: z.ZodCoercedNumber<unknown>;
@@ -12,7 +12,7 @@ export declare const eventRsvpBaseSchema: z.ZodObject<{
12
12
  }>;
13
13
  guest_count: z.ZodDefault<z.ZodCoercedNumber<unknown>>;
14
14
  message: z.ZodOptional<z.ZodNullable<z.ZodString>>;
15
- responded_at: z.ZodOptional<z.ZodCoercedDate<unknown>>;
15
+ responded_at: z.ZodOptional<z.ZodISODateTime>;
16
16
  }, z.core.$strip>;
17
17
  export declare const createEventRsvpSchema: z.ZodObject<{
18
18
  event_id: z.ZodCoercedNumber<unknown>;
@@ -26,7 +26,7 @@ export declare const createEventRsvpSchema: z.ZodObject<{
26
26
  }>;
27
27
  guest_count: z.ZodDefault<z.ZodCoercedNumber<unknown>>;
28
28
  message: z.ZodOptional<z.ZodNullable<z.ZodString>>;
29
- responded_at: z.ZodOptional<z.ZodCoercedDate<unknown>>;
29
+ responded_at: z.ZodOptional<z.ZodISODateTime>;
30
30
  }, z.core.$strip>;
31
31
  export declare const updateEventRsvpSchema: z.ZodObject<{
32
32
  event_id: z.ZodCoercedNumber<unknown>;
@@ -40,7 +40,7 @@ export declare const updateEventRsvpSchema: z.ZodObject<{
40
40
  }>;
41
41
  guest_count: z.ZodDefault<z.ZodCoercedNumber<unknown>>;
42
42
  message: z.ZodOptional<z.ZodNullable<z.ZodString>>;
43
- responded_at: z.ZodOptional<z.ZodCoercedDate<unknown>>;
43
+ responded_at: z.ZodOptional<z.ZodISODateTime>;
44
44
  id: z.ZodCoercedNumber<unknown>;
45
45
  }, z.core.$strip>;
46
46
  export declare const saveEventRsvpSchema: z.ZodObject<{
@@ -55,7 +55,7 @@ export declare const saveEventRsvpSchema: z.ZodObject<{
55
55
  }>;
56
56
  guest_count: z.ZodDefault<z.ZodCoercedNumber<unknown>>;
57
57
  message: z.ZodOptional<z.ZodNullable<z.ZodString>>;
58
- responded_at: z.ZodOptional<z.ZodCoercedDate<unknown>>;
58
+ responded_at: z.ZodOptional<z.ZodISODateTime>;
59
59
  id: z.ZodOptional<z.ZodCoercedNumber<unknown>>;
60
60
  }, z.core.$strip>;
61
61
  export declare const getEventRsvpFilterSchema: z.ZodObject<{
@@ -2,7 +2,11 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.getEventRsvpFilterSchema = exports.saveEventRsvpSchema = exports.updateEventRsvpSchema = exports.createEventRsvpSchema = exports.eventRsvpBaseSchema = exports.attendanceStatusValues = void 0;
4
4
  const zod_1 = require("zod");
5
- exports.attendanceStatusValues = ['attending', 'not_attending', 'maybe'];
5
+ exports.attendanceStatusValues = [
6
+ "attending",
7
+ "not_attending",
8
+ "maybe",
9
+ ];
6
10
  exports.eventRsvpBaseSchema = zod_1.z.object({
7
11
  event_id: zod_1.z.coerce.number().int().positive(),
8
12
  first_name: zod_1.z.string().trim().min(1).max(150),
@@ -11,7 +15,7 @@ exports.eventRsvpBaseSchema = zod_1.z.object({
11
15
  attendance_status: zod_1.z.enum(exports.attendanceStatusValues),
12
16
  guest_count: zod_1.z.coerce.number().int().positive().max(100).default(1),
13
17
  message: zod_1.z.string().trim().max(5000).nullable().optional(),
14
- responded_at: zod_1.z.coerce.date().optional(),
18
+ responded_at: zod_1.z.iso.datetime().optional(),
15
19
  });
16
20
  exports.createEventRsvpSchema = exports.eventRsvpBaseSchema;
17
21
  exports.updateEventRsvpSchema = exports.eventRsvpBaseSchema.extend({
@@ -8,6 +8,10 @@ export const PaymentGateways = {
8
8
  name: { en: "Sham Cash (Manual)", ar: "شام كاش (يدوي)" },
9
9
  },
10
10
  PAYMERA: { value: "paymera", name: { en: "Paymera", ar: "بايميرا" } },
11
+ WALLET_BALANCE: {
12
+ value: "wallet_balance",
13
+ name: { en: "Wallet Balance", ar: "رصيد المحفظة" },
14
+ },
11
15
  };
12
16
  export const PaymentGatewayValues = Object.values(PaymentGateways).map((g) => g.value);
13
17
  export const PaymentGatewayOptions = Object.values(PaymentGateways).map((g) => ({
@@ -5,8 +5,8 @@ import { EventInvitationScanTypeValues } from "../../constants/events/index.js";
5
5
  export const eventBaseSchema = z.object({
6
6
  lat: z.coerce.number().optional().nullable(),
7
7
  long: z.coerce.number().optional().nullable(),
8
- start_date: z.coerce.date().optional().nullable(),
9
- end_date: z.coerce.date().optional().nullable(),
8
+ start_date: z.iso.datetime().optional().nullable(),
9
+ end_date: z.iso.datetime().optional().nullable(),
10
10
  is_published: z.boolean().optional(),
11
11
  slug: z.string().trim().min(1).max(255),
12
12
  wedding: saveEventWeddingSchema,
@@ -1,5 +1,9 @@
1
- import { z } from 'zod';
2
- export const attendanceStatusValues = ['attending', 'not_attending', 'maybe'];
1
+ import { z } from "zod";
2
+ export const attendanceStatusValues = [
3
+ "attending",
4
+ "not_attending",
5
+ "maybe",
6
+ ];
3
7
  export const eventRsvpBaseSchema = z.object({
4
8
  event_id: z.coerce.number().int().positive(),
5
9
  first_name: z.string().trim().min(1).max(150),
@@ -8,7 +12,7 @@ export const eventRsvpBaseSchema = z.object({
8
12
  attendance_status: z.enum(attendanceStatusValues),
9
13
  guest_count: z.coerce.number().int().positive().max(100).default(1),
10
14
  message: z.string().trim().max(5000).nullable().optional(),
11
- responded_at: z.coerce.date().optional(),
15
+ responded_at: z.iso.datetime().optional(),
12
16
  });
13
17
  export const createEventRsvpSchema = eventRsvpBaseSchema;
14
18
  export const updateEventRsvpSchema = eventRsvpBaseSchema.extend({
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@deallony/shared",
3
- "version": "1.2.37",
3
+ "version": "1.2.39",
4
4
  "private": false,
5
5
  "main": "dist/cjs/index.js",
6
6
  "module": "dist/esm/index.js",