@kubex/zinc 1.0.110 → 1.0.112

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.
@@ -59,6 +59,79 @@
59
59
  }
60
60
  ]
61
61
  },
62
+ {
63
+ "kind": "javascript-module",
64
+ "path": "components/action-bar/action-bar.js",
65
+ "declarations": [
66
+ {
67
+ "kind": "class",
68
+ "description": "",
69
+ "name": "ZnActionBar",
70
+ "cssProperties": [
71
+ {
72
+ "description": "An example CSS custom property.",
73
+ "name": "--example"
74
+ }
75
+ ],
76
+ "cssParts": [
77
+ {
78
+ "description": "The component's base wrapper.",
79
+ "name": "base"
80
+ }
81
+ ],
82
+ "slots": [
83
+ {
84
+ "description": "The default slot.",
85
+ "name": ""
86
+ },
87
+ {
88
+ "description": "An example slot.",
89
+ "name": "example"
90
+ }
91
+ ],
92
+ "members": [
93
+ {
94
+ "kind": "field",
95
+ "name": "localize",
96
+ "privacy": "private",
97
+ "readonly": true,
98
+ "default": "new LocalizeController(this)"
99
+ }
100
+ ],
101
+ "events": [
102
+ {
103
+ "description": "Emitted as an example.",
104
+ "name": "zn-event-name"
105
+ }
106
+ ],
107
+ "superclass": {
108
+ "name": "ZincElement",
109
+ "module": "/src/internal/zinc-element"
110
+ },
111
+ "summary": "Short summary of the component's intended use.",
112
+ "tagNameWithoutPrefix": "action-bar",
113
+ "tagName": "zn-action-bar",
114
+ "customElement": true,
115
+ "jsDoc": "/**\n * @summary Short summary of the component's intended use.\n * @documentation https://zinc.style/components/action-bar\n * @status experimental\n * @since 1.0\n *\n * @dependency zn-example\n *\n * @event zn-event-name - Emitted as an example.\n *\n * @slot - The default slot.\n * @slot example - An example slot.\n *\n * @csspart base - The component's base wrapper.\n *\n * @cssproperty --example - An example CSS custom property.\n */",
116
+ "documentation": "https://zinc.style/components/action-bar",
117
+ "status": "experimental",
118
+ "since": "1.0",
119
+ "dependencies": [
120
+ "zn-example"
121
+ ]
122
+ }
123
+ ],
124
+ "exports": [
125
+ {
126
+ "kind": "js",
127
+ "name": "default",
128
+ "declaration": {
129
+ "name": "ZnActionBar",
130
+ "module": "components/action-bar/action-bar.js"
131
+ }
132
+ }
133
+ ]
134
+ },
62
135
  {
63
136
  "kind": "javascript-module",
64
137
  "path": "components/alert/alert.js",
@@ -217,79 +290,6 @@
217
290
  }
218
291
  ]
219
292
  },
220
- {
221
- "kind": "javascript-module",
222
- "path": "components/action-bar/action-bar.js",
223
- "declarations": [
224
- {
225
- "kind": "class",
226
- "description": "",
227
- "name": "ZnActionBar",
228
- "cssProperties": [
229
- {
230
- "description": "An example CSS custom property.",
231
- "name": "--example"
232
- }
233
- ],
234
- "cssParts": [
235
- {
236
- "description": "The component's base wrapper.",
237
- "name": "base"
238
- }
239
- ],
240
- "slots": [
241
- {
242
- "description": "The default slot.",
243
- "name": ""
244
- },
245
- {
246
- "description": "An example slot.",
247
- "name": "example"
248
- }
249
- ],
250
- "members": [
251
- {
252
- "kind": "field",
253
- "name": "localize",
254
- "privacy": "private",
255
- "readonly": true,
256
- "default": "new LocalizeController(this)"
257
- }
258
- ],
259
- "events": [
260
- {
261
- "description": "Emitted as an example.",
262
- "name": "zn-event-name"
263
- }
264
- ],
265
- "superclass": {
266
- "name": "ZincElement",
267
- "module": "/src/internal/zinc-element"
268
- },
269
- "summary": "Short summary of the component's intended use.",
270
- "tagNameWithoutPrefix": "action-bar",
271
- "tagName": "zn-action-bar",
272
- "customElement": true,
273
- "jsDoc": "/**\n * @summary Short summary of the component's intended use.\n * @documentation https://zinc.style/components/action-bar\n * @status experimental\n * @since 1.0\n *\n * @dependency zn-example\n *\n * @event zn-event-name - Emitted as an example.\n *\n * @slot - The default slot.\n * @slot example - An example slot.\n *\n * @csspart base - The component's base wrapper.\n *\n * @cssproperty --example - An example CSS custom property.\n */",
274
- "documentation": "https://zinc.style/components/action-bar",
275
- "status": "experimental",
276
- "since": "1.0",
277
- "dependencies": [
278
- "zn-example"
279
- ]
280
- }
281
- ],
282
- "exports": [
283
- {
284
- "kind": "js",
285
- "name": "default",
286
- "declaration": {
287
- "name": "ZnActionBar",
288
- "module": "components/action-bar/action-bar.js"
289
- }
290
- }
291
- ]
292
- },
293
293
  {
294
294
  "kind": "javascript-module",
295
295
  "path": "components/animated-button/animated-button.js",
@@ -13456,6 +13456,13 @@
13456
13456
  "readonly": true,
13457
13457
  "default": "new HasSlotController(this, 'help-text', '[default]')"
13458
13458
  },
13459
+ {
13460
+ "kind": "field",
13461
+ "name": "conditionalController",
13462
+ "privacy": "private",
13463
+ "readonly": true,
13464
+ "default": "new ConditionalController(this)"
13465
+ },
13459
13466
  {
13460
13467
  "kind": "field",
13461
13468
  "name": "value",
@@ -13490,6 +13497,15 @@
13490
13497
  },
13491
13498
  "attribute": "edit-text"
13492
13499
  },
13500
+ {
13501
+ "kind": "field",
13502
+ "name": "conditional",
13503
+ "type": {
13504
+ "text": "string"
13505
+ },
13506
+ "default": "''",
13507
+ "attribute": "conditional"
13508
+ },
13493
13509
  {
13494
13510
  "kind": "field",
13495
13511
  "name": "disabled",
@@ -13922,6 +13938,14 @@
13922
13938
  },
13923
13939
  "fieldName": "editText"
13924
13940
  },
13941
+ {
13942
+ "name": "conditional",
13943
+ "type": {
13944
+ "text": "string"
13945
+ },
13946
+ "default": "''",
13947
+ "fieldName": "conditional"
13948
+ },
13925
13949
  {
13926
13950
  "name": "disabled",
13927
13951
  "type": {
@@ -24797,6 +24821,13 @@
24797
24821
  "readonly": true,
24798
24822
  "default": "new FormControlController(this, { assumeInteractionOn: ['zn-blur', 'zn-input'] })"
24799
24823
  },
24824
+ {
24825
+ "kind": "field",
24826
+ "name": "conditionalController",
24827
+ "privacy": "private",
24828
+ "readonly": true,
24829
+ "default": "new ConditionalController(this)"
24830
+ },
24800
24831
  {
24801
24832
  "kind": "field",
24802
24833
  "name": "hasSlotController",
@@ -33234,7 +33265,7 @@
33234
33265
  "package": {
33235
33266
  "name": "@kubex/zinc",
33236
33267
  "description": "A collection of web components for building web applications based off of @shoelace-style/Shoelace",
33237
- "version": "1.0.110",
33268
+ "version": "1.0.112",
33238
33269
  "author": "",
33239
33270
  "license": "MIT"
33240
33271
  }
@@ -13,6 +13,17 @@
13
13
  }
14
14
  ]
15
15
  },
16
+ {
17
+ "name": "zn-action-bar",
18
+ "description": "Short summary of the component's intended use.\n---\n\n\n### **Events:**\n - **zn-event-name** - Emitted as an example.\n\n### **Slots:**\n - _default_ - The default slot.\n- **example** - An example slot.\n\n### **CSS Properties:**\n - **--example** - An example CSS custom property. _(default: undefined)_\n\n### **CSS Parts:**\n - **base** - The component's base wrapper.",
19
+ "attributes": [],
20
+ "references": [
21
+ {
22
+ "name": "Documentation",
23
+ "url": "https://zinc.style/components/action-bar"
24
+ }
25
+ ]
26
+ },
16
27
  {
17
28
  "name": "zn-alert",
18
29
  "description": "Short summary of the component's intended use.\n---\n\n\n### **Events:**\n - **zn-event-name** - Emitted as an example.\n\n### **Slots:**\n - _default_ - The default slot.\n- **example** - An example slot.\n\n### **CSS Properties:**\n - **--example** - An example CSS custom property. _(default: undefined)_\n\n### **CSS Parts:**\n - **base** - The component's base wrapper.",
@@ -48,17 +59,6 @@
48
59
  }
