@momo-kits/native-kits 0.89.30-rc.1 → 0.89.30-rc.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -33,7 +33,6 @@ fun CheckBox(
33
33
  var backgroundColor = AppTheme.current.colors.background.surface
34
34
  val iconSource = if (indeterminate) "minus" else "ic_checked"
35
35
 
36
-
37
36
  if (checked) {
38
37
  borderColor = AppTheme.current.colors.primary
39
38
  backgroundColor = AppTheme.current.colors.primary
@@ -1,17 +1,13 @@
1
1
  package vn.momo.kits.components
2
2
 
3
- import androidx.compose.foundation.layout.Box
4
- import androidx.compose.foundation.layout.fillMaxSize
5
3
  import androidx.compose.foundation.layout.size
6
4
  import androidx.compose.runtime.Composable
7
- import androidx.compose.ui.Alignment
8
5
  import androidx.compose.ui.Modifier
9
6
  import androidx.compose.ui.graphics.Color
10
7
  import androidx.compose.ui.graphics.ColorFilter
11
8
  import androidx.compose.ui.layout.ContentScale
12
9
  import androidx.compose.ui.unit.Dp
13
10
  import androidx.compose.ui.unit.dp
14
- import coil3.compose.AsyncImage
15
11
  import vn.momo.kits.const.AppTheme
16
12
  import vn.momo.kits.utils.Icons
17
13
 
@@ -25,16 +21,16 @@ fun Icon(
25
21
  val icon = if (source.contains("https")) {
26
22
  source
27
23
  } else {
28
- Icons[source]
24
+ Icons[source] ?: ""
29
25
  }
30
- Box(modifier.size(size), contentAlignment = Alignment.Center) {
31
- AsyncImage(
32
- modifier = Modifier.fillMaxSize(),
33
- model = icon,
34
- contentDescription = null,
26
+ Image(
27
+ modifier = modifier.size(size),
28
+ source = icon,
29
+ loading = false,
30
+ options = Options(
35
31
  contentScale = ContentScale.Fit,
36
32
  colorFilter = color?.let { ColorFilter.tint(it) }
37
- )
38
- }
33
+ ),
34
+ )
39
35
  }
40
36
 
@@ -15,7 +15,6 @@ import androidx.compose.ui.layout.ContentScale
15
15
  import androidx.compose.ui.semantics.contentDescription
16
16
  import androidx.compose.ui.semantics.semantics
17
17
  import androidx.compose.ui.semantics.testTag
18
- import androidx.compose.ui.unit.dp
19
18
  import coil3.compose.AsyncImage
20
19
  import vn.momo.kits.const.AppTheme
21
20
 
@@ -123,7 +123,10 @@ fun TrustBanner(
123
123
  modifier = Modifier
124
124
  .width(64.dp)
125
125
  .height(64.dp)
126
- .padding(end = 8.dp)
126
+ .padding(end = 8.dp),
127
+ options = Options(
128
+ contentScale = ContentScale.Fit,
129
+ )
127
130
  )
128
131
  Column {
129
132
  Text(
@@ -141,11 +144,17 @@ fun TrustBanner(
141
144
  .padding(end = 4.dp)
142
145
  .width(52.dp)
143
146
  .height(20.dp)
147
+ ,options = Options(
148
+ contentScale = ContentScale.Fit,
149
+ )
144
150
  )
145
151
  Image(
146
152
  source = trustBanner.sslImage, modifier = Modifier
147
153
  .width(52.dp)
148
- .height(20.dp)
154
+ .height(20.dp),
155
+ options = Options(
156
+ contentScale = ContentScale.Fit,
157
+ )
149
158
  )
150
159
  }
151
160
  Row(
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@momo-kits/native-kits",
3
- "version": "0.89.30-rc.1",
3
+ "version": "0.89.30-rc.3",
4
4
  "private": false,
5
5
  "dependencies": {},
6
6
  "devDependencies": {},