mirror of
https://github.com/bpatrik/pigallery2.git
synced 2024-12-16 11:37:13 +02:00
52 lines
1.8 KiB
HTML
52 lines
1.8 KiB
HTML
<form #settingsForm="ngForm" class="form-horizontal">
|
|
<div class="card mb-4">
|
|
<h5 class="card-header">
|
|
<ng-container i18n>Map settings</ng-container>
|
|
<div class="switch-wrapper">
|
|
<bSwitch
|
|
class="switch"
|
|
name="enabled"
|
|
[switch-on-color]="'success'"
|
|
[switch-inverse]="'inverse'"
|
|
[switch-off-text]="text.Disabled"
|
|
[switch-on-text]="text.Enabled"
|
|
[switch-disabled]="inProgress"
|
|
[switch-handle-width]="'100'"
|
|
[switch-label-width]="'20'"
|
|
[(ngModel)]="settings.enabled">
|
|
</bSwitch>
|
|
</div>
|
|
</h5>
|
|
<div class="card-body">
|
|
<div [hidden]="!error" class="alert alert-danger" role="alert"><strong>Error: </strong>{{error}}</div>
|
|
|
|
|
|
<div class="form-group row">
|
|
<label class="col-md-2 control-label" for="googleApiKey" i18n>Google maps api key</label>
|
|
<div class="col-md-10">
|
|
<input type="text" class="form-control" placeholder="Google api key"
|
|
[(ngModel)]="settings.googleApiKey"
|
|
[disabled]="!settings.enabled"
|
|
name="googleApiKey" id="googleApiKey" required>
|
|
<small class="form-text text-muted">
|
|
<ng-container i18n>To show the images on a map,</ng-container>
|
|
<a
|
|
href="https://developers.google.com/maps/documentation/javascript/get-api-key" i18n>google api key</a> <ng-container
|
|
i18n>is need
|
|
</ng-container>
|
|
</small>
|
|
</div>
|
|
</div>
|
|
|
|
<button class="btn btn-success float-right"
|
|
[disabled]="!settingsForm.form.valid || !changed || inProgress"
|
|
(click)="save()" i18n>Save
|
|
</button>
|
|
<button class="btn btn-default float-right"
|
|
(click)="reset()" i18n>Reset
|
|
</button>
|
|
</div>
|
|
</div>
|
|
|
|
</form>
|