This commit is contained in:
syuilo 2018-02-18 23:51:41 +09:00
parent 2a54802efa
commit e01b9d3f16
22 changed files with 142 additions and 129 deletions

View file

@ -23,7 +23,7 @@ export default Vue.extend({
data() {
return {
text: null,
files: [],
file: null,
sending: false
};
},
@ -49,17 +49,17 @@ export default Vue.extend({
},
chooseFileFromDrive() {
const w = new MkDriveChooserWindow({
propsData: {
multiple: true
}
}).$mount();
w.$once('selected', files => {
files.forEach(this.addFile);
(this as any).apis.chooseDriveFile({
multiple: false
}).then(file => {
this.file = file;
});
document.body.appendChild(w.$el);
},
upload() {
// TODO
}
send() {
this.sending = true;
(this as any).api('messaging/messages/create', {