Skip to content

Commit e5d9002

Browse files
rootBr1an67
authored andcommitted
fix(tab-group): ensure indicator is visible with 1px track-width
The indicator was invisible when --track-width was set to 1px because box-sizing: border-box (inherited from component styles) caused the border to be drawn inside the element's 0-height content area. Adding box-sizing: content-box to the indicator ensures the border extends outside the content area and remains visible.
1 parent 4fc0fc3 commit e5d9002

File tree

2 files changed

+2
-0
lines changed

2 files changed

+2
-0
lines changed

.branch_name

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
fix/issue-2415-tab-indicator-track-width

src/components/tab-group/tab-group.styles.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ export default css`
2121
2222
.tab-group__indicator {
2323
position: absolute;
24+
box-sizing: content-box;
2425
transition:
2526
var(--sl-transition-fast) translate ease,
2627
var(--sl-transition-fast) width ease;

0 commit comments

Comments
 (0)