From 7b094f694b5d08e528eedc66b5560e18e8f35bd6 Mon Sep 17 00:00:00 2001
From: Jan-Hendrik Willms <tleilax+github@gmail.com>
Date: Mon, 5 Aug 2024 16:10:12 +0200
Subject: [PATCH] adjustments according to gui feedback, re #696

---
 app/views/materialien/files/add_dokument.php |  4 +--
 resources/assets/stylesheets/scss/mvv.scss   | 27 ++++++++++++++++++++
 2 files changed, 29 insertions(+), 2 deletions(-)

diff --git a/app/views/materialien/files/add_dokument.php b/app/views/materialien/files/add_dokument.php
index db6c7c6f4a0..d0f12f6ba76 100644
--- a/app/views/materialien/files/add_dokument.php
+++ b/app/views/materialien/files/add_dokument.php
@@ -20,7 +20,7 @@
         </select>
     </label>
 
-    <table class="default">
+    <table class="default mvv-files-table">
     <? foreach($GLOBALS['MVV_LANGUAGES']['values'] as $key => $entry) : ?>
         <tr>
             <td rowspan="2">
@@ -89,7 +89,7 @@
                             <input type="hidden" name="document_id" id="document_id" value="<?= htmlReady($documents[$key]->fileref_id) ?>">
                             <span class="icon"><?= Icon::create('file', Icon::ROLE_INFO, ['class' => 'text-bottom']); ?></span>
                             <span class="name"><?= htmlReady($documents[$key]->filename) ?></span>
-                            <span class="size"></span>
+                            <span class="size"><?= relsize($documents[$key]->file_ref->size) ?></span>
                             <button class="refresh_attachment as-link" data-language="<?= htmlReady($key) ?>">
                                 <?= Icon::create('refresh')->asImg([
                                     'class' => 'text-bottom',
diff --git a/resources/assets/stylesheets/scss/mvv.scss b/resources/assets/stylesheets/scss/mvv.scss
index ce8570114f6..fef7505f932 100644
--- a/resources/assets/stylesheets/scss/mvv.scss
+++ b/resources/assets/stylesheets/scss/mvv.scss
@@ -634,3 +634,30 @@ form.default .mvv-inst-chooser select {
     vertical-align: text-top;
     text-decoration: none;
 }
+
+li.stgfile {
+    display: flex;
+    max-width: 48em;
+
+    .size {
+        margin-left: 0.5ex;
+        &::before {
+            content: ' (';
+        }
+        &::after {
+            content: ')';
+        }
+    }
+
+    button:first-of-type {
+        flex: 1;
+        margin-left: auto;
+        text-align: right;
+    }
+}
+
+.mvv-files-table {
+    &.default > tbody:last-of-type > tr:last-child td {
+        border-bottom-color: var(--table-header-color);
+    }
+}
-- 
GitLab