PolymerElements / paper-icon-button

A Material Design icon button
https://www.webcomponents.org/element/PolymerElements/paper-icon-button
42 stars 44 forks source link

Icon shrinks in flex parent #73

Open robrez opened 8 years ago

robrez commented 8 years ago

When placed inside a horizontal-flex parent, the iron-icon shrinks w/ the content window.

Here is a codepen

paper-icon-button

A couple workarounds:

Issue #22 seems similar, except the focus was on getting paper-icon-button/its icon to be larger. This issue recommended usage of explicit sizing of the paper-icon-button... maybe workaround (B) is the recommended fix?

Potential patch?

      iron-icon {
        --iron-icon-width: 100%;
        --iron-icon-height: 100%;
+       min-width: var(--iron-icon-width, 24px);
+       min-height: var(--iron-icon-height, 24px);
      }
Ortham commented 8 years ago

I've noticed this happening with my own application, and also (probably of more concern to Google engineers) to Google Play Music's playlist button.

screenshot 6

Sinjins commented 7 years ago

+1