@opendoor/partner-sdk-client-react 1.2.1-beta.103.1 → 1.2.1-beta.104.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/client-react/src/components/DtcOnboardingFlow/DtcProvider.d.ts +0 -1
- package/dist/client-react/src/components/DtcOnboardingFlow/DtcProvider.d.ts.map +1 -1
- package/dist/client-react/src/components/DtcOnboardingFlow/index.d.ts +0 -2
- package/dist/client-react/src/components/DtcOnboardingFlow/index.d.ts.map +1 -1
- package/dist/index.js +881 -891
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import
|
|
2
|
-
import { createPortal as
|
|
1
|
+
import vt, { createContext as Ue, useState as E, useEffect as le, useContext as Ae, useRef as Z, useMemo as Ie, useCallback as Ee, useLayoutEffect as qt } from "react";
|
|
2
|
+
import { createPortal as Ut } from "react-dom";
|
|
3
3
|
var qe = { exports: {} }, je = {};
|
|
4
4
|
/*
|
|
5
5
|
object-assign
|
|
@@ -7,7 +7,7 @@ object-assign
|
|
|
7
7
|
@license MIT
|
|
8
8
|
*/
|
|
9
9
|
var Fe, st;
|
|
10
|
-
function
|
|
10
|
+
function xt() {
|
|
11
11
|
if (st) return Fe;
|
|
12
12
|
st = 1;
|
|
13
13
|
var e = Object.getOwnPropertySymbols, r = Object.prototype.hasOwnProperty, a = Object.prototype.propertyIsEnumerable;
|
|
@@ -25,31 +25,31 @@ function Ct() {
|
|
|
25
25
|
return !1;
|
|
26
26
|
for (var _ = {}, f = 0; f < 10; f++)
|
|
27
27
|
_["_" + String.fromCharCode(f)] = f;
|
|
28
|
-
var
|
|
29
|
-
return _[
|
|
28
|
+
var d = Object.getOwnPropertyNames(_).map(function(u) {
|
|
29
|
+
return _[u];
|
|
30
30
|
});
|
|
31
|
-
if (
|
|
31
|
+
if (d.join("") !== "0123456789")
|
|
32
32
|
return !1;
|
|
33
33
|
var h = {};
|
|
34
|
-
return "abcdefghijklmnopqrst".split("").forEach(function(
|
|
35
|
-
h[
|
|
34
|
+
return "abcdefghijklmnopqrst".split("").forEach(function(u) {
|
|
35
|
+
h[u] = u;
|
|
36
36
|
}), Object.keys(Object.assign({}, h)).join("") === "abcdefghijklmnopqrst";
|
|
37
37
|
} catch {
|
|
38
38
|
return !1;
|
|
39
39
|
}
|
|
40
40
|
}
|
|
41
41
|
return Fe = o() ? Object.assign : function(i, _) {
|
|
42
|
-
for (var f,
|
|
43
|
-
f = Object(arguments[
|
|
42
|
+
for (var f, d = s(i), h, u = 1; u < arguments.length; u++) {
|
|
43
|
+
f = Object(arguments[u]);
|
|
44
44
|
for (var m in f)
|
|
45
|
-
r.call(f, m) && (
|
|
45
|
+
r.call(f, m) && (d[m] = f[m]);
|
|
46
46
|
if (e) {
|
|
47
47
|
h = e(f);
|
|
48
48
|
for (var g = 0; g < h.length; g++)
|
|
49
|
-
a.call(f, h[g]) && (
|
|
49
|
+
a.call(f, h[g]) && (d[h[g]] = f[h[g]]);
|
|
50
50
|
}
|
|
51
51
|
}
|
|
52
|
-
return
|
|
52
|
+
return d;
|
|
53
53
|
}, Fe;
|
|
54
54
|
}
|
|
55
55
|
/** @license React v17.0.2
|
|
@@ -61,21 +61,21 @@ function Ct() {
|
|
|
61
61
|
* LICENSE file in the root directory of this source tree.
|
|
62
62
|
*/
|
|
63
63
|
var ot;
|
|
64
|
-
function
|
|
64
|
+
function Gt() {
|
|
65
65
|
if (ot) return je;
|
|
66
|
-
ot = 1,
|
|
67
|
-
var e =
|
|
66
|
+
ot = 1, xt();
|
|
67
|
+
var e = vt, r = 60103;
|
|
68
68
|
if (je.Fragment = 60107, typeof Symbol == "function" && Symbol.for) {
|
|
69
69
|
var a = Symbol.for;
|
|
70
70
|
r = a("react.element"), je.Fragment = a("react.fragment");
|
|
71
71
|
}
|
|
72
72
|
var s = e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, o = Object.prototype.hasOwnProperty, i = { key: !0, ref: !0, __self: !0, __source: !0 };
|
|
73
|
-
function _(f,
|
|
74
|
-
var
|
|
75
|
-
h !== void 0 && (g = "" + h),
|
|
76
|
-
for (
|
|
77
|
-
if (f && f.defaultProps) for (
|
|
78
|
-
return { $$typeof: r, type: f, key: g, ref:
|
|
73
|
+
function _(f, d, h) {
|
|
74
|
+
var u, m = {}, g = null, C = null;
|
|
75
|
+
h !== void 0 && (g = "" + h), d.key !== void 0 && (g = "" + d.key), d.ref !== void 0 && (C = d.ref);
|
|
76
|
+
for (u in d) o.call(d, u) && !i.hasOwnProperty(u) && (m[u] = d[u]);
|
|
77
|
+
if (f && f.defaultProps) for (u in d = f.defaultProps, d) m[u] === void 0 && (m[u] = d[u]);
|
|
78
|
+
return { $$typeof: r, type: f, key: g, ref: C, props: m, _owner: s.current };
|
|
79
79
|
}
|
|
80
80
|
return je.jsx = _, je.jsxs = _, je;
|
|
81
81
|
}
|
|
@@ -89,56 +89,56 @@ var We = {};
|
|
|
89
89
|
* LICENSE file in the root directory of this source tree.
|
|
90
90
|
*/
|
|
91
91
|
var it;
|
|
92
|
-
function
|
|
92
|
+
function Yt() {
|
|
93
93
|
return it || (it = 1, function(e) {
|
|
94
94
|
process.env.NODE_ENV !== "production" && function() {
|
|
95
|
-
var r =
|
|
95
|
+
var r = vt, a = xt(), s = 60103, o = 60106;
|
|
96
96
|
e.Fragment = 60107;
|
|
97
|
-
var i = 60108, _ = 60114, f = 60109,
|
|
97
|
+
var i = 60108, _ = 60114, f = 60109, d = 60110, h = 60112, u = 60113, m = 60120, g = 60115, C = 60116, v = 60121, R = 60122, W = 60117, S = 60129, K = 60131;
|
|
98
98
|
if (typeof Symbol == "function" && Symbol.for) {
|
|
99
|
-
var
|
|
100
|
-
s =
|
|
99
|
+
var w = Symbol.for;
|
|
100
|
+
s = w("react.element"), o = w("react.portal"), e.Fragment = w("react.fragment"), i = w("react.strict_mode"), _ = w("react.profiler"), f = w("react.provider"), d = w("react.context"), h = w("react.forward_ref"), u = w("react.suspense"), m = w("react.suspense_list"), g = w("react.memo"), C = w("react.lazy"), v = w("react.block"), R = w("react.server.block"), W = w("react.fundamental"), w("react.scope"), w("react.opaque.id"), S = w("react.debug_trace_mode"), w("react.offscreen"), K = w("react.legacy_hidden");
|
|
101
101
|
}
|
|
102
|
-
var
|
|
103
|
-
function
|
|
102
|
+
var re = typeof Symbol == "function" && Symbol.iterator, T = "@@iterator";
|
|
103
|
+
function ae(n) {
|
|
104
104
|
if (n === null || typeof n != "object")
|
|
105
105
|
return null;
|
|
106
|
-
var c =
|
|
106
|
+
var c = re && n[re] || n[T];
|
|
107
107
|
return typeof c == "function" ? c : null;
|
|
108
108
|
}
|
|
109
|
-
var
|
|
110
|
-
function
|
|
109
|
+
var V = r.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
|
|
110
|
+
function P(n) {
|
|
111
111
|
{
|
|
112
|
-
for (var c = arguments.length, b = new Array(c > 1 ? c - 1 : 0),
|
|
113
|
-
b[
|
|
112
|
+
for (var c = arguments.length, b = new Array(c > 1 ? c - 1 : 0), k = 1; k < c; k++)
|
|
113
|
+
b[k - 1] = arguments[k];
|
|
114
114
|
te("error", n, b);
|
|
115
115
|
}
|
|
116
116
|
}
|
|
117
117
|
function te(n, c, b) {
|
|
118
118
|
{
|
|
119
|
-
var
|
|
120
|
-
|
|
121
|
-
var
|
|
122
|
-
return "" +
|
|
119
|
+
var k = V.ReactDebugCurrentFrame, H = k.getStackAddendum();
|
|
120
|
+
H !== "" && (c += "%s", b = b.concat([H]));
|
|
121
|
+
var F = b.map(function(A) {
|
|
122
|
+
return "" + A;
|
|
123
123
|
});
|
|
124
|
-
|
|
124
|
+
F.unshift("Warning: " + c), Function.prototype.apply.call(console[n], console, F);
|
|
125
125
|
}
|
|
126
126
|
}
|
|
127
127
|
var G = !1;
|
|
128
|
-
function
|
|
129
|
-
return !!(typeof n == "string" || typeof n == "function" || n === e.Fragment || n === _ || n ===
|
|
128
|
+
function ne(n) {
|
|
129
|
+
return !!(typeof n == "string" || typeof n == "function" || n === e.Fragment || n === _ || n === S || n === i || n === u || n === m || n === K || G || typeof n == "object" && n !== null && (n.$$typeof === C || n.$$typeof === g || n.$$typeof === f || n.$$typeof === d || n.$$typeof === h || n.$$typeof === W || n.$$typeof === v || n[0] === R));
|
|
130
130
|
}
|
|
131
|
-
function
|
|
132
|
-
var
|
|
133
|
-
return n.displayName || (
|
|
131
|
+
function se(n, c, b) {
|
|
132
|
+
var k = c.displayName || c.name || "";
|
|
133
|
+
return n.displayName || (k !== "" ? b + "(" + k + ")" : b);
|
|
134
134
|
}
|
|
135
|
-
function
|
|
135
|
+
function Y(n) {
|
|
136
136
|
return n.displayName || "Context";
|
|
137
137
|
}
|
|
138
|
-
function
|
|
138
|
+
function O(n) {
|
|
139
139
|
if (n == null)
|
|
140
140
|
return null;
|
|
141
|
-
if (typeof n.tag == "number" &&
|
|
141
|
+
if (typeof n.tag == "number" && P("Received an unexpected object in getComponentName(). This is likely a bug in React. Please file an issue."), typeof n == "function")
|
|
142
142
|
return n.displayName || n.name || null;
|
|
143
143
|
if (typeof n == "string")
|
|
144
144
|
return n;
|
|
@@ -151,29 +151,29 @@ function Zt() {
|
|
|
151
151
|
return "Profiler";
|
|
152
152
|
case i:
|
|
153
153
|
return "StrictMode";
|
|
154
|
-
case
|
|
154
|
+
case u:
|
|
155
155
|
return "Suspense";
|
|
156
156
|
case m:
|
|
157
157
|
return "SuspenseList";
|
|
158
158
|
}
|
|
159
159
|
if (typeof n == "object")
|
|
160
160
|
switch (n.$$typeof) {
|
|
161
|
-
case
|
|
161
|
+
case d:
|
|
162
162
|
var c = n;
|
|
163
|
-
return
|
|
163
|
+
return Y(c) + ".Consumer";
|
|
164
164
|
case f:
|
|
165
165
|
var b = n;
|
|
166
|
-
return
|
|
166
|
+
return Y(b._context) + ".Provider";
|
|
167
167
|
case h:
|
|
168
|
-
return
|
|
168
|
+
return se(n, n.render, "ForwardRef");
|
|
169
169
|
case g:
|
|
170
|
-
return
|
|
171
|
-
case
|
|
172
|
-
return
|
|
173
|
-
case
|
|
174
|
-
var
|
|
170
|
+
return O(n.type);
|
|
171
|
+
case v:
|
|
172
|
+
return O(n._render);
|
|
173
|
+
case C: {
|
|
174
|
+
var k = n, H = k._payload, F = k._init;
|
|
175
175
|
try {
|
|
176
|
-
return F(
|
|
176
|
+
return O(F(H));
|
|
177
177
|
} catch {
|
|
178
178
|
return null;
|
|
179
179
|
}
|
|
@@ -181,18 +181,18 @@ function Zt() {
|
|
|
181
181
|
}
|
|
182
182
|
return null;
|
|
183
183
|
}
|
|
184
|
-
var
|
|
185
|
-
function
|
|
184
|
+
var U = 0, B, y, I, j, me, ce, pe;
|
|
185
|
+
function de() {
|
|
186
186
|
}
|
|
187
|
-
|
|
188
|
-
function
|
|
187
|
+
de.__reactDisabledLog = !0;
|
|
188
|
+
function N() {
|
|
189
189
|
{
|
|
190
|
-
if (
|
|
191
|
-
|
|
190
|
+
if (U === 0) {
|
|
191
|
+
B = console.log, y = console.info, I = console.warn, j = console.error, me = console.group, ce = console.groupCollapsed, pe = console.groupEnd;
|
|
192
192
|
var n = {
|
|
193
193
|
configurable: !0,
|
|
194
194
|
enumerable: !0,
|
|
195
|
-
value:
|
|
195
|
+
value: de,
|
|
196
196
|
writable: !0
|
|
197
197
|
};
|
|
198
198
|
Object.defineProperties(console, {
|
|
@@ -205,12 +205,12 @@ function Zt() {
|
|
|
205
205
|
groupEnd: n
|
|
206
206
|
});
|
|
207
207
|
}
|
|
208
|
-
|
|
208
|
+
U++;
|
|
209
209
|
}
|
|
210
210
|
}
|
|
211
|
-
function
|
|
211
|
+
function M() {
|
|
212
212
|
{
|
|
213
|
-
if (
|
|
213
|
+
if (U--, U === 0) {
|
|
214
214
|
var n = {
|
|
215
215
|
configurable: !0,
|
|
216
216
|
enumerable: !0,
|
|
@@ -218,119 +218,119 @@ function Zt() {
|
|
|
218
218
|
};
|
|
219
219
|
Object.defineProperties(console, {
|
|
220
220
|
log: a({}, n, {
|
|
221
|
-
value:
|
|
221
|
+
value: B
|
|
222
222
|
}),
|
|
223
223
|
info: a({}, n, {
|
|
224
224
|
value: y
|
|
225
225
|
}),
|
|
226
226
|
warn: a({}, n, {
|
|
227
|
-
value:
|
|
227
|
+
value: I
|
|
228
228
|
}),
|
|
229
229
|
error: a({}, n, {
|
|
230
|
-
value:
|
|
230
|
+
value: j
|
|
231
231
|
}),
|
|
232
232
|
group: a({}, n, {
|
|
233
|
-
value:
|
|
233
|
+
value: me
|
|
234
234
|
}),
|
|
235
235
|
groupCollapsed: a({}, n, {
|
|
236
|
-
value:
|
|
236
|
+
value: ce
|
|
237
237
|
}),
|
|
238
238
|
groupEnd: a({}, n, {
|
|
239
239
|
value: pe
|
|
240
240
|
})
|
|
241
241
|
});
|
|
242
242
|
}
|
|
243
|
-
|
|
243
|
+
U < 0 && P("disabledDepth fell below zero. This is a bug in React. Please file an issue.");
|
|
244
244
|
}
|
|
245
245
|
}
|
|
246
|
-
var
|
|
247
|
-
function
|
|
246
|
+
var q = V.ReactCurrentDispatcher, $;
|
|
247
|
+
function oe(n, c, b) {
|
|
248
248
|
{
|
|
249
|
-
if (
|
|
249
|
+
if ($ === void 0)
|
|
250
250
|
try {
|
|
251
251
|
throw Error();
|
|
252
|
-
} catch (
|
|
253
|
-
var
|
|
254
|
-
|
|
252
|
+
} catch (H) {
|
|
253
|
+
var k = H.stack.trim().match(/\n( *(at )?)/);
|
|
254
|
+
$ = k && k[1] || "";
|
|
255
255
|
}
|
|
256
256
|
return `
|
|
257
|
-
` +
|
|
257
|
+
` + $ + n;
|
|
258
258
|
}
|
|
259
259
|
}
|
|
260
|
-
var
|
|
260
|
+
var he = !1, ge;
|
|
261
261
|
{
|
|
262
262
|
var Oe = typeof WeakMap == "function" ? WeakMap : Map;
|
|
263
263
|
ge = new Oe();
|
|
264
264
|
}
|
|
265
265
|
function ye(n, c) {
|
|
266
|
-
if (!n ||
|
|
266
|
+
if (!n || he)
|
|
267
267
|
return "";
|
|
268
268
|
{
|
|
269
269
|
var b = ge.get(n);
|
|
270
270
|
if (b !== void 0)
|
|
271
271
|
return b;
|
|
272
272
|
}
|
|
273
|
-
var
|
|
274
|
-
|
|
275
|
-
var
|
|
273
|
+
var k;
|
|
274
|
+
he = !0;
|
|
275
|
+
var H = Error.prepareStackTrace;
|
|
276
276
|
Error.prepareStackTrace = void 0;
|
|
277
|
-
var
|
|
278
|
-
|
|
277
|
+
var F;
|
|
278
|
+
F = q.current, q.current = null, N();
|
|
279
279
|
try {
|
|
280
280
|
if (c) {
|
|
281
|
-
var
|
|
281
|
+
var A = function() {
|
|
282
282
|
throw Error();
|
|
283
283
|
};
|
|
284
|
-
if (Object.defineProperty(
|
|
284
|
+
if (Object.defineProperty(A.prototype, "props", {
|
|
285
285
|
set: function() {
|
|
286
286
|
throw Error();
|
|
287
287
|
}
|
|
288
288
|
}), typeof Reflect == "object" && Reflect.construct) {
|
|
289
289
|
try {
|
|
290
|
-
Reflect.construct(
|
|
290
|
+
Reflect.construct(A, []);
|
|
291
291
|
} catch (be) {
|
|
292
|
-
|
|
292
|
+
k = be;
|
|
293
293
|
}
|
|
294
|
-
Reflect.construct(n, [],
|
|
294
|
+
Reflect.construct(n, [], A);
|
|
295
295
|
} else {
|
|
296
296
|
try {
|
|
297
|
-
|
|
297
|
+
A.call();
|
|
298
298
|
} catch (be) {
|
|
299
|
-
|
|
299
|
+
k = be;
|
|
300
300
|
}
|
|
301
|
-
n.call(
|
|
301
|
+
n.call(A.prototype);
|
|
302
302
|
}
|
|
303
303
|
} else {
|
|
304
304
|
try {
|
|
305
305
|
throw Error();
|
|
306
306
|
} catch (be) {
|
|
307
|
-
|
|
307
|
+
k = be;
|
|
308
308
|
}
|
|
309
309
|
n();
|
|
310
310
|
}
|
|
311
311
|
} catch (be) {
|
|
312
|
-
if (be &&
|
|
313
|
-
for (var
|
|
314
|
-
`),
|
|
315
|
-
`),
|
|
312
|
+
if (be && k && typeof be.stack == "string") {
|
|
313
|
+
for (var L = be.stack.split(`
|
|
314
|
+
`), ie = k.stack.split(`
|
|
315
|
+
`), J = L.length - 1, Q = ie.length - 1; J >= 1 && Q >= 0 && L[J] !== ie[Q]; )
|
|
316
316
|
Q--;
|
|
317
|
-
for (;
|
|
318
|
-
if (
|
|
319
|
-
if (
|
|
317
|
+
for (; J >= 1 && Q >= 0; J--, Q--)
|
|
318
|
+
if (L[J] !== ie[Q]) {
|
|
319
|
+
if (J !== 1 || Q !== 1)
|
|
320
320
|
do
|
|
321
|
-
if (
|
|
321
|
+
if (J--, Q--, Q < 0 || L[J] !== ie[Q]) {
|
|
322
322
|
var _e = `
|
|
323
|
-
` +
|
|
323
|
+
` + L[J].replace(" at new ", " at ");
|
|
324
324
|
return typeof n == "function" && ge.set(n, _e), _e;
|
|
325
325
|
}
|
|
326
|
-
while (
|
|
326
|
+
while (J >= 1 && Q >= 0);
|
|
327
327
|
break;
|
|
328
328
|
}
|
|
329
329
|
}
|
|
330
330
|
} finally {
|
|
331
|
-
|
|
331
|
+
he = !1, q.current = F, M(), Error.prepareStackTrace = H;
|
|
332
332
|
}
|
|
333
|
-
var ke = n ? n.displayName || n.name : "", at = ke ?
|
|
333
|
+
var ke = n ? n.displayName || n.name : "", at = ke ? oe(ke) : "";
|
|
334
334
|
return typeof n == "function" && ge.set(n, at), at;
|
|
335
335
|
}
|
|
336
336
|
function Pe(n, c, b) {
|
|
@@ -340,71 +340,71 @@ function Zt() {
|
|
|
340
340
|
var c = n.prototype;
|
|
341
341
|
return !!(c && c.isReactComponent);
|
|
342
342
|
}
|
|
343
|
-
function
|
|
343
|
+
function x(n, c, b) {
|
|
344
344
|
if (n == null)
|
|
345
345
|
return "";
|
|
346
346
|
if (typeof n == "function")
|
|
347
347
|
return ye(n, ve(n));
|
|
348
348
|
if (typeof n == "string")
|
|
349
|
-
return
|
|
349
|
+
return oe(n);
|
|
350
350
|
switch (n) {
|
|
351
|
-
case
|
|
352
|
-
return
|
|
351
|
+
case u:
|
|
352
|
+
return oe("Suspense");
|
|
353
353
|
case m:
|
|
354
|
-
return
|
|
354
|
+
return oe("SuspenseList");
|
|
355
355
|
}
|
|
356
356
|
if (typeof n == "object")
|
|
357
357
|
switch (n.$$typeof) {
|
|
358
358
|
case h:
|
|
359
359
|
return Pe(n.render);
|
|
360
360
|
case g:
|
|
361
|
-
return
|
|
362
|
-
case
|
|
361
|
+
return x(n.type, c, b);
|
|
362
|
+
case v:
|
|
363
363
|
return Pe(n._render);
|
|
364
|
-
case
|
|
365
|
-
var
|
|
364
|
+
case C: {
|
|
365
|
+
var k = n, H = k._payload, F = k._init;
|
|
366
366
|
try {
|
|
367
|
-
return
|
|
367
|
+
return x(F(H), c, b);
|
|
368
368
|
} catch {
|
|
369
369
|
}
|
|
370
370
|
}
|
|
371
371
|
}
|
|
372
372
|
return "";
|
|
373
373
|
}
|
|
374
|
-
var
|
|
374
|
+
var z = {}, X = V.ReactDebugCurrentFrame;
|
|
375
375
|
function xe(n) {
|
|
376
376
|
if (n) {
|
|
377
|
-
var c = n._owner, b =
|
|
377
|
+
var c = n._owner, b = x(n.type, n._source, c ? c.type : null);
|
|
378
378
|
X.setExtraStackFrame(b);
|
|
379
379
|
} else
|
|
380
380
|
X.setExtraStackFrame(null);
|
|
381
381
|
}
|
|
382
|
-
function Ce(n, c, b,
|
|
382
|
+
function Ce(n, c, b, k, H) {
|
|
383
383
|
{
|
|
384
|
-
var
|
|
385
|
-
for (var
|
|
386
|
-
if (
|
|
387
|
-
var
|
|
384
|
+
var F = Function.call.bind(Object.prototype.hasOwnProperty);
|
|
385
|
+
for (var A in n)
|
|
386
|
+
if (F(n, A)) {
|
|
387
|
+
var L = void 0;
|
|
388
388
|
try {
|
|
389
|
-
if (typeof n[
|
|
390
|
-
var
|
|
391
|
-
throw
|
|
389
|
+
if (typeof n[A] != "function") {
|
|
390
|
+
var ie = Error((k || "React class") + ": " + b + " type `" + A + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof n[A] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");
|
|
391
|
+
throw ie.name = "Invariant Violation", ie;
|
|
392
392
|
}
|
|
393
|
-
|
|
394
|
-
} catch (
|
|
395
|
-
|
|
393
|
+
L = n[A](c, A, k, b, null, "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED");
|
|
394
|
+
} catch (J) {
|
|
395
|
+
L = J;
|
|
396
396
|
}
|
|
397
|
-
|
|
397
|
+
L && !(L instanceof Error) && (xe(H), P("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).", k || "React class", b, A, typeof L), xe(null)), L instanceof Error && !(L.message in z) && (z[L.message] = !0, xe(H), P("Failed %s type: %s", b, L.message), xe(null));
|
|
398
398
|
}
|
|
399
399
|
}
|
|
400
400
|
}
|
|
401
|
-
var Ne =
|
|
401
|
+
var Ne = V.ReactCurrentOwner, Re = Object.prototype.hasOwnProperty, Et = {
|
|
402
402
|
key: !0,
|
|
403
403
|
ref: !0,
|
|
404
404
|
__self: !0,
|
|
405
405
|
__source: !0
|
|
406
406
|
}, ze, Je;
|
|
407
|
-
function
|
|
407
|
+
function St(n) {
|
|
408
408
|
if (Re.call(n, "ref")) {
|
|
409
409
|
var c = Object.getOwnPropertyDescriptor(n, "ref").get;
|
|
410
410
|
if (c && c.isReactWarning)
|
|
@@ -412,7 +412,7 @@ function Zt() {
|
|
|
412
412
|
}
|
|
413
413
|
return n.ref !== void 0;
|
|
414
414
|
}
|
|
415
|
-
function
|
|
415
|
+
function Pt(n) {
|
|
416
416
|
if (Re.call(n, "key")) {
|
|
417
417
|
var c = Object.getOwnPropertyDescriptor(n, "key").get;
|
|
418
418
|
if (c && c.isReactWarning)
|
|
@@ -420,13 +420,13 @@ function Zt() {
|
|
|
420
420
|
}
|
|
421
421
|
return n.key !== void 0;
|
|
422
422
|
}
|
|
423
|
-
function
|
|
423
|
+
function Lt(n, c) {
|
|
424
424
|
typeof n.ref == "string" && Ne.current;
|
|
425
425
|
}
|
|
426
|
-
function
|
|
426
|
+
function Tt(n, c) {
|
|
427
427
|
{
|
|
428
428
|
var b = function() {
|
|
429
|
-
ze || (ze = !0,
|
|
429
|
+
ze || (ze = !0, P("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)", c));
|
|
430
430
|
};
|
|
431
431
|
b.isReactWarning = !0, Object.defineProperty(n, "key", {
|
|
432
432
|
get: b,
|
|
@@ -437,7 +437,7 @@ function Zt() {
|
|
|
437
437
|
function At(n, c) {
|
|
438
438
|
{
|
|
439
439
|
var b = function() {
|
|
440
|
-
Je || (Je = !0,
|
|
440
|
+
Je || (Je = !0, P("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)", c));
|
|
441
441
|
};
|
|
442
442
|
b.isReactWarning = !0, Object.defineProperty(n, "ref", {
|
|
443
443
|
get: b,
|
|
@@ -445,57 +445,57 @@ function Zt() {
|
|
|
445
445
|
});
|
|
446
446
|
}
|
|
447
447
|
}
|
|
448
|
-
var
|
|
449
|
-
var
|
|
448
|
+
var Dt = function(n, c, b, k, H, F, A) {
|
|
449
|
+
var L = {
|
|
450
450
|
// This tag allows us to uniquely identify this as a React Element
|
|
451
451
|
$$typeof: s,
|
|
452
452
|
// Built-in properties that belong on the element
|
|
453
453
|
type: n,
|
|
454
454
|
key: c,
|
|
455
455
|
ref: b,
|
|
456
|
-
props:
|
|
456
|
+
props: A,
|
|
457
457
|
// Record the component responsible for creating this element.
|
|
458
|
-
_owner:
|
|
458
|
+
_owner: F
|
|
459
459
|
};
|
|
460
|
-
return
|
|
460
|
+
return L._store = {}, Object.defineProperty(L._store, "validated", {
|
|
461
461
|
configurable: !1,
|
|
462
462
|
enumerable: !1,
|
|
463
463
|
writable: !0,
|
|
464
464
|
value: !1
|
|
465
|
-
}), Object.defineProperty(
|
|
465
|
+
}), Object.defineProperty(L, "_self", {
|
|
466
466
|
configurable: !1,
|
|
467
467
|
enumerable: !1,
|
|
468
468
|
writable: !1,
|
|
469
|
-
value:
|
|
470
|
-
}), Object.defineProperty(
|
|
469
|
+
value: k
|
|
470
|
+
}), Object.defineProperty(L, "_source", {
|
|
471
471
|
configurable: !1,
|
|
472
472
|
enumerable: !1,
|
|
473
473
|
writable: !1,
|
|
474
|
-
value:
|
|
475
|
-
}), Object.freeze && (Object.freeze(
|
|
474
|
+
value: H
|
|
475
|
+
}), Object.freeze && (Object.freeze(L.props), Object.freeze(L)), L;
|
|
476
476
|
};
|
|
477
|
-
function
|
|
477
|
+
function Ot(n, c, b, k, H) {
|
|
478
478
|
{
|
|
479
|
-
var
|
|
480
|
-
b !== void 0 && (
|
|
481
|
-
for (
|
|
482
|
-
Re.call(c,
|
|
479
|
+
var F, A = {}, L = null, ie = null;
|
|
480
|
+
b !== void 0 && (L = "" + b), Pt(c) && (L = "" + c.key), St(c) && (ie = c.ref, Lt(c, H));
|
|
481
|
+
for (F in c)
|
|
482
|
+
Re.call(c, F) && !Et.hasOwnProperty(F) && (A[F] = c[F]);
|
|
483
483
|
if (n && n.defaultProps) {
|
|
484
|
-
var
|
|
485
|
-
for (
|
|
486
|
-
|
|
484
|
+
var J = n.defaultProps;
|
|
485
|
+
for (F in J)
|
|
486
|
+
A[F] === void 0 && (A[F] = J[F]);
|
|
487
487
|
}
|
|
488
|
-
if (
|
|
488
|
+
if (L || ie) {
|
|
489
489
|
var Q = typeof n == "function" ? n.displayName || n.name || "Unknown" : n;
|
|
490
|
-
|
|
490
|
+
L && Tt(A, Q), ie && At(A, Q);
|
|
491
491
|
}
|
|
492
|
-
return
|
|
492
|
+
return Dt(n, L, ie, H, k, Ne.current, A);
|
|
493
493
|
}
|
|
494
494
|
}
|
|
495
|
-
var Be =
|
|
495
|
+
var Be = V.ReactCurrentOwner, Xe = V.ReactDebugCurrentFrame;
|
|
496
496
|
function we(n) {
|
|
497
497
|
if (n) {
|
|
498
|
-
var c = n._owner, b =
|
|
498
|
+
var c = n._owner, b = x(n.type, n._source, c ? c.type : null);
|
|
499
499
|
Xe.setExtraStackFrame(b);
|
|
500
500
|
} else
|
|
501
501
|
Xe.setExtraStackFrame(null);
|
|
@@ -508,7 +508,7 @@ function Zt() {
|
|
|
508
508
|
function Qe() {
|
|
509
509
|
{
|
|
510
510
|
if (Be.current) {
|
|
511
|
-
var n =
|
|
511
|
+
var n = O(Be.current.type);
|
|
512
512
|
if (n)
|
|
513
513
|
return `
|
|
514
514
|
|
|
@@ -517,11 +517,11 @@ Check the render method of \`` + n + "`.";
|
|
|
517
517
|
return "";
|
|
518
518
|
}
|
|
519
519
|
}
|
|
520
|
-
function
|
|
520
|
+
function Rt(n) {
|
|
521
521
|
return "";
|
|
522
522
|
}
|
|
523
523
|
var et = {};
|
|
524
|
-
function
|
|
524
|
+
function Bt(n) {
|
|
525
525
|
{
|
|
526
526
|
var c = Qe();
|
|
527
527
|
if (!c) {
|
|
@@ -538,12 +538,12 @@ Check the top-level render call using <` + b + ">.");
|
|
|
538
538
|
if (!n._store || n._store.validated || n.key != null)
|
|
539
539
|
return;
|
|
540
540
|
n._store.validated = !0;
|
|
541
|
-
var b =
|
|
541
|
+
var b = Bt(c);
|
|
542
542
|
if (et[b])
|
|
543
543
|
return;
|
|
544
544
|
et[b] = !0;
|
|
545
|
-
var
|
|
546
|
-
n && n._owner && n._owner !== Be.current && (
|
|
545
|
+
var k = "";
|
|
546
|
+
n && n._owner && n._owner !== Be.current && (k = " It was passed a child from " + O(n._owner.type) + "."), we(n), P('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', b, k), we(null);
|
|
547
547
|
}
|
|
548
548
|
}
|
|
549
549
|
function rt(n, c) {
|
|
@@ -552,20 +552,20 @@ Check the top-level render call using <` + b + ">.");
|
|
|
552
552
|
return;
|
|
553
553
|
if (Array.isArray(n))
|
|
554
554
|
for (var b = 0; b < n.length; b++) {
|
|
555
|
-
var
|
|
556
|
-
$e(
|
|
555
|
+
var k = n[b];
|
|
556
|
+
$e(k) && tt(k, c);
|
|
557
557
|
}
|
|
558
558
|
else if ($e(n))
|
|
559
559
|
n._store && (n._store.validated = !0);
|
|
560
560
|
else if (n) {
|
|
561
|
-
var
|
|
562
|
-
if (typeof
|
|
563
|
-
for (var
|
|
564
|
-
$e(
|
|
561
|
+
var H = ae(n);
|
|
562
|
+
if (typeof H == "function" && H !== n.entries)
|
|
563
|
+
for (var F = H.call(n), A; !(A = F.next()).done; )
|
|
564
|
+
$e(A.value) && tt(A.value, c);
|
|
565
565
|
}
|
|
566
566
|
}
|
|
567
567
|
}
|
|
568
|
-
function
|
|
568
|
+
function Mt(n) {
|
|
569
569
|
{
|
|
570
570
|
var c = n.type;
|
|
571
571
|
if (c == null || typeof c == "string")
|
|
@@ -580,76 +580,76 @@ Check the top-level render call using <` + b + ">.");
|
|
|
580
580
|
else
|
|
581
581
|
return;
|
|
582
582
|
if (b) {
|
|
583
|
-
var
|
|
584
|
-
Ce(b, n.props, "prop",
|
|
583
|
+
var k = O(c);
|
|
584
|
+
Ce(b, n.props, "prop", k, n);
|
|
585
585
|
} else if (c.PropTypes !== void 0 && !Me) {
|
|
586
586
|
Me = !0;
|
|
587
|
-
var
|
|
588
|
-
|
|
587
|
+
var H = O(c);
|
|
588
|
+
P("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?", H || "Unknown");
|
|
589
589
|
}
|
|
590
|
-
typeof c.getDefaultProps == "function" && !c.getDefaultProps.isReactClassApproved &&
|
|
590
|
+
typeof c.getDefaultProps == "function" && !c.getDefaultProps.isReactClassApproved && P("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.");
|
|
591
591
|
}
|
|
592
592
|
}
|
|
593
|
-
function
|
|
593
|
+
function $t(n) {
|
|
594
594
|
{
|
|
595
595
|
for (var c = Object.keys(n.props), b = 0; b < c.length; b++) {
|
|
596
|
-
var
|
|
597
|
-
if (
|
|
598
|
-
we(n),
|
|
596
|
+
var k = c[b];
|
|
597
|
+
if (k !== "children" && k !== "key") {
|
|
598
|
+
we(n), P("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.", k), we(null);
|
|
599
599
|
break;
|
|
600
600
|
}
|
|
601
601
|
}
|
|
602
|
-
n.ref !== null && (we(n),
|
|
602
|
+
n.ref !== null && (we(n), P("Invalid attribute `ref` supplied to `React.Fragment`."), we(null));
|
|
603
603
|
}
|
|
604
604
|
}
|
|
605
|
-
function nt(n, c, b,
|
|
605
|
+
function nt(n, c, b, k, H, F) {
|
|
606
606
|
{
|
|
607
|
-
var
|
|
608
|
-
if (!
|
|
609
|
-
var
|
|
610
|
-
(n === void 0 || typeof n == "object" && n !== null && Object.keys(n).length === 0) && (
|
|
611
|
-
var
|
|
612
|
-
|
|
613
|
-
var
|
|
614
|
-
n === null ?
|
|
607
|
+
var A = ne(n);
|
|
608
|
+
if (!A) {
|
|
609
|
+
var L = "";
|
|
610
|
+
(n === void 0 || typeof n == "object" && n !== null && Object.keys(n).length === 0) && (L += " You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");
|
|
611
|
+
var ie = Rt();
|
|
612
|
+
ie ? L += ie : L += Qe();
|
|
613
|
+
var J;
|
|
614
|
+
n === null ? J = "null" : Array.isArray(n) ? J = "array" : n !== void 0 && n.$$typeof === s ? (J = "<" + (O(n.type) || "Unknown") + " />", L = " Did you accidentally export a JSX literal instead of a component?") : J = typeof n, P("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", J, L);
|
|
615
615
|
}
|
|
616
|
-
var Q =
|
|
616
|
+
var Q = Ot(n, c, b, H, F);
|
|
617
617
|
if (Q == null)
|
|
618
618
|
return Q;
|
|
619
|
-
if (
|
|
619
|
+
if (A) {
|
|
620
620
|
var _e = c.children;
|
|
621
621
|
if (_e !== void 0)
|
|
622
|
-
if (
|
|
622
|
+
if (k)
|
|
623
623
|
if (Array.isArray(_e)) {
|
|
624
624
|
for (var ke = 0; ke < _e.length; ke++)
|
|
625
625
|
rt(_e[ke], n);
|
|
626
626
|
Object.freeze && Object.freeze(_e);
|
|
627
627
|
} else
|
|
628
|
-
|
|
628
|
+
P("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");
|
|
629
629
|
else
|
|
630
630
|
rt(_e, n);
|
|
631
631
|
}
|
|
632
|
-
return n === e.Fragment ?
|
|
632
|
+
return n === e.Fragment ? $t(Q) : Mt(Q), Q;
|
|
633
633
|
}
|
|
634
634
|
}
|
|
635
|
-
function
|
|
635
|
+
function Ft(n, c, b) {
|
|
636
636
|
return nt(n, c, b, !0);
|
|
637
637
|
}
|
|
638
|
-
function
|
|
638
|
+
function Wt(n, c, b) {
|
|
639
639
|
return nt(n, c, b, !1);
|
|
640
640
|
}
|
|
641
|
-
var
|
|
642
|
-
e.jsx =
|
|
641
|
+
var Ht = Wt, Vt = Ft;
|
|
642
|
+
e.jsx = Ht, e.jsxs = Vt;
|
|
643
643
|
}();
|
|
644
644
|
}(We)), We;
|
|
645
645
|
}
|
|
646
|
-
process.env.NODE_ENV === "production" ? qe.exports =
|
|
646
|
+
process.env.NODE_ENV === "production" ? qe.exports = Gt() : qe.exports = Yt();
|
|
647
647
|
var t = qe.exports;
|
|
648
|
-
const
|
|
648
|
+
const Zt = {
|
|
649
649
|
production: "https://journey.apps.opendoor.com/_journey/api/v1/events",
|
|
650
650
|
staging: "https://journey.apps-staging.opendoor.com/_journey/api/v1/events"
|
|
651
|
-
},
|
|
652
|
-
function
|
|
651
|
+
}, Kt = "partner-sdk", zt = "1.0", Jt = 5e3, Xt = 20, Qt = 512, er = 5, lt = 500, ct = "od_sdk_aid";
|
|
652
|
+
function tr() {
|
|
653
653
|
try {
|
|
654
654
|
const e = localStorage.getItem(ct);
|
|
655
655
|
if (e)
|
|
@@ -660,7 +660,7 @@ function rr() {
|
|
|
660
660
|
return;
|
|
661
661
|
}
|
|
662
662
|
}
|
|
663
|
-
function
|
|
663
|
+
function rr() {
|
|
664
664
|
return typeof window > "u" ? { url: "", eventOrigin: "CLIENT" } : {
|
|
665
665
|
url: window.location.href,
|
|
666
666
|
userAgent: navigator.userAgent,
|
|
@@ -676,17 +676,17 @@ function nr() {
|
|
|
676
676
|
language: Array.from(navigator.languages ?? [])
|
|
677
677
|
};
|
|
678
678
|
}
|
|
679
|
-
function
|
|
679
|
+
function nr(e) {
|
|
680
680
|
let r = 0;
|
|
681
681
|
for (const a of e)
|
|
682
682
|
r += a.length;
|
|
683
683
|
return r / 1024;
|
|
684
684
|
}
|
|
685
|
-
function
|
|
686
|
-
return
|
|
685
|
+
function ar(e) {
|
|
686
|
+
return nr(e) >= Qt - 50;
|
|
687
687
|
}
|
|
688
|
-
async function
|
|
689
|
-
let a =
|
|
688
|
+
async function sr(e, r) {
|
|
689
|
+
let a = er;
|
|
690
690
|
for (; a > 0; )
|
|
691
691
|
try {
|
|
692
692
|
const s = await fetch(e, r);
|
|
@@ -703,13 +703,13 @@ async function or(e, r) {
|
|
|
703
703
|
break;
|
|
704
704
|
}
|
|
705
705
|
}
|
|
706
|
-
class
|
|
706
|
+
class or {
|
|
707
707
|
constructor(r) {
|
|
708
708
|
this.buffer = [], this.destroyed = !1, this.onVisibilityChange = () => {
|
|
709
709
|
document.visibilityState === "hidden" && this.flush(!0);
|
|
710
710
|
}, this.onBeforeUnload = () => {
|
|
711
711
|
this.flush(!0);
|
|
712
|
-
}, this.endpoint =
|
|
712
|
+
}, this.endpoint = Zt[r], this.anonymousId = tr(), this.timer = setInterval(() => this.flush(), Jt), typeof document < "u" && document.addEventListener("visibilitychange", this.onVisibilityChange), typeof window < "u" && window.addEventListener("beforeunload", this.onBeforeUnload);
|
|
713
713
|
}
|
|
714
714
|
trackPlatform(r) {
|
|
715
715
|
this.enqueue({ platform: r });
|
|
@@ -724,14 +724,14 @@ class ir {
|
|
|
724
724
|
if (this.buffer.length === 0)
|
|
725
725
|
return;
|
|
726
726
|
const a = `{"eventWrappers":[${this.buffer.join(",")}]}`;
|
|
727
|
-
this.buffer = [],
|
|
727
|
+
this.buffer = [], sr(this.endpoint, {
|
|
728
728
|
method: "POST",
|
|
729
729
|
credentials: "omit",
|
|
730
730
|
keepalive: r,
|
|
731
731
|
headers: {
|
|
732
732
|
"Content-Type": "application/json",
|
|
733
|
-
"X-Journey-Client-Name":
|
|
734
|
-
"X-Journey-Client-Version":
|
|
733
|
+
"X-Journey-Client-Name": Kt,
|
|
734
|
+
"X-Journey-Client-Version": zt
|
|
735
735
|
},
|
|
736
736
|
body: a
|
|
737
737
|
});
|
|
@@ -744,11 +744,11 @@ class ir {
|
|
|
744
744
|
return;
|
|
745
745
|
const a = {
|
|
746
746
|
timestamp: (/* @__PURE__ */ new Date()).toISOString(),
|
|
747
|
-
websiteSource:
|
|
747
|
+
websiteSource: rr(),
|
|
748
748
|
anonymousId: this.anonymousId,
|
|
749
749
|
...r
|
|
750
750
|
};
|
|
751
|
-
this.buffer.push(JSON.stringify(a)), (this.buffer.length >=
|
|
751
|
+
this.buffer.push(JSON.stringify(a)), (this.buffer.length >= Xt || ar(this.buffer)) && this.flush();
|
|
752
752
|
}
|
|
753
753
|
}
|
|
754
754
|
const Ge = {
|
|
@@ -760,35 +760,35 @@ const Ge = {
|
|
|
760
760
|
},
|
|
761
761
|
destroy() {
|
|
762
762
|
}
|
|
763
|
-
}, Ye = Ue(null),
|
|
763
|
+
}, Ye = Ue(null), Ct = Ue(Ge), Ao = ({
|
|
764
764
|
client: e,
|
|
765
765
|
children: r
|
|
766
766
|
}) => {
|
|
767
|
-
const [a, s] =
|
|
768
|
-
return
|
|
769
|
-
const o = new
|
|
767
|
+
const [a, s] = E(Ge);
|
|
768
|
+
return le(() => {
|
|
769
|
+
const o = new or(e.environment);
|
|
770
770
|
return s(o), () => {
|
|
771
771
|
o.destroy();
|
|
772
772
|
};
|
|
773
|
-
}, [e]), /* @__PURE__ */ t.jsx(Ye.Provider, { value: e, children: /* @__PURE__ */ t.jsx(
|
|
774
|
-
},
|
|
775
|
-
const e =
|
|
773
|
+
}, [e]), /* @__PURE__ */ t.jsx(Ye.Provider, { value: e, children: /* @__PURE__ */ t.jsx(Ct.Provider, { value: a, children: r }) });
|
|
774
|
+
}, wt = () => {
|
|
775
|
+
const e = Ae(Ye);
|
|
776
776
|
if (!e)
|
|
777
777
|
throw new Error(
|
|
778
778
|
"useOpendoorClient must be used within an <OpendoorProvider>. Wrap your component tree with <OpendoorProvider client={client}>."
|
|
779
779
|
);
|
|
780
780
|
return e;
|
|
781
|
-
}, Ze = () =>
|
|
782
|
-
function
|
|
783
|
-
const a = Ze(), s =
|
|
781
|
+
}, Ze = () => Ae(Ct);
|
|
782
|
+
function kt(e, r = {}) {
|
|
783
|
+
const a = Ze(), s = Z(a);
|
|
784
784
|
s.current = a;
|
|
785
|
-
const o =
|
|
786
|
-
return
|
|
785
|
+
const o = Z(null), i = Z(!1);
|
|
786
|
+
return le(() => {
|
|
787
787
|
const _ = o.current;
|
|
788
788
|
if (!_ || !e || i.current) return;
|
|
789
789
|
const f = new IntersectionObserver(
|
|
790
|
-
([
|
|
791
|
-
if (
|
|
790
|
+
([d]) => {
|
|
791
|
+
if (d.isIntersecting && !i.current) {
|
|
792
792
|
if (s.current === Ge) return;
|
|
793
793
|
i.current = !0, s.current.trackPlatform({
|
|
794
794
|
inputViewEvent: { targetName: e }
|
|
@@ -845,7 +845,7 @@ const He = {
|
|
|
845
845
|
colorCardBorder: "#e5e7eb",
|
|
846
846
|
colorCardBorderSelected: "#235ca3",
|
|
847
847
|
colorCardBackgroundSelected: "#f0f5ff"
|
|
848
|
-
},
|
|
848
|
+
}, ir = {
|
|
849
849
|
/** Default theme — pill-shaped inputs, bold borders, Opendoor blue */
|
|
850
850
|
default: He,
|
|
851
851
|
/** Minimal theme — subtle borders, square corners, lighter shadows */
|
|
@@ -881,22 +881,22 @@ const He = {
|
|
|
881
881
|
buttonPaddingX: "32px"
|
|
882
882
|
}
|
|
883
883
|
};
|
|
884
|
-
function
|
|
885
|
-
const r =
|
|
884
|
+
function lr(e) {
|
|
885
|
+
const r = ir[(e == null ? void 0 : e.theme) ?? "default"];
|
|
886
886
|
return e != null && e.variables ? { ...r, ...e.variables } : r;
|
|
887
887
|
}
|
|
888
888
|
function Se(e) {
|
|
889
|
-
const r =
|
|
889
|
+
const r = lr(e), a = {};
|
|
890
890
|
for (const [s, o] of Object.entries(r)) {
|
|
891
891
|
const i = s.replace(/([A-Z])/g, "-$1").toLowerCase();
|
|
892
892
|
a[`--od-${i}`] = o;
|
|
893
893
|
}
|
|
894
894
|
return a;
|
|
895
895
|
}
|
|
896
|
-
const
|
|
897
|
-
attribution:
|
|
898
|
-
text:
|
|
899
|
-
},
|
|
896
|
+
const cr = "_attribution_11y4r_7", ur = "_text_11y4r_16", ut = {
|
|
897
|
+
attribution: cr,
|
|
898
|
+
text: ur
|
|
899
|
+
}, dr = () => /* @__PURE__ */ t.jsx(
|
|
900
900
|
"svg",
|
|
901
901
|
{
|
|
902
902
|
width: "75",
|
|
@@ -915,33 +915,33 @@ const ur = "_attribution_11y4r_7", dr = "_text_11y4r_16", ut = {
|
|
|
915
915
|
)
|
|
916
916
|
}
|
|
917
917
|
);
|
|
918
|
-
function
|
|
918
|
+
function hr() {
|
|
919
919
|
return /* @__PURE__ */ t.jsxs("div", { className: ut.attribution, "data-testid": "od-attribution", children: [
|
|
920
920
|
/* @__PURE__ */ t.jsx("span", { className: ut.text, children: "Powered by" }),
|
|
921
|
-
/* @__PURE__ */ t.jsx(
|
|
921
|
+
/* @__PURE__ */ t.jsx(dr, {})
|
|
922
922
|
] });
|
|
923
923
|
}
|
|
924
|
-
const
|
|
925
|
-
container:
|
|
926
|
-
inputSection:
|
|
927
|
-
inputWrapper:
|
|
928
|
-
input:
|
|
929
|
-
inputIcon:
|
|
930
|
-
button:
|
|
931
|
-
spinner:
|
|
932
|
-
suggestions:
|
|
933
|
-
errorState:
|
|
934
|
-
suggestion:
|
|
935
|
-
error:
|
|
936
|
-
errorIcon:
|
|
937
|
-
errorBorder:
|
|
938
|
-
manualLink:
|
|
939
|
-
manualForm:
|
|
940
|
-
manualFormField:
|
|
941
|
-
manualFormLabel:
|
|
942
|
-
manualFormInput:
|
|
943
|
-
formRow:
|
|
944
|
-
submitButton:
|
|
924
|
+
const fr = "_container_tu90h_8", mr = "_inputSection_tu90h_16", pr = "_inputWrapper_tu90h_22", gr = "_input_tu90h_16", _r = "_inputIcon_tu90h_63", br = "_button_tu90h_80", yr = "_spinner_tu90h_121", vr = "_suggestions_tu90h_136", xr = "_errorState_tu90h_150", Cr = "_suggestion_tu90h_136", wr = "_error_tu90h_150", kr = "_errorIcon_tu90h_199", jr = "_errorBorder_tu90h_213", Nr = "_manualLink_tu90h_223", Ir = "_manualForm_tu90h_245", Er = "_manualFormField_tu90h_260", Sr = "_manualFormLabel_tu90h_264", Pr = "_manualFormInput_tu90h_273", Lr = "_formRow_tu90h_294", Tr = "_submitButton_tu90h_302", D = {
|
|
925
|
+
container: fr,
|
|
926
|
+
inputSection: mr,
|
|
927
|
+
inputWrapper: pr,
|
|
928
|
+
input: gr,
|
|
929
|
+
inputIcon: _r,
|
|
930
|
+
button: br,
|
|
931
|
+
spinner: yr,
|
|
932
|
+
suggestions: vr,
|
|
933
|
+
errorState: xr,
|
|
934
|
+
suggestion: Cr,
|
|
935
|
+
error: wr,
|
|
936
|
+
errorIcon: kr,
|
|
937
|
+
errorBorder: jr,
|
|
938
|
+
manualLink: Nr,
|
|
939
|
+
manualForm: Ir,
|
|
940
|
+
manualFormField: Er,
|
|
941
|
+
manualFormLabel: Sr,
|
|
942
|
+
manualFormInput: Pr,
|
|
943
|
+
formRow: Lr,
|
|
944
|
+
submitButton: Tr
|
|
945
945
|
}, dt = () => /* @__PURE__ */ t.jsx(
|
|
946
946
|
"svg",
|
|
947
947
|
{
|
|
@@ -987,7 +987,7 @@ function ht(e) {
|
|
|
987
987
|
const r = [e.street1];
|
|
988
988
|
return e.street2 && (r[0] += ` ${e.street2}`), r.push(`${e.city}, ${e.state} ${e.postalCode}`), r.join(", ");
|
|
989
989
|
}
|
|
990
|
-
function
|
|
990
|
+
function Do({
|
|
991
991
|
onAddressSelect: e,
|
|
992
992
|
enableAddressSuggestions: r = !0,
|
|
993
993
|
debounceMs: a = 300,
|
|
@@ -996,91 +996,91 @@ function Ao({
|
|
|
996
996
|
placeholderText: i = "Enter your home address",
|
|
997
997
|
buttonText: _ = "Get cash offer",
|
|
998
998
|
showButton: f = !0,
|
|
999
|
-
buttonIcon:
|
|
999
|
+
buttonIcon: d,
|
|
1000
1000
|
inputIcon: h,
|
|
1001
|
-
manualEntryText:
|
|
1001
|
+
manualEntryText: u = "Enter address manually instead",
|
|
1002
1002
|
appearance: m,
|
|
1003
1003
|
onReady: g,
|
|
1004
|
-
onChange:
|
|
1005
|
-
onValidationError:
|
|
1006
|
-
onAddressSuggestionsStart:
|
|
1007
|
-
onAddressSuggestionsComplete:
|
|
1008
|
-
onError:
|
|
1004
|
+
onChange: C,
|
|
1005
|
+
onValidationError: v,
|
|
1006
|
+
onAddressSuggestionsStart: R,
|
|
1007
|
+
onAddressSuggestionsComplete: W,
|
|
1008
|
+
onError: S
|
|
1009
1009
|
}) {
|
|
1010
|
-
const
|
|
1010
|
+
const K = wt(), w = Ze(), re = Se(m), [T, ae] = E(""), [V, P] = E([]), [te, G] = E(!1), [ne, se] = E(!1), [Y, O] = E(null), [U, B] = E(!1), [y, I] = E(!1), [j, me] = E({
|
|
1011
1011
|
street1: "",
|
|
1012
1012
|
street2: "",
|
|
1013
1013
|
city: "",
|
|
1014
1014
|
state: "",
|
|
1015
1015
|
postalCode: ""
|
|
1016
|
-
}),
|
|
1016
|
+
}), ce = Z(null), pe = kt("partner-sdk-address-input", {
|
|
1017
1017
|
immediate: !0
|
|
1018
|
-
}),
|
|
1019
|
-
|
|
1020
|
-
const
|
|
1021
|
-
|
|
1022
|
-
const
|
|
1023
|
-
|
|
1024
|
-
const
|
|
1025
|
-
|
|
1018
|
+
}), de = Z(S);
|
|
1019
|
+
de.current = S;
|
|
1020
|
+
const N = Z(R);
|
|
1021
|
+
N.current = R;
|
|
1022
|
+
const M = Z(W);
|
|
1023
|
+
M.current = W;
|
|
1024
|
+
const q = Z(null), $ = te && !ne && T.trim().length >= 3 && V.length === 0 && !y;
|
|
1025
|
+
le(() => {
|
|
1026
1026
|
g == null || g();
|
|
1027
|
-
}, []),
|
|
1028
|
-
if (!r ||
|
|
1029
|
-
|
|
1027
|
+
}, []), le(() => {
|
|
1028
|
+
if (!r || T.trim().length < 3 || U) {
|
|
1029
|
+
T.trim().length === 0 && (P([]), G(!1), O(null));
|
|
1030
1030
|
return;
|
|
1031
1031
|
}
|
|
1032
|
-
|
|
1033
|
-
const
|
|
1034
|
-
var
|
|
1035
|
-
(
|
|
1032
|
+
se(!0), O(null);
|
|
1033
|
+
const x = setTimeout(async () => {
|
|
1034
|
+
var z, X, xe;
|
|
1035
|
+
(z = N.current) == null || z.call(N, T);
|
|
1036
1036
|
try {
|
|
1037
|
-
const Ce = await
|
|
1038
|
-
|
|
1037
|
+
const Ce = await K.getAddressSuggestions(T);
|
|
1038
|
+
P(Ce.addresses), G(!0), (X = M.current) == null || X.call(M, Ce.addresses);
|
|
1039
1039
|
} catch (Ce) {
|
|
1040
1040
|
const Ne = Ce instanceof Error ? Ce : new Error("Failed to fetch address suggestions");
|
|
1041
|
-
|
|
1041
|
+
O(Ne.message), P([]), G(!0), (xe = de.current) == null || xe.call(de, Ne);
|
|
1042
1042
|
} finally {
|
|
1043
|
-
|
|
1043
|
+
se(!1);
|
|
1044
1044
|
}
|
|
1045
1045
|
}, a);
|
|
1046
|
-
return () => clearTimeout(
|
|
1047
|
-
}, [
|
|
1048
|
-
const
|
|
1049
|
-
|
|
1046
|
+
return () => clearTimeout(x);
|
|
1047
|
+
}, [T, U, r, a, K]), le(() => {
|
|
1048
|
+
const x = (z) => {
|
|
1049
|
+
q.current && !q.current.contains(z.target) && ce.current && !ce.current.contains(z.target) && G(!1);
|
|
1050
1050
|
};
|
|
1051
|
-
return document.addEventListener("mousedown",
|
|
1051
|
+
return document.addEventListener("mousedown", x), () => document.removeEventListener("mousedown", x);
|
|
1052
1052
|
}, []);
|
|
1053
|
-
const
|
|
1054
|
-
const
|
|
1055
|
-
|
|
1056
|
-
},
|
|
1057
|
-
|
|
1053
|
+
const oe = (x) => {
|
|
1054
|
+
const z = x.target.value;
|
|
1055
|
+
ae(z), B(!1), C == null || C({ street1: z });
|
|
1056
|
+
}, he = async (x) => {
|
|
1057
|
+
B(!0), ae(ht(x)), P([]), G(!1), O(null), C == null || C(x), w.trackSell({
|
|
1058
1058
|
addressEntryV2: {
|
|
1059
|
-
street1:
|
|
1060
|
-
city:
|
|
1061
|
-
state:
|
|
1062
|
-
postalCode:
|
|
1063
|
-
unit:
|
|
1059
|
+
street1: x.street1,
|
|
1060
|
+
city: x.city,
|
|
1061
|
+
state: x.state,
|
|
1062
|
+
postalCode: x.postalCode,
|
|
1063
|
+
unit: x.street2,
|
|
1064
1064
|
sourcePage: "partner-sdk"
|
|
1065
1065
|
}
|
|
1066
1066
|
});
|
|
1067
1067
|
try {
|
|
1068
|
-
await e(
|
|
1069
|
-
} catch (
|
|
1070
|
-
const X =
|
|
1071
|
-
|
|
1068
|
+
await e(x);
|
|
1069
|
+
} catch (z) {
|
|
1070
|
+
const X = z instanceof Error ? z : new Error("Failed to process address");
|
|
1071
|
+
O(X.message), S == null || S(X), ae(""), B(!1);
|
|
1072
1072
|
}
|
|
1073
1073
|
}, ge = () => {
|
|
1074
|
-
|
|
1074
|
+
w.trackPlatform({
|
|
1075
1075
|
inputFocusEvent: { targetName: "partner-sdk-address-input" }
|
|
1076
|
-
}),
|
|
1076
|
+
}), V.length > 0 && T.length > 0 && G(!0);
|
|
1077
1077
|
}, Oe = () => {
|
|
1078
|
-
|
|
1078
|
+
w.trackPlatform({
|
|
1079
1079
|
linkClickEvent: { targetName: "partner-sdk-manual-entry" }
|
|
1080
|
-
}),
|
|
1081
|
-
}, ye = (
|
|
1082
|
-
const X = { ...
|
|
1083
|
-
|
|
1080
|
+
}), I(!0), G(!1);
|
|
1081
|
+
}, ye = (x, z) => {
|
|
1082
|
+
const X = { ...j, [x]: z };
|
|
1083
|
+
me(X), C == null || C({
|
|
1084
1084
|
street1: X.street1,
|
|
1085
1085
|
...X.street2 ? { street2: X.street2 } : {},
|
|
1086
1086
|
city: X.city,
|
|
@@ -1088,111 +1088,111 @@ function Ao({
|
|
|
1088
1088
|
postalCode: X.postalCode
|
|
1089
1089
|
});
|
|
1090
1090
|
}, Pe = async () => {
|
|
1091
|
-
if (!
|
|
1092
|
-
const
|
|
1093
|
-
|
|
1091
|
+
if (!j.street1 || !j.city || !j.state || !j.postalCode) {
|
|
1092
|
+
const x = "Please fill in all required fields";
|
|
1093
|
+
O(x), v == null || v(x);
|
|
1094
1094
|
return;
|
|
1095
1095
|
}
|
|
1096
|
-
|
|
1096
|
+
se(!0), O(null);
|
|
1097
1097
|
try {
|
|
1098
|
-
const
|
|
1099
|
-
street1:
|
|
1100
|
-
...
|
|
1101
|
-
city:
|
|
1102
|
-
state:
|
|
1103
|
-
postalCode:
|
|
1098
|
+
const x = {
|
|
1099
|
+
street1: j.street1,
|
|
1100
|
+
...j.street2 ? { street2: j.street2 } : {},
|
|
1101
|
+
city: j.city,
|
|
1102
|
+
state: j.state,
|
|
1103
|
+
postalCode: j.postalCode
|
|
1104
1104
|
};
|
|
1105
|
-
|
|
1105
|
+
w.trackSell({
|
|
1106
1106
|
addressEntryV2: {
|
|
1107
|
-
street1:
|
|
1108
|
-
city:
|
|
1109
|
-
state:
|
|
1110
|
-
postalCode:
|
|
1111
|
-
unit:
|
|
1107
|
+
street1: x.street1,
|
|
1108
|
+
city: x.city,
|
|
1109
|
+
state: x.state,
|
|
1110
|
+
postalCode: x.postalCode,
|
|
1111
|
+
unit: x.street2,
|
|
1112
1112
|
sourcePage: "partner-sdk"
|
|
1113
1113
|
}
|
|
1114
|
-
}), await e(
|
|
1115
|
-
} catch (
|
|
1116
|
-
const
|
|
1117
|
-
|
|
1114
|
+
}), await e(x);
|
|
1115
|
+
} catch (x) {
|
|
1116
|
+
const z = x instanceof Error ? x : new Error("Failed to submit address");
|
|
1117
|
+
O(z.message), S == null || S(z);
|
|
1118
1118
|
} finally {
|
|
1119
|
-
|
|
1119
|
+
se(!1);
|
|
1120
1120
|
}
|
|
1121
|
-
}, ve = !!
|
|
1122
|
-
return /* @__PURE__ */ t.jsxs("div", { ref: pe, className:
|
|
1123
|
-
y ? /* @__PURE__ */ t.jsxs("div", { className:
|
|
1124
|
-
/* @__PURE__ */ t.jsxs("div", { className:
|
|
1125
|
-
/* @__PURE__ */ t.jsx("label", { className:
|
|
1121
|
+
}, ve = !!Y;
|
|
1122
|
+
return /* @__PURE__ */ t.jsxs("div", { ref: pe, className: D.container, style: re, children: [
|
|
1123
|
+
y ? /* @__PURE__ */ t.jsxs("div", { className: D.manualForm, children: [
|
|
1124
|
+
/* @__PURE__ */ t.jsxs("div", { className: D.manualFormField, children: [
|
|
1125
|
+
/* @__PURE__ */ t.jsx("label", { className: D.manualFormLabel, htmlFor: "ae-street1", children: "Street Address *" }),
|
|
1126
1126
|
/* @__PURE__ */ t.jsx(
|
|
1127
1127
|
"input",
|
|
1128
1128
|
{
|
|
1129
1129
|
id: "ae-street1",
|
|
1130
1130
|
type: "text",
|
|
1131
|
-
className:
|
|
1132
|
-
value:
|
|
1133
|
-
onChange: (
|
|
1131
|
+
className: D.manualFormInput,
|
|
1132
|
+
value: j.street1,
|
|
1133
|
+
onChange: (x) => ye("street1", x.target.value),
|
|
1134
1134
|
disabled: o,
|
|
1135
1135
|
placeholder: "123 Main St"
|
|
1136
1136
|
}
|
|
1137
1137
|
)
|
|
1138
1138
|
] }),
|
|
1139
|
-
/* @__PURE__ */ t.jsxs("div", { className:
|
|
1140
|
-
/* @__PURE__ */ t.jsx("label", { className:
|
|
1139
|
+
/* @__PURE__ */ t.jsxs("div", { className: D.manualFormField, children: [
|
|
1140
|
+
/* @__PURE__ */ t.jsx("label", { className: D.manualFormLabel, htmlFor: "ae-street2", children: "Unit / Apt (optional)" }),
|
|
1141
1141
|
/* @__PURE__ */ t.jsx(
|
|
1142
1142
|
"input",
|
|
1143
1143
|
{
|
|
1144
1144
|
id: "ae-street2",
|
|
1145
1145
|
type: "text",
|
|
1146
|
-
className:
|
|
1147
|
-
value:
|
|
1148
|
-
onChange: (
|
|
1146
|
+
className: D.manualFormInput,
|
|
1147
|
+
value: j.street2,
|
|
1148
|
+
onChange: (x) => ye("street2", x.target.value),
|
|
1149
1149
|
disabled: o,
|
|
1150
1150
|
placeholder: "Apt 4B"
|
|
1151
1151
|
}
|
|
1152
1152
|
)
|
|
1153
1153
|
] }),
|
|
1154
|
-
/* @__PURE__ */ t.jsxs("div", { className:
|
|
1155
|
-
/* @__PURE__ */ t.jsx("label", { className:
|
|
1154
|
+
/* @__PURE__ */ t.jsxs("div", { className: D.manualFormField, children: [
|
|
1155
|
+
/* @__PURE__ */ t.jsx("label", { className: D.manualFormLabel, htmlFor: "ae-city", children: "City *" }),
|
|
1156
1156
|
/* @__PURE__ */ t.jsx(
|
|
1157
1157
|
"input",
|
|
1158
1158
|
{
|
|
1159
1159
|
id: "ae-city",
|
|
1160
1160
|
type: "text",
|
|
1161
|
-
className:
|
|
1162
|
-
value:
|
|
1163
|
-
onChange: (
|
|
1161
|
+
className: D.manualFormInput,
|
|
1162
|
+
value: j.city,
|
|
1163
|
+
onChange: (x) => ye("city", x.target.value),
|
|
1164
1164
|
disabled: o,
|
|
1165
1165
|
placeholder: "Austin"
|
|
1166
1166
|
}
|
|
1167
1167
|
)
|
|
1168
1168
|
] }),
|
|
1169
|
-
/* @__PURE__ */ t.jsxs("div", { className:
|
|
1170
|
-
/* @__PURE__ */ t.jsxs("div", { className:
|
|
1171
|
-
/* @__PURE__ */ t.jsx("label", { className:
|
|
1169
|
+
/* @__PURE__ */ t.jsxs("div", { className: D.formRow, children: [
|
|
1170
|
+
/* @__PURE__ */ t.jsxs("div", { className: D.manualFormField, children: [
|
|
1171
|
+
/* @__PURE__ */ t.jsx("label", { className: D.manualFormLabel, htmlFor: "ae-state", children: "State *" }),
|
|
1172
1172
|
/* @__PURE__ */ t.jsx(
|
|
1173
1173
|
"input",
|
|
1174
1174
|
{
|
|
1175
1175
|
id: "ae-state",
|
|
1176
1176
|
type: "text",
|
|
1177
|
-
className:
|
|
1178
|
-
value:
|
|
1179
|
-
onChange: (
|
|
1177
|
+
className: D.manualFormInput,
|
|
1178
|
+
value: j.state,
|
|
1179
|
+
onChange: (x) => ye("state", x.target.value),
|
|
1180
1180
|
disabled: o,
|
|
1181
1181
|
placeholder: "TX",
|
|
1182
1182
|
maxLength: 2
|
|
1183
1183
|
}
|
|
1184
1184
|
)
|
|
1185
1185
|
] }),
|
|
1186
|
-
/* @__PURE__ */ t.jsxs("div", { className:
|
|
1187
|
-
/* @__PURE__ */ t.jsx("label", { className:
|
|
1186
|
+
/* @__PURE__ */ t.jsxs("div", { className: D.manualFormField, children: [
|
|
1187
|
+
/* @__PURE__ */ t.jsx("label", { className: D.manualFormLabel, htmlFor: "ae-postalCode", children: "ZIP Code *" }),
|
|
1188
1188
|
/* @__PURE__ */ t.jsx(
|
|
1189
1189
|
"input",
|
|
1190
1190
|
{
|
|
1191
1191
|
id: "ae-postalCode",
|
|
1192
1192
|
type: "text",
|
|
1193
|
-
className:
|
|
1194
|
-
value:
|
|
1195
|
-
onChange: (
|
|
1193
|
+
className: D.manualFormInput,
|
|
1194
|
+
value: j.postalCode,
|
|
1195
|
+
onChange: (x) => ye("postalCode", x.target.value),
|
|
1196
1196
|
disabled: o,
|
|
1197
1197
|
placeholder: "78701",
|
|
1198
1198
|
maxLength: 5
|
|
@@ -1200,36 +1200,36 @@ function Ao({
|
|
|
1200
1200
|
)
|
|
1201
1201
|
] })
|
|
1202
1202
|
] }),
|
|
1203
|
-
|
|
1203
|
+
Y && /* @__PURE__ */ t.jsx("div", { className: D.error, children: Y }),
|
|
1204
1204
|
/* @__PURE__ */ t.jsxs(
|
|
1205
1205
|
"button",
|
|
1206
1206
|
{
|
|
1207
1207
|
type: "button",
|
|
1208
|
-
className:
|
|
1208
|
+
className: D.submitButton,
|
|
1209
1209
|
onClick: Pe,
|
|
1210
1210
|
disabled: o,
|
|
1211
1211
|
children: [
|
|
1212
1212
|
/* @__PURE__ */ t.jsx("span", { children: _ }),
|
|
1213
|
-
|
|
1213
|
+
d || /* @__PURE__ */ t.jsx(dt, {})
|
|
1214
1214
|
]
|
|
1215
1215
|
}
|
|
1216
1216
|
)
|
|
1217
|
-
] }) : /* @__PURE__ */ t.jsxs("div", { className:
|
|
1217
|
+
] }) : /* @__PURE__ */ t.jsxs("div", { className: D.inputSection, children: [
|
|
1218
1218
|
/* @__PURE__ */ t.jsxs(
|
|
1219
1219
|
"div",
|
|
1220
1220
|
{
|
|
1221
|
-
className: `${
|
|
1221
|
+
className: `${D.inputWrapper} ${ve ? D.errorBorder : ""}`,
|
|
1222
1222
|
children: [
|
|
1223
1223
|
/* @__PURE__ */ t.jsx(
|
|
1224
1224
|
"input",
|
|
1225
1225
|
{
|
|
1226
|
-
ref:
|
|
1226
|
+
ref: ce,
|
|
1227
1227
|
type: "text",
|
|
1228
|
-
value:
|
|
1229
|
-
onChange:
|
|
1228
|
+
value: T,
|
|
1229
|
+
onChange: oe,
|
|
1230
1230
|
onFocus: ge,
|
|
1231
1231
|
placeholder: i,
|
|
1232
|
-
className:
|
|
1232
|
+
className: D.input,
|
|
1233
1233
|
disabled: o,
|
|
1234
1234
|
"aria-label": "Address input",
|
|
1235
1235
|
"aria-autocomplete": "list",
|
|
@@ -1237,20 +1237,20 @@ function Ao({
|
|
|
1237
1237
|
"aria-expanded": te
|
|
1238
1238
|
}
|
|
1239
1239
|
),
|
|
1240
|
-
h && /* @__PURE__ */ t.jsx("div", { className:
|
|
1240
|
+
h && /* @__PURE__ */ t.jsx("div", { className: D.inputIcon, children: h }),
|
|
1241
1241
|
f && /* @__PURE__ */ t.jsx(
|
|
1242
1242
|
"button",
|
|
1243
1243
|
{
|
|
1244
|
-
className:
|
|
1244
|
+
className: D.button,
|
|
1245
1245
|
type: "button",
|
|
1246
1246
|
disabled: o,
|
|
1247
1247
|
"aria-label": _,
|
|
1248
|
-
children:
|
|
1248
|
+
children: ne ? /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
|
|
1249
1249
|
/* @__PURE__ */ t.jsx("span", { children: _ }),
|
|
1250
1250
|
/* @__PURE__ */ t.jsxs(
|
|
1251
1251
|
"svg",
|
|
1252
1252
|
{
|
|
1253
|
-
className:
|
|
1253
|
+
className: D.spinner,
|
|
1254
1254
|
width: "20",
|
|
1255
1255
|
height: "20",
|
|
1256
1256
|
viewBox: "0 0 24 24",
|
|
@@ -1282,7 +1282,7 @@ function Ao({
|
|
|
1282
1282
|
)
|
|
1283
1283
|
] }) : /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
|
|
1284
1284
|
/* @__PURE__ */ t.jsx("span", { children: _ }),
|
|
1285
|
-
|
|
1285
|
+
d || /* @__PURE__ */ t.jsx(dt, {})
|
|
1286
1286
|
] })
|
|
1287
1287
|
}
|
|
1288
1288
|
)
|
|
@@ -1292,60 +1292,60 @@ function Ao({
|
|
|
1292
1292
|
(te || ve) && /* @__PURE__ */ t.jsx(
|
|
1293
1293
|
"div",
|
|
1294
1294
|
{
|
|
1295
|
-
ref:
|
|
1296
|
-
className: `${
|
|
1295
|
+
ref: q,
|
|
1296
|
+
className: `${D.suggestions} ${ve ? D.errorState : ""}`,
|
|
1297
1297
|
id: "address-suggestions",
|
|
1298
1298
|
role: ve && !te ? "alert" : "listbox",
|
|
1299
1299
|
"aria-live": ve && !te ? "polite" : void 0,
|
|
1300
|
-
children: ve ? /* @__PURE__ */ t.jsxs("div", { className:
|
|
1301
|
-
/* @__PURE__ */ t.jsx("div", { className:
|
|
1302
|
-
/* @__PURE__ */ t.jsx("div", { children:
|
|
1303
|
-
] }) :
|
|
1300
|
+
children: ve ? /* @__PURE__ */ t.jsxs("div", { className: D.error, children: [
|
|
1301
|
+
/* @__PURE__ */ t.jsx("div", { className: D.errorIcon, children: /* @__PURE__ */ t.jsx(Ar, {}) }),
|
|
1302
|
+
/* @__PURE__ */ t.jsx("div", { children: Y })
|
|
1303
|
+
] }) : V.length > 0 ? V.map((x, z) => /* @__PURE__ */ t.jsx(
|
|
1304
1304
|
"div",
|
|
1305
1305
|
{
|
|
1306
|
-
className:
|
|
1307
|
-
onClick: () =>
|
|
1306
|
+
className: D.suggestion,
|
|
1307
|
+
onClick: () => he(x),
|
|
1308
1308
|
role: "option",
|
|
1309
1309
|
"aria-selected": !1,
|
|
1310
1310
|
tabIndex: 0,
|
|
1311
1311
|
onKeyDown: (X) => {
|
|
1312
|
-
(X.key === "Enter" || X.key === " ") && (X.preventDefault(),
|
|
1312
|
+
(X.key === "Enter" || X.key === " ") && (X.preventDefault(), he(x));
|
|
1313
1313
|
},
|
|
1314
|
-
children: ht(
|
|
1314
|
+
children: ht(x)
|
|
1315
1315
|
},
|
|
1316
|
-
`${
|
|
1317
|
-
)) :
|
|
1316
|
+
`${x.street1}-${x.city}-${x.postalCode}-${z}`
|
|
1317
|
+
)) : $ && /* @__PURE__ */ t.jsx(
|
|
1318
1318
|
"button",
|
|
1319
1319
|
{
|
|
1320
1320
|
type: "button",
|
|
1321
|
-
className:
|
|
1321
|
+
className: D.manualLink,
|
|
1322
1322
|
onClick: Oe,
|
|
1323
|
-
children:
|
|
1323
|
+
children: u
|
|
1324
1324
|
}
|
|
1325
1325
|
)
|
|
1326
1326
|
}
|
|
1327
1327
|
)
|
|
1328
1328
|
] }),
|
|
1329
|
-
s && /* @__PURE__ */ t.jsx(
|
|
1329
|
+
s && /* @__PURE__ */ t.jsx(hr, {})
|
|
1330
1330
|
] });
|
|
1331
1331
|
}
|
|
1332
|
-
const
|
|
1333
|
-
container:
|
|
1334
|
-
title:
|
|
1335
|
-
addressCard:
|
|
1336
|
-
addressText:
|
|
1337
|
-
editLink:
|
|
1338
|
-
fieldGroup:
|
|
1339
|
-
fieldLabel:
|
|
1340
|
-
input:
|
|
1341
|
-
checkboxRow:
|
|
1342
|
-
checkbox:
|
|
1343
|
-
checkboxLabel:
|
|
1344
|
-
error:
|
|
1345
|
-
actions:
|
|
1346
|
-
confirmButton:
|
|
1332
|
+
const Dr = "_container_rg8mk_3", Or = "_title_rg8mk_7", Rr = "_addressCard_rg8mk_16", Br = "_addressText_rg8mk_26", Mr = "_editLink_rg8mk_34", $r = "_fieldGroup_rg8mk_47", Fr = "_fieldLabel_rg8mk_51", Wr = "_input_rg8mk_60", Hr = "_checkboxRow_rg8mk_84", Vr = "_checkbox_rg8mk_84", qr = "_checkboxLabel_rg8mk_101", Ur = "_error_rg8mk_108", Gr = "_actions_rg8mk_115", Yr = "_confirmButton_rg8mk_120", ue = {
|
|
1333
|
+
container: Dr,
|
|
1334
|
+
title: Or,
|
|
1335
|
+
addressCard: Rr,
|
|
1336
|
+
addressText: Br,
|
|
1337
|
+
editLink: Mr,
|
|
1338
|
+
fieldGroup: $r,
|
|
1339
|
+
fieldLabel: Fr,
|
|
1340
|
+
input: Wr,
|
|
1341
|
+
checkboxRow: Hr,
|
|
1342
|
+
checkbox: Vr,
|
|
1343
|
+
checkboxLabel: qr,
|
|
1344
|
+
error: Ur,
|
|
1345
|
+
actions: Gr,
|
|
1346
|
+
confirmButton: Yr
|
|
1347
1347
|
};
|
|
1348
|
-
function
|
|
1348
|
+
function Zr(e) {
|
|
1349
1349
|
return `${e.street1 + (e.street2 ? ` ${e.street2}` : "")}, ${e.city}, ${e.state} ${e.postalCode}`;
|
|
1350
1350
|
}
|
|
1351
1351
|
function Oo({
|
|
@@ -1354,82 +1354,82 @@ function Oo({
|
|
|
1354
1354
|
onConfirm: a,
|
|
1355
1355
|
onEdit: s
|
|
1356
1356
|
}) {
|
|
1357
|
-
const o = Ze(), _ = Se(r), f =
|
|
1358
|
-
if (!
|
|
1359
|
-
|
|
1357
|
+
const o = Ze(), _ = Se(r), f = kt("partner-sdk-unit-input"), [d, h] = E(""), [u, m] = E(!1), [g, C] = E(null), v = () => {
|
|
1358
|
+
if (!u && !d.trim()) {
|
|
1359
|
+
C("Please enter a unit number or select 'No unit number'");
|
|
1360
1360
|
return;
|
|
1361
1361
|
}
|
|
1362
|
-
|
|
1362
|
+
C(null), o.trackPlatform({
|
|
1363
1363
|
buttonClickEvent: { targetName: "partner-sdk-confirm-unit" }
|
|
1364
|
-
}), a(
|
|
1365
|
-
},
|
|
1364
|
+
}), a(u ? { ...e } : { ...e, street2: d.trim() });
|
|
1365
|
+
}, R = () => {
|
|
1366
1366
|
o.trackPlatform({
|
|
1367
1367
|
checkboxClickEvent: {
|
|
1368
1368
|
targetName: "partner-sdk-no-unit",
|
|
1369
|
-
optionName: String(!
|
|
1369
|
+
optionName: String(!u)
|
|
1370
1370
|
}
|
|
1371
|
-
}), m(!
|
|
1372
|
-
},
|
|
1373
|
-
h(
|
|
1374
|
-
},
|
|
1371
|
+
}), m(!u), u || (h(""), C(null));
|
|
1372
|
+
}, W = (K) => {
|
|
1373
|
+
h(K.target.value), g && C(null);
|
|
1374
|
+
}, S = () => {
|
|
1375
1375
|
o.trackPlatform({
|
|
1376
1376
|
inputFocusEvent: { targetName: "partner-sdk-unit-input" }
|
|
1377
1377
|
});
|
|
1378
1378
|
};
|
|
1379
|
-
return /* @__PURE__ */ t.jsxs("div", { ref: f, style: _, className:
|
|
1380
|
-
/* @__PURE__ */ t.jsx("h2", { className:
|
|
1381
|
-
/* @__PURE__ */ t.jsxs("div", { className:
|
|
1382
|
-
/* @__PURE__ */ t.jsx("span", { className:
|
|
1383
|
-
s && /* @__PURE__ */ t.jsx("button", { type: "button", className:
|
|
1379
|
+
return /* @__PURE__ */ t.jsxs("div", { ref: f, style: _, className: ue.container, children: [
|
|
1380
|
+
/* @__PURE__ */ t.jsx("h2", { className: ue.title, children: "Confirm your home address" }),
|
|
1381
|
+
/* @__PURE__ */ t.jsxs("div", { className: ue.addressCard, children: [
|
|
1382
|
+
/* @__PURE__ */ t.jsx("span", { className: ue.addressText, children: Zr(e) }),
|
|
1383
|
+
s && /* @__PURE__ */ t.jsx("button", { type: "button", className: ue.editLink, onClick: s, children: "Edit" })
|
|
1384
1384
|
] }),
|
|
1385
|
-
/* @__PURE__ */ t.jsxs("div", { className:
|
|
1386
|
-
/* @__PURE__ */ t.jsx("label", { className:
|
|
1385
|
+
/* @__PURE__ */ t.jsxs("div", { className: ue.fieldGroup, children: [
|
|
1386
|
+
/* @__PURE__ */ t.jsx("label", { className: ue.fieldLabel, htmlFor: "od-unit-number", children: "Unit number, apt, or floor*" }),
|
|
1387
1387
|
/* @__PURE__ */ t.jsx(
|
|
1388
1388
|
"input",
|
|
1389
1389
|
{
|
|
1390
1390
|
id: "od-unit-number",
|
|
1391
1391
|
type: "text",
|
|
1392
|
-
className:
|
|
1392
|
+
className: ue.input,
|
|
1393
1393
|
placeholder: "#1234",
|
|
1394
|
-
value:
|
|
1395
|
-
onChange:
|
|
1396
|
-
onFocus:
|
|
1397
|
-
disabled:
|
|
1394
|
+
value: d,
|
|
1395
|
+
onChange: W,
|
|
1396
|
+
onFocus: S,
|
|
1397
|
+
disabled: u
|
|
1398
1398
|
}
|
|
1399
1399
|
)
|
|
1400
1400
|
] }),
|
|
1401
|
-
/* @__PURE__ */ t.jsxs("label", { className:
|
|
1401
|
+
/* @__PURE__ */ t.jsxs("label", { className: ue.checkboxRow, children: [
|
|
1402
1402
|
/* @__PURE__ */ t.jsx(
|
|
1403
1403
|
"input",
|
|
1404
1404
|
{
|
|
1405
1405
|
type: "checkbox",
|
|
1406
|
-
className:
|
|
1407
|
-
checked:
|
|
1408
|
-
onChange:
|
|
1406
|
+
className: ue.checkbox,
|
|
1407
|
+
checked: u,
|
|
1408
|
+
onChange: R
|
|
1409
1409
|
}
|
|
1410
1410
|
),
|
|
1411
|
-
/* @__PURE__ */ t.jsx("span", { className:
|
|
1411
|
+
/* @__PURE__ */ t.jsx("span", { className: ue.checkboxLabel, children: "No unit number" })
|
|
1412
1412
|
] }),
|
|
1413
|
-
g && /* @__PURE__ */ t.jsx("p", { className:
|
|
1414
|
-
/* @__PURE__ */ t.jsx("div", { className:
|
|
1413
|
+
g && /* @__PURE__ */ t.jsx("p", { className: ue.error, children: g }),
|
|
1414
|
+
/* @__PURE__ */ t.jsx("div", { className: ue.actions, children: /* @__PURE__ */ t.jsx(
|
|
1415
1415
|
"button",
|
|
1416
1416
|
{
|
|
1417
1417
|
type: "button",
|
|
1418
|
-
className:
|
|
1419
|
-
onClick:
|
|
1418
|
+
className: ue.confirmButton,
|
|
1419
|
+
onClick: v,
|
|
1420
1420
|
children: "Confirm address"
|
|
1421
1421
|
}
|
|
1422
1422
|
) })
|
|
1423
1423
|
] });
|
|
1424
1424
|
}
|
|
1425
|
-
const
|
|
1426
|
-
function
|
|
1425
|
+
const Kr = "https://api.mapbox.com/geocoding/v5/mapbox.places", zr = "https://api.mapbox.com/styles/v1/mapbox/light-v11/static", Jr = "pk.eyJ1Ijoib3BlbmRvb3IiLCJhIjoiWXJ2bTJiRSJ9.lsnjT9yTNyyVzKRIzqxnqg", Xr = "https://images.opendoor.com/source/s3/imgdrop-production/2026-02-1771546296495-06570.png?service=partner-sdk", Qr = 640, en = 320, tn = 14;
|
|
1426
|
+
function rn(e, r, a) {
|
|
1427
1427
|
return e.startsWith("http://") || e.startsWith("https://") ? `url-${encodeURIComponent(e)}(${r},${a})` : `${e}(${r},${a})`;
|
|
1428
1428
|
}
|
|
1429
|
-
function
|
|
1430
|
-
const a = (r == null ? void 0 : r.mapboxAccessToken) ??
|
|
1431
|
-
return
|
|
1432
|
-
|
|
1429
|
+
function nn(e, r) {
|
|
1430
|
+
const a = (r == null ? void 0 : r.mapboxAccessToken) ?? Jr, s = (r == null ? void 0 : r.mapPinMarker) ?? Xr, o = (r == null ? void 0 : r.width) ?? Qr, i = (r == null ? void 0 : r.height) ?? en, _ = (r == null ? void 0 : r.zoom) ?? tn, [f, d] = E(void 0), [h, u] = E("loading");
|
|
1431
|
+
return le(() => {
|
|
1432
|
+
u("loading");
|
|
1433
1433
|
const m = [
|
|
1434
1434
|
e.street1,
|
|
1435
1435
|
e.city,
|
|
@@ -1437,26 +1437,26 @@ function an(e, r) {
|
|
|
1437
1437
|
e.postalCode
|
|
1438
1438
|
].join(" ");
|
|
1439
1439
|
let g = !1;
|
|
1440
|
-
async function
|
|
1441
|
-
var
|
|
1440
|
+
async function C() {
|
|
1441
|
+
var v, R;
|
|
1442
1442
|
try {
|
|
1443
|
-
const
|
|
1444
|
-
if (!
|
|
1445
|
-
g ||
|
|
1443
|
+
const W = `${Kr}/${encodeURIComponent(m)}.json?access_token=${a}&limit=1`, S = await fetch(W);
|
|
1444
|
+
if (!S.ok || g) {
|
|
1445
|
+
g || u("error");
|
|
1446
1446
|
return;
|
|
1447
1447
|
}
|
|
1448
|
-
const
|
|
1449
|
-
if (!
|
|
1450
|
-
g ||
|
|
1448
|
+
const w = (R = (v = (await S.json()).features) == null ? void 0 : v[0]) == null ? void 0 : R.center;
|
|
1449
|
+
if (!w || g) {
|
|
1450
|
+
g || u("error");
|
|
1451
1451
|
return;
|
|
1452
1452
|
}
|
|
1453
|
-
const [
|
|
1454
|
-
g ||
|
|
1453
|
+
const [re, T] = w, ae = rn(s, re, T), V = `${zr}/${ae}/${re},${T},${_}/${o}x${i}@2x?access_token=${a}&attribution=false&logo=false`;
|
|
1454
|
+
g || d(V);
|
|
1455
1455
|
} catch {
|
|
1456
|
-
g ||
|
|
1456
|
+
g || u("error");
|
|
1457
1457
|
}
|
|
1458
1458
|
}
|
|
1459
|
-
return
|
|
1459
|
+
return C(), () => {
|
|
1460
1460
|
g = !0;
|
|
1461
1461
|
};
|
|
1462
1462
|
}, [
|
|
@@ -1471,10 +1471,10 @@ function an(e, r) {
|
|
|
1471
1471
|
_
|
|
1472
1472
|
]), { url: f, status: h };
|
|
1473
1473
|
}
|
|
1474
|
-
const
|
|
1475
|
-
container:
|
|
1476
|
-
mapImage:
|
|
1477
|
-
mapImageLoaded:
|
|
1474
|
+
const an = "_container_1vap7_3", sn = "_mapImage_1vap7_13", on = "_mapImageLoaded_1vap7_22", Ve = {
|
|
1475
|
+
container: an,
|
|
1476
|
+
mapImage: sn,
|
|
1477
|
+
mapImageLoaded: on
|
|
1478
1478
|
};
|
|
1479
1479
|
function Ro({
|
|
1480
1480
|
address: e,
|
|
@@ -1485,54 +1485,54 @@ function Ro({
|
|
|
1485
1485
|
height: i,
|
|
1486
1486
|
zoom: _,
|
|
1487
1487
|
borderRadius: f,
|
|
1488
|
-
onLoad:
|
|
1488
|
+
onLoad: d,
|
|
1489
1489
|
onError: h
|
|
1490
1490
|
}) {
|
|
1491
|
-
const
|
|
1491
|
+
const u = Se(r), { url: m, status: g } = nn(e, {
|
|
1492
1492
|
mapboxAccessToken: a,
|
|
1493
1493
|
mapPinMarker: s,
|
|
1494
1494
|
width: o,
|
|
1495
1495
|
height: i,
|
|
1496
1496
|
zoom: _
|
|
1497
|
-
}), [
|
|
1498
|
-
|
|
1499
|
-
const
|
|
1500
|
-
|
|
1501
|
-
var
|
|
1502
|
-
g === "error" && ((
|
|
1497
|
+
}), [C, v] = E(!1), R = Z(d);
|
|
1498
|
+
R.current = d;
|
|
1499
|
+
const W = Z(h);
|
|
1500
|
+
W.current = h, le(() => {
|
|
1501
|
+
var w;
|
|
1502
|
+
g === "error" && ((w = W.current) == null || w.call(W, new Error("Failed to load map for address")));
|
|
1503
1503
|
}, [g]);
|
|
1504
|
-
const
|
|
1505
|
-
var
|
|
1506
|
-
|
|
1507
|
-
},
|
|
1508
|
-
...
|
|
1504
|
+
const S = () => {
|
|
1505
|
+
var w;
|
|
1506
|
+
v(!0), (w = R.current) == null || w.call(R);
|
|
1507
|
+
}, K = {
|
|
1508
|
+
...u,
|
|
1509
1509
|
...f ? { borderRadius: f } : {}
|
|
1510
1510
|
};
|
|
1511
|
-
return /* @__PURE__ */ t.jsx("div", { className: Ve.container, style:
|
|
1511
|
+
return /* @__PURE__ */ t.jsx("div", { className: Ve.container, style: K, children: m && /* @__PURE__ */ t.jsx(
|
|
1512
1512
|
"img",
|
|
1513
1513
|
{
|
|
1514
1514
|
src: m,
|
|
1515
1515
|
alt: "Map",
|
|
1516
|
-
className: `${Ve.mapImage} ${
|
|
1517
|
-
onLoad:
|
|
1516
|
+
className: `${Ve.mapImage} ${C ? Ve.mapImageLoaded : ""}`.trim(),
|
|
1517
|
+
onLoad: S
|
|
1518
1518
|
}
|
|
1519
1519
|
) });
|
|
1520
1520
|
}
|
|
1521
|
-
function
|
|
1521
|
+
function ln(e) {
|
|
1522
1522
|
return "field" in e;
|
|
1523
1523
|
}
|
|
1524
|
-
function
|
|
1524
|
+
function cn(e) {
|
|
1525
1525
|
return "and" in e;
|
|
1526
1526
|
}
|
|
1527
|
-
function
|
|
1527
|
+
function un(e) {
|
|
1528
1528
|
return "or" in e;
|
|
1529
1529
|
}
|
|
1530
1530
|
function Te(e, r) {
|
|
1531
|
-
if (
|
|
1531
|
+
if (cn(e))
|
|
1532
1532
|
return e.and.every((a) => Te(a, r));
|
|
1533
|
-
if (
|
|
1533
|
+
if (un(e))
|
|
1534
1534
|
return e.or.some((a) => Te(a, r));
|
|
1535
|
-
if (
|
|
1535
|
+
if (ln(e)) {
|
|
1536
1536
|
const a = r(e.field);
|
|
1537
1537
|
switch (e.op) {
|
|
1538
1538
|
case "eq":
|
|
@@ -1555,13 +1555,13 @@ function Te(e, r) {
|
|
|
1555
1555
|
}
|
|
1556
1556
|
return !1;
|
|
1557
1557
|
}
|
|
1558
|
-
function
|
|
1558
|
+
function jt(e, r) {
|
|
1559
1559
|
return e.questions.filter((a) => !a.showWhen || Te(a.showWhen, r));
|
|
1560
1560
|
}
|
|
1561
|
-
function
|
|
1561
|
+
function dn(e, r) {
|
|
1562
1562
|
return e.filter((a) => !a.showWhen || Te(a.showWhen, r));
|
|
1563
1563
|
}
|
|
1564
|
-
function
|
|
1564
|
+
function hn(e, r) {
|
|
1565
1565
|
const a = typeof r == "string" && r.trim() === "";
|
|
1566
1566
|
if (e.required) {
|
|
1567
1567
|
if (r == null || r === "" || a)
|
|
@@ -1581,9 +1581,9 @@ function fn(e, r) {
|
|
|
1581
1581
|
}
|
|
1582
1582
|
}
|
|
1583
1583
|
function ft(e, r) {
|
|
1584
|
-
const a = {}, s =
|
|
1584
|
+
const a = {}, s = jt(e, r);
|
|
1585
1585
|
for (const o of s) {
|
|
1586
|
-
const i = r(o.key), _ =
|
|
1586
|
+
const i = r(o.key), _ = hn(o, i);
|
|
1587
1587
|
_ && (a[o.key] = _);
|
|
1588
1588
|
}
|
|
1589
1589
|
return {
|
|
@@ -1591,16 +1591,16 @@ function ft(e, r) {
|
|
|
1591
1591
|
errors: a
|
|
1592
1592
|
};
|
|
1593
1593
|
}
|
|
1594
|
-
class
|
|
1594
|
+
class fn {
|
|
1595
1595
|
constructor(r, a) {
|
|
1596
|
-
this._validationErrors = {}, this._submitted = !1, this._listeners = /* @__PURE__ */ new Map(), this.getAnswer = (o) => this._answers[o], this._allPages = r, this._answers = a != null && a.initialAnswers ? { ...a.initialAnswers } : {}
|
|
1596
|
+
this._validationErrors = {}, this._submitted = !1, this._listeners = /* @__PURE__ */ new Map(), this.getAnswer = (o) => this._answers[o], this._allPages = r, this._answers = a != null && a.initialAnswers ? { ...a.initialAnswers } : {};
|
|
1597
1597
|
const s = this.visiblePages;
|
|
1598
1598
|
this._currentPageId = s.length > 0 ? s[0].id : "";
|
|
1599
1599
|
}
|
|
1600
1600
|
// ── Derived state (recomputed on access) ──────────────────────────────────
|
|
1601
1601
|
/** Pages visible given current answers (filtered by showWhen conditions). */
|
|
1602
1602
|
get visiblePages() {
|
|
1603
|
-
return
|
|
1603
|
+
return dn(this._allPages, this.getAnswer);
|
|
1604
1604
|
}
|
|
1605
1605
|
/** The current page, or undefined if no pages are visible. */
|
|
1606
1606
|
get currentPage() {
|
|
@@ -1637,9 +1637,6 @@ class mn {
|
|
|
1637
1637
|
get validationErrors() {
|
|
1638
1638
|
return { ...this._validationErrors };
|
|
1639
1639
|
}
|
|
1640
|
-
get market() {
|
|
1641
|
-
return this._market;
|
|
1642
|
-
}
|
|
1643
1640
|
// ── Actions ───────────────────────────────────────────────────────────────
|
|
1644
1641
|
/**
|
|
1645
1642
|
* Set an answer value. Clears any validation error for that field.
|
|
@@ -1731,7 +1728,7 @@ class mn {
|
|
|
1731
1728
|
*/
|
|
1732
1729
|
getVisibleQuestionsForCurrentPage() {
|
|
1733
1730
|
const r = this.currentPage;
|
|
1734
|
-
return r ?
|
|
1731
|
+
return r ? jt(r, this.getAnswer) : [];
|
|
1735
1732
|
}
|
|
1736
1733
|
// ── Events ────────────────────────────────────────────────────────────────
|
|
1737
1734
|
/**
|
|
@@ -1775,18 +1772,18 @@ class mn {
|
|
|
1775
1772
|
});
|
|
1776
1773
|
}
|
|
1777
1774
|
}
|
|
1778
|
-
const
|
|
1779
|
-
function
|
|
1780
|
-
if (typeof e == "string" && !
|
|
1775
|
+
const mn = /^[^\s@]+@[^\s@]+\.[^\s@]+$/;
|
|
1776
|
+
function Nt(e) {
|
|
1777
|
+
if (typeof e == "string" && !mn.test(e))
|
|
1781
1778
|
return "Please enter a valid email address";
|
|
1782
1779
|
}
|
|
1783
|
-
function
|
|
1780
|
+
function pn(e) {
|
|
1784
1781
|
if (typeof e != "string")
|
|
1785
1782
|
return;
|
|
1786
1783
|
if (e.replace(/\D/g, "").length < 10)
|
|
1787
1784
|
return "Please enter a valid 10-digit phone number";
|
|
1788
1785
|
}
|
|
1789
|
-
const
|
|
1786
|
+
const gn = {
|
|
1790
1787
|
id: "confirm-home-details",
|
|
1791
1788
|
title: "Confirm your home details",
|
|
1792
1789
|
subtitle: "This info is available to the public. You can edit these details if you've made any updates to your home.",
|
|
@@ -1978,7 +1975,7 @@ const _n = {
|
|
|
1978
1975
|
}
|
|
1979
1976
|
}
|
|
1980
1977
|
]
|
|
1981
|
-
},
|
|
1978
|
+
}, _n = {
|
|
1982
1979
|
id: "ownership",
|
|
1983
1980
|
title: "Are you the owner of this home?",
|
|
1984
1981
|
subtitle: "We have additional questions if you're an agent.",
|
|
@@ -1996,7 +1993,7 @@ const _n = {
|
|
|
1996
1993
|
]
|
|
1997
1994
|
}
|
|
1998
1995
|
]
|
|
1999
|
-
},
|
|
1996
|
+
}, bn = {
|
|
2000
1997
|
id: "sale-timeline",
|
|
2001
1998
|
title: "When do you need to sell your home?",
|
|
2002
1999
|
subtitle: "This won't affect your offer. We're here to help with any timeline.",
|
|
@@ -2017,13 +2014,13 @@ const _n = {
|
|
|
2017
2014
|
]
|
|
2018
2015
|
}
|
|
2019
2016
|
]
|
|
2020
|
-
},
|
|
2017
|
+
}, yn = [
|
|
2021
2018
|
"fixer_upper",
|
|
2022
2019
|
"dated",
|
|
2023
2020
|
"standard",
|
|
2024
2021
|
"high_end",
|
|
2025
2022
|
"luxury"
|
|
2026
|
-
],
|
|
2023
|
+
], vn = {
|
|
2027
2024
|
kitchen: {
|
|
2028
2025
|
fixer_upper: "Kitchen needs significant repairs",
|
|
2029
2026
|
dated: "Kitchen hasn't been updated recently",
|
|
@@ -2052,14 +2049,14 @@ const _n = {
|
|
|
2052
2049
|
high_end: "Exterior has high-quality upgrades",
|
|
2053
2050
|
luxury: "Exterior has elegant, top-tier finishes"
|
|
2054
2051
|
}
|
|
2055
|
-
},
|
|
2052
|
+
}, xn = {
|
|
2056
2053
|
fixer_upper: "Fixer upper",
|
|
2057
2054
|
dated: "Dated",
|
|
2058
2055
|
standard: "Standard",
|
|
2059
2056
|
high_end: "High-end",
|
|
2060
2057
|
luxury: "Luxury"
|
|
2061
2058
|
};
|
|
2062
|
-
function
|
|
2059
|
+
function De(e, r, a) {
|
|
2063
2060
|
return {
|
|
2064
2061
|
id: `${e}-condition`,
|
|
2065
2062
|
title: a,
|
|
@@ -2072,17 +2069,17 @@ function Ae(e, r, a) {
|
|
|
2072
2069
|
style: "image-card",
|
|
2073
2070
|
required: !0,
|
|
2074
2071
|
autoAdvance: !0,
|
|
2075
|
-
options:
|
|
2076
|
-
label:
|
|
2072
|
+
options: yn.map((s) => ({
|
|
2073
|
+
label: xn[s],
|
|
2077
2074
|
value: s,
|
|
2078
|
-
description:
|
|
2075
|
+
description: vn[e][s],
|
|
2079
2076
|
imageId: `${e}-${s}`
|
|
2080
2077
|
}))
|
|
2081
2078
|
}
|
|
2082
2079
|
]
|
|
2083
2080
|
};
|
|
2084
2081
|
}
|
|
2085
|
-
const
|
|
2082
|
+
const Cn = De("kitchen", "home.kitchen_seller_score", "How would you describe your kitchen?"), wn = De("bathroom", "home.bathroom_seller_score", "How would you describe your main bathroom?"), kn = De("living-room", "home.living_room_seller_score", "How would you describe your living room?"), jn = De("exterior", "home.exterior_seller_score", "How would you describe your home's exterior?"), Nn = {
|
|
2086
2083
|
id: "hoa",
|
|
2087
2084
|
title: "Is your home part of a homeowners association?",
|
|
2088
2085
|
subtitle: "This is often called an HOA. It's a group that helps maintain your community for a fee.",
|
|
@@ -2100,7 +2097,7 @@ const wn = Ae("kitchen", "home.kitchen_seller_score", "How would you describe yo
|
|
|
2100
2097
|
]
|
|
2101
2098
|
}
|
|
2102
2099
|
]
|
|
2103
|
-
},
|
|
2100
|
+
}, In = {
|
|
2104
2101
|
id: "hoa-type",
|
|
2105
2102
|
title: "Does your home belong to any of these types of communities?",
|
|
2106
2103
|
showWhen: { field: "home.hoa", op: "eq", value: "yes" },
|
|
@@ -2121,7 +2118,7 @@ const wn = Ae("kitchen", "home.kitchen_seller_score", "How would you describe yo
|
|
|
2121
2118
|
]
|
|
2122
2119
|
}
|
|
2123
2120
|
]
|
|
2124
|
-
},
|
|
2121
|
+
}, En = {
|
|
2125
2122
|
id: "hoa-guard",
|
|
2126
2123
|
title: "Is there a guard at the entrance?",
|
|
2127
2124
|
showWhen: {
|
|
@@ -2144,7 +2141,7 @@ const wn = Ae("kitchen", "home.kitchen_seller_score", "How would you describe yo
|
|
|
2144
2141
|
]
|
|
2145
2142
|
}
|
|
2146
2143
|
]
|
|
2147
|
-
},
|
|
2144
|
+
}, Sn = {
|
|
2148
2145
|
id: "hoa-fees",
|
|
2149
2146
|
title: "What are your monthly HOA fees?",
|
|
2150
2147
|
subtitle: "(Optional) This helps us better understand your property's monthly expenses.",
|
|
@@ -2159,7 +2156,7 @@ const wn = Ae("kitchen", "home.kitchen_seller_score", "How would you describe yo
|
|
|
2159
2156
|
min: 0
|
|
2160
2157
|
}
|
|
2161
2158
|
]
|
|
2162
|
-
},
|
|
2159
|
+
}, Pn = {
|
|
2163
2160
|
id: "eligibility-criteria",
|
|
2164
2161
|
title: "Do any of these apply to your home?",
|
|
2165
2162
|
subtitle: "Select all that apply. We keep an eye out for these things when making an offer.",
|
|
@@ -2214,7 +2211,7 @@ const wn = Ae("kitchen", "home.kitchen_seller_score", "How would you describe yo
|
|
|
2214
2211
|
]
|
|
2215
2212
|
}
|
|
2216
2213
|
]
|
|
2217
|
-
},
|
|
2214
|
+
}, Ln = {
|
|
2218
2215
|
id: "upgrades",
|
|
2219
2216
|
title: "Has your home had any upgrades?",
|
|
2220
2217
|
subtitle: "This includes renovations, remodels, or major improvements.",
|
|
@@ -2232,7 +2229,7 @@ const wn = Ae("kitchen", "home.kitchen_seller_score", "How would you describe yo
|
|
|
2232
2229
|
]
|
|
2233
2230
|
}
|
|
2234
2231
|
]
|
|
2235
|
-
},
|
|
2232
|
+
}, Tn = {
|
|
2236
2233
|
id: "homebuilder",
|
|
2237
2234
|
title: "Are you working with a homebuilder?",
|
|
2238
2235
|
subtitle: "We can work with them to line up your close dates.",
|
|
@@ -2269,7 +2266,7 @@ const wn = Ae("kitchen", "home.kitchen_seller_score", "How would you describe yo
|
|
|
2269
2266
|
placeholder: "Select or search..."
|
|
2270
2267
|
}
|
|
2271
2268
|
]
|
|
2272
|
-
},
|
|
2269
|
+
}, Dn = {
|
|
2273
2270
|
id: "homebuilder-details",
|
|
2274
2271
|
title: "Please tell us more about your homebuilder",
|
|
2275
2272
|
showWhen: {
|
|
@@ -2285,7 +2282,7 @@ const wn = Ae("kitchen", "home.kitchen_seller_score", "How would you describe yo
|
|
|
2285
2282
|
style: "email",
|
|
2286
2283
|
required: !1,
|
|
2287
2284
|
placeholder: "you@example.com",
|
|
2288
|
-
validate:
|
|
2285
|
+
validate: Nt
|
|
2289
2286
|
},
|
|
2290
2287
|
{
|
|
2291
2288
|
key: "seller.home_builder_community",
|
|
@@ -2296,7 +2293,7 @@ const wn = Ae("kitchen", "home.kitchen_seller_score", "How would you describe yo
|
|
|
2296
2293
|
placeholder: "Community name"
|
|
2297
2294
|
}
|
|
2298
2295
|
]
|
|
2299
|
-
},
|
|
2296
|
+
}, On = {
|
|
2300
2297
|
id: "contact-info",
|
|
2301
2298
|
title: "You're one step from your offer.",
|
|
2302
2299
|
subtitle: "Create a free account to see your offer. No commitment to sell — just your number, email, and name.",
|
|
@@ -2317,7 +2314,7 @@ const wn = Ae("kitchen", "home.kitchen_seller_score", "How would you describe yo
|
|
|
2317
2314
|
style: "email",
|
|
2318
2315
|
required: !0,
|
|
2319
2316
|
placeholder: "you@example.com",
|
|
2320
|
-
validate:
|
|
2317
|
+
validate: Nt
|
|
2321
2318
|
},
|
|
2322
2319
|
{
|
|
2323
2320
|
key: "seller.phone_number",
|
|
@@ -2326,7 +2323,7 @@ const wn = Ae("kitchen", "home.kitchen_seller_score", "How would you describe yo
|
|
|
2326
2323
|
style: "phone",
|
|
2327
2324
|
required: !0,
|
|
2328
2325
|
placeholder: "(555) 555-5555",
|
|
2329
|
-
validate:
|
|
2326
|
+
validate: pn
|
|
2330
2327
|
},
|
|
2331
2328
|
{
|
|
2332
2329
|
key: "seller.sms_opt_in",
|
|
@@ -2336,10 +2333,11 @@ const wn = Ae("kitchen", "home.kitchen_seller_score", "How would you describe yo
|
|
|
2336
2333
|
required: !1
|
|
2337
2334
|
}
|
|
2338
2335
|
]
|
|
2339
|
-
},
|
|
2336
|
+
}, Rn = [
|
|
2337
|
+
gn,
|
|
2340
2338
|
_n,
|
|
2341
2339
|
bn,
|
|
2342
|
-
|
|
2340
|
+
Cn,
|
|
2343
2341
|
wn,
|
|
2344
2342
|
kn,
|
|
2345
2343
|
jn,
|
|
@@ -2350,17 +2348,16 @@ const wn = Ae("kitchen", "home.kitchen_seller_score", "How would you describe yo
|
|
|
2350
2348
|
Pn,
|
|
2351
2349
|
Ln,
|
|
2352
2350
|
Tn,
|
|
2353
|
-
Dn,
|
|
2354
2351
|
An,
|
|
2355
|
-
|
|
2356
|
-
|
|
2352
|
+
Dn,
|
|
2353
|
+
On
|
|
2357
2354
|
];
|
|
2358
|
-
function
|
|
2359
|
-
return new
|
|
2355
|
+
function Bn(e) {
|
|
2356
|
+
return new fn(Rn, e);
|
|
2360
2357
|
}
|
|
2361
|
-
const
|
|
2362
|
-
function
|
|
2363
|
-
const e =
|
|
2358
|
+
const It = Ue(null);
|
|
2359
|
+
function fe() {
|
|
2360
|
+
const e = Ae(It);
|
|
2364
2361
|
if (!e)
|
|
2365
2362
|
throw new Error(
|
|
2366
2363
|
"useDtc must be used within a <DtcOnboardingFlow> component"
|
|
@@ -2368,121 +2365,116 @@ function me() {
|
|
|
2368
2365
|
return e;
|
|
2369
2366
|
}
|
|
2370
2367
|
const Mn = ({
|
|
2371
|
-
|
|
2372
|
-
|
|
2373
|
-
|
|
2374
|
-
|
|
2375
|
-
|
|
2376
|
-
|
|
2377
|
-
|
|
2378
|
-
|
|
2379
|
-
|
|
2380
|
-
children: h
|
|
2368
|
+
initialAnswers: e,
|
|
2369
|
+
smsConsentText: r,
|
|
2370
|
+
contactConsentText: a,
|
|
2371
|
+
onSubmit: s,
|
|
2372
|
+
onPageChange: o,
|
|
2373
|
+
onAnswerChange: i,
|
|
2374
|
+
onReady: _,
|
|
2375
|
+
onError: f,
|
|
2376
|
+
children: d
|
|
2381
2377
|
}) => {
|
|
2382
|
-
var
|
|
2383
|
-
const
|
|
2384
|
-
|
|
2385
|
-
const
|
|
2378
|
+
var Y;
|
|
2379
|
+
const h = Z(s);
|
|
2380
|
+
h.current = s;
|
|
2381
|
+
const u = Z(o);
|
|
2382
|
+
u.current = o;
|
|
2383
|
+
const m = Z(i);
|
|
2386
2384
|
m.current = i;
|
|
2387
|
-
const g =
|
|
2385
|
+
const g = Z(_);
|
|
2388
2386
|
g.current = _;
|
|
2389
|
-
const
|
|
2390
|
-
|
|
2391
|
-
const
|
|
2392
|
-
|
|
2393
|
-
|
|
2394
|
-
|
|
2395
|
-
),
|
|
2396
|
-
|
|
2397
|
-
|
|
2398
|
-
|
|
2399
|
-
const [q, j] = P(
|
|
2400
|
-
k.answers
|
|
2401
|
-
), [J, W] = P(
|
|
2402
|
-
((ie = k.currentPage) == null ? void 0 : ie.id) ?? ""
|
|
2403
|
-
), [ne, H] = P({}), [E, te] = P(
|
|
2404
|
-
k.visiblePages
|
|
2387
|
+
const C = Z(f);
|
|
2388
|
+
C.current = f;
|
|
2389
|
+
const [v] = E(
|
|
2390
|
+
() => Bn({ initialAnswers: e })
|
|
2391
|
+
), [R, W] = E(
|
|
2392
|
+
v.answers
|
|
2393
|
+
), [S, K] = E(
|
|
2394
|
+
((Y = v.currentPage) == null ? void 0 : Y.id) ?? ""
|
|
2395
|
+
), [w, re] = E({}), [T, ae] = E(
|
|
2396
|
+
v.visiblePages
|
|
2405
2397
|
);
|
|
2406
|
-
|
|
2407
|
-
var
|
|
2408
|
-
const
|
|
2409
|
-
|
|
2410
|
-
var
|
|
2411
|
-
|
|
2398
|
+
le(() => {
|
|
2399
|
+
var U;
|
|
2400
|
+
const O = [
|
|
2401
|
+
v.on("answerChange", (B) => {
|
|
2402
|
+
var y;
|
|
2403
|
+
W(v.answers), ae([...v.visiblePages]), B.type === "answerChange" && ((y = m.current) == null || y.call(m, B.key, B.value));
|
|
2412
2404
|
}),
|
|
2413
|
-
|
|
2414
|
-
var
|
|
2415
|
-
|
|
2405
|
+
v.on("pageChange", (B) => {
|
|
2406
|
+
var y;
|
|
2407
|
+
B.type === "pageChange" && (K(B.pageId), ae([...v.visiblePages]), re({}), (y = u.current) == null || y.call(u, B.pageIndex, B.pageId));
|
|
2416
2408
|
}),
|
|
2417
|
-
|
|
2418
|
-
|
|
2409
|
+
v.on("validationError", (B) => {
|
|
2410
|
+
B.type === "validationError" && re(B.errors);
|
|
2419
2411
|
}),
|
|
2420
|
-
|
|
2421
|
-
|
|
2412
|
+
v.on("submit", (B) => {
|
|
2413
|
+
B.type === "submit" && h.current(B.answers);
|
|
2422
2414
|
})
|
|
2423
2415
|
];
|
|
2424
|
-
return (
|
|
2425
|
-
|
|
2416
|
+
return (U = g.current) == null || U.call(g), () => {
|
|
2417
|
+
O.forEach((B) => B()), v.destroy();
|
|
2426
2418
|
};
|
|
2427
|
-
}, [
|
|
2428
|
-
const
|
|
2429
|
-
|
|
2430
|
-
|
|
2431
|
-
}, [
|
|
2432
|
-
const
|
|
2433
|
-
const
|
|
2434
|
-
return
|
|
2435
|
-
}, [
|
|
2419
|
+
}, [v]);
|
|
2420
|
+
const V = Z(e);
|
|
2421
|
+
le(() => {
|
|
2422
|
+
e && e !== V.current && (V.current = e, v.setAnswers(e));
|
|
2423
|
+
}, [e, v]);
|
|
2424
|
+
const P = Ie(() => {
|
|
2425
|
+
const O = T.findIndex((U) => U.id === S);
|
|
2426
|
+
return O >= 0 ? O : 0;
|
|
2427
|
+
}, [T, S]), te = T[P], G = Ie(() => S ? v.getVisibleQuestionsForCurrentPage() : [], [v, S, R]), ne = Ie(() => T.length <= 1 ? 0 : Math.min(
|
|
2436
2428
|
1,
|
|
2437
|
-
Math.max(0,
|
|
2438
|
-
), [
|
|
2429
|
+
Math.max(0, P / (T.length - 1))
|
|
2430
|
+
), [P, T.length]), se = Ie(
|
|
2439
2431
|
() => ({
|
|
2440
|
-
engine:
|
|
2441
|
-
currentPage:
|
|
2442
|
-
currentPageIndex:
|
|
2443
|
-
visiblePages:
|
|
2444
|
-
visibleQuestions:
|
|
2445
|
-
answers:
|
|
2446
|
-
validationErrors:
|
|
2447
|
-
progress:
|
|
2448
|
-
isFirstPage:
|
|
2449
|
-
contactConsentText:
|
|
2450
|
-
isLastPage:
|
|
2451
|
-
setAnswer: (
|
|
2452
|
-
getAnswer:
|
|
2432
|
+
engine: v,
|
|
2433
|
+
currentPage: te,
|
|
2434
|
+
currentPageIndex: P,
|
|
2435
|
+
visiblePages: T,
|
|
2436
|
+
visibleQuestions: G,
|
|
2437
|
+
answers: R,
|
|
2438
|
+
validationErrors: w,
|
|
2439
|
+
progress: ne,
|
|
2440
|
+
isFirstPage: P === 0,
|
|
2441
|
+
contactConsentText: a,
|
|
2442
|
+
isLastPage: T.length > 0 && P === T.length - 1,
|
|
2443
|
+
setAnswer: (O, U) => v.setAnswer(O, U),
|
|
2444
|
+
getAnswer: v.getAnswer,
|
|
2453
2445
|
goToNext: () => {
|
|
2454
|
-
var
|
|
2455
|
-
const
|
|
2456
|
-
if (!
|
|
2446
|
+
var U;
|
|
2447
|
+
const O = v.goToNext();
|
|
2448
|
+
if (!O.valid)
|
|
2457
2449
|
try {
|
|
2458
|
-
(
|
|
2459
|
-
|
|
2450
|
+
(U = C.current) == null || U.call(
|
|
2451
|
+
C,
|
|
2460
2452
|
new Error(
|
|
2461
|
-
`Validation failed: ${Object.values(
|
|
2453
|
+
`Validation failed: ${Object.values(O.errors).join(", ")}`
|
|
2462
2454
|
)
|
|
2463
2455
|
);
|
|
2464
|
-
} catch (
|
|
2465
|
-
console.error("[DtcOnboardingFlow] onError callback threw:",
|
|
2456
|
+
} catch (B) {
|
|
2457
|
+
console.error("[DtcOnboardingFlow] onError callback threw:", B);
|
|
2466
2458
|
}
|
|
2467
2459
|
},
|
|
2468
|
-
goToPrev: () =>
|
|
2469
|
-
smsConsentText:
|
|
2460
|
+
goToPrev: () => v.goToPrev(),
|
|
2461
|
+
smsConsentText: r
|
|
2470
2462
|
}),
|
|
2471
2463
|
[
|
|
2472
|
-
|
|
2473
|
-
|
|
2474
|
-
|
|
2475
|
-
|
|
2476
|
-
|
|
2477
|
-
|
|
2464
|
+
v,
|
|
2465
|
+
te,
|
|
2466
|
+
P,
|
|
2467
|
+
T,
|
|
2468
|
+
G,
|
|
2469
|
+
R,
|
|
2470
|
+
w,
|
|
2478
2471
|
ne,
|
|
2479
|
-
|
|
2480
|
-
a
|
|
2481
|
-
s
|
|
2472
|
+
r,
|
|
2473
|
+
a
|
|
2482
2474
|
]
|
|
2483
2475
|
);
|
|
2484
|
-
return /* @__PURE__ */ t.jsx(
|
|
2485
|
-
}, $n = "_container_uharh_7", Fn = "_header_uharh_20", Wn = "_headerLogos_uharh_30", Hn = "_headerPartnerLogo_uharh_36", Vn = "_headerOpendoorLogo_uharh_42", qn = "_headerCloseButton_uharh_46", Un = "_layout_uharh_71", Gn = "_layoutScrollable_uharh_78", Yn = "_addressBar_uharh_94", Zn = "_addressIcon_uharh_102", Kn = "_addressText_uharh_106", zn = "_contentSplit_uharh_112", Jn = "_contentLeft_uharh_126", Xn = "_contentRight_uharh_132", Qn = "_pageTitle_uharh_148", ea = "_pageSubtitle_uharh_156", ta = "_pageContent_uharh_165", ra = "_navigation_uharh_173", na = "_navigationButtons_uharh_187", aa = "_backButton_uharh_193", sa = "_nextButton_uharh_216", oa = "_progressBar_uharh_242", ia = "_progressBarFill_uharh_249", la = "_radioCardGroup_uharh_257", ca = "_radioCard_uharh_257", ua = "_radioCardSelected_uharh_289", da = "_radioCardLabel_uharh_294", ha = "_radioCardDescription_uharh_300", fa = "_imageCardGroup_uharh_307", ma = "_imageCard_uharh_307", pa = "_imageCardSelected_uharh_339", ga = "_imageCardPhoto_uharh_344", _a = "_imageCardLabel_uharh_351", ba = "_imageCardDescription_uharh_358", ya = "_fieldGroup_uharh_367", va = "_fieldLabel_uharh_373", xa = "_fieldDescription_uharh_380", Ca = "_fieldSelect_uharh_387", wa = "_fieldSelectError_uharh_413", ka = "_fieldInputWrapper_uharh_417", ja = "_fieldInput_uharh_417", Na = "_fieldInputError_uharh_455", Ia = "_fieldSuffix_uharh_459", Ea = "_fieldError_uharh_470", Sa = "_checkboxCardGroup_uharh_479", Pa = "_checkboxCard_uharh_479", La = "_checkboxCardSelected_uharh_511", Ta = "_checkboxCardContent_uharh_516",
|
|
2476
|
+
return /* @__PURE__ */ t.jsx(It.Provider, { value: se, children: d });
|
|
2477
|
+
}, $n = "_container_uharh_7", Fn = "_header_uharh_20", Wn = "_headerLogos_uharh_30", Hn = "_headerPartnerLogo_uharh_36", Vn = "_headerOpendoorLogo_uharh_42", qn = "_headerCloseButton_uharh_46", Un = "_layout_uharh_71", Gn = "_layoutScrollable_uharh_78", Yn = "_addressBar_uharh_94", Zn = "_addressIcon_uharh_102", Kn = "_addressText_uharh_106", zn = "_contentSplit_uharh_112", Jn = "_contentLeft_uharh_126", Xn = "_contentRight_uharh_132", Qn = "_pageTitle_uharh_148", ea = "_pageSubtitle_uharh_156", ta = "_pageContent_uharh_165", ra = "_navigation_uharh_173", na = "_navigationButtons_uharh_187", aa = "_backButton_uharh_193", sa = "_nextButton_uharh_216", oa = "_progressBar_uharh_242", ia = "_progressBarFill_uharh_249", la = "_radioCardGroup_uharh_257", ca = "_radioCard_uharh_257", ua = "_radioCardSelected_uharh_289", da = "_radioCardLabel_uharh_294", ha = "_radioCardDescription_uharh_300", fa = "_imageCardGroup_uharh_307", ma = "_imageCard_uharh_307", pa = "_imageCardSelected_uharh_339", ga = "_imageCardPhoto_uharh_344", _a = "_imageCardLabel_uharh_351", ba = "_imageCardDescription_uharh_358", ya = "_fieldGroup_uharh_367", va = "_fieldLabel_uharh_373", xa = "_fieldDescription_uharh_380", Ca = "_fieldSelect_uharh_387", wa = "_fieldSelectError_uharh_413", ka = "_fieldInputWrapper_uharh_417", ja = "_fieldInput_uharh_417", Na = "_fieldInputError_uharh_455", Ia = "_fieldSuffix_uharh_459", Ea = "_fieldError_uharh_470", Sa = "_checkboxCardGroup_uharh_479", Pa = "_checkboxCard_uharh_479", La = "_checkboxCardSelected_uharh_511", Ta = "_checkboxCardContent_uharh_516", Aa = "_checkboxCardLabel_uharh_523", Da = "_checkboxCardHelper_uharh_529", Oa = "_checkboxIndicator_uharh_534", Ra = "_checkboxIndicatorChecked_uharh_546", Ba = "_currencyWrapper_uharh_554", Ma = "_currencyPrefix_uharh_560", $a = "_currencyInput_uharh_569", Fa = "_consentText_uharh_589", Wa = "_consentLink_uharh_597", Ha = "_ctaButton_uharh_602", Va = "_toggleGroup_uharh_634", qa = "_toggleLabel_uharh_638", Ua = "_toggleCheckbox_uharh_646", Ga = "_toggleText_uharh_655", Ya = "_searchableDropdown_uharh_663", Za = "_searchableDropdownToggle_uharh_673", Ka = "_searchableDropdownList_uharh_686", za = "_searchableDropdownOption_uharh_695", Ja = "_searchableDropdownOptionSelected_uharh_713", Xa = "_searchableDropdownOptionHighlighted_uharh_718", Qa = "_searchableDropdownEmpty_uharh_722", l = {
|
|
2486
2478
|
container: $n,
|
|
2487
2479
|
header: Fn,
|
|
2488
2480
|
headerLogos: Wn,
|
|
@@ -2531,8 +2523,8 @@ const Mn = ({
|
|
|
2531
2523
|
checkboxCard: Pa,
|
|
2532
2524
|
checkboxCardSelected: La,
|
|
2533
2525
|
checkboxCardContent: Ta,
|
|
2534
|
-
checkboxCardLabel:
|
|
2535
|
-
checkboxCardHelper:
|
|
2526
|
+
checkboxCardLabel: Aa,
|
|
2527
|
+
checkboxCardHelper: Da,
|
|
2536
2528
|
checkboxIndicator: Oa,
|
|
2537
2529
|
checkboxIndicatorChecked: Ra,
|
|
2538
2530
|
currencyWrapper: Ba,
|
|
@@ -2632,7 +2624,7 @@ const Mn = ({
|
|
|
2632
2624
|
}
|
|
2633
2625
|
);
|
|
2634
2626
|
}, ns = () => {
|
|
2635
|
-
const { isFirstPage: e, currentPage: r, progress: a, goToNext: s, goToPrev: o } =
|
|
2627
|
+
const { isFirstPage: e, currentPage: r, progress: a, goToNext: s, goToPrev: o } = fe();
|
|
2636
2628
|
if ((r == null ? void 0 : r.id) === "contact-info") return null;
|
|
2637
2629
|
const i = (r == null ? void 0 : r.submitLabel) ?? "Next";
|
|
2638
2630
|
return /* @__PURE__ */ t.jsxs("nav", { className: l.navigation, "aria-label": "Page navigation", children: [
|
|
@@ -2665,28 +2657,28 @@ const Mn = ({
|
|
|
2665
2657
|
] })
|
|
2666
2658
|
] });
|
|
2667
2659
|
}, as = ({ question: e }) => {
|
|
2668
|
-
var
|
|
2669
|
-
const { getAnswer: r, setAnswer: a, goToNext: s, validationErrors: o } =
|
|
2670
|
-
|
|
2660
|
+
var u;
|
|
2661
|
+
const { getAnswer: r, setAnswer: a, goToNext: s, validationErrors: o } = fe(), i = r(e.key), _ = o[e.key], f = Z(null);
|
|
2662
|
+
le(() => () => {
|
|
2671
2663
|
f.current && clearTimeout(f.current);
|
|
2672
2664
|
}, []);
|
|
2673
|
-
const
|
|
2665
|
+
const d = Ee(
|
|
2674
2666
|
(m) => {
|
|
2675
2667
|
a(e.key, m), e.autoAdvance && (f.current && clearTimeout(f.current), f.current = setTimeout(() => s(), 150));
|
|
2676
2668
|
},
|
|
2677
2669
|
[e.key, e.autoAdvance, a, s]
|
|
2678
2670
|
), h = Ee(
|
|
2679
2671
|
(m, g) => {
|
|
2680
|
-
var
|
|
2681
|
-
const
|
|
2682
|
-
if (!
|
|
2683
|
-
let
|
|
2684
|
-
if (m.key === "ArrowDown" || m.key === "ArrowRight" ? (m.preventDefault(),
|
|
2685
|
-
const
|
|
2686
|
-
(
|
|
2672
|
+
var R, W;
|
|
2673
|
+
const C = e.options;
|
|
2674
|
+
if (!C) return;
|
|
2675
|
+
let v = null;
|
|
2676
|
+
if (m.key === "ArrowDown" || m.key === "ArrowRight" ? (m.preventDefault(), v = (g + 1) % C.length) : (m.key === "ArrowUp" || m.key === "ArrowLeft") && (m.preventDefault(), v = (g - 1 + C.length) % C.length), v !== null) {
|
|
2677
|
+
const S = (R = m.currentTarget.closest('[role="radiogroup"]')) == null ? void 0 : R.querySelectorAll('[role="radio"]');
|
|
2678
|
+
(W = S == null ? void 0 : S[v]) == null || W.focus(), d(C[v].value);
|
|
2687
2679
|
}
|
|
2688
2680
|
},
|
|
2689
|
-
[e.options,
|
|
2681
|
+
[e.options, d]
|
|
2690
2682
|
);
|
|
2691
2683
|
return /* @__PURE__ */ t.jsxs(
|
|
2692
2684
|
"div",
|
|
@@ -2695,18 +2687,18 @@ const Mn = ({
|
|
|
2695
2687
|
role: "radiogroup",
|
|
2696
2688
|
"aria-label": e.label,
|
|
2697
2689
|
children: [
|
|
2698
|
-
(
|
|
2699
|
-
const
|
|
2690
|
+
(u = e.options) == null ? void 0 : u.map((m, g) => {
|
|
2691
|
+
const C = i === m.value;
|
|
2700
2692
|
return /* @__PURE__ */ t.jsxs(
|
|
2701
2693
|
"button",
|
|
2702
2694
|
{
|
|
2703
2695
|
type: "button",
|
|
2704
2696
|
role: "radio",
|
|
2705
|
-
"aria-checked":
|
|
2706
|
-
tabIndex:
|
|
2707
|
-
className: `${l.radioCard} ${
|
|
2708
|
-
onClick: () =>
|
|
2709
|
-
onKeyDown: (
|
|
2697
|
+
"aria-checked": C,
|
|
2698
|
+
tabIndex: C || g === 0 && !i ? 0 : -1,
|
|
2699
|
+
className: `${l.radioCard} ${C ? l.radioCardSelected : ""}`,
|
|
2700
|
+
onClick: () => d(m.value),
|
|
2701
|
+
onKeyDown: (v) => h(v, g),
|
|
2710
2702
|
children: [
|
|
2711
2703
|
/* @__PURE__ */ t.jsx("span", { className: l.radioCardLabel, children: m.label }),
|
|
2712
2704
|
m.description && /* @__PURE__ */ t.jsx("span", { className: l.radioCardDescription, children: m.description })
|
|
@@ -2750,13 +2742,13 @@ const is = {
|
|
|
2750
2742
|
"exterior-luxury": ee("2023-04-1681773220487-59852.png")
|
|
2751
2743
|
}, ls = ({ question: e }) => {
|
|
2752
2744
|
var h;
|
|
2753
|
-
const { getAnswer: r, setAnswer: a, goToNext: s, validationErrors: o } =
|
|
2754
|
-
|
|
2745
|
+
const { getAnswer: r, setAnswer: a, goToNext: s, validationErrors: o } = fe(), i = r(e.key), _ = o[e.key], f = Z(null);
|
|
2746
|
+
le(() => () => {
|
|
2755
2747
|
f.current && clearTimeout(f.current);
|
|
2756
2748
|
}, []);
|
|
2757
|
-
const
|
|
2758
|
-
(
|
|
2759
|
-
a(e.key,
|
|
2749
|
+
const d = Ee(
|
|
2750
|
+
(u) => {
|
|
2751
|
+
a(e.key, u), e.autoAdvance && (f.current && clearTimeout(f.current), f.current = setTimeout(() => s(), 300));
|
|
2760
2752
|
},
|
|
2761
2753
|
[e.key, e.autoAdvance, a, s]
|
|
2762
2754
|
);
|
|
@@ -2767,8 +2759,8 @@ const is = {
|
|
|
2767
2759
|
role: "radiogroup",
|
|
2768
2760
|
"aria-label": e.label,
|
|
2769
2761
|
children: [
|
|
2770
|
-
(h = e.options) == null ? void 0 : h.map((
|
|
2771
|
-
const m = i ===
|
|
2762
|
+
(h = e.options) == null ? void 0 : h.map((u) => {
|
|
2763
|
+
const m = i === u.value, g = u.imageId ? is[u.imageId] : void 0;
|
|
2772
2764
|
return /* @__PURE__ */ t.jsxs(
|
|
2773
2765
|
"button",
|
|
2774
2766
|
{
|
|
@@ -2776,22 +2768,22 @@ const is = {
|
|
|
2776
2768
|
role: "radio",
|
|
2777
2769
|
"aria-checked": m,
|
|
2778
2770
|
className: `${l.imageCard} ${m ? l.imageCardSelected : ""}`,
|
|
2779
|
-
onClick: () => u
|
|
2771
|
+
onClick: () => d(u.value),
|
|
2780
2772
|
children: [
|
|
2781
2773
|
g && /* @__PURE__ */ t.jsx(
|
|
2782
2774
|
"img",
|
|
2783
2775
|
{
|
|
2784
2776
|
src: g,
|
|
2785
|
-
alt:
|
|
2777
|
+
alt: u.label,
|
|
2786
2778
|
className: l.imageCardPhoto,
|
|
2787
2779
|
loading: "lazy"
|
|
2788
2780
|
}
|
|
2789
2781
|
),
|
|
2790
|
-
/* @__PURE__ */ t.jsx("span", { className: l.imageCardLabel, children:
|
|
2791
|
-
|
|
2782
|
+
/* @__PURE__ */ t.jsx("span", { className: l.imageCardLabel, children: u.label }),
|
|
2783
|
+
u.description && /* @__PURE__ */ t.jsx("span", { className: l.imageCardDescription, children: u.description })
|
|
2792
2784
|
]
|
|
2793
2785
|
},
|
|
2794
|
-
String(
|
|
2786
|
+
String(u.value)
|
|
2795
2787
|
);
|
|
2796
2788
|
}),
|
|
2797
2789
|
_ && /* @__PURE__ */ t.jsx("p", { className: l.fieldError, children: _ })
|
|
@@ -2802,24 +2794,24 @@ const is = {
|
|
|
2802
2794
|
question: e
|
|
2803
2795
|
}) => {
|
|
2804
2796
|
var f;
|
|
2805
|
-
const { getAnswer: r, setAnswer: a, validationErrors: s } =
|
|
2797
|
+
const { getAnswer: r, setAnswer: a, validationErrors: s } = fe(), o = r(e.key) ?? [], i = s[e.key], _ = (d) => {
|
|
2806
2798
|
var m;
|
|
2807
|
-
const h = (m = e.options) == null ? void 0 : m.find((g) => g.value ===
|
|
2799
|
+
const h = (m = e.options) == null ? void 0 : m.find((g) => g.value === d);
|
|
2808
2800
|
if (h != null && h.exclusive) {
|
|
2809
|
-
a(e.key, [
|
|
2801
|
+
a(e.key, [d]);
|
|
2810
2802
|
return;
|
|
2811
2803
|
}
|
|
2812
|
-
const
|
|
2804
|
+
const u = o.filter(
|
|
2813
2805
|
(g) => {
|
|
2814
|
-
var
|
|
2815
|
-
return !((
|
|
2806
|
+
var C, v;
|
|
2807
|
+
return !((v = (C = e.options) == null ? void 0 : C.find((R) => R.value === g)) != null && v.exclusive);
|
|
2816
2808
|
}
|
|
2817
2809
|
);
|
|
2818
|
-
if (
|
|
2819
|
-
const g =
|
|
2810
|
+
if (u.includes(d)) {
|
|
2811
|
+
const g = u.filter((C) => C !== d);
|
|
2820
2812
|
a(e.key, g.length > 0 ? g : void 0);
|
|
2821
2813
|
} else
|
|
2822
|
-
a(e.key, [...
|
|
2814
|
+
a(e.key, [...u, d]);
|
|
2823
2815
|
};
|
|
2824
2816
|
return /* @__PURE__ */ t.jsxs(
|
|
2825
2817
|
"div",
|
|
@@ -2828,8 +2820,8 @@ const is = {
|
|
|
2828
2820
|
role: "group",
|
|
2829
2821
|
"aria-label": e.label,
|
|
2830
2822
|
children: [
|
|
2831
|
-
(f = e.options) == null ? void 0 : f.map((
|
|
2832
|
-
const h = o.includes(String(
|
|
2823
|
+
(f = e.options) == null ? void 0 : f.map((d) => {
|
|
2824
|
+
const h = o.includes(String(d.value));
|
|
2833
2825
|
return /* @__PURE__ */ t.jsxs(
|
|
2834
2826
|
"button",
|
|
2835
2827
|
{
|
|
@@ -2837,11 +2829,11 @@ const is = {
|
|
|
2837
2829
|
role: "checkbox",
|
|
2838
2830
|
"aria-checked": h,
|
|
2839
2831
|
className: `${l.checkboxCard} ${h ? l.checkboxCardSelected : ""}`,
|
|
2840
|
-
onClick: () => _(String(
|
|
2832
|
+
onClick: () => _(String(d.value)),
|
|
2841
2833
|
children: [
|
|
2842
2834
|
/* @__PURE__ */ t.jsxs("span", { className: l.checkboxCardContent, children: [
|
|
2843
|
-
/* @__PURE__ */ t.jsx("span", { className: l.checkboxCardLabel, children:
|
|
2844
|
-
|
|
2835
|
+
/* @__PURE__ */ t.jsx("span", { className: l.checkboxCardLabel, children: d.label }),
|
|
2836
|
+
d.helperText && /* @__PURE__ */ t.jsx("span", { className: l.checkboxCardHelper, children: d.helperText })
|
|
2845
2837
|
] }),
|
|
2846
2838
|
/* @__PURE__ */ t.jsx(
|
|
2847
2839
|
"span",
|
|
@@ -2861,7 +2853,7 @@ const is = {
|
|
|
2861
2853
|
)
|
|
2862
2854
|
]
|
|
2863
2855
|
},
|
|
2864
|
-
String(
|
|
2856
|
+
String(d.value)
|
|
2865
2857
|
);
|
|
2866
2858
|
}),
|
|
2867
2859
|
i && /* @__PURE__ */ t.jsx("p", { className: l.fieldError, children: i })
|
|
@@ -2870,8 +2862,8 @@ const is = {
|
|
|
2870
2862
|
);
|
|
2871
2863
|
}, us = ({ question: e }) => {
|
|
2872
2864
|
var f;
|
|
2873
|
-
const { getAnswer: r, setAnswer: a, validationErrors: s } =
|
|
2874
|
-
const h =
|
|
2865
|
+
const { getAnswer: r, setAnswer: a, validationErrors: s } = fe(), o = r(e.key), i = s[e.key], _ = (d) => {
|
|
2866
|
+
const h = d.target.value;
|
|
2875
2867
|
e.type === "number" && h !== "" ? a(e.key, Number(h)) : a(e.key, h || void 0);
|
|
2876
2868
|
};
|
|
2877
2869
|
return /* @__PURE__ */ t.jsxs("div", { className: l.fieldGroup, children: [
|
|
@@ -2886,17 +2878,17 @@ const is = {
|
|
|
2886
2878
|
onChange: _,
|
|
2887
2879
|
children: [
|
|
2888
2880
|
/* @__PURE__ */ t.jsx("option", { value: "", children: e.placeholder || "Select..." }),
|
|
2889
|
-
(f = e.options) == null ? void 0 : f.map((
|
|
2881
|
+
(f = e.options) == null ? void 0 : f.map((d) => /* @__PURE__ */ t.jsx("option", { value: String(d.value), children: d.label }, String(d.value)))
|
|
2890
2882
|
]
|
|
2891
2883
|
}
|
|
2892
2884
|
),
|
|
2893
2885
|
i && /* @__PURE__ */ t.jsx("p", { className: l.fieldError, children: i })
|
|
2894
2886
|
] });
|
|
2895
2887
|
}, ds = ({ question: e }) => {
|
|
2896
|
-
const { getAnswer: r, setAnswer: a, validationErrors: s } =
|
|
2897
|
-
const h =
|
|
2888
|
+
const { getAnswer: r, setAnswer: a, validationErrors: s } = fe(), o = r(e.key), i = s[e.key], _ = (d) => {
|
|
2889
|
+
const h = d.target.value;
|
|
2898
2890
|
if (e.type === "number") {
|
|
2899
|
-
const
|
|
2891
|
+
const u = h.replace(/[^0-9.]/g, ""), m = u === "" ? void 0 : Number(u), g = m !== void 0 && isNaN(m) ? void 0 : m;
|
|
2900
2892
|
a(e.key, g);
|
|
2901
2893
|
} else
|
|
2902
2894
|
a(e.key, h || void 0);
|
|
@@ -2922,9 +2914,9 @@ const is = {
|
|
|
2922
2914
|
i && /* @__PURE__ */ t.jsx("p", { className: l.fieldError, children: i })
|
|
2923
2915
|
] });
|
|
2924
2916
|
}, hs = ({ question: e }) => {
|
|
2925
|
-
const { getAnswer: r, setAnswer: a, validationErrors: s } =
|
|
2926
|
-
const h =
|
|
2927
|
-
a(e.key,
|
|
2917
|
+
const { getAnswer: r, setAnswer: a, validationErrors: s } = fe(), o = r(e.key), i = s[e.key], _ = (d) => {
|
|
2918
|
+
const h = d.target.value.replace(/[^0-9]/g, ""), u = h === "" ? void 0 : Number(h);
|
|
2919
|
+
a(e.key, u !== void 0 && isNaN(u) ? void 0 : u);
|
|
2928
2920
|
}, f = o != null ? String(o) : "";
|
|
2929
2921
|
return /* @__PURE__ */ t.jsxs("div", { className: l.fieldGroup, children: [
|
|
2930
2922
|
/* @__PURE__ */ t.jsx("label", { className: l.fieldLabel, htmlFor: e.key, children: e.label }),
|
|
@@ -2951,7 +2943,7 @@ function fs(e) {
|
|
|
2951
2943
|
return r.length <= 3 ? r : r.length <= 6 ? `(${r.slice(0, 3)}) ${r.slice(3)}` : `(${r.slice(0, 3)}) ${r.slice(3, 6)}-${r.slice(6)}`;
|
|
2952
2944
|
}
|
|
2953
2945
|
const ms = ({ question: e }) => {
|
|
2954
|
-
const { getAnswer: r, setAnswer: a, validationErrors: s } =
|
|
2946
|
+
const { getAnswer: r, setAnswer: a, validationErrors: s } = fe(), o = r(e.key) ?? "", i = s[e.key], _ = (f) => {
|
|
2955
2947
|
const h = f.target.value.replace(/\D/g, "").slice(0, 10);
|
|
2956
2948
|
a(e.key, h || void 0);
|
|
2957
2949
|
};
|
|
@@ -2971,7 +2963,7 @@ const ms = ({ question: e }) => {
|
|
|
2971
2963
|
i && /* @__PURE__ */ t.jsx("p", { className: l.fieldError, children: i })
|
|
2972
2964
|
] });
|
|
2973
2965
|
}, ps = ({ question: e }) => {
|
|
2974
|
-
const { getAnswer: r, setAnswer: a, smsConsentText: s } =
|
|
2966
|
+
const { getAnswer: r, setAnswer: a, smsConsentText: s } = fe(), o = r(e.key);
|
|
2975
2967
|
let i = e.label;
|
|
2976
2968
|
return e.key === "seller.sms_opt_in" && s && (i = s), /* @__PURE__ */ t.jsx("div", { className: l.toggleGroup, children: /* @__PURE__ */ t.jsxs("label", { className: l.toggleLabel, children: [
|
|
2977
2969
|
/* @__PURE__ */ t.jsx(
|
|
@@ -2985,7 +2977,7 @@ const ms = ({ question: e }) => {
|
|
|
2985
2977
|
),
|
|
2986
2978
|
/* @__PURE__ */ t.jsx("span", { className: l.toggleText, children: i })
|
|
2987
2979
|
] }) });
|
|
2988
|
-
},
|
|
2980
|
+
}, mt = 4, Le = 8, gs = 240, _s = 80;
|
|
2989
2981
|
function bs(e) {
|
|
2990
2982
|
const r = {};
|
|
2991
2983
|
for (let a = e; a; a = a.parentElement) {
|
|
@@ -2998,128 +2990,128 @@ function bs(e) {
|
|
|
2998
2990
|
return r;
|
|
2999
2991
|
}
|
|
3000
2992
|
const ys = ({ question: e }) => {
|
|
3001
|
-
var
|
|
3002
|
-
const { getAnswer: r, setAnswer: a, validationErrors: s } =
|
|
3003
|
-
|
|
2993
|
+
var B;
|
|
2994
|
+
const { getAnswer: r, setAnswer: a, validationErrors: s } = fe(), o = r(e.key), i = s[e.key], _ = `${e.key}-combobox`, [f, d] = E(""), [h, u] = E(!1), [m, g] = E([]), [C, v] = E(!1), R = Z(null), W = Z(null), S = Z(null), [K, w] = E(null), [re, T] = E({}), ae = Ae(Ye);
|
|
2995
|
+
le(() => {
|
|
3004
2996
|
let y = !1;
|
|
3005
|
-
return e.dataSource === "homebuilders" &&
|
|
2997
|
+
return e.dataSource === "homebuilders" && ae ? (v(!0), ae.getHomebuilders().then((I) => {
|
|
3006
2998
|
y || g(
|
|
3007
|
-
|
|
3008
|
-
label:
|
|
3009
|
-
value:
|
|
2999
|
+
I.homebuilders.map((j) => ({
|
|
3000
|
+
label: j.displayName,
|
|
3001
|
+
value: j.identifier
|
|
3010
3002
|
}))
|
|
3011
3003
|
);
|
|
3012
3004
|
}).catch(() => {
|
|
3013
3005
|
y || (e.options ? g(
|
|
3014
|
-
e.options.map((
|
|
3015
|
-
label:
|
|
3016
|
-
value: String(
|
|
3006
|
+
e.options.map((I) => ({
|
|
3007
|
+
label: I.label,
|
|
3008
|
+
value: String(I.value)
|
|
3017
3009
|
}))
|
|
3018
3010
|
) : g([]));
|
|
3019
3011
|
}).finally(() => {
|
|
3020
|
-
y ||
|
|
3012
|
+
y || v(!1);
|
|
3021
3013
|
})) : e.options ? g(
|
|
3022
|
-
e.options.map((
|
|
3023
|
-
label:
|
|
3024
|
-
value: String(
|
|
3014
|
+
e.options.map((I) => ({
|
|
3015
|
+
label: I.label,
|
|
3016
|
+
value: String(I.value)
|
|
3025
3017
|
}))
|
|
3026
3018
|
) : g([]), () => {
|
|
3027
3019
|
y = !0;
|
|
3028
3020
|
};
|
|
3029
|
-
}, [e.dataSource, e.options,
|
|
3030
|
-
const
|
|
3031
|
-
const y =
|
|
3021
|
+
}, [e.dataSource, e.options, ae]);
|
|
3022
|
+
const V = Ee(() => {
|
|
3023
|
+
const y = W.current;
|
|
3032
3024
|
if (!y) return;
|
|
3033
|
-
const
|
|
3025
|
+
const I = y.getBoundingClientRect(), j = window.visualViewport, me = (j == null ? void 0 : j.height) ?? window.innerHeight, ce = (j == null ? void 0 : j.width) ?? window.innerWidth, pe = (j == null ? void 0 : j.offsetTop) ?? 0, de = (j == null ? void 0 : j.offsetLeft) ?? 0, M = pe + me - I.bottom - mt - Le, q = Math.max(
|
|
3034
3026
|
_s,
|
|
3035
|
-
Math.min(gs,
|
|
3036
|
-
),
|
|
3037
|
-
|
|
3038
|
-
top:
|
|
3027
|
+
Math.min(gs, M)
|
|
3028
|
+
), $ = Math.min(I.width, ce - Le * 2), oe = de + Le, he = de + ce - $ - Le, ge = Math.max(oe, Math.min(I.left, he));
|
|
3029
|
+
w({
|
|
3030
|
+
top: I.bottom + window.scrollY + mt,
|
|
3039
3031
|
left: ge + window.scrollX,
|
|
3040
|
-
width:
|
|
3041
|
-
maxHeight:
|
|
3032
|
+
width: $,
|
|
3033
|
+
maxHeight: q
|
|
3042
3034
|
});
|
|
3043
3035
|
}, []);
|
|
3044
|
-
|
|
3036
|
+
qt(() => {
|
|
3045
3037
|
if (!h) {
|
|
3046
|
-
|
|
3038
|
+
w(null);
|
|
3047
3039
|
return;
|
|
3048
3040
|
}
|
|
3049
|
-
|
|
3050
|
-
const y = () =>
|
|
3041
|
+
W.current && T(bs(W.current)), V();
|
|
3042
|
+
const y = () => V();
|
|
3051
3043
|
window.addEventListener("scroll", y, !0), window.addEventListener("resize", y);
|
|
3052
|
-
const
|
|
3053
|
-
|
|
3054
|
-
const
|
|
3044
|
+
const I = window.visualViewport;
|
|
3045
|
+
I == null || I.addEventListener("resize", y), I == null || I.addEventListener("scroll", y);
|
|
3046
|
+
const j = window.setTimeout(y, 300);
|
|
3055
3047
|
return () => {
|
|
3056
|
-
window.removeEventListener("scroll", y, !0), window.removeEventListener("resize", y),
|
|
3048
|
+
window.removeEventListener("scroll", y, !0), window.removeEventListener("resize", y), I == null || I.removeEventListener("resize", y), I == null || I.removeEventListener("scroll", y), window.clearTimeout(j);
|
|
3057
3049
|
};
|
|
3058
|
-
}, [h,
|
|
3059
|
-
const y = (
|
|
3060
|
-
var
|
|
3061
|
-
const
|
|
3062
|
-
(
|
|
3050
|
+
}, [h, V]), le(() => {
|
|
3051
|
+
const y = (I) => {
|
|
3052
|
+
var me, ce;
|
|
3053
|
+
const j = I.target;
|
|
3054
|
+
(me = R.current) != null && me.contains(j) || (ce = S.current) != null && ce.contains(j) || u(!1);
|
|
3063
3055
|
};
|
|
3064
3056
|
return document.addEventListener("mousedown", y), () => document.removeEventListener("mousedown", y);
|
|
3065
3057
|
}, []);
|
|
3066
|
-
const
|
|
3058
|
+
const P = f ? m.filter(
|
|
3067
3059
|
(y) => y.label.toLowerCase().includes(f.toLowerCase())
|
|
3068
|
-
) : m, te = (
|
|
3060
|
+
) : m, te = (B = m.find((y) => y.value === o)) == null ? void 0 : B.label, [G, ne] = E(-1), se = `${e.key}-listbox`, Y = Ee(
|
|
3069
3061
|
(y) => {
|
|
3070
|
-
a(e.key, y),
|
|
3062
|
+
a(e.key, y), u(!1), d(""), ne(-1);
|
|
3071
3063
|
},
|
|
3072
3064
|
[e.key, a]
|
|
3073
|
-
),
|
|
3065
|
+
), O = (y) => {
|
|
3074
3066
|
if (!h) {
|
|
3075
|
-
(y.key === "ArrowDown" || y.key === "Enter") && (y.preventDefault(),
|
|
3067
|
+
(y.key === "ArrowDown" || y.key === "Enter") && (y.preventDefault(), u(!0));
|
|
3076
3068
|
return;
|
|
3077
3069
|
}
|
|
3078
3070
|
switch (y.key) {
|
|
3079
3071
|
case "ArrowDown":
|
|
3080
|
-
y.preventDefault(),
|
|
3081
|
-
(
|
|
3072
|
+
y.preventDefault(), P.length > 0 && ne(
|
|
3073
|
+
(I) => I < P.length - 1 ? I + 1 : 0
|
|
3082
3074
|
);
|
|
3083
3075
|
break;
|
|
3084
3076
|
case "ArrowUp":
|
|
3085
|
-
y.preventDefault(),
|
|
3086
|
-
(
|
|
3077
|
+
y.preventDefault(), P.length > 0 && ne(
|
|
3078
|
+
(I) => I > 0 ? I - 1 : P.length - 1
|
|
3087
3079
|
);
|
|
3088
3080
|
break;
|
|
3089
3081
|
case "Enter":
|
|
3090
|
-
y.preventDefault(), G >= 0 && G <
|
|
3082
|
+
y.preventDefault(), G >= 0 && G < P.length && Y(P[G].value);
|
|
3091
3083
|
break;
|
|
3092
3084
|
case "Escape":
|
|
3093
|
-
y.preventDefault(),
|
|
3085
|
+
y.preventDefault(), u(!1), ne(-1);
|
|
3094
3086
|
break;
|
|
3095
3087
|
}
|
|
3096
|
-
},
|
|
3088
|
+
}, U = h && K && typeof document < "u" ? Ut(
|
|
3097
3089
|
/* @__PURE__ */ t.jsx(
|
|
3098
3090
|
"div",
|
|
3099
3091
|
{
|
|
3100
|
-
ref:
|
|
3092
|
+
ref: S,
|
|
3101
3093
|
className: l.searchableDropdownList,
|
|
3102
3094
|
role: "listbox",
|
|
3103
|
-
id:
|
|
3095
|
+
id: se,
|
|
3104
3096
|
style: {
|
|
3105
3097
|
position: "absolute",
|
|
3106
|
-
top:
|
|
3107
|
-
left:
|
|
3098
|
+
top: K.top,
|
|
3099
|
+
left: K.left,
|
|
3108
3100
|
right: "auto",
|
|
3109
|
-
width:
|
|
3110
|
-
maxHeight:
|
|
3111
|
-
...
|
|
3101
|
+
width: K.width,
|
|
3102
|
+
maxHeight: K.maxHeight,
|
|
3103
|
+
...re
|
|
3112
3104
|
},
|
|
3113
|
-
children:
|
|
3105
|
+
children: C ? /* @__PURE__ */ t.jsx("div", { className: l.searchableDropdownEmpty, children: "Loading..." }) : P.length === 0 ? /* @__PURE__ */ t.jsx("div", { className: l.searchableDropdownEmpty, children: "No results found" }) : P.map((y, I) => /* @__PURE__ */ t.jsx(
|
|
3114
3106
|
"button",
|
|
3115
3107
|
{
|
|
3116
|
-
id: `${
|
|
3108
|
+
id: `${se}-option-${I}`,
|
|
3117
3109
|
type: "button",
|
|
3118
3110
|
role: "option",
|
|
3119
3111
|
"aria-selected": y.value === o,
|
|
3120
|
-
className: `${l.searchableDropdownOption} ${y.value === o ? l.searchableDropdownOptionSelected : ""} ${
|
|
3121
|
-
onMouseDown: (
|
|
3122
|
-
onClick: () =>
|
|
3112
|
+
className: `${l.searchableDropdownOption} ${y.value === o ? l.searchableDropdownOptionSelected : ""} ${I === G ? l.searchableDropdownOptionHighlighted : ""}`,
|
|
3113
|
+
onMouseDown: (j) => j.preventDefault(),
|
|
3114
|
+
onClick: () => Y(y.value),
|
|
3123
3115
|
children: y.label
|
|
3124
3116
|
},
|
|
3125
3117
|
y.value
|
|
@@ -3128,8 +3120,8 @@ const ys = ({ question: e }) => {
|
|
|
3128
3120
|
),
|
|
3129
3121
|
document.body
|
|
3130
3122
|
) : null;
|
|
3131
|
-
return /* @__PURE__ */ t.jsxs("div", { ref:
|
|
3132
|
-
/* @__PURE__ */ t.jsxs("div", { ref:
|
|
3123
|
+
return /* @__PURE__ */ t.jsxs("div", { ref: R, className: l.fieldGroup, children: [
|
|
3124
|
+
/* @__PURE__ */ t.jsxs("div", { ref: W, className: l.searchableDropdown, children: [
|
|
3133
3125
|
/* @__PURE__ */ t.jsx(
|
|
3134
3126
|
"input",
|
|
3135
3127
|
{
|
|
@@ -3138,17 +3130,17 @@ const ys = ({ question: e }) => {
|
|
|
3138
3130
|
className: l.fieldInput,
|
|
3139
3131
|
value: h ? f : te ?? "",
|
|
3140
3132
|
onChange: (y) => {
|
|
3141
|
-
|
|
3133
|
+
d(y.target.value), ne(-1), h || u(!0);
|
|
3142
3134
|
},
|
|
3143
|
-
onFocus: () =>
|
|
3144
|
-
onKeyDown:
|
|
3135
|
+
onFocus: () => u(!0),
|
|
3136
|
+
onKeyDown: O,
|
|
3145
3137
|
placeholder: e.placeholder || "Select or search...",
|
|
3146
3138
|
"aria-label": e.label,
|
|
3147
3139
|
"aria-expanded": h,
|
|
3148
3140
|
role: "combobox",
|
|
3149
3141
|
"aria-haspopup": "listbox",
|
|
3150
|
-
"aria-controls": h ?
|
|
3151
|
-
"aria-activedescendant": h && G >= 0 ? `${
|
|
3142
|
+
"aria-controls": h ? se : void 0,
|
|
3143
|
+
"aria-activedescendant": h && G >= 0 ? `${se}-option-${G}` : void 0
|
|
3152
3144
|
}
|
|
3153
3145
|
),
|
|
3154
3146
|
/* @__PURE__ */ t.jsx(
|
|
@@ -3156,7 +3148,7 @@ const ys = ({ question: e }) => {
|
|
|
3156
3148
|
{
|
|
3157
3149
|
type: "button",
|
|
3158
3150
|
className: l.searchableDropdownToggle,
|
|
3159
|
-
onClick: () =>
|
|
3151
|
+
onClick: () => u(!h),
|
|
3160
3152
|
"aria-label": "Toggle dropdown",
|
|
3161
3153
|
tabIndex: -1,
|
|
3162
3154
|
children: /* @__PURE__ */ t.jsx("svg", { width: "12", height: "8", viewBox: "0 0 12 8", fill: "none", children: /* @__PURE__ */ t.jsx(
|
|
@@ -3173,7 +3165,7 @@ const ys = ({ question: e }) => {
|
|
|
3173
3165
|
)
|
|
3174
3166
|
] }),
|
|
3175
3167
|
i && /* @__PURE__ */ t.jsx("p", { className: l.fieldError, children: i }),
|
|
3176
|
-
|
|
3168
|
+
U
|
|
3177
3169
|
] });
|
|
3178
3170
|
};
|
|
3179
3171
|
function vs(e) {
|
|
@@ -3202,8 +3194,8 @@ function vs(e) {
|
|
|
3202
3194
|
}
|
|
3203
3195
|
}
|
|
3204
3196
|
const xs = () => {
|
|
3205
|
-
const { currentPage: e, visibleQuestions: r, goToNext: a, contactConsentText: s } =
|
|
3206
|
-
return
|
|
3197
|
+
const { currentPage: e, visibleQuestions: r, goToNext: a, contactConsentText: s } = fe(), o = Z(null);
|
|
3198
|
+
return le(() => {
|
|
3207
3199
|
var i, _, f;
|
|
3208
3200
|
(_ = (i = o.current) == null ? void 0 : i.scrollTo) == null || _.call(i, { top: 0, behavior: "smooth" }), (f = o.current) == null || f.focus();
|
|
3209
3201
|
}, [e == null ? void 0 : e.id]), e ? /* @__PURE__ */ t.jsxs(
|
|
@@ -3253,7 +3245,7 @@ const xs = () => {
|
|
|
3253
3245
|
}
|
|
3254
3246
|
) : null;
|
|
3255
3247
|
}, Cs = ({ address: e }) => {
|
|
3256
|
-
const { currentPage: r } =
|
|
3248
|
+
const { currentPage: r } = fe();
|
|
3257
3249
|
if (!r) return null;
|
|
3258
3250
|
const a = [
|
|
3259
3251
|
e.street1,
|
|
@@ -3302,32 +3294,30 @@ const xs = () => {
|
|
|
3302
3294
|
smsConsentText: i,
|
|
3303
3295
|
onPageChange: _,
|
|
3304
3296
|
onAnswerChange: f,
|
|
3305
|
-
onClose:
|
|
3297
|
+
onClose: d,
|
|
3306
3298
|
onReady: h,
|
|
3307
|
-
onError:
|
|
3308
|
-
|
|
3309
|
-
contactConsentText: g
|
|
3299
|
+
onError: u,
|
|
3300
|
+
contactConsentText: m
|
|
3310
3301
|
}) => {
|
|
3311
|
-
const
|
|
3312
|
-
return /* @__PURE__ */ t.jsx("div", { className: l.container, style:
|
|
3302
|
+
const g = Se(s);
|
|
3303
|
+
return /* @__PURE__ */ t.jsx("div", { className: l.container, style: g, children: /* @__PURE__ */ t.jsxs(
|
|
3313
3304
|
Mn,
|
|
3314
3305
|
{
|
|
3315
|
-
market: m,
|
|
3316
3306
|
initialAnswers: o,
|
|
3317
3307
|
smsConsentText: i,
|
|
3318
|
-
contactConsentText:
|
|
3308
|
+
contactConsentText: m,
|
|
3319
3309
|
onSubmit: r,
|
|
3320
3310
|
onPageChange: _,
|
|
3321
3311
|
onAnswerChange: f,
|
|
3322
3312
|
onReady: h,
|
|
3323
|
-
onError:
|
|
3313
|
+
onError: u,
|
|
3324
3314
|
children: [
|
|
3325
|
-
/* @__PURE__ */ t.jsx(ts, { partnerLogoUrl: a, onClose:
|
|
3315
|
+
/* @__PURE__ */ t.jsx(ts, { partnerLogoUrl: a, onClose: d }),
|
|
3326
3316
|
/* @__PURE__ */ t.jsx(Cs, { address: e })
|
|
3327
3317
|
]
|
|
3328
3318
|
}
|
|
3329
3319
|
) });
|
|
3330
|
-
}, ws = "_root_1iq32_7", ks = "_card_1iq32_18", js = "_titleLarge_1iq32_36", Ns = "_featuresList_1iq32_40", Is = "_stepLayout_1iq32_55", Es = "_leftColumn_1iq32_47", Ss = "_introHeader_1iq32_68", Ps = "_schedule_1iq32_74", Ls = "_subtitleLeft_1iq32_124", Ts = "_feature_1iq32_40",
|
|
3320
|
+
}, ws = "_root_1iq32_7", ks = "_card_1iq32_18", js = "_titleLarge_1iq32_36", Ns = "_featuresList_1iq32_40", Is = "_stepLayout_1iq32_55", Es = "_leftColumn_1iq32_47", Ss = "_introHeader_1iq32_68", Ps = "_schedule_1iq32_74", Ls = "_subtitleLeft_1iq32_124", Ts = "_feature_1iq32_40", As = "_featureTitle_1iq32_143", Ds = "_featureDescription_1iq32_150", Os = "_title_1iq32_36", Rs = "_subtitle_1iq32_124", Bs = "_calendarHeader_1iq32_175", Ms = "_calendarMonthLabel_1iq32_182", $s = "_calendarNavButton_1iq32_188", Fs = "_calendarGrid_1iq32_208", Ws = "_calendarDayHeader_1iq32_214", Hs = "_calendarDayAvailable_1iq32_223", Vs = "_calendarDayDisabled_1iq32_224", qs = "_calendarDaySelected_1iq32_225", Us = "_timesHeader_1iq32_256", Gs = "_timeRow_1iq32_263", Ys = "_timeButton_1iq32_270", Zs = "_timeButtonSelected_1iq32_271", Ks = "_field_1iq32_294", zs = "_fieldLabel_1iq32_300", Js = "_input_1iq32_306", Xs = "_fieldset_1iq32_327", Qs = "_radioRow_1iq32_336", eo = "_radioOption_1iq32_341", to = "_faqBelowActions_1iq32_362", ro = "_faq_1iq32_362", no = "_faqHeader_1iq32_373", ao = "_faqItem_1iq32_381", so = "_faqQuestion_1iq32_390", oo = "_faqAnswer_1iq32_406", io = "_faqChevron_1iq32_413", lo = "_errorText_1iq32_423", co = "_actionsRow_1iq32_429", uo = "_linkButton_1iq32_437", ho = "_primaryButton_1iq32_454", fo = "_successCheckCircle_1iq32_488", mo = "_summaryCard_1iq32_500", po = "_summaryRow_1iq32_510", go = "_summaryIcon_1iq32_518", p = {
|
|
3331
3321
|
root: ws,
|
|
3332
3322
|
card: ks,
|
|
3333
3323
|
titleLarge: js,
|
|
@@ -3338,8 +3328,8 @@ const xs = () => {
|
|
|
3338
3328
|
schedule: Ps,
|
|
3339
3329
|
subtitleLeft: Ls,
|
|
3340
3330
|
feature: Ts,
|
|
3341
|
-
featureTitle:
|
|
3342
|
-
featureDescription:
|
|
3331
|
+
featureTitle: As,
|
|
3332
|
+
featureDescription: Ds,
|
|
3343
3333
|
title: Os,
|
|
3344
3334
|
subtitle: Rs,
|
|
3345
3335
|
calendarHeader: Bs,
|
|
@@ -3391,57 +3381,57 @@ function Mo({
|
|
|
3391
3381
|
onScheduled: i,
|
|
3392
3382
|
onDone: _,
|
|
3393
3383
|
onReady: f,
|
|
3394
|
-
onError:
|
|
3384
|
+
onError: d
|
|
3395
3385
|
}) {
|
|
3396
|
-
const h =
|
|
3397
|
-
|
|
3398
|
-
let
|
|
3386
|
+
const h = wt(), u = Se(o), [m, g] = E(_o), [C, v] = E("select"), [R, W] = E(null), [S, K] = E(null), [w, re] = E(null), [T, ae] = E(r ?? ""), [V, P] = E(pt(a ?? "")), [te, G] = E(null), [ne, se] = E(""), [Y, O] = E(!1), [U, B] = E(null);
|
|
3387
|
+
le(() => {
|
|
3388
|
+
let N = !1;
|
|
3399
3389
|
return (async () => {
|
|
3400
3390
|
try {
|
|
3401
|
-
const
|
|
3402
|
-
if (
|
|
3391
|
+
const M = await h.getAssessmentSlots({ offerId: e });
|
|
3392
|
+
if (N) return;
|
|
3403
3393
|
if (g({
|
|
3404
3394
|
loading: !1,
|
|
3405
3395
|
error: null,
|
|
3406
|
-
availableSlots:
|
|
3407
|
-
isSlotBased:
|
|
3408
|
-
timezone:
|
|
3409
|
-
}),
|
|
3410
|
-
|
|
3396
|
+
availableSlots: M.availableSlots,
|
|
3397
|
+
isSlotBased: M.isSlotBased,
|
|
3398
|
+
timezone: M.timezone
|
|
3399
|
+
}), M.availableSlots.length > 0)
|
|
3400
|
+
re(
|
|
3411
3401
|
yo(
|
|
3412
|
-
|
|
3402
|
+
gt(M.availableSlots[0], M.timezone)
|
|
3413
3403
|
)
|
|
3414
3404
|
);
|
|
3415
3405
|
else {
|
|
3416
|
-
const
|
|
3417
|
-
|
|
3406
|
+
const q = /* @__PURE__ */ new Date();
|
|
3407
|
+
re({ year: q.getFullYear(), month: q.getMonth() });
|
|
3418
3408
|
}
|
|
3419
3409
|
f == null || f();
|
|
3420
|
-
} catch (
|
|
3421
|
-
const
|
|
3422
|
-
if (
|
|
3423
|
-
g((
|
|
3424
|
-
const
|
|
3425
|
-
|
|
3410
|
+
} catch (M) {
|
|
3411
|
+
const q = M instanceof Error ? M : new Error(String(M));
|
|
3412
|
+
if (N) return;
|
|
3413
|
+
g((oe) => ({ ...oe, loading: !1, error: q }));
|
|
3414
|
+
const $ = /* @__PURE__ */ new Date();
|
|
3415
|
+
re({ year: $.getFullYear(), month: $.getMonth() }), d == null || d(q);
|
|
3426
3416
|
}
|
|
3427
3417
|
})(), () => {
|
|
3428
|
-
|
|
3418
|
+
N = !0;
|
|
3429
3419
|
};
|
|
3430
3420
|
}, [h, e]);
|
|
3431
3421
|
const y = Ie(() => {
|
|
3432
|
-
const
|
|
3433
|
-
for (const
|
|
3434
|
-
const
|
|
3435
|
-
|
|
3422
|
+
const N = /* @__PURE__ */ new Map();
|
|
3423
|
+
for (const M of m.availableSlots) {
|
|
3424
|
+
const q = gt(M, m.timezone), $ = N.get(q) ?? [];
|
|
3425
|
+
$.push(M), N.set(q, $);
|
|
3436
3426
|
}
|
|
3437
|
-
return
|
|
3427
|
+
return N;
|
|
3438
3428
|
}, [m.availableSlots, m.timezone]);
|
|
3439
|
-
if (m.loading || !
|
|
3429
|
+
if (m.loading || !w)
|
|
3440
3430
|
return /* @__PURE__ */ t.jsx(
|
|
3441
3431
|
"div",
|
|
3442
3432
|
{
|
|
3443
3433
|
className: p.root,
|
|
3444
|
-
style:
|
|
3434
|
+
style: u,
|
|
3445
3435
|
"data-testid": "schedule-assessment-loading",
|
|
3446
3436
|
children: /* @__PURE__ */ t.jsx("div", { className: p.card, children: /* @__PURE__ */ t.jsx("p", { className: p.subtitle, children: "Loading available times…" }) })
|
|
3447
3437
|
}
|
|
@@ -3451,18 +3441,18 @@ function Mo({
|
|
|
3451
3441
|
"div",
|
|
3452
3442
|
{
|
|
3453
3443
|
className: p.root,
|
|
3454
|
-
style:
|
|
3444
|
+
style: u,
|
|
3455
3445
|
"data-testid": "schedule-assessment-error",
|
|
3456
3446
|
children: /* @__PURE__ */ t.jsx("div", { className: p.card, children: /* @__PURE__ */ t.jsx("p", { className: p.subtitle, children: "We couldn't load available times. Please try again in a few minutes." }) })
|
|
3457
3447
|
}
|
|
3458
3448
|
);
|
|
3459
|
-
if (
|
|
3460
|
-
const
|
|
3449
|
+
if (C === "success") {
|
|
3450
|
+
const N = S ? new Date(S) : null;
|
|
3461
3451
|
return /* @__PURE__ */ t.jsx(
|
|
3462
3452
|
"div",
|
|
3463
3453
|
{
|
|
3464
3454
|
className: p.root,
|
|
3465
|
-
style:
|
|
3455
|
+
style: u,
|
|
3466
3456
|
"data-testid": "schedule-assessment-success",
|
|
3467
3457
|
children: /* @__PURE__ */ t.jsxs("div", { className: p.card, children: [
|
|
3468
3458
|
/* @__PURE__ */ t.jsx("div", { className: p.successCheckCircle, "aria-hidden": "true", children: /* @__PURE__ */ t.jsx("svg", { width: "20", height: "20", viewBox: "0 0 20 20", fill: "none", children: /* @__PURE__ */ t.jsx(
|
|
@@ -3475,17 +3465,17 @@ function Mo({
|
|
|
3475
3465
|
strokeLinejoin: "round"
|
|
3476
3466
|
}
|
|
3477
3467
|
) }) }),
|
|
3478
|
-
/* @__PURE__ */ t.jsx("h2", { className: p.title, children:
|
|
3468
|
+
/* @__PURE__ */ t.jsx("h2", { className: p.title, children: T ? `${bo(T)}, your assessment is scheduled!` : "Your assessment is scheduled!" }),
|
|
3479
3469
|
/* @__PURE__ */ t.jsx("p", { className: p.subtitle, children: "A calendar invite has been sent to your email address." }),
|
|
3480
3470
|
/* @__PURE__ */ t.jsxs("div", { className: p.summaryCard, children: [
|
|
3481
|
-
|
|
3471
|
+
N && /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
|
|
3482
3472
|
/* @__PURE__ */ t.jsxs("div", { className: p.summaryRow, children: [
|
|
3483
3473
|
/* @__PURE__ */ t.jsx(ko, {}),
|
|
3484
|
-
/* @__PURE__ */ t.jsx("span", { children:
|
|
3474
|
+
/* @__PURE__ */ t.jsx("span", { children: _t(N, m.timezone) })
|
|
3485
3475
|
] }),
|
|
3486
3476
|
/* @__PURE__ */ t.jsxs("div", { className: p.summaryRow, children: [
|
|
3487
3477
|
/* @__PURE__ */ t.jsx(jo, {}),
|
|
3488
|
-
/* @__PURE__ */ t.jsx("span", { children:
|
|
3478
|
+
/* @__PURE__ */ t.jsx("span", { children: bt(N, m.timezone) })
|
|
3489
3479
|
] })
|
|
3490
3480
|
] }),
|
|
3491
3481
|
s && /* @__PURE__ */ t.jsxs("div", { className: p.summaryRow, children: [
|
|
@@ -3506,29 +3496,29 @@ function Mo({
|
|
|
3506
3496
|
}
|
|
3507
3497
|
);
|
|
3508
3498
|
}
|
|
3509
|
-
if (
|
|
3510
|
-
const
|
|
3511
|
-
if (!(!
|
|
3512
|
-
|
|
3499
|
+
if (C === "confirm") {
|
|
3500
|
+
const N = V.replace(/\D/g, ""), M = !Y && T.trim().length > 0 && N.length >= 10 && te !== null && (!te || ne.trim().length > 0), q = async () => {
|
|
3501
|
+
if (!(!M || !S)) {
|
|
3502
|
+
O(!0), B(null);
|
|
3513
3503
|
try {
|
|
3514
|
-
const
|
|
3504
|
+
const $ = te ? `Customer: ${T.trim()}. Access instructions: ${ne.trim()}` : `Customer: ${T.trim()}. No gate code or entry restrictions.`, oe = await h.scheduleAssessment({
|
|
3515
3505
|
offerId: e,
|
|
3516
|
-
selectedInspectionTime:
|
|
3517
|
-
reminderPhone:
|
|
3518
|
-
notes:
|
|
3506
|
+
selectedInspectionTime: S,
|
|
3507
|
+
reminderPhone: V.replace(/\D/g, ""),
|
|
3508
|
+
notes: $
|
|
3519
3509
|
});
|
|
3520
|
-
|
|
3510
|
+
v("success");
|
|
3521
3511
|
try {
|
|
3522
|
-
await (i == null ? void 0 : i(
|
|
3523
|
-
} catch (
|
|
3524
|
-
const ge =
|
|
3525
|
-
|
|
3512
|
+
await (i == null ? void 0 : i(oe.visitId));
|
|
3513
|
+
} catch (he) {
|
|
3514
|
+
const ge = he instanceof Error ? he : new Error(String(he));
|
|
3515
|
+
d == null || d(ge);
|
|
3526
3516
|
}
|
|
3527
|
-
} catch (
|
|
3528
|
-
const
|
|
3529
|
-
|
|
3517
|
+
} catch ($) {
|
|
3518
|
+
const oe = $ instanceof Error ? $ : new Error(String($));
|
|
3519
|
+
B(oe.message), d == null || d(oe);
|
|
3530
3520
|
} finally {
|
|
3531
|
-
|
|
3521
|
+
O(!1);
|
|
3532
3522
|
}
|
|
3533
3523
|
}
|
|
3534
3524
|
};
|
|
@@ -3536,7 +3526,7 @@ function Mo({
|
|
|
3536
3526
|
"div",
|
|
3537
3527
|
{
|
|
3538
3528
|
className: p.root,
|
|
3539
|
-
style:
|
|
3529
|
+
style: u,
|
|
3540
3530
|
"data-testid": "schedule-assessment-confirm",
|
|
3541
3531
|
children: /* @__PURE__ */ t.jsxs("div", { className: p.card, children: [
|
|
3542
3532
|
/* @__PURE__ */ t.jsx("h2", { className: p.title, children: "Confirm your details" }),
|
|
@@ -3547,9 +3537,9 @@ function Mo({
|
|
|
3547
3537
|
{
|
|
3548
3538
|
className: p.input,
|
|
3549
3539
|
type: "text",
|
|
3550
|
-
value:
|
|
3551
|
-
onChange: (
|
|
3552
|
-
disabled:
|
|
3540
|
+
value: T,
|
|
3541
|
+
onChange: ($) => ae($.target.value),
|
|
3542
|
+
disabled: Y
|
|
3553
3543
|
}
|
|
3554
3544
|
)
|
|
3555
3545
|
] }),
|
|
@@ -3563,9 +3553,9 @@ function Mo({
|
|
|
3563
3553
|
inputMode: "tel",
|
|
3564
3554
|
autoComplete: "tel",
|
|
3565
3555
|
placeholder: "(555) 555-5555",
|
|
3566
|
-
value:
|
|
3567
|
-
onChange: (
|
|
3568
|
-
disabled:
|
|
3556
|
+
value: V,
|
|
3557
|
+
onChange: ($) => P(pt($.target.value)),
|
|
3558
|
+
disabled: Y
|
|
3569
3559
|
}
|
|
3570
3560
|
)
|
|
3571
3561
|
] }),
|
|
@@ -3580,7 +3570,7 @@ function Mo({
|
|
|
3580
3570
|
name: "gate-code",
|
|
3581
3571
|
checked: te === !0,
|
|
3582
3572
|
onChange: () => G(!0),
|
|
3583
|
-
disabled:
|
|
3573
|
+
disabled: Y
|
|
3584
3574
|
}
|
|
3585
3575
|
),
|
|
3586
3576
|
/* @__PURE__ */ t.jsx("span", { children: "Yes" })
|
|
@@ -3593,7 +3583,7 @@ function Mo({
|
|
|
3593
3583
|
name: "gate-code",
|
|
3594
3584
|
checked: te === !1,
|
|
3595
3585
|
onChange: () => G(!1),
|
|
3596
|
-
disabled:
|
|
3586
|
+
disabled: Y
|
|
3597
3587
|
}
|
|
3598
3588
|
),
|
|
3599
3589
|
/* @__PURE__ */ t.jsx("span", { children: "No" })
|
|
@@ -3608,21 +3598,21 @@ function Mo({
|
|
|
3608
3598
|
className: p.input,
|
|
3609
3599
|
type: "text",
|
|
3610
3600
|
placeholder: "Gate code, directions, etc.",
|
|
3611
|
-
value:
|
|
3612
|
-
onChange: (
|
|
3613
|
-
disabled:
|
|
3601
|
+
value: ne,
|
|
3602
|
+
onChange: ($) => se($.target.value),
|
|
3603
|
+
disabled: Y
|
|
3614
3604
|
}
|
|
3615
3605
|
)
|
|
3616
3606
|
] }),
|
|
3617
|
-
|
|
3607
|
+
U && /* @__PURE__ */ t.jsx("p", { className: p.errorText, children: U }),
|
|
3618
3608
|
/* @__PURE__ */ t.jsxs("div", { className: p.actionsRow, children: [
|
|
3619
3609
|
/* @__PURE__ */ t.jsx(
|
|
3620
3610
|
"button",
|
|
3621
3611
|
{
|
|
3622
3612
|
type: "button",
|
|
3623
3613
|
className: p.linkButton,
|
|
3624
|
-
onClick: () =>
|
|
3625
|
-
disabled:
|
|
3614
|
+
onClick: () => v("select"),
|
|
3615
|
+
disabled: Y,
|
|
3626
3616
|
children: "← Back"
|
|
3627
3617
|
}
|
|
3628
3618
|
),
|
|
@@ -3631,9 +3621,9 @@ function Mo({
|
|
|
3631
3621
|
{
|
|
3632
3622
|
type: "button",
|
|
3633
3623
|
className: p.primaryButton,
|
|
3634
|
-
onClick: () => void
|
|
3635
|
-
disabled: !
|
|
3636
|
-
children:
|
|
3624
|
+
onClick: () => void q(),
|
|
3625
|
+
disabled: !M,
|
|
3626
|
+
children: Y ? "Scheduling…" : "Schedule"
|
|
3637
3627
|
}
|
|
3638
3628
|
)
|
|
3639
3629
|
] }),
|
|
@@ -3642,12 +3632,12 @@ function Mo({
|
|
|
3642
3632
|
}
|
|
3643
3633
|
);
|
|
3644
3634
|
}
|
|
3645
|
-
const
|
|
3635
|
+
const I = vo(w), j = xo(w), me = Co(w, y), ce = wo(w, y), pe = R ? y.get(R) ?? [] : [], de = pe[0] ? _t(new Date(pe[0]), m.timezone) : null;
|
|
3646
3636
|
return /* @__PURE__ */ t.jsx(
|
|
3647
3637
|
"div",
|
|
3648
3638
|
{
|
|
3649
3639
|
className: p.root,
|
|
3650
|
-
style:
|
|
3640
|
+
style: u,
|
|
3651
3641
|
"data-testid": "schedule-assessment-flow",
|
|
3652
3642
|
children: /* @__PURE__ */ t.jsx("div", { className: p.card, children: /* @__PURE__ */ t.jsxs("div", { className: p.stepLayout, children: [
|
|
3653
3643
|
/* @__PURE__ */ t.jsxs("div", { className: p.leftColumn, children: [
|
|
@@ -3655,10 +3645,10 @@ function Mo({
|
|
|
3655
3645
|
/* @__PURE__ */ t.jsx("h2", { className: p.titleLarge, children: "Schedule your assessment" }),
|
|
3656
3646
|
/* @__PURE__ */ t.jsx("p", { className: p.subtitleLeft, children: "Pick a time that works for you." })
|
|
3657
3647
|
] }),
|
|
3658
|
-
/* @__PURE__ */ t.jsx("div", { className: p.featuresList, children: Io.map((
|
|
3659
|
-
/* @__PURE__ */ t.jsx("p", { className: p.featureTitle, children:
|
|
3660
|
-
/* @__PURE__ */ t.jsx("p", { className: p.featureDescription, children:
|
|
3661
|
-
] },
|
|
3648
|
+
/* @__PURE__ */ t.jsx("div", { className: p.featuresList, children: Io.map((N) => /* @__PURE__ */ t.jsxs("div", { className: p.feature, children: [
|
|
3649
|
+
/* @__PURE__ */ t.jsx("p", { className: p.featureTitle, children: N.title }),
|
|
3650
|
+
/* @__PURE__ */ t.jsx("p", { className: p.featureDescription, children: N.description })
|
|
3651
|
+
] }, N.title)) })
|
|
3662
3652
|
] }),
|
|
3663
3653
|
/* @__PURE__ */ t.jsxs("div", { className: p.schedule, children: [
|
|
3664
3654
|
/* @__PURE__ */ t.jsxs("div", { className: p.calendarHeader, children: [
|
|
@@ -3667,61 +3657,61 @@ function Mo({
|
|
|
3667
3657
|
{
|
|
3668
3658
|
type: "button",
|
|
3669
3659
|
className: p.calendarNavButton,
|
|
3670
|
-
onClick: () =>
|
|
3671
|
-
disabled: !
|
|
3660
|
+
onClick: () => re(yt(w, -1)),
|
|
3661
|
+
disabled: !me,
|
|
3672
3662
|
"aria-label": "Previous month",
|
|
3673
3663
|
children: "‹"
|
|
3674
3664
|
}
|
|
3675
3665
|
),
|
|
3676
|
-
/* @__PURE__ */ t.jsx("span", { className: p.calendarMonthLabel, children:
|
|
3666
|
+
/* @__PURE__ */ t.jsx("span", { className: p.calendarMonthLabel, children: j }),
|
|
3677
3667
|
/* @__PURE__ */ t.jsx(
|
|
3678
3668
|
"button",
|
|
3679
3669
|
{
|
|
3680
3670
|
type: "button",
|
|
3681
3671
|
className: p.calendarNavButton,
|
|
3682
|
-
onClick: () =>
|
|
3683
|
-
disabled: !
|
|
3672
|
+
onClick: () => re(yt(w, 1)),
|
|
3673
|
+
disabled: !ce,
|
|
3684
3674
|
"aria-label": "Next month",
|
|
3685
3675
|
children: "›"
|
|
3686
3676
|
}
|
|
3687
3677
|
)
|
|
3688
3678
|
] }),
|
|
3689
3679
|
/* @__PURE__ */ t.jsxs("div", { className: p.calendarGrid, children: [
|
|
3690
|
-
["SUN", "MON", "TUE", "WED", "THU", "FRI", "SAT"].map((
|
|
3691
|
-
|
|
3692
|
-
const
|
|
3680
|
+
["SUN", "MON", "TUE", "WED", "THU", "FRI", "SAT"].map((N) => /* @__PURE__ */ t.jsx("div", { className: p.calendarDayHeader, children: N }, N)),
|
|
3681
|
+
I.map((N, M) => {
|
|
3682
|
+
const q = N ? y.has(N.key) : !1, $ = !!N && N.key === R;
|
|
3693
3683
|
return /* @__PURE__ */ t.jsx(
|
|
3694
3684
|
"button",
|
|
3695
3685
|
{
|
|
3696
3686
|
type: "button",
|
|
3697
|
-
className:
|
|
3687
|
+
className: $ ? p.calendarDaySelected : q ? p.calendarDayAvailable : p.calendarDayDisabled,
|
|
3698
3688
|
onClick: () => {
|
|
3699
|
-
|
|
3689
|
+
N && q && (W(N.key), K(null));
|
|
3700
3690
|
},
|
|
3701
|
-
disabled: !
|
|
3702
|
-
"aria-pressed":
|
|
3703
|
-
children:
|
|
3691
|
+
disabled: !q,
|
|
3692
|
+
"aria-pressed": !!$,
|
|
3693
|
+
children: N ? N.day : ""
|
|
3704
3694
|
},
|
|
3705
|
-
|
|
3695
|
+
N ? N.key : `empty-${j}-${M}`
|
|
3706
3696
|
);
|
|
3707
3697
|
})
|
|
3708
3698
|
] }),
|
|
3709
|
-
|
|
3699
|
+
de && /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
|
|
3710
3700
|
/* @__PURE__ */ t.jsxs("p", { className: p.timesHeader, children: [
|
|
3711
3701
|
"Available times for ",
|
|
3712
|
-
|
|
3702
|
+
de
|
|
3713
3703
|
] }),
|
|
3714
|
-
/* @__PURE__ */ t.jsx("div", { className: p.timeRow, children: pe.map((
|
|
3715
|
-
const
|
|
3704
|
+
/* @__PURE__ */ t.jsx("div", { className: p.timeRow, children: pe.map((N) => {
|
|
3705
|
+
const M = N === S;
|
|
3716
3706
|
return /* @__PURE__ */ t.jsx(
|
|
3717
3707
|
"button",
|
|
3718
3708
|
{
|
|
3719
3709
|
type: "button",
|
|
3720
|
-
className:
|
|
3721
|
-
onClick: () =>
|
|
3722
|
-
children:
|
|
3710
|
+
className: M ? p.timeButtonSelected : p.timeButton,
|
|
3711
|
+
onClick: () => K(N),
|
|
3712
|
+
children: bt(new Date(N), m.timezone)
|
|
3723
3713
|
},
|
|
3724
|
-
|
|
3714
|
+
N
|
|
3725
3715
|
);
|
|
3726
3716
|
}) })
|
|
3727
3717
|
] }),
|
|
@@ -3730,8 +3720,8 @@ function Mo({
|
|
|
3730
3720
|
{
|
|
3731
3721
|
type: "button",
|
|
3732
3722
|
className: p.primaryButton,
|
|
3733
|
-
onClick: () =>
|
|
3734
|
-
disabled: !
|
|
3723
|
+
onClick: () => v("confirm"),
|
|
3724
|
+
disabled: !S,
|
|
3735
3725
|
children: "Continue"
|
|
3736
3726
|
}
|
|
3737
3727
|
)
|
|
@@ -3743,11 +3733,11 @@ function Mo({
|
|
|
3743
3733
|
function bo(e) {
|
|
3744
3734
|
return e.trim().split(/\s+/)[0] ?? "";
|
|
3745
3735
|
}
|
|
3746
|
-
function
|
|
3736
|
+
function pt(e) {
|
|
3747
3737
|
const r = e.replace(/\D/g, "").slice(0, 10);
|
|
3748
3738
|
return r.length === 0 ? "" : r.length <= 3 ? `(${r}` : r.length <= 6 ? `(${r.slice(0, 3)}) ${r.slice(3)}` : `(${r.slice(0, 3)}) ${r.slice(3, 6)}-${r.slice(6)}`;
|
|
3749
3739
|
}
|
|
3750
|
-
function
|
|
3740
|
+
function gt(e, r) {
|
|
3751
3741
|
const a = new Date(e);
|
|
3752
3742
|
return new Intl.DateTimeFormat("en-CA", {
|
|
3753
3743
|
timeZone: r,
|
|
@@ -3760,7 +3750,7 @@ function yo(e) {
|
|
|
3760
3750
|
const [r, a] = e.split("-").map((s) => parseInt(s, 10));
|
|
3761
3751
|
return { year: r, month: a - 1 };
|
|
3762
3752
|
}
|
|
3763
|
-
function
|
|
3753
|
+
function _t(e, r) {
|
|
3764
3754
|
return new Intl.DateTimeFormat(void 0, {
|
|
3765
3755
|
timeZone: r,
|
|
3766
3756
|
weekday: "long",
|
|
@@ -3768,7 +3758,7 @@ function bt(e, r) {
|
|
|
3768
3758
|
day: "numeric"
|
|
3769
3759
|
}).format(e);
|
|
3770
3760
|
}
|
|
3771
|
-
function
|
|
3761
|
+
function bt(e, r) {
|
|
3772
3762
|
return new Intl.DateTimeFormat(void 0, {
|
|
3773
3763
|
timeZone: r,
|
|
3774
3764
|
hour: "numeric",
|
|
@@ -3776,14 +3766,14 @@ function yt(e, r) {
|
|
|
3776
3766
|
hour12: !0
|
|
3777
3767
|
}).format(e);
|
|
3778
3768
|
}
|
|
3779
|
-
function
|
|
3769
|
+
function yt(e, r) {
|
|
3780
3770
|
const a = e.year * 12 + e.month + r, s = Math.floor(a / 12), o = a - s * 12;
|
|
3781
3771
|
return { year: s, month: o };
|
|
3782
3772
|
}
|
|
3783
3773
|
function vo({ year: e, month: r }) {
|
|
3784
3774
|
const a = new Date(Date.UTC(e, r, 1)).getUTCDay(), s = new Date(Date.UTC(e, r + 1, 0)).getUTCDate(), o = Math.ceil((a + s) / 7) * 7, i = [], _ = String(e).padStart(4, "0"), f = String(r + 1).padStart(2, "0");
|
|
3785
|
-
for (let
|
|
3786
|
-
const h =
|
|
3775
|
+
for (let d = 0; d < o; d++) {
|
|
3776
|
+
const h = d - a + 1;
|
|
3787
3777
|
h < 1 || h > s ? i.push(null) : i.push({
|
|
3788
3778
|
key: `${_}-${f}-${String(h).padStart(2, "0")}`,
|
|
3789
3779
|
day: h
|
|
@@ -3906,13 +3896,13 @@ function Po({
|
|
|
3906
3896
|
] });
|
|
3907
3897
|
}
|
|
3908
3898
|
export {
|
|
3909
|
-
|
|
3899
|
+
Do as AddressEntry,
|
|
3910
3900
|
Ro as AddressMap,
|
|
3911
3901
|
Oo as AddressUnitConfirmation,
|
|
3912
3902
|
Bo as DtcOnboardingFlow,
|
|
3913
|
-
|
|
3903
|
+
Ao as OpendoorProvider,
|
|
3914
3904
|
Mo as ScheduleAssessmentFlow,
|
|
3915
|
-
|
|
3916
|
-
|
|
3917
|
-
|
|
3905
|
+
ir as THEMES,
|
|
3906
|
+
lr as resolveAppearance,
|
|
3907
|
+
wt as useOpendoorClient
|
|
3918
3908
|
};
|