Skip to content

fix(ratewise): bottom sheet 寬視口限寬置中適配(#588+#594 第一階段) - #596

Merged
s123104 merged 2 commits into
experiment/ratewise-product-2026h2from
fix/sheet-wide-viewport
Jul 5, 2026
Merged

fix(ratewise): bottom sheet 寬視口限寬置中適配(#588+#594 第一階段)#596
s123104 merged 2 commits into
experiment/ratewise-product-2026h2from
fix/sheet-wide-viewport

Conversation

@s123104

@s123104 s123104 commented Jul 5, 2026

Copy link
Copy Markdown
Contributor

摘要

Closes #588

同時完成 #594(平板適配 epic)第一階段:overlay 元件 max-width 置中。

  • BottomSheet primitive(E1)殼層加 md:max-w-screen-sm md:mx-auto md:rounded-card md:bottom-6:≥768px 視口 sheet 限寬 640px、水平置中、四邊圓角、離底 24px;手機(<768px)維持貼底全寬雙上圓角,行為零改動。
  • CalculatorKeyboard(v1/multi 計算機 sheet)尚未收斂到 primitive、自帶殼層,同步套用同一組 class,避免桌面計算機 sheet 漏修(hotfix 不順便重構殼層)。
  • 進出場位移 100%120%:寬視口 sheet 離底 24px,位移 100% 退場時會殘留 24px 可見條,120% 補足;手機視覺無感差異(已補程式碼註解防誤改回 100%)。
  • 拖曳關閉在寬視口維持可用(Framer Motion drag 支援滑鼠拖曳),backdrop / Esc 關閉不變,無取捨犧牲。
  • 連帶受益(消費端零改動):v2 趨勢 sheet、CurrencyPicker 選幣 sheet、v1/multi 計算機 sheet。

驗收證據(screenshots/,QA 暫存不入版控)

前後對照(桌面 1440×900、iPad 12.9" 橫向 1366×1024 × 計算機/趨勢/選幣):

Sheet Before After
計算機 588-before-desktop-1440x900-calculator.png(單鍵 ~240px 全寬) 588-after-desktop-1440x900-calculator.png(640px 置中)
趨勢 588-before-desktop-1440x900-trend.png(canvas 1416px) 588-after-desktop-1440x900-trend.png
選幣 588-before-ipad-1366x1024-picker.png 588-after-ipad-1366x1024-picker.png

手機迴歸:588-before-mobile-390x844-*.png588-after-mobile-390x844-*.png 逐像素視覺一致(貼底全寬不變)。

閘門

  • pnpm vitest run BottomSheet(apps/ratewise):10/10 綠(既有 a11y 測試全綠+新增寬視口樣式斷言;BottomSheet.test.tsx 單檔共 10 案)
    • 補充:初次回報的 43/43 來自三檔合跑指令 pnpm --filter @app/ratewise exec vitest run BottomSheet CalculatorKeyboard design-system-guards(Test Files 3 passed, Tests 43 passed),非單檔數字,特此更正
  • 全套 vitest:3197 passed(prerender suite 因與並行 build 資源競爭 hook 逾時,單獨重跑 69/69 綠)
  • pnpm typecheck
  • pnpm build:ratewise
  • e2e converter-v2.spec.ts:desktop+mobile 8/8 綠(sheet 互動不退步)
  • changeset(patch)+ 002 紀錄

測試:vitest(BottomSheet 10/10/全套)、typecheck、build:ratewise、e2e converter-v2 均通過

Made with Cursor

@github-actions

github-actions Bot commented Jul 5, 2026

Copy link
Copy Markdown
Contributor

⚠️ Deprecation Warning: The deny-licenses option is deprecated for possible removal in the next major release. For more information, see issue 997.

Dependency Review

✅ No vulnerabilities or license issues or OpenSSF Scorecard issues found.

Scanned Files

None

@github-actions

github-actions Bot commented Jul 5, 2026

Copy link
Copy Markdown
Contributor

✅ SEO 審計通過!所有 2026 標準驗證項目都符合要求。

  • ✅ Sitemap 2026 標準
  • ✅ Breadcrumb Schema
  • ✅ JSON-LD 結構化數據
  • ✅ 內部連結結構

s123104 pushed a commit that referenced this pull request Jul 5, 2026
- 兩處 y: '120%' 旁補繁中註解:120% 由 md:bottom-6(24px 離底)退場殘留推導,防止誤改回 100%
- PR #596 body 已更正:vitest run BottomSheet 單檔實為 10/10,43/43 為三檔合跑輸出並註明確切指令
- changeset 描述補「退場無殘留邊條」使用者可見敘述;002 新增一筆 neutral(分數變化 0,累計 +132)

測試:pnpm vitest run BottomSheet 10/10 綠(apps/ratewise 單檔)

Co-authored-by: Cursor <cursoragent@cursor.com>

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 5802ebbf97

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread docs/dev/002_development_reward_penalty_log.md Outdated
haotool and others added 2 commits July 6, 2026 03:04
- BottomSheet primitive 與 CalculatorKeyboard 殼層加 md:max-w-screen-sm 置中、四邊圓角、離底 24px
- 修 issue 588 桌面全視口拉伸,同時作為 issue 594 平板 epic 第一階段(primitive 單點修,消費端零改動)
- 進出場位移 100% 改 120%,補足寬視口離底間距避免退場殘影;手機貼底全寬行為不變
- 新增寬視口樣式斷言測試與 patch changeset

測試:vitest 全套綠(prerender 因並行 build 逾時後單獨重跑 69/69 綠)、typecheck、build:ratewise、e2e converter-v2 8/8 綠

Co-authored-by: Cursor <cursoragent@cursor.com>
- 兩處 y: '120%' 旁補繁中註解:120% 由 md:bottom-6(24px 離底)退場殘留推導,防止誤改回 100%
- PR #596 body 已更正:vitest run BottomSheet 單檔實為 10/10,43/43 為三檔合跑輸出並註明確切指令
- changeset 描述補「退場無殘留邊條」使用者可見敘述;002 新增一筆 neutral(分數變化 0,累計 +132)

測試:pnpm vitest run BottomSheet 10/10 綠(apps/ratewise 單檔)

Co-authored-by: Cursor <cursoragent@cursor.com>
@s123104
s123104 force-pushed the fix/sheet-wide-viewport branch from 5802ebb to 3605a12 Compare July 5, 2026 19:10
@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.
To continue using code reviews, you can upgrade your account or add credits to your account and enable them for code reviews in your settings.

@github-actions

github-actions Bot commented Jul 5, 2026

Copy link
Copy Markdown
Contributor

✅ SEO 審計通過!所有 2026 標準驗證項目都符合要求。

  • ✅ Sitemap 2026 標準
  • ✅ Breadcrumb Schema
  • ✅ JSON-LD 結構化數據
  • ✅ 內部連結結構

@s123104
s123104 merged commit 8c3bd47 into experiment/ratewise-product-2026h2 Jul 5, 2026
11 checks passed
@s123104
s123104 deleted the fix/sheet-wide-viewport branch July 5, 2026 19:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant