feat: implement initial language resolution for SSR and local storage support
- Added a function to determine the initial language based on server-side rendering and local storage. - Updated i18n initialization to use the resolved initial language instead of the default.
This commit is contained in:
9
src/lib/player-viewport.ts
Normal file
9
src/lib/player-viewport.ts
Normal file
@@ -0,0 +1,9 @@
|
||||
/** H5 玩家端逻辑宽度(px),桌面浏览器居中展示为「手机画布」 */
|
||||
export const PLAYER_VIEWPORT_MAX_PX = 480;
|
||||
|
||||
/** 内容列:全宽但不超过手机逻辑宽度,水平居中 */
|
||||
export const playerViewportColumnClass = "mx-auto w-full max-w-[480px]" as const;
|
||||
|
||||
/** 贴底/贴顶固定栏:与内容列同宽并居中(桌面不铺满整屏) */
|
||||
export const playerViewportFixedBarClass =
|
||||
"fixed left-1/2 z-50 w-full max-w-[480px] -translate-x-1/2" as const;
|
||||
Reference in New Issue
Block a user