Add deferred worksheet font color edits - #17
Merged
shps951023 merged 9 commits intoSep 14, 2026
Merged
shps951023 merged 9 commits into
shps951023 merged 9 commits into
Conversation
為 MiniExcel Browser Lab(https://mini-software.github.io/MiniExcel-Rust/)增強搜尋引擎最佳化(SEO)與社群媒體(Facebook / Twitter)分享卡片體驗: 1. 新增 Open Graph (og:*) 標籤: - og:type: website - og:url: 設定頁面標準網址(https://mini-software.github.io/MiniExcel-Rust/) - og:title: MiniExcel Browser Lab - og:description: 描述 MiniExcel 本地串流 Rust、WebAssembly 與 RAG 匯出能力 - og:image / og:image:secure_url: 包含完整 HTTPS 絕對路徑的社群預覽圖片 - og:image:type: image/png - og:image:width / og:image:height: 1200 x 630(符合 Facebook 建議的 1.91:1 最佳黃金比例) - og:image:alt: 說明預覽圖所呈現的試算表預覽與分析介面 - og:site_name 與 og:locale: 設定站點名稱為 MiniExcel 與 en_US 語系 2. 新增 Twitter Card (twitter:*) 標籤: - twitter:card: summary_large_image 大圖卡片格式 - twitter:url、twitter:title、twitter:description - twitter:image 與 twitter:image:alt 3. 新增標準 SEO 標籤: - link[rel="canonical"]: 指向標準部署網址,避免重複內容分散權重 - meta[name="robots"]: 允許搜尋引擎檢索與追蹤(index, follow) 4. 加入 Facebook 最佳化預覽截圖 (web-demo/public/og-image.png): - 透過 Chrome DevTools 連線至瀏覽器中實際運行的 MiniExcel Browser Lab 頁面 - 調整 Viewport 解析度為 1200x630,捕捉完整的產品品牌、控制面板與試算表數據網格 - 圖片大小約 92 KB,兼顧高清畫質與社群爬蟲快速載入需求
Prevent the Browser Lab RAG export controls from overflowing by allowing the export button row to wrap and giving buttons a 140px flex basis. Add Playwright coverage that verifies all five RAG export buttons wrap without clipping or horizontal overflow on desktop and mobile.
* feat(web-demo): 新增 GitHub 儲存庫連結圖示 在 Browser Lab 頂端列最右側新增 GitHub 圖示,讓使用者能直接回到 MiniExcel.Rust 上游儲存庫,並維持桌面版與行動版的頂端列版面。 實作內容: - 使用原生 anchor 元素連結至 https://github.com/mini-software/MiniExcel-Rust。 - 以內嵌 SVG 呈現 GitHub 標誌,並以 aria-label 提供可存取名稱。 - 使用 target="_blank" 與 rel="noopener noreferrer" 開啟外部儲存庫。 - 新增一般、滑鼠移入與鍵盤 focus 狀態的圖示按鈕樣式。 - 將 GitHub 連結加入 Browser Lab 桌面版與行動版 E2E 覆蓋範圍。 影響範圍: - web-demo/public/index.html:新增右上角 GitHub 連結與可存取的 SVG 圖示。 - web-demo/public/styles.css:新增 GitHub 圖示連結的尺寸、色彩與互動樣式。 - web-demo/tests/browser.spec.mjs:驗證 GitHub 連結的可見名稱與目標網址。 驗證項目: - npm ci - npm run build - npm run test:e2e:14 項通過、4 項依既有桌面/行動版篩選條件跳過。 - 桌面版與 Pixel 7 行動版截圖檢查:圖示位於右上角,且沒有橫向溢位。 * Refactor GitHub link expectation in tests Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> --------- Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Hide the secondary runtime badge below 360px so the implementation switch and GitHub link remain visible without horizontal scrolling. Add a 320px Playwright project to prevent regressions at the minimum supported viewport.
Browser Lab 左側控制欄固定為 380px 且無法收合,使用者在小螢幕或需要 更大預覽空間時無法自行調整版面。本次新增圖示切換鈕與可拖曳分隔線, 並將版面狀態保存於 localStorage,重新載入後可完整還原。 實作內容: - 在預覽面板標題列左側新增面板圖示切換鈕,可收合或展開左側控制欄。 - 於控制欄與預覽面板之間新增 role="separator" 分隔線,可用滑鼠拖曳調整寬度。 - 分隔線支援雙擊還原預設 380px,以及鍵盤 ArrowLeft/ArrowRight/Home/End 調整。 - 寬度限制在 260px 至 720px,且不超過工作區寬度的 60%,確保預覽面板保有可用寬度。 - 以 miniexcel.browser-lab.layout/v1 鍵保存寬度與收合狀態,載入時還原並依目前視窗夾限。 - 收合以 hidden 屬性搭配網格樣式實作;900px 以下的堆疊版面隱藏分隔線並維持單欄滿版。 - 拖曳期間於 body 加入 is-resizing 狀態,避免選取文字並維持 col-resize 游標。 - localStorage 無法使用或內容無效時回退為展開的預設版面,不影響既有操作。 影響範圍: - web-demo/public/index.html:新增控制欄切換鈕、分隔線與工作區 id。 - web-demo/public/styles.css:新增三欄網格、分隔線、切換鈕與收合狀態樣式。 - web-demo/public/app.js:新增版面狀態、localStorage 存取、拖曳與鍵盤調整邏輯。 - web-demo/tests/browser.spec.mjs:新增桌面版切換、拖曳、鍵盤、無效儲存值回退與行動版無溢位測試。 - docs/compatibility.md、docs/compatibility.zh-CN.md:更新 Browser Lab Playwright 覆蓋範圍說明。 驗證項目: - npm ci:通過。 - npm run build:通過。 - npm run test:e2e:28 項通過、20 項依既有桌面/行動版篩選條件跳過。 - 版面量測:1280px、901px、412px、320px 皆無橫向溢位;收合後預覽面板佔滿工作區。 - 主控台檢查:拖曳、鍵盤調整、切換與重新載入皆沒有警告或錯誤。
PR #15 的自動化審查指出兩個問題:readStoredLayout 逐欄位寬鬆驗證,資料 半殘時仍會套用無效欄位;拖曳期間的 is-resizing 只設在 body,子元素自身的 cursor: pointer 會蓋掉 col-resize。兩者皆已修正並補上可重現的回歸測試。 修正內容: - readStoredLayout 改為整筆記錄驗證:非物件、陣列、寬度非有限數值或超出 260px~720px、collapsed 非 boolean 時,一律回退為展開的 380px 預設版面。 - 無效資料不再只靠渲染階段夾限,避免以 260px 或維持收合的狀態殘留。 - is-resizing 狀態改為同時套用到 body 與其所有子元素,並以 !important 蓋過 按鈕等元素既有的 cursor: pointer,拖曳期間一律維持 col-resize 並禁止選取文字。 - 測試新增 9 種無效儲存值(型別錯誤、0、900、null、缺欄位、陣列、字串)的 回退驗證,並確認回退後的 380px 會正確寫回儲存內容。 - 測試新增拖曳游標契約驗證:body 與 cursor: pointer 子元素的 computed cursor 皆為 col-resize、user-select 為 none,指標放開後恢復原本的 pointer。 影響範圍: - web-demo/public/app.js:readStoredLayout 改為整筆記錄驗證。 - web-demo/public/styles.css:is-resizing 游標與選取規則一併套用到子元素。 - web-demo/tests/browser.spec.mjs:擴充無效版面回退測試並新增游標契約測試。 - docs/compatibility.md、docs/compatibility.zh-CN.md:更新為會校驗保存布局。 驗證項目: - npm run build:通過(miniexcel-wasm release 建置)。 - npm run test:e2e:29 項通過、22 項依既有桌面/行動版篩選條件跳過。 - 回歸驗證:暫時還原 app.js 修正時,「invalid stored layouts」測試在 {width: 0, collapsed: true} 案例失敗;暫時還原 styles.css 修正時, 「resize cursor」測試在子元素游標斷言失敗,確認兩項測試都能攔阻原始缺陷。
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Advanced Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
Comment |
This was referenced Sep 14, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds a Rust-native fluent editor for deferred font-color updates to existing worksheet cells.
CellReference/RgbColoroperations and normalize them atsave()Validation:
cargo +1.85.0 test --workspace --all-targets --lockedcargo +1.85.0 test -p miniexcel --test insert --lockedcargo +1.85.0 clippy --workspace --all-targets --locked -- -D warningscargo +1.85.0 doc --workspace --no-deps --lockedCloses #16