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

Chrome update, icons missing #305

Open
martinoleary opened this issue May 4, 2016 · 18 comments · May be fixed by #307
Open

Chrome update, icons missing #305

martinoleary opened this issue May 4, 2016 · 18 comments · May be fixed by #307

Comments

@martinoleary
Copy link

Details

Chrome not showing the icons on the share popup

Description

see attached.

Affected Tech

Chrome Browser version: 50.0.2661.94 (64-bit)

OS(s)

Ubuntu and Windows 10

Browser(s)

Chrome

Steps to Reproduce

replicate on the example site using this chrome version or later: https://sharebutton.co/
share-button

jsfiddle Example

TL; DR

...

Comments

Anything else related to the issue that doesn't fit above.

@techpines
Copy link

+1

Is there a workaround?

@rcamposp
Copy link

rcamposp commented May 5, 2016

Same here. Still looking for a answer...

@kylemac
Copy link
Contributor

kylemac commented May 5, 2016

all, we may not be able to look into solving this for weeks. unfortunately, this project is low on our priority list and we'll have to rely on the community if there's going to be an immediate solution.

@techpines
Copy link

I think if you host the SVG icons somewhere else, and then just reference them in the stylesheets, I bet this would work.

Right now they are embedding the SVG's as base64 data in the css, and there must be some kind of encoding mistake. I'll post a workaround, in the next few days unless someone else does.

@rcamposp
Copy link

rcamposp commented May 5, 2016

I've downloaded the SVG files and change the background images to point directly to the files instead of the URI data and it worked. Apparently the encoding generated after stylus compilation is not longer compatible with Chrome.

@hhsnopek
Copy link
Contributor

hhsnopek commented May 5, 2016

It appears we're missing utf8 in our data uri
see this thread - https://mobile.twitter.com/hhsnopek/status/728251445103845376

@xxxdepy
Copy link

xxxdepy commented May 5, 2016

As well the encoding of the SVG markup in the background-image URL doesn't look good.

The normal SVG markup code be used, like this:

background-image: url("data:image/svg+xml;utf8, <svg>...</svg>");

@gauravmak
Copy link

@rcamposp How did you exactly save SVGs as image files? I tried a couple of solutions but failed.

@rcamposp
Copy link

rcamposp commented May 6, 2016

At the end i tried something different because i couldn't change de color
(i don't have much experience working with svg). Because I was using
fontawesome on the project for other stuff, I decided to use those icons
instead and worked like a charm.
On May 5, 2016 10:36 PM, "Gaurav Makhecha" [email protected] wrote:

@rcamposp https://github.com/rcamposp How did you exactly save SVGs as
image files? I tried a couple of solutions but failed.


You are receiving this because you were mentioned.
Reply to this email directly or view it on GitHub
#305 (comment)

@rcamposp
Copy link

rcamposp commented May 6, 2016

I tried something like what @hhsnopek and @xxxdepy suggested but didn't worked for me. Anyone else has tried changing the url?

@xxxdepy
Copy link

xxxdepy commented May 6, 2016

@hhsnopek @rcamposp It appears that omitting utf8 isn't the actual problem.

In Chrome, not explicitly setting the width and height of the SVG element causes it to not work.

Here's an example with the same code being used on the page with the problem:
http://jsbin.com/wuyemu/edit?html,css,output

Setting the width and height may work.

Interestingly Mozilla Firefox doesn't seem to support non-encoded SVG, but using the URI encoded SVG is the option to go for.

@gauravmak
Copy link

Thank you @xxxdepy Specifying width and height works well.

@colavitam colavitam linked a pull request May 7, 2016 that will close this issue
@yeusiukou
Copy link

Can anybody post the fixed css file?

@colavitam
Copy link

These are the new css files as produced by #307.

newcss.zip

@yeusiukou
Copy link

Thank you, @colavitam!

@unRARed
Copy link

unRARed commented Aug 2, 2016

I just ran into this same issue this evening. It appeared the solution was going to be having to download the assets and refer to them explicitly, but strangely I was able to get the assets to display as is with only these two lines of SASS:

share-button .sb-social ul li:before
  background-image: url()

Can't confirm vanilla CSS will do the trick but the above compiles to:

share-button .sb-social ul li:before {
  background-image: url();
}

Confirmed working in Safari Version 9.1.1 (11601.6.17), Firefox 47.0 and Chrome 51.0.2704.103.

@simsketch
Copy link

I guess all that remains is for the carrot creative team to update the css on sharebutton.co to reflect the newcss.zip file which has been confirmed working. @hhsnopek

@refi64
Copy link

refi64 commented Apr 30, 2017

FWIW just rebuilding with the latest svg builder seems to fix the problem...

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

Successfully merging a pull request may close this issue.