@burdenoff/microfe-housingvista 2026.830.2 → 2026.923.1
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/housingvista/components/maps/CoordinatePicker.d.ts +19 -0
- package/dist/housingvista/components/maps/CoordinatePicker.d.ts.map +1 -0
- package/dist/housingvista/components/maps/CoordinatePicker.js +148 -0
- package/dist/housingvista/components/maps/CoordinatePicker.js.map +1 -0
- package/dist/housingvista/components/maps/index.d.ts +2 -0
- package/dist/housingvista/components/maps/index.d.ts.map +1 -1
- package/dist/housingvista/components/maps/index.js +1 -0
- package/dist/housingvista/hooks/index.d.ts +5 -0
- package/dist/housingvista/hooks/index.d.ts.map +1 -1
- package/dist/housingvista/hooks/index.js.map +1 -1
- package/dist/housingvista/pages/properties/AddPropertyPage.d.ts.map +1 -1
- package/dist/housingvista/pages/properties/AddPropertyPage.js +287 -274
- package/dist/housingvista/pages/properties/AddPropertyPage.js.map +1 -1
- package/dist/housingvista/types/index.d.ts.map +1 -1
- package/dist/node_modules/react-leaflet/lib/hooks.js +1 -1
- package/package.json +1 -1
|
@@ -6,98 +6,99 @@ import { useCreateProperty as a } from "../../hooks/index.js";
|
|
|
6
6
|
import { notify as o } from "../../lib/toast.js";
|
|
7
7
|
import { FileUploader as s } from "../../components/FileUploader.js";
|
|
8
8
|
import "../../components/index.js";
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
9
|
+
import { CoordinatePicker as c } from "../../components/maps/CoordinatePicker.js";
|
|
10
|
+
import { useCallback as l, useState as u } from "react";
|
|
11
|
+
import { Bath as d, Bed as f, Calendar as p, Car as m, CheckCircle as h, ChevronLeft as g, ChevronRight as _, DollarSign as v, Dumbbell as y, Flame as b, Home as x, MapPin as S, Maximize as C, Shield as w, TreePine as T, Upload as E, Waves as D, Wifi as O, Wind as k } from "lucide-react";
|
|
12
|
+
import { useNavigate as A } from "react-router";
|
|
13
|
+
import { jsx as j, jsxs as M } from "react/jsx-runtime";
|
|
14
|
+
import { EmphasisPanel as N } from "@burdenoff/fe-libs/ui";
|
|
14
15
|
//#region src/housingvista/pages/properties/AddPropertyPage.tsx
|
|
15
|
-
var
|
|
16
|
+
var P = {
|
|
16
17
|
sale: "for_sale",
|
|
17
18
|
rent: "for_rent",
|
|
18
19
|
lease: "for_rent"
|
|
19
|
-
},
|
|
20
|
+
}, F = {
|
|
20
21
|
sale: "sale",
|
|
21
22
|
rent: "rent",
|
|
22
23
|
lease: "lease"
|
|
23
|
-
},
|
|
24
|
+
}, I = [
|
|
24
25
|
{
|
|
25
26
|
id: "basic",
|
|
26
27
|
label: "Basic Info",
|
|
27
|
-
icon:
|
|
28
|
+
icon: x
|
|
28
29
|
},
|
|
29
30
|
{
|
|
30
31
|
id: "location",
|
|
31
32
|
label: "Location",
|
|
32
|
-
icon:
|
|
33
|
+
icon: S
|
|
33
34
|
},
|
|
34
35
|
{
|
|
35
36
|
id: "specs",
|
|
36
37
|
label: "Specifications",
|
|
37
|
-
icon:
|
|
38
|
+
icon: C
|
|
38
39
|
},
|
|
39
40
|
{
|
|
40
41
|
id: "amenities",
|
|
41
42
|
label: "Amenities",
|
|
42
|
-
icon:
|
|
43
|
+
icon: O
|
|
43
44
|
},
|
|
44
45
|
{
|
|
45
46
|
id: "pricing",
|
|
46
47
|
label: "Pricing",
|
|
47
|
-
icon:
|
|
48
|
+
icon: v
|
|
48
49
|
},
|
|
49
50
|
{
|
|
50
51
|
id: "images",
|
|
51
52
|
label: "Images",
|
|
52
|
-
icon:
|
|
53
|
+
icon: E
|
|
53
54
|
}
|
|
54
|
-
],
|
|
55
|
+
], L = [
|
|
55
56
|
{
|
|
56
57
|
id: "swimming_pool",
|
|
57
58
|
label: "Swimming Pool",
|
|
58
|
-
icon:
|
|
59
|
+
icon: D
|
|
59
60
|
},
|
|
60
61
|
{
|
|
61
62
|
id: "gym",
|
|
62
63
|
label: "Gym / Fitness",
|
|
63
|
-
icon:
|
|
64
|
+
icon: y
|
|
64
65
|
},
|
|
65
66
|
{
|
|
66
67
|
id: "parking",
|
|
67
68
|
label: "Parking",
|
|
68
|
-
icon:
|
|
69
|
+
icon: m
|
|
69
70
|
},
|
|
70
71
|
{
|
|
71
72
|
id: "garden",
|
|
72
73
|
label: "Garden",
|
|
73
|
-
icon:
|
|
74
|
+
icon: T
|
|
74
75
|
},
|
|
75
76
|
{
|
|
76
77
|
id: "security",
|
|
77
78
|
label: "24/7 Security",
|
|
78
|
-
icon:
|
|
79
|
+
icon: w
|
|
79
80
|
},
|
|
80
81
|
{
|
|
81
82
|
id: "wifi",
|
|
82
83
|
label: "Wi-Fi",
|
|
83
|
-
icon:
|
|
84
|
+
icon: O
|
|
84
85
|
},
|
|
85
86
|
{
|
|
86
87
|
id: "fireplace",
|
|
87
88
|
label: "Fireplace",
|
|
88
|
-
icon:
|
|
89
|
+
icon: b
|
|
89
90
|
},
|
|
90
91
|
{
|
|
91
92
|
id: "ac",
|
|
92
93
|
label: "Central AC",
|
|
93
|
-
icon:
|
|
94
|
+
icon: k
|
|
94
95
|
}
|
|
95
|
-
],
|
|
96
|
+
], R = [{
|
|
96
97
|
label: "Properties",
|
|
97
98
|
href: "../"
|
|
98
|
-
}, { label: "Add New" }],
|
|
99
|
+
}, { label: "Add New" }], z = () => {
|
|
99
100
|
i("housingvista.property.create_viewed");
|
|
100
|
-
let
|
|
101
|
+
let y = A(), { createProperty: b, loading: x } = a(), { emitResource: w } = r(), [T, D] = u(0), [O, k] = u({
|
|
101
102
|
title: "",
|
|
102
103
|
description: "",
|
|
103
104
|
propertyType: "residential",
|
|
@@ -109,6 +110,7 @@ var N = {
|
|
|
109
110
|
zipCode: "",
|
|
110
111
|
neighborhood: "",
|
|
111
112
|
country: "USA",
|
|
113
|
+
coordinates: null,
|
|
112
114
|
bedrooms: "",
|
|
113
115
|
bathrooms: "",
|
|
114
116
|
area: "",
|
|
@@ -122,132 +124,133 @@ var N = {
|
|
|
122
124
|
currency: "USD",
|
|
123
125
|
negotiable: !1,
|
|
124
126
|
images: []
|
|
125
|
-
}),
|
|
126
|
-
|
|
127
|
+
}), z = l((e) => {
|
|
128
|
+
k((t) => {
|
|
127
129
|
let n = new Set(t.images.map((e) => e.id)), r = [...t.images, ...e.filter((e) => !n.has(e.id))];
|
|
128
130
|
return {
|
|
129
131
|
...t,
|
|
130
132
|
images: r
|
|
131
133
|
};
|
|
132
134
|
});
|
|
133
|
-
}, []),
|
|
134
|
-
|
|
135
|
+
}, []), B = l((e) => {
|
|
136
|
+
k((t) => ({
|
|
135
137
|
...t,
|
|
136
138
|
images: t.images.filter((t) => t.id !== e)
|
|
137
139
|
}));
|
|
138
|
-
}, []),
|
|
140
|
+
}, []), V = l((e) => {
|
|
139
141
|
let { name: t, value: n, type: r } = e.target;
|
|
140
|
-
|
|
142
|
+
k((i) => ({
|
|
141
143
|
...i,
|
|
142
144
|
[t]: r === "checkbox" ? e.target.checked : n
|
|
143
145
|
}));
|
|
144
|
-
}, []),
|
|
145
|
-
|
|
146
|
+
}, []), H = l((e) => {
|
|
147
|
+
k((t) => ({
|
|
146
148
|
...t,
|
|
147
149
|
amenities: t.amenities.includes(e) ? t.amenities.filter((t) => t !== e) : [...t.amenities, e]
|
|
148
150
|
}));
|
|
149
|
-
}, []),
|
|
150
|
-
switch (
|
|
151
|
-
case 0: return
|
|
152
|
-
case 1: return
|
|
153
|
-
case 2: return
|
|
151
|
+
}, []), U = () => {
|
|
152
|
+
switch (T) {
|
|
153
|
+
case 0: return O.title.trim() !== "" && O.description.trim() !== "";
|
|
154
|
+
case 1: return O.address.trim() !== "" && O.city.trim() !== "" && O.state.trim() !== "";
|
|
155
|
+
case 2: return O.area.trim() !== "";
|
|
154
156
|
case 3: return !0;
|
|
155
|
-
case 4: return
|
|
157
|
+
case 4: return O.price.trim() !== "";
|
|
156
158
|
case 5: return !0;
|
|
157
159
|
default: return !1;
|
|
158
160
|
}
|
|
159
|
-
},
|
|
161
|
+
}, W = async () => {
|
|
160
162
|
let e = {
|
|
161
|
-
title:
|
|
162
|
-
description:
|
|
163
|
-
status:
|
|
164
|
-
type:
|
|
165
|
-
category:
|
|
166
|
-
address:
|
|
167
|
-
city:
|
|
168
|
-
state:
|
|
169
|
-
country:
|
|
170
|
-
pincode:
|
|
171
|
-
neighborhood:
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
163
|
+
title: O.title.trim(),
|
|
164
|
+
description: O.description.trim() || void 0,
|
|
165
|
+
status: P[O.listingType] ?? "for_sale",
|
|
166
|
+
type: O.propertyType,
|
|
167
|
+
category: O.category,
|
|
168
|
+
address: O.address.trim() || void 0,
|
|
169
|
+
city: O.city.trim(),
|
|
170
|
+
state: O.state.trim(),
|
|
171
|
+
country: O.country || void 0,
|
|
172
|
+
pincode: O.zipCode.trim() || void 0,
|
|
173
|
+
neighborhood: O.neighborhood.trim() || void 0,
|
|
174
|
+
coordinates: O.coordinates ?? void 0,
|
|
175
|
+
price: Number(O.price) || 0,
|
|
176
|
+
currency: O.currency,
|
|
177
|
+
priceType: F[O.listingType] ?? "sale",
|
|
178
|
+
negotiable: O.negotiable,
|
|
179
|
+
bedrooms: Number(O.bedrooms) || 0,
|
|
180
|
+
bathrooms: Number(O.bathrooms) || 0,
|
|
181
|
+
totalArea: Number(O.area) || 0,
|
|
182
|
+
floors: O.floors ? Number(O.floors) : void 0,
|
|
183
|
+
parking: O.parking ? Number(O.parking) : void 0,
|
|
184
|
+
furnishingStatus: O.furnishing,
|
|
185
|
+
ageOfProperty: O.yearBuilt ? Math.max(0, (/* @__PURE__ */ new Date()).getFullYear() - Number(O.yearBuilt)) : void 0,
|
|
186
|
+
facing: O.facing,
|
|
187
|
+
amenities: O.amenities.map((e) => ({
|
|
188
|
+
name: L.find((t) => t.id === e)?.label ?? e,
|
|
186
189
|
category: "general",
|
|
187
190
|
available: !0
|
|
188
191
|
})),
|
|
189
|
-
images:
|
|
192
|
+
images: O.images.map((e, t) => ({
|
|
190
193
|
url: e.url,
|
|
191
194
|
isPrimary: t === 0,
|
|
192
195
|
order: t
|
|
193
196
|
}))
|
|
194
197
|
};
|
|
195
198
|
try {
|
|
196
|
-
let t = await
|
|
197
|
-
|
|
199
|
+
let t = await b(e);
|
|
200
|
+
w("housingvista.property.created", t.id), o.success("Property created", `${t.title} has been added to your listings.`), y(`../properties/${t.id}`);
|
|
198
201
|
} catch (e) {
|
|
199
202
|
o.error("Could not create property", e.message);
|
|
200
203
|
}
|
|
201
|
-
},
|
|
202
|
-
return /* @__PURE__ */
|
|
204
|
+
}, G = T === I.length - 1;
|
|
205
|
+
return /* @__PURE__ */ M(t, {
|
|
203
206
|
title: "Add New Property",
|
|
204
207
|
description: "List your property for sale or rent",
|
|
205
208
|
purpose: "Create a complete, market-ready listing in a few guided steps. Fill in the basics, location, specifications, amenities, pricing, and photos — the more detail you add, the more inquiries and stronger offers your property attracts.",
|
|
206
209
|
children: [
|
|
207
|
-
/* @__PURE__ */
|
|
208
|
-
/* @__PURE__ */
|
|
210
|
+
/* @__PURE__ */ j(n, { items: R }),
|
|
211
|
+
/* @__PURE__ */ M(N, {
|
|
209
212
|
className: "p-5",
|
|
210
213
|
children: [
|
|
211
|
-
/* @__PURE__ */
|
|
214
|
+
/* @__PURE__ */ M("div", {
|
|
212
215
|
className: "mb-3 flex items-center justify-between",
|
|
213
|
-
children: [/* @__PURE__ */
|
|
216
|
+
children: [/* @__PURE__ */ M("div", { children: [/* @__PURE__ */ M("p", {
|
|
214
217
|
className: "text-xs font-medium uppercase tracking-wide text-text-secondary",
|
|
215
218
|
children: [
|
|
216
219
|
"Step ",
|
|
217
|
-
|
|
220
|
+
T + 1,
|
|
218
221
|
" of ",
|
|
219
|
-
|
|
222
|
+
I.length
|
|
220
223
|
]
|
|
221
|
-
}), /* @__PURE__ */
|
|
224
|
+
}), /* @__PURE__ */ j("p", {
|
|
222
225
|
className: "text-base font-semibold text-text-primary",
|
|
223
|
-
children:
|
|
224
|
-
})] }), /* @__PURE__ */
|
|
226
|
+
children: I[T].label
|
|
227
|
+
})] }), /* @__PURE__ */ M("span", {
|
|
225
228
|
className: "text-sm font-semibold text-text-primary",
|
|
226
|
-
children: [Math.round((
|
|
229
|
+
children: [Math.round((T + 1) / I.length * 100), "%"]
|
|
227
230
|
})]
|
|
228
231
|
}),
|
|
229
|
-
/* @__PURE__ */
|
|
232
|
+
/* @__PURE__ */ j("div", {
|
|
230
233
|
className: "h-1.5 w-full overflow-hidden rounded-full bg-bg-sunken",
|
|
231
|
-
children: /* @__PURE__ */
|
|
234
|
+
children: /* @__PURE__ */ j("div", {
|
|
232
235
|
className: "h-full rounded-full bg-action-primary-bg transition-[width] duration-300",
|
|
233
|
-
style: { width: `${(
|
|
236
|
+
style: { width: `${(T + 1) / I.length * 100}%` }
|
|
234
237
|
})
|
|
235
238
|
}),
|
|
236
|
-
/* @__PURE__ */
|
|
239
|
+
/* @__PURE__ */ j("div", {
|
|
237
240
|
className: "mt-4 flex items-center gap-1 overflow-x-auto pb-1",
|
|
238
|
-
children:
|
|
239
|
-
let r = t.icon, i = n ===
|
|
240
|
-
return /* @__PURE__ */
|
|
241
|
-
onClick: () => n <=
|
|
242
|
-
className: e("flex shrink-0 items-center gap-2 rounded-full px-3 py-1.5 text-sm font-medium transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[var(--color-focus-ring)]", i && "bg-action-primary-bg text-action-primary-text", a && "bg-status-success-bg-subtle text-status-success-text", !i && !a && "text-text-secondary hover:bg-bg-sunken/50", n >
|
|
243
|
-
disabled: n >
|
|
241
|
+
children: I.map((t, n) => {
|
|
242
|
+
let r = t.icon, i = n === T, a = n < T;
|
|
243
|
+
return /* @__PURE__ */ M("button", {
|
|
244
|
+
onClick: () => n <= T && D(n),
|
|
245
|
+
className: e("flex shrink-0 items-center gap-2 rounded-full px-3 py-1.5 text-sm font-medium transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[var(--color-focus-ring)]", i && "bg-action-primary-bg text-action-primary-text", a && "bg-status-success-bg-subtle text-status-success-text", !i && !a && "text-text-secondary hover:bg-bg-sunken/50", n > T && "cursor-not-allowed"),
|
|
246
|
+
disabled: n > T,
|
|
244
247
|
children: [
|
|
245
|
-
|
|
246
|
-
/* @__PURE__ */
|
|
248
|
+
j(a ? h : r, { className: "h-4 w-4" }),
|
|
249
|
+
/* @__PURE__ */ j("span", {
|
|
247
250
|
className: "hidden sm:inline",
|
|
248
251
|
children: t.label
|
|
249
252
|
}),
|
|
250
|
-
/* @__PURE__ */
|
|
253
|
+
/* @__PURE__ */ j("span", {
|
|
251
254
|
className: "sm:hidden",
|
|
252
255
|
children: n + 1
|
|
253
256
|
})
|
|
@@ -257,145 +260,145 @@ var N = {
|
|
|
257
260
|
})
|
|
258
261
|
]
|
|
259
262
|
}),
|
|
260
|
-
/* @__PURE__ */
|
|
263
|
+
/* @__PURE__ */ M("div", {
|
|
261
264
|
className: "max-w-3xl",
|
|
262
|
-
children: [/* @__PURE__ */
|
|
265
|
+
children: [/* @__PURE__ */ M("div", {
|
|
263
266
|
className: "rounded-lg border border-border-subtle bg-bg-surface p-6",
|
|
264
267
|
children: [
|
|
265
|
-
|
|
268
|
+
T === 0 && /* @__PURE__ */ M("div", {
|
|
266
269
|
className: "space-y-4",
|
|
267
270
|
children: [
|
|
268
|
-
/* @__PURE__ */
|
|
271
|
+
/* @__PURE__ */ j("h3", {
|
|
269
272
|
className: "text-lg font-semibold text-text-primary",
|
|
270
273
|
children: "Basic Information"
|
|
271
274
|
}),
|
|
272
|
-
/* @__PURE__ */
|
|
275
|
+
/* @__PURE__ */ M("div", { children: [/* @__PURE__ */ j("label", {
|
|
273
276
|
htmlFor: "title",
|
|
274
277
|
className: "mb-1.5 block text-sm font-medium text-text-primary",
|
|
275
278
|
children: "Property Title *"
|
|
276
|
-
}), /* @__PURE__ */
|
|
279
|
+
}), /* @__PURE__ */ j("input", {
|
|
277
280
|
id: "title",
|
|
278
281
|
name: "title",
|
|
279
|
-
value:
|
|
280
|
-
onChange:
|
|
282
|
+
value: O.title,
|
|
283
|
+
onChange: V,
|
|
281
284
|
placeholder: "e.g., Luxury 3BHK Apartment in Downtown",
|
|
282
285
|
required: !0,
|
|
283
286
|
className: "h-10 w-full rounded-md border border-border-subtle bg-bg-surface px-3 text-sm text-text-primary placeholder:text-text-secondary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]"
|
|
284
287
|
})] }),
|
|
285
|
-
/* @__PURE__ */
|
|
288
|
+
/* @__PURE__ */ M("div", { children: [/* @__PURE__ */ j("label", {
|
|
286
289
|
htmlFor: "description",
|
|
287
290
|
className: "mb-1.5 block text-sm font-medium text-text-primary",
|
|
288
291
|
children: "Description *"
|
|
289
|
-
}), /* @__PURE__ */
|
|
292
|
+
}), /* @__PURE__ */ j("textarea", {
|
|
290
293
|
id: "description",
|
|
291
294
|
name: "description",
|
|
292
|
-
value:
|
|
293
|
-
onChange:
|
|
295
|
+
value: O.description,
|
|
296
|
+
onChange: V,
|
|
294
297
|
placeholder: "Describe your property in detail...",
|
|
295
298
|
required: !0,
|
|
296
299
|
rows: 4,
|
|
297
300
|
className: "w-full rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary placeholder:text-text-secondary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]"
|
|
298
301
|
})] }),
|
|
299
|
-
/* @__PURE__ */
|
|
302
|
+
/* @__PURE__ */ M("div", {
|
|
300
303
|
className: "grid grid-cols-1 gap-4 sm:grid-cols-2",
|
|
301
|
-
children: [/* @__PURE__ */
|
|
304
|
+
children: [/* @__PURE__ */ M("div", { children: [/* @__PURE__ */ j("label", {
|
|
302
305
|
htmlFor: "propertyType",
|
|
303
306
|
className: "mb-1.5 block text-sm font-medium text-text-primary",
|
|
304
307
|
children: "Property Type *"
|
|
305
|
-
}), /* @__PURE__ */
|
|
308
|
+
}), /* @__PURE__ */ M("select", {
|
|
306
309
|
id: "propertyType",
|
|
307
310
|
name: "propertyType",
|
|
308
|
-
value:
|
|
309
|
-
onChange:
|
|
311
|
+
value: O.propertyType,
|
|
312
|
+
onChange: V,
|
|
310
313
|
className: "h-10 w-full rounded-md border border-border-subtle bg-bg-surface px-3 text-sm text-text-primary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]",
|
|
311
314
|
children: [
|
|
312
|
-
/* @__PURE__ */
|
|
315
|
+
/* @__PURE__ */ j("option", {
|
|
313
316
|
value: "residential",
|
|
314
317
|
children: "Residential"
|
|
315
318
|
}),
|
|
316
|
-
/* @__PURE__ */
|
|
319
|
+
/* @__PURE__ */ j("option", {
|
|
317
320
|
value: "commercial",
|
|
318
321
|
children: "Commercial"
|
|
319
322
|
}),
|
|
320
|
-
/* @__PURE__ */
|
|
323
|
+
/* @__PURE__ */ j("option", {
|
|
321
324
|
value: "industrial",
|
|
322
325
|
children: "Industrial"
|
|
323
326
|
}),
|
|
324
|
-
/* @__PURE__ */
|
|
327
|
+
/* @__PURE__ */ j("option", {
|
|
325
328
|
value: "agricultural",
|
|
326
329
|
children: "Agricultural"
|
|
327
330
|
}),
|
|
328
|
-
/* @__PURE__ */
|
|
331
|
+
/* @__PURE__ */ j("option", {
|
|
329
332
|
value: "mixed_use",
|
|
330
333
|
children: "Mixed Use"
|
|
331
334
|
})
|
|
332
335
|
]
|
|
333
|
-
})] }), /* @__PURE__ */
|
|
336
|
+
})] }), /* @__PURE__ */ M("div", { children: [/* @__PURE__ */ j("label", {
|
|
334
337
|
htmlFor: "category",
|
|
335
338
|
className: "mb-1.5 block text-sm font-medium text-text-primary",
|
|
336
339
|
children: "Category *"
|
|
337
|
-
}), /* @__PURE__ */
|
|
340
|
+
}), /* @__PURE__ */ M("select", {
|
|
338
341
|
id: "category",
|
|
339
342
|
name: "category",
|
|
340
|
-
value:
|
|
341
|
-
onChange:
|
|
343
|
+
value: O.category,
|
|
344
|
+
onChange: V,
|
|
342
345
|
className: "h-10 w-full rounded-md border border-border-subtle bg-bg-surface px-3 text-sm text-text-primary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]",
|
|
343
346
|
children: [
|
|
344
|
-
/* @__PURE__ */
|
|
347
|
+
/* @__PURE__ */ j("option", {
|
|
345
348
|
value: "apartment",
|
|
346
349
|
children: "Apartment"
|
|
347
350
|
}),
|
|
348
|
-
/* @__PURE__ */
|
|
351
|
+
/* @__PURE__ */ j("option", {
|
|
349
352
|
value: "house",
|
|
350
353
|
children: "House"
|
|
351
354
|
}),
|
|
352
|
-
/* @__PURE__ */
|
|
355
|
+
/* @__PURE__ */ j("option", {
|
|
353
356
|
value: "villa",
|
|
354
357
|
children: "Villa"
|
|
355
358
|
}),
|
|
356
|
-
/* @__PURE__ */
|
|
359
|
+
/* @__PURE__ */ j("option", {
|
|
357
360
|
value: "office",
|
|
358
361
|
children: "Office"
|
|
359
362
|
}),
|
|
360
|
-
/* @__PURE__ */
|
|
363
|
+
/* @__PURE__ */ j("option", {
|
|
361
364
|
value: "retail",
|
|
362
365
|
children: "Retail"
|
|
363
366
|
}),
|
|
364
|
-
/* @__PURE__ */
|
|
367
|
+
/* @__PURE__ */ j("option", {
|
|
365
368
|
value: "warehouse",
|
|
366
369
|
children: "Warehouse"
|
|
367
370
|
}),
|
|
368
|
-
/* @__PURE__ */
|
|
371
|
+
/* @__PURE__ */ j("option", {
|
|
369
372
|
value: "land",
|
|
370
373
|
children: "Land"
|
|
371
374
|
}),
|
|
372
|
-
/* @__PURE__ */
|
|
375
|
+
/* @__PURE__ */ j("option", {
|
|
373
376
|
value: "plot",
|
|
374
377
|
children: "Plot"
|
|
375
378
|
})
|
|
376
379
|
]
|
|
377
380
|
})] })]
|
|
378
381
|
}),
|
|
379
|
-
/* @__PURE__ */
|
|
382
|
+
/* @__PURE__ */ M("div", { children: [/* @__PURE__ */ j("label", {
|
|
380
383
|
htmlFor: "listingType",
|
|
381
384
|
className: "mb-1.5 block text-sm font-medium text-text-primary",
|
|
382
385
|
children: "Listing Type *"
|
|
383
|
-
}), /* @__PURE__ */
|
|
386
|
+
}), /* @__PURE__ */ M("select", {
|
|
384
387
|
id: "listingType",
|
|
385
388
|
name: "listingType",
|
|
386
|
-
value:
|
|
387
|
-
onChange:
|
|
389
|
+
value: O.listingType,
|
|
390
|
+
onChange: V,
|
|
388
391
|
className: "h-10 w-full rounded-md border border-border-subtle bg-bg-surface px-3 text-sm text-text-primary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)] sm:max-w-xs",
|
|
389
392
|
children: [
|
|
390
|
-
/* @__PURE__ */
|
|
393
|
+
/* @__PURE__ */ j("option", {
|
|
391
394
|
value: "sale",
|
|
392
395
|
children: "For Sale"
|
|
393
396
|
}),
|
|
394
|
-
/* @__PURE__ */
|
|
397
|
+
/* @__PURE__ */ j("option", {
|
|
395
398
|
value: "rent",
|
|
396
399
|
children: "For Rent"
|
|
397
400
|
}),
|
|
398
|
-
/* @__PURE__ */
|
|
401
|
+
/* @__PURE__ */ j("option", {
|
|
399
402
|
value: "lease",
|
|
400
403
|
children: "For Lease"
|
|
401
404
|
})
|
|
@@ -403,259 +406,269 @@ var N = {
|
|
|
403
406
|
})] })
|
|
404
407
|
]
|
|
405
408
|
}),
|
|
406
|
-
|
|
409
|
+
T === 1 && /* @__PURE__ */ M("div", {
|
|
407
410
|
className: "space-y-4",
|
|
408
411
|
children: [
|
|
409
|
-
/* @__PURE__ */
|
|
412
|
+
/* @__PURE__ */ M("h3", {
|
|
410
413
|
className: "flex items-center gap-2 text-lg font-semibold text-text-primary",
|
|
411
|
-
children: [/* @__PURE__ */
|
|
414
|
+
children: [/* @__PURE__ */ j(S, { className: "h-5 w-5" }), "Location Details"]
|
|
412
415
|
}),
|
|
413
|
-
/* @__PURE__ */
|
|
416
|
+
/* @__PURE__ */ M("div", { children: [/* @__PURE__ */ j("label", {
|
|
414
417
|
htmlFor: "address",
|
|
415
418
|
className: "mb-1.5 block text-sm font-medium text-text-primary",
|
|
416
419
|
children: "Street Address *"
|
|
417
|
-
}), /* @__PURE__ */
|
|
420
|
+
}), /* @__PURE__ */ j("input", {
|
|
418
421
|
id: "address",
|
|
419
422
|
name: "address",
|
|
420
|
-
value:
|
|
421
|
-
onChange:
|
|
423
|
+
value: O.address,
|
|
424
|
+
onChange: V,
|
|
422
425
|
placeholder: "e.g., 123 Main Street, Unit 2504",
|
|
423
426
|
required: !0,
|
|
424
427
|
className: "h-10 w-full rounded-md border border-border-subtle bg-bg-surface px-3 text-sm text-text-primary placeholder:text-text-secondary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]"
|
|
425
428
|
})] }),
|
|
426
|
-
/* @__PURE__ */
|
|
429
|
+
/* @__PURE__ */ M("div", { children: [/* @__PURE__ */ j("label", {
|
|
427
430
|
htmlFor: "neighborhood",
|
|
428
431
|
className: "mb-1.5 block text-sm font-medium text-text-primary",
|
|
429
432
|
children: "Neighborhood"
|
|
430
|
-
}), /* @__PURE__ */
|
|
433
|
+
}), /* @__PURE__ */ j("input", {
|
|
431
434
|
id: "neighborhood",
|
|
432
435
|
name: "neighborhood",
|
|
433
|
-
value:
|
|
434
|
-
onChange:
|
|
436
|
+
value: O.neighborhood,
|
|
437
|
+
onChange: V,
|
|
435
438
|
placeholder: "e.g., Midtown",
|
|
436
439
|
className: "h-10 w-full rounded-md border border-border-subtle bg-bg-surface px-3 text-sm text-text-primary placeholder:text-text-secondary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]"
|
|
437
440
|
})] }),
|
|
438
|
-
/* @__PURE__ */
|
|
441
|
+
/* @__PURE__ */ M("div", {
|
|
439
442
|
className: "grid grid-cols-1 gap-4 sm:grid-cols-3",
|
|
440
443
|
children: [
|
|
441
|
-
/* @__PURE__ */
|
|
444
|
+
/* @__PURE__ */ M("div", { children: [/* @__PURE__ */ j("label", {
|
|
442
445
|
htmlFor: "city",
|
|
443
446
|
className: "mb-1.5 block text-sm font-medium text-text-primary",
|
|
444
447
|
children: "City *"
|
|
445
|
-
}), /* @__PURE__ */
|
|
448
|
+
}), /* @__PURE__ */ j("input", {
|
|
446
449
|
id: "city",
|
|
447
450
|
name: "city",
|
|
448
|
-
value:
|
|
449
|
-
onChange:
|
|
451
|
+
value: O.city,
|
|
452
|
+
onChange: V,
|
|
450
453
|
placeholder: "City",
|
|
451
454
|
required: !0,
|
|
452
455
|
className: "h-10 w-full rounded-md border border-border-subtle bg-bg-surface px-3 text-sm text-text-primary placeholder:text-text-secondary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]"
|
|
453
456
|
})] }),
|
|
454
|
-
/* @__PURE__ */
|
|
457
|
+
/* @__PURE__ */ M("div", { children: [/* @__PURE__ */ j("label", {
|
|
455
458
|
htmlFor: "state",
|
|
456
459
|
className: "mb-1.5 block text-sm font-medium text-text-primary",
|
|
457
460
|
children: "State *"
|
|
458
|
-
}), /* @__PURE__ */
|
|
461
|
+
}), /* @__PURE__ */ j("input", {
|
|
459
462
|
id: "state",
|
|
460
463
|
name: "state",
|
|
461
|
-
value:
|
|
462
|
-
onChange:
|
|
464
|
+
value: O.state,
|
|
465
|
+
onChange: V,
|
|
463
466
|
placeholder: "State",
|
|
464
467
|
required: !0,
|
|
465
468
|
className: "h-10 w-full rounded-md border border-border-subtle bg-bg-surface px-3 text-sm text-text-primary placeholder:text-text-secondary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]"
|
|
466
469
|
})] }),
|
|
467
|
-
/* @__PURE__ */
|
|
470
|
+
/* @__PURE__ */ M("div", { children: [/* @__PURE__ */ j("label", {
|
|
468
471
|
htmlFor: "zipCode",
|
|
469
472
|
className: "mb-1.5 block text-sm font-medium text-text-primary",
|
|
470
473
|
children: "ZIP Code *"
|
|
471
|
-
}), /* @__PURE__ */
|
|
474
|
+
}), /* @__PURE__ */ j("input", {
|
|
472
475
|
id: "zipCode",
|
|
473
476
|
name: "zipCode",
|
|
474
|
-
value:
|
|
475
|
-
onChange:
|
|
477
|
+
value: O.zipCode,
|
|
478
|
+
onChange: V,
|
|
476
479
|
placeholder: "ZIP Code",
|
|
477
480
|
required: !0,
|
|
478
481
|
className: "h-10 w-full rounded-md border border-border-subtle bg-bg-surface px-3 text-sm text-text-primary placeholder:text-text-secondary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]"
|
|
479
482
|
})] })
|
|
480
483
|
]
|
|
481
484
|
}),
|
|
482
|
-
/* @__PURE__ */
|
|
485
|
+
/* @__PURE__ */ M("div", { children: [/* @__PURE__ */ j("label", {
|
|
483
486
|
htmlFor: "country",
|
|
484
487
|
className: "mb-1.5 block text-sm font-medium text-text-primary",
|
|
485
488
|
children: "Country"
|
|
486
|
-
}), /* @__PURE__ */
|
|
489
|
+
}), /* @__PURE__ */ M("select", {
|
|
487
490
|
id: "country",
|
|
488
491
|
name: "country",
|
|
489
|
-
value:
|
|
490
|
-
onChange:
|
|
492
|
+
value: O.country,
|
|
493
|
+
onChange: V,
|
|
491
494
|
className: "h-10 w-full rounded-md border border-border-subtle bg-bg-surface px-3 text-sm text-text-primary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)] sm:max-w-xs",
|
|
492
495
|
children: [
|
|
493
|
-
/* @__PURE__ */
|
|
496
|
+
/* @__PURE__ */ j("option", {
|
|
494
497
|
value: "USA",
|
|
495
498
|
children: "United States"
|
|
496
499
|
}),
|
|
497
|
-
/* @__PURE__ */
|
|
500
|
+
/* @__PURE__ */ j("option", {
|
|
498
501
|
value: "Canada",
|
|
499
502
|
children: "Canada"
|
|
500
503
|
}),
|
|
501
|
-
/* @__PURE__ */
|
|
504
|
+
/* @__PURE__ */ j("option", {
|
|
502
505
|
value: "UK",
|
|
503
506
|
children: "United Kingdom"
|
|
504
507
|
}),
|
|
505
|
-
/* @__PURE__ */
|
|
508
|
+
/* @__PURE__ */ j("option", {
|
|
506
509
|
value: "India",
|
|
507
510
|
children: "India"
|
|
508
511
|
})
|
|
509
512
|
]
|
|
513
|
+
})] }),
|
|
514
|
+
/* @__PURE__ */ M("div", { children: [/* @__PURE__ */ j("label", {
|
|
515
|
+
className: "mb-1.5 block text-sm font-medium text-text-primary",
|
|
516
|
+
children: "Map location (optional)"
|
|
517
|
+
}), /* @__PURE__ */ j(c, {
|
|
518
|
+
value: O.coordinates,
|
|
519
|
+
onChange: (e) => k((t) => ({
|
|
520
|
+
...t,
|
|
521
|
+
coordinates: e
|
|
522
|
+
}))
|
|
510
523
|
})] })
|
|
511
524
|
]
|
|
512
525
|
}),
|
|
513
|
-
|
|
526
|
+
T === 2 && /* @__PURE__ */ M("div", {
|
|
514
527
|
className: "space-y-4",
|
|
515
528
|
children: [
|
|
516
|
-
/* @__PURE__ */
|
|
529
|
+
/* @__PURE__ */ j("h3", {
|
|
517
530
|
className: "text-lg font-semibold text-text-primary",
|
|
518
531
|
children: "Property Specifications"
|
|
519
532
|
}),
|
|
520
|
-
/* @__PURE__ */
|
|
533
|
+
/* @__PURE__ */ M("div", {
|
|
521
534
|
className: "grid grid-cols-1 gap-4 sm:grid-cols-2",
|
|
522
|
-
children: [/* @__PURE__ */
|
|
535
|
+
children: [/* @__PURE__ */ M("div", { children: [/* @__PURE__ */ M("label", {
|
|
523
536
|
htmlFor: "area",
|
|
524
537
|
className: "mb-1.5 flex items-center gap-1.5 text-sm font-medium text-text-primary",
|
|
525
|
-
children: [/* @__PURE__ */
|
|
526
|
-
}), /* @__PURE__ */
|
|
538
|
+
children: [/* @__PURE__ */ j(C, { className: "h-4 w-4" }), "Total Area (sq ft) *"]
|
|
539
|
+
}), /* @__PURE__ */ j("input", {
|
|
527
540
|
id: "area",
|
|
528
541
|
name: "area",
|
|
529
542
|
type: "number",
|
|
530
|
-
value:
|
|
531
|
-
onChange:
|
|
543
|
+
value: O.area,
|
|
544
|
+
onChange: V,
|
|
532
545
|
placeholder: "Enter area",
|
|
533
546
|
required: !0,
|
|
534
547
|
className: "h-10 w-full rounded-md border border-border-subtle bg-bg-surface px-3 text-sm text-text-primary placeholder:text-text-secondary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]"
|
|
535
|
-
})] }), /* @__PURE__ */
|
|
548
|
+
})] }), /* @__PURE__ */ M("div", { children: [/* @__PURE__ */ M("label", {
|
|
536
549
|
htmlFor: "yearBuilt",
|
|
537
550
|
className: "mb-1.5 flex items-center gap-1.5 text-sm font-medium text-text-primary",
|
|
538
|
-
children: [/* @__PURE__ */
|
|
539
|
-
}), /* @__PURE__ */
|
|
551
|
+
children: [/* @__PURE__ */ j(p, { className: "h-4 w-4" }), "Year Built"]
|
|
552
|
+
}), /* @__PURE__ */ j("input", {
|
|
540
553
|
id: "yearBuilt",
|
|
541
554
|
name: "yearBuilt",
|
|
542
555
|
type: "number",
|
|
543
|
-
value:
|
|
544
|
-
onChange:
|
|
556
|
+
value: O.yearBuilt,
|
|
557
|
+
onChange: V,
|
|
545
558
|
placeholder: "YYYY",
|
|
546
559
|
className: "h-10 w-full rounded-md border border-border-subtle bg-bg-surface px-3 text-sm text-text-primary placeholder:text-text-secondary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]"
|
|
547
560
|
})] })]
|
|
548
561
|
}),
|
|
549
|
-
/* @__PURE__ */
|
|
562
|
+
/* @__PURE__ */ M("div", {
|
|
550
563
|
className: "grid grid-cols-1 gap-4 sm:grid-cols-3",
|
|
551
564
|
children: [
|
|
552
|
-
/* @__PURE__ */
|
|
565
|
+
/* @__PURE__ */ M("div", { children: [/* @__PURE__ */ M("label", {
|
|
553
566
|
htmlFor: "bedrooms",
|
|
554
567
|
className: "mb-1.5 flex items-center gap-1.5 text-sm font-medium text-text-primary",
|
|
555
|
-
children: [/* @__PURE__ */
|
|
556
|
-
}), /* @__PURE__ */
|
|
568
|
+
children: [/* @__PURE__ */ j(f, { className: "h-4 w-4" }), "Bedrooms"]
|
|
569
|
+
}), /* @__PURE__ */ j("input", {
|
|
557
570
|
id: "bedrooms",
|
|
558
571
|
name: "bedrooms",
|
|
559
572
|
type: "number",
|
|
560
|
-
value:
|
|
561
|
-
onChange:
|
|
573
|
+
value: O.bedrooms,
|
|
574
|
+
onChange: V,
|
|
562
575
|
placeholder: "0",
|
|
563
576
|
className: "h-10 w-full rounded-md border border-border-subtle bg-bg-surface px-3 text-sm text-text-primary placeholder:text-text-secondary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]"
|
|
564
577
|
})] }),
|
|
565
|
-
/* @__PURE__ */
|
|
578
|
+
/* @__PURE__ */ M("div", { children: [/* @__PURE__ */ M("label", {
|
|
566
579
|
htmlFor: "bathrooms",
|
|
567
580
|
className: "mb-1.5 flex items-center gap-1.5 text-sm font-medium text-text-primary",
|
|
568
|
-
children: [/* @__PURE__ */
|
|
569
|
-
}), /* @__PURE__ */
|
|
581
|
+
children: [/* @__PURE__ */ j(d, { className: "h-4 w-4" }), "Bathrooms"]
|
|
582
|
+
}), /* @__PURE__ */ j("input", {
|
|
570
583
|
id: "bathrooms",
|
|
571
584
|
name: "bathrooms",
|
|
572
585
|
type: "number",
|
|
573
|
-
value:
|
|
574
|
-
onChange:
|
|
586
|
+
value: O.bathrooms,
|
|
587
|
+
onChange: V,
|
|
575
588
|
placeholder: "0",
|
|
576
589
|
className: "h-10 w-full rounded-md border border-border-subtle bg-bg-surface px-3 text-sm text-text-primary placeholder:text-text-secondary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]"
|
|
577
590
|
})] }),
|
|
578
|
-
/* @__PURE__ */
|
|
591
|
+
/* @__PURE__ */ M("div", { children: [/* @__PURE__ */ M("label", {
|
|
579
592
|
htmlFor: "parking",
|
|
580
593
|
className: "mb-1.5 flex items-center gap-1.5 text-sm font-medium text-text-primary",
|
|
581
|
-
children: [/* @__PURE__ */
|
|
582
|
-
}), /* @__PURE__ */
|
|
594
|
+
children: [/* @__PURE__ */ j(m, { className: "h-4 w-4" }), "Parking Spots"]
|
|
595
|
+
}), /* @__PURE__ */ j("input", {
|
|
583
596
|
id: "parking",
|
|
584
597
|
name: "parking",
|
|
585
598
|
type: "number",
|
|
586
|
-
value:
|
|
587
|
-
onChange:
|
|
599
|
+
value: O.parking,
|
|
600
|
+
onChange: V,
|
|
588
601
|
placeholder: "0",
|
|
589
602
|
className: "h-10 w-full rounded-md border border-border-subtle bg-bg-surface px-3 text-sm text-text-primary placeholder:text-text-secondary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]"
|
|
590
603
|
})] })
|
|
591
604
|
]
|
|
592
605
|
}),
|
|
593
|
-
/* @__PURE__ */
|
|
606
|
+
/* @__PURE__ */ M("div", {
|
|
594
607
|
className: "grid grid-cols-1 gap-4 sm:grid-cols-2",
|
|
595
|
-
children: [/* @__PURE__ */
|
|
608
|
+
children: [/* @__PURE__ */ M("div", { children: [/* @__PURE__ */ j("label", {
|
|
596
609
|
htmlFor: "furnishing",
|
|
597
610
|
className: "mb-1.5 block text-sm font-medium text-text-primary",
|
|
598
611
|
children: "Furnishing Status"
|
|
599
|
-
}), /* @__PURE__ */
|
|
612
|
+
}), /* @__PURE__ */ M("select", {
|
|
600
613
|
id: "furnishing",
|
|
601
614
|
name: "furnishing",
|
|
602
|
-
value:
|
|
603
|
-
onChange:
|
|
615
|
+
value: O.furnishing,
|
|
616
|
+
onChange: V,
|
|
604
617
|
className: "h-10 w-full rounded-md border border-border-subtle bg-bg-surface px-3 text-sm text-text-primary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]",
|
|
605
618
|
children: [
|
|
606
|
-
/* @__PURE__ */
|
|
619
|
+
/* @__PURE__ */ j("option", {
|
|
607
620
|
value: "unfurnished",
|
|
608
621
|
children: "Unfurnished"
|
|
609
622
|
}),
|
|
610
|
-
/* @__PURE__ */
|
|
623
|
+
/* @__PURE__ */ j("option", {
|
|
611
624
|
value: "semi_furnished",
|
|
612
625
|
children: "Semi Furnished"
|
|
613
626
|
}),
|
|
614
|
-
/* @__PURE__ */
|
|
627
|
+
/* @__PURE__ */ j("option", {
|
|
615
628
|
value: "furnished",
|
|
616
629
|
children: "Furnished"
|
|
617
630
|
})
|
|
618
631
|
]
|
|
619
|
-
})] }), /* @__PURE__ */
|
|
632
|
+
})] }), /* @__PURE__ */ M("div", { children: [/* @__PURE__ */ j("label", {
|
|
620
633
|
htmlFor: "facing",
|
|
621
634
|
className: "mb-1.5 block text-sm font-medium text-text-primary",
|
|
622
635
|
children: "Facing Direction"
|
|
623
|
-
}), /* @__PURE__ */
|
|
636
|
+
}), /* @__PURE__ */ M("select", {
|
|
624
637
|
id: "facing",
|
|
625
638
|
name: "facing",
|
|
626
|
-
value:
|
|
627
|
-
onChange:
|
|
639
|
+
value: O.facing,
|
|
640
|
+
onChange: V,
|
|
628
641
|
className: "h-10 w-full rounded-md border border-border-subtle bg-bg-surface px-3 text-sm text-text-primary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]",
|
|
629
642
|
children: [
|
|
630
|
-
/* @__PURE__ */
|
|
643
|
+
/* @__PURE__ */ j("option", {
|
|
631
644
|
value: "North",
|
|
632
645
|
children: "North"
|
|
633
646
|
}),
|
|
634
|
-
/* @__PURE__ */
|
|
647
|
+
/* @__PURE__ */ j("option", {
|
|
635
648
|
value: "South",
|
|
636
649
|
children: "South"
|
|
637
650
|
}),
|
|
638
|
-
/* @__PURE__ */
|
|
651
|
+
/* @__PURE__ */ j("option", {
|
|
639
652
|
value: "East",
|
|
640
653
|
children: "East"
|
|
641
654
|
}),
|
|
642
|
-
/* @__PURE__ */
|
|
655
|
+
/* @__PURE__ */ j("option", {
|
|
643
656
|
value: "West",
|
|
644
657
|
children: "West"
|
|
645
658
|
}),
|
|
646
|
-
/* @__PURE__ */
|
|
659
|
+
/* @__PURE__ */ j("option", {
|
|
647
660
|
value: "Northeast",
|
|
648
661
|
children: "Northeast"
|
|
649
662
|
}),
|
|
650
|
-
/* @__PURE__ */
|
|
663
|
+
/* @__PURE__ */ j("option", {
|
|
651
664
|
value: "Northwest",
|
|
652
665
|
children: "Northwest"
|
|
653
666
|
}),
|
|
654
|
-
/* @__PURE__ */
|
|
667
|
+
/* @__PURE__ */ j("option", {
|
|
655
668
|
value: "Southeast",
|
|
656
669
|
children: "Southeast"
|
|
657
670
|
}),
|
|
658
|
-
/* @__PURE__ */
|
|
671
|
+
/* @__PURE__ */ j("option", {
|
|
659
672
|
value: "Southwest",
|
|
660
673
|
children: "Southwest"
|
|
661
674
|
})
|
|
@@ -664,97 +677,97 @@ var N = {
|
|
|
664
677
|
})
|
|
665
678
|
]
|
|
666
679
|
}),
|
|
667
|
-
|
|
680
|
+
T === 3 && /* @__PURE__ */ M("div", {
|
|
668
681
|
className: "space-y-4",
|
|
669
682
|
children: [
|
|
670
|
-
/* @__PURE__ */
|
|
683
|
+
/* @__PURE__ */ j("h3", {
|
|
671
684
|
className: "text-lg font-semibold text-text-primary",
|
|
672
685
|
children: "Property Amenities"
|
|
673
686
|
}),
|
|
674
|
-
/* @__PURE__ */
|
|
687
|
+
/* @__PURE__ */ j("p", {
|
|
675
688
|
className: "text-sm text-text-secondary",
|
|
676
689
|
children: "Select all amenities available at this property."
|
|
677
690
|
}),
|
|
678
|
-
/* @__PURE__ */
|
|
691
|
+
/* @__PURE__ */ j("div", {
|
|
679
692
|
className: "grid grid-cols-2 gap-3 sm:grid-cols-4",
|
|
680
|
-
children:
|
|
681
|
-
let n = t.icon, r =
|
|
682
|
-
return /* @__PURE__ */
|
|
693
|
+
children: L.map((t) => {
|
|
694
|
+
let n = t.icon, r = O.amenities.includes(t.id);
|
|
695
|
+
return /* @__PURE__ */ M("button", {
|
|
683
696
|
type: "button",
|
|
684
|
-
onClick: () =>
|
|
697
|
+
onClick: () => H(t.id),
|
|
685
698
|
className: e("flex flex-col items-center gap-2 rounded-lg border p-4 text-sm font-medium transition-colors", r ? "border-action-primary-border bg-action-primary-bg/5 text-text-primary" : "border-border-subtle text-text-secondary hover:bg-bg-sunken/50"),
|
|
686
699
|
children: [
|
|
687
|
-
/* @__PURE__ */
|
|
688
|
-
/* @__PURE__ */
|
|
689
|
-
r && /* @__PURE__ */
|
|
700
|
+
/* @__PURE__ */ j(n, { className: "h-6 w-6" }),
|
|
701
|
+
/* @__PURE__ */ j("span", { children: t.label }),
|
|
702
|
+
r && /* @__PURE__ */ j(h, { className: "h-4 w-4 text-status-success-text" })
|
|
690
703
|
]
|
|
691
704
|
}, t.id);
|
|
692
705
|
})
|
|
693
706
|
})
|
|
694
707
|
]
|
|
695
708
|
}),
|
|
696
|
-
|
|
709
|
+
T === 4 && /* @__PURE__ */ M("div", {
|
|
697
710
|
className: "space-y-4",
|
|
698
711
|
children: [
|
|
699
|
-
/* @__PURE__ */
|
|
712
|
+
/* @__PURE__ */ M("h3", {
|
|
700
713
|
className: "flex items-center gap-2 text-lg font-semibold text-text-primary",
|
|
701
|
-
children: [/* @__PURE__ */
|
|
714
|
+
children: [/* @__PURE__ */ j(v, { className: "h-5 w-5" }), "Pricing Details"]
|
|
702
715
|
}),
|
|
703
|
-
/* @__PURE__ */
|
|
716
|
+
/* @__PURE__ */ M("div", {
|
|
704
717
|
className: "grid grid-cols-1 gap-4 sm:grid-cols-2",
|
|
705
|
-
children: [/* @__PURE__ */
|
|
718
|
+
children: [/* @__PURE__ */ M("div", { children: [/* @__PURE__ */ j("label", {
|
|
706
719
|
htmlFor: "price",
|
|
707
720
|
className: "mb-1.5 block text-sm font-medium text-text-primary",
|
|
708
721
|
children: "Price *"
|
|
709
|
-
}), /* @__PURE__ */
|
|
722
|
+
}), /* @__PURE__ */ j("input", {
|
|
710
723
|
id: "price",
|
|
711
724
|
name: "price",
|
|
712
725
|
type: "number",
|
|
713
|
-
value:
|
|
714
|
-
onChange:
|
|
726
|
+
value: O.price,
|
|
727
|
+
onChange: V,
|
|
715
728
|
placeholder: "Enter price",
|
|
716
729
|
required: !0,
|
|
717
730
|
className: "h-10 w-full rounded-md border border-border-subtle bg-bg-surface px-3 text-sm text-text-primary placeholder:text-text-secondary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]"
|
|
718
|
-
})] }), /* @__PURE__ */
|
|
731
|
+
})] }), /* @__PURE__ */ M("div", { children: [/* @__PURE__ */ j("label", {
|
|
719
732
|
htmlFor: "currency",
|
|
720
733
|
className: "mb-1.5 block text-sm font-medium text-text-primary",
|
|
721
734
|
children: "Currency"
|
|
722
|
-
}), /* @__PURE__ */
|
|
735
|
+
}), /* @__PURE__ */ M("select", {
|
|
723
736
|
id: "currency",
|
|
724
737
|
name: "currency",
|
|
725
|
-
value:
|
|
726
|
-
onChange:
|
|
738
|
+
value: O.currency,
|
|
739
|
+
onChange: V,
|
|
727
740
|
className: "h-10 w-full rounded-md border border-border-subtle bg-bg-surface px-3 text-sm text-text-primary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]",
|
|
728
741
|
children: [
|
|
729
|
-
/* @__PURE__ */
|
|
742
|
+
/* @__PURE__ */ j("option", {
|
|
730
743
|
value: "USD",
|
|
731
744
|
children: "USD ($)"
|
|
732
745
|
}),
|
|
733
|
-
/* @__PURE__ */
|
|
746
|
+
/* @__PURE__ */ j("option", {
|
|
734
747
|
value: "EUR",
|
|
735
748
|
children: "EUR"
|
|
736
749
|
}),
|
|
737
|
-
/* @__PURE__ */
|
|
750
|
+
/* @__PURE__ */ j("option", {
|
|
738
751
|
value: "GBP",
|
|
739
752
|
children: "GBP"
|
|
740
753
|
}),
|
|
741
|
-
/* @__PURE__ */
|
|
754
|
+
/* @__PURE__ */ j("option", {
|
|
742
755
|
value: "INR",
|
|
743
756
|
children: "INR"
|
|
744
757
|
})
|
|
745
758
|
]
|
|
746
759
|
})] })]
|
|
747
760
|
}),
|
|
748
|
-
/* @__PURE__ */
|
|
761
|
+
/* @__PURE__ */ M("div", {
|
|
749
762
|
className: "flex items-center gap-2",
|
|
750
|
-
children: [/* @__PURE__ */
|
|
763
|
+
children: [/* @__PURE__ */ j("input", {
|
|
751
764
|
type: "checkbox",
|
|
752
765
|
id: "negotiable",
|
|
753
766
|
name: "negotiable",
|
|
754
|
-
checked:
|
|
755
|
-
onChange:
|
|
767
|
+
checked: O.negotiable,
|
|
768
|
+
onChange: V,
|
|
756
769
|
className: "h-4 w-4 rounded border-border-subtle"
|
|
757
|
-
}), /* @__PURE__ */
|
|
770
|
+
}), /* @__PURE__ */ j("label", {
|
|
758
771
|
htmlFor: "negotiable",
|
|
759
772
|
className: "text-sm text-text-primary",
|
|
760
773
|
children: "Price is negotiable"
|
|
@@ -762,34 +775,34 @@ var N = {
|
|
|
762
775
|
})
|
|
763
776
|
]
|
|
764
777
|
}),
|
|
765
|
-
|
|
778
|
+
T === 5 && /* @__PURE__ */ M("div", {
|
|
766
779
|
className: "space-y-4",
|
|
767
780
|
children: [
|
|
768
|
-
/* @__PURE__ */
|
|
781
|
+
/* @__PURE__ */ M("h3", {
|
|
769
782
|
className: "flex items-center gap-2 text-lg font-semibold text-text-primary",
|
|
770
|
-
children: [/* @__PURE__ */
|
|
783
|
+
children: [/* @__PURE__ */ j(E, { className: "h-5 w-5" }), "Property Images"]
|
|
771
784
|
}),
|
|
772
|
-
/* @__PURE__ */
|
|
785
|
+
/* @__PURE__ */ j("p", {
|
|
773
786
|
className: "text-sm text-text-secondary",
|
|
774
787
|
children: "Upload photos of the property (JPG, PNG). The first image becomes the cover."
|
|
775
788
|
}),
|
|
776
|
-
/* @__PURE__ */
|
|
789
|
+
/* @__PURE__ */ j(s, {
|
|
777
790
|
accept: "image/*",
|
|
778
791
|
multiple: !0,
|
|
779
792
|
label: "Upload property images",
|
|
780
|
-
value:
|
|
781
|
-
onUploaded:
|
|
782
|
-
onRemove:
|
|
793
|
+
value: O.images,
|
|
794
|
+
onUploaded: z,
|
|
795
|
+
onRemove: B
|
|
783
796
|
}),
|
|
784
|
-
|
|
797
|
+
O.images.length > 0 && /* @__PURE__ */ j("div", {
|
|
785
798
|
className: "grid grid-cols-3 gap-3 sm:grid-cols-4",
|
|
786
|
-
children:
|
|
799
|
+
children: O.images.map((e, t) => /* @__PURE__ */ M("div", {
|
|
787
800
|
className: "relative aspect-square overflow-hidden rounded-lg border border-border-subtle bg-bg-sunken/50",
|
|
788
|
-
children: [/* @__PURE__ */
|
|
801
|
+
children: [/* @__PURE__ */ j("img", {
|
|
789
802
|
src: e.url,
|
|
790
803
|
alt: e.name,
|
|
791
804
|
className: "h-full w-full object-cover"
|
|
792
|
-
}), t === 0 && /* @__PURE__ */
|
|
805
|
+
}), t === 0 && /* @__PURE__ */ j("span", {
|
|
793
806
|
className: "absolute left-1.5 top-1.5 rounded bg-action-primary-bg px-1.5 py-0.5 text-[10px] font-semibold text-action-primary-text",
|
|
794
807
|
children: "Cover"
|
|
795
808
|
})]
|
|
@@ -798,26 +811,26 @@ var N = {
|
|
|
798
811
|
]
|
|
799
812
|
})
|
|
800
813
|
]
|
|
801
|
-
}), /* @__PURE__ */
|
|
814
|
+
}), /* @__PURE__ */ M("div", {
|
|
802
815
|
className: "mt-6 flex items-center justify-between",
|
|
803
|
-
children: [/* @__PURE__ */
|
|
816
|
+
children: [/* @__PURE__ */ M("button", {
|
|
804
817
|
type: "button",
|
|
805
|
-
onClick: () =>
|
|
806
|
-
disabled:
|
|
818
|
+
onClick: () => T === 0 ? y("../properties") : D((e) => e - 1),
|
|
819
|
+
disabled: x,
|
|
807
820
|
className: "inline-flex items-center gap-2 rounded-md border border-border-subtle px-4 py-2 text-sm font-medium text-text-primary transition-colors hover:bg-bg-sunken disabled:opacity-50",
|
|
808
|
-
children: [/* @__PURE__ */
|
|
809
|
-
}),
|
|
821
|
+
children: [/* @__PURE__ */ j(g, { className: "h-4 w-4" }), T === 0 ? "Cancel" : "Previous"]
|
|
822
|
+
}), G ? /* @__PURE__ */ j("button", {
|
|
810
823
|
type: "button",
|
|
811
|
-
onClick:
|
|
812
|
-
disabled: !
|
|
824
|
+
onClick: W,
|
|
825
|
+
disabled: !U() || x,
|
|
813
826
|
className: "inline-flex items-center gap-2 rounded-md bg-action-primary-bg px-6 py-2 text-sm font-medium text-action-primary-text transition-colors hover:bg-action-primary-bg-hover disabled:opacity-50",
|
|
814
|
-
children:
|
|
815
|
-
}) : /* @__PURE__ */
|
|
827
|
+
children: x ? "Adding Property..." : "Submit Property"
|
|
828
|
+
}) : /* @__PURE__ */ M("button", {
|
|
816
829
|
type: "button",
|
|
817
|
-
onClick: () =>
|
|
818
|
-
disabled: !
|
|
830
|
+
onClick: () => D((e) => e + 1),
|
|
831
|
+
disabled: !U(),
|
|
819
832
|
className: "inline-flex items-center gap-2 rounded-md bg-action-primary-bg px-4 py-2 text-sm font-medium text-action-primary-text transition-colors hover:bg-action-primary-bg-hover disabled:opacity-50",
|
|
820
|
-
children: ["Next", /* @__PURE__ */
|
|
833
|
+
children: ["Next", /* @__PURE__ */ j(_, { className: "h-4 w-4" })]
|
|
821
834
|
})]
|
|
822
835
|
})]
|
|
823
836
|
})
|
|
@@ -825,6 +838,6 @@ var N = {
|
|
|
825
838
|
});
|
|
826
839
|
};
|
|
827
840
|
//#endregion
|
|
828
|
-
export {
|
|
841
|
+
export { z as AddPropertyPage };
|
|
829
842
|
|
|
830
843
|
//# sourceMappingURL=AddPropertyPage.js.map
|