中文字幕av专区_日韩电影在线播放_精品国产精品久久一区免费式_av在线免费观看网站

溫馨提示×

溫馨提示×

您好,登錄后才能下訂單哦!

密碼登錄×
登錄注冊×
其他方式登錄
點擊 登錄注冊 即表示同意《億速云用戶服務條款》

HTML5和CSS3實現機器貓的案例

發布時間:2020-10-23 16:26:02 來源:億速云 閱讀:145 作者:小新 欄目:web開發

這篇文章將為大家詳細講解有關HTML5和CSS3實現機器貓的案例,小編覺得挺實用的,因此分享給大家做個參考,希望大家閱讀完這篇文章后可以有所收獲。

具體代碼如下所示:

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>機器貓</title>
<style type="text/css">
* {   
margin: 0;   
padding: 0;   
}   
.whole {   
width: 800px;   
margin: 20px auto;   
/*border: 2px solid yellow;*/   
background-color: white;   
position: relative;   
}   
.head {   
margin: 0 auto;   
position: relative;   
width: 500px;   
height: 440px;   
background-color: #00b7e7;   
border-radius: 220px;   
border: 1px solid red;   
}   
.eye .left_eye,   
.eye .right_eye {   
width: 100px;   
height: 130px;   
background-color: white;   
border: 2px solid black;   
border-radius: 50px;   
position: absolute;   
top: 50px;   
z-index: 3;   
}   
.eye .LeyeBall,   
.eye .ReyeBall {   
width: 20px;   
height: 20px;   
background: black;   
border-radius: 10px;   
position: absolute;   
top: 65px;   
}   
.eye .left_eye {   
left: 146px;   
}   
.eye .right_eye {   
left: 250px;   
}   
.eye .LeyeBall {   
right: 10px;   
}   
.eye .ReyeBall {   
left: 10px;   
}   
.face {   
position: relative;   
z-index: 2;   
}   
.face .feature {   
width: 400px;   
height: 320px;   
border-radius: 160px;   
position: absolute;   
top: 100px;   
left: 50px;   
background: white;   
}   
.face .nose {   
width: 45px;   
height: 50px;   
border-radius: 23px;   
background-color: #cf3318;   
border: 2px solid black;   
position: absolute;   
top: 165px;   
left: 225px;   
z-index: 3;   
}   
.face .Nline {   
width: 3px;   
height: 160px;   
background: black;   
position: absolute;   
top: 218px;   
left: 248px;   
z-index: 3;   
}   
.face .mouth {   
width: 280px;   
height: 280px;   
border-bottom: 5px solid black;   
border-radius: 140px;   
position: absolute;   
top: 98px;   
left: 105px;   
}   
.face .mustache .MutR_higher {   
width: 80px;   
height: 2px;   
background: black;   
position: absolute;   
top: 220px;   
left: 295px;   
z-index: 2;   
}   
.face .mustache .MutR_middle {   
width: 80px;   
height: 2px;   
background: black;   
position: absolute;   
top: 240px;   
left: 295px;   
z-index: 2;   
}   
.face .mustache .MutR_lower {   
width: 80px;   
height: 2px;   
background: black;   
position: absolute;   
top: 260px;   
left: 295px;   
z-index: 2;   
}   
.face .mustache .MutL_top {   
width: 80px;   
height: 2px;   
background: black;   
position: absolute;   
top: 220px;   
left: 115px;   
z-index: 2;   
}   
.face .mustache .MutL_center {   
width: 80px;   
height: 2px;   
background: black;   
position: absolute;   
top: 240px;   
left: 115px;   
z-index: 2;   
}   
.face .mustache .MutL_bottom {   
width: 80px;   
height: 2px;   
background: black;   
position: absolute;   
top: 260px;   
left: 115px;   
z-index: 2;   
}   
.face .mustache .MutL_bottom,   
.face .mustache .MutR_higher {   
transform: rotate(160deg);   
}   
.face .mustache .MutL_top,   
.face .mustache .MutR_lower {   
transform: rotate(200deg);   
}   
.neck {   
width: 300px;   
height: 30px;   
background-color: #a31f12;   
border: 2px solid black;   
border-radius: 15px;   
position: relative;   
top: 0px;   
left: 250px;   
z-index: 4;   
}   
.neck .bell {   
width: 60px;   
height: 60px;   
overflow: hidden;   
border: 2px solid black;   
border-radius: 60px;   
background-color: #cfcb3c;   
position: absolute;   
top: 5px;   
left: 120px;   
}   
.bell .Bline {   
width: 60px;   
height: 2px;   
background-color: #cfcb3c;   
border: 2px solid black;   
border-radius: 3px 3px 0 0;   
position: absolute;   
top: 15px;   
}   
.bell .Bcircle {   
width: 20px;   
height: 16px;   
background: black;   
border-radius: 8px;   
position: absolute;   
top: 25px;   
left: 20px;   
}   
.bell .Bunderpart {   
width: 3px;   
height: 20px;   
background-color: black;   
position: absolute;   
left: 28px;   
top: 40px;   
}   
.body {   
position: relative;   
top: -300px;   
z-index: 1;   
}   
.body .tummy {   
width: 280px;   
height: 240px;   
background-color: #00b1e1;   
border: 2px solid black;   
position: absolute;   
top: 267px;   
left: 260px;   
}   
.body .bellyband {   
width: 220px;   
height: 220px;   
background-color: white;   
border: 2px solid black;   
border-radius: 110px;   
position: absolute;   
left: 290px;   
top: 267px;   
}   
.body .pocket {   
width: 160px;   
height: 160px;   
border-radius: 80px;   
background-color: white;   
border: 2px solid black;   
position: absolute;   
top: 305px;   
left: 320px;   
}   
.cover {   
width: 164px;   
height: 80px;   
background-color: white;   
border-bottom: 2px solid black;   
/*border: 5px solid orange;*/   
position: absolute;   
top: 300px;   
left: 320px;   
}   
.left_hand,   
.right_hand {   
height: 100px;   
width: 100px;   
position: absolute;   
top: 272px;   
left: 248px;   
}   
.left_hand {   
left: -10px;   
}   
.left_hand .Larm {   
width: 70px;   
height: 100px;   
background-color: #00bee8;   
border: 1px solid black;   
position: relative;   
top: 200px;   
left: 535px;   
transform: rotateZ(135deg);   
/*z-index: -1;*/   
}   
.right_hand {   
left: -10px;   
}   
.right_hand .Rarm {   
width: 70px;   
height: 100px;   
background-color: #00bee8;   
border: 1px solid black;   
/*z-index: -1;*/   
position: relative;   
top: 200px;   
left: 215px;   
transform: rotateZ(45deg);   
}   
.left_hand .Lpalm,   
.right_hand .Rpalm {   
width: 80px;   
height: 80px;   
border-radius: 40px;   
border: 2px solid black;   
background-color: white;   
position: absolute;   
}   
.right_hand .Rpalm {   
left: 580px;   
top: 260px;   
z-index: 1;   
}   
.left_hand .Lpalm {   
left: 160px;   
top: 260px;   
z-index: 1;   
}   
.foot .left_foot,   
.foot .right_foot {   
width: 150px;   
height: 40px;   
background-color: white;   
border: 2px solid black;   
border-radius: 80px 60px 60px 40px;   
position: relative;   
}   
.foot .left_foot {   
left: 240px;   
top: 210px;   
}   
.foot .right_foot {   
top: 165px;   
left: 410px;   
}   
.foot .crotch {   
width: 40px;   
height: 20px;   
background-color: white;   
border: 2px solid black;   
border-bottom: none;   
border-radius: 40px 40px 0 0;   
position: relative;   
top: 103px;   
left: 382px;   
z-index: 2   
}   
</style>
</head>
<body>
<p class="wrap">
<p class="whole">
<!-- 頭 -->
<p class="head">
<!-- 眼 -->
<p class="eye">
<!-- 左眼 -->
<p class="left_eye">
<!-- 左眼球 -->
<p class="LeyeBall"></p>
</p>
<!-- 右眼 -->
<p class="right_eye">
<!-- 右眼球 -->
<p class="ReyeBall"></p>
</p>
</p>
<!-- 臉 -->
<p class="face">
<!-- 臉型 -->
<p class="feature"></p>
<!-- 鼻 -->
<p class="nose"></p>
<!-- 鼻子線 -->
<p class="Nline"></p>
<!-- 嘴 -->
<p class="mouth"></p>
<!-- 胡子 -->
<p class="mustache">
<p class="MutL_top"></p>
<p class="MutL_center"></p>
<p class="MutL_bottom"></p>
<p class="MutR_higher"></p>
<p class="MutR_middle"></p>
<p class="MutR_lower"></p>
</p>
</p>
</p>
<!-- 脖子 -->
<p class="neck">
<!-- 鈴鐺 -->
<p class="bell">
<p class="Bline"></p>
<p class="Bcircle"></p>
<p class="Bunderpart"></p>
</p>
</p>
<!-- 身體 -->
<p class="body">
<!-- 肚子 -->
<p class="tummy"></p>
<!-- 肚兜 -->
<p class="bellyband"></p>
<!-- 口袋 -->
<p class="pocket"></p>
<p class="cover"></p>
</p>
<!-- 左手 -->
<p class="left_hand">
<!-- 手臂 -->
<p class="Larm"></p>
<!-- 手掌 -->
<p class="Lpalm"></p>
</p>
<!-- 右手 -->
<p class="right_hand">
<!-- 手臂 -->
<p class="Rarm"></p>
<!-- 手掌 -->
<p class="Rpalm"></p>
</p>
<!-- 腳 -->
<p class="foot">
<!-- 左腳 -->
<p class="left_foot"></p>
<!-- 右腳 -->
<p class="right_foot"></p>
<p class="crotch"></p>
</p>
</p>
</p>
</body>
</html>

關于HTML5和CSS3實現機器貓的案例就分享到這里了,希望以上內容可以對大家有一定的幫助,可以學到更多知識。如果覺得文章不錯,可以把它分享出去讓更多的人看到。

向AI問一下細節

免責聲明:本站發布的內容(圖片、視頻和文字)以原創、轉載和分享為主,文章觀點不代表本網站立場,如果涉及侵權請聯系站長郵箱:is@yisu.com進行舉報,并提供相關證據,一經查實,將立刻刪除涉嫌侵權內容。

AI

鄢陵县| 玛曲县| 格尔木市| 响水县| 苏尼特右旗| 蒲江县| 青岛市| 绥滨县| 洱源县| 永康市| 琼海市| 龙胜| 禹州市| 班玛县| 临江市| 洛南县| 雅安市| 沙田区| 松江区| 兰考县| 阳东县| 四川省| 贵州省| 渝北区| 信宜市| 鹤峰县| 佛冈县| 永定县| 扎赉特旗| 鸡泽县| 乌什县| 米林县| 土默特右旗| 文安县| 孟村| 安乡县| 通州市| 桃园县| 古田县| 岚皋县| 五原县|