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

Percentage-based Border Radii #57

Closed
mattrothenberg opened this issue Dec 24, 2018 · 0 comments
Closed

Percentage-based Border Radii #57

mattrothenberg opened this issue Dec 24, 2018 · 0 comments

Comments

@mattrothenberg
Copy link

Howdy! First and foremost, thanks for building + maintaining this library! It's been an invaluable asset to my open-source lib, https://github.com/mattrothenberg/vue-overdrive.

In upgrading to 0.6.0-alpha, I noticed (what I think is) a regression around percentage-based radii. Simply put, if one of the nodes passed to the transform function has a border-radius with a percentage in it, ramjet barfs with the following error.

screen shot 2018-12-24 at 10 29 00 am

Upon closer inspection, it seems like the following line might be the culprit. https://github.com/Rich-Harris/ramjet/blob/master/src/utils/parseBorderRadius.js#L1

var borderRadiusRegex = /^(\d+)px(?: (\d+)px)?$/;

I figured you might have better context than myself as to what might have changed between versions.

I've set up a Codepen that reproduces the error.

Demo: https://streamable.com/sphja
Link: https://codepen.io/mattrothenberg/pen/MZbdNx?editors=0111

❤️

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

No branches or pull requests

1 participant