intl-tel-input 25.14.1 → 25.15.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 (98) hide show
  1. package/README.md +21 -19
  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/build/css/intlTelInput-no-assets.css +1259 -0
  6. package/build/css/intlTelInput-no-assets.min.css +1 -0
  7. package/build/css/intlTelInput.css +6 -4
  8. package/build/css/intlTelInput.min.css +1 -1
  9. package/build/js/data.js +1 -1
  10. package/build/js/data.min.js +1 -1
  11. package/build/js/i18n/zh-hk/countries.js +245 -0
  12. package/build/js/i18n/zh-hk/index.js +5 -0
  13. package/build/js/i18n/zh-hk/interface.js +14 -0
  14. package/build/js/intlTelInput.js +2 -2
  15. package/build/js/intlTelInput.min.js +2 -2
  16. package/build/js/intlTelInputWithUtils.js +126 -187
  17. package/build/js/intlTelInputWithUtils.min.js +2 -2
  18. package/build/js/utils.js +53 -54
  19. package/package.json +2 -2
  20. package/react/README.md +4 -2
  21. package/react/build/IntlTelInput.cjs +1 -1
  22. package/react/build/IntlTelInput.js +1 -1
  23. package/react/build/IntlTelInputWithUtils.cjs +125 -186
  24. package/react/build/IntlTelInputWithUtils.js +125 -186
  25. package/svelte/README.md +7 -9
  26. package/svelte/build/IntlTelInput.mjs +1329 -1329
  27. package/svelte/build/IntlTelInputWithUtils.mjs +1829 -1890
  28. package/vue/README.md +7 -9
  29. package/vue/build/IntlTelInput.mjs +1 -1
  30. package/vue/build/IntlTelInput.vue.d.ts +34 -0
  31. package/vue/build/IntlTelInputWithUtils.mjs +125 -186
  32. package/vue/build/IntlTelInputWithUtils.vue.d.ts +34 -0
  33. package/vue/build/exports/IntlTelInput.d.ts +3 -0
  34. package/vue/build/exports/IntlTelInput.mjs +66 -0
  35. package/vue/build/exports/IntlTelInputWithUtils.d.ts +3 -0
  36. package/vue/build/exports/IntlTelInputWithUtils.mjs +6207 -0
  37. package/vue/build/intl-tel-input/data.d.ts +18 -0
  38. package/vue/build/intl-tel-input/i18n/ar/index.d.ts +3 -0
  39. package/vue/build/intl-tel-input/i18n/bg/index.d.ts +3 -0
  40. package/vue/build/intl-tel-input/i18n/bn/index.d.ts +3 -0
  41. package/vue/build/intl-tel-input/i18n/bs/index.d.ts +3 -0
  42. package/vue/build/intl-tel-input/i18n/ca/index.d.ts +3 -0
  43. package/vue/build/intl-tel-input/i18n/cs/index.d.ts +3 -0
  44. package/vue/build/intl-tel-input/i18n/da/index.d.ts +3 -0
  45. package/vue/build/intl-tel-input/i18n/de/index.d.ts +3 -0
  46. package/vue/build/intl-tel-input/i18n/ee/index.d.ts +3 -0
  47. package/vue/build/intl-tel-input/i18n/el/index.d.ts +3 -0
  48. package/vue/build/intl-tel-input/i18n/en/index.d.ts +3 -0
  49. package/vue/build/intl-tel-input/i18n/es/index.d.ts +3 -0
  50. package/vue/build/intl-tel-input/i18n/fa/index.d.ts +3 -0
  51. package/vue/build/intl-tel-input/i18n/fi/index.d.ts +3 -0
  52. package/vue/build/intl-tel-input/i18n/fr/index.d.ts +3 -0
  53. package/vue/build/intl-tel-input/i18n/hi/index.d.ts +3 -0
  54. package/vue/build/intl-tel-input/i18n/hr/index.d.ts +3 -0
  55. package/vue/build/intl-tel-input/i18n/hu/index.d.ts +3 -0
  56. package/vue/build/intl-tel-input/i18n/id/index.d.ts +3 -0
  57. package/vue/build/intl-tel-input/i18n/index.d.ts +43 -0
  58. package/vue/build/intl-tel-input/i18n/it/index.d.ts +3 -0
  59. package/vue/build/intl-tel-input/i18n/ja/index.d.ts +3 -0
  60. package/vue/build/intl-tel-input/i18n/ko/index.d.ts +3 -0
  61. package/vue/build/intl-tel-input/i18n/lt/index.d.ts +3 -0
  62. package/vue/build/intl-tel-input/i18n/mr/index.d.ts +3 -0
  63. package/vue/build/intl-tel-input/i18n/nl/index.d.ts +3 -0
  64. package/vue/build/intl-tel-input/i18n/no/index.d.ts +3 -0
  65. package/vue/build/intl-tel-input/i18n/pl/index.d.ts +3 -0
  66. package/vue/build/intl-tel-input/i18n/pt/index.d.ts +3 -0
  67. package/vue/build/intl-tel-input/i18n/ro/index.d.ts +3 -0
  68. package/vue/build/intl-tel-input/i18n/ru/index.d.ts +3 -0
  69. package/vue/build/intl-tel-input/i18n/sk/index.d.ts +3 -0
  70. package/vue/build/intl-tel-input/i18n/sl/index.d.ts +3 -0
  71. package/vue/build/intl-tel-input/i18n/sq/index.d.ts +3 -0
  72. package/vue/build/intl-tel-input/i18n/sr/index.d.ts +3 -0
  73. package/vue/build/intl-tel-input/i18n/sv/index.d.ts +3 -0
  74. package/vue/build/intl-tel-input/i18n/te/index.d.ts +3 -0
  75. package/vue/build/intl-tel-input/i18n/th/index.d.ts +3 -0
  76. package/vue/build/intl-tel-input/i18n/tr/index.d.ts +3 -0
  77. package/vue/build/intl-tel-input/i18n/types.d.ts +10 -0
  78. package/vue/build/intl-tel-input/i18n/uk/index.d.ts +3 -0
  79. package/vue/build/intl-tel-input/i18n/ur/index.d.ts +3 -0
  80. package/vue/build/intl-tel-input/i18n/uz/index.d.ts +3 -0
  81. package/vue/build/intl-tel-input/i18n/vi/index.d.ts +3 -0
  82. package/vue/build/intl-tel-input/i18n/zh/index.d.ts +3 -0
  83. package/vue/build/intl-tel-input/intlTelInputWithUtils.d.ts +2 -0
  84. package/vue/build/intl-tel-input-f0-6rrpA.mjs +3081 -0
  85. package/vue/build/intl-tel-input.d.ts +97 -0
  86. package/vue/build/modules/constants.d.ts +85 -0
  87. package/vue/build/modules/core/countrySearch.d.ts +17 -0
  88. package/vue/build/modules/core/icons.d.ts +9 -0
  89. package/vue/build/modules/core/options.d.ts +3 -0
  90. package/vue/build/modules/core/ui.d.ts +45 -0
  91. package/vue/build/modules/data/country-data.d.ts +12 -0
  92. package/vue/build/modules/data/nanp-regionless.d.ts +2 -0
  93. package/vue/build/modules/format/caret.d.ts +1 -0
  94. package/vue/build/modules/format/formatting.d.ts +3 -0
  95. package/vue/build/modules/types/events.d.ts +9 -0
  96. package/vue/build/modules/types/public-api.d.ts +79 -0
  97. package/vue/build/modules/utils/dom.d.ts +6 -0
  98. package/vue/build/modules/utils/string.d.ts +2 -0
package/vue/README.md CHANGED
@@ -10,7 +10,9 @@ A Vue component wrapper for the [intl-tel-input](https://github.com/jackocnr/int
10
10
  - [Accessing Static Methods](#accessing-static-methods)
11
11
 
12
12
  ## Demo
13
- Try it for yourself by downloading the project and running `npm install` and then `npm run vue:demo` and then copy the given URL into your browser.
13
+ There is a demo of the Vue component on the [demo site](https://intl-tel-input.com/examples/vue-component.html) with example code.
14
+
15
+ 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 can then run `npm run vue:demo` and copy the given URL into your browser. By default, this is setup to show the validation demo - you can change this by locating the `"vue:demo"` task in the scripts section of package.json, and updating the demo path accordingly. View a list of available demos [here](https://github.com/jackocnr/intl-tel-input/tree/master/vue/demo).
14
16
 
15
17
  ## Getting Started
16
18
  ```vue
@@ -28,13 +30,9 @@ Try it for yourself by downloading the project and running `npm install` and the
28
30
  </template>
29
31
  ```
30
32
 
31
- See the [Validation demo](https://github.com/jackocnr/intl-tel-input/blob/master/vue/demo/validation/App.vue) for a more fleshed-out example of how to handle validation. Make sure to change the path in the `package.json` script to the correct demo if you're running it locally e.g.:
32
-
33
- ```
34
- "vue:demo": "vite --config vue/demo/[demo variant]/vite.config.js"
35
- ```
33
+ See the [Validation demo](https://github.com/jackocnr/intl-tel-input/blob/master/vue/demo/validation/App.vue) for a more fleshed-out example of how to handle validation. See the instructions above for how to run this demo (and others) yourself.
36
34
 
37
- 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 IntlTelInput from `"intl-tel-input/vueWithUtils"`, to include the utils script. Alternatively, if you use the main `"intl-tel-input/vue"` 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.14.1/build/js/utils.js"`.
35
+ 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 IntlTelInput from `"intl-tel-input/vueWithUtils"`, to include the utils script. Alternatively, if you use the main `"intl-tel-input/vue"` 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.1/build/js/utils.js"`.
38
36
 
39
37
  ## Props
40
38
  Here's a list of all of the current props you can pass to the IntlTelInput Vue component.
@@ -45,7 +43,7 @@ Sets the disabled attribute of both the telephone input and selected country but
45
43
 
46
44
  **inputProps**
47
45
  Type: `Object`
48
- The props to pass to the input element e.g. `id`, `class`, `placeholder`, `required`, `onBlur` etc. *Note: we recommend using the separate `disabled` prop instead of `inputProps.disabled`.*
46
+ The props to pass to the input element, e.g. `id`, `class`, `placeholder`, `required`, `onBlur`. *Note: we recommend using the separate `disabled` prop instead of `inputProps.disabled`.*
49
47
 
50
48
  **options**
51
49
  Type: `Object`
@@ -60,7 +58,7 @@ Here's a list of all of the current events you can listen to on the IntlTelInput
60
58
 
61
59
  **changeCountry**
62
60
  Type: `Function`
63
- A handler to be called when the selected country changes. It will be passed the new country iso2 code e.g. "gb" for UK.
61
+ A handler to be called when the selected country changes. It will be passed the new country iso2 code, e.g. "gb" for the UK.
64
62
 
65
63
  **changeErrorCode**
66
64
  Type: `Function`
@@ -3317,7 +3317,7 @@ const Tt = (l) => {
3317
3317
  attachUtils: Tt,
3318
3318
  startedLoadingUtilsScript: !1,
3319
3319
  startedLoadingAutoCountry: !1,
3320
- version: "25.14.1"
3320
+ version: "25.15.1"
3321
3321
  }
3322
3322
  ), Ot = {
3323
3323
  __name: "IntlTelInput",
@@ -0,0 +1,34 @@
1
+ import { SomeOptions } from './modules/types/public-api';
2
+ import { InputHTMLAttributes } from 'vue';
3
+ interface Props {
4
+ options?: SomeOptions;
5
+ disabled?: boolean;
6
+ inputProps?: InputHTMLAttributes;
7
+ }
8
+ type __VLS_Props = Props;
9
+ type __VLS_PublicProps = {
10
+ modelValue?: string;
11
+ } & __VLS_Props;
12
+ declare const _default: import('vue').DefineComponent<__VLS_PublicProps, {
13
+ instance: import('vue').Ref<any, any>;
14
+ input: import('vue').Ref<any, any>;
15
+ }, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
16
+ changeNumber: (...args: any[]) => void;
17
+ changeCountry: (...args: any[]) => void;
18
+ changeValidity: (...args: any[]) => void;
19
+ changeErrorCode: (...args: any[]) => void;
20
+ "update:modelValue": (value: string) => void;
21
+ }, string, import('vue').PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
22
+ onChangeNumber?: (...args: any[]) => any;
23
+ onChangeCountry?: (...args: any[]) => any;
24
+ onChangeValidity?: (...args: any[]) => any;
25
+ onChangeErrorCode?: (...args: any[]) => any;
26
+ "onUpdate:modelValue"?: (value: string) => any;
27
+ }>, {
28
+ disabled: boolean;
29
+ options: SomeOptions;
30
+ inputProps: InputHTMLAttributes;
31
+ }, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {
32
+ input: HTMLInputElement;
33
+ }, any>;
34
+ export default _default;