mirror of
https://github.com/home-assistant/frontend.git
synced 2025-07-25 18:26:35 +00:00
Pipeline debug, set pipeline instead of lang (#16217)
This commit is contained in:
parent
0f622589a3
commit
7fa4a75009
@ -112,7 +112,6 @@ export type PipelineRunOptions = (
|
|||||||
}
|
}
|
||||||
) & {
|
) & {
|
||||||
end_stage: "stt" | "intent" | "tts";
|
end_stage: "stt" | "intent" | "tts";
|
||||||
language?: string;
|
|
||||||
pipeline?: string;
|
pipeline?: string;
|
||||||
conversation_id?: string | null;
|
conversation_id?: string | null;
|
||||||
};
|
};
|
||||||
|
@ -39,7 +39,7 @@ export class AssistPipelineDebug extends LitElement {
|
|||||||
|
|
||||||
@state() private _finished = false;
|
@state() private _finished = false;
|
||||||
|
|
||||||
@state() private _languageOverride?: string;
|
@state() private _pipelineId?: string;
|
||||||
|
|
||||||
protected render(): TemplateResult {
|
protected render(): TemplateResult {
|
||||||
return html`
|
return html`
|
||||||
@ -65,8 +65,8 @@ export class AssistPipelineDebug extends LitElement {
|
|||||||
</ha-button>
|
</ha-button>
|
||||||
`
|
`
|
||||||
: html`
|
: html`
|
||||||
<ha-button slot="toolbar-icon" @click=${this._setLanguage}>
|
<ha-button slot="toolbar-icon" @click=${this._pickPipeline}>
|
||||||
Set Language
|
Pick pipeline
|
||||||
</ha-button>
|
</ha-button>
|
||||||
`}
|
`}
|
||||||
|
|
||||||
@ -282,7 +282,7 @@ export class AssistPipelineDebug extends LitElement {
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
...options,
|
...options,
|
||||||
language: this._languageOverride,
|
pipeline: this._pipelineId,
|
||||||
conversation_id: this.conversationId,
|
conversation_id: this.conversationId,
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
@ -322,15 +322,15 @@ export class AssistPipelineDebug extends LitElement {
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
private async _setLanguage() {
|
private async _pickPipeline() {
|
||||||
const language = await showPromptDialog(this, {
|
const pipeline = await showPromptDialog(this, {
|
||||||
title: "Language override",
|
title: "Set pipeline",
|
||||||
inputLabel: "Language",
|
inputLabel: "Pipeline ID",
|
||||||
inputType: "text",
|
inputType: "text",
|
||||||
confirmText: "Set",
|
confirmText: "Set",
|
||||||
});
|
});
|
||||||
if (language) {
|
if (pipeline) {
|
||||||
this._languageOverride = language;
|
this._pipelineId = pipeline;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user