Closed fibo closed 6 years ago
@fibo We make the assumption that most users use a base rem size of 16px
. 16
* 1.5
= 24px
the native 1:1 size for people on older screens this should look best.
You can also pass a string to the size
. So you could put any value you want. size={'1.5em'}
for example.
Hopefully that reasoning makes sense. It's mostly to accommodate 95% of users, but allows the 5% to use a string.
So in your wrapper, simply put size={`${size}rem`}
, is what I mean.
Chatting with the team about this, we're going to remove the default setting of 1 and make it unset.
Small breaking change for existing users, but probably best to handle this in CSS.
Okay, we've decided to bundle this breaking change into v1.0.0
along side the release of <Stack/>
component that will be bundled with <Icon/>
.
Thanks for the answer and support, I also opted for passing a string.
Since you're passing a string it will continue to work the same after the changes go out for v1.0.0. Your feedback along with 2 others convinced me we should change the default functionality in the final release, so thanks!
@fibo By the way v1.0.0
released with this change (and lots of other updates). 😺
@Templarian thanks, I am going to check it out. I will probably using your package in production at my new job, just in few minutes I am going to discuss about some proposal and among many others there will be this package.
Ahah I was like cause it was what I was looking for and it was just created, I putted like the fifth star on GitHub.
Thanks for sharing your software and for your passion, I hope you can find useful some packages I shared or at least I will try to contribute with feedbacks and maybe PRs.
Have a nice day, Gianluca.
Hi, why the icon size is multiplied by 1.5 ?
I refer to this snippet:
I am wrapping
@mdi/react
icon to addisSmall
,isLarge
props: I expected that size would be passed as is.