mirror of
https://github.com/viarotel-org/escrcpy.git
synced 2025-02-17 10:58:38 +01:00
perf: ➖ Remove redundant packages
This commit is contained in:
parent
34c9393ad6
commit
f9e4a0e774
@ -1,5 +1,6 @@
|
||||
node_modules
|
||||
.github
|
||||
.gitignore
|
||||
node_modules
|
||||
dist
|
||||
dist-electron
|
||||
dist-release
|
15
.eslintrc.js
15
.eslintrc.js
@ -1,16 +1,25 @@
|
||||
module.exports = {
|
||||
extends: ['@viarotel-org'],
|
||||
extends: ['@antfu'],
|
||||
rules: {
|
||||
'antfu/top-level-function': 'off',
|
||||
'no-unused-vars': 'off',
|
||||
'eqeqeq': 'off',
|
||||
'prefer-promise-reject-errors': 'off',
|
||||
'no-new-func': 'off',
|
||||
|
||||
'antfu/top-level-function': 'off',
|
||||
'curly': 'off',
|
||||
'no-console': 'off',
|
||||
'unused-imports/no-unused-vars': 'off',
|
||||
|
||||
'import/default': 'off',
|
||||
|
||||
'vue/no-mutating-props': 'off',
|
||||
'vue/no-use-v-if-with-v-for': 'off',
|
||||
'vue/html-self-closing': 'off',
|
||||
'vue/block-order': 'off',
|
||||
'vue/no-unused-refs': 'off',
|
||||
|
||||
'n/prefer-global/process': 'off',
|
||||
|
||||
'@typescript-eslint/no-invalid-this': 'off',
|
||||
},
|
||||
}
|
||||
|
@ -1,5 +1,5 @@
|
||||
<template>
|
||||
<div class="flex flex-col absolute inset-fix-0 h-full overflow-hidden">
|
||||
<div class="flex flex-col absolute inset-0 h-full overflow-hidden">
|
||||
<div class="py-4 px-4 flex items-center flex-none">
|
||||
<a class="block" :href="escrcpyURL" target="_blank">
|
||||
<img src="@electron/resources/build/logo.png" class="h-9" alt="" />
|
||||
|
15
package.json
15
package.json
@ -13,7 +13,8 @@
|
||||
"build:mac": "vite build && electron-builder --mac",
|
||||
"build:linux": "vite build && electron-builder --linux",
|
||||
"preview": "vite preview",
|
||||
"lint": "eslint . --ext .md,.vue,.js,.jsx,.cjs,.mjs,.ts,.tsx,.cts,.mts --ignore-path .eslintignore --fix",
|
||||
"lint": "eslint . --ignore-path .eslintignore",
|
||||
"lint:fix": "eslint . --ignore-path .eslintignore --fix",
|
||||
"svgo": "svgo --folder=src/icons/svgo --output=src/icons/svg --config=src/icons/svgo.config.js",
|
||||
"postinstall": "electron-builder install-app-deps",
|
||||
"prepare": "husky install"
|
||||
@ -22,15 +23,15 @@
|
||||
"vue": "^3.3.6"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@antfu/eslint-config": "^0.43.1",
|
||||
"@devicefarmer/adbkit": "^3.2.5",
|
||||
"@electron-toolkit/preload": "^2.0.0",
|
||||
"@electron-toolkit/utils": "^2.0.1",
|
||||
"@hono/node-server": "^1.2.3",
|
||||
"@intlify/unplugin-vue-i18n": "^1.4.0",
|
||||
"@viarotel-org/design": "^0.7.0",
|
||||
"@viarotel-org/eslint-config": "^0.7.0",
|
||||
"@viarotel-org/postcss-config": "^0.7.0",
|
||||
"@viarotel-org/unocss-config": "^0.7.4",
|
||||
"@unocss/reset": "^0.58.5",
|
||||
"@unocss/transformer-directives": "^0.58.5",
|
||||
"@viarotel-org/unocss-preset-shades": "^0.8.2",
|
||||
"@vitejs/plugin-vue": "^4.4.0",
|
||||
"dayjs": "^1.11.10",
|
||||
"electron": "^27.0.3",
|
||||
@ -51,14 +52,14 @@
|
||||
"postcss-nested": "^6.0.1",
|
||||
"postcss-scss": "^4.0.9",
|
||||
"typescript": "5.2.2",
|
||||
"unocss": "^0.58.5",
|
||||
"vite": "^4.5.0",
|
||||
"vite-plugin-electron": "^0.14.1",
|
||||
"vite-plugin-electron-renderer": "^0.14.5",
|
||||
"vite-plugin-eslint": "^1.8.1",
|
||||
"vite-svg-loader": "^4.0.0",
|
||||
"vue-command": "^35.2.1",
|
||||
"vue-i18n": "^9.5.0",
|
||||
"which": "^4.0.0",
|
||||
"ws": "^8.14.2"
|
||||
}
|
||||
}
|
||||
}
|
@ -53,8 +53,7 @@ export default {
|
||||
this.loading = false
|
||||
|
||||
await mirroring
|
||||
}
|
||||
catch (error) {
|
||||
} catch (error) {
|
||||
console.warn(error)
|
||||
if (error.message) {
|
||||
this.$message.warning(error.message)
|
||||
@ -64,9 +63,7 @@ export default {
|
||||
}
|
||||
},
|
||||
onStdout() {},
|
||||
onStderr() {
|
||||
this.loading = false
|
||||
},
|
||||
onStderr() {},
|
||||
},
|
||||
}
|
||||
</script>
|
||||
|
@ -34,7 +34,7 @@ export default {
|
||||
{
|
||||
excludes: ['--video-source', '--mouse', '--keyboard'],
|
||||
isCamera: true,
|
||||
},
|
||||
}
|
||||
)}`
|
||||
|
||||
try {
|
||||
@ -50,8 +50,7 @@ export default {
|
||||
this.loading = false
|
||||
|
||||
await mirroring
|
||||
}
|
||||
catch (error) {
|
||||
} catch (error) {
|
||||
console.warn(error)
|
||||
|
||||
if (error.message) {
|
||||
@ -62,9 +61,7 @@ export default {
|
||||
}
|
||||
},
|
||||
onStdout() {},
|
||||
onStderr() {
|
||||
this.loading = false
|
||||
},
|
||||
onStderr() {},
|
||||
},
|
||||
}
|
||||
</script>
|
||||
|
@ -47,8 +47,7 @@ export default {
|
||||
this.loading = false
|
||||
|
||||
await mirroring
|
||||
}
|
||||
catch (error) {
|
||||
} catch (error) {
|
||||
console.warn(error)
|
||||
|
||||
if (error.message) {
|
||||
@ -59,9 +58,7 @@ export default {
|
||||
}
|
||||
},
|
||||
onStdout() {},
|
||||
onStderr() {
|
||||
this.loading = false
|
||||
},
|
||||
onStderr() {},
|
||||
},
|
||||
}
|
||||
</script>
|
||||
|
@ -52,8 +52,7 @@ export default {
|
||||
await recording
|
||||
|
||||
this.onRecordSuccess(savePath)
|
||||
}
|
||||
catch (error) {
|
||||
} catch (error) {
|
||||
console.warn(error)
|
||||
|
||||
if (error.message) {
|
||||
@ -62,9 +61,7 @@ export default {
|
||||
}
|
||||
},
|
||||
onStdout() {},
|
||||
onStderr() {
|
||||
this.loading = false
|
||||
},
|
||||
onStderr() {},
|
||||
getRecordPath(row) {
|
||||
const config = this.$store.preference.getData(row.id)
|
||||
const basePath = config.savePath
|
||||
@ -72,7 +69,7 @@ export default {
|
||||
|
||||
const fileName = this.$store.device.getLabel(
|
||||
row,
|
||||
({ time }) => `record-${time}.${extension}`,
|
||||
({ time }) => `record-${time}.${extension}`
|
||||
)
|
||||
|
||||
const joinValue = this.$path.join(basePath, fileName)
|
||||
@ -90,12 +87,11 @@ export default {
|
||||
cancelButtonText: this.$t('common.cancel'),
|
||||
closeOnClickModal: false,
|
||||
type: 'success',
|
||||
},
|
||||
}
|
||||
)
|
||||
|
||||
await this.$electron.ipcRenderer.invoke('show-item-in-folder', savePath)
|
||||
}
|
||||
catch (error) {
|
||||
} catch (error) {
|
||||
console.warn(error)
|
||||
}
|
||||
},
|
||||
|
@ -1,3 +1,3 @@
|
||||
import '@viarotel-org/design/styles/resets'
|
||||
import '@unocss/reset/tailwind-compat.css'
|
||||
import './desktop.css'
|
||||
import './helpers.css'
|
||||
import './helpers.css'
|
@ -1,5 +1,28 @@
|
||||
import extendConfig from '@viarotel-org/unocss-config/src/desktop/index.js'
|
||||
import { presetWind, defineConfig } from 'unocss'
|
||||
import transformerDirectives from '@unocss/transformer-directives'
|
||||
import { presetShades } from '@viarotel-org/unocss-preset-shades'
|
||||
|
||||
export default extendConfig({
|
||||
shortcuts: {},
|
||||
const presetMain = presetWind()
|
||||
|
||||
const presets = [presetMain, presetShades('#028d71')]
|
||||
|
||||
export default defineConfig({
|
||||
// @ts-ignore
|
||||
presets,
|
||||
transformers: [transformerDirectives()],
|
||||
theme: {
|
||||
boxShadow: {
|
||||
el: 'var(--el-box-shadow)',
|
||||
'el-light': 'var(--el-box-shadow-light)',
|
||||
'el-lighter': 'var(--el-box-shadow-lighter)',
|
||||
'el-dark': 'var(--el-box-shadow-dark)',
|
||||
},
|
||||
},
|
||||
shortcuts: {
|
||||
'inset-0': 'top-0 bottom-0 left-0 right-0',
|
||||
'inset-center':
|
||||
'top-1/2 left-1/2 transform -translate-y-1/2 -translate-x-1/2',
|
||||
'inset-left-center': 'left-1/2 transform -translate-x-1/2',
|
||||
'inset-top-center': 'top-1/2 transform -translate-y-1/2',
|
||||
},
|
||||
})
|
||||
|
@ -5,7 +5,6 @@ import useRenderer from 'vite-plugin-electron-renderer'
|
||||
import { notBundle } from 'vite-plugin-electron/plugin'
|
||||
|
||||
import useVue from '@vitejs/plugin-vue'
|
||||
import useEslint from 'vite-plugin-eslint'
|
||||
import useUnoCSS from 'unocss/vite'
|
||||
import useSvg from 'vite-svg-loader'
|
||||
import useI18n from '@intlify/unplugin-vue-i18n/vite'
|
||||
@ -47,7 +46,6 @@ export default params =>
|
||||
},
|
||||
},
|
||||
plugins: [
|
||||
useEslint(),
|
||||
useUnoCSS(),
|
||||
useSvg(),
|
||||
useVue(),
|
||||
|
Loading…
x
Reference in New Issue
Block a user