Skip to content

Commit 4d3ad8a

Browse files
committed
Refactor and update various components and pages for improved consistency and functionality
- Updated imports to use type imports where applicable in multiple files. - Added missing commas in metadata objects for consistency. - Improved error handling in Discord API fetch functions. - Enhanced accessibility by adding titles to SVG icons. - Refactored button components for better readability and functionality. - Updated CSS styles for consistency and clarity. - Added GitHub Actions workflows for CI and reviewdog integration. - Introduced biome configuration for linting and formatting.
1 parent 9b4267a commit 4d3ad8a

36 files changed

Lines changed: 374 additions & 926 deletions

.github/workflows/CI.yaml

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
name: Code quality
2+
on:
3+
push:
4+
paths-ignore:
5+
- "*.md"
6+
- ".vscode/**"
7+
jobs:
8+
quality:
9+
runs-on: ubuntu-latest
10+
permissions:
11+
contents: read
12+
steps:
13+
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6
14+
with:
15+
persist-credentials: false
16+
- name: Set up Bun
17+
uses: oven-sh/setup-bun@3d267786b128fe76c2f16a390aa2448b815359f3 # v2
18+
with:
19+
bun-version: latest
20+
- name: Setup Biome
21+
uses: biomejs/setup-biome@29711cbb52afee00eb13aeb30636592f9edc0088 # v2
22+
with:
23+
version: latest
24+
- name: Run Biome
25+
run: biome ci .

.github/workflows/Tagger.yaml

Lines changed: 0 additions & 58 deletions
This file was deleted.
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,5 @@
1-
name: CI
1+
name: reviewdog
22
on:
3-
push:
4-
paths-ignore:
5-
- "*.md"
6-
- ".vscode/**"
73
pull_request:
84
types:
95
- opened
@@ -14,31 +10,24 @@ on:
1410
- "*.md"
1511
- ".vscode/**"
1612
jobs:
17-
eslint:
18-
runs-on: ubuntu-24.04
13+
biome:
14+
name: runner / Biome
15+
runs-on: ubuntu-latest
1916
timeout-minutes: 3
2017
permissions:
2118
contents: read
2219
pull-requests: write
23-
strategy:
24-
matrix:
25-
env: [src]
2620
if: github.event.pull_request.draft == false
2721
steps:
28-
- uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6
22+
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6
2923
- name: Set up Bun
3024
uses: oven-sh/setup-bun@3d267786b128fe76c2f16a390aa2448b815359f3 # v2
3125
with:
3226
bun-version: latest
3327
- name: Install dependencies
3428
run: bun install
35-
- uses: reviewdog/action-setup@d8a7baabd7f3e8544ee4dbde3ee41d0011c3a93f # v1
36-
with:
37-
reviewdog_version: latest
38-
- name: Run reviewdog with eslint
39-
uses: reviewdog/action-eslint@556a3fdaf8b4201d4d74d406013386aa4f7dab96 # v1
29+
- name: Run reviewdog with biome
30+
uses: mongolyy/reviewdog-action-biome@eaba62a1e048fb13e4ff5e017ff8c15d00b2c1a2 # v2
4031
with:
4132
github_token: ${{ secrets.GITHUB_TOKEN }}
42-
filter_mode: diff_context
43-
fail_level: error
44-
workdir: ${{ matrix.env }}
33+
reporter: github-pr-review

.vscode/settings.json

Lines changed: 18 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,19 @@
11
{
2-
"typescript.tsdk": "node_modules/typescript/lib"
3-
}
2+
"js/ts.tsdk.path": "node_modules/typescript/lib",
3+
4+
// TypeScriptファイル用の設定
5+
"[typescript]": {
6+
"editor.defaultFormatter": "biomejs.biome",
7+
"editor.formatOnSave": true
8+
},
9+
// TypeScript React (TSX) ファイル用の設定
10+
"[typescriptreact]": {
11+
"editor.defaultFormatter": "biomejs.biome",
12+
"editor.formatOnSave": true
13+
},
14+
// JS/TS全般に対する設定
15+
"editor.defaultFormatter": "biomejs.biome",
16+
"[jsonc]": {
17+
"editor.defaultFormatter": "esbenp.prettier-vscode"
18+
}
19+
}

biome.json

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
{
2+
"$schema": "https://biomejs.dev/schemas/2.4.5/schema.json",
3+
"vcs": {
4+
"enabled": true,
5+
"clientKind": "git",
6+
"useIgnoreFile": true
7+
},
8+
"files": {
9+
"ignoreUnknown": true,
10+
"includes": ["**", "!node_modules", "!.next", "!dist", "!build"]
11+
},
12+
"formatter": {
13+
"enabled": true,
14+
"indentStyle": "space",
15+
"indentWidth": 2
16+
},
17+
"linter": {
18+
"enabled": true,
19+
"rules": {
20+
"recommended": true,
21+
"suspicious": {
22+
"noUnknownAtRules": "off"
23+
}
24+
},
25+
"domains": {
26+
"next": "recommended",
27+
"react": "recommended"
28+
}
29+
},
30+
"assist": {
31+
"actions": {
32+
"source": {
33+
"organizeImports": "on"
34+
}
35+
}
36+
},
37+
"css": {
38+
"parser": {
39+
"tailwindDirectives": true
40+
}
41+
}
42+
}

0 commit comments

Comments
 (0)