@kubex/zinc 1.1.67 → 1.1.68

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.
@@ -1318,10 +1318,19 @@
1318
1318
  "name": "zn-defined-label",
1319
1319
  "description": "This component provides a labeled input with support for predefined and custom labels,\nallowing users to select or enter label-value pairs within a dropdown interface.\n---\n\n\n### **CSS Parts:**\n - **input** - The component's main input.\n- **input-value** - The label's value inputs.",
1320
1320
  "attributes": [
1321
- { "name": "value", "values": [] },
1322
- { "name": "inputValue", "values": [] },
1321
+ {
1322
+ "name": "value",
1323
+ "description": "The selected label key. Also acts as the filter while typing.",
1324
+ "values": []
1325
+ },
1326
+ {
1327
+ "name": "inputValue",
1328
+ "description": "The value entered for the selected label. Submitted as `label:value` when present.",
1329
+ "values": []
1330
+ },
1323
1331
  {
1324
1332
  "name": "input-size",
1333
+ "description": "The size of the main input.",
1325
1334
  "values": [
1326
1335
  { "name": "x-small" },
1327
1336
  { "name": "small" },
@@ -1329,11 +1338,31 @@
1329
1338
  { "name": "large" }
1330
1339
  ]
1331
1340
  },
1332
- { "name": "name", "values": [] },
1333
- { "name": "title", "values": [] },
1334
- { "name": "disabled", "values": [] },
1335
- { "name": "allow-custom", "values": [] },
1336
- { "name": "predefined-labels", "values": [{ "name": "array" }] }
1341
+ {
1342
+ "name": "name",
1343
+ "description": "The name of the control. Used for form submission.",
1344
+ "values": []
1345
+ },
1346
+ {
1347
+ "name": "title",
1348
+ "description": "The title of the main input.",
1349
+ "values": []
1350
+ },
1351
+ {
1352
+ "name": "disabled",
1353
+ "description": "Disables the control.",
1354
+ "values": []
1355
+ },
1356
+ {
1357
+ "name": "allow-custom",
1358
+ "description": "Allows labels that aren't in the predefined list.",
1359
+ "values": []
1360
+ },
1361
+ {
1362
+ "name": "predefined-labels",
1363
+ "description": "The predefined labels. Entries are either a string or `{name, options}`.",
1364
+ "values": [{ "name": "(PredefinedLabel" }, { "name": "string)[]" }]
1365
+ }
1337
1366
  ],
1338
1367
  "references": [
1339
1368
  {
@@ -1665,6 +1694,11 @@
1665
1694
  "name": "show-link",
1666
1695
  "description": "When enabled, render the current link (`previewSrc`) as a clickable URL below the control.\nUseful for showing the existing CDN link alongside the preview.",
1667
1696
  "values": []
1697
+ },
1698
+ {
1699
+ "name": "upload-url",
1700
+ "description": "When set, a chosen file is immediately POSTed (multipart, field `file`) to this URL.\nThe endpoint must respond with JSON `{\"url\": \"...\"}`; that URL becomes the control's\nvalue (and `src` preview) in place of the file bytes, so the control works inside\nJSON-serialising hosts such as `zn-page-builder`. Emits `zn-error` when the upload fails.",
1701
+ "values": []
1668
1702
  }
1669
1703
  ],
1670
1704
  "references": [
@@ -1750,29 +1784,6 @@
1750
1784
  }
1751
1785
  ]
1752
1786
  },
1753
- {
1754
- "name": "zn-header",
1755
- "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.",
1756
- "attributes": [
1757
- { "name": "full-location", "values": [] },
1758
- { "name": "entity-id", "values": [] },
1759
- { "name": "entity-id-show", "values": [] },
1760
- { "name": "transparent", "values": [] },
1761
- { "name": "caption", "values": [] },
1762
- { "name": "icon", "values": [] },
1763
- { "name": "navigation", "values": [{ "name": "array" }] },
1764
- { "name": "full-width", "values": [] },
1765
- { "name": "previous-path", "values": [] },
1766
- { "name": "previous-target", "values": [] },
1767
- { "name": "hide-breadcrumb", "values": [] }
1768
- ],
1769
- "references": [
1770
- {
1771
- "name": "Documentation",
1772
- "url": "https://zinc.style/components/header"
1773
- }
1774
- ]
1775
- },
1776
1787
  {
1777
1788
  "name": "zn-hover-container",
1778
1789
  "description": "The HoverContainer component is used to display additional information when a user hovers over or clicks\non an element.\n---\n\n\n### **Events:**\n - **zn-show** - Emitted when the hover-container is shown.\n- **zn-after-show** - Emitted after the hover-container is shown.\n- **zn-hide** - Emitted when the hover-container is hidden.\n- **zn-after-hide** - Emitted after the hover-container is hidden.\n\n### **Slots:**\n - _default_ - The content of the hover-container\n- **anchor** - The anchor the hover-container is attached to.",
@@ -1810,6 +1821,29 @@
1810
1821
  }
1811
1822
  ]
1812
1823
  },
1824
+ {
1825
+ "name": "zn-header",
1826
+ "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.",
1827
+ "attributes": [
1828
+ { "name": "full-location", "values": [] },
1829
+ { "name": "entity-id", "values": [] },
1830
+ { "name": "entity-id-show", "values": [] },
1831
+ { "name": "transparent", "values": [] },
1832
+ { "name": "caption", "values": [] },
1833
+ { "name": "icon", "values": [] },
1834
+ { "name": "navigation", "values": [{ "name": "array" }] },
1835
+ { "name": "full-width", "values": [] },
1836
+ { "name": "previous-path", "values": [] },
1837
+ { "name": "previous-target", "values": [] },
1838
+ { "name": "hide-breadcrumb", "values": [] }
1839
+ ],
1840
+ "references": [
1841
+ {
1842
+ "name": "Documentation",
1843
+ "url": "https://zinc.style/components/header"
1844
+ }
1845
+ ]
1846
+ },
1813
1847
  {
1814
1848
  "name": "zn-icon",
1815
1849
  "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.",
@@ -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.67",
4
+ "version": "1.1.68",
5
5
  "description-markup": "markdown",
6
6
  "contributions": {
7
7
  "html": {
@@ -3055,13 +3055,19 @@
3055
3055
  "description": "This component provides a labeled input with support for predefined and custom labels,\nallowing users to select or enter label-value pairs within a dropdown interface.\n---\n\n\n### **CSS Parts:**\n - **input** - The component's main input.\n- **input-value** - The label's value inputs.",
3056
3056
  "doc-url": "",
3057
3057
  "attributes": [
3058
- { "name": "value", "value": { "type": "string", "default": "''" } },
3058
+ {
3059
+ "name": "value",
3060
+ "description": "The selected label key. Also acts as the filter while typing.",
3061
+ "value": { "type": "string", "default": "''" }
3062
+ },
3059
3063
  {
3060
3064
  "name": "inputValue",
3065
+ "description": "The value entered for the selected label. Submitted as `label:value` when present.",
3061
3066
  "value": { "type": "string", "default": "''" }
3062
3067
  },
3063
3068
  {
3064
3069
  "name": "input-size",
3070
+ "description": "The size of the main input.",
3065
3071
  "value": {
3066
3072
  "type": "'x-small' | 'small' | 'medium' | 'large'",
3067
3073
  "default": "'medium'"
@@ -3069,20 +3075,31 @@
3069
3075
  },
3070
3076
  {
3071
3077
  "name": "name",
3078
+ "description": "The name of the control. Used for form submission.",
3072
3079
  "value": { "type": "string", "default": "'label'" }
3073
3080
  },
3074
- { "name": "title", "value": { "type": "string" } },
3081
+ {
3082
+ "name": "title",
3083
+ "description": "The title of the main input.",
3084
+ "value": { "type": "string" }
3085
+ },
3075
3086
  {
3076
3087
  "name": "disabled",
3088
+ "description": "Disables the control.",
3077
3089
  "value": { "type": "boolean", "default": "false" }
3078
3090
  },
3079
3091
  {
3080
3092
  "name": "allow-custom",
3093
+ "description": "Allows labels that aren't in the predefined list.",
3081
3094
  "value": { "type": "boolean", "default": "false" }
3082
3095
  },
3083
3096
  {
3084
3097
  "name": "predefined-labels",
3085
- "value": { "type": "array", "default": "[]" }
3098
+ "description": "The predefined labels. Entries are either a string or `{name, options}`.",
3099
+ "value": {
3100
+ "type": "(PredefinedLabel | string)[]",
3101
+ "default": "[]"
3102
+ }
3086
3103
  }
3087
3104
  ],
3088
3105
  "events": [],
@@ -3090,17 +3107,46 @@
3090
3107
  "properties": [
3091
3108
  { "name": "input", "type": "ZnInput" },
3092
3109
  { "name": "dropdown", "type": "ZnDropdown" },
3093
- { "name": "value", "type": "string" },
3094
- { "name": "inputValue", "type": "string" },
3110
+ {
3111
+ "name": "value",
3112
+ "description": "The selected label key. Also acts as the filter while typing.",
3113
+ "type": "string"
3114
+ },
3115
+ {
3116
+ "name": "inputValue",
3117
+ "description": "The value entered for the selected label. Submitted as `label:value` when present.",
3118
+ "type": "string"
3119
+ },
3095
3120
  {
3096
3121
  "name": "inputSize",
3122
+ "description": "The size of the main input.",
3097
3123
  "type": "'x-small' | 'small' | 'medium' | 'large'"
3098
3124
  },
3099
- { "name": "name", "type": "string" },
3100
- { "name": "title", "type": "string" },
3101
- { "name": "disabled", "type": "boolean" },
3102
- { "name": "allowCustom", "type": "boolean" },
3103
- { "name": "predefinedLabels", "type": "array" },
3125
+ {
3126
+ "name": "name",
3127
+ "description": "The name of the control. Used for form submission.",
3128
+ "type": "string"
3129
+ },
3130
+ {
3131
+ "name": "title",
3132
+ "description": "The title of the main input.",
3133
+ "type": "string"
3134
+ },
3135
+ {
3136
+ "name": "disabled",
3137
+ "description": "Disables the control.",
3138
+ "type": "boolean"
3139
+ },
3140
+ {
3141
+ "name": "allowCustom",
3142
+ "description": "Allows labels that aren't in the predefined list.",
3143
+ "type": "boolean"
3144
+ },
3145
+ {
3146
+ "name": "predefinedLabels",
3147
+ "description": "The predefined labels. Entries are either a string or `{name, options}`.",
3148
+ "type": "(PredefinedLabel | string)[]"
3149
+ },
3104
3150
  { "name": "validationMessage" },
3105
3151
  { "name": "validity" }
3106
3152
  ],
@@ -3717,6 +3763,11 @@
3717
3763
  "name": "show-link",
3718
3764
  "description": "When enabled, render the current link (`previewSrc`) as a clickable URL below the control.\nUseful for showing the existing CDN link alongside the preview.",
3719
3765
  "value": { "type": "boolean", "default": "false" }
3766
+ },
3767
+ {
3768
+ "name": "upload-url",
3769
+ "description": "When set, a chosen file is immediately POSTed (multipart, field `file`) to this URL.\nThe endpoint must respond with JSON `{\"url\": \"...\"}`; that URL becomes the control's\nvalue (and `src` preview) in place of the file bytes, so the control works inside\nJSON-serialising hosts such as `zn-page-builder`. Emits `zn-error` when the upload fails.",
3770
+ "value": { "type": "string", "default": "''" }
3720
3771
  }
3721
3772
  ],
3722
3773
  "slots": [
@@ -3868,6 +3919,11 @@
3868
3919
  "description": "When enabled, render the current link (`previewSrc`) as a clickable URL below the control.\nUseful for showing the existing CDN link alongside the preview.",
3869
3920
  "type": "boolean"
3870
3921
  },
3922
+ {
3923
+ "name": "uploadUrl",
3924
+ "description": "When set, a chosen file is immediately POSTed (multipart, field `file`) to this URL.\nThe endpoint must respond with JSON `{\"url\": \"...\"}`; that URL becomes the control's\nvalue (and `src` preview) in place of the file bytes, so the control works inside\nJSON-serialising hosts such as `zn-page-builder`. Emits `zn-error` when the upload fails.",
3925
+ "type": "string"
3926
+ },
3871
3927
  {
3872
3928
  "name": "validity",
3873
3929
  "description": "Gets the validity state object"
@@ -4151,63 +4207,6 @@
4151
4207
  "events": []
4152
4208
  }
4153
4209
  },
4154
- {
4155
- "name": "zn-header",
4156
- "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.",
4157
- "doc-url": "",
4158
- "attributes": [
4159
- { "name": "full-location", "value": { "type": "string" } },
4160
- { "name": "entity-id", "value": { "type": "string" } },
4161
- { "name": "entity-id-show", "value": { "type": "boolean" } },
4162
- {
4163
- "name": "transparent",
4164
- "value": { "type": "boolean", "default": "false" }
4165
- },
4166
- { "name": "caption", "value": { "type": "string" } },
4167
- { "name": "icon", "value": { "type": "string" } },
4168
- {
4169
- "name": "navigation",
4170
- "value": { "type": "array", "default": "[]" }
4171
- },
4172
- { "name": "full-width", "value": { "type": "boolean" } },
4173
- { "name": "previous-path", "value": { "type": "string" } },
4174
- { "name": "previous-target", "value": { "type": "string" } },
4175
- {
4176
- "name": "hide-breadcrumb",
4177
- "value": { "type": "boolean", "default": "false" }
4178
- }
4179
- ],
4180
- "slots": [
4181
- { "name": "", "description": "The default slot." },
4182
- { "name": "example", "description": "An example slot." }
4183
- ],
4184
- "events": [
4185
- { "name": "zn-event-name", "description": "Emitted as an example." }
4186
- ],
4187
- "js": {
4188
- "properties": [
4189
- { "name": "fullLocation", "type": "string" },
4190
- { "name": "entityId", "type": "string" },
4191
- { "name": "entityIdShow", "type": "boolean" },
4192
- { "name": "transparent", "type": "boolean" },
4193
- { "name": "caption", "type": "string" },
4194
- { "name": "icon", "type": "string" },
4195
- { "name": "navigation", "type": "array" },
4196
- { "name": "fullWidth", "type": "boolean" },
4197
- { "name": "previousPath", "type": "string" },
4198
- { "name": "previousTarget", "type": "string" },
4199
- { "name": "hideBreadcrumb", "type": "boolean" },
4200
- { "name": "handleAltPress" },
4201
- { "name": "handleAltUp" }
4202
- ],
4203
- "events": [
4204
- {
4205
- "name": "zn-event-name",
4206
- "description": "Emitted as an example."
4207
- }
4208
- ]
4209
- }
4210
- },
4211
4210
  {
4212
4211
  "name": "zn-hover-container",
4213
4212
  "description": "The HoverContainer component is used to display additional information when a user hovers over or clicks\non an element.\n---\n\n\n### **Events:**\n - **zn-show** - Emitted when the hover-container is shown.\n- **zn-after-show** - Emitted after the hover-container is shown.\n- **zn-hide** - Emitted when the hover-container is hidden.\n- **zn-after-hide** - Emitted after the hover-container is hidden.\n\n### **Slots:**\n - _default_ - The content of the hover-container\n- **anchor** - The anchor the hover-container is attached to.",
@@ -4311,6 +4310,63 @@
4311
4310
  ]
4312
4311
  }
4313
4312
  },
4313
+ {
4314
+ "name": "zn-header",
4315
+ "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.",
4316
+ "doc-url": "",
4317
+ "attributes": [
4318
+ { "name": "full-location", "value": { "type": "string" } },
4319
+ { "name": "entity-id", "value": { "type": "string" } },
4320
+ { "name": "entity-id-show", "value": { "type": "boolean" } },
4321
+ {
4322
+ "name": "transparent",
4323
+ "value": { "type": "boolean", "default": "false" }
4324
+ },
4325
+ { "name": "caption", "value": { "type": "string" } },
4326
+ { "name": "icon", "value": { "type": "string" } },
4327
+ {
4328
+ "name": "navigation",
4329
+ "value": { "type": "array", "default": "[]" }
4330
+ },
4331
+ { "name": "full-width", "value": { "type": "boolean" } },
4332
+ { "name": "previous-path", "value": { "type": "string" } },
4333
+ { "name": "previous-target", "value": { "type": "string" } },
4334
+ {
4335
+ "name": "hide-breadcrumb",
4336
+ "value": { "type": "boolean", "default": "false" }
4337
+ }
4338
+ ],
4339
+ "slots": [
4340
+ { "name": "", "description": "The default slot." },
4341
+ { "name": "example", "description": "An example slot." }
4342
+ ],
4343
+ "events": [
4344
+ { "name": "zn-event-name", "description": "Emitted as an example." }
4345
+ ],
4346
+ "js": {
4347
+ "properties": [
4348
+ { "name": "fullLocation", "type": "string" },
4349
+ { "name": "entityId", "type": "string" },
4350
+ { "name": "entityIdShow", "type": "boolean" },
4351
+ { "name": "transparent", "type": "boolean" },
4352
+ { "name": "caption", "type": "string" },
4353
+ { "name": "icon", "type": "string" },
4354
+ { "name": "navigation", "type": "array" },
4355
+ { "name": "fullWidth", "type": "boolean" },
4356
+ { "name": "previousPath", "type": "string" },
4357
+ { "name": "previousTarget", "type": "string" },
4358
+ { "name": "hideBreadcrumb", "type": "boolean" },
4359
+ { "name": "handleAltPress" },
4360
+ { "name": "handleAltUp" }
4361
+ ],
4362
+ "events": [
4363
+ {
4364
+ "name": "zn-event-name",
4365
+ "description": "Emitted as an example."
4366
+ }
4367
+ ]
4368
+ }
4369
+ },
4314
4370
  {
4315
4371
  "name": "zn-icon",
4316
4372
  "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.",
package/dist/zn.d.ts CHANGED
@@ -3424,6 +3424,7 @@ declare module "components/data-table/data-table.component" {
3424
3424
  import ZnStyle from "components/style/index";
3425
3425
  interface Cell {
3426
3426
  text: string;
3427
+ subText?: string;
3427
3428
  column: string;
3428
3429
  color?: string;
3429
3430
  style?: string;
@@ -3439,6 +3440,7 @@ declare module "components/data-table/data-table.component" {
3439
3440
  uri?: string;
3440
3441
  target?: string;
3441
3442
  copyable?: boolean;
3443
+ title?: string;
3442
3444
  }
3443
3445
  interface Row {
3444
3446
  id: string;
@@ -3704,9 +3706,16 @@ declare module "components/cols/index" {
3704
3706
  declare module "components/defined-label/defined-label.component" {
3705
3707
  import { type CSSResultGroup, type PropertyValues, type TemplateResult } from 'lit';
3706
3708
  import ZincElement from "internal/zinc-element";
3709
+ import ZnButton from "components/button/index";
3710
+ import ZnDropdown from "components/dropdown/index";
3711
+ import ZnInput from "components/input/index";
3712
+ import ZnOption from "components/option/index";
3713
+ import ZnSelect from "components/select/index";
3707
3714
  import type { ZincFormControl } from "internal/zinc-element";
3708
- import type ZnDropdown from "components/dropdown/index";
3709
- import type ZnInput from "components/input/index";
3715
+ interface PredefinedLabel {
3716
+ name: string;
3717
+ options?: string[];
3718
+ }
3710
3719
  /**
3711
3720
  * @summary This component provides a labeled input with support for predefined and custom labels,
3712
3721
  * allowing users to select or enter label-value pairs within a dropdown interface.
@@ -3718,26 +3727,39 @@ declare module "components/defined-label/defined-label.component" {
3718
3727
  * @dependency zn-dropdown
3719
3728
  * @dependency zn-input
3720
3729
  * @dependency zn-option
3721
- * @dependency zn-panel
3722
3730
  * @dependency zn-select
3723
- * @dependency zn-sp
3724
3731
  *
3725
3732
  * @csspart input - The component's main input.
3726
3733
  * @csspart input-value - The label's value inputs.
3727
3734
  */
3728
3735
  export default class ZnDefinedLabel extends ZincElement implements ZincFormControl {
3729
3736
  static styles: CSSResultGroup;
3737
+ static dependencies: {
3738
+ 'zn-button': typeof ZnButton;
3739
+ 'zn-dropdown': typeof ZnDropdown;
3740
+ 'zn-input': typeof ZnInput;
3741
+ 'zn-option': typeof ZnOption;
3742
+ 'zn-select': typeof ZnSelect;
3743
+ };
3730
3744
  private readonly formControlController;
3731
3745
  input: ZnInput;
3732
3746
  dropdown: ZnDropdown;
3747
+ /** The selected label key. Also acts as the filter while typing. */
3733
3748
  value: string;
3749
+ /** The value entered for the selected label. Submitted as `label:value` when present. */
3734
3750
  inputValue: string;
3751
+ /** The size of the main input. */
3735
3752
  inputSize: 'x-small' | 'small' | 'medium' | 'large';
3753
+ /** The name of the control. Used for form submission. */
3736
3754
  name: string;
3755
+ /** The title of the main input. */
3737
3756
  title: string;
3757
+ /** Disables the control. */
3738
3758
  disabled: boolean;
3759
+ /** Allows labels that aren't in the predefined list. */
3739
3760
  allowCustom: boolean;
3740
- predefinedLabels: never[];
3761
+ /** The predefined labels. Entries are either a string or `{name, options}`. */
3762
+ predefinedLabels: (PredefinedLabel | string)[];
3741
3763
  get validationMessage(): string;
3742
3764
  get validity(): ValidityState;
3743
3765
  checkValidity(): boolean;
@@ -3746,12 +3768,14 @@ declare module "components/defined-label/defined-label.component" {
3746
3768
  setCustomValidity(message: string): void;
3747
3769
  handleValueChange(): Promise<void>;
3748
3770
  protected firstUpdated(changedProperties: PropertyValues): void;
3771
+ private getFilteredLabels;
3749
3772
  private handleChange;
3750
3773
  private handleInput;
3751
3774
  private handleClick;
3752
3775
  private handleInputValueChange;
3753
- private handleInputValueInput;
3754
3776
  private handleFormSubmit;
3777
+ private renderValueControl;
3778
+ private renderRow;
3755
3779
  render(): TemplateResult<1>;
3756
3780
  }
3757
3781
  }
@@ -7182,6 +7206,14 @@ declare module "components/file/file.component" {
7182
7206
  * Useful for showing the existing CDN link alongside the preview.
7183
7207
  */
7184
7208
  showLink: boolean;
7209
+ /**
7210
+ * When set, a chosen file is immediately POSTed (multipart, field `file`) to this URL.
7211
+ * The endpoint must respond with JSON `{"url": "..."}`; that URL becomes the control's
7212
+ * value (and `src` preview) in place of the file bytes, so the control works inside
7213
+ * JSON-serialising hosts such as `zn-page-builder`. Emits `zn-error` when the upload fails.
7214
+ */
7215
+ uploadUrl: string;
7216
+ private uploading;
7185
7217
  /** Gets the validity state object */
7186
7218
  get validity(): ValidityState;
7187
7219
  /** Gets the validation message */
@@ -7210,6 +7242,11 @@ declare module "components/file/file.component" {
7210
7242
  private handleClick;
7211
7243
  /** Handles the change event of the native input */
7212
7244
  private handleChange;
7245
+ /**
7246
+ * Uploads the chosen file to `uploadUrl` and adopts the returned URL as the
7247
+ * control's value. The local file preview stays visible while the upload runs.
7248
+ */
7249
+ private uploadFile;
7213
7250
  private handleDragOver;
7214
7251
  private handleDragLeave;
7215
7252
  private handleDrop;