Users discussed improving the UX of adding permissions in Discourse, noting that it’s easy to forget to click ‘Add Permission’ before saving. Mark_Walkom and Falco suggested either a reminder for unapplied permissions or auto-applying them on save. simon cautioned against auto-application due to potential errors, recommending confirmation instead — perhaps by changing the ‘Add Permission’ button to a green checkmark. mipe proposed a simpler UI fix: renaming the button to ‘+’ and aligning it with the combo-boxes, which they implemented in a PR https://github.com/discourse/discourse/pull/6999. sam raised concerns about localization and layout, suggesting a flexbox to avoid overlap. awesomerobot reviewed the PR, approved the ‘+’ icon for easier translation, and noted that position: absolute was unnecessary. mipe adjusted the button’s vertical alignment with position: relative and added margin. The PR was merged by awesomerobot, with a note that a broader alignment fix is planned. The change improves discoverability without altering core logic.
When editing permissions, it can be easy to add a new set but forget to click the Add Permission to apply it before closing the edit box (don’t judge me! :p).
Would it be possible to have either a reminder - saying Unapplied Permissions or similar - or just apply the new permissions when clicking Save Category?
I have forgotten to to this as well, but making a mistake by adding the wrong group to category permissions could have serious consequences. I think having requiring confirmation here is a good idea.
Without a confirmation, there would need to be some way to dismiss a permission after the Edit Permissions button has been clicked.
I wanted to contribute and looked at this issue, I think it would be good enough if the design could be changed: By renaming the “Add Permission” Button into just “Add” and moving it to the same line as the combo-boxes:
It would be intuitive to click, rather than changing the logic (which would involve checking if something has changed in the combo-boxes and then showing a Message).
Let me know what you think
I worry that this will not fit in some non English locales. maybe if its in some magic flexbox it would work. @awesomerobot can you have a very quick look at this.
Thanks a lot for the review, I changed it accordingly and added a right margin to the permission-selector.
In order to make the add-button align with the combo-boxes, I did the following: .add-permission { position: relative; top: 0.1em; }
otherwise the button would float a few pixels higher then the combo-boxes.
Open for suggestions if there’s a better way to do it