@pictogrammers/components 0.5.23 → 0.5.24

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/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@pictogrammers/components",
3
3
  "type": "module",
4
- "version": "0.5.23",
4
+ "version": "0.5.24",
5
5
  "license": "MIT",
6
6
  "author": "Austin Andrews",
7
7
  "scripts": {
@@ -8,7 +8,15 @@ import PgInputNumber from '@pictogrammers/components/pgInputText';
8
8
  ```
9
9
 
10
10
  ```html
11
- <pg-input-number value="50"></pg-input-number>
11
+ <pg-input-number part="input" value="50"></pg-input-number>
12
+ ```
13
+
14
+ ```typescript
15
+ // handle plus and minus buttons
16
+ this.$input.addEventListener('input', (e: any) => {
17
+ const { value } = e.detail;
18
+ this.$input.value = value;
19
+ });
12
20
  ```
13
21
 
14
22
  ## Attributes
@@ -17,11 +25,14 @@ import PgInputNumber from '@pictogrammers/components/pgInputText';
17
25
  | ----------- | -------- | ----------- |
18
26
  | name | | Unique name in `pg-form` |
19
27
  | value | | Field value |
28
+ | step | | Default `1` |
29
+ | min | | Default `-1 * Number.MAX_SAFE_INTEGER` |
30
+ | max | | Default `Number.MAX_SAFE_INTEGER` |
20
31
  | placeholder | | Placeholder text |
21
32
 
22
33
  ## Events
23
34
 
24
35
  | Events | Tested | Description |
25
36
  | ---------- | -------- | ----------- |
26
- | change | | `{ detail: { value }` |
27
- | input | | `{ detail: { value }` |
37
+ | change | | `{ detail: { value, name }` |
38
+ | input | | `{ detail: { value, name }` |