Sha256: 86b0dc8f5fbb5c43bfe4ee116de3667273ce712463fb74aad721fa16658b9df2

Contents?: true

Size: 620 Bytes

Versions: 16

Compression:

Stored size: 620 Bytes

Contents

# frozen_string_literal: true

module Decidim
  module Proposals
    # A cell to display when a proposal has been published.
    class ProposalActivityCell < ActivityCell
      def title
        I18n.t(
          "decidim.proposals.last_activity.new_proposal_at_html",
          link: participatory_space_link
        )
      end

      def resource_link_text
        decidim_html_escape(presenter.title)
      end

      def description
        strip_tags(presenter.body(links: true))
      end

      def presenter
        @presenter ||= Decidim::Proposals::ProposalPresenter.new(resource)
      end
    end
  end
end

Version data entries

16 entries across 16 versions & 1 rubygems

Version Path
decidim-proposals-0.24.0.rc1 app/cells/decidim/proposals/proposal_activity_cell.rb
decidim-proposals-0.23.3 app/cells/decidim/proposals/proposal_activity_cell.rb
decidim-proposals-0.23.2 app/cells/decidim/proposals/proposal_activity_cell.rb
decidim-proposals-0.23.1 app/cells/decidim/proposals/proposal_activity_cell.rb
decidim-proposals-0.23.1.rc1 app/cells/decidim/proposals/proposal_activity_cell.rb
decidim-proposals-0.23.0 app/cells/decidim/proposals/proposal_activity_cell.rb
decidim-proposals-0.22.0 app/cells/decidim/proposals/proposal_activity_cell.rb
decidim-proposals-0.21.0 app/cells/decidim/proposals/proposal_activity_cell.rb
decidim-proposals-0.20.1 app/cells/decidim/proposals/proposal_activity_cell.rb
decidim-proposals-0.20.0 app/cells/decidim/proposals/proposal_activity_cell.rb
decidim-proposals-0.19.1 app/cells/decidim/proposals/proposal_activity_cell.rb
decidim-proposals-0.18.1 app/cells/decidim/proposals/proposal_activity_cell.rb
decidim-proposals-0.19.0 app/cells/decidim/proposals/proposal_activity_cell.rb
decidim-proposals-0.17.2 app/cells/decidim/proposals/proposal_activity_cell.rb
decidim-proposals-0.18.0 app/cells/decidim/proposals/proposal_activity_cell.rb
decidim-proposals-0.17.1 app/cells/decidim/proposals/proposal_activity_cell.rb