react-better-html 1.1.169 → 1.1.171

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -1613,1774 +1613,54 @@ var appConfig = {
1613
1613
  };
1614
1614
  var defaultAlertDuration = 2.3 * 1e3;
1615
1615
 
1616
- // src/utils/functions.ts
1617
- var import_crypto_js = __toESM(require("crypto-js"));
1616
+ // src/components/alerts/AlertsHolder.tsx
1617
+ var import_react8 = require("react");
1618
1618
 
1619
- // src/constants/countries.ts
1620
- var countries = [
1621
- {
1622
- name: "Afghanistan",
1623
- code: "AF",
1624
- timeZone: "Asia/Kabul",
1625
- phoneNumberExtension: "93"
1626
- },
1627
- {
1628
- name: "\xC5land Islands",
1629
- code: "AX",
1630
- timeZone: "Europe/Mariehamn",
1631
- phoneNumberExtension: "358"
1632
- },
1633
- {
1634
- name: "Albania",
1635
- code: "AL",
1636
- timeZone: "Europe/Tirane",
1637
- phoneNumberExtension: "355"
1638
- },
1639
- {
1640
- name: "Algeria",
1641
- code: "DZ",
1642
- timeZone: "Africa/Algiers",
1643
- phoneNumberExtension: "213"
1644
- },
1645
- {
1646
- name: "United States of America",
1647
- code: "US",
1648
- timeZone: "America/New_York",
1649
- phoneNumberExtension: "1",
1650
- phoneNumberFormat: "(XXX)XXX-XXXX"
1651
- },
1652
- {
1653
- name: "American Samoa",
1654
- code: "AS",
1655
- timeZone: "Pacific/Pago_Pago",
1656
- phoneNumberExtension: "1",
1657
- phoneNumberFormat: "(XXX)XXX-XXXX"
1658
- },
1659
- {
1660
- name: "Andorra",
1661
- code: "AD",
1662
- timeZone: "Europe/Andorra",
1663
- phoneNumberExtension: "376"
1664
- },
1665
- {
1666
- name: "Angola",
1667
- code: "AO",
1668
- timeZone: "Africa/Luanda",
1669
- phoneNumberExtension: "244"
1670
- },
1671
- {
1672
- name: "Anguilla",
1673
- code: "AI",
1674
- timeZone: "America/Anguilla",
1675
- phoneNumberExtension: "1",
1676
- phoneNumberFormat: "(XXX)XXX-XXXX"
1677
- },
1678
- {
1679
- name: "Antarctica",
1680
- code: "AQ",
1681
- timeZone: "Antarctica/Casey",
1682
- phoneNumberExtension: "672"
1683
- },
1684
- {
1685
- name: "Antigua and Barbuda",
1686
- code: "AG",
1687
- timeZone: "America/Antigua",
1688
- phoneNumberExtension: "1",
1689
- phoneNumberFormat: "(XXX)XXX-XXXX"
1690
- },
1691
- {
1692
- name: "Argentina",
1693
- code: "AR",
1694
- timeZone: "America/Argentina/Buenos_Aires",
1695
- phoneNumberExtension: "54"
1696
- },
1697
- {
1698
- name: "Armenia",
1699
- code: "AM",
1700
- timeZone: "Asia/Yerevan",
1701
- phoneNumberExtension: "374"
1702
- },
1703
- {
1704
- name: "Aruba",
1705
- code: "AW",
1706
- timeZone: "America/Aruba",
1707
- phoneNumberExtension: "297"
1708
- },
1709
- {
1710
- name: "Australia",
1711
- code: "AU",
1712
- timeZone: "Australia/Sydney",
1713
- phoneNumberExtension: "61"
1714
- },
1715
- {
1716
- name: "Austria",
1717
- code: "AT",
1718
- timeZone: "Europe/Vienna",
1719
- phoneNumberExtension: "43"
1720
- },
1721
- {
1722
- name: "Azerbaijan",
1723
- code: "AZ",
1724
- timeZone: "Asia/Baku",
1725
- phoneNumberExtension: "994"
1726
- },
1727
- {
1728
- name: "Bahamas",
1729
- code: "BS",
1730
- timeZone: "America/Nassau",
1731
- phoneNumberExtension: "1",
1732
- phoneNumberFormat: "(XXX)XXX-XXXX"
1733
- },
1734
- {
1735
- name: "Bahrain",
1736
- code: "BH",
1737
- timeZone: "Asia/Bahrain",
1738
- phoneNumberExtension: "973"
1739
- },
1740
- {
1741
- name: "Bangladesh",
1742
- code: "BD",
1743
- timeZone: "Asia/Dhaka",
1744
- phoneNumberExtension: "880"
1745
- },
1746
- {
1747
- name: "Barbados",
1748
- code: "BB",
1749
- timeZone: "America/Barbados",
1750
- phoneNumberExtension: "1",
1751
- phoneNumberFormat: "(XXX)XXX-XXXX"
1752
- },
1753
- {
1754
- name: "Belarus",
1755
- code: "BY",
1756
- timeZone: "Europe/Minsk",
1757
- phoneNumberExtension: "375"
1758
- },
1759
- {
1760
- name: "Belgium",
1761
- code: "BE",
1762
- timeZone: "Europe/Brussels",
1763
- phoneNumberExtension: "32"
1764
- },
1765
- {
1766
- name: "Belize",
1767
- code: "BZ",
1768
- timeZone: "America/Belize",
1769
- phoneNumberExtension: "501"
1770
- },
1771
- {
1772
- name: "Benin",
1773
- code: "BJ",
1774
- timeZone: "Africa/Porto-Novo",
1775
- phoneNumberExtension: "229"
1776
- },
1777
- {
1778
- name: "Bermuda",
1779
- code: "BM",
1780
- timeZone: "Atlantic/Bermuda",
1781
- phoneNumberExtension: "1",
1782
- phoneNumberFormat: "(XXX)XXX-XXXX"
1783
- },
1784
- {
1785
- name: "Bhutan",
1786
- code: "BT",
1787
- timeZone: "Asia/Thimphu",
1788
- phoneNumberExtension: "975"
1789
- },
1790
- {
1791
- name: "Bolivia",
1792
- code: "BO",
1793
- timeZone: "America/La_Paz",
1794
- phoneNumberExtension: "591"
1795
- },
1796
- {
1797
- name: "Bosnia and Herzegovina",
1798
- code: "BA",
1799
- timeZone: "Europe/Sarajevo",
1800
- phoneNumberExtension: "387"
1801
- },
1802
- {
1803
- name: "Botswana",
1804
- code: "BW",
1805
- timeZone: "Africa/Gaborone",
1806
- phoneNumberExtension: "267"
1807
- },
1808
- {
1809
- name: "Bouvet Island",
1810
- code: "BV",
1811
- timeZone: "Europe/Oslo",
1812
- phoneNumberExtension: "47"
1619
+ // src/components/alerts/Alert.tsx
1620
+ var import_react7 = require("react");
1621
+ var import_styled_components6 = __toESM(require("styled-components"));
1622
+
1623
+ // src/plugins/alerts.ts
1624
+ var defaultAlertsPluginOptions = {
1625
+ position: "bottom",
1626
+ align: "right",
1627
+ defaultDuration: "auto",
1628
+ maxWidth: 460,
1629
+ withLoaderBar: true,
1630
+ withCloseButton: true
1631
+ };
1632
+ var alertsPlugin = (options) => ({
1633
+ name: "alerts",
1634
+ initialize: () => {
1635
+ console.log("alerts plugin initialized");
1813
1636
  },
1814
- {
1815
- name: "Brazil",
1816
- code: "BR",
1817
- timeZone: "America/Sao_Paulo",
1818
- phoneNumberExtension: "55"
1637
+ getConfig: () => ({
1638
+ ...defaultAlertsPluginOptions,
1639
+ ...options
1640
+ })
1641
+ });
1642
+
1643
+ // src/plugins/reactRouterDom.ts
1644
+ var defaultReactRouterDomPluginOptions = {};
1645
+ var reactRouterDomPlugin = (options) => ({
1646
+ name: "react-router-dom",
1647
+ initialize: () => {
1648
+ console.log("react-router-dom plugin initialized");
1819
1649
  },
1820
- {
1821
- name: "British Indian Ocean Territory",
1822
- code: "IO",
1823
- timeZone: "Indian/Chagos",
1824
- phoneNumberExtension: "246"
1825
- },
1826
- {
1827
- name: "Brunei Darussalam",
1828
- code: "BN",
1829
- timeZone: "Asia/Brunei",
1830
- phoneNumberExtension: "673"
1831
- },
1832
- {
1833
- name: "Bulgaria",
1834
- code: "BG",
1835
- timeZone: "Europe/Sofia",
1836
- phoneNumberExtension: "359",
1837
- phoneNumberFormat: "XX XXX XXXX"
1838
- },
1839
- {
1840
- name: "Burkina Faso",
1841
- code: "BF",
1842
- timeZone: "Africa/Ouagadougou",
1843
- phoneNumberExtension: "226"
1844
- },
1845
- {
1846
- name: "Burundi",
1847
- code: "BI",
1848
- timeZone: "Africa/Bujumbura",
1849
- phoneNumberExtension: "257"
1850
- },
1851
- {
1852
- name: "Cambodia",
1853
- code: "KH",
1854
- timeZone: "Asia/Phnom_Penh",
1855
- phoneNumberExtension: "855"
1856
- },
1857
- {
1858
- name: "Cameroon",
1859
- code: "CM",
1860
- timeZone: "Africa/Douala",
1861
- phoneNumberExtension: "237"
1862
- },
1863
- {
1864
- name: "Canada",
1865
- code: "CA",
1866
- timeZone: "America/Toronto",
1867
- phoneNumberExtension: "1",
1868
- phoneNumberFormat: "(XXX)XXX-XXXX"
1869
- },
1870
- {
1871
- name: "Cape Verde",
1872
- code: "CV",
1873
- timeZone: "Atlantic/Cape_Verde",
1874
- phoneNumberExtension: "238"
1875
- },
1876
- {
1877
- name: "Cayman Islands",
1878
- code: "KY",
1879
- timeZone: "America/Cayman",
1880
- phoneNumberExtension: "1",
1881
- phoneNumberFormat: "(XXX)XXX-XXXX"
1882
- },
1883
- {
1884
- name: "Central African Republic",
1885
- code: "CF",
1886
- timeZone: "Africa/Bangui",
1887
- phoneNumberExtension: "236"
1888
- },
1889
- {
1890
- name: "Chad",
1891
- code: "TD",
1892
- timeZone: "Africa/Ndjamena",
1893
- phoneNumberExtension: "235"
1894
- },
1895
- {
1896
- name: "Chile",
1897
- code: "CL",
1898
- timeZone: "America/Santiago",
1899
- phoneNumberExtension: "56"
1900
- },
1901
- {
1902
- name: "China",
1903
- code: "CN",
1904
- timeZone: "Asia/Shanghai",
1905
- phoneNumberExtension: "86"
1906
- },
1907
- {
1908
- name: "Christmas Island",
1909
- code: "CX",
1910
- timeZone: "Indian/Christmas",
1911
- phoneNumberExtension: "61"
1912
- },
1913
- {
1914
- name: "Cocos (Keeling) Islands",
1915
- code: "CC",
1916
- timeZone: "Indian/Cocos",
1917
- phoneNumberExtension: "61"
1918
- },
1919
- {
1920
- name: "Colombia",
1921
- code: "CO",
1922
- timeZone: "America/Bogota",
1923
- phoneNumberExtension: "57"
1924
- },
1925
- {
1926
- name: "Comoros",
1927
- code: "KM",
1928
- timeZone: "Indian/Comoro",
1929
- phoneNumberExtension: "269"
1930
- },
1931
- {
1932
- name: "Congo",
1933
- code: "CG",
1934
- timeZone: "Africa/Brazzaville",
1935
- phoneNumberExtension: "242"
1936
- },
1937
- {
1938
- name: "Congo, The Democratic Republic of the",
1939
- code: "CD",
1940
- timeZone: "Africa/Kinshasa",
1941
- phoneNumberExtension: "243"
1942
- },
1943
- {
1944
- name: "Cook Islands",
1945
- code: "CK",
1946
- timeZone: "Pacific/Rarotonga",
1947
- phoneNumberExtension: "682"
1948
- },
1949
- {
1950
- name: "Costa Rica",
1951
- code: "CR",
1952
- timeZone: "America/Costa_Rica",
1953
- phoneNumberExtension: "506"
1954
- },
1955
- {
1956
- name: "Cote D'Ivoire",
1957
- code: "CI",
1958
- timeZone: "Africa/Abidjan",
1959
- phoneNumberExtension: "225"
1960
- },
1961
- {
1962
- name: "Croatia",
1963
- code: "HR",
1964
- timeZone: "Europe/Zagreb",
1965
- phoneNumberExtension: "385"
1966
- },
1967
- {
1968
- name: "Cuba",
1969
- code: "CU",
1970
- timeZone: "America/Havana",
1971
- phoneNumberExtension: "53"
1972
- },
1973
- {
1974
- name: "Cyprus",
1975
- code: "CY",
1976
- timeZone: "Asia/Nicosia",
1977
- phoneNumberExtension: "357"
1978
- },
1979
- {
1980
- name: "Czech Republic",
1981
- code: "CZ",
1982
- timeZone: "Europe/Prague",
1983
- phoneNumberExtension: "420"
1984
- },
1985
- {
1986
- name: "Denmark",
1987
- code: "DK",
1988
- timeZone: "Europe/Copenhagen",
1989
- phoneNumberExtension: "45"
1990
- },
1991
- {
1992
- name: "Djibouti",
1993
- code: "DJ",
1994
- timeZone: "Africa/Djibouti",
1995
- phoneNumberExtension: "253"
1996
- },
1997
- {
1998
- name: "Dominica",
1999
- code: "DM",
2000
- timeZone: "America/Dominica",
2001
- phoneNumberExtension: "1",
2002
- phoneNumberFormat: "(XXX)XXX-XXXX"
2003
- },
2004
- {
2005
- name: "Dominican Republic",
2006
- code: "DO",
2007
- timeZone: "America/Santo_Domingo",
2008
- phoneNumberExtension: "1",
2009
- phoneNumberFormat: "(XXX)XXX-XXXX"
2010
- },
2011
- {
2012
- name: "Ecuador",
2013
- code: "EC",
2014
- timeZone: "America/Guayaquil",
2015
- phoneNumberExtension: "593"
2016
- },
2017
- {
2018
- name: "Egypt",
2019
- code: "EG",
2020
- timeZone: "Africa/Cairo",
2021
- phoneNumberExtension: "20"
2022
- },
2023
- {
2024
- name: "El Salvador",
2025
- code: "SV",
2026
- timeZone: "America/El_Salvador",
2027
- phoneNumberExtension: "503"
2028
- },
2029
- {
2030
- name: "Equatorial Guinea",
2031
- code: "GQ",
2032
- timeZone: "Africa/Malabo",
2033
- phoneNumberExtension: "240"
2034
- },
2035
- {
2036
- name: "Eritrea",
2037
- code: "ER",
2038
- timeZone: "Africa/Asmara",
2039
- phoneNumberExtension: "291"
2040
- },
2041
- {
2042
- name: "Estonia",
2043
- code: "EE",
2044
- timeZone: "Europe/Tallinn",
2045
- phoneNumberExtension: "372"
2046
- },
2047
- {
2048
- name: "Ethiopia",
2049
- code: "ET",
2050
- timeZone: "Africa/Addis_Ababa",
2051
- phoneNumberExtension: "251"
2052
- },
2053
- {
2054
- name: "Falkland Islands (Malvinas)",
2055
- code: "FK",
2056
- timeZone: "Atlantic/Stanley",
2057
- phoneNumberExtension: "500"
2058
- },
2059
- {
2060
- name: "Faroe Islands",
2061
- code: "FO",
2062
- timeZone: "Atlantic/Faroe",
2063
- phoneNumberExtension: "298"
2064
- },
2065
- {
2066
- name: "Fiji",
2067
- code: "FJ",
2068
- timeZone: "Pacific/Fiji",
2069
- phoneNumberExtension: "679"
2070
- },
2071
- {
2072
- name: "Finland",
2073
- code: "FI",
2074
- timeZone: "Europe/Helsinki",
2075
- phoneNumberExtension: "358",
2076
- phoneNumberFormat: "XX XXX XX XX"
2077
- },
2078
- {
2079
- name: "France",
2080
- code: "FR",
2081
- timeZone: "Europe/Paris",
2082
- phoneNumberExtension: "33",
2083
- phoneNumberFormat: "X XX XX XX XX"
2084
- },
2085
- {
2086
- name: "French Guiana",
2087
- code: "GF",
2088
- timeZone: "America/Cayenne",
2089
- phoneNumberExtension: "594"
2090
- },
2091
- {
2092
- name: "French Polynesia",
2093
- code: "PF",
2094
- timeZone: "Pacific/Tahiti",
2095
- phoneNumberExtension: "689"
2096
- },
2097
- {
2098
- name: "French Southern Territories",
2099
- code: "TF",
2100
- timeZone: "Indian/Kerguelen",
2101
- phoneNumberExtension: "262"
2102
- },
2103
- {
2104
- name: "Gabon",
2105
- code: "GA",
2106
- timeZone: "Africa/Libreville",
2107
- phoneNumberExtension: "241"
2108
- },
2109
- {
2110
- name: "Gambia",
2111
- code: "GM",
2112
- timeZone: "Africa/Banjul",
2113
- phoneNumberExtension: "220"
2114
- },
2115
- {
2116
- name: "Georgia",
2117
- code: "GE",
2118
- timeZone: "Asia/Tbilisi",
2119
- phoneNumberExtension: "995"
2120
- },
2121
- {
2122
- name: "Germany",
2123
- code: "DE",
2124
- timeZone: "Europe/Berlin",
2125
- phoneNumberExtension: "49",
2126
- phoneNumberFormat: "XXXX XXXXXXX"
2127
- },
2128
- {
2129
- name: "Ghana",
2130
- code: "GH",
2131
- timeZone: "Africa/Accra",
2132
- phoneNumberExtension: "233"
2133
- },
2134
- {
2135
- name: "Gibraltar",
2136
- code: "GI",
2137
- timeZone: "Europe/Gibraltar",
2138
- phoneNumberExtension: "350"
2139
- },
2140
- {
2141
- name: "Greece",
2142
- code: "GR",
2143
- timeZone: "Europe/Athens",
2144
- phoneNumberExtension: "30"
2145
- },
2146
- {
2147
- name: "Greenland",
2148
- code: "GL",
2149
- timeZone: "America/Godthab",
2150
- phoneNumberExtension: "299"
2151
- },
2152
- {
2153
- name: "Grenada",
2154
- code: "GD",
2155
- timeZone: "America/Grenada",
2156
- phoneNumberExtension: "1",
2157
- phoneNumberFormat: "(XXX)XXX-XXXX"
2158
- },
2159
- {
2160
- name: "Guadeloupe",
2161
- code: "GP",
2162
- timeZone: "America/Guadeloupe",
2163
- phoneNumberExtension: "590"
2164
- },
2165
- {
2166
- name: "Guam",
2167
- code: "GU",
2168
- timeZone: "Pacific/Guam",
2169
- phoneNumberExtension: "1",
2170
- phoneNumberFormat: "(XXX)XXX-XXXX"
2171
- },
2172
- {
2173
- name: "Guatemala",
2174
- code: "GT",
2175
- timeZone: "America/Guatemala",
2176
- phoneNumberExtension: "502"
2177
- },
2178
- {
2179
- name: "United Kingdom",
2180
- code: "GB",
2181
- timeZone: "Europe/London",
2182
- phoneNumberExtension: "44",
2183
- phoneNumberFormat: "XX XXXX XXXX"
2184
- },
2185
- {
2186
- name: "Guernsey",
2187
- code: "GG",
2188
- timeZone: "Europe/Guernsey",
2189
- phoneNumberExtension: "44",
2190
- phoneNumberFormat: "XX XXXX XXXX"
2191
- },
2192
- {
2193
- name: "Guinea",
2194
- code: "GN",
2195
- timeZone: "Africa/Conakry",
2196
- phoneNumberExtension: "224"
2197
- },
2198
- {
2199
- name: "Guinea-Bissau",
2200
- code: "GW",
2201
- timeZone: "Africa/Bissau",
2202
- phoneNumberExtension: "245"
2203
- },
2204
- {
2205
- name: "Guyana",
2206
- code: "GY",
2207
- timeZone: "America/Guyana",
2208
- phoneNumberExtension: "592"
2209
- },
2210
- {
2211
- name: "Haiti",
2212
- code: "HT",
2213
- timeZone: "America/Port-au-Prince",
2214
- phoneNumberExtension: "509"
2215
- },
2216
- {
2217
- name: "Heard Island and Mcdonald Islands",
2218
- code: "HM",
2219
- timeZone: "Indian/Kerguelen",
2220
- phoneNumberExtension: "672"
2221
- },
2222
- {
2223
- name: "Holy See (Vatican City State)",
2224
- code: "VA",
2225
- timeZone: "Europe/Vatican",
2226
- phoneNumberExtension: "379"
2227
- },
2228
- {
2229
- name: "Honduras",
2230
- code: "HN",
2231
- timeZone: "America/Tegucigalpa",
2232
- phoneNumberExtension: "504"
2233
- },
2234
- {
2235
- name: "Hong Kong",
2236
- code: "HK",
2237
- timeZone: "Asia/Hong_Kong",
2238
- phoneNumberExtension: "852"
2239
- },
2240
- {
2241
- name: "Hungary",
2242
- code: "HU",
2243
- timeZone: "Europe/Budapest",
2244
- phoneNumberExtension: "36"
2245
- },
2246
- {
2247
- name: "Iceland",
2248
- code: "IS",
2249
- timeZone: "Atlantic/Reykjavik",
2250
- phoneNumberExtension: "354"
2251
- },
2252
- {
2253
- name: "India",
2254
- code: "IN",
2255
- timeZone: "Asia/Kolkata",
2256
- phoneNumberExtension: "91"
2257
- },
2258
- {
2259
- name: "Indonesia",
2260
- code: "ID",
2261
- timeZone: "Asia/Jakarta",
2262
- phoneNumberExtension: "62"
2263
- },
2264
- {
2265
- name: "Iran, Islamic Republic Of",
2266
- code: "IR",
2267
- timeZone: "Asia/Tehran",
2268
- phoneNumberExtension: "98"
2269
- },
2270
- {
2271
- name: "Iraq",
2272
- code: "IQ",
2273
- timeZone: "Asia/Baghdad",
2274
- phoneNumberExtension: "964"
2275
- },
2276
- {
2277
- name: "Ireland",
2278
- code: "IE",
2279
- timeZone: "Europe/Dublin",
2280
- phoneNumberExtension: "353"
2281
- },
2282
- {
2283
- name: "Israel",
2284
- code: "IL",
2285
- timeZone: "Asia/Jerusalem",
2286
- phoneNumberExtension: "972"
2287
- },
2288
- {
2289
- name: "Italy",
2290
- code: "IT",
2291
- timeZone: "Europe/Rome",
2292
- phoneNumberExtension: "39",
2293
- phoneNumberFormat: "XXX XXX XXXX"
2294
- },
2295
- {
2296
- name: "Jamaica",
2297
- code: "JM",
2298
- timeZone: "America/Jamaica",
2299
- phoneNumberExtension: "1",
2300
- phoneNumberFormat: "(XXX)XXX-XXXX"
2301
- },
2302
- {
2303
- name: "Japan",
2304
- code: "JP",
2305
- timeZone: "Asia/Tokyo",
2306
- phoneNumberExtension: "81"
2307
- },
2308
- {
2309
- name: "Jersey",
2310
- code: "JE",
2311
- timeZone: "Europe/Jersey",
2312
- phoneNumberExtension: "44",
2313
- phoneNumberFormat: "XX XXXX XXXX"
2314
- },
2315
- {
2316
- name: "Jordan",
2317
- code: "JO",
2318
- timeZone: "Asia/Amman",
2319
- phoneNumberExtension: "962"
2320
- },
2321
- {
2322
- name: "Kazakhstan",
2323
- code: "KZ",
2324
- timeZone: "Asia/Almaty",
2325
- phoneNumberExtension: "7"
2326
- },
2327
- {
2328
- name: "Kenya",
2329
- code: "KE",
2330
- timeZone: "Africa/Nairobi",
2331
- phoneNumberExtension: "254"
2332
- },
2333
- {
2334
- name: "Kiribati",
2335
- code: "KI",
2336
- timeZone: "Pacific/Tarawa",
2337
- phoneNumberExtension: "686"
2338
- },
2339
- {
2340
- name: "Korea, Democratic People's Republic of (North Korea)",
2341
- code: "KP",
2342
- timeZone: "Asia/Pyongyang",
2343
- phoneNumberExtension: "850"
2344
- },
2345
- {
2346
- name: "Korea, Republic of (South Korea)",
2347
- code: "KR",
2348
- timeZone: "Asia/Seoul",
2349
- phoneNumberExtension: "82"
2350
- },
2351
- {
2352
- name: "Kuwait",
2353
- code: "KW",
2354
- timeZone: "Asia/Kuwait",
2355
- phoneNumberExtension: "965"
2356
- },
2357
- {
2358
- name: "Kyrgyzstan",
2359
- code: "KG",
2360
- timeZone: "Asia/Bishkek",
2361
- phoneNumberExtension: "996"
2362
- },
2363
- {
2364
- name: "Lao People's Democratic Republic",
2365
- code: "LA",
2366
- timeZone: "Asia/Vientiane",
2367
- phoneNumberExtension: "856"
2368
- },
2369
- {
2370
- name: "Latvia",
2371
- code: "LV",
2372
- timeZone: "Europe/Riga",
2373
- phoneNumberExtension: "371"
2374
- },
2375
- {
2376
- name: "Lebanon",
2377
- code: "LB",
2378
- timeZone: "Asia/Beirut",
2379
- phoneNumberExtension: "961"
2380
- },
2381
- {
2382
- name: "Lesotho",
2383
- code: "LS",
2384
- timeZone: "Africa/Maseru",
2385
- phoneNumberExtension: "266"
2386
- },
2387
- {
2388
- name: "Liberia",
2389
- code: "LR",
2390
- timeZone: "Africa/Monrovia",
2391
- phoneNumberExtension: "231"
2392
- },
2393
- {
2394
- name: "Libyan Arab Jamahiriya",
2395
- code: "LY",
2396
- timeZone: "Africa/Tripoli",
2397
- phoneNumberExtension: "218"
2398
- },
2399
- {
2400
- name: "Liechtenstein",
2401
- code: "LI",
2402
- timeZone: "Europe/Vaduz",
2403
- phoneNumberExtension: "423"
2404
- },
2405
- {
2406
- name: "Lithuania",
2407
- code: "LT",
2408
- timeZone: "Europe/Vilnius",
2409
- phoneNumberExtension: "370"
2410
- },
2411
- {
2412
- name: "Luxembourg",
2413
- code: "LU",
2414
- timeZone: "Europe/Luxembourg",
2415
- phoneNumberExtension: "352"
2416
- },
2417
- {
2418
- name: "Macao",
2419
- code: "MO",
2420
- timeZone: "Asia/Macau",
2421
- phoneNumberExtension: "853"
2422
- },
2423
- {
2424
- name: "Macedonia, The Former Yugoslav Republic of",
2425
- code: "MK",
2426
- timeZone: "Europe/Skopje",
2427
- phoneNumberExtension: "389"
2428
- },
2429
- {
2430
- name: "Madagascar",
2431
- code: "MG",
2432
- timeZone: "Indian/Antananarivo",
2433
- phoneNumberExtension: "261"
2434
- },
2435
- {
2436
- name: "Malawi",
2437
- code: "MW",
2438
- timeZone: "Africa/Blantyre",
2439
- phoneNumberExtension: "265"
2440
- },
2441
- {
2442
- name: "Malaysia",
2443
- code: "MY",
2444
- timeZone: "Asia/Kuala_Lumpur",
2445
- phoneNumberExtension: "60"
2446
- },
2447
- {
2448
- name: "Maldives",
2449
- code: "MV",
2450
- timeZone: "Indian/Maldives",
2451
- phoneNumberExtension: "960"
2452
- },
2453
- {
2454
- name: "Mali",
2455
- code: "ML",
2456
- timeZone: "Africa/Bamako",
2457
- phoneNumberExtension: "223"
2458
- },
2459
- {
2460
- name: "Malta",
2461
- code: "MT",
2462
- timeZone: "Europe/Malta",
2463
- phoneNumberExtension: "356"
2464
- },
2465
- {
2466
- name: "Marshall Islands",
2467
- code: "MH",
2468
- timeZone: "Pacific/Majuro",
2469
- phoneNumberExtension: "692"
2470
- },
2471
- {
2472
- name: "Martinique",
2473
- code: "MQ",
2474
- timeZone: "America/Martinique",
2475
- phoneNumberExtension: "596"
2476
- },
2477
- {
2478
- name: "Mauritania",
2479
- code: "MR",
2480
- timeZone: "Africa/Nouakchott",
2481
- phoneNumberExtension: "222"
2482
- },
2483
- {
2484
- name: "Mauritius",
2485
- code: "MU",
2486
- timeZone: "Indian/Mauritius",
2487
- phoneNumberExtension: "230"
2488
- },
2489
- {
2490
- name: "Mayotte",
2491
- code: "YT",
2492
- timeZone: "Indian/Mayotte",
2493
- phoneNumberExtension: "262"
2494
- },
2495
- {
2496
- name: "Mexico",
2497
- code: "MX",
2498
- timeZone: "America/Mexico_City",
2499
- phoneNumberExtension: "52"
2500
- },
2501
- {
2502
- name: "Micronesia, Federated States of",
2503
- code: "FM",
2504
- timeZone: "Pacific/Chuuk",
2505
- phoneNumberExtension: "691"
2506
- },
2507
- {
2508
- name: "Moldova, Republic of",
2509
- code: "MD",
2510
- timeZone: "Europe/Chisinau",
2511
- phoneNumberExtension: "373"
2512
- },
2513
- {
2514
- name: "Monaco",
2515
- code: "MC",
2516
- timeZone: "Europe/Monaco",
2517
- phoneNumberExtension: "377"
2518
- },
2519
- {
2520
- name: "Mongolia",
2521
- code: "MN",
2522
- timeZone: "Asia/Ulaanbaatar",
2523
- phoneNumberExtension: "976"
2524
- },
2525
- {
2526
- name: "Montserrat",
2527
- code: "MS",
2528
- timeZone: "America/Montserrat",
2529
- phoneNumberExtension: "1",
2530
- phoneNumberFormat: "(XXX)XXX-XXXX"
2531
- },
2532
- {
2533
- name: "Morocco",
2534
- code: "MA",
2535
- timeZone: "Africa/Casablanca",
2536
- phoneNumberExtension: "212"
2537
- },
2538
- {
2539
- name: "Mozambique",
2540
- code: "MZ",
2541
- timeZone: "Africa/Maputo",
2542
- phoneNumberExtension: "258"
2543
- },
2544
- {
2545
- name: "Myanmar",
2546
- code: "MM",
2547
- timeZone: "Asia/Yangon",
2548
- phoneNumberExtension: "95"
2549
- },
2550
- {
2551
- name: "Namibia",
2552
- code: "NA",
2553
- timeZone: "Africa/Windhoek",
2554
- phoneNumberExtension: "264"
2555
- },
2556
- {
2557
- name: "Nauru",
2558
- code: "NR",
2559
- timeZone: "Pacific/Nauru",
2560
- phoneNumberExtension: "674"
2561
- },
2562
- {
2563
- name: "Nepal",
2564
- code: "NP",
2565
- timeZone: "Asia/Kathmandu",
2566
- phoneNumberExtension: "977"
2567
- },
2568
- {
2569
- name: "Netherlands",
2570
- code: "NL",
2571
- timeZone: "Europe/Amsterdam",
2572
- phoneNumberExtension: "31"
2573
- },
2574
- {
2575
- name: "New Caledonia",
2576
- code: "NC",
2577
- timeZone: "Pacific/Noumea",
2578
- phoneNumberExtension: "687"
2579
- },
2580
- {
2581
- name: "New Zealand",
2582
- code: "NZ",
2583
- timeZone: "Pacific/Auckland",
2584
- phoneNumberExtension: "64"
2585
- },
2586
- {
2587
- name: "Nicaragua",
2588
- code: "NI",
2589
- timeZone: "America/Managua",
2590
- phoneNumberExtension: "505"
2591
- },
2592
- {
2593
- name: "Niger",
2594
- code: "NE",
2595
- timeZone: "Africa/Niamey",
2596
- phoneNumberExtension: "227"
2597
- },
2598
- {
2599
- name: "Nigeria",
2600
- code: "NG",
2601
- timeZone: "Africa/Lagos",
2602
- phoneNumberExtension: "234"
2603
- },
2604
- {
2605
- name: "Niue",
2606
- code: "NU",
2607
- timeZone: "Pacific/Niue",
2608
- phoneNumberExtension: "683"
2609
- },
2610
- {
2611
- name: "Norfolk Island",
2612
- code: "NF",
2613
- timeZone: "Pacific/Norfolk",
2614
- phoneNumberExtension: "672"
2615
- },
2616
- {
2617
- name: "Northern Mariana Islands",
2618
- code: "MP",
2619
- timeZone: "Pacific/Saipan",
2620
- phoneNumberExtension: "1",
2621
- phoneNumberFormat: "(XXX)XXX-XXXX"
2622
- },
2623
- {
2624
- name: "Norway",
2625
- code: "NO",
2626
- timeZone: "Europe/Oslo",
2627
- phoneNumberExtension: "47"
2628
- },
2629
- {
2630
- name: "Oman",
2631
- code: "OM",
2632
- timeZone: "Asia/Muscat",
2633
- phoneNumberExtension: "968"
2634
- },
2635
- {
2636
- name: "Pakistan",
2637
- code: "PK",
2638
- timeZone: "Asia/Karachi",
2639
- phoneNumberExtension: "92"
2640
- },
2641
- {
2642
- name: "Palau",
2643
- code: "PW",
2644
- timeZone: "Pacific/Palau",
2645
- phoneNumberExtension: "680"
2646
- },
2647
- {
2648
- name: "Palestinian Territory, Occupied",
2649
- code: "PS",
2650
- timeZone: "Asia/Hebron",
2651
- phoneNumberExtension: "970"
2652
- },
2653
- {
2654
- name: "Panama",
2655
- code: "PA",
2656
- timeZone: "America/Panama",
2657
- phoneNumberExtension: "507"
2658
- },
2659
- {
2660
- name: "Papua New Guinea",
2661
- code: "PG",
2662
- timeZone: "Pacific/Port_Moresby",
2663
- phoneNumberExtension: "675"
2664
- },
2665
- {
2666
- name: "Paraguay",
2667
- code: "PY",
2668
- timeZone: "America/Asuncion",
2669
- phoneNumberExtension: "595"
2670
- },
2671
- {
2672
- name: "Peru",
2673
- code: "PE",
2674
- timeZone: "America/Lima",
2675
- phoneNumberExtension: "51"
2676
- },
2677
- {
2678
- name: "Philippines",
2679
- code: "PH",
2680
- timeZone: "Asia/Manila",
2681
- phoneNumberExtension: "63"
2682
- },
2683
- {
2684
- name: "Pitcairn",
2685
- code: "PN",
2686
- timeZone: "Pacific/Pitcairn",
2687
- phoneNumberExtension: "64"
2688
- },
2689
- {
2690
- name: "Poland",
2691
- code: "PL",
2692
- timeZone: "Europe/Warsaw",
2693
- phoneNumberExtension: "48"
2694
- },
2695
- {
2696
- name: "Portugal",
2697
- code: "PT",
2698
- timeZone: "Europe/Lisbon",
2699
- phoneNumberExtension: "351"
2700
- },
2701
- {
2702
- name: "Puerto Rico",
2703
- code: "PR",
2704
- timeZone: "America/Puerto_Rico",
2705
- phoneNumberExtension: "1",
2706
- phoneNumberFormat: "(XXX)XXX-XXXX"
2707
- },
2708
- {
2709
- name: "Qatar",
2710
- code: "QA",
2711
- timeZone: "Asia/Qatar",
2712
- phoneNumberExtension: "974"
2713
- },
2714
- {
2715
- name: "Reunion",
2716
- code: "RE",
2717
- timeZone: "Indian/Reunion",
2718
- phoneNumberExtension: "262"
2719
- },
2720
- {
2721
- name: "Romania",
2722
- code: "RO",
2723
- timeZone: "Europe/Bucharest",
2724
- phoneNumberExtension: "40"
2725
- },
2726
- {
2727
- name: "Russian Federation",
2728
- code: "RU",
2729
- timeZone: "Europe/Moscow",
2730
- phoneNumberExtension: "7"
2731
- },
2732
- {
2733
- name: "RWANDA",
2734
- code: "RW",
2735
- timeZone: "Africa/Kigali",
2736
- phoneNumberExtension: "250"
2737
- },
2738
- {
2739
- name: "Saint Helena",
2740
- code: "SH",
2741
- timeZone: "Atlantic/St_Helena",
2742
- phoneNumberExtension: "290"
2743
- },
2744
- {
2745
- name: "Saint Kitts and Nevis",
2746
- code: "KN",
2747
- timeZone: "America/St_Kitts",
2748
- phoneNumberExtension: "1",
2749
- phoneNumberFormat: "(XXX)XXX-XXXX"
2750
- },
2751
- {
2752
- name: "Saint Lucia",
2753
- code: "LC",
2754
- timeZone: "America/St_Lucia",
2755
- phoneNumberExtension: "1",
2756
- phoneNumberFormat: "(XXX)XXX-XXXX"
2757
- },
2758
- {
2759
- name: "Saint Pierre and Miquelon",
2760
- code: "PM",
2761
- timeZone: "America/Miquelon",
2762
- phoneNumberExtension: "508"
2763
- },
2764
- {
2765
- name: "Saint Vincent and the Grenadines",
2766
- code: "VC",
2767
- timeZone: "America/St_Vincent",
2768
- phoneNumberExtension: "1",
2769
- phoneNumberFormat: "(XXX)XXX-XXXX"
2770
- },
2771
- {
2772
- name: "Samoa",
2773
- code: "WS",
2774
- timeZone: "Pacific/Apia",
2775
- phoneNumberExtension: "685"
2776
- },
2777
- {
2778
- name: "San Marino",
2779
- code: "SM",
2780
- timeZone: "Europe/San_Marino",
2781
- phoneNumberExtension: "378"
2782
- },
2783
- {
2784
- name: "Sao Tome and Principe",
2785
- code: "ST",
2786
- timeZone: "Africa/Sao_Tome",
2787
- phoneNumberExtension: "239"
2788
- },
2789
- {
2790
- name: "Saudi Arabia",
2791
- code: "SA",
2792
- timeZone: "Asia/Riyadh",
2793
- phoneNumberExtension: "966"
2794
- },
2795
- {
2796
- name: "Senegal",
2797
- code: "SN",
2798
- timeZone: "Africa/Dakar",
2799
- phoneNumberExtension: "221"
2800
- },
2801
- {
2802
- name: "Republic of Serbia",
2803
- code: "RS",
2804
- timeZone: "Europe/Belgrade",
2805
- phoneNumberExtension: "381"
2806
- },
2807
- {
2808
- name: "Seychelles",
2809
- code: "SC",
2810
- timeZone: "Indian/Mahe",
2811
- phoneNumberExtension: "248"
2812
- },
2813
- {
2814
- name: "Sierra Leone",
2815
- code: "SL",
2816
- timeZone: "Africa/Freetown",
2817
- phoneNumberExtension: "232"
2818
- },
2819
- {
2820
- name: "Singapore",
2821
- code: "SG",
2822
- timeZone: "Asia/Singapore",
2823
- phoneNumberExtension: "65"
2824
- },
2825
- {
2826
- name: "Slovakia",
2827
- code: "SK",
2828
- timeZone: "Europe/Bratislava",
2829
- phoneNumberExtension: "421"
2830
- },
2831
- {
2832
- name: "Slovenia",
2833
- code: "SI",
2834
- timeZone: "Europe/Ljubljana",
2835
- phoneNumberExtension: "386"
2836
- },
2837
- {
2838
- name: "Solomon Islands",
2839
- code: "SB",
2840
- timeZone: "Pacific/Guadalcanal",
2841
- phoneNumberExtension: "677"
2842
- },
2843
- {
2844
- name: "Somalia",
2845
- code: "SO",
2846
- timeZone: "Africa/Mogadishu",
2847
- phoneNumberExtension: "252"
2848
- },
2849
- {
2850
- name: "South Africa",
2851
- code: "ZA",
2852
- timeZone: "Africa/Johannesburg",
2853
- phoneNumberExtension: "27"
2854
- },
2855
- {
2856
- name: "South Georgia and the South Sandwich Islands",
2857
- code: "GS",
2858
- timeZone: "Atlantic/South_Georgia",
2859
- phoneNumberExtension: "500"
2860
- },
2861
- {
2862
- name: "Spain",
2863
- code: "ES",
2864
- timeZone: "Europe/Madrid",
2865
- phoneNumberExtension: "34"
2866
- },
2867
- {
2868
- name: "Sri Lanka",
2869
- code: "LK",
2870
- timeZone: "Asia/Colombo",
2871
- phoneNumberExtension: "94"
2872
- },
2873
- {
2874
- name: "Sudan",
2875
- code: "SD",
2876
- timeZone: "Africa/Khartoum",
2877
- phoneNumberExtension: "249"
2878
- },
2879
- {
2880
- name: "Suriname",
2881
- code: "SR",
2882
- timeZone: "America/Paramaribo",
2883
- phoneNumberExtension: "597"
2884
- },
2885
- {
2886
- name: "Svalbard and Jan Mayen",
2887
- code: "SJ",
2888
- timeZone: "Arctic/Longyearbyen",
2889
- phoneNumberExtension: "47"
2890
- },
2891
- {
2892
- name: "Swaziland",
2893
- code: "SZ",
2894
- timeZone: "Africa/Mbabane",
2895
- phoneNumberExtension: "268"
2896
- },
2897
- {
2898
- name: "Sweden",
2899
- code: "SE",
2900
- timeZone: "Europe/Stockholm",
2901
- phoneNumberExtension: "46"
2902
- },
2903
- {
2904
- name: "Switzerland",
2905
- code: "CH",
2906
- timeZone: "Europe/Zurich",
2907
- phoneNumberExtension: "41"
2908
- },
2909
- {
2910
- name: "Syrian Arab Republic",
2911
- code: "SY",
2912
- timeZone: "Asia/Damascus",
2913
- phoneNumberExtension: "963"
2914
- },
2915
- {
2916
- name: "Taiwan, Province of China",
2917
- code: "TW",
2918
- timeZone: "Asia/Taipei",
2919
- phoneNumberExtension: "886"
2920
- },
2921
- {
2922
- name: "Tajikistan",
2923
- code: "TJ",
2924
- timeZone: "Asia/Dushanbe",
2925
- phoneNumberExtension: "992"
2926
- },
2927
- {
2928
- name: "Tanzania, United Republic of",
2929
- code: "TZ",
2930
- timeZone: "Africa/Dar_es_Salaam",
2931
- phoneNumberExtension: "255"
2932
- },
2933
- {
2934
- name: "Thailand",
2935
- code: "TH",
2936
- timeZone: "Asia/Bangkok",
2937
- phoneNumberExtension: "66"
2938
- },
2939
- {
2940
- name: "Timor-Leste",
2941
- code: "TL",
2942
- timeZone: "Asia/Dili",
2943
- phoneNumberExtension: "670"
2944
- },
2945
- {
2946
- name: "Togo",
2947
- code: "TG",
2948
- timeZone: "Africa/Lome",
2949
- phoneNumberExtension: "228"
2950
- },
2951
- {
2952
- name: "Tokelau",
2953
- code: "TK",
2954
- timeZone: "Pacific/Fakaofo",
2955
- phoneNumberExtension: "690"
2956
- },
2957
- {
2958
- name: "Tonga",
2959
- code: "TO",
2960
- timeZone: "Pacific/Tongatapu",
2961
- phoneNumberExtension: "676"
2962
- },
2963
- {
2964
- name: "Trinidad and Tobago",
2965
- code: "TT",
2966
- timeZone: "America/Port_of_Spain",
2967
- phoneNumberExtension: "1",
2968
- phoneNumberFormat: "(XXX)XXX-XXXX"
2969
- },
2970
- {
2971
- name: "Tunisia",
2972
- code: "TN",
2973
- timeZone: "Africa/Tunis",
2974
- phoneNumberExtension: "216"
2975
- },
2976
- {
2977
- name: "Turkey",
2978
- code: "TR",
2979
- timeZone: "Europe/Istanbul",
2980
- phoneNumberExtension: "90"
2981
- },
2982
- {
2983
- name: "Turkmenistan",
2984
- code: "TM",
2985
- timeZone: "Asia/Ashgabat",
2986
- phoneNumberExtension: "993"
2987
- },
2988
- {
2989
- name: "Turks and Caicos Islands",
2990
- code: "TC",
2991
- timeZone: "America/Grand_Turk",
2992
- phoneNumberExtension: "1",
2993
- phoneNumberFormat: "(XXX)XXX-XXXX"
2994
- },
2995
- {
2996
- name: "Tuvalu",
2997
- code: "TV",
2998
- timeZone: "Pacific/Funafuti",
2999
- phoneNumberExtension: "688"
3000
- },
3001
- {
3002
- name: "Uganda",
3003
- code: "UG",
3004
- timeZone: "Africa/Kampala",
3005
- phoneNumberExtension: "256"
3006
- },
3007
- {
3008
- name: "Ukraine",
3009
- code: "UA",
3010
- timeZone: "Europe/Kiev",
3011
- phoneNumberExtension: "380"
3012
- },
3013
- {
3014
- name: "United Arab Emirates",
3015
- code: "AE",
3016
- timeZone: "Asia/Dubai",
3017
- phoneNumberExtension: "971"
3018
- },
3019
- {
3020
- name: "United States Minor Outlying Islands",
3021
- code: "UM",
3022
- timeZone: "Pacific/Midway",
3023
- phoneNumberExtension: "1",
3024
- phoneNumberFormat: "(XXX)XXX-XXXX"
3025
- },
3026
- {
3027
- name: "Uruguay",
3028
- code: "UY",
3029
- timeZone: "America/Montevideo",
3030
- phoneNumberExtension: "598"
3031
- },
3032
- {
3033
- name: "Uzbekistan",
3034
- code: "UZ",
3035
- timeZone: "Asia/Tashkent",
3036
- phoneNumberExtension: "998"
3037
- },
3038
- {
3039
- name: "Vanuatu",
3040
- code: "VU",
3041
- timeZone: "Pacific/Efate",
3042
- phoneNumberExtension: "678"
3043
- },
3044
- {
3045
- name: "Venezuela",
3046
- code: "VE",
3047
- timeZone: "America/Caracas",
3048
- phoneNumberExtension: "58"
3049
- },
3050
- {
3051
- name: "Viet Nam",
3052
- code: "VN",
3053
- timeZone: "Asia/Ho_Chi_Minh",
3054
- phoneNumberExtension: "84"
3055
- },
3056
- {
3057
- name: "Virgin Islands, British",
3058
- code: "VG",
3059
- timeZone: "America/Tortola",
3060
- phoneNumberExtension: "1",
3061
- phoneNumberFormat: "(XXX)XXX-XXXX"
3062
- },
3063
- {
3064
- name: "Virgin Islands, U.S.",
3065
- code: "VI",
3066
- timeZone: "America/St_Thomas",
3067
- phoneNumberExtension: "1",
3068
- phoneNumberFormat: "(XXX)XXX-XXXX"
3069
- },
3070
- {
3071
- name: "Wallis and Futuna",
3072
- code: "WF",
3073
- timeZone: "Pacific/Wallis",
3074
- phoneNumberExtension: "681"
3075
- },
3076
- {
3077
- name: "Western Sahara",
3078
- code: "EH",
3079
- timeZone: "Africa/El_Aaiun",
3080
- phoneNumberExtension: "212"
3081
- },
3082
- {
3083
- name: "Yemen",
3084
- code: "YE",
3085
- timeZone: "Asia/Aden",
3086
- phoneNumberExtension: "967"
3087
- },
3088
- {
3089
- name: "Zambia",
3090
- code: "ZM",
3091
- timeZone: "Africa/Lusaka",
3092
- phoneNumberExtension: "260"
3093
- },
3094
- {
3095
- name: "Zimbabwe",
3096
- code: "ZW",
3097
- timeZone: "Africa/Harare",
3098
- phoneNumberExtension: "263"
3099
- }
3100
- ];
3101
-
3102
- // src/utils/variableFunctions.ts
3103
- var checkBetterHtmlContextValue = (value, functionsName) => {
3104
- if (value === void 0) {
3105
- throw new Error(
3106
- `\`${functionsName}()\` must be used within a \`<BetterHtmlProvider>\`. Make sure to add one at the root of your component tree.`
3107
- );
3108
- }
3109
- return value !== void 0;
3110
- };
3111
- var loaderControls = {
3112
- startLoading: (loaderName) => {
3113
- if (!checkBetterHtmlContextValue(externalBetterHtmlContextValue, "loaderControls.startLoading")) return;
3114
- externalBetterHtmlContextValue.setLoaders((oldValue) => ({
3115
- ...oldValue,
3116
- [loaderName.toString()]: true
3117
- }));
3118
- },
3119
- stopLoading: (loaderName) => {
3120
- if (!checkBetterHtmlContextValue(externalBetterHtmlContextValue, "loaderControls.stopLoading")) return;
3121
- externalBetterHtmlContextValue.setLoaders((oldValue) => ({
3122
- ...oldValue,
3123
- [loaderName.toString()]: false
3124
- }));
3125
- }
3126
- };
3127
- var alertControls = {
3128
- createAlert: (alert) => {
3129
- if (!checkBetterHtmlContextValue(externalBetterHtmlContextValue, "alertControls.createAlert"))
3130
- return void 0;
3131
- const readyAlert = {
3132
- id: crypto.randomUUID(),
3133
- ...alert
3134
- };
3135
- externalBetterHtmlContextValue.setAlerts((oldValue) => [...oldValue, readyAlert]);
3136
- return readyAlert;
3137
- },
3138
- removeAlert: (alertId) => {
3139
- if (!checkBetterHtmlContextValue(externalBetterHtmlContextValue, "alertControls.removeAlert")) return;
3140
- externalBetterHtmlContextValue.setAlerts((oldValue) => oldValue.filter((alert) => alert.id !== alertId));
3141
- }
3142
- };
3143
- var colorThemeControls = {
3144
- toggleTheme: (theme2) => {
3145
- if (!checkBetterHtmlContextValue(externalBetterHtmlContextValue, "colorThemeControls.toggleTheme")) return;
3146
- const currentColorTheme = externalBetterHtmlContextValue.colorTheme;
3147
- const newColorTheme = theme2 ?? (currentColorTheme === "dark" ? "light" : "dark");
3148
- setTimeout(() => {
3149
- window.document.body.parentElement?.setAttribute("data-theme", newColorTheme);
3150
- LocalStorage.setItem("theme", newColorTheme);
3151
- }, 0.01 * 1e3);
3152
- }
3153
- };
3154
- var filterHover = () => {
3155
- if (!checkBetterHtmlContextValue(externalBetterHtmlContextValue, "filterHover")) return void 0;
3156
- return {
3157
- z05: externalBetterHtmlContextValue.colorTheme === "dark" ? "brightness(1.2)" : "brightness(0.95)",
3158
- z1: externalBetterHtmlContextValue.colorTheme === "dark" ? "brightness(1.3)" : "brightness(0.9)",
3159
- z2: externalBetterHtmlContextValue.colorTheme === "dark" ? "brightness(1.6)" : "brightness(0.8)",
3160
- z3: externalBetterHtmlContextValue.colorTheme === "dark" ? "brightness(1.9)" : "brightness(0.7)"
3161
- };
3162
- };
3163
-
3164
- // src/utils/functions.ts
3165
- var generateRandomString = (stringLength, options) => {
3166
- const capitals = "ABCDEFGHIJKLMNOPQRSTUVWXYZ";
3167
- const lowers = "abcdefghijklmnopqrstuvwxyz";
3168
- const numbers = "0123456789";
3169
- const includes = [];
3170
- if (options?.includeCapitalLetters !== false) includes.push(capitals);
3171
- if (options?.includeLowerLetters !== false) includes.push(lowers);
3172
- if (options?.includeNumbers !== false) includes.push(numbers);
3173
- const characters = includes.join("");
3174
- const dashSections = Math.max(1, options?.dashSections ?? 1);
3175
- const dashSectionLength = Math.floor(stringLength / dashSections);
3176
- if (stringLength < dashSections) return "";
3177
- let result = "";
3178
- let currentSectionLength = 0;
3179
- while (result.length < stringLength) {
3180
- if (currentSectionLength >= dashSectionLength) {
3181
- result += "-";
3182
- currentSectionLength = 0;
3183
- }
3184
- if (result.length < stringLength) {
3185
- result += characters.charAt(Math.floor(Math.random() * characters.length));
3186
- currentSectionLength += 1;
3187
- }
3188
- }
3189
- return result;
3190
- };
3191
- var getBrowser = () => {
3192
- const userAgent = navigator.userAgent.toLowerCase();
3193
- if (userAgent.includes("firefox")) return "firefox";
3194
- if (userAgent.includes("chrome") && !userAgent.includes("edg")) return "chrome";
3195
- if (userAgent.includes("safari") && !userAgent.includes("chrome")) return "safari";
3196
- if (userAgent.includes("edg")) return "edge";
3197
- if (userAgent.includes("opr") || userAgent.includes("opera")) return "opera";
3198
- return;
3199
- };
3200
- var formatPhoneNumber = (phoneNumber) => {
3201
- const cleanPhoneNumber = phoneNumber.replace(/\D/g, "");
3202
- const country = countries.find(
3203
- (country2) => country2.phoneNumberExtension === cleanPhoneNumber.slice(0, country2.phoneNumberExtension.length)
3204
- );
3205
- if (!country) return phoneNumber;
3206
- let phonNumberRest = cleanPhoneNumber.slice(country.phoneNumberExtension.length);
3207
- if (country.phoneNumberFormat) {
3208
- let formattedNumber = "";
3209
- let index = 0;
3210
- for (const char of country.phoneNumberFormat) {
3211
- if (char === "X" && index < phonNumberRest.length) {
3212
- formattedNumber += phonNumberRest[index];
3213
- index++;
3214
- } else {
3215
- formattedNumber += char;
3216
- }
3217
- }
3218
- phonNumberRest = formattedNumber.replace(/X/g, "").trim();
3219
- }
3220
- return `+${country.phoneNumberExtension} ${phonNumberRest}`;
3221
- };
3222
- var getFormErrorObject = (formValues) => {
3223
- return {};
3224
- };
3225
- var eventPreventDefault = (event) => {
3226
- event.preventDefault();
3227
- };
3228
- var eventStopPropagation = (event) => {
3229
- event.stopPropagation();
3230
- };
3231
- var eventPreventStop = (event) => {
3232
- event.preventDefault();
3233
- event.stopPropagation();
3234
- };
3235
- var encryptString = (text) => {
3236
- if (!checkBetterHtmlContextValue(externalBetterHtmlContextValue, "encryptString")) return void 0;
3237
- const localStoragePlugin2 = externalBetterHtmlContextValue.plugins.find((plugin) => plugin.name === "localStorage");
3238
- if (!localStoragePlugin2) {
3239
- throw new Error(
3240
- "`encryptString` hook requires the `localStorage` plugin to be added to the `plugins` prop in `<BetterHtmlProvider>`."
3241
- );
3242
- }
3243
- const pluginConfig = localStoragePlugin2.getConfig();
3244
- if (!pluginConfig.encryption?.enabled) return text;
3245
- const encrypted = import_crypto_js.default.AES.encrypt(text, import_crypto_js.default.enc.Hex.parse(pluginConfig.encryption.secretKey), {
3246
- iv: import_crypto_js.default.enc.Hex.parse(pluginConfig.encryption.iv),
3247
- mode: import_crypto_js.default.mode.CBC,
3248
- padding: import_crypto_js.default.pad.Pkcs7
3249
- }).toString();
3250
- return encrypted;
3251
- };
3252
- var decryptString = (text) => {
3253
- if (!checkBetterHtmlContextValue(externalBetterHtmlContextValue, "decryptString")) return void 0;
3254
- const localStoragePlugin2 = externalBetterHtmlContextValue.plugins.find((plugin) => plugin.name === "localStorage");
3255
- if (!localStoragePlugin2) {
3256
- throw new Error(
3257
- "`decryptString` hook requires the `localStorage` plugin to be added to the `plugins` prop in `<BetterHtmlProvider>`."
3258
- );
3259
- }
3260
- const pluginConfig = localStoragePlugin2.getConfig();
3261
- if (!pluginConfig.encryption?.enabled) return text;
3262
- const decrypted = import_crypto_js.default.AES.decrypt(text, import_crypto_js.default.enc.Hex.parse(pluginConfig.encryption.secretKey), {
3263
- iv: import_crypto_js.default.enc.Hex.parse(pluginConfig.encryption.iv),
3264
- mode: import_crypto_js.default.mode.CBC,
3265
- padding: import_crypto_js.default.pad.Pkcs7
3266
- });
3267
- return decrypted.toString(import_crypto_js.default.enc.Utf8);
3268
- };
3269
-
3270
- // src/utils/localStorage.ts
3271
- function generateLocalStorage() {
3272
- return {
3273
- setItem: (name, value) => {
3274
- if (!checkBetterHtmlContextValue(externalBetterHtmlContextValue, "generateLocalStorage"))
3275
- return void 0;
3276
- const localStoragePlugin2 = externalBetterHtmlContextValue.plugins.find(
3277
- (plugin) => plugin.name === "localStorage"
3278
- );
3279
- if (!localStoragePlugin2) {
3280
- throw new Error(
3281
- "`generateLocalStorage` hook requires the `localStorage` plugin to be added to the `plugins` prop in `<BetterHtmlProvider>`."
3282
- );
3283
- }
3284
- const pluginConfig = localStoragePlugin2.getConfig();
3285
- const encryptionEnabled = pluginConfig.encryption?.enabled ?? false;
3286
- const readyName = encryptionEnabled ? encryptString(name.toString()) : name;
3287
- const readyValue = encryptionEnabled ? encryptString(JSON.stringify(value)) : JSON.stringify(value);
3288
- if (value) localStorage.setItem(readyName.toString(), readyValue);
3289
- else localStorage.removeItem(readyName.toString());
3290
- },
3291
- getItem: (name) => {
3292
- if (!checkBetterHtmlContextValue(externalBetterHtmlContextValue, "generateLocalStorage"))
3293
- return void 0;
3294
- const localStoragePlugin2 = externalBetterHtmlContextValue.plugins.find(
3295
- (plugin) => plugin.name === "localStorage"
3296
- );
3297
- if (!localStoragePlugin2) {
3298
- throw new Error(
3299
- "`generateLocalStorage` hook requires the `localStorage` plugin to be added to the `plugins` prop in `<BetterHtmlProvider>`."
3300
- );
3301
- }
3302
- const pluginConfig = localStoragePlugin2.getConfig();
3303
- const encryptionEnabled = pluginConfig.encryption?.enabled ?? false;
3304
- const readyName = encryptionEnabled ? encryptString(name.toString()) : name;
3305
- const item = localStorage.getItem(readyName.toString());
3306
- if (item === null) return void 0;
3307
- try {
3308
- return encryptionEnabled ? JSON.parse(decryptString(item)) : JSON.parse(item);
3309
- } catch (error) {
3310
- return void 0;
3311
- }
3312
- },
3313
- removeItem: (name) => {
3314
- if (!checkBetterHtmlContextValue(externalBetterHtmlContextValue, "generateLocalStorage"))
3315
- return void 0;
3316
- const localStoragePlugin2 = externalBetterHtmlContextValue.plugins.find(
3317
- (plugin) => plugin.name === "localStorage"
3318
- );
3319
- if (!localStoragePlugin2) {
3320
- throw new Error(
3321
- "`generateLocalStorage` hook requires the `localStorage` plugin to be added to the `plugins` prop in `<BetterHtmlProvider>`."
3322
- );
3323
- }
3324
- const pluginConfig = localStoragePlugin2.getConfig();
3325
- const encryptionEnabled = pluginConfig.encryption?.enabled ?? false;
3326
- const readyName = encryptionEnabled ? encryptString(name.toString()) : name;
3327
- localStorage.removeItem(readyName.toString());
3328
- },
3329
- removeAllItems: () => {
3330
- localStorage.clear();
3331
- }
3332
- };
3333
- }
3334
- var LocalStorage = generateLocalStorage();
3335
-
3336
- // src/components/alerts/AlertsHolder.tsx
3337
- var import_react8 = require("react");
3338
-
3339
- // src/components/alerts/Alert.tsx
3340
- var import_react7 = require("react");
3341
- var import_styled_components6 = __toESM(require("styled-components"));
3342
-
3343
- // src/plugins/alerts.ts
3344
- var defaultAlertsPluginOptions = {
3345
- position: "bottom",
3346
- align: "right",
3347
- defaultDuration: "auto",
3348
- maxWidth: 460,
3349
- withLoaderBar: true,
3350
- withCloseButton: true
3351
- };
3352
- var alertsPlugin = (options) => ({
3353
- name: "alerts",
3354
- initialize: () => {
3355
- console.log("alerts plugin initialized");
3356
- },
3357
- getConfig: () => ({
3358
- ...defaultAlertsPluginOptions,
3359
- ...options
3360
- })
3361
- });
3362
-
3363
- // src/plugins/reactRouterDom.ts
3364
- var defaultReactRouterDomPluginOptions = {};
3365
- var reactRouterDomPlugin = (options) => ({
3366
- name: "react-router-dom",
3367
- initialize: () => {
3368
- console.log("react-router-dom plugin initialized");
3369
- },
3370
- getConfig: () => ({
3371
- ...defaultReactRouterDomPluginOptions,
3372
- ...options
3373
- })
3374
- });
3375
-
3376
- // src/plugins/localStorage.ts
3377
- var defaultLocalStoragePluginOptions = {
3378
- encryption: {}
3379
- };
3380
- var localStoragePlugin = (options) => ({
3381
- name: "localStorage",
3382
- initialize: () => {
3383
- console.log("localStorage plugin initialized");
1650
+ getConfig: () => ({
1651
+ ...defaultReactRouterDomPluginOptions,
1652
+ ...options
1653
+ })
1654
+ });
1655
+
1656
+ // src/plugins/localStorage.ts
1657
+ var defaultLocalStoragePluginOptions = {
1658
+ encryption: {}
1659
+ };
1660
+ var localStoragePlugin = (options) => ({
1661
+ name: "localStorage",
1662
+ initialize: () => {
1663
+ console.log("localStorage plugin initialized");
3384
1664
  },
3385
1665
  getConfig: () => ({
3386
1666
  ...defaultLocalStoragePluginOptions,
@@ -4344,7 +2624,7 @@ function BetterHtmlProviderContent({ children }) {
4344
2624
  }
4345
2625
  function BetterHtmlProvider({ value, plugins: pluginsToUse, children }) {
4346
2626
  const [colorTheme, setColorTheme] = (0, import_react9.useState)(
4347
- LocalStorage.getItem("theme") === "dark" ? "dark" : value?.colorTheme ?? "light"
2627
+ localStorage.getItem("theme") === "dark" ? "dark" : value?.colorTheme ?? "light"
4348
2628
  );
4349
2629
  const [loaders, setLoaders] = (0, import_react9.useState)(value?.loaders ?? {});
4350
2630
  const [plugins] = (0, import_react9.useState)(pluginsToUse ?? []);
@@ -5356,413 +3636,2067 @@ var ModalComponent = (0, import_react14.forwardRef)(function Modal({
5356
3636
  children: isOpenedLate ? /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
5357
3637
  Div_default.column,
5358
3638
  {
5359
- position: "relative",
5360
- width: "100%",
5361
- maxWidth: maxWidth ?? app.contentMaxWidth / 1.3,
5362
- minHeight: `calc(100% - ${theme2.styles.space * 2}px)`,
5363
- alignItems: "center",
5364
- justifyContent: "center",
3639
+ position: "relative",
3640
+ width: "100%",
3641
+ maxWidth: maxWidth ?? app.contentMaxWidth / 1.3,
3642
+ minHeight: `calc(100% - ${theme2.styles.space * 2}px)`,
3643
+ alignItems: "center",
3644
+ justifyContent: "center",
3645
+ marginBlock: theme2.styles.space,
3646
+ marginInline: "auto",
3647
+ transform: `translateY(${theme2.styles.space}px)`,
3648
+ transition: theme2.styles.transition,
3649
+ animation: isOpened ? "fadeInAnimation 0.2s ease forwards" : "fadeOutAnimation 0.2s ease forwards",
3650
+ children: /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(
3651
+ Div_default,
3652
+ {
3653
+ position: "relative",
3654
+ width: "100%",
3655
+ minHeight: 32 + theme2.styles.space * 2,
3656
+ backgroundColor: theme2.colors.backgroundBase,
3657
+ borderRadius: theme2.styles.borderRadius * 2,
3658
+ padding: !title ? theme2.styles.space : void 0,
3659
+ overflow,
3660
+ children: [
3661
+ title ? /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(import_jsx_runtime12.Fragment, { children: [
3662
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(
3663
+ Div_default.row,
3664
+ {
3665
+ alignItems: "center",
3666
+ gap: theme2.styles.gap,
3667
+ backgroundColor: headerBackgroundColor,
3668
+ borderTopLeftRadius: theme2.styles.borderRadius * 2 - 1,
3669
+ borderTopRightRadius: theme2.styles.borderRadius * 2 - 1,
3670
+ paddingInline: theme2.styles.space,
3671
+ paddingBlock: theme2.styles.space,
3672
+ transition: theme2.styles.transition,
3673
+ children: [
3674
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(Div_default.column, { flex: 1, gap: theme2.styles.gap / 2, children: [
3675
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
3676
+ Text_default,
3677
+ {
3678
+ as: "h1",
3679
+ color: titleColor ?? theme2.colors.textPrimary,
3680
+ transition: theme2.styles.transition,
3681
+ children: title
3682
+ }
3683
+ ),
3684
+ description && /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
3685
+ Text_default,
3686
+ {
3687
+ color: descriptionColor ?? theme2.colors.textSecondary,
3688
+ transition: theme2.styles.transition,
3689
+ children: description
3690
+ }
3691
+ )
3692
+ ] }),
3693
+ !withoutCloseButton && /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
3694
+ Button_default.icon,
3695
+ {
3696
+ icon: "XMark",
3697
+ marginTop: 1,
3698
+ iconColor: titleColor,
3699
+ onClick: onClickClose,
3700
+ transition: theme2.styles.transition
3701
+ }
3702
+ )
3703
+ ]
3704
+ }
3705
+ ),
3706
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Divider_default.horizontal, {})
3707
+ ] }) : /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(import_jsx_runtime12.Fragment, { children: !withoutCloseButton && /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Div_default, { position: "absolute", top: theme2.styles.space, right: theme2.styles.space, children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Button_default.icon, { icon: "XMark", onClick: onClickClose }) }) }),
3708
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Div_default, { padding: title ? theme2.styles.space : void 0, children })
3709
+ ]
3710
+ }
3711
+ )
3712
+ }
3713
+ ) : void 0
3714
+ }
3715
+ ),
3716
+ document.body
3717
+ );
3718
+ });
3719
+ ModalComponent.confirmation = (0, import_react14.forwardRef)(function Confirmation({ message, continueButtonLoaderName, onContinue, onCancel, ...props }, ref) {
3720
+ const theme2 = useTheme();
3721
+ const modalRef = (0, import_react14.useRef)(null);
3722
+ const onCancelElement = (0, import_react14.useCallback)(() => {
3723
+ onCancel?.();
3724
+ modalRef.current?.close();
3725
+ }, [onCancel]);
3726
+ const onContinueElement = (0, import_react14.useCallback)(() => {
3727
+ onContinue?.();
3728
+ modalRef.current?.close();
3729
+ }, [onContinue]);
3730
+ (0, import_react14.useImperativeHandle)(ref, () => modalRef.current, []);
3731
+ return /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(ModalComponent, { title: "Are you sure?", maxWidth: 660, ...props, ref: modalRef, children: [
3732
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Text_default, { color: theme2.colors.textSecondary, children: message ?? "Do you really want to continue? This action may be irreversible." }),
3733
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(
3734
+ Div_default.row,
3735
+ {
3736
+ alignItems: "center",
3737
+ justifyContent: "flex-end",
3738
+ gap: theme2.styles.gap,
3739
+ marginTop: theme2.styles.space * 2,
3740
+ children: [
3741
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Button_default.secondary, { text: "Cancel", onClick: onCancelElement }),
3742
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Button_default, { text: "Continue", loaderName: continueButtonLoaderName, onClick: onContinueElement })
3743
+ ]
3744
+ }
3745
+ )
3746
+ ] });
3747
+ });
3748
+ ModalComponent.destructive = (0, import_react14.forwardRef)(function Destructive2({ message, deleteButtonLoaderName, onDelete, onCancel, ...props }, ref) {
3749
+ const theme2 = useTheme();
3750
+ const modalRef = (0, import_react14.useRef)(null);
3751
+ const onCancelElement = (0, import_react14.useCallback)(() => {
3752
+ onCancel?.();
3753
+ modalRef.current?.close();
3754
+ }, [onCancel]);
3755
+ const onDeleteElement = (0, import_react14.useCallback)(() => {
3756
+ onDelete?.();
3757
+ modalRef.current?.close();
3758
+ }, [onDelete]);
3759
+ (0, import_react14.useImperativeHandle)(ref, () => modalRef.current, []);
3760
+ return /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(ModalComponent, { title: "Are you sure?", maxWidth: 660, ...props, ref: modalRef, children: [
3761
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Text_default, { color: theme2.colors.textSecondary, children: message ?? "Do you really want to continue with the deleting of the item? This action may be irreversible." }),
3762
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(
3763
+ Div_default.row,
3764
+ {
3765
+ alignItems: "center",
3766
+ justifyContent: "flex-end",
3767
+ gap: theme2.styles.gap,
3768
+ marginTop: theme2.styles.space * 2,
3769
+ children: [
3770
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Button_default.secondary, { text: "Cancel", onClick: onCancelElement }),
3771
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
3772
+ Button_default.destructive,
3773
+ {
3774
+ icon: "trash",
3775
+ text: "Delete",
3776
+ loaderName: deleteButtonLoaderName,
3777
+ onClick: onDeleteElement
3778
+ }
3779
+ )
3780
+ ]
3781
+ }
3782
+ )
3783
+ ] });
3784
+ });
3785
+ var Modal2 = (0, import_react14.memo)(ModalComponent);
3786
+ Modal2.confirmation = ModalComponent.confirmation;
3787
+ Modal2.destructive = ModalComponent.destructive;
3788
+ var Modal_default = Modal2;
3789
+
3790
+ // src/components/PageHolder.tsx
3791
+ var import_react15 = require("react");
3792
+ var import_jsx_runtime13 = require("react/jsx-runtime");
3793
+ var PageHolderComponent = (0, import_react15.forwardRef)(function PageHolder({ noMaxContentWidth, children, ...props }, ref) {
3794
+ const theme2 = useTheme();
3795
+ const { app } = useBetterHtmlContextInternal();
3796
+ return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
3797
+ Div_default,
3798
+ {
3799
+ as: "main",
3800
+ width: "100%",
3801
+ maxWidth: !noMaxContentWidth ? app.contentMaxWidth : void 0,
3802
+ margin: "0px auto",
3803
+ padding: theme2.styles.space,
3804
+ ...props,
3805
+ ref,
3806
+ children
3807
+ }
3808
+ );
3809
+ });
3810
+ PageHolderComponent.center = (0, import_react15.forwardRef)(function Center({
3811
+ pageBackgroundColor,
3812
+ pageBackgroundImage,
3813
+ contentMaxWidth,
3814
+ behindComponent,
3815
+ sideComponent,
3816
+ sideComponentPosition = "right",
3817
+ noMaxContentWidth,
3818
+ children,
3819
+ ...props
3820
+ }, ref) {
3821
+ const theme2 = useTheme();
3822
+ const mediaQuery = useMediaQuery();
3823
+ const { app } = useBetterHtmlContextInternal();
3824
+ const breakingPoint = mediaQuery.size1000;
3825
+ const withSideComponent = sideComponent && !breakingPoint;
3826
+ return /* @__PURE__ */ (0, import_jsx_runtime13.jsxs)(
3827
+ Div_default.row,
3828
+ {
3829
+ position: "relative",
3830
+ width: "100%",
3831
+ minHeight: "100svh",
3832
+ alignItems: "center",
3833
+ justifyContent: "center",
3834
+ backgroundColor: pageBackgroundColor,
3835
+ backgroundImage: pageBackgroundImage,
3836
+ children: [
3837
+ behindComponent && /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
3838
+ Div_default,
3839
+ {
3840
+ position: "fixed",
3841
+ width: `${withSideComponent ? 50 : 100}%`,
3842
+ height: "100svh",
3843
+ top: 0,
3844
+ left: sideComponentPosition === "right" ? 0 : "auto",
3845
+ right: sideComponentPosition === "left" ? 0 : "auto",
3846
+ zIndex: 1,
3847
+ children: behindComponent
3848
+ }
3849
+ ),
3850
+ sideComponentPosition === "left" && withSideComponent && /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(Div_default, { width: "50%" }),
3851
+ /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(Div_default.column, { position: "relative", width: `${withSideComponent ? 50 : 100}%`, alignItems: "center", zIndex: 2, children: /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
3852
+ Div_default.box,
3853
+ {
3854
+ width: `calc(100% - ${theme2.styles.space * 2}px)`,
3855
+ maxWidth: !noMaxContentWidth ? contentMaxWidth ?? app.contentMaxWidth / 2 : void 0,
3856
+ marginInline: theme2.styles.space,
5365
3857
  marginBlock: theme2.styles.space,
5366
- marginInline: "auto",
5367
- transform: `translateY(${theme2.styles.space}px)`,
5368
- transition: theme2.styles.transition,
5369
- animation: isOpened ? "fadeInAnimation 0.2s ease forwards" : "fadeOutAnimation 0.2s ease forwards",
5370
- children: /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(
5371
- Div_default,
5372
- {
5373
- position: "relative",
5374
- width: "100%",
5375
- minHeight: 32 + theme2.styles.space * 2,
5376
- backgroundColor: theme2.colors.backgroundBase,
5377
- borderRadius: theme2.styles.borderRadius * 2,
5378
- padding: !title ? theme2.styles.space : void 0,
5379
- overflow,
5380
- children: [
5381
- title ? /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(import_jsx_runtime12.Fragment, { children: [
5382
- /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(
5383
- Div_default.row,
5384
- {
5385
- alignItems: "center",
5386
- gap: theme2.styles.gap,
5387
- backgroundColor: headerBackgroundColor,
5388
- borderTopLeftRadius: theme2.styles.borderRadius * 2 - 1,
5389
- borderTopRightRadius: theme2.styles.borderRadius * 2 - 1,
5390
- paddingInline: theme2.styles.space,
5391
- paddingBlock: theme2.styles.space,
5392
- transition: theme2.styles.transition,
5393
- children: [
5394
- /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(Div_default.column, { flex: 1, gap: theme2.styles.gap / 2, children: [
5395
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
5396
- Text_default,
5397
- {
5398
- as: "h1",
5399
- color: titleColor ?? theme2.colors.textPrimary,
5400
- transition: theme2.styles.transition,
5401
- children: title
5402
- }
5403
- ),
5404
- description && /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
5405
- Text_default,
5406
- {
5407
- color: descriptionColor ?? theme2.colors.textSecondary,
5408
- transition: theme2.styles.transition,
5409
- children: description
5410
- }
5411
- )
5412
- ] }),
5413
- !withoutCloseButton && /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
5414
- Button_default.icon,
5415
- {
5416
- icon: "XMark",
5417
- marginTop: 1,
5418
- iconColor: titleColor,
5419
- onClick: onClickClose,
5420
- transition: theme2.styles.transition
5421
- }
5422
- )
5423
- ]
5424
- }
5425
- ),
5426
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Divider_default.horizontal, {})
5427
- ] }) : /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(import_jsx_runtime12.Fragment, { children: !withoutCloseButton && /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Div_default, { position: "absolute", top: theme2.styles.space, right: theme2.styles.space, children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Button_default.icon, { icon: "XMark", onClick: onClickClose }) }) }),
5428
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Div_default, { padding: title ? theme2.styles.space : void 0, children })
5429
- ]
5430
- }
5431
- )
3858
+ ...props,
3859
+ ref,
3860
+ children
5432
3861
  }
