@kubex/zinc 1.1.8 → 1.1.9
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/dist/custom-elements.json +74 -74
- package/dist/vscode.html-custom-data.json +11 -11
- package/dist/web-types.json +23 -23
- package/dist/zn.min.js +1 -1
- package/package.json +1 -1
- package/src/components/page/page.scss +1 -2
|
@@ -47,6 +47,79 @@
|
|
|
47
47
|
}
|
|
48
48
|
]
|
|
49
49
|
},
|
|
50
|
+
{
|
|
51
|
+
"kind": "javascript-module",
|
|
52
|
+
"path": "components/action-bar/action-bar.js",
|
|
53
|
+
"declarations": [
|
|
54
|
+
{
|
|
55
|
+
"kind": "class",
|
|
56
|
+
"description": "",
|
|
57
|
+
"name": "ZnActionBar",
|
|
58
|
+
"cssProperties": [
|
|
59
|
+
{
|
|
60
|
+
"description": "An example CSS custom property.",
|
|
61
|
+
"name": "--example"
|
|
62
|
+
}
|
|
63
|
+
],
|
|
64
|
+
"cssParts": [
|
|
65
|
+
{
|
|
66
|
+
"description": "The component's base wrapper.",
|
|
67
|
+
"name": "base"
|
|
68
|
+
}
|
|
69
|
+
],
|
|
70
|
+
"slots": [
|
|
71
|
+
{
|
|
72
|
+
"description": "The default slot.",
|
|
73
|
+
"name": ""
|
|
74
|
+
},
|
|
75
|
+
{
|
|
76
|
+
"description": "An example slot.",
|
|
77
|
+
"name": "example"
|
|
78
|
+
}
|
|
79
|
+
],
|
|
80
|
+
"members": [
|
|
81
|
+
{
|
|
82
|
+
"kind": "field",
|
|
83
|
+
"name": "localize",
|
|
84
|
+
"privacy": "private",
|
|
85
|
+
"readonly": true,
|
|
86
|
+
"default": "new LocalizeController(this)"
|
|
87
|
+
}
|
|
88
|
+
],
|
|
89
|
+
"events": [
|
|
90
|
+
{
|
|
91
|
+
"description": "Emitted as an example.",
|
|
92
|
+
"name": "zn-event-name"
|
|
93
|
+
}
|
|
94
|
+
],
|
|
95
|
+
"superclass": {
|
|
96
|
+
"name": "ZincElement",
|
|
97
|
+
"module": "/src/internal/zinc-element"
|
|
98
|
+
},
|
|
99
|
+
"summary": "Short summary of the component's intended use.",
|
|
100
|
+
"tagNameWithoutPrefix": "action-bar",
|
|
101
|
+
"tagName": "zn-action-bar",
|
|
102
|
+
"customElement": true,
|
|
103
|
+
"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 */",
|
|
104
|
+
"documentation": "https://zinc.style/components/action-bar",
|
|
105
|
+
"status": "experimental",
|
|
106
|
+
"since": "1.0",
|
|
107
|
+
"dependencies": [
|
|
108
|
+
"zn-example"
|
|
109
|
+
]
|
|
110
|
+
}
|
|
111
|
+
],
|
|
112
|
+
"exports": [
|
|
113
|
+
{
|
|
114
|
+
"kind": "js",
|
|
115
|
+
"name": "default",
|
|
116
|
+
"declaration": {
|
|
117
|
+
"name": "ZnActionBar",
|
|
118
|
+
"module": "components/action-bar/action-bar.js"
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
]
|
|
122
|
+
},
|
|
50
123
|
{
|
|
51
124
|
"kind": "javascript-module",
|
|
52
125
|
"path": "components/alert/alert.js",
|
|
@@ -223,79 +296,6 @@
|
|
|
223
296
|
}
|
|
224
297
|
]
|
|
225
298
|
},
|
|
226
|
-
{
|
|
227
|
-
"kind": "javascript-module",
|
|
228
|
-
"path": "components/action-bar/action-bar.js",
|
|
229
|
-
"declarations": [
|
|
230
|
-
{
|
|
231
|
-
"kind": "class",
|
|
232
|
-
"description": "",
|
|
233
|
-
"name": "ZnActionBar",
|
|
234
|
-
"cssProperties": [
|
|
235
|
-
{
|
|
236
|
-
"description": "An example CSS custom property.",
|
|
237
|
-
"name": "--example"
|
|
238
|
-
}
|
|
239
|
-
],
|
|
240
|
-
"cssParts": [
|
|
241
|
-
{
|
|
242
|
-
"description": "The component's base wrapper.",
|
|
243
|
-
"name": "base"
|
|
244
|
-
}
|
|
245
|
-
],
|
|
246
|
-
"slots": [
|
|
247
|
-
{
|
|
248
|
-
"description": "The default slot.",
|
|
249
|
-
"name": ""
|
|
250
|
-
},
|
|
251
|
-
{
|
|
252
|
-
"description": "An example slot.",
|
|
253
|
-
"name": "example"
|
|
254
|
-
}
|
|
255
|
-
],
|
|
256
|
-
"members": [
|
|
257
|
-
{
|
|
258
|
-
"kind": "field",
|
|
259
|
-
"name": "localize",
|
|
260
|
-
"privacy": "private",
|
|
261
|
-
"readonly": true,
|
|
262
|
-
"default": "new LocalizeController(this)"
|
|
263
|
-
}
|
|
264
|
-
],
|
|
265
|
-
"events": [
|
|
266
|
-
{
|
|
267
|
-
"description": "Emitted as an example.",
|
|
268
|
-
"name": "zn-event-name"
|
|
269
|
-
}
|
|
270
|
-
],
|
|
271
|
-
"superclass": {
|
|
272
|
-
"name": "ZincElement",
|
|
273
|
-
"module": "/src/internal/zinc-element"
|
|
274
|
-
},
|
|
275
|
-
"summary": "Short summary of the component's intended use.",
|
|
276
|
-
"tagNameWithoutPrefix": "action-bar",
|
|
277
|
-
"tagName": "zn-action-bar",
|
|
278
|
-
"customElement": true,
|
|
279
|
-
"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 */",
|
|
280
|
-
"documentation": "https://zinc.style/components/action-bar",
|
|
281
|
-
"status": "experimental",
|
|
282
|
-
"since": "1.0",
|
|
283
|
-
"dependencies": [
|
|
284
|
-
"zn-example"
|
|
285
|
-
]
|
|
286
|
-
}
|
|
287
|
-
],
|
|
288
|
-
"exports": [
|
|
289
|
-
{
|
|
290
|
-
"kind": "js",
|
|
291
|
-
"name": "default",
|
|
292
|
-
"declaration": {
|
|
293
|
-
"name": "ZnActionBar",
|
|
294
|
-
"module": "components/action-bar/action-bar.js"
|
|
295
|
-
}
|
|
296
|
-
}
|
|
297
|
-
]
|
|
298
|
-
},
|
|
299
299
|
{
|
|
300
300
|
"kind": "javascript-module",
|
|
301
301
|
"path": "components/animated-button/animated-button.js",
|
|
@@ -36368,7 +36368,7 @@
|
|
|
36368
36368
|
"package": {
|
|
36369
36369
|
"name": "@kubex/zinc",
|
|
36370
36370
|
"description": "A collection of web components for building web applications based off of @shoelace-style/Shoelace",
|
|
36371
|
-
"version": "1.1.
|
|
36371
|
+
"version": "1.1.9",
|
|
36372
36372
|
"author": "",
|
|
36373
36373
|
"license": "MIT"
|
|
36374
36374
|
}
|
|
@@ -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.",
|
|
@@ -52,17 +63,6 @@
|
|
|
52
63
|
}
|
|
53
64
|
]
|
|
54
65
|
},
|
|
55
|
-
{
|
|
56
|
-
"name": "zn-action-bar",
|
|
57
|
-
"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.",
|
|
58
|
-
"attributes": [],
|
|
59
|
-
"references": [
|
|
60
|
-
{
|
|
61
|
-
"name": "Documentation",
|
|
62
|
-
"url": "https://zinc.style/components/action-bar"
|
|
63
|
-
}
|
|
64
|
-
]
|
|
65
|
-
},
|
|
66
66
|
{
|
|
67
67
|
"name": "zn-animated-button",
|
|
68
68
|
"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",
|
package/dist/web-types.json
CHANGED
|
@@ -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.
|
|
4
|
+
"version": "1.1.9",
|
|
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.",
|
|
@@ -78,28 +100,6 @@
|
|
|
78
100
|
]
|
|
79
101
|
}
|
|
80
102
|
},
|
|
81
|
-
{
|
|
82
|
-
"name": "zn-action-bar",
|
|
83
|
-
"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.",
|
|
84
|
-
"doc-url": "",
|
|
85
|
-
"attributes": [],
|
|
86
|
-
"slots": [
|
|
87
|
-
{ "name": "", "description": "The default slot." },
|
|
88
|
-
{ "name": "example", "description": "An example slot." }
|
|
89
|
-
],
|
|
90
|
-
"events": [
|
|
91
|
-
{ "name": "zn-event-name", "description": "Emitted as an example." }
|
|
92
|
-
],
|
|
93
|
-
"js": {
|
|
94
|
-
"properties": [],
|
|
95
|
-
"events": [
|
|
96
|
-
{
|
|
97
|
-
"name": "zn-event-name",
|
|
98
|
-
"description": "Emitted as an example."
|
|
99
|
-
}
|
|
100
|
-
]
|
|
101
|
-
}
|
|
102
|
-
},
|
|
103
103
|
{
|
|
104
104
|
"name": "zn-animated-button",
|
|
105
105
|
"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",
|
package/dist/zn.min.js
CHANGED
|
@@ -1301,7 +1301,7 @@ function print() { __p += __j.call(arguments, '') }
|
|
|
1301
1301
|
</div>
|
|
1302
1302
|
<slot name="bottom"></slot>
|
|
1303
1303
|
</div>
|
|
1304
|
-
`}};sr.styles=Q(G2e),_([w({attribute:"master-id",reflect:!0})],sr.prototype,"masterId",2),_([w({attribute:"default-uri",reflect:!0})],sr.prototype,"defaultUri",2),_([w({attribute:"active",reflect:!0})],sr.prototype,"_current",2),_([w({attribute:"split",type:Number,reflect:!0})],sr.prototype,"_split",2),_([w({attribute:"split-min",type:Number,reflect:!0})],sr.prototype,"_splitMin",2),_([w({attribute:"split-min-secondary",type:Number,reflect:!0})],sr.prototype,"_splitMinSecondary",2),_([w({attribute:"split-max",type:Number,reflect:!0})],sr.prototype,"_splitMax",2),_([w({attribute:"primary-caption",reflect:!0})],sr.prototype,"primaryCaption",2),_([w({attribute:"secondary-caption",reflect:!0})],sr.prototype,"secondaryCaption",2),_([w({attribute:"no-prefetch",type:Boolean,reflect:!0})],sr.prototype,"noPrefetch",2),_([w({attribute:"no-cache",type:Boolean,reflect:!0})],sr.prototype,"noCache",2),_([w({attribute:"local-storage",type:Boolean,reflect:!0})],sr.prototype,"localStorage",2),_([w({attribute:"store-key"})],sr.prototype,"storeKey",2),_([w({attribute:"store-ttl",type:Number,reflect:!0})],sr.prototype,"storeTtl",2),_([w({attribute:"padded",type:Boolean,reflect:!0})],sr.prototype,"padded",2),_([w({attribute:"fetch-style",type:String,reflect:!0})],sr.prototype,"fetchStyle",2),_([w({attribute:"full-width",type:Boolean,reflect:!0})],sr.prototype,"fullWidth",2),_([w({attribute:"padded-right",type:Boolean,reflect:!0})],sr.prototype,"paddedRight",2),_([w()],sr.prototype,"monitor",2),_([w()],sr.prototype,"caption",2),_([w()],sr.prototype,"description",2);var $u=sr;sr.define("zn-tabs");var W2e=J`@keyframes rotate-gradient{from{--rotate:0deg}to{--rotate:360deg}}:host{text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;text-transform:none}:host *,:host *::before,:host *::after{box-sizing:border-box;border-width:0;border-style:solid;border-color:rgb(var(--zn-border-color))}[hidden]{display:none !important}.width-container,.form-container,.wide-form-container{height:100%;width:100%;margin:var(--zn-default-margin,0 auto)}.width-container{max-width:var(--zn-container)}.form-container{max-width:var(--zn-container-ph)}.wide-form-container{max-width:var(--zn-container-lg)}@container (width > 1024px){:host{--zn-gutter:16px}}@container (width > 1400px){:host{--zn-gutter:24px}}@container (width > 1500px){:host{--zn-gutter:32px}}:host{display:block;width:100%;height:100%;min-height:0;container-type:inline-size;--zn-page-content-background:var(--zn-body);--zn-page-header-background:var(--zn-page-surface-background,var(--zn-page-background,var(--zn-body)))}:host([panel]){--zn-page-content-background:var(--zn-panel)}:host([panel-head]){--zn-page-header-background:var(--zn-panel)}:host([panel-nav]){--zn-active-nav-background:var(--zn-panel)}.page__header{flex:0 0 auto;position:sticky;top:0;z-index:2;box-sizing:border-box;background:rgba(var(--zn-page-header-background),95%)}.page__header::after{content:"";position:absolute;right:var(--zn-base-gap);bottom:0;left:var(--zn-base-gap);height:1px;background:rgb(var(--zn-border-color));opacity:0;transition:opacity 180ms ease-in-out;pointer-events:none}.page__header--scrolled-no-navigation::after{opacity:1}.header{display:flex;flex-direction:column;position:relative;margin:0;padding:calc(var(--zn-base-px) * 3) var(--zn-base-gap) calc(var(--zn-base-px) * 3 - var(--zn-base-gap)) var(--zn-base-gap)}.header.header--has-navigation{padding:calc(var(--zn-base-px) * 3) var(--zn-base-gap)}.header .content{display:flex;flex-wrap:wrap;position:relative;width:100%;max-width:100%;height:-moz-fit-content;height:fit-content;gap:var(--zn-base-gap);margin:0 auto;padding:0;box-sizing:border-box}.header--has-navigation .content{min-height:36px}.header .caption{flex-grow:1;display:flex;align-items:flex-start;justify-content:space-between;gap:2px;max-width:100%;min-height:36px}.header .caption a{display:flex;align-items:center;color:inherit;text-decoration:none}.header__left{display:flex;justify-content:flex-start;flex-direction:column;gap:4px;min-height:36px;flex-shrink:1;max-width:100%}.header__right{flex-grow:1;flex-shrink:1;overflow:hidden;min-width:20px}.header__caption{font-weight:var(--zn-text-h1-font-weight);font-size:var(--zn-text-h1-font-size);color:rgba(var(--zn-text-panel-title),100%);line-height:18px;margin:0;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;display:flex;gap:var(--zn-spacing-x-small);align-items:center;text-wrap:auto}.header__description{display:block;font-size:var(--zn-font-size-medium);line-height:14px}.header .breadcrumb{display:inline-flex;align-items:center;gap:var(--zn-spacing-2x-small);font:inherit;color:inherit}.header .breadcrumb::slotted(a){font:inherit;color:inherit;text-decoration:inherit}.header .breadcrumb::slotted(a:hover){color:rgb(var(--zn-primary))}.header .breadcrumb::slotted(a)::after{content:">";margin-left:var(--zn-spacing-2x-small);color:rgb(var(--zn-text-muted));font-weight:var(--zn-font-weight-normal)}.header slot{display:flex;align-items:center;flex-wrap:wrap;gap:var(--zn-spacing-x-small);word-break:break-word}.header slot[name=actions]{justify-content:end;flex-wrap:nowrap}.header slot[name=actions]::slotted(zn-button-menu){flex-grow:1;flex-shrink:1}.caption__back{display:flex;justify-content:center;align-items:center;color:inherit}.alt-overlay{display:none}.alt-overlay--visible{display:flex}:host(.alt-pressed) .alt-overlay:empty{display:none !important}:host(.alt-pressed) .alt-overlay{display:flex}.alt-overlay{gap:10px;align-items:flex-end;position:absolute;left:0;top:0;padding:6px 15px;background:rgba(var(--zn-panel),0.95);z-index:10}.alt-overlay a{display:flex}.alt-overlay zn-icon:hover{color:rgb(var(--zn-primary));cursor:pointer}.page{display:flex;flex-direction:column;position:relative;height:100%;min-height:0;max-height:100%;width:100%;max-width:100%;overflow:auto;box-sizing:border-box;padding:0}.page__tabs{flex-grow:1;display:flex;flex-direction:column;min-height:0;width:100%;overflow:visible;box-sizing:border-box;padding:0 var(--zn-base-gap) var(--zn-base-gap);background:rgb(var(--zn-page-content-background,var(--zn-body)))}.page__tabs .page__content{display:flex;flex-direction:column;flex-grow:1;min-height:0;max-width:100%;width:100%;overflow:visible;box-sizing:border-box}.page__tabs #content ::slotted(zn-tab){display:block !important}:host([flush]) .page__tabs,:host([flush]) .page__tabs .page__content#content{padding:0}zn-navbar::part(navbar){height:40px;min-height:40px;max-height:40px;padding-left:var(--zn-base-gap);margin:0}zn-navbar::part(navbar-item){height:40px;box-sizing:border-box;font-size:var(--zn-font-size-medium);line-height:16px}:host .page__header{padding-inline:0}:host .header{padding-inline:calc(var(--zn-gutter,0) + var(--zn-base-gap,0))}:host zn-navbar::part(navbar){padding-inline:calc(var(--zn-gutter,0) + var(--zn-base-gap,0))}:host .page__tabs{padding:0}:host .page__tabs #content.page__content{padding:0 var(--zn-gutter,0)}`;var ba=class extends $u{constructor(){super(...arguments);this.pageSlotController=new Je(this,"breadcrumb","actions","caption");this.modal=!1;this.nested=!1;this.primary=!1;this.scrolled=!1;this.tabDefinitions=[];this.hasExpandingActions=!1;this.actionObserver=null;this.tabObserver=null;this.handleAltPress=()=>{this.classList.toggle("alt-pressed",!0)};this.handleAltUp=()=>{this.classList.toggle("alt-pressed",!1)};this._registerTabs=()=>{this.registerPageNavigationTabs()}}async connectedCallback(){let t=super.connectedCallback();window.addEventListener("alt-press",this.handleAltPress),window.addEventListener("alt-up",this.handleAltUp),this.prepareTabs(),this.refreshExpandingActionsState(),this.tabObserver=new MutationObserver(i=>{i.some(n=>n.type==="childList")&&this.prepareTabs()}),this.tabObserver.observe(this,{childList:!0}),this.actionObserver=new MutationObserver(i=>{i.some(n=>n.type==="childList")&&(this.refreshExpandingActionsState(),this.syncExpandingActionsToNavbar())}),this.actionObserver.observe(this,{childList:!0,subtree:!0}),await t}disconnectedCallback(){var t,i;super.disconnectedCallback(),window.removeEventListener("alt-press",this.handleAltPress),window.removeEventListener("alt-up",this.handleAltUp),(t=this.tabObserver)==null||t.disconnect(),this.tabObserver=null,(i=this.actionObserver)==null||i.disconnect(),this.actionObserver=null}firstUpdated(t){super.firstUpdated(t),this.registerPagePanels(),this.syncExpandingActionsToNavbar(),setTimeout(()=>this.activateInitialPageTab(),20)}getOwnExpandingActions(){return Array.from(this.querySelectorAll("zn-expanding-action")).filter(t=>t.closest("zn-page")===this)}getNavbar(){var t;return((t=this.shadowRoot)==null?void 0:t.querySelector("zn-navbar"))||null}refreshExpandingActionsState(){var o;let t=this.getNavbar(),i=!!(t!=null&&t.querySelector("zn-expanding-action")||(o=t==null?void 0:t.shadowRoot)!=null&&o.querySelector("zn-expanding-action")),n=this.getOwnExpandingActions().length>0||i;this.hasExpandingActions!==n&&(this.hasExpandingActions=n)}syncExpandingActionsToNavbar(){let t=this.getNavbar();t&&(this.getOwnExpandingActions().forEach(i=>t.addExpandingAction(i)),this.refreshExpandingActionsState())}prepareTabs(){let t=[],i=new Set;Array.from(this.children).filter(o=>o.tagName==="ZN-TAB").forEach((o,s)=>{let l=o.getAttribute("caption")||"Tab",d=o.getAttribute("id"),c=this.uniqueId(d!==null?d:this.captionToId(l),i),f=this.parsePriority(o.getAttribute("priority")),p=o.getAttribute("uri"),h=p?null:`page-tab-${s}`,m=o.hasAttribute("selected");o.id=c,p||(o.slot=h),t.push({id:c,caption:l,priority:f,sourceIndex:s,uri:p,slotName:h,selected:m})}),this.tabDefinitions=t.sort((o,s)=>this.compareTabs(o,s))}parsePriority(t){if(t===null||t.trim()==="")return null;let i=Number(t);return Number.isFinite(i)?i:null}compareTabs(t,i){return t.id===""&&i.id!==""?-1:t.id!==""&&i.id===""?1:t.priority!==null&&i.priority!==null&&t.priority!==i.priority?t.priority-i.priority:t.priority!==null&&i.priority===null?-1:t.priority===null&&i.priority!==null?1:t.sourceIndex-i.sourceIndex}captionToId(t){return t.trim().toLowerCase()==="overview"?"":t.trim().toLowerCase().replace(/[^a-z0-9]+/g,"-").replace(/^-+|-+$/g,"")||"tab"}uniqueId(t,i){let n=t,o=2;for(;i.has(n);)n=t===""?`tab-${o}`:`${t}-${o}`,o+=1;return i.add(n),n}handlePageScroll(t){let i=t.currentTarget.scrollTop>24;this.scrolled!==i&&(this.scrolled=i)}updated(t){super.updated(t),t.has("tabDefinitions")&&this.registerPagePanels(),(t.has("tabDefinitions")||t.has("hasExpandingActions"))&&this.syncExpandingActionsToNavbar()}handleNavigationSelect(t){let i=t.detail.item,n=i.getAttribute("tab-uri"),o=i.getAttribute("tab");if(n){this.clickTab(i,!1),this.syncNavigationActive(i);return}o!==null&&this.activateTab(o,!0)}activateTab(t,i){var o;this.setActiveTab(t,i,!1);let n=(o=this.shadowRoot)==null?void 0:o.querySelector(`zn-navbar li[tab="${CSS.escape(t)}"]`);n&&this.syncNavigationActive(n)}activateInitialPageTab(){var o;let t=this.tabDefinitions.find(s=>s.selected);if(t){this.activateTabDefinition(t);return}let i=(o=this.shadowRoot)==null?void 0:o.querySelector("#content > div[selected]"),n=this.tabDefinitions[0];!i&&n&&this.activateTab(n.id,!1)}activateTabDefinition(t){if(t.uri){let i=this.findNavItemForUri(t.uri);if(i){this.clickTab(i,!1),this.syncNavigationActive(i);return}}this.activateTab(t.id,!1)}findNavItemForUri(t){var n,o;let i=(o=(n=this.shadowRoot)==null?void 0:n.querySelectorAll("zn-navbar li[tab-uri]"))!=null?o:[];for(let s of Array.from(i))if(s.getAttribute("tab-uri")===t)return s;return null}registerPagePanels(){var t;(t=this.shadowRoot)==null||t.querySelectorAll("#content > div[id]").forEach(i=>{this._addPanel(i)}),this.registerPageNavigationTabs(),setTimeout(()=>this.registerPageNavigationTabs())}registerPageNavigationTabs(){var t,i;(t=this.shadowRoot)==null||t.querySelectorAll("zn-navbar li[tab], zn-navbar li[tab-uri]").forEach(n=>this._addTab(n)),(i=this.shadowRoot)==null||i.querySelectorAll("zn-navbar").forEach(n=>{var o;(o=n.shadowRoot)==null||o.querySelectorAll("li[tab], li[tab-uri]").forEach(s=>this._addTab(s))})}syncNavigationActive(t){var n;(((n=this.shadowRoot)==null?void 0:n.querySelectorAll("zn-navbar li[tab], zn-navbar li[tab-uri]"))||[]).forEach(o=>{let s=o===t;o.classList.toggle("active",s),o.classList.toggle("zn-tb-active",s)})}render(){let t=!this.modal&&!this.nested&&this.pageSlotController.test("breadcrumb"),i=this.tabDefinitions.length>1||this.hasExpandingActions,n=this.entityId,o=this.fullLocation,s=this.previousPath;return C`
|
|
1304
|
+
`}};sr.styles=Q(G2e),_([w({attribute:"master-id",reflect:!0})],sr.prototype,"masterId",2),_([w({attribute:"default-uri",reflect:!0})],sr.prototype,"defaultUri",2),_([w({attribute:"active",reflect:!0})],sr.prototype,"_current",2),_([w({attribute:"split",type:Number,reflect:!0})],sr.prototype,"_split",2),_([w({attribute:"split-min",type:Number,reflect:!0})],sr.prototype,"_splitMin",2),_([w({attribute:"split-min-secondary",type:Number,reflect:!0})],sr.prototype,"_splitMinSecondary",2),_([w({attribute:"split-max",type:Number,reflect:!0})],sr.prototype,"_splitMax",2),_([w({attribute:"primary-caption",reflect:!0})],sr.prototype,"primaryCaption",2),_([w({attribute:"secondary-caption",reflect:!0})],sr.prototype,"secondaryCaption",2),_([w({attribute:"no-prefetch",type:Boolean,reflect:!0})],sr.prototype,"noPrefetch",2),_([w({attribute:"no-cache",type:Boolean,reflect:!0})],sr.prototype,"noCache",2),_([w({attribute:"local-storage",type:Boolean,reflect:!0})],sr.prototype,"localStorage",2),_([w({attribute:"store-key"})],sr.prototype,"storeKey",2),_([w({attribute:"store-ttl",type:Number,reflect:!0})],sr.prototype,"storeTtl",2),_([w({attribute:"padded",type:Boolean,reflect:!0})],sr.prototype,"padded",2),_([w({attribute:"fetch-style",type:String,reflect:!0})],sr.prototype,"fetchStyle",2),_([w({attribute:"full-width",type:Boolean,reflect:!0})],sr.prototype,"fullWidth",2),_([w({attribute:"padded-right",type:Boolean,reflect:!0})],sr.prototype,"paddedRight",2),_([w()],sr.prototype,"monitor",2),_([w()],sr.prototype,"caption",2),_([w()],sr.prototype,"description",2);var $u=sr;sr.define("zn-tabs");var W2e=J`@keyframes rotate-gradient{from{--rotate:0deg}to{--rotate:360deg}}:host{text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;text-transform:none}:host *,:host *::before,:host *::after{box-sizing:border-box;border-width:0;border-style:solid;border-color:rgb(var(--zn-border-color))}[hidden]{display:none !important}.width-container,.form-container,.wide-form-container{height:100%;width:100%;margin:var(--zn-default-margin,0 auto)}.width-container{max-width:var(--zn-container)}.form-container{max-width:var(--zn-container-ph)}.wide-form-container{max-width:var(--zn-container-lg)}@container (width > 1024px){:host{--zn-gutter:16px}}@container (width > 1400px){:host{--zn-gutter:24px}}@container (width > 1500px){:host{--zn-gutter:32px}}:host{display:block;width:100%;height:100%;min-height:0;container-type:inline-size;--zn-page-content-background:var(--zn-body);--zn-page-header-background:var(--zn-page-surface-background,var(--zn-page-background,var(--zn-body)))}:host([panel]){--zn-page-content-background:var(--zn-panel)}:host([panel-head]){--zn-page-header-background:var(--zn-panel)}:host([panel-nav]){--zn-active-nav-background:var(--zn-panel)}.page__header{flex:0 0 auto;position:sticky;top:0;z-index:2;box-sizing:border-box;background:rgba(var(--zn-page-header-background),95%)}.page__header::after{content:"";position:absolute;right:var(--zn-base-gap);bottom:0;left:var(--zn-base-gap);height:1px;background:rgb(var(--zn-border-color));opacity:0;transition:opacity 180ms ease-in-out;pointer-events:none}.page__header--scrolled-no-navigation::after{opacity:1}.header{display:flex;flex-direction:column;position:relative;margin:0;padding:calc(var(--zn-base-px) * 3) var(--zn-base-gap) calc(var(--zn-base-px) * 3 - var(--zn-base-gap)) var(--zn-base-gap)}.header.header--has-navigation{padding:calc(var(--zn-base-px) * 3) var(--zn-base-gap)}.header .content{display:flex;flex-wrap:wrap;position:relative;width:100%;max-width:100%;height:-moz-fit-content;height:fit-content;gap:var(--zn-base-gap);margin:0 auto;padding:0;box-sizing:border-box}.header--has-navigation .content{min-height:36px}.header .caption{flex-grow:1;display:flex;align-items:flex-start;justify-content:space-between;gap:2px;max-width:100%;min-height:36px}.header .caption a{display:flex;align-items:center;color:inherit;text-decoration:none}.header__left{display:flex;justify-content:flex-start;flex-direction:column;gap:4px;min-height:36px;flex-shrink:1;max-width:100%}.header__right{flex-grow:1;flex-shrink:1;overflow:hidden;min-width:20px}.header__caption{font-weight:var(--zn-text-h1-font-weight);font-size:var(--zn-text-h1-font-size);color:rgba(var(--zn-text-panel-title),100%);line-height:18px;margin:0;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;display:flex;gap:var(--zn-spacing-x-small);align-items:center;text-wrap:auto}.header__description{font-family:var(--zn-font-sans);font-size:var(--zn-text-subheading-font-size);font-weight:var(--zn-text-subheading-font-weight);line-height:var(--zn-text-subheading-line-height);color:var(--zn-text-subheading-color);text-transform:var(--zn-text-subheading-transform);display:block}.header .breadcrumb{display:inline-flex;align-items:center;gap:var(--zn-spacing-2x-small);font:inherit;color:inherit}.header .breadcrumb::slotted(a){font:inherit;color:inherit;text-decoration:inherit}.header .breadcrumb::slotted(a:hover){color:rgb(var(--zn-primary))}.header .breadcrumb::slotted(a)::after{content:">";margin-left:var(--zn-spacing-2x-small);color:rgb(var(--zn-text-muted));font-weight:var(--zn-font-weight-normal)}.header slot{display:flex;align-items:center;flex-wrap:wrap;gap:var(--zn-spacing-x-small);word-break:break-word}.header slot[name=actions]{justify-content:end;flex-wrap:nowrap}.header slot[name=actions]::slotted(zn-button-menu){flex-grow:1;flex-shrink:1}.caption__back{display:flex;justify-content:center;align-items:center;color:inherit}.alt-overlay{display:none}.alt-overlay--visible{display:flex}:host(.alt-pressed) .alt-overlay:empty{display:none !important}:host(.alt-pressed) .alt-overlay{display:flex}.alt-overlay{gap:10px;align-items:flex-end;position:absolute;left:0;top:0;padding:6px 15px;background:rgba(var(--zn-panel),0.95);z-index:10}.alt-overlay a{display:flex}.alt-overlay zn-icon:hover{color:rgb(var(--zn-primary));cursor:pointer}.page{display:flex;flex-direction:column;position:relative;height:100%;min-height:0;max-height:100%;width:100%;max-width:100%;overflow:auto;box-sizing:border-box;padding:0}.page__tabs{flex-grow:1;display:flex;flex-direction:column;min-height:0;width:100%;overflow:visible;box-sizing:border-box;padding:0 var(--zn-base-gap) var(--zn-base-gap);background:rgb(var(--zn-page-content-background,var(--zn-body)))}.page__tabs .page__content{display:flex;flex-direction:column;flex-grow:1;min-height:0;max-width:100%;width:100%;overflow:visible;box-sizing:border-box}.page__tabs #content ::slotted(zn-tab){display:block !important}:host([flush]) .page__tabs,:host([flush]) .page__tabs .page__content#content{padding:0}zn-navbar::part(navbar){height:40px;min-height:40px;max-height:40px;padding-left:var(--zn-base-gap);margin:0}zn-navbar::part(navbar-item){height:40px;box-sizing:border-box;font-size:var(--zn-font-size-medium);line-height:16px}:host .page__header{padding-inline:0}:host .header{padding-inline:calc(var(--zn-gutter,0) + var(--zn-base-gap,0))}:host zn-navbar::part(navbar){padding-inline:calc(var(--zn-gutter,0) + var(--zn-base-gap,0))}:host .page__tabs{padding:0}:host .page__tabs #content.page__content{padding:0 var(--zn-gutter,0)}`;var ba=class extends $u{constructor(){super(...arguments);this.pageSlotController=new Je(this,"breadcrumb","actions","caption");this.modal=!1;this.nested=!1;this.primary=!1;this.scrolled=!1;this.tabDefinitions=[];this.hasExpandingActions=!1;this.actionObserver=null;this.tabObserver=null;this.handleAltPress=()=>{this.classList.toggle("alt-pressed",!0)};this.handleAltUp=()=>{this.classList.toggle("alt-pressed",!1)};this._registerTabs=()=>{this.registerPageNavigationTabs()}}async connectedCallback(){let t=super.connectedCallback();window.addEventListener("alt-press",this.handleAltPress),window.addEventListener("alt-up",this.handleAltUp),this.prepareTabs(),this.refreshExpandingActionsState(),this.tabObserver=new MutationObserver(i=>{i.some(n=>n.type==="childList")&&this.prepareTabs()}),this.tabObserver.observe(this,{childList:!0}),this.actionObserver=new MutationObserver(i=>{i.some(n=>n.type==="childList")&&(this.refreshExpandingActionsState(),this.syncExpandingActionsToNavbar())}),this.actionObserver.observe(this,{childList:!0,subtree:!0}),await t}disconnectedCallback(){var t,i;super.disconnectedCallback(),window.removeEventListener("alt-press",this.handleAltPress),window.removeEventListener("alt-up",this.handleAltUp),(t=this.tabObserver)==null||t.disconnect(),this.tabObserver=null,(i=this.actionObserver)==null||i.disconnect(),this.actionObserver=null}firstUpdated(t){super.firstUpdated(t),this.registerPagePanels(),this.syncExpandingActionsToNavbar(),setTimeout(()=>this.activateInitialPageTab(),20)}getOwnExpandingActions(){return Array.from(this.querySelectorAll("zn-expanding-action")).filter(t=>t.closest("zn-page")===this)}getNavbar(){var t;return((t=this.shadowRoot)==null?void 0:t.querySelector("zn-navbar"))||null}refreshExpandingActionsState(){var o;let t=this.getNavbar(),i=!!(t!=null&&t.querySelector("zn-expanding-action")||(o=t==null?void 0:t.shadowRoot)!=null&&o.querySelector("zn-expanding-action")),n=this.getOwnExpandingActions().length>0||i;this.hasExpandingActions!==n&&(this.hasExpandingActions=n)}syncExpandingActionsToNavbar(){let t=this.getNavbar();t&&(this.getOwnExpandingActions().forEach(i=>t.addExpandingAction(i)),this.refreshExpandingActionsState())}prepareTabs(){let t=[],i=new Set;Array.from(this.children).filter(o=>o.tagName==="ZN-TAB").forEach((o,s)=>{let l=o.getAttribute("caption")||"Tab",d=o.getAttribute("id"),c=this.uniqueId(d!==null?d:this.captionToId(l),i),f=this.parsePriority(o.getAttribute("priority")),p=o.getAttribute("uri"),h=p?null:`page-tab-${s}`,m=o.hasAttribute("selected");o.id=c,p||(o.slot=h),t.push({id:c,caption:l,priority:f,sourceIndex:s,uri:p,slotName:h,selected:m})}),this.tabDefinitions=t.sort((o,s)=>this.compareTabs(o,s))}parsePriority(t){if(t===null||t.trim()==="")return null;let i=Number(t);return Number.isFinite(i)?i:null}compareTabs(t,i){return t.id===""&&i.id!==""?-1:t.id!==""&&i.id===""?1:t.priority!==null&&i.priority!==null&&t.priority!==i.priority?t.priority-i.priority:t.priority!==null&&i.priority===null?-1:t.priority===null&&i.priority!==null?1:t.sourceIndex-i.sourceIndex}captionToId(t){return t.trim().toLowerCase()==="overview"?"":t.trim().toLowerCase().replace(/[^a-z0-9]+/g,"-").replace(/^-+|-+$/g,"")||"tab"}uniqueId(t,i){let n=t,o=2;for(;i.has(n);)n=t===""?`tab-${o}`:`${t}-${o}`,o+=1;return i.add(n),n}handlePageScroll(t){let i=t.currentTarget.scrollTop>24;this.scrolled!==i&&(this.scrolled=i)}updated(t){super.updated(t),t.has("tabDefinitions")&&this.registerPagePanels(),(t.has("tabDefinitions")||t.has("hasExpandingActions"))&&this.syncExpandingActionsToNavbar()}handleNavigationSelect(t){let i=t.detail.item,n=i.getAttribute("tab-uri"),o=i.getAttribute("tab");if(n){this.clickTab(i,!1),this.syncNavigationActive(i);return}o!==null&&this.activateTab(o,!0)}activateTab(t,i){var o;this.setActiveTab(t,i,!1);let n=(o=this.shadowRoot)==null?void 0:o.querySelector(`zn-navbar li[tab="${CSS.escape(t)}"]`);n&&this.syncNavigationActive(n)}activateInitialPageTab(){var o;let t=this.tabDefinitions.find(s=>s.selected);if(t){this.activateTabDefinition(t);return}let i=(o=this.shadowRoot)==null?void 0:o.querySelector("#content > div[selected]"),n=this.tabDefinitions[0];!i&&n&&this.activateTab(n.id,!1)}activateTabDefinition(t){if(t.uri){let i=this.findNavItemForUri(t.uri);if(i){this.clickTab(i,!1),this.syncNavigationActive(i);return}}this.activateTab(t.id,!1)}findNavItemForUri(t){var n,o;let i=(o=(n=this.shadowRoot)==null?void 0:n.querySelectorAll("zn-navbar li[tab-uri]"))!=null?o:[];for(let s of Array.from(i))if(s.getAttribute("tab-uri")===t)return s;return null}registerPagePanels(){var t;(t=this.shadowRoot)==null||t.querySelectorAll("#content > div[id]").forEach(i=>{this._addPanel(i)}),this.registerPageNavigationTabs(),setTimeout(()=>this.registerPageNavigationTabs())}registerPageNavigationTabs(){var t,i;(t=this.shadowRoot)==null||t.querySelectorAll("zn-navbar li[tab], zn-navbar li[tab-uri]").forEach(n=>this._addTab(n)),(i=this.shadowRoot)==null||i.querySelectorAll("zn-navbar").forEach(n=>{var o;(o=n.shadowRoot)==null||o.querySelectorAll("li[tab], li[tab-uri]").forEach(s=>this._addTab(s))})}syncNavigationActive(t){var n;(((n=this.shadowRoot)==null?void 0:n.querySelectorAll("zn-navbar li[tab], zn-navbar li[tab-uri]"))||[]).forEach(o=>{let s=o===t;o.classList.toggle("active",s),o.classList.toggle("zn-tb-active",s)})}render(){let t=!this.modal&&!this.nested&&this.pageSlotController.test("breadcrumb"),i=this.tabDefinitions.length>1||this.hasExpandingActions,n=this.entityId,o=this.fullLocation,s=this.previousPath;return C`
|
|
1305
1305
|
<div class="page" part="base" @scroll="${this.handlePageScroll}">
|
|
1306
1306
|
<div class="${ie({page__header:!0,"page__header--scrolled-no-navigation":this.scrolled&&!i})}" part="header">
|
|
1307
1307
|
<div class="${ie({header:!0,"header--has-breadcrumb":t,"header--has-entity-id":n,"header--has-full-location":o,"header--has-navigation":i,"header--has-previous":s})}">
|
package/package.json
CHANGED