Skip to content
This repository was archived by the owner on Sep 5, 2024. It is now read-only.

Conversation

clshortfuse
Copy link
Contributor

Safari has an alignment issue with SVG icons when its parent has
any padding, causing its content to shift placement

  • Force SVG elements to inherit height and width properties.

Fixes #9147

Safari has an alignment issue with SVG icons when its parent has
any padding, causing its content to shift placement

* Force SVG elements to inherit height and width properties.

Fixes angular#9147
@clshortfuse clshortfuse added ui: CSS needs: review This PR is waiting on review from the team browser: Safari labels Oct 10, 2016
@clshortfuse clshortfuse added this to the 1.1.2 milestone Oct 10, 2016
@clshortfuse
Copy link
Contributor Author

Review with: http://codepen.io/shortfuse/full/GjxLYj/

Tested OK on IE 11, Safari 9, Chrome 53, Firefox 49, Android 4.4.2

If somebody knows an alternative -webkit- solution, please share. -webkit-calc(100%) did not work.

@ThomasBurleson ThomasBurleson added needs: presubmit and removed needs: review This PR is waiting on review from the team labels Oct 10, 2016
@topherfangio
Copy link
Contributor

@clshortfuse I don't see a -webkit- anything in your changes. What are you talking about? Can you explain a bit more?

@clshortfuse
Copy link
Contributor Author

@topherfangio The idea being, if we are targeting a Safari issue, we would ideally limit the CSS to just Safari.

The only possible solution I found the one in the commit, that was applies to all browsers. As I said before, though, I didn't notice any issue in any of our supported browsers.

Copy link
Contributor

@topherfangio topherfangio left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 👍

@kara kara added pr: merge ready This PR is ready for a caretaker to review and removed needs: presubmit labels Oct 12, 2016
@kara kara merged commit ec318e7 into angular:master Oct 12, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
browser: Safari pr: merge ready This PR is ready for a caretaker to review ui: CSS
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants