Sha256: e7457ef908442dc4241b7e4d829238877828156d0a5e5bcc3895a9c8dafbdab0

Contents?: true

Size: 501 Bytes

Versions: 2

Compression:

Stored size: 501 Bytes

Contents

module CurationConcerns
  module PermissionsHelper
    def help_link(file, title, aria_label)
      link_to help_icon, '#', 'data-toggle': 'popover', 'data-content': capture_content(file),
                              'data-original-title': title, 'aria-label': aria_label
    end

    private

      def capture_content(file)
        capture do
          render file
        end
      end

      def help_icon
        content_tag 'i', '', 'aria-hidden': true, class: 'help-icon'
      end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
curation_concerns-0.5.0 app/helpers/curation_concerns/permissions_helper.rb
curation_concerns-0.4.0 app/helpers/curation_concerns/permissions_helper.rb