Closed GustavoFernandes closed 7 years ago
Hooray yes this!
Here are some suggestions on how to implement this feature.
I'm also open to other ideas. Which do you think is the best approach?
I'd prefer the first method (A). Seems more practical.
C) ?
The user's choice is remembered via localStorage or cookies or whatnot.
D)
What about simplifying and extending @jonsmithers 's idea with 1 checkbox?
When it comes to "1 checkbox" vs "2 radio buttons", I don't think checkboxes are always better. For example, if you're choosing between "pepperoni" and "sausage" for your pizza topping, should you use a checkbox or radio buttons? Probably radio buttons. Choosing between "normal crust" and "extra thick crust"? Probably checkbox. I coincidentally had a mini conversation with Tyson about this concept last Friday and that was the example he gave.
Agreed - if you want sausage, you wouldn't expect your choices to be "check for pepperoni, un-check for not pepperoni" because sausage is not the opposite of pepperoni. It also doesn't account if you want pineapple as pizza topping.
However, in this case, I only see 2 ways of interpreting the value of the tip field: it's either a percentage or it's not.
Gus wrote pretty much exactly what I was typing on my phone. Agreed.
On Sun, Feb 26, 2017, 5:11 PM GustavoFernandes notifications@github.com wrote:
Agreed - if you want sausage, you wouldn't expect your choices to be "check for pepperoni, un-check for not pepperoni" because sausage is not the opposite of pepperoni. It also doesn't account if you want pineapple as pizza topping.
However, in this case, I only see 2 ways of interpreting the value of the tip field: it's either a percentage or it's not.
— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/GustavoFernandes/order-splitter/issues/25#issuecomment-282592356, or mute the thread https://github.com/notifications/unsubscribe-auth/ADgur-3vWNuf453w64jDJ7dLlNYFuYsKks5rgfiVgaJpZM4La33L .
Upon further ponderment, I agree with you. Especially with a dollar sign in front...I reckon it's already pretty clear what the "unchecked" state indicates.
This made it into dev
before it was the default branch.