Skip to content

Commit

Permalink
Merge pull request sirocco-ventures#109 from uchiha-vivek/dependency
Browse files Browse the repository at this point in the history
Change default behavior of capability collapsible card to be closed on Capabilities sirocco-ventures#37
  • Loading branch information
ashmilhussain authored Oct 11, 2024
2 parents ac6d3a2 + 7596055 commit 9c5e027
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 8 deletions.
10 changes: 4 additions & 6 deletions ui/src/pages/ChatConfiguration/ChatConfiguration.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -96,13 +96,11 @@ const BotConfiguration = () => {
tempSelectedCapabilities.push({ value: cap.id, label: cap.name })
})
setSelectedOptions(tempSelectedCapabilities)
console.log({k :configs[0].inference[0]?.id})


if(configs[0].capabilities?.length == 0) {
setCapabalities([{id: undefined, title:`Capability 1`, name:"", description:"", requirements: [], isCollapse: false}])
}else{
setCapabalities(configs[0].capabilities)
}
if(configs[0].capabalities?.length>0){
setCapabalities(configs[0].capabalities)
}

if(configs[0].inference[0]?.id){
let inference = configs[0].inference[0];
Expand Down
8 changes: 6 additions & 2 deletions ui/src/pages/Configuration/ProviderForm/ProviderForm.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ const ProviderForm = ()=>{
const [progressTime, setProgressTime] = useState('');
const pdfUploadRef = useRef(null);



const [disableConnectorSave, setDisableConnectorSave] = useState(true);

Expand Down Expand Up @@ -111,7 +112,8 @@ const ProviderForm = ()=>{
window.localStorage.setItem("dbschema", JSON.stringify(tempTableDetails))

}




const rowExpandComponent = (row)=>{
let tempTableDetails = JSON.parse(window.localStorage.getItem("dbschema"))
Expand Down Expand Up @@ -619,7 +621,9 @@ const onRemoveFile = (fileId) => {
<Tabs activeTab={currentActiveTab}>
<Tab title="Configuration" tabKey="configuration" key={"configuration"}>
<form onSubmit={handleSubmit(onSaveConnector)}>
{generateGeneralDetails()}

{generateGeneralDetails()}

<div className={style.ActionDiv}>
<div style={{flexGrow: 1}}>
<Button type="transparent" className="icon-button" onClick={()=>navigate("/plugins")}> <FaArrowLeft/> Cancel</Button>
Expand Down

0 comments on commit 9c5e027

Please sign in to comment.