</header>
<div id="main">
<div>
- <div id="archived"></div>
+ <div id="archived">
+ <p>No archived todos for now...</p>
+ </div>
</div>
</div>
<footer></footer>
const hydrateTodos = () => {
- archivedElement.innerHTML = archived
+ if (archived.length > 0) archivedElement.innerHTML = archived
.map((x, index) => todoElement(x, index))
.join("");
<div>
<button id="createTodo">
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
- <g fill="none" stroke="currentColor" stroke-dasharray="16" stroke-linecap="round" stroke-linejoin="round" stroke-width="2">
- <path d="M5 12h14">
- <animate fill="freeze" attributeName="stroke-dashoffset" dur="0.5s" values="16;0"/>
- </path>
- <path stroke-dashoffset="16" d="M12 5v14">
- <animate fill="freeze" attributeName="stroke-dashoffset" begin="0.5s" dur="0.5s" to="0"/>
- </path>
- </g>
+ <path fill="currentColor" d="M11 13H5v-2h6V5h2v6h6v2h-6v6h-2z" />
</svg>
</button>
<div id="todos"></div>
}
#override_css {
+ font-family: monospace;
+ border-radius: 0.5rem;
resize: vertical;
+ border: 0.25rem solid var(--background-tertiary);
+ background-color: var(--background-secondary);
}
a, a:visited, a:active {
background-color: var(--background-tertiary);
}
+#archived p {
+ text-align: center;
+}
+
.hidden,
div:has(> #todos-completed.hidden),
#main div:has(#todos-completed.hidden) #showCompleted_close,