@opendoor/partner-sdk-client-react 1.3.3-beta.111.1 → 1.3.3-beta.113.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/index.js +716 -663
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import
|
|
2
|
-
import { createPortal as
|
|
1
|
+
import wt, { createContext as Ye, useState as E, useEffect as se, useContext as De, useRef as G, useMemo as Se, useCallback as Ee, useLayoutEffect as Ut } from "react";
|
|
2
|
+
import { createPortal as Yt } from "react-dom";
|
|
3
3
|
var Ge = { exports: {} }, Ne = {};
|
|
4
4
|
/*
|
|
5
5
|
object-assign
|
|
6
6
|
(c) Sindre Sorhus
|
|
7
7
|
@license MIT
|
|
8
8
|
*/
|
|
9
|
-
var
|
|
10
|
-
function
|
|
11
|
-
if (
|
|
12
|
-
|
|
9
|
+
var $e, it;
|
|
10
|
+
function kt() {
|
|
11
|
+
if (it) return $e;
|
|
12
|
+
it = 1;
|
|
13
13
|
var e = Object.getOwnPropertySymbols, r = Object.prototype.hasOwnProperty, a = Object.prototype.propertyIsEnumerable;
|
|
14
14
|
function s(i) {
|
|
15
15
|
if (i == null)
|
|
@@ -23,34 +23,34 @@ function Ct() {
|
|
|
23
23
|
var i = new String("abc");
|
|
24
24
|
if (i[5] = "de", Object.getOwnPropertyNames(i)[0] === "5")
|
|
25
25
|
return !1;
|
|
26
|
-
for (var
|
|
27
|
-
|
|
28
|
-
var
|
|
29
|
-
return
|
|
26
|
+
for (var m = {}, f = 0; f < 10; f++)
|
|
27
|
+
m["_" + String.fromCharCode(f)] = f;
|
|
28
|
+
var d = Object.getOwnPropertyNames(m).map(function(h) {
|
|
29
|
+
return m[h];
|
|
30
30
|
});
|
|
31
|
-
if (
|
|
31
|
+
if (d.join("") !== "0123456789")
|
|
32
32
|
return !1;
|
|
33
|
-
var
|
|
34
|
-
return "abcdefghijklmnopqrst".split("").forEach(function(
|
|
35
|
-
h
|
|
36
|
-
}), Object.keys(Object.assign({},
|
|
33
|
+
var u = {};
|
|
34
|
+
return "abcdefghijklmnopqrst".split("").forEach(function(h) {
|
|
35
|
+
u[h] = h;
|
|
36
|
+
}), Object.keys(Object.assign({}, u)).join("") === "abcdefghijklmnopqrst";
|
|
37
37
|
} catch {
|
|
38
38
|
return !1;
|
|
39
39
|
}
|
|
40
40
|
}
|
|
41
|
-
return
|
|
42
|
-
for (var f,
|
|
43
|
-
f = Object(arguments[
|
|
44
|
-
for (var
|
|
45
|
-
r.call(f,
|
|
41
|
+
return $e = o() ? Object.assign : function(i, m) {
|
|
42
|
+
for (var f, d = s(i), u, h = 1; h < arguments.length; h++) {
|
|
43
|
+
f = Object(arguments[h]);
|
|
44
|
+
for (var p in f)
|
|
45
|
+
r.call(f, p) && (d[p] = f[p]);
|
|
46
46
|
if (e) {
|
|
47
|
-
|
|
48
|
-
for (var
|
|
49
|
-
a.call(f,
|
|
47
|
+
u = e(f);
|
|
48
|
+
for (var _ = 0; _ < u.length; _++)
|
|
49
|
+
a.call(f, u[_]) && (d[u[_]] = f[u[_]]);
|
|
50
50
|
}
|
|
51
51
|
}
|
|
52
|
-
return
|
|
53
|
-
},
|
|
52
|
+
return d;
|
|
53
|
+
}, $e;
|
|
54
54
|
}
|
|
55
55
|
/** @license React v17.0.2
|
|
56
56
|
* react-jsx-runtime.production.min.js
|
|
@@ -60,24 +60,24 @@ function Ct() {
|
|
|
60
60
|
* This source code is licensed under the MIT license found in the
|
|
61
61
|
* LICENSE file in the root directory of this source tree.
|
|
62
62
|
*/
|
|
63
|
-
var
|
|
64
|
-
function
|
|
65
|
-
if (
|
|
66
|
-
|
|
67
|
-
var e =
|
|
63
|
+
var lt;
|
|
64
|
+
function Zt() {
|
|
65
|
+
if (lt) return Ne;
|
|
66
|
+
lt = 1, kt();
|
|
67
|
+
var e = wt, r = 60103;
|
|
68
68
|
if (Ne.Fragment = 60107, typeof Symbol == "function" && Symbol.for) {
|
|
69
69
|
var a = Symbol.for;
|
|
70
70
|
r = a("react.element"), Ne.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
|
|
74
|
-
var
|
|
75
|
-
|
|
76
|
-
for (
|
|
77
|
-
if (f && f.defaultProps) for (
|
|
78
|
-
return { $$typeof: r, type: f, key:
|
|
73
|
+
function m(f, d, u) {
|
|
74
|
+
var h, p = {}, _ = null, C = null;
|
|
75
|
+
u !== void 0 && (_ = "" + u), d.key !== void 0 && (_ = "" + d.key), d.ref !== void 0 && (C = d.ref);
|
|
76
|
+
for (h in d) o.call(d, h) && !i.hasOwnProperty(h) && (p[h] = d[h]);
|
|
77
|
+
if (f && f.defaultProps) for (h in d = f.defaultProps, d) p[h] === void 0 && (p[h] = d[h]);
|
|
78
|
+
return { $$typeof: r, type: f, key: _, ref: C, props: p, _owner: s.current };
|
|
79
79
|
}
|
|
80
|
-
return Ne.jsx =
|
|
80
|
+
return Ne.jsx = m, Ne.jsxs = m, Ne;
|
|
81
81
|
}
|
|
82
82
|
var We = {};
|
|
83
83
|
/** @license React v17.0.2
|
|
@@ -88,45 +88,45 @@ var We = {};
|
|
|
88
88
|
* This source code is licensed under the MIT license found in the
|
|
89
89
|
* LICENSE file in the root directory of this source tree.
|
|
90
90
|
*/
|
|
91
|
-
var
|
|
92
|
-
function
|
|
93
|
-
return
|
|
91
|
+
var ct;
|
|
92
|
+
function Kt() {
|
|
93
|
+
return ct || (ct = 1, function(e) {
|
|
94
94
|
process.env.NODE_ENV !== "production" && function() {
|
|
95
|
-
var r =
|
|
95
|
+
var r = wt, a = kt(), s = 60103, o = 60106;
|
|
96
96
|
e.Fragment = 60107;
|
|
97
|
-
var i = 60108,
|
|
97
|
+
var i = 60108, m = 60114, f = 60109, d = 60110, u = 60112, h = 60113, p = 60120, _ = 60115, C = 60116, S = 60121, k = 60122, H = 60117, P = 60129, Y = 60131;
|
|
98
98
|
if (typeof Symbol == "function" && Symbol.for) {
|
|
99
99
|
var j = Symbol.for;
|
|
100
|
-
s = j("react.element"), o = j("react.portal"), e.Fragment = j("react.fragment"), i = j("react.strict_mode"),
|
|
100
|
+
s = j("react.element"), o = j("react.portal"), e.Fragment = j("react.fragment"), i = j("react.strict_mode"), m = j("react.profiler"), f = j("react.provider"), d = j("react.context"), u = j("react.forward_ref"), h = j("react.suspense"), p = j("react.suspense_list"), _ = j("react.memo"), C = j("react.lazy"), S = j("react.block"), k = j("react.server.block"), H = j("react.fundamental"), j("react.scope"), j("react.opaque.id"), P = j("react.debug_trace_mode"), j("react.offscreen"), Y = j("react.legacy_hidden");
|
|
101
101
|
}
|
|
102
|
-
var ne = typeof Symbol == "function" && Symbol.iterator,
|
|
102
|
+
var ne = typeof Symbol == "function" && Symbol.iterator, F = "@@iterator";
|
|
103
103
|
function oe(n) {
|
|
104
104
|
if (n === null || typeof n != "object")
|
|
105
105
|
return null;
|
|
106
|
-
var c = ne && n[ne] || n[
|
|
106
|
+
var c = ne && n[ne] || n[F];
|
|
107
107
|
return typeof c == "function" ? c : null;
|
|
108
108
|
}
|
|
109
109
|
var U = r.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
|
|
110
|
-
function
|
|
110
|
+
function A(n) {
|
|
111
111
|
{
|
|
112
112
|
for (var c = arguments.length, b = new Array(c > 1 ? c - 1 : 0), I = 1; I < c; I++)
|
|
113
113
|
b[I - 1] = arguments[I];
|
|
114
|
-
|
|
114
|
+
$("error", n, b);
|
|
115
115
|
}
|
|
116
116
|
}
|
|
117
|
-
function
|
|
117
|
+
function $(n, c, b) {
|
|
118
118
|
{
|
|
119
119
|
var I = U.ReactDebugCurrentFrame, V = I.getStackAddendum();
|
|
120
120
|
V !== "" && (c += "%s", b = b.concat([V]));
|
|
121
|
-
var W = b.map(function(
|
|
122
|
-
return "" +
|
|
121
|
+
var W = b.map(function(D) {
|
|
122
|
+
return "" + D;
|
|
123
123
|
});
|
|
124
124
|
W.unshift("Warning: " + c), Function.prototype.apply.call(console[n], console, W);
|
|
125
125
|
}
|
|
126
126
|
}
|
|
127
127
|
var Z = !1;
|
|
128
128
|
function ae(n) {
|
|
129
|
-
return !!(typeof n == "string" || typeof n == "function" || n === e.Fragment || n ===
|
|
129
|
+
return !!(typeof n == "string" || typeof n == "function" || n === e.Fragment || n === m || n === P || n === i || n === h || n === p || n === Y || Z || typeof n == "object" && n !== null && (n.$$typeof === C || n.$$typeof === _ || n.$$typeof === f || n.$$typeof === d || n.$$typeof === u || n.$$typeof === H || n.$$typeof === S || n[0] === k));
|
|
130
130
|
}
|
|
131
131
|
function z(n, c, b) {
|
|
132
132
|
var I = c.displayName || c.name || "";
|
|
@@ -138,7 +138,7 @@ function Zt() {
|
|
|
138
138
|
function q(n) {
|
|
139
139
|
if (n == null)
|
|
140
140
|
return null;
|
|
141
|
-
if (typeof n.tag == "number" &&
|
|
141
|
+
if (typeof n.tag == "number" && A("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;
|
|
@@ -147,28 +147,28 @@ function Zt() {
|
|
|
147
147
|
return "Fragment";
|
|
148
148
|
case o:
|
|
149
149
|
return "Portal";
|
|
150
|
-
case
|
|
150
|
+
case m:
|
|
151
151
|
return "Profiler";
|
|
152
152
|
case i:
|
|
153
153
|
return "StrictMode";
|
|
154
|
-
case
|
|
154
|
+
case h:
|
|
155
155
|
return "Suspense";
|
|
156
|
-
case
|
|
156
|
+
case p:
|
|
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
163
|
return K(c) + ".Consumer";
|
|
164
164
|
case f:
|
|
165
165
|
var b = n;
|
|
166
166
|
return K(b._context) + ".Provider";
|
|
167
|
-
case
|
|
167
|
+
case u:
|
|
168
168
|
return z(n, n.render, "ForwardRef");
|
|
169
|
-
case
|
|
169
|
+
case _:
|
|
170
170
|
return q(n.type);
|
|
171
|
-
case
|
|
171
|
+
case S:
|
|
172
172
|
return q(n._render);
|
|
173
173
|
case C: {
|
|
174
174
|
var I = n, V = I._payload, W = I._init;
|
|
@@ -240,7 +240,7 @@ function Zt() {
|
|
|
240
240
|
})
|
|
241
241
|
});
|
|
242
242
|
}
|
|
243
|
-
ie < 0 &&
|
|
243
|
+
ie < 0 && A("disabledDepth fell below zero. This is a bug in React. Please file an issue.");
|
|
244
244
|
}
|
|
245
245
|
}
|
|
246
246
|
var N = U.ReactCurrentDispatcher, L;
|
|
@@ -278,27 +278,27 @@ function Zt() {
|
|
|
278
278
|
W = N.current, N.current = null, me();
|
|
279
279
|
try {
|
|
280
280
|
if (c) {
|
|
281
|
-
var
|
|
281
|
+
var D = function() {
|
|
282
282
|
throw Error();
|
|
283
283
|
};
|
|
284
|
-
if (Object.defineProperty(
|
|
284
|
+
if (Object.defineProperty(D.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(D, []);
|
|
291
291
|
} catch (be) {
|
|
292
292
|
I = be;
|
|
293
293
|
}
|
|
294
|
-
Reflect.construct(n, [],
|
|
294
|
+
Reflect.construct(n, [], D);
|
|
295
295
|
} else {
|
|
296
296
|
try {
|
|
297
|
-
|
|
297
|
+
D.call();
|
|
298
298
|
} catch (be) {
|
|
299
299
|
I = be;
|
|
300
300
|
}
|
|
301
|
-
n.call(
|
|
301
|
+
n.call(D.prototype);
|
|
302
302
|
}
|
|
303
303
|
} else {
|
|
304
304
|
try {
|
|
@@ -330,8 +330,8 @@ function Zt() {
|
|
|
330
330
|
} finally {
|
|
331
331
|
M = !1, N.current = W, pe(), Error.prepareStackTrace = V;
|
|
332
332
|
}
|
|
333
|
-
var je = n ? n.displayName || n.name : "",
|
|
334
|
-
return typeof n == "function" && le.set(n,
|
|
333
|
+
var je = n ? n.displayName || n.name : "", ot = je ? B(je) : "";
|
|
334
|
+
return typeof n == "function" && le.set(n, ot), ot;
|
|
335
335
|
}
|
|
336
336
|
function Le(n, c, b) {
|
|
337
337
|
return ge(n, !1);
|
|
@@ -348,18 +348,18 @@ function Zt() {
|
|
|
348
348
|
if (typeof n == "string")
|
|
349
349
|
return B(n);
|
|
350
350
|
switch (n) {
|
|
351
|
-
case
|
|
351
|
+
case h:
|
|
352
352
|
return B("Suspense");
|
|
353
|
-
case
|
|
353
|
+
case p:
|
|
354
354
|
return B("SuspenseList");
|
|
355
355
|
}
|
|
356
356
|
if (typeof n == "object")
|
|
357
357
|
switch (n.$$typeof) {
|
|
358
|
-
case
|
|
358
|
+
case u:
|
|
359
359
|
return Le(n.render);
|
|
360
|
-
case
|
|
360
|
+
case _:
|
|
361
361
|
return w(n.type, c, b);
|
|
362
|
-
case
|
|
362
|
+
case S:
|
|
363
363
|
return Le(n._render);
|
|
364
364
|
case C: {
|
|
365
365
|
var I = n, V = I._payload, W = I._init;
|
|
@@ -382,29 +382,29 @@ function Zt() {
|
|
|
382
382
|
function we(n, c, b, I, V) {
|
|
383
383
|
{
|
|
384
384
|
var W = Function.call.bind(Object.prototype.hasOwnProperty);
|
|
385
|
-
for (var
|
|
386
|
-
if (W(n,
|
|
385
|
+
for (var D in n)
|
|
386
|
+
if (W(n, D)) {
|
|
387
387
|
var T = void 0;
|
|
388
388
|
try {
|
|
389
|
-
if (typeof n[
|
|
390
|
-
var ce = Error((I || "React class") + ": " + b + " type `" +
|
|
389
|
+
if (typeof n[D] != "function") {
|
|
390
|
+
var ce = Error((I || "React class") + ": " + b + " type `" + D + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof n[D] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");
|
|
391
391
|
throw ce.name = "Invariant Violation", ce;
|
|
392
392
|
}
|
|
393
|
-
T = n[
|
|
393
|
+
T = n[D](c, D, I, b, null, "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED");
|
|
394
394
|
} catch (Q) {
|
|
395
395
|
T = Q;
|
|
396
396
|
}
|
|
397
|
-
T && !(T instanceof Error) && (Ce(V),
|
|
397
|
+
T && !(T instanceof Error) && (Ce(V), A("%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).", I || "React class", b, D, typeof T), Ce(null)), T instanceof Error && !(T.message in X) && (X[T.message] = !0, Ce(V), A("Failed %s type: %s", b, T.message), Ce(null));
|
|
398
398
|
}
|
|
399
399
|
}
|
|
400
400
|
}
|
|
401
|
-
var Ie = U.ReactCurrentOwner, Re = Object.prototype.hasOwnProperty,
|
|
401
|
+
var Ie = U.ReactCurrentOwner, Re = Object.prototype.hasOwnProperty, Pt = {
|
|
402
402
|
key: !0,
|
|
403
403
|
ref: !0,
|
|
404
404
|
__self: !0,
|
|
405
405
|
__source: !0
|
|
406
|
-
},
|
|
407
|
-
function
|
|
406
|
+
}, Xe, Qe;
|
|
407
|
+
function Lt(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 Tt(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 At(n, c) {
|
|
424
424
|
typeof n.ref == "string" && Ie.current;
|
|
425
425
|
}
|
|
426
426
|
function Dt(n, c) {
|
|
427
427
|
{
|
|
428
428
|
var b = function() {
|
|
429
|
-
|
|
429
|
+
Xe || (Xe = !0, A("%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,
|
|
@@ -434,10 +434,10 @@ function Zt() {
|
|
|
434
434
|
});
|
|
435
435
|
}
|
|
436
436
|
}
|
|
437
|
-
function
|
|
437
|
+
function Ot(n, c) {
|
|
438
438
|
{
|
|
439
439
|
var b = function() {
|
|
440
|
-
|
|
440
|
+
Qe || (Qe = !0, A("%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,7 +445,7 @@ function Zt() {
|
|
|
445
445
|
});
|
|
446
446
|
}
|
|
447
447
|
}
|
|
448
|
-
var
|
|
448
|
+
var Rt = function(n, c, b, I, V, W, D) {
|
|
449
449
|
var T = {
|
|
450
450
|
// This tag allows us to uniquely identify this as a React Element
|
|
451
451
|
$$typeof: s,
|
|
@@ -453,7 +453,7 @@ function Zt() {
|
|
|
453
453
|
type: n,
|
|
454
454
|
key: c,
|
|
455
455
|
ref: b,
|
|
456
|
-
props:
|
|
456
|
+
props: D,
|
|
457
457
|
// Record the component responsible for creating this element.
|
|
458
458
|
_owner: W
|
|
459
459
|
};
|
|
@@ -474,38 +474,38 @@ function Zt() {
|
|
|
474
474
|
value: V
|
|
475
475
|
}), Object.freeze && (Object.freeze(T.props), Object.freeze(T)), T;
|
|
476
476
|
};
|
|
477
|
-
function
|
|
477
|
+
function Bt(n, c, b, I, V) {
|
|
478
478
|
{
|
|
479
|
-
var W,
|
|
480
|
-
b !== void 0 && (T = "" + b),
|
|
479
|
+
var W, D = {}, T = null, ce = null;
|
|
480
|
+
b !== void 0 && (T = "" + b), Tt(c) && (T = "" + c.key), Lt(c) && (ce = c.ref, At(c, V));
|
|
481
481
|
for (W in c)
|
|
482
|
-
Re.call(c, W) && !
|
|
482
|
+
Re.call(c, W) && !Pt.hasOwnProperty(W) && (D[W] = c[W]);
|
|
483
483
|
if (n && n.defaultProps) {
|
|
484
484
|
var Q = n.defaultProps;
|
|
485
485
|
for (W in Q)
|
|
486
|
-
|
|
486
|
+
D[W] === void 0 && (D[W] = Q[W]);
|
|
487
487
|
}
|
|
488
488
|
if (T || ce) {
|
|
489
489
|
var te = typeof n == "function" ? n.displayName || n.name || "Unknown" : n;
|
|
490
|
-
T && Dt(
|
|
490
|
+
T && Dt(D, te), ce && Ot(D, te);
|
|
491
491
|
}
|
|
492
|
-
return
|
|
492
|
+
return Rt(n, T, ce, V, I, Ie.current, D);
|
|
493
493
|
}
|
|
494
494
|
}
|
|
495
|
-
var Be = U.ReactCurrentOwner,
|
|
495
|
+
var Be = U.ReactCurrentOwner, et = U.ReactDebugCurrentFrame;
|
|
496
496
|
function ke(n) {
|
|
497
497
|
if (n) {
|
|
498
498
|
var c = n._owner, b = w(n.type, n._source, c ? c.type : null);
|
|
499
|
-
|
|
499
|
+
et.setExtraStackFrame(b);
|
|
500
500
|
} else
|
|
501
|
-
|
|
501
|
+
et.setExtraStackFrame(null);
|
|
502
502
|
}
|
|
503
503
|
var Me;
|
|
504
504
|
Me = !1;
|
|
505
|
-
function
|
|
505
|
+
function Fe(n) {
|
|
506
506
|
return typeof n == "object" && n !== null && n.$$typeof === s;
|
|
507
507
|
}
|
|
508
|
-
function
|
|
508
|
+
function tt() {
|
|
509
509
|
{
|
|
510
510
|
if (Be.current) {
|
|
511
511
|
var n = q(Be.current.type);
|
|
@@ -517,13 +517,13 @@ Check the render method of \`` + n + "`.";
|
|
|
517
517
|
return "";
|
|
518
518
|
}
|
|
519
519
|
}
|
|
520
|
-
function
|
|
520
|
+
function Mt(n) {
|
|
521
521
|
return "";
|
|
522
522
|
}
|
|
523
|
-
var
|
|
524
|
-
function
|
|
523
|
+
var rt = {};
|
|
524
|
+
function Ft(n) {
|
|
525
525
|
{
|
|
526
|
-
var c =
|
|
526
|
+
var c = tt();
|
|
527
527
|
if (!c) {
|
|
528
528
|
var b = typeof n == "string" ? n : n.displayName || n.name;
|
|
529
529
|
b && (c = `
|
|
@@ -533,35 +533,35 @@ Check the top-level render call using <` + b + ">.");
|
|
|
533
533
|
return c;
|
|
534
534
|
}
|
|
535
535
|
}
|
|
536
|
-
function
|
|
536
|
+
function nt(n, c) {
|
|
537
537
|
{
|
|
538
538
|
if (!n._store || n._store.validated || n.key != null)
|
|
539
539
|
return;
|
|
540
540
|
n._store.validated = !0;
|
|
541
|
-
var b =
|
|
542
|
-
if (
|
|
541
|
+
var b = Ft(c);
|
|
542
|
+
if (rt[b])
|
|
543
543
|
return;
|
|
544
|
-
|
|
544
|
+
rt[b] = !0;
|
|
545
545
|
var I = "";
|
|
546
|
-
n && n._owner && n._owner !== Be.current && (I = " It was passed a child from " + q(n._owner.type) + "."), ke(n),
|
|
546
|
+
n && n._owner && n._owner !== Be.current && (I = " It was passed a child from " + q(n._owner.type) + "."), ke(n), A('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', b, I), ke(null);
|
|
547
547
|
}
|
|
548
548
|
}
|
|
549
|
-
function
|
|
549
|
+
function at(n, c) {
|
|
550
550
|
{
|
|
551
551
|
if (typeof n != "object")
|
|
552
552
|
return;
|
|
553
553
|
if (Array.isArray(n))
|
|
554
554
|
for (var b = 0; b < n.length; b++) {
|
|
555
555
|
var I = n[b];
|
|
556
|
-
|
|
556
|
+
Fe(I) && nt(I, c);
|
|
557
557
|
}
|
|
558
|
-
else if (
|
|
558
|
+
else if (Fe(n))
|
|
559
559
|
n._store && (n._store.validated = !0);
|
|
560
560
|
else if (n) {
|
|
561
561
|
var V = oe(n);
|
|
562
562
|
if (typeof V == "function" && V !== n.entries)
|
|
563
|
-
for (var W = V.call(n),
|
|
564
|
-
|
|
563
|
+
for (var W = V.call(n), D; !(D = W.next()).done; )
|
|
564
|
+
Fe(D.value) && nt(D.value, c);
|
|
565
565
|
}
|
|
566
566
|
}
|
|
567
567
|
}
|
|
@@ -573,9 +573,9 @@ Check the top-level render call using <` + b + ">.");
|
|
|
573
573
|
var b;
|
|
574
574
|
if (typeof c == "function")
|
|
575
575
|
b = c.propTypes;
|
|
576
|
-
else if (typeof c == "object" && (c.$$typeof ===
|
|
576
|
+
else if (typeof c == "object" && (c.$$typeof === u || // Note: Memo only checks outer props here.
|
|
577
577
|
// Inner props are checked in the reconciler.
|
|
578
|
-
c.$$typeof ===
|
|
578
|
+
c.$$typeof === _))
|
|
579
579
|
b = c.propTypes;
|
|
580
580
|
else
|
|
581
581
|
return;
|
|
@@ -585,82 +585,82 @@ Check the top-level render call using <` + b + ">.");
|
|
|
585
585
|
} else if (c.PropTypes !== void 0 && !Me) {
|
|
586
586
|
Me = !0;
|
|
587
587
|
var V = q(c);
|
|
588
|
-
|
|
588
|
+
A("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?", V || "Unknown");
|
|
589
589
|
}
|
|
590
|
-
typeof c.getDefaultProps == "function" && !c.getDefaultProps.isReactClassApproved &&
|
|
590
|
+
typeof c.getDefaultProps == "function" && !c.getDefaultProps.isReactClassApproved && A("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.");
|
|
591
591
|
}
|
|
592
592
|
}
|
|
593
|
-
function
|
|
593
|
+
function Wt(n) {
|
|
594
594
|
{
|
|
595
595
|
for (var c = Object.keys(n.props), b = 0; b < c.length; b++) {
|
|
596
596
|
var I = c[b];
|
|
597
597
|
if (I !== "children" && I !== "key") {
|
|
598
|
-
ke(n),
|
|
598
|
+
ke(n), A("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.", I), ke(null);
|
|
599
599
|
break;
|
|
600
600
|
}
|
|
601
601
|
}
|
|
602
|
-
n.ref !== null && (ke(n),
|
|
602
|
+
n.ref !== null && (ke(n), A("Invalid attribute `ref` supplied to `React.Fragment`."), ke(null));
|
|
603
603
|
}
|
|
604
604
|
}
|
|
605
|
-
function
|
|
605
|
+
function st(n, c, b, I, V, W) {
|
|
606
606
|
{
|
|
607
|
-
var
|
|
608
|
-
if (!
|
|
607
|
+
var D = ae(n);
|
|
608
|
+
if (!D) {
|
|
609
609
|
var T = "";
|
|
610
610
|
(n === void 0 || typeof n == "object" && n !== null && Object.keys(n).length === 0) && (T += " 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 ce =
|
|
612
|
-
ce ? T += ce : T +=
|
|
611
|
+
var ce = Mt();
|
|
612
|
+
ce ? T += ce : T += tt();
|
|
613
613
|
var Q;
|
|
614
|
-
n === null ? Q = "null" : Array.isArray(n) ? Q = "array" : n !== void 0 && n.$$typeof === s ? (Q = "<" + (q(n.type) || "Unknown") + " />", T = " Did you accidentally export a JSX literal instead of a component?") : Q = typeof n,
|
|
614
|
+
n === null ? Q = "null" : Array.isArray(n) ? Q = "array" : n !== void 0 && n.$$typeof === s ? (Q = "<" + (q(n.type) || "Unknown") + " />", T = " Did you accidentally export a JSX literal instead of a component?") : Q = typeof n, A("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", Q, T);
|
|
615
615
|
}
|
|
616
|
-
var te =
|
|
616
|
+
var te = Bt(n, c, b, V, W);
|
|
617
617
|
if (te == null)
|
|
618
618
|
return te;
|
|
619
|
-
if (
|
|
619
|
+
if (D) {
|
|
620
620
|
var _e = c.children;
|
|
621
621
|
if (_e !== void 0)
|
|
622
622
|
if (I)
|
|
623
623
|
if (Array.isArray(_e)) {
|
|
624
624
|
for (var je = 0; je < _e.length; je++)
|
|
625
|
-
|
|
625
|
+
at(_e[je], n);
|
|
626
626
|
Object.freeze && Object.freeze(_e);
|
|
627
627
|
} else
|
|
628
|
-
|
|
628
|
+
A("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
|
+
at(_e, n);
|
|
631
631
|
}
|
|
632
|
-
return n === e.Fragment ?
|
|
632
|
+
return n === e.Fragment ? Wt(te) : $t(te), te;
|
|
633
633
|
}
|
|
634
634
|
}
|
|
635
|
-
function Wt(n, c, b) {
|
|
636
|
-
return at(n, c, b, !0);
|
|
637
|
-
}
|
|
638
635
|
function Ht(n, c, b) {
|
|
639
|
-
return
|
|
636
|
+
return st(n, c, b, !0);
|
|
640
637
|
}
|
|
641
|
-
|
|
642
|
-
|
|
638
|
+
function Vt(n, c, b) {
|
|
639
|
+
return st(n, c, b, !1);
|
|
640
|
+
}
|
|
641
|
+
var qt = Vt, Gt = Ht;
|
|
642
|
+
e.jsx = qt, e.jsxs = Gt;
|
|
643
643
|
}();
|
|
644
644
|
}(We)), We;
|
|
645
645
|
}
|
|
646
|
-
process.env.NODE_ENV === "production" ? Ge.exports =
|
|
646
|
+
process.env.NODE_ENV === "production" ? Ge.exports = Zt() : Ge.exports = Kt();
|
|
647
647
|
var t = Ge.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
|
+
}, Jt = "partner-sdk", Xt = "1.0", Qt = 5e3, er = 20, tr = 512, rr = 5, ut = 500, dt = "od_sdk_aid";
|
|
652
|
+
function nr() {
|
|
653
653
|
try {
|
|
654
|
-
const e = localStorage.getItem(
|
|
654
|
+
const e = localStorage.getItem(dt);
|
|
655
655
|
if (e)
|
|
656
656
|
return e;
|
|
657
657
|
const r = crypto.randomUUID();
|
|
658
|
-
return localStorage.setItem(
|
|
658
|
+
return localStorage.setItem(dt, r), r;
|
|
659
659
|
} catch {
|
|
660
660
|
return;
|
|
661
661
|
}
|
|
662
662
|
}
|
|
663
|
-
function
|
|
663
|
+
function ar() {
|
|
664
664
|
return typeof window > "u" ? { url: "", eventOrigin: "CLIENT" } : {
|
|
665
665
|
url: window.location.href,
|
|
666
666
|
userAgent: navigator.userAgent,
|
|
@@ -676,40 +676,40 @@ function nr() {
|
|
|
676
676
|
language: Array.from(navigator.languages ?? [])
|
|
677
677
|
};
|
|
678
678
|
}
|
|
679
|
-
function
|
|
679
|
+
function sr(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 or(e) {
|
|
686
|
+
return sr(e) >= tr - 50;
|
|
687
687
|
}
|
|
688
|
-
async function
|
|
689
|
-
let a =
|
|
688
|
+
async function ir(e, r) {
|
|
689
|
+
let a = rr;
|
|
690
690
|
for (; a > 0; )
|
|
691
691
|
try {
|
|
692
692
|
const s = await fetch(e, r);
|
|
693
693
|
if (s.status === 202)
|
|
694
694
|
return;
|
|
695
695
|
if (s.status >= 500 && a >= 1)
|
|
696
|
-
await new Promise((o) => setTimeout(o,
|
|
696
|
+
await new Promise((o) => setTimeout(o, ut)), a--;
|
|
697
697
|
else
|
|
698
698
|
break;
|
|
699
699
|
} catch {
|
|
700
700
|
if (a >= 1)
|
|
701
|
-
await new Promise((s) => setTimeout(s,
|
|
701
|
+
await new Promise((s) => setTimeout(s, ut)), a--;
|
|
702
702
|
else
|
|
703
703
|
break;
|
|
704
704
|
}
|
|
705
705
|
}
|
|
706
|
-
class
|
|
706
|
+
class lr {
|
|
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 = nr(), this.timer = setInterval(() => this.flush(), Qt), 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 = [], ir(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": Jt,
|
|
734
|
+
"X-Journey-Client-Version": Xt
|
|
735
735
|
},
|
|
736
736
|
body: a
|
|
737
737
|
});
|
|
@@ -744,14 +744,14 @@ class ir {
|
|
|
744
744
|
return;
|
|
745
745
|
const a = {
|
|
746
746
|
timestamp: (/* @__PURE__ */ new Date()).toISOString(),
|
|
747
|
-
websiteSource:
|
|
747
|
+
websiteSource: ar(),
|
|
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 >= er || or(this.buffer)) && this.flush();
|
|
752
752
|
}
|
|
753
753
|
}
|
|
754
|
-
const
|
|
754
|
+
const Ze = {
|
|
755
755
|
trackPlatform() {
|
|
756
756
|
},
|
|
757
757
|
trackSell() {
|
|
@@ -760,36 +760,36 @@ const Ye = {
|
|
|
760
760
|
},
|
|
761
761
|
destroy() {
|
|
762
762
|
}
|
|
763
|
-
},
|
|
763
|
+
}, Ke = Ye(null), jt = Ye(Ze), Ao = ({
|
|
764
764
|
client: e,
|
|
765
765
|
children: r
|
|
766
766
|
}) => {
|
|
767
|
-
const [a, s] =
|
|
767
|
+
const [a, s] = E(Ze);
|
|
768
768
|
return se(() => {
|
|
769
|
-
const o = new
|
|
769
|
+
const o = new lr(e.environment);
|
|
770
770
|
return s(o), () => {
|
|
771
771
|
o.destroy();
|
|
772
772
|
};
|
|
773
|
-
}, [e]), /* @__PURE__ */ t.jsx(
|
|
774
|
-
},
|
|
775
|
-
const e =
|
|
773
|
+
}, [e]), /* @__PURE__ */ t.jsx(Ke.Provider, { value: e, children: /* @__PURE__ */ t.jsx(jt.Provider, { value: a, children: r }) });
|
|
774
|
+
}, Nt = () => {
|
|
775
|
+
const e = De(Ke);
|
|
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
|
-
},
|
|
782
|
-
function
|
|
783
|
-
const a =
|
|
781
|
+
}, ze = () => De(jt);
|
|
782
|
+
function It(e, r = {}) {
|
|
783
|
+
const a = ze(), s = G(a);
|
|
784
784
|
s.current = a;
|
|
785
785
|
const o = G(null), i = G(!1);
|
|
786
786
|
return se(() => {
|
|
787
|
-
const
|
|
788
|
-
if (!
|
|
787
|
+
const m = o.current;
|
|
788
|
+
if (!m || !e || i.current) return;
|
|
789
789
|
const f = new IntersectionObserver(
|
|
790
|
-
([
|
|
791
|
-
if (
|
|
792
|
-
if (s.current ===
|
|
790
|
+
([d]) => {
|
|
791
|
+
if (d.isIntersecting && !i.current) {
|
|
792
|
+
if (s.current === Ze) return;
|
|
793
793
|
i.current = !0, s.current.trackPlatform({
|
|
794
794
|
inputViewEvent: { targetName: e }
|
|
795
795
|
}), r.immediate && s.current.flush(), f.disconnect();
|
|
@@ -797,7 +797,7 @@ function jt(e, r = {}) {
|
|
|
797
797
|
},
|
|
798
798
|
{ threshold: 0.5 }
|
|
799
799
|
);
|
|
800
|
-
return f.observe(
|
|
800
|
+
return f.observe(m), () => f.disconnect();
|
|
801
801
|
}, [e, r.immediate]), o;
|
|
802
802
|
}
|
|
803
803
|
const He = {
|
|
@@ -845,7 +845,7 @@ const He = {
|
|
|
845
845
|
colorCardBorder: "#e5e7eb",
|
|
846
846
|
colorCardBorderSelected: "#235ca3",
|
|
847
847
|
colorCardBackgroundSelected: "#f0f5ff"
|
|
848
|
-
},
|
|
848
|
+
}, cr = {
|
|
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,11 +881,11 @@ const He = {
|
|
|
881
881
|
buttonPaddingX: "32px"
|
|
882
882
|
}
|
|
883
883
|
};
|
|
884
|
-
function
|
|
885
|
-
const r =
|
|
884
|
+
function ur(e) {
|
|
885
|
+
const r = cr[(e == null ? void 0 : e.theme) ?? "default"];
|
|
886
886
|
return e != null && e.variables ? { ...r, ...e.variables } : r;
|
|
887
887
|
}
|
|
888
|
-
const
|
|
888
|
+
const Do = [
|
|
889
889
|
"confirm-home-details",
|
|
890
890
|
"ownership",
|
|
891
891
|
"sale-timeline",
|
|
@@ -905,17 +905,17 @@ const Ao = [
|
|
|
905
905
|
"contact-info"
|
|
906
906
|
];
|
|
907
907
|
function Pe(e) {
|
|
908
|
-
const r =
|
|
908
|
+
const r = ur(e), a = {};
|
|
909
909
|
for (const [s, o] of Object.entries(r)) {
|
|
910
910
|
const i = s.replace(/([A-Z])/g, "-$1").toLowerCase();
|
|
911
911
|
a[`--od-${i}`] = o;
|
|
912
912
|
}
|
|
913
913
|
return a;
|
|
914
914
|
}
|
|
915
|
-
const
|
|
916
|
-
attribution:
|
|
917
|
-
text:
|
|
918
|
-
},
|
|
915
|
+
const dr = "_attribution_11y4r_7", hr = "_text_11y4r_16", ht = {
|
|
916
|
+
attribution: dr,
|
|
917
|
+
text: hr
|
|
918
|
+
}, fr = () => /* @__PURE__ */ t.jsx(
|
|
919
919
|
"svg",
|
|
920
920
|
{
|
|
921
921
|
width: "75",
|
|
@@ -934,34 +934,34 @@ const ur = "_attribution_11y4r_7", dr = "_text_11y4r_16", dt = {
|
|
|
934
934
|
)
|
|
935
935
|
}
|
|
936
936
|
);
|
|
937
|
-
function
|
|
938
|
-
return /* @__PURE__ */ t.jsxs("div", { className:
|
|
939
|
-
/* @__PURE__ */ t.jsx("span", { className:
|
|
940
|
-
/* @__PURE__ */ t.jsx(
|
|
937
|
+
function mr() {
|
|
938
|
+
return /* @__PURE__ */ t.jsxs("div", { className: ht.attribution, "data-testid": "od-attribution", children: [
|
|
939
|
+
/* @__PURE__ */ t.jsx("span", { className: ht.text, children: "Powered by" }),
|
|
940
|
+
/* @__PURE__ */ t.jsx(fr, {})
|
|
941
941
|
] });
|
|
942
942
|
}
|
|
943
|
-
const
|
|
944
|
-
container:
|
|
945
|
-
inputSection:
|
|
946
|
-
inputWrapper:
|
|
947
|
-
input:
|
|
948
|
-
inputIcon:
|
|
949
|
-
button:
|
|
950
|
-
spinner:
|
|
951
|
-
suggestions:
|
|
952
|
-
errorState:
|
|
953
|
-
suggestion:
|
|
954
|
-
error:
|
|
955
|
-
errorIcon:
|
|
956
|
-
errorBorder:
|
|
957
|
-
manualLink:
|
|
943
|
+
const pr = "_container_tu90h_8", gr = "_inputSection_tu90h_16", _r = "_inputWrapper_tu90h_22", br = "_input_tu90h_16", yr = "_inputIcon_tu90h_63", vr = "_button_tu90h_80", xr = "_spinner_tu90h_121", Cr = "_suggestions_tu90h_136", wr = "_errorState_tu90h_150", kr = "_suggestion_tu90h_136", jr = "_error_tu90h_150", Nr = "_errorIcon_tu90h_199", Ir = "_errorBorder_tu90h_213", Sr = "_manualLink_tu90h_223", Er = "_manualForm_tu90h_245", Pr = "_manualFormField_tu90h_260", Lr = "_manualFormLabel_tu90h_264", Tr = "_manualFormInput_tu90h_273", Ar = "_formRow_tu90h_294", Dr = "_submitButton_tu90h_302", O = {
|
|
944
|
+
container: pr,
|
|
945
|
+
inputSection: gr,
|
|
946
|
+
inputWrapper: _r,
|
|
947
|
+
input: br,
|
|
948
|
+
inputIcon: yr,
|
|
949
|
+
button: vr,
|
|
950
|
+
spinner: xr,
|
|
951
|
+
suggestions: Cr,
|
|
952
|
+
errorState: wr,
|
|
953
|
+
suggestion: kr,
|
|
954
|
+
error: jr,
|
|
955
|
+
errorIcon: Nr,
|
|
956
|
+
errorBorder: Ir,
|
|
957
|
+
manualLink: Sr,
|
|
958
958
|
manualForm: Er,
|
|
959
|
-
manualFormField:
|
|
960
|
-
manualFormLabel:
|
|
961
|
-
manualFormInput:
|
|
962
|
-
formRow:
|
|
959
|
+
manualFormField: Pr,
|
|
960
|
+
manualFormLabel: Lr,
|
|
961
|
+
manualFormInput: Tr,
|
|
962
|
+
formRow: Ar,
|
|
963
963
|
submitButton: Dr
|
|
964
|
-
},
|
|
964
|
+
}, ft = () => /* @__PURE__ */ t.jsx(
|
|
965
965
|
"svg",
|
|
966
966
|
{
|
|
967
967
|
width: "20",
|
|
@@ -980,7 +980,7 @@ const mr = "_container_tu90h_8", pr = "_inputSection_tu90h_16", gr = "_inputWrap
|
|
|
980
980
|
}
|
|
981
981
|
)
|
|
982
982
|
}
|
|
983
|
-
),
|
|
983
|
+
), Or = () => /* @__PURE__ */ t.jsxs(
|
|
984
984
|
"svg",
|
|
985
985
|
{
|
|
986
986
|
width: "20",
|
|
@@ -1002,7 +1002,7 @@ const mr = "_container_tu90h_8", pr = "_inputSection_tu90h_16", gr = "_inputWrap
|
|
|
1002
1002
|
]
|
|
1003
1003
|
}
|
|
1004
1004
|
);
|
|
1005
|
-
function
|
|
1005
|
+
function mt(e) {
|
|
1006
1006
|
const r = [e.street1];
|
|
1007
1007
|
return e.street2 && (r[0] += ` ${e.street2}`), r.push(`${e.city}, ${e.state} ${e.postalCode}`), r.join(", ");
|
|
1008
1008
|
}
|
|
@@ -1013,26 +1013,26 @@ function Oo({
|
|
|
1013
1013
|
showAttribution: s = !1,
|
|
1014
1014
|
disabled: o = !1,
|
|
1015
1015
|
placeholderText: i = "Enter your home address",
|
|
1016
|
-
buttonText:
|
|
1016
|
+
buttonText: m = "Get cash offer",
|
|
1017
1017
|
showButton: f = !0,
|
|
1018
|
-
buttonIcon:
|
|
1019
|
-
inputIcon:
|
|
1020
|
-
manualEntryText:
|
|
1021
|
-
appearance:
|
|
1022
|
-
onReady:
|
|
1018
|
+
buttonIcon: d,
|
|
1019
|
+
inputIcon: u,
|
|
1020
|
+
manualEntryText: h = "Enter address manually instead",
|
|
1021
|
+
appearance: p,
|
|
1022
|
+
onReady: _,
|
|
1023
1023
|
onChange: C,
|
|
1024
|
-
onValidationError:
|
|
1024
|
+
onValidationError: S,
|
|
1025
1025
|
onAddressSuggestionsStart: k,
|
|
1026
1026
|
onAddressSuggestionsComplete: H,
|
|
1027
1027
|
onError: P
|
|
1028
1028
|
}) {
|
|
1029
|
-
const Y =
|
|
1029
|
+
const Y = Nt(), j = ze(), ne = Pe(p), [F, oe] = E(""), [U, A] = E([]), [$, Z] = E(!1), [ae, z] = E(!1), [K, q] = E(null), [ie, ue] = E(!1), [v, x] = E(!1), [y, R] = E({
|
|
1030
1030
|
street1: "",
|
|
1031
1031
|
street2: "",
|
|
1032
1032
|
city: "",
|
|
1033
1033
|
state: "",
|
|
1034
1034
|
postalCode: ""
|
|
1035
|
-
}), J = G(null), ye =
|
|
1035
|
+
}), J = G(null), ye = It("partner-sdk-address-input", {
|
|
1036
1036
|
immediate: !0
|
|
1037
1037
|
}), he = G(P);
|
|
1038
1038
|
he.current = P;
|
|
@@ -1040,30 +1040,30 @@ function Oo({
|
|
|
1040
1040
|
me.current = k;
|
|
1041
1041
|
const pe = G(H);
|
|
1042
1042
|
pe.current = H;
|
|
1043
|
-
const N = G(null), L =
|
|
1043
|
+
const N = G(null), L = $ && !ae && F.trim().length >= 3 && U.length === 0 && !v;
|
|
1044
1044
|
se(() => {
|
|
1045
|
-
|
|
1045
|
+
_ == null || _();
|
|
1046
1046
|
}, []), se(() => {
|
|
1047
|
-
if (!r ||
|
|
1048
|
-
|
|
1047
|
+
if (!r || F.trim().length < 3 || ie) {
|
|
1048
|
+
F.trim().length === 0 && (A([]), Z(!1), q(null));
|
|
1049
1049
|
return;
|
|
1050
1050
|
}
|
|
1051
1051
|
z(!0), q(null);
|
|
1052
1052
|
const w = setTimeout(async () => {
|
|
1053
1053
|
var X, ee, Ce;
|
|
1054
|
-
(X = me.current) == null || X.call(me,
|
|
1054
|
+
(X = me.current) == null || X.call(me, F);
|
|
1055
1055
|
try {
|
|
1056
|
-
const we = await Y.getAddressSuggestions(
|
|
1057
|
-
|
|
1056
|
+
const we = await Y.getAddressSuggestions(F);
|
|
1057
|
+
A(we.addresses), Z(!0), (ee = pe.current) == null || ee.call(pe, we.addresses);
|
|
1058
1058
|
} catch (we) {
|
|
1059
1059
|
const Ie = we instanceof Error ? we : new Error("Failed to fetch address suggestions");
|
|
1060
|
-
q(Ie.message),
|
|
1060
|
+
q(Ie.message), A([]), Z(!0), (Ce = he.current) == null || Ce.call(he, Ie);
|
|
1061
1061
|
} finally {
|
|
1062
1062
|
z(!1);
|
|
1063
1063
|
}
|
|
1064
1064
|
}, a);
|
|
1065
1065
|
return () => clearTimeout(w);
|
|
1066
|
-
}, [
|
|
1066
|
+
}, [F, ie, r, a, Y]), se(() => {
|
|
1067
1067
|
const w = (X) => {
|
|
1068
1068
|
N.current && !N.current.contains(X.target) && J.current && !J.current.contains(X.target) && Z(!1);
|
|
1069
1069
|
};
|
|
@@ -1073,7 +1073,7 @@ function Oo({
|
|
|
1073
1073
|
const X = w.target.value;
|
|
1074
1074
|
oe(X), ue(!1), C == null || C({ street1: X });
|
|
1075
1075
|
}, M = async (w) => {
|
|
1076
|
-
ue(!0), oe(
|
|
1076
|
+
ue(!0), oe(mt(w)), A([]), Z(!1), q(null), C == null || C(w), j.trackSell({
|
|
1077
1077
|
addressEntryV2: {
|
|
1078
1078
|
street1: w.street1,
|
|
1079
1079
|
city: w.city,
|
|
@@ -1092,7 +1092,7 @@ function Oo({
|
|
|
1092
1092
|
}, le = () => {
|
|
1093
1093
|
j.trackPlatform({
|
|
1094
1094
|
inputFocusEvent: { targetName: "partner-sdk-address-input" }
|
|
1095
|
-
}), U.length > 0 &&
|
|
1095
|
+
}), U.length > 0 && F.length > 0 && Z(!0);
|
|
1096
1096
|
}, xe = () => {
|
|
1097
1097
|
j.trackPlatform({
|
|
1098
1098
|
linkClickEvent: { targetName: "partner-sdk-manual-entry" }
|
|
@@ -1109,7 +1109,7 @@ function Oo({
|
|
|
1109
1109
|
}, Le = async () => {
|
|
1110
1110
|
if (!y.street1 || !y.city || !y.state || !y.postalCode) {
|
|
1111
1111
|
const w = "Please fill in all required fields";
|
|
1112
|
-
q(w),
|
|
1112
|
+
q(w), S == null || S(w);
|
|
1113
1113
|
return;
|
|
1114
1114
|
}
|
|
1115
1115
|
z(!0), q(null);
|
|
@@ -1228,8 +1228,8 @@ function Oo({
|
|
|
1228
1228
|
onClick: Le,
|
|
1229
1229
|
disabled: o,
|
|
1230
1230
|
children: [
|
|
1231
|
-
/* @__PURE__ */ t.jsx("span", { children:
|
|
1232
|
-
|
|
1231
|
+
/* @__PURE__ */ t.jsx("span", { children: m }),
|
|
1232
|
+
d || /* @__PURE__ */ t.jsx(ft, {})
|
|
1233
1233
|
]
|
|
1234
1234
|
}
|
|
1235
1235
|
)
|
|
@@ -1244,7 +1244,7 @@ function Oo({
|
|
|
1244
1244
|
{
|
|
1245
1245
|
ref: J,
|
|
1246
1246
|
type: "text",
|
|
1247
|
-
value:
|
|
1247
|
+
value: F,
|
|
1248
1248
|
onChange: B,
|
|
1249
1249
|
onFocus: le,
|
|
1250
1250
|
placeholder: i,
|
|
@@ -1253,19 +1253,19 @@ function Oo({
|
|
|
1253
1253
|
"aria-label": "Address input",
|
|
1254
1254
|
"aria-autocomplete": "list",
|
|
1255
1255
|
"aria-controls": "address-suggestions",
|
|
1256
|
-
"aria-expanded":
|
|
1256
|
+
"aria-expanded": $
|
|
1257
1257
|
}
|
|
1258
1258
|
),
|
|
1259
|
-
|
|
1259
|
+
u && /* @__PURE__ */ t.jsx("div", { className: O.inputIcon, children: u }),
|
|
1260
1260
|
f && /* @__PURE__ */ t.jsx(
|
|
1261
1261
|
"button",
|
|
1262
1262
|
{
|
|
1263
1263
|
className: O.button,
|
|
1264
1264
|
type: "button",
|
|
1265
1265
|
disabled: o,
|
|
1266
|
-
"aria-label":
|
|
1266
|
+
"aria-label": m,
|
|
1267
1267
|
children: ae ? /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
|
|
1268
|
-
/* @__PURE__ */ t.jsx("span", { children:
|
|
1268
|
+
/* @__PURE__ */ t.jsx("span", { children: m }),
|
|
1269
1269
|
/* @__PURE__ */ t.jsxs(
|
|
1270
1270
|
"svg",
|
|
1271
1271
|
{
|
|
@@ -1300,24 +1300,24 @@ function Oo({
|
|
|
1300
1300
|
}
|
|
1301
1301
|
)
|
|
1302
1302
|
] }) : /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
|
|
1303
|
-
/* @__PURE__ */ t.jsx("span", { children:
|
|
1304
|
-
|
|
1303
|
+
/* @__PURE__ */ t.jsx("span", { children: m }),
|
|
1304
|
+
d || /* @__PURE__ */ t.jsx(ft, {})
|
|
1305
1305
|
] })
|
|
1306
1306
|
}
|
|
1307
1307
|
)
|
|
1308
1308
|
]
|
|
1309
1309
|
}
|
|
1310
1310
|
),
|
|
1311
|
-
(
|
|
1311
|
+
($ || ve) && /* @__PURE__ */ t.jsx(
|
|
1312
1312
|
"div",
|
|
1313
1313
|
{
|
|
1314
1314
|
ref: N,
|
|
1315
1315
|
className: `${O.suggestions} ${ve ? O.errorState : ""}`,
|
|
1316
1316
|
id: "address-suggestions",
|
|
1317
|
-
role: ve &&
|
|
1318
|
-
"aria-live": ve &&
|
|
1317
|
+
role: ve && !$ ? "alert" : "listbox",
|
|
1318
|
+
"aria-live": ve && !$ ? "polite" : void 0,
|
|
1319
1319
|
children: ve ? /* @__PURE__ */ t.jsxs("div", { className: O.error, children: [
|
|
1320
|
-
/* @__PURE__ */ t.jsx("div", { className: O.errorIcon, children: /* @__PURE__ */ t.jsx(
|
|
1320
|
+
/* @__PURE__ */ t.jsx("div", { className: O.errorIcon, children: /* @__PURE__ */ t.jsx(Or, {}) }),
|
|
1321
1321
|
/* @__PURE__ */ t.jsx("div", { children: K })
|
|
1322
1322
|
] }) : U.length > 0 ? U.map((w, X) => /* @__PURE__ */ t.jsx(
|
|
1323
1323
|
"div",
|
|
@@ -1330,7 +1330,7 @@ function Oo({
|
|
|
1330
1330
|
onKeyDown: (ee) => {
|
|
1331
1331
|
(ee.key === "Enter" || ee.key === " ") && (ee.preventDefault(), M(w));
|
|
1332
1332
|
},
|
|
1333
|
-
children:
|
|
1333
|
+
children: mt(w)
|
|
1334
1334
|
},
|
|
1335
1335
|
`${w.street1}-${w.city}-${w.postalCode}-${X}`
|
|
1336
1336
|
)) : L && /* @__PURE__ */ t.jsx(
|
|
@@ -1339,32 +1339,32 @@ function Oo({
|
|
|
1339
1339
|
type: "button",
|
|
1340
1340
|
className: O.manualLink,
|
|
1341
1341
|
onClick: xe,
|
|
1342
|
-
children:
|
|
1342
|
+
children: h
|
|
1343
1343
|
}
|
|
1344
1344
|
)
|
|
1345
1345
|
}
|
|
1346
1346
|
)
|
|
1347
1347
|
] }),
|
|
1348
|
-
s && /* @__PURE__ */ t.jsx(
|
|
1348
|
+
s && /* @__PURE__ */ t.jsx(mr, {})
|
|
1349
1349
|
] });
|
|
1350
1350
|
}
|
|
1351
|
-
const
|
|
1352
|
-
container:
|
|
1353
|
-
title:
|
|
1354
|
-
addressCard:
|
|
1355
|
-
addressText:
|
|
1351
|
+
const Rr = "_container_rg8mk_3", Br = "_title_rg8mk_7", Mr = "_addressCard_rg8mk_16", Fr = "_addressText_rg8mk_26", $r = "_editLink_rg8mk_34", Wr = "_fieldGroup_rg8mk_47", Hr = "_fieldLabel_rg8mk_51", Vr = "_input_rg8mk_60", qr = "_checkboxRow_rg8mk_84", Gr = "_checkbox_rg8mk_84", Ur = "_checkboxLabel_rg8mk_101", Yr = "_error_rg8mk_108", Zr = "_actions_rg8mk_115", Kr = "_confirmButton_rg8mk_120", de = {
|
|
1352
|
+
container: Rr,
|
|
1353
|
+
title: Br,
|
|
1354
|
+
addressCard: Mr,
|
|
1355
|
+
addressText: Fr,
|
|
1356
1356
|
editLink: $r,
|
|
1357
|
-
fieldGroup:
|
|
1358
|
-
fieldLabel:
|
|
1359
|
-
input:
|
|
1360
|
-
checkboxRow:
|
|
1361
|
-
checkbox:
|
|
1362
|
-
checkboxLabel:
|
|
1363
|
-
error:
|
|
1364
|
-
actions:
|
|
1365
|
-
confirmButton:
|
|
1357
|
+
fieldGroup: Wr,
|
|
1358
|
+
fieldLabel: Hr,
|
|
1359
|
+
input: Vr,
|
|
1360
|
+
checkboxRow: qr,
|
|
1361
|
+
checkbox: Gr,
|
|
1362
|
+
checkboxLabel: Ur,
|
|
1363
|
+
error: Yr,
|
|
1364
|
+
actions: Zr,
|
|
1365
|
+
confirmButton: Kr
|
|
1366
1366
|
};
|
|
1367
|
-
function
|
|
1367
|
+
function zr(e) {
|
|
1368
1368
|
return `${e.street1 + (e.street2 ? ` ${e.street2}` : "")}, ${e.city}, ${e.state} ${e.postalCode}`;
|
|
1369
1369
|
}
|
|
1370
1370
|
function Ro({
|
|
@@ -1373,32 +1373,32 @@ function Ro({
|
|
|
1373
1373
|
onConfirm: a,
|
|
1374
1374
|
onEdit: s
|
|
1375
1375
|
}) {
|
|
1376
|
-
const o =
|
|
1377
|
-
if (!
|
|
1376
|
+
const o = ze(), m = Pe(r), f = It("partner-sdk-unit-input"), [d, u] = E(""), [h, p] = E(!1), [_, C] = E(null), S = () => {
|
|
1377
|
+
if (!h && !d.trim()) {
|
|
1378
1378
|
C("Please enter a unit number or select 'No unit number'");
|
|
1379
1379
|
return;
|
|
1380
1380
|
}
|
|
1381
1381
|
C(null), o.trackPlatform({
|
|
1382
1382
|
buttonClickEvent: { targetName: "partner-sdk-confirm-unit" }
|
|
1383
|
-
}), a(
|
|
1383
|
+
}), a(h ? { ...e } : { ...e, street2: d.trim() });
|
|
1384
1384
|
}, k = () => {
|
|
1385
1385
|
o.trackPlatform({
|
|
1386
1386
|
checkboxClickEvent: {
|
|
1387
1387
|
targetName: "partner-sdk-no-unit",
|
|
1388
|
-
optionName: String(!
|
|
1388
|
+
optionName: String(!h)
|
|
1389
1389
|
}
|
|
1390
|
-
}),
|
|
1390
|
+
}), p(!h), h || (u(""), C(null));
|
|
1391
1391
|
}, H = (Y) => {
|
|
1392
|
-
|
|
1392
|
+
u(Y.target.value), _ && C(null);
|
|
1393
1393
|
}, P = () => {
|
|
1394
1394
|
o.trackPlatform({
|
|
1395
1395
|
inputFocusEvent: { targetName: "partner-sdk-unit-input" }
|
|
1396
1396
|
});
|
|
1397
1397
|
};
|
|
1398
|
-
return /* @__PURE__ */ t.jsxs("div", { ref: f, style:
|
|
1398
|
+
return /* @__PURE__ */ t.jsxs("div", { ref: f, style: m, className: de.container, children: [
|
|
1399
1399
|
/* @__PURE__ */ t.jsx("h2", { className: de.title, children: "Confirm your home address" }),
|
|
1400
1400
|
/* @__PURE__ */ t.jsxs("div", { className: de.addressCard, children: [
|
|
1401
|
-
/* @__PURE__ */ t.jsx("span", { className: de.addressText, children:
|
|
1401
|
+
/* @__PURE__ */ t.jsx("span", { className: de.addressText, children: zr(e) }),
|
|
1402
1402
|
s && /* @__PURE__ */ t.jsx("button", { type: "button", className: de.editLink, onClick: s, children: "Edit" })
|
|
1403
1403
|
] }),
|
|
1404
1404
|
/* @__PURE__ */ t.jsxs("div", { className: de.fieldGroup, children: [
|
|
@@ -1410,10 +1410,10 @@ function Ro({
|
|
|
1410
1410
|
type: "text",
|
|
1411
1411
|
className: de.input,
|
|
1412
1412
|
placeholder: "#1234",
|
|
1413
|
-
value:
|
|
1413
|
+
value: d,
|
|
1414
1414
|
onChange: H,
|
|
1415
1415
|
onFocus: P,
|
|
1416
|
-
disabled:
|
|
1416
|
+
disabled: h
|
|
1417
1417
|
}
|
|
1418
1418
|
)
|
|
1419
1419
|
] }),
|
|
@@ -1423,60 +1423,60 @@ function Ro({
|
|
|
1423
1423
|
{
|
|
1424
1424
|
type: "checkbox",
|
|
1425
1425
|
className: de.checkbox,
|
|
1426
|
-
checked:
|
|
1426
|
+
checked: h,
|
|
1427
1427
|
onChange: k
|
|
1428
1428
|
}
|
|
1429
1429
|
),
|
|
1430
1430
|
/* @__PURE__ */ t.jsx("span", { className: de.checkboxLabel, children: "No unit number" })
|
|
1431
1431
|
] }),
|
|
1432
|
-
|
|
1432
|
+
_ && /* @__PURE__ */ t.jsx("p", { className: de.error, children: _ }),
|
|
1433
1433
|
/* @__PURE__ */ t.jsx("div", { className: de.actions, children: /* @__PURE__ */ t.jsx(
|
|
1434
1434
|
"button",
|
|
1435
1435
|
{
|
|
1436
1436
|
type: "button",
|
|
1437
1437
|
className: de.confirmButton,
|
|
1438
|
-
onClick:
|
|
1438
|
+
onClick: S,
|
|
1439
1439
|
children: "Confirm address"
|
|
1440
1440
|
}
|
|
1441
1441
|
) })
|
|
1442
1442
|
] });
|
|
1443
1443
|
}
|
|
1444
|
-
const
|
|
1445
|
-
function
|
|
1444
|
+
const Jr = "https://api.mapbox.com/geocoding/v5/mapbox.places", Xr = "https://api.mapbox.com/styles/v1/mapbox/light-v11/static", Qr = "pk.eyJ1Ijoib3BlbmRvb3IiLCJhIjoiWXJ2bTJiRSJ9.lsnjT9yTNyyVzKRIzqxnqg", en = "https://images.opendoor.com/source/s3/imgdrop-production/2026-02-1771546296495-06570.png?service=partner-sdk", tn = 640, rn = 320, nn = 14;
|
|
1445
|
+
function an(e, r, a) {
|
|
1446
1446
|
return e.startsWith("http://") || e.startsWith("https://") ? `url-${encodeURIComponent(e)}(${r},${a})` : `${e}(${r},${a})`;
|
|
1447
1447
|
}
|
|
1448
|
-
function
|
|
1449
|
-
const a = (r == null ? void 0 : r.mapboxAccessToken) ??
|
|
1448
|
+
function sn(e, r) {
|
|
1449
|
+
const a = (r == null ? void 0 : r.mapboxAccessToken) ?? Qr, s = (r == null ? void 0 : r.mapPinMarker) ?? en, o = (r == null ? void 0 : r.width) ?? tn, i = (r == null ? void 0 : r.height) ?? rn, m = (r == null ? void 0 : r.zoom) ?? nn, [f, d] = E(void 0), [u, h] = E("loading");
|
|
1450
1450
|
return se(() => {
|
|
1451
|
-
|
|
1452
|
-
const
|
|
1451
|
+
h("loading");
|
|
1452
|
+
const p = [
|
|
1453
1453
|
e.street1,
|
|
1454
1454
|
e.city,
|
|
1455
1455
|
e.state,
|
|
1456
1456
|
e.postalCode
|
|
1457
1457
|
].join(" ");
|
|
1458
|
-
let
|
|
1458
|
+
let _ = !1;
|
|
1459
1459
|
async function C() {
|
|
1460
|
-
var
|
|
1460
|
+
var S, k;
|
|
1461
1461
|
try {
|
|
1462
|
-
const H = `${
|
|
1463
|
-
if (!P.ok ||
|
|
1464
|
-
|
|
1462
|
+
const H = `${Jr}/${encodeURIComponent(p)}.json?access_token=${a}&limit=1`, P = await fetch(H);
|
|
1463
|
+
if (!P.ok || _) {
|
|
1464
|
+
_ || h("error");
|
|
1465
1465
|
return;
|
|
1466
1466
|
}
|
|
1467
|
-
const j = (k = (
|
|
1468
|
-
if (!j ||
|
|
1469
|
-
|
|
1467
|
+
const j = (k = (S = (await P.json()).features) == null ? void 0 : S[0]) == null ? void 0 : k.center;
|
|
1468
|
+
if (!j || _) {
|
|
1469
|
+
_ || h("error");
|
|
1470
1470
|
return;
|
|
1471
1471
|
}
|
|
1472
|
-
const [ne,
|
|
1473
|
-
|
|
1472
|
+
const [ne, F] = j, oe = an(s, ne, F), U = `${Xr}/${oe}/${ne},${F},${m}/${o}x${i}@2x?access_token=${a}&attribution=false&logo=false`;
|
|
1473
|
+
_ || d(U);
|
|
1474
1474
|
} catch {
|
|
1475
|
-
|
|
1475
|
+
_ || h("error");
|
|
1476
1476
|
}
|
|
1477
1477
|
}
|
|
1478
1478
|
return C(), () => {
|
|
1479
|
-
|
|
1479
|
+
_ = !0;
|
|
1480
1480
|
};
|
|
1481
1481
|
}, [
|
|
1482
1482
|
e.street1,
|
|
@@ -1487,13 +1487,13 @@ function an(e, r) {
|
|
|
1487
1487
|
s,
|
|
1488
1488
|
o,
|
|
1489
1489
|
i,
|
|
1490
|
-
|
|
1491
|
-
]), { url: f, status:
|
|
1490
|
+
m
|
|
1491
|
+
]), { url: f, status: u };
|
|
1492
1492
|
}
|
|
1493
|
-
const
|
|
1494
|
-
container:
|
|
1495
|
-
mapImage:
|
|
1496
|
-
mapImageLoaded:
|
|
1493
|
+
const on = "_container_1vap7_3", ln = "_mapImage_1vap7_13", cn = "_mapImageLoaded_1vap7_22", Ve = {
|
|
1494
|
+
container: on,
|
|
1495
|
+
mapImage: ln,
|
|
1496
|
+
mapImageLoaded: cn
|
|
1497
1497
|
};
|
|
1498
1498
|
function Bo({
|
|
1499
1499
|
address: e,
|
|
@@ -1502,56 +1502,56 @@ function Bo({
|
|
|
1502
1502
|
mapPinMarker: s,
|
|
1503
1503
|
width: o,
|
|
1504
1504
|
height: i,
|
|
1505
|
-
zoom:
|
|
1505
|
+
zoom: m,
|
|
1506
1506
|
borderRadius: f,
|
|
1507
|
-
onLoad:
|
|
1508
|
-
onError:
|
|
1507
|
+
onLoad: d,
|
|
1508
|
+
onError: u
|
|
1509
1509
|
}) {
|
|
1510
|
-
const
|
|
1510
|
+
const h = Pe(r), { url: p, status: _ } = sn(e, {
|
|
1511
1511
|
mapboxAccessToken: a,
|
|
1512
1512
|
mapPinMarker: s,
|
|
1513
1513
|
width: o,
|
|
1514
1514
|
height: i,
|
|
1515
|
-
zoom:
|
|
1516
|
-
}), [C,
|
|
1517
|
-
k.current =
|
|
1518
|
-
const H = G(
|
|
1519
|
-
H.current =
|
|
1515
|
+
zoom: m
|
|
1516
|
+
}), [C, S] = E(!1), k = G(d);
|
|
1517
|
+
k.current = d;
|
|
1518
|
+
const H = G(u);
|
|
1519
|
+
H.current = u, se(() => {
|
|
1520
1520
|
var j;
|
|
1521
|
-
|
|
1522
|
-
}, [
|
|
1521
|
+
_ === "error" && ((j = H.current) == null || j.call(H, new Error("Failed to load map for address")));
|
|
1522
|
+
}, [_]);
|
|
1523
1523
|
const P = () => {
|
|
1524
1524
|
var j;
|
|
1525
|
-
|
|
1525
|
+
S(!0), (j = k.current) == null || j.call(k);
|
|
1526
1526
|
}, Y = {
|
|
1527
|
-
...
|
|
1527
|
+
...h,
|
|
1528
1528
|
...f ? { borderRadius: f } : {}
|
|
1529
1529
|
};
|
|
1530
|
-
return /* @__PURE__ */ t.jsx("div", { className: Ve.container, style: Y, children:
|
|
1530
|
+
return /* @__PURE__ */ t.jsx("div", { className: Ve.container, style: Y, children: p && /* @__PURE__ */ t.jsx(
|
|
1531
1531
|
"img",
|
|
1532
1532
|
{
|
|
1533
|
-
src:
|
|
1533
|
+
src: p,
|
|
1534
1534
|
alt: "Map",
|
|
1535
1535
|
className: `${Ve.mapImage} ${C ? Ve.mapImageLoaded : ""}`.trim(),
|
|
1536
1536
|
onLoad: P
|
|
1537
1537
|
}
|
|
1538
1538
|
) });
|
|
1539
1539
|
}
|
|
1540
|
-
function
|
|
1540
|
+
function un(e) {
|
|
1541
1541
|
return "field" in e;
|
|
1542
1542
|
}
|
|
1543
|
-
function
|
|
1543
|
+
function dn(e) {
|
|
1544
1544
|
return "and" in e;
|
|
1545
1545
|
}
|
|
1546
|
-
function
|
|
1546
|
+
function hn(e) {
|
|
1547
1547
|
return "or" in e;
|
|
1548
1548
|
}
|
|
1549
|
-
function
|
|
1550
|
-
if (un(e))
|
|
1551
|
-
return e.and.every((a) => De(a, r));
|
|
1549
|
+
function Ae(e, r) {
|
|
1552
1550
|
if (dn(e))
|
|
1553
|
-
return e.
|
|
1554
|
-
if (
|
|
1551
|
+
return e.and.every((a) => Ae(a, r));
|
|
1552
|
+
if (hn(e))
|
|
1553
|
+
return e.or.some((a) => Ae(a, r));
|
|
1554
|
+
if (un(e)) {
|
|
1555
1555
|
const a = r(e.field);
|
|
1556
1556
|
switch (e.op) {
|
|
1557
1557
|
case "eq":
|
|
@@ -1574,11 +1574,11 @@ function De(e, r) {
|
|
|
1574
1574
|
}
|
|
1575
1575
|
return !1;
|
|
1576
1576
|
}
|
|
1577
|
-
function
|
|
1578
|
-
return e.questions.filter((a) => !a.showWhen ||
|
|
1577
|
+
function Ue(e, r) {
|
|
1578
|
+
return e.questions.filter((a) => !a.showWhen || Ae(a.showWhen, r));
|
|
1579
1579
|
}
|
|
1580
|
-
function
|
|
1581
|
-
return e.filter((a) => !a.showWhen ||
|
|
1580
|
+
function pt(e, r) {
|
|
1581
|
+
return e.filter((a) => !a.showWhen || Ae(a.showWhen, r));
|
|
1582
1582
|
}
|
|
1583
1583
|
function fn(e, r) {
|
|
1584
1584
|
const a = typeof r == "string" && r.trim() === "";
|
|
@@ -1599,11 +1599,11 @@ function fn(e, r) {
|
|
|
1599
1599
|
return e.validate(r);
|
|
1600
1600
|
}
|
|
1601
1601
|
}
|
|
1602
|
-
function
|
|
1603
|
-
const a = {}, s =
|
|
1602
|
+
function gt(e, r) {
|
|
1603
|
+
const a = {}, s = Ue(e, r);
|
|
1604
1604
|
for (const o of s) {
|
|
1605
|
-
const i = r(o.key),
|
|
1606
|
-
|
|
1605
|
+
const i = r(o.key), m = fn(o, i);
|
|
1606
|
+
m && (a[o.key] = m);
|
|
1607
1607
|
}
|
|
1608
1608
|
return {
|
|
1609
1609
|
valid: Object.keys(a).length === 0,
|
|
@@ -1622,7 +1622,7 @@ class mn {
|
|
|
1622
1622
|
* conditions and the partner-supplied `skipPages` allowlist.
|
|
1623
1623
|
*/
|
|
1624
1624
|
get visiblePages() {
|
|
1625
|
-
const r =
|
|
1625
|
+
const r = pt(this._allPages, this.getAnswer);
|
|
1626
1626
|
return this._skipPages.size === 0 ? r : r.filter((a) => !this._skipPages.has(a.id));
|
|
1627
1627
|
}
|
|
1628
1628
|
/** The current page, or undefined if no pages are visible. */
|
|
@@ -1669,7 +1669,7 @@ class mn {
|
|
|
1669
1669
|
const { [r]: s, ...o } = this._validationErrors;
|
|
1670
1670
|
this._validationErrors = o;
|
|
1671
1671
|
}
|
|
1672
|
-
this.emit({ type: "answerChange", key: r, value: a }), this.recoverIfCurrentPageHidden();
|
|
1672
|
+
this.pruneAnswersForHiddenQuestions(), this.emit({ type: "answerChange", key: r, value: a }), this.recoverIfCurrentPageHidden();
|
|
1673
1673
|
}
|
|
1674
1674
|
/**
|
|
1675
1675
|
* Set multiple answers at once (e.g., for initial data prefill).
|
|
@@ -1682,6 +1682,7 @@ class mn {
|
|
|
1682
1682
|
const { [s]: o, ...i } = this._validationErrors;
|
|
1683
1683
|
this._validationErrors = i;
|
|
1684
1684
|
}
|
|
1685
|
+
this.pruneAnswersForHiddenQuestions();
|
|
1685
1686
|
const a = Object.keys(r);
|
|
1686
1687
|
if (a.length > 0) {
|
|
1687
1688
|
const s = a[a.length - 1];
|
|
@@ -1705,7 +1706,7 @@ class mn {
|
|
|
1705
1706
|
const r = this.currentPage;
|
|
1706
1707
|
if (!r)
|
|
1707
1708
|
return { valid: !1, errors: { _page: "No current page" } };
|
|
1708
|
-
const a =
|
|
1709
|
+
const a = gt(r, this.getAnswer);
|
|
1709
1710
|
if (!a.valid)
|
|
1710
1711
|
return this._validationErrors = a.errors, this.emit({ type: "validationError", errors: a.errors }), a;
|
|
1711
1712
|
if (this._validationErrors = {}, this.isLastPage)
|
|
@@ -1744,14 +1745,14 @@ class mn {
|
|
|
1744
1745
|
*/
|
|
1745
1746
|
validate() {
|
|
1746
1747
|
const r = this.currentPage;
|
|
1747
|
-
return r ?
|
|
1748
|
+
return r ? gt(r, this.getAnswer) : { valid: !1, errors: { _page: "No current page" } };
|
|
1748
1749
|
}
|
|
1749
1750
|
/**
|
|
1750
1751
|
* Get visible questions on the current page (filtered by showWhen).
|
|
1751
1752
|
*/
|
|
1752
1753
|
getVisibleQuestionsForCurrentPage() {
|
|
1753
1754
|
const r = this.currentPage;
|
|
1754
|
-
return r ?
|
|
1755
|
+
return r ? Ue(r, this.getAnswer) : [];
|
|
1755
1756
|
}
|
|
1756
1757
|
// ── Events ────────────────────────────────────────────────────────────────
|
|
1757
1758
|
/**
|
|
@@ -1776,6 +1777,38 @@ class mn {
|
|
|
1776
1777
|
for (const s of a)
|
|
1777
1778
|
s(r);
|
|
1778
1779
|
}
|
|
1780
|
+
/**
|
|
1781
|
+
* Delete answers belonging to questions hidden by a `showWhen` condition —
|
|
1782
|
+
* either on the question itself or on its page. Prevents stale follow-up
|
|
1783
|
+
* answers (e.g., the "describe your relationship" text typed before the
|
|
1784
|
+
* seller backtracked from "Other" to "Self") from being submitted alongside
|
|
1785
|
+
* the new answer.
|
|
1786
|
+
*
|
|
1787
|
+
* Answers for pages in the partner-supplied `skipPages` set are preserved
|
|
1788
|
+
* unconditionally — partners use `initialAnswers` together with `skipPages`
|
|
1789
|
+
* to inject answers for questions their UI never shows, and the engine
|
|
1790
|
+
* must not delete those.
|
|
1791
|
+
*/
|
|
1792
|
+
pruneAnswersForHiddenQuestions() {
|
|
1793
|
+
const r = pt(this._allPages, this.getAnswer), a = /* @__PURE__ */ new Set(), s = /* @__PURE__ */ new Set();
|
|
1794
|
+
for (const m of this._allPages) {
|
|
1795
|
+
for (const u of m.questions)
|
|
1796
|
+
a.add(u.key);
|
|
1797
|
+
if (this._skipPages.has(m.id)) {
|
|
1798
|
+
for (const u of m.questions)
|
|
1799
|
+
s.add(u.key);
|
|
1800
|
+
continue;
|
|
1801
|
+
}
|
|
1802
|
+
if (r.some((u) => u.id === m.id))
|
|
1803
|
+
for (const u of Ue(m, this.getAnswer))
|
|
1804
|
+
s.add(u.key);
|
|
1805
|
+
}
|
|
1806
|
+
let o = !1;
|
|
1807
|
+
const i = {};
|
|
1808
|
+
for (const [m, f] of Object.entries(this._answers))
|
|
1809
|
+
!a.has(m) || s.has(m) ? i[m] = f : o = !0;
|
|
1810
|
+
o && (this._answers = i);
|
|
1811
|
+
}
|
|
1779
1812
|
/**
|
|
1780
1813
|
* If the current page became hidden (answer change removed it from visible pages),
|
|
1781
1814
|
* auto-correct to the nearest visible page. Emits pageChange if corrected.
|
|
@@ -1787,7 +1820,7 @@ class mn {
|
|
|
1787
1820
|
const a = this._allPages.findIndex((o) => o.id === this._currentPageId);
|
|
1788
1821
|
let s = r[0];
|
|
1789
1822
|
for (const o of r)
|
|
1790
|
-
this._allPages.findIndex((
|
|
1823
|
+
this._allPages.findIndex((m) => m.id === o.id) <= a && (s = o);
|
|
1791
1824
|
this._currentPageId = s.id, this.emit({
|
|
1792
1825
|
type: "pageChange",
|
|
1793
1826
|
pageIndex: this.currentPageIndex,
|
|
@@ -1796,7 +1829,7 @@ class mn {
|
|
|
1796
1829
|
}
|
|
1797
1830
|
}
|
|
1798
1831
|
const pn = /^[^\s@]+@[^\s@]+\.[^\s@]+$/;
|
|
1799
|
-
function
|
|
1832
|
+
function St(e) {
|
|
1800
1833
|
if (typeof e == "string" && !pn.test(e))
|
|
1801
1834
|
return "Please enter a valid email address";
|
|
1802
1835
|
}
|
|
@@ -2001,7 +2034,6 @@ const _n = {
|
|
|
2001
2034
|
}, bn = {
|
|
2002
2035
|
id: "ownership",
|
|
2003
2036
|
title: "Are you the owner of this home?",
|
|
2004
|
-
subtitle: "We have additional questions if you're an agent.",
|
|
2005
2037
|
questions: [
|
|
2006
2038
|
{
|
|
2007
2039
|
key: "seller.relation_to_owner",
|
|
@@ -2009,11 +2041,32 @@ const _n = {
|
|
|
2009
2041
|
type: "string",
|
|
2010
2042
|
style: "radio-card",
|
|
2011
2043
|
required: !0,
|
|
2012
|
-
autoAdvance: !0,
|
|
2013
2044
|
options: [
|
|
2014
2045
|
{ label: "Yes, I own this home", value: "self" },
|
|
2015
|
-
{ label: "No, I'm an agent", value: "agent" }
|
|
2046
|
+
{ label: "No, I'm an agent", value: "agent" },
|
|
2047
|
+
{
|
|
2048
|
+
label: "I'm an agent, and I own this home",
|
|
2049
|
+
value: "agent_and_owner"
|
|
2050
|
+
},
|
|
2051
|
+
{ label: "Other", value: "other" }
|
|
2016
2052
|
]
|
|
2053
|
+
},
|
|
2054
|
+
// Reception-fe shows a free-text follow-up inline when the seller picks
|
|
2055
|
+
// "Other"; mirror that here as a second question on the same page rather
|
|
2056
|
+
// than a separate conditional page. autoAdvance is dropped from the radio
|
|
2057
|
+
// above because it would fire before the seller could type the follow-up.
|
|
2058
|
+
{
|
|
2059
|
+
key: "seller.relation_to_owner.other",
|
|
2060
|
+
label: "Describe your relationship to this home",
|
|
2061
|
+
type: "string",
|
|
2062
|
+
style: "input",
|
|
2063
|
+
required: !0,
|
|
2064
|
+
placeholder: "e.g., executor of the estate",
|
|
2065
|
+
showWhen: {
|
|
2066
|
+
field: "seller.relation_to_owner",
|
|
2067
|
+
op: "eq",
|
|
2068
|
+
value: "other"
|
|
2069
|
+
}
|
|
2017
2070
|
}
|
|
2018
2071
|
]
|
|
2019
2072
|
}, yn = {
|
|
@@ -2120,7 +2173,7 @@ const wn = Oe("kitchen", "home.kitchen_seller_score", "How would you describe yo
|
|
|
2120
2173
|
]
|
|
2121
2174
|
}
|
|
2122
2175
|
]
|
|
2123
|
-
},
|
|
2176
|
+
}, Sn = {
|
|
2124
2177
|
id: "hoa-type",
|
|
2125
2178
|
title: "Does your home belong to any of these types of communities?",
|
|
2126
2179
|
showWhen: { field: "home.hoa", op: "eq", value: "yes" },
|
|
@@ -2141,7 +2194,7 @@ const wn = Oe("kitchen", "home.kitchen_seller_score", "How would you describe yo
|
|
|
2141
2194
|
]
|
|
2142
2195
|
}
|
|
2143
2196
|
]
|
|
2144
|
-
},
|
|
2197
|
+
}, En = {
|
|
2145
2198
|
id: "hoa-guard",
|
|
2146
2199
|
title: "Is there a guard at the entrance?",
|
|
2147
2200
|
showWhen: {
|
|
@@ -2252,7 +2305,7 @@ const wn = Oe("kitchen", "home.kitchen_seller_score", "How would you describe yo
|
|
|
2252
2305
|
]
|
|
2253
2306
|
}
|
|
2254
2307
|
]
|
|
2255
|
-
},
|
|
2308
|
+
}, An = {
|
|
2256
2309
|
id: "homebuilder",
|
|
2257
2310
|
title: "Are you working with a homebuilder?",
|
|
2258
2311
|
subtitle: "We can work with them to line up your close dates.",
|
|
@@ -2270,7 +2323,7 @@ const wn = Oe("kitchen", "home.kitchen_seller_score", "How would you describe yo
|
|
|
2270
2323
|
]
|
|
2271
2324
|
}
|
|
2272
2325
|
]
|
|
2273
|
-
},
|
|
2326
|
+
}, Dn = {
|
|
2274
2327
|
id: "homebuilder-name",
|
|
2275
2328
|
title: "Which homebuilder are you working with?",
|
|
2276
2329
|
showWhen: {
|
|
@@ -2305,7 +2358,7 @@ const wn = Oe("kitchen", "home.kitchen_seller_score", "How would you describe yo
|
|
|
2305
2358
|
style: "email",
|
|
2306
2359
|
required: !1,
|
|
2307
2360
|
placeholder: "you@example.com",
|
|
2308
|
-
validate:
|
|
2361
|
+
validate: St
|
|
2309
2362
|
},
|
|
2310
2363
|
{
|
|
2311
2364
|
key: "seller.home_builder_community",
|
|
@@ -2337,7 +2390,7 @@ const wn = Oe("kitchen", "home.kitchen_seller_score", "How would you describe yo
|
|
|
2337
2390
|
style: "email",
|
|
2338
2391
|
required: !0,
|
|
2339
2392
|
placeholder: "you@example.com",
|
|
2340
|
-
validate:
|
|
2393
|
+
validate: St
|
|
2341
2394
|
},
|
|
2342
2395
|
{
|
|
2343
2396
|
key: "seller.phone_number",
|
|
@@ -2365,22 +2418,22 @@ const wn = Oe("kitchen", "home.kitchen_seller_score", "How would you describe yo
|
|
|
2365
2418
|
jn,
|
|
2366
2419
|
Nn,
|
|
2367
2420
|
In,
|
|
2368
|
-
En,
|
|
2369
2421
|
Sn,
|
|
2422
|
+
En,
|
|
2370
2423
|
Pn,
|
|
2371
2424
|
Ln,
|
|
2372
2425
|
Tn,
|
|
2373
|
-
Dn,
|
|
2374
2426
|
An,
|
|
2427
|
+
Dn,
|
|
2375
2428
|
On,
|
|
2376
2429
|
Rn
|
|
2377
2430
|
];
|
|
2378
|
-
function
|
|
2431
|
+
function _t(e) {
|
|
2379
2432
|
return new mn(Bn, e);
|
|
2380
2433
|
}
|
|
2381
|
-
const Et =
|
|
2434
|
+
const Et = Ye(null);
|
|
2382
2435
|
function fe() {
|
|
2383
|
-
const e =
|
|
2436
|
+
const e = De(Et);
|
|
2384
2437
|
if (!e)
|
|
2385
2438
|
throw new Error(
|
|
2386
2439
|
"useDtc must be used within a <DtcOnboardingFlow> component"
|
|
@@ -2394,33 +2447,33 @@ const Mn = ({
|
|
|
2394
2447
|
contactConsentText: s,
|
|
2395
2448
|
onSubmit: o,
|
|
2396
2449
|
onPageChange: i,
|
|
2397
|
-
onAnswerChange:
|
|
2450
|
+
onAnswerChange: m,
|
|
2398
2451
|
onReady: f,
|
|
2399
|
-
onError:
|
|
2400
|
-
children:
|
|
2452
|
+
onError: d,
|
|
2453
|
+
children: u
|
|
2401
2454
|
}) => {
|
|
2402
2455
|
var v;
|
|
2403
|
-
const
|
|
2404
|
-
|
|
2405
|
-
const
|
|
2406
|
-
|
|
2407
|
-
const
|
|
2408
|
-
|
|
2456
|
+
const h = G(o);
|
|
2457
|
+
h.current = o;
|
|
2458
|
+
const p = G(i);
|
|
2459
|
+
p.current = i;
|
|
2460
|
+
const _ = G(m);
|
|
2461
|
+
_.current = m;
|
|
2409
2462
|
const C = G(f);
|
|
2410
2463
|
C.current = f;
|
|
2411
|
-
const
|
|
2412
|
-
|
|
2413
|
-
const [k, H] =
|
|
2414
|
-
() =>
|
|
2464
|
+
const S = G(d);
|
|
2465
|
+
S.current = d;
|
|
2466
|
+
const [k, H] = E(
|
|
2467
|
+
() => _t({ initialAnswers: e, skipPages: r })
|
|
2415
2468
|
), P = (r ?? []).join("|"), Y = G(P);
|
|
2416
2469
|
se(() => {
|
|
2417
|
-
P !== Y.current && (Y.current = P, H(
|
|
2470
|
+
P !== Y.current && (Y.current = P, H(_t({ initialAnswers: e, skipPages: r })));
|
|
2418
2471
|
}, [P]);
|
|
2419
|
-
const [j, ne] =
|
|
2472
|
+
const [j, ne] = E(
|
|
2420
2473
|
k.answers
|
|
2421
|
-
), [
|
|
2474
|
+
), [F, oe] = E(
|
|
2422
2475
|
((v = k.currentPage) == null ? void 0 : v.id) ?? ""
|
|
2423
|
-
), [U,
|
|
2476
|
+
), [U, A] = E({}), [$, Z] = E(
|
|
2424
2477
|
k.visiblePages
|
|
2425
2478
|
);
|
|
2426
2479
|
se(() => {
|
|
@@ -2428,17 +2481,17 @@ const Mn = ({
|
|
|
2428
2481
|
const x = [
|
|
2429
2482
|
k.on("answerChange", (R) => {
|
|
2430
2483
|
var J;
|
|
2431
|
-
ne(k.answers), Z([...k.visiblePages]), R.type === "answerChange" && ((J =
|
|
2484
|
+
ne(k.answers), Z([...k.visiblePages]), R.type === "answerChange" && ((J = _.current) == null || J.call(_, R.key, R.value));
|
|
2432
2485
|
}),
|
|
2433
2486
|
k.on("pageChange", (R) => {
|
|
2434
2487
|
var J;
|
|
2435
|
-
R.type === "pageChange" && (oe(R.pageId), Z([...k.visiblePages]),
|
|
2488
|
+
R.type === "pageChange" && (oe(R.pageId), Z([...k.visiblePages]), A({}), (J = p.current) == null || J.call(p, R.pageIndex, R.pageId));
|
|
2436
2489
|
}),
|
|
2437
2490
|
k.on("validationError", (R) => {
|
|
2438
|
-
R.type === "validationError" &&
|
|
2491
|
+
R.type === "validationError" && A(R.errors);
|
|
2439
2492
|
}),
|
|
2440
2493
|
k.on("submit", (R) => {
|
|
2441
|
-
R.type === "submit" &&
|
|
2494
|
+
R.type === "submit" && h.current(R.answers);
|
|
2442
2495
|
})
|
|
2443
2496
|
];
|
|
2444
2497
|
return (y = C.current) == null || y.call(C), () => {
|
|
@@ -2449,25 +2502,25 @@ const Mn = ({
|
|
|
2449
2502
|
se(() => {
|
|
2450
2503
|
e && e !== ae.current && (ae.current = e, k.setAnswers(e));
|
|
2451
2504
|
}, [e, k]);
|
|
2452
|
-
const z =
|
|
2453
|
-
const x =
|
|
2505
|
+
const z = Se(() => {
|
|
2506
|
+
const x = $.findIndex((y) => y.id === F);
|
|
2454
2507
|
return x >= 0 ? x : 0;
|
|
2455
|
-
}, [F
|
|
2508
|
+
}, [$, F]), K = $[z], q = Se(() => F ? k.getVisibleQuestionsForCurrentPage() : [], [k, F, j]), ie = Se(() => $.length <= 1 ? 0 : Math.min(
|
|
2456
2509
|
1,
|
|
2457
|
-
Math.max(0, z / (
|
|
2458
|
-
), [z,
|
|
2510
|
+
Math.max(0, z / ($.length - 1))
|
|
2511
|
+
), [z, $.length]), ue = Se(
|
|
2459
2512
|
() => ({
|
|
2460
2513
|
engine: k,
|
|
2461
2514
|
currentPage: K,
|
|
2462
2515
|
currentPageIndex: z,
|
|
2463
|
-
visiblePages:
|
|
2516
|
+
visiblePages: $,
|
|
2464
2517
|
visibleQuestions: q,
|
|
2465
2518
|
answers: j,
|
|
2466
2519
|
validationErrors: U,
|
|
2467
2520
|
progress: ie,
|
|
2468
2521
|
isFirstPage: z === 0,
|
|
2469
2522
|
contactConsentText: s,
|
|
2470
|
-
isLastPage:
|
|
2523
|
+
isLastPage: $.length > 0 && z === $.length - 1,
|
|
2471
2524
|
setAnswer: (x, y) => k.setAnswer(x, y),
|
|
2472
2525
|
getAnswer: k.getAnswer,
|
|
2473
2526
|
goToNext: () => {
|
|
@@ -2475,8 +2528,8 @@ const Mn = ({
|
|
|
2475
2528
|
const x = k.goToNext();
|
|
2476
2529
|
if (!x.valid)
|
|
2477
2530
|
try {
|
|
2478
|
-
(y =
|
|
2479
|
-
|
|
2531
|
+
(y = S.current) == null || y.call(
|
|
2532
|
+
S,
|
|
2480
2533
|
new Error(
|
|
2481
2534
|
`Validation failed: ${Object.values(x.errors).join(", ")}`
|
|
2482
2535
|
)
|
|
@@ -2492,7 +2545,7 @@ const Mn = ({
|
|
|
2492
2545
|
k,
|
|
2493
2546
|
K,
|
|
2494
2547
|
z,
|
|
2495
|
-
|
|
2548
|
+
$,
|
|
2496
2549
|
q,
|
|
2497
2550
|
j,
|
|
2498
2551
|
U,
|
|
@@ -2501,10 +2554,10 @@ const Mn = ({
|
|
|
2501
2554
|
s
|
|
2502
2555
|
]
|
|
2503
2556
|
);
|
|
2504
|
-
return /* @__PURE__ */ t.jsx(Et.Provider, { value: ue, children:
|
|
2505
|
-
},
|
|
2506
|
-
container:
|
|
2507
|
-
header:
|
|
2557
|
+
return /* @__PURE__ */ t.jsx(Et.Provider, { value: ue, children: u });
|
|
2558
|
+
}, Fn = "_container_uharh_7", $n = "_header_uharh_20", Wn = "_headerLogos_uharh_30", Hn = "_headerPartnerLogo_uharh_36", Vn = "_headerOpendoorLogo_uharh_42", qn = "_headerCloseButton_uharh_46", Gn = "_layout_uharh_71", Un = "_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", Sa = "_fieldError_uharh_470", Ea = "_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", Fa = "_currencyInput_uharh_569", $a = "_consentText_uharh_589", Wa = "_consentLink_uharh_597", Ha = "_ctaButton_uharh_602", Va = "_toggleGroup_uharh_634", qa = "_toggleLabel_uharh_638", Ga = "_toggleCheckbox_uharh_646", Ua = "_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 = {
|
|
2559
|
+
container: Fn,
|
|
2560
|
+
header: $n,
|
|
2508
2561
|
headerLogos: Wn,
|
|
2509
2562
|
headerPartnerLogo: Hn,
|
|
2510
2563
|
headerOpendoorLogo: Vn,
|
|
@@ -2546,19 +2599,19 @@ const Mn = ({
|
|
|
2546
2599
|
fieldInput: ja,
|
|
2547
2600
|
fieldInputError: Na,
|
|
2548
2601
|
fieldSuffix: Ia,
|
|
2549
|
-
fieldError:
|
|
2550
|
-
checkboxCardGroup:
|
|
2602
|
+
fieldError: Sa,
|
|
2603
|
+
checkboxCardGroup: Ea,
|
|
2551
2604
|
checkboxCard: Pa,
|
|
2552
2605
|
checkboxCardSelected: La,
|
|
2553
2606
|
checkboxCardContent: Ta,
|
|
2554
|
-
checkboxCardLabel:
|
|
2555
|
-
checkboxCardHelper:
|
|
2607
|
+
checkboxCardLabel: Aa,
|
|
2608
|
+
checkboxCardHelper: Da,
|
|
2556
2609
|
checkboxIndicator: Oa,
|
|
2557
2610
|
checkboxIndicatorChecked: Ra,
|
|
2558
2611
|
currencyWrapper: Ba,
|
|
2559
2612
|
currencyPrefix: Ma,
|
|
2560
|
-
currencyInput:
|
|
2561
|
-
consentText:
|
|
2613
|
+
currencyInput: Fa,
|
|
2614
|
+
consentText: $a,
|
|
2562
2615
|
consentLink: Wa,
|
|
2563
2616
|
ctaButton: Ha,
|
|
2564
2617
|
toggleGroup: Va,
|
|
@@ -2685,28 +2738,28 @@ const Mn = ({
|
|
|
2685
2738
|
] })
|
|
2686
2739
|
] });
|
|
2687
2740
|
}, as = ({ question: e }) => {
|
|
2688
|
-
var
|
|
2689
|
-
const { getAnswer: r, setAnswer: a, goToNext: s, validationErrors: o } = fe(), i = r(e.key),
|
|
2741
|
+
var h;
|
|
2742
|
+
const { getAnswer: r, setAnswer: a, goToNext: s, validationErrors: o } = fe(), i = r(e.key), m = o[e.key], f = G(null);
|
|
2690
2743
|
se(() => () => {
|
|
2691
2744
|
f.current && clearTimeout(f.current);
|
|
2692
2745
|
}, []);
|
|
2693
|
-
const
|
|
2694
|
-
(
|
|
2695
|
-
a(e.key,
|
|
2746
|
+
const d = Ee(
|
|
2747
|
+
(p) => {
|
|
2748
|
+
a(e.key, p), e.autoAdvance && (f.current && clearTimeout(f.current), f.current = setTimeout(() => s(), 150));
|
|
2696
2749
|
},
|
|
2697
2750
|
[e.key, e.autoAdvance, a, s]
|
|
2698
|
-
),
|
|
2699
|
-
(
|
|
2751
|
+
), u = Ee(
|
|
2752
|
+
(p, _) => {
|
|
2700
2753
|
var k, H;
|
|
2701
2754
|
const C = e.options;
|
|
2702
2755
|
if (!C) return;
|
|
2703
|
-
let
|
|
2704
|
-
if (
|
|
2705
|
-
const P = (k =
|
|
2706
|
-
(H = P == null ? void 0 : P[
|
|
2756
|
+
let S = null;
|
|
2757
|
+
if (p.key === "ArrowDown" || p.key === "ArrowRight" ? (p.preventDefault(), S = (_ + 1) % C.length) : (p.key === "ArrowUp" || p.key === "ArrowLeft") && (p.preventDefault(), S = (_ - 1 + C.length) % C.length), S !== null) {
|
|
2758
|
+
const P = (k = p.currentTarget.closest('[role="radiogroup"]')) == null ? void 0 : k.querySelectorAll('[role="radio"]');
|
|
2759
|
+
(H = P == null ? void 0 : P[S]) == null || H.focus(), d(C[S].value);
|
|
2707
2760
|
}
|
|
2708
2761
|
},
|
|
2709
|
-
[e.options,
|
|
2762
|
+
[e.options, d]
|
|
2710
2763
|
);
|
|
2711
2764
|
return /* @__PURE__ */ t.jsxs(
|
|
2712
2765
|
"div",
|
|
@@ -2715,27 +2768,27 @@ const Mn = ({
|
|
|
2715
2768
|
role: "radiogroup",
|
|
2716
2769
|
"aria-label": e.label,
|
|
2717
2770
|
children: [
|
|
2718
|
-
(
|
|
2719
|
-
const C = i ===
|
|
2771
|
+
(h = e.options) == null ? void 0 : h.map((p, _) => {
|
|
2772
|
+
const C = i === p.value;
|
|
2720
2773
|
return /* @__PURE__ */ t.jsxs(
|
|
2721
2774
|
"button",
|
|
2722
2775
|
{
|
|
2723
2776
|
type: "button",
|
|
2724
2777
|
role: "radio",
|
|
2725
2778
|
"aria-checked": C,
|
|
2726
|
-
tabIndex: C ||
|
|
2779
|
+
tabIndex: C || _ === 0 && !i ? 0 : -1,
|
|
2727
2780
|
className: `${l.radioCard} ${C ? l.radioCardSelected : ""}`,
|
|
2728
|
-
onClick: () =>
|
|
2729
|
-
onKeyDown: (
|
|
2781
|
+
onClick: () => d(p.value),
|
|
2782
|
+
onKeyDown: (S) => u(S, _),
|
|
2730
2783
|
children: [
|
|
2731
|
-
/* @__PURE__ */ t.jsx("span", { className: l.radioCardLabel, children:
|
|
2732
|
-
|
|
2784
|
+
/* @__PURE__ */ t.jsx("span", { className: l.radioCardLabel, children: p.label }),
|
|
2785
|
+
p.description && /* @__PURE__ */ t.jsx("span", { className: l.radioCardDescription, children: p.description })
|
|
2733
2786
|
]
|
|
2734
2787
|
},
|
|
2735
|
-
String(
|
|
2788
|
+
String(p.value)
|
|
2736
2789
|
);
|
|
2737
2790
|
}),
|
|
2738
|
-
|
|
2791
|
+
m && /* @__PURE__ */ t.jsx("p", { className: l.fieldError, children: m })
|
|
2739
2792
|
]
|
|
2740
2793
|
}
|
|
2741
2794
|
);
|
|
@@ -2769,14 +2822,14 @@ const is = {
|
|
|
2769
2822
|
"exterior-high_end": re("2023-04-1682103085417-24272.jpeg", "3:2-md"),
|
|
2770
2823
|
"exterior-luxury": re("2023-04-1681773220487-59852.png")
|
|
2771
2824
|
}, ls = ({ question: e }) => {
|
|
2772
|
-
var
|
|
2773
|
-
const { getAnswer: r, setAnswer: a, goToNext: s, validationErrors: o } = fe(), i = r(e.key),
|
|
2825
|
+
var u;
|
|
2826
|
+
const { getAnswer: r, setAnswer: a, goToNext: s, validationErrors: o } = fe(), i = r(e.key), m = o[e.key], f = G(null);
|
|
2774
2827
|
se(() => () => {
|
|
2775
2828
|
f.current && clearTimeout(f.current);
|
|
2776
2829
|
}, []);
|
|
2777
|
-
const
|
|
2778
|
-
(
|
|
2779
|
-
a(e.key,
|
|
2830
|
+
const d = Ee(
|
|
2831
|
+
(h) => {
|
|
2832
|
+
a(e.key, h), e.autoAdvance && (f.current && clearTimeout(f.current), f.current = setTimeout(() => s(), 300));
|
|
2780
2833
|
},
|
|
2781
2834
|
[e.key, e.autoAdvance, a, s]
|
|
2782
2835
|
);
|
|
@@ -2787,34 +2840,34 @@ const is = {
|
|
|
2787
2840
|
role: "radiogroup",
|
|
2788
2841
|
"aria-label": e.label,
|
|
2789
2842
|
children: [
|
|
2790
|
-
(
|
|
2791
|
-
const
|
|
2843
|
+
(u = e.options) == null ? void 0 : u.map((h) => {
|
|
2844
|
+
const p = i === h.value, _ = h.imageId ? is[h.imageId] : void 0;
|
|
2792
2845
|
return /* @__PURE__ */ t.jsxs(
|
|
2793
2846
|
"button",
|
|
2794
2847
|
{
|
|
2795
2848
|
type: "button",
|
|
2796
2849
|
role: "radio",
|
|
2797
|
-
"aria-checked":
|
|
2798
|
-
className: `${l.imageCard} ${
|
|
2799
|
-
onClick: () =>
|
|
2850
|
+
"aria-checked": p,
|
|
2851
|
+
className: `${l.imageCard} ${p ? l.imageCardSelected : ""}`,
|
|
2852
|
+
onClick: () => d(h.value),
|
|
2800
2853
|
children: [
|
|
2801
|
-
|
|
2854
|
+
_ && /* @__PURE__ */ t.jsx(
|
|
2802
2855
|
"img",
|
|
2803
2856
|
{
|
|
2804
|
-
src:
|
|
2805
|
-
alt:
|
|
2857
|
+
src: _,
|
|
2858
|
+
alt: h.label,
|
|
2806
2859
|
className: l.imageCardPhoto,
|
|
2807
2860
|
loading: "lazy"
|
|
2808
2861
|
}
|
|
2809
2862
|
),
|
|
2810
|
-
/* @__PURE__ */ t.jsx("span", { className: l.imageCardLabel, children:
|
|
2811
|
-
|
|
2863
|
+
/* @__PURE__ */ t.jsx("span", { className: l.imageCardLabel, children: h.label }),
|
|
2864
|
+
h.description && /* @__PURE__ */ t.jsx("span", { className: l.imageCardDescription, children: h.description })
|
|
2812
2865
|
]
|
|
2813
2866
|
},
|
|
2814
|
-
String(
|
|
2867
|
+
String(h.value)
|
|
2815
2868
|
);
|
|
2816
2869
|
}),
|
|
2817
|
-
|
|
2870
|
+
m && /* @__PURE__ */ t.jsx("p", { className: l.fieldError, children: m })
|
|
2818
2871
|
]
|
|
2819
2872
|
}
|
|
2820
2873
|
);
|
|
@@ -2822,24 +2875,24 @@ const is = {
|
|
|
2822
2875
|
question: e
|
|
2823
2876
|
}) => {
|
|
2824
2877
|
var f;
|
|
2825
|
-
const { getAnswer: r, setAnswer: a, validationErrors: s } = fe(), o = r(e.key) ?? [], i = s[e.key],
|
|
2826
|
-
var
|
|
2827
|
-
const
|
|
2828
|
-
if (
|
|
2829
|
-
a(e.key, [
|
|
2878
|
+
const { getAnswer: r, setAnswer: a, validationErrors: s } = fe(), o = r(e.key) ?? [], i = s[e.key], m = (d) => {
|
|
2879
|
+
var p;
|
|
2880
|
+
const u = (p = e.options) == null ? void 0 : p.find((_) => _.value === d);
|
|
2881
|
+
if (u != null && u.exclusive) {
|
|
2882
|
+
a(e.key, [d]);
|
|
2830
2883
|
return;
|
|
2831
2884
|
}
|
|
2832
|
-
const
|
|
2833
|
-
(
|
|
2834
|
-
var C,
|
|
2835
|
-
return !((
|
|
2885
|
+
const h = o.filter(
|
|
2886
|
+
(_) => {
|
|
2887
|
+
var C, S;
|
|
2888
|
+
return !((S = (C = e.options) == null ? void 0 : C.find((k) => k.value === _)) != null && S.exclusive);
|
|
2836
2889
|
}
|
|
2837
2890
|
);
|
|
2838
|
-
if (
|
|
2839
|
-
const
|
|
2840
|
-
a(e.key,
|
|
2891
|
+
if (h.includes(d)) {
|
|
2892
|
+
const _ = h.filter((C) => C !== d);
|
|
2893
|
+
a(e.key, _.length > 0 ? _ : void 0);
|
|
2841
2894
|
} else
|
|
2842
|
-
a(e.key, [...
|
|
2895
|
+
a(e.key, [...h, d]);
|
|
2843
2896
|
};
|
|
2844
2897
|
return /* @__PURE__ */ t.jsxs(
|
|
2845
2898
|
"div",
|
|
@@ -2848,26 +2901,26 @@ const is = {
|
|
|
2848
2901
|
role: "group",
|
|
2849
2902
|
"aria-label": e.label,
|
|
2850
2903
|
children: [
|
|
2851
|
-
(f = e.options) == null ? void 0 : f.map((
|
|
2852
|
-
const
|
|
2904
|
+
(f = e.options) == null ? void 0 : f.map((d) => {
|
|
2905
|
+
const u = o.includes(String(d.value));
|
|
2853
2906
|
return /* @__PURE__ */ t.jsxs(
|
|
2854
2907
|
"button",
|
|
2855
2908
|
{
|
|
2856
2909
|
type: "button",
|
|
2857
2910
|
role: "checkbox",
|
|
2858
|
-
"aria-checked":
|
|
2859
|
-
className: `${l.checkboxCard} ${
|
|
2860
|
-
onClick: () =>
|
|
2911
|
+
"aria-checked": u,
|
|
2912
|
+
className: `${l.checkboxCard} ${u ? l.checkboxCardSelected : ""}`,
|
|
2913
|
+
onClick: () => m(String(d.value)),
|
|
2861
2914
|
children: [
|
|
2862
2915
|
/* @__PURE__ */ t.jsxs("span", { className: l.checkboxCardContent, children: [
|
|
2863
|
-
/* @__PURE__ */ t.jsx("span", { className: l.checkboxCardLabel, children:
|
|
2864
|
-
|
|
2916
|
+
/* @__PURE__ */ t.jsx("span", { className: l.checkboxCardLabel, children: d.label }),
|
|
2917
|
+
d.helperText && /* @__PURE__ */ t.jsx("span", { className: l.checkboxCardHelper, children: d.helperText })
|
|
2865
2918
|
] }),
|
|
2866
2919
|
/* @__PURE__ */ t.jsx(
|
|
2867
2920
|
"span",
|
|
2868
2921
|
{
|
|
2869
|
-
className: `${l.checkboxIndicator} ${
|
|
2870
|
-
children:
|
|
2922
|
+
className: `${l.checkboxIndicator} ${u ? l.checkboxIndicatorChecked : ""}`,
|
|
2923
|
+
children: u && /* @__PURE__ */ t.jsx("svg", { width: "12", height: "12", viewBox: "0 0 12 12", fill: "none", children: /* @__PURE__ */ t.jsx(
|
|
2871
2924
|
"path",
|
|
2872
2925
|
{
|
|
2873
2926
|
d: "M2 6l3 3 5-5",
|
|
@@ -2881,7 +2934,7 @@ const is = {
|
|
|
2881
2934
|
)
|
|
2882
2935
|
]
|
|
2883
2936
|
},
|
|
2884
|
-
String(
|
|
2937
|
+
String(d.value)
|
|
2885
2938
|
);
|
|
2886
2939
|
}),
|
|
2887
2940
|
i && /* @__PURE__ */ t.jsx("p", { className: l.fieldError, children: i })
|
|
@@ -2890,9 +2943,9 @@ const is = {
|
|
|
2890
2943
|
);
|
|
2891
2944
|
}, us = ({ question: e }) => {
|
|
2892
2945
|
var f;
|
|
2893
|
-
const { getAnswer: r, setAnswer: a, validationErrors: s } = fe(), o = r(e.key), i = s[e.key],
|
|
2894
|
-
const
|
|
2895
|
-
e.type === "number" &&
|
|
2946
|
+
const { getAnswer: r, setAnswer: a, validationErrors: s } = fe(), o = r(e.key), i = s[e.key], m = (d) => {
|
|
2947
|
+
const u = d.target.value;
|
|
2948
|
+
e.type === "number" && u !== "" ? a(e.key, Number(u)) : a(e.key, u || void 0);
|
|
2896
2949
|
};
|
|
2897
2950
|
return /* @__PURE__ */ t.jsxs("div", { className: l.fieldGroup, children: [
|
|
2898
2951
|
/* @__PURE__ */ t.jsx("label", { className: l.fieldLabel, htmlFor: e.key, children: e.label }),
|
|
@@ -2903,23 +2956,23 @@ const is = {
|
|
|
2903
2956
|
id: e.key,
|
|
2904
2957
|
className: `${l.fieldSelect} ${i ? l.fieldSelectError : ""}`,
|
|
2905
2958
|
value: o !== void 0 ? String(o) : "",
|
|
2906
|
-
onChange:
|
|
2959
|
+
onChange: m,
|
|
2907
2960
|
children: [
|
|
2908
2961
|
/* @__PURE__ */ t.jsx("option", { value: "", children: e.placeholder || "Select..." }),
|
|
2909
|
-
(f = e.options) == null ? void 0 : f.map((
|
|
2962
|
+
(f = e.options) == null ? void 0 : f.map((d) => /* @__PURE__ */ t.jsx("option", { value: String(d.value), children: d.label }, String(d.value)))
|
|
2910
2963
|
]
|
|
2911
2964
|
}
|
|
2912
2965
|
),
|
|
2913
2966
|
i && /* @__PURE__ */ t.jsx("p", { className: l.fieldError, children: i })
|
|
2914
2967
|
] });
|
|
2915
2968
|
}, ds = ({ question: e }) => {
|
|
2916
|
-
const { getAnswer: r, setAnswer: a, validationErrors: s } = fe(), o = r(e.key), i = s[e.key],
|
|
2917
|
-
const
|
|
2969
|
+
const { getAnswer: r, setAnswer: a, validationErrors: s } = fe(), o = r(e.key), i = s[e.key], m = (d) => {
|
|
2970
|
+
const u = d.target.value;
|
|
2918
2971
|
if (e.type === "number") {
|
|
2919
|
-
const
|
|
2920
|
-
a(e.key,
|
|
2972
|
+
const h = u.replace(/[^0-9.]/g, ""), p = h === "" ? void 0 : Number(h), _ = p !== void 0 && isNaN(p) ? void 0 : p;
|
|
2973
|
+
a(e.key, _);
|
|
2921
2974
|
} else
|
|
2922
|
-
a(e.key,
|
|
2975
|
+
a(e.key, u || void 0);
|
|
2923
2976
|
}, f = o != null ? String(o) : "";
|
|
2924
2977
|
return /* @__PURE__ */ t.jsxs("div", { className: l.fieldGroup, children: [
|
|
2925
2978
|
/* @__PURE__ */ t.jsx("label", { className: l.fieldLabel, htmlFor: e.key, children: e.label }),
|
|
@@ -2933,7 +2986,7 @@ const is = {
|
|
|
2933
2986
|
inputMode: e.type === "number" ? "numeric" : void 0,
|
|
2934
2987
|
className: `${l.fieldInput} ${i ? l.fieldInputError : ""}`,
|
|
2935
2988
|
value: f,
|
|
2936
|
-
onChange:
|
|
2989
|
+
onChange: m,
|
|
2937
2990
|
placeholder: e.placeholder
|
|
2938
2991
|
}
|
|
2939
2992
|
),
|
|
@@ -2942,9 +2995,9 @@ const is = {
|
|
|
2942
2995
|
i && /* @__PURE__ */ t.jsx("p", { className: l.fieldError, children: i })
|
|
2943
2996
|
] });
|
|
2944
2997
|
}, hs = ({ question: e }) => {
|
|
2945
|
-
const { getAnswer: r, setAnswer: a, validationErrors: s } = fe(), o = r(e.key), i = s[e.key],
|
|
2946
|
-
const
|
|
2947
|
-
a(e.key,
|
|
2998
|
+
const { getAnswer: r, setAnswer: a, validationErrors: s } = fe(), o = r(e.key), i = s[e.key], m = (d) => {
|
|
2999
|
+
const u = d.target.value.replace(/[^0-9]/g, ""), h = u === "" ? void 0 : Number(u);
|
|
3000
|
+
a(e.key, h !== void 0 && isNaN(h) ? void 0 : h);
|
|
2948
3001
|
}, f = o != null ? String(o) : "";
|
|
2949
3002
|
return /* @__PURE__ */ t.jsxs("div", { className: l.fieldGroup, children: [
|
|
2950
3003
|
/* @__PURE__ */ t.jsx("label", { className: l.fieldLabel, htmlFor: e.key, children: e.label }),
|
|
@@ -2958,7 +3011,7 @@ const is = {
|
|
|
2958
3011
|
inputMode: "numeric",
|
|
2959
3012
|
className: `${l.currencyInput} ${i ? l.fieldInputError : ""}`,
|
|
2960
3013
|
value: f,
|
|
2961
|
-
onChange:
|
|
3014
|
+
onChange: m,
|
|
2962
3015
|
placeholder: e.placeholder
|
|
2963
3016
|
}
|
|
2964
3017
|
)
|
|
@@ -2971,9 +3024,9 @@ function fs(e) {
|
|
|
2971
3024
|
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)}`;
|
|
2972
3025
|
}
|
|
2973
3026
|
const ms = ({ question: e }) => {
|
|
2974
|
-
const { getAnswer: r, setAnswer: a, validationErrors: s } = fe(), o = r(e.key) ?? "", i = s[e.key],
|
|
2975
|
-
const
|
|
2976
|
-
a(e.key,
|
|
3027
|
+
const { getAnswer: r, setAnswer: a, validationErrors: s } = fe(), o = r(e.key) ?? "", i = s[e.key], m = (f) => {
|
|
3028
|
+
const u = f.target.value.replace(/\D/g, "").slice(0, 10);
|
|
3029
|
+
a(e.key, u || void 0);
|
|
2977
3030
|
};
|
|
2978
3031
|
return /* @__PURE__ */ t.jsxs("div", { className: l.fieldGroup, children: [
|
|
2979
3032
|
/* @__PURE__ */ t.jsx("label", { className: l.fieldLabel, htmlFor: e.key, children: e.label }),
|
|
@@ -2984,7 +3037,7 @@ const ms = ({ question: e }) => {
|
|
|
2984
3037
|
type: "tel",
|
|
2985
3038
|
className: `${l.fieldInput} ${i ? l.fieldInputError : ""}`,
|
|
2986
3039
|
value: fs(o),
|
|
2987
|
-
onChange:
|
|
3040
|
+
onChange: m,
|
|
2988
3041
|
placeholder: e.placeholder || "(555) 555-5555"
|
|
2989
3042
|
}
|
|
2990
3043
|
),
|
|
@@ -3000,12 +3053,12 @@ const ms = ({ question: e }) => {
|
|
|
3000
3053
|
type: "checkbox",
|
|
3001
3054
|
className: l.toggleCheckbox,
|
|
3002
3055
|
checked: o === !0,
|
|
3003
|
-
onChange: (
|
|
3056
|
+
onChange: (m) => a(e.key, m.target.checked)
|
|
3004
3057
|
}
|
|
3005
3058
|
),
|
|
3006
3059
|
/* @__PURE__ */ t.jsx("span", { className: l.toggleText, children: i })
|
|
3007
3060
|
] }) });
|
|
3008
|
-
},
|
|
3061
|
+
}, bt = 4, Te = 8, gs = 240, _s = 80;
|
|
3009
3062
|
function bs(e) {
|
|
3010
3063
|
const r = {};
|
|
3011
3064
|
for (let a = e; a; a = a.parentElement) {
|
|
@@ -3019,54 +3072,54 @@ function bs(e) {
|
|
|
3019
3072
|
}
|
|
3020
3073
|
const ys = ({ question: e }) => {
|
|
3021
3074
|
var ue;
|
|
3022
|
-
const { getAnswer: r, setAnswer: a, validationErrors: s } = fe(), o = r(e.key), i = s[e.key],
|
|
3075
|
+
const { getAnswer: r, setAnswer: a, validationErrors: s } = fe(), o = r(e.key), i = s[e.key], m = `${e.key}-combobox`, [f, d] = E(""), [u, h] = E(!1), [p, _] = E([]), [C, S] = E(!1), k = G(null), H = G(null), P = G(null), [Y, j] = E(null), [ne, F] = E({}), oe = De(Ke);
|
|
3023
3076
|
se(() => {
|
|
3024
3077
|
let v = !1;
|
|
3025
|
-
return e.dataSource === "homebuilders" && oe ? (
|
|
3026
|
-
v ||
|
|
3078
|
+
return e.dataSource === "homebuilders" && oe ? (S(!0), oe.getHomebuilders().then((x) => {
|
|
3079
|
+
v || _(
|
|
3027
3080
|
x.homebuilders.map((y) => ({
|
|
3028
3081
|
label: y.displayName,
|
|
3029
3082
|
value: y.identifier
|
|
3030
3083
|
}))
|
|
3031
3084
|
);
|
|
3032
3085
|
}).catch(() => {
|
|
3033
|
-
v || (e.options ?
|
|
3086
|
+
v || (e.options ? _(
|
|
3034
3087
|
e.options.map((x) => ({
|
|
3035
3088
|
label: x.label,
|
|
3036
3089
|
value: String(x.value)
|
|
3037
3090
|
}))
|
|
3038
|
-
) :
|
|
3091
|
+
) : _([]));
|
|
3039
3092
|
}).finally(() => {
|
|
3040
|
-
v ||
|
|
3041
|
-
})) : e.options ?
|
|
3093
|
+
v || S(!1);
|
|
3094
|
+
})) : e.options ? _(
|
|
3042
3095
|
e.options.map((x) => ({
|
|
3043
3096
|
label: x.label,
|
|
3044
3097
|
value: String(x.value)
|
|
3045
3098
|
}))
|
|
3046
|
-
) :
|
|
3099
|
+
) : _([]), () => {
|
|
3047
3100
|
v = !0;
|
|
3048
3101
|
};
|
|
3049
3102
|
}, [e.dataSource, e.options, oe]);
|
|
3050
|
-
const U =
|
|
3103
|
+
const U = Ee(() => {
|
|
3051
3104
|
const v = H.current;
|
|
3052
3105
|
if (!v) return;
|
|
3053
|
-
const x = v.getBoundingClientRect(), y = window.visualViewport, R = (y == null ? void 0 : y.height) ?? window.innerHeight, J = (y == null ? void 0 : y.width) ?? window.innerWidth, ye = (y == null ? void 0 : y.offsetTop) ?? 0, he = (y == null ? void 0 : y.offsetLeft) ?? 0, pe = ye + R - x.bottom -
|
|
3106
|
+
const x = v.getBoundingClientRect(), y = window.visualViewport, R = (y == null ? void 0 : y.height) ?? window.innerHeight, J = (y == null ? void 0 : y.width) ?? window.innerWidth, ye = (y == null ? void 0 : y.offsetTop) ?? 0, he = (y == null ? void 0 : y.offsetLeft) ?? 0, pe = ye + R - x.bottom - bt - Te, N = Math.max(
|
|
3054
3107
|
_s,
|
|
3055
3108
|
Math.min(gs, pe)
|
|
3056
3109
|
), L = Math.min(x.width, J - Te * 2), B = he + Te, M = he + J - L - Te, le = Math.max(B, Math.min(x.left, M));
|
|
3057
3110
|
j({
|
|
3058
|
-
top: x.bottom + window.scrollY +
|
|
3111
|
+
top: x.bottom + window.scrollY + bt,
|
|
3059
3112
|
left: le + window.scrollX,
|
|
3060
3113
|
width: L,
|
|
3061
3114
|
maxHeight: N
|
|
3062
3115
|
});
|
|
3063
3116
|
}, []);
|
|
3064
|
-
|
|
3065
|
-
if (!
|
|
3117
|
+
Ut(() => {
|
|
3118
|
+
if (!u) {
|
|
3066
3119
|
j(null);
|
|
3067
3120
|
return;
|
|
3068
3121
|
}
|
|
3069
|
-
H.current &&
|
|
3122
|
+
H.current && F(bs(H.current)), U();
|
|
3070
3123
|
const v = () => U();
|
|
3071
3124
|
window.addEventListener("scroll", v, !0), window.addEventListener("resize", v);
|
|
3072
3125
|
const x = window.visualViewport;
|
|
@@ -3075,45 +3128,45 @@ const ys = ({ question: e }) => {
|
|
|
3075
3128
|
return () => {
|
|
3076
3129
|
window.removeEventListener("scroll", v, !0), window.removeEventListener("resize", v), x == null || x.removeEventListener("resize", v), x == null || x.removeEventListener("scroll", v), window.clearTimeout(y);
|
|
3077
3130
|
};
|
|
3078
|
-
}, [
|
|
3131
|
+
}, [u, U]), se(() => {
|
|
3079
3132
|
const v = (x) => {
|
|
3080
3133
|
var R, J;
|
|
3081
3134
|
const y = x.target;
|
|
3082
|
-
(R = k.current) != null && R.contains(y) || (J = P.current) != null && J.contains(y) ||
|
|
3135
|
+
(R = k.current) != null && R.contains(y) || (J = P.current) != null && J.contains(y) || h(!1);
|
|
3083
3136
|
};
|
|
3084
3137
|
return document.addEventListener("mousedown", v), () => document.removeEventListener("mousedown", v);
|
|
3085
3138
|
}, []);
|
|
3086
|
-
const
|
|
3139
|
+
const A = f ? p.filter(
|
|
3087
3140
|
(v) => v.label.toLowerCase().includes(f.toLowerCase())
|
|
3088
|
-
) :
|
|
3141
|
+
) : p, $ = (ue = p.find((v) => v.value === o)) == null ? void 0 : ue.label, [Z, ae] = E(-1), z = `${e.key}-listbox`, K = Ee(
|
|
3089
3142
|
(v) => {
|
|
3090
|
-
a(e.key, v),
|
|
3143
|
+
a(e.key, v), h(!1), d(""), ae(-1);
|
|
3091
3144
|
},
|
|
3092
3145
|
[e.key, a]
|
|
3093
3146
|
), q = (v) => {
|
|
3094
|
-
if (!
|
|
3095
|
-
(v.key === "ArrowDown" || v.key === "Enter") && (v.preventDefault(),
|
|
3147
|
+
if (!u) {
|
|
3148
|
+
(v.key === "ArrowDown" || v.key === "Enter") && (v.preventDefault(), h(!0));
|
|
3096
3149
|
return;
|
|
3097
3150
|
}
|
|
3098
3151
|
switch (v.key) {
|
|
3099
3152
|
case "ArrowDown":
|
|
3100
|
-
v.preventDefault(),
|
|
3101
|
-
(x) => x <
|
|
3153
|
+
v.preventDefault(), A.length > 0 && ae(
|
|
3154
|
+
(x) => x < A.length - 1 ? x + 1 : 0
|
|
3102
3155
|
);
|
|
3103
3156
|
break;
|
|
3104
3157
|
case "ArrowUp":
|
|
3105
|
-
v.preventDefault(),
|
|
3106
|
-
(x) => x > 0 ? x - 1 :
|
|
3158
|
+
v.preventDefault(), A.length > 0 && ae(
|
|
3159
|
+
(x) => x > 0 ? x - 1 : A.length - 1
|
|
3107
3160
|
);
|
|
3108
3161
|
break;
|
|
3109
3162
|
case "Enter":
|
|
3110
|
-
v.preventDefault(), Z >= 0 && Z <
|
|
3163
|
+
v.preventDefault(), Z >= 0 && Z < A.length && K(A[Z].value);
|
|
3111
3164
|
break;
|
|
3112
3165
|
case "Escape":
|
|
3113
|
-
v.preventDefault(),
|
|
3166
|
+
v.preventDefault(), h(!1), ae(-1);
|
|
3114
3167
|
break;
|
|
3115
3168
|
}
|
|
3116
|
-
}, ie =
|
|
3169
|
+
}, ie = u && Y && typeof document < "u" ? Yt(
|
|
3117
3170
|
/* @__PURE__ */ t.jsx(
|
|
3118
3171
|
"div",
|
|
3119
3172
|
{
|
|
@@ -3130,7 +3183,7 @@ const ys = ({ question: e }) => {
|
|
|
3130
3183
|
maxHeight: Y.maxHeight,
|
|
3131
3184
|
...ne
|
|
3132
3185
|
},
|
|
3133
|
-
children: C ? /* @__PURE__ */ t.jsx("div", { className: l.searchableDropdownEmpty, children: "Loading..." }) :
|
|
3186
|
+
children: C ? /* @__PURE__ */ t.jsx("div", { className: l.searchableDropdownEmpty, children: "Loading..." }) : A.length === 0 ? /* @__PURE__ */ t.jsx("div", { className: l.searchableDropdownEmpty, children: "No results found" }) : A.map((v, x) => /* @__PURE__ */ t.jsx(
|
|
3134
3187
|
"button",
|
|
3135
3188
|
{
|
|
3136
3189
|
id: `${z}-option-${x}`,
|
|
@@ -3153,22 +3206,22 @@ const ys = ({ question: e }) => {
|
|
|
3153
3206
|
/* @__PURE__ */ t.jsx(
|
|
3154
3207
|
"input",
|
|
3155
3208
|
{
|
|
3156
|
-
id:
|
|
3209
|
+
id: m,
|
|
3157
3210
|
type: "text",
|
|
3158
3211
|
className: l.fieldInput,
|
|
3159
|
-
value:
|
|
3212
|
+
value: u ? f : $ ?? "",
|
|
3160
3213
|
onChange: (v) => {
|
|
3161
|
-
|
|
3214
|
+
d(v.target.value), ae(-1), u || h(!0);
|
|
3162
3215
|
},
|
|
3163
|
-
onFocus: () =>
|
|
3216
|
+
onFocus: () => h(!0),
|
|
3164
3217
|
onKeyDown: q,
|
|
3165
3218
|
placeholder: e.placeholder || "Select or search...",
|
|
3166
3219
|
"aria-label": e.label,
|
|
3167
|
-
"aria-expanded":
|
|
3220
|
+
"aria-expanded": u,
|
|
3168
3221
|
role: "combobox",
|
|
3169
3222
|
"aria-haspopup": "listbox",
|
|
3170
|
-
"aria-controls":
|
|
3171
|
-
"aria-activedescendant":
|
|
3223
|
+
"aria-controls": u ? z : void 0,
|
|
3224
|
+
"aria-activedescendant": u && Z >= 0 ? `${z}-option-${Z}` : void 0
|
|
3172
3225
|
}
|
|
3173
3226
|
),
|
|
3174
3227
|
/* @__PURE__ */ t.jsx(
|
|
@@ -3176,7 +3229,7 @@ const ys = ({ question: e }) => {
|
|
|
3176
3229
|
{
|
|
3177
3230
|
type: "button",
|
|
3178
3231
|
className: l.searchableDropdownToggle,
|
|
3179
|
-
onClick: () =>
|
|
3232
|
+
onClick: () => h(!u),
|
|
3180
3233
|
"aria-label": "Toggle dropdown",
|
|
3181
3234
|
tabIndex: -1,
|
|
3182
3235
|
children: /* @__PURE__ */ t.jsx("svg", { width: "12", height: "8", viewBox: "0 0 12 8", fill: "none", children: /* @__PURE__ */ t.jsx(
|
|
@@ -3224,8 +3277,8 @@ function vs(e) {
|
|
|
3224
3277
|
const xs = () => {
|
|
3225
3278
|
const { currentPage: e, visibleQuestions: r, goToNext: a, contactConsentText: s } = fe(), o = G(null);
|
|
3226
3279
|
return se(() => {
|
|
3227
|
-
var i,
|
|
3228
|
-
(
|
|
3280
|
+
var i, m, f;
|
|
3281
|
+
(m = (i = o.current) == null ? void 0 : i.scrollTo) == null || m.call(i, { top: 0, behavior: "smooth" }), (f = o.current) == null || f.focus();
|
|
3229
3282
|
}, [e == null ? void 0 : e.id]), e ? /* @__PURE__ */ t.jsxs(
|
|
3230
3283
|
"div",
|
|
3231
3284
|
{
|
|
@@ -3320,13 +3373,13 @@ const xs = () => {
|
|
|
3320
3373
|
appearance: s = { theme: "minimal" },
|
|
3321
3374
|
initialAnswers: o,
|
|
3322
3375
|
skipPages: i,
|
|
3323
|
-
smsConsentText:
|
|
3376
|
+
smsConsentText: m,
|
|
3324
3377
|
onPageChange: f,
|
|
3325
|
-
onAnswerChange:
|
|
3326
|
-
onClose:
|
|
3327
|
-
onReady:
|
|
3328
|
-
onError:
|
|
3329
|
-
contactConsentText:
|
|
3378
|
+
onAnswerChange: d,
|
|
3379
|
+
onClose: u,
|
|
3380
|
+
onReady: h,
|
|
3381
|
+
onError: p,
|
|
3382
|
+
contactConsentText: _
|
|
3330
3383
|
}) => {
|
|
3331
3384
|
const C = Pe(s);
|
|
3332
3385
|
return /* @__PURE__ */ t.jsx("div", { className: l.container, style: C, children: /* @__PURE__ */ t.jsxs(
|
|
@@ -3334,38 +3387,38 @@ const xs = () => {
|
|
|
3334
3387
|
{
|
|
3335
3388
|
initialAnswers: o,
|
|
3336
3389
|
skipPages: i,
|
|
3337
|
-
smsConsentText:
|
|
3338
|
-
contactConsentText:
|
|
3390
|
+
smsConsentText: m,
|
|
3391
|
+
contactConsentText: _,
|
|
3339
3392
|
onSubmit: r,
|
|
3340
3393
|
onPageChange: f,
|
|
3341
|
-
onAnswerChange:
|
|
3342
|
-
onReady:
|
|
3343
|
-
onError:
|
|
3394
|
+
onAnswerChange: d,
|
|
3395
|
+
onReady: h,
|
|
3396
|
+
onError: p,
|
|
3344
3397
|
children: [
|
|
3345
|
-
/* @__PURE__ */ t.jsx(ts, { partnerLogoUrl: a, onClose:
|
|
3398
|
+
/* @__PURE__ */ t.jsx(ts, { partnerLogoUrl: a, onClose: u }),
|
|
3346
3399
|
/* @__PURE__ */ t.jsx(Cs, { address: e })
|
|
3347
3400
|
]
|
|
3348
3401
|
}
|
|
3349
3402
|
) });
|
|
3350
|
-
}, ws = "_root_1iq32_7", ks = "_card_1iq32_18", js = "_titleLarge_1iq32_36", Ns = "_featuresList_1iq32_40", Is = "_stepLayout_1iq32_55",
|
|
3403
|
+
}, ws = "_root_1iq32_7", ks = "_card_1iq32_18", js = "_titleLarge_1iq32_36", Ns = "_featuresList_1iq32_40", Is = "_stepLayout_1iq32_55", Ss = "_leftColumn_1iq32_47", Es = "_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", Fs = "_calendarNavButton_1iq32_188", $s = "_calendarGrid_1iq32_208", Ws = "_calendarDayHeader_1iq32_214", Hs = "_calendarDayAvailable_1iq32_223", Vs = "_calendarDayDisabled_1iq32_224", qs = "_calendarDaySelected_1iq32_225", Gs = "_timesHeader_1iq32_256", Us = "_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", g = {
|
|
3351
3404
|
root: ws,
|
|
3352
3405
|
card: ks,
|
|
3353
3406
|
titleLarge: js,
|
|
3354
3407
|
featuresList: Ns,
|
|
3355
3408
|
stepLayout: Is,
|
|
3356
|
-
leftColumn:
|
|
3357
|
-
introHeader:
|
|
3409
|
+
leftColumn: Ss,
|
|
3410
|
+
introHeader: Es,
|
|
3358
3411
|
schedule: Ps,
|
|
3359
3412
|
subtitleLeft: Ls,
|
|
3360
3413
|
feature: Ts,
|
|
3361
|
-
featureTitle:
|
|
3362
|
-
featureDescription:
|
|
3414
|
+
featureTitle: As,
|
|
3415
|
+
featureDescription: Ds,
|
|
3363
3416
|
title: Os,
|
|
3364
3417
|
subtitle: Rs,
|
|
3365
3418
|
calendarHeader: Bs,
|
|
3366
3419
|
calendarMonthLabel: Ms,
|
|
3367
|
-
calendarNavButton:
|
|
3368
|
-
calendarGrid:
|
|
3420
|
+
calendarNavButton: Fs,
|
|
3421
|
+
calendarGrid: $s,
|
|
3369
3422
|
calendarDayHeader: Ws,
|
|
3370
3423
|
calendarDayAvailable: Hs,
|
|
3371
3424
|
calendarDayDisabled: Vs,
|
|
@@ -3402,18 +3455,18 @@ const xs = () => {
|
|
|
3402
3455
|
isSlotBased: !1,
|
|
3403
3456
|
timezone: "UTC"
|
|
3404
3457
|
};
|
|
3405
|
-
function
|
|
3458
|
+
function Fo({
|
|
3406
3459
|
offerId: e,
|
|
3407
3460
|
customerName: r,
|
|
3408
3461
|
customerPhone: a,
|
|
3409
3462
|
address: s,
|
|
3410
3463
|
appearance: o,
|
|
3411
3464
|
onScheduled: i,
|
|
3412
|
-
onDone:
|
|
3465
|
+
onDone: m,
|
|
3413
3466
|
onReady: f,
|
|
3414
|
-
onError:
|
|
3467
|
+
onError: d
|
|
3415
3468
|
}) {
|
|
3416
|
-
const
|
|
3469
|
+
const u = Nt(), h = Pe(o), [p, _] = E(_o), [C, S] = E("select"), [k, H] = E(null), [P, Y] = E(null), [j, ne] = E(null), [F, oe] = E(r ?? ""), [U, A] = E(qe(a ?? "")), [$, Z] = E(null), [ae, z] = E(""), [K, q] = E(!1), [ie, ue] = E(null), v = G(r);
|
|
3417
3470
|
v.current = r;
|
|
3418
3471
|
const x = G(a);
|
|
3419
3472
|
x.current = a, se(() => {
|
|
@@ -3422,13 +3475,13 @@ function $o({
|
|
|
3422
3475
|
let N = !1;
|
|
3423
3476
|
return (async () => {
|
|
3424
3477
|
try {
|
|
3425
|
-
const L = await
|
|
3478
|
+
const L = await u.getCustomerContact({
|
|
3426
3479
|
opendoorOfferRequestId: e
|
|
3427
3480
|
});
|
|
3428
3481
|
if (N) return;
|
|
3429
3482
|
oe(
|
|
3430
3483
|
(B) => !v.current && !B && L.fullName ? L.fullName : B
|
|
3431
|
-
),
|
|
3484
|
+
), A(
|
|
3432
3485
|
(B) => !x.current && !B && L.phoneNumber ? qe(L.phoneNumber) : B
|
|
3433
3486
|
);
|
|
3434
3487
|
} catch {
|
|
@@ -3436,13 +3489,13 @@ function $o({
|
|
|
3436
3489
|
})(), () => {
|
|
3437
3490
|
N = !0;
|
|
3438
3491
|
};
|
|
3439
|
-
}, [
|
|
3492
|
+
}, [u, e]), se(() => {
|
|
3440
3493
|
let N = !1;
|
|
3441
3494
|
return (async () => {
|
|
3442
3495
|
try {
|
|
3443
|
-
const L = await
|
|
3496
|
+
const L = await u.getAssessmentSlots({ offerId: e });
|
|
3444
3497
|
if (N) return;
|
|
3445
|
-
if (
|
|
3498
|
+
if (_({
|
|
3446
3499
|
loading: !1,
|
|
3447
3500
|
error: null,
|
|
3448
3501
|
availableSlots: L.availableSlots,
|
|
@@ -3451,7 +3504,7 @@ function $o({
|
|
|
3451
3504
|
}), L.availableSlots.length > 0)
|
|
3452
3505
|
ne(
|
|
3453
3506
|
yo(
|
|
3454
|
-
|
|
3507
|
+
yt(L.availableSlots[0], L.timezone)
|
|
3455
3508
|
)
|
|
3456
3509
|
);
|
|
3457
3510
|
else {
|
|
@@ -3462,40 +3515,40 @@ function $o({
|
|
|
3462
3515
|
} catch (L) {
|
|
3463
3516
|
const B = L instanceof Error ? L : new Error(String(L));
|
|
3464
3517
|
if (N) return;
|
|
3465
|
-
|
|
3518
|
+
_((le) => ({ ...le, loading: !1, error: B }));
|
|
3466
3519
|
const M = /* @__PURE__ */ new Date();
|
|
3467
|
-
ne({ year: M.getFullYear(), month: M.getMonth() }),
|
|
3520
|
+
ne({ year: M.getFullYear(), month: M.getMonth() }), d == null || d(B);
|
|
3468
3521
|
}
|
|
3469
3522
|
})(), () => {
|
|
3470
3523
|
N = !0;
|
|
3471
3524
|
};
|
|
3472
|
-
}, [
|
|
3473
|
-
const y =
|
|
3525
|
+
}, [u, e]);
|
|
3526
|
+
const y = Se(() => {
|
|
3474
3527
|
const N = /* @__PURE__ */ new Map();
|
|
3475
|
-
for (const L of
|
|
3476
|
-
const B =
|
|
3528
|
+
for (const L of p.availableSlots) {
|
|
3529
|
+
const B = yt(L, p.timezone), M = N.get(B) ?? [];
|
|
3477
3530
|
M.push(L), N.set(B, M);
|
|
3478
3531
|
}
|
|
3479
3532
|
return N;
|
|
3480
|
-
}, [
|
|
3481
|
-
if (
|
|
3533
|
+
}, [p.availableSlots, p.timezone]);
|
|
3534
|
+
if (p.loading || !j)
|
|
3482
3535
|
return /* @__PURE__ */ t.jsx(
|
|
3483
3536
|
"div",
|
|
3484
3537
|
{
|
|
3485
|
-
className:
|
|
3486
|
-
style:
|
|
3538
|
+
className: g.root,
|
|
3539
|
+
style: h,
|
|
3487
3540
|
"data-testid": "schedule-assessment-loading",
|
|
3488
|
-
children: /* @__PURE__ */ t.jsx("div", { className:
|
|
3541
|
+
children: /* @__PURE__ */ t.jsx("div", { className: g.card, children: /* @__PURE__ */ t.jsx("p", { className: g.subtitle, children: "Loading available times…" }) })
|
|
3489
3542
|
}
|
|
3490
3543
|
);
|
|
3491
|
-
if (
|
|
3544
|
+
if (p.error)
|
|
3492
3545
|
return /* @__PURE__ */ t.jsx(
|
|
3493
3546
|
"div",
|
|
3494
3547
|
{
|
|
3495
|
-
className:
|
|
3496
|
-
style:
|
|
3548
|
+
className: g.root,
|
|
3549
|
+
style: h,
|
|
3497
3550
|
"data-testid": "schedule-assessment-error",
|
|
3498
|
-
children: /* @__PURE__ */ t.jsx("div", { className:
|
|
3551
|
+
children: /* @__PURE__ */ t.jsx("div", { className: g.card, children: /* @__PURE__ */ t.jsx("p", { className: g.subtitle, children: "We couldn't load available times. Please try again in a few minutes." }) })
|
|
3499
3552
|
}
|
|
3500
3553
|
);
|
|
3501
3554
|
if (C === "success") {
|
|
@@ -3503,11 +3556,11 @@ function $o({
|
|
|
3503
3556
|
return /* @__PURE__ */ t.jsx(
|
|
3504
3557
|
"div",
|
|
3505
3558
|
{
|
|
3506
|
-
className:
|
|
3507
|
-
style:
|
|
3559
|
+
className: g.root,
|
|
3560
|
+
style: h,
|
|
3508
3561
|
"data-testid": "schedule-assessment-success",
|
|
3509
|
-
children: /* @__PURE__ */ t.jsxs("div", { className:
|
|
3510
|
-
/* @__PURE__ */ t.jsx("div", { className:
|
|
3562
|
+
children: /* @__PURE__ */ t.jsxs("div", { className: g.card, children: [
|
|
3563
|
+
/* @__PURE__ */ t.jsx("div", { className: g.successCheckCircle, "aria-hidden": "true", children: /* @__PURE__ */ t.jsx("svg", { width: "20", height: "20", viewBox: "0 0 20 20", fill: "none", children: /* @__PURE__ */ t.jsx(
|
|
3511
3564
|
"path",
|
|
3512
3565
|
{
|
|
3513
3566
|
d: "M5 10.5l3 3 7-7",
|
|
@@ -3517,20 +3570,20 @@ function $o({
|
|
|
3517
3570
|
strokeLinejoin: "round"
|
|
3518
3571
|
}
|
|
3519
3572
|
) }) }),
|
|
3520
|
-
/* @__PURE__ */ t.jsx("h2", { className:
|
|
3521
|
-
/* @__PURE__ */ t.jsx("p", { className:
|
|
3522
|
-
/* @__PURE__ */ t.jsxs("div", { className:
|
|
3573
|
+
/* @__PURE__ */ t.jsx("h2", { className: g.title, children: F ? `${bo(F)}, your assessment is scheduled!` : "Your assessment is scheduled!" }),
|
|
3574
|
+
/* @__PURE__ */ t.jsx("p", { className: g.subtitle, children: "A calendar invite has been sent to your email address." }),
|
|
3575
|
+
/* @__PURE__ */ t.jsxs("div", { className: g.summaryCard, children: [
|
|
3523
3576
|
N && /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
|
|
3524
|
-
/* @__PURE__ */ t.jsxs("div", { className:
|
|
3577
|
+
/* @__PURE__ */ t.jsxs("div", { className: g.summaryRow, children: [
|
|
3525
3578
|
/* @__PURE__ */ t.jsx(ko, {}),
|
|
3526
|
-
/* @__PURE__ */ t.jsx("span", { children:
|
|
3579
|
+
/* @__PURE__ */ t.jsx("span", { children: vt(N, p.timezone) })
|
|
3527
3580
|
] }),
|
|
3528
|
-
/* @__PURE__ */ t.jsxs("div", { className:
|
|
3581
|
+
/* @__PURE__ */ t.jsxs("div", { className: g.summaryRow, children: [
|
|
3529
3582
|
/* @__PURE__ */ t.jsx(jo, {}),
|
|
3530
|
-
/* @__PURE__ */ t.jsx("span", { children:
|
|
3583
|
+
/* @__PURE__ */ t.jsx("span", { children: xt(N, p.timezone) })
|
|
3531
3584
|
] })
|
|
3532
3585
|
] }),
|
|
3533
|
-
s && /* @__PURE__ */ t.jsxs("div", { className:
|
|
3586
|
+
s && /* @__PURE__ */ t.jsxs("div", { className: g.summaryRow, children: [
|
|
3534
3587
|
/* @__PURE__ */ t.jsx(No, {}),
|
|
3535
3588
|
/* @__PURE__ */ t.jsx("span", { children: s })
|
|
3536
3589
|
] })
|
|
@@ -3539,8 +3592,8 @@ function $o({
|
|
|
3539
3592
|
"button",
|
|
3540
3593
|
{
|
|
3541
3594
|
type: "button",
|
|
3542
|
-
className:
|
|
3543
|
-
onClick: () =>
|
|
3595
|
+
className: g.primaryButton,
|
|
3596
|
+
onClick: () => m == null ? void 0 : m(),
|
|
3544
3597
|
children: "Done"
|
|
3545
3598
|
}
|
|
3546
3599
|
)
|
|
@@ -3549,26 +3602,26 @@ function $o({
|
|
|
3549
3602
|
);
|
|
3550
3603
|
}
|
|
3551
3604
|
if (C === "confirm") {
|
|
3552
|
-
const N = U.replace(/\D/g, ""), L = !K &&
|
|
3605
|
+
const N = U.replace(/\D/g, ""), L = !K && F.trim().length > 0 && N.length >= 10 && $ !== null && (!$ || ae.trim().length > 0), B = async () => {
|
|
3553
3606
|
if (!(!L || !P)) {
|
|
3554
3607
|
q(!0), ue(null);
|
|
3555
3608
|
try {
|
|
3556
|
-
const M =
|
|
3609
|
+
const M = $ ? `Customer: ${F.trim()}. Access instructions: ${ae.trim()}` : `Customer: ${F.trim()}. No gate code or entry restrictions.`, le = await u.scheduleAssessment({
|
|
3557
3610
|
offerId: e,
|
|
3558
3611
|
selectedInspectionTime: P,
|
|
3559
3612
|
reminderPhone: U.replace(/\D/g, ""),
|
|
3560
3613
|
notes: M
|
|
3561
3614
|
});
|
|
3562
|
-
|
|
3615
|
+
S("success");
|
|
3563
3616
|
try {
|
|
3564
3617
|
await (i == null ? void 0 : i(le.visitId));
|
|
3565
3618
|
} catch (xe) {
|
|
3566
3619
|
const ge = xe instanceof Error ? xe : new Error(String(xe));
|
|
3567
|
-
|
|
3620
|
+
d == null || d(ge);
|
|
3568
3621
|
}
|
|
3569
3622
|
} catch (M) {
|
|
3570
3623
|
const le = M instanceof Error ? M : new Error(String(M));
|
|
3571
|
-
ue(le.message),
|
|
3624
|
+
ue(le.message), d == null || d(le);
|
|
3572
3625
|
} finally {
|
|
3573
3626
|
q(!1);
|
|
3574
3627
|
}
|
|
@@ -3577,63 +3630,63 @@ function $o({
|
|
|
3577
3630
|
return /* @__PURE__ */ t.jsx(
|
|
3578
3631
|
"div",
|
|
3579
3632
|
{
|
|
3580
|
-
className:
|
|
3581
|
-
style:
|
|
3633
|
+
className: g.root,
|
|
3634
|
+
style: h,
|
|
3582
3635
|
"data-testid": "schedule-assessment-confirm",
|
|
3583
|
-
children: /* @__PURE__ */ t.jsxs("div", { className:
|
|
3584
|
-
/* @__PURE__ */ t.jsx("h2", { className:
|
|
3585
|
-
/* @__PURE__ */ t.jsxs("label", { className:
|
|
3586
|
-
/* @__PURE__ */ t.jsx("span", { className:
|
|
3636
|
+
children: /* @__PURE__ */ t.jsxs("div", { className: g.card, children: [
|
|
3637
|
+
/* @__PURE__ */ t.jsx("h2", { className: g.title, children: "Confirm your details" }),
|
|
3638
|
+
/* @__PURE__ */ t.jsxs("label", { className: g.field, children: [
|
|
3639
|
+
/* @__PURE__ */ t.jsx("span", { className: g.fieldLabel, children: "Customer name" }),
|
|
3587
3640
|
/* @__PURE__ */ t.jsx(
|
|
3588
3641
|
"input",
|
|
3589
3642
|
{
|
|
3590
|
-
className:
|
|
3643
|
+
className: g.input,
|
|
3591
3644
|
type: "text",
|
|
3592
|
-
value:
|
|
3645
|
+
value: F,
|
|
3593
3646
|
onChange: (M) => oe(M.target.value),
|
|
3594
3647
|
disabled: K
|
|
3595
3648
|
}
|
|
3596
3649
|
)
|
|
3597
3650
|
] }),
|
|
3598
|
-
/* @__PURE__ */ t.jsxs("label", { className:
|
|
3599
|
-
/* @__PURE__ */ t.jsx("span", { className:
|
|
3651
|
+
/* @__PURE__ */ t.jsxs("label", { className: g.field, children: [
|
|
3652
|
+
/* @__PURE__ */ t.jsx("span", { className: g.fieldLabel, children: "Phone number" }),
|
|
3600
3653
|
/* @__PURE__ */ t.jsx(
|
|
3601
3654
|
"input",
|
|
3602
3655
|
{
|
|
3603
|
-
className:
|
|
3656
|
+
className: g.input,
|
|
3604
3657
|
type: "tel",
|
|
3605
3658
|
inputMode: "tel",
|
|
3606
3659
|
autoComplete: "tel",
|
|
3607
3660
|
placeholder: "(555) 555-5555",
|
|
3608
3661
|
value: U,
|
|
3609
|
-
onChange: (M) =>
|
|
3662
|
+
onChange: (M) => A(qe(M.target.value)),
|
|
3610
3663
|
disabled: K
|
|
3611
3664
|
}
|
|
3612
3665
|
)
|
|
3613
3666
|
] }),
|
|
3614
|
-
/* @__PURE__ */ t.jsxs("fieldset", { className:
|
|
3615
|
-
/* @__PURE__ */ t.jsx("legend", { className:
|
|
3616
|
-
/* @__PURE__ */ t.jsxs("div", { className:
|
|
3617
|
-
/* @__PURE__ */ t.jsxs("label", { className:
|
|
3667
|
+
/* @__PURE__ */ t.jsxs("fieldset", { className: g.fieldset, children: [
|
|
3668
|
+
/* @__PURE__ */ t.jsx("legend", { className: g.fieldLabel, children: "Are there gate codes or entry restrictions?" }),
|
|
3669
|
+
/* @__PURE__ */ t.jsxs("div", { className: g.radioRow, children: [
|
|
3670
|
+
/* @__PURE__ */ t.jsxs("label", { className: g.radioOption, children: [
|
|
3618
3671
|
/* @__PURE__ */ t.jsx(
|
|
3619
3672
|
"input",
|
|
3620
3673
|
{
|
|
3621
3674
|
type: "radio",
|
|
3622
3675
|
name: "gate-code",
|
|
3623
|
-
checked:
|
|
3676
|
+
checked: $ === !0,
|
|
3624
3677
|
onChange: () => Z(!0),
|
|
3625
3678
|
disabled: K
|
|
3626
3679
|
}
|
|
3627
3680
|
),
|
|
3628
3681
|
/* @__PURE__ */ t.jsx("span", { children: "Yes" })
|
|
3629
3682
|
] }),
|
|
3630
|
-
/* @__PURE__ */ t.jsxs("label", { className:
|
|
3683
|
+
/* @__PURE__ */ t.jsxs("label", { className: g.radioOption, children: [
|
|
3631
3684
|
/* @__PURE__ */ t.jsx(
|
|
3632
3685
|
"input",
|
|
3633
3686
|
{
|
|
3634
3687
|
type: "radio",
|
|
3635
3688
|
name: "gate-code",
|
|
3636
|
-
checked:
|
|
3689
|
+
checked: $ === !1,
|
|
3637
3690
|
onChange: () => Z(!1),
|
|
3638
3691
|
disabled: K
|
|
3639
3692
|
}
|
|
@@ -3642,12 +3695,12 @@ function $o({
|
|
|
3642
3695
|
] })
|
|
3643
3696
|
] })
|
|
3644
3697
|
] }),
|
|
3645
|
-
|
|
3646
|
-
/* @__PURE__ */ t.jsx("span", { className:
|
|
3698
|
+
$ && /* @__PURE__ */ t.jsxs("label", { className: g.field, children: [
|
|
3699
|
+
/* @__PURE__ */ t.jsx("span", { className: g.fieldLabel, children: "Please provide access instructions for your home." }),
|
|
3647
3700
|
/* @__PURE__ */ t.jsx(
|
|
3648
3701
|
"input",
|
|
3649
3702
|
{
|
|
3650
|
-
className:
|
|
3703
|
+
className: g.input,
|
|
3651
3704
|
type: "text",
|
|
3652
3705
|
placeholder: "Gate code, directions, etc.",
|
|
3653
3706
|
value: ae,
|
|
@@ -3656,14 +3709,14 @@ function $o({
|
|
|
3656
3709
|
}
|
|
3657
3710
|
)
|
|
3658
3711
|
] }),
|
|
3659
|
-
ie && /* @__PURE__ */ t.jsx("p", { className:
|
|
3660
|
-
/* @__PURE__ */ t.jsxs("div", { className:
|
|
3712
|
+
ie && /* @__PURE__ */ t.jsx("p", { className: g.errorText, children: ie }),
|
|
3713
|
+
/* @__PURE__ */ t.jsxs("div", { className: g.actionsRow, children: [
|
|
3661
3714
|
/* @__PURE__ */ t.jsx(
|
|
3662
3715
|
"button",
|
|
3663
3716
|
{
|
|
3664
3717
|
type: "button",
|
|
3665
|
-
className:
|
|
3666
|
-
onClick: () =>
|
|
3718
|
+
className: g.linkButton,
|
|
3719
|
+
onClick: () => S("select"),
|
|
3667
3720
|
disabled: K,
|
|
3668
3721
|
children: "← Back"
|
|
3669
3722
|
}
|
|
@@ -3672,71 +3725,71 @@ function $o({
|
|
|
3672
3725
|
"button",
|
|
3673
3726
|
{
|
|
3674
3727
|
type: "button",
|
|
3675
|
-
className:
|
|
3728
|
+
className: g.primaryButton,
|
|
3676
3729
|
onClick: () => void B(),
|
|
3677
3730
|
disabled: !L,
|
|
3678
3731
|
children: K ? "Scheduling…" : "Schedule"
|
|
3679
3732
|
}
|
|
3680
3733
|
)
|
|
3681
3734
|
] }),
|
|
3682
|
-
/* @__PURE__ */ t.jsx("div", { className:
|
|
3735
|
+
/* @__PURE__ */ t.jsx("div", { className: g.faqBelowActions, children: /* @__PURE__ */ t.jsx(Po, { items: So }) })
|
|
3683
3736
|
] })
|
|
3684
3737
|
}
|
|
3685
3738
|
);
|
|
3686
3739
|
}
|
|
3687
|
-
const R = vo(j), J = xo(j), ye = Co(j, y), he = wo(j, y), me = k ? y.get(k) ?? [] : [], pe = me[0] ?
|
|
3740
|
+
const R = vo(j), J = xo(j), ye = Co(j, y), he = wo(j, y), me = k ? y.get(k) ?? [] : [], pe = me[0] ? vt(new Date(me[0]), p.timezone) : null;
|
|
3688
3741
|
return /* @__PURE__ */ t.jsx(
|
|
3689
3742
|
"div",
|
|
3690
3743
|
{
|
|
3691
|
-
className:
|
|
3692
|
-
style:
|
|
3744
|
+
className: g.root,
|
|
3745
|
+
style: h,
|
|
3693
3746
|
"data-testid": "schedule-assessment-flow",
|
|
3694
|
-
children: /* @__PURE__ */ t.jsx("div", { className:
|
|
3695
|
-
/* @__PURE__ */ t.jsxs("div", { className:
|
|
3696
|
-
/* @__PURE__ */ t.jsxs("div", { className:
|
|
3697
|
-
/* @__PURE__ */ t.jsx("h2", { className:
|
|
3698
|
-
/* @__PURE__ */ t.jsx("p", { className:
|
|
3747
|
+
children: /* @__PURE__ */ t.jsx("div", { className: g.card, children: /* @__PURE__ */ t.jsxs("div", { className: g.stepLayout, children: [
|
|
3748
|
+
/* @__PURE__ */ t.jsxs("div", { className: g.leftColumn, children: [
|
|
3749
|
+
/* @__PURE__ */ t.jsxs("div", { className: g.introHeader, children: [
|
|
3750
|
+
/* @__PURE__ */ t.jsx("h2", { className: g.titleLarge, children: "Schedule your assessment" }),
|
|
3751
|
+
/* @__PURE__ */ t.jsx("p", { className: g.subtitleLeft, children: "Pick a time that works for you." })
|
|
3699
3752
|
] }),
|
|
3700
|
-
/* @__PURE__ */ t.jsx("div", { className:
|
|
3701
|
-
/* @__PURE__ */ t.jsx("p", { className:
|
|
3702
|
-
/* @__PURE__ */ t.jsx("p", { className:
|
|
3753
|
+
/* @__PURE__ */ t.jsx("div", { className: g.featuresList, children: Io.map((N) => /* @__PURE__ */ t.jsxs("div", { className: g.feature, children: [
|
|
3754
|
+
/* @__PURE__ */ t.jsx("p", { className: g.featureTitle, children: N.title }),
|
|
3755
|
+
/* @__PURE__ */ t.jsx("p", { className: g.featureDescription, children: N.description })
|
|
3703
3756
|
] }, N.title)) })
|
|
3704
3757
|
] }),
|
|
3705
|
-
/* @__PURE__ */ t.jsxs("div", { className:
|
|
3706
|
-
/* @__PURE__ */ t.jsxs("div", { className:
|
|
3758
|
+
/* @__PURE__ */ t.jsxs("div", { className: g.schedule, children: [
|
|
3759
|
+
/* @__PURE__ */ t.jsxs("div", { className: g.calendarHeader, children: [
|
|
3707
3760
|
/* @__PURE__ */ t.jsx(
|
|
3708
3761
|
"button",
|
|
3709
3762
|
{
|
|
3710
3763
|
type: "button",
|
|
3711
|
-
className:
|
|
3712
|
-
onClick: () => ne(
|
|
3764
|
+
className: g.calendarNavButton,
|
|
3765
|
+
onClick: () => ne(Ct(j, -1)),
|
|
3713
3766
|
disabled: !ye,
|
|
3714
3767
|
"aria-label": "Previous month",
|
|
3715
3768
|
children: "‹"
|
|
3716
3769
|
}
|
|
3717
3770
|
),
|
|
3718
|
-
/* @__PURE__ */ t.jsx("span", { className:
|
|
3771
|
+
/* @__PURE__ */ t.jsx("span", { className: g.calendarMonthLabel, children: J }),
|
|
3719
3772
|
/* @__PURE__ */ t.jsx(
|
|
3720
3773
|
"button",
|
|
3721
3774
|
{
|
|
3722
3775
|
type: "button",
|
|
3723
|
-
className:
|
|
3724
|
-
onClick: () => ne(
|
|
3776
|
+
className: g.calendarNavButton,
|
|
3777
|
+
onClick: () => ne(Ct(j, 1)),
|
|
3725
3778
|
disabled: !he,
|
|
3726
3779
|
"aria-label": "Next month",
|
|
3727
3780
|
children: "›"
|
|
3728
3781
|
}
|
|
3729
3782
|
)
|
|
3730
3783
|
] }),
|
|
3731
|
-
/* @__PURE__ */ t.jsxs("div", { className:
|
|
3732
|
-
["SUN", "MON", "TUE", "WED", "THU", "FRI", "SAT"].map((N) => /* @__PURE__ */ t.jsx("div", { className:
|
|
3784
|
+
/* @__PURE__ */ t.jsxs("div", { className: g.calendarGrid, children: [
|
|
3785
|
+
["SUN", "MON", "TUE", "WED", "THU", "FRI", "SAT"].map((N) => /* @__PURE__ */ t.jsx("div", { className: g.calendarDayHeader, children: N }, N)),
|
|
3733
3786
|
R.map((N, L) => {
|
|
3734
3787
|
const B = N ? y.has(N.key) : !1, M = !!N && N.key === k;
|
|
3735
3788
|
return /* @__PURE__ */ t.jsx(
|
|
3736
3789
|
"button",
|
|
3737
3790
|
{
|
|
3738
3791
|
type: "button",
|
|
3739
|
-
className: M ?
|
|
3792
|
+
className: M ? g.calendarDaySelected : B ? g.calendarDayAvailable : g.calendarDayDisabled,
|
|
3740
3793
|
onClick: () => {
|
|
3741
3794
|
N && B && (H(N.key), Y(null));
|
|
3742
3795
|
},
|
|
@@ -3749,19 +3802,19 @@ function $o({
|
|
|
3749
3802
|
})
|
|
3750
3803
|
] }),
|
|
3751
3804
|
pe && /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
|
|
3752
|
-
/* @__PURE__ */ t.jsxs("p", { className:
|
|
3805
|
+
/* @__PURE__ */ t.jsxs("p", { className: g.timesHeader, children: [
|
|
3753
3806
|
"Available times for ",
|
|
3754
3807
|
pe
|
|
3755
3808
|
] }),
|
|
3756
|
-
/* @__PURE__ */ t.jsx("div", { className:
|
|
3809
|
+
/* @__PURE__ */ t.jsx("div", { className: g.timeRow, children: me.map((N) => {
|
|
3757
3810
|
const L = N === P;
|
|
3758
3811
|
return /* @__PURE__ */ t.jsx(
|
|
3759
3812
|
"button",
|
|
3760
3813
|
{
|
|
3761
3814
|
type: "button",
|
|
3762
|
-
className: L ?
|
|
3815
|
+
className: L ? g.timeButtonSelected : g.timeButton,
|
|
3763
3816
|
onClick: () => Y(N),
|
|
3764
|
-
children:
|
|
3817
|
+
children: xt(new Date(N), p.timezone)
|
|
3765
3818
|
},
|
|
3766
3819
|
N
|
|
3767
3820
|
);
|
|
@@ -3771,8 +3824,8 @@ function $o({
|
|
|
3771
3824
|
"button",
|
|
3772
3825
|
{
|
|
3773
3826
|
type: "button",
|
|
3774
|
-
className:
|
|
3775
|
-
onClick: () =>
|
|
3827
|
+
className: g.primaryButton,
|
|
3828
|
+
onClick: () => S("confirm"),
|
|
3776
3829
|
disabled: !P,
|
|
3777
3830
|
children: "Continue"
|
|
3778
3831
|
}
|
|
@@ -3789,7 +3842,7 @@ function qe(e) {
|
|
|
3789
3842
|
const r = e.replace(/\D/g, "").slice(0, 10);
|
|
3790
3843
|
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)}`;
|
|
3791
3844
|
}
|
|
3792
|
-
function
|
|
3845
|
+
function yt(e, r) {
|
|
3793
3846
|
const a = new Date(e);
|
|
3794
3847
|
return new Intl.DateTimeFormat("en-CA", {
|
|
3795
3848
|
timeZone: r,
|
|
@@ -3802,7 +3855,7 @@ function yo(e) {
|
|
|
3802
3855
|
const [r, a] = e.split("-").map((s) => parseInt(s, 10));
|
|
3803
3856
|
return { year: r, month: a - 1 };
|
|
3804
3857
|
}
|
|
3805
|
-
function
|
|
3858
|
+
function vt(e, r) {
|
|
3806
3859
|
return new Intl.DateTimeFormat(void 0, {
|
|
3807
3860
|
timeZone: r,
|
|
3808
3861
|
weekday: "long",
|
|
@@ -3810,7 +3863,7 @@ function bt(e, r) {
|
|
|
3810
3863
|
day: "numeric"
|
|
3811
3864
|
}).format(e);
|
|
3812
3865
|
}
|
|
3813
|
-
function
|
|
3866
|
+
function xt(e, r) {
|
|
3814
3867
|
return new Intl.DateTimeFormat(void 0, {
|
|
3815
3868
|
timeZone: r,
|
|
3816
3869
|
hour: "numeric",
|
|
@@ -3818,17 +3871,17 @@ function yt(e, r) {
|
|
|
3818
3871
|
hour12: !0
|
|
3819
3872
|
}).format(e);
|
|
3820
3873
|
}
|
|
3821
|
-
function
|
|
3874
|
+
function Ct(e, r) {
|
|
3822
3875
|
const a = e.year * 12 + e.month + r, s = Math.floor(a / 12), o = a - s * 12;
|
|
3823
3876
|
return { year: s, month: o };
|
|
3824
3877
|
}
|
|
3825
3878
|
function vo({ year: e, month: r }) {
|
|
3826
|
-
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 = [],
|
|
3827
|
-
for (let
|
|
3828
|
-
const
|
|
3829
|
-
|
|
3830
|
-
key: `${
|
|
3831
|
-
day:
|
|
3879
|
+
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 = [], m = String(e).padStart(4, "0"), f = String(r + 1).padStart(2, "0");
|
|
3880
|
+
for (let d = 0; d < o; d++) {
|
|
3881
|
+
const u = d - a + 1;
|
|
3882
|
+
u < 1 || u > s ? i.push(null) : i.push({
|
|
3883
|
+
key: `${m}-${f}-${String(u).padStart(2, "0")}`,
|
|
3884
|
+
day: u
|
|
3832
3885
|
});
|
|
3833
3886
|
}
|
|
3834
3887
|
return i;
|
|
@@ -3856,7 +3909,7 @@ function wo(e, r) {
|
|
|
3856
3909
|
}
|
|
3857
3910
|
return !1;
|
|
3858
3911
|
}
|
|
3859
|
-
function
|
|
3912
|
+
function Je() {
|
|
3860
3913
|
return {
|
|
3861
3914
|
width: 16,
|
|
3862
3915
|
height: 16,
|
|
@@ -3867,23 +3920,23 @@ function ze() {
|
|
|
3867
3920
|
strokeLinecap: "round",
|
|
3868
3921
|
strokeLinejoin: "round",
|
|
3869
3922
|
"aria-hidden": !0,
|
|
3870
|
-
className:
|
|
3923
|
+
className: g.summaryIcon
|
|
3871
3924
|
};
|
|
3872
3925
|
}
|
|
3873
3926
|
function ko() {
|
|
3874
|
-
return /* @__PURE__ */ t.jsxs("svg", { ...
|
|
3927
|
+
return /* @__PURE__ */ t.jsxs("svg", { ...Je(), children: [
|
|
3875
3928
|
/* @__PURE__ */ t.jsx("rect", { x: "2", y: "3.5", width: "12", height: "11", rx: "1.5" }),
|
|
3876
3929
|
/* @__PURE__ */ t.jsx("path", { d: "M2 6.5h12M5.5 2v3M10.5 2v3" })
|
|
3877
3930
|
] });
|
|
3878
3931
|
}
|
|
3879
3932
|
function jo() {
|
|
3880
|
-
return /* @__PURE__ */ t.jsxs("svg", { ...
|
|
3933
|
+
return /* @__PURE__ */ t.jsxs("svg", { ...Je(), children: [
|
|
3881
3934
|
/* @__PURE__ */ t.jsx("circle", { cx: "8", cy: "8", r: "6" }),
|
|
3882
3935
|
/* @__PURE__ */ t.jsx("path", { d: "M8 4.5V8l2.5 1.5" })
|
|
3883
3936
|
] });
|
|
3884
3937
|
}
|
|
3885
3938
|
function No() {
|
|
3886
|
-
return /* @__PURE__ */ t.jsxs("svg", { ...
|
|
3939
|
+
return /* @__PURE__ */ t.jsxs("svg", { ...Je(), children: [
|
|
3887
3940
|
/* @__PURE__ */ t.jsx("path", { d: "M8 14s-4.5-4-4.5-7.5a4.5 4.5 0 1 1 9 0C12.5 10 8 14 8 14z" }),
|
|
3888
3941
|
/* @__PURE__ */ t.jsx("circle", { cx: "8", cy: "6.5", r: "1.5" })
|
|
3889
3942
|
] });
|
|
@@ -3901,7 +3954,7 @@ const Io = [
|
|
|
3901
3954
|
title: "30 minutes or less",
|
|
3902
3955
|
description: "Examine the home's exterior and take a quick look inside."
|
|
3903
3956
|
}
|
|
3904
|
-
],
|
|
3957
|
+
], So = [
|
|
3905
3958
|
{
|
|
3906
3959
|
title: "What are you looking for during the assessment?",
|
|
3907
3960
|
body: "We will verify the property's condition matches your contract. We'll check the home's exterior and interior, including major systems, structure, and overall condition. This helps us confirm all details are accurate before closing."
|
|
@@ -3915,7 +3968,7 @@ const Io = [
|
|
|
3915
3968
|
body: "Once we're done with the home assessment, it typically takes a few days to email your final offer. You'll be able to see your final offer price along with the service charge, any repair cost, and your estimated closing costs."
|
|
3916
3969
|
}
|
|
3917
3970
|
];
|
|
3918
|
-
function
|
|
3971
|
+
function Eo() {
|
|
3919
3972
|
return /* @__PURE__ */ t.jsx(
|
|
3920
3973
|
"svg",
|
|
3921
3974
|
{
|
|
@@ -3928,7 +3981,7 @@ function So() {
|
|
|
3928
3981
|
strokeLinecap: "round",
|
|
3929
3982
|
strokeLinejoin: "round",
|
|
3930
3983
|
"aria-hidden": "true",
|
|
3931
|
-
className:
|
|
3984
|
+
className: g.faqChevron,
|
|
3932
3985
|
children: /* @__PURE__ */ t.jsx("path", { d: "M4 6l4 4 4-4" })
|
|
3933
3986
|
}
|
|
3934
3987
|
);
|
|
@@ -3936,14 +3989,14 @@ function So() {
|
|
|
3936
3989
|
function Po({
|
|
3937
3990
|
items: e
|
|
3938
3991
|
}) {
|
|
3939
|
-
return /* @__PURE__ */ t.jsxs("div", { className:
|
|
3940
|
-
/* @__PURE__ */ t.jsx("h3", { className:
|
|
3941
|
-
e.map((r) => /* @__PURE__ */ t.jsxs("details", { className:
|
|
3942
|
-
/* @__PURE__ */ t.jsxs("summary", { className:
|
|
3992
|
+
return /* @__PURE__ */ t.jsxs("div", { className: g.faq, children: [
|
|
3993
|
+
/* @__PURE__ */ t.jsx("h3", { className: g.faqHeader, children: "Frequently asked questions" }),
|
|
3994
|
+
e.map((r) => /* @__PURE__ */ t.jsxs("details", { className: g.faqItem, children: [
|
|
3995
|
+
/* @__PURE__ */ t.jsxs("summary", { className: g.faqQuestion, children: [
|
|
3943
3996
|
/* @__PURE__ */ t.jsx("span", { children: r.title }),
|
|
3944
|
-
/* @__PURE__ */ t.jsx(
|
|
3997
|
+
/* @__PURE__ */ t.jsx(Eo, {})
|
|
3945
3998
|
] }),
|
|
3946
|
-
/* @__PURE__ */ t.jsx("p", { className:
|
|
3999
|
+
/* @__PURE__ */ t.jsx("p", { className: g.faqAnswer, children: r.body })
|
|
3947
4000
|
] }, r.title))
|
|
3948
4001
|
] });
|
|
3949
4002
|
}
|
|
@@ -3951,11 +4004,11 @@ export {
|
|
|
3951
4004
|
Oo as AddressEntry,
|
|
3952
4005
|
Bo as AddressMap,
|
|
3953
4006
|
Ro as AddressUnitConfirmation,
|
|
3954
|
-
|
|
4007
|
+
Do as DTC_ONBOARDING_PAGE_IDS,
|
|
3955
4008
|
Mo as DtcOnboardingFlow,
|
|
3956
|
-
|
|
3957
|
-
|
|
3958
|
-
|
|
3959
|
-
|
|
3960
|
-
|
|
4009
|
+
Ao as OpendoorProvider,
|
|
4010
|
+
Fo as ScheduleAssessmentFlow,
|
|
4011
|
+
cr as THEMES,
|
|
4012
|
+
ur as resolveAppearance,
|
|
4013
|
+
Nt as useOpendoorClient
|
|
3961
4014
|
};
|