magiccube-vue3
Version:
vue3-js版组件库
24 lines (21 loc) • 541 B
JavaScript
import Confirm from './confirm'
import Alert from './alert'
import Toast from './toast'
/**
* How to use toast?
* import { toast } from 'message'
* toast('content here...')
* ----
* How to use confirm and alert?
* import { message } from 'message
* message.alert({opt...})
* message.confirm({opt...}).then(state => ...) // state: confirm / cancel/ close
* ----
* What is close state?
* close state is action when you click on mask
*/
export const toast = Toast
export const message = {
confirm: Confirm,
alert: Alert
}