Skip to content

Commit

Permalink
Changed today background to have rounded corners
Browse files Browse the repository at this point in the history
  • Loading branch information
HeyPouya committed Sep 7, 2024
1 parent d30afd1 commit 3793068
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,12 @@ import androidx.compose.material3.Text
import androidx.compose.runtime.Composable
import androidx.compose.ui.Alignment
import androidx.compose.ui.Modifier
import androidx.compose.ui.draw.clip
import androidx.compose.ui.graphics.Color
import androidx.compose.ui.tooling.preview.Preview
import androidx.compose.ui.unit.dp
import com.pouyaheydari.calendar.features.calendar.main.theme.DarkBlue80
import com.pouyaheydari.calendar.features.calendar.main.theme.TodayShape

@Composable
fun DayItemComponent(
Expand All @@ -30,6 +32,7 @@ fun DayItemComponent(
Box(modifier = modifier
.fillMaxSize()
.clickable { onItemClicked() }
.clip(TodayShape)
.background(background)
.padding(4.dp)) {
Text(
Expand All @@ -50,5 +53,5 @@ fun DayItemComponent(
@Preview
@Composable
private fun Preview() {
DayItemComponent(persianDay = "۳۰", gregorianDay = "9")
DayItemComponent(persianDay = "۳۰", gregorianDay = "9", isToday = true)
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
package com.pouyaheydari.calendar.features.calendar.main.theme

import androidx.compose.foundation.shape.RoundedCornerShape

val TodayShape = RoundedCornerShape(15)

0 comments on commit 3793068

Please sign in to comment.