mirror of
https://github.com/skydoves/android-developer-roadmap.git
synced 2024-12-25 00:00:04 +03:00
Formatting improved
This commit is contained in:
parent
0c24210719
commit
169d29410a
|
@ -32,42 +32,44 @@ import com.mxalbert.zoomable.Zoomable
|
||||||
import io.getstream.androiddeveloperroadmap.ui.theme.AndroidDeveloperRoadmapTheme
|
import io.getstream.androiddeveloperroadmap.ui.theme.AndroidDeveloperRoadmapTheme
|
||||||
|
|
||||||
class MainActivity : ComponentActivity() {
|
class MainActivity : ComponentActivity() {
|
||||||
override fun onCreate(savedInstanceState: Bundle?) {
|
override fun onCreate(savedInstanceState: Bundle?) {
|
||||||
super.onCreate(savedInstanceState)
|
super.onCreate(savedInstanceState)
|
||||||
|
|
||||||
setContent {
|
setContent {
|
||||||
AndroidDeveloperRoadmapTheme {
|
AndroidDeveloperRoadmapTheme {
|
||||||
Surface(
|
Surface(
|
||||||
color = MaterialTheme.colors.background
|
color = MaterialTheme.colors.background
|
||||||
) {
|
) {
|
||||||
Roadmap()
|
Roadmap()
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@Composable
|
@Composable
|
||||||
private fun Roadmap() {
|
private fun Roadmap() {
|
||||||
Zoomable(
|
Zoomable(
|
||||||
modifier = Modifier.fillMaxSize(),
|
modifier = Modifier.fillMaxSize(),
|
||||||
) {
|
) {
|
||||||
Image(
|
Image(
|
||||||
painter = rememberImagePainter("https://user-images.githubusercontent.com/24237865/144350753-5a52e6e5-3517-476c-8e5c-adad919abe8e.png",
|
painter = rememberImagePainter(
|
||||||
builder = {
|
"https://user-images.githubusercontent.com/24237865/144350753-5a52e6e5-3517-476c-8e5c-adad919abe8e.png",
|
||||||
placeholder(R.drawable.roadmap_preview)
|
builder = {
|
||||||
}),
|
placeholder(R.drawable.roadmap_preview)
|
||||||
modifier = Modifier.fillMaxSize(),
|
}
|
||||||
contentScale = ContentScale.Fit,
|
),
|
||||||
contentDescription = null
|
modifier = Modifier.fillMaxSize(),
|
||||||
)
|
contentScale = ContentScale.Fit,
|
||||||
}
|
contentDescription = null
|
||||||
|
)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@Preview(showBackground = true)
|
@Preview(showBackground = true)
|
||||||
@Composable
|
@Composable
|
||||||
private fun DefaultPreview() {
|
private fun DefaultPreview() {
|
||||||
AndroidDeveloperRoadmapTheme {
|
AndroidDeveloperRoadmapTheme {
|
||||||
Roadmap()
|
Roadmap()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue