refactor(shell): delete EmptyTabScreen
Its own KDoc said M5 to M8 would replace it. M8 was the last one: every tab now has content of its own, so the placeholder has no caller left.
This commit is contained in:
@@ -1,20 +1,9 @@
|
||||
package de.jeanlucmakiola.clockula.ui.shell
|
||||
|
||||
import androidx.compose.foundation.layout.Spacer
|
||||
import androidx.compose.foundation.layout.height
|
||||
import androidx.compose.foundation.layout.padding
|
||||
import androidx.compose.material3.MaterialTheme
|
||||
import androidx.compose.material3.Text
|
||||
import androidx.compose.runtime.Composable
|
||||
import androidx.compose.runtime.ProvidableCompositionLocal
|
||||
import androidx.compose.runtime.compositionLocalOf
|
||||
import androidx.compose.ui.Modifier
|
||||
import androidx.compose.ui.unit.Dp
|
||||
import androidx.compose.ui.unit.dp
|
||||
import de.jeanlucmakiola.floret.components.CollapsingScaffold
|
||||
import de.jeanlucmakiola.floret.components.GroupedListInset
|
||||
import de.jeanlucmakiola.floret.components.GroupedSurface
|
||||
import de.jeanlucmakiola.floret.components.Position
|
||||
import kotlin.time.Duration
|
||||
import kotlin.time.Duration.Companion.seconds
|
||||
|
||||
@@ -43,34 +32,3 @@ object ShellDefaults {
|
||||
* pill comes and goes, and a static local would recompose the whole subtree.
|
||||
*/
|
||||
val LocalLivePillInset: ProvidableCompositionLocal<Dp> = compositionLocalOf { 0.dp }
|
||||
|
||||
/**
|
||||
* A top-level tab's title bar over a single sentence on a grouped surface —
|
||||
* the shape M4's four tabs share while their content belongs to M5–M8. Each
|
||||
* tab keeps the pill's band clear through [LocalLivePillInset], so a countdown
|
||||
* never sits on top of the last row.
|
||||
*
|
||||
* Lives here rather than being written out four times: the tabs differ only in
|
||||
* two strings today, and each of M5–M8 replaces its own tab outright.
|
||||
*/
|
||||
@Composable
|
||||
internal fun EmptyTabScreen(
|
||||
title: String,
|
||||
message: String,
|
||||
modifier: Modifier = Modifier,
|
||||
) {
|
||||
CollapsingScaffold(title = title, modifier = modifier) {
|
||||
GroupedSurface(
|
||||
position = Position.Alone,
|
||||
modifier = Modifier.padding(horizontal = GroupedListInset),
|
||||
) {
|
||||
Text(
|
||||
text = message,
|
||||
style = MaterialTheme.typography.bodyLarge,
|
||||
color = MaterialTheme.colorScheme.onSurfaceVariant,
|
||||
modifier = Modifier.padding(horizontal = 20.dp, vertical = 24.dp),
|
||||
)
|
||||
}
|
||||
Spacer(Modifier.height(LocalLivePillInset.current))
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user