@vonage/vivid 3.0.0-next.29 → 3.0.0-next.31

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.
@@ -0,0 +1,17 @@
1
+ import { F as FoundationElement, h as html, d as designSystem } from '../shared/index.js';
2
+
3
+ class Sidenav extends FoundationElement {}
4
+
5
+ let _ = t => t,
6
+ _t;
7
+ const SidenavTemplate = () => html(_t || (_t = _`
8
+ <nav><slot></slot></nav>
9
+ `));
10
+
11
+ const vividSidenav = Sidenav.compose({
12
+ baseName: 'sidenav',
13
+ template: SidenavTemplate
14
+ });
15
+ designSystem.register(vividSidenav());
16
+
17
+ export { vividSidenav };
@@ -18,10 +18,9 @@ import '../shared/web.dom-collections.iterator.js';
18
18
  import '../shared/object-keys.js';
19
19
  import '../shared/anchor.js';
20
20
  import '../shared/aria-global.js';
21
- import '../shared/ref.js';
22
21
  import '../shared/focus2.js';
23
22
 
24
- var css_248z = "/*\n Do not edit directly\n Generated on Wed, 27 Apr 2022 11:58:36 GMT\n*/\n.control {\n font: 400 ultra-condensed 14px / 20px SpeziaWebVariable;\n letter-spacing: 0px;\n text-decoration: none;\n text-transform: none;\n position: relative;\n display: inline-flex;\n box-sizing: border-box;\n align-items: center;\n background-color: transparent;\n border-radius: 6px;\n color: var(--vvd-color-on-canvas);\n gap: 8px;\n -webkit-hyphens: auto;\n hyphens: auto;\n inline-size: 100%;\n min-block-size: 40px;\n padding-block: 10px;\n padding-inline: 8px;\n text-decoration: none;\n vertical-align: middle;\n word-break: break-word;\n}\n@supports selector(:focus-visible) {\n .control:focus {\n outline: none;\n }\n}\n.control.icon-only {\n display: flex;\n block-size: 40px;\n inline-size: 40px;\n place-content: center;\n}\n\n.control:focus {\n background-color: var(--vvd-color-neutral-20);\n}\n\n.control:not(:focus-visible) .focus-indicator {\n display: none;\n}\n\n.icon {\n font-size: 20px;\n}";
23
+ var css_248z = "/*\n Do not edit directly\n Generated on Wed, 27 Apr 2022 11:58:36 GMT\n*/\n.control {\n font: 400 ultra-condensed 14px / 20px SpeziaWebVariable;\n letter-spacing: 0px;\n text-decoration: none;\n text-transform: none;\n position: relative;\n display: inline-flex;\n box-sizing: border-box;\n align-items: center;\n background-color: var(--_appearance-color-fill);\n border-radius: 6px;\n box-shadow: inset 0 0 0 1px var(--_appearance-color-outline);\n color: var(--_appearance-color-text);\n gap: 8px;\n -webkit-hyphens: auto;\n hyphens: auto;\n inline-size: 100%;\n min-block-size: 40px;\n padding-block: 10px;\n padding-inline: 8px;\n text-decoration: none;\n vertical-align: middle;\n word-break: break-word;\n}\n.control {\n --_appearance-color-text: var(--_connotation-color-primary);\n --_appearance-color-fill: transaprent;\n --_appearance-color-outline: transaprent;\n}\n.control: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.control: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.control:where(.selected, [aria-current]):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.control {\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 .control:focus {\n outline: none;\n }\n}\n.control.icon-only {\n display: flex;\n block-size: 40px;\n inline-size: 40px;\n place-content: center;\n}\n\n.control:not(:focus-visible) .focus-indicator {\n display: none;\n}\n\n.icon {\n font-size: 20px;\n}";
25
24
  styleInject(css_248z);
26
25
 
27
26
  class SidenavItem extends TextAnchor {}
