0
0
Bootsrapmarkup~5 mins

Modal sizes and positioning in Bootsrap - Cheat Sheet & Quick Revision

Choose your learning style9 modes available
Recall & Review
beginner
What class in Bootstrap controls the size of a modal?
Bootstrap uses classes like modal-sm, modal-lg, and modal-xl on the .modal-dialog element to control modal sizes.
Click to reveal answer
beginner
How do you center a Bootstrap modal vertically?
Add the class modal-dialog-centered to the .modal-dialog element to vertically center the modal in the viewport.
Click to reveal answer
intermediate
Which Bootstrap class makes a modal full screen on all devices?
Use the class modal-fullscreen on the .modal-dialog element to make the modal cover the entire screen.
Click to reveal answer
beginner
What is the default horizontal alignment of a Bootstrap modal?
By default, Bootstrap modals are horizontally centered in the viewport without extra classes.
Click to reveal answer
intermediate
How can you make a modal scrollable if its content is too tall?
Add the class modal-dialog-scrollable to the .modal-dialog element to enable vertical scrolling inside the modal body.
Click to reveal answer
Which class would you add to make a Bootstrap modal larger than the default size?
Amodal-lg
Bmodal-center
Cmodal-small
Dmodal-fullscreen
How do you vertically center a Bootstrap modal?
AAdd <code>modal-center</code> to <code>.modal</code>
BAdd <code>modal-dialog-centered</code> to <code>.modal-dialog</code>
CAdd <code>centered</code> to <code>.modal-content</code>
DAdd <code>modal-vertical</code> to <code>.modal-dialog</code>
Which class makes a Bootstrap modal take up the entire screen?
Amodal-lg
Bmodal-xl
Cmodal-fullscreen
Dmodal-scrollable
If modal content is too tall, which class helps to scroll inside the modal?
Amodal-dialog-scrollable
Bmodal-scroll
Cmodal-scrollbar
Dmodal-content-scroll
What is the default horizontal alignment of Bootstrap modals?
ATop aligned
BAligned left
CAligned right
DCentered horizontally
Explain how to change the size of a Bootstrap modal and give examples of classes used.
Think about classes added to the modal dialog to control width.
You got /5 concepts.
    Describe how to position a Bootstrap modal vertically centered and how to handle tall content inside it.
    Consider classes that affect vertical alignment and scrolling.
    You got /4 concepts.