modal-dialog

How to keep focus within modal dialog?

喜夏-厌秋 提交于 2019-11-28 04:03:59
问题 I'm developing an app with Angular and Semantic-UI . The app should be accessible, this means it should be compliant with WCAG 2.0. To reach this purpose the modals should keep focus within the dialog and prevents users from going outside or move with "tabs" between elements of the page that lays under the modal. I have found some working examples, like the following: JQuery dialog: https://jqueryui.com/dialog/#modal-confirmation dialog HTML 5.1 element: https://demo.agektmr.com/dialog ARIA

How to make a .NET MVC Form inside a Modal using jQuery with validation

杀马特。学长 韩版系。学妹 提交于 2019-11-28 03:51:37
I am really struggling with knowing how to put this all together. I've built forms inside .net MVC pages plenty of times, with and without validation. And I've built forms using jQuery, with and without validation. And I've built forms inside of a modal, but never with MVC. I understand from my original question that because this form is inside a modal that I'll need to use jQuery to handle the submit. I am having a heck of a time figuring out how to put all these moving pieces together. So far, I've not found a tutorial (or combo of tutorials) that puts this all together. Here is what I need:

React Navigation modal height

筅森魡賤 提交于 2019-11-28 03:40:15
问题 How do I set the height a React Navigation modal view so once it has appeared it will only cover about half of the screen from the bottom up, and the view below remains visible? Update: I'm trying to create a ux flow similar to the App Store purchase modal, where some kind of StackNavigator is nested in a modal that fills the bottom half of the screen. 回答1: In your stacknavigator you can set these options: mode: 'modal', headerMode: 'none', cardStyle:{ backgroundColor:"transparent", opacity:0

UIModalPresentationFormSheet resizing view

泪湿孤枕 提交于 2019-11-28 03:27:45
I am interested to know on how I can resize the view when using UIModalPresentationFormSheet of modalPresentationStyle , it looks like it has a fixed size so I was wondering if anyone out there did managed to manipulate the popup view from the sizing perspective. So there is either UIModalPresentationFormSheet with a fixed view size or full views and I am after something in between. tosi MyModalViewController *targetController = [[[MyModalViewController alloc] init] autorelease]; targetController.modalPresentationStyle = UIModalPresentationFormSheet; targetController.modalTransitionStyle =

How to show twitter bootstrap modal via JS request in rails?

天大地大妈咪最大 提交于 2019-11-28 03:06:41
I want to show a twitter bootstrap modal as a response to a JS request. My show.js.erb function looks something like this: $(document).ready(function() { $('#dialog').modal('show') }); Here "dialog" is the modal's id. The modal code itself looks something like this: <div id="dialog" class="modal hide fade"> <div class="modal-header"> <a href="#" class="close">×</a> <h3> Showing Modal </h3> </div> <div class="modal-body"> I need to show up! </div> <div class="modal-footer"> <a href="#" class="btn primary">Done</a> </div> </div> One thing I am sure of is that the javascript is being called. I

How to create a React Modal(which is append to `<body>`) with transitions?

微笑、不失礼 提交于 2019-11-28 02:48:22
There is a modal in this answer https://stackoverflow.com/a/26789089/883571 which is creating a React-based Modal by appending it to <body> . However, I found it not compatible with the transition addons provided by React. How to create one with transitions(during enter and leave)? At react conf 2015, Ryan Florence demonstrated using portals . Here's how you can create a simple Portal component... var Portal = React.createClass({ render: () => null, portalElement: null, componentDidMount() { var p = this.props.portalId && document.getElementById(this.props.portalId); if (!p) { var p = document

How to fix the iOS 11 input element in fixed modals bug

不打扰是莪最后的温柔 提交于 2019-11-28 02:42:18
问题 A bug in HTML inputs in the newly released iOS 11 is creating problems for websites that have input elements in fixed containers. Here is exactly what is happening and some possible workarounds. If you have an in an fixed container and it is close enough to the bottom of the screen forcing the browser to scroll to make room for the keyboard, the cursor is put outside of the text input. This was a critical problem for us since one of our core functionalities relies on the user input through a

How to stop Java from running the entire code with out waiting for Gui input from The user

倖福魔咒の 提交于 2019-11-28 02:16:49
Im fairly new to Java and im just looking for a little help Im trying to create a program which allows the user to enter as a gui the name and> >location of a department store. It allows this but the program does not wait for the >details to be entered it just initializes the Gui class and simply continues on with the >processing Which is to add the details entered into the Gui into an array list. But the >details have not yet been entered yet so it is creating a null value because it has jumped >ahead. So how can I make it stop and wait till the values have been entered and then submitted?

Yii2 Modal Dialog on Gridview view and update button shows same content for both buttons

浪尽此生 提交于 2019-11-28 02:04:04
问题 With reference to How to implement Yii2 Modal Dialog on Gridview view and update button?, the problem is currently solved on enabling Yii2 gridview view button with modal dialog. However, i implemented a "create new" button above the gridview which opens up a modal too. Now when i click on the view button on gridview which opens up a modal, i close the modal and click on "create new" button. But the content in "create new" button modal opens up showing the same content as the one inside "view

How to update html in sidebar template from modal dialog template with javascript in Google Apps Script?

大兔子大兔子 提交于 2019-11-28 02:00:38
问题 I have a form in a modal dialog. After submiting a form that dialog closes and does some actions in the background. After closing the modal dialog I also want to update html in the sidebar ( without refreshing the sidebar ). I have a div with "loader" id in the sidebar with class hidden (which prevents it to be visible). On modal dialog close I want to remove class hidden from the "loader" div. How do I access that "loader" div from the modal dialog template ? 回答1: You could use the browser