Skip to content

Commit 6eee501

Browse files
committed
Merge branch 'main' into feat/algolia-search
2 parents 1c9df3b + 8edb91b commit 6eee501

File tree

563 files changed

+136176
-10714
lines changed

Some content is hidden

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

563 files changed

+136176
-10714
lines changed

.env.example

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
#secure password, can use openssl rand -hex 32
2+
NUXT_SESSION_PASSWORD=""

.gitattributes

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
* text=auto eol=lf

.github/workflows/autofix.yml

Lines changed: 22 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -5,38 +5,43 @@ on:
55
pull_request:
66
branches:
77
- main
8+
merge_group:
9+
branches:
10+
- main
811

912
permissions:
1013
contents: read
1114

1215
jobs:
1316
code:
14-
runs-on: ubuntu-latest
17+
name: 🤖 Autofix code
18+
runs-on: ubuntu-24.04-arm
1519

1620
steps:
17-
- uses: actions/checkout@v6
18-
- run: corepack enable
19-
- uses: actions/setup-node@v6
21+
- uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
22+
23+
- uses: actions/setup-node@6044e13b5dc448c55e2357c09f80417699197238 # v6.2.0
2024
with:
2125
node-version: lts/*
22-
cache: 'pnpm'
26+
27+
- uses: pnpm/action-setup@1e1c8eafbd745f64b1ef30a7d7ed7965034c486c # 1e1c8eafbd745f64b1ef30a7d7ed7965034c486c
28+
name: 🟧 Install pnpm
29+
with:
30+
cache: true
2331

2432
- name: 📦 Install dependencies
2533
run: pnpm install
2634

27-
- name: 📦 Install browsers
28-
run: pnpm playwright install
35+
- name: 🎨 Check for non-RTL CSS classes
36+
run: pnpm rtl:check
2937

30-
- name: 🔠 Fix lint errors
31-
run: pnpm lint:fix
32-
33-
- name: 🧪 Update unit test snapshots
34-
run: pnpm test:unit -u
38+
- name: 🌐 Compare translations
39+
run: pnpm i18n:check
3540

36-
- name: 🏃 Update component test snapshots
37-
run: pnpm test:nuxt -u
41+
- name: 🌍 Update lunaria data
42+
run: pnpm build:lunaria
3843

39-
- name: 🖥️ Update browser test snapshots
40-
run: pnpm test:browser --update-snapshots
44+
- name: 🔠 Fix lint errors
45+
run: pnpm lint:fix
4146

42-
- uses: autofix-ci/action@635ffb0c9798bd160680f18fd73371e355b85f27
47+
- uses: autofix-ci/action@635ffb0c9798bd160680f18fd73371e355b85f27 # 635ffb0c9798bd160680f18fd73371e355b85f27

.github/workflows/ci.yml

Lines changed: 174 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -7,91 +7,231 @@ on:
77
push:
88
branches:
99
- main
10+
merge_group:
11+
branches:
12+
- main
13+
14+
# cancel in-progress runs on new commits to same PR (gitub.event.number)
15+
concurrency:
16+
group: ${{ github.workflow }}-${{ github.event.number || github.sha }}
17+
cancel-in-progress: true
1018

1119
permissions:
1220
contents: read
1321

1422
jobs:
1523
lint:
16-
runs-on: ubuntu-latest
24+
name: 🔠 Lint project
25+
runs-on: ubuntu-24.04-arm
1726

1827
steps:
19-
- uses: actions/checkout@v6
20-
- run: corepack enable
21-
- uses: actions/setup-node@v6
28+
- uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
29+
30+
- uses: actions/setup-node@6044e13b5dc448c55e2357c09f80417699197238 # v6.2.0
2231
with:
2332
node-version: lts/*
24-
cache: pnpm
2533

26-
- name: 📦 Install dependencies
27-
run: pnpm install
34+
- uses: pnpm/action-setup@1e1c8eafbd745f64b1ef30a7d7ed7965034c486c # 1e1c8eafbd745f64b1ef30a7d7ed7965034c486c
35+
name: 🟧 Install pnpm
36+
with:
37+
cache: true
38+
39+
- name: 📦 Install dependencies (root only, no scripts)
40+
run: pnpm install --filter . --ignore-scripts
2841

2942
- name: 🔠 Lint project
3043
run: pnpm lint
3144

45+
types:
46+
name: 💪 Type check
47+
runs-on: ubuntu-24.04-arm
48+
49+
steps:
50+
- uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
51+
52+
- uses: actions/setup-node@6044e13b5dc448c55e2357c09f80417699197238 # v6.2.0
53+
with:
54+
node-version: lts/*
55+
56+
- uses: pnpm/action-setup@1e1c8eafbd745f64b1ef30a7d7ed7965034c486c # 1e1c8eafbd745f64b1ef30a7d7ed7965034c486c
57+
name: 🟧 Install pnpm
58+
with:
59+
cache: true
60+
61+
- name: 📦 Install dependencies
62+
run: pnpm install
63+
64+
- name: 💪 Type check
65+
run: pnpm test:types
66+
67+
unit:
68+
name: 🧪 Unit tests
69+
runs-on: ubuntu-24.04-arm
70+
71+
steps:
72+
- uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
73+
74+
- uses: actions/setup-node@6044e13b5dc448c55e2357c09f80417699197238 # v6.2.0
75+
with:
76+
node-version: lts/*
77+
78+
- uses: pnpm/action-setup@1e1c8eafbd745f64b1ef30a7d7ed7965034c486c # 1e1c8eafbd745f64b1ef30a7d7ed7965034c486c
79+
name: 🟧 Install pnpm
80+
with:
81+
cache: true
82+
83+
- name: 📦 Install dependencies
84+
run: pnpm install
85+
86+
- name: 🧪 Unit tests
87+
run: pnpm test:unit run --coverage --reporter=junit --outputFile=test-report.junit.xml
88+
89+
- name: ⬆︎ Upload test results to Codecov
90+
if: ${{ !cancelled() }}
91+
uses: codecov/test-results-action@0fa95f0e1eeaafde2c782583b36b28ad0d8c77d3 # v1
92+
with:
93+
token: ${{ secrets.CODECOV_TOKEN }}
94+
3295
test:
33-
runs-on: ubuntu-latest
96+
name: 🧪 Component tests
97+
runs-on: ubuntu-24.04-arm
3498

3599
steps:
36-
- uses: actions/checkout@v6
37-
- run: corepack enable
38-
- uses: actions/setup-node@v6
100+
- uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
101+
102+
- uses: actions/setup-node@6044e13b5dc448c55e2357c09f80417699197238 # v6.2.0
39103
with:
40104
node-version: lts/*
41-
cache: pnpm
105+
106+
- uses: pnpm/action-setup@1e1c8eafbd745f64b1ef30a7d7ed7965034c486c # 1e1c8eafbd745f64b1ef30a7d7ed7965034c486c
107+
name: 🟧 Install pnpm
108+
with:
109+
cache: true
42110

43111
- name: 📦 Install dependencies
44112
run: pnpm install
45113

46114
- name: 🌐 Install browser
47-
run: pnpm playwright install
115+
run: pnpm playwright install chromium-headless-shell
48116

49-
- name: 💪 Type check
50-
run: pnpm test:types
117+
- name: 🧪 Component tests
118+
run: pnpm test:nuxt run --coverage --reporter=junit --outputFile=test-report.junit.xml
51119

52-
- name: 🧪 Unit test
53-
run: pnpm test:unit
120+
- name: ⬆︎ Upload coverage reports to Codecov
121+
uses: codecov/codecov-action@671740ac38dd9b0130fbe1cec585b89eea48d3de # v5
122+
with:
123+
report_type: test_results
124+
env:
125+
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
54126

55-
- name: 🏃 Component tests
56-
run: pnpm test:nuxt
127+
- name: ⬆︎ Upload coverage reports to Codecov
128+
uses: codecov/codecov-action@671740ac38dd9b0130fbe1cec585b89eea48d3de # v5
129+
env:
130+
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
57131

58132
browser:
59-
runs-on: ubuntu-latest
133+
name: 🖥️ Browser tests
134+
runs-on: ubuntu-24.04-arm
60135
container:
61-
image: mcr.microsoft.com/playwright:v1.57.0-noble
136+
image: mcr.microsoft.com/playwright:v1.58.0-noble
62137

63138
steps:
64-
- uses: actions/checkout@v6
65-
- run: corepack enable
66-
- uses: actions/setup-node@v6
139+
- uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
140+
141+
- uses: actions/setup-node@6044e13b5dc448c55e2357c09f80417699197238 # v6.2.0
67142
with:
68143
node-version: lts/*
69-
cache: pnpm
144+
145+
- uses: pnpm/action-setup@1e1c8eafbd745f64b1ef30a7d7ed7965034c486c # 1e1c8eafbd745f64b1ef30a7d7ed7965034c486c
146+
name: 🟧 Install pnpm
147+
with:
148+
cache: true
70149

71150
- name: 📦 Install dependencies
72151
run: pnpm install
73152

153+
- name: 🏗️ Build project
154+
run: pnpm build:test
155+
env:
156+
VALIDATE_HTML: true
157+
74158
- name: 🖥️ Test project (browser)
75-
run: pnpm test:browser
159+
run: pnpm test:browser:prebuilt
76160

77161
a11y:
78-
runs-on: ubuntu-latest
162+
name: ♿ Accessibility audit
163+
runs-on: ubuntu-latest # See https://github.com/GoogleChrome/lighthouse/discussions/16834
164+
strategy:
165+
matrix:
166+
mode: [dark, light]
79167

80168
steps:
81-
- uses: actions/checkout@v6
82-
- run: corepack enable
83-
- uses: actions/setup-node@v6
169+
- uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
170+
171+
- uses: actions/setup-node@6044e13b5dc448c55e2357c09f80417699197238 # v6.2.0
84172
with:
85173
node-version: lts/*
86-
cache: pnpm
174+
175+
- uses: pnpm/action-setup@1e1c8eafbd745f64b1ef30a7d7ed7965034c486c # 1e1c8eafbd745f64b1ef30a7d7ed7965034c486c
176+
name: 🟧 Install pnpm
177+
with:
178+
cache: true
87179

88180
- name: 📦 Install dependencies
89181
run: pnpm install
90182

91183
- name: 🏗️ Build project
92-
run: pnpm build
184+
run: pnpm build:test
93185

94-
- name: ♿ Accessibility audit (Lighthouse)
95-
run: pnpx @lhci/cli autorun
186+
- name: ♿ Accessibility audit (Lighthouse - ${{ matrix.mode }} mode)
187+
run: pnpm test:a11y:prebuilt
96188
env:
97189
LHCI_GITHUB_APP_TOKEN: ${{ secrets.LHCI_GITHUB_APP_TOKEN }}
190+
LIGHTHOUSE_COLOR_MODE: ${{ matrix.mode }}
191+
192+
knip:
193+
name: 🧹 Unused code check
194+
runs-on: ubuntu-24.04-arm
195+
196+
steps:
197+
- uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
198+
199+
- uses: actions/setup-node@6044e13b5dc448c55e2357c09f80417699197238 # v6.2.0
200+
with:
201+
node-version: lts/*
202+
203+
- uses: pnpm/action-setup@1e1c8eafbd745f64b1ef30a7d7ed7965034c486c # 1e1c8eafbd745f64b1ef30a7d7ed7965034c486c
204+
name: 🟧 Install pnpm
205+
with:
206+
cache: true
207+
208+
- name: 📦 Install dependencies
209+
run: pnpm install
210+
211+
- name: 🧹 Check for unused code
212+
run: pnpm knip
213+
214+
- name: 🧹 Check for unused production code
215+
run: pnpm knip --production
216+
217+
i18n:
218+
name: 🌐 i18n validation
219+
runs-on: ubuntu-24.04-arm
220+
221+
steps:
222+
- uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
223+
224+
- uses: actions/setup-node@6044e13b5dc448c55e2357c09f80417699197238 # v6.2.0
225+
with:
226+
node-version: lts/*
227+
228+
- uses: pnpm/action-setup@1e1c8eafbd745f64b1ef30a7d7ed7965034c486c # 1e1c8eafbd745f64b1ef30a7d7ed7965034c486c
229+
name: 🟧 Install pnpm
230+
with:
231+
cache: true
232+
233+
- name: 📦 Install dependencies (root only, no scripts)
234+
run: pnpm install --filter . --ignore-scripts
235+
236+
- name: 🌐 Check for missing or dynamic i18n keys
237+
run: pnpm i18n:report

.github/workflows/lunaria.yml

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
name: lunaria
2+
3+
on:
4+
# Trigger the workflow every time a pull request is opened or synchronized at the target `main` branch
5+
pull_request_target:
6+
types: [opened, synchronize]
7+
8+
# Automatically cancel in-progress actions on the same branch
9+
concurrency:
10+
group: ${{ github.workflow }}-${{ github.event_name == 'pull_request_target' && github.head_ref || github.ref }}
11+
cancel-in-progress: true
12+
13+
# Allow this job to clone the repository and comment on the pull request
14+
permissions:
15+
contents: read
16+
pull-requests: write
17+
18+
jobs:
19+
lunaria-overview:
20+
name: 🌝 Generate Lunaria Overview
21+
runs-on: ubuntu-24.04-arm
22+
23+
steps:
24+
- name: Checkout
25+
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
26+
with:
27+
# Necessary for Lunaria to work properly
28+
# Makes the action clone the entire git history
29+
fetch-depth: 0
30+
31+
- uses: actions/setup-node@6044e13b5dc448c55e2357c09f80417699197238 # v6.2.0
32+
with:
33+
node-version: lts/*
34+
35+
- uses: pnpm/action-setup@1e1c8eafbd745f64b1ef30a7d7ed7965034c486c # 1e1c8eafbd745f64b1ef30a7d7ed7965034c486c
36+
name: 🟧 Install pnpm
37+
with:
38+
cache: true
39+
40+
- name: 📦 Install dependencies
41+
run: pnpm install
42+
43+
- name: Generate Lunaria Overview
44+
uses: lunariajs/action@4911ad0736d1e3b20af4cb70f5079aea2327ed8e # v1-prerelease

0 commit comments

Comments
 (0)