Closed jancborchardt closed 10 months ago
This indeed looks way better.
Do you want to have this on all dialogs? What about dialogs with three items?
Yes, it’s probably good to have it on all dialogs! Especially because the screenshots you show illustrate how currently the primary action ("Yes" for the left one and "OK" for the right one) is not highlighted at all.
And any cancel action (like "No" for the left one" and "Cancel" for the right one) maybe is even better as a text-only link without outline, so only the primary one is highlighted. In the case of deletion, it would be that "Yes" is primary, "Local only" is secondary (outlined) and "No" is cancel (text-only). What do you think?
Looking at the material guidelines text-only links are preferred for dialogs. While we could still have them colored differently for primary/secondary/action. What do you think? Having "primary buttons" on dialogs also seems very bold-styled to me and a bit heavy. Also checking the Google apps I am not aware of any app using buttons with boders or even filled ones but only borderless/text-only buttons.
https://material.io/design/components/buttons.html --> Text button
https://material.io/design/components/buttons.html --> Placement
As @AndyScherzinger said, text-only buttons should be used in materials design, and they are also not colored. But then we are already very close to the guidelines…? :thinking:
But then we are already very close to the guidelines…? :thinking:
As for dialogs, yes we are material design compliant :)
As for the other buttons we are material design 1.0 compliant while all the screenshot now show the material design "2.0" updated guidelines and that needs some (minor) work.
Yeah, in the guidelines they say text links. But it does seem strange to not directly have the primary action highlighted, don't you think? At least one primary should be a bit highlighted (whether it be by looking like a button or else).
At least one primary should be a bit highlighted
Though it is not really MaterialDesign, I like the idea.
Though it is not really MaterialDesign, I like the idea.
Me too! :+1:
To sum things up
Any idea how we can show secondary actions in text-links since grey might well be mistaken for disabled-state? Is black to heavy or would that work in your opinion?
Any idea how we can show secondary actions in text-links since grey might well be mistaken for disabled-state? Is black to heavy or would that work in your opinion?
@AndyScherzinger the secondary actions are fine like they are, with the primary color as text color. :)
@AndyScherzinger the secondary actions are fine like they are, with the primary color as text color. :)
Okay :smiley: :+1:
(Basically just like in the first screenshot I posted, minus the grey border around the button. :)
(Basically just like in the first screenshot I posted, minus the grey border around the button. :)
While we argued that actions in dialogs would be text-only buttons so the primary actions wouldn't have the filling which is displayed in your original screenshot :) Hence the question
@AndyScherzinger ah ok, I thought by
move to the "new", material design 2.0 styling for "bold"-buttons
you meant the filled buttons – sorry I misread. Is there a documentation or screenshot for that? Is it simply just bolder text for the primary action? If that’s the standard then I’m fine with trying that out. :) Important is that the primary action looks sufficiently different from the others.
Maybe it is better to have some visual image snippets to show, @jancborchardt. I think this makes talking about it way easier.
These are from material.io: high emphasis: real button with primary background medium emphasis: real button with white background, primary text color low emphasis: text "button" with primary color
So if we use "low emphasis" all "text buttons" we can have the primary bottom with our primary color. But what about the other one? (keep in mind that there is also black/white (which then is grey for buttons) as primary color)
This is exactly the point I am struggling with and not having come with a good solution. According to Material Design the dialogs should use "low emphasis" all "text buttons" buttons which then means the users can't visually distinguish primary/secondary/tertiary actions since the text buttons all look the same. We can distinguish primary/secondary/etc. with "normal buttons" like in the screenshots posted while that is not the type of button styling Material Design proposes for Dialogs. :/
I also think choosing different colors for primary/secondary text buttons should be fine while it is like @tobiasKaminsky said it's tricky to pick the secondary action color. Even then we will still have an accessibility issue since this might still be hard to discover for colorblind users :/
I also think choosing different colors for primary/secondary text buttons should be fine while it is like @tobiasKaminsky said it's tricky to pick the secondary action color. Even then we will still have an accessibility issue since this might still be hard to discover for colorblind users :/
Yes, exactly. But even apart from that, this is not only about people who have difficulties distinguishing color. It is very difficult in general to distinguish by color alone, that’s why the form should also come in. (This is very important. ;) Especially on mobile, you don’t really want to spend time thinking about which action to pick. Highlighting the most likely path is crucial and takes cognitive load from people.)
That’s why I think a good start for us would be basically it’s like it is now, with only one step improved and that is that the primary action styled as a real button. All others are text only.:
When the primary color is grey, the button should also be grey. At a threshold of #555
grey in the web interface we do not go brighter with the button or other elements and keep that value. cc @juliushaertl
This is how we should do it for Android too.
I am fine with this idea :+1: Let us see how it works out.
Yeah, I am also fine with this approach. It might not be fully material design for dialogs but I agree with @jancborchardt argument that it is about cognitive load and that this is actually not solved properly in the material design guidelines. :+1:
@jancborchardt please check together with @ZetaTom (who will start again Monday) and create a list of all things that needs to be changed, then Tom shall estimate it.
This is an overview of the changes that need to be made. These suggestions are based on the guidelines provided by the current Material Design and on the recommendations from @jancborchardt.
https://m3.material.io/components/dialogs/guidelines#befd7f4d-1029-4957-b1b5-da13fc0bbf3c
SyncedFolderPreferencesDialogFragment
): possibly extend to full-screen dialogue
https://developer.android.com/design/ui/mobile/guides/home-screen/notifications
FileDetailSharingFragment
)@ZetaTom @tobiasKaminsky @jancborchardt
After updating components we should also update these.
Update "styles.xml" parent tags to use the "M3" instead of "MaterialComponents". e.g parent="@style/ThemeOverlay.MaterialComponents.BottomSheetDialog" to parent="@style/ThemeOverlay.Material3.BottomSheetDialog"
Upgrade the "com.google.android.material:material" dependency.
Set the API Level to 34 for the latest material design library compatibility.
From the Material buttons page, this fits our case nicest:
(Copied over from discussion at https://github.com/nextcloud/android/pull/2778#issuecomment-406193365)