fixed some small issues on the ombi settings page

This commit is contained in:
tidusjar 2020-06-11 21:53:26 +01:00
commit cbd4cee9aa
3 changed files with 35 additions and 32 deletions

View file

@ -6,15 +6,15 @@
<form novalidate [formGroup]="form" (ngSubmit)="onSubmit(form)"> <form novalidate [formGroup]="form" (ngSubmit)="onSubmit(form)">
<div class="col-md-12 col-12 col-sm-12"> <div class="col-md-12 col-12 col-sm-12">
<div class="md-form-field"> <div class="md-form-field">
<mat-form-field appearance="outline" floatLabel=always> <mat-form-field appearance="outline" >
<mat-label>Base URL</mat-label> <mat-label>Base URL</mat-label>
<input matInput placeholder="Base Url" formControlName="baseUrl"> <input matInput formControlName="baseUrl">
</mat-form-field> </mat-form-field>
</div> </div>
<div class="md-form-field"> <div class="md-form-field">
<mat-form-field appearance="outline" floatLabel=always> <mat-form-field appearance="outline">
<mat-label>Api Key</mat-label> <mat-label>Api Key</mat-label>
<input matInput id="ApiKey" name="ApiKey" placeholder="Api Key" formControlName="apiKey" readonly="readonly"> <input matInput id="ApiKey" name="ApiKey" formControlName="apiKey" readonly="readonly">
<button type="button" matSuffix (click)="refreshApiKey()" style="display:inline-block;"> <button type="button" matSuffix (click)="refreshApiKey()" style="display:inline-block;">
<mat-icon class="fa fa-refresh"></mat-icon> <mat-icon class="fa fa-refresh"></mat-icon>
</button> </button>
@ -41,19 +41,19 @@
</mat-checkbox> </mat-checkbox>
</div> </div>
<div> <div>
<mat-checkbox formControlName="collectAnalyticData" matTooltip="This will allow us to have a better understanding of the userbase so we know what we should be supporting"> <mat-checkbox formControlName="collectAnalyticData" matTooltip="This will allow us to have a better understanding of the userbase so we know what we should be supporting (Uses Google Analytics)">
Allow us to collect anonymous analytical data e.g. browser used Allow us to collect anonymous analytical data e.g. browser used
</mat-checkbox> </mat-checkbox>
</div> </div>
<div> <!-- <div>
<mat-checkbox formControlName="disableHealthChecks"> <mat-checkbox formControlName="disableHealthChecks">
Disable the health checks page Disable the health checks page
<a href="/healthchecks-ui" target="_blank">/healthchecks-ui</a> <a href="/healthchecks-ui" target="_blank">/healthchecks-ui</a>
</mat-checkbox> </mat-checkbox>
</div> </div> -->
<div> <div>
<mat-form-field *ngIf="langauges"> <mat-form-field *ngIf="langauges">
<mat-select placeholder="Language" formControlName="defaultLanguageCode"> <mat-select matTooltip="This is the default site language for search results, the user can override this in their preferences page" placeholder="Language" formControlName="defaultLanguageCode">
<mat-option>--</mat-option> <mat-option>--</mat-option>
<mat-option *ngFor="let lang of langauges" [value]="lang.code"> <mat-option *ngFor="let lang of langauges" [value]="lang.code">
{{lang.nativeName}} {{lang.nativeName}}

View file

@ -5,7 +5,7 @@ import { ILanguageRefine, IOmbiSettings } from "../../interfaces";
import { NotificationService } from "../../services"; import { NotificationService } from "../../services";
import { SettingsService } from "../../services"; import { SettingsService } from "../../services";
import * as languageData from "../../../other/iso-lang.json"; import languageData from "./../../../other/iso-lang.json";
@Component({ @Component({
templateUrl: "./ombi.component.html", templateUrl: "./ombi.component.html",
@ -33,7 +33,8 @@ export class OmbiComponent implements OnInit {
disableHealthChecks: [x.disableHealthChecks] disableHealthChecks: [x.disableHealthChecks]
}); });
}); });
this.langauges = <ILanguageRefine[]><any>languageData; debugger;
this.langauges = <ILanguageRefine[]>languageData
} }
public refreshApiKey() { public refreshApiKey() {

View file

@ -1,25 +1,27 @@
{ {
"compileOnSave": false, "compileOnSave": false,
"compilerOptions": { "compilerOptions": {
"baseUrl": "./", "baseUrl": "./",
"module": "esnext", "module": "esnext",
"outDir": "./dist/out-tsc", "outDir": "./dist/out-tsc",
"sourceMap": true, "sourceMap": true,
"declaration": false, "declaration": false,
"moduleResolution": "node", "moduleResolution": "node",
"emitDecoratorMetadata": true, "emitDecoratorMetadata": true,
"experimentalDecorators": true, "experimentalDecorators": true,
"target": "es5", "target": "es5",
"types": ["node"], "types": ["node"],
"resolveJsonModule":true, "resolveJsonModule":true,
"typeRoots": [ "allowSyntheticDefaultImports":true,
"node_modules/@types" "typeRoots": [
], "node_modules/@types"
"lib": [ ],
"es2017", "lib": [
"dom" "es2017",
] "dom"
} , ]
}
,
"files": [ "files": [
"main.ts", "main.ts",
"polyfills.ts" "polyfills.ts"
@ -27,4 +29,4 @@
"include": [ "include": [
"src/**/*.d.ts" "src/**/*.d.ts"
] ]
} }