@momo-kits/foundation 0.81.24 → 0.81.25
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.
- package/Layout/Card.tsx +13 -14
- package/Layout/styles.ts +1 -0
- package/package.json +1 -1
package/Layout/Card.tsx
CHANGED
|
@@ -7,7 +7,7 @@ import Item from './Item';
|
|
|
7
7
|
import {Image} from '../Image';
|
|
8
8
|
import {ApplicationContext} from '../Application';
|
|
9
9
|
import styles from './styles';
|
|
10
|
-
import {Colors, Shadow, Spacing} from '../Consts';
|
|
10
|
+
import {Colors, Radius, Shadow, Spacing} from '../Consts';
|
|
11
11
|
import ItemList from './ItemList';
|
|
12
12
|
|
|
13
13
|
export interface CardProps extends ViewProps {
|
|
@@ -140,19 +140,6 @@ const Card: React.FC<CardProps> = ({
|
|
|
140
140
|
const {theme} = useContext(ApplicationContext);
|
|
141
141
|
return (
|
|
142
142
|
<GridContext.Provider value={gridContext}>
|
|
143
|
-
{!!backgroundImage && (
|
|
144
|
-
<Image
|
|
145
|
-
source={{uri: backgroundImage}}
|
|
146
|
-
style={[
|
|
147
|
-
styles.imageBackground,
|
|
148
|
-
{
|
|
149
|
-
width: widthSection,
|
|
150
|
-
marginHorizontal: margin,
|
|
151
|
-
borderRadius: Spacing.M,
|
|
152
|
-
},
|
|
153
|
-
]}
|
|
154
|
-
/>
|
|
155
|
-
)}
|
|
156
143
|
<View
|
|
157
144
|
accessibilityLabel={`Card`}
|
|
158
145
|
style={[
|
|
@@ -168,6 +155,18 @@ const Card: React.FC<CardProps> = ({
|
|
|
168
155
|
},
|
|
169
156
|
useShadow && Shadow.Light,
|
|
170
157
|
]}>
|
|
158
|
+
{!!backgroundImage && (
|
|
159
|
+
<Image
|
|
160
|
+
source={{uri: backgroundImage}}
|
|
161
|
+
style={[
|
|
162
|
+
styles.imageBackground,
|
|
163
|
+
{
|
|
164
|
+
width: widthSection,
|
|
165
|
+
borderRadius: Radius.M,
|
|
166
|
+
},
|
|
167
|
+
]}
|
|
168
|
+
/>
|
|
169
|
+
)}
|
|
171
170
|
{renderView(validateChildren(children, [Item, ItemList]))}
|
|
172
171
|
{showGrid && renderOverlay()}
|
|
173
172
|
</View>
|
package/Layout/styles.ts
CHANGED