File tree 2 files changed +13
-2
lines changed 2 files changed +13
-2
lines changed Original file line number Diff line number Diff line change 2
2
3
3
All notable changes to ` laravel-tel-input ` will be documented in this file
4
4
5
+ ## v1.1.6 - 2021-11-12
6
+
7
+ - Added default value for ` id ` props.
8
+
5
9
## v1.1.5 - 2021-09-28
6
10
7
11
- Fix tel-input not rendering in Livewire after component update, refresh or change in DOM content.
8
- -
12
+
9
13
## v1.1.4 - 2021-09-27
10
14
11
15
- Fix utilsScript relative path bug
Original file line number Diff line number Diff line change @@ -14,10 +14,17 @@ class LaravelTelInput extends Component
14
14
*
15
15
* @return void
16
16
*/
17
- public function __construct (string $ id , string $ name = 'phone ' )
17
+ public function __construct (string $ id = null , string $ name = 'phone ' )
18
18
{
19
19
$ this ->id = $ id ;
20
20
$ this ->name = $ name ;
21
+
22
+ if (!$ this ->name ) {
23
+ $ this ->name = 'phone- ' . uniqid ();
24
+ }
25
+ if (!$ this ->id ) {
26
+ $ this ->id = $ this ->name ;
27
+ }
21
28
}
22
29
23
30
/**
You can’t perform that action at this time.
0 commit comments