File tree Expand file tree Collapse file tree 3 files changed +4
-7
lines changed
components/fields/ListBox Expand file tree Collapse file tree 3 files changed +4
-7
lines changed Original file line number Diff line number Diff line change @@ -37,7 +37,7 @@ import {
3737 Styles ,
3838 tasty ,
3939} from '../../../tasty' ;
40- import { SIZES , SIZES_MAP } from '../../../tokens' ;
40+ import { SIZE_NAME_TO_KEY , SIZES } from '../../../tokens' ;
4141import { mergeProps , useCombinedRefs } from '../../../utils/react' ;
4242import { useFocus } from '../../../utils/react/interactions' ;
4343// Import Menu styled components for header and footer
@@ -793,7 +793,7 @@ export const ListBox = forwardRef(function ListBox<T extends object>(
793793 if ( currentItem ?. props ?. description ) {
794794 return SIZES . XL + 1 ;
795795 }
796- return SIZES [ SIZES_MAP [ size ] as keyof typeof SIZES ] + 1 ;
796+ return SIZES [ SIZE_NAME_TO_KEY [ size ] as keyof typeof SIZES ] + 1 ;
797797 } ,
798798 measureElement : ( el ) => {
799799 return el . offsetHeight + 1 ;
Original file line number Diff line number Diff line change @@ -20,7 +20,7 @@ import { BASE_TOKENS } from './base';
2020import { COLOR_TOKENS } from './colors' ;
2121import { LAYOUT_TOKENS } from './layout' ;
2222import { SHADOW_TOKENS } from './shadows' ;
23- import { SIZE_NAME_TO_KEY , SIZE_TOKENS , SIZES , SIZES_MAP } from './sizes' ;
23+ import { SIZE_NAME_TO_KEY , SIZE_TOKENS , SIZES } from './sizes' ;
2424import { SPACE_TOKENS } from './spacing' ;
2525
2626import type { Styles } from '../tasty/styles/types' ;
@@ -53,7 +53,7 @@ export const TOKENS: Styles = {
5353
5454// Re-export category modules for direct access
5555export { COLOR_TOKENS } from './colors' ;
56- export { SIZES , SIZE_NAME_TO_KEY , SIZES_MAP , SIZE_TOKENS } from './sizes' ;
56+ export { SIZES , SIZE_NAME_TO_KEY , SIZE_TOKENS } from './sizes' ;
5757export type { SizeKey , SizeName } from './sizes' ;
5858export { SPACE_TOKENS } from './spacing' ;
5959export { SHADOW_TOKENS } from './shadows' ;
Original file line number Diff line number Diff line change @@ -29,9 +29,6 @@ export const SIZE_NAME_TO_KEY: Record<SizeName, SizeKey> = {
2929 xlarge : 'XL' ,
3030} ;
3131
32- /** @deprecated Use SIZE_NAME_TO_KEY instead */
33- export const SIZES_MAP = SIZE_NAME_TO_KEY ;
34-
3532/**
3633 * Size tokens with $ prefix for CSS custom properties.
3734 * Creates tokens like `$size-xs`, `$size-sm`, etc.
You can’t perform that action at this time.
0 commit comments