Stories

Detail Return Return

SVG 瞭解下 - Stories Detail

1. SVG中後面的元素會覆蓋前面的元素

<svg width="200" height="200" xmlns="http://www.w3.org/2000/svg">
    <!-- 第一層:紅色矩形 -->
    <rect x="10" y="10" width="100" height="100" fill="red" />
    <!-- 第二層:藍色矩形 -->
    <rect x="50" y="50" width="100" height="100" fill="blue" />
</svg>

image.png

藍色的矩形會顯示在紅色矩形的上面

渲染規則:寫在後面的元素擁有更高的層級

user avatar zhoumo_62382eba4b454 Avatar kk_470661 Avatar kasong Avatar zhedan_sam_wan9 Avatar karuru Avatar zxl20070701 Avatar daishuyunshuzhanqianduan Avatar zhipanyun Avatar zzd41 Avatar
Favorites 9 users favorite the story!
Favorites

Add a new Comments

Some HTML is okay.