fleetcor-lwc 3.8.5 → 3.8.6
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
|
@@ -501,11 +501,12 @@ This component fully extends from `Input Text`
|
|
|
501
501
|
|
|
502
502
|
#### Input Phone methods
|
|
503
503
|
|
|
504
|
-
| @api | params
|
|
505
|
-
| -------- |
|
|
506
|
-
| validate |
|
|
507
|
-
| isValid |
|
|
508
|
-
| getData | silent:bool
|
|
504
|
+
| @api | params | return type | description |
|
|
505
|
+
| -------- | ------------------ | ----------- | ----------------------------------------------------------------------------------------------------------------------- |
|
|
506
|
+
| validate | | void | Check component validation and show error message to user |
|
|
507
|
+
| isValid | | bool | Return `true` or `false` |
|
|
508
|
+
| getData | silent:bool | object | Return full data of component's state. If `silent` true - return value will be without any errors displaying for client |
|
|
509
|
+
| setCode | countryCode:string | void | Change country code |
|
|
509
510
|
|
|
510
511
|
#### Input Phone events
|
|
511
512
|
|
|
@@ -665,6 +666,10 @@ You can override them as you wish by global css variables as priority.
|
|
|
665
666
|
|
|
666
667
|
## Release Notes:
|
|
667
668
|
|
|
669
|
+
- v.3.8.6
|
|
670
|
+
|
|
671
|
+
- Bug fix visiability of `flt-input-phone`
|
|
672
|
+
|
|
668
673
|
- v.3.8.5
|
|
669
674
|
|
|
670
675
|
- Bug fix visiability of `flt-input-phone`
|
|
@@ -79,6 +79,25 @@ export default class InputPhone extends UserDataValidator {
|
|
|
79
79
|
}
|
|
80
80
|
|
|
81
81
|
phoneNumber = ''
|
|
82
|
+
|
|
83
|
+
@api setCode(countryCode) {
|
|
84
|
+
const restore = !this.touched
|
|
85
|
+
this.codeValue = COUNTRIES.find((c) => c.code === countryCode)?.dialCode || this.codeValue
|
|
86
|
+
if (countryCode == CODE_BY_DEFAULT) {
|
|
87
|
+
this.mask.updateOptions({
|
|
88
|
+
mask: '#000000000',
|
|
89
|
+
definitions: {
|
|
90
|
+
'#': /[1-9]/
|
|
91
|
+
},
|
|
92
|
+
overwrite: false,
|
|
93
|
+
lazy: false
|
|
94
|
+
})
|
|
95
|
+
}
|
|
96
|
+
if (restore) {
|
|
97
|
+
this.touched = false
|
|
98
|
+
}
|
|
99
|
+
}
|
|
100
|
+
|
|
82
101
|
codeValue = ''
|
|
83
102
|
touched
|
|
84
103
|
focused
|
package/package.json
CHANGED