diff --git a/README.md b/README.md index 221231a43..c71de1af1 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,9 @@ -[日本語のREADMEへ](readme/README-ja.md) +

+ 日本語のREADMEへ + +

+ +
### @@ -10,8 +15,7 @@ # SpMp A YouTube Music client with a focus on language and metadata customisation, built for Android using Jetpack Compose and Kotlin. - - +

## Development status @@ -21,7 +25,7 @@ Support for Compose Multiplatform on desktop is [planned](https://github.com/toa
- + # Features - Edit song, artist, and playlist titles @@ -40,23 +44,23 @@ Support for Compose Multiplatform on desktop is [planned](https://github.com/toa

Screenshots

- - - + + +

More Screenshots

- - - + + +

- - + +

diff --git a/metadata/en-US/images/phoneScreenshots/0.png b/metadata/en-US/images/phoneScreenshots/0.png new file mode 100644 index 000000000..08473c5bc Binary files /dev/null and b/metadata/en-US/images/phoneScreenshots/0.png differ diff --git a/metadata/en-US/images/phoneScreenshots/1.png b/metadata/en-US/images/phoneScreenshots/1.png index 2a378cb49..6a293b34d 100644 Binary files a/metadata/en-US/images/phoneScreenshots/1.png and b/metadata/en-US/images/phoneScreenshots/1.png differ diff --git a/metadata/en-US/images/phoneScreenshots/10.png b/metadata/en-US/images/phoneScreenshots/10.png deleted file mode 100644 index 04bfd1ce0..000000000 Binary files a/metadata/en-US/images/phoneScreenshots/10.png and /dev/null differ diff --git a/metadata/en-US/images/phoneScreenshots/2.png b/metadata/en-US/images/phoneScreenshots/2.png index 5105a686d..e5a228382 100644 Binary files a/metadata/en-US/images/phoneScreenshots/2.png and b/metadata/en-US/images/phoneScreenshots/2.png differ diff --git a/metadata/en-US/images/phoneScreenshots/3.png b/metadata/en-US/images/phoneScreenshots/3.png index 446e2c867..7b88932d9 100644 Binary files a/metadata/en-US/images/phoneScreenshots/3.png and b/metadata/en-US/images/phoneScreenshots/3.png differ diff --git a/metadata/en-US/images/phoneScreenshots/4.png b/metadata/en-US/images/phoneScreenshots/4.png index e9b77c3a4..6c3c07e2c 100644 Binary files a/metadata/en-US/images/phoneScreenshots/4.png and b/metadata/en-US/images/phoneScreenshots/4.png differ diff --git a/metadata/en-US/images/phoneScreenshots/5.png b/metadata/en-US/images/phoneScreenshots/5.png index 6db4cf941..314e144a5 100644 Binary files a/metadata/en-US/images/phoneScreenshots/5.png and b/metadata/en-US/images/phoneScreenshots/5.png differ diff --git a/metadata/en-US/images/phoneScreenshots/6.png b/metadata/en-US/images/phoneScreenshots/6.png index 074a0fe8f..5bb57d00a 100644 Binary files a/metadata/en-US/images/phoneScreenshots/6.png and b/metadata/en-US/images/phoneScreenshots/6.png differ diff --git a/metadata/en-US/images/phoneScreenshots/7.png b/metadata/en-US/images/phoneScreenshots/7.png index 0343334b5..391cd6ad5 100644 Binary files a/metadata/en-US/images/phoneScreenshots/7.png and b/metadata/en-US/images/phoneScreenshots/7.png differ diff --git a/metadata/en-US/images/phoneScreenshots/8.png b/metadata/en-US/images/phoneScreenshots/8.png index bd0929237..090aa1f0b 100644 Binary files a/metadata/en-US/images/phoneScreenshots/8.png and b/metadata/en-US/images/phoneScreenshots/8.png differ diff --git a/metadata/en-US/images/phoneScreenshots/9.png b/metadata/en-US/images/phoneScreenshots/9.png index 1c19beaa7..bc738fa51 100644 Binary files a/metadata/en-US/images/phoneScreenshots/9.png and b/metadata/en-US/images/phoneScreenshots/9.png differ diff --git a/readme/README-ja.md b/readme/README-ja.md index c3fb07109..2be5e1a81 100644 --- a/readme/README-ja.md +++ b/readme/README-ja.md @@ -1,4 +1,9 @@ -[To the English README](../README.md) +

+ To the English README + +

+ +
### @@ -10,8 +15,7 @@ # SpMp 言語とメタデータのカスタマイズに特化した YouTube Music のアプリ。Jetpack ComposeとKotlinを使って主にAndroid向けに開発されています。 - - +

## 開発状態 @@ -21,7 +25,7 @@ Compose Multiplatformでのデスクトップ上サポートは[計画](https://
- + ## 機能 - 曲、アーティスト、またはプレイリストのタイトルを編集 @@ -40,23 +44,23 @@ Compose Multiplatformでのデスクトップ上サポートは[計画](https://

スクリーンショット

- - - + + +

他のスクリーンショット

- - - + + +

- - + +

diff --git a/shared/src/commonMain/kotlin/com/toasterofbread/spmp/model/mediaitem/loader/MediaItemThumbnailLoader.kt b/shared/src/commonMain/kotlin/com/toasterofbread/spmp/model/mediaitem/loader/MediaItemThumbnailLoader.kt index 720755b03..673041216 100644 --- a/shared/src/commonMain/kotlin/com/toasterofbread/spmp/model/mediaitem/loader/MediaItemThumbnailLoader.kt +++ b/shared/src/commonMain/kotlin/com/toasterofbread/spmp/model/mediaitem/loader/MediaItemThumbnailLoader.kt @@ -137,6 +137,9 @@ internal object MediaItemThumbnailLoader: ListenerLoader> val loading_images: List + + fun getHighestQuality(): ImageBitmap? = + loaded_images.maxByOrNull { it.key.ordinal }?.value?.get() } @Composable diff --git a/shared/src/commonMain/kotlin/com/toasterofbread/spmp/platform/Composables.kt b/shared/src/commonMain/kotlin/com/toasterofbread/spmp/platform/Composables.kt index a5e3b8480..ef18444d1 100644 --- a/shared/src/commonMain/kotlin/com/toasterofbread/spmp/platform/Composables.kt +++ b/shared/src/commonMain/kotlin/com/toasterofbread/spmp/platform/Composables.kt @@ -22,6 +22,7 @@ import androidx.compose.ui.unit.dp import com.toasterofbread.spmp.platform.composable.BackHandler import com.toasterofbread.spmp.platform.composable.PlatformDialog import com.toasterofbread.utils.common.thenIf +import com.toasterofbread.utils.composable.WidthShrinkText @Composable fun LargeDropdownMenu( @@ -65,7 +66,7 @@ fun LargeDropdownMenu( } .padding(8.dp) ) { - Text( + WidthShrinkText( text = getItem(index), style = MaterialTheme.typography.titleSmall ) diff --git a/shared/src/commonMain/kotlin/com/toasterofbread/spmp/resources/uilocalisation/localised/YoutubeHomeFeed.kt b/shared/src/commonMain/kotlin/com/toasterofbread/spmp/resources/uilocalisation/localised/YoutubeHomeFeed.kt index b8c706533..603d4965e 100644 --- a/shared/src/commonMain/kotlin/com/toasterofbread/spmp/resources/uilocalisation/localised/YoutubeHomeFeed.kt +++ b/shared/src/commonMain/kotlin/com/toasterofbread/spmp/resources/uilocalisation/localised/YoutubeHomeFeed.kt @@ -35,7 +35,7 @@ fun getYoutubeHomeFeedLocalisations(languages: UILanguages): YoutubeUILocalisati es to "Favoritos olvidados" ) add( - en to "TODO", + en to "From your library", ja to "ライブラリから" ) add( diff --git a/shared/src/commonMain/kotlin/com/toasterofbread/spmp/service/playercontroller/PersistentQueueHandler.kt b/shared/src/commonMain/kotlin/com/toasterofbread/spmp/service/playercontroller/PersistentQueueHandler.kt index 259722a9d..f054d4a3f 100644 --- a/shared/src/commonMain/kotlin/com/toasterofbread/spmp/service/playercontroller/PersistentQueueHandler.kt +++ b/shared/src/commonMain/kotlin/com/toasterofbread/spmp/service/playercontroller/PersistentQueueHandler.kt @@ -175,6 +175,7 @@ internal class PersistentQueueHandler(val player: PlayerServicePlayer, val conte addMultipleToQueue(songs, 0) player.seekToSong(metadata.song_index) player.seekTo(metadata.position_ms) + player.pause() } } } diff --git a/shared/src/commonMain/kotlin/com/toasterofbread/spmp/ui/component/mediaitempreview/MediaItemPreview.kt b/shared/src/commonMain/kotlin/com/toasterofbread/spmp/ui/component/mediaitempreview/MediaItemPreview.kt index b914d62ab..3d5ad08d6 100644 --- a/shared/src/commonMain/kotlin/com/toasterofbread/spmp/ui/component/mediaitempreview/MediaItemPreview.kt +++ b/shared/src/commonMain/kotlin/com/toasterofbread/spmp/ui/component/mediaitempreview/MediaItemPreview.kt @@ -12,6 +12,8 @@ import androidx.compose.foundation.layout.fillMaxSize import androidx.compose.foundation.layout.fillMaxWidth import androidx.compose.foundation.layout.height import androidx.compose.foundation.layout.padding +import androidx.compose.foundation.layout.requiredHeight +import androidx.compose.foundation.layout.requiredSize import androidx.compose.foundation.layout.size import androidx.compose.foundation.shape.CircleShape import androidx.compose.material.icons.Icons @@ -26,7 +28,6 @@ import androidx.compose.runtime.remember import androidx.compose.ui.Alignment import androidx.compose.ui.Modifier import androidx.compose.ui.draw.alpha -import androidx.compose.ui.draw.shadow import androidx.compose.ui.graphics.Color import androidx.compose.ui.text.style.TextAlign import androidx.compose.ui.text.style.TextOverflow @@ -278,7 +279,7 @@ fun MediaItemPreviewLong( private fun InfoText(text: String, contentColour: (() -> Color)?) { Text( text, - Modifier.alpha(0.5f), + Modifier.alpha(0.5f).requiredHeight(20.dp), fontSize = 12.sp, color = contentColour?.invoke() ?: Color.Unspecified, maxLines = 1, diff --git a/shared/src/commonMain/kotlin/com/toasterofbread/spmp/ui/layout/artistpage/ArtistLayout.kt b/shared/src/commonMain/kotlin/com/toasterofbread/spmp/ui/layout/artistpage/ArtistLayout.kt index 69169c39b..e1bb17899 100644 --- a/shared/src/commonMain/kotlin/com/toasterofbread/spmp/ui/layout/artistpage/ArtistLayout.kt +++ b/shared/src/commonMain/kotlin/com/toasterofbread/spmp/ui/layout/artistpage/ArtistLayout.kt @@ -96,7 +96,7 @@ fun ArtistLayout( val density = LocalDensity.current val thumbnail_provider: MediaItemThumbnailProvider? by artist.ThumbnailProvider.observe(player.database) - val thumbnail_load_state = MediaItemThumbnailLoader.rememberItemState(artist) + val thumbnail_load_state: MediaItemThumbnailLoader.ItemState = MediaItemThumbnailLoader.rememberItemState(artist) LaunchedEffect(thumbnail_provider) { thumbnail_provider?.also { provider -> @@ -176,8 +176,10 @@ fun ArtistLayout( TopBar() } + val th = thumbnail_load_state.getHighestQuality() + // Thumbnail - Crossfade(thumbnail_load_state.loaded_images.values.firstOrNull()?.get()) { thumbnail -> + Crossfade(th) { thumbnail -> if (thumbnail != null) { if (accent_colour == null) { accent_colour = player.theme.makeVibrant(thumbnail.getThemeColour() ?: player.theme.accent) diff --git a/shared/src/commonMain/kotlin/com/toasterofbread/spmp/ui/layout/nowplaying/maintab/SeekBar.kt b/shared/src/commonMain/kotlin/com/toasterofbread/spmp/ui/layout/nowplaying/maintab/SeekBar.kt index f06fd5342..b2d28b7a8 100644 --- a/shared/src/commonMain/kotlin/com/toasterofbread/spmp/ui/layout/nowplaying/maintab/SeekBar.kt +++ b/shared/src/commonMain/kotlin/com/toasterofbread/spmp/ui/layout/nowplaying/maintab/SeekBar.kt @@ -6,14 +6,12 @@ import androidx.compose.animation.core.animateFloatAsState import androidx.compose.animation.core.spring import androidx.compose.foundation.Canvas import androidx.compose.foundation.layout.Arrangement +import androidx.compose.foundation.layout.Box import androidx.compose.foundation.layout.Column import androidx.compose.foundation.layout.Row import androidx.compose.foundation.layout.fillMaxWidth -import androidx.compose.foundation.layout.fillMaxHeight import androidx.compose.foundation.layout.height import androidx.compose.foundation.layout.padding -import androidx.compose.foundation.layout.IntrinsicSize -import androidx.compose.foundation.layout.offset import androidx.compose.foundation.layout.requiredHeight import androidx.compose.material3.Text import androidx.compose.runtime.Composable @@ -28,13 +26,11 @@ import androidx.compose.ui.graphics.Brush import androidx.compose.ui.graphics.Color import androidx.compose.ui.graphics.StrokeCap import androidx.compose.ui.text.font.FontWeight -import androidx.compose.ui.text.style.TextOverflow import androidx.compose.ui.unit.Dp import androidx.compose.ui.unit.DpSize import androidx.compose.ui.unit.LayoutDirection import androidx.compose.ui.unit.dp import androidx.compose.ui.unit.sp -import androidx.compose.ui.zIndex import com.github.krottv.compose.sliders.DefaultThumb import com.github.krottv.compose.sliders.SliderValueHorizontal import com.toasterofbread.spmp.ui.layout.nowplaying.POSITION_UPDATE_INTERVAL_MS @@ -69,13 +65,15 @@ fun SeekBar(seek: (Float) -> Unit) { state Column(verticalArrangement = Arrangement.spacedBy(5.dp)) { - Row( - Modifier.fillMaxWidth().padding(horizontal = 7.dp).zIndex(1f).requiredHeight(12.dp), - horizontalArrangement = Arrangement.SpaceBetween, - verticalAlignment = Alignment.CenterVertically - ) { - SeekBarTimeText(player.status.getPositionMillis(), player.getNPOnBackground()) - SeekBarTimeText(player.status.m_duration_ms, player.getNPOnBackground()) + Box(Modifier.fillMaxWidth().padding(horizontal = 7.dp).requiredHeight(12.dp), contentAlignment = Alignment.BottomCenter) { + Row( + Modifier.fillMaxWidth().requiredHeight(30.dp), + horizontalArrangement = Arrangement.SpaceBetween, + verticalAlignment = Alignment.CenterVertically + ) { + SeekBarTimeText(player.status.getPositionMillis(), player.getNPOnBackground()) + SeekBarTimeText(player.status.m_duration_ms, player.getNPOnBackground()) + } } SliderValueHorizontal( @@ -110,7 +108,8 @@ private fun SeekBarTimeText(time: Long, colour: Color, modifier: Modifier = Modi fontSize = 12.sp, fontWeight = FontWeight.Light, color = colour, - modifier = modifier + modifier = modifier, + softWrap = false ) } } diff --git a/shared/src/commonMain/kotlin/com/toasterofbread/utils/common/FuriganaText.kt b/shared/src/commonMain/kotlin/com/toasterofbread/utils/common/FuriganaText.kt index 12144a2e8..70e2b5fe8 100644 --- a/shared/src/commonMain/kotlin/com/toasterofbread/utils/common/FuriganaText.kt +++ b/shared/src/commonMain/kotlin/com/toasterofbread/utils/common/FuriganaText.kt @@ -233,7 +233,7 @@ private fun getLyricsInlineTextContent( placeholder = Placeholder( width = (text.length.toDouble() + ((text.length - 1) * 0.05)).em * ( if (text.any { it.isFullWidth() }) 1f - else 0.55f + else 0.6f ), height = (font_size.value + (reading_font_size.value * 2)).sp, placeholderVerticalAlign = PlaceholderVerticalAlign.Bottom