🐞 fix: 修复类型错误

This commit is contained in:
底层用户
2025-09-15 12:06:50 +08:00
parent 244a832c52
commit 8e88bf64b1
4 changed files with 5 additions and 2 deletions

2
components.d.ts vendored
View File

@@ -92,9 +92,11 @@ declare module 'vue' {
NOl: typeof import('naive-ui')['NOl'] NOl: typeof import('naive-ui')['NOl']
NP: typeof import('naive-ui')['NP'] NP: typeof import('naive-ui')['NP']
NPopover: typeof import('naive-ui')['NPopover'] NPopover: typeof import('naive-ui')['NPopover']
NProgress: typeof import('naive-ui')['NProgress']
NQrCode: typeof import('naive-ui')['NQrCode'] NQrCode: typeof import('naive-ui')['NQrCode']
NRadio: typeof import('naive-ui')['NRadio'] NRadio: typeof import('naive-ui')['NRadio']
NRadioGroup: typeof import('naive-ui')['NRadioGroup'] NRadioGroup: typeof import('naive-ui')['NRadioGroup']
NResult: typeof import('naive-ui')['NResult']
NScrollbar: typeof import('naive-ui')['NScrollbar'] NScrollbar: typeof import('naive-ui')['NScrollbar']
NSelect: typeof import('naive-ui')['NSelect'] NSelect: typeof import('naive-ui')['NSelect']
NSkeleton: typeof import('naive-ui')['NSkeleton'] NSkeleton: typeof import('naive-ui')['NSkeleton']

View File

@@ -18,7 +18,7 @@ class BlobURLManager {
// console.log("🌱 Blob URL already exists:", key); // console.log("🌱 Blob URL already exists:", key);
return this.blobURLs.get(key)!; return this.blobURLs.get(key)!;
} }
const blob = new Blob([data], { type: format }); const blob = new Blob([new Uint8Array(data)], { type: format });
const blobURL = URL.createObjectURL(blob); const blobURL = URL.createObjectURL(blob);
// 存储 Blob URL // 存储 Blob URL
this.blobURLs.set(key, blobURL); this.blobURLs.set(key, blobURL);

View File

@@ -29,7 +29,7 @@ class Player {
// 频谱数据 // 频谱数据
private audioContext: AudioContext | null = null; private audioContext: AudioContext | null = null;
private analyser: AnalyserNode | null = null; private analyser: AnalyserNode | null = null;
private dataArray: Uint8Array | null = null; private dataArray: Uint8Array<ArrayBuffer> | null = null;
private source: MediaElementAudioSourceNode | null = null; private source: MediaElementAudioSourceNode | null = null;
// 其他数据 // 其他数据
private testNumber: number = 0; private testNumber: number = 0;

View File

@@ -11,6 +11,7 @@
"compilerOptions": { "compilerOptions": {
"composite": true, "composite": true,
"esModuleInterop": true, "esModuleInterop": true,
"moduleResolution": "bundler",
"maxNodeModuleJsDepth": 2, "maxNodeModuleJsDepth": 2,
"baseUrl": ".", "baseUrl": ".",
"paths": { "paths": {