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
4 changes: 2 additions & 2 deletions buildSrc/src/main/kotlin/Configs.kt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
object Configs {
const val COMPILE_SDK_VERSION = 34
const val TARGET_SDK_VERSION = 34
const val COMPILE_SDK_VERSION = 35
const val TARGET_SDK_VERSION = 35
const val MIN_SDK_VERSION = 26
const val CORE_APP_ID = "com.metacto.coreApp"
const val SAMPLE_APP_FRAMEWORK_NAME = "sampleAppShared"
Expand Down
2 changes: 1 addition & 1 deletion buildSrc/src/main/kotlin/Versions.kt
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ object Versions {
const val VOYAGER = "1.1.0-beta02"
const val ACTIVITY_COMPOSE = "1.8.0"
const val APP_COMPAT = "1.6.1"
const val CORE_KTS = "1.12.0"
const val CORE_KTS = "1.15.0"
const val SECURITY_CRYPTO = "1.0.0"
const val PLAY_SERVICES_AUTH = "20.7.0"
const val SPLASH_SCREEN = "1.1.0-alpha02"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ actual fun AudioPlayer(
handleLifecyclePause: Boolean,
playIconRes: DrawableResource,
pauseIconRes: DrawableResource,
backgroundColor: Color,
playIconColor: Color,
playIconSize: Dp,
durationTextColor: Color,
Expand Down Expand Up @@ -112,6 +113,7 @@ actual fun AudioPlayer(
horizontalPadding = horizontalPadding,
progressSpacing = progressSpacing,
topPadding = topPadding,
backgroundColor = backgroundColor,
onPlayClick = playerManager::togglePlay,
modifier = modifier
)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ expect fun AudioPlayer(
handleLifecyclePause: Boolean = false,
playIconRes: DrawableResource = Res.drawable.ic_audio_play,
pauseIconRes: DrawableResource = Res.drawable.ic_audio_pause,
backgroundColor: Color = colors.audioPlayer.backgroundColor,
playIconColor: Color = colors.audioPlayer.playIcon,
playIconSize: Dp = spacings.audioPlayer.playIconSize,
durationTextColor: Color = colors.audioPlayer.durationText,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@ import androidx.compose.ui.text.TextStyle
import androidx.compose.ui.unit.Dp
import com.metacto.core.presentation.components.images.AppImage
import com.metacto.core.presentation.components.texts.SingleLineText
import com.metacto.core.presentation.theme.CoreTheme.colors
import com.metacto.core.utils.extensions.noRippleClickable
import org.jetbrains.compose.resources.DrawableResource
import org.jetbrains.compose.resources.painterResource
Expand Down Expand Up @@ -60,6 +59,7 @@ fun AudioPlayerComponent(
topPadding: Dp,
horizontalPadding: Dp,
horizontalArrangement: Dp,
backgroundColor: Color,
onPlayClick: () -> Unit
) {
// prepare vars
Expand Down Expand Up @@ -89,7 +89,7 @@ fun AudioPlayerComponent(
verticalArrangement = Arrangement.spacedBy(progressSpacing),
modifier = modifier
.fillMaxWidth()
.background(color = colors.white)
.background(color = backgroundColor)
.padding(top = topPadding)
) {
// Main content row
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -451,7 +451,8 @@ data class CoreColors(
// AudioPlayer
val audioPlayer: AudioPlayerColors = AudioPlayerColors(
primary = primary,
black = black
black = black,
white = white
)
)

Expand Down Expand Up @@ -1012,12 +1013,14 @@ data class LoadingMoreColors(
data class AudioPlayerColors(
private val primary: Color,
private val black: Color,
private val white: Color,
val playIcon: Color = primary,
val durationText: Color = primary,
val progress: List<Color> = listOf(primary, primary),
val tracker: Color = primary.copy(alpha = 0.5f),
val titleColor: Color = primary,
val thumbnailShadowColor: Color = black
val thumbnailShadowColor: Color = black,
val backgroundColor: Color = white
)

val LocalCoreColors = staticCompositionLocalOf { CoreColors() }
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ actual fun AudioPlayer(
handleLifecyclePause: Boolean,
playIconRes: DrawableResource,
pauseIconRes: DrawableResource,
backgroundColor: Color,
playIconColor: Color,
playIconSize: Dp,
durationTextColor: Color,
Expand Down Expand Up @@ -166,6 +167,7 @@ actual fun AudioPlayer(
horizontalPadding = horizontalPadding,
progressSpacing = progressSpacing,
topPadding = topPadding,
backgroundColor = backgroundColor,
onPlayClick = {
if (isPlaying) {
player.pause()
Expand Down