lint
This commit is contained in:
parent
ac8d0f133e
commit
1fce71a7d7
|
@ -274,7 +274,7 @@ const maxTextLength = computed((): number => {
|
|||
|
||||
const canPost = computed((): boolean => {
|
||||
return !props.mock && !posting.value && !posted.value &&
|
||||
(1 <= textLength.value || 1 <= files.value.length || !!poll.value || !!props.renote || !!event) &&
|
||||
(1 <= textLength.value || 1 <= files.value.length || !!poll.value || !!props.renote || !!event.value) &&
|
||||
(textLength.value <= maxTextLength.value) &&
|
||||
(!poll.value || poll.value.choices.length >= 2);
|
||||
});
|
||||
|
@ -425,10 +425,10 @@ function togglePoll() {
|
|||
}
|
||||
|
||||
function toggleEvent() {
|
||||
if (event) {
|
||||
event = null;
|
||||
if (event.value) {
|
||||
event.value = null;
|
||||
} else {
|
||||
event = {
|
||||
event.value = {
|
||||
title: '',
|
||||
start: (new Date()).toString(),
|
||||
end: null,
|
||||
|
@ -1031,7 +1031,7 @@ onMounted(() => {
|
|||
};
|
||||
}
|
||||
if (init.event) {
|
||||
event = {
|
||||
event.value = {
|
||||
title: init.event.title,
|
||||
start: init.event.start,
|
||||
end: init.event.end,
|
||||
|
|
|
@ -92,7 +92,7 @@ const prepend = note => {
|
|||
|
||||
const prependFilterdMedia = note => {
|
||||
if (note.files !== null && note.files.length > 0) {
|
||||
tlComponent.pagingComponent?.prepend(note);
|
||||
tlComponent.value.pagingComponent?.prepend(note);
|
||||
}
|
||||
|
||||
emit('note');
|
||||
|
|
|
@ -108,8 +108,8 @@ const search = () => {
|
|||
};
|
||||
|
||||
const searchLocal = () => {
|
||||
if (username === '') {
|
||||
users = [];
|
||||
if (username.value === '') {
|
||||
users.value = [];
|
||||
return;
|
||||
}
|
||||
os.api('users/search', {
|
||||
|
@ -118,7 +118,7 @@ const searchLocal = () => {
|
|||
limit: 10,
|
||||
detail: false,
|
||||
}).then(_users => {
|
||||
users = _users;
|
||||
users.value = _users;
|
||||
});
|
||||
};
|
||||
|
||||
|
|
|
@ -175,7 +175,7 @@ function deleteResolver(id: string): void {
|
|||
os.apiWithDialog('admin/abuse-report-resolver/delete', {
|
||||
resolverId: id,
|
||||
}).then(() => {
|
||||
resolverPagingComponent?.value.reload();
|
||||
resolverPagingComponent.value.reload();
|
||||
});
|
||||
}
|
||||
|
||||
|
@ -188,8 +188,8 @@ function create(): void {
|
|||
expiresAt: newResolver.value.expiresAt,
|
||||
forward: newResolver.value.forward,
|
||||
}).then(() => {
|
||||
folderComponent?.value.toggle();
|
||||
resolverPagingComponent?.value.reload();
|
||||
folderComponent.value.toggle();
|
||||
resolverPagingComponent.value.reload();
|
||||
newResolver.value.name = '';
|
||||
newResolver.value.targetUserPattern = '';
|
||||
newResolver.value.reporterPattern = '';
|
||||
|
|
|
@ -49,7 +49,7 @@ SPDX-License-Identifier: AGPL-3.0-only
|
|||
</template>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import {computed} from 'vue';
|
||||
import { computed } from 'vue';
|
||||
import * as mfm from 'cherrypick-mfm-js';
|
||||
import * as Misskey from 'cherrypick-js';
|
||||
import * as os from '@/os.js';
|
||||
|
|
|
@ -259,7 +259,7 @@ provideMetadataReceiver((info) => {
|
|||
childInfo.value = null;
|
||||
} else {
|
||||
childInfo.value = info;
|
||||
INFO.value.needWideArea = info.value?.needWideArea ?? undefined;
|
||||
INFO.value.needWideArea = info.value.needWideArea ?? undefined;
|
||||
}
|
||||
});
|
||||
|
||||
|
|
|
@ -153,9 +153,9 @@ function save() {
|
|||
volume: volume.value,
|
||||
});
|
||||
|
||||
saved = true;
|
||||
saved.value = true;
|
||||
window.setTimeout(() => {
|
||||
saved = false;
|
||||
saved.value = false;
|
||||
}, 500);
|
||||
|
||||
// os.success();
|
||||
|
|
|
@ -52,12 +52,12 @@ function showMenu(ev: MouseEvent) {
|
|||
}, {
|
||||
text: i18n.ts.following,
|
||||
action: () => {
|
||||
chartSrc = 'per-user-following';
|
||||
chartSrc.value = 'per-user-following';
|
||||
},
|
||||
}, {
|
||||
text: i18n.ts.followers,
|
||||
action: () => {
|
||||
chartSrc = 'per-user-followers';
|
||||
chartSrc.value = 'per-user-followers';
|
||||
},
|
||||
}], ev.currentTarget ?? ev.target);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue