Untitled
unknown
plain_text
8 months ago
3.1 kB
2
Indexable
Never
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>Menu Editor</title> <style> /* CSS styles */ body { font-family: Arial, sans-serif; margin: 0; padding: 0; background-color: #f4f4f4; } .menu-editor { max-width: 800px; margin: 20px auto; padding: 20px; background-color: #fff; border-radius: 8px; box-shadow: 0 0 10px rgba(0, 0, 0, 0.1); } h1 { text-align: center; } .menu-items { margin-top: 20px; } .menu-item { background-color: #f9f9f9; padding: 10px; margin-bottom: 10px; border-radius: 5px; } .menu-item h3 { margin-top: 0; } .menu-item button { background-color: #ff0000; color: #fff; border: none; padding: 5px 10px; border-radius: 5px; cursor: pointer; } .modal { display: none; position: fixed; z-index: 1; left: 0; top: 0; width: 100%; height: 100%; background-color: rgba(0, 0, 0, 0.5); } .modal-content { background-color: #fff; margin: 20% auto; padding: 20px; width: 60%; border-radius: 8px; box-shadow: 0 0 10px rgba(0, 0, 0, 0.3); } .close { color: #aaa; float: right; font-size: 28px; font-weight: bold; cursor: pointer; } #item-name, #item-price { width: 100%; padding: 10px; margin-bottom: 10px; border: 1px solid #ccc; border-radius: 5px; box-sizing: border-box; } #save-item-btn { background-color: #4caf50; color: #fff; border: none; padding: 10px 20px; border-radius: 5px; cursor: pointer; } </style> </head> <body> <div class="menu-editor"> <h1>Menu Editor</h1> <div class="menu-items"> <!-- Menu items will be dynamically added here --> </div> <button id="add-item-btn">Add New Item</button> </div> <!-- Modal for adding/editing menu items --> <div id="item-modal" class="modal"> <div class="modal-content"> <span class="close">×</span> <h2>Add/Edit Menu Item</h2> <input type="text" id="item-name" placeholder="Item Name"> <input type="number" id="item-price" placeholder="Item Price"> <button id="save-item-btn">Save</button> </div> </div> <script> // JavaScript code for functionality // You need to implement this part </script> </body> </html>
Leave a Comment