@kubex/zinc 1.1.58 → 1.1.60

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.
@@ -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.1.58",
4
+ "version": "1.1.60",
5
5
  "description-markup": "markdown",
6
6
  "contributions": {
7
7
  "html": {
@@ -15,28 +15,6 @@
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
- },
40
18
  {
41
19
  "name": "zn-alert",
42
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.",
@@ -105,6 +83,28 @@
105
83
  ]
106
84
  }
107
85
  },
86
+ {
87
+ "name": "zn-action-bar",
88
+ "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.",
89
+ "doc-url": "",
90
+ "attributes": [],
91
+ "slots": [
92
+ { "name": "", "description": "The default slot." },
93
+ { "name": "example", "description": "An example slot." }
94
+ ],
95
+ "events": [
96
+ { "name": "zn-event-name", "description": "Emitted as an example." }
97
+ ],
98
+ "js": {
99
+ "properties": [],
100
+ "events": [
101
+ {
102
+ "name": "zn-event-name",
103
+ "description": "Emitted as an example."
104
+ }
105
+ ]
106
+ }
107
+ },
108
108
  {
109
109
  "name": "zn-animated-button",
110
110
  "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",
@@ -4822,6 +4822,11 @@
4822
4822
  "value": {
4823
4823
  "type": "'none' | 'text' | 'decimal' | 'numeric' | 'tel' | 'search' | 'email' | 'url'"
4824
4824
  }
4825
+ },
4826
+ {
4827
+ "name": "trigger-submit",
4828
+ "description": "When enabled, pressing enter will always submit the surrounding form, even when the form uses\nenter-navigation to move between fields.",
4829
+ "value": { "type": "boolean", "default": "false" }
4825
4830
  }
4826
4831
  ],
4827
4832
  "slots": [
@@ -5068,6 +5073,11 @@
5068
5073
  "description": "Tells the browser what type of data will be entered by the user, allowing it to display the appropriate virtual\nkeyboard on supportive devices.",
5069
5074
  "type": "'none' | 'text' | 'decimal' | 'numeric' | 'tel' | 'search' | 'email' | 'url'"
5070
5075
  },
5076
+ {
5077
+ "name": "triggerSubmit",
5078
+ "description": "When enabled, pressing enter will always submit the surrounding form, even when the form uses\nenter-navigation to move between fields.",
5079
+ "type": "boolean"
5080
+ },
5071
5081
  {
5072
5082
  "name": "valueAsDate",
5073
5083
  "description": "Gets or sets the current value as `date` object. Returns `null` if the value can't be converted. This will use\nthe native `<input type=\"{{type}}\">` implementation and may result in an error."
@@ -8154,6 +8164,34 @@
8154
8164
  ]
8155
8165
  }
8156
8166
  },
8167
+ {
8168
+ "name": "zn-simple-chart",
8169
+ "description": "A simple, pre-styled bar chart.\n---\n",
8170
+ "doc-url": "",
8171
+ "attributes": [
8172
+ {
8173
+ "name": "datasets",
8174
+ "value": { "type": "{ data: number[] }[] | undefined" }
8175
+ },
8176
+ { "name": "labels", "value": { "type": "string[] | undefined" } },
8177
+ {
8178
+ "name": "enable-animations",
8179
+ "value": { "type": "boolean | number", "default": "false" }
8180
+ }
8181
+ ],
8182
+ "events": [],
8183
+ "js": {
8184
+ "properties": [
8185
+ {
8186
+ "name": "datasets",
8187
+ "type": "{ data: number[] }[] | undefined"
8188
+ },
8189
+ { "name": "labels", "type": "string[] | undefined" },
8190
+ { "name": "enableAnimations", "type": "boolean | number" }
8191
+ ],
8192
+ "events": []
8193
+ }
8194
+ },
8157
8195
  {
8158
8196
  "name": "zn-skeleton",
8159
8197
  "description": "Skeleton loaders provide visual placeholders while content is loading, improving perceived performance and user experience.\n---\n",
@@ -8288,34 +8326,6 @@
8288
8326
  ]
8289
8327
  }
8290
8328
  },
8291
- {
8292
- "name": "zn-simple-chart",
8293
- "description": "A simple, pre-styled bar chart.\n---\n",
8294
- "doc-url": "",
8295
- "attributes": [
8296
- {
8297
- "name": "datasets",
8298
- "value": { "type": "{ data: number[] }[] | undefined" }
8299
- },
8300
- { "name": "labels", "value": { "type": "string[] | undefined" } },
8301
- {
8302
- "name": "enable-animations",
8303
- "value": { "type": "boolean | number", "default": "false" }
8304
- }
8305
- ],
8306
- "events": [],
8307
- "js": {
8308
- "properties": [
8309
- {
8310
- "name": "datasets",
8311
- "type": "{ data: number[] }[] | undefined"
8312
- },
8313
- { "name": "labels", "type": "string[] | undefined" },
8314
- { "name": "enableAnimations", "type": "boolean | number" }
8315
- ],
8316
- "events": []
8317
- }
8318
- },
8319
8329
  {
8320
8330
  "name": "zn-sp",
8321
8331
  "description": "A flexible layout container for spacing and arranging child elements in rows or columns with configurable gap, padding, and dividers.\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.",
@@ -9550,7 +9560,7 @@
9550
9560
  },
9551
9561
  {
9552
9562
  "name": "zn-toggle",
9553
- "description": "Toggles allow the user to switch an option on or off.\n---\n\n\n### **Events:**\n - **zn-input** - Emitted when the toggle receives input.\n\n### **Slots:**\n - _default_ - The toggle's label.\n\n### **CSS Properties:**\n - **--zn-toggle-margin** - The margin around the toggle switch. Defaults to `8px 0`. _(default: undefined)_\n\n### **CSS Parts:**\n - **base** - The component's base wrapper containing the toggle switch.\n- **control** - The toggle switch control (the circular button that slides).",
9563
+ "description": "Toggles allow the user to switch an option on or off.\n---\n\n\n### **Events:**\n - **zn-input** - Emitted when the toggle receives input.\n\n### **Slots:**\n - _default_ - The toggle's label.\n- **description** - A description of the toggle's label. Alternatively, you can use the `description` attribute.\n- **help-text** - Text that describes how to use the toggle. Alternatively, you can use the `help-text` attribute.\n\n### **CSS Properties:**\n - **--zn-toggle-margin** - The margin around the toggle switch. Defaults to `8px 0`. _(default: undefined)_\n\n### **CSS Parts:**\n - **base** - The component's base wrapper containing the toggle switch.\n- **control** - The toggle switch control (the circular button that slides).\n- **description** - The container that wraps the toggle's description.",
9554
9564
  "doc-url": "",
9555
9565
  "attributes": [
9556
9566
  {
@@ -9603,12 +9613,34 @@
9603
9613
  "value": { "type": "string", "default": "''" }
9604
9614
  },
9605
9615
  { "name": "label", "value": { "type": "string", "default": "''" } },
9616
+ {
9617
+ "name": "description",
9618
+ "description": "The toggle's description, displayed under the label. If you need to display HTML, use the `description` slot instead.",
9619
+ "value": { "type": "string", "default": "''" }
9620
+ },
9621
+ {
9622
+ "name": "label-position",
9623
+ "value": {
9624
+ "type": "'top' | 'left' | 'right'",
9625
+ "default": "'top'"
9626
+ }
9627
+ },
9606
9628
  {
9607
9629
  "name": "inline",
9608
9630
  "value": { "type": "boolean", "default": "false" }
9609
9631
  }
9610
9632
  ],
9611
- "slots": [{ "name": "", "description": "The toggle's label." }],
9633
+ "slots": [
9634
+ { "name": "", "description": "The toggle's label." },
9635
+ {
9636
+ "name": "description",
9637
+ "description": "A description of the toggle's label. Alternatively, you can use the `description` attribute."
9638
+ },
9639
+ {
9640
+ "name": "help-text",
9641
+ "description": "Text that describes how to use the toggle. Alternatively, you can use the `help-text` attribute."
9642
+ }
9643
+ ],
9612
9644
  "events": [
9613
9645
  {
9614
9646
  "name": "zn-input",
@@ -9634,6 +9666,12 @@
9634
9666
  { "name": "onText", "type": "string" },
9635
9667
  { "name": "offText", "type": "string" },
9636
9668
  { "name": "label", "type": "string" },
9669
+ {
9670
+ "name": "description",
9671
+ "description": "The toggle's description, displayed under the label. If you need to display HTML, use the `description` slot instead.",
9672
+ "type": "string"
9673
+ },
9674
+ { "name": "labelPosition", "type": "'top' | 'left' | 'right'" },
9637
9675
  { "name": "inline", "type": "boolean" },
9638
9676
  { "name": "validity" },
9639
9677
  { "name": "validationMessage" }
package/dist/zn.d.ts CHANGED
@@ -1309,14 +1309,18 @@ declare module "components/toggle/toggle.component" {
1309
1309
  * @event zn-input - Emitted when the toggle receives input.
1310
1310
  *
1311
1311
  * @slot - The toggle's label.
1312
+ * @slot description - A description of the toggle's label. Alternatively, you can use the `description` attribute.
1313
+ * @slot help-text - Text that describes how to use the toggle. Alternatively, you can use the `help-text` attribute.
1312
1314
  *
1313
1315
  * @csspart base - The component's base wrapper containing the toggle switch.
1314
1316
  * @csspart control - The toggle switch control (the circular button that slides).
1317
+ * @csspart description - The container that wraps the toggle's description.
1315
1318
  *
1316
1319
  * @cssproperty --zn-toggle-margin - The margin around the toggle switch. Defaults to `8px 0`.
1317
1320
  */
1318
1321
  export default class ZnToggle extends ZincElement implements ZincFormControl {
1319
1322
  static styles: CSSResultGroup;
1323
+ private readonly hasSlotController;
1320
1324
  private readonly formControlController;
1321
1325
  input: HTMLInputElement;
1322
1326
  hasFocus: boolean;
@@ -1335,6 +1339,9 @@ declare module "components/toggle/toggle.component" {
1335
1339
  onText: string;
1336
1340
  offText: string;
1337
1341
  label: string;
1342
+ /** The toggle's description, displayed under the label. If you need to display HTML, use the `description` slot instead. */
1343
+ description: string;
1344
+ labelPosition: 'top' | 'left' | 'right';
1338
1345
  inline: boolean;
1339
1346
  get validity(): ValidityState;
1340
1347
  get validationMessage(): string;
@@ -1999,6 +2006,11 @@ declare module "components/input/input.component" {
1999
2006
  * keyboard on supportive devices.
2000
2007
  */
2001
2008
  inputmode: 'none' | 'text' | 'decimal' | 'numeric' | 'tel' | 'search' | 'email' | 'url';
2009
+ /**
2010
+ * When enabled, pressing enter will always submit the surrounding form, even when the form uses
2011
+ * enter-navigation to move between fields.
2012
+ */
2013
+ triggerSubmit: boolean;
2002
2014
  /**
2003
2015
  * Gets or sets the current value as `date` object. Returns `null` if the value can't be converted. This will use
2004
2016
  * the native `<input type="{{type}}">` implementation and may result in an error.