@snmt-react-ui/country-select 2.2.1 → 2.3.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/CountrySelect.d.ts +2 -2
- package/dist/country-select.js +179 -175
- package/package.json +3 -3
package/dist/CountrySelect.d.ts
CHANGED
@@ -1,8 +1,8 @@
|
|
1
1
|
export interface CountrySelectProps {
|
2
2
|
/** Sets value for the city select */
|
3
|
-
value?: string;
|
3
|
+
value?: string | null;
|
4
4
|
/** Callback to handle change event */
|
5
|
-
onChange: (value: string) => void;
|
5
|
+
onChange: (value: string | null) => void;
|
6
6
|
/** Sets city value if country select is used first */
|
7
7
|
selectedCity?: string;
|
8
8
|
/** Custom width of a date picker */
|
package/dist/country-select.js
CHANGED
@@ -75,7 +75,7 @@ const de = ({
|
|
75
75
|
}
|
76
76
|
);
|
77
77
|
};
|
78
|
-
var
|
78
|
+
var k = /* @__PURE__ */ ((i) => (i.GREY_LIGHT_0 = "var(--grey-light-0)", i.GREY_LIGHT_1 = "var(--grey-light-1)", i.GREY_LIGHT_2 = "var(--grey-light-2)", i.GREY_LIGHT_3 = "var(--grey-light-3)", i.GREY_LIGHT_4 = "var(--grey-light-4)", i.GREY_DARK_1 = "var(--grey-dark-1)", i.GREY_DARK_2 = "var(--grey-dark-2)", i.GREY_DARK_3 = "var(--grey-dark-3)", i.GREY_DARK_4 = "var(--grey-dark-4)", i.GREY_DARK_5 = "var(--grey-dark-5)", i.BLUE_PRIMARY = "var(--blue-primary)", i.BLUE_HOVER = "var(--blue-hover)", i.BLUE_LIGHT_1 = "var(--blue-light-1)", i.BLUE_LIGHT_2 = "var(--blue-light-2)", i.BLUE_LIGHT_3 = "var(--blue-light-3)", i.BLUE_LIGHT_4 = "var(--blue-light-4)", i.BLUE_DARK_1 = "var(--blue-dark-1)", i.PURPLE_LIGHT = "var(--purple-light)", i.PURPLE_DARK = "var(--purple-dark)", i.NOTIFICATION_WARNING_LIGHT = "var(--notification-warning-light)", i.NOTIFICATION_WARNING_DARK = "var(--notification-warning-dark)", i.NOTIFICATION_SUCCESS_LIGHT = "var(--notification-success-light)", i.NOTIFICATION_SUCCESS_DARK = "var(--notification-success-dark)", i.NOTIFICATION_ERROR_LIGHT = "var(--notification-error-light)", i.NOTIFICATION_ERROR_DARK = "var(--notification-error-dark)", i.NOTIFICATION_ERROR_DARK_MODE = "var(--notification-error-dark-mode)", i))(k || {});
|
79
79
|
const G1 = e1({
|
80
80
|
locale: "en",
|
81
81
|
theme: "light"
|
@@ -1621,7 +1621,7 @@ const ge = ({
|
|
1621
1621
|
), tt = ({
|
1622
1622
|
width: i = 24,
|
1623
1623
|
height: e = 24,
|
1624
|
-
color: t =
|
1624
|
+
color: t = k.GREY_DARK_5,
|
1625
1625
|
className: s,
|
1626
1626
|
onClick: o
|
1627
1627
|
}) => /* @__PURE__ */ u(
|
@@ -1660,7 +1660,7 @@ const ge = ({
|
|
1660
1660
|
), it = ({
|
1661
1661
|
width: i = 20,
|
1662
1662
|
height: e = 20,
|
1663
|
-
color: t =
|
1663
|
+
color: t = k.GREY_DARK_1,
|
1664
1664
|
className: s,
|
1665
1665
|
onClick: o
|
1666
1666
|
}) => /* @__PURE__ */ u(
|
@@ -1693,7 +1693,7 @@ const ge = ({
|
|
1693
1693
|
), st = ({
|
1694
1694
|
width: i = 81,
|
1695
1695
|
height: e = 80,
|
1696
|
-
color: t =
|
1696
|
+
color: t = k.GREY_DARK_5,
|
1697
1697
|
className: s,
|
1698
1698
|
onClick: o
|
1699
1699
|
}) => /* @__PURE__ */ u(
|
@@ -1741,7 +1741,7 @@ const ge = ({
|
|
1741
1741
|
}
|
1742
1742
|
), ot = ({
|
1743
1743
|
className: i,
|
1744
|
-
color: e =
|
1744
|
+
color: e = k.GREY_DARK_5,
|
1745
1745
|
height: t = 20,
|
1746
1746
|
width: s = 20,
|
1747
1747
|
onClick: o
|
@@ -1768,7 +1768,7 @@ const ge = ({
|
|
1768
1768
|
}
|
1769
1769
|
), nt = ({
|
1770
1770
|
className: i,
|
1771
|
-
color: e =
|
1771
|
+
color: e = k.GREY_DARK_5,
|
1772
1772
|
height: t = 20,
|
1773
1773
|
width: s = 20,
|
1774
1774
|
onClick: o
|
@@ -1795,7 +1795,7 @@ const ge = ({
|
|
1795
1795
|
}
|
1796
1796
|
), rt = ({
|
1797
1797
|
className: i,
|
1798
|
-
color: e =
|
1798
|
+
color: e = k.GREY_DARK_5,
|
1799
1799
|
height: t = 5,
|
1800
1800
|
width: s = 10,
|
1801
1801
|
onClick: o
|
@@ -1819,7 +1819,7 @@ const ge = ({
|
|
1819
1819
|
}
|
1820
1820
|
), lt = ({
|
1821
1821
|
className: i,
|
1822
|
-
color: e =
|
1822
|
+
color: e = k.GREY_DARK_5,
|
1823
1823
|
height: t = 5,
|
1824
1824
|
width: s = 10,
|
1825
1825
|
onClick: o
|
@@ -1844,7 +1844,7 @@ const ge = ({
|
|
1844
1844
|
}
|
1845
1845
|
), at = ({
|
1846
1846
|
className: i,
|
1847
|
-
color: e =
|
1847
|
+
color: e = k.GREY_DARK_5,
|
1848
1848
|
height: t = 24,
|
1849
1849
|
width: s = 24,
|
1850
1850
|
onClick: o
|
@@ -1883,7 +1883,7 @@ const ge = ({
|
|
1883
1883
|
}
|
1884
1884
|
), ht = ({
|
1885
1885
|
className: i,
|
1886
|
-
color: e =
|
1886
|
+
color: e = k.GREY_DARK_5,
|
1887
1887
|
height: t = 24,
|
1888
1888
|
width: s = 24,
|
1889
1889
|
onClick: o
|
@@ -1922,7 +1922,7 @@ const ge = ({
|
|
1922
1922
|
}
|
1923
1923
|
), ct = ({
|
1924
1924
|
className: i,
|
1925
|
-
color: e =
|
1925
|
+
color: e = k.GREY_DARK_5,
|
1926
1926
|
height: t = 24,
|
1927
1927
|
width: s = 24,
|
1928
1928
|
onClick: o
|
@@ -1949,7 +1949,7 @@ const ge = ({
|
|
1949
1949
|
}
|
1950
1950
|
), dt = ({
|
1951
1951
|
className: i,
|
1952
|
-
color: e =
|
1952
|
+
color: e = k.GREY_DARK_5,
|
1953
1953
|
height: t = 24,
|
1954
1954
|
width: s = 24,
|
1955
1955
|
onClick: o
|
@@ -2008,7 +2008,7 @@ const ge = ({
|
|
2008
2008
|
}
|
2009
2009
|
), gt = ({
|
2010
2010
|
className: i,
|
2011
|
-
color: e =
|
2011
|
+
color: e = k.GREY_DARK_5,
|
2012
2012
|
height: t = 24,
|
2013
2013
|
width: s = 24,
|
2014
2014
|
onClick: o
|
@@ -2045,7 +2045,7 @@ const ge = ({
|
|
2045
2045
|
}
|
2046
2046
|
), ut = ({
|
2047
2047
|
className: i,
|
2048
|
-
color: e =
|
2048
|
+
color: e = k.GREY_DARK_3,
|
2049
2049
|
height: t = 14,
|
2050
2050
|
width: s = 14,
|
2051
2051
|
onClick: o
|
@@ -2082,7 +2082,7 @@ const ge = ({
|
|
2082
2082
|
}
|
2083
2083
|
), Ct = ({
|
2084
2084
|
className: i,
|
2085
|
-
color: e =
|
2085
|
+
color: e = k.GREY_DARK_5,
|
2086
2086
|
height: t = 18,
|
2087
2087
|
onClick: s,
|
2088
2088
|
width: o = 18
|
@@ -2109,7 +2109,7 @@ const ge = ({
|
|
2109
2109
|
}
|
2110
2110
|
), pt = ({
|
2111
2111
|
className: i,
|
2112
|
-
color: e =
|
2112
|
+
color: e = k.GREY_DARK_5,
|
2113
2113
|
height: t = 24,
|
2114
2114
|
width: s = 24,
|
2115
2115
|
onClick: o
|
@@ -2161,7 +2161,7 @@ const ge = ({
|
|
2161
2161
|
}
|
2162
2162
|
), ft = ({
|
2163
2163
|
className: i,
|
2164
|
-
color: e =
|
2164
|
+
color: e = k.GREY_DARK_5,
|
2165
2165
|
height: t = 24,
|
2166
2166
|
width: s = 24,
|
2167
2167
|
onClick: o
|
@@ -2198,7 +2198,7 @@ const ge = ({
|
|
2198
2198
|
}
|
2199
2199
|
), wt = ({
|
2200
2200
|
className: i,
|
2201
|
-
color: e =
|
2201
|
+
color: e = k.NOTIFICATION_WARNING_DARK,
|
2202
2202
|
height: t = 37,
|
2203
2203
|
width: s = 36,
|
2204
2204
|
onClick: o
|
@@ -2237,7 +2237,7 @@ const ge = ({
|
|
2237
2237
|
}
|
2238
2238
|
), mt = ({
|
2239
2239
|
className: i,
|
2240
|
-
color: e =
|
2240
|
+
color: e = k.GREY_DARK_5,
|
2241
2241
|
height: t = 24,
|
2242
2242
|
width: s = 24,
|
2243
2243
|
onClick: o
|
@@ -2263,7 +2263,7 @@ const ge = ({
|
|
2263
2263
|
}
|
2264
2264
|
), kt = ({
|
2265
2265
|
className: i,
|
2266
|
-
color: e =
|
2266
|
+
color: e = k.GREY_DARK_5,
|
2267
2267
|
height: t = 24,
|
2268
2268
|
width: s = 24,
|
2269
2269
|
onClick: o
|
@@ -2302,7 +2302,7 @@ const ge = ({
|
|
2302
2302
|
}
|
2303
2303
|
), Lt = ({
|
2304
2304
|
className: i,
|
2305
|
-
color: e =
|
2305
|
+
color: e = k.GREY_DARK_5,
|
2306
2306
|
height: t = 24,
|
2307
2307
|
width: s = 24,
|
2308
2308
|
onClick: o
|
@@ -2341,7 +2341,7 @@ const ge = ({
|
|
2341
2341
|
}
|
2342
2342
|
), vt = ({
|
2343
2343
|
className: i,
|
2344
|
-
color: e =
|
2344
|
+
color: e = k.GREY_DARK_5,
|
2345
2345
|
height: t = 24,
|
2346
2346
|
width: s = 24,
|
2347
2347
|
onClick: o
|
@@ -2410,7 +2410,7 @@ const ge = ({
|
|
2410
2410
|
}
|
2411
2411
|
), Nt = ({
|
2412
2412
|
className: i,
|
2413
|
-
color: e =
|
2413
|
+
color: e = k.GREY_DARK_5,
|
2414
2414
|
height: t = 24,
|
2415
2415
|
width: s = 24,
|
2416
2416
|
onClick: o
|
@@ -2449,7 +2449,7 @@ const ge = ({
|
|
2449
2449
|
}
|
2450
2450
|
), xt = ({
|
2451
2451
|
className: i,
|
2452
|
-
color: e =
|
2452
|
+
color: e = k.GREY_DARK_5,
|
2453
2453
|
height: t = 24,
|
2454
2454
|
width: s = 24,
|
2455
2455
|
onClick: o
|
@@ -2506,7 +2506,7 @@ const ge = ({
|
|
2506
2506
|
}
|
2507
2507
|
), Rt = ({
|
2508
2508
|
className: i,
|
2509
|
-
color: e =
|
2509
|
+
color: e = k.GREY_DARK_5,
|
2510
2510
|
height: t = 24,
|
2511
2511
|
width: s = 24,
|
2512
2512
|
onClick: o
|
@@ -2545,7 +2545,7 @@ const ge = ({
|
|
2545
2545
|
}
|
2546
2546
|
), Mt = ({
|
2547
2547
|
className: i,
|
2548
|
-
color: e =
|
2548
|
+
color: e = k.GREY_DARK_5,
|
2549
2549
|
height: t = 24,
|
2550
2550
|
width: s = 24,
|
2551
2551
|
onClick: o
|
@@ -2594,7 +2594,7 @@ const ge = ({
|
|
2594
2594
|
}
|
2595
2595
|
), yt = ({
|
2596
2596
|
className: i,
|
2597
|
-
color: e =
|
2597
|
+
color: e = k.GREY_DARK_5,
|
2598
2598
|
height: t = 24,
|
2599
2599
|
width: s = 24,
|
2600
2600
|
onClick: o
|
@@ -2633,7 +2633,7 @@ const ge = ({
|
|
2633
2633
|
}
|
2634
2634
|
), bt = ({
|
2635
2635
|
className: i,
|
2636
|
-
color: e =
|
2636
|
+
color: e = k.GREY_DARK_5,
|
2637
2637
|
height: t = 24,
|
2638
2638
|
width: s = 24,
|
2639
2639
|
onClick: o
|
@@ -2660,7 +2660,7 @@ const ge = ({
|
|
2660
2660
|
}
|
2661
2661
|
), Et = ({
|
2662
2662
|
className: i,
|
2663
|
-
color: e =
|
2663
|
+
color: e = k.GREY_DARK_5,
|
2664
2664
|
height: t = 24,
|
2665
2665
|
width: s = 24,
|
2666
2666
|
onClick: o
|
@@ -2698,7 +2698,7 @@ const ge = ({
|
|
2698
2698
|
}
|
2699
2699
|
), _t = ({
|
2700
2700
|
className: i,
|
2701
|
-
color: e =
|
2701
|
+
color: e = k.GREY_DARK_5,
|
2702
2702
|
height: t = 24,
|
2703
2703
|
width: s = 24,
|
2704
2704
|
onClick: o
|
@@ -2719,7 +2719,7 @@ const ge = ({
|
|
2719
2719
|
}
|
2720
2720
|
), Ht = ({
|
2721
2721
|
className: i,
|
2722
|
-
color: e =
|
2722
|
+
color: e = k.GREY_DARK_5,
|
2723
2723
|
height: t = 24,
|
2724
2724
|
width: s = 24,
|
2725
2725
|
onClick: o
|
@@ -2758,7 +2758,7 @@ const ge = ({
|
|
2758
2758
|
}
|
2759
2759
|
), Vt = ({
|
2760
2760
|
className: i,
|
2761
|
-
color: e =
|
2761
|
+
color: e = k.GREY_DARK_5,
|
2762
2762
|
height: t = 24,
|
2763
2763
|
width: s = 24,
|
2764
2764
|
onClick: o
|
@@ -2797,7 +2797,7 @@ const ge = ({
|
|
2797
2797
|
}
|
2798
2798
|
), It = ({
|
2799
2799
|
className: i,
|
2800
|
-
color: e =
|
2800
|
+
color: e = k.GREY_DARK_5,
|
2801
2801
|
height: t = 24,
|
2802
2802
|
width: s = 24,
|
2803
2803
|
onClick: o
|
@@ -2836,7 +2836,7 @@ const ge = ({
|
|
2836
2836
|
}
|
2837
2837
|
), St = ({
|
2838
2838
|
className: i,
|
2839
|
-
color: e =
|
2839
|
+
color: e = k.GREY_DARK_2,
|
2840
2840
|
height: t = 16,
|
2841
2841
|
width: s = 16,
|
2842
2842
|
onClick: o
|
@@ -2862,7 +2862,7 @@ const ge = ({
|
|
2862
2862
|
}
|
2863
2863
|
), Ot = ({
|
2864
2864
|
className: i,
|
2865
|
-
color: e =
|
2865
|
+
color: e = k.GREY_DARK_5,
|
2866
2866
|
height: t = 20,
|
2867
2867
|
width: s = 20,
|
2868
2868
|
onClick: o
|
@@ -2891,7 +2891,7 @@ const ge = ({
|
|
2891
2891
|
}
|
2892
2892
|
), At = ({
|
2893
2893
|
className: i,
|
2894
|
-
color: e =
|
2894
|
+
color: e = k.GREY_DARK_5,
|
2895
2895
|
height: t = 20,
|
2896
2896
|
width: s = 20,
|
2897
2897
|
onClick: o
|
@@ -2920,7 +2920,7 @@ const ge = ({
|
|
2920
2920
|
}
|
2921
2921
|
), Bt = ({
|
2922
2922
|
className: i,
|
2923
|
-
color: e =
|
2923
|
+
color: e = k.GREY_DARK_5,
|
2924
2924
|
height: t = 20,
|
2925
2925
|
width: s = 20,
|
2926
2926
|
onClick: o
|
@@ -2935,7 +2935,7 @@ const ge = ({
|
|
2935
2935
|
fill: "none",
|
2936
2936
|
xmlns: "http://www.w3.org/2000/svg",
|
2937
2937
|
children: [
|
2938
|
-
/* @__PURE__ */ n("rect", { width: "20", height: "20", rx: "4", fill:
|
2938
|
+
/* @__PURE__ */ n("rect", { width: "20", height: "20", rx: "4", fill: k.GREY_LIGHT_2 }),
|
2939
2939
|
/* @__PURE__ */ n(
|
2940
2940
|
"path",
|
2941
2941
|
{
|
@@ -2949,7 +2949,7 @@ const ge = ({
|
|
2949
2949
|
}
|
2950
2950
|
), Wt = ({
|
2951
2951
|
className: i,
|
2952
|
-
color: e =
|
2952
|
+
color: e = k.GREY_DARK_5,
|
2953
2953
|
height: t = 20,
|
2954
2954
|
width: s = 20,
|
2955
2955
|
onClick: o
|
@@ -2964,7 +2964,7 @@ const ge = ({
|
|
2964
2964
|
fill: "none",
|
2965
2965
|
xmlns: "http://www.w3.org/2000/svg",
|
2966
2966
|
children: [
|
2967
|
-
/* @__PURE__ */ n("rect", { width: "20", height: "20", rx: "4", fill:
|
2967
|
+
/* @__PURE__ */ n("rect", { width: "20", height: "20", rx: "4", fill: k.GREY_LIGHT_2 }),
|
2968
2968
|
/* @__PURE__ */ n(
|
2969
2969
|
"path",
|
2970
2970
|
{
|
@@ -3077,7 +3077,7 @@ const ge = ({
|
|
3077
3077
|
disabled: l = !1,
|
3078
3078
|
onClick: c
|
3079
3079
|
}) => {
|
3080
|
-
const [r, d] = S(o), { theme: g } = t1(G1), a = l ? g && g === "dark" ?
|
3080
|
+
const [r, d] = S(o), { theme: g } = t1(G1), a = l ? g && g === "dark" ? k.GREY_LIGHT_4 : k.GREY_DARK_1 : s, h = l ? void 0 : c;
|
3081
3081
|
return A(() => {
|
3082
3082
|
if (o) {
|
3083
3083
|
h && !l && d(`${o} clickable`);
|
@@ -3367,7 +3367,7 @@ const ge = ({
|
|
3367
3367
|
);
|
3368
3368
|
}
|
3369
3369
|
);
|
3370
|
-
var
|
3370
|
+
var L = /* @__PURE__ */ ((i) => (i.GREY_LIGHT_0 = "var(--grey-light-0)", i.GREY_LIGHT_1 = "var(--grey-light-1)", i.GREY_LIGHT_2 = "var(--grey-light-2)", i.GREY_LIGHT_3 = "var(--grey-light-3)", i.GREY_LIGHT_4 = "var(--grey-light-4)", i.GREY_DARK_1 = "var(--grey-dark-1)", i.GREY_DARK_2 = "var(--grey-dark-2)", i.GREY_DARK_3 = "var(--grey-dark-3)", i.GREY_DARK_4 = "var(--grey-dark-4)", i.GREY_DARK_5 = "var(--grey-dark-5)", i.BLUE_PRIMARY = "var(--blue-primary)", i.BLUE_HOVER = "var(--blue-hover)", i.BLUE_LIGHT_1 = "var(--blue-light-1)", i.BLUE_LIGHT_2 = "var(--blue-light-2)", i.BLUE_LIGHT_3 = "var(--blue-light-3)", i.BLUE_LIGHT_4 = "var(--blue-light-4)", i.BLUE_DARK_1 = "var(--blue-dark-1)", i.PURPLE_LIGHT = "var(--purple-light)", i.PURPLE_DARK = "var(--purple-dark)", i.NOTIFICATION_WARNING_LIGHT = "var(--notification-warning-light)", i.NOTIFICATION_WARNING_DARK = "var(--notification-warning-dark)", i.NOTIFICATION_SUCCESS_LIGHT = "var(--notification-success-light)", i.NOTIFICATION_SUCCESS_DARK = "var(--notification-success-dark)", i.NOTIFICATION_ERROR_LIGHT = "var(--notification-error-light)", i.NOTIFICATION_ERROR_DARK = "var(--notification-error-dark)", i.NOTIFICATION_ERROR_DARK_MODE = "var(--notification-error-dark-mode)", i))(L || {});
|
3371
3371
|
const K1 = e1({
|
3372
3372
|
locale: "en",
|
3373
3373
|
theme: "light"
|
@@ -4913,7 +4913,7 @@ const Ft = ({
|
|
4913
4913
|
), O2 = ({
|
4914
4914
|
width: i = 24,
|
4915
4915
|
height: e = 24,
|
4916
|
-
color: t =
|
4916
|
+
color: t = L.GREY_DARK_5,
|
4917
4917
|
className: s,
|
4918
4918
|
onClick: o
|
4919
4919
|
}) => /* @__PURE__ */ u(
|
@@ -4952,7 +4952,7 @@ const Ft = ({
|
|
4952
4952
|
), A2 = ({
|
4953
4953
|
width: i = 20,
|
4954
4954
|
height: e = 20,
|
4955
|
-
color: t =
|
4955
|
+
color: t = L.GREY_DARK_1,
|
4956
4956
|
className: s,
|
4957
4957
|
onClick: o
|
4958
4958
|
}) => /* @__PURE__ */ u(
|
@@ -4985,7 +4985,7 @@ const Ft = ({
|
|
4985
4985
|
), B2 = ({
|
4986
4986
|
width: i = 81,
|
4987
4987
|
height: e = 80,
|
4988
|
-
color: t =
|
4988
|
+
color: t = L.GREY_DARK_5,
|
4989
4989
|
className: s,
|
4990
4990
|
onClick: o
|
4991
4991
|
}) => /* @__PURE__ */ u(
|
@@ -5033,7 +5033,7 @@ const Ft = ({
|
|
5033
5033
|
}
|
5034
5034
|
), W2 = ({
|
5035
5035
|
className: i,
|
5036
|
-
color: e =
|
5036
|
+
color: e = L.GREY_DARK_5,
|
5037
5037
|
height: t = 20,
|
5038
5038
|
width: s = 20,
|
5039
5039
|
onClick: o
|
@@ -5060,7 +5060,7 @@ const Ft = ({
|
|
5060
5060
|
}
|
5061
5061
|
), j2 = ({
|
5062
5062
|
className: i,
|
5063
|
-
color: e =
|
5063
|
+
color: e = L.GREY_DARK_5,
|
5064
5064
|
height: t = 20,
|
5065
5065
|
width: s = 20,
|
5066
5066
|
onClick: o
|
@@ -5087,7 +5087,7 @@ const Ft = ({
|
|
5087
5087
|
}
|
5088
5088
|
), Z2 = ({
|
5089
5089
|
className: i,
|
5090
|
-
color: e =
|
5090
|
+
color: e = L.GREY_DARK_5,
|
5091
5091
|
height: t = 5,
|
5092
5092
|
width: s = 10,
|
5093
5093
|
onClick: o
|
@@ -5111,7 +5111,7 @@ const Ft = ({
|
|
5111
5111
|
}
|
5112
5112
|
), D2 = ({
|
5113
5113
|
className: i,
|
5114
|
-
color: e =
|
5114
|
+
color: e = L.GREY_DARK_5,
|
5115
5115
|
height: t = 5,
|
5116
5116
|
width: s = 10,
|
5117
5117
|
onClick: o
|
@@ -5136,7 +5136,7 @@ const Ft = ({
|
|
5136
5136
|
}
|
5137
5137
|
), T2 = ({
|
5138
5138
|
className: i,
|
5139
|
-
color: e =
|
5139
|
+
color: e = L.GREY_DARK_5,
|
5140
5140
|
height: t = 24,
|
5141
5141
|
width: s = 24,
|
5142
5142
|
onClick: o
|
@@ -5175,7 +5175,7 @@ const Ft = ({
|
|
5175
5175
|
}
|
5176
5176
|
), G2 = ({
|
5177
5177
|
className: i,
|
5178
|
-
color: e =
|
5178
|
+
color: e = L.GREY_DARK_5,
|
5179
5179
|
height: t = 24,
|
5180
5180
|
width: s = 24,
|
5181
5181
|
onClick: o
|
@@ -5214,7 +5214,7 @@ const Ft = ({
|
|
5214
5214
|
}
|
5215
5215
|
), K2 = ({
|
5216
5216
|
className: i,
|
5217
|
-
color: e =
|
5217
|
+
color: e = L.GREY_DARK_5,
|
5218
5218
|
height: t = 24,
|
5219
5219
|
width: s = 24,
|
5220
5220
|
onClick: o
|
@@ -5241,7 +5241,7 @@ const Ft = ({
|
|
5241
5241
|
}
|
5242
5242
|
), P2 = ({
|
5243
5243
|
className: i,
|
5244
|
-
color: e =
|
5244
|
+
color: e = L.GREY_DARK_5,
|
5245
5245
|
height: t = 24,
|
5246
5246
|
width: s = 24,
|
5247
5247
|
onClick: o
|
@@ -5300,7 +5300,7 @@ const Ft = ({
|
|
5300
5300
|
}
|
5301
5301
|
), F2 = ({
|
5302
5302
|
className: i,
|
5303
|
-
color: e =
|
5303
|
+
color: e = L.GREY_DARK_5,
|
5304
5304
|
height: t = 24,
|
5305
5305
|
width: s = 24,
|
5306
5306
|
onClick: o
|
@@ -5337,7 +5337,7 @@ const Ft = ({
|
|
5337
5337
|
}
|
5338
5338
|
), $2 = ({
|
5339
5339
|
className: i,
|
5340
|
-
color: e =
|
5340
|
+
color: e = L.GREY_DARK_3,
|
5341
5341
|
height: t = 14,
|
5342
5342
|
width: s = 14,
|
5343
5343
|
onClick: o
|
@@ -5374,7 +5374,7 @@ const Ft = ({
|
|
5374
5374
|
}
|
5375
5375
|
), Y2 = ({
|
5376
5376
|
className: i,
|
5377
|
-
color: e =
|
5377
|
+
color: e = L.GREY_DARK_5,
|
5378
5378
|
height: t = 18,
|
5379
5379
|
onClick: s,
|
5380
5380
|
width: o = 18
|
@@ -5401,7 +5401,7 @@ const Ft = ({
|
|
5401
5401
|
}
|
5402
5402
|
), U2 = ({
|
5403
5403
|
className: i,
|
5404
|
-
color: e =
|
5404
|
+
color: e = L.GREY_DARK_5,
|
5405
5405
|
height: t = 24,
|
5406
5406
|
width: s = 24,
|
5407
5407
|
onClick: o
|
@@ -5453,7 +5453,7 @@ const Ft = ({
|
|
5453
5453
|
}
|
5454
5454
|
), z2 = ({
|
5455
5455
|
className: i,
|
5456
|
-
color: e =
|
5456
|
+
color: e = L.GREY_DARK_5,
|
5457
5457
|
height: t = 24,
|
5458
5458
|
width: s = 24,
|
5459
5459
|
onClick: o
|
@@ -5490,7 +5490,7 @@ const Ft = ({
|
|
5490
5490
|
}
|
5491
5491
|
), J2 = ({
|
5492
5492
|
className: i,
|
5493
|
-
color: e =
|
5493
|
+
color: e = L.NOTIFICATION_WARNING_DARK,
|
5494
5494
|
height: t = 37,
|
5495
5495
|
width: s = 36,
|
5496
5496
|
onClick: o
|
@@ -5529,7 +5529,7 @@ const Ft = ({
|
|
5529
5529
|
}
|
5530
5530
|
), Q2 = ({
|
5531
5531
|
className: i,
|
5532
|
-
color: e =
|
5532
|
+
color: e = L.GREY_DARK_5,
|
5533
5533
|
height: t = 24,
|
5534
5534
|
width: s = 24,
|
5535
5535
|
onClick: o
|
@@ -5555,7 +5555,7 @@ const Ft = ({
|
|
5555
5555
|
}
|
5556
5556
|
), q2 = ({
|
5557
5557
|
className: i,
|
5558
|
-
color: e =
|
5558
|
+
color: e = L.GREY_DARK_5,
|
5559
5559
|
height: t = 24,
|
5560
5560
|
width: s = 24,
|
5561
5561
|
onClick: o
|
@@ -5594,7 +5594,7 @@ const Ft = ({
|
|
5594
5594
|
}
|
5595
5595
|
), X2 = ({
|
5596
5596
|
className: i,
|
5597
|
-
color: e =
|
5597
|
+
color: e = L.GREY_DARK_5,
|
5598
5598
|
height: t = 24,
|
5599
5599
|
width: s = 24,
|
5600
5600
|
onClick: o
|
@@ -5633,7 +5633,7 @@ const Ft = ({
|
|
5633
5633
|
}
|
5634
5634
|
), ei = ({
|
5635
5635
|
className: i,
|
5636
|
-
color: e =
|
5636
|
+
color: e = L.GREY_DARK_5,
|
5637
5637
|
height: t = 24,
|
5638
5638
|
width: s = 24,
|
5639
5639
|
onClick: o
|
@@ -5702,7 +5702,7 @@ const Ft = ({
|
|
5702
5702
|
}
|
5703
5703
|
), ti = ({
|
5704
5704
|
className: i,
|
5705
|
-
color: e =
|
5705
|
+
color: e = L.GREY_DARK_5,
|
5706
5706
|
height: t = 24,
|
5707
5707
|
width: s = 24,
|
5708
5708
|
onClick: o
|
@@ -5741,7 +5741,7 @@ const Ft = ({
|
|
5741
5741
|
}
|
5742
5742
|
), ii = ({
|
5743
5743
|
className: i,
|
5744
|
-
color: e =
|
5744
|
+
color: e = L.GREY_DARK_5,
|
5745
5745
|
height: t = 24,
|
5746
5746
|
width: s = 24,
|
5747
5747
|
onClick: o
|
@@ -5798,7 +5798,7 @@ const Ft = ({
|
|
5798
5798
|
}
|
5799
5799
|
), si = ({
|
5800
5800
|
className: i,
|
5801
|
-
color: e =
|
5801
|
+
color: e = L.GREY_DARK_5,
|
5802
5802
|
height: t = 24,
|
5803
5803
|
width: s = 24,
|
5804
5804
|
onClick: o
|
@@ -5837,7 +5837,7 @@ const Ft = ({
|
|
5837
5837
|
}
|
5838
5838
|
), oi = ({
|
5839
5839
|
className: i,
|
5840
|
-
color: e =
|
5840
|
+
color: e = L.GREY_DARK_5,
|
5841
5841
|
height: t = 24,
|
5842
5842
|
width: s = 24,
|
5843
5843
|
onClick: o
|
@@ -5886,7 +5886,7 @@ const Ft = ({
|
|
5886
5886
|
}
|
5887
5887
|
), ni = ({
|
5888
5888
|
className: i,
|
5889
|
-
color: e =
|
5889
|
+
color: e = L.GREY_DARK_5,
|
5890
5890
|
height: t = 24,
|
5891
5891
|
width: s = 24,
|
5892
5892
|
onClick: o
|
@@ -5925,7 +5925,7 @@ const Ft = ({
|
|
5925
5925
|
}
|
5926
5926
|
), ri = ({
|
5927
5927
|
className: i,
|
5928
|
-
color: e =
|
5928
|
+
color: e = L.GREY_DARK_5,
|
5929
5929
|
height: t = 24,
|
5930
5930
|
width: s = 24,
|
5931
5931
|
onClick: o
|
@@ -5952,7 +5952,7 @@ const Ft = ({
|
|
5952
5952
|
}
|
5953
5953
|
), li = ({
|
5954
5954
|
className: i,
|
5955
|
-
color: e =
|
5955
|
+
color: e = L.GREY_DARK_5,
|
5956
5956
|
height: t = 24,
|
5957
5957
|
width: s = 24,
|
5958
5958
|
onClick: o
|
@@ -5990,7 +5990,7 @@ const Ft = ({
|
|
5990
5990
|
}
|
5991
5991
|
), ai = ({
|
5992
5992
|
className: i,
|
5993
|
-
color: e =
|
5993
|
+
color: e = L.GREY_DARK_5,
|
5994
5994
|
height: t = 24,
|
5995
5995
|
width: s = 24,
|
5996
5996
|
onClick: o
|
@@ -6011,7 +6011,7 @@ const Ft = ({
|
|
6011
6011
|
}
|
6012
6012
|
), hi = ({
|
6013
6013
|
className: i,
|
6014
|
-
color: e =
|
6014
|
+
color: e = L.GREY_DARK_5,
|
6015
6015
|
height: t = 24,
|
6016
6016
|
width: s = 24,
|
6017
6017
|
onClick: o
|
@@ -6050,7 +6050,7 @@ const Ft = ({
|
|
6050
6050
|
}
|
6051
6051
|
), ci = ({
|
6052
6052
|
className: i,
|
6053
|
-
color: e =
|
6053
|
+
color: e = L.GREY_DARK_5,
|
6054
6054
|
height: t = 24,
|
6055
6055
|
width: s = 24,
|
6056
6056
|
onClick: o
|
@@ -6089,7 +6089,7 @@ const Ft = ({
|
|
6089
6089
|
}
|
6090
6090
|
), di = ({
|
6091
6091
|
className: i,
|
6092
|
-
color: e =
|
6092
|
+
color: e = L.GREY_DARK_5,
|
6093
6093
|
height: t = 24,
|
6094
6094
|
width: s = 24,
|
6095
6095
|
onClick: o
|
@@ -6128,7 +6128,7 @@ const Ft = ({
|
|
6128
6128
|
}
|
6129
6129
|
), gi = ({
|
6130
6130
|
className: i,
|
6131
|
-
color: e =
|
6131
|
+
color: e = L.GREY_DARK_2,
|
6132
6132
|
height: t = 16,
|
6133
6133
|
width: s = 16,
|
6134
6134
|
onClick: o
|
@@ -6154,7 +6154,7 @@ const Ft = ({
|
|
6154
6154
|
}
|
6155
6155
|
), ui = ({
|
6156
6156
|
className: i,
|
6157
|
-
color: e =
|
6157
|
+
color: e = L.GREY_DARK_5,
|
6158
6158
|
height: t = 20,
|
6159
6159
|
width: s = 20,
|
6160
6160
|
onClick: o
|
@@ -6183,7 +6183,7 @@ const Ft = ({
|
|
6183
6183
|
}
|
6184
6184
|
), Ci = ({
|
6185
6185
|
className: i,
|
6186
|
-
color: e =
|
6186
|
+
color: e = L.GREY_DARK_5,
|
6187
6187
|
height: t = 20,
|
6188
6188
|
width: s = 20,
|
6189
6189
|
onClick: o
|
@@ -6212,7 +6212,7 @@ const Ft = ({
|
|
6212
6212
|
}
|
6213
6213
|
), pi = ({
|
6214
6214
|
className: i,
|
6215
|
-
color: e =
|
6215
|
+
color: e = L.GREY_DARK_5,
|
6216
6216
|
height: t = 20,
|
6217
6217
|
width: s = 20,
|
6218
6218
|
onClick: o
|
@@ -6227,7 +6227,7 @@ const Ft = ({
|
|
6227
6227
|
fill: "none",
|
6228
6228
|
xmlns: "http://www.w3.org/2000/svg",
|
6229
6229
|
children: [
|
6230
|
-
/* @__PURE__ */ n("rect", { width: "20", height: "20", rx: "4", fill:
|
6230
|
+
/* @__PURE__ */ n("rect", { width: "20", height: "20", rx: "4", fill: L.GREY_LIGHT_2 }),
|
6231
6231
|
/* @__PURE__ */ n(
|
6232
6232
|
"path",
|
6233
6233
|
{
|
@@ -6241,7 +6241,7 @@ const Ft = ({
|
|
6241
6241
|
}
|
6242
6242
|
), fi = ({
|
6243
6243
|
className: i,
|
6244
|
-
color: e =
|
6244
|
+
color: e = L.GREY_DARK_5,
|
6245
6245
|
height: t = 20,
|
6246
6246
|
width: s = 20,
|
6247
6247
|
onClick: o
|
@@ -6256,7 +6256,7 @@ const Ft = ({
|
|
6256
6256
|
fill: "none",
|
6257
6257
|
xmlns: "http://www.w3.org/2000/svg",
|
6258
6258
|
children: [
|
6259
|
-
/* @__PURE__ */ n("rect", { width: "20", height: "20", rx: "4", fill:
|
6259
|
+
/* @__PURE__ */ n("rect", { width: "20", height: "20", rx: "4", fill: L.GREY_LIGHT_2 }),
|
6260
6260
|
/* @__PURE__ */ n(
|
6261
6261
|
"path",
|
6262
6262
|
{
|
@@ -6369,7 +6369,7 @@ const Ft = ({
|
|
6369
6369
|
disabled: l = !1,
|
6370
6370
|
onClick: c
|
6371
6371
|
}) => {
|
6372
|
-
const [r, d] = S(o), { theme: g } = t1(K1), a = l ? g && g === "dark" ?
|
6372
|
+
const [r, d] = S(o), { theme: g } = t1(K1), a = l ? g && g === "dark" ? L.GREY_LIGHT_4 : L.GREY_DARK_1 : s, h = l ? void 0 : c;
|
6373
6373
|
return A(() => {
|
6374
6374
|
if (o) {
|
6375
6375
|
h && !l && d(`${o} clickable`);
|
@@ -6783,11 +6783,11 @@ const F1 = ({ children: i, width: e, size: t = "small", onClose: s, closable: o
|
|
6783
6783
|
id: w,
|
6784
6784
|
extraOptions: v,
|
6785
6785
|
dropdownRender: N,
|
6786
|
-
optionRender:
|
6787
|
-
isLoading:
|
6788
|
-
readOnly:
|
6789
|
-
},
|
6790
|
-
const [
|
6786
|
+
optionRender: E,
|
6787
|
+
isLoading: y,
|
6788
|
+
readOnly: R
|
6789
|
+
}, m) => {
|
6790
|
+
const [x, b] = S(!1), [M, D] = S(!1), [i1, P] = S(!0), [V, s1] = S(i), o1 = N1(null);
|
6791
6791
|
A(() => {
|
6792
6792
|
s1(i);
|
6793
6793
|
}, [i]);
|
@@ -6812,14 +6812,14 @@ const F1 = ({ children: i, width: e, size: t = "small", onClose: s, closable: o
|
|
6812
6812
|
},
|
6813
6813
|
[s, e]
|
6814
6814
|
), j = Z(() => {
|
6815
|
-
if (!
|
6815
|
+
if (!R) {
|
6816
6816
|
if (s) {
|
6817
6817
|
H([]);
|
6818
6818
|
return;
|
6819
6819
|
}
|
6820
6820
|
H("");
|
6821
6821
|
}
|
6822
|
-
}, [H, s,
|
6822
|
+
}, [H, s, R]), B = Z(
|
6823
6823
|
(f) => {
|
6824
6824
|
const _ = V.filter((O) => O !== f);
|
6825
6825
|
H(_), s1(_);
|
@@ -6854,13 +6854,13 @@ const F1 = ({ children: i, width: e, size: t = "small", onClose: s, closable: o
|
|
6854
6854
|
values: f,
|
6855
6855
|
onTagClose: B,
|
6856
6856
|
maxWidth: ((_ = o1.current) == null ? void 0 : _.clientWidth) || 0,
|
6857
|
-
disabled: r ||
|
6857
|
+
disabled: r || R,
|
6858
6858
|
options: l,
|
6859
6859
|
extraOptions: v
|
6860
6860
|
}
|
6861
6861
|
);
|
6862
6862
|
},
|
6863
|
-
[r, v, B, l,
|
6863
|
+
[r, v, B, l, R]
|
6864
6864
|
), te = Z(
|
6865
6865
|
({ label: f, value: _, mode: O }) => O === "filter" ? J(_) : /* @__PURE__ */ n("div", { onMouseDown: q1, className: "tag-wrapper", children: /* @__PURE__ */ n(F1, { onClose: () => B(_), closable: !r, children: /* @__PURE__ */ n($1, { variant: "body4", children: typeof f == "object" ? f : p1(_) }) }) }),
|
6866
6866
|
[r, p1, B, J]
|
@@ -6869,7 +6869,7 @@ const F1 = ({ children: i, width: e, size: t = "small", onClose: s, closable: o
|
|
6869
6869
|
"div",
|
6870
6870
|
{
|
6871
6871
|
className: `snmt-select ${M ? "snmt-select-focused" : ""}
|
6872
|
-
${s ? "" : "snmt-select-single"} ${
|
6872
|
+
${s ? "" : "snmt-select-single"} ${R ? "snmt-select-read-only" : ""}`,
|
6873
6873
|
ref: o1,
|
6874
6874
|
style: { width: c },
|
6875
6875
|
children: [
|
@@ -6877,9 +6877,9 @@ const F1 = ({ children: i, width: e, size: t = "small", onClose: s, closable: o
|
|
6877
6877
|
ne,
|
6878
6878
|
{
|
6879
6879
|
className: "snmt-select-blank",
|
6880
|
-
popupClassName:
|
6880
|
+
popupClassName: R ? "dropdown-read-only" : "",
|
6881
6881
|
id: w,
|
6882
|
-
ref:
|
6882
|
+
ref: m,
|
6883
6883
|
showSearch: !!o,
|
6884
6884
|
filterOption: o && G,
|
6885
6885
|
onDropdownVisibleChange: T,
|
@@ -6900,7 +6900,7 @@ const F1 = ({ children: i, width: e, size: t = "small", onClose: s, closable: o
|
|
6900
6900
|
maxTagCount: "responsive",
|
6901
6901
|
maxTagPlaceholder: ee,
|
6902
6902
|
onPopupScroll: X1,
|
6903
|
-
prefix:
|
6903
|
+
prefix: R && !i && /* @__PURE__ */ n(R1, { size: 15 }),
|
6904
6904
|
suffixIcon: /* @__PURE__ */ n("div", { className: "wrapper-suffix-icon", children: s !== "filter" && /* @__PURE__ */ u(z, { children: [
|
6905
6905
|
s && V && !!V.length && /* @__PURE__ */ n("div", { onClick: j, children: /* @__PURE__ */ n(r1, { name: "cancel" }) }),
|
6906
6906
|
/* @__PURE__ */ n(
|
@@ -6908,14 +6908,14 @@ const F1 = ({ children: i, width: e, size: t = "small", onClose: s, closable: o
|
|
6908
6908
|
{
|
6909
6909
|
name: "selectArrowIcon",
|
6910
6910
|
color: r ? U.GREY_DARK_1 : U.GREY_DARK_5,
|
6911
|
-
className:
|
6912
|
-
onClick: () => b(!
|
6911
|
+
className: x ? "select-arrow-rotated" : "select-arrow",
|
6912
|
+
onClick: () => b(!x)
|
6913
6913
|
}
|
6914
6914
|
)
|
6915
6915
|
] }) }),
|
6916
6916
|
removeIcon: /* @__PURE__ */ n(r1, { name: "errorSmall", color: U.GREY_DARK_2 }),
|
6917
6917
|
options: l,
|
6918
|
-
optionRender: (f) =>
|
6918
|
+
optionRender: (f) => E ? E(f.data) : /* @__PURE__ */ u(a1, { justifyContent: "space-between", alignItems: "center", flex: "1", children: [
|
6919
6919
|
/* @__PURE__ */ u(a1, { alignItems: "center", gap: 12, children: [
|
6920
6920
|
s && /* @__PURE__ */ n(
|
6921
6921
|
de,
|
@@ -6938,7 +6938,7 @@ const F1 = ({ children: i, width: e, size: t = "small", onClose: s, closable: o
|
|
6938
6938
|
}
|
6939
6939
|
)
|
6940
6940
|
] }),
|
6941
|
-
dropdownRender:
|
6941
|
+
dropdownRender: y ? () => /* @__PURE__ */ n(
|
6942
6942
|
"div",
|
6943
6943
|
{
|
6944
6944
|
style: {
|
@@ -7302,15 +7302,15 @@ class g1 extends C1 {
|
|
7302
7302
|
} = this.extractFromKey(e[e.length - 1], t), d = r[r.length - 1], g = t.lng || this.language, a = t.appendNamespaceToCIMode || this.options.appendNamespaceToCIMode;
|
7303
7303
|
if (g && g.toLowerCase() === "cimode") {
|
7304
7304
|
if (a) {
|
7305
|
-
const
|
7305
|
+
const m = t.nsSeparator || this.options.nsSeparator;
|
7306
7306
|
return o ? {
|
7307
|
-
res: `${d}${
|
7307
|
+
res: `${d}${m}${c}`,
|
7308
7308
|
usedKey: c,
|
7309
7309
|
exactUsedKey: c,
|
7310
7310
|
usedLng: g,
|
7311
7311
|
usedNS: d,
|
7312
7312
|
usedParams: this.getUsedParamsDetails(t)
|
7313
|
-
} : `${d}${
|
7313
|
+
} : `${d}${m}${c}`;
|
7314
7314
|
}
|
7315
7315
|
return o ? {
|
7316
7316
|
res: c,
|
@@ -7323,39 +7323,39 @@ class g1 extends C1 {
|
|
7323
7323
|
}
|
7324
7324
|
const h = this.resolve(e, t);
|
7325
7325
|
let C = h && h.res;
|
7326
|
-
const p = h && h.usedKey || c, w = h && h.exactUsedKey || c, v = Object.prototype.toString.apply(C), N = ["[object Number]", "[object Function]", "[object RegExp]"],
|
7327
|
-
if (
|
7326
|
+
const p = h && h.usedKey || c, w = h && h.exactUsedKey || c, v = Object.prototype.toString.apply(C), N = ["[object Number]", "[object Function]", "[object RegExp]"], E = t.joinArrays !== void 0 ? t.joinArrays : this.options.joinArrays, y = !this.i18nFormat || this.i18nFormat.handleAsObject;
|
7327
|
+
if (y && C && (typeof C != "string" && typeof C != "boolean" && typeof C != "number") && N.indexOf(v) < 0 && !(typeof E == "string" && Array.isArray(C))) {
|
7328
7328
|
if (!t.returnObjects && !this.options.returnObjects) {
|
7329
7329
|
this.options.returnedObjectHandler || this.logger.warn("accessing an object - but returnObjects options is not enabled!");
|
7330
|
-
const
|
7330
|
+
const m = this.options.returnedObjectHandler ? this.options.returnedObjectHandler(p, C, {
|
7331
7331
|
...t,
|
7332
7332
|
ns: r
|
7333
7333
|
}) : `key '${c} (${this.language})' returned an object instead of string.`;
|
7334
|
-
return o ? (h.res =
|
7334
|
+
return o ? (h.res = m, h.usedParams = this.getUsedParamsDetails(t), h) : m;
|
7335
7335
|
}
|
7336
7336
|
if (l) {
|
7337
|
-
const
|
7337
|
+
const m = Array.isArray(C), x = m ? [] : {}, b = m ? w : p;
|
7338
7338
|
for (const M in C)
|
7339
7339
|
if (Object.prototype.hasOwnProperty.call(C, M)) {
|
7340
7340
|
const D = `${b}${l}${M}`;
|
7341
|
-
|
7341
|
+
x[M] = this.translate(D, {
|
7342
7342
|
...t,
|
7343
7343
|
joinArrays: !1,
|
7344
7344
|
ns: r
|
7345
|
-
}),
|
7345
|
+
}), x[M] === D && (x[M] = C[M]);
|
7346
7346
|
}
|
7347
|
-
C =
|
7347
|
+
C = x;
|
7348
7348
|
}
|
7349
|
-
} else if (
|
7350
|
-
C = C.join(
|
7349
|
+
} else if (y && typeof E == "string" && Array.isArray(C))
|
7350
|
+
C = C.join(E), C && (C = this.extendTranslation(C, e, t, s));
|
7351
7351
|
else {
|
7352
|
-
let
|
7352
|
+
let m = !1, x = !1;
|
7353
7353
|
const b = t.count !== void 0 && typeof t.count != "string", M = g1.hasDefaultValue(t), D = b ? this.pluralResolver.getSuffix(g, t.count, t) : "", i1 = t.ordinal && b ? this.pluralResolver.getSuffix(g, t.count, {
|
7354
7354
|
ordinal: !1
|
7355
7355
|
}) : "", P = b && !t.ordinal && t.count === 0 && this.pluralResolver.shouldUseIntlApi(), V = P && t[`defaultValue${this.options.pluralSeparator}zero`] || t[`defaultValue${D}`] || t[`defaultValue${i1}`] || t.defaultValue;
|
7356
|
-
!this.isValidLookup(C) && M && (
|
7357
|
-
const o1 = (t.missingKeyNoValueFallbackToKey || this.options.missingKeyNoValueFallbackToKey) &&
|
7358
|
-
if (
|
7356
|
+
!this.isValidLookup(C) && M && (m = !0, C = V), this.isValidLookup(C) || (x = !0, C = c);
|
7357
|
+
const o1 = (t.missingKeyNoValueFallbackToKey || this.options.missingKeyNoValueFallbackToKey) && x ? void 0 : C, T = M && V !== C && this.options.updateMissing;
|
7358
|
+
if (x || m || T) {
|
7359
7359
|
if (this.logger.log(T ? "updateKey" : "missingKey", g, d, c, T ? V : C), l) {
|
7360
7360
|
const H = this.resolve(c, {
|
7361
7361
|
...t,
|
@@ -7380,7 +7380,7 @@ class g1 extends C1 {
|
|
7380
7380
|
});
|
7381
7381
|
}) : n1(G, c, V));
|
7382
7382
|
}
|
7383
|
-
C = this.extendTranslation(C, e, t, h, s),
|
7383
|
+
C = this.extendTranslation(C, e, t, h, s), x && C === c && this.options.appendNamespaceToMissingKey && (C = `${d}:${c}`), (x || m) && this.options.parseMissingKeyHandler && (this.options.compatibilityAPI !== "v1" ? C = this.options.parseMissingKeyHandler(this.options.appendNamespaceToMissingKey ? `${d}:${c}` : c, m ? C : void 0) : C = this.options.parseMissingKeyHandler(C));
|
7384
7384
|
}
|
7385
7385
|
return o ? (h.res = C, h.usedParams = this.getUsedParamsDetails(t), h) : C;
|
7386
7386
|
}
|
@@ -7440,24 +7440,24 @@ class g1 extends C1 {
|
|
7440
7440
|
this.options.fallbackNS && (h = h.concat(this.options.fallbackNS));
|
7441
7441
|
const C = t.count !== void 0 && typeof t.count != "string", p = C && !t.ordinal && t.count === 0 && this.pluralResolver.shouldUseIntlApi(), w = t.context !== void 0 && (typeof t.context == "string" || typeof t.context == "number") && t.context !== "", v = t.lngs ? t.lngs : this.languageUtils.toResolveHierarchy(t.lng || this.language, t.fallbackLng);
|
7442
7442
|
h.forEach((N) => {
|
7443
|
-
this.isValidLookup(s) || (r = N, !H1[`${v[0]}-${N}`] && this.utils && this.utils.hasLoadedNamespace && !this.utils.hasLoadedNamespace(r) && (H1[`${v[0]}-${N}`] = !0, this.logger.warn(`key "${o}" for languages "${v.join(", ")}" won't get resolved as namespace "${r}" was not yet loaded`, "This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!")), v.forEach((
|
7443
|
+
this.isValidLookup(s) || (r = N, !H1[`${v[0]}-${N}`] && this.utils && this.utils.hasLoadedNamespace && !this.utils.hasLoadedNamespace(r) && (H1[`${v[0]}-${N}`] = !0, this.logger.warn(`key "${o}" for languages "${v.join(", ")}" won't get resolved as namespace "${r}" was not yet loaded`, "This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!")), v.forEach((E) => {
|
7444
7444
|
if (this.isValidLookup(s)) return;
|
7445
|
-
c =
|
7446
|
-
const
|
7445
|
+
c = E;
|
7446
|
+
const y = [a];
|
7447
7447
|
if (this.i18nFormat && this.i18nFormat.addLookupKeys)
|
7448
|
-
this.i18nFormat.addLookupKeys(
|
7448
|
+
this.i18nFormat.addLookupKeys(y, a, E, N, t);
|
7449
7449
|
else {
|
7450
|
-
let
|
7451
|
-
C && (
|
7452
|
-
const
|
7453
|
-
if (C && (
|
7450
|
+
let m;
|
7451
|
+
C && (m = this.pluralResolver.getSuffix(E, t.count, t));
|
7452
|
+
const x = `${this.options.pluralSeparator}zero`, b = `${this.options.pluralSeparator}ordinal${this.options.pluralSeparator}`;
|
7453
|
+
if (C && (y.push(a + m), t.ordinal && m.indexOf(b) === 0 && y.push(a + m.replace(b, this.options.pluralSeparator)), p && y.push(a + x)), w) {
|
7454
7454
|
const M = `${a}${this.options.contextSeparator}${t.context}`;
|
7455
|
-
|
7455
|
+
y.push(M), C && (y.push(M + m), t.ordinal && m.indexOf(b) === 0 && y.push(M + m.replace(b, this.options.pluralSeparator)), p && y.push(M + x));
|
7456
7456
|
}
|
7457
7457
|
}
|
7458
|
-
let
|
7459
|
-
for (;
|
7460
|
-
this.isValidLookup(s) || (l =
|
7458
|
+
let R;
|
7459
|
+
for (; R = y.pop(); )
|
7460
|
+
this.isValidLookup(s) || (l = R, s = this.getResource(E, N, R, t));
|
7461
7461
|
}));
|
7462
7462
|
});
|
7463
7463
|
}), {
|
@@ -7783,10 +7783,10 @@ class Fi {
|
|
7783
7783
|
nestingSuffix: w,
|
7784
7784
|
nestingSuffixEscaped: v,
|
7785
7785
|
nestingOptionsSeparator: N,
|
7786
|
-
maxReplaces:
|
7787
|
-
alwaysFormat:
|
7786
|
+
maxReplaces: E,
|
7787
|
+
alwaysFormat: y
|
7788
7788
|
} = e.interpolation;
|
7789
|
-
this.escape = t !== void 0 ? t : Oi, this.escapeValue = s !== void 0 ? s : !0, this.useRawValueToEscape = o !== void 0 ? o : !1, this.prefix = l ? $(l) : c || "{{", this.suffix = r ? $(r) : d || "}}", this.formatSeparator = g || ",", this.unescapePrefix = a ? "" : h || "-", this.unescapeSuffix = this.unescapePrefix ? "" : a || "", this.nestingPrefix = C ? $(C) : p || $("$t("), this.nestingSuffix = w ? $(w) : v || $(")"), this.nestingOptionsSeparator = N || ",", this.maxReplaces =
|
7789
|
+
this.escape = t !== void 0 ? t : Oi, this.escapeValue = s !== void 0 ? s : !0, this.useRawValueToEscape = o !== void 0 ? o : !1, this.prefix = l ? $(l) : c || "{{", this.suffix = r ? $(r) : d || "}}", this.formatSeparator = g || ",", this.unescapePrefix = a ? "" : h || "-", this.unescapeSuffix = this.unescapePrefix ? "" : a || "", this.nestingPrefix = C ? $(C) : p || $("$t("), this.nestingSuffix = w ? $(w) : v || $(")"), this.nestingOptionsSeparator = N || ",", this.maxReplaces = E || 1e3, this.alwaysFormat = y !== void 0 ? y : !1, this.resetRegExp();
|
7790
7790
|
}
|
7791
7791
|
reset() {
|
7792
7792
|
this.options && this.init(this.options);
|
@@ -7799,12 +7799,12 @@ class Fi {
|
|
7799
7799
|
let l, c, r;
|
7800
7800
|
const d = this.options && this.options.interpolation && this.options.interpolation.defaultVariables || {}, g = (p) => {
|
7801
7801
|
if (p.indexOf(this.formatSeparator) < 0) {
|
7802
|
-
const
|
7803
|
-
return this.alwaysFormat ? this.format(
|
7802
|
+
const E = S1(t, d, p, this.options.keySeparator, this.options.ignoreJSONStructure);
|
7803
|
+
return this.alwaysFormat ? this.format(E, void 0, s, {
|
7804
7804
|
...o,
|
7805
7805
|
...t,
|
7806
7806
|
interpolationkey: p
|
7807
|
-
}) :
|
7807
|
+
}) : E;
|
7808
7808
|
}
|
7809
7809
|
const w = p.split(this.formatSeparator), v = w.shift().trim(), N = w.join(this.formatSeparator).trim();
|
7810
7810
|
return this.format(S1(t, d, v, this.options.keySeparator, this.options.ignoreJSONStructure), N, s, {
|
@@ -8567,8 +8567,8 @@ const g5 = (i, e) => {
|
|
8567
8567
|
} = t1(c5) || {}, l = t || s || a5();
|
8568
8568
|
if (l && !l.reportNamespaces && (l.reportNamespaces = new d5()), !l) {
|
8569
8569
|
L1("You will need to pass in an i18next instance by using initReactI18next");
|
8570
|
-
const
|
8571
|
-
return
|
8570
|
+
const m = (b, M) => K(M) ? M : e5(M) && K(M.defaultValue) ? M.defaultValue : Array.isArray(b) ? b[b.length - 1] : b, x = [m, {}, !1];
|
8571
|
+
return x.t = m, x.i18n = {}, x.ready = !1, x;
|
8572
8572
|
}
|
8573
8573
|
l.options.react && l.options.react.wait !== void 0 && L1("It seems you are still using the old wait option, you may migrate to the new useSuspense behaviour.");
|
8574
8574
|
const c = {
|
@@ -8581,33 +8581,33 @@ const g5 = (i, e) => {
|
|
8581
8581
|
} = c;
|
8582
8582
|
let g = i;
|
8583
8583
|
g = K(g) ? [g] : g || ["translation"], l.reportNamespaces.addUsedNamespaces && l.reportNamespaces.addUsedNamespaces(g);
|
8584
|
-
const a = (l.isInitialized || l.initializedStoreOnce) && g.every((
|
8584
|
+
const a = (l.isInitialized || l.initializedStoreOnce) && g.every((m) => Xi(m, l, c)), h = u5(l, e.lng || null, c.nsMode === "fallback" ? g : g[0], d), C = () => h, p = () => Q1(l, e.lng || null, c.nsMode === "fallback" ? g : g[0], d), [w, v] = S(C);
|
8585
8585
|
let N = g.join();
|
8586
8586
|
e.lng && (N = `${e.lng}${N}`);
|
8587
|
-
const
|
8587
|
+
const E = g5(N), y = N1(!0);
|
8588
8588
|
A(() => {
|
8589
8589
|
const {
|
8590
|
-
bindI18n:
|
8591
|
-
bindI18nStore:
|
8590
|
+
bindI18n: m,
|
8591
|
+
bindI18nStore: x
|
8592
8592
|
} = c;
|
8593
|
-
|
8594
|
-
|
8593
|
+
y.current = !0, !a && !r && (e.lng ? j1(l, e.lng, g, () => {
|
8594
|
+
y.current && v(p);
|
8595
8595
|
}) : W1(l, g, () => {
|
8596
|
-
|
8597
|
-
})), a &&
|
8596
|
+
y.current && v(p);
|
8597
|
+
})), a && E && E !== N && y.current && v(p);
|
8598
8598
|
const b = () => {
|
8599
|
-
|
8599
|
+
y.current && v(p);
|
8600
8600
|
};
|
8601
|
-
return
|
8602
|
-
|
8601
|
+
return m && l && l.on(m, b), x && l && l.store.on(x, b), () => {
|
8602
|
+
y.current = !1, m && l && m.split(" ").forEach((M) => l.off(M, b)), x && l && x.split(" ").forEach((M) => l.store.off(M, b));
|
8603
8603
|
};
|
8604
8604
|
}, [l, N]), A(() => {
|
8605
|
-
|
8605
|
+
y.current && a && v(C);
|
8606
8606
|
}, [l, d, a]);
|
8607
|
-
const
|
8608
|
-
if (
|
8609
|
-
throw new Promise((
|
8610
|
-
e.lng ? j1(l, e.lng, g, () =>
|
8607
|
+
const R = [w, l, a];
|
8608
|
+
if (R.t = w, R.i18n = l, R.ready = a, a || !a && !r) return R;
|
8609
|
+
throw new Promise((m) => {
|
8610
|
+
e.lng ? j1(l, e.lng, g, () => m()) : W1(l, g, () => m());
|
8611
8611
|
});
|
8612
8612
|
}, p5 = "Country", f5 = {
|
8613
8613
|
placeholder: p5
|
@@ -8628,56 +8628,60 @@ I.use(h5).init({
|
|
8628
8628
|
});
|
8629
8629
|
const y5 = u1(
|
8630
8630
|
({ width: i, selectedCity: e, setSelectedCity: t, onChange: s, value: o, id: l, disabled: c }, r) => {
|
8631
|
-
const [d, g] = S([]), [a, h] = S([]), { locale:
|
8632
|
-
if (!
|
8631
|
+
const [d, g] = S([]), [a, h] = S([]), [C, p] = S(!1), { locale: w, axiosPeople: v } = t1(oe);
|
8632
|
+
if (!v)
|
8633
8633
|
throw new Error(
|
8634
8634
|
`CountrySelect requires "axiosPeople" to fetch counties.
|
8635
8635
|
Please provide it via SNMTUiContext.`
|
8636
8636
|
);
|
8637
|
-
const { t:
|
8637
|
+
const { t: N } = C5("common", { lng: w }), E = Z(async () => {
|
8638
|
+
p(!0);
|
8638
8639
|
try {
|
8639
|
-
const R = await
|
8640
|
+
const R = await v.post("v1/countries/search");
|
8640
8641
|
h(R == null ? void 0 : R.data.data);
|
8641
8642
|
} catch {
|
8642
8643
|
g([]);
|
8644
|
+
} finally {
|
8645
|
+
p(!1);
|
8643
8646
|
}
|
8644
|
-
}, [
|
8647
|
+
}, [v]);
|
8645
8648
|
A(() => {
|
8646
|
-
|
8649
|
+
E();
|
8647
8650
|
}, []), A(() => {
|
8648
8651
|
if (e) {
|
8649
|
-
const R = e.split("-")[1],
|
8650
|
-
(
|
8652
|
+
const R = e.split("-")[1], m = a.filter(
|
8653
|
+
(x) => x.name.includes(R)
|
8651
8654
|
);
|
8652
|
-
if (
|
8653
|
-
const
|
8654
|
-
label:
|
8655
|
-
value:
|
8655
|
+
if (m.length) {
|
8656
|
+
const x = m.map((b) => ({
|
8657
|
+
label: b.name,
|
8658
|
+
value: b.name
|
8656
8659
|
}));
|
8657
|
-
s(
|
8660
|
+
s(x[0].value);
|
8658
8661
|
}
|
8659
8662
|
}
|
8660
8663
|
}, [e, a, s]), A(() => {
|
8661
|
-
const R = a.map((
|
8662
|
-
label:
|
8663
|
-
value:
|
8664
|
+
const R = a.map((m) => ({
|
8665
|
+
label: m.name,
|
8666
|
+
value: m.name
|
8664
8667
|
}));
|
8665
8668
|
g(R);
|
8666
8669
|
}, [a]);
|
8667
|
-
const
|
8668
|
-
R ===
|
8670
|
+
const y = (R) => {
|
8671
|
+
R === null ? (s(""), t && t("")) : (s(R), t && t(""));
|
8669
8672
|
};
|
8670
8673
|
return /* @__PURE__ */ n("div", { className: "snmt-country-select", children: /* @__PURE__ */ n(
|
8671
8674
|
bi,
|
8672
8675
|
{
|
8673
8676
|
id: l,
|
8674
8677
|
width: i,
|
8675
|
-
placeholder:
|
8678
|
+
placeholder: N("placeholder"),
|
8676
8679
|
value: o,
|
8677
8680
|
ref: r,
|
8678
|
-
onChange:
|
8679
|
-
options: [{ label: "None", value:
|
8680
|
-
disabled: c
|
8681
|
+
onChange: y,
|
8682
|
+
options: [{ label: "None", value: null }, ...d],
|
8683
|
+
disabled: c,
|
8684
|
+
isLoading: C
|
8681
8685
|
}
|
8682
8686
|
) });
|
8683
8687
|
}
|
package/package.json
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
{
|
2
2
|
"name": "@snmt-react-ui/country-select",
|
3
3
|
"private": false,
|
4
|
-
"version": "2.
|
4
|
+
"version": "2.3.0",
|
5
5
|
"type": "module",
|
6
6
|
"main": "dist/country-select.js",
|
7
7
|
"types": "dist/index.d.ts",
|
@@ -18,7 +18,7 @@
|
|
18
18
|
"build": "tsc && vite build"
|
19
19
|
},
|
20
20
|
"dependencies": {
|
21
|
-
"@snmt-react-ui/city-select": "^2.
|
21
|
+
"@snmt-react-ui/city-select": "^2.3.0",
|
22
22
|
"@snmt-react-ui/core": "^2.1.0",
|
23
23
|
"@snmt-react-ui/flex": "^1.5.0",
|
24
24
|
"i18next": "^23.11.5",
|
@@ -27,5 +27,5 @@
|
|
27
27
|
"peerDependencies": {
|
28
28
|
"antd": "^5.18.3"
|
29
29
|
},
|
30
|
-
"gitHead": "
|
30
|
+
"gitHead": "1c62f906731e5202b370cd64a425b97b796e3f47"
|
31
31
|
}
|