Commit 420c6999 authored by kingweight's avatar kingweight

更新缓存大小

parent 8aa270b1
......@@ -278,7 +278,7 @@ export class FormComponent extends ComponentBase implements OnInit, OnChanges, O
// 尝试保存到 localStorage
const cacheJson = JSON.stringify(existingCache);
const cacheSize = new Blob([cacheJson]).size;
const maxSize = 4 * 1024 * 1024; // 4MB 限制,留一些余量
const maxSize = 100 * 1024 * 1024; // 100MB 限制,留一些余量
if (cacheSize > maxSize) {
console.warn('缩略图缓存大小超出限制,跳过保存到 localStorage');
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment