Angular UI Bootstrap Modal-如何防止用户交互 [英] Angular UI Bootstrap Modal - how to prevent user interaction
本文介绍了Angular UI Bootstrap Modal-如何防止用户交互的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
在当前用例中,我试图使用angular-ui模态窗口显示在后台进程中执行的计算进度,该进程在完成时会禁用.
In my current usecase, I am trying to use angular-ui modal window to show the progress of calculations that we do in a background process which we disable on completion.
一切正常.我只想禁止用户单击背景中的任何元素.
All works well. I just want to disable user from clicking any of element in background.
任何想法我们该怎么做?
Any idea how can we do this?
推荐答案
打开模式窗口时,您可以传递以下选项,以防止用户关闭窗口:
You can pass the following options, when opening a modal window, to prevent users from closing the window:
-
backdrop: 'static'
-顶部阻止用户在背景幕点击时关闭模式 -
keyboard: false
-因此用户无法通过按ESC键关闭窗口
backdrop: 'static'
- top prevent users from closing a modal on backdrop clickkeyboard: false
- so users can't close a window by pressing ESC
此处提供完整文档: http://angular-ui.github.io/bootstrap/#/modal
这篇关于Angular UI Bootstrap Modal-如何防止用户交互的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文