Gemini 3.1 Flash Lite
by GoogleReasoningClean
Running live in a sandboxed frame. Click inside it before using the keyboard.
How it went
- Total time
- 4.9 s
- Cost
- $0.0029
- Output tokens
- 1,852
- Spent thinking
- 0 tokens
- Speed
- 427.8 tok/s
- Console errors
- 0
- First token after
- 526 ms
- First visible text after
- 526 ms
- Prompt tokens
- 507
- Code size
- 5.7 KB
- Finish reason
- stop
- Served by
- Model id
google/gemini-3.1-flash-lite- Reasoning sent
{"effort":"minimal"}- Max output
- 65,536 tokens
- Generated
- Nov 12, 2026
What it was asked
The prompt
Build an interactive Kanban board in vanilla HTML, CSS and JavaScript (no framework, no library). Requirements: - Three columns: "To do", "In progress", "Done", each showing its card count. - Pre-populate the board with 6 realistic cards spread across the columns so the first screenshot looks alive. - Each card has a title and a priority (low / medium / high) shown as a colored badge. - Add a card through a small modal form (title required), and delete a card with a button on it. - Drag and drop cards between columns with the mouse, with a clear visual drop indicator. - A search field that filters cards live by title. - A light / dark theme toggle. - State lives in memory only (no storage APIs).
System prompt, sent with every prompt
You are generating a self-contained web demo. It will be rendered automatically in a sandboxed iframe and compared side by side with the output of other AI models given the exact same task. Output rules: - Reply with exactly ONE fenced code block containing the complete file: ```html (or ```svg when the task asks for an SVG). No text before or after the code block. - Everything must be inline: CSS in <style>, JavaScript in <script>. No external files, images, fonts or network requests, except the CDN URLs explicitly allowed by the task. - Do not use localStorage, sessionStorage, cookies, IndexedDB, alert(), confirm(), prompt() or window.open(): they are blocked in the sandbox and will throw. - The page must look right in a 1280×800 viewport and adapt gracefully down to 375px wide. No horizontal scrollbar. - Something meaningful must be visible on first paint: a screenshot is taken automatically about 3 seconds after load, without any interaction. - Everything that makes the demo interesting must be visible within the first seconds: nothing hidden behind a high score, a later level or a long play session. - Games must start in a self-playing demo mode (a simple AI plays) behind a "Click or press a key to start" message, so the game can be judged in action without playing. - The iframe only receives keyboard events after the user clicks it: if the demo uses the keyboard, display a clear "Click or press a key to start" message. - The code must run with zero errors in the console of the latest Chrome.
Code run-1.html · 116 lines
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Kanban Pro</title>
<style>
:root { --bg: #f4f7f6; --card: #fff; --text: #333; --border: #ddd; --primary: #4a90e2; }
.dark { --bg: #1a1a1a; --card: #2d2d2d; --text: #eee; --border: #444; --primary: #357abd; }
body { font-family: system-ui, sans-serif; background: var(--bg); color: var(--text); margin: 0; transition: background 0.3s; }
header { display: flex; justify-content: space-between; align-items: center; padding: 1rem 2rem; background: var(--card); box-shadow: 0 2px 5px rgba(0,0,0,0.1); }
.board { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 1.5rem; padding: 2rem; align-items: start; }
.column { background: rgba(0,0,0,0.05); border-radius: 8px; padding: 1rem; min-height: 500px; display: flex; flex-direction: column; gap: 1rem; }
.column h2 { margin-top: 0; font-size: 1.1rem; display: flex; justify-content: space-between; }
.card { background: var(--card); padding: 1rem; border-radius: 6px; box-shadow: 0 2px 4px rgba(0,0,0,0.1); cursor: grab; border-left: 4px solid var(--primary); }
.badge { font-size: 0.7rem; padding: 2px 6px; border-radius: 4px; text-transform: uppercase; margin-right: 5px; }
.priority-high { background: #ff4d4d; color: white; }
.priority-medium { background: #ffa500; color: white; }
.priority-low { background: #2ecc71; color: white; }
.controls { display: flex; gap: 10px; }
.modal { display: none; position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.5); justify-content: center; align-items: center; }
.modal-content { background: var(--card); padding: 2rem; border-radius: 8px; width: 300px; }
.drop-zone { border: 2px dashed var(--primary); opacity: 0.5; }
input, select, button { padding: 8px; border-radius: 4px; border: 1px solid var(--border); background: var(--card); color: var(--text); }
.del-btn { color: red; cursor: pointer; float: right; border: none; background: none; }
</style>
</head>
<body>
<header>
<h1>Kanban</h1>
<div class="controls">
<input type="text" id="search" placeholder="Filter cards...">
<button onclick="openModal()">+ Add Card</button>
<button onclick="toggleTheme()">🌓</button>
</div>
</header>
<div class="board" id="board">
<div class="column" id="todo" ondrop="drop(event)" ondragover="allowDrop(event)">
<h2>To Do <span class="count">0</span></h2>
</div>
<div class="column" id="in-progress" ondrop="drop(event)" ondragover="allowDrop(event)">
<h2>In Progress <span class="count">0</span></h2>
</div>
<div class="column" id="done" ondrop="drop(event)" ondragover="allowDrop(event)">
<h2>Done <span class="count">0</span></h2>
</div>
</div>
<div id="modal" class="modal">
<div class="modal-content">
<h3>New Card</h3>
<input id="cardTitle" placeholder="Title" required><br><br>
<select id="cardPriority"><option>low</option><option>medium</option><option>high</option></select><br><br>
<button onclick="addCard()">Save</button>
<button onclick="closeModal()">Cancel</button>
</div>
</div>
<script>
let state = [
{id: 1, title: 'Learn Vanilla JS', col: 'todo', priority: 'high'},
{id: 2, title: 'Build Kanban', col: 'in-progress', priority: 'medium'},
{id: 3, title: 'Fix CSS bug', col: 'todo', priority: 'low'},
{id: 4, title: 'Write Tests', col: 'in-progress', priority: 'high'},
{id: 5, title: 'Deploy App', col: 'done', priority: 'low'},
{id: 6, title: 'Coffee break', col: 'done', priority: 'medium'}
];
function render() {
const query = document.getElementById('search').value.toLowerCase();
document.querySelectorAll('.column').forEach(c => c.querySelectorAll('.card').forEach(x => x.remove()));
state.forEach(item => {
if (!item.title.toLowerCase().includes(query)) return;
const el = document.createElement('div');
el.className = 'card';
el.draggable = true;
el.id = 'c' + item.id;
el.ondragstart = e => e.dataTransfer.setData('text', item.id);
el.innerHTML = `<button class="del-btn" onclick="deleteCard(${item.id})">✕</button><span class="badge priority-${item.priority}">${item.priority}</span><br><strong>${item.title}</strong>`;
document.getElementById(item.col).appendChild(el);
});
['todo', 'in-progress', 'done'].forEach(id => {
document.querySelector(`#${id} .count`).innerText = state.filter(s => s.col === id).length;
});
}
function allowDrop(e) { e.preventDefault(); }
function drop(e) {
const id = parseInt(e.dataTransfer.getData('text'));
const col = e.target.closest('.column').id;
state = state.map(s => s.id === id ? {...s, col} : s);
render();
}
function addCard() {
const title = document.getElementById('cardTitle').value;
if(!title) return;
state.push({id: Date.now(), title, col: 'todo', priority: document.getElementById('cardPriority').value});
closeModal();
render();
}
function deleteCard(id) { state = state.filter(s => s.id !== id); render(); }
function openModal() { document.getElementById('modal').style.display = 'flex'; }
function closeModal() { document.getElementById('modal').style.display = 'none'; }
function toggleTheme() { document.body.classList.toggle('dark'); }
document.getElementById('search').addEventListener('input', render);
render();
</script>
</body>
</html>