Skip to content
This repository has been archived by the owner on Nov 3, 2023. It is now read-only.

CSS combining not working with inline svg rgb definition #8788

Closed
qbadev opened this issue Sep 26, 2017 · 3 comments
Closed

CSS combining not working with inline svg rgb definition #8788

qbadev opened this issue Sep 26, 2017 · 3 comments
Assignees
Labels
Milestone

Comments

@qbadev
Copy link

qbadev commented Sep 26, 2017

Contao 3.5.28. I use inline svg inside my css. I noticed, that after combining, contao adds a quote inside rgb color definition.
My css is:

background-image: url("data:image/svg+xml;charset=utf8,<svg xmlns='http://www.w3.org/2000/svg'><path stroke='rgb(255, 255, 255)'></svg>");

after combining it looks as shown below

background-image: url("data:image/svg+xml;charset=utf8,<svg xmlns='http://www.w3.org/2000/svg'><path stroke='rgb(255, 255, 255")'></svg>");

Combiner adds needless double quote just before rgb ending bracket

@leofeyer
Copy link
Member

What happens if you use single quotes for the image and double quotes for the attributes?

background-image: url('data:image/svg+xml;charset=utf8,<svg xmlns="http://www.w3.org/2000/svg"><path stroke="rgb(255, 255, 255)"></svg>');

@qbadev
Copy link
Author

qbadev commented Sep 26, 2017

It outputs sth much more weird than before, as it still adds double quote before ending bracket and also changes first single quote after url( to double quote. I think combiner "thinks" that rgb ending bracket is the end of url definition.

background-image: url("data:image/svg+xml;charset=utf8,<svg xmlns="http://www.w3.org/2000/svg"><path stroke="rgb(255, 255, 255")"></svg>');

@leofeyer leofeyer added this to the 3.5.29 milestone Sep 26, 2017
@leofeyer leofeyer self-assigned this Sep 26, 2017
@leofeyer
Copy link
Member

Fixed in a2be3cb.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

2 participants