🎉 Add ellipsis to text

This commit is contained in:
Eva 2022-08-04 13:54:35 +02:00
parent 57ec9f8218
commit 33706e0bda
2 changed files with 10 additions and 6 deletions

View file

@ -94,9 +94,7 @@
} }
.item-info { .item-info {
color: $color-gray-20; display: grid;
display: flex;
flex-direction: column;
padding: $size-2; padding: $size-2;
text-align: left; text-align: left;
width: 100%; width: 100%;
@ -120,13 +118,18 @@
max-width: 230px; max-width: 230px;
} }
} }
span.date { span.date {
color: $color-gray-30; color: $color-gray-20;
font-size: $fs14; font-size: $fs14;
overflow: hidden; overflow: hidden;
text-overflow: ellipsis; text-overflow: ellipsis;
width: 100%; width: 100%;
white-space: nowrap;
max-width: 260px;
@media #{$bp-max-1366} {
max-width: 230px;
}
} }
.edit-wrapper { .edit-wrapper {

View file

@ -62,7 +62,8 @@
[{:keys [modified-at]}] [{:keys [modified-at]}]
(let [locale (mf/deref i18n/locale) (let [locale (mf/deref i18n/locale)
time (dt/timeago modified-at {:locale locale})] time (dt/timeago modified-at {:locale locale})]
(str (tr "ds.updated-at" time)))) [:span.date
(str (tr "ds.updated-at" time))]))
(defn create-counter-element (defn create-counter-element
[_element file-count] [_element file-count]