@vamos-ui/react 0.3.0 → 0.4.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/README.md +4 -0
- package/dist/blocks/block-heading.js +1 -1
- package/dist/blocks/block-image.js +1 -1
- package/dist/blocks/block-link.js +2 -2
- package/dist/blocks/index.d.ts +5 -5
- package/dist/blocks/index.js +5 -5
- package/dist/blocks/labels.d.ts +8 -0
- package/dist/blocks/labels.js +60 -0
- package/dist/blocks/section-header.js +1 -1
- package/dist/blocks/section.js +2 -2
- package/dist/blocks/site/_kit-1.js +1 -1
- package/dist/blocks/site/announcement-bar.js +1 -1
- package/dist/blocks/site/article-layout.d.ts +1 -0
- package/dist/blocks/site/article-layout.js +2 -1
- package/dist/blocks/site/blog-list.d.ts +1 -0
- package/dist/blocks/site/blog-list.js +3 -2
- package/dist/blocks/site/contact-dock.js +3 -1
- package/dist/blocks/site/contact-form.js +1 -1
- package/dist/blocks/site/cta.d.ts +2 -2
- package/dist/blocks/site/cta.js +6 -4
- package/dist/blocks/site/feature-grid.d.ts +1 -0
- package/dist/blocks/site/feature-grid.js +5 -4
- package/dist/blocks/site/feature-tabs.js +1 -1
- package/dist/blocks/site/footer.d.ts +11 -2
- package/dist/blocks/site/footer.js +36 -11
- package/dist/blocks/site/gallery-section.d.ts +6 -1
- package/dist/blocks/site/gallery-section.js +5 -4
- package/dist/blocks/site/hero.d.ts +3 -2
- package/dist/blocks/site/hero.js +7 -5
- package/dist/blocks/site/logo-strip.d.ts +1 -0
- package/dist/blocks/site/logo-strip.js +1 -1
- package/dist/blocks/site/map-hours.d.ts +2 -2
- package/dist/blocks/site/map-hours.js +4 -2
- package/dist/blocks/site/media-text.d.ts +4 -1
- package/dist/blocks/site/media-text.js +4 -3
- package/dist/blocks/site/menu-list.d.ts +7 -3
- package/dist/blocks/site/menu-list.js +34 -7
- package/dist/blocks/site/navbar.d.ts +1 -0
- package/dist/blocks/site/navbar.js +6 -5
- package/dist/blocks/site/not-found.js +2 -1
- package/dist/blocks/site/page-intro.d.ts +1 -0
- package/dist/blocks/site/page-intro.js +2 -1
- package/dist/blocks/site/process.d.ts +1 -0
- package/dist/blocks/site/process.js +2 -1
- package/dist/blocks/site/registry-1.d.ts +1 -1
- package/dist/blocks/site/registry-2.d.ts +5 -0
- package/dist/blocks/site/registry-2.js +5 -3
- package/dist/blocks/site/rich-text-section.js +2 -1
- package/dist/blocks/site/shared/heading-lines.d.ts +9 -0
- package/dist/blocks/site/shared/heading-lines.js +32 -0
- package/dist/blocks/site/shared/image-sizes.d.ts +25 -0
- package/dist/blocks/site/shared/image-sizes.js +37 -0
- package/dist/blocks/site/shared/island-keys.d.ts +1 -1
- package/dist/blocks/site/shared/island-keys.js +1 -1
- package/dist/blocks/site/shared/labels-2.d.ts +17 -1
- package/dist/blocks/site/shared/labels-2.js +832 -6
- package/dist/blocks/site/shared/open-now.d.ts +1 -1
- package/dist/blocks/site/shared/open-now.js +1 -1
- package/dist/blocks/site/shared/opening-hours.d.ts +18 -2
- package/dist/blocks/site/shared/opening-hours.js +36 -7
- package/dist/blocks/site/shared/tap.d.ts +9 -0
- package/dist/blocks/site/shared/tap.js +16 -0
- package/dist/blocks/site/site-shell.js +3 -3
- package/dist/blocks/site/team.d.ts +1 -1
- package/dist/blocks/site/team.js +4 -3
- package/dist/blocks/site/testimonials.d.ts +2 -2
- package/dist/blocks/site/testimonials.js +3 -3
- package/dist/business/approval-flow.js +2 -2
- package/dist/business/import-wizard.js +1 -1
- package/dist/business/line-items.js +1 -1
- package/dist/business/multi-step-form.js +2 -2
- package/dist/business/permission-matrix.js +1 -1
- package/dist/business/setup-checklist.js +2 -2
- package/dist/business/signer-status.js +1 -1
- package/dist/charts/bar-chart.js +1 -1
- package/dist/charts/bar-list.js +1 -1
- package/dist/charts/chart-shell.d.ts +9 -2
- package/dist/charts/chart-shell.js +11 -5
- package/dist/charts/chart.js +1 -1
- package/dist/charts/combo-chart.js +5 -7
- package/dist/charts/donut-chart.js +1 -1
- package/dist/charts/funnel.js +1 -1
- package/dist/charts/gauge.js +2 -2
- package/dist/charts/utils.d.ts +10 -0
- package/dist/charts/utils.js +46 -0
- package/dist/components/accordion.d.ts +1 -1
- package/dist/components/accordion.js +8 -8
- package/dist/components/activity-timeline.js +11 -11
- package/dist/components/address-field.js +3 -3
- package/dist/components/alert-dialog.d.ts +1 -1
- package/dist/components/alert-dialog.js +8 -8
- package/dist/components/alert.js +2 -2
- package/dist/components/app-shell.js +3 -3
- package/dist/components/aspect-ratio.d.ts +26 -0
- package/dist/components/aspect-ratio.js +42 -0
- package/dist/components/attachment-list.js +2 -2
- package/dist/components/audit-log.js +1 -1
- package/dist/components/avatar.d.ts +1 -1
- package/dist/components/avatar.js +8 -8
- package/dist/components/backup-codes.js +1 -1
- package/dist/components/badge.js +3 -3
- package/dist/components/breadcrumb.js +10 -9
- package/dist/components/button-group.js +4 -4
- package/dist/components/button.js +4 -4
- package/dist/components/calendar.js +5 -5
- package/dist/components/card.js +8 -8
- package/dist/components/carousel.d.ts +12 -3
- package/dist/components/carousel.js +17 -14
- package/dist/components/checkbox.d.ts +1 -1
- package/dist/components/checkbox.js +6 -6
- package/dist/components/collapsible.d.ts +36 -0
- package/dist/components/collapsible.js +37 -0
- package/dist/components/color-picker.js +3 -3
- package/dist/components/combobox.js +1 -1
- package/dist/components/command.js +9 -9
- package/dist/components/comment-thread.js +3 -3
- package/dist/components/context-menu.d.ts +1 -1
- package/dist/components/context-menu.js +9 -9
- package/dist/components/currency-input.js +1 -1
- package/dist/components/date-picker.js +2 -2
- package/dist/components/date-range-picker.js +1 -1
- package/dist/components/description-list.js +2 -2
- package/dist/components/dialog.d.ts +1 -1
- package/dist/components/dialog.js +9 -9
- package/dist/components/dropdown-menu.d.ts +1 -1
- package/dist/components/dropdown-menu.js +9 -9
- package/dist/components/editor-layout.js +9 -9
- package/dist/components/empty-state.js +2 -2
- package/dist/components/entity-card.js +1 -1
- package/dist/components/file-upload.js +5 -5
- package/dist/components/formatted-input.js +3 -3
- package/dist/components/hierarchy-chart.js +1 -1
- package/dist/components/hover-card.d.ts +1 -1
- package/dist/components/hover-card.js +3 -3
- package/dist/components/iban-input.js +1 -1
- package/dist/components/id-input.js +3 -3
- package/dist/components/image.d.ts +18 -2
- package/dist/components/image.js +16 -9
- package/dist/components/input-otp.js +6 -6
- package/dist/components/input.d.ts +1 -1
- package/dist/components/input.js +6 -6
- package/dist/components/item.js +4 -4
- package/dist/components/kbd.js +3 -3
- package/dist/components/list-layout.js +9 -9
- package/dist/components/menubar.d.ts +96 -0
- package/dist/components/menubar.js +123 -0
- package/dist/components/native-select.js +1 -1
- package/dist/components/navigation-menu.d.ts +1 -1
- package/dist/components/navigation-menu.js +12 -11
- package/dist/components/notification-center.js +4 -4
- package/dist/components/page-header.js +3 -3
- package/dist/components/pagination.js +9 -9
- package/dist/components/phone-input.js +1 -1
- package/dist/components/pin-map.js +1 -1
- package/dist/components/placeholder-art.d.ts +51 -0
- package/dist/components/placeholder-art.js +82 -0
- package/dist/components/popover.d.ts +1 -1
- package/dist/components/popover.js +7 -7
- package/dist/components/progress.js +3 -3
- package/dist/components/qr-code.js +1 -1
- package/dist/components/radio-group.d.ts +1 -1
- package/dist/components/radio-group.js +4 -4
- package/dist/components/record-detail-layout.js +10 -10
- package/dist/components/record-picker.js +2 -2
- package/dist/components/resizable.js +2 -2
- package/dist/components/scroll-area.d.ts +1 -1
- package/dist/components/scroll-area.js +4 -4
- package/dist/components/select.d.ts +1 -1
- package/dist/components/select.js +10 -10
- package/dist/components/separator.d.ts +1 -1
- package/dist/components/separator.js +3 -3
- package/dist/components/settings-layout.js +6 -6
- package/dist/components/sheet.js +3 -3
- package/dist/components/sidebar.js +12 -11
- package/dist/components/signature-pad.js +1 -1
- package/dist/components/skeleton.js +5 -5
- package/dist/components/sla-timer.js +2 -2
- package/dist/components/slider.d.ts +1 -1
- package/dist/components/slider.js +2 -2
- package/dist/components/slug-input.js +1 -1
- package/dist/components/sparkline.js +1 -1
- package/dist/components/spinner.js +2 -2
- package/dist/components/stat.js +5 -5
- package/dist/components/status-picker.js +2 -2
- package/dist/components/stepper.js +1 -1
- package/dist/components/switch.d.ts +1 -1
- package/dist/components/switch.js +3 -3
- package/dist/components/table.js +10 -10
- package/dist/components/tabs.d.ts +1 -1
- package/dist/components/tabs.js +11 -11
- package/dist/components/tag-input.js +1 -1
- package/dist/components/task-list.js +1 -1
- package/dist/components/time-picker.js +3 -3
- package/dist/components/toggle.d.ts +2 -1
- package/dist/components/toggle.js +7 -6
- package/dist/components/tooltip.d.ts +1 -1
- package/dist/components/tooltip.js +5 -4
- package/dist/components/top-bar.js +4 -4
- package/dist/components/tour.js +1 -1
- package/dist/components/tree-select.js +2 -2
- package/dist/components/tree-view.js +3 -3
- package/dist/components/typography.js +11 -11
- package/dist/components/user-picker.js +2 -2
- package/dist/components/version-history.js +3 -3
- package/dist/data-table/data-table.js +1 -1
- package/dist/data-table/filter-bar.js +2 -2
- package/dist/data-table/index.d.ts +15 -8
- package/dist/data-table/index.js +9 -8
- package/dist/data-table/saved-views.js +1 -1
- package/dist/editor/block-editor.js +1 -1
- package/dist/editor/context.js +1 -1
- package/dist/editor/menus.js +1 -1
- package/dist/fonts/font-picker.js +3 -3
- package/dist/fonts/pairing-picker.js +1 -1
- package/dist/fonts/provider.js +1 -1
- package/dist/index.d.ts +188 -90
- package/dist/index.js +94 -90
- package/dist/lib/data-islands.js +1 -1
- package/dist/lib/field-context.js +1 -1
- package/dist/lib/floating-arrow.js +1 -1
- package/dist/lib/islands.js +1 -1
- package/dist/lib/layer.js +3 -3
- package/dist/lib/locale.js +2 -2
- package/dist/lib/menu.js +2 -2
- package/dist/lib/provider.js +4 -4
- package/dist/lib/theme-scope.js +4 -3
- package/dist/lib/value-format.js +1 -1
- package/dist/lib/variants.js +2 -2
- package/dist/locales/ar.d.ts +2087 -0
- package/dist/locales/ar.js +2088 -0
- package/dist/locales/de.d.ts +2087 -0
- package/dist/locales/de.js +2088 -0
- package/dist/locales/en.d.ts +1 -0
- package/dist/locales/en.js +1 -0
- package/dist/locales/es.d.ts +2087 -0
- package/dist/locales/es.js +2087 -0
- package/dist/locales/fr.d.ts +2087 -0
- package/dist/locales/fr.js +2088 -0
- package/dist/locales/tr.d.ts +1 -0
- package/dist/locales/tr.js +1 -0
- package/dist/media/focal-point.js +1 -1
- package/dist/media/gallery.js +1 -1
- package/dist/media/image-cropper.js +1 -1
- package/dist/media/image-field.js +2 -2
- package/dist/media/lightbox.js +4 -3
- package/dist/media/link-preview.js +3 -3
- package/dist/media/media-library.js +4 -4
- package/dist/media/media-picker.js +1 -1
- package/dist/media/media-provider.js +1 -1
- package/dist/media/video-player.js +4 -4
- package/dist/motion/count-up.js +1 -1
- package/dist/motion/motion-scope.js +2 -2
- package/dist/motion/page-transition.js +1 -1
- package/dist/motion/parallax.js +2 -2
- package/dist/motion/pointer.js +3 -3
- package/dist/motion/reveal.js +3 -3
- package/dist/motion/skeleton-swap.js +1 -1
- package/dist/motion/text-reveal.d.ts +3 -1
- package/dist/motion/text-reveal.js +6 -4
- package/dist/motion/ticker.js +1 -1
- package/dist/node_modules/.vite/vitest/da39a3ee5e6b4b0d3255bfef95601890afd80709/results.json +1 -0
- package/dist/render/block-renderer.js +1 -1
- package/dist/scheduler/gantt.js +2 -2
- package/dist/scheduler/resource-calendar.js +2 -2
- package/dist/scheduler/scheduler.js +3 -3
- package/dist/scheduler/time-tracker.js +4 -4
- package/dist/sortable/kanban.js +2 -2
- package/dist/sortable/sortable-list.js +2 -2
- package/dist/sortable/sortable.js +4 -4
- package/dist/styles/blocks.css +18 -9
- package/dist/styles/editors.css +2 -1
- package/dist/styles/media.css +31 -5
- package/dist/styles.css +39 -9
- package/package.json +1 -1
|
@@ -51,7 +51,7 @@ export const sortableLabels = {
|
|
|
51
51
|
moveToHeading: "Move to list",
|
|
52
52
|
dropHere: "Drop items here",
|
|
53
53
|
};
|
|
54
|
-
const SortableRootContext = React.createContext(null);
|
|
54
|
+
const SortableRootContext = /*#__PURE__*/ React.createContext(null);
|
|
55
55
|
function useSortableRoot(component) {
|
|
56
56
|
const ctx = React.useContext(SortableRootContext);
|
|
57
57
|
if (!ctx)
|
|
@@ -397,7 +397,7 @@ export function useSortableItem(id, options = {}) {
|
|
|
397
397
|
label,
|
|
398
398
|
};
|
|
399
399
|
}
|
|
400
|
-
const SortableItemContext = React.createContext(null);
|
|
400
|
+
const SortableItemContext = /*#__PURE__*/ React.createContext(null);
|
|
401
401
|
/** The current item (inside `SortableItem`). */
|
|
402
402
|
export function useSortableItemContext() {
|
|
403
403
|
return React.useContext(SortableItemContext);
|
|
@@ -406,7 +406,7 @@ export function useSortableItemContext() {
|
|
|
406
406
|
* A sortable element. With `handle` (default) put a `SortableHandle` inside; with
|
|
407
407
|
* `handle={false}` the whole item is the activator.
|
|
408
408
|
*/
|
|
409
|
-
export const SortableItem = React.forwardRef(function SortableItem({ id, as: Comp = "div", disabled, className, style, children, ...props }, ref) {
|
|
409
|
+
export const SortableItem = /*#__PURE__*/ React.forwardRef(function SortableItem({ id, as: Comp = "div", disabled, className, style, children, ...props }, ref) {
|
|
410
410
|
const ctx = useSortableRoot("SortableItem");
|
|
411
411
|
const item = useSortableItem(id, { disabled });
|
|
412
412
|
const setRef = React.useCallback((node) => {
|
|
@@ -427,7 +427,7 @@ export const SortableItem = React.forwardRef(function SortableItem({ id, as: Com
|
|
|
427
427
|
}, "data-slot": "sortable-item", "data-dragging": item.isDragging ? "" : undefined, "data-placeholder": item.isPlaceholder ? "" : undefined, "data-disabled": item.disabled ? "" : undefined, className: cn("vui-sortable-item", !ctx.handle && !item.disabled && "focus-ring cursor-grab", className), style: { ...item.style, ...style }, ...activatorProps, ...props, children: children }) }));
|
|
428
428
|
});
|
|
429
429
|
/** The drag handle: a button named "Reorder {item}". Hidden for disabled items. */
|
|
430
|
-
export const SortableHandle = React.forwardRef(function SortableHandle({ id: _id, size = "md", className, children, ...props }, ref) {
|
|
430
|
+
export const SortableHandle = /*#__PURE__*/ React.forwardRef(function SortableHandle({ id: _id, size = "md", className, children, ...props }, ref) {
|
|
431
431
|
const item = useSortableItemContext();
|
|
432
432
|
if (!item)
|
|
433
433
|
throw new Error("<SortableHandle> must be used inside <SortableItem> (or pass the handle props from useSortableItem).");
|
package/dist/styles/blocks.css
CHANGED
|
@@ -11,6 +11,11 @@
|
|
|
11
11
|
--scrim: linear-gradient(to top, rgb(6 8 4 / 0.8), rgb(6 8 4 / 0.58) 55%, rgb(6 8 4 / 0.5));
|
|
12
12
|
--vb-rhythm: 1;
|
|
13
13
|
}
|
|
14
|
+
/* Rhythm overrides sit next to the default, outside @layer: an unlayered declaration always beats a
|
|
15
|
+
layered one, so inside `@layer components` these never applied. */
|
|
16
|
+
.vb-section[data-rhythm="tight"] { --vb-rhythm: 0.55; }
|
|
17
|
+
.vb-section[data-rhythm="loose"] { --vb-rhythm: 1.35; }
|
|
18
|
+
.vb-section[data-rhythm="none"] { --vb-rhythm: 0; }
|
|
14
19
|
/* Emphasis in sans presets reads as accent ink (italic stays the serif's job). */
|
|
15
20
|
[data-font="grotesk"],
|
|
16
21
|
[data-font="corporate"],
|
|
@@ -27,9 +32,6 @@
|
|
|
27
32
|
color: var(--fg);
|
|
28
33
|
scroll-margin-top: calc(var(--topbar-h) + 1rem);
|
|
29
34
|
}
|
|
30
|
-
.vb-section[data-rhythm="tight"] { --vb-rhythm: 0.55; }
|
|
31
|
-
.vb-section[data-rhythm="loose"] { --vb-rhythm: 1.35; }
|
|
32
|
-
.vb-section[data-rhythm="none"] { --vb-rhythm: 0; }
|
|
33
35
|
|
|
34
36
|
.vb-section[data-surface="scene"] { background-color: var(--scene); }
|
|
35
37
|
/* Surface tokens are translucent under glass: lay them over the section's own scene colour so a
|
|
@@ -99,15 +101,18 @@
|
|
|
99
101
|
}
|
|
100
102
|
|
|
101
103
|
/* Container widths */
|
|
104
|
+
/* Full width up to the measure. An explicit width (not `auto`) matters: inside a flex column the
|
|
105
|
+
auto inline margins switch off stretching, and the container shrank to its content (a grid of
|
|
106
|
+
lazy images collapsed to almost nothing). */
|
|
102
107
|
.vb-container {
|
|
103
|
-
box-sizing:
|
|
104
|
-
width:
|
|
105
|
-
max-width: var(--container);
|
|
108
|
+
box-sizing: border-box;
|
|
109
|
+
width: 100%;
|
|
110
|
+
max-width: calc(var(--container) + 2 * var(--gutter));
|
|
106
111
|
margin-inline: auto;
|
|
107
112
|
padding-inline: var(--gutter);
|
|
108
113
|
}
|
|
109
|
-
.vb-container[data-size="wide"] { max-width: var(--container-wide); }
|
|
110
|
-
.vb-container[data-size="prose"] { max-width: var(--prose); }
|
|
114
|
+
.vb-container[data-size="wide"] { max-width: calc(var(--container-wide) + 2 * var(--gutter)); }
|
|
115
|
+
.vb-container[data-size="prose"] { max-width: calc(var(--prose) + 2 * var(--gutter)); }
|
|
111
116
|
.vb-container[data-size="full"] { max-width: none; }
|
|
112
117
|
|
|
113
118
|
/* Headings */
|
|
@@ -126,6 +131,9 @@
|
|
|
126
131
|
background-size: cover;
|
|
127
132
|
background-position: var(--vb-focal, 50% 50%);
|
|
128
133
|
}
|
|
134
|
+
/* No ratio: the frame follows the image. Was a Tailwind h-auto class, which (utilities layer)
|
|
135
|
+
silently beat component sizes such as .vb-nav-logo's 1.75rem height. */
|
|
136
|
+
.vb-image:where(:not([data-ratio])) { height: auto; }
|
|
129
137
|
.vb-image > img,
|
|
130
138
|
.vb-image > picture > img {
|
|
131
139
|
display: block;
|
|
@@ -163,11 +171,12 @@
|
|
|
163
171
|
/* Edit-mode placeholders for unknown / invalid blocks. */
|
|
164
172
|
.vb-notice {
|
|
165
173
|
--tone: var(--danger);
|
|
174
|
+
--tone-ink: var(--danger-ink);
|
|
166
175
|
border: 1px dashed color-mix(in srgb, var(--tone) 55%, transparent);
|
|
167
176
|
background: color-mix(in srgb, var(--tone) 7%, var(--scene));
|
|
168
177
|
color: var(--fg);
|
|
169
178
|
}
|
|
170
|
-
.vb-notice[data-tone="warning"] { --tone: var(--warning); }
|
|
179
|
+
.vb-notice[data-tone="warning"] { --tone: var(--warning); --tone-ink: var(--warning-ink); }
|
|
171
180
|
}
|
|
172
181
|
|
|
173
182
|
/* The primary action can't be accent-on-accent: it inverts. Unlayered on purpose, so it wins
|
package/dist/styles/editors.css
CHANGED
|
@@ -589,7 +589,8 @@
|
|
|
589
589
|
.vui-cblock-unknown p { margin: 0; }
|
|
590
590
|
|
|
591
591
|
/* Images */
|
|
592
|
-
|
|
592
|
+
/* Editor image node only: the kit <Image> shares the class name. */
|
|
593
|
+
.ProseMirror .vui-image { margin-block: 1.5rem; }
|
|
593
594
|
.vui-image-frame { position: relative; border-radius: var(--radius-ui-sm); }
|
|
594
595
|
.vui-image-frame img { display: block; max-width: 100%; height: auto; border-radius: inherit; }
|
|
595
596
|
.vui-image[data-selected] .vui-image-frame { outline: 1.5px solid var(--ring); outline-offset: 4px; }
|
package/dist/styles/media.css
CHANGED
|
@@ -169,7 +169,8 @@
|
|
|
169
169
|
/* ------------------------------------------------------------------ */
|
|
170
170
|
@keyframes vui-marquee { to { transform: translateX(calc(-100% * var(--dir))); } }
|
|
171
171
|
@layer components {
|
|
172
|
-
.vui-marquee { gap: var(--marquee-gap); }
|
|
172
|
+
.vui-marquee-viewport { gap: var(--marquee-gap); }
|
|
173
|
+
.vui-marquee[data-controls] .vui-marquee-viewport { margin-inline-end: 2.25rem; }
|
|
173
174
|
.vui-marquee-track {
|
|
174
175
|
gap: var(--marquee-gap);
|
|
175
176
|
min-width: 100%;
|
|
@@ -178,15 +179,40 @@
|
|
|
178
179
|
}
|
|
179
180
|
.vui-marquee[data-reverse] .vui-marquee-track { animation-direction: reverse; }
|
|
180
181
|
.vui-marquee[data-pause-on-hover]:hover .vui-marquee-track,
|
|
181
|
-
.vui-marquee[data-pause-on-hover]:focus-within .vui-marquee-track
|
|
182
|
-
.vui-marquee
|
|
182
|
+
.vui-marquee[data-pause-on-hover]:focus-within .vui-marquee-track,
|
|
183
|
+
.vui-marquee:has(.vui-marquee-pause:checked) .vui-marquee-track { animation-play-state: paused; }
|
|
184
|
+
.vui-marquee-toggle {
|
|
185
|
+
position: absolute;
|
|
186
|
+
inset-inline-end: 0;
|
|
187
|
+
inset-block-start: 50%;
|
|
188
|
+
translate: 0 -50%;
|
|
189
|
+
display: grid;
|
|
190
|
+
place-items: center;
|
|
191
|
+
width: 1.75rem;
|
|
192
|
+
height: 1.75rem;
|
|
193
|
+
border-radius: 999px;
|
|
194
|
+
border: 1px solid var(--surface-border);
|
|
195
|
+
background: var(--surface);
|
|
196
|
+
color: var(--fg-muted);
|
|
197
|
+
cursor: pointer;
|
|
198
|
+
}
|
|
199
|
+
.vui-marquee-toggle:hover { color: var(--fg); background: color-mix(in srgb, var(--fg) 5%, var(--surface)); }
|
|
200
|
+
.vui-marquee-toggle:has(:focus-visible) { color: var(--fg); outline: 2px solid var(--ring); outline-offset: 2px; }
|
|
201
|
+
.vui-marquee-toggle svg { width: 0.75rem; height: 0.75rem; }
|
|
202
|
+
.vui-marquee-icon-play,
|
|
203
|
+
.vui-marquee:has(.vui-marquee-pause:checked) .vui-marquee-icon-pause { display: none; }
|
|
204
|
+
.vui-marquee:has(.vui-marquee-pause:checked) .vui-marquee-icon-play { display: block; }
|
|
205
|
+
[data-motion="off"] .vui-marquee-toggle { display: none; }
|
|
206
|
+
[data-motion="off"] .vui-marquee[data-controls] .vui-marquee-viewport { margin-inline-end: 0; }
|
|
207
|
+
.vui-marquee[data-fade] .vui-marquee-viewport {
|
|
183
208
|
-webkit-mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent);
|
|
184
209
|
mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent);
|
|
185
210
|
}
|
|
186
211
|
@media (prefers-reduced-motion: reduce) {
|
|
187
|
-
.vui-marquee { overflow-x: auto; }
|
|
212
|
+
.vui-marquee-viewport { overflow-x: auto; margin-inline-end: 0; }
|
|
188
213
|
.vui-marquee-track { animation: none; }
|
|
189
|
-
.vui-marquee-track[aria-hidden]
|
|
214
|
+
.vui-marquee-track[aria-hidden],
|
|
215
|
+
.vui-marquee-toggle { display: none; }
|
|
190
216
|
}
|
|
191
217
|
}
|
|
192
218
|
|
package/dist/styles.css
CHANGED
|
@@ -46,7 +46,7 @@
|
|
|
46
46
|
--accent-ink-dark: oklch(0.9 0.19 122);
|
|
47
47
|
}
|
|
48
48
|
[data-accent="ocean"] {
|
|
49
|
-
--accent-base: oklch(0.
|
|
49
|
+
--accent-base: oklch(0.55 0.17 245);
|
|
50
50
|
--accent-fg: #fff;
|
|
51
51
|
--accent-ink-light: oklch(0.5 0.17 250);
|
|
52
52
|
--accent-ink-dark: oklch(0.78 0.12 240);
|
|
@@ -58,7 +58,7 @@
|
|
|
58
58
|
--accent-ink-dark: oklch(0.8 0.14 50);
|
|
59
59
|
}
|
|
60
60
|
[data-accent="rose"] {
|
|
61
|
-
--accent-base: oklch(0.
|
|
61
|
+
--accent-base: oklch(0.58 0.21 10);
|
|
62
62
|
--accent-fg: #fff;
|
|
63
63
|
--accent-ink-light: oklch(0.52 0.2 12);
|
|
64
64
|
--accent-ink-dark: oklch(0.8 0.13 10);
|
|
@@ -125,6 +125,13 @@
|
|
|
125
125
|
/* solid danger fill behind white text (destructive buttons); stays >= 4.5:1 in both themes */
|
|
126
126
|
--danger-solid: #d0303c;
|
|
127
127
|
--info: #2563eb;
|
|
128
|
+
/* Text-safe status inks (text-success/-warning/-danger/-info, tone text). The base hues stay for
|
|
129
|
+
fills, dots and badges; the inks keep small text >= 4.5:1 on scene, surface, hover and
|
|
130
|
+
selected rows (measured: success 5.47, warning 5.71, danger 5.51, info 5.44 on --scene). */
|
|
131
|
+
--success-ink: #0a6e4b;
|
|
132
|
+
--warning-ink: #8f4c00;
|
|
133
|
+
--danger-ink: #b8232f;
|
|
134
|
+
--info-ink: #1f56d6;
|
|
128
135
|
|
|
129
136
|
--chart-1: var(--accent-ink);
|
|
130
137
|
--chart-2: #2f6fd6;
|
|
@@ -188,6 +195,11 @@
|
|
|
188
195
|
--danger: #f2717a;
|
|
189
196
|
--danger-solid: #c93a45;
|
|
190
197
|
--info: #7cb0ff;
|
|
198
|
+
/* the dark hues already clear 4.5:1 as text (>= 5.97 on surface-2) */
|
|
199
|
+
--success-ink: var(--success);
|
|
200
|
+
--warning-ink: var(--warning);
|
|
201
|
+
--danger-ink: var(--danger);
|
|
202
|
+
--info-ink: var(--info);
|
|
191
203
|
|
|
192
204
|
--chart-2: #6ea4ff;
|
|
193
205
|
--chart-3: #f0a256;
|
|
@@ -522,6 +534,15 @@
|
|
|
522
534
|
--color-danger: var(--danger);
|
|
523
535
|
--color-danger-solid: var(--danger-solid);
|
|
524
536
|
--color-info: var(--info);
|
|
537
|
+
--color-success-ink: var(--success-ink);
|
|
538
|
+
--color-warning-ink: var(--warning-ink);
|
|
539
|
+
--color-danger-ink: var(--danger-ink);
|
|
540
|
+
--color-info-ink: var(--info-ink);
|
|
541
|
+
/* text-<status> reads the ink; bg-/border-/fill-<status> keep the base hue */
|
|
542
|
+
--text-color-success: var(--success-ink);
|
|
543
|
+
--text-color-warning: var(--warning-ink);
|
|
544
|
+
--text-color-danger: var(--danger-ink);
|
|
545
|
+
--text-color-info: var(--info-ink);
|
|
525
546
|
--color-chart-1: var(--chart-1);
|
|
526
547
|
--color-chart-2: var(--chart-2);
|
|
527
548
|
--color-chart-3: var(--chart-3);
|
|
@@ -647,15 +668,24 @@ html {
|
|
|
647
668
|
}
|
|
648
669
|
/* Semantic tints shared by Badge, Alert, Toast and Status picker:
|
|
649
670
|
pick a hue with tone-<name> (or set --tone), paint with tone-soft. */
|
|
650
|
-
@utility tone-neutral { --tone: var(--fg-muted); }
|
|
651
|
-
@utility tone-accent { --tone: var(--accent-ink); }
|
|
652
|
-
@utility tone-success { --tone: var(--success); }
|
|
653
|
-
@utility tone-warning { --tone: var(--warning); }
|
|
654
|
-
@utility tone-danger { --tone: var(--danger); }
|
|
655
|
-
@utility tone-info { --tone: var(--info); }
|
|
671
|
+
@utility tone-neutral { --tone: var(--fg-muted); --tone-ink: var(--fg-muted); }
|
|
672
|
+
@utility tone-accent { --tone: var(--accent-ink); --tone-ink: var(--accent-ink); }
|
|
673
|
+
@utility tone-success { --tone: var(--success); --tone-ink: var(--success-ink); }
|
|
674
|
+
@utility tone-warning { --tone: var(--warning); --tone-ink: var(--warning-ink); }
|
|
675
|
+
@utility tone-danger { --tone: var(--danger); --tone-ink: var(--danger-ink); }
|
|
676
|
+
@utility tone-info { --tone: var(--info); --tone-ink: var(--info-ink); }
|
|
656
677
|
@utility tone-soft {
|
|
657
678
|
background-color: color-mix(in srgb, var(--tone, var(--fg-muted)) var(--tone-mix, 13%), transparent);
|
|
658
|
-
color: color-mix(in srgb, var(--tone, var(--fg-muted)) var(--tone-ink-mix, 100%), var(--fg));
|
|
679
|
+
color: color-mix(in srgb, var(--tone, var(--fg-muted)) var(--tone-ink-mix, 100%), var(--tone-ink-base, var(--fg)));
|
|
680
|
+
}
|
|
681
|
+
/* The nav stays dark in the light theme: tone-soft text mixes toward white there instead of --fg
|
|
682
|
+
(light: >= 4.9:1 on the solid and glass rail for every tone). */
|
|
683
|
+
:where(.surface-nav, .bg-nav) {
|
|
684
|
+
--tone-ink-base: var(--nav-fg-strong);
|
|
685
|
+
--tone-ink-mix: 50%;
|
|
686
|
+
}
|
|
687
|
+
:where(.dark .surface-nav, .dark .bg-nav) {
|
|
688
|
+
--tone-ink-mix: 80%;
|
|
659
689
|
}
|
|
660
690
|
@utility focus-ring {
|
|
661
691
|
&:focus-visible {
|