You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
:root {
--cl-px:1rem; /* Your customer can override this variable in his code. */
}
/* In your code it could look like it. */
.cl-card {
max-width:calc(320*var(--cl-px));
}
This way you can don't worry anymore that some customers for some reason use non-16px rems.
If you know a less ugly way to fix it on our side, please tell me.
Now we'll just spend a couple of hours rewriting our CSS to px. Not a big deal for the current project, but it would be great if we could use Clerk React components in other projects without rewriting our styles.
Thank you.
The text was updated successfully, but these errors were encountered:
Hi!
For our site we have the following global CSS:
We do it to use clear sizes like 12rem, 18rem, 24rem in our styles. We don't want to sit with a calculator for 0.35rem, 0.68rem, etc.
This is how
<UserProfile />
component looks on our page.I'm not CSS pro, but probably you can consider switching to custom units like those described here:
w3c/csswg-drafts#7613
w3c/csswg-drafts#7379
I mean something like:
This way you can don't worry anymore that some customers for some reason use non-16px rems.
If you know a less ugly way to fix it on our side, please tell me.
Now we'll just spend a couple of hours rewriting our CSS to px. Not a big deal for the current project, but it would be great if we could use Clerk React components in other projects without rewriting our styles.
Thank you.
The text was updated successfully, but these errors were encountered: