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

Have "favorite owners" and highlight crates by your favorite owners in crate lists #494

Open
Tracked by #9 ...
carols10cents opened this issue Dec 18, 2016 · 12 comments
Labels
A-frontend 🐹 C-enhancement ✨ Category: Adding new behavior or a change to the way an existing feature works E-help-wanted E-medium

Comments

@carols10cents
Copy link
Member

carols10cents commented Dec 18, 2016

Part of RFC 1824, rust-lang/rust#41616.

In the user research study we did, many people mentioned the reputation of an author as a factor they considered when deciding which crates to try.

We could do something like show how many other crates an author has, with the assumption that more crates = more experience = better quality, but that might not be true, and publishing lots of empty crates could gain you more reputation defined in this way.

We could distinguish members of any of the Rust teams, but there are lots of experienced people providing high quality crates that would not get this distinction.

Instead, I think it would be useful if each person who uses crates.io could add a crate author to their "favorite" authors, and any search that user does would show an indicator in the list of crates if the crate was written by a favorite author. The list of someone's favorite authors would be private so that each person could decide who they think is experienced, and this feature wouldn't get gamed or become a popularity contest.

What needs to be done

  • In a similar manner that you can "follow" crates today, add a button next to crate owners that's "favorite" or a star or something. When clicked, save a record in a table similar to the follows table that a particular user has saved that crate author. (I think this should be on crate owners, that is, the users or groups that are in crates.io's database and associated with a crate, not crate author information, that can be anything, read from Cargo.toml)

  • We'll need an "unfavorite" or "unstar" button too, to be able to remove an owner as someone in your favorite owners.

  • We should list all favorite owners, potentially with what they've been up to lately on crates.io, on your dashboard

  • When looking at any list of crates, we should query for whether any of a crate's owners are in the current user's favorites. This should get returned in the JSON from the API. When this metadata indicates one of a crate's owners is one of the current user's favorites, we should add a CSS class to the HTML and style that crate's row differently (and also indicate why it's styled differently somehow).

Please let me know if you have any questions, potential implementers!

@carols10cents carols10cents added A-ui C-enhancement ✨ Category: Adding new behavior or a change to the way an existing feature works labels Dec 18, 2016
@carols10cents carols10cents changed the title Have "favorite authors" and highlight crates by your favorite authors in crate lists Have "favorite owners" and highlight crates by your favorite owners in crate lists May 2, 2017
@PritiKumr
Copy link
Contributor

@carols10cents This is a very cool feature and I'd love to work on this.

@carols10cents
Copy link
Member Author

Awesome! Do you have any questions about getting started?

@PritiKumr
Copy link
Contributor

Hey @carols10cents

I think this should be on crate owners, that is, the users or groups that are in crates.io's database and associated with a crate, not crate author information, that can be anything, read from Cargo.toml

So in terms of the tables and associations, shouldn't we be creating a table, probably called favorite_users which will have references to the favorited user and the currentUser?

The other alternative is to associate the user with crate_owners records, which is what I was initially thinking. But then a crate owner can be removed from a crate. So this would be not be a good idea IMO.

What do you think?.

@carols10cents
Copy link
Member Author

Creating a favorite_users join table sounds right to me!

PritiKumr added a commit to PritiKumr/crates.io that referenced this issue Jun 14, 2017
@PritiKumr
Copy link
Contributor

potentially with what they've been up to lately on crates.io

@carols10cents could you elaborate more on what sort of things would be useful to show here? I was thinking we can show things like new crates, version updates, users / crates they follow. But then this would probably require us to have an activity feed system to implement this effectively, which could be a separate task on its own.

Wondering if we can just list the favorite users in the dashboard for now...

@carols10cents
Copy link
Member Author

Yeah, I think just having a list of favorite users on the dashboard (and the ability to unfavorite them there) is a great start!

@steverob
Copy link

steverob commented Jul 22, 2017

@carols10cents here are two options regarding the UI indication part of this issue -

Highlighted background:
2017-07-22_14-39-56_scrot

Gold crate name
2017-07-22_14-38-04_scrot

We could put a message either below or above the list, say - Highlighted crates are authored by your favorite crate owners - is that okay?

Another option I've been thinking is to place a star icon along with the text 'Favorite Owner' or just 'Owner' - so it would be like [star-icon] Owner or [star-icon] Fav Owner.. something like that maybe?

Looking forward to hearing your and others' thoughts here :)

@carols10cents
Copy link
Member Author

I think I like the highlighted background better!

We could put a message either below or above the list, say - Highlighted crates are authored by your favorite crate owners - is that okay?

Sounds great! Let's try the highlighted background option-- my concern with the star icon is that people would expect to be able to click on the star to favorite crates and see how many other people have starred it (something people have requested that we don't have plans to do so I don't want to get people's hopes up ;))

PritiKumr added a commit to PritiKumr/crates.io that referenced this issue Aug 1, 2017
@carols10cents
Copy link
Member Author

Possible bootstrapping strategy: github api for who you follow on github?

@steverob
Copy link

steverob commented Aug 19, 2017 via email

@BatmanAoD
Copy link
Member

@PritiKumr It looks like you made some progress on this; what was the status of your WIP branch as far as you remember? @steverob did you implement that background-highlighting logic somewhere?

@BatmanAoD
Copy link
Member

@carols10cents I've revived @PritiKumr's branch on my own fork and gotten it to at least build, but I don't really know what I'm doing with regard to the frontend. Since it's been two years since progress was made, do you think it would be appropriate to restore the help-wanted tag?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-frontend 🐹 C-enhancement ✨ Category: Adding new behavior or a change to the way an existing feature works E-help-wanted E-medium
Projects
None yet
Development

No branches or pull requests

5 participants