Sha256: d37c80e2f602fb2137714f8133c55f1d10dd70379d1d25e471fca7ef30dfeefc

Contents?: true

Size: 809 Bytes

Versions: 2

Compression:

Stored size: 809 Bytes

Contents

# frozen_string_literal: true
def init
  sections :list, [T('docstring')]
end

def tag_signature(tag)
  types = tag.types || []
  signature = "<strong>#{tag_link_name(tag)}</strong> "
  sig_tag = tag.object.tag('yard.signature')
  extra = sig_tag.text if sig_tag
  extra ||= case types.first
            when 'with_name'
              "name description"
            when 'with_types'
              "[Types] description"
            when 'with_types_and_name'
              "name [Types] description"
            when 'with_title_and_text'
              "title\ndescription"
            when 'with_types_and_title'
              "[Types] title\ndescription"
            else
              "description"
            end
  signature + h(extra).gsub(/\n/, "<br/>&nbsp;&nbsp;&nbsp;")
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
yard-0.9.18 docs/templates/default/yard_tags/html/setup.rb
yard-0.9.17 docs/templates/default/yard_tags/html/setup.rb