Skip to content

Fix tab indicator clipping by removing matchContentSize in JetLaggedHeaderTabs - #1707

Merged
riggaroo merged 1 commit into
android:mainfrom
kuvandikov:fix-tab-indicator-issue-1703
Oct 19, 2026
Merged

riggaroo merged 1 commit into
android:mainfrom
kuvandikov:fix-tab-indicator-issue-1703

Conversation

@kuvandikov

Copy link
Copy Markdown
Contributor

Description

This PR fixes issue #1703 where the tab selection indicator in the JetLagged sample was incorrectly sized and clipping the label text.

Screenshot_20260829_053440

Changes:

  • Removed matchContentSize = true from .tabIndicatorOffset() in the indicator implementation.
  • By disabling content matching (returning to default behavior), the indicator box now fills the entire tab slot, providing enough space to comfortably encapsulate the label text without clipping.

Verification:

  • Verified via Compose Preview: The indicator now correctly encloses the entire label (e.g., "Day", "Week") without any clipping.
  • Verified on Emulator: The selection box aligns perfectly with the tab's clickable area.

Related Issues

Fixes #1703

@kuvandikov kuvandikov changed the title Fix tab indicator clipping by removing matchContentSize in JetLaggedHeaderTabs Fix tab indicator clipping by removing matchContentSize in JetLaggedHeaderTabs #1703 Aug 29, 2026
@kuvandikov kuvandikov changed the title Fix tab indicator clipping by removing matchContentSize in JetLaggedHeaderTabs #1703 Fix tab indicator clipping by removing matchContentSize in JetLaggedHeaderTabs Aug 29, 2026
@kuvandikov

Copy link
Copy Markdown
Contributor Author

Hi @srikrishnasakunia, @riggaroo, I’ve looked into this issue and implemented a fix. By removing the matchContentSize = true parameter from the indicator's offset, we ensure the selection box comfortably encapsulates the full label text (e.g., 'Day', 'Week') without any clipping. I’ve tested this across all tabs, and it now aligns perfectly with the clickable area. Looking forward to your feedback!

@riggaroo

Copy link
Copy Markdown
Collaborator

please update with latest main changes to get build status run

@kuvandikov
kuvandikov requested a review from a team as a code owner October 19, 2026 09:49
@kuvandikov
kuvandikov force-pushed the fix-tab-indicator-issue-1703 branch from 049ce32 to 5d15a04 Compare October 19, 2026 09:54
@kuvandikov
kuvandikov requested a review from riggaroo October 19, 2026 09:59
@riggaroo
riggaroo merged commit 4b34129 into android:main Oct 19, 2026
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: JetLagged: Home screen: Selection indicator on "Day" tab is misaligned and truncated.

2 participants