Skip to content

Network preference for the order of communities in the dashboard and dropdown - #2143

Draft
MoshiKoi wants to merge 10 commits into
developfrom
MoshiKoi/community-order-setting
Draft

Network preference for the order of communities in the dashboard and dropdown#2143
MoshiKoi wants to merge 10 commits into
developfrom
MoshiKoi/community-order-setting

Conversation

@MoshiKoi

@MoshiKoi MoshiKoi commented Aug 21, 2026

Copy link
Copy Markdown
Member

First take at #1323, testing and feedback welcome

This PR adds a new preference type for the community preference, as well as a separate "block preference" for styling purposes since it didn't make much sense trying to cram it into the horizontal layout the other preferences use. The styling is very much a work in progress, but it is functional right now.

image

You can reorder the communities by dragging. I pulled in JQuery-UI for this - not entirely sure if it's worth bringing it in as a dependency, but it can be replaced if needed. I have switch to SortableJS to avoid depending on jQuery.

Might try to also implement "collapsed" communities (#1993). Not sure if that has any real added value if it just sends communities to the bottom since users can do that anyway, but it might be useful as a foundation for later work if we want users to, for instance, be able to set up an email subscription of "posts from focused communities" or similar mechanism.

@MoshiKoi
MoshiKoi force-pushed the MoshiKoi/community-order-setting branch from 52f17d6 to 3a556aa Compare August 21, 2026 06:58
@codecov

codecov Bot commented Aug 21, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 75.00000% with 2 lines in your changes missing coverage. Please review.
✅ Project coverage is 81.11%. Comparing base (1ab1ddf) to head (60c9c99).

Files with missing lines Patch % Lines
app/controllers/application_controller.rb 0.00% 1 Missing ⚠️
app/models/community.rb 85.71% 1 Missing ⚠️
Additional details and impacted files
Components Coverage Δ
controllers 76.98% <0.00%> (ø)
helpers 85.47% <ø> (ø)
jobs 77.43% <ø> (ø)
models 93.22% <85.71%> (-0.03%) ⬇️
tasks 61.11% <ø> (ø)
scripts ∅ <ø> (∅)

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@trichoplax

trichoplax commented Aug 21, 2026

Copy link
Copy Markdown
Contributor

I like the draggable handles. I think for many people that will be the easiest way to rearrange the communities. Could we keep the handles and also add up and down buttons (that shift that community one place in that direction)?

Some people may find up and down buttons more convenient, but also some people cannot drag (for various reasons).

See Dragging Movements accessibility guidance.

If both draggable handles and up and down buttons take up too much space, there's also the possibility of having up and down buttons only appear when a draggable handle is clicked/tapped rather than dragged. Personally I'd prefer up and down buttons that are always visible to aid discoverability.

@MoshiKoi
MoshiKoi force-pushed the MoshiKoi/community-order-setting branch from 8ff0145 to f397525 Compare August 21, 2026 11:36
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