react-simple-phone-input 4.6.6 → 4.6.8
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/cjs/index.js +1 -1
- package/dist/cjs/index.js.map +1 -1
- package/dist/cjs/types/components/PhoneInput/PhoneInput.d.ts +29 -2
- package/dist/cjs/types/components/PhoneInput/index.d.ts +1 -1
- package/dist/cjs/types/components/index.d.ts +1 -1
- package/dist/esm/index.js +1 -1
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/types/components/PhoneInput/PhoneInput.d.ts +29 -2
- package/dist/esm/types/components/PhoneInput/index.d.ts +1 -1
- package/dist/esm/types/components/index.d.ts +1 -1
- package/dist/index.d.ts +30 -3
- package/dist/style.css +16 -8
- package/package.json +1 -1
package/dist/cjs/index.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";var o=require("react/jsx-runtime"),n=require("react"),e=function(){return e=Object.assign||function(o){for(var n,e=1,c=arguments.length;e<c;e++)for(var r in n=arguments[e])Object.prototype.hasOwnProperty.call(n,r)&&(o[r]=n[r]);return o},e.apply(this,arguments)},c=[{country:"Afghanistan",countryCode:"AF",callingCode:"+93"},{country:"Albania",countryCode:"AL",callingCode:"+355"},{country:"Algeria",countryCode:"DZ",callingCode:"+213"},{country:"American Samoa",countryCode:"AS",callingCode:"+1684"},{country:"Andorra",countryCode:"AD",callingCode:"+376"},{country:"Angola",countryCode:"AO",callingCode:"+244"},{country:"Anguilla",countryCode:"AI",callingCode:"+1264"},{country:"Antarctica",countryCode:"AQ",callingCode:"+672"},{country:"Antigua and Barbuda",countryCode:"AG",callingCode:"+1268"},{country:"Argentina",countryCode:"AR",callingCode:"+54"},{country:"Armenia",countryCode:"AM",callingCode:"+374"},{country:"Aruba",countryCode:"AW",callingCode:"+297"},{country:"Australia",countryCode:"AU",callingCode:"+61"},{country:"Austria",countryCode:"AT",callingCode:"+43"},{country:"Azerbaijan",countryCode:"AZ",callingCode:"+994"},{country:"Bahamas",countryCode:"BS",callingCode:"+1242"},{country:"Bahrain",countryCode:"BH",callingCode:"+973"},{country:"Bangladesh",countryCode:"BD",callingCode:"+880"},{country:"Barbados",countryCode:"BB",callingCode:"+1246"},{country:"Belarus",countryCode:"BY",callingCode:"+375"},{country:"Belgium",countryCode:"BE",callingCode:"+32"},{country:"Belize",countryCode:"BZ",callingCode:"+501"},{country:"Benin",countryCode:"BJ",callingCode:"+229"},{country:"Bermuda",countryCode:"BM",callingCode:"+1441"},{country:"Bhutan",countryCode:"BT",callingCode:"+975"},{country:"Bolivia",countryCode:"BO",callingCode:"+591"},{country:"Bosnia and Herzegovina",countryCode:"BA",callingCode:"+387"},{country:"Botswana",countryCode:"BW",callingCode:"+267"},{country:"Bouvet Island",countryCode:"BV",callingCode:"+47"},{country:"Brazil",countryCode:"BR",callingCode:"+55"},{country:"British Indian Ocean Territory",countryCode:"IO",callingCode:"+246"},{country:"British Virgin Islands",countryCode:"VG",callingCode:"+1284"},{country:"Brunei",countryCode:"BN",callingCode:"+673"},{country:"Bulgaria",countryCode:"BG",callingCode:"+359"},{country:"Burkina Faso",countryCode:"BF",callingCode:"+226"},{country:"Burundi",countryCode:"BI",callingCode:"+257"},{country:"Cambodia",countryCode:"KH",callingCode:"+855"},{country:"Cameroon",countryCode:"CM",callingCode:"+237"},{country:"Canada",countryCode:"CA",callingCode:"+1"},{country:"Cape Verde",countryCode:"CV",callingCode:"+238"},{country:"Cayman Islands",countryCode:"KY",callingCode:"+1345"},{country:"Central African Republic",countryCode:"CF",callingCode:"+236"},{country:"Chad",countryCode:"TD",callingCode:"+235"},{country:"Chile",countryCode:"CL",callingCode:"+56"},{country:"China",countryCode:"CN",callingCode:"+86"},{country:"Christmas Island",countryCode:"CX",callingCode:"+61"},{country:"Cocos Islands",countryCode:"CC",callingCode:"+61"},{country:"Colombia",countryCode:"CO",callingCode:"+57"},{country:"Comoros",countryCode:"KM",callingCode:"+269"},{country:"Cook Islands",countryCode:"CK",callingCode:"+682"},{country:"Costa Rica",countryCode:"CR",callingCode:"+506"},{country:"Croatia",countryCode:"HR",callingCode:"+385"},{country:"Cuba",countryCode:"CU",callingCode:"+53"},{country:"Cyprus",countryCode:"CY",callingCode:"+357"},{country:"Czech Republic",countryCode:"CZ",callingCode:"+420"},{country:"Democratic Republic of the Congo",countryCode:"CD",callingCode:"+243"},{country:"Denmark",countryCode:"DK",callingCode:"+45"},{country:"Djibouti",countryCode:"DJ",callingCode:"+253"},{country:"Dominica",countryCode:"DM",callingCode:"+1767"},{country:"Dominican Republic",countryCode:"DO",callingCode:"+1"},{country:"East Timor",countryCode:"TL",callingCode:"+670"},{country:"Ecuador",countryCode:"EC",callingCode:"+593"},{country:"Egypt",countryCode:"EG",callingCode:"+20"},{country:"El Salvador",countryCode:"SV",callingCode:"+503"},{country:"Equatorial Guinea",countryCode:"GQ",callingCode:"+240"},{country:"Eritrea",countryCode:"ER",callingCode:"+291"},{country:"Estonia",countryCode:"EE",callingCode:"+372"},{country:"Ethiopia",countryCode:"ET",callingCode:"+251"},{country:"Falkland Islands",countryCode:"FK",callingCode:"+500"},{country:"Faroe Islands",countryCode:"FO",callingCode:"+298"},{country:"Fiji",countryCode:"FJ",callingCode:"+679"},{country:"Finland",countryCode:"FI",callingCode:"+358"},{country:"France",countryCode:"FR",callingCode:"+33"},{country:"French Guiana",countryCode:"GF",callingCode:"+594"},{country:"French Polynesia",countryCode:"PF",callingCode:"+689"},{country:"French Southern Territories",countryCode:"TF",callingCode:"+262"},{country:"Gabon",countryCode:"GA",callingCode:"+241"},{country:"Gambia",countryCode:"GM",callingCode:"+220"},{country:"Georgia",countryCode:"GE",callingCode:"+995"},{country:"Germany",countryCode:"DE",callingCode:"+49"},{country:"Ghana",countryCode:"GH",callingCode:"+233"},{country:"Gibraltar",countryCode:"GI",callingCode:"+350"},{country:"Greece",countryCode:"GR",callingCode:"+30"},{country:"Greenland",countryCode:"GL",callingCode:"+299"},{country:"Grenada",countryCode:"GD",callingCode:"+473"},{country:"Guadeloupe",countryCode:"GP",callingCode:"+590"},{country:"Guam",countryCode:"GU",callingCode:"+1671"},{country:"Guatemala",countryCode:"GT",callingCode:"+502"},{country:"Guinea",countryCode:"GN",callingCode:"+224"},{country:"Guinea-Bissau",countryCode:"GW",callingCode:"+245"},{country:"Guyana",countryCode:"GY",callingCode:"+592"},{country:"Haiti",countryCode:"HT",callingCode:"+509"},{country:"Honduras",countryCode:"HN",callingCode:"+504"},{country:"Hong Kong",countryCode:"HK",callingCode:"+852"},{country:"Hungary",countryCode:"HU",callingCode:"+36"},{country:"Iceland",countryCode:"IS",callingCode:"+354"},{country:"India",countryCode:"IN",callingCode:"+91"},{country:"Indonesia",countryCode:"ID",callingCode:"+62"},{country:"Iran",countryCode:"IR",callingCode:"+98"},{country:"Iraq",countryCode:"IQ",callingCode:"+964"},{country:"Ireland",countryCode:"IE",callingCode:"+353"},{country:"Israel",countryCode:"IL",callingCode:"+972"},{country:"Italy",countryCode:"IT",callingCode:"+39"},{country:"Ivory Coast",countryCode:"CI",callingCode:"+225"},{country:"Jamaica",countryCode:"JM",callingCode:"+1876"},{country:"Japan",countryCode:"JP",callingCode:"+81"},{country:"Jordan",countryCode:"JO",callingCode:"+962"},{country:"Kazakhstan",countryCode:"KZ",callingCode:"+7"},{country:"Kenya",countryCode:"KE",callingCode:"+254"},{country:"Kiribati",countryCode:"KI",callingCode:"+686"},{country:"Kuwait",countryCode:"KW",callingCode:"+965"},{country:"Kyrgyzstan",countryCode:"KG",callingCode:"+996"},{country:"Laos",countryCode:"LA",callingCode:"+856"},{country:"Latvia",countryCode:"LV",callingCode:"+371"},{country:"Lebanon",countryCode:"LB",callingCode:"+961"},{country:"Lesotho",countryCode:"LS",callingCode:"+266"},{country:"Liberia",countryCode:"LR",callingCode:"+231"},{country:"Libya",countryCode:"LY",callingCode:"+218"},{country:"Liechtenstein",countryCode:"LI",callingCode:"+423"},{country:"Lithuania",countryCode:"LT",callingCode:"+370"},{country:"Luxembourg",countryCode:"LU",callingCode:"+352"},{country:"Macao",countryCode:"MO",callingCode:"+853"},{country:"Macedonia",countryCode:"MK",callingCode:"+389"},{country:"Madagascar",countryCode:"MG",callingCode:"+261"},{country:"Malawi",countryCode:"MW",callingCode:"+265"},{country:"Malaysia",countryCode:"MY",callingCode:"+60"},{country:"Maldives",countryCode:"MV",callingCode:"+960"},{country:"Mali",countryCode:"ML",callingCode:"+223"},{country:"Malta",countryCode:"MT",callingCode:"+356"},{country:"Marshall Islands",countryCode:"MH",callingCode:"+692"},{country:"Martinique",countryCode:"MQ",callingCode:"+596"},{country:"Mauritania",countryCode:"MR",callingCode:"+222"},{country:"Mauritius",countryCode:"MU",callingCode:"+230"},{country:"Mayotte",countryCode:"YT",callingCode:"+262"},{country:"Mexico",countryCode:"MX",callingCode:"+52"},{country:"Micronesia",countryCode:"FM",callingCode:"+691"},{country:"Moldova",countryCode:"MD",callingCode:"+373"},{country:"Monaco",countryCode:"MC",callingCode:"+377"},{country:"Mongolia",countryCode:"MN",callingCode:"+976"},{country:"Montserrat",countryCode:"MS",callingCode:"+1664"},{country:"Morocco",countryCode:"MA",callingCode:"+212"},{country:"Mozambique",countryCode:"MZ",callingCode:"+258"},{country:"Myanmar",countryCode:"MM",callingCode:"+95"},{country:"Namibia",countryCode:"NA",callingCode:"+264"},{country:"Nauru",countryCode:"NR",callingCode:"+674"},{country:"Nepal",countryCode:"NP",callingCode:"+977"},{country:"Netherlands",countryCode:"NL",callingCode:"+31"},{country:"New Caledonia",countryCode:"NC",callingCode:"+687"},{country:"New Zealand",countryCode:"NZ",callingCode:"+64"},{country:"Nicaragua",countryCode:"NI",callingCode:"+505"},{country:"Niger",countryCode:"NE",callingCode:"+227"},{country:"Nigeria",countryCode:"NG",callingCode:"+234"},{country:"Niue",countryCode:"NU",callingCode:"+683"},{country:"Norfolk Island",countryCode:"NF",callingCode:"+672"},{country:"North Korea",countryCode:"KP",callingCode:"+850"},{country:"Northern Mariana Islands",countryCode:"MP",callingCode:"+1670"},{country:"Norway",countryCode:"NO",callingCode:"+47"},{country:"Oman",countryCode:"OM",callingCode:"+968"},{country:"Pakistan",countryCode:"PK",callingCode:"+92"},{country:"Palau",countryCode:"PW",callingCode:"+680"},{country:"Palestinian Territory",countryCode:"PS",callingCode:"+970"},{country:"Panama",countryCode:"PA",callingCode:"+507"},{country:"Papua New Guinea",countryCode:"PG",callingCode:"+675"},{country:"Paraguay",countryCode:"PY",callingCode:"+595"},{country:"Peru",countryCode:"PE",callingCode:"+51"},{country:"Philippines",countryCode:"PH",callingCode:"+63"},{country:"Pitcairn",countryCode:"PN",callingCode:"+872"},{country:"Poland",countryCode:"PL",callingCode:"+48"},{country:"Portugal",countryCode:"PT",callingCode:"+351"},{country:"Puerto Rico",countryCode:"PR",callingCode:"+1"},{country:"Qatar",countryCode:"QA",callingCode:"+974"},{country:"Republic of the Congo",countryCode:"CG",callingCode:"+242"},{country:"Reunion",countryCode:"RE",callingCode:"+262"},{country:"Romania",countryCode:"RO",callingCode:"+40"},{country:"Russia",countryCode:"RU",callingCode:"+7"},{country:"Rwanda",countryCode:"RW",callingCode:"+250"},{country:"Saint Helena",countryCode:"SH",callingCode:"+290"},{country:"Saint Kitts and Nevis",countryCode:"KN",callingCode:"+1869"},{country:"Saint Lucia",countryCode:"LC",callingCode:"+1758"},{country:"Saint Pierre and Miquelon",countryCode:"PM",callingCode:"+508"},{country:"Saint Vincent and the Grenadines",countryCode:"VC",callingCode:"+1784"},{country:"Samoa",countryCode:"WS",callingCode:"+685"},{country:"San Marino",countryCode:"SM",callingCode:"+378"},{country:"Sao Tome and Principe",countryCode:"ST",callingCode:"+239"},{country:"Saudi Arabia",countryCode:"SA",callingCode:"+966"},{country:"Senegal",countryCode:"SN",callingCode:"+221"},{country:"Seychelles",countryCode:"SC",callingCode:"+248"},{country:"Sierra Leone",countryCode:"SL",callingCode:"+232"},{country:"Singapore",countryCode:"SG",callingCode:"+65"},{country:"Slovakia",countryCode:"SK",callingCode:"+421"},{country:"Slovenia",countryCode:"SI",callingCode:"+386"},{country:"Solomon Islands",countryCode:"SB",callingCode:"+677"},{country:"Somalia",countryCode:"SO",callingCode:"+252"},{country:"South Africa",countryCode:"ZA",callingCode:"+27"},{country:"South Georgia and the South Sandwich Islands",countryCode:"GS",callingCode:"+500"},{country:"South Korea",countryCode:"KR",callingCode:"+82"},{country:"Spain",countryCode:"ES",callingCode:"+34"},{country:"Sri Lanka",countryCode:"LK",callingCode:"+94"},{country:"Sudan",countryCode:"SD",callingCode:"+249"},{country:"Suriname",countryCode:"SR",callingCode:"+597"},{country:"Svalbard and Jan Mayen",countryCode:"SJ",callingCode:"+47"},{country:"Swaziland",countryCode:"SZ",callingCode:"+268"},{country:"Sweden",countryCode:"SE",callingCode:"+46"},{country:"Switzerland",countryCode:"CH",callingCode:"+41"},{country:"Syria",countryCode:"SY",callingCode:"+963"},{country:"Taiwan",countryCode:"TW",callingCode:"+886"},{country:"Tajikistan",countryCode:"TJ",callingCode:"+992"},{country:"Tanzania",countryCode:"TZ",callingCode:"+255"},{country:"Thailand",countryCode:"TH",callingCode:"+66"},{country:"Togo",countryCode:"TG",callingCode:"+228"},{country:"Tokelau",countryCode:"TK",callingCode:"+690"},{country:"Tonga",countryCode:"TO",callingCode:"+676"},{country:"Trinidad and Tobago",countryCode:"TT",callingCode:"+1868"},{country:"Tunisia",countryCode:"TN",callingCode:"+216"},{country:"Turkey",countryCode:"TR",callingCode:"+90"},{country:"Turkmenistan",countryCode:"TM",callingCode:"+993"},{country:"Turks and Caicos Islands",countryCode:"TC",callingCode:"+1649"},{country:"Tuvalu",countryCode:"TV",callingCode:"+688"},{country:"U.S. Virgin Islands",countryCode:"VI",callingCode:"+1340"},{country:"Uganda",countryCode:"UG",callingCode:"+256"},{country:"Ukraine",countryCode:"UA",callingCode:"+380"},{country:"United Arab Emirates",countryCode:"AE",callingCode:"+971"},{country:"United Kingdom",countryCode:"GB",callingCode:"+44"},{country:"United States",countryCode:"US",callingCode:"+1"},{country:"United States Minor Outlying Islands",countryCode:"UM",callingCode:"+1"},{country:"Uruguay",countryCode:"UY",callingCode:"+598"},{country:"Uzbekistan",countryCode:"UZ",callingCode:"+998"},{country:"Vanuatu",countryCode:"VU",callingCode:"+678"},{country:"Vatican",countryCode:"VA",callingCode:"+379"},{country:"Venezuela",countryCode:"VE",callingCode:"+58"},{country:"Vietnam",countryCode:"VN",callingCode:"+84"},{country:"Wallis and Futuna",countryCode:"WF",callingCode:"+681"},{country:"Western Sahara",countryCode:"EH",callingCode:"+212"},{country:"Yemen",countryCode:"YE",callingCode:"+967"},{country:"Zambia",countryCode:"ZM",callingCode:"+260"},{country:"Zimbabwe",countryCode:"ZW",callingCode:"+263"}],r=function(o){return c.find((function(n){return n.countryCode===o}))};exports.PhoneInput=function(t){var l,u,a=t.placeholder,d=t.country,i=t.onChange,C=t.value,y=t.iconComponent,g=t.inputProps,s=t.onlyCountries,h=t.excludeCountries,p=t.preferredCountries,m=t.showDropdownIcon,v=void 0===m||m,f=t.dialCodeInputField,S=void 0!==f&&f,M=t.search,N=void 0===M||M,B=t.searchPlaceholder,I=void 0===B?"Search country":B,A=t.showSearchIcon,G=void 0===A||A,w=t.searchIconComponent,T=t.searchProps,x=t.searchNotFound,b=void 0===x?"Not found":x,E=n.useState({}),P=E[0],L=E[1],j=n.useState(!1),R=j[0],K=j[1],F=n.useState(C||""),D=F[0],U=F[1],k=n.useState(c),O=k[0],V=k[1],H=n.useState(0),z=H[0],Z=H[1],W=n.useRef(null),Y=n.useRef(null);l=W,u=function(){return K(!1)},n.useEffect((function(){var o=function(o){l.current&&!l.current.contains(o.target)&&u(o)};return document.addEventListener("mousedown",o),document.addEventListener("touchstart",o),function(){document.removeEventListener("mousedown",o),document.removeEventListener("touchstart",o)}}),[l,u]);var J=function(o){R&&("ArrowDown"===o.key&&(o.preventDefault(),Z((function(o){return o<O.length-1?o+1:o}))),"ArrowUp"===o.key&&(o.preventDefault(),Z((function(o){return o>0?o-1:0}))),"Escape"===o.key&&K(!1),"Enter"===o.key&&z>=0&&(L(O[z]),K(!1)))};return n.useEffect((function(){var o;if(z<0||z>O.length||!Y)return function(){};if(R&&Y&&O.length>0){var n=Array.from(null===(o=Y.current)||void 0===o?void 0:o.children);n[z]&&function(o){var n;N&&O.length>0&&(null===(n=Y.current)||void 0===n||n.scrollTo({top:o,behavior:"smooth"}))}(n[z].offsetTop-65)}}),[z]),n.useMemo((function(){if(S){var o=null==D?void 0:D.replace(P.callingCode,r(d).callingCode);console.log(o),U(o.length>0?o:r(d).callingCode)}L(r(d))}),[d,S]),n.useMemo((function(){var o,n,e;V((o=s,e=p,((n=h)&&n.length>0?c.filter((function(o){return!(null==n?void 0:n.includes(o.countryCode))})):o&&(null==o?void 0:o.length)>0?c.filter((function(n){return null==o?void 0:o.includes(n.countryCode)})):c).sort((function(o,n){return Number(null==e?void 0:e.includes(n.countryCode))-Number(null==e?void 0:e.includes(o.countryCode))||(null==e?void 0:e.indexOf(o.countryCode))-(null==e?void 0:e.indexOf(n.countryCode))}))))}),[s,h,p]),o.jsx("div",e({className:"simple-phone-input-sri198-container",onKeyDown:function(o){return J(o)},tabIndex:-1},{children:o.jsxs("div",e({className:"simple-phone-input-sri198-main"},{children:[o.jsxs("div",e({className:"simple-phone-input-sri198-dropdown-container",ref:W},{children:[o.jsxs("div",e({onClick:function(){return K(!R)},className:S?"simple-phone-input-sri198-dropdown-container-button dial":"simple-phone-input-sri198-dropdown-container-button"},{children:[o.jsx("img",{src:"https://cdn.jsdelivr.net/gh/siamahnaf198/country-flags@main/img/"+P.countryCode+".svg",alt:P.country,width:"20px"}),!S&&o.jsx("span",e({className:"simple-phone-input-sri198-selected-code"},{children:P.callingCode})),v&&o.jsx("div",e({className:R?"simple-phone-input-sri198-dropdown-icon":"simple-phone-input-sri198-dropdown-icon active"},{children:y||o.jsx("svg",e({xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",preserveAspectRatio:"xMidYMid meet",viewBox:"0 0 24 24"},{children:o.jsx("path",{fill:"currentColor",d:"m7 10l5 5l5-5z"})}))}))]})),o.jsxs("ul",e({className:R?"simple-phone-input-sri198-dropdown active":"simple-phone-input-sri198-dropdown",ref:Y},{children:[N&&o.jsxs("div",e({className:"simple-phone-input-sri198-search-container"},{children:[o.jsx("input",e({placeholder:I},T,{onChange:function(o){var n=o.target.value;V(function(o,n,e){return(e&&e.length>0?c.filter((function(o){return!(null==e?void 0:e.includes(o.countryCode))})):n&&(null==n?void 0:n.length)>0?c.filter((function(o){return null==n?void 0:n.includes(o.countryCode)})):c).filter((function(n){var e=new RegExp(o.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&"),"gi");return n.country.match(e)}))}(n,s,h))}})),G&&o.jsx("div",e({className:"simple-phone-input-sri198-search-icon"},{children:null!=w?w:o.jsxs("svg",e({xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",preserveAspectRatio:"xMidYMid meet",viewBox:"0 0 48 48"},{children:[o.jsxs("g",e({fill:"#616161"},{children:[o.jsx("path",{d:"m29.175 31.99l2.828-2.827l12.019 12.019l-2.828 2.827z"}),o.jsx("circle",{cx:"20",cy:"20",r:"16"})]})),o.jsx("path",{fill:"#37474F",d:"m32.45 35.34l2.827-2.828l8.696 8.696l-2.828 2.828z"}),o.jsx("circle",{cx:"20",cy:"20",r:"13",fill:"#64B5F6"}),o.jsx("path",{fill:"#BBDEFB",d:"M26.9 14.2c-1.7-2-4.2-3.2-6.9-3.2s-5.2 1.2-6.9 3.2c-.4.4-.3 1.1.1 1.4c.4.4 1.1.3 1.4-.1C16 13.9 17.9 13 20 13s4 .9 5.4 2.5c.2.2.5.4.8.4c.2 0 .5-.1.6-.2c.4-.4.4-1.1.1-1.5z"})]}))}))]})),0===O.length&&o.jsx("div",e({className:"simple-phone-input-sri198-not-found"},{children:b})),O.map((function(n,c){return o.jsxs("li",e({onClick:function(){return function(o,n){if(S){var e=null==D?void 0:D.replace(P.callingCode,o.callingCode);U(e.length>0?e:o.callingCode),i(e.length>0?e:o.callingCode)}else i(o.callingCode+D);L(o),K(!1),Z(n)}(n,c)},className:c===z?"active":""},{children:[o.jsx("img",{src:"https://cdn.jsdelivr.net/gh/siamahnaf198/country-flags@main/img/"+n.countryCode+".svg",alt:n.country,width:"20px"}),o.jsx("span",e({className:"simple-phone-input-sri198-dropdown-text"},{children:n.country})),o.jsx("span",e({className:"simple-phone-input-sri198-dropdown-country-code"},{children:n.callingCode}))]}),c)}))]}))]})),o.jsx("input",e({className:"simple-phone-input-sri198-input",placeholder:a,onChange:function(o){var n=o.target.value.replace(/\D/g,"");S?(i("+"+n),U("+"+n)):(U(n),i(P.callingCode+n))},type:"tel",onInput:function(o){if(S){var n=D.slice(P.callingCode.length);o.target.value.startsWith(P.callingCode)?o.target.value=o.target.value:o.target.value=P.callingCode+n}},onKeyDown:function(o){return J(o)},value:D},g))]}))}))};
|
|
1
|
+
"use strict";var o=require("react/jsx-runtime"),n=require("react");const e=[{country:"Afghanistan",countryCode:"AF",callingCode:"+93"},{country:"Albania",countryCode:"AL",callingCode:"+355"},{country:"Algeria",countryCode:"DZ",callingCode:"+213"},{country:"American Samoa",countryCode:"AS",callingCode:"+1684"},{country:"Andorra",countryCode:"AD",callingCode:"+376"},{country:"Angola",countryCode:"AO",callingCode:"+244"},{country:"Anguilla",countryCode:"AI",callingCode:"+1264"},{country:"Antarctica",countryCode:"AQ",callingCode:"+672"},{country:"Antigua and Barbuda",countryCode:"AG",callingCode:"+1268"},{country:"Argentina",countryCode:"AR",callingCode:"+54"},{country:"Armenia",countryCode:"AM",callingCode:"+374"},{country:"Aruba",countryCode:"AW",callingCode:"+297"},{country:"Australia",countryCode:"AU",callingCode:"+61"},{country:"Austria",countryCode:"AT",callingCode:"+43"},{country:"Azerbaijan",countryCode:"AZ",callingCode:"+994"},{country:"Bahamas",countryCode:"BS",callingCode:"+1242"},{country:"Bahrain",countryCode:"BH",callingCode:"+973"},{country:"Bangladesh",countryCode:"BD",callingCode:"+880"},{country:"Barbados",countryCode:"BB",callingCode:"+1246"},{country:"Belarus",countryCode:"BY",callingCode:"+375"},{country:"Belgium",countryCode:"BE",callingCode:"+32"},{country:"Belize",countryCode:"BZ",callingCode:"+501"},{country:"Benin",countryCode:"BJ",callingCode:"+229"},{country:"Bermuda",countryCode:"BM",callingCode:"+1441"},{country:"Bhutan",countryCode:"BT",callingCode:"+975"},{country:"Bolivia",countryCode:"BO",callingCode:"+591"},{country:"Bosnia and Herzegovina",countryCode:"BA",callingCode:"+387"},{country:"Botswana",countryCode:"BW",callingCode:"+267"},{country:"Bouvet Island",countryCode:"BV",callingCode:"+47"},{country:"Brazil",countryCode:"BR",callingCode:"+55"},{country:"British Indian Ocean Territory",countryCode:"IO",callingCode:"+246"},{country:"British Virgin Islands",countryCode:"VG",callingCode:"+1284"},{country:"Brunei",countryCode:"BN",callingCode:"+673"},{country:"Bulgaria",countryCode:"BG",callingCode:"+359"},{country:"Burkina Faso",countryCode:"BF",callingCode:"+226"},{country:"Burundi",countryCode:"BI",callingCode:"+257"},{country:"Cambodia",countryCode:"KH",callingCode:"+855"},{country:"Cameroon",countryCode:"CM",callingCode:"+237"},{country:"Canada",countryCode:"CA",callingCode:"+1"},{country:"Cape Verde",countryCode:"CV",callingCode:"+238"},{country:"Cayman Islands",countryCode:"KY",callingCode:"+1345"},{country:"Central African Republic",countryCode:"CF",callingCode:"+236"},{country:"Chad",countryCode:"TD",callingCode:"+235"},{country:"Chile",countryCode:"CL",callingCode:"+56"},{country:"China",countryCode:"CN",callingCode:"+86"},{country:"Christmas Island",countryCode:"CX",callingCode:"+61"},{country:"Cocos Islands",countryCode:"CC",callingCode:"+61"},{country:"Colombia",countryCode:"CO",callingCode:"+57"},{country:"Comoros",countryCode:"KM",callingCode:"+269"},{country:"Cook Islands",countryCode:"CK",callingCode:"+682"},{country:"Costa Rica",countryCode:"CR",callingCode:"+506"},{country:"Croatia",countryCode:"HR",callingCode:"+385"},{country:"Cuba",countryCode:"CU",callingCode:"+53"},{country:"Cyprus",countryCode:"CY",callingCode:"+357"},{country:"Czech Republic",countryCode:"CZ",callingCode:"+420"},{country:"Democratic Republic of the Congo",countryCode:"CD",callingCode:"+243"},{country:"Denmark",countryCode:"DK",callingCode:"+45"},{country:"Djibouti",countryCode:"DJ",callingCode:"+253"},{country:"Dominica",countryCode:"DM",callingCode:"+1767"},{country:"Dominican Republic",countryCode:"DO",callingCode:"+1"},{country:"East Timor",countryCode:"TL",callingCode:"+670"},{country:"Ecuador",countryCode:"EC",callingCode:"+593"},{country:"Egypt",countryCode:"EG",callingCode:"+20"},{country:"El Salvador",countryCode:"SV",callingCode:"+503"},{country:"Equatorial Guinea",countryCode:"GQ",callingCode:"+240"},{country:"Eritrea",countryCode:"ER",callingCode:"+291"},{country:"Estonia",countryCode:"EE",callingCode:"+372"},{country:"Ethiopia",countryCode:"ET",callingCode:"+251"},{country:"Falkland Islands",countryCode:"FK",callingCode:"+500"},{country:"Faroe Islands",countryCode:"FO",callingCode:"+298"},{country:"Fiji",countryCode:"FJ",callingCode:"+679"},{country:"Finland",countryCode:"FI",callingCode:"+358"},{country:"France",countryCode:"FR",callingCode:"+33"},{country:"French Guiana",countryCode:"GF",callingCode:"+594"},{country:"French Polynesia",countryCode:"PF",callingCode:"+689"},{country:"French Southern Territories",countryCode:"TF",callingCode:"+262"},{country:"Gabon",countryCode:"GA",callingCode:"+241"},{country:"Gambia",countryCode:"GM",callingCode:"+220"},{country:"Georgia",countryCode:"GE",callingCode:"+995"},{country:"Germany",countryCode:"DE",callingCode:"+49"},{country:"Ghana",countryCode:"GH",callingCode:"+233"},{country:"Gibraltar",countryCode:"GI",callingCode:"+350"},{country:"Greece",countryCode:"GR",callingCode:"+30"},{country:"Greenland",countryCode:"GL",callingCode:"+299"},{country:"Grenada",countryCode:"GD",callingCode:"+473"},{country:"Guadeloupe",countryCode:"GP",callingCode:"+590"},{country:"Guam",countryCode:"GU",callingCode:"+1671"},{country:"Guatemala",countryCode:"GT",callingCode:"+502"},{country:"Guinea",countryCode:"GN",callingCode:"+224"},{country:"Guinea-Bissau",countryCode:"GW",callingCode:"+245"},{country:"Guyana",countryCode:"GY",callingCode:"+592"},{country:"Haiti",countryCode:"HT",callingCode:"+509"},{country:"Honduras",countryCode:"HN",callingCode:"+504"},{country:"Hong Kong",countryCode:"HK",callingCode:"+852"},{country:"Hungary",countryCode:"HU",callingCode:"+36"},{country:"Iceland",countryCode:"IS",callingCode:"+354"},{country:"India",countryCode:"IN",callingCode:"+91"},{country:"Indonesia",countryCode:"ID",callingCode:"+62"},{country:"Iran",countryCode:"IR",callingCode:"+98"},{country:"Iraq",countryCode:"IQ",callingCode:"+964"},{country:"Ireland",countryCode:"IE",callingCode:"+353"},{country:"Israel",countryCode:"IL",callingCode:"+972"},{country:"Italy",countryCode:"IT",callingCode:"+39"},{country:"Ivory Coast",countryCode:"CI",callingCode:"+225"},{country:"Jamaica",countryCode:"JM",callingCode:"+1876"},{country:"Japan",countryCode:"JP",callingCode:"+81"},{country:"Jordan",countryCode:"JO",callingCode:"+962"},{country:"Kazakhstan",countryCode:"KZ",callingCode:"+7"},{country:"Kenya",countryCode:"KE",callingCode:"+254"},{country:"Kiribati",countryCode:"KI",callingCode:"+686"},{country:"Kuwait",countryCode:"KW",callingCode:"+965"},{country:"Kyrgyzstan",countryCode:"KG",callingCode:"+996"},{country:"Laos",countryCode:"LA",callingCode:"+856"},{country:"Latvia",countryCode:"LV",callingCode:"+371"},{country:"Lebanon",countryCode:"LB",callingCode:"+961"},{country:"Lesotho",countryCode:"LS",callingCode:"+266"},{country:"Liberia",countryCode:"LR",callingCode:"+231"},{country:"Libya",countryCode:"LY",callingCode:"+218"},{country:"Liechtenstein",countryCode:"LI",callingCode:"+423"},{country:"Lithuania",countryCode:"LT",callingCode:"+370"},{country:"Luxembourg",countryCode:"LU",callingCode:"+352"},{country:"Macao",countryCode:"MO",callingCode:"+853"},{country:"Macedonia",countryCode:"MK",callingCode:"+389"},{country:"Madagascar",countryCode:"MG",callingCode:"+261"},{country:"Malawi",countryCode:"MW",callingCode:"+265"},{country:"Malaysia",countryCode:"MY",callingCode:"+60"},{country:"Maldives",countryCode:"MV",callingCode:"+960"},{country:"Mali",countryCode:"ML",callingCode:"+223"},{country:"Malta",countryCode:"MT",callingCode:"+356"},{country:"Marshall Islands",countryCode:"MH",callingCode:"+692"},{country:"Martinique",countryCode:"MQ",callingCode:"+596"},{country:"Mauritania",countryCode:"MR",callingCode:"+222"},{country:"Mauritius",countryCode:"MU",callingCode:"+230"},{country:"Mayotte",countryCode:"YT",callingCode:"+262"},{country:"Mexico",countryCode:"MX",callingCode:"+52"},{country:"Micronesia",countryCode:"FM",callingCode:"+691"},{country:"Moldova",countryCode:"MD",callingCode:"+373"},{country:"Monaco",countryCode:"MC",callingCode:"+377"},{country:"Mongolia",countryCode:"MN",callingCode:"+976"},{country:"Montserrat",countryCode:"MS",callingCode:"+1664"},{country:"Morocco",countryCode:"MA",callingCode:"+212"},{country:"Mozambique",countryCode:"MZ",callingCode:"+258"},{country:"Myanmar",countryCode:"MM",callingCode:"+95"},{country:"Namibia",countryCode:"NA",callingCode:"+264"},{country:"Nauru",countryCode:"NR",callingCode:"+674"},{country:"Nepal",countryCode:"NP",callingCode:"+977"},{country:"Netherlands",countryCode:"NL",callingCode:"+31"},{country:"New Caledonia",countryCode:"NC",callingCode:"+687"},{country:"New Zealand",countryCode:"NZ",callingCode:"+64"},{country:"Nicaragua",countryCode:"NI",callingCode:"+505"},{country:"Niger",countryCode:"NE",callingCode:"+227"},{country:"Nigeria",countryCode:"NG",callingCode:"+234"},{country:"Niue",countryCode:"NU",callingCode:"+683"},{country:"Norfolk Island",countryCode:"NF",callingCode:"+672"},{country:"North Korea",countryCode:"KP",callingCode:"+850"},{country:"Northern Mariana Islands",countryCode:"MP",callingCode:"+1670"},{country:"Norway",countryCode:"NO",callingCode:"+47"},{country:"Oman",countryCode:"OM",callingCode:"+968"},{country:"Pakistan",countryCode:"PK",callingCode:"+92"},{country:"Palau",countryCode:"PW",callingCode:"+680"},{country:"Palestinian Territory",countryCode:"PS",callingCode:"+970"},{country:"Panama",countryCode:"PA",callingCode:"+507"},{country:"Papua New Guinea",countryCode:"PG",callingCode:"+675"},{country:"Paraguay",countryCode:"PY",callingCode:"+595"},{country:"Peru",countryCode:"PE",callingCode:"+51"},{country:"Philippines",countryCode:"PH",callingCode:"+63"},{country:"Pitcairn",countryCode:"PN",callingCode:"+872"},{country:"Poland",countryCode:"PL",callingCode:"+48"},{country:"Portugal",countryCode:"PT",callingCode:"+351"},{country:"Puerto Rico",countryCode:"PR",callingCode:"+1"},{country:"Qatar",countryCode:"QA",callingCode:"+974"},{country:"Republic of the Congo",countryCode:"CG",callingCode:"+242"},{country:"Reunion",countryCode:"RE",callingCode:"+262"},{country:"Romania",countryCode:"RO",callingCode:"+40"},{country:"Russia",countryCode:"RU",callingCode:"+7"},{country:"Rwanda",countryCode:"RW",callingCode:"+250"},{country:"Saint Helena",countryCode:"SH",callingCode:"+290"},{country:"Saint Kitts and Nevis",countryCode:"KN",callingCode:"+1869"},{country:"Saint Lucia",countryCode:"LC",callingCode:"+1758"},{country:"Saint Pierre and Miquelon",countryCode:"PM",callingCode:"+508"},{country:"Saint Vincent and the Grenadines",countryCode:"VC",callingCode:"+1784"},{country:"Samoa",countryCode:"WS",callingCode:"+685"},{country:"San Marino",countryCode:"SM",callingCode:"+378"},{country:"Sao Tome and Principe",countryCode:"ST",callingCode:"+239"},{country:"Saudi Arabia",countryCode:"SA",callingCode:"+966"},{country:"Senegal",countryCode:"SN",callingCode:"+221"},{country:"Seychelles",countryCode:"SC",callingCode:"+248"},{country:"Sierra Leone",countryCode:"SL",callingCode:"+232"},{country:"Singapore",countryCode:"SG",callingCode:"+65"},{country:"Slovakia",countryCode:"SK",callingCode:"+421"},{country:"Slovenia",countryCode:"SI",callingCode:"+386"},{country:"Solomon Islands",countryCode:"SB",callingCode:"+677"},{country:"Somalia",countryCode:"SO",callingCode:"+252"},{country:"South Africa",countryCode:"ZA",callingCode:"+27"},{country:"South Georgia and the South Sandwich Islands",countryCode:"GS",callingCode:"+500"},{country:"South Korea",countryCode:"KR",callingCode:"+82"},{country:"Spain",countryCode:"ES",callingCode:"+34"},{country:"Sri Lanka",countryCode:"LK",callingCode:"+94"},{country:"Sudan",countryCode:"SD",callingCode:"+249"},{country:"Suriname",countryCode:"SR",callingCode:"+597"},{country:"Svalbard and Jan Mayen",countryCode:"SJ",callingCode:"+47"},{country:"Swaziland",countryCode:"SZ",callingCode:"+268"},{country:"Sweden",countryCode:"SE",callingCode:"+46"},{country:"Switzerland",countryCode:"CH",callingCode:"+41"},{country:"Syria",countryCode:"SY",callingCode:"+963"},{country:"Taiwan",countryCode:"TW",callingCode:"+886"},{country:"Tajikistan",countryCode:"TJ",callingCode:"+992"},{country:"Tanzania",countryCode:"TZ",callingCode:"+255"},{country:"Thailand",countryCode:"TH",callingCode:"+66"},{country:"Togo",countryCode:"TG",callingCode:"+228"},{country:"Tokelau",countryCode:"TK",callingCode:"+690"},{country:"Tonga",countryCode:"TO",callingCode:"+676"},{country:"Trinidad and Tobago",countryCode:"TT",callingCode:"+1868"},{country:"Tunisia",countryCode:"TN",callingCode:"+216"},{country:"Turkey",countryCode:"TR",callingCode:"+90"},{country:"Turkmenistan",countryCode:"TM",callingCode:"+993"},{country:"Turks and Caicos Islands",countryCode:"TC",callingCode:"+1649"},{country:"Tuvalu",countryCode:"TV",callingCode:"+688"},{country:"U.S. Virgin Islands",countryCode:"VI",callingCode:"+1340"},{country:"Uganda",countryCode:"UG",callingCode:"+256"},{country:"Ukraine",countryCode:"UA",callingCode:"+380"},{country:"United Arab Emirates",countryCode:"AE",callingCode:"+971"},{country:"United Kingdom",countryCode:"GB",callingCode:"+44"},{country:"United States",countryCode:"US",callingCode:"+1"},{country:"United States Minor Outlying Islands",countryCode:"UM",callingCode:"+1"},{country:"Uruguay",countryCode:"UY",callingCode:"+598"},{country:"Uzbekistan",countryCode:"UZ",callingCode:"+998"},{country:"Vanuatu",countryCode:"VU",callingCode:"+678"},{country:"Vatican",countryCode:"VA",callingCode:"+379"},{country:"Venezuela",countryCode:"VE",callingCode:"+58"},{country:"Vietnam",countryCode:"VN",callingCode:"+84"},{country:"Wallis and Futuna",countryCode:"WF",callingCode:"+681"},{country:"Western Sahara",countryCode:"EH",callingCode:"+212"},{country:"Yemen",countryCode:"YE",callingCode:"+967"},{country:"Zambia",countryCode:"ZM",callingCode:"+260"},{country:"Zimbabwe",countryCode:"ZW",callingCode:"+263"}],c=o=>e.find((n=>n.countryCode===o));exports.PhoneInput=({placeholder:t,country:r,onChange:l,value:a,iconComponent:d,inputProps:u,onlyCountries:i,excludeCountries:C,preferredCountries:y,showDropdownIcon:g=!0,dialCodeInputField:s=!1,search:h=!0,disableDropdownOnly:p=!1,disableInput:m=!1,searchPlaceholder:S="Search country",showSearchIcon:M=!0,searchIconComponent:v,searchProps:I,searchNotFound:N="Not found",containerClass:w,buttonClass:B,dropdownClass:A,dropdownListClass:G,dropdownIconClass:T,searchContainerClass:x,searchInputClass:f,searchIconClass:b,inputClass:P,containerStyle:E,buttonStyle:L,dropdownStyle:R,dropdownListStyle:j,dropdownIconStyle:K,searchContainerStyle:F,searchInputStyle:D,searchIconStyle:U,inputStyle:k})=>{const[V,H]=n.useState({}),[O,W]=n.useState(!1),[z,Z]=n.useState(a||""),[Y,J]=n.useState(e),[q,Q]=n.useState(0),X=n.useRef(null),$=n.useRef(null);var _,oo;_=X,oo=()=>W(!1),n.useEffect((()=>{const o=o=>{_.current&&!_.current.contains(o.target)&&oo(o)};return document.addEventListener("mousedown",o),document.addEventListener("touchstart",o),()=>{document.removeEventListener("mousedown",o),document.removeEventListener("touchstart",o)}}),[_,oo]);const no=o=>{O&&("ArrowDown"===o.key&&(o.preventDefault(),Q((o=>o<Y.length-1?o+1:o))),"ArrowUp"===o.key&&(o.preventDefault(),Q((o=>o>0?o-1:0))),"Escape"===o.key&&W(!1),"Enter"===o.key&&q>=0&&(H(Y[q]),W(!1)))};return n.useEffect((()=>{if(q<0||q>Y.length||!$)return()=>{};if(O&&$&&Y.length>0){let n=Array.from($.current?.children);n[q]&&(o=n[q].offsetTop-65,h&&Y.length>0&&$.current?.scrollTo({top:o,behavior:"smooth"}))}var o}),[q]),n.useMemo((()=>{if(s){const o=z?.replace(V.callingCode,c(r).callingCode);console.log(o),Z(o.length>0?o:c(r).callingCode)}H(c(r))}),[r,s]),n.useMemo((()=>{J(((o,n,c)=>{let t=[];return t=n&&n.length>0?e.filter((o=>!n?.includes(o.countryCode))):o&&o?.length>0?e.filter((n=>o?.includes(n.countryCode))):e,t.sort(((o,n)=>Number(c?.includes(n.countryCode))-Number(c?.includes(o.countryCode))||c?.indexOf(o.countryCode)-c?.indexOf(n.countryCode)))})(i,C,y))}),[i,C,y]),o.jsx("div",{className:"simple-phone-input-sri198-container"+(w?" "+w:""),onKeyDown:o=>no(o),tabIndex:-1,style:E,children:o.jsxs("div",{className:"simple-phone-input-sri198-main",children:[o.jsxs("div",{className:"simple-phone-input-sri198-dropdown-container",ref:X,children:[o.jsxs("div",{onClick:()=>{p||W(!O)},className:s?"simple-phone-input-sri198-dropdown-container-button dial"+(B?" "+B:""):"simple-phone-input-sri198-dropdown-container-button"+(B?" "+B:""),style:L,children:[o.jsx("img",{src:"https://cdn.jsdelivr.net/gh/siamahnaf198/country-flags@main/img/"+V.countryCode+".svg",alt:V.country,width:"20px"}),!s&&o.jsx("span",{className:"simple-phone-input-sri198-selected-code",children:V.callingCode}),g&&!p&&o.jsx("div",{className:O?"simple-phone-input-sri198-dropdown-icon"+(T?" "+T:""):"simple-phone-input-sri198-dropdown-icon active"+(T?" "+T:""),style:K,children:d||o.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",preserveAspectRatio:"xMidYMid meet",viewBox:"0 0 24 24",children:o.jsx("path",{fill:"currentColor",d:"m7 10l5 5l5-5z"})})})]}),o.jsxs("ul",{className:O?"simple-phone-input-sri198-dropdown active"+(A?" "+A:""):"simple-phone-input-sri198-dropdown"+(A?" "+A:""),ref:$,style:R,children:[h&&o.jsxs("div",{className:"simple-phone-input-sri198-search-container"+(x?" "+x:""),style:F,children:[o.jsx("input",{placeholder:S,...I,onChange:o=>{const n=o.target.value;J(((o,n,c)=>{let t=[];return t=c&&c.length>0?e.filter((o=>!c?.includes(o.countryCode))):n&&n?.length>0?e.filter((o=>n?.includes(o.countryCode))):e,t.filter((n=>{const e=new RegExp(o.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&"),"gi");return n.country.match(e)}))})(n,i,C))},className:f??"",style:D}),M&&o.jsx("div",{className:"simple-phone-input-sri198-search-icon"+(b?" "+b:""),style:U,children:v??o.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",preserveAspectRatio:"xMidYMid meet",viewBox:"0 0 48 48",children:[o.jsxs("g",{fill:"#616161",children:[o.jsx("path",{d:"m29.175 31.99l2.828-2.827l12.019 12.019l-2.828 2.827z"}),o.jsx("circle",{cx:"20",cy:"20",r:"16"})]}),o.jsx("path",{fill:"#37474F",d:"m32.45 35.34l2.827-2.828l8.696 8.696l-2.828 2.828z"}),o.jsx("circle",{cx:"20",cy:"20",r:"13",fill:"#64B5F6"}),o.jsx("path",{fill:"#BBDEFB",d:"M26.9 14.2c-1.7-2-4.2-3.2-6.9-3.2s-5.2 1.2-6.9 3.2c-.4.4-.3 1.1.1 1.4c.4.4 1.1.3 1.4-.1C16 13.9 17.9 13 20 13s4 .9 5.4 2.5c.2.2.5.4.8.4c.2 0 .5-.1.6-.2c.4-.4.4-1.1.1-1.5z"})]})})]}),0===Y.length&&o.jsx("div",{className:"simple-phone-input-sri198-not-found",children:N}),Y.map(((n,e)=>o.jsxs("li",{onClick:()=>((o,n)=>{if(s){const n=z?.replace(V.callingCode,o.callingCode);Z(n.length>0?n:o.callingCode),l({country:o.country,code:o.countryCode,dialCode:o.callingCode,value:n.length>0?n:o.callingCode,valueWithoutPlus:n.length>0?n.replace("+",""):o.callingCode.replace("+","")})}else l({country:o.country,code:o.countryCode,dialCode:o.callingCode,value:o.callingCode+z,valueWithoutPlus:o.callingCode.replace("+","")+z});H(o),W(!1),Q(n)})(n,e),className:e===q?"active"+(G?" "+G:""):""+(G?" "+G:""),style:j,children:[o.jsx("img",{src:"https://cdn.jsdelivr.net/gh/siamahnaf198/country-flags@main/img/"+n.countryCode+".svg",alt:n.country,width:"20px"}),o.jsx("span",{className:"simple-phone-input-sri198-dropdown-text",children:n.country}),o.jsx("span",{className:"simple-phone-input-sri198-dropdown-country-code",children:n.callingCode})]},e)))]})]}),o.jsx("input",{className:"simple-phone-input-sri198-input "+(P?" "+P:""),placeholder:t,onChange:o=>{const n=o.target.value.replace(/\D/g,"");s?(l({country:V.country,code:V.countryCode,dialCode:V.callingCode,value:"+"+n,valueWithoutPlus:n}),Z("+"+n)):(Z(n),l({country:V.country,code:V.countryCode,dialCode:V.callingCode,value:V.callingCode+n,valueWithoutPlus:V.callingCode.replace("+","")+n}))},type:"tel",onInput:o=>{if(s){const n=z.slice(V.callingCode.length);o.target.value.startsWith(V.callingCode)?o.target.value=o.target.value:o.target.value=V.callingCode+n}},onKeyDown:o=>no(o),value:z,...u,style:k,disabled:m})]})})};
|
|
2
2
|
//# sourceMappingURL=index.js.map
|
package/dist/cjs/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":["../../node_modules/tslib/tslib.es6.js","../../src/Data/country-data.ts","../../src/Helpers/country-helper.ts","../../src/components/PhoneInput/PhoneInput.tsx","../../src/Helpers/hook.ts"],"sourcesContent":["/******************************************************************************\r\nCopyright (c) Microsoft Corporation.\r\n\r\nPermission to use, copy, modify, and/or distribute this software for any\r\npurpose with or without fee is hereby granted.\r\n\r\nTHE SOFTWARE IS PROVIDED \"AS IS\" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH\r\nREGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY\r\nAND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,\r\nINDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM\r\nLOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR\r\nOTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR\r\nPERFORMANCE OF THIS SOFTWARE.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };\r\n return extendStatics(d, b);\r\n};\r\n\r\nexport function __extends(d, b) {\r\n if (typeof b !== \"function\" && b !== null)\r\n throw new TypeError(\"Class extends value \" + String(b) + \" is not a constructor or null\");\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\r\n\r\nexport var __assign = function() {\r\n __assign = Object.assign || function __assign(t) {\r\n for (var s, i = 1, n = arguments.length; i < n; i++) {\r\n s = arguments[i];\r\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];\r\n }\r\n return t;\r\n }\r\n return __assign.apply(this, arguments);\r\n}\r\n\r\nexport function __rest(s, e) {\r\n var t = {};\r\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)\r\n t[p] = s[p];\r\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\")\r\n for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\r\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))\r\n t[p[i]] = s[p[i]];\r\n }\r\n return t;\r\n}\r\n\r\nexport function __decorate(decorators, target, key, desc) {\r\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\r\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\r\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\r\n return c > 3 && r && Object.defineProperty(target, key, r), r;\r\n}\r\n\r\nexport function __param(paramIndex, decorator) {\r\n return function (target, key) { decorator(target, key, paramIndex); }\r\n}\r\n\r\nexport function __metadata(metadataKey, metadataValue) {\r\n if (typeof Reflect === \"object\" && typeof Reflect.metadata === \"function\") return Reflect.metadata(metadataKey, metadataValue);\r\n}\r\n\r\nexport function __awaiter(thisArg, _arguments, P, generator) {\r\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\r\n return new (P || (P = Promise))(function (resolve, reject) {\r\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\r\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\r\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\r\n step((generator = generator.apply(thisArg, _arguments || [])).next());\r\n });\r\n}\r\n\r\nexport function __generator(thisArg, body) {\r\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\r\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\r\n function verb(n) { return function (v) { return step([n, v]); }; }\r\n function step(op) {\r\n if (f) throw new TypeError(\"Generator is already executing.\");\r\n while (g && (g = 0, op[0] && (_ = 0)), _) try {\r\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\r\n if (y = 0, t) op = [op[0] & 2, t.value];\r\n switch (op[0]) {\r\n case 0: case 1: t = op; break;\r\n case 4: _.label++; return { value: op[1], done: false };\r\n case 5: _.label++; y = op[1]; op = [0]; continue;\r\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\r\n default:\r\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\r\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\r\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\r\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\r\n if (t[2]) _.ops.pop();\r\n _.trys.pop(); continue;\r\n }\r\n op = body.call(thisArg, _);\r\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\r\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\r\n }\r\n}\r\n\r\nexport var __createBinding = Object.create ? (function(o, m, k, k2) {\r\n if (k2 === undefined) k2 = k;\r\n var desc = Object.getOwnPropertyDescriptor(m, k);\r\n if (!desc || (\"get\" in desc ? !m.__esModule : desc.writable || desc.configurable)) {\r\n desc = { enumerable: true, get: function() { return m[k]; } };\r\n }\r\n Object.defineProperty(o, k2, desc);\r\n}) : (function(o, m, k, k2) {\r\n if (k2 === undefined) k2 = k;\r\n o[k2] = m[k];\r\n});\r\n\r\nexport function __exportStar(m, o) {\r\n for (var p in m) if (p !== \"default\" && !Object.prototype.hasOwnProperty.call(o, p)) __createBinding(o, m, p);\r\n}\r\n\r\nexport function __values(o) {\r\n var s = typeof Symbol === \"function\" && Symbol.iterator, m = s && o[s], i = 0;\r\n if (m) return m.call(o);\r\n if (o && typeof o.length === \"number\") return {\r\n next: function () {\r\n if (o && i >= o.length) o = void 0;\r\n return { value: o && o[i++], done: !o };\r\n }\r\n };\r\n throw new TypeError(s ? \"Object is not iterable.\" : \"Symbol.iterator is not defined.\");\r\n}\r\n\r\nexport function __read(o, n) {\r\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\r\n if (!m) return o;\r\n var i = m.call(o), r, ar = [], e;\r\n try {\r\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\r\n }\r\n catch (error) { e = { error: error }; }\r\n finally {\r\n try {\r\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\r\n }\r\n finally { if (e) throw e.error; }\r\n }\r\n return ar;\r\n}\r\n\r\n/** @deprecated */\r\nexport function __spread() {\r\n for (var ar = [], i = 0; i < arguments.length; i++)\r\n ar = ar.concat(__read(arguments[i]));\r\n return ar;\r\n}\r\n\r\n/** @deprecated */\r\nexport function __spreadArrays() {\r\n for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length;\r\n for (var r = Array(s), k = 0, i = 0; i < il; i++)\r\n for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)\r\n r[k] = a[j];\r\n return r;\r\n}\r\n\r\nexport function __spreadArray(to, from, pack) {\r\n if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {\r\n if (ar || !(i in from)) {\r\n if (!ar) ar = Array.prototype.slice.call(from, 0, i);\r\n ar[i] = from[i];\r\n }\r\n }\r\n return to.concat(ar || Array.prototype.slice.call(from));\r\n}\r\n\r\nexport function __await(v) {\r\n return this instanceof __await ? (this.v = v, this) : new __await(v);\r\n}\r\n\r\nexport function __asyncGenerator(thisArg, _arguments, generator) {\r\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\r\n var g = generator.apply(thisArg, _arguments || []), i, q = [];\r\n return i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () { return this; }, i;\r\n function verb(n) { if (g[n]) i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; }\r\n function resume(n, v) { try { step(g[n](v)); } catch (e) { settle(q[0][3], e); } }\r\n function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); }\r\n function fulfill(value) { resume(\"next\", value); }\r\n function reject(value) { resume(\"throw\", value); }\r\n function settle(f, v) { if (f(v), q.shift(), q.length) resume(q[0][0], q[0][1]); }\r\n}\r\n\r\nexport function __asyncDelegator(o) {\r\n var i, p;\r\n return i = {}, verb(\"next\"), verb(\"throw\", function (e) { throw e; }), verb(\"return\"), i[Symbol.iterator] = function () { return this; }, i;\r\n function verb(n, f) { i[n] = o[n] ? function (v) { return (p = !p) ? { value: __await(o[n](v)), done: n === \"return\" } : f ? f(v) : v; } : f; }\r\n}\r\n\r\nexport function __asyncValues(o) {\r\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\r\n var m = o[Symbol.asyncIterator], i;\r\n return m ? m.call(o) : (o = typeof __values === \"function\" ? __values(o) : o[Symbol.iterator](), i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () { return this; }, i);\r\n function verb(n) { i[n] = o[n] && function (v) { return new Promise(function (resolve, reject) { v = o[n](v), settle(resolve, reject, v.done, v.value); }); }; }\r\n function settle(resolve, reject, d, v) { Promise.resolve(v).then(function(v) { resolve({ value: v, done: d }); }, reject); }\r\n}\r\n\r\nexport function __makeTemplateObject(cooked, raw) {\r\n if (Object.defineProperty) { Object.defineProperty(cooked, \"raw\", { value: raw }); } else { cooked.raw = raw; }\r\n return cooked;\r\n};\r\n\r\nvar __setModuleDefault = Object.create ? (function(o, v) {\r\n Object.defineProperty(o, \"default\", { enumerable: true, value: v });\r\n}) : function(o, v) {\r\n o[\"default\"] = v;\r\n};\r\n\r\nexport function __importStar(mod) {\r\n if (mod && mod.__esModule) return mod;\r\n var result = {};\r\n if (mod != null) for (var k in mod) if (k !== \"default\" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);\r\n __setModuleDefault(result, mod);\r\n return result;\r\n}\r\n\r\nexport function __importDefault(mod) {\r\n return (mod && mod.__esModule) ? mod : { default: mod };\r\n}\r\n\r\nexport function __classPrivateFieldGet(receiver, state, kind, f) {\r\n if (kind === \"a\" && !f) throw new TypeError(\"Private accessor was defined without a getter\");\r\n if (typeof state === \"function\" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError(\"Cannot read private member from an object whose class did not declare it\");\r\n return kind === \"m\" ? f : kind === \"a\" ? f.call(receiver) : f ? f.value : state.get(receiver);\r\n}\r\n\r\nexport function __classPrivateFieldSet(receiver, state, value, kind, f) {\r\n if (kind === \"m\") throw new TypeError(\"Private method is not writable\");\r\n if (kind === \"a\" && !f) throw new TypeError(\"Private accessor was defined without a setter\");\r\n if (typeof state === \"function\" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError(\"Cannot write private member to an object whose class did not declare it\");\r\n return (kind === \"a\" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value)), value;\r\n}\r\n\r\nexport function __classPrivateFieldIn(state, receiver) {\r\n if (receiver === null || (typeof receiver !== \"object\" && typeof receiver !== \"function\")) throw new TypeError(\"Cannot use 'in' operator on non-object\");\r\n return typeof state === \"function\" ? receiver === state : state.has(receiver);\r\n}\r\n",null,null,null,null],"names":["__assign","Object","assign","t","s","i","n","arguments","length","p","prototype","hasOwnProperty","call","apply","this","countryData","country","countryCode","callingCode","getDefaultCountry","code","find","item","_a","ref","handler","placeholder","onChange","value","iconComponent","inputProps","onlyCountries","excludeCountries","preferredCountries","_b","showDropdownIcon","_c","dialCodeInputField","_d","search","_e","searchPlaceholder","_f","showSearchIcon","searchIconComponent","searchProps","_g","searchNotFound","_h","React","useState","selected","setSelected","_j","isDropdown","setDropdown","_k","inputValue","setInputValue","_l","countryDataInfo","setCountryData","_m","cursor","setCursor","dropdownRef","useRef","listRef","useEffect","listener","event","current","contains","target","document","addEventListener","removeEventListener","keyBoardNav","e","key","preventDefault","c","listItems","Array","from","children","position","scrollTo","top","behavior","scrollIntoView","offsetTop","useMemo","result","replace","console","log","onlyCountry","excludeCountry","preferredCountry","filter","includes","sort","a","b","Number","indexOf","_jsx","className","onKeyDown","tabIndex","_jsxs","jsxs","onClick","jsx","src","alt","width","xmlns","height","preserveAspectRatio","viewBox","fill","d","regex","RegExp","match","getBySearch","cx","cy","r","map","handleSelected","onlyNumber","type","onInput","oldVal","slice","startsWith"],"mappings":"mEA+BWA,EAAW,WAQlB,OAPAA,EAAWC,OAAOC,QAAU,SAAkBC,GAC1C,IAAK,IAAIC,EAAGC,EAAI,EAAGC,EAAIC,UAAUC,OAAQH,EAAIC,EAAGD,IAE5C,IAAK,IAAII,KADTL,EAAIG,UAAUF,GACOJ,OAAOS,UAAUC,eAAeC,KAAKR,EAAGK,KAAIN,EAAEM,GAAKL,EAAEK,IAE9E,OAAON,CACV,EACMH,EAASa,MAAMC,KAAMP,UAChC,ECxCaQ,EAAc,CACvB,CACIC,QAAS,cACTC,YAAa,KACbC,YAAa,OAEjB,CACIF,QAAS,UACTC,YAAa,KACbC,YAAa,QAEjB,CACIF,QAAS,UACTC,YAAa,KACbC,YAAa,QAEjB,CACIF,QAAS,iBACTC,YAAa,KACbC,YAAa,SAEjB,CACIF,QAAS,UACTC,YAAa,KACbC,YAAa,QAEjB,CACIF,QAAS,SACTC,YAAa,KACbC,YAAa,QAEjB,CACIF,QAAS,WACTC,YAAa,KACbC,YAAa,SAEjB,CACIF,QAAS,aACTC,YAAa,KACbC,YAAa,QAEjB,CACIF,QAAS,sBACTC,YAAa,KACbC,YAAa,SAEjB,CACIF,QAAS,YACTC,YAAa,KACbC,YAAa,OAEjB,CACIF,QAAS,UACTC,YAAa,KACbC,YAAa,QAEjB,CACIF,QAAS,QACTC,YAAa,KACbC,YAAa,QAEjB,CACIF,QAAS,YACTC,YAAa,KACbC,YAAa,OAEjB,CACIF,QAAS,UACTC,YAAa,KACbC,YAAa,OAEjB,CACIF,QAAS,aACTC,YAAa,KACbC,YAAa,QAEjB,CACIF,QAAS,UACTC,YA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B,IAAMmG,EAAS/E,EAAWgF,MAAMtF,EAASjC,YAAYV,QACjDsE,EAAEL,OAAO7C,MAAM8G,WAAWvF,EAASjC,aACnC4D,EAAEL,OAAO7C,MAAQkD,EAAEL,OAAO7C,MAE1BkD,EAAEL,OAAO7C,MAAQuB,EAASjC,YAAcsH,CAE/C,GAEL3B,UAAW,SAAC/B,GAAM,OAAAD,EAAYC,EAAE,EAChClD,MAAO6B,GACH3B,UAKxB"}
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../../src/Data/country-data.ts","../../src/Helpers/country-helper.ts","../../src/components/PhoneInput/PhoneInput.tsx","../../src/Helpers/hook.ts"],"sourcesContent":[null,null,null,null],"names":["countryData","country","countryCode","callingCode","getDefaultCountry","code","find","item","placeholder","onChange","value","iconComponent","inputProps","onlyCountries","excludeCountries","preferredCountries","showDropdownIcon","dialCodeInputField","search","disableDropdownOnly","disableInput","searchPlaceholder","showSearchIcon","searchIconComponent","searchProps","searchNotFound","containerClass","buttonClass","dropdownClass","dropdownListClass","dropdownIconClass","searchContainerClass","searchInputClass","searchIconClass","inputClass","containerStyle","buttonStyle","dropdownStyle","dropdownListStyle","dropdownIconStyle","searchContainerStyle","searchInputStyle","searchIconStyle","inputStyle","selected","setSelected","React","useState","isDropdown","setDropdown","inputValue","setInputValue","countryDataInfo","setCountryData","cursor","setCursor","dropdownRef","useRef","listRef","ref","handler","useEffect","listener","event","current","contains","target","document","addEventListener","removeEventListener","keyBoardNav","e","key","preventDefault","c","length","listItems","Array","from","children","position","offsetTop","scrollTo","top","behavior","useMemo","result","replace","console","log","onlyCountry","excludeCountry","preferredCountry","countries","filter","includes","sort","a","b","Number","indexOf","getCountryByFilter","_jsx","className","onKeyDown","tabIndex","style","_jsxs","jsxs","onClick","jsx","src","alt","width","xmlns","height","preserveAspectRatio","viewBox","fill","d","regex","RegExp","match","getBySearch","cx","cy","r","map","i","dialCode","valueWithoutPlus","handleSelected","onlyNumber","type","onInput","oldVal","slice","startsWith","disabled"],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EACP+F,SAAUtH,QAIxB"}
|
|
@@ -1,9 +1,16 @@
|
|
|
1
1
|
import React from "react";
|
|
2
2
|
import "./PhoneInput.css";
|
|
3
|
+
export interface PhoneInputResponseType {
|
|
4
|
+
country: string;
|
|
5
|
+
code: string;
|
|
6
|
+
dialCode: string;
|
|
7
|
+
value: string;
|
|
8
|
+
valueWithoutPlus: string;
|
|
9
|
+
}
|
|
3
10
|
interface Props {
|
|
4
11
|
placeholder: string;
|
|
5
12
|
country: string;
|
|
6
|
-
onChange: (e:
|
|
13
|
+
onChange: (e: PhoneInputResponseType) => void;
|
|
7
14
|
value?: string;
|
|
8
15
|
iconComponent?: React.ReactNode;
|
|
9
16
|
inputProps?: React.DetailedHTMLProps<React.InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>;
|
|
@@ -12,12 +19,32 @@ interface Props {
|
|
|
12
19
|
preferredCountries?: string[];
|
|
13
20
|
showDropdownIcon?: boolean;
|
|
14
21
|
dialCodeInputField?: boolean;
|
|
22
|
+
disableDropdownOnly?: boolean;
|
|
23
|
+
disableInput?: boolean;
|
|
15
24
|
search?: boolean;
|
|
16
25
|
searchPlaceholder?: string;
|
|
17
26
|
showSearchIcon?: boolean;
|
|
18
27
|
searchIconComponent?: React.ReactNode;
|
|
19
28
|
searchProps?: React.DetailedHTMLProps<React.InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>;
|
|
20
29
|
searchNotFound?: string;
|
|
30
|
+
containerClass?: string;
|
|
31
|
+
buttonClass?: string;
|
|
32
|
+
dropdownClass?: string;
|
|
33
|
+
dropdownListClass?: string;
|
|
34
|
+
dropdownIconClass?: string;
|
|
35
|
+
searchContainerClass?: string;
|
|
36
|
+
searchInputClass?: string;
|
|
37
|
+
searchIconClass?: string;
|
|
38
|
+
inputClass?: string;
|
|
39
|
+
containerStyle?: React.CSSProperties;
|
|
40
|
+
buttonStyle?: React.CSSProperties;
|
|
41
|
+
dropdownStyle?: React.CSSProperties;
|
|
42
|
+
dropdownListStyle?: React.CSSProperties;
|
|
43
|
+
dropdownIconStyle?: React.CSSProperties;
|
|
44
|
+
searchContainerStyle?: React.CSSProperties;
|
|
45
|
+
searchInputStyle?: React.CSSProperties;
|
|
46
|
+
searchIconStyle?: React.CSSProperties;
|
|
47
|
+
inputStyle?: React.CSSProperties;
|
|
21
48
|
}
|
|
22
|
-
declare const PhoneInput: ({ placeholder, country, onChange, value, iconComponent, inputProps, onlyCountries, excludeCountries, preferredCountries, showDropdownIcon, dialCodeInputField, search, searchPlaceholder, showSearchIcon, searchIconComponent, searchProps, searchNotFound }: Props) => JSX.Element;
|
|
49
|
+
declare const PhoneInput: ({ placeholder, country, onChange, value, iconComponent, inputProps, onlyCountries, excludeCountries, preferredCountries, showDropdownIcon, dialCodeInputField, search, disableDropdownOnly, disableInput, searchPlaceholder, showSearchIcon, searchIconComponent, searchProps, searchNotFound, containerClass, buttonClass, dropdownClass, dropdownListClass, dropdownIconClass, searchContainerClass, searchInputClass, searchIconClass, inputClass, containerStyle, buttonStyle, dropdownStyle, dropdownListStyle, dropdownIconStyle, searchContainerStyle, searchInputStyle, searchIconStyle, inputStyle }: Props) => JSX.Element;
|
|
23
50
|
export default PhoneInput;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { default } from "./PhoneInput";
|
|
1
|
+
export { default, PhoneInputResponseType } from "./PhoneInput";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { default as PhoneInput } from "./PhoneInput";
|
|
1
|
+
export { default as PhoneInput, PhoneInputResponseType } from "./PhoneInput";
|
package/dist/esm/index.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{jsx as o,jsxs as n}from"react/jsx-runtime";import c from"react";var e=function(){return e=Object.assign||function(o){for(var n,c=1,e=arguments.length;c<e;c++)for(var r in n=arguments[c])Object.prototype.hasOwnProperty.call(n,r)&&(o[r]=n[r]);return o},e.apply(this,arguments)},r=[{country:"Afghanistan",countryCode:"AF",callingCode:"+93"},{country:"Albania",countryCode:"AL",callingCode:"+355"},{country:"Algeria",countryCode:"DZ",callingCode:"+213"},{country:"American Samoa",countryCode:"AS",callingCode:"+1684"},{country:"Andorra",countryCode:"AD",callingCode:"+376"},{country:"Angola",countryCode:"AO",callingCode:"+244"},{country:"Anguilla",countryCode:"AI",callingCode:"+1264"},{country:"Antarctica",countryCode:"AQ",callingCode:"+672"},{country:"Antigua and Barbuda",countryCode:"AG",callingCode:"+1268"},{country:"Argentina",countryCode:"AR",callingCode:"+54"},{country:"Armenia",countryCode:"AM",callingCode:"+374"},{country:"Aruba",countryCode:"AW",callingCode:"+297"},{country:"Australia",countryCode:"AU",callingCode:"+61"},{country:"Austria",countryCode:"AT",callingCode:"+43"},{country:"Azerbaijan",countryCode:"AZ",callingCode:"+994"},{country:"Bahamas",countryCode:"BS",callingCode:"+1242"},{country:"Bahrain",countryCode:"BH",callingCode:"+973"},{country:"Bangladesh",countryCode:"BD",callingCode:"+880"},{country:"Barbados",countryCode:"BB",callingCode:"+1246"},{country:"Belarus",countryCode:"BY",callingCode:"+375"},{country:"Belgium",countryCode:"BE",callingCode:"+32"},{country:"Belize",countryCode:"BZ",callingCode:"+501"},{country:"Benin",countryCode:"BJ",callingCode:"+229"},{country:"Bermuda",countryCode:"BM",callingCode:"+1441"},{country:"Bhutan",countryCode:"BT",callingCode:"+975"},{country:"Bolivia",countryCode:"BO",callingCode:"+591"},{country:"Bosnia and Herzegovina",countryCode:"BA",callingCode:"+387"},{country:"Botswana",countryCode:"BW",callingCode:"+267"},{country:"Bouvet Island",countryCode:"BV",callingCode:"+47"},{country:"Brazil",countryCode:"BR",callingCode:"+55"},{country:"British Indian Ocean Territory",countryCode:"IO",callingCode:"+246"},{country:"British Virgin Islands",countryCode:"VG",callingCode:"+1284"},{country:"Brunei",countryCode:"BN",callingCode:"+673"},{country:"Bulgaria",countryCode:"BG",callingCode:"+359"},{country:"Burkina Faso",countryCode:"BF",callingCode:"+226"},{country:"Burundi",countryCode:"BI",callingCode:"+257"},{country:"Cambodia",countryCode:"KH",callingCode:"+855"},{country:"Cameroon",countryCode:"CM",callingCode:"+237"},{country:"Canada",countryCode:"CA",callingCode:"+1"},{country:"Cape Verde",countryCode:"CV",callingCode:"+238"},{country:"Cayman Islands",countryCode:"KY",callingCode:"+1345"},{country:"Central African Republic",countryCode:"CF",callingCode:"+236"},{country:"Chad",countryCode:"TD",callingCode:"+235"},{country:"Chile",countryCode:"CL",callingCode:"+56"},{country:"China",countryCode:"CN",callingCode:"+86"},{country:"Christmas Island",countryCode:"CX",callingCode:"+61"},{country:"Cocos Islands",countryCode:"CC",callingCode:"+61"},{country:"Colombia",countryCode:"CO",callingCode:"+57"},{country:"Comoros",countryCode:"KM",callingCode:"+269"},{country:"Cook Islands",countryCode:"CK",callingCode:"+682"},{country:"Costa Rica",countryCode:"CR",callingCode:"+506"},{country:"Croatia",countryCode:"HR",callingCode:"+385"},{country:"Cuba",countryCode:"CU",callingCode:"+53"},{country:"Cyprus",countryCode:"CY",callingCode:"+357"},{country:"Czech Republic",countryCode:"CZ",callingCode:"+420"},{country:"Democratic Republic of the Congo",countryCode:"CD",callingCode:"+243"},{country:"Denmark",countryCode:"DK",callingCode:"+45"},{country:"Djibouti",countryCode:"DJ",callingCode:"+253"},{country:"Dominica",countryCode:"DM",callingCode:"+1767"},{country:"Dominican Republic",countryCode:"DO",callingCode:"+1"},{country:"East Timor",countryCode:"TL",callingCode:"+670"},{country:"Ecuador",countryCode:"EC",callingCode:"+593"},{country:"Egypt",countryCode:"EG",callingCode:"+20"},{country:"El Salvador",countryCode:"SV",callingCode:"+503"},{country:"Equatorial Guinea",countryCode:"GQ",callingCode:"+240"},{country:"Eritrea",countryCode:"ER",callingCode:"+291"},{country:"Estonia",countryCode:"EE",callingCode:"+372"},{country:"Ethiopia",countryCode:"ET",callingCode:"+251"},{country:"Falkland Islands",countryCode:"FK",callingCode:"+500"},{country:"Faroe Islands",countryCode:"FO",callingCode:"+298"},{country:"Fiji",countryCode:"FJ",callingCode:"+679"},{country:"Finland",countryCode:"FI",callingCode:"+358"},{country:"France",countryCode:"FR",callingCode:"+33"},{country:"French Guiana",countryCode:"GF",callingCode:"+594"},{country:"French Polynesia",countryCode:"PF",callingCode:"+689"},{country:"French Southern Territories",countryCode:"TF",callingCode:"+262"},{country:"Gabon",countryCode:"GA",callingCode:"+241"},{country:"Gambia",countryCode:"GM",callingCode:"+220"},{country:"Georgia",countryCode:"GE",callingCode:"+995"},{country:"Germany",countryCode:"DE",callingCode:"+49"},{country:"Ghana",countryCode:"GH",callingCode:"+233"},{country:"Gibraltar",countryCode:"GI",callingCode:"+350"},{country:"Greece",countryCode:"GR",callingCode:"+30"},{country:"Greenland",countryCode:"GL",callingCode:"+299"},{country:"Grenada",countryCode:"GD",callingCode:"+473"},{country:"Guadeloupe",countryCode:"GP",callingCode:"+590"},{country:"Guam",countryCode:"GU",callingCode:"+1671"},{country:"Guatemala",countryCode:"GT",callingCode:"+502"},{country:"Guinea",countryCode:"GN",callingCode:"+224"},{country:"Guinea-Bissau",countryCode:"GW",callingCode:"+245"},{country:"Guyana",countryCode:"GY",callingCode:"+592"},{country:"Haiti",countryCode:"HT",callingCode:"+509"},{country:"Honduras",countryCode:"HN",callingCode:"+504"},{country:"Hong Kong",countryCode:"HK",callingCode:"+852"},{country:"Hungary",countryCode:"HU",callingCode:"+36"},{country:"Iceland",countryCode:"IS",callingCode:"+354"},{country:"India",countryCode:"IN",callingCode:"+91"},{country:"Indonesia",countryCode:"ID",callingCode:"+62"},{country:"Iran",countryCode:"IR",callingCode:"+98"},{country:"Iraq",countryCode:"IQ",callingCode:"+964"},{country:"Ireland",countryCode:"IE",callingCode:"+353"},{country:"Israel",countryCode:"IL",callingCode:"+972"},{country:"Italy",countryCode:"IT",callingCode:"+39"},{country:"Ivory Coast",countryCode:"CI",callingCode:"+225"},{country:"Jamaica",countryCode:"JM",callingCode:"+1876"},{country:"Japan",countryCode:"JP",callingCode:"+81"},{country:"Jordan",countryCode:"JO",callingCode:"+962"},{country:"Kazakhstan",countryCode:"KZ",callingCode:"+7"},{country:"Kenya",countryCode:"KE",callingCode:"+254"},{country:"Kiribati",countryCode:"KI",callingCode:"+686"},{country:"Kuwait",countryCode:"KW",callingCode:"+965"},{country:"Kyrgyzstan",countryCode:"KG",callingCode:"+996"},{country:"Laos",countryCode:"LA",callingCode:"+856"},{country:"Latvia",countryCode:"LV",callingCode:"+371"},{country:"Lebanon",countryCode:"LB",callingCode:"+961"},{country:"Lesotho",countryCode:"LS",callingCode:"+266"},{country:"Liberia",countryCode:"LR",callingCode:"+231"},{country:"Libya",countryCode:"LY",callingCode:"+218"},{country:"Liechtenstein",countryCode:"LI",callingCode:"+423"},{country:"Lithuania",countryCode:"LT",callingCode:"+370"},{country:"Luxembourg",countryCode:"LU",callingCode:"+352"},{country:"Macao",countryCode:"MO",callingCode:"+853"},{country:"Macedonia",countryCode:"MK",callingCode:"+389"},{country:"Madagascar",countryCode:"MG",callingCode:"+261"},{country:"Malawi",countryCode:"MW",callingCode:"+265"},{country:"Malaysia",countryCode:"MY",callingCode:"+60"},{country:"Maldives",countryCode:"MV",callingCode:"+960"},{country:"Mali",countryCode:"ML",callingCode:"+223"},{country:"Malta",countryCode:"MT",callingCode:"+356"},{country:"Marshall Islands",countryCode:"MH",callingCode:"+692"},{country:"Martinique",countryCode:"MQ",callingCode:"+596"},{country:"Mauritania",countryCode:"MR",callingCode:"+222"},{country:"Mauritius",countryCode:"MU",callingCode:"+230"},{country:"Mayotte",countryCode:"YT",callingCode:"+262"},{country:"Mexico",countryCode:"MX",callingCode:"+52"},{country:"Micronesia",countryCode:"FM",callingCode:"+691"},{country:"Moldova",countryCode:"MD",callingCode:"+373"},{country:"Monaco",countryCode:"MC",callingCode:"+377"},{country:"Mongolia",countryCode:"MN",callingCode:"+976"},{country:"Montserrat",countryCode:"MS",callingCode:"+1664"},{country:"Morocco",countryCode:"MA",callingCode:"+212"},{country:"Mozambique",countryCode:"MZ",callingCode:"+258"},{country:"Myanmar",countryCode:"MM",callingCode:"+95"},{country:"Namibia",countryCode:"NA",callingCode:"+264"},{country:"Nauru",countryCode:"NR",callingCode:"+674"},{country:"Nepal",countryCode:"NP",callingCode:"+977"},{country:"Netherlands",countryCode:"NL",callingCode:"+31"},{country:"New Caledonia",countryCode:"NC",callingCode:"+687"},{country:"New Zealand",countryCode:"NZ",callingCode:"+64"},{country:"Nicaragua",countryCode:"NI",callingCode:"+505"},{country:"Niger",countryCode:"NE",callingCode:"+227"},{country:"Nigeria",countryCode:"NG",callingCode:"+234"},{country:"Niue",countryCode:"NU",callingCode:"+683"},{country:"Norfolk Island",countryCode:"NF",callingCode:"+672"},{country:"North Korea",countryCode:"KP",callingCode:"+850"},{country:"Northern Mariana Islands",countryCode:"MP",callingCode:"+1670"},{country:"Norway",countryCode:"NO",callingCode:"+47"},{country:"Oman",countryCode:"OM",callingCode:"+968"},{country:"Pakistan",countryCode:"PK",callingCode:"+92"},{country:"Palau",countryCode:"PW",callingCode:"+680"},{country:"Palestinian Territory",countryCode:"PS",callingCode:"+970"},{country:"Panama",countryCode:"PA",callingCode:"+507"},{country:"Papua New Guinea",countryCode:"PG",callingCode:"+675"},{country:"Paraguay",countryCode:"PY",callingCode:"+595"},{country:"Peru",countryCode:"PE",callingCode:"+51"},{country:"Philippines",countryCode:"PH",callingCode:"+63"},{country:"Pitcairn",countryCode:"PN",callingCode:"+872"},{country:"Poland",countryCode:"PL",callingCode:"+48"},{country:"Portugal",countryCode:"PT",callingCode:"+351"},{country:"Puerto Rico",countryCode:"PR",callingCode:"+1"},{country:"Qatar",countryCode:"QA",callingCode:"+974"},{country:"Republic of the Congo",countryCode:"CG",callingCode:"+242"},{country:"Reunion",countryCode:"RE",callingCode:"+262"},{country:"Romania",countryCode:"RO",callingCode:"+40"},{country:"Russia",countryCode:"RU",callingCode:"+7"},{country:"Rwanda",countryCode:"RW",callingCode:"+250"},{country:"Saint Helena",countryCode:"SH",callingCode:"+290"},{country:"Saint Kitts and Nevis",countryCode:"KN",callingCode:"+1869"},{country:"Saint Lucia",countryCode:"LC",callingCode:"+1758"},{country:"Saint Pierre and Miquelon",countryCode:"PM",callingCode:"+508"},{country:"Saint Vincent and the Grenadines",countryCode:"VC",callingCode:"+1784"},{country:"Samoa",countryCode:"WS",callingCode:"+685"},{country:"San Marino",countryCode:"SM",callingCode:"+378"},{country:"Sao Tome and Principe",countryCode:"ST",callingCode:"+239"},{country:"Saudi Arabia",countryCode:"SA",callingCode:"+966"},{country:"Senegal",countryCode:"SN",callingCode:"+221"},{country:"Seychelles",countryCode:"SC",callingCode:"+248"},{country:"Sierra Leone",countryCode:"SL",callingCode:"+232"},{country:"Singapore",countryCode:"SG",callingCode:"+65"},{country:"Slovakia",countryCode:"SK",callingCode:"+421"},{country:"Slovenia",countryCode:"SI",callingCode:"+386"},{country:"Solomon Islands",countryCode:"SB",callingCode:"+677"},{country:"Somalia",countryCode:"SO",callingCode:"+252"},{country:"South Africa",countryCode:"ZA",callingCode:"+27"},{country:"South Georgia and the South Sandwich Islands",countryCode:"GS",callingCode:"+500"},{country:"South Korea",countryCode:"KR",callingCode:"+82"},{country:"Spain",countryCode:"ES",callingCode:"+34"},{country:"Sri Lanka",countryCode:"LK",callingCode:"+94"},{country:"Sudan",countryCode:"SD",callingCode:"+249"},{country:"Suriname",countryCode:"SR",callingCode:"+597"},{country:"Svalbard and Jan Mayen",countryCode:"SJ",callingCode:"+47"},{country:"Swaziland",countryCode:"SZ",callingCode:"+268"},{country:"Sweden",countryCode:"SE",callingCode:"+46"},{country:"Switzerland",countryCode:"CH",callingCode:"+41"},{country:"Syria",countryCode:"SY",callingCode:"+963"},{country:"Taiwan",countryCode:"TW",callingCode:"+886"},{country:"Tajikistan",countryCode:"TJ",callingCode:"+992"},{country:"Tanzania",countryCode:"TZ",callingCode:"+255"},{country:"Thailand",countryCode:"TH",callingCode:"+66"},{country:"Togo",countryCode:"TG",callingCode:"+228"},{country:"Tokelau",countryCode:"TK",callingCode:"+690"},{country:"Tonga",countryCode:"TO",callingCode:"+676"},{country:"Trinidad and Tobago",countryCode:"TT",callingCode:"+1868"},{country:"Tunisia",countryCode:"TN",callingCode:"+216"},{country:"Turkey",countryCode:"TR",callingCode:"+90"},{country:"Turkmenistan",countryCode:"TM",callingCode:"+993"},{country:"Turks and Caicos Islands",countryCode:"TC",callingCode:"+1649"},{country:"Tuvalu",countryCode:"TV",callingCode:"+688"},{country:"U.S. Virgin Islands",countryCode:"VI",callingCode:"+1340"},{country:"Uganda",countryCode:"UG",callingCode:"+256"},{country:"Ukraine",countryCode:"UA",callingCode:"+380"},{country:"United Arab Emirates",countryCode:"AE",callingCode:"+971"},{country:"United Kingdom",countryCode:"GB",callingCode:"+44"},{country:"United States",countryCode:"US",callingCode:"+1"},{country:"United States Minor Outlying Islands",countryCode:"UM",callingCode:"+1"},{country:"Uruguay",countryCode:"UY",callingCode:"+598"},{country:"Uzbekistan",countryCode:"UZ",callingCode:"+998"},{country:"Vanuatu",countryCode:"VU",callingCode:"+678"},{country:"Vatican",countryCode:"VA",callingCode:"+379"},{country:"Venezuela",countryCode:"VE",callingCode:"+58"},{country:"Vietnam",countryCode:"VN",callingCode:"+84"},{country:"Wallis and Futuna",countryCode:"WF",callingCode:"+681"},{country:"Western Sahara",countryCode:"EH",callingCode:"+212"},{country:"Yemen",countryCode:"YE",callingCode:"+967"},{country:"Zambia",countryCode:"ZM",callingCode:"+260"},{country:"Zimbabwe",countryCode:"ZW",callingCode:"+263"}],t=function(o){return r.find((function(n){return n.countryCode===o}))};var l=function(l){var u,a,d=l.placeholder,i=l.country,C=l.onChange,y=l.value,g=l.iconComponent,s=l.inputProps,h=l.onlyCountries,p=l.excludeCountries,m=l.preferredCountries,v=l.showDropdownIcon,f=void 0===v||v,S=l.dialCodeInputField,M=void 0!==S&&S,N=l.search,B=void 0===N||N,A=l.searchPlaceholder,I=void 0===A?"Search country":A,G=l.showSearchIcon,w=void 0===G||G,T=l.searchIconComponent,b=l.searchProps,E=l.searchNotFound,P=void 0===E?"Not found":E,L=c.useState({}),R=L[0],K=L[1],F=c.useState(!1),D=F[0],U=F[1],k=c.useState(y||""),O=k[0],V=k[1],x=c.useState(r),H=x[0],z=x[1],Z=c.useState(0),W=Z[0],Y=Z[1],J=c.useRef(null),j=c.useRef(null);u=J,a=function(){return U(!1)},c.useEffect((function(){var o=function(o){u.current&&!u.current.contains(o.target)&&a(o)};return document.addEventListener("mousedown",o),document.addEventListener("touchstart",o),function(){document.removeEventListener("mousedown",o),document.removeEventListener("touchstart",o)}}),[u,a]);var Q=function(o){D&&("ArrowDown"===o.key&&(o.preventDefault(),Y((function(o){return o<H.length-1?o+1:o}))),"ArrowUp"===o.key&&(o.preventDefault(),Y((function(o){return o>0?o-1:0}))),"Escape"===o.key&&U(!1),"Enter"===o.key&&W>=0&&(K(H[W]),U(!1)))};return c.useEffect((function(){var o;if(W<0||W>H.length||!j)return function(){};if(D&&j&&H.length>0){var n=Array.from(null===(o=j.current)||void 0===o?void 0:o.children);n[W]&&function(o){var n;B&&H.length>0&&(null===(n=j.current)||void 0===n||n.scrollTo({top:o,behavior:"smooth"}))}(n[W].offsetTop-65)}}),[W]),c.useMemo((function(){if(M){var o=null==O?void 0:O.replace(R.callingCode,t(i).callingCode);console.log(o),V(o.length>0?o:t(i).callingCode)}K(t(i))}),[i,M]),c.useMemo((function(){var o,n,c;z((o=h,c=m,((n=p)&&n.length>0?r.filter((function(o){return!(null==n?void 0:n.includes(o.countryCode))})):o&&(null==o?void 0:o.length)>0?r.filter((function(n){return null==o?void 0:o.includes(n.countryCode)})):r).sort((function(o,n){return Number(null==c?void 0:c.includes(n.countryCode))-Number(null==c?void 0:c.includes(o.countryCode))||(null==c?void 0:c.indexOf(o.countryCode))-(null==c?void 0:c.indexOf(n.countryCode))}))))}),[h,p,m]),o("div",e({className:"simple-phone-input-sri198-container",onKeyDown:function(o){return Q(o)},tabIndex:-1},{children:n("div",e({className:"simple-phone-input-sri198-main"},{children:[n("div",e({className:"simple-phone-input-sri198-dropdown-container",ref:J},{children:[n("div",e({onClick:function(){return U(!D)},className:M?"simple-phone-input-sri198-dropdown-container-button dial":"simple-phone-input-sri198-dropdown-container-button"},{children:[o("img",{src:"https://cdn.jsdelivr.net/gh/siamahnaf198/country-flags@main/img/"+R.countryCode+".svg",alt:R.country,width:"20px"}),!M&&o("span",e({className:"simple-phone-input-sri198-selected-code"},{children:R.callingCode})),f&&o("div",e({className:D?"simple-phone-input-sri198-dropdown-icon":"simple-phone-input-sri198-dropdown-icon active"},{children:g||o("svg",e({xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",preserveAspectRatio:"xMidYMid meet",viewBox:"0 0 24 24"},{children:o("path",{fill:"currentColor",d:"m7 10l5 5l5-5z"})}))}))]})),n("ul",e({className:D?"simple-phone-input-sri198-dropdown active":"simple-phone-input-sri198-dropdown",ref:j},{children:[B&&n("div",e({className:"simple-phone-input-sri198-search-container"},{children:[o("input",e({placeholder:I},b,{onChange:function(o){var n=o.target.value;z(function(o,n,c){return(c&&c.length>0?r.filter((function(o){return!(null==c?void 0:c.includes(o.countryCode))})):n&&(null==n?void 0:n.length)>0?r.filter((function(o){return null==n?void 0:n.includes(o.countryCode)})):r).filter((function(n){var c=new RegExp(o.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&"),"gi");return n.country.match(c)}))}(n,h,p))}})),w&&o("div",e({className:"simple-phone-input-sri198-search-icon"},{children:null!=T?T:n("svg",e({xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",preserveAspectRatio:"xMidYMid meet",viewBox:"0 0 48 48"},{children:[n("g",e({fill:"#616161"},{children:[o("path",{d:"m29.175 31.99l2.828-2.827l12.019 12.019l-2.828 2.827z"}),o("circle",{cx:"20",cy:"20",r:"16"})]})),o("path",{fill:"#37474F",d:"m32.45 35.34l2.827-2.828l8.696 8.696l-2.828 2.828z"}),o("circle",{cx:"20",cy:"20",r:"13",fill:"#64B5F6"}),o("path",{fill:"#BBDEFB",d:"M26.9 14.2c-1.7-2-4.2-3.2-6.9-3.2s-5.2 1.2-6.9 3.2c-.4.4-.3 1.1.1 1.4c.4.4 1.1.3 1.4-.1C16 13.9 17.9 13 20 13s4 .9 5.4 2.5c.2.2.5.4.8.4c.2 0 .5-.1.6-.2c.4-.4.4-1.1.1-1.5z"})]}))}))]})),0===H.length&&o("div",e({className:"simple-phone-input-sri198-not-found"},{children:P})),H.map((function(c,r){return n("li",e({onClick:function(){return function(o,n){if(M){var c=null==O?void 0:O.replace(R.callingCode,o.callingCode);V(c.length>0?c:o.callingCode),C(c.length>0?c:o.callingCode)}else C(o.callingCode+O);K(o),U(!1),Y(n)}(c,r)},className:r===W?"active":""},{children:[o("img",{src:"https://cdn.jsdelivr.net/gh/siamahnaf198/country-flags@main/img/"+c.countryCode+".svg",alt:c.country,width:"20px"}),o("span",e({className:"simple-phone-input-sri198-dropdown-text"},{children:c.country})),o("span",e({className:"simple-phone-input-sri198-dropdown-country-code"},{children:c.callingCode}))]}),r)}))]}))]})),o("input",e({className:"simple-phone-input-sri198-input",placeholder:d,onChange:function(o){var n=o.target.value.replace(/\D/g,"");M?(C("+"+n),V("+"+n)):(V(n),C(R.callingCode+n))},type:"tel",onInput:function(o){if(M){var n=O.slice(R.callingCode.length);o.target.value.startsWith(R.callingCode)?o.target.value=o.target.value:o.target.value=R.callingCode+n}},onKeyDown:function(o){return Q(o)},value:O},s))]}))}))};export{l as PhoneInput};
|
|
1
|
+
import{jsx as o,jsxs as n}from"react/jsx-runtime";import e from"react";const c=[{country:"Afghanistan",countryCode:"AF",callingCode:"+93"},{country:"Albania",countryCode:"AL",callingCode:"+355"},{country:"Algeria",countryCode:"DZ",callingCode:"+213"},{country:"American Samoa",countryCode:"AS",callingCode:"+1684"},{country:"Andorra",countryCode:"AD",callingCode:"+376"},{country:"Angola",countryCode:"AO",callingCode:"+244"},{country:"Anguilla",countryCode:"AI",callingCode:"+1264"},{country:"Antarctica",countryCode:"AQ",callingCode:"+672"},{country:"Antigua and Barbuda",countryCode:"AG",callingCode:"+1268"},{country:"Argentina",countryCode:"AR",callingCode:"+54"},{country:"Armenia",countryCode:"AM",callingCode:"+374"},{country:"Aruba",countryCode:"AW",callingCode:"+297"},{country:"Australia",countryCode:"AU",callingCode:"+61"},{country:"Austria",countryCode:"AT",callingCode:"+43"},{country:"Azerbaijan",countryCode:"AZ",callingCode:"+994"},{country:"Bahamas",countryCode:"BS",callingCode:"+1242"},{country:"Bahrain",countryCode:"BH",callingCode:"+973"},{country:"Bangladesh",countryCode:"BD",callingCode:"+880"},{country:"Barbados",countryCode:"BB",callingCode:"+1246"},{country:"Belarus",countryCode:"BY",callingCode:"+375"},{country:"Belgium",countryCode:"BE",callingCode:"+32"},{country:"Belize",countryCode:"BZ",callingCode:"+501"},{country:"Benin",countryCode:"BJ",callingCode:"+229"},{country:"Bermuda",countryCode:"BM",callingCode:"+1441"},{country:"Bhutan",countryCode:"BT",callingCode:"+975"},{country:"Bolivia",countryCode:"BO",callingCode:"+591"},{country:"Bosnia and Herzegovina",countryCode:"BA",callingCode:"+387"},{country:"Botswana",countryCode:"BW",callingCode:"+267"},{country:"Bouvet Island",countryCode:"BV",callingCode:"+47"},{country:"Brazil",countryCode:"BR",callingCode:"+55"},{country:"British Indian Ocean Territory",countryCode:"IO",callingCode:"+246"},{country:"British Virgin Islands",countryCode:"VG",callingCode:"+1284"},{country:"Brunei",countryCode:"BN",callingCode:"+673"},{country:"Bulgaria",countryCode:"BG",callingCode:"+359"},{country:"Burkina Faso",countryCode:"BF",callingCode:"+226"},{country:"Burundi",countryCode:"BI",callingCode:"+257"},{country:"Cambodia",countryCode:"KH",callingCode:"+855"},{country:"Cameroon",countryCode:"CM",callingCode:"+237"},{country:"Canada",countryCode:"CA",callingCode:"+1"},{country:"Cape Verde",countryCode:"CV",callingCode:"+238"},{country:"Cayman Islands",countryCode:"KY",callingCode:"+1345"},{country:"Central African Republic",countryCode:"CF",callingCode:"+236"},{country:"Chad",countryCode:"TD",callingCode:"+235"},{country:"Chile",countryCode:"CL",callingCode:"+56"},{country:"China",countryCode:"CN",callingCode:"+86"},{country:"Christmas Island",countryCode:"CX",callingCode:"+61"},{country:"Cocos Islands",countryCode:"CC",callingCode:"+61"},{country:"Colombia",countryCode:"CO",callingCode:"+57"},{country:"Comoros",countryCode:"KM",callingCode:"+269"},{country:"Cook Islands",countryCode:"CK",callingCode:"+682"},{country:"Costa Rica",countryCode:"CR",callingCode:"+506"},{country:"Croatia",countryCode:"HR",callingCode:"+385"},{country:"Cuba",countryCode:"CU",callingCode:"+53"},{country:"Cyprus",countryCode:"CY",callingCode:"+357"},{country:"Czech Republic",countryCode:"CZ",callingCode:"+420"},{country:"Democratic Republic of the Congo",countryCode:"CD",callingCode:"+243"},{country:"Denmark",countryCode:"DK",callingCode:"+45"},{country:"Djibouti",countryCode:"DJ",callingCode:"+253"},{country:"Dominica",countryCode:"DM",callingCode:"+1767"},{country:"Dominican Republic",countryCode:"DO",callingCode:"+1"},{country:"East Timor",countryCode:"TL",callingCode:"+670"},{country:"Ecuador",countryCode:"EC",callingCode:"+593"},{country:"Egypt",countryCode:"EG",callingCode:"+20"},{country:"El Salvador",countryCode:"SV",callingCode:"+503"},{country:"Equatorial Guinea",countryCode:"GQ",callingCode:"+240"},{country:"Eritrea",countryCode:"ER",callingCode:"+291"},{country:"Estonia",countryCode:"EE",callingCode:"+372"},{country:"Ethiopia",countryCode:"ET",callingCode:"+251"},{country:"Falkland Islands",countryCode:"FK",callingCode:"+500"},{country:"Faroe Islands",countryCode:"FO",callingCode:"+298"},{country:"Fiji",countryCode:"FJ",callingCode:"+679"},{country:"Finland",countryCode:"FI",callingCode:"+358"},{country:"France",countryCode:"FR",callingCode:"+33"},{country:"French Guiana",countryCode:"GF",callingCode:"+594"},{country:"French Polynesia",countryCode:"PF",callingCode:"+689"},{country:"French Southern Territories",countryCode:"TF",callingCode:"+262"},{country:"Gabon",countryCode:"GA",callingCode:"+241"},{country:"Gambia",countryCode:"GM",callingCode:"+220"},{country:"Georgia",countryCode:"GE",callingCode:"+995"},{country:"Germany",countryCode:"DE",callingCode:"+49"},{country:"Ghana",countryCode:"GH",callingCode:"+233"},{country:"Gibraltar",countryCode:"GI",callingCode:"+350"},{country:"Greece",countryCode:"GR",callingCode:"+30"},{country:"Greenland",countryCode:"GL",callingCode:"+299"},{country:"Grenada",countryCode:"GD",callingCode:"+473"},{country:"Guadeloupe",countryCode:"GP",callingCode:"+590"},{country:"Guam",countryCode:"GU",callingCode:"+1671"},{country:"Guatemala",countryCode:"GT",callingCode:"+502"},{country:"Guinea",countryCode:"GN",callingCode:"+224"},{country:"Guinea-Bissau",countryCode:"GW",callingCode:"+245"},{country:"Guyana",countryCode:"GY",callingCode:"+592"},{country:"Haiti",countryCode:"HT",callingCode:"+509"},{country:"Honduras",countryCode:"HN",callingCode:"+504"},{country:"Hong Kong",countryCode:"HK",callingCode:"+852"},{country:"Hungary",countryCode:"HU",callingCode:"+36"},{country:"Iceland",countryCode:"IS",callingCode:"+354"},{country:"India",countryCode:"IN",callingCode:"+91"},{country:"Indonesia",countryCode:"ID",callingCode:"+62"},{country:"Iran",countryCode:"IR",callingCode:"+98"},{country:"Iraq",countryCode:"IQ",callingCode:"+964"},{country:"Ireland",countryCode:"IE",callingCode:"+353"},{country:"Israel",countryCode:"IL",callingCode:"+972"},{country:"Italy",countryCode:"IT",callingCode:"+39"},{country:"Ivory Coast",countryCode:"CI",callingCode:"+225"},{country:"Jamaica",countryCode:"JM",callingCode:"+1876"},{country:"Japan",countryCode:"JP",callingCode:"+81"},{country:"Jordan",countryCode:"JO",callingCode:"+962"},{country:"Kazakhstan",countryCode:"KZ",callingCode:"+7"},{country:"Kenya",countryCode:"KE",callingCode:"+254"},{country:"Kiribati",countryCode:"KI",callingCode:"+686"},{country:"Kuwait",countryCode:"KW",callingCode:"+965"},{country:"Kyrgyzstan",countryCode:"KG",callingCode:"+996"},{country:"Laos",countryCode:"LA",callingCode:"+856"},{country:"Latvia",countryCode:"LV",callingCode:"+371"},{country:"Lebanon",countryCode:"LB",callingCode:"+961"},{country:"Lesotho",countryCode:"LS",callingCode:"+266"},{country:"Liberia",countryCode:"LR",callingCode:"+231"},{country:"Libya",countryCode:"LY",callingCode:"+218"},{country:"Liechtenstein",countryCode:"LI",callingCode:"+423"},{country:"Lithuania",countryCode:"LT",callingCode:"+370"},{country:"Luxembourg",countryCode:"LU",callingCode:"+352"},{country:"Macao",countryCode:"MO",callingCode:"+853"},{country:"Macedonia",countryCode:"MK",callingCode:"+389"},{country:"Madagascar",countryCode:"MG",callingCode:"+261"},{country:"Malawi",countryCode:"MW",callingCode:"+265"},{country:"Malaysia",countryCode:"MY",callingCode:"+60"},{country:"Maldives",countryCode:"MV",callingCode:"+960"},{country:"Mali",countryCode:"ML",callingCode:"+223"},{country:"Malta",countryCode:"MT",callingCode:"+356"},{country:"Marshall Islands",countryCode:"MH",callingCode:"+692"},{country:"Martinique",countryCode:"MQ",callingCode:"+596"},{country:"Mauritania",countryCode:"MR",callingCode:"+222"},{country:"Mauritius",countryCode:"MU",callingCode:"+230"},{country:"Mayotte",countryCode:"YT",callingCode:"+262"},{country:"Mexico",countryCode:"MX",callingCode:"+52"},{country:"Micronesia",countryCode:"FM",callingCode:"+691"},{country:"Moldova",countryCode:"MD",callingCode:"+373"},{country:"Monaco",countryCode:"MC",callingCode:"+377"},{country:"Mongolia",countryCode:"MN",callingCode:"+976"},{country:"Montserrat",countryCode:"MS",callingCode:"+1664"},{country:"Morocco",countryCode:"MA",callingCode:"+212"},{country:"Mozambique",countryCode:"MZ",callingCode:"+258"},{country:"Myanmar",countryCode:"MM",callingCode:"+95"},{country:"Namibia",countryCode:"NA",callingCode:"+264"},{country:"Nauru",countryCode:"NR",callingCode:"+674"},{country:"Nepal",countryCode:"NP",callingCode:"+977"},{country:"Netherlands",countryCode:"NL",callingCode:"+31"},{country:"New Caledonia",countryCode:"NC",callingCode:"+687"},{country:"New Zealand",countryCode:"NZ",callingCode:"+64"},{country:"Nicaragua",countryCode:"NI",callingCode:"+505"},{country:"Niger",countryCode:"NE",callingCode:"+227"},{country:"Nigeria",countryCode:"NG",callingCode:"+234"},{country:"Niue",countryCode:"NU",callingCode:"+683"},{country:"Norfolk Island",countryCode:"NF",callingCode:"+672"},{country:"North Korea",countryCode:"KP",callingCode:"+850"},{country:"Northern Mariana Islands",countryCode:"MP",callingCode:"+1670"},{country:"Norway",countryCode:"NO",callingCode:"+47"},{country:"Oman",countryCode:"OM",callingCode:"+968"},{country:"Pakistan",countryCode:"PK",callingCode:"+92"},{country:"Palau",countryCode:"PW",callingCode:"+680"},{country:"Palestinian Territory",countryCode:"PS",callingCode:"+970"},{country:"Panama",countryCode:"PA",callingCode:"+507"},{country:"Papua New Guinea",countryCode:"PG",callingCode:"+675"},{country:"Paraguay",countryCode:"PY",callingCode:"+595"},{country:"Peru",countryCode:"PE",callingCode:"+51"},{country:"Philippines",countryCode:"PH",callingCode:"+63"},{country:"Pitcairn",countryCode:"PN",callingCode:"+872"},{country:"Poland",countryCode:"PL",callingCode:"+48"},{country:"Portugal",countryCode:"PT",callingCode:"+351"},{country:"Puerto Rico",countryCode:"PR",callingCode:"+1"},{country:"Qatar",countryCode:"QA",callingCode:"+974"},{country:"Republic of the Congo",countryCode:"CG",callingCode:"+242"},{country:"Reunion",countryCode:"RE",callingCode:"+262"},{country:"Romania",countryCode:"RO",callingCode:"+40"},{country:"Russia",countryCode:"RU",callingCode:"+7"},{country:"Rwanda",countryCode:"RW",callingCode:"+250"},{country:"Saint Helena",countryCode:"SH",callingCode:"+290"},{country:"Saint Kitts and Nevis",countryCode:"KN",callingCode:"+1869"},{country:"Saint Lucia",countryCode:"LC",callingCode:"+1758"},{country:"Saint Pierre and Miquelon",countryCode:"PM",callingCode:"+508"},{country:"Saint Vincent and the Grenadines",countryCode:"VC",callingCode:"+1784"},{country:"Samoa",countryCode:"WS",callingCode:"+685"},{country:"San Marino",countryCode:"SM",callingCode:"+378"},{country:"Sao Tome and Principe",countryCode:"ST",callingCode:"+239"},{country:"Saudi Arabia",countryCode:"SA",callingCode:"+966"},{country:"Senegal",countryCode:"SN",callingCode:"+221"},{country:"Seychelles",countryCode:"SC",callingCode:"+248"},{country:"Sierra Leone",countryCode:"SL",callingCode:"+232"},{country:"Singapore",countryCode:"SG",callingCode:"+65"},{country:"Slovakia",countryCode:"SK",callingCode:"+421"},{country:"Slovenia",countryCode:"SI",callingCode:"+386"},{country:"Solomon Islands",countryCode:"SB",callingCode:"+677"},{country:"Somalia",countryCode:"SO",callingCode:"+252"},{country:"South Africa",countryCode:"ZA",callingCode:"+27"},{country:"South Georgia and the South Sandwich Islands",countryCode:"GS",callingCode:"+500"},{country:"South Korea",countryCode:"KR",callingCode:"+82"},{country:"Spain",countryCode:"ES",callingCode:"+34"},{country:"Sri Lanka",countryCode:"LK",callingCode:"+94"},{country:"Sudan",countryCode:"SD",callingCode:"+249"},{country:"Suriname",countryCode:"SR",callingCode:"+597"},{country:"Svalbard and Jan Mayen",countryCode:"SJ",callingCode:"+47"},{country:"Swaziland",countryCode:"SZ",callingCode:"+268"},{country:"Sweden",countryCode:"SE",callingCode:"+46"},{country:"Switzerland",countryCode:"CH",callingCode:"+41"},{country:"Syria",countryCode:"SY",callingCode:"+963"},{country:"Taiwan",countryCode:"TW",callingCode:"+886"},{country:"Tajikistan",countryCode:"TJ",callingCode:"+992"},{country:"Tanzania",countryCode:"TZ",callingCode:"+255"},{country:"Thailand",countryCode:"TH",callingCode:"+66"},{country:"Togo",countryCode:"TG",callingCode:"+228"},{country:"Tokelau",countryCode:"TK",callingCode:"+690"},{country:"Tonga",countryCode:"TO",callingCode:"+676"},{country:"Trinidad and Tobago",countryCode:"TT",callingCode:"+1868"},{country:"Tunisia",countryCode:"TN",callingCode:"+216"},{country:"Turkey",countryCode:"TR",callingCode:"+90"},{country:"Turkmenistan",countryCode:"TM",callingCode:"+993"},{country:"Turks and Caicos Islands",countryCode:"TC",callingCode:"+1649"},{country:"Tuvalu",countryCode:"TV",callingCode:"+688"},{country:"U.S. Virgin Islands",countryCode:"VI",callingCode:"+1340"},{country:"Uganda",countryCode:"UG",callingCode:"+256"},{country:"Ukraine",countryCode:"UA",callingCode:"+380"},{country:"United Arab Emirates",countryCode:"AE",callingCode:"+971"},{country:"United Kingdom",countryCode:"GB",callingCode:"+44"},{country:"United States",countryCode:"US",callingCode:"+1"},{country:"United States Minor Outlying Islands",countryCode:"UM",callingCode:"+1"},{country:"Uruguay",countryCode:"UY",callingCode:"+598"},{country:"Uzbekistan",countryCode:"UZ",callingCode:"+998"},{country:"Vanuatu",countryCode:"VU",callingCode:"+678"},{country:"Vatican",countryCode:"VA",callingCode:"+379"},{country:"Venezuela",countryCode:"VE",callingCode:"+58"},{country:"Vietnam",countryCode:"VN",callingCode:"+84"},{country:"Wallis and Futuna",countryCode:"WF",callingCode:"+681"},{country:"Western Sahara",countryCode:"EH",callingCode:"+212"},{country:"Yemen",countryCode:"YE",callingCode:"+967"},{country:"Zambia",countryCode:"ZM",callingCode:"+260"},{country:"Zimbabwe",countryCode:"ZW",callingCode:"+263"}],t=o=>c.find((n=>n.countryCode===o));const r=({placeholder:r,country:l,onChange:a,value:d,iconComponent:u,inputProps:i,onlyCountries:C,excludeCountries:y,preferredCountries:g,showDropdownIcon:s=!0,dialCodeInputField:h=!1,search:p=!0,disableDropdownOnly:m=!1,disableInput:S=!1,searchPlaceholder:M="Search country",showSearchIcon:v=!0,searchIconComponent:I,searchProps:N,searchNotFound:w="Not found",containerClass:B,buttonClass:A,dropdownClass:G,dropdownListClass:T,dropdownIconClass:f,searchContainerClass:b,searchInputClass:P,searchIconClass:E,inputClass:L,containerStyle:R,buttonStyle:K,dropdownStyle:F,dropdownListStyle:D,dropdownIconStyle:U,searchContainerStyle:k,searchInputStyle:V,searchIconStyle:x,inputStyle:H})=>{const[O,W]=e.useState({}),[z,Z]=e.useState(!1),[Y,J]=e.useState(d||""),[j,Q]=e.useState(c),[q,X]=e.useState(0),$=e.useRef(null),_=e.useRef(null);var oo,no;oo=$,no=()=>Z(!1),e.useEffect((()=>{const o=o=>{oo.current&&!oo.current.contains(o.target)&&no(o)};return document.addEventListener("mousedown",o),document.addEventListener("touchstart",o),()=>{document.removeEventListener("mousedown",o),document.removeEventListener("touchstart",o)}}),[oo,no]);const eo=o=>{z&&("ArrowDown"===o.key&&(o.preventDefault(),X((o=>o<j.length-1?o+1:o))),"ArrowUp"===o.key&&(o.preventDefault(),X((o=>o>0?o-1:0))),"Escape"===o.key&&Z(!1),"Enter"===o.key&&q>=0&&(W(j[q]),Z(!1)))};return e.useEffect((()=>{if(q<0||q>j.length||!_)return()=>{};if(z&&_&&j.length>0){let n=Array.from(_.current?.children);n[q]&&(o=n[q].offsetTop-65,p&&j.length>0&&_.current?.scrollTo({top:o,behavior:"smooth"}))}var o}),[q]),e.useMemo((()=>{if(h){const o=Y?.replace(O.callingCode,t(l).callingCode);console.log(o),J(o.length>0?o:t(l).callingCode)}W(t(l))}),[l,h]),e.useMemo((()=>{Q(((o,n,e)=>{let t=[];return t=n&&n.length>0?c.filter((o=>!n?.includes(o.countryCode))):o&&o?.length>0?c.filter((n=>o?.includes(n.countryCode))):c,t.sort(((o,n)=>Number(e?.includes(n.countryCode))-Number(e?.includes(o.countryCode))||e?.indexOf(o.countryCode)-e?.indexOf(n.countryCode)))})(C,y,g))}),[C,y,g]),o("div",{className:"simple-phone-input-sri198-container"+(B?" "+B:""),onKeyDown:o=>eo(o),tabIndex:-1,style:R,children:n("div",{className:"simple-phone-input-sri198-main",children:[n("div",{className:"simple-phone-input-sri198-dropdown-container",ref:$,children:[n("div",{onClick:()=>{m||Z(!z)},className:h?"simple-phone-input-sri198-dropdown-container-button dial"+(A?" "+A:""):"simple-phone-input-sri198-dropdown-container-button"+(A?" "+A:""),style:K,children:[o("img",{src:"https://cdn.jsdelivr.net/gh/siamahnaf198/country-flags@main/img/"+O.countryCode+".svg",alt:O.country,width:"20px"}),!h&&o("span",{className:"simple-phone-input-sri198-selected-code",children:O.callingCode}),s&&!m&&o("div",{className:z?"simple-phone-input-sri198-dropdown-icon"+(f?" "+f:""):"simple-phone-input-sri198-dropdown-icon active"+(f?" "+f:""),style:U,children:u||o("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",preserveAspectRatio:"xMidYMid meet",viewBox:"0 0 24 24",children:o("path",{fill:"currentColor",d:"m7 10l5 5l5-5z"})})})]}),n("ul",{className:z?"simple-phone-input-sri198-dropdown active"+(G?" "+G:""):"simple-phone-input-sri198-dropdown"+(G?" "+G:""),ref:_,style:F,children:[p&&n("div",{className:"simple-phone-input-sri198-search-container"+(b?" "+b:""),style:k,children:[o("input",{placeholder:M,...N,onChange:o=>{const n=o.target.value;Q(((o,n,e)=>{let t=[];return t=e&&e.length>0?c.filter((o=>!e?.includes(o.countryCode))):n&&n?.length>0?c.filter((o=>n?.includes(o.countryCode))):c,t.filter((n=>{const e=new RegExp(o.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&"),"gi");return n.country.match(e)}))})(n,C,y))},className:P??"",style:V}),v&&o("div",{className:"simple-phone-input-sri198-search-icon"+(E?" "+E:""),style:x,children:I??n("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",preserveAspectRatio:"xMidYMid meet",viewBox:"0 0 48 48",children:[n("g",{fill:"#616161",children:[o("path",{d:"m29.175 31.99l2.828-2.827l12.019 12.019l-2.828 2.827z"}),o("circle",{cx:"20",cy:"20",r:"16"})]}),o("path",{fill:"#37474F",d:"m32.45 35.34l2.827-2.828l8.696 8.696l-2.828 2.828z"}),o("circle",{cx:"20",cy:"20",r:"13",fill:"#64B5F6"}),o("path",{fill:"#BBDEFB",d:"M26.9 14.2c-1.7-2-4.2-3.2-6.9-3.2s-5.2 1.2-6.9 3.2c-.4.4-.3 1.1.1 1.4c.4.4 1.1.3 1.4-.1C16 13.9 17.9 13 20 13s4 .9 5.4 2.5c.2.2.5.4.8.4c.2 0 .5-.1.6-.2c.4-.4.4-1.1.1-1.5z"})]})})]}),0===j.length&&o("div",{className:"simple-phone-input-sri198-not-found",children:w}),j.map(((e,c)=>n("li",{onClick:()=>((o,n)=>{if(h){const n=Y?.replace(O.callingCode,o.callingCode);J(n.length>0?n:o.callingCode),a({country:o.country,code:o.countryCode,dialCode:o.callingCode,value:n.length>0?n:o.callingCode,valueWithoutPlus:n.length>0?n.replace("+",""):o.callingCode.replace("+","")})}else a({country:o.country,code:o.countryCode,dialCode:o.callingCode,value:o.callingCode+Y,valueWithoutPlus:o.callingCode.replace("+","")+Y});W(o),Z(!1),X(n)})(e,c),className:c===q?"active"+(T?" "+T:""):""+(T?" "+T:""),style:D,children:[o("img",{src:"https://cdn.jsdelivr.net/gh/siamahnaf198/country-flags@main/img/"+e.countryCode+".svg",alt:e.country,width:"20px"}),o("span",{className:"simple-phone-input-sri198-dropdown-text",children:e.country}),o("span",{className:"simple-phone-input-sri198-dropdown-country-code",children:e.callingCode})]},c)))]})]}),o("input",{className:"simple-phone-input-sri198-input "+(L?" "+L:""),placeholder:r,onChange:o=>{const n=o.target.value.replace(/\D/g,"");h?(a({country:O.country,code:O.countryCode,dialCode:O.callingCode,value:"+"+n,valueWithoutPlus:n}),J("+"+n)):(J(n),a({country:O.country,code:O.countryCode,dialCode:O.callingCode,value:O.callingCode+n,valueWithoutPlus:O.callingCode.replace("+","")+n}))},type:"tel",onInput:o=>{if(h){const n=Y.slice(O.callingCode.length);o.target.value.startsWith(O.callingCode)?o.target.value=o.target.value:o.target.value=O.callingCode+n}},onKeyDown:o=>eo(o),value:Y,...i,style:H,disabled:S})]})})};export{r as PhoneInput};
|
|
2
2
|
//# sourceMappingURL=index.js.map
|
package/dist/esm/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":["../../node_modules/tslib/tslib.es6.js","../../src/Data/country-data.ts","../../src/Helpers/country-helper.ts","../../src/components/PhoneInput/PhoneInput.tsx","../../src/Helpers/hook.ts"],"sourcesContent":["/******************************************************************************\r\nCopyright (c) Microsoft Corporation.\r\n\r\nPermission to use, copy, modify, and/or distribute this software for any\r\npurpose with or without fee is hereby granted.\r\n\r\nTHE SOFTWARE IS PROVIDED \"AS IS\" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH\r\nREGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY\r\nAND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,\r\nINDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM\r\nLOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR\r\nOTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR\r\nPERFORMANCE OF THIS SOFTWARE.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };\r\n return extendStatics(d, b);\r\n};\r\n\r\nexport function __extends(d, b) {\r\n if (typeof b !== \"function\" && b !== null)\r\n throw new TypeError(\"Class extends value \" + String(b) + \" is not a constructor or null\");\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\r\n\r\nexport var __assign = function() {\r\n __assign = Object.assign || function __assign(t) {\r\n for (var s, i = 1, n = arguments.length; i < n; i++) {\r\n s = arguments[i];\r\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];\r\n }\r\n return t;\r\n }\r\n return __assign.apply(this, arguments);\r\n}\r\n\r\nexport function __rest(s, e) {\r\n var t = {};\r\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)\r\n t[p] = s[p];\r\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\")\r\n for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\r\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))\r\n t[p[i]] = s[p[i]];\r\n }\r\n return t;\r\n}\r\n\r\nexport function __decorate(decorators, target, key, desc) {\r\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\r\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\r\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\r\n return c > 3 && r && Object.defineProperty(target, key, r), r;\r\n}\r\n\r\nexport function __param(paramIndex, decorator) {\r\n return function (target, key) { decorator(target, key, paramIndex); }\r\n}\r\n\r\nexport function __metadata(metadataKey, metadataValue) {\r\n if (typeof Reflect === \"object\" && typeof Reflect.metadata === \"function\") return Reflect.metadata(metadataKey, metadataValue);\r\n}\r\n\r\nexport function __awaiter(thisArg, _arguments, P, generator) {\r\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\r\n return new (P || (P = Promise))(function (resolve, reject) {\r\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\r\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\r\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\r\n step((generator = generator.apply(thisArg, _arguments || [])).next());\r\n });\r\n}\r\n\r\nexport function __generator(thisArg, body) {\r\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\r\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\r\n function verb(n) { return function (v) { return step([n, v]); }; }\r\n function step(op) {\r\n if (f) throw new TypeError(\"Generator is already executing.\");\r\n while (g && (g = 0, op[0] && (_ = 0)), _) try {\r\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\r\n if (y = 0, t) op = [op[0] & 2, t.value];\r\n switch (op[0]) {\r\n case 0: case 1: t = op; break;\r\n case 4: _.label++; return { value: op[1], done: false };\r\n case 5: _.label++; y = op[1]; op = [0]; continue;\r\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\r\n default:\r\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\r\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\r\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\r\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\r\n if (t[2]) _.ops.pop();\r\n _.trys.pop(); continue;\r\n }\r\n op = body.call(thisArg, _);\r\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\r\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\r\n }\r\n}\r\n\r\nexport var __createBinding = Object.create ? (function(o, m, k, k2) {\r\n if (k2 === undefined) k2 = k;\r\n var desc = Object.getOwnPropertyDescriptor(m, k);\r\n if (!desc || (\"get\" in desc ? !m.__esModule : desc.writable || desc.configurable)) {\r\n desc = { enumerable: true, get: function() { return m[k]; } };\r\n }\r\n Object.defineProperty(o, k2, desc);\r\n}) : (function(o, m, k, k2) {\r\n if (k2 === undefined) k2 = k;\r\n o[k2] = m[k];\r\n});\r\n\r\nexport function __exportStar(m, o) {\r\n for (var p in m) if (p !== \"default\" && !Object.prototype.hasOwnProperty.call(o, p)) __createBinding(o, m, p);\r\n}\r\n\r\nexport function __values(o) {\r\n var s = typeof Symbol === \"function\" && Symbol.iterator, m = s && o[s], i = 0;\r\n if (m) return m.call(o);\r\n if (o && typeof o.length === \"number\") return {\r\n next: function () {\r\n if (o && i >= o.length) o = void 0;\r\n return { value: o && o[i++], done: !o };\r\n }\r\n };\r\n throw new TypeError(s ? \"Object is not iterable.\" : \"Symbol.iterator is not defined.\");\r\n}\r\n\r\nexport function __read(o, n) {\r\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\r\n if (!m) return o;\r\n var i = m.call(o), r, ar = [], e;\r\n try {\r\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\r\n }\r\n catch (error) { e = { error: error }; }\r\n finally {\r\n try {\r\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\r\n }\r\n finally { if (e) throw e.error; }\r\n }\r\n return ar;\r\n}\r\n\r\n/** @deprecated */\r\nexport function __spread() {\r\n for (var ar = [], i = 0; i < arguments.length; i++)\r\n ar = ar.concat(__read(arguments[i]));\r\n return ar;\r\n}\r\n\r\n/** @deprecated */\r\nexport function __spreadArrays() {\r\n for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length;\r\n for (var r = Array(s), k = 0, i = 0; i < il; i++)\r\n for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)\r\n r[k] = a[j];\r\n return r;\r\n}\r\n\r\nexport function __spreadArray(to, from, pack) {\r\n if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {\r\n if (ar || !(i in from)) {\r\n if (!ar) ar = Array.prototype.slice.call(from, 0, i);\r\n ar[i] = from[i];\r\n }\r\n }\r\n return to.concat(ar || Array.prototype.slice.call(from));\r\n}\r\n\r\nexport function __await(v) {\r\n return this instanceof __await ? (this.v = v, this) : new __await(v);\r\n}\r\n\r\nexport function __asyncGenerator(thisArg, _arguments, generator) {\r\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\r\n var g = generator.apply(thisArg, _arguments || []), i, q = [];\r\n return i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () { return this; }, i;\r\n function verb(n) { if (g[n]) i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; }\r\n function resume(n, v) { try { step(g[n](v)); } catch (e) { settle(q[0][3], e); } }\r\n function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); }\r\n function fulfill(value) { resume(\"next\", value); }\r\n function reject(value) { resume(\"throw\", value); }\r\n function settle(f, v) { if (f(v), q.shift(), q.length) resume(q[0][0], q[0][1]); }\r\n}\r\n\r\nexport function __asyncDelegator(o) {\r\n var i, p;\r\n return i = {}, verb(\"next\"), verb(\"throw\", function (e) { throw e; }), verb(\"return\"), i[Symbol.iterator] = function () { return this; }, i;\r\n function verb(n, f) { i[n] = o[n] ? function (v) { return (p = !p) ? { value: __await(o[n](v)), done: n === \"return\" } : f ? f(v) : v; } : f; }\r\n}\r\n\r\nexport function __asyncValues(o) {\r\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\r\n var m = o[Symbol.asyncIterator], i;\r\n return m ? m.call(o) : (o = typeof __values === \"function\" ? __values(o) : o[Symbol.iterator](), i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () { return this; }, i);\r\n function verb(n) { i[n] = o[n] && function (v) { return new Promise(function (resolve, reject) { v = o[n](v), settle(resolve, reject, v.done, v.value); }); }; }\r\n function settle(resolve, reject, d, v) { Promise.resolve(v).then(function(v) { resolve({ value: v, done: d }); }, reject); }\r\n}\r\n\r\nexport function __makeTemplateObject(cooked, raw) {\r\n if (Object.defineProperty) { Object.defineProperty(cooked, \"raw\", { value: raw }); } else { cooked.raw = raw; }\r\n return cooked;\r\n};\r\n\r\nvar __setModuleDefault = Object.create ? (function(o, v) {\r\n Object.defineProperty(o, \"default\", { enumerable: true, value: v });\r\n}) : function(o, v) {\r\n o[\"default\"] = v;\r\n};\r\n\r\nexport function __importStar(mod) {\r\n if (mod && mod.__esModule) return mod;\r\n var result = {};\r\n if (mod != null) for (var k in mod) if (k !== \"default\" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);\r\n __setModuleDefault(result, mod);\r\n return result;\r\n}\r\n\r\nexport function __importDefault(mod) {\r\n return (mod && mod.__esModule) ? mod : { default: mod };\r\n}\r\n\r\nexport function __classPrivateFieldGet(receiver, state, kind, f) {\r\n if (kind === \"a\" && !f) throw new TypeError(\"Private accessor was defined without a getter\");\r\n if (typeof state === \"function\" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError(\"Cannot read private member from an object whose class did not declare it\");\r\n return kind === \"m\" ? f : kind === \"a\" ? f.call(receiver) : f ? f.value : state.get(receiver);\r\n}\r\n\r\nexport function __classPrivateFieldSet(receiver, state, value, kind, f) {\r\n if (kind === \"m\") throw new TypeError(\"Private method is not writable\");\r\n if (kind === \"a\" && !f) throw new TypeError(\"Private accessor was defined without a setter\");\r\n if (typeof state === \"function\" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError(\"Cannot write private member to an object whose class did not declare it\");\r\n return (kind === \"a\" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value)), value;\r\n}\r\n\r\nexport function __classPrivateFieldIn(state, receiver) {\r\n if (receiver === null || (typeof receiver !== \"object\" && typeof receiver !== \"function\")) throw new TypeError(\"Cannot use 'in' operator on non-object\");\r\n return typeof state === \"function\" ? receiver === state : state.has(receiver);\r\n}\r\n",null,null,null,null],"names":["__assign","Object","assign","t","s","i","n","arguments","length","p","prototype","hasOwnProperty","call","apply","this","countryData","country","countryCode","callingCode","getDefaultCountry","code","find","item","PhoneInput","_a","ref","handler","placeholder","onChange","value","iconComponent","inputProps","onlyCountries","excludeCountries","preferredCountries","_b","showDropdownIcon","_c","dialCodeInputField","_d","search","_e","searchPlaceholder","_f","showSearchIcon","searchIconComponent","searchProps","_g","searchNotFound","_h","React","useState","selected","setSelected","_j","isDropdown","setDropdown","_k","inputValue","setInputValue","_l","countryDataInfo","setCountryData","_m","cursor","setCursor","dropdownRef","useRef","listRef","useEffect","listener","event","current","contains","target","document","addEventListener","removeEventListener","keyBoardNav","e","key","preventDefault","c","listItems","Array","from","children","position","scrollTo","top","behavior","scrollIntoView","offsetTop","useMemo","result","replace","console","log","onlyCountry","excludeCountry","preferredCountry","filter","includes","sort","a","b","Number","indexOf","_jsx","className","onKeyDown","tabIndex","_jsxs","onClick","src","alt","width","xmlns","height","preserveAspectRatio","viewBox","fill","d","regex","RegExp","match","getBySearch","cx","cy","r","map","handleSelected","onlyNumber","type","onInput","oldVal","slice","startsWith"],"mappings":"uEA+BO,IAAIA,EAAW,WAQlB,OAPAA,EAAWC,OAAOC,QAAU,SAAkBC,GAC1C,IAAK,IAAIC,EAAGC,EAAI,EAAGC,EAAIC,UAAUC,OAAQH,EAAIC,EAAGD,IAE5C,IAAK,IAAII,KADTL,EAAIG,UAAUF,GACOJ,OAAOS,UAAUC,eAAeC,KAAKR,EAAGK,KAAIN,EAAEM,GAAKL,EAAEK,IAE9E,OAAON,CACV,EACMH,EAASa,MAAMC,KAAMP,UAChC,ECxCaQ,EAAc,CACvB,CACIC,QAAS,cACTC,YAAa,KACbC,YAAa,OAEjB,CACIF,QAAS,UACTC,YAAa,KACbC,YAAa,QAEjB,CACIF,QAAS,UACTC,YAAa,KACbC,YAAa,QAEjB,CACIF,QAAS,iBACTC,YAAa,KACbC,YAAa,SAEjB,CACIF,QAAS,UACTC,YAAa,KACbC,YAAa,QAEjB,CACIF,QAAS,SACTC,YAAa,KACbC,YAAa,QAEjB,CACIF,QAAS,WACTC,YAAa,KACbC,YAAa,SAEjB,CACIF,QAAS,aACTC,YAAa,KACbC,YAAa,QAEjB,CACIF,QAAS,sBACTC,YAAa,KACbC,YAAa,SAEjB,CACIF,QAAS,YACTC,YAAa,KACbC,YAAa,OAEjB,CACIF,QAAS,UACTC,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cyE,GACdxG,EAASwB,EAASlC,YAAckH,GAExC,EAkIgBC,KAAK,MACLC,QAAS,SAACvD,GACN,GAAIzC,EAAoB,CACpB,IAAMiG,EAAS7E,EAAW8E,MAAMpF,EAASlC,YAAYV,QACjDuE,EAAEL,OAAO7C,MAAM4G,WAAWrF,EAASlC,aACnC6D,EAAEL,OAAO7C,MAAQkD,EAAEL,OAAO7C,MAE1BkD,EAAEL,OAAO7C,MAAQuB,EAASlC,YAAcqH,CAE/C,GAELzB,UAAW,SAAC/B,GAAM,OAAAD,EAAYC,EAAE,EAChClD,MAAO6B,GACH3B,UAKxB"}
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../../src/Data/country-data.ts","../../src/Helpers/country-helper.ts","../../src/components/PhoneInput/PhoneInput.tsx","../../src/Helpers/hook.ts"],"sourcesContent":[null,null,null,null],"names":["countryData","country","countryCode","callingCode","getDefaultCountry","code","find","item","PhoneInput","placeholder","onChange","value","iconComponent","inputProps","onlyCountries","excludeCountries","preferredCountries","showDropdownIcon","dialCodeInputField","search","disableDropdownOnly","disableInput","searchPlaceholder","showSearchIcon","searchIconComponent","searchProps","searchNotFound","containerClass","buttonClass","dropdownClass","dropdownListClass","dropdownIconClass","searchContainerClass","searchInputClass","searchIconClass","inputClass","containerStyle","buttonStyle","dropdownStyle","dropdownListStyle","dropdownIconStyle","searchContainerStyle","searchInputStyle","searchIconStyle","inputStyle","selected","setSelected","React","useState","isDropdown","setDropdown","inputValue","setInputValue","countryDataInfo","setCountryData","cursor","setCursor","dropdownRef","useRef","listRef","ref","handler","useEffect","listener","event","current","contains","target","document","addEventListener","removeEventListener","keyBoardNav","e","key","preventDefault","c","length","listItems","Array","from","children","position","offsetTop","scrollTo","top","behavior","useMemo","result","replace","console","log","onlyCountry","excludeCountry","preferredCountry","countries","filter","includes","sort","a","b","Number","indexOf","getCountryByFilter","_jsx","className","onKeyDown","tabIndex","style","_jsxs","onClick","src","alt","width","xmlns","height","preserveAspectRatio","viewBox","fill","d","regex","RegExp","match","getBySearch","cx","cy","r","map","i","dialCode","valueWithoutPlus","handleSelected","onlyNumber","type","onInput","oldVal","slice","startsWith","disabled"],"mappings":"uEAAO,MAAMA,EAAc,CACvB,CACIC,QAAS,cACTC,YAAa,KACbC,YAAa,OAEjB,CACIF,QAAS,UACTC,YAAa,KACbC,YAAa,QAEjB,CACIF,QAAS,UACTC,YAAa,KACbC,YAAa,QAEjB,CACIF,QAAS,iBACTC,YAAa,KACbC,YAAa,SAEjB,CACIF,QAAS,UACTC,YAAa,KACbC,YAAa,QAEjB,CACIF,QAAS,SACTC,YAAa,KACbC,YAAa,QAEjB,CACIF,QAAS,WACTC,YAAa,KACbC,YAAa,SAEjB,CACIF,QAAS,aACTC,YAAa,KACbC,YAAa,QAEjB,CACIF,QAAS,sBACTC,YAAa,KACbC,YAAa,SAEjB,CACIF,QAAS,YACTC,YAAa,KACbC,YAAa,OAEjB,CACIF,QAAS,UACTC,YAAa,KACbC,YAAa,QAEjB,CACIF,QAAS,QACTC,YAAa,KACbC,YAAa,QAEjB,CACIF,QAAS,YACTC,YAAa,KACbC,YAAa,OAEjB,CACIF,QAAS,UACTC,YAAa,KACbC,YAAa,OAEjB,CACIF,QAAS,aACTC,YAAa,KACbC,YAAa,QAEjB,CACIF,QAAS,UACTC,YAAa,KACbC,YAAa,SAEjB,CACIF,QAAS,UACTC,YAAa,KACbC,YAAa,QAEjB,CACIF,QAAS,aACTC,YAAa,KACbC,YAAa,QAEjB,CACIF,QAAS,WACTC,YAAa,KACbC,YAAa,SAEjB,CACIF,QAAS,UACTC,YAAa,KACbC,YAAa,QAEjB,CACIF,QAAS,UACTC,YAAa,KACbC,YAAa,OAEjB,CACIF,QAAS,SACTC,YAAa,KACbC,YAAa,QAEjB,CACIF,QAAS,QACTC,YAAa,KACbC,YAAa,QAEjB,CACIF,QAAS,UACTC,YAAa,KACbC,YAAa,SAEjB,CACIF,QAAS,SACTC,YAAa,KACbC,YAAa,QAEjB,CACIF,QAAS,UACTC,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+1,16 @@
|
|
|
1
1
|
import React from "react";
|
|
2
2
|
import "./PhoneInput.css";
|
|
3
|
+
export interface PhoneInputResponseType {
|
|
4
|
+
country: string;
|
|
5
|
+
code: string;
|
|
6
|
+
dialCode: string;
|
|
7
|
+
value: string;
|
|
8
|
+
valueWithoutPlus: string;
|
|
9
|
+
}
|
|
3
10
|
interface Props {
|
|
4
11
|
placeholder: string;
|
|
5
12
|
country: string;
|
|
6
|
-
onChange: (e:
|
|
13
|
+
onChange: (e: PhoneInputResponseType) => void;
|
|
7
14
|
value?: string;
|
|
8
15
|
iconComponent?: React.ReactNode;
|
|
9
16
|
inputProps?: React.DetailedHTMLProps<React.InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>;
|
|
@@ -12,12 +19,32 @@ interface Props {
|
|
|
12
19
|
preferredCountries?: string[];
|
|
13
20
|
showDropdownIcon?: boolean;
|
|
14
21
|
dialCodeInputField?: boolean;
|
|
22
|
+
disableDropdownOnly?: boolean;
|
|
23
|
+
disableInput?: boolean;
|
|
15
24
|
search?: boolean;
|
|
16
25
|
searchPlaceholder?: string;
|
|
17
26
|
showSearchIcon?: boolean;
|
|
18
27
|
searchIconComponent?: React.ReactNode;
|
|
19
28
|
searchProps?: React.DetailedHTMLProps<React.InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>;
|
|
20
29
|
searchNotFound?: string;
|
|
30
|
+
containerClass?: string;
|
|
31
|
+
buttonClass?: string;
|
|
32
|
+
dropdownClass?: string;
|
|
33
|
+
dropdownListClass?: string;
|
|
34
|
+
dropdownIconClass?: string;
|
|
35
|
+
searchContainerClass?: string;
|
|
36
|
+
searchInputClass?: string;
|
|
37
|
+
searchIconClass?: string;
|
|
38
|
+
inputClass?: string;
|
|
39
|
+
containerStyle?: React.CSSProperties;
|
|
40
|
+
buttonStyle?: React.CSSProperties;
|
|
41
|
+
dropdownStyle?: React.CSSProperties;
|
|
42
|
+
dropdownListStyle?: React.CSSProperties;
|
|
43
|
+
dropdownIconStyle?: React.CSSProperties;
|
|
44
|
+
searchContainerStyle?: React.CSSProperties;
|
|
45
|
+
searchInputStyle?: React.CSSProperties;
|
|
46
|
+
searchIconStyle?: React.CSSProperties;
|
|
47
|
+
inputStyle?: React.CSSProperties;
|
|
21
48
|
}
|
|
22
|
-
declare const PhoneInput: ({ placeholder, country, onChange, value, iconComponent, inputProps, onlyCountries, excludeCountries, preferredCountries, showDropdownIcon, dialCodeInputField, search, searchPlaceholder, showSearchIcon, searchIconComponent, searchProps, searchNotFound }: Props) => JSX.Element;
|
|
49
|
+
declare const PhoneInput: ({ placeholder, country, onChange, value, iconComponent, inputProps, onlyCountries, excludeCountries, preferredCountries, showDropdownIcon, dialCodeInputField, search, disableDropdownOnly, disableInput, searchPlaceholder, showSearchIcon, searchIconComponent, searchProps, searchNotFound, containerClass, buttonClass, dropdownClass, dropdownListClass, dropdownIconClass, searchContainerClass, searchInputClass, searchIconClass, inputClass, containerStyle, buttonStyle, dropdownStyle, dropdownListStyle, dropdownIconStyle, searchContainerStyle, searchInputStyle, searchIconStyle, inputStyle }: Props) => JSX.Element;
|
|
23
50
|
export default PhoneInput;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { default } from "./PhoneInput";
|
|
1
|
+
export { default, PhoneInputResponseType } from "./PhoneInput";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { default as PhoneInput } from "./PhoneInput";
|
|
1
|
+
export { default as PhoneInput, PhoneInputResponseType } from "./PhoneInput";
|
package/dist/index.d.ts
CHANGED
|
@@ -1,9 +1,16 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
|
|
3
|
+
interface PhoneInputResponseType {
|
|
4
|
+
country: string;
|
|
5
|
+
code: string;
|
|
6
|
+
dialCode: string;
|
|
7
|
+
value: string;
|
|
8
|
+
valueWithoutPlus: string;
|
|
9
|
+
}
|
|
3
10
|
interface Props {
|
|
4
11
|
placeholder: string;
|
|
5
12
|
country: string;
|
|
6
|
-
onChange: (e:
|
|
13
|
+
onChange: (e: PhoneInputResponseType) => void;
|
|
7
14
|
value?: string;
|
|
8
15
|
iconComponent?: React.ReactNode;
|
|
9
16
|
inputProps?: React.DetailedHTMLProps<React.InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>;
|
|
@@ -12,13 +19,33 @@ interface Props {
|
|
|
12
19
|
preferredCountries?: string[];
|
|
13
20
|
showDropdownIcon?: boolean;
|
|
14
21
|
dialCodeInputField?: boolean;
|
|
22
|
+
disableDropdownOnly?: boolean;
|
|
23
|
+
disableInput?: boolean;
|
|
15
24
|
search?: boolean;
|
|
16
25
|
searchPlaceholder?: string;
|
|
17
26
|
showSearchIcon?: boolean;
|
|
18
27
|
searchIconComponent?: React.ReactNode;
|
|
19
28
|
searchProps?: React.DetailedHTMLProps<React.InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>;
|
|
20
29
|
searchNotFound?: string;
|
|
30
|
+
containerClass?: string;
|
|
31
|
+
buttonClass?: string;
|
|
32
|
+
dropdownClass?: string;
|
|
33
|
+
dropdownListClass?: string;
|
|
34
|
+
dropdownIconClass?: string;
|
|
35
|
+
searchContainerClass?: string;
|
|
36
|
+
searchInputClass?: string;
|
|
37
|
+
searchIconClass?: string;
|
|
38
|
+
inputClass?: string;
|
|
39
|
+
containerStyle?: React.CSSProperties;
|
|
40
|
+
buttonStyle?: React.CSSProperties;
|
|
41
|
+
dropdownStyle?: React.CSSProperties;
|
|
42
|
+
dropdownListStyle?: React.CSSProperties;
|
|
43
|
+
dropdownIconStyle?: React.CSSProperties;
|
|
44
|
+
searchContainerStyle?: React.CSSProperties;
|
|
45
|
+
searchInputStyle?: React.CSSProperties;
|
|
46
|
+
searchIconStyle?: React.CSSProperties;
|
|
47
|
+
inputStyle?: React.CSSProperties;
|
|
21
48
|
}
|
|
22
|
-
declare const PhoneInput: ({ placeholder, country, onChange, value, iconComponent, inputProps, onlyCountries, excludeCountries, preferredCountries, showDropdownIcon, dialCodeInputField, search, searchPlaceholder, showSearchIcon, searchIconComponent, searchProps, searchNotFound }: Props) => JSX.Element;
|
|
49
|
+
declare const PhoneInput: ({ placeholder, country, onChange, value, iconComponent, inputProps, onlyCountries, excludeCountries, preferredCountries, showDropdownIcon, dialCodeInputField, search, disableDropdownOnly, disableInput, searchPlaceholder, showSearchIcon, searchIconComponent, searchProps, searchNotFound, containerClass, buttonClass, dropdownClass, dropdownListClass, dropdownIconClass, searchContainerClass, searchInputClass, searchIconClass, inputClass, containerStyle, buttonStyle, dropdownStyle, dropdownListStyle, dropdownIconStyle, searchContainerStyle, searchInputStyle, searchIconStyle, inputStyle }: Props) => JSX.Element;
|
|
23
50
|
|
|
24
|
-
export { PhoneInput };
|
|
51
|
+
export { PhoneInput, PhoneInputResponseType };
|
package/dist/style.css
CHANGED
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
|
|
11
11
|
.simple-phone-input-sri198-main {
|
|
12
12
|
display: flex;
|
|
13
|
-
border: 1px solid
|
|
13
|
+
border: 1px solid rgb(203 203 203);
|
|
14
14
|
user-select: none;
|
|
15
15
|
border-radius: 3px;
|
|
16
16
|
}
|
|
@@ -19,7 +19,8 @@
|
|
|
19
19
|
cursor: pointer;
|
|
20
20
|
display: flex;
|
|
21
21
|
align-items: center;
|
|
22
|
-
background:
|
|
22
|
+
background: rgb(231 231 231);
|
|
23
|
+
border-right: 1px solid rgb(203 203 203);
|
|
23
24
|
}
|
|
24
25
|
|
|
25
26
|
.simple-phone-input-sri198-dropdown-container img {
|
|
@@ -32,17 +33,23 @@
|
|
|
32
33
|
padding: 0;
|
|
33
34
|
margin: 0;
|
|
34
35
|
position: absolute;
|
|
35
|
-
top:
|
|
36
|
+
top: 110%;
|
|
36
37
|
left: 0;
|
|
37
38
|
right: 0;
|
|
38
39
|
height: 250px;
|
|
39
40
|
overflow-y: auto;
|
|
40
|
-
box-shadow:
|
|
41
|
-
|
|
41
|
+
box-shadow: 0px 4px 15px rgb(163 163 163);
|
|
42
|
+
border-radius: 3px;
|
|
43
|
+
transition: 0.3s ease;
|
|
44
|
+
transform: translateY(-5px);
|
|
45
|
+
opacity: 0;
|
|
46
|
+
visibility: hidden;
|
|
42
47
|
}
|
|
43
48
|
|
|
44
49
|
.simple-phone-input-sri198-dropdown.active {
|
|
45
|
-
|
|
50
|
+
transform: translateY(0px);
|
|
51
|
+
opacity: 1;
|
|
52
|
+
visibility: visible;
|
|
46
53
|
}
|
|
47
54
|
|
|
48
55
|
.simple-phone-input-sri198-dropdown li {
|
|
@@ -67,7 +74,8 @@
|
|
|
67
74
|
display: flex;
|
|
68
75
|
flex: 1;
|
|
69
76
|
width: 92px;
|
|
70
|
-
padding:
|
|
77
|
+
padding: 7px 2px 7px 7px;
|
|
78
|
+
align-items: center;
|
|
71
79
|
}
|
|
72
80
|
|
|
73
81
|
.simple-phone-input-sri198-dropdown-container-button.dial {
|
|
@@ -103,7 +111,7 @@
|
|
|
103
111
|
.simple-phone-input-sri198-selected-code {
|
|
104
112
|
flex: 1;
|
|
105
113
|
font-size: 14px;
|
|
106
|
-
margin-top:
|
|
114
|
+
margin-top: 2px;
|
|
107
115
|
}
|
|
108
116
|
|
|
109
117
|
.simple-phone-input-sri198-input {
|
package/package.json
CHANGED