feat: add custom button component
This commit is contained in:
parent
94b655481c
commit
3ceeeabf0b
|
|
@ -0,0 +1,30 @@
|
|||
package com.syaroful.agrilinkvocpro.growth_recipe_feature.core.component
|
||||
|
||||
import androidx.compose.foundation.BorderStroke
|
||||
import androidx.compose.foundation.layout.fillMaxWidth
|
||||
import androidx.compose.foundation.shape.RoundedCornerShape
|
||||
import androidx.compose.material3.Button
|
||||
import androidx.compose.material3.ButtonDefaults
|
||||
import androidx.compose.material3.Text
|
||||
import androidx.compose.runtime.Composable
|
||||
import androidx.compose.ui.Modifier
|
||||
import androidx.compose.ui.graphics.Color
|
||||
import androidx.compose.ui.unit.dp
|
||||
import com.syaroful.agrilinkvocpro.presentation.theme.MainGreen
|
||||
|
||||
|
||||
@Composable
|
||||
fun CustomButton(onClick: () -> Unit, title: String){
|
||||
Button(
|
||||
modifier = Modifier.fillMaxWidth(),
|
||||
onClick = onClick,
|
||||
colors = ButtonDefaults.buttonColors(
|
||||
containerColor = Color.Transparent,
|
||||
contentColor = MainGreen
|
||||
),
|
||||
shape = RoundedCornerShape(8.dp),
|
||||
border = BorderStroke(color = MainGreen, width = 1.dp)
|
||||
) {
|
||||
Text(title)
|
||||
}
|
||||
}
|
||||
Loading…
Reference in New Issue
Block a user