Compare commits
2 Commits
fd4204dfc5
...
4e3bdeff74
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
4e3bdeff74 | ||
|
|
aab6ffb174 |
@@ -1,80 +0,0 @@
|
|||||||
{
|
|
||||||
"env": {
|
|
||||||
"browser": true,
|
|
||||||
"es6": true,
|
|
||||||
"node": true,
|
|
||||||
"no-console": "off"
|
|
||||||
},
|
|
||||||
"extends": [
|
|
||||||
"eslint:recommended",
|
|
||||||
"plugin:@typescript-eslint/eslint-recommended",
|
|
||||||
"plugin:@typescript-eslint/recommended",
|
|
||||||
"plugin:import/recommended",
|
|
||||||
"plugin:import/electron",
|
|
||||||
"plugin:import/typescript"
|
|
||||||
],
|
|
||||||
"parser": "@typescript-eslint/parser",
|
|
||||||
"plugins": ["vue", "@typescript-eslint"],
|
|
||||||
"overrides": [
|
|
||||||
{
|
|
||||||
"files": ["*.ts", "*.tsx", "*.vue"],
|
|
||||||
"rules": {
|
|
||||||
"no-undef": "off"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"rules": {
|
|
||||||
// http://eslint.cn/docs/rules/
|
|
||||||
// https://eslint.vuejs.org/rules/
|
|
||||||
// https://typescript-eslint.io/rules/no-unused-vars/
|
|
||||||
"@typescript-eslint/ban-ts-ignore": "off",
|
|
||||||
"@typescript-eslint/explicit-function-return-type": "off",
|
|
||||||
"@typescript-eslint/no-explicit-any": "off",
|
|
||||||
"@typescript-eslint/no-var-requires": "off",
|
|
||||||
"@typescript-eslint/no-empty-function": "off",
|
|
||||||
"@typescript-eslint/no-use-before-define": "off",
|
|
||||||
"@typescript-eslint/ban-ts-comment": "off",
|
|
||||||
"@typescript-eslint/ban-types": "off",
|
|
||||||
"@typescript-eslint/no-non-null-assertion": "off",
|
|
||||||
"@typescript-eslint/explicit-module-boundary-types": "off",
|
|
||||||
"@typescript-eslint/no-redeclare": "error",
|
|
||||||
"@typescript-eslint/no-non-null-asserted-optional-chain": "off",
|
|
||||||
"@typescript-eslint/no-unused-vars": [2],
|
|
||||||
"vue/custom-event-name-casing": "off",
|
|
||||||
"vue/attributes-order": "off",
|
|
||||||
"vue/one-component-per-file": "off",
|
|
||||||
"vue/html-closing-bracket-newline": "off",
|
|
||||||
"vue/max-attributes-per-line": "off",
|
|
||||||
"vue/multiline-html-element-content-newline": "off",
|
|
||||||
"vue/singleline-html-element-content-newline": "off",
|
|
||||||
"vue/attribute-hyphenation": "off",
|
|
||||||
"vue/html-self-closing": "off",
|
|
||||||
"vue/no-multiple-template-root": "off",
|
|
||||||
"vue/require-default-prop": "off",
|
|
||||||
"vue/no-v-model-argument": "off",
|
|
||||||
"vue/no-arrow-functions-in-watch": "off",
|
|
||||||
"vue/no-template-key": "off",
|
|
||||||
"vue/no-v-html": "off",
|
|
||||||
"vue/comment-directive": "off",
|
|
||||||
"vue/no-mutating-props": "off",
|
|
||||||
"vue/no-parsing-error": "off",
|
|
||||||
"vue/no-deprecated-v-on-native-modifier": "off",
|
|
||||||
"vue/multi-word-component-names": "off",
|
|
||||||
"no-useless-escape": "off",
|
|
||||||
"no-sparse-arrays": "off",
|
|
||||||
"no-prototype-builtins": "off",
|
|
||||||
"no-constant-condition": "off",
|
|
||||||
"no-use-before-define": "off",
|
|
||||||
"no-restricted-globals": "off",
|
|
||||||
"no-restricted-syntax": "off",
|
|
||||||
"generator-star-spacing": "off",
|
|
||||||
"no-unreachable": "off",
|
|
||||||
"no-multiple-template-root": "off",
|
|
||||||
"no-unused-vars": "error",
|
|
||||||
"no-v-model-argument": "off",
|
|
||||||
"no-case-declarations": "off",
|
|
||||||
"no-console": "error",
|
|
||||||
"no-redeclare": "off",
|
|
||||||
"no-mixed-spaces-and-tabs": "off"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
7
.vscode/settings.json
vendored
Normal file
7
.vscode/settings.json
vendored
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
{
|
||||||
|
"i18n-ally.localesPaths": [
|
||||||
|
"locales"
|
||||||
|
],
|
||||||
|
"i18n-ally.displayLanguage": "zh",
|
||||||
|
"i18n-ally.keystyle": "nested"
|
||||||
|
}
|
||||||
7
env.d.ts
vendored
Normal file
7
env.d.ts
vendored
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
declare module "@store/*";
|
||||||
|
declare module "@modules/*";
|
||||||
|
declare module "@utils/*";
|
||||||
|
declare module "@assets/images/*";
|
||||||
|
declare module "@constant/*";
|
||||||
|
declare module "@remixicon/vue";
|
||||||
|
declare module "vue-router";
|
||||||
83
global.d.ts
vendored
83
global.d.ts
vendored
@@ -1,7 +1,78 @@
|
|||||||
declare module "@store/*";
|
import { IPC_EVENTS } from '@common/constants'
|
||||||
declare module "@utils/*";
|
|
||||||
declare module "@assets/images/*";
|
|
||||||
declare module "@constant/*";
|
|
||||||
declare module "@remixicon/vue";
|
|
||||||
declare module "vue-router";
|
|
||||||
|
|
||||||
|
declare global {
|
||||||
|
// 定义每个通道的参数和返回值类型
|
||||||
|
interface IPCTypings {
|
||||||
|
// 同步通信
|
||||||
|
[IPC_EVENTS.APP_MINIMIZE]: {
|
||||||
|
params: [window:number]
|
||||||
|
return: {success: boolean, error?: string}
|
||||||
|
}
|
||||||
|
[IPC_EVENTS.APP_MAXIMIZE]: {
|
||||||
|
params: [window:number]
|
||||||
|
return: {success: boolean, error?: string}
|
||||||
|
}
|
||||||
|
[IPC_EVENTS.GET_WINDOW_ID]: {
|
||||||
|
params: []
|
||||||
|
return: number
|
||||||
|
}
|
||||||
|
|
||||||
|
// 异步通信
|
||||||
|
[IPC_EVENTS.FILE_READ]: {
|
||||||
|
params: [filePath: string]
|
||||||
|
return: Promise<{success: boolean, data?: string, error?: string}>
|
||||||
|
}
|
||||||
|
[IPC_EVENTS.FILE_WRITE]: {
|
||||||
|
params: [filePath: string, content: string]
|
||||||
|
return: Promise<{success: boolean, error?: string}>
|
||||||
|
}
|
||||||
|
|
||||||
|
// 事件通信
|
||||||
|
[IPC_EVENTS.TIME_UPDATE]: {
|
||||||
|
params: [time: string]
|
||||||
|
return: void
|
||||||
|
}
|
||||||
|
[IPC_EVENTS.CUSTOM_EVENT]: {
|
||||||
|
params: [message: string]
|
||||||
|
return: void
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// 定义IPC API 接口
|
||||||
|
interface WindowApi {
|
||||||
|
invoke<T extends keyof IPCTypings>(channel: T, ...args: IPCTypings[T]['params']): IPCTypings[T]['return'],
|
||||||
|
invokeAsync<T extends keyof IPCTypings>(channel: T, ...args: IPCTypings[T]['params']): IPCTypings[T]['return'],
|
||||||
|
on<T extends keyof IPCTypings>(channel: T, callback: (...args: IPCTypings[T]['params']) => void): () => void
|
||||||
|
send<T extends keyof IPCTypings>(channel: T, ...args: IPCTypings[T]['params']): void,
|
||||||
|
getCurrentWindowId(): number,
|
||||||
|
versions: NodeJS.ProcessVersions,
|
||||||
|
external: {
|
||||||
|
open: (url: string) => void
|
||||||
|
},
|
||||||
|
window: {
|
||||||
|
minimize: () => void,
|
||||||
|
maximize: () => void,
|
||||||
|
close: () => void
|
||||||
|
},
|
||||||
|
app: {
|
||||||
|
setFrameless: (route?: string) => void
|
||||||
|
},
|
||||||
|
tabs: {
|
||||||
|
create: (url?: string) => void,
|
||||||
|
list: () => void,
|
||||||
|
navigate: (tabId: string, url: string) => void,
|
||||||
|
reload: (tabId: string) => void,
|
||||||
|
back: (tabId: string) => void,
|
||||||
|
forward: (tabId: string) => void,
|
||||||
|
switch: (tabId: string) => void,
|
||||||
|
close: (tabId: string) => void,
|
||||||
|
on: (event: 'tab-updated' | 'tab-created' | 'tab-closed' | 'tab-switched', handler: (payload: any) => void) => void
|
||||||
|
},
|
||||||
|
readFile: (filePath: string) => Promise<{success: boolean, data?: string, error?: string}>,
|
||||||
|
logToMain: (logLevel: string, message: string) => void,
|
||||||
|
}
|
||||||
|
|
||||||
|
declare interface Window {
|
||||||
|
api: WindowApi;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|||||||
3209
package-lock.json
generated
3209
package-lock.json
generated
File diff suppressed because it is too large
Load Diff
@@ -35,13 +35,9 @@
|
|||||||
"@types/electron-squirrel-startup": "^1.0.2",
|
"@types/electron-squirrel-startup": "^1.0.2",
|
||||||
"@types/lodash-es": "^4.17.12",
|
"@types/lodash-es": "^4.17.12",
|
||||||
"@typescript-eslint/parser": "^5.62.0",
|
"@typescript-eslint/parser": "^5.62.0",
|
||||||
|
"@types/node": "^24.0.8",
|
||||||
"@vitejs/plugin-vue": "^5.2.4",
|
"@vitejs/plugin-vue": "^5.2.4",
|
||||||
"autoprefixer": "^10.4.21",
|
|
||||||
"electron": "38.2.2",
|
"electron": "38.2.2",
|
||||||
"eslint": "^8.57.1",
|
|
||||||
"eslint-plugin-import": "^2.32.0",
|
|
||||||
"eslint-plugin-vue": "^10.6.0",
|
|
||||||
"sass-embedded": "^1.89.1",
|
|
||||||
"tailwindcss": "^4.1.11",
|
"tailwindcss": "^4.1.11",
|
||||||
"typescript": "^5.8.3",
|
"typescript": "^5.8.3",
|
||||||
"unplugin-auto-import": "^20.3.0",
|
"unplugin-auto-import": "^20.3.0",
|
||||||
@@ -52,7 +48,6 @@
|
|||||||
"@vueuse/core": "^14.1.0",
|
"@vueuse/core": "^14.1.0",
|
||||||
"dotenv-cli": "^11.0.0",
|
"dotenv-cli": "^11.0.0",
|
||||||
"electron-log": "^5.4.3",
|
"electron-log": "^5.4.3",
|
||||||
"axios": "^1.12.2",
|
|
||||||
"bytenode": "^1.5.7",
|
"bytenode": "^1.5.7",
|
||||||
"crypto": "^1.0.1",
|
"crypto": "^1.0.1",
|
||||||
"electron-squirrel-startup": "^1.0.1",
|
"electron-squirrel-startup": "^1.0.1",
|
||||||
|
|||||||
@@ -36,73 +36,6 @@ export const MAIN_WIN_SIZE = {
|
|||||||
} as const
|
} as const
|
||||||
|
|
||||||
|
|
||||||
// 定义每个通道的参数和返回值类型
|
|
||||||
interface IPCTypings {
|
|
||||||
// 同步通信
|
|
||||||
[IPC_EVENTS.APP_MINIMIZE]: {
|
|
||||||
params: [window:number]
|
|
||||||
return: {success: boolean, error?: string}
|
|
||||||
}
|
|
||||||
[IPC_EVENTS.APP_MAXIMIZE]: {
|
|
||||||
params: [window:number]
|
|
||||||
return: {success: boolean, error?: string}
|
|
||||||
}
|
|
||||||
[IPC_EVENTS.GET_WINDOW_ID]: {
|
|
||||||
params: []
|
|
||||||
return: number
|
|
||||||
}
|
|
||||||
|
|
||||||
// 异步通信
|
|
||||||
[IPC_EVENTS.FILE_READ]: {
|
|
||||||
params: [filePath: string]
|
|
||||||
return: Promise<{success: boolean, data?: string, error?: string}>
|
|
||||||
}
|
|
||||||
[IPC_EVENTS.FILE_WRITE]: {
|
|
||||||
params: [filePath: string, content: string]
|
|
||||||
return: Promise<{success: boolean, error?: string}>
|
|
||||||
}
|
|
||||||
|
|
||||||
// 事件通信
|
|
||||||
[IPC_EVENTS.TIME_UPDATE]: {
|
|
||||||
params: [time: string]
|
|
||||||
return: void
|
|
||||||
}
|
|
||||||
[IPC_EVENTS.CUSTOM_EVENT]: {
|
|
||||||
params: [message: string]
|
|
||||||
return: void
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// 定义IPC API 接口
|
|
||||||
export interface WindowApi {
|
|
||||||
invoke<T extends keyof IPCTypings>(channel: T, ...args: IPCTypings[T]['params']): IPCTypings[T]['return'],
|
|
||||||
invokeAsync<T extends keyof IPCTypings>(channel: T, ...args: IPCTypings[T]['params']): IPCTypings[T]['return'],
|
|
||||||
on<T extends keyof IPCTypings>(channel: T, callback: (...args: IPCTypings[T]['params']) => void): () => void
|
|
||||||
send<T extends keyof IPCTypings>(channel: T, ...args: IPCTypings[T]['params']): void,
|
|
||||||
getCurrentWindowId(): number,
|
|
||||||
versions: NodeJS.ProcessVersions,
|
|
||||||
external: {
|
|
||||||
open: (url: string) => void
|
|
||||||
},
|
|
||||||
window: {
|
|
||||||
minimize: () => void,
|
|
||||||
maximize: () => void,
|
|
||||||
close: () => void
|
|
||||||
},
|
|
||||||
app: {
|
|
||||||
setFrameless: (route?: string) => void
|
|
||||||
},
|
|
||||||
tabs: {
|
|
||||||
create: (url?: string) => void,
|
|
||||||
list: () => void,
|
|
||||||
navigate: (tabId: string, url: string) => void,
|
|
||||||
reload: (tabId: string) => void,
|
|
||||||
back: (tabId: string) => void,
|
|
||||||
forward: (tabId: string) => void,
|
|
||||||
switch: (tabId: string) => void,
|
|
||||||
close: (tabId: string) => void,
|
|
||||||
on: (event: 'tab-updated' | 'tab-created' | 'tab-closed' | 'tab-switched', handler: (payload: any) => void) => void
|
|
||||||
},
|
|
||||||
readFile: (filePath: string) => Promise<{success: boolean, data?: string, error?: string}>,
|
|
||||||
logToMain: (logLevel: string, message: string) => void,
|
|
||||||
}
|
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
import { contextBridge, ipcRenderer } from 'electron'
|
import { contextBridge, ipcRenderer } from 'electron'
|
||||||
import { IPC_EVENTS, WindowApi } from '@common/constants';
|
import { IPC_EVENTS } from '@common/constants';
|
||||||
|
|
||||||
const api: WindowApi = {
|
const api: WindowApi = {
|
||||||
versions: process.versions,
|
versions: process.versions,
|
||||||
|
|||||||
@@ -10,16 +10,13 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { defineProps } from 'vue'
|
interface TitleSectionProps {
|
||||||
|
title?: string
|
||||||
|
desc?: string
|
||||||
|
}
|
||||||
|
|
||||||
const props = defineProps({
|
withDefaults(
|
||||||
title: {
|
defineProps<TitleSectionProps>(),
|
||||||
type: String,
|
{ title: '', desc: '' }
|
||||||
default: ''
|
)
|
||||||
},
|
</script>
|
||||||
desc: {
|
|
||||||
type: String,
|
|
||||||
default: ''
|
|
||||||
}
|
|
||||||
})
|
|
||||||
</script>
|
|
||||||
|
|||||||
@@ -1,13 +0,0 @@
|
|||||||
<template>
|
|
||||||
<ul class="versions">
|
|
||||||
<li class="electron-version">Electron v{{ versions.electron }}</li>
|
|
||||||
<li class="chrome-version">Chromium v{{ versions.chrome }}</li>
|
|
||||||
<li class="node-version">Node v{{ versions.node }}</li>
|
|
||||||
</ul>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script setup lang="ts">
|
|
||||||
import { reactive } from 'vue'
|
|
||||||
|
|
||||||
const versions = reactive({ ...window.electron.process.versions })
|
|
||||||
</script>
|
|
||||||
@@ -19,6 +19,6 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup lang="ts" name="Layout">
|
<script setup lang="ts" name="Layout">
|
||||||
import TaskList from '@/components/TaskList/index.vue'
|
import TaskList from '@renderer/components/TaskList/index.vue'
|
||||||
import Menus from '@/components/Menus/index.vue'
|
import Menus from '@renderer/components/Menus/index.vue'
|
||||||
</script>
|
</script>
|
||||||
@@ -1,16 +1,16 @@
|
|||||||
import { createRouter, createWebHistory } from "vue-router";
|
import { createRouter, createWebHistory } from "vue-router";
|
||||||
import Layout from '@/layout/index.vue'
|
import Layout from '@renderer/layout/index.vue'
|
||||||
|
|
||||||
const routes = [
|
const routes = [
|
||||||
{
|
{
|
||||||
path: "/login",
|
path: "/login",
|
||||||
name: "Login",
|
name: "Login",
|
||||||
component: () => import("@/views/login/index.vue"),
|
component: () => import("@renderer/views/login/index.vue"),
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
path: "/browser",
|
path: "/browser",
|
||||||
name: "Browser",
|
name: "Browser",
|
||||||
component: () => import("@/browser/BrowserLayout.vue"),
|
component: () => import("@renderer/browser/BrowserLayout.vue"),
|
||||||
meta: { requiresAuth: true },
|
meta: { requiresAuth: true },
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@@ -19,44 +19,44 @@ const routes = [
|
|||||||
children: [
|
children: [
|
||||||
{
|
{
|
||||||
path: "home",
|
path: "home",
|
||||||
component: () => import("@/views/home/index.vue"),
|
component: () => import("@renderer/views/home/index.vue"),
|
||||||
name: "Home",
|
name: "Home",
|
||||||
meta: { requiresAuth: true },
|
meta: { requiresAuth: true },
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
path: "stock",
|
path: "stock",
|
||||||
name: "Stock",
|
name: "Stock",
|
||||||
component: () => import("@/views/stock/index.vue"),
|
component: () => import("@renderer/views/stock/index.vue"),
|
||||||
meta: { requiresAuth: true },
|
meta: { requiresAuth: true },
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
path: "rate",
|
path: "rate",
|
||||||
name: "Rate",
|
name: "Rate",
|
||||||
component: () => import("@/views/rate/index.vue"),
|
component: () => import("@renderer/views/rate/index.vue"),
|
||||||
meta: { requiresAuth: true },
|
meta: { requiresAuth: true },
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
path: "order",
|
path: "order",
|
||||||
name: "Order",
|
name: "Order",
|
||||||
component: () => import("@/views/order/index.vue"),
|
component: () => import("@renderer/views/order/index.vue"),
|
||||||
meta: { requiresAuth: true },
|
meta: { requiresAuth: true },
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
path: "more",
|
path: "more",
|
||||||
name: "More",
|
name: "More",
|
||||||
component: () => import("@/views/more/index.vue"),
|
component: () => import("@renderer/views/more/index.vue"),
|
||||||
meta: { requiresAuth: true },
|
meta: { requiresAuth: true },
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
path: "setting",
|
path: "setting",
|
||||||
name: "Setting",
|
name: "Setting",
|
||||||
component: () => import("@/views/setting/index.vue"),
|
component: () => import("@renderer/views/setting/index.vue"),
|
||||||
meta: { requiresAuth: true },
|
meta: { requiresAuth: true },
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
path: "/dashboard",
|
path: "/dashboard",
|
||||||
name: "Dashboard",
|
name: "Dashboard",
|
||||||
component: () => import("@/views/dashboard/index.vue"),
|
component: () => import("@renderer/views/dashboard/index.vue"),
|
||||||
meta: { requiresAuth: true },
|
meta: { requiresAuth: true },
|
||||||
},
|
},
|
||||||
]
|
]
|
||||||
@@ -64,7 +64,7 @@ const routes = [
|
|||||||
{
|
{
|
||||||
path: "/about",
|
path: "/about",
|
||||||
name: "About",
|
name: "About",
|
||||||
component: () => import("@/views/about/index.vue"),
|
component: () => import("@renderer/views/about/index.vue"),
|
||||||
},
|
},
|
||||||
];
|
];
|
||||||
|
|
||||||
|
|||||||
0
src/renderer/shared/index.ts
Normal file
0
src/renderer/shared/index.ts
Normal file
@@ -1,12 +0,0 @@
|
|||||||
export interface PaginationProps {
|
|
||||||
currentPage?: number
|
|
||||||
total: number
|
|
||||||
pageSize: number
|
|
||||||
pageSizes?: number[]
|
|
||||||
}
|
|
||||||
|
|
||||||
export interface EmitsProps {
|
|
||||||
(e: 'update:currentPage', value: number): void
|
|
||||||
(e: 'update:pageSize', value: string): void
|
|
||||||
(e: 'currentChange', value: number): void
|
|
||||||
}
|
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
import { PaginationProps, EmitsProps } from './PaginationProps'
|
|
||||||
|
|
||||||
export { PaginationProps, EmitsProps }
|
|
||||||
@@ -77,7 +77,7 @@
|
|||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { ref, reactive } from "vue";
|
import { ref, reactive } from "vue";
|
||||||
import { useRouter } from "vue-router";
|
import { useRouter } from "vue-router";
|
||||||
// import { login as apiLogin } from "@/renderer/api/login";
|
// import { login as apiLogin } from "@renderer/api/login";
|
||||||
import { RiUser3Fill, RiKey2Fill } from '@remixicon/vue'
|
import { RiUser3Fill, RiKey2Fill } from '@remixicon/vue'
|
||||||
|
|
||||||
const router = useRouter();
|
const router = useRouter();
|
||||||
|
|||||||
@@ -16,8 +16,8 @@
|
|||||||
|
|
||||||
<script setup lang="ts" name="RateContentSection">
|
<script setup lang="ts" name="RateContentSection">
|
||||||
import { ref } from 'vue'
|
import { ref } from 'vue'
|
||||||
import { commentList } from '@/constant/rate'
|
import { commentList } from '@renderer/constant/rate'
|
||||||
import Pagination from '@/components/Pagination/index.vue'
|
import Pagination from '@renderer/components/Pagination/index.vue'
|
||||||
import RateFilterSection from '../RateFilterSection/index.vue'
|
import RateFilterSection from '../RateFilterSection/index.vue'
|
||||||
import RateListSection from '../RateListSection/index.vue'
|
import RateListSection from '../RateListSection/index.vue'
|
||||||
|
|
||||||
|
|||||||
@@ -7,7 +7,7 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup lang="ts" name="Rate">
|
<script setup lang="ts" name="Rate">
|
||||||
import TitleSection from '@/components/TitleSection/index.vue'
|
import TitleSection from '@renderer/components/TitleSection/index.vue'
|
||||||
import RatePanelSection from './components/RatePanelSection/index.vue'
|
import RatePanelSection from './components/RatePanelSection/index.vue'
|
||||||
import RateContentSection from './components/RateContentSection/index.vue'
|
import RateContentSection from './components/RateContentSection/index.vue'
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@@ -24,6 +24,6 @@
|
|||||||
|
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { RiCheckboxCircleFill } from '@remixicon/vue'
|
import { RiCheckboxCircleFill } from '@remixicon/vue'
|
||||||
import TitleSection from '@/components/TitleSection/index.vue'
|
import TitleSection from '@renderer/components/TitleSection/index.vue'
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
@@ -31,6 +31,6 @@
|
|||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { channel } from '@constant/channel'
|
import { channel } from '@constant/channel'
|
||||||
import { RiForbidLine } from '@remixicon/vue'
|
import { RiForbidLine } from '@remixicon/vue'
|
||||||
import TitleSection from '@/components/TitleSection/index.vue'
|
import TitleSection from '@renderer/components/TitleSection/index.vue'
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
@@ -15,7 +15,7 @@
|
|||||||
|
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { ref, defineEmits } from 'vue'
|
import { ref, defineEmits } from 'vue'
|
||||||
import { systemMenus } from '@/constant/system-config'
|
import { systemMenus } from '@renderer/constant/system-config'
|
||||||
|
|
||||||
const currentId = ref(1)
|
const currentId = ref(1)
|
||||||
|
|
||||||
|
|||||||
@@ -12,5 +12,5 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import TitleSection from '@/components/TitleSection/index.vue'
|
import TitleSection from '@renderer/components/TitleSection/index.vue'
|
||||||
</script>
|
</script>
|
||||||
46
tsconfig.app.json
Normal file
46
tsconfig.app.json
Normal file
@@ -0,0 +1,46 @@
|
|||||||
|
{
|
||||||
|
"compilerOptions": {
|
||||||
|
"composite": true,
|
||||||
|
"tsBuildInfoFile": "./node_modules/.tmp/tsconfig.app.tsbuildinfo",
|
||||||
|
"target": "ES2020",
|
||||||
|
"useDefineForClassFields": true,
|
||||||
|
"module": "ESNext",
|
||||||
|
"lib": [
|
||||||
|
"ES2020",
|
||||||
|
"DOM",
|
||||||
|
"DOM.Iterable"
|
||||||
|
],
|
||||||
|
"skipLibCheck": true,
|
||||||
|
/* Bundler mode */
|
||||||
|
"moduleResolution": "Bundler",
|
||||||
|
"allowImportingTsExtensions": true,
|
||||||
|
"resolveJsonModule": true,
|
||||||
|
"isolatedModules": true,
|
||||||
|
"moduleDetection": "force",
|
||||||
|
"noEmit": true,
|
||||||
|
"jsx": "preserve",
|
||||||
|
/* Linting */
|
||||||
|
"strict": true,
|
||||||
|
"noUnusedLocals": true,
|
||||||
|
"noUnusedParameters": true,
|
||||||
|
"noFallthroughCasesInSwitch": true,
|
||||||
|
"baseUrl": "./",
|
||||||
|
"paths": {
|
||||||
|
"@renderer/*": ["src/renderer/*"],
|
||||||
|
"@api/*": ["src/renderer/api/*"],
|
||||||
|
"@shared/*": ["src/renderer/shared/*"],
|
||||||
|
"@store/*": ["src/renderer/store/*"],
|
||||||
|
"@constant/*": ["src/renderer/constant/*"],
|
||||||
|
"@utils/*": ["src/renderer/utils/*"],
|
||||||
|
"@common/*": ["src/common/*"],
|
||||||
|
"@modules/*": ["src/main/modules/*"]
|
||||||
|
},
|
||||||
|
"types": ["element-plus/global", "vue"]
|
||||||
|
},
|
||||||
|
"include": [
|
||||||
|
"forge.env.d.ts",
|
||||||
|
"src/renderer/**/*.vue",
|
||||||
|
"**/*.d.ts",
|
||||||
|
"**/*.ts",
|
||||||
|
]
|
||||||
|
}
|
||||||
16
tsconfig.config.json
Normal file
16
tsconfig.config.json
Normal file
@@ -0,0 +1,16 @@
|
|||||||
|
{
|
||||||
|
"compilerOptions": {
|
||||||
|
"composite": true,
|
||||||
|
"tsBuildInfoFile": "./node_modules/.tmp/tsconfig.config.tsbuildinfo",
|
||||||
|
"skipLibCheck": true,
|
||||||
|
"module": "ESNext",
|
||||||
|
"moduleResolution": "bundler",
|
||||||
|
"allowSyntheticDefaultImports": true,
|
||||||
|
"strict": true,
|
||||||
|
"noEmit": true
|
||||||
|
},
|
||||||
|
"include": [
|
||||||
|
"**.config.ts",
|
||||||
|
"**/*.ts",
|
||||||
|
]
|
||||||
|
}
|
||||||
@@ -1,45 +1,15 @@
|
|||||||
{
|
{
|
||||||
|
"files": [],
|
||||||
|
"references": [
|
||||||
|
{"path": "./tsconfig.app.json"},
|
||||||
|
{"path": "./tsconfig.config.json"}
|
||||||
|
],
|
||||||
"compilerOptions": {
|
"compilerOptions": {
|
||||||
"target": "ESNext",
|
"baseUrl": "./",
|
||||||
"module": "ESNext",
|
|
||||||
"lib": ["dom", "ESNext"],
|
|
||||||
"experimentalDecorators": true,
|
|
||||||
"composite": true,
|
|
||||||
"declaration": true,
|
|
||||||
"forceConsistentCasingInFileNames": true,
|
|
||||||
"allowJs": false,
|
|
||||||
"esModuleInterop": true,
|
|
||||||
"allowSyntheticDefaultImports": true,
|
|
||||||
"noImplicitAny": true,
|
|
||||||
"sourceMap": true,
|
|
||||||
"strict": true,
|
|
||||||
"baseUrl": ".",
|
|
||||||
"paths": {
|
"paths": {
|
||||||
"@/*": ["src/renderer/*"],
|
|
||||||
"@assets/*": ["src/assets/*"],
|
"@assets/*": ["src/assets/*"],
|
||||||
"@common/*": ["src/common/*"],
|
"@common/*": ["src/common/*"],
|
||||||
"@store/*": ["src/renderer/store/*"],
|
|
||||||
"@constant/*": ["src/renderer/constant/*"],
|
|
||||||
"@utils/*": ["src/renderer/utils/*"],
|
|
||||||
"@api/*": ["src/renderer/api/*"],
|
|
||||||
"@/types": ["src/renderer/types/index.ts"],
|
|
||||||
"@modules/*": ["src/main/modules/*"],
|
"@modules/*": ["src/main/modules/*"],
|
||||||
"@/shared/*": ["src/shared/*"],
|
}
|
||||||
},
|
}
|
||||||
"outDir": "dist",
|
|
||||||
"moduleResolution": "Bundler",
|
|
||||||
"resolveJsonModule": true,
|
|
||||||
"types": ["element-plus/global"]
|
|
||||||
},
|
|
||||||
"include": [
|
|
||||||
"src/**/*",
|
|
||||||
"./package.json",
|
|
||||||
"./forge.config.ts",
|
|
||||||
"forge.env.d.ts",
|
|
||||||
"**/*.ts",
|
|
||||||
"**/*.d.ts",
|
|
||||||
"vite.renderer.config.ts",
|
|
||||||
"packages/electron-chrome-context-menu",
|
|
||||||
"packages/chrome-ui"
|
|
||||||
]
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -9,8 +9,10 @@ export default defineConfig( async () => {
|
|||||||
plugins: [electronBytecode({ entry: ".vite/build/main.js", keepSource: false })],
|
plugins: [electronBytecode({ entry: ".vite/build/main.js", keepSource: false })],
|
||||||
resolve: {
|
resolve: {
|
||||||
alias: {
|
alias: {
|
||||||
"@": resolve(__dirname, "./src/main"),
|
"@main": resolve(__dirname, "./src/main"),
|
||||||
'@common': resolve(__dirname, './src/common'),
|
'@common': resolve(__dirname, './src/common'),
|
||||||
|
'@renderer': resolve(__dirname, './src/renderer'),
|
||||||
|
'@locales': resolve(__dirname, 'locales'),
|
||||||
"@modules": resolve(__dirname, "./src/main/modules"),
|
"@modules": resolve(__dirname, "./src/main/modules"),
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -5,8 +5,10 @@ import { resolve } from "path";
|
|||||||
export default defineConfig({
|
export default defineConfig({
|
||||||
resolve: {
|
resolve: {
|
||||||
alias: {
|
alias: {
|
||||||
"@": resolve(__dirname, "./src"),
|
|
||||||
'@common': resolve(__dirname, './src/common'),
|
'@common': resolve(__dirname, './src/common'),
|
||||||
|
'@main': resolve(__dirname, './src/main'),
|
||||||
|
'@renderer': resolve(__dirname, './src/renderer'),
|
||||||
|
'@locales': resolve(__dirname, 'locales'),
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -20,14 +20,14 @@ export default defineConfig(async () => {
|
|||||||
resolve: {
|
resolve: {
|
||||||
preserveSymlinks: true,
|
preserveSymlinks: true,
|
||||||
alias: {
|
alias: {
|
||||||
"@": resolve(__dirname, "./src/renderer"),
|
"@renderer": resolve(__dirname, "./src/renderer"),
|
||||||
"@api": resolve(__dirname, "./src/renderer/api"),
|
"@api": resolve(__dirname, "./src/renderer/api"),
|
||||||
"@assets": resolve(__dirname, "./src/assets"),
|
"@assets": resolve(__dirname, "./src/assets"),
|
||||||
'@common': resolve(__dirname, './src/common'),
|
'@common': resolve(__dirname, './src/common'),
|
||||||
"@constant": resolve(__dirname, "./src/renderer/constant"),
|
"@constant": resolve(__dirname, "./src/renderer/constant"),
|
||||||
"@store": resolve(__dirname, "./src/renderer/store"),
|
"@store": resolve(__dirname, "./src/renderer/store"),
|
||||||
"@utils": resolve(__dirname, "./src/renderer/utils"),
|
"@utils": resolve(__dirname, "./src/renderer/utils"),
|
||||||
"@/types": resolve(__dirname, "./src/renderer/types"),
|
"@shared": resolve(__dirname, "./src/renderer/shared"),
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user