main ← dev/theme-disallow-groups
merged 11:28PM - 19 Jul 26 UTC
Further following on from bee1be8599c977f286a248e6d89fd5b73f398b42,
this brings… greater parity between theme settings and site settings.
This commit adds a new `disallowed_groups` field to theme and component
settings, which allows theme authors to specify groups that cannot be selected
by admins for a particular list type or object group type setting.
This is useful for cases where the group-based setting isn't usable
for a group like e.g. anonymous_users, no point allowing them for
a setting that requires a user to be logged in to take effect.
c.f. https://meta.discourse.org/t/granular-group-based-permissions-for-anonymous-and-logged-in-users/402273/18?u=martin
### List groups
With `disallowed_groups: "4|5"` specified (`logged_in_users` & `anonymous_users`)
<img width="734" height="450" alt="image" src="https://github.com/user-attachments/assets/ed8d7338-65fa-44e6-8dce-7073a87076e6" />
### Object groups
With `disallowed_groups: "4|5"` specified (`logged_in_users` & `anonymous_users`)
<img width="696" height="725" alt="image" src="https://github.com/user-attachments/assets/1a9103d4-cf44-4038-9d62-3838cb779b49" />