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

fix: SVG scaling issues in Internet Explorer #6021

Merged
merged 3 commits into from Mar 7, 2017

Conversation

Projects
None yet
5 participants
@geordish
Contributor

geordish commented Feb 27, 2017

fixes #6019

DO NOT DELETE THIS TEXT

Please note

Please read this information carefully. You can run ./scripts/pre-commit.php to check your code before submitting.

  • Have you signed the Contributors agreement - please do NOT submit a pull request unless you have (signing the agreement in the same pull request is fine). Your commit message for signing the agreement must appear as per the docs.
  • Have you followed our code guidelines?

Testers

If you would like to test this pull request then please run: ./scripts/github-apply <pr_id>, i.e ./scripts/github-apply 5926

@LibreNMS-CI

This comment has been minimized.

LibreNMS-CI commented Feb 27, 2017

Auto-Deploy finished, Test PR at http://6021.ci.librenms.org or https://6021.ci.librenms.org

@laf

This comment has been minimized.

Member

laf commented Feb 27, 2017

What's changed in the svg images?

@geordish

This comment has been minimized.

Contributor

geordish commented Feb 27, 2017

}
@media screen and (-ms-high-contrast: active), (-ms-high-contrast: none) {
img {
width: 100%;

This comment has been minimized.

@murrant

murrant Feb 27, 2017

Member

This makes all logos 250px wide on IE...

This comment has been minimized.

@geordish

geordish Feb 27, 2017

Contributor

Yes, I'm not convinced that this PR is the best way to go about fixing it.

I might remove the CSS changes, and leave the additions of viewbox to the SVGs. I think those are going to be required regardless.

This comment has been minimized.

@murrant

murrant Feb 27, 2017

Member

Yeah, I did some quick searches and tried a few things and could not fix the logos on IE11.
Tried different combinations of viewbox and height/width svg properties and the css here.

@murrant

This comment has been minimized.

Member

murrant commented Mar 7, 2017

viewBox is needed for proper scaling. IE fucks it up when width+height are set...

@LibreNMS-CI

This comment has been minimized.

LibreNMS-CI commented Mar 7, 2017

Auto-Deploy finished, Test PR at http://6021.ci.librenms.org or https://6021.ci.librenms.org

1 similar comment
@LibreNMS-CI

This comment has been minimized.

LibreNMS-CI commented Mar 7, 2017

Auto-Deploy finished, Test PR at http://6021.ci.librenms.org or https://6021.ci.librenms.org

@murrant murrant changed the title from Attempt to fix sizing issues in IE to fix: SVG size issues in Internet Explorer Mar 7, 2017

@LibreNMS-CI

This comment has been minimized.

LibreNMS-CI commented Mar 7, 2017

Auto-Deploy finished, Test PR at http://6021.ci.librenms.org or https://6021.ci.librenms.org

1 similar comment
@LibreNMS-CI

This comment has been minimized.

LibreNMS-CI commented Mar 7, 2017

Auto-Deploy finished, Test PR at http://6021.ci.librenms.org or https://6021.ci.librenms.org

@murrant

murrant approved these changes Mar 7, 2017

@murrant

This comment has been minimized.

Member

murrant commented Mar 7, 2017

There was some positive feedback from a user on this, but I messed up a merge commit, so it lost the comment. Looks good in my testing with IE11. Also has unit tests to make sure things keep working.

@scrutinizer-notifier

This comment has been minimized.

scrutinizer-notifier commented Mar 7, 2017

The inspection completed: 5 updated code elements

@laf

This comment has been minimized.

Member

laf commented Mar 7, 2017

Are the 90+ other files that have been changed supposed to be there?

@murrant

This comment has been minimized.

Member

murrant commented Mar 7, 2017

Yes, those are the changes to fix IE, or remove svgs containing pngs.

@murrant murrant changed the title from fix: SVG size issues in Internet Explorer to fix: SVG scaling issues in Internet Explorer Mar 7, 2017

@murrant murrant added the Bug 🐞 label Mar 7, 2017

@laf laf merged commit 3bb5ba3 into librenms:master Mar 7, 2017

2 checks passed

Auto-Deploy Build finished.
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment