@momo-kits/native-kits 0.117.1-beta.17 → 0.117.1-beta.19
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.
|
@@ -4,6 +4,7 @@ import androidx.compose.runtime.Composable
|
|
|
4
4
|
import androidx.compose.ui.Modifier
|
|
5
5
|
import androidx.compose.ui.graphics.Color
|
|
6
6
|
import androidx.compose.ui.text.style.TextAlign
|
|
7
|
+
import androidx.compose.ui.text.style.TextOverflow
|
|
7
8
|
import androidx.compose.ui.unit.sp
|
|
8
9
|
import androidx.compose.ui.zIndex
|
|
9
10
|
import vn.momo.kits.components.Text
|
|
@@ -25,6 +26,7 @@ fun HeaderTitle(
|
|
|
25
26
|
lineHeight = 22.sp,
|
|
26
27
|
),
|
|
27
28
|
color = color,
|
|
28
|
-
maxLines = 1
|
|
29
|
+
maxLines = 1,
|
|
30
|
+
overflow = TextOverflow.Ellipsis,
|
|
29
31
|
)
|
|
30
32
|
}
|
|
@@ -108,13 +108,13 @@ fun PopupNotify(
|
|
|
108
108
|
RoundedCornerShape(Radius.L)
|
|
109
109
|
)
|
|
110
110
|
) {
|
|
111
|
-
image.
|
|
111
|
+
if(image.isNotEmpty()) {
|
|
112
112
|
Image(
|
|
113
113
|
source = image,
|
|
114
114
|
modifier = Modifier.fillMaxWidth().aspectRatio(1.777f),
|
|
115
|
-
options = Options(alignment =
|
|
116
|
-
)
|
|
117
|
-
|
|
115
|
+
options = Options(alignment = Alignment.Center)
|
|
116
|
+
)
|
|
117
|
+
}
|
|
118
118
|
|
|
119
119
|
Column(modifier = Modifier.padding(Spacing.XL)) {
|
|
120
120
|
Text(
|
|
@@ -126,7 +126,7 @@ fun PopupNotify(
|
|
|
126
126
|
content(Modifier.padding(top = Spacing.S))
|
|
127
127
|
if (error.isNotEmpty()) {
|
|
128
128
|
Text(
|
|
129
|
-
text =
|
|
129
|
+
text = error,
|
|
130
130
|
style = Typography.descriptionXsRegular,
|
|
131
131
|
color = AppTheme.current.colors.text.hint,
|
|
132
132
|
maxLines = 1,
|
package/ios/Button/Button.swift
CHANGED
|
@@ -42,7 +42,7 @@ public struct Button: View {
|
|
|
42
42
|
SwiftUI.Button(action: action) {
|
|
43
43
|
HStack {
|
|
44
44
|
iconLeft
|
|
45
|
-
renderTitle(title: title, type: type, size: size)
|
|
45
|
+
renderTitle(title: title, type: type, size: size).lineLimit(1).truncationMode(.tail)
|
|
46
46
|
iconRight
|
|
47
47
|
}
|
|
48
48
|
.buttonSize(size)
|
|
@@ -123,15 +123,15 @@ private extension View {
|
|
|
123
123
|
case .large:
|
|
124
124
|
return self
|
|
125
125
|
.frame(maxWidth: .infinity, minHeight: 48, maxHeight: 48)
|
|
126
|
-
.padding([.leading, .trailing], Spacing.
|
|
126
|
+
.padding([.leading, .trailing], Spacing.L)
|
|
127
127
|
case .medium:
|
|
128
128
|
return self
|
|
129
129
|
.frame(minWidth: 80, maxWidth: .infinity, minHeight: 36, maxHeight: 36)
|
|
130
|
-
.padding([.leading, .trailing], Spacing.
|
|
130
|
+
.padding([.leading, .trailing], Spacing.M)
|
|
131
131
|
case .small:
|
|
132
132
|
return self
|
|
133
133
|
.frame(minWidth: 56, maxWidth: 76, minHeight: 28, maxHeight: 28)
|
|
134
|
-
.padding([.leading, .trailing], Spacing.
|
|
134
|
+
.padding([.leading, .trailing], Spacing.S)
|
|
135
135
|
}
|
|
136
136
|
}
|
|
137
137
|
}
|