mirror of
https://github.com/ArthurDanjou/ui.git
synced 2026-01-20 15:01:46 +01:00
docs(modal): update
This commit is contained in:
@@ -20,6 +20,10 @@ export interface DrawerProps extends Pick<DrawerRootProps, 'activeSnapPoint' | '
|
||||
description?: string
|
||||
/** The content of the drawer. */
|
||||
content?: Omit<DialogContentProps, 'as' | 'asChild' | 'forceMount'>
|
||||
/**
|
||||
* Render an overlay behind the drawer.
|
||||
* @defaultValue true
|
||||
*/
|
||||
overlay?: boolean
|
||||
/**
|
||||
* Render the drawer in a portal.
|
||||
|
||||
@@ -15,8 +15,20 @@ export interface ModalProps extends DialogRootProps {
|
||||
description?: string
|
||||
/** The content of the modal. */
|
||||
content?: Omit<DialogContentProps, 'as' | 'asChild' | 'forceMount'>
|
||||
/**
|
||||
* Render an overlay behind the modal.
|
||||
* @defaultValue true
|
||||
*/
|
||||
overlay?: boolean
|
||||
/**
|
||||
* Animate the modal when opening or closing.
|
||||
* @defaultValue true
|
||||
*/
|
||||
transition?: boolean
|
||||
/**
|
||||
* When `true`, the modal will take up the full screen.
|
||||
* @defaultValue false
|
||||
*/
|
||||
fullscreen?: boolean
|
||||
/**
|
||||
* Render the modal in a portal.
|
||||
@@ -34,7 +46,10 @@ export interface ModalProps extends DialogRootProps {
|
||||
* @defaultValue appConfig.ui.icons.close
|
||||
*/
|
||||
closeIcon?: string
|
||||
/** When `true`, the modal will not close when clicking outside. */
|
||||
/**
|
||||
* When `true`, the modal will not close when clicking outside.
|
||||
* @defaultValue false
|
||||
*/
|
||||
preventClose?: boolean
|
||||
class?: any
|
||||
ui?: Partial<typeof modal.slots>
|
||||
@@ -65,7 +80,8 @@ const props = withDefaults(defineProps<ModalProps>(), {
|
||||
close: true,
|
||||
portal: true,
|
||||
overlay: true,
|
||||
transition: true
|
||||
transition: true,
|
||||
modal: true
|
||||
})
|
||||
const emits = defineEmits<ModalEmits>()
|
||||
const slots = defineSlots<ModalSlots>()
|
||||
|
||||
@@ -18,12 +18,12 @@ export interface SlideoverProps extends DialogRootProps {
|
||||
/** The content of the slideover. */
|
||||
content?: Omit<DialogContentProps, 'as' | 'asChild' | 'forceMount'>
|
||||
/**
|
||||
* Display an overlay behind the slideover.
|
||||
* Render an overlay behind the slideover.
|
||||
* @defaultValue true
|
||||
*/
|
||||
overlay?: boolean
|
||||
/**
|
||||
* Open & close the slideover with a transition.
|
||||
* Animate the slideover when opening or closing.
|
||||
* @defaultValue true
|
||||
*/
|
||||
transition?: boolean
|
||||
@@ -44,7 +44,10 @@ export interface SlideoverProps extends DialogRootProps {
|
||||
* @defaultValue appConfig.ui.icons.close
|
||||
*/
|
||||
closeIcon?: string
|
||||
/** When `true`, the slideover will not close when clicking outside. */
|
||||
/**
|
||||
* When `true`, the slideover will not close when clicking outside.
|
||||
* @defaultValue false
|
||||
*/
|
||||
preventClose?: boolean
|
||||
class?: any
|
||||
ui?: Partial<typeof slideover.slots>
|
||||
@@ -76,6 +79,7 @@ const props = withDefaults(defineProps<SlideoverProps>(), {
|
||||
portal: true,
|
||||
overlay: true,
|
||||
transition: true,
|
||||
modal: true,
|
||||
side: 'right'
|
||||
})
|
||||
const emits = defineEmits<SlideoverEmits>()
|
||||
|
||||
Reference in New Issue
Block a user