5433
- ) : void 0
5434
- }
5435
- ),
5436
- document.body
3862
+ ) }),
3863
+ sideComponentPosition === "right" && withSideComponent && /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(Div_default, { width: "50%" }),
3864
+ withSideComponent && /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
3865
+ Div_default,
3866
+ {
3867
+ position: "fixed",
3868
+ width: "50%",
3869
+ height: "100svh",
3870
+ top: 0,
3871
+ left: sideComponentPosition === "left" ? 0 : "auto",
3872
+ right: sideComponentPosition === "right" ? 0 : "auto",
3873
+ children: sideComponent
3874
+ }
3875
+ )
3876
+ ]
3877
+ }
5437
3878
  );
5438
3879
  });
5439
- ModalComponent.confirmation = (0, import_react14.forwardRef)(function Confirmation({ message, continueButtonLoaderName, onContinue, onCancel, ...props }, ref) {
3880
+ var PageHolder2 = (0, import_react15.memo)(PageHolderComponent);
3881
+ PageHolder2.center = PageHolderComponent.center;
3882
+ var PageHolder_default = PageHolder2;
3883
+
3884
+ // src/components/Chip.tsx
3885
+ var import_react16 = require("react");
3886
+
3887
+ // src/utils/colorManipulation.ts
3888
+ var rgbToHsl = (r, g, b) => {
3889
+ r /= 255;
3890
+ g /= 255;
3891
+ b /= 255;
3892
+ const max = Math.max(r, g, b);
3893
+ const min = Math.min(r, g, b);
3894
+ let h = 0;
3895
+ let s = 0;
3896
+ const l = (max + min) / 2;
3897
+ if (max !== min) {
3898
+ const d = max - min;
3899
+ s = l > 0.5 ? d / (2 - max - min) : d / (max + min);
3900
+ switch (max) {
3901
+ case r:
3902
+ h = (g - b) / d + (g < b ? 6 : 0);
3903
+ break;
3904
+ case g:
3905
+ h = (b - r) / d + 2;
3906
+ break;
3907
+ case b:
3908
+ h = (r - g) / d + 4;
3909
+ break;
3910
+ }
3911
+ h /= 6;
3912
+ }
3913
+ return [h, s, l];
3914
+ };
3915
+ var hslToRgb = (h, s, l) => {
3916
+ let r, g, b;
3917
+ if (s === 0) {
3918
+ r = g = b = l;
3919
+ } else {
3920
+ const hue2rgb = (p2, q2, t) => {
3921
+ if (t < 0) t += 1;
3922
+ if (t > 1) t -= 1;
3923
+ if (t < 1 / 6) return p2 + (q2 - p2) * 6 * t;
3924
+ if (t < 1 / 2) return q2;
3925
+ if (t < 2 / 3) return p2 + (q2 - p2) * (2 / 3 - t) * 6;
3926
+ return p2;
3927
+ };
3928
+ const q = l < 0.5 ? l * (1 + s) : l + s - l * s;
3929
+ const p = 2 * l - q;
3930
+ r = hue2rgb(p, q, h + 1 / 3);
3931
+ g = hue2rgb(p, q, h);
3932
+ b = hue2rgb(p, q, h - 1 / 3);
3933
+ }
3934
+ return [Math.round(r * 255), Math.round(g * 255), Math.round(b * 255)];
3935
+ };
3936
+ var lightenColor = (hexColor, amount) => {
3937
+ let hex = hexColor.replace(/^#/, "");
3938
+ if (hex.length === 3) {
3939
+ hex = hex[0] + hex[0] + hex[1] + hex[1] + hex[2] + hex[2];
3940
+ }
3941
+ const safeAmount = Math.max(0, Math.min(1, amount));
3942
+ const r = parseInt(hex.substring(0, 2), 16);
3943
+ const g = parseInt(hex.substring(2, 4), 16);
3944
+ const b = parseInt(hex.substring(4, 6), 16);
3945
+ const lightenComponent = (component) => {
3946
+ return Math.round(component + (255 - component) * safeAmount);
3947
+ };
3948
+ const rHex = lightenComponent(r).toString(16).padStart(2, "0");
3949
+ const gHex = lightenComponent(g).toString(16).padStart(2, "0");
3950
+ const bHex = lightenComponent(b).toString(16).padStart(2, "0");
3951
+ return `#${rHex}${gHex}${bHex}`;
3952
+ };
3953
+ var darkenColor = (hexColor, amount) => {
3954
+ let hex = hexColor.replace(/^#/, "");
3955
+ if (hex.length === 3) {
3956
+ hex = hex[0] + hex[0] + hex[1] + hex[1] + hex[2] + hex[2];
3957
+ }
3958
+ const safeAmount = Math.max(0, Math.min(1, amount));
3959
+ const r = parseInt(hex.substring(0, 2), 16);
3960
+ const g = parseInt(hex.substring(2, 4), 16);
3961
+ const b = parseInt(hex.substring(4, 6), 16);
3962
+ const darkenComponent = (component) => {
3963
+ return Math.round(component * (1 - safeAmount));
3964
+ };
3965
+ const rHex = darkenComponent(r).toString(16).padStart(2, "0");
3966
+ const gHex = darkenComponent(g).toString(16).padStart(2, "0");
3967
+ const bHex = darkenComponent(b).toString(16).padStart(2, "0");
3968
+ return `#${rHex}${gHex}${bHex}`;
3969
+ };
3970
+ var saturateColor = (hexColor, amount) => {
3971
+ let hex = hexColor.replace(/^#/, "");
3972
+ if (hex.length === 3) {
3973
+ hex = hex[0] + hex[0] + hex[1] + hex[1] + hex[2] + hex[2];
3974
+ }
3975
+ const safeAmount = Math.max(0, Math.min(1, amount));
3976
+ const r = parseInt(hex.substring(0, 2), 16);
3977
+ const g = parseInt(hex.substring(2, 4), 16);
3978
+ const b = parseInt(hex.substring(4, 6), 16);
3979
+ const [h, s, l] = rgbToHsl(r, g, b);
3980
+ const newSaturation = Math.min(1, s + safeAmount * (1 - s));
3981
+ const [newR, newG, newB] = hslToRgb(h, newSaturation, l);
3982
+ const rHex = Math.round(newR).toString(16).padStart(2, "0");
3983
+ const gHex = Math.round(newG).toString(16).padStart(2, "0");
3984
+ const bHex = Math.round(newB).toString(16).padStart(2, "0");
3985
+ return `#${rHex}${gHex}${bHex}`;
3986
+ };
3987
+ var desaturateColor = (hexColor, amount) => {
3988
+ let hex = hexColor.replace(/^#/, "");
3989
+ if (hex.length === 3) {
3990
+ hex = hex[0] + hex[0] + hex[1] + hex[1] + hex[2] + hex[2];
3991
+ }
3992
+ const safeAmount = Math.max(0, Math.min(1, amount));
3993
+ const r = parseInt(hex.substring(0, 2), 16);
3994
+ const g = parseInt(hex.substring(2, 4), 16);
3995
+ const b = parseInt(hex.substring(4, 6), 16);
3996
+ const [h, s, l] = rgbToHsl(r, g, b);
3997
+ const newSaturation = Math.max(0, s * (1 - safeAmount));
3998
+ const [newR, newG, newB] = hslToRgb(h, newSaturation, l);
3999
+ const rHex = Math.round(newR).toString(16).padStart(2, "0");
4000
+ const gHex = Math.round(newG).toString(16).padStart(2, "0");
4001
+ const bHex = Math.round(newB).toString(16).padStart(2, "0");
4002
+ return `#${rHex}${gHex}${bHex}`;
4003
+ };
4004
+
4005
+ // src/components/Chip.tsx
4006
+ var import_jsx_runtime14 = require("react/jsx-runtime");
4007
+ var ChipComponent = (0, import_react16.forwardRef)(function Chip({ text, color, backgroundColor, borderRadius, isCircle, ...props }, ref) {
5440
4008
  const theme2 = useTheme();
5441
- const modalRef = (0, import_react14.useRef)(null);
5442
- const onCancelElement = (0, import_react14.useCallback)(() => {
5443
- onCancel?.();
5444
- modalRef.current?.close();
5445
- }, [onCancel]);
5446
- const onContinueElement = (0, import_react14.useCallback)(() => {
5447
- onContinue?.();
5448
- modalRef.current?.close();
5449
- }, [onContinue]);
5450
- (0, import_react14.useImperativeHandle)(ref, () => modalRef.current, []);
5451
- return /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(ModalComponent, { title: "Are you sure?", maxWidth: 660, ...props, ref: modalRef, children: [
5452
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Text_default, { color: theme2.colors.textSecondary, children: message ?? "Do you really want to continue? This action may be irreversible." }),
5453
- /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(
5454
- Div_default.row,
5455
- {
5456
- alignItems: "center",
5457
- justifyContent: "flex-end",
5458
- gap: theme2.styles.gap,
5459
- marginTop: theme2.styles.space * 2,
5460
- children: [
5461
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Button_default.secondary, { text: "Cancel", onClick: onCancelElement }),
5462
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Button_default, { text: "Continue", loaderName: continueButtonLoaderName, onClick: onContinueElement })
5463
- ]
5464
- }
5465
- )
5466
- ] });
4009
+ return /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
4010
+ Div_default,
4011
+ {
4012
+ width: "fit-content",
4013
+ backgroundColor: backgroundColor ?? theme2.colors.backgroundSecondary,
4014
+ borderRadius: isCircle ? 999 : borderRadius ?? theme2.styles.borderRadius / 1.3,
4015
+ paddingBlock: theme2.styles.gap / 2,
4016
+ paddingInline: theme2.styles.space / 1.5,
4017
+ ...props,
4018
+ ref,
4019
+ children: /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(Text_default, { color: color ?? theme2.colors.textPrimary, children: text })
4020
+ }
4021
+ );
5467
4022
  });
5468
- ModalComponent.destructive = (0, import_react14.forwardRef)(function Destructive2({ message, deleteButtonLoaderName, onDelete, onCancel, ...props }, ref) {
4023
+ ChipComponent.colored = (0, import_react16.forwardRef)(function Colored({ color, ...props }, ref) {
5469
4024
  const theme2 = useTheme();
5470
- const modalRef = (0, import_react14.useRef)(null);
5471
- const onCancelElement = (0, import_react14.useCallback)(() => {
5472
- onCancel?.();
5473
- modalRef.current?.close();
5474
- }, [onCancel]);
5475
- const onDeleteElement = (0, import_react14.useCallback)(() => {
5476
- onDelete?.();
5477
- modalRef.current?.close();
5478
- }, [onDelete]);
5479
- (0, import_react14.useImperativeHandle)(ref, () => modalRef.current, []);
5480
- return /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(ModalComponent, { title: "Are you sure?", maxWidth: 660, ...props, ref: modalRef, children: [
5481
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Text_default, { color: theme2.colors.textSecondary, children: message ?? "Do you really want to continue with the deleting of the item? This action may be irreversible." }),
5482
- /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(
5483
- Div_default.row,
5484
- {
5485
- alignItems: "center",
5486
- justifyContent: "flex-end",
5487
- gap: theme2.styles.gap,
5488
- marginTop: theme2.styles.space * 2,
5489
- children: [
5490
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Button_default.secondary, { text: "Cancel", onClick: onCancelElement }),
5491
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
5492
- Button_default.destructive,
5493
- {
5494
- icon: "trash",
5495
- text: "Delete",
5496
- loaderName: deleteButtonLoaderName,
5497
- onClick: onDeleteElement
5498
- }
5499
- )
5500
- ]
5501
- }
5502
- )
5503
- ] });
4025
+ const { colorTheme } = useBetterHtmlContextInternal();
4026
+ const readyColor = color ?? theme2.colors.textSecondary;
4027
+ return /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
4028
+ ChipComponent,
4029
+ {
4030
+ color: colorTheme === "light" ? darkenColor(readyColor, 0.7) : lightenColor(readyColor, 0.7),
4031
+ backgroundColor: readyColor + "40",
4032
+ border: `1px solid ${readyColor}`,
4033
+ ref,
4034
+ ...props
4035
+ }
4036
+ );
5504
4037
  });
5505
- var Modal2 = (0, import_react14.memo)(ModalComponent);
5506
- Modal2.confirmation = ModalComponent.confirmation;
5507
- Modal2.destructive = ModalComponent.destructive;
5508
- var Modal_default = Modal2;
4038
+ var Chip2 = (0, import_react16.memo)(ChipComponent);
4039
+ Chip2.colored = ChipComponent.colored;
4040
+ var Chip_default = Chip2;
4041
+
4042
+ // src/components/InputField.tsx
4043
+ var import_react20 = require("react");
4044
+ var import_styled_components11 = __toESM(require("styled-components"));
4045
+
4046
+ // src/constants/countries.ts
4047
+ var countries = [
4048
+ {
4049
+ name: "Afghanistan",
4050
+ code: "AF",
4051
+ timeZone: "Asia/Kabul",
4052
+ phoneNumberExtension: "93"
4053
+ },
4054
+ {
4055
+ name: "\xC5land Islands",
4056
+ code: "AX",
4057
+ timeZone: "Europe/Mariehamn",
4058
+ phoneNumberExtension: "358"
4059
+ },
4060
+ {
4061
+ name: "Albania",
4062
+ code: "AL",
4063
+ timeZone: "Europe/Tirane",
4064
+ phoneNumberExtension: "355"
4065
+ },
4066
+ {
4067
+ name: "Algeria",
4068
+ code: "DZ",
4069
+ timeZone: "Africa/Algiers",
4070
+ phoneNumberExtension: "213"
4071
+ },
4072
+ {
4073
+ name: "United States of America",
4074
+ code: "US",
4075
+ timeZone: "America/New_York",
4076
+ phoneNumberExtension: "1",
4077
+ phoneNumberFormat: "(XXX)XXX-XXXX"
4078
+ },
4079
+ {
4080
+ name: "American Samoa",
4081
+ code: "AS",
4082
+ timeZone: "Pacific/Pago_Pago",
4083
+ phoneNumberExtension: "1",
4084
+ phoneNumberFormat: "(XXX)XXX-XXXX"
4085
+ },
4086
+ {
4087
+ name: "Andorra",
4088
+ code: "AD",
4089
+ timeZone: "Europe/Andorra",
4090
+ phoneNumberExtension: "376"
4091
+ },
4092
+ {
4093
+ name: "Angola",
4094
+ code: "AO",
4095
+ timeZone: "Africa/Luanda",
4096
+ phoneNumberExtension: "244"
4097
+ },
4098
+ {
4099
+ name: "Anguilla",
4100
+ code: "AI",
4101
+ timeZone: "America/Anguilla",
4102
+ phoneNumberExtension: "1",
4103
+ phoneNumberFormat: "(XXX)XXX-XXXX"
4104
+ },
4105
+ {
4106
+ name: "Antarctica",
4107
+ code: "AQ",
4108
+ timeZone: "Antarctica/Casey",
4109
+ phoneNumberExtension: "672"
4110
+ },
4111
+ {
4112
+ name: "Antigua and Barbuda",
4113
+ code: "AG",
4114
+ timeZone: "America/Antigua",
4115
+ phoneNumberExtension: "1",
4116
+ phoneNumberFormat: "(XXX)XXX-XXXX"
4117
+ },
4118
+ {
4119
+ name: "Argentina",
4120
+ code: "AR",
4121
+ timeZone: "America/Argentina/Buenos_Aires",
4122
+ phoneNumberExtension: "54"
4123
+ },
4124
+ {
4125
+ name: "Armenia",
4126
+ code: "AM",
4127
+ timeZone: "Asia/Yerevan",
4128
+ phoneNumberExtension: "374"
4129
+ },
4130
+ {
4131
+ name: "Aruba",
4132
+ code: "AW",
4133
+ timeZone: "America/Aruba",
4134
+ phoneNumberExtension: "297"
4135
+ },
4136
+ {
4137
+ name: "Australia",
4138
+ code: "AU",
4139
+ timeZone: "Australia/Sydney",
4140
+ phoneNumberExtension: "61"
4141
+ },
4142
+ {
4143
+ name: "Austria",
4144
+ code: "AT",
4145
+ timeZone: "Europe/Vienna",
4146
+ phoneNumberExtension: "43"
4147
+ },
4148
+ {
4149
+ name: "Azerbaijan",
4150
+ code: "AZ",
4151
+ timeZone: "Asia/Baku",
4152
+ phoneNumberExtension: "994"
4153
+ },
4154
+ {
4155
+ name: "Bahamas",
4156
+ code: "BS",
4157
+ timeZone: "America/Nassau",
4158
+ phoneNumberExtension: "1",
4159
+ phoneNumberFormat: "(XXX)XXX-XXXX"
4160
+ },
4161
+ {
4162
+ name: "Bahrain",
4163
+ code: "BH",
4164
+ timeZone: "Asia/Bahrain",
4165
+ phoneNumberExtension: "973"
4166
+ },
4167
+ {
4168
+ name: "Bangladesh",
4169
+ code: "BD",
4170
+ timeZone: "Asia/Dhaka",
4171
+ phoneNumberExtension: "880"
4172
+ },
4173
+ {
4174
+ name: "Barbados",
4175
+ code: "BB",
4176
+ timeZone: "America/Barbados",
4177
+ phoneNumberExtension: "1",
4178
+ phoneNumberFormat: "(XXX)XXX-XXXX"
4179
+ },
4180
+ {
4181
+ name: "Belarus",
4182
+ code: "BY",
4183
+ timeZone: "Europe/Minsk",
4184
+ phoneNumberExtension: "375"
4185
+ },
4186
+ {
4187
+ name: "Belgium",
4188
+ code: "BE",
4189
+ timeZone: "Europe/Brussels",
4190
+ phoneNumberExtension: "32"
4191
+ },
4192
+ {
4193
+ name: "Belize",
4194
+ code: "BZ",
4195
+ timeZone: "America/Belize",
4196
+ phoneNumberExtension: "501"
4197
+ },
4198
+ {
4199
+ name: "Benin",
4200
+ code: "BJ",
4201
+ timeZone: "Africa/Porto-Novo",
4202
+ phoneNumberExtension: "229"
4203
+ },
4204
+ {
4205
+ name: "Bermuda",
4206
+ code: "BM",
4207
+ timeZone: "Atlantic/Bermuda",
4208
+ phoneNumberExtension: "1",
4209
+ phoneNumberFormat: "(XXX)XXX-XXXX"
4210
+ },
4211
+ {
4212
+ name: "Bhutan",
4213
+ code: "BT",
4214
+ timeZone: "Asia/Thimphu",
4215
+ phoneNumberExtension: "975"
4216
+ },
4217
+ {
4218
+ name: "Bolivia",
4219
+ code: "BO",
4220
+ timeZone: "America/La_Paz",
4221
+ phoneNumberExtension: "591"
4222
+ },
4223
+ {
4224
+ name: "Bosnia and Herzegovina",
4225
+ code: "BA",
4226
+ timeZone: "Europe/Sarajevo",
4227
+ phoneNumberExtension: "387"
4228
+ },
4229
+ {
4230
+ name: "Botswana",
4231
+ code: "BW",
4232
+ timeZone: "Africa/Gaborone",
4233
+ phoneNumberExtension: "267"
4234
+ },
4235
+ {
4236
+ name: "Bouvet Island",
4237
+ code: "BV",
4238
+ timeZone: "Europe/Oslo",
4239
+ phoneNumberExtension: "47"
4240
+ },
4241
+ {
4242
+ name: "Brazil",
4243
+ code: "BR",
4244
+ timeZone: "America/Sao_Paulo",
4245
+ phoneNumberExtension: "55"
4246
+ },
4247
+ {
4248
+ name: "British Indian Ocean Territory",
4249
+ code: "IO",
4250
+ timeZone: "Indian/Chagos",
4251
+ phoneNumberExtension: "246"
4252
+ },
4253
+ {
4254
+ name: "Brunei Darussalam",
4255
+ code: "BN",
4256
+ timeZone: "Asia/Brunei",
4257
+ phoneNumberExtension: "673"
4258
+ },
4259
+ {
4260
+ name: "Bulgaria",
4261
+ code: "BG",
4262
+ timeZone: "Europe/Sofia",
4263
+ phoneNumberExtension: "359",
4264
+ phoneNumberFormat: "XX XXX XXXX"
4265
+ },
4266
+ {
4267
+ name: "Burkina Faso",
4268
+ code: "BF",
4269
+ timeZone: "Africa/Ouagadougou",
4270
+ phoneNumberExtension: "226"
4271
+ },
4272
+ {
4273
+ name: "Burundi",
4274
+ code: "BI",
4275
+ timeZone: "Africa/Bujumbura",
4276
+ phoneNumberExtension: "257"
4277
+ },
4278
+ {
4279
+ name: "Cambodia",
4280
+ code: "KH",
4281
+ timeZone: "Asia/Phnom_Penh",
4282
+ phoneNumberExtension: "855"
4283
+ },
4284
+ {
4285
+ name: "Cameroon",
4286
+ code: "CM",
4287
+ timeZone: "Africa/Douala",
4288
+ phoneNumberExtension: "237"
4289
+ },
4290
+ {
4291
+ name: "Canada",
4292
+ code: "CA",
4293
+ timeZone: "America/Toronto",
4294
+ phoneNumberExtension: "1",
4295
+ phoneNumberFormat: "(XXX)XXX-XXXX"
4296
+ },
4297
+ {
4298
+ name: "Cape Verde",
4299
+ code: "CV",
4300
+ timeZone: "Atlantic/Cape_Verde",
4301
+ phoneNumberExtension: "238"
4302
+ },
4303
+ {
4304
+ name: "Cayman Islands",
4305
+ code: "KY",
4306
+ timeZone: "America/Cayman",
4307
+ phoneNumberExtension: "1",
4308
+ phoneNumberFormat: "(XXX)XXX-XXXX"
4309
+ },
4310
+ {
4311
+ name: "Central African Republic",
4312
+ code: "CF",
4313
+ timeZone: "Africa/Bangui",
4314
+ phoneNumberExtension: "236"
4315
+ },
4316
+ {
4317
+ name: "Chad",
4318
+ code: "TD",
4319
+ timeZone: "Africa/Ndjamena",
4320
+ phoneNumberExtension: "235"
4321
+ },
4322
+ {
4323
+ name: "Chile",
4324
+ code: "CL",
4325
+ timeZone: "America/Santiago",
4326
+ phoneNumberExtension: "56"
4327
+ },
4328
+ {
4329
+ name: "China",
4330
+ code: "CN",
4331
+ timeZone: "Asia/Shanghai",
4332
+ phoneNumberExtension: "86"
4333
+ },
4334
+ {
4335
+ name: "Christmas Island",
4336
+ code: "CX",
4337
+ timeZone: "Indian/Christmas",
4338
+ phoneNumberExtension: "61"
4339
+ },
4340
+ {
4341
+ name: "Cocos (Keeling) Islands",
4342
+ code: "CC",
4343
+ timeZone: "Indian/Cocos",
4344
+ phoneNumberExtension: "61"
4345
+ },
4346
+ {
4347
+ name: "Colombia",
4348
+ code: "CO",
4349
+ timeZone: "America/Bogota",
4350
+ phoneNumberExtension: "57"
4351
+ },
4352
+ {
4353
+ name: "Comoros",
4354
+ code: "KM",
4355
+ timeZone: "Indian/Comoro",
4356
+ phoneNumberExtension: "269"
4357
+ },
4358
+ {
4359
+ name: "Congo",
4360
+ code: "CG",
4361
+ timeZone: "Africa/Brazzaville",
4362
+ phoneNumberExtension: "242"
4363
+ },
4364
+ {
4365
+ name: "Congo, The Democratic Republic of the",
4366
+ code: "CD",
4367
+ timeZone: "Africa/Kinshasa",
4368
+ phoneNumberExtension: "243"
4369
+ },
4370
+ {
4371
+ name: "Cook Islands",
4372
+ code: "CK",
4373
+ timeZone: "Pacific/Rarotonga",
4374
+ phoneNumberExtension: "682"
4375
+ },
4376
+ {
4377
+ name: "Costa Rica",
4378
+ code: "CR",
4379
+ timeZone: "America/Costa_Rica",
4380
+ phoneNumberExtension: "506"
4381
+ },
4382
+ {
4383
+ name: "Cote D'Ivoire",
4384
+ code: "CI",
4385
+ timeZone: "Africa/Abidjan",
4386
+ phoneNumberExtension: "225"
4387
+ },
4388
+ {
4389
+ name: "Croatia",
4390
+ code: "HR",
4391
+ timeZone: "Europe/Zagreb",
4392
+ phoneNumberExtension: "385"
4393
+ },
4394
+ {
4395
+ name: "Cuba",
4396
+ code: "CU",
4397
+ timeZone: "America/Havana",
4398
+ phoneNumberExtension: "53"
4399
+ },
4400
+ {
4401
+ name: "Cyprus",
4402
+ code: "CY",
4403
+ timeZone: "Asia/Nicosia",
4404
+ phoneNumberExtension: "357"
4405
+ },
4406
+ {
4407
+ name: "Czech Republic",
4408
+ code: "CZ",
4409
+ timeZone: "Europe/Prague",
4410
+ phoneNumberExtension: "420"
4411
+ },
4412
+ {
4413
+ name: "Denmark",
4414
+ code: "DK",
4415
+ timeZone: "Europe/Copenhagen",
4416
+ phoneNumberExtension: "45"
4417
+ },
4418
+ {
4419
+ name: "Djibouti",
4420
+ code: "DJ",
4421
+ timeZone: "Africa/Djibouti",
4422
+ phoneNumberExtension: "253"
4423
+ },
4424
+ {
4425
+ name: "Dominica",
4426
+ code: "DM",
4427
+ timeZone: "America/Dominica",
4428
+ phoneNumberExtension: "1",
4429
+ phoneNumberFormat: "(XXX)XXX-XXXX"
4430
+ },
4431
+ {
4432
+ name: "Dominican Republic",
4433
+ code: "DO",
4434
+ timeZone: "America/Santo_Domingo",
4435
+ phoneNumberExtension: "1",
4436
+ phoneNumberFormat: "(XXX)XXX-XXXX"
4437
+ },
4438
+ {
4439
+ name: "Ecuador",
4440
+ code: "EC",
4441
+ timeZone: "America/Guayaquil",
4442
+ phoneNumberExtension: "593"
4443
+ },
4444
+ {
4445
+ name: "Egypt",
4446
+ code: "EG",
4447
+ timeZone: "Africa/Cairo",
4448
+ phoneNumberExtension: "20"
4449
+ },
4450
+ {
4451
+ name: "El Salvador",
4452
+ code: "SV",
4453
+ timeZone: "America/El_Salvador",
4454
+ phoneNumberExtension: "503"
4455
+ },
4456
+ {
4457
+ name: "Equatorial Guinea",
4458
+ code: "GQ",
4459
+ timeZone: "Africa/Malabo",
4460
+ phoneNumberExtension: "240"
4461
+ },
4462
+ {
4463
+ name: "Eritrea",
4464
+ code: "ER",
4465
+ timeZone: "Africa/Asmara",
4466
+ phoneNumberExtension: "291"
4467
+ },
4468
+ {
4469
+ name: "Estonia",
4470
+ code: "EE",
4471
+ timeZone: "Europe/Tallinn",
4472
+ phoneNumberExtension: "372"
4473
+ },
4474
+ {
4475
+ name: "Ethiopia",
4476
+ code: "ET",
4477
+ timeZone: "Africa/Addis_Ababa",
4478
+ phoneNumberExtension: "251"
4479
+ },
4480
+ {
4481
+ name: "Falkland Islands (Malvinas)",
4482
+ code: "FK",
4483
+ timeZone: "Atlantic/Stanley",
4484
+ phoneNumberExtension: "500"
4485
+ },
4486
+ {
4487
+ name: "Faroe Islands",
4488
+ code: "FO",
4489
+ timeZone: "Atlantic/Faroe",
4490
+ phoneNumberExtension: "298"
4491
+ },
4492
+ {
4493
+ name: "Fiji",
4494
+ code: "FJ",
4495
+ timeZone: "Pacific/Fiji",
4496
+ phoneNumberExtension: "679"
4497
+ },
4498
+ {
4499
+ name: "Finland",
4500
+ code: "FI",
4501
+ timeZone: "Europe/Helsinki",
4502
+ phoneNumberExtension: "358",
4503
+ phoneNumberFormat: "XX XXX XX XX"
4504
+ },
4505
+ {
4506
+ name: "France",
4507
+ code: "FR",
4508
+ timeZone: "Europe/Paris",
4509
+ phoneNumberExtension: "33",
4510
+ phoneNumberFormat: "X XX XX XX XX"
4511
+ },
4512
+ {
4513
+ name: "French Guiana",
4514
+ code: "GF",
4515
+ timeZone: "America/Cayenne",
4516
+ phoneNumberExtension: "594"
4517
+ },
4518
+ {
4519
+ name: "French Polynesia",
4520
+ code: "PF",
4521
+ timeZone: "Pacific/Tahiti",
4522
+ phoneNumberExtension: "689"
4523
+ },
4524
+ {
4525
+ name: "French Southern Territories",
4526
+ code: "TF",
4527
+ timeZone: "Indian/Kerguelen",
4528
+ phoneNumberExtension: "262"
4529
+ },
4530
+ {
4531
+ name: "Gabon",
4532
+ code: "GA",
4533
+ timeZone: "Africa/Libreville",
4534
+ phoneNumberExtension: "241"
4535
+ },
4536
+ {
4537
+ name: "Gambia",
4538
+ code: "GM",
4539
+ timeZone: "Africa/Banjul",
4540
+ phoneNumberExtension: "220"
4541
+ },
4542
+ {
4543
+ name: "Georgia",
4544
+ code: "GE",
4545
+ timeZone: "Asia/Tbilisi",
4546
+ phoneNumberExtension: "995"
4547
+ },
4548
+ {
4549
+ name: "Germany",
4550
+ code: "DE",
4551
+ timeZone: "Europe/Berlin",
4552
+ phoneNumberExtension: "49",
4553
+ phoneNumberFormat: "XXXX XXXXXXX"
4554
+ },
4555
+ {
4556
+ name: "Ghana",
4557
+ code: "GH",
4558
+ timeZone: "Africa/Accra",
4559
+ phoneNumberExtension: "233"
4560
+ },
4561
+ {
4562
+ name: "Gibraltar",
4563
+ code: "GI",
4564
+ timeZone: "Europe/Gibraltar",
4565
+ phoneNumberExtension: "350"
4566
+ },
4567
+ {
4568
+ name: "Greece",
4569
+ code: "GR",
4570
+ timeZone: "Europe/Athens",
4571
+ phoneNumberExtension: "30"
4572
+ },
4573
+ {
4574
+ name: "Greenland",
4575
+ code: "GL",
4576
+ timeZone: "America/Godthab",
4577
+ phoneNumberExtension: "299"
4578
+ },
4579
+ {
4580
+ name: "Grenada",
4581
+ code: "GD",
4582
+ timeZone: "America/Grenada",
4583
+ phoneNumberExtension: "1",
4584
+ phoneNumberFormat: "(XXX)XXX-XXXX"
4585
+ },
4586
+ {
4587
+ name: "Guadeloupe",
4588
+ code: "GP",
4589
+ timeZone: "America/Guadeloupe",
4590
+ phoneNumberExtension: "590"
4591
+ },
4592
+ {
4593
+ name: "Guam",
4594
+ code: "GU",
4595
+ timeZone: "Pacific/Guam",
4596
+ phoneNumberExtension: "1",
4597
+ phoneNumberFormat: "(XXX)XXX-XXXX"
4598
+ },
4599
+ {
4600
+ name: "Guatemala",
4601
+ code: "GT",
4602
+ timeZone: "America/Guatemala",
4603
+ phoneNumberExtension: "502"
4604
+ },
4605
+ {
4606
+ name: "United Kingdom",
4607
+ code: "GB",
4608
+ timeZone: "Europe/London",
4609
+ phoneNumberExtension: "44",
4610
+ phoneNumberFormat: "XX XXXX XXXX"
4611
+ },
4612
+ {
4613
+ name: "Guernsey",
4614
+ code: "GG",
4615
+ timeZone: "Europe/Guernsey",
4616
+ phoneNumberExtension: "44",
4617
+ phoneNumberFormat: "XX XXXX XXXX"
4618
+ },
4619
+ {
4620
+ name: "Guinea",
4621
+ code: "GN",
4622
+ timeZone: "Africa/Conakry",
4623
+ phoneNumberExtension: "224"
4624
+ },
4625
+ {
4626
+ name: "Guinea-Bissau",
4627
+ code: "GW",
4628
+ timeZone: "Africa/Bissau",
4629
+ phoneNumberExtension: "245"
4630
+ },
4631
+ {
4632
+ name: "Guyana",
4633
+ code: "GY",
4634
+ timeZone: "America/Guyana",
4635
+ phoneNumberExtension: "592"
4636
+ },
4637
+ {
4638
+ name: "Haiti",
4639
+ code: "HT",
4640
+ timeZone: "America/Port-au-Prince",
4641
+ phoneNumberExtension: "509"
4642
+ },
4643
+ {
4644
+ name: "Heard Island and Mcdonald Islands",
4645
+ code: "HM",
4646
+ timeZone: "Indian/Kerguelen",
4647
+ phoneNumberExtension: "672"
4648
+ },
4649
+ {
4650
+ name: "Holy See (Vatican City State)",
4651
+ code: "VA",
4652
+ timeZone: "Europe/Vatican",
4653
+ phoneNumberExtension: "379"
4654
+ },
4655
+ {
4656
+ name: "Honduras",
4657
+ code: "HN",
4658
+ timeZone: "America/Tegucigalpa",
4659
+ phoneNumberExtension: "504"
4660
+ },
4661
+ {
4662
+ name: "Hong Kong",
4663
+ code: "HK",
4664
+ timeZone: "Asia/Hong_Kong",
4665
+ phoneNumberExtension: "852"
4666
+ },
4667
+ {
4668
+ name: "Hungary",
4669
+ code: "HU",
4670
+ timeZone: "Europe/Budapest",
4671
+ phoneNumberExtension: "36"
4672
+ },
4673
+ {
4674
+ name: "Iceland",
4675
+ code: "IS",
4676
+ timeZone: "Atlantic/Reykjavik",
4677
+ phoneNumberExtension: "354"
4678
+ },
4679
+ {
4680
+ name: "India",
4681
+ code: "IN",
4682
+ timeZone: "Asia/Kolkata",
4683
+ phoneNumberExtension: "91"
4684
+ },
4685
+ {
4686
+ name: "Indonesia",
4687
+ code: "ID",
4688
+ timeZone: "Asia/Jakarta",
4689
+ phoneNumberExtension: "62"
4690
+ },
4691
+ {
4692
+ name: "Iran, Islamic Republic Of",
4693
+ code: "IR",
4694
+ timeZone: "Asia/Tehran",
4695
+ phoneNumberExtension: "98"
4696
+ },
4697
+ {
4698
+ name: "Iraq",
4699
+ code: "IQ",
4700
+ timeZone: "Asia/Baghdad",
4701
+ phoneNumberExtension: "964"
4702
+ },
4703
+ {
4704
+ name: "Ireland",
4705
+ code: "IE",
4706
+ timeZone: "Europe/Dublin",
4707
+ phoneNumberExtension: "353"
4708
+ },
4709
+ {
4710
+ name: "Israel",
4711
+ code: "IL",
4712
+ timeZone: "Asia/Jerusalem",
4713
+ phoneNumberExtension: "972"
4714
+ },
4715
+ {
4716
+ name: "Italy",
4717
+ code: "IT",
4718
+ timeZone: "Europe/Rome",
4719
+ phoneNumberExtension: "39",
4720
+ phoneNumberFormat: "XXX XXX XXXX"
4721
+ },
4722
+ {
4723
+ name: "Jamaica",
4724
+ code: "JM",
4725
+ timeZone: "America/Jamaica",
4726
+ phoneNumberExtension: "1",
4727
+ phoneNumberFormat: "(XXX)XXX-XXXX"
4728
+ },
4729
+ {
4730
+ name: "Japan",
4731
+ code: "JP",
4732
+ timeZone: "Asia/Tokyo",
4733
+ phoneNumberExtension: "81"
4734
+ },
4735
+ {
4736
+ name: "Jersey",
4737
+ code: "JE",
4738
+ timeZone: "Europe/Jersey",
4739
+ phoneNumberExtension: "44",
4740
+ phoneNumberFormat: "XX XXXX XXXX"
4741
+ },
4742
+ {
4743
+ name: "Jordan",
4744
+ code: "JO",
4745
+ timeZone: "Asia/Amman",
4746
+ phoneNumberExtension: "962"
4747
+ },
4748
+ {
4749
+ name: "Kazakhstan",
4750
+ code: "KZ",
4751
+ timeZone: "Asia/Almaty",
4752
+ phoneNumberExtension: "7"
4753
+ },
4754
+ {
4755
+ name: "Kenya",
4756
+ code: "KE",
4757
+ timeZone: "Africa/Nairobi",
4758
+ phoneNumberExtension: "254"
4759
+ },
4760
+ {
4761
+ name: "Kiribati",
4762
+ code: "KI",
4763
+ timeZone: "Pacific/Tarawa",
4764
+ phoneNumberExtension: "686"
4765
+ },
4766
+ {
4767
+ name: "Korea, Democratic People's Republic of (North Korea)",
4768
+ code: "KP",
4769
+ timeZone: "Asia/Pyongyang",
4770
+ phoneNumberExtension: "850"
4771
+ },
4772
+ {
4773
+ name: "Korea, Republic of (South Korea)",
4774
+ code: "KR",
4775
+ timeZone: "Asia/Seoul",
4776
+ phoneNumberExtension: "82"
4777
+ },
4778
+ {
4779
+ name: "Kuwait",
4780
+ code: "KW",
4781
+ timeZone: "Asia/Kuwait",
4782
+ phoneNumberExtension: "965"
4783
+ },
4784
+ {
4785
+ name: "Kyrgyzstan",
4786
+ code: "KG",
4787
+ timeZone: "Asia/Bishkek",
4788
+ phoneNumberExtension: "996"
4789
+ },
4790
+ {
4791
+ name: "Lao People's Democratic Republic",
4792
+ code: "LA",
4793
+ timeZone: "Asia/Vientiane",
4794
+ phoneNumberExtension: "856"
4795
+ },
4796
+ {
4797
+ name: "Latvia",
4798
+ code: "LV",
4799
+ timeZone: "Europe/Riga",
4800
+ phoneNumberExtension: "371"
4801
+ },
4802
+ {
4803
+ name: "Lebanon",
4804
+ code: "LB",
4805
+ timeZone: "Asia/Beirut",
4806
+ phoneNumberExtension: "961"
4807
+ },
4808
+ {
4809
+ name: "Lesotho",
4810
+ code: "LS",
4811
+ timeZone: "Africa/Maseru",
4812
+ phoneNumberExtension: "266"
4813
+ },
4814
+ {
4815
+ name: "Liberia",
4816
+ code: "LR",
4817
+ timeZone: "Africa/Monrovia",
4818
+ phoneNumberExtension: "231"
4819
+ },
4820
+ {
4821
+ name: "Libyan Arab Jamahiriya",
4822
+ code: "LY",
4823
+ timeZone: "Africa/Tripoli",
4824
+ phoneNumberExtension: "218"
4825
+ },
4826
+ {
4827
+ name: "Liechtenstein",
4828
+ code: "LI",
4829
+ timeZone: "Europe/Vaduz",
4830
+ phoneNumberExtension: "423"
4831
+ },
4832
+ {
4833
+ name: "Lithuania",
4834
+ code: "LT",
4835
+ timeZone: "Europe/Vilnius",
4836
+ phoneNumberExtension: "370"
4837
+ },
4838
+ {
4839
+ name: "Luxembourg",
4840
+ code: "LU",
4841
+ timeZone: "Europe/Luxembourg",
4842
+ phoneNumberExtension: "352"
4843
+ },
4844
+ {
4845
+ name: "Macao",
4846
+ code: "MO",
4847
+ timeZone: "Asia/Macau",
4848
+ phoneNumberExtension: "853"
4849
+ },
4850
+ {
4851
+ name: "Macedonia, The Former Yugoslav Republic of",
4852
+ code: "MK",
4853
+ timeZone: "Europe/Skopje",
4854
+ phoneNumberExtension: "389"
4855
+ },
4856
+ {
4857
+ name: "Madagascar",
4858
+ code: "MG",
4859
+ timeZone: "Indian/Antananarivo",
4860
+ phoneNumberExtension: "261"
4861
+ },
4862
+ {
4863
+ name: "Malawi",
4864
+ code: "MW",
4865
+ timeZone: "Africa/Blantyre",
4866
+ phoneNumberExtension: "265"
4867
+ },
4868
+ {
4869
+ name: "Malaysia",
4870
+ code: "MY",
4871
+ timeZone: "Asia/Kuala_Lumpur",
4872
+ phoneNumberExtension: "60"
4873
+ },
4874
+ {
4875
+ name: "Maldives",
4876
+ code: "MV",
4877
+ timeZone: "Indian/Maldives",
4878
+ phoneNumberExtension: "960"
4879
+ },
4880
+ {
4881
+ name: "Mali",
4882
+ code: "ML",
4883
+ timeZone: "Africa/Bamako",
4884
+ phoneNumberExtension: "223"
4885
+ },
4886
+ {
4887
+ name: "Malta",
4888
+ code: "MT",
4889
+ timeZone: "Europe/Malta",
4890
+ phoneNumberExtension: "356"
4891
+ },
4892
+ {
4893
+ name: "Marshall Islands",
4894
+ code: "MH",
4895
+ timeZone: "Pacific/Majuro",
4896
+ phoneNumberExtension: "692"
4897
+ },
4898
+ {
4899
+ name: "Martinique",
4900
+ code: "MQ",
4901
+ timeZone: "America/Martinique",
4902
+ phoneNumberExtension: "596"
4903
+ },
4904
+ {
4905
+ name: "Mauritania",
4906
+ code: "MR",
4907
+ timeZone: "Africa/Nouakchott",
4908
+ phoneNumberExtension: "222"
4909
+ },
4910
+ {
4911
+ name: "Mauritius",
4912
+ code: "MU",
4913
+ timeZone: "Indian/Mauritius",
4914
+ phoneNumberExtension: "230"
4915
+ },
4916
+ {
4917
+ name: "Mayotte",
4918
+ code: "YT",
4919
+ timeZone: "Indian/Mayotte",
4920
+ phoneNumberExtension: "262"
4921
+ },
4922
+ {
4923
+ name: "Mexico",
4924
+ code: "MX",
4925
+ timeZone: "America/Mexico_City",
4926
+ phoneNumberExtension: "52"
4927
+ },
4928
+ {
4929
+ name: "Micronesia, Federated States of",
4930
+ code: "FM",
4931
+ timeZone: "Pacific/Chuuk",
4932
+ phoneNumberExtension: "691"
4933
+ },
4934
+ {
4935
+ name: "Moldova, Republic of",
4936
+ code: "MD",
4937
+ timeZone: "Europe/Chisinau",
4938
+ phoneNumberExtension: "373"
4939
+ },
4940
+ {
4941
+ name: "Monaco",
4942
+ code: "MC",
4943
+ timeZone: "Europe/Monaco",
4944
+ phoneNumberExtension: "377"
4945
+ },
4946
+ {
4947
+ name: "Mongolia",
4948
+ code: "MN",
4949
+ timeZone: "Asia/Ulaanbaatar",
4950
+ phoneNumberExtension: "976"
4951
+ },
4952
+ {
4953
+ name: "Montserrat",
4954
+ code: "MS",
4955
+ timeZone: "America/Montserrat",
4956
+ phoneNumberExtension: "1",
4957
+ phoneNumberFormat: "(XXX)XXX-XXXX"
4958
+ },
4959
+ {
4960
+ name: "Morocco",
4961
+ code: "MA",
4962
+ timeZone: "Africa/Casablanca",
4963
+ phoneNumberExtension: "212"
4964
+ },
4965
+ {
4966
+ name: "Mozambique",
4967
+ code: "MZ",
4968
+ timeZone: "Africa/Maputo",
4969
+ phoneNumberExtension: "258"
4970
+ },
4971
+ {
4972
+ name: "Myanmar",
4973
+ code: "MM",
4974
+ timeZone: "Asia/Yangon",
4975
+ phoneNumberExtension: "95"
4976
+ },
4977
+ {
4978
+ name: "Namibia",
4979
+ code: "NA",
4980
+ timeZone: "Africa/Windhoek",
4981
+ phoneNumberExtension: "264"
4982
+ },
4983
+ {
4984
+ name: "Nauru",
4985
+ code: "NR",
4986
+ timeZone: "Pacific/Nauru",
4987
+ phoneNumberExtension: "674"
4988
+ },
4989
+ {
4990
+ name: "Nepal",
4991
+ code: "NP",
4992
+ timeZone: "Asia/Kathmandu",
4993
+ phoneNumberExtension: "977"
4994
+ },
4995
+ {
4996
+ name: "Netherlands",
4997
+ code: "NL",
4998
+ timeZone: "Europe/Amsterdam",
4999
+ phoneNumberExtension: "31"
5000
+ },
5001
+ {
5002
+ name: "New Caledonia",
5003
+ code: "NC",
5004
+ timeZone: "Pacific/Noumea",
5005
+ phoneNumberExtension: "687"
5006
+ },
5007
+ {
5008
+ name: "New Zealand",
5009
+ code: "NZ",
5010
+ timeZone: "Pacific/Auckland",
5011
+ phoneNumberExtension: "64"
5012
+ },
5013
+ {
5014
+ name: "Nicaragua",
5015
+ code: "NI",
5016
+ timeZone: "America/Managua",
5017
+ phoneNumberExtension: "505"
5018
+ },
5019
+ {
5020
+ name: "Niger",
5021
+ code: "NE",
5022
+ timeZone: "Africa/Niamey",
5023
+ phoneNumberExtension: "227"
5024
+ },
5025
+ {
5026
+ name: "Nigeria",
5027
+ code: "NG",
5028
+ timeZone: "Africa/Lagos",
5029
+ phoneNumberExtension: "234"
5030
+ },
5031
+ {
5032
+ name: "Niue",
5033
+ code: "NU",
5034
+ timeZone: "Pacific/Niue",
5035
+ phoneNumberExtension: "683"
5036
+ },
5037
+ {
5038
+ name: "Norfolk Island",
5039
+ code: "NF",
5040
+ timeZone: "Pacific/Norfolk",
5041
+ phoneNumberExtension: "672"
5042
+ },
5043
+ {
5044
+ name: "Northern Mariana Islands",
5045
+ code: "MP",
5046
+ timeZone: "Pacific/Saipan",
5047
+ phoneNumberExtension: "1",
5048
+ phoneNumberFormat: "(XXX)XXX-XXXX"
5049
+ },
5050
+ {
5051
+ name: "Norway",
5052
+ code: "NO",
5053
+ timeZone: "Europe/Oslo",
5054
+ phoneNumberExtension: "47"
5055
+ },
5056
+ {
5057
+ name: "Oman",
5058
+ code: "OM",
5059
+ timeZone: "Asia/Muscat",
5060
+ phoneNumberExtension: "968"
5061
+ },
5062
+ {
5063
+ name: "Pakistan",
5064
+ code: "PK",
5065
+ timeZone: "Asia/Karachi",
5066
+ phoneNumberExtension: "92"
5067
+ },
5068
+ {
5069
+ name: "Palau",
5070
+ code: "PW",
5071
+ timeZone: "Pacific/Palau",
5072
+ phoneNumberExtension: "680"
5073
+ },
5074
+ {
5075
+ name: "Palestinian Territory, Occupied",
5076
+ code: "PS",
5077
+ timeZone: "Asia/Hebron",
5078
+ phoneNumberExtension: "970"
5079
+ },
5080
+ {
5081
+ name: "Panama",
5082
+ code: "PA",
5083
+ timeZone: "America/Panama",
5084
+ phoneNumberExtension: "507"
5085
+ },
5086
+ {
5087
+ name: "Papua New Guinea",
5088
+ code: "PG",
5089
+ timeZone: "Pacific/Port_Moresby",
5090
+ phoneNumberExtension: "675"
5091
+ },
5092
+ {
5093
+ name: "Paraguay",
5094
+ code: "PY",
5095
+ timeZone: "America/Asuncion",
5096
+ phoneNumberExtension: "595"
5097
+ },
5098
+ {
5099
+ name: "Peru",
5100
+ code: "PE",
5101
+ timeZone: "America/Lima",
5102
+ phoneNumberExtension: "51"
5103
+ },
5104
+ {
5105
+ name: "Philippines",
5106
+ code: "PH",
5107
+ timeZone: "Asia/Manila",
5108
+ phoneNumberExtension: "63"
5109
+ },
5110
+ {
5111
+ name: "Pitcairn",
5112
+ code: "PN",
5113
+ timeZone: "Pacific/Pitcairn",
5114
+ phoneNumberExtension: "64"
5115
+ },
5116
+ {
5117
+ name: "Poland",
5118
+ code: "PL",
5119
+ timeZone: "Europe/Warsaw",
5120
+ phoneNumberExtension: "48"
5121
+ },
5122
+ {
5123
+ name: "Portugal",
5124
+ code: "PT",
5125
+ timeZone: "Europe/Lisbon",
5126
+ phoneNumberExtension: "351"
5127
+ },
5128
+ {
5129
+ name: "Puerto Rico",
5130
+ code: "PR",
5131
+ timeZone: "America/Puerto_Rico",
5132
+ phoneNumberExtension: "1",
5133
+ phoneNumberFormat: "(XXX)XXX-XXXX"
5134
+ },
5135
+ {
5136
+ name: "Qatar",
5137
+ code: "QA",
5138
+ timeZone: "Asia/Qatar",
5139
+ phoneNumberExtension: "974"
5140
+ },
5141
+ {
5142
+ name: "Reunion",
5143
+ code: "RE",
5144
+ timeZone: "Indian/Reunion",
5145
+ phoneNumberExtension: "262"
5146
+ },
5147
+ {
5148
+ name: "Romania",
5149
+ code: "RO",
5150
+ timeZone: "Europe/Bucharest",
5151
+ phoneNumberExtension: "40"
5152
+ },
5153
+ {
5154
+ name: "Russian Federation",
5155
+ code: "RU",
5156
+ timeZone: "Europe/Moscow",
5157
+ phoneNumberExtension: "7"
5158
+ },
5159
+ {
5160
+ name: "RWANDA",
5161
+ code: "RW",
5162
+ timeZone: "Africa/Kigali",
5163
+ phoneNumberExtension: "250"
5164
+ },
5165
+ {
5166
+ name: "Saint Helena",
5167
+ code: "SH",
5168
+ timeZone: "Atlantic/St_Helena",
5169
+ phoneNumberExtension: "290"
5170
+ },
5171
+ {
5172
+ name: "Saint Kitts and Nevis",
5173
+ code: "KN",
5174
+ timeZone: "America/St_Kitts",
5175
+ phoneNumberExtension: "1",
5176
+ phoneNumberFormat: "(XXX)XXX-XXXX"
5177
+ },
5178
+ {
5179
+ name: "Saint Lucia",
5180
+ code: "LC",
5181
+ timeZone: "America/St_Lucia",
5182
+ phoneNumberExtension: "1",
5183
+ phoneNumberFormat: "(XXX)XXX-XXXX"
5184
+ },
5185
+ {
5186
+ name: "Saint Pierre and Miquelon",
5187
+ code: "PM",
5188
+ timeZone: "America/Miquelon",
5189
+ phoneNumberExtension: "508"
5190
+ },
5191
+ {
5192
+ name: "Saint Vincent and the Grenadines",
5193
+ code: "VC",
5194
+ timeZone: "America/St_Vincent",
5195
+ phoneNumberExtension: "1",
5196
+ phoneNumberFormat: "(XXX)XXX-XXXX"
5197
+ },
5198
+ {
5199
+ name: "Samoa",
5200
+ code: "WS",
5201
+ timeZone: "Pacific/Apia",
5202
+ phoneNumberExtension: "685"
5203
+ },
5204
+ {
5205
+ name: "San Marino",
5206
+ code: "SM",
5207
+ timeZone: "Europe/San_Marino",
5208
+ phoneNumberExtension: "378"
5209
+ },
5210
+ {
5211
+ name: "Sao Tome and Principe",
5212
+ code: "ST",
5213
+ timeZone: "Africa/Sao_Tome",
5214
+ phoneNumberExtension: "239"
5215
+ },
5216
+ {
5217
+ name: "Saudi Arabia",
5218
+ code: "SA",
5219
+ timeZone: "Asia/Riyadh",
5220
+ phoneNumberExtension: "966"
5221
+ },
5222
+ {
5223
+ name: "Senegal",
5224
+ code: "SN",
5225
+ timeZone: "Africa/Dakar",
5226
+ phoneNumberExtension: "221"
5227
+ },
5228
+ {
5229
+ name: "Republic of Serbia",
5230
+ code: "RS",
5231
+ timeZone: "Europe/Belgrade",
5232
+ phoneNumberExtension: "381"
5233
+ },
5234
+ {
5235
+ name: "Seychelles",
5236
+ code: "SC",
5237
+ timeZone: "Indian/Mahe",
5238
+ phoneNumberExtension: "248"
5239
+ },
5240
+ {
5241
+ name: "Sierra Leone",
5242
+ code: "SL",
5243
+ timeZone: "Africa/Freetown",
5244
+ phoneNumberExtension: "232"
5245
+ },
5246
+ {
5247
+ name: "Singapore",
5248
+ code: "SG",
5249
+ timeZone: "Asia/Singapore",
5250
+ phoneNumberExtension: "65"
5251
+ },
5252
+ {
5253
+ name: "Slovakia",
5254
+ code: "SK",
5255
+ timeZone: "Europe/Bratislava",
5256
+ phoneNumberExtension: "421"
5257
+ },
5258
+ {
5259
+ name: "Slovenia",
5260
+ code: "SI",
5261
+ timeZone: "Europe/Ljubljana",
5262
+ phoneNumberExtension: "386"
5263
+ },
5264
+ {
5265
+ name: "Solomon Islands",
5266
+ code: "SB",
5267
+ timeZone: "Pacific/Guadalcanal",
5268
+ phoneNumberExtension: "677"
5269
+ },
5270
+ {
5271
+ name: "Somalia",
5272
+ code: "SO",
5273
+ timeZone: "Africa/Mogadishu",
5274
+ phoneNumberExtension: "252"
5275
+ },
5276
+ {
5277
+ name: "South Africa",
5278
+ code: "ZA",
5279
+ timeZone: "Africa/Johannesburg",
5280
+ phoneNumberExtension: "27"
5281
+ },
5282
+ {
5283
+ name: "South Georgia and the South Sandwich Islands",
5284
+ code: "GS",
5285
+ timeZone: "Atlantic/South_Georgia",
5286
+ phoneNumberExtension: "500"
5287
+ },
5288
+ {
5289
+ name: "Spain",
5290
+ code: "ES",
5291
+ timeZone: "Europe/Madrid",
5292
+ phoneNumberExtension: "34"
5293
+ },
5294
+ {
5295
+ name: "Sri Lanka",
5296
+ code: "LK",
5297
+ timeZone: "Asia/Colombo",
5298
+ phoneNumberExtension: "94"
5299
+ },
5300
+ {
5301
+ name: "Sudan",
5302
+ code: "SD",
5303
+ timeZone: "Africa/Khartoum",
5304
+ phoneNumberExtension: "249"
5305
+ },
5306
+ {
5307
+ name: "Suriname",
5308
+ code: "SR",
5309
+ timeZone: "America/Paramaribo",
5310
+ phoneNumberExtension: "597"
5311
+ },
5312
+ {
5313
+ name: "Svalbard and Jan Mayen",
5314
+ code: "SJ",
5315
+ timeZone: "Arctic/Longyearbyen",
5316
+ phoneNumberExtension: "47"
5317
+ },
5318
+ {
5319
+ name: "Swaziland",
5320
+ code: "SZ",
5321
+ timeZone: "Africa/Mbabane",
5322
+ phoneNumberExtension: "268"
5323
+ },
5324
+ {
5325
+ name: "Sweden",
5326
+ code: "SE",
5327
+ timeZone: "Europe/Stockholm",
5328
+ phoneNumberExtension: "46"
5329
+ },
5330
+ {
5331
+ name: "Switzerland",
5332
+ code: "CH",
5333
+ timeZone: "Europe/Zurich",
5334
+ phoneNumberExtension: "41"
5335
+ },
5336
+ {
5337
+ name: "Syrian Arab Republic",
5338
+ code: "SY",
5339
+ timeZone: "Asia/Damascus",
5340
+ phoneNumberExtension: "963"
5341
+ },
5342
+ {
5343
+ name: "Taiwan, Province of China",
5344
+ code: "TW",
5345
+ timeZone: "Asia/Taipei",
5346
+ phoneNumberExtension: "886"
5347
+ },
5348
+ {
5349
+ name: "Tajikistan",
5350
+ code: "TJ",
5351
+ timeZone: "Asia/Dushanbe",
5352
+ phoneNumberExtension: "992"
5353
+ },
5354
+ {
5355
+ name: "Tanzania, United Republic of",
5356
+ code: "TZ",
5357
+ timeZone: "Africa/Dar_es_Salaam",
5358
+ phoneNumberExtension: "255"
5359
+ },
5360
+ {
5361
+ name: "Thailand",
5362
+ code: "TH",
5363
+ timeZone: "Asia/Bangkok",
5364
+ phoneNumberExtension: "66"
5365
+ },
5366
+ {
5367
+ name: "Timor-Leste",
5368
+ code: "TL",
5369
+ timeZone: "Asia/Dili",
5370
+ phoneNumberExtension: "670"
5371
+ },
5372
+ {
5373
+ name: "Togo",
5374
+ code: "TG",
5375
+ timeZone: "Africa/Lome",
5376
+ phoneNumberExtension: "228"
5377
+ },
5378
+ {
5379
+ name: "Tokelau",
5380
+ code: "TK",
5381
+ timeZone: "Pacific/Fakaofo",
5382
+ phoneNumberExtension: "690"
5383
+ },
5384
+ {
5385
+ name: "Tonga",
5386
+ code: "TO",
5387
+ timeZone: "Pacific/Tongatapu",
5388
+ phoneNumberExtension: "676"
5389
+ },
5390
+ {
5391
+ name: "Trinidad and Tobago",
5392
+ code: "TT",
5393
+ timeZone: "America/Port_of_Spain",
5394
+ phoneNumberExtension: "1",
5395
+ phoneNumberFormat: "(XXX)XXX-XXXX"
5396
+ },
5397
+ {
5398
+ name: "Tunisia",
5399
+ code: "TN",
5400
+ timeZone: "Africa/Tunis",
5401
+ phoneNumberExtension: "216"
5402
+ },
5403
+ {
5404
+ name: "Turkey",
5405
+ code: "TR",
5406
+ timeZone: "Europe/Istanbul",
5407
+ phoneNumberExtension: "90"
5408
+ },
5409
+ {
5410
+ name: "Turkmenistan",
5411
+ code: "TM",
5412
+ timeZone: "Asia/Ashgabat",
5413
+ phoneNumberExtension: "993"
5414
+ },
5415
+ {
5416
+ name: "Turks and Caicos Islands",
5417
+ code: "TC",
5418
+ timeZone: "America/Grand_Turk",
5419
+ phoneNumberExtension: "1",
5420
+ phoneNumberFormat: "(XXX)XXX-XXXX"
5421
+ },
5422
+ {
5423
+ name: "Tuvalu",
5424
+ code: "TV",
5425
+ timeZone: "Pacific/Funafuti",
5426
+ phoneNumberExtension: "688"
5427
+ },
5428
+ {
5429
+ name: "Uganda",
5430
+ code: "UG",
5431
+ timeZone: "Africa/Kampala",
5432
+ phoneNumberExtension: "256"
5433
+ },
5434
+ {
5435
+ name: "Ukraine",
5436
+ code: "UA",
5437
+ timeZone: "Europe/Kiev",
5438
+ phoneNumberExtension: "380"
5439
+ },
5440
+ {
5441
+ name: "United Arab Emirates",
5442
+ code: "AE",
5443
+ timeZone: "Asia/Dubai",
5444
+ phoneNumberExtension: "971"
5445
+ },
5446
+ {
5447
+ name: "United States Minor Outlying Islands",
5448
+ code: "UM",
5449
+ timeZone: "Pacific/Midway",
5450
+ phoneNumberExtension: "1",
5451
+ phoneNumberFormat: "(XXX)XXX-XXXX"
5452
+ },
5453
+ {
5454
+ name: "Uruguay",
5455
+ code: "UY",
5456
+ timeZone: "America/Montevideo",
5457
+ phoneNumberExtension: "598"
5458
+ },
5459
+ {
5460
+ name: "Uzbekistan",
5461
+ code: "UZ",
5462
+ timeZone: "Asia/Tashkent",
5463
+ phoneNumberExtension: "998"
5464
+ },
5465
+ {
5466
+ name: "Vanuatu",
5467
+ code: "VU",
5468
+ timeZone: "Pacific/Efate",
5469
+ phoneNumberExtension: "678"
5470
+ },
5471
+ {
5472
+ name: "Venezuela",
5473
+ code: "VE",
5474
+ timeZone: "America/Caracas",
5475
+ phoneNumberExtension: "58"
5476
+ },
5477
+ {
5478
+ name: "Viet Nam",
5479
+ code: "VN",
5480
+ timeZone: "Asia/Ho_Chi_Minh",
5481
+ phoneNumberExtension: "84"
5482
+ },
5483
+ {
5484
+ name: "Virgin Islands, British",
5485
+ code: "VG",
5486
+ timeZone: "America/Tortola",
5487
+ phoneNumberExtension: "1",
5488
+ phoneNumberFormat: "(XXX)XXX-XXXX"
5489
+ },
5490
+ {
5491
+ name: "Virgin Islands, U.S.",
5492
+ code: "VI",
5493
+ timeZone: "America/St_Thomas",
5494
+ phoneNumberExtension: "1",
5495
+ phoneNumberFormat: "(XXX)XXX-XXXX"
5496
+ },
5497
+ {
5498
+ name: "Wallis and Futuna",
5499
+ code: "WF",
5500
+ timeZone: "Pacific/Wallis",
5501
+ phoneNumberExtension: "681"
5502
+ },
5503
+ {
5504
+ name: "Western Sahara",
5505
+ code: "EH",
5506
+ timeZone: "Africa/El_Aaiun",
5507
+ phoneNumberExtension: "212"
5508
+ },
5509
+ {
5510
+ name: "Yemen",
5511
+ code: "YE",
5512
+ timeZone: "Asia/Aden",
5513
+ phoneNumberExtension: "967"
5514
+ },
5515
+ {
5516
+ name: "Zambia",
5517
+ code: "ZM",
5518
+ timeZone: "Africa/Lusaka",
5519
+ phoneNumberExtension: "260"
5520
+ },
5521
+ {
5522
+ name: "Zimbabwe",
5523
+ code: "ZW",
5524
+ timeZone: "Africa/Harare",
5525
+ phoneNumberExtension: "263"
5526
+ }
5527
+ ];
5509
5528
 
