Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
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
34 changes: 34 additions & 0 deletions .github/workflows/build-apk.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: Build Android APK

on:
push:
branches: [ "main", "master" ]
workflow_dispatch:

jobs:
build:
runs-on: ubuntu-latest

steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Set up JDK 17
uses: actions/setup-java@v4
with:
java-version: '17'
distribution: 'temurin'
cache: gradle
Comment on lines +16 to +21

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P1 Workflow uses unsupported JDK

On every push or manual invocation, this workflow runs Gradle under JDK 17 even though the repository requires JDK 21, causing the APK build to run with an unsupported toolchain and fail before producing its artifact.

Suggested change
- name: Set up JDK 17
uses: actions/setup-java@v4
with:
java-version: '17'
distribution: 'temurin'
cache: gradle
- name: Set up JDK 21
uses: actions/setup-java@v4
with:
java-version: '21'
distribution: 'temurin'
cache: gradle

Context Used: CONTRIBUTING.md (source)

Prompt To Fix With AI
This is a comment left during a code review.
Path: .github/workflows/build-apk.yml
Line: 16-21

Comment:
**Workflow uses unsupported JDK**

On every push or manual invocation, this workflow runs Gradle under JDK 17 even though the repository requires JDK 21, causing the APK build to run with an unsupported toolchain and fail before producing its artifact.

```suggestion
      - name: Set up JDK 21
        uses: actions/setup-java@v4
        with:
          java-version: '21'
          distribution: 'temurin'
          cache: gradle
```