@@ -36,10 +35,7 @@ const SidenavItemTemplate = (context, definition) => html(_t || (_t = _`
36
35
  const vividSidenavItem = SidenavItem.compose({
37
36
  baseName: 'sidenav-item',
38
37
  template: SidenavItemTemplate,
39
- styles: css_248z,
40
- shadowOptions: {
41
- delegatesFocus: true
42
- }
38
+ styles: css_248z
43
39
  });
44
40
  designSystem.register(vividSidenavItem());
45
41
 
@@ -12,7 +12,6 @@ import '../shared/_has.js';
12
12
  import '../shared/anchor.js';
13
13
  import '../shared/apply-mixins.js';
14
14
  import '../shared/aria-global.js';
15
- import '../shared/ref.js';
16
15
  import '../shared/focus2.js';
17
16
  import '../shared/focus.js';
18
17
  import '../shared/class-names.js';
@@ -6,11 +6,10 @@ import { b as AffixIcon, a as affixIconTemplateFactory } from '../shared/affix.j
6
6
  import '../shared/focus.js';
7
7
  import { a as applyMixins } from '../shared/apply-mixins.js';
8
8
  import { F as FormAssociated } from '../shared/form-associated.js';
9
- import { A as ARIAGlobalStatesAndProperties, S as StartEnd } from '../shared/aria-global.js';
9
+ import { A as ARIAGlobalStatesAndProperties, S as StartEnd, r as ref } from '../shared/aria-global.js';
10
10
  import { s as styleInject } from '../shared/style-inject.es.js';
11
11
  import { f as focusTemplateFactory } from '../shared/focus2.js';
12
12
  import { w as when } from '../shared/when.js';
13
- import { r as ref } from '../shared/ref.js';
14
13
  import { c as classNames } from '../shared/class-names.js';
15
14
  import '../shared/icon.js';
16
15
  import '../shared/export.js';
package/tooltip/index.js CHANGED
@@ -19,7 +19,6 @@ import '../shared/button.js';
19
19
  import '../shared/apply-mixins.js';
20
20
  import '../shared/form-associated.js';
21
21
  import '../shared/aria-global.js';
22
- import '../shared/ref.js';
23
22
  import '../shared/focus2.js';
24
23
  import '../shared/object-keys.js';
25
24
  import '../shared/es.object.assign.js';
@@ -51,9 +50,9 @@ let _2 = t => t,
51
50
  const getClasses = _ => classNames('control');
52
51
 
53
52
  const TooltipTemplate = () => html(_t || (_t = _2`
54
- <vwc-popup class="${0}" arrow alternate="true"
53
+ <vwc-popup class="${0}" arrow alternate
55
54
  corner=${0} open=${0} anchor=${0}
56
- exportparts="vvd-theme-alternate">
55
+ exportparts="vvd-theme-alternate" role="tooltip">
57
56
  <div class="tooltip">
58
57
  <header part="vvd-theme-alternate" class="tooltip-header">
59
58
  <div class="tooltip-text">${0}</div>
package/shared/ref.js DELETED
@@ -1,41 +0,0 @@
1
- import { A as AttachedBehaviorHTMLDirective } from './index.js';
2
-
3
- /**
4
- * The runtime behavior for template references.
5
- * @public
6
- */
7
- class RefBehavior {
8
- /**
9
- * Creates an instance of RefBehavior.
10
- * @param target - The element to reference.
11
- * @param propertyName - The name of the property to assign the reference to.
12
- */
13
- constructor(target, propertyName) {
14
- this.target = target;
15
- this.propertyName = propertyName;
16
- }
17
- /**
18
- * Bind this behavior to the source.
19
- * @param source - The source to bind to.
20
- * @param context - The execution context that the binding is operating within.
21
- */
22
- bind(source) {
23
- source[this.propertyName] = this.target;
24
- }
25
- /**
26
- * Unbinds this behavior from the source.
27
- * @param source - The source to unbind from.
28
- */
29
- /* eslint-disable-next-line @typescript-eslint/no-empty-function */
30
- unbind() { }
31
- }
32
- /**
33
- * A directive that observes the updates a property with a reference to the element.
34
- * @param propertyName - The name of the property to assign the reference to.
35
- * @public
36
- */
37
- function ref(propertyName) {
38
- return new AttachedBehaviorHTMLDirective("fast-ref", RefBehavior, propertyName);
39
- }
40
-
41
- export { ref as r };