Angular UI modal directive, backdrop missing

前端 未结 5 2128
梦谈多话
梦谈多话 2021-02-15 01:47

I have no backdrop when using the modal directive from UI Bootstrap http://angular-ui.github.io/bootstrap/. The modal itself is working.

I have tried with both the ui-b

5条回答
  •  小蘑菇
    小蘑菇 (楼主)
    2021-02-15 02:21

    Try this PR

    Plunker

    Basically you just need to add one line in directive 'modalWindow'

    angular.element($document[0].querySelectorAll('div.modal-backdrop')).css('height',element[0].scrollHeight + 'px');
    

    and inject $document

提交回复
热议问题