mirror of
https://github.com/silenty4ng/k5web
synced 2025-01-09 13:24:38 +00:00
update
This commit is contained in:
parent
300d51f79b
commit
92fcd4f7b3
2 changed files with 26 additions and 1 deletions
BIN
public/new_font_k_f.bin
Normal file
BIN
public/new_font_k_f.bin
Normal file
Binary file not shown.
|
@ -14,6 +14,12 @@
|
||||||
</template>
|
</template>
|
||||||
<a-button @click="restore(1)">{{ $t('tool.writefontwrite') }}</a-button>
|
<a-button @click="restore(1)">{{ $t('tool.writefontwrite') }}</a-button>
|
||||||
</t-card>
|
</t-card>
|
||||||
|
<t-card bordered v-show="state.showHide >= 5">
|
||||||
|
<template #header>
|
||||||
|
{{ $t('tool.fontwrite') }}(繁體)
|
||||||
|
</template>
|
||||||
|
<a-button @click="restore(6)">{{ $t('tool.writefontwrite') }}</a-button>
|
||||||
|
</t-card>
|
||||||
<t-card bordered>
|
<t-card bordered>
|
||||||
<template #header>
|
<template #header>
|
||||||
{{ $t('tool.pinyinwrite') }}
|
{{ $t('tool.pinyinwrite') }}
|
||||||
|
@ -145,6 +151,25 @@ const restore = async(type: any = 1) => {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if(type == 6){
|
||||||
|
if(appStore.configuration?.charset == "gb2312"){
|
||||||
|
fontPacket = await fetch('/new_font_k_f.bin')
|
||||||
|
const reader = fontPacket.body.getReader();
|
||||||
|
const chunks = [];
|
||||||
|
while(true) {
|
||||||
|
const {done, value} = await reader.read();
|
||||||
|
if (done) {
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
chunks.push(...value)
|
||||||
|
}
|
||||||
|
const binary = new Uint8Array(chunks)
|
||||||
|
await restoreRange(0x02480, binary)
|
||||||
|
return;
|
||||||
|
}else{
|
||||||
|
alert('不支持的版本')
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue