@vonage/vivid 3.0.0-next.5 → 3.0.0-next.50
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/README.md +133 -4
- package/accordion/index.js +2 -2
- package/accordion-item/index.js +26 -18
- package/action-group/index.js +49 -0
- package/badge/index.js +14 -18
- package/banner/index.js +18 -81
- package/breadcrumb/index.js +20 -16
- package/breadcrumb-item/index.js +14 -9
- package/button/index.js +28 -659
- package/calendar/index.js +37 -8
- package/calendar-event/index.js +117 -0
- package/card/index.js +134 -0
- package/checkbox/index.js +173 -0
- package/dialog/index.js +282 -0
- package/divider/index.js +88 -0
- package/elevation/index.js +4 -31
- package/fab/index.js +102 -0
- package/focus/index.js +20 -3
- package/header/index.js +68 -0
- package/icon/index.js +9 -3
- package/index.js +45 -20
- package/layout/index.js +4 -4
- package/lib/accordion-item/accordion-item.d.ts +2 -2
- package/lib/accordion-item/index.d.ts +2 -1
- package/lib/action-group/action-group.d.ts +10 -0
- package/lib/{sidenav-item/sidenav-item.template.d.ts → action-group/action-group.template.d.ts} +2 -2
- package/lib/{sidenav-item → action-group}/index.d.ts +1 -2
- package/lib/badge/badge.d.ts +6 -6
- package/lib/badge/index.d.ts +1 -1
- package/lib/banner/banner.template.d.ts +0 -2
- package/lib/banner/index.d.ts +1 -0
- package/lib/breadcrumb/breadcrumb.template.d.ts +4 -0
- package/lib/breadcrumb-item/breadcrumb-item.d.ts +1 -1
- package/lib/breadcrumb-item/index.d.ts +1 -0
- package/lib/button/button.d.ts +6 -5
- package/lib/button/index.d.ts +2 -19
- package/lib/calendar/calendar.d.ts +3 -1
- package/lib/calendar/index.d.ts +0 -1
- package/lib/calendar-event/calendar-event.d.ts +14 -0
- package/lib/calendar-event/calendar-event.template.d.ts +4 -0
- package/lib/calendar-event/index.d.ts +2 -0
- package/lib/card/card.d.ts +10 -0
- package/lib/{text/text.template.d.ts → card/card.template.d.ts} +2 -2
- package/lib/card/index.d.ts +4 -0
- package/lib/checkbox/checkbox.d.ts +5 -0
- package/lib/checkbox/checkbox.template.d.ts +4 -0
- package/lib/checkbox/index.d.ts +4 -0
- package/lib/components.d.ts +22 -10
- package/lib/dialog/dialog.d.ts +20 -0
- package/lib/dialog/dialog.template.d.ts +4 -0
- package/lib/dialog/index.d.ts +5 -0
- package/lib/divider/divider.d.ts +3 -0
- package/lib/divider/divider.template.d.ts +4 -0
- package/lib/divider/index.d.ts +2 -0
- package/lib/elevation/elevation.d.ts +1 -0
- package/lib/elevation/index.d.ts +1 -1
- package/lib/enums.d.ts +11 -5
- package/lib/fab/fab.d.ts +13 -0
- package/lib/fab/fab.template.d.ts +4 -0
- package/lib/fab/index.d.ts +4 -0
- package/lib/focus/index.d.ts +1 -1
- package/lib/header/header.d.ts +5 -0
- package/lib/header/header.template.d.ts +4 -0
- package/lib/header/index.d.ts +3 -0
- package/lib/icon/icon.d.ts +4 -3
- package/lib/layout/index.d.ts +1 -1
- package/lib/layout/layout.d.ts +3 -3
- package/lib/menu/index.d.ts +11 -0
- package/lib/menu/menu.d.ts +7 -0
- package/lib/menu/menu.template.d.ts +3 -0
- package/lib/nav/index.d.ts +2 -0
- package/lib/nav/nav.d.ts +3 -0
- package/lib/nav/nav.template.d.ts +4 -0
- package/lib/nav-disclosure/index.d.ts +4 -0
- package/lib/nav-disclosure/nav-disclosure.d.ts +10 -0
- package/lib/nav-disclosure/nav-disclosure.template.d.ts +4 -0
- package/lib/nav-item/index.d.ts +4 -0
- package/lib/{sidenav-item/sidenav-item.d.ts → nav-item/nav-item.d.ts} +2 -2
- package/lib/nav-item/nav-item.template.d.ts +4 -0
- package/lib/{text → note}/index.d.ts +1 -1
- package/lib/note/note.d.ts +10 -0
- package/lib/note/note.template.d.ts +5 -0
- package/lib/popup/index.d.ts +1 -1
- package/lib/popup/popup.d.ts +3 -15
- package/lib/progress/progress.d.ts +1 -1
- package/lib/progress-ring/progress-ring.d.ts +2 -1
- package/lib/side-drawer/index.d.ts +1 -1
- package/lib/side-drawer/side-drawer.d.ts +2 -7
- package/lib/side-drawer/side-drawer.template.d.ts +2 -2
- package/lib/text-anchor/text-anchor.d.ts +1 -1
- package/lib/text-field/index.d.ts +4 -0
- package/lib/text-field/text-field.d.ts +23 -0
- package/lib/text-field/text-field.template.d.ts +5 -0
- package/lib/tooltip/tooltip.d.ts +2 -4
- package/menu/index.js +661 -0
- package/nav/index.js +17 -0
- package/nav-disclosure/index.js +90 -0
- package/nav-item/index.js +43 -0
- package/note/index.js +68 -0
- package/package.json +48 -8
- package/popup/index.js +20 -2082
- package/progress/index.js +33 -24
- package/progress-ring/index.js +9 -3
- package/shared/anchor.js +8 -1
- package/shared/aria-global.js +3 -40
- package/shared/base-progress.js +5 -0
- package/shared/button.js +195 -0
- package/shared/calendar-event.js +26 -0
- package/shared/dialog-polyfill.esm.js +858 -0
- package/shared/enums.js +79 -0
- package/shared/es.object.assign.js +7 -6
- package/shared/export.js +972 -0
- package/shared/focus.js +5 -0
- package/shared/focus2.js +11 -0
- package/shared/form-associated.js +557 -0
- package/shared/icon.js +504 -508
- package/shared/index.js +79 -56
- package/shared/index2.js +26 -10
- package/shared/index3.js +2109 -0
- package/shared/iterators.js +61 -0
- package/shared/object-keys.js +13 -0
- package/shared/patterns/focus.d.ts +3 -0
- package/shared/patterns/index.d.ts +1 -0
- package/shared/ref.js +41 -0
- package/shared/text-anchor.js +2 -11
- package/shared/text-anchor.template.js +5 -2
- package/shared/to-string.js +51 -0
- package/shared/web.dom-collections.iterator.js +61 -1074
- package/side-drawer/index.js +33 -51
- package/styles/fonts/SpeziaCompleteVariableItalicWeb.woff +0 -0
- package/styles/fonts/SpeziaCompleteVariableItalicWeb.woff2 +0 -0
- package/styles/fonts/SpeziaCompleteVariableUprightWeb.woff +0 -0
- package/styles/fonts/SpeziaCompleteVariableUprightWeb.woff2 +0 -0
- package/styles/fonts/SpeziaMonoCompleteVariableWeb.woff +0 -0
- package/styles/fonts/SpeziaMonoCompleteVariableWeb.woff2 +0 -0
- package/styles/fonts/spezia.css +11 -11
- package/styles/themes/dark.css +12 -0
- package/styles/themes/light.css +12 -0
- package/styles/typography/desktop.css +72 -0
- package/text-anchor/index.js +8 -1
- package/text-field/index.js +412 -0
- package/tooltip/index.js +19 -21
- package/lib/text/text.d.ts +0 -10
- package/sidenav-item/index.js +0 -38
- package/text/index.js +0 -45
package/README.md
CHANGED
|
@@ -1,7 +1,136 @@
|
|
|
1
|
-
# components
|
|
2
1
|
|
|
3
|
-
|
|
2
|
+
# Vivid UI
|
|
4
3
|
|
|
5
|
-
|
|
4
|
+
Essential UI **web components** for building modern web applications, bound to provide a **safe**, **simple** and **intuitive** interface.
|
|
6
5
|
|
|
7
|
-
|
|
6
|
+
<!-- ! TODO add visual - GIF or image reflecting an easy integration of vivid in code and page result -->
|
|
7
|
+

