react-native-exp-fig 0.1.17 → 0.1.18
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/lib/commonjs/common/icons-svg/constants/index.js +8 -6
- package/lib/commonjs/common/icons-svg/constants/index.js.map +1 -1
- package/lib/commonjs/common/icons-svg/house/index.js +49 -0
- package/lib/commonjs/common/icons-svg/house/index.js.map +1 -0
- package/lib/commonjs/common/icons-svg/index.js +26 -12
- package/lib/commonjs/common/icons-svg/index.js.map +1 -1
- package/lib/commonjs/common/icons-svg/island/index.js +34 -0
- package/lib/commonjs/common/icons-svg/island/index.js.map +1 -0
- package/lib/commonjs/components/activities-progress/index.js +16 -14
- package/lib/commonjs/components/activities-progress/index.js.map +1 -1
- package/lib/commonjs/components/activities-progress/interface.d.js.map +1 -1
- package/lib/commonjs/components/card-history/index.js +20 -9
- package/lib/commonjs/components/card-history/index.js.map +1 -1
- package/lib/commonjs/components/card-history/interface.d.js.map +1 -1
- package/lib/commonjs/components/menu-item/interface.d.js.map +1 -1
- package/lib/commonjs/stories/activities-progress/activities-progress.stories.js +24 -14
- package/lib/commonjs/stories/activities-progress/activities-progress.stories.js.map +1 -1
- package/lib/commonjs/stories/card-history/card-history.stories.js +5 -2
- package/lib/commonjs/stories/card-history/card-history.stories.js.map +1 -1
- package/lib/commonjs/utils/get-icon-by-property/index.js +85 -0
- package/lib/commonjs/utils/get-icon-by-property/index.js.map +1 -0
- package/lib/module/common/icons-svg/constants/index.js +8 -6
- package/lib/module/common/icons-svg/constants/index.js.map +1 -1
- package/lib/module/common/icons-svg/house/index.js +41 -0
- package/lib/module/common/icons-svg/house/index.js.map +1 -0
- package/lib/module/common/icons-svg/index.js +26 -12
- package/lib/module/common/icons-svg/index.js.map +1 -1
- package/lib/module/common/icons-svg/island/index.js +26 -0
- package/lib/module/common/icons-svg/island/index.js.map +1 -0
- package/lib/module/components/activities-progress/index.js +15 -14
- package/lib/module/components/activities-progress/index.js.map +1 -1
- package/lib/module/components/activities-progress/interface.d.js.map +1 -1
- package/lib/module/components/card-history/index.js +20 -9
- package/lib/module/components/card-history/index.js.map +1 -1
- package/lib/module/components/card-history/interface.d.js.map +1 -1
- package/lib/module/components/menu-item/interface.d.js.map +1 -1
- package/lib/module/stories/activities-progress/activities-progress.stories.js +24 -14
- package/lib/module/stories/activities-progress/activities-progress.stories.js.map +1 -1
- package/lib/module/stories/card-history/card-history.stories.js +5 -2
- package/lib/module/stories/card-history/card-history.stories.js.map +1 -1
- package/lib/module/utils/get-icon-by-property/index.js +79 -0
- package/lib/module/utils/get-icon-by-property/index.js.map +1 -0
- package/lib/typescript/src/common/icons-svg/constants/index.d.ts +3 -1
- package/lib/typescript/src/common/icons-svg/house/index.d.ts +10 -0
- package/lib/typescript/src/common/icons-svg/island/index.d.ts +10 -0
- package/lib/typescript/src/utils/get-icon-by-property/index.d.ts +15 -0
- package/package.json +2 -3
- package/src/common/icons-svg/constants/index.ts +66 -64
- package/src/common/icons-svg/house/index.tsx +41 -0
- package/src/common/icons-svg/index.tsx +267 -259
- package/src/common/icons-svg/island/index.tsx +25 -0
- package/src/components/activities-progress/index.tsx +169 -162
- package/src/components/activities-progress/interface.d.ts +61 -41
- package/src/components/card-history/index.tsx +221 -211
- package/src/components/card-history/interface.d.ts +38 -34
- package/src/components/menu-item/interface.d.ts +1 -1
- package/src/stories/activities-progress/activities-progress.stories.tsx +71 -61
- package/src/stories/card-history/card-history.stories.tsx +53 -50
- package/src/utils/get-icon-by-property/index.tsx +53 -0
|
@@ -1,211 +1,221 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* IMPORTS
|
|
3
|
-
*/
|
|
4
|
-
import React from "react";
|
|
5
|
-
import { Image, TouchableOpacity } from "react-native";
|
|
6
|
-
|
|
7
|
-
// components
|
|
8
|
-
import { Box } from "../box";
|
|
9
|
-
import { Typography } from "../typography";
|
|
10
|
-
|
|
11
|
-
// typings
|
|
12
|
-
import { ICardHistory } from "./interface";
|
|
13
|
-
|
|
14
|
-
// styles
|
|
15
|
-
import { theme } from "../../styles/theme/theme";
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
*
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
}
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
1
|
+
/**
|
|
2
|
+
* IMPORTS
|
|
3
|
+
*/
|
|
4
|
+
import React from "react";
|
|
5
|
+
import { Image, TouchableOpacity } from "react-native";
|
|
6
|
+
|
|
7
|
+
// components
|
|
8
|
+
import { Box } from "../box";
|
|
9
|
+
import { Typography } from "../typography";
|
|
10
|
+
|
|
11
|
+
// typings
|
|
12
|
+
import { ICardHistory } from "./interface";
|
|
13
|
+
|
|
14
|
+
// styles
|
|
15
|
+
import { theme } from "../../styles/theme/theme";
|
|
16
|
+
import { Icons } from "../../common/icons-svg";
|
|
17
|
+
|
|
18
|
+
/**
|
|
19
|
+
*
|
|
20
|
+
* Componente CardLoading para a interação do usuário com ui.
|
|
21
|
+
*/
|
|
22
|
+
const CardHistory: React.FC<ICardHistory> = ({
|
|
23
|
+
width,
|
|
24
|
+
title = "Carregamento #01020304050607",
|
|
25
|
+
local = "Doca 1, Patío 03 - Usiminas Ipatinga",
|
|
26
|
+
vehicle = "EXP-0000",
|
|
27
|
+
data_start = "12:34 10/03/2025",
|
|
28
|
+
data_end = "13:34 10/03/2025",
|
|
29
|
+
duration = "01:34",
|
|
30
|
+
testID,
|
|
31
|
+
handleNavigation,
|
|
32
|
+
status_carregamento,
|
|
33
|
+
}: ICardHistory) => {
|
|
34
|
+
return (
|
|
35
|
+
<TouchableOpacity onPress={handleNavigation} activeOpacity={0.7}>
|
|
36
|
+
<Box
|
|
37
|
+
testID={testID}
|
|
38
|
+
width={width ?? "100%"}
|
|
39
|
+
backgroundColor={theme.colors.blue[400]}
|
|
40
|
+
marginStyle={{ marginBottom: theme.margins.md }}
|
|
41
|
+
paddingStyle={{ padding: theme.paddings["2xs"] }}
|
|
42
|
+
borderStyled={{
|
|
43
|
+
borderWidth: theme.borderWidths.thin,
|
|
44
|
+
borderColor: theme.colors.blue[400],
|
|
45
|
+
borderRadius: theme.borderWidths.thick_medium,
|
|
46
|
+
}}
|
|
47
|
+
flexStyle={{ flexDirection: "row", justifyContent: "flex-start", alignItems: "center" }}
|
|
48
|
+
>
|
|
49
|
+
<Box width={"25%"} borderStyled={{ borderRadius: theme.borderWidths.thick_medium }}>
|
|
50
|
+
<Image
|
|
51
|
+
source={{
|
|
52
|
+
uri: "https://th.bing.com/th/id/OIP.Rr9_IUNo8J66QbvQkxzXtwHaEJ?w=276&h=180&c=7&r=0&o=5&pid=1.7",
|
|
53
|
+
}}
|
|
54
|
+
style={{
|
|
55
|
+
width: "100%",
|
|
56
|
+
flex: 1,
|
|
57
|
+
borderRadius: theme.borderWidths.thick_medium,
|
|
58
|
+
}}
|
|
59
|
+
/>
|
|
60
|
+
</Box>
|
|
61
|
+
|
|
62
|
+
<Box width={"75%"} paddingStyle={{ paddingLeft: theme.paddings["2xs"] }}>
|
|
63
|
+
<Typography
|
|
64
|
+
text={title}
|
|
65
|
+
ellipsizeMode="tail"
|
|
66
|
+
numberOfLines={1}
|
|
67
|
+
color={theme.colors.neutral[25]}
|
|
68
|
+
size={theme.fontSizes.sm}
|
|
69
|
+
fontFamily={theme.fonts.inter_bold_700}
|
|
70
|
+
lineHeight={theme.fontSizes.xl ?? 20}
|
|
71
|
+
letterSpacing={"regular"}
|
|
72
|
+
marginBottom={4}
|
|
73
|
+
/>
|
|
74
|
+
|
|
75
|
+
<Typography
|
|
76
|
+
text={local}
|
|
77
|
+
color={theme.colors.neutral[25]}
|
|
78
|
+
size={theme.fontSizes.xs}
|
|
79
|
+
fontFamily={theme.fonts.inter_regular_400}
|
|
80
|
+
lineHeight={theme.fontSizes.md ?? 16}
|
|
81
|
+
letterSpacing={"regular"}
|
|
82
|
+
marginBottom={4}
|
|
83
|
+
/>
|
|
84
|
+
|
|
85
|
+
{/**DADOS DO VEÍCULOS */}
|
|
86
|
+
<Box
|
|
87
|
+
flexStyle={{
|
|
88
|
+
flexDirection: "row",
|
|
89
|
+
justifyContent: "space-between",
|
|
90
|
+
alignItems: "center",
|
|
91
|
+
}}
|
|
92
|
+
marginStyle={{
|
|
93
|
+
marginBottom: 4,
|
|
94
|
+
}}
|
|
95
|
+
>
|
|
96
|
+
<Box
|
|
97
|
+
flexStyle={{
|
|
98
|
+
flexDirection: "row",
|
|
99
|
+
alignItems: "center",
|
|
100
|
+
}}
|
|
101
|
+
>
|
|
102
|
+
<Typography
|
|
103
|
+
text={"Dados Veículo:"}
|
|
104
|
+
color={theme.colors.neutral[25]}
|
|
105
|
+
size={theme.fontSizes.xs}
|
|
106
|
+
fontFamily={theme.fonts.inter_regular_400}
|
|
107
|
+
lineHeight={theme.fontSizes.md ?? 16}
|
|
108
|
+
letterSpacing={"regular"}
|
|
109
|
+
/>
|
|
110
|
+
<Typography
|
|
111
|
+
text={vehicle}
|
|
112
|
+
color={theme.colors.neutral[25]}
|
|
113
|
+
size={theme.fontSizes.xs}
|
|
114
|
+
fontFamily={theme.fonts.inter_bold_700}
|
|
115
|
+
lineHeight={theme.fontSizes.md ?? 16}
|
|
116
|
+
letterSpacing={"regular"}
|
|
117
|
+
marginLeft={4}
|
|
118
|
+
/>
|
|
119
|
+
</Box>
|
|
120
|
+
<Icons size={9} color={status_carregamento} icon={"ELLIPSE"} />
|
|
121
|
+
</Box>
|
|
122
|
+
|
|
123
|
+
{/**DATA INICIO DO CARREGAMENTO */}
|
|
124
|
+
<Box
|
|
125
|
+
flexStyle={{
|
|
126
|
+
flexDirection: "row",
|
|
127
|
+
justifyContent: "flex-start",
|
|
128
|
+
alignItems: "center",
|
|
129
|
+
}}
|
|
130
|
+
marginStyle={{
|
|
131
|
+
marginBottom: 4,
|
|
132
|
+
}}
|
|
133
|
+
>
|
|
134
|
+
<Typography
|
|
135
|
+
text={"Data Inicio:"}
|
|
136
|
+
color={theme.colors.neutral[25]}
|
|
137
|
+
size={theme.fontSizes.xs}
|
|
138
|
+
fontFamily={theme.fonts.inter_regular_400}
|
|
139
|
+
lineHeight={theme.fontSizes.md ?? 16}
|
|
140
|
+
letterSpacing={"regular"}
|
|
141
|
+
/>
|
|
142
|
+
<Typography
|
|
143
|
+
text={data_start}
|
|
144
|
+
color={theme.colors.neutral[25]}
|
|
145
|
+
size={theme.fontSizes.xs}
|
|
146
|
+
fontFamily={theme.fonts.inter_bold_700}
|
|
147
|
+
lineHeight={theme.fontSizes.md ?? 16}
|
|
148
|
+
letterSpacing={"regular"}
|
|
149
|
+
marginLeft={4}
|
|
150
|
+
/>
|
|
151
|
+
</Box>
|
|
152
|
+
|
|
153
|
+
{/**DATA FIM DO CARREGAMENTO */}
|
|
154
|
+
<Box
|
|
155
|
+
flexStyle={{
|
|
156
|
+
flexDirection: "row",
|
|
157
|
+
justifyContent: "flex-start",
|
|
158
|
+
alignItems: "center",
|
|
159
|
+
}}
|
|
160
|
+
marginStyle={{
|
|
161
|
+
marginBottom: 4,
|
|
162
|
+
}}
|
|
163
|
+
>
|
|
164
|
+
<Typography
|
|
165
|
+
text={"Data Fim:"}
|
|
166
|
+
color={theme.colors.neutral[25]}
|
|
167
|
+
size={theme.fontSizes.xs}
|
|
168
|
+
fontFamily={theme.fonts.inter_regular_400}
|
|
169
|
+
lineHeight={theme.fontSizes.md ?? 16}
|
|
170
|
+
letterSpacing={"regular"}
|
|
171
|
+
/>
|
|
172
|
+
<Typography
|
|
173
|
+
text={data_end}
|
|
174
|
+
color={theme.colors.neutral[25]}
|
|
175
|
+
size={theme.fontSizes.xs}
|
|
176
|
+
fontFamily={theme.fonts.inter_bold_700}
|
|
177
|
+
lineHeight={theme.fontSizes.md ?? 16}
|
|
178
|
+
letterSpacing={"regular"}
|
|
179
|
+
marginLeft={4}
|
|
180
|
+
/>
|
|
181
|
+
</Box>
|
|
182
|
+
|
|
183
|
+
{/**DURAÇÃO DO CARREGAMENTO */}
|
|
184
|
+
<Box
|
|
185
|
+
flexStyle={{
|
|
186
|
+
flexDirection: "row",
|
|
187
|
+
justifyContent: "flex-start",
|
|
188
|
+
alignItems: "center",
|
|
189
|
+
}}
|
|
190
|
+
marginStyle={{
|
|
191
|
+
marginBottom: 4,
|
|
192
|
+
}}
|
|
193
|
+
>
|
|
194
|
+
<Typography
|
|
195
|
+
text={"Duração:"}
|
|
196
|
+
color={theme.colors.neutral[25]}
|
|
197
|
+
size={theme.fontSizes.xs}
|
|
198
|
+
fontFamily={theme.fonts.inter_regular_400}
|
|
199
|
+
lineHeight={theme.fontSizes.md ?? 16}
|
|
200
|
+
letterSpacing={"regular"}
|
|
201
|
+
/>
|
|
202
|
+
<Typography
|
|
203
|
+
text={duration}
|
|
204
|
+
color={theme.colors.neutral[25]}
|
|
205
|
+
size={theme.fontSizes.xs}
|
|
206
|
+
fontFamily={theme.fonts.inter_bold_700}
|
|
207
|
+
lineHeight={theme.fontSizes.md ?? 16}
|
|
208
|
+
letterSpacing={"regular"}
|
|
209
|
+
marginLeft={4}
|
|
210
|
+
/>
|
|
211
|
+
</Box>
|
|
212
|
+
</Box>
|
|
213
|
+
</Box>
|
|
214
|
+
</TouchableOpacity>
|
|
215
|
+
);
|
|
216
|
+
};
|
|
217
|
+
|
|
218
|
+
/**
|
|
219
|
+
* EXPORTS
|
|
220
|
+
*/
|
|
221
|
+
export { CardHistory };
|
|
@@ -1,34 +1,38 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* IMPORTS
|
|
3
|
-
*/
|
|
4
|
-
import { TouchableOpacityProps } from "react-native";
|
|
5
|
-
|
|
6
|
-
// typing
|
|
7
|
-
import { IGlobalCss } from "../../styles/global/interface";
|
|
8
|
-
|
|
9
|
-
interface ICardHistory extends TouchableOpacityProps, IGlobalCss {
|
|
10
|
-
/**propriedade que indica o título do carregamento */
|
|
11
|
-
title?: string;
|
|
12
|
-
|
|
13
|
-
/**propriedade que indica o local do carregamento */
|
|
14
|
-
local?: string;
|
|
15
|
-
|
|
16
|
-
/**propriedade que indica o veiculo */
|
|
17
|
-
vehicle?: string;
|
|
18
|
-
|
|
19
|
-
/**propriedade que indica inicio do carregamento */
|
|
20
|
-
data_start?: string;
|
|
21
|
-
|
|
22
|
-
/**propriedade que indica fim do carregamento */
|
|
23
|
-
data_end?: string;
|
|
24
|
-
|
|
25
|
-
/**
|
|
26
|
-
duration?: string;
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
/**
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
1
|
+
/**
|
|
2
|
+
* IMPORTS
|
|
3
|
+
*/
|
|
4
|
+
import { TouchableOpacityProps } from "react-native";
|
|
5
|
+
|
|
6
|
+
// typing
|
|
7
|
+
import { IGlobalCss } from "../../styles/global/interface";
|
|
8
|
+
|
|
9
|
+
interface ICardHistory extends TouchableOpacityProps, IGlobalCss {
|
|
10
|
+
/**propriedade que indica o título do carregamento */
|
|
11
|
+
title?: string;
|
|
12
|
+
|
|
13
|
+
/**propriedade que indica o local do carregamento */
|
|
14
|
+
local?: string;
|
|
15
|
+
|
|
16
|
+
/**propriedade que indica o veiculo */
|
|
17
|
+
vehicle?: string;
|
|
18
|
+
|
|
19
|
+
/**propriedade que indica inicio do carregamento */
|
|
20
|
+
data_start?: string;
|
|
21
|
+
|
|
22
|
+
/**propriedade que indica fim do carregamento */
|
|
23
|
+
data_end?: string;
|
|
24
|
+
|
|
25
|
+
/**propriedade que mostra a duração gasta no carregamento */
|
|
26
|
+
duration?: string;
|
|
27
|
+
|
|
28
|
+
/**função de navegação para outra tela */
|
|
29
|
+
handleNavigation: () => void;
|
|
30
|
+
|
|
31
|
+
/**propriedade que pega o status do carregamento */
|
|
32
|
+
status_carregamento: string;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
/**
|
|
36
|
+
* EXPORTS
|
|
37
|
+
*/
|
|
38
|
+
export { ICardHistory };
|
|
@@ -1,61 +1,71 @@
|
|
|
1
|
-
import type { StoryObj, Meta } from "@storybook/react";
|
|
2
|
-
|
|
3
|
-
import { ActivitiesProgress } from "../../components/activities-progress";
|
|
4
|
-
|
|
5
|
-
const meta: Meta<typeof ActivitiesProgress> = {
|
|
6
|
-
title: "componente/ActivitiesProgress",
|
|
7
|
-
component: ActivitiesProgress,
|
|
8
|
-
args: {
|
|
9
|
-
|
|
10
|
-
duracao: "00:30",
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
1
|
+
import type { StoryObj, Meta } from "@storybook/react";
|
|
2
|
+
|
|
3
|
+
import { ActivitiesProgress } from "../../components/activities-progress";
|
|
4
|
+
|
|
5
|
+
const meta: Meta<typeof ActivitiesProgress> = {
|
|
6
|
+
title: "componente/ActivitiesProgress",
|
|
7
|
+
component: ActivitiesProgress,
|
|
8
|
+
args: {
|
|
9
|
+
data_inicio: "11/05/2025",
|
|
10
|
+
duracao: "00:30",
|
|
11
|
+
data_inicio_horario: "17:20",
|
|
12
|
+
tipo_atividade: "trabalho",
|
|
13
|
+
titleLabel: "Operação com Veículo",
|
|
14
|
+
criado_ofiline: true,
|
|
15
|
+
referencia: "repouso_semanal",
|
|
16
|
+
},
|
|
17
|
+
parameters: {
|
|
18
|
+
notes: `
|
|
19
|
+
# ActivitiesProgress
|
|
20
|
+
|
|
21
|
+
Este é um componente de progresso de atividades.
|
|
22
|
+
Você usa assim:
|
|
23
|
+
\`\`\`tsx
|
|
24
|
+
<ActivitiesProgress
|
|
25
|
+
data_inicio="11/05/2025"
|
|
26
|
+
duracao="00:30"
|
|
27
|
+
data_inicio_horario="17:20"
|
|
28
|
+
tipo_atividade="descanso"
|
|
29
|
+
titleLabel="Repouso Noturno"
|
|
30
|
+
criado_ofiline=true
|
|
31
|
+
referencia="repouso_semanal"
|
|
32
|
+
/>
|
|
33
|
+
\`\`\`
|
|
34
|
+
`,
|
|
35
|
+
},
|
|
36
|
+
};
|
|
37
|
+
|
|
38
|
+
export default meta;
|
|
39
|
+
|
|
40
|
+
type Story = StoryObj<typeof meta>;
|
|
41
|
+
|
|
42
|
+
export const ActivitiesProgressPadrao: Story = {
|
|
43
|
+
name: "activities-progress-padrao",
|
|
44
|
+
args: {},
|
|
45
|
+
};
|
|
46
|
+
|
|
47
|
+
export const ActivitiesProgressTrabalho: Story = {
|
|
48
|
+
name: "activities-progress-trabalho",
|
|
49
|
+
args: {
|
|
50
|
+
data_inicio: "15/06/2023",
|
|
51
|
+
duracao: "01:45",
|
|
52
|
+
data_inicio_horario: "14:30",
|
|
53
|
+
titleLabel: "Em Carga",
|
|
54
|
+
tipo_atividade: "trabalho",
|
|
55
|
+
criado_ofiline: true,
|
|
56
|
+
referencia: "operacao_veiculo",
|
|
57
|
+
},
|
|
58
|
+
};
|
|
59
|
+
|
|
60
|
+
export const ActivitiesProgressDescanso: Story = {
|
|
61
|
+
name: "activities-progress-descanso",
|
|
62
|
+
args: {
|
|
63
|
+
data_inicio: "20/07/2023",
|
|
64
|
+
duracao: "00:15",
|
|
65
|
+
data_inicio_horario: "12:00",
|
|
66
|
+
titleLabel: "Refeição",
|
|
67
|
+
tipo_atividade: "descanso",
|
|
68
|
+
criado_ofiline: false,
|
|
69
|
+
referencia: "refeicao",
|
|
70
|
+
},
|
|
71
|
+
};
|