Last active
April 4, 2019 23:18
-
-
Save tdrach/ee18ffbd06bbfde14614362e11112feb to your computer and use it in GitHub Desktop.
Funnels Chart
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Funnels Chart | |
First Step | |
Create Cohort -> Create Cohort Modal | |
Second Step | |
Create Cohort -> Create Cohort Modal | |
Third Step | |
Create Cohort -> Create Cohort Modal | |
Create Cohort Modal | |
Save Cohort -> Confirmation Toast | |
Cancel -> First Step | |
Confirmation Toast | |
Dismiss -> Funnels Chart |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function bar(model, height) { | |
return $("div", { | |
style: { | |
width: '40px', | |
height: `${height}px`, | |
background: 'blue', | |
marginRight: '10px', | |
}, | |
onClick: function () { | |
model.emit('Create Cohort') | |
} | |
}) | |
} | |
function render(model){ | |
let current_state_name = model.active_states[0].name; | |
return $("div", { | |
style: { | |
display: 'flex', | |
alignItems: 'bottom' | |
} | |
}, | |
bar(model, 100), | |
bar(model, 30), | |
bar(model, 60), | |
bar(model, 20), | |
model.active_states[0].name); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment