diff --git a/app/assets/stylesheets/views/profile.scss b/app/assets/stylesheets/views/profile.scss index 5c3007c25..beb838de3 100644 --- a/app/assets/stylesheets/views/profile.scss +++ b/app/assets/stylesheets/views/profile.scss @@ -73,6 +73,14 @@ flex-wrap: nowrap; white-space: nowrap; padding: var(--su-2) var(--su-2); + max-width: 100%; + overflow: hidden; + text-overflow: ellipsis; + + & > span { + overflow: hidden; + text-overflow: ellipsis; + } @media (min-width: $breakpoint-m) { padding: var(--su-1) var(--su-3); diff --git a/app/views/organizations/_header.html.erb b/app/views/organizations/_header.html.erb index 47749acaf..1631eca37 100644 --- a/app/views/organizations/_header.html.erb +++ b/app/views/organizations/_header.html.erb @@ -37,13 +37,17 @@ <% if @organization.location.present? %> <%= crayons_icon_tag(:location, class: "mr-2 shrink-0", title: t("views.organizations.location.icon")) %> - <%= sanitize @organization.location %> + + <%= sanitize @organization.location %> + <% end %> <%= crayons_icon_tag(:cake, class: "mr-2 shrink-0", title: t("views.organizations.joined.icon")) %> - <%= t("views.organizations.joined.text_html", date: local_date(@user.created_at)) %> + + <%= t("views.organizations.joined.text_html", date: local_date(@user.created_at)) %> + diff --git a/app/views/users/show.html.erb b/app/views/users/show.html.erb index a9f4eb480..f3e1f4952 100644 --- a/app/views/users/show.html.erb +++ b/app/views/users/show.html.erb @@ -65,26 +65,34 @@ <% if @user.profile.location.present? %> <%= crayons_icon_tag(:location, class: "mr-2 shrink-0", title: t("views.users.location_icon")) %> - <%= @user.profile.location %> + + <%= @user.profile.location %> + <% end %> <%= crayons_icon_tag(:cake, class: "mr-2 shrink-0", title: t("views.users.joined.icon")) %> - <%= t("views.users.joined.text_html", date: local_date(@user.created_at)) %> + + <%= t("views.users.joined.text_html", date: local_date(@user.created_at)) %> + <% if @user.setting.display_email_on_profile %> <%= crayons_icon_tag(:email, class: "mr-2 shrink-0", title: t("views.users.email_icon")) %> - <%= @user.email %> + + <%= @user.email %> + <% end %> <% if @user.profile.website_url.present? %> " class="profile-header__meta__item"> <%= crayons_icon_tag("external-link", class: "mr-2 shrink-0", title: t("views.users.website")) %> - <%= @user.profile.website_url %> + + <%= @user.profile.website_url %> + <% end %>