🐛 fix(components): remove unnecessary empty line in ToggleComponent
🐛 fix(modals): fix typo in comment in CodeAreaModal 🐛 fix(pages): remove unnecessary empty line in MainPage 🐛 fix(utils): remove unnecessary semicolons in utils.ts
This commit is contained in:
parent
a21345ff44
commit
dff5c87c72
4 changed files with 6 additions and 7 deletions
|
|
@ -8,7 +8,6 @@ export default function ToggleComponent({
|
||||||
setEnabled,
|
setEnabled,
|
||||||
disabled,
|
disabled,
|
||||||
}: ToggleComponentType) {
|
}: ToggleComponentType) {
|
||||||
|
|
||||||
// set component state as disabled
|
// set component state as disabled
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
if (disabled) {
|
if (disabled) {
|
||||||
|
|
|
||||||
|
|
@ -39,7 +39,7 @@ export default function CodeAreaModal({
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Check for custom code errors
|
// Check for custom code errors
|
||||||
function handleClick() {
|
function handleClick() {
|
||||||
postValidateCode(code)
|
postValidateCode(code)
|
||||||
.then((apiReturn) => {
|
.then((apiReturn) => {
|
||||||
|
|
|
||||||
|
|
@ -8,7 +8,7 @@ import { TabsContext } from "../../contexts/tabsContext";
|
||||||
export default function HomePage() {
|
export default function HomePage() {
|
||||||
const { flows, setTabId, downloadFlows, uploadFlows, addFlow, removeFlow } =
|
const { flows, setTabId, downloadFlows, uploadFlows, addFlow, removeFlow } =
|
||||||
useContext(TabsContext);
|
useContext(TabsContext);
|
||||||
|
|
||||||
// Set a null id
|
// Set a null id
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
setTabId("");
|
setTabId("");
|
||||||
|
|
|
||||||
|
|
@ -259,7 +259,7 @@ export function getRandomKeyByssmm(): string {
|
||||||
export function varHighlightHTML({ name }: IVarHighlightType): string {
|
export function varHighlightHTML({ name }: IVarHighlightType): string {
|
||||||
const html = `<span class="font-semibold chat-message-highlight">{${name}}</span>`;
|
const html = `<span class="font-semibold chat-message-highlight">{${name}}</span>`;
|
||||||
return html;
|
return html;
|
||||||
};
|
}
|
||||||
|
|
||||||
export function buildTweakObject(tweak) {
|
export function buildTweakObject(tweak) {
|
||||||
tweak.forEach((el) => {
|
tweak.forEach((el) => {
|
||||||
|
|
@ -331,7 +331,7 @@ def run_flow(inputs: dict, flow_id: str, tweaks: Optional[dict] = None) -> dict:
|
||||||
# Setup any tweaks you want to apply to the flow
|
# Setup any tweaks you want to apply to the flow
|
||||||
inputs = ${inputs}
|
inputs = ${inputs}
|
||||||
print(run_flow(inputs, flow_id=FLOW_ID, tweaks=TWEAKS))`;
|
print(run_flow(inputs, flow_id=FLOW_ID, tweaks=TWEAKS))`;
|
||||||
};
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Function to get the curl code for the API
|
* Function to get the curl code for the API
|
||||||
|
|
@ -357,7 +357,7 @@ export function getCurlCode(
|
||||||
? buildTweakObject(tweak)
|
? buildTweakObject(tweak)
|
||||||
: JSON.stringify(tweaks, null, 2)
|
: JSON.stringify(tweaks, null, 2)
|
||||||
}}'`;
|
}}'`;
|
||||||
};
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Function to get the python code for the API
|
* Function to get the python code for the API
|
||||||
|
|
@ -382,4 +382,4 @@ flow = load_flow_from_json("${flowName}.json", tweaks=TWEAKS)
|
||||||
# Now you can use it like any chain
|
# Now you can use it like any chain
|
||||||
inputs = ${inputs}
|
inputs = ${inputs}
|
||||||
flow(inputs)`;
|
flow(inputs)`;
|
||||||
};
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue