Skip to content

Commit

Permalink
Show overflow of <ol> in /blocks list (#4142)
Browse files Browse the repository at this point in the history
  • Loading branch information
casey authored Dec 23, 2024
1 parent a2d397a commit 9718470
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 10 deletions.
2 changes: 1 addition & 1 deletion static/index.css
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ dl {
overflow-wrap: break-word;
}

ol, ul {
ul {
overflow: hidden;
}

Expand Down
19 changes: 10 additions & 9 deletions templates/blocks.html
Original file line number Diff line number Diff line change
@@ -1,19 +1,20 @@
<h1>Blocks</h1>
%% for (i, hash) in self.blocks.iter().enumerate() {
%% if let Some(inscription_ids) = &self.featured_blocks.get(hash) {
%% let height = self.last - u32::try_from(i).unwrap();
%% if let Some(inscription_ids) = &self.featured_blocks.get(hash) {
<div class=block>
<h2><a href=/block/{{ self.last - i as u32 }}>Block {{ self.last - i as u32 }}</a></h2>
<h2><a href=/block/{{ height }}>Block {{ height }}</a></h2>
<div class=thumbnails>
%% for id in *inscription_ids {
%% for id in *inscription_ids {
{{ Iframe::thumbnail(*id) }}
%% }
%% }
</div>
</div>
%% } else {
%% if i == self.featured_blocks.len() {
<ol start={{ self.last - self.featured_blocks.len() as u32 }} reversed class=block-list>
%% }
%% } else {
%% if i == self.featured_blocks.len() {
<ol start={{ height }} reversed class=block-list>
%% }
<li><a class=collapse href=/block/{{ hash }}>{{ hash }}</a></li>
%% }
%% }
%% }
</ol>

0 comments on commit 9718470

Please sign in to comment.