Class: Decidim::Accountability::HighlightedResultsForComponentCell
- Inherits:
-
ViewModel
- Object
- ViewModel
- Decidim::Accountability::HighlightedResultsForComponentCell
- Includes:
- Cell::ViewModel::Partial, ApplicationHelper
- Defined in:
- app/cells/decidim/accountability/highlighted_results_for_component_cell.rb
Overview
This cell renders the highlighted results for a given component. It is intended to be used in the ‘participatory_space_highlighted_elements` view hook.
Instance Method Summary collapse
Methods included from ApplicationHelper
#apply_accountability_pack_tags, #component_name, #display_percentage, #filter_items_for
Instance Method Details
#items_blank? ⇒ Boolean
20 21 22 |
# File 'app/cells/decidim/accountability/highlighted_results_for_component_cell.rb', line 20 def items_blank? results_count.zero? end |
#show ⇒ Object
16 17 18 |
# File 'app/cells/decidim/accountability/highlighted_results_for_component_cell.rb', line 16 def show render unless items_blank? end |