5510
- // src/components/PageHolder.tsx
5511
- var import_react15 = require("react");
5512
- var import_jsx_runtime13 = require("react/jsx-runtime");
5513
- var PageHolderComponent = (0, import_react15.forwardRef)(function PageHolder({ noMaxContentWidth, children, ...props }, ref) {
5514
- const theme2 = useTheme();
5515
- const { app } = useBetterHtmlContextInternal();
5516
- return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
5517
- Div_default,
5518
- {
5519
- as: "main",
5520
- width: "100%",
5521
- maxWidth: !noMaxContentWidth ? app.contentMaxWidth : void 0,
5522
- margin: "0px auto",
5523
- padding: theme2.styles.space,
5524
- ...props,
5525
- ref,
5526
- children
5527
- }
5528
- );
5529
- });
5530
- PageHolderComponent.center = (0, import_react15.forwardRef)(function Center({
5531
- pageBackgroundColor,
5532
- pageBackgroundImage,
5533
- contentMaxWidth,
5534
- behindComponent,
5535
- sideComponent,
5536
- sideComponentPosition = "right",
5537
- noMaxContentWidth,
5538
- children,
5539
- ...props
5540
- }, ref) {
5541
- const theme2 = useTheme();
5542
- const mediaQuery = useMediaQuery();
5543
- const { app } = useBetterHtmlContextInternal();
5544
- const breakingPoint = mediaQuery.size1000;
5545
- const withSideComponent = sideComponent && !breakingPoint;
5546
- return /* @__PURE__ */ (0, import_jsx_runtime13.jsxs)(
5547
- Div_default.row,
5548
- {
5549
- position: "relative",
5550
- width: "100%",
5551
- minHeight: "100svh",
5552
- alignItems: "center",
5553
- justifyContent: "center",
5554
- backgroundColor: pageBackgroundColor,
5555
- backgroundImage: pageBackgroundImage,
5556
- children: [
5557
- behindComponent && /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
5558
- Div_default,
5559
- {
5560
- position: "fixed",
5561
- width: `${withSideComponent ? 50 : 100}%`,
5562
- height: "100svh",
5563
- top: 0,
5564
- left: sideComponentPosition === "right" ? 0 : "auto",
5565
- right: sideComponentPosition === "left" ? 0 : "auto",
5566
- zIndex: 1,
5567
- children: behindComponent
5568
- }
5569
- ),
5570
- sideComponentPosition === "left" && withSideComponent && /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(Div_default, { width: "50%" }),
5571
- /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(Div_default.column, { position: "relative", width: `${withSideComponent ? 50 : 100}%`, alignItems: "center", zIndex: 2, children: /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
5572
- Div_default.box,
5573
- {
5574
- width: `calc(100% - ${theme2.styles.space * 2}px)`,
5575
- maxWidth: !noMaxContentWidth ? contentMaxWidth ?? app.contentMaxWidth / 2 : void 0,
5576
- marginInline: theme2.styles.space,
5577
- marginBlock: theme2.styles.space,
5578
- ...props,
5579
- ref,
5580
- children
5581
- }
5582
- ) }),
5583
- sideComponentPosition === "right" && withSideComponent && /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(Div_default, { width: "50%" }),
5584
- withSideComponent && /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
5585
- Div_default,
5586
- {
5587
- position: "fixed",
5588
- width: "50%",
5589
- height: "100svh",
5590
- top: 0,
5591
- left: sideComponentPosition === "left" ? 0 : "auto",
5592
- right: sideComponentPosition === "right" ? 0 : "auto",
5593
- children: sideComponent
5594
- }
5595
- )
5596
- ]
5597
- }
5598
- );
5599
- });
5600
- var PageHolder2 = (0, import_react15.memo)(PageHolderComponent);
5601
- PageHolder2.center = PageHolderComponent.center;
5602
- var PageHolder_default = PageHolder2;
5529
+ // src/utils/functions.ts
5530
+ var import_crypto_js = __toESM(require("crypto-js"));
5603
5531
 
