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

Create first levels in "Lists" #299

Merged
merged 1 commit into from
Nov 14, 2023
Merged

Create first levels in "Lists" #299

merged 1 commit into from
Nov 14, 2023

Conversation

MGaetan89
Copy link
Member

Pull request

Description

The goal of this PR is to add the first two levels of navigations in the "Lists" section of the demo app for TV:

  • TV Topics
    • All BUs
  • TV Shows
    • All BUs
  • TV Latest medias
    • All BUs
  • TV Livestreams
    • All BUs
  • TV Live center
    • All BUs
  • TV Live web
    • All BUs
  • Radio livestream
    • All BUs
  • Radio Latest medias
    • All radio channels
  • Radio Shows
    • All radio channels

Video

Screen_recording_20231113_125515.webm

Changes made

  • Move some code from the mobile demo app to the shared module, so it can be used in the TV demo app
  • Display each item as an actionnable card that can be selected to go to the next level

Checklist

  • Your branch has been rebased onto the main branch.
  • APIs have been properly documented (if relevant).
  • The documentation has been updated (if relevant).
  • New unit tests have been written (if relevant).
  • The demo has been updated (if relevant).
  • All pull request status checks pass.

@MGaetan89 MGaetan89 linked an issue Nov 13, 2023 that may be closed by this pull request
@MGaetan89 MGaetan89 force-pushed the 293-create-lists-section branch from 6f63a92 to 61f697c Compare November 13, 2023 15:40
Comment on lines +110 to +124
composable(
route = ContentList.TvTopics.route,
arguments = listOf(
navArgument("bu") { type = NavType.StringType }
)
) {
val contentList = ContentList.TvTopics.parse(it)

BackHandler {
navController.popBackStack()
}

// TODO Integrate content (https://github.com/SRGSSR/pillarbox-android/issues/298)
Text(text = contentList.toString())
}
Copy link
Member

Choose a reason for hiding this comment

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

I notice that this code is used multiple times. Can we factorize it in some way?

Copy link
Member Author

Choose a reason for hiding this comment

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

I hope so. For now, I've just reused what @StaehliJ created for the mobile demo app.
I'll investigate this more while working on #298, as I'll address these TODOs there 🙂

@MGaetan89 MGaetan89 merged commit ac9e954 into main Nov 14, 2023
4 checks passed
@MGaetan89 MGaetan89 deleted the 293-create-lists-section branch November 14, 2023 07:50
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.

Integrate first two levels of "Lists"
2 participants