mirror of
https://github.com/DSpace/dspace-angular.git
synced 2025-10-07 01:54:15 +00:00
[Port dspace-7_x] Clean up spacing in input forms
Manual port of #4136 by @gingyx to DSpace 7.x.
This commit is contained in:
@@ -1,4 +1,4 @@
|
|||||||
<div [class.form-group]="(model.type !== 'GROUP' && asBootstrapFormGroup) || getClass('element', 'container').includes('form-group')"
|
<div [class.form-group]="hasLabel || model.type === 'DATE' || (model.type !== 'GROUP' && asBootstrapFormGroup) || getClass('element', 'container').includes('form-group')"
|
||||||
[class.d-none]="model.hidden"
|
[class.d-none]="model.hidden"
|
||||||
[formGroup]="group"
|
[formGroup]="group"
|
||||||
[ngClass]="[getClass('element', 'container'), getClass('grid', 'container')]">
|
[ngClass]="[getClass('element', 'container'), getClass('grid', 'container')]">
|
||||||
@@ -19,8 +19,7 @@
|
|||||||
<small *ngIf="hasHint && (formBuilderService.hasArrayGroupValue(model) || (!model.repeatable && (isRelationship === false || value?.value === null)) || (model.repeatable === true && context?.index === context?.context?.groups?.length - 1)) && (!showErrorMessages || errorMessages.length === 0)"
|
<small *ngIf="hasHint && (formBuilderService.hasArrayGroupValue(model) || (!model.repeatable && (isRelationship === false || value?.value === null)) || (model.repeatable === true && context?.index === context?.context?.groups?.length - 1)) && (!showErrorMessages || errorMessages.length === 0)"
|
||||||
class="text-muted ds-hint" [innerHTML]="model.hint | translate" [ngClass]="getClass('element', 'hint')"></small>
|
class="text-muted ds-hint" [innerHTML]="model.hint | translate" [ngClass]="getClass('element', 'hint')"></small>
|
||||||
<!-- In case of repeatable fields show empty space for all elements except the first -->
|
<!-- In case of repeatable fields show empty space for all elements except the first -->
|
||||||
<div *ngIf="context?.index !== null
|
<div *ngIf="context?.parent?.groups?.length > 1 && (!showErrorMessages || errorMessages.length === 0)" class="clearfix w-100 mb-2"></div>
|
||||||
&& (!showErrorMessages || errorMessages.length === 0)" class="clearfix w-100 mb-2"></div>
|
|
||||||
|
|
||||||
<div *ngIf="!model.hideErrorMessages && showErrorMessages" [id]="id + '_errors'"
|
<div *ngIf="!model.hideErrorMessages && showErrorMessages" [id]="id + '_errors'"
|
||||||
[ngClass]="[getClass('element', 'errors'), getClass('grid', 'errors')]">
|
[ngClass]="[getClass('element', 'errors'), getClass('grid', 'errors')]">
|
||||||
@@ -78,7 +77,7 @@
|
|||||||
</ds-existing-relation-list-element>
|
</ds-existing-relation-list-element>
|
||||||
<small *ngIf="hasHint && (model.repeatable === false || context?.index === context?.context?.groups?.length - 1) && (!showErrorMessages || errorMessages.length === 0)"
|
<small *ngIf="hasHint && (model.repeatable === false || context?.index === context?.context?.groups?.length - 1) && (!showErrorMessages || errorMessages.length === 0)"
|
||||||
class="text-muted ds-hint" [innerHTML]="model.hint | translate" [ngClass]="getClass('element', 'hint')"></small>
|
class="text-muted ds-hint" [innerHTML]="model.hint | translate" [ngClass]="getClass('element', 'hint')"></small>
|
||||||
<div class="clearfix w-100 mb-2"></div>
|
<div *ngIf="context?.parent?.groups?.length > 1 && (!showErrorMessages || errorMessages.length === 0)" class="clearfix w-100 mb-2"></div>
|
||||||
</ng-container>
|
</ng-container>
|
||||||
<ng-content></ng-content>
|
<ng-content></ng-content>
|
||||||
</div>
|
</div>
|
||||||
|
@@ -14,3 +14,13 @@
|
|||||||
-moz-appearance: none;
|
-moz-appearance: none;
|
||||||
appearance: none;
|
appearance: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.invalid-feedback {
|
||||||
|
margin-top: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.col-form-label {
|
||||||
|
padding-top: 0;
|
||||||
|
padding-bottom: 0;
|
||||||
|
margin-bottom: 0.5rem;
|
||||||
|
}
|
||||||
|
@@ -1,5 +1,5 @@
|
|||||||
<div class="d-flex">
|
<div class="d-flex">
|
||||||
<span class="mr-auto text-contents">
|
<span class="mr-auto text-contents align-self-center">
|
||||||
<ng-container *ngIf="!(metadataRepresentation$ | async)">
|
<ng-container *ngIf="!(metadataRepresentation$ | async)">
|
||||||
<ds-themed-loading [showMessage]="false"></ds-themed-loading>
|
<ds-themed-loading [showMessage]="false"></ds-themed-loading>
|
||||||
</ng-container>
|
</ng-container>
|
||||||
|
@@ -4,4 +4,5 @@
|
|||||||
|
|
||||||
legend {
|
legend {
|
||||||
font-size: initial;
|
font-size: initial;
|
||||||
|
margin-bottom: 0;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user