-
-
Notifications
You must be signed in to change notification settings - Fork 2.5k
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 of "Title wraps within word in Improve the Experience screen" #8322
Conversation
Thanks for your pull request 👍 We have talked about this internally and decided on a path forward. Please see #8257 (comment) I've created PR #8341 to switch to showing the brand name. Once that is merged it would be awesome if you could look into resizing the text so it fits the available width. Side note: Please don't merge |
b7f4f9f
to
290bc9a
Compare
@cketti I have made corresponding text auto resizable so it always fits the available width. Please let me know if that's alright and/or if anything else needed. |
cdccd7c
to
c8b8519
Compare
if (style.fontSize.isUnspecified) { | ||
resizedTextStyle = resizedTextStyle.copy( | ||
fontSize = defaultFontSize, | ||
) | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
All of our text styles contain a font size. So this code is not necessary.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done!
@@ -39,3 +46,43 @@ fun TextDisplayMedium( | |||
style = MainTheme.typography.displayMedium, | |||
) | |||
} | |||
|
|||
@Composable | |||
fun AutoResizeableTextDisplayMedium( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please rename to TextDisplayMediumAutoResize
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done!
modifier: Modifier = Modifier, | ||
color: Color = Color.Unspecified, | ||
textAlign: TextAlign? = null, | ||
style: TextStyle = MainTheme.typography.displayMedium, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please remove the style
parameter.
If we need this functionality for another text style we can then figure out how best to generalize (and where to move) this code.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done!
…Added AutoResizeableTextDisplayMedium"
…Added AutoResizeableTextDisplayMedium"- reviews resolved.
c8b8519
to
0eefbce
Compare
Thanks 👍 |
Fixes #8257