Synced files across admin systems
This commit is contained in:
@@ -57,7 +57,7 @@ const AppCreationModal = ({ open, onClose, theme, globalUrl, isCloud }) => {
|
||||
: hover
|
||||
? ""
|
||||
: "1px solid rgba(255,255,255,0.3)",
|
||||
borderImage: makeFancy ? "linear-gradient(45deg, red, orange, yellow, green, blue, indigo, violet) 1" : "none",
|
||||
borderImage: makeFancy ? "linear-gradient(to right, #ff8544 0%, #ec517c 50%, #9c5af2 100%) 1" : "none",
|
||||
transition: 'all 0.2s ease-in-out',
|
||||
}
|
||||
|
||||
@@ -340,7 +340,7 @@ const AppCreationModal = ({ open, onClose, theme, globalUrl, isCloud }) => {
|
||||
|
||||
|
||||
const circularLoader = validation ? <CircularProgress color="primary" /> : null
|
||||
const errorText = openApiError?.length > 0 ? <div style={{ marginTop: 10 }}>Error: {openApiError}</div> : null
|
||||
const errorText = openApiError?.length > 0 ? <div style={{ marginTop: 15, color: '#fd4c62' }}>Error: {openApiError}</div> : null
|
||||
|
||||
// Common dialog styles
|
||||
const dialogStyle = {
|
||||
@@ -400,7 +400,13 @@ const AppCreationModal = ({ open, onClose, theme, globalUrl, isCloud }) => {
|
||||
Create New App
|
||||
</Typography>
|
||||
<IconButton
|
||||
onClick={onClose}
|
||||
onClick={() => {
|
||||
setOpenApi("")
|
||||
setOpenApiError("")
|
||||
setAppValidation("")
|
||||
setValidation(false)
|
||||
onClose()
|
||||
}}
|
||||
sx={{
|
||||
color: 'rgba(255, 255, 255, 0.7)',
|
||||
'&:hover': { bgcolor: 'rgba(255, 255, 255, 0.1)' }
|
||||
@@ -477,7 +483,14 @@ const AppCreationModal = ({ open, onClose, theme, globalUrl, isCloud }) => {
|
||||
Create New App from Open API or Swagger
|
||||
</Typography>
|
||||
<IconButton
|
||||
onClick={() => setOpenApiModal(false)}
|
||||
onClick={() => {
|
||||
setOpenApiModal(false)
|
||||
setGenerateAppModal(false)
|
||||
setOpenApi("")
|
||||
setOpenApiError("")
|
||||
setAppValidation("")
|
||||
setValidation(false)
|
||||
}}
|
||||
sx={{
|
||||
color: 'rgba(255,255,255,0.7)',
|
||||
'&:hover': { bgcolor: 'rgba(255,255,255,0.1)' }
|
||||
@@ -487,14 +500,16 @@ const AppCreationModal = ({ open, onClose, theme, globalUrl, isCloud }) => {
|
||||
</IconButton>
|
||||
</DialogTitle>
|
||||
<DialogContent sx={{ px: 4, py: 3 }}>
|
||||
<div style={{ display: "flex", fontSize: '14px', gap: '5px', alignItems: 'center', marginBottom: '10px', fontFamily: theme?.typography?.fontFamily }}>
|
||||
<Typography sx={{ color: 'rgba(255,255,255,0.85)', fontSize: '14px' }}>
|
||||
<div style={{ display: "flex", fontSize: '14px', gap: '5px', alignItems: 'center', marginBottom: '10px', fontFamily: theme?.typography?.fontFamily, marginTop: '15px' }}>
|
||||
<Typography sx={{ color: 'rgba(255,255,255,0.85)', fontSize: '16px' }}>
|
||||
Paste in the URI for the OpenAPI or find out
|
||||
</Typography>
|
||||
<Link style={{
|
||||
color: '#ff8544',
|
||||
textDecoration: 'none',
|
||||
textDecoration: 'underline',
|
||||
fontSize: '16px',
|
||||
fontFamily: theme?.typography?.fontFamily
|
||||
}}>
|
||||
How to find URI for openAPI?
|
||||
</Link>
|
||||
@@ -506,12 +521,13 @@ const AppCreationModal = ({ open, onClose, theme, globalUrl, isCloud }) => {
|
||||
fullWidth
|
||||
variant="outlined"
|
||||
placeholder="Open API URI"
|
||||
style={{ fontFamily: theme?.typography?.fontFamily, fontSize: '16px' }}
|
||||
sx={{
|
||||
'& .MuiOutlinedInput-root': {
|
||||
height: '40px'
|
||||
height: '40px',
|
||||
},
|
||||
'& .MuiOutlinedInput-input::placeholder': {
|
||||
fontSize: '14px'
|
||||
fontSize: '16px'
|
||||
}
|
||||
}}
|
||||
onChange={(e) => setOpenApi(e.target.value)}
|
||||
@@ -526,7 +542,7 @@ const AppCreationModal = ({ open, onClose, theme, globalUrl, isCloud }) => {
|
||||
px: 3,
|
||||
textTransform: 'none',
|
||||
height: '40px',
|
||||
fontSize: '14px',
|
||||
fontSize: '16px',
|
||||
fontFamily: theme?.typography?.fontFamily,
|
||||
cursor: 'pointer'
|
||||
}}
|
||||
@@ -562,7 +578,7 @@ const AppCreationModal = ({ open, onClose, theme, globalUrl, isCloud }) => {
|
||||
sx={{
|
||||
color: '#FF8544',
|
||||
borderColor: '#FF8544',
|
||||
px: 3,
|
||||
px: 5,
|
||||
py: 1,
|
||||
'&:hover': {
|
||||
borderColor: '#FF8544',
|
||||
@@ -570,7 +586,8 @@ const AppCreationModal = ({ open, onClose, theme, globalUrl, isCloud }) => {
|
||||
},
|
||||
textTransform: 'none',
|
||||
fontSize: '14px',
|
||||
fontFamily: theme?.typography?.fontFamily
|
||||
fontFamily: theme?.typography?.fontFamily,
|
||||
height: '40px'
|
||||
}}
|
||||
>
|
||||
Upload
|
||||
@@ -605,7 +622,8 @@ const AppCreationModal = ({ open, onClose, theme, globalUrl, isCloud }) => {
|
||||
},
|
||||
textTransform: 'none',
|
||||
py: 1.5,
|
||||
fontSize: '14px',
|
||||
mb: 1.5,
|
||||
fontSize: '16px',
|
||||
fontWeight: 500,
|
||||
width: '100%',
|
||||
maxWidth: '300px',
|
||||
@@ -648,7 +666,7 @@ const AppCreationModal = ({ open, onClose, theme, globalUrl, isCloud }) => {
|
||||
<Typography variant="h6" sx={{
|
||||
color: '#F1F1F1',
|
||||
fontWeight: 500,
|
||||
fontFamily: theme?.typography?.fontFamily
|
||||
fontFamily: theme?.typography?.fontFamily,
|
||||
}}>
|
||||
Generate an app based on documentation (beta)
|
||||
</Typography>
|
||||
@@ -656,6 +674,10 @@ const AppCreationModal = ({ open, onClose, theme, globalUrl, isCloud }) => {
|
||||
onClick={() => {
|
||||
setGenerateAppModal(false)
|
||||
setOpenApiModal(false)
|
||||
setOpenApi("")
|
||||
setOpenApiError("")
|
||||
setAppValidation("")
|
||||
setValidation(false)
|
||||
}}
|
||||
sx={{
|
||||
color: 'rgba(255,255,255,0.7)',
|
||||
@@ -668,9 +690,9 @@ const AppCreationModal = ({ open, onClose, theme, globalUrl, isCloud }) => {
|
||||
<DialogContent sx={{ px: 4, py: 3, pt: 0 }}>
|
||||
<Typography sx={{
|
||||
color: 'rgba(255,255,255,0.85)',
|
||||
mb: 3,
|
||||
mb: 2,
|
||||
fontSize: '14px',
|
||||
mt:4,
|
||||
mt: 2,
|
||||
fontFamily: theme?.typography?.fontFamily
|
||||
}}>
|
||||
Paste in a URL, and we will make it into an app for you.
|
||||
@@ -689,18 +711,15 @@ const AppCreationModal = ({ open, onClose, theme, globalUrl, isCloud }) => {
|
||||
color: 'white',
|
||||
'& fieldset': {
|
||||
borderWidth: '1px',
|
||||
borderImage: 'linear-gradient(45deg, red, orange, yellow, green, blue, indigo, violet) 1',
|
||||
borderImageSlice: 1,
|
||||
borderImage: "linear-gradient(to right, #ff8544 0%, #ec517c 50%, #9c5af2 100%) 1",
|
||||
},
|
||||
'&:hover fieldset': {
|
||||
borderWidth: '1px',
|
||||
borderImage: 'linear-gradient(45deg, red, orange, yellow, green, blue, indigo, violet) 1',
|
||||
borderImageSlice: 1,
|
||||
borderImage: "linear-gradient(to right, #ff8544 0%, #ec517c 50%, #9c5af2 100%) 1",
|
||||
},
|
||||
'&.Mui-focused fieldset': {
|
||||
borderWidth: '2px',
|
||||
borderImage: 'linear-gradient(45deg, red, orange, yellow, green, blue, indigo, violet) 1',
|
||||
borderImageSlice: 1,
|
||||
borderImage: "linear-gradient(to right, #ff8544 0%, #ec517c 50%, #9c5af2 100%) 1",
|
||||
}
|
||||
},
|
||||
'& .MuiOutlinedInput-input::placeholder': {
|
||||
@@ -727,6 +746,7 @@ const AppCreationModal = ({ open, onClose, theme, globalUrl, isCloud }) => {
|
||||
</DialogContent>
|
||||
<DialogActions sx={{
|
||||
py: 2,
|
||||
pt: 1,
|
||||
px: 3,
|
||||
gap: 2,
|
||||
display: 'flex',
|
||||
@@ -736,7 +756,7 @@ const AppCreationModal = ({ open, onClose, theme, globalUrl, isCloud }) => {
|
||||
{circularLoader}
|
||||
{
|
||||
!validation &&
|
||||
<Typography sx={{ color: 'rgba(255,255,255,0.85)', fontSize: '14px', fontFamily: theme?.typography?.fontFamily, pt: 2 }}>
|
||||
<Typography sx={{ color: '#c5c5c5', fontSize: '14px', fontFamily: theme?.typography?.fontFamily, }}>
|
||||
This may take multiple minutes based on the size of the documentation.
|
||||
</Typography>
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user