Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
31 commits
Select commit Hold shift + click to select a range
7f36142
ci: post releases to Discord
Priveetee Nov 16, 2026
92c7277
ci: rename the Discord release bots
Priveetee Nov 16, 2026
f41de9c
feat: let the home show recommendations as one grid or by category
Priveetee Nov 17, 2026
373c5b8
test: cover the home grid and category layouts
Priveetee Nov 17, 2026
0e5c3c6
feat: persist the server Twitch capability
Priveetee Nov 17, 2026
71ef8ac
feat: call the Twitch routes of the server
Priveetee Nov 17, 2026
c0b28e8
feat: read Twitch lives, past broadcasts and clips as videos
Priveetee Nov 17, 2026
0380735
feat: play Twitch lives, past broadcasts and clips
Priveetee Nov 17, 2026
85364a2
feat: add a Live tab with the Twitch lives of the moment
Priveetee Nov 17, 2026
4a3780d
feat: show how many people watch a live
Priveetee Nov 17, 2026
9f672fe
fix: keep only playback on Twitch watch pages
Priveetee Nov 17, 2026
6279807
test: move the Twitch migration test to its own file
Priveetee Nov 17, 2026
cab8598
fix: play Twitch clips from the instance origin
Priveetee Nov 17, 2026
cd0792f
feat: read the Twitch chat of a live
Priveetee Nov 17, 2026
4067262
feat: open Twitch channel pages with their videos and clips
Priveetee Nov 17, 2026
4e6b524
feat: browse Twitch categories and search channels
Priveetee Nov 17, 2026
d2cf732
feat: show Twitch polls and pinned messages in the chat
Priveetee Nov 17, 2026
9605c83
feat: show the game chapters of Twitch past broadcasts
Priveetee Nov 17, 2026
f1c4f3b
fix: say a Twitch stream has ended when its channel is offline
Priveetee Nov 17, 2026
55dd3de
feat: count watched videos with the profile's threshold
Priveetee Nov 18, 2026
9a72c5b
feat: replay the chat of Twitch past broadcasts
Priveetee Nov 18, 2026
de57810
fix: play Bilibili and NicoNico lives from their own playlist
Priveetee Nov 18, 2026
1b64e98
feat: start a Twitch live over from its recording
Priveetee Nov 18, 2026
5cb7f46
feat: connect a Twitch account from linked accounts with a device code
Priveetee Nov 18, 2026
793088c
feat: follow Twitch channels with the linked account
Priveetee Nov 18, 2026
1635a2e
feat: send Twitch chat messages and vote in polls
Priveetee Nov 18, 2026
adfb971
fix: keep the app bars on the Live tab
Priveetee Nov 18, 2026
3ff4980
fix: keep bottom tab labels on one line
Priveetee Nov 18, 2026
206761f
fix: keep the bottom bar on Twitch channel pages
Priveetee Nov 18, 2026
15b658b
fix: mention Twitch in the linked accounts summary
Priveetee Nov 18, 2026
fd2347d
chore: release 1.14.0-beta.1
Priveetee Nov 18, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
44 changes: 44 additions & 0 deletions .github/workflows/discord-app-release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
# For app repos (TypeType-Android, TypeType-IOS, TypeType-TV, TypeType-tvOS).
# Pre-releases (-beta.N, -rc.N) go to #🧪・releases-rc, stable releases go to #🚀・releases-main,
# with the release notes. Needs the secrets DISCORD_WEBHOOK_RC and DISCORD_WEBHOOK_MAIN.
name: Discord release notify

on:
release:
types: [published]

permissions:
contents: read

