├── doc └── img.jpg ├── babel.config.js ├── src ├── assets │ └── home.ico ├── vue.d.ts ├── shims-vue.d.ts ├── config.d.ts ├── shims-tsx.d.ts ├── main.ts ├── router │ └── index.ts ├── views │ ├── home.vue │ ├── about.vue │ └── config.vue ├── components │ ├── nologin.vue │ └── user.vue ├── main │ └── rpc.ts ├── background.ts ├── App.vue ├── function │ └── send.ts └── store │ └── index.ts ├── .prettierrc ├── .gitignore ├── .eslintrc ├── public └── index.html ├── .github └── workflows │ └── build.yml ├── tsconfig.json ├── README.md ├── LICENSE ├── vue.config.js └── package.json /doc/img.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Curtion/douyu-gift/HEAD/doc/img.jpg -------------------------------------------------------------------------------- /babel.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | presets: ['@vue/cli-plugin-babel/preset'] 3 | }; 4 | -------------------------------------------------------------------------------- /src/assets/home.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Curtion/douyu-gift/HEAD/src/assets/home.ico -------------------------------------------------------------------------------- /src/vue.d.ts: -------------------------------------------------------------------------------- 1 | declare module '*.vue' { 2 | import Vue from 'vue' 3 | export default Vue 4 | } 5 | -------------------------------------------------------------------------------- /.prettierrc: -------------------------------------------------------------------------------- 1 | { 2 | "singleQuote": true, 3 | "semi": false, 4 | "printWidth": 200, 5 | "trailingCommas": "none" 6 | } -------------------------------------------------------------------------------- /src/shims-vue.d.ts: -------------------------------------------------------------------------------- 1 | import Vue from 'vue' 2 | declare module 'vue/types/vue' { 3 | interface Vue { 4 | $db: any 5 | $auto: any 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /src/config.d.ts: -------------------------------------------------------------------------------- 1 | interface Fans { 2 | name: string 3 | intimacy: string 4 | today: string 5 | ranking: string 6 | send: string // 赠送比例 7 | roomid: string 8 | } 9 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | node_modules 3 | /dist 4 | 5 | # local env files 6 | .env.local 7 | .env.*.local 8 | 9 | # Log files 10 | npm-debug.log* 11 | yarn-debug.log* 12 | yarn-error.log* 13 | 14 | # Editor directories and files 15 | .idea 16 | .vscode 17 | *.suo 18 | *.ntvs* 19 | *.njsproj 20 | *.sln 21 | *.sw? 22 | 23 | #Electron-builder output 24 | /dist_electron -------------------------------------------------------------------------------- /src/shims-tsx.d.ts: -------------------------------------------------------------------------------- 1 | import Vue, { VNode } from 'vue' 2 | 3 | declare global { 4 | namespace JSX { 5 | // tslint:disable no-empty-interface 6 | interface Element extends VNode {} 7 | // tslint:disable no-empty-interface 8 | interface ElementClass extends Vue {} 9 | interface IntrinsicElements { 10 | [elem: string]: any 11 | } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /src/main.ts: -------------------------------------------------------------------------------- 1 | import Vue from 'vue' 2 | import App from './App.vue' 3 | import router from './router' 4 | import store from './store' 5 | import ElementUI from 'element-ui' 6 | import 'element-ui/lib/theme-chalk/index.css' 7 | const db = require('electron').remote.getGlobal('db') 8 | Vue.config.productionTip = false 9 | Vue.use(ElementUI) 10 | 11 | Vue.prototype.$db = db 12 | Vue.prototype.$auto = null 13 | const vm = new Vue({ 14 | router, 15 | store, 16 | render: h => h(App) 17 | }).$mount('#app') 18 | 19 | export default vm 20 | -------------------------------------------------------------------------------- /.eslintrc: -------------------------------------------------------------------------------- 1 | { 2 | "root": true, 3 | "env": { 4 | "node": true 5 | }, 6 | "plugins": [ 7 | "@typescript-eslint" 8 | ], 9 | "extends": [ 10 | "plugin:vue/recommended", 11 | "@vue/prettier", 12 | "@vue/typescript" 13 | ], 14 | "parserOptions": { 15 | "ecmaVersion": 6, 16 | "sourceType": "module", 17 | "ecmaFeatures": { 18 | "modules": true 19 | }, 20 | "parser": "@typescript-eslint/parser" 21 | }, 22 | "rules": { 23 | "no-console": "off", 24 | "prettier/prettier": "error", 25 | "comma-dangle": [ 26 | "error", 27 | "never" 28 | ] 29 | } 30 | } -------------------------------------------------------------------------------- /public/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 |
5 | 6 | 7 | 8 | 9 |