5604
- // src/components/Chip.tsx
5605
- var import_react16 = require("react");
5532
+ // src/utils/variableFunctions.ts
5533
+ var checkBetterHtmlContextValue = (value, functionsName) => {
5534
+ if (value === void 0) {
5535
+ throw new Error(
5536
+ `\`${functionsName}()\` must be used within a \`<BetterHtmlProvider>\`. Make sure to add one at the root of your component tree.`
5537
+ );
5538
+ }
5539
+ return value !== void 0;
5540
+ };
5541
+ var loaderControls = {
5542
+ startLoading: (loaderName) => {
5543
+ if (!checkBetterHtmlContextValue(externalBetterHtmlContextValue, "loaderControls.startLoading")) return;
5544
+ externalBetterHtmlContextValue.setLoaders((oldValue) => ({
5545
+ ...oldValue,
5546
+ [loaderName.toString()]: true
5547
+ }));
5548
+ },
5549
+ stopLoading: (loaderName) => {
5550
+ if (!checkBetterHtmlContextValue(externalBetterHtmlContextValue, "loaderControls.stopLoading")) return;
5551
+ externalBetterHtmlContextValue.setLoaders((oldValue) => ({
5552
+ ...oldValue,
5553
+ [loaderName.toString()]: false
5554
+ }));
5555
+ }
5556
+ };
5557
+ var alertControls = {
5558
+ createAlert: (alert) => {
5559
+ if (!checkBetterHtmlContextValue(externalBetterHtmlContextValue, "alertControls.createAlert"))
5560
+ return void 0;
5561
+ const readyAlert = {
5562
+ id: crypto.randomUUID(),
5563
+ ...alert
5564
+ };
5565
+ externalBetterHtmlContextValue.setAlerts((oldValue) => [...oldValue, readyAlert]);
5566
+ return readyAlert;
5567
+ },
5568
+ removeAlert: (alertId) => {
5569
+ if (!checkBetterHtmlContextValue(externalBetterHtmlContextValue, "alertControls.removeAlert")) return;
5570
+ externalBetterHtmlContextValue.setAlerts((oldValue) => oldValue.filter((alert) => alert.id !== alertId));
5571
+ }
5572
+ };
5573
+ var colorThemeControls = {
5574
+ toggleTheme: (theme2) => {
5575
+ if (!checkBetterHtmlContextValue(externalBetterHtmlContextValue, "colorThemeControls.toggleTheme")) return;
5576
+ const currentColorTheme = externalBetterHtmlContextValue.colorTheme;
5577
+ const newColorTheme = theme2 ?? (currentColorTheme === "dark" ? "light" : "dark");
5578
+ setTimeout(() => {
5579
+ window.document.body.parentElement?.setAttribute("data-theme", newColorTheme);
5580
+ localStorage.setItem("theme", newColorTheme);
5581
+ }, 0.01 * 1e3);
5582
+ }
5583
+ };
5584
+ var filterHover = () => {
5585
+ if (!checkBetterHtmlContextValue(externalBetterHtmlContextValue, "filterHover")) return void 0;
5586
+ return {
5587
+ z05: externalBetterHtmlContextValue.colorTheme === "dark" ? "brightness(1.2)" : "brightness(0.95)",
5588
+ z1: externalBetterHtmlContextValue.colorTheme === "dark" ? "brightness(1.3)" : "brightness(0.9)",
5589
+ z2: externalBetterHtmlContextValue.colorTheme === "dark" ? "brightness(1.6)" : "brightness(0.8)",
5590
+ z3: externalBetterHtmlContextValue.colorTheme === "dark" ? "brightness(1.9)" : "brightness(0.7)"
5591
+ };
5592
+ };
5606
5593
 
