jornada-ui 0.4.18 → 0.4.20

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.
Files changed (180) hide show
  1. package/lib/commonjs/components/box/index.js +5 -5
  2. package/lib/commonjs/components/box/index.js.map +1 -1
  3. package/lib/commonjs/components/button/index.js +5 -5
  4. package/lib/commonjs/components/button/index.js.map +1 -1
  5. package/lib/commonjs/components/capture-photo/index.js +1 -1
  6. package/lib/commonjs/components/capture-photo/index.js.map +1 -1
  7. package/lib/commonjs/components/card-hours/index.js +5 -5
  8. package/lib/commonjs/components/card-hours/index.js.map +1 -1
  9. package/lib/commonjs/components/card-maintenance/index.js +3 -0
  10. package/lib/commonjs/components/card-maintenance/index.js.map +1 -1
  11. package/lib/commonjs/components/list-supplies/index.js +132 -111
  12. package/lib/commonjs/components/list-supplies/index.js.map +1 -1
  13. package/lib/commonjs/components/maintenance-description-input/index.js +5 -1
  14. package/lib/commonjs/components/maintenance-description-input/index.js.map +1 -1
  15. package/lib/commonjs/components/modal-maintenance/index.js +2 -0
  16. package/lib/commonjs/components/modal-maintenance/index.js.map +1 -1
  17. package/lib/commonjs/components/modal-type-activities/index.js +10 -4
  18. package/lib/commonjs/components/modal-type-activities/index.js.map +1 -1
  19. package/lib/commonjs/components/modals/modal-change-activitie-history/index.js +2 -0
  20. package/lib/commonjs/components/modals/modal-change-activitie-history/index.js.map +1 -1
  21. package/lib/commonjs/components/notification-details-card/index.js +6 -6
  22. package/lib/commonjs/components/report-bobinas/index.js +12 -6
  23. package/lib/commonjs/components/report-bobinas/index.js.map +1 -1
  24. package/lib/commonjs/components/resume-raking/index.js +5 -0
  25. package/lib/commonjs/components/resume-raking/index.js.map +1 -1
  26. package/lib/commonjs/components/step-indicator/index.js +12 -4
  27. package/lib/commonjs/components/step-indicator/index.js.map +1 -1
  28. package/lib/commonjs/components/toast-message/index.js +10 -6
  29. package/lib/commonjs/components/toast-message/index.js.map +1 -1
  30. package/lib/commonjs/components/toggle-fuel/index.js +1 -0
  31. package/lib/commonjs/components/toggle-fuel/index.js.map +1 -1
  32. package/lib/commonjs/components/trip-details-card/index.js +218 -182
  33. package/lib/commonjs/components/trip-details-card/index.js.map +1 -1
  34. package/lib/commonjs/components/typography/index.js +2 -0
  35. package/lib/commonjs/components/typography/index.js.map +1 -1
  36. package/lib/commonjs/components/user-journey-work-card/index.js +14 -0
  37. package/lib/commonjs/components/user-journey-work-card/index.js.map +1 -1
  38. package/lib/commonjs/components/user-profile/index.js +9 -1
  39. package/lib/commonjs/components/user-profile/index.js.map +1 -1
  40. package/lib/commonjs/components/weekly-hours-balance/index.js +2 -0
  41. package/lib/commonjs/components/weekly-hours-balance/index.js.map +1 -1
  42. package/lib/commonjs/index.js +32 -32
  43. package/lib/module/components/box/index.js +5 -5
  44. package/lib/module/components/box/index.js.map +1 -1
  45. package/lib/module/components/button/index.js +5 -5
  46. package/lib/module/components/button/index.js.map +1 -1
  47. package/lib/module/components/capture-photo/index.js +1 -1
  48. package/lib/module/components/capture-photo/index.js.map +1 -1
  49. package/lib/module/components/card-hours/index.js +5 -5
  50. package/lib/module/components/card-hours/index.js.map +1 -1
  51. package/lib/module/components/card-maintenance/index.js +3 -0
  52. package/lib/module/components/card-maintenance/index.js.map +1 -1
  53. package/lib/module/components/list-supplies/index.js +134 -113
  54. package/lib/module/components/list-supplies/index.js.map +1 -1
  55. package/lib/module/components/maintenance-description-input/index.js +5 -1
  56. package/lib/module/components/maintenance-description-input/index.js.map +1 -1
  57. package/lib/module/components/modal-maintenance/index.js +2 -0
  58. package/lib/module/components/modal-maintenance/index.js.map +1 -1
  59. package/lib/module/components/modal-type-activities/index.js +10 -4
  60. package/lib/module/components/modal-type-activities/index.js.map +1 -1
  61. package/lib/module/components/modals/modal-change-activitie-history/index.js +2 -0
  62. package/lib/module/components/modals/modal-change-activitie-history/index.js.map +1 -1
  63. package/lib/module/components/notification-details-card/index.js +6 -6
  64. package/lib/module/components/report-bobinas/index.js +12 -6
  65. package/lib/module/components/report-bobinas/index.js.map +1 -1
  66. package/lib/module/components/resume-raking/index.js +5 -0
  67. package/lib/module/components/resume-raking/index.js.map +1 -1
  68. package/lib/module/components/step-indicator/index.js +12 -4
  69. package/lib/module/components/step-indicator/index.js.map +1 -1
  70. package/lib/module/components/toast-message/index.js +10 -6
  71. package/lib/module/components/toast-message/index.js.map +1 -1
  72. package/lib/module/components/toggle-fuel/index.js +1 -0
  73. package/lib/module/components/toggle-fuel/index.js.map +1 -1
  74. package/lib/module/components/trip-details-card/index.js +221 -184
  75. package/lib/module/components/trip-details-card/index.js.map +1 -1
  76. package/lib/module/components/typography/index.js +2 -0
  77. package/lib/module/components/typography/index.js.map +1 -1
  78. package/lib/module/components/user-journey-work-card/index.js +14 -0
  79. package/lib/module/components/user-journey-work-card/index.js.map +1 -1
  80. package/lib/module/components/user-profile/index.js +9 -1
  81. package/lib/module/components/user-profile/index.js.map +1 -1
  82. package/lib/module/components/weekly-hours-balance/index.js +2 -0
  83. package/lib/module/components/weekly-hours-balance/index.js.map +1 -1
  84. package/lib/module/index.js +4 -4
  85. package/lib/module/index.js.map +1 -1
  86. package/lib/typescript/commonjs/src/components/box/index.d.ts.map +1 -1
  87. package/lib/typescript/commonjs/src/components/button/index.d.ts.map +1 -1
  88. package/lib/typescript/commonjs/src/components/capture-photo/index.d.ts.map +1 -1
  89. package/lib/typescript/commonjs/src/components/card-hours/index.d.ts.map +1 -1
  90. package/lib/typescript/commonjs/src/components/card-maintenance/index.d.ts.map +1 -1
  91. package/lib/typescript/commonjs/src/components/list-supplies/index.d.ts.map +1 -1
  92. package/lib/typescript/commonjs/src/components/maintenance-description-input/index.d.ts.map +1 -1
  93. package/lib/typescript/commonjs/src/components/modal-maintenance/index.d.ts.map +1 -1
  94. package/lib/typescript/commonjs/src/components/modal-type-activities/index.d.ts.map +1 -1
  95. package/lib/typescript/commonjs/src/components/modal-type-activities/interface.d.ts +2 -0
  96. package/lib/typescript/commonjs/src/components/modal-type-activities/interface.d.ts.map +1 -1
  97. package/lib/typescript/commonjs/src/components/modals/modal-change-activitie-history/index.d.ts.map +1 -1
  98. package/lib/typescript/commonjs/src/components/modals/modal-change-activitie-history/interface.d.ts +4 -0
  99. package/lib/typescript/commonjs/src/components/modals/modal-change-activitie-history/interface.d.ts.map +1 -1
  100. package/lib/typescript/commonjs/src/components/report-bobinas/index.d.ts.map +1 -1
  101. package/lib/typescript/commonjs/src/components/resume-raking/index.d.ts.map +1 -1
  102. package/lib/typescript/commonjs/src/components/resume-raking/interface.d.ts +13 -0
  103. package/lib/typescript/commonjs/src/components/resume-raking/interface.d.ts.map +1 -1
  104. package/lib/typescript/commonjs/src/components/step-indicator/index.d.ts +3 -0
  105. package/lib/typescript/commonjs/src/components/step-indicator/index.d.ts.map +1 -1
  106. package/lib/typescript/commonjs/src/components/toast-message/index.d.ts.map +1 -1
  107. package/lib/typescript/commonjs/src/components/toast-message/interface.d.ts +1 -0
  108. package/lib/typescript/commonjs/src/components/toast-message/interface.d.ts.map +1 -1
  109. package/lib/typescript/commonjs/src/components/toggle-fuel/index.d.ts.map +1 -1
  110. package/lib/typescript/commonjs/src/components/trip-details-card/index.d.ts.map +1 -1
  111. package/lib/typescript/commonjs/src/components/typography/index.d.ts +1 -0
  112. package/lib/typescript/commonjs/src/components/typography/index.d.ts.map +1 -1
  113. package/lib/typescript/commonjs/src/components/user-journey-work-card/index.d.ts.map +1 -1
  114. package/lib/typescript/commonjs/src/components/user-profile/index.d.ts.map +1 -1
  115. package/lib/typescript/commonjs/src/components/weekly-hours-balance/index.d.ts.map +1 -1
  116. package/lib/typescript/commonjs/src/index.d.ts +4 -4
  117. package/lib/typescript/commonjs/src/index.d.ts.map +1 -1
  118. package/lib/typescript/module/src/components/box/index.d.ts.map +1 -1
  119. package/lib/typescript/module/src/components/button/index.d.ts.map +1 -1
  120. package/lib/typescript/module/src/components/capture-photo/index.d.ts.map +1 -1
  121. package/lib/typescript/module/src/components/card-hours/index.d.ts.map +1 -1
  122. package/lib/typescript/module/src/components/card-maintenance/index.d.ts.map +1 -1
  123. package/lib/typescript/module/src/components/list-supplies/index.d.ts.map +1 -1
  124. package/lib/typescript/module/src/components/maintenance-description-input/index.d.ts.map +1 -1
  125. package/lib/typescript/module/src/components/modal-maintenance/index.d.ts.map +1 -1
  126. package/lib/typescript/module/src/components/modal-type-activities/index.d.ts.map +1 -1
  127. package/lib/typescript/module/src/components/modal-type-activities/interface.d.ts +2 -0
  128. package/lib/typescript/module/src/components/modal-type-activities/interface.d.ts.map +1 -1
  129. package/lib/typescript/module/src/components/modals/modal-change-activitie-history/index.d.ts.map +1 -1
  130. package/lib/typescript/module/src/components/modals/modal-change-activitie-history/interface.d.ts +4 -0
  131. package/lib/typescript/module/src/components/modals/modal-change-activitie-history/interface.d.ts.map +1 -1
  132. package/lib/typescript/module/src/components/report-bobinas/index.d.ts.map +1 -1
  133. package/lib/typescript/module/src/components/resume-raking/index.d.ts.map +1 -1
  134. package/lib/typescript/module/src/components/resume-raking/interface.d.ts +13 -0
  135. package/lib/typescript/module/src/components/resume-raking/interface.d.ts.map +1 -1
  136. package/lib/typescript/module/src/components/step-indicator/index.d.ts +3 -0
  137. package/lib/typescript/module/src/components/step-indicator/index.d.ts.map +1 -1
  138. package/lib/typescript/module/src/components/toast-message/index.d.ts.map +1 -1
  139. package/lib/typescript/module/src/components/toast-message/interface.d.ts +1 -0
  140. package/lib/typescript/module/src/components/toast-message/interface.d.ts.map +1 -1
  141. package/lib/typescript/module/src/components/toggle-fuel/index.d.ts.map +1 -1
  142. package/lib/typescript/module/src/components/trip-details-card/index.d.ts.map +1 -1
  143. package/lib/typescript/module/src/components/typography/index.d.ts +1 -0
  144. package/lib/typescript/module/src/components/typography/index.d.ts.map +1 -1
  145. package/lib/typescript/module/src/components/user-journey-work-card/index.d.ts.map +1 -1
  146. package/lib/typescript/module/src/components/user-profile/index.d.ts.map +1 -1
  147. package/lib/typescript/module/src/components/weekly-hours-balance/index.d.ts.map +1 -1
  148. package/lib/typescript/module/src/index.d.ts +4 -4
  149. package/lib/typescript/module/src/index.d.ts.map +1 -1
  150. package/package.json +2 -1
  151. package/src/components/box/index.tsx +53 -53
  152. package/src/components/button/index.tsx +76 -76
  153. package/src/components/capture-photo/index.tsx +1 -1
  154. package/src/components/card-hours/index.tsx +121 -121
  155. package/src/components/card-maintenance/index.tsx +8 -2
  156. package/src/components/card-maintenance/interface.d.ts +4 -0
  157. package/src/components/list-supplies/index.tsx +178 -153
  158. package/src/components/maintenance-description-input/index.tsx +11 -4
  159. package/src/components/modal-maintenance/index.tsx +2 -1
  160. package/src/components/modal-maintenance/interface.d.ts +1 -0
  161. package/src/components/modal-type-activities/index.tsx +23 -5
  162. package/src/components/modal-type-activities/interface.ts +3 -0
  163. package/src/components/modals/modal-change-activitie-history/index.tsx +2 -1
  164. package/src/components/modals/modal-change-activitie-history/interface.ts +4 -0
  165. package/src/components/notification-details-card/index.tsx +180 -180
  166. package/src/components/report-bobinas/index.tsx +185 -175
  167. package/src/components/resume-raking/index.tsx +5 -1
  168. package/src/components/resume-raking/interface.ts +16 -0
  169. package/src/components/step-indicator/index.tsx +26 -8
  170. package/src/components/step-indicator/interface.d.ts +3 -0
  171. package/src/components/toast-message/index.tsx +77 -75
  172. package/src/components/toast-message/interface.ts +18 -17
  173. package/src/components/toggle-fuel/index.tsx +1 -0
  174. package/src/components/trip-details-card/index.tsx +65 -32
  175. package/src/components/typography/index.tsx +2 -0
  176. package/src/components/typography/interface.d.ts +104 -102
  177. package/src/components/user-journey-work-card/index.tsx +23 -2
  178. package/src/components/user-profile/index.tsx +10 -1
  179. package/src/components/weekly-hours-balance/index.tsx +2 -1
  180. package/src/index.tsx +4 -4
