Improve typing

This commit is contained in:
tamaina
2020-05-26 14:33:55 +09:00
parent 05c7cacdd1
commit 9bee9d20f7
9 changed files with 24 additions and 10 deletions

View File

@ -278,6 +278,9 @@ export default Vue.extend({
(this as any).$root.api('promo/read', {
noteId: this.appearNote.id
});
this.$root.stream.send('readNotification', {
id: notification.id
});
this.hideThisNote = true;
},

View File

@ -67,6 +67,7 @@ import extractMentions from '../../misc/extract-mentions';
import getAcct from '../../misc/acct/render';
import { formatTimeString } from '../../misc/format-time-string';
import { selectDriveFile } from '../scripts/select-drive-file';
import { noteVisibilities } from '../../types'
export default Vue.extend({
components: {
@ -405,7 +406,7 @@ export default Vue.extend({
},
applyVisibility(v: string) {
this.visibility = ['public', 'home', 'followers', 'specified'].includes(v) ? v : 'public'; // v11互換性のため
this.visibility = (noteVisibilities as unknown as string[]).includes(v) ? v : 'public'; // v11互換性のため
},
addVisibleUser() {