From c1d3e4cd6e646b69819b1aa08bba617c1a6139bc Mon Sep 17 00:00:00 2001 From: "alonso.torres" Date: Fri, 22 Nov 2024 15:31:06 +0100 Subject: [PATCH] :bug: Fix problem with scroll in history versions --- frontend/src/app/main/ui/workspace/sidebar.cljs | 14 +++++--------- frontend/src/app/main/ui/workspace/sidebar.scss | 1 + .../app/main/ui/workspace/sidebar/versions.scss | 6 ++++++ frontend/translations/en.po | 6 ++++++ frontend/translations/es.po | 6 ++++++ 5 files changed, 24 insertions(+), 9 deletions(-) diff --git a/frontend/src/app/main/ui/workspace/sidebar.cljs b/frontend/src/app/main/ui/workspace/sidebar.cljs index 6886108a0a..cc9a9c5504 100644 --- a/frontend/src/app/main/ui/workspace/sidebar.cljs +++ b/frontend/src/app/main/ui/workspace/sidebar.cljs @@ -237,15 +237,11 @@ [:& comments-sidebar] (true? is-history?) - [:> tab-switcher* {:tabs #js [#js {:label "History" :id "history" :content versions-tab} - #js {:label "Actions" :id "actions" :content history-tab}] - :default-selected "history" - ;;:selected (name section) - ;;:on-change-tab on-tab-change - :class (stl/css :left-sidebar-tabs) - ;;:action-button-position "start" - ;;:action-button (mf/html [:& collapse-button {:on-click handle-collapse}]) - }] + [:> tab-switcher* + {:tabs #js [#js {:label (tr "workspace.versions.tab.history") :id "history" :content versions-tab} + #js {:label (tr "workspace.versions.tab.actions") :id "actions" :content history-tab}] + :default-selected "history" + :class (stl/css :left-sidebar-tabs)}] :else [:> options-toolbox props])]]])) diff --git a/frontend/src/app/main/ui/workspace/sidebar.scss b/frontend/src/app/main/ui/workspace/sidebar.scss index 64ca985a40..d4d606d123 100644 --- a/frontend/src/app/main/ui/workspace/sidebar.scss +++ b/frontend/src/app/main/ui/workspace/sidebar.scss @@ -113,4 +113,5 @@ $width-settings-bar-max: $s-500; .versions-tab { width: 100%; overflow: hidden; + height: calc(100vh - $s-88); } diff --git a/frontend/src/app/main/ui/workspace/sidebar/versions.scss b/frontend/src/app/main/ui/workspace/sidebar/versions.scss index 703f8d3be4..a924ae31d9 100644 --- a/frontend/src/app/main/ui/workspace/sidebar/versions.scss +++ b/frontend/src/app/main/ui/workspace/sidebar/versions.scss @@ -8,6 +8,10 @@ .version-toolbox { padding: $s-8; + height: 100%; + display: grid; + overflow: hidden; + grid-template-rows: auto auto 1fr; } .versions-entry-empty { @@ -49,6 +53,8 @@ display: flex; flex-direction: column; gap: $s-6; + overflow: auto; + margin: 0; } .version-entry { diff --git a/frontend/translations/en.po b/frontend/translations/en.po index 3b7441229f..df8d57bbc3 100644 --- a/frontend/translations/en.po +++ b/frontend/translations/en.po @@ -6565,3 +6565,9 @@ msgstr "Open version menu" #, unused msgid "workspace.viewport.click-to-close-path" msgstr "Click to close the path" + +msgid "workspace.versions.tab.history" +msgstr "History" + +msgid "workspace.versions.tab.actions" +msgstr "Actions" diff --git a/frontend/translations/es.po b/frontend/translations/es.po index 0c09c0a449..703c7636f8 100644 --- a/frontend/translations/es.po +++ b/frontend/translations/es.po @@ -6560,3 +6560,9 @@ msgstr "Abrir menu de versiones" #, unused msgid "workspace.viewport.click-to-close-path" msgstr "Pulsar para cerrar la ruta" + +msgid "workspace.versions.tab.history" +msgstr "Histórico" + +msgid "workspace.versions.tab.actions" +msgstr "Acciones"