| 353 | */ |
| 354 | @Watch('value') |
| 355 | protected valueChanged() { |
| 356 | const nativeInput = this.nativeInput; |
| 357 | const value = this.getValue(); |
| 358 | if (nativeInput && nativeInput.value !== value && !this.isComposing) { |
| 359 | /** |
| 360 | * Assigning the native input's value on attribute |
| 361 | * value change, allows `ionInput` implementations |
| 362 | * to override the control's value. |
| 363 | * |
| 364 | * Used for patterns such as input trimming (removing whitespace), |
| 365 | * or input masking. |
| 366 | */ |
| 367 | nativeInput.value = value; |
| 368 | } |
| 369 | } |
| 370 | |
| 371 | /** |
| 372 | * dir is a globally enumerated attribute. |