polaris icon indicating copy to clipboard operation
polaris copied to clipboard

Components with `rem` unit have layout problem.

Open nonjene opened this issue 8 years ago • 8 comments

Originally posted by @ry5n in https://github.com/Shopify/polaris/issues/296#issuecomment-393682836

Issue summary

utilities.scss's $base-font-size set to 10px will cause layout problem in Chrome in which system's language is Chinese or Japanese.

Because at that env Chrome will limit the min font size to 12px, 10px will not take effect. It will cause components with rem unit have larger size.

Expected behavior

Set utilities.scss's $base-font-size to 12px

Actual behavior

You can easily recreate the issue by setting the the html element's font-size to 12px in Chrome's devtool.

Steps to reproduce the problem

  1. Change the system language to Chinese or Japanese

Specifications

  • Are you using the React components? (Y/N): Y
  • Polaris version number: v2.8 and v2.10
  • Browser: Chrome
  • Device: Macbook pro
  • Operating System: macOS High Sierra 10.13.6

nonjene avatar Sep 20 '18 06:09 nonjene

Hi @nonjene! We're working on some updates that should help improve this.

dpersing avatar Sep 20 '18 21:09 dpersing

@dpersing Thank you for the update.

nonjene avatar Sep 21 '18 10:09 nonjene

@nonjene This repo getting a makeover! We want to make it easier to find existing issues, remove duplicates, and increase community engagement. If you issue is closed, re-labelled, or moved, don’t panic–it may be a duplicate (check the comments), or there is a new label or repository that work better.

If you disagree with the changes or have any other thoughts on how we can make Polaris better, please let us know!

In this case, it's because we're removing the WIP label in favour of this issue getting triaged in our backlog. I've reached out to @ry5n and @dpersing to see where we're at on this issue. If it can be closed, feel free to do that as well.

yourpalsonja avatar Apr 16 '19 22:04 yourpalsonja

Hi @dpersing ! has any solution to this issue? I saw the fix not shipped on the v4

nonjene avatar Dec 10 '19 16:12 nonjene

Hi @nonjene. We merged and reverted a change to fix this. The problem was inter-op (compatibility) issues when Polaris React had been used with other frameworks in a single app.

We’d still like to ship this in a future version.

ry5n avatar Dec 11 '19 21:12 ry5n

Hi @ry5n, Thanks for that~ hope it will be soon 🙏

nonjene avatar Dec 12 '19 09:12 nonjene

This issue has been inactive for 180 days and labeled with Icebox. It will be closed in 7 days if there is no further activity.

ghost avatar Jun 09 '20 10:06 ghost

Hey @nonjene I know it's a long time coming, we shipped version 8 and updated the base font size to 16px. Thanks for raising this!

alex-page avatar Feb 02 '22 16:02 alex-page