Skip to content

Commit

Permalink
fix initial request sometimes don't mask input
Browse files Browse the repository at this point in the history
  • Loading branch information
ariaieboy committed May 14, 2024
1 parent 65de393 commit 6c29184
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion resources/views/currency-mask.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
input:\$wire.{$applyStateBindingModifiers("\$entangle('{$statePath}')")},
masked:'',
init(){
this.masked = this.input?.toString().replaceAll('.','$decimalSeparator');
\$nextTick(()=>this.masked = this.input?.toString().replaceAll('.','$decimalSeparator'));
\$watch('masked',()=>this.updateInput());
\$watch('input',()=>this.updateMasked());
},
Expand Down

0 comments on commit 6c29184

Please sign in to comment.