From 8d1a0bac9d6fbe708b92b5f562340011879c3ac7 Mon Sep 17 00:00:00 2001 From: Kalki Date: Tue, 18 Jul 2023 13:05:59 +0530 Subject: [PATCH 1/5] committed --- gui/pages/Content/Agents/ResourceList.js | 16 +++++++--------- 1 file changed, 7 insertions(+), 9 deletions(-) diff --git a/gui/pages/Content/Agents/ResourceList.js b/gui/pages/Content/Agents/ResourceList.js index ce3dcfa9f..288628eac 100644 --- a/gui/pages/Content/Agents/ResourceList.js +++ b/gui/pages/Content/Agents/ResourceList.js @@ -4,7 +4,7 @@ import Image from "next/image"; import {downloadFile, downloadAllFiles, formatBytes, returnResourceIcon} from "@/utils/utils"; export default function ResourceList({files, channel, runs}) { - const [selectedRun, setSelectedRun] = useState(null); + const [selectedRunId, setSelectedRunId] = useState(null); const filesByRun = useMemo(() => runs.map(run => { const relatedFiles = files.filter(file => file.agent_execution_id === run.id); return relatedFiles.length !== 0 && {"run": run, "files": relatedFiles}; @@ -15,7 +15,7 @@ export default function ResourceList({files, channel, runs}) { runFiles.length !== 0 && downloadAllFiles(runFiles, name); } - const isAnyFileWithAgentId = files.some(file => file.agent_execution_id !== null) + const isAnyFileWithAgentId = files.some(file => file.agent_execution_id !== null); const File = ({file, index}) => (
downloadFile(file.id, file.name)} className={styles.history_box} @@ -45,10 +45,10 @@ export default function ResourceList({files, channel, runs}) { {filesByRun.map((filesRun, index) => (
setSelectedRun(filesRun.run === selectedRun ? null : filesRun.run)}> + onClick={() => setSelectedRunId(filesRun.run.id === selectedRunId ? null : filesRun.run.id)}>
arrow {filesRun.run.name}
bolt downloadRunFiles(filesRun.run.id, filesRun.run.name)}/>
- {selectedRun === filesRun.run && ( + {selectedRunId === filesRun.run.id && (
- {/* eslint-disable-next-line react/jsx-key */} - {filesRun.files.map((file, index) => )} + {filesRun.files.map((file, index) => )}
)}
@@ -72,8 +71,7 @@ export default function ResourceList({files, channel, runs}) { {channel === 'input' &&
- {/* eslint-disable-next-line react/jsx-key */} - {files.map((file, index) => )} + {files.map((file, index) => )}
}
) From 65217d6e6843c1482cce41b167fb8d3f94ed30d4 Mon Sep 17 00:00:00 2001 From: Kalki Date: Tue, 18 Jul 2023 13:09:43 +0530 Subject: [PATCH 2/5] marketplace bug fix - naman --- gui/pages/Content/Marketplace/AgentTemplate.js | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/gui/pages/Content/Marketplace/AgentTemplate.js b/gui/pages/Content/Marketplace/AgentTemplate.js index f1d4bda4c..99393a110 100644 --- a/gui/pages/Content/Marketplace/AgentTemplate.js +++ b/gui/pages/Content/Marketplace/AgentTemplate.js @@ -53,7 +53,7 @@ export default function AgentTemplate({template, env}) { setGoals(data.configs.goal.value) setConstraints(data.configs.constraints.value) setTools(data.configs.tools.value) - setInstructions(data.configs.instructions ? data.configs.instructions.value : null); + setInstructions(data.configs.instruction ? data.configs.instruction.value : null); setIsLoading(false) } @@ -175,7 +175,6 @@ export default function AgentTemplate({template, env}) { {instructions.map((instruction, index) => (
{index + 1}. {instruction || ''}
- {index !== instructions.length - 1 &&
}
))}
} From 3dec554b9be3500784182580e1c19619d1dea966 Mon Sep 17 00:00:00 2001 From: Kalki Date: Tue, 18 Jul 2023 13:23:18 +0530 Subject: [PATCH 3/5] Agent Create Scrolling Issue - Parth --- gui/pages/Content/Agents/AgentCreate.js | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/gui/pages/Content/Agents/AgentCreate.js b/gui/pages/Content/Agents/AgentCreate.js index eb51abe22..94ff50837 100644 --- a/gui/pages/Content/Agents/AgentCreate.js +++ b/gui/pages/Content/Agents/AgentCreate.js @@ -96,6 +96,11 @@ export default function AgentCreate({ const [createModal, setCreateModal] = useState(false); const [scheduleData, setScheduleData] = useState(null); + const [col6ScrollTop, setCol6ScrollTop] = useState(0); + + const handleCol3Scroll = (event) => { + setCol6ScrollTop(event.target.scrollTop); + }; useEffect(() => { getOrganisationConfig(organisationId, "model_api_key") @@ -653,7 +658,7 @@ export default function AgentCreate({ return (<>
-
+
Create new agent
From d83071017bd5163e597bd8cb373eff9f8b049ee8 Mon Sep 17 00:00:00 2001 From: Kalki Date: Tue, 18 Jul 2023 13:28:44 +0530 Subject: [PATCH 4/5] Agent Create Scrolling Issue - Parth --- gui/pages/Content/Agents/AgentCreate.js | 4 ++-- gui/pages/_app.css | 3 +++ 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/gui/pages/Content/Agents/AgentCreate.js b/gui/pages/Content/Agents/AgentCreate.js index 94ff50837..c0c8afc1f 100644 --- a/gui/pages/Content/Agents/AgentCreate.js +++ b/gui/pages/Content/Agents/AgentCreate.js @@ -967,9 +967,9 @@ export default function AgentCreate({ src={!permissionDropdown ? '/images/dropdown_down.svg' : '/images/dropdown_up.svg'} alt="expand-icon"/>
-
+
{permissionDropdown && -
+
{permissions.map((permit, index) => (
handlePermissionSelect(index)} style={{padding: '12px 14px', maxWidth: '100%'}}> diff --git a/gui/pages/_app.css b/gui/pages/_app.css index 646a735dd..7cb54b15c 100644 --- a/gui/pages/_app.css +++ b/gui/pages/_app.css @@ -653,6 +653,9 @@ p { .mb_10{margin-bottom: 10px;} .mb_16{margin-bottom: 16px;} .mb_20{margin-bottom: 20px;} +.mb_24{margin-bottom: 24px;} +.mb_30{margin-bottom: 30px;} +.mb_34{margin-bottom: 34px;} .ml_24{margin-left:24px;} .ml_6{margin-left: 6px;} From bde4f2874b29294690957addb8f3210d05e6f53b Mon Sep 17 00:00:00 2001 From: Kalki Date: Tue, 18 Jul 2023 13:40:54 +0530 Subject: [PATCH 5/5] APM Dashboard (commenting reset button) - Parth --- gui/pages/Content/APM/ApmDashboard.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gui/pages/Content/APM/ApmDashboard.js b/gui/pages/Content/APM/ApmDashboard.js index 51f6678f0..510c2ee43 100644 --- a/gui/pages/Content/APM/ApmDashboard.js +++ b/gui/pages/Content/APM/ApmDashboard.js @@ -130,7 +130,7 @@ export default function ApmDashboard() { padding: '0 8px' }}> Agent Performance Monitoring - + {/**/}