googlearchive / paper-toast

A lightweight feedback about an operation in a small popup at the base of the screen on mobile and at the lower left on desktop.
17 stars 8 forks source link

Toast has full screen height when called on domReady #17

Closed zdarovka closed 9 years ago

zdarovka commented 9 years ago

Hi, I need to show toast message as soon as application is launched. For this, I figure that best events should be domReady or attached. But when the UI is rendered and the toast is visible it has full screen height. It works OK if I show toast when UI is rendered (like on click on button etc.)

Toast is shown on the image below. The gray area on the left is toast message Image of toastt

frankiefu commented 9 years ago

This seems to work for me here: http://jsbin.com/damuxitapo/1/edit

Also depends on your setup, it may help if you do it inside a async/timeout. e.g.

domReady: function() {
  this.async(function() {
    this.$.toast.show();
  });
},
zdarovka commented 9 years ago

I added timeout, this is only way I got it working. It is not nice solution, I hope that I will find better solution someday