imageColor not working
See original GitHub issueHello,
First of all tanks a lot for this beautiful, simple and powerful plugin.
I’ve tried to use the new defaults, as in example 5.
I’ve also tried to directly use the new defaults directly in $.LoadingOverlay(action [,options])
without setting default options with $.LoadingOverlaySetup(options)
.
In both case, inspecting the DOM show that the div.loadingoverlay_element
has a fill: rgb(0, 0, 0)
if i set the imageColor
to "#000"
or "#000000"
or "black"
, but nothing happens.
Going further in multiple <svg>
file, I found that the fill
attribute is applied to the <svg>
tag directly or to the <path>
tag or to the <g>
tag off the image itself (not the stroke(s)).
So, if I set an imageClass
to the image and target the tag that has the fill
attribute and give it the desired fill color in a CSS file, everything goes as expected and the fill
attribute has the defined color in CSS !
EDIT / UPDATE
If I do the following, I can control the fill and stroke(s) where ever they are in the .svg
file :
JS
imageClass: "loadingoverlayimageclass"
CSS
.loadingoverlayimageclass * {
fill: red;
stroke: black;
}
END EDIT / UPDATE
Hope that those information will help to tweak the plugin so the fill
attribute will be applied to the exact tag
.
Side Note : I’ll be using your plugin in the next update of my theme that is already on the WP theme repository 😉
Thanks again for your time and all your efforts.
Issue Analytics
- State:
- Created 5 years ago
- Comments:7 (4 by maintainers)
Top GitHub Comments
I’ll release v2.1.0 today, please give me some time to update the documentation and you will find everything in there 😉
Yep, that’s what I wrote: those SVGs have inline styles built-in. I will work-around that, don’t worry.