mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-01-03 16:51:40 +09:00
Add script to support <input type="text" inputmode="numeric">
This commit is contained in:
parent
d7fb2422fe
commit
0ea9778682
2 changed files with 8 additions and 0 deletions
7
modules/extravar/skins/default/assets/number.js
Normal file
7
modules/extravar/skins/default/assets/number.js
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
'use strict';
|
||||
|
||||
$(function() {
|
||||
$('input.rx_ev_number').on('input', function() {
|
||||
this.value = this.value.replace(/[^0-9]/g, '');
|
||||
});
|
||||
});
|
||||
|
|
@ -17,6 +17,7 @@
|
|||
@readonly(toBool($definition->is_readonly))
|
||||
/>
|
||||
@elseif ($type === 'number')
|
||||
@load('../assets/number.js')
|
||||
<input type="text" inputmode="numeric" name="{{ $input_name }}"
|
||||
id="{{ $input_id }}"|if="$input_id" class="number rx_ev_number"
|
||||
style="{{ $definition->style }}"|if="$definition->style"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue