@canmingir/link 1.2.30 → 1.2.32
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/package.json +1 -1
- package/src/layouts/auth/modern.jsx +49 -84
- package/src/lib/APIDialogAction/APIDialogAction.jsx +4 -5
- package/src/lib/APIParams/APIParams.jsx +2 -2
- package/src/lib/APIPath/APIPath.jsx +2 -2
- package/src/lib/APITree/APITree.jsx +134 -372
- package/src/lib/APITree/Arrow.jsx +10 -9
- package/src/lib/Flow/core/Flow.jsx +26 -13
- package/src/lib/NucDialog/NucDialog.jsx +4 -4
- package/src/lib/ParamTable/ParamTable.jsx +2 -2
- package/src/lib/ResourceMenu/AlertMassage.jsx +2 -2
- package/src/lib/ResourceMenu/DeleteResourceDialog.jsx +9 -6
- package/src/lib/ResourceMenu/ResourceMenu.jsx +5 -8
- package/src/lib/Schema/Schema.jsx +5 -6
- package/src/lib/SchemaEditor/SchemaEditor.jsx +12 -10
- package/src/lib/index.js +1 -0
- package/src/pages/LoginPage.jsx +72 -2
- package/src/widgets/Login/CognitoLogin.jsx +48 -82
- package/src/widgets/Login/DemoLogin.jsx +30 -83
- package/src/widgets/Login/styles.jsx +35 -0
package/package.json
CHANGED
|
@@ -5,107 +5,72 @@ import { Outlet } from "react-router";
|
|
|
5
5
|
import React from "react";
|
|
6
6
|
import Stack from "@mui/material/Stack";
|
|
7
7
|
import { alpha } from "@mui/material/styles";
|
|
8
|
-
import { useResponsive } from "../../hooks/use-responsive";
|
|
9
8
|
|
|
10
9
|
// ----------------------------------------------------------------------
|
|
11
10
|
|
|
12
|
-
export default function AuthModernLayout(
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
const renderContent = (
|
|
11
|
+
export default function AuthModernLayout() {
|
|
12
|
+
return (
|
|
16
13
|
<Stack
|
|
14
|
+
component="main"
|
|
17
15
|
sx={{
|
|
18
|
-
|
|
19
|
-
mx: "auto",
|
|
20
|
-
maxWidth: 600,
|
|
21
|
-
px: { xs: 3, md: 10 },
|
|
22
|
-
py: { xs: 4, md: 0 },
|
|
23
|
-
height: "100vh",
|
|
24
|
-
justifyContent: "center",
|
|
16
|
+
minHeight: "100vh",
|
|
25
17
|
alignItems: "center",
|
|
18
|
+
justifyContent: "center",
|
|
19
|
+
position: "relative",
|
|
26
20
|
}}
|
|
27
21
|
>
|
|
28
|
-
<
|
|
29
|
-
maxSize={140}
|
|
22
|
+
<Box
|
|
30
23
|
sx={{
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
24
|
+
position: "fixed",
|
|
25
|
+
inset: 0,
|
|
26
|
+
backgroundImage: (theme) => `
|
|
27
|
+
radial-gradient(
|
|
28
|
+
${alpha(theme.palette.divider, 0.08)} 1px,
|
|
29
|
+
transparent 1px
|
|
30
|
+
)
|
|
31
|
+
`,
|
|
32
|
+
backgroundSize: "16px 16px",
|
|
33
|
+
pointerEvents: "none",
|
|
34
|
+
zIndex: 0,
|
|
34
35
|
}}
|
|
35
36
|
/>
|
|
36
|
-
|
|
37
|
-
<Card
|
|
37
|
+
<Stack
|
|
38
38
|
sx={{
|
|
39
39
|
width: 1,
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
40
|
+
mx: "auto",
|
|
41
|
+
maxWidth: 480,
|
|
42
|
+
px: { xs: 3, md: 6 },
|
|
43
|
+
py: { xs: 4, md: 0 },
|
|
44
|
+
position: "relative",
|
|
45
|
+
zIndex: 1,
|
|
46
|
+
}}
|
|
47
|
+
>
|
|
48
|
+
<Logo
|
|
49
|
+
maxSize={140}
|
|
50
|
+
sx={{
|
|
51
|
+
mb: 2,
|
|
52
|
+
width: 72,
|
|
53
|
+
height: 72,
|
|
54
|
+
alignSelf: "center",
|
|
55
|
+
}}
|
|
56
|
+
/>
|
|
57
|
+
|
|
58
|
+
<Card
|
|
59
|
+
sx={{
|
|
60
|
+
width: 1,
|
|
61
|
+
py: { xs: 5, md: 5 },
|
|
62
|
+
px: { xs: 4, md: 5 },
|
|
63
|
+
boxShadow: (theme) =>
|
|
44
64
|
`0 0 2px ${alpha(
|
|
45
65
|
theme.palette.grey[500],
|
|
46
66
|
0.16
|
|
47
67
|
)}, 0 12px 24px -4px ${alpha(theme.palette.grey[500], 0.12)}`,
|
|
48
|
-
|
|
49
|
-
}
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
>
|
|
55
|
-
<Outlet />
|
|
56
|
-
</Card>
|
|
57
|
-
</Stack>
|
|
58
|
-
);
|
|
59
|
-
|
|
60
|
-
const renderSection = (
|
|
61
|
-
<Stack
|
|
62
|
-
sx={{
|
|
63
|
-
flexGrow: 1,
|
|
64
|
-
position: "relative"
|
|
65
|
-
}}>
|
|
66
|
-
<Box
|
|
67
|
-
component="img"
|
|
68
|
-
alt="auth"
|
|
69
|
-
src={image || "/assets/background/overlay_3.jpg"}
|
|
70
|
-
sx={{
|
|
71
|
-
top: "50%",
|
|
72
|
-
left: "50%",
|
|
73
|
-
transform: "translate(-50%, -50%)",
|
|
74
|
-
objectFit: "cover",
|
|
75
|
-
position: "absolute",
|
|
76
|
-
width: "calc(60% - 32px)",
|
|
77
|
-
height: "calc(60% - 32px)",
|
|
78
|
-
borderRadius: 3,
|
|
79
|
-
}}
|
|
80
|
-
/>
|
|
81
|
-
</Stack>
|
|
82
|
-
);
|
|
83
|
-
|
|
84
|
-
return (
|
|
85
|
-
<Stack
|
|
86
|
-
component="main"
|
|
87
|
-
direction="row"
|
|
88
|
-
sx={{
|
|
89
|
-
minHeight: "100vh",
|
|
90
|
-
position: "relative",
|
|
91
|
-
"&:before": {
|
|
92
|
-
width: 1,
|
|
93
|
-
height: 1,
|
|
94
|
-
zIndex: -1,
|
|
95
|
-
content: "''",
|
|
96
|
-
position: "absolute",
|
|
97
|
-
backgroundSize: "cover",
|
|
98
|
-
opacity: { xs: 0.24, md: 0 },
|
|
99
|
-
backgroundRepeat: "no-repeat",
|
|
100
|
-
backgroundPosition: "center center",
|
|
101
|
-
backgroundImage:
|
|
102
|
-
"url(https://minimals.cc/assets/background/overlay_4.jpg)",
|
|
103
|
-
},
|
|
104
|
-
}}
|
|
105
|
-
>
|
|
106
|
-
{renderContent}
|
|
107
|
-
|
|
108
|
-
{mdUp && renderSection}
|
|
68
|
+
borderRadius: 2,
|
|
69
|
+
}}
|
|
70
|
+
>
|
|
71
|
+
<Outlet />
|
|
72
|
+
</Card>
|
|
73
|
+
</Stack>
|
|
109
74
|
</Stack>
|
|
110
75
|
);
|
|
111
76
|
}
|
|
@@ -1,8 +1,7 @@
|
|
|
1
|
-
import DeleteIcon from "@mui/icons-material/Delete";
|
|
2
1
|
import DialogTooltip from "../DialogTootip/DialogTooltip";
|
|
3
|
-
import SaveIcon from "@mui/icons-material/Save";
|
|
4
2
|
|
|
5
3
|
import { Box, Button, ToggleButton, ToggleButtonGroup } from "@mui/material";
|
|
4
|
+
import { Delete, Save } from "@mui/icons-material";
|
|
6
5
|
import { useEffect, useState } from "react";
|
|
7
6
|
|
|
8
7
|
function APIDialogAction({
|
|
@@ -72,7 +71,7 @@ function APIDialogAction({
|
|
|
72
71
|
variant="contained"
|
|
73
72
|
color="error"
|
|
74
73
|
onClick={deleteMethod}
|
|
75
|
-
startIcon={<
|
|
74
|
+
startIcon={<Delete />}
|
|
76
75
|
data-cy="delete-api-button-yes"
|
|
77
76
|
>
|
|
78
77
|
Delete
|
|
@@ -85,7 +84,7 @@ function APIDialogAction({
|
|
|
85
84
|
color="error"
|
|
86
85
|
onClick={handleTooltipOpen}
|
|
87
86
|
disabled={deleteDisable}
|
|
88
|
-
startIcon={<
|
|
87
|
+
startIcon={<Delete />}
|
|
89
88
|
data-cy="delete-api-button"
|
|
90
89
|
>
|
|
91
90
|
Delete
|
|
@@ -96,7 +95,7 @@ function APIDialogAction({
|
|
|
96
95
|
color="primary"
|
|
97
96
|
onClick={saveApiDialog}
|
|
98
97
|
disabled={saveDisable}
|
|
99
|
-
startIcon={<
|
|
98
|
+
startIcon={<Save />}
|
|
100
99
|
data-cy="save-api-button"
|
|
101
100
|
>
|
|
102
101
|
Save
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { Add } from "@mui/icons-material";
|
|
2
2
|
import ParamTable from "../ParamTable";
|
|
3
3
|
|
|
4
4
|
import { Box, Fab } from "@mui/material";
|
|
@@ -47,7 +47,7 @@ const APIParams = ({ types, paramsRef, addParams }) => {
|
|
|
47
47
|
onClick={handleAddParams}
|
|
48
48
|
data-cy="add-param-button"
|
|
49
49
|
>
|
|
50
|
-
<
|
|
50
|
+
<Add />
|
|
51
51
|
</Fab>
|
|
52
52
|
</Box>
|
|
53
53
|
</Box>
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { Language } from "@mui/icons-material";
|
|
2
2
|
import styles from "./styles";
|
|
3
3
|
|
|
4
4
|
import {
|
|
@@ -72,7 +72,7 @@ const APIPath = ({
|
|
|
72
72
|
</Grid>
|
|
73
73
|
</Grid>
|
|
74
74
|
<Button onClick={onTypesButtonClick} data-cy="types-button">
|
|
75
|
-
<
|
|
75
|
+
<Language sx={styles.icon} />
|
|
76
76
|
Types
|
|
77
77
|
</Button>
|
|
78
78
|
</Grid>
|