Module: Blacklight::LayoutHelperBehavior
- Included in:
- BlacklightHelperBehavior
- Defined in:
- app/helpers/blacklight/layout_helper_behavior.rb
Overview
A module for useful methods used in layout configuration
Instance Method Summary collapse
-
#container_classes ⇒ String
Class used for specifying main layout container classes.
-
#html_tag_attributes ⇒ Hash
Attributes to add to the <html> tag (e.g. lang and dir).
-
#main_content_classes ⇒ String
Classes used for sizing the main content of a Blacklight page.
-
#show_content_classes ⇒ String
Classes added to a document's show content div.
-
#show_sidebar_classes ⇒ String
Classes added to a document's sidebar div.
-
#sidebar_classes ⇒ String
Classes used for sizing the sidebar content of a Blacklight page.
Instance Method Details
#container_classes ⇒ String
Class used for specifying main layout container classes. Can be overwritten to return 'container-fluid' for Bootstrap full-width layout
47 48 49 |
# File 'app/helpers/blacklight/layout_helper_behavior.rb', line 47 def container_classes 'container' end |
#html_tag_attributes ⇒ Hash
Attributes to add to the <html> tag (e.g. lang and dir)
18 19 20 |
# File 'app/helpers/blacklight/layout_helper_behavior.rb', line 18 def html_tag_attributes { lang: I18n.locale } end |
#main_content_classes ⇒ String
Classes used for sizing the main content of a Blacklight page
32 33 34 |
# File 'app/helpers/blacklight/layout_helper_behavior.rb', line 32 def main_content_classes 'col-lg-9' end |
#show_content_classes ⇒ String
Classes added to a document's show content div
11 12 13 |
# File 'app/helpers/blacklight/layout_helper_behavior.rb', line 11 def show_content_classes "#{main_content_classes} show-document" end |
#show_sidebar_classes ⇒ String
Classes added to a document's sidebar div
25 26 27 |
# File 'app/helpers/blacklight/layout_helper_behavior.rb', line 25 def end |
#sidebar_classes ⇒ String
Classes used for sizing the sidebar content of a Blacklight page
39 40 41 |
# File 'app/helpers/blacklight/layout_helper_behavior.rb', line 39 def 'page-sidebar col-lg-3' end |