use-mask-input 1.0.1 → 2.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (51) hide show
  1. package/dist/example/App.example.d.ts +3 -0
  2. package/dist/{useMaskInput.test.d.ts → example/index.d.ts} +0 -0
  3. package/dist/index.js +1 -2
  4. package/dist/index.js.map +1 -1
  5. package/dist/index.modern.js +1 -2
  6. package/dist/index.modern.js.map +1 -1
  7. package/dist/useMaskInput.d.ts +3 -3
  8. package/node_modules/inputmask/README.md +109 -79
  9. package/node_modules/inputmask/bundle.js +6 -5
  10. package/node_modules/inputmask/dist/inputmask.es6.js +5 -0
  11. package/node_modules/inputmask/dist/inputmask.js +2892 -2608
  12. package/node_modules/inputmask/dist/inputmask.min.js +3 -3
  13. package/node_modules/inputmask/dist/jquery.inputmask.js +2829 -2534
  14. package/node_modules/inputmask/dist/jquery.inputmask.min.js +3 -3
  15. package/node_modules/inputmask/lib/bindings/inputmask.es6.js +5 -0
  16. package/node_modules/inputmask/lib/canUseDOM.js +7 -0
  17. package/node_modules/inputmask/lib/defaults.js +101 -0
  18. package/node_modules/inputmask/lib/definitions.js +13 -0
  19. package/node_modules/inputmask/lib/dependencyLibs/data.js +8 -0
  20. package/node_modules/inputmask/lib/dependencyLibs/events.js +199 -0
  21. package/node_modules/inputmask/lib/dependencyLibs/extend.js +58 -0
  22. package/node_modules/inputmask/lib/dependencyLibs/inputmask.dependencyLib.jquery.js +4 -3
  23. package/node_modules/inputmask/lib/dependencyLibs/inputmask.dependencyLib.js +12 -343
  24. package/node_modules/inputmask/lib/environment.js +9 -0
  25. package/node_modules/inputmask/lib/escapeRegex.js +4 -0
  26. package/node_modules/inputmask/lib/eventhandlers.js +513 -0
  27. package/node_modules/inputmask/lib/eventruler.js +124 -0
  28. package/node_modules/inputmask/lib/extensions/inputmask.date.extensions.js +552 -385
  29. package/node_modules/inputmask/lib/extensions/inputmask.extensions.js +116 -97
  30. package/node_modules/inputmask/lib/extensions/inputmask.numeric.extensions.js +594 -565
  31. package/node_modules/inputmask/lib/global/window.js +2 -6
  32. package/node_modules/inputmask/lib/inputHandling.js +252 -0
  33. package/node_modules/inputmask/lib/inputmask.js +129 -126
  34. package/node_modules/inputmask/lib/inputmaskElement.js +26 -20
  35. package/node_modules/inputmask/lib/jquery.inputmask.js +3 -1
  36. package/node_modules/inputmask/lib/keycode.json +6 -1
  37. package/node_modules/inputmask/lib/mask-lexer.js +467 -0
  38. package/node_modules/inputmask/lib/mask.js +244 -0
  39. package/node_modules/inputmask/lib/masktoken.js +13 -0
  40. package/node_modules/inputmask/lib/polyfills/Array.includes.js +48 -0
  41. package/node_modules/inputmask/lib/polyfills/Object.getPrototypeOf.js +7 -0
  42. package/node_modules/inputmask/lib/positioning.js +348 -0
  43. package/node_modules/inputmask/lib/validation-tests.js +597 -0
  44. package/node_modules/inputmask/lib/validation.js +664 -0
  45. package/node_modules/inputmask/package.json +41 -71
  46. package/package.json +40 -43
  47. package/node_modules/inputmask/CHANGELOG.md +0 -714
  48. package/node_modules/inputmask/index.js +0 -1
  49. package/node_modules/inputmask/lib/dependencyLibs/inputmask.dependencyLib.jqlite.js +0 -170
  50. package/node_modules/inputmask/lib/maskScope.js +0 -2498
  51. package/node_modules/inputmask/lib/maskset.js +0 -466
