2018-02-20 15:53:34 +02:00
|
|
|
import PostFormWindow from '../views/components/post-form-window.vue';
|
2018-04-07 20:30:37 +03:00
|
|
|
import RenoteFormWindow from '../views/components/renote-form-window.vue';
|
2018-02-20 15:53:34 +02:00
|
|
|
|
2018-02-21 19:15:46 +02:00
|
|
|
export default function(opts) {
|
|
|
|
const o = opts || {};
|
2018-04-07 20:30:37 +03:00
|
|
|
if (o.renote) {
|
|
|
|
const vm = new RenoteFormWindow({
|
2018-02-21 19:15:46 +02:00
|
|
|
propsData: {
|
2018-04-07 20:30:37 +03:00
|
|
|
renote: o.renote
|
2018-02-21 19:15:46 +02:00
|
|
|
}
|
|
|
|
}).$mount();
|
|
|
|
document.body.appendChild(vm.$el);
|
|
|
|
} else {
|
|
|
|
const vm = new PostFormWindow({
|
|
|
|
propsData: {
|
|
|
|
reply: o.reply
|
|
|
|
}
|
|
|
|
}).$mount();
|
|
|
|
document.body.appendChild(vm.$el);
|
|
|
|
}
|
2018-02-20 15:53:34 +02:00
|
|
|
}
|