Skip to content

Commit 69150ed

Browse files
committed
Tweak styles (remove arrow, box shadow, center Storybook example)
1 parent fe1eb43 commit 69150ed

File tree

3 files changed

+15
-16
lines changed

3 files changed

+15
-16
lines changed

packages/components/src/ui/radix-dropdown/index.tsx

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,6 @@ export const DropdownMenu = ( {
8383
loop={ true }
8484
>
8585
{ children }
86-
<DropdownMenuStyled.Arrow />
8786
</DropdownMenuStyled.Content>
8887
</DropdownMenuPrimitive.Portal>
8988
</DropdownMenuPrimitive.Root>

packages/components/src/ui/radix-dropdown/stories/index.tsx

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -166,7 +166,17 @@ const RadioItemsGroup = () => {
166166
};
167167

168168
const Template: ComponentStory< typeof DropdownMenu > = ( props ) => (
169-
<DropdownMenu { ...props } />
169+
<div
170+
style={ {
171+
width: '100%',
172+
minHeight: '300px',
173+
display: 'flex',
174+
alignItems: 'center',
175+
justifyContent: 'center',
176+
} }
177+
>
178+
<DropdownMenu { ...props } />
179+
</div>
170180
);
171181
export const Default = Template.bind( {} );
172182
Default.args = {
@@ -175,7 +185,7 @@ Default.args = {
175185
<Icon icon={ menu } size={ 20 } />
176186
</MenuButton>
177187
),
178-
sideOffset: 5,
188+
sideOffset: 12,
179189
children: (
180190
<>
181191
<DropdownMenuGroup>

packages/components/src/ui/radix-dropdown/styles.ts

Lines changed: 3 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -57,8 +57,9 @@ const baseContent = css`
5757
border: 1px solid ${ COLORS.ui.border };
5858
border-radius: 6px;
5959
padding: ${ space( 2 ) };
60-
box-shadow: 0px 10px 38px -10px rgba( 22, 23, 24, 0.35 ),
61-
0px 10px 20px -15px rgba( 22, 23, 24, 0.2 );
60+
box-shadow: 0 0.7px 1px rgba( 0, 0, 0, 0.1 ),
61+
0 1.2px 1.7px -0.2px rgba( 0, 0, 0, 0.1 ),
62+
0 2.3px 3.3px -0.5px rgba( 0, 0, 0, 0.1 );
6263
animation-duration: ${ ANIMATION_PARAMS.DURATION };
6364
animation-timing-function: ${ ANIMATION_PARAMS.EASING };
6465
will-change: transform, opacity;
@@ -175,14 +176,3 @@ export const ItemPrefixWrapper = styled.span`
175176
export const ItemSuffixWrapper = styled.span`
176177
${ itemSuffix }
177178
`;
178-
179-
export const Arrow = styled( DropdownMenu.Arrow )`
180-
fill: ${ COLORS.ui.background };
181-
182-
/* The following styles aim at adding a border to the arrow*/
183-
stroke: ${ COLORS.ui.border };
184-
stroke-dasharray: 36 28;
185-
stroke-dashoffset: 34;
186-
stroke-linejoin: round;
187-
stroke-width: 2.5;
188-
`;

0 commit comments

Comments
 (0)