diff --git a/apps/red-ui/src/app/modules/dossier-overview/components/table-item/file-attribute/file-attribute.component.html b/apps/red-ui/src/app/modules/dossier-overview/components/table-item/file-attribute/file-attribute.component.html
index cbe8c5324..69898c796 100644
--- a/apps/red-ui/src/app/modules/dossier-overview/components/table-item/file-attribute/file-attribute.component.html
+++ b/apps/red-ui/src/app/modules/dossier-overview/components/table-item/file-attribute/file-attribute.component.html
@@ -3,8 +3,9 @@
{{ fileAttributeValue ? (fileAttributeValue | date : 'd MMM yyyy') : '-' }}
-
-
+
+
+
diff --git a/apps/red-ui/src/app/modules/dossier-overview/components/table-item/file-attribute/file-attribute.component.scss b/apps/red-ui/src/app/modules/dossier-overview/components/table-item/file-attribute/file-attribute.component.scss
index f713d58ce..f9755ac60 100644
--- a/apps/red-ui/src/app/modules/dossier-overview/components/table-item/file-attribute/file-attribute.component.scss
+++ b/apps/red-ui/src/app/modules/dossier-overview/components/table-item/file-attribute/file-attribute.component.scss
@@ -5,52 +5,18 @@
align-items: center;
.edit-button {
- transform: translate(-25%);
- background: radial-gradient(var(--iqser-side-nav) 10%, rgba(244, 245, 247, 0) 60%);
-
- #edit-attribute-button {
- position: absolute;
- top: 50%;
- transform: translate(-50%, -50%);
- left: 50%;
- }
- }
-
- .edit-button,
- .edit {
position: absolute;
display: none;
- top: 0;
+ background: radial-gradient(var(--iqser-side-nav) 10%, rgba(244, 245, 247, 0) 60%);
height: 100%;
width: 150%;
- z-index: 1;
- }
-
- iqser-dynamic-input {
- margin-top: 0;
- }
-
- .edit {
- width: 300%;
- display: block;
-
- background: radial-gradient(var(--iqser-side-nav) 10%, rgba(244, 245, 247, 0) 95%);
-
- form {
- display: flex;
- gap: 5px;
- align-items: center;
- z-index: 10;
- width: 75%;
+ transform: translate(-25%);
+ iqser-circle-button {
position: absolute;
top: 50%;
- transform: translate(0%, -50%);
- }
-
- iqser-dynamic-input {
- width: 75%;
- margin-top: 0;
+ left: 50%;
+ transform: translate(-50%, -50%);
}
}
@@ -59,4 +25,28 @@
display: block;
}
}
+
+ .edit-input {
+ cursor: default;
+ display: flex;
+ z-index: 1;
+ border: solid var(--iqser-grey-4);
+ border-radius: 10px;
+ background: var(--iqser-background);
+ box-shadow: 0 2px 8px 0 rgba(0, 0, 0, 0.15);
+
+ form {
+ margin: 5px;
+ display: flex;
+ align-items: center;
+
+ iqser-dynamic-input {
+ margin-top: 0;
+ }
+
+ .save {
+ margin-left: 7px;
+ }
+ }
+ }
}
diff --git a/apps/red-ui/src/app/modules/dossier-overview/components/table-item/file-attribute/file-attribute.component.ts b/apps/red-ui/src/app/modules/dossier-overview/components/table-item/file-attribute/file-attribute.component.ts
index 983b37ba8..c22ab777c 100644
--- a/apps/red-ui/src/app/modules/dossier-overview/components/table-item/file-attribute/file-attribute.component.ts
+++ b/apps/red-ui/src/app/modules/dossier-overview/components/table-item/file-attribute/file-attribute.component.ts
@@ -1,4 +1,4 @@
-import { ChangeDetectionStrategy, Component, Input, OnInit } from '@angular/core';
+import { ChangeDetectionStrategy, Component, HostListener, Input, OnInit } from '@angular/core';
import { Dossier, File, FileAttributeConfigTypes, IFileAttributeConfig } from '@red/domain';
import { BaseFormComponent, ListingService, Toaster } from '@iqser/common-ui';
import { PermissionsService } from '@services/permissions.service';
@@ -24,6 +24,7 @@ export class FileAttributeComponent extends BaseFormComponent implements OnInit
@Input() dossier!: Dossier;
isInEditMode = false;
+ closedDatepicker = true;
readonly isEditingFileAttribute$: BehaviorSubject;
readonly selectedFile$: Observable;
@@ -139,4 +140,11 @@ export class FileAttributeComponent extends BaseFormComponent implements OnInit
input.focus();
}, 100);
}
+
+ @HostListener('document:click')
+ clickOutside() {
+ if (this.isInEditMode && this.closedDatepicker) {
+ this.close();
+ }
+ }
}
diff --git a/libs/common-ui b/libs/common-ui
index d9a92992c..cdfd0b59b 160000
--- a/libs/common-ui
+++ b/libs/common-ui
@@ -1 +1 @@
-Subproject commit d9a92992c3b6f4700fbbdb3662d981bfe23b979b
+Subproject commit cdfd0b59b4e1f63693366ac5c9e80d3c309d687d