File tree Expand file tree Collapse file tree 1 file changed +22
-19
lines changed
app/src/main/java/com/xinto/mauth/ui/screen/export Expand file tree Collapse file tree 1 file changed +22
-19
lines changed Original file line number Diff line number Diff line change @@ -182,25 +182,28 @@ private fun BatchExports(
182182 )
183183 }
184184 }
185- Row (
186- modifier = Modifier
187- .fillMaxWidth()
188- .height(24 .dp),
189- horizontalArrangement = Arrangement .spacedBy(4 .dp, Alignment .CenterHorizontally ),
190- verticalAlignment = Alignment .CenterVertically
191- ) {
192- repeat(state.data.size) {
193- val selectedBackgroundColor = MaterialTheme .colorScheme.primary
194- val unselectedBackgroundColor = MaterialTheme .colorScheme.secondary
195- Box (
196- modifier = Modifier
197- .drawBehind {
198- val color = if (pagerState.currentPage == it) selectedBackgroundColor else unselectedBackgroundColor
199- drawCircle(color)
200- }
201- .animateContentSize()
202- .size(if (pagerState.currentPage == it) 16 .dp else 12 .dp)
203- )
185+ if (state.data.size > 1 ) {
186+ Row (
187+ modifier = Modifier
188+ .fillMaxWidth()
189+ .height(24 .dp),
190+ horizontalArrangement = Arrangement .spacedBy(4 .dp, Alignment .CenterHorizontally ),
191+ verticalAlignment = Alignment .CenterVertically
192+ ) {
193+ repeat(state.data.size) {
194+ val selectedBackgroundColor = MaterialTheme .colorScheme.primary
195+ val unselectedBackgroundColor = MaterialTheme .colorScheme.secondary
196+ Box (
197+ modifier = Modifier
198+ .drawBehind {
199+ val color =
200+ if (pagerState.currentPage == it) selectedBackgroundColor else unselectedBackgroundColor
201+ drawCircle(color)
202+ }
203+ .animateContentSize()
204+ .size(if (pagerState.currentPage == it) 16 .dp else 12 .dp)
205+ )
206+ }
204207 }
205208 }
206209 }
You can’t perform that action at this time.
0 commit comments