jornada-ui 0.4.14 → 0.4.16
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 +2 -1
- package/lib/commonjs/common/icons-svg/constants/index.js.map +1 -1
- package/lib/commonjs/common/icons-svg/download/index.js +53 -0
- package/lib/commonjs/common/icons-svg/download/index.js.map +1 -0
- package/lib/commonjs/common/icons-svg/index.js +7 -0
- package/lib/commonjs/common/icons-svg/index.js.map +1 -1
- package/lib/commonjs/components/activities-progress/index.js +10 -10
- package/lib/commonjs/components/activities-progress/index.js.map +1 -1
- package/lib/commonjs/components/card-work-session/index.js +50 -17
- package/lib/commonjs/components/card-work-session/index.js.map +1 -1
- package/lib/commonjs/components/inputs/input-date-time/index.js +11 -9
- package/lib/commonjs/components/inputs/input-date-time/index.js.map +1 -1
- package/lib/commonjs/components/inputs/input-date-time/styles.js +6 -3
- package/lib/commonjs/components/inputs/input-date-time/styles.js.map +1 -1
- package/lib/commonjs/components/modals/{modal-journey-rectification → modal-edite-journey-rectification}/index.js +71 -65
- package/lib/commonjs/components/modals/modal-edite-journey-rectification/index.js.map +1 -0
- package/lib/commonjs/components/modals/modal-edite-journey-rectification/interface.d.js.map +1 -0
- package/lib/commonjs/components/notification-card/index.js +142 -0
- package/lib/commonjs/components/notification-card/index.js.map +1 -0
- package/lib/commonjs/components/notification-card/interface.js +6 -0
- package/lib/commonjs/components/notification-card/interface.js.map +1 -0
- package/lib/commonjs/components/notification-details-card/index.js +181 -0
- package/lib/commonjs/components/notification-details-card/index.js.map +1 -0
- package/lib/commonjs/components/notification-details-card/interface.js +6 -0
- package/lib/commonjs/components/notification-details-card/interface.js.map +1 -0
- package/lib/commonjs/components/user-journey-work-card/index.js +44 -4
- package/lib/commonjs/components/user-journey-work-card/index.js.map +1 -1
- package/lib/commonjs/index.js +19 -5
- package/lib/commonjs/index.js.map +1 -1
- package/lib/commonjs/stories/button/button.stories.js +0 -2
- package/lib/commonjs/stories/button/button.stories.js.map +1 -1
- package/lib/commonjs/stories/capture-photo/capture-photo.stories.js +0 -1
- package/lib/commonjs/stories/capture-photo/capture-photo.stories.js.map +1 -1
- package/lib/commonjs/stories/card-work-session/card-work-session.stories.js +62 -9
- package/lib/commonjs/stories/card-work-session/card-work-session.stories.js.map +1 -1
- package/lib/commonjs/stories/modal-journey-rectification/modal-journey-rectification.stories.js +3 -3
- package/lib/commonjs/stories/modal-journey-rectification/modal-journey-rectification.stories.js.map +1 -1
- package/lib/commonjs/stories/notification-card/notification-card.stories.js +100 -0
- package/lib/commonjs/stories/notification-card/notification-card.stories.js.map +1 -0
- package/lib/commonjs/stories/notification-details-card/notification-details-card.stories.js +112 -0
- package/lib/commonjs/stories/notification-details-card/notification-details-card.stories.js.map +1 -0
- package/lib/commonjs/stories/user-journey-work-card/user-journey-work-card.stories.js +12 -4
- package/lib/commonjs/stories/user-journey-work-card/user-journey-work-card.stories.js.map +1 -1
- package/lib/commonjs/styles/theme/theme.js +2 -1
- package/lib/commonjs/styles/theme/theme.js.map +1 -1
- package/lib/module/common/icons-svg/constants/index.js +2 -1
- package/lib/module/common/icons-svg/constants/index.js.map +1 -1
- package/lib/module/common/icons-svg/download/index.js +47 -0
- package/lib/module/common/icons-svg/download/index.js.map +1 -0
- package/lib/module/common/icons-svg/index.js +7 -0
- package/lib/module/common/icons-svg/index.js.map +1 -1
- package/lib/module/components/activities-progress/index.js +10 -10
- package/lib/module/components/activities-progress/index.js.map +1 -1
- package/lib/module/components/card-work-session/index.js +50 -17
- package/lib/module/components/card-work-session/index.js.map +1 -1
- package/lib/module/components/inputs/input-date-time/index.js +11 -9
- package/lib/module/components/inputs/input-date-time/index.js.map +1 -1
- package/lib/module/components/inputs/input-date-time/styles.js +6 -3
- package/lib/module/components/inputs/input-date-time/styles.js.map +1 -1
- package/lib/module/components/modals/{modal-journey-rectification → modal-edite-journey-rectification}/index.js +69 -63
- package/lib/module/components/modals/modal-edite-journey-rectification/index.js.map +1 -0
- package/lib/module/components/modals/modal-edite-journey-rectification/interface.d.js.map +1 -0
- package/lib/module/components/notification-card/index.js +135 -0
- package/lib/module/components/notification-card/index.js.map +1 -0
- package/lib/module/components/notification-card/interface.js +4 -0
- package/lib/module/components/notification-card/interface.js.map +1 -0
- package/lib/module/components/notification-details-card/index.js +183 -0
- package/lib/module/components/notification-details-card/index.js.map +1 -0
- package/lib/module/components/notification-details-card/interface.js +4 -0
- package/lib/module/components/notification-details-card/interface.js.map +1 -0
- package/lib/module/components/user-journey-work-card/index.js +44 -4
- package/lib/module/components/user-journey-work-card/index.js.map +1 -1
- package/lib/module/index.js +3 -1
- package/lib/module/index.js.map +1 -1
- package/lib/module/stories/button/button.stories.js +0 -1
- package/lib/module/stories/button/button.stories.js.map +1 -1
- package/lib/module/stories/capture-photo/capture-photo.stories.js +0 -1
- package/lib/module/stories/capture-photo/capture-photo.stories.js.map +1 -1
- package/lib/module/stories/card-work-session/card-work-session.stories.js +62 -9
- package/lib/module/stories/card-work-session/card-work-session.stories.js.map +1 -1
- package/lib/module/stories/modal-journey-rectification/modal-journey-rectification.stories.js +3 -3
- package/lib/module/stories/modal-journey-rectification/modal-journey-rectification.stories.js.map +1 -1
- package/lib/module/stories/notification-card/notification-card.stories.js +95 -0
- package/lib/module/stories/notification-card/notification-card.stories.js.map +1 -0
- package/lib/module/stories/notification-details-card/notification-details-card.stories.js +107 -0
- package/lib/module/stories/notification-details-card/notification-details-card.stories.js.map +1 -0
- package/lib/module/stories/user-journey-work-card/user-journey-work-card.stories.js +12 -4
- package/lib/module/stories/user-journey-work-card/user-journey-work-card.stories.js.map +1 -1
- package/lib/module/styles/theme/theme.js +2 -1
- package/lib/module/styles/theme/theme.js.map +1 -1
- package/lib/typescript/commonjs/src/common/icons-svg/constants/index.d.ts +1 -0
- package/lib/typescript/commonjs/src/common/icons-svg/constants/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/common/icons-svg/download/index.d.ts +11 -0
- package/lib/typescript/commonjs/src/common/icons-svg/download/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/common/icons-svg/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/components/card-report/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/components/card-scheduled-journey/index.d.ts +1 -1
- package/lib/typescript/commonjs/src/components/card-work-session/index.d.ts +2 -1
- package/lib/typescript/commonjs/src/components/card-work-session/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/components/inputs/input-date-time/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/components/inputs/input-date-time/styles.d.ts +2 -1
- package/lib/typescript/commonjs/src/components/inputs/input-date-time/styles.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/components/modals/{modal-journey-rectification → modal-edite-journey-rectification}/index.d.ts +3 -0
- package/lib/typescript/commonjs/src/components/modals/modal-edite-journey-rectification/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification-card/index.d.ts +11 -0
- package/lib/typescript/commonjs/src/components/notification-card/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification-card/interface.d.ts +17 -0
- package/lib/typescript/commonjs/src/components/notification-card/interface.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification-details-card/index.d.ts +11 -0
- package/lib/typescript/commonjs/src/components/notification-details-card/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification-details-card/interface.d.ts +15 -0
- package/lib/typescript/commonjs/src/components/notification-details-card/interface.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/selects/select-date-and-hours/index.d.ts +1 -1
- package/lib/typescript/commonjs/src/components/travel-history/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/components/user-journey-work-card/index.d.ts +2 -0
- package/lib/typescript/commonjs/src/components/user-journey-work-card/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/index.d.ts +3 -1
- package/lib/typescript/commonjs/src/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/stories/card-work-session/card-work-session.stories.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/stories/modal-journey-rectification/modal-journey-rectification.stories.d.ts +1 -1
- package/lib/typescript/commonjs/src/stories/modal-journey-rectification/modal-journey-rectification.stories.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/stories/notification-card/notification-card.stories.d.ts +14 -0
- package/lib/typescript/commonjs/src/stories/notification-card/notification-card.stories.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/stories/notification-details-card/notification-details-card.stories.d.ts +16 -0
- package/lib/typescript/commonjs/src/stories/notification-details-card/notification-details-card.stories.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/stories/user-journey-work-card/user-journey-work-card.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/constants/index.d.ts +1 -0
- package/lib/typescript/module/src/common/icons-svg/constants/index.d.ts.map +1 -1
- package/lib/typescript/module/src/common/icons-svg/download/index.d.ts +11 -0
- package/lib/typescript/module/src/common/icons-svg/download/index.d.ts.map +1 -0
- package/lib/typescript/module/src/common/icons-svg/index.d.ts.map +1 -1
- package/lib/typescript/module/src/components/card-report/index.d.ts.map +1 -1
- package/lib/typescript/module/src/components/card-scheduled-journey/index.d.ts +1 -1
- package/lib/typescript/module/src/components/card-work-session/index.d.ts +2 -1
- package/lib/typescript/module/src/components/card-work-session/index.d.ts.map +1 -1
- package/lib/typescript/module/src/components/inputs/input-date-time/index.d.ts.map +1 -1
- package/lib/typescript/module/src/components/inputs/input-date-time/styles.d.ts +2 -1
- package/lib/typescript/module/src/components/inputs/input-date-time/styles.d.ts.map +1 -1
- package/lib/typescript/module/src/components/modals/{modal-journey-rectification → modal-edite-journey-rectification}/index.d.ts +3 -0
- package/lib/typescript/module/src/components/modals/modal-edite-journey-rectification/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification-card/index.d.ts +11 -0
- package/lib/typescript/module/src/components/notification-card/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification-card/interface.d.ts +17 -0
- package/lib/typescript/module/src/components/notification-card/interface.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification-details-card/index.d.ts +11 -0
- package/lib/typescript/module/src/components/notification-details-card/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification-details-card/interface.d.ts +15 -0
- package/lib/typescript/module/src/components/notification-details-card/interface.d.ts.map +1 -0
- package/lib/typescript/module/src/components/selects/select-date-and-hours/index.d.ts +1 -1
- package/lib/typescript/module/src/components/travel-history/index.d.ts.map +1 -1
- package/lib/typescript/module/src/components/user-journey-work-card/index.d.ts +2 -0
- package/lib/typescript/module/src/components/user-journey-work-card/index.d.ts.map +1 -1
- package/lib/typescript/module/src/index.d.ts +3 -1
- package/lib/typescript/module/src/index.d.ts.map +1 -1
- package/lib/typescript/module/src/stories/card-work-session/card-work-session.stories.d.ts.map +1 -1
- package/lib/typescript/module/src/stories/modal-journey-rectification/modal-journey-rectification.stories.d.ts +1 -1
- package/lib/typescript/module/src/stories/modal-journey-rectification/modal-journey-rectification.stories.d.ts.map +1 -1
- package/lib/typescript/module/src/stories/notification-card/notification-card.stories.d.ts +14 -0
- package/lib/typescript/module/src/stories/notification-card/notification-card.stories.d.ts.map +1 -0
- package/lib/typescript/module/src/stories/notification-details-card/notification-details-card.stories.d.ts +16 -0
- package/lib/typescript/module/src/stories/notification-details-card/notification-details-card.stories.d.ts.map +1 -0
- package/lib/typescript/module/src/stories/user-journey-work-card/user-journey-work-card.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/constants/index.ts +1 -0
- package/src/common/icons-svg/download/index.tsx +52 -0
- package/src/common/icons-svg/index.tsx +4 -0
- package/src/components/activities-progress/index.tsx +172 -172
- package/src/components/card-report/interface.d.ts +1 -1
- package/src/components/card-work-session/index.tsx +190 -172
- package/src/components/card-work-session/interface.d.ts +151 -150
- package/src/components/inputs/input-date-time/index.tsx +13 -12
- package/src/components/inputs/input-date-time/styles.ts +64 -63
- package/src/components/modals/{modal-journey-rectification → modal-edite-journey-rectification}/index.tsx +78 -67
- package/src/components/modals/{modal-journey-rectification → modal-edite-journey-rectification}/interface.d.ts +10 -10
- package/src/components/monthly-summary-table/interface.d.ts +1 -1
- package/src/components/notification-card/index.tsx +123 -0
- package/src/components/notification-card/interface.ts +18 -0
- package/src/components/notification-details-card/index.tsx +180 -0
- package/src/components/notification-details-card/interface.ts +16 -0
- package/src/components/travel-history/interface.d.ts +1 -1
- package/src/components/user-journey-work-card/index.tsx +28 -1
- package/src/components/user-journey-work-card/interface.d.ts +149 -145
- package/src/index.tsx +3 -1
- package/src/stories/button/button.stories.tsx +1 -1
- package/src/stories/capture-photo/capture-photo.stories.tsx +1 -1
- package/src/stories/card-work-session/card-work-session.stories.tsx +106 -53
- package/src/stories/modal-journey-rectification/modal-journey-rectification.stories.tsx +60 -60
- package/src/stories/notification-card/notification-card.stories.tsx +93 -0
- package/src/stories/notification-details-card/notification-details-card.stories.tsx +109 -0
- package/src/stories/user-journey-work-card/user-journey-work-card.stories.tsx +71 -63
- package/src/styles/theme/theme.ts +1 -0
- package/lib/commonjs/components/modals/modal-journey-rectification/index.js.map +0 -1
- package/lib/commonjs/components/modals/modal-journey-rectification/interface.d.js.map +0 -1
- package/lib/module/components/modals/modal-journey-rectification/index.js.map +0 -1
- package/lib/module/components/modals/modal-journey-rectification/interface.d.js.map +0 -1
- package/lib/typescript/commonjs/src/components/modals/modal-journey-rectification/index.d.ts.map +0 -1
- package/lib/typescript/module/src/components/modals/modal-journey-rectification/index.d.ts.map +0 -1
- /package/lib/commonjs/components/modals/{modal-journey-rectification → modal-edite-journey-rectification}/interface.d.js +0 -0
- /package/lib/module/components/modals/{modal-journey-rectification → modal-edite-journey-rectification}/interface.d.js +0 -0
|
@@ -1,150 +1,151 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* IMPORTS
|
|
3
|
-
*/
|
|
4
|
-
import type React from "react";
|
|
5
|
-
import { ViewProps, type DimensionValue } from "react-native";
|
|
6
|
-
|
|
7
|
-
/**
|
|
8
|
-
* INTERFACE
|
|
9
|
-
*/
|
|
10
|
-
type ICardWorkSession = ViewProps & {
|
|
11
|
-
/**
|
|
12
|
-
* props que mostra o nome do usuário
|
|
13
|
-
*/
|
|
14
|
-
name: string;
|
|
15
|
-
|
|
16
|
-
/**
|
|
17
|
-
* props que mostra a data
|
|
18
|
-
*/
|
|
19
|
-
workDate: string;
|
|
20
|
-
|
|
21
|
-
/**
|
|
22
|
-
* props que mostra o
|
|
23
|
-
*/
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
/**
|
|
27
|
-
* props que mostra
|
|
28
|
-
*/
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
/**
|
|
32
|
-
* props que mostra
|
|
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
|
-
| "flex-
|
|
88
|
-
| "
|
|
89
|
-
| "
|
|
90
|
-
| "space-
|
|
91
|
-
| "space-
|
|
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
|
-
|
|
1
|
+
/*
|
|
2
|
+
* IMPORTS
|
|
3
|
+
*/
|
|
4
|
+
import type React from "react";
|
|
5
|
+
import { ViewProps, type DimensionValue } from "react-native";
|
|
6
|
+
|
|
7
|
+
/**
|
|
8
|
+
* INTERFACE
|
|
9
|
+
*/
|
|
10
|
+
type ICardWorkSession = ViewProps & {
|
|
11
|
+
/**
|
|
12
|
+
* props que mostra o nome do usuário
|
|
13
|
+
*/
|
|
14
|
+
name: string;
|
|
15
|
+
|
|
16
|
+
/**
|
|
17
|
+
* props que mostra a data
|
|
18
|
+
*/
|
|
19
|
+
workDate: string;
|
|
20
|
+
|
|
21
|
+
/**
|
|
22
|
+
* props que mostra o horário inicial
|
|
23
|
+
*/
|
|
24
|
+
initialTime?: string;
|
|
25
|
+
|
|
26
|
+
/**
|
|
27
|
+
* props que mostra a duração
|
|
28
|
+
*/
|
|
29
|
+
duration?: string;
|
|
30
|
+
|
|
31
|
+
/**
|
|
32
|
+
* props que mostra o avatar do usuário
|
|
33
|
+
*/
|
|
34
|
+
avatar: string;
|
|
35
|
+
|
|
36
|
+
handleNavigation: () => void;
|
|
37
|
+
handleNavigationNotification: () => void;
|
|
38
|
+
|
|
39
|
+
/**
|
|
40
|
+
* props que mostra a quantidade de notificações
|
|
41
|
+
*/
|
|
42
|
+
counterBadge: number;
|
|
43
|
+
|
|
44
|
+
children?: React.ReactNode;
|
|
45
|
+
|
|
46
|
+
/**
|
|
47
|
+
* TestID para testes automático e identificação
|
|
48
|
+
*/
|
|
49
|
+
testID?: string;
|
|
50
|
+
|
|
51
|
+
/**
|
|
52
|
+
* A propriedade CSS abreviada border define a borda de um elemento. Ele define os valores de largura da borda, estilo da borda e cor da borda.
|
|
53
|
+
*/
|
|
54
|
+
borderStyled?: {
|
|
55
|
+
borderStyle?: "solid" | "dotted" | "dashed";
|
|
56
|
+
|
|
57
|
+
borderRadius?: number | DimensionValue;
|
|
58
|
+
borderTopRightRadius?: number | DimensionValue;
|
|
59
|
+
borderTopLeftRadius?: number | DimensionValue;
|
|
60
|
+
borderBottomRightRadius?: number | DimensionValue;
|
|
61
|
+
borderBottomLeftRadius?: number | DimensionValue;
|
|
62
|
+
|
|
63
|
+
borderWidth?: number | DimensionValue;
|
|
64
|
+
borderLeftWidth?: number | DimensionValue;
|
|
65
|
+
borderRightWidth?: number | DimensionValue;
|
|
66
|
+
borderTopWidth?: number | DimensionValue;
|
|
67
|
+
borderBottomWidth?: number | DimensionValue;
|
|
68
|
+
|
|
69
|
+
borderColor?: string;
|
|
70
|
+
borderBottomColor?: string;
|
|
71
|
+
borderLeftColor?: string;
|
|
72
|
+
borderRightColor?: string;
|
|
73
|
+
borderTopColor?: string;
|
|
74
|
+
};
|
|
75
|
+
|
|
76
|
+
/**
|
|
77
|
+
* Propriedades que define a orientação do button que é usada para representar uma página. Na maioria das vezes, esse valores corresponde ao posicionamento alvo da página impressa, se aplicável.
|
|
78
|
+
*/
|
|
79
|
+
flexStyle?: {
|
|
80
|
+
alignItems?: "flex-start" | "flex-end" | "center" | "stretch" | "baseline";
|
|
81
|
+
alignSelf?: "auto" | "flex-start" | "flex-end" | "center" | "stretch" | "baseline";
|
|
82
|
+
flex?: string | number;
|
|
83
|
+
flexDirection?: "column" | "column-reverse" | "row" | "row-reverse";
|
|
84
|
+
flexWrap?: "nowrap" | "wrap" | "wrap-reverse";
|
|
85
|
+
textAlign?: "auto" | "center" | "left" | "right" | "justify";
|
|
86
|
+
justifyContent?:
|
|
87
|
+
| "flex-start"
|
|
88
|
+
| "flex-end"
|
|
89
|
+
| "center"
|
|
90
|
+
| "space-between"
|
|
91
|
+
| "space-around"
|
|
92
|
+
| "space-evenly";
|
|
93
|
+
};
|
|
94
|
+
|
|
95
|
+
/**
|
|
96
|
+
* A propriedade margin do CSS define a área de margem nos quatro lados do elemento. É uma abreviação que define todas as margens individuais de uma só vez: margin-top, margin-right (en-US), margin-bottom, e margin-left (en-US).
|
|
97
|
+
*/
|
|
98
|
+
marginStyle?: {
|
|
99
|
+
margin?: number | DimensionValue;
|
|
100
|
+
marginLeft?: number | DimensionValue;
|
|
101
|
+
marginRight?: number | DimensionValue;
|
|
102
|
+
marginTop?: number | DimensionValue;
|
|
103
|
+
marginBottom?: number | DimensionValue;
|
|
104
|
+
};
|
|
105
|
+
|
|
106
|
+
/**
|
|
107
|
+
* A propriedade padding define uma a distância entre o conteúdo de um elemento e suas bordas. É um atalho que evita definir uma distância para cada lado separadamente (padding-top, padding-right, padding-bottom, padding-left).
|
|
108
|
+
*/
|
|
109
|
+
paddingStyle?: {
|
|
110
|
+
padding?: number | DimensionValue;
|
|
111
|
+
paddingLeft?: number | DimensionValue;
|
|
112
|
+
paddingRight?: number | DimensionValue;
|
|
113
|
+
paddingTop?: number | DimensionValue;
|
|
114
|
+
paddingBottom?: number | DimensionValue;
|
|
115
|
+
};
|
|
116
|
+
|
|
117
|
+
/**
|
|
118
|
+
* A propriedade CSS height define a altura de um elemento. A altura de um elemento é a distância do topo da borda superior do elemento ao fundo da borda inferior.
|
|
119
|
+
*/
|
|
120
|
+
height?: number | DimensionValue;
|
|
121
|
+
|
|
122
|
+
/**
|
|
123
|
+
* A propriedade CSS width define a largura de um elemento. A largura de um elemento é a distância do topo da borda esquerda do elemento ao fundo da borda direita.
|
|
124
|
+
*/
|
|
125
|
+
width?: number | DimensionValue;
|
|
126
|
+
|
|
127
|
+
/**
|
|
128
|
+
* O fundo abreviado CSS Propriedade define todas as propriedades do estilo de fundo de uma só vez, como cor, imagem, origem e tamanho ou método de repetição. As propriedades dos componentes não definidas no fundo da declaração de valor da propriedade abreviada são definidas como seus valores padrão..
|
|
129
|
+
*/
|
|
130
|
+
backgroundColor?: string;
|
|
131
|
+
|
|
132
|
+
/**
|
|
133
|
+
* Propriedade texto que sera renderizado pro usuário final
|
|
134
|
+
*/
|
|
135
|
+
text?: string;
|
|
136
|
+
|
|
137
|
+
/**
|
|
138
|
+
* A propriedade CSS color define o valor da cor de primeiro plano do texto e das decorações de texto de um elemento e define o valor currentcolor. currentcolor pode ser usado como um valor indireto em outras propriedades e é o padrão para outras propriedades de cores, como border-color.
|
|
139
|
+
*/
|
|
140
|
+
color?: {
|
|
141
|
+
colorSvg?: string;
|
|
142
|
+
colorText?: string;
|
|
143
|
+
colorTextBold?: string;
|
|
144
|
+
colorTextData?: string;
|
|
145
|
+
};
|
|
146
|
+
};
|
|
147
|
+
|
|
148
|
+
/**
|
|
149
|
+
* EXPORTS
|
|
150
|
+
*/
|
|
151
|
+
export type { ICardWorkSession };
|
|
@@ -15,8 +15,9 @@ import type { IInputDateTimeProps } from "./interface";
|
|
|
15
15
|
// styles
|
|
16
16
|
import { styles } from "./styles";
|
|
17
17
|
import { theme } from "../../../styles/theme/theme";
|
|
18
|
+
import Typography from "../../typography";
|
|
18
19
|
|
|
19
|
-
/** formatadores
|
|
20
|
+
/** formatadores simples */
|
|
20
21
|
function fmtDate(d: Date) {
|
|
21
22
|
const dd = String(d.getDate()).padStart(2, "0");
|
|
22
23
|
const mm = String(d.getMonth() + 1).padStart(2, "0");
|
|
@@ -47,7 +48,6 @@ const InputDateTime = forwardRef<any, IInputDateTimeProps>((props, ref): React.R
|
|
|
47
48
|
testID,
|
|
48
49
|
} = props;
|
|
49
50
|
|
|
50
|
-
// estado interno quando o componente não é controlado
|
|
51
51
|
const [inner, setInner] = useState<Date>(value ?? new Date());
|
|
52
52
|
const [visible, setVisible] = useState(false);
|
|
53
53
|
|
|
@@ -83,14 +83,19 @@ const InputDateTime = forwardRef<any, IInputDateTimeProps>((props, ref): React.R
|
|
|
83
83
|
disabled={disabled}
|
|
84
84
|
>
|
|
85
85
|
<Icons
|
|
86
|
-
size={theme.fontSizes
|
|
86
|
+
size={theme.fontSizes.md}
|
|
87
87
|
color={theme.colors.blue[500]}
|
|
88
|
-
icon={mode === "date" ? "CALENDAR" : "
|
|
88
|
+
icon={mode === "date" ? "CALENDAR" : "TIMER"}
|
|
89
89
|
style={styles(styleProps).iconStandard}
|
|
90
90
|
/>
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
91
|
+
|
|
92
|
+
<Typography
|
|
93
|
+
text={`${human || placeholder}`}
|
|
94
|
+
color={theme.colors.blue[500]}
|
|
95
|
+
fontFamily={theme.fonts.inter_medium_500}
|
|
96
|
+
size={theme.fontSizes.md}
|
|
97
|
+
marginLeft={100}
|
|
98
|
+
/>
|
|
94
99
|
</TouchableOpacity>
|
|
95
100
|
|
|
96
101
|
<Modal
|
|
@@ -104,11 +109,7 @@ const InputDateTime = forwardRef<any, IInputDateTimeProps>((props, ref): React.R
|
|
|
104
109
|
<View style={styles(styleProps).modalContainer}>
|
|
105
110
|
<View style={{ width: "100%", alignItems: "flex-end" }}>
|
|
106
111
|
<TouchableOpacity testID="close-icon" onPress={() => setVisible(false)}>
|
|
107
|
-
<Icons
|
|
108
|
-
size={theme.fontSizes["md"]}
|
|
109
|
-
color={theme.colors.blue[500]}
|
|
110
|
-
icon={"CLOSED"}
|
|
111
|
-
/>
|
|
112
|
+
<Icons size={theme.fontSizes.md} color={theme.colors.blue[500]} icon="CLOSED" />
|
|
112
113
|
</TouchableOpacity>
|
|
113
114
|
</View>
|
|
114
115
|
|
|
@@ -1,63 +1,64 @@
|
|
|
1
|
-
import { StyleSheet } from "react-native";
|
|
2
|
-
import { theme } from "../../../styles/theme/theme";
|
|
3
|
-
import type { IInputDateTimeProps } from "./interface";
|
|
4
|
-
|
|
5
|
-
const styles = (props: IInputDateTimeProps) =>
|
|
6
|
-
StyleSheet.create({
|
|
7
|
-
container: {
|
|
8
|
-
width: "100%",
|
|
9
|
-
marginBottom: 16,
|
|
10
|
-
opacity: props.disabled ? 0.6 : 1,
|
|
11
|
-
},
|
|
12
|
-
label: {
|
|
13
|
-
fontSize: props.sizeTitleLabel ?? 16,
|
|
14
|
-
fontWeight: "bold",
|
|
15
|
-
color: props.colortitleLabel ?? theme.colors.black[100],
|
|
16
|
-
marginBottom: 5,
|
|
17
|
-
},
|
|
18
|
-
selectBox: {
|
|
19
|
-
flexDirection: "row",
|
|
20
|
-
alignItems: "center",
|
|
21
|
-
justifyContent: "
|
|
22
|
-
width: "100%",
|
|
23
|
-
height: 45,
|
|
24
|
-
borderWidth: 1,
|
|
25
|
-
borderColor: theme.colors.gray[700],
|
|
26
|
-
borderRadius: 10,
|
|
27
|
-
backgroundColor: props.backgroundColor ?? theme.colors.neutral[25],
|
|
28
|
-
paddingHorizontal: 10,
|
|
29
|
-
position: "relative",
|
|
30
|
-
},
|
|
31
|
-
selectedText: {
|
|
32
|
-
flex: 1,
|
|
33
|
-
fontSize: 14,
|
|
34
|
-
textAlign: "center",
|
|
35
|
-
color: theme.colors.gray[700],
|
|
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
|
-
|
|
1
|
+
import { StyleSheet } from "react-native";
|
|
2
|
+
import { theme } from "../../../styles/theme/theme";
|
|
3
|
+
import type { IInputDateTimeProps } from "./interface";
|
|
4
|
+
|
|
5
|
+
const styles = (props: IInputDateTimeProps) =>
|
|
6
|
+
StyleSheet.create({
|
|
7
|
+
container: {
|
|
8
|
+
width: "100%",
|
|
9
|
+
marginBottom: 16,
|
|
10
|
+
opacity: props.disabled ? 0.6 : 1,
|
|
11
|
+
},
|
|
12
|
+
label: {
|
|
13
|
+
fontSize: props.sizeTitleLabel ?? 16,
|
|
14
|
+
fontWeight: "bold",
|
|
15
|
+
color: props.colortitleLabel ?? theme.colors.black[100],
|
|
16
|
+
marginBottom: 5,
|
|
17
|
+
},
|
|
18
|
+
selectBox: {
|
|
19
|
+
flexDirection: "row",
|
|
20
|
+
alignItems: "center",
|
|
21
|
+
justifyContent: "flex-start", // não centraliza o container todo
|
|
22
|
+
width: "100%",
|
|
23
|
+
height: 45,
|
|
24
|
+
borderWidth: 1,
|
|
25
|
+
borderColor: theme.colors.gray[700],
|
|
26
|
+
borderRadius: 10,
|
|
27
|
+
backgroundColor: props.backgroundColor ?? theme.colors.neutral[25],
|
|
28
|
+
paddingHorizontal: 10,
|
|
29
|
+
position: "relative",
|
|
30
|
+
},
|
|
31
|
+
selectedText: {
|
|
32
|
+
flex: 1,
|
|
33
|
+
fontSize: 14,
|
|
34
|
+
textAlign: "center", // centraliza o texto no espaço disponível
|
|
35
|
+
color: theme.colors.gray[700],
|
|
36
|
+
marginLeft: 44,
|
|
37
|
+
},
|
|
38
|
+
placeholderText: {
|
|
39
|
+
flex: 1,
|
|
40
|
+
textAlign: "center",
|
|
41
|
+
fontSize: 14,
|
|
42
|
+
color: theme.colors.gray[700],
|
|
43
|
+
},
|
|
44
|
+
modalOverlay: {
|
|
45
|
+
flex: 1,
|
|
46
|
+
backgroundColor: "rgba(0,0,0,0.5)",
|
|
47
|
+
justifyContent: "center",
|
|
48
|
+
alignItems: "center",
|
|
49
|
+
padding: 24,
|
|
50
|
+
},
|
|
51
|
+
modalContainer: {
|
|
52
|
+
width: "100%",
|
|
53
|
+
backgroundColor: theme.colors.neutral[25],
|
|
54
|
+
borderRadius: 10,
|
|
55
|
+
padding: 15,
|
|
56
|
+
alignItems: "center",
|
|
57
|
+
},
|
|
58
|
+
iconStandard: {
|
|
59
|
+
position: "absolute",
|
|
60
|
+
left: 12, // ícone fixo no canto esquerdo
|
|
61
|
+
},
|
|
62
|
+
});
|
|
63
|
+
|
|
64
|
+
export { styles };
|