diff --git a/dmp-frontend/src/app/app.component.scss b/dmp-frontend/src/app/app.component.scss index ddc6df33c..26f07d9f5 100644 --- a/dmp-frontend/src/app/app.component.scss +++ b/dmp-frontend/src/app/app.component.scss @@ -21,7 +21,7 @@ display: flex; align-items: center; justify-content: center; - width: 260px; + width: 270px; background: #ffffff 0% 0% no-repeat padding-box; box-shadow: 0px 0px 16px 2px #00000029; border-right-width: 0px; diff --git a/dmp-frontend/src/app/ui/dmp/invitation/dialog/dmp-invitation-dialog.component.html b/dmp-frontend/src/app/ui/dmp/invitation/dialog/dmp-invitation-dialog.component.html index 8dcfc23ab..475d3e46b 100644 --- a/dmp-frontend/src/app/ui/dmp/invitation/dialog/dmp-invitation-dialog.component.html +++ b/dmp-frontend/src/app/ui/dmp/invitation/dialog/dmp-invitation-dialog.component.html @@ -7,9 +7,9 @@ close -
+
- +
diff --git a/dmp-frontend/src/app/ui/dmp/user-field/user-field.component.html b/dmp-frontend/src/app/ui/dmp/user-field/user-field.component.html index eb2f1d7ab..8da4e4d27 100644 --- a/dmp-frontend/src/app/ui/dmp/user-field/user-field.component.html +++ b/dmp-frontend/src/app/ui/dmp/user-field/user-field.component.html @@ -1,9 +1,26 @@ -
-
-
+
+ hello! + +
+ + + + + +
+
+ +
+
+ + +
+
{{userIndex + 1}}
-
drag_indicator
+
drag_indicator
@@ -11,47 +28,43 @@
-
-
-
- - {{'DMP-EDITOR.FIELDS1.USER' | translate}}* - - {{user.get('user').getError('backendError').message}} - {{'GENERAL.VALIDATION.REQUIRED' | translate}} - -
-
- - {{'DMP-EDITOR.FIELDS1.EMAIL' | translate}}* - - {{user.get('email').getError('backendError').message}} - {{'GENERAL.VALIDATION.REQUIRED' | translate}} - -
-
- - {{'DMP-EDITOR.FIELDS1.USER-ROLE' | translate}} - - {{enumUtils.toDmpUserRoleString(userRole)}} - - {{user.get('role').getError('backendError').message}} - {{'GENERAL.VALIDATION.REQUIRED' | translate}} - -
-
- - {{'DMP-EDITOR.FIELDS1.SECTION' | translate}} - - - {{ section.label }} - - - {{user.get('sectionId').getError('backendError').message}} - {{'GENERAL.VALIDATION.REQUIRED' |translate}} - -
-
+
+ + {{'DMP-EDITOR.FIELDS1.USER' | translate}}* + + {{user.get('user').getError('backendError').message}} + {{'GENERAL.VALIDATION.REQUIRED' | translate}} + +
+
+ + {{'DMP-EDITOR.FIELDS1.EMAIL' | translate}}* + + {{user.get('email').getError('backendError').message}} + {{'GENERAL.VALIDATION.REQUIRED' | translate}} + +
+
+ + {{'DMP-EDITOR.FIELDS1.USER-ROLE' | translate}} + + {{enumUtils.toDmpUserRoleString(userRole)}} + + {{user.get('role').getError('backendError').message}} + {{'GENERAL.VALIDATION.REQUIRED' | translate}} + +
+
+ + {{'DMP-EDITOR.FIELDS1.SECTION' | translate}} + + + {{ section.label }} + + + {{user.get('sectionId').getError('backendError').message}} + {{'GENERAL.VALIDATION.REQUIRED' |translate}} +
+ {{'DMP-EDITOR.USERS-REQUIRED' | translate}} {{form.get('users').getError('backendError').message}} -
-
-
- -
-
\ No newline at end of file +
diff --git a/dmp-frontend/src/app/ui/dmp/user-field/user-field.component.scss b/dmp-frontend/src/app/ui/dmp/user-field/user-field.component.scss index dbaf6e932..8274928d1 100644 --- a/dmp-frontend/src/app/ui/dmp/user-field/user-field.component.scss +++ b/dmp-frontend/src/app/ui/dmp/user-field/user-field.component.scss @@ -6,4 +6,15 @@ .drag-handle-disabled { cursor: auto; color: rgba(0, 0, 0, 0.38);; -} \ No newline at end of file +} + +.user-fields-wrapper { + display: flex; + flex-direction: row; + justify-content: space-around; + align-items: baseline; + + @media (width <= 1350px) { + flex-direction: column; + } +} diff --git a/dmp-frontend/src/app/ui/dmp/user-field/user-field.component.ts b/dmp-frontend/src/app/ui/dmp/user-field/user-field.component.ts index 1bd5b72f6..0df0b0e9b 100644 --- a/dmp-frontend/src/app/ui/dmp/user-field/user-field.component.ts +++ b/dmp-frontend/src/app/ui/dmp/user-field/user-field.component.ts @@ -24,6 +24,8 @@ export class UserFieldComponent extends BaseComponent implements OnInit { @Input() required: boolean = false; @Input() placeholder: string; @Input() sections: DmpBlueprintDefinitionSection[] = null; + @Input() initializeUsers: boolean = false; + @Input() enableSorting: boolean = true; dmpUserTypeEnum = DmpUserType; dmpUserTypeEnumValues = this.enumUtils.getEnumValues(DmpUserType); @@ -37,6 +39,10 @@ export class UserFieldComponent extends BaseComponent implements OnInit { ) { super(); } ngOnInit() { + console.log('sorting mode: ', this.enableSorting); + if(this.initializeUsers) { + this.addUser(); + } } addUser(): void {