Skip to content

Commit d317190

Browse files
committed
Add alt to img, fix styling issue voice
1 parent 0a954cf commit d317190

8 files changed

+46
-12
lines changed

src/dialogs/voice-assistant-setup/styles.ts

+5-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ export const AssistantSetupStyles = [
77
:host {
88
align-items: center;
99
text-align: center;
10-
min-height: 300px;
10+
min-height: 400px;
1111
display: flex;
1212
flex-direction: column;
1313
justify-content: space-between;
@@ -22,6 +22,10 @@ export const AssistantSetupStyles = [
2222
width: 120px;
2323
}
2424
@media all and (max-width: 450px), all and (max-height: 500px) {
25+
:host {
26+
min-height: 100%;
27+
height: auto;
28+
}
2529
.content img {
2630
margin-top: 68px;
2731
margin-bottom: 68px;

src/dialogs/voice-assistant-setup/voice-assistant-setup-step-area.ts

+4-1
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,10 @@ export class HaVoiceAssistantSetupStepArea extends LitElement {
1717
const device = this.hass.devices[this.deviceId];
1818

1919
return html`<div class="content">
20-
<img src="/static/images/voice-assistant/area.png" />
20+
<img
21+
src="/static/images/voice-assistant/area.png"
22+
alt="Casita Home Assistant logo"
23+
/>
2124
<h1>Select area</h1>
2225
<p class="secondary">
2326
When you voice assistant knows where it is, it can better control the

src/dialogs/voice-assistant-setup/voice-assistant-setup-step-change-wake-word.ts

+4-1
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,10 @@ export class HaVoiceAssistantSetupStepChangeWakeWord extends LitElement {
2121

2222
protected override render() {
2323
return html`<div class="padding content">
24-
<img src="/static/images/voice-assistant/change-wake-word.png" />
24+
<img
25+
src="/static/images/voice-assistant/change-wake-word.png"
26+
alt="Casita Home Assistant logo"
27+
/>
2528
<h1>Change wake word</h1>
2629
<p class="secondary">
2730
Some wake words are better for

src/dialogs/voice-assistant-setup/voice-assistant-setup-step-check.ts

+8-2
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,10 @@ export class HaVoiceAssistantSetupStepCheck extends LitElement {
3636
protected override render() {
3737
return html`<div class="content">
3838
${this._status === "timeout"
39-
? html`<img src="/static/images/voice-assistant/error.png" />
39+
? html`<img
40+
src="/static/images/voice-assistant/error.png"
41+
alt="Casita Home Assistant error logo"
42+
/>
4043
<h1>The voice assistant is unable to connect to Home Assistant</h1>
4144
<p class="secondary">
4245
To play audio, the voice assistant device has to connect to Home
@@ -53,7 +56,10 @@ export class HaVoiceAssistantSetupStepCheck extends LitElement {
5356
>
5457
<ha-button @click=${this._testConnection}>Retry</ha-button>
5558
</div>`
56-
: html`<img src="/static/images/voice-assistant/hi.png" />
59+
: html`<img
60+
src="/static/images/voice-assistant/hi.png"
61+
alt="Casita Home Assistant hi logo"
62+
/>
5763
<h1>Hi</h1>
5864
<p class="secondary">
5965
Over the next couple steps we're going to personalize your voice

src/dialogs/voice-assistant-setup/voice-assistant-setup-step-local.ts

+12-3
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,10 @@ export class HaVoiceAssistantSetupStepLocal extends LitElement {
4444
protected override render() {
4545
return html`<div class="content">
4646
${this._state === "INSTALLING"
47-
? html`<img src="/static/images/voice-assistant/update.png" />
47+
? html`<img
48+
src="/static/images/voice-assistant/update.png"
49+
alt="Casita Home Assistant loading logo"
50+
/>
4851
<h1>Installing add-ons</h1>
4952
<p>
5053
The Whisper and Piper add-ons are being installed and configured.
@@ -54,7 +57,10 @@ export class HaVoiceAssistantSetupStepLocal extends LitElement {
5457
${this._detailState || "Installation can take several minutes"}
5558
</p>`
5659
: this._state === "ERROR"
57-
? html` <img src="/static/images/voice-assistant/error.png" />
60+
? html` <img
61+
src="/static/images/voice-assistant/error.png"
62+
alt="Casita Home Assistant error logo"
63+
/>
5864
<h1>Failed to install add-ons</h1>
5965
<p>
6066
We could not automatically install a local TTS and STT provider
@@ -75,7 +81,10 @@ export class HaVoiceAssistantSetupStepLocal extends LitElement {
7581
>
7682
</a>`
7783
: this._state === "NOT_SUPPORTED"
78-
? html`<img src="/static/images/voice-assistant/error.png" />
84+
? html`<img
85+
src="/static/images/voice-assistant/error.png"
86+
alt="Casita Home Assistant error logo"
87+
/>
7988
<h1>Installation of add-ons is not supported on your system</h1>
8089
<p>
8190
Your system is not supported to automatically install a local

src/dialogs/voice-assistant-setup/voice-assistant-setup-step-success.ts

+4-1
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,10 @@ export class HaVoiceAssistantSetupStepSuccess extends LitElement {
6868
: undefined;
6969

7070
return html`<div class="content">
71-
<img src="/static/images/voice-assistant/heart.png" />
71+
<img
72+
src="/static/images/voice-assistant/heart.png"
73+
alt="Casita Home Assistant logo"
74+
/>
7275
<h1>Ready to Assist!</h1>
7376
<p class="secondary">
7477
Make any final customizations here. You can always change these in the

src/dialogs/voice-assistant-setup/voice-assistant-setup-step-update.ts

+4-1
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,10 @@ export class HaVoiceAssistantSetupStepUpdate extends LitElement {
6565
const progressIsNumeric = stateObj && updateUsesProgress(stateObj);
6666

6767
return html`<div class="content">
68-
<img src="/static/images/voice-assistant/update.png" />
68+
<img
69+
src="/static/images/voice-assistant/update.png"
70+
alt="Casita Home Assistant loading logo"
71+
/>
6972
<h1>
7073
${stateObj &&
7174
(stateObj.state === "unavailable" || updateIsInstalling(stateObj))

src/dialogs/voice-assistant-setup/voice-assistant-setup-step-wake-word.ts

+5-2
Original file line numberDiff line numberDiff line change
@@ -90,14 +90,17 @@ export class HaVoiceAssistantSetupStepWakeWord extends LitElement {
9090
return html`<div class="content">
9191
${!this._detected
9292
? html`
93-
<img src="/static/images/voice-assistant/sleep.png" />
93+
<img src="/static/images/voice-assistant/sleep.png" alt="Casita Home Assistant logo"/>
9494
<h1>
9595
Say “${this._activeWakeWord(this.assistConfiguration)}” to wake the
9696
device up
9797
</h1>
9898
<p class="secondary">Setup will continue once the device is awake.</p>
9999
</div>`
100-
: html`<img src="/static/images/voice-assistant/ok-nabu.png" />
100+
: html`<img
101+
src="/static/images/voice-assistant/ok-nabu.png"
102+
alt="Casita Home Assistant logo"
103+
/>
101104
<h1>
102105
Say “${this._activeWakeWord(this.assistConfiguration)}” again
103106
</h1>

0 commit comments

Comments
 (0)