Skip to content

Commit b89cd43

Browse files
committed
Always show the tab list. #593
1 parent 0326d2e commit b89cd43

File tree

2 files changed

+12
-2
lines changed

2 files changed

+12
-2
lines changed

src/renderer/components/Pref/index.tsx

+3-2
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ import { BiSliderAlt } from 'react-icons/bi'
3232
import Advanced from './Advanced'
3333
import Commands from './Commands'
3434
import General from './General'
35+
import styles from './styles.less'
3536

3637
interface Props {}
3738

@@ -91,15 +92,15 @@ const PreferencePanel = (props: Props) => {
9192
</DrawerHeader>
9293

9394
<DrawerBody>
94-
<Tabs>
95+
<Tabs className={styles.tabs}>
9596
<TabList>
9697
<Tab>{lang.general}</Tab>
9798
<Tab>{lang.commands}</Tab>
9899
<Tab>{lang.proxy}</Tab>
99100
<Tab>{lang.advanced}</Tab>
100101
</TabList>
101102

102-
<TabPanels>
103+
<TabPanels className={styles.tab_panels}>
103104
<TabPanel>
104105
<General data={data} onChange={onUpdate} />
105106
</TabPanel>

src/renderer/components/Pref/styles.less

+9
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,15 @@
55
color: inherit;
66
}
77

8+
.tabs {
9+
height: 100%;
10+
}
11+
12+
.tab_panels {
13+
height: calc(100% - 37px);
14+
overflow: auto;
15+
}
16+
817
:global {
918
label {
1019
span.chakra-radio__control {

0 commit comments

Comments
 (0)