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

Change Path Color of SVG #44

Open
keithgulbro opened this issue Apr 17, 2019 · 7 comments
Open

Change Path Color of SVG #44

keithgulbro opened this issue Apr 17, 2019 · 7 comments

Comments

@keithgulbro
Copy link

Hi there,

Thanks for creating a great package, I have successfully got the base functionality operational.

One issue that I've encountered is changing the default black path of my SVG image to something different like green.

Typically in CSS you would use the fill declaration to change the color of the SVG path but in Nativescript-Vue this declaration doesn't seem to work.

Any insight into how to change the path color of an SVG inside a Nativescript application would be greatly appreciated.

@Remigius2011
Copy link

@keithgulbro did you find a solution? if yo, please post it here.

@keithgulbro
Copy link
Author

@Remigius2011

@Remigius2011 No I wasn't able to determine how to change the color via the code, I resorted to an old-school method of opening up the SVG file in it's raw format & searching for path's with the Hex color value I was attempting to change. I.E. path="#FFFFFF" -> path="#666666" Totally a hack, not what I was looking for but it got me past a minor roadblock. If you find a more concrete alternative, please let me know!

@Remigius2011
Copy link

@keithgulbro thanks for the info, we resorted so far to a similar solution - edit the svg files and set the fill attribute. maybe i'll have a look at the code and see what could be done. as you closed the issue i was assuming you found a solution, bud maybe it would make sense to reopen it to attract some attention and get a least a hint on how to proceed.

@keithgulbro keithgulbro reopened this Apr 24, 2019
@keithgulbro
Copy link
Author

@Remigius2011 ,

That's a solid idea, at least we have a temporary workaround.

Let's see if we can get some support from the plugin developer's. @victorsosa @tbozhikov 😃

@victorsosa
Copy link
Contributor

PR are welcome; You can summit a PR

@mrcretu
Copy link

mrcretu commented Feb 13, 2020

Any updates for this feature? It would be nice to have a fill attribute as we have width and height. Maybe another workaround to have the possibility to change svg's color programmatically?

@odedBartov
Copy link

odedBartov commented May 10, 2021

How can i change the fill color of the SVG image? I am stuck with the default color

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

5 participants