I am looking for a solution for display a window over the page like a dialog box but this box will contains a lot of information. It is for my betting game, i display a list of game with a choice between 1 N and 2.
Here is an image of a betting game named netbet :
As you can see i have selected 2.10 in the game Slavia Mozyr/ FC Minsk and a window appears at the bottom of the page for set the amount of money i need to bet. I think it will be better,because mobile screen are very little, displaying a window over the page like a dialog box. Is there a solution for do that in flutter ? Thanks
You might want to use Bottom sheet which does the exact task. It opens a small 'page' (read: widget) over the normal app screen. It'll allow to place the bet etc. It vanishes when use taps anywhere outside.
Sample implementation is here. You can also check solid bottom sheet.
Related
As part of a training, I'm trying to duplicate this Liberation newspaper mobile application in Flutter. I have a lot of questions about how both the menu that you can scroll like a carousel sideways but also the ability to switch between menus by Swiping from anywhere on the screen to the left or right, which takes you back to the next or previous menu.
Here is the link to a ten second video of the application I want to copy : https://drive.google.com/file/d/1FgHvWh6bggfKGzb5CBFdwWhkM167R0Ne/view
If anyone can take the time to advise me, that would be great, thanks a lot :-)
I've just started on a new project of my own.
What I would like to do is, on large screens, having a button activating a modal window BUT, on smaller screen (mobiles), I would like that modal window to become an off canvas section and when the button is clicked, the off canvas slides in from the side. Within that modal/off canvas part, there will be a form to fill out. (there will actually be multiple buttons that will need to activate the feature. Think something like multiple thumbnails with each a button to let viewers add comments)
I'm using Bootstrap 3 as my base framework. I would like to minimise the javascript (jQuery) functionalities but I understand I can't completely.
Questions I have,
do I have to create two HTML sections, one for the modal and one for the off canvas and then programatically hide/show according screen size?
Would it be best to create the form and then thru javascript, add the proper HTML around it according screen size? (though I think this option would be a tough to implement as my javascript skills are "advance beginner" at best)
How would I make the same button switch activation of the modal window or the off canvas form?
It seems to me that I need to detect screen size, no matter how I do the above, what would be the best way to detect the screen size, the safest and surest way?
Thanks for any insights you guys might have on this.
You will have to show code in your questions here, so i also vote to close your question.
I'm using Bootstrap 3 as my base framework. I would like to minimise
the javascript (jQuery) functionalities but I understand I can't
completely.
Angular JS decouples Twitter's Bootstrap from javascript. See: http://angular-ui.github.io/bootstrap/
Questions I have, do I have to create two HTML sections, one for the
modal and one for the off canvas and then programatically hide/show
according screen size?
Take a look to the Responsive Utilities: http://getbootstrap.com/css/#responsive-utilities
The screen detection of Twitter's Bootstrap is based on CSS media queries.
How would I make the same button switch activation of the modal window or the off canvas >form?
To give the same button different function based on sceensize you will need javascript / jQuery. See: Get the size of the screen, current web page and browser window you also could consider to use something like enquire.js, see also http://bassjobsen.weblogs.fm/responsive-banner-ads-2/
Or create two buttons and hide / show them with the the Responsive Utilities.
I can not solve my problem. As example, my website : www.mananaseguro.com.
In the home page, I have some popup appearing just under movies's poster (when the mouse is over the poster). But when I scroll UP (for example), the popup will not appear just under the poster. Their is a space between them. I tried to add the popup to the home's page panel but it did not succeed.
So is it possible to simulate the good popup behavior? (the popup must stay under the poster).
Or more precisely, is it possible to attach a DecoratedPopupPanel to another panel inside the page in order to have the popup scrolling in the same way that others elements?
Try using the PopupPanel#showRelativeTo() method.
You can achive good popup behavior by using below property.
popup.setPopupPosition(left, top)
Pass movie image x and y index position in top and left. and make consistent look and fill.
As you may know not long time ago facebook added several new features. One of them was a "New Stories" button which when clicked expands (with what I guess is a slideToggle effect) and shows new stories.
Here is the button I am talking about:
I would like to know How to achieve same slide / toggle effect and fade in effect that comes in after this button is clicked, with a help of jQuery.
I tried searching for this on internet, but all effects I found were regular slideToggle effects, I mean they started showing div from top and slided down to it's bottom (here is what I mean by regular content http://jsfiddle.net/TwxB4/), where as one facebook uses starts from the bottom of the hidden div and sort of slides to the top of it. (You will see what I mean if you check it on facebook).
Edit: I am only looking for a slideToggle effect and nothing else, I want to be abble to expand and shrink hidden div when user clicks on the link that lunches the effect.
Edit: Here is an illustration of the effect I'm looking for:
This example works the way you described, showing bottom content first:
http://jsfiddle.net/SBLNn/16/
Also full screen view here:
http://jsfiddle.net/SBLNn/16/embedded/result/
They may also do it by having the overflow of the feed hidden, and then setting a negative margin on the inner feed wrapper, then when you click they just animate that negative margin down to 0.
Does this works for you
http://jsfiddle.net/wb7h6/1/
updated version
http://jsfiddle.net/wb7h6/9/ I hope this is what you need
You want slideToggle() I think. See this jsFiddle.
I'm having a sort out of my (Delphi) applications and I been visiting the floating form size and location persistence which seems to be increasingly important with larger screen real-estate and multi-monitors. Clearly it is often desireable to have a user's form reopen in the same place as they closed it, but maybe not always, for example a modal dialog might justify opening bang in front of the users vision, i.e on the primary monitor center screen. There seems to be little out there on the 'net about this and commercial applications seem inconsistent especially regarding multiple monitors. So, a few (probably contravertial!) rules to get us started...
Non-modal forms should always reopen at the size and location of closure.
Modal forms (i.e with OK/cancel, Yes/No buttons) should reopen at the
previous size (if sizeable), but inthe center of the monitor on which the application resides.
An information message box should open in the center of the monitor on which the application resides.
A warning or error dialog should open in the center of the primary monitor.
Thanks in advance,
Brian
"Non-modal forms should always reopen at the size and location of closure."
They must have a default position and size when they first open. Do you have
any rules about this?
I would add the qualifier: If the screen resolution/monitor count is
different from the last time this form was opened, then it reverts to default
position. So no inaccessible forms restored 400 pixels to the right and below
the screen area.
"A warning or error dialog should open in the centre of the primary monitor."
I don't understand why you move the messagebox from 'monitor where the app
resides' (henceforth MWTAR) to the primary monitor. You know the punter is
looking at the MWTAR; after all he has just done something 'bad'. Why are you
changing monitors now you have something important to say?
(After all, if it is an error dialog containing useful diagnostics, he won't
read it anyway. I don't see the need to hide it from him.)
A further thought. One problem with error modal dialogs is that, wherever they pop up, the user may hit 'Enter' accidentally while typing something else and dismiss it. I know I do this quite often.
One trick I have seen to overcome this is to disable the Ok button when the dialog is first displayed. There is a 3 second timer in the dialog which counts down, displaying the time remaining in a small label attached to the button. So the punter knows he will be able to dismiss the thing soon.
Obviously this must be used very, very sparingly, and only on the rarest and most important of dialogs. But it struck me as quite clever. Perhaps all that needs doing is to make Ok the default button after three seconds.
A dialog should never open in the center of the monitor. Consider one of the 30" monitors with 2560 x 1600 pixels resolution - using an application maximized on one of these monitors makes sense only in very specific cases. If an application form resides in one of the corners of that huge screen area then the user would need to move the mouse cursor from its current location to the center of the screen, and back after dismissing the dialog. Also, with a normal viewing distance it's probably impossible to have all of that screen in view at the same time, so center of the active window will be more "in front of the users vision" than the screen center. Any dialog that doesn't remember its position should open centered on its parent window. Exceptions should be made for dialogs that are bigger than their parent window (where it makes sense to leave a bit of the parent visible, which makes it more obvious for the user what's going on), and property pages that should appear near the objects they apply to.
I would also think about saving screen positions in percent of the screen area, not in pixels. This way using a laptop with and without a large external screen will always make optimum use of the screen area - using absolute coordinates will either have portions of the screen unused, or windows moved outside of the visible area.
Depending on the platform, when the application does not have focus when throwing up an alert it should avoid taking focus. Too easy for a user typing to dismiss the alert without any chance to read it.
E.g. on Windows make use of the ability to flash a task bar button.