Skip to content

Commit

Permalink
Added truncation to browe tile
Browse files Browse the repository at this point in the history
  • Loading branch information
wbraden committed Aug 8, 2024
1 parent 091d1ec commit b194bd3
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Components/browseTile.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,10 @@ browseTileTemplate.innerHTML = `
</div>
<div class="content">
<div class="browse-tile-details">
<p class="typography body md tcp">
<p class="typography body md tcp truncate">
<slot name="label"></slot>
</p>
<p class="typography body sm tcs">
<p class="typography body sm tcs truncate">
<slot name="description"></slot>
</p>
</div>
Expand Down
6 changes: 6 additions & 0 deletions css/main.css
Original file line number Diff line number Diff line change
Expand Up @@ -401,6 +401,12 @@ button {
cursor: pointer;
}

.truncate {
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}

.typography.body {
text-align: left;
line-height: 1.5;
Expand Down
1 change: 1 addition & 0 deletions index.html
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
<!DOCTYPE html>
<html lang="en">
<head>

<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/swiper@11/swiper-bundle.min.css">
<link rel="stylesheet" href="css/main.css">
Expand Down

0 comments on commit b194bd3

Please sign in to comment.