Skip to content

Commit

Permalink
fix(react): fix CompositePanel
Browse files Browse the repository at this point in the history
  • Loading branch information
janryWang committed Oct 8, 2021
1 parent cc616aa commit 84e8dfb
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion packages/react/src/panels/CompositePanel.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,7 @@ export const CompositePanel: React.FC<ICompositePanelProps> & {
href={item.href}
onClick={(e: any) => {
if (shape === 'tab') {
if (index === activeKey) {
if (activeKey === index || activeKey === item.key) {
setVisible(!visible)
} else {
setVisible(true)
Expand Down
2 changes: 1 addition & 1 deletion packages/react/src/panels/styles.less
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,7 @@

.@{prefix-cls}-composite-panel-tabs-pane.active:after {
left: auto;
right: 0px;
right: -1px;
}

.@{prefix-cls}-composite-panel-tabs-content.pinning {
Expand Down

0 comments on commit 84e8dfb

Please sign in to comment.