bootstrap-input-spinner 3.0.3 → 3.1.3

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.
package/README.md CHANGED
@@ -38,7 +38,7 @@ npm install bootstrap-input-spinner
38
38
  ```
39
39
  Bootstrap 4 compatible version
40
40
  ```bash
41
- npm install bootstrap-input-spinner@2.1.2
41
+ npm install bootstrap-input-spinner@2.2.0
42
42
  ```
43
43
 
44
44
 
package/index.html CHANGED
@@ -3,7 +3,7 @@
3
3
  <head>
4
4
  <meta charset="UTF-8">
5
5
  <title>bootstrap-input-spinner</title>
6
- <link rel="stylesheet" href="./node_modules/bootstrap/dist/css/bootstrap.min.css"/>
6
+ <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap@5.1.1/dist/css/bootstrap.min.css" integrity="sha384-F3w7mX95PdgyTmZZMECAngseQB83DfGTowi0iMjiWaeVhAn4FJkqJByhZMI3AhiU" crossorigin="anonymous">
7
7
  <link rel="stylesheet" href="./node_modules/prismjs/themes/prism-tomorrow.css"/>
8
8
  <meta name="viewport" content="width=device-width, initial-scale=1"/>
9
9
  <style type="text/css">
@@ -21,8 +21,8 @@
21
21
  max-width: 250px;
22
22
  }
23
23
  </style>
24
- <script src="./node_modules/jquery/dist/jquery.min.js"></script>
25
- <script src="./node_modules/bootstrap/dist/js/bootstrap.bundle.min.js"></script>
24
+ <script src="https://code.jquery.com/jquery-3.6.0.min.js" integrity="sha256-/xUj+3OJU5yExlq6GSYGSHk7tPXikynS7ogEvDej/m4=" crossorigin="anonymous"></script>
25
+ <script src="https://cdn.jsdelivr.net/npm/bootstrap@5.1.1/dist/js/bootstrap.bundle.min.js" integrity="sha384-/bQdsTh/da6pkI1MST/rWKFNjaCP5gBSY4sEBT38Q/9RBh9AH40zEOg7Hlq2THRZ" crossorigin="anonymous"></script>
26
26
  <script src="src/bootstrap-input-spinner.js"></script>
27
27
  <script src="src/custom-editors.js"></script>
28
28
  <script src="./node_modules/prismjs/prism.js"></script>
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "bootstrap-input-spinner",
3
- "version": "3.0.3",
3
+ "version": "3.1.3",
4
4
  "description": "A Bootstrap 5 / jQuery plugin to create input spinner elements for number input.",
5
5
  "browser": "./src/bootstrap-input-spinner.js",
6
6
  "scripts": {
@@ -25,13 +25,8 @@
25
25
  "url": "https://github.com/shaack/bootstrap-input-spinner/issues"
26
26
  },
27
27
  "homepage": "https://shaack.com/en/open-source-components",
28
- "dependencies": {
29
- "bootstrap": "^5.0.1",
30
- "jquery": "^3.6.0",
31
- "popper.js": "^1.16.1"
32
- },
33
28
  "devDependencies": {
34
- "prismjs": "^1.23.0",
29
+ "prismjs": "^1.25.0",
35
30
  "teevi": "^2.1.10"
36
31
  }
37
32
  }
@@ -194,6 +194,7 @@
194
194
  })
195
195
  onPointerUp(document.body, function () {
196
196
  resetTimer()
197
+ dispatchEvent($original, "change")
197
198
  })
198
199
  }
199
200
 
@@ -210,10 +211,8 @@
210
211
  } else {
211
212
  newValue = parseFloat(newValue)
212
213
  newValue = Math.min(Math.max(newValue, min), max)
213
- // newValue = Math.round(newValue * Math.pow(10, decimals)) / Math.pow(10, decimals)
214
214
  $original[0].value = newValue
215
215
  if (updateInput) {
216
- // $input[0].value = numberFormat.format(newValue)
217
216
  $input[0].value = $original[0].inputSpinnerEditor.render(newValue)
218
217
  }
219
218
  value = newValue
@@ -266,7 +265,6 @@
266
265
  }
267
266
  setValue(Math.round(value / step) * step + step)
268
267
  dispatchEvent($original, "input")
269
- dispatchEvent($original, "change")
270
268
  }
271
269
 
272
270
  function resetTimer() {