Fixed visuals and targeting during onboarding
This commit is contained in:
File diff suppressed because one or more lines are too long
@@ -167,7 +167,7 @@ const ParsedAction = (props) => {
|
||||
const classes = useStyles();
|
||||
|
||||
const [expansionModalOpen, setExpansionModalOpen] = React.useState(false);
|
||||
const [hideBody, setHideBody] = React.useState(false);
|
||||
const [hideBody, setHideBody] = React.useState(true);
|
||||
const [activateHidingBody, setActivateHidingBody] = React.useState(false);
|
||||
const [codedata, setcodedata] = React.useState("");
|
||||
const [fieldCount, setFieldCount] = React.useState(0);
|
||||
@@ -980,11 +980,13 @@ const ParsedAction = (props) => {
|
||||
|
||||
//console.log("AUTH: ", authenticationType)
|
||||
if (authenticationType !== undefined && authenticationType !== null && authenticationType.type === "oauth2") {
|
||||
/*
|
||||
return (
|
||||
<Typography variant="body1" color="textSecondary" style={{marginTop: 15}}>
|
||||
You must authenticate before using oauth2 apps.
|
||||
</Typography>
|
||||
)
|
||||
*/
|
||||
}
|
||||
|
||||
// FIXME: Issue #40 - selectedActionParameters not reset
|
||||
@@ -1074,7 +1076,7 @@ const ParsedAction = (props) => {
|
||||
multiline = true;
|
||||
}
|
||||
|
||||
var placeholder = "Static value";
|
||||
var placeholder = "Value";
|
||||
if (
|
||||
data.example !== undefined &&
|
||||
data.example !== null &&
|
||||
@@ -1163,6 +1165,9 @@ const ParsedAction = (props) => {
|
||||
|
||||
for (var key in selectedActionParameters) {
|
||||
var currentItem = selectedActionParameters[key];
|
||||
if (currentItem.name === "ssl_verify") {
|
||||
|
||||
}
|
||||
|
||||
if (currentItem.description === openApiFieldDesc) {
|
||||
currentItem.field_active = !hideBody;
|
||||
@@ -1191,7 +1196,7 @@ const ParsedAction = (props) => {
|
||||
setActivateHidingBody(true);
|
||||
}
|
||||
} else {
|
||||
console.log("SHOW BUTTON");
|
||||
//console.log("SHOW BUTTON");
|
||||
|
||||
rows = "1";
|
||||
disabled = true;
|
||||
|
||||
@@ -23,18 +23,18 @@ const CodeEditor = (props) => {
|
||||
const [localcodedata, setlocalcodedata] = React.useState(codedata === undefined || codedata === null || codedata.length === 0 ? "" : codedata);
|
||||
// const {codelang, setcodelang} = props
|
||||
const theme = useTheme();
|
||||
|
||||
const [validation, setvalidation] = React.useState(" ");
|
||||
const [expOutput, setexpOutput] = React.useState(" ");
|
||||
|
||||
function IsJsonString(str) {
|
||||
try {
|
||||
var o = JSON.parse(str);
|
||||
if (o && typeof o === "object") {
|
||||
setvalidation("Validation Status: Correct!")
|
||||
if (o && typeof o === "object") {
|
||||
setvalidation("Correct!")
|
||||
}
|
||||
} catch (e) {setvalidation("Validation Status: Incorrect!");}
|
||||
} catch (e) {setvalidation("Incorrect!");}
|
||||
}
|
||||
|
||||
const [expOutput, setexpOutput] = React.useState(" ");
|
||||
function expectedOutput(input) {
|
||||
|
||||
const found = input.match(/[$]{1}([a-zA-Z0-9_-]+\.?){1}([a-zA-Z0-9#_-]+\.?){0,}/g)
|
||||
@@ -96,6 +96,7 @@ const CodeEditor = (props) => {
|
||||
<DialogTitle
|
||||
style={{
|
||||
paddingBottom:20,
|
||||
paddingLeft: 10,
|
||||
}}
|
||||
>
|
||||
Code Editor
|
||||
@@ -129,6 +130,7 @@ const CodeEditor = (props) => {
|
||||
<DialogTitle
|
||||
style={{
|
||||
paddingTop: 30,
|
||||
paddingLeft: 10,
|
||||
}}
|
||||
>
|
||||
<span
|
||||
@@ -150,6 +152,7 @@ const CodeEditor = (props) => {
|
||||
marginTop: -2,
|
||||
border: `2px solid ${theme.palette.inputColor}`,
|
||||
borderRadius: theme.palette.borderRadius,
|
||||
maxHeight: 400,
|
||||
}}
|
||||
>
|
||||
{expOutput}
|
||||
@@ -159,10 +162,11 @@ const CodeEditor = (props) => {
|
||||
color: "white",
|
||||
fontFamily: "monospace",
|
||||
padding: 20,
|
||||
paddingLeft: 10,
|
||||
marginTop: -15,
|
||||
}}
|
||||
>
|
||||
{validation}
|
||||
JSON Validation: {validation}
|
||||
</p>
|
||||
</div>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user