Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -208,14 +208,6 @@ export function DataExtensionsEditor({
});
}, []);

const onGenerateAllFromLlmClick = useCallback(() => {
vscode.postMessage({
t: "generateExternalApiFromLlm",
externalApiUsages,
modeledMethods,
});
}, [externalApiUsages, modeledMethods]);

const onModelDependencyClick = useCallback(() => {
vscode.postMessage({
t: "modelDependency",
Expand Down Expand Up @@ -304,23 +296,21 @@ export function DataExtensionsEditor({

<EditorContainer>
<ButtonsContainer>
<VSCodeButton onClick={onSaveAllClick}>Apply</VSCodeButton>
<VSCodeButton
onClick={onSaveAllClick}
disabled={modifiedSignatures.size === 0}
>
Save all
</VSCodeButton>
{viewState.enableFrameworkMode && (
<VSCodeButton appearance="secondary" onClick={onRefreshClick}>
Refresh
</VSCodeButton>
)}
<VSCodeButton onClick={onGenerateFromSourceClick}>
{viewState.mode === Mode.Framework
? "Generate"
: "Download and generate"}
</VSCodeButton>
{viewState.showLlmButton && (
<>
<VSCodeButton onClick={onGenerateAllFromLlmClick}>
Generate using LLM
</VSCodeButton>
</>
{viewState.mode === Mode.Framework && (
<VSCodeButton onClick={onGenerateFromSourceClick}>
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've just removed Application mode from the conditional. Should we also remove the references to Application mode from the underlying function here, or are we expecting to use that somewhere else? πŸ€”

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actually, ignore me! It looks like this function is also called from the "Model from source" button in application mode, so will keep it as-is:
image

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yep, that's right. That code is still called in both modes.

Generate
</VSCodeButton>
)}
</ButtonsContainer>
<ModeledMethodsList
Expand Down