Skip to content

Commit

Permalink
Merge branch 'develop' into steam-beta
Browse files Browse the repository at this point in the history
  • Loading branch information
Raphiiko committed Oct 23, 2023
2 parents 61dac59 + 2c9a78f commit 39a2421
Show file tree
Hide file tree
Showing 41 changed files with 12,750 additions and 11,231 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- A configuration saving loop in status automations view
- Malformed OSC packets causing a crash
- OSC message processing being slower than necessary
- Date formatting for Korean language

## [1.9.0]

Expand Down
13 changes: 13 additions & 0 deletions src-ui/app/app-routing.module.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,8 @@ import { PowerAutomationsViewComponent } from './views/dashboard-view/views/powe
import { ShutdownAutomationsViewComponent } from './views/dashboard-view/views/shutdown-automations-view/shutdown-automations-view.component';
import { VRChatMicMuteAutomationsViewComponent } from './views/dashboard-view/views/vrchat-mic-mute-automations-view/vrchat-mic-mute-automations-view.component';
import { SystemMicMuteAutomationsViewComponent } from './views/dashboard-view/views/system-mic-mute-automations-view/system-mic-mute-automations-view.component';
import { TranslationLoaderViewComponent } from './modules/translation/views/translation-loader-view/translation-loader-view.component';
import { TranslationEditorViewComponent } from './modules/translation/views/translation-editor-view/translation-editor-view.component';

const routes: Routes = [
{
Expand Down Expand Up @@ -95,6 +97,17 @@ const routes: Routes = [
},
],
},
{
path: 'translation',
children: [
{ path: 'loader', component: TranslationLoaderViewComponent },
{ path: 'editor', component: TranslationEditorViewComponent },
{
path: '**',
redirectTo: 'loader',
},
],
},
{
path: '**',
redirectTo: 'dashboard',
Expand Down
9 changes: 9 additions & 0 deletions src-ui/app/app.module.ts
Original file line number Diff line number Diff line change
Expand Up @@ -167,6 +167,10 @@ import { SystemMicMuteAutomationService } from './services/system-mic-mute-autom
import { OpenVRInputService } from './services/openvr-input.service';
import { OverlayService } from './services/overlay/overlay.service';
import { ControllerBindingComponent } from './components/controller-binding/controller-binding.component';
import { TranslationLoaderViewComponent } from './modules/translation/views/translation-loader-view/translation-loader-view.component';
import { FormsModule } from '@angular/forms';
import { TranslationEditorViewComponent } from './modules/translation/views/translation-editor-view/translation-editor-view.component';
import { TextareaAutoResizeDirective } from './directives/textarea-auto-resize.directive';

[localeEN, localeFR, localeCN_TW, localeNL, localeKO, localeJP, localeES, localeID].forEach(
(locale) => registerLocaleData(locale)
Expand Down Expand Up @@ -262,6 +266,9 @@ export function createTranslateLoader(http: HttpClient) {
DebugAudioDeviceDebuggerComponent,
SystemMicMuteAutomationsViewComponent,
ControllerBindingComponent,
TranslationLoaderViewComponent,
TranslationEditorViewComponent,
TextareaAutoResizeDirective,
],
imports: [
CommonModule,
Expand All @@ -283,8 +290,10 @@ export function createTranslateLoader(http: HttpClient) {
},
}),
NgPipesModule,
FormsModule,
],
providers: [ThemeService, TStringTranslatePipe],
exports: [SelectBoxComponent],
})
export class AppModule {
constructor(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,34 +7,28 @@
<div class="icon-wrapper">
<img src="/assets/img/icon_controller.png" />
</div>
<div class="text-wrapper" *ngIf="error && error !== 'MISSING_CONTROLLER' && error !=='NO_CONTROLLERS'">
<div
class="text-wrapper"
*ngIf="error && error !== 'MISSING_CONTROLLER' && error !== 'NO_CONTROLLERS'"
>
<ng-container *ngIf="error === 'MISSING_KEY'">
<div class="line1" translate>
No Action Set
</div>
<div class="line1" translate> No Action Set </div>
</ng-container>
<ng-container *ngIf="error === 'STEAMVR_INACTIVE'">
<div class="line1" translate>
comp.controller-binding.errors.STEAMVR_INACTIVE.message
</div>
<div class="line1" translate> comp.controller-binding.errors.STEAMVR_INACTIVE.message </div>
</ng-container>
<ng-container *ngIf="error === 'DASHBOARD_OPEN'">
<div class="line1" translate>
comp.controller-binding.errors.DASHBOARD_OPEN.message
</div>
<div class="line1" translate> comp.controller-binding.errors.DASHBOARD_OPEN.message </div>
</ng-container>
<ng-container *ngIf="error === 'UNKNOWN'">
<div class="line1" translate>
comp.controller-binding.errors.UNKNOWN.message
</div>
<div class="line1" translate> comp.controller-binding.errors.UNKNOWN.message </div>
</ng-container>
</div>
<ng-container *ngIf="error === 'MISSING_CONTROLLER' || error === 'NO_CONTROLLERS'">
<div class="missing-controller-row">
<div class="missing-controller missing-controller-left" [class.connected]="hasLeftHand">
<span>L</span>
<img src="/assets/img/icon_controller.png" />

</div>
<div class="missing-controller missing-controller-right" [class.connected]="hasRightHand">
<img src="/assets/img/icon_controller.png" />
Expand All @@ -45,11 +39,11 @@
<div class="text-wrapper" *ngIf="!error">
<div class="line0">{{ activeBinding?.localizedControllerType }}</div>
<div class="line1"
>{{ activeBinding?.localizedHand }} {{ activeBinding?.localizedInputSource }}</div
>{{ activeBinding?.localizedHand }} {{ activeBinding?.localizedInputSource }}</div
>
<div class="line2">{{
'comp.controller-binding.slot.' + activeBinding?.slotName | translate
}}</div>
}}</div>
</div>
</button>
<div class="dropdown-container">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
border-radius: 0.5em;
cursor: pointer;
font-size: 12px;
transition: all .15s;
transition: all 0.15s;
padding: 0;
min-width: 13em;

Expand All @@ -30,7 +30,8 @@
width: 1.5em;
height: 1.5em;
vertical-align: middle;
filter: invert(91%) sepia(2%) saturate(3440%) hue-rotate(193deg) brightness(83%) contrast(100%);
filter: invert(91%) sepia(2%) saturate(3440%) hue-rotate(193deg) brightness(83%)
contrast(100%);
}
}

Expand All @@ -41,7 +42,8 @@
padding: 0.5em 1em 0.5em 0.25em;
white-space: pre-line;

.line0, .line2 {
.line0,
.line2 {
color: var(--color-text-3);
}
}
Expand Down Expand Up @@ -78,16 +80,14 @@
width: 1.5em;
height: 1.5em;
vertical-align: middle;
filter: invert(91%) sepia(2%) saturate(3440%) hue-rotate(193deg) brightness(83%) contrast(100%);
filter: invert(91%) sepia(2%) saturate(3440%) hue-rotate(193deg) brightness(83%)
contrast(100%);
}

&-left {


}

&-right {

}
}
}
Expand Down Expand Up @@ -126,7 +126,7 @@
border: 1px solid;
border-color: var(--color-surface-2);
border-radius: 0.5em;
transition: all .15s;
transition: all 0.15s;
@include shadow(5, true);
overflow: hidden;

Expand All @@ -148,7 +148,7 @@
padding: 0.5em;
color: var(--color-text-2);
cursor: pointer;
transition: all .15s;
transition: all 0.15s;
&:hover {
background: var(--color-surface-1);
}
Expand All @@ -158,4 +158,3 @@
}
}
}

Original file line number Diff line number Diff line change
Expand Up @@ -136,12 +136,12 @@
<div class="menu-item-label" translate>comp.dashboard-navbar.autoInviteRequestAccept</div>
</div>

<!-- <div class="menu-item" [routerLinkActive]="'active'" [routerLink]="'vrchatMicMuteAutomations'">-->
<!-- <div class="menu-item-icon-prefix">-->
<!-- <i class="material-icons-round">mic_off</i>-->
<!-- </div>-->
<!-- <div class="menu-item-label" translate>comp.dashboard-navbar.vrchatMicMuteAutomations</div>-->
<!-- </div>-->
<!-- <div class="menu-item" [routerLinkActive]="'active'" [routerLink]="'vrchatMicMuteAutomations'">-->
<!-- <div class="menu-item-icon-prefix">-->
<!-- <i class="material-icons-round">mic_off</i>-->
<!-- </div>-->
<!-- <div class="menu-item-label" translate>comp.dashboard-navbar.vrchatMicMuteAutomations</div>-->
<!-- </div>-->

<div class="menu-item" [routerLinkActive]="'active'" [routerLink]="'oscAutomations'">
<div class="menu-item-icon-prefix">
Expand Down
Original file line number Diff line number Diff line change
@@ -1,40 +1,58 @@
<button class="btn btn-secondary" (click)="audioDeviceService.getAudioDevices()">Refresh Devices</button>
<button class="btn btn-secondary" (click)="audioDeviceService.getAudioDevices()"
>Refresh Devices</button
>
<div class="device-lists">
<div class="device-list">
<h3>Render Devices</h3>
<div class="device" *ngFor="let device of renderDevices | async">
<h4>{{device.name}}</h4>
<h4>{{ device.name }}</h4>
<div>
<span *ngIf="device.mute">Muted</span>
<span *ngIf="!device.mute">Unmuted</span>
<span *ngIf="device.default">&nbsp;(Default Device)</span>
<span *ngIf="device.default">&nbsp;(Default Communications Device)</span>
</div>
<div class="row">
<span>{{device.volume * 100 | number: '1.1-1'}}%</span>
<app-slider [min]="0" [max]="1" [step]="0.001" [value]="device.volume"
(valueChange)="audioDeviceService.setVolume(device.id, $event)"></app-slider>
<span>{{ device.volume * 100 | number : '1.1-1' }}%</span>
<app-slider
[min]="0"
[max]="1"
[step]="0.001"
[value]="device.volume"
(valueChange)="audioDeviceService.setVolume(device.id, $event)"
></app-slider>
</div>
<button class="btn btn-secondary" (click)="audioDeviceService.setMute(device.id, !device.mute)">Toggle Mute
<button
class="btn btn-secondary"
(click)="audioDeviceService.setMute(device.id, !device.mute)"
>Toggle Mute
</button>
</div>
</div>
<div class="device-list">
<h3>Capture Devices</h3>
<div class="device" *ngFor="let device of captureDevices | async">
<h4>{{device.name}}</h4>
<h4>{{ device.name }}</h4>
<div>
<span *ngIf="device.mute">Muted</span>
<span *ngIf="!device.mute">Unmuted</span>
<span *ngIf="device.default">&nbsp;(Default Device)</span>
<span *ngIf="device.default">&nbsp;(Default Communications Device)</span>
</div>
<div class="row">
<span>{{device.volume * 100 | number: '1.1-1'}}%</span>
<app-slider [min]="0" [max]="1" [step]="0.001" [value]="device.volume"
(valueChange)="audioDeviceService.setVolume(device.id, $event)"></app-slider>
<span>{{ device.volume * 100 | number : '1.1-1' }}%</span>
<app-slider
[min]="0"
[max]="1"
[step]="0.001"
[value]="device.volume"
(valueChange)="audioDeviceService.setVolume(device.id, $event)"
></app-slider>
</div>
<button class="btn btn-secondary" (click)="audioDeviceService.setMute(device.id, !device.mute)">Toggle Mute
<button
class="btn btn-secondary"
(click)="audioDeviceService.setMute(device.id, !device.mute)"
>Toggle Mute
</button>
</div>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,9 @@
<app-debug-brightness-testing
*ngIf="activeTab === 'BRIGHTNESS_TESTING'"
></app-debug-brightness-testing>
<app-debug-audio-device-debugger *ngIf="activeTab === 'AUDIO_DEVICE'"></app-debug-audio-device-debugger>
<app-misc-testing *ngIf="activeTab === 'MISC_TESTING'"></app-misc-testing>
<app-debug-audio-device-debugger
*ngIf="activeTab === 'AUDIO_DEVICE'"
></app-debug-audio-device-debugger>
<app-misc-testing *ngIf="activeTab === 'MISC_TESTING'" [modal]="this"></app-misc-testing>
</div>
</div>
Original file line number Diff line number Diff line change
@@ -1,11 +1,21 @@
<h3>Navigation</h3>
<div class="row">
<button class="btn btn-secondary" (click)="navigateTo(['translation'])"
>Translation Module</button
>
</div>
<h3>Actions</h3>
<button class="btn btn-secondary" (click)="openBindingConfig()">Open Binding Config</button>
<button class="btn btn-secondary" (click)="getActionBindings()">Get Action Bindings</button>
<pre *ngIf="bindings">{{bindings | json}}</pre>
<pre *ngIf="bindings">{{ bindings | json }}</pre>
<h3>Notification Sounds</h3>
<div class="row">
<button class="btn btn-secondary" (click)="playSound('notification_bell')">notification_bell</button>
<button class="btn btn-secondary" (click)="playSound('notification_block')">notification_block</button>
<button class="btn btn-secondary" (click)="playSound('notification_bell')"
>notification_bell</button
>
<button class="btn btn-secondary" (click)="playSound('notification_block')"
>notification_block</button
>
<button class="btn btn-secondary" (click)="playSound('mic_mute')">mic_mute</button>
<button class="btn btn-secondary" (click)="playSound('mic_unmute')">mic_unmute</button>
<app-slider-setting [(value)]="soundVolume" [max]="200"></app-slider-setting>
Expand All @@ -18,5 +28,5 @@ <h3>VRChat microphone muting</h3>
<button class="btn btn-primary" (click)="automation.setMute(false)">Unmute</button>
<button class="btn btn-secondary" (click)="automation.setMode('TOGGLE')">Set Toggle Mode</button>
<button class="btn btn-secondary" (click)="automation.setMode('PUSH_TO_MUTE')"
>Set Push To Mute Mode
>Set Push To Mute Mode
</button>
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
import { Component } from '@angular/core';
import { Component, Input } from '@angular/core';
import { VRChatMicMuteAutomationService } from '../../../services/osc-automations/vrchat-mic-mute-automation.service';
import { invoke } from '@tauri-apps/api';
import { OVRInputEventAction, OVRInputEventActionSet } from '../../../models/ovr-input-event';
import { NotificationService, NotificationSound } from '../../../services/notification.service';
import { Router } from '@angular/router';
import { BaseModalComponent } from '../../base-modal/base-modal.component';

@Component({
selector: 'app-misc-testing',
Expand All @@ -12,10 +14,12 @@ import { NotificationService, NotificationSound } from '../../../services/notifi
export class MiscTestingComponent {
bindings: any;
soundVolume = 100;
@Input() modal?: BaseModalComponent<any, any>;

constructor(
protected automation: VRChatMicMuteAutomationService,
private notificationService: NotificationService
private notificationService: NotificationService,
private router: Router
) {}

async openBindingConfig() {
Expand Down Expand Up @@ -47,4 +51,9 @@ export class MiscTestingComponent {
async playSound(sound: NotificationSound) {
await this.notificationService.playSound(sound, this.soundVolume / 100);
}

navigateTo(destination: string[]) {
this.router.navigate(destination);
this.modal?.close();
}
}
Loading

0 comments on commit 39a2421

Please sign in to comment.