Skip to content

Commit

Permalink
fix show edge case where max items is equal to the items total length
Browse files Browse the repository at this point in the history
  • Loading branch information
syphax-bouazzouni committed Jan 10, 2025
1 parent db67ff3 commit dbc9d6b
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
- containers[..@max_items].each do |item|
= item

- unless @max_items > containers.size
- containers[@max_items+1..].each do |item|
- if (@max_items + 1) < containers.size
- Array(containers[@max_items+1..]).each do |item|
%span{'data-reveal-component-target': "item", class: 'd-none'}
= item
%div{'data-reveal-component-target': "showButton", 'data-action': "click->reveal-component#show" }
Expand Down

0 comments on commit dbc9d6b

Please sign in to comment.