Pull-to-sync's still ring is floret-kit's BusyIndicator (#157)
This commit is contained in:
1 parent
8732f50ded
commit
dd225e0a0e
2 files changed
+4
-9
No files matched your search
@@ -4,7 +4,6 @@ import androidx.compose.foundation.layout.Box
|
||||
import androidx.compose.foundation.layout.BoxScope
|
||||
import androidx.compose.foundation.layout.padding
|
||||
import androidx.compose.foundation.layout.size
|
||||
import androidx.compose.material3.CircularProgressIndicator
|
||||
import androidx.compose.material3.ExperimentalMaterial3Api
|
||||
import androidx.compose.material3.ExperimentalMaterial3ExpressiveApi
|
||||
import androidx.compose.material3.pulltorefresh.PullToRefreshBox
|
||||
@@ -15,10 +14,8 @@ import androidx.compose.ui.Alignment
|
||||
import androidx.compose.ui.Modifier
|
||||
import androidx.compose.ui.unit.Dp
|
||||
import androidx.compose.ui.unit.dp
|
||||
import de.jeanlucmakiola.floret.components.BusyIndicator
|
||||
import de.jeanlucmakiola.floret.identity.rememberLoopingMotion
|
||||
import androidx.compose.ui.semantics.ProgressBarRangeInfo
|
||||
import androidx.compose.ui.semantics.clearAndSetSemantics
|
||||
import androidx.compose.ui.semantics.progressBarRangeInfo
|
||||
|
||||
/**
|
||||
* Pull down to sync every account (#73). Without an account there is nothing
|
||||
@@ -59,11 +56,9 @@ fun SyncPullBox(
|
||||
modifier = placement,
|
||||
containerColor = PullToRefreshDefaults.loadingIndicatorContainerColor,
|
||||
) {
|
||||
CircularProgressIndicator(
|
||||
BusyIndicator(
|
||||
progress = { if (syncing) 1f else state.distanceFraction.coerceIn(0f, 1f) },
|
||||
modifier = Modifier
|
||||
.size(24.dp)
|
||||
.clearAndSetSemantics { progressBarRangeInfo = ProgressBarRangeInfo.Indeterminate },
|
||||
modifier = Modifier.size(24.dp),
|
||||
strokeWidth = 2.5.dp,
|
||||
)
|
||||
}
|
||||
|
||||
+1
-1
Submodule floret-kit updated: a7f8166c4b...a11f3e9f57.
Reference in new issue
Block a user