Skip to content

Commit

Permalink
fix(box): add bg shorthand
Browse files Browse the repository at this point in the history
  • Loading branch information
gokselpirnal committed Aug 12, 2024
1 parent 42cf842 commit fe2abfd
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
4 changes: 3 additions & 1 deletion src/components/Box/Box.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import {
backgroundColor,
backgroundColorShorthand,
opacity,
visible,
layout,
Expand All @@ -20,14 +21,15 @@ type RestyleProps = RestyleBoxProps<Theme>;

const restyleFunctions = composeRestyleFunctions<Theme, RestyleProps>([
backgroundColor,
backgroundColorShorthand,
opacity,
visible,
layout,
spacing,
spacingShorthand,
border,
shadow,
position,
spacingShorthand,
]);

export type BoxProps = RNViewProps & RestyleProps;
Expand Down
4 changes: 2 additions & 2 deletions src/components/Modal/__snapshots__/Modal.test.tsx.snap
Original file line number Diff line number Diff line change
Expand Up @@ -44,10 +44,10 @@ exports[`Modal should render Modal when visible true with children 1`] = `
<View
accessibilityLabel="modal"
accessible={true}
bg="white"
style={
Array [
Object {
"backgroundColor": "#FFFFFF",
"borderRadius": 8,
"padding": 16,
},
Expand Down Expand Up @@ -276,10 +276,10 @@ exports[`Modal should render Modal without header 1`] = `
<View
accessibilityLabel="modal"
accessible={true}
bg="white"
style={
Array [
Object {
"backgroundColor": "#FFFFFF",
"borderRadius": 8,
"padding": 16,
},
Expand Down

0 comments on commit fe2abfd

Please sign in to comment.