UNPKG

@mantine/core

Version:

React components library focused on usability, accessibility and developer experience

37 lines (34 loc) 1.35 kB
import { INPUT_SIZES } from '../Input/Input.js'; import { createMemoStyles } from '../../theme/create-memo-styles.js'; import { getSizeValue } from '../../theme/utils/get-size-value/get-size-value.js'; var useStyles = createMemoStyles({ wrapper: { position: "relative" }, dropdown: ({ theme, size }) => ({ position: "absolute", zIndex: 1, top: getSizeValue({ size, sizes: INPUT_SIZES }) + theme.spacing.sm / 2, left: 0, right: 0, backgroundColor: theme.colorScheme === "dark" ? theme.colors.dark[5] : theme.white, border: `1px solid ${theme.colorScheme === "dark" ? theme.colors.dark[5] : theme.colors.gray[2]}`, paddingTop: getSizeValue({ size, sizes: theme.spacing }) / 2, paddingBottom: getSizeValue({ size, sizes: theme.spacing }) / 2 }), item: ({ theme, size }) => ({ textAlign: "left", width: "100%", padding: [ getSizeValue({ size, sizes: theme.spacing }) / 1.5, getSizeValue({ size, sizes: theme.spacing }) ], fontSize: getSizeValue({ size, sizes: theme.fontSizes }), color: theme.colorScheme === "dark" ? theme.colors.dark[0] : theme.black }), hovered: ({ theme }) => ({ backgroundColor: theme.colorScheme === "dark" ? theme.colors.dark[4] : theme.colors.gray[1] }) }); export default useStyles; //# sourceMappingURL=Autocomplete.styles.js.map