Skip to content

Commit 0a0e320

Browse files
authored
chore: remove mergedTabPosition (#567)
1 parent de602a9 commit 0a0e320

File tree

1 file changed

+2
-7
lines changed

1 file changed

+2
-7
lines changed

src/Tabs.tsx

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -138,11 +138,6 @@ function Tabs(
138138
value: id,
139139
});
140140

141-
let mergedTabPosition = tabPosition;
142-
if (mobile && !['left', 'right'].includes(tabPosition)) {
143-
mergedTabPosition = 'top';
144-
}
145-
146141
// Async generate id to avoid ssr mapping failed
147142
useEffect(() => {
148143
if (!id) {
@@ -166,7 +161,7 @@ function Tabs(
166161
id: mergedId,
167162
activeKey: mergedActiveKey,
168163
animated: mergedAnimated,
169-
tabPosition: mergedTabPosition,
164+
tabPosition,
170165
rtl,
171166
mobile,
172167
};
@@ -196,7 +191,7 @@ function Tabs(
196191
id={id}
197192
className={classNames(
198193
prefixCls,
199-
`${prefixCls}-${mergedTabPosition}`,
194+
`${prefixCls}-${tabPosition}`,
200195
{
201196
[`${prefixCls}-mobile`]: mobile,
202197
[`${prefixCls}-editable`]: editable,

0 commit comments

Comments
 (0)