From 7ede27bf0fbd1f6e3dae27c566e4041c6b7b0e70 Mon Sep 17 00:00:00 2001 From: Yohan Boniface Date: Fri, 28 Mar 2025 16:39:40 +0100 Subject: [PATCH] chore: top edit bar responsiveness Co-authored-by: David Larlet --- umap/static/umap/css/bar.css | 26 ++++++++++++++++++++------ umap/static/umap/js/modules/ui/bar.js | 12 ++++++------ 2 files changed, 26 insertions(+), 12 deletions(-) diff --git a/umap/static/umap/css/bar.css b/umap/static/umap/css/bar.css index 96f00495..4dc36f6d 100644 --- a/umap/static/umap/css/bar.css +++ b/umap/static/umap/css/bar.css @@ -129,17 +129,20 @@ text-indent: -9999px; } .umap-main-edit-toolbox .map-name { - display: inline-block; - overflow: hidden; - white-space: nowrap; - text-overflow: ellipsis; font-weight: bold; text-align: start; } +.truncate { + display: inline-flex; + overflow: hidden; + white-space: nowrap; + text-overflow: ellipsis; +} +.umap-main-edit-toolbox .username { + max-width: 100px; +} .umap-main-edit-toolbox .share-status { font-style: italic; - overflow: hidden; - text-overflow: ellipsis; } .map-name:after { content: '\00a0'; @@ -236,3 +239,14 @@ padding: 0; margin: 0; } +@media all and (max-width: 980px) { + .umap-main-edit-toolbox button span { + display: none; + } +} +@media all and (max-width: 770px) { + .umap-main-edit-toolbox .umap-help-link, + .umap-main-edit-toolbox .share-status { + display: none !important; + } +} diff --git a/umap/static/umap/js/modules/ui/bar.js b/umap/static/umap/js/modules/ui/bar.js index 496954de..04659db4 100644 --- a/umap/static/umap/js/modules/ui/bar.js +++ b/umap/static/umap/js/modules/ui/bar.js @@ -9,15 +9,15 @@ const TOP_BAR_TEMPLATE = `
- - + +
@@ -27,12 +27,12 @@ const TOP_BAR_TEMPLATE = `