Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/diaspora/diaspora.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorflaburgan <flaburgan@geexxx.fr>2021-10-29 00:41:08 +0300
committerBenjamin Neff <benjamin@coding4coffee.ch>2021-11-23 02:27:05 +0300
commit37f081959c8ea1aad7bd23481a34d8ca5815bb13 (patch)
treeb189241b7f6c2ea324ce27388bf9353645859f75
parentf69215edf10588843bc1354f03a07bf5ecccddf2 (diff)
Add a max-width to user name in the header, fixes #7676
closes #8313
-rw-r--r--Changelog.md1
-rw-r--r--app/assets/stylesheets/header.scss13
-rw-r--r--app/assets/templates/header_tpl.jst.hbs2
3 files changed, 15 insertions, 1 deletions
diff --git a/Changelog.md b/Changelog.md
index 96466dfb0..0c7f45d8c 100644
--- a/Changelog.md
+++ b/Changelog.md
@@ -9,6 +9,7 @@
## Bug fixes
* Ensure the log folder exists [#8287](https://github.com/diaspora/diaspora/pull/8287)
+* Limit name length in header [#8313] (https://github.com/diaspora/diaspora/pull/8313)
## Features
* Add tags to tumblr posts [#8244](https://github.com/diaspora/diaspora/pull/8244)
diff --git a/app/assets/stylesheets/header.scss b/app/assets/stylesheets/header.scss
index 55fe8f924..c3285f99f 100644
--- a/app/assets/stylesheets/header.scss
+++ b/app/assets/stylesheets/header.scss
@@ -119,6 +119,19 @@
}
}
+ .dropdown-toggle {
+ align-items: center;
+ display: flex;
+
+ .user-name {
+ margin-right: 3px;
+ max-width: 250px;
+ overflow: hidden;
+ text-overflow: ellipsis;
+ white-space: nowrap;
+ }
+ }
+
.user-menu-dropdown {
padding: 0;
}
diff --git a/app/assets/templates/header_tpl.jst.hbs b/app/assets/templates/header_tpl.jst.hbs
index d730a8bd5..567f3aa85 100644
--- a/app/assets/templates/header_tpl.jst.hbs
+++ b/app/assets/templates/header_tpl.jst.hbs
@@ -69,7 +69,7 @@
<ul class="nav navbar-nav navbar-right">
<li class="dropdown user-menu" id="user-menu">
<a href="{{urlTo "person" current_user.guid}}" class="dropdown-toggle hidden-xs hidden-sm" data-toggle="dropdown" role="button" aria-expanded="false">
- <span class="user-avatar pull-left">
+ <span class="user-avatar">
{{{personImage current_user "small"}}}
</span>
<span class="user-name">{{current_user.name}}</span>