question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

icon: Keep symbol viewBox value when register an iconSet

See original GitHub issue

Bug, feature request, or proposal:

Bug

What is the expected behavior?

When registering an SVG iconSet, every symbol may provide a custom viewBox attribute. This attribute should be keep in the newly SVG element created.

What is the current behavior?

The viewBox attribute is swallowed.

What are the steps to reproduce?

What is the use-case or motivation for changing an existing behavior?

Which versions of Angular, Material, OS, TypeScript, browsers are affected?

At least since beta 7

Is there anything else we should know?

This is related to #5188 #2981 For SVG icon set with symbol, see https://css-tricks.com/svg-symbol-good-choice-icons/

Issue Analytics

  • State:open
  • Created 6 years ago
  • Reactions:11
  • Comments:11 (3 by maintainers)

github_iconTop GitHub Comments

8reactions
ilaboriecommented, Nov 25, 2017

I still do not understand why this 3-lines patch is not applied?

5reactions
jelbourncommented, Sep 4, 2018

Potentially revisiting this now

Read more comments on GitHub >

github_iconTop Results From Across the Web

icon: Keep symbol viewBox value when register an iconSet ...
When registering an SVG iconSet, every symbol may provide a custom viewBox attribute. This attribute should be keep in the newly SVG element ......
Read more >
SVG Viewport and viewBox (For Complete Beginners)
In this quick SVG viewport and viewBox tutorial, we're going to break down exactly what viewport and viewBox are in SVG for the...
Read more >
viewBox - SVG: Scalable Vector Graphics - MDN Web Docs
The viewBox attribute defines the position and dimension, in user space, of an SVG viewport. The value of the viewBox attribute is a...
Read more >
Inline SVG icons not displaying in viewbox - Stack Overflow
Load it into a browser and use getBBox() to find the correct values for the viewBox.
Read more >
Using SVG Icons Components in React - Leapfrog Technology
TL;DR: We create a single SVG component and pass a name prop to it. The component resolves the viewBox and path values associated...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found