2017-07-15 22:31:43 +08:00
|
|
|
<form #settingsForm="ngForm" class="form-horizontal">
|
2018-05-14 04:59:57 +08:00
|
|
|
<div class="card mb-4">
|
|
|
|
<h5 class="card-header" i18n>
|
|
|
|
Other settings
|
|
|
|
</h5>
|
|
|
|
<div class="card-body">
|
2017-12-25 07:42:25 +08:00
|
|
|
<div [hidden]="!error" class="alert alert-danger" role="alert"><strong i18n>Error: </strong>{{error}}</div>
|
2017-07-15 22:31:43 +08:00
|
|
|
|
|
|
|
|
2018-05-14 04:59:57 +08:00
|
|
|
<div class="form-group row">
|
|
|
|
<label class="col-md-2 control-label" for="enableThreading" i18n>Threading</label>
|
|
|
|
<div class="col-md-10">
|
2017-07-15 22:31:43 +08:00
|
|
|
<bSwitch
|
|
|
|
id="enableThreading"
|
|
|
|
class="switch"
|
|
|
|
name="enableThreading"
|
|
|
|
[switch-on-color]="'primary'"
|
|
|
|
[switch-inverse]="'inverse'"
|
2018-03-30 08:30:23 +08:00
|
|
|
[switch-off-text]="text.Disabled"
|
|
|
|
[switch-on-text]="text.Enabled"
|
2017-07-15 22:31:43 +08:00
|
|
|
[switch-handle-width]="'100'"
|
|
|
|
[switch-label-width]="'20'"
|
2017-07-15 23:29:40 +08:00
|
|
|
[(ngModel)]="settings.enableThreading">
|
2017-07-15 22:31:43 +08:00
|
|
|
</bSwitch>
|
2018-05-14 04:59:57 +08:00
|
|
|
<small class="form-text text-muted" i18n>Runs directory scanning and thumbnail generation (only for Jimp) in a
|
|
|
|
different thread
|
|
|
|
</small>
|
2017-07-15 22:31:43 +08:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
2018-05-14 04:59:57 +08:00
|
|
|
<div class="form-group row">
|
|
|
|
<label class="col-md-2 control-label" for="enableOnScrollThumbnailPrioritising" i18n>Scroll based thumbnail
|
2017-07-15 22:31:43 +08:00
|
|
|
generation</label>
|
2018-05-14 04:59:57 +08:00
|
|
|
<div class="col-md-10">
|
2017-07-15 22:31:43 +08:00
|
|
|
<bSwitch
|
|
|
|
id="enableOnScrollThumbnailPrioritising"
|
|
|
|
class="switch"
|
|
|
|
name="enableOnScrollThumbnailPrioritising"
|
|
|
|
[switch-on-color]="'primary'"
|
|
|
|
[switch-inverse]="'inverse'"
|
2018-03-30 08:30:23 +08:00
|
|
|
[switch-off-text]="text.Disabled"
|
|
|
|
[switch-on-text]="text.Enabled"
|
2017-07-15 22:31:43 +08:00
|
|
|
[switch-handle-width]="'100'"
|
|
|
|
[switch-label-width]="'20'"
|
2017-07-15 23:29:40 +08:00
|
|
|
[(ngModel)]="settings.enableOnScrollThumbnailPrioritising">
|
2017-07-15 22:31:43 +08:00
|
|
|
</bSwitch>
|
2018-05-14 04:59:57 +08:00
|
|
|
<small class="form-text text-muted" i18n>Those thumbnails get higher priority that are visible on the screen
|
|
|
|
</small>
|
2017-07-15 22:31:43 +08:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
2018-05-14 04:59:57 +08:00
|
|
|
<div class="form-group row">
|
|
|
|
<label class="col-md-2 control-label" for="enableOnScrollRendering" i18n>Lazy image rendering</label>
|
|
|
|
<div class="col-md-10">
|
2017-07-15 22:31:43 +08:00
|
|
|
<bSwitch
|
|
|
|
id="enableOnScrollRendering"
|
|
|
|
class="switch"
|
|
|
|
name="enableOnScrollRendering"
|
|
|
|
[switch-on-color]="'primary'"
|
|
|
|
[switch-inverse]="'inverse'"
|
2018-03-30 08:30:23 +08:00
|
|
|
[switch-off-text]="text.Disabled"
|
|
|
|
[switch-on-text]="text.Enabled"
|
2017-07-15 22:31:43 +08:00
|
|
|
[switch-handle-width]="'100'"
|
|
|
|
[switch-label-width]="'20'"
|
2017-07-15 23:29:40 +08:00
|
|
|
[(ngModel)]="settings.enableOnScrollRendering">
|
2017-07-15 22:31:43 +08:00
|
|
|
</bSwitch>
|
2018-05-14 04:59:57 +08:00
|
|
|
<small class="form-text text-muted" i18n>Shows only the required amount of photos at once. Renders more if
|
|
|
|
page bottom is reached
|
|
|
|
</small>
|
2017-07-15 22:31:43 +08:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
2018-05-14 04:59:57 +08:00
|
|
|
<div class="form-group row">
|
|
|
|
<label class="col-md-2 control-label" for="enableCache" i18n>Cache</label>
|
|
|
|
<div class="col-md-10">
|
2017-07-15 22:31:43 +08:00
|
|
|
<bSwitch
|
|
|
|
id="enableCache"
|
|
|
|
class="switch"
|
|
|
|
name="enableCache"
|
|
|
|
[switch-on-color]="'primary'"
|
|
|
|
[switch-inverse]="'inverse'"
|
2018-03-30 08:30:23 +08:00
|
|
|
[switch-off-text]="text.Disabled"
|
|
|
|
[switch-on-text]="text.Enabled"
|
2017-07-15 22:31:43 +08:00
|
|
|
[switch-handle-width]="'100'"
|
|
|
|
[switch-label-width]="'20'"
|
2017-07-15 23:29:40 +08:00
|
|
|
[(ngModel)]="settings.enableCache">
|
2017-07-15 22:31:43 +08:00
|
|
|
</bSwitch>
|
2018-05-14 04:59:57 +08:00
|
|
|
<small class="form-text text-muted" i18n>Caches directory contents and search results for better performance
|
|
|
|
</small>
|
2017-07-15 22:31:43 +08:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
2018-05-29 02:03:12 +08:00
|
|
|
<div class="form-group row" [hidden]="simplifiedMode">
|
|
|
|
<label class="col-md-2 control-label" for="defaultPhotoSortingMethod" i18n>Default photo sorting method</label>
|
|
|
|
<div class="col-md-10">
|
|
|
|
<select id="defaultPhotoSortingMethod" class="form-control" [(ngModel)]="settings.defaultPhotoSortingMethod"
|
|
|
|
name="defaultPhotoSortingMethod" required>
|
|
|
|
<option *ngFor="let type of types" [ngValue]="type.key">{{type.key | stringifySorting}}
|
|
|
|
</option>
|
|
|
|
</select>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
2018-05-14 04:59:57 +08:00
|
|
|
<button class="btn btn-success float-right"
|
2017-07-15 22:31:43 +08:00
|
|
|
[disabled]="!settingsForm.form.valid || !changed || inProgress"
|
2017-12-25 07:42:25 +08:00
|
|
|
(click)="save()" i18n>Save
|
2017-07-15 22:31:43 +08:00
|
|
|
</button>
|
2018-05-14 04:59:57 +08:00
|
|
|
<button class="btn btn-default float-right"
|
2017-12-25 07:42:25 +08:00
|
|
|
(click)="reset()" i18n>Reset
|
2017-07-15 22:31:43 +08:00
|
|
|
</button>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
</form>
|