Skip to content

Commit b0d98d0

Browse files
committed
feat(frontend)
1 parent caee84a commit b0d98d0

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

41 files changed

+331
-227
lines changed

backend/app/models/overlays.py

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,16 @@
66
class OverlayBase(SQLModel):
77
riot_id: str
88
hdev_api_key: str
9+
# text_color: str
10+
# primary_color: str
11+
# bg_color: str
12+
# progress_rank_color: str
13+
# progress_rank_bg_color: str
14+
# alpha_bg: bool
15+
# alpha_grad_bg: bool
16+
# wl_stat: bool
17+
# progress_rank: bool
18+
# last_match_points: bool
919

1020

1121
class Overlay(OverlayBase, table=True):

frontend/.editorconfig

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
[*.{js,jsx,mjs,cjs,ts,tsx,mts,cts,vue}]
2+
charset = utf-8
3+
indent_size = 2
4+
indent_style = space
5+
insert_final_newline = true
6+
trim_trailing_whitespace = true

frontend/.eslintrc.cjs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
/* eslint-env node */
2+
// eslint-disable-next-line @typescript-eslint/no-require-imports
23
require('@rushstack/eslint-patch/modern-module-resolution')
34

45
module.exports = {

frontend/.gitignore

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
# Logs
2+
logs
3+
*.log
4+
npm-debug.log*
5+
yarn-debug.log*
6+
yarn-error.log*
7+
pnpm-debug.log*
8+
lerna-debug.log*
9+
10+
node_modules
11+
.DS_Store
12+
dist
13+
dist-ssr
14+
coverage
15+
*.local
16+
17+
/cypress/videos/
18+
/cypress/screenshots/
19+
20+
# Editor directories and files
21+
.vscode/*
22+
!.vscode/extensions.json
23+
.idea
24+
*.suo
25+
*.ntvs*
26+
*.njsproj
27+
*.sln
28+
*.sw?
29+
30+
*.tsbuildinfo

frontend/.prettierrc

Lines changed: 0 additions & 14 deletions
This file was deleted.

frontend/.prettierrc.json

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
{
2+
"$schema": "https://json.schemastore.org/prettierrc",
3+
"plugins": [
4+
"@trivago/prettier-plugin-sort-imports"
5+
],
6+
"semi": false,
7+
"singleQuote": true,
8+
"printWidth": 100
9+
}

frontend/components.d.ts

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,9 @@ declare module 'vue' {
1010
ASpin: typeof import('ant-design-vue/es')['Spin']
1111
Button: typeof import('./src/components/ui/Button.vue')['default']
1212
Footer: typeof import('./src/components/Footer.vue')['default']
13+
FooterItem: typeof import('./src/components/FooterItem.vue')['default']
1314
Highlights: typeof import('./src/components/Highlights.vue')['default']
15+
HighlightsItem: typeof import('./src/components/HighlightsItem.vue')['default']
1416
IconBillCheck: typeof import('./src/components/icons/IconBillCheck.vue')['default']
1517
IconGithub: typeof import('./src/components/icons/IconGithub.vue')['default']
1618
IconHeart: typeof import('./src/components/icons/IconHeart.vue')['default']
@@ -24,8 +26,13 @@ declare module 'vue' {
2426
Input: typeof import('./src/components/ui/Input.vue')['default']
2527
LanguageSwitcher: typeof import('./src/components/ui/LanguageSwitcher.vue')['default']
2628
Overlay: typeof import('./src/components/Overlay.vue')['default']
29+
OverlayItem: typeof import('./src/components/OverlayItem.vue')['default']
2730
RouterLink: typeof import('vue-router')['RouterLink']
2831
RouterView: typeof import('vue-router')['RouterView']
2932
Switch: typeof import('./src/components/ui/Switch.vue')['default']
33+
UiButton: typeof import('./src/components/ui/uiButton.vue')['default']
34+
UiInput: typeof import('./src/components/ui/uiInput.vue')['default']
35+
UiLanguageSwitcher: typeof import('./src/components/ui/uiLanguageSwitcher.vue')['default']
36+
UiSwitch: typeof import('./src/components/ui/uiSwitch.vue')['default']
3037
}
3138
}

frontend/env.d.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
/// <reference types="vite/client" />

frontend/eslint.config.js

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
import pluginVue from 'eslint-plugin-vue'
2+
import vueTsEslintConfig from '@vue/eslint-config-typescript'
3+
import skipFormatting from '@vue/eslint-config-prettier/skip-formatting'
4+
5+
export default [
6+
{
7+
name: 'app/files-to-lint',
8+
files: ['**/*.{ts,mts,tsx,vue}'],
9+
},
10+
11+
{
12+
name: 'app/files-to-ignore',
13+
ignores: ['**/dist/**', '**/dist-ssr/**', '**/coverage/**'],
14+
},
15+
16+
...pluginVue.configs['flat/essential'],
17+
...vueTsEslintConfig(),
18+
skipFormatting,
19+
]

frontend/package.json

Lines changed: 19 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
{
22
"name": "valory",
33
"private": true,
4+
"type": "module",
45
"license": "MIT",
56
"repository": "https://github.com/haxgun/valory",
67
"author": "MAGICX <[email protected]>",
@@ -13,13 +14,17 @@
1314
},
1415
"scripts": {
1516
"dev": "vite",
16-
"build": "vue-tsc --noEmit && vite build",
17+
"build": "run-p type-check \"build-only {@}\" --",
18+
"build-only": "vite build",
1719
"preview": "vite preview",
1820
"serve": "vite build && vite preview",
19-
"lint": "eslint . --ext .vue,.js,.jsx,.cjs,.mjs --fix --ignore-path .gitignore",
21+
"lint": "eslint . --fix",
2022
"format": "prettier --write src/"
2123
},
2224
"dependencies": {
25+
"vue": "^3.5.13",
26+
"vue-router": "^4.5.0",
27+
"pinia": "^2.2.6",
2328
"@iconify/vue": "^4.1.2",
2429
"@vueuse/core": "^10.11.1",
2530
"copy-to-clipboard": "^3.3.3",
@@ -34,27 +39,31 @@
3439
"vue-template-compiler": "^2.7.16"
3540
},
3641
"devDependencies": {
42+
"@tsconfig/node22": "^22.0.0",
43+
"@types/node": "^22.9.3",
44+
"@vitejs/plugin-vue": "^5.2.1",
45+
"@vitejs/plugin-vue-jsx": "^4.1.1",
46+
"@vue/tsconfig": "^0.7.0",
3747
"@intlify/unplugin-vue-i18n": "^1.6.0",
3848
"@plugin-web-update-notification/vite": "^1.7.1",
3949
"@rushstack/eslint-patch": "^1.10.4",
4050
"@trivago/prettier-plugin-sort-imports": "^4.3.0",
41-
"@vitejs/plugin-vue": "^4.6.2",
42-
"@vue/eslint-config-prettier": "^8.0.0",
51+
"@vue/eslint-config-prettier": "^10.1.0",
52+
"@vue/eslint-config-typescript": "^14.1.3",
4353
"@vue/runtime-dom": "^3.5.13",
4454
"autoprefixer": "^10.4.20",
4555
"eslint": "^9.16.0",
4656
"eslint-config-prettier": "^9.1.0",
4757
"eslint-plugin-vue": "^9.32.0",
4858
"naive-ui": "^2.40.3",
49-
"pinia": "^2.3.0",
5059
"postcss": "^8.4.49",
5160
"prettier": "^3.4.2",
5261
"sass": "^1.82.0",
53-
"typescript": "5.6.2",
62+
"typescript": "~5.6.3",
5463
"unplugin-vue-components": "^0.25.2",
55-
"vite": "^4.5.5",
56-
"vue": "^3.5.13",
57-
"vue-router": "^4.5.0",
58-
"vue-tsc": "2.0.29"
64+
"npm-run-all2": "^7.0.1",
65+
"vite": "^6.0.1",
66+
"vite-plugin-vue-devtools": "^7.6.5",
67+
"vue-tsc": "^2.1.10"
5968
}
6069
}

0 commit comments

Comments
 (0)