-
Notifications
You must be signed in to change notification settings - Fork 2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Checklists: State and structure #26015
Labels
Comments
Love it ❤️ It makes so much more sense to put stuff like |
Noting that completed tasks move up, which changes the declared ordering. We can handle that with flexbox magic. css idea.SomeChecklistWrapper {
display: flex;
flex-direction: column;
}
.ChecklistItem {
order: 100;
}
.ChecklistItem.is-complete {
order: 0;
} |
@markryall @taggon @timmyc Wanted to involve you in this conversation as you've been involved in checklists. |
This was referenced Jul 12, 2018
5 tasks
5 tasks
Implimented in #26618 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
This issue is to share some discussion that @ockham and I have been having while looking at #25956
I'll summarize conversations up until this point and provide a bit of a roadmap. We're taking on some checklist work.
tasks
is a mix of structure and state.Here's
tasks
now (or soon):wp-calypso/client/my-sites/checklist/jetpack-checklist.js
Lines 7 to 19 in 1501e9f
It's connected and merged with server state in connect:
wp-calypso/client/my-sites/stats/checklist-banner/index.jsx
Lines 212 to 216 in 1501e9f
Note that this is undesirable because:
connect
Then a checklist is rendered like this:
wp-calypso/client/blocks/checklist/index.jsx
Line 102 in 4722397
What if a checklist looked like this?
No more
tasks
state and structure.Each checklist looks more like this. Note that all of these structural things live here declaratively (task ids, urls, translated strings…)
And our
ChecklistItem
blocks looked something like this?Now, we'd imaging that Redux state would be very minimal, including only the
status
of a particular task (pending, in progress, complete, dismissed?).The text was updated successfully, but these errors were encountered: