1
0
mirror of https://github.com/misskey-dev/misskey.git synced 2026-05-21 16:55:33 +02:00

fix: review fixes (#17208)

* fix: OAuthのContent-Typeを正しく判定するように

* fix(frontend): fix outdated comments

* fix: storagePersistenceのtop-level awaitを解消

* fix

* fix(frontend): add comment

Co-Authored-By: anatawa12 <anatawa12@icloud.com>

* fix

* fix: rename `users/get-following-users-by-birthday`

* fix: fix types

* Update MkForm.vue

* refactor utility/storage.ts

---------

Co-authored-by: anatawa12 <anatawa12@icloud.com>
Co-authored-by: syuilo <4439005+syuilo@users.noreply.github.com>
This commit is contained in:
かっこかり
2026-03-05 19:24:30 +09:00
committed by GitHub
parent 810faa8e5d
commit 3980b2ca55
20 changed files with 48 additions and 33 deletions

View File

@@ -3,13 +3,21 @@
* SPDX-License-Identifier: AGPL-3.0-only
*/
import { ref } from 'vue';
import { readonly, ref } from 'vue';
import * as os from '@/os.js';
import { store } from '@/store.js';
import { i18n } from '@/i18n.js';
export const storagePersistenceSupported = window.isSecureContext && 'storage' in navigator;
export const storagePersisted = ref(storagePersistenceSupported ? await navigator.storage.persisted() : false);
const storagePersisted = ref(false);
export async function getStoragePersistenceStatusRef() {
if (storagePersistenceSupported) {
storagePersisted.value = await navigator.storage.persisted().catch(() => false);
}
return readonly(storagePersisted);
}
export async function enableStoragePersistence() {
if (!storagePersistenceSupported) return;