Checklist management without reordering
This commit is contained in:
parent
dc2b6dac8b
commit
d0f410323e
12 changed files with 1100 additions and 46 deletions
|
|
@ -379,6 +379,12 @@ header {
|
|||
border-radius: 4px;
|
||||
}
|
||||
|
||||
pre {
|
||||
background: #f5f5f5;
|
||||
padding: 8px;
|
||||
border-radius: 8px;
|
||||
}
|
||||
|
||||
pre > code {
|
||||
background: unset;
|
||||
padding: 0px;
|
||||
|
|
@ -398,31 +404,83 @@ header {
|
|||
margin-top: 8px;
|
||||
margin-bottom: 0px;
|
||||
|
||||
.header {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(3, min-content);
|
||||
align-items: center;
|
||||
grid-gap: 0 16px;
|
||||
|
||||
img {
|
||||
height: 20px;
|
||||
cursor: pointer;
|
||||
}
|
||||
}
|
||||
|
||||
.header + .checklist-group.edit {
|
||||
margin-top: 16px;
|
||||
}
|
||||
|
||||
.checklist-group {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(4, min-content);
|
||||
align-items: center;
|
||||
grid-gap: 0 8px;
|
||||
|
||||
margin-top: 1em;
|
||||
margin-bottom: 8px;
|
||||
font-weight: bold;
|
||||
|
||||
.label {
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.label.ok {
|
||||
color: #54b356;
|
||||
}
|
||||
|
||||
.label.error {
|
||||
color: #d13636;
|
||||
}
|
||||
|
||||
&.edit {
|
||||
margin-top: 32px;
|
||||
border-bottom: 1px solid #aaa;
|
||||
padding-bottom: 8px;
|
||||
}
|
||||
|
||||
&:not(.edit) {
|
||||
.reorder { display: none; }
|
||||
img { display: none; }
|
||||
}
|
||||
|
||||
img {
|
||||
height: 14px;
|
||||
cursor: pointer;
|
||||
}
|
||||
}
|
||||
|
||||
.checklist-item {
|
||||
display: grid;
|
||||
grid-template-columns: min-content 1fr;
|
||||
grid-template-columns: repeat(3, min-content);
|
||||
grid-gap: 0 8px;
|
||||
align-items: center;
|
||||
margin-top: 0.50em;
|
||||
padding: 4px 0;
|
||||
border-bottom: 2px solid #fff;
|
||||
|
||||
&.checked {
|
||||
text-decoration: line-through;
|
||||
color: #888;
|
||||
color: #aaa;
|
||||
}
|
||||
|
||||
&.drag-target {
|
||||
border-bottom: 2px solid #71c837;
|
||||
}
|
||||
|
||||
input[type="checkbox"] {
|
||||
margin-left: 0px;
|
||||
margin-right: 8px;
|
||||
|
||||
-webkit-appearance: none;
|
||||
appearance: none;
|
||||
background-color: #fff;
|
||||
margin: 0 8px 0 0;
|
||||
margin: 0 2px 0 0;
|
||||
font: inherit;
|
||||
color: currentColor;
|
||||
width: 1.25em;
|
||||
|
|
@ -435,6 +493,14 @@ header {
|
|||
place-content: center;
|
||||
}
|
||||
|
||||
label.ok {
|
||||
color: #54b356;
|
||||
}
|
||||
|
||||
label.error {
|
||||
color: #d13636;
|
||||
}
|
||||
|
||||
input[type="checkbox"].ok {
|
||||
border: 0.15em solid #54b356;
|
||||
}
|
||||
|
|
@ -464,8 +530,30 @@ header {
|
|||
transform: scale(1);
|
||||
}
|
||||
|
||||
&.edit {
|
||||
input[type="checkbox"] {
|
||||
margin-left: 8px;
|
||||
}
|
||||
}
|
||||
|
||||
&:not(.edit) {
|
||||
.reorder {
|
||||
display: none;
|
||||
}
|
||||
img {
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
|
||||
img {
|
||||
height: 14px;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
|
||||
label {
|
||||
user-select: none;
|
||||
white-space: nowrap;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue