From c489fabb778efe9fe9ad61103b6776dc571e3e73 Mon Sep 17 00:00:00 2001 From: Edouard DUPIN Date: Fri, 24 Jan 2025 21:57:04 +0100 Subject: [PATCH] [theme and reciepice --- front/package.json | 2 - front/pnpm-lock.yaml | 36 - front/src/App.tsx | 4 +- front/src/components/TopBar/TopBar.tsx | 11 +- front/src/components/album/DisplayAlbum.tsx | 14 +- .../components/contextMenu/ContextMenu.tsx | 26 +- front/src/components/form/FormCovers.tsx | 6 +- front/src/components/popup/AlbumEditPopUp.tsx | 7 +- .../src/components/popup/ArtistEditPopUp.tsx | 4 +- .../src/components/select/SelectMultiple.tsx | 2 +- .../components/track/DisplayTrackSkeleton.tsx | 2 +- front/src/components/ui/avatar.tsx | 74 + front/src/components/ui/button.tsx | 40 + front/src/components/ui/checkbox.tsx | 25 + front/src/components/ui/color-mode.tsx | 62 +- front/src/components/ui/field.tsx | 33 + front/src/components/ui/input-group.tsx | 53 + front/src/components/ui/popover.tsx | 59 + front/src/components/ui/provider.tsx | 15 + front/src/components/ui/radio.tsx | 24 + front/src/components/ui/slider.tsx | 82 + front/src/components/ui/tooltip.tsx | 46 + front/src/errors/ErrorBoundary.tsx | 7 +- front/src/scene/album/AlbumsPage.tsx | 2 +- .../scene/artist/ArtistAlbumDetailPage.tsx | 1 - front/src/scene/artist/ArtistDetailPage.tsx | 2 +- front/src/scene/artist/ArtistsPage.tsx | 2 +- front/src/scene/gender/GendersPage.tsx | 2 +- front/src/scene/home/HomePage.tsx | 2 +- front/src/theme/config sample.ts | 10888 ++++++++++++++++ front/src/theme/foundations/colors.ts | 38 +- front/src/theme/foundations/shadows.ts | 30 +- front/src/theme/recipes/button.ts | 10 +- front/src/theme/recipes/index.ts | 2 +- front/src/theme/styleguide/colors.stories.tsx | 2 +- front/src/theme/styles.ts | 4 - front/src/theme/theme.ts | 129 +- 37 files changed, 11601 insertions(+), 147 deletions(-) create mode 100644 front/src/components/ui/avatar.tsx create mode 100644 front/src/components/ui/button.tsx create mode 100644 front/src/components/ui/checkbox.tsx create mode 100644 front/src/components/ui/field.tsx create mode 100644 front/src/components/ui/input-group.tsx create mode 100644 front/src/components/ui/popover.tsx create mode 100644 front/src/components/ui/provider.tsx create mode 100644 front/src/components/ui/radio.tsx create mode 100644 front/src/components/ui/slider.tsx create mode 100644 front/src/components/ui/tooltip.tsx create mode 100644 front/src/theme/config sample.ts delete mode 100644 front/src/theme/styles.ts diff --git a/front/package.json b/front/package.json index 706a554..6a3e368 100644 --- a/front/package.json +++ b/front/package.json @@ -29,11 +29,9 @@ "*.{ts,tsx,js,jsx,json}": "prettier --write" }, "dependencies": { - "@chakra-ui/anatomy": "2.3.4", "@chakra-ui/cli": "3.3.1", "@chakra-ui/react": "3.3.1", "@emotion/react": "11.14.0", - "@emotion/styled": "11.14.0", "allotment": "1.20.2", "css-mediaquery": "0.1.2", "dayjs": "1.11.13", diff --git a/front/pnpm-lock.yaml b/front/pnpm-lock.yaml index 63d780a..5a43b9b 100644 --- a/front/pnpm-lock.yaml +++ b/front/pnpm-lock.yaml @@ -8,9 +8,6 @@ importers: .: dependencies: - '@chakra-ui/anatomy': - specifier: 2.3.4 - version: 2.3.4 '@chakra-ui/cli': specifier: 3.3.1 version: 3.3.1(@chakra-ui/react@3.3.1(@emotion/react@11.14.0(@types/react@18.3.8)(react@18.3.1))(react-dom@18.3.1(react@18.3.1))(react@18.3.1)) @@ -20,9 +17,6 @@ importers: '@emotion/react': specifier: 11.14.0 version: 11.14.0(@types/react@18.3.8)(react@18.3.1) - '@emotion/styled': - specifier: 11.14.0 - version: 11.14.0(@emotion/react@11.14.0(@types/react@18.3.8)(react@18.3.1))(@types/react@18.3.8)(react@18.3.1) allotment: specifier: 1.20.2 version: 1.20.2(react-dom@18.3.1(react@18.3.1))(react@18.3.1) @@ -378,9 +372,6 @@ packages: '@bcoe/v8-coverage@0.2.3': resolution: {integrity: sha512-0hYQ8SB4Db5zvZB4axdMHGwEaQjkZzFjQiN9LVYvIFB2nSUHW9tYpxWriPrWDASIxiaXax83REcLxuSdnGPZtw==} - '@chakra-ui/anatomy@2.3.4': - resolution: {integrity: sha512-fFIYN7L276gw0Q7/ikMMlZxP7mvnjRaWJ7f3Jsf9VtDOi6eAYIBRrhQe6+SZ0PGmoOkRaBc7gSE5oeIbgFFyrw==} - '@chakra-ui/cli@3.3.1': resolution: {integrity: sha512-TTpGVT4RuajxzYjMP95Ba3HU052cmdrYgru77ZGD+IDb/HLATjpXNViFAn1R+ITMCxa4v0zqYEWLY9Ex2L090A==} hasBin: true @@ -444,16 +435,6 @@ packages: '@emotion/sheet@1.4.0': resolution: {integrity: sha512-fTBW9/8r2w3dXWYM4HCB1Rdp8NLibOw2+XELH5m5+AkWiL/KqYX6dc0kKYlaYyKjrQ6ds33MCdMPEwgs2z1rqg==} - '@emotion/styled@11.14.0': - resolution: {integrity: sha512-XxfOnXFffatap2IyCeJyNov3kiDQWoR08gPUQxvbL7fxKryGBKUZUkG6Hz48DZwVrJSVh9sJboyV1Ds4OW6SgA==} - peerDependencies: - '@emotion/react': ^11.0.0-rc.0 - '@types/react': '*' - react: '>=16.8.0' - peerDependenciesMeta: - '@types/react': - optional: true - '@emotion/unitless@0.10.0': resolution: {integrity: sha512-dFoMUuQA20zvtVTuxZww6OHoJYgrzfKM1t52mVySDJnMSEa08ruEvdYQbhvyu6soU+NeLVd3yKfTfT0NeV6qGg==} @@ -5469,8 +5450,6 @@ snapshots: '@bcoe/v8-coverage@0.2.3': {} - '@chakra-ui/anatomy@2.3.4': {} - '@chakra-ui/cli@3.3.1(@chakra-ui/react@3.3.1(@emotion/react@11.14.0(@types/react@18.3.8)(react@18.3.1))(react-dom@18.3.1(react@18.3.1))(react@18.3.1))': dependencies: '@chakra-ui/react': 3.3.1(@emotion/react@11.14.0(@types/react@18.3.8)(react@18.3.1))(react-dom@18.3.1(react@18.3.1))(react@18.3.1) @@ -5595,21 +5574,6 @@ snapshots: '@emotion/sheet@1.4.0': {} - '@emotion/styled@11.14.0(@emotion/react@11.14.0(@types/react@18.3.8)(react@18.3.1))(@types/react@18.3.8)(react@18.3.1)': - dependencies: - '@babel/runtime': 7.24.7 - '@emotion/babel-plugin': 11.13.5 - '@emotion/is-prop-valid': 1.3.1 - '@emotion/react': 11.14.0(@types/react@18.3.8)(react@18.3.1) - '@emotion/serialize': 1.3.3 - '@emotion/use-insertion-effect-with-fallbacks': 1.2.0(react@18.3.1) - '@emotion/utils': 1.4.2 - react: 18.3.1 - optionalDependencies: - '@types/react': 18.3.8 - transitivePeerDependencies: - - supports-color - '@emotion/unitless@0.10.0': {} '@emotion/use-insertion-effect-with-fallbacks@1.2.0(react@18.3.1)': diff --git a/front/src/App.tsx b/front/src/App.tsx index 4c119c0..efb8056 100644 --- a/front/src/App.tsx +++ b/front/src/App.tsx @@ -56,6 +56,7 @@ const AppEnvHint = () => { return ( <> { insetEnd="0" h="2px" bg="warning.400" - as="button" cursor="pointer" data-test-id="devtools" onClick={dialog.onOpen} @@ -84,7 +84,7 @@ const AppEnvHint = () => { > {envName.join(' : ')} - + Outils développeurs diff --git a/front/src/components/TopBar/TopBar.tsx b/front/src/components/TopBar/TopBar.tsx index 4527a82..91a392b 100644 --- a/front/src/components/TopBar/TopBar.tsx +++ b/front/src/components/TopBar/TopBar.tsx @@ -38,7 +38,14 @@ import { Button } from '../ui/themed'; export const TOP_BAR_HEIGHT = '50px'; export const BUTTON_TOP_BAR_PROPERTY = { - theme: '@menu', + bg: 'back.100', + color: 'brand.900', + borderRadius: 0, + border: 0, + _hover: { background: 'back.300' }, + _focus: { border: 'none' }, + fontSize: '20px', + textTransform: 'uppercase', height: TOP_BAR_HEIGHT, }; @@ -143,7 +150,7 @@ export const TopBar = ({ title, children }: TopBarProps) => { { data={dataAlbum?.covers} size={BASE_WRAP_ICON_SIZE} flex={1} - // TODO: iconEmpty={LuDisc3} + iconEmpty={} /> { overflowX="hidden" flex={1} > - { // noOfLines={[1, 2]} > {dataAlbum?.name} - - + { // noOfLines={1} > {countTracksOfAnAlbum} track{countTracksOfAnAlbum >= 1 && 's'} - + ); diff --git a/front/src/components/contextMenu/ContextMenu.tsx b/front/src/components/contextMenu/ContextMenu.tsx index 482c365..76a24ae 100644 --- a/front/src/components/contextMenu/ContextMenu.tsx +++ b/front/src/components/contextMenu/ContextMenu.tsx @@ -1,12 +1,9 @@ import { useState } from 'react'; -import { - IconButton, -} from '@chakra-ui/react'; import { LuMenu } from 'react-icons/lu'; import { MenuContent, MenuItem, MenuRoot, MenuTrigger } from '../ui/menu'; -import { Button } from '../ui/themed'; -import { customVariant } from '@/theme/recipes/button'; +import { Button } from '../ui/button'; + export type MenuElement = { name: string; @@ -17,21 +14,6 @@ export type ContextMenuProps = { elements?: MenuElement[]; }; -const theme = { - plop: { - bg: { _light: 'red', _dark: 'brand.300', _pink: "orange" }, - _hover: { bg: { _light: 'green', _dark: 'brand.400', _pink: "black" } }, - // bg: { _light: 'brand.600', _dark: 'brand.300' }, - // _hover: { bg: { _light: 'brand.700', _dark: 'brand.400' } }, - /* - bgActive: { _light: 'brand.600', _dark: 'brand.300' }, - color: { _light: 'white', _dark: 'brand.900' }, - colorHover: { _light: 'brand.800', _dark: 'brand.100' }, - boxShadowHover: 'outline-over' - */ - } -}; - export const ContextMenu = ({ elements }: ContextMenuProps) => { if (!elements) { return <>; @@ -40,9 +22,11 @@ export const ContextMenu = ({ elements }: ContextMenuProps) => { {/* This is very stupid, we need to set as span to prevent a button in button... WTF */} - diff --git a/front/src/components/form/FormCovers.tsx b/front/src/components/form/FormCovers.tsx index 547e12a..254efcc 100644 --- a/front/src/components/form/FormCovers.tsx +++ b/front/src/components/form/FormCovers.tsx @@ -104,14 +104,13 @@ export const CenterIcon = ({ return ( + >{IconEl} ); }; @@ -150,14 +149,13 @@ export const FormCovers = ({ onRemove && onRemove(index)} - /> + > diff --git a/front/src/components/popup/AlbumEditPopUp.tsx b/front/src/components/popup/AlbumEditPopUp.tsx index 1ba321d..c0ddd3f 100644 --- a/front/src/components/popup/AlbumEditPopUp.tsx +++ b/front/src/components/popup/AlbumEditPopUp.tsx @@ -25,7 +25,8 @@ import { useServiceContext } from '@/service/ServiceContext'; import { useCountTracksWithAlbumId } from '@/service/Track'; import { isNullOrUndefined } from '@/utils/validator'; import { DialogBody, DialogContent, DialogFooter, DialogHeader, DialogRoot } from '@/components/ui/dialog'; -import { Button } from '../ui/themed'; +import { Button } from '../ui/button'; + export type AlbumEditPopUpProps = {}; @@ -168,7 +169,9 @@ export const AlbumEditPopUp = ({ }: AlbumEditPopUpProps) => { diff --git a/front/src/scene/album/AlbumsPage.tsx b/front/src/scene/album/AlbumsPage.tsx index f938205..cd70ece 100644 --- a/front/src/scene/album/AlbumsPage.tsx +++ b/front/src/scene/album/AlbumsPage.tsx @@ -36,7 +36,7 @@ export const AlbumsPage = () => { - + {dataAlbums.map((data) => ( { backgroundColor={useColorModeValue('#FFFFFF88', '#00000088')} key={data.id} padding="5px" - as="button" _hover={{ boxShadow: 'outline-over', bgColor: useColorModeValue('#FFFFFFF7', '#000000F7'), diff --git a/front/src/scene/artist/ArtistDetailPage.tsx b/front/src/scene/artist/ArtistDetailPage.tsx index b9bcb70..c6af6f9 100644 --- a/front/src/scene/artist/ArtistDetailPage.tsx +++ b/front/src/scene/artist/ArtistDetailPage.tsx @@ -88,7 +88,7 @@ export const ArtistDetailPage = () => { - + {albumIdsOfAnArtist?.map((data) => ( { - + {dataArtist?.map((data) => ( { - + {dataGenders.map((data) => ( { <> - + {homeList.map((data) => ( option, & > optgroup": { + "bg": "inherit" + } + }, + "indicator": { + "position": "absolute", + "display": "inline-flex", + "alignItems": "center", + "justifyContent": "center", + "pointerEvents": "none", + "top": "50%", + "transform": "translateY(-50%)", + "height": "100%", + "color": "fg.muted", + "_disabled": { + "opacity": "0.5" + }, + "_invalid": { + "color": "fg.error" + }, + "_icon": { + "width": "1em", + "height": "1em" + } + } + }, + "variants": { + "variant": { + "outline": { + "field": { + "bg": "transparent", + "borderWidth": "1px", + "borderColor": "border", + "_expanded": { + "borderColor": "border.emphasized" + } + } + }, + "subtle": { + "field": { + "borderWidth": "1px", + "borderColor": "transparent", + "bg": "bg.muted" + } + }, + "plain": { + "field": { + "bg": "transparent", + "color": "fg", + "focusRingWidth": "2px" + } + } + }, + "size": { + "xs": { + "field": { + "textStyle": "xs", + "ps": "2", + "pe": "6", + "height": "6" + }, + "indicator": { + "textStyle": "sm", + "insetEnd": "1.5" + } + }, + "sm": { + "field": { + "textStyle": "sm", + "ps": "2.5", + "pe": "8", + "height": "8" + }, + "indicator": { + "textStyle": "md", + "insetEnd": "2" + } + }, + "md": { + "field": { + "textStyle": "sm", + "ps": "3", + "pe": "8", + "height": "10" + }, + "indicator": { + "textStyle": "lg", + "insetEnd": "2" + } + }, + "lg": { + "field": { + "textStyle": "md", + "ps": "4", + "pe": "8", + "height": "11" + }, + "indicator": { + "textStyle": "xl", + "insetEnd": "3" + } + }, + "xl": { + "field": { + "textStyle": "md", + "ps": "4.5", + "pe": "10", + "height": "12" + }, + "indicator": { + "textStyle": "xl", + "insetEnd": "3" + } + } + } + }, + "defaultVariants": { + "size": "md", + "variant": "outline" + } + }, + "numberInput": { + "className": "chakra-number-input", + "slots": [ + "root", + "label", + "input", + "control", + "valueText", + "incrementTrigger", + "decrementTrigger", + "scrubber" + ], + "base": { + "root": { + "position": "relative", + "zIndex": "0", + "isolation": "isolate" + }, + "input": { + "width": "100%", + "minWidth": "0", + "outline": "0", + "position": "relative", + "appearance": "none", + "textAlign": "start", + "borderRadius": "l2", + "_disabled": { + "layerStyle": "disabled" + }, + "height": "var(--input-height)", + "minW": "var(--input-height)", + "--focus-color": "colors.colorPalette.focusRing", + "--error-color": "colors.border.error", + "_invalid": { + "focusRingColor": "var(--error-color)", + "borderColor": "var(--error-color)" + }, + "verticalAlign": "top", + "pe": "calc(var(--stepper-width) + 0.5rem)" + }, + "control": { + "display": "flex", + "flexDirection": "column", + "position": "absolute", + "top": "0", + "insetEnd": "0px", + "margin": "1px", + "width": "var(--stepper-width)", + "height": "calc(100% - 2px)", + "zIndex": "1", + "borderStartWidth": "1px", + "divideY": "1px" + }, + "incrementTrigger": { + "display": "flex", + "justifyContent": "center", + "alignItems": "center", + "flex": "1", + "userSelect": "none", + "cursor": "button", + "lineHeight": "1", + "color": "fg.muted", + "--stepper-base-radius": "radii.l1", + "--stepper-radius": "calc(var(--stepper-base-radius) + 1px)", + "_icon": { + "boxSize": "1em" + }, + "_disabled": { + "opacity": "0.5" + }, + "_hover": { + "bg": "bg.muted" + }, + "_active": { + "bg": "bg.emphasized" + }, + "borderTopEndRadius": "var(--stepper-radius)" + }, + "decrementTrigger": { + "display": "flex", + "justifyContent": "center", + "alignItems": "center", + "flex": "1", + "userSelect": "none", + "cursor": "button", + "lineHeight": "1", + "color": "fg.muted", + "--stepper-base-radius": "radii.l1", + "--stepper-radius": "calc(var(--stepper-base-radius) + 1px)", + "_icon": { + "boxSize": "1em" + }, + "_disabled": { + "opacity": "0.5" + }, + "_hover": { + "bg": "bg.muted" + }, + "_active": { + "bg": "bg.emphasized" + }, + "borderBottomEndRadius": "var(--stepper-radius)" + }, + "valueText": { + "fontWeight": "medium", + "fontFeatureSettings": "pnum", + "fontVariantNumeric": "proportional-nums" + } + }, + "variants": { + "size": { + "xs": { + "input": { + "textStyle": "xs", + "px": "2", + "--input-height": "sizes.8" + }, + "control": { + "fontSize": "2xs", + "--stepper-width": "sizes.4" + } + }, + "sm": { + "input": { + "textStyle": "sm", + "px": "2.5", + "--input-height": "sizes.9" + }, + "control": { + "fontSize": "xs", + "--stepper-width": "sizes.5" + } + }, + "md": { + "input": { + "textStyle": "sm", + "px": "3", + "--input-height": "sizes.10" + }, + "control": { + "fontSize": "sm", + "--stepper-width": "sizes.6" + } + }, + "lg": { + "input": { + "textStyle": "md", + "px": "4", + "--input-height": "sizes.11" + }, + "control": { + "fontSize": "sm", + "--stepper-width": "sizes.6" + } + } + }, + "variant": { + "outline": { + "input": { + "bg": "transparent", + "borderWidth": "1px", + "borderColor": "border", + "focusVisibleRing": "inside" + } + }, + "subtle": { + "input": { + "borderWidth": "1px", + "borderColor": "transparent", + "bg": "bg.muted", + "focusVisibleRing": "inside" + } + }, + "flushed": { + "input": { + "bg": "transparent", + "borderBottomWidth": "1px", + "borderBottomColor": "border", + "borderRadius": "0", + "px": "0", + "_focusVisible": { + "borderColor": "var(--focus-color)", + "boxShadow": "0px 1px 0px 0px var(--focus-color)" + } + } + } + } + }, + "defaultVariants": { + "size": "md", + "variant": "outline" + } + }, + "pinInput": { + "className": "chakra-pin-input", + "slots": [ + "root", + "label", + "input", + "control" + ], + "base": { + "input": { + "width": "var(--input-height)", + "minWidth": "0", + "outline": "0", + "position": "relative", + "appearance": "none", + "textAlign": "center", + "borderRadius": "l2", + "_disabled": { + "layerStyle": "disabled" + }, + "height": "var(--input-height)", + "minW": "var(--input-height)", + "--focus-color": "colors.colorPalette.focusRing", + "--error-color": "colors.border.error", + "_invalid": { + "focusRingColor": "var(--error-color)", + "borderColor": "var(--error-color)" + } + } + }, + "variants": { + "size": { + "2xs": { + "input": { + "textStyle": "xs", + "px": "2", + "--input-height": "sizes.7" + } + }, + "xs": { + "input": { + "textStyle": "xs", + "px": "2", + "--input-height": "sizes.8" + } + }, + "sm": { + "input": { + "textStyle": "sm", + "px": "2.5", + "--input-height": "sizes.9" + } + }, + "md": { + "input": { + "textStyle": "sm", + "px": "3", + "--input-height": "sizes.10" + } + }, + "lg": { + "input": { + "textStyle": "md", + "px": "4", + "--input-height": "sizes.11" + } + }, + "xl": { + "input": { + "textStyle": "md", + "px": "4.5", + "--input-height": "sizes.12" + } + }, + "2xl": { + "input": { + "textStyle": "lg", + "px": "5", + "--input-height": "sizes.16" + } + } + }, + "variant": { + "outline": { + "input": { + "bg": "transparent", + "borderWidth": "1px", + "borderColor": "border", + "focusVisibleRing": "inside" + } + }, + "subtle": { + "input": { + "borderWidth": "1px", + "borderColor": "transparent", + "bg": "bg.muted", + "focusVisibleRing": "inside" + } + }, + "flushed": { + "input": { + "bg": "transparent", + "borderBottomWidth": "1px", + "borderBottomColor": "border", + "borderRadius": "0", + "px": "0", + "_focusVisible": { + "borderColor": "var(--focus-color)", + "boxShadow": "0px 1px 0px 0px var(--focus-color)" + } + } + } + } + }, + "defaultVariants": { + "size": "md", + "variant": "outline" + } + }, + "popover": { + "className": "chakra-popover", + "slots": [ + "arrow", + "arrowTip", + "anchor", + "trigger", + "indicator", + "positioner", + "content", + "title", + "description", + "closeTrigger", + "header", + "body", + "footer" + ], + "base": { + "content": { + "position": "relative", + "display": "flex", + "flexDirection": "column", + "textStyle": "sm", + "--popover-bg": "colors.bg.panel", + "bg": "var(--popover-bg)", + "boxShadow": "lg", + "--popover-size": "sizes.xs", + "--popover-mobile-size": "calc(100dvw - 1rem)", + "width": { + "base": "min(var(--popover-mobile-size), var(--popover-size))", + "sm": "var(--popover-size)" + }, + "borderRadius": "l3", + "--popover-z-index": "zIndex.popover", + "zIndex": "calc(var(--popover-z-index) + var(--layer-index, 0))", + "outline": "0", + "transformOrigin": "var(--transform-origin)", + "_open": { + "animationStyle": "scale-fade-in", + "animationDuration": "fast" + }, + "_closed": { + "animationStyle": "scale-fade-out", + "animationDuration": "faster" + } + }, + "header": { + "paddingInline": "var(--popover-padding)", + "paddingTop": "var(--popover-padding)" + }, + "body": { + "padding": "var(--popover-padding)", + "flex": "1" + }, + "footer": { + "display": "flex", + "alignItems": "center", + "paddingInline": "var(--popover-padding)", + "paddingBottom": "var(--popover-padding)" + }, + "arrow": { + "--arrow-size": "sizes.3", + "--arrow-background": "var(--popover-bg)" + }, + "arrowTip": { + "borderTopWidth": "1px", + "borderInlineStartWidth": "1px" + } + }, + "variants": { + "size": { + "xs": { + "content": { + "--popover-padding": "spacing.3" + } + }, + "sm": { + "content": { + "--popover-padding": "spacing.4" + } + }, + "md": { + "content": { + "--popover-padding": "spacing.5" + } + }, + "lg": { + "content": { + "--popover-padding": "spacing.6" + } + } + } + }, + "defaultVariants": { + "size": "md" + } + }, + "progress": { + "slots": [ + "root", + "label", + "track", + "range", + "valueText", + "view", + "circle", + "circleTrack", + "circleRange" + ], + "className": "chakra-progress", + "base": { + "root": { + "textStyle": "sm", + "position": "relative" + }, + "track": { + "overflow": "hidden", + "position": "relative" + }, + "range": { + "display": "flex", + "alignItems": "center", + "justifyContent": "center", + "transitionProperty": "width, height", + "transitionDuration": "slow", + "height": "100%", + "bgColor": "var(--track-color)", + "_indeterminate": { + "--animate-from-x": "-40%", + "--animate-to-x": "100%", + "position": "absolute", + "willChange": "left", + "minWidth": "50%", + "animation": "position 1s ease infinite normal none running", + "backgroundImage": "linear-gradient(to right, transparent 0%, var(--track-color) 50%, transparent 100%)" + } + }, + "label": { + "display": "inline-flex", + "fontWeight": "medium", + "alignItems": "center", + "gap": "1" + }, + "valueText": { + "textStyle": "xs", + "lineHeight": "1", + "fontWeight": "medium" + } + }, + "variants": { + "variant": { + "outline": { + "track": { + "shadow": "inset", + "bgColor": "bg.muted" + }, + "range": { + "bgColor": "colorPalette.solid" + } + }, + "subtle": { + "track": { + "bgColor": "colorPalette.muted" + }, + "range": { + "bgColor": "colorPalette.solid/72" + } + } + }, + "shape": { + "square": {}, + "rounded": { + "track": { + "borderRadius": "l1" + } + }, + "full": { + "track": { + "borderRadius": "full" + } + } + }, + "striped": { + "true": { + "range": { + "backgroundImage": "linear-gradient(45deg, var(--stripe-color) 25%, transparent 25%, transparent 50%, var(--stripe-color) 50%, var(--stripe-color) 75%, transparent 75%, transparent)", + "backgroundSize": "var(--stripe-size) var(--stripe-size)", + "--stripe-size": "1rem", + "--stripe-color": { + "_light": "rgba(255, 255, 255, 0.3)", + "_dark": "rgba(0, 0, 0, 0.3)" + } + } + } + }, + "animated": { + "true": { + "range": { + "--animate-from": "var(--stripe-size)", + "animation": "bg-position 1s linear infinite" + } + } + }, + "size": { + "xs": { + "track": { + "h": "1.5" + } + }, + "sm": { + "track": { + "h": "2" + } + }, + "md": { + "track": { + "h": "2.5" + } + }, + "lg": { + "track": { + "h": "3" + } + }, + "xl": { + "track": { + "h": "4" + } + } + } + }, + "defaultVariants": { + "variant": "outline", + "size": "md", + "shape": "rounded" + } + }, + "progressCircle": { + "className": "chakra-progress-circle", + "slots": [ + "root", + "label", + "track", + "range", + "valueText", + "view", + "circle", + "circleTrack", + "circleRange" + ], + "base": { + "root": { + "display": "inline-flex", + "textStyle": "sm", + "position": "relative" + }, + "circle": { + "_indeterminate": { + "animation": "spin 2s linear infinite" + } + }, + "circleTrack": { + "--track-color": "colors.colorPalette.muted", + "stroke": "var(--track-color)" + }, + "circleRange": { + "stroke": "colorPalette.solid", + "transitionProperty": "stroke-dasharray", + "transitionDuration": "0.6s", + "_indeterminate": { + "animation": "circular-progress 1.5s linear infinite" + } + }, + "label": { + "display": "inline-flex" + }, + "valueText": { + "lineHeight": "1", + "fontWeight": "medium", + "letterSpacing": "tight", + "fontVariantNumeric": "tabular-nums" + } + }, + "variants": { + "size": { + "xs": { + "circle": { + "--size": "24px", + "--thickness": "4px" + }, + "valueText": { + "textStyle": "2xs" + } + }, + "sm": { + "circle": { + "--size": "32px", + "--thickness": "5px" + }, + "valueText": { + "textStyle": "2xs" + } + }, + "md": { + "circle": { + "--size": "40px", + "--thickness": "6px" + }, + "valueText": { + "textStyle": "xs" + } + }, + "lg": { + "circle": { + "--size": "48px", + "--thickness": "7px" + }, + "valueText": { + "textStyle": "sm" + } + }, + "xl": { + "circle": { + "--size": "64px", + "--thickness": "8px" + }, + "valueText": { + "textStyle": "sm" + } + } + } + }, + "defaultVariants": { + "size": "md" + } + }, + "radioCard": { + "className": "chakra-radio-card", + "slots": [ + "root", + "label", + "item", + "itemText", + "itemControl", + "indicator", + "itemAddon", + "itemIndicator", + "itemContent", + "itemDescription" + ], + "base": { + "root": { + "display": "flex", + "flexDirection": "column", + "gap": "1.5", + "isolation": "isolate" + }, + "item": { + "flex": "1", + "display": "flex", + "flexDirection": "column", + "userSelect": "none", + "position": "relative", + "borderRadius": "l2", + "_focus": { + "bg": "colorPalette.muted/20" + }, + "_disabled": { + "opacity": "0.8", + "borderColor": "border.disabled" + }, + "_checked": { + "zIndex": "1" + } + }, + "label": { + "display": "inline-flex", + "fontWeight": "medium", + "textStyle": "sm", + "_disabled": { + "opacity": "0.5" + } + }, + "itemText": { + "fontWeight": "medium" + }, + "itemDescription": { + "opacity": "0.64", + "textStyle": "sm" + }, + "itemControl": { + "display": "inline-flex", + "flex": "1", + "pos": "relative", + "rounded": "inherit", + "justifyContent": "var(--radio-card-justify)", + "alignItems": "var(--radio-card-align)", + "_disabled": { + "bg": "bg.muted" + } + }, + "itemIndicator": { + "display": "inline-flex", + "alignItems": "center", + "justifyContent": "center", + "flexShrink": 0, + "verticalAlign": "top", + "color": "white", + "borderWidth": "1px", + "borderColor": "transparent", + "borderRadius": "full", + "cursor": "radio", + "_focusVisible": { + "outline": "2px solid", + "outlineColor": "colorPalette.focusRing", + "outlineOffset": "2px" + }, + "_invalid": { + "colorPalette": "red", + "borderColor": "red.500" + }, + "_disabled": { + "opacity": "0.5", + "cursor": "disabled" + }, + "& .dot": { + "height": "100%", + "width": "100%", + "borderRadius": "full", + "bg": "currentColor", + "scale": "0.4" + } + }, + "itemAddon": { + "roundedBottom": "inherit", + "_disabled": { + "color": "fg.muted" + } + }, + "itemContent": { + "display": "flex", + "flexDirection": "column", + "flex": "1", + "gap": "1", + "justifyContent": "var(--radio-card-justify)", + "alignItems": "var(--radio-card-align)" + } + }, + "variants": { + "size": { + "sm": { + "item": { + "textStyle": "sm" + }, + "itemControl": { + "padding": "3", + "gap": "1.5" + }, + "itemAddon": { + "px": "3", + "py": "1.5", + "borderTopWidth": "1px" + }, + "itemIndicator": { + "boxSize": "4" + } + }, + "md": { + "item": { + "textStyle": "sm" + }, + "itemControl": { + "padding": "4", + "gap": "2.5" + }, + "itemAddon": { + "px": "4", + "py": "2", + "borderTopWidth": "1px" + }, + "itemIndicator": { + "boxSize": "5" + } + }, + "lg": { + "item": { + "textStyle": "md" + }, + "itemControl": { + "padding": "4", + "gap": "3.5" + }, + "itemAddon": { + "px": "4", + "py": "2", + "borderTopWidth": "1px" + }, + "itemIndicator": { + "boxSize": "6" + } + } + }, + "variant": { + "surface": { + "item": { + "borderWidth": "1px", + "_checked": { + "bg": "colorPalette.subtle", + "color": "colorPalette.fg", + "borderColor": "colorPalette.muted" + } + }, + "itemIndicator": { + "borderWidth": "1px", + "borderColor": "border", + "_checked": { + "bg": "colorPalette.solid", + "color": "colorPalette.contrast", + "borderColor": "colorPalette.solid" + } + } + }, + "subtle": { + "item": { + "bg": "bg.muted" + }, + "itemControl": { + "_checked": { + "bg": "colorPalette.muted", + "color": "colorPalette.fg" + } + }, + "itemIndicator": { + "borderWidth": "1px", + "borderColor": "inherit", + "_checked": { + "color": "colorPalette.fg", + "borderColor": "colorPalette.solid" + }, + "& .dot": { + "scale": "0.6" + } + } + }, + "outline": { + "item": { + "borderWidth": "1px", + "_checked": { + "boxShadow": "0 0 0 1px var(--shadow-color)", + "boxShadowColor": "colorPalette.solid", + "borderColor": "colorPalette.solid" + } + }, + "itemIndicator": { + "borderWidth": "1px", + "borderColor": "border", + "_checked": { + "bg": "colorPalette.solid", + "color": "colorPalette.contrast", + "borderColor": "colorPalette.solid" + } + } + }, + "solid": { + "item": { + "borderWidth": "1px", + "_checked": { + "bg": "colorPalette.solid", + "color": "colorPalette.contrast", + "borderColor": "colorPalette.solid" + } + }, + "itemIndicator": { + "bg": "bg", + "borderWidth": "1px", + "borderColor": "inherit", + "_checked": { + "color": "colorPalette.solid", + "borderColor": "currentcolor" + } + } + } + }, + "justify": { + "start": { + "item": { + "--radio-card-justify": "flex-start" + } + }, + "end": { + "item": { + "--radio-card-justify": "flex-end" + } + }, + "center": { + "item": { + "--radio-card-justify": "center" + } + } + }, + "align": { + "start": { + "item": { + "--radio-card-align": "flex-start" + }, + "itemControl": { + "textAlign": "start" + } + }, + "end": { + "item": { + "--radio-card-align": "flex-end" + }, + "itemControl": { + "textAlign": "end" + } + }, + "center": { + "item": { + "--radio-card-align": "center" + }, + "itemControl": { + "textAlign": "center" + } + } + }, + "orientation": { + "vertical": { + "itemControl": { + "flexDirection": "column" + } + }, + "horizontal": { + "itemControl": { + "flexDirection": "row" + } + } + } + }, + "defaultVariants": { + "size": "md", + "variant": "outline", + "align": "start", + "orientation": "horizontal" + } + }, + "radioGroup": { + "className": "chakra-radio-group", + "slots": [ + "root", + "label", + "item", + "itemText", + "itemControl", + "indicator", + "itemAddon", + "itemIndicator" + ], + "base": { + "item": { + "display": "inline-flex", + "alignItems": "center", + "position": "relative", + "fontWeight": "medium", + "_disabled": { + "cursor": "disabled" + } + }, + "itemControl": { + "display": "inline-flex", + "alignItems": "center", + "justifyContent": "center", + "flexShrink": 0, + "verticalAlign": "top", + "color": "white", + "borderWidth": "1px", + "borderColor": "transparent", + "borderRadius": "full", + "cursor": "radio", + "_focusVisible": { + "outline": "2px solid", + "outlineColor": "colorPalette.focusRing", + "outlineOffset": "2px" + }, + "_invalid": { + "colorPalette": "red", + "borderColor": "red.500" + }, + "_disabled": { + "opacity": "0.5", + "cursor": "disabled" + }, + "& .dot": { + "height": "100%", + "width": "100%", + "borderRadius": "full", + "bg": "currentColor", + "scale": "0.4" + } + }, + "label": { + "userSelect": "none", + "textStyle": "sm", + "_disabled": { + "opacity": "0.5" + } + } + }, + "variants": { + "variant": { + "outline": { + "itemControl": { + "borderWidth": "1px", + "borderColor": "inherit", + "_checked": { + "color": "colorPalette.fg", + "borderColor": "colorPalette.solid" + }, + "& .dot": { + "scale": "0.6" + } + } + }, + "subtle": { + "itemControl": { + "borderWidth": "1px", + "bg": "colorPalette.muted", + "borderColor": "colorPalette.muted", + "color": "transparent", + "_checked": { + "color": "colorPalette.fg" + } + } + }, + "solid": { + "itemControl": { + "borderWidth": "1px", + "borderColor": "border", + "_checked": { + "bg": "colorPalette.solid", + "color": "colorPalette.contrast", + "borderColor": "colorPalette.solid" + } + } + } + }, + "size": { + "xs": { + "item": { + "textStyle": "xs", + "gap": "1.5" + }, + "itemControl": { + "boxSize": "3" + } + }, + "sm": { + "item": { + "textStyle": "sm", + "gap": "2" + }, + "itemControl": { + "boxSize": "4" + } + }, + "md": { + "item": { + "textStyle": "sm", + "gap": "2.5" + }, + "itemControl": { + "boxSize": "5" + } + }, + "lg": { + "item": { + "textStyle": "md", + "gap": "3" + }, + "itemControl": { + "boxSize": "6" + } + } + } + }, + "defaultVariants": { + "size": "md", + "variant": "solid" + } + }, + "ratingGroup": { + "className": "chakra-rating-group", + "slots": [ + "root", + "label", + "item", + "control", + "itemIndicator" + ], + "base": { + "root": { + "display": "inline-flex" + }, + "control": { + "display": "inline-flex", + "alignItems": "center" + }, + "item": { + "display": "inline-flex", + "alignItems": "center", + "justifyContent": "center", + "userSelect": "none" + }, + "itemIndicator": { + "display": "inline-flex", + "alignItems": "center", + "justifyContent": "center", + "width": "1em", + "height": "1em", + "position": "relative", + "_icon": { + "stroke": "currentColor", + "width": "100%", + "height": "100%", + "display": "inline-block", + "flexShrink": 0, + "position": "absolute", + "left": 0, + "top": 0 + }, + "& [data-bg]": { + "color": "bg.emphasized" + }, + "& [data-fg]": { + "color": "transparent" + }, + "&[data-highlighted]:not([data-half])": { + "& [data-fg]": { + "color": "colorPalette.solid" + } + }, + "&[data-half]": { + "& [data-fg]": { + "color": "colorPalette.solid", + "clipPath": "inset(0 50% 0 0)" + } + } + } + }, + "variants": { + "size": { + "xs": { + "item": { + "textStyle": "sm" + } + }, + "sm": { + "item": { + "textStyle": "md" + } + }, + "md": { + "item": { + "textStyle": "xl" + } + }, + "lg": { + "item": { + "textStyle": "2xl" + } + } + } + }, + "defaultVariants": { + "size": "md" + } + }, + "segmentGroup": { + "className": "chakra-segment-group", + "slots": [ + "root", + "label", + "item", + "itemText", + "itemControl", + "indicator" + ], + "base": { + "root": { + "--segment-radius": "radii.l2", + "borderRadius": "l2", + "display": "inline-flex", + "boxShadow": "inset", + "minW": "max-content", + "textAlign": "center", + "position": "relative", + "isolation": "isolate", + "bg": "bg.muted" + }, + "item": { + "display": "flex", + "alignItems": "center", + "userSelect": "none", + "fontSize": "sm", + "position": "relative", + "color": "fg", + "borderRadius": "var(--segment-radius)", + "_disabled": { + "opacity": "0.5" + }, + "&:has(input:focus-visible)": { + "focusRing": "outside" + }, + "_before": { + "content": "\"\"", + "position": "absolute", + "insetInlineStart": 0, + "insetBlock": "1.5", + "bg": "border", + "width": "1px", + "transition": "opacity 0.2s" + }, + "& + &[data-state=checked], &[data-state=checked] + &, &:first-of-type": { + "_before": { + "opacity": "0" + } + }, + "&[data-state=checked][data-ssr]": { + "shadow": "sm", + "bg": "bg", + "borderRadius": "var(--segment-radius)" + } + }, + "indicator": { + "shadow": "sm", + "pos": "absolute", + "bg": { + "_light": "bg", + "_dark": "bg.emphasized" + }, + "width": "var(--width)", + "height": "var(--height)", + "top": "var(--top)", + "left": "var(--left)", + "zIndex": -1, + "borderRadius": "var(--segment-radius)" + } + }, + "variants": { + "size": { + "xs": { + "root": { + "height": "6" + }, + "item": { + "textStyle": "xs", + "px": "3", + "gap": "1" + } + }, + "sm": { + "root": { + "height": "8" + }, + "item": { + "textStyle": "sm", + "px": "4", + "gap": "2" + } + }, + "md": { + "root": { + "height": "10" + }, + "item": { + "textStyle": "sm", + "px": "4", + "gap": "2" + } + }, + "lg": { + "root": { + "height": "10" + }, + "item": { + "textStyle": "md", + "px": "5", + "gap": "3" + } + } + } + }, + "defaultVariants": { + "size": "md" + } + }, + "select": { + "className": "chakra-select", + "slots": [ + "label", + "positioner", + "trigger", + "indicator", + "clearTrigger", + "item", + "itemText", + "itemIndicator", + "itemGroup", + "itemGroupLabel", + "list", + "content", + "root", + "control", + "valueText", + "indicatorGroup" + ], + "base": { + "root": { + "display": "flex", + "flexDirection": "column", + "gap": "1.5", + "width": "full" + }, + "trigger": { + "display": "flex", + "alignItems": "center", + "justifyContent": "space-between", + "width": "full", + "minH": "var(--select-trigger-height)", + "px": "var(--select-trigger-padding-x)", + "borderRadius": "l2", + "userSelect": "none", + "textAlign": "start", + "focusVisibleRing": "inside", + "_placeholderShown": { + "color": "fg.muted" + }, + "_disabled": { + "layerStyle": "disabled" + }, + "_invalid": { + "borderColor": "border.error" + } + }, + "indicatorGroup": { + "display": "flex", + "alignItems": "center", + "gap": "1", + "pos": "absolute", + "right": "0", + "top": "0", + "bottom": "0", + "px": "var(--select-trigger-padding-x)", + "pointerEvents": "none" + }, + "indicator": { + "display": "flex", + "alignItems": "center", + "justifyContent": "center", + "color": { + "base": "fg.muted", + "_disabled": "fg.subtle", + "_invalid": "fg.error" + } + }, + "content": { + "background": "bg.panel", + "display": "flex", + "flexDirection": "column", + "zIndex": "dropdown", + "borderRadius": "l2", + "outline": 0, + "maxH": "96", + "overflowY": "auto", + "boxShadow": "md", + "_open": { + "animationStyle": "slide-fade-in", + "animationDuration": "fast" + }, + "_closed": { + "animationStyle": "slide-fade-out", + "animationDuration": "fastest" + } + }, + "item": { + "position": "relative", + "userSelect": "none", + "display": "flex", + "alignItems": "center", + "gap": "2", + "cursor": "option", + "justifyContent": "space-between", + "flex": "1", + "textAlign": "start", + "borderRadius": "l1", + "_highlighted": { + "bg": { + "_light": "bg.muted", + "_dark": "bg.emphasized" + } + }, + "_disabled": { + "pointerEvents": "none", + "opacity": "0.5" + }, + "_icon": { + "width": "4", + "height": "4" + } + }, + "control": { + "pos": "relative" + }, + "itemText": { + "flex": "1" + }, + "itemGroup": { + "_first": { + "mt": "0" + } + }, + "itemGroupLabel": { + "py": "1", + "fontWeight": "medium" + }, + "label": { + "fontWeight": "medium", + "userSelect": "none", + "textStyle": "sm", + "_disabled": { + "layerStyle": "disabled" + } + }, + "valueText": { + "lineClamp": "1", + "maxW": "80%" + } + }, + "variants": { + "variant": { + "outline": { + "trigger": { + "bg": "transparent", + "borderWidth": "1px", + "borderColor": "border", + "_expanded": { + "borderColor": "border.emphasized" + } + } + }, + "subtle": { + "trigger": { + "borderWidth": "1px", + "borderColor": "transparent", + "bg": "bg.muted" + } + } + }, + "size": { + "xs": { + "root": { + "--select-trigger-height": "sizes.8", + "--select-trigger-padding-x": "spacing.2" + }, + "content": { + "p": "1", + "gap": "1", + "textStyle": "xs" + }, + "trigger": { + "textStyle": "xs", + "gap": "1" + }, + "item": { + "py": "1", + "px": "2" + }, + "itemGroupLabel": { + "py": "1", + "px": "2" + }, + "indicator": { + "_icon": { + "width": "3.5", + "height": "3.5" + } + } + }, + "sm": { + "root": { + "--select-trigger-height": "sizes.9", + "--select-trigger-padding-x": "spacing.2.5" + }, + "content": { + "p": "1", + "textStyle": "sm" + }, + "trigger": { + "textStyle": "sm", + "gap": "1" + }, + "indicator": { + "_icon": { + "width": "4", + "height": "4" + } + }, + "item": { + "py": "1", + "px": "1.5" + }, + "itemGroup": { + "mt": "1" + }, + "itemGroupLabel": { + "py": "1", + "px": "1.5" + } + }, + "md": { + "root": { + "--select-trigger-height": "sizes.10", + "--select-trigger-padding-x": "spacing.3" + }, + "content": { + "p": "1", + "textStyle": "sm" + }, + "itemGroup": { + "mt": "1.5" + }, + "item": { + "py": "1.5", + "px": "2" + }, + "itemIndicator": { + "display": "flex", + "alignItems": "center", + "justifyContent": "center" + }, + "itemGroupLabel": { + "py": "1.5", + "px": "2" + }, + "trigger": { + "textStyle": "sm", + "gap": "2" + }, + "indicator": { + "_icon": { + "width": "4", + "height": "4" + } + } + }, + "lg": { + "root": { + "--select-trigger-height": "sizes.12", + "--select-trigger-padding-x": "spacing.4" + }, + "content": { + "p": "1.5", + "textStyle": "md" + }, + "itemGroup": { + "mt": "2" + }, + "item": { + "py": "2", + "px": "3" + }, + "itemGroupLabel": { + "py": "2", + "px": "3" + }, + "trigger": { + "textStyle": "md", + "py": "3", + "gap": "2" + }, + "indicator": { + "_icon": { + "width": "5", + "height": "5" + } + } + } + } + }, + "defaultVariants": { + "size": "md", + "variant": "outline" + } + }, + "slider": { + "className": "chakra-slider", + "slots": [ + "root", + "label", + "thumb", + "valueText", + "track", + "range", + "control", + "markerGroup", + "marker", + "draggingIndicator", + "markerIndicator" + ], + "base": { + "root": { + "display": "flex", + "flexDirection": "column", + "gap": "1", + "textStyle": "sm", + "position": "relative", + "isolation": "isolate", + "touchAction": "none" + }, + "label": { + "fontWeight": "medium", + "textStyle": "sm" + }, + "control": { + "display": "inline-flex", + "alignItems": "center", + "position": "relative" + }, + "track": { + "overflow": "hidden", + "borderRadius": "full", + "flex": "1" + }, + "range": { + "width": "inherit", + "height": "inherit", + "_disabled": { + "bg": "border.emphasized!" + } + }, + "markerGroup": { + "position": "absolute!", + "zIndex": "1" + }, + "marker": { + "--marker-bg": { + "base": "white", + "_underValue": "colors.bg" + }, + "display": "flex", + "alignItems": "center", + "gap": "calc(var(--slider-thumb-size) / 2)", + "color": "fg.muted", + "textStyle": "xs" + }, + "markerIndicator": { + "width": "var(--slider-marker-size)", + "height": "var(--slider-marker-size)", + "borderRadius": "full", + "bg": "var(--marker-bg)" + }, + "thumb": { + "width": "var(--slider-thumb-size)", + "height": "var(--slider-thumb-size)", + "display": "flex", + "alignItems": "center", + "justifyContent": "center", + "outline": 0, + "zIndex": "2", + "borderRadius": "full", + "_focusVisible": { + "ring": "2px", + "ringColor": "colorPalette.focusRing", + "ringOffset": "2px", + "ringOffsetColor": "bg" + } + } + }, + "variants": { + "size": { + "sm": { + "root": { + "--slider-thumb-size": "sizes.4", + "--slider-track-size": "sizes.1.5", + "--slider-marker-center": "6px", + "--slider-marker-size": "sizes.1", + "--slider-marker-inset": "3px" + } + }, + "md": { + "root": { + "--slider-thumb-size": "sizes.5", + "--slider-track-size": "sizes.2", + "--slider-marker-center": "8px", + "--slider-marker-size": "sizes.1", + "--slider-marker-inset": "4px" + } + }, + "lg": { + "root": { + "--slider-thumb-size": "sizes.6", + "--slider-track-size": "sizes.2.5", + "--slider-marker-center": "9px", + "--slider-marker-size": "sizes.1.5", + "--slider-marker-inset": "5px" + } + } + }, + "variant": { + "outline": { + "track": { + "shadow": "inset", + "bg": "bg.emphasized/72" + }, + "range": { + "bg": "colorPalette.solid" + }, + "thumb": { + "borderWidth": "2px", + "borderColor": "colorPalette.solid", + "bg": "bg", + "_disabled": { + "bg": "border.emphasized", + "borderColor": "border.emphasized" + } + } + }, + "solid": { + "track": { + "bg": "colorPalette.subtle", + "_disabled": { + "bg": "bg.muted" + } + }, + "range": { + "bg": "colorPalette.solid" + }, + "thumb": { + "bg": "colorPalette.solid", + "_disabled": { + "bg": "border.emphasized" + } + } + } + }, + "orientation": { + "vertical": { + "root": { + "display": "inline-flex" + }, + "control": { + "flexDirection": "column", + "height": "100%", + "minWidth": "var(--slider-thumb-size)", + "&[data-has-mark-label]": { + "marginEnd": "4" + } + }, + "track": { + "width": "var(--slider-track-size)" + }, + "thumb": { + "left": "50%", + "translate": "-50% 0" + }, + "markerGroup": { + "insetStart": "var(--slider-marker-center)", + "insetBlock": "var(--slider-marker-inset)" + }, + "marker": { + "flexDirection": "row" + } + }, + "horizontal": { + "control": { + "flexDirection": "row", + "width": "100%", + "minHeight": "var(--slider-thumb-size)", + "&[data-has-mark-label]": { + "marginBottom": "4" + } + }, + "track": { + "height": "var(--slider-track-size)" + }, + "thumb": { + "top": "50%", + "translate": "0 -50%" + }, + "markerGroup": { + "top": "var(--slider-marker-center)", + "insetInline": "var(--slider-marker-inset)" + }, + "marker": { + "flexDirection": "column" + } + } + } + }, + "defaultVariants": { + "size": "md", + "variant": "outline", + "orientation": "horizontal" + } + }, + "stat": { + "className": "chakra-stat", + "slots": [ + "root", + "label", + "helpText", + "valueText", + "valueUnit", + "indicator" + ], + "base": { + "root": { + "display": "flex", + "flexDirection": "column", + "gap": "1", + "position": "relative", + "flex": "1" + }, + "label": { + "display": "inline-flex", + "gap": "1.5", + "alignItems": "center", + "color": "fg.muted", + "textStyle": "sm" + }, + "helpText": { + "color": "fg.muted", + "textStyle": "xs" + }, + "valueUnit": { + "color": "fg.muted", + "textStyle": "xs", + "fontWeight": "initial", + "letterSpacing": "initial" + }, + "valueText": { + "verticalAlign": "baseline", + "fontWeight": "semibold", + "letterSpacing": "tight", + "fontFeatureSettings": "pnum", + "fontVariantNumeric": "proportional-nums", + "display": "inline-flex", + "gap": "1" + }, + "indicator": { + "display": "inline-flex", + "alignItems": "center", + "justifyContent": "center", + "marginEnd": 1, + "& :where(svg)": { + "w": "1em", + "h": "1em" + }, + "&[data-type=up]": { + "color": "fg.success" + }, + "&[data-type=down]": { + "color": "fg.error" + } + } + }, + "variants": { + "size": { + "sm": { + "valueText": { + "textStyle": "xl" + } + }, + "md": { + "valueText": { + "textStyle": "2xl" + } + }, + "lg": { + "valueText": { + "textStyle": "3xl" + } + } + } + }, + "defaultVariants": { + "size": "md" + } + }, + "steps": { + "className": "chakra-steps", + "slots": [ + "root", + "list", + "item", + "trigger", + "indicator", + "separator", + "content", + "title", + "description", + "nextTrigger", + "prevTrigger", + "progress" + ], + "base": { + "root": { + "display": "flex", + "width": "full" + }, + "list": { + "display": "flex", + "justifyContent": "space-between", + "--steps-gutter": "spacing.3", + "--steps-thickness": "2px" + }, + "title": { + "fontWeight": "medium", + "color": "fg" + }, + "description": { + "color": "fg.muted" + }, + "separator": { + "bg": "border", + "flex": "1" + }, + "indicator": { + "display": "flex", + "justifyContent": "center", + "alignItems": "center", + "flexShrink": "0", + "borderRadius": "full", + "fontWeight": "medium", + "width": "var(--steps-size)", + "height": "var(--steps-size)", + "_icon": { + "flexShrink": "0", + "width": "var(--steps-icon-size)", + "height": "var(--steps-icon-size)" + } + }, + "item": { + "position": "relative", + "display": "flex", + "flex": "1 0 0", + "&:last-of-type": { + "flex": "initial", + "& [data-part=separator]": { + "display": "none" + } + } + }, + "trigger": { + "display": "flex", + "alignItems": "center", + "gap": "3", + "textAlign": "start", + "focusVisibleRing": "outside", + "borderRadius": "l2" + }, + "content": { + "focusVisibleRing": "outside" + } + }, + "variants": { + "orientation": { + "vertical": { + "root": { + "flexDirection": "row", + "height": "100%" + }, + "list": { + "flexDirection": "column", + "alignItems": "flex-start" + }, + "separator": { + "position": "absolute", + "width": "var(--steps-thickness)", + "height": "100%", + "maxHeight": "calc(100% - var(--steps-size) - var(--steps-gutter) * 2)", + "top": "calc(var(--steps-size) + var(--steps-gutter))", + "insetStart": "calc(var(--steps-size) / 2 - 1px)" + }, + "item": { + "alignItems": "flex-start" + } + }, + "horizontal": { + "root": { + "flexDirection": "column", + "width": "100%" + }, + "list": { + "flexDirection": "row", + "alignItems": "center" + }, + "separator": { + "width": "100%", + "height": "var(--steps-thickness)", + "marginX": "var(--steps-gutter)" + }, + "item": { + "alignItems": "center" + } + } + }, + "variant": { + "solid": { + "indicator": { + "_incomplete": { + "borderWidth": "var(--steps-thickness)" + }, + "_current": { + "bg": "colorPalette.muted", + "borderWidth": "var(--steps-thickness)", + "borderColor": "colorPalette.solid", + "color": "colorPalette.fg" + }, + "_complete": { + "bg": "colorPalette.solid", + "borderColor": "colorPalette.solid", + "color": "colorPalette.contrast" + } + }, + "separator": { + "_complete": { + "bg": "colorPalette.solid" + } + } + }, + "subtle": { + "indicator": { + "_incomplete": { + "bg": "bg.muted" + }, + "_current": { + "bg": "colorPalette.muted", + "color": "colorPalette.fg" + }, + "_complete": { + "bg": "colorPalette.emphasized", + "color": "colorPalette.fg" + } + }, + "separator": { + "_complete": { + "bg": "colorPalette.emphasized" + } + } + } + }, + "size": { + "xs": { + "root": { + "gap": "2.5" + }, + "list": { + "--steps-size": "sizes.6", + "--steps-icon-size": "sizes.3.5", + "textStyle": "xs" + }, + "title": { + "textStyle": "sm" + } + }, + "sm": { + "root": { + "gap": "3" + }, + "list": { + "--steps-size": "sizes.8", + "--steps-icon-size": "sizes.4", + "textStyle": "xs" + }, + "title": { + "textStyle": "sm" + } + }, + "md": { + "root": { + "gap": "4" + }, + "list": { + "--steps-size": "sizes.10", + "--steps-icon-size": "sizes.4", + "textStyle": "sm" + }, + "title": { + "textStyle": "sm" + } + }, + "lg": { + "root": { + "gap": "6" + }, + "list": { + "--steps-size": "sizes.11", + "--steps-icon-size": "sizes.5", + "textStyle": "md" + }, + "title": { + "textStyle": "md" + } + } + } + }, + "defaultVariants": { + "size": "md", + "variant": "solid", + "orientation": "horizontal" + } + }, + "switch": { + "slots": [ + "root", + "label", + "control", + "thumb", + "indicator" + ], + "className": "chakra-switch", + "base": { + "root": { + "display": "inline-flex", + "gap": "2.5", + "alignItems": "center", + "position": "relative", + "verticalAlign": "middle", + "--switch-diff": "calc(var(--switch-width) - var(--switch-height))", + "--switch-x": { + "base": "var(--switch-diff)", + "_rtl": "calc(var(--switch-diff) * -1)" + } + }, + "label": { + "lineHeight": "1", + "userSelect": "none", + "fontSize": "sm", + "fontWeight": "medium", + "_disabled": { + "opacity": "0.5" + } + }, + "indicator": { + "position": "absolute", + "height": "var(--switch-height)", + "width": "var(--switch-height)", + "fontSize": "var(--switch-indicator-font-size)", + "fontWeight": "medium", + "flexShrink": 0, + "userSelect": "none", + "display": "grid", + "placeContent": "center", + "transition": "inset-inline-start 0.12s ease", + "insetInlineStart": "calc(var(--switch-x) - 2px)", + "_checked": { + "insetInlineStart": "2px" + } + }, + "control": { + "display": "inline-flex", + "gap": "0.5rem", + "flexShrink": 0, + "justifyContent": "flex-start", + "cursor": "switch", + "borderRadius": "full", + "position": "relative", + "width": "var(--switch-width)", + "height": "var(--switch-height)", + "_disabled": { + "opacity": "0.5", + "cursor": "not-allowed" + }, + "_invalid": { + "outline": "2px solid", + "outlineColor": "border.error", + "outlineOffset": "2px" + } + }, + "thumb": { + "display": "flex", + "alignItems": "center", + "justifyContent": "center", + "flexShrink": 0, + "transitionProperty": "translate", + "transitionDuration": "fast", + "borderRadius": "inherit", + "_checked": { + "translate": "var(--switch-x) 0" + } + } + }, + "variants": { + "variant": { + "solid": { + "control": { + "borderRadius": "full", + "bg": "bg.emphasized", + "focusVisibleRing": "outside", + "_checked": { + "bg": "colorPalette.solid" + } + }, + "thumb": { + "bg": "white", + "width": "var(--switch-height)", + "height": "var(--switch-height)", + "scale": "0.8", + "boxShadow": "sm", + "_checked": { + "bg": "colorPalette.contrast" + } + } + }, + "raised": { + "control": { + "borderRadius": "full", + "height": "calc(var(--switch-height) / 2)", + "bg": "bg.muted", + "boxShadow": "inset", + "_checked": { + "bg": "colorPalette.solid/60" + } + }, + "thumb": { + "width": "var(--switch-height)", + "height": "var(--switch-height)", + "position": "relative", + "top": "calc(var(--switch-height) * -0.25)", + "bg": "white", + "boxShadow": "xs", + "focusVisibleRing": "outside", + "_checked": { + "bg": "colorPalette.solid" + } + } + } + }, + "size": { + "xs": { + "root": { + "--switch-width": "sizes.6", + "--switch-height": "sizes.3", + "--switch-indicator-font-size": "fontSizes.xs" + } + }, + "sm": { + "root": { + "--switch-width": "sizes.8", + "--switch-height": "sizes.4", + "--switch-indicator-font-size": "fontSizes.xs" + } + }, + "md": { + "root": { + "--switch-width": "sizes.10", + "--switch-height": "sizes.5", + "--switch-indicator-font-size": "fontSizes.sm" + } + }, + "lg": { + "root": { + "--switch-width": "sizes.12", + "--switch-height": "sizes.6", + "--switch-indicator-font-size": "fontSizes.md" + } + } + } + }, + "defaultVariants": { + "variant": "solid", + "size": "md" + } + }, + "table": { + "className": "chakra-table", + "slots": [ + "root", + "header", + "body", + "row", + "columnHeader", + "cell", + "footer", + "caption" + ], + "base": { + "root": { + "fontVariantNumeric": "lining-nums tabular-nums", + "borderCollapse": "collapse", + "width": "full", + "textAlign": "start", + "verticalAlign": "top" + }, + "row": { + "_selected": { + "bg": "colorPalette.subtle" + } + }, + "cell": { + "textAlign": "start", + "alignItems": "center" + }, + "columnHeader": { + "fontWeight": "medium", + "textAlign": "start", + "color": "fg" + }, + "caption": { + "fontWeight": "medium", + "textStyle": "xs" + }, + "footer": { + "fontWeight": "medium" + } + }, + "variants": { + "interactive": { + "true": { + "body": { + "& tr": { + "_hover": { + "bg": "colorPalette.subtle" + } + } + } + } + }, + "stickyHeader": { + "true": { + "header": { + "& :where(tr)": { + "top": "var(--table-sticky-offset, 0)", + "position": "sticky", + "zIndex": 1 + } + } + } + }, + "striped": { + "true": { + "row": { + "&:nth-of-type(odd) td": { + "bg": "bg.muted" + } + } + } + }, + "showColumnBorder": { + "true": { + "columnHeader": { + "&:not(:last-of-type)": { + "borderInlineEndWidth": "1px" + } + }, + "cell": { + "&:not(:last-of-type)": { + "borderInlineEndWidth": "1px" + } + } + } + }, + "variant": { + "line": { + "columnHeader": { + "borderBottomWidth": "1px" + }, + "cell": { + "borderBottomWidth": "1px" + }, + "row": { + "bg": "bg" + } + }, + "outline": { + "root": { + "boxShadow": "0 0 0 1px {colors.border}", + "overflow": "hidden" + }, + "columnHeader": { + "borderBottomWidth": "1px" + }, + "header": { + "bg": "bg.muted" + }, + "row": { + "&:not(:last-of-type)": { + "borderBottomWidth": "1px" + } + }, + "footer": { + "borderTopWidth": "1px" + } + } + }, + "size": { + "sm": { + "root": { + "textStyle": "sm" + }, + "columnHeader": { + "px": "2", + "py": "2" + }, + "cell": { + "px": "2", + "py": "2" + } + }, + "md": { + "root": { + "textStyle": "sm" + }, + "columnHeader": { + "px": "3", + "py": "3" + }, + "cell": { + "px": "3", + "py": "3" + } + }, + "lg": { + "root": { + "textStyle": "md" + }, + "columnHeader": { + "px": "4", + "py": "3" + }, + "cell": { + "px": "4", + "py": "3" + } + } + } + }, + "defaultVariants": { + "variant": "line", + "size": "md" + } + }, + "tabs": { + "slots": [ + "root", + "trigger", + "list", + "content", + "contentGroup", + "indicator" + ], + "className": "chakra-tabs", + "base": { + "root": { + "--tabs-trigger-radius": "radii.l2", + "position": "relative", + "_horizontal": { + "display": "block" + }, + "_vertical": { + "display": "flex" + } + }, + "list": { + "display": "inline-flex", + "position": "relative", + "isolation": "isolate", + "--tabs-indicator-shadow": "shadows.xs", + "--tabs-indicator-bg": "colors.bg", + "minH": "var(--tabs-height)", + "_horizontal": { + "flexDirection": "row" + }, + "_vertical": { + "flexDirection": "column" + } + }, + "trigger": { + "outline": "0", + "minW": "var(--tabs-height)", + "height": "var(--tabs-height)", + "display": "flex", + "alignItems": "center", + "fontWeight": "medium", + "position": "relative", + "cursor": "button", + "gap": "2", + "_focusVisible": { + "zIndex": 1, + "outline": "2px solid", + "outlineColor": "colorPalette.focusRing" + }, + "_disabled": { + "cursor": "not-allowed", + "opacity": 0.5 + } + }, + "content": { + "focusVisibleRing": "inside", + "_horizontal": { + "width": "100%", + "pt": "var(--tabs-content-padding)" + }, + "_vertical": { + "height": "100%", + "ps": "var(--tabs-content-padding)" + } + }, + "indicator": { + "width": "var(--width)", + "height": "var(--height)", + "borderRadius": "var(--tabs-indicator-radius)", + "bg": "var(--tabs-indicator-bg)", + "shadow": "var(--tabs-indicator-shadow)", + "zIndex": -1 + } + }, + "variants": { + "fitted": { + "true": { + "list": { + "display": "flex" + }, + "trigger": { + "flex": 1, + "textAlign": "center", + "justifyContent": "center" + } + } + }, + "justify": { + "start": { + "list": { + "justifyContent": "flex-start" + } + }, + "center": { + "list": { + "justifyContent": "center" + } + }, + "end": { + "list": { + "justifyContent": "flex-end" + } + } + }, + "size": { + "sm": { + "root": { + "--tabs-height": "sizes.9", + "--tabs-content-padding": "spacing.3" + }, + "trigger": { + "py": "1", + "px": "3", + "textStyle": "sm" + } + }, + "md": { + "root": { + "--tabs-height": "sizes.10", + "--tabs-content-padding": "spacing.4" + }, + "trigger": { + "py": "2", + "px": "4", + "textStyle": "sm" + } + }, + "lg": { + "root": { + "--tabs-height": "sizes.11", + "--tabs-content-padding": "spacing.4.5" + }, + "trigger": { + "py": "2", + "px": "4.5", + "textStyle": "md" + } + } + }, + "variant": { + "line": { + "list": { + "display": "flex", + "borderColor": "border", + "_horizontal": { + "borderBottomWidth": "1px" + }, + "_vertical": { + "borderEndWidth": "1px" + } + }, + "trigger": { + "color": "fg.muted", + "_disabled": { + "_active": { + "bg": "initial" + } + }, + "_selected": { + "color": "fg", + "_horizontal": { + "layerStyle": "indicator.bottom", + "--indicator-offset-y": "-1px", + "--indicator-color": "colors.colorPalette.solid" + }, + "_vertical": { + "layerStyle": "indicator.end", + "--indicator-offset-x": "-1px" + } + } + } + }, + "subtle": { + "trigger": { + "borderRadius": "var(--tabs-trigger-radius)", + "color": "fg.muted", + "_selected": { + "bg": "colorPalette.subtle", + "color": "colorPalette.fg" + } + } + }, + "enclosed": { + "list": { + "bg": "bg.muted", + "padding": "1", + "borderRadius": "l3", + "minH": "calc(var(--tabs-height) - 4px)" + }, + "trigger": { + "justifyContent": "center", + "color": "fg.muted", + "borderRadius": "var(--tabs-trigger-radius)", + "_selected": { + "bg": "bg", + "color": "colorPalette.fg", + "shadow": "xs" + } + } + }, + "outline": { + "list": { + "--line-thickness": "1px", + "--line-offset": "calc(var(--line-thickness) * -1)", + "borderColor": "border", + "display": "flex", + "_horizontal": { + "_before": { + "content": "\"\"", + "position": "absolute", + "bottom": "0px", + "width": "100%", + "borderBottomWidth": "var(--line-thickness)", + "borderBottomColor": "border" + } + }, + "_vertical": { + "_before": { + "content": "\"\"", + "position": "absolute", + "insetInline": "var(--line-offset)", + "height": "calc(100% - calc(var(--line-thickness) * 2))", + "borderEndWidth": "var(--line-thickness)", + "borderEndColor": "border" + } + } + }, + "trigger": { + "color": "fg.muted", + "borderWidth": "1px", + "borderColor": "transparent", + "_selected": { + "bg": "currentBg", + "color": "colorPalette.fg" + }, + "_horizontal": { + "borderTopRadius": "var(--tabs-trigger-radius)", + "marginBottom": "var(--line-offset)", + "marginEnd": { + "_notLast": "var(--line-offset)" + }, + "_selected": { + "borderColor": "border", + "borderBottomColor": "transparent" + } + }, + "_vertical": { + "borderStartRadius": "var(--tabs-trigger-radius)", + "marginEnd": "var(--line-offset)", + "marginBottom": { + "_notLast": "var(--line-offset)" + }, + "_selected": { + "borderColor": "border", + "borderEndColor": "transparent" + } + } + } + }, + "plain": { + "trigger": { + "color": "fg.muted", + "_selected": { + "color": "colorPalette.fg" + }, + "borderRadius": "var(--tabs-trigger-radius)", + "&[data-selected][data-ssr]": { + "bg": "var(--tabs-indicator-bg)", + "shadow": "var(--tabs-indicator-shadow)", + "borderRadius": "var(--tabs-indicator-radius)" + } + } + } + } + }, + "defaultVariants": { + "size": "md", + "variant": "line" + } + }, + "tag": { + "slots": [ + "root", + "label", + "closeTrigger", + "startElement", + "endElement" + ], + "className": "chakra-tag", + "base": { + "root": { + "display": "inline-flex", + "alignItems": "center", + "verticalAlign": "top", + "maxWidth": "100%", + "userSelect": "none", + "borderRadius": "l2", + "focusVisibleRing": "outside" + }, + "label": { + "lineClamp": "1" + }, + "closeTrigger": { + "display": "flex", + "alignItems": "center", + "justifyContent": "center", + "outline": "0", + "borderRadius": "l1", + "color": "currentColor", + "focusVisibleRing": "inside", + "focusRingWidth": "2px" + }, + "startElement": { + "flexShrink": 0, + "boxSize": "var(--tag-element-size)", + "ms": "var(--tag-element-offset)", + "&:has([data-scope=avatar])": { + "boxSize": "var(--tag-avatar-size)", + "ms": "calc(var(--tag-element-offset) * 1.5)" + }, + "_icon": { + "boxSize": "100%" + } + }, + "endElement": { + "flexShrink": 0, + "boxSize": "var(--tag-element-size)", + "me": "var(--tag-element-offset)", + "_icon": { + "boxSize": "100%" + }, + "&:has(button)": { + "ms": "calc(var(--tag-element-offset) * -1)" + } + } + }, + "variants": { + "size": { + "sm": { + "root": { + "px": "1.5", + "minH": "4.5", + "gap": "1", + "--tag-avatar-size": "spacing.3", + "--tag-element-size": "spacing.3", + "--tag-element-offset": "-2px" + }, + "label": { + "textStyle": "xs" + } + }, + "md": { + "root": { + "px": "1.5", + "minH": "5", + "gap": "1", + "--tag-avatar-size": "spacing.3.5", + "--tag-element-size": "spacing.3.5", + "--tag-element-offset": "-2px" + }, + "label": { + "textStyle": "xs" + } + }, + "lg": { + "root": { + "px": "2", + "minH": "6", + "gap": "1.5", + "--tag-avatar-size": "spacing.4.5", + "--tag-element-size": "spacing.4", + "--tag-element-offset": "-3px" + }, + "label": { + "textStyle": "sm" + } + }, + "xl": { + "root": { + "px": "2.5", + "minH": "8", + "gap": "1.5", + "--tag-avatar-size": "spacing.6", + "--tag-element-size": "spacing.4.5", + "--tag-element-offset": "-4px" + }, + "label": { + "textStyle": "sm" + } + } + }, + "variant": { + "subtle": { + "root": { + "bg": "colorPalette.subtle", + "color": "colorPalette.fg" + } + }, + "solid": { + "root": { + "bg": "colorPalette.solid", + "color": "colorPalette.contrast" + } + }, + "outline": { + "root": { + "color": "colorPalette.fg", + "shadow": "inset 0 0 0px 1px var(--shadow-color)", + "shadowColor": "colorPalette.muted" + } + }, + "surface": { + "root": { + "bg": "colorPalette.subtle", + "color": "colorPalette.fg", + "shadow": "inset 0 0 0px 1px var(--shadow-color)", + "shadowColor": "colorPalette.muted" + } + } + } + }, + "defaultVariants": { + "size": "md", + "variant": "surface" + } + }, + "toast": { + "slots": [ + "root", + "title", + "description", + "indicator", + "closeTrigger", + "actionTrigger" + ], + "className": "chakra-toast", + "base": { + "root": { + "width": "full", + "display": "flex", + "alignItems": "flex-start", + "position": "relative", + "gap": "3", + "py": "4", + "ps": "4", + "pe": "6", + "borderRadius": "l2", + "translate": "var(--x) var(--y)", + "scale": "var(--scale)", + "zIndex": "var(--z-index)", + "height": "var(--height)", + "opacity": "var(--opacity)", + "willChange": "translate, opacity, scale", + "transition": "translate 400ms, scale 400ms, opacity 400ms, height 400ms, box-shadow 200ms", + "transitionTimingFunction": "cubic-bezier(0.21, 1.02, 0.73, 1)", + "_closed": { + "transition": "translate 400ms, scale 400ms, opacity 200ms", + "transitionTimingFunction": "cubic-bezier(0.06, 0.71, 0.55, 1)" + }, + "bg": "bg.panel", + "color": "fg", + "boxShadow": "xl", + "--toast-trigger-bg": "colors.bg.muted", + "&[data-type=warning]": { + "bg": "orange.solid", + "color": "orange.contrast", + "--toast-trigger-bg": "{white/10}", + "--toast-border-color": "{white/40}" + }, + "&[data-type=success]": { + "bg": "green.solid", + "color": "green.contrast", + "--toast-trigger-bg": "{white/10}", + "--toast-border-color": "{white/40}" + }, + "&[data-type=error]": { + "bg": "red.solid", + "color": "red.contrast", + "--toast-trigger-bg": "{white/10}", + "--toast-border-color": "{white/40}" + } + }, + "title": { + "fontWeight": "medium", + "textStyle": "sm", + "marginEnd": "2" + }, + "description": { + "display": "inline", + "textStyle": "sm", + "opacity": "0.8" + }, + "indicator": { + "flexShrink": "0", + "boxSize": "5" + }, + "actionTrigger": { + "textStyle": "sm", + "fontWeight": "medium", + "height": "8", + "px": "3", + "borderRadius": "l2", + "alignSelf": "center", + "borderWidth": "1px", + "borderColor": "var(--toast-border-color, inherit)", + "transition": "background 200ms", + "_hover": { + "bg": "var(--toast-trigger-bg)" + } + }, + "closeTrigger": { + "position": "absolute", + "top": "1", + "insetEnd": "1", + "padding": "1", + "display": "inline-flex", + "alignItems": "center", + "justifyContent": "center", + "color": "{currentColor/60}", + "borderRadius": "l2", + "textStyle": "md", + "transition": "background 200ms" + } + } + }, + "tooltip": { + "slots": [ + "trigger", + "arrow", + "arrowTip", + "positioner", + "content" + ], + "className": "chakra-tooltip", + "base": { + "content": { + "--tooltip-bg": "colors.bg.inverted", + "bg": "var(--tooltip-bg)", + "color": "fg.inverted", + "px": "2.5", + "py": "1", + "borderRadius": "l2", + "fontWeight": "medium", + "textStyle": "xs", + "boxShadow": "md", + "maxW": "xs", + "zIndex": "tooltip", + "transformOrigin": "var(--transform-origin)", + "_open": { + "animationStyle": "scale-fade-in", + "animationDuration": "fast" + }, + "_closed": { + "animationStyle": "scale-fade-out", + "animationDuration": "fast" + } + }, + "arrow": { + "--arrow-size": "sizes.2", + "--arrow-background": "var(--tooltip-bg)" + }, + "arrowTip": { + "borderTopWidth": "1px", + "borderInlineStartWidth": "1px", + "borderColor": "var(--tooltip-bg)" + } + } + }, + "status": { + "className": "chakra-status", + "slots": [ + "root", + "indicator" + ], + "base": { + "root": { + "display": "inline-flex", + "alignItems": "center", + "gap": "2" + }, + "indicator": { + "width": "0.64em", + "height": "0.64em", + "flexShrink": 0, + "borderRadius": "full", + "forcedColorAdjust": "none", + "bg": "colorPalette.solid" + } + }, + "variants": { + "size": { + "sm": { + "root": { + "textStyle": "xs" + } + }, + "md": { + "root": { + "textStyle": "sm" + } + }, + "lg": { + "root": { + "textStyle": "md" + } + } + } + }, + "defaultVariants": { + "size": "md" + } + }, + "timeline": { + "slots": [ + "root", + "item", + "content", + "separator", + "indicator", + "connector", + "title", + "description" + ], + "className": "chakra-timeline", + "base": { + "root": { + "display": "flex", + "flexDirection": "column", + "width": "full", + "--timeline-thickness": "1px", + "--timeline-gutter": "4px" + }, + "item": { + "display": "flex", + "position": "relative", + "alignItems": "flex-start", + "flexShrink": 0, + "gap": "4", + "_last": { + "& :where(.chakra-timeline__separator)": { + "display": "none" + } + } + }, + "separator": { + "position": "absolute", + "borderStartWidth": "var(--timeline-thickness)", + "ms": "calc(-1 * var(--timeline-thickness) / 2)", + "insetInlineStart": "calc(var(--timeline-indicator-size) / 2)", + "insetBlock": "0", + "borderColor": "border" + }, + "indicator": { + "outline": "2px solid {colors.bg}", + "position": "relative", + "flexShrink": "0", + "boxSize": "var(--timeline-indicator-size)", + "fontSize": "var(--timeline-font-size)", + "display": "flex", + "alignItems": "center", + "justifyContent": "center", + "borderRadius": "full", + "fontWeight": "medium" + }, + "connector": { + "alignSelf": "stretch", + "position": "relative" + }, + "content": { + "pb": "6", + "display": "flex", + "flexDirection": "column", + "width": "full", + "gap": "2" + }, + "title": { + "display": "flex", + "fontWeight": "medium", + "flexWrap": "wrap", + "gap": "1.5", + "alignItems": "center", + "mt": "var(--timeline-margin)" + }, + "description": { + "color": "fg.muted", + "textStyle": "xs" + } + }, + "variants": { + "variant": { + "subtle": { + "indicator": { + "bg": "colorPalette.muted" + } + }, + "solid": { + "indicator": { + "bg": "colorPalette.solid", + "color": "colorPalette.contrast" + } + }, + "outline": { + "indicator": { + "bg": "currentBg", + "borderWidth": "1px", + "borderColor": "colorPalette.muted" + } + }, + "plain": {} + }, + "size": { + "sm": { + "root": { + "--timeline-indicator-size": "sizes.4", + "--timeline-font-size": "fontSizes.2xs" + }, + "title": { + "textStyle": "xs" + } + }, + "md": { + "root": { + "--timeline-indicator-size": "sizes.5", + "--timeline-font-size": "fontSizes.xs" + }, + "title": { + "textStyle": "sm" + } + }, + "lg": { + "root": { + "--timeline-indicator-size": "sizes.6", + "--timeline-font-size": "fontSizes.xs" + }, + "title": { + "mt": "0.5", + "textStyle": "sm" + } + }, + "xl": { + "root": { + "--timeline-indicator-size": "sizes.8", + "--timeline-font-size": "fontSizes.sm" + }, + "title": { + "mt": "1.5", + "textStyle": "sm" + } + } + } + }, + "defaultVariants": { + "size": "md", + "variant": "solid" + } + }, + "colorPicker": { + "className": "colorPicker", + "slots": [ + "root", + "label", + "control", + "trigger", + "positioner", + "content", + "area", + "areaThumb", + "valueText", + "areaBackground", + "channelSlider", + "channelSliderLabel", + "channelSliderTrack", + "channelSliderThumb", + "channelSliderValueText", + "channelInput", + "transparencyGrid", + "swatchGroup", + "swatchTrigger", + "swatchIndicator", + "swatch", + "eyeDropperTrigger", + "formatTrigger", + "formatSelect", + "view" + ], + "base": { + "root": { + "display": "flex", + "flexDirection": "column", + "gap": "1.5" + }, + "label": { + "color": "fg", + "fontWeight": "medium", + "textStyle": "sm" + }, + "valueText": { + "textAlign": "start" + }, + "control": { + "display": "flex", + "alignItems": "center", + "flexDirection": "row", + "gap": "2", + "position": "relative" + }, + "swatchTrigger": { + "display": "flex", + "alignItems": "center", + "justifyContent": "center" + }, + "trigger": { + "display": "flex", + "alignItems": "center", + "justifyContent": "center", + "flexDirection": "row", + "flexShrink": "0", + "gap": "2", + "textStyle": "sm", + "minH": "var(--input-height)", + "minW": "var(--input-height)", + "px": "1", + "rounded": "l2", + "_disabled": { + "opacity": "0.5" + }, + "--focus-color": "colors.colorPalette.focusRing", + "&:focus-visible": { + "borderColor": "var(--focus-color)", + "outline": "1px solid var(--focus-color)" + }, + "&[data-fit-content]": { + "--input-height": "unset", + "px": "0", + "border": "0" + } + }, + "content": { + "display": "flex", + "flexDirection": "column", + "bg": "bg.panel", + "borderRadius": "l3", + "boxShadow": "lg", + "width": "64", + "p": "4", + "gap": "3", + "zIndex": "dropdown", + "_open": { + "animationStyle": "slide-fade-in", + "animationDuration": "fast" + }, + "_closed": { + "animationStyle": "slide-fade-out", + "animationDuration": "faster" + } + }, + "area": { + "height": "180px", + "borderRadius": "l2", + "overflow": "hidden" + }, + "areaThumb": { + "borderRadius": "full", + "height": "var(--thumb-size)", + "width": "var(--thumb-size)", + "borderWidth": "2px", + "borderColor": "white", + "shadow": "sm", + "focusVisibleRing": "mixed", + "focusRingColor": "white" + }, + "areaBackground": { + "height": "full" + }, + "channelSlider": { + "borderRadius": "l2", + "flex": "1" + }, + "channelSliderTrack": { + "height": "var(--slider-height)", + "borderRadius": "inherit", + "boxShadow": "inset 0 0 0 1px rgba(0,0,0,0.1)" + }, + "swatchGroup": { + "display": "flex", + "flexDirection": "row", + "flexWrap": "wrap", + "gap": "2" + }, + "swatch": { + "boxSize": "var(--swatch-size)", + "shadow": "inset 0 0 0 1px rgba(0, 0, 0, 0.1)", + "--checker-size": "8px", + "--checker-bg": "colors.bg", + "--checker-fg": "colors.bg.emphasized", + "background": "linear-gradient(var(--color), var(--color)), repeating-conic-gradient(var(--checker-fg) 0%, var(--checker-fg) 25%, var(--checker-bg) 0%, var(--checker-bg) 50%) 0% 50% / var(--checker-size) var(--checker-size) !important", + "display": "inline-flex", + "alignItems": "center", + "justifyContent": "center", + "flexShrink": "0", + "borderRadius": "l1" + }, + "swatchIndicator": { + "color": "white", + "rounded": "full" + }, + "channelSliderThumb": { + "borderRadius": "full", + "height": "var(--thumb-size)", + "width": "var(--thumb-size)", + "borderWidth": "2px", + "borderColor": "white", + "shadow": "sm", + "transform": "translate(-50%, -50%)", + "focusVisibleRing": "outside", + "focusRingOffset": "1px" + }, + "channelInput": { + "width": "100%", + "minWidth": "0", + "outline": "0", + "position": "relative", + "appearance": "none", + "textAlign": "start", + "borderRadius": "l2", + "_disabled": { + "layerStyle": "disabled" + }, + "height": "var(--input-height)", + "minW": "var(--input-height)", + "--focus-color": "colors.colorPalette.focusRing", + "--error-color": "colors.border.error", + "_invalid": { + "focusRingColor": "var(--error-color)", + "borderColor": "var(--error-color)" + }, + "&::-webkit-inner-spin-button, &::-webkit-outer-spin-button": { + "WebkitAppearance": "none", + "margin": 0 + } + }, + "formatSelect": { + "textStyle": "xs", + "textTransform": "uppercase", + "borderWidth": "1px", + "minH": "6", + "focusRing": "inside", + "rounded": "l2" + }, + "transparencyGrid": { + "borderRadius": "l2" + }, + "view": { + "display": "flex", + "flexDirection": "column", + "gap": "2" + } + }, + "variants": { + "size": { + "2xs": { + "channelInput": { + "textStyle": "xs", + "px": "2", + "--input-height": "sizes.7" + }, + "swatch": { + "--swatch-size": "sizes.4.5" + }, + "trigger": { + "--input-height": "sizes.7" + }, + "area": { + "--thumb-size": "sizes.3" + }, + "channelSlider": { + "--slider-height": "sizes.3", + "--thumb-size": "sizes.3" + } + }, + "xs": { + "channelInput": { + "textStyle": "xs", + "px": "2", + "--input-height": "sizes.8" + }, + "swatch": { + "--swatch-size": "sizes.5" + }, + "trigger": { + "--input-height": "sizes.8" + }, + "area": { + "--thumb-size": "sizes.3.5" + }, + "channelSlider": { + "--slider-height": "sizes.3.5", + "--thumb-size": "sizes.3.5" + } + }, + "sm": { + "channelInput": { + "textStyle": "sm", + "px": "2.5", + "--input-height": "sizes.9" + }, + "swatch": { + "--swatch-size": "sizes.6" + }, + "trigger": { + "--input-height": "sizes.9" + }, + "area": { + "--thumb-size": "sizes.3.5" + }, + "channelSlider": { + "--slider-height": "sizes.3.5", + "--thumb-size": "sizes.3.5" + } + }, + "md": { + "channelInput": { + "textStyle": "sm", + "px": "3", + "--input-height": "sizes.10" + }, + "swatch": { + "--swatch-size": "sizes.7" + }, + "trigger": { + "--input-height": "sizes.10" + }, + "area": { + "--thumb-size": "sizes.3.5" + }, + "channelSlider": { + "--slider-height": "sizes.3.5", + "--thumb-size": "sizes.3.5" + } + }, + "lg": { + "channelInput": { + "textStyle": "md", + "px": "4", + "--input-height": "sizes.11" + }, + "swatch": { + "--swatch-size": "sizes.7" + }, + "trigger": { + "--input-height": "sizes.11" + }, + "area": { + "--thumb-size": "sizes.3.5" + }, + "channelSlider": { + "--slider-height": "sizes.3.5", + "--thumb-size": "sizes.3.5" + } + }, + "xl": { + "channelInput": { + "textStyle": "md", + "px": "4.5", + "--input-height": "sizes.12" + }, + "swatch": { + "--swatch-size": "sizes.8" + }, + "trigger": { + "--input-height": "sizes.12" + }, + "area": { + "--thumb-size": "sizes.3.5" + }, + "channelSlider": { + "--slider-height": "sizes.3.5", + "--thumb-size": "sizes.3.5" + } + }, + "2xl": { + "channelInput": { + "textStyle": "lg", + "px": "5", + "--input-height": "sizes.16" + }, + "swatch": { + "--swatch-size": "sizes.10" + }, + "trigger": { + "--input-height": "sizes.16" + }, + "area": { + "--thumb-size": "sizes.3.5" + }, + "channelSlider": { + "--slider-height": "sizes.3.5", + "--thumb-size": "sizes.3.5" + } + } + }, + "variant": { + "outline": { + "channelInput": { + "bg": "transparent", + "borderWidth": "1px", + "borderColor": "border", + "focusVisibleRing": "inside" + }, + "trigger": { + "borderWidth": "1px" + } + }, + "subtle": { + "channelInput": { + "borderWidth": "1px", + "borderColor": "transparent", + "bg": "bg.muted", + "focusVisibleRing": "inside" + }, + "trigger": { + "borderWidth": "1px", + "borderColor": "transparent", + "bg": "bg.muted" + } + } + } + }, + "defaultVariants": { + "size": "md", + "variant": "outline" + } + }, + "qrCode": { + "slots": [ + "root", + "frame", + "pattern", + "overlay", + "downloadTrigger" + ], + "className": "chakra-qr-code", + "base": { + "root": { + "position": "relative", + "width": "fit-content", + "--qr-code-overlay-size": "calc(var(--qr-code-size) / 3)" + }, + "frame": { + "width": "var(--qr-code-size)", + "height": "var(--qr-code-size)", + "fill": "currentColor" + }, + "overlay": { + "display": "flex", + "alignItems": "center", + "justifyContent": "center", + "width": "var(--qr-code-overlay-size)", + "height": "var(--qr-code-overlay-size)", + "padding": "1", + "bg": "bg", + "rounded": "l1" + } + }, + "variants": { + "size": { + "2xs": { + "root": { + "--qr-code-size": "40px" + } + }, + "xs": { + "root": { + "--qr-code-size": "64px" + } + }, + "sm": { + "root": { + "--qr-code-size": "80px" + } + }, + "md": { + "root": { + "--qr-code-size": "120px" + } + }, + "lg": { + "root": { + "--qr-code-size": "160px" + } + }, + "xl": { + "root": { + "--qr-code-size": "200px" + } + }, + "2xl": { + "root": { + "--qr-code-size": "240px" + } + }, + "full": { + "root": { + "--qr-code-size": "100%" + } + } + } + }, + "defaultVariants": { + "size": "md" + } + } + }, + "textStyles": { + "2xs": { + "value": { + "fontSize": "2xs", + "lineHeight": "0.75rem" + } + }, + "xs": { + "value": { + "fontSize": "xs", + "lineHeight": "1rem" + } + }, + "sm": { + "value": { + "fontSize": "sm", + "lineHeight": "1.25rem" + } + }, + "md": { + "value": { + "fontSize": "md", + "lineHeight": "1.5rem" + } + }, + "lg": { + "value": { + "fontSize": "lg", + "lineHeight": "1.75rem" + } + }, + "xl": { + "value": { + "fontSize": "xl", + "lineHeight": "1.875rem" + } + }, + "2xl": { + "value": { + "fontSize": "2xl", + "lineHeight": "2rem" + } + }, + "3xl": { + "value": { + "fontSize": "3xl", + "lineHeight": "2.375rem" + } + }, + "4xl": { + "value": { + "fontSize": "4xl", + "lineHeight": "2.75rem", + "letterSpacing": "-0.025em" + } + }, + "5xl": { + "value": { + "fontSize": "5xl", + "lineHeight": "3.75rem", + "letterSpacing": "-0.025em" + } + }, + "6xl": { + "value": { + "fontSize": "6xl", + "lineHeight": "4.5rem", + "letterSpacing": "-0.025em" + } + }, + "7xl": { + "value": { + "fontSize": "7xl", + "lineHeight": "5.75rem", + "letterSpacing": "-0.025em" + } + }, + "none": { + "value": {} + } + }, + "layerStyles": { + "fill.muted": { + "value": { + "background": "colorPalette.muted", + "color": "colorPalette.fg" + } + }, + "fill.subtle": { + "value": { + "background": "colorPalette.subtle", + "color": "colorPalette.fg" + } + }, + "fill.surface": { + "value": { + "background": "colorPalette.subtle", + "color": "colorPalette.fg", + "boxShadow": "0 0 0px 1px var(--shadow-color)", + "boxShadowColor": "colorPalette.muted" + } + }, + "fill.solid": { + "value": { + "background": "colorPalette.solid", + "color": "colorPalette.contrast" + } + }, + "outline.subtle": { + "value": { + "color": "colorPalette.fg", + "boxShadow": "inset 0 0 0px 1px var(--shadow-color)", + "boxShadowColor": "colorPalette.subtle" + } + }, + "outline.solid": { + "value": { + "borderWidth": "1px", + "borderColor": "colorPalette.solid", + "color": "colorPalette.fg" + } + }, + "indicator.bottom": { + "value": { + "position": "relative", + "--indicator-color-fallback": "colors.colorPalette.solid", + "_before": { + "content": "\"\"", + "position": "absolute", + "bottom": "var(--indicator-offset-y, 0)", + "insetInline": "var(--indicator-offset-x, 0)", + "height": "var(--indicator-thickness, 2px)", + "background": "var(--indicator-color, var(--indicator-color-fallback))" + } + } + }, + "indicator.top": { + "value": { + "position": "relative", + "--indicator-color-fallback": "colors.colorPalette.solid", + "_before": { + "content": "\"\"", + "position": "absolute", + "top": "var(--indicator-offset-y, 0)", + "insetInline": "var(--indicator-offset-x, 0)", + "height": "var(--indicator-thickness, 2px)", + "background": "var(--indicator-color, var(--indicator-color-fallback))" + } + } + }, + "indicator.start": { + "value": { + "position": "relative", + "--indicator-color-fallback": "colors.colorPalette.solid", + "_before": { + "content": "\"\"", + "position": "absolute", + "insetInlineStart": "var(--indicator-offset-x, 0)", + "insetBlock": "var(--indicator-offset-y, 0)", + "width": "var(--indicator-thickness, 2px)", + "background": "var(--indicator-color, var(--indicator-color-fallback))" + } + } + }, + "indicator.end": { + "value": { + "position": "relative", + "--indicator-color-fallback": "colors.colorPalette.solid", + "_before": { + "content": "\"\"", + "position": "absolute", + "insetInlineEnd": "var(--indicator-offset-x, 0)", + "insetBlock": "var(--indicator-offset-y, 0)", + "width": "var(--indicator-thickness, 2px)", + "background": "var(--indicator-color, var(--indicator-color-fallback))" + } + } + }, + "disabled": { + "value": { + "opacity": "0.5", + "cursor": "not-allowed" + } + }, + "none": { + "value": {} + } + }, + "animationStyles": { + "slide-fade-in": { + "value": { + "transformOrigin": "var(--transform-origin)", + "&[data-placement^=top]": { + "animationName": "slide-from-bottom, fade-in" + }, + "&[data-placement^=bottom]": { + "animationName": "slide-from-top, fade-in" + }, + "&[data-placement^=left]": { + "animationName": "slide-from-right, fade-in" + }, + "&[data-placement^=right]": { + "animationName": "slide-from-left, fade-in" + } + } + }, + "slide-fade-out": { + "value": { + "transformOrigin": "var(--transform-origin)", + "&[data-placement^=top]": { + "animationName": "slide-to-bottom, fade-out" + }, + "&[data-placement^=bottom]": { + "animationName": "slide-to-top, fade-out" + }, + "&[data-placement^=left]": { + "animationName": "slide-to-right, fade-out" + }, + "&[data-placement^=right]": { + "animationName": "slide-to-left, fade-out" + } + } + }, + "scale-fade-in": { + "value": { + "transformOrigin": "var(--transform-origin)", + "animationName": "scale-in, fade-in" + } + }, + "scale-fade-out": { + "value": { + "transformOrigin": "var(--transform-origin)", + "animationName": "scale-out, fade-out" + } + } + } + } +}; \ No newline at end of file diff --git a/front/src/theme/foundations/colors.ts b/front/src/theme/foundations/colors.ts index ecb6f27..284f80a 100644 --- a/front/src/theme/foundations/colors.ts +++ b/front/src/theme/foundations/colors.ts @@ -1,17 +1,21 @@ + +type PandaColorModel = { + value: string; +} type ThemeModel = { - 50: string; - 100: string; - 200: string; - 300: string; - 400: string; - 500: string; - 600: string; - 700: string; - 800: string; - 900: string; + 50: PandaColorModel; + 100: PandaColorModel; + 200: PandaColorModel; + 300: PandaColorModel; + 400: PandaColorModel; + 500: PandaColorModel; + 600: PandaColorModel; + 700: PandaColorModel; + 800: PandaColorModel; + 900: PandaColorModel; }; -const back = { +const back: ThemeModel = { 50: { value: '#ebf4fa' }, 100: { value: '#d1dbe0' }, 200: { value: '#b6c2c9' }, @@ -24,7 +28,7 @@ const back = { 900: { value: '#020f12' }, }; -const brand = { +const brand: ThemeModel = { 50: { value: '#e3edff' }, 100: { value: '#b6c9fd' }, 200: { value: '#88a5f7' }, @@ -36,7 +40,7 @@ const brand = { 800: { value: '#02164a' }, 900: { value: '#00071e' }, }; -const normalText = { +const normalText: ThemeModel = { 50: { value: '#f2f2f2' }, 100: { value: '#d9d9d9' }, 200: { value: '#bfbfbf' }, @@ -49,7 +53,7 @@ const normalText = { 900: { value: '#0d0d0d' }, }; -const green = { +const green: ThemeModel = { 50: { value: '#f0fdf4' }, 100: { value: '#dcfce7' }, 200: { value: '#bbf7d0' }, @@ -61,7 +65,7 @@ const green = { 800: { value: '#166534' }, 900: { value: '#14532d' }, }; -const blue = { +const blue: ThemeModel = { 50: { value: '#eff6ff' }, 100: { value: '#dbeafe' }, 200: { value: '#bfdbfe' }, @@ -74,7 +78,7 @@ const blue = { 900: { value: '#1e3a8a' }, }; -const orange = { +const orange: ThemeModel = { 50: { value: '#fff7ed' }, 100: { value: '#ffedd5' }, 200: { value: '#fed7aa' }, @@ -86,7 +90,7 @@ const orange = { 800: { value: '#9a3412' }, 900: { value: '#7c2d12' }, }; -const red = { +const red: ThemeModel = { 50: { value: '#fef2f2' }, 100: { value: '#fee2e2' }, 200: { value: '#fecaca' }, diff --git a/front/src/theme/foundations/shadows.ts b/front/src/theme/foundations/shadows.ts index 7d0da71..507be20 100644 --- a/front/src/theme/foundations/shadows.ts +++ b/front/src/theme/foundations/shadows.ts @@ -1,21 +1,23 @@ +import { SystemConfig } from '@chakra-ui/react'; import { colors } from './colors'; -const createOutline = (colorScheme = 'gray') => - `0 0 0 3px ${colorScheme}.500/3`; +const createOutline = (colorScheme = 'gray') => { + return { value: `0 0 0 3px ${colorScheme}.500/3` }; +} export const shadows = { outline: createOutline('brand'), - 'outline-brand': '0 0 0 1px brand.900', - 'outline-gray': createOutline('gray'), - 'outline-over': `4px 4px 5px #00000088`, - 'outline-darkgray': `0 0 0 3px gray.500/8`, - 'outline-success': createOutline('success'), - 'outline-warning': createOutline('warning'), - 'outline-error': createOutline('error'), - 'outline-doing': createOutline('doing'), - 'outline-paused': createOutline('paused'), - layout: '0 0 24px 1px rgba(0, 0, 0, 0.05)', - smooth: 'inset 0px 0px 16px rgba(0, 0, 0, 0.05)', + // 'outline-brand': '0 0 0 1px brand.900', + // 'outline-gray': createOutline('gray'), + // 'outline-over': `4px 4px 5px #00000088`, + // 'outline-darkgray': `0 0 0 3px gray.500/8`, + // 'outline-success': createOutline('success'), + // 'outline-warning': createOutline('warning'), + // 'outline-error': createOutline('error'), + // 'outline-doing': createOutline('doing'), + // 'outline-paused': createOutline('paused'), + //layout: '0 0 24px 1px rgba(0, 0, 0, 0.05)', + //smooth: 'inset 0px 0px 16px rgba(0, 0, 0, 0.05)', // smooth-light is used for dark backgrounds - 'smooth-light': 'inset 0px 0px 16px rgba(255, 255, 255, 0.1)', + //'smooth-light': 'inset 0px 0px 16px rgba(255, 255, 255, 0.1)', }; diff --git a/front/src/theme/recipes/button.ts b/front/src/theme/recipes/button.ts index d257249..3a9d045 100644 --- a/front/src/theme/recipes/button.ts +++ b/front/src/theme/recipes/button.ts @@ -33,8 +33,12 @@ export const customVariant = ({ bg, bgHover, bgActive, color, colorHover, boxSha }; const buttonRecipe = defineRecipe({ + base: { + borderRadius: 0, + background: "green", + }, variants: { - theme: { + variant: { "@primary": customVariant({ bg: { _light: 'brand.600', _dark: 'brand.300' }, @@ -106,4 +110,8 @@ const buttonRecipe = defineRecipe({ }, }); + +console.log(`buttonRecipe: ${JSON.stringify(buttonRecipe, null, 2)}`); + + export default buttonRecipe; diff --git a/front/src/theme/recipes/index.ts b/front/src/theme/recipes/index.ts index 2e9794d..f921490 100644 --- a/front/src/theme/recipes/index.ts +++ b/front/src/theme/recipes/index.ts @@ -1,5 +1,5 @@ export { default as Badge } from './badge'; -export { default as Button } from './button'; +export { default as button } from './button'; export { default as Checkbox } from './checkbox'; export { default as Input } from './input'; //export { default as NumberInput } from './numberInput.ts_'; diff --git a/front/src/theme/styleguide/colors.stories.tsx b/front/src/theme/styleguide/colors.stories.tsx index 59e2f5b..1c8b94f 100644 --- a/front/src/theme/styleguide/colors.stories.tsx +++ b/front/src/theme/styleguide/colors.stories.tsx @@ -19,7 +19,7 @@ const Color = ({ children, ...rest }: FlexProps) => ( const Colors = ({ colorScheme = 'gray', ...rest }) => (