-
-
Notifications
You must be signed in to change notification settings - Fork 87
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(prettier): explicitly use latest version
- Loading branch information
Showing
47 changed files
with
662 additions
and
571 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
14 changes: 7 additions & 7 deletions
14
src/app/components/i18n-language-selector/i18n-language-selector.component.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,11 @@ | ||
<select [attr.aria-label]="'language-selector.label' | transloco" (change)="change($event)"> | ||
@for (group of languages; track group) { | ||
<optgroup [label]="group.label"> | ||
@for (lang of group.languages; track lang.key) { | ||
<option [value]="lang.key" [selected]="lang.key === current"> | ||
{{ lang.value }} | ||
</option> | ||
} | ||
</optgroup> | ||
<optgroup [label]="group.label"> | ||
@for (lang of group.languages; track lang.key) { | ||
<option [value]="lang.key" [selected]="lang.key === current"> | ||
{{ lang.value }} | ||
</option> | ||
} | ||
</optgroup> | ||
} | ||
</select> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,5 +3,5 @@ | |
<img src="../../../assets/brand/logo.svg" alt="Logo" /> | ||
</picture> | ||
@if (text) { | ||
{{ text }} | ||
{{ text }} | ||
} |
44 changes: 22 additions & 22 deletions
44
src/app/components/speech-to-text/speech-to-text.component.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,28 +1,28 @@ | ||
<ng-container *transloco="let t; read: 'speech-to-text'"> | ||
<!-- As a single button it is uglier code, but nice ripple animation --> | ||
@if (!supportError) { | ||
<ion-button | ||
class="circle-icon" | ||
fill="clear" | ||
shape="round" | ||
color="dark" | ||
(click)="isRecording ? stop() : start()" | ||
[attr.aria-label]="t(isRecording ? 'stop' : 'start')" | ||
[matTooltip]="t(isRecording ? 'stop' : 'start')" | ||
[matTooltipPosition]="matTooltipPosition"> | ||
<ion-icon [name]="isRecording ? 'stop-circle-outline' : 'mic-outline'" slot="icon-only" color="primary" /> | ||
</ion-button> | ||
<ion-button | ||
class="circle-icon" | ||
fill="clear" | ||
shape="round" | ||
color="dark" | ||
(click)="isRecording ? stop() : start()" | ||
[attr.aria-label]="t(isRecording ? 'stop' : 'start')" | ||
[matTooltip]="t(isRecording ? 'stop' : 'start')" | ||
[matTooltipPosition]="matTooltipPosition"> | ||
<ion-icon [name]="isRecording ? 'stop-circle-outline' : 'mic-outline'" slot="icon-only" color="primary" /> | ||
</ion-button> | ||
} @else { | ||
<!-- If language is not supported --> | ||
<ion-button | ||
class="circle-icon" | ||
fill="clear" | ||
shape="round" | ||
color="medium" | ||
[attr.aria-label]="t(supportError)" | ||
[matTooltip]="t(supportError)" | ||
[matTooltipPosition]="matTooltipPosition"> | ||
<ion-icon name="mic-off-outline" slot="icon-only" /> | ||
</ion-button> | ||
<!-- If language is not supported --> | ||
<ion-button | ||
class="circle-icon" | ||
fill="clear" | ||
shape="round" | ||
color="medium" | ||
[attr.aria-label]="t(supportError)" | ||
[matTooltip]="t(supportError)" | ||
[matTooltipPosition]="matTooltipPosition"> | ||
<ion-icon name="mic-off-outline" slot="icon-only" /> | ||
</ion-button> | ||
} | ||
</ng-container> |
57 changes: 31 additions & 26 deletions
57
src/app/components/text-to-speech/text-to-speech.component.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,28 +1,33 @@ | ||
<ng-container *transloco="let t; read: 'text-to-speech'"> | ||
@if (text.trim()) { @if (isSupported) { | ||
<!-- As a single button it is uglier code, but nice ripple animation --> | ||
<ion-button | ||
class="circle-icon" | ||
fill="clear" | ||
shape="round" | ||
color="dark" | ||
(click)="isSpeaking ? cancel() : play()" | ||
[attr.aria-label]="t(isSpeaking ? 'cancel' : 'play')" | ||
[matTooltip]="t(isSpeaking ? 'cancel' : 'play')" | ||
matTooltipPosition="above"> | ||
<ion-icon [name]="isSpeaking ? 'stop-circle-outline' : 'volume-medium-outline'" slot="icon-only" color="primary" /> | ||
</ion-button> | ||
} @else { | ||
<!-- If language is not supported --> | ||
<ion-button | ||
class="circle-icon" | ||
fill="clear" | ||
shape="round" | ||
color="medium" | ||
[attr.aria-label]="t('unavailable')" | ||
[matTooltip]="t('unavailable')" | ||
matTooltipPosition="above"> | ||
<ion-icon name="volume-mute-outline" slot="icon-only" /> | ||
</ion-button> | ||
} } | ||
@if (text.trim()) { | ||
@if (isSupported) { | ||
<!-- As a single button it is uglier code, but nice ripple animation --> | ||
<ion-button | ||
class="circle-icon" | ||
fill="clear" | ||
shape="round" | ||
color="dark" | ||
(click)="isSpeaking ? cancel() : play()" | ||
[attr.aria-label]="t(isSpeaking ? 'cancel' : 'play')" | ||
[matTooltip]="t(isSpeaking ? 'cancel' : 'play')" | ||
matTooltipPosition="above"> | ||
<ion-icon | ||
[name]="isSpeaking ? 'stop-circle-outline' : 'volume-medium-outline'" | ||
slot="icon-only" | ||
color="primary" /> | ||
</ion-button> | ||
} @else { | ||
<!-- If language is not supported --> | ||
<ion-button | ||
class="circle-icon" | ||
fill="clear" | ||
shape="round" | ||
color="medium" | ||
[attr.aria-label]="t('unavailable')" | ||
[matTooltip]="t('unavailable')" | ||
matTooltipPosition="above"> | ||
<ion-icon name="volume-mute-outline" slot="icon-only" /> | ||
</ion-button> | ||
} | ||
} | ||
</ng-container> |
45 changes: 23 additions & 22 deletions
45
src/app/components/video/video-controls/video-controls.component.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,25 +1,26 @@ | ||
<ng-container *transloco="let t; read: 'video.controls'"> | ||
@if (settingsState$ | async; as settings) { | ||
<!-- Video --> | ||
@if (settings.receiveVideo) { | ||
<ion-fab> | ||
<ion-fab-button | ||
(click)="applySetting('receiveVideo', false)" | ||
[attr.aria-label]="t('receiveVideo.on')" | ||
[matTooltip]="t('receiveVideo.on')" | ||
class="transparent"> | ||
<ion-icon name="videocam-outline" /> | ||
</ion-fab-button> | ||
</ion-fab> | ||
} @else { | ||
<ion-fab> | ||
<ion-fab-button | ||
(click)="applySetting('receiveVideo', true)" | ||
[attr.aria-label]="t('receiveVideo.off')" | ||
[matTooltip]="t('receiveVideo.off')" | ||
color="danger"> | ||
<ion-icon name="videocam-off-outline" /> | ||
</ion-fab-button> | ||
</ion-fab> | ||
} } | ||
<!-- Video --> | ||
@if (settings.receiveVideo) { | ||
<ion-fab> | ||
<ion-fab-button | ||
(click)="applySetting('receiveVideo', false)" | ||
[attr.aria-label]="t('receiveVideo.on')" | ||
[matTooltip]="t('receiveVideo.on')" | ||
class="transparent"> | ||
<ion-icon name="videocam-outline" /> | ||
</ion-fab-button> | ||
</ion-fab> | ||
} @else { | ||
<ion-fab> | ||
<ion-fab-button | ||
(click)="applySetting('receiveVideo', true)" | ||
[attr.aria-label]="t('receiveVideo.off')" | ||
[matTooltip]="t('receiveVideo.off')" | ||
color="danger"> | ||
<ion-icon name="videocam-off-outline" /> | ||
</ion-fab-button> | ||
</ion-fab> | ||
} | ||
} | ||
</ng-container> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,24 +1,28 @@ | ||
@if (videoState$ | async; as videoState) { @if (poseState$ | async; as poseState) { | ||
<ng-container *transloco="let t; read: 'video'"> | ||
@if (videoState.error) { | ||
<p>{{ t('errors.' + videoState.error) }}</p> | ||
} @else if (!poseState.isLoaded) { | ||
<p>{{ 'pose.loading' | transloco }}</p> | ||
@if (videoState$ | async; as videoState) { | ||
@if (poseState$ | async; as poseState) { | ||
<ng-container *transloco="let t; read: 'video'"> | ||
@if (videoState.error) { | ||
<p>{{ t('errors.' + videoState.error) }}</p> | ||
} @else if (!poseState.isLoaded) { | ||
<p>{{ 'pose.loading' | transloco }}</p> | ||
} | ||
</ng-container> | ||
<div [hidden]="videoState.error || !poseState.isLoaded" id="video-container"> | ||
<video #video muted playsinline crossorigin="anonymous"></video> | ||
<canvas #canvas height="100%" width="100%"></canvas> | ||
<div #stats></div> | ||
@if (videoEnded) { | ||
<div class="video-overlay" (click)="replayVideo()"> | ||
<ion-icon name="play-circle-outline" /> | ||
</div> | ||
} | ||
</div> | ||
<!-- [hidden]="videoState.error || !poseState.isLoaded" --> | ||
@if (animatePose$ | async) { | ||
<app-animation /> | ||
} | ||
@if (displayControls) { | ||
<app-video-controls /> | ||
} | ||
} | ||
</ng-container> | ||
<div [hidden]="videoState.error || !poseState.isLoaded" id="video-container"> | ||
<video #video muted playsinline crossorigin="anonymous"></video> | ||
<canvas #canvas height="100%" width="100%"></canvas> | ||
<div #stats></div> | ||
@if (videoEnded) { | ||
<div class="video-overlay" (click)="replayVideo()"> | ||
<ion-icon name="play-circle-outline" /> | ||
</div> | ||
} | ||
</div> | ||
<!-- [hidden]="videoState.error || !poseState.isLoaded" --> | ||
@if (animatePose$ | async) { | ||
<app-animation /> | ||
} @if (displayControls) { | ||
<app-video-controls /> | ||
} } } | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,9 @@ | ||
<ion-list *transloco="let t; read: 'settings'"> | ||
@for (s of availableSettings; track s) { | ||
<ion-item> | ||
<ion-checkbox [checked]="settings[s]" [attr.aria-label]="t(s)" (ionChange)="changeSetting(s, $event)"> | ||
{{ t(s) }} | ||
</ion-checkbox> | ||
</ion-item> | ||
<ion-item> | ||
<ion-checkbox [checked]="settings[s]" [attr.aria-label]="t(s)" (ionChange)="changeSetting(s, $event)"> | ||
{{ t(s) }} | ||
</ion-checkbox> | ||
</ion-item> | ||
} | ||
</ion-list> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.