@acronis-platform/ui-react 0.54.0 → 0.56.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/README.md +1 -1
- package/package.json +4 -2
- package/dist/components/ui/accordion/accordion.js +0 -53
- package/dist/components/ui/accordion/accordion.js.map +0 -1
- package/dist/components/ui/alert/alert.js +0 -99
- package/dist/components/ui/alert/alert.js.map +0 -1
- package/dist/components/ui/app-shell/app-shell.js +0 -75
- package/dist/components/ui/app-shell/app-shell.js.map +0 -1
- package/dist/components/ui/auth-layout/auth-layout.js +0 -56
- package/dist/components/ui/auth-layout/auth-layout.js.map +0 -1
- package/dist/components/ui/avatar/avatar.js +0 -70
- package/dist/components/ui/avatar/avatar.js.map +0 -1
- package/dist/components/ui/breadcrumb/breadcrumb.js +0 -116
- package/dist/components/ui/breadcrumb/breadcrumb.js.map +0 -1
- package/dist/components/ui/button/button.js +0 -50
- package/dist/components/ui/button/button.js.map +0 -1
- package/dist/components/ui/button-icon/button-icon.js +0 -35
- package/dist/components/ui/button-icon/button-icon.js.map +0 -1
- package/dist/components/ui/button-menu/button-menu.js +0 -52
- package/dist/components/ui/button-menu/button-menu.js.map +0 -1
- package/dist/components/ui/card/card.js +0 -92
- package/dist/components/ui/card/card.js.map +0 -1
- package/dist/components/ui/card-filter/card-filter.js +0 -63
- package/dist/components/ui/card-filter/card-filter.js.map +0 -1
- package/dist/components/ui/chart/chart.js +0 -213
- package/dist/components/ui/chart/chart.js.map +0 -1
- package/dist/components/ui/checkbox/checkbox.js +0 -70
- package/dist/components/ui/checkbox/checkbox.js.map +0 -1
- package/dist/components/ui/chip/chip.js +0 -70
- package/dist/components/ui/chip/chip.js.map +0 -1
- package/dist/components/ui/collapsible/collapsible.js +0 -22
- package/dist/components/ui/collapsible/collapsible.js.map +0 -1
- package/dist/components/ui/combobox/combobox.js +0 -149
- package/dist/components/ui/combobox/combobox.js.map +0 -1
- package/dist/components/ui/data-table/data-table-column-header.js +0 -36
- package/dist/components/ui/data-table/data-table-column-header.js.map +0 -1
- package/dist/components/ui/data-table/data-table-pagination.js +0 -89
- package/dist/components/ui/data-table/data-table-pagination.js.map +0 -1
- package/dist/components/ui/data-table/data-table-toolbar.js +0 -46
- package/dist/components/ui/data-table/data-table-toolbar.js.map +0 -1
- package/dist/components/ui/data-table/data-table-view-options.js +0 -40
- package/dist/components/ui/data-table/data-table-view-options.js.map +0 -1
- package/dist/components/ui/data-table/data-table.js +0 -89
- package/dist/components/ui/data-table/data-table.js.map +0 -1
- package/dist/components/ui/description-list/description-list.js +0 -54
- package/dist/components/ui/description-list/description-list.js.map +0 -1
- package/dist/components/ui/dialog/dialog.js +0 -140
- package/dist/components/ui/dialog/dialog.js.map +0 -1
- package/dist/components/ui/dropdown-menu/dropdown-menu.js +0 -159
- package/dist/components/ui/dropdown-menu/dropdown-menu.js.map +0 -1
- package/dist/components/ui/empty/empty.js +0 -78
- package/dist/components/ui/empty/empty.js.map +0 -1
- package/dist/components/ui/field/field.js +0 -189
- package/dist/components/ui/field/field.js.map +0 -1
- package/dist/components/ui/form/form.js +0 -16
- package/dist/components/ui/form/form.js.map +0 -1
- package/dist/components/ui/grid/grid.js +0 -69
- package/dist/components/ui/grid/grid.js.map +0 -1
- package/dist/components/ui/input/input.js +0 -22
- package/dist/components/ui/input/input.js.map +0 -1
- package/dist/components/ui/input-date-picker/input-date-picker.js +0 -104
- package/dist/components/ui/input-date-picker/input-date-picker.js.map +0 -1
- package/dist/components/ui/input-search/input-search.js +0 -57
- package/dist/components/ui/input-search/input-search.js.map +0 -1
- package/dist/components/ui/input-select/input-select.js +0 -265
- package/dist/components/ui/input-select/input-select.js.map +0 -1
- package/dist/components/ui/input-text/input-text.js +0 -87
- package/dist/components/ui/input-text/input-text.js.map +0 -1
- package/dist/components/ui/input-text-area/input-text-area.js +0 -77
- package/dist/components/ui/input-text-area/input-text-area.js.map +0 -1
- package/dist/components/ui/label/label.js +0 -12
- package/dist/components/ui/label/label.js.map +0 -1
- package/dist/components/ui/link/link.js +0 -39
- package/dist/components/ui/link/link.js.map +0 -1
- package/dist/components/ui/number-field/number-field.js +0 -61
- package/dist/components/ui/number-field/number-field.js.map +0 -1
- package/dist/components/ui/page-content/page-content.js +0 -19
- package/dist/components/ui/page-content/page-content.js.map +0 -1
- package/dist/components/ui/page-header/page-header.js +0 -74
- package/dist/components/ui/page-header/page-header.js.map +0 -1
- package/dist/components/ui/pagination/pagination.js +0 -87
- package/dist/components/ui/pagination/pagination.js.map +0 -1
- package/dist/components/ui/popover/popover.js +0 -48
- package/dist/components/ui/popover/popover.js.map +0 -1
- package/dist/components/ui/progress/progress.js +0 -30
- package/dist/components/ui/progress/progress.js.map +0 -1
- package/dist/components/ui/progress-circle/progress-circle.js +0 -115
- package/dist/components/ui/progress-circle/progress-circle.js.map +0 -1
- package/dist/components/ui/radio/radio.js +0 -44
- package/dist/components/ui/radio/radio.js.map +0 -1
- package/dist/components/ui/resizable/resizable.js +0 -52
- package/dist/components/ui/resizable/resizable.js.map +0 -1
- package/dist/components/ui/scroll-area/scroll-area.js +0 -61
- package/dist/components/ui/scroll-area/scroll-area.js.map +0 -1
- package/dist/components/ui/search/search.js +0 -93
- package/dist/components/ui/search/search.js.map +0 -1
- package/dist/components/ui/search-global/search-global.js +0 -60
- package/dist/components/ui/search-global/search-global.js.map +0 -1
- package/dist/components/ui/section/section.js +0 -37
- package/dist/components/ui/section/section.js.map +0 -1
- package/dist/components/ui/separator/separator.js +0 -22
- package/dist/components/ui/separator/separator.js.map +0 -1
- package/dist/components/ui/sheet/sheet-details.js +0 -80
- package/dist/components/ui/sheet/sheet-details.js.map +0 -1
- package/dist/components/ui/sheet/sheet.js +0 -138
- package/dist/components/ui/sheet/sheet.js.map +0 -1
- package/dist/components/ui/sidebar-primary/sidebar-primary.js +0 -252
- package/dist/components/ui/sidebar-primary/sidebar-primary.js.map +0 -1
- package/dist/components/ui/sidebar-secondary/sidebar-secondary.js +0 -470
- package/dist/components/ui/sidebar-secondary/sidebar-secondary.js.map +0 -1
- package/dist/components/ui/skeleton/skeleton.js +0 -22
- package/dist/components/ui/skeleton/skeleton.js.map +0 -1
- package/dist/components/ui/slider/slider.js +0 -42
- package/dist/components/ui/slider/slider.js.map +0 -1
- package/dist/components/ui/spinner/spinner.js +0 -38
- package/dist/components/ui/spinner/spinner.js.map +0 -1
- package/dist/components/ui/stack/stack.js +0 -61
- package/dist/components/ui/stack/stack.js.map +0 -1
- package/dist/components/ui/switch/switch.js +0 -41
- package/dist/components/ui/switch/switch.js.map +0 -1
- package/dist/components/ui/table/table.js +0 -118
- package/dist/components/ui/table/table.js.map +0 -1
- package/dist/components/ui/tabs/tabs.js +0 -44
- package/dist/components/ui/tabs/tabs.js.map +0 -1
- package/dist/components/ui/tag/tag.js +0 -47
- package/dist/components/ui/tag/tag.js.map +0 -1
- package/dist/components/ui/toast/toast.js +0 -83
- package/dist/components/ui/toast/toast.js.map +0 -1
- package/dist/components/ui/toggle-group/toggle-group.js +0 -47
- package/dist/components/ui/toggle-group/toggle-group.js.map +0 -1
- package/dist/components/ui/tooltip/tooltip.js +0 -49
- package/dist/components/ui/tooltip/tooltip.js.map +0 -1
- package/dist/components/ui/widget-placeholder/widget-placeholder.js +0 -106
- package/dist/components/ui/widget-placeholder/widget-placeholder.js.map +0 -1
- package/dist/index.d.ts +0 -2
- package/dist/index.js +0 -360
- package/dist/index.js.map +0 -1
- package/dist/lib/utils.js +0 -9
- package/dist/lib/utils.js.map +0 -1
- package/dist/node_modules/.pnpm/@tanstack_react-table@8.21.3_react-dom@19.2.6_react@19.2.6__react@19.2.6/node_modules/@tanstack/react-table/build/lib/index.js +0 -104
- package/dist/node_modules/.pnpm/@tanstack_react-table@8.21.3_react-dom@19.2.6_react@19.2.6__react@19.2.6/node_modules/@tanstack/react-table/build/lib/index.js.map +0 -1
- package/dist/node_modules/.pnpm/@tanstack_table-core@8.21.3/node_modules/@tanstack/table-core/build/lib/index.js +0 -1900
- package/dist/node_modules/.pnpm/@tanstack_table-core@8.21.3/node_modules/@tanstack/table-core/build/lib/index.js.map +0 -1
- package/dist/node_modules/.pnpm/class-variance-authority@0.7.1/node_modules/class-variance-authority/dist/index.js +0 -36
- package/dist/node_modules/.pnpm/class-variance-authority@0.7.1/node_modules/class-variance-authority/dist/index.js.map +0 -1
- package/dist/node_modules/.pnpm/clsx@2.1.1/node_modules/clsx/dist/clsx.js +0 -17
- package/dist/node_modules/.pnpm/clsx@2.1.1/node_modules/clsx/dist/clsx.js.map +0 -1
- package/dist/node_modules/.pnpm/react-resizable-panels@4.11.2_react-dom@19.2.6_react@19.2.6__react@19.2.6/node_modules/react-resizable-panels/dist/react-resizable-panels.js +0 -2093
- package/dist/node_modules/.pnpm/react-resizable-panels@4.11.2_react-dom@19.2.6_react@19.2.6__react@19.2.6/node_modules/react-resizable-panels/dist/react-resizable-panels.js.map +0 -1
- package/dist/node_modules/.pnpm/tailwind-merge@3.6.0/node_modules/tailwind-merge/dist/bundle-mjs.js +0 -2996
- package/dist/node_modules/.pnpm/tailwind-merge@3.6.0/node_modules/tailwind-merge/dist/bundle-mjs.js.map +0 -1
- package/dist/react.d.ts +0 -2
- package/dist/react.js +0 -360
- package/dist/react.js.map +0 -1
- package/dist/src/components/ui/accordion/accordion.d.ts +0 -7
- package/dist/src/components/ui/accordion/index.d.ts +0 -1
- package/dist/src/components/ui/alert/alert.d.ts +0 -14
- package/dist/src/components/ui/alert/index.d.ts +0 -2
- package/dist/src/components/ui/app-shell/app-shell.d.ts +0 -8
- package/dist/src/components/ui/app-shell/index.d.ts +0 -1
- package/dist/src/components/ui/auth-layout/auth-layout.d.ts +0 -6
- package/dist/src/components/ui/auth-layout/index.d.ts +0 -1
- package/dist/src/components/ui/avatar/avatar.d.ts +0 -27
- package/dist/src/components/ui/avatar/index.d.ts +0 -1
- package/dist/src/components/ui/breadcrumb/breadcrumb.d.ts +0 -30
- package/dist/src/components/ui/breadcrumb/index.d.ts +0 -1
- package/dist/src/components/ui/button/button.d.ts +0 -16
- package/dist/src/components/ui/button/index.d.ts +0 -1
- package/dist/src/components/ui/button-icon/button-icon.d.ts +0 -20
- package/dist/src/components/ui/button-icon/index.d.ts +0 -1
- package/dist/src/components/ui/button-menu/button-menu.d.ts +0 -29
- package/dist/src/components/ui/button-menu/index.d.ts +0 -1
- package/dist/src/components/ui/card/card.d.ts +0 -17
- package/dist/src/components/ui/card/index.d.ts +0 -1
- package/dist/src/components/ui/card-filter/card-filter.d.ts +0 -27
- package/dist/src/components/ui/card-filter/index.d.ts +0 -1
- package/dist/src/components/ui/chart/chart.d.ts +0 -55
- package/dist/src/components/ui/chart/index.d.ts +0 -2
- package/dist/src/components/ui/checkbox/checkbox.d.ts +0 -10
- package/dist/src/components/ui/checkbox/index.d.ts +0 -1
- package/dist/src/components/ui/chip/chip.d.ts +0 -20
- package/dist/src/components/ui/chip/index.d.ts +0 -1
- package/dist/src/components/ui/collapsible/collapsible.d.ts +0 -5
- package/dist/src/components/ui/collapsible/index.d.ts +0 -1
- package/dist/src/components/ui/combobox/combobox.d.ts +0 -28
- package/dist/src/components/ui/combobox/index.d.ts +0 -2
- package/dist/src/components/ui/data-table/data-table-column-header.d.ts +0 -8
- package/dist/src/components/ui/data-table/data-table-pagination.d.ts +0 -8
- package/dist/src/components/ui/data-table/data-table-toolbar.d.ts +0 -9
- package/dist/src/components/ui/data-table/data-table-view-options.d.ts +0 -6
- package/dist/src/components/ui/data-table/data-table.d.ts +0 -24
- package/dist/src/components/ui/data-table/data-table.docs.d.ts +0 -22
- package/dist/src/components/ui/data-table/index.d.ts +0 -5
- package/dist/src/components/ui/description-list/description-list.d.ts +0 -8
- package/dist/src/components/ui/description-list/index.d.ts +0 -1
- package/dist/src/components/ui/dialog/dialog.d.ts +0 -39
- package/dist/src/components/ui/dialog/dialog.docs.d.ts +0 -24
- package/dist/src/components/ui/dialog/index.d.ts +0 -1
- package/dist/src/components/ui/dropdown-menu/dropdown-menu.d.ts +0 -39
- package/dist/src/components/ui/dropdown-menu/dropdown-menu.docs.d.ts +0 -25
- package/dist/src/components/ui/dropdown-menu/index.d.ts +0 -1
- package/dist/src/components/ui/empty/empty.d.ts +0 -9
- package/dist/src/components/ui/empty/index.d.ts +0 -1
- package/dist/src/components/ui/field/field.d.ts +0 -39
- package/dist/src/components/ui/field/field.docs.d.ts +0 -27
- package/dist/src/components/ui/field/index.d.ts +0 -2
- package/dist/src/components/ui/form/form.d.ts +0 -6
- package/dist/src/components/ui/form/index.d.ts +0 -1
- package/dist/src/components/ui/grid/grid.d.ts +0 -15
- package/dist/src/components/ui/grid/index.d.ts +0 -1
- package/dist/src/components/ui/input/index.d.ts +0 -1
- package/dist/src/components/ui/input/input.d.ts +0 -4
- package/dist/src/components/ui/input-date-picker/index.d.ts +0 -1
- package/dist/src/components/ui/input-date-picker/input-date-picker.d.ts +0 -27
- package/dist/src/components/ui/input-search/index.d.ts +0 -1
- package/dist/src/components/ui/input-search/input-search.d.ts +0 -10
- package/dist/src/components/ui/input-select/index.d.ts +0 -1
- package/dist/src/components/ui/input-select/input-select.d.ts +0 -46
- package/dist/src/components/ui/input-text/index.d.ts +0 -1
- package/dist/src/components/ui/input-text/input-text.d.ts +0 -20
- package/dist/src/components/ui/input-text-area/index.d.ts +0 -1
- package/dist/src/components/ui/input-text-area/input-text-area.d.ts +0 -16
- package/dist/src/components/ui/label/index.d.ts +0 -1
- package/dist/src/components/ui/label/label.d.ts +0 -5
- package/dist/src/components/ui/label/label.docs.d.ts +0 -10
- package/dist/src/components/ui/link/index.d.ts +0 -1
- package/dist/src/components/ui/link/link.d.ts +0 -15
- package/dist/src/components/ui/number-field/index.d.ts +0 -1
- package/dist/src/components/ui/number-field/number-field.d.ts +0 -7
- package/dist/src/components/ui/page-content/index.d.ts +0 -1
- package/dist/src/components/ui/page-content/page-content.d.ts +0 -4
- package/dist/src/components/ui/page-header/index.d.ts +0 -1
- package/dist/src/components/ui/page-header/page-header.d.ts +0 -8
- package/dist/src/components/ui/pagination/index.d.ts +0 -2
- package/dist/src/components/ui/pagination/pagination.d.ts +0 -25
- package/dist/src/components/ui/popover/index.d.ts +0 -1
- package/dist/src/components/ui/popover/popover.d.ts +0 -27
- package/dist/src/components/ui/popover/popover.docs.d.ts +0 -25
- package/dist/src/components/ui/progress/index.d.ts +0 -1
- package/dist/src/components/ui/progress/progress.d.ts +0 -9
- package/dist/src/components/ui/progress/progress.docs.d.ts +0 -16
- package/dist/src/components/ui/progress-circle/index.d.ts +0 -1
- package/dist/src/components/ui/progress-circle/progress-circle.d.ts +0 -47
- package/dist/src/components/ui/progress-circle/progress-circle.docs.d.ts +0 -21
- package/dist/src/components/ui/radio/index.d.ts +0 -1
- package/dist/src/components/ui/radio/radio.d.ts +0 -8
- package/dist/src/components/ui/resizable/index.d.ts +0 -1
- package/dist/src/components/ui/resizable/resizable.d.ts +0 -9
- package/dist/src/components/ui/scroll-area/index.d.ts +0 -1
- package/dist/src/components/ui/scroll-area/scroll-area.d.ts +0 -10
- package/dist/src/components/ui/search/index.d.ts +0 -1
- package/dist/src/components/ui/search/search.d.ts +0 -7
- package/dist/src/components/ui/search-global/index.d.ts +0 -1
- package/dist/src/components/ui/search-global/search-global.d.ts +0 -7
- package/dist/src/components/ui/section/index.d.ts +0 -1
- package/dist/src/components/ui/section/section.d.ts +0 -7
- package/dist/src/components/ui/select/index.d.ts +0 -1
- package/dist/src/components/ui/select/select.d.ts +0 -1
- package/dist/src/components/ui/separator/index.d.ts +0 -1
- package/dist/src/components/ui/separator/separator.d.ts +0 -3
- package/dist/src/components/ui/sheet/index.d.ts +0 -3
- package/dist/src/components/ui/sheet/sheet-details.d.ts +0 -42
- package/dist/src/components/ui/sheet/sheet.d.ts +0 -36
- package/dist/src/components/ui/sheet/sheet.docs.d.ts +0 -21
- package/dist/src/components/ui/sidebar-primary/index.d.ts +0 -1
- package/dist/src/components/ui/sidebar-primary/sidebar-primary.d.ts +0 -54
- package/dist/src/components/ui/sidebar-secondary/index.d.ts +0 -1
- package/dist/src/components/ui/sidebar-secondary/sidebar-secondary.d.ts +0 -112
- package/dist/src/components/ui/skeleton/index.d.ts +0 -1
- package/dist/src/components/ui/skeleton/skeleton.d.ts +0 -4
- package/dist/src/components/ui/slider/index.d.ts +0 -1
- package/dist/src/components/ui/slider/slider.d.ts +0 -7
- package/dist/src/components/ui/spinner/index.d.ts +0 -1
- package/dist/src/components/ui/spinner/spinner.d.ts +0 -9
- package/dist/src/components/ui/stack/index.d.ts +0 -1
- package/dist/src/components/ui/stack/stack.d.ts +0 -13
- package/dist/src/components/ui/switch/index.d.ts +0 -1
- package/dist/src/components/ui/switch/switch.d.ts +0 -8
- package/dist/src/components/ui/table/index.d.ts +0 -1
- package/dist/src/components/ui/table/table.d.ts +0 -23
- package/dist/src/components/ui/tabs/index.d.ts +0 -1
- package/dist/src/components/ui/tabs/tabs.d.ts +0 -6
- package/dist/src/components/ui/tabs/tabs.docs.d.ts +0 -25
- package/dist/src/components/ui/tag/index.d.ts +0 -1
- package/dist/src/components/ui/tag/tag.d.ts +0 -12
- package/dist/src/components/ui/toast/index.d.ts +0 -1
- package/dist/src/components/ui/toast/toast.d.ts +0 -48
- package/dist/src/components/ui/toast/toast.docs.d.ts +0 -12
- package/dist/src/components/ui/toggle-group/index.d.ts +0 -1
- package/dist/src/components/ui/toggle-group/toggle-group.d.ts +0 -7
- package/dist/src/components/ui/tooltip/index.d.ts +0 -1
- package/dist/src/components/ui/tooltip/tooltip.d.ts +0 -13
- package/dist/src/components/ui/widget-placeholder/index.d.ts +0 -1
- package/dist/src/components/ui/widget-placeholder/widget-placeholder.d.ts +0 -18
- package/dist/src/components/ui/widget-placeholder/widget-placeholder.docs.d.ts +0 -14
- package/dist/src/index.d.ts +0 -66
- package/dist/src/lib/utils.d.ts +0 -2
- package/dist/src/react.d.ts +0 -1
- package/dist/styles.d.ts +0 -1
- package/dist/ui-react.css +0 -1
|
@@ -1,61 +0,0 @@
|
|
|
1
|
-
import { jsx as i } from "react/jsx-runtime";
|
|
2
|
-
import * as a from "react";
|
|
3
|
-
import { NumberField as t } from "@base-ui/react/number-field";
|
|
4
|
-
import { MinusIcon as n, PlusIcon as u } from "@acronis-platform/icons-react/stroke-mono";
|
|
5
|
-
import { cn as l } from "../../../lib/utils.js";
|
|
6
|
-
const g = t.Root, b = a.forwardRef(({ className: e, ...r }, o) => /* @__PURE__ */ i(
|
|
7
|
-
t.Group,
|
|
8
|
-
{
|
|
9
|
-
ref: o,
|
|
10
|
-
className: l(
|
|
11
|
-
"flex h-[var(--ui-input-text-global-box-height)] w-full min-w-0 items-stretch overflow-hidden rounded-[var(--ui-input-text-global-box-border-radius)] border bg-[var(--ui-input-text-global-box-color-idle)] border-[var(--ui-input-text-normal-box-border-color-idle)] transition-colors",
|
|
12
|
-
"not-has-disabled:hover:border-[var(--ui-input-text-normal-box-border-color-hover)]",
|
|
13
|
-
"has-[input:focus-visible]:border-[var(--ui-input-text-normal-box-border-color-hover)] has-[input:focus-visible]:ring-[3px] has-[input:focus-visible]:ring-[var(--ui-focus-primary)]",
|
|
14
|
-
"has-disabled:cursor-not-allowed has-disabled:border-[var(--ui-input-text-normal-box-border-color-disabled)] has-disabled:bg-[var(--ui-input-text-global-box-color-disabled)]",
|
|
15
|
-
"has-[input[aria-invalid=true]]:border-[var(--ui-input-text-error-msg-box-border-color-idle)] has-[input[aria-invalid=true]:focus-visible]:ring-[var(--ui-focus-error)]",
|
|
16
|
-
e
|
|
17
|
-
),
|
|
18
|
-
...r
|
|
19
|
-
}
|
|
20
|
-
));
|
|
21
|
-
b.displayName = "NumberFieldGroup";
|
|
22
|
-
const c = a.forwardRef(({ className: e, ...r }, o) => /* @__PURE__ */ i(
|
|
23
|
-
t.Input,
|
|
24
|
-
{
|
|
25
|
-
ref: o,
|
|
26
|
-
className: l(
|
|
27
|
-
"min-w-0 flex-1 bg-transparent px-[var(--ui-input-text-global-box-padding-x)] text-center text-sm leading-6 text-[var(--ui-input-text-global-value-color-idle)] outline-none placeholder:text-[var(--ui-input-text-global-placeholder-color-idle)] disabled:cursor-not-allowed disabled:text-[var(--ui-input-text-global-value-color-disabled)]",
|
|
28
|
-
e
|
|
29
|
-
),
|
|
30
|
-
...r
|
|
31
|
-
}
|
|
32
|
-
));
|
|
33
|
-
c.displayName = "NumberFieldInput";
|
|
34
|
-
const s = "flex w-9 shrink-0 cursor-pointer items-center justify-center text-[var(--ui-text-on-surface-secondary)] transition-colors not-disabled:hover:bg-[var(--ui-background-surface-hover)] not-disabled:hover:text-[var(--ui-text-on-surface-primary)] disabled:cursor-not-allowed disabled:text-[var(--ui-text-on-surface-disabled)]", m = a.forwardRef(({ className: e, children: r, ...o }, d) => /* @__PURE__ */ i(
|
|
35
|
-
t.Decrement,
|
|
36
|
-
{
|
|
37
|
-
ref: d,
|
|
38
|
-
className: l(s, e),
|
|
39
|
-
...o,
|
|
40
|
-
children: r ?? /* @__PURE__ */ i(n, { size: 16 })
|
|
41
|
-
}
|
|
42
|
-
));
|
|
43
|
-
m.displayName = "NumberFieldDecrement";
|
|
44
|
-
const p = a.forwardRef(({ className: e, children: r, ...o }, d) => /* @__PURE__ */ i(
|
|
45
|
-
t.Increment,
|
|
46
|
-
{
|
|
47
|
-
ref: d,
|
|
48
|
-
className: l(s, e),
|
|
49
|
-
...o,
|
|
50
|
-
children: r ?? /* @__PURE__ */ i(u, { size: 16 })
|
|
51
|
-
}
|
|
52
|
-
));
|
|
53
|
-
p.displayName = "NumberFieldIncrement";
|
|
54
|
-
export {
|
|
55
|
-
g as NumberField,
|
|
56
|
-
m as NumberFieldDecrement,
|
|
57
|
-
b as NumberFieldGroup,
|
|
58
|
-
p as NumberFieldIncrement,
|
|
59
|
-
c as NumberFieldInput
|
|
60
|
-
};
|
|
61
|
-
//# sourceMappingURL=number-field.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"number-field.js","sources":["../../../../src/components/ui/number-field/number-field.tsx"],"sourcesContent":["'use client';\n\nimport * as React from 'react';\nimport { NumberField as NumberFieldPrimitive } from '@base-ui/react/number-field';\nimport { MinusIcon, PlusIcon } from '@acronis-platform/icons-react/stroke-mono';\n\nimport { cn } from '@/lib/utils';\n\n// Ported from `@acronis-platform`'s `number-field`, on Base UI's NumberField\n// (Root / Group / Decrement / Input / Increment). No `--ui-number-field-*` tier —\n// the box reuses the `--ui-input-text-*` tier (already imported) so it matches\n// InputBox / InputText; the steppers use the muted/primary surface + text tokens.\n\nconst NumberField = NumberFieldPrimitive.Root;\n\n// The bordered box wrapping the steppers + input. Mirrors the InputBox field box\n// (height / radius / border / bg / hover / focus-within ring / disabled / invalid).\nconst NumberFieldGroup = React.forwardRef<\n React.ElementRef<typeof NumberFieldPrimitive.Group>,\n React.ComponentPropsWithoutRef<typeof NumberFieldPrimitive.Group>\n>(({ className, ...props }, ref) => (\n <NumberFieldPrimitive.Group\n ref={ref}\n className={cn(\n 'flex h-[var(--ui-input-text-global-box-height)] w-full min-w-0 items-stretch overflow-hidden rounded-[var(--ui-input-text-global-box-border-radius)] border bg-[var(--ui-input-text-global-box-color-idle)] border-[var(--ui-input-text-normal-box-border-color-idle)] transition-colors',\n 'not-has-disabled:hover:border-[var(--ui-input-text-normal-box-border-color-hover)]',\n 'has-[input:focus-visible]:border-[var(--ui-input-text-normal-box-border-color-hover)] has-[input:focus-visible]:ring-[3px] has-[input:focus-visible]:ring-[var(--ui-focus-primary)]',\n 'has-disabled:cursor-not-allowed has-disabled:border-[var(--ui-input-text-normal-box-border-color-disabled)] has-disabled:bg-[var(--ui-input-text-global-box-color-disabled)]',\n 'has-[input[aria-invalid=true]]:border-[var(--ui-input-text-error-msg-box-border-color-idle)] has-[input[aria-invalid=true]:focus-visible]:ring-[var(--ui-focus-error)]',\n className\n )}\n {...props}\n />\n));\nNumberFieldGroup.displayName = 'NumberFieldGroup';\n\nconst NumberFieldInput = React.forwardRef<\n React.ElementRef<typeof NumberFieldPrimitive.Input>,\n React.ComponentPropsWithoutRef<typeof NumberFieldPrimitive.Input>\n>(({ className, ...props }, ref) => (\n <NumberFieldPrimitive.Input\n ref={ref}\n className={cn(\n 'min-w-0 flex-1 bg-transparent px-[var(--ui-input-text-global-box-padding-x)] text-center text-sm leading-6 text-[var(--ui-input-text-global-value-color-idle)] outline-none placeholder:text-[var(--ui-input-text-global-placeholder-color-idle)] disabled:cursor-not-allowed disabled:text-[var(--ui-input-text-global-value-color-disabled)]',\n className\n )}\n {...props}\n />\n));\nNumberFieldInput.displayName = 'NumberFieldInput';\n\nconst stepperClassName =\n 'flex w-9 shrink-0 cursor-pointer items-center justify-center text-[var(--ui-text-on-surface-secondary)] transition-colors not-disabled:hover:bg-[var(--ui-background-surface-hover)] not-disabled:hover:text-[var(--ui-text-on-surface-primary)] disabled:cursor-not-allowed disabled:text-[var(--ui-text-on-surface-disabled)]';\n\nconst NumberFieldDecrement = React.forwardRef<\n React.ElementRef<typeof NumberFieldPrimitive.Decrement>,\n React.ComponentPropsWithoutRef<typeof NumberFieldPrimitive.Decrement>\n>(({ className, children, ...props }, ref) => (\n <NumberFieldPrimitive.Decrement\n ref={ref}\n className={cn(stepperClassName, className)}\n {...props}\n >\n {children ?? <MinusIcon size={16} />}\n </NumberFieldPrimitive.Decrement>\n));\nNumberFieldDecrement.displayName = 'NumberFieldDecrement';\n\nconst NumberFieldIncrement = React.forwardRef<\n React.ElementRef<typeof NumberFieldPrimitive.Increment>,\n React.ComponentPropsWithoutRef<typeof NumberFieldPrimitive.Increment>\n>(({ className, children, ...props }, ref) => (\n <NumberFieldPrimitive.Increment\n ref={ref}\n className={cn(stepperClassName, className)}\n {...props}\n >\n {children ?? <PlusIcon size={16} />}\n </NumberFieldPrimitive.Increment>\n));\nNumberFieldIncrement.displayName = 'NumberFieldIncrement';\n\nexport {\n NumberField,\n NumberFieldGroup,\n NumberFieldInput,\n NumberFieldDecrement,\n NumberFieldIncrement,\n};\n"],"names":["NumberField","NumberFieldPrimitive","NumberFieldGroup","React","className","props","ref","jsx","cn","NumberFieldInput","stepperClassName","NumberFieldDecrement","children","MinusIcon","NumberFieldIncrement","PlusIcon"],"mappings":";;;;;AAaA,MAAMA,IAAcC,EAAqB,MAInCC,IAAmBC,EAAM,WAG7B,CAAC,EAAE,WAAAC,GAAW,GAAGC,EAAA,GAASC,MAC1B,gBAAAC;AAAA,EAACN,EAAqB;AAAA,EAArB;AAAA,IACC,KAAAK;AAAA,IACA,WAAWE;AAAA,MACT;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACAJ;AAAA,IAAA;AAAA,IAED,GAAGC;AAAA,EAAA;AACN,CACD;AACDH,EAAiB,cAAc;AAE/B,MAAMO,IAAmBN,EAAM,WAG7B,CAAC,EAAE,WAAAC,GAAW,GAAGC,EAAA,GAASC,MAC1B,gBAAAC;AAAA,EAACN,EAAqB;AAAA,EAArB;AAAA,IACC,KAAAK;AAAA,IACA,WAAWE;AAAA,MACT;AAAA,MACAJ;AAAA,IAAA;AAAA,IAED,GAAGC;AAAA,EAAA;AACN,CACD;AACDI,EAAiB,cAAc;AAE/B,MAAMC,IACJ,mUAEIC,IAAuBR,EAAM,WAGjC,CAAC,EAAE,WAAAC,GAAW,UAAAQ,GAAU,GAAGP,KAASC,MACpC,gBAAAC;AAAA,EAACN,EAAqB;AAAA,EAArB;AAAA,IACC,KAAAK;AAAA,IACA,WAAWE,EAAGE,GAAkBN,CAAS;AAAA,IACxC,GAAGC;AAAA,IAEH,UAAAO,KAAY,gBAAAL,EAACM,GAAA,EAAU,MAAM,GAAA,CAAI;AAAA,EAAA;AACpC,CACD;AACDF,EAAqB,cAAc;AAEnC,MAAMG,IAAuBX,EAAM,WAGjC,CAAC,EAAE,WAAAC,GAAW,UAAAQ,GAAU,GAAGP,KAASC,MACpC,gBAAAC;AAAA,EAACN,EAAqB;AAAA,EAArB;AAAA,IACC,KAAAK;AAAA,IACA,WAAWE,EAAGE,GAAkBN,CAAS;AAAA,IACxC,GAAGC;AAAA,IAEH,UAAAO,KAAY,gBAAAL,EAACQ,GAAA,EAAS,MAAM,GAAA,CAAI;AAAA,EAAA;AACnC,CACD;AACDD,EAAqB,cAAc;"}
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
import { jsx as e } from "react/jsx-runtime";
|
|
2
|
-
import * as r from "react";
|
|
3
|
-
import { cn as m } from "../../../lib/utils.js";
|
|
4
|
-
const n = r.forwardRef(
|
|
5
|
-
({ className: t, ...o }, a) => /* @__PURE__ */ e(
|
|
6
|
-
"div",
|
|
7
|
-
{
|
|
8
|
-
ref: a,
|
|
9
|
-
"data-slot": "page-content",
|
|
10
|
-
className: m("flex-1 p-6", t),
|
|
11
|
-
...o
|
|
12
|
-
}
|
|
13
|
-
)
|
|
14
|
-
);
|
|
15
|
-
n.displayName = "PageContent";
|
|
16
|
-
export {
|
|
17
|
-
n as PageContent
|
|
18
|
-
};
|
|
19
|
-
//# sourceMappingURL=page-content.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"page-content.js","sources":["../../../../src/components/ui/page-content/page-content.tsx"],"sourcesContent":["import * as React from 'react';\n\nimport { cn } from '@/lib/utils';\n\n// The page content region — the padded gutter for a page's body. Ported from\n// `@acronis-platform`'s `page-content`. Rendered as a `<div>` (not `<main>`) so it\n// nests inside `AppShellMain` without duplicating the `main` landmark; if used\n// standalone, wrap it in your own `<main>`. Layout-only (flex-1 + page padding).\nexport type PageContentProps = React.HTMLAttributes<HTMLDivElement>;\n\nconst PageContent = React.forwardRef<HTMLDivElement, PageContentProps>(\n ({ className, ...props }, ref) => (\n <div\n ref={ref}\n data-slot=\"page-content\"\n className={cn('flex-1 p-6', className)}\n {...props}\n />\n )\n);\nPageContent.displayName = 'PageContent';\n\nexport { PageContent };\n"],"names":["PageContent","React","className","props","ref","jsx","cn"],"mappings":";;;AAUA,MAAMA,IAAcC,EAAM;AAAA,EACxB,CAAC,EAAE,WAAAC,GAAW,GAAGC,EAAA,GAASC,MACxB,gBAAAC;AAAA,IAAC;AAAA,IAAA;AAAA,MACC,KAAAD;AAAA,MACA,aAAU;AAAA,MACV,WAAWE,EAAG,cAAcJ,CAAS;AAAA,MACpC,GAAGC;AAAA,IAAA;AAAA,EAAA;AAGV;AACAH,EAAY,cAAc;"}
|
|
@@ -1,74 +0,0 @@
|
|
|
1
|
-
import { jsx as t } from "react/jsx-runtime";
|
|
2
|
-
import * as d from "react";
|
|
3
|
-
import { cn as s } from "../../../lib/utils.js";
|
|
4
|
-
const o = d.forwardRef(({ className: e, ...a }, r) => /* @__PURE__ */ t(
|
|
5
|
-
"div",
|
|
6
|
-
{
|
|
7
|
-
ref: r,
|
|
8
|
-
"data-slot": "page-header",
|
|
9
|
-
role: "banner",
|
|
10
|
-
className: s("flex flex-col gap-2 pb-4", e),
|
|
11
|
-
...a
|
|
12
|
-
}
|
|
13
|
-
));
|
|
14
|
-
o.displayName = "PageHeader";
|
|
15
|
-
const i = d.forwardRef(({ className: e, ...a }, r) => /* @__PURE__ */ t(
|
|
16
|
-
"nav",
|
|
17
|
-
{
|
|
18
|
-
ref: r,
|
|
19
|
-
"data-slot": "page-header-breadcrumb",
|
|
20
|
-
"aria-label": "Breadcrumb",
|
|
21
|
-
className: s("text-sm text-muted-foreground", e),
|
|
22
|
-
...a
|
|
23
|
-
}
|
|
24
|
-
));
|
|
25
|
-
i.displayName = "PageHeaderBreadcrumb";
|
|
26
|
-
const l = d.forwardRef(({ className: e, ...a }, r) => /* @__PURE__ */ t(
|
|
27
|
-
"div",
|
|
28
|
-
{
|
|
29
|
-
ref: r,
|
|
30
|
-
"data-slot": "page-header-row",
|
|
31
|
-
className: s("flex items-center justify-between gap-4", e),
|
|
32
|
-
...a
|
|
33
|
-
}
|
|
34
|
-
));
|
|
35
|
-
l.displayName = "PageHeaderRow";
|
|
36
|
-
const m = d.forwardRef(({ className: e, ...a }, r) => /* @__PURE__ */ t(
|
|
37
|
-
"h1",
|
|
38
|
-
{
|
|
39
|
-
ref: r,
|
|
40
|
-
"data-slot": "page-header-title",
|
|
41
|
-
className: s("text-lg font-semibold leading-tight tracking-tight", e),
|
|
42
|
-
...a
|
|
43
|
-
}
|
|
44
|
-
));
|
|
45
|
-
m.displayName = "PageHeaderTitle";
|
|
46
|
-
const c = d.forwardRef(({ className: e, ...a }, r) => /* @__PURE__ */ t(
|
|
47
|
-
"p",
|
|
48
|
-
{
|
|
49
|
-
ref: r,
|
|
50
|
-
"data-slot": "page-header-description",
|
|
51
|
-
className: s("text-sm text-muted-foreground", e),
|
|
52
|
-
...a
|
|
53
|
-
}
|
|
54
|
-
));
|
|
55
|
-
c.displayName = "PageHeaderDescription";
|
|
56
|
-
const g = d.forwardRef(({ className: e, ...a }, r) => /* @__PURE__ */ t(
|
|
57
|
-
"div",
|
|
58
|
-
{
|
|
59
|
-
ref: r,
|
|
60
|
-
"data-slot": "page-header-actions",
|
|
61
|
-
className: s("flex shrink-0 items-center gap-2", e),
|
|
62
|
-
...a
|
|
63
|
-
}
|
|
64
|
-
));
|
|
65
|
-
g.displayName = "PageHeaderActions";
|
|
66
|
-
export {
|
|
67
|
-
o as PageHeader,
|
|
68
|
-
g as PageHeaderActions,
|
|
69
|
-
i as PageHeaderBreadcrumb,
|
|
70
|
-
c as PageHeaderDescription,
|
|
71
|
-
l as PageHeaderRow,
|
|
72
|
-
m as PageHeaderTitle
|
|
73
|
-
};
|
|
74
|
-
//# sourceMappingURL=page-header.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"page-header.js","sources":["../../../../src/components/ui/page-header/page-header.tsx"],"sourcesContent":["import * as React from 'react';\n\nimport { cn } from '@/lib/utils';\n\n// The page header region from the Figma (shadcn-uikit node 2850-701): an optional\n// breadcrumb, a title row (title left, actions right), and an optional description.\n// Ported from `@acronis-platform`'s `page-header` and reconciled with the Figma —\n// the title is a moderate page title (not the legacy 2xl). Markup-only; the only\n// color is the muted breadcrumb/description (text-muted-foreground →\n// --ui-text-on-surface-secondary).\n\nconst PageHeader = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes<HTMLDivElement>\n>(({ className, ...props }, ref) => (\n <div\n ref={ref}\n data-slot=\"page-header\"\n role=\"banner\"\n className={cn('flex flex-col gap-2 pb-4', className)}\n {...props}\n />\n));\nPageHeader.displayName = 'PageHeader';\n\nconst PageHeaderBreadcrumb = React.forwardRef<\n HTMLElement,\n React.HTMLAttributes<HTMLElement>\n>(({ className, ...props }, ref) => (\n <nav\n ref={ref}\n data-slot=\"page-header-breadcrumb\"\n aria-label=\"Breadcrumb\"\n className={cn('text-sm text-muted-foreground', className)}\n {...props}\n />\n));\nPageHeaderBreadcrumb.displayName = 'PageHeaderBreadcrumb';\n\n// The title + actions row: title on the left, actions pushed to the right.\nconst PageHeaderRow = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes<HTMLDivElement>\n>(({ className, ...props }, ref) => (\n <div\n ref={ref}\n data-slot=\"page-header-row\"\n className={cn('flex items-center justify-between gap-4', className)}\n {...props}\n />\n));\nPageHeaderRow.displayName = 'PageHeaderRow';\n\nconst PageHeaderTitle = React.forwardRef<\n HTMLHeadingElement,\n React.HTMLAttributes<HTMLHeadingElement>\n>(({ className, ...props }, ref) => (\n <h1\n ref={ref}\n data-slot=\"page-header-title\"\n className={cn('text-lg font-semibold leading-tight tracking-tight', className)}\n {...props}\n />\n));\nPageHeaderTitle.displayName = 'PageHeaderTitle';\n\nconst PageHeaderDescription = React.forwardRef<\n HTMLParagraphElement,\n React.HTMLAttributes<HTMLParagraphElement>\n>(({ className, ...props }, ref) => (\n <p\n ref={ref}\n data-slot=\"page-header-description\"\n className={cn('text-sm text-muted-foreground', className)}\n {...props}\n />\n));\nPageHeaderDescription.displayName = 'PageHeaderDescription';\n\nconst PageHeaderActions = React.forwardRef<\n HTMLDivElement,\n React.HTMLAttributes<HTMLDivElement>\n>(({ className, ...props }, ref) => (\n <div\n ref={ref}\n data-slot=\"page-header-actions\"\n className={cn('flex shrink-0 items-center gap-2', className)}\n {...props}\n />\n));\nPageHeaderActions.displayName = 'PageHeaderActions';\n\nexport {\n PageHeader,\n PageHeaderBreadcrumb,\n PageHeaderRow,\n PageHeaderTitle,\n PageHeaderDescription,\n PageHeaderActions,\n};\n"],"names":["PageHeader","React","className","props","ref","jsx","cn","PageHeaderBreadcrumb","PageHeaderRow","PageHeaderTitle","PageHeaderDescription","PageHeaderActions"],"mappings":";;;AAWA,MAAMA,IAAaC,EAAM,WAGvB,CAAC,EAAE,WAAAC,GAAW,GAAGC,EAAA,GAASC,MAC1B,gBAAAC;AAAA,EAAC;AAAA,EAAA;AAAA,IACC,KAAAD;AAAA,IACA,aAAU;AAAA,IACV,MAAK;AAAA,IACL,WAAWE,EAAG,4BAA4BJ,CAAS;AAAA,IAClD,GAAGC;AAAA,EAAA;AACN,CACD;AACDH,EAAW,cAAc;AAEzB,MAAMO,IAAuBN,EAAM,WAGjC,CAAC,EAAE,WAAAC,GAAW,GAAGC,EAAA,GAASC,MAC1B,gBAAAC;AAAA,EAAC;AAAA,EAAA;AAAA,IACC,KAAAD;AAAA,IACA,aAAU;AAAA,IACV,cAAW;AAAA,IACX,WAAWE,EAAG,iCAAiCJ,CAAS;AAAA,IACvD,GAAGC;AAAA,EAAA;AACN,CACD;AACDI,EAAqB,cAAc;AAGnC,MAAMC,IAAgBP,EAAM,WAG1B,CAAC,EAAE,WAAAC,GAAW,GAAGC,EAAA,GAASC,MAC1B,gBAAAC;AAAA,EAAC;AAAA,EAAA;AAAA,IACC,KAAAD;AAAA,IACA,aAAU;AAAA,IACV,WAAWE,EAAG,2CAA2CJ,CAAS;AAAA,IACjE,GAAGC;AAAA,EAAA;AACN,CACD;AACDK,EAAc,cAAc;AAE5B,MAAMC,IAAkBR,EAAM,WAG5B,CAAC,EAAE,WAAAC,GAAW,GAAGC,EAAA,GAASC,MAC1B,gBAAAC;AAAA,EAAC;AAAA,EAAA;AAAA,IACC,KAAAD;AAAA,IACA,aAAU;AAAA,IACV,WAAWE,EAAG,sDAAsDJ,CAAS;AAAA,IAC5E,GAAGC;AAAA,EAAA;AACN,CACD;AACDM,EAAgB,cAAc;AAE9B,MAAMC,IAAwBT,EAAM,WAGlC,CAAC,EAAE,WAAAC,GAAW,GAAGC,EAAA,GAASC,MAC1B,gBAAAC;AAAA,EAAC;AAAA,EAAA;AAAA,IACC,KAAAD;AAAA,IACA,aAAU;AAAA,IACV,WAAWE,EAAG,iCAAiCJ,CAAS;AAAA,IACvD,GAAGC;AAAA,EAAA;AACN,CACD;AACDO,EAAsB,cAAc;AAEpC,MAAMC,IAAoBV,EAAM,WAG9B,CAAC,EAAE,WAAAC,GAAW,GAAGC,EAAA,GAASC,MAC1B,gBAAAC;AAAA,EAAC;AAAA,EAAA;AAAA,IACC,KAAAD;AAAA,IACA,aAAU;AAAA,IACV,WAAWE,EAAG,oCAAoCJ,CAAS;AAAA,IAC1D,GAAGC;AAAA,EAAA;AACN,CACD;AACDQ,EAAkB,cAAc;"}
|
|
@@ -1,87 +0,0 @@
|
|
|
1
|
-
import { jsx as e, jsxs as s } from "react/jsx-runtime";
|
|
2
|
-
import * as r from "react";
|
|
3
|
-
import { EllipsisIcon as l, ChevronRightIcon as c, ChevronLeftIcon as m } from "@acronis-platform/icons-react/stroke-mono";
|
|
4
|
-
import { cn as t } from "../../../lib/utils.js";
|
|
5
|
-
function y({ className: a, ...i }) {
|
|
6
|
-
return /* @__PURE__ */ e(
|
|
7
|
-
"nav",
|
|
8
|
-
{
|
|
9
|
-
role: "navigation",
|
|
10
|
-
"aria-label": "pagination",
|
|
11
|
-
className: t("mx-auto flex w-full justify-center", a),
|
|
12
|
-
...i
|
|
13
|
-
}
|
|
14
|
-
);
|
|
15
|
-
}
|
|
16
|
-
const u = r.forwardRef(({ className: a, ...i }, n) => /* @__PURE__ */ e(
|
|
17
|
-
"ul",
|
|
18
|
-
{
|
|
19
|
-
ref: n,
|
|
20
|
-
className: t("flex flex-row items-center gap-1", a),
|
|
21
|
-
...i
|
|
22
|
-
}
|
|
23
|
-
));
|
|
24
|
-
u.displayName = "PaginationContent";
|
|
25
|
-
const g = r.forwardRef(({ className: a, ...i }, n) => /* @__PURE__ */ e("li", { ref: n, className: a, ...i }));
|
|
26
|
-
g.displayName = "PaginationItem";
|
|
27
|
-
const f = (a) => t(
|
|
28
|
-
"inline-flex h-8 min-w-8 select-none items-center justify-center rounded-md px-2 text-sm font-medium text-[var(--ui-text-on-surface-primary)] transition-colors outline-none",
|
|
29
|
-
"focus-visible:ring-2 focus-visible:ring-[var(--ui-focus-primary)]",
|
|
30
|
-
a ? "bg-[var(--ui-background-surface-active)]" : "hover:bg-[var(--ui-background-surface-hover)]"
|
|
31
|
-
), o = ({
|
|
32
|
-
className: a,
|
|
33
|
-
isActive: i,
|
|
34
|
-
...n
|
|
35
|
-
}) => /* @__PURE__ */ e(
|
|
36
|
-
"a",
|
|
37
|
-
{
|
|
38
|
-
"aria-current": i ? "page" : void 0,
|
|
39
|
-
className: t(f(i), a),
|
|
40
|
-
...n
|
|
41
|
-
}
|
|
42
|
-
);
|
|
43
|
-
o.displayName = "PaginationLink";
|
|
44
|
-
const p = ({
|
|
45
|
-
className: a,
|
|
46
|
-
...i
|
|
47
|
-
}) => /* @__PURE__ */ e(
|
|
48
|
-
o,
|
|
49
|
-
{
|
|
50
|
-
"aria-label": "Go to previous page",
|
|
51
|
-
className: a,
|
|
52
|
-
...i,
|
|
53
|
-
children: /* @__PURE__ */ e(m, { size: 16 })
|
|
54
|
-
}
|
|
55
|
-
);
|
|
56
|
-
p.displayName = "PaginationPrevious";
|
|
57
|
-
const d = ({ className: a, ...i }) => /* @__PURE__ */ e(o, { "aria-label": "Go to next page", className: a, ...i, children: /* @__PURE__ */ e(c, { size: 16 }) });
|
|
58
|
-
d.displayName = "PaginationNext";
|
|
59
|
-
const x = ({
|
|
60
|
-
className: a,
|
|
61
|
-
...i
|
|
62
|
-
}) => /* @__PURE__ */ s(
|
|
63
|
-
"span",
|
|
64
|
-
{
|
|
65
|
-
"aria-hidden": !0,
|
|
66
|
-
className: t(
|
|
67
|
-
"flex h-8 w-8 items-center justify-center text-[var(--ui-text-on-surface-secondary)]",
|
|
68
|
-
a
|
|
69
|
-
),
|
|
70
|
-
...i,
|
|
71
|
-
children: [
|
|
72
|
-
/* @__PURE__ */ e(l, { size: 16 }),
|
|
73
|
-
/* @__PURE__ */ e("span", { className: "sr-only", children: "More pages" })
|
|
74
|
-
]
|
|
75
|
-
}
|
|
76
|
-
);
|
|
77
|
-
x.displayName = "PaginationEllipsis";
|
|
78
|
-
export {
|
|
79
|
-
y as Pagination,
|
|
80
|
-
u as PaginationContent,
|
|
81
|
-
x as PaginationEllipsis,
|
|
82
|
-
g as PaginationItem,
|
|
83
|
-
o as PaginationLink,
|
|
84
|
-
d as PaginationNext,
|
|
85
|
-
p as PaginationPrevious
|
|
86
|
-
};
|
|
87
|
-
//# sourceMappingURL=pagination.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"pagination.js","sources":["../../../../src/components/ui/pagination/pagination.tsx"],"sourcesContent":["import * as React from 'react';\nimport {\n ChevronLeftIcon,\n ChevronRightIcon,\n EllipsisIcon,\n} from '@acronis-platform/icons-react/stroke-mono';\n\nimport { cn } from '@/lib/utils';\n\n// Ported from `@acronis-platform`'s `pagination`. Markup-only (no Base UI\n// primitive). The page links are styled directly with semantic tokens (rather than\n// the Button cva, whose min-width tokens don't fit a compact square link): neutral\n// foreground page numbers, the active surface for the current page, and the hover\n// surface on hover.\nfunction Pagination({ className, ...props }: React.ComponentProps<'nav'>) {\n return (\n <nav\n role=\"navigation\"\n aria-label=\"pagination\"\n className={cn('mx-auto flex w-full justify-center', className)}\n {...props}\n />\n );\n}\n\nconst PaginationContent = React.forwardRef<\n HTMLUListElement,\n React.ComponentProps<'ul'>\n>(({ className, ...props }, ref) => (\n <ul\n ref={ref}\n className={cn('flex flex-row items-center gap-1', className)}\n {...props}\n />\n));\nPaginationContent.displayName = 'PaginationContent';\n\nconst PaginationItem = React.forwardRef<\n HTMLLIElement,\n React.ComponentProps<'li'>\n>(({ className, ...props }, ref) => <li ref={ref} className={className} {...props} />);\nPaginationItem.displayName = 'PaginationItem';\n\nexport interface PaginationLinkProps extends React.ComponentProps<'a'> {\n /** Marks the current page (sets aria-current and the selected treatment). */\n isActive?: boolean;\n}\n\nconst paginationLinkClassName = (isActive?: boolean) =>\n cn(\n 'inline-flex h-8 min-w-8 select-none items-center justify-center rounded-md px-2 text-sm font-medium text-[var(--ui-text-on-surface-primary)] transition-colors outline-none',\n 'focus-visible:ring-2 focus-visible:ring-[var(--ui-focus-primary)]',\n isActive\n ? 'bg-[var(--ui-background-surface-active)]'\n : 'hover:bg-[var(--ui-background-surface-hover)]'\n );\n\nconst PaginationLink = ({\n className,\n isActive,\n ...props\n}: PaginationLinkProps) => (\n <a\n aria-current={isActive ? 'page' : undefined}\n className={cn(paginationLinkClassName(isActive), className)}\n {...props}\n />\n);\nPaginationLink.displayName = 'PaginationLink';\n\nconst PaginationPrevious = ({\n className,\n ...props\n}: PaginationLinkProps) => (\n <PaginationLink\n aria-label=\"Go to previous page\"\n className={className}\n {...props}\n >\n <ChevronLeftIcon size={16} />\n </PaginationLink>\n);\nPaginationPrevious.displayName = 'PaginationPrevious';\n\nconst PaginationNext = ({ className, ...props }: PaginationLinkProps) => (\n <PaginationLink aria-label=\"Go to next page\" className={className} {...props}>\n <ChevronRightIcon size={16} />\n </PaginationLink>\n);\nPaginationNext.displayName = 'PaginationNext';\n\nconst PaginationEllipsis = ({\n className,\n ...props\n}: React.ComponentProps<'span'>) => (\n <span\n aria-hidden\n className={cn(\n 'flex h-8 w-8 items-center justify-center text-[var(--ui-text-on-surface-secondary)]',\n className\n )}\n {...props}\n >\n <EllipsisIcon size={16} />\n <span className=\"sr-only\">More pages</span>\n </span>\n);\nPaginationEllipsis.displayName = 'PaginationEllipsis';\n\nexport {\n Pagination,\n PaginationContent,\n PaginationItem,\n PaginationLink,\n PaginationPrevious,\n PaginationNext,\n PaginationEllipsis,\n};\n"],"names":["Pagination","className","props","jsx","cn","PaginationContent","React","ref","PaginationItem","paginationLinkClassName","isActive","PaginationLink","PaginationPrevious","ChevronLeftIcon","PaginationNext","ChevronRightIcon","PaginationEllipsis","jsxs","EllipsisIcon"],"mappings":";;;;AAcA,SAASA,EAAW,EAAE,WAAAC,GAAW,GAAGC,KAAsC;AACxE,SACE,gBAAAC;AAAA,IAAC;AAAA,IAAA;AAAA,MACC,MAAK;AAAA,MACL,cAAW;AAAA,MACX,WAAWC,EAAG,sCAAsCH,CAAS;AAAA,MAC5D,GAAGC;AAAA,IAAA;AAAA,EAAA;AAGV;AAEA,MAAMG,IAAoBC,EAAM,WAG9B,CAAC,EAAE,WAAAL,GAAW,GAAGC,EAAA,GAASK,MAC1B,gBAAAJ;AAAA,EAAC;AAAA,EAAA;AAAA,IACC,KAAAI;AAAA,IACA,WAAWH,EAAG,oCAAoCH,CAAS;AAAA,IAC1D,GAAGC;AAAA,EAAA;AACN,CACD;AACDG,EAAkB,cAAc;AAEhC,MAAMG,IAAiBF,EAAM,WAG3B,CAAC,EAAE,WAAAL,GAAW,GAAGC,EAAA,GAASK,wBAAS,MAAA,EAAG,KAAAA,GAAU,WAAAN,GAAuB,GAAGC,GAAO,CAAE;AACrFM,EAAe,cAAc;AAO7B,MAAMC,IAA0B,CAACC,MAC/BN;AAAA,EACE;AAAA,EACA;AAAA,EACAM,IACI,6CACA;AACN,GAEIC,IAAiB,CAAC;AAAA,EACtB,WAAAV;AAAA,EACA,UAAAS;AAAA,EACA,GAAGR;AACL,MACE,gBAAAC;AAAA,EAAC;AAAA,EAAA;AAAA,IACC,gBAAcO,IAAW,SAAS;AAAA,IAClC,WAAWN,EAAGK,EAAwBC,CAAQ,GAAGT,CAAS;AAAA,IACzD,GAAGC;AAAA,EAAA;AACN;AAEFS,EAAe,cAAc;AAE7B,MAAMC,IAAqB,CAAC;AAAA,EAC1B,WAAAX;AAAA,EACA,GAAGC;AACL,MACE,gBAAAC;AAAA,EAACQ;AAAA,EAAA;AAAA,IACC,cAAW;AAAA,IACX,WAAAV;AAAA,IACC,GAAGC;AAAA,IAEJ,UAAA,gBAAAC,EAACU,GAAA,EAAgB,MAAM,GAAA,CAAI;AAAA,EAAA;AAC7B;AAEFD,EAAmB,cAAc;AAEjC,MAAME,IAAiB,CAAC,EAAE,WAAAb,GAAW,GAAGC,EAAA,MACtC,gBAAAC,EAACQ,GAAA,EAAe,cAAW,mBAAkB,WAAAV,GAAuB,GAAGC,GACrE,4BAACa,GAAA,EAAiB,MAAM,IAAI,EAAA,CAC9B;AAEFD,EAAe,cAAc;AAE7B,MAAME,IAAqB,CAAC;AAAA,EAC1B,WAAAf;AAAA,EACA,GAAGC;AACL,MACE,gBAAAe;AAAA,EAAC;AAAA,EAAA;AAAA,IACC,eAAW;AAAA,IACX,WAAWb;AAAA,MACT;AAAA,MACAH;AAAA,IAAA;AAAA,IAED,GAAGC;AAAA,IAEJ,UAAA;AAAA,MAAA,gBAAAC,EAACe,GAAA,EAAa,MAAM,GAAA,CAAI;AAAA,MACxB,gBAAAf,EAAC,QAAA,EAAK,WAAU,WAAU,UAAA,aAAA,CAAU;AAAA,IAAA;AAAA,EAAA;AACtC;AAEFa,EAAmB,cAAc;"}
|
|
@@ -1,48 +0,0 @@
|
|
|
1
|
-
import { jsx as t } from "react/jsx-runtime";
|
|
2
|
-
import * as c from "react";
|
|
3
|
-
import { Popover as o } from "@base-ui/react/popover";
|
|
4
|
-
import { cn as f } from "../../../lib/utils.js";
|
|
5
|
-
const v = o.Root, h = o.Trigger, w = o.Portal, P = c.forwardRef(
|
|
6
|
-
({
|
|
7
|
-
className: r,
|
|
8
|
-
side: a = "bottom",
|
|
9
|
-
align: d = "center",
|
|
10
|
-
sideOffset: n = 4,
|
|
11
|
-
portal: i = !0,
|
|
12
|
-
portalContainer: s,
|
|
13
|
-
keepMounted: m,
|
|
14
|
-
...p
|
|
15
|
-
}, l) => {
|
|
16
|
-
const e = /* @__PURE__ */ t(
|
|
17
|
-
o.Positioner,
|
|
18
|
-
{
|
|
19
|
-
side: a,
|
|
20
|
-
align: d,
|
|
21
|
-
sideOffset: n,
|
|
22
|
-
className: "z-50",
|
|
23
|
-
children: /* @__PURE__ */ t(
|
|
24
|
-
o.Popup,
|
|
25
|
-
{
|
|
26
|
-
ref: l,
|
|
27
|
-
className: f(
|
|
28
|
-
"w-72 rounded-md border border-border bg-background p-4 text-foreground shadow-md outline-none",
|
|
29
|
-
"duration-200 data-[open]:animate-in data-[closed]:animate-out data-[open]:fade-in-0 data-[closed]:fade-out-0 data-[open]:zoom-in-95 data-[closed]:zoom-out-95",
|
|
30
|
-
"data-[side=bottom]:slide-in-from-top-2 data-[side=top]:slide-in-from-bottom-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2",
|
|
31
|
-
r
|
|
32
|
-
),
|
|
33
|
-
...p
|
|
34
|
-
}
|
|
35
|
-
)
|
|
36
|
-
}
|
|
37
|
-
);
|
|
38
|
-
return i ? /* @__PURE__ */ t(o.Portal, { container: s, keepMounted: m, children: e }) : e;
|
|
39
|
-
}
|
|
40
|
-
);
|
|
41
|
-
P.displayName = "PopoverContent";
|
|
42
|
-
export {
|
|
43
|
-
v as Popover,
|
|
44
|
-
P as PopoverContent,
|
|
45
|
-
w as PopoverPortal,
|
|
46
|
-
h as PopoverTrigger
|
|
47
|
-
};
|
|
48
|
-
//# sourceMappingURL=popover.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"popover.js","sources":["../../../../src/components/ui/popover/popover.tsx"],"sourcesContent":["import * as React from 'react';\nimport { Popover as PopoverPrimitive } from '@base-ui/react/popover';\n\nimport { cn } from '@/lib/utils';\n\n// Ported from `@acronis-platform/shadcn-uikit`'s `popover`\n// (packages/ui-legacy/src/components/ui/popover.tsx). A floating panel anchored\n// to a trigger, built on the Base UI Popover primitive (positioning, focus\n// management, outside-press / Esc dismissal, ARIA come from Base UI). No\n// `--ui-popover-*` token tier exists yet, so this design-pending v1 themes from\n// the shared semantic tokens:\n// • surface -> bg-background (--ui-background-surface-primary) (legacy `bg-popover`)\n// • text -> text-foreground (--ui-text-on-surface-primary) (legacy `text-popover-foreground`)\n// • border -> border-border (--ui-border-on-surface-border) (legacy bare `border`)\n// Enter/exit animations use `tw-animate-css` keyed to Base UI's data-[open] /\n// data-[closed] / data-[side] attributes. Reconcile (and a possible\n// `--ui-popover-*` tier) with `/figma-component Popover <url> --update`.\n\nconst Popover = PopoverPrimitive.Root;\n\nconst PopoverTrigger = PopoverPrimitive.Trigger;\n\nconst PopoverPortal = PopoverPrimitive.Portal;\n\nexport interface PopoverContentProps\n extends React.ComponentPropsWithoutRef<typeof PopoverPrimitive.Popup> {\n /** Which side of the trigger to render on. */\n side?: PopoverPrimitive.Positioner.Props['side'];\n /** Alignment along the chosen side. */\n align?: PopoverPrimitive.Positioner.Props['align'];\n /** Distance in px from the trigger. */\n sideOffset?: number;\n /**\n * Render inside a portal (default `true`). Set `false` for inline usage\n * (e.g. when supplying your own `PopoverPortal`).\n */\n portal?: boolean;\n /**\n * Portal container. Pass a shadow-root mount for isolated-style previews\n * (the docs demos do this via `useShadowMount`).\n */\n portalContainer?: PopoverPrimitive.Portal.Props['container'];\n /** Keep the content mounted while closed (Base UI `Portal` prop). */\n keepMounted?: PopoverPrimitive.Portal.Props['keepMounted'];\n}\n\nconst PopoverContent = React.forwardRef<\n React.ElementRef<typeof PopoverPrimitive.Popup>,\n PopoverContentProps\n>(\n (\n {\n className,\n side = 'bottom',\n align = 'center',\n sideOffset = 4,\n portal = true,\n portalContainer,\n keepMounted,\n ...props\n },\n ref\n ) => {\n const positioner = (\n <PopoverPrimitive.Positioner\n side={side}\n align={align}\n sideOffset={sideOffset}\n className=\"z-50\"\n >\n <PopoverPrimitive.Popup\n ref={ref}\n className={cn(\n 'w-72 rounded-md border border-border bg-background p-4 text-foreground shadow-md outline-none',\n 'duration-200 data-[open]:animate-in data-[closed]:animate-out data-[open]:fade-in-0 data-[closed]:fade-out-0 data-[open]:zoom-in-95 data-[closed]:zoom-out-95',\n 'data-[side=bottom]:slide-in-from-top-2 data-[side=top]:slide-in-from-bottom-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2',\n className\n )}\n {...props}\n />\n </PopoverPrimitive.Positioner>\n );\n\n return portal ? (\n <PopoverPrimitive.Portal container={portalContainer} keepMounted={keepMounted}>\n {positioner}\n </PopoverPrimitive.Portal>\n ) : (\n positioner\n );\n }\n);\nPopoverContent.displayName = 'PopoverContent';\n\nexport { Popover, PopoverTrigger, PopoverPortal, PopoverContent };\n"],"names":["Popover","PopoverPrimitive","PopoverTrigger","PopoverPortal","PopoverContent","React","className","side","align","sideOffset","portal","portalContainer","keepMounted","props","ref","positioner","jsx","cn"],"mappings":";;;;AAkBA,MAAMA,IAAUC,EAAiB,MAE3BC,IAAiBD,EAAiB,SAElCE,IAAgBF,EAAiB,QAwBjCG,IAAiBC,EAAM;AAAA,EAI3B,CACE;AAAA,IACE,WAAAC;AAAA,IACA,MAAAC,IAAO;AAAA,IACP,OAAAC,IAAQ;AAAA,IACR,YAAAC,IAAa;AAAA,IACb,QAAAC,IAAS;AAAA,IACT,iBAAAC;AAAA,IACA,aAAAC;AAAA,IACA,GAAGC;AAAA,EAAA,GAELC,MACG;AACH,UAAMC,IACJ,gBAAAC;AAAA,MAACf,EAAiB;AAAA,MAAjB;AAAA,QACC,MAAAM;AAAA,QACA,OAAAC;AAAA,QACA,YAAAC;AAAA,QACA,WAAU;AAAA,QAEV,UAAA,gBAAAO;AAAA,UAACf,EAAiB;AAAA,UAAjB;AAAA,YACC,KAAAa;AAAA,YACA,WAAWG;AAAA,cACT;AAAA,cACA;AAAA,cACA;AAAA,cACAX;AAAA,YAAA;AAAA,YAED,GAAGO;AAAA,UAAA;AAAA,QAAA;AAAA,MACN;AAAA,IAAA;AAIJ,WAAOH,sBACJT,EAAiB,QAAjB,EAAwB,WAAWU,GAAiB,aAAAC,GAClD,UAAAG,EAAA,CACH,IAEAA;AAAA,EAEJ;AACF;AACAX,EAAe,cAAc;"}
|
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
import { jsx as e } from "react/jsx-runtime";
|
|
2
|
-
import * as i from "react";
|
|
3
|
-
import { Progress as r } from "@base-ui/react";
|
|
4
|
-
import { cn as n } from "../../../lib/utils.js";
|
|
5
|
-
const s = i.forwardRef(
|
|
6
|
-
({ className: o, value: a, ...l }, t) => /* @__PURE__ */ e(
|
|
7
|
-
r.Root,
|
|
8
|
-
{
|
|
9
|
-
ref: t,
|
|
10
|
-
value: a ?? null,
|
|
11
|
-
className: n(
|
|
12
|
-
"relative h-2 w-full overflow-hidden rounded-full",
|
|
13
|
-
o
|
|
14
|
-
),
|
|
15
|
-
...l,
|
|
16
|
-
children: /* @__PURE__ */ e(r.Track, { className: "relative h-full w-full overflow-hidden bg-input", children: /* @__PURE__ */ e(
|
|
17
|
-
r.Indicator,
|
|
18
|
-
{
|
|
19
|
-
className: "h-full bg-secondary transition-all data-[indeterminate]:animate-indeterminate-progress data-[indeterminate]:transition-none",
|
|
20
|
-
style: a == null ? { width: "33%" } : void 0
|
|
21
|
-
}
|
|
22
|
-
) })
|
|
23
|
-
}
|
|
24
|
-
)
|
|
25
|
-
);
|
|
26
|
-
s.displayName = "Progress";
|
|
27
|
-
export {
|
|
28
|
-
s as Progress
|
|
29
|
-
};
|
|
30
|
-
//# sourceMappingURL=progress.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"progress.js","sources":["../../../../src/components/ui/progress/progress.tsx"],"sourcesContent":["'use client';\n\nimport * as React from 'react';\nimport { Progress as ProgressPrimitive } from '@base-ui/react';\n\nimport { cn } from '@/lib/utils';\n\n// Ported from `@acronis-platform/shadcn-uikit`'s `progress`\n// (packages/ui-legacy/src/components/ui/progress.tsx). Wraps Base UI's Progress\n// primitive (Root → Track → Indicator). No `--ui-progress-*` tier yet: the\n// track uses the shared border token via `bg-input`, and the filled indicator\n// uses the brand action blue via `bg-secondary` (--ui-background-brand-secondary,\n// the same remap Spinner uses — ui-react's `primary` is the dark navy, not the\n// action color legacy's `bg-primary` meant). When `value` is `null` the bar is\n// indeterminate: Base UI sets `data-indeterminate`, which swaps the determinate\n// width transition for the sliding `indeterminate-progress` keyframe (registered\n// in src/styles/index.css).\n// Base UI types `value` as required; we make it optional so `<Progress />`\n// renders an indeterminate bar (the `value ?? null` below normalizes it).\nexport type ProgressProps = Omit<\n React.ComponentPropsWithoutRef<typeof ProgressPrimitive.Root>,\n 'value'\n> & {\n value?: number | null;\n};\n\nconst Progress = React.forwardRef<HTMLDivElement, ProgressProps>(\n ({ className, value, ...props }, ref) => (\n <ProgressPrimitive.Root\n ref={ref}\n value={value ?? null}\n className={cn(\n 'relative h-2 w-full overflow-hidden rounded-full',\n className\n )}\n {...props}\n >\n <ProgressPrimitive.Track className=\"relative h-full w-full overflow-hidden bg-input\">\n <ProgressPrimitive.Indicator\n className=\"h-full bg-secondary transition-all data-[indeterminate]:animate-indeterminate-progress data-[indeterminate]:transition-none\"\n style={value == null ? { width: '33%' } : undefined}\n />\n </ProgressPrimitive.Track>\n </ProgressPrimitive.Root>\n )\n);\nProgress.displayName = 'Progress';\n\nexport { Progress };\n"],"names":["Progress","React","className","value","props","ref","jsx","ProgressPrimitive","cn"],"mappings":";;;;AA0BA,MAAMA,IAAWC,EAAM;AAAA,EACrB,CAAC,EAAE,WAAAC,GAAW,OAAAC,GAAO,GAAGC,EAAA,GAASC,MAC/B,gBAAAC;AAAA,IAACC,EAAkB;AAAA,IAAlB;AAAA,MACC,KAAAF;AAAA,MACA,OAAOF,KAAS;AAAA,MAChB,WAAWK;AAAA,QACT;AAAA,QACAN;AAAA,MAAA;AAAA,MAED,GAAGE;AAAA,MAEJ,UAAA,gBAAAE,EAACC,EAAkB,OAAlB,EAAwB,WAAU,mDACjC,UAAA,gBAAAD;AAAA,QAACC,EAAkB;AAAA,QAAlB;AAAA,UACC,WAAU;AAAA,UACV,OAAOJ,KAAS,OAAO,EAAE,OAAO,UAAU;AAAA,QAAA;AAAA,MAAA,EAC5C,CACF;AAAA,IAAA;AAAA,EAAA;AAGN;AACAH,EAAS,cAAc;"}
|
|
@@ -1,115 +0,0 @@
|
|
|
1
|
-
import { jsxs as x, jsx as e } from "react/jsx-runtime";
|
|
2
|
-
import * as I from "react";
|
|
3
|
-
import { Progress as M } from "@base-ui/react/progress";
|
|
4
|
-
import { CircleCheckIcon as R, TriangleWarningIcon as g, CircleTimesIcon as j } from "@acronis-platform/icons-react/stroke-mono";
|
|
5
|
-
import { cva as P } from "../../../node_modules/.pnpm/class-variance-authority@0.7.1/node_modules/class-variance-authority/dist/index.js";
|
|
6
|
-
import { cn as c } from "../../../lib/utils.js";
|
|
7
|
-
const S = {
|
|
8
|
-
tiny: { d: 16, stroke: 2, font: "text-[10px] leading-none" },
|
|
9
|
-
sm: { d: 24, stroke: 3, font: "text-[10px] leading-none" },
|
|
10
|
-
md: { d: 40, stroke: 4, font: "text-xs font-semibold" },
|
|
11
|
-
lg: { d: 64, stroke: 5, font: "text-sm font-semibold" }
|
|
12
|
-
}, T = {
|
|
13
|
-
brand: "stroke-[var(--ui-background-brand-secondary)]",
|
|
14
|
-
danger: "stroke-[var(--ui-text-on-status-danger)]",
|
|
15
|
-
critical: "stroke-[var(--ui-text-on-status-critical)]",
|
|
16
|
-
warning: "stroke-[var(--ui-text-on-status-warning)]",
|
|
17
|
-
success: "stroke-[var(--ui-text-on-status-success)]"
|
|
18
|
-
}, _ = {
|
|
19
|
-
danger: /* @__PURE__ */ e(j, { className: "text-[var(--ui-text-on-status-danger)]" }),
|
|
20
|
-
critical: /* @__PURE__ */ e(g, { className: "text-[var(--ui-text-on-status-critical)]" }),
|
|
21
|
-
warning: /* @__PURE__ */ e(g, { className: "text-[var(--ui-text-on-status-warning)]" }),
|
|
22
|
-
success: /* @__PURE__ */ e(R, { className: "text-[var(--ui-text-on-status-success)]" })
|
|
23
|
-
};
|
|
24
|
-
function O(s) {
|
|
25
|
-
return s >= 0.8 ? "success" : s >= 0.6 ? "warning" : s >= 0.4 ? "critical" : "danger";
|
|
26
|
-
}
|
|
27
|
-
const W = P(
|
|
28
|
-
"relative inline-flex shrink-0 items-center justify-center",
|
|
29
|
-
{
|
|
30
|
-
variants: {
|
|
31
|
-
size: { tiny: "", sm: "", md: "", lg: "" }
|
|
32
|
-
},
|
|
33
|
-
defaultVariants: { size: "sm" }
|
|
34
|
-
}
|
|
35
|
-
), $ = I.forwardRef(
|
|
36
|
-
({
|
|
37
|
-
className: s,
|
|
38
|
-
value: l = 0,
|
|
39
|
-
max: n = 100,
|
|
40
|
-
size: u = "sm",
|
|
41
|
-
status: h,
|
|
42
|
-
showValue: k = !1,
|
|
43
|
-
showIcon: v = !1,
|
|
44
|
-
children: p,
|
|
45
|
-
...N
|
|
46
|
-
}, y) => {
|
|
47
|
-
const { d: t, stroke: o, font: C } = S[u], w = n > 0 ? n : 100, a = Math.min(1, Math.max(0, l / w)), d = h ?? O(a), i = (t - o) / 2, f = 2 * Math.PI * i, r = t / 2, b = v ? _[d] : void 0, m = p ?? b ?? (k ? `${Math.round(a * 100)}%` : null);
|
|
48
|
-
return /* @__PURE__ */ x(
|
|
49
|
-
M.Root,
|
|
50
|
-
{
|
|
51
|
-
ref: y,
|
|
52
|
-
value: l,
|
|
53
|
-
max: n,
|
|
54
|
-
className: c(W({ size: u }), s),
|
|
55
|
-
style: { width: t, height: t },
|
|
56
|
-
...N,
|
|
57
|
-
children: [
|
|
58
|
-
/* @__PURE__ */ x(
|
|
59
|
-
"svg",
|
|
60
|
-
{
|
|
61
|
-
width: t,
|
|
62
|
-
height: t,
|
|
63
|
-
viewBox: `0 0 ${t} ${t}`,
|
|
64
|
-
className: "-rotate-90",
|
|
65
|
-
"aria-hidden": "true",
|
|
66
|
-
children: [
|
|
67
|
-
/* @__PURE__ */ e(
|
|
68
|
-
"circle",
|
|
69
|
-
{
|
|
70
|
-
className: "stroke-[var(--ui-border-on-surface-border)]",
|
|
71
|
-
fill: "none",
|
|
72
|
-
strokeWidth: o,
|
|
73
|
-
cx: r,
|
|
74
|
-
cy: r,
|
|
75
|
-
r: i
|
|
76
|
-
}
|
|
77
|
-
),
|
|
78
|
-
/* @__PURE__ */ e(
|
|
79
|
-
"circle",
|
|
80
|
-
{
|
|
81
|
-
className: c(T[d], "transition-[stroke-dashoffset]"),
|
|
82
|
-
fill: "none",
|
|
83
|
-
strokeWidth: o,
|
|
84
|
-
strokeLinecap: "round",
|
|
85
|
-
cx: r,
|
|
86
|
-
cy: r,
|
|
87
|
-
r: i,
|
|
88
|
-
strokeDasharray: f,
|
|
89
|
-
strokeDashoffset: f * (1 - a)
|
|
90
|
-
}
|
|
91
|
-
)
|
|
92
|
-
]
|
|
93
|
-
}
|
|
94
|
-
),
|
|
95
|
-
m != null && /* @__PURE__ */ e(
|
|
96
|
-
"span",
|
|
97
|
-
{
|
|
98
|
-
className: c(
|
|
99
|
-
"absolute inset-0 flex items-center justify-center text-foreground [&_svg]:size-[60%]",
|
|
100
|
-
C
|
|
101
|
-
),
|
|
102
|
-
children: m
|
|
103
|
-
}
|
|
104
|
-
)
|
|
105
|
-
]
|
|
106
|
-
}
|
|
107
|
-
);
|
|
108
|
-
}
|
|
109
|
-
);
|
|
110
|
-
$.displayName = "ProgressCircle";
|
|
111
|
-
export {
|
|
112
|
-
$ as ProgressCircle,
|
|
113
|
-
W as progressCircleVariants
|
|
114
|
-
};
|
|
115
|
-
//# sourceMappingURL=progress-circle.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"progress-circle.js","sources":["../../../../src/components/ui/progress-circle/progress-circle.tsx"],"sourcesContent":["'use client';\n\nimport * as React from 'react';\nimport { Progress as ProgressPrimitive } from '@base-ui/react/progress';\nimport {\n CircleCheckIcon,\n CircleTimesIcon,\n TriangleWarningIcon,\n} from '@acronis-platform/icons-react/stroke-mono';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { cn } from '@/lib/utils';\n\n// A circular (radial) progress indicator — an SVG ring whose arc fills with the\n// value and whose color tracks the level (danger → critical → warning →\n// success). Built from the Cyber-Compliance \"Compliance %\" design (node\n// 2396-186059) and the Vue kit's `AvProgressRadial`. The ring is wrapped in the\n// Base UI Progress primitive so it carries the proper `role=\"progressbar\"` +\n// `aria-valuenow/min/max`; the visuals are a hand-drawn SVG (Base UI's Track/\n// Indicator are linear-only). No `--ui-progress-circle-*` tier — the arc uses the\n// shared status colors (`--ui-text-on-status-*`), the track the border token, and\n// the center label the surface foreground.\n\n// `brand` is the neutral single-color mode (matches the linear Progress accent);\n// the others are score levels. With no `status`, the level is derived from the\n// value (like the Vue ProgressRadial).\nexport type ProgressCircleStatus =\n | 'brand'\n | 'danger'\n | 'critical'\n | 'warning'\n | 'success';\n\n// Size → [diameter px, stroke px, center font class]. The table cell uses the\n// smaller sizes; lg suits cards/widgets.\nconst SIZES = {\n tiny: { d: 16, stroke: 2, font: 'text-[10px] leading-none' },\n sm: { d: 24, stroke: 3, font: 'text-[10px] leading-none' },\n md: { d: 40, stroke: 4, font: 'text-xs font-semibold' },\n lg: { d: 64, stroke: 5, font: 'text-sm font-semibold' },\n} as const;\n\nexport type ProgressCircleSize = keyof typeof SIZES;\n\nconst ARC_COLOR: Record<ProgressCircleStatus, string> = {\n brand: 'stroke-[var(--ui-background-brand-secondary)]',\n danger: 'stroke-[var(--ui-text-on-status-danger)]',\n critical: 'stroke-[var(--ui-text-on-status-critical)]',\n warning: 'stroke-[var(--ui-text-on-status-warning)]',\n success: 'stroke-[var(--ui-text-on-status-success)]',\n};\n\n// `brand` has no score icon — only the level statuses do.\nconst ICON_BY_STATUS: Partial<Record<ProgressCircleStatus, React.ReactNode>> = {\n danger: <CircleTimesIcon className=\"text-[var(--ui-text-on-status-danger)]\" />,\n critical: (\n <TriangleWarningIcon className=\"text-[var(--ui-text-on-status-critical)]\" />\n ),\n warning: (\n <TriangleWarningIcon className=\"text-[var(--ui-text-on-status-warning)]\" />\n ),\n success: (\n <CircleCheckIcon className=\"text-[var(--ui-text-on-status-success)]\" />\n ),\n};\n\n// Default value → status thresholds (confirm exact breakpoints with design — the\n// Figma shows ~25% danger, 50% critical, 75% warning, 80%+ success).\nfunction statusForFraction(fraction: number): ProgressCircleStatus {\n if (fraction >= 0.8) return 'success';\n if (fraction >= 0.6) return 'warning';\n if (fraction >= 0.4) return 'critical';\n return 'danger';\n}\n\nconst progressCircleVariants = cva(\n 'relative inline-flex shrink-0 items-center justify-center',\n {\n variants: {\n size: { tiny: '', sm: '', md: '', lg: '' },\n },\n defaultVariants: { size: 'sm' },\n }\n);\n\nexport interface ProgressCircleProps\n extends Omit<React.HTMLAttributes<HTMLDivElement>, 'children'>,\n VariantProps<typeof progressCircleVariants> {\n /** Current progress; clamped to `[0, max]`. */\n value?: number;\n /** Value representing full completion. */\n max?: number;\n /** Ring diameter + stroke. Defaults to `sm`. */\n size?: ProgressCircleSize;\n /** Color level for the arc. Omit to derive from `value`/`max` by thresholds. */\n status?: ProgressCircleStatus;\n /** Show the rounded percentage in the center. */\n showValue?: boolean;\n /** Show a status icon in the center (takes priority over `showValue`). */\n showIcon?: boolean;\n /** Custom center content (takes priority over icon/value). */\n children?: React.ReactNode;\n}\n\nconst ProgressCircle = React.forwardRef<HTMLDivElement, ProgressCircleProps>(\n (\n {\n className,\n value = 0,\n max = 100,\n size = 'sm',\n status,\n showValue = false,\n showIcon = false,\n children,\n ...props\n },\n ref\n ) => {\n const { d, stroke, font } = SIZES[size];\n const safeMax = max > 0 ? max : 100;\n const fraction = Math.min(1, Math.max(0, value / safeMax));\n const level = status ?? statusForFraction(fraction);\n const radius = (d - stroke) / 2;\n const circumference = 2 * Math.PI * radius;\n const center = d / 2;\n const icon = showIcon ? ICON_BY_STATUS[level] : undefined;\n const centerContent =\n children ?? icon ?? (showValue ? `${Math.round(fraction * 100)}%` : null);\n\n return (\n <ProgressPrimitive.Root\n ref={ref}\n value={value}\n max={max}\n className={cn(progressCircleVariants({ size }), className)}\n style={{ width: d, height: d }}\n {...props}\n >\n <svg\n width={d}\n height={d}\n viewBox={`0 0 ${d} ${d}`}\n className=\"-rotate-90\"\n aria-hidden=\"true\"\n >\n <circle\n className=\"stroke-[var(--ui-border-on-surface-border)]\"\n fill=\"none\"\n strokeWidth={stroke}\n cx={center}\n cy={center}\n r={radius}\n />\n <circle\n className={cn(ARC_COLOR[level], 'transition-[stroke-dashoffset]')}\n fill=\"none\"\n strokeWidth={stroke}\n strokeLinecap=\"round\"\n cx={center}\n cy={center}\n r={radius}\n strokeDasharray={circumference}\n strokeDashoffset={circumference * (1 - fraction)}\n />\n </svg>\n {centerContent != null && (\n <span\n className={cn(\n 'absolute inset-0 flex items-center justify-center text-foreground [&_svg]:size-[60%]',\n font\n )}\n >\n {centerContent}\n </span>\n )}\n </ProgressPrimitive.Root>\n );\n }\n);\nProgressCircle.displayName = 'ProgressCircle';\n\nexport { ProgressCircle, progressCircleVariants };\n"],"names":["SIZES","ARC_COLOR","ICON_BY_STATUS","jsx","CircleTimesIcon","TriangleWarningIcon","CircleCheckIcon","statusForFraction","fraction","progressCircleVariants","cva","ProgressCircle","React","className","value","max","size","status","showValue","showIcon","children","props","ref","d","stroke","font","safeMax","level","radius","circumference","center","icon","centerContent","jsxs","ProgressPrimitive","cn"],"mappings":";;;;;;AAmCA,MAAMA,IAAQ;AAAA,EACZ,MAAM,EAAE,GAAG,IAAI,QAAQ,GAAG,MAAM,2BAAA;AAAA,EAChC,IAAI,EAAE,GAAG,IAAI,QAAQ,GAAG,MAAM,2BAAA;AAAA,EAC9B,IAAI,EAAE,GAAG,IAAI,QAAQ,GAAG,MAAM,wBAAA;AAAA,EAC9B,IAAI,EAAE,GAAG,IAAI,QAAQ,GAAG,MAAM,wBAAA;AAChC,GAIMC,IAAkD;AAAA,EACtD,OAAO;AAAA,EACP,QAAQ;AAAA,EACR,UAAU;AAAA,EACV,SAAS;AAAA,EACT,SAAS;AACX,GAGMC,IAAyE;AAAA,EAC7E,QAAQ,gBAAAC,EAACC,GAAA,EAAgB,WAAU,yCAAA,CAAyC;AAAA,EAC5E,UACE,gBAAAD,EAACE,GAAA,EAAoB,WAAU,2CAAA,CAA2C;AAAA,EAE5E,SACE,gBAAAF,EAACE,GAAA,EAAoB,WAAU,0CAAA,CAA0C;AAAA,EAE3E,SACE,gBAAAF,EAACG,GAAA,EAAgB,WAAU,0CAAA,CAA0C;AAEzE;AAIA,SAASC,EAAkBC,GAAwC;AACjE,SAAIA,KAAY,MAAY,YACxBA,KAAY,MAAY,YACxBA,KAAY,MAAY,aACrB;AACT;AAEA,MAAMC,IAAyBC;AAAA,EAC7B;AAAA,EACA;AAAA,IACE,UAAU;AAAA,MACR,MAAM,EAAE,MAAM,IAAI,IAAI,IAAI,IAAI,IAAI,IAAI,GAAA;AAAA,IAAG;AAAA,IAE3C,iBAAiB,EAAE,MAAM,KAAA;AAAA,EAAK;AAElC,GAqBMC,IAAiBC,EAAM;AAAA,EAC3B,CACE;AAAA,IACE,WAAAC;AAAA,IACA,OAAAC,IAAQ;AAAA,IACR,KAAAC,IAAM;AAAA,IACN,MAAAC,IAAO;AAAA,IACP,QAAAC;AAAA,IACA,WAAAC,IAAY;AAAA,IACZ,UAAAC,IAAW;AAAA,IACX,UAAAC;AAAA,IACA,GAAGC;AAAA,EAAA,GAELC,MACG;AACH,UAAM,EAAE,GAAAC,GAAG,QAAAC,GAAQ,MAAAC,EAAA,IAASzB,EAAMgB,CAAI,GAChCU,IAAUX,IAAM,IAAIA,IAAM,KAC1BP,IAAW,KAAK,IAAI,GAAG,KAAK,IAAI,GAAGM,IAAQY,CAAO,CAAC,GACnDC,IAAQV,KAAUV,EAAkBC,CAAQ,GAC5CoB,KAAUL,IAAIC,KAAU,GACxBK,IAAgB,IAAI,KAAK,KAAKD,GAC9BE,IAASP,IAAI,GACbQ,IAAOZ,IAAWjB,EAAeyB,CAAK,IAAI,QAC1CK,IACJZ,KAAYW,MAASb,IAAY,GAAG,KAAK,MAAMV,IAAW,GAAG,CAAC,MAAM;AAEtE,WACE,gBAAAyB;AAAA,MAACC,EAAkB;AAAA,MAAlB;AAAA,QACC,KAAAZ;AAAA,QACA,OAAAR;AAAA,QACA,KAAAC;AAAA,QACA,WAAWoB,EAAG1B,EAAuB,EAAE,MAAAO,EAAA,CAAM,GAAGH,CAAS;AAAA,QACzD,OAAO,EAAE,OAAOU,GAAG,QAAQA,EAAA;AAAA,QAC1B,GAAGF;AAAA,QAEJ,UAAA;AAAA,UAAA,gBAAAY;AAAA,YAAC;AAAA,YAAA;AAAA,cACC,OAAOV;AAAA,cACP,QAAQA;AAAA,cACR,SAAS,OAAOA,CAAC,IAAIA,CAAC;AAAA,cACtB,WAAU;AAAA,cACV,eAAY;AAAA,cAEZ,UAAA;AAAA,gBAAA,gBAAApB;AAAA,kBAAC;AAAA,kBAAA;AAAA,oBACC,WAAU;AAAA,oBACV,MAAK;AAAA,oBACL,aAAaqB;AAAA,oBACb,IAAIM;AAAA,oBACJ,IAAIA;AAAA,oBACJ,GAAGF;AAAA,kBAAA;AAAA,gBAAA;AAAA,gBAEL,gBAAAzB;AAAA,kBAAC;AAAA,kBAAA;AAAA,oBACC,WAAWgC,EAAGlC,EAAU0B,CAAK,GAAG,gCAAgC;AAAA,oBAChE,MAAK;AAAA,oBACL,aAAaH;AAAA,oBACb,eAAc;AAAA,oBACd,IAAIM;AAAA,oBACJ,IAAIA;AAAA,oBACJ,GAAGF;AAAA,oBACH,iBAAiBC;AAAA,oBACjB,kBAAkBA,KAAiB,IAAIrB;AAAA,kBAAA;AAAA,gBAAA;AAAA,cACzC;AAAA,YAAA;AAAA,UAAA;AAAA,UAEDwB,KAAiB,QAChB,gBAAA7B;AAAA,YAAC;AAAA,YAAA;AAAA,cACC,WAAWgC;AAAA,gBACT;AAAA,gBACAV;AAAA,cAAA;AAAA,cAGD,UAAAO;AAAA,YAAA;AAAA,UAAA;AAAA,QACH;AAAA,MAAA;AAAA,IAAA;AAAA,EAIR;AACF;AACArB,EAAe,cAAc;"}
|
|
@@ -1,44 +0,0 @@
|
|
|
1
|
-
import { jsx as e } from "react/jsx-runtime";
|
|
2
|
-
import * as i from "react";
|
|
3
|
-
import { Radio as r } from "@base-ui/react/radio";
|
|
4
|
-
import { RadioGroup as b } from "@base-ui/react/radio-group";
|
|
5
|
-
import { cn as c } from "../../../lib/utils.js";
|
|
6
|
-
const l = i.forwardRef(({ className: o, ...d }, a) => /* @__PURE__ */ e(
|
|
7
|
-
b,
|
|
8
|
-
{
|
|
9
|
-
ref: a,
|
|
10
|
-
className: c("flex flex-col gap-2", o),
|
|
11
|
-
...d
|
|
12
|
-
}
|
|
13
|
-
));
|
|
14
|
-
l.displayName = "RadioGroup";
|
|
15
|
-
const t = i.forwardRef(({ className: o, ...d }, a) => /* @__PURE__ */ e(
|
|
16
|
-
r.Root,
|
|
17
|
-
{
|
|
18
|
-
ref: a,
|
|
19
|
-
className: c(
|
|
20
|
-
// geometry + focus ring
|
|
21
|
-
"inline-flex size-[var(--ui-radio-global-box-size)] shrink-0 cursor-pointer items-center justify-center rounded-full border outline-none transition-colors focus-visible:ring-[3px] focus-visible:ring-[var(--ui-focus-primary)]",
|
|
22
|
-
// unchecked (base): idle / hover / active
|
|
23
|
-
"bg-[var(--ui-radio-unchecked-box-color-idle)] border-[var(--ui-radio-unchecked-box-border-color-idle)]",
|
|
24
|
-
"not-data-[disabled]:hover:bg-[var(--ui-radio-unchecked-box-color-hover)] not-data-[disabled]:hover:border-[var(--ui-radio-unchecked-box-border-color-hover)]",
|
|
25
|
-
"not-data-[disabled]:active:bg-[var(--ui-radio-unchecked-box-color-active)] not-data-[disabled]:active:border-[var(--ui-radio-unchecked-box-border-color-active)]",
|
|
26
|
-
// checked: idle / hover / active
|
|
27
|
-
"data-[checked]:not-data-[disabled]:bg-[var(--ui-radio-checked-box-color-idle)] data-[checked]:not-data-[disabled]:border-[var(--ui-radio-checked-box-border-color-idle)]",
|
|
28
|
-
"data-[checked]:not-data-[disabled]:hover:bg-[var(--ui-radio-checked-box-color-hover)] data-[checked]:not-data-[disabled]:hover:border-[var(--ui-radio-checked-box-border-color-hover)]",
|
|
29
|
-
"data-[checked]:not-data-[disabled]:active:bg-[var(--ui-radio-checked-box-color-active)] data-[checked]:not-data-[disabled]:active:border-[var(--ui-radio-checked-box-border-color-active)]",
|
|
30
|
-
// disabled (unchecked base + checked override)
|
|
31
|
-
"data-[disabled]:cursor-not-allowed data-[disabled]:bg-[var(--ui-radio-unchecked-box-color-disabled)] data-[disabled]:border-[var(--ui-radio-unchecked-box-border-color-disabled)]",
|
|
32
|
-
"data-[disabled]:data-[checked]:bg-[var(--ui-radio-checked-box-color-disabled)] data-[disabled]:data-[checked]:border-[var(--ui-radio-checked-box-border-color-disabled)]",
|
|
33
|
-
o
|
|
34
|
-
),
|
|
35
|
-
...d,
|
|
36
|
-
children: /* @__PURE__ */ e(r.Indicator, { className: "size-2 rounded-full bg-[var(--ui-radio-checked-icon-color-idle)] data-[disabled]:bg-[var(--ui-radio-checked-icon-color-disabled)]" })
|
|
37
|
-
}
|
|
38
|
-
));
|
|
39
|
-
t.displayName = "Radio";
|
|
40
|
-
export {
|
|
41
|
-
t as Radio,
|
|
42
|
-
l as RadioGroup
|
|
43
|
-
};
|
|
44
|
-
//# sourceMappingURL=radio.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"radio.js","sources":["../../../../src/components/ui/radio/radio.tsx"],"sourcesContent":["import * as React from 'react';\nimport { Radio as RadioPrimitive } from '@base-ui/react/radio';\nimport { RadioGroup as RadioGroupPrimitive } from '@base-ui/react/radio-group';\n\nimport { cn } from '@/lib/utils';\n\n// Radio group + item, wrapping Base UI's RadioGroup / Radio primitives. Radios\n// are mutually exclusive, so the group owns the selected value; each Radio takes\n// a `value`. Colors and geometry come from the dedicated next-gen `--ui-radio-*`\n// token tier from @acronis-platform/tokens-pd (which mirrors `--ui-checkbox-*`):\n// the circle has two logical states — `unchecked` (the base) and `checked` —\n// each with its own per-interaction (idle / hover / active / disabled) fill\n// (`*-box-color-*`) and border (`*-box-border-color-*`) tokens. `unchecked` is\n// the base layer (lowest specificity); `data-[checked]` overrides it, and\n// `data-[disabled]:data-[checked]` overrides that in turn. The inner dot fill\n// uses `--ui-radio-checked-icon-color-*`. Box geometry (16px size) comes from\n// `--ui-radio-global-box-size`; the focus ring uses `--ui-focus-primary`. Each\n// state is wired to its own token, and the checked overrides are scoped with\n// `not-data-[disabled]` so the disabled tokens win.\n\nexport type RadioGroupProps = React.ComponentPropsWithoutRef<\n typeof RadioGroupPrimitive\n>;\n\nconst RadioGroup = React.forwardRef<\n React.ElementRef<typeof RadioGroupPrimitive>,\n RadioGroupProps\n>(({ className, ...props }, ref) => (\n <RadioGroupPrimitive\n ref={ref}\n className={cn('flex flex-col gap-2', className)}\n {...props}\n />\n));\nRadioGroup.displayName = 'RadioGroup';\n\nexport type RadioProps = React.ComponentPropsWithoutRef<\n typeof RadioPrimitive.Root\n>;\n\nconst Radio = React.forwardRef<\n React.ElementRef<typeof RadioPrimitive.Root>,\n RadioProps\n>(({ className, ...props }, ref) => (\n <RadioPrimitive.Root\n ref={ref}\n className={cn(\n // geometry + focus ring\n 'inline-flex size-[var(--ui-radio-global-box-size)] shrink-0 cursor-pointer items-center justify-center rounded-full border outline-none transition-colors focus-visible:ring-[3px] focus-visible:ring-[var(--ui-focus-primary)]',\n // unchecked (base): idle / hover / active\n 'bg-[var(--ui-radio-unchecked-box-color-idle)] border-[var(--ui-radio-unchecked-box-border-color-idle)]',\n 'not-data-[disabled]:hover:bg-[var(--ui-radio-unchecked-box-color-hover)] not-data-[disabled]:hover:border-[var(--ui-radio-unchecked-box-border-color-hover)]',\n 'not-data-[disabled]:active:bg-[var(--ui-radio-unchecked-box-color-active)] not-data-[disabled]:active:border-[var(--ui-radio-unchecked-box-border-color-active)]',\n // checked: idle / hover / active\n 'data-[checked]:not-data-[disabled]:bg-[var(--ui-radio-checked-box-color-idle)] data-[checked]:not-data-[disabled]:border-[var(--ui-radio-checked-box-border-color-idle)]',\n 'data-[checked]:not-data-[disabled]:hover:bg-[var(--ui-radio-checked-box-color-hover)] data-[checked]:not-data-[disabled]:hover:border-[var(--ui-radio-checked-box-border-color-hover)]',\n 'data-[checked]:not-data-[disabled]:active:bg-[var(--ui-radio-checked-box-color-active)] data-[checked]:not-data-[disabled]:active:border-[var(--ui-radio-checked-box-border-color-active)]',\n // disabled (unchecked base + checked override)\n 'data-[disabled]:cursor-not-allowed data-[disabled]:bg-[var(--ui-radio-unchecked-box-color-disabled)] data-[disabled]:border-[var(--ui-radio-unchecked-box-border-color-disabled)]',\n 'data-[disabled]:data-[checked]:bg-[var(--ui-radio-checked-box-color-disabled)] data-[disabled]:data-[checked]:border-[var(--ui-radio-checked-box-border-color-disabled)]',\n className\n )}\n {...props}\n >\n <RadioPrimitive.Indicator className=\"size-2 rounded-full bg-[var(--ui-radio-checked-icon-color-idle)] data-[disabled]:bg-[var(--ui-radio-checked-icon-color-disabled)]\" />\n </RadioPrimitive.Root>\n));\nRadio.displayName = 'Radio';\n\nexport { RadioGroup, Radio };\n"],"names":["RadioGroup","React","className","props","ref","jsx","RadioGroupPrimitive","cn","Radio","RadioPrimitive"],"mappings":";;;;;AAwBA,MAAMA,IAAaC,EAAM,WAGvB,CAAC,EAAE,WAAAC,GAAW,GAAGC,EAAA,GAASC,MAC1B,gBAAAC;AAAA,EAACC;AAAAA,EAAA;AAAA,IACC,KAAAF;AAAA,IACA,WAAWG,EAAG,uBAAuBL,CAAS;AAAA,IAC7C,GAAGC;AAAA,EAAA;AACN,CACD;AACDH,EAAW,cAAc;AAMzB,MAAMQ,IAAQP,EAAM,WAGlB,CAAC,EAAE,WAAAC,GAAW,GAAGC,EAAA,GAASC,MAC1B,gBAAAC;AAAA,EAACI,EAAe;AAAA,EAAf;AAAA,IACC,KAAAL;AAAA,IACA,WAAWG;AAAA;AAAA,MAET;AAAA;AAAA,MAEA;AAAA,MACA;AAAA,MACA;AAAA;AAAA,MAEA;AAAA,MACA;AAAA,MACA;AAAA;AAAA,MAEA;AAAA,MACA;AAAA,MACAL;AAAA,IAAA;AAAA,IAED,GAAGC;AAAA,IAEJ,UAAA,gBAAAE,EAACI,EAAe,WAAf,EAAyB,WAAU,oIAAA,CAAoI;AAAA,EAAA;AAC1K,CACD;AACDD,EAAM,cAAc;"}
|