Skip to content

Commit

Permalink
fix: add tabs dropdown rtl classname (#276)
Browse files Browse the repository at this point in the history
* fix: add tabs dropdown rtl classname

* fix: demo
  • Loading branch information
xrkffgg authored Jun 3, 2020
1 parent 0716132 commit 814d847
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
4 changes: 4 additions & 0 deletions assets/rtl.less
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,8 @@
&-rtl {
direction: rtl;
}

&-dropdown-rtl {
direction: rtl;
}
}
5 changes: 5 additions & 0 deletions src/TabNavList/OperationNode.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -148,6 +148,10 @@ function OperationNode(
moreStyle.order = 1;
}

const overlayClassName = classNames({
[`${dropdownPrefix}-rtl`]: rtl
})

const moreNode: React.ReactElement = mobile ? null : (
<Dropdown
prefixCls={dropdownPrefix}
Expand All @@ -156,6 +160,7 @@ function OperationNode(
visible={open}
transitionName={moreTransitionName}
onVisibleChange={setOpen}
overlayClassName={overlayClassName}
>
<button
type="button"
Expand Down

0 comments on commit 814d847

Please sign in to comment.