deltachat / deltachat-android

Email-based instant messaging for Android.
GNU General Public License v3.0
1.15k stars 148 forks source link

improve msg_action_button #3400

Closed adbenitez closed 1 week ago

adbenitez commented 3 weeks ago

close #3395

github-actions[bot] commented 3 weeks ago

To test the changes in this pull request, install this apk: 📦 app-preview.apk

r10s commented 3 weeks ago

fine for that "start..." button.

and also for the other buttons ("show full message", "download", "downloading", "download failed" ...) enlarging the click area is a good idea.

however, apart from that, we should not change the layout for the non-start-buttons - they are not primary buttons, and would get too much focus by that. eg. the "show full message" button is very often superfluous as we do not exactly know if the is needed or not, and in doubt, add the button. so putting additional focus on that is not needed, that is more a "more ..." button and should stay as is, layout wise

technically, to not make it too complicated, on can set the style also programatically afaik

(did not test or compile, just judging from the code :)

Hocuri commented 3 weeks ago

Looking forward to a better start button on webxdcs!

I agree with @r10s that for "show full message" it would be nicer to keep the layout as-is, though for me it's not that important. But the "Download" button is the primary button on this message and I do think that it would be nice to emphasize it similarly to the "Start" button. Not sure about the "Downloading..." and "Download failed" button because they are not primary buttons, but it's nicer to make them similar to the "Download" button in order to reduce flickering when the button changes from "Download" to "Downloading".

r10s commented 3 weeks ago

for he "show full message", i'd like to add that here are chats where every single message has these buttons, with, from the view of the user, mostly the same content showing there. this typically happens when chatting with someone not using delta chat, and renders things as text+html

yes, i agree that "Download" is a primary button for these bubbles bubble. but i may still look a bit weird, as there is just no other content in, same with having a primary button change title result in more flickering. therefore, as we anyway need two styles, still my suggestion to change the issue #3395 on point and only change the "start" button as proposed in the issue, not unrelated buttons.

Hocuri commented 3 weeks ago

+1 for "Show full message".

But I don't think that this looks weird:

Screenshot_20241030-164122

and, in fact, I think it looks a lot better than it did before.

r10s commented 3 weeks ago

i agree, it is fine :)

adbenitez commented 3 weeks ago

I will need to add a extra button then for show-full-message and hide one and show the other in dependency, I knew this was coming, just tried to see if I could get away with this without the extra work :sweat_smile:

r10s commented 3 weeks ago

yeah, it is probably easier to add a second button to the xml than to try to change the style programatically

adbenitez commented 3 weeks ago

this is the results, nicer indeed:

adbenitez commented 3 weeks ago

oops! I shared screenshot but forgot to push! please review now

github-actions[bot] commented 3 weeks ago

To test the changes in this pull request, install this apk: 📦 app-preview.apk