Skip to content
This repository has been archived by the owner on Dec 28, 2024. It is now read-only.

this.style.backgroundImage needs quotes #32

Closed
rchrd2 opened this issue Nov 2, 2015 · 4 comments
Closed

this.style.backgroundImage needs quotes #32

rchrd2 opened this issue Nov 2, 2015 · 4 comments
Assignees

Comments

@rchrd2
Copy link

rchrd2 commented Nov 2, 2015

I had an issue with a URL that did not load when using the sizing property. I changed the code and it works now.

Before:

        this.style.backgroundImage = this.src ? 'url(' + this.src + ')': '';

After:

        this.style.backgroundImage = this.src ? 'url("' + this.src + '")': '';

The example markup was:

<iron-image sizing="cover" style="width: 400px; height: 400px" preload src="uploads/screenshot-modesto craigslist org 2015-06-08 22-42-27.png"></iron-image>

I can submit a pull request for this if necessary.

@alefwmm
Copy link

alefwmm commented Nov 12, 2015

+1. Same problem here.

@notwaldorf
Copy link
Contributor

@rchrd2 A PR would be awesome! 🎉

@bicknellr
Copy link
Contributor

#37

@bicknellr
Copy link
Contributor

This line and this line should handle this for the image itself (when sized) and the placeholder, respectively.

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

No branches or pull requests

4 participants