Class: Arclight::DocumentCollectionContextComponent

Inherits:
SearchResultComponent
  • Object
show all
Defined in:
app/components/arclight/document_collection_context_component.rb

Overview

Display a single document in the collection

Instance Attribute Summary collapse

Attributes inherited from SearchResultComponent

#document

Instance Method Summary collapse

Methods inherited from SearchResultComponent

#compact?, #icon

Constructor Details

#initialize(document: nil, blacklight_config: nil, **kwargs) ⇒ DocumentCollectionContextComponent

Returns a new instance of DocumentCollectionContextComponent.

Parameters:



7
8
9
10
# File 'app/components/arclight/document_collection_context_component.rb', line 7

def initialize(document: nil, blacklight_config: nil, **kwargs)
  super(document: document, **kwargs)
  @blacklight_config = blacklight_config
end

Instance Attribute Details

#blacklight_configObject (readonly)

Returns the value of attribute blacklight_config.



12
13
14
# File 'app/components/arclight/document_collection_context_component.rb', line 12

def blacklight_config
  @blacklight_config
end

Instance Method Details

#classesObject



14
15
16
# File 'app/components/arclight/document_collection_context_component.rb', line 14

def classes
  (super - ['row'] + ['al-collection-context']).flatten
end