From 031347a2bcb9846881eddb858d1157a71c21c66d Mon Sep 17 00:00:00 2001 From: Joe Mou Date: Thu, 29 Jan 2026 08:40:31 -0500 Subject: Better formatting for long URLs --- static/style.css | 21 ++++++++++++++++----- views/repo.eta | 12 ++++++------ 2 files changed, 22 insertions(+), 11 deletions(-) diff --git a/static/style.css b/static/style.css index 5673aa7..818c244 100644 --- a/static/style.css +++ b/static/style.css @@ -137,12 +137,23 @@ footer { border: 1px solid var(--border-color); } -.description { - margin-bottom: .2rem; -} +.repo-info { + .description { + margin-bottom: .2rem; + } + + .detail { + white-space: nowrap; + } -.count + .count { - margin-left: 1rem; + div.detail { + overflow-x: hidden; + text-overflow: ellipsis; + } + + span.detail + span.detail { + margin-left: 1rem; + } } pre.box { diff --git a/views/repo.eta b/views/repo.eta index fbca299..a6fcfb3 100644 --- a/views/repo.eta +++ b/views/repo.eta @@ -1,24 +1,24 @@ <% layout("./layout.eta") %> <% if (it.info) { %> -
+
<% if (it.info.description) { %>
<%= it.info.description %>
<% } %> <% if (it.info.website) { %> -
<%= it.info.website %>
+ <% } %> <% if (it.info.stars) { %> - stars <%= it.info.stars %> + stars <%= it.info.stars %> <% } %> <% if (it.info.watchers) { %> - watchers <%= it.info.watchers %> + watchers <%= it.info.watchers %> <% } %> <% if (it.info.forks) { %> - forks <%= it.info.forks %> + forks <%= it.info.forks %> <% } %> <% if (it.info.numReleases) { %> -
<%= it.info.numReleases %> releases
+ <% } %>
<% } %> -- cgit v1.3.1