input-duration 2.2.1 → 2.2.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
@@ -208,7 +208,7 @@ Without packaging:
208
208
 
209
209
  <script type="module">
210
210
 
211
- import chronlyhms from 'https://cdn.jsdelivr.net/npm/input-duration/+esm'
211
+ import id from 'https://cdn.jsdelivr.net/npm/input-duration/+esm'
212
212
 
213
213
  </script>
214
214
 
@@ -266,7 +266,7 @@ _For more documentation, please refer to the jscocs on [input-duration Docs](ht
266
266
  - [ ] Spanish
267
267
  - [ ] min and max values (sorry for the moment you'll have to do those yourself in js)
268
268
 
269
- See the [open issues](https://github.com/StephanLuis/chronlyhms/issues) for a full list of proposed features (and known issues).
269
+ See the [open issues](https://github.com/StephanLuis/input-duration/issues) for a full list of proposed features (and known issues).
270
270
 
271
271
  <p align="right">(<a href="#top">back to top</a>)</p>
272
272
 
@@ -280,7 +280,7 @@ See the [open issues](https://github.com/StephanLuis/chronlyhms/issues) for a fu
280
280
  ![TestStatusDIY](https://img.shields.io/static/v1?label=osX:Safari&message=Pass&color=<COLOR>&style=for-the-badge)
281
281
  ![TestStatusDIY](https://img.shields.io/static/v1?label=osX:Chrome&message=Pass&color=<COLOR>&style=for-the-badge)
282
282
 
283
- [Tests & Live Status](https://github.com/StephanLuis/BrowserStackSelenium/blob/main/chronlyHMStests/README.md)
283
+ [Tests & Live Status](https://github.com/StephanLuis/BrowserStackSelenium/blob/main/input-duration/README.md)
284
284
 
285
285
 
286
286
  <!-- CONTRIBUTING -->
@@ -304,7 +304,7 @@ Don't forget to give the project a star! Thanks again!
304
304
  <!-- LICENSE -->
305
305
  ## License
306
306
 
307
- Distributed under the MIT License. See [`LICENSE.txt`](https://github.com/StephanLuis/chronlyhms/blob/main/LICENSE) for more information.
307
+ Distributed under the MIT License. See [`LICENSE.txt`](https://github.com/StephanLuis/input-duration/blob/main/LICENSE) for more information.
308
308
 
309
309
  <p align="right">(<a href="#top">back to top</a>)</p>
310
310
 
@@ -315,7 +315,7 @@ Distributed under the MIT License. See [`LICENSE.txt`](https://github.com/Stepha
315
315
 
316
316
  Stephan Luis - stephan@learnsense.org
317
317
 
318
- Project Link: [https://github.com/StephanLuis/chronlyhms](https://github.com/StephanLuis/chronlyhms)
318
+ Project Link: [https://github.com/StephanLuis/input-duration](https://github.com/StephanLuis/input-duration)
319
319
 
320
320
  <p align="right">(<a href="#top">back to top</a>)</p>
321
321
 
@@ -342,20 +342,20 @@ Resources I've found helpful and would like to give credit to:
342
342
  <!-- https://www.markdownguide.org/basic-syntax/#reference-style-links -->
343
343
 
344
344
 
345
- [contributors-shield]: https://img.shields.io/github/contributors/StephanLuis/chronlyhms?style=for-the-badge
346
- [contributors-url]: https://github.com/StephanLuis/chronlyhms/graphs/contributors
347
- [forks-shield]: https://img.shields.io/github/forks/StephanLuis/chronlyhms?style=for-the-badge
348
- [forks-url]: https://github.com/StephanLuis/chronlyhms/network/members
349
- [stars-shield]: https://img.shields.io/github/stars/StephanLuis/chronlyhms?style=for-the-badge
350
- [stars-url]: https://github.com/StephanLuis/chronlyhms/stargazers
351
- [issues-shield]: https://img.shields.io/github/issues/StephanLuis/chronlyhms?style=for-the-badge
352
- [issues-url]: https://github.com/StephanLuis/chronlyhms/issues
353
- [license-shield]: https://img.shields.io/github/license/StephanLuis/chronlyhms?style=for-the-badge
354
- [license-url]: https://github.com/StephanLuis/chronlyhms/blob/main/LICENSE
355
- [reposize-shield]: https://img.shields.io/github/repo-size/stephanluis/chronlyhms?style=for-the-badge
356
- [reposize-url]: https://github.com/StephanLuis/chronlyhms
345
+ [contributors-shield]: https://img.shields.io/github/contributors/StephanLuis/input-duration?style=for-the-badge
346
+ [contributors-url]: https://github.com/StephanLuis/input-duration/graphs/contributors
347
+ [forks-shield]: https://img.shields.io/github/forks/StephanLuis/input-duration?style=for-the-badge
348
+ [forks-url]: https://github.com/StephanLuis/input-duration/network/members
349
+ [stars-shield]: https://img.shields.io/github/stars/StephanLuis/input-duration?style=for-the-badge
350
+ [stars-url]: https://github.com/StephanLuis/input-duration/stargazers
351
+ [issues-shield]: https://img.shields.io/github/issues/StephanLuis/input-duration?style=for-the-badge
352
+ [issues-url]: https://github.com/StephanLuis/input-duration/issues
353
+ [license-shield]: https://img.shields.io/github/license/StephanLuis/input-duration?style=for-the-badge
354
+ [license-url]: https://github.com/StephanLuis/input-duration/blob/main/LICENSE
355
+ [reposize-shield]: https://img.shields.io/github/repo-size/stephanluis/input-duration?style=for-the-badge
356
+ [reposize-url]: https://github.com/StephanLuis/input-duration
357
357
  [product-screenshot]: images/screenshot.png
358
- [npm-bundle-size]: https://img.shields.io/bundlephobia/minzip/chronlyhms?style=for-the-badge
358
+ [npm-bundle-size]: https://img.shields.io/bundlephobia/minzip/input-duration?style=for-the-badge
359
359
  [teststatus-shield]: https://img.shields.io/badge/dynamic/json?url=https://app.saucelabs.com/u/stephanluis&label=Sauce%20Labs%20Status&color=brightgreen&style=for-the-badge&query=passing
360
360
 
361
361
 
@@ -93,7 +93,7 @@
93
93
 
94
94
  <dt class="tag-source">Source:</dt>
95
95
  <dd class="tag-source"><ul class="dummy"><li>
96
- <a href="index.js.html">index.js</a>, <a href="index.js.html#line12">line 12</a>
96
+ <a href="index.js.html">index.js</a>, <a href="index.js.html#line14">line 14</a>
97
97
  </li></ul></dd>
98
98
 
99
99
 
@@ -199,7 +199,7 @@ so in js use var x = document.querySelector("#bobPrepop").value;
199
199
 
200
200
  <dt class="tag-source">Source:</dt>
201
201
  <dd class="tag-source"><ul class="dummy"><li>
202
- <a href="index.js.html">index.js</a>, <a href="index.js.html#line41">line 41</a>
202
+ <a href="index.js.html">index.js</a>, <a href="index.js.html#line43">line 43</a>
203
203
  </li></ul></dd>
204
204
 
205
205
 
@@ -262,7 +262,7 @@ so in js use document.querySelector("#bobPrepop").value = "05:05:05.005"
262
262
 
263
263
  <dt class="tag-source">Source:</dt>
264
264
  <dd class="tag-source"><ul class="dummy"><li>
265
- <a href="index.js.html">index.js</a>, <a href="index.js.html#line68">line 68</a>
265
+ <a href="index.js.html">index.js</a>, <a href="index.js.html#line70">line 70</a>
266
266
  </li></ul></dd>
267
267
 
268
268
 
@@ -343,7 +343,7 @@ the change event of the input
343
343
 
344
344
  <dt class="tag-source">Source:</dt>
345
345
  <dd class="tag-source"><ul class="dummy"><li>
346
- <a href="index.js.html">index.js</a>, <a href="index.js.html#line520">line 520</a>
346
+ <a href="index.js.html">index.js</a>, <a href="index.js.html#line523">line 523</a>
347
347
  </li></ul></dd>
348
348
 
349
349
 
@@ -439,7 +439,7 @@ the change event of the input
439
439
 
440
440
  <dt class="tag-source">Source:</dt>
441
441
  <dd class="tag-source"><ul class="dummy"><li>
442
- <a href="index.js.html">index.js</a>, <a href="index.js.html#line155">line 155</a>
442
+ <a href="index.js.html">index.js</a>, <a href="index.js.html#line158">line 158</a>
443
443
  </li></ul></dd>
444
444
 
445
445
 
@@ -535,7 +535,7 @@ the click event of the input
535
535
 
536
536
  <dt class="tag-source">Source:</dt>
537
537
  <dd class="tag-source"><ul class="dummy"><li>
538
- <a href="index.js.html">index.js</a>, <a href="index.js.html#line548">line 548</a>
538
+ <a href="index.js.html">index.js</a>, <a href="index.js.html#line551">line 551</a>
539
539
  </li></ul></dd>
540
540
 
541
541
 
@@ -630,7 +630,7 @@ the click event of the input
630
630
 
631
631
  <dt class="tag-source">Source:</dt>
632
632
  <dd class="tag-source"><ul class="dummy"><li>
633
- <a href="index.js.html">index.js</a>, <a href="index.js.html#line226">line 226</a>
633
+ <a href="index.js.html">index.js</a>, <a href="index.js.html#line229">line 229</a>
634
634
  </li></ul></dd>
635
635
 
636
636
 
@@ -726,7 +726,7 @@ the change event of the input
726
726
 
727
727
  <dt class="tag-source">Source:</dt>
728
728
  <dd class="tag-source"><ul class="dummy"><li>
729
- <a href="index.js.html">index.js</a>, <a href="index.js.html#line343">line 343</a>
729
+ <a href="index.js.html">index.js</a>, <a href="index.js.html#line346">line 346</a>
730
730
  </li></ul></dd>
731
731
 
732
732
 
@@ -821,7 +821,7 @@ the change event of the input
821
821
 
822
822
  <dt class="tag-source">Source:</dt>
823
823
  <dd class="tag-source"><ul class="dummy"><li>
824
- <a href="index.js.html">index.js</a>, <a href="index.js.html#line409">line 409</a>
824
+ <a href="index.js.html">index.js</a>, <a href="index.js.html#line412">line 412</a>
825
825
  </li></ul></dd>
826
826
 
827
827
 
@@ -916,7 +916,7 @@ the change event of the input
916
916
 
917
917
  <dt class="tag-source">Source:</dt>
918
918
  <dd class="tag-source"><ul class="dummy"><li>
919
- <a href="index.js.html">index.js</a>, <a href="index.js.html#line133">line 133</a>
919
+ <a href="index.js.html">index.js</a>, <a href="index.js.html#line135">line 135</a>
920
920
  </li></ul></dd>
921
921
 
922
922
 
@@ -1004,7 +1004,7 @@ the change event of the input
1004
1004
 
1005
1005
  <dt class="tag-source">Source:</dt>
1006
1006
  <dd class="tag-source"><ul class="dummy"><li>
1007
- <a href="index.js.html">index.js</a>, <a href="index.js.html#line585">line 585</a>
1007
+ <a href="index.js.html">index.js</a>, <a href="index.js.html#line602">line 602</a>
1008
1008
  </li></ul></dd>
1009
1009
 
1010
1010
 
@@ -1092,7 +1092,7 @@ the change event of the input
1092
1092
 
1093
1093
  <dt class="tag-source">Source:</dt>
1094
1094
  <dd class="tag-source"><ul class="dummy"><li>
1095
- <a href="index.js.html">index.js</a>, <a href="index.js.html#line601">line 601</a>
1095
+ <a href="index.js.html">index.js</a>, <a href="index.js.html#line618">line 618</a>
1096
1096
  </li></ul></dd>
1097
1097
 
1098
1098
 
@@ -1181,7 +1181,7 @@ the keypress event of the input
1181
1181
 
1182
1182
  <dt class="tag-source">Source:</dt>
1183
1183
  <dd class="tag-source"><ul class="dummy"><li>
1184
- <a href="index.js.html">index.js</a>, <a href="index.js.html#line561">line 561</a>
1184
+ <a href="index.js.html">index.js</a>, <a href="index.js.html#line564">line 564</a>
1185
1185
  </li></ul></dd>
1186
1186
 
1187
1187
 
@@ -1218,6 +1218,95 @@ the keypress event of the input
1218
1218
 
1219
1219
 
1220
1220
 
1221
+
1222
+
1223
+
1224
+
1225
+
1226
+
1227
+ <h4 class="name" id="removeEprop"><span class="type-signature"></span>removeEprop<span class="signature">()</span><span class="type-signature"></span></h4>
1228
+
1229
+
1230
+
1231
+
1232
+
1233
+
1234
+ <div class="description">
1235
+ Stop event propigation from the timeCase up through the DOM so when keys
1236
+ are being used they don't affect other controls (like volume on plyr)
1237
+ </div>
1238
+
1239
+
1240
+
1241
+
1242
+
1243
+
1244
+
1245
+
1246
+
1247
+
1248
+
1249
+
1250
+
1251
+ <dl class="details">
1252
+
1253
+
1254
+
1255
+
1256
+
1257
+
1258
+
1259
+
1260
+
1261
+
1262
+
1263
+
1264
+
1265
+
1266
+
1267
+
1268
+
1269
+
1270
+
1271
+
1272
+
1273
+
1274
+
1275
+
1276
+
1277
+
1278
+ <dt class="tag-source">Source:</dt>
1279
+ <dd class="tag-source"><ul class="dummy"><li>
1280
+ <a href="index.js.html">index.js</a>, <a href="index.js.html#line586">line 586</a>
1281
+ </li></ul></dd>
1282
+
1283
+
1284
+
1285
+
1286
+
1287
+
1288
+
1289
+ </dl>
1290
+
1291
+
1292
+
1293
+
1294
+
1295
+
1296
+
1297
+
1298
+
1299
+
1300
+
1301
+
1302
+
1303
+
1304
+
1305
+
1306
+
1307
+
1308
+
1309
+
1221
1310
 
1222
1311
 
1223
1312
 
@@ -1240,7 +1329,7 @@ the keypress event of the input
1240
1329
  <br class="clear">
1241
1330
 
1242
1331
  <footer>
1243
- Documentation generated by <a href="https://github.com/jsdoc/jsdoc">JSDoc 4.0.2</a> on Thu Jul 06 2023 16:38:37 GMT+0000 (GMT)
1332
+ Documentation generated by <a href="https://github.com/jsdoc/jsdoc">JSDoc 4.0.2</a> on Fri Sep 29 2023 11:02:59 GMT+0000 (GMT)
1244
1333
  </footer>
1245
1334
 
1246
1335
  <script> prettyPrint(); </script>
package/docs/index.html CHANGED
@@ -168,7 +168,7 @@
168
168
  <br class="clear">
169
169
 
170
170
  <footer>
171
- Documentation generated by <a href="https://github.com/jsdoc/jsdoc">JSDoc 4.0.2</a> on Thu Jul 06 2023 16:38:37 GMT+0000 (GMT)
171
+ Documentation generated by <a href="https://github.com/jsdoc/jsdoc">JSDoc 4.0.2</a> on Fri Sep 29 2023 11:02:59 GMT+0000 (GMT)
172
172
  </footer>
173
173
 
174
174
  <script> prettyPrint(); </script>
@@ -27,6 +27,8 @@
27
27
  <section>
28
28
  <article>
29
29
  <pre class="prettyprint source linenums"><code>/**
30
+ * This is jsdoc 'auto' documentation see https://jsdoc.app/
31
+ *
30
32
  * @fileoverview INPUT-DURATION
31
33
  * @file INPUT-DURATION
32
34
  * @author Stephan Luis
@@ -169,6 +171,7 @@ class InputDuration extends HTMLElement {
169
171
  this.addNumericInput();
170
172
  this.addClicksToActivate();
171
173
  this.nonNumericBugInHTML();
174
+ this.removeEprop();
172
175
 
173
176
  }
174
177
 
@@ -260,7 +263,7 @@ class InputDuration extends HTMLElement {
260
263
  var template = document.createElement('template');
261
264
 
262
265
  template.innerHTML = `
263
- &lt;input id="inShadow" type="number" class="sH D2 ts_digit" name="startHours" data-tp="1" min="-1" max="100" value="00" >
266
+ &lt;input type="number" class="sH D2 ts_digit" name="startHours" data-tp="1" min="-1" max="100" value="00" >
264
267
  &lt;span class="bds-h">:&lt;/span>
265
268
  &lt;input type="number" class="sM D2 ts_digit" name="startMinutes" data-tp="2" min="-1" max="60" value="00">
266
269
  &lt;span class="bds-m">:&lt;/span>
@@ -602,7 +605,21 @@ class InputDuration extends HTMLElement {
602
605
  }));
603
606
  }
604
607
 
608
+ /**
609
+ * Stop event propigation from the timeCase up through the DOM so when keys
610
+ * are being used they don't affect other controls (like volume on plyr)
611
+ * @method
612
+ */
613
+
614
+ removeEprop() {
615
+
616
+ document.querySelector('input-duration').shadowRoot.querySelector('.timeCase')
617
+ .addEventListener('keydown', function (event) { event.stopPropagation();});
605
618
 
619
+ }
620
+
621
+
622
+
606
623
  // formatting and behaviour options
607
624
 
608
625
  /**
@@ -662,7 +679,7 @@ export default customElements.define('input-duration', InputDuration);
662
679
  <br class="clear">
663
680
 
664
681
  <footer>
665
- Documentation generated by <a href="https://github.com/jsdoc/jsdoc">JSDoc 4.0.2</a> on Thu Jul 06 2023 16:38:37 GMT+0000 (GMT)
682
+ Documentation generated by <a href="https://github.com/jsdoc/jsdoc">JSDoc 4.0.2</a> on Fri Sep 29 2023 11:02:59 GMT+0000 (GMT)
666
683
  </footer>
667
684
 
668
685
  <script> prettyPrint(); </script>
package/index.js CHANGED
@@ -1,4 +1,9 @@
1
1
  /**
2
+ * This is jsdoc 'auto' documentation see https://jsdoc.app/
3
+ * npm install -g jsdoc
4
+ * jsdoc index.js -d ./docs/
5
+ *
6
+ *
2
7
  * @fileoverview INPUT-DURATION
3
8
  * @file INPUT-DURATION
4
9
  * @author Stephan Luis
@@ -233,7 +238,7 @@ class InputDuration extends HTMLElement {
233
238
  var template = document.createElement('template');
234
239
 
235
240
  template.innerHTML = `
236
- <input id="inShadow" type="number" class="sH D2 ts_digit" name="startHours" data-tp="1" min="-1" max="100" value="00" >
241
+ <input type="number" class="sH D2 ts_digit" name="startHours" data-tp="1" min="-1" max="100" value="00" >
237
242
  <span class="bds-h">:</span>
238
243
  <input type="number" class="sM D2 ts_digit" name="startMinutes" data-tp="2" min="-1" max="60" value="00">
239
244
  <span class="bds-m">:</span>
@@ -583,8 +588,8 @@ class InputDuration extends HTMLElement {
583
588
 
584
589
  removeEprop() {
585
590
 
586
- document.querySelector('input-duration').shadowRoot.querySelector('.timeCase')
587
- .addEventListener('keydown', function (event) { event.stopPropagation();});
591
+ document.querySelectorAll('input-duration').forEach(x => x.shadowRoot.querySelector('.timeCase')
592
+ .addEventListener('keydown', function (event) { event.stopPropagation();}));
588
593
 
589
594
  }
590
595
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "input-duration",
3
- "version": "2.2.1",
3
+ "version": "2.2.3",
4
4
  "author": "Stephan Luis <stephan@learnsense.org>",
5
5
  "description": "This is the 'Input-Duration'! It is a webcomponent that provides an hour, minute, second, and millisecond control for HTML5.",
6
6
  "browser": "indexjs",