Skip to content

Commit

Permalink
remove radial progress bar when there's no tasks
Browse files Browse the repository at this point in the history
This action only worked when adding or removing tasks, but
not when loading a card.
  • Loading branch information
HectorVilas committed Jan 14, 2023
1 parent aa67b6e commit 7cab942
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/modules/ui.js
Original file line number Diff line number Diff line change
Expand Up @@ -185,6 +185,7 @@ export const ui = (() => {
const completed = todo.checks.filter(item => item.isDone).length;
const percentage = completed * 100 / todo.checks.length;
progress.style.background = `conic-gradient(#2e10c0 ${percentage}%, transparent ${percentage}%, transparent 100%)`
progress.style.opacity = todo.checks.length === 0 ? "0%" : "100%";

const description = document.createElement("p");
description.classList.add("description");
Expand Down

0 comments on commit 7cab942

Please sign in to comment.