Visibility UI: selector, badges, and filtering #35
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Type
Feature
Lineage
Follow-up from spike #17 (
docs/visibility.md— Implementation Tickets). Depends on #30 (visibility column) and #32 (users + OmniAuth).Repo
ldraney/palinksUser Story
As Lucas
I want to see and control link visibility from the dashboard
So that I can manage what each audience sees
Context
The visibility column exists (from #30) but isn't wired into the UI. This ticket adds: a dropdown on the link form, visibility badges on cards (superadmin only), and
visible_to(current_role)filtering in the controller. Anonymous users see public links only, members see public+member, superadmin sees all.File Targets
app/controllers/links_controller.rb— wirevisible_to(current_role)into index, permit visibility paramapp/views/links/_form.html.erb— add visibility dropdown (superadmin only)app/views/links/_link.html.erb— add visibility badge (superadmin only)Feature Flag
Flag:
visibility_badgesType: role-scoped
Default: disabled
Visibility: superadmin only
Removal: after visibility system is proven stable (2+ weeks)
The filtering itself (which links you see) is NOT flagged — that's core behavior. Only the badge display is flagged for gradual rollout.
Acceptance Criteria
visible_to(current_role)Test Expectations
bundle exec rails testConstraints
visibility_badgesfeature flagChecklist
Related
project-palinks— project pagedocs/visibility.md— tier definitions and inventory