Skip to content

Commit 901f1b7

Browse files
committed
imporve tab component style
1 parent afd6d06 commit 901f1b7

File tree

2 files changed

+2
-4
lines changed

2 files changed

+2
-4
lines changed

src/components/TabGroup.module.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@
99
padding: 5px 8px 5px;
1010
font-size: 12px;
1111
border: none;
12-
border-top: 1px solid var(--color-secondary);
1312
transition: 0.3s all;
1413
text-transform: uppercase;
1514
}
@@ -23,6 +22,7 @@
2322
}
2423

2524
.buttonTabGroup > button:disabled {
25+
border-top: 1px solid var(--color-secondary);
2626
background: var(--color-primary);
2727
color: white;
2828
cursor: not-allowed;

src/components/TabGroup.tsx

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,7 @@ const TabGroup = ({ children, buttonLabels }) => {
1414
<button
1515
key={label}
1616
style={{
17-
...(currentIndex === index
18-
? { cursor: "default", borderTop: "1px solid transparent" }
19-
: {}),
17+
...(currentIndex === index ? { cursor: "default" } : {}),
2018
}}
2119
disabled={currentIndex === index}
2220
onClick={() => setIndex(currentIndex)}

0 commit comments

Comments
 (0)