bootstrap icon indicating copy to clipboard operation
bootstrap copied to clipboard

Modal only display content after second open

Open inkidotcom opened this issue 12 years ago • 2 comments

When using an external URL to load modal template (not inline) the modal is empty on first open() then once closed (clicking in gray area) opening it again then display the modal correctly.

I modified your example plunkr and simply moved the the modal template to an external file:

example: http://plnkr.co/UssLZD5tuBTa5k9jrky6

inkidotcom avatar May 15 '14 19:05 inkidotcom

You are doing it wrong ;) The <script type="text/ng-template" id="newModal.html"> tag puts the template in the ng-template store (with the name newModal.html). This happens on your first click. On the second click the content is fetched from the store and everything works. Removing the script tag should do the thing for you.

paulpflug avatar May 15 '14 19:05 paulpflug

You are absolutely right. Thanks.

inkidotcom avatar May 15 '14 20:05 inkidotcom