@calcom/atoms 1.0.95 → 1.0.96-beta-2
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/{AddressInput-jf7dQUjM.js → AddressInput-BwaFtJdW.js} +9 -8
- package/dist/{AlbyPriceComponent-xvHTaJkB.js → AlbyPriceComponent-5_IY8XI4.js} +53 -52
- package/dist/AppCard-vvom7JzI.js +162 -0
- package/dist/AppListCardPlatformWrapper-BMbohX9G.js +9 -0
- package/dist/{AppListCardWebWrapper-mvJDHeHP.js → AppListCardWebWrapper-jgSaE2tc.js} +10 -9
- package/dist/AppSettingsInterface-GvEAHqgC.js +23 -0
- package/dist/AppSettingsInterface-hahnFvsF.js +29 -0
- package/dist/AppSettingsInterface-rwvU2JZ1.js +75 -0
- package/dist/{DateRangePicker-sOCh5jbf.js → DateRangePicker-H2MDflCi.js} +784 -783
- package/dist/EventTypeAppCardInterface-12lncOdf.js +34 -0
- package/dist/EventTypeAppCardInterface-27TiN1LB.js +34 -0
- package/dist/EventTypeAppCardInterface-4REsm-ax.js +24 -0
- package/dist/EventTypeAppCardInterface-BIBLDaQW.js +41 -0
- package/dist/EventTypeAppCardInterface-Bxn2VRDe.js +42 -0
- package/dist/EventTypeAppCardInterface-Ia4uQvA6.js +24 -0
- package/dist/EventTypeAppCardInterface-IsxbWtC-.js +86 -0
- package/dist/EventTypeAppCardInterface-MYYfLsWy.js +31 -0
- package/dist/EventTypeAppCardInterface-TvEkNxDI.js +34 -0
- package/dist/EventTypeAppCardInterface-W-C-Vuq4.js +32 -0
- package/dist/EventTypeAppCardInterface-YC7gXugR.js +41 -0
- package/dist/EventTypeAppCardInterface-ZN2mBt9v.js +34 -0
- package/dist/EventTypeAppCardInterface-Ze5KpMAZ.js +24 -0
- package/dist/EventTypeAppCardInterface-ZshqKbPT.js +34 -0
- package/dist/{EventTypeAppCardInterface-fTBMlXsW.js → EventTypeAppCardInterface-_8D8Qs9P.js} +17 -16
- package/dist/EventTypeAppCardInterface-cXUeW2Wg.js +24 -0
- package/dist/EventTypeAppCardInterface-f4ubwOzR.js +42 -0
- package/dist/EventTypeAppCardInterface-g5WwbLf6.js +39 -0
- package/dist/EventTypeAppCardInterface-iMFMTR_Q.js +24 -0
- package/dist/EventTypeAppCardInterface-kh27UiaS.js +34 -0
- package/dist/EventTypeAppCardInterface-loGF0ZWc.js +452 -0
- package/dist/EventTypeAppCardInterface-mpaqmq1C.js +32 -0
- package/dist/EventTypeAppCardInterface-n2hGNKAo.js +34 -0
- package/dist/EventTypeAppCardInterface-nYtaHSPH.js +49 -0
- package/dist/EventTypeAppCardInterface-qIAbqcW-.js +51 -0
- package/dist/EventTypeAppCardInterface-zTg1f5hR.js +33 -0
- package/dist/{EventTypeAppSettingsInterface-uy_EiYRt.js → EventTypeAppSettingsInterface-2iQLRc2L.js} +6 -5
- package/dist/{EventTypeAppSettingsInterface-PqMppH4B.js → EventTypeAppSettingsInterface-4j95fNdX.js} +72 -71
- package/dist/EventTypeAppSettingsInterface-7r6Eayog.js +221 -0
- package/dist/{EventTypeAppSettingsInterface-WFmNo91Z.js → EventTypeAppSettingsInterface-8XJ_he7F.js} +7 -6
- package/dist/EventTypeAppSettingsInterface-PHF7Vsmi.js +43 -0
- package/dist/EventTypeAppSettingsInterface-ThYijWt9.js +42 -0
- package/dist/EventTypeAppSettingsInterface-WrZ3-X7V.js +48 -0
- package/dist/{EventTypeAppSettingsInterface-CJVHdj5Z.js → EventTypeAppSettingsInterface-eJdqCSck.js} +39 -38
- package/dist/{EventTypeAppSettingsInterface-W6KdgBF4.js → EventTypeAppSettingsInterface-hI24Lgxv.js} +6 -5
- package/dist/{EventTypeAppSettingsInterface-5MFFd8K-.js → EventTypeAppSettingsInterface-rDoWsnFN.js} +6 -5
- package/dist/EventTypeAppSettingsInterface-vOTw0emu.js +72 -0
- package/dist/EventTypeAppSettingsInterface-wRHYYE7a.js +78 -0
- package/dist/InstallAppButton-9T0Dl0KY.js +14 -0
- package/dist/InstallAppButton-J-143AmA.js +14 -0
- package/dist/{InstallAppButton-l1JAKXJ2.js → InstallAppButton-JXhBVaYJ.js} +8 -8
- package/dist/InstallAppButton-qpMMTpVW.js +58 -0
- package/dist/{PhoneInput-ZSx8kdAN.js → PhoneInput-EZYUI6dU.js} +97 -96
- package/dist/StripePaymentForm-N2YTyBqm.js +1157 -0
- package/dist/cal-atoms.js +6 -6
- package/dist/cal-atoms.umd.cjs +372 -436
- package/dist/{framer-features-12oM4SHg.js → framer-features-pqh7SjMd.js} +65 -65
- package/dist/{index-3tVCLfaZ.js → index-D4njVTQA.js} +2 -2
- package/dist/{index-LgmOiR20.js → index-KPOdbfnz.js} +1 -1
- package/dist/{index-xyF3DZet.js → index-_1f6rhg6.js} +72418 -98083
- package/dist/{index-sMgQwFEx.js → index-_1xRkNP6.js} +1 -1
- package/dist/index-v9tzGygd.js +626 -0
- package/dist/{isSupportedCountry-DPaP_R-3.js → isSupportedCountry--S1ZKbg0.js} +1 -1
- package/dist/packages/app-store/hitpay/pages/setup/index.d.ts.map +1 -1
- package/dist/packages/app-store/salesforce/lib/CrmService.d.ts.map +1 -1
- package/dist/packages/app-store/salesforce/lib/__tests__/salesforceMock.d.ts.map +1 -1
- package/dist/packages/features/eventtypes/components/EventTypeLayout.d.ts.map +1 -1
- package/dist/packages/features/schedules/components/DateOverrideList.d.ts +1 -1
- package/dist/packages/features/schedules/components/DateOverrideList.d.ts.map +1 -1
- package/dist/packages/features/shell/Shell.d.ts +0 -1
- package/dist/packages/features/shell/Shell.d.ts.map +1 -1
- package/dist/packages/platform/atoms/availability/AvailabilitySettings.d.ts +1 -1
- package/dist/packages/platform/atoms/availability/AvailabilitySettings.d.ts.map +1 -1
- package/dist/packages/platform/atoms/hooks/bookings/useHandleBookEvent.d.ts.map +1 -1
- package/dist/packages/platform/atoms/vite.config.d.ts.map +1 -1
- package/dist/packages/trpc/react/shared.d.ts +1 -1
- package/dist/packages/trpc/react/shared.d.ts.map +1 -1
- package/dist/packages/trpc/server/routers/_app.d.ts +469 -373
- package/dist/packages/trpc/server/routers/_app.d.ts.map +1 -1
- package/dist/packages/trpc/server/routers/loggedInViewer/_router.d.ts +0 -124
- package/dist/packages/trpc/server/routers/loggedInViewer/_router.d.ts.map +1 -1
- package/dist/packages/trpc/server/routers/viewer/__tests__/outOfOffice.handler.test.d.ts.map +1 -0
- package/dist/packages/trpc/server/routers/viewer/_router.d.ts +469 -373
- package/dist/packages/trpc/server/routers/viewer/_router.d.ts.map +1 -1
- package/dist/packages/trpc/server/routers/viewer/ooo/_router.d.ts +132 -0
- package/dist/packages/trpc/server/routers/viewer/ooo/_router.d.ts.map +1 -0
- package/dist/packages/trpc/server/routers/viewer/ooo/outOfOffice.utils.d.ts.map +1 -0
- package/dist/packages/trpc/server/routers/{loggedInViewer → viewer/ooo}/outOfOfficeCreateOrUpdate.handler.d.ts +1 -1
- package/dist/packages/trpc/server/routers/viewer/ooo/outOfOfficeCreateOrUpdate.handler.d.ts.map +1 -0
- package/dist/packages/trpc/server/routers/viewer/ooo/outOfOfficeCreateOrUpdate.schema.d.ts.map +1 -0
- package/dist/packages/trpc/server/routers/{loggedInViewer → viewer/ooo}/outOfOfficeEntriesList.handler.d.ts +6 -6
- package/dist/packages/trpc/server/routers/viewer/ooo/outOfOfficeEntriesList.handler.d.ts.map +1 -0
- package/dist/packages/trpc/server/routers/viewer/ooo/outOfOfficeEntriesList.schema.d.ts.map +1 -0
- package/dist/packages/trpc/server/routers/{loggedInViewer → viewer/ooo}/outOfOfficeEntryDelete.handler.d.ts +1 -1
- package/dist/packages/trpc/server/routers/viewer/ooo/outOfOfficeEntryDelete.handler.d.ts.map +1 -0
- package/dist/packages/trpc/server/routers/viewer/ooo/outOfOfficeEntryDelete.schema.d.ts.map +1 -0
- package/dist/packages/trpc/server/routers/viewer/ooo/outOfOfficeReasons.handler.d.ts.map +1 -0
- package/dist/packages/trpc/server/routers/viewer/travelSchedules/_router.d.ts +26 -0
- package/dist/packages/trpc/server/routers/viewer/travelSchedules/_router.d.ts.map +1 -0
- package/dist/packages/trpc/server/routers/{loggedInViewer → viewer/travelSchedules}/getTravelSchedules.handler.d.ts +1 -1
- package/dist/packages/trpc/server/routers/viewer/travelSchedules/getTravelSchedules.handler.d.ts.map +1 -0
- package/dist/packages/trpc/server/routers/viewer/travelSchedules/getTravelSchedules.schema.d.ts.map +1 -0
- package/dist/{useIsAppEnabled-lWZHByfn.js → useIsAppEnabled-EWMW2qIQ.js} +1 -1
- package/package.json +3 -2
- package/dist/AppCard-6POsrWUi.js +0 -161
- package/dist/AppListCardPlatformWrapper-lBuJfkuH.js +0 -8
- package/dist/AppSettingsInterface-4Tks23KV.js +0 -22
- package/dist/AppSettingsInterface-FOcRnk3Z.js +0 -28
- package/dist/AppSettingsInterface-GkmVYzlh.js +0 -74
- package/dist/EventTypeAppCardInterface-3WtIPV90.js +0 -48
- package/dist/EventTypeAppCardInterface-59_1Chn3.js +0 -23
- package/dist/EventTypeAppCardInterface-6vA3mNLM.js +0 -23
- package/dist/EventTypeAppCardInterface-8G0alNRB.js +0 -23
- package/dist/EventTypeAppCardInterface-DmRoseb5.js +0 -33
- package/dist/EventTypeAppCardInterface-E6oGIXby.js +0 -30
- package/dist/EventTypeAppCardInterface-F3iYQZzz.js +0 -33
- package/dist/EventTypeAppCardInterface-Gz942CB8.js +0 -41
- package/dist/EventTypeAppCardInterface-JtE97AbR.js +0 -38
- package/dist/EventTypeAppCardInterface-KoXkfIyN.js +0 -451
- package/dist/EventTypeAppCardInterface-O6Qm27_l.js +0 -33
- package/dist/EventTypeAppCardInterface-S1ri5C5w.js +0 -33
- package/dist/EventTypeAppCardInterface-SDs4emhR.js +0 -40
- package/dist/EventTypeAppCardInterface-_ilno5U4.js +0 -32
- package/dist/EventTypeAppCardInterface-b4zgfRie.js +0 -31
- package/dist/EventTypeAppCardInterface-dDQePpru.js +0 -33
- package/dist/EventTypeAppCardInterface-dxJA4SDA.js +0 -40
- package/dist/EventTypeAppCardInterface-dyUZdYi1.js +0 -31
- package/dist/EventTypeAppCardInterface-hEAZCP4y.js +0 -33
- package/dist/EventTypeAppCardInterface-iH8XDMJc.js +0 -23
- package/dist/EventTypeAppCardInterface-kzr8i-KV.js +0 -33
- package/dist/EventTypeAppCardInterface-nIcRzdps.js +0 -23
- package/dist/EventTypeAppCardInterface-n_WURLN6.js +0 -41
- package/dist/EventTypeAppCardInterface-oOvyPBbl.js +0 -85
- package/dist/EventTypeAppCardInterface-uxE48sJK.js +0 -50
- package/dist/EventTypeAppSettingsInterface-11qrPEq9.js +0 -47
- package/dist/EventTypeAppSettingsInterface-DQAYuCVY.js +0 -220
- package/dist/EventTypeAppSettingsInterface-G9QLW8nF.js +0 -42
- package/dist/EventTypeAppSettingsInterface-KP3N_MKJ.js +0 -71
- package/dist/EventTypeAppSettingsInterface-jExNP130.js +0 -77
- package/dist/EventTypeAppSettingsInterface-wvbPVzEw.js +0 -41
- package/dist/InstallAppButton-Texs62TM.js +0 -13
- package/dist/InstallAppButton-k-fI7lJG.js +0 -13
- package/dist/InstallAppButton-uI0Lr0hc.js +0 -57
- package/dist/StripePaymentForm-8vKNcyMv.js +0 -492
- package/dist/index-TRud8iK5.js +0 -510
- package/dist/packages/trpc/server/routers/loggedInViewer/__tests__/outOfOffice.handler.test.d.ts.map +0 -1
- package/dist/packages/trpc/server/routers/loggedInViewer/getTravelSchedules.handler.d.ts.map +0 -1
- package/dist/packages/trpc/server/routers/loggedInViewer/getTravelSchedules.schema.d.ts.map +0 -1
- package/dist/packages/trpc/server/routers/loggedInViewer/outOfOffice.utils.d.ts.map +0 -1
- package/dist/packages/trpc/server/routers/loggedInViewer/outOfOfficeCreateOrUpdate.handler.d.ts.map +0 -1
- package/dist/packages/trpc/server/routers/loggedInViewer/outOfOfficeCreateOrUpdate.schema.d.ts.map +0 -1
- package/dist/packages/trpc/server/routers/loggedInViewer/outOfOfficeEntriesList.handler.d.ts.map +0 -1
- package/dist/packages/trpc/server/routers/loggedInViewer/outOfOfficeEntriesList.schema.d.ts.map +0 -1
- package/dist/packages/trpc/server/routers/loggedInViewer/outOfOfficeEntryDelete.handler.d.ts.map +0 -1
- package/dist/packages/trpc/server/routers/loggedInViewer/outOfOfficeEntryDelete.schema.d.ts.map +0 -1
- package/dist/packages/trpc/server/routers/loggedInViewer/outOfOfficeReasons.handler.d.ts.map +0 -1
- /package/dist/packages/trpc/server/routers/{loggedInViewer → viewer}/__tests__/outOfOffice.handler.test.d.ts +0 -0
- /package/dist/packages/trpc/server/routers/{loggedInViewer → viewer/ooo}/outOfOffice.utils.d.ts +0 -0
- /package/dist/packages/trpc/server/routers/{loggedInViewer → viewer/ooo}/outOfOfficeCreateOrUpdate.schema.d.ts +0 -0
- /package/dist/packages/trpc/server/routers/{loggedInViewer → viewer/ooo}/outOfOfficeEntriesList.schema.d.ts +0 -0
- /package/dist/packages/trpc/server/routers/{loggedInViewer → viewer/ooo}/outOfOfficeEntryDelete.schema.d.ts +0 -0
- /package/dist/packages/trpc/server/routers/{loggedInViewer → viewer/ooo}/outOfOfficeReasons.handler.d.ts +0 -0
- /package/dist/packages/trpc/server/routers/{loggedInViewer → viewer/travelSchedules}/getTravelSchedules.schema.d.ts +0 -0
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import
|
|
3
|
-
import {
|
|
1
|
+
import { jsx as vt } from "react/jsx-runtime";
|
|
2
|
+
import Bt, { useState as Gt, useEffect as $t } from "react";
|
|
3
|
+
import { as as Vt, ak as qt, Z as It, R as Kt } from "./index-_1f6rhg6.js";
|
|
4
|
+
import { i as Ut } from "./isSupportedCountry--S1ZKbg0.js";
|
|
4
5
|
var Wt = function(U) {
|
|
5
6
|
var J = {};
|
|
6
7
|
function s(u) {
|
|
@@ -34,7 +35,7 @@ var Wt = function(U) {
|
|
|
34
35
|
return Object.prototype.hasOwnProperty.call(u, x);
|
|
35
36
|
}, s.p = "", s(s.s = 9);
|
|
36
37
|
}([function(U, J) {
|
|
37
|
-
U.exports =
|
|
38
|
+
U.exports = Bt;
|
|
38
39
|
}, function(U, J, s) {
|
|
39
40
|
var u;
|
|
40
41
|
/*!
|
|
@@ -67,7 +68,7 @@ var Wt = function(U) {
|
|
|
67
68
|
})();
|
|
68
69
|
}, function(U, J, s) {
|
|
69
70
|
(function(u) {
|
|
70
|
-
var x = /^\s+|\s+$/g, D = /^[-+]0x[0-9a-f]+$/i, te = /^0b[01]+$/i, re = /^0o[0-7]+$/i, ne = parseInt, Se = typeof u == "object" && u && u.Object === Object && u, be = typeof self == "object" && self && self.Object === Object && self, ge = Se || be || Function("return this")(), ve = Object.prototype.toString, Oe = ge.Symbol,
|
|
71
|
+
var x = /^\s+|\s+$/g, D = /^[-+]0x[0-9a-f]+$/i, te = /^0b[01]+$/i, re = /^0o[0-7]+$/i, ne = parseInt, Se = typeof u == "object" && u && u.Object === Object && u, be = typeof self == "object" && self && self.Object === Object && self, ge = Se || be || Function("return this")(), ve = Object.prototype.toString, Oe = ge.Symbol, ke = Oe ? Oe.prototype : void 0, _e = ke ? ke.toString : void 0;
|
|
71
72
|
function g(j) {
|
|
72
73
|
if (typeof j == "string")
|
|
73
74
|
return j;
|
|
@@ -76,7 +77,7 @@ var Wt = function(U) {
|
|
|
76
77
|
var b = j + "";
|
|
77
78
|
return b == "0" && 1 / j == -1 / 0 ? "-0" : b;
|
|
78
79
|
}
|
|
79
|
-
function
|
|
80
|
+
function Ee(j) {
|
|
80
81
|
var b = typeof j;
|
|
81
82
|
return !!j && (b == "object" || b == "function");
|
|
82
83
|
}
|
|
@@ -91,9 +92,9 @@ var Wt = function(U) {
|
|
|
91
92
|
return b;
|
|
92
93
|
if (R(b))
|
|
93
94
|
return NaN;
|
|
94
|
-
if (
|
|
95
|
+
if (Ee(b)) {
|
|
95
96
|
var W = typeof b.valueOf == "function" ? b.valueOf() : b;
|
|
96
|
-
b =
|
|
97
|
+
b = Ee(W) ? W + "" : W;
|
|
97
98
|
}
|
|
98
99
|
if (typeof b != "string")
|
|
99
100
|
return b === 0 ? b : +b;
|
|
@@ -123,50 +124,50 @@ var Wt = function(U) {
|
|
|
123
124
|
U.exports = s;
|
|
124
125
|
}, function(U, J, s) {
|
|
125
126
|
(function(u) {
|
|
126
|
-
var x = /^\[object .+?Constructor\]$/, D = typeof u == "object" && u && u.Object === Object && u, te = typeof self == "object" && self && self.Object === Object && self, re = D || te || Function("return this")(), ne, Se = Array.prototype, be = Function.prototype, ge = Object.prototype, ve = re["__core-js_shared__"], Oe = (ne = /[^.]+$/.exec(ve && ve.keys && ve.keys.IE_PROTO || "")) ? "Symbol(src)_1." + ne : "",
|
|
127
|
+
var x = /^\[object .+?Constructor\]$/, D = typeof u == "object" && u && u.Object === Object && u, te = typeof self == "object" && self && self.Object === Object && self, re = D || te || Function("return this")(), ne, Se = Array.prototype, be = Function.prototype, ge = Object.prototype, ve = re["__core-js_shared__"], Oe = (ne = /[^.]+$/.exec(ve && ve.keys && ve.keys.IE_PROTO || "")) ? "Symbol(src)_1." + ne : "", ke = be.toString, _e = ge.hasOwnProperty, g = ge.toString, Ee = RegExp("^" + ke.call(_e).replace(/[\\^$.*+?()[\]{}|]/g, "\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, "$1.*?") + "$"), R = Se.splice, V = Ce(re, "Map"), j = Ce(Object, "create");
|
|
127
128
|
function b(l) {
|
|
128
129
|
var y = -1, C = l ? l.length : 0;
|
|
129
130
|
for (this.clear(); ++y < C; ) {
|
|
130
|
-
var
|
|
131
|
-
this.set(
|
|
131
|
+
var k = l[y];
|
|
132
|
+
this.set(k[0], k[1]);
|
|
132
133
|
}
|
|
133
134
|
}
|
|
134
135
|
function W(l) {
|
|
135
136
|
var y = -1, C = l ? l.length : 0;
|
|
136
137
|
for (this.clear(); ++y < C; ) {
|
|
137
|
-
var
|
|
138
|
-
this.set(
|
|
138
|
+
var k = l[y];
|
|
139
|
+
this.set(k[0], k[1]);
|
|
139
140
|
}
|
|
140
141
|
}
|
|
141
142
|
function ce(l) {
|
|
142
143
|
var y = -1, C = l ? l.length : 0;
|
|
143
144
|
for (this.clear(); ++y < C; ) {
|
|
144
|
-
var
|
|
145
|
-
this.set(
|
|
145
|
+
var k = l[y];
|
|
146
|
+
this.set(k[0], k[1]);
|
|
146
147
|
}
|
|
147
148
|
}
|
|
148
149
|
function G(l, y) {
|
|
149
|
-
for (var C,
|
|
150
|
-
if ((C = l[fe][0]) === (
|
|
150
|
+
for (var C, k, fe = l.length; fe--; )
|
|
151
|
+
if ((C = l[fe][0]) === (k = y) || C != C && k != k)
|
|
151
152
|
return fe;
|
|
152
153
|
return -1;
|
|
153
154
|
}
|
|
154
155
|
function le(l) {
|
|
155
156
|
return !(!we(l) || (y = l, Oe && Oe in y)) && (function(C) {
|
|
156
|
-
var
|
|
157
|
-
return
|
|
157
|
+
var k = we(C) ? g.call(C) : "";
|
|
158
|
+
return k == "[object Function]" || k == "[object GeneratorFunction]";
|
|
158
159
|
}(l) || function(C) {
|
|
159
|
-
var
|
|
160
|
+
var k = !1;
|
|
160
161
|
if (C != null && typeof C.toString != "function")
|
|
161
162
|
try {
|
|
162
|
-
|
|
163
|
+
k = !!(C + "");
|
|
163
164
|
} catch {
|
|
164
165
|
}
|
|
165
|
-
return
|
|
166
|
-
}(l) ?
|
|
166
|
+
return k;
|
|
167
|
+
}(l) ? Ee : x).test(function(C) {
|
|
167
168
|
if (C != null) {
|
|
168
169
|
try {
|
|
169
|
-
return
|
|
170
|
+
return ke.call(C);
|
|
170
171
|
} catch {
|
|
171
172
|
}
|
|
172
173
|
try {
|
|
@@ -179,12 +180,12 @@ var Wt = function(U) {
|
|
|
179
180
|
var y;
|
|
180
181
|
}
|
|
181
182
|
function q(l, y) {
|
|
182
|
-
var C,
|
|
183
|
-
return ((
|
|
183
|
+
var C, k, fe = l.__data__;
|
|
184
|
+
return ((k = typeof (C = y)) == "string" || k == "number" || k == "symbol" || k == "boolean" ? C !== "__proto__" : C === null) ? fe[typeof y == "string" ? "string" : "hash"] : fe.map;
|
|
184
185
|
}
|
|
185
186
|
function Ce(l, y) {
|
|
186
|
-
var C = function(
|
|
187
|
-
return
|
|
187
|
+
var C = function(k, fe) {
|
|
188
|
+
return k == null ? void 0 : k[fe];
|
|
188
189
|
}(l, y);
|
|
189
190
|
return le(C) ? C : void 0;
|
|
190
191
|
}
|
|
@@ -192,10 +193,10 @@ var Wt = function(U) {
|
|
|
192
193
|
if (typeof l != "function" || y && typeof y != "function")
|
|
193
194
|
throw new TypeError("Expected a function");
|
|
194
195
|
var C = function() {
|
|
195
|
-
var
|
|
196
|
+
var k = arguments, fe = y ? y.apply(this, k) : k[0], Ae = C.cache;
|
|
196
197
|
if (Ae.has(fe))
|
|
197
198
|
return Ae.get(fe);
|
|
198
|
-
var m = l.apply(this,
|
|
199
|
+
var m = l.apply(this, k);
|
|
199
200
|
return C.cache = Ae.set(fe, m), m;
|
|
200
201
|
};
|
|
201
202
|
return C.cache = new (me.Cache || ce)(), C;
|
|
@@ -231,8 +232,8 @@ var Wt = function(U) {
|
|
|
231
232
|
}, W.prototype.has = function(l) {
|
|
232
233
|
return G(this.__data__, l) > -1;
|
|
233
234
|
}, W.prototype.set = function(l, y) {
|
|
234
|
-
var C = this.__data__,
|
|
235
|
-
return
|
|
235
|
+
var C = this.__data__, k = G(C, l);
|
|
236
|
+
return k < 0 ? C.push([l, y]) : C[k][1] = y, this;
|
|
236
237
|
}, ce.prototype.clear = function() {
|
|
237
238
|
this.__data__ = { hash: new b(), map: new (V || W)(), string: new b() };
|
|
238
239
|
}, ce.prototype.delete = function(l) {
|
|
@@ -247,14 +248,14 @@ var Wt = function(U) {
|
|
|
247
248
|
}).call(this, s(3));
|
|
248
249
|
}, function(U, J, s) {
|
|
249
250
|
(function(u) {
|
|
250
|
-
var x = /^\s+|\s+$/g, D = /^[-+]0x[0-9a-f]+$/i, te = /^0b[01]+$/i, re = /^0o[0-7]+$/i, ne = parseInt, Se = typeof u == "object" && u && u.Object === Object && u, be = typeof self == "object" && self && self.Object === Object && self, ge = Se || be || Function("return this")(), ve = Object.prototype.toString, Oe = Math.max,
|
|
251
|
+
var x = /^\s+|\s+$/g, D = /^[-+]0x[0-9a-f]+$/i, te = /^0b[01]+$/i, re = /^0o[0-7]+$/i, ne = parseInt, Se = typeof u == "object" && u && u.Object === Object && u, be = typeof self == "object" && self && self.Object === Object && self, ge = Se || be || Function("return this")(), ve = Object.prototype.toString, Oe = Math.max, ke = Math.min, _e = function() {
|
|
251
252
|
return ge.Date.now();
|
|
252
253
|
};
|
|
253
254
|
function g(R) {
|
|
254
255
|
var V = typeof R;
|
|
255
256
|
return !!R && (V == "object" || V == "function");
|
|
256
257
|
}
|
|
257
|
-
function
|
|
258
|
+
function Ee(R) {
|
|
258
259
|
if (typeof R == "number")
|
|
259
260
|
return R;
|
|
260
261
|
if (function(b) {
|
|
@@ -284,24 +285,24 @@ var Wt = function(U) {
|
|
|
284
285
|
function C(c) {
|
|
285
286
|
return Ce = c, le = setTimeout(fe, V), me ? y(c) : G;
|
|
286
287
|
}
|
|
287
|
-
function
|
|
288
|
+
function k(c) {
|
|
288
289
|
var N = c - q;
|
|
289
290
|
return q === void 0 || N >= V || N < 0 || we && c - Ce >= ce;
|
|
290
291
|
}
|
|
291
292
|
function fe() {
|
|
292
293
|
var c = _e();
|
|
293
|
-
if (
|
|
294
|
+
if (k(c))
|
|
294
295
|
return Ae(c);
|
|
295
296
|
le = setTimeout(fe, function(N) {
|
|
296
297
|
var P = V - (N - q);
|
|
297
|
-
return we ?
|
|
298
|
+
return we ? ke(P, ce - (N - Ce)) : P;
|
|
298
299
|
}(c));
|
|
299
300
|
}
|
|
300
301
|
function Ae(c) {
|
|
301
302
|
return le = void 0, l && b ? y(c) : (b = W = void 0, G);
|
|
302
303
|
}
|
|
303
304
|
function m() {
|
|
304
|
-
var c = _e(), N =
|
|
305
|
+
var c = _e(), N = k(c);
|
|
305
306
|
if (b = arguments, W = this, q = c, N) {
|
|
306
307
|
if (le === void 0)
|
|
307
308
|
return C(q);
|
|
@@ -310,7 +311,7 @@ var Wt = function(U) {
|
|
|
310
311
|
}
|
|
311
312
|
return le === void 0 && (le = setTimeout(fe, V)), G;
|
|
312
313
|
}
|
|
313
|
-
return V =
|
|
314
|
+
return V = Ee(V) || 0, g(j) && (me = !!j.leading, ce = (we = "maxWait" in j) ? Oe(Ee(j.maxWait) || 0, V) : ce, l = "trailing" in j ? !!j.trailing : l), m.cancel = function() {
|
|
314
315
|
le !== void 0 && clearTimeout(le), Ce = 0, b = q = W = le = void 0;
|
|
315
316
|
}, m.flush = function() {
|
|
316
317
|
return le === void 0 ? G : Ae(_e());
|
|
@@ -319,9 +320,9 @@ var Wt = function(U) {
|
|
|
319
320
|
}).call(this, s(3));
|
|
320
321
|
}, function(U, J, s) {
|
|
321
322
|
(function(u, x) {
|
|
322
|
-
var D = "[object Arguments]", te = "[object Map]", re = "[object Object]", ne = "[object Set]", Se = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, be = /^\w*$/, ge = /^\./, ve = /[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g, Oe = /\\(\\)?/g,
|
|
323
|
+
var D = "[object Arguments]", te = "[object Map]", re = "[object Object]", ne = "[object Set]", Se = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, be = /^\w*$/, ge = /^\./, ve = /[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g, Oe = /\\(\\)?/g, ke = /^\[object .+?Constructor\]$/, _e = /^(?:0|[1-9]\d*)$/, g = {};
|
|
323
324
|
g["[object Float32Array]"] = g["[object Float64Array]"] = g["[object Int8Array]"] = g["[object Int16Array]"] = g["[object Int32Array]"] = g["[object Uint8Array]"] = g["[object Uint8ClampedArray]"] = g["[object Uint16Array]"] = g["[object Uint32Array]"] = !0, g[D] = g["[object Array]"] = g["[object ArrayBuffer]"] = g["[object Boolean]"] = g["[object DataView]"] = g["[object Date]"] = g["[object Error]"] = g["[object Function]"] = g[te] = g["[object Number]"] = g[re] = g["[object RegExp]"] = g[ne] = g["[object String]"] = g["[object WeakMap]"] = !1;
|
|
324
|
-
var
|
|
325
|
+
var Ee = typeof u == "object" && u && u.Object === Object && u, R = typeof self == "object" && self && self.Object === Object && self, V = Ee || R || Function("return this")(), j = J && !J.nodeType && J, b = j && typeof x == "object" && x && !x.nodeType && x, W = b && b.exports === j && Ee.process, ce = function() {
|
|
325
326
|
try {
|
|
326
327
|
return W && W.binding("util");
|
|
327
328
|
} catch {
|
|
@@ -365,9 +366,9 @@ var Wt = function(U) {
|
|
|
365
366
|
a[++r] = i;
|
|
366
367
|
}), a;
|
|
367
368
|
}
|
|
368
|
-
var y, C,
|
|
369
|
-
return C(
|
|
370
|
-
}), se = Ue(V, "DataView"), de = Ue(V, "Map"), ie = Ue(V, "Promise"), n = Ue(V, "Set"), o = Ue(V, "WeakMap"), d = Ue(Object, "create"),
|
|
369
|
+
var y, C, k, fe = Array.prototype, Ae = Function.prototype, m = Object.prototype, c = V["__core-js_shared__"], N = (y = /[^.]+$/.exec(c && c.keys && c.keys.IE_PROTO || "")) ? "Symbol(src)_1." + y : "", P = Ae.toString, f = m.hasOwnProperty, t = m.toString, z = RegExp("^" + P.call(f).replace(/[\\^$.*+?()[\]{}|]/g, "\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, "$1.*?") + "$"), M = V.Symbol, L = V.Uint8Array, ae = m.propertyIsEnumerable, Y = fe.splice, oe = (C = Object.keys, k = Object, function(e) {
|
|
370
|
+
return C(k(e));
|
|
371
|
+
}), se = Ue(V, "DataView"), de = Ue(V, "Map"), ie = Ue(V, "Promise"), n = Ue(V, "Set"), o = Ue(V, "WeakMap"), d = Ue(Object, "create"), E = $e(se), O = $e(de), T = $e(ie), A = $e(n), K = $e(o), p = M ? M.prototype : void 0, S = p ? p.valueOf : void 0, F = p ? p.toString : void 0;
|
|
371
372
|
function h(e) {
|
|
372
373
|
var r = -1, a = e ? e.length : 0;
|
|
373
374
|
for (this.clear(); ++r < a; ) {
|
|
@@ -544,9 +545,9 @@ var Wt = function(U) {
|
|
|
544
545
|
return !1;
|
|
545
546
|
}(w, I, ue, Z, ee, $, B);
|
|
546
547
|
if (!(2 & $)) {
|
|
547
|
-
var Qe = xe && f.call(w, "__wrapped__"),
|
|
548
|
-
if (Qe ||
|
|
549
|
-
var Rt = Qe ? w.value() : w, zt =
|
|
548
|
+
var Qe = xe && f.call(w, "__wrapped__"), kt = Ve && f.call(I, "__wrapped__");
|
|
549
|
+
if (Qe || kt) {
|
|
550
|
+
var Rt = Qe ? w.value() : w, zt = kt ? I.value() : I;
|
|
550
551
|
return B || (B = new ye()), Z(Rt, zt, ee, $, B);
|
|
551
552
|
}
|
|
552
553
|
}
|
|
@@ -559,9 +560,9 @@ var Wt = function(U) {
|
|
|
559
560
|
if (!(Fe ? Be in H : f.call(H, Be)))
|
|
560
561
|
return !1;
|
|
561
562
|
}
|
|
562
|
-
var
|
|
563
|
-
if (
|
|
564
|
-
return
|
|
563
|
+
var Et = Ne.get(Q);
|
|
564
|
+
if (Et && Ne.get(H))
|
|
565
|
+
return Et == H;
|
|
565
566
|
var ut = !0;
|
|
566
567
|
Ne.set(Q, H), Ne.set(H, Q);
|
|
567
568
|
for (var gt = Fe; ++We < Ye; ) {
|
|
@@ -586,7 +587,7 @@ var Wt = function(U) {
|
|
|
586
587
|
function Ze(e) {
|
|
587
588
|
return !(!rt(e) || function(r) {
|
|
588
589
|
return !!N && N in r;
|
|
589
|
-
}(e)) && (Ot(e) || me(e) ? z :
|
|
590
|
+
}(e)) && (Ot(e) || me(e) ? z : ke).test($e(e));
|
|
590
591
|
}
|
|
591
592
|
function At(e) {
|
|
592
593
|
return typeof e == "function" ? e : e == null ? Lt : typeof e == "object" ? Le(e) ? function(i, _) {
|
|
@@ -729,7 +730,7 @@ var Wt = function(U) {
|
|
|
729
730
|
var r = t.call(e), a = r == re ? e.constructor : void 0, i = a ? $e(a) : void 0;
|
|
730
731
|
if (i)
|
|
731
732
|
switch (i) {
|
|
732
|
-
case
|
|
733
|
+
case E:
|
|
733
734
|
return "[object DataView]";
|
|
734
735
|
case O:
|
|
735
736
|
return te;
|
|
@@ -909,13 +910,13 @@ var Wt = function(U) {
|
|
|
909
910
|
return c.__proto__ || Object.getPrototypeOf(c);
|
|
910
911
|
})(m);
|
|
911
912
|
}
|
|
912
|
-
function
|
|
913
|
-
return (
|
|
913
|
+
function ke(m, c) {
|
|
914
|
+
return (ke = Object.setPrototypeOf || function(N, P) {
|
|
914
915
|
return N.__proto__ = P, N;
|
|
915
916
|
})(m, c);
|
|
916
917
|
}
|
|
917
918
|
s.r(J);
|
|
918
|
-
var _e = s(0), g = s.n(_e),
|
|
919
|
+
var _e = s(0), g = s.n(_e), Ee = s(5), R = s.n(Ee), V = s(4), j = s.n(V), b = s(6), W = s.n(b), ce = s(2), G = s.n(ce), le = s(1), q = s.n(le);
|
|
919
920
|
s(8);
|
|
920
921
|
function Ce(m, c) {
|
|
921
922
|
return te(m) || function(N, P) {
|
|
@@ -977,7 +978,7 @@ var Wt = function(U) {
|
|
|
977
978
|
});
|
|
978
979
|
}
|
|
979
980
|
}
|
|
980
|
-
function
|
|
981
|
+
function k(m, c) {
|
|
981
982
|
return c.length === 0 ? m : m.map(function(N) {
|
|
982
983
|
var P = c.findIndex(function(t) {
|
|
983
984
|
return t[0] === N[2];
|
|
@@ -1046,7 +1047,7 @@ var Wt = function(U) {
|
|
|
1046
1047
|
var n = function(p, S, F) {
|
|
1047
1048
|
var h = [];
|
|
1048
1049
|
return C(h, 1, p, !0), C(h, 3, S), C(h, 2, F), h;
|
|
1049
|
-
}(L, ae, Y), o =
|
|
1050
|
+
}(L, ae, Y), o = k(JSON.parse(JSON.stringify(me)), n), d = k(JSON.parse(JSON.stringify(we)), n), E = Ce(y(o, c, se, de, ie), 2), O = E[0], T = E[1];
|
|
1050
1051
|
if (N) {
|
|
1051
1052
|
var A = Ce(y(d, c, se, de, ie), 2), K = A[0];
|
|
1052
1053
|
A[1], O = this.sortTerritories(K, O);
|
|
@@ -1061,9 +1062,9 @@ var Wt = function(U) {
|
|
|
1061
1062
|
return n && n.length !== 0 ? t.state.onlyCountries.filter(function(o) {
|
|
1062
1063
|
return G()(o.name.toLowerCase(), n.toLowerCase());
|
|
1063
1064
|
}, ve(ve(t)))[0] : null;
|
|
1064
|
-
}), t.guessSelectedCountry = j()(function(n, o, d,
|
|
1065
|
+
}), t.guessSelectedCountry = j()(function(n, o, d, E) {
|
|
1065
1066
|
var O;
|
|
1066
|
-
if (t.props.enableAreaCodes === !1 && (
|
|
1067
|
+
if (t.props.enableAreaCodes === !1 && (E.some(function(K) {
|
|
1067
1068
|
if (G()(n, K.dialCode))
|
|
1068
1069
|
return d.some(function(p) {
|
|
1069
1070
|
if (K.iso2 === p.iso2 && p.mainCode)
|
|
@@ -1082,21 +1083,21 @@ var Wt = function(U) {
|
|
|
1082
1083
|
return A.name ? A : T;
|
|
1083
1084
|
}), t.updateCountry = function(n) {
|
|
1084
1085
|
var o, d = t.state.onlyCountries;
|
|
1085
|
-
(o = n.indexOf(0) >= "0" && n.indexOf(0) <= "9" ? d.find(function(
|
|
1086
|
-
return
|
|
1087
|
-
}) : d.find(function(
|
|
1088
|
-
return
|
|
1086
|
+
(o = n.indexOf(0) >= "0" && n.indexOf(0) <= "9" ? d.find(function(E) {
|
|
1087
|
+
return E.dialCode == +n;
|
|
1088
|
+
}) : d.find(function(E) {
|
|
1089
|
+
return E.iso2 == n;
|
|
1089
1090
|
})) && o.dialCode && t.setState({ selectedCountry: o, formattedNumber: t.props.disableCountryCode ? "" : t.formatNumber(o.dialCode, o) });
|
|
1090
1091
|
}, t.scrollTo = function(n, o) {
|
|
1091
1092
|
if (n) {
|
|
1092
1093
|
var d = t.dropdownRef;
|
|
1093
1094
|
if (d && document.body) {
|
|
1094
|
-
var
|
|
1095
|
+
var E = d.offsetHeight, O = d.getBoundingClientRect().top + document.body.scrollTop, T = O + E, A = n, K = A.getBoundingClientRect(), p = A.offsetHeight, S = K.top + document.body.scrollTop, F = S + p, h = S - O + d.scrollTop, v = E / 2 - p / 2;
|
|
1095
1096
|
if (t.props.enableSearch ? S < O + 32 : S < O)
|
|
1096
1097
|
o && (h -= v), d.scrollTop = h;
|
|
1097
1098
|
else if (F > T) {
|
|
1098
1099
|
o && (h += v);
|
|
1099
|
-
var X =
|
|
1100
|
+
var X = E - p;
|
|
1100
1101
|
d.scrollTop = h - X;
|
|
1101
1102
|
}
|
|
1102
1103
|
}
|
|
@@ -1107,8 +1108,8 @@ var Wt = function(U) {
|
|
|
1107
1108
|
}, t.formatNumber = function(n, o) {
|
|
1108
1109
|
if (!o)
|
|
1109
1110
|
return n;
|
|
1110
|
-
var d,
|
|
1111
|
-
if (T ? ((d =
|
|
1111
|
+
var d, E = o.format, O = t.props, T = O.disableCountryCode, A = O.enableAreaCodeStretch, K = O.enableLongNumbers, p = O.autoFormat;
|
|
1112
|
+
if (T ? ((d = E.split(" ")).shift(), d = d.join(" ")) : A && o.isAreaCode ? ((d = E.split(" "))[1] = d[1].replace(/\.+/, "".padEnd(o.areaCodeLength, ".")), d = d.join(" ")) : d = E, !n || n.length === 0)
|
|
1112
1113
|
return T ? "" : t.props.prefix;
|
|
1113
1114
|
if (n && n.length < 2 || !d || !p)
|
|
1114
1115
|
return T ? n : t.props.prefix + n;
|
|
@@ -1134,7 +1135,7 @@ var Wt = function(U) {
|
|
|
1134
1135
|
return t.state.selectedCountry ? { name: t.state.selectedCountry.name || "", dialCode: t.state.selectedCountry.dialCode || "", countryCode: t.state.selectedCountry.iso2 || "", format: t.state.selectedCountry.format || "" } : {};
|
|
1135
1136
|
}, t.handleFlagDropdownClick = function(n) {
|
|
1136
1137
|
if (n.preventDefault(), t.state.showDropdown || !t.props.disabled) {
|
|
1137
|
-
var o = t.state, d = o.preferredCountries,
|
|
1138
|
+
var o = t.state, d = o.preferredCountries, E = o.onlyCountries, O = o.selectedCountry, T = t.concatPreferredCountries(d, E).findIndex(function(A) {
|
|
1138
1139
|
return A.dialCode === O.dialCode && A.iso2 === O.iso2;
|
|
1139
1140
|
});
|
|
1140
1141
|
t.setState({ showDropdown: !t.state.showDropdown, highlightCountryIndex: T }, function() {
|
|
@@ -1142,15 +1143,15 @@ var Wt = function(U) {
|
|
|
1142
1143
|
});
|
|
1143
1144
|
}
|
|
1144
1145
|
}, t.handleInput = function(n) {
|
|
1145
|
-
var o = n.target.value, d = t.props,
|
|
1146
|
+
var o = n.target.value, d = t.props, E = d.prefix, O = d.onChange, T = t.props.disableCountryCode ? "" : E, A = t.state.selectedCountry, K = t.state.freezeSelection;
|
|
1146
1147
|
if (!t.props.countryCodeEditable) {
|
|
1147
|
-
var p =
|
|
1148
|
+
var p = E + (A.hasAreaCodes ? t.state.onlyCountries.find(function(pe) {
|
|
1148
1149
|
return pe.iso2 === A.iso2 && pe.mainCode;
|
|
1149
1150
|
}).dialCode : A.dialCode);
|
|
1150
1151
|
if (o.slice(0, p.length) !== p)
|
|
1151
1152
|
return;
|
|
1152
1153
|
}
|
|
1153
|
-
if (o ===
|
|
1154
|
+
if (o === E)
|
|
1154
1155
|
return O && O("", t.getCountryData(), n, ""), t.setState({ formattedNumber: "" });
|
|
1155
1156
|
if (!(o.replace(/\D/g, "").length > 15 && (t.props.enableLongNumbers === !1 || typeof t.props.enableLongNumbers == "number" && o.replace(/\D/g, "").length > t.props.enableLongNumbers)) && o !== t.state.formattedNumber) {
|
|
1156
1157
|
n.preventDefault ? n.preventDefault() : n.returnValue = !1;
|
|
@@ -1170,12 +1171,12 @@ var Wt = function(U) {
|
|
|
1170
1171
|
var o = n.target.value.length;
|
|
1171
1172
|
n.target.setSelectionRange(0, o);
|
|
1172
1173
|
}, t.handleFlagItemClick = function(n, o) {
|
|
1173
|
-
var d = t.state.selectedCountry,
|
|
1174
|
+
var d = t.state.selectedCountry, E = t.state.onlyCountries.find(function(K) {
|
|
1174
1175
|
return K == n;
|
|
1175
1176
|
});
|
|
1176
|
-
if (
|
|
1177
|
-
var O = t.state.formattedNumber.replace(" ", "").replace("(", "").replace(")", "").replace("-", ""), T = O.length > 1 ? O.replace(d.dialCode,
|
|
1178
|
-
t.setState({ showDropdown: !1, selectedCountry:
|
|
1177
|
+
if (E) {
|
|
1178
|
+
var O = t.state.formattedNumber.replace(" ", "").replace("(", "").replace(")", "").replace("-", ""), T = O.length > 1 ? O.replace(d.dialCode, E.dialCode) : E.dialCode, A = t.formatNumber(T.replace(/\D/g, ""), E);
|
|
1179
|
+
t.setState({ showDropdown: !1, selectedCountry: E, freezeSelection: !0, formattedNumber: A, searchValue: "" }, function() {
|
|
1179
1180
|
t.cursorToEnd(), t.props.onChange && t.props.onChange(A.replace(/[^0-9]+/g, ""), t.getCountryData(), o, A);
|
|
1180
1181
|
});
|
|
1181
1182
|
}
|
|
@@ -1206,17 +1207,17 @@ var Wt = function(U) {
|
|
|
1206
1207
|
return n.target.blur();
|
|
1207
1208
|
if (t.state.showDropdown && !t.props.disabled && (!d.includes("search-box") || n.which === o.UP || n.which === o.DOWN || n.which === o.ENTER || n.which === o.ESC && n.target.value === "")) {
|
|
1208
1209
|
n.preventDefault ? n.preventDefault() : n.returnValue = !1;
|
|
1209
|
-
var
|
|
1210
|
+
var E = function(O) {
|
|
1210
1211
|
t.setState({ highlightCountryIndex: t.getHighlightCountryIndex(O) }, function() {
|
|
1211
1212
|
t.scrollTo(t.getElement(t.state.highlightCountryIndex), !0);
|
|
1212
1213
|
});
|
|
1213
1214
|
};
|
|
1214
1215
|
switch (n.which) {
|
|
1215
1216
|
case o.DOWN:
|
|
1216
|
-
|
|
1217
|
+
E(1);
|
|
1217
1218
|
break;
|
|
1218
1219
|
case o.UP:
|
|
1219
|
-
|
|
1220
|
+
E(-1);
|
|
1220
1221
|
break;
|
|
1221
1222
|
case o.ENTER:
|
|
1222
1223
|
t.props.enableSearch ? t.handleFlagItemClick(t.getSearchFilteredCountries()[t.state.highlightCountryIndex] || t.getSearchFilteredCountries()[0], n) : t.handleFlagItemClick([].concat(D(t.state.preferredCountries), D(t.state.onlyCountries))[t.state.highlightCountryIndex], n);
|
|
@@ -1230,15 +1231,15 @@ var Wt = function(U) {
|
|
|
1230
1231
|
}
|
|
1231
1232
|
}
|
|
1232
1233
|
}, t.handleInputKeyDown = function(n) {
|
|
1233
|
-
var o = t.props, d = o.keys,
|
|
1234
|
-
n.which === d.ENTER &&
|
|
1234
|
+
var o = t.props, d = o.keys, E = o.onEnterKeyPress, O = o.onKeyDown;
|
|
1235
|
+
n.which === d.ENTER && E && E(n), O && O(n);
|
|
1235
1236
|
}, t.handleClickOutside = function(n) {
|
|
1236
1237
|
t.dropdownRef && !t.dropdownContainerRef.contains(n.target) && t.state.showDropdown && t.setState({ showDropdown: !1 });
|
|
1237
1238
|
}, t.handleSearchChange = function(n) {
|
|
1238
|
-
var o = n.currentTarget.value, d = t.state,
|
|
1239
|
+
var o = n.currentTarget.value, d = t.state, E = d.preferredCountries, O = d.selectedCountry, T = 0;
|
|
1239
1240
|
if (o === "" && O) {
|
|
1240
1241
|
var A = t.state.onlyCountries;
|
|
1241
|
-
T = t.concatPreferredCountries(
|
|
1242
|
+
T = t.concatPreferredCountries(E, A).findIndex(function(K) {
|
|
1242
1243
|
return K == O;
|
|
1243
1244
|
}), setTimeout(function() {
|
|
1244
1245
|
return t.scrollTo(t.getElement(T));
|
|
@@ -1250,7 +1251,7 @@ var Wt = function(U) {
|
|
|
1250
1251
|
}, t.getDropdownCountryName = function(n) {
|
|
1251
1252
|
return n.localName || n.name;
|
|
1252
1253
|
}, t.getSearchFilteredCountries = function() {
|
|
1253
|
-
var n = t.state, o = n.preferredCountries, d = n.onlyCountries,
|
|
1254
|
+
var n = t.state, o = n.preferredCountries, d = n.onlyCountries, E = n.searchValue, O = t.props.enableSearch, T = t.concatPreferredCountries(o, d), A = E.trim().toLowerCase().replace("+", "");
|
|
1254
1255
|
if (O && A) {
|
|
1255
1256
|
if (/^\d+$/.test(A))
|
|
1256
1257
|
return T.filter(function(S) {
|
|
@@ -1274,7 +1275,7 @@ var Wt = function(U) {
|
|
|
1274
1275
|
}
|
|
1275
1276
|
return T;
|
|
1276
1277
|
}, t.getCountryDropdownList = function() {
|
|
1277
|
-
var n = t.state, o = n.preferredCountries, d = n.highlightCountryIndex,
|
|
1278
|
+
var n = t.state, o = n.preferredCountries, d = n.highlightCountryIndex, E = n.showDropdown, O = n.searchValue, T = t.props, A = T.disableDropdown, K = T.prefix, p = t.props, S = p.enableSearch, F = p.searchNotFound, h = p.disableSearchIcon, v = p.searchClass, X = p.searchStyle, je = p.searchPlaceholder, ye = p.autocompleteSearch, Te = t.getSearchFilteredCountries().map(function(pe, Ke) {
|
|
1278
1279
|
var He = d === Ke, dt = q()({ country: !0, preferred: pe.iso2 === "us" || pe.iso2 === "gb", active: pe.iso2 === "us", highlight: He }), Je = "flag ".concat(pe.iso2);
|
|
1279
1280
|
return g.a.createElement("li", Object.assign({ ref: function(Ze) {
|
|
1280
1281
|
return t["flag_no_".concat(Ke)] = Ze;
|
|
@@ -1283,7 +1284,7 @@ var Wt = function(U) {
|
|
|
1283
1284
|
}, role: "option" }, He ? { "aria-selected": !0 } : {}), g.a.createElement("div", { className: Je }), g.a.createElement("span", { className: "country-name" }, t.getDropdownCountryName(pe)), g.a.createElement("span", { className: "dial-code" }, pe.format ? t.formatNumber(pe.dialCode, pe) : K + pe.dialCode));
|
|
1284
1285
|
}), Pe = g.a.createElement("li", { key: "dashes", className: "divider" });
|
|
1285
1286
|
o.length > 0 && (!S || S && !O.trim()) && Te.splice(o.length, 0, Pe);
|
|
1286
|
-
var Ge = q()(u({ "country-list": !0, hide: !
|
|
1287
|
+
var Ge = q()(u({ "country-list": !0, hide: !E }, t.props.dropdownClass, !0));
|
|
1287
1288
|
return g.a.createElement("ul", { ref: function(pe) {
|
|
1288
1289
|
return !S && pe && pe.focus(), t.dropdownRef = pe;
|
|
1289
1290
|
}, className: Ge, style: t.props.dropdownStyle, role: "listbox", tabIndex: "0" }, S && g.a.createElement("li", { className: q()(u({ search: !0 }, v, v)) }, !h && g.a.createElement("span", { className: q()(u({ "search-emoji": !0 }, "".concat(v, "-emoji"), v)), role: "img", "aria-label": "Magnifying glass" }, "🔎"), g.a.createElement("input", { className: q()(u({ "search-box": !0 }, "".concat(v, "-box"), v)), style: X, type: "search", placeholder: je, autoFocus: !0, autoComplete: ye ? "on" : "off", value: O, onChange: t.handleSearchChange })), Te.length > 0 ? Te : g.a.createElement("li", { className: "no-entries-message" }, g.a.createElement("span", null, F)));
|
|
@@ -1303,7 +1304,7 @@ var Wt = function(U) {
|
|
|
1303
1304
|
return function(f, t) {
|
|
1304
1305
|
if (typeof t != "function" && t !== null)
|
|
1305
1306
|
throw new TypeError("Super expression must either be null or a function");
|
|
1306
|
-
f.prototype = Object.create(t && t.prototype, { constructor: { value: f, writable: !0, configurable: !0 } }), t &&
|
|
1307
|
+
f.prototype = Object.create(t && t.prototype, { constructor: { value: f, writable: !0, configurable: !0 } }), t && ke(f, t);
|
|
1307
1308
|
}(c, m), N = c, (P = [{ key: "componentDidMount", value: function() {
|
|
1308
1309
|
document.addEventListener && this.props.enableClickOutside && document.addEventListener("mousedown", this.handleClickOutside), this.props.onMount && this.props.onMount(this.state.formattedNumber.replace(/[^0-9]+/g, ""), this.getCountryData(), this.state.formattedNumber);
|
|
1309
1310
|
} }, { key: "componentWillUnmount", value: function() {
|
|
@@ -1324,12 +1325,12 @@ var Wt = function(U) {
|
|
|
1324
1325
|
de = this.formatNumber((this.props.disableCountryCode ? "" : n) + ie, se || void 0), this.setState({ selectedCountry: se, formattedNumber: de });
|
|
1325
1326
|
}
|
|
1326
1327
|
} }, { key: "render", value: function() {
|
|
1327
|
-
var f, t, z, M = this, L = this.state, ae = L.onlyCountries, Y = L.selectedCountry, oe = L.showDropdown, se = L.formattedNumber, de = L.hiddenAreaCodes, ie = this.props, n = ie.disableDropdown, o = ie.renderStringAsFlag, d = ie.isValid,
|
|
1328
|
+
var f, t, z, M = this, L = this.state, ae = L.onlyCountries, Y = L.selectedCountry, oe = L.showDropdown, se = L.formattedNumber, de = L.hiddenAreaCodes, ie = this.props, n = ie.disableDropdown, o = ie.renderStringAsFlag, d = ie.isValid, E = ie.defaultErrorMessage, O = ie.specialLabel;
|
|
1328
1329
|
if (typeof d == "boolean")
|
|
1329
1330
|
t = d;
|
|
1330
1331
|
else {
|
|
1331
1332
|
var T = d(se.replace(/\D/g, ""), Y, ae, de);
|
|
1332
|
-
typeof T == "boolean" ? (t = T) === !1 && (z =
|
|
1333
|
+
typeof T == "boolean" ? (t = T) === !1 && (z = E) : (t = !1, z = T);
|
|
1333
1334
|
}
|
|
1334
1335
|
var A = q()((u(f = {}, this.props.containerClass, !0), u(f, "react-tel-input", !0), f)), K = q()({ arrow: !0, up: oe }), p = q()(u({ "form-control": !0, "invalid-number": !t, open: oe }, this.props.inputClass, !0)), S = q()({ "selected-flag": !0, open: oe }), F = q()(u({ "flag-dropdown": !0, "invalid-number": !t, open: oe }, this.props.buttonClass, !0)), h = "flag ".concat(Y && Y.iso2);
|
|
1335
1336
|
return g.a.createElement("div", { className: "".concat(A, " ").concat(this.props.className), style: this.props.style || this.props.containerStyle, onKeyDown: this.handleKeydown }, O && g.a.createElement("div", { className: "special-label" }, O), z && g.a.createElement("div", { className: "invalid-number-message" }, z), g.a.createElement("input", Object.assign({ className: p, style: this.props.inputStyle, onChange: this.handleInput, onClick: this.handleInputClick, onDoubleClick: this.handleDoubleClick, onFocus: this.handleInputFocus, onBlur: this.handleInputBlur, onCopy: this.handleInputCopy, value: se, onKeyDown: this.handleInputKeyDown, placeholder: this.props.placeholder, disabled: this.props.disabled, type: "tel" }, this.props.inputProps, { ref: function(v) {
|
|
@@ -1341,8 +1342,8 @@ var Wt = function(U) {
|
|
|
1341
1342
|
}(g.a.Component);
|
|
1342
1343
|
Ae.defaultProps = { country: "", value: "", onlyCountries: [], preferredCountries: [], excludeCountries: [], placeholder: "1 (702) 123-4567", searchPlaceholder: "search", searchNotFound: "No entries to show", flagsImagePath: "./flags.png", disabled: !1, containerStyle: {}, inputStyle: {}, buttonStyle: {}, dropdownStyle: {}, searchStyle: {}, containerClass: "", inputClass: "", buttonClass: "", dropdownClass: "", searchClass: "", className: "", autoFormat: !0, enableAreaCodes: !1, enableTerritories: !1, disableCountryCode: !1, disableDropdown: !1, enableLongNumbers: !1, countryCodeEditable: !0, enableSearch: !1, disableSearchIcon: !1, disableInitialCountryGuess: !1, disableCountryGuess: !1, regions: "", inputProps: {}, localization: {}, masks: null, priority: null, areaCodes: null, preserveOrder: [], defaultMask: "... ... ... ... ..", alwaysDefaultMask: !1, prefix: "+", copyNumbersOnly: !0, renderStringAsFlag: "", autocompleteSearch: !1, jumpCursorToEnd: !0, enableAreaCodeStretch: !1, enableClickOutside: !0, showDropdown: !1, isValid: !0, defaultErrorMessage: "", specialLabel: "Phone", onEnterKeyPress: null, keys: { UP: 38, DOWN: 40, RIGHT: 39, LEFT: 37, ENTER: 13, ESC: 27, PLUS: 43, A: 65, Z: 90, SPACE: 32, TAB: 9 } }, J.default = Ae;
|
|
1343
1344
|
}]);
|
|
1344
|
-
const Dt = /* @__PURE__ */
|
|
1345
|
-
function
|
|
1345
|
+
const Dt = /* @__PURE__ */ Vt(Wt);
|
|
1346
|
+
function er({
|
|
1346
1347
|
name: U,
|
|
1347
1348
|
className: J = "",
|
|
1348
1349
|
onChange: s,
|
|
@@ -1350,7 +1351,7 @@ function Xt({
|
|
|
1350
1351
|
defaultCountry: x = "us",
|
|
1351
1352
|
...D
|
|
1352
1353
|
}) {
|
|
1353
|
-
return
|
|
1354
|
+
return qt() ? /* @__PURE__ */ vt(
|
|
1354
1355
|
Dt,
|
|
1355
1356
|
{
|
|
1356
1357
|
...D,
|
|
@@ -1387,7 +1388,7 @@ function Xt({
|
|
|
1387
1388
|
},
|
|
1388
1389
|
dropdownStyle: { width: "max-content" }
|
|
1389
1390
|
}
|
|
1390
|
-
) : /* @__PURE__ */ vt
|
|
1391
|
+
) : /* @__PURE__ */ vt(Ht, { name: U, className: J, onChange: s, value: u, ...D });
|
|
1391
1392
|
}
|
|
1392
1393
|
function Ht({
|
|
1393
1394
|
name: U,
|
|
@@ -1397,7 +1398,7 @@ function Ht({
|
|
|
1397
1398
|
...x
|
|
1398
1399
|
}) {
|
|
1399
1400
|
const D = Jt();
|
|
1400
|
-
return /* @__PURE__ */ vt
|
|
1401
|
+
return /* @__PURE__ */ vt(
|
|
1401
1402
|
Dt,
|
|
1402
1403
|
{
|
|
1403
1404
|
...x,
|
|
@@ -1437,12 +1438,12 @@ function Ht({
|
|
|
1437
1438
|
);
|
|
1438
1439
|
}
|
|
1439
1440
|
const Jt = () => {
|
|
1440
|
-
const [U, J] =
|
|
1441
|
+
const [U, J] = Gt("us"), s = Kt.viewer.public.countryCode.useQuery(void 0, {
|
|
1441
1442
|
refetchOnWindowFocus: !1,
|
|
1442
1443
|
refetchOnReconnect: !1,
|
|
1443
1444
|
retry: !1
|
|
1444
1445
|
});
|
|
1445
|
-
return
|
|
1446
|
+
return $t(
|
|
1446
1447
|
function() {
|
|
1447
1448
|
var D;
|
|
1448
1449
|
const x = s.data;
|
|
@@ -1452,5 +1453,5 @@ const Jt = () => {
|
|
|
1452
1453
|
), U;
|
|
1453
1454
|
};
|
|
1454
1455
|
export {
|
|
1455
|
-
|
|
1456
|
+
er as default
|
|
1456
1457
|
};
|