jobs:
notify:
runs-on: ubuntu-latest
steps:
- name: Post to Discord
env:
WEBHOOK_RC: ${{ secrets.DISCORD_WEBHOOK_RC }}
WEBHOOK_MAIN: ${{ secrets.DISCORD_WEBHOOK_MAIN }}
PRERELEASE: ${{ github.event.release.prerelease }}
TAG: ${{ github.event.release.tag_name }}
RNAME: ${{ github.event.release.name }}
URL: ${{ github.event.release.html_url }}
BODY: ${{ github.event.release.body }}
REPO: ${{ github.repository }}
run: |
set -euo pipefail
if [ "$PRERELEASE" = "true" ]; then
WEBHOOK="$WEBHOOK_RC"; BOT="The Lab TV"; EMOJI="🧪"; COLOR=15105570; INTRO="Beta build, might break, have fun (・ω・)"
else
WEBHOOK="$WEBHOOK_MAIN"; BOT="Rocket TV"; EMOJI="🚀"; COLOR=5763719; INTRO="New release (。•̀ᴗ-)✧"
fi
[ -n "$WEBHOOK" ] || { echo "webhook secret not set"; exit 0; }
TITLE="${EMOJI} ${RNAME:-${REPO#*/} ${TAG}}"
jq -n \
--arg title "$TITLE" \
--arg url "$URL" \
--arg desc "$(printf '%s\n\n%s' "$INTRO" "${BODY:-}" | cut -c1-3900)" \
--argjson color "$COLOR" \
--arg bot "$BOT" \
'{username: $bot, embeds: [{title: $title, url: $url, description: $desc, color: $color}]}' \
> payload.json
curl -fsS -H "Content-Type: application/json" -d @payload.json "$WEBHOOK"
5 changes: 3 additions & 2 deletions app/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ android {

defaultConfig {
applicationId = "dev.typetype.android"
versionCode = 11119
versionName = "1.13.0-beta.4"
versionCode = 11121
versionName = "1.14.0-beta.1"
}

signingConfigs {
Expand Down Expand Up @@ -105,6 +105,7 @@ dependencies {
implementation(project(":feature:setup"))
implementation(project(":feature:channel"))
implementation(project(":feature:library"))
implementation(project(":feature:live"))
implementation(project(":feature:subscriptions"))
implementation(project(":feature:settings"))
implementation(project(":feature:player"))
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,10 @@ import androidx.navigation.compose.rememberNavController
import dev.typetype.android.core.ui.navigation.ChannelRoute
import dev.typetype.android.core.ui.navigation.HomeRoute
import dev.typetype.android.core.ui.navigation.LibraryRoute
import dev.typetype.android.core.ui.navigation.LiveRoute
import dev.typetype.android.core.ui.navigation.ShortsRoute
import dev.typetype.android.core.ui.navigation.SubscriptionsRoute
import org.junit.Assert.assertTrue
import org.junit.Rule
import org.junit.Test

Expand Down Expand Up @@ -49,4 +52,26 @@ class TopLevelNavigationTest {
}
composeRule.onNodeWithText("Subscriptions").assertExists()
}

@Test
fun everyTabIsRecognizedOnItsOwnDestination() {
composeRule.setContent {
controller = rememberNavController()
NavHost(controller, startDestination = HomeRoute) {
composable<HomeRoute> { Text("Home") }
composable<ShortsRoute> { Text("Shorts") }
composable<SubscriptionsRoute> { Text("Subscriptions") }
composable<LiveRoute> { Text("Live") }
composable<LibraryRoute> { Text("Library") }
}
}
topLevelTabs.forEach { tab ->
composeRule.runOnIdle {
controller.navigateTopLevel(tab.route, controller.currentDestination?.route)
}
composeRule.runOnIdle {
assertTrue(tab.route.toString(), controller.currentDestination.matchesRoute(tab.route))
}
}
}
}
13 changes: 13 additions & 0 deletions app/src/main/java/dev/typetype/android/AppNavHost.kt
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
package dev.typetype.android

import dev.typetype.android.core.ui.navigation.LiveRoute
import dev.typetype.android.core.ui.navigation.TwitchChannelRoute
import dev.typetype.android.feature.live.TwitchChannelRouteScreen
import dev.typetype.android.feature.live.TwitchChannelViewModel
import dev.typetype.android.feature.live.LiveRouteScreen
import dev.typetype.android.feature.live.LiveViewModel
import androidx.compose.animation.AnimatedContentTransitionScope
import androidx.compose.animation.core.tween
import androidx.compose.runtime.Composable
Expand Down Expand Up @@ -122,6 +128,7 @@ fun AppNavHost(
avatarUrl = avatarUrl,
avatarFallbackLetter = avatarFallback,
showShorts = !deArrowSettings.hideShorts,
showLive = currentServer?.twitchEnabled == true,
accessiblePlayerControls = appPreferences.playerAccessibleControlsEnabled,
onPlayVideo = onPlayVideo,
onOpenChannel = onOpenChannel,
Expand Down Expand Up @@ -171,6 +178,12 @@ fun AppNavHost(
onOpenChannel = onOpenChannel,
)
}
composable<LiveRoute> {
LiveRouteScreen(viewModel = hiltViewModel<LiveViewModel>(), onPlayVideo = onPlayVideo, onOpenChannel = onOpenChannel)
}
composable<TwitchChannelRoute> {
TwitchChannelRouteScreen(viewModel = hiltViewModel<TwitchChannelViewModel>(), onPlayVideo = onPlayVideo)
}
composable<SearchRoute> {
SearchRouteScreen(
onNavigateBack = { navController.popBackStack() },
Expand Down
20 changes: 16 additions & 4 deletions app/src/main/java/dev/typetype/android/AppNavigation.kt
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ import androidx.compose.foundation.layout.size
import androidx.compose.foundation.layout.systemBars
import androidx.compose.foundation.layout.width
import androidx.compose.foundation.layout.windowInsetsPadding
import androidx.compose.foundation.text.TextAutoSize
import androidx.compose.material.icons.Icons
import androidx.compose.material.icons.filled.Search
import androidx.compose.material.icons.filled.Settings
Expand Down Expand Up @@ -51,6 +52,7 @@ import androidx.navigation.NavDestination.Companion.hasRoute
import dev.typetype.android.core.ui.navigation.LibraryLandingRoute
import dev.typetype.android.core.ui.navigation.HomeRoute
import dev.typetype.android.core.ui.navigation.LibraryRoute
import dev.typetype.android.core.ui.navigation.LiveRoute
import dev.typetype.android.core.ui.navigation.ShortsRoute
import dev.typetype.android.core.ui.navigation.SubscriptionsRoute
import dev.typetype.android.core.ui.components.ProfileAvatar
Expand All @@ -65,11 +67,12 @@ internal val topLevelTabs = listOf(
TopLevelTab(HomeRoute, R.string.tab_home, R.drawable.ic_home),
TopLevelTab(ShortsRoute, R.string.tab_shorts, R.drawable.ic_shorts),
TopLevelTab(SubscriptionsRoute, R.string.tab_subscriptions, R.drawable.ic_subscriptions),
TopLevelTab(LiveRoute, R.string.tab_live, R.drawable.ic_live),
TopLevelTab(LibraryRoute, R.string.tab_library, R.drawable.ic_library),
)

internal fun visibleTopLevelTabs(showShorts: Boolean): List<TopLevelTab> =
topLevelTabs.filter { showShorts || it.route != ShortsRoute }
internal fun visibleTopLevelTabs(showShorts: Boolean, showLive: Boolean = false): List<TopLevelTab> =
topLevelTabs.filter { (showShorts || it.route != ShortsRoute) && (showLive || it.route != LiveRoute) }

@OptIn(ExperimentalMaterial3Api::class)
@Composable
Expand Down Expand Up @@ -168,8 +171,16 @@ internal fun AppBottomBar(
onClick = { onTabClick(tab) },
icon = { Icon(painterResource(tab.iconRes), contentDescription = null,
modifier = Modifier.size(if (expanded) 32.dp else 24.dp)) },
label = { Text(stringResource(tab.labelRes), style = if (expanded)
MaterialTheme.typography.titleSmall else MaterialTheme.typography.labelMedium) },
label = {
val style = if (expanded) MaterialTheme.typography.titleSmall else MaterialTheme.typography.labelMedium
// Five tabs leave little width: a long label shrinks instead of wrapping.
Text(
text = stringResource(tab.labelRes),
style = style,
maxLines = 1,
autoSize = TextAutoSize.StepBased(minFontSize = 9.sp, maxFontSize = style.fontSize),
)
},
)
}
}
Expand Down Expand Up @@ -234,6 +245,7 @@ internal fun NavDestination?.matchesRoute(route: Any): Boolean {
HomeRoute -> destination.hasRoute<HomeRoute>()
ShortsRoute -> destination.hasRoute<ShortsRoute>()
SubscriptionsRoute -> destination.hasRoute<SubscriptionsRoute>()
LiveRoute -> destination.hasRoute<LiveRoute>()
LibraryRoute -> destination.hasRoute<LibraryRoute>() ||
destination.hasRoute<LibraryLandingRoute>()
else -> false
Expand Down
5 changes: 4 additions & 1 deletion app/src/main/java/dev/typetype/android/AppShell.kt
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ import dev.typetype.android.core.ui.navigation.PodcastRoute
import dev.typetype.android.core.ui.navigation.PublicPlaylistRoute
import dev.typetype.android.core.ui.navigation.SearchRoute
import dev.typetype.android.core.ui.navigation.ShortsRoute
import dev.typetype.android.core.ui.navigation.TwitchChannelRoute
import dev.typetype.android.core.ui.player.PlayerHostController
import dev.typetype.android.core.ui.player.PlayerHostTarget
import dev.typetype.android.feature.player.components.LocalMediaController
Expand Down Expand Up @@ -76,6 +77,7 @@ fun AppShell(
avatarUrl: String? = null,
avatarFallbackLetter: String? = null,
showShorts: Boolean = true,
showLive: Boolean = false,
accessiblePlayerControls: Boolean = false,
onPlayVideo: (videoUrl: String) -> Unit,
onOpenChannel: (channelUrl: String) -> Unit,
Expand All @@ -86,11 +88,12 @@ fun AppShell(
val backStackEntry by navController.currentBackStackEntryAsState()
val currentDestination = backStackEntry?.destination
val isShorts = currentDestination.matchesRoute(ShortsRoute)
val navigationTabs = visibleTopLevelTabs(showShorts)
val navigationTabs = visibleTopLevelTabs(showShorts, showLive)
val isTopLevel = topLevelTabs.any { currentDestination.matchesRoute(it.route) }
val showsNavigation = !isShorts && (
isTopLevel ||
currentDestination?.hasRoute<ChannelRoute>() == true ||
currentDestination?.hasRoute<TwitchChannelRoute>() == true ||
currentDestination?.hasRoute<PlaylistRoute>() == true ||
currentDestination?.hasRoute<PublicPlaylistRoute>() == true ||
currentDestination?.hasRoute<PodcastRoute>() == true ||
Expand Down
6 changes: 5 additions & 1 deletion app/src/main/java/dev/typetype/android/ChannelNavigation.kt
Original file line number Diff line number Diff line change
@@ -1,9 +1,13 @@
package dev.typetype.android

import dev.typetype.android.core.ui.navigation.TwitchChannelRoute
import dev.typetype.android.domain.twitch.TwitchTarget
import dev.typetype.android.domain.twitch.TwitchUrls
import androidx.navigation.NavHostController
import dev.typetype.android.core.ui.navigation.ChannelRoute
import dev.typetype.android.core.ui.navigation.channelNavigationUrl

internal fun NavHostController.navigateToChannel(channelUrl: String) {
navigate(ChannelRoute(channelUrl = channelNavigationUrl(channelUrl)))
val twitch = TwitchUrls.parse(channelUrl) as? TwitchTarget.Live
if (twitch != null) navigate(TwitchChannelRoute(twitch.login)) else navigate(ChannelRoute(channelUrl = channelNavigationUrl(channelUrl)))
}
Loading