improve performance
This commit is contained in:
parent
746fac0dfe
commit
d5aee2ea58
14 changed files with 88 additions and 44 deletions
|
|
@ -66,8 +66,9 @@ import * as os from '@/os';
|
|||
import { defaultStore } from '@/store';
|
||||
import { i18n } from '@/i18n';
|
||||
import { definePageMetadata } from '@/scripts/page-metadata';
|
||||
import { deepClone } from '@/scripts/clone';
|
||||
|
||||
let reactions = $ref(JSON.parse(JSON.stringify(defaultStore.state.reactions)));
|
||||
let reactions = $ref(deepClone(defaultStore.state.reactions));
|
||||
|
||||
const reactionPickerSize = $computed(defaultStore.makeGetterSetter('reactionPickerSize'));
|
||||
const reactionPickerWidth = $computed(defaultStore.makeGetterSetter('reactionPickerWidth'));
|
||||
|
|
@ -101,7 +102,7 @@ async function setDefault() {
|
|||
});
|
||||
if (canceled) return;
|
||||
|
||||
reactions = JSON.parse(JSON.stringify(defaultStore.def.reactions.default));
|
||||
reactions = deepClone(defaultStore.def.reactions.default);
|
||||
}
|
||||
|
||||
function chooseEmoji(ev: MouseEvent) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue