Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: ensure DataTable.Title respects font scaling to prevent clipping #4640

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

kacperzolkiewski
Copy link

Motivation

Currently, text inside DataTable.Title gets cut off vertically when users increase font size in accessibility settings. This happens because the maxHeight does not account for scaled font sizes.

This PR ensures that the component properly respects PixelRatio.getFontScale(), preventing text clipping when font size is increased.

Related issue

Fixes: #4490

Test plan

Steps to Reproduce the Issue (Before Fix)

  • Open a screen with DataTable.Title.
  • Go to Device Settings > Accessibility > Font Size and increase the font size.
  • Observe that the text gets cut off vertically.

Steps to Verify the Fix

  • Apply this PR’s changes.
  • Increase font size in accessibility settings.
  • Verify that the text is now fully visible and scales correctly without clipping.

@callstack-bot
Copy link

Hey @kacperzolkiewski, thank you for your pull request 🤗. The documentation from this branch can be viewed here.

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.

Text gets cut in half (vertically) for DataTable.Title
2 participants