Swagger, Tachiyomi, and some new settings (#1331)
* Fixed up swagger generation * Updated Tachiyomi's latest-chapter to hopefully solve some sync issues. * Fixed #1279 with table of contents due to new EPubReader * When errors occur, show the event widget icon in red * Lots of documentation added and tweaked some wording around backups and swagger * For promidius * Return proper ChapterDTO * Hacks for Promidius * Cleanup code * No loose leaf, send max chapter * One more encode change * Implemented code per promiduius' requirements * Fixed a bug in the epub parsing where even if you had a series index and series group, but didn't have the series in the title, Kavita wouldn't group them properly. * Removed some extra comment * Implemented the ability to change a library's type after it's been setup. This displays a warning explaining the dangers of it. * Removed some whitespace * Blur descriptions based on read status for list item view to avoid spoilers * Tweaked placement of a tooltip due to new series detail styles * Hooked up a user preference for bluring unread summaries. Fixed a bug in refresh token where we would cause re-authentication when it shouldn't be needed.
This commit is contained in:
parent
f2c08092b8
commit
2ab0aedd22
36 changed files with 1851 additions and 72 deletions
|
|
@ -19,7 +19,7 @@
|
|||
<label for="library-type" class="form-label">Type</label> <i class="fa fa-info-circle" placement="right" [ngbTooltip]="typeTooltip" role="button" tabindex="0"></i>
|
||||
<ng-template #typeTooltip>Library type determines how filenames are parsed and if the UI shows Chapters (Manga) vs Issues (Comics). Book work the same way as Manga but fall back to embedded data.</ng-template>
|
||||
<span class="visually-hidden" id="library-type-help">Library type determines how filenames are parsed and if the UI shows Chapters (Manga) vs Issues (Comics). Book work the same way as Manga but fall back to embedded data.</span>
|
||||
<select class="form-select" id="library-type" formControlName="type" [attr.disabled]="this.library" aria-describedby="library-type-help">
|
||||
<select class="form-select" id="library-type" formControlName="type" aria-describedby="library-type-help"> <!-- [attr.disabled]="this.library" -->
|
||||
<option [value]="i" *ngFor="let opt of libraryTypes; let i = index">{{opt}}</option>
|
||||
</select>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -2,6 +2,7 @@ import { Component, Input, OnInit } from '@angular/core';
|
|||
import { FormControl, FormGroup, Validators } from '@angular/forms';
|
||||
import { NgbActiveModal, NgbModal } from '@ng-bootstrap/ng-bootstrap';
|
||||
import { ToastrService } from 'ngx-toastr';
|
||||
import { ConfirmService } from 'src/app/shared/confirm.service';
|
||||
import { Library } from 'src/app/_models/library';
|
||||
import { LibraryService } from 'src/app/_services/library.service';
|
||||
import { SettingsService } from '../../settings.service';
|
||||
|
|
@ -28,7 +29,7 @@ export class LibraryEditorModalComponent implements OnInit {
|
|||
|
||||
|
||||
constructor(private modalService: NgbModal, private libraryService: LibraryService, public modal: NgbActiveModal, private settingService: SettingsService,
|
||||
private toastr: ToastrService) { }
|
||||
private toastr: ToastrService, private confirmService: ConfirmService) { }
|
||||
|
||||
ngOnInit(): void {
|
||||
|
||||
|
|
@ -45,7 +46,7 @@ export class LibraryEditorModalComponent implements OnInit {
|
|||
this.madeChanges = true;
|
||||
}
|
||||
|
||||
submitLibrary() {
|
||||
async submitLibrary() {
|
||||
const model = this.libraryForm.value;
|
||||
model.folders = this.selectedFolders;
|
||||
|
||||
|
|
@ -57,6 +58,12 @@ export class LibraryEditorModalComponent implements OnInit {
|
|||
model.id = this.library.id;
|
||||
model.folders = model.folders.map((item: string) => item.startsWith('\\') ? item.substr(1, item.length) : item);
|
||||
model.type = parseInt(model.type, 10);
|
||||
|
||||
if (model.type !== this.library.type) {
|
||||
if (!await this.confirmService.confirm(`Changing library type will trigger a new scan with different parsing rules and may lead to
|
||||
series being re-created and hence you may loose progress and bookmarks. You should backup before you do this. Are you sure you want to continue?`)) return;
|
||||
}
|
||||
|
||||
this.libraryService.update(model).subscribe(() => {
|
||||
this.close(true);
|
||||
}, err => {
|
||||
|
|
|
|||
|
|
@ -29,7 +29,7 @@
|
|||
</div>
|
||||
|
||||
<div class="col-md-4 col-sm-12 pe-2">
|
||||
<label for="backup-tasks" class="form-label">Backup Tasks</label> <i class="fa fa-info-circle" placement="right" [ngbTooltip]="backupTasksTooltip" role="button" tabindex="0"></i>
|
||||
<label for="backup-tasks" class="form-label">Days of Backups</label> <i class="fa fa-info-circle" placement="right" [ngbTooltip]="backupTasksTooltip" role="button" tabindex="0"></i>
|
||||
<ng-template #backupTasksTooltip>The number of backups to maintain. Default is 30, minumum is 1, maximum is 30.</ng-template>
|
||||
<span class="visually-hidden" id="backup-tasks-help">The number of backups to maintain. Default is 30, minumum is 1, maximum is 30.</span>
|
||||
<input id="backup-tasks" aria-describedby="backup-tasks-help" class="form-control" formControlName="totalBackups" type="number" step="1" min="1" max="30" onkeypress="return event.charCode >= 48 && event.charCode <= 57">
|
||||
|
|
@ -67,7 +67,7 @@
|
|||
|
||||
<div class="mb-3">
|
||||
<label for="swagger-ui" class="form-label" aria-describedby="swaggerui-info">Expose Swagger UI</label>
|
||||
<p class="accent" id="swaggerui-info">Allows Swagger UI to be exposed via swagger/ on your server. Authentication is not required, but a valid JWT token is. Requires a restart to take effect.</p>
|
||||
<p class="accent" id="swaggerui-info">Allows Swagger UI to be exposed via swagger/ on your server. Authentication is not required, but a valid JWT token is. Requires a restart to take effect. Swagger is hosted on yourip:5000/swagger</p>
|
||||
<div class="form-check form-switch">
|
||||
<input id="swagger-ui" type="checkbox" class="form-check-input" formControlName="enableSwaggerUi" role="switch">
|
||||
<label for="swagger-ui" class="form-check-label">Enable Swagger UI</label>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue