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

clipPathUnits is being renamed to kebab-case version which breaks functionality #122

Open
vitaliyrtest1 opened this issue Dec 9, 2019 · 0 comments

Comments

@vitaliyrtest1
Copy link

Hello!

When using clipPathUnits attribute in svgs, svg-react-loader renames this attribute to kebab version clip-path-units, which actually breaks functionality of this attribute.

I've been testing this for hours until found the bug :(

Right now I'm loading this SVG as text and insert as it is, but I guess it will be good to fix this bug.

Example svg:

<svg>
  <defs>
    <clipPath id="header-background-path" clipPathUnits="objectBoundingBox" transform="scale(0.002777778, 0.005747126)">
      <path d="M0,0 L360,0 L360,124 C311.942708,144 254.8125,154 188.609375,154 C122.40625,154 59.5364583,160.666667 0,174 L0,0 Z" />
    </clipPath>
  </defs>
</svg>

Expected result - as it is.

Actual result:

...
<clipPath id="header-background-path" clip-pathunits="objectBoundingBox" transform="scale(0.002777778, 0.005747126)">
...
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