Skip to content

Comments

UserRow: handle current user#88

Merged
danirabbit merged 9 commits intomainfrom
danirabbit/dry-userrow
Jul 4, 2025
Merged

UserRow: handle current user#88
danirabbit merged 9 commits intomainfrom
danirabbit/dry-userrow

Conversation

@danirabbit
Copy link
Member

@danirabbit danirabbit commented Mar 4, 2025

Fixes #125

Have UserRow handle the case where its user is the current user instead of duplicating all that code into another widget

@danirabbit danirabbit requested a review from a team March 4, 2025 05:22
@danirabbit danirabbit marked this pull request as ready for review March 4, 2025 05:22
Copy link
Contributor

@jeremypw jeremypw left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Everything works as before afaict. There is a small oddity in that the guest avatar color changes depending on whether they are logged in or not whereas normal users (with no loadable icon) the color is fixed and apparently random (not their accent color). Not sure if this is intended.

There is some repeated code for removing color classes.

Conflict resolution required.

@danirabbit
Copy link
Member Author

There is a small oddity in that the guest avatar color changes depending on whether they are logged in or not

@jeremypw can you elaborate on where you're seeing that? In the list of logged in users, in the header, when logged in as another user, on the main settings page, etc? I'm not seeing a difference here.

whereas normal users (with no loadable icon) the color is fixed and apparently random

Adw.Avatar bases its color on a hash of the name supplied to it. I agree it should use their accent color, but I think that's outside the scope of this branch

There is some repeated code for removing color classes

I'm not sure it's worth trying to do anything about that at the moment. In GTK4 it'll be a single line

@danirabbit danirabbit requested a review from jeremypw April 28, 2025 19:10
@jeremypw
Copy link
Contributor

jeremypw commented Jul 4, 2025

Sorry this fell off the radar. Looking at it again I cannot reproduce that color issue I reported before. I also noticed that it fixed an issue I noticed in the master branch. I'll approve this now.

@danirabbit danirabbit merged commit fda8715 into main Jul 4, 2025
4 checks passed
@danirabbit danirabbit deleted the danirabbit/dry-userrow branch July 4, 2025 22:42
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

Successfully merging this pull request may close these issues.

Guest account always shows as logged out

3 participants