refactor(frontend): signinRequired -> ensureSignin
This commit is contained in:
parent
22b0ace8b4
commit
a773f2976d
26 changed files with 51 additions and 51 deletions
|
|
@ -117,9 +117,9 @@ import MkFolder from '@/components/MkFolder.vue';
|
|||
import MkInfo from '@/components/MkInfo.vue';
|
||||
import MkLink from '@/components/MkLink.vue';
|
||||
import { confetti } from '@/utility/confetti.js';
|
||||
import { signinRequired } from '@/i.js';
|
||||
import { ensureSignin } from '@/i.js';
|
||||
|
||||
const $i = signinRequired();
|
||||
const $i = ensureSignin();
|
||||
|
||||
defineProps<{
|
||||
twoFactorData: {
|
||||
|
|
|
|||
|
|
@ -92,11 +92,11 @@ import FormSection from '@/components/form/section.vue';
|
|||
import MkFolder from '@/components/MkFolder.vue';
|
||||
import MkLink from '@/components/MkLink.vue';
|
||||
import * as os from '@/os.js';
|
||||
import { signinRequired } from '@/i.js';
|
||||
import { ensureSignin } from '@/i.js';
|
||||
import { i18n } from '@/i18n.js';
|
||||
import { updateCurrentAccountPartial } from '@/accounts.js';
|
||||
|
||||
const $i = signinRequired();
|
||||
const $i = ensureSignin();
|
||||
|
||||
// メモ: 各エンドポイントはmeUpdatedを発行するため、refreshAccountは不要
|
||||
|
||||
|
|
|
|||
|
|
@ -16,9 +16,9 @@ SPDX-License-Identifier: AGPL-3.0-only
|
|||
|
||||
<script lang="ts" setup>
|
||||
import { computed } from 'vue';
|
||||
import { signinRequired } from '@/i.js';
|
||||
import { ensureSignin } from '@/i.js';
|
||||
|
||||
const $i = signinRequired();
|
||||
const $i = ensureSignin();
|
||||
|
||||
const props = defineProps<{
|
||||
active?: boolean;
|
||||
|
|
|
|||
|
|
@ -51,9 +51,9 @@ import MkModalWindow from '@/components/MkModalWindow.vue';
|
|||
import MkSwitch from '@/components/MkSwitch.vue';
|
||||
import { i18n } from '@/i18n.js';
|
||||
import MkRange from '@/components/MkRange.vue';
|
||||
import { signinRequired } from '@/i.js';
|
||||
import { ensureSignin } from '@/i.js';
|
||||
|
||||
const $i = signinRequired();
|
||||
const $i = ensureSignin();
|
||||
|
||||
const props = defineProps<{
|
||||
usingIndex: number | null;
|
||||
|
|
|
|||
|
|
@ -54,11 +54,11 @@ import MkButton from '@/components/MkButton.vue';
|
|||
import * as os from '@/os.js';
|
||||
import { misskeyApi } from '@/utility/misskey-api.js';
|
||||
import { i18n } from '@/i18n.js';
|
||||
import { signinRequired } from '@/i.js';
|
||||
import { ensureSignin } from '@/i.js';
|
||||
import MkInfo from '@/components/MkInfo.vue';
|
||||
import { definePage } from '@/page.js';
|
||||
|
||||
const $i = signinRequired();
|
||||
const $i = ensureSignin();
|
||||
|
||||
const loading = ref(true);
|
||||
const avatarDecorations = ref<Misskey.entities.GetAvatarDecorationsResponse>([]);
|
||||
|
|
|
|||
|
|
@ -104,12 +104,12 @@ import bytes from '@/filters/bytes.js';
|
|||
import MkChart from '@/components/MkChart.vue';
|
||||
import { i18n } from '@/i18n.js';
|
||||
import { definePage } from '@/page.js';
|
||||
import { signinRequired } from '@/i.js';
|
||||
import { ensureSignin } from '@/i.js';
|
||||
import { prefer } from '@/preferences.js';
|
||||
import MkPreferenceContainer from '@/components/MkPreferenceContainer.vue';
|
||||
import MkFeatureBanner from '@/components/MkFeatureBanner.vue';
|
||||
|
||||
const $i = signinRequired();
|
||||
const $i = ensureSignin();
|
||||
|
||||
const fetching = ref(true);
|
||||
const usage = ref<number | null>(null);
|
||||
|
|
|
|||
|
|
@ -67,12 +67,12 @@ import MkSwitch from '@/components/MkSwitch.vue';
|
|||
import MkDisableSection from '@/components/MkDisableSection.vue';
|
||||
import * as os from '@/os.js';
|
||||
import { misskeyApi } from '@/utility/misskey-api.js';
|
||||
import { signinRequired } from '@/i.js';
|
||||
import { ensureSignin } from '@/i.js';
|
||||
import { i18n } from '@/i18n.js';
|
||||
import { definePage } from '@/page.js';
|
||||
import { instance } from '@/instance.js';
|
||||
|
||||
const $i = signinRequired();
|
||||
const $i = ensureSignin();
|
||||
|
||||
const emailAddress = ref($i.email);
|
||||
|
||||
|
|
|
|||
|
|
@ -68,10 +68,10 @@ import MkUserInfo from '@/components/MkUserInfo.vue';
|
|||
import * as os from '@/os.js';
|
||||
import { misskeyApi } from '@/utility/misskey-api.js';
|
||||
import { i18n } from '@/i18n.js';
|
||||
import { signinRequired } from '@/i.js';
|
||||
import { ensureSignin } from '@/i.js';
|
||||
import { unisonReload } from '@/utility/unison-reload.js';
|
||||
|
||||
const $i = signinRequired();
|
||||
const $i = ensureSignin();
|
||||
|
||||
const moveToAccount = ref('');
|
||||
const movedTo = ref<Misskey.entities.UserDetailed>();
|
||||
|
|
|
|||
|
|
@ -19,11 +19,11 @@ import { ref, watch } from 'vue';
|
|||
import MkTextarea from '@/components/MkTextarea.vue';
|
||||
import MkInfo from '@/components/MkInfo.vue';
|
||||
import MkButton from '@/components/MkButton.vue';
|
||||
import { signinRequired } from '@/i.js';
|
||||
import { ensureSignin } from '@/i.js';
|
||||
import { misskeyApi } from '@/utility/misskey-api.js';
|
||||
import { i18n } from '@/i18n.js';
|
||||
|
||||
const $i = signinRequired();
|
||||
const $i = ensureSignin();
|
||||
|
||||
const instanceMutes = ref($i.mutedInstances.join('\n'));
|
||||
const changed = ref(false);
|
||||
|
|
|
|||
|
|
@ -188,7 +188,7 @@ import { definePage } from '@/page.js';
|
|||
import MkUserCardMini from '@/components/MkUserCardMini.vue';
|
||||
import * as os from '@/os.js';
|
||||
import { instance, infoImageUrl } from '@/instance.js';
|
||||
import { signinRequired } from '@/i.js';
|
||||
import { ensureSignin } from '@/i.js';
|
||||
import MkInfo from '@/components/MkInfo.vue';
|
||||
import MkFolder from '@/components/MkFolder.vue';
|
||||
import MkSwitch from '@/components/MkSwitch.vue';
|
||||
|
|
@ -196,7 +196,7 @@ import { reloadAsk } from '@/utility/reload-ask.js';
|
|||
import { prefer } from '@/preferences.js';
|
||||
import MkFeatureBanner from '@/components/MkFeatureBanner.vue';
|
||||
|
||||
const $i = signinRequired();
|
||||
const $i = ensureSignin();
|
||||
|
||||
const renoteMutingPagination = {
|
||||
endpoint: 'renote-mute/list' as const,
|
||||
|
|
|
|||
|
|
@ -75,14 +75,14 @@ import FormSection from '@/components/form/section.vue';
|
|||
import MkFolder from '@/components/MkFolder.vue';
|
||||
import MkSwitch from '@/components/MkSwitch.vue';
|
||||
import * as os from '@/os.js';
|
||||
import { signinRequired } from '@/i.js';
|
||||
import { ensureSignin } from '@/i.js';
|
||||
import { misskeyApi } from '@/utility/misskey-api.js';
|
||||
import { i18n } from '@/i18n.js';
|
||||
import { definePage } from '@/page.js';
|
||||
import MkPushNotificationAllowButton from '@/components/MkPushNotificationAllowButton.vue';
|
||||
import MkFeatureBanner from '@/components/MkFeatureBanner.vue';
|
||||
|
||||
const $i = signinRequired();
|
||||
const $i = ensureSignin();
|
||||
|
||||
const nonConfigurableNotificationTypes = ['note', 'roleAssigned', 'followRequestAccepted', 'test', 'exportCompleted'] satisfies (typeof notificationTypes[number])[] as string[];
|
||||
|
||||
|
|
|
|||
|
|
@ -127,7 +127,7 @@ import MkKeyValue from '@/components/MkKeyValue.vue';
|
|||
import MkButton from '@/components/MkButton.vue';
|
||||
import * as os from '@/os.js';
|
||||
import { misskeyApi } from '@/utility/misskey-api.js';
|
||||
import { signinRequired } from '@/i.js';
|
||||
import { ensureSignin } from '@/i.js';
|
||||
import { i18n } from '@/i18n.js';
|
||||
import { definePage } from '@/page.js';
|
||||
import { reloadAsk } from '@/utility/reload-ask.js';
|
||||
|
|
@ -136,7 +136,7 @@ import { prefer } from '@/preferences.js';
|
|||
import MkRolePreview from '@/components/MkRolePreview.vue';
|
||||
import { signout } from '@/signout.js';
|
||||
|
||||
const $i = signinRequired();
|
||||
const $i = ensureSignin();
|
||||
|
||||
const reportError = prefer.model('reportError');
|
||||
const enableCondensedLine = prefer.model('enableCondensedLine');
|
||||
|
|
|
|||
|
|
@ -184,7 +184,7 @@ import MkFolder from '@/components/MkFolder.vue';
|
|||
import { misskeyApi } from '@/utility/misskey-api.js';
|
||||
import { i18n } from '@/i18n.js';
|
||||
import { instance } from '@/instance.js';
|
||||
import { signinRequired } from '@/i.js';
|
||||
import { ensureSignin } from '@/i.js';
|
||||
import { definePage } from '@/page.js';
|
||||
import FormSlot from '@/components/form/slot.vue';
|
||||
import { formatDateTimeString } from '@/utility/format-time-string.js';
|
||||
|
|
@ -194,7 +194,7 @@ import MkDisableSection from '@/components/MkDisableSection.vue';
|
|||
import MkInfo from '@/components/MkInfo.vue';
|
||||
import MkFeatureBanner from '@/components/MkFeatureBanner.vue';
|
||||
|
||||
const $i = signinRequired();
|
||||
const $i = ensureSignin();
|
||||
|
||||
const isLocked = ref($i.isLocked);
|
||||
const autoAcceptFollowed = ref($i.autoAcceptFollowed);
|
||||
|
|
|
|||
|
|
@ -164,7 +164,7 @@ import FormSlot from '@/components/form/slot.vue';
|
|||
import { selectFile } from '@/utility/select-file.js';
|
||||
import * as os from '@/os.js';
|
||||
import { i18n } from '@/i18n.js';
|
||||
import { signinRequired } from '@/i.js';
|
||||
import { ensureSignin } from '@/i.js';
|
||||
import { langmap } from '@/utility/langmap.js';
|
||||
import { definePage } from '@/page.js';
|
||||
import { claimAchievement } from '@/utility/achievements.js';
|
||||
|
|
@ -173,7 +173,7 @@ import { globalEvents } from '@/events.js';
|
|||
import MkInfo from '@/components/MkInfo.vue';
|
||||
import MkTextarea from '@/components/MkTextarea.vue';
|
||||
|
||||
const $i = signinRequired();
|
||||
const $i = ensureSignin();
|
||||
|
||||
const Sortable = defineAsyncComponent(() => import('vuedraggable').then(x => x.default));
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue