svelte-tel-input 3.4.0 → 3.5.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md
CHANGED
|
@@ -29,6 +29,7 @@ export let country;
|
|
|
29
29
|
export let detailedValue = null;
|
|
30
30
|
export let valid = true;
|
|
31
31
|
export let options = defaultOptions;
|
|
32
|
+
export let el = void 0;
|
|
32
33
|
let inputValue = value;
|
|
33
34
|
let prevCountry = country;
|
|
34
35
|
const combinedOptions = {
|
|
@@ -137,6 +138,8 @@ onMount(() => {
|
|
|
137
138
|
</script>
|
|
138
139
|
|
|
139
140
|
<input
|
|
141
|
+
{...$$restProps}
|
|
142
|
+
bind:this={el}
|
|
140
143
|
{autocomplete}
|
|
141
144
|
class={classes}
|
|
142
145
|
{disabled}
|
|
@@ -2,21 +2,23 @@ import { SvelteComponentTyped } from "svelte";
|
|
|
2
2
|
import type { DetailedValue, CountryCode, E164Number, TelInputOptions } from '../../types';
|
|
3
3
|
declare const __propDef: {
|
|
4
4
|
props: {
|
|
5
|
+
[x: string]: any;
|
|
5
6
|
autocomplete?: string | null;
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
7
|
+
class?: string;
|
|
8
|
+
disabled?: boolean;
|
|
9
|
+
id?: string;
|
|
10
|
+
name?: string | null;
|
|
11
|
+
placeholder?: string | null;
|
|
12
|
+
readonly?: boolean | null;
|
|
13
|
+
required?: boolean | null;
|
|
14
|
+
size?: number | null;
|
|
15
|
+
value: E164Number | null;
|
|
16
|
+
country: CountryCode | null;
|
|
17
|
+
detailedValue?: Partial<DetailedValue> | null;
|
|
18
|
+
valid?: boolean;
|
|
19
|
+
options?: TelInputOptions;
|
|
20
|
+
el?: HTMLInputElement | undefined;
|
|
21
|
+
updateValue?: (newValue: string | E164Number | null, newCountry?: CountryCode | null) => void;
|
|
20
22
|
};
|
|
21
23
|
events: {
|
|
22
24
|
beforeinput: InputEvent;
|
|
@@ -43,6 +45,6 @@ export type TelInputProps = typeof __propDef.props;
|
|
|
43
45
|
export type TelInputEvents = typeof __propDef.events;
|
|
44
46
|
export type TelInputSlots = typeof __propDef.slots;
|
|
45
47
|
export default class TelInput extends SvelteComponentTyped<TelInputProps, TelInputEvents, TelInputSlots> {
|
|
46
|
-
get updateValue(): (newValue: string | E164Number | null, newCountry
|
|
48
|
+
get updateValue(): (newValue: string | E164Number | null, newCountry?: CountryCode | null) => void;
|
|
47
49
|
}
|
|
48
50
|
export {};
|