基礎版型 220409
以 PDWebsitemplate 模組(T002、C004、C013、C006、C014、C007、B001)透過 sn 屬性組成的靜態形象頁,綠色主題。
概要
即時預覽
在新分頁開啟範例
頁面區塊
相依資源
樣式
即使頁面只用 7 個模組仍編譯整套模組庫;每個模組以 div[sn=XXXX] 為範圍,並以 ::after 依 --module-hint 顯示模組代號。sass/index.scss(含 _header-0、_section-1)是頁面未引用的另一個殘留入口。
cd target/20220409
npx sass sass/PDWebsitemplate.min.scss css/PDWebsitemplate.min.css --no-source-map || exit 1
使用技巧
- 屬性驅動模組:sn="T002" 等選擇模組樣式;df="x2/x3" 欄數、df="btn fff col xl" 按鈕變化、wh="1" 圖片外框、df="sd" 陰影卡。
- 主題以 inline <style> 於 * 設定 CSS 變數:--col-sys(綠 rgb(30,120,50))、--max-width 1140px、--default-radius 0.25rem、--module-hint 1。
- 桌面優先 max-width 斷點(413 / 479 / 639 / 767 / 959 / 1023px),並以 (hover: hover) and (pointer: fine) 搭配 keyframe 顏色過場處理 hover。
- 導覽列為純 CSS hover 下拉;640px 以下連結隱藏(display: none)。
外部資源
https://fakeimg.pl/1024/282828/eae0d0/?text=sample
https://pardn.io/image/head.png
https://pardn.io/web-template/image/20220409.jpg
- /sample2, /sample2/gallery, /sample2/blog (root-absolute nav links)
- ../icon/watch/1/fff.svg, ../image/bg-l.svg, ../image/bg-m.svg (referenced by compiled CSS, not present in the folder)
已知問題
- Nav links /sample2, /sample2/gallery and /sample2/blog are root-absolute and point to pages that do not exist. CSS url(../icon/watch/1/fff.svg), url(../image/bg-l.svg) and url(../image/bg-m.svg) resolve to <folder>/icon and <folder>/image, which are not in the folder (bg-l.svg is overridden by inline background-image). The mobile menu <img df="nvb"> has an empty src, its icon CSS is commented out and no JS is loaded, so links are unreachable below 640px.
相關頁面