@@ -1,175 +1,185 @@
1
- /**
2
- * IMPORTS
3
- */
4
- import React, { forwardRef } from "react";
5
-
6
- // components
7
- import Box from "../../components/box";
8
- import Typography from "../../components/typography";
9
-
10
- // commons / icons
11
- import { Icons } from "../../common/icons-svg";
12
-
13
- // typings
14
- import type { IReportCoils } from "./interface";
15
- import { asBaseComponent } from "../../@types/as-base-component";
16
-
17
- // styles
18
- import { theme } from "../../styles/theme/theme";
19
-
20
- /**
21
- * Componente ReportCoils para a interação da ui.
22
- */
23
- const ReportCoils = forwardRef<any, IReportCoils>((props, ref): React.ReactElement => {
24
- const {
25
- codeDisplayed = 4567,
26
- generatedDate = "15/07/2025",
27
- generatedTime = "10:30",
28
- status = "OK",
29
- backgroundColor,
30
- idWithdrawal = 1,
31
- } = props;
32
- return (
33
- <Box
34
- ref={ref}
35
- width={"100%"}
36
- backgroundColor={theme.colors.neutral[25]}
37
- borderStyled={{
38
- borderRadius: theme.borderWidths.thick_medium,
39
- }}
40
- marginStyle={{
41
- marginBottom: theme.margins["2xs"],
42
- }}
43
- >
44
- <Box
45
- width={"100%"}
46
- height={22}
47
- backgroundColor={backgroundColor ?? theme.colors.green[400]}
48
- borderStyled={{
49
- borderTopLeftRadius: theme.borderWidths.thin_bold,
50
- borderTopRightRadius: theme.borderWidths.thin_bold,
51
- borderColor: theme.colors.blue[400],
52
- }}
53
- flexStyle={{
54
- justifyContent: "center",
55
- }}
56
- >
57
- <Typography
58
- text={`Retirada ${idWithdrawal}`}
59
- color={theme.colors.neutral[25]}
60
- size={theme.fontSizes.sm}
61
- fontFamily={theme.fonts.inter_medium_500}
62
- fontWeight={"500"}
63
- lineHeight={theme.fontSizes.lg}
64
- marginLeft={theme.margins["2xs"]}
65
- />
66
- </Box>
67
- <Box
68
- width={"100%"}
69
- flexStyle={{
70
- flexDirection: "row",
71
- justifyContent: "space-between",
72
- }}
73
- paddingStyle={{
74
- padding: 4,
75
- }}
76
- >
77
- <Box>
78
- <Box
79
- flexStyle={{
80
- flexDirection: "row",
81
- alignItems: "center",
82
- }}
83
- marginStyle={{
84
- marginLeft: 4,
85
- }}
86
- height={45}
87
- >
88
- <Icons icon={"FILES"} size={32} color={theme.colors.blue[100]} />
89
- <Box>
90
- <Box flexStyle={{ flexDirection: "row" }}>
91
- <Typography
92
- text={`Efetuada em: `}
93
- size={12}
94
- color={theme.colors.gray[900]}
95
- fontFamily={theme.fonts.inter_bold_700}
96
- />
97
- <Typography
98
- text={`${generatedDate} ${generatedTime}`}
99
- size={12}
100
- color={theme.colors.gray[700]}
101
- fontFamily={theme.fonts.inter_regular_400}
102
- />
103
- </Box>
104
- <Box marginStyle={{ marginTop: -8 }} flexStyle={{ flexDirection: "row" }}>
105
- <Typography
106
- text={`Status: `}
107
- size={12}
108
- color={theme.colors.gray[900]}
109
- fontFamily={theme.fonts.inter_medium_500}
110
- />
111
-
112
- <Typography
113
- text={`${status}`}
114
- size={12}
115
- color={theme.colors.gray[700]}
116
- fontFamily={theme.fonts.inter_regular_400}
117
- marginLeft={2}
118
- />
119
- </Box>
120
- </Box>
121
- </Box>
122
- </Box>
123
- </Box>
124
-
125
- {/* Segunda separação */}
126
- <Box
127
- width={"100%"}
128
- height={46}
129
- flexStyle={{
130
- flexDirection: "row",
131
- justifyContent: "space-between",
132
- alignItems: "center",
133
- }}
134
- paddingStyle={{
135
- paddingLeft: theme.paddings["2xs"],
136
- paddingRight: theme.paddings["2xs"],
137
- }}
138
- borderStyled={{
139
- borderTopWidth: 2,
140
- borderTopColor: theme.colors.neutral[200],
141
- }}
142
- >
143
- <Box>
144
- <Box flexStyle={{ flexDirection: "row", alignItems: "center" }}>
145
- <Box marginStyle={{ marginRight: 2 }}>
146
- <Typography
147
- text={`Codigo apresentado:`}
148
- size={10}
149
- color={theme.colors.gray[700]}
150
- fontFamily={theme.fonts.inter_regular_400}
151
- />
152
-
153
- <Typography
154
- text={`${codeDisplayed}`}
155
- size={12}
156
- color={theme.colors.blue[100]}
157
- fontFamily={theme.fonts.inter_semi_bold_600}
158
- marginTop={-8}
159
- />
160
- </Box>
161
- </Box>
162
- </Box>
163
-
164
- <Icons icon={"CHECK_CIRCLE"} size={32} background={backgroundColor} />
165
- </Box>
166
- </Box>
167
- );
168
- });
169
-
170
- ReportCoils.displayName = "ReportCoils";
171
-
172
- /**
173
- * EXPORTS
174
- */
175
- export default asBaseComponent(ReportCoils);
1
+ /**
2
+ * IMPORTS
3
+ */
4
+ import React, { forwardRef } from "react";
5
+
6
+ // components
7
+ import Box from "../../components/box";
8
+ import Typography from "../../components/typography";
9
+
10
+ // commons / icons
11
+ import { Icons } from "../../common/icons-svg";
12
+
13
+ // typings
14
+ import type { IReportCoils } from "./interface";
15
+ import { asBaseComponent } from "../../@types/as-base-component";
16
+
17
+ // styles
18
+ import { theme } from "../../styles/theme/theme";
19
+
20
+ /**
21
+ * Componente ReportCoils para a interação da ui.
22
+ */
23
+ const ReportCoils = forwardRef<any, IReportCoils>((props, ref): React.ReactElement => {
24
+ const {
25
+ testID = "report-coils",
26
+ codeDisplayed = 4567,
27
+ generatedDate = "15/07/2025",
28
+ generatedTime = "10:30",
29
+ status = "OK",
30
+ backgroundColor,
31
+ idWithdrawal = 1,
32
+ } = props;
33
+ return (
34
+ <Box
35
+ testID={testID}
36
+ ref={ref}
37
+ width={"100%"}
38
+ backgroundColor={theme.colors.neutral[25]}
39
+ borderStyled={{
40
+ borderRadius: theme.borderWidths.thick_medium,
41
+ }}
42
+ marginStyle={{
43
+ marginBottom: theme.margins["2xs"],
44
+ }}
45
+ >
46
+ <Box
47
+ width={"100%"}
48
+ height={22}
49
+ backgroundColor={backgroundColor ?? theme.colors.green[400]}
50
+ borderStyled={{
51
+ borderTopLeftRadius: theme.borderWidths.thin_bold,
52
+ borderTopRightRadius: theme.borderWidths.thin_bold,
53
+ borderColor: theme.colors.blue[400],
54
+ }}
55
+ flexStyle={{
56
+ justifyContent: "center",
57
+ }}
58
+ >
59
+ <Typography
60
+ testID={`${testID}-retirada`}
61
+ text={`Retirada ${idWithdrawal}`}
62
+ color={theme.colors.neutral[25]}
63
+ size={theme.fontSizes.sm}
64
+ fontFamily={theme.fonts.inter_medium_500}
65
+ fontWeight={"500"}
66
+ lineHeight={theme.fontSizes.lg}
67
+ marginLeft={theme.margins["2xs"]}
68
+ />
69
+ </Box>
70
+ <Box
71
+ width={"100%"}
72
+ flexStyle={{
73
+ flexDirection: "row",
74
+ justifyContent: "space-between",
75
+ }}
76
+ paddingStyle={{
77
+ padding: 4,
78
+ }}
79
+ >
80
+ <Box>
81
+ <Box
82
+ flexStyle={{
83
+ flexDirection: "row",
84
+ alignItems: "center",
85
+ }}
86
+ marginStyle={{
87
+ marginLeft: 4,
88
+ }}
89
+ height={45}
90
+ >
91
+ <Icons
92
+ testID={`${testID}-icon`}
93
+ icon={"FILES"}
94
+ size={32}
95
+ color={theme.colors.blue[100]}
96
+ />
97
+ <Box>
98
+ <Box flexStyle={{ flexDirection: "row" }}>
99
+ <Typography
100
+ testID={`${testID}-efetuada`}
101
+ text={`Efetuada em: `}
102
+ size={12}
103
+ color={theme.colors.gray[900]}
104
+ fontFamily={theme.fonts.inter_bold_700}
105
+ />
106
+ <Typography
107
+ text={`${generatedDate} ${generatedTime}`}
108
+ size={12}
109
+ color={theme.colors.gray[700]}
110
+ fontFamily={theme.fonts.inter_regular_400}
111
+ />
112
+ </Box>
113
+ <Box marginStyle={{ marginTop: -8 }} flexStyle={{ flexDirection: "row" }}>
114
+ <Typography
115
+ testID={`${testID}-status`}
116
+ text={`Status: `}
117
+ size={12}
118
+ color={theme.colors.gray[900]}
119
+ fontFamily={theme.fonts.inter_medium_500}
120
+ />
121
+
122
+ <Typography
123
+ text={`${status}`}
124
+ size={12}
125
+ color={theme.colors.gray[700]}
126
+ fontFamily={theme.fonts.inter_regular_400}
127
+ marginLeft={2}
128
+ />
129
+ </Box>
130
+ </Box>
131
+ </Box>
132
+ </Box>
133
+ </Box>
134
+
135
+ {/* Segunda separação */}
136
+ <Box
137
+ width={"100%"}
138
+ height={46}
139
+ flexStyle={{
140
+ flexDirection: "row",
141
+ justifyContent: "space-between",
142
+ alignItems: "center",
143
+ }}
144
+ paddingStyle={{
145
+ paddingLeft: theme.paddings["2xs"],
146
+ paddingRight: theme.paddings["2xs"],
147
+ }}
148
+ borderStyled={{
149
+ borderTopWidth: 2,
150
+ borderTopColor: theme.colors.neutral[200],
151
+ }}
152
+ >
153
+ <Box>
154
+ <Box flexStyle={{ flexDirection: "row", alignItems: "center" }}>
155
+ <Box marginStyle={{ marginRight: 2 }}>
156
+ <Typography
157
+ text={`Codigo apresentado:`}
158
+ size={10}
159
+ color={theme.colors.gray[700]}
160
+ fontFamily={theme.fonts.inter_regular_400}
161
+ />
162
+
163
+ <Typography
164
+ text={`${codeDisplayed}`}
165
+ size={12}
166
+ color={theme.colors.blue[100]}
167
+ fontFamily={theme.fonts.inter_semi_bold_600}
168
+ marginTop={-8}
169
+ />
170
+ </Box>
171
+ </Box>
172
+ </Box>
173
+
174
+ <Icons icon={"CHECK_CIRCLE"} size={32} background={backgroundColor} />
175
+ </Box>
176
+ </Box>
177
+ );
178
+ });
179
+
180
+ ReportCoils.displayName = "ReportCoils";
181
+
182
+ /**
183
+ * EXPORTS
184
+ */
185
+ export default asBaseComponent(ReportCoils);
@@ -18,9 +18,10 @@ import type { IRankingCard } from "./interface";
18
18
  * Componente ResumeRaking para a interação da ui.
