Repository navigation
更新日誌
- 修復 MathJax 4 行內公式被強制換行與溢出的問題:行內公式改用
inline+nowrap,超長公式在段落、列表項與標題內橫向滾動,不再撐破頁面(不支援:has()的瀏覽器會自動回退到舊方案) - 修復 Mermaid 內聯腳本模板中
</body>/</html>提前閉合、導致「在新視窗開啟」圖表失敗的問題 - 重構畫廊(justified gallery / masonry)的載入邏輯:
- 資料或 InfiniteGrid 腳本載入失敗時顯示本地化提示文案(新增
gallery_error,涵蓋 7 種語言) - 對遠端圖片網址做協定白名單檢查,阻止
javascript:等注入 - 優先使用 ResizeObserver 重新排版,不支援時回退到 autoResize;關閉 recycle,避免捲回時重複觸發延遲載入與燈箱
- 修復「載入更多」按鈕重複出現、載入動畫殘留的問題
- 畫廊初始化移至相對時間渲染之後執行;pjax 切換時銷毀 masonry 實例
- 資料或 InfiniteGrid 腳本載入失敗時顯示本地化提示文案(新增
- 修復佈局 6/7 的首頁卡片:封面鋪滿整張卡片並改用漸層遮罩,標題過長時不再被裁切
- 統一畫廊按鈕樣式,並補充鍵盤焦點(focus-visible)樣式
- 首頁、分類、標籤頁(佈局 6/7)預先載入 InfiniteGrid 腳本
- 升級內建第三方外掛:mermaid 12.4.0、waline 3.16.3、twikoo 2.0.18、algoliasearch 5.65.0、chart.js 4.6.2、abcjs 6.7.3
- 更新 npm 發布流程(Node.js 24 + OIDC 可信發布)
- 版本號升至 5.7.3
Changelog
- Fix MathJax 4 inline formulas wrapping onto several lines and overflowing: inline math now uses
inline+nowrap, and long formulas scroll horizontally inside paragraphs, list items and headings instead of breaking the page layout (falls back to the previous layout when:has()is unsupported) - Fix
</body>/</html>being closed early in the inline Mermaid script template, which broke opening a diagram in a new window - Rework the gallery (justified gallery / masonry) loading logic:
- show a localized message when the gallery data or the InfiniteGrid script fails to load (new
gallery_errorstring in 7 languages) - validate the protocol of remote image URLs to block
javascript:and similar injection - prefer ResizeObserver for re-layout and fall back to autoResize; disable recycling so lazyload and lightbox are not re-run when scrolling back
- fix the duplicated "load more" button and the loading spinner that never disappeared
- run the gallery init after relative dates are rendered; destroy masonry instances on pjax
- show a localized message when the gallery data or the InfiniteGrid script fails to load (new
- Fix the homepage card for index layout 6/7: the cover now fills the whole card with a gradient overlay, and long titles are no longer clipped
- Unify the gallery button style and add a keyboard
focus-visiblefocus ring - Preload the InfiniteGrid script on home, category and tag pages (layout 6/7)
- Bump bundled third-party plugins: mermaid 12.4.0, waline 3.16.3, twikoo 2.0.18, algoliasearch 5.65.0, chart.js 4.6.2, abcjs 6.7.3
- Update the npm publish workflow (Node.js 24 + OIDC trusted publishing)
- Bump version to 5.7.3
Full Changelog: 5.7.2...5.7.3