Alexander Shabunevich
6f4836345c
chore: update dependencies and package.json for v3
2024-04-14 12:54:18 +03:00
Alexander Shabunevich
bdcdecc301
chore: move docs demo app to root folder
2024-04-14 12:54:18 +03:00
Alexander Shabunevich
88d92b2753
fix: change event abort to manual event removing
...
Because happy-dom can't handle event abortion and test do not passing
2024-04-14 12:54:18 +03:00
Alexander Shabunevich
04bd6b249c
fix: correct binding.value check in vue directive
2024-04-14 12:54:18 +03:00
Alexander Shabunevich
9257950422
chore: rename mask-input.ts to input.ts
2024-04-14 12:09:36 +03:00
Alexander Shabunevich
2fb8e9b460
test: add BindModel component
2024-04-11 22:41:55 +03:00
Alexander Shabunevich
9b6f964d59
chore: demo app
2024-04-11 22:41:45 +03:00
Alexander Shabunevich
f01cacb046
style: code format
2024-04-11 22:13:16 +03:00
Alexander Shabunevich
500fd1d6cf
test: warning about input type
2024-04-11 21:49:14 +03:00
Alexander Shabunevich
9943a17fd1
style: code format
2024-04-11 21:37:42 +03:00
Alexander Shabunevich
e01e66a7c9
chore: rename directive.js to vue.js
2024-04-11 21:32:15 +03:00
Alexander Shabunevich
7159eb3460
chore: fix lint warnings
2024-04-11 21:30:28 +03:00
Alexander Shabunevich
7273dc73a4
feat: console warning on non-supported input type
2024-04-11 21:22:42 +03:00
Alexander Shabunevich
12ce5da3f5
chore: rename directive.test to vue.test
2024-04-09 22:29:57 +03:00
Alexander Shabunevich
f26128d19b
test: additional tests for cursor position
2024-04-09 22:29:42 +03:00
Alexander Shabunevich
9d4dfbd1bc
chore: update happy-dom to 14.6.2
2024-04-09 21:24:41 +03:00
Alexander Shabunevich
1e50a2a259
refactor: MaskInput rework
...
- abort controller for events
- refactor onInput
- remove beforeinputEvent
- new cursor position fix
2024-04-09 21:24:41 +03:00
Alexander Shabunevich
243b8445a2
test: fix tests for new eager mode
2024-04-06 12:00:02 +03:00
Alexander Shabunevich
150ee77c48
fix: rework updating value
2024-04-06 11:59:33 +03:00
Alexander Shabunevich
81a748e891
style: code format
2024-04-06 10:17:11 +03:00
Alexander Shabunevich
ce1243abcd
fix!: change eager mask behavior
...
Now eager mask take into account a hardcoded symbols
2024-04-06 10:13:31 +03:00
Alexander Shabunevich
dee8f2eaf2
test: additional check for callbacks with binding
2024-03-30 15:15:31 +03:00
Alexander Shabunevich
00f7caede8
fix: check input value on every update
...
For better handling value change without directive, like vanilla case
2024-03-30 15:08:44 +03:00
Alexander Shabunevich
816c49c466
style: code formating
2024-03-30 15:07:31 +03:00
Alexander Shabunevich
cd1e9f3564
feat!: rework for v3
...
- new directive format: pass options as value, bound as argument with modifiers
- update and checkValue methods in MaskInput
2024-03-30 12:39:22 +03:00
Alexander Shabunevich
fe2dc8a766
Merge pull request #204 from IlyaSemenov/replace_binded_bound
...
Replace "binded" with "bound"
2024-03-30 12:02:34 +03:00
Ilya Semenov
a38e8a2512
Replace "binded" with "bound"
2024-02-13 13:56:56 +07:00
Alexander Shabunevich
18191d23ef
2.1.11
2024-01-10 22:41:49 +03:00
Alexander Shabunevich
08c17dc5be
Merge pull request #199 from asselin/master
...
Fix #183 Multiple modifier breaks other custom tokens
2024-01-10 20:47:49 +03:00
Andre Asselin
222f2df70a
Fix #183 Multiple modifier breaks other custom tokens
...
When a token with multiple:true does not match the next character, we need to determine if it matched any previous characters or not.
If it hasn't matched any characters yet, then we skip the invalid input character and remain on the same token.
If it has matched 1 or more input characters, then we advance to the next token, but stay on the same input character.
The old code had several issues with this. I replaced it with a simple flag (multipleMatched) that is set to true whenever a token with multiple==true matches an input character, and can then be tested when a token with multiple==true doesn't match an input character.
2024-01-09 18:27:18 -05:00
Alexander Shabunevich
716c38e501
docs: example and known issues
...
- add example of set options with bind
- add known issues
2023-12-25 21:31:05 +03:00
Alexander Shabunevich
ffe70ecaef
2.1.10
2023-08-01 18:40:09 +03:00
Alexander Shabunevich
b0174bcf0a
Merge pull request #177 from hiddenLadder/patch-1
...
Return null if input type equals file
2023-08-01 18:36:07 +03:00
Ilya Machnev
7ad5792858
Update directive.ts
2023-08-01 10:49:55 +08:00
Ilya Machnev
c8998d6bf5
Return if input type equals file
...
Direcitve doesnt work on inputs with type set to 'file', it throws error when value changes
2023-08-01 10:45:01 +08:00
Alexander Shabunevich
d718a16509
Fixed tests
2023-07-10 23:30:42 +03:00
Alexander Shabunevich
a44f0c7e91
Changes in build script
2023-07-10 22:13:27 +03:00
Alexander Shabunevich
21155a07c2
Added notice in docs about options object
2023-07-10 22:10:59 +03:00
Alexander Shabunevich
1df3e61460
Removed package-lock.json
2023-07-10 21:48:53 +03:00
Alexander Shabunevich
5d155917db
2.1.9
2023-05-01 19:59:58 +03:00
Alexander Shabunevich
cc5eac46ec
Add types ref to package.json exports
2023-05-01 19:41:59 +03:00
Alexander Shabunevich
893e31c466
Updated vitest config reference
2023-05-01 15:09:30 +03:00
Alexander Shabunevich
3440f74e11
Updated deps
2023-05-01 15:03:56 +03:00
Alexander Shabunevich
f73c21b5fa
Revert "allow custom escape character"
...
This reverts commit e078efd695 .
2023-04-21 14:27:47 +03:00
Alexander Shabunevich
593c111acb
Add example of usage as Nuxt plugin
2023-04-21 00:47:08 +03:00
Alexander Shabunevich
a6833d32b4
Merge pull request #147 from killroyboy/master
...
allow custom escape character
2023-04-20 23:37:03 +03:00
Dan Wilson
e078efd695
allow custom escape character
2023-04-18 14:00:50 -06:00
Alexander Shabunevich
e965d15c81
2.1.8
2023-04-10 22:53:45 +03:00
Alexander Shabunevich
c12b5c3840
Code format
2023-04-10 22:26:11 +03:00
Alexander Shabunevich
e1092fcb4b
Merge pull request #144 from killroyboy/master
...
avoid re-rendering input and therefore entering infinite update loop
2023-04-10 22:24:39 +03:00