@momo-kits/foundation 0.169.4-beta.2 → 0.169.4-beta.4
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.
|
@@ -16,10 +16,10 @@ describe('getModalLayout', () => {
|
|
|
16
16
|
expect(layout.isFoldable).toBe(false);
|
|
17
17
|
expect(layout.popup.width).toBe(342);
|
|
18
18
|
expect(layout.popup.maxHeight).toBeUndefined();
|
|
19
|
-
expect(layout.popup.radius).toBe(
|
|
19
|
+
expect(layout.popup.radius).toBe(24);
|
|
20
20
|
expect(layout.sheet.width).toBeUndefined();
|
|
21
21
|
expect(layout.sheet.maxHeight).toBeUndefined();
|
|
22
|
-
expect(layout.sheet.radius).toBe(
|
|
22
|
+
expect(layout.sheet.radius).toBe(24);
|
|
23
23
|
expect(layout.scrimOpacity).toBe(0.6);
|
|
24
24
|
});
|
|
25
25
|
|
|
@@ -33,7 +33,7 @@ describe('getModalLayout', () => {
|
|
|
33
33
|
expect(layout.isFoldable).toBe(false);
|
|
34
34
|
expect(layout.popup.width).toBe(844 - 48);
|
|
35
35
|
expect(layout.popup.maxHeight).toBeUndefined();
|
|
36
|
-
expect(layout.popup.radius).toBe(
|
|
36
|
+
expect(layout.popup.radius).toBe(24);
|
|
37
37
|
expect(layout.sheet.width).toBeUndefined();
|
|
38
38
|
expect(layout.scrimOpacity).toBe(0.6);
|
|
39
39
|
});
|
|
@@ -112,9 +112,9 @@ const getModalLayout = ({
|
|
|
112
112
|
minWidth: popupWidth,
|
|
113
113
|
maxWidth: popupWidth,
|
|
114
114
|
margin: Spacing.XL,
|
|
115
|
-
radius: Radius.
|
|
115
|
+
radius: Radius.XL,
|
|
116
116
|
},
|
|
117
|
-
sheet: { margin: 0, radius: Radius.
|
|
117
|
+
sheet: { margin: 0, radius: Radius.XL },
|
|
118
118
|
scrimOpacity: SCRIM_OPACITY,
|
|
119
119
|
};
|
|
120
120
|
}
|
package/Popup/PopupNotify.tsx
CHANGED
|
@@ -183,18 +183,12 @@ const PopupNotify: React.FC<PopupNotifyProps> = ({
|
|
|
183
183
|
const body = (
|
|
184
184
|
<>
|
|
185
185
|
{!!image && (
|
|
186
|
-
<Image
|
|
187
|
-
source={{ uri: image }}
|
|
188
|
-
style={[
|
|
189
|
-
styles.image,
|
|
190
|
-
{ borderTopLeftRadius: radius, borderTopRightRadius: radius },
|
|
191
|
-
]}
|
|
192
|
-
/>
|
|
186
|
+
<Image source={{ uri: image }} style={styles.image} />
|
|
193
187
|
)}
|
|
194
188
|
<View style={[styles.content, isFoldable && styles.shrink]}>
|
|
195
189
|
<Text
|
|
196
190
|
typography={'header_default_bold'}
|
|
197
|
-
numberOfLines={
|
|
191
|
+
numberOfLines={2}
|
|
198
192
|
accessibilityLabel={'title_popup_notify'}
|
|
199
193
|
// keeps the title clear of the close button on a text only popup
|
|
200
194
|
style={
|
|
@@ -250,6 +244,7 @@ const PopupNotify: React.FC<PopupNotifyProps> = ({
|
|
|
250
244
|
width: popupWidth,
|
|
251
245
|
maxHeight,
|
|
252
246
|
},
|
|
247
|
+
styles.card,
|
|
253
248
|
showBaseLineDebug && styles.debugBaseLine,
|
|
254
249
|
]}
|
|
255
250
|
>
|
|
@@ -262,9 +257,10 @@ const PopupNotify: React.FC<PopupNotifyProps> = ({
|
|
|
262
257
|
|
|
263
258
|
const styles = StyleSheet.create({
|
|
264
259
|
debugBaseLine: { borderWidth: 1, borderColor: Colors.green_06 },
|
|
260
|
+
// clips the image and content to the card radius
|
|
261
|
+
card: { overflow: 'hidden' },
|
|
265
262
|
image: {
|
|
266
263
|
aspectRatio: 1.7777,
|
|
267
|
-
overflow: 'hidden',
|
|
268
264
|
},
|
|
269
265
|
shrink: { flexShrink: 1 },
|
|
270
266
|
content: { padding: Spacing.XL },
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@momo-kits/foundation",
|
|
3
|
-
"version": "0.169.4-beta.
|
|
3
|
+
"version": "0.169.4-beta.4",
|
|
4
4
|
"description": "React Native Component Kits",
|
|
5
5
|
"main": "index.ts",
|
|
6
6
|
"scripts": {},
|
|
@@ -8,21 +8,21 @@
|
|
|
8
8
|
"@momo-kits/foundation"
|
|
9
9
|
],
|
|
10
10
|
"dependencies": {
|
|
11
|
-
"react-native-fast-image": "git+https://oauth2:TGi6oBj-LdzsKpLXQSoH@gitlab.mservice.com.vn/momo-platform/public/react-native-fast-image.git#v8.11.0",
|
|
12
11
|
"@react-navigation/bottom-tabs": "7.4.2",
|
|
13
12
|
"@react-navigation/core": "7.12.1",
|
|
14
13
|
"@react-navigation/elements": "2.5.2",
|
|
15
14
|
"@react-navigation/native": "7.1.14",
|
|
16
15
|
"@react-navigation/routers": "7.4.1",
|
|
17
16
|
"@react-navigation/stack": "7.4.2",
|
|
17
|
+
"@shopify/flash-list": "2.1.0",
|
|
18
|
+
"lottie-react-native": "7.2.4",
|
|
19
|
+
"react-native-fast-image": "git+https://oauth2:TGi6oBj-LdzsKpLXQSoH@gitlab.mservice.com.vn/momo-platform/public/react-native-fast-image.git#v8.11.0",
|
|
18
20
|
"react-native-gesture-handler": "2.27.1",
|
|
19
21
|
"react-native-linear-gradient": "git+https://oauth2:TGi6oBj-LdzsKpLXQSoH@gitlab.mservice.com.vn/momo-platform/public/react-native-linear-gradient#v3.0.0",
|
|
20
22
|
"react-native-reanimated": "4.2.2",
|
|
21
|
-
"react-native-worklets": "0.6.1",
|
|
22
|
-
"react-native-safe-area-context": "5.5.2",
|
|
23
23
|
"react-native-reserved-regions": "0.2.0",
|
|
24
|
-
"
|
|
25
|
-
"
|
|
24
|
+
"react-native-safe-area-context": "5.5.2",
|
|
25
|
+
"react-native-worklets": "0.6.1"
|
|
26
26
|
},
|
|
27
27
|
"peerDependencies": {
|
|
28
28
|
"react-native": "*",
|
|
@@ -36,4 +36,4 @@
|
|
|
36
36
|
"registry": "https://registry.npmjs.org/"
|
|
37
37
|
},
|
|
38
38
|
"license": "MoMo"
|
|
39
|
-
}
|
|
39
|
+
}
|