Material: mdToast displays in incorrect position if page is scrolled

Created on 1 Jul 2015  路  2Comments  路  Source: angular/material

Demo: http://codepen.io/anon/pen/zGRZav . Scroll down a bit and click the "Show toast" link. The toast appears in what would be the bottom left if the page had not been scrolled, but is now the middle or top of the window. Observed in both Chrome and Firefox.

duplicate

Most helpful comment

  1. Move ng-app to head
  2. Apply layout="column" to body
  3. Wrap content with <md-content></md-content>
  4. Add overflow-y: hidden !important to body css to avoid double scrollbars when toast is being shown (and other material components)
  5. Drink beer.

http://codepen.io/dani3l/pen/PqQpgB

As much as I know the toasts are no position: fixed so they can be used with FAB buttons (see here) and follow material design styleguide

All 2 comments

  1. Move ng-app to head
  2. Apply layout="column" to body
  3. Wrap content with <md-content></md-content>
  4. Add overflow-y: hidden !important to body css to avoid double scrollbars when toast is being shown (and other material components)
  5. Drink beer.

http://codepen.io/dani3l/pen/PqQpgB

As much as I know the toasts are no position: fixed so they can be used with FAB buttons (see here) and follow material design styleguide

@dozingcat @dani3l there is an open issue for this at #1106.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

buzybee83 picture buzybee83  路  3Comments

chriseyhorn picture chriseyhorn  路  3Comments

robertmesserle picture robertmesserle  路  3Comments

ddimitrop picture ddimitrop  路  3Comments

kasajian picture kasajian  路  3Comments