react-native-exp-fig 0.1.8 → 0.1.10
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/check-box/index.js +6 -6
- package/lib/commonjs/common/icons-svg/constants/index.js +4 -4
- package/lib/commonjs/common/icons-svg/index.js +10 -7
- package/lib/commonjs/common/icons-svg/index.js.map +1 -1
- package/lib/commonjs/components/card-work-session/index.js +35 -3
- package/lib/commonjs/components/card-work-session/index.js.map +1 -1
- package/lib/commonjs/components/check-box/index.js +6 -6
- package/lib/commonjs/components/coil/index.js +14 -8
- package/lib/commonjs/components/coil/index.js.map +1 -1
- package/lib/commonjs/components/header-profile/index.js +6 -6
- package/lib/commonjs/stories/card-work-session/card-work-session.stories.js +18 -3
- package/lib/commonjs/stories/card-work-session/card-work-session.stories.js.map +1 -1
- package/lib/commonjs/stories/coil/coil.stories.js +6 -5
- package/lib/commonjs/stories/coil/coil.stories.js.map +1 -1
- package/lib/commonjs/styles/theme/theme.js +1 -0
- package/lib/commonjs/styles/theme/theme.js.map +1 -1
- package/lib/module/common/icons-svg/check-box/index.js +6 -6
- package/lib/module/common/icons-svg/constants/index.js +4 -4
- package/lib/module/common/icons-svg/index.js +10 -7
- package/lib/module/common/icons-svg/index.js.map +1 -1
- package/lib/module/components/card-work-session/index.js +35 -3
- package/lib/module/components/card-work-session/index.js.map +1 -1
- package/lib/module/components/check-box/index.js +6 -6
- package/lib/module/components/coil/index.js +14 -8
- package/lib/module/components/coil/index.js.map +1 -1
- package/lib/module/components/header-profile/index.js +6 -6
- package/lib/module/stories/card-work-session/card-work-session.stories.js +17 -2
- package/lib/module/stories/card-work-session/card-work-session.stories.js.map +1 -1
- package/lib/module/stories/coil/coil.stories.js +6 -5
- package/lib/module/stories/coil/coil.stories.js.map +1 -1
- package/lib/module/styles/theme/theme.js +1 -0
- package/lib/module/styles/theme/theme.js.map +1 -1
- package/lib/typescript/commonjs/src/common/icons-svg/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/components/card-work-session/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/components/coil/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/stories/card-work-session/card-work-session.stories.d.ts +1 -0
- package/lib/typescript/commonjs/src/stories/card-work-session/card-work-session.stories.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/stories/coil/coil.stories.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/styles/global/theme-provider.d.ts +1 -0
- package/lib/typescript/commonjs/src/styles/global/theme-provider.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/styles/theme/theme.d.ts +1 -0
- package/lib/typescript/commonjs/src/styles/theme/theme.d.ts.map +1 -1
- package/lib/typescript/module/src/common/icons-svg/index.d.ts.map +1 -1
- package/lib/typescript/module/src/components/card-work-session/index.d.ts.map +1 -1
- package/lib/typescript/module/src/components/coil/index.d.ts.map +1 -1
- package/lib/typescript/module/src/stories/card-work-session/card-work-session.stories.d.ts +1 -0
- package/lib/typescript/module/src/stories/card-work-session/card-work-session.stories.d.ts.map +1 -1
- package/lib/typescript/module/src/stories/coil/coil.stories.d.ts.map +1 -1
- package/lib/typescript/module/src/styles/global/theme-provider.d.ts +1 -0
- package/lib/typescript/module/src/styles/global/theme-provider.d.ts.map +1 -1
- package/lib/typescript/module/src/styles/theme/theme.d.ts +1 -0
- package/lib/typescript/module/src/styles/theme/theme.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/common/icons-svg/agent/index.tsx +40 -0
- package/src/common/icons-svg/bed/index.tsx +41 -0
- package/src/common/icons-svg/car/index.tsx +29 -0
- package/src/common/icons-svg/check-box/index.tsx +28 -28
- package/src/common/icons-svg/check-outline/index.tsx +42 -0
- package/src/common/icons-svg/coffee/index.tsx +43 -0
- package/src/common/icons-svg/constants/index.ts +8 -0
- package/src/common/icons-svg/index.tsx +57 -5
- package/src/common/icons-svg/pencil/index.tsx +32 -0
- package/src/common/icons-svg/refresh-ccw-dot/index.tsx +32 -0
- package/src/common/icons-svg/truck-activity/index.tsx +29 -0
- package/src/components/activities-daily/index.tsx +116 -0
- package/src/components/activities-daily/interface.d.ts +22 -0
- package/src/components/activities-progress/index.tsx +162 -0
- package/src/components/activities-progress/interface.d.ts +41 -0
- package/src/components/avatar-profile/index.tsx +95 -0
- package/src/components/avatar-profile/interface.d.ts +39 -0
- package/src/components/card-history/index.tsx +149 -150
- package/src/components/card-loading/index.tsx +16 -1
- package/src/components/card-work-session/index.tsx +187 -161
- package/src/components/card-work-session/interface.d.ts +5 -0
- package/src/components/check-box/index.tsx +22 -53
- package/src/components/check-box/interface.d.ts +31 -27
- package/src/components/coil/index.tsx +103 -90
- package/src/components/coil/interface.d.ts +26 -26
- package/src/components/filter-date-selector/index.tsx +101 -89
- package/src/components/header-profile/index.tsx +132 -132
- package/src/components/history-details/index.tsx +100 -0
- package/src/components/history-details/interface.d.ts +18 -0
- package/src/components/image-capture-with-remove/index.tsx +8 -2
- package/src/components/image-capture-with-remove/interface.d.ts +3 -0
- package/src/components/notification-loading/index.tsx +18 -7
- package/src/components/notification-loading/interface.d.ts +4 -0
- package/src/components/profile-menu-option/index.tsx +65 -0
- package/src/components/profile-menu-option/interface.d.ts +42 -0
- package/src/components/step-indicator/index.tsx +164 -164
- package/src/components/step-indicator/interface.d.ts +34 -34
- package/src/components/user-profile/index.tsx +58 -70
- package/src/index.ts +42 -37
- package/src/stories/activities-daily/activities-daily.stories.tsx +40 -0
- package/src/stories/activities-progress/activities-progress.stories.tsx +61 -0
- package/src/stories/avatar-profile/avatar-profile.stories.tsx +32 -0
- package/src/stories/card-loading/card-loading.stories.tsx +2 -2
- package/src/stories/card-work-session/card-work-session.stories.tsx +16 -1
- package/src/stories/check-box/check-box.stories.tsx +81 -83
- package/src/stories/coil/coil.stories.tsx +98 -74
- package/src/stories/filter-date-selector/filter-date-selector.stories.tsx +122 -93
- package/src/stories/header-profile/header-profile.stories.tsx +103 -103
- package/src/stories/history-details/history-details.stories.tsx +36 -0
- package/src/stories/image-capture-with-remove/image-capture-with-remove.stories.tsx +10 -0
- package/src/stories/notification-loading/notification-loading.stories.tsx +15 -0
- package/src/stories/profile-menu-option/profile-menu-option.stories.tsx +70 -0
- package/src/stories/step-indicator/step-indicator.stories.tsx +124 -116
- package/src/styles/global/interface.d.ts +10 -0
- package/src/styles/theme/theme.ts +3 -0
- package/src/utils/format-data/index.ts +66 -40
- package/src/utils/status-color/return-color.ts +12 -4
|
@@ -1,90 +1,103 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* IMPORTS
|
|
3
|
-
*/
|
|
4
|
-
import React from "react";
|
|
5
|
-
import { TouchableOpacity } from "react-native";
|
|
6
|
-
|
|
7
|
-
// components
|
|
8
|
-
import { Box } from "../box";
|
|
9
|
-
import { Typography } from "../typography";
|
|
10
|
-
|
|
11
|
-
// icons
|
|
12
|
-
import { Icons } from "../../common/icons-svg";
|
|
13
|
-
|
|
14
|
-
// theme
|
|
15
|
-
import { theme } from "../../styles/theme/theme";
|
|
16
|
-
|
|
17
|
-
import { ICoil } from "./interface";
|
|
18
|
-
|
|
19
|
-
const Coil: React.FC<ICoil> = ({
|
|
20
|
-
description,
|
|
21
|
-
handleNavigation,
|
|
22
|
-
title,
|
|
23
|
-
testID,
|
|
24
|
-
status,
|
|
25
|
-
backgroundColor,
|
|
26
|
-
style,
|
|
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
|
-
|
|
1
|
+
/**
|
|
2
|
+
* IMPORTS
|
|
3
|
+
*/
|
|
4
|
+
import React from "react";
|
|
5
|
+
import { TouchableOpacity } from "react-native";
|
|
6
|
+
|
|
7
|
+
// components
|
|
8
|
+
import { Box } from "../box";
|
|
9
|
+
import { Typography } from "../typography";
|
|
10
|
+
|
|
11
|
+
// icons
|
|
12
|
+
import { Icons } from "../../common/icons-svg";
|
|
13
|
+
|
|
14
|
+
// theme
|
|
15
|
+
import { theme } from "../../styles/theme/theme";
|
|
16
|
+
|
|
17
|
+
import { ICoil } from "./interface";
|
|
18
|
+
|
|
19
|
+
const Coil: React.FC<ICoil> = ({
|
|
20
|
+
description,
|
|
21
|
+
handleNavigation,
|
|
22
|
+
title,
|
|
23
|
+
testID,
|
|
24
|
+
status,
|
|
25
|
+
backgroundColor,
|
|
26
|
+
style,
|
|
27
|
+
disabled,
|
|
28
|
+
backgroundColorIcon,
|
|
29
|
+
}) => {
|
|
30
|
+
return (
|
|
31
|
+
<TouchableOpacity
|
|
32
|
+
disabled={disabled}
|
|
33
|
+
activeOpacity={0.7}
|
|
34
|
+
testID={testID}
|
|
35
|
+
onPress={handleNavigation}
|
|
36
|
+
>
|
|
37
|
+
<Box
|
|
38
|
+
width={"100%"}
|
|
39
|
+
flexStyle={{ flexDirection: "row", alignItems: "center" }}
|
|
40
|
+
height={70}
|
|
41
|
+
backgroundColor={backgroundColor ?? theme.colors.blue[400]}
|
|
42
|
+
borderStyled={{
|
|
43
|
+
borderWidth: theme.borderWidths.thin,
|
|
44
|
+
borderRadius: theme.borderWidths.thick_medium,
|
|
45
|
+
borderColor: backgroundColor ?? theme.colors.blue[400],
|
|
46
|
+
}}
|
|
47
|
+
paddingStyle={{ padding: theme.paddings["2xs"] }}
|
|
48
|
+
marginStyle={{ marginBottom: theme.margins.md }}
|
|
49
|
+
style={[style, { elevation: 5 }]}
|
|
50
|
+
>
|
|
51
|
+
<Box
|
|
52
|
+
width={"80%"}
|
|
53
|
+
height={70}
|
|
54
|
+
flexStyle={{ flexDirection: "row", alignItems: "center", justifyContent: "flex-start" }}
|
|
55
|
+
>
|
|
56
|
+
<Icons icon={"LIFEBUOY"} size={32} />
|
|
57
|
+
|
|
58
|
+
<Box
|
|
59
|
+
flexStyle={{ flexDirection: "column", flexWrap: "wrap" }}
|
|
60
|
+
marginStyle={{ marginLeft: theme.margins.lg }}
|
|
61
|
+
>
|
|
62
|
+
<Typography
|
|
63
|
+
text={title}
|
|
64
|
+
size={theme.fontSizes["2xl"]}
|
|
65
|
+
fontFamily={theme.fonts.inter_bold_700}
|
|
66
|
+
color={theme.colors.neutral[25]}
|
|
67
|
+
letterSpacing={"regular"}
|
|
68
|
+
paddingTop={theme.paddings.md}
|
|
69
|
+
/>
|
|
70
|
+
<Typography
|
|
71
|
+
text={description}
|
|
72
|
+
size={theme.fontSizes["2xs"]}
|
|
73
|
+
fontFamily={theme.fonts.inter_semi_bold_600}
|
|
74
|
+
color={theme.colors.neutral[25]}
|
|
75
|
+
letterSpacing={"regular"}
|
|
76
|
+
/>
|
|
77
|
+
</Box>
|
|
78
|
+
</Box>
|
|
79
|
+
|
|
80
|
+
<Box
|
|
81
|
+
width={"20%"}
|
|
82
|
+
flexStyle={{ flexDirection: "row", alignItems: "center", justifyContent: "flex-end" }}
|
|
83
|
+
height={70}
|
|
84
|
+
>
|
|
85
|
+
{status === "Cancelado" && (
|
|
86
|
+
<Icons icon={"RECUSED"} size={32} background={backgroundColorIcon} />
|
|
87
|
+
)}
|
|
88
|
+
{status === "Concluido" && (
|
|
89
|
+
<Icons icon={"CHECK_CIRCLE"} size={32} background={backgroundColorIcon} />
|
|
90
|
+
)}
|
|
91
|
+
{(status === "Pendente" || status === "Andamento") && (
|
|
92
|
+
<Icons icon={"EXCLAMATION_CIRCLE"} size={32} background={backgroundColorIcon} />
|
|
93
|
+
)}
|
|
94
|
+
</Box>
|
|
95
|
+
</Box>
|
|
96
|
+
</TouchableOpacity>
|
|
97
|
+
);
|
|
98
|
+
};
|
|
99
|
+
|
|
100
|
+
/**
|
|
101
|
+
* EXPORTS
|
|
102
|
+
*/
|
|
103
|
+
export { Coil };
|
|
@@ -1,26 +1,26 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* IMPORTS
|
|
3
|
-
*/
|
|
4
|
-
import { ViewProps } from "react-native";
|
|
5
|
-
|
|
6
|
-
// typing
|
|
7
|
-
import { IGlobalCss } from "../../styles/global/interface";
|
|
8
|
-
|
|
9
|
-
interface ICoil extends ViewProps, IGlobalCss {
|
|
10
|
-
/**propriedade que indica o título da bobina */
|
|
11
|
-
title: string;
|
|
12
|
-
|
|
13
|
-
/**propriedade que indica a descrição da bobina */
|
|
14
|
-
description: string;
|
|
15
|
-
|
|
16
|
-
/**propriedade que indica que levar para tela da bobina */
|
|
17
|
-
handleNavigation: () => void;
|
|
18
|
-
|
|
19
|
-
/**propriedade que indica status da bobina */
|
|
20
|
-
status?: "
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
/**
|
|
24
|
-
* EXPORTS
|
|
25
|
-
*/
|
|
26
|
-
export { ICoil };
|
|
1
|
+
/**
|
|
2
|
+
* IMPORTS
|
|
3
|
+
*/
|
|
4
|
+
import { ViewProps } from "react-native";
|
|
5
|
+
|
|
6
|
+
// typing
|
|
7
|
+
import { IGlobalCss } from "../../styles/global/interface";
|
|
8
|
+
|
|
9
|
+
interface ICoil extends ViewProps, IGlobalCss {
|
|
10
|
+
/**propriedade que indica o título da bobina */
|
|
11
|
+
title: string;
|
|
12
|
+
|
|
13
|
+
/**propriedade que indica a descrição da bobina */
|
|
14
|
+
description: string;
|
|
15
|
+
|
|
16
|
+
/**propriedade que indica que levar para tela da bobina */
|
|
17
|
+
handleNavigation: () => void;
|
|
18
|
+
|
|
19
|
+
/**propriedade que indica status da bobina */
|
|
20
|
+
status?: "Cancelado" | "Pendente" | "Concluido" | "Andamento";
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
/**
|
|
24
|
+
* EXPORTS
|
|
25
|
+
*/
|
|
26
|
+
export { ICoil };
|
|
@@ -1,89 +1,101 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* IMPORTS
|
|
3
|
-
*/
|
|
4
|
-
import React from "react";
|
|
5
|
-
import { TouchableOpacity, ActivityIndicator, FlatList } from "react-native";
|
|
6
|
-
|
|
7
|
-
// components
|
|
8
|
-
import { Box } from "../box";
|
|
9
|
-
import { Typography } from "../typography";
|
|
10
|
-
|
|
11
|
-
// styles
|
|
12
|
-
import { theme } from "../../styles/theme/theme";
|
|
13
|
-
|
|
14
|
-
//typing
|
|
15
|
-
import { IFilterDateSelector, ISelectedDay } from "./interface";
|
|
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
|
-
|
|
1
|
+
/**
|
|
2
|
+
* IMPORTS
|
|
3
|
+
*/
|
|
4
|
+
import React from "react";
|
|
5
|
+
import { TouchableOpacity, ActivityIndicator, FlatList } from "react-native";
|
|
6
|
+
|
|
7
|
+
// components
|
|
8
|
+
import { Box } from "../box";
|
|
9
|
+
import { Typography } from "../typography";
|
|
10
|
+
|
|
11
|
+
// styles
|
|
12
|
+
import { theme } from "../../styles/theme/theme";
|
|
13
|
+
|
|
14
|
+
//typing
|
|
15
|
+
import { IFilterDateSelector, ISelectedDay } from "./interface";
|
|
16
|
+
import { Icons } from "../../common/icons-svg";
|
|
17
|
+
|
|
18
|
+
/**
|
|
19
|
+
*
|
|
20
|
+
* Componente FilterDateSelector para a interação do usuário com ui.
|
|
21
|
+
*/
|
|
22
|
+
const FilterDateSelector: React.FC<IFilterDateSelector> = ({
|
|
23
|
+
selectedDay,
|
|
24
|
+
handleSelectedDay,
|
|
25
|
+
days,
|
|
26
|
+
isLoading,
|
|
27
|
+
testID,
|
|
28
|
+
}) => {
|
|
29
|
+
const renderDayBlock = ({ item: day, index }: { item: ISelectedDay; index: number }) => {
|
|
30
|
+
const isSelected = selectedDay && selectedDay.date === day.date;
|
|
31
|
+
return (
|
|
32
|
+
<TouchableOpacity
|
|
33
|
+
disabled={isSelected}
|
|
34
|
+
key={index}
|
|
35
|
+
activeOpacity={0.7}
|
|
36
|
+
onPress={() => handleSelectedDay(day)}
|
|
37
|
+
>
|
|
38
|
+
<Box
|
|
39
|
+
testID={testID}
|
|
40
|
+
width={65}
|
|
41
|
+
height={75}
|
|
42
|
+
flexStyle={{ alignItems: "center", justifyContent: "center" }}
|
|
43
|
+
backgroundColor={isSelected ? theme.colors.blue[400] : theme.colors.gray[350]}
|
|
44
|
+
borderStyled={{
|
|
45
|
+
borderRadius: theme.borderWidths.thick_large,
|
|
46
|
+
borderColor: isSelected ? theme.colors.blue[400] : theme.colors.gray[350],
|
|
47
|
+
borderWidth: theme.borderWidths.thin,
|
|
48
|
+
}}
|
|
49
|
+
marginStyle={{ marginRight: theme.margins["2xs"], marginTop: theme.margins["2xs"] }}
|
|
50
|
+
>
|
|
51
|
+
{isSelected && isLoading ? (
|
|
52
|
+
<ActivityIndicator size="small" color="white" />
|
|
53
|
+
) : (
|
|
54
|
+
<>
|
|
55
|
+
{day.date === "all" ? (
|
|
56
|
+
<Icons icon="REFRESH_CCW_DOT" color={theme.colors.neutral[25]} />
|
|
57
|
+
) : (
|
|
58
|
+
<>
|
|
59
|
+
<Typography
|
|
60
|
+
text={day.date === "all" ? "" : day.date.toString().padStart(2, "0")}
|
|
61
|
+
size={theme.fontSizes.lg}
|
|
62
|
+
color={theme.colors.neutral[25]}
|
|
63
|
+
fontFamily={theme.fonts.inter_bold_700}
|
|
64
|
+
/>
|
|
65
|
+
<Typography
|
|
66
|
+
text={day.date === "all" ? "Todos" : day.dayName.slice(0, 3)}
|
|
67
|
+
size={theme.fontSizes.lg}
|
|
68
|
+
color={theme.colors.neutral[25]}
|
|
69
|
+
fontFamily={theme.fonts.inter_bold_700}
|
|
70
|
+
marginBottom={day.date === "all" ? theme.margins["3xl"] : 0}
|
|
71
|
+
letterSpacing="o_16"
|
|
72
|
+
/>
|
|
73
|
+
</>
|
|
74
|
+
)}
|
|
75
|
+
</>
|
|
76
|
+
)}
|
|
77
|
+
</Box>
|
|
78
|
+
</TouchableOpacity>
|
|
79
|
+
);
|
|
80
|
+
};
|
|
81
|
+
const daySorted = days.sort(
|
|
82
|
+
(a, b) => new Date(b.fullDate).getTime() - new Date(a.fullDate).getTime()
|
|
83
|
+
);
|
|
84
|
+
|
|
85
|
+
// Adiciona a opção "Todos" no início da lista
|
|
86
|
+
const dataWithAllOption = [...daySorted];
|
|
87
|
+
|
|
88
|
+
return (
|
|
89
|
+
<FlatList
|
|
90
|
+
horizontal
|
|
91
|
+
data={dataWithAllOption}
|
|
92
|
+
showsHorizontalScrollIndicator={false}
|
|
93
|
+
renderItem={renderDayBlock}
|
|
94
|
+
/>
|
|
95
|
+
);
|
|
96
|
+
};
|
|
97
|
+
|
|
98
|
+
/**
|
|
99
|
+
* EXPORTS
|
|
100
|
+
*/
|
|
101
|
+
export { FilterDateSelector };
|