react-native-exp-fig 0.1.19 → 0.1.21

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 (40) hide show
  1. package/lib/commonjs/common/icons-svg/steering-wheel/index.js +6 -6
  2. package/lib/commonjs/common/icons-svg/steering-wheel/index.js.map +1 -1
  3. package/lib/commonjs/common/icons-svg/truck/index.js +10 -8
  4. package/lib/commonjs/common/icons-svg/truck/index.js.map +1 -1
  5. package/lib/commonjs/components/activities-progress/index.js +1 -1
  6. package/lib/commonjs/components/activities-progress/index.js.map +1 -1
  7. package/lib/commonjs/components/loading-details/index.js +13 -11
  8. package/lib/commonjs/components/loading-details/index.js.map +1 -1
  9. package/lib/commonjs/components/loading-details/interface.d.js.map +1 -1
  10. package/lib/commonjs/stories/loading-details/loading-details.stories.js +14 -2
  11. package/lib/commonjs/stories/loading-details/loading-details.stories.js.map +1 -1
  12. package/lib/commonjs/styles/theme/theme.js +5 -4
  13. package/lib/commonjs/styles/theme/theme.js.map +1 -1
  14. package/lib/commonjs/utils/get-icon-by-property/index.js.map +1 -1
  15. package/lib/module/common/icons-svg/steering-wheel/index.js +6 -6
  16. package/lib/module/common/icons-svg/steering-wheel/index.js.map +1 -1
  17. package/lib/module/common/icons-svg/truck/index.js +10 -8
  18. package/lib/module/common/icons-svg/truck/index.js.map +1 -1
  19. package/lib/module/components/activities-progress/index.js +1 -1
  20. package/lib/module/components/activities-progress/index.js.map +1 -1
  21. package/lib/module/components/loading-details/index.js +13 -11
  22. package/lib/module/components/loading-details/index.js.map +1 -1
  23. package/lib/module/components/loading-details/interface.d.js.map +1 -1
  24. package/lib/module/stories/loading-details/loading-details.stories.js +13 -1
  25. package/lib/module/stories/loading-details/loading-details.stories.js.map +1 -1
  26. package/lib/module/styles/theme/theme.js +5 -4
  27. package/lib/module/styles/theme/theme.js.map +1 -1
  28. package/lib/module/utils/get-icon-by-property/index.js.map +1 -1
  29. package/lib/typescript/src/stories/loading-details/loading-details.stories.d.ts +1 -0
  30. package/lib/typescript/src/styles/global/theme-provider.d.ts +1 -0
  31. package/lib/typescript/src/styles/theme/theme.d.ts +1 -0
  32. package/package.json +1 -1
  33. package/src/common/icons-svg/steering-wheel/index.tsx +49 -49
  34. package/src/common/icons-svg/truck/index.tsx +41 -39
  35. package/src/components/activities-progress/index.tsx +1 -1
  36. package/src/components/loading-details/index.tsx +156 -154
  37. package/src/components/loading-details/interface.d.ts +31 -28
  38. package/src/stories/loading-details/loading-details.stories.tsx +60 -48
  39. package/src/styles/theme/theme.ts +172 -171
  40. package/src/utils/get-icon-by-property/index.tsx +1 -0
