Skip to content

Commit

Permalink
refactor(toggle-emoji-button): remove type assertion with dir
Browse files Browse the repository at this point in the history
  • Loading branch information
yangwooseong committed Nov 6, 2024
1 parent 32c77b8 commit cfbe5e7
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ export const ToggleEmojiButtonGroup = forwardRef<
defaultValue,
children,
style,
dir,
dir = 'ltr',
onValueChange,
...rest
},
Expand Down Expand Up @@ -133,7 +133,6 @@ export const ToggleEmojiButtonGroup = forwardRef<
fillDirection && styles[`fillDirection-${fillDirection}`],
className
)}
dir={dir as 'ltr' | 'rtl'}
{...rest}
>
{children}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,14 +37,20 @@ interface ToggleEmojiButtonGroupOwnProps {
* Use when you do not need to control the state of the items.
*/
defaultValue?: string
/**
*
* @default 'ltr'
* The reading direction of the toggle group.
*/
dir?: 'ltr' | 'rtl'
/**
* Event handler called when the value changes.
*/
onValueChange?: (value: string) => void
}

export interface ToggleEmojiButtonGroupProps
extends Omit<BezierComponentProps<'div'>, 'defaultValue'>,
extends Omit<BezierComponentProps<'div'>, 'dir' | 'defaultValue'>,
ToggleEmojiButtonGroupOwnProps {}

export interface ToggleEmojiButtonSourceProps
Expand Down

0 comments on commit cfbe5e7

Please sign in to comment.