**Context Used:** CONTRIBUTING.md ([source](https://github.com/pixelplayerhq/pixelplayeross/blob/main/CONTRIBUTING.md))

---

For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.

Fix in Claude Code Fix in Codex


- name: Grant execute permission for gradlew
run: chmod +x gradlew

- name: Build Debug APK
run: ./gradlew assembleDebug --stacktrace

- name: Upload APK Artifact
uses: actions/upload-artifact@v4
with:
name: PixelPlayer-Debug
path: app/build/outputs/apk/debug/*.apk

Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ import com.lostf1sh.pixelplayeross.BuildConfig
import com.lostf1sh.pixelplayeross.R
import com.lostf1sh.pixelplayeross.ui.theme.RoundedSans
import com.lostf1sh.pixelplayeross.ui.theme.PixelPlayerStatusBarStyle
import com.lostf1sh.pixelplayeross.ui.theme.liquidGlass
import androidx.compose.ui.res.stringResource

@OptIn(ExperimentalMaterial3Api::class)
Expand Down Expand Up @@ -73,16 +74,22 @@ fun GenreGradientTopBar(
modifier = Modifier.background(brush = gradientBrush),
navigationIcon = {
IconButton(
modifier = Modifier.padding(start = 10.dp),
modifier = Modifier
.padding(start = 10.dp)
.liquidGlass(
shape = CircleShape,
tintColor = contentColor,
tintAlpha = 0.22f
),
onClick = onNavigationIconClick,
colors = IconButtonDefaults.iconButtonColors(
containerColor = contentColor
containerColor = Color.Transparent
)
) {
Icon(
imageVector = Icons.AutoMirrored.Rounded.ArrowBack,
contentDescription = stringResource(R.string.auth_cd_back),
tint = startColor
tint = contentColor
)
}
},
Expand All @@ -95,7 +102,6 @@ fun GenreGradientTopBar(
)
}


@OptIn(ExperimentalMaterial3Api::class)
@Composable
fun HomeGradientTopBar(
Expand Down Expand Up @@ -126,11 +132,17 @@ fun HomeGradientTopBar(
modifier = Modifier.padding(start = 12.dp)
) {
FilledTonalButton(
modifier = Modifier.padding(start = 4.dp),
modifier = Modifier
.padding(start = 4.dp)
.liquidGlass(
shape = CircleShape,
tintColor = surfaceContainerHigh,
tintAlpha = 0.52f
),
shape = CircleShape,
contentPadding = PaddingValues(horizontal = 14.dp, vertical = 10.dp),
colors = ButtonDefaults.filledTonalButtonColors(
containerColor = MaterialTheme.colorScheme.surfaceContainerHigh,
containerColor = Color.Transparent,
contentColor = MaterialTheme.colorScheme.onSurface
),
onClick = onBetaClick
Expand All @@ -153,20 +165,22 @@ fun HomeGradientTopBar(
modifier = Modifier.padding(end = 14.dp)
) {
FilledIconButton(
modifier = Modifier.liquidGlass(shape = CircleShape, tintAlpha = 0.50f),
colors = IconButtonDefaults.filledIconButtonColors(
containerColor = MaterialTheme.colorScheme.surfaceContainerHigh,
containerColor = Color.Transparent,
contentColor = MaterialTheme.colorScheme.onSurface
),
onClick = onStreamingClick
) {
Icon(
imageVector = Icons.Rounded.Cloud,
contentDescription = stringResource(R.string.presentation_batch_g_streaming_title)
imageVector = Icons.Rounded.Cloud,
contentDescription = stringResource(R.string.presentation_batch_g_streaming_title)
)
}
FilledIconButton(
modifier = Modifier.liquidGlass(shape = CircleShape, tintAlpha = 0.50f),
colors = IconButtonDefaults.filledIconButtonColors(
containerColor = MaterialTheme.colorScheme.surfaceContainerHigh,
containerColor = Color.Transparent,
contentColor = MaterialTheme.colorScheme.onSurface
),
onClick = onMoreOptionsClick
Expand All @@ -177,8 +191,9 @@ fun HomeGradientTopBar(
)
}
FilledIconButton(
modifier = Modifier.liquidGlass(shape = CircleShape, tintAlpha = 0.50f),
colors = IconButtonDefaults.filledIconButtonColors(
containerColor = MaterialTheme.colorScheme.surfaceContainerHigh,
containerColor = Color.Transparent,
contentColor = MaterialTheme.colorScheme.onSurface
),
onClick = onNavigationIconClick
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ import com.lostf1sh.pixelplayeross.BottomNavItem
import com.lostf1sh.pixelplayeross.data.preferences.NavBarStyle
import com.lostf1sh.pixelplayeross.presentation.components.scoped.CustomNavigationBarItem
import com.lostf1sh.pixelplayeross.presentation.navigation.Screen
import com.lostf1sh.pixelplayeross.ui.theme.liquidGlass
import kotlinx.collections.immutable.ImmutableList
import kotlinx.coroutines.delay
import kotlinx.coroutines.launch
Expand Down Expand Up @@ -114,7 +115,12 @@ private fun PlayerInternalNavigationItemsRow(
.fillMaxWidth()
}
Row(
modifier = rowModifier,
modifier = rowModifier.liquidGlass(
shape = androidx.compose.foundation.shape.RoundedCornerShape(28.dp),
borderWidth = 1.dp,
tintColor = MaterialTheme.colorScheme.surfaceContainer,
tintAlpha = if (compactMode) 0.58f else 0.50f
),
horizontalArrangement = Arrangement.SpaceAround,
verticalAlignment = Alignment.CenterVertically
) {
Expand All @@ -124,7 +130,7 @@ private fun PlayerInternalNavigationItemsRow(
val isSelected = currentRoute != null && currentRoute == item.screen.route
val selectedColor = MaterialTheme.colorScheme.primary
val unselectedColor = MaterialTheme.colorScheme.onSurfaceVariant
val indicatorColorFromTheme = MaterialTheme.colorScheme.secondaryContainer
val indicatorColorFromTheme = MaterialTheme.colorScheme.secondaryContainer.copy(alpha = 0.72f)

val iconPainterResId = if (isSelected && item.selectedIconResId != null && item.selectedIconResId != 0) {
item.selectedIconResId
Expand Down
Loading