house-types 2.2.1 → 2.3.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.
package/dist/index.d.ts CHANGED
@@ -1,20 +1,17 @@
1
1
  import { z } from "zod";
2
2
  export declare const AlertSchema: z.ZodObject<{
3
- id: z.ZodString;
4
3
  city: z.ZodString;
5
4
  maxPrice: z.ZodEffects<z.ZodString, number, string>;
6
5
  minBedrooms: z.ZodEffects<z.ZodString, number, string>;
7
6
  furnishedOnly: z.ZodOptional<z.ZodBoolean>;
8
7
  propertyType: z.ZodOptional<z.ZodArray<z.ZodEnum<["house", "apartment", "studio", "shared-room"]>, "many">>;
9
8
  }, "strip", z.ZodTypeAny, {
10
- id: string;
11
9
  city: string;
12
10
  maxPrice: number;
13
11
  minBedrooms: number;
14
12
  furnishedOnly?: boolean | undefined;
15
13
  propertyType?: ("house" | "apartment" | "studio" | "shared-room")[] | undefined;
16
14
  }, {
17
- id: string;
18
15
  city: string;
19
16
  maxPrice: string;
20
17
  minBedrooms: string;
@@ -23,27 +20,23 @@ export declare const AlertSchema: z.ZodObject<{
23
20
  }>;
24
21
  export type Alert = z.infer<typeof AlertSchema>;
25
22
  export declare const UserSchema: z.ZodObject<{
26
- id: z.ZodString;
27
23
  notificationsEnabled: z.ZodDefault<z.ZodBoolean>;
28
24
  frequency: z.ZodEffects<z.ZodEnum<["5", "15", "60", "180", "360", "1440", "10080"]>, number, "5" | "15" | "60" | "180" | "360" | "1440" | "10080">;
29
25
  email: z.ZodString;
30
26
  lastNotified: z.ZodOptional<z.ZodString>;
31
27
  alerts: z.ZodDefault<z.ZodArray<z.ZodObject<{
32
- id: z.ZodString;
33
28
  city: z.ZodString;
34
29
  maxPrice: z.ZodEffects<z.ZodString, number, string>;
35
30
  minBedrooms: z.ZodEffects<z.ZodString, number, string>;
36
31
  furnishedOnly: z.ZodOptional<z.ZodBoolean>;
37
32
  propertyType: z.ZodOptional<z.ZodArray<z.ZodEnum<["house", "apartment", "studio", "shared-room"]>, "many">>;
38
33
  }, "strip", z.ZodTypeAny, {
39
- id: string;
40
34
  city: string;
41
35
  maxPrice: number;
42
36
  minBedrooms: number;
43
37
  furnishedOnly?: boolean | undefined;
44
38
  propertyType?: ("house" | "apartment" | "studio" | "shared-room")[] | undefined;
45
39
  }, {
46
- id: string;
47
40
  city: string;
48
41
  maxPrice: string;
49
42
  minBedrooms: string;
@@ -51,12 +44,10 @@ export declare const UserSchema: z.ZodObject<{
51
44
  propertyType?: ("house" | "apartment" | "studio" | "shared-room")[] | undefined;
52
45
  }>, "many">>;
53
46
  }, "strip", z.ZodTypeAny, {
54
- id: string;
55
47
  notificationsEnabled: boolean;
56
48
  frequency: number;
57
49
  email: string;
58
50
  alerts: {
59
- id: string;
60
51
  city: string;
61
52
  maxPrice: number;
62
53
  minBedrooms: number;
@@ -65,13 +56,11 @@ export declare const UserSchema: z.ZodObject<{
65
56
  }[];
66
57
  lastNotified?: string | undefined;
67
58
  }, {
68
- id: string;
69
59
  frequency: "5" | "15" | "60" | "180" | "360" | "1440" | "10080";
70
60
  email: string;
71
61
  notificationsEnabled?: boolean | undefined;
72
62
  lastNotified?: string | undefined;
73
63
  alerts?: {
74
- id: string;
75
64
  city: string;
76
65
  maxPrice: string;
77
66
  minBedrooms: string;
@@ -86,13 +75,13 @@ export declare const RawHouseSchema: z.ZodObject<{
86
75
  price: z.ZodEffects<z.ZodString, number, string>;
87
76
  image: z.ZodString;
88
77
  }, "strip", z.ZodTypeAny, {
89
- id: string;
90
78
  city: string;
79
+ id: string;
91
80
  price: number;
92
81
  image: string;
93
82
  }, {
94
- id: string;
95
83
  city: string;
84
+ id: string;
96
85
  price: string;
97
86
  image: string;
98
87
  }>;
@@ -112,9 +101,9 @@ export declare const HouseSchema: z.ZodObject<{
112
101
  image: z.ZodOptional<z.ZodString>;
113
102
  createdAt: z.ZodString;
114
103
  }, "strip", z.ZodTypeAny, {
115
- id: string;
116
104
  city: string;
117
105
  propertyType: "house" | "apartment" | "studio" | "shared-room";
106
+ id: string;
118
107
  price: number;
119
108
  bedrooms: number;
120
109
  roommates: number;
@@ -126,9 +115,9 @@ export declare const HouseSchema: z.ZodObject<{
126
115
  propertyGender?: "m" | "f" | "mixed" | undefined;
127
116
  furnished?: boolean | undefined;
128
117
  }, {
129
- id: string;
130
118
  city: string;
131
119
  propertyType: "house" | "apartment" | "studio" | "shared-room";
120
+ id: string;
132
121
  price: string;
133
122
  bedrooms: string;
134
123
  roommates: string;
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,eAAO,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;EAStB,CAAC;AAEH,MAAM,MAAM,KAAK,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,WAAW,CAAC,CAAC;AAEhD,eAAO,MAAM,UAAU;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAOrB,CAAC;AAEH,MAAM,MAAM,IAAI,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,UAAU,CAAC,CAAC;AAE9C,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;EAKzB,CAAC;AAEH,MAAM,MAAM,QAAQ,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC;AAEtD,eAAO,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EActB,CAAC;AAEH,MAAM,MAAM,KAAK,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,WAAW,CAAC,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,eAAO,MAAM,WAAW;;;;;;;;;;;;;;;;;;EAQtB,CAAC;AAEH,MAAM,MAAM,KAAK,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,WAAW,CAAC,CAAC;AAEhD,eAAO,MAAM,UAAU;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAMrB,CAAC;AAEH,MAAM,MAAM,IAAI,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,UAAU,CAAC,CAAC;AAE9C,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;EAKzB,CAAC;AAEH,MAAM,MAAM,QAAQ,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC;AAEtD,eAAO,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EActB,CAAC;AAEH,MAAM,MAAM,KAAK,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,WAAW,CAAC,CAAC"}
package/dist/index.js CHANGED
@@ -1,6 +1,5 @@
1
1
  import { z } from "zod";
2
2
  export const AlertSchema = z.object({
3
- id: z.string(),
4
3
  city: z.string(),
5
4
  maxPrice: z.string().regex(/^\d+$/).transform(Number),
6
5
  minBedrooms: z.string().regex(/^\d+$/).transform(Number),
@@ -10,7 +9,6 @@ export const AlertSchema = z.object({
10
9
  .optional(),
11
10
  });
12
11
  export const UserSchema = z.object({
13
- id: z.string(),
14
12
  notificationsEnabled: z.boolean().default(true),
15
13
  frequency: z.enum(["5", "15", "60", "180", "360", "1440", "10080"]).transform(Number),
16
14
  email: z.string().email(),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "house-types",
3
- "version": "2.2.1",
3
+ "version": "2.3.0",
4
4
  "description": "",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",