From 70c13b456d9e5e86fdeb39d5c1243fda4bc698e7 Mon Sep 17 00:00:00 2001
From: rhenck <richard.henck@iqb.hu-berlin.de>
Date: Wed, 15 Dec 2021 12:32:52 +0100
Subject: [PATCH] Fix fixed sized element positioning

Section was picking up the size of children elements. With relative it
works.
---
 projects/common/ui-elements/button/button.component.ts       | 2 +-
 projects/common/ui-elements/drop-list/drop-list.component.ts | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/projects/common/ui-elements/button/button.component.ts b/projects/common/ui-elements/button/button.component.ts
index 63f58619e..55816ce69 100644
--- a/projects/common/ui-elements/button/button.component.ts
+++ b/projects/common/ui-elements/button/button.component.ts
@@ -33,7 +33,7 @@ import { ButtonElement } from './button-element';
   styles: [
     '.dynamic-image {width: 100%; height: fit-content}',
     '.static-image {width: 100%; height: 100%; object-fit: contain}',
-    '.center-content {position: absolute; top: 0; bottom: 0; left: 0;right: 0; margin: auto;}'
+    '.center-content {position: relative; top: 0; bottom: 0; left: 0;right: 0; margin: auto;}'
   ]
 })
 export class ButtonComponent extends ElementComponent {
diff --git a/projects/common/ui-elements/drop-list/drop-list.component.ts b/projects/common/ui-elements/drop-list/drop-list.component.ts
index a231a945c..e8ac18124 100644
--- a/projects/common/ui-elements/drop-list/drop-list.component.ts
+++ b/projects/common/ui-elements/drop-list/drop-list.component.ts
@@ -87,7 +87,7 @@ import { DragNDropValueObject } from '../../models/uI-element';
     '.dropList-highlight.cdk-drop-list-dragging {border: solid;}',
 
     '.align-flex {flex: 1 1 auto; flex-flow: row wrap; display: flex; place-content: center space-around; gap: 10px}',
-    '.center-content {position: absolute; top: 0; bottom: 0; left: 0;right: 0; margin: auto;}'
+    '.center-content {position: relative; top: 0; bottom: 0; left: 0;right: 0; margin: auto;}'
   ]
 })
 export class DropListComponent extends FormElementComponent {
-- 
GitLab