@threadlabs/looma 0.42.0 → 0.43.1
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-action-bar/ui-action-bar.html +1 -7
- package/components/ui-affordance-scope/ui-affordance-scope.html +4 -4
- package/components/ui-avatar/ui-avatar.html +0 -22
- package/components/ui-avatar-group/ui-avatar-group.html +1 -11
- package/components/ui-badge/ui-badge.html +57 -78
- package/components/ui-button/ui-button.html +36 -81
- package/components/ui-callout/ui-callout.html +30 -68
- package/components/ui-card/ui-card.html +47 -21
- package/components/ui-checkbox/ui-checkbox.html +1 -15
- package/components/ui-cluster/ui-cluster.html +1 -7
- package/components/ui-combobox/ui-combobox.html +7 -70
- package/components/ui-container/ui-container.html +2 -12
- package/components/ui-context-menu/ui-context-menu.html +1 -23
- package/components/ui-dialog/ui-dialog.html +1 -31
- package/components/ui-disclosure/ui-disclosure.html +1 -15
- package/components/ui-editor-mention-menu/ui-editor-mention-menu.js +3 -0
- package/components/ui-editor-slash-menu/ui-editor-slash-menu.js +4 -0
- package/components/ui-editor-table-overlay/ui-editor-table-overlay.html +3 -2
- package/components/ui-floating-action-button/ui-floating-action-button.html +0 -14
- package/components/ui-form-field/ui-form-field.html +2 -32
- package/components/ui-grid/ui-grid.html +1 -11
- package/components/ui-icon/ui-icon.html +1 -12
- package/components/ui-icon-button/ui-icon-button.html +52 -87
- package/components/ui-input/ui-input.html +5 -55
- package/components/ui-input-group/ui-input-group.html +1 -13
- package/components/ui-list/ui-list.html +0 -10
- package/components/ui-list-item/ui-list-item.html +1 -19
- package/components/ui-listbox/ui-listbox.html +0 -21
- package/components/ui-menu/ui-menu.html +0 -22
- package/components/ui-menu-item/ui-menu-item.html +0 -26
- package/components/ui-meter/ui-meter.html +11 -6
- package/components/ui-nav-item/ui-nav-item.html +0 -18
- package/components/ui-popover/ui-popover.html +0 -30
- package/components/ui-radio/ui-radio.html +7 -13
- package/components/ui-radio-group/ui-radio-group.html +0 -5
- package/components/ui-reel/ui-reel.html +1 -11
- package/components/ui-search-result-row/ui-search-result-row.html +0 -34
- package/components/ui-search-shell/ui-search-shell.html +1 -43
- package/components/ui-select/ui-select.html +0 -42
- package/components/ui-separator/ui-separator.html +0 -6
- package/components/ui-sidebar/ui-sidebar.html +2 -24
- package/components/ui-site-header/ui-site-header.html +0 -25
- package/components/ui-skeleton/ui-skeleton.html +0 -9
- package/components/ui-stack/ui-stack.html +6 -11
- package/components/ui-swatch/ui-swatch.html +0 -5
- package/components/ui-switch/ui-switch.html +1 -15
- package/components/ui-switcher/ui-switcher.html +1 -11
- package/components/ui-tabs/ui-tabs.html +1 -19
- package/components/ui-text/ui-text.html +19 -6
- package/components/ui-textarea/ui-textarea.html +0 -50
- package/components/ui-toast/ui-toast.html +12 -27
- package/components/ui-toast-region/ui-toast-region.html +13 -34
- package/components/ui-tooltip/ui-tooltip.html +1 -43
- package/components/ui-top-bar/ui-top-bar.html +1 -31
- package/components/ui-tree/ui-tree.html +1 -16
- package/components/ui-tree-item/ui-tree-item.html +1 -23
- package/components/ui-tree-item/ui-tree-item.js +0 -1
- package/dist/index.js +1 -1
- package/docs/README.md +13 -11
- package/docs/card.html +2 -6
- package/docs/card.js +7 -37
- package/docs/catalog.json +821 -202
- package/docs/catalog.mjs +1 -1
- package/docs/customizer-render.mjs +27 -14
- package/docs/customizer.js +42 -9
- package/docs/documentation.css +3 -7
- package/docs/examples/ui-button/examples/08-loading.behavior.js +1 -1
- package/docs/examples/ui-checkbox/examples/02-checked-indeterminate-and-disabled.behavior.js +1 -1
- package/docs/examples/ui-editor-mention-menu/examples/00-preview.behavior.js +1 -0
- package/docs/examples/ui-editor-slash-menu/examples/00-preview.behavior.js +81 -0
- package/docs/examples/ui-editor-table-overlay/examples/00-preview.behavior.js +24 -0
- package/docs/examples/ui-search-shell/examples/00-preview.behavior.js +14 -0
- package/docs/examples/ui-search-shell/examples/02-label-dismissible-status-and-footer.behavior.js +7 -7
- package/docs/examples/ui-toast/examples/01-authored.behavior.js +2 -2
- package/docs/index.d.ts +1 -1
- package/docs/local-server.mjs +2 -5
- package/docs/palette.mjs +5 -4
- package/docs/pastoral.svg +54 -0
- package/docs/portrait.svg +15 -0
- package/docs/render.mjs +33 -3
- package/docs/site.mjs +22 -54
- package/docs/theme.mjs +97 -35
- package/docs/value-editors.mjs +2 -1
- package/package.json +2 -2
- package/styles/ui-action-bar.css +3 -11
- package/styles/ui-affordance-scope.css +4 -4
- package/styles/ui-avatar-group.css +3 -15
- package/styles/ui-avatar.css +2 -26
- package/styles/ui-badge.css +56 -80
- package/styles/ui-button.css +35 -83
- package/styles/ui-callout.css +32 -72
- package/styles/ui-card.css +42 -18
- package/styles/ui-checkbox.css +3 -19
- package/styles/ui-cluster.css +2 -10
- package/styles/ui-combobox.css +7 -140
- package/styles/ui-container.css +2 -14
- package/styles/ui-context-menu.css +3 -27
- package/styles/ui-dialog.css +5 -67
- package/styles/ui-disclosure.css +3 -19
- package/styles/ui-editor-table-overlay.css +2 -2
- package/styles/ui-floating-action-button.css +2 -18
- package/styles/ui-form-field.css +4 -36
- package/styles/ui-grid.css +2 -14
- package/styles/ui-icon-button.css +51 -89
- package/styles/ui-icon.css +3 -16
- package/styles/ui-input-group.css +2 -14
- package/styles/ui-input.css +6 -57
- package/styles/ui-list-item.css +3 -23
- package/styles/ui-list.css +2 -14
- package/styles/ui-listbox.css +2 -44
- package/styles/ui-menu-item.css +2 -30
- package/styles/ui-menu.css +2 -26
- package/styles/ui-meter.css +8 -4
- package/styles/ui-nav-item.css +2 -22
- package/styles/ui-popover.css +2 -34
- package/styles/ui-radio-group.css +1 -6
- package/styles/ui-radio.css +9 -17
- package/styles/ui-reel.css +2 -14
- package/styles/ui-search-result-row.css +2 -38
- package/styles/ui-search-shell.css +3 -47
- package/styles/ui-select.css +2 -46
- package/styles/ui-separator.css +2 -10
- package/styles/ui-sidebar.css +4 -28
- package/styles/ui-site-header.css +1 -26
- package/styles/ui-skeleton.css +2 -12
- package/styles/ui-stack.css +4 -12
- package/styles/ui-swatch.css +1 -6
- package/styles/ui-switch.css +3 -19
- package/styles/ui-switcher.css +2 -14
- package/styles/ui-tabs.css +3 -23
- package/styles/ui-text.css +10 -2
- package/styles/ui-textarea.css +2 -54
- package/styles/ui-toast-region.css +29 -73
- package/styles/ui-toast.css +24 -54
- package/styles/ui-tooltip.css +3 -47
- package/styles/ui-top-bar.css +3 -35
- package/styles/ui-tree-item.css +5 -51
- package/styles/ui-tree.css +3 -20
- package/theme-system.css +6 -2
- package/tokens.css +55 -21
- package/vanilla/UiBadge.d.ts +1 -1
- package/vanilla/UiBadge.js +1 -1
- package/vanilla/UiButton.d.ts +1 -1
- package/vanilla/UiButton.js +1 -1
- package/vanilla/UiCard.d.ts +1 -1
- package/vanilla/UiCard.js +1 -1
- package/vanilla/UiEditorTableOverlay.js +50 -36
- package/vanilla/UiIconButton.d.ts +1 -1
- package/vanilla/UiIconButton.js +1 -1
- package/vanilla/UiMeter.d.ts +1 -1
- package/vanilla/UiMeter.js +1 -1
- package/vanilla/UiStack.js +1 -1
- package/vanilla/UiText.d.ts +1 -1
- package/vanilla/UiText.js +1 -1
- package/vue/UiActionBar.vue +3 -9
- package/vue/UiAffordanceScope.vue +4 -4
- package/vue/UiAvatar.vue +1 -28
- package/vue/UiAvatarGroup.vue +1 -11
- package/vue/UiBadge.d.ts +2 -2
- package/vue/UiBadge.vue +84 -81
- package/vue/UiButton.d.ts +2 -2
- package/vue/UiButton.vue +78 -97
- package/vue/UiCallout.vue +30 -71
- package/vue/UiCard.d.ts +2 -2
- package/vue/UiCard.vue +77 -26
- package/vue/UiCheckbox.vue +1 -15
- package/vue/UiCluster.vue +1 -10
- package/vue/UiCombobox.vue +13 -72
- package/vue/UiContainer.vue +1 -13
- package/vue/UiContextMenu.vue +1 -30
- package/vue/UiDialog.vue +3 -33
- package/vue/UiDisclosure.vue +1 -15
- package/vue/UiEditorTableOverlay.d.ts +11 -1
- package/vue/UiEditorTableOverlay.vue +100 -65
- package/vue/UiFloatingActionButton.vue +0 -22
- package/vue/UiFormField.vue +6 -33
- package/vue/UiGrid.vue +1 -13
- package/vue/UiIcon.vue +1 -16
- package/vue/UiIconButton.d.ts +2 -2
- package/vue/UiIconButton.vue +103 -99
- package/vue/UiInput.vue +1 -54
- package/vue/UiInputGroup.vue +8 -20
- package/vue/UiList.vue +2 -12
- package/vue/UiListItem.vue +8 -26
- package/vue/UiListbox.vue +0 -23
- package/vue/UiMenu.vue +1 -23
- package/vue/UiMenuItem.vue +0 -26
- package/vue/UiMeter.d.ts +2 -2
- package/vue/UiMeter.vue +47 -12
- package/vue/UiNavItem.vue +3 -21
- package/vue/UiPopover.vue +1 -32
- package/vue/UiRadio.vue +1 -11
- package/vue/UiRadioGroup.vue +0 -11
- package/vue/UiReel.vue +1 -11
- package/vue/UiSearchResultRow.vue +0 -35
- package/vue/UiSearchShell.vue +1 -53
- package/vue/UiSelect.vue +0 -42
- package/vue/UiSeparator.vue +0 -7
- package/vue/UiSidebar.vue +3 -26
- package/vue/UiSiteHeader.vue +0 -24
- package/vue/UiSkeleton.vue +0 -9
- package/vue/UiStack.vue +6 -11
- package/vue/UiSwatch.vue +1 -6
- package/vue/UiSwitch.vue +1 -15
- package/vue/UiSwitcher.vue +1 -14
- package/vue/UiTabs.vue +1 -19
- package/vue/UiText.d.ts +2 -2
- package/vue/UiText.vue +29 -4
- package/vue/UiTextarea.vue +0 -50
- package/vue/UiToast.vue +26 -34
- package/vue/UiToastRegion.vue +26 -55
- package/vue/UiTooltip.vue +1 -43
- package/vue/UiTopBar.vue +1 -34
- package/vue/UiTree.vue +2 -17
- package/vue/UiTreeItem.vue +2 -28
- package/vue/chunks/UiActionBar.js +1 -1
- package/vue/chunks/UiAffordanceScope.js +1 -1
- package/vue/chunks/UiAvatar.js +1 -1
- package/vue/chunks/UiAvatarGroup.js +1 -1
- package/vue/chunks/UiBadge.js +4 -2
- package/vue/chunks/UiButton.js +4 -2
- package/vue/chunks/UiCallout.js +1 -1
- package/vue/chunks/UiCard.js +5 -3
- package/vue/chunks/UiCheckbox.js +1 -1
- package/vue/chunks/UiCluster.js +2 -2
- package/vue/chunks/UiCombobox.js +3 -3
- package/vue/chunks/UiContainer.js +2 -2
- package/vue/chunks/UiContextMenu.js +1 -1
- package/vue/chunks/UiDialog.js +1 -1
- package/vue/chunks/UiDisclosure.js +1 -1
- package/vue/chunks/UiEditorTableOverlay.js +41 -13
- package/vue/chunks/UiFloatingActionButton.js +1 -1
- package/vue/chunks/UiFormField.js +1 -1
- package/vue/chunks/UiGrid.js +2 -2
- package/vue/chunks/UiIcon.js +1 -1
- package/vue/chunks/UiIconButton.js +4 -2
- package/vue/chunks/UiInput.js +1 -1
- package/vue/chunks/UiInputGroup.js +1 -1
- package/vue/chunks/UiList.js +1 -1
- package/vue/chunks/UiListItem.js +1 -1
- package/vue/chunks/UiListbox.js +1 -1
- package/vue/chunks/UiMenu.js +1 -1
- package/vue/chunks/UiMenuItem.js +1 -1
- package/vue/chunks/UiMeter.js +4 -2
- package/vue/chunks/UiNavItem.js +1 -1
- package/vue/chunks/UiPopover.js +1 -1
- package/vue/chunks/UiRadio.js +1 -1
- package/vue/chunks/UiRadioGroup.js +1 -1
- package/vue/chunks/UiReel.js +2 -2
- package/vue/chunks/UiSearchResultRow.js +1 -1
- package/vue/chunks/UiSearchShell.js +1 -1
- package/vue/chunks/UiSelect.js +1 -1
- package/vue/chunks/UiSeparator.js +1 -1
- package/vue/chunks/UiSidebar.js +1 -1
- package/vue/chunks/UiSiteHeader.js +1 -1
- package/vue/chunks/UiSkeleton.js +1 -1
- package/vue/chunks/UiStack.js +3 -3
- package/vue/chunks/UiSwatch.js +1 -1
- package/vue/chunks/UiSwitch.js +1 -1
- package/vue/chunks/UiSwitcher.js +2 -2
- package/vue/chunks/UiTabs.js +1 -1
- package/vue/chunks/UiText.js +4 -2
- package/vue/chunks/UiTextarea.js +1 -1
- package/vue/chunks/UiToast.js +1 -1
- package/vue/chunks/UiToastRegion.js +1 -1
- package/vue/chunks/UiTooltip.js +1 -1
- package/vue/chunks/UiTopBar.js +1 -1
- package/vue/chunks/UiTree.js +1 -1
- package/vue/chunks/UiTreeItem.js +1 -1
- package/vue/components.css +633 -2068
- package/vue/editor/index.js +7 -1
- package/docs/preview.js +0 -22
package/vue/UiButton.vue
CHANGED
|
@@ -134,8 +134,17 @@ const propValidityContract = {
|
|
|
134
134
|
required: false,
|
|
135
135
|
target: { attribute: 'tone' },
|
|
136
136
|
description:
|
|
137
|
-
'Which colour the button speaks in. It applies to every variant, so an outline, a ghost, and a solid in the same tone are the same action at three volumes:\n tone="danger" variant="outline" is a destructive secondary action. neutral is the quiet one, for a button that should not claim a colour. The field\n variant always uses neutral field colors.',
|
|
138
|
-
values: [
|
|
137
|
+
'Which colour the button speaks in. It applies to every variant, so an outline, a ghost, and a solid in the same tone are the same action at three volumes:\n tone="danger" variant="outline" is a destructive secondary action. neutral is the quiet one, for a button that should not claim a colour. The field\n variant always uses neutral field colors. Supporting brand families use accent-secondary and accent-tertiary; their usable colors derive from the theme,\n and unset families follow the primary accent.',
|
|
138
|
+
values: [
|
|
139
|
+
'accent',
|
|
140
|
+
'accent-secondary',
|
|
141
|
+
'accent-tertiary',
|
|
142
|
+
'neutral',
|
|
143
|
+
'danger',
|
|
144
|
+
'success',
|
|
145
|
+
'warning',
|
|
146
|
+
'info',
|
|
147
|
+
],
|
|
139
148
|
default: 'neutral',
|
|
140
149
|
},
|
|
141
150
|
type: {
|
|
@@ -177,7 +186,15 @@ const props = defineProps({
|
|
|
177
186
|
target: { type: null as unknown as PropType<string | null> },
|
|
178
187
|
tone: {
|
|
179
188
|
type: null as unknown as PropType<
|
|
180
|
-
|
|
189
|
+
| 'accent'
|
|
190
|
+
| 'accent-secondary'
|
|
191
|
+
| 'accent-tertiary'
|
|
192
|
+
| 'neutral'
|
|
193
|
+
| 'danger'
|
|
194
|
+
| 'success'
|
|
195
|
+
| 'warning'
|
|
196
|
+
| 'info'
|
|
197
|
+
| null
|
|
181
198
|
>,
|
|
182
199
|
},
|
|
183
200
|
type: { type: null as unknown as PropType<'button' | 'submit' | 'reset' | null> },
|
|
@@ -308,11 +325,25 @@ const checkedProps = computed(() => {
|
|
|
308
325
|
props[BINDING_INPUTS_PROP],
|
|
309
326
|
) as boolean,
|
|
310
327
|
target: propInputs.value<string | null>('target', props['target'], props[BINDING_INPUTS_PROP]),
|
|
311
|
-
tone: propInputs.value<
|
|
312
|
-
'
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
328
|
+
tone: propInputs.value<
|
|
329
|
+
| 'accent'
|
|
330
|
+
| 'accent-secondary'
|
|
331
|
+
| 'accent-tertiary'
|
|
332
|
+
| 'neutral'
|
|
333
|
+
| 'danger'
|
|
334
|
+
| 'success'
|
|
335
|
+
| 'warning'
|
|
336
|
+
| 'info'
|
|
337
|
+
| null
|
|
338
|
+
>('tone', props['tone'], props[BINDING_INPUTS_PROP]) as
|
|
339
|
+
| 'accent'
|
|
340
|
+
| 'accent-secondary'
|
|
341
|
+
| 'accent-tertiary'
|
|
342
|
+
| 'neutral'
|
|
343
|
+
| 'danger'
|
|
344
|
+
| 'success'
|
|
345
|
+
| 'warning'
|
|
346
|
+
| 'info',
|
|
316
347
|
type: propInputs.value<'button' | 'submit' | 'reset' | null>(
|
|
317
348
|
'type',
|
|
318
349
|
props['type'],
|
|
@@ -930,80 +961,6 @@ useComponentHost(() => import('../components/ui-button/ui-button.js'), {
|
|
|
930
961
|
</template>
|
|
931
962
|
|
|
932
963
|
<style scoped>
|
|
933
|
-
/* This component's hooks style the element they are set on, and never a nested one. */
|
|
934
|
-
@property --ui-button-active-surface {
|
|
935
|
-
syntax: "*";
|
|
936
|
-
inherits: false;
|
|
937
|
-
}
|
|
938
|
-
@property --ui-button-border {
|
|
939
|
-
syntax: "*";
|
|
940
|
-
inherits: false;
|
|
941
|
-
}
|
|
942
|
-
@property --ui-button-disabled-filter {
|
|
943
|
-
syntax: "*";
|
|
944
|
-
inherits: false;
|
|
945
|
-
}
|
|
946
|
-
@property --ui-button-disabled-opacity {
|
|
947
|
-
syntax: "*";
|
|
948
|
-
inherits: false;
|
|
949
|
-
}
|
|
950
|
-
@property --ui-button-ghost-active-surface {
|
|
951
|
-
syntax: "*";
|
|
952
|
-
inherits: false;
|
|
953
|
-
}
|
|
954
|
-
@property --ui-button-ghost-hover-surface {
|
|
955
|
-
syntax: "*";
|
|
956
|
-
inherits: false;
|
|
957
|
-
}
|
|
958
|
-
@property --ui-button-ghost-text {
|
|
959
|
-
syntax: "*";
|
|
960
|
-
inherits: false;
|
|
961
|
-
}
|
|
962
|
-
@property --ui-button-hover-border {
|
|
963
|
-
syntax: "*";
|
|
964
|
-
inherits: false;
|
|
965
|
-
}
|
|
966
|
-
@property --ui-button-hover-surface {
|
|
967
|
-
syntax: "*";
|
|
968
|
-
inherits: false;
|
|
969
|
-
}
|
|
970
|
-
@property --ui-button-link-hover-text {
|
|
971
|
-
syntax: "*";
|
|
972
|
-
inherits: false;
|
|
973
|
-
}
|
|
974
|
-
@property --ui-button-link-text {
|
|
975
|
-
syntax: "*";
|
|
976
|
-
inherits: false;
|
|
977
|
-
}
|
|
978
|
-
@property --ui-button-min-block-size {
|
|
979
|
-
syntax: "*";
|
|
980
|
-
inherits: false;
|
|
981
|
-
}
|
|
982
|
-
@property --ui-button-radius {
|
|
983
|
-
syntax: "*";
|
|
984
|
-
inherits: false;
|
|
985
|
-
}
|
|
986
|
-
@property --ui-button-shadow {
|
|
987
|
-
syntax: "*";
|
|
988
|
-
inherits: false;
|
|
989
|
-
}
|
|
990
|
-
@property --ui-button-solid-shadow {
|
|
991
|
-
syntax: "*";
|
|
992
|
-
inherits: false;
|
|
993
|
-
}
|
|
994
|
-
@property --ui-button-surface {
|
|
995
|
-
syntax: "*";
|
|
996
|
-
inherits: false;
|
|
997
|
-
}
|
|
998
|
-
@property --ui-button-text {
|
|
999
|
-
syntax: "*";
|
|
1000
|
-
inherits: false;
|
|
1001
|
-
}
|
|
1002
|
-
@property --ui-button-white-space {
|
|
1003
|
-
syntax: "*";
|
|
1004
|
-
inherits: false;
|
|
1005
|
-
}
|
|
1006
|
-
|
|
1007
964
|
/* An anchor keeps the boxed button look even when an app styles ordinary links. */
|
|
1008
965
|
|
|
1009
966
|
/* A count is an adornment, not another line of label text. Keep the standard control height
|
|
@@ -1091,21 +1048,17 @@ useComponentHost(() => import('../components/ui-button/ui-button.js'), {
|
|
|
1091
1048
|
vertical-align: middle;
|
|
1092
1049
|
color: var(--_tone-text);
|
|
1093
1050
|
}
|
|
1094
|
-
|
|
1095
1051
|
:global(:scope:dir(rtl):where([data-hn-ui-button])) {
|
|
1096
1052
|
--_ui-action-start: -1px;
|
|
1097
1053
|
}
|
|
1098
|
-
|
|
1099
1054
|
:global(:scope[data-ui-button-state~="align=start"]:where([data-hn-ui-button])) {
|
|
1100
1055
|
justify-content: flex-start !important;
|
|
1101
1056
|
text-align: start;
|
|
1102
1057
|
}
|
|
1103
|
-
|
|
1104
1058
|
:global(:scope[data-ui-button-state~="stretch"]:where([data-hn-ui-button])) {
|
|
1105
1059
|
display: flex !important;
|
|
1106
1060
|
inline-size: 100%;
|
|
1107
1061
|
}
|
|
1108
|
-
|
|
1109
1062
|
:global(:scope:where([data-hn-ui-button])) {
|
|
1110
1063
|
--_button-square-size: var(--ui-button-min-block-size, var(--ui-control-size-md));
|
|
1111
1064
|
box-sizing: border-box !important;
|
|
@@ -1302,10 +1255,42 @@ useComponentHost(() => import('../components/ui-button/ui-button.js'), {
|
|
|
1302
1255
|
background-image: none;
|
|
1303
1256
|
box-shadow: var(--ui-pressed);
|
|
1304
1257
|
}
|
|
1258
|
+
:global(:scope[data-tone="accent-secondary"]:where([data-hn-ui-button])) {
|
|
1259
|
+
--_tone-border: var(--ui-accent-secondary-border, var(--ui-accent-secondary));
|
|
1260
|
+
--_tone-hover-border: var(--ui-accent-secondary-hover-border, var(--ui-accent-secondary-hover));
|
|
1261
|
+
--_tone-active-border: var(
|
|
1262
|
+
--ui-accent-secondary-active-border,
|
|
1263
|
+
var(--ui-accent-secondary-active)
|
|
1264
|
+
);
|
|
1265
|
+
--_tone-highlight: var(--ui-accent-secondary-highlight, none);
|
|
1266
|
+
--_tone-glow: var(--ui-accent-secondary-glow, 0 0 transparent);
|
|
1267
|
+
--_hue: var(--ui-accent-secondary);
|
|
1268
|
+
--_hue-hover: var(--ui-accent-secondary-hover);
|
|
1269
|
+
--_hue-active: var(--ui-accent-secondary-active);
|
|
1270
|
+
--_hue-text: var(--ui-accent-secondary-subtle-text);
|
|
1271
|
+
--_on-hue: var(--ui-accent-secondary-on-strong);
|
|
1272
|
+
}
|
|
1273
|
+
|
|
1274
|
+
:global(:scope[data-tone="accent-tertiary"]:where([data-hn-ui-button])) {
|
|
1275
|
+
--_tone-border: var(--ui-accent-tertiary-border, var(--ui-accent-tertiary));
|
|
1276
|
+
--_tone-hover-border: var(--ui-accent-tertiary-hover-border, var(--ui-accent-tertiary-hover));
|
|
1277
|
+
--_tone-active-border: var(
|
|
1278
|
+
--ui-accent-tertiary-active-border,
|
|
1279
|
+
var(--ui-accent-tertiary-active)
|
|
1280
|
+
);
|
|
1281
|
+
--_tone-highlight: var(--ui-accent-tertiary-highlight, none);
|
|
1282
|
+
--_tone-glow: var(--ui-accent-tertiary-glow, 0 0 transparent);
|
|
1283
|
+
--_hue: var(--ui-accent-tertiary);
|
|
1284
|
+
--_hue-hover: var(--ui-accent-tertiary-hover);
|
|
1285
|
+
--_hue-active: var(--ui-accent-tertiary-active);
|
|
1286
|
+
--_hue-text: var(--ui-accent-tertiary-subtle-text);
|
|
1287
|
+
--_on-hue: var(--ui-accent-tertiary-on-strong);
|
|
1288
|
+
}
|
|
1289
|
+
|
|
1305
1290
|
:global(:scope[data-tone="neutral"]:where([data-hn-ui-button])) {
|
|
1306
|
-
--_tone-border: var(--ui-
|
|
1307
|
-
--_tone-hover-border: var(--ui-
|
|
1308
|
-
--_tone-active-border: var(--ui-
|
|
1291
|
+
--_tone-border: var(--ui-control-border, var(--ui-neutral-surface));
|
|
1292
|
+
--_tone-hover-border: var(--ui-control-border-hover, var(--ui-neutral-hover));
|
|
1293
|
+
--_tone-active-border: var(--ui-control-border-hover, var(--ui-neutral-active));
|
|
1309
1294
|
--_tone-highlight: var(--ui-neutral-highlight, none);
|
|
1310
1295
|
--_tone-glow: var(--ui-neutral-glow, 0 0 transparent);
|
|
1311
1296
|
--_hue: var(--ui-text);
|
|
@@ -1318,24 +1303,20 @@ useComponentHost(() => import('../components/ui-button/ui-button.js'), {
|
|
|
1318
1303
|
:global(:scope[data-tone="neutral"][data-appearance="solid"]:where([data-hn-ui-button])) {
|
|
1319
1304
|
border-color: var(--ui-button-border, var(--_tone-border));
|
|
1320
1305
|
background-color: var(--ui-button-surface, var(--ui-neutral-surface));
|
|
1306
|
+
box-shadow: var(--ui-button-solid-shadow, var(--ui-button-shadow, var(--ui-neutral-shadow)));
|
|
1321
1307
|
color: var(--ui-button-text, var(--ui-text));
|
|
1322
1308
|
}
|
|
1323
1309
|
:global(:scope[data-tone="neutral"][data-appearance="outline"]:where([data-hn-ui-button])) {
|
|
1324
1310
|
border-color: var(--ui-button-border, var(--ui-control-border));
|
|
1325
1311
|
background-color: var(--ui-button-surface, transparent);
|
|
1312
|
+
box-shadow: var(--ui-button-shadow, var(--ui-neutral-shadow));
|
|
1326
1313
|
}
|
|
1327
1314
|
:global(:scope[data-tone="neutral"][data-appearance="outline"]:hover:not(:disabled, [aria-disabled="true"]):where([data-hn-ui-button])) {
|
|
1328
|
-
border-color: var(
|
|
1329
|
-
--ui-button-hover-border,
|
|
1330
|
-
var(--ui-control-border-hover, var(--ui-control-border))
|
|
1331
|
-
);
|
|
1315
|
+
border-color: var(--ui-button-hover-border, var(--ui-control-border-hover));
|
|
1332
1316
|
background-color: var(--ui-button-hover-surface, var(--ui-neutral-hover));
|
|
1333
1317
|
}
|
|
1334
1318
|
:global(:scope[data-tone="neutral"][data-appearance="outline"]:active:not(:disabled, [aria-disabled="true"]):where([data-hn-ui-button])) {
|
|
1335
|
-
border-color: var(
|
|
1336
|
-
--ui-button-hover-border,
|
|
1337
|
-
var(--ui-control-border-hover, var(--ui-control-border))
|
|
1338
|
-
);
|
|
1319
|
+
border-color: var(--ui-button-hover-border, var(--ui-control-border-hover));
|
|
1339
1320
|
background-color: var(--ui-button-active-surface, var(--ui-neutral-active));
|
|
1340
1321
|
}
|
|
1341
1322
|
:global(:scope[data-tone="neutral"][data-appearance="solid"]:hover:not(:disabled, [aria-disabled="true"]):where([data-hn-ui-button])) {
|
package/vue/UiCallout.vue
CHANGED
|
@@ -266,52 +266,6 @@ const hostState = computed(() =>
|
|
|
266
266
|
</template>
|
|
267
267
|
|
|
268
268
|
<style scoped>
|
|
269
|
-
/* This component's hooks style the element they are set on, and never a nested one. */
|
|
270
|
-
@property --ui-callout-border {
|
|
271
|
-
syntax: "*";
|
|
272
|
-
inherits: false;
|
|
273
|
-
}
|
|
274
|
-
@property --ui-callout-border-width {
|
|
275
|
-
syntax: "*";
|
|
276
|
-
inherits: false;
|
|
277
|
-
}
|
|
278
|
-
@property --ui-callout-gap {
|
|
279
|
-
syntax: "*";
|
|
280
|
-
inherits: false;
|
|
281
|
-
}
|
|
282
|
-
@property --ui-callout-icon {
|
|
283
|
-
syntax: "*";
|
|
284
|
-
inherits: false;
|
|
285
|
-
}
|
|
286
|
-
@property --ui-callout-icon-column {
|
|
287
|
-
syntax: "*";
|
|
288
|
-
inherits: false;
|
|
289
|
-
}
|
|
290
|
-
@property --ui-callout-icon-size {
|
|
291
|
-
syntax: "*";
|
|
292
|
-
inherits: false;
|
|
293
|
-
}
|
|
294
|
-
@property --ui-callout-leading-border-width {
|
|
295
|
-
syntax: "*";
|
|
296
|
-
inherits: false;
|
|
297
|
-
}
|
|
298
|
-
@property --ui-callout-padding-block {
|
|
299
|
-
syntax: "*";
|
|
300
|
-
inherits: false;
|
|
301
|
-
}
|
|
302
|
-
@property --ui-callout-padding-inline {
|
|
303
|
-
syntax: "*";
|
|
304
|
-
inherits: false;
|
|
305
|
-
}
|
|
306
|
-
@property --ui-callout-surface {
|
|
307
|
-
syntax: "*";
|
|
308
|
-
inherits: false;
|
|
309
|
-
}
|
|
310
|
-
@property --ui-callout-text {
|
|
311
|
-
syntax: "*";
|
|
312
|
-
inherits: false;
|
|
313
|
-
}
|
|
314
|
-
|
|
315
269
|
/* One line box tall, so the icon centres on the first line of text. */
|
|
316
270
|
|
|
317
271
|
/* A link in the callout's text is underlined, so it reads as a link by more than colour. */
|
|
@@ -320,20 +274,14 @@ const hostState = computed(() =>
|
|
|
320
274
|
|
|
321
275
|
@scope (.ui-callout) to ([data-hn]) {
|
|
322
276
|
:global(:scope:where([data-hn-ui-callout])) {
|
|
323
|
-
/*
|
|
277
|
+
/* Resolve shared part values at the component root. */
|
|
324
278
|
--_ui-callout-icon-column: var(--ui-callout-icon-column);
|
|
325
279
|
--_ui-callout-icon: var(--ui-callout-icon);
|
|
326
280
|
--_ui-callout-icon-size: var(--ui-callout-icon-size);
|
|
327
281
|
|
|
328
|
-
|
|
329
|
-
--_callout-
|
|
330
|
-
|
|
331
|
-
from var(--_callout-border)
|
|
332
|
-
96% min(c, calc(0.02 + 0.03 * max(0, cos(calc((h - 140) * 1deg)))))
|
|
333
|
-
h
|
|
334
|
-
),
|
|
335
|
-
oklch(from var(--_callout-border) 25% min(c, 0.035) h)
|
|
336
|
-
);
|
|
282
|
+
--_callout-surface: var(--ui-info-soft);
|
|
283
|
+
--_callout-tone-text: var(--ui-info-subtle-text);
|
|
284
|
+
--_ui-surface-text: var(--ui-callout-text, var(--_callout-tone-text));
|
|
337
285
|
--_ui-selection-context-surface: light-dark(
|
|
338
286
|
oklch(
|
|
339
287
|
from var(--ui-callout-surface, var(--_callout-surface))
|
|
@@ -364,8 +312,8 @@ const hostState = computed(() =>
|
|
|
364
312
|
);
|
|
365
313
|
--_ui-selection-context-text: var(--ui-text-primary);
|
|
366
314
|
|
|
367
|
-
--_callout-border: var(--ui-info-
|
|
368
|
-
--_callout-icon: var(--ui-info-
|
|
315
|
+
--_callout-border: var(--ui-info-soft-border);
|
|
316
|
+
--_callout-icon: var(--ui-info-subtle-text);
|
|
369
317
|
|
|
370
318
|
display: grid !important;
|
|
371
319
|
grid-template-columns: var(--ui-callout-icon-column, 1.125rem) minmax(0, 1fr);
|
|
@@ -376,14 +324,14 @@ const hostState = computed(() =>
|
|
|
376
324
|
padding-inline-start: var(--ui-callout-padding-inline, var(--ui-space-2)) !important;
|
|
377
325
|
padding-inline-end: var(--ui-callout-padding-inline, var(--ui-space-3)) !important;
|
|
378
326
|
border: var(--ui-callout-border-width, var(--ui-border-width)) solid
|
|
379
|
-
|
|
327
|
+
var(--ui-callout-border, var(--_callout-border));
|
|
380
328
|
border-inline-start: var(
|
|
381
329
|
--ui-callout-leading-border-width,
|
|
382
330
|
var(--ui-callout-border-width, var(--ui-border-width))
|
|
383
|
-
) solid
|
|
331
|
+
) solid var(--ui-callout-border, var(--_callout-border));
|
|
384
332
|
border-radius: var(--ui-radius-md);
|
|
385
333
|
background: var(--ui-callout-surface, var(--_callout-surface));
|
|
386
|
-
color: var(--ui-callout-text, var(--
|
|
334
|
+
color: var(--ui-callout-text, var(--_ui-surface-text));
|
|
387
335
|
font-family: var(--ui-font-family-sans);
|
|
388
336
|
font-size: var(--ui-font-size-sm);
|
|
389
337
|
font-weight: var(--ui-font-normal);
|
|
@@ -417,34 +365,45 @@ const hostState = computed(() =>
|
|
|
417
365
|
--_ui-selection-context-border: initial;
|
|
418
366
|
--_ui-selection-context-text: initial;
|
|
419
367
|
--_callout-surface: var(--ui-surface-muted);
|
|
368
|
+
--_callout-tone-text: var(--ui-text-primary);
|
|
420
369
|
--_callout-border: var(--ui-border-strong);
|
|
421
370
|
--_callout-icon: var(--ui-text-secondary);
|
|
422
371
|
}
|
|
423
372
|
|
|
424
373
|
:global(:scope[data-ui-callout-state~="tone=tip"]:where([data-hn-ui-callout])) {
|
|
425
|
-
--_callout-border: var(--ui-success-
|
|
426
|
-
--_callout-
|
|
374
|
+
--_callout-border: var(--ui-success-soft-border);
|
|
375
|
+
--_callout-surface: var(--ui-success-soft);
|
|
376
|
+
--_callout-tone-text: var(--ui-success-subtle-text);
|
|
377
|
+
--_callout-icon: var(--ui-success-subtle-text);
|
|
427
378
|
}
|
|
428
379
|
|
|
429
380
|
:global(:scope[data-ui-callout-state~="tone=important"]:where([data-hn-ui-callout])) {
|
|
430
|
-
--_callout-border: var(--ui-accent-
|
|
431
|
-
--_callout-
|
|
381
|
+
--_callout-border: var(--ui-accent-soft-border);
|
|
382
|
+
--_callout-surface: var(--ui-accent-soft);
|
|
383
|
+
--_callout-tone-text: var(--ui-accent-subtle-text);
|
|
384
|
+
--_callout-icon: var(--ui-accent-subtle-text);
|
|
432
385
|
}
|
|
433
386
|
|
|
434
387
|
:global(:scope[data-ui-callout-state~="tone=warning"]:where([data-hn-ui-callout])) {
|
|
435
|
-
--_callout-border: var(--ui-warning-
|
|
436
|
-
--_callout-
|
|
388
|
+
--_callout-border: var(--ui-warning-soft-border);
|
|
389
|
+
--_callout-surface: var(--ui-warning-soft);
|
|
390
|
+
--_callout-tone-text: var(--ui-warning-subtle-text);
|
|
391
|
+
--_callout-icon: var(--ui-warning-subtle-text);
|
|
437
392
|
}
|
|
438
393
|
|
|
439
394
|
:global(:scope[data-ui-callout-state~="tone=success"]:where([data-hn-ui-callout])) {
|
|
440
|
-
--_callout-border: var(--ui-success-
|
|
441
|
-
--_callout-
|
|
395
|
+
--_callout-border: var(--ui-success-soft-border);
|
|
396
|
+
--_callout-surface: var(--ui-success-soft);
|
|
397
|
+
--_callout-tone-text: var(--ui-success-subtle-text);
|
|
398
|
+
--_callout-icon: var(--ui-success-subtle-text);
|
|
442
399
|
}
|
|
443
400
|
|
|
444
401
|
:global(:scope[data-ui-callout-state~="tone=danger"]:where([data-hn-ui-callout])),
|
|
445
402
|
:global(:scope[data-ui-callout-state~="tone=caution"]:where([data-hn-ui-callout])) {
|
|
446
|
-
--_callout-border: var(--ui-danger-
|
|
447
|
-
--_callout-
|
|
403
|
+
--_callout-border: var(--ui-danger-soft-border);
|
|
404
|
+
--_callout-surface: var(--ui-danger-soft);
|
|
405
|
+
--_callout-tone-text: var(--ui-danger-subtle-text);
|
|
406
|
+
--_callout-icon: var(--ui-danger-subtle-text);
|
|
448
407
|
}
|
|
449
408
|
:global(.content :where(:not([data-hn-ui-callout])):is(a)) {
|
|
450
409
|
color: var(--ui-accent-subtle-text);
|
package/vue/UiCard.d.ts
CHANGED
|
@@ -21,7 +21,7 @@ declare const __VLS_base: import("vue").DefineComponent<import("vue").ExtractPro
|
|
|
21
21
|
type: PropType<"content" | "sm" | "md" | "lg" | null>;
|
|
22
22
|
};
|
|
23
23
|
tone: {
|
|
24
|
-
type: PropType<"neutral" | "accent" | "info" | "success" | "warning" | "danger" | null>;
|
|
24
|
+
type: PropType<"neutral" | "accent" | "accent-secondary" | "accent-tertiary" | "info" | "success" | "warning" | "danger" | null>;
|
|
25
25
|
};
|
|
26
26
|
treatment: {
|
|
27
27
|
type: PropType<"standard" | "expressive" | null>;
|
|
@@ -43,7 +43,7 @@ declare const __VLS_base: import("vue").DefineComponent<import("vue").ExtractPro
|
|
|
43
43
|
type: PropType<"content" | "sm" | "md" | "lg" | null>;
|
|
44
44
|
};
|
|
45
45
|
tone: {
|
|
46
|
-
type: PropType<"neutral" | "accent" | "info" | "success" | "warning" | "danger" | null>;
|
|
46
|
+
type: PropType<"neutral" | "accent" | "accent-secondary" | "accent-tertiary" | "info" | "success" | "warning" | "danger" | null>;
|
|
47
47
|
};
|
|
48
48
|
treatment: {
|
|
49
49
|
type: PropType<"standard" | "expressive" | null>;
|
package/vue/UiCard.vue
CHANGED
|
@@ -51,8 +51,17 @@ const propValidityContract = {
|
|
|
51
51
|
required: false,
|
|
52
52
|
target: { attribute: 'tone' },
|
|
53
53
|
description:
|
|
54
|
-
'accent, info, success, warning and danger add a quiet semantic surface without changing card geometry. Row highlights follow the surface hue; action\n controls retain their own intent.',
|
|
55
|
-
values: [
|
|
54
|
+
'accent, info, success, warning and danger add a quiet semantic surface without changing card geometry. Row highlights follow the surface hue; action\n controls retain their own intent. Supporting brand families use accent-secondary and accent-tertiary; their usable colors derive from the theme, and unset\n families follow the primary accent.',
|
|
55
|
+
values: [
|
|
56
|
+
'neutral',
|
|
57
|
+
'accent',
|
|
58
|
+
'accent-secondary',
|
|
59
|
+
'accent-tertiary',
|
|
60
|
+
'info',
|
|
61
|
+
'success',
|
|
62
|
+
'warning',
|
|
63
|
+
'danger',
|
|
64
|
+
],
|
|
56
65
|
default: 'neutral',
|
|
57
66
|
},
|
|
58
67
|
treatment: {
|
|
@@ -60,7 +69,7 @@ const propValidityContract = {
|
|
|
60
69
|
required: false,
|
|
61
70
|
target: { attribute: 'treatment' },
|
|
62
71
|
description:
|
|
63
|
-
'How much of the theme\'s decorative material the surface expresses. standard preserves its restrained treatment; expressive uses the full material\n treatment. Its glass rim can transmit and frost the surrounding scene while content remains opaque. Surface separation controls the rim, independently of
|
|
72
|
+
'How much of the theme\'s decorative material the surface expresses. standard preserves its restrained treatment; expressive uses the full material\n treatment. Its glass rim can transmit and frost the surrounding scene while content remains opaque. Surface separation controls the rim, independently of\n frosting. This does not add elevation or require glass.',
|
|
64
73
|
values: ['standard', 'expressive'],
|
|
65
74
|
default: 'standard',
|
|
66
75
|
},
|
|
@@ -81,7 +90,15 @@ const props = defineProps({
|
|
|
81
90
|
size: { type: null as unknown as PropType<'content' | 'sm' | 'md' | 'lg' | null> },
|
|
82
91
|
tone: {
|
|
83
92
|
type: null as unknown as PropType<
|
|
84
|
-
|
|
93
|
+
| 'neutral'
|
|
94
|
+
| 'accent'
|
|
95
|
+
| 'accent-secondary'
|
|
96
|
+
| 'accent-tertiary'
|
|
97
|
+
| 'info'
|
|
98
|
+
| 'success'
|
|
99
|
+
| 'warning'
|
|
100
|
+
| 'danger'
|
|
101
|
+
| null
|
|
85
102
|
>,
|
|
86
103
|
},
|
|
87
104
|
treatment: { type: null as unknown as PropType<'standard' | 'expressive' | null> },
|
|
@@ -142,11 +159,25 @@ const checkedProps = computed(() => {
|
|
|
142
159
|
props['size'],
|
|
143
160
|
props[BINDING_INPUTS_PROP],
|
|
144
161
|
) as 'content' | 'sm' | 'md' | 'lg',
|
|
145
|
-
tone: propInputs.value<
|
|
146
|
-
'
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
162
|
+
tone: propInputs.value<
|
|
163
|
+
| 'neutral'
|
|
164
|
+
| 'accent'
|
|
165
|
+
| 'accent-secondary'
|
|
166
|
+
| 'accent-tertiary'
|
|
167
|
+
| 'info'
|
|
168
|
+
| 'success'
|
|
169
|
+
| 'warning'
|
|
170
|
+
| 'danger'
|
|
171
|
+
| null
|
|
172
|
+
>('tone', props['tone'], props[BINDING_INPUTS_PROP]) as
|
|
173
|
+
| 'neutral'
|
|
174
|
+
| 'accent'
|
|
175
|
+
| 'accent-secondary'
|
|
176
|
+
| 'accent-tertiary'
|
|
177
|
+
| 'info'
|
|
178
|
+
| 'success'
|
|
179
|
+
| 'warning'
|
|
180
|
+
| 'danger',
|
|
150
181
|
treatment: propInputs.value<'standard' | 'expressive' | null>(
|
|
151
182
|
'treatment',
|
|
152
183
|
props['treatment'],
|
|
@@ -288,6 +319,7 @@ const hostState = computed(() =>
|
|
|
288
319
|
@scope (.ui-card) to ([data-hn]) {
|
|
289
320
|
:global(:scope:where([data-hn-ui-card])) {
|
|
290
321
|
--_ui-card-surface: var(--ui-surface-raised);
|
|
322
|
+
--_ui-surface-text: initial;
|
|
291
323
|
--_ui-card-elevation: 0 0 0 transparent;
|
|
292
324
|
--_ui-selection-context-surface: initial;
|
|
293
325
|
--_ui-selection-context-border: initial;
|
|
@@ -301,7 +333,7 @@ const hostState = computed(() =>
|
|
|
301
333
|
border: var(--ui-border-width) solid var(--ui-border-strong);
|
|
302
334
|
border-radius: var(--ui-radius-lg);
|
|
303
335
|
background: var(--_ui-card-surface);
|
|
304
|
-
color: var(--ui-text-primary);
|
|
336
|
+
color: var(--_ui-surface-text, var(--ui-text-primary));
|
|
305
337
|
}
|
|
306
338
|
|
|
307
339
|
:global(:scope[data-ui-card-state~="padding=xs"]:where([data-hn-ui-card])) {
|
|
@@ -374,35 +406,54 @@ const hostState = computed(() =>
|
|
|
374
406
|
}
|
|
375
407
|
}
|
|
376
408
|
|
|
409
|
+
:global(:scope[data-ui-card-state~="tone=accent-secondary"]:where([data-hn-ui-card])) {
|
|
410
|
+
border-color: var(--ui-accent-secondary-soft-border);
|
|
411
|
+
--_ui-card-surface: var(--ui-accent-secondary-soft);
|
|
412
|
+
--_ui-surface-text: var(--ui-accent-secondary-subtle-text);
|
|
413
|
+
}
|
|
414
|
+
|
|
415
|
+
:global(:scope[data-ui-card-state~="tone=accent-tertiary"]:where([data-hn-ui-card])) {
|
|
416
|
+
border-color: var(--ui-accent-tertiary-soft-border);
|
|
417
|
+
--_ui-card-surface: var(--ui-accent-tertiary-soft);
|
|
418
|
+
--_ui-surface-text: var(--ui-accent-tertiary-subtle-text);
|
|
419
|
+
}
|
|
420
|
+
|
|
377
421
|
:global(:scope[data-ui-card-state~="tone=accent"]:where([data-hn-ui-card])) {
|
|
378
|
-
border-color:
|
|
379
|
-
--_ui-card-surface:
|
|
422
|
+
border-color: var(--ui-accent-soft-border);
|
|
423
|
+
--_ui-card-surface: var(--ui-accent-soft);
|
|
424
|
+
--_ui-surface-text: var(--ui-accent-subtle-text);
|
|
380
425
|
}
|
|
381
426
|
|
|
382
427
|
:global(:scope[data-ui-card-state~="tone=info"]:where([data-hn-ui-card])) {
|
|
383
|
-
border-color:
|
|
384
|
-
--_ui-card-surface:
|
|
428
|
+
border-color: var(--ui-info-soft-border);
|
|
429
|
+
--_ui-card-surface: var(--ui-info-soft);
|
|
430
|
+
--_ui-surface-text: var(--ui-info-subtle-text);
|
|
385
431
|
}
|
|
386
432
|
|
|
387
433
|
:global(:scope[data-ui-card-state~="tone=success"]:where([data-hn-ui-card])) {
|
|
388
|
-
border-color:
|
|
389
|
-
--_ui-card-surface:
|
|
434
|
+
border-color: var(--ui-success-soft-border);
|
|
435
|
+
--_ui-card-surface: var(--ui-success-soft);
|
|
436
|
+
--_ui-surface-text: var(--ui-success-subtle-text);
|
|
390
437
|
}
|
|
391
438
|
|
|
392
439
|
:global(:scope[data-ui-card-state~="tone=warning"]:where([data-hn-ui-card])) {
|
|
393
|
-
border-color:
|
|
394
|
-
--_ui-card-surface:
|
|
440
|
+
border-color: var(--ui-warning-soft-border);
|
|
441
|
+
--_ui-card-surface: var(--ui-warning-soft);
|
|
442
|
+
--_ui-surface-text: var(--ui-warning-subtle-text);
|
|
395
443
|
}
|
|
396
444
|
|
|
397
|
-
:global(:scope[data-ui-card-state~="variant=subtle"]:is([data-ui-card-state~="tone=accent"], [data-ui-card-state~="tone=info"], [data-ui-card-state~="tone=success"], [data-ui-card-state~="tone=warning"]):where([data-hn-ui-card])) {
|
|
445
|
+
:global(:scope[data-ui-card-state~="variant=subtle"]:is([data-ui-card-state~="tone=accent"], [data-ui-card-state~="tone=accent-secondary"], [data-ui-card-state~="tone=accent-tertiary"], [data-ui-card-state~="tone=info"], [data-ui-card-state~="tone=success"], [data-ui-card-state~="tone=warning"]):where([data-hn-ui-card])) {
|
|
398
446
|
border-color: transparent;
|
|
399
447
|
}
|
|
400
448
|
|
|
401
449
|
:global(:scope[data-ui-card-state~="tone=danger"]:where([data-hn-ui-card])) {
|
|
402
|
-
border-color:
|
|
450
|
+
border-color: var(--ui-danger-soft-border);
|
|
403
451
|
--_ui-card-surface: var(--ui-danger-soft);
|
|
452
|
+
--_ui-surface-text: var(--ui-danger-subtle-text);
|
|
404
453
|
}
|
|
405
454
|
:global(:scope[data-ui-card-state~="tone=accent"]:where([data-hn-ui-card])),
|
|
455
|
+
:global(:scope[data-ui-card-state~="tone=accent-secondary"]:where([data-hn-ui-card])),
|
|
456
|
+
:global(:scope[data-ui-card-state~="tone=accent-tertiary"]:where([data-hn-ui-card])),
|
|
406
457
|
:global(:scope[data-ui-card-state~="tone=info"]:where([data-hn-ui-card])),
|
|
407
458
|
:global(:scope[data-ui-card-state~="tone=success"]:where([data-hn-ui-card])),
|
|
408
459
|
:global(:scope[data-ui-card-state~="tone=warning"]:where([data-hn-ui-card])),
|
|
@@ -419,16 +470,16 @@ const hostState = computed(() =>
|
|
|
419
470
|
}
|
|
420
471
|
|
|
421
472
|
:global(:scope[data-ui-card-state~="size=sm"]:where([data-hn-ui-card])) {
|
|
422
|
-
inline-size: min(22rem, calc(100vw - var(--ui-space-2) * 2));
|
|
423
|
-
max-inline-size: min(22rem, calc(100vw - var(--ui-space-2) * 2));
|
|
473
|
+
inline-size: min(22rem, 100%, calc(100vw - var(--ui-space-2) * 2));
|
|
474
|
+
max-inline-size: min(22rem, 100%, calc(100vw - var(--ui-space-2) * 2));
|
|
424
475
|
}
|
|
425
476
|
:global(:scope[data-ui-card-state~="size=md"]:where([data-hn-ui-card])) {
|
|
426
|
-
inline-size: min(28rem, calc(100vw - var(--ui-space-2) * 2));
|
|
427
|
-
max-inline-size: min(28rem, calc(100vw - var(--ui-space-2) * 2));
|
|
477
|
+
inline-size: min(28rem, 100%, calc(100vw - var(--ui-space-2) * 2));
|
|
478
|
+
max-inline-size: min(28rem, 100%, calc(100vw - var(--ui-space-2) * 2));
|
|
428
479
|
}
|
|
429
480
|
:global(:scope[data-ui-card-state~="size=lg"]:where([data-hn-ui-card])) {
|
|
430
|
-
inline-size: min(36rem, calc(100vw - var(--ui-space-2) * 2));
|
|
431
|
-
max-inline-size: min(36rem, calc(100vw - var(--ui-space-2) * 2));
|
|
481
|
+
inline-size: min(36rem, 100%, calc(100vw - var(--ui-space-2) * 2));
|
|
482
|
+
max-inline-size: min(36rem, 100%, calc(100vw - var(--ui-space-2) * 2));
|
|
432
483
|
}
|
|
433
484
|
:global(:scope[hidden]:where([data-hn-ui-card])) {
|
|
434
485
|
display: none !important;
|
package/vue/UiCheckbox.vue
CHANGED
|
@@ -361,20 +361,6 @@ useComponentHost(() => import('../components/ui-checkbox/ui-checkbox.js'), {
|
|
|
361
361
|
</template>
|
|
362
362
|
|
|
363
363
|
<style scoped>
|
|
364
|
-
/* This component's hooks style the element they are set on, and never a nested one. */
|
|
365
|
-
@property --ui-checkbox-gap {
|
|
366
|
-
syntax: "*";
|
|
367
|
-
inherits: false;
|
|
368
|
-
}
|
|
369
|
-
@property --ui-checkbox-invalid-border {
|
|
370
|
-
syntax: "*";
|
|
371
|
-
inherits: false;
|
|
372
|
-
}
|
|
373
|
-
@property --ui-checkbox-size {
|
|
374
|
-
syntax: "*";
|
|
375
|
-
inherits: false;
|
|
376
|
-
}
|
|
377
|
-
|
|
378
364
|
/* The label, and under it an optional line saying what the choice means. */
|
|
379
365
|
|
|
380
366
|
/* The SVG's painted bounds are centred in its viewBox, including its round stroke.
|
|
@@ -403,7 +389,7 @@ useComponentHost(() => import('../components/ui-checkbox/ui-checkbox.js'), {
|
|
|
403
389
|
|
|
404
390
|
@scope (.ui-checkbox) to ([data-hn]) {
|
|
405
391
|
:global(:scope:where([data-hn-ui-checkbox])) {
|
|
406
|
-
/*
|
|
392
|
+
/* Resolve shared part values at the component root. */
|
|
407
393
|
--_ui-checkbox-size: var(--ui-checkbox-size, var(--ui-choice-mark-size));
|
|
408
394
|
--_ui-checkbox-invalid-border: var(
|
|
409
395
|
--ui-checkbox-invalid-border,
|