Skip to content

Commit b9ac514

Browse files
author
Section One
committed
Codi JC26 - Creant la segona pantalla en Jetpack Compose
1 parent f3b122c commit b9ac514

File tree

2 files changed

+35
-6
lines changed

2 files changed

+35
-6
lines changed

app/src/main/java/es/cibernarium/jetpackcomposeapp/pantalles/PrimeraPantalla.kt

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -31,9 +31,4 @@ fun ContingutCos(){
3131
Text("Navega")
3232
}
3333
}
34-
}
35-
36-
@Composable
37-
fun VistaPrevia(){
38-
PrimeraPantalla()
39-
}
34+
}
Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
package es.cibernarium.jetpackcomposeapp.pantalles
2+
3+
import android.annotation.SuppressLint
4+
import androidx.compose.foundation.layout.Arrangement
5+
import androidx.compose.foundation.layout.Column
6+
import androidx.compose.foundation.layout.fillMaxSize
7+
import androidx.compose.material3.Button
8+
import androidx.compose.material3.Scaffold
9+
import androidx.compose.material3.Text
10+
import androidx.compose.runtime.Composable
11+
import androidx.compose.ui.Alignment
12+
import androidx.compose.ui.Modifier
13+
14+
@SuppressLint("UnusedMaterial3ScaffoldPaddingParameter")
15+
@Composable
16+
fun SegonaPantalla(){
17+
//Scaffold (
18+
ContingutCos1()
19+
//}
20+
}
21+
22+
@Composable
23+
fun ContingutCos1(){
24+
Column(
25+
modifier = Modifier.fillMaxSize(),
26+
verticalArrangement = Arrangement.Center,
27+
horizontalAlignment = Alignment.CenterHorizontally
28+
) {
29+
Text("Intranet")
30+
Button(onClick = { /*TODO*/ }) {
31+
Text("Navega")
32+
}
33+
}
34+
}

0 commit comments

Comments
 (0)