Files
nairobi/app/components/layout/top_links_component.rb
Javi Martín dae4aae328 Avoid rendenring an empty list in top links
We've had an accessibility error reported by the Spanish "Portal
Administración electrónica" (PAe). While I can't find any accessibility
rule saying empty lists should be avoided, it looks like some screen
readers report finding lists with 0 items, which is annoying.
2021-06-24 13:15:04 +02:00

14 lines
255 B
Ruby

class Layout::TopLinksComponent < ApplicationComponent
delegate :content_block, to: :helpers
def render?
top_links_content_block.present?
end
private
def top_links_content_block
content_block("top_links", I18n.locale)
end
end