Skip to content
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

Payment method auto-capture boolean provides 3 options to the user #3697

Closed
seand7565 opened this issue Jul 9, 2020 · 8 comments
Closed

Comments

@seand7565
Copy link
Contributor

The value of auto-capture is a boolean, but has three possible values in the following image: false, yes, and no.

image

IMO we should use true and false instead of yes and no, but we could also set the value of app default to yes and no - as long as we're consistent with our options.

@aldesantis
Copy link
Member

@seand7565 hmm, not sure this is an actual issue. The first option corresponds to nil, which tells Solidus to use the application's default auto_capture setting. In this case, that setting is false, so it's displayed next to "Use App Default" for the user's convenience.

@seand7565
Copy link
Contributor Author

@aldesantis Right, behind the scenes the value is either true or false, but the dropdown indicates to the user that there are 3 possible values - false, yes or no. As a user, I'd expect to see something like this:
image
Or this:
image

(I prefer the first option, but maybe that's just me)

No problem with the logic, just nitpicking at the text in the provided options. 😛

@aldesantis
Copy link
Member

Ah, sorry, didn't realize you were referring to the label! I think the best option is to use yes/no consistently, since true/false only makes sense for developers.

@jarednorman
Copy link
Member

Yeah, for consistency I think the ideal options are probably:

  • Use App Default (No)
  • Yes
  • No

@michaelmichael
Copy link
Contributor

I believe I fixed this in #3703 according to the consensus here.

  • Use App Default (No)
  • Yes
  • No

However, I wonder if it would be better to remove the redundant option from the dropdown to reduce cognitive overhead.

While having the third option makes sense to the store's developer, it could be confusing to users. Why have three answers to a yes or no question? The user may wonder if there is any difference between "Use App Default (No)" and "No"—At least, I wondered this when first setting up payment methods.

So, my pull request as submitted makes the verbiage more consistent. That said, I could update it if others agree that reducing it to just two options is preferable, as in:

  • Use App Default (No)
  • Yes

To take it one step further, I think something like the following would be easiest to scan and parse:

  • No (Default)
  • Yes

@aldesantis
Copy link
Member

@michaelmichael when you select "Use App Default", what happens under the hood is that the value of the preference will be set to nil, and the actual logic will change depending on the current store default. When you select Yes/No, the value of the preference will be fixed and will not change with the store's default preference. So choosing "No" and "Use App Default (No)" will actually lead to two different behaviors. Hope I explained it clearly, let me know if you have any questions!

@michaelmichael
Copy link
Contributor

@aldesantis Makes perfect sense 👍

@seand7565
Copy link
Contributor Author

Yep, that covers it! Thanks so much @michaelmichael

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants