Skip to content

Conversation

@gianniguida
Copy link
Collaborator

@gianniguida gianniguida commented Aug 25, 2025

Fixes #0000
Improve poll setting UX and always allow admins to see vote counts and voters

Changes proposed in this pull request:

  • Reflect mutually exclusive public poll and hide votes settings in UI by disabling the other setting when one is enabled
  • Improve clarity of public poll and hide votes setting labels in UI
  • Include admin check in vote count visibility logic. Always allow admins to see the vote result and list of voters

Reviewers should focus on:

Screenshot
image
image

Confirmed

  • Frontend changes: tested on a local Flarum installation.
  • Backend changes: tests are green (run composer test).

Required changes:

@gianniguida gianniguida requested a review from a team as a code owner August 25, 2025 10:25
@dsevillamartin
Copy link
Member

dsevillamartin commented Aug 26, 2025

always allow admins to see vote counts and voters

Are there use cases were we wouldn't want this ability? I know the data is technically still available in DB, but admins don't necessarily have access to that.

Reflect mutually exclusive public poll and hide votes

Should these be mutually exclusive? From my understanding while reading (and vaguely from making updates to this ext), seeing who has voted != seeing vote results. Vote results to me means % -- eg. what option wins a poll. Who voted means what users specifically chose each option. These are not mutually exclusive. Who voted does allow seeing vote results (as you can calculate with that data).

The option to hide until poll ends, to me, is just to keep the results anonymous (and who voted, if the user can see this) until after poll ends so they're not influenced. "Allow everyone to see who voted" in this situation seems to me like it should just allow this functionality once the poll ends if the hide option is chosen as well, but that hide doesn't necessarily mean individual votes are visible at the end. Unless I'm misunderstanding this.

Note: I'm not necessarily talking about what the current functionality is (perhaps more what it should be if not), but simply by reading these options, I'm still not sure as to why they're mutually exclusive.

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.

3 participants