|
| 1 | +@Composable |
| 2 | +fun HomePage(modifier: Modifier = Modifier) { |
| 3 | + Box( |
| 4 | + modifier = modifier |
| 5 | + .requiredWidth(width = 360.dp) |
| 6 | + .requiredHeight(height = 838.dp) |
| 7 | + .background(brush = Brush.linearGradient( |
| 8 | + 0f to Color(0xffca263a), |
| 9 | + 1f to Color.Black, |
| 10 | + start = Offset(180f, 0f), |
| 11 | + end = Offset(180f, 838f))) |
| 12 | + ) { |
| 13 | + TextButton( |
| 14 | + onClick = { }, |
| 15 | + colors = ButtonDefaults.buttonColors(containerColor = Color.Transparent), |
| 16 | + modifier = Modifier |
| 17 | + .align(alignment = Alignment.TopStart) |
| 18 | + .offset(x = 142.dp, |
| 19 | + y = 709.dp) |
| 20 | + .requiredWidth(width = 77.dp) |
| 21 | + .requiredHeight(height = 70.dp) |
| 22 | + ) { |
| 23 | + Box( |
| 24 | + modifier = Modifier |
| 25 | + .requiredWidth(width = 77.dp) |
| 26 | + .requiredHeight(height = 70.dp) |
| 27 | + ) { |
| 28 | + Box( |
| 29 | + modifier = Modifier |
| 30 | + .requiredWidth(width = 77.dp) |
| 31 | + .requiredHeight(height = 70.dp) |
| 32 | + ) { |
| 33 | + Image( |
| 34 | + painter = painterResource(id = R.drawable.ellipse3), |
| 35 | + contentDescription = "Ellipse 3", |
| 36 | + modifier = Modifier |
| 37 | + .fillMaxSize()) |
| 38 | + } |
| 39 | + } |
| 40 | + } |
| 41 | + TextButton( |
| 42 | + onClick = { }, |
| 43 | + colors = ButtonDefaults.buttonColors(containerColor = Color.Transparent), |
| 44 | + modifier = Modifier |
| 45 | + .align(alignment = Alignment.TopStart) |
| 46 | + .offset(x = 97.dp, |
| 47 | + y = 50.dp) |
| 48 | + .requiredWidth(width = 165.dp) |
| 49 | + .requiredHeight(height = 168.dp) |
| 50 | + ) { |
| 51 | + Box( |
| 52 | + modifier = Modifier |
| 53 | + .requiredWidth(width = 165.dp) |
| 54 | + .requiredHeight(height = 168.dp) |
| 55 | + ) { |
| 56 | + Box( |
| 57 | + modifier = Modifier |
| 58 | + .requiredWidth(width = 165.dp) |
| 59 | + .requiredHeight(height = 168.dp) |
| 60 | + .background(color = Color(0xffd91d34))) |
| 61 | + Text( |
| 62 | + text = "فوریت بالا", |
| 63 | + color = Color(0xff201a1a).copy(alpha = 0.5f), |
| 64 | + style = TextStyle( |
| 65 | + fontSize = 20.sp), |
| 66 | + modifier = Modifier |
| 67 | + .align(alignment = Alignment.Center) |
| 68 | + .offset(x = 15.191879272460938.dp, |
| 69 | + y = 22.dp) |
| 70 | + .requiredWidth(width = 107.dp) |
| 71 | + .requiredHeight(height = 74.dp)) |
| 72 | + } |
| 73 | + } |
| 74 | + TextButton( |
| 75 | + onClick = { }, |
| 76 | + colors = ButtonDefaults.buttonColors(containerColor = Color.Transparent), |
| 77 | + modifier = Modifier |
| 78 | + .align(alignment = Alignment.TopStart) |
| 79 | + .offset(x = 97.dp, |
| 80 | + y = 241.dp) |
| 81 | + .requiredWidth(width = 165.dp) |
| 82 | + .requiredHeight(height = 168.dp) |
| 83 | + ) { |
| 84 | + Box( |
| 85 | + modifier = Modifier |
| 86 | + .requiredWidth(width = 165.dp) |
| 87 | + .requiredHeight(height = 168.dp) |
| 88 | + ) { |
| 89 | + Box( |
| 90 | + modifier = Modifier |
| 91 | + .requiredWidth(width = 165.dp) |
| 92 | + .requiredHeight(height = 168.dp) |
| 93 | + .background(color = Color(0xffd91d34))) |
| 94 | + Text( |
| 95 | + text = "فوریت متوسط", |
| 96 | + color = Color(0xff201a1a).copy(alpha = 0.5f), |
| 97 | + style = TextStyle( |
| 98 | + fontSize = 20.sp), |
| 99 | + modifier = Modifier |
| 100 | + .align(alignment = Alignment.Center) |
| 101 | + .offset(x = 0.1918792724609375.dp, |
| 102 | + y = 22.dp) |
| 103 | + .requiredWidth(width = 127.dp) |
| 104 | + .requiredHeight(height = 74.dp)) |
| 105 | + } |
| 106 | + } |
| 107 | + TextButton( |
| 108 | + onClick = { }, |
| 109 | + colors = ButtonDefaults.buttonColors(containerColor = Color.Transparent), |
| 110 | + modifier = Modifier |
| 111 | + .align(alignment = Alignment.TopStart) |
| 112 | + .offset(x = 98.dp, |
| 113 | + y = 432.dp) |
| 114 | + .requiredWidth(width = 165.dp) |
| 115 | + .requiredHeight(height = 168.dp) |
| 116 | + ) { |
| 117 | + Box( |
| 118 | + modifier = Modifier |
| 119 | + .requiredWidth(width = 165.dp) |
| 120 | + .requiredHeight(height = 168.dp) |
| 121 | + ) { |
| 122 | + Box( |
| 123 | + modifier = Modifier |
| 124 | + .requiredWidth(width = 165.dp) |
| 125 | + .requiredHeight(height = 168.dp) |
| 126 | + .background(color = Color(0xffd91d34))) |
| 127 | + Text( |
| 128 | + text = "فوریت پایین", |
| 129 | + color = Color(0xff201a1a).copy(alpha = 0.5f), |
| 130 | + style = TextStyle( |
| 131 | + fontSize = 20.sp), |
| 132 | + modifier = Modifier |
| 133 | + .align(alignment = Alignment.Center) |
| 134 | + .offset(x = 0.1918792724609375.dp, |
| 135 | + y = 22.dp) |
| 136 | + .requiredWidth(width = 107.dp) |
| 137 | + .requiredHeight(height = 74.dp)) |
| 138 | + } |
| 139 | + } |
| 140 | + } |
| 141 | + } |
| 142 | + |
| 143 | +@Preview(widthDp = 360, heightDp = 838) |
| 144 | +@Composable |
| 145 | +private fun HomePagePreview() { |
| 146 | + HomePage(Modifier) |
| 147 | + } |
0 commit comments