intl-tel-input 26.0.0-beta.0 → 26.0.1

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.
Files changed (206) hide show
  1. package/README.md +26 -20
  2. package/angular/README.md +1 -1
  3. package/angular/build/IntlTelInput.js +1 -1
  4. package/angular/build/IntlTelInputWithUtils.js +125 -186
  5. package/angular/build/types/intl-tel-input/i18n/index.d.ts +1 -0
  6. package/angular/build/types/intl-tel-input/i18n/zh-hk/index.d.ts +3 -0
  7. package/build/js/data.js +1 -1
  8. package/build/js/data.min.js +1 -1
  9. package/build/js/i18n/ar/countries.js +245 -0
  10. package/build/js/i18n/ar/index.js +1 -0
  11. package/build/js/i18n/ar/interface.js +23 -0
  12. package/build/js/i18n/bg/countries.js +245 -0
  13. package/build/js/i18n/bg/index.js +1 -0
  14. package/build/js/i18n/bg/interface.js +13 -0
  15. package/build/js/i18n/bn/countries.js +245 -0
  16. package/build/js/i18n/bn/index.js +1 -0
  17. package/build/js/i18n/bn/interface.js +13 -0
  18. package/build/js/i18n/bs/countries.js +245 -0
  19. package/build/js/i18n/bs/index.js +1 -0
  20. package/build/js/i18n/bs/interface.js +20 -0
  21. package/build/js/i18n/ca/countries.js +245 -0
  22. package/build/js/i18n/ca/index.js +1 -0
  23. package/build/js/i18n/ca/interface.js +13 -0
  24. package/build/js/i18n/cs/countries.js +245 -0
  25. package/build/js/i18n/cs/index.js +1 -0
  26. package/build/js/i18n/cs/interface.js +20 -0
  27. package/build/js/i18n/da/countries.js +245 -0
  28. package/build/js/i18n/da/index.js +1 -0
  29. package/build/js/i18n/da/interface.js +13 -0
  30. package/build/js/i18n/de/countries.js +245 -0
  31. package/build/js/i18n/de/index.js +1 -0
  32. package/build/js/i18n/de/interface.js +13 -0
  33. package/build/js/i18n/ee/countries.js +245 -0
  34. package/build/js/i18n/ee/index.js +1 -0
  35. package/build/js/i18n/ee/interface.js +13 -0
  36. package/build/js/i18n/el/countries.js +245 -0
  37. package/build/js/i18n/el/index.js +1 -0
  38. package/build/js/i18n/el/interface.js +13 -0
  39. package/build/js/i18n/en/countries.js +245 -0
  40. package/build/js/i18n/en/interface.js +14 -0
  41. package/build/js/i18n/es/countries.js +245 -0
  42. package/build/js/i18n/es/index.js +1 -0
  43. package/build/js/i18n/es/interface.js +13 -0
  44. package/build/js/i18n/fa/countries.js +245 -0
  45. package/build/js/i18n/fa/index.js +1 -0
  46. package/build/js/i18n/fa/interface.js +13 -0
  47. package/build/js/i18n/fi/countries.js +245 -0
  48. package/build/js/i18n/fi/index.js +1 -0
  49. package/build/js/i18n/fi/interface.js +13 -0
  50. package/build/js/i18n/fr/countries.js +245 -0
  51. package/build/js/i18n/fr/index.js +1 -0
  52. package/build/js/i18n/fr/interface.js +13 -0
  53. package/build/js/i18n/hi/countries.js +245 -0
  54. package/build/js/i18n/hi/index.js +1 -0
  55. package/build/js/i18n/hi/interface.js +13 -0
  56. package/build/js/i18n/hr/countries.js +245 -0
  57. package/build/js/i18n/hr/index.js +1 -0
  58. package/build/js/i18n/hr/interface.js +20 -0
  59. package/build/js/i18n/hu/countries.js +245 -0
  60. package/build/js/i18n/hu/index.js +1 -0
  61. package/build/js/i18n/hu/interface.js +13 -0
  62. package/build/js/i18n/id/countries.js +245 -0
  63. package/build/js/i18n/id/index.js +1 -0
  64. package/build/js/i18n/id/interface.js +13 -0
  65. package/build/js/i18n/index.js +1 -0
  66. package/build/js/i18n/it/countries.js +245 -0
  67. package/build/js/i18n/it/index.js +1 -0
  68. package/build/js/i18n/it/interface.js +13 -0
  69. package/build/js/i18n/ja/countries.js +245 -0
  70. package/build/js/i18n/ja/index.js +1 -0
  71. package/build/js/i18n/ja/interface.js +13 -0
  72. package/build/js/i18n/ko/countries.js +245 -0
  73. package/build/js/i18n/ko/index.js +1 -0
  74. package/build/js/i18n/ko/interface.js +13 -0
  75. package/build/js/i18n/lt/countries.js +245 -0
  76. package/build/js/i18n/lt/interface.js +26 -0
  77. package/build/js/i18n/mr/countries.js +245 -0
  78. package/build/js/i18n/mr/index.js +1 -0
  79. package/build/js/i18n/mr/interface.js +13 -0
  80. package/build/js/i18n/nl/countries.js +245 -0
  81. package/build/js/i18n/nl/index.js +1 -0
  82. package/build/js/i18n/nl/interface.js +13 -0
  83. package/build/js/i18n/no/countries.js +245 -0
  84. package/build/js/i18n/no/index.js +1 -0
  85. package/build/js/i18n/no/interface.js +13 -0
  86. package/build/js/i18n/pl/countries.js +245 -0
  87. package/build/js/i18n/pl/index.js +1 -0
  88. package/build/js/i18n/pl/interface.js +19 -0
  89. package/build/js/i18n/pt/countries.js +245 -0
  90. package/build/js/i18n/pt/index.js +1 -0
  91. package/build/js/i18n/pt/interface.js +13 -0
  92. package/build/js/i18n/ro/countries.js +245 -0
  93. package/build/js/i18n/ro/index.js +1 -0
  94. package/build/js/i18n/ro/interface.js +18 -0
  95. package/build/js/i18n/ru/countries.js +245 -0
  96. package/build/js/i18n/ru/index.js +1 -0
  97. package/build/js/i18n/ru/interface.js +20 -0
  98. package/build/js/i18n/sk/countries.js +245 -0
  99. package/build/js/i18n/sk/index.js +1 -0
  100. package/build/js/i18n/sk/interface.js +20 -0
  101. package/build/js/i18n/sl/countries.js +245 -0
  102. package/build/js/i18n/sl/interface.js +25 -0
  103. package/build/js/i18n/sq/countries.js +245 -0
  104. package/build/js/i18n/sq/interface.js +14 -0
  105. package/build/js/i18n/sr/countries.js +245 -0
  106. package/build/js/i18n/sr/interface.js +21 -0
  107. package/build/js/i18n/sv/countries.js +245 -0
  108. package/build/js/i18n/sv/index.js +1 -0
  109. package/build/js/i18n/sv/interface.js +13 -0
  110. package/build/js/i18n/te/countries.js +245 -0
  111. package/build/js/i18n/te/index.js +1 -0
  112. package/build/js/i18n/te/interface.js +13 -0
  113. package/build/js/i18n/th/countries.js +245 -0
  114. package/build/js/i18n/th/index.js +1 -0
  115. package/build/js/i18n/th/interface.js +13 -0
  116. package/build/js/i18n/tr/countries.js +245 -0
  117. package/build/js/i18n/tr/index.js +1 -0
  118. package/build/js/i18n/tr/interface.js +13 -0
  119. package/build/js/i18n/uk/countries.js +245 -0
  120. package/build/js/i18n/uk/index.js +1 -0
  121. package/build/js/i18n/uk/interface.js +20 -0
  122. package/build/js/i18n/ur/countries.js +245 -0
  123. package/build/js/i18n/ur/index.js +1 -0
  124. package/build/js/i18n/ur/interface.js +13 -0
  125. package/build/js/i18n/uz/countries.js +245 -0
  126. package/build/js/i18n/uz/index.js +1 -0
  127. package/build/js/i18n/uz/interface.js +13 -0
  128. package/build/js/i18n/vi/countries.js +245 -0
  129. package/build/js/i18n/vi/index.js +1 -0
  130. package/build/js/i18n/vi/interface.js +13 -0
  131. package/build/js/i18n/zh/countries.js +245 -0
  132. package/build/js/i18n/zh/index.js +1 -0
  133. package/build/js/i18n/zh/interface.js +13 -0
  134. package/build/js/i18n/zh-hk/countries.js +245 -0
  135. package/build/js/i18n/zh-hk/index.js +18 -0
  136. package/build/js/i18n/zh-hk/interface.js +14 -0
  137. package/build/js/intlTelInput.d.ts +6 -0
  138. package/build/js/intlTelInput.js +2 -2
  139. package/build/js/intlTelInput.min.js +2 -2
  140. package/build/js/intlTelInputWithUtils.js +126 -187
  141. package/build/js/intlTelInputWithUtils.min.js +2 -2
  142. package/build/js/utils.js +53 -54
  143. package/package.json +2 -2
  144. package/react/README.md +4 -2
  145. package/react/build/IntlTelInput.cjs +1 -1
  146. package/react/build/IntlTelInput.d.ts +6 -0
  147. package/react/build/IntlTelInput.js +1 -1
  148. package/react/build/IntlTelInputWithUtils.cjs +125 -186
  149. package/react/build/IntlTelInputWithUtils.js +125 -186
  150. package/svelte/README.md +7 -9
  151. package/svelte/build/IntlTelInput.mjs +1437 -1437
  152. package/svelte/build/IntlTelInputWithUtils.mjs +1785 -1846
  153. package/vue/README.md +12 -10
  154. package/vue/build/IntlTelInput.vue.d.ts +2 -0
  155. package/vue/build/IntlTelInputWithUtils.vue.d.ts +2 -0
  156. package/vue/build/exports/IntlTelInput.mjs +17 -16
  157. package/vue/build/exports/IntlTelInputWithUtils.mjs +176 -236
  158. package/vue/build/intl-tel-input/data.d.ts +18 -0
  159. package/vue/build/intl-tel-input/i18n/ar/index.d.ts +3 -0
  160. package/vue/build/intl-tel-input/i18n/bg/index.d.ts +3 -0
  161. package/vue/build/intl-tel-input/i18n/bn/index.d.ts +3 -0
  162. package/vue/build/intl-tel-input/i18n/bs/index.d.ts +3 -0
  163. package/vue/build/intl-tel-input/i18n/ca/index.d.ts +3 -0
  164. package/vue/build/intl-tel-input/i18n/cs/index.d.ts +3 -0
  165. package/vue/build/intl-tel-input/i18n/da/index.d.ts +3 -0
  166. package/vue/build/intl-tel-input/i18n/de/index.d.ts +3 -0
  167. package/vue/build/intl-tel-input/i18n/ee/index.d.ts +3 -0
  168. package/vue/build/intl-tel-input/i18n/el/index.d.ts +3 -0
  169. package/vue/build/intl-tel-input/i18n/en/index.d.ts +3 -0
  170. package/vue/build/intl-tel-input/i18n/es/index.d.ts +3 -0
  171. package/vue/build/intl-tel-input/i18n/fa/index.d.ts +3 -0
  172. package/vue/build/intl-tel-input/i18n/fi/index.d.ts +3 -0
  173. package/vue/build/intl-tel-input/i18n/fr/index.d.ts +3 -0
  174. package/vue/build/intl-tel-input/i18n/hi/index.d.ts +3 -0
  175. package/vue/build/intl-tel-input/i18n/hr/index.d.ts +3 -0
  176. package/vue/build/intl-tel-input/i18n/hu/index.d.ts +3 -0
  177. package/vue/build/intl-tel-input/i18n/id/index.d.ts +3 -0
  178. package/vue/build/intl-tel-input/i18n/index.d.ts +44 -0
  179. package/vue/build/intl-tel-input/i18n/it/index.d.ts +3 -0
  180. package/vue/build/intl-tel-input/i18n/ja/index.d.ts +3 -0
  181. package/vue/build/intl-tel-input/i18n/ko/index.d.ts +3 -0
  182. package/vue/build/intl-tel-input/i18n/lt/index.d.ts +3 -0
  183. package/vue/build/intl-tel-input/i18n/mr/index.d.ts +3 -0
  184. package/vue/build/intl-tel-input/i18n/nl/index.d.ts +3 -0
  185. package/vue/build/intl-tel-input/i18n/no/index.d.ts +3 -0
  186. package/vue/build/intl-tel-input/i18n/pl/index.d.ts +3 -0
  187. package/vue/build/intl-tel-input/i18n/pt/index.d.ts +3 -0
  188. package/vue/build/intl-tel-input/i18n/ro/index.d.ts +3 -0
  189. package/vue/build/intl-tel-input/i18n/ru/index.d.ts +3 -0
  190. package/vue/build/intl-tel-input/i18n/sk/index.d.ts +3 -0
  191. package/vue/build/intl-tel-input/i18n/sl/index.d.ts +3 -0
  192. package/vue/build/intl-tel-input/i18n/sq/index.d.ts +3 -0
  193. package/vue/build/intl-tel-input/i18n/sr/index.d.ts +3 -0
  194. package/vue/build/intl-tel-input/i18n/sv/index.d.ts +3 -0
  195. package/vue/build/intl-tel-input/i18n/te/index.d.ts +3 -0
  196. package/vue/build/intl-tel-input/i18n/th/index.d.ts +3 -0
  197. package/vue/build/intl-tel-input/i18n/tr/index.d.ts +3 -0
  198. package/vue/build/intl-tel-input/i18n/types.d.ts +10 -0
  199. package/vue/build/intl-tel-input/i18n/uk/index.d.ts +3 -0
  200. package/vue/build/intl-tel-input/i18n/ur/index.d.ts +3 -0
  201. package/vue/build/intl-tel-input/i18n/uz/index.d.ts +3 -0
  202. package/vue/build/intl-tel-input/i18n/vi/index.d.ts +3 -0
  203. package/vue/build/intl-tel-input/i18n/zh/index.d.ts +3 -0
  204. package/vue/build/intl-tel-input/i18n/zh-hk/index.d.ts +3 -0
  205. package/vue/build/intl-tel-input/intlTelInputWithUtils.d.ts +2 -0
  206. package/vue/build/{intl-tel-input-BY4WpieT.mjs → intl-tel-input-Bk5kP2Ot.mjs} +1 -1
