运行 ❯
获取您
的
网站
×
更改方向
保存代码
更改主题,深色/浅色
前往 Spaces
<!DOCTYPE html> <html> <head> <meta name="viewport" content="width=device-width, initial-scale=1"> <!-- Add icon library --> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css"> <style> .btn { background-color: DodgerBlue; border: none; color: white; padding: 12px 16px; font-size: 16px; cursor: pointer; } /* Darker background on mouse-over */ .btn:hover { background-color: RoyalBlue; } </style> </head> <body> <h2>Icon Buttons</h2> <p>Icon buttons:</p> <button class="btn"><i class="fa fa-home"></i></button> <button class="btn"><i class="fa fa-bars"></i></button> <button class="btn"><i class="fa fa-trash"></i></button> <button class="btn"><i class="fa fa-close"></i></button> <button class="btn"><i class="fa fa-folder"></i></button> <p>Icon buttons with text:</p> <button class="btn"><i class="fa fa-home"></i> Home</button> <button class="btn"><i class="fa fa-bars"></i> Menu</button> <button class="btn"><i class="fa fa-trash"></i> Trash</button> <button class="btn"><i class="fa fa-close"></i> Close</button> <button class="btn"><i class="fa fa-folder"></i> Folder</button> </body> </html>