feat:移除废弃的快捷方式
This commit is contained in:
@@ -55,10 +55,6 @@ function toggleDictation() {
|
||||
settingStore.dictation = !settingStore.dictation
|
||||
}
|
||||
|
||||
function openSetting() {
|
||||
runtimeStore.showSettingModal = true
|
||||
}
|
||||
|
||||
function toggleConciseMode() {
|
||||
settingStore.showToolbar = !settingStore.showToolbar
|
||||
settingStore.showPanel = settingStore.showToolbar
|
||||
@@ -83,7 +79,6 @@ onMounted(() => {
|
||||
emitter.on(ShortcutKey.DictationChapter, write)
|
||||
emitter.on(ShortcutKey.ToggleShowTranslate, toggleShowTranslate)
|
||||
emitter.on(ShortcutKey.ToggleDictation, toggleDictation)
|
||||
emitter.on(ShortcutKey.OpenSetting, openSetting)
|
||||
emitter.on(ShortcutKey.ToggleTheme, toggleTheme)
|
||||
emitter.on(ShortcutKey.ToggleConciseMode, toggleConciseMode)
|
||||
emitter.on(ShortcutKey.TogglePanel, togglePanel)
|
||||
@@ -99,7 +94,6 @@ onUnmounted(() => {
|
||||
emitter.off(ShortcutKey.DictationChapter, write)
|
||||
emitter.off(ShortcutKey.ToggleShowTranslate, toggleShowTranslate)
|
||||
emitter.off(ShortcutKey.ToggleDictation, toggleDictation)
|
||||
emitter.off(ShortcutKey.OpenSetting, openSetting)
|
||||
emitter.off(ShortcutKey.ToggleTheme, toggleTheme)
|
||||
emitter.off(ShortcutKey.ToggleConciseMode, toggleConciseMode)
|
||||
emitter.off(ShortcutKey.TogglePanel, togglePanel)
|
||||
|
||||
@@ -132,9 +132,8 @@ function importData(e) {
|
||||
|
||||
<template>
|
||||
<BasePage>
|
||||
<div class="page-title text-align-center">设置</div>
|
||||
<div class="setting">
|
||||
<div class="left">
|
||||
<div class="left mt-10">
|
||||
<div class="tabs">
|
||||
<div class="tab" :class="tabIndex === 0 && 'active'" @click="tabIndex = 0">
|
||||
<Icon icon="bx:headphone" width="20" color="#0C8CE9"/>
|
||||
@@ -161,11 +160,9 @@ function importData(e) {
|
||||
<span>关于</span>
|
||||
</div>
|
||||
</div>
|
||||
<div class="git-log">
|
||||
Build {{ gitLastCommitHash }}
|
||||
</div>
|
||||
</div>
|
||||
<div class="content">
|
||||
<div class="page-title text-align-center">设置</div>
|
||||
<div v-if="tabIndex === 0">
|
||||
<div class="row">
|
||||
<label class="main-title">所有音效</label>
|
||||
@@ -394,7 +391,7 @@ function importData(e) {
|
||||
。如果您需要在不同的设备、浏览器或者其他非官方部署上使用 {{ APP_NAME }}, 您需要手动进行数据同步和保存。
|
||||
</label>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="row mt-2">
|
||||
<BaseButton @click="exportData">数据导出</BaseButton>
|
||||
</div>
|
||||
<div class="row">
|
||||
@@ -453,6 +450,10 @@ function importData(e) {
|
||||
反馈:<a
|
||||
href="https://github.com/zyronon/typing-word/issues">https://github.com/zyronon/typing-word/issues</a>
|
||||
</p>
|
||||
<div class="text-md color-gray">
|
||||
Build {{ gitLastCommitHash }}
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -465,7 +466,6 @@ function importData(e) {
|
||||
color: var(--color-font-1);
|
||||
|
||||
.left {
|
||||
height: 93vh;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: space-between;
|
||||
@@ -492,18 +492,12 @@ function importData(e) {
|
||||
}
|
||||
}
|
||||
|
||||
.git-log {
|
||||
font-size: .6rem;
|
||||
color: gray;
|
||||
margin-bottom: .3rem;
|
||||
}
|
||||
}
|
||||
|
||||
.content {
|
||||
flex: 1;
|
||||
height: 100%;
|
||||
overflow: auto;
|
||||
padding: var(--space);
|
||||
padding: 0 2.6rem;
|
||||
|
||||
.row {
|
||||
|
||||
@@ -50,10 +50,6 @@ function toggleDictation() {
|
||||
settingStore.dictation = !settingStore.dictation
|
||||
}
|
||||
|
||||
function openSetting() {
|
||||
runtimeStore.showSettingModal = true
|
||||
}
|
||||
|
||||
function toggleConciseMode() {
|
||||
settingStore.showToolbar = !settingStore.showToolbar
|
||||
settingStore.showPanel = settingStore.showToolbar
|
||||
@@ -78,7 +74,6 @@ onMounted(() => {
|
||||
emitter.on(ShortcutKey.DictationChapter, write)
|
||||
emitter.on(ShortcutKey.ToggleShowTranslate, toggleShowTranslate)
|
||||
emitter.on(ShortcutKey.ToggleDictation, toggleDictation)
|
||||
emitter.on(ShortcutKey.OpenSetting, openSetting)
|
||||
emitter.on(ShortcutKey.ToggleTheme, toggleTheme)
|
||||
emitter.on(ShortcutKey.ToggleConciseMode, toggleConciseMode)
|
||||
emitter.on(ShortcutKey.TogglePanel, togglePanel)
|
||||
@@ -94,7 +89,6 @@ onUnmounted(() => {
|
||||
emitter.off(ShortcutKey.DictationChapter, write)
|
||||
emitter.off(ShortcutKey.ToggleShowTranslate, toggleShowTranslate)
|
||||
emitter.off(ShortcutKey.ToggleDictation, toggleDictation)
|
||||
emitter.off(ShortcutKey.OpenSetting, openSetting)
|
||||
emitter.off(ShortcutKey.ToggleTheme, toggleTheme)
|
||||
emitter.off(ShortcutKey.ToggleConciseMode, toggleConciseMode)
|
||||
emitter.off(ShortcutKey.TogglePanel, togglePanel)
|
||||
|
||||
@@ -40,10 +40,7 @@ const {toggleTheme} = useTheme()
|
||||
<Icon icon="ph:article-ny-times"/>
|
||||
<span v-if="settingStore.sideExpand">文章</span>
|
||||
</div>
|
||||
<div class="row"
|
||||
:title="`设置(${settingStore.shortcutKeyMap[ShortcutKey.OpenSetting]})`"
|
||||
@click="router.push('/setting')"
|
||||
>
|
||||
<div class="row" @click="router.push('/setting')">
|
||||
<Icon icon="uil:setting"/>
|
||||
<span v-if="settingStore.sideExpand">设置</span>
|
||||
</div>
|
||||
@@ -58,7 +55,6 @@ const {toggleTheme} = useTheme()
|
||||
</div>
|
||||
<div class="bottom flex justify-evenly ">
|
||||
<BaseIcon
|
||||
:title="`收起(${settingStore.shortcutKeyMap[ShortcutKey.OpenSetting]})`"
|
||||
@click="settingStore.sideExpand = !settingStore.sideExpand"
|
||||
:icon="settingStore.sideExpand?'formkit:left':'formkit:right'"/>
|
||||
<Tooltip
|
||||
|
||||
@@ -313,10 +313,6 @@ function toggleDictation() {
|
||||
settingStore.dictation = !settingStore.dictation
|
||||
}
|
||||
|
||||
function openSetting() {
|
||||
runtimeStore.showSettingModal = true
|
||||
}
|
||||
|
||||
function toggleConciseMode() {
|
||||
settingStore.showToolbar = !settingStore.showToolbar
|
||||
settingStore.showPanel = settingStore.showToolbar
|
||||
@@ -348,7 +344,6 @@ useEvents([
|
||||
[ShortcutKey.RepeatChapter, repeat],
|
||||
[ShortcutKey.ToggleShowTranslate, toggleTranslate],
|
||||
[ShortcutKey.ToggleDictation, toggleDictation],
|
||||
[ShortcutKey.OpenSetting, openSetting],
|
||||
[ShortcutKey.ToggleTheme, toggleTheme],
|
||||
[ShortcutKey.ToggleConciseMode, toggleConciseMode],
|
||||
[ShortcutKey.TogglePanel, togglePanel],
|
||||
|
||||
@@ -6,7 +6,6 @@ export interface RuntimeState {
|
||||
modalList: Array<{ id: string | number, close: Function }>
|
||||
editDict: Dict
|
||||
showDictModal: boolean
|
||||
showSettingModal: boolean
|
||||
excludeRoutes: any[]
|
||||
routeData: any,
|
||||
}
|
||||
@@ -19,7 +18,6 @@ export const useRuntimeStore = defineStore('runtime', {
|
||||
modalList: [],
|
||||
editDict: getDefaultDict(),
|
||||
showDictModal: false,
|
||||
showSettingModal: false,
|
||||
excludeRoutes: [],
|
||||
}
|
||||
},
|
||||
@@ -39,4 +37,4 @@ export const useRuntimeStore = defineStore('runtime', {
|
||||
// console.log('store.excludeRoutes', this.excludeRoutes)
|
||||
},
|
||||
}
|
||||
})
|
||||
})
|
||||
|
||||
@@ -186,9 +186,6 @@ export enum ShortcutKey {
|
||||
// PlayTranslatePronunciation = 'PlayTranslatePronunciation',
|
||||
ToggleShowTranslate = 'ToggleShowTranslate',
|
||||
ToggleDictation = 'ToggleDictation',
|
||||
OpenSetting = 'OpenSetting',
|
||||
//todo 废弃
|
||||
OpenDictDetail = 'OpenDictDetail',
|
||||
ToggleTheme = 'ToggleTheme',
|
||||
ToggleConciseMode = 'ToggleConciseMode',
|
||||
TogglePanel = 'TogglePanel'
|
||||
@@ -210,9 +207,7 @@ export const DefaultShortcutKeyMap = {
|
||||
// [ShortcutKey.PlayTranslatePronunciation]: 'Ctrl+O',
|
||||
[ShortcutKey.ToggleShowTranslate]: 'Ctrl+Z',
|
||||
[ShortcutKey.ToggleDictation]: 'Ctrl+I',
|
||||
[ShortcutKey.OpenSetting]: 'Ctrl+S',
|
||||
[ShortcutKey.ToggleTheme]: 'Ctrl+Q',
|
||||
[ShortcutKey.OpenDictDetail]: 'Ctrl+J',
|
||||
[ShortcutKey.ToggleConciseMode]: 'Ctrl+M',
|
||||
[ShortcutKey.TogglePanel]: 'Ctrl+L',
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user