mirror of
https://github.com/xuthus83/pigallery2.git
synced 2024-11-03 21:04:03 +08:00
Merge branch 'bpatrik:master' into gpx_wpt_mappoints
This commit is contained in:
commit
55c0e98df8
@ -59,8 +59,8 @@ export class ClientSharingConfig {
|
|||||||
|
|
||||||
@SubConfigClass()
|
@SubConfigClass()
|
||||||
export class ClientRandomPhotoConfig {
|
export class ClientRandomPhotoConfig {
|
||||||
@ConfigProperty({description: 'Enables random link generation. NOTE: With the current implementation, it poses a security risk. See https://github.com/bpatrik/pigallery2/issues/392'})
|
@ConfigProperty({description: 'Enables random link generation.'})
|
||||||
enabled: boolean = false;
|
enabled: boolean = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
@SubConfigClass()
|
@SubConfigClass()
|
||||||
|
@ -15,7 +15,7 @@ export class LanguageComponent {
|
|||||||
current: string = null;
|
current: string = null;
|
||||||
|
|
||||||
constructor(private cookieService: CookieService) {
|
constructor(private cookieService: CookieService) {
|
||||||
this.languages = Config.Client.languages;
|
this.languages = Config.Client.languages.sort();
|
||||||
if (this.cookieService.get(CookieNames.lang) != null) {
|
if (this.cookieService.get(CookieNames.lang) != null) {
|
||||||
this.current = this.cookieService.get(CookieNames.lang);
|
this.current = this.cookieService.get(CookieNames.lang);
|
||||||
}
|
}
|
||||||
|
@ -8,6 +8,7 @@
|
|||||||
|
|
||||||
<app-settings-entry
|
<app-settings-entry
|
||||||
name="Type"
|
name="Type"
|
||||||
|
[optionMap]="dbTypesMap"
|
||||||
[ngModel]="states.type"
|
[ngModel]="states.type"
|
||||||
i18n-name
|
i18n-name
|
||||||
required="true">
|
required="true">
|
||||||
|
@ -31,6 +31,14 @@ export class DatabaseSettingsComponent extends SettingsComponentDirective<Server
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
dbTypesMap = (v: { key: number, value: string }) => {
|
||||||
|
if (v.key === DatabaseType.sqlite) {
|
||||||
|
v.value += ' ' + $localize`(recommended)`;
|
||||||
|
} else if (v.value === DatabaseType[DatabaseType.memory]) {
|
||||||
|
v.value += ' ' + $localize`(deprecated, will be removed)`;
|
||||||
|
}
|
||||||
|
return v;
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -48,14 +48,6 @@ export class PhotoSettingsComponent extends SettingsComponentDirective<{
|
|||||||
return this.jobsService.progress.value[JobDTOUtils.getHashName(DefaultsJobs[DefaultsJobs['Photo Converting']])];
|
return this.jobsService.progress.value[JobDTOUtils.getHashName(DefaultsJobs[DefaultsJobs['Photo Converting']])];
|
||||||
}
|
}
|
||||||
|
|
||||||
libTypesMap = (v: { key: number, value: string }) => {
|
|
||||||
if (v.value.toLowerCase() === 'sharp') {
|
|
||||||
v.value += ' ' + $localize`(recommended)`;
|
|
||||||
} else {
|
|
||||||
v.value += ' ' + $localize`(deprecated, will be removed)`;
|
|
||||||
}
|
|
||||||
return v;
|
|
||||||
};
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -33,7 +33,7 @@
|
|||||||
</ng-container>
|
</ng-container>
|
||||||
<br/>
|
<br/>
|
||||||
<ng-container i18n>
|
<ng-container i18n>
|
||||||
Note: With the current implementation, it poses a security risk. See:
|
Note: With the current implementation, random link also requires login. See:
|
||||||
</ng-container>
|
</ng-container>
|
||||||
<a href="https://github.com/bpatrik/pigallery2/issues/392">#392</a>
|
<a href="https://github.com/bpatrik/pigallery2/issues/392">#392</a>
|
||||||
</div>
|
</div>
|
||||||
|
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue
Block a user