Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow multiple ways to sort the stream list #16

Open
rht opened this issue Dec 13, 2019 · 10 comments
Open

Allow multiple ways to sort the stream list #16

rht opened this issue Dec 13, 2019 · 10 comments

Comments

@rht
Copy link
Contributor

rht commented Dec 13, 2019

Currently, the stream list is sorted by the number of topics. This is the use case of Lean, but other project may prefer different sorting method, e.g. Rust prefers sorting alphabetically.

This can be solved dynamically by adding js code to the index.html output.

See #2 (comment) for context of the discussion.

@showell
Copy link
Contributor

showell commented Dec 20, 2019

In #19 I at least extracted some helpers for sorting during the build, but I agree that the best solution here is probably just some client-side JS to do the most obvious sorts (by count, by name, by recency, etc.)

We'd want sorting in all three pages:

  • list of streams
  • list of topics (for single stream)
  • list of messages (for single topic)

@showell
Copy link
Contributor

showell commented Apr 9, 2020

@rht Do you have any interest in working on this? Or maybe try to recruit on of the GSOC folks to play with it?

@rht
Copy link
Contributor Author

rht commented Apr 10, 2020

I can do this later this weekend. Regarding with GSoC, isn't it already too late to specify a zulip-archive project in https://github.com/zulip/zulip/blob/master/docs/overview/gsoc-ideas.md?

@showell
Copy link
Contributor

showell commented Apr 10, 2020

For GSoC, there might be students who just want to work on this for fun, and maybe to help their chances of being admitted. It's too late to name projects, but I think there's still time for them to improve their chances for admission via contributions, correct?

@Rik44444
Copy link

hi, has this topic been solved? Is there a way to set the sorting of topics and streams now, both at organization level (default) and at user level?

@rht
Copy link
Contributor Author

rht commented Jun 27, 2023

You can modify

return sorted(streams, key=lambda s: len(streams[s]["topic_data"]), reverse=True)
to the sorting mechanism of your choice.

@Rik44444
Copy link

You can modify

return sorted(streams, key=lambda s: len(streams[s]["topic_data"]), reverse=True)

to the sorting mechanism of your choice.

thanks! We use the Zulip Cloud, we don't self-host. Is there a place in the Settings there where we can modify this, both:

  • the default sorting on an organization level and
  • sorting on a user level (preferable even on a stream level)

?

@rht
Copy link
Contributor Author

rht commented Jun 27, 2023

This repo is specifically for archival tool for web-public streams. You should raise in the main repo instead: #10205.

@rht
Copy link
Contributor Author

rht commented Jun 27, 2023

I meant zulip/zulip#10205.

@Rik44444
Copy link

OK :) thanks!

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

No branches or pull requests

3 participants