-
Notifications
You must be signed in to change notification settings - Fork 6
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
List projects on homepage #16
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sweet!! Thanks for adding this!
From the screenshot, I think this could benefit from some style tweaks. The margin is a bit disproportionate; probably should be larger between the projects and smaller between the project name and branch. This is fine in a secondary pass.
src/UnisonLocal/Page/HomePage.elm
Outdated
} | ||
, projectNames | ||
|> List.map | ||
(fetchProjectBranches FetchProjectBranchesFinished |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This seems fine right now (especially since its unlikely for there to be large number of projects and branches), but it'd be cool if the backend could support fetching both projects and branches in one go instead of an extra request for each branch, cc @ChrisPenner
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah that makes sense, this'll be fine for now (esp. since all of these requests are just to localhost)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🎉
Problem
When opening the homepage you are presented with an instruction to run the
ui
command in a project in UCM. This message can be confusing if you navigate to the homepage or if you have started a headless instance of UCM and connected to it with the development server.Solution
This solution lists the projects and each branch on the homepage for easier navigation.
Caveats/Notes
It was decided together with @hojberg to not use the
ProjectListing
component since it takes a Unison Share project as a parameter, but local projects are of another (simpler) type. There might be a way to put together these two project concepts, but it is out of scope for this PR.