簡易的小米導航欄的製作HTML
阿新 • • 發佈:2022-01-15
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta http-equiv="X-UA-Compatible" content="IE=edge"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>Document</title> <style> a{ color: white; display: block; height: 40px; width: 230px; background-color: grey; font-size: 14px; text-decoration: none; text-indent: 2em; /* 文字行高等於盒子高度可以讓文字居中顯示 */ line-height: 40px; } a:hover { background-color: orange; } </style> </head> <body> <a href="">手機 電話卡</a> <a href="">電視 盒子</a> <a href="">筆記本 平板</a> <a href="">出行 穿戴</a> <a href="">智慧 路由器</a> <a href="">健康 兒童</a> <a href="">耳機 音響</a> </body> </html>
基礎有限,僅供參考