feat: configure responsive image sizes for optimized loading
Some checks failed
lotteryfront CI / build (push) Has been cancelled

- Added custom deviceSizes configuration in next.config.ts to support common mobile and desktop breakpoints
- Added responsive sizes attribute to hall wallet strip background image for proper srcset generation
This commit is contained in:
2026-06-26 09:30:44 +08:00
parent 4d24906d45
commit dd1155978a
2 changed files with 5 additions and 0 deletions

View File

@@ -9,6 +9,10 @@ const nextConfig: NextConfig = {
...(allowedDevOrigins.length > 0 ? { allowedDevOrigins } : {}),
reactCompiler: true,
images: {
deviceSizes: [640, 750, 828, 1080, 1200, 1920],
},
// 非 CSP 安全头CSP 由 middleware 按后台接入站点白名单动态生成。
async headers() {
return [

View File

@@ -91,6 +91,7 @@ export function HallWalletStrip() {
src="/entry/image5.png"
alt=""
fill
sizes="(max-width: 768px) 100vw, 768px"
className="pointer-events-none object-cover object-center"
aria-hidden
/>