49
60
  ]
50
61
  },
51
- {
52
- "name": "zn-action-bar",
53
- "description": "Short summary of the component's intended use.\n---\n\n\n### **Events:**\n - **zn-event-name** - Emitted as an example.\n\n### **Slots:**\n - _default_ - The default slot.\n- **example** - An example slot.\n\n### **CSS Properties:**\n - **--example** - An example CSS custom property. _(default: undefined)_\n\n### **CSS Parts:**\n - **base** - The component's base wrapper.",
54
- "attributes": [],
55
- "references": [
56
- {
57
- "name": "Documentation",
58
- "url": "https://zinc.style/components/action-bar"
59
- }
60
- ]
61
- },
62
62
  {
63
63
  "name": "zn-animated-button",
64
64
  "description": "\n---\n\n\n### **Methods:**\n - **purchase(): _void_** - Programmatically trigger the purchase flow\n- **setSuccess(): _void_** - Set the button to success state manually\n- **setFailure(message): _void_** - Set the button to failure state manually with optional error message\n- **reset(): _void_** - Reset the button to idle state",
@@ -1537,6 +1537,7 @@
1537
1537
  { "name": "name", "values": [] },
1538
1538
  { "name": "placeholder", "values": [] },
1539
1539
  { "name": "edit-text", "values": [] },
1540
+ { "name": "conditional", "values": [] },
1540
1541
  { "name": "disabled", "values": [] },
1541
1542
  { "name": "inline", "values": [] },
1542
1543
  { "name": "padded", "values": [] },
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "$schema": "https://raw.githubusercontent.com/JetBrains/web-types/master/schema/web-types.json",
3
3
  "name": "@kubex/zinc",
4
- "version": "1.0.110",
4
+ "version": "1.0.112",
5
5
  "description-markup": "markdown",
6
6
  "contributions": {
7
7
  "html": {
@@ -15,6 +15,28 @@
15
15
  "events": [],
16
16
  "js": { "properties": [], "events": [] }
17
17
  },
18
+ {
19
+ "name": "zn-action-bar",
20
+ "description": "Short summary of the component's intended use.\n---\n\n\n### **Events:**\n - **zn-event-name** - Emitted as an example.\n\n### **Slots:**\n - _default_ - The default slot.\n- **example** - An example slot.\n\n### **CSS Properties:**\n - **--example** - An example CSS custom property. _(default: undefined)_\n\n### **CSS Parts:**\n - **base** - The component's base wrapper.",
21
+ "doc-url": "",
22
+ "attributes": [],
23
+ "slots": [
24
+ { "name": "", "description": "The default slot." },
25
+ { "name": "example", "description": "An example slot." }
26
+ ],
27
+ "events": [
28
+ { "name": "zn-event-name", "description": "Emitted as an example." }
29
+ ],
30
+ "js": {
31
+ "properties": [],
32
+ "events": [
33
+ {
34
+ "name": "zn-event-name",
35
+ "description": "Emitted as an example."
36
+ }
37
+ ]
38
+ }
39
+ },
18
40
  {
19
41
  "name": "zn-alert",
20
42
  "description": "Short summary of the component's intended use.\n---\n\n\n### **Events:**\n - **zn-event-name** - Emitted as an example.\n\n### **Slots:**\n - _default_ - The default slot.\n- **example** - An example slot.\n\n### **CSS Properties:**\n - **--example** - An example CSS custom property. _(default: undefined)_\n\n### **CSS Parts:**\n - **base** - The component's base wrapper.",
@@ -70,28 +92,6 @@
70
92
  ]
71
93
  }
72
94
  },