5607
- // src/utils/colorManipulation.ts
5608
- var rgbToHsl = (r, g, b) => {
5609
- r /= 255;
5610
- g /= 255;
5611
- b /= 255;
5612
- const max = Math.max(r, g, b);
5613
- const min = Math.min(r, g, b);
5614
- let h = 0;
5615
- let s = 0;
5616
- const l = (max + min) / 2;
5617
- if (max !== min) {
5618
- const d = max - min;
5619
- s = l > 0.5 ? d / (2 - max - min) : d / (max + min);
5620
- switch (max) {
5621
- case r:
5622
- h = (g - b) / d + (g < b ? 6 : 0);
5623
- break;
5624
- case g:
5625
- h = (b - r) / d + 2;
5626
- break;
5627
- case b:
5628
- h = (r - g) / d + 4;
5629
- break;
5594
+ // src/utils/functions.ts
5595
+ var generateRandomString = (stringLength, options) => {
5596
+ const capitals = "ABCDEFGHIJKLMNOPQRSTUVWXYZ";
5597
+ const lowers = "abcdefghijklmnopqrstuvwxyz";
5598
+ const numbers = "0123456789";
5599
+ const includes = [];
5600
+ if (options?.includeCapitalLetters !== false) includes.push(capitals);
5601
+ if (options?.includeLowerLetters !== false) includes.push(lowers);
5602
+ if (options?.includeNumbers !== false) includes.push(numbers);
5603
+ const characters = includes.join("");
5604
+ const dashSections = Math.max(1, options?.dashSections ?? 1);
5605
+ const dashSectionLength = Math.floor(stringLength / dashSections);
5606
+ if (stringLength < dashSections) return "";
5607
+ let result = "";
5608
+ let currentSectionLength = 0;
5609
+ while (result.length < stringLength) {
5610
+ if (currentSectionLength >= dashSectionLength) {
5611
+ result += "-";
5612
+ currentSectionLength = 0;
5613
+ }
5614
+ if (result.length < stringLength) {
5615
+ result += characters.charAt(Math.floor(Math.random() * characters.length));
5616
+ currentSectionLength += 1;
5630
5617
  }
5631
- h /= 6;
5632
5618
  }
5633
- return [h, s, l];
5619
+ return result;
5634
5620
  };
5635
- var hslToRgb = (h, s, l) => {
5636
- let r, g, b;
5637
- if (s === 0) {
5638
- r = g = b = l;
5639
- } else {
5640
- const hue2rgb = (p2, q2, t) => {
5641
- if (t < 0) t += 1;
5642
- if (t > 1) t -= 1;
5643
- if (t < 1 / 6) return p2 + (q2 - p2) * 6 * t;
5644
- if (t < 1 / 2) return q2;
5645
- if (t < 2 / 3) return p2 + (q2 - p2) * (2 / 3 - t) * 6;
5646
- return p2;
5647
- };
5648
- const q = l < 0.5 ? l * (1 + s) : l + s - l * s;
5649
- const p = 2 * l - q;
5650
- r = hue2rgb(p, q, h + 1 / 3);
5651
- g = hue2rgb(p, q, h);
5652
- b = hue2rgb(p, q, h - 1 / 3);
5653
- }
5654
- return [Math.round(r * 255), Math.round(g * 255), Math.round(b * 255)];
5621
+ var getBrowser = () => {
5622
+ const userAgent = navigator.userAgent.toLowerCase();
5623
+ if (userAgent.includes("firefox")) return "firefox";
5624
+ if (userAgent.includes("chrome") && !userAgent.includes("edg")) return "chrome";
5625
+ if (userAgent.includes("safari") && !userAgent.includes("chrome")) return "safari";
5626
+ if (userAgent.includes("edg")) return "edge";
5627
+ if (userAgent.includes("opr") || userAgent.includes("opera")) return "opera";
5628
+ return;
5655
5629
  };
5656
- var lightenColor = (hexColor, amount) => {
5657
- let hex = hexColor.replace(/^#/, "");
5658
- if (hex.length === 3) {
5659
- hex = hex[0] + hex[0] + hex[1] + hex[1] + hex[2] + hex[2];
5630
+ var formatPhoneNumber = (phoneNumber) => {
5631
+ const cleanPhoneNumber = phoneNumber.replace(/\D/g, "");
5632
+ const country = countries.find(
5633
+ (country2) => country2.phoneNumberExtension === cleanPhoneNumber.slice(0, country2.phoneNumberExtension.length)
5634
+ );
5635
+ if (!country) return phoneNumber;
5636
+ let phonNumberRest = cleanPhoneNumber.slice(country.phoneNumberExtension.length);
5637
+ if (country.phoneNumberFormat) {
5638
+ let formattedNumber = "";
5639
+ let index = 0;
5640
+ for (const char of country.phoneNumberFormat) {
5641
+ if (char === "X" && index < phonNumberRest.length) {
5642
+ formattedNumber += phonNumberRest[index];
5643
+ index++;
5644
+ } else {
5645
+ formattedNumber += char;
5646
+ }
5647
+ }
5648
+ phonNumberRest = formattedNumber.replace(/X/g, "").trim();
5660
5649
  }
5661
- const safeAmount = Math.max(0, Math.min(1, amount));
5662
- const r = parseInt(hex.substring(0, 2), 16);
5663
- const g = parseInt(hex.substring(2, 4), 16);
5664
- const b = parseInt(hex.substring(4, 6), 16);
5665
- const lightenComponent = (component) => {
5666
- return Math.round(component + (255 - component) * safeAmount);
5667
- };
5668
- const rHex = lightenComponent(r).toString(16).padStart(2, "0");
5669
- const gHex = lightenComponent(g).toString(16).padStart(2, "0");
5670
- const bHex = lightenComponent(b).toString(16).padStart(2, "0");
5671
- return `#${rHex}${gHex}${bHex}`;
5650
+ return `+${country.phoneNumberExtension} ${phonNumberRest}`;
5672
5651
  };
5673
- var darkenColor = (hexColor, amount) => {
5674
- let hex = hexColor.replace(/^#/, "");
5675
- if (hex.length === 3) {
5676
- hex = hex[0] + hex[0] + hex[1] + hex[1] + hex[2] + hex[2];
5677
- }
5678
- const safeAmount = Math.max(0, Math.min(1, amount));
5679
- const r = parseInt(hex.substring(0, 2), 16);
5680
- const g = parseInt(hex.substring(2, 4), 16);
5681
- const b = parseInt(hex.substring(4, 6), 16);
5682
- const darkenComponent = (component) => {
5683
- return Math.round(component * (1 - safeAmount));
5684
- };
5685
- const rHex = darkenComponent(r).toString(16).padStart(2, "0");
5686
- const gHex = darkenComponent(g).toString(16).padStart(2, "0");
5687
- const bHex = darkenComponent(b).toString(16).padStart(2, "0");
5688
- return `#${rHex}${gHex}${bHex}`;
5652
+ var getFormErrorObject = (formValues) => {
5653
+ return {};
5689
5654
  };
5690
- var saturateColor = (hexColor, amount) => {
5691
- let hex = hexColor.replace(/^#/, "");
5692
- if (hex.length === 3) {
5693
- hex = hex[0] + hex[0] + hex[1] + hex[1] + hex[2] + hex[2];
5655
+ var eventPreventDefault = (event) => {
5656
+ event.preventDefault();
5657
+ };
5658
+ var eventStopPropagation = (event) => {
5659
+ event.stopPropagation();
5660
+ };
5661
+ var eventPreventStop = (event) => {
5662
+ event.preventDefault();
5663
+ event.stopPropagation();
5664
+ };
5665
+ var encryptString = (text) => {
5666
+ if (!checkBetterHtmlContextValue(externalBetterHtmlContextValue, "encryptString")) return void 0;
5667
+ const localStoragePlugin2 = externalBetterHtmlContextValue.plugins.find((plugin) => plugin.name === "localStorage");
5668
+ if (!localStoragePlugin2) {
5669
+ throw new Error(
5670
+ "`encryptString` hook requires the `localStorage` plugin to be added to the `plugins` prop in `<BetterHtmlProvider>`."
5671
+ );
5694
5672
  }
5695
- const safeAmount = Math.max(0, Math.min(1, amount));
5696
- const r = parseInt(hex.substring(0, 2), 16);
5697
- const g = parseInt(hex.substring(2, 4), 16);
5698
- const b = parseInt(hex.substring(4, 6), 16);
5699
- const [h, s, l] = rgbToHsl(r, g, b);
5700
- const newSaturation = Math.min(1, s + safeAmount * (1 - s));
5701
- const [newR, newG, newB] = hslToRgb(h, newSaturation, l);
5702
- const rHex = Math.round(newR).toString(16).padStart(2, "0");
5703
- const gHex = Math.round(newG).toString(16).padStart(2, "0");
5704
- const bHex = Math.round(newB).toString(16).padStart(2, "0");
5705
- return `#${rHex}${gHex}${bHex}`;
5673
+ const pluginConfig = localStoragePlugin2.getConfig();
5674
+ if (!pluginConfig.encryption?.enabled) return text;
5675
+ const encrypted = import_crypto_js.default.AES.encrypt(text, import_crypto_js.default.enc.Hex.parse(pluginConfig.encryption.secretKey), {
5676
+ iv: import_crypto_js.default.enc.Hex.parse(pluginConfig.encryption.iv),
5677
+ mode: import_crypto_js.default.mode.CBC,
5678
+ padding: import_crypto_js.default.pad.Pkcs7
5679
+ }).toString();
5680
+ return encrypted;
5706
5681
  };
5707
- var desaturateColor = (hexColor, amount) => {
5708
- let hex = hexColor.replace(/^#/, "");
5709
- if (hex.length === 3) {
5710
- hex = hex[0] + hex[0] + hex[1] + hex[1] + hex[2] + hex[2];
5682
+ var decryptString = (text) => {
5683
+ if (!checkBetterHtmlContextValue(externalBetterHtmlContextValue, "decryptString")) return void 0;
5684
+ const localStoragePlugin2 = externalBetterHtmlContextValue.plugins.find((plugin) => plugin.name === "localStorage");
5685
+ if (!localStoragePlugin2) {
5686
+ throw new Error(
5687
+ "`decryptString` hook requires the `localStorage` plugin to be added to the `plugins` prop in `<BetterHtmlProvider>`."
5688
+ );
5711
5689
  }
5712
- const safeAmount = Math.max(0, Math.min(1, amount));
5713
- const r = parseInt(hex.substring(0, 2), 16);
5714
- const g = parseInt(hex.substring(2, 4), 16);
5715
- const b = parseInt(hex.substring(4, 6), 16);
5716
- const [h, s, l] = rgbToHsl(r, g, b);
5717
- const newSaturation = Math.max(0, s * (1 - safeAmount));
5718
- const [newR, newG, newB] = hslToRgb(h, newSaturation, l);
5719
- const rHex = Math.round(newR).toString(16).padStart(2, "0");
5720
- const gHex = Math.round(newG).toString(16).padStart(2, "0");
5721
- const bHex = Math.round(newB).toString(16).padStart(2, "0");
5722
- return `#${rHex}${gHex}${bHex}`;
5690
+ const pluginConfig = localStoragePlugin2.getConfig();
5691
+ if (!pluginConfig.encryption?.enabled) return text;
5692
+ const decrypted = import_crypto_js.default.AES.decrypt(text, import_crypto_js.default.enc.Hex.parse(pluginConfig.encryption.secretKey), {
5693
+ iv: import_crypto_js.default.enc.Hex.parse(pluginConfig.encryption.iv),
5694
+ mode: import_crypto_js.default.mode.CBC,
5695
+ padding: import_crypto_js.default.pad.Pkcs7
5696
+ });
5697
+ return decrypted.toString(import_crypto_js.default.enc.Utf8);
5723
5698
  };
5724
5699
 
5725
- // src/components/Chip.tsx
5726
- var import_jsx_runtime14 = require("react/jsx-runtime");
5727
- var ChipComponent = (0, import_react16.forwardRef)(function Chip({ text, color, backgroundColor, borderRadius, isCircle, ...props }, ref) {
5728
- const theme2 = useTheme();
5729
- return /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
5730
- Div_default,
5731
- {
5732
- width: "fit-content",
5733
- backgroundColor: backgroundColor ?? theme2.colors.backgroundSecondary,
5734
- borderRadius: isCircle ? 999 : borderRadius ?? theme2.styles.borderRadius / 1.3,
5735
- paddingBlock: theme2.styles.gap / 2,
5736
- paddingInline: theme2.styles.space / 1.5,
5737
- ...props,
5738
- ref,
5739
- children: /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(Text_default, { color: color ?? theme2.colors.textPrimary, children: text })
5740
- }
5741
- );
5742
- });
5743
- ChipComponent.colored = (0, import_react16.forwardRef)(function Colored({ color, ...props }, ref) {
5744
- const theme2 = useTheme();
5745
- const { colorTheme } = useBetterHtmlContextInternal();
5746
- const readyColor = color ?? theme2.colors.textSecondary;
5747
- return /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
5748
- ChipComponent,
5749
- {
5750
- color: colorTheme === "light" ? darkenColor(readyColor, 0.7) : lightenColor(readyColor, 0.7),
5751
- backgroundColor: readyColor + "40",
5752
- border: `1px solid ${readyColor}`,
5753
- ref,
5754
- ...props
5755
- }
5756
- );
5757
- });
5758
- var Chip2 = (0, import_react16.memo)(ChipComponent);
5759
- Chip2.colored = ChipComponent.colored;
5760
- var Chip_default = Chip2;
5761
-
5762
- // src/components/InputField.tsx
5763
- var import_react20 = require("react");
5764
- var import_styled_components11 = __toESM(require("styled-components"));
5765
-
5766
5700
  // src/components/Label.tsx
5767
5701
  var import_react17 = require("react");
5768
5702
  var import_jsx_runtime15 = require("react/jsx-runtime");
@@ -7600,6 +7534,10 @@ var FormComponent = (0, import_react22.forwardRef)(function Form({
7600
7534
  submitButtonId,
7601
7535
  submitButtonIsDisabled,
7602
7536
  cancelButtonText,
7537
+ cancelButtonLoaderName,
7538
+ cancelButtonIsLoading,
7539
+ cancelButtonId,
7540
+ cancelButtonIsDisabled,
7603
7541
  actionButtonsLocation = "right",
7604
7542
  gap,
7605
7543
  isDestructive,
@@ -7633,7 +7571,17 @@ var FormComponent = (0, import_react22.forwardRef)(function Form({
7633
7571
  marginTop: theme2.styles.space,
7634
7572
  children: [
7635
7573
  renderActionButtons,
7636
- onClickCancel && /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(Button_default.secondary, { text: cancelButtonText ?? "Cancel", onClick: onClickCancel }),
7574
+ onClickCancel && /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
7575
+ Button_default.secondary,
7576
+ {
7577
+ text: cancelButtonText ?? "Cancel",
7578
+ isLoading: cancelButtonIsLoading,
7579
+ loaderName: cancelButtonLoaderName,
7580
+ disabled: cancelButtonIsDisabled,
7581
+ id: cancelButtonId,
7582
+ onClick: onClickCancel
7583
+ }
7584
+ ),
7637
7585
  /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
7638
7586
  SubmitButtonTag,
7639
7587
  {
@@ -7740,7 +7688,7 @@ var ColorThemeSwitchComponent = function ColorThemeSwitch({
7740
7688
  }) {
7741
7689
  const form = useForm({
7742
7690
  defaultValues: {
7743
- darkMode: LocalStorage.getItem("theme") === "dark"
7691
+ darkMode: localStorage.getItem("theme") === "dark"
7744
7692
  }
7745
7693
  });
7746
7694
  (0, import_react24.useEffect)(() => {
@@ -9335,6 +9283,71 @@ FoldableComponent.box = (0, import_react28.forwardRef)(function Box3({ ...props
9335
9283
  var Foldable2 = (0, import_react28.memo)(FoldableComponent);
9336
9284
  Foldable2.box = FoldableComponent.box;
9337
9285
  var Foldable_default = Foldable2;
9286
+
9287
+ // src/utils/localStorage.ts
9288
+ function generateLocalStorage() {
9289
+ return {
9290
+ setItem: (name, value) => {
9291
+ if (!checkBetterHtmlContextValue(externalBetterHtmlContextValue, "generateLocalStorage.setItem"))
9292
+ return void 0;
9293
+ const localStoragePlugin2 = externalBetterHtmlContextValue.plugins.find(
9294
+ (plugin) => plugin.name === "localStorage"
9295
+ );
9296
+ if (!localStoragePlugin2) {
9297
+ throw new Error(
9298
+ "`generateLocalStorage.setItem` function requires the `localStorage` plugin to be added to the `plugins` prop in `<BetterHtmlProvider>`."
9299
+ );
9300
+ }
9301
+ const pluginConfig = localStoragePlugin2.getConfig();
9302
+ const encryptionEnabled = pluginConfig.encryption?.enabled ?? false;
9303
+ const readyName = encryptionEnabled ? encryptString(name.toString()) : name;
9304
+ const readyValue = encryptionEnabled ? encryptString(JSON.stringify(value)) : JSON.stringify(value);
9305
+ if (value) localStorage.setItem(readyName.toString(), readyValue);
9306
+ else localStorage.removeItem(readyName.toString());
9307
+ },
9308
+ getItem: (name) => {
9309
+ if (!checkBetterHtmlContextValue(externalBetterHtmlContextValue, "generateLocalStorage.getItem"))
9310
+ return void 0;
9311
+ const localStoragePlugin2 = externalBetterHtmlContextValue.plugins.find(
9312
+ (plugin) => plugin.name === "localStorage"
9313
+ );
9314
+ if (!localStoragePlugin2) {
9315
+ throw new Error(
9316
+ "`generateLocalStorage.getItem` function requires the `localStorage` plugin to be added to the `plugins` prop in `<BetterHtmlProvider>`."
9317
+ );
9318
+ }
9319
+ const pluginConfig = localStoragePlugin2.getConfig();
9320
+ const encryptionEnabled = pluginConfig.encryption?.enabled ?? false;
9321
+ const readyName = encryptionEnabled ? encryptString(name.toString()) : name;
9322
+ const item = localStorage.getItem(readyName.toString());
9323
+ if (item === null) return void 0;
9324
+ try {
9325
+ return encryptionEnabled ? JSON.parse(decryptString(item)) : JSON.parse(item);
9326
+ } catch (error) {
9327
+ return void 0;
9328
+ }
9329
+ },
9330
+ removeItem: (name) => {
9331
+ if (!checkBetterHtmlContextValue(externalBetterHtmlContextValue, "generateLocalStorage.removeItem"))
9332
+ return void 0;
9333
+ const localStoragePlugin2 = externalBetterHtmlContextValue.plugins.find(
9334
+ (plugin) => plugin.name === "localStorage"
9335
+ );
9336
+ if (!localStoragePlugin2) {
9337
+ throw new Error(
9338
+ "`generateLocalStorage.removeItem` function requires the `localStorage` plugin to be added to the `plugins` prop in `<BetterHtmlProvider>`."
9339
+ );
9340
+ }
9341
+ const pluginConfig = localStoragePlugin2.getConfig();
9342
+ const encryptionEnabled = pluginConfig.encryption?.enabled ?? false;
9343
+ const readyName = encryptionEnabled ? encryptString(name.toString()) : name;
9344
+ localStorage.removeItem(readyName.toString());
9345
+ },
9346
+ removeAllItems: () => {
9347
+ localStorage.clear();
9348
+ }
9349
+ };
9350
+ }
9338
9351
  // Annotate the CommonJS export names for ESM import in node:
9339
9352
  0 && (module.exports = {
9340
9353
  BetterHtmlProvider,