Sha256: 7cdb6d5993566670157110024f78ffe6106b8944b8e2e084ba6080cbaf8f8a1b

Contents?: true

Size: 609 Bytes

Versions: 13

Compression:

Stored size: 609 Bytes

Contents

# frozen_string_literal: true

module Decidim
  module Votings
    module ContentBlocks
      module LandingPage
        class DescriptionCell < Decidim::ViewModel
          include Decidim::SanitizeHelper

          delegate :current_participatory_space, to: :controller

          private

          def introductory_image
            current_participatory_space.attached_uploader(:introductory_image)
          end

          def description_text
            decidim_sanitize_editor_admin(translated_attribute(current_participatory_space.description))
          end
        end
      end
    end
  end
end

Version data entries

13 entries across 13 versions & 1 rubygems

Version Path
decidim-elections-0.27.9 app/cells/decidim/votings/content_blocks/landing_page/description_cell.rb
decidim-elections-0.27.8 app/cells/decidim/votings/content_blocks/landing_page/description_cell.rb
decidim-elections-0.27.7 app/cells/decidim/votings/content_blocks/landing_page/description_cell.rb
decidim-elections-0.27.6 app/cells/decidim/votings/content_blocks/landing_page/description_cell.rb
decidim-elections-0.26.10 app/cells/decidim/votings/content_blocks/landing_page/description_cell.rb
decidim-elections-0.26.9 app/cells/decidim/votings/content_blocks/landing_page/description_cell.rb
decidim-elections-0.27.5 app/cells/decidim/votings/content_blocks/landing_page/description_cell.rb
decidim-elections-0.26.8 app/cells/decidim/votings/content_blocks/landing_page/description_cell.rb
decidim-elections-0.27.4 app/cells/decidim/votings/content_blocks/landing_page/description_cell.rb
decidim-elections-0.27.3 app/cells/decidim/votings/content_blocks/landing_page/description_cell.rb
decidim-elections-0.26.7 app/cells/decidim/votings/content_blocks/landing_page/description_cell.rb
decidim-elections-0.27.2 app/cells/decidim/votings/content_blocks/landing_page/description_cell.rb
decidim-elections-0.27.1 app/cells/decidim/votings/content_blocks/landing_page/description_cell.rb