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

RouteCell refactor to display multiple combinations of directions #48

Merged
merged 8 commits into from
Jan 18, 2025

Conversation

Mihilih
Copy link
Contributor

@Mihilih Mihilih commented Jan 17, 2025

  • RouteCell can now display routes with any number of bus and walk directions in any order. (Closes Route shows a '0' bus line #44 )
  • Changed Transport class to have no sealed classes (created unnecessary complications in RouteScreen)
  • Added functionality to the add favorites button in the HomeScreen search bar
  • Added functionality to the button that switches the start and end locations in RouteScreen
Demo.1.mp4
Demo.2.mp4

Copy link

@zachseidner1 zachseidner1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great work Mihili! The refactor is so refreshing to see many many lines of code get deleted, the logic seems way simpler too. Anything that I said "Nit:" is optional to address, everything else I would like to be addressed. Although there are a lot of comments I want to emphasize that you did a great job! Most of them are minor lol.

) {
Text(
text = transport.lateness.text(),
fontFamily = sfProDisplayFamily,

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why are we using SF pro 😭 this is a copyrighted font and is NOT legal for us to use... I may bring this up in leads lol (you don't have to respond to this comment but just interesting to point out)

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall it is great to see sooooo much code getting deleted, beautiful stuff!

@Mihilih Mihilih requested a review from zachseidner1 January 17, 2025 09:50
Copy link

@zachseidner1 zachseidner1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yaaayyy amazing job! Just make the previews and helper Composables private and you should be good to go.

* @param transport The transport data to display in the route cell.
*/
@Composable
fun RouteCellHeader(transport: Transport) {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I just remembered all the @Preview functions and this helper function should be private

@Mihilih Mihilih merged commit 76e58a2 into main Jan 18, 2025
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.

Route shows a '0' bus line
2 participants