This commit is contained in:
syuilo 2018-02-22 02:15:46 +09:00
parent abf1c30ce6
commit 73029df58a
6 changed files with 53 additions and 17 deletions

View file

@ -1,6 +1,21 @@
import PostFormWindow from '../views/components/post-form-window.vue';
import RepostFormWindow from '../views/components/repost-form-window.vue';
export default function() {
const vm = new PostFormWindow().$mount();
document.body.appendChild(vm.$el);
export default function(opts) {
const o = opts || {};
if (o.repost) {
const vm = new RepostFormWindow({
propsData: {
repost: o.repost
}
}).$mount();
document.body.appendChild(vm.$el);
} else {
const vm = new PostFormWindow({
propsData: {
reply: o.reply
}
}).$mount();
document.body.appendChild(vm.$el);
}
}