Skip to content

Instantly share code, notes, and snippets.

@dariocravero
Last active February 20, 2019 10:51
Show Gist options
  • Save dariocravero/936350ba9360df4687d0be8491db8d9b to your computer and use it in GitHub Desktop.
Save dariocravero/936350ba9360df4687d0be8491db8d9b to your computer and use it in GitHub Desktop.
# one at a time
# one at a time
App
# parallel
Provide review and submit data with progress&
Progress
review data -> Review data
# one at a time
Provide review and submit data
# parallel
Provide data with guidance&
# one at a time
Provide data
Question 1
next 1 -> Question 2
Question 2
next 2 -> Question N
yes -> Question 2 1
# show when Question 2 is yes
Question 2 1
next 2 1 -> Question 2 2
# show when Question 2 is yes
Question 2 2
next N -> Question N
Question N
next N -> Submit
# hide when first question is answered
Welcome message
Review data&
Question 1 repeater
edit 1 -> Question 1
Question 2 repeater
edit 2 -> Question 2
Question 3 repeater
edit N -> Question N
# show when there are unanswered questions
# the ability to "focus" or go to a piece of data
# that wasn't filled in, is something we may want
# to expose in Views
Edit unanswered question
edit unanswered -> Question N
# show when data is valid
Submit
submit -> Confirmation
Confirmation
get pdf -> Pdf
Message
Pdf
function render(model){
let current_state_name = model.active_states[0].name;
return $("h1",
{style: {color: "darkBlue"}},
`The current state is: ${current_state_name}`);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment