material icon indicating copy to clipboard operation
material copied to clipboard

Label and Icon are not center in Menu-Item (Windows IE11)

Open RichOren opened this issue 10 years ago • 4 comments

Actual Behavior:

  • What is the issue? * In IE 11.0.096 - AM - 1.1.0-rc.5 - The <p> & <md-icon> are not centered in the <md-button>.
  • What is the expected behavior? The<p> and <md-icon> should be centered in the <md-button> in the menu-item
  • Details: Look https://material.angularjs.org/latest/demo/menu - and test the position modes examples.

Angular Versions: *

  • Angular Version: 1.5.7
  • Angular Material Version: 1.1.0-rc.5

Additional Information:

  • Browser Type: * IE 11
  • Browser Version: * IE 11.0.096
  • OS: * Windows.

RichOren avatar Jul 21 '16 21:07 RichOren

Are you referring to this?

angular_material_-demos__menu-_internet_explore_2016-07-21_23-28-16

crisbeto avatar Jul 21 '16 21:07 crisbeto

Yes - I have temp fix for now.

I put layout-fill attribute on the <div>

and added this to my component css

md-menu-item > .md-button p {
    text-align: left; // for IE
    line-height: 48px; // for IE
}
<md-menu-item ng-repeat="item in [1, 2, 3]">
    <md-button ng-click="ctrl.announceClick($index)">
        <div layout-fill layout="row" flex="">
            <p flex="">Option {{item}}</p>
            <md-icon md-menu-align-target="" md-svg-icon="call:portable-wifi-off" style="margin: auto 3px auto 0;"></md-icon>
        </div>
    </md-button>
</md-menu-item>

RichOren avatar Jul 21 '16 21:07 RichOren

Yep - It LGTM in master. Thank you for looking into that.

RichOren avatar Jul 22 '16 00:07 RichOren