✨ CSS Border Style Generator

Configure border width, style, radius and colour with per-side control and copy the CSS for dividers and card outlines.

📐 工作原理與說明
邊框樣式按 solid / dashed / dotted / double / groove / ridge / inset / outset 八種輪換(下拉可固定其中一種);寬度與圓角留空時隨機(寬度 1–8 px、圓角 0–32 px),填寫後按填寫值固定輸出;配色預設在 10 色板內隨機,把「配色方式」切到「使用左側顏色」則統一使用所選色值;雙線 double 寬度小於 3 px 時自動提升到 3 px(否則瀏覽器按實線渲染)。單邊獨立開啟後只輸出 border-top / border-right / border-bottom / border-left 中的一條,四邊聯動則輸出 border 簡寫。
按邊框寬度、樣式、圓角與配色拼裝 border 系列宣告,支援單邊獨立設定;用於分隔線、卡片邊框等樣式產出。

📚 深度解析:邊框樣式生成器(圓角、線條)

💡 常見使用場景

  • 做卡片邊框。
  • 分隔線/虛線。
  • 單邊高亮。
生成底部 2px 橙線

輸入:僅 bottom 2px solid #FF6B35。

處理:拼 border 簡寫。

輸出:CSS 與預覽。結果以瀏覽器即時計算為準,純前端本地處理、資料不上傳;生成的樣式與程式碼僅作快速產出參考,正式專案請以設計系統、規範與瀏覽器實測為準。

❓ 常見問題(FAQ)

單邊怎麼寫?
用 border-bottom 等單邊屬性,或四向簡寫配合 none。結果以瀏覽器即時計算為準,純前端本地處理、資料不上傳;生成的樣式與程式碼僅作快速產出參考,正式專案請以設計系統、規範與瀏覽器實測為準。
生成的程式碼/圖片能直接用嗎?
可直接複製使用,建議粘到專案後在瀏覽器實測微調;本工具只生成不託管。
會儲存或上傳我的內容嗎?
結果以瀏覽器即時計算為準,純前端本地處理、資料不上傳;生成的樣式與程式碼僅作快速產出參考,正式專案請以設計系統、規範與瀏覽器實測為準。

Formula & Standard References

Item Formula / Note Source / Standard
Border shorthand order border-width and border-style follow top, right, bottom, left order CSS Backgrounds and Borders Level 3
Focus ring outline draws outside layout and suits keyboard focus rings CSS UI Level 4 / WCAG 2.2 (2.4.7)
Boundary contrast input borders need at least 3:1 contrast with adjacent colours WCAG 2.2 (1.4.11)
⚠️ 使用說明與注意事項