@rpcbase/ui 0.252.0 → 0.254.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/Notifications/types.d.ts +2 -0
- package/dist/components/Notifications/types.d.ts.map +1 -1
- package/dist/index10.js +2 -2
- package/dist/index106.js +1 -1
- package/dist/index11.js +2 -2
- package/dist/index12.js +3 -3
- package/dist/index120.js +10 -10
- package/dist/index122.js +2 -2
- package/dist/index123.js +3 -3
- package/dist/index13.js +2 -2
- package/dist/index14.js +2 -2
- package/dist/index15.js +2 -2
- package/dist/index16.js +8 -8
- package/dist/index167.js +3 -3
- package/dist/index17.js +1 -1
- package/dist/index172.js +3 -3
- package/dist/index175.js +1 -1
- package/dist/index176.js +4 -4
- package/dist/index18.js +7 -7
- package/dist/index182.js +2 -2
- package/dist/index184.js +4 -4
- package/dist/index185.js +14 -14
- package/dist/index186.js +1 -1
- package/dist/index187.js +1 -1
- package/dist/index188.js +6 -6
- package/dist/index189.js +2 -2
- package/dist/index19.js +16 -16
- package/dist/index192.js +2 -2
- package/dist/index193.js +6 -6
- package/dist/index21.js +1 -1
- package/dist/index22.js +2 -2
- package/dist/index23.js +1 -1
- package/dist/index235.js +27 -14
- package/dist/index235.js.map +1 -1
- package/dist/index236.js +12 -7
- package/dist/index236.js.map +1 -1
- package/dist/index237.js +24 -9
- package/dist/index237.js.map +1 -1
- package/dist/index238.js +5 -10
- package/dist/index238.js.map +1 -1
- package/dist/index239.js +15 -20
- package/dist/index239.js.map +1 -1
- package/dist/index24.js +1 -1
- package/dist/index240.js +7 -8
- package/dist/index240.js.map +1 -1
- package/dist/index241.js +10 -9
- package/dist/index241.js.map +1 -1
- package/dist/index242.js +10 -9
- package/dist/index242.js.map +1 -1
- package/dist/index243.js +21 -4
- package/dist/index243.js.map +1 -1
- package/dist/index244.js +8 -5
- package/dist/index244.js.map +1 -1
- package/dist/index245.js +9 -16
- package/dist/index245.js.map +1 -1
- package/dist/index246.js +8 -8
- package/dist/index246.js.map +1 -1
- package/dist/index247.js +4 -18
- package/dist/index247.js.map +1 -1
- package/dist/index248.js +5 -20
- package/dist/index248.js.map +1 -1
- package/dist/index249.js +16 -12
- package/dist/index249.js.map +1 -1
- package/dist/index25.js +1 -1
- package/dist/index250.js +9 -29
- package/dist/index250.js.map +1 -1
- package/dist/index251.js +18 -12
- package/dist/index251.js.map +1 -1
- package/dist/index252.js +20 -25
- package/dist/index252.js.map +1 -1
- package/dist/index253.js +12 -5
- package/dist/index253.js.map +1 -1
- package/dist/index260.js +2 -2
- package/dist/index273.js +1 -1
- package/dist/index277.js +25 -20
- package/dist/index277.js.map +1 -1
- package/dist/index278.js +24 -62
- package/dist/index278.js.map +1 -1
- package/dist/index279.js +16 -6
- package/dist/index279.js.map +1 -1
- package/dist/index28.js +1 -1
- package/dist/index280.js +20 -6
- package/dist/index280.js.map +1 -1
- package/dist/index281.js +66 -11
- package/dist/index281.js.map +1 -1
- package/dist/index282.js +6 -3
- package/dist/index282.js.map +1 -1
- package/dist/index283.js +5 -50
- package/dist/index283.js.map +1 -1
- package/dist/index284.js +12 -4
- package/dist/index284.js.map +1 -1
- package/dist/index285.js +3 -29
- package/dist/index285.js.map +1 -1
- package/dist/index286.js +49 -15
- package/dist/index286.js.map +1 -1
- package/dist/index287.js +4 -6
- package/dist/index287.js.map +1 -1
- package/dist/index288.js +28 -20
- package/dist/index288.js.map +1 -1
- package/dist/index289.js +15 -52
- package/dist/index289.js.map +1 -1
- package/dist/index29.js +3 -56
- package/dist/index29.js.map +1 -1
- package/dist/index290.js +5 -20
- package/dist/index290.js.map +1 -1
- package/dist/index291.js +21 -41
- package/dist/index291.js.map +1 -1
- package/dist/index292.js +53 -39
- package/dist/index292.js.map +1 -1
- package/dist/index293.js +21 -46
- package/dist/index293.js.map +1 -1
- package/dist/index294.js +40 -19
- package/dist/index294.js.map +1 -1
- package/dist/index295.js +38 -69
- package/dist/index295.js.map +1 -1
- package/dist/index296.js +46 -18
- package/dist/index296.js.map +1 -1
- package/dist/index297.js +20 -3
- package/dist/index297.js.map +1 -1
- package/dist/index298.js +69 -10
- package/dist/index298.js.map +1 -1
- package/dist/index299.js +16 -12
- package/dist/index299.js.map +1 -1
- package/dist/index3.js +2 -2
- package/dist/index30.js +242 -3
- package/dist/index30.js.map +1 -1
- package/dist/index300.js +3 -18
- package/dist/index300.js.map +1 -1
- package/dist/index301.js +11 -36
- package/dist/index301.js.map +1 -1
- package/dist/index302.js +12 -238
- package/dist/index302.js.map +1 -1
- package/dist/index303.js +15 -249
- package/dist/index303.js.map +1 -1
- package/dist/index304.js +35 -67
- package/dist/index304.js.map +1 -1
- package/dist/index305.js +233 -93
- package/dist/index305.js.map +1 -1
- package/dist/index306.js +243 -74
- package/dist/index306.js.map +1 -1
- package/dist/index307.js +68 -3
- package/dist/index307.js.map +1 -1
- package/dist/index308.js +96 -26
- package/dist/index308.js.map +1 -1
- package/dist/index309.js +83 -16
- package/dist/index309.js.map +1 -1
- package/dist/index31.js +21 -239
- package/dist/index31.js.map +1 -1
- package/dist/index310.js +4 -35
- package/dist/index310.js.map +1 -1
- package/dist/index311.js +28 -16
- package/dist/index311.js.map +1 -1
- package/dist/index312.js +16 -3
- package/dist/index312.js.map +1 -1
- package/dist/index313.js +35 -27
- package/dist/index313.js.map +1 -1
- package/dist/index314.js +17 -28
- package/dist/index314.js.map +1 -1
- package/dist/index315.js +4 -4
- package/dist/index315.js.map +1 -1
- package/dist/index316.js +23 -75
- package/dist/index316.js.map +1 -1
- package/dist/index317.js +25 -269
- package/dist/index317.js.map +1 -1
- package/dist/index318.js +4 -12
- package/dist/index318.js.map +1 -1
- package/dist/index319.js +79 -11
- package/dist/index319.js.map +1 -1
- package/dist/index32.js +4 -23
- package/dist/index32.js.map +1 -1
- package/dist/index320.js +270 -23
- package/dist/index320.js.map +1 -1
- package/dist/index321.js +11 -16
- package/dist/index321.js.map +1 -1
- package/dist/index322.js +10 -125
- package/dist/index322.js.map +1 -1
- package/dist/index323.js +24 -4
- package/dist/index323.js.map +1 -1
- package/dist/index324.js +16 -65
- package/dist/index324.js.map +1 -1
- package/dist/index325.js +125 -13
- package/dist/index325.js.map +1 -1
- package/dist/index326.js +5 -7
- package/dist/index326.js.map +1 -1
- package/dist/index327.js +65 -5
- package/dist/index327.js.map +1 -1
- package/dist/index328.js +14 -4
- package/dist/index328.js.map +1 -1
- package/dist/index329.js +7 -10
- package/dist/index329.js.map +1 -1
- package/dist/index33.js +6 -3
- package/dist/index33.js.map +1 -1
- package/dist/index330.js +5 -7
- package/dist/index330.js.map +1 -1
- package/dist/index331.js +3 -133
- package/dist/index331.js.map +1 -1
- package/dist/index332.js +9 -398
- package/dist/index332.js.map +1 -1
- package/dist/index333.js +8 -5
- package/dist/index333.js.map +1 -1
- package/dist/index334.js +131 -50
- package/dist/index334.js.map +1 -1
- package/dist/index335.js +399 -11
- package/dist/index335.js.map +1 -1
- package/dist/index336.js +5 -28
- package/dist/index336.js.map +1 -1
- package/dist/index337.js +52 -11
- package/dist/index337.js.map +1 -1
- package/dist/index338.js +11 -24
- package/dist/index338.js.map +1 -1
- package/dist/index339.js +27 -28
- package/dist/index339.js.map +1 -1
- package/dist/index34.js +38 -8
- package/dist/index34.js.map +1 -1
- package/dist/index340.js +11 -16
- package/dist/index340.js.map +1 -1
- package/dist/index341.js +1 -1
- package/dist/index348.js +5 -51
- package/dist/index348.js.map +1 -1
- package/dist/index349.js +51 -5
- package/dist/index349.js.map +1 -1
- package/dist/index35.js +74 -35
- package/dist/index35.js.map +1 -1
- package/dist/index350.js +3 -3
- package/dist/index358.js +5 -5
- package/dist/index359.js +1 -1
- package/dist/index36.js +20 -74
- package/dist/index36.js.map +1 -1
- package/dist/index363.js +5 -5
- package/dist/index368.js +11 -5
- package/dist/index368.js.map +1 -1
- package/dist/index369.js +6 -3
- package/dist/index369.js.map +1 -1
- package/dist/index37.js +33 -18
- package/dist/index37.js.map +1 -1
- package/dist/index370.js +3 -12
- package/dist/index370.js.map +1 -1
- package/dist/index372.js +1 -1
- package/dist/index375.js +2 -2
- package/dist/index376.js +3 -3
- package/dist/index377.js +8 -8
- package/dist/index379.js +5 -5
- package/dist/index38.js +26 -36
- package/dist/index38.js.map +1 -1
- package/dist/index380.js +3 -3
- package/dist/index382.js +1 -1
- package/dist/index384.js +1 -1
- package/dist/index385.js +2 -2
- package/dist/index386.js +1 -1
- package/dist/index388.js +2 -2
- package/dist/index389.js +2 -2
- package/dist/index39.js +21 -26
- package/dist/index39.js.map +1 -1
- package/dist/index399.js +2 -2
- package/dist/index4.js +2 -2
- package/dist/index40.js +56 -20
- package/dist/index40.js.map +1 -1
- package/dist/index41.js +51 -59
- package/dist/index41.js.map +1 -1
- package/dist/index411.js +3 -15
- package/dist/index411.js.map +1 -1
- package/dist/index412.js +15 -3
- package/dist/index412.js.map +1 -1
- package/dist/index413.js +1 -1
- package/dist/index414.js +68 -5
- package/dist/index414.js.map +1 -1
- package/dist/index415.js +30 -55
- package/dist/index415.js.map +1 -1
- package/dist/index416.js +9 -68
- package/dist/index416.js.map +1 -1
- package/dist/index417.js +148 -26
- package/dist/index417.js.map +1 -1
- package/dist/index418.js +108 -9
- package/dist/index418.js.map +1 -1
- package/dist/index419.js +5 -153
- package/dist/index419.js.map +1 -1
- package/dist/index42.js +21 -50
- package/dist/index42.js.map +1 -1
- package/dist/index420.js +54 -106
- package/dist/index420.js.map +1 -1
- package/dist/index43.js +127 -18
- package/dist/index43.js.map +1 -1
- package/dist/index44.js +39 -122
- package/dist/index44.js.map +1 -1
- package/dist/index45.js +85 -42
- package/dist/index45.js.map +1 -1
- package/dist/index46.js +123 -87
- package/dist/index46.js.map +1 -1
- package/dist/index47.js +5 -126
- package/dist/index47.js.map +1 -1
- package/dist/index48.js +332 -5
- package/dist/index48.js.map +1 -1
- package/dist/index49.js +245 -320
- package/dist/index49.js.map +1 -1
- package/dist/index5.js +2 -2
- package/dist/index50.js +23 -254
- package/dist/index50.js.map +1 -1
- package/dist/index51.js +129 -25
- package/dist/index51.js.map +1 -1
- package/dist/index52.js +24 -129
- package/dist/index52.js.map +1 -1
- package/dist/index53.js +19 -22
- package/dist/index53.js.map +1 -1
- package/dist/index54.js +134 -19
- package/dist/index54.js.map +1 -1
- package/dist/index55.js +30 -133
- package/dist/index55.js.map +1 -1
- package/dist/index56.js +24 -30
- package/dist/index56.js.map +1 -1
- package/dist/index57.js +38 -26
- package/dist/index57.js.map +1 -1
- package/dist/index58.js +19 -39
- package/dist/index58.js.map +1 -1
- package/dist/index59.js +133 -18
- package/dist/index59.js.map +1 -1
- package/dist/index6.js +4 -4
- package/dist/index60.js +49 -134
- package/dist/index60.js.map +1 -1
- package/dist/index61.js +25 -48
- package/dist/index61.js.map +1 -1
- package/dist/index62.js +57 -28
- package/dist/index62.js.map +1 -1
- package/dist/index63.js +56 -57
- package/dist/index63.js.map +1 -1
- package/dist/index64.js +5 -5
- package/dist/index64.js.map +1 -1
- package/dist/index66.js +23 -11
- package/dist/index66.js.map +1 -1
- package/dist/index67.js +232 -17
- package/dist/index67.js.map +1 -1
- package/dist/index68.js +5 -5
- package/dist/index68.js.map +1 -1
- package/dist/index7.js +11 -11
- package/dist/index70.js +11 -23
- package/dist/index70.js.map +1 -1
- package/dist/index71.js +17 -232
- package/dist/index71.js.map +1 -1
- package/dist/index72.js +6 -2
- package/dist/index72.js.map +1 -1
- package/dist/index73.js +8 -2
- package/dist/index73.js.map +1 -1
- package/dist/index74.js +6 -2
- package/dist/index74.js.map +1 -1
- package/dist/index75.js +2 -2
- package/dist/index76.js +2 -6
- package/dist/index76.js.map +1 -1
- package/dist/index77.js +2 -8
- package/dist/index77.js.map +1 -1
- package/dist/index78.js +2 -6
- package/dist/index78.js.map +1 -1
- package/dist/index8.js +2 -2
- package/dist/index9.js +1 -1
- package/package.json +1 -1
package/dist/index46.js
CHANGED
|
@@ -1,94 +1,130 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
for (let i = 0; i < r; i += 1)
|
|
11
|
-
c(t[i] ?? "") && (n += 1);
|
|
12
|
-
return n;
|
|
13
|
-
}
|
|
14
|
-
function a(t, e) {
|
|
15
|
-
if (e <= 0)
|
|
16
|
-
return t.startsWith("+") ? Math.min(1, t.length) : 0;
|
|
17
|
-
let n = 0;
|
|
18
|
-
for (let r = 0; r < t.length; r += 1)
|
|
19
|
-
if (c(t[r] ?? "") && (n += 1, n === e))
|
|
20
|
-
return r + 1;
|
|
21
|
-
return t.length;
|
|
22
|
-
}
|
|
23
|
-
function g(t) {
|
|
24
|
-
return !t || c(t) ? !1 : t !== "+";
|
|
25
|
-
}
|
|
26
|
-
function h(t, e) {
|
|
27
|
-
let n = e;
|
|
28
|
-
for (; n > 0; ) {
|
|
29
|
-
const r = t[n - 1] ?? "";
|
|
30
|
-
if (!g(r))
|
|
31
|
-
break;
|
|
32
|
-
n -= 1;
|
|
1
|
+
import { j as l } from "./index28.js";
|
|
2
|
+
import { c as M } from "./index29.js";
|
|
3
|
+
import * as v from "react";
|
|
4
|
+
import { cn as L } from "./index2.js";
|
|
5
|
+
const P = v.createContext(null);
|
|
6
|
+
function T(t, e) {
|
|
7
|
+
if (typeof t == "function") {
|
|
8
|
+
t(e);
|
|
9
|
+
return;
|
|
33
10
|
}
|
|
34
|
-
|
|
11
|
+
t && typeof t == "object" && Reflect.set(t, "current", e);
|
|
35
12
|
}
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
13
|
+
const V = (t) => {
|
|
14
|
+
const e = M.c(30), n = v.useContext(P), o = n?.highlightedValue === t.data.value;
|
|
15
|
+
let i, r, s;
|
|
16
|
+
e[0] !== t.innerProps ? ({
|
|
17
|
+
onMouseMove: i,
|
|
18
|
+
className: r,
|
|
19
|
+
...s
|
|
20
|
+
} = t.innerProps, e[0] = t.innerProps, e[1] = i, e[2] = r, e[3] = s) : (i = e[1], r = e[2], s = e[3]);
|
|
21
|
+
let f;
|
|
22
|
+
e[4] !== n?.renderOptionLabel ? (f = n?.renderOptionLabel ?? z, e[4] = n?.renderOptionLabel, e[5] = f) : f = e[5];
|
|
23
|
+
const b = f, w = v.useRef(null), {
|
|
24
|
+
innerRef: S
|
|
25
|
+
} = t;
|
|
26
|
+
let m;
|
|
27
|
+
e[6] !== S ? (m = (c) => {
|
|
28
|
+
w.current = c, T(S, c);
|
|
29
|
+
}, e[6] = S, e[7] = m) : m = e[7];
|
|
30
|
+
const j = m;
|
|
31
|
+
let g;
|
|
32
|
+
e[8] !== n?.consumeScrollBehavior || e[9] !== o ? (g = () => {
|
|
33
|
+
if (!o)
|
|
34
|
+
return;
|
|
35
|
+
const c = n?.consumeScrollBehavior, H = c ? c() : "smooth", d = w.current;
|
|
36
|
+
if (!d)
|
|
37
|
+
return;
|
|
38
|
+
const C = d.parentElement;
|
|
39
|
+
if (!C)
|
|
40
|
+
return;
|
|
41
|
+
const N = d.offsetTop, B = N + d.offsetHeight, O = C.scrollTop, E = O + C.clientHeight;
|
|
42
|
+
N >= O && B <= E || d.scrollIntoView({
|
|
43
|
+
block: "nearest",
|
|
44
|
+
behavior: H
|
|
45
|
+
});
|
|
46
|
+
}, e[8] = n?.consumeScrollBehavior, e[9] = o, e[10] = g) : g = e[10];
|
|
47
|
+
let h;
|
|
48
|
+
e[11] !== n || e[12] !== o ? (h = [n, o], e[11] = n, e[12] = o, e[13] = h) : h = e[13], v.useEffect(g, h);
|
|
49
|
+
let p;
|
|
50
|
+
e[14] !== n || e[15] !== i || e[16] !== t.data ? (p = (c) => {
|
|
51
|
+
i?.(c), n?.setHighlightedOption(t.data);
|
|
52
|
+
}, e[14] = n, e[15] = i, e[16] = t.data, e[17] = p) : p = e[17];
|
|
53
|
+
const R = p, y = o ? "bg-muted text-foreground" : "text-foreground hover:bg-muted";
|
|
54
|
+
let a;
|
|
55
|
+
e[18] !== r || e[19] !== y ? (a = L("flex cursor-pointer items-center justify-between gap-3 px-3 py-2 text-sm", r, y), e[18] = r, e[19] = y, e[20] = a) : a = e[20];
|
|
56
|
+
let u;
|
|
57
|
+
e[21] !== t.data || e[22] !== b ? (u = b(t.data), e[21] = t.data, e[22] = b, e[23] = u) : u = e[23];
|
|
58
|
+
let x;
|
|
59
|
+
return e[24] !== j || e[25] !== R || e[26] !== s || e[27] !== a || e[28] !== u ? (x = /* @__PURE__ */ l.jsx("div", { ref: j, ...s, onMouseMove: R, className: a, children: u }), e[24] = j, e[25] = R, e[26] = s, e[27] = a, e[28] = u, e[29] = x) : x = e[29], x;
|
|
60
|
+
}, $ = {
|
|
61
|
+
control: () => ({
|
|
62
|
+
display: "none"
|
|
63
|
+
}),
|
|
64
|
+
menu: (t) => ({
|
|
65
|
+
...t,
|
|
66
|
+
marginTop: 4,
|
|
67
|
+
borderRadius: "var(--radius)",
|
|
68
|
+
boxShadow: "0 18px 36px rgba(15, 23, 42, 0.18)",
|
|
69
|
+
backgroundColor: "hsl(var(--popover))",
|
|
70
|
+
overflow: "hidden",
|
|
71
|
+
zIndex: 20
|
|
72
|
+
}),
|
|
73
|
+
menuList: (t) => ({
|
|
74
|
+
...t,
|
|
75
|
+
maxHeight: 240,
|
|
76
|
+
padding: 0
|
|
77
|
+
}),
|
|
78
|
+
option: (t, e) => ({
|
|
79
|
+
...t,
|
|
80
|
+
fontSize: "0.875rem",
|
|
81
|
+
backgroundColor: e.isFocused ? "hsl(var(--muted))" : e.isSelected ? "hsl(var(--accent))" : "transparent",
|
|
82
|
+
color: e.isSelected ? "hsl(var(--accent-foreground))" : "hsl(var(--foreground))",
|
|
83
|
+
cursor: "pointer"
|
|
84
|
+
}),
|
|
85
|
+
noOptionsMessage: (t) => ({
|
|
86
|
+
...t,
|
|
87
|
+
fontSize: "0.875rem",
|
|
88
|
+
color: "hsl(var(--muted-foreground))"
|
|
89
|
+
})
|
|
90
|
+
}, A = (t) => {
|
|
91
|
+
const e = M.c(5), {
|
|
92
|
+
children: n,
|
|
93
|
+
innerProps: o,
|
|
94
|
+
innerRef: i
|
|
95
|
+
} = t;
|
|
96
|
+
let r;
|
|
97
|
+
e[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (r = {
|
|
98
|
+
height: 0,
|
|
99
|
+
minHeight: 0,
|
|
100
|
+
opacity: 0,
|
|
101
|
+
overflow: "hidden",
|
|
102
|
+
pointerEvents: "none"
|
|
103
|
+
}, e[0] = r) : r = e[0];
|
|
104
|
+
let s;
|
|
105
|
+
return e[1] !== n || e[2] !== o || e[3] !== i ? (s = /* @__PURE__ */ l.jsx("div", { ...o, ref: i, style: r, children: n }), e[1] = n, e[2] = o, e[3] = i, e[4] = s) : s = e[4], s;
|
|
106
|
+
}, q = () => null;
|
|
107
|
+
function k(t) {
|
|
108
|
+
return /* @__PURE__ */ l.jsxs(l.Fragment, { children: [
|
|
109
|
+
/* @__PURE__ */ l.jsxs("span", { className: "flex min-w-0 items-center gap-2", children: [
|
|
110
|
+
t.flag ? /* @__PURE__ */ l.jsx("span", { "aria-hidden": "true", className: "text-lg leading-none", children: t.flag }) : null,
|
|
111
|
+
/* @__PURE__ */ l.jsx("span", { className: "truncate", children: t.name })
|
|
112
|
+
] }),
|
|
113
|
+
/* @__PURE__ */ l.jsxs("span", { className: "text-xs text-muted-foreground", children: [
|
|
114
|
+
"+",
|
|
115
|
+
t.dialCode
|
|
116
|
+
] })
|
|
117
|
+
] });
|
|
60
118
|
}
|
|
61
|
-
function
|
|
62
|
-
|
|
63
|
-
if (t.wasAtEnd) {
|
|
64
|
-
const f = e.length;
|
|
65
|
-
return {
|
|
66
|
-
start: f,
|
|
67
|
-
end: f
|
|
68
|
-
};
|
|
69
|
-
}
|
|
70
|
-
if (t.wasAtStart)
|
|
71
|
-
return {
|
|
72
|
-
start: 0,
|
|
73
|
-
end: 0
|
|
74
|
-
};
|
|
75
|
-
}
|
|
76
|
-
const n = t.preserveStartIndex ? Math.min(t.selectionStart, e.length) : a(e, t.startDigits), r = t.preserveEndIndex ? Math.min(t.selectionEnd, e.length) : a(e, t.endDigits);
|
|
77
|
-
let i = n, o = r;
|
|
78
|
-
t.wasAtStart && (i = 0), t.wasAtEnd && (o = e.length), t.selectionStart === t.selectionEnd && (i = o);
|
|
79
|
-
const d = Math.min(Math.max(i, 0), e.length), s = Math.min(Math.max(o, 0), e.length);
|
|
80
|
-
return d > s ? {
|
|
81
|
-
start: s,
|
|
82
|
-
end: s
|
|
83
|
-
} : {
|
|
84
|
-
start: d,
|
|
85
|
-
end: s
|
|
86
|
-
};
|
|
119
|
+
function z(t) {
|
|
120
|
+
return k(t);
|
|
87
121
|
}
|
|
88
122
|
export {
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
123
|
+
A as HiddenControl,
|
|
124
|
+
q as NullComponent,
|
|
125
|
+
P as SuggestionContext,
|
|
126
|
+
V as SuggestionOption,
|
|
127
|
+
k as formatCountryOption,
|
|
128
|
+
$ as suggestionSelectStyles
|
|
93
129
|
};
|
|
94
130
|
//# sourceMappingURL=index46.js.map
|
package/dist/index46.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index46.js","sources":["../src/components/PhoneNumberInput/selection.ts"],"sourcesContent":["function isDigitCharacter(char: string) {\n if (!char) {\n return false\n }\n const code = char.charCodeAt(0)\n return code >= 48 && code <= 57\n}\n\nfunction countDigitsBefore(value: string, index: number) {\n let count = 0\n const limit = Math.min(index, value.length)\n for (let position = 0; position < limit; position += 1) {\n if (isDigitCharacter(value[position] ?? \"\")) {\n count += 1\n }\n }\n return count\n}\n\nfunction findIndexForDigitCount(value: string, digitCount: number) {\n if (digitCount <= 0) {\n return value.startsWith(\"+\") ? Math.min(1, value.length) : 0\n }\n\n let seen = 0\n for (let index = 0; index < value.length; index += 1) {\n if (isDigitCharacter(value[index] ?? \"\")) {\n seen += 1\n if (seen === digitCount) {\n return index + 1\n }\n }\n }\n\n return value.length\n}\n\nfunction isFormattingCharacter(char: string) {\n if (!char) {\n return false\n }\n if (isDigitCharacter(char)) {\n return false\n }\n return char !== \"+\"\n}\n\nexport function skipFormattingCharactersLeft(value: string, index: number) {\n let position = index\n while (position > 0) {\n const next = value[position - 1] ?? \"\"\n if (!isFormattingCharacter(next)) {\n break\n }\n position -= 1\n }\n return position\n}\n\nexport function skipFormattingCharactersRight(value: string, index: number) {\n let position = index\n while (position < value.length) {\n const next = value[position] ?? \"\"\n if (!isFormattingCharacter(next)) {\n break\n }\n position += 1\n }\n return position\n}\n\ntype SelectionSnapshot = {\n selectionStart: number\n selectionEnd: number\n startDigits: number\n endDigits: number\n preserveStartIndex: boolean\n preserveEndIndex: boolean\n wasAtStart: boolean\n wasAtEnd: boolean\n}\n\nexport function captureSelectionSnapshot(input: HTMLInputElement): SelectionSnapshot {\n const { value } = input\n const selectionStart = input.selectionStart ?? value.length\n const selectionEnd = input.selectionEnd ?? selectionStart\n const preserveStartIndex = selectionStart <= 1 && value.startsWith(\"+\")\n const preserveEndIndex = selectionEnd <= 1 && value.startsWith(\"+\")\n\n return {\n selectionStart,\n selectionEnd,\n startDigits: countDigitsBefore(value, selectionStart),\n endDigits: countDigitsBefore(value, selectionEnd),\n preserveStartIndex,\n preserveEndIndex,\n wasAtStart: selectionStart === 0,\n wasAtEnd: selectionEnd === value.length,\n }\n}\n\nexport function resolveSelection(snapshot: SelectionSnapshot, value: string) {\n if (snapshot.selectionStart === snapshot.selectionEnd) {\n if (snapshot.wasAtEnd) {\n const end = value.length\n return { start: end, end }\n }\n if (snapshot.wasAtStart) {\n return { start: 0, end: 0 }\n }\n }\n\n const start = snapshot.preserveStartIndex\n ? Math.min(snapshot.selectionStart, value.length)\n : findIndexForDigitCount(value, snapshot.startDigits)\n const end = snapshot.preserveEndIndex\n ? Math.min(snapshot.selectionEnd, value.length)\n : findIndexForDigitCount(value, snapshot.endDigits)\n\n let resolvedStart = start\n let resolvedEnd = end\n\n if (snapshot.wasAtStart) {\n resolvedStart = 0\n }\n\n if (snapshot.wasAtEnd) {\n resolvedEnd = value.length\n }\n\n if (snapshot.selectionStart === snapshot.selectionEnd) {\n resolvedStart = resolvedEnd\n }\n\n const clampedStart = Math.min(Math.max(resolvedStart, 0), value.length)\n const clampedEnd = Math.min(Math.max(resolvedEnd, 0), value.length)\n\n if (clampedStart > clampedEnd) {\n return { start: clampedEnd, end: clampedEnd }\n }\n\n return { start: clampedStart, end: clampedEnd }\n}\n\n"],"names":["isDigitCharacter","char","code","charCodeAt","countDigitsBefore","value","index","count","limit","Math","min","length","position","findIndexForDigitCount","digitCount","startsWith","seen","isFormattingCharacter","skipFormattingCharactersLeft","next","skipFormattingCharactersRight","captureSelectionSnapshot","input","selectionStart","selectionEnd","preserveStartIndex","preserveEndIndex","startDigits","endDigits","wasAtStart","wasAtEnd","resolveSelection","snapshot","end","start","resolvedStart","resolvedEnd","clampedStart","max","clampedEnd"],"mappings":"AAAA,SAASA,EAAiBC,GAAc;AACtC,MAAI,CAACA;AACH,WAAO;AAET,QAAMC,IAAOD,EAAKE,WAAW,CAAC;AAC9B,SAAOD,KAAQ,MAAMA,KAAQ;AAC/B;AAEA,SAASE,EAAkBC,GAAeC,GAAe;AACvD,MAAIC,IAAQ;AACZ,QAAMC,IAAQC,KAAKC,IAAIJ,GAAOD,EAAMM,MAAM;AAC1C,WAASC,IAAW,GAAGA,IAAWJ,GAAOI,KAAY;AACnD,IAAIZ,EAAiBK,EAAMO,CAAQ,KAAK,EAAE,MACxCL,KAAS;AAGb,SAAOA;AACT;AAEA,SAASM,EAAuBR,GAAeS,GAAoB;AACjE,MAAIA,KAAc;AAChB,WAAOT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;AAAAA,IACAG,YAAYN,MAAmB;AAAA,IAC/BO,UAAUN,MAAiBnB,EAAMM;AAAAA,EAAAA;AAErC;AAEO,SAASoB,EAAiBC,GAA6B3B,GAAe;AAC3E,MAAI2B,EAAST,mBAAmBS,EAASR,cAAc;AACrD,QAAIQ,EAASF,UAAU;AACrB,YAAMG,IAAM5B,EAAMM;AAClB,aAAO;AAAA,QAAEuB,OAAOD;AAAAA,QAAKA,KAAAA;AAAAA,MAAAA;AAAAA,IACvB;AACA,QAAID,EAASH;AACX,aAAO;AAAA,QAAEK,OAAO;AAAA,QAAGD,KAAK;AAAA,MAAA;AAAA,EAE5B;AAEA,QAAMC,IAAQF,EAASP,qBACnBhB,KAAKC,IAAIsB,EAAST,gBAAgBlB,EAAMM,MAAM,IAC9CE,EAAuBR,GAAO2B,EAASL,WAAW,GAChDM,IAAMD,EAASN,mBACjBjB,KAAKC,IAAIsB,EAASR,cAAcnB,EAAMM,MAAM,IAC5CE,EAAuBR,GAAO2B,EAASJ,SAAS;AAEpD,MAAIO,IAAgBD,GAChBE,IAAcH;AAElB,EAAID,EAASH,eACXM,IAAgB,IAGdH,EAASF,aACXM,IAAc/B,EAAMM,SAGlBqB,EAAST,mBAAmBS,EAASR,iBACvCW,IAAgBC;AAGlB,QAAMC,IAAe5B,KAAKC,IAAID,KAAK6B,IAAIH,GAAe,CAAC,GAAG9B,EAAMM,MAAM,GAChE4B,IAAa9B,KAAKC,IAAID,KAAK6B,IAAIF,GAAa,CAAC,GAAG/B,EAAMM,MAAM;AAElE,SAAI0B,IAAeE,IACV;AAAA,IAAEL,OAAOK;AAAAA,IAAYN,KAAKM;AAAAA,EAAAA,IAG5B;AAAA,IAAEL,OAAOG;AAAAA,IAAcJ,KAAKM;AAAAA,EAAAA;AACrC;"}
|
|
1
|
+
{"version":3,"file":"index46.js","sources":["../src/components/PhoneNumberInput/suggestions.tsx"],"sourcesContent":["import * as React from \"react\"\nimport type { CountryCode } from \"libphonenumber-js\"\nimport type { ControlProps, OptionProps, StylesConfig } from \"react-select\"\n\nimport { cn } from \"@/lib/utils\"\n\nimport type { CountryOption } from \"./types\"\n\n\nexport type SuggestionContextValue = {\n highlightedValue: CountryCode | null\n setHighlightedOption: (option: CountryOption) => void\n renderOptionLabel: (option: CountryOption) => React.ReactNode\n consumeScrollBehavior: () => ScrollBehavior\n}\n\nexport const SuggestionContext = React.createContext<SuggestionContextValue | null>(null)\n\nfunction assignOptionRef(ref: React.Ref<HTMLDivElement> | undefined, node: HTMLDivElement | null) {\n if (typeof ref === \"function\") {\n ref(node)\n return\n }\n if (ref && typeof ref === \"object\") {\n Reflect.set(ref, \"current\", node)\n }\n}\n\nexport const SuggestionOption = (props: OptionProps<CountryOption, false>) => {\n const context = React.useContext(SuggestionContext)\n const isActive = context?.highlightedValue === props.data.value\n const { onMouseMove, className: receivedClassName, ...restInnerProps } = props.innerProps\n const renderLabel =\n context?.renderOptionLabel ?? ((option: CountryOption) => formatCountryOption(option))\n const optionRef = React.useRef<HTMLDivElement | null>(null)\n const { innerRef } = props\n\n const assignRef = React.useCallback(\n (node: HTMLDivElement | null) => {\n optionRef.current = node\n assignOptionRef(innerRef, node)\n },\n [innerRef]\n )\n\n React.useEffect(() => {\n if (!isActive) {\n return\n }\n\n const consumeScrollBehavior = context?.consumeScrollBehavior\n const behavior = consumeScrollBehavior ? consumeScrollBehavior() : \"smooth\"\n\n const target = optionRef.current\n if (!target) {\n return\n }\n\n const parent = target.parentElement\n if (!parent) {\n return\n }\n\n const top = target.offsetTop\n const bottom = top + target.offsetHeight\n const viewTop = parent.scrollTop\n const viewBottom = viewTop + parent.clientHeight\n\n if (top >= viewTop && bottom <= viewBottom) {\n return\n }\n\n target.scrollIntoView({\n block: \"nearest\",\n behavior,\n })\n }, [context, isActive])\n\n const handleMouseMove = (event: React.MouseEvent<HTMLDivElement>) => {\n onMouseMove?.(event)\n context?.setHighlightedOption(props.data)\n }\n\n return (\n <div\n ref={assignRef}\n {...restInnerProps}\n onMouseMove={handleMouseMove}\n className={cn(\n \"flex cursor-pointer items-center justify-between gap-3 px-3 py-2 text-sm\",\n receivedClassName,\n isActive ? \"bg-muted text-foreground\" : \"text-foreground hover:bg-muted\"\n )}\n >\n {renderLabel(props.data)}\n </div>\n )\n}\n\nexport const suggestionSelectStyles: StylesConfig<CountryOption, false> = {\n control: () => ({\n display: \"none\",\n }),\n menu: (provided) => ({\n ...provided,\n marginTop: 4,\n borderRadius: \"var(--radius)\",\n boxShadow: \"0 18px 36px rgba(15, 23, 42, 0.18)\",\n backgroundColor: \"hsl(var(--popover))\",\n overflow: \"hidden\",\n zIndex: 20,\n }),\n menuList: (provided) => ({\n ...provided,\n maxHeight: 240,\n padding: 0,\n }),\n option: (provided, state) => ({\n ...provided,\n fontSize: \"0.875rem\",\n backgroundColor: state.isFocused\n ? \"hsl(var(--muted))\"\n : state.isSelected\n ? \"hsl(var(--accent))\"\n : \"transparent\",\n color: state.isSelected\n ? \"hsl(var(--accent-foreground))\"\n : \"hsl(var(--foreground))\",\n cursor: \"pointer\",\n }),\n noOptionsMessage: (provided) => ({\n ...provided,\n fontSize: \"0.875rem\",\n color: \"hsl(var(--muted-foreground))\",\n }),\n}\n\nexport const HiddenControl = (props: ControlProps<CountryOption, false>) => {\n const { children, innerProps, innerRef } = props\n\n return (\n <div\n {...innerProps}\n ref={innerRef}\n style={{\n height: 0,\n minHeight: 0,\n opacity: 0,\n overflow: \"hidden\",\n pointerEvents: \"none\",\n }}\n >\n {children}\n </div>\n )\n}\n\nexport const NullComponent = () => null\n\nexport function formatCountryOption(option: CountryOption) {\n return (\n <>\n <span className=\"flex min-w-0 items-center gap-2\">\n {option.flag ? (\n <span aria-hidden=\"true\" className=\"text-lg leading-none\">\n {option.flag}\n </span>\n ) : null}\n <span className=\"truncate\">{option.name}</span>\n </span>\n <span className=\"text-xs text-muted-foreground\">+{option.dialCode}</span>\n </>\n )\n}\n"],"names":["SuggestionContext","React","createContext","assignOptionRef","ref","node","Reflect","set","SuggestionOption","props","$","_c","context","useContext","isActive","highlightedValue","data","value","onMouseMove","receivedClassName","restInnerProps","innerProps","className","t0","renderOptionLabel","_temp","renderLabel","optionRef","useRef","innerRef","t1","current","assignRef","t2","consumeScrollBehavior","behavior","target","parent","parentElement","top","offsetTop","bottom","offsetHeight","viewTop","scrollTop","viewBottom","clientHeight","scrollIntoView","block","t3","useEffect","t4","event","setHighlightedOption","handleMouseMove","t5","t6","cn","t7","t8","jsx","suggestionSelectStyles","control","display","menu","provided","marginTop","borderRadius","boxShadow","backgroundColor","overflow","zIndex","menuList","maxHeight","padding","option","state","fontSize","isFocused","isSelected","color","cursor","noOptionsMessage","HiddenControl","children","Symbol","for","height","minHeight","opacity","pointerEvents","NullComponent","formatCountryOption","jsxs","Fragment","flag","name","dialCode"],"mappings":";;;;AAgBO,MAAMA,IAAoBC,EAAMC,cAA6C,IAAI;AAExF,SAASC,EAAgBC,GAA4CC,GAA6B;AAChG,MAAI,OAAOD,KAAQ,YAAY;AAC7BA,IAAAA,EAAIC,CAAI;AACR;AAAA,EACF;AACA,EAAID,KAAO,OAAOA,KAAQ,YACxBE,QAAQC,IAAIH,GAAK,WAAWC,CAAI;AAEpC;AAEO,MAAMG,IAAmBC,CAAAA,MAAA;AAAA,QAAAC,IAAAC,EAAAA,EAAA,EAAA,GAC9BC,IAAgBX,EAAKY,WAAYb,CAAiB,GAClDc,IAAiBF,GAAOG,qBAAuBN,EAAKO,KAAKC;AAAM,MAAAC,GAAAC,GAAAC;AAAA,EAAAV,EAAA,CAAA,MAAAD,EAAAY,cAC/D;AAAA,IAAAH,aAAAA;AAAAA,IAAAI,WAAAH;AAAAA,IAAA,GAAAC;AAAAA,EAAAA,IAAyEX,EAAKY,YAAWX,EAAA,CAAA,IAAAD,EAAAY,YAAAX,OAAAQ,GAAAR,OAAAS,GAAAT,OAAAU,MAAAF,IAAAR,EAAA,CAAA,GAAAS,IAAAT,EAAA,CAAA,GAAAU,IAAAV,EAAA,CAAA;AAAA,MAAAa;AAAA,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OAAA0E,GAAA1E,OAAAW,GAAAX,OAAAmB,GAAAnB,OAAAoB,KAAAA,IAAApB,EAAA,CAAA,GAZNoB;AAYM,GAIG6D,IAAgBA,MAAM;AAE5B,SAASC,EAAoBjB,GAAuB;AACzD,SACEkB,gBAAAA,EAAAA,KAAAC,YAAA,EACE,UAAA;AAAA,IAAAD,gBAAAA,EAAAA,KAAC,QAAA,EAAK,WAAU,mCACblB,UAAAA;AAAAA,MAAAA,EAAOoB,6BACL,QAAA,EAAK,eAAY,QAAO,WAAU,wBAChCpB,UAAAA,EAAOoB,KAAAA,CACV,IACE;AAAA,MACJnC,gBAAAA,EAAAA,IAAC,QAAA,EAAK,WAAU,YAAYe,YAAOqB,KAAAA,CAAK;AAAA,IAAA,GAC1C;AAAA,IACAH,gBAAAA,EAAAA,KAAC,QAAA,EAAK,WAAU,iCAAgC,UAAA;AAAA,MAAA;AAAA,MAAElB,EAAOsB;AAAAA,IAAAA,EAAAA,CAAS;AAAA,EAAA,GACpE;AAEJ;AAjJgC,SAAAxE,EAAAkD,GAAA;AAAA,SAK8BiB,EAAoBjB,CAAM;AAAC;"}
|
package/dist/index47.js
CHANGED
|
@@ -1,130 +1,9 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
const P = v.createContext(null);
|
|
6
|
-
function T(t, e) {
|
|
7
|
-
if (typeof t == "function") {
|
|
8
|
-
t(e);
|
|
9
|
-
return;
|
|
10
|
-
}
|
|
11
|
-
t && typeof t == "object" && Reflect.set(t, "current", e);
|
|
12
|
-
}
|
|
13
|
-
const V = (t) => {
|
|
14
|
-
const e = M.c(30), n = v.useContext(P), o = n?.highlightedValue === t.data.value;
|
|
15
|
-
let i, r, s;
|
|
16
|
-
e[0] !== t.innerProps ? ({
|
|
17
|
-
onMouseMove: i,
|
|
18
|
-
className: r,
|
|
19
|
-
...s
|
|
20
|
-
} = t.innerProps, e[0] = t.innerProps, e[1] = i, e[2] = r, e[3] = s) : (i = e[1], r = e[2], s = e[3]);
|
|
21
|
-
let f;
|
|
22
|
-
e[4] !== n?.renderOptionLabel ? (f = n?.renderOptionLabel ?? z, e[4] = n?.renderOptionLabel, e[5] = f) : f = e[5];
|
|
23
|
-
const b = f, w = v.useRef(null), {
|
|
24
|
-
innerRef: S
|
|
25
|
-
} = t;
|
|
26
|
-
let m;
|
|
27
|
-
e[6] !== S ? (m = (c) => {
|
|
28
|
-
w.current = c, T(S, c);
|
|
29
|
-
}, e[6] = S, e[7] = m) : m = e[7];
|
|
30
|
-
const j = m;
|
|
31
|
-
let g;
|
|
32
|
-
e[8] !== n?.consumeScrollBehavior || e[9] !== o ? (g = () => {
|
|
33
|
-
if (!o)
|
|
34
|
-
return;
|
|
35
|
-
const c = n?.consumeScrollBehavior, H = c ? c() : "smooth", d = w.current;
|
|
36
|
-
if (!d)
|
|
37
|
-
return;
|
|
38
|
-
const C = d.parentElement;
|
|
39
|
-
if (!C)
|
|
40
|
-
return;
|
|
41
|
-
const N = d.offsetTop, B = N + d.offsetHeight, O = C.scrollTop, E = O + C.clientHeight;
|
|
42
|
-
N >= O && B <= E || d.scrollIntoView({
|
|
43
|
-
block: "nearest",
|
|
44
|
-
behavior: H
|
|
45
|
-
});
|
|
46
|
-
}, e[8] = n?.consumeScrollBehavior, e[9] = o, e[10] = g) : g = e[10];
|
|
47
|
-
let h;
|
|
48
|
-
e[11] !== n || e[12] !== o ? (h = [n, o], e[11] = n, e[12] = o, e[13] = h) : h = e[13], v.useEffect(g, h);
|
|
49
|
-
let p;
|
|
50
|
-
e[14] !== n || e[15] !== i || e[16] !== t.data ? (p = (c) => {
|
|
51
|
-
i?.(c), n?.setHighlightedOption(t.data);
|
|
52
|
-
}, e[14] = n, e[15] = i, e[16] = t.data, e[17] = p) : p = e[17];
|
|
53
|
-
const R = p, y = o ? "bg-muted text-foreground" : "text-foreground hover:bg-muted";
|
|
54
|
-
let a;
|
|
55
|
-
e[18] !== r || e[19] !== y ? (a = L("flex cursor-pointer items-center justify-between gap-3 px-3 py-2 text-sm", r, y), e[18] = r, e[19] = y, e[20] = a) : a = e[20];
|
|
56
|
-
let u;
|
|
57
|
-
e[21] !== t.data || e[22] !== b ? (u = b(t.data), e[21] = t.data, e[22] = b, e[23] = u) : u = e[23];
|
|
58
|
-
let x;
|
|
59
|
-
return e[24] !== j || e[25] !== R || e[26] !== s || e[27] !== a || e[28] !== u ? (x = /* @__PURE__ */ l.jsx("div", { ref: j, ...s, onMouseMove: R, className: a, children: u }), e[24] = j, e[25] = R, e[26] = s, e[27] = a, e[28] = u, e[29] = x) : x = e[29], x;
|
|
60
|
-
}, $ = {
|
|
61
|
-
control: () => ({
|
|
62
|
-
display: "none"
|
|
63
|
-
}),
|
|
64
|
-
menu: (t) => ({
|
|
65
|
-
...t,
|
|
66
|
-
marginTop: 4,
|
|
67
|
-
borderRadius: "var(--radius)",
|
|
68
|
-
boxShadow: "0 18px 36px rgba(15, 23, 42, 0.18)",
|
|
69
|
-
backgroundColor: "hsl(var(--popover))",
|
|
70
|
-
overflow: "hidden",
|
|
71
|
-
zIndex: 20
|
|
72
|
-
}),
|
|
73
|
-
menuList: (t) => ({
|
|
74
|
-
...t,
|
|
75
|
-
maxHeight: 240,
|
|
76
|
-
padding: 0
|
|
77
|
-
}),
|
|
78
|
-
option: (t, e) => ({
|
|
79
|
-
...t,
|
|
80
|
-
fontSize: "0.875rem",
|
|
81
|
-
backgroundColor: e.isFocused ? "hsl(var(--muted))" : e.isSelected ? "hsl(var(--accent))" : "transparent",
|
|
82
|
-
color: e.isSelected ? "hsl(var(--accent-foreground))" : "hsl(var(--foreground))",
|
|
83
|
-
cursor: "pointer"
|
|
84
|
-
}),
|
|
85
|
-
noOptionsMessage: (t) => ({
|
|
86
|
-
...t,
|
|
87
|
-
fontSize: "0.875rem",
|
|
88
|
-
color: "hsl(var(--muted-foreground))"
|
|
89
|
-
})
|
|
90
|
-
}, A = (t) => {
|
|
91
|
-
const e = M.c(5), {
|
|
92
|
-
children: n,
|
|
93
|
-
innerProps: o,
|
|
94
|
-
innerRef: i
|
|
95
|
-
} = t;
|
|
96
|
-
let r;
|
|
97
|
-
e[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (r = {
|
|
98
|
-
height: 0,
|
|
99
|
-
minHeight: 0,
|
|
100
|
-
opacity: 0,
|
|
101
|
-
overflow: "hidden",
|
|
102
|
-
pointerEvents: "none"
|
|
103
|
-
}, e[0] = r) : r = e[0];
|
|
104
|
-
let s;
|
|
105
|
-
return e[1] !== n || e[2] !== o || e[3] !== i ? (s = /* @__PURE__ */ l.jsx("div", { ...o, ref: i, style: r, children: n }), e[1] = n, e[2] = o, e[3] = i, e[4] = s) : s = e[4], s;
|
|
106
|
-
}, q = () => null;
|
|
107
|
-
function k(t) {
|
|
108
|
-
return /* @__PURE__ */ l.jsxs(l.Fragment, { children: [
|
|
109
|
-
/* @__PURE__ */ l.jsxs("span", { className: "flex min-w-0 items-center gap-2", children: [
|
|
110
|
-
t.flag ? /* @__PURE__ */ l.jsx("span", { "aria-hidden": "true", className: "text-lg leading-none", children: t.flag }) : null,
|
|
111
|
-
/* @__PURE__ */ l.jsx("span", { className: "truncate", children: t.name })
|
|
112
|
-
] }),
|
|
113
|
-
/* @__PURE__ */ l.jsxs("span", { className: "text-xs text-muted-foreground", children: [
|
|
114
|
-
"+",
|
|
115
|
-
t.dialCode
|
|
116
|
-
] })
|
|
117
|
-
] });
|
|
118
|
-
}
|
|
119
|
-
function z(t) {
|
|
120
|
-
return k(t);
|
|
1
|
+
import t from "./index149.js";
|
|
2
|
+
import { getCountryCallingCode as o } from "./index163.js";
|
|
3
|
+
function n() {
|
|
4
|
+
return t(o, arguments);
|
|
121
5
|
}
|
|
122
6
|
export {
|
|
123
|
-
|
|
124
|
-
q as NullComponent,
|
|
125
|
-
P as SuggestionContext,
|
|
126
|
-
V as SuggestionOption,
|
|
127
|
-
k as formatCountryOption,
|
|
128
|
-
$ as suggestionSelectStyles
|
|
7
|
+
n as getCountryCallingCode
|
|
129
8
|
};
|
|
130
9
|
//# sourceMappingURL=index47.js.map
|
package/dist/index47.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index47.js","sources":["../src/components/PhoneNumberInput/suggestions.tsx"],"sourcesContent":["import * as React from \"react\"\nimport type { CountryCode } from \"libphonenumber-js\"\nimport type { ControlProps, OptionProps, StylesConfig } from \"react-select\"\n\nimport { cn } from \"@/lib/utils\"\n\nimport type { CountryOption } from \"./types\"\n\n\nexport type SuggestionContextValue = {\n highlightedValue: CountryCode | null\n setHighlightedOption: (option: CountryOption) => void\n renderOptionLabel: (option: CountryOption) => React.ReactNode\n consumeScrollBehavior: () => ScrollBehavior\n}\n\nexport const SuggestionContext = React.createContext<SuggestionContextValue | null>(null)\n\nfunction assignOptionRef(ref: React.Ref<HTMLDivElement> | undefined, node: HTMLDivElement | null) {\n if (typeof ref === \"function\") {\n ref(node)\n return\n }\n if (ref && typeof ref === \"object\") {\n Reflect.set(ref, \"current\", node)\n }\n}\n\nexport const SuggestionOption = (props: OptionProps<CountryOption, false>) => {\n const context = React.useContext(SuggestionContext)\n const isActive = context?.highlightedValue === props.data.value\n const { onMouseMove, className: receivedClassName, ...restInnerProps } = props.innerProps\n const renderLabel =\n context?.renderOptionLabel ?? ((option: CountryOption) => formatCountryOption(option))\n const optionRef = React.useRef<HTMLDivElement | null>(null)\n const { innerRef } = props\n\n const assignRef = React.useCallback(\n (node: HTMLDivElement | null) => {\n optionRef.current = node\n assignOptionRef(innerRef, node)\n },\n [innerRef]\n )\n\n React.useEffect(() => {\n if (!isActive) {\n return\n }\n\n const consumeScrollBehavior = context?.consumeScrollBehavior\n const behavior = consumeScrollBehavior ? consumeScrollBehavior() : \"smooth\"\n\n const target = optionRef.current\n if (!target) {\n return\n }\n\n const parent = target.parentElement\n if (!parent) {\n return\n }\n\n const top = target.offsetTop\n const bottom = top + target.offsetHeight\n const viewTop = parent.scrollTop\n const viewBottom = viewTop + parent.clientHeight\n\n if (top >= viewTop && bottom <= viewBottom) {\n return\n }\n\n target.scrollIntoView({\n block: \"nearest\",\n behavior,\n })\n }, [context, isActive])\n\n const handleMouseMove = (event: React.MouseEvent<HTMLDivElement>) => {\n onMouseMove?.(event)\n context?.setHighlightedOption(props.data)\n }\n\n return (\n <div\n ref={assignRef}\n {...restInnerProps}\n onMouseMove={handleMouseMove}\n className={cn(\n \"flex cursor-pointer items-center justify-between gap-3 px-3 py-2 text-sm\",\n receivedClassName,\n isActive ? \"bg-muted text-foreground\" : \"text-foreground hover:bg-muted\"\n )}\n >\n {renderLabel(props.data)}\n </div>\n )\n}\n\nexport const suggestionSelectStyles: StylesConfig<CountryOption, false> = {\n control: () => ({\n display: \"none\",\n }),\n menu: (provided) => ({\n ...provided,\n marginTop: 4,\n borderRadius: \"var(--radius)\",\n boxShadow: \"0 18px 36px rgba(15, 23, 42, 0.18)\",\n backgroundColor: \"hsl(var(--popover))\",\n overflow: \"hidden\",\n zIndex: 20,\n }),\n menuList: (provided) => ({\n ...provided,\n maxHeight: 240,\n padding: 0,\n }),\n option: (provided, state) => ({\n ...provided,\n fontSize: \"0.875rem\",\n backgroundColor: state.isFocused\n ? \"hsl(var(--muted))\"\n : state.isSelected\n ? \"hsl(var(--accent))\"\n : \"transparent\",\n color: state.isSelected\n ? \"hsl(var(--accent-foreground))\"\n : \"hsl(var(--foreground))\",\n cursor: \"pointer\",\n }),\n noOptionsMessage: (provided) => ({\n ...provided,\n fontSize: \"0.875rem\",\n color: \"hsl(var(--muted-foreground))\",\n }),\n}\n\nexport const HiddenControl = (props: ControlProps<CountryOption, false>) => {\n const { children, innerProps, innerRef } = props\n\n return (\n <div\n {...innerProps}\n ref={innerRef}\n style={{\n height: 0,\n minHeight: 0,\n opacity: 0,\n overflow: \"hidden\",\n pointerEvents: \"none\",\n }}\n >\n {children}\n </div>\n )\n}\n\nexport const NullComponent = () => null\n\nexport function formatCountryOption(option: CountryOption) {\n return (\n <>\n <span className=\"flex min-w-0 items-center gap-2\">\n {option.flag ? (\n <span aria-hidden=\"true\" className=\"text-lg leading-none\">\n {option.flag}\n </span>\n ) : null}\n <span className=\"truncate\">{option.name}</span>\n </span>\n <span className=\"text-xs text-muted-foreground\">+{option.dialCode}</span>\n </>\n )\n}\n"],"names":["SuggestionContext","React","createContext","assignOptionRef","ref","node","Reflect","set","SuggestionOption","props","$","_c","context","useContext","isActive","highlightedValue","data","value","onMouseMove","receivedClassName","restInnerProps","innerProps","className","t0","renderOptionLabel","_temp","renderLabel","optionRef","useRef","innerRef","t1","current","assignRef","t2","consumeScrollBehavior","behavior","target","parent","parentElement","top","offsetTop","bottom","offsetHeight","viewTop","scrollTop","viewBottom","clientHeight","scrollIntoView","block","t3","useEffect","t4","event","setHighlightedOption","handleMouseMove","t5","t6","cn","t7","t8","jsx","suggestionSelectStyles","control","display","menu","provided","marginTop","borderRadius","boxShadow","backgroundColor","overflow","zIndex","menuList","maxHeight","padding","option","state","fontSize","isFocused","isSelected","color","cursor","noOptionsMessage","HiddenControl","children","Symbol","for","height","minHeight","opacity","pointerEvents","NullComponent","formatCountryOption","jsxs","Fragment","flag","name","dialCode"],"mappings":";;;;AAgBO,MAAMA,IAAoBC,EAAMC,cAA6C,IAAI;AAExF,SAASC,EAAgBC,GAA4CC,GAA6B;AAChG,MAAI,OAAOD,KAAQ,YAAY;AAC7BA,IAAAA,EAAIC,CAAI;AACR;AAAA,EACF;AACA,EAAID,KAAO,OAAOA,KAAQ,YACxBE,QAAQC,IAAIH,GAAK,WAAWC,CAAI;AAEpC;AAEO,MAAMG,IAAmBC,CAAAA,MAAA;AAAA,QAAAC,IAAAC,EAAAA,EAAA,EAAA,GAC9BC,IAAgBX,EAAKY,WAAYb,CAAiB,GAClDc,IAAiBF,GAAOG,qBAAuBN,EAAKO,KAAKC;AAAM,MAAAC,GAAAC,GAAAC;AAAA,EAAAV,EAAA,CAAA,MAAAD,EAAAY,cAC/D;AAAA,IAAAH,aAAAA;AAAAA,IAA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UACA;AAAA,IAAQoB,eACH;AAAA,EAAA,GAChBhF,OAAAa,KAAAA,IAAAb,EAAA,CAAA;AAAA,MAAAoB;AAAA,SAAApB,EAAA,CAAA,MAAA0E,KAAA1E,SAAAW,KAAAX,EAAA,CAAA,MAAAmB,KATHC,mCAYM,GAXAT,GACCQ,QACE,OAAAN,GAQN6D,UAAAA,GACH,GAAM1E,OAAA0E,GAAA1E,OAAAW,GAAAX,OAAAmB,GAAAnB,OAAAoB,KAAAA,IAAApB,EAAA,CAAA,GAZNoB;AAYM,GAIG6D,IAAgBA,MAAM;AAE5B,SAASC,EAAoBjB,GAAuB;AACzD,SACEkB,gBAAAA,EAAAA,KAAAC,YAAA,EACE,UAAA;AAAA,IAAAD,gBAAAA,EAAAA,KAAC,QAAA,EAAK,WAAU,mCACblB,UAAAA;AAAAA,MAAAA,EAAOoB,6BACL,QAAA,EAAK,eAAY,QAAO,WAAU,wBAChCpB,UAAAA,EAAOoB,KAAAA,CACV,IACE;AAAA,MACJnC,gBAAAA,EAAAA,IAAC,QAAA,EAAK,WAAU,YAAYe,YAAOqB,KAAAA,CAAK;AAAA,IAAA,GAC1C;AAAA,IACAH,gBAAAA,EAAAA,KAAC,QAAA,EAAK,WAAU,iCAAgC,UAAA;AAAA,MAAA;AAAA,MAAElB,EAAOsB;AAAAA,IAAAA,EAAAA,CAAS;AAAA,EAAA,GACpE;AAEJ;AAjJgC,SAAAxE,EAAAkD,GAAA;AAAA,SAK8BiB,EAAoBjB,CAAM;AAAC;"}
|
|
1
|
+
{"version":3,"file":"index47.js","sources":["../../../node_modules/libphonenumber-js/min/exports/getCountryCallingCode.js"],"sourcesContent":["import withMetadataArgument from './withMetadataArgument.js'\r\nimport { getCountryCallingCode as _getCountryCallingCode } from '../../core/index.js'\r\n\r\nexport function getCountryCallingCode() {\r\n\treturn withMetadataArgument(_getCountryCallingCode, arguments)\r\n}"],"names":["getCountryCallingCode","withMetadataArgument","_getCountryCallingCode"],"mappings":";;AAGO,SAASA,IAAwB;AACvC,SAAOC,EAAqBC,GAAwB,SAAS;AAC9D;","x_google_ignoreList":[0]}
|