更新依赖,code lint

pull/1397/head
lyswhut 2023-05-19 22:01:18 +08:00
parent bd5107bbaf
commit fe94a1eac9
74 changed files with 1537 additions and 1210 deletions

119
.eslintrc
View File

@ -1,119 +0,0 @@
{
"root": true,
"extends": [
"standard"
],
"plugins": [
"html"
],
"parser": "@babel/eslint-parser",
"parserOptions": {
// "requireConfigFile": false
},
"rules": {
"no-new": "off",
"camelcase": "off",
"no-return-assign": "off",
"space-before-function-paren": ["error", "never"],
"no-var": "error",
"no-fallthrough": "off",
"prefer-promise-reject-errors": "off",
"eqeqeq": "off",
"no-multiple-empty-lines": [1, {"max": 2}],
"comma-dangle": [2, "always-multiline"],
"standard/no-callback-literal": "off",
"prefer-const": "off",
"no-labels": "off",
"node/no-callback-literal": "off"
},
"ignorePatterns": ["vendors", "*.min.js", "dist"],
"overrides": [
{
"files": [ "*.vue" ],
"rules": {
"no-new": "off",
"camelcase": "off",
"no-return-assign": "off",
"space-before-function-paren": ["error", "never"],
"no-var": "error",
"no-fallthrough": "off",
"prefer-promise-reject-errors": "off",
"eqeqeq": "off",
"no-multiple-empty-lines": [1, {"max": 2}],
"comma-dangle": [2, "always-multiline"],
"standard/no-callback-literal": "off",
"prefer-const": "off",
"no-labels": "off",
"node/no-callback-literal": "off",
"vue/multi-word-component-names": "off",
"@typescript-eslint/strict-boolean-expressions": "off",
"@typescript-eslint/explicit-function-return-type": "off",
"@typescript-eslint/space-before-function-paren": "off",
"@typescript-eslint/no-non-null-assertion": "off",
"@typescript-eslint/naming-convention": "off",
"@typescript-eslint/ban-ts-comment": "off",
"vue/max-attributes-per-line": "off",
"vue/singleline-html-element-content-newline": "off",
"vue/use-v-on-exact": "off",
"@typescript-eslint/restrict-template-expressions": "off",
// "no-undef": "off"
},
"parser": "vue-eslint-parser",
"extends": [
"plugin:vue/base",
// "plugin:vue/strongly-recommended"
"plugin:vue/vue3-recommended",
"standard-with-typescript",
],
"parserOptions": {
"sourceType": "module",
"parser": {
// Script parser for `<script>`
"js": "@typescript-eslint/parser",
// Script parser for `<script lang="ts">`
"ts": "@typescript-eslint/parser"
},
"extraFileExtensions": [".vue"]
}
},
{
"files": [ "*.ts" ],
"rules": {
"no-new": "off",
"camelcase": "off",
"no-return-assign": "off",
"space-before-function-paren": ["error", "never"],
"no-var": "error",
"no-fallthrough": "off",
"prefer-promise-reject-errors": "off",
"eqeqeq": "off",
"no-multiple-empty-lines": [1, {"max": 2}],
"comma-dangle": [2, "always-multiline"],
"standard/no-callback-literal": "off",
"prefer-const": "off",
"no-labels": "off",
"node/no-callback-literal": "off",
"@typescript-eslint/strict-boolean-expressions": "off",
"@typescript-eslint/explicit-function-return-type": "off",
"@typescript-eslint/space-before-function-paren": "off",
"@typescript-eslint/no-non-null-assertion": "off",
"@typescript-eslint/restrict-template-expressions": [1, {
"allowBoolean": true
}],
"@typescript-eslint/naming-convention": "off",
"@typescript-eslint/return-await": "off",
"@typescript-eslint/ban-ts-comment": "off",
"multiline-ternary": "off",
"@typescript-eslint/comma-dangle": "off",
},
"parser": "@typescript-eslint/parser",
"extends": [
"standard-with-typescript"
],
"parserOptions": {
"project": "./src/**/tsconfig.json"
}
}
]
}

91
.eslintrc.cjs Normal file
View File

@ -0,0 +1,91 @@
const javascript = {
'no-new': 'off',
camelcase: 'off',
'no-return-assign': 'off',
'space-before-function-paren': ['error', 'never'],
'no-var': 'error',
'no-fallthrough': 'off',
'prefer-promise-reject-errors': 'off',
eqeqeq: 'off',
'no-multiple-empty-lines': [1, { max: 2 }],
'comma-dangle': [2, 'always-multiline'],
'standard/no-callback-literal': 'off',
'prefer-const': 'off',
'no-labels': 'off',
'node/no-callback-literal': 'off',
'multiline-ternary': 'off',
}
const typescript = {
...javascript,
'@typescript-eslint/strict-boolean-expressions': 'off',
'@typescript-eslint/explicit-function-return-type': 'off',
'@typescript-eslint/space-before-function-paren': 'off',
'@typescript-eslint/no-non-null-assertion': 'off',
'@typescript-eslint/restrict-template-expressions': [1, {
allowBoolean: true,
}],
'@typescript-eslint/naming-convention': 'off',
'@typescript-eslint/return-await': 'off',
'@typescript-eslint/ban-ts-comment': 'off',
'@typescript-eslint/comma-dangle': 'off',
}
const vue = {
...typescript,
'vue/multi-word-component-names': 'off',
'vue/max-attributes-per-line': 'off',
'vue/singleline-html-element-content-newline': 'off',
'vue/use-v-on-exact': 'off',
}
delete vue['@typescript-eslint/restrict-template-expressions']
module.exports = {
root: true,
extends: [
'standard',
],
plugins: [
'html',
],
parser: '@babel/eslint-parser',
parserOptions: {
// "requireConfigFile": false
},
rules: javascript,
ignorePatterns: ['vendors', '*.min.js', 'dist'],
overrides: [
{
files: ['*.vue'],
rules: vue,
parser: 'vue-eslint-parser',
extends: [
'plugin:vue/base',
// "plugin:vue/strongly-recommended"
'plugin:vue/vue3-recommended',
'plugin:vue-pug/vue3-recommended',
'standard-with-typescript',
],
parserOptions: {
sourceType: 'module',
parser: {
// Script parser for `<script>`
js: '@typescript-eslint/parser',
// Script parser for `<script lang="ts">`
ts: '@typescript-eslint/parser',
},
extraFileExtensions: ['.vue'],
},
},
{
files: ['*.ts'],
rules: typescript,
parser: '@typescript-eslint/parser',
extends: [
'standard-with-typescript',
],
parserOptions: {
project: './src/**/tsconfig.json',
},
},
],
}

View File

@ -5,15 +5,24 @@ module.exports = {
'chalk',
'del',
'comlink',
'vue',
'eslint-plugin-n',
],
// target: 'newest',
// filter: [
// 'electron-builder',
// 'electron-updater',
// ],
// target: 'patch',
// filter: [
// 'vue',
// ],
// target: 'minor',
// filter: [
// 'eslint-plugin-n',
// 'electron',
// ],
}

View File

@ -17,6 +17,7 @@ const { Worker, isMainThread, parentPort } = require('worker_threads')
function build() {
console.time('build')
del.sync(['dist/**', 'build/**'])
const spinners = new Spinnies({ color: 'blue' })
@ -36,6 +37,7 @@ function build() {
process.stdout.write('\x1B[2J\x1B[0f')
console.log(`\n\n${results}`)
console.log(`${okayLog}take it away ${chalk.yellow('`electron-builder`')}\n`)
console.timeEnd('build')
process.exit()
}

1250
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@ -213,12 +213,13 @@
"@babel/plugin-transform-runtime": "^7.21.4",
"@babel/preset-env": "^7.21.5",
"@babel/preset-typescript": "^7.21.5",
"@tsconfig/recommended": "^1.0.2",
"@types/better-sqlite3": "^7.6.4",
"@types/needle": "^3.2.0",
"@types/tunnel": "^0.0.3",
"@typescript-eslint/eslint-plugin": "^5.59.2",
"@typescript-eslint/parser": "^5.59.2",
"@volar/vue-language-plugin-pug": "^1.6.4",
"@typescript-eslint/eslint-plugin": "^5.59.6",
"@typescript-eslint/parser": "^5.59.6",
"@volar/vue-language-plugin-pug": "^1.6.5",
"babel-loader": "^9.1.2",
"browserslist": "^4.21.5",
"chalk": "^4.1.2",
@ -226,14 +227,14 @@
"copy-webpack-plugin": "^11.0.0",
"core-js": "^3.30.2",
"cross-env": "^7.0.3",
"css-loader": "^6.7.3",
"css-loader": "^6.7.4",
"css-minimizer-webpack-plugin": "^5.0.0",
"del": "^6.1.1",
"electron": "^22.3.8",
"electron-builder": "^24.3.0",
"electron": "^22.3.10",
"electron-builder": "^24.4.0",
"electron-debug": "^3.2.0",
"electron-devtools-installer": "^3.2.0",
"electron-to-chromium": "^1.4.385",
"electron-to-chromium": "^1.4.401",
"electron-updater": "^6.1.0",
"eslint": "^8.40.0",
"eslint-config-standard": "^17.0.0",
@ -243,32 +244,33 @@
"eslint-plugin-import": "^2.27.5",
"eslint-plugin-n": "^15.7.0",
"eslint-plugin-promise": "^6.1.1",
"eslint-plugin-vue": "^9.11.1",
"eslint-plugin-vue": "^9.13.0",
"eslint-plugin-vue-pug": "^0.6.0",
"eslint-webpack-plugin": "^4.0.1",
"html-webpack-plugin": "^5.5.1",
"less": "^4.1.3",
"less-loader": "^11.1.0",
"mini-css-extract-plugin": "^2.7.5",
"mini-css-extract-plugin": "^2.7.6",
"node-loader": "^2.0.0",
"postcss": "^8.4.23",
"postcss-loader": "^7.3.0",
"postcss-pxtorem": "^6.0.0",
"pug": "^3.0.2",
"pug-plain-loader": "^1.1.0",
"rimraf": "^5.0.0",
"rimraf": "^5.0.1",
"spinnies": "github:lyswhut/spinnies#233305c58694aa3b053e3ab9af9049993f918b9d",
"svg-sprite-loader": "^6.0.11",
"svg-transform-loader": "^2.0.13",
"svgo-loader": "^4.0.0",
"terser": "^5.17.1",
"terser-webpack-plugin": "^5.3.8",
"terser": "^5.17.4",
"terser-webpack-plugin": "^5.3.9",
"ts-loader": "^9.4.2",
"typescript": "^5.0.4",
"vue-eslint-parser": "^9.2.1",
"vue-loader": "^17.1.0",
"vue-eslint-parser": "^9.3.0",
"vue-loader": "^17.1.1",
"vue-template-compiler": "^2.7.14",
"webpack": "^5.82.0",
"webpack-cli": "^5.1.0",
"webpack": "^5.83.1",
"webpack-cli": "^5.1.1",
"webpack-dev-server": "^4.15.0",
"webpack-hot-middleware": "github:lyswhut/webpack-hot-middleware#329c4375134b89d39da23a56a94db651247c74a1",
"webpack-merge": "^5.8.0"
@ -292,8 +294,8 @@
"sortablejs": "^1.15.0",
"tunnel": "^0.0.6",
"utf-8-validate": "^6.0.3",
"vue": "^3.2.47",
"vue-router": "^4.1.6",
"vue": "~3.2.47",
"vue-router": "^4.2.1",
"ws": "^8.13.0"
},
"overrides": {

View File

@ -10,4 +10,4 @@
### 其他
- 更新 electron 到 v22.3.8
- 更新 electron 到 v22.3.10

View File

@ -1,16 +1,11 @@
{
"extends": "../../tsconfig.json",
"compilerOptions": {
"module": "esnext",
"moduleResolution": "nodenext",
"typeRoots": [ /* Specify multiple folders that act like './node_modules/@types'. */
"paths": {
"@common/*": ["common/*"],
},
"typeRoots": [
"./types"
],
},
// "include": [
// "**/*.ts",
// "**/*.js",
// "**/*.vue",
// "**/*.json",
// ],
}

View File

@ -4,24 +4,24 @@
// -------------------------------------------------------------------------------------------------
// Change the following variables to customize the appearance of the particles
var numParticles = window.innerWidth / 50;
var maxSpeed = 2.5;
var minSpeed = 1;
var maxSize = 5;
var minSize = 3;
var maxOpacity = 1;
var minOpacity = 0.2;
let numParticles = window.innerWidth / 50
let maxSpeed = 2.5
let minSpeed = 1
let maxSize = 5
let minSize = 3
let maxOpacity = 1
let minOpacity = 0.2
// If the following is true, the canvas resolution will be set to match the full viewport width and height.
// var fixCanvasResolution = true;
var snow_particles = [];
let snow_particles = []
var canvas
let canvas
window.onload = function() {
canvas = document.createElement('canvas')
canvas.style.position = 'fixed';
canvas.style.position = 'fixed'
canvas.style.top = '0px'
canvas.style.left = '0px'
canvas.style.pointerEvents = 'none'
@ -35,57 +35,57 @@ window.onload = function() {
// canvas.height = window.innerHeight;
// }
InitPoints();
InitPoints()
requestAnimationFrame(Redraw, 15);
window.requestAnimationFrame(Redraw, 15)
window.addEventListener('resize', this.onWindowResize)
}
function onWindowResize (e) {
canvas.width = document.documentElement.clientWidth
canvas.height = document.documentElement.clientHeight
}
// function onWindowResize(e) {
// canvas.width = document.documentElement.clientWidth
// canvas.height = document.documentElement.clientHeight
// }
function Redraw() {
var ctx = canvas.getContext("2d");
ctx.clearRect(0,0,canvas.width,canvas.height);
for (var i = 0; i < snow_particles.length; i++) {
var newYPos = snow_particles[i].yPos + snow_particles[i].speed;
let ctx = canvas.getContext('2d')
ctx.clearRect(0, 0, canvas.width, canvas.height)
for (let i = 0; i < snow_particles.length; i++) {
let newYPos = snow_particles[i].yPos + snow_particles[i].speed
if (newYPos > window.innerHeight) {
newYPos = getRandomInt(-100,-10);
snow_particles[i].xPos = getRandomInt(0, window.innerWidth);
snow_particles[i].speed = Math.random() * (maxSpeed - minSpeed) + minSpeed;
snow_particles[i].opacity = Math.random() * (maxOpacity - minOpacity) + minOpacity;
snow_particles[i].size = Math.random() * (maxSize - minSize) + minSize;
newYPos = getRandomInt(-100, -10)
snow_particles[i].xPos = getRandomInt(0, window.innerWidth)
snow_particles[i].speed = Math.random() * (maxSpeed - minSpeed) + minSpeed
snow_particles[i].opacity = Math.random() * (maxOpacity - minOpacity) + minOpacity
snow_particles[i].size = Math.random() * (maxSize - minSize) + minSize
}
snow_particles[i].yPos = newYPos;
ctx.beginPath();
ctx.arc(snow_particles[i].xPos, newYPos, snow_particles[i].size, 0, 2 * Math.PI);
ctx.fillStyle = "rgba(255, 255, 255, " + snow_particles[i].opacity + ")";
ctx.fill();
snow_particles[i].yPos = newYPos
ctx.beginPath()
ctx.arc(snow_particles[i].xPos, newYPos, snow_particles[i].size, 0, 2 * Math.PI)
ctx.fillStyle = 'rgba(255, 255, 255, ' + snow_particles[i].opacity + ')'
ctx.fill()
}
requestAnimationFrame(Redraw)
window.requestAnimationFrame(Redraw)
}
function InitPoints() {
for (var i = 0; i < numParticles; i++) {
var startX = getRandomInt(0, window.innerWidth);
var startY = getRandomInt(0, window.innerHeight);
var speed = Math.random() * (maxSpeed - minSpeed) + minSpeed;
var opacity = Math.random() * (maxOpacity - minOpacity) + minOpacity;
var size = Math.random() * (maxSize - minSize) + minSize;
for (let i = 0; i < numParticles; i++) {
let startX = getRandomInt(0, window.innerWidth)
let startY = getRandomInt(0, window.innerHeight)
let speed = Math.random() * (maxSpeed - minSpeed) + minSpeed
let opacity = Math.random() * (maxOpacity - minOpacity) + minOpacity
let size = Math.random() * (maxSize - minSize) + minSize
snow_particles.push({
"xPos": startX,
"yPos": startY,
"speed": speed,
"opacity": opacity,
"size": size,
});
xPos: startX,
yPos: startY,
speed,
opacity,
size,
})
}
}
function getRandomInt(min, max) {
min = Math.ceil(min);
max = Math.floor(max);
return Math.floor(Math.random() * (max - min)) + min;
min = Math.ceil(min)
max = Math.floor(max)
return Math.floor(Math.random() * (max - min)) + min
}

View File

@ -17,11 +17,7 @@ import {
type ComputedRef,
type Ref,
type ShallowRef,
defineProps,
defineEmits,
defineComponent,
shallowReactive,
defineExpose,
withDefaults,
} from 'vue'
// import { useStore } from 'vuex'
@ -75,11 +71,7 @@ export {
unref,
onMounted,
markRaw,
defineProps,
defineEmits,
defineComponent,
shallowReactive,
defineExpose,
withDefaults,
}

View File

@ -1,14 +1,8 @@
{
"extends": "../../tsconfig.json",
"compilerOptions": {
"module": "esnext", /* Specify what module code is generated. */
"moduleResolution": "nodenext", /* Specify how TypeScript looks up a file from a given module specifier. */
},
// "include": [
// "**/*.ts",
// "**/*.js",
// "**/*.vue",
// "**/*.json",
// "typeRoots": [
// "./types"
// ],
// "exclude": ["dbService"]
},
}

View File

@ -102,4 +102,4 @@ declare class EventType extends Event {
off<K extends keyof EventMethods>(event: K, listener: EventMethods[K]): this
}
export declare type Type = Omit<EventType, keyof Omit<EventEmitter, 'on' | 'off' | 'once'>>
export type Type = Omit<EventType, keyof Omit<EventEmitter, 'on' | 'off' | 'once'>>

View File

@ -185,4 +185,4 @@ declare class EventType extends Event {
once<K extends keyof EventMethods>(event: K, listener: EventMethods[K]): this
off<K extends keyof EventMethods>(event: K, listener: EventMethods[K]): this
}
export declare type Type = Omit<EventType, keyof Omit<EventEmitter, 'on' | 'off' | 'once'>>
export type Type = Omit<EventType, keyof Omit<EventEmitter, 'on' | 'off' | 'once'>>

View File

@ -6,7 +6,7 @@
*/
import { app } from 'electron'
import * as electronDebug from 'electron-debug'
import electronDebug from 'electron-debug'
import installExtension, { VUEJS_DEVTOOLS } from 'electron-devtools-installer'
// Install `electron-debug` with `devtron`
electronDebug({

View File

@ -1,23 +1,15 @@
{
"extends": "../../tsconfig.json",
"compilerOptions": {
"module": "esnext", /* Specify what module code is generated. */
"moduleResolution": "nodenext", /* Specify how TypeScript looks up a file from a given module specifier. */
// "module": "esnext",
"typeRoots": [
"./types"
],
"paths": { /* Specify a set of entries that re-map imports to additional lookup locations. */
"@common/*": ["common/*"],
"@main/*": ["main/*"],
"@static/*": ["static/*"],
"@/*": ["./*"],
},
"typeRoots": [ /* Specify multiple folders that act like './node_modules/@types'. */
"./types",
],
},
// "include": [
// "**/*.ts",
// "**/*.js",
// "**/*.vue",
// "**/*.json",
// ],
// "exclude": ["dbService"]
}

View File

@ -9,7 +9,7 @@ const common = {
exposeWorker(Object.assign(common, list, lyric, music_url, music_other_source, download))
export declare type workerDBSeriveTypes = typeof common
export type workerDBSeriveTypes = typeof common
& typeof list
& typeof lyric
& typeof music_url

View File

@ -2,7 +2,7 @@ import { Worker } from 'worker_threads'
import * as Comlink from 'comlink'
import nodeEndpoint from 'comlink/dist/esm/node-adapter'
export declare type DBSeriveTypes = Comlink.Remote<LX.WorkerDBSeriveListTypes>
export type DBSeriveTypes = Comlink.Remote<LX.WorkerDBSeriveListTypes>
export const createDBServiceWorker = () => {
const worker: Worker = new Worker(new URL(

View File

@ -80,7 +80,7 @@ export const setting = shallowReactive<LX.DesktopLyric.Config>({
// },
// ])
// export declare type Status = 'playing' | 'paused' | 'stopped'
// export type Status = 'playing' | 'paused' | 'stopped'
// export const status = ref<Status>('stopped')
export const isPlay = ref(false)

View File

@ -1,9 +1,7 @@
{
"extends": "../../tsconfig.json",
"compilerOptions": {
"jsx": "preserve",
"module": "esnext",
"moduleResolution": "nodenext",
"isolatedModules": true,
"paths": { /* Specify a set of entries that re-map imports to additional lookup locations. */
"@common/*": ["common/*"],
// "@renderer/*": ["renderer/*"],
@ -15,11 +13,11 @@
"./types"
],
},
"vueCompilerOptions": {
"plugins": [
"@volar/vue-language-plugin-pug"
]
}
// "vueCompilerOptions": {
// "plugins": [
// "@volar/vue-language-plugin-pug"
// ]
// }
// "include": [
// "./**/*.ts",
// // "./**/*.js",

View File

@ -51,7 +51,7 @@ export default {
default: false,
},
},
emits: ['update:modelValue', 'change'],
emits: ['update:model-value', 'change'],
data() {
return {
checked: false,
@ -80,7 +80,7 @@ export default {
modelValue = checked
} else modelValue = checked ? this.value : ''
}
this.$emit('update:modelValue', modelValue)
this.$emit('update:model-value', modelValue)
this.$emit('change', modelValue)
},
setValue(value) {

View File

@ -52,7 +52,7 @@ export default {
// default: true,
// },
},
emits: ['update:modelValue', 'submit', 'change'],
emits: ['update:model-value', 'submit', 'change'],
methods: {
handleInput(event) {
let value = event.target.value
@ -60,7 +60,7 @@ export default {
value = value.trim()
event.target.value = value
}
this.$emit('update:modelValue', value)
this.$emit('update:model-value', value)
},
focus() {
this.$refs.dom_input.focus()
@ -78,7 +78,7 @@ export default {
// if (dom_input.selectionStart == dom_input.selectionEnd) {
const value = text.substring(0, dom_input.selectionStart) + str + text.substring(dom_input.selectionEnd, text.length)
event.target.value = value
this.$emit('update:modelValue', value)
this.$emit('update:model-value', value)
// } else {
// clipboardWriteText(text.substring(dom_input.selectionStart, dom_input.selectionEnd))
// }

View File

@ -48,13 +48,13 @@ export default {
default: 'name',
},
},
emits: ['update:modelValue', 'menu-click'],
emits: ['update:model-value', 'menu-click'],
setup(props, { emit }) {
const visible = computed(() => props.modelValue)
const location = computed(() => props.xy)
const onHide = () => {
emit('update:modelValue', false)
emit('update:model-value', false)
menuClick(null)
}

View File

@ -17,7 +17,7 @@
</template>
<script setup lang="ts">
import { ref, watch, onMounted, onBeforeUnmount, reactive, defineEmits } from '@common/utils/vueTools'
import { ref, watch, onMounted, onBeforeUnmount, reactive } from '@common/utils/vueTools'
// https://github.com/vuejs/core/issues/2855#issuecomment-768388962
import {

View File

@ -42,7 +42,7 @@ export default {
default: '',
},
},
emits: ['update:modelValue', 'change'],
emits: ['update:model-value', 'change'],
data() {
return {
show: false,
@ -84,7 +84,7 @@ export default {
handleClick(item) {
// console.log(this.modelValue)
if (item === this.modelValue) return
this.$emit('update:modelValue', this.itemKey ? item[this.itemKey] : item)
this.$emit('update:model-value', this.itemKey ? item[this.itemKey] : item)
this.$emit('change', item)
},
handleShow() {

View File

@ -37,11 +37,11 @@ export default {
default: '',
},
},
emits: ['update:modelValue', 'change'],
emits: ['update:model-value', 'change'],
setup(props, { emit }) {
const handleToggle = id => {
if (id == props.modelValue) return
emit('update:modelValue', id)
emit('update:model-value', id)
emit('change', id)
}

View File

@ -1,24 +1,24 @@
<template lang="pug">
material-modal(:show="isShowChangeLog" @close="isShowChangeLog = false" max-width="60%")
material-modal(:show="isShowChangeLog" max-width="60%" @close="isShowChangeLog = false")
main(:class="$style.main")
h2 当前版本更新日志
div.scroll.select(:class="$style.info")
div(:class="$style.current")
h3 当前版本{{versionInfo.version}}
h3 当前版本{{ versionInfo.version }}
template(v-if="info.desc")
h3 版本变化
pre(:class="$style.desc" v-text="info.desc")
div(:class="[$style.history, $style.desc]" v-if="info.history.length")
div(v-if="info.history.length" :class="[$style.history, $style.desc]")
h3 历史版本
div(:class="$style.item" v-for="ver in info.history")
h4 v{{ver.version}}
div(v-for="(ver, index) in info.history" :key="index" :class="$style.item")
h4 v{{ ver.version }}
pre(v-text="ver.desc")
div(:class="$style.footer")
div(:class="$style.desc")
p 📢&nbsp;为了减少疑问我们墙裂建议阅读版本更新日志来了解当前所用版本的变化
p 📢&nbsp;若遇到问题可以去设置-关于查看常见问题
p(v-if="!info.isLatest") 🚀&nbsp;发现新版本v{{versionInfo.newVersion.version}}建议 去设置-软件更新 更新新版本
p(v-if="!info.isLatest") 🚀&nbsp;发现新版本v{{ versionInfo.newVersion.version }}建议 去设置-软件更新 更新新版本
</template>
<script>

View File

@ -25,7 +25,7 @@ export default {
setup() {
const visible = ref(false)
const visibleProgress = ref(false)
const dom_btn = ref<HTMLElement | null>(null)
const dom_btn = ref(null)
const handleShowPopup = (evt) => {
if (visible.value) {

View File

@ -1,27 +1,27 @@
<template lang="pug">
div(:class="$style.footerLeftControlBtns")
button(:class="[$style.footerLeftControlBtn, $style.lrcBtn]" @click="toggleDesktopLyric" @contextmenu="toggleLockDesktopLyric" :aria-label="toggleDesktopLyricBtnTitle")
svg(v-show="appSetting['desktopLyric.enable']" version='1.1' xmlns='http://www.w3.org/2000/svg' xlink='http://www.w3.org/1999/xlink' height='125%' viewBox='0 0 512 512' space='preserve')
use(xlink:href='#icon-desktop-lyric-on')
svg(v-show="!appSetting['desktopLyric.enable']" version='1.1' xmlns='http://www.w3.org/2000/svg' xlink='http://www.w3.org/1999/xlink' height='125%' viewBox='0 0 512 512' space='preserve')
use(xlink:href='#icon-desktop-lyric-off')
button(:class="[$style.footerLeftControlBtn, { [$style.active]: appSetting['player.audioVisualization'] }]" @click="toggleAudioVisualization" :aria-label="$t('audio_visualization')")
svg(version='1.1' xmlns='http://www.w3.org/2000/svg' xlink='http://www.w3.org/1999/xlink' width='95%' viewBox='0 0 24 24' space='preserve')
use(xlink:href='#icon-audio-wave')
button(:class="[$style.footerLeftControlBtn, { [$style.active]: isShowLrcSelectContent }]" @click="toggleVisibleLrc" :aria-label="$t('lyric__select')")
svg(version='1.1' xmlns='http://www.w3.org/2000/svg' xlink='http://www.w3.org/1999/xlink' width='95%' viewBox='0 0 24 24' space='preserve')
use(xlink:href='#icon-text')
button(:class="[$style.footerLeftControlBtn, {[$style.active]: isShowPlayComment}]" @click="toggleVisibleComment" :aria-label="$t('comment__show')")
svg(version='1.1' xmlns='http://www.w3.org/2000/svg' xlink='http://www.w3.org/1999/xlink' width='95%' viewBox='0 0 24 24' space='preserve')
use(xlink:href='#icon-comment')
button(:class="[$style.footerLeftControlBtn, $style.lrcBtn]" :aria-label="toggleDesktopLyricBtnTitle" @click="toggleDesktopLyric" @contextmenu="toggleLockDesktopLyric")
svg(v-show="appSetting['desktopLyric.enable']" version="1.1" xmlns="http://www.w3.org/2000/svg" xlink="http://www.w3.org/1999/xlink" height="125%" viewBox="0 0 512 512" space="preserve")
use(xlink:href="#icon-desktop-lyric-on")
svg(v-show="!appSetting['desktopLyric.enable']" version="1.1" xmlns="http://www.w3.org/2000/svg" xlink="http://www.w3.org/1999/xlink" height="125%" viewBox="0 0 512 512" space="preserve")
use(xlink:href="#icon-desktop-lyric-off")
button(:class="[$style.footerLeftControlBtn, { [$style.active]: appSetting['player.audioVisualization'] }]" :aria-label="$t('audio_visualization')" @click="toggleAudioVisualization")
svg(version="1.1" xmlns="http://www.w3.org/2000/svg" xlink="http://www.w3.org/1999/xlink" width="95%" viewBox="0 0 24 24" space="preserve")
use(xlink:href="#icon-audio-wave")
button(:class="[$style.footerLeftControlBtn, { [$style.active]: isShowLrcSelectContent }]" :aria-label="$t('lyric__select')" @click="toggleVisibleLrc")
svg(version="1.1" xmlns="http://www.w3.org/2000/svg" xlink="http://www.w3.org/1999/xlink" width="95%" viewBox="0 0 24 24" space="preserve")
use(xlink:href="#icon-text")
button(:class="[$style.footerLeftControlBtn, {[$style.active]: isShowPlayComment}]" :aria-label="$t('comment__show')" @click="toggleVisibleComment")
svg(version="1.1" xmlns="http://www.w3.org/2000/svg" xlink="http://www.w3.org/1999/xlink" width="95%" viewBox="0 0 24 24" space="preserve")
use(xlink:href="#icon-comment")
common-sound-effect-btn
common-playback-rate-btn
common-volume-btn
common-toggle-play-mode-btn
button(:class="$style.footerLeftControlBtn" @click="isShowAddMusicTo = true" :aria-label="$t('player__add_music_to')")
svg(version='1.1' xmlns='http://www.w3.org/2000/svg' xlink='http://www.w3.org/1999/xlink' viewBox='0 0 512 512' space='preserve')
use(xlink:href='#icon-add-2')
common-list-add-modal(v-model:show="isShowAddMusicTo" :musicInfo="playMusicInfo.musicInfo")
button(:class="$style.footerLeftControlBtn" :aria-label="$t('player__add_music_to')" @click="isShowAddMusicTo = true")
svg(version="1.1" xmlns="http://www.w3.org/2000/svg" xlink="http://www.w3.org/1999/xlink" viewBox="0 0 512 512" space="preserve")
use(xlink:href="#icon-add-2")
common-list-add-modal(v-model:show="isShowAddMusicTo" :music-info="playMusicInfo.musicInfo")
</template>

View File

@ -83,7 +83,7 @@ export default {
required: true,
},
},
emits: ['updateLyric', 'update:modelValue'],
emits: ['updateLyric', 'update:model-value'],
setup(props, { emit }) {
// const appSetting = useRefGetter('appSetting')
// const playDetailSetting = useRefGetter('playDetailSetting')
@ -98,7 +98,7 @@ export default {
const location = computed(() => props.xy)
const onHide = () => {
emit('update:modelValue', false)
emit('update:model-value', false)
}
const setFontAlign = val => {

View File

@ -1,24 +1,24 @@
<template lang="pug">
div(:class="$style.container")
ul
li(v-for="(item, index) in comments" :key="item.id" :class="$style.listItem")
li(v-for="item in comments" :key="item.id" :class="$style.listItem")
div(:class="$style.content")
div(:class="$style.left")
img( :class="$style.avatar" :src="item.avatar || commentDefImg" @error="handleUserImg")
div(:class="$style.right")
div(:class="$style.info")
div(:class="$style.baseInfo")
div.select(:class="$style.name") {{item.userName}}
div.select(:class="$style.name") {{ item.userName }}
div(:class="$style.metaInfo")
time(:class="$style.label" v-if="item.timeStr") {{timeFormat(item.timeStr)}}
div(:class="$style.label" v-if="item.location") {{$t('comment__location', { location: item.location })}}
div(:class="$style.likes" v-if="item.likedCount != null")
svg(:class="$style.likesIcon" version='1.1' xmlns='http://www.w3.org/2000/svg' xlink='http://www.w3.org/1999/xlink' viewBox='0 0 512 512' space='preserve')
use(xlink:href='#icon-thumbs-up')
time(v-if="item.timeStr" :class="$style.label") {{ timeFormat(item.timeStr) }}
div(v-if="item.location" :class="$style.label") {{$t('comment__location', { location: item.location })}}
div(v-if="item.likedCount != null" :class="$style.likes")
svg(:class="$style.likesIcon" version="1.1" xmlns="http://www.w3.org/2000/svg" xlink="http://www.w3.org/1999/xlink" viewBox="0 0 512 512" space="preserve")
use(xlink:href="#icon-thumbs-up")
| {{item.likedCount}}
p.select(:class="$style.comment_text") {{item.text}}
p.select(:class="$style.comment_text") {{ item.text }}
div(v-if="item.images?.length" :class="$style.comment_images")
img(v-for="url in item.images" :src="url" loading="lazy" decoding="async")
img(v-for="(url, index) in item.images" :key="index" :src="url" loading="lazy" decoding="async")
comment-floor(v-if="item.reply && item.reply.length" :class="$style.reply_floor" :comments="item.reply")
</template>

View File

@ -1,37 +1,37 @@
<template lang="pug">
div.comment(:class="$style.comment" ref="dom_container")
div.comment(ref="dom_container" :class="$style.comment")
div(:class="$style.commentHeader")
h3 {{$t('comment__title', { name: title })}}
h3 {{ $t('comment__title', { name: title }) }}
div(:class="$style.commentHeaderBtns")
div(:class="$style.commentHeaderBtn" @click="handleShowComment" :aria-label="$t('comment__refresh')")
svg(version='1.1' xmlns='http://www.w3.org/2000/svg' xlink='http://www.w3.org/1999/xlink' style='transform: rotate(45deg);' viewBox='0 0 24 24' space='preserve')
use(xlink:href='#icon-refresh')
div(:class="$style.commentHeaderBtn" :aria-label="$t('comment__refresh')" @click="handleShowComment")
svg(version="1.1" xmlns="http://www.w3.org/2000/svg" xlink="http://www.w3.org/1999/xlink" style="transform: rotate(45deg);" viewBox="0 0 24 24" space="preserve")
use(xlink:href="#icon-refresh")
div(:class="$style.commentHeaderBtn" @click="$emit('close')")
svg(version='1.1' xmlns='http://www.w3.org/2000/svg' xlink='http://www.w3.org/1999/xlink' viewBox='0 0 24 24' space='preserve')
use(xlink:href='#icon-close')
svg(version="1.1" xmlns="http://www.w3.org/2000/svg" xlink="http://www.w3.org/1999/xlink" viewBox="0 0 24 24" space="preserve")
use(xlink:href="#icon-close")
div(:class="$style.commentMain")
template(v-if="available")
header(:class="$style.tab_header")
button(type="button" @click="handleToggleTab('hot')" :class="[$style.commentType, { [$style.active]: tabActiveId == 'hot' }]") {{$t('comment__hot_title')}} ({{hotComment.total}})
button(type="button" @click="handleToggleTab('new')" :class="[$style.commentType, { [$style.active]: tabActiveId == 'new' }]") {{$t('comment__new_title')}} ({{newComment.total}})
main(:class="$style.tab_main" ref="dom_tabMain")
button(type="button" :class="[$style.commentType, { [$style.active]: tabActiveId == 'hot' }]" @click="handleToggleTab('hot')") {{ $t('comment__hot_title') }} ({{ hotComment.total }})
button(type="button" :class="[$style.commentType, { [$style.active]: tabActiveId == 'new' }]" @click="handleToggleTab('new')") {{ $t('comment__new_title') }} ({{ newComment.total }})
main(ref="dom_tabMain" :class="$style.tab_main")
div(:class="$style.tab_content")
div.scroll(:class="$style.tab_content_scroll" ref="dom_commentHot")
p(:class="$style.commentLabel" style="cursor: pointer;" v-if="hotComment.isLoadError" @click="handleGetHotComment(currentMusicInfo, hotComment.nextPage, hotComment.limit)") {{$t('comment__hot_load_error')}}
p(:class="$style.commentLabel" v-else-if="hotComment.isLoading && !hotComment.list.length") {{$t('comment__hot_loading')}}
div.scroll(ref="dom_commentHot" :class="$style.tab_content_scroll")
p(v-if="hotComment.isLoadError" :class="$style.commentLabel" style="cursor: pointer;" @click="handleGetHotComment(currentMusicInfo, hotComment.nextPage, hotComment.limit)") {{ $t('comment__hot_load_error') }}
p(v-else-if="hotComment.isLoading && !hotComment.list.length" :class="$style.commentLabel") {{ $t('comment__hot_loading') }}
comment-floor(v-if="!hotComment.isLoadError && hotComment.list.length" :class="[$style.commentFloor, hotComment.isLoading ? $style.loading : null]" :comments="hotComment.list")
p(:class="$style.commentLabel" v-else-if="!hotComment.isLoadError && !hotComment.isLoading") {{$t('comment__no_content')}}
p(v-else-if="!hotComment.isLoadError && !hotComment.isLoading" :class="$style.commentLabel") {{ $t('comment__no_content') }}
div(:class="$style.pagination")
material-pagination(:count="hotComment.total" :btnLength="5" :limit="hotComment.limit" :page="hotComment.page" @btn-click="handleToggleHotCommentPage")
material-pagination(:count="hotComment.total" :btn-length="5" :limit="hotComment.limit" :page="hotComment.page" @btn-click="handleToggleHotCommentPage")
div(:class="$style.tab_content")
div.scroll(:class="$style.tab_content_scroll" ref="dom_commentNew")
p(:class="$style.commentLabel" style="cursor: pointer;" v-if="newComment.isLoadError" @click="handleGetNewComment(currentMusicInfo, newComment.nextPage, newComment.limit)") {{$t('comment__new_load_error')}}
p(:class="$style.commentLabel" v-else-if="newComment.isLoading && !newComment.list.length") {{$t('comment__new_loading')}}
div.scroll(ref="dom_commentNew" :class="$style.tab_content_scroll")
p(v-if="newComment.isLoadError" :class="$style.commentLabel" style="cursor: pointer;" @click="handleGetNewComment(currentMusicInfo, newComment.nextPage, newComment.limit)") {{ $t('comment__new_load_error') }}
p(v-else-if="newComment.isLoading && !newComment.list.length" :class="$style.commentLabel") {{ $t('comment__new_loading') }}
comment-floor(v-if="!newComment.isLoadError && newComment.list.length" :class="[$style.commentFloor, newComment.isLoading ? $style.loading : null]" :comments="newComment.list")
p(:class="$style.commentLabel" v-else-if="!newComment.isLoadError && !newComment.isLoading") {{$t('comment__no_content')}}
p(v-else-if="!newComment.isLoadError && !newComment.isLoading" :class="$style.commentLabel") {{ $t('comment__no_content') }}
div(:class="$style.pagination")
material-pagination(:count="newComment.total" :btnLength="5" :limit="newComment.limit" :page="newComment.page" @btn-click="handleToggleCommentPage")
material-pagination(:count="newComment.total" :btn-length="5" :limit="newComment.limit" :page="newComment.page" @btn-click="handleToggleCommentPage")
div(v-else :class="$style.unavailable")
p {{$t('comment__unavailable')}}
</template>

View File

@ -1,54 +1,54 @@
<template lang="pug">
transition(enter-active-class="animated slideInRight" leave-active-class="animated slideOutDown" @after-enter="handleAfterEnter" @after-leave="handleAfterLeave")
div(:class="[$style.container, { [$style.fullscreen]: isFullscreen }]" @contextmenu="handleContextMenu" v-if="isShowPlayerDetail")
div(v-if="isShowPlayerDetail" :class="[$style.container, { [$style.fullscreen]: isFullscreen }]" @contextmenu="handleContextMenu")
div(:class="$style.bg")
//- div(:class="$style.bg" :style="bgStyle")
//- div(:class="$style.bg2")
div(:class="[$style.header, $style.controlBtnLeft]" v-if="appSetting['common.controlBtnPosition'] == 'left'")
div(v-if="appSetting['common.controlBtnPosition'] == 'left'" :class="[$style.header, $style.controlBtnLeft]")
div(:class="$style.controBtn")
button(type="button" :class="$style.hide" :aria-label="$t('player__hide_detail_tip')" @click="hide")
svg(:class="$style.controBtnIcon" version='1.1' xmlns='http://www.w3.org/2000/svg' xlink='http://www.w3.org/1999/xlink' width='80%' viewBox='0 0 30.727 30.727' space='preserve')
use(xlink:href='#icon-window-hide')
svg(:class="$style.controBtnIcon" version="1.1" xmlns="http://www.w3.org/2000/svg" xlink="http://www.w3.org/1999/xlink" width="80%" viewBox="0 0 30.727 30.727" space="preserve")
use(xlink:href="#icon-window-hide")
button(type="button" :class="$style.fullscreenExit" :aria-label="$t('fullscreen_exit')" @click="fullscreenExit")
svg(:class="$style.controBtnIcon" version='1.1' xmlns='http://www.w3.org/2000/svg' xlink='http://www.w3.org/1999/xlink' width='100%')
use(xlink:href='#icon-fullscreen-exit')
svg(:class="$style.controBtnIcon" version="1.1" xmlns="http://www.w3.org/2000/svg" xlink="http://www.w3.org/1999/xlink" width="100%")
use(xlink:href="#icon-fullscreen-exit")
button(type="button" :class="$style.min" :aria-label="$t('min')" @click="min")
svg(:class="$style.controBtnIcon" version='1.1' xmlns='http://www.w3.org/2000/svg' xlink='http://www.w3.org/1999/xlink' width='100%' viewBox='0 0 24 24' space='preserve')
use(xlink:href='#icon-window-minimize')
svg(:class="$style.controBtnIcon" version="1.1" xmlns="http://www.w3.org/2000/svg" xlink="http://www.w3.org/1999/xlink" width="100%" viewBox="0 0 24 24" space="preserve")
use(xlink:href="#icon-window-minimize")
//- button(type="button" :class="$style.max" @click="max")
button(type="button" :class="$style.close" :aria-label="$t('close')" @click="close")
svg(:class="$style.controBtnIcon" version='1.1' xmlns='http://www.w3.org/2000/svg' xlink='http://www.w3.org/1999/xlink' width='100%' viewBox='0 0 24 24' space='preserve')
use(xlink:href='#icon-window-close')
div(:class="[$style.header, $style.controlBtnRight]" v-else)
svg(:class="$style.controBtnIcon" version="1.1" xmlns="http://www.w3.org/2000/svg" xlink="http://www.w3.org/1999/xlink" width="100%" viewBox="0 0 24 24" space="preserve")
use(xlink:href="#icon-window-close")
div(v-else :class="[$style.header, $style.controlBtnRight]")
div(:class="$style.controBtn")
button(type="button" :class="$style.hide" :aria-label="$t('player__hide_detail_tip')" @click="hide")
svg(:class="$style.controBtnIcon" version='1.1' xmlns='http://www.w3.org/2000/svg' xlink='http://www.w3.org/1999/xlink' height='35%' viewBox='0 0 30.727 30.727' space='preserve')
use(xlink:href='#icon-window-hide')
svg(:class="$style.controBtnIcon" version="1.1" xmlns="http://www.w3.org/2000/svg" xlink="http://www.w3.org/1999/xlink" height="35%" viewBox="0 0 30.727 30.727" space="preserve")
use(xlink:href="#icon-window-hide")
button(type="button" :class="$style.fullscreenExit" :aria-label="$t('fullscreen_exit')" @click="fullscreenExit")
svg(:class="$style.controBtnIcon" version='1.1' xmlns='http://www.w3.org/2000/svg' xlink='http://www.w3.org/1999/xlink' height='60%')
use(xlink:href='#icon-fullscreen-exit')
svg(:class="$style.controBtnIcon" version="1.1" xmlns="http://www.w3.org/2000/svg" xlink="http://www.w3.org/1999/xlink" height="60%")
use(xlink:href="#icon-fullscreen-exit")
button(type="button" :class="$style.min" :aria-label="$t('min')" @click="min")
svg(:class="$style.controBtnIcon" version='1.1' xmlns='http://www.w3.org/2000/svg' xlink='http://www.w3.org/1999/xlink' height='60%' viewBox='0 0 24 24' space='preserve')
use(xlink:href='#icon-window-minimize-2')
svg(:class="$style.controBtnIcon" version="1.1" xmlns="http://www.w3.org/2000/svg" xlink="http://www.w3.org/1999/xlink" height="60%" viewBox="0 0 24 24" space="preserve")
use(xlink:href="#icon-window-minimize-2")
//- button(type="button" :class="$style.max" @click="max")
button(type="button" :class="$style.close" :aria-label="$t('close')" @click="close")
svg(:class="$style.controBtnIcon" version='1.1' xmlns='http://www.w3.org/2000/svg' xlink='http://www.w3.org/1999/xlink' height='60%' viewBox='0 0 24 24' space='preserve')
use(xlink:href='#icon-window-close-2')
svg(:class="$style.controBtnIcon" version="1.1" xmlns="http://www.w3.org/2000/svg" xlink="http://www.w3.org/1999/xlink" height="60%" viewBox="0 0 24 24" space="preserve")
use(xlink:href="#icon-window-close-2")
div(:class="[$style.main, {[$style.showComment]: isShowPlayComment}]")
div.left(:class="$style.left")
//- div(:class="$style.info")
div(:class="$style.info")
img(:class="$style.img" :src="musicInfo.pic" v-if="musicInfo.pic")
img(v-if="musicInfo.pic" :class="$style.img" :src="musicInfo.pic")
div.description(:class="$style.description")
p {{$t('player__music_name')}}{{musicInfo.name}}
p {{$t('player__music_singer')}}{{musicInfo.singer}}
p(v-if="musicInfo.album") {{$t('player__music_album')}}{{musicInfo.album}}
p {{ $t('player__music_name') }}{{ musicInfo.name }}
p {{ $t('player__music_singer') }}{{ musicInfo.singer }}
p(v-if="musicInfo.album") {{ $t('player__music_album') }}{{musicInfo.album}}
transition(enter-active-class="animated fadeIn" leave-active-class="animated fadeOut")
LyricPlayer(v-if="visibled")
music-comment(:class="$style.comment" :show="isShowPlayComment" :musicInfo="playMusicInfo.musicInfo" @close="hideComment" v-if="visibled")
music-comment(v-if="visibled" :class="$style.comment" :show="isShowPlayComment" :music-info="playMusicInfo.musicInfo" @close="hideComment")
transition(enter-active-class="animated fadeIn" leave-active-class="animated fadeOut")
play-bar(v-if="visibled")
transition(enter-active-class="animated-slow fadeIn" leave-active-class="animated-slow fadeOut")

View File

@ -1,52 +1,52 @@
<template lang="pug">
material-modal(:show="versionInfo.showModal" @close="handleClose" max-width="60%")
main(:class="$style.main" v-if="versionInfo.isLatest")
material-modal(:show="versionInfo.showModal" max-width="60%" @close="handleClose")
main(v-if="versionInfo.isLatest" :class="$style.main")
h2 🎉 已是最新版本 🎉
div.scroll.select(:class="$style.info")
div(:class="$style.current")
h3 最新版本{{versionInfo.newVersion?.version}}
h3 当前版本{{versionInfo.version}}
h3 最新版本{{ versionInfo.newVersion?.version }}
h3 当前版本{{ versionInfo.version }}
h3 版本变化
pre(:class="$style.desc" v-text="versionInfo.newVersion?.desc")
div(:class="$style.footer")
div(:class="$style.btns")
base-btn(v-if="versionInfo.status == 'checking'" :class="$style.btn" disabled) 检查更新中...
base-btn(v-else :class="$style.btn" @click="handleCheckUpdate") 重新检查更新
main(:class="$style.main" v-else-if="versionInfo.isUnknown")
main(v-else-if="versionInfo.isUnknown" :class="$style.main")
h2 获取最新版本信息失败
div.scroll.select(:class="$style.info")
div(:class="$style.current")
h3 当前版本{{versionInfo.version}}
h3 当前版本{{ versionInfo.version }}
div(:class="$style.desc")
p 更新信息获取失败可能是无法访问Github导致的请手动检查更新
p
| 检查方法打开
base-btn(min @click="handleOpenUrl('https://github.com/lyswhut/lx-music-desktop/releases')" aria-label="点击打开") 软件发布页
base-btn(min aria-label="点击打开" @click="handleOpenUrl('https://github.com/lyswhut/lx-music-desktop/releases')") 软件发布页
|
base-btn(min @click="handleOpenUrl('https://www.lanzoui.com/b0bf2cfa/')" aria-label="点击打开") 网盘
base-btn(min aria-label="点击打开" @click="handleOpenUrl('https://www.lanzoui.com/b0bf2cfa/')") 网盘
| (密码
strong.hover(@click="handleCopy('glqw')" aria-label="点击复制") glqw
strong.hover(aria-label="点击复制" @click="handleCopy('glqw')") glqw
| )查看它们的
strong 版本号
| 与当前版本({{versionInfo.version}})对比是否一样
| 与当前版本({{ versionInfo.version }})对比是否一样
p 若一样则不必理会该弹窗直接关闭即可否则请手动下载新版本更新
div(:class="$style.footer")
div(:class="$style.btns")
base-btn(v-if="versionInfo.status == 'error'" :class="$style.btn" @click="handleCheckUpdate") 重新检查更新
base-btn(v-else :class="$style.btn" disabled) 检查更新中...
main(:class="$style.main" v-else-if="versionInfo.status == 'downloaded'")
main(v-else-if="versionInfo.status == 'downloaded'" :class="$style.main")
h2 🚀程序更新🚀
div.scroll.select(:class="$style.info")
div(:class="$style.current")
h3 最新版本{{versionInfo.newVersion?.version}}
h3 当前版本{{versionInfo.version}}
h3 最新版本{{ versionInfo.newVersion?.version }}
h3 当前版本{{ versionInfo.version }}
h3 版本变化
pre(:class="$style.desc" v-text="versionInfo.newVersion?.desc")
div(:class="[$style.history, $style.desc]" v-if="history.length")
div(v-if="history.length" :class="[$style.history, $style.desc]")
h3 历史版本
div(:class="$style.item" v-for="ver in history")
h4 v{{ver.version}}
div(v-for="(ver, index) in history" :key="index" :class="$style.item")
h4 v{{ ver.version }}
pre(v-text="ver.desc")
div(:class="$style.footer")
div(:class="$style.desc")
@ -58,37 +58,37 @@ material-modal(:show="versionInfo.showModal" @close="handleClose" max-width="60%
strong 关闭程序时
| 自动更新~
div(:class="$style.btns")
base-btn(:class="$style.btn" @click.onec="handleRestartClick") 立即重启更新
main(:class="$style.main" v-else)
base-btn(:class="$style.btn" @click="handleRestartClick") 立即重启更新
main(v-else :class="$style.main")
h2 🌟发现新版本🌟
div.scroll.select(:class="$style.info")
div(:class="$style.current")
h3 最新版本{{versionInfo.newVersion?.version}}
h3 当前版本{{versionInfo.version}}
h3 最新版本{{ versionInfo.newVersion?.version }}
h3 当前版本{{ versionInfo.version }}
h3 版本变化
pre(:class="$style.desc" v-text="versionInfo.newVersion?.desc")
div(:class="[$style.history, $style.desc]" v-if="history.length")
div(v-if="history.length" :class="[$style.history, $style.desc]")
h3 历史版本
div(:class="$style.item" v-for="ver in history")
h4 v{{ver.version}}
div(v-for="(ver, index) in history" :key="index" :class="$style.item")
h4 v{{ ver.version }}
pre(v-text="ver.desc")
div(:class="$style.footer")
div(:class="$style.desc")
p 发现有新版本啦你可以尝试使用自动更新或手动更新
p 手动更新可以去&nbsp;
strong.hover.underline(@click="handleOpenUrl('https://github.com/lyswhut/lx-music-desktop/releases')" aria-label="点击打开") 软件发布页
strong.hover.underline(aria-label="点击打开" @click="handleOpenUrl('https://github.com/lyswhut/lx-music-desktop/releases')") 软件发布页
| &nbsp;&nbsp;
strong.hover.underline(@click="handleOpenUrl('https://www.lanzoui.com/b0bf2cfa/')" aria-label="点击打开") 网盘
strong.hover.underline(aria-label="点击打开" @click="handleOpenUrl('https://www.lanzoui.com/b0bf2cfa/')") 网盘
| (密码
strong.hover(@click="handleCopy('glqw')" aria-label="点击复制") glqw
strong.hover(aria-label="点击复制" @click="handleCopy('glqw')") glqw
| )&nbsp;下载
p 国内Windows/MAC用户推荐到网盘下载若遇到问题可以看
strong.hover.underline(@click="handleOpenUrl('https://lyswhut.github.io/lx-music-doc/desktop/faq')" aria-label="点击打开") 常见问题
p(v-if="progress") 当前下载进度{{progress}}
strong.hover.underline(aria-label="点击打开" @click="handleOpenUrl('https://lyswhut.github.io/lx-music-doc/desktop/faq')") 常见问题
p(v-if="progress") 当前下载进度{{ progress }}
p(v-else) &nbsp;
div(:class="$style.btns")
base-btn(:class="$style.btn2" @click="handleIgnoreClick") {{ isIgnored ? '取消忽略' : '忽略更新该版本'}}
base-btn(:class="$style.btn2" @click="handleIgnoreClick") {{ isIgnored ? '取消忽略' : '忽略更新该版本' }}
base-btn(v-if="versionInfo.status == 'downloading'" :class="$style.btn2" disabled) 下载更新中...
base-btn(v-else :class="$style.btn2" @click="handleDonwloadClick") 下载更新
</template>

View File

@ -8,7 +8,7 @@
</template>
<script setup lang="ts">
import { ref, defineExpose } from '@common/utils/vueTools'
import { ref } from '@common/utils/vueTools'
const visible = ref(false)
const dom_btn = ref<HTMLElement | null>(null)

View File

@ -8,7 +8,7 @@
:placeholder="placeholder"
@focus="handleFocus"
@blur="handleBlur"
@input="$emit('update:modelValue', text)"
@input="$emit('update:model-value', text)"
@change="sendEvent('change')"
@keyup.enter="handleSearch"
@keydown.arrow-down.arrow-up.prevent
@ -82,7 +82,7 @@ export default {
default: false,
},
},
emits: ['update:modelValue', 'event'],
emits: ['update:model-value', 'event'],
data() {
return {
isShow: false,
@ -174,11 +174,11 @@ export default {
str = str.replace(/\s+/g, ' ')
let dom_input = this.$refs.dom_input
this.text = this.text.substring(0, dom_input.selectionStart) + str + this.text.substring(dom_input.selectionEnd, this.text.length)
this.$emit('update:modelValue', this.text)
this.$emit('update:model-value', this.text)
},
handleClearList() {
this.text = ''
this.$emit('update:modelValue', this.text)
this.$emit('update:model-value', this.text)
this.sendEvent('submit')
},
},

View File

@ -51,7 +51,7 @@ const loadBuffer = async(name: string) => new Promise<AudioBuffer>((resolve, rej
})
export default () => {
console.log(appSetting['player.soundEffect.panner.enable'])
// console.log(appSetting['player.soundEffect.panner.enable'])
if (appSetting['player.soundEffect.panner.enable']) startPanner()
setPannerSoundR(appSetting['player.soundEffect.panner.soundR'] / 10)
setPannerSpeed(2 * (appSetting['player.soundEffect.panner.speed'] / 10))

View File

@ -1,7 +1,7 @@
import { reactive, markRaw, shallowReactive } from '@common/utils/vueTools'
import music from '@renderer/utils/musicSdk'
export declare type Source = LX.OnlineSource
export type Source = LX.OnlineSource
export const sources: LX.OnlineSource[] = markRaw([])
@ -10,12 +10,12 @@ for (const source of music.sources) {
sources.push(source.id as LX.OnlineSource)
}
export declare interface BoardItem {
export interface BoardItem {
id: string
name: string
bangid: string
}
export declare interface Board {
export interface Board {
list: BoardItem[]
source: LX.OnlineSource
}
@ -23,7 +23,7 @@ type Boards = Partial<Record<LX.OnlineSource, Board>>
export const boards = shallowReactive<Boards>({})
export declare interface ListDetailInfo {
export interface ListDetailInfo {
list: LX.Music.MusicInfoOnline[]
total: number
page: number

View File

@ -3,7 +3,7 @@ import { ref, shallowReactive } from '@common/utils/vueTools'
export const searchText = ref('')
export declare type onlineSource = LX.OnlineSource
export type onlineSource = LX.OnlineSource
export const historyList = shallowReactive<string[]>([])

View File

@ -1,7 +1,7 @@
import { reactive, markRaw, ref, shallowReactive } from '@common/utils/vueTools'
import music from '@renderer/utils/musicSdk'
export declare interface SortInfo {
export interface SortInfo {
name: string
id: string
}
@ -16,18 +16,18 @@ for (const source of music.sources) {
sortList[source.id as LX.OnlineSource] = songList.sortList as SortInfo[]
}
export declare interface TagInfoItem<T extends LX.OnlineSource = LX.OnlineSource> {
export interface TagInfoItem<T extends LX.OnlineSource = LX.OnlineSource> {
parent_id: string
parent_name: string
id: string
name: string
source: T
}
export declare interface TagInfoTypeItem<T extends LX.OnlineSource = LX.OnlineSource> {
export interface TagInfoTypeItem<T extends LX.OnlineSource = LX.OnlineSource> {
name: string
list: Array<TagInfoItem<T>>
}
export declare interface TagInfo<Source extends LX.OnlineSource = LX.OnlineSource> {
export interface TagInfo<Source extends LX.OnlineSource = LX.OnlineSource> {
tags: Array<TagInfoTypeItem<Source>>
hotTag: Array<TagInfoItem<Source>>
source: Source
@ -38,7 +38,7 @@ type Tags = Partial<Record<LX.OnlineSource, TagInfo>>
export const tags = shallowReactive<Tags>({})
export declare interface ListInfoItem {
export interface ListInfoItem {
play_count: string
id: string
author: string
@ -50,7 +50,7 @@ export declare interface ListInfoItem {
source: LX.OnlineSource
total?: string
}
export declare interface ListInfo {
export interface ListInfo {
list: ListInfoItem[]
total: number
page: number
@ -62,7 +62,7 @@ export declare interface ListInfo {
sortId: string
}
export declare interface ListDetailInfo {
export interface ListDetailInfo {
list: LX.Music.MusicInfoOnline[]
source: LX.OnlineSource
desc: string | null

View File

@ -1,9 +1,7 @@
{
"extends": "../../tsconfig.json",
"compilerOptions": {
"jsx": "preserve",
"module": "esnext",
"moduleResolution": "nodenext",
"isolatedModules": true,
"paths": { /* Specify a set of entries that re-map imports to additional lookup locations. */
"@common/*": ["common/*"],
"@renderer/*": ["renderer/*"],
@ -12,14 +10,14 @@
"@/*": ["./*"],
},
"typeRoots": [ /* Specify multiple folders that act like './node_modules/@types'. */
"./types"
"renderer/types"
],
},
"vueCompilerOptions": {
"plugins": [
"@volar/vue-language-plugin-pug"
]
}
// "vueCompilerOptions": {
// "plugins": [
// "@volar/vue-language-plugin-pug"
// ]
// }
// "include": [
// "./**/*.ts",
// // "./**/*.js",

View File

@ -2,11 +2,11 @@ import { isMac } from '@common/utils'
const downKeys = new Set<string>()
export declare type KeyActionType = LX.KeyDownEevent['type']
export declare type Keys = LX.KeyDownEevent['keys']
export declare type Key = LX.KeyDownEevent['key']
export declare type EventKey = LX.KeyDownEevent['eventKey']
export declare type Event = LX.KeyDownEevent['event']
export type KeyActionType = LX.KeyDownEevent['type']
export type Keys = LX.KeyDownEevent['keys']
export type Key = LX.KeyDownEevent['key']
export type EventKey = LX.KeyDownEevent['eventKey']
export type Event = LX.KeyDownEevent['event']
const handleEvent = (type: KeyActionType, event: LX.KeyEvent, keys: Keys, isEditing: boolean) => {
let eventKey = event.key

View File

@ -23,7 +23,7 @@
</template>
<script setup lang="ts">
import { watch, shallowReactive, ref, defineExpose } from '@common/utils/vueTools'
import { watch, shallowReactive, ref } from '@common/utils/vueTools'
import { getBoardsList, setBoard } from '@renderer/store/leaderboard/action'
import { boards, Board } from '@renderer/store/leaderboard/state'
import useMenu from './useMenu'

View File

@ -15,7 +15,7 @@
</template>
<script setup lang="ts">
import { watch, defineProps, defineExpose } from '@common/utils/vueTools'
import { watch } from '@common/utils/vueTools'
import LX from '@renderer/types/lx'
import useList from './useList'

View File

@ -16,7 +16,7 @@
</template>
<script setup lang="ts">
import { watch, defineProps } from '@common/utils/vueTools'
import { watch } from '@common/utils/vueTools'
import { searchText } from '@renderer/store/search/state'
import { useRouter, useRoute } from '@common/utils/vueRouter'
import useList, { SearchSource } from './useList'

View File

@ -8,7 +8,7 @@ import { addHistoryWord } from '@renderer/store/search/action'
import { search as searchMusic, listInfos, type ListInfo } from '@renderer/store/search/music'
import { assertApiSupport } from '@renderer/store/utils'
export declare type SearchSource = LX.OnlineSource | 'all'
export type SearchSource = LX.OnlineSource | 'all'
export default () => {
const listRef = ref<any>(null)

View File

@ -5,7 +5,7 @@
</template>
<script setup lang="ts">
import { watch, defineProps } from '@common/utils/vueTools'
import { watch } from '@common/utils/vueTools'
import { searchText } from '@renderer/store/search/state'
import { useRouter, useRoute } from '@common/utils/vueRouter'
import useList, { SearchSource } from './useList'

View File

@ -6,7 +6,7 @@ import { addHistoryWord } from '@renderer/store/search/action'
import type { SearchListInfo, ListInfoItem } from '@renderer/store/search/songlist'
import { search as searchSongList, listInfos } from '@renderer/store/search/songlist'
export declare type SearchSource = LX.OnlineSource | 'all'
export type SearchSource = LX.OnlineSource | 'all'
export default () => {
const listRef = ref<any>(null)

View File

@ -1,17 +1,17 @@
<template lang="pug">
material-modal(:show="modelValue" @close="handleCloseModal" @after-enter="$refs.dom_input.focus()" teleport="#view")
material-modal(:show="modelValue" teleport="#view" @close="handleCloseModal" @after-enter="$refs.dom_input.focus()")
main(:class="$style.main")
h2 {{$t('play_timeout')}}
h2 {{ $t('play_timeout') }}
div(:class="$style.content")
div(:class="[$style.row, $style.inputGroup]")
base-input(:class="$style.input" ref="dom_input" v-model="time" type="number")
p(:class="$style.inputLabel") {{$t('play_timeout_unit')}}
base-input(ref="dom_input" v-model="time" :class="$style.input" type="number")
p(:class="$style.inputLabel") {{ $t('play_timeout_unit') }}
div(:class="$style.row")
base-checkbox(id="play_timeout_end" :modelValue="appSetting['player.waitPlayEndStop']" @update:modelValue="updateSetting({'player.waitPlayEndStop': $event})" :label="$t('play_timeout_end')")
base-checkbox(id="play_timeout_end" :model-value="appSetting['player.waitPlayEndStop']" :label="$t('play_timeout_end')" @update:model-value="updateSetting({'player.waitPlayEndStop': $event})")
div(:class="[$style.row, $style.tip, { [$style.show]: !!timeLabel }]")
p {{$t('play_timeout_tip', { time: timeLabel })}}
div(:class="$style.footer")
base-btn(:class="$style.footerBtn" @click="handleCancel") {{$t(timeLabel ? 'play_timeout_stop' : 'play_timeout_close')}}
base-btn(:class="$style.footerBtn" @click="handleCancel") {{ $t(timeLabel ? 'play_timeout_stop' : 'play_timeout_close') }}
base-btn(:class="$style.footerBtn" @click="handleConfirm") {{$t(timeLabel ? 'play_timeout_update' : 'play_timeout_confirm')}}
</template>
@ -31,13 +31,13 @@ export default {
default: false,
},
},
emits: ['update:modelValue'],
emits: ['update:model-value'],
setup(props, { emit }) {
const { timeLabel } = useTimeout()
const time = ref(appSetting['player.waitPlayEndStopTime'])
const handleCloseModal = () => {
emit('update:modelValue', false)
emit('update:model-value', false)
}
const handleCancel = () => {
if (timeLabel.value) {

View File

@ -1,23 +1,23 @@
<template lang="pug">
dt#about {{$t('setting__about')}}
dt#about {{ $t('setting__about') }}
dd
p.small
.p.small
| 本软件完全免费代码已开源开源地址
span.hover.underline(:aria-label="$t('setting__click_open')" @click="openUrl('https://github.com/lyswhut/lx-music-desktop#readme')") https://github.com/lyswhut/lx-music-desktop
p.small
.p.small
| 最新版网盘下载地址网盘内有WindowsMAC版
span.hover.underline(:aria-label="$t('setting__click_open')" @click="openUrl('https://www.lanzoui.com/b0bf2cfa/')") 网盘地址
| &nbsp;&nbsp;密码
span.hover(:aria-label="$t('setting__click_copy')" @click="clipboardWriteText('glqw')") glqw
p.small
.p.small
| 软件的常见问题可转至
span.hover.underline(:aria-label="$t('setting__click_open')" @click="openUrl('https://lyswhut.github.io/lx-music-doc/desktop/faq')") 常见问题
p.small
.p.small
strong 本软件没有客服
| 但我们整理了一些常见的使用问题
strong 仔细 仔细 仔细
| 地阅读常见问题后
p.small
.p.small
| 仍有问题可加企鹅群&nbsp;
span.hover(:aria-label="$t('setting__click_open')" @click="openUrl('https://jq.qq.com/?_wv=1027&k=51ECeq2')") 830125506
| &nbsp;反馈
@ -26,20 +26,20 @@ dd
span.hover.underline(:aria-label="$t('setting__click_open')" @click="openUrl('https://github.com/lyswhut/lx-music-desktop/issues')") issue
br
p.small
.p.small
| 如果你喜欢并经常使用洛雪音乐并想要第一时间尝鲜洛雪的新功能&nbsp;
span(style="text-decoration: line-through;") 当小白鼠
|
p
.p
| 可以加入测试企鹅群&nbsp;
span.hover(:aria-label="$t('setting__click_open')" @click="openUrl('https://qm.qq.com/cgi-bin/qm/qr?k=zR6aYosQoKb07g4FGFZdO9n9zL1dhFpE&jump_from=webapi')") 768786588
| &nbsp;注意测试版的功能可能会不稳定
strong 打算潜水的勿加
br
p.small 由于软件开发的初衷仅是为了对新技术的学习与研究因此软件直至停止维护都将会一直保持纯净
.p.small 由于软件开发的初衷仅是为了对新技术的学习与研究因此软件直至停止维护都将会一直保持纯净
p.small
.p.small
| 你已签署本软件的&nbsp;
base-btn(min @click="handleShowPact") 许可协议
| 协议的在线版本在&nbsp;
@ -47,7 +47,7 @@ dd
| &nbsp;
br
p
.p
small By
| 落雪无痕
</template>

View File

@ -1,21 +1,21 @@
<template lang="pug">
dt#backup {{$t('setting__backup')}}
dt#backup {{ $t('setting__backup') }}
dd
h3#backup_part {{$t('setting__backup_part')}}
h3#backup_part {{ $t('setting__backup_part') }}
div
base-btn.btn.gap-left(min @click="handleImportPlayList") {{$t('setting__backup_part_import_list')}}
base-btn.btn.gap-left(min @click="handleExportPlayList") {{$t('setting__backup_part_export_list')}}
base-btn.btn.gap-left(min @click="handleImportSetting") {{$t('setting__backup_part_import_setting')}}
base-btn.btn.gap-left(min @click="handleImportPlayList") {{ $t('setting__backup_part_import_list') }}
base-btn.btn.gap-left(min @click="handleExportPlayList") {{ $t('setting__backup_part_export_list') }}
base-btn.btn.gap-left(min @click="handleImportSetting") {{ $t('setting__backup_part_import_setting') }}
base-btn.btn.gap-left(min @click="handleExportSetting") {{$t('setting__backup_part_export_setting')}}
dd
h3#backup_all {{$t('setting__backup_all')}}
h3#backup_all {{ $t('setting__backup_all') }}
div
base-btn.btn.gap-left(min @click="handleImportAllData") {{$t('setting__backup_all_import')}}
base-btn.btn.gap-left(min @click="handleImportAllData") {{ $t('setting__backup_all_import') }}
base-btn.btn.gap-left(min @click="handleExportAllData") {{$t('setting__backup_all_export')}}
dd
h3#backup_other {{$t('setting__backup_other')}}
h3#backup_other {{ $t('setting__backup_other') }}
div
base-btn.btn.gap-left(min @click="handleExportPlayListToText") {{$t('setting__backup_other_export_list_text')}}
base-btn.btn.gap-left(min @click="handleExportPlayListToText") {{ $t('setting__backup_other_export_list_text') }}
base-btn.btn.gap-left(min @click="handleExportPlayListToCsv") {{$t('setting__backup_other_export_list_csv')}}
</template>

View File

@ -1,22 +1,22 @@
<template lang="pug">
dt#basic {{$t('setting__basic')}}
dt#basic {{ $t('setting__basic') }}
dd
h3#basic_theme {{$t('setting__basic_theme')}}
h3#basic_theme {{ $t('setting__basic_theme') }}
div
ul(:class="$style.theme")
li(v-for="theme in defaultThemes" :key="theme.id" :aria-label="$t('theme_' + theme.id)" @click="toggleTheme(theme)" :style="theme.styles" :class="[$style.themeItem, {[$style.active]: themeId == theme.id}]")
li(v-for="theme in defaultThemes" :key="theme.id" :aria-label="$t('theme_' + theme.id)" :style="theme.styles" :class="[$style.themeItem, {[$style.active]: themeId == theme.id}]" @click="toggleTheme(theme)")
div(:class="$style.bg")
span(:class="$style.label") {{$t('theme_' + theme.id)}}
li(v-for="theme in userThemes" :key="theme.id" :aria-label="theme.name" @click="toggleTheme(theme)" @contextmenu="handleEditTheme(theme)" :style="theme.styles" :class="[$style.themeItem, {[$style.active]: themeId == theme.id}]")
span(:class="$style.label") {{ $t('theme_' + theme.id) }}
li(v-for="theme in userThemes" :key="theme.id" :aria-label="theme.name" :style="theme.styles" :class="[$style.themeItem, {[$style.active]: themeId == theme.id}]" @click="toggleTheme(theme)" @contextmenu="handleEditTheme(theme)")
div(:class="$style.bg")
span(:class="$style.label") {{theme.name}}
li(:aria-label="$t('theme_auto_tip')" @click="handleSetThemeAuto" @contextmenu="isShowThemeSelectorModal = true" :style="autoTheme" :class="[$style.themeItem, $style.auto, {[$style.active]: themeId == 'auto'}]")
span(:class="$style.label") {{ theme.name }}
li(:aria-label="$t('theme_auto_tip')" :style="autoTheme" :class="[$style.themeItem, $style.auto, {[$style.active]: themeId == 'auto'}]" @click="handleSetThemeAuto" @contextmenu="isShowThemeSelectorModal = true")
div(:class="$style.bg")
div(:class="$style.bgContent")
div(:class="$style.light")
div(:class="$style.dark")
span(:class="$style.label") {{$t('theme_auto')}}
li(:aria-label="$t('theme_add')" @click="handleEditTheme()" :class="[$style.themeItem, $style.add]")
span(:class="$style.label") {{ $t('theme_auto') }}
li(:aria-label="$t('theme_add')" :class="[$style.themeItem, $style.add]" @click="handleEditTheme()")
div(:class="$style.bg")
div(:class="$style.bgContent")
svg-icon(:class="$style.icon" name="plus")
@ -25,69 +25,78 @@ dd
dd
div
.gap-top.top
base-checkbox(id="setting_show_animate" :modelValue="appSetting['common.isShowAnimation']" @update:modelValue="updateSetting({'common.isShowAnimation': $event})" :label="$t('setting__basic_show_animation')")
base-checkbox(id="setting_show_animate" :model-value="appSetting['common.isShowAnimation']" :label="$t('setting__basic_show_animation')" @update:model-value="updateSetting({'common.isShowAnimation': $event})")
.gap-top
base-checkbox(id="setting_animate" :modelValue="appSetting['common.randomAnimate']" @update:modelValue="updateSetting({'common.randomAnimate': $event})" :label="$t('setting__basic_animation')")
base-checkbox(id="setting_animate" :model-value="appSetting['common.randomAnimate']" :label="$t('setting__basic_animation')" @update:model-value="updateSetting({'common.randomAnimate': $event})")
.gap-top
base-checkbox(id="setting_start_in_fullscreen" :modelValue="appSetting['common.startInFullscreen']" @update:modelValue="updateSetting({'common.startInFullscreen': $event})" :label="$t('setting__basic_start_in_fullscreen')")
base-checkbox(id="setting_start_in_fullscreen" :model-value="appSetting['common.startInFullscreen']" :label="$t('setting__basic_start_in_fullscreen')" @update:model-value="updateSetting({'common.startInFullscreen': $event})")
.gap-top
base-checkbox(id="setting_to_tray" :modelValue="appSetting['tray.enable']" @update:modelValue="updateSetting({'tray.enable': $event})" :label="$t('setting__basic_to_tray')")
p.gap-top
base-checkbox(id="setting_to_tray" :model-value="appSetting['tray.enable']" :label="$t('setting__basic_to_tray')" @update:model-value="updateSetting({'tray.enable': $event})")
.p.gap-top
base-btn.btn(min @click="isShowPlayTimeoutModal = true") {{$t('setting__play_timeout')}} {{ timeLabel ? ` (${timeLabel})` : '' }}
dd
h3#basic_source {{$t('setting__basic_source')}}
h3#basic_source {{ $t('setting__basic_source') }}
div
.gap-top(v-for="item in apiSources" :key="item.id")
base-checkbox(:id="`setting_api_source_${item.id}`" name="setting_api_source"
need :modelValue="appSetting['common.apiSource']" @update:modelValue="updateSetting({'common.apiSource': $event})" :disabled="item.disabled" :value="item.id" :label="item.label")
p.gap-top
base-checkbox(
:id="`setting_api_source_${item.id}`" name="setting_api_source"
need :model-value="appSetting['common.apiSource']" :disabled="item.disabled" :value="item.id" :label="item.label" @update:model-value="updateSetting({'common.apiSource': $event})")
.p.gap-top
base-btn.btn(min @click="isShowUserApiModal = true") {{$t('setting__basic_source_user_api_btn')}}
dd
h3#basic_window_size {{$t('setting__basic_window_size')}}
h3#basic_window_size {{ $t('setting__basic_window_size') }}
div
base-checkbox.gap-left(v-for="(item, index) in windowSizeList" :id="`setting_window_size_${item.id}`" name="setting_window_size"
need :modelValue="appSetting['common.windowSizeId']" @update:modelValue="updateSetting({'common.windowSizeId': $event})" :disabled="isFullscreen" :value="item.id" :label="$t('setting__basic_window_size_' + item.name)" :key="item.id")
base-checkbox.gap-left(
v-for="item in windowSizeList" :id="`setting_window_size_${item.id}`" :key="item.id"
name="setting_window_size" need :model-value="appSetting['common.windowSizeId']" :disabled="isFullscreen" :value="item.id" :label="$t('setting__basic_window_size_' + item.name)" @update:model-value="updateSetting({'common.windowSizeId': $event})")
dd
h3#basic_font_size {{$t('setting__basic_font_size')}}
h3#basic_font_size {{ $t('setting__basic_font_size') }}
div
//- base-selection.gap-teft(:list="fontSizeList" :modelValue="appSetting['common.fontSize']" @update:modelValue="updateSetting({'common.fontSize': $event})")
base-checkbox.gap-left(v-for="item in fontSizeList" :key="item.id" :id="`setting_basic_font_size_${item.id}`"
name="setting_basic_font_size" need :modelValue="appSetting['common.fontSize']" @update:modelValue="updateSetting({'common.fontSize': $event})"
:value="item.id" :label="item.label" :disabled="isFullscreen")
//- base-selection.gap-teft(:list="fontSizeList" :modelValue="appSetting['common.fontSize']" @update:model-value="updateSetting({'common.fontSize': $event})")
base-checkbox.gap-left(
v-for="item in fontSizeList" :id="`setting_basic_font_size_${item.id}`" :key="item.id"
name="setting_basic_font_size" need :model-value="appSetting['common.fontSize']" :value="item.id"
:label="item.label" :disabled="isFullscreen" @update:model-value="updateSetting({'common.fontSize': $event})")
dd
h3#basic_font {{$t('setting__basic_font')}}
h3#basic_font {{ $t('setting__basic_font') }}
div
base-selection.gap-teft(:list="fontList" :modelValue="appSetting['common.font']" @update:modelValue="updateSetting({'common.font': $event})" item-key="id" item-name="label")
base-selection.gap-teft(:list="fontList" :model-value="appSetting['common.font']" item-key="id" item-name="label" @update:model-value="updateSetting({'common.font': $event})")
dd
h3#basic_lang {{$t('setting__basic_lang')}}
h3#basic_lang {{ $t('setting__basic_lang') }}
div
base-checkbox.gap-left(v-for="item in langList" :key="item.locale" :id="`setting_lang_${item.locale}`" name="setting_lang"
need :modelValue="appSetting['common.langId']" @update:modelValue="updateSetting({'common.langId': $event})" :value="item.locale" :label="item.name")
base-checkbox.gap-left(
v-for="item in langList" :id="`setting_lang_${item.locale}`" :key="item.locale" name="setting_lang"
need :model-value="appSetting['common.langId']" :value="item.locale" :label="item.name" @update:model-value="updateSetting({'common.langId': $event})")
dd
h3#basic_sourcename {{$t('setting__basic_sourcename')}}
h3#basic_sourcename {{ $t('setting__basic_sourcename') }}
div
base-checkbox.gap-left(v-for="item in sourceNameTypes" :key="item.id" :id="`setting_abasic_sourcename_${item.id}`"
name="setting_basic_sourcename" need :modelValue="appSetting['common.sourceNameType']" @update:modelValue="updateSetting({'common.sourceNameType': $event})" :value="item.id" :label="item.label")
base-checkbox.gap-left(
v-for="item in sourceNameTypes" :id="`setting_abasic_sourcename_${item.id}`" :key="item.id"
name="setting_basic_sourcename" need :model-value="appSetting['common.sourceNameType']" :value="item.id" :label="item.label" @update:model-value="updateSetting({'common.sourceNameType': $event})")
dd
h3#basic_control_btn_position {{$t('setting__basic_control_btn_position')}}
h3#basic_control_btn_position {{ $t('setting__basic_control_btn_position') }}
div
base-checkbox.gap-left(v-for="item in controlBtnPositionList" :key="item.id" :id="`setting_basic_control_btn_position_${item.id}`"
name="setting_basic_control_btn_position" need :modelValue="appSetting['common.controlBtnPosition']" @update:modelValue="updateSetting({'common.controlBtnPosition': $event})" :value="item.id" :label="item.name")
base-checkbox.gap-left(
v-for="item in controlBtnPositionList" :id="`setting_basic_control_btn_position_${item.id}`" :key="item.id"
name="setting_basic_control_btn_position" need :model-value="appSetting['common.controlBtnPosition']" :value="item.id" :label="item.name" @update:model-value="updateSetting({'common.controlBtnPosition': $event})")
dd
h3#basic_playbar_progress_style {{$t('setting__basic_playbar_progress_style')}}
h3#basic_playbar_progress_style {{ $t('setting__basic_playbar_progress_style') }}
div
base-checkbox.gap-left(id="setting_basic_playbar_progress_style_mini" name="setting_basic_playbar_progress_style"
need :modelValue="appSetting['common.playBarProgressStyle']" @update:modelValue="updateSetting({'common.playBarProgressStyle': $event})" value="mini" :label="$t('setting__basic_playbar_progress_style_mini')")
base-checkbox.gap-left(id="setting_basic_playbar_progress_style_middle" name="setting_basic_playbar_progress_style"
need :modelValue="appSetting['common.playBarProgressStyle']" @update:modelValue="updateSetting({'common.playBarProgressStyle': $event})" value="middle" :label="$t('setting__basic_playbar_progress_style_middle')")
base-checkbox.gap-left(id="setting_basic_playbar_progress_style_full" name="setting_basic_playbar_progress_style"
need :modelValue="appSetting['common.playBarProgressStyle']" @update:modelValue="updateSetting({'common.playBarProgressStyle': $event})" value="full" :label="$t('setting__basic_playbar_progress_style_full')")
base-checkbox.gap-left(
id="setting_basic_playbar_progress_style_mini" name="setting_basic_playbar_progress_style"
need :model-value="appSetting['common.playBarProgressStyle']" value="mini" :label="$t('setting__basic_playbar_progress_style_mini')" @update:model-value="updateSetting({'common.playBarProgressStyle': $event})")
base-checkbox.gap-left(
id="setting_basic_playbar_progress_style_middle" name="setting_basic_playbar_progress_style"
need :model-value="appSetting['common.playBarProgressStyle']" value="middle" :label="$t('setting__basic_playbar_progress_style_middle')" @update:model-value="updateSetting({'common.playBarProgressStyle': $event})")
base-checkbox.gap-left(
id="setting_basic_playbar_progress_style_full" name="setting_basic_playbar_progress_style"
need :model-value="appSetting['common.playBarProgressStyle']" value="full" :label="$t('setting__basic_playbar_progress_style_full')" @update:model-value="updateSetting({'common.playBarProgressStyle': $event})")
ThemeSelectorModal(v-model="isShowThemeSelectorModal")
ThemeEditModal(v-model="isShowThemeEditModal" :theme-id="editThemeId" @submit="handleRefreshTheme")

View File

@ -1,91 +1,91 @@
<template lang="pug">
dt#desktop_lyric {{$t('setting__desktop_lyric')}}
dt#desktop_lyric {{ $t('setting__desktop_lyric') }}
dd
.gap-top
base-checkbox(id="setting_desktop_lyric_enable" :modelValue="appSetting['desktopLyric.enable']" @update:modelValue="updateSetting({ 'desktopLyric.enable': $event })" :label="$t('setting__desktop_lyric_enable')")
base-checkbox(id="setting_desktop_lyric_enable" :model-value="appSetting['desktopLyric.enable']" :label="$t('setting__desktop_lyric_enable')" @update:model-value="updateSetting({ 'desktopLyric.enable': $event })")
.gap-top
base-checkbox(id="setting_desktop_lyric_lock" :modelValue="appSetting['desktopLyric.isLock']" @update:modelValue="updateSetting({ 'desktopLyric.isLock': $event })" :label="$t('setting__desktop_lyric_lock')")
base-checkbox(id="setting_desktop_lyric_lock" :model-value="appSetting['desktopLyric.isLock']" :label="$t('setting__desktop_lyric_lock')" @update:model-value="updateSetting({ 'desktopLyric.isLock': $event })")
.gap-top
base-checkbox(id="setting_desktop_lyric_fullscreen_hide" :modelValue="appSetting['desktopLyric.fullscreenHide']" @update:modelValue="updateSetting({ 'desktopLyric.fullscreenHide': $event })" :label="$t('setting__desktop_lyric_fullscreen_hide')")
base-checkbox(id="setting_desktop_lyric_fullscreen_hide" :model-value="appSetting['desktopLyric.fullscreenHide']" :label="$t('setting__desktop_lyric_fullscreen_hide')" @update:model-value="updateSetting({ 'desktopLyric.fullscreenHide': $event })")
.gap-top
base-checkbox(id="setting_desktop_lyric_audio_visualization" :modelValue="appSetting['desktopLyric.audioVisualization']" @update:modelValue="updateSetting({ 'desktopLyric.audioVisualization': $event })" :label="$t('setting__desktop_lyric_audio_visualization')")
base-checkbox(id="setting_desktop_lyric_audio_visualization" :model-value="appSetting['desktopLyric.audioVisualization']" :label="$t('setting__desktop_lyric_audio_visualization')" @update:model-value="updateSetting({ 'desktopLyric.audioVisualization': $event })")
.gap-top
base-checkbox(id="setting_desktop_lyric_delayScroll" :modelValue="appSetting['desktopLyric.isDelayScroll']" @update:modelValue="updateSetting({ 'desktopLyric.isDelayScroll': $event })" :label="$t('setting__desktop_lyric_delay_scroll')")
base-checkbox(id="setting_desktop_lyric_delayScroll" :model-value="appSetting['desktopLyric.isDelayScroll']" :label="$t('setting__desktop_lyric_delay_scroll')" @update:model-value="updateSetting({ 'desktopLyric.isDelayScroll': $event })")
.gap-top
base-checkbox(id="setting_desktop_lyric_alwaysOnTop" :modelValue="appSetting['desktopLyric.isAlwaysOnTop']" @update:modelValue="updateSetting({ 'desktopLyric.isAlwaysOnTop': $event })" :label="$t('setting__desktop_lyric_always_on_top')")
base-checkbox(id="setting_desktop_lyric_alwaysOnTop" :model-value="appSetting['desktopLyric.isAlwaysOnTop']" :label="$t('setting__desktop_lyric_always_on_top')" @update:model-value="updateSetting({ 'desktopLyric.isAlwaysOnTop': $event })")
.gap-top
base-checkbox(id="setting_desktop_lyric_showTaskbar" :modelValue="appSetting['desktopLyric.isShowTaskbar']" @update:modelValue="updateSetting({ 'desktopLyric.isShowTaskbar': $event })" :label="$t('setting__desktop_lyric_show_taskbar')")
base-checkbox(id="setting_desktop_lyric_showTaskbar" :model-value="appSetting['desktopLyric.isShowTaskbar']" :label="$t('setting__desktop_lyric_show_taskbar')" @update:model-value="updateSetting({ 'desktopLyric.isShowTaskbar': $event })")
.gap-top
base-checkbox(id="setting_desktop_lyric_alwaysOnTopLoop" :modelValue="appSetting['desktopLyric.isAlwaysOnTopLoop']" @update:modelValue="updateSetting({ 'desktopLyric.isAlwaysOnTopLoop': $event })" :label="$t('setting__desktop_lyric_always_on_top_loop')")
base-checkbox(id="setting_desktop_lyric_alwaysOnTopLoop" :model-value="appSetting['desktopLyric.isAlwaysOnTopLoop']" :label="$t('setting__desktop_lyric_always_on_top_loop')" @update:model-value="updateSetting({ 'desktopLyric.isAlwaysOnTopLoop': $event })")
.gap-top
base-checkbox(id="setting_desktop_lyric_lockScreen" :modelValue="appSetting['desktopLyric.isLockScreen']" @update:modelValue="updateSetting({ 'desktopLyric.isLockScreen': $event })" :label="$t('setting__desktop_lyric_lock_screen')")
base-checkbox(id="setting_desktop_lyric_lockScreen" :model-value="appSetting['desktopLyric.isLockScreen']" :label="$t('setting__desktop_lyric_lock_screen')" @update:model-value="updateSetting({ 'desktopLyric.isLockScreen': $event })")
.gap-top(v-if="!isLinux")
base-checkbox(id="setting_desktop_lyric_hoverHide" :modelValue="appSetting['desktopLyric.isHoverHide']" @update:modelValue="updateSetting({ 'desktopLyric.isHoverHide': $event })" :label="$t('setting__desktop_lyric_hover_hide')")
base-checkbox(id="setting_desktop_lyric_hoverHide" :model-value="appSetting['desktopLyric.isHoverHide']" :label="$t('setting__desktop_lyric_hover_hide')" @update:model-value="updateSetting({ 'desktopLyric.isHoverHide': $event })")
.gap-top
base-checkbox(id="setting_desktop_lyric_ellipsis" :modelValue="appSetting['desktopLyric.style.ellipsis']" @update:modelValue="updateSetting({ 'desktopLyric.style.ellipsis': $event })" :label="$t('setting__desktop_lyric_ellipsis')")
base-checkbox(id="setting_desktop_lyric_ellipsis" :model-value="appSetting['desktopLyric.style.ellipsis']" :label="$t('setting__desktop_lyric_ellipsis')" @update:model-value="updateSetting({ 'desktopLyric.style.ellipsis': $event })")
.gap-top
base-checkbox(id="setting_desktop_lyric_zoom" :modelValue="appSetting['desktopLyric.style.isZoomActiveLrc']" @update:modelValue="updateSetting({ 'desktopLyric.style.isZoomActiveLrc': $event })" :label="$t('desktop_lyric__lrc_active_zoom_on')")
base-checkbox(id="setting_desktop_lyric_zoom" :model-value="appSetting['desktopLyric.style.isZoomActiveLrc']" :label="$t('desktop_lyric__lrc_active_zoom_on')" @update:model-value="updateSetting({ 'desktopLyric.style.isZoomActiveLrc': $event })")
//- .gap-top
base-checkbox(id="setting_desktop_lyric_fontWeight" :modelValue="appSetting['desktopLyric.style.fontWeight']" @update:modelValue="updateSetting({ 'desktopLyric.style.fontWeight': $event })" :label="$t('setting__desktop_lyric_font_weight')")
base-checkbox(id="setting_desktop_lyric_fontWeight" :modelValue="appSetting['desktopLyric.style.fontWeight']" @update:model-value="updateSetting({ 'desktopLyric.style.fontWeight': $event })" :label="$t('setting__desktop_lyric_font_weight')")
dd
h3#setting__desktop_lyric_font_weight {{$t('setting__desktop_lyric_font_weight')}}
h3#setting__desktop_lyric_font_weight {{ $t('setting__desktop_lyric_font_weight') }}
div
base-checkbox.gap-left(id="setting_setting__desktop_lyric_font_weight_font" :modelValue="appSetting['desktopLyric.style.isFontWeightFont']" @update:modelValue="updateSetting({ 'desktopLyric.style.isFontWeightFont': $event })" :label="$t('setting__setting__desktop_lyric_font_weight_font')")
base-checkbox.gap-left(id="setting_setting__desktop_lyric_font_weight_line" :modelValue="appSetting['desktopLyric.style.isFontWeightLine']" @update:modelValue="updateSetting({ 'desktopLyric.style.isFontWeightLine': $event })" :label="$t('setting__setting__desktop_lyric_font_weight_line')")
base-checkbox.gap-left(id="setting_setting__desktop_lyric_font_weight_extended" :modelValue="appSetting['desktopLyric.style.isFontWeightExtended']" @update:modelValue="updateSetting({ 'desktopLyric.style.isFontWeightExtended': $event })" :label="$t('setting__setting__desktop_lyric_font_weight_extended')")
base-checkbox.gap-left(id="setting_setting__desktop_lyric_font_weight_font" :model-value="appSetting['desktopLyric.style.isFontWeightFont']" :label="$t('setting__setting__desktop_lyric_font_weight_font')" @update:model-value="updateSetting({ 'desktopLyric.style.isFontWeightFont': $event })")
base-checkbox.gap-left(id="setting_setting__desktop_lyric_font_weight_line" :model-value="appSetting['desktopLyric.style.isFontWeightLine']" :label="$t('setting__setting__desktop_lyric_font_weight_line')" @update:model-value="updateSetting({ 'desktopLyric.style.isFontWeightLine': $event })")
base-checkbox.gap-left(id="setting_setting__desktop_lyric_font_weight_extended" :model-value="appSetting['desktopLyric.style.isFontWeightExtended']" :label="$t('setting__setting__desktop_lyric_font_weight_extended')" @update:model-value="updateSetting({ 'desktopLyric.style.isFontWeightExtended': $event })")
dd
h3#desktop_lyric_direction {{$t('setting__desktop_lyric_direction')}}
h3#desktop_lyric_direction {{ $t('setting__desktop_lyric_direction') }}
div
base-checkbox.gap-left(id="setting_desktop_lyric_direction_horizontal" :modelValue="appSetting['desktopLyric.direction']" @update:modelValue="updateSetting({ 'desktopLyric.direction': $event })" need value="horizontal" :label="$t('setting__desktop_lyric_direction_horizontal')")
base-checkbox.gap-left(id="setting_desktop_lyric_direction_vertical" :modelValue="appSetting['desktopLyric.direction']" @update:modelValue="updateSetting({ 'desktopLyric.direction': $event })" need value="vertical" :label="$t('setting__desktop_lyric_direction_vertical')")
base-checkbox.gap-left(id="setting_desktop_lyric_direction_horizontal" :model-value="appSetting['desktopLyric.direction']" need value="horizontal" :label="$t('setting__desktop_lyric_direction_horizontal')" @update:model-value="updateSetting({ 'desktopLyric.direction': $event })")
base-checkbox.gap-left(id="setting_desktop_lyric_direction_vertical" :model-value="appSetting['desktopLyric.direction']" need value="vertical" :label="$t('setting__desktop_lyric_direction_vertical')" @update:model-value="updateSetting({ 'desktopLyric.direction': $event })")
dd
h3#desktop_lyric_scroll_align {{$t('setting__desktop_lyric_scroll_align')}}
h3#desktop_lyric_scroll_align {{ $t('setting__desktop_lyric_scroll_align') }}
div
base-checkbox.gap-left(id="setting_desktop_lyric_scroll_align_top" :modelValue="appSetting['desktopLyric.scrollAlign']" @update:modelValue="updateSetting({ 'desktopLyric.scrollAlign': $event })" need value="top" :label="$t('setting__desktop_lyric_scroll_align_top')")
base-checkbox.gap-left(id="setting_desktop_lyric_scroll_align_center" :modelValue="appSetting['desktopLyric.scrollAlign']" @update:modelValue="updateSetting({ 'desktopLyric.scrollAlign': $event })" need value="center" :label="$t('setting__desktop_lyric_scroll_align_center')")
base-checkbox.gap-left(id="setting_desktop_lyric_scroll_align_top" :model-value="appSetting['desktopLyric.scrollAlign']" need value="top" :label="$t('setting__desktop_lyric_scroll_align_top')" @update:model-value="updateSetting({ 'desktopLyric.scrollAlign': $event })")
base-checkbox.gap-left(id="setting_desktop_lyric_scroll_align_center" :model-value="appSetting['desktopLyric.scrollAlign']" need value="center" :label="$t('setting__desktop_lyric_scroll_align_center')" @update:model-value="updateSetting({ 'desktopLyric.scrollAlign': $event })")
dd
h3#desktop_lyric_align {{$t('setting__desktop_lyric_align')}}
h3#desktop_lyric_align {{ $t('setting__desktop_lyric_align') }}
div
base-checkbox.gap-left(id="setting_desktop_lyric_align_left" :modelValue="appSetting['desktopLyric.style.align']" @update:modelValue="updateSetting({ 'desktopLyric.style.align': $event })" need value="left" :label="$t('setting__desktop_lyric_align_left')")
base-checkbox.gap-left(id="setting_desktop_lyric_align_center" :modelValue="appSetting['desktopLyric.style.align']" @update:modelValue="updateSetting({ 'desktopLyric.style.align': $event })" need value="center" :label="$t('setting__desktop_lyric_align_center')")
base-checkbox.gap-left(id="setting_desktop_lyric_align_right" :modelValue="appSetting['desktopLyric.style.align']" @update:modelValue="updateSetting({ 'desktopLyric.style.align': $event })" need value="right" :label="$t('setting__desktop_lyric_align_right')")
base-checkbox.gap-left(id="setting_desktop_lyric_align_left" :model-value="appSetting['desktopLyric.style.align']" need value="left" :label="$t('setting__desktop_lyric_align_left')" @update:model-value="updateSetting({ 'desktopLyric.style.align': $event })")
base-checkbox.gap-left(id="setting_desktop_lyric_align_center" :model-value="appSetting['desktopLyric.style.align']" need value="center" :label="$t('setting__desktop_lyric_align_center')" @update:model-value="updateSetting({ 'desktopLyric.style.align': $event })")
base-checkbox.gap-left(id="setting_desktop_lyric_align_right" :model-value="appSetting['desktopLyric.style.align']" need value="right" :label="$t('setting__desktop_lyric_align_right')" @update:model-value="updateSetting({ 'desktopLyric.style.align': $event })")
dd
h3#desktop_lyric_line_gap {{$t('setting__desktop_lyric_line_gap', { num: appSetting['desktopLyric.style.lineGap'] })}}
h3#desktop_lyric_line_gap {{ $t('setting__desktop_lyric_line_gap', { num: appSetting['desktopLyric.style.lineGap'] }) }}
div
p
base-btn.btn(min @click="changeLineGap(-1)") {{$t('setting__desktop_lyric_line_gap_dec')}}
.p
base-btn.btn(min @click="changeLineGap(-1)") {{ $t('setting__desktop_lyric_line_gap_dec') }}
base-btn.btn(min @click="changeLineGap(1)") {{$t('setting__desktop_lyric_line_gap_add')}}
dd
h3#desktop_lyric_color {{$t('setting__desktop_lyric_color')}}
h3#desktop_lyric_color {{ $t('setting__desktop_lyric_color') }}
div
p.gap-top
.p.gap-top
div(:class="$style.groupContent")
div(:class="$style.item")
div(ref="lyric_unplay_color_ref", :class="$style.color")
div(ref="lyric_unplay_color_ref" :class="$style.color")
div(:class="$style.label") {{ $t('setting__desktop_lyric_unplay_color') }}
div(:class="$style.item")
div(ref="lyric_played_color_ref", :class="$style.color")
div(ref="lyric_played_color_ref" :class="$style.color")
div(:class="$style.label") {{ $t('setting__desktop_lyric_played_color') }}
div(:class="$style.item")
div(ref="lyric_shadow_color_ref", :class="$style.color")
div(ref="lyric_shadow_color_ref" :class="$style.color")
div(:class="$style.label") {{ $t('setting__desktop_lyric_shadow_color') }}
p.gap-top
.p.gap-top
base-btn.btn(min @click="resetColor") {{$t('setting__desktop_lyric_color_reset')}}
dd
h3#desktop_lyric_font {{$t('setting__desktop_lyric_font')}}
h3#desktop_lyric_font {{ $t('setting__desktop_lyric_font') }}
div
base-selection.gap-teft(:list="fontList" :modelValue="appSetting['desktopLyric.style.font']" @update:modelValue="updateSetting({ 'desktopLyric.style.font': $event })" item-key="id" item-name="label")
base-selection.gap-teft(:list="fontList" :model-value="appSetting['desktopLyric.style.font']" item-key="id" item-name="label" @update:model-value="updateSetting({ 'desktopLyric.style.font': $event })")
dd
h3#desktop_lyric_reset {{ $t('setting__desktop_lyric_reset') }}
div
p.gap-top
.p.gap-top
base-btn.btn(min @click="resetWindowSetting") {{$t('setting__desktop_lyric_reset_window')}}
</template>

View File

@ -1,53 +1,56 @@
<template lang="pug">
dt#download {{$t('setting__download')}}
dt#download {{ $t('setting__download') }}
dd
.gap-top
base-checkbox(id="setting_download_enable" :modelValue="appSetting['download.enable']" @update:modelValue="updateSetting({'download.enable': $event})" :label="$t('setting__download_enable')")
base-checkbox(id="setting_download_enable" :model-value="appSetting['download.enable']" :label="$t('setting__download_enable')" @update:model-value="updateSetting({'download.enable': $event})")
.gap-top
base-checkbox(id="setting_download_skip_exist_file" :modelValue="appSetting['download.skipExistFile']" @update:modelValue="updateSetting({'download.skipExistFile': $event})" :label="$t('setting__download_skip_exist_file')")
base-checkbox(id="setting_download_skip_exist_file" :model-value="appSetting['download.skipExistFile']" :label="$t('setting__download_skip_exist_file')" @update:model-value="updateSetting({'download.skipExistFile': $event})")
dd(:aria-label="$t('setting__download_path_title')")
h3#download_path {{$t('setting__download_path')}}
h3#download_path {{ $t('setting__download_path') }}
div
p
| {{$t('setting__download_path_label')}}
span.auto-hidden.hover(:class="$style.savePath" @click="openDirInExplorer(appSetting['download.savePath'])" :aria-label="$t('setting__download_path_open_label')") {{appSetting['download.savePath']}}
p
.p
| {{ $t('setting__download_path_label') }}
span.auto-hidden.hover(:class="$style.savePath" :aria-label="$t('setting__download_path_open_label')" @click="openDirInExplorer(appSetting['download.savePath'])") {{ appSetting['download.savePath'] }}
.p
base-btn.btn(min @click="handleChangeSavePath") {{$t('setting__download_path_change_btn')}}
dd
h3#download_use_other_source
| {{$t('setting__download_use_other_source')}}
| {{ $t('setting__download_use_other_source') }}
svg-icon(class="help-icon" name="help-circle-outline" :aria-label="$t('setting__download_use_other_source_tip')")
div
base-checkbox(id="setting_download_isUseOtherSource" :modelValue="appSetting['download.isUseOtherSource']" @update:modelValue="updateSetting({'download.isUseOtherSource': $event})" :label="$t('setting__is_enable')")
base-checkbox(id="setting_download_isUseOtherSource" :model-value="appSetting['download.isUseOtherSource']" :label="$t('setting__is_enable')" @update:model-value="updateSetting({'download.isUseOtherSource': $event})")
div
dd(:aria-label="$t('setting__download_name_title')")
h3#download_name {{$t('setting__download_name')}}
h3#download_name {{ $t('setting__download_name') }}
div
base-checkbox.gap-left(:id="`setting_download_musicName_${item.value}`" name="setting_download_musicName" :value="item.value" :key="item.value" need
:modelValue="appSetting['download.fileName']" @update:modelValue="updateSetting({'download.fileName': $event})" v-for="item in musicNames" :label="item.name")
base-checkbox.gap-left(
v-for="item in musicNames" :id="`setting_download_musicName_${item.value}`" :key="item.value" name="setting_download_musicName" :value="item.value"
need :model-value="appSetting['download.fileName']" :label="item.name" @update:model-value="updateSetting({'download.fileName': $event})")
dd
h3#download_data_embed {{$t('setting__download_data_embed')}}
h3#download_data_embed {{ $t('setting__download_data_embed') }}
.gap-top
base-checkbox(id="setting_download_isEmbedPic" :modelValue="appSetting['download.isEmbedPic']" @update:modelValue="updateSetting({'download.isEmbedPic': $event})" :label="$t('setting__download_embed_pic')")
base-checkbox(id="setting_download_isEmbedPic" :model-value="appSetting['download.isEmbedPic']" :label="$t('setting__download_embed_pic')" @update:model-value="updateSetting({'download.isEmbedPic': $event})")
.gap-top
base-checkbox(id="setting_download_isEmbedLyric" :modelValue="appSetting['download.isEmbedLyric']" @update:modelValue="updateSetting({'download.isEmbedLyric': $event})" :label="$t('setting__download_embed_lyric')")
base-checkbox(id="setting_download_isEmbedLyric" :model-value="appSetting['download.isEmbedLyric']" :label="$t('setting__download_embed_lyric')" @update:model-value="updateSetting({'download.isEmbedLyric': $event})")
.gap-top
base-checkbox(id="setting_download_isEmbedLyricT" :disabled="!appSetting['download.isEmbedLyric']" :modelValue="appSetting['download.isEmbedLyricT']" @update:modelValue="updateSetting({'download.isEmbedLyricT': $event})" :label="$t('setting__download_embed_tlyric')")
base-checkbox(id="setting_download_isEmbedLyricT" :disabled="!appSetting['download.isEmbedLyric']" :model-value="appSetting['download.isEmbedLyricT']" :label="$t('setting__download_embed_tlyric')" @update:model-value="updateSetting({'download.isEmbedLyricT': $event})")
.gap-top
base-checkbox(id="setting_download_isEmbedLyricR" :disabled="!appSetting['download.isEmbedLyric']" :modelValue="appSetting['download.isEmbedLyricR']" @update:modelValue="updateSetting({'download.isEmbedLyricR': $event})" :label="$t('setting__download_embed_rlyric')")
base-checkbox(id="setting_download_isEmbedLyricR" :disabled="!appSetting['download.isEmbedLyric']" :model-value="appSetting['download.isEmbedLyricR']" :label="$t('setting__download_embed_rlyric')" @update:model-value="updateSetting({'download.isEmbedLyricR': $event})")
dd(:aria-label="$t('setting__download_lyric_title')")
h3#download_lyric {{$t('setting__download_lyric')}}
h3#download_lyric {{ $t('setting__download_lyric') }}
.gap-top
base-checkbox(id="setting_download_isDownloadLrc" :modelValue="appSetting['download.isDownloadLrc']" @update:modelValue="updateSetting({'download.isDownloadLrc': $event})" :label="$t('setting__is_enable')")
base-checkbox(id="setting_download_isDownloadLrc" :model-value="appSetting['download.isDownloadLrc']" :label="$t('setting__is_enable')" @update:model-value="updateSetting({'download.isDownloadLrc': $event})")
.gap-top
base-checkbox(id="setting_download_isDownloadTLrc" :disabled="!appSetting['download.isDownloadLrc']" :modelValue="appSetting['download.isDownloadTLrc']" @update:modelValue="updateSetting({'download.isDownloadTLrc': $event})" :label="$t('setting__download_tlyric')")
base-checkbox(id="setting_download_isDownloadTLrc" :disabled="!appSetting['download.isDownloadLrc']" :model-value="appSetting['download.isDownloadTLrc']" :label="$t('setting__download_tlyric')" @update:model-value="updateSetting({'download.isDownloadTLrc': $event})")
.gap-top
base-checkbox(id="setting_download_isDownloadRLrc" :disabled="!appSetting['download.isDownloadLrc']" :modelValue="appSetting['download.isDownloadRLrc']" @update:modelValue="updateSetting({'download.isDownloadRLrc': $event})" :label="$t('setting__download_rlyric')")
base-checkbox(id="setting_download_isDownloadRLrc" :disabled="!appSetting['download.isDownloadLrc']" :model-value="appSetting['download.isDownloadRLrc']" :label="$t('setting__download_rlyric')" @update:model-value="updateSetting({'download.isDownloadRLrc': $event})")
dd
h3#download_lyric_format {{$t('setting__download_lyric_format')}}
h3#download_lyric_format {{ $t('setting__download_lyric_format') }}
div
base-checkbox.gap-left(v-for="item in lrcFormatList" :key="item.id" :id="`setting_download_lrcFormat_${item.id}`"
name="setting_download_lrcFormat" need :modelValue="appSetting['download.lrcFormat']" @update:modelValue="updateSetting({'download.lrcFormat': $event})" :value="item.id" :label="item.name")
base-checkbox.gap-left(
v-for="item in lrcFormatList" :id="`setting_download_lrcFormat_${item.id}`" :key="item.id"
name="setting_download_lrcFormat" need :model-value="appSetting['download.lrcFormat']" :value="item.id" :label="item.name"
@update:model-value="updateSetting({'download.lrcFormat': $event})")
</template>
<script>

View File

@ -1,25 +1,27 @@
<template lang="pug">
dt#hot_key {{$t('setting__hot_key')}}
dt#hot_key {{ $t('setting__hot_key') }}
dd
h3#hot_key_local_title {{$t('setting__hot_key_local_title')}}
h3#hot_key_local_title {{ $t('setting__hot_key_local_title') }}
div
base-checkbox(id="setting_download_hotKeyLocal" v-model="current_hot_key.local.enable" :label="$t('setting__is_enable')" @change="handleHotKeySaveConfig")
div(:class="$style.hotKeyContainer" :style="{ opacity: current_hot_key.local.enable ? 1 : .6 }")
div(:class="$style.hotKeyItem" v-for="item in allHotKeys.local")
h4(:class="$style.hotKeyItemTitle") {{$t('setting__hot_key_' + item.name)}}
base-input(:class="$style.hotKeyItemInput" readonly @keyup.prevent :auto-paste="false" :placeholder="$t('setting__hot_key_unset_input')"
:value="hotKeyConfig.local[item.name] && formatHotKeyName(hotKeyConfig.local[item.name].key)"
div(v-for="(item, index) in allHotKeys.local" :key="index" :class="$style.hotKeyItem")
h4(:class="$style.hotKeyItemTitle") {{ $t('setting__hot_key_' + item.name) }}
base-input(
:class="$style.hotKeyItemInput" readonly :auto-paste="false" :placeholder="$t('setting__hot_key_unset_input')" :value="hotKeyConfig.local[item.name] && formatHotKeyName(hotKeyConfig.local[item.name].key)"
@keyup.prevent
@focus="handleHotKeyFocus($event, item, 'local')"
@blur="handleHotKeyBlur($event, item, 'local')")
dd
h3#hot_key_global_title {{$t('setting__hot_key_global_title')}}
h3#hot_key_global_title {{ $t('setting__hot_key_global_title') }}
div
base-checkbox(id="setting_download_hotKeyGlobal" v-model="current_hot_key.global.enable" :label="$t('setting__is_enable')" @change="handleEnableHotKey")
div(:class="$style.hotKeyContainer" :style="{ opacity: current_hot_key.global.enable ? 1 : .6 }")
div(:class="$style.hotKeyItem" v-for="item in allHotKeys.global")
h4(:class="$style.hotKeyItemTitle") {{$t('setting__hot_key_' + item.name)}}
base-input(:class="[$style.hotKeyItemInput, hotKeyConfig.global[item.name] && hotKeyStatus[hotKeyConfig.global[item.name].key] && hotKeyStatus[hotKeyConfig.global[item.name].key].status === false ? $style.hotKeyFailed : null]"
:value="hotKeyConfig.global[item.name] && formatHotKeyName(hotKeyConfig.global[item.name].key)" @input.prevent :auto-paste="false" readonly :placeholder="$t('setting__hot_key_unset_input')"
div(v-for="(item, index) in allHotKeys.global" :key="index" :class="$style.hotKeyItem")
h4(:class="$style.hotKeyItemTitle") {{ $t('setting__hot_key_' + item.name) }}
base-input(
:class="[$style.hotKeyItemInput, hotKeyConfig.global[item.name] && hotKeyStatus[hotKeyConfig.global[item.name].key] && hotKeyStatus[hotKeyConfig.global[item.name].key].status === false ? $style.hotKeyFailed : null]"
:value="hotKeyConfig.global[item.name] && formatHotKeyName(hotKeyConfig.global[item.name].key)" :auto-paste="false" readonly :placeholder="$t('setting__hot_key_unset_input')" @input.prevent
@focus="handleHotKeyFocus($event, item, 'global')"
@blur="handleHotKeyBlur($event, item, 'global')")
</template>

View File

@ -1,21 +1,25 @@
<template lang="pug">
dt#list {{$t('setting__list')}}
dt#list {{ $t('setting__list') }}
dd
.gap-top
base-checkbox(id="setting_list_actionButtonsVisible_enable" :modelValue="appSetting['list.actionButtonsVisible']" @update:modelValue="updateSetting({'list.actionButtonsVisible': $event})" :label="$t('setting__list_action_btn')")
base-checkbox(id="setting_list_actionButtonsVisible_enable" :model-value="appSetting['list.actionButtonsVisible']" :label="$t('setting__list_action_btn')" @update:model-value="updateSetting({'list.actionButtonsVisible': $event})")
.gap-top
base-checkbox(id="setting_list_showSource_enable" :modelValue="appSetting['list.isShowSource']" @update:modelValue="updateSetting({'list.isShowSource': $event})" :label="$t('setting__list_source')")
base-checkbox(id="setting_list_showSource_enable" :model-value="appSetting['list.isShowSource']" :label="$t('setting__list_source')" @update:model-value="updateSetting({'list.isShowSource': $event})")
.gap-top
base-checkbox(id="setting_list_scroll_enable" :modelValue="appSetting['list.isSaveScrollLocation']" @update:modelValue="updateSetting({'list.isSaveScrollLocation': $event})" :label="$t('setting__list_scroll')")
base-checkbox(id="setting_list_scroll_enable" :model-value="appSetting['list.isSaveScrollLocation']" :label="$t('setting__list_scroll')" @update:model-value="updateSetting({'list.isSaveScrollLocation': $event})")
.gap-top
base-checkbox(id="setting_list_clickAction_enable" :modelValue="appSetting['list.isClickPlayList']" @update:modelValue="updateSetting({'list.isClickPlayList': $event})" :label="$t('setting__list_click_action')")
base-checkbox(id="setting_list_clickAction_enable" :model-value="appSetting['list.isClickPlayList']" :label="$t('setting__list_click_action')" @update:model-value="updateSetting({'list.isClickPlayList': $event})")
dd(:aria-label="$t('setting__basic_sourcename_title')")
h3#list_addMusicLocationType {{$t('setting__list_add_music_location_type')}}
h3#list_addMusicLocationType {{ $t('setting__list_add_music_location_type') }}
div
base-checkbox.gap-left(id="setting_list_add_music_location_type_top"
name="setting_list_add_music_location_type" need :modelValue="appSetting['list.addMusicLocationType']" @update:modelValue="updateSetting({'list.addMusicLocationType': $event})" value="top" :label="$t('setting__list_add_music_location_type_top')")
base-checkbox.gap-left(id="setting_list_add_music_location_type_bottom"
name="setting_list_add_music_location_type" need :modelValue="appSetting['list.addMusicLocationType']" @update:modelValue="updateSetting({'list.addMusicLocationType': $event})" value="bottom" :label="$t('setting__list_add_music_location_type_bottom')")
base-checkbox.gap-left(
id="setting_list_add_music_location_type_top" name="setting_list_add_music_location_type" need
:model-value="appSetting['list.addMusicLocationType']" value="top" :label="$t('setting__list_add_music_location_type_top')"
@update:model-value="updateSetting({'list.addMusicLocationType': $event})")
base-checkbox.gap-left(
id="setting_list_add_music_location_type_bottom" name="setting_list_add_music_location_type" need
:model-value="appSetting['list.addMusicLocationType']" value="bottom" :label="$t('setting__list_add_music_location_type_bottom')"
@update:model-value="updateSetting({'list.addMusicLocationType': $event})")
</template>

View File

@ -1,16 +1,16 @@
<template lang="pug">
dt#network {{$t('setting__network')}}
dt#network {{ $t('setting__network') }}
dd
h3#network_proxy_title {{$t('setting__network_proxy_title')}}
h3#network_proxy_title {{ $t('setting__network_proxy_title') }}
div
p
base-checkbox(id="setting_network_proxy_enable" :modelValue="appSetting['network.proxy.enable']" @update:modelValue="updateSetting({'network.proxy.enable': $event})" :label="$t('setting__is_enable')")
p
base-input.gap-left(:modelValue="appSetting['network.proxy.host']" @update:modelValue="setHost" :placeholder="proxy.envProxy ? proxy.envProxy.host : $t('setting__network_proxy_host')")
base-input.gap-left(:modelValue="appSetting['network.proxy.port']" @update:modelValue="setPort" :placeholder="proxy.envProxy ? proxy.envProxy.port : $t('setting__network_proxy_port')")
p
base-input.gap-left(:modelValue="appSetting['network.proxy.username']" @update:modelValue="setUserName" :placeholder="$t('setting__network_proxy_username')")
base-input.gap-left(:modelValue="appSetting['network.proxy.password']" @update:modelValue="setPassword" type="password" :placeholder="$t('setting__network_proxy_password')")
.p
base-checkbox(id="setting_network_proxy_enable" :model-value="appSetting['network.proxy.enable']" :label="$t('setting__is_enable')" @update:model-value="updateSetting({'network.proxy.enable': $event})")
.p
base-input.gap-left(:model-value="appSetting['network.proxy.host']" :placeholder="proxy.envProxy ? proxy.envProxy.host : $t('setting__network_proxy_host')" @update:model-value="setHost")
base-input.gap-left(:model-value="appSetting['network.proxy.port']" :placeholder="proxy.envProxy ? proxy.envProxy.port : $t('setting__network_proxy_port')" @update:model-value="setPort")
.p
base-input.gap-left(:model-value="appSetting['network.proxy.username']" :placeholder="$t('setting__network_proxy_username')" @update:model-value="setUserName")
base-input.gap-left(:model-value="appSetting['network.proxy.password']" type="password" :placeholder="$t('setting__network_proxy_password')" @update:model-value="setPassword")
</template>

View File

@ -1,10 +1,10 @@
<template lang="pug">
dt#odc {{$t('setting__odc')}}
dt#odc {{ $t('setting__odc') }}
dd
.gap-top
base-checkbox(id="setting_odc_isAutoClearSearchInput" :modelValue="appSetting['odc.isAutoClearSearchInput']" @update:modelValue="updateSetting({'odc.isAutoClearSearchInput': $event})" :label="$t('setting__odc_clear_search_input')")
base-checkbox(id="setting_odc_isAutoClearSearchInput" :model-value="appSetting['odc.isAutoClearSearchInput']" :label="$t('setting__odc_clear_search_input')" @update:model-value="updateSetting({'odc.isAutoClearSearchInput': $event})")
.gap-top
base-checkbox(id="setting_odc_isAutoClearSearchList" :modelValue="appSetting['odc.isAutoClearSearchList']" @update:modelValue="updateSetting({'odc.isAutoClearSearchList': $event})" :label="$t('setting__odc_clear_search_list')")
base-checkbox(id="setting_odc_isAutoClearSearchList" :model-value="appSetting['odc.isAutoClearSearchList']" :label="$t('setting__odc_clear_search_list')" @update:model-value="updateSetting({'odc.isAutoClearSearchList': $event})")
</template>
<script>

View File

@ -1,51 +1,52 @@
<template lang="pug">
dt#other {{$t('setting__other')}}
dt#other {{ $t('setting__other') }}
dd
h3#other_tray_theme {{$t('setting__other_tray_theme')}}
h3#other_tray_theme {{ $t('setting__other_tray_theme') }}
div
base-checkbox.gap-left(:id="'setting_tray_theme_' + item.id" :modelValue="appSetting['tray.themeId']" @update:modelValue="updateSetting({'tray.themeId': $event})" name="setting_tray_theme" need
:label="item.label" :key="item.id" :value="item.id" v-for="item in trayThemeList")
base-checkbox.gap-left(
v-for="item in trayThemeList" :id="'setting_tray_theme_' + item.id" :key="item.id" :model-value="appSetting['tray.themeId']" name="setting_tray_theme"
need :label="item.label" :value="item.id" @update:model-value="updateSetting({'tray.themeId': $event})")
dd
h3#other_resource_cache
| {{$t('setting__other_resource_cache')}}
| {{ $t('setting__other_resource_cache') }}
svg-icon(class="help-icon" name="help-circle-outline" :aria-label="$t('setting__other_resource_cache_tip')")
div
p
| {{$t('setting__other_resource_cache_label')}}
span.auto-hidden {{cacheSize}}
p
.p
| {{ $t('setting__other_resource_cache_label') }}
span.auto-hidden {{ cacheSize }}
.p
base-btn.btn(min :disabled="isDisabledResourceCacheClear" @click="clearResourceCache") {{$t('setting__other_resource_cache_clear_btn')}}
dd
h3#other_other_source {{$t('setting__other_other_cache')}}
h3#other_other_source {{ $t('setting__other_other_cache') }}
div
p
| {{$t('setting__other_other_source_label')}}
span.auto-hidden {{otherSourceCount}}
p
| {{$t('setting__other_music_url_label')}}
span.auto-hidden {{musicUrlCount}}
p
| {{$t('setting__other_lyric_raw_label')}}
span.auto-hidden {{lyricRawCount}}
p
base-btn.btn(min :disabled="isDisabledOtherSourceCacheClear" @click="handleClearOtherSourceCache") {{$t('setting__other_other_source_clear_btn')}}
base-btn.btn(min :disabled="isDisabledMusicUrlCacheClear" @click="handleClearMusicUrlCache") {{$t('setting__other_music_url_clear_btn')}}
.p
| {{ $t('setting__other_other_source_label') }}
span.auto-hidden {{ otherSourceCount }}
.p
| {{ $t('setting__other_music_url_label') }}
span.auto-hidden {{ musicUrlCount }}
.p
| {{ $t('setting__other_lyric_raw_label') }}
span.auto-hidden {{ lyricRawCount }}
.p
base-btn.btn(min :disabled="isDisabledOtherSourceCacheClear" @click="handleClearOtherSourceCache") {{ $t('setting__other_other_source_clear_btn') }}
base-btn.btn(min :disabled="isDisabledMusicUrlCacheClear" @click="handleClearMusicUrlCache") {{ $t('setting__other_music_url_clear_btn') }}
base-btn.btn(min :disabled="isDisabledLyricRawCacheClear" @click="handleClearLyricRawCache") {{$t('setting__other_lyric_raw_clear_btn')}}
dd
h3#other_lyric_edited {{$t('setting__other_lyric_edited_cache')}}
h3#other_lyric_edited {{ $t('setting__other_lyric_edited_cache') }}
div
p
| {{$t('setting__other_lyric_edited_label')}}
span.auto-hidden {{lyricEditedCount}}
p
.p
| {{ $t('setting__other_lyric_edited_label') }}
span.auto-hidden {{ lyricEditedCount }}
.p
base-btn.btn(min :disabled="isDisabledLyricEditedCacheClear" @click="handleClearLyricEditedCache") {{$t('setting__other_lyric_edited_clear_btn')}}
dd
h3#other_lyric_edited {{$t('setting__other_listdata')}}
h3#other_lyric_edited {{ $t('setting__other_listdata') }}
div
p
.p
base-btn.btn(min @click="handleClearListData") {{$t('setting__other_listdata_clear_btn')}}
</template>

View File

@ -1,30 +1,30 @@
<template lang="pug">
dt#play {{$t('setting__play')}}
dt#play {{ $t('setting__play') }}
dd
.gap-top
base-checkbox(id="setting_player_startup_auto_play" :modelValue="appSetting['player.startupAutoPlay']" @update:modelValue="updateSetting({'player.startupAutoPlay': $event})" :label="$t('setting__play_startup_auto_play')")
base-checkbox(id="setting_player_startup_auto_play" :model-value="appSetting['player.startupAutoPlay']" :label="$t('setting__play_startup_auto_play')" @update:model-value="updateSetting({'player.startupAutoPlay': $event})")
.gap-top
base-checkbox(id="setting_player_save_play_time" :modelValue="appSetting['player.isSavePlayTime']" @update:modelValue="updateSetting({'player.isSavePlayTime': $event})" :label="$t('setting__play_save_play_time')")
base-checkbox(id="setting_player_save_play_time" :model-value="appSetting['player.isSavePlayTime']" :label="$t('setting__play_save_play_time')" @update:model-value="updateSetting({'player.isSavePlayTime': $event})")
.gap-top
base-checkbox(id="setting_player_lyric_transition" :modelValue="appSetting['player.isShowLyricTranslation']" @update:modelValue="updateSetting({'player.isShowLyricTranslation': $event})" :label="$t('setting__play_lyric_transition')")
base-checkbox(id="setting_player_lyric_transition" :model-value="appSetting['player.isShowLyricTranslation']" :label="$t('setting__play_lyric_transition')" @update:model-value="updateSetting({'player.isShowLyricTranslation': $event})")
.gap-top
base-checkbox(id="setting_player_lyric_roma" :modelValue="appSetting['player.isShowLyricRoma']" @update:modelValue="updateSetting({'player.isShowLyricRoma': $event})" :label="$t('setting__play_lyric_roma')")
base-checkbox(id="setting_player_lyric_roma" :model-value="appSetting['player.isShowLyricRoma']" :label="$t('setting__play_lyric_roma')" @update:model-value="updateSetting({'player.isShowLyricRoma': $event})")
.gap-top
base-checkbox(id="setting_player_auto_skip_on_error" :modelValue="appSetting['player.autoSkipOnError']" @update:modelValue="updateSetting({'player.autoSkipOnError': $event})" :label="$t('setting__play_auto_skip_on_error')")
base-checkbox(id="setting_player_auto_skip_on_error" :model-value="appSetting['player.autoSkipOnError']" :label="$t('setting__play_auto_skip_on_error')" @update:model-value="updateSetting({'player.autoSkipOnError': $event})")
.gap-top
base-checkbox(id="setting_player_lyric_s2t" :modelValue="appSetting['player.isS2t']" @update:modelValue="updateSetting({'player.isS2t': $event})" :label="$t('setting__play_lyric_s2t')")
base-checkbox(id="setting_player_lyric_s2t" :model-value="appSetting['player.isS2t']" :label="$t('setting__play_lyric_s2t')" @update:model-value="updateSetting({'player.isS2t': $event})")
.gap-top
base-checkbox(id="setting_player_lyric_play_lxlrc" :modelValue="appSetting['player.isPlayLxlrc']" @update:modelValue="updateSetting({'player.isPlayLxlrc': $event})" :label="$t('setting__play_lyric_lxlrc')")
base-checkbox(id="setting_player_lyric_play_lxlrc" :model-value="appSetting['player.isPlayLxlrc']" :label="$t('setting__play_lyric_lxlrc')" @update:model-value="updateSetting({'player.isPlayLxlrc': $event})")
.gap-top
base-checkbox(id="setting_player_highQuality" :modelValue="appSetting['player.highQuality']" @update:modelValue="updateSetting({'player.highQuality': $event})" :label="$t('setting__play_quality')")
base-checkbox(id="setting_player_highQuality" :model-value="appSetting['player.highQuality']" :label="$t('setting__play_quality')" @update:model-value="updateSetting({'player.highQuality': $event})")
.gap-top
base-checkbox(id="setting_player_showTaskProgess" :modelValue="appSetting['player.isShowTaskProgess']" @update:modelValue="updateSetting({'player.isShowTaskProgess': $event})" :label="$t('setting__play_task_bar')")
base-checkbox(id="setting_player_showTaskProgess" :model-value="appSetting['player.isShowTaskProgess']" :label="$t('setting__play_task_bar')" @update:model-value="updateSetting({'player.isShowTaskProgess': $event})")
.gap-top
base-checkbox(id="setting_player_isMediaDeviceRemovedStopPlay" :modelValue="appSetting['player.isMediaDeviceRemovedStopPlay']" @update:modelValue="updateSetting({'player.isMediaDeviceRemovedStopPlay': $event})" :label="$t('setting__play_mediaDevice_remove_stop_play')")
base-checkbox(id="setting_player_isMediaDeviceRemovedStopPlay" :model-value="appSetting['player.isMediaDeviceRemovedStopPlay']" :label="$t('setting__play_mediaDevice_remove_stop_play')" @update:model-value="updateSetting({'player.isMediaDeviceRemovedStopPlay': $event})")
dd(:aria-label="$t('setting__play_mediaDevice_title')")
h3#play_mediaDevice {{$t('setting__play_mediaDevice')}}
h3#play_mediaDevice {{ $t('setting__play_mediaDevice') }}
div
base-selection.gap-left(:list="mediaDevices" v-model="mediaDeviceId" @change="handleMediaDeviceIdChnage" item-key="deviceId" item-name="label")
base-selection.gap-left(v-model="mediaDeviceId" :list="mediaDevices" item-key="deviceId" item-name="label" @change="handleMediaDeviceIdChnage")
</template>
<script>

View File

@ -1,17 +1,17 @@
<template lang="pug">
dt#play_detail {{$t('setting__play_detail')}}
dt#play_detail {{ $t('setting__play_detail') }}
dd
.gap-top
base-checkbox(id="setting_play_detail_font_zoom_enable" :modelValue="appSetting['playDetail.isZoomActiveLrc']" @update:modelValue="updateSetting({'playDetail.isZoomActiveLrc': $event})" :label="$t('setting__play_detail_font_zoom')")
base-checkbox(id="setting_play_detail_font_zoom_enable" :model-value="appSetting['playDetail.isZoomActiveLrc']" :label="$t('setting__play_detail_font_zoom')" @update:model-value="updateSetting({'playDetail.isZoomActiveLrc': $event})")
.gap-top
base-checkbox(id="setting_play_detail_lyric_progress_enable" :modelValue="appSetting['playDetail.isShowLyricProgressSetting']" @update:modelValue="updateSetting({'playDetail.isShowLyricProgressSetting': $event})" :label="$t('setting__play_detail_lyric_progress')")
base-checkbox(id="setting_play_detail_lyric_progress_enable" :model-value="appSetting['playDetail.isShowLyricProgressSetting']" :label="$t('setting__play_detail_lyric_progress')" @update:model-value="updateSetting({'playDetail.isShowLyricProgressSetting': $event})")
dd
h3#play_detail_align {{$t('setting__play_detail_align')}}
h3#play_detail_align {{ $t('setting__play_detail_align') }}
div
base-checkbox.gap-left(id="setting_play_detail_align_left" :modelValue="appSetting['playDetail.style.align']" @update:modelValue="updateSetting({ 'playDetail.style.align': $event })" need value="left" :label="$t('setting__play_detail_align_left')")
base-checkbox.gap-left(id="setting_play_detail_align_center" :modelValue="appSetting['playDetail.style.align']" @update:modelValue="updateSetting({ 'playDetail.style.align': $event })" need value="center" :label="$t('setting__play_detail_align_center')")
base-checkbox.gap-left(id="setting_play_detail_align_right" :modelValue="appSetting['playDetail.style.align']" @update:modelValue="updateSetting({ 'playDetail.style.align': $event })" need value="right" :label="$t('setting__play_detail_align_right')")
base-checkbox.gap-left(id="setting_play_detail_align_left" :model-value="appSetting['playDetail.style.align']" need value="left" :label="$t('setting__play_detail_align_left')" @update:model-value="updateSetting({ 'playDetail.style.align': $event })")
base-checkbox.gap-left(id="setting_play_detail_align_center" :model-value="appSetting['playDetail.style.align']" need value="center" :label="$t('setting__play_detail_align_center')" @update:model-value="updateSetting({ 'playDetail.style.align': $event })")
base-checkbox.gap-left(id="setting_play_detail_align_right" :model-value="appSetting['playDetail.style.align']" need value="right" :label="$t('setting__play_detail_align_right')" @update:model-value="updateSetting({ 'playDetail.style.align': $event })")
</template>

View File

@ -1,12 +1,12 @@
<template lang="pug">
dt#search {{$t('setting__search')}}
dt#search {{ $t('setting__search') }}
dd
.gap-top
base-checkbox(id="setting_search_showHot_enable" :modelValue="appSetting['search.isShowHotSearch']" @update:modelValue="updateSetting({'search.isShowHotSearch': $event})" :label="$t('setting__search_hot')")
base-checkbox(id="setting_search_showHot_enable" :model-value="appSetting['search.isShowHotSearch']" :label="$t('setting__search_hot')" @update:model-value="updateSetting({'search.isShowHotSearch': $event})")
.gap-top
base-checkbox(id="setting_search_showHistory_enable" :modelValue="appSetting['search.isShowHistorySearch']" @update:modelValue="updateSetting({'search.isShowHistorySearch': $event})" :label="$t('setting__search_history')")
base-checkbox(id="setting_search_showHistory_enable" :model-value="appSetting['search.isShowHistorySearch']" :label="$t('setting__search_history')" @update:model-value="updateSetting({'search.isShowHistorySearch': $event})")
.gap-top
base-checkbox(id="setting_search_focusSearchBox_enable" :modelValue="appSetting['search.isFocusSearchBox']" @update:modelValue="updateSetting({'search.isFocusSearchBox': $event})" :label="$t('setting__search_focus_search_box')")
base-checkbox(id="setting_search_focusSearchBox_enable" :model-value="appSetting['search.isFocusSearchBox']" :label="$t('setting__search_focus_search_box')" @update:model-value="updateSetting({'search.isFocusSearchBox': $event})")
</template>

View File

@ -1,39 +1,40 @@
<template lang="pug">
dt#sync
| {{$t('setting__sync')}}
button(class="help-btn" @click="openUrl('https://lyswhut.github.io/lx-music-doc/desktop/faq/sync')" :aria-label="$t('setting__sync_tip')")
| {{ $t('setting__sync') }}
button(class="help-btn" :aria-label="$t('setting__sync_tip')" @click="openUrl('https://lyswhut.github.io/lx-music-doc/desktop/faq/sync')")
svg-icon(name="help-circle-outline")
dd
base-checkbox(id="setting_sync_enable" :modelValue="appSetting['sync.enable']" @update:modelValue="updateSetting({ 'sync.enable': $event })" :label="$t('setting__sync_enable')")
base-checkbox(id="setting_sync_enable" :model-value="appSetting['sync.enable']" :label="$t('setting__sync_enable')" @update:model-value="updateSetting({ 'sync.enable': $event })")
dd
h3#sync_mode {{$t('setting__sync_mode')}}
h3#sync_mode {{ $t('setting__sync_mode') }}
div
base-checkbox.gap-left(id="setting_sync_mode_server" :disabled="sync.enable" :modelValue="appSetting['sync.mode']" @update:modelValue="updateSetting({ 'sync.mode': $event })" need value="server" :label="$t('setting__sync_mode_server')")
base-checkbox.gap-left(id="setting_sync_mode_client" :disabled="sync.enable" :modelValue="appSetting['sync.mode']" @update:modelValue="updateSetting({ 'sync.mode': $event })" need value="client" :label="$t('setting__sync_mode_client')")
base-checkbox.gap-left(id="setting_sync_mode_server" :disabled="sync.enable" :model-value="appSetting['sync.mode']" need value="server" :label="$t('setting__sync_mode_server')" @update:model-value="updateSetting({ 'sync.mode': $event })")
base-checkbox.gap-left(id="setting_sync_mode_client" :disabled="sync.enable" :model-value="appSetting['sync.mode']" need value="client" :label="$t('setting__sync_mode_client')" @update:model-value="updateSetting({ 'sync.mode': $event })")
dd(v-if="sync.mode == 'client'")
h3 {{$t('setting__sync_client_mode')}}
h3 {{ $t('setting__sync_client_mode') }}
div
p.small {{$t('setting__sync_client_status', { status: clientStatus })}}
p.small {{$t('setting__sync_client_address', { address: sync.client.status.address.join(', ') || '' })}}
p
p.small {{$t('setting__sync_client_host')}}
.p.small {{ $t('setting__sync_client_status', { status: clientStatus }) }}
.p.small {{ $t('setting__sync_client_address', { address: sync.client.status.address.join(', ') || '' }) }}
.p
.p.small {{ $t('setting__sync_client_host') }}
div
base-input.gap-left(:class="$style.hostInput" :modelValue="appSetting['sync.client.host']" :disabled="sync.enable" @update:modelValue="setSyncClientHost" :placeholder="$t('setting__sync_client_host_tip')")
base-input.gap-left(:class="$style.hostInput" :model-value="appSetting['sync.client.host']" :disabled="sync.enable" :placeholder="$t('setting__sync_client_host_tip')" @update:model-value="setSyncClientHost")
dd(v-else)
h3 {{syncEnableServerTitle}}
h3 {{ syncEnableServerTitle }}
div
p.small {{$t('setting__sync_server_auth_code', { code: sync.server.status.code || '' })}}
p.small {{$t('setting__sync_server_address', { address: sync.server.status.address.join(', ') || '' })}}
p.small {{$t('setting__sync_server_device', { devices: syncDevices })}}
p
base-btn.btn(min :disabled="!sync.server.status.status" @click="refreshSyncCode") {{$t('setting__sync_server_refresh_code')}}
p
p.small {{$t('setting__sync_server_port')}}
.p.small {{ $t('setting__sync_server_auth_code', { code: sync.server.status.code || '' }) }}
.p.small {{ $t('setting__sync_server_address', { address: sync.server.status.address.join(', ') || '' }) }}
.p.small {{ $t('setting__sync_server_device', { devices: syncDevices }) }}
.p
base-btn.btn(min :disabled="!sync.server.status.status" @click="refreshSyncCode") {{ $t('setting__sync_server_refresh_code') }}
.p
.p.small {{ $t('setting__sync_server_port') }}
div
base-input.gap-left(:class="$style.portInput" :modelValue="appSetting['sync.server.port']" :disabled="sync.enable" type="number" @update:modelValue="setSyncServerPort" :placeholder="$t('setting__sync_server_port_tip')")
base-input.gap-left(:class="$style.portInput" :model-value="appSetting['sync.server.port']" :disabled="sync.enable" type="number" :placeholder="$t('setting__sync_server_port_tip')" @update:model-value="setSyncServerPort")
</template>

View File

@ -1,26 +1,26 @@
<template lang="pug">
dt#update {{$t('setting__update')}}
dt#update {{ $t('setting__update') }}
dd
.gap-top
base-checkbox(id="setting__update_tryAutoUpdate" :modelValue="appSetting['common.tryAutoUpdate']" @update:modelValue="updateSetting({'common.tryAutoUpdate': $event})" :label="$t('setting__update_try_auto_update')")
base-checkbox(id="setting__update_tryAutoUpdate" :model-value="appSetting['common.tryAutoUpdate']" :label="$t('setting__update_try_auto_update')" @update:model-value="updateSetting({'common.tryAutoUpdate': $event})")
.gap-top
base-checkbox(id="setting__update_showChangeLog" :modelValue="appSetting['common.showChangeLog']" @update:modelValue="updateSetting({'common.showChangeLog': $event})" :label="$t('setting__update_show_change_log')")
base-checkbox(id="setting__update_showChangeLog" :model-value="appSetting['common.showChangeLog']" :label="$t('setting__update_show_change_log')" @update:model-value="updateSetting({'common.showChangeLog': $event})")
.gap-top
p.small
| {{$t('setting__update_latest_label')}}{{versionInfo.newVersion ? versionInfo.newVersion.version : $t('setting__update_unknown')}}
p.small(@click="handleOpenDevTools") {{$t('setting__update_current_label')}}{{versionInfo.version}}
p.small(v-if="downloadProgress" style="line-height: 1.5;")
| {{$t('setting__update_downloading')}}
.p.small
| {{ $t('setting__update_latest_label') }}{{ versionInfo.newVersion ? versionInfo.newVersion.version : $t('setting__update_unknown') }}
.p.small(@click="handleOpenDevTools") {{ $t('setting__update_current_label') }}{{ versionInfo.version }}
.p.small(v-if="downloadProgress" style="line-height: 1.5;")
| {{ $t('setting__update_downloading') }}
br
| {{$t('setting__update_progress')}}{{downloadProgress}}
| {{ $t('setting__update_progress') }}{{ downloadProgress }}
template(v-if="versionInfo.newVersion")
p(v-if="versionInfo.isLatest")
span {{$t('setting__update_latest')}}
p(v-else-if="versionInfo.status != 'downloading'")
.p(v-if="versionInfo.isLatest")
span {{ $t('setting__update_latest') }}
.p(v-else-if="versionInfo.status != 'downloading'")
span {{ $t('setting__update_new_version') }}
p
.p
base-btn.btn.gap-left(min @click="showUpdateModal") {{$t('setting__update_open_version_modal_btn')}}
p.small(v-else-if="versionInfo.status =='checking'") {{$t('setting__update_checking')}}
.p.small(v-else-if="versionInfo.status =='checking'") {{$t('setting__update_checking')}}
</template>
<script>

View File

@ -157,7 +157,7 @@ export default {
default: '',
},
},
emits: ['update:modelValue', 'submit'],
emits: ['update:model-value', 'submit'],
setup(props, { emit }) {
const themeName = ref('')
const isDark = ref(false)
@ -417,7 +417,7 @@ export default {
}
const handleCancel = () => {
handlePreview(false)
emit('update:modelValue', false)
emit('update:model-value', false)
}
//
const handleSubmit = async() => {
@ -440,7 +440,7 @@ export default {
handlePreview(false)
await saveTheme(theme)
emit('submit')
emit('update:modelValue', false)
emit('update:model-value', false)
}
//
const handleRemove = async() => {
@ -475,7 +475,7 @@ export default {
if (index > -1) themeInfo.userThemes.splice(index, 1)
handlePreview(false)
emit('submit')
emit('update:modelValue', false)
emit('update:model-value', false)
}
//
const handleSaveNew = async() => {
@ -498,7 +498,7 @@ export default {
handlePreview(false)
await saveTheme(theme)
emit('submit')
emit('update:modelValue', false)
emit('update:model-value', false)
}
return {

View File

@ -1,5 +1,5 @@
<template>
<material-modal :show="modelValue" bg-close="bg-close" teleport="#view" @close="$emit('update:modelValue', false)">
<material-modal :show="modelValue" bg-close="bg-close" teleport="#view" @close="$emit('update:model-value', false)">
<main :class="$style.main">
<h2>{{ $t('theme_selector_modal__title') }}</h2>
<div class="scroll" :class="$style.content">
@ -50,7 +50,7 @@ export default {
default: false,
},
},
emits: ['update:modelValue'],
emits: ['update:model-value'],
setup(props) {
const themeInfo = reactive({
themeLights: [],

View File

@ -1,26 +1,26 @@
<template lang="pug">
material-modal(:show="modelValue" bg-close @close="handleClose" teleport="#view")
material-modal(:show="modelValue" bg-close teleport="#view" @close="handleClose")
main(:class="$style.main")
h2 {{$t('user_api__title')}}
h2 {{ $t('user_api__title') }}
ul.scroll(v-if="apiList.length" :class="$style.content")
li(:class="[$style.listItem, {[$style.active]: appSetting['common.apiSource'] == api.id}]" v-for="(api, index) in apiList" :key="api.id")
li(v-for="(api, index) in apiList" :key="api.id" :class="[$style.listItem, {[$style.active]: appSetting['common.apiSource'] == api.id}]")
div(:class="$style.listLeft")
h3 {{api.name}}
p {{api.description}}
h3 {{ api.name }}
p {{ api.description }}
div
base-checkbox(:class="$style.checkbox" :id="`user_api_${api.id}`" v-model="api.allowShowUpdateAlert" @change="handleChangeAllowUpdateAlert(api, $event)" :label="$t('user_api__allow_show_update_alert')")
base-checkbox(:id="`user_api_${api.id}`" v-model="api.allowShowUpdateAlert" :class="$style.checkbox" :label="$t('user_api__allow_show_update_alert')" @change="handleChangeAllowUpdateAlert(api, $event)")
base-btn(:class="$style.listBtn" outline :aria-label="$t('user_api__btn_remove')" @click.stop="handleRemove(index)")
svg(version='1.1' xmlns='http://www.w3.org/2000/svg' xlink='http://www.w3.org/1999/xlink' viewBox='0 0 212.982 212.982' space='preserve' v-once)
use(xlink:href='#icon-delete')
svg(v-once version="1.1" xmlns="http://www.w3.org/2000/svg" xlink="http://www.w3.org/1999/xlink" viewBox="0 0 212.982 212.982" space="preserve")
use(xlink:href="#icon-delete")
div(v-else :class="$style.content")
div(:class="$style.noitem") {{$t('user_api__noitem')}}
div(:class="$style.noitem") {{ $t('user_api__noitem') }}
div(:class="$style.note")
p(:class="[$style.ruleLink]")
| {{$t('user_api__readme')}}
span.hover.underline(@click="handleOpenUrl('https://lyswhut.github.io/lx-music-doc/desktop/custom-source')" aria-label="https://lxmusic.toside.cn/desktop/custom-source") FAQ
p {{$t('user_api__note')}}
| {{ $t('user_api__readme') }}
span.hover.underline(aria-label="https://lxmusic.toside.cn/desktop/custom-source" @click="handleOpenUrl('https://lyswhut.github.io/lx-music-doc/desktop/custom-source')") FAQ
p {{ $t('user_api__note') }}
div(:class="$style.footer")
base-btn(:class="$style.footerBtn" @click="handleImport") {{$t('user_api__btn_import')}}
base-btn(:class="$style.footerBtn" @click="handleImport") {{ $t('user_api__btn_import') }}
//- base-btn(:class="$style.footerBtn" @click="handleExport") {{$t('user_api__btn_export')}}
</template>
@ -39,7 +39,7 @@ export default {
default: false,
},
},
emits: ['update:modelValue'],
emits: ['update:model-value'],
setup() {
return {
userApi,
@ -89,7 +89,7 @@ export default {
userApi.list = await removeUserApi([api.id])
},
handleClose() {
this.$emit('update:modelValue', false)
this.$emit('update:model-value', false)
},
handleOpenUrl(url) {
openUrl(url)

View File

@ -257,7 +257,7 @@ export default {
font-size: 12px;
margin: 25px 0 15px;
}
p {
.p {
padding: 3px 0;
line-height: 1.3;
.btn {

View File

@ -1,5 +1,5 @@
<template>
<material-modal :show="props.modelValue" teleport="#view" width="60%" bg-close @close="emit('update:modelValue', $event)" @after-enter="$refs.input.focus()">
<material-modal :show="props.modelValue" teleport="#view" width="60%" bg-close @close="emit('update:model-value', $event)" @after-enter="$refs.input.focus()">
<main :class="$style.main">
<h2>{{ $t('songlist__import_input_title') }}</h2>
<div :class="$style.inputContent">
@ -49,7 +49,7 @@ const props = defineProps({
},
})
const emit = defineEmits(['update:modelValue'])
const emit = defineEmits(['update:model-value'])
const router = useRouter()
const route = useRoute()

View File

@ -34,7 +34,7 @@
</template>
<script setup lang="ts">
import { ref, defineEmits, defineExpose } from '@common/utils/vueTools'
import { ref } from '@common/utils/vueTools'
import type { ListInfo, ListInfoItem } from '@renderer/store/songList/state'
// import LX from '@renderer/types/lx'
import { useRoute, useRouter } from '@common/utils/vueRouter'

View File

@ -23,7 +23,7 @@
<script setup lang="ts">
import { watch, shallowReactive, ref, onMounted, onBeforeUnmount, computed, reactive } from '@common/utils/vueTools'
import { setTags, getTags } from '@renderer/store/songList/action'
import { tags, TagInfoTypeItem } from '@renderer/store/songList/state'
import { tags, type TagInfoTypeItem } from '@renderer/store/songList/state'
import LX from '@renderer/types/lx'
import { useRouter, useRoute } from '@common/utils/vueRouter'
import { useI18n } from '@renderer/plugins/i18n'

View File

@ -9,5 +9,5 @@ console.log('hello download worker')
exposeWorker(Object.assign({}, common, download))
export declare type workerDownloadTypes = typeof common &
export type workerDownloadTypes = typeof common &
typeof download

View File

@ -10,6 +10,6 @@ console.log('hello main worker')
exposeWorker(Object.assign({}, common, list, music))
export declare type workerMainTypes = typeof common
export type workerMainTypes = typeof common
& typeof list
& typeof music

View File

@ -1,6 +1,6 @@
import * as Comlink from 'comlink'
export declare type MainTypes = Comlink.Remote<LX.WorkerMainTypes>
export type MainTypes = Comlink.Remote<LX.WorkerMainTypes>
export const createMainWorker = () => {
const worker: Worker = new Worker(new URL(
@ -20,7 +20,7 @@ export const createMainWorker = () => {
// // })
// }
export declare type DownloadTypes = Comlink.Remote<LX.WorkerDownloadTypes>
export type DownloadTypes = Comlink.Remote<LX.WorkerDownloadTypes>
export const createDownloadWorker = () => {
const worker: Worker = new Worker(new URL(
/* webpackChunkName: 'renderer.download.worker' */

View File

@ -1,124 +1,21 @@
{
"$schema": "https://json.schemastore.org/tsconfig",
// https://github.com/tsconfig/bases#recommended-tsconfigjson
"extends": "@tsconfig/recommended/tsconfig.json",
"compilerOptions": {
/* Visit https://aka.ms/tsconfig to read more about this file */
/* Projects */
// "incremental": true, /* Save .tsbuildinfo files to allow for incremental compilation of projects. */
// "composite": true, /* Enable constraints that allow a TypeScript project to be used with project references. */
// "tsBuildInfoFile": "./.tsbuildinfo", /* Specify the path to .tsbuildinfo incremental compilation file. */
// "disableSourceOfProjectReferenceRedirect": true, /* Disable preferring source files instead of declaration files when referencing composite projects. */
// "disableSolutionSearching": true, /* Opt a project out of multi-project reference checking when editing. */
// "disableReferencedProjectLoad": true, /* Reduce the number of projects loaded automatically by TypeScript. */
/* Language and Environment */
"target": "esnext", /* Set the JavaScript language version for emitted JavaScript and include compatible library declarations. */
// "lib": [], /* Specify a set of bundled library declaration files that describe the target runtime environment. */
// "jsx": "preserve", /* Specify what JSX code is generated. */
// "experimentalDecorators": true, /* Enable experimental support for TC39 stage 2 draft decorators. */
// "emitDecoratorMetadata": true, /* Emit design-type metadata for decorated declarations in source files. */
// "jsxFactory": "", /* Specify the JSX factory function used when targeting React JSX emit, e.g. 'React.createElement' or 'h'. */
// "jsxFragmentFactory": "", /* Specify the JSX Fragment reference used for fragments when targeting React JSX emit e.g. 'React.Fragment' or 'Fragment'. */
// "jsxImportSource": "", /* Specify module specifier used to import the JSX factory functions when using 'jsx: react-jsx*'. */
// "reactNamespace": "", /* Specify the object invoked for 'createElement'. This only applies when targeting 'react' JSX emit. */
// "noLib": true, /* Disable including any library files, including the default lib.d.ts. */
"useDefineForClassFields": true, /* Emit ECMAScript-standard-compliant class fields. */
// "moduleDetection": "auto", /* Control what method is used to detect module-format JS files. */
/* Modules */
"module": "esnext", /* Specify what module code is generated. */
// "rootDir": "./", /* Specify the root folder within your source files. */
"moduleResolution": "node", /* Specify how TypeScript looks up a file from a given module specifier. */
"target": "ESNext",
"allowJs": true,
"module": "esnext",
"resolveJsonModule": true,
"moduleResolution": "nodenext",
"outDir": "./dist",
"baseUrl": "./src", /* Specify the base directory to resolve non-relative module names. */
"paths": { /* Specify a set of entries that re-map imports to additional lookup locations. */
"@common/*": ["common/*"],
"@renderer/*": ["renderer/*"],
"@main/*": ["main/*"],
// "@lyric/*": ["renderer-lyric/*"],
"@static/*": ["static/*"],
"@/*": ["./*"],
// "paths": { /* Specify a set of entries that re-map imports to additional lookup locations. */
// "@common/*": ["common/*"],
// "@renderer/*": ["renderer/*"],
// "@main/*": ["main/*"],
// // "@lyric/*": ["renderer-lyric/*"],
// "@static/*": ["static/*"],
// "@/*": ["./*"],
// },
},
// "rootDirs": [], /* Allow multiple folders to be treated as one when resolving modules. */
// "typeRoots": [ /* Specify multiple folders that act like './node_modules/@types'. */
// "./node_modules/@types",
// "./common/types",
// // "./main/types",
// // "./renderer/types",
// // "./renderer-lyric/types",
// ],
// "types": [], /* Specify type package names to be included without being referenced in a source file. */
// "allowUmdGlobalAccess": true, /* Allow accessing UMD globals from modules. */
// "moduleSuffixes": [], /* List of file name suffixes to search when resolving a module. */
"resolveJsonModule": true, /* Enable importing .json files. */
// "noResolve": true, /* Disallow 'import's, 'require's or '<reference>'s from expanding the number of files TypeScript should add to a project. */
/* JavaScript Support */
"allowJs": true, /* Allow JavaScript files to be a part of your program. Use the 'checkJS' option to get errors from these files. */
// "checkJs": true, /* Enable error reporting in type-checked JavaScript files. */
// "maxNodeModuleJsDepth": 1, /* Specify the maximum folder depth used for checking JavaScript files from 'node_modules'. Only applicable with 'allowJs'. */
/* Emit */
// "declaration": true, /* Generate .d.ts files from TypeScript and JavaScript files in your project. */
// "declarationMap": true, /* Create sourcemaps for d.ts files. */
// "emitDeclarationOnly": true, /* Only output d.ts files and not JavaScript files. */
"sourceMap": true, /* Create source map files for emitted JavaScript files. */
// "outFile": "./", /* Specify a file that bundles all outputs into one JavaScript file. If 'declaration' is true, also designates a file that bundles all .d.ts output. */
"outDir": "./dist/", /* Specify an output folder for all emitted files. */
// "removeComments": true, /* Disable emitting comments. */
// "noEmit": true, /* Disable emitting files from a compilation. */
// "importHelpers": true, /* Allow importing helper functions from tslib once per project, instead of including them per-file. */
// "importsNotUsedAsValues": "remove", /* Specify emit/checking behavior for imports that are only used for types. */
// "downlevelIteration": true, /* Emit more compliant, but verbose and less performant JavaScript for iteration. */
// "sourceRoot": "", /* Specify the root path for debuggers to find the reference source code. */
// "mapRoot": "", /* Specify the location where debugger should locate map files instead of generated locations. */
// "inlineSourceMap": true, /* Include sourcemap files inside the emitted JavaScript. */
// "inlineSources": true, /* Include source code in the sourcemaps inside the emitted JavaScript. */
// "emitBOM": true, /* Emit a UTF-8 Byte Order Mark (BOM) in the beginning of output files. */
// "newLine": "crlf", /* Set the newline character for emitting files. */
// "stripInternal": true, /* Disable emitting declarations that have '@internal' in their JSDoc comments. */
// "noEmitHelpers": true, /* Disable generating custom helper functions like '__extends' in compiled output. */
// "noEmitOnError": true, /* Disable emitting files if any type checking errors are reported. */
// "preserveConstEnums": true, /* Disable erasing 'const enum' declarations in generated code. */
// "declarationDir": "./", /* Specify the output directory for generated declaration files. */
// "preserveValueImports": true, /* Preserve unused imported values in the JavaScript output that would otherwise be removed. */
/* Interop Constraints */
"isolatedModules": true, /* Ensure that each file can be safely transpiled without relying on other imports. */
"allowSyntheticDefaultImports": true, /* Allow 'import x from y' when a module doesn't have a default export. */
"esModuleInterop": false, /* Emit additional JavaScript to ease support for importing CommonJS modules. This enables 'allowSyntheticDefaultImports' for type compatibility. */
// "preserveSymlinks": true, /* Disable resolving symlinks to their realpath. This correlates to the same flag in node. */
"forceConsistentCasingInFileNames": false, /* Ensure that casing is correct in imports. */
/* Type Checking */
"strict": true, /* Enable all strict type-checking options. */
"noImplicitAny": true, /* Enable error reporting for expressions and declarations with an implied 'any' type. */
// "strictNullChecks": true, /* When type checking, take into account 'null' and 'undefined'. */
// "strictFunctionTypes": true, /* When assigning functions, check to ensure parameters and the return values are subtype-compatible. */
// "strictBindCallApply": true, /* Check that the arguments for 'bind', 'call', and 'apply' methods match the original function. */
// "strictPropertyInitialization": true, /* Check for class properties that are declared but not set in the constructor. */
// "noImplicitThis": true, /* Enable error reporting when 'this' is given the type 'any'. */
// "useUnknownInCatchVariables": true, /* Default catch clause variables as 'unknown' instead of 'any'. */
// "alwaysStrict": true, /* Ensure 'use strict' is always emitted. */
// "noUnusedLocals": true, /* Enable error reporting when local variables aren't read. */
// "noUnusedParameters": true, /* Raise an error when a function parameter isn't read. */
// "exactOptionalPropertyTypes": true, /* Interpret optional property types as written, rather than adding 'undefined'. */
// "noImplicitReturns": true, /* Enable error reporting for codepaths that do not explicitly return in a function. */
// "noFallthroughCasesInSwitch": true, /* Enable error reporting for fallthrough cases in switch statements. */
// "noUncheckedIndexedAccess": true, /* Add 'undefined' to a type when accessed using an index. */
// "noImplicitOverride": true, /* Ensure overriding members in derived classes are marked with an override modifier. */
// "noPropertyAccessFromIndexSignature": true, /* Enforces using indexed accessors for keys declared using an indexed type. */
// "allowUnusedLabels": true, /* Disable error reporting for unused labels. */
// "allowUnreachableCode": true, /* Disable error reporting for unreachable code. */
/* Completeness */
// "skipDefaultLibCheck": true, /* Skip type checking .d.ts files that are included with TypeScript. */
"skipLibCheck": true /* Skip type checking all .d.ts files. */
},
// "include": [
// // "**/*.ts",
// // "**/*.js",
// "**/*.vue",
// "**/*.json",
// ],
"exclude": ["node_modules", "build", "dist", ".eslintrc.js"]
}