Skip to content

Commit

Permalink
fix: missing exports
Browse files Browse the repository at this point in the history
  • Loading branch information
gndz07 authored Oct 22, 2024
1 parent 3b26448 commit 5d5bc8e
Show file tree
Hide file tree
Showing 6 changed files with 58 additions and 125 deletions.
2 changes: 1 addition & 1 deletion components/DropdownMenu/DropdownMenu.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ import React from 'react';
import { CSS, styled } from '../../stitches.config';
import { Box } from '../Box';
import { Flex } from '../Flex';
import { itemCss, labelCss, menuCss, separatorCss } from '../Menu';
import { panelStyles } from '../Panel';
import { itemCss, labelCss, menuCss, separatorCss } from './styles';

export const DropdownMenu = DropdownMenuPrimitive.Root;
export const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;
Expand Down
54 changes: 54 additions & 0 deletions components/DropdownMenu/styles.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
import { css } from '../../stitches.config';
import { elevationVariants } from '../Elevation';

export const baseItemCss = css({
display: 'flex',
alignItems: 'center',
justifyContent: 'space-between',
fontFamily: '$rubik',
fontSize: '$1',
fontVariantNumeric: 'tabular-nums',
lineHeight: '1',
cursor: 'default',
userSelect: 'none',
whiteSpace: 'nowrap',
height: '$5',
px: '$5',
});

export const itemCss = css(baseItemCss, {
position: 'relative',
color: '$hiContrast',

'&:focus': {
outline: 'none',
backgroundColor: '$blue9',
color: 'white',
},

'&[data-disabled]': {
color: '$slate9',
},
});

export const labelCss = css(baseItemCss, {
color: '$slate11',
});

export const menuCss = css({
boxSizing: 'border-box',
minWidth: 120,
py: '$1',
variants: {
elevation: elevationVariants,
},
defaultVariants: {
elevation: 2,
},
});

export const separatorCss = css({
height: 1,
my: '$1',
backgroundColor: '$slate6',
});
121 changes: 0 additions & 121 deletions components/Menu.tsx

This file was deleted.

2 changes: 2 additions & 0 deletions index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,9 @@ export { FaencyProvider } from './components/FaencyProvider';
export { Flex } from './components/Flex';
export { Grid } from './components/Grid';
export { H1, H2, H3, H4, H5, H6 } from './components/Heading';
export { IconButton } from './components/IconButton';
export { Image } from './components/Image';
export { Input } from './components/Input';
export { Label } from './components/Label';
export { Link } from './components/Link';
export { Li, Ol, Ul } from './components/List';
Expand Down
1 change: 0 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,6 @@
"@radix-ui/react-icons": "^1.1.1",
"@radix-ui/react-id": "^1.0.0",
"@radix-ui/react-label": "^2.0.0",
"@radix-ui/react-menu": "^2.0.1",
"@radix-ui/react-navigation-menu": "^1.2.0",
"@radix-ui/react-popover": "^1.0.2",
"@radix-ui/react-portal": "^1.0.1",
Expand Down
3 changes: 1 addition & 2 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -4543,7 +4543,7 @@ __metadata:
languageName: node
linkType: hard

"@radix-ui/react-menu@npm:2.0.6, @radix-ui/react-menu@npm:^2.0.1":
"@radix-ui/react-menu@npm:2.0.6":
version: 2.0.6
resolution: "@radix-ui/react-menu@npm:2.0.6"
dependencies:
Expand Down Expand Up @@ -6196,7 +6196,6 @@ __metadata:
"@radix-ui/react-icons": "npm:^1.1.1"
"@radix-ui/react-id": "npm:^1.0.0"
"@radix-ui/react-label": "npm:^2.0.0"
"@radix-ui/react-menu": "npm:^2.0.1"
"@radix-ui/react-navigation-menu": "npm:^1.2.0"
"@radix-ui/react-popover": "npm:^1.0.2"
"@radix-ui/react-portal": "npm:^1.0.1"
Expand Down

0 comments on commit 5d5bc8e

Please sign in to comment.