สีและการออกแบบ
เครื่องมือสร้าง Glassmorphism
Frosted-glass UI cards with backdrop-filter.
หมายเหตุจากบรรณาธิการ
Understanding · Frosted glass, in three CSS properties.
บทเชิงลึกนี้มีให้บริการเฉพาะภาษาอังกฤษในขณะนี้ เครื่องมือแปลงด้านบนทำงานในภาษาของคุณ บทความอธิบายแบบยาวยังไม่ได้แปล
คำถามที่พบบ่อย
Quick answers.
›Which CSS property creates the glass effect?
The primary property is `backdrop-filter: blur()`, which applies the blur to the area behind the element rather than the element itself. This is usually paired with a semi-transparent `background-color` using RGBA or HSLA values.
›Does this work in all browsers?
Most modern browsers support `backdrop-filter`. Firefox occasionally requires the `layout.css.backdrop-filter.enabled` flag to be set to true in older versions, so including a fallback background colour is recommended.
›Why does the blur not appear in my project?
Ensure the element has a transparent or semi-transparent background. If the background is fully opaque, the blur effect happening behind the element will be hidden from view.
›Can I use this for production UI components?
Yes. Glassmorphism is a common design pattern for cards, navigation bars, and modals. The generated CSS is standard-compliant and ready for use in any stylesheet.
ผู้คนยังค้นหา
เครื่องมือที่เกี่ยวข้อง
More in this room.
- ตัวสร้าง Gradientสร้าง CSS gradient แบบ linear, radial และ conic
- ตัวสร้าง Box Shadowตัวแก้ไข CSS box-shadow แบบภาพ
- ตัวสร้าง Border Radiusตัวแก้ไข CSS border-radius แยกแต่ละมุม
- ตัวแก้ไข Cubic Bezierออกแบบเส้นโค้ง Easing ของ CSS ด้วยภาพ
- ตัวสร้างแอนิเมชั่น CSSสร้างคีย์เฟรมด้วยสายตา คัดลอก CSS ที่พร้อมใช้
- ตัวสร้างตัวกรอง CSSดูตัวอย่างสด blur, brightness, hue-rotate และอื่นๆ