Skip to content

Commit

Permalink
Remove unnecessary optional chaining
Browse files Browse the repository at this point in the history
  • Loading branch information
ciampo committed Nov 29, 2024
1 parent df87182 commit e2c46b4
Show file tree
Hide file tree
Showing 6 changed files with 9 additions and 9 deletions.
4 changes: 2 additions & 2 deletions packages/components/src/menu/checkbox-item.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -38,10 +38,10 @@ export const MenuCheckboxItem = forwardRef<
{ ...props }
accessibleWhenDisabled
hideOnClick={ hideOnClick }
store={ menuContext?.store }
store={ menuContext.store }
>
<Ariakit.MenuItemCheck
store={ menuContext?.store }
store={ menuContext.store }
render={ <Styled.ItemPrefixWrapper /> }
// Override some ariakit inline styles
style={ { width: 'auto', height: 'auto' } }
Expand Down
2 changes: 1 addition & 1 deletion packages/components/src/menu/group-label.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ export const MenuGroupLabel = forwardRef<
/>
}
{ ...props }
store={ menuContext?.store }
store={ menuContext.store }
/>
);
} );
2 changes: 1 addition & 1 deletion packages/components/src/menu/group.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ export const MenuGroup = forwardRef<
<Styled.MenuGroup
ref={ ref }
{ ...props }
store={ menuContext?.store }
store={ menuContext.store }
/>
);
} );
2 changes: 1 addition & 1 deletion packages/components/src/menu/item.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ export const MenuItem = forwardRef<
{ ...props }
accessibleWhenDisabled
hideOnClick={ hideOnClick }
store={ menuContext?.store }
store={ menuContext.store }
>
<Styled.ItemPrefixWrapper>{ prefix }</Styled.ItemPrefixWrapper>

Expand Down
4 changes: 2 additions & 2 deletions packages/components/src/menu/radio-item.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -45,10 +45,10 @@ export const MenuRadioItem = forwardRef<
{ ...props }
accessibleWhenDisabled
hideOnClick={ hideOnClick }
store={ menuContext?.store }
store={ menuContext.store }
>
<Ariakit.MenuItemCheck
store={ menuContext?.store }
store={ menuContext.store }
render={ <Styled.ItemPrefixWrapper /> }
// Override some ariakit inline styles
style={ { width: 'auto', height: 'auto' } }
Expand Down
4 changes: 2 additions & 2 deletions packages/components/src/menu/separator.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@ export const MenuSeparator = forwardRef<
<Styled.MenuSeparator
ref={ ref }
{ ...props }
store={ menuContext?.store }
variant={ menuContext?.variant }
store={ menuContext.store }
variant={ menuContext.variant }
/>
);
} );

0 comments on commit e2c46b4

Please sign in to comment.