@aleph-alpha/ui-library 6.5.0 → 6.6.0
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/dist/system/components/core/toggle/index.d.ts +1 -1
- package/dist/system/lib.js +14623 -14438
- package/dist/system/patterns/UiFloatActions/UiFloatActionItems.vue.d.ts +21 -174
- package/dist/system/patterns/UiFloatActions/core/FloatingButton.vue.d.ts +36 -0
- package/dist/system/patterns/UiFloatActions/core/FloatingInput.vue.d.ts +19 -0
- package/dist/system/patterns/UiFloatActions/floatActionItemContext.d.ts +3 -1
- package/dist/system/patterns/UiFloatActions/types.d.ts +93 -19
- package/dist/system/patterns/UiLayout/layout-shell.d.ts +117 -252
- package/package.json +2 -2
- package/src/components/UiAccordion/UiAccordion.stories.ts +8 -8
- package/src/components/UiAlert/UiAlert.stories.ts +13 -13
- package/src/components/UiAlertDialog/UiAlertDialog.stories.ts +4 -4
- package/src/components/UiAutocomplete/UiAutocomplete.stories.ts +13 -13
- package/src/components/UiAutocomplete/UiAutocomplete.vue +3 -3
- package/src/components/UiBadge/UiBadge.stories.ts +9 -9
- package/src/components/UiBreadcrumb/UiBreadcrumb.stories.ts +14 -14
- package/src/components/UiButton/UiButton.stories.ts +35 -35
- package/src/components/UiButtonGroup/UiButtonGroup.stories.ts +6 -6
- package/src/components/UiCalendar/UiCalendar.stories.ts +6 -6
- package/src/components/UiCard/UiCard.stories.ts +6 -6
- package/src/components/UiCheckbox/UiCheckbox.stories.ts +30 -30
- package/src/components/UiChip/UiChip.stories.ts +14 -14
- package/src/components/UiChip/UiChip.vue +1 -1
- package/src/components/UiDialog/UiDialog.stories.ts +20 -20
- package/src/components/UiDrawer/UiDrawer.stories.ts +29 -29
- package/src/components/UiDropdownMenu/UiDropdownMenu.stories.ts +13 -13
- package/src/components/UiEmpty/UiEmpty.vue +1 -1
- package/src/components/UiFadeMask/UiFadeMask.stories.ts +13 -13
- package/src/components/UiField/UiField.stories.ts +27 -27
- package/src/components/UiFileItem/UiFileItem.vue +4 -4
- package/src/components/UiFileItem/__tests__/UiFileItem.test.ts +2 -2
- package/src/components/UiFileType/UiFileType.stories.ts +10 -10
- package/src/components/UiFileUploadBox/UiFileUploadBox.stories.ts +10 -10
- package/src/components/UiFileUploadBox/UiFileUploadBox.vue +3 -3
- package/src/components/UiIcon/UiIcon.stories.ts +9 -9
- package/src/components/UiInput/UiInput.stories.ts +13 -13
- package/src/components/UiInput/UiInput.vue +1 -1
- package/src/components/UiInputGroup/UiInputGroup.stories.ts +10 -10
- package/src/components/UiItem/UiItem.stories.ts +12 -12
- package/src/components/UiItem/__tests__/UiItem.test.ts +2 -2
- package/src/components/UiKbd/UiKbd.stories.ts +18 -18
- package/src/components/UiKbd/UiKbd.vue +1 -1
- package/src/components/UiLabel/UiLabel.stories.ts +12 -12
- package/src/components/UiLabel/__tests__/UiLabel.test.ts +1 -1
- package/src/components/UiListbox/UiListbox.stories.ts +20 -20
- package/src/components/UiNavigationMenu/UiNavigationMenu.stories.ts +94 -94
- package/src/components/UiPopover/UiPopover.stories.ts +35 -35
- package/src/components/UiRadioGroup/UiRadioGroup.stories.ts +53 -53
- package/src/components/UiRangeCalendar/UiRangeCalendar.stories.ts +6 -6
- package/src/components/UiResizable/UiResizable.stories.ts +40 -40
- package/src/components/UiSelect/UiSelect.stories.ts +14 -14
- package/src/components/UiSeparator/UiSeparator.stories.ts +16 -16
- package/src/components/UiSheet/UiSheet.stories.ts +29 -29
- package/src/components/UiSlider/UiSlider.stories.ts +28 -28
- package/src/components/UiSnackbar/UiSnackbar.stories.ts +6 -6
- package/src/components/UiSnackbar/UiSnackbar.vue +2 -2
- package/src/components/UiSnackbar/UiSnackbarContent.vue +2 -2
- package/src/components/UiSpinner/UiSpinner.stories.ts +8 -8
- package/src/components/UiStepper/UiStepper.stories.ts +6 -6
- package/src/components/UiSwitch/UiSwitch.stories.ts +37 -37
- package/src/components/UiTable/UiTable.stories.ts +4 -4
- package/src/components/UiTabs/UiTabs.stories.ts +64 -64
- package/src/components/UiTagsInput/UiTagsInput.stories.ts +16 -16
- package/src/components/UiTextarea/UiTextarea.stories.ts +20 -20
- package/src/components/UiToggle/UiToggle.stories.ts +26 -26
- package/src/components/UiToggleGroup/UiToggleGroup.stories.ts +31 -31
- package/src/components/UiTooltip/UiTooltip.stories.ts +7 -7
- package/src/components/core/accordion/AccordionContent.vue +1 -1
- package/src/components/core/accordion/AccordionTrigger.vue +1 -1
- package/src/components/core/alert/AlertDescription.vue +1 -1
- package/src/components/core/alert/index.ts +1 -1
- package/src/components/core/alert-dialog/AlertDialogDescription.vue +1 -1
- package/src/components/core/badge/index.ts +2 -2
- package/src/components/core/button/index.ts +3 -3
- package/src/components/core/calendar/Calendar.vue +4 -4
- package/src/components/core/calendar/CalendarCell.vue +1 -1
- package/src/components/core/calendar/CalendarHeading.vue +1 -1
- package/src/components/core/card/CardDescription.vue +1 -1
- package/src/components/core/dialog/DialogDescription.vue +1 -1
- package/src/components/core/drawer/DrawerDescription.vue +1 -1
- package/src/components/core/dropdown-menu/DropdownMenuCheckboxItem.vue +1 -1
- package/src/components/core/dropdown-menu/DropdownMenuLabel.vue +1 -1
- package/src/components/core/dropdown-menu/DropdownMenuRadioItem.vue +1 -1
- package/src/components/core/dropdown-menu/DropdownMenuShortcut.vue +1 -1
- package/src/components/core/dropdown-menu/DropdownMenuSubTrigger.vue +1 -1
- package/src/components/core/field/FieldDescription.vue +1 -1
- package/src/components/core/field/FieldError.vue +1 -1
- package/src/components/core/field/FieldLabel.vue +1 -1
- package/src/components/core/field/FieldLegend.vue +2 -2
- package/src/components/core/field/FieldSeparator.vue +1 -1
- package/src/components/core/field/FieldTitle.vue +1 -1
- package/src/components/core/input/Input.vue +1 -1
- package/src/components/core/input-group/InputGroupText.vue +1 -1
- package/src/components/core/input-group/index.ts +1 -1
- package/src/components/core/item/ItemDescription.vue +1 -1
- package/src/components/core/item/ItemTitle.vue +1 -1
- package/src/components/core/item/index.ts +2 -2
- package/src/components/core/label/Label.vue +1 -1
- package/src/components/core/listbox/ListboxFilter.vue +1 -1
- package/src/components/core/listbox/ListboxGroupLabel.vue +1 -1
- package/src/components/core/listbox/ListboxItem.vue +1 -1
- package/src/components/core/native-select/NativeSelect.vue +1 -1
- package/src/components/core/navigation-menu/NavigationMenuLink.vue +1 -1
- package/src/components/core/navigation-menu/index.ts +1 -1
- package/src/components/core/range-calendar/RangeCalendarCell.vue +1 -1
- package/src/components/core/range-calendar/RangeCalendarHeading.vue +1 -1
- package/src/components/core/select/SelectItem.vue +1 -1
- package/src/components/core/select/SelectLabel.vue +1 -1
- package/src/components/core/select/SelectTrigger.vue +1 -1
- package/src/components/core/sheet/SheetDescription.vue +1 -1
- package/src/components/core/sidebar/SidebarGroupContent.vue +1 -1
- package/src/components/core/sidebar/SidebarGroupLabel.vue +1 -1
- package/src/components/core/sidebar/SidebarMenuBadge.vue +1 -1
- package/src/components/core/sidebar/SidebarMenuSubButton.vue +2 -2
- package/src/components/core/sidebar/index.ts +4 -4
- package/src/components/core/stepper/StepperDescription.vue +1 -1
- package/src/components/core/stepper/StepperTitle.vue +1 -1
- package/src/components/core/table/Table.vue +1 -1
- package/src/components/core/table/TableCaption.vue +1 -1
- package/src/components/core/table/TableEmpty.vue +1 -1
- package/src/components/core/tabs/TabsTrigger.vue +1 -1
- package/src/components/core/tags-input/TagsInput.vue +1 -1
- package/src/components/core/tags-input/TagsInputItem.vue +1 -1
- package/src/components/core/textarea/Textarea.vue +1 -1
- package/src/components/core/toggle/index.ts +1 -1
- package/src/components/core/tooltip/TooltipContent.vue +1 -1
- package/src/directives/vHover.stories.ts +17 -17
- package/src/lib/useDevice.stories.ts +29 -29
- package/src/lib/useDrag.stories.ts +14 -14
- package/src/patterns/UiDataTable/UiDataTable.stories.ts +27 -27
- package/src/patterns/UiDataTable/UiDataTableColumnFilter.vue +2 -2
- package/src/patterns/UiDataTable/UiDataTableFilterMenu.vue +2 -2
- package/src/patterns/UiDataTable/UiDataTablePagination.vue +3 -3
- package/src/patterns/UiDataTable/__tests__/UiDataTableColumnFilter.test.ts +2 -2
- package/src/patterns/UiDatePicker/UiDatePicker.stories.ts +14 -14
- package/src/patterns/UiFileUpload/UiFileItem.stories.ts +14 -14
- package/src/patterns/UiFileUpload/UiFileUpload.stories.ts +6 -6
- package/src/patterns/UiFloatActions/UiFloatActionItems.vue +226 -76
- package/src/patterns/UiFloatActions/UiFloatActions.stories.ts +1136 -116
- package/src/patterns/UiFloatActions/__tests__/UiFloatActionItems.test.ts +187 -1
- package/src/patterns/UiFloatActions/core/FloatingButton.vue +83 -0
- package/src/patterns/UiFloatActions/core/FloatingInput.vue +53 -0
- package/src/patterns/UiFloatActions/floatActionItemContext.ts +3 -1
- package/src/patterns/UiFloatActions/types.ts +106 -19
- package/src/patterns/UiLayout/UiLayoutContent.stories.ts +17 -17
- package/src/patterns/UiLayout/UiLayoutMobile.stories.ts +4 -4
- package/src/patterns/UiLayout/layout-shell.ts +6 -6
- package/src/patterns/UiProfileCard/UiProfileCard.stories.ts +8 -8
- package/src/patterns/UiProfileCard/profile-card.ts +2 -2
- package/src/patterns/UiSidebar/UiSidebar.stories.ts +6 -6
- package/src/patterns/UiSidebar/UiSidebarGroup.stories.ts +1 -1
- package/src/patterns/UiSidebar/UiSidebarGroupLabel.stories.ts +4 -4
- package/src/patterns/UiSidebar/UiSidebarGroupLabel.vue +1 -1
- package/src/patterns/UiSidebar/UiSidebarHeader.vue +1 -1
- package/src/patterns/UiSidebar/UiSidebarMenuButton.stories.ts +7 -7
- package/src/patterns/UiSidebar/UiSidebarMenuButton.vue +4 -4
- package/src/patterns/UiSidebar/UiSidebarMenuItem.stories.ts +4 -4
- package/src/patterns/UiSidebar/UiSidebarMenuSubItem.stories.ts +1 -1
- package/src/patterns/UiSidebar/UiSidebarMenuSubItem.vue +1 -1
- package/src/patterns/UiSidebar/UiSidebarPopoverMenu.vue +1 -1
- package/src/patterns/UiSidebar/UiSidebarPopoverMenuItem.vue +3 -3
- package/src/patterns/UiSidebar/UiSidebarPopoverTrigger.stories.ts +1 -1
- package/src/patterns/UiSidebar/UiSidebarPopoverTrigger.vue +1 -1
- package/src/patterns/UiSidebar/UiSidebarSub.stories.ts +1 -1
- package/src/patterns/UiTopBar/UiTopBar.stories.ts +24 -24
- package/src/theme/Background.stories.ts +62 -62
- package/src/theme/Border.stories.ts +19 -19
- package/src/theme/BorderRadius.stories.ts +14 -14
- package/src/theme/Extended.stories.ts +26 -26
- package/src/theme/Flex.stories.ts +21 -21
- package/src/theme/Grid.stories.ts +19 -19
- package/src/theme/HoverLayer.stories.ts +26 -26
- package/src/theme/Overlay.stories.ts +14 -14
- package/src/theme/Scrollbar.stories.ts +58 -58
- package/src/theme/Shadow.stories.ts +5 -5
- package/src/theme/Theme.stories.ts +38 -38
|
@@ -58,7 +58,7 @@ const triggerAriaLabel = computed(() =>
|
|
|
58
58
|
:active="open || hasActiveFilters"
|
|
59
59
|
soft
|
|
60
60
|
size="sm"
|
|
61
|
-
class="label-
|
|
61
|
+
class="label-s-medium h-8"
|
|
62
62
|
left-icon="list-filter"
|
|
63
63
|
:aria-label="triggerAriaLabel"
|
|
64
64
|
>
|
|
@@ -68,7 +68,7 @@ const triggerAriaLabel = computed(() =>
|
|
|
68
68
|
v-if="hasActiveFilters"
|
|
69
69
|
variant="default"
|
|
70
70
|
size="small"
|
|
71
|
-
class="h-5 min-w-5 justify-center px-1 label-
|
|
71
|
+
class="h-5 min-w-5 justify-center px-1 label-xs-medium"
|
|
72
72
|
>
|
|
73
73
|
{{ activeCount }}
|
|
74
74
|
</UiBadge>
|
|
@@ -38,7 +38,7 @@ const labels = computed(() => ({
|
|
|
38
38
|
<div class="flex items-center gap-2 justify-between px-2">
|
|
39
39
|
<div
|
|
40
40
|
v-if="showSelection"
|
|
41
|
-
class="flex-1 body-
|
|
41
|
+
class="flex-1 body-s-regular text-content-on-surface-muted"
|
|
42
42
|
>
|
|
43
43
|
{{
|
|
44
44
|
labels.rowsSelected(
|
|
@@ -50,7 +50,7 @@ const labels = computed(() => ({
|
|
|
50
50
|
<div v-else class="flex-1" />
|
|
51
51
|
<div class="flex items-center gap-x-6 lg:gap-x-8">
|
|
52
52
|
<div v-if="showPageSize" class="flex items-center gap-x-2">
|
|
53
|
-
<p id="rows-per-page-label" class="body-
|
|
53
|
+
<p id="rows-per-page-label" class="body-s-medium">
|
|
54
54
|
{{ labels.rowsPerPage }}
|
|
55
55
|
</p>
|
|
56
56
|
<UiDropdownMenu>
|
|
@@ -75,7 +75,7 @@ const labels = computed(() => ({
|
|
|
75
75
|
</UiDropdownMenuContent>
|
|
76
76
|
</UiDropdownMenu>
|
|
77
77
|
</div>
|
|
78
|
-
<div class="flex w-[100px] items-center justify-center body-
|
|
78
|
+
<div class="flex w-[100px] items-center justify-center body-s-medium">
|
|
79
79
|
{{
|
|
80
80
|
labels.pageOf(
|
|
81
81
|
table.getState().pagination.pageIndex + 1,
|
|
@@ -86,7 +86,7 @@ describe('UiDataTableColumnFilter', () => {
|
|
|
86
86
|
render(UiDataTableColumnFilter, { props: { table: table as never } });
|
|
87
87
|
|
|
88
88
|
const trigger = screen.getByRole('button', { name: 'Toggle columns' });
|
|
89
|
-
expect(trigger.className).toContain('label-
|
|
89
|
+
expect(trigger.className).toContain('label-s-medium');
|
|
90
90
|
expect(trigger.className).toContain('font-medium');
|
|
91
91
|
expect(trigger.querySelectorAll('[data-slot="icon"]')).toHaveLength(2);
|
|
92
92
|
|
|
@@ -100,7 +100,7 @@ describe('UiDataTableColumnFilter', () => {
|
|
|
100
100
|
const itemClassName = screen.getByRole('menuitemcheckbox', {
|
|
101
101
|
name: 'Status',
|
|
102
102
|
}).className;
|
|
103
|
-
expect(itemClassName).toContain('body-
|
|
103
|
+
expect(itemClassName).toContain('body-s-regular');
|
|
104
104
|
expect(itemClassName).toContain('gap-2');
|
|
105
105
|
expect(itemClassName).toContain('p-2');
|
|
106
106
|
expect(itemClassName).toContain('pl-8');
|
|
@@ -956,14 +956,14 @@ const appointmentDate = ref<DateValue>()
|
|
|
956
956
|
|
|
957
957
|
<template>
|
|
958
958
|
<div class="gap-y-2">
|
|
959
|
-
<label class="label-
|
|
959
|
+
<label class="label-s-medium">Appointment Date</label>
|
|
960
960
|
<UiDatePicker
|
|
961
961
|
v-model="appointmentDate"
|
|
962
962
|
placeholder="Select appointment date"
|
|
963
963
|
class="w-full"
|
|
964
964
|
aria-label="Select appointment date"
|
|
965
965
|
/>
|
|
966
|
-
<p class="label-
|
|
966
|
+
<p class="label-xs-regular text-content-on-surface-muted">
|
|
967
967
|
Choose a date for your appointment.
|
|
968
968
|
</p>
|
|
969
969
|
</div>
|
|
@@ -981,7 +981,7 @@ export const FormExample: Story = {
|
|
|
981
981
|
return { appointmentDate, args };
|
|
982
982
|
},
|
|
983
983
|
template: `<div class="gap-y-2">
|
|
984
|
-
<label class="label-
|
|
984
|
+
<label class="label-s-medium">Appointment Date</label>
|
|
985
985
|
<UiDatePicker
|
|
986
986
|
v-model="appointmentDate"
|
|
987
987
|
placeholder="Select appointment date"
|
|
@@ -990,7 +990,7 @@ export const FormExample: Story = {
|
|
|
990
990
|
:disabled="args.disabled"
|
|
991
991
|
:locale="args.locale"
|
|
992
992
|
/>
|
|
993
|
-
<p class="label-
|
|
993
|
+
<p class="label-xs-regular text-content-on-surface-muted">
|
|
994
994
|
Choose a date for your appointment.
|
|
995
995
|
</p>
|
|
996
996
|
</div>`,
|
|
@@ -1273,7 +1273,7 @@ const travelDates = ref<DateRange>()
|
|
|
1273
1273
|
|
|
1274
1274
|
<template>
|
|
1275
1275
|
<div class="gap-y-2 max-w-sm">
|
|
1276
|
-
<label for="travel-dates" class="label-
|
|
1276
|
+
<label for="travel-dates" class="label-s-medium">
|
|
1277
1277
|
Travel Dates
|
|
1278
1278
|
</label>
|
|
1279
1279
|
<UiDatePicker
|
|
@@ -1284,7 +1284,7 @@ const travelDates = ref<DateRange>()
|
|
|
1284
1284
|
placeholder="Select dates"
|
|
1285
1285
|
aria-label="Select travel dates"
|
|
1286
1286
|
/>
|
|
1287
|
-
<p class="label-
|
|
1287
|
+
<p class="label-xs-regular text-content-on-surface-muted">
|
|
1288
1288
|
Choose your check-in and check-out dates.
|
|
1289
1289
|
</p>
|
|
1290
1290
|
</div>
|
|
@@ -1307,7 +1307,7 @@ export const RangeFormExample: Story = {
|
|
|
1307
1307
|
return { travelDates, args };
|
|
1308
1308
|
},
|
|
1309
1309
|
template: `<div class="gap-y-2 max-w-sm">
|
|
1310
|
-
<label for="travel-dates" class="label-
|
|
1310
|
+
<label for="travel-dates" class="label-s-medium">
|
|
1311
1311
|
Travel Dates
|
|
1312
1312
|
</label>
|
|
1313
1313
|
<UiDatePicker
|
|
@@ -1320,7 +1320,7 @@ export const RangeFormExample: Story = {
|
|
|
1320
1320
|
:disabled="args.disabled"
|
|
1321
1321
|
:locale="args.locale"
|
|
1322
1322
|
/>
|
|
1323
|
-
<p class="label-
|
|
1323
|
+
<p class="label-xs-regular text-content-on-surface-muted">
|
|
1324
1324
|
Choose your check-in and check-out dates.
|
|
1325
1325
|
</p>
|
|
1326
1326
|
</div>`,
|
|
@@ -1724,10 +1724,10 @@ export const Accessibility: Story = {
|
|
|
1724
1724
|
|
|
1725
1725
|
<div class="flex flex-col gap-6">
|
|
1726
1726
|
<div class="flex flex-col gap-2">
|
|
1727
|
-
<h3 class="body-
|
|
1727
|
+
<h3 class="body-m-medium text-content-on-surface-primary">
|
|
1728
1728
|
Requirements
|
|
1729
1729
|
</h3>
|
|
1730
|
-
<ul class="body-
|
|
1730
|
+
<ul class="body-m-regular flex list-disc flex-col gap-1 pl-6 text-content-on-surface-primary">
|
|
1731
1731
|
<li>
|
|
1732
1732
|
Today and the selected day differ in shape as well as fill, so
|
|
1733
1733
|
both survive without colour
|
|
@@ -1769,10 +1769,10 @@ export const Accessibility: Story = {
|
|
|
1769
1769
|
</div>
|
|
1770
1770
|
|
|
1771
1771
|
<div class="flex flex-col gap-2">
|
|
1772
|
-
<h3 class="body-
|
|
1772
|
+
<h3 class="body-m-medium text-content-on-surface-primary">
|
|
1773
1773
|
Enable accessibility theme
|
|
1774
1774
|
</h3>
|
|
1775
|
-
<p class="body-
|
|
1775
|
+
<p class="body-m-regular text-content-on-surface-primary">
|
|
1776
1776
|
When accessibility is required, enable our accessibility theme.
|
|
1777
1777
|
This increases contrast and ensures there are no color contrast
|
|
1778
1778
|
issues.
|
|
@@ -1782,7 +1782,7 @@ export const Accessibility: Story = {
|
|
|
1782
1782
|
|
|
1783
1783
|
<div class="grid gap-4 md:grid-cols-2">
|
|
1784
1784
|
<div class="flex flex-col gap-3">
|
|
1785
|
-
<h3 class="label-
|
|
1785
|
+
<h3 class="label-m-medium text-center text-content-on-surface-primary">
|
|
1786
1786
|
Default
|
|
1787
1787
|
</h3>
|
|
1788
1788
|
<div class="flex min-h-20 items-center justify-center border border-border-surface-default p-6">
|
|
@@ -1791,7 +1791,7 @@ export const Accessibility: Story = {
|
|
|
1791
1791
|
</div>
|
|
1792
1792
|
|
|
1793
1793
|
<div class="accessible-theme flex flex-col gap-3">
|
|
1794
|
-
<h3 class="label-
|
|
1794
|
+
<h3 class="label-m-medium text-center text-content-on-surface-primary">
|
|
1795
1795
|
Accessible
|
|
1796
1796
|
</h3>
|
|
1797
1797
|
<div class="flex min-h-20 items-center justify-center border border-border-surface-default p-6">
|
|
@@ -611,7 +611,7 @@ const onRemove = () => undefined;
|
|
|
611
611
|
<template>
|
|
612
612
|
<div class="flex flex-wrap gap-8">
|
|
613
613
|
<div class="flex max-w-md flex-1 flex-col gap-3">
|
|
614
|
-
<p class="label-
|
|
614
|
+
<p class="label-xs-medium text-content-on-surface-muted">Default size</p>
|
|
615
615
|
<UiFileItem filename="Filename.pdf" :progress="30" @remove="onRemove" />
|
|
616
616
|
<UiFileItem
|
|
617
617
|
filename="Filename.pdf"
|
|
@@ -629,7 +629,7 @@ const onRemove = () => undefined;
|
|
|
629
629
|
<UiFileItem filename="Filename.pdf" error="Upload failed" @remove="onRemove" />
|
|
630
630
|
</div>
|
|
631
631
|
<div class="flex max-w-64 flex-1 flex-col gap-3">
|
|
632
|
-
<p class="label-
|
|
632
|
+
<p class="label-xs-medium text-content-on-surface-muted">Small size</p>
|
|
633
633
|
<UiFileItem size="small" filename="Filename.pdf" :progress="30" @remove="onRemove" />
|
|
634
634
|
<UiFileItem
|
|
635
635
|
size="small"
|
|
@@ -797,7 +797,7 @@ const items = [
|
|
|
797
797
|
<template>
|
|
798
798
|
<div class="flex flex-wrap gap-8">
|
|
799
799
|
<div class="flex max-w-md flex-1 flex-col gap-3">
|
|
800
|
-
<p class="label-
|
|
800
|
+
<p class="label-xs-medium text-content-on-surface-muted">Default size</p>
|
|
801
801
|
<UiFileItem
|
|
802
802
|
filename="Attached documents"
|
|
803
803
|
type-label="4 files"
|
|
@@ -810,7 +810,7 @@ const items = [
|
|
|
810
810
|
/>
|
|
811
811
|
</div>
|
|
812
812
|
<div class="flex max-w-64 flex-1 flex-col gap-3">
|
|
813
|
-
<p class="label-
|
|
813
|
+
<p class="label-xs-medium text-content-on-surface-muted">Small size</p>
|
|
814
814
|
<UiFileItem
|
|
815
815
|
size="small"
|
|
816
816
|
filename="Attached documents"
|
|
@@ -843,7 +843,7 @@ export const Multi: Story = {
|
|
|
843
843
|
template: `
|
|
844
844
|
<div class="flex flex-wrap gap-8">
|
|
845
845
|
<div class="flex max-w-md flex-1 flex-col gap-3">
|
|
846
|
-
<p class="label-
|
|
846
|
+
<p class="label-xs-medium text-content-on-surface-muted">Default size</p>
|
|
847
847
|
<UiFileItem
|
|
848
848
|
filename="Attached documents"
|
|
849
849
|
type-label="4 files"
|
|
@@ -856,7 +856,7 @@ export const Multi: Story = {
|
|
|
856
856
|
/>
|
|
857
857
|
</div>
|
|
858
858
|
<div class="flex max-w-64 flex-1 flex-col gap-3">
|
|
859
|
-
<p class="label-
|
|
859
|
+
<p class="label-xs-medium text-content-on-surface-muted">Small size</p>
|
|
860
860
|
<UiFileItem
|
|
861
861
|
size="small"
|
|
862
862
|
filename="Attached documents"
|
|
@@ -1167,7 +1167,7 @@ export const AllVariants: Story = {
|
|
|
1167
1167
|
template: `
|
|
1168
1168
|
<div class="flex flex-wrap gap-8">
|
|
1169
1169
|
<div class="flex max-w-md flex-1 flex-col gap-3">
|
|
1170
|
-
<p class="label-
|
|
1170
|
+
<p class="label-xs-medium text-content-on-surface-muted">Default size</p>
|
|
1171
1171
|
<UiFileItem filename="Filename.pdf" :progress="30" @remove="onRemove" />
|
|
1172
1172
|
<UiFileItem
|
|
1173
1173
|
filename="Filename.pdf"
|
|
@@ -1185,7 +1185,7 @@ export const AllVariants: Story = {
|
|
|
1185
1185
|
<UiFileItem filename="Filename.pdf" error="Upload failed" @remove="onRemove" />
|
|
1186
1186
|
</div>
|
|
1187
1187
|
<div class="flex max-w-64 flex-1 flex-col gap-3">
|
|
1188
|
-
<p class="label-
|
|
1188
|
+
<p class="label-xs-medium text-content-on-surface-muted">Small size</p>
|
|
1189
1189
|
<UiFileItem size="small" filename="Filename.pdf" :progress="30" @remove="onRemove" />
|
|
1190
1190
|
<UiFileItem
|
|
1191
1191
|
size="small"
|
|
@@ -1228,19 +1228,19 @@ export const Accessibility: Story = {
|
|
|
1228
1228
|
|
|
1229
1229
|
<div class="flex flex-col gap-6">
|
|
1230
1230
|
<div class="flex flex-col gap-2">
|
|
1231
|
-
<h3 class="body-
|
|
1231
|
+
<h3 class="body-m-medium text-content-on-surface-primary">
|
|
1232
1232
|
Enable accessibility theme
|
|
1233
1233
|
</h3>
|
|
1234
|
-
<p class="body-
|
|
1234
|
+
<p class="body-m-regular text-content-on-surface-primary">
|
|
1235
1235
|
When accessibility is required, enable our accessibility theme. This increases contrast and makes sure there are no color contrast issues.
|
|
1236
1236
|
</p>
|
|
1237
1237
|
</div>
|
|
1238
1238
|
|
|
1239
1239
|
<div class="flex flex-col gap-2">
|
|
1240
|
-
<h3 class="body-
|
|
1240
|
+
<h3 class="body-m-medium text-content-on-surface-primary">
|
|
1241
1241
|
Never rely on the media badge alone
|
|
1242
1242
|
</h3>
|
|
1243
|
-
<p class="body-
|
|
1243
|
+
<p class="body-m-regular text-content-on-surface-primary">
|
|
1244
1244
|
The round media badge is decorative and hidden from assistive tech, so the file family must also be stated in text. In the accessibility theme the media badge for video resolves to the same yellow as tabular files, which is why every row keeps its type label and its own icon. Processing uses the same neutral badge as an upload in progress, so the status has to be the text “Processing…”, not the badge.
|
|
1245
1245
|
</p>
|
|
1246
1246
|
</div>
|
|
@@ -1248,7 +1248,7 @@ export const Accessibility: Story = {
|
|
|
1248
1248
|
|
|
1249
1249
|
<div class="grid gap-4 md:grid-cols-2">
|
|
1250
1250
|
<div class="flex flex-col gap-3">
|
|
1251
|
-
<h3 class="label-
|
|
1251
|
+
<h3 class="label-m-medium text-center text-content-on-surface-primary">
|
|
1252
1252
|
Default
|
|
1253
1253
|
</h3>
|
|
1254
1254
|
<div class="flex flex-col gap-3 border border-border-surface-default p-4">
|
|
@@ -1258,7 +1258,7 @@ export const Accessibility: Story = {
|
|
|
1258
1258
|
</div>
|
|
1259
1259
|
|
|
1260
1260
|
<div class="accessible-theme flex flex-col gap-3">
|
|
1261
|
-
<h3 class="label-
|
|
1261
|
+
<h3 class="label-m-medium text-center text-content-on-surface-primary">
|
|
1262
1262
|
Accessible
|
|
1263
1263
|
</h3>
|
|
1264
1264
|
<div class="flex flex-col gap-3 border border-border-surface-default p-4">
|
|
@@ -829,10 +829,10 @@ export const Accessibility: Story = {
|
|
|
829
829
|
|
|
830
830
|
<div class="flex flex-col gap-6">
|
|
831
831
|
<div class="flex flex-col gap-2">
|
|
832
|
-
<h3 class="body-
|
|
832
|
+
<h3 class="body-m-medium text-content-on-surface-primary">
|
|
833
833
|
Requirements
|
|
834
834
|
</h3>
|
|
835
|
-
<ul class="body-
|
|
835
|
+
<ul class="body-m-regular flex list-disc flex-col gap-1 pl-6 text-content-on-surface-primary">
|
|
836
836
|
<li>
|
|
837
837
|
The drop zone reads as an interactive target at rest, not only
|
|
838
838
|
while a file is dragged over it
|
|
@@ -863,10 +863,10 @@ export const Accessibility: Story = {
|
|
|
863
863
|
</div>
|
|
864
864
|
|
|
865
865
|
<div class="flex flex-col gap-2">
|
|
866
|
-
<h3 class="body-
|
|
866
|
+
<h3 class="body-m-medium text-content-on-surface-primary">
|
|
867
867
|
Enable accessibility theme
|
|
868
868
|
</h3>
|
|
869
|
-
<p class="body-
|
|
869
|
+
<p class="body-m-regular text-content-on-surface-primary">
|
|
870
870
|
When accessibility is required, enable our accessibility theme.
|
|
871
871
|
This increases contrast and ensures there are no color contrast
|
|
872
872
|
issues.
|
|
@@ -876,7 +876,7 @@ export const Accessibility: Story = {
|
|
|
876
876
|
|
|
877
877
|
<div class="grid gap-4 md:grid-cols-2">
|
|
878
878
|
<div class="flex flex-col gap-3">
|
|
879
|
-
<h3 class="label-
|
|
879
|
+
<h3 class="label-m-medium text-center text-content-on-surface-primary">
|
|
880
880
|
Default
|
|
881
881
|
</h3>
|
|
882
882
|
<div class="flex min-h-20 flex-col justify-center gap-3 border border-border-surface-default p-6">
|
|
@@ -906,7 +906,7 @@ export const Accessibility: Story = {
|
|
|
906
906
|
</div>
|
|
907
907
|
|
|
908
908
|
<div class="accessible-theme flex flex-col gap-3">
|
|
909
|
-
<h3 class="label-
|
|
909
|
+
<h3 class="label-m-medium text-center text-content-on-surface-primary">
|
|
910
910
|
Accessible
|
|
911
911
|
</h3>
|
|
912
912
|
<div class="flex min-h-20 flex-col justify-center gap-3 border border-border-surface-default p-6">
|