@@ -1,154 +1,156 @@
1
- /**
2
- * IMPORTS
3
- */
4
- import React from "react";
5
-
6
- // components
7
- import { Box } from "../box";
8
- import { Button } from "../button";
9
- import { Typography } from "../typography";
10
-
11
- // typings
12
- import { ILoadingDetails } from "./interface";
13
-
14
- // styles
15
- import { theme } from "../../styles/theme/theme";
16
-
17
- const LoadingDetails: React.FC<ILoadingDetails> = ({
18
- numero = "01020304050607",
19
- local = "Doca 1, Pátio 02 - Usimais (Ipatinga)",
20
- date = "24/03/2025",
21
- duracao = "00:00",
22
- isLoadingStart = false,
23
- handleClickGoback,
24
- handleClickStart,
25
- }: ILoadingDetails) => {
26
- return (
27
- <Box
28
- width="100%"
29
- borderStyled={{ borderRadius: 8 }}
30
- style={{
31
- shadowColor: theme.colors.black[10],
32
- shadowOpacity: 0.1,
33
- shadowOffset: { width: 0, height: 2 },
34
- shadowRadius: 4,
35
- elevation: 2,
36
- }}
37
- backgroundColor={theme.colors.blue[400]}
38
- >
39
- <Box
40
- width={"100%"}
41
- flexStyle={{
42
- flexDirection: "row",
43
- alignItems: "center",
44
- justifyContent: "space-between",
45
- }}
46
- paddingStyle={{ padding: theme.paddings.md }}
47
- >
48
- <Box
49
- width={"78%"}
50
- flexStyle={{
51
- flexDirection: "column",
52
- justifyContent: "flex-start",
53
- alignItems: "flex-start",
54
- }}
55
- >
56
- <Typography
57
- text={`Carregamento - #${numero}`}
58
- size={theme.fontSizes.sm}
59
- fontFamily={theme.fonts.inter_bold}
60
- fontWeight="700"
61
- color={theme.colors.neutral[25]}
62
- lineHeight={theme.fontSizes["lg"]}
63
- letterSpacing={"regular"}
64
- />
65
-
66
- <Typography
67
- text={local}
68
- color={theme.colors.neutral[25]}
69
- size={theme.fontSizes.xs}
70
- lineHeight={theme.fontSizes["2xl"]}
71
- letterSpacing={"regular"}
72
- numberOfLines={1}
73
- />
74
- <Typography
75
- text={`Data carregamento: ${date}`}
76
- color={theme.colors.neutral[25]}
77
- size={theme.fontSizes.xs}
78
- lineHeight={theme.fontSizes["2xl"]}
79
- letterSpacing={"regular"}
80
- numberOfLines={1}
81
- />
82
- </Box>
83
-
84
- <Typography
85
- text={duracao}
86
- color={theme.colors.neutral[25]}
87
- size={24}
88
- align="left"
89
- fontFamily="inter_bold"
90
- fontWeight="700"
91
- lineHeight={theme.fontSizes["3xl"]}
92
- letterSpacing={"regular"}
93
- />
94
- </Box>
95
-
96
- <Box
97
- height={1}
98
- backgroundColor={theme.colors.gray[950]}
99
- marginStyle={{ marginTop: theme.margins.xs, marginBottom: theme.margins.xs }}
100
- />
101
-
102
- <Box style={{ flexDirection: "row", gap: 12, marginBottom: 8, padding: theme.paddings.md }}>
103
- <Button
104
- title="INICIAR"
105
- onPress={handleClickStart}
106
- height={40}
107
- isLoading={isLoadingStart}
108
- disabled={isLoadingStart}
109
- backgroundColor={theme.colors.green[250]}
110
- flexStyle={{ flex: 1, alignItems: "center", justifyContent: "center" }}
111
- buttonTextStyle={{
112
- color: theme.colors.neutral[25],
113
- fontFamily: theme.fonts.inter_semi_bold_600,
114
- fontSize: theme.fontSizes.md,
115
- fontWeight: "600",
116
- textAlign: "center",
117
- }}
118
- borderStyled={{
119
- borderWidth: 1,
120
- borderColor: theme.colors.green[250],
121
- borderRadius: 24,
122
- }}
123
- />
124
-
125
- <Button
126
- title="VOLTAR"
127
- onPress={handleClickGoback}
128
- height={40}
129
- isLoading={false}
130
- disabled={isLoadingStart}
131
- backgroundColor={theme.colors.yellow[75]}
132
- flexStyle={{ flex: 1, alignItems: "center", justifyContent: "center" }}
133
- buttonTextStyle={{
134
- color: theme.colors.neutral[25],
135
- fontFamily: theme.fonts.inter_semi_bold_600,
136
- fontSize: theme.fontSizes.md,
137
- fontWeight: "600",
138
- textAlign: "center",
139
- }}
140
- borderStyled={{
141
- borderWidth: 1,
142
- borderColor: theme.colors.yellow[75],
143
- borderRadius: 24,
144
- }}
145
- />
146
- </Box>
147
- </Box>
148
- );
149
- };
150
-
151
- /**
152
- * EXPORTS
153
- */
154
- export { LoadingDetails };
1
+ /**
2
+ * IMPORTS
3
+ */
4
+ import React from "react";
5
+
6
+ // components
7
+ import { Box } from "../box";
8
+ import { Button } from "../button";
9
+ import { Typography } from "../typography";
10
+
11
+ // typings
12
+ import { ILoadingDetails } from "./interface";
13
+
14
+ // styles
15
+ import { theme } from "../../styles/theme/theme";
16
+
17
+ const LoadingDetails: React.FC<ILoadingDetails> = ({
18
+ numero = "01020304050607",
19
+ local = "Doca 1, Pátio 02 - Usimais (Ipatinga)",
20
+ date = "24/03/2025",
21
+ duracao = "00:00",
22
+ isLoadingStart = false,
23
+ disabled,
24
+ handleClickGoback,
25
+ handleClickStart,
26
+ }: ILoadingDetails) => {
27
+ return (
28
+ <Box
29
+ width="100%"
30
+ borderStyled={{ borderRadius: 8 }}
31
+ style={{
32
+ shadowColor: theme.colors.black[10],
33
+ shadowOpacity: 0.1,
34
+ shadowOffset: { width: 0, height: 2 },
35
+ shadowRadius: 4,
36
+ elevation: 2,
37
+ }}
38
+ backgroundColor={theme.colors.blue[400]}
39
+ >
40
+ <Box
41
+ width={"100%"}
42
+ flexStyle={{
43
+ flexDirection: "row",
44
+ alignItems: "center",
45
+ justifyContent: "space-between",
46
+ }}
47
+ paddingStyle={{ padding: theme.paddings.md }}
48
+ >
49
+ <Box
50
+ width={"78%"}
51
+ flexStyle={{
52
+ flexDirection: "column",
53
+ justifyContent: "flex-start",
54
+ alignItems: "flex-start",
55
+ }}
56
+ >
57
+ <Typography
58
+ text={`Carregamento - #${numero}`}
59
+ size={theme.fontSizes.sm}
60
+ fontFamily={theme.fonts.inter_bold}
61
+ fontWeight="700"
62
+ color={theme.colors.neutral[25]}
63
+ lineHeight={theme.fontSizes["lg"]}
64
+ letterSpacing={"regular"}
65
+ />
66
+
67
+ <Typography
68
+ text={local}
69
+ color={theme.colors.neutral[25]}
70
+ size={theme.fontSizes.xs}
71
+ lineHeight={theme.fontSizes["2xl"]}
72
+ letterSpacing={"regular"}
73
+ numberOfLines={1}
74
+ />
75
+ <Typography
76
+ text={`Data carregamento: ${date}`}
77
+ color={theme.colors.neutral[25]}
78
+ size={theme.fontSizes.xs}
79
+ lineHeight={theme.fontSizes["2xl"]}
80
+ letterSpacing={"regular"}
81
+ numberOfLines={1}
82
+ />
83
+ </Box>
84
+
85
+ <Typography
86
+ text={duracao}
87
+ color={theme.colors.neutral[25]}
88
+ size={24}
89
+ align="left"
90
+ fontFamily="inter_bold"
91
+ fontWeight="700"
92
+ lineHeight={theme.fontSizes["3xl"]}
93
+ letterSpacing={"regular"}
94
+ />
95
+ </Box>
96
+
97
+ <Box
98
+ height={1}
99
+ backgroundColor={theme.colors.gray[950]}
100
+ marginStyle={{ marginTop: theme.margins.xs, marginBottom: theme.margins.xs }}
101
+ />
102
+
103
+ <Box style={{ flexDirection: "row", gap: 12, marginBottom: 8, padding: theme.paddings.md }}>
104
+ <Button
105
+ testID="iniciar-button"
106
+ title="INICIAR"
107
+ onPress={handleClickStart}
108
+ height={40}
109
+ isLoading={isLoadingStart}
110
+ disabled={disabled}
111
+ backgroundColor={disabled ? theme.colors.green[100] : theme.colors.green[250]}
112
+ flexStyle={{ flex: 1, alignItems: "center", justifyContent: "center" }}
113
+ buttonTextStyle={{
114
+ color: theme.colors.neutral[25],
115
+ fontFamily: theme.fonts.inter_semi_bold_600,
116
+ fontSize: theme.fontSizes.md,
117
+ fontWeight: "600",
118
+ textAlign: "center",
119
+ }}
120
+ borderStyled={{
121
+ borderWidth: theme.borderWidths.thin,
122
+ borderColor: disabled ? theme.colors.green[100] : theme.colors.green[250],
123
+ borderRadius: theme.fontSizes["2xl"],
124
+ }}
125
+ />
126
+
127
+ <Button
128
+ title="VOLTAR"
129
+ onPress={handleClickGoback}
130
+ height={40}
131
+ isLoading={false}
132
+ disabled={isLoadingStart}
133
+ backgroundColor={theme.colors.yellow[75]}
134
+ flexStyle={{ flex: 1, alignItems: "center", justifyContent: "center" }}
135
+ buttonTextStyle={{
136
+ color: theme.colors.neutral[25],
137
+ fontFamily: theme.fonts.inter_semi_bold_600,
138
+ fontSize: theme.fontSizes.md,
139
+ fontWeight: "600",
140
+ textAlign: "center",
141
+ }}
142
+ borderStyled={{
143
+ borderWidth: theme.borderWidths.thin,
144
+ borderColor: theme.colors.yellow[75],
145
+ borderRadius: theme.fontSizes["2xl"],
146
+ }}
147
+ />
148
+ </Box>
149
+ </Box>
150
+ );
151
+ };
152
+
153
+ /**
154
+ * EXPORTS
155
+ */
156
+ export { LoadingDetails };
@@ -1,28 +1,31 @@
1
- /**
2
- * IMPORTS
3
- */
4
- type ILoadingDetails = {
5
- /**número do carregamento */
6
- numero: string;
7
- /**local onde vai ser o carregamento */
8
- local: string;
9
- /**data de quando o carregamento vai ser realizado */
10
- date: string;
11
- /**duração para o carregamento */
12
- duracao: string;
13
-
14
- /**carregamento do inicio do start */
15
- isLoadingStart?: boolean;
16
-
17
- /**Actions */
18
-
19
- /**função usada para voltar usuário */
20
- handleClickGoback: () => void;
21
- /**função que inicia o carregamento */
22
- handleClickStart: () => void;
23
- };
24
-
25
- /**
26
- * EXPORTS
27
- */
28
- export { ILoadingDetails };
1
+ /**
2
+ * IMPORTS
3
+ */
4
+ type ILoadingDetails = {
5
+ /**número do carregamento */
6
+ numero: string;
7
+ /**local onde vai ser o carregamento */
8
+ local: string;
9
+ /**data de quando o carregamento vai ser realizado */
10
+ date: string;
11
+ /**duração para o carregamento */
12
+ duracao: string;
13
+
14
+ /**Actions */
15
+ /**carregamento do inicio do start */
16
+ isLoadingStart?: boolean;
17
+
18
+ /**função usada para voltar usuário */
19
+ handleClickGoback: () => void;
20
+
21
+ /**função que inicia o carregamento */
22
+ handleClickStart: () => void;
23
+
24
+ /**para desabilitar o button de iniciar o carregamento*/
25
+ disabled?: boolean;
26
+ };
27
+
28
+ /**
29
+ * EXPORTS
30
+ */
31
+ export { ILoadingDetails };
@@ -1,48 +1,60 @@
1
- import React from "react";
2
- import type { StoryObj, Meta } from "@storybook/react";
3
-
4
- import { LoadingDetails } from "../../components/loading-details";
5
-
6
- const meta: Meta<typeof LoadingDetails> = {
7
- title: "componente/LoadingDetails",
8
- component: LoadingDetails as React.FC,
9
- args: {
10
- numero: "01",
11
- local: "Doca 1, Pátio 02 - Ultrimais (Ipatinga)",
12
- date: "24/03/2025",
13
- duracao: "00:00",
14
- },
15
- parameters: {
16
- notes: `
17
- # LoadingDetails
18
-
19
- Este é um componente de LoadingDetails.
20
- Você usa assim:
21
- \`\`\`tsx
22
- <LoadingDetails
23
- numero="01"
24
- local="Doca 1, Pátio 02 - Usiminas (Ipatinga)"
25
- date="24/03/2025"
26
- duracao="00:00"
27
- handleClickGoback={() => {}}
28
- isLoadingStart={false}
29
- handleClickStart={() => {}}
30
- />
31
- \`\`\`
32
- `,
33
- },
34
- };
35
-
36
- export default meta;
37
-
38
- type Story = StoryObj<typeof meta>;
39
-
40
- export const Profile: Story = {
41
- name: "loading-details",
42
- args: {
43
- numero: "01",
44
- local: "Doca 1, Pátio 02 - Ultrimais (Ipatinga)",
45
- date: "24/03/2025",
46
- duracao: "00:00",
47
- },
48
- };
1
+ import React from "react";
2
+ import type { StoryObj, Meta } from "@storybook/react";
3
+
4
+ import { LoadingDetails } from "../../components/loading-details";
5
+
6
+ const meta: Meta<typeof LoadingDetails> = {
7
+ title: "componente/LoadingDetails",
8
+ component: LoadingDetails as React.FC,
9
+ args: {
10
+ numero: "01",
11
+ local: "Doca 1, Pátio 02 - Ultrimais (Ipatinga)",
12
+ date: "24/03/2025",
13
+ duracao: "00:00",
14
+ disabled: false,
15
+ },
16
+ parameters: {
17
+ notes: `
18
+ # LoadingDetails
19
+
20
+ Este é um componente de LoadingDetails.
21
+ Você usa assim:
22
+ \`\`\`tsx
23
+ <LoadingDetails
24
+ numero="01"
25
+ local="Doca 1, Pátio 02 - Usiminas (Ipatinga)"
26
+ date="24/03/2025"
27
+ duracao="00:00"
28
+ handleClickGoback={() => {}}
29
+ isLoadingStart={false}
30
+ handleClickStart={() => {}}
31
+ disabled={true}
32
+ />
33
+ \`\`\`
34
+ `,
35
+ },
36
+ };
37
+
38
+ export default meta;
39
+
40
+ type Story = StoryObj<typeof meta>;
41
+
42
+ export const Profile: Story = {
43
+ name: "loading-details",
44
+ args: {
45
+ numero: "01",
46
+ local: "Doca 1, Pátio 02 - Ultrimais (Ipatinga)",
47
+ date: "24/03/2025",
48
+ duracao: "00:00",
49
+ },
50
+ };
51
+ export const ProfileDisabled: Story = {
52
+ name: "loading-details-disabled",
53
+ args: {
54
+ numero: "01",
55
+ local: "Doca 1, Pátio 02 - Ultrimais (Ipatinga)",
56
+ date: "24/03/2025",
57
+ duracao: "00:00",
58
+ disabled: true,
59
+ },
60
+ };