Class: Geoblacklight::IndexMapLegendComponent

Inherits:
ViewComponent::Base
  • Object
show all
Defined in:
app/components/geoblacklight/index_map_legend_component.rb

Overview

A component for rendering legend for the index map

Instance Method Summary collapse

Constructor Details

#initialize(document:) ⇒ IndexMapLegendComponent

Returns a new instance of IndexMapLegendComponent.



8
9
10
11
# File 'app/components/geoblacklight/index_map_legend_component.rb', line 8

def initialize(document:)
  super()
  @document = document
end

Instance Method Details

#render?Boolean

Returns:

  • (Boolean)


13
14
15
# File 'app/components/geoblacklight/index_map_legend_component.rb', line 13

def render?
  @document.item_viewer.index_map
end