@threadlabs/looma 0.26.1 → 0.26.2
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/components/ui-badge/ui-badge.html +42 -3
- package/components/ui-container/ui-container.html +11 -0
- package/components/ui-icon-button/ui-icon-button.html +58 -12
- package/dist/index.js +1 -1
- package/package.json +1 -1
- package/styles/ui-badge.css +40 -0
- package/styles/ui-container.css +8 -0
- package/styles/ui-icon-button.css +62 -12
- package/vanilla/UiBadge.d.ts +1 -1
- package/vanilla/UiBadge.js +1 -1
- package/vanilla/UiContainer.d.ts +1 -0
- package/vanilla/UiContainer.js +5 -5
- package/vanilla/UiIconButton.d.ts +1 -0
- package/vanilla/UiIconButton.js +4 -4
- package/vue/UiBadge.d.ts +3 -3
- package/vue/UiBadge.vue +44 -6
- package/vue/UiContainer.d.ts +9 -0
- package/vue/UiContainer.vue +27 -1
- package/vue/UiIconButton.d.ts +9 -0
- package/vue/UiIconButton.vue +95 -12
- package/vue/chunks/UiBadge.js +5 -4
- package/vue/chunks/UiContainer.js +23 -1
- package/vue/chunks/UiIconButton.js +25 -1
- package/vue/components.css +202 -102
package/vue/UiIconButton.vue
CHANGED
|
@@ -71,6 +71,14 @@ const propValidityContract = {
|
|
|
71
71
|
values: ['sm', 'md', 'lg'],
|
|
72
72
|
default: 'md',
|
|
73
73
|
},
|
|
74
|
+
tone: {
|
|
75
|
+
type: { kind: 'terminal', name: 'keyword' },
|
|
76
|
+
required: false,
|
|
77
|
+
target: { attribute: 'tone' },
|
|
78
|
+
description:
|
|
79
|
+
'Colour for every variant. When omitted, ghost and outline keep their neutral appearance and solid keeps its accent fill. Set accent for a coloured action\n or neutral for a quiet one. Native aria-pressed="true" keeps an outline toggle visibly pressed; the consumer owns that state.',
|
|
80
|
+
values: ['accent', 'neutral'],
|
|
81
|
+
},
|
|
74
82
|
variant: {
|
|
75
83
|
type: { kind: 'terminal', name: 'keyword' },
|
|
76
84
|
required: false,
|
|
@@ -91,6 +99,7 @@ const props = defineProps({
|
|
|
91
99
|
pending: { type: null as unknown as PropType<boolean | null>, default: false },
|
|
92
100
|
round: { type: null as unknown as PropType<boolean | null>, default: false },
|
|
93
101
|
size: { type: null as unknown as PropType<'sm' | 'md' | 'lg' | null>, default: 'md' },
|
|
102
|
+
tone: { type: null as unknown as PropType<'accent' | 'neutral' | null>, default: null },
|
|
94
103
|
variant: {
|
|
95
104
|
type: null as unknown as PropType<'ghost' | 'outline' | 'solid' | null>,
|
|
96
105
|
default: 'ghost',
|
|
@@ -105,6 +114,7 @@ const acceptedProps: Record<string, unknown> = {
|
|
|
105
114
|
pending: false,
|
|
106
115
|
round: false,
|
|
107
116
|
size: 'md',
|
|
117
|
+
tone: null,
|
|
108
118
|
variant: 'ghost',
|
|
109
119
|
}
|
|
110
120
|
const checkedProps = computed(() => ({
|
|
@@ -164,6 +174,13 @@ const checkedProps = computed(() => ({
|
|
|
164
174
|
'size',
|
|
165
175
|
acceptedProps,
|
|
166
176
|
) as 'sm' | 'md' | 'lg',
|
|
177
|
+
tone: checkedProp<'accent' | 'neutral'>(
|
|
178
|
+
props['tone'],
|
|
179
|
+
{ kind: 'terminal', name: 'keyword' },
|
|
180
|
+
false,
|
|
181
|
+
'tone',
|
|
182
|
+
acceptedProps,
|
|
183
|
+
),
|
|
167
184
|
variant: checkedProp<'ghost' | 'outline' | 'solid'>(
|
|
168
185
|
props['variant'],
|
|
169
186
|
{ kind: 'terminal', name: 'keyword' },
|
|
@@ -269,6 +286,8 @@ if (
|
|
|
269
286
|
/** The values the styles' :host-state() rules test. */
|
|
270
287
|
const hostState = computed(() =>
|
|
271
288
|
[
|
|
289
|
+
checkedProps.value.tone && 'tone',
|
|
290
|
+
checkedProps.value.tone != null && `tone=${encodeURIComponent(checkedProps.value.tone)}`,
|
|
272
291
|
checkedProps.value.anticipatory && 'anticipatory',
|
|
273
292
|
checkedProps.value.variant && 'variant',
|
|
274
293
|
checkedProps.value.variant != null
|
|
@@ -308,6 +327,7 @@ useComponentHost(() => import('../components/ui-icon-button/ui-icon-button.js'),
|
|
|
308
327
|
'pending',
|
|
309
328
|
'round',
|
|
310
329
|
'size',
|
|
330
|
+
'tone',
|
|
311
331
|
'variant',
|
|
312
332
|
],
|
|
313
333
|
propValidity: (name: string) =>
|
|
@@ -364,6 +384,7 @@ function concat<T extends unknown[]>(...values: T): ConcatResult<T> {
|
|
|
364
384
|
:data-pending="reflectedProp('pending', 'pending', checkedProps.pending, undefined, false)"
|
|
365
385
|
:data-round="reflectedProp('round', 'round', checkedProps.round, undefined, false)"
|
|
366
386
|
:data-size="reflectedProp('size', 'size', checkedProps.size, undefined, false)"
|
|
387
|
+
:data-tone="reflectedProp('tone', 'tone', checkedProps.tone, undefined, false)"
|
|
367
388
|
:data-variant="reflectedProp('variant', 'variant', checkedProps.variant, undefined, false)"
|
|
368
389
|
:data-ui-icon-button-state="hostState || undefined"
|
|
369
390
|
ref="root"
|
|
@@ -461,6 +482,25 @@ function concat<T extends unknown[]>(...values: T): ConcatResult<T> {
|
|
|
461
482
|
color: var(--ui-text-secondary);
|
|
462
483
|
}
|
|
463
484
|
|
|
485
|
+
[data-component~="ui-icon-button"][data-ui-icon-button-state~="tone=accent"] {
|
|
486
|
+
--_icon-button-border: var(--ui-accent-solid);
|
|
487
|
+
--_icon-button-hover-border: var(--ui-accent-hover);
|
|
488
|
+
--_icon-button-text: var(--ui-accent-subtle-text, var(--ui-accent-solid));
|
|
489
|
+
--_icon-button-outline-surface: color-mix(
|
|
490
|
+
in srgb,
|
|
491
|
+
var(--ui-accent-solid) 5%,
|
|
492
|
+
var(--ui-surface-default)
|
|
493
|
+
);
|
|
494
|
+
color: var(--_icon-button-text);
|
|
495
|
+
}
|
|
496
|
+
|
|
497
|
+
/* Omitted tone retains the existing accent solid; explicit neutral is additive. */
|
|
498
|
+
[data-component~="ui-icon-button"][data-ui-icon-button-state~="tone=neutral"] {
|
|
499
|
+
--_icon-button-solid-surface: var(--ui-text-primary);
|
|
500
|
+
--_icon-button-solid-hover-surface: var(--ui-text-primary);
|
|
501
|
+
--_icon-button-solid-text: var(--ui-surface-default);
|
|
502
|
+
}
|
|
503
|
+
|
|
464
504
|
[data-component~="ui-icon-button"][data-ui-icon-button-state~="anticipatory"] {
|
|
465
505
|
position: relative;
|
|
466
506
|
}
|
|
@@ -495,13 +535,13 @@ function concat<T extends unknown[]>(...values: T): ConcatResult<T> {
|
|
|
495
535
|
}
|
|
496
536
|
|
|
497
537
|
@media (hover: hover) and (pointer: fine) {
|
|
498
|
-
[data-component~="ui-icon-button"][data-ui-icon-button-state~="anticipatory"]:not([data-component~="ui-icon-button"][data-ui-icon-button-state~="variant=solid"], [data-component~="ui-icon-button"][data-ui-icon-button-state~="loading"], [data-component~="ui-icon-button"][data-ui-icon-button-state~="pending"], :disabled, [data-ui-proximity="near"], :hover, :focus-visible) {
|
|
538
|
+
[data-component~="ui-icon-button"][data-ui-icon-button-state~="anticipatory"]:not([data-component~="ui-icon-button"][data-ui-icon-button-state~="variant=solid"], [data-component~="ui-icon-button"][data-ui-icon-button-state~="loading"], [data-component~="ui-icon-button"][data-ui-icon-button-state~="pending"], :disabled, [aria-pressed="true"], [data-ui-proximity="near"], :hover, :focus-visible) {
|
|
499
539
|
border-color: transparent;
|
|
500
540
|
background-color: transparent;
|
|
501
541
|
box-shadow: none;
|
|
502
542
|
}
|
|
503
543
|
|
|
504
|
-
[data-component~="ui-icon-button"][data-ui-icon-button-state~="anticipatory"]:not([data-component~="ui-icon-button"][data-ui-icon-button-state~="variant=solid"], [data-component~="ui-icon-button"][data-ui-icon-button-state~="loading"], [data-component~="ui-icon-button"][data-ui-icon-button-state~="pending"], :disabled, [data-ui-proximity="near"], :hover, :focus-visible)
|
|
544
|
+
[data-component~="ui-icon-button"][data-ui-icon-button-state~="anticipatory"]:not([data-component~="ui-icon-button"][data-ui-icon-button-state~="variant=solid"], [data-component~="ui-icon-button"][data-ui-icon-button-state~="loading"], [data-component~="ui-icon-button"][data-ui-icon-button-state~="pending"], :disabled, [aria-pressed="true"], [data-ui-proximity="near"], :hover, :focus-visible)
|
|
505
545
|
.content {
|
|
506
546
|
opacity: 0;
|
|
507
547
|
transform: scale(0.65);
|
|
@@ -509,7 +549,7 @@ function concat<T extends unknown[]>(...values: T): ConcatResult<T> {
|
|
|
509
549
|
}
|
|
510
550
|
}
|
|
511
551
|
|
|
512
|
-
[data-component~="ui-icon-button"][data-ui-icon-button-state~="anticipatory"]:is([data-component~="ui-icon-button"][data-ui-icon-button-state~="variant=solid"], [data-ui-proximity="near"], :hover, :focus-visible)::before {
|
|
552
|
+
[data-component~="ui-icon-button"][data-ui-icon-button-state~="anticipatory"]:is([data-component~="ui-icon-button"][data-ui-icon-button-state~="variant=solid"], [aria-pressed="true"], [data-ui-proximity="near"], :hover, :focus-visible)::before {
|
|
513
553
|
opacity: 0;
|
|
514
554
|
}
|
|
515
555
|
|
|
@@ -622,17 +662,26 @@ html[data-ui-input-modality="touch"] [data-component~="ui-icon-button"]::after {
|
|
|
622
662
|
}
|
|
623
663
|
|
|
624
664
|
[data-component~="ui-icon-button"][data-ui-icon-button-state~="variant=outline"] {
|
|
625
|
-
border-color: var(
|
|
626
|
-
|
|
665
|
+
border-color: var(
|
|
666
|
+
--ui-icon-button-border,
|
|
667
|
+
var(--_icon-button-border, var(--ui-control-border, var(--ui-border-strong)))
|
|
668
|
+
);
|
|
669
|
+
background-color: var(
|
|
670
|
+
--ui-icon-button-outline-surface,
|
|
671
|
+
var(--_icon-button-outline-surface, var(--ui-surface-default))
|
|
672
|
+
);
|
|
627
673
|
background-image: var(--ui-raised-highlight);
|
|
628
|
-
color: var(--ui-icon-button-outline-text, var(--ui-text-primary));
|
|
674
|
+
color: var(--ui-icon-button-outline-text, var(--_icon-button-text, var(--ui-text-primary)));
|
|
629
675
|
box-shadow: var(--ui-raised);
|
|
630
676
|
}
|
|
631
677
|
|
|
632
678
|
[data-component~="ui-icon-button"][data-ui-icon-button-state~="variant=solid"] {
|
|
633
|
-
background-color: var(
|
|
679
|
+
background-color: var(
|
|
680
|
+
--ui-icon-button-solid-surface,
|
|
681
|
+
var(--_icon-button-solid-surface, var(--ui-accent-solid))
|
|
682
|
+
);
|
|
634
683
|
background-image: var(--ui-raised-highlight);
|
|
635
|
-
color: var(--ui-icon-button-solid-text, var(--ui-text-on-accent));
|
|
684
|
+
color: var(--ui-icon-button-solid-text, var(--_icon-button-solid-text, var(--ui-text-on-accent)));
|
|
636
685
|
box-shadow: var(
|
|
637
686
|
--ui-icon-button-solid-shadow,
|
|
638
687
|
0 1px 2px color-mix(in srgb, var(--ui-accent-solid) 18%, transparent)
|
|
@@ -645,18 +694,26 @@ html[data-ui-input-modality="touch"] [data-component~="ui-icon-button"]::after {
|
|
|
645
694
|
--ui-icon-button-hover-surface,
|
|
646
695
|
color-mix(in srgb, currentColor 8%, transparent)
|
|
647
696
|
);
|
|
648
|
-
color: var(--ui-icon-button-hover-text, var(--ui-text-primary));
|
|
697
|
+
color: var(--ui-icon-button-hover-text, var(--_icon-button-text, var(--ui-text-primary)));
|
|
649
698
|
}
|
|
650
699
|
|
|
651
700
|
[data-component~="ui-icon-button"][data-ui-icon-button-state~="variant=outline"]:hover:enabled:not([aria-disabled="true"]) {
|
|
652
701
|
border-color: var(
|
|
653
702
|
--ui-icon-button-hover-border,
|
|
654
|
-
var(--ui-control-border-hover, var(--ui-control-border))
|
|
703
|
+
var(--_icon-button-hover-border, var(--ui-control-border-hover, var(--ui-control-border)))
|
|
655
704
|
);
|
|
656
705
|
}
|
|
657
706
|
|
|
658
707
|
[data-component~="ui-icon-button"][data-ui-icon-button-state~="variant=solid"]:hover:enabled:not([aria-disabled="true"]) {
|
|
659
|
-
background-color: var(
|
|
708
|
+
background-color: var(
|
|
709
|
+
--ui-icon-button-solid-hover-surface,
|
|
710
|
+
var(--_icon-button-solid-hover-surface, var(--ui-accent-hover))
|
|
711
|
+
);
|
|
712
|
+
}
|
|
713
|
+
|
|
714
|
+
[data-component~="ui-icon-button"][data-ui-icon-button-state~="variant=solid"][data-ui-icon-button-state~="tone=accent"]:hover:enabled:not([aria-disabled="true"]),
|
|
715
|
+
[data-component~="ui-icon-button"][data-ui-icon-button-state~="variant=solid"][data-ui-icon-button-state~="tone=neutral"]:hover:enabled:not([aria-disabled="true"]) {
|
|
716
|
+
color: var(--ui-icon-button-solid-text, var(--_icon-button-solid-text, var(--ui-text-on-accent)));
|
|
660
717
|
}
|
|
661
718
|
|
|
662
719
|
[data-component~="ui-icon-button"][data-ui-icon-button-state~="variant=ghost"][aria-expanded="true"]:enabled:not([aria-disabled="true"]) {
|
|
@@ -664,7 +721,17 @@ html[data-ui-input-modality="touch"] [data-component~="ui-icon-button"]::after {
|
|
|
664
721
|
--ui-icon-button-active-surface,
|
|
665
722
|
color-mix(in srgb, currentColor 16%, transparent)
|
|
666
723
|
);
|
|
667
|
-
color: var(--ui-icon-button-hover-text, var(--ui-text-primary));
|
|
724
|
+
color: var(--ui-icon-button-hover-text, var(--_icon-button-text, var(--ui-text-primary)));
|
|
725
|
+
box-shadow: var(--ui-pressed);
|
|
726
|
+
}
|
|
727
|
+
|
|
728
|
+
/* Native toggle state persists after pointer release, including during loading. */
|
|
729
|
+
[data-component~="ui-icon-button"][data-ui-icon-button-state~="variant=outline"][aria-pressed="true"]:enabled {
|
|
730
|
+
background-color: var(
|
|
731
|
+
--ui-icon-button-active-surface,
|
|
732
|
+
color-mix(in srgb, currentColor 12%, var(--ui-surface-default))
|
|
733
|
+
);
|
|
734
|
+
background-image: none;
|
|
668
735
|
box-shadow: var(--ui-pressed);
|
|
669
736
|
}
|
|
670
737
|
|
|
@@ -698,6 +765,22 @@ html[data-ui-input-modality="touch"] [data-component~="ui-icon-button"]::after {
|
|
|
698
765
|
box-shadow: var(--ui-focus-halo);
|
|
699
766
|
}
|
|
700
767
|
|
|
768
|
+
[data-component~="ui-icon-button"][data-ui-icon-button-state~="variant=outline"][aria-pressed="true"]:enabled:focus-visible {
|
|
769
|
+
box-shadow:
|
|
770
|
+
var(--ui-pressed),
|
|
771
|
+
var(--ui-focus-halo);
|
|
772
|
+
}
|
|
773
|
+
|
|
774
|
+
@media (forced-colors: active) {
|
|
775
|
+
[data-component~="ui-icon-button"][data-ui-icon-button-state~="variant=outline"][aria-pressed="true"]:enabled {
|
|
776
|
+
outline: var(--ui-focus-width) solid Highlight;
|
|
777
|
+
outline-offset: calc(-2 * var(--ui-focus-width));
|
|
778
|
+
}
|
|
779
|
+
[data-component~="ui-icon-button"][data-ui-icon-button-state~="variant=outline"][aria-pressed="true"]:enabled:focus-visible {
|
|
780
|
+
outline-offset: var(--ui-focus-width);
|
|
781
|
+
}
|
|
782
|
+
}
|
|
783
|
+
|
|
701
784
|
/* Disabled is a flat neutral control, independent of the active variant's tone. */
|
|
702
785
|
[data-component~="ui-icon-button"]:disabled {
|
|
703
786
|
border-color: var(--ui-disabled-border);
|
package/vue/chunks/UiBadge.js
CHANGED
|
@@ -46,12 +46,13 @@ var UiBadge_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PURE
|
|
|
46
46
|
},
|
|
47
47
|
required: false,
|
|
48
48
|
target: { attribute: "shape" },
|
|
49
|
-
description: "Silhouette. pill is rounded at both ends; tag is a pointed label. dot is a compact circular signal with visually hidden text: include a state label, or set\n aria-hidden when the surrounding control already names that state. square is a fixed rounded square for an icon or single glyph beside a heading; hide a\n decorative icon when adjacent words name it.",
|
|
49
|
+
description: "Silhouette. pill is rounded at both ends; tag is a pointed label. dot is a compact circular signal with visually hidden text: include a state label, or set\n aria-hidden when the surrounding control already names that state. square is a fixed rounded square for an icon or single glyph beside a heading; hide a\n decorative icon when adjacent words name it. circle frames a visible single glyph or icon in a fixed circle, centered in both directions.",
|
|
50
50
|
values: [
|
|
51
51
|
"pill",
|
|
52
52
|
"tag",
|
|
53
53
|
"dot",
|
|
54
|
-
"square"
|
|
54
|
+
"square",
|
|
55
|
+
"circle"
|
|
55
56
|
],
|
|
56
57
|
default: "pill"
|
|
57
58
|
},
|
|
@@ -62,7 +63,7 @@ var UiBadge_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PURE
|
|
|
62
63
|
},
|
|
63
64
|
required: false,
|
|
64
65
|
target: { attribute: "size" },
|
|
65
|
-
description: "Scale. xs is a compact count beside small controls; md is the usual text badge. A square is 24px at xs and 32px at md with default spacing.",
|
|
66
|
+
description: "Scale. xs is a compact count beside small controls; md is the usual text badge. A square is 24px at xs and 32px at md with default spacing. A circle is\n 16px at xs and 24px at md.",
|
|
66
67
|
values: ["xs", "md"],
|
|
67
68
|
default: "md"
|
|
68
69
|
},
|
|
@@ -173,6 +174,6 @@ var UiBadge_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PURE
|
|
|
173
174
|
}]]);
|
|
174
175
|
};
|
|
175
176
|
}
|
|
176
|
-
}), [["__scopeId", "data-v-
|
|
177
|
+
}), [["__scopeId", "data-v-c96818e7"]]);
|
|
177
178
|
//#endregion
|
|
178
179
|
export { UiBadge_default as t };
|
|
@@ -3,6 +3,7 @@ import { a as vPropValidity, n as checkedProp } from "./props.js";
|
|
|
3
3
|
import { computed, createElementBlock, defineComponent, getCurrentInstance, mergeProps, openBlock, renderSlot, unref, watchSyncEffect, withDirectives } from "vue";
|
|
4
4
|
//#region .build/vue/UiContainer.vue?vue&type=script&setup=true&lang.ts
|
|
5
5
|
var _hoisted_1 = [
|
|
6
|
+
"data-fill",
|
|
6
7
|
"data-gutters",
|
|
7
8
|
"data-measure",
|
|
8
9
|
"data-ui-container-state"
|
|
@@ -13,6 +14,10 @@ var UiContainer_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__
|
|
|
13
14
|
inheritAttrs: false,
|
|
14
15
|
__name: "UiContainer",
|
|
15
16
|
props: {
|
|
17
|
+
fill: {
|
|
18
|
+
type: null,
|
|
19
|
+
default: false
|
|
20
|
+
},
|
|
16
21
|
gutters: {
|
|
17
22
|
type: null,
|
|
18
23
|
default: null
|
|
@@ -24,6 +29,16 @@ var UiContainer_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__
|
|
|
24
29
|
},
|
|
25
30
|
setup(__props) {
|
|
26
31
|
const propValidityContract = { props: {
|
|
32
|
+
fill: {
|
|
33
|
+
type: {
|
|
34
|
+
kind: "terminal",
|
|
35
|
+
name: "boolean"
|
|
36
|
+
},
|
|
37
|
+
required: false,
|
|
38
|
+
target: { attribute: "fill" },
|
|
39
|
+
description: "Keeps the readable width while filling available layout space. Uses a flex column so scrolling children can shrink inside a bounded flex or grid parent.\n Omit it to keep the usual block layout.",
|
|
40
|
+
default: false
|
|
41
|
+
},
|
|
27
42
|
gutters: {
|
|
28
43
|
type: {
|
|
29
44
|
kind: "terminal",
|
|
@@ -51,10 +66,15 @@ var UiContainer_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__
|
|
|
51
66
|
} };
|
|
52
67
|
const props = __props;
|
|
53
68
|
const acceptedProps = {
|
|
69
|
+
fill: false,
|
|
54
70
|
gutters: null,
|
|
55
71
|
measure: null
|
|
56
72
|
};
|
|
57
73
|
const checkedProps = computed(() => ({
|
|
74
|
+
fill: checkedProp(props["fill"], {
|
|
75
|
+
kind: "terminal",
|
|
76
|
+
name: "boolean"
|
|
77
|
+
}, false, "fill", acceptedProps),
|
|
58
78
|
gutters: checkedProp(props["gutters"], {
|
|
59
79
|
kind: "terminal",
|
|
60
80
|
name: "keyword"
|
|
@@ -92,11 +112,13 @@ var UiContainer_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__
|
|
|
92
112
|
const hostState = computed(() => [
|
|
93
113
|
checkedProps.value.measure && "measure",
|
|
94
114
|
checkedProps.value.measure != null && `measure=${encodeURIComponent(checkedProps.value.measure)}`,
|
|
115
|
+
checkedProps.value.fill && "fill",
|
|
95
116
|
checkedProps.value.gutters && "gutters",
|
|
96
117
|
checkedProps.value.gutters != null && `gutters=${encodeURIComponent(checkedProps.value.gutters)}`
|
|
97
118
|
].filter(Boolean).join(" "));
|
|
98
119
|
return (_ctx, _cache) => {
|
|
99
120
|
return withDirectives((openBlock(), createElementBlock("div", mergeProps({ "data-component": "ui-container" }, nativeAttrs(_ctx.$attrs), {
|
|
121
|
+
"data-fill": reflectedProp("fill", "fill", checkedProps.value.fill, void 0, false),
|
|
100
122
|
"data-gutters": reflectedProp("gutters", "gutters", checkedProps.value.gutters, void 0, false),
|
|
101
123
|
"data-measure": reflectedProp("measure", "measure", checkedProps.value.measure, void 0, false),
|
|
102
124
|
"data-ui-container-state": hostState.value || void 0
|
|
@@ -106,6 +128,6 @@ var UiContainer_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__
|
|
|
106
128
|
}]]);
|
|
107
129
|
};
|
|
108
130
|
}
|
|
109
|
-
}), [["__scopeId", "data-v-
|
|
131
|
+
}), [["__scopeId", "data-v-d3919ea4"]]);
|
|
110
132
|
//#endregion
|
|
111
133
|
export { UiContainer_default as t };
|
|
@@ -17,6 +17,7 @@ var _hoisted_1 = [
|
|
|
17
17
|
"data-pending",
|
|
18
18
|
"data-round",
|
|
19
19
|
"data-size",
|
|
20
|
+
"data-tone",
|
|
20
21
|
"data-variant",
|
|
21
22
|
"data-ui-icon-button-state"
|
|
22
23
|
];
|
|
@@ -59,6 +60,10 @@ var UiIconButton_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @_
|
|
|
59
60
|
type: null,
|
|
60
61
|
default: "md"
|
|
61
62
|
},
|
|
63
|
+
tone: {
|
|
64
|
+
type: null,
|
|
65
|
+
default: null
|
|
66
|
+
},
|
|
62
67
|
variant: {
|
|
63
68
|
type: null,
|
|
64
69
|
default: "ghost"
|
|
@@ -150,6 +155,16 @@ var UiIconButton_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @_
|
|
|
150
155
|
],
|
|
151
156
|
default: "md"
|
|
152
157
|
},
|
|
158
|
+
tone: {
|
|
159
|
+
type: {
|
|
160
|
+
kind: "terminal",
|
|
161
|
+
name: "keyword"
|
|
162
|
+
},
|
|
163
|
+
required: false,
|
|
164
|
+
target: { attribute: "tone" },
|
|
165
|
+
description: "Colour for every variant. When omitted, ghost and outline keep their neutral appearance and solid keeps its accent fill. Set accent for a coloured action\n or neutral for a quiet one. Native aria-pressed=\"true\" keeps an outline toggle visibly pressed; the consumer owns that state.",
|
|
166
|
+
values: ["accent", "neutral"]
|
|
167
|
+
},
|
|
153
168
|
variant: {
|
|
154
169
|
type: {
|
|
155
170
|
kind: "terminal",
|
|
@@ -176,6 +191,7 @@ var UiIconButton_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @_
|
|
|
176
191
|
pending: false,
|
|
177
192
|
round: false,
|
|
178
193
|
size: "md",
|
|
194
|
+
tone: null,
|
|
179
195
|
variant: "ghost"
|
|
180
196
|
};
|
|
181
197
|
const checkedProps = computed(() => ({
|
|
@@ -211,6 +227,10 @@ var UiIconButton_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @_
|
|
|
211
227
|
kind: "terminal",
|
|
212
228
|
name: "keyword"
|
|
213
229
|
}, false, "size", acceptedProps),
|
|
230
|
+
tone: checkedProp(props["tone"], {
|
|
231
|
+
kind: "terminal",
|
|
232
|
+
name: "keyword"
|
|
233
|
+
}, false, "tone", acceptedProps),
|
|
214
234
|
variant: checkedProp(props["variant"], {
|
|
215
235
|
kind: "terminal",
|
|
216
236
|
name: "keyword"
|
|
@@ -261,6 +281,8 @@ var UiIconButton_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @_
|
|
|
261
281
|
});
|
|
262
282
|
/** The values the styles' :host-state() rules test. */
|
|
263
283
|
const hostState = computed(() => [
|
|
284
|
+
checkedProps.value.tone && "tone",
|
|
285
|
+
checkedProps.value.tone != null && `tone=${encodeURIComponent(checkedProps.value.tone)}`,
|
|
264
286
|
checkedProps.value.anticipatory && "anticipatory",
|
|
265
287
|
checkedProps.value.variant && "variant",
|
|
266
288
|
checkedProps.value.variant != null && `variant=${encodeURIComponent(checkedProps.value.variant)}`,
|
|
@@ -294,6 +316,7 @@ var UiIconButton_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @_
|
|
|
294
316
|
"pending",
|
|
295
317
|
"round",
|
|
296
318
|
"size",
|
|
319
|
+
"tone",
|
|
297
320
|
"variant"
|
|
298
321
|
],
|
|
299
322
|
propValidity: (name) => propValidityState({
|
|
@@ -332,6 +355,7 @@ var UiIconButton_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @_
|
|
|
332
355
|
"data-pending": reflectedProp("pending", "pending", checkedProps.value.pending, void 0, false),
|
|
333
356
|
"data-round": reflectedProp("round", "round", checkedProps.value.round, void 0, false),
|
|
334
357
|
"data-size": reflectedProp("size", "size", checkedProps.value.size, void 0, false),
|
|
358
|
+
"data-tone": reflectedProp("tone", "tone", checkedProps.value.tone, void 0, false),
|
|
335
359
|
"data-variant": reflectedProp("variant", "variant", checkedProps.value.variant, void 0, false),
|
|
336
360
|
"data-ui-icon-button-state": hostState.value || void 0,
|
|
337
361
|
ref_key: "root",
|
|
@@ -345,6 +369,6 @@ var UiIconButton_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @_
|
|
|
345
369
|
}]]);
|
|
346
370
|
};
|
|
347
371
|
}
|
|
348
|
-
}), [["__scopeId", "data-v-
|
|
372
|
+
}), [["__scopeId", "data-v-b66a1661"]]);
|
|
349
373
|
//#endregion
|
|
350
374
|
export { UiIconButton_default as t };
|