@servesall/atoms 1.1.16 → 1.1.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.
- package/dist/bundle.cjs.js +165 -60
- package/dist/bundle.esm.js +163 -62
- package/dist/bundle.umd.js +165 -60
- package/package.json +5 -4
- package/src/Buttons/RoundButton/RoundButton.style.js +11 -1
- package/src/Buttons/RoundedButton/RoundedButton.style.js +11 -1
- package/src/Inputs/InputNormal/index.js +26 -1
- package/src/Layout/BorderBottom.js +10 -0
- package/src/Layout/BorderBox.js +8 -0
- package/src/Layout/BorderTop.js +8 -0
- package/src/Layout/Box.js +1 -1
- package/src/Layout/Center.js +7 -7
- package/src/Layout/CenterLeft.js +7 -7
- package/src/Layout/CenterRight.js +7 -7
- package/src/Layout/ImageWrapper.js +10 -0
- package/src/Layout/Layout.style.js +51 -25
- package/src/Layout/Margin.js +7 -7
- package/src/Layout/MarginBottom.js +7 -7
- package/src/Layout/MarginHorizontal.js +7 -7
- package/src/Layout/MarginLeft.js +1 -1
- package/src/Layout/MarginRight.js +1 -1
- package/src/Layout/MarginTop.js +1 -1
- package/src/Layout/MarginVertical.js +7 -7
- package/src/Layout/Padding.js +7 -7
- package/src/Layout/PaddingBottom.js +1 -1
- package/src/Layout/PaddingHorizontal.js +7 -7
- package/src/Layout/PaddingLeft.js +1 -1
- package/src/Layout/PaddingRight.js +1 -1
- package/src/Layout/PaddingTop.js +1 -1
- package/src/Layout/PaddingVertical.js +7 -7
- package/src/Layout/RoundedTopBox.js +1 -1
- package/src/Layout/Stretch.js +7 -7
- package/src/Layout/WebSmallWrapper.js +7 -8
- package/src/Layout/index.js +8 -0
- package/src/SlideToConfirm/Swipe.style.js +1 -1
- package/src/SlideToConfirm/index.js +13 -2
- package/src/SplashScreen/SplashScreen.style.js +6 -0
- package/src/SplashScreen/assets/bootsplash_logo.png +0 -0
- package/src/SplashScreen/assets/bootsplash_logo@1,5x.png +0 -0
- package/src/SplashScreen/assets/bootsplash_logo@2x.png +0 -0
- package/src/SplashScreen/assets/bootsplash_logo@3x.png +0 -0
- package/src/SplashScreen/assets/bootsplash_logo@4x.png +0 -0
- package/src/SplashScreen/assets/bootsplash_manifest.json +7 -0
- package/src/SplashScreen/assets/penguinOriginal.svg +20 -0
- package/src/SplashScreen/index.js +69 -0
- package/src/index.js +10 -0
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React, { useEffect, useState, useRef } from "react";
|
|
2
2
|
import { H4 } from "../../Text";
|
|
3
3
|
import { MarginHorizontal, Row } from "../../Layout";
|
|
4
|
-
import { KeyboardAvoidingView, Platform } from "react-native";
|
|
4
|
+
import { KeyboardAvoidingView, Platform, Keyboard } from "react-native";
|
|
5
5
|
import { InputWrapper, InputElement, BorderWrapper } from "./Animated.style";
|
|
6
6
|
import Placeholder from "./Placeholder";
|
|
7
7
|
|
|
@@ -27,19 +27,43 @@ const Input = ({
|
|
|
27
27
|
isRightBound = false,
|
|
28
28
|
isLeftBound = false,
|
|
29
29
|
euro = false,
|
|
30
|
+
focused = () => {},
|
|
30
31
|
}) => {
|
|
31
32
|
const [isFocused, setIsFocused] = useState(false);
|
|
32
33
|
const [textValue, setTextValue] = useState(value || defaultValue);
|
|
33
34
|
const inputRef = useRef();
|
|
34
35
|
|
|
36
|
+
useEffect(() => {
|
|
37
|
+
focused();
|
|
38
|
+
}, [isFocused]);
|
|
39
|
+
|
|
35
40
|
useEffect(() => {
|
|
36
41
|
textChange(textValue);
|
|
37
42
|
}, [textValue]);
|
|
38
43
|
|
|
44
|
+
useEffect(() => {
|
|
45
|
+
defaultValue && setTextValue(defaultValue);
|
|
46
|
+
}, [defaultValue]);
|
|
47
|
+
|
|
39
48
|
useEffect(() => {
|
|
40
49
|
autoFocus && inputRef.current?.focus();
|
|
41
50
|
}, [autoFocus]);
|
|
42
51
|
|
|
52
|
+
function blurTextInput() {
|
|
53
|
+
inputRef.current?.blur();
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
useEffect(() => {
|
|
57
|
+
const keyboardDidHideSubscription = Keyboard.addListener(
|
|
58
|
+
"keyboardDidHide",
|
|
59
|
+
blurTextInput
|
|
60
|
+
);
|
|
61
|
+
|
|
62
|
+
return () => {
|
|
63
|
+
keyboardDidHideSubscription?.remove();
|
|
64
|
+
};
|
|
65
|
+
}, []);
|
|
66
|
+
|
|
43
67
|
return (
|
|
44
68
|
<KeyboardAvoidingView
|
|
45
69
|
behavior={Platform.OS === "ios" ? "padding" : "height"}
|
|
@@ -106,6 +130,7 @@ const Input = ({
|
|
|
106
130
|
active={isFocused}
|
|
107
131
|
style={style}
|
|
108
132
|
returnKeyType="done"
|
|
133
|
+
onSubmitEditing={blurTextInput}
|
|
109
134
|
/>
|
|
110
135
|
</Row>
|
|
111
136
|
</MarginHorizontal>
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { BorderBottomElement } from "./Layout.style";
|
|
3
|
+
|
|
4
|
+
const BorderBottom = ({ children, style }) => {
|
|
5
|
+
return (
|
|
6
|
+
<BorderBottomElement style={{ ...style }}>{children}</BorderBottomElement>
|
|
7
|
+
);
|
|
8
|
+
};
|
|
9
|
+
|
|
10
|
+
export default BorderBottom;
|
package/src/Layout/Box.js
CHANGED
package/src/Layout/Center.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import React from
|
|
2
|
-
import { CenterElement } from
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { CenterElement } from "./Layout.style";
|
|
3
3
|
|
|
4
4
|
const Center = ({ children, style, direction = false }) => {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
5
|
+
return (
|
|
6
|
+
<CenterElement style={style} direction={direction}>
|
|
7
|
+
{children}
|
|
8
|
+
</CenterElement>
|
|
9
|
+
);
|
|
10
10
|
};
|
|
11
11
|
|
|
12
12
|
export default Center;
|
package/src/Layout/CenterLeft.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import React from
|
|
2
|
-
import { CenterLeftElement } from
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { CenterLeftElement } from "./Layout.style";
|
|
3
3
|
|
|
4
4
|
const CenterLeft = ({ children, style, direction = false }) => {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
5
|
+
return (
|
|
6
|
+
<CenterLeftElement style={style} direction={direction}>
|
|
7
|
+
{children}
|
|
8
|
+
</CenterLeftElement>
|
|
9
|
+
);
|
|
10
10
|
};
|
|
11
11
|
|
|
12
12
|
export default CenterLeft;
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import React from
|
|
2
|
-
import { CenterRightElement } from
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { CenterRightElement } from "./Layout.style";
|
|
3
3
|
|
|
4
4
|
const CenterRight = ({ children, style, direction = false }) => {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
5
|
+
return (
|
|
6
|
+
<CenterRightElement style={style} direction={direction}>
|
|
7
|
+
{children}
|
|
8
|
+
</CenterRightElement>
|
|
9
|
+
);
|
|
10
10
|
};
|
|
11
11
|
|
|
12
12
|
export default CenterRight;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { ImageWrapperElement } from "./Layout.style";
|
|
3
|
+
|
|
4
|
+
const ImageWrapper = ({ children, box = false, style }) => {
|
|
5
|
+
return (
|
|
6
|
+
<ImageWrapperElement style={{ ...style }}>{children}</ImageWrapperElement>
|
|
7
|
+
);
|
|
8
|
+
};
|
|
9
|
+
|
|
10
|
+
export default ImageWrapper;
|
|
@@ -7,119 +7,119 @@ export const CenterElement = styled.View`
|
|
|
7
7
|
align-items: center;
|
|
8
8
|
justify-content: center;
|
|
9
9
|
flex: 1;
|
|
10
|
-
|
|
10
|
+
flexdirection: ${(props) => props.direction || DEFAULT_FLEX_DIRECTION};
|
|
11
11
|
${(props) => props.style};
|
|
12
12
|
`;
|
|
13
13
|
|
|
14
14
|
export const CenterLeftElement = styled.View`
|
|
15
15
|
align-items: ${(props) =>
|
|
16
|
-
(props.
|
|
16
|
+
(props.direction || DEFAULT_FLEX_DIRECTION) === "row"
|
|
17
17
|
? "center"
|
|
18
18
|
: "flex-start"};
|
|
19
19
|
justify-content: ${(props) =>
|
|
20
|
-
(props.
|
|
20
|
+
(props.direction || DEFAULT_FLEX_DIRECTION) === "row"
|
|
21
21
|
? "flex-start"
|
|
22
22
|
: "center"};
|
|
23
23
|
flex: 1;
|
|
24
|
-
flex-direction: ${(props) => props.
|
|
24
|
+
flex-direction: ${(props) => props.direction || DEFAULT_FLEX_DIRECTION};
|
|
25
25
|
${(props) => props.style};
|
|
26
26
|
`;
|
|
27
27
|
|
|
28
28
|
export const CenterRightElement = styled.View`
|
|
29
29
|
align-items: ${(props) =>
|
|
30
|
-
(props.
|
|
30
|
+
(props.direction || DEFAULT_FLEX_DIRECTION) === "row"
|
|
31
31
|
? "center"
|
|
32
32
|
: "flex-end"};
|
|
33
33
|
justify-content: ${(props) =>
|
|
34
|
-
(props.
|
|
34
|
+
(props.direction || DEFAULT_FLEX_DIRECTION) === "row"
|
|
35
35
|
? "flex-end"
|
|
36
36
|
: "center"};
|
|
37
37
|
flex: 1;
|
|
38
|
-
flex-direction: ${(props) => props.
|
|
38
|
+
flex-direction: ${(props) => props.direction || DEFAULT_FLEX_DIRECTION};
|
|
39
39
|
${(props) => props.style};
|
|
40
40
|
`;
|
|
41
41
|
|
|
42
42
|
export const MarginElement = styled.View`
|
|
43
43
|
margin: ${(props) => props.theme.margin};
|
|
44
|
-
flex-direction: ${(props) => props.
|
|
44
|
+
flex-direction: ${(props) => props.direction || DEFAULT_FLEX_DIRECTION};
|
|
45
45
|
${(props) => props.style};
|
|
46
46
|
`;
|
|
47
47
|
|
|
48
48
|
export const MarginHorizontalElement = styled.View`
|
|
49
49
|
margin: 0 ${(props) => props.theme.margin};
|
|
50
|
-
flex-direction: ${(props) => props.
|
|
50
|
+
flex-direction: ${(props) => props.direction || DEFAULT_FLEX_DIRECTION};
|
|
51
51
|
${(props) => props.style};
|
|
52
52
|
`;
|
|
53
53
|
|
|
54
54
|
export const MarginVerticalElement = styled.View`
|
|
55
55
|
margin: ${(props) => props.theme.margin} 0;
|
|
56
|
-
flex-direction: ${(props) => props.
|
|
56
|
+
flex-direction: ${(props) => props.direction || DEFAULT_FLEX_DIRECTION};
|
|
57
57
|
${(props) => props.style};
|
|
58
58
|
`;
|
|
59
59
|
|
|
60
60
|
export const MarginBottomElement = styled.View`
|
|
61
61
|
margin-bottom: ${(props) => props.theme.margin};
|
|
62
|
-
flex-direction: ${(props) => props.
|
|
62
|
+
flex-direction: ${(props) => props.direction || DEFAULT_FLEX_DIRECTION};
|
|
63
63
|
${(props) => props.style};
|
|
64
64
|
`;
|
|
65
65
|
|
|
66
66
|
export const MarginTopElement = styled.View`
|
|
67
67
|
margin-top: ${(props) => props.theme.margin};
|
|
68
|
-
flex-direction: ${(props) => props.
|
|
68
|
+
flex-direction: ${(props) => props.direction || DEFAULT_FLEX_DIRECTION};
|
|
69
69
|
${(props) => props.style};
|
|
70
70
|
`;
|
|
71
71
|
|
|
72
72
|
export const MarginRightElement = styled.View`
|
|
73
73
|
margin-right: ${(props) => props.theme.margin};
|
|
74
|
-
flex-direction: ${(props) => props.
|
|
74
|
+
flex-direction: ${(props) => props.direction || DEFAULT_FLEX_DIRECTION};
|
|
75
75
|
${(props) => props.style};
|
|
76
76
|
`;
|
|
77
77
|
|
|
78
78
|
export const MarginLeftElement = styled.View`
|
|
79
79
|
margin-left: ${(props) => props.theme.margin};
|
|
80
|
-
flex-direction: ${(props) => props.
|
|
80
|
+
flex-direction: ${(props) => props.direction || DEFAULT_FLEX_DIRECTION};
|
|
81
81
|
${(props) => props.style};
|
|
82
82
|
`;
|
|
83
83
|
|
|
84
84
|
export const PaddingElement = styled.View`
|
|
85
85
|
padding: ${(props) => props.theme.padding};
|
|
86
|
-
flex-direction: ${(props) => props.
|
|
86
|
+
flex-direction: ${(props) => props.direction || DEFAULT_FLEX_DIRECTION};
|
|
87
87
|
${(props) => props.style};
|
|
88
88
|
`;
|
|
89
89
|
|
|
90
90
|
export const PaddingHorizontalElement = styled.View`
|
|
91
91
|
padding: 0 ${(props) => props.theme.padding};
|
|
92
|
-
flex-direction: ${(props) => props.
|
|
92
|
+
flex-direction: ${(props) => props.direction || DEFAULT_FLEX_DIRECTION};
|
|
93
93
|
${(props) => props.style};
|
|
94
94
|
`;
|
|
95
95
|
|
|
96
96
|
export const PaddingVerticalElement = styled.View`
|
|
97
97
|
padding: ${(props) => props.theme.padding} 0;
|
|
98
|
-
flex-direction: ${(props) => props.
|
|
98
|
+
flex-direction: ${(props) => props.direction || DEFAULT_FLEX_DIRECTION};
|
|
99
99
|
${(props) => props.style};
|
|
100
100
|
`;
|
|
101
101
|
|
|
102
102
|
export const PaddingTopElement = styled.View`
|
|
103
103
|
padding-top: ${(props) => props.theme.padding};
|
|
104
|
-
flex-direction: ${(props) => props.
|
|
104
|
+
flex-direction: ${(props) => props.direction || DEFAULT_FLEX_DIRECTION};
|
|
105
105
|
${(props) => props.style};
|
|
106
106
|
`;
|
|
107
107
|
|
|
108
108
|
export const PaddingBottomElement = styled.View`
|
|
109
109
|
padding-bottom: ${(props) => props.theme.padding};
|
|
110
|
-
flex-direction: ${(props) => props.
|
|
110
|
+
flex-direction: ${(props) => props.direction || DEFAULT_FLEX_DIRECTION};
|
|
111
111
|
${(props) => props.style};
|
|
112
112
|
`;
|
|
113
113
|
|
|
114
114
|
export const PaddingLeftElement = styled.View`
|
|
115
115
|
padding-left: ${(props) => props.theme.padding};
|
|
116
|
-
flex-direction: ${(props) => props.
|
|
116
|
+
flex-direction: ${(props) => props.direction || DEFAULT_FLEX_DIRECTION};
|
|
117
117
|
${(props) => props.style};
|
|
118
118
|
`;
|
|
119
119
|
|
|
120
120
|
export const PaddingRightElement = styled.View`
|
|
121
121
|
padding-right: ${(props) => props.theme.padding};
|
|
122
|
-
flex-direction: ${(props) => props.
|
|
122
|
+
flex-direction: ${(props) => props.direction || DEFAULT_FLEX_DIRECTION};
|
|
123
123
|
${(props) => props.style};
|
|
124
124
|
`;
|
|
125
125
|
|
|
@@ -131,13 +131,32 @@ export const RowElement = styled.View`
|
|
|
131
131
|
export const StretchElement = styled.View`
|
|
132
132
|
align-items: stretch;
|
|
133
133
|
align-self: stretch;
|
|
134
|
-
flex-direction: ${(props) => props.
|
|
134
|
+
flex-direction: ${(props) => props.direction || DEFAULT_FLEX_DIRECTION};
|
|
135
135
|
${(props) => props.style};
|
|
136
136
|
`;
|
|
137
137
|
|
|
138
138
|
export const BoxElement = styled.View`
|
|
139
139
|
flex: 1;
|
|
140
|
-
flex-direction: ${(props) => props.
|
|
140
|
+
flex-direction: ${(props) => props.direction || DEFAULT_FLEX_DIRECTION};
|
|
141
|
+
${(props) => props.style};
|
|
142
|
+
`;
|
|
143
|
+
|
|
144
|
+
export const BorderBottomElement = styled.View`
|
|
145
|
+
border-bottom-width: 2px;
|
|
146
|
+
border-color: ${(props) => props.theme.color7};
|
|
147
|
+
${(props) => props.style};
|
|
148
|
+
`;
|
|
149
|
+
|
|
150
|
+
export const BorderTopElement = styled.View`
|
|
151
|
+
border-top-width: 2px;
|
|
152
|
+
border-color: ${(props) => props.theme.color7};
|
|
153
|
+
${(props) => props.style};
|
|
154
|
+
`;
|
|
155
|
+
|
|
156
|
+
export const BorderBoxElement = styled.View`
|
|
157
|
+
border-width: 2px;
|
|
158
|
+
border-color: ${(props) => props.theme.color7};
|
|
159
|
+
border-radius: ${(props) => props.theme.borderRadiusSmall};
|
|
141
160
|
${(props) => props.style};
|
|
142
161
|
`;
|
|
143
162
|
|
|
@@ -148,12 +167,19 @@ export const FullScreenElement = styled.View`
|
|
|
148
167
|
left: 0;
|
|
149
168
|
right: 0;
|
|
150
169
|
z-index: 11;
|
|
151
|
-
flex-direction: ${(props) => props.
|
|
170
|
+
flex-direction: ${(props) => props.direction || DEFAULT_FLEX_DIRECTION};
|
|
152
171
|
${(props) => props.style};
|
|
153
172
|
`;
|
|
154
173
|
|
|
155
174
|
export const WebSmallWrapperElement = styled.View`
|
|
156
|
-
flex-direction: ${(props) => props.
|
|
175
|
+
flex-direction: ${(props) => props.direction || DEFAULT_FLEX_DIRECTION};
|
|
157
176
|
width: 500px;
|
|
158
177
|
${(props) => props.style};
|
|
159
178
|
`;
|
|
179
|
+
|
|
180
|
+
export const ImageWrapperElement = styled.View`
|
|
181
|
+
border-radius: ${(props) => props.theme.borderRadiusSmall};
|
|
182
|
+
background-color: ${(props) => props.theme.color7};
|
|
183
|
+
overflow: hidden;
|
|
184
|
+
${(props) => props.styles};
|
|
185
|
+
`;
|
package/src/Layout/Margin.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import React from
|
|
2
|
-
import { MarginElement } from
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { MarginElement } from "./Layout.style";
|
|
3
3
|
|
|
4
4
|
const Margin = ({ children, style, direction = false }) => {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
5
|
+
return (
|
|
6
|
+
<MarginElement style={style} direction={direction}>
|
|
7
|
+
{children}
|
|
8
|
+
</MarginElement>
|
|
9
|
+
);
|
|
10
10
|
};
|
|
11
11
|
|
|
12
12
|
export default Margin;
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import React from
|
|
2
|
-
import { MarginBottomElement } from
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { MarginBottomElement } from "./Layout.style";
|
|
3
3
|
|
|
4
4
|
const MarginBottom = ({ children, style, direction = false }) => {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
5
|
+
return (
|
|
6
|
+
<MarginBottomElement style={style} direction={direction}>
|
|
7
|
+
{children}
|
|
8
|
+
</MarginBottomElement>
|
|
9
|
+
);
|
|
10
10
|
};
|
|
11
11
|
|
|
12
12
|
export default MarginBottom;
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import React from
|
|
2
|
-
import { MarginHorizontalElement } from
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { MarginHorizontalElement } from "./Layout.style";
|
|
3
3
|
|
|
4
4
|
const MarginHorizontal = ({ children, style, direction = false }) => {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
5
|
+
return (
|
|
6
|
+
<MarginHorizontalElement style={style} direction={direction}>
|
|
7
|
+
{children}
|
|
8
|
+
</MarginHorizontalElement>
|
|
9
|
+
);
|
|
10
10
|
};
|
|
11
11
|
|
|
12
12
|
export default MarginHorizontal;
|
package/src/Layout/MarginLeft.js
CHANGED
|
@@ -3,7 +3,7 @@ import { MarginLeftElement } from "./Layout.style";
|
|
|
3
3
|
|
|
4
4
|
const MarginLeft = ({ children, style, direction = false }) => {
|
|
5
5
|
return (
|
|
6
|
-
<MarginLeftElement style={style}
|
|
6
|
+
<MarginLeftElement style={style} direction={direction}>
|
|
7
7
|
{children}
|
|
8
8
|
</MarginLeftElement>
|
|
9
9
|
);
|
|
@@ -3,7 +3,7 @@ import { MarginRightElement } from "./Layout.style";
|
|
|
3
3
|
|
|
4
4
|
const MarginRight = ({ children, style, direction = false }) => {
|
|
5
5
|
return (
|
|
6
|
-
<MarginRightElement style={style}
|
|
6
|
+
<MarginRightElement style={style} direction={direction}>
|
|
7
7
|
{children}
|
|
8
8
|
</MarginRightElement>
|
|
9
9
|
);
|
package/src/Layout/MarginTop.js
CHANGED
|
@@ -3,7 +3,7 @@ import { MarginTopElement } from "./Layout.style";
|
|
|
3
3
|
|
|
4
4
|
const MarginTop = ({ children, style, direction = false }) => {
|
|
5
5
|
return (
|
|
6
|
-
<MarginTopElement style={style}
|
|
6
|
+
<MarginTopElement style={style} direction={direction}>
|
|
7
7
|
{children}
|
|
8
8
|
</MarginTopElement>
|
|
9
9
|
);
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import React from
|
|
2
|
-
import { MarginVerticalElement } from
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { MarginVerticalElement } from "./Layout.style";
|
|
3
3
|
|
|
4
4
|
const MarginVertical = ({ children, style, direction = false }) => {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
5
|
+
return (
|
|
6
|
+
<MarginVerticalElement style={style} direction={direction}>
|
|
7
|
+
{children}
|
|
8
|
+
</MarginVerticalElement>
|
|
9
|
+
);
|
|
10
10
|
};
|
|
11
11
|
|
|
12
12
|
export default MarginVertical;
|
package/src/Layout/Padding.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import React from
|
|
2
|
-
import { PaddingElement } from
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { PaddingElement } from "./Layout.style";
|
|
3
3
|
|
|
4
4
|
const Padding = ({ children, style, direction = false }) => {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
5
|
+
return (
|
|
6
|
+
<PaddingElement style={style} direction={direction}>
|
|
7
|
+
{children}
|
|
8
|
+
</PaddingElement>
|
|
9
|
+
);
|
|
10
10
|
};
|
|
11
11
|
|
|
12
12
|
export default Padding;
|
|
@@ -3,7 +3,7 @@ import { PaddingBottomElement } from "./Layout.style";
|
|
|
3
3
|
|
|
4
4
|
const PaddingBottom = ({ children, style, direction = false }) => {
|
|
5
5
|
return (
|
|
6
|
-
<PaddingBottomElement style={style}
|
|
6
|
+
<PaddingBottomElement style={style} direction={direction}>
|
|
7
7
|
{children}
|
|
8
8
|
</PaddingBottomElement>
|
|
9
9
|
);
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import React from
|
|
2
|
-
import { PaddingHorizontalElement } from
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { PaddingHorizontalElement } from "./Layout.style";
|
|
3
3
|
|
|
4
4
|
const PaddingHorizontal = ({ children, style, direction = false }) => {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
5
|
+
return (
|
|
6
|
+
<PaddingHorizontalElement style={style} direction={direction}>
|
|
7
|
+
{children}
|
|
8
|
+
</PaddingHorizontalElement>
|
|
9
|
+
);
|
|
10
10
|
};
|
|
11
11
|
|
|
12
12
|
export default PaddingHorizontal;
|
|
@@ -3,7 +3,7 @@ import { PaddingLeftElement } from "./Layout.style";
|
|
|
3
3
|
|
|
4
4
|
const PaddingLeft = ({ children, style, direction = false }) => {
|
|
5
5
|
return (
|
|
6
|
-
<PaddingLeftElement style={style}
|
|
6
|
+
<PaddingLeftElement style={style} direction={direction}>
|
|
7
7
|
{children}
|
|
8
8
|
</PaddingLeftElement>
|
|
9
9
|
);
|
|
@@ -3,7 +3,7 @@ import { PaddingRightElement } from "./Layout.style";
|
|
|
3
3
|
|
|
4
4
|
const PaddingRight = ({ children, style, direction = false }) => {
|
|
5
5
|
return (
|
|
6
|
-
<PaddingRightElement style={style}
|
|
6
|
+
<PaddingRightElement style={style} direction={direction}>
|
|
7
7
|
{children}
|
|
8
8
|
</PaddingRightElement>
|
|
9
9
|
);
|
package/src/Layout/PaddingTop.js
CHANGED
|
@@ -3,7 +3,7 @@ import { PaddingTopElement } from "./Layout.style";
|
|
|
3
3
|
|
|
4
4
|
const PaddingTop = ({ children, style, direction = false }) => {
|
|
5
5
|
return (
|
|
6
|
-
<PaddingTopElement style={style}
|
|
6
|
+
<PaddingTopElement style={style} direction={direction}>
|
|
7
7
|
{children}
|
|
8
8
|
</PaddingTopElement>
|
|
9
9
|
);
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import React from
|
|
2
|
-
import { PaddingVerticalElement } from
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { PaddingVerticalElement } from "./Layout.style";
|
|
3
3
|
|
|
4
4
|
const PaddingVertical = ({ children, style, direction = false }) => {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
5
|
+
return (
|
|
6
|
+
<PaddingVerticalElement style={style} direction={direction}>
|
|
7
|
+
{children}
|
|
8
|
+
</PaddingVerticalElement>
|
|
9
|
+
);
|
|
10
10
|
};
|
|
11
11
|
|
|
12
12
|
export default PaddingVertical;
|
package/src/Layout/Stretch.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import React from
|
|
2
|
-
import { StretchElement } from
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { StretchElement } from "./Layout.style";
|
|
3
3
|
|
|
4
4
|
const Stretch = ({ children, style, direction = false }) => {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
5
|
+
return (
|
|
6
|
+
<StretchElement style={style} direction={direction}>
|
|
7
|
+
{children}
|
|
8
|
+
</StretchElement>
|
|
9
|
+
);
|
|
10
10
|
};
|
|
11
11
|
|
|
12
12
|
export default Stretch;
|
|
@@ -1,13 +1,12 @@
|
|
|
1
|
-
import React from
|
|
2
|
-
import { WebSmallWrapperElement } from
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { WebSmallWrapperElement } from "./Layout.style";
|
|
3
3
|
|
|
4
4
|
const WebSmallWrapper = ({ children, style, direction = false }) => {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
5
|
+
return (
|
|
6
|
+
<WebSmallWrapperElement style={style} direction={direction}>
|
|
7
|
+
{children}
|
|
8
|
+
</WebSmallWrapperElement>
|
|
9
|
+
);
|
|
10
10
|
};
|
|
11
11
|
|
|
12
12
|
export default WebSmallWrapper;
|
|
13
|
-
|