Merge 12c403b7e2 into da71eaebd2
This commit is contained in:
commit
6b9f0cdaec
@ -240,7 +240,16 @@ export function renderChat(props: ChatProps) {
|
||||
`;
|
||||
|
||||
return html`
|
||||
<section class="card chat">
|
||||
<section
|
||||
class="card chat"
|
||||
tabindex="-1"
|
||||
@keydown=${(e: KeyboardEvent) => {
|
||||
if (e.key === "Escape" && canAbort && props.onAbort) {
|
||||
e.preventDefault();
|
||||
props.onAbort();
|
||||
}
|
||||
}}
|
||||
>
|
||||
${props.disabledReason
|
||||
? html`<div class="callout">${props.disabledReason}</div>`
|
||||
: nothing}
|
||||
@ -359,7 +368,9 @@ export function renderChat(props: ChatProps) {
|
||||
?disabled=${!props.connected || (!canAbort && props.sending)}
|
||||
@click=${canAbort ? props.onAbort : props.onNewSession}
|
||||
>
|
||||
${canAbort ? "Stop" : "New session"}
|
||||
${canAbort ? "Stop" : "New session"}${canAbort
|
||||
? html`<kbd class="btn-kbd">Esc</kbd>`
|
||||
: nothing}
|
||||
</button>
|
||||
<button
|
||||
class="btn primary"
|
||||
|
||||
Loading…
Reference in New Issue
Block a user