| Total Complexity | 3 |
| Complexity/F | 1 |
| Lines of Code | 10 |
| Function Count | 3 |
| Duplicated Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | import '../../../scss/components/form/field.scss'; |
||
| 2 | |||
| 3 | $(function() { |
||
| 4 | // Add a space every thousand for number inputs |
||
| 5 | $('[data-type="number"]').on('input', function () { |
||
| 6 | $(this).val(function (index, value) { |
||
| 7 | return value.replace(/[^\dA-Z]/g, '').replace(/(.)(?=(.{3})+$)/g,'$1 ').trim(); |
||
| 8 | }); |
||
| 9 | }) |
||
| 10 | }); |
||
| 11 |