1
0
mirror of https://github.com/misskey-dev/misskey.git synced 2026-05-27 15:24:43 +02:00

lint fixes

This commit is contained in:
syuilo
2025-03-20 19:00:09 +09:00
parent c02f0b3b33
commit 6015254e59
71 changed files with 160 additions and 160 deletions

View File

@@ -226,7 +226,7 @@ export function createSourceNode(buffer: AudioBuffer, opts: {
* @param file ファイルのURLドライブIDではない
*/
export async function getSoundDuration(file: string): Promise<number> {
const audioEl = document.createElement('audio');
const audioEl = window.document.createElement('audio');
audioEl.src = file;
return new Promise((resolve) => {
const si = setInterval(() => {
@@ -249,7 +249,7 @@ export function isMute(): boolean {
}
// noinspection RedundantIfStatementJS
if (prefer.s['sound.useSoundOnlyWhenActive'] && document.visibilityState === 'hidden') {
if (prefer.s['sound.useSoundOnlyWhenActive'] && window.document.visibilityState === 'hidden') {
// ブラウザがアクティブな時のみサウンドを出力する
return true;
}