30 июля, 2022

Weather App JetPack Compose #6 : WeatherModel

WeatherModel data class WeatherModel( val city: String, val time: String, val currentTemp: String, val condition: String, val icon: String, val maxTemp: String, val minTemp: String, val hours: String) MainScreen import androidx.compose.foundation.Imageimport androidx.compose.foundation.layout.*import androidx.compose.foundation.lazy.LazyColumnimport androidx.compose.foundation.lazy.itemsIndexedimport androidx.compose.foundation.shape.RoundedCornerShapeimport androidx.compose.material.*import androidx.compose.runtime.Composableimport androidx.compose.runtime.rememberCoroutineScopeimport androidx.compose.ui.Alignmentimport androidx.compose.ui.Modifierimport androidx.compose.ui.draw.alphaimport androidx.compose.ui.draw.clipimport androidx.compose.ui.graphics.Colorimport androidx.compose.ui.layout.ContentScaleimport androidx.compose.ui.res.painterResourceimport androidx.compose.ui.text.TextStyleimport androidx.compose.ui.tooling.preview.Previewimport androidx.compose.ui.unit.dpimport androidx.compose.ui.unit.spimport coil.compose.AsyncImageimport com.google.accompanist.pager.ExperimentalPagerApiimport com.google.accompanist.pager.HorizontalPagerimport com.google.accompanist.pager.pagerTabIndicatorOffsetimport com.google.accompanist.pager.rememberPagerStateimport com.meter_alc_rgb.weatherappcomposey.Rimport com.meter_alc_rgb.weatherappcomposey.data.WeatherModelimport com.meter_alc_rgb.weatherappcomposey.ui.theme.BlueLightimport kotlinx.coroutines.launch@Composablefun MainCard() { Column( modifier = Modifier .padding(5.dp) ) { Card( modifier =… Подробнее »Weather App JetPack Compose #6 : WeatherModel