@@ -1,70 +1,22 @@
1
1
  {
2
- "_args": [
3
- [
4
- "inputmask@5.0.3",
5
- "/Users/edu/Projetos/use-mask-input/example"
6
- ]
7
- ],
8
- "_from": "inputmask@5.0.3",
9
- "_id": "inputmask@5.0.3",
10
- "_inBundle": false,
11
- "_integrity": "sha512-v1l5IoJK6NE8TapI2g6n/y1/ksMwyVLkkaIS6VPTkdvpgEITLzDtSi7n9Jpp471hL2DdJlae9HpMnFmTpf5VXA==",
12
- "_location": "/use-mask-input/inputmask",
13
- "_phantomChildren": {},
14
- "_requested": {
15
- "type": "version",
16
- "registry": true,
17
- "raw": "inputmask@5.0.3",
18
- "name": "inputmask",
19
- "escapedName": "inputmask",
20
- "rawSpec": "5.0.3",
21
- "saveSpec": null,
22
- "fetchSpec": "5.0.3"
23
- },
24
- "_requiredBy": [
25
- "/use-mask-input"
26
- ],
27
- "_resolved": "https://registry.npmjs.org/inputmask/-/inputmask-5.0.3.tgz",
28
- "_spec": "5.0.3",
29
- "_where": "/Users/edu/Projetos/use-mask-input/example",
30
- "author": {
31
- "name": "Robin Herbots",
32
- "url": "https://github.com/RobinHerbots"
33
- },
34
- "bugs": {
35
- "url": "https://github.com/RobinHerbots/Inputmask/issues"
36
- },
2
+ "name": "inputmask",
3
+ "version": "5.0.7",
37
4
  "description": "Inputmask is a javascript library which creates an input mask. Inputmask can run against vanilla javascript, jQuery and jqlite.",
38
- "devDependencies": {
39
- "@babel/core": "^7.7.2",
40
- "@babel/plugin-transform-modules-commonjs": "^7.7.0",
41
- "@babel/preset-env": "^7.7.1",
42
- "babel-loader": "^8.0.6",
43
- "grunt": "^1.0.4",
44
- "grunt-available-tasks": "^0.6.3",
45
- "grunt-bump": "^0.8.0",
46
- "grunt-cli": "^1.3.2",
47
- "grunt-contrib-clean": "^2.0.0",
48
- "grunt-contrib-copy": "^1.0.0",
49
- "grunt-eslint": "^22.0.0",
50
- "grunt-nuget": "^0.3.1",
51
- "grunt-release": "^0.14.0",
52
- "grunt-webpack": "^3.1.3",
53
- "jqlite": "^0.2.42",
54
- "jquery": "^3.4.1",
55
- "jsdom": "^15.2.1",
56
- "load-grunt-tasks": "^5.1.0",
57
- "qunit": "^2.9.3",
58
- "uglifyjs-webpack-plugin": "^2.2.0",
59
- "webpack": "^4.41.2",
60
- "webpack-cli": "^3.3.10"
61
- },
5
+ "main": "dist/inputmask.js",
62
6
  "files": [
63
7
  "bundle.js",
64
8
  "dist/",
65
9
  "lib/"
66
10
  ],
67
- "homepage": "https://github.com/RobinHerbots/Inputmask",
11
+ "scripts": {
12
+ "start": "webpack --progress --watch --config-name main --config webpack.config.js",
13
+ "jquery": "webpack --progress --watch --config-name jquery --config webpack.config.js",
14
+ "test": "grunt validate"
15
+ },
16
+ "repository": {
17
+ "type": "git",
18
+ "url": "https://github.com/RobinHerbots/Inputmask.git"
19
+ },
68
20
  "keywords": [
69
21
  "form",
70
22
  "input",
@@ -74,17 +26,35 @@
74
26
  "mask",
75
27
  "plugins"
76
28
  ],
77
- "license": "MIT",
78
- "main": "index.js",
79
- "name": "inputmask",
80
- "repository": {
81
- "type": "git",
82
- "url": "git+https://github.com/RobinHerbots/Inputmask.git"
29
+ "author": {
30
+ "name": "Robin Herbots",
31
+ "url": "https://github.com/RobinHerbots"
83
32
  },
84
- "scripts": {
85
- "jquery": "webpack --progress --watch --config-name jquery --config webpack.config.js",
86
- "start": "webpack --progress --watch --config-name main --config webpack.config.js",
87
- "test": "grunt validate"
33
+ "license": "MIT",
34
+ "bugs": {
35
+ "url": "https://github.com/RobinHerbots/Inputmask/issues"
88
36
  },
89
- "version": "5.0.3"
37
+ "homepage": "https://github.com/RobinHerbots/Inputmask",
38
+ "devDependencies": {
39
+ "@babel/core": "^7.16.5",
40
+ "@babel/plugin-transform-modules-commonjs": "^7.16.5",
41
+ "@babel/preset-env": "^7.16.5",
42
+ "@babel/preset-typescript": "^7.16.5",
43
+ "@robinherbots/grunt-available-tasks": "^0.6.4",
44
+ "@robinherbots/grunt-nuget": "^0.3.2",
45
+ "babel-loader": "^8.2.3",
46
+ "grunt": "^1.4.1",
47
+ "grunt-bump": "^0.8.0",
48
+ "grunt-contrib-clean": "^2.0.0",
49
+ "grunt-contrib-copy": "^1.0.0",
50
+ "grunt-eslint": "^24.0.0",
51
+ "grunt-release": "^0.14.0",
52
+ "grunt-webpack": "^5.0.0",
53
+ "jquery": "^3.6.0",
54
+ "load-grunt-tasks": "^5.1.0",
55
+ "lodash": "^4.17.21",
56
+ "qunit": "^2.17.2",
57
+ "webpack": "^5.65.0",
58
+ "webpack-cli": "^4.9.1"
59
+ }
90
60
  }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "use-mask-input",
3
- "version": "1.0.1",
4
- "description": "Made with create-react-library",
3
+ "version": "2.0.0",
4
+ "description": "A react Hook for build elegant input masks. Compatible with React Hook Form",
5
5
  "author": "eduardoborges",
6
6
  "license": "MIT",
7
7
  "repository": "https://github.com/eduardoborges/use-mask-input",
@@ -13,57 +13,54 @@
13
13
  },
14
14
  "scripts": {
15
15
  "build": "microbundle-crl --no-compress --format modern,cjs",
16
- "start": "microbundle-crl watch --no-compress --format modern,cjs",
17
- "prepare": "run-s build",
18
- "test": "run-s test:unit test:lint test:build",
19
- "test:build": "run-s build",
16
+ "start": "vite",
17
+ "prepare": "npm run build",
18
+ "test": "concurrently \"test:unit test:lint test:build\"",
19
+ "test:build": "npm run build",
20
20
  "test:lint": "eslint .",
21
- "test:unit": "cross-env CI=1 react-scripts test --env=jsdom",
22
- "test:watch": "react-scripts test --env=jsdom",
23
- "predeploy": "cd example && npm install && npm run build",
24
- "deploy": "gh-pages -d example/build"
21
+ "test:unit": "",
22
+ "test:watch": "",
23
+ "predeploy": "npm install && npm run build"
25
24
  },
26
25
  "peerDependencies": {
27
- "react": "^16.0.0"
26
+ "react": "^17.x",
27
+ "react-dom": "^17.x"
28
28
  },
29
29
  "devDependencies": {
30
- "@testing-library/jest-dom": "^4.2.4",
31
- "@testing-library/react": "^9.5.0",
32
- "@testing-library/react-hooks": "^3.3.0",
33
- "@testing-library/user-event": "^7.2.1",
34
- "@types/jest": "^25.1.4",
35
- "@types/node": "^12.12.38",
36
- "@types/react": "^16.9.27",
37
- "@types/react-dom": "^16.9.7",
38
- "@typescript-eslint/eslint-plugin": "^2.26.0",
39
- "@typescript-eslint/parser": "^2.26.0",
40
- "babel-eslint": "^10.0.3",
41
- "cross-env": "^7.0.2",
42
- "eslint": "^6.8.0",
43
- "eslint-config-prettier": "^6.7.0",
44
- "eslint-config-standard": "^14.1.0",
45
- "eslint-config-standard-react": "^9.2.0",
46
- "eslint-plugin-import": "^2.18.2",
47
- "eslint-plugin-node": "^11.0.0",
48
- "eslint-plugin-prettier": "^3.1.1",
49
- "eslint-plugin-promise": "^4.2.1",
50
- "eslint-plugin-react": "^7.17.0",
51
- "eslint-plugin-standard": "^4.0.1",
52
- "gh-pages": "^2.2.0",
53
- "microbundle-crl": "^0.13.10",
54
- "npm-run-all": "^4.1.5",
55
- "prettier": "^2.0.4",
56
- "react": "^16.13.1",
57
- "react-dom": "^16.13.1",
58
- "react-scripts": "^3.4.1",
59
- "typescript": "^3.7.5",
60
- "@types/inputmask": "^4.0.1"
30
+ "@semantic-release/changelog": "6.0.1",
31
+ "@semantic-release/commit-analyzer": "9.0.2",
32
+ "@semantic-release/git": "10.0.1",
33
+ "@semantic-release/github": "8.0.5",
34
+ "@semantic-release/npm": "^9.0.1",
35
+ "@semantic-release/release-notes-generator": "10.0.3",
36
+ "@types/inputmask": "^5.0.3",
37
+ "@types/jest": "29.0.3",
38
+ "@types/node": "18",
39
+ "@types/react": "^17.x",
40
+ "@types/react-dom": "^17.x",
41
+ "@typescript-eslint/eslint-plugin": "^5.38.1",
42
+ "@typescript-eslint/parser": "^5.38.1",
43
+ "@vitejs/plugin-react": "2.1.0",
44
+ "concurrently": "^7.4.0",
45
+ "cross-env": "7.0.3",
46
+ "eslint": "^8.24.0",
47
+ "eslint-config-airbnb": "^19.0.4",
48
+ "eslint-config-airbnb-typescript": "^17.0.0",
49
+ "eslint-plugin-import": "^2.26.0",
50
+ "eslint-plugin-jsx-a11y": "^6.6.1",
51
+ "eslint-plugin-react": "^7.31.8",
52
+ "eslint-plugin-react-hooks": "^4.6.0",
53
+ "gh-pages": "4.0.0",
54
+ "microbundle-crl": "0.13.11",
55
+ "semantic-release": "19.0.3",
56
+ "typescript": "4.8.3",
57
+ "vite": "3.1.3"
61
58
  },
62
59
  "files": [
63
60
  "dist"
64
61
  ],
65
62
  "dependencies": {
66
- "inputmask": "^5.0.3"
63
+ "inputmask": "^5.0.7"
67
64
  },
68
65
  "bundleDependencies": [
69
66
  "inputmask"