I think it's a bug of iron-fit-behavior, I have filed an issue
<https://github.com/PolymerElements/iron-fit-behavior/issues/13> .
Solution: wrap your dialog into a top-left positioned div, like this:
> <body>
> ...
> <div id="modals-container" style="position:absolute;top:0;left:0">
> ...your dialogs here
> </div>
> </body>
Good luck!
On Saturday, July 11, 2015 at 9:08:25 PM UTC+8, Adam McKee wrote:
>
> Hi,
>
> In my project I'm creating a paper-dialog with JavaScript similar to this:
>
> var fragment = "<paper-dialog id='mydialog' modal='true'
> ...>...</paper-dialog>";
> $('body').append(fragment);
> var $dialog = $('#mydialog');
> var dialog = $dialog.get(0);
> Polymer.Base.async(function(){
> dialog.toggle();
>
> // correct the unfathomable style "max-height: 0px;" applied to
> the dialog after toggle() is called
> if ($dialog.css('max-height') == '0px') $dialog.css('max-height',
> 'none');
> }, 1);
>
> What I find is: after dialog.toggle(), the dialog element is given the
> style "max-height: 0px" (in its style attribute). Does anyone know *why
> on Earth* this would happen? Max-height of 0 is totally unexpected.
>
> Thanks for any ideas!
>
>
Follow Polymer on Google+: plus.google.com/107187849809354688692
---
You received this message because you are subscribed to the Google Groups
"Polymer" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/polymer-dev/226c0b12-baa6-4a76-9353-d8bca1b3cb57%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.