|
|
8
|
+
|
|
9
|
+
## Installation
|
|
10
|
+
|
|
11
|
+
To integrate Vivid components into your project, run:
|
|
12
|
+
|
|
13
|
+
```bash
|
|
14
|
+
npm install @vonage/vivid # or yarn add @vonage/vivid
|
|
15
|
+
```
|
|
16
|
+
|
|
17
|
+
## Usage
|
|
18
|
+
|
|
19
|
+
Import components in your project via [side effect imports](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/import#import_a_module_for_its_side_effects_only):
|
|
20
|
+
|
|
21
|
+
```js
|
|
22
|
+
import '@vonage/vivid/button';
|
|
23
|
+
```
|
|
24
|
+
|
|
25
|
+
And include in HTML:
|
|
26
|
+
|
|
27
|
+
```html
|
|
28
|
+
<vwc-button label="Click me"></vwc-button>
|
|
29
|
+
```
|
|
30
|
+
|
|
31
|
+
For a full list of components and API, explore the [components docs](https://vivid.deno.dev/components/accordion/) 📚.
|
|
32
|
+
|
|
33
|
+
### Prerequisites
|
|
34
|
+
|
|
35
|
+
The Vivid components library rely on a set of **core styles** to:
|
|
36
|
+
|
|
37
|
+
- Be present in the DOM
|
|
38
|
+
|
|
39
|
+
- Be shared across all components
|
|
40
|
+
|
|
41
|
+
- Apply common design identities (such as colors, typography, spacing etc')
|
|
42
|
+
|
|
43
|
+
- Ensure the components look as intended.
|
|
44
|
+
|
|
45
|
+
As the task of loading css is not trivial, and may vary from project to project, this library does not provide any way to load the css. It is up to the author to load the css in the most appropriate manner for their project.
|
|
46
|
+
|
|
47
|
+
To **include the styles**, css files must be loaded into the project from the `node_modules/@vonage/vivid/styles` folder.
|
|
48
|
+
|
|
49
|
+
The folder contains the following files:
|
|
50
|
+
|
|
51
|
+
- Fonts
|
|
52
|
+
|
|
53
|
+
- `fonts/spezia.css` - Loads the *Spezia* variable font and specifies its font face definition. *Spezia* is Vonage's branded font and is required by most Vivid components. folder also contains the font files
|
|
54
|
+
|
|
55
|
+
- Typography
|
|
56
|
+
|
|
57
|
+
- `typography/desktop.css` - Defines the typography for desktop devices
|
|
58
|
+
|
|
59
|
+
- Themes - only one theme can apply at a time. thus, only one is required to be loaded
|
|
60
|
+
|
|
61
|
+
- `themes/light.css` - Light theme
|
|
62
|
+
|
|
63
|
+
- `themes/dark.css` - Dark theme
|
|
64
|
+
|
|
65
|
+
Note: scss users can simply [forward](https://sass-lang.com/documentation/at-rules/forward) the styles to their scss project:
|
|
66
|
+
|
|
67
|
+
```css
|
|
68
|
+
@forward 'node_modules/@vonage/vivid/styles/fonts/spezia.css';
|
|
69
|
+
@forward 'node_modules/@vonage/vivid/styles/typography/desktop.css';
|
|
70
|
+
@forward 'node_modules/@vonage/vivid/styles/themes/light.css';
|
|
71
|
+
```
|
|
72
|
+
|
|
73
|
+
## Support
|
|
74
|
+
|
|
75
|
+
This library is open source, developed and maintained by the [Vonage Vivid team](Vonage/vivid).
|
|
76
|
+
|
|
77
|
+
For any questions, please open a [bug report](https://github.com/Vonage/vivid-3/issues/new?assignees=&labels=&template=bug_report.md&title=) or [feature request](https://github.com/Vonage/vivid-3/issues/new?assignees=&labels=&template=feature_request.md&title=).
|
|
78
|
+
|
|
79
|
+
## Roadmap
|
|
80
|
+
|
|
81
|
+
- View [components status](https://github.com/orgs/Vonage/projects/6)
|
|
82
|
+
|
|
83
|
+
- [What's on our plate](https://github.com/orgs/Vonage/projects/3/views/7)
|
|
84
|
+
|
|
85
|
+
- See the [open issues](https://github.com/vonage/vivid-3/issues) for a full list of proposed features (and known issues).
|
|
86
|
+
|
|
87
|
+
We publish a *next* release on every successful merge to main, so you never need to wait for a new stable version to make use of any updates.
|
|
88
|
+
|
|
89
|
+
## Contributing
|
|
90
|
+
|
|
91
|
+
Please read [CONTRIBUTING.md](.github/CONTRIBUTING.md) for details on our code of conduct, and the process for submitting pull requests to us.
|
|
92
|
+
|
|
93
|
+
## Versioning
|
|
94
|
+
|
|
95
|
+
We use [SemVer](http://semver.org/) for versioning. For the versions available, see the [npm page](https://www.npmjs.com/package/@vonage/vivid).
|
|
96
|
+
|
|
97
|
+
## Authors
|
|
98
|
+
|
|
99
|
+
See also the list of [contributors](https://github.com/your/project/contributors) who participated in this project.
|
|
100
|
+
|
|
101
|
+
## License
|
|
102
|
+
|
|
103
|
+
This project is licensed under the Apache 2.0 License - see the [LICENSE.md](LICENSE.md) file for details
|
|
104
|
+
|
|
105
|
+
<!-- ## Acknowledgments
|
|
106
|
+
|
|
107
|
+
- Hat tip to anyone whose code was used
|
|
108
|
+
- Inspiration
|
|
109
|
+
- etc -->
|
|
110
|
+
|
|
111
|
+
## Built With
|
|
112
|
+
|
|
113
|
+
- [Fast](https://www.fast.design) - to extend element classes and compile code to native web components
|
|
114
|
+
- [Typescript](https://www.typescriptlang.org) - for ergonomic and type-safe code
|
|
115
|
+
- [Sass](https://sass-lang.com) - for styles authoring extensibility and consistency
|
|
116
|
+
|
|
117
|
+
## Quickstart
|
|
118
|
+
|
|
119
|
+
Global content delivery networks can help quickly integrate content within html pages, fetching content from an URL, skipping local builds entirely.
|
|
120
|
+
Such practice is often used when working on POCs or reproduction environments.
|
|
121
|
+
Tools like [UNPKG](https://unpkg.com), [jsDeliver](https://www.jsdelivr.com), [Skypack](https://www.skypack.dev) etc' are bound to deliver any content registered in the npm registry.
|
|
122
|
+
|
|
123
|
+
The following snippet fully renders a Vivid button component
|
|
124
|
+
|
|
125
|
+
```html
|
|
126
|
+
<!-- import spezia font -->
|
|
127
|
+
<link rel="stylesheet" href="https://unpkg.com/@vonage/vivid@next/styles/fonts/spezia.css">
|
|
128
|
+
|
|
129
|
+
<!-- import light theme style tokens -->
|
|
130
|
+
<link rel="stylesheet" href="https://unpkg.com/@vonage/vivid@next/styles/themes/light.css">
|
|
131
|
+
|
|
132
|
+
<!-- import Vivid button component -->
|
|
133
|
+
<script type="module" src="https://unpkg.com/@vonage/vivid@next/button/index.js"></script>
|
|
134
|
+
|
|
135
|
+
<vwc-button label="Click me" appearance="filled" connotation="cta"></vwc-button>
|
|
136
|
+
```
|
package/accordion/index.js
CHANGED
|
@@ -2,7 +2,7 @@ import { F as FoundationElement, _ as __decorate, a as attr, b as __metadata, h
|
|
|
2
2
|
import { s as styleInject } from '../shared/style-inject.es.js';
|
|
3
3
|
import { c as classNames } from '../shared/class-names.js';
|
|
4
4
|
|
|
5
|
-
var css_248z = ".
|
|
5
|
+
var css_248z = ".base {\n display: flex;\n flex-direction: column;\n}\n\n::slotted(vwc-accordion-item:not(:only-of-type)) {\n border-bottom: 1px solid var(--vvd-color-neutral-30);\n}";
|
|
6
6
|
styleInject(css_248z);
|
|
7
7
|
|
|
8
8
|
class Accordion extends FoundationElement {
|
|
@@ -45,7 +45,7 @@ __decorate([attr({
|
|
|
45
45
|
let _2 = t => t,
|
|
46
46
|
_t;
|
|
47
47
|
|
|
48
|
-
const getClasses = _ => classNames('
|
|
48
|
+
const getClasses = _ => classNames('base');
|
|
49
49
|
|
|
50
50
|
const AccordionTemplate = () => html(_t || (_t = _2`<div class="${0}">
|
|
51
51
|
<slot></slot>
|
package/accordion-item/index.js
CHANGED
|
@@ -1,23 +1,28 @@
|
|
|
1
|
+
import '../icon/index.js';
|
|
2
|
+
import '../focus/index.js';
|
|
1
3
|
import { F as FoundationElement, _ as __decorate, a as attr, b as __metadata, h as html, d as designSystem } from '../shared/index.js';
|
|
2
4
|
import { s as styleInject } from '../shared/style-inject.es.js';
|
|
3
5
|
import '../shared/web.dom-collections.iterator.js';
|
|
4
6
|
import { A as AffixIconWithTrailing, a as affixIconTemplateFactory } from '../shared/affix.js';
|
|
5
7
|
import { a as applyMixins } from '../shared/apply-mixins.js';
|
|
8
|
+
import { f as focusTemplateFactory } from '../shared/focus2.js';
|
|
6
9
|
import { w as when } from '../shared/when.js';
|
|
7
10
|
import { c as classNames } from '../shared/class-names.js';
|
|
8
|
-
import '../icon/index.js';
|
|
9
11
|
import '../shared/icon.js';
|
|
12
|
+
import '../shared/export.js';
|
|
13
|
+
import '../shared/iterators.js';
|
|
14
|
+
import '../shared/to-string.js';
|
|
10
15
|
import '../shared/_has.js';
|
|
16
|
+
import '../shared/focus.js';
|
|
17
|
+
import '../shared/object-keys.js';
|
|
11
18
|
|
|
12
|
-
var css_248z = "/*\n Do not edit directly\n Generated on
|
|
19
|
+
var css_248z = "/*\n Do not edit directly\n Generated on Wed, 27 Apr 2022 11:58:36 GMT\n*/\n.body {\n font: 400 ultra-condensed 14px / 20px SpeziaWebVariable;\n letter-spacing: 0px;\n text-decoration: none;\n text-transform: none;\n padding: 8px 32px 24px 16px;\n}\n.icon:not(.icon-trailing) .body {\n padding-left: 48px;\n}\n\n.base {\n display: flex;\n flex-direction: column;\n}\n.base:not(.open) .body {\n display: none;\n}\n\n.header {\n padding: 0;\n margin: 0;\n}\n\n.button {\n font: 500 condensed 20px / 28px SpeziaWebVariable;\n letter-spacing: 0px;\n text-decoration: none;\n text-transform: none;\n position: relative;\n display: flex;\n width: 100%;\n align-items: center;\n padding: 16px;\n border: 0 none;\n margin: 0;\n background-color: var(--_appearance-color-fill);\n box-shadow: inset 0 0 0 1px var(--_appearance-color-outline);\n color: var(--_appearance-color-text);\n cursor: pointer;\n}\n.button {\n --_appearance-color-text: var(--_connotation-color-primary);\n --_appearance-color-fill: transaprent;\n --_appearance-color-outline: transaprent;\n}\n.button:where(:hover, .hover):where(:not(:disabled, .disabled)) {\n --_appearance-color-text: var(--_connotation-color-primary);\n --_appearance-color-fill: var(--_connotation-color-faint);\n --_appearance-color-outline: transaprent;\n}\n.button:where(:active, .active):where(:not(:disabled, .disabled)) {\n --_appearance-color-text: var(--_connotation-color-primary);\n --_appearance-color-fill: var(--_connotation-color-soft);\n --_appearance-color-outline: transaprent;\n}\n.button {\n --_connotation-color-primary: var(--vvd-color-on-canvas);\n --_connotation-color-faint: var(--vvd-color-neutral-10);\n --_connotation-color-soft: var(--vvd-color-neutral-20);\n}\n@supports selector(:focus-visible) {\n .button:focus {\n outline: none;\n }\n}\n@supports ((-webkit-user-select: none) or (user-select: none)) {\n .button {\n -webkit-user-select: none;\n user-select: none;\n }\n}\n.button .heading-text {\n flex-grow: 1;\n margin-inline-end: auto;\n text-align: left;\n}\n.button .meta {\n font: 600 ultra-condensed 14px / 20px SpeziaWebVariable;\n letter-spacing: 0px;\n text-decoration: none;\n text-transform: none;\n overflow: hidden;\n max-width: 20%;\n flex-shrink: 0;\n color: var(--vvd-color-neutral-70);\n margin-inline-start: 16px;\n text-align: end;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n.button .indicator {\n display: flex;\n}\n.button .indicator vwc-icon,\n.button .indicator slot[name=indicator i]::slotted(vwc-icon) {\n margin-inline-start: 16px;\n}\n.button .icon {\n margin-inline-end: 16px;\n}\n\n/* Icon */\n.icon-trailing .icon {\n order: 1;\n}\n\n.button:not(:focus-visible) > .focus-indicator {\n display: none;\n}";
|
|
13
20
|
styleInject(css_248z);
|
|
14
21
|
|
|
15
22
|
class AccordionItem extends FoundationElement {
|
|
16
23
|
constructor() {
|
|
17
24
|
super(...arguments);
|
|
18
|
-
this.heading = '';
|
|
19
25
|
this.noIndicator = false;
|
|
20
|
-
this.meta = '';
|
|
21
26
|
this.open = false;
|
|
22
27
|
}
|
|
23
28
|
|
|
@@ -40,9 +45,7 @@ class AccordionItem extends FoundationElement {
|
|
|
40
45
|
|
|
41
46
|
}
|
|
42
47
|
|
|
43
|
-
__decorate([attr(
|
|
44
|
-
mode: 'fromView'
|
|
45
|
-
}), __metadata("design:type", Object)], AccordionItem.prototype, "heading", void 0);
|
|
48
|
+
__decorate([attr, __metadata("design:type", String)], AccordionItem.prototype, "heading", void 0);
|
|
46
49
|
|
|
47
50
|
__decorate([attr({
|
|
48
51
|
attribute: 'heading-level'
|
|
@@ -53,9 +56,7 @@ __decorate([attr({
|
|
|
53
56
|
attribute: 'no-indicator'
|
|
54
57
|
}), __metadata("design:type", Object)], AccordionItem.prototype, "noIndicator", void 0);
|
|
55
58
|
|
|
56
|
-
__decorate([attr(
|
|
57
|
-
mode: 'fromView'
|
|
58
|
-
}), __metadata("design:type", Object)], AccordionItem.prototype, "meta", void 0);
|
|
59
|
+
__decorate([attr, __metadata("design:type", String)], AccordionItem.prototype, "meta", void 0);
|
|
59
60
|
|
|
60
61
|
__decorate([attr({
|
|
61
62
|
mode: 'boolean'
|
|
@@ -68,7 +69,9 @@ let _ = t => t,
|
|
|
68
69
|
_t2,
|
|
69
70
|
_t3,
|
|
70
71
|
_t4,
|
|
71
|
-
_t5
|
|
72
|
+
_t5,
|
|
73
|
+
_t6,
|
|
74
|
+
_t7;
|
|
72
75
|
const PANEL = 'panel';
|
|
73
76
|
|
|
74
77
|
const getClasses = ({
|
|
@@ -76,7 +79,7 @@ const getClasses = ({
|
|
|
76
79
|
iconTrailing,
|
|
77
80
|
icon,
|
|
78
81
|
noIndicator
|
|
79
|
-
}) => classNames('
|
|
82
|
+
}) => classNames('base', ['open', open], ['icon', Boolean(icon)], ['icon-trailing', iconTrailing], ['no-indicator', noIndicator]);
|
|
80
83
|
|
|
81
84
|
const AccordionItemTemplate = context => html(_t || (_t = _`
|
|
82
85
|
<div class="${0}">
|
|
@@ -98,10 +101,12 @@ const renderPanelHeader = (context, headingLevel) => {
|
|
|
98
101
|
|
|
99
102
|
const renderHeaderButton = context => {
|
|
100
103
|
const affixIconTemplate = affixIconTemplateFactory(context);
|
|
104
|
+
const focusTemplate = focusTemplateFactory(context);
|
|
101
105
|
return html(_t3 || (_t3 = _`
|
|
102
106
|
<button class="button" id="header" @click=${0}
|
|
103
|
-
|
|
107
|
+
aria-expanded=${0}
|
|
104
108
|
aria-controls="${0}">
|
|
109
|
+
${0}
|
|
105
110
|
${0}
|
|
106
111
|
<span class="heading-text">${0}</span>
|
|
107
112
|
${0}
|
|
@@ -109,16 +114,19 @@ const renderHeaderButton = context => {
|
|
|
109
114
|
${0}
|
|
110
115
|
</span>
|
|
111
116
|
</button>
|
|
112
|
-
`), x => x.open = !x.open, x => x.open, PANEL, x => affixIconTemplate(x.icon), x => x.heading, when(x => x.meta, html(_t4 || (_t4 = _`<span class="meta">${0}</span>`), x => x.meta)), when(x => !x.noIndicator && !x.iconTrailing, html(_t5 || (_t5 = _`
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
`))));
|
|
117
|
+
`), x => x.open = !x.open, x => x.open, PANEL, () => focusTemplate, x => affixIconTemplate(x.icon), x => x.heading, when(x => x.meta, html(_t4 || (_t4 = _`<span class="meta">${0}</span>`), x => x.meta)), when(x => !x.noIndicator && !x.iconTrailing, html(_t5 || (_t5 = _`
|
|
118
|
+
${0}
|
|
119
|
+
${0}
|
|
120
|
+
`), when(x => !x.open, html(_t6 || (_t6 = _`<vwc-icon type='chevron-down-solid'></vwc-icon>`))), when(x => x.open, html(_t7 || (_t7 = _`<vwc-icon type='chevron-up-solid'></vwc-icon>`))))));
|
|
116
121
|
};
|
|
117
122
|
|
|
118
123
|
const vividAccordionItem = AccordionItem.compose({
|
|
119
124
|
baseName: 'accordion-item',
|
|
120
125
|
template: AccordionItemTemplate,
|
|
121
|
-
styles: css_248z
|
|
126
|
+
styles: css_248z,
|
|
127
|
+
shadowOptions: {
|
|
128
|
+
delegatesFocus: true
|
|
129
|
+
}
|
|
122
130
|
});
|
|
123
131
|
designSystem.register(vividAccordionItem());
|
|
124
132
|
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import { F as FoundationElement, _ as __decorate, a as attr, b as __metadata, h as html, d as designSystem } from '../shared/index.js';
|
|
2
|
+
import { s as styleInject } from '../shared/style-inject.es.js';
|
|
3
|
+
import '../shared/web.dom-collections.iterator.js';
|
|
4
|
+
import { c as classNames } from '../shared/class-names.js';
|
|
5
|
+
import '../shared/export.js';
|
|
6
|
+
import '../shared/object-keys.js';
|
|
7
|
+
import '../shared/iterators.js';
|
|
8
|
+
|
|
9
|
+
var css_248z = ":host {\n display: inline-block;\n}\n\n.base {\n position: relative;\n display: flex;\n box-sizing: border-box;\n align-items: center;\n background-color: var(--_appearance-color-fill);\n color: var(--_appearance-color-text);\n inline-size: inherit;\n vertical-align: middle;\n}\n.base {\n --_appearance-color-text: var(--vvd-color-on-canvas);\n --_appearance-color-fill: var(--vvd-color-canvas);\n --_appearance-color-outline: var(--vvd-color-neutral-50);\n}\n.base.appearance-ghost {\n --_appearance-color-text: var(--_connotation-color-primary);\n --_appearance-color-fill: transaprent;\n --_appearance-color-outline: transaprent;\n}\n.base::before {\n position: absolute;\n z-index: 1;\n border-radius: inherit;\n box-shadow: inset 0 0 0 1px var(--_appearance-color-outline);\n content: \"\";\n inset: 0;\n pointer-events: none;\n}\n.base:not(.tight) {\n padding: 4px;\n column-gap: 4px;\n}\n\n/* Shape */\n.base:not(.shape-pill) {\n border-radius: 6px;\n}\n\n.base.shape-pill {\n border-radius: 24px;\n}\n\n/* Separator */\n::slotted(vwc-divider) {\n align-self: stretch;\n margin-block: 4px;\n}";
|
|
10
|
+
styleInject(css_248z);
|
|
11
|
+
|
|
12
|
+
class ActionGroup extends FoundationElement {
|
|
13
|
+
constructor() {
|
|
14
|
+
super(...arguments);
|
|
15
|
+
this.tight = false;
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
__decorate([attr, __metadata("design:type", String)], ActionGroup.prototype, "shape", void 0);
|
|
21
|
+
|
|
22
|
+
__decorate([attr, __metadata("design:type", String)], ActionGroup.prototype, "appearance", void 0);
|
|
23
|
+
|
|
24
|
+
__decorate([attr({
|
|
25
|
+
mode: 'boolean'
|
|
26
|
+
}), __metadata("design:type", Object)], ActionGroup.prototype, "tight", void 0);
|
|
27
|
+
|
|
28
|
+
let _ = t => t,
|
|
29
|
+
_t;
|
|
30
|
+
|
|
31
|
+
const getClasses = ({
|
|
32
|
+
appearance,
|
|
33
|
+
shape,
|
|
34
|
+
tight
|
|
35
|
+
}) => classNames('base', [`appearance-${appearance}`, Boolean(appearance)], [`shape-${shape}`, Boolean(shape)], ['tight', tight]);
|
|
36
|
+
|
|
37
|
+
const ActionGroupTemplate = () => html(_t || (_t = _`
|
|
38
|
+
<div class="${0}">
|
|
39
|
+
<slot></slot>
|
|
40
|
+
</div>`), getClasses);
|
|
41
|
+
|
|
42
|
+
const vividActionGroup = ActionGroup.compose({
|
|
43
|
+
baseName: 'action-group',
|
|
44
|
+
template: ActionGroupTemplate,
|
|
45
|
+
styles: css_248z
|
|
46
|
+
});
|
|
47
|
+
designSystem.register(vividActionGroup());
|
|
48
|
+
|
|
49
|
+
export { vividActionGroup };
|
package/badge/index.js
CHANGED
|
@@ -1,21 +1,19 @@
|
|
|
1
1
|
import '../icon/index.js';
|
|
2
2
|
import { F as FoundationElement, _ as __decorate, a as attr, b as __metadata, h as html, d as designSystem } from '../shared/index.js';
|
|
3
|
-
import '../shared/web.dom-collections.iterator.js';
|
|
4
3
|
import { A as AffixIconWithTrailing, a as affixIconTemplateFactory } from '../shared/affix.js';
|
|
5
4
|
import { a as applyMixins } from '../shared/apply-mixins.js';
|
|
6
5
|
import { s as styleInject } from '../shared/style-inject.es.js';
|
|
7
6
|
import { c as classNames } from '../shared/class-names.js';
|
|
8
7
|
import '../shared/icon.js';
|
|
8
|
+
import '../shared/export.js';
|
|
9
|
+
import '../shared/iterators.js';
|
|
10
|
+
import '../shared/to-string.js';
|
|
9
11
|
import '../shared/_has.js';
|
|
10
12
|
import '../shared/when.js';
|
|
13
|
+
import '../shared/web.dom-collections.iterator.js';
|
|
14
|
+
import '../shared/object-keys.js';
|
|
11
15
|
|
|
12
|
-
class Badge extends FoundationElement {
|
|
13
|
-
constructor() {
|
|
14
|
-
super(...arguments);
|
|
15
|
-
this.text = '';
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
}
|
|
16
|
+
class Badge extends FoundationElement {}
|
|
19
17
|
|
|
20
18
|
__decorate([attr, __metadata("design:type", String)], Badge.prototype, "connotation", void 0);
|
|
21
19
|
|
|
@@ -23,15 +21,13 @@ __decorate([attr, __metadata("design:type", String)], Badge.prototype, "shape",
|
|
|
23
21
|
|
|
24
22
|
__decorate([attr, __metadata("design:type", String)], Badge.prototype, "appearance", void 0);
|
|
25
23
|
|
|
26
|
-
__decorate([attr, __metadata("design:type", String)], Badge.prototype, "
|
|
24
|
+
__decorate([attr, __metadata("design:type", String)], Badge.prototype, "density", void 0);
|
|
27
25
|
|
|
28
|
-
__decorate([attr(
|
|
29
|
-
mode: 'fromView'
|
|
30
|
-
}), __metadata("design:type", Object)], Badge.prototype, "text", void 0);
|
|
26
|
+
__decorate([attr, __metadata("design:type", String)], Badge.prototype, "text", void 0);
|
|
31
27
|
|
|
32
28
|
applyMixins(Badge, AffixIconWithTrailing);
|
|
33
29
|
|
|
34
|
-
var css_248z = "/*\n Do not edit directly\n Generated on
|
|
30
|
+
var css_248z = "/*\n Do not edit directly\n Generated on Wed, 27 Apr 2022 11:58:36 GMT\n*/\n.control {\n font: 600 ultra-condensed 12px / 16px SpeziaWebVariable;\n letter-spacing: 0px;\n text-decoration: none;\n text-transform: none;\n display: inline-flex;\n box-sizing: border-box;\n align-items: center;\n background-color: var(--_appearance-color-fill);\n box-shadow: inset 0 0 0 1px var(--_appearance-color-outline);\n color: var(--_appearance-color-text);\n column-gap: 8px;\n vertical-align: middle;\n}\n.control.connotation-cta {\n --_connotation-color-primary: var(--vvd-color-cta);\n --_connotation-color-on-primary: var(--vvd-color-on-cta);\n --_connotation-color-intermediate: var(--vvd-color-cta);\n --_connotation-color-soft: var(--vvd-color-cta-20);\n --_connotation-color-contrast: var(--vvd-color-cta-90);\n}\n.control.connotation-success {\n --_connotation-color-primary: var(--vvd-color-success);\n --_connotation-color-on-primary: var(--vvd-color-on-success);\n --_connotation-color-intermediate: var(--vvd-color-success);\n --_connotation-color-soft: var(--vvd-color-success-20);\n --_connotation-color-contrast: var(--vvd-color-success-90);\n}\n.control.connotation-alert {\n --_connotation-color-primary: var(--vvd-color-alert);\n --_connotation-color-on-primary: var(--vvd-color-on-alert);\n --_connotation-color-intermediate: var(--vvd-color-alert);\n --_connotation-color-soft: var(--vvd-color-alert-20);\n --_connotation-color-contrast: var(--vvd-color-alert-90);\n}\n.control.connotation-warning {\n --_connotation-color-primary: var(--vvd-color-warning);\n --_connotation-color-on-primary: var(--vvd-color-on-warning);\n --_connotation-color-intermediate: var(--vvd-color-warning);\n --_connotation-color-soft: var(--vvd-color-warning-20);\n --_connotation-color-contrast: var(--vvd-color-warning-90);\n}\n.control.connotation-info {\n --_connotation-color-primary: var(--vvd-color-info);\n --_connotation-color-on-primary: var(--vvd-color-on-info);\n --_connotation-color-intermediate: var(--vvd-color-info);\n --_connotation-color-soft: var(--vvd-color-info-20);\n --_connotation-color-contrast: var(--vvd-color-info-90);\n}\n.control:not(.connotation-cta, .connotation-success, .connotation-alert, .connotation-warning, .connotation-info) {\n --_connotation-color-primary: var(--vvd-color-on-canvas);\n --_connotation-color-on-primary: var(--vvd-color-canvas);\n --_connotation-color-intermediate: var(--vvd-color-neutral);\n --_connotation-color-soft: var(--vvd-color-neutral-20);\n --_connotation-color-contrast: var(--vvd-color-neutral-90);\n}\n.control {\n --_appearance-color-text: var(--_connotation-color-on-primary);\n --_appearance-color-fill: var(--_connotation-color-primary);\n --_appearance-color-outline: transaprent;\n}\n.control.appearance-duotone {\n --_appearance-color-text: var(--_connotation-color-contrast);\n --_appearance-color-fill: transaprent;\n --_appearance-color-outline: var(--_connotation-color-intermediate);\n}\n.control.appearance-subtle {\n --_appearance-color-text: var(--_connotation-color-contrast);\n --_appearance-color-fill: var(--_connotation-color-soft);\n --_appearance-color-outline: transaprent;\n}\n\n/* Size */\n.control:not(.density-condensed):not(.density-extended) {\n block-size: 24px;\n padding-inline: 10px;\n}\n\n.control.density-condensed {\n block-size: 20px;\n padding-inline: 8px;\n}\n\n.control.density-extended {\n block-size: 28px;\n padding-inline: 12px;\n}\n\n/* Shape */\n.control:not(.shape-pill) {\n border-radius: 4px;\n}\n\n.control.shape-pill {\n border-radius: 14px;\n}\n\n/* Icon */\n.icon-trailing .icon {\n order: 1;\n}";
|
|
35
31
|
styleInject(css_248z);
|
|
36
32
|
|
|
37
33
|
let _ = t => t,
|
|
@@ -41,9 +37,9 @@ const getClasses = ({
|
|
|
41
37
|
connotation,
|
|
42
38
|
appearance,
|
|
43
39
|
shape,
|
|
44
|
-
|
|
40
|
+
density,
|
|
45
41
|
iconTrailing
|
|
46
|
-
}) => classNames('control', [`connotation-${connotation}`, Boolean(connotation)], [`appearance-${appearance}`, Boolean(appearance)], [`shape-${shape}`, Boolean(shape)], [`
|
|
42
|
+
}) => classNames('control', [`connotation-${connotation}`, Boolean(connotation)], [`appearance-${appearance}`, Boolean(appearance)], [`shape-${shape}`, Boolean(shape)], [`density-${density}`, Boolean(density)], ['icon-trailing', iconTrailing]);
|
|
47
43
|
|
|
48
44
|
const badgeTemplate = context => {
|
|
49
45
|
const affixIconTemplate = affixIconTemplateFactory(context);
|
|
@@ -54,11 +50,11 @@ const badgeTemplate = context => {
|
|
|
54
50
|
</span>`), getClasses, x => affixIconTemplate(x.icon), x => x.text);
|
|
55
51
|
};
|
|
56
52
|
|
|
57
|
-
const
|
|
53
|
+
const vividBadge = Badge.compose({
|
|
58
54
|
baseName: 'badge',
|
|
59
55
|
template: badgeTemplate,
|
|
60
56
|
styles: css_248z
|
|
61
57
|
});
|
|
62
|
-
designSystem.register(
|
|
58
|
+
designSystem.register(vividBadge());
|
|
63
59
|
|
|
64
|
-
export {
|
|
60
|
+
export { vividBadge };
|
package/banner/index.js
CHANGED
|
@@ -1,93 +1,30 @@
|
|
|
1
|
+
import '../button/index.js';
|
|
1
2
|
import { F as FoundationElement, c as __classPrivateFieldGet, _ as __decorate, a as attr, b as __metadata, h as html, d as designSystem } from '../shared/index.js';
|
|
2
3
|
import { s as styleInject } from '../shared/style-inject.es.js';
|
|
3
4
|
import '../shared/web.dom-collections.iterator.js';
|
|
5
|
+
import { C as Connotation } from '../shared/enums.js';
|
|
4
6
|
import { b as AffixIcon, a as affixIconTemplateFactory } from '../shared/affix.js';
|
|
5
7
|
import { a as applyMixins } from '../shared/apply-mixins.js';
|
|
6
|
-
import '../button/index.js';
|
|
7
|
-
import '../text-anchor/index.js';
|
|
8
8
|
import { w as when } from '../shared/when.js';
|
|
9
9
|
import { c as classNames } from '../shared/class-names.js';
|
|
10
|
+
import '../icon/index.js';
|
|
10
11
|
import '../shared/icon.js';
|
|
12
|
+
import '../shared/export.js';
|
|
13
|
+
import '../shared/iterators.js';
|
|
14
|
+
import '../shared/to-string.js';
|
|
11
15
|
import '../shared/_has.js';
|
|
12
|
-
import '../
|
|
13
|
-
import '../shared/
|
|
16
|
+
import '../focus/index.js';
|
|
17
|
+
import '../shared/focus.js';
|
|
18
|
+
import '../shared/button.js';
|
|
19
|
+
import '../shared/form-associated.js';
|
|
14
20
|
import '../shared/aria-global.js';
|
|
15
|
-
import '../shared/
|
|
16
|
-
import '../shared/
|
|
17
|
-
import '../shared/
|
|
21
|
+
import '../shared/ref.js';
|
|
22
|
+
import '../shared/focus2.js';
|
|
23
|
+
import '../shared/object-keys.js';
|
|
18
24
|
|
|
19
|
-
var css_248z = "/*\n Do not edit directly\n Generated on
|
|
25
|
+
var css_248z = "/*\n Do not edit directly\n Generated on Wed, 27 Apr 2022 11:58:36 GMT\n*/\n.control {\n overflow: hidden;\n max-height: 160px;\n background-color: var(--_appearance-color-fill);\n color: var(--_appearance-color-text);\n transition: max-height var(--transition-delay, 200ms);\n}\n.control.connotation-success {\n --_connotation-color-primary: var(--vvd-color-success);\n --_connotation-color-on-primary: var(--vvd-color-on-success);\n}\n.control.connotation-alert {\n --_connotation-color-primary: var(--vvd-color-alert);\n --_connotation-color-on-primary: var(--vvd-color-on-alert);\n}\n.control.connotation-announcement {\n --_connotation-color-primary: var(--vvd-color-announcement);\n --_connotation-color-on-primary: var(--vvd-color-on-announcement);\n}\n.control.connotation-warning {\n --_connotation-color-primary: var(--vvd-color-warning);\n --_connotation-color-on-primary: var(--vvd-color-on-warning);\n}\n.control:not(.connotation-success, .connotation-alert, .connotation-announcement, .connotation-warning) {\n --_connotation-color-primary: var(--vvd-color-info);\n --_connotation-color-on-primary: var(--vvd-color-on-info);\n}\n.control {\n --_appearance-color-text: var(--_connotation-color-on-primary);\n --_appearance-color-fill: var(--_connotation-color-primary);\n --_appearance-color-outline: transaprent;\n}\n.control.removing {\n max-height: 0;\n}\n.control > .header {\n font: 600 ultra-condensed 14px / 20px SpeziaWebVariable;\n letter-spacing: 0px;\n text-decoration: none;\n text-transform: none;\n display: flex;\n min-height: 60px;\n align-items: center;\n justify-content: flex-start;\n}\n.control > .header > .user-content {\n display: flex;\n flex: 1 0;\n align-items: center;\n justify-content: center;\n padding-inline: 16px;\n}\n.control > .header > .user-content > .icon {\n flex: 0 0 auto;\n font-size: 20px;\n margin-inline-end: 15px;\n}\n.control > .header > .user-content > .action-items {\n display: inline-block;\n flex: 0 0 auto;\n padding-inline-start: 15px;\n}\n.control > .header > .user-content > .message {\n padding: 20px 0;\n}\n.control > .header > .dismiss-button {\n --vvd-icon-button-color: inherit;\n flex: 0 0 auto;\n margin-inline-end: 8px;\n}";
|
|
20
26
|
styleInject(css_248z);
|
|
21
27
|
|
|
22
|
-
var Connotation;
|
|
23
|
-
|
|
24
|
-
(function (Connotation) {
|
|
25
|
-
Connotation["Primary"] = "primary";
|
|
26
|
-
Connotation["CTA"] = "cta";
|
|
27
|
-
Connotation["Success"] = "success";
|
|
28
|
-
Connotation["Alert"] = "alert";
|
|
29
|
-
Connotation["Warning"] = "warning";
|
|
30
|
-
Connotation["Info"] = "info";
|
|
31
|
-
Connotation["Announcement"] = "announcement";
|
|
32
|
-
})(Connotation || (Connotation = {}));
|
|
33
|
-
|
|
34
|
-
var ConnotationDecorative;
|
|
35
|
-
|
|
36
|
-
(function (ConnotationDecorative) {
|
|
37
|
-
ConnotationDecorative["Pacific"] = "pacific";
|
|
38
|
-
})(ConnotationDecorative || (ConnotationDecorative = {}));
|
|
39
|
-
|
|
40
|
-
var Shape;
|
|
41
|
-
|
|
42
|
-
(function (Shape) {
|
|
43
|
-
Shape["Rounded"] = "rounded";
|
|
44
|
-
Shape["Pill"] = "pill";
|
|
45
|
-
Shape["Circled"] = "circled";
|
|
46
|
-
Shape["Sharp"] = "sharp";
|
|
47
|
-
})(Shape || (Shape = {}));
|
|
48
|
-
|
|
49
|
-
var Appearance;
|
|
50
|
-
|
|
51
|
-
(function (Appearance) {
|
|
52
|
-
Appearance["Text"] = "text";
|
|
53
|
-
Appearance["Filled"] = "filled";
|
|
54
|
-
Appearance["Outlined"] = "outlined";
|
|
55
|
-
Appearance["Subtle"] = "subtle";
|
|
56
|
-
Appearance["Ghost"] = "ghost";
|
|
57
|
-
})(Appearance || (Appearance = {}));
|
|
58
|
-
|
|
59
|
-
var Size;
|
|
60
|
-
|
|
61
|
-
(function (Size) {
|
|
62
|
-
Size["BaseSmall"] = "base-small";
|
|
63
|
-
Size["Base"] = "base";
|
|
64
|
-
Size["BaseLarge"] = "base-large";
|
|
65
|
-
})(Size || (Size = {}));
|
|
66
|
-
|
|
67
|
-
var Position;
|
|
68
|
-
|
|
69
|
-
(function (Position) {
|
|
70
|
-
Position["Top"] = "TOP";
|
|
71
|
-
Position["Bottom"] = "BOTTOM";
|
|
72
|
-
Position["Start"] = "START";
|
|
73
|
-
Position["Center"] = "CENTER";
|
|
74
|
-
Position["End"] = "END";
|
|
75
|
-
})(Position || (Position = {}));
|
|
76
|
-
|
|
77
|
-
var Role;
|
|
78
|
-
|
|
79
|
-
(function (Role) {
|
|
80
|
-
Role["Status"] = "status";
|
|
81
|
-
Role["Alert"] = "alert";
|
|
82
|
-
})(Role || (Role = {}));
|
|
83
|
-
|
|
84
|
-
var AriaLive;
|
|
85
|
-
|
|
86
|
-
(function (AriaLive) {
|
|
87
|
-
AriaLive["Polite"] = "polite";
|
|
88
|
-
AriaLive["Assertive"] = "assertive";
|
|
89
|
-
})(AriaLive || (AriaLive = {}));
|
|
90
|
-
|
|
91
28
|
var _Banner_handleRemoveEnd, _Banner_closeOnKeyDown;
|
|
92
29
|
const connotationIconMap = new Map([[Connotation.Info, 'info-solid'], [Connotation.Announcement, 'megaphone-solid'], [Connotation.Success, 'check-circle-solid'], [Connotation.Warning, 'warning-solid'], [Connotation.Alert, 'error-solid']]);
|
|
93
30
|
|
|
@@ -99,7 +36,7 @@ class Banner extends FoundationElement {
|
|
|
99
36
|
this.removable = false;
|
|
100
37
|
|
|
101
38
|
_Banner_handleRemoveEnd.set(this, () => {
|
|
102
|
-
this.$emit('
|
|
39
|
+
this.$emit('removed');
|
|
103
40
|
this.parentElement && this.parentElement.removeChild(this);
|
|
104
41
|
});
|
|
105
42
|
|
|
@@ -129,7 +66,7 @@ class Banner extends FoundationElement {
|
|
|
129
66
|
}
|
|
130
67
|
|
|
131
68
|
remove() {
|
|
132
|
-
this.$emit('
|
|
69
|
+
this.$emit('removing');
|
|
133
70
|
const banner = this.shadowRoot && this.shadowRoot.querySelector('.banner');
|
|
134
71
|
|
|
135
72
|
if (banner) {
|
|
@@ -174,7 +111,7 @@ const getClasses = _ => classNames('control', [`connotation-${_.connotation}`, !
|
|
|
174
111
|
function renderDismissButton() {
|
|
175
112
|
return html(_t || (_t = _2`
|
|
176
113
|
<vwc-button
|
|
177
|
-
|
|
114
|
+
density="condensed"
|
|
178
115
|
class="dismiss-button"
|
|
179
116
|
icon="close-line"
|
|
180
117
|
@click="${0}">
|
|
@@ -193,7 +130,7 @@ const BannerTemplate = context => {
|
|
|
193
130
|
aria-live="${0}">
|
|
194
131
|
${0}
|
|
195
132
|
</div>
|
|
196
|
-
<slot class="action-items" name="
|
|
133
|
+
<slot class="action-items" name="action-items"></slot>
|
|
197
134
|
</div>
|
|
198
135
|
|
|
199
136
|
${0}
|
package/breadcrumb/index.js
CHANGED
|
@@ -1,27 +1,16 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { F as FoundationElement, _ as __decorate, o as observable, h as html, d as designSystem } from '../shared/index.js';
|
|
2
|
+
import { s as slotted, e as elements } from '../shared/slotted.js';
|
|
2
3
|
import { s as styleInject } from '../shared/style-inject.es.js';
|
|
3
4
|
import { B as BreadcrumbItem } from '../shared/breadcrumb-item.js';
|
|
4
|
-
import { s as slotted, e as elements } from '../shared/slotted.js';
|
|
5
5
|
import '../shared/anchor.js';
|
|
6
6
|
import '../shared/apply-mixins.js';
|
|
7
7
|
import '../shared/aria-global.js';
|
|
8
|
-
|
|
9
|
-
/**
|
|
10
|
-
* The template for the {@link @microsoft/fast-foundation#Breadcrumb} component.
|
|
11
|
-
* @public
|
|
12
|
-
*/
|
|
13
|
-
const breadcrumbTemplate = (context, definition) => html `
|
|
14
|
-
<template role="navigation">
|
|
15
|
-
<div role="list" class="list" part="list">
|
|
16
|
-
<slot
|
|
17
|
-
${slotted({ property: "slottedBreadcrumbItems", filter: elements() })}
|
|
18
|
-
></slot>
|
|
19
|
-
</div>
|
|
20
|
-
</template>
|
|
21
|
-
`;
|
|
8
|
+
import '../shared/ref.js';
|
|
22
9
|
|
|
23
10
|
/**
|
|
24
11
|
* A Breadcrumb Custom HTML Element.
|
|
12
|
+
* @slot - The default slot for the breadcrumb items
|
|
13
|
+
* @csspart list - The element wrapping the slotted items
|
|
25
14
|
*
|
|
26
15
|
* @public
|
|
27
16
|
*/
|
|
@@ -85,6 +74,21 @@ __decorate([
|
|
|
85
74
|
observable
|
|
86
75
|
], Breadcrumb$1.prototype, "slottedBreadcrumbItems", void 0);
|
|
87
76
|
|
|
77
|
+
let _ = t => t,
|
|
78
|
+
_t;
|
|
79
|
+
const breadcrumbTemplate = () => html(_t || (_t = _`
|
|
80
|
+
<nav aria-label="breadcrumbs" class="base">
|
|
81
|
+
<div role="list" class="list">
|
|
82
|
+
<slot
|
|
83
|
+
${0}
|
|
84
|
+
></slot>
|
|
85
|
+
</div>
|
|
86
|
+
</nav>
|
|
87
|
+
`), slotted({
|
|
88
|
+
property: 'slottedBreadcrumbItems',
|
|
89
|
+
filter: elements()
|
|
90
|
+
}));
|
|
91
|
+
|
|
88
92
|
var css_248z = ".list {\n display: flex;\n}";
|
|
89
93
|
styleInject(css_248z);
|
|
90
94
|
|