package/README.md CHANGED
@@ -1,14 +1,14 @@
1
1
  # International Telephone Input [![CI](https://github.com/jackocnr/intl-tel-input/actions/workflows/ci.yml/badge.svg?branch=master)](https://github.com/jackocnr/intl-tel-input/actions/workflows/ci.yml) <img src="https://img.shields.io/github/package-json/v/jackocnr/intl-tel-input.svg" alt="version"/> <img src="https://img.shields.io/npm/dm/intl-tel-input.svg" alt="downloads"/>
2
2
 
3
- <img src="https://raw.github.com/jackocnr/intl-tel-input/master/screenshots/vue-icon.png" alt="Vue logo" width="16" /> NEWS: we now have our own <a href="https://github.com/jackocnr/intl-tel-input/tree/master/vue">Vue component</a>!
3
+ 🗣️ NEWS: [v26.0.0-beta.0](https://github.com/jackocnr/intl-tel-input/releases/tag/v26.0.0-beta.0) released, with support for:
4
+ - Autocomplete
5
+ - TypeScript types for the Vue component
6
+ - Country names now generated with `Intl.DisplayNames` (reduced bundle size)
7
+ - A more easily customisable globe icon SVG
8
+ - Modernised CSS
9
+ - More control over number extensions
4
10
 
5
- <img src="https://raw.github.com/jackocnr/intl-tel-input/master/screenshots/react.webp" alt="React logo" width="16" /> NEWS: we now have our own <a href="https://github.com/jackocnr/intl-tel-input/tree/master/react">React component</a>! Play with it on <a href="https://intl-tel-input.com/storybook/?path=/docs/intltelinput--vanilla">Storybook</a>.
6
-
7
- <img src="https://raw.github.com/jackocnr/intl-tel-input/master/screenshots/angular.png" alt="Angular logo" width="16" /> NEWS: we now have our own <a href="https://github.com/jackocnr/intl-tel-input/tree/master/angular">Angular component</a>!
8
-
9
- 🗣️ NEWS: we now provide [translations](#translations) in over 40 languages! [See them in action](https://intl-tel-input.com/storybook/?path=/docs/intltelinput--i18n).
10
-
11
- International Telephone Input is a JavaScript plugin for entering and validating international telephone numbers. It takes a regular input field, adds a searchable country dropdown, auto-detects the user's country, displays a relevant placeholder number, formats the number as you type, and provides comprehensive validation methods. React, Vue and Angular components are also included.
11
+ International Telephone Input is a JavaScript plugin for entering and validating international telephone numbers. It takes a regular input field, adds a searchable country dropdown, auto-detects the user's country, displays a relevant placeholder number, formats the number as you type, and provides comprehensive validation methods. [React](https://github.com/jackocnr/intl-tel-input/blob/master/react/README.md), [Vue](https://github.com/jackocnr/intl-tel-input/blob/master/vue/README.md), [Angular](https://github.com/jackocnr/intl-tel-input/blob/master/angular/README.md) and [Svelte (beta)](https://github.com/jackocnr/intl-tel-input/blob/master/svelte/README.md) components are also included.
12
12
 
13
13
  <picture>
14
14
  <source media="(prefers-color-scheme: dark)" srcset="https://raw.github.com/jackocnr/intl-tel-input/master/screenshots/vanilla-dark.png">
@@ -25,7 +25,7 @@ Use [Twilio's API to build phone verification, SMS 2FA, appointment reminders, m
25
25
 
26
26
  ## Table of Contents
27
27
 
28
- - [React, Vue and Angular Components](#react-vue-and-angular-components)
28
+ - [React, Vue, Angular and Svelte Components](#react-vue-angular-and-svelte-components)
29
29
  - [Demo and Examples](#demo-and-examples)
30
30
  - [Mobile](#mobile)
31
31
  - [Features](#features)
@@ -44,11 +44,13 @@ Use [Twilio's API to build phone verification, SMS 2FA, appointment reminders, m
44
44
  - [Contributing](#contributing)
45
45
  - [Attributions](#attributions)
46
46
 
47
- ## React, Vue and Angular Components
48
- We now provide React, Vue and Angular components alongside the regular JavaScript plugin. This readme is for the JavaScript plugin. View the [React Component readme](https://github.com/jackocnr/intl-tel-input/blob/master/react/README.md), the [Vue Component readme](https://github.com/jackocnr/intl-tel-input/blob/master/vue/README.md) or the [Angular Component readme](https://github.com/jackocnr/intl-tel-input/blob/master/angular/README.md).
47
+ ## React, Vue, Angular and Svelte Components
48
+ We now provide React, Vue, Angular and Svelte (beta) components alongside the regular JavaScript plugin. This readme is for the JavaScript plugin. View the [React Component](https://github.com/jackocnr/intl-tel-input/blob/master/react/README.md), the [Vue Component](https://github.com/jackocnr/intl-tel-input/blob/master/vue/README.md) the [Angular Component](https://github.com/jackocnr/intl-tel-input/blob/master/angular/README.md), or the [Svelte component (beta)](https://github.com/jackocnr/intl-tel-input/blob/master/svelte/README.md).
49
49
 
50
50
  ## Demo and Examples
51
- You can view [a live demo](https://intl-tel-input.com) and see some examples of how to use the various options. Alternatively, try it for yourself by downloading the project and opening demo.html in a browser.
51
+ View the [live demo](https://intl-tel-input.com) for examples of how to use the various options, along with the relevant code snippets. Or play with the options yourself on [Storybook](https://intl-tel-input.com/storybook/?path=/docs/intltelinput--vanilla).
52
+
53
+ Alternatively, download and build the project yourself in 3 simple steps. You just need to initialise the submodules with `git submodule update --init --recursive`, then run `npm install`, and then `npm run build`. You should now be able to open the included demo.html in your browser and have a working plugin!
52
54
 
53
55
  ## Mobile
54
56
  By default, on mobile devices, we show a fullscreen popup instead of the inline dropdown to make better use of the limited screen space. This is similar to how a native `<select>` element works. You can control this behaviour with the `useFullscreenPopup` option. The popup can be closed by either selecting a country from the list or by tapping on the grey area on the sides. [See example](https://intl-tel-input.com/storybook/?path=/docs/intltelinput--usefullscreenpopup) (using the React component).
@@ -67,8 +69,8 @@ By default, on mobile devices, we show a fullscreen popup instead of the inline
67
69
  * Accessibility provided via ARIA tags
68
70
  * Typescript type definitions included
69
71
  * Easily customise styles by overriding CSS variables, e.g. support dark mode
70
- * React, Vue, and Angular components also included
71
- * Translations for country names (etc) provided in over 40 languages, and support for RTL layout
72
+ * React, Vue, Angular and Svelte components also included
73
+ * Translations provided in over 40 languages, as well as support for RTL layout and alternative numeral sets
72
74
  * Lots of initialisation options for customisation, as well as instance methods/events for interaction
73
75
 
74
76
  ## Browser Compatibility
@@ -81,16 +83,16 @@ _Note: We have now dropped support for all versions of Internet Explorer because
81
83
  ## Getting Started (Using a CDN)
82
84
  1. Add the CSS
83
85
  ```html
84
- <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/intl-tel-input@25.15.0/build/css/intlTelInput.css">
86
+ <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/intl-tel-input@26.0.1/build/css/intlTelInput.css">
85
87
  ```
86
88
 
87
89
  2. Add the plugin script and initialise it on your input element
88
90
  ```html
89
- <script src="https://cdn.jsdelivr.net/npm/intl-tel-input@25.15.0/build/js/intlTelInput.min.js"></script>
91
+ <script src="https://cdn.jsdelivr.net/npm/intl-tel-input@26.0.1/build/js/intlTelInput.min.js"></script>
90
92
  <script>
91
93
  const input = document.querySelector("#phone");
92
94
  window.intlTelInput(input, {
93
- loadUtils: () => import("https://cdn.jsdelivr.net/npm/intl-tel-input@25.15.0/build/js/utils.js"),
95
+ loadUtils: () => import("https://cdn.jsdelivr.net/npm/intl-tel-input@26.0.1/build/js/utils.js"),
94
96
  });
95
97
  </script>
96
98
  ```
@@ -165,7 +167,7 @@ When you initialise the plugin, the first argument is the input element, and the
165
167
  Type: `Boolean` Default: `true`
166
168
  Whether or not to allow the dropdown. If disabled, there is no dropdown arrow, and the selected country is not clickable. Also, if showFlags is enabled, we display the selected flag on the right instead, because it is just a marker of state. Note that if `separateDialCode` is enabled, `allowDropdown` is forced to `true` as the dropdown is required when the user types "+" in this case. Play with this option on [Storybook](https://intl-tel-input.com/storybook/?path=/docs/intltelinput--allowdropdown) (using the React component).
167
169
 
168
- **allowNumberExtensions**.
170
+ **allowNumberExtensions**
169
171
  Type: `Boolean` Default: `false`
170
172
  Whether or not the validation methods return `true` for numbers containing extensions, e.g. "+1 702 123-1234 ext. 1234".
171
173
 
@@ -181,6 +183,10 @@ Set the input's placeholder to an example number for the selected country, and u
181
183
  Type: `String` Default: `""`
182
184
  Additional classes to add to the (injected) wrapper `<div>`.
183
185
 
186
+ **countryNameLocale**
187
+ Type: `String` Default: `"en"`
188
+ The locale to pass to `Intl.DisplayNames` to generate the country names.
189
+
184
190
  **countryOrder**
185
191
  Type: `Array` Default: `null`
186
192
  Specify the ordering for the country list with an array of iso2 country codes. Any omitted countries will appear after those specified, in alphabetical order, e.g. setting `countryOrder` to `["jp", "kr"]` will result in the list: Japan, South Korea, Afghanistan, Albania, Algeria etc...
@@ -316,12 +322,12 @@ Set the initial country selection by specifying its country code, e.g. `"us"` fo
316
322
  Type: `() => Promise<module>` Default: `null`
317
323
  This is one way to lazy load the included utils.js (to enable formatting/validation, etc) - see [Loading The Utilities Script](#loading-the-utilities-script) for more options.
318
324
 
319
- The `loadUtils` option takes a function that returns a Promise resolving to the utils module (see example code below). You can `import` the utils module in different ways: (A) from a CDN, (B) from your own hosted version of [utils.js](https://cdn.jsdelivr.net/npm/intl-tel-input@25.15.0/build/js/utils.js), or (C) if you use a bundler like Webpack, Vite or Parcel, you can import it directly from the package.
325
+ The `loadUtils` option takes a function that returns a Promise resolving to the utils module (see example code below). You can `import` the utils module in different ways: (A) from a CDN, (B) from your own hosted version of [utils.js](https://cdn.jsdelivr.net/npm/intl-tel-input@26.0.1/build/js/utils.js), or (C) if you use a bundler like Webpack, Vite or Parcel, you can import it directly from the package.
320
326
 
321
327
  ```js
322
328
  // (A) import utils module from a CDN
323
329
  intlTelInput(htmlInputElement, {
324
- loadUtils: () => import("https://cdn.jsdelivr.net/npm/intl-tel-input@25.15.0/build/js/utils.js"),
330
+ loadUtils: () => import("https://cdn.jsdelivr.net/npm/intl-tel-input@26.0.1/build/js/utils.js"),
325
331
  });
326
332
 
327
333
  // (B) import utils module from your own hosted version of utils.js
package/angular/README.md CHANGED
@@ -54,7 +54,7 @@ import "intl-tel-input/styles";
54
54
 
55
55
  See the [validation demo](https://github.com/jackocnr/intl-tel-input/blob/master/angular/demo/validation/validation.component.ts) for a more fleshed-out example of how to handle validation, or check out the [form demo](https://github.com/jackocnr/intl-tel-input/blob/master/angular/demo/form/form.component.ts) for an alternative approach using `ReactiveFormsModule`.
56
56
 
57
- A note on the utils script (~260KB): if you're lazy loading the IntlTelInput chunk (and so less worried about filesize) then you can just `import { IntlTelInputComponent } from "intl-tel-input/angularWithUtils"`, to include the utils script. Alternatively, if you use the main `"intl-tel-input/angular"` import, then you should couple this with the `loadUtils` initialisation option - you will need to host the [utils.js](https://github.com/jackocnr/intl-tel-input/blob/master/build/js/utils.js) file, and then set the `loadUtils` option to that URL, or alternatively just point it to a CDN hosted version e.g. `"https://cdn.jsdelivr.net/npm/intl-tel-input@25.15.0/build/js/utils.js"`.
57
+ A note on the utils script (~260KB): if you're lazy loading the IntlTelInput chunk (and so less worried about filesize) then you can just `import { IntlTelInputComponent } from "intl-tel-input/angularWithUtils"`, to include the utils script. Alternatively, if you use the main `"intl-tel-input/angular"` import, then you should couple this with the `loadUtils` initialisation option - you will need to host the [utils.js](https://github.com/jackocnr/intl-tel-input/blob/master/build/js/utils.js) file, and then set the `loadUtils` option to that URL, or alternatively just point it to a CDN hosted version e.g. `"https://cdn.jsdelivr.net/npm/intl-tel-input@26.0.1/build/js/utils.js"`.
58
58
 
59
59
  ## Props
60
60
 
@@ -3629,7 +3629,7 @@ var intlTelInput = Object.assign((input, options) => {
3629
3629
  attachUtils,
3630
3630
  startedLoadingUtilsScript: false,
3631
3631
  startedLoadingAutoCountry: false,
3632
- version: "26.0.0-beta.0"
3632
+ version: "26.0.1"
3633
3633
  });
3634
3634
  var intl_tel_input_default = intlTelInput;
3635
3635