@vygruppen/spor-react 3.7.4 → 3.7.6

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.
@@ -1,5 +1,5 @@
1
1
 
2
- > @vygruppen/spor-react@3.7.4 build
2
+ > @vygruppen/spor-react@3.7.6 build
3
3
  > tsup src/index.tsx --dts --treeshake --format cjs,esm
4
4
 
5
5
  CLI Building entry: src/index.tsx
@@ -9,14 +9,14 @@
9
9
  CJS Build start
10
10
  ESM Build start
11
11
  DTS Build start
12
- "toZoned" and "toTime" are imported from external module "@internationalized/date" but never used in "dist/chunk-TMLJPE4H.mjs".
13
12
  "toZoned" and "toTime" are imported from external module "@internationalized/date" but never used in "dist/index.js".
13
+ "toZoned" and "toTime" are imported from external module "@internationalized/date" but never used in "dist/chunk-LQEO65MM.mjs".
14
+ CJS dist/index.js 539.15 KB
15
+ CJS ⚡️ Build success in 4394ms
14
16
  ESM dist/index.mjs 2.09 KB
15
- ESM dist/CountryCodeSelect-FLRREZ6C.mjs 1.19 KB
16
- ESM dist/chunk-TMLJPE4H.mjs 430.62 KB
17
- ESM ⚡️ Build success in 3863ms
18
- CJS dist/index.js 538.95 KB
19
- CJS ⚡️ Build success in 3864ms
20
- DTS ⚡️ Build success in 18236ms
21
- DTS dist/index.d.ts 256.42 KB
22
- DTS dist/index.d.mts 256.42 KB
17
+ ESM dist/CountryCodeSelect-IV4VKD4A.mjs 1.19 KB
18
+ ESM dist/chunk-LQEO65MM.mjs 430.76 KB
19
+ ESM ⚡️ Build success in 4394ms
20
+ DTS ⚡️ Build success in 19752ms
21
+ DTS dist/index.d.ts 256.31 KB
22
+ DTS dist/index.d.mts 256.31 KB
package/CHANGELOG.md CHANGED
@@ -1,5 +1,19 @@
1
1
  # @vygruppen/spor-react
2
2
 
3
+ ## 3.7.6
4
+
5
+ ### Patch Changes
6
+
7
+ - 9e78f2f0: BreadcrumbLink: Fix a bug where the current page got a different amount of padding than other breadcrumbs
8
+
9
+ ## 3.7.5
10
+
11
+ ### Patch Changes
12
+
13
+ - fde28bf1: Input: Changed active-color to mint for light mode
14
+ - 6778a4cf: Breadcrumb: Fix focus
15
+ - e9fdce39: Fix bug where you couldn't use FAB as a link
16
+
3
17
  ## 3.7.4
4
18
 
5
19
  ### Patch Changes
@@ -1,4 +1,4 @@
1
- import { createTexts, useTranslation, InfoSelect, Item } from './chunk-TMLJPE4H.mjs';
1
+ import { createTexts, useTranslation, InfoSelect, Item } from './chunk-LQEO65MM.mjs';
2
2
  import React from 'react';
3
3
  import { getSupportedCallingCodes } from 'awesome-phonenumber';
4
4
 
@@ -1,10 +1,10 @@
1
- import { forwardRef, Divider as Divider$1, Stack as Stack$1, Accordion as Accordion$1, Skeleton as Skeleton$1, useButtonGroup, Button as Button$1, Box, Center, ButtonGroup as ButtonGroup$1, IconButton as IconButton$1, useStyleConfig, Badge as Badge$1, Code as Code$1, Text, useMultiStyleConfig, PopoverAnchor, FormLabel, Flex, useFormControlContext, useBreakpointValue, PopoverContent, PopoverArrow, PopoverBody, FocusLock, Popover, InputGroup, PopoverTrigger, Portal, chakra, Checkbox as Checkbox$1, useCheckbox, FormControl as FormControl$1, InputLeftElement, Input as Input$1, InputRightElement, Select, useDisclosure, useControllableState, Radio as Radio$1, RadioGroup as RadioGroup$1, Switch as Switch$1, Textarea as Textarea$1, Link, ModalHeader as ModalHeader$1, useModalContext, DrawerContent as DrawerContent$1, Tabs as Tabs$1, Table as Table$1, defineStyleConfig as defineStyleConfig$1, createMultiStyleConfigHelpers as createMultiStyleConfigHelpers$1, AccordionItem, AccordionButton, AccordionIcon, AccordionPanel, SkeletonCircle as SkeletonCircle$1, SkeletonText as SkeletonText$1, Breadcrumb as Breadcrumb$1, BreadcrumbItem as BreadcrumbItem$1, BreadcrumbLink as BreadcrumbLink$1, Heading as Heading$1, CheckboxGroup as CheckboxGroup$1, List, ListItem, useColorModeValue, useFormControlProps, useFormControl, Drawer as Drawer$1, DrawerOverlay, DrawerCloseButton, DrawerBody, usePopoverContext, DarkMode, PopoverCloseButton, ChakraProvider, HStack, useToast as useToast$1, useInterval } from '@chakra-ui/react';
1
+ import { forwardRef, Divider as Divider$1, Stack as Stack$1, Accordion as Accordion$1, Skeleton as Skeleton$1, useButtonGroup, Button as Button$1, Box, Center, ButtonGroup as ButtonGroup$1, IconButton as IconButton$1, useMultiStyleConfig, useStyleConfig, Badge as Badge$1, Code as Code$1, Text, PopoverAnchor, FormLabel, Flex, useFormControlContext, useBreakpointValue, PopoverContent, PopoverArrow, PopoverBody, FocusLock, Popover, InputGroup, PopoverTrigger, Portal, chakra, Checkbox as Checkbox$1, useCheckbox, FormControl as FormControl$1, InputLeftElement, Input as Input$1, InputRightElement, Select, useDisclosure, useControllableState, Radio as Radio$1, RadioGroup as RadioGroup$1, Switch as Switch$1, Textarea as Textarea$1, Link, ModalHeader as ModalHeader$1, useModalContext, DrawerContent as DrawerContent$1, Tabs as Tabs$1, Table as Table$1, defineStyleConfig as defineStyleConfig$1, createMultiStyleConfigHelpers as createMultiStyleConfigHelpers$1, AccordionItem, AccordionButton, AccordionIcon, AccordionPanel, SkeletonCircle as SkeletonCircle$1, SkeletonText as SkeletonText$1, Breadcrumb as Breadcrumb$1, BreadcrumbItem as BreadcrumbItem$1, BreadcrumbLink as BreadcrumbLink$1, Heading as Heading$1, CheckboxGroup as CheckboxGroup$1, List, ListItem, useColorModeValue, useFormControlProps, useFormControl, Drawer as Drawer$1, DrawerOverlay, DrawerCloseButton, DrawerBody, usePopoverContext, DarkMode, PopoverCloseButton, ChakraProvider, HStack, useToast as useToast$1, useInterval } from '@chakra-ui/react';
2
2
  export { AccordionButton, AccordionIcon, AccordionItem, AccordionPanel, Box, Center, Collapse, Container, DarkMode, DrawerBody, DrawerCloseButton, DrawerFooter, DrawerOverlay, Fade, Flex, FormHelperText, Grid, GridItem, HStack, Image, Img, InputGroup, LightMode, ListItem, Modal, ModalBody, ModalCloseButton, ModalContent, ModalFooter, ModalOverlay, OrderedList, Popover, PopoverAnchor, PopoverArrow, PopoverBody, PopoverCloseButton, PopoverContent, PopoverFooter, PopoverHeader, PopoverTrigger, ScaleFade, SimpleGrid, Slide, SlideFade, Spacer, Tab, TabList, TabPanel, TabPanels, TableCaption, Tbody, Td, Tfoot, Th, Thead, Tr, UnorderedList, VStack, Wrap, WrapItem, extendTheme, useBreakpointValue, useClipboard, useColorMode, useColorModePreference, useColorModeValue, useControllableProp, useDisclosure, useMediaQuery, useMergeRefs, useOutsideClick, usePrefersReducedMotion, useTheme, useToken } from '@chakra-ui/react';
3
3
  import tokens10__default from '@vygruppen/spor-design-tokens';
4
4
  import * as tokens10 from '@vygruppen/spor-design-tokens';
5
5
  export { tokens10 as tokens };
6
6
  import * as React50 from 'react';
7
- import React50__default, { createContext, forwardRef as forwardRef$1, useRef, useState, useEffect, useId, Suspense, useMemo, useContext, useCallback } from 'react';
7
+ import React50__default, { createContext, useEffect, forwardRef as forwardRef$1, useRef, useState, useId, Suspense, useMemo, useContext, useCallback } from 'react';
8
8
  import { CloseFill30Icon, CloseFill24Icon, CloseFill18Icon, CalendarOutline24Icon, CloseOutline24Icon, SearchOutline24Icon, InformationFill24Icon, InformationFill18Icon, WarningFill24Icon, WarningFill18Icon, ErrorFill24Icon, ErrorFill18Icon, LinkOutOutline24Icon, DropdownRightFill18Icon, DropdownLeftFill18Icon, DropdownDownFill18Icon, DropdownDownFill24Icon, DropdownUpFill24Icon, ArrowRightFill18Icon, DropdownLeftFill24Icon, ArrowLeftOutline24Icon, ArrowRightOutline24Icon, ErrorOutline24Icon, AltTransportOutline24Icon, WarningOutline24Icon, SuccessOutline24Icon, InformationOutline24Icon, TrainFill18Icon, TrainFill24Icon, TrainFill30Icon, ExpressBusFill18Icon, ExpressBusFill24Icon, ExpressBusFill30Icon, BusFill18Icon, BusFill24Icon, BusFill30Icon, FerryFill18Icon, FerryFill24Icon, FerryFill30Icon, SubwayFill18Icon, SubwayFill24Icon, SubwayFill30Icon, TramFill18Icon, TramFill24Icon, TramFill30Icon, AltTransportFill18Icon, AltTransportFill24Icon, AltTransportFill30Icon, WalkFill18Icon, WalkFill24Icon, WalkFill30Icon } from '@vygruppen/spor-icon-react';
9
9
  import { inlineLoaderColorData, spinnerColorData, contentLoaderData, fullScreenLoaderWhiteData, inlineLoaderDarkData, spinnerDarkData, fullScreenLoaderBlackData, inlineLoaderLightData, spinnerLightData } from '@vygruppen/spor-loader';
10
10
  import { useLottie } from 'lottie-react';
@@ -1284,68 +1284,71 @@ var texts4 = createTexts({
1284
1284
  }
1285
1285
  });
1286
1286
  var MotionBox = motion(Box);
1287
- var FloatingActionButton = ({
1288
- children,
1289
- icon,
1290
- variant,
1291
- isTextVisible: externalIsTextVisible,
1292
- placement = "bottom right",
1293
- ...props
1294
- }) => {
1295
- const [isTextVisible, setIsTextVisible] = React50__default.useState(
1296
- externalIsTextVisible !== void 0 ? externalIsTextVisible : false
1297
- );
1298
- const scrollDirection = useScrollDirection();
1299
- useEffect(() => {
1300
- if (externalIsTextVisible !== void 0) {
1301
- return;
1302
- }
1303
- const id = window.setTimeout(
1304
- () => setIsTextVisible(scrollDirection !== "down"),
1305
- 1e3
1306
- );
1307
- return () => window.clearTimeout(id);
1308
- }, [scrollDirection, externalIsTextVisible]);
1309
- useEffect(() => {
1310
- setIsTextVisible(!!externalIsTextVisible);
1311
- }, [externalIsTextVisible]);
1312
- const style = useMultiStyleConfig("FloatingActionButton", {
1287
+ var FloatingActionButton = forwardRef(
1288
+ ({
1289
+ as,
1290
+ children,
1291
+ icon,
1313
1292
  variant,
1314
- isTextVisible,
1315
- placement
1316
- });
1317
- return /* @__PURE__ */ React50__default.createElement(
1318
- MotionBox,
1319
- {
1320
- __css: style.container,
1321
- as: "button",
1322
- "aria-label": children,
1323
- ...props
1324
- },
1325
- /* @__PURE__ */ React50__default.createElement(Box, { __css: style.icon }, icon),
1326
- /* @__PURE__ */ React50__default.createElement(
1293
+ isTextVisible: externalIsTextVisible,
1294
+ placement = "bottom right",
1295
+ ...props
1296
+ }, ref) => {
1297
+ const [isTextVisible, setIsTextVisible] = React50__default.useState(
1298
+ externalIsTextVisible !== void 0 ? externalIsTextVisible : false
1299
+ );
1300
+ const scrollDirection = useScrollDirection();
1301
+ useEffect(() => {
1302
+ if (externalIsTextVisible !== void 0) {
1303
+ return;
1304
+ }
1305
+ const id = window.setTimeout(
1306
+ () => setIsTextVisible(scrollDirection !== "down"),
1307
+ 1e3
1308
+ );
1309
+ return () => window.clearTimeout(id);
1310
+ }, [scrollDirection, externalIsTextVisible]);
1311
+ useEffect(() => {
1312
+ setIsTextVisible(!!externalIsTextVisible);
1313
+ }, [externalIsTextVisible]);
1314
+ const style = useMultiStyleConfig("FloatingActionButton", {
1315
+ variant,
1316
+ isTextVisible,
1317
+ placement
1318
+ });
1319
+ return /* @__PURE__ */ React50__default.createElement(
1327
1320
  MotionBox,
1328
1321
  {
1329
- animate: isTextVisible ? "show" : "hide",
1330
- initial: externalIsTextVisible ? "show" : "hide",
1331
- variants: {
1332
- show: {
1333
- opacity: 1,
1334
- width: "auto",
1335
- visibility: "visible"
1322
+ __css: style.container,
1323
+ "aria-label": children,
1324
+ ref,
1325
+ ...props
1326
+ },
1327
+ /* @__PURE__ */ React50__default.createElement(Box, { __css: style.icon }, icon),
1328
+ /* @__PURE__ */ React50__default.createElement(
1329
+ MotionBox,
1330
+ {
1331
+ animate: isTextVisible ? "show" : "hide",
1332
+ initial: externalIsTextVisible ? "show" : "hide",
1333
+ variants: {
1334
+ show: {
1335
+ opacity: 1,
1336
+ width: "auto",
1337
+ visibility: "visible"
1338
+ },
1339
+ hide: {
1340
+ opacity: 0,
1341
+ width: 0,
1342
+ visibility: "hidden"
1343
+ }
1336
1344
  },
1337
- hide: {
1338
- opacity: 0,
1339
- width: 0,
1340
- visibility: "hidden"
1341
- }
1345
+ __css: style.text
1342
1346
  },
1343
- __css: style.text
1344
- },
1345
- children
1346
- )
1347
- );
1348
- };
1347
+ children
1348
+ )
1349
+ );
1350
+ }
1351
+ );
1349
1352
  var useScrollDirection = () => {
1350
1353
  const [scrollDirection, setScrollDirection] = React50__default.useState(null);
1351
1354
  const lastScrollPosition = React50__default.useRef(
@@ -5087,7 +5090,7 @@ var texts14 = createTexts({
5087
5090
  sv: "Telefonnummer"
5088
5091
  }
5089
5092
  });
5090
- var LazyCountryCodeSelect = React50__default.lazy(() => import('./CountryCodeSelect-FLRREZ6C.mjs'));
5093
+ var LazyCountryCodeSelect = React50__default.lazy(() => import('./CountryCodeSelect-IV4VKD4A.mjs'));
5091
5094
  var Radio = forwardRef((props, ref) => {
5092
5095
  return /* @__PURE__ */ React50__default.createElement(Radio$1, { ...props, ref });
5093
5096
  });
@@ -11370,22 +11373,24 @@ var baseStyleLink2 = defineStyle((props) => ({
11370
11373
  color: "inherit",
11371
11374
  textDecoration: "none",
11372
11375
  textStyle: "xs",
11376
+ paddingX: 0.5,
11377
+ borderRadius: "xs",
11373
11378
  "&:not([aria-current=page])": {
11374
11379
  cursor: "pointer",
11375
- paddingX: 0.5,
11376
- borderRadius: "xs",
11377
11380
  _hover: {
11378
11381
  backgroundColor: mode("seaMist", "pine")(props)
11379
11382
  },
11380
- _focusVisible: {
11381
- boxShadow: getBoxShadowString({
11382
- borderColor: mode("greenHaze", "azure")(props),
11383
- borderWidth: 2
11384
- }),
11383
+ ...focusVisible({
11384
+ focus: {
11385
+ boxShadow: getBoxShadowString({
11386
+ borderColor: mode("greenHaze", "azure")(props),
11387
+ borderWidth: 2
11388
+ })
11389
+ },
11385
11390
  notFocus: {
11386
- notFocus: { boxShadow: "none" }
11391
+ boxShadow: "none"
11387
11392
  }
11388
- },
11393
+ }),
11389
11394
  _active: {
11390
11395
  backgroundColor: mode("mint", "whiteAlpha.200")(props)
11391
11396
  }
@@ -13087,7 +13092,7 @@ var config21 = helpers13.defineMultiStyleConfig({
13087
13092
  borderColor: mode("blackAlpha.400", "whiteAlpha.400")(props)
13088
13093
  }),
13089
13094
  _active: {
13090
- backgroundColor: mode("blackAlpha.100", "whiteAlpha.100")(props),
13095
+ backgroundColor: mode("mint", "whiteAlpha.100")(props),
13091
13096
  boxShadow: getBoxShadowString({
13092
13097
  borderColor: mode("blackAlpha.400", "whiteAlpha.400")(props)
13093
13098
  })
package/dist/index.d.mts CHANGED
@@ -1,4 +1,4 @@
1
- import { DividerProps as DividerProps$1, As, BoxProps, StackProps as StackProps$1, AccordionProps as AccordionProps$1, AccordionItemProps, BreadcrumbProps as BreadcrumbProps$1, ButtonProps as ButtonProps$1, ButtonGroupProps as ButtonGroupProps$1, IconButtonProps as IconButtonProps$1, ResponsiveValue, FlexProps, CheckboxProps as CheckboxProps$1, CheckboxGroupProps as CheckboxGroupProps$1, StackDirection, FormControlProps as FormControlProps$1, FormLabelProps as FormLabelProps$1, InputProps as InputProps$1, InputElementProps as InputElementProps$1, SelectProps, RadioProps as RadioProps$1, RadioGroupProps as RadioGroupProps$1, SwitchProps as SwitchProps$1, TextareaProps as TextareaProps$1, LinkProps as LinkProps$1, SkeletonTextProps as SkeletonTextProps$1, ModalHeaderProps as ModalHeaderProps$1, DrawerContentProps, DrawerProps as DrawerProps$1, PopoverProps, ChakraProviderProps, TabsProps as TabsProps$1, TableProps as TableProps$1, BadgeProps as BadgeProps$1, CodeProps as CodeProps$1, HeadingProps as HeadingProps$1, TextProps as TextProps$1 } from '@chakra-ui/react';
1
+ import { DividerProps as DividerProps$1, As, BoxProps, StackProps as StackProps$1, AccordionProps as AccordionProps$1, AccordionItemProps, BreadcrumbProps as BreadcrumbProps$1, ButtonProps as ButtonProps$1, ButtonGroupProps as ButtonGroupProps$1, IconButtonProps as IconButtonProps$1, ComponentWithAs, ResponsiveValue, FlexProps, CheckboxProps as CheckboxProps$1, CheckboxGroupProps as CheckboxGroupProps$1, StackDirection, FormControlProps as FormControlProps$1, FormLabelProps as FormLabelProps$1, InputProps as InputProps$1, InputElementProps as InputElementProps$1, SelectProps, RadioProps as RadioProps$1, RadioGroupProps as RadioGroupProps$1, SwitchProps as SwitchProps$1, TextareaProps as TextareaProps$1, LinkProps as LinkProps$1, SkeletonTextProps as SkeletonTextProps$1, ModalHeaderProps as ModalHeaderProps$1, DrawerContentProps, DrawerProps as DrawerProps$1, PopoverProps, ChakraProviderProps, TabsProps as TabsProps$1, TableProps as TableProps$1, BadgeProps as BadgeProps$1, CodeProps as CodeProps$1, HeadingProps as HeadingProps$1, TextProps as TextProps$1 } from '@chakra-ui/react';
2
2
  export { AccordionButton, AccordionButtonProps, AccordionIcon, AccordionItem, AccordionItemProps, AccordionPanel, AccordionPanelProps, Box, BoxProps, Center, CenterProps, Collapse, CollapseProps, Container, ContainerProps, DarkMode, DrawerBody, DrawerCloseButton, DrawerFooter, DrawerOverlay, DrawerProps, Fade, FadeProps, Flex, FlexProps, FormHelperText, Grid, GridItem, GridItemProps, GridProps, HStack, Image, ImageProps, Img, ImgProps, InputGroup, InputGroupProps, LightMode, ListItem, ListItemProps, ListProps, Modal, ModalBody, ModalBodyProps, ModalCloseButton, ModalContent, ModalContentProps, ModalFooter, ModalFooterProps, ModalOverlay, ModalOverlayProps, ModalProps, OrderedList, Popover, PopoverAnchor, PopoverArrow, PopoverArrowProps, PopoverBody, PopoverBodyProps, PopoverCloseButton, PopoverCloseButtonProps, PopoverContent, PopoverContentProps, PopoverFooter, PopoverFooterProps, PopoverHeader, PopoverHeaderProps, PopoverProps, PopoverTrigger, ScaleFade, ScaleFadeProps, SimpleGrid, SimpleGridProps, Slide, SlideFade, SlideFadeProps, SlideProps, Spacer, SpacerProps, Tab, TabList, TabListProps, TabPanel, TabPanelProps, TabPanels, TabPanelsProps, TabProps, TableBodyProps, TableCaption, TableCaptionProps, TableCellProps, TableColumnHeaderProps, TableFooterProps, TableHeadProps, TableRowProps, Tbody, Td, Tfoot, Th, Thead, Tr, UnorderedList, UseClipboardOptions, UseDisclosureProps, UseOutsideClickProps, VStack, Wrap, WrapItem, WrapItemProps, WrapProps, extendTheme, useBreakpointValue, useClipboard, useColorMode, useColorModePreference, useColorModeValue, useControllableProp, useDisclosure, useMediaQuery, useMergeRefs, useOutsideClick, usePrefersReducedMotion, useTheme, useToken } from '@chakra-ui/react';
3
3
  import tokens__default from '@vygruppen/spor-design-tokens';
4
4
  import * as tokens from '@vygruppen/spor-design-tokens';
@@ -411,7 +411,7 @@ type FloatingActionButtonProps = BoxProps & {
411
411
  * placement="bottom right"
412
412
  * />
413
413
  */
414
- declare const FloatingActionButton: ({ children, icon, variant, isTextVisible: externalIsTextVisible, placement, ...props }: FloatingActionButtonProps) => React__default.JSX.Element;
414
+ declare const FloatingActionButton: ComponentWithAs<ComponentWithAs<"a" | "button">, FloatingActionButtonProps>;
415
415
 
416
416
  type CardProps = Exclude<BoxProps, "size"> & {
417
417
  size?: "sm" | "lg";
@@ -2193,22 +2193,17 @@ declare const theme: {
2193
2193
  color: string;
2194
2194
  textDecoration: string;
2195
2195
  textStyle: string;
2196
+ paddingX: number;
2197
+ borderRadius: string;
2196
2198
  "&:not([aria-current=page])": {
2197
- cursor: string;
2198
- paddingX: number;
2199
- borderRadius: string;
2200
- _hover: {
2199
+ _active: {
2201
2200
  backgroundColor: string;
2202
2201
  };
2203
- _focusVisible: {
2204
- boxShadow: string;
2205
- notFocus: {
2206
- notFocus: {
2207
- boxShadow: string;
2208
- };
2209
- };
2210
- };
2211
- _active: {
2202
+ _focus: _chakra_ui_styled_system.SystemStyleObject;
2203
+ _focusVisible: _chakra_ui_styled_system.SystemStyleObject;
2204
+ "&[data-focus]:not([data-focus-visible])": _chakra_ui_styled_system.SystemStyleObject;
2205
+ cursor: string;
2206
+ _hover: {
2212
2207
  backgroundColor: string;
2213
2208
  };
2214
2209
  };
package/dist/index.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { DividerProps as DividerProps$1, As, BoxProps, StackProps as StackProps$1, AccordionProps as AccordionProps$1, AccordionItemProps, BreadcrumbProps as BreadcrumbProps$1, ButtonProps as ButtonProps$1, ButtonGroupProps as ButtonGroupProps$1, IconButtonProps as IconButtonProps$1, ResponsiveValue, FlexProps, CheckboxProps as CheckboxProps$1, CheckboxGroupProps as CheckboxGroupProps$1, StackDirection, FormControlProps as FormControlProps$1, FormLabelProps as FormLabelProps$1, InputProps as InputProps$1, InputElementProps as InputElementProps$1, SelectProps, RadioProps as RadioProps$1, RadioGroupProps as RadioGroupProps$1, SwitchProps as SwitchProps$1, TextareaProps as TextareaProps$1, LinkProps as LinkProps$1, SkeletonTextProps as SkeletonTextProps$1, ModalHeaderProps as ModalHeaderProps$1, DrawerContentProps, DrawerProps as DrawerProps$1, PopoverProps, ChakraProviderProps, TabsProps as TabsProps$1, TableProps as TableProps$1, BadgeProps as BadgeProps$1, CodeProps as CodeProps$1, HeadingProps as HeadingProps$1, TextProps as TextProps$1 } from '@chakra-ui/react';
1
+ import { DividerProps as DividerProps$1, As, BoxProps, StackProps as StackProps$1, AccordionProps as AccordionProps$1, AccordionItemProps, BreadcrumbProps as BreadcrumbProps$1, ButtonProps as ButtonProps$1, ButtonGroupProps as ButtonGroupProps$1, IconButtonProps as IconButtonProps$1, ComponentWithAs, ResponsiveValue, FlexProps, CheckboxProps as CheckboxProps$1, CheckboxGroupProps as CheckboxGroupProps$1, StackDirection, FormControlProps as FormControlProps$1, FormLabelProps as FormLabelProps$1, InputProps as InputProps$1, InputElementProps as InputElementProps$1, SelectProps, RadioProps as RadioProps$1, RadioGroupProps as RadioGroupProps$1, SwitchProps as SwitchProps$1, TextareaProps as TextareaProps$1, LinkProps as LinkProps$1, SkeletonTextProps as SkeletonTextProps$1, ModalHeaderProps as ModalHeaderProps$1, DrawerContentProps, DrawerProps as DrawerProps$1, PopoverProps, ChakraProviderProps, TabsProps as TabsProps$1, TableProps as TableProps$1, BadgeProps as BadgeProps$1, CodeProps as CodeProps$1, HeadingProps as HeadingProps$1, TextProps as TextProps$1 } from '@chakra-ui/react';
2
2
  export { AccordionButton, AccordionButtonProps, AccordionIcon, AccordionItem, AccordionItemProps, AccordionPanel, AccordionPanelProps, Box, BoxProps, Center, CenterProps, Collapse, CollapseProps, Container, ContainerProps, DarkMode, DrawerBody, DrawerCloseButton, DrawerFooter, DrawerOverlay, DrawerProps, Fade, FadeProps, Flex, FlexProps, FormHelperText, Grid, GridItem, GridItemProps, GridProps, HStack, Image, ImageProps, Img, ImgProps, InputGroup, InputGroupProps, LightMode, ListItem, ListItemProps, ListProps, Modal, ModalBody, ModalBodyProps, ModalCloseButton, ModalContent, ModalContentProps, ModalFooter, ModalFooterProps, ModalOverlay, ModalOverlayProps, ModalProps, OrderedList, Popover, PopoverAnchor, PopoverArrow, PopoverArrowProps, PopoverBody, PopoverBodyProps, PopoverCloseButton, PopoverCloseButtonProps, PopoverContent, PopoverContentProps, PopoverFooter, PopoverFooterProps, PopoverHeader, PopoverHeaderProps, PopoverProps, PopoverTrigger, ScaleFade, ScaleFadeProps, SimpleGrid, SimpleGridProps, Slide, SlideFade, SlideFadeProps, SlideProps, Spacer, SpacerProps, Tab, TabList, TabListProps, TabPanel, TabPanelProps, TabPanels, TabPanelsProps, TabProps, TableBodyProps, TableCaption, TableCaptionProps, TableCellProps, TableColumnHeaderProps, TableFooterProps, TableHeadProps, TableRowProps, Tbody, Td, Tfoot, Th, Thead, Tr, UnorderedList, UseClipboardOptions, UseDisclosureProps, UseOutsideClickProps, VStack, Wrap, WrapItem, WrapItemProps, WrapProps, extendTheme, useBreakpointValue, useClipboard, useColorMode, useColorModePreference, useColorModeValue, useControllableProp, useDisclosure, useMediaQuery, useMergeRefs, useOutsideClick, usePrefersReducedMotion, useTheme, useToken } from '@chakra-ui/react';
3
3
  import tokens__default from '@vygruppen/spor-design-tokens';
4
4
  import * as tokens from '@vygruppen/spor-design-tokens';
@@ -411,7 +411,7 @@ type FloatingActionButtonProps = BoxProps & {
411
411
  * placement="bottom right"
412
412
  * />
413
413
  */
414
- declare const FloatingActionButton: ({ children, icon, variant, isTextVisible: externalIsTextVisible, placement, ...props }: FloatingActionButtonProps) => React__default.JSX.Element;
414
+ declare const FloatingActionButton: ComponentWithAs<ComponentWithAs<"a" | "button">, FloatingActionButtonProps>;
415
415
 
416
416
  type CardProps = Exclude<BoxProps, "size"> & {
417
417
  size?: "sm" | "lg";
@@ -2193,22 +2193,17 @@ declare const theme: {
2193
2193
  color: string;
2194
2194
  textDecoration: string;
2195
2195
  textStyle: string;
2196
+ paddingX: number;
2197
+ borderRadius: string;
2196
2198
  "&:not([aria-current=page])": {
2197
- cursor: string;
2198
- paddingX: number;
2199
- borderRadius: string;
2200
- _hover: {
2199
+ _active: {
2201
2200
  backgroundColor: string;
2202
2201
  };
2203
- _focusVisible: {
2204
- boxShadow: string;
2205
- notFocus: {
2206
- notFocus: {
2207
- boxShadow: string;
2208
- };
2209
- };
2210
- };
2211
- _active: {
2202
+ _focus: _chakra_ui_styled_system.SystemStyleObject;
2203
+ _focusVisible: _chakra_ui_styled_system.SystemStyleObject;
2204
+ "&[data-focus]:not([data-focus-visible])": _chakra_ui_styled_system.SystemStyleObject;
2205
+ cursor: string;
2206
+ _hover: {
2212
2207
  backgroundColor: string;
2213
2208
  };
2214
2209
  };
package/dist/index.js CHANGED
@@ -782,68 +782,71 @@ var MotionBox; exports.FloatingActionButton = void 0; var useScrollDirection;
782
782
  var init_FloatingActionButton = __esm({
783
783
  "src/button/FloatingActionButton.tsx"() {
784
784
  MotionBox = framerMotion.motion(react.Box);
785
- exports.FloatingActionButton = ({
786
- children,
787
- icon,
788
- variant,
789
- isTextVisible: externalIsTextVisible,
790
- placement = "bottom right",
791
- ...props
792
- }) => {
793
- const [isTextVisible, setIsTextVisible] = React50__namespace.default.useState(
794
- externalIsTextVisible !== void 0 ? externalIsTextVisible : false
795
- );
796
- const scrollDirection = useScrollDirection();
797
- React50.useEffect(() => {
798
- if (externalIsTextVisible !== void 0) {
799
- return;
800
- }
801
- const id = window.setTimeout(
802
- () => setIsTextVisible(scrollDirection !== "down"),
803
- 1e3
804
- );
805
- return () => window.clearTimeout(id);
806
- }, [scrollDirection, externalIsTextVisible]);
807
- React50.useEffect(() => {
808
- setIsTextVisible(!!externalIsTextVisible);
809
- }, [externalIsTextVisible]);
810
- const style = react.useMultiStyleConfig("FloatingActionButton", {
785
+ exports.FloatingActionButton = react.forwardRef(
786
+ ({
787
+ as,
788
+ children,
789
+ icon,
811
790
  variant,
812
- isTextVisible,
813
- placement
814
- });
815
- return /* @__PURE__ */ React50__namespace.default.createElement(
816
- MotionBox,
817
- {
818
- __css: style.container,
819
- as: "button",
820
- "aria-label": children,
821
- ...props
822
- },
823
- /* @__PURE__ */ React50__namespace.default.createElement(react.Box, { __css: style.icon }, icon),
824
- /* @__PURE__ */ React50__namespace.default.createElement(
791
+ isTextVisible: externalIsTextVisible,
792
+ placement = "bottom right",
793
+ ...props
794
+ }, ref) => {
795
+ const [isTextVisible, setIsTextVisible] = React50__namespace.default.useState(
796
+ externalIsTextVisible !== void 0 ? externalIsTextVisible : false
797
+ );
798
+ const scrollDirection = useScrollDirection();
799
+ React50.useEffect(() => {
800
+ if (externalIsTextVisible !== void 0) {
801
+ return;
802
+ }
803
+ const id = window.setTimeout(
804
+ () => setIsTextVisible(scrollDirection !== "down"),
805
+ 1e3
806
+ );
807
+ return () => window.clearTimeout(id);
808
+ }, [scrollDirection, externalIsTextVisible]);
809
+ React50.useEffect(() => {
810
+ setIsTextVisible(!!externalIsTextVisible);
811
+ }, [externalIsTextVisible]);
812
+ const style = react.useMultiStyleConfig("FloatingActionButton", {
813
+ variant,
814
+ isTextVisible,
815
+ placement
816
+ });
817
+ return /* @__PURE__ */ React50__namespace.default.createElement(
825
818
  MotionBox,
826
819
  {
827
- animate: isTextVisible ? "show" : "hide",
828
- initial: externalIsTextVisible ? "show" : "hide",
829
- variants: {
830
- show: {
831
- opacity: 1,
832
- width: "auto",
833
- visibility: "visible"
820
+ __css: style.container,
821
+ "aria-label": children,
822
+ ref,
823
+ ...props
824
+ },
825
+ /* @__PURE__ */ React50__namespace.default.createElement(react.Box, { __css: style.icon }, icon),
826
+ /* @__PURE__ */ React50__namespace.default.createElement(
827
+ MotionBox,
828
+ {
829
+ animate: isTextVisible ? "show" : "hide",
830
+ initial: externalIsTextVisible ? "show" : "hide",
831
+ variants: {
832
+ show: {
833
+ opacity: 1,
834
+ width: "auto",
835
+ visibility: "visible"
836
+ },
837
+ hide: {
838
+ opacity: 0,
839
+ width: 0,
840
+ visibility: "hidden"
841
+ }
834
842
  },
835
- hide: {
836
- opacity: 0,
837
- width: 0,
838
- visibility: "hidden"
839
- }
843
+ __css: style.text
840
844
  },
841
- __css: style.text
842
- },
843
- children
844
- )
845
- );
846
- };
845
+ children
846
+ )
847
+ );
848
+ }
849
+ );
847
850
  useScrollDirection = () => {
848
851
  const [scrollDirection, setScrollDirection] = React50__namespace.default.useState(null);
849
852
  const lastScrollPosition = React50__namespace.default.useRef(
@@ -12867,6 +12870,7 @@ var init_breadcrumb2 = __esm({
12867
12870
  init_dist4();
12868
12871
  init_dist3();
12869
12872
  init_box_shadow_utils();
12873
+ init_focus_utils();
12870
12874
  ({ defineMultiStyleConfig: defineMultiStyleConfig27, definePartsStyle: definePartsStyle27 } = createMultiStyleConfigHelpers(breadcrumbAnatomy.keys));
12871
12875
  baseStyleLink2 = defineStyle((props) => ({
12872
12876
  transitionProperty: "common",
@@ -12876,22 +12880,24 @@ var init_breadcrumb2 = __esm({
12876
12880
  color: "inherit",
12877
12881
  textDecoration: "none",
12878
12882
  textStyle: "xs",
12883
+ paddingX: 0.5,
12884
+ borderRadius: "xs",
12879
12885
  "&:not([aria-current=page])": {
12880
12886
  cursor: "pointer",
12881
- paddingX: 0.5,
12882
- borderRadius: "xs",
12883
12887
  _hover: {
12884
12888
  backgroundColor: themeTools.mode("seaMist", "pine")(props)
12885
12889
  },
12886
- _focusVisible: {
12887
- boxShadow: getBoxShadowString({
12888
- borderColor: themeTools.mode("greenHaze", "azure")(props),
12889
- borderWidth: 2
12890
- }),
12890
+ ...focusVisible({
12891
+ focus: {
12892
+ boxShadow: getBoxShadowString({
12893
+ borderColor: themeTools.mode("greenHaze", "azure")(props),
12894
+ borderWidth: 2
12895
+ })
12896
+ },
12891
12897
  notFocus: {
12892
- notFocus: { boxShadow: "none" }
12898
+ boxShadow: "none"
12893
12899
  }
12894
- },
12900
+ }),
12895
12901
  _active: {
12896
12902
  backgroundColor: themeTools.mode("mint", "whiteAlpha.200")(props)
12897
12903
  }
@@ -14713,7 +14719,7 @@ var init_input2 = __esm({
14713
14719
  borderColor: themeTools.mode("blackAlpha.400", "whiteAlpha.400")(props)
14714
14720
  }),
14715
14721
  _active: {
14716
- backgroundColor: themeTools.mode("blackAlpha.100", "whiteAlpha.100")(props),
14722
+ backgroundColor: themeTools.mode("mint", "whiteAlpha.100")(props),
14717
14723
  boxShadow: getBoxShadowString({
14718
14724
  borderColor: themeTools.mode("blackAlpha.400", "whiteAlpha.400")(props)
14719
14725
  })
package/dist/index.mjs CHANGED
@@ -1 +1 @@
1
- export { Accordion, AccordionButton, AccordionIcon, AccordionItem, AccordionPanel, AttachedInputs, Badge, Box, Breadcrumb, BreadcrumbItem, BreadcrumbLink, Button, ButtonGroup, Card, CardSelect, Center, Checkbox, CheckboxGroup, ChoiceChip, ClosableAlert, CloseButton, Code, Collapse, ColorInlineLoader, ColorSpinner, Combobox, Container, ContentLoader, DarkFullScreenLoader, DarkInlineLoader, DarkMode, DarkSpinner, DatePicker, DateRangePicker, Divider, Drawer, DrawerBody, DrawerCloseButton, DrawerContent, DrawerFooter, ModalHeader as DrawerHeader, DrawerOverlay, Expandable, ExpandableAlert, ExpandableItem, Fade, Flex, FloatingActionButton, FormControl, FormErrorMessage, FormHelperText, FormLabel, Grid, GridItem, HStack, Heading, IconButton, Image, Img, InfoSelect, InfoTag, Input, InputGroup, InputLeftElement, InputRightElement, Item, ItemDescription, ItemLabel, JumpButton, Language, LanguageProvider, LightFullScreenLoader, LightInlineLoader, LightMode, LightSpinner, LineIcon, ListBox, ListItem, Modal, ModalBody, ModalCloseButton, ModalContent, ModalFooter, ModalHeader, ModalOverlay, NativeSelect, NumericStepper, OrderedList, PasswordInput, PhoneNumberInput, PlayPauseButton, Popover, PopoverAnchor, PopoverArrow, PopoverBody, PopoverCloseButton, PopoverContent, PopoverFooter, PopoverHeader, PopoverTrigger, PopoverWizardBody, ProgressBar, ProgressLoader, Radio, RadioGroup, ScaleFade, SearchInput, Section, SimpleDrawer, SimpleGrid, SimplePopover, Skeleton, SkeletonCircle, SkeletonText, SkipButton, Slide, SlideFade, Spacer, SporProvider, Stack, StaticAlert, Stepper, StepperStep, Switch, Tab, TabList, TabPanel, TabPanels, Table, TableCaption, Tabs, Tbody, Td, Text, TextLink, Textarea, Tfoot, Th, Thead, Time, TimePicker, Tr, TravelTag, UnorderedList, VStack, VyLogo, WizardPopover, Wrap, WrapItem, createTexts, extendTheme, fontFaces, theme, tokens, useBreakpointValue, useClipboard, useColorMode, useColorModePreference, useColorModeValue, useControllableProp, useDisclosure, useMediaQuery, useMergeRefs, useOutsideClick, usePrefersReducedMotion, useTheme, useToast, useToken, useTranslation } from './chunk-TMLJPE4H.mjs';
1
+ export { Accordion, AccordionButton, AccordionIcon, AccordionItem, AccordionPanel, AttachedInputs, Badge, Box, Breadcrumb, BreadcrumbItem, BreadcrumbLink, Button, ButtonGroup, Card, CardSelect, Center, Checkbox, CheckboxGroup, ChoiceChip, ClosableAlert, CloseButton, Code, Collapse, ColorInlineLoader, ColorSpinner, Combobox, Container, ContentLoader, DarkFullScreenLoader, DarkInlineLoader, DarkMode, DarkSpinner, DatePicker, DateRangePicker, Divider, Drawer, DrawerBody, DrawerCloseButton, DrawerContent, DrawerFooter, ModalHeader as DrawerHeader, DrawerOverlay, Expandable, ExpandableAlert, ExpandableItem, Fade, Flex, FloatingActionButton, FormControl, FormErrorMessage, FormHelperText, FormLabel, Grid, GridItem, HStack, Heading, IconButton, Image, Img, InfoSelect, InfoTag, Input, InputGroup, InputLeftElement, InputRightElement, Item, ItemDescription, ItemLabel, JumpButton, Language, LanguageProvider, LightFullScreenLoader, LightInlineLoader, LightMode, LightSpinner, LineIcon, ListBox, ListItem, Modal, ModalBody, ModalCloseButton, ModalContent, ModalFooter, ModalHeader, ModalOverlay, NativeSelect, NumericStepper, OrderedList, PasswordInput, PhoneNumberInput, PlayPauseButton, Popover, PopoverAnchor, PopoverArrow, PopoverBody, PopoverCloseButton, PopoverContent, PopoverFooter, PopoverHeader, PopoverTrigger, PopoverWizardBody, ProgressBar, ProgressLoader, Radio, RadioGroup, ScaleFade, SearchInput, Section, SimpleDrawer, SimpleGrid, SimplePopover, Skeleton, SkeletonCircle, SkeletonText, SkipButton, Slide, SlideFade, Spacer, SporProvider, Stack, StaticAlert, Stepper, StepperStep, Switch, Tab, TabList, TabPanel, TabPanels, Table, TableCaption, Tabs, Tbody, Td, Text, TextLink, Textarea, Tfoot, Th, Thead, Time, TimePicker, Tr, TravelTag, UnorderedList, VStack, VyLogo, WizardPopover, Wrap, WrapItem, createTexts, extendTheme, fontFaces, theme, tokens, useBreakpointValue, useClipboard, useColorMode, useColorModePreference, useColorModeValue, useControllableProp, useDisclosure, useMediaQuery, useMergeRefs, useOutsideClick, usePrefersReducedMotion, useTheme, useToast, useToken, useTranslation } from './chunk-LQEO65MM.mjs';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vygruppen/spor-react",
3
- "version": "3.7.4",
3
+ "version": "3.7.6",
4
4
  "main": "./dist/index.js",
5
5
  "module": "./dist/index.mjs",
6
6
  "types": "./dist/index.d.ts",
@@ -1,4 +1,10 @@
1
- import { Box, BoxProps, useMultiStyleConfig } from "@chakra-ui/react";
1
+ import {
2
+ Box,
3
+ BoxProps,
4
+ ComponentWithAs,
5
+ forwardRef,
6
+ useMultiStyleConfig,
7
+ } from "@chakra-ui/react";
2
8
  import { motion } from "framer-motion";
3
9
  import React, { useEffect } from "react";
4
10
 
@@ -24,68 +30,77 @@ type FloatingActionButtonProps = BoxProps & {
24
30
  * placement="bottom right"
25
31
  * />
26
32
  */
27
- export const FloatingActionButton = ({
28
- children,
29
- icon,
30
- variant,
31
- isTextVisible: externalIsTextVisible,
32
- placement = "bottom right",
33
- ...props
34
- }: FloatingActionButtonProps) => {
35
- const [isTextVisible, setIsTextVisible] = React.useState(
36
- externalIsTextVisible !== undefined ? externalIsTextVisible : false
37
- );
38
- const scrollDirection = useScrollDirection();
39
- useEffect(() => {
40
- if (externalIsTextVisible !== undefined) {
41
- return;
42
- }
43
- const id = window.setTimeout(
44
- () => setIsTextVisible(scrollDirection !== "down"),
45
- 1000
33
+ export const FloatingActionButton = forwardRef<
34
+ FloatingActionButtonProps,
35
+ ComponentWithAs<"a" | "button">
36
+ >(
37
+ (
38
+ {
39
+ as,
40
+ children,
41
+ icon,
42
+ variant,
43
+ isTextVisible: externalIsTextVisible,
44
+ placement = "bottom right",
45
+ ...props
46
+ },
47
+ ref
48
+ ) => {
49
+ const [isTextVisible, setIsTextVisible] = React.useState(
50
+ externalIsTextVisible !== undefined ? externalIsTextVisible : false
46
51
  );
47
- return () => window.clearTimeout(id);
48
- }, [scrollDirection, externalIsTextVisible]);
52
+ const scrollDirection = useScrollDirection();
53
+ useEffect(() => {
54
+ if (externalIsTextVisible !== undefined) {
55
+ return;
56
+ }
57
+ const id = window.setTimeout(
58
+ () => setIsTextVisible(scrollDirection !== "down"),
59
+ 1000
60
+ );
61
+ return () => window.clearTimeout(id);
62
+ }, [scrollDirection, externalIsTextVisible]);
49
63
 
50
- useEffect(() => {
51
- setIsTextVisible(!!externalIsTextVisible);
52
- }, [externalIsTextVisible]);
64
+ useEffect(() => {
65
+ setIsTextVisible(!!externalIsTextVisible);
66
+ }, [externalIsTextVisible]);
53
67
 
54
- const style = useMultiStyleConfig("FloatingActionButton", {
55
- variant,
56
- isTextVisible,
57
- placement,
58
- });
59
- return (
60
- <MotionBox
61
- __css={style.container}
62
- as="button"
63
- aria-label={children}
64
- {...props}
65
- >
66
- <Box __css={style.icon}>{icon}</Box>
68
+ const style = useMultiStyleConfig("FloatingActionButton", {
69
+ variant,
70
+ isTextVisible,
71
+ placement,
72
+ });
73
+ return (
67
74
  <MotionBox
68
- animate={isTextVisible ? "show" : "hide"}
69
- initial={externalIsTextVisible ? "show" : "hide"}
70
- variants={{
71
- show: {
72
- opacity: 1,
73
- width: "auto",
74
- visibility: "visible",
75
- },
76
- hide: {
77
- opacity: 0,
78
- width: 0,
79
- visibility: "hidden",
80
- },
81
- }}
82
- __css={style.text}
75
+ __css={style.container}
76
+ aria-label={children}
77
+ ref={ref}
78
+ {...props}
83
79
  >
84
- {children}
80
+ <Box __css={style.icon}>{icon}</Box>
81
+ <MotionBox
82
+ animate={isTextVisible ? "show" : "hide"}
83
+ initial={externalIsTextVisible ? "show" : "hide"}
84
+ variants={{
85
+ show: {
86
+ opacity: 1,
87
+ width: "auto",
88
+ visibility: "visible",
89
+ },
90
+ hide: {
91
+ opacity: 0,
92
+ width: 0,
93
+ visibility: "hidden",
94
+ },
95
+ }}
96
+ __css={style.text}
97
+ >
98
+ {children}
99
+ </MotionBox>
85
100
  </MotionBox>
86
- </MotionBox>
87
- );
88
- };
101
+ );
102
+ }
103
+ );
89
104
 
90
105
  type ScrollDirection = "up" | "down" | null;
91
106
  const useScrollDirection = () => {
@@ -1,7 +1,11 @@
1
1
  import { breadcrumbAnatomy as parts } from "@chakra-ui/anatomy";
2
- import { createMultiStyleConfigHelpers, defineStyle } from "@chakra-ui/styled-system";
3
- import { getBoxShadowString } from "../utils/box-shadow-utils";
2
+ import {
3
+ createMultiStyleConfigHelpers,
4
+ defineStyle,
5
+ } from "@chakra-ui/styled-system";
4
6
  import { mode } from "@chakra-ui/theme-tools";
7
+ import { getBoxShadowString } from "../utils/box-shadow-utils";
8
+ import { focusVisible } from "../utils/focus-utils";
5
9
 
6
10
  const { defineMultiStyleConfig, definePartsStyle } =
7
11
  createMultiStyleConfigHelpers(parts.keys);
@@ -14,22 +18,24 @@ const baseStyleLink = defineStyle((props) => ({
14
18
  color: "inherit",
15
19
  textDecoration: "none",
16
20
  textStyle: "xs",
21
+ paddingX: 0.5,
22
+ borderRadius: "xs",
17
23
  "&:not([aria-current=page])": {
18
24
  cursor: "pointer",
19
- paddingX: 0.5,
20
- borderRadius: "xs",
21
25
  _hover: {
22
26
  backgroundColor: mode("seaMist", "pine")(props),
23
27
  },
24
- _focusVisible: {
25
- boxShadow: getBoxShadowString({
26
- borderColor: mode("greenHaze", "azure")(props),
27
- borderWidth: 2,
28
- }),
29
- notFocus: {
30
- notFocus: { boxShadow: "none" },
31
- }
32
- },
28
+ ...focusVisible({
29
+ focus: {
30
+ boxShadow: getBoxShadowString({
31
+ borderColor: mode("greenHaze", "azure")(props),
32
+ borderWidth: 2,
33
+ }),
34
+ },
35
+ notFocus: {
36
+ boxShadow: "none",
37
+ },
38
+ }),
33
39
  _active: {
34
40
  backgroundColor: mode("mint", "whiteAlpha.200")(props),
35
41
  },
@@ -26,7 +26,7 @@ const config = helpers.defineMultiStyleConfig({
26
26
  borderColor: mode("blackAlpha.400", "whiteAlpha.400")(props),
27
27
  }),
28
28
  _active: {
29
- backgroundColor: mode("blackAlpha.100", "whiteAlpha.100")(props),
29
+ backgroundColor: mode("mint", "whiteAlpha.100")(props),
30
30
  boxShadow: getBoxShadowString({
31
31
  borderColor: mode("blackAlpha.400", "whiteAlpha.400")(props),
32
32
  }),