-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Modals
Sanya Boriskin edited this page Aug 5, 2019
·
14 revisions
<va-modal
v-model="showModalPositionTop"
title="Simple Popup, Full Width"
message="Message 1"
position="top"
/>
export default {
data () {
return {
showModalPositionTop: false
}
}
// ...
}
-
value
- Boolean - controls visibility of modal -
position
- String - usesize='top'
to set the position of modal. Use one of these values['top', 'right', 'bottom', 'left']
-
size
- String (default: 'medium') - use:size="small"
to set the size of modal. Use one of these values['small', 'medium', 'large']
-
fullscreen
- Boolean (default false) - usefullscreen
to show modal in fullscreen mode -
mobileFullscreen
- Boolean (default: true) - usemobile-fullscreen: false
to prevent fullscreeen mode on mobile devices -
maxWidth
- String - usemax-width
string. You can use any line as in ordinary css.300px, 30%
etc. -
maxHeight
- String (default90vh
) - usemax-height
to change the maximum height of the modal. If content is larger, scroll will appear -
noEscDismiss
- Boolean (default: false) - useno-esc-dismiss: true
to disallow close modal on esc button click -
noOutsideDismiss
- Boolean (default false) - useno-outside-dismiss: true
to disallow close modal when outside modal was clicked -
hideDefaultActions
- Boolean (default: false) - usehideDefaultActions: true
to hide Cancel and Ok buttons -
title
- String -
message
- String -
okText
- String (default: 'OK') - useokText="Some Text Here"
to set text in confirm button -
cancelText
- String (default: 'Cancel') - usecancelText="Some Text Here"
to set text in cancel button -
fixedLayout
- Boolean (default: false) - usefixedLayout: true
to scroll only content in modal. Title and actions will be fixed -
withoutTransitions
- Boolean (default: false) - usewithoutTransitions: true
to turn off the animations on the modal
-
onOk
- action, that happens if user clicks on "OK" button -
onCancel
- action, that happens if user clicks on "Cancel" button or close icon
-
default
- the main content of the modal -
header
- appears after the title in the modal -
actions
- appears after the default actions at the bottom of the modal