diff --git a/.github/workflows/create_heroku_review_app.yaml b/.github/workflows/create_heroku_review_app.yaml index 61605fb65..7e3ade03a 100644 --- a/.github/workflows/create_heroku_review_app.yaml +++ b/.github/workflows/create_heroku_review_app.yaml @@ -7,7 +7,7 @@ jobs: create-review-app: runs-on: ubuntu-latest steps: - - uses: fastruby/manage-heroku-review-app@9fa49f0320460f278c3687bc348dd0cbb18555dc # v1.3 + - uses: kqito/manage-heroku-review-app@55e434ad5ac86f21cf2f7654de1566973fbc7046 with: action: create env: diff --git a/.github/workflows/destroy_heroku_review_app.yaml b/.github/workflows/destroy_heroku_review_app.yaml index b2bf67949..cbcec744a 100644 --- a/.github/workflows/destroy_heroku_review_app.yaml +++ b/.github/workflows/destroy_heroku_review_app.yaml @@ -7,7 +7,7 @@ jobs: destroy-review-app: runs-on: ubuntu-latest steps: - - uses: fastruby/manage-heroku-review-app@9fa49f0320460f278c3687bc348dd0cbb18555dc # v1.3 + - uses: kqito/manage-heroku-review-app@55e434ad5ac86f21cf2f7654de1566973fbc7046 with: action: destroy env: diff --git a/optimize-images.js b/optimize-images.js new file mode 100644 index 000000000..865a7fe14 --- /dev/null +++ b/optimize-images.js @@ -0,0 +1,37 @@ +const sharp = require('sharp'); +const fs = require('fs'); +const path = require('path'); + +const inputDir = 'public/images'; +const outputDir = 'public/images/optimized'; + +// 出力ディレクトリが存在しない場合は作成 +if (!fs.existsSync(outputDir)) { + fs.mkdirSync(outputDir, { recursive: true }); +} + +// 画像ファイルを処理 +fs.readdirSync(inputDir) + .filter(file => file.endsWith('.jpeg')) + .forEach(async (file) => { + const inputPath = path.join(inputDir, file); + const outputPath = path.join(outputDir, file.replace('.jpeg', '.avif')); + + try { + await sharp(inputPath) + .avif({ + quality: 60, // AVIF品質を60%に設定 + effort: 6, // 圧縮の努力レベル(0-8、高いほど圧縮率が高くなる) + chromaSubsampling: '4:4:4', // 色の品質を維持 + }) + .toFile(outputPath); + + const originalSize = fs.statSync(inputPath).size; + const optimizedSize = fs.statSync(outputPath).size; + const reduction = ((originalSize - optimizedSize) / originalSize * 100).toFixed(2); + + console.log(`${file}: ${(originalSize / 1024).toFixed(2)}KB → ${(optimizedSize / 1024).toFixed(2)}KB (${reduction}% 削減)`); + } catch (error) { + console.error(`Error processing ${file}:`, error); + } + }); \ No newline at end of file diff --git a/public/images/001.avif b/public/images/001.avif new file mode 100644 index 000000000..4796af73d Binary files /dev/null and b/public/images/001.avif differ diff --git a/public/images/002.avif b/public/images/002.avif new file mode 100644 index 000000000..556780071 Binary files /dev/null and b/public/images/002.avif differ diff --git a/public/images/003.avif b/public/images/003.avif new file mode 100644 index 000000000..45c67ebaa Binary files /dev/null and b/public/images/003.avif differ diff --git a/public/images/004.avif b/public/images/004.avif new file mode 100644 index 000000000..c6ae668a9 Binary files /dev/null and b/public/images/004.avif differ diff --git a/public/images/005.avif b/public/images/005.avif new file mode 100644 index 000000000..faa5cbc17 Binary files /dev/null and b/public/images/005.avif differ diff --git a/public/images/006.avif b/public/images/006.avif new file mode 100644 index 000000000..b110a9dbd Binary files /dev/null and b/public/images/006.avif differ diff --git a/public/images/007.avif b/public/images/007.avif new file mode 100644 index 000000000..b03af8fa5 Binary files /dev/null and b/public/images/007.avif differ diff --git a/public/images/008.avif b/public/images/008.avif new file mode 100644 index 000000000..81aa9f96c Binary files /dev/null and b/public/images/008.avif differ diff --git a/public/images/009.avif b/public/images/009.avif new file mode 100644 index 000000000..55bb59a27 Binary files /dev/null and b/public/images/009.avif differ diff --git a/public/images/010.avif b/public/images/010.avif new file mode 100644 index 000000000..f17262e53 Binary files /dev/null and b/public/images/010.avif differ diff --git a/public/images/011.avif b/public/images/011.avif new file mode 100644 index 000000000..0eb246205 Binary files /dev/null and b/public/images/011.avif differ diff --git a/public/images/012.avif b/public/images/012.avif new file mode 100644 index 000000000..24d23e13c Binary files /dev/null and b/public/images/012.avif differ diff --git a/public/images/013.avif b/public/images/013.avif new file mode 100644 index 000000000..c14163fce Binary files /dev/null and b/public/images/013.avif differ diff --git a/public/images/014.avif b/public/images/014.avif new file mode 100644 index 000000000..ec3a625b8 Binary files /dev/null and b/public/images/014.avif differ diff --git a/public/images/015.avif b/public/images/015.avif new file mode 100644 index 000000000..b8f22c847 Binary files /dev/null and b/public/images/015.avif differ diff --git a/public/images/016.avif b/public/images/016.avif new file mode 100644 index 000000000..d93827a20 Binary files /dev/null and b/public/images/016.avif differ diff --git a/public/images/017.avif b/public/images/017.avif new file mode 100644 index 000000000..2040e3ff8 Binary files /dev/null and b/public/images/017.avif differ diff --git a/public/images/018.avif b/public/images/018.avif new file mode 100644 index 000000000..f6efc58be Binary files /dev/null and b/public/images/018.avif differ diff --git a/public/images/019.avif b/public/images/019.avif new file mode 100644 index 000000000..0dee43e9d Binary files /dev/null and b/public/images/019.avif differ diff --git a/public/images/020.avif b/public/images/020.avif new file mode 100644 index 000000000..f6c4f4cd7 Binary files /dev/null and b/public/images/020.avif differ diff --git a/public/images/021.avif b/public/images/021.avif new file mode 100644 index 000000000..c09b86283 Binary files /dev/null and b/public/images/021.avif differ diff --git a/public/images/022.avif b/public/images/022.avif new file mode 100644 index 000000000..597c83f46 Binary files /dev/null and b/public/images/022.avif differ diff --git a/public/images/023.avif b/public/images/023.avif new file mode 100644 index 000000000..f678e4c49 Binary files /dev/null and b/public/images/023.avif differ diff --git a/public/images/024.avif b/public/images/024.avif new file mode 100644 index 000000000..199cbd833 Binary files /dev/null and b/public/images/024.avif differ diff --git a/public/images/025.avif b/public/images/025.avif new file mode 100644 index 000000000..f68445559 Binary files /dev/null and b/public/images/025.avif differ diff --git a/public/images/026.avif b/public/images/026.avif new file mode 100644 index 000000000..71ca227c3 Binary files /dev/null and b/public/images/026.avif differ diff --git a/public/images/027.avif b/public/images/027.avif new file mode 100644 index 000000000..65b753b7c Binary files /dev/null and b/public/images/027.avif differ diff --git a/public/images/028.avif b/public/images/028.avif new file mode 100644 index 000000000..ffd1df175 Binary files /dev/null and b/public/images/028.avif differ diff --git a/public/images/029.avif b/public/images/029.avif new file mode 100644 index 000000000..35b4081f7 Binary files /dev/null and b/public/images/029.avif differ diff --git a/public/images/030.avif b/public/images/030.avif new file mode 100644 index 000000000..515c06fd9 Binary files /dev/null and b/public/images/030.avif differ diff --git a/public/images/031.avif b/public/images/031.avif new file mode 100644 index 000000000..8977542d0 Binary files /dev/null and b/public/images/031.avif differ diff --git a/public/images/032.avif b/public/images/032.avif new file mode 100644 index 000000000..ec625e3a1 Binary files /dev/null and b/public/images/032.avif differ diff --git a/public/images/033.avif b/public/images/033.avif new file mode 100644 index 000000000..ec71ab41d Binary files /dev/null and b/public/images/033.avif differ diff --git a/public/images/034.avif b/public/images/034.avif new file mode 100644 index 000000000..69ef43888 Binary files /dev/null and b/public/images/034.avif differ diff --git a/public/images/035.avif b/public/images/035.avif new file mode 100644 index 000000000..51a0c453a Binary files /dev/null and b/public/images/035.avif differ diff --git a/public/images/036.avif b/public/images/036.avif new file mode 100644 index 000000000..07d5d54e6 Binary files /dev/null and b/public/images/036.avif differ diff --git a/public/images/037.avif b/public/images/037.avif new file mode 100644 index 000000000..439c27f34 Binary files /dev/null and b/public/images/037.avif differ diff --git a/workspaces/client/src/app/createRoutes.tsx b/workspaces/client/src/app/createRoutes.tsx index a81e12561..190d280ff 100644 --- a/workspaces/client/src/app/createRoutes.tsx +++ b/workspaces/client/src/app/createRoutes.tsx @@ -13,7 +13,7 @@ export function createRoutes(store: ReturnType): RouteObject async lazy() { const { HomePage, prefetch } = await lazy( import('@wsh-2025/client/src/pages/home/components/HomePage'), - 1000, + 500, ); return { Component: HomePage, @@ -27,7 +27,7 @@ export function createRoutes(store: ReturnType): RouteObject async lazy() { const { EpisodePage, prefetch } = await lazy( import('@wsh-2025/client/src/pages/episode/components/EpisodePage'), - 1000, + 500, ); return { Component: EpisodePage, @@ -42,7 +42,7 @@ export function createRoutes(store: ReturnType): RouteObject async lazy() { const { prefetch, ProgramPage } = await lazy( import('@wsh-2025/client/src/pages/program/components/ProgramPage'), - 1000, + 500, ); return { Component: ProgramPage, @@ -57,7 +57,7 @@ export function createRoutes(store: ReturnType): RouteObject async lazy() { const { prefetch, SeriesPage } = await lazy( import('@wsh-2025/client/src/pages/series/components/SeriesPage'), - 1000, + 500, ); return { Component: SeriesPage, @@ -72,7 +72,7 @@ export function createRoutes(store: ReturnType): RouteObject async lazy() { const { prefetch, TimetablePage } = await lazy( import('@wsh-2025/client/src/pages/timetable/components/TimetablePage'), - 1000, + 500, ); return { Component: TimetablePage, @@ -87,7 +87,7 @@ export function createRoutes(store: ReturnType): RouteObject async lazy() { const { NotFoundPage, prefetch } = await lazy( import('@wsh-2025/client/src/pages/not_found/components/NotFoundPage'), - 1000, + 500, ); return { Component: NotFoundPage, diff --git a/workspaces/client/src/features/program/services/programService.ts b/workspaces/client/src/features/program/services/programService.ts index dc17a25c0..b3bdf138d 100644 --- a/workspaces/client/src/features/program/services/programService.ts +++ b/workspaces/client/src/features/program/services/programService.ts @@ -38,8 +38,8 @@ const batcher = batshit.create({ return item; }, scheduler: batshit.windowedFiniteBatchScheduler({ - maxBatchSize: 100, - windowMs: 1000, + maxBatchSize: 10, + windowMs: 100, }), }); diff --git a/workspaces/server/database.sqlite b/workspaces/server/database.sqlite index 5afaf4e28..ace2fa170 100644 Binary files a/workspaces/server/database.sqlite and b/workspaces/server/database.sqlite differ