73
- {
74
- "name": "zn-action-bar",
75
- "description": "Short summary of the component's intended use.\n---\n\n\n### **Events:**\n - **zn-event-name** - Emitted as an example.\n\n### **Slots:**\n - _default_ - The default slot.\n- **example** - An example slot.\n\n### **CSS Properties:**\n - **--example** - An example CSS custom property. _(default: undefined)_\n\n### **CSS Parts:**\n - **base** - The component's base wrapper.",
76
- "doc-url": "",
77
- "attributes": [],
78
- "slots": [
79
- { "name": "", "description": "The default slot." },
80
- { "name": "example", "description": "An example slot." }
81
- ],
82
- "events": [
83
- { "name": "zn-event-name", "description": "Emitted as an example." }
84
- ],
85
- "js": {
86
- "properties": [],
87
- "events": [
88
- {
89
- "name": "zn-event-name",
90
- "description": "Emitted as an example."
91
- }
92
- ]
93
- }
94
- },
95
95
  {
96
96
  "name": "zn-animated-button",
97
97
  "description": "\n---\n\n\n### **Methods:**\n - **purchase(): _void_** - Programmatically trigger the purchase flow\n- **setSuccess(): _void_** - Set the button to success state manually\n- **setFailure(message): _void_** - Set the button to failure state manually with optional error message\n- **reset(): _void_** - Reset the button to idle state",
@@ -3581,6 +3581,10 @@
3581
3581
  { "name": "name", "value": { "type": "string" } },
3582
3582
  { "name": "placeholder", "value": { "type": "string" } },
3583
3583
  { "name": "edit-text", "value": { "type": "string" } },
3584
+ {
3585
+ "name": "conditional",
3586
+ "value": { "type": "string", "default": "''" }
3587
+ },
3584
3588
  { "name": "disabled", "value": { "type": "boolean" } },
3585
3589
  { "name": "inline", "value": { "type": "boolean" } },
3586
3590
  { "name": "padded", "value": { "type": "boolean" } },
@@ -3669,6 +3673,7 @@
3669
3673
  { "name": "name", "type": "string" },
3670
3674
  { "name": "placeholder", "type": "string" },
3671
3675
  { "name": "editText", "type": "string" },
3676
+ { "name": "conditional", "type": "string" },
3672
3677
  { "name": "disabled", "type": "boolean" },
3673
3678
  { "name": "inline", "type": "boolean" },
3674
3679
  { "name": "padded", "type": "boolean" },
package/dist/zn.d.ts CHANGED
@@ -2030,6 +2030,28 @@ declare module "internal/animate" {
2030
2030
  offset?: number | null;
2031
2031
  }[];
2032
2032
  }
2033
+ declare module "internal/conditional" {
2034
+ import type { ReactiveController, ReactiveControllerHost } from 'lit';
2035
+ export interface ConditionalHost {
2036
+ conditional: string;
2037
+ disabled: boolean;
2038
+ }
2039
+ /** A reactive controller that disables the host when linked selects have a value. */
2040
+ export class ConditionalController implements ReactiveController {
2041
+ host: ReactiveControllerHost & Element & ConditionalHost;
2042
+ private conditionals;
2043
+ private initiallyDisabled;
2044
+ private readonly handleChange;
2045
+ constructor(host: ReactiveControllerHost & Element & ConditionalHost);
2046
+ /** Call from the host's `firstUpdated()` to parse IDs, find elements, attach listeners, and run the initial check. */
2047
+ setup(): void;
2048
+ hostConnected(): void;
2049
+ hostDisconnected(): void;
2050
+ /** Re-evaluate the conditional state. Call from the host when needed. */
2051
+ check(): void;
2052
+ private checkConditionals;
2053
+ }
2054
+ }
2033
2055
  declare module "utilities/animation-registry" {
2034
2056
  export interface ElementAnimation {
2035
2057
  keyframes: Keyframe[];
@@ -2177,6 +2199,7 @@ declare module "components/select/select.component" {
2177
2199
  'zn-tag': typeof ZnChip;
2178
2200
  };
2179
2201
  protected readonly formControlController: FormControlController;
2202
+ private readonly conditionalController;
2180
2203
  private readonly hasSlotController;
2181
2204
  private readonly localize;
2182
2205
  private typeToSelectString;
@@ -3786,10 +3809,12 @@ declare module "components/inline-edit/inline-edit.component" {
3786
3809
  static styles: CSSResultGroup;
3787
3810
  private readonly formControlController;
3788
3811
  private readonly hasSlotController;
3812
+ private readonly conditionalController;
3789
3813
  value: string | string[];
3790
3814
  name: string;
3791
3815
  placeholder: string;
3792
3816
  editText: string;
3817
+ conditional: string;
3793
3818
  disabled: boolean;
3794
3819
  inline: boolean;
3795
3820
  padded: boolean;