Skip to content

Instantly share code, notes, and snippets.

@pksbogastro
Created March 13, 2026 15:31
Show Gist options
  • Select an option

  • Save pksbogastro/353647baf40a9a88ff509000ae9cf74e to your computer and use it in GitHub Desktop.

Select an option

Save pksbogastro/353647baf40a9a88ff509000ae9cf74e to your computer and use it in GitHub Desktop.
Einkaufen
<!DOCTYPE html>
<html lang="de">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=no">
<title>Foodtruck Liste</title>
<style>
body { font-family: sans-serif; background: #f4f7f6; margin: 0; padding: 10px; text-align: center; }
.card { background: white; padding: 15px; border-radius: 16px; box-shadow: 0 4px 12px rgba(0,0,0,0.1); margin-bottom: 12px; }
select { width: 100%; padding: 14px; font-size: 18px; border: 2px solid #2196F3; border-radius: 12px; margin-bottom: 12px; background: white; }
.btn { width: 100%; padding: 16px; border: none; border-radius: 12px; font-weight: bold; font-size: 16px; margin: 6px 0; cursor: pointer; color: white; display: flex; align-items: center; justify-content: center; }
.btn-row { display: flex; justify-content: space-between; gap: 10px; }
.btn-small { width: 48%; }
.btn-gray { background: #e0e0e0; color: #333; }
.btn-red { background: #ff5252; }
.btn-green { background: #4CAF50; }
.btn-blue { background: #2196F3; }
.btn-orange { background: #FF9800; }
.btn-black { background: #333; }
#admin-area { display: none; padding: 15px; border: 2px dashed #ddd; border-radius: 12px; margin-top: 10px; background: #fafafa; }
input { width: 100%; padding: 12px; margin-bottom: 10px; border-radius: 8px; border: 1px solid #ccc; box-sizing: border-box; font-size: 16px; }
.item { background: white; padding: 12px; border-radius: 12px; margin-bottom: 8px; display: flex; align-items: center; text-align: left; border: 1px solid #e0e0e0; position: relative; min-height: 90px; }
.item img { width: 85px; height: 85px; object-fit: cover; border-radius: 8px; margin-right: 15px; background: #eee; flex-shrink: 0; }
.item-info { flex-grow: 1; display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.edit-name { font-size: 1.2em; font-weight: bold; border: none; background: transparent; color: #333; flex-grow: 1; outline: none; }
.edit-qty { width: 55px; height: 40px; border: 1px solid #ccc; border-radius: 8px; text-align: center; font-size: 1.1em; background: white; color: #333; }
.shop-checked { opacity: 0.25; filter: grayscale(100%); text-decoration: line-through; }
#img-overlay { display: none; position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.9); z-index: 1000; justify-content: center; align-items: center; }
#img-overlay img { max-width: 95%; max-height: 95%; border-radius: 10px; }
.del-btn { position: absolute; top: -5px; right: -5px; background: #ff5252; color: white; width: 28px; height: 28px; border-radius: 50%; font-size: 20px; line-height: 26px; text-align: center; cursor: pointer; border: 2px solid white; z-index: 5; }
@media print { .no-print { display: none !important; } .item { border: none; border-bottom: 1px solid #eee; } }
</style>
</head>
<body>
<div id="img-overlay" onclick="this.style.display='none'"><img id="full-img"></div>
<div class="card no-print">
<select id="listSelect" onchange="updateList()"></select>
<div class="btn-row">
<button class="btn btn-gray btn-small" onclick="addList()">+ Neu</button>
<button class="btn btn-red btn-small" onclick="removeList()">Löschen</button>
</div>
</div>
<div class="card no-print">
<button class="btn btn-green" onclick="toggleAdd()">➕ Artikel hinzufügen</button>
<div id="admin-area">
<input type="text" id="nameInp" placeholder="Name">
<input type="file" id="imgInp" accept="image/*">
<button class="btn btn-green" onclick="saveNew()">SPEICHERN</button>
</div>
<button id="modeBtn" class="btn btn-blue"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment