fleetcor-lwc 3.13.3 → 3.13.4
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
|
@@ -946,6 +946,12 @@ You can override them as you wish by global css variables as priority.
|
|
|
946
946
|
<details>
|
|
947
947
|
<summary>Click to expand/collapse</summary>
|
|
948
948
|
|
|
949
|
+
v.3.13.4
|
|
950
|
+
|
|
951
|
+
- Bug fix `flt-input-text` component
|
|
952
|
+
|
|
953
|
+
---
|
|
954
|
+
|
|
949
955
|
v.3.13.3
|
|
950
956
|
|
|
951
957
|
- Bug fix `flt-input-phone` component
|
|
@@ -177,6 +177,23 @@ describe('flt-input-text', () => {
|
|
|
177
177
|
return Promise.resolve().then(async () => {
|
|
178
178
|
await expect(inputTextElement.value).toBeFalsy()
|
|
179
179
|
await expect(inputElement.value).toBeFalsy()
|
|
180
|
+
|
|
181
|
+
inputTextElement.disabled = false
|
|
182
|
+
inputElement.value = 'Aleks '
|
|
183
|
+
inputElement.dispatchEvent(new Event('change'))
|
|
184
|
+
|
|
185
|
+
return Promise.resolve().then(async () => {
|
|
186
|
+
await expect(inputTextElement.value).toBe('Aleks')
|
|
187
|
+
await expect(inputElement.value).toBe('Aleks')
|
|
188
|
+
|
|
189
|
+
inputElement.value = ''
|
|
190
|
+
inputElement.dispatchEvent(new Event('change'))
|
|
191
|
+
|
|
192
|
+
return Promise.resolve().then(async () => {
|
|
193
|
+
await expect(inputTextElement.value).toBe('')
|
|
194
|
+
await expect(inputElement.value).toBe('')
|
|
195
|
+
})
|
|
196
|
+
})
|
|
180
197
|
})
|
|
181
198
|
})
|
|
182
199
|
})
|
|
@@ -63,8 +63,6 @@ export default class InputText extends InputElement {
|
|
|
63
63
|
if (this.disabled) return
|
|
64
64
|
this.focused = false
|
|
65
65
|
this.touched = true
|
|
66
|
-
this.value = (event.target.value || '').trim()
|
|
67
|
-
event.target.value = this.value
|
|
68
66
|
this.dispatchEvent(
|
|
69
67
|
new CustomEvent('blur', {
|
|
70
68
|
detail: null,
|
|
@@ -83,7 +81,7 @@ export default class InputText extends InputElement {
|
|
|
83
81
|
this.value = event.target.value
|
|
84
82
|
this.dispatchEvent(
|
|
85
83
|
new CustomEvent('change', {
|
|
86
|
-
detail: this.getData()
|
|
84
|
+
detail: { ...this.getData(), _oninput: true }
|
|
87
85
|
})
|
|
88
86
|
)
|
|
89
87
|
}
|
|
@@ -92,7 +90,17 @@ export default class InputText extends InputElement {
|
|
|
92
90
|
handleChange(event) {
|
|
93
91
|
if (this.disabled) {
|
|
94
92
|
event.target.value = ''
|
|
93
|
+
} else {
|
|
94
|
+
this.value = (event.target.value || '').trim()
|
|
95
|
+
event.target.value = this.value
|
|
96
|
+
|
|
97
|
+
this.dispatchEvent(
|
|
98
|
+
new CustomEvent('change', {
|
|
99
|
+
detail: { ...this.getData(), _onchage: true }
|
|
100
|
+
})
|
|
101
|
+
)
|
|
95
102
|
}
|
|
103
|
+
|
|
96
104
|
event.stopPropagation()
|
|
97
105
|
event.preventDefault()
|
|
98
106
|
}
|
package/package.json
CHANGED