Sha256: 567b55aed87e41a6d536d14987a7f30eb98a14a1810d2fdff1d946a0e5c7ba74

Contents?: true

Size: 534 Bytes

Versions: 13

Compression:

Stored size: 534 Bytes

Contents

# frozen_string_literal: true

module Decidim
  module Admin
    class SecondaryMenuPresenter < Decidim::MenuPresenter
      def render(render_options = {}, &)
        output = []
        output.push render_title(render_options) if render_options.fetch(:title, false)
        output.push render_menu(&)
        safe_join(output)
      end

      protected

      def render_title(render_options)
        content_tag :div, class: "secondary-nav__title" do
          render_options.fetch(:title)
        end
      end
    end
  end
end

Version data entries

13 entries across 13 versions & 1 rubygems

Version Path
decidim-admin-0.29.1 app/presenters/decidim/admin/secondary_menu_presenter.rb
decidim-admin-0.28.4 app/presenters/decidim/admin/secondary_menu_presenter.rb
decidim-admin-0.29.0 app/presenters/decidim/admin/secondary_menu_presenter.rb
decidim-admin-0.28.3 app/presenters/decidim/admin/secondary_menu_presenter.rb
decidim-admin-0.29.0.rc4 app/presenters/decidim/admin/secondary_menu_presenter.rb
decidim-admin-0.29.0.rc3 app/presenters/decidim/admin/secondary_menu_presenter.rb
decidim-admin-0.29.0.rc2 app/presenters/decidim/admin/secondary_menu_presenter.rb
decidim-admin-0.29.0.rc1 app/presenters/decidim/admin/secondary_menu_presenter.rb
decidim-admin-0.28.2 app/presenters/decidim/admin/secondary_menu_presenter.rb
decidim-admin-0.28.1 app/presenters/decidim/admin/secondary_menu_presenter.rb
decidim-admin-0.28.0 app/presenters/decidim/admin/secondary_menu_presenter.rb
decidim-admin-0.28.0.rc5 app/presenters/decidim/admin/secondary_menu_presenter.rb
decidim-admin-0.28.0.rc4 app/presenters/decidim/admin/secondary_menu_presenter.rb