19
19
  */
20
20
  const ResumeRaking = forwardRef<any, IRankingCard>(
21
- ({ title, value, description }, ref): React.ReactElement => {
21
+ ({ testID, title, value, description }, ref): React.ReactElement => {
22
22
  return (
23
23
  <Box
24
+ testID={testID}
24
25
  ref={ref}
25
26
  width={"100%"}
26
27
  backgroundColor={theme.colors.neutral[25]}
@@ -38,6 +39,7 @@ const ResumeRaking = forwardRef<any, IRankingCard>(
38
39
  >
39
40
  {/* título */}
40
41
  <Typography
42
+ testID={`${testID}-title`}
41
43
  text={title}
42
44
  color={theme.colors.black[100]}
43
45
  size={theme.fontSizes.sm}
@@ -48,6 +50,7 @@ const ResumeRaking = forwardRef<any, IRankingCard>(
48
50
 
49
51
  {/* valor principal */}
50
52
  <Typography
53
+ testID={`${testID}-value`}
51
54
  text={value}
52
55
  color={theme.colors.black[180]}
53
56
  size={theme.fontSizes["2xl"]}
@@ -59,6 +62,7 @@ const ResumeRaking = forwardRef<any, IRankingCard>(
59
62
  <Box flexStyle={{ flexDirection: "row", alignItems: "center", justifyContent: "flex-end" }}>
60
63
  {/* descrição */}
61
64
  <Typography
65
+ testID={`${testID}-description`}
62
66
  text={description}
63
67
  color={theme.colors.red[500]}
64
68
  size={theme.fontSizes.sm}
@@ -3,8 +3,24 @@
3
3
  */
4
4
 
5
5
  interface IRankingCard {
6
+ /**
7
+ * TestID para testes automático e identificação
8
+ */
9
+ testID?: string;
10
+
11
+ /**
12
+ * Titulo para o card
13
+ */
6
14
  title: string;
15
+
16
+ /**
17
+ * Valor para o card
18
+ */
7
19
  value: string; // Ex: "53:35 H"
20
+
21
+ /**
22
+ * Descrição para o card
23
+ */
8
24
  description: string; // Ex: "3.200 KM + 60:17 HORAS"
9
25
  }
10
26
 
@@ -1,3 +1,6 @@
1
+ /**
2
+ * IMPORTS
3
+ */
1
4
  import React, { useState, forwardRef, useImperativeHandle, useRef } from "react";
2
5
  import { View, Text, TouchableOpacity, FlatList, FlatList as FlatListType } from "react-native";
3
6
 
@@ -10,23 +13,31 @@ import { Icons } from "../../common/icons-svg";
10
13
  // helpers
11
14
  import { getIconKeyByValue } from "./helpers/get-icon-by-status";
12
15
 
13
- // typings
14
- import type { IStepIndicator } from "./interface";
15
-
16
16
  // utils
17
17
  import { formHoursMinute } from "../../utils/format-date";
18
18
 
19
+ // typings
20
+ import type { IStepIndicator } from "./interface";
21
+ import { asBaseComponent } from "../../@types/as-base-component";
22
+
19
23
  // styles
20
24
  import { styles } from "./styles";
21
25
  import { theme } from "../../styles/theme/theme";
22
- import { asBaseComponent } from "../../@types/as-base-component";
23
26
 
24
27
  /**
25
28
  * Componente StepIndicator para a interação da ui.
26
29
  */
27
30
  const StepIndicator = forwardRef<any, IStepIndicator>(
28
31
  (
29
- { data = [], type, textColorDescription, titleColor, titleNumberColor, onChangeActivity },
32
+ {
33
+ testID = "step-indicator",
34
+ data = [],
35
+ type,
36
+ textColorDescription,
37
+ titleColor,
38
+ titleNumberColor,
39
+ onChangeActivity,
40
+ },
30
41
  ref
31
42
  ) => {
32
43
  const StepDefault = () => {
@@ -83,7 +94,7 @@ const StepIndicator = forwardRef<any, IStepIndicator>(
83
94
 
84
95
  return (
85
96
  <TouchableOpacity
86
- testID="step-indicator"
97
+ testID={`${testID}-item-${index}`}
87
98
  activeOpacity={0.7}
88
99
  style={styles({}).containerIndicator}
89
100
  disabled={!canEdit}
@@ -112,13 +123,19 @@ const StepIndicator = forwardRef<any, IStepIndicator>(
112
123
  <Text style={styles({ titleColor }).title}>{history?.descricao}</Text>
113
124
 
114
125
  {history?.data_inicio && (
115
- <Text style={styles({ textColorDescription }).titleDescription}>
126
+ <Text
127
+ testID={`${testID}-data-${index}`}
128
+ style={styles({ textColorDescription }).titleDescription}
129
+ >
116
130
  {`Inicio: ${history.data_inicio} ás ${history.data_fim}`}
117
131
  </Text>
118
132
  )}
119
133
 
120
134
  {history.duracao_segundos && (
121
- <Text style={styles({ textColorDescription }).titleDescription}>
135
+ <Text
136
+ testID={`${testID}-duration-${index}`}
137
+ style={styles({ textColorDescription }).titleDescription}
138
+ >
122
139
  Duração: {formHoursMinute(history?.duracao_segundos as string)}
123
140
  </Text>
124
141
  )}
@@ -155,6 +172,7 @@ const StepIndicator = forwardRef<any, IStepIndicator>(
155
172
 
156
173
  {isModalVisible && (
157
174
  <ModalChangeActivity
175
+ testID={`${testID}-modal-change-activity`}
158
176
  visible={isModalVisible}
159
177
  modalConfirm={handleConfirmModal}
160
178
  descricao=""
@@ -23,6 +23,9 @@ type IStyleProps = {
23
23
  };
24
24
 
25
25
  interface IStepIndicator {
26
+ /**Identificador para o components */
27
+ testID: string;
28
+
26
29
  /**dados que vão ser renderizados */
27
30
  data?: IData[];
28
31
 
@@ -1,75 +1,77 @@
1
- /**
2
- * IMPORTS
3
- */
4
-
5
- import React, { forwardRef, useMemo } from "react";
6
- import { View } from "react-native";
7
-
8
- // components
9
- import Typography from "../typography";
10
-
11
- // typings
12
- import type { ToastMessageCustoProps } from "./interface";
13
- import { asBaseComponent } from "../../@types/as-base-component";
14
-
15
- import { styles } from "./styles";
16
- import { theme } from "../../styles/theme/theme";
17
-
18
- /**
19
- * Componente ToastMessage para a exibição de mensagens de conexão.
20
- */
21
- const ToastMessage = forwardRef<any, ToastMessageCustoProps>(
22
- ({ text1, text2, options }, ref): React.ReactElement => {
23
- const borderColor = useMemo(() => {
24
- const map = {
25
- success: theme.colors?.green[400] ?? "#69C779",
26
- alert: theme.colors?.blue[800] ?? "#87CEFA",
27
- error: theme.colors?.red[500] ?? "#ef4444",
28
- } as const;
29
- return map[options];
30
- }, [options, theme]);
31
-
32
- return (
33
- <View ref={ref} style={styles.wrapperToash}>
34
- <View style={styles.wrapperBorder}>
35
- <View
36
- testID="border-custom"
37
- style={[styles.borderCustom, { backgroundColor: borderColor }]}
38
- />
39
- </View>
40
-
41
- <View style={styles.wrapperText}>
42
- {!!text1 && (
43
- <Typography
44
- text={String(text1)}
45
- fontFamily={theme.fonts.inter_medium_500}
46
- color={"blue500"}
47
- size={theme.fontSizes.xs}
48
- lineHeight={theme.lineHeight["2xl"]}
49
- letterSpacing={"regular"}
50
- />
51
- )}
52
-
53
- {!!text2 && (
54
- <Typography
55
- text={String(text2)}
56
- fontFamily="inter_regular_400"
57
- color={"black25"}
58
- size={theme.fontSizes.xs}
59
- lineHeight={theme.lineHeight["2xl"]}
60
- letterSpacing={"regular"}
61
- marginBottom={4}
62
- />
63
- )}
64
- </View>
65
- </View>
66
- );
67
- }
68
- );
69
-
70
- ToastMessage.displayName = "ToastMessage";
71
-
72
- /**
73
- * EXPORT
74
- */
75
- export default asBaseComponent(ToastMessage);
1
+ /**
2
+ * IMPORTS
3
+ */
4
+
5
+ import React, { forwardRef, useMemo } from "react";
6
+ import { View } from "react-native";
7
+
8
+ // components
9
+ import Typography from "../typography";
10
+
11
+ // typings
12
+ import type { ToastMessageCustoProps } from "./interface";
13
+ import { asBaseComponent } from "../../@types/as-base-component";
14
+
15
+ import { styles } from "./styles";
16
+ import { theme } from "../../styles/theme/theme";
17
+
18
+ /**
19
+ * Componente ToastMessage para a exibição de mensagens de conexão.
20
+ */
21
+ const ToastMessage = forwardRef<any, ToastMessageCustoProps>(
22
+ ({ testID, text1, text2, options }, ref): React.ReactElement => {
23
+ const borderColor = useMemo(() => {
24
+ const map = {
25
+ success: theme.colors?.green[400] ?? "#69C779",
26
+ alert: theme.colors?.blue[800] ?? "#87CEFA",
27
+ error: theme.colors?.red[500] ?? "#ef4444",
28
+ } as const;
29
+ return map[options];
30
+ }, [options, theme]);
31
+
32
+ return (
33
+ <View testID={testID} ref={ref} style={styles.wrapperToash}>
34
+ <View style={styles.wrapperBorder}>
35
+ <View
36
+ testID="border-custom"
37
+ style={[styles.borderCustom, { backgroundColor: borderColor }]}
38
+ />
39
+ </View>
40
+
41
+ <View style={styles.wrapperText}>
42
+ {!!text1 && (
43
+ <Typography
44
+ testID={`${testID}-text1`}
45
+ text={String(text1)}
46
+ fontFamily={theme.fonts.inter_medium_500}
47
+ color={"blue500"}
48
+ size={theme.fontSizes.xs}
49
+ lineHeight={theme.lineHeight["2xl"]}
50
+ letterSpacing={"regular"}
51
+ />
52
+ )}
53
+
54
+ {!!text2 && (
55
+ <Typography
56
+ testID={`${testID}-text2`}
57
+ text={String(text2)}
58
+ fontFamily="inter_regular_400"
59
+ color={"black25"}
60
+ size={theme.fontSizes.xs}
61
+ lineHeight={theme.lineHeight["2xl"]}
62
+ letterSpacing={"regular"}
63
+ marginBottom={4}
64
+ />
65
+ )}
66
+ </View>
67
+ </View>
68
+ );
69
+ }
70
+ );
71
+
72
+ ToastMessage.displayName = "ToastMessage";
73
+
74
+ /**
75
+ * EXPORT
76
+ */
77
+ export default asBaseComponent(ToastMessage);