Skip to content

Commit

Permalink
Merge pull request #28 from Team-Notitime/fix/27-banner-ui
Browse files Browse the repository at this point in the history
fix: banner ui #27
  • Loading branch information
easyhz authored Jul 20, 2024
2 parents 9b2d8a7 + 1e8c0df commit 3b33049
Showing 1 changed file with 2 additions and 13 deletions.
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
package com.easyhz.noffice.core.design_system.component.banner

import androidx.compose.foundation.Image
import androidx.compose.foundation.background
import androidx.compose.foundation.layout.Box
import androidx.compose.foundation.layout.fillMaxWidth
Expand All @@ -12,8 +11,6 @@ import androidx.compose.runtime.remember
import androidx.compose.ui.Alignment
import androidx.compose.ui.Modifier
import androidx.compose.ui.graphics.Brush
import androidx.compose.ui.layout.ContentScale
import androidx.compose.ui.res.painterResource
import androidx.compose.ui.res.stringResource
import androidx.compose.ui.text.ParagraphStyle
import androidx.compose.ui.text.buildAnnotatedString
Expand Down Expand Up @@ -58,24 +55,16 @@ fun Banner(
Box(
modifier = modifier
.fillMaxWidth()
.heightIn(min = 180.dp)
.heightIn(min = 108.dp)
.background(
brush = Brush.verticalGradient(listOf(White, Green100)),
)
) {
Image(
modifier = Modifier
.fillMaxWidth()
.align(Alignment.BottomStart),
painter = painterResource(id = R.drawable.ic_banner),
contentDescription = "banner",
contentScale = ContentScale.Crop
)
Text(text = annotatedString,
modifier = Modifier
.align(Alignment.BottomStart)
.screenHorizonPadding()
.padding(bottom = 20.dp)
.padding(bottom = 8.dp)
)
}
}
Expand Down

0 comments on commit 3b33049

Please sign in to comment.