Class: Blacklight::Configuration::ViewConfig
- Inherits:
-
OpenStructWithHashAccess
- Object
- OpenStruct
- OpenStructWithHashAccess
- Blacklight::Configuration::ViewConfig
- Defined in:
- lib/blacklight/configuration/view_config.rb
Defined Under Namespace
Instance Attribute Summary collapse
-
#constraints_component ⇒ Class
Component class used to render the constraints.
-
#display_type_field ⇒ String, Symbol
Solr field to use to render format-specific partials.
-
#document_actions ⇒ NestedOpenStructWithHashAccess{Symbol => Blacklight::Configuration::ToolConfig}
'tools' to render for each document.
-
#document_component ⇒ Class
Component class used to render a document; defaults to Blacklight::DocumentComponent.
-
#document_presenter_class ⇒ Class
Document presenter class used by helpers and views.
-
#facet_group_component ⇒ Class
Component class used to render a facet group.
-
#icon ⇒ String, Symbol
Icon file to use in the view picker.
-
#partials ⇒ Array<String>
Partials to render for each document(see #render_document_partials).
-
#search_bar_component ⇒ Class
Component class used to render the search bar.
-
#template ⇒ String
Partial to render around the documents.
-
#title_field ⇒ String, Symbol
Solr field to use to render a document title.
Instance Method Summary collapse
Methods inherited from OpenStructWithHashAccess
#deep_dup, #merge, #merge!, #reverse_merge, #select, #sort_by, #sort_by!, #to_h, #try
Instance Attribute Details
#constraints_component ⇒ Class
Returns component class used to render the constraints.
26 27 28 |
# File 'lib/blacklight/configuration/view_config.rb', line 26 def super || Blacklight::SearchBarPresenter end |
#display_type_field ⇒ String, Symbol
Returns solr field to use to render format-specific partials.
26 27 28 |
# File 'lib/blacklight/configuration/view_config.rb', line 26 def super || Blacklight::SearchBarPresenter end |
#document_actions ⇒ NestedOpenStructWithHashAccess{Symbol => Blacklight::Configuration::ToolConfig}
Returns 'tools' to render for each document.
26 27 28 |
# File 'lib/blacklight/configuration/view_config.rb', line 26 def super || Blacklight::SearchBarPresenter end |
#document_component ⇒ Class
Returns component class used to render a document; defaults to Blacklight::DocumentComponent.
26 27 28 |
# File 'lib/blacklight/configuration/view_config.rb', line 26 def super || Blacklight::SearchBarPresenter end |
#document_presenter_class ⇒ Class
Returns document presenter class used by helpers and views.
26 27 28 |
# File 'lib/blacklight/configuration/view_config.rb', line 26 def super || Blacklight::SearchBarPresenter end |
#facet_group_component ⇒ Class
Returns component class used to render a facet group.
26 27 28 |
# File 'lib/blacklight/configuration/view_config.rb', line 26 def super || Blacklight::SearchBarPresenter end |
#icon ⇒ String, Symbol
Returns icon file to use in the view picker.
26 27 28 |
# File 'lib/blacklight/configuration/view_config.rb', line 26 def super || Blacklight::SearchBarPresenter end |
#partials ⇒ Array<String>
Returns partials to render for each document(see #render_document_partials).
26 27 28 |
# File 'lib/blacklight/configuration/view_config.rb', line 26 def super || Blacklight::SearchBarPresenter end |
#search_bar_component ⇒ Class
Returns component class used to render the search bar.
26 27 28 |
# File 'lib/blacklight/configuration/view_config.rb', line 26 def super || Blacklight::SearchBarPresenter end |
#template ⇒ String
Returns partial to render around the documents.
26 27 28 |
# File 'lib/blacklight/configuration/view_config.rb', line 26 def super || Blacklight::SearchBarPresenter end |
#title_field ⇒ String, Symbol
Returns solr field to use to render a document title.
26 27 28 |
# File 'lib/blacklight/configuration/view_config.rb', line 26 def super || Blacklight::SearchBarPresenter end |
Instance Method Details
#display_label(deprecated_key = nil, **options) ⇒ Object
30 31 32 33 34 35 36 37 38 39 40 41 42 43 |
# File 'lib/blacklight/configuration/view_config.rb', line 30 def display_label(deprecated_key = nil, **) Deprecation.warn(Blacklight::Configuration::ViewConfig, 'Passing the key argument to ViewConfig#display_label is deprecated') if deprecated_key.present? I18n.t( :"blacklight.search.view_title.#{deprecated_key || key}", default: [ :"blacklight.search.view.#{deprecated_key || key}", label, title, (deprecated_key || key).to_s.humanize ], ** ) end |
#search_bar_presenter_class ⇒ Object
26 27 28 |
# File 'lib/blacklight/configuration/view_config.rb', line 26 def super || Blacklight::SearchBarPresenter end |