40 lines
895 B
HTML
40 lines
895 B
HTML
<ModalDialog
|
|
{id}
|
|
{label}
|
|
{title}
|
|
background="var(--main-bg)"
|
|
>
|
|
<ComposeBox realm="dialog" size="slim" autoFocus="true" />
|
|
</ModalDialog>
|
|
<script>
|
|
import ModalDialog from './ModalDialog.html'
|
|
import ComposeBox from '../../compose/ComposeBox.html'
|
|
import { on } from '../../../_utils/eventBus'
|
|
import { show } from '../helpers/showDialog'
|
|
import { oncreate as onCreateDialog } from '../helpers/onCreateDialog'
|
|
import { close } from '../helpers/closeDialog'
|
|
|
|
export default {
|
|
oncreate () {
|
|
on('postedStatus', this, this.onPostedStatus)
|
|
onCreateDialog.call(this)
|
|
},
|
|
data: () => ({
|
|
title: void 0
|
|
}),
|
|
methods: {
|
|
show,
|
|
close,
|
|
onPostedStatus (realm) {
|
|
if (realm !== 'dialog') {
|
|
return
|
|
}
|
|
this.close()
|
|
}
|
|
},
|
|
components: {
|
|
ModalDialog,
|
|
ComposeBox
|
|
}
|
|
}
|
|
</script> |