@swiftwc/ui 0.0.0-dev.92 → 0.0.0-dev.94
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/generated/components/alert-dialog.d.ts +1 -2
- package/generated/components/alert-dialog.js +1 -2
- package/generated/components/body-view.d.ts +8 -0
- package/generated/components/body-view.js +3 -0
- package/generated/components/bordered-button.d.ts +2 -2
- package/generated/components/bordered-button.js +2 -2
- package/generated/components/bordered-prominent-button.d.ts +2 -2
- package/generated/components/bordered-prominent-button.js +2 -2
- package/generated/components/borderless-button.d.ts +2 -2
- package/generated/components/borderless-button.js +2 -2
- package/generated/components/color-scheme.d.ts +5 -0
- package/generated/components/content-unavailable.d.ts +30 -0
- package/generated/components/{content-unavailable-view.js → content-unavailable.js} +8 -8
- package/generated/components/date-picker.d.ts +10 -5
- package/generated/components/date-picker.js +19 -11
- package/generated/components/fine-tooltip.d.ts +5 -0
- package/generated/components/form-view.d.ts +5 -0
- package/generated/components/glass-button.d.ts +2 -2
- package/generated/components/glass-button.js +2 -2
- package/generated/components/glass-prominent-button.d.ts +2 -2
- package/generated/components/glass-prominent-button.js +2 -2
- package/generated/components/h-stack.d.ts +6 -1
- package/generated/components/h-stack.js +1 -1
- package/generated/components/image-view.d.ts +5 -0
- package/generated/components/index.d.ts +1 -1
- package/generated/components/index.js +1 -1
- package/generated/components/label-view.d.ts +8 -2
- package/generated/components/label-view.js +19 -5
- package/generated/components/labeled-content.d.ts +5 -0
- package/generated/components/labeled-content.js +14 -4
- package/generated/components/list-view.d.ts +5 -0
- package/generated/components/list-view.js +0 -12
- package/generated/components/menu-view.d.ts +6 -1
- package/generated/components/menu-view.js +2 -8
- package/generated/components/navigation-large-title.d.ts +5 -0
- package/generated/components/navigation-split-view.d.ts +5 -0
- package/generated/components/navigation-stack.d.ts +5 -0
- package/generated/components/navigation-stack.js +0 -2
- package/generated/components/navigation-title.d.ts +5 -0
- package/generated/components/navigation-title.js +0 -9
- package/generated/components/picker-view.d.ts +10 -4
- package/generated/components/picker-view.js +18 -15
- package/generated/components/progress-view.d.ts +5 -0
- package/generated/components/progress-view.js +1 -1
- package/generated/components/scroll-view-proxy.d.ts +5 -0
- package/generated/components/scroll-view.d.ts +5 -0
- package/generated/components/scroll-view.js +0 -1
- package/generated/components/search-view.d.ts +5 -0
- package/generated/components/search-view.js +0 -3
- package/generated/components/section-view.d.ts +6 -1
- package/generated/components/section-view.js +3 -48
- package/generated/components/sheet-view.js +0 -20
- package/generated/components/sidebar-toggle.d.ts +6 -1
- package/generated/components/sidebar-toggle.js +6 -6
- package/generated/components/sidebar-view.js +1 -1
- package/generated/components/sticky-container.d.ts +6 -1
- package/generated/components/sticky-container.js +5 -5
- package/generated/components/tab-bar.js +0 -3
- package/generated/components/tab-view.d.ts +7 -2
- package/generated/components/tab-view.js +0 -70
- package/generated/components/table-view.d.ts +5 -0
- package/generated/components/table-view.js +2 -2
- package/generated/components/text-field.d.ts +10 -5
- package/generated/components/text-field.js +39 -17
- package/generated/components/toggle-view.d.ts +13 -4
- package/generated/components/toggle-view.js +16 -12
- package/generated/components/tool-bar-item-group.d.ts +5 -0
- package/generated/components/tool-bar-item.d.ts +5 -0
- package/generated/components/tool-bar.d.ts +5 -0
- package/generated/components/v-keyboard.d.ts +5 -0
- package/generated/components/v-stack.d.ts +6 -1
- package/generated/components/v-stack.js +1 -1
- package/generated/css/index.css +24 -17
- package/generated/events/alert-dialog.d.ts +3 -1
- package/generated/events/confirmation-dialog.d.ts +3 -1
- package/generated/events/date-picker.d.ts +3 -1
- package/generated/events/lifecycle-observer.d.ts +6 -2
- package/generated/events/picker-view.d.ts +12 -4
- package/generated/events/scroll-view.d.ts +6 -2
- package/generated/events/scroll-view.js +0 -4
- package/generated/events/tab-view.d.ts +24 -8
- package/generated/events/text-field.d.ts +3 -1
- package/generated/events/text-field.js +0 -3
- package/generated/events/toggle-view.d.ts +3 -1
- package/generated/events/toggle-view.js +0 -3
- package/generated/internal/class/form-associated-base.js +1 -1
- package/generated/internal/utils/ensure-placeholder.js +0 -55
- package/generated/internal/utils/kebab-case.js +6 -9
- package/package.json +1 -1
- package/scss/_components.scss +1 -1
- package/scss/components/{_content-unavailable-view.scss → _content-unavailable.scss} +1 -1
- package/scss/components/_index.scss +5 -4
- package/scss/components/_labeled-content.scss +8 -0
- package/scss/components/_navigation-title.scss +1 -1
- package/scss/components/_toggle-view.scss +1 -1
- package/web-components.html-data/en.json +89 -31
- package/generated/components/content-unavailable-view.d.ts +0 -25
|
@@ -14,15 +14,31 @@ export type TabViewAdaptableTabBarPlacementDetail = {
|
|
|
14
14
|
oldValue?: TabBarPlacement;
|
|
15
15
|
newValue?: TabBarPlacement;
|
|
16
16
|
};
|
|
17
|
+
export interface TabshowEvent extends CustomEvent<TabDetail> {
|
|
18
|
+
}
|
|
19
|
+
export interface TabhideEvent extends CustomEvent<TabDetail> {
|
|
20
|
+
}
|
|
21
|
+
export interface TabrevealEvent extends CustomEvent<TabDetail> {
|
|
22
|
+
}
|
|
23
|
+
export interface TabswapEvent extends CustomEvent<TabDetail> {
|
|
24
|
+
}
|
|
25
|
+
export interface BeforetabrevealEvent extends CustomEvent<TabBeforeDetail> {
|
|
26
|
+
}
|
|
27
|
+
export interface BeforetabswapEvent extends CustomEvent<TabBeforeDetail> {
|
|
28
|
+
}
|
|
29
|
+
export interface TabViewToggleEvent extends CustomEvent<TabViewDetail> {
|
|
30
|
+
}
|
|
31
|
+
export interface TabViewAdaptableTabBarPlacementChangeEvent extends CustomEvent<TabViewAdaptableTabBarPlacementDetail> {
|
|
32
|
+
}
|
|
17
33
|
declare global {
|
|
18
34
|
interface HTMLElementEventMap {
|
|
19
|
-
tabshow:
|
|
20
|
-
tabhide:
|
|
21
|
-
tabreveal:
|
|
22
|
-
tabswap:
|
|
23
|
-
beforetabreveal:
|
|
24
|
-
beforetabswap:
|
|
25
|
-
'tab-view:toggle':
|
|
26
|
-
'tab-view:adaptable-tab-bar-placement-change':
|
|
35
|
+
tabshow: TabshowEvent;
|
|
36
|
+
tabhide: TabhideEvent;
|
|
37
|
+
tabreveal: TabrevealEvent;
|
|
38
|
+
tabswap: TabswapEvent;
|
|
39
|
+
beforetabreveal: BeforetabrevealEvent;
|
|
40
|
+
beforetabswap: BeforetabswapEvent;
|
|
41
|
+
'tab-view:toggle': TabViewToggleEvent;
|
|
42
|
+
'tab-view:adaptable-tab-bar-placement-change': TabViewAdaptableTabBarPlacementChangeEvent;
|
|
27
43
|
}
|
|
28
44
|
}
|
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
export type TextFieldCommitDetail = {
|
|
2
2
|
text: string;
|
|
3
3
|
};
|
|
4
|
+
export interface TextFieldCommitEvent extends CustomEvent<TextFieldCommitDetail> {
|
|
5
|
+
}
|
|
4
6
|
declare global {
|
|
5
7
|
interface HTMLElementEventMap {
|
|
6
|
-
commit:
|
|
8
|
+
commit: TextFieldCommitEvent;
|
|
7
9
|
}
|
|
8
10
|
}
|
|
@@ -2,8 +2,10 @@ export type ToggleChangeDetail = {
|
|
|
2
2
|
isOn: boolean;
|
|
3
3
|
value: string | null;
|
|
4
4
|
};
|
|
5
|
+
export interface ToggleChangeEvent extends CustomEvent<ToggleChangeDetail> {
|
|
6
|
+
}
|
|
5
7
|
declare global {
|
|
6
8
|
interface HTMLElementEventMap {
|
|
7
|
-
'toggle:change':
|
|
9
|
+
'toggle:change': ToggleChangeEvent;
|
|
8
10
|
}
|
|
9
11
|
}
|
|
@@ -29,7 +29,7 @@ export class FormAssociatedBase extends HTMLElement {
|
|
|
29
29
|
}
|
|
30
30
|
constructor() {
|
|
31
31
|
super();
|
|
32
|
-
internals.set(this, this.attachInternals());
|
|
32
|
+
internals.set(this, this.attachInternals?.());
|
|
33
33
|
// trackedElements.set(this, new Set<Element>())
|
|
34
34
|
}
|
|
35
35
|
disconnectedCallback() {
|
|
@@ -1,63 +1,10 @@
|
|
|
1
1
|
import { I18n } from '../../i18n';
|
|
2
2
|
import { html, queryMorph } from '../../morphdom';
|
|
3
|
-
// type ButtonRole = keyof ReturnType<typeof I18n.t<'ButtonRole'>>
|
|
4
|
-
// function renderPlaceholder(el: HTMLElement, role: string | null, titleKey?: ButtonRole, config?: Record<string, string>) {
|
|
5
|
-
// // if (!el.isConnected) return
|
|
6
|
-
// // self.requestAnimationFrame(() => {
|
|
7
|
-
// // if (!el.isConnected) return
|
|
8
|
-
// let title: string | undefined, systemImage: string | undefined
|
|
9
|
-
// // const label = el.querySelector(':scope>[slot=placeholder]') ?? el.appendChild($(`<label-view slot="placeholder"></label-view>`, '>1'))
|
|
10
|
-
// switch (role) {
|
|
11
|
-
// case 'cancel':
|
|
12
|
-
// title = titleKey && titleKey in I18n.t('ButtonRole') ? I18n.t('ButtonRole')[titleKey] : I18n.t('ButtonRole').Cancel //label.setAttribute('title', titleKey && titleKey in I18n.t('ButtonRole') ? I18n.t('ButtonRole')[titleKey] : I18n.t('ButtonRole').Cancel)
|
|
13
|
-
// systemImage = config?.['cancel-button-icon'] ?? '' //label.setAttribute('system-image', config?.['cancel-button-icon'] ?? '')
|
|
14
|
-
// break
|
|
15
|
-
// case 'close':
|
|
16
|
-
// if (el.closest('[is=alert-dialog]')) {
|
|
17
|
-
// title = titleKey && titleKey in I18n.t('ButtonRole') ? I18n.t('ButtonRole')[titleKey] : I18n.t('ButtonRole').OK //.setAttribute('title', titleKey && titleKey in I18n.t('ButtonRole') ? I18n.t('ButtonRole')[titleKey] : I18n.t('ButtonRole').OK)
|
|
18
|
-
// } else {
|
|
19
|
-
// title = titleKey && titleKey in I18n.t('ButtonRole') ? I18n.t('ButtonRole')[titleKey] : I18n.t('ButtonRole').Close //label.setAttribute('title', titleKey && titleKey in I18n.t('ButtonRole') ? I18n.t('ButtonRole')[titleKey] : I18n.t('ButtonRole').Close)
|
|
20
|
-
// systemImage = config?.['close-button-icon'] ?? '' //label.setAttribute('system-image', config?.['close-button-icon'] ?? '')
|
|
21
|
-
// }
|
|
22
|
-
// break
|
|
23
|
-
// case 'confirm':
|
|
24
|
-
// title = titleKey && titleKey in I18n.t('ButtonRole') ? I18n.t('ButtonRole')[titleKey] : I18n.t('ButtonRole').Confirm //label.setAttribute('title', titleKey && titleKey in I18n.t('ButtonRole') ? I18n.t('ButtonRole')[titleKey] : I18n.t('ButtonRole').Confirm)
|
|
25
|
-
// systemImage = config?.['confirm-button-icon'] ?? '' //label.setAttribute('system-image', config?.['confirm-button-icon'] ?? '')
|
|
26
|
-
// break
|
|
27
|
-
// case 'confirmation-action':
|
|
28
|
-
// title = titleKey && titleKey in I18n.t('ButtonRole') ? I18n.t('ButtonRole')[titleKey] : I18n.t('ButtonRole').Confirm //label.setAttribute('title', titleKey && titleKey in I18n.t('ButtonRole') ? I18n.t('ButtonRole')[titleKey] : I18n.t('ButtonRole').Confirm)
|
|
29
|
-
// systemImage = config?.['confirm-button-icon'] ?? '' //label.setAttribute('system-image', config?.['confirm-button-icon'] ?? '')
|
|
30
|
-
// break
|
|
31
|
-
// case 'cancellation-action':
|
|
32
|
-
// title = titleKey && titleKey in I18n.t('ButtonRole') ? I18n.t('ButtonRole')[titleKey] : I18n.t('ButtonRole').Cancel //label.setAttribute('title', titleKey && titleKey in I18n.t('ButtonRole') ? I18n.t('ButtonRole')[titleKey] : I18n.t('ButtonRole').Cancel)
|
|
33
|
-
// systemImage = config?.['cancel-button-icon'] ?? '' //label.setAttribute('system-image', config?.['cancel-button-icon'] ?? '')
|
|
34
|
-
// break
|
|
35
|
-
// case 'destructive':
|
|
36
|
-
// title = titleKey && titleKey in I18n.t('ButtonRole') ? I18n.t('ButtonRole')[titleKey] : I18n.t('ButtonRole').Destructive // label.setAttribute('title', titleKey && titleKey in I18n.t('ButtonRole') ? I18n.t('ButtonRole')[titleKey] : I18n.t('ButtonRole').Destructive)
|
|
37
|
-
// systemImage = config?.['delete-button-icon'] ?? '' // label.setAttribute('system-image', config?.['delete-button-icon'] ?? '')
|
|
38
|
-
// break
|
|
39
|
-
// // default:
|
|
40
|
-
// // label?.remove()
|
|
41
|
-
// // break
|
|
42
|
-
// }
|
|
43
|
-
// queryMorph(
|
|
44
|
-
// '[slot=placeholder]',
|
|
45
|
-
// html`<label-view slot="placeholder">${systemImage ? html`<image-view slot="icon" system-name="${systemImage}"></image-view>` : null}${title ? html`<span>${title}</span>` : null}</label-view>`,
|
|
46
|
-
// el,
|
|
47
|
-
// { removeIf: !title }
|
|
48
|
-
// )
|
|
49
|
-
// // if (role) {
|
|
50
|
-
// // label.setAttribute('title', I18n.t('ButtonRole').Default.Destructive)
|
|
51
|
-
// // } else label?.remove()
|
|
52
|
-
// // })
|
|
53
|
-
// }
|
|
54
3
|
export default function (target, role, titleKey, config) {
|
|
55
4
|
if (!target)
|
|
56
5
|
return;
|
|
57
6
|
const overiderTitle = typeof titleKey === 'string' && titleKey in I18n.t('ButtonRole') ? titleKey : undefined;
|
|
58
|
-
// renderPlaceholder(target, role, overiderTitle, config)
|
|
59
7
|
let title, systemImage;
|
|
60
|
-
// const label = el.querySelector(':scope>[slot=placeholder]') ?? el.appendChild($(`<label-view slot="placeholder"></label-view>`, '>1'))
|
|
61
8
|
switch (role) {
|
|
62
9
|
case 'cancel':
|
|
63
10
|
title = overiderTitle && overiderTitle in I18n.t('ButtonRole') ? I18n.t('ButtonRole')[overiderTitle] : I18n.t('ButtonRole').Cancel;
|
|
@@ -90,6 +37,4 @@ export default function (target, role, titleKey, config) {
|
|
|
90
37
|
break;
|
|
91
38
|
}
|
|
92
39
|
queryMorph('[slot=placeholder]', html `<label-view slot="placeholder">${systemImage ? html `<image-view slot="icon" system-name="${systemImage}"></image-view>` : null}${title ? html `<span>${title}</span>` : null}</label-view>`, target, { removeIf: !title });
|
|
93
|
-
// CleanupRegistry.unregister(target, 'i18n')
|
|
94
|
-
// CleanupRegistry.register(target, onoff('localechange', () => renderPlaceholder(target, role, overiderTitle), I18n.on).on(), 'i18n')
|
|
95
40
|
}
|
|
@@ -1,11 +1,8 @@
|
|
|
1
1
|
export default function (str) {
|
|
2
|
-
return
|
|
3
|
-
// Replace uppercase letters with - + lowercase
|
|
4
|
-
.replace(/
|
|
5
|
-
//
|
|
6
|
-
.
|
|
7
|
-
//
|
|
8
|
-
.toLowerCase()
|
|
9
|
-
// Remove leading/trailing dashes
|
|
10
|
-
.replace(/^-+|-+$/g, ''));
|
|
2
|
+
return str
|
|
3
|
+
.replace(/([A-Z])/g, '-$1') // Replace uppercase letters with - + lowercase
|
|
4
|
+
.replace(/[\s_]+/g, '-') // Replace spaces and underscores with -
|
|
5
|
+
.replace(/-+/g, '-') // collapse any run of dashes into one
|
|
6
|
+
.toLowerCase() // Convert to lowercase
|
|
7
|
+
.replace(/^-+|-+$/g, ''); // Remove leading/trailing dashes
|
|
11
8
|
}
|
package/package.json
CHANGED
package/scss/_components.scss
CHANGED
|
@@ -7,6 +7,7 @@
|
|
|
7
7
|
navigation-stack,
|
|
8
8
|
navigation-split-view,
|
|
9
9
|
navigation-large-title,
|
|
10
|
+
navigation-title,
|
|
10
11
|
scroll-view,
|
|
11
12
|
body-view,
|
|
12
13
|
tab-view,
|
|
@@ -30,7 +31,7 @@
|
|
|
30
31
|
[is='glass-prominent-button'],
|
|
31
32
|
list-view,
|
|
32
33
|
table-view,
|
|
33
|
-
content-unavailable
|
|
34
|
+
content-unavailable,
|
|
34
35
|
progress-view,
|
|
35
36
|
tool-bar-item,
|
|
36
37
|
tool-bar-item-group,
|
|
@@ -59,9 +60,9 @@
|
|
|
59
60
|
:where(labeled-content)::part(labeled-content-label-stack),
|
|
60
61
|
:where(labeled-content)::part(labeled-content-value-stack),
|
|
61
62
|
:where(progress-view)::part(progress-control),
|
|
62
|
-
:where(content-unavailable
|
|
63
|
-
:where(content-unavailable
|
|
64
|
-
:where(content-unavailable
|
|
63
|
+
:where(content-unavailable)::part(content-unavailable-title-stack),
|
|
64
|
+
:where(content-unavailable)::part(content-unavailable-description-stack),
|
|
65
|
+
:where(content-unavailable)::part(content-unavailable-actions-stack),
|
|
65
66
|
:where(table-view)::part(table-container),
|
|
66
67
|
:where(table-view)::part(table-column-stack),
|
|
67
68
|
:where(table-view)::part(table-header-stack),
|
|
@@ -1,4 +1,6 @@
|
|
|
1
|
+
@use 'sass:string';
|
|
1
2
|
@use '../vars';
|
|
3
|
+
@use '../mixins';
|
|
2
4
|
|
|
3
5
|
@layer #{vars.$components-layer} {
|
|
4
6
|
labeled-content {
|
|
@@ -61,6 +63,12 @@
|
|
|
61
63
|
> [slot='footer'] {
|
|
62
64
|
:where(&) {
|
|
63
65
|
color: var(--secondary);
|
|
66
|
+
|
|
67
|
+
--label-font: callout;
|
|
68
|
+
|
|
69
|
+
@supports not (x: #{string.unquote('if(else:red)')}) {
|
|
70
|
+
@include mixins.set-label-font(callout);
|
|
71
|
+
}
|
|
64
72
|
}
|
|
65
73
|
}
|
|
66
74
|
}
|
|
@@ -9,10 +9,16 @@
|
|
|
9
9
|
"url": "https://swiftwc.github.io/ui/web-components/alert-dialog"
|
|
10
10
|
}
|
|
11
11
|
],
|
|
12
|
-
"description": "
|
|
12
|
+
"description": ""
|
|
13
13
|
},
|
|
14
14
|
{
|
|
15
15
|
"name": "body-view",
|
|
16
|
+
"references": [
|
|
17
|
+
{
|
|
18
|
+
"name": "Documentation",
|
|
19
|
+
"url": "https://swiftwc.github.io/ui/web-components/body-view"
|
|
20
|
+
}
|
|
21
|
+
],
|
|
16
22
|
"description": ""
|
|
17
23
|
},
|
|
18
24
|
{
|
|
@@ -23,7 +29,7 @@
|
|
|
23
29
|
"url": "https://swiftwc.github.io/ui/web-components/bordered-button"
|
|
24
30
|
}
|
|
25
31
|
],
|
|
26
|
-
"description": "### **Slots:**\n- **overlay**\n\n### **Examples:**\n**Creating a
|
|
32
|
+
"description": "### **Slots:**\n- **overlay**\n\n### **Examples:**\n**Creating a bordered button:**\n```html\n<button is=\"bordered-button\">\n <label-view system-image=\"hand-tap\" title=\"Tap Me\"></label-view>\n</button>\n\n```",
|
|
27
33
|
"attributes": [
|
|
28
34
|
{
|
|
29
35
|
"name": "role",
|
|
@@ -50,7 +56,7 @@
|
|
|
50
56
|
"url": "https://swiftwc.github.io/ui/web-components/bordered-prominent-button"
|
|
51
57
|
}
|
|
52
58
|
],
|
|
53
|
-
"description": "### **Slots:**\n- **overlay**\n\n### **Examples:**\n**
|
|
59
|
+
"description": "### **Slots:**\n- **overlay**\n\n### **Examples:**\n**Creating a prominent bordered button:**\n```html\n<button is=\"bordered-prominent-button\">\n <label-view system-image=\"hand-tap\" title=\"Tap Me\"></label-view>\n</button>\n\n```",
|
|
54
60
|
"attributes": [
|
|
55
61
|
{
|
|
56
62
|
"name": "role",
|
|
@@ -77,7 +83,7 @@
|
|
|
77
83
|
"url": "https://swiftwc.github.io/ui/web-components/borderless-button"
|
|
78
84
|
}
|
|
79
85
|
],
|
|
80
|
-
"description": "### **Slots:**\n- **overlay**\n\n### **Examples:**\n**
|
|
86
|
+
"description": "### **Slots:**\n- **overlay**\n\n### **Examples:**\n**Use the `is` attribute to style a `button` as a `borderless-button`:**\n```html\n<button is=\"borderless-button\">\n <label-view system-image=\"hand-tap\" title=\"Tap Me\"></label-view>\n</button>\n\n```",
|
|
81
87
|
"attributes": [
|
|
82
88
|
{
|
|
83
89
|
"name": "role",
|
|
@@ -121,14 +127,14 @@
|
|
|
121
127
|
"description": "A representation of a confirmation presentation.\nUse it from the client module like `await confirmation(trigger, 'Permanently erase the items in the Trash?')`.\n---"
|
|
122
128
|
},
|
|
123
129
|
{
|
|
124
|
-
"name": "content-unavailable
|
|
130
|
+
"name": "content-unavailable",
|
|
125
131
|
"references": [
|
|
126
132
|
{
|
|
127
133
|
"name": "Documentation",
|
|
128
|
-
"url": "https://swiftwc.github.io/ui/web-components/content-unavailable
|
|
134
|
+
"url": "https://swiftwc.github.io/ui/web-components/content-unavailable"
|
|
129
135
|
}
|
|
130
136
|
],
|
|
131
|
-
"description": "### **Slots:**\n- _default_ — The default slot.\n- **description**\n- **actions**\n\n### **Examples:**\n**Example:**\n```html\n<content-unavailable
|
|
137
|
+
"description": "### **Slots:**\n- _default_ — The default slot.\n- **description**\n- **actions**\n\n### **Examples:**\n**Example:**\n```html\n<content-unavailable search></content-unavailable>\n\n```\n**Example:**\n```html\n<content-unavailable search=\"foo\"></content-unavailable>\n\n```\n**Example:**\n```html\n<content-unavailable padding>\n <label-view title=\"No Mail\">\n <i class=\"ph ph-tray\" slot=\"icon\" foreground=\"secondary\"></i>\n </label-view>\n <label-view\n title=\"New mails you receive will appear here.\"\n foreground=\"secondary\"\n slot=\"description\"\n ></label-view>\n <button is=\"borderless-button\" type=\"button\" tabindex=\"0\" slot=\"actions\">\n <label-view title=\"Switch Account\"></label-view>\n </button>\n</content-unavailable>\n\n```\n**Example:**\n```html\n<content-unavailable padding>\n <label-view title=\"No Mail\">\n <svg slot=\"icon\" foreground=\"secondary\" ...>...</svg>\n </label-view>\n <label-view\n title=\"New mails you receive will appear here.\"\n foreground=\"secondary\"\n slot=\"description\"\n ></label-view>\n <button is=\"borderless-button\" type=\"button\" tabindex=\"0\" slot=\"actions\">\n <label-view title=\"Switch Account\"></label-view>\n </button>\n</content-unavailable>\n\n```",
|
|
132
138
|
"attributes": [
|
|
133
139
|
{
|
|
134
140
|
"name": "search"
|
|
@@ -143,7 +149,7 @@
|
|
|
143
149
|
"url": "https://swiftwc.github.io/ui/web-components/date-picker"
|
|
144
150
|
}
|
|
145
151
|
],
|
|
146
|
-
"description": "### **Properties:**\n- readonly **template** — DocumentFragment\n- readonly **datePickerStyle** — \"graphical\" | \"field\" | \"automatic\"\n- readonly **name** — string
|
|
152
|
+
"description": "### **Properties:**\n- readonly **template** — DocumentFragment\n- readonly **datePickerStyle** — \"graphical\" | \"field\" | \"automatic\"\n- readonly **name** — string\n- readonly **value** — { year: string; month: string; day: string; }\n- readonly **valueAsDate** — Date | null\n- readonly **minimum** — { year: string; month: string; day: string; } | null\n- readonly **maximum** — { year: string; month: string; day: string; } | null",
|
|
147
153
|
"attributes": [
|
|
148
154
|
{
|
|
149
155
|
"name": "date-picker-style",
|
|
@@ -161,7 +167,13 @@
|
|
|
161
167
|
]
|
|
162
168
|
},
|
|
163
169
|
{
|
|
164
|
-
"name": "required"
|
|
170
|
+
"name": "required",
|
|
171
|
+
"description": "Value Type: “required”",
|
|
172
|
+
"values": [
|
|
173
|
+
{
|
|
174
|
+
"name": "required"
|
|
175
|
+
}
|
|
176
|
+
]
|
|
165
177
|
},
|
|
166
178
|
{
|
|
167
179
|
"name": "prompt"
|
|
@@ -176,7 +188,13 @@
|
|
|
176
188
|
"name": "selection"
|
|
177
189
|
},
|
|
178
190
|
{
|
|
179
|
-
"name": "disabled"
|
|
191
|
+
"name": "disabled",
|
|
192
|
+
"description": "Value Type: “disabled”",
|
|
193
|
+
"values": [
|
|
194
|
+
{
|
|
195
|
+
"name": "disabled"
|
|
196
|
+
}
|
|
197
|
+
]
|
|
180
198
|
},
|
|
181
199
|
{
|
|
182
200
|
"name": "minimum"
|
|
@@ -235,7 +253,7 @@
|
|
|
235
253
|
"url": "https://swiftwc.github.io/ui/web-components/glass-button"
|
|
236
254
|
}
|
|
237
255
|
],
|
|
238
|
-
"description": "### **Slots:**\n- **overlay**\n\n### **Examples:**\n**
|
|
256
|
+
"description": "### **Slots:**\n- **overlay**\n\n### **Examples:**\n**Creating a glass button:**\n```html\n<button is=\"glass-button\">\n <label-view system-image=\"hand-tap\" title=\"Tap Me\"></label-view>\n</button>\n\n```",
|
|
239
257
|
"attributes": [
|
|
240
258
|
{
|
|
241
259
|
"name": "role",
|
|
@@ -262,7 +280,7 @@
|
|
|
262
280
|
"url": "https://swiftwc.github.io/ui/web-components/glass-prominent-button"
|
|
263
281
|
}
|
|
264
282
|
],
|
|
265
|
-
"description": "### **Slots:**\n- **overlay**\n\n### **Examples:**\n**
|
|
283
|
+
"description": "### **Slots:**\n- **overlay**\n\n### **Examples:**\n**Creating a prominent glass button:**\n```html\n<button is=\"glass-prominent-button\">\n <label-view system-image=\"hand-tap\" title=\"Tap Me\"></label-view>\n</button>\n\n```",
|
|
266
284
|
"attributes": [
|
|
267
285
|
{
|
|
268
286
|
"name": "role",
|
|
@@ -282,11 +300,11 @@
|
|
|
282
300
|
]
|
|
283
301
|
},
|
|
284
302
|
{
|
|
285
|
-
"name": "
|
|
303
|
+
"name": "h-stack",
|
|
286
304
|
"references": [
|
|
287
305
|
{
|
|
288
306
|
"name": "Documentation",
|
|
289
|
-
"url": "https://swiftwc.github.io/ui/web-components/
|
|
307
|
+
"url": "https://swiftwc.github.io/ui/web-components/h-stack"
|
|
290
308
|
}
|
|
291
309
|
],
|
|
292
310
|
"description": "",
|
|
@@ -338,6 +356,7 @@
|
|
|
338
356
|
"url": "https://swiftwc.github.io/ui/web-components/label-view"
|
|
339
357
|
}
|
|
340
358
|
],
|
|
359
|
+
"description": "### **Slots:**\n- _default_ — Any children without a `slot` attribute are placed in the title block of the label.\n- **icon** — Use the `slot=\"icon\"` attribute to place childen in the icon block of the label.\n\n### **Examples:**\n**Creating a label using a `span` element:**\n```html\n<label-view><span>Hello world!</span></label-view>\n\n```\n**Creating a label using the `title` attribute:**\n```html\n<label-view title=\"Hello world!\"></label-view>\n\n```\n**Creating a label with an icon and a title using the `system-image` attribute:**\n```html\n<label-view system-image=\"hand-waving\"><span>Hello world!</span></label-view>\n\n```\n**Creating a label with an icon and a title using the `icon` slot:**\n```html\n<label-view>\n <i slot=\"icon\" class=\"ph ph-duotone ph-hand-waving\"></i>\n <span>Hello world!</span>\n</label-view>\n\n```",
|
|
341
360
|
"attributes": [
|
|
342
361
|
{
|
|
343
362
|
"name": "font",
|
|
@@ -354,10 +373,15 @@
|
|
|
354
373
|
"name": "line-limit"
|
|
355
374
|
},
|
|
356
375
|
{
|
|
357
|
-
"name": "truncation-mode"
|
|
376
|
+
"name": "truncation-mode",
|
|
377
|
+
"description": "Value Type: “tail”",
|
|
378
|
+
"values": [
|
|
379
|
+
{
|
|
380
|
+
"name": "tail"
|
|
381
|
+
}
|
|
382
|
+
]
|
|
358
383
|
}
|
|
359
|
-
]
|
|
360
|
-
"description": "### **Slots:**\n- _default_ — The default slot.\n- **icon**"
|
|
384
|
+
]
|
|
361
385
|
},
|
|
362
386
|
{
|
|
363
387
|
"name": "labeled-content",
|
|
@@ -375,7 +399,16 @@
|
|
|
375
399
|
"name": "footer"
|
|
376
400
|
},
|
|
377
401
|
{
|
|
378
|
-
"name": "labeled-content-style"
|
|
402
|
+
"name": "labeled-content-style",
|
|
403
|
+
"description": "Value Type: “vertical” | “horizontal”",
|
|
404
|
+
"values": [
|
|
405
|
+
{
|
|
406
|
+
"name": "vertical"
|
|
407
|
+
},
|
|
408
|
+
{
|
|
409
|
+
"name": "horizontal"
|
|
410
|
+
}
|
|
411
|
+
]
|
|
379
412
|
},
|
|
380
413
|
{
|
|
381
414
|
"name": "format"
|
|
@@ -475,6 +508,7 @@
|
|
|
475
508
|
"url": "https://swiftwc.github.io/ui/web-components/picker-view"
|
|
476
509
|
}
|
|
477
510
|
],
|
|
511
|
+
"description": "### **Slots:**\n- _default_ — The default slot.\n- **label**\n- **list**\n- **validity-options**\n\n### **Properties:**\n- **selection** — string\n- readonly **template** — DocumentFragment\n- readonly **pickerStyle** — \"automatic\" | \"menu\" | \"inline\" | \"navigation-link\" | \"sheet\"\n- readonly **name** — string",
|
|
478
512
|
"attributes": [
|
|
479
513
|
{
|
|
480
514
|
"name": "picker-style",
|
|
@@ -530,8 +564,7 @@
|
|
|
530
564
|
}
|
|
531
565
|
]
|
|
532
566
|
}
|
|
533
|
-
]
|
|
534
|
-
"description": "### **Slots:**\n- _default_ — The default slot.\n- **label**\n- **list**\n- **validity-options**\n\n### **Properties:**\n- **selection** — string\n- readonly **template** — DocumentFragment\n- readonly **pickerStyle** — \"automatic\" | \"menu\" | \"inline\" | \"navigation-link\" | \"sheet\"\n- readonly **name** — string Form participation property"
|
|
567
|
+
]
|
|
535
568
|
},
|
|
536
569
|
{
|
|
537
570
|
"name": "plain-button",
|
|
@@ -700,7 +733,7 @@
|
|
|
700
733
|
"url": "https://swiftwc.github.io/ui/web-components/text-field"
|
|
701
734
|
}
|
|
702
735
|
],
|
|
703
|
-
"description": "### **Slots:**\n- **label**\n- **validity-options**\n\n### **Properties:**\n- readonly **keyboardType** — \"decimal-pad\" | \"number-pad\" | \"default\"\n- **text** — string\n- readonly **name** — string
|
|
736
|
+
"description": "### **Slots:**\n- **label**\n- **validity-options**\n\n### **Properties:**\n- readonly **keyboardType** — \"decimal-pad\" | \"number-pad\" | \"default\"\n- **text** — string\n- readonly **name** — string\n- readonly **value** — string\n- readonly **valueAsNumber** — number | \"\"\n- readonly **negativeNumbersAllowed** — boolean",
|
|
704
737
|
"attributes": [
|
|
705
738
|
{
|
|
706
739
|
"name": "prompt"
|
|
@@ -730,16 +763,41 @@
|
|
|
730
763
|
"name": "text-input-autocapitalization"
|
|
731
764
|
},
|
|
732
765
|
{
|
|
733
|
-
"name": "disable-autocorrection"
|
|
766
|
+
"name": "disable-autocorrection",
|
|
767
|
+
"description": ""
|
|
734
768
|
},
|
|
735
769
|
{
|
|
736
|
-
"name": "keyboard-type"
|
|
770
|
+
"name": "keyboard-type",
|
|
771
|
+
"description": "Value Type: “decimal-pad” | “number-pad” | “default”",
|
|
772
|
+
"values": [
|
|
773
|
+
{
|
|
774
|
+
"name": "decimal-pad"
|
|
775
|
+
},
|
|
776
|
+
{
|
|
777
|
+
"name": "number-pad"
|
|
778
|
+
},
|
|
779
|
+
{
|
|
780
|
+
"name": "default"
|
|
781
|
+
}
|
|
782
|
+
]
|
|
737
783
|
},
|
|
738
784
|
{
|
|
739
|
-
"name": "required"
|
|
785
|
+
"name": "required",
|
|
786
|
+
"description": "Value Type: “required”",
|
|
787
|
+
"values": [
|
|
788
|
+
{
|
|
789
|
+
"name": "required"
|
|
790
|
+
}
|
|
791
|
+
]
|
|
740
792
|
},
|
|
741
793
|
{
|
|
742
|
-
"name": "disabled"
|
|
794
|
+
"name": "disabled",
|
|
795
|
+
"description": "Value Type: “disabled”",
|
|
796
|
+
"values": [
|
|
797
|
+
{
|
|
798
|
+
"name": "disabled"
|
|
799
|
+
}
|
|
800
|
+
]
|
|
743
801
|
}
|
|
744
802
|
]
|
|
745
803
|
},
|
|
@@ -751,6 +809,7 @@
|
|
|
751
809
|
"url": "https://swiftwc.github.io/ui/web-components/toggle-view"
|
|
752
810
|
}
|
|
753
811
|
],
|
|
812
|
+
"description": "### **Slots:**\n- **label**\n- **validity-options**\n\n### **Properties:**\n- readonly **toggleStyle** — \"button\" | \"switch\"\n- **isOn** — boolean\n- readonly **name** — string\n- **value** — string | null\n\n### **Events:**\n- **toggle:change** — User toggled the control",
|
|
754
813
|
"attributes": [
|
|
755
814
|
{
|
|
756
815
|
"name": "label"
|
|
@@ -773,8 +832,7 @@
|
|
|
773
832
|
{
|
|
774
833
|
"name": "disabled"
|
|
775
834
|
}
|
|
776
|
-
]
|
|
777
|
-
"description": "### **Slots:**\n- **label**\n- **validity-options**\n\n### **Properties:**\n- readonly **toggleStyle** — \"button\" | \"switch\"\n- **isOn** — boolean\n- readonly **name** — string Form participation property\n- **value** — string | null"
|
|
835
|
+
]
|
|
778
836
|
},
|
|
779
837
|
{
|
|
780
838
|
"name": "tool-bar-item-group",
|
|
@@ -818,11 +876,11 @@
|
|
|
818
876
|
"description": "### **Slots:**\n- **cancellation-action** — The item represents a cancellation action for a modal interface. Places the item in the leading edge of the top bar and on the trailing edge of the bottom bar when fine modal\n- **primary-action** — The item represents a primary action. Places the item in the trailing edge of the top bar and on the trailing edge of the bottom bar when fine modal\n- **confirmation-action** — The item represents a confirmation action for a modal interface. Places the item in the trailing edge of the top bar and on the trailing edge of the bottom bar when fine modal\n- **destructive-action** — The item represents a destructive action for a modal interface. Places the item in the leading edge of the top bar and on the leading edge of the bottom bar when fine modal\n- **top-bar-leading** — Places the item in the leading edge of the top bar\n- **top-bar-principal** — Places the item in the middle of the top bar\n- **top-bar-trailing** — Places the item in the trailing edge of the top bar\n- **bottom-bar-leading** — Places the item in the leading edge of the bottom bar\n- **bottom-bar-principal** — Places the item in the middle of the bottom bar\n- **bottom-bar-trailing** — Places the item in the trailing edge of the bottom bar"
|
|
819
877
|
},
|
|
820
878
|
{
|
|
821
|
-
"name": "
|
|
879
|
+
"name": "v-keyboard",
|
|
822
880
|
"references": [
|
|
823
881
|
{
|
|
824
882
|
"name": "Documentation",
|
|
825
|
-
"url": "https://swiftwc.github.io/ui/web-components/
|
|
883
|
+
"url": "https://swiftwc.github.io/ui/web-components/v-keyboard"
|
|
826
884
|
}
|
|
827
885
|
],
|
|
828
886
|
"description": "BUG: Safari on IOS reports inaccurate innerHeight (which is what we really want) on orientationchange.\nSo we live with a pescy body-scrollbar that shows up on resize on desktops.\n---",
|
|
@@ -839,11 +897,11 @@
|
|
|
839
897
|
]
|
|
840
898
|
},
|
|
841
899
|
{
|
|
842
|
-
"name": "
|
|
900
|
+
"name": "v-stack",
|
|
843
901
|
"references": [
|
|
844
902
|
{
|
|
845
903
|
"name": "Documentation",
|
|
846
|
-
"url": "https://swiftwc.github.io/ui/web-components/
|
|
904
|
+
"url": "https://swiftwc.github.io/ui/web-components/v-stack"
|
|
847
905
|
}
|
|
848
906
|
],
|
|
849
907
|
"description": "",
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @summary A message with a title and extra information that you show when part of your app can’t be used.
|
|
3
|
-
*
|
|
4
|
-
* @example <content-unavailable-view search></content-unavailable-view>
|
|
5
|
-
*
|
|
6
|
-
* @example <content-unavailable-view search="foo"></content-unavailable-view>
|
|
7
|
-
*
|
|
8
|
-
* @example <content-unavailable-view padding><label-view title="No Mail"><i class="ph ph-tray" slot="icon" foreground="secondary"></i></label-view><label-view title="New mails you receive will appear here." foreground="secondary" slot="description"></label-view><button is="borderless-button" type="button" tabindex="0" slot="actions"><label-view title="Switch Account"></label-view></button></content-unavailable-view>
|
|
9
|
-
*
|
|
10
|
-
* @example <content-unavailable-view padding><label-view title="No Mail"><svg slot="icon" foreground="secondary" ...>...</svg></label-view><label-view title="New mails you receive will appear here." foreground="secondary" slot="description"></label-view><button is="borderless-button" type="button" tabindex="0" slot="actions"><label-view title="Switch Account"></label-view></button></content-unavailable-view>
|
|
11
|
-
*
|
|
12
|
-
* @slot — The default slot.
|
|
13
|
-
* @slot description
|
|
14
|
-
* @slot actions
|
|
15
|
-
*
|
|
16
|
-
*/
|
|
17
|
-
export declare class ContentUnavailableView extends HTMLElement {
|
|
18
|
-
#private;
|
|
19
|
-
static get observedAttributes(): string[];
|
|
20
|
-
static get template(): DocumentFragment;
|
|
21
|
-
constructor();
|
|
22
|
-
attributeChangedCallback(name: string, oldValue: string | null, newValue: string | null): void;
|
|
23
|
-
disconnectedCallback(): void;
|
|
24
|
-
connectedCallback(): void;
|
|
25
|
-
}
|