Skip to content

Images with a colon in URL are broken #1357

Closed
@alexisbernard

Description

@alexisbernard

Hi,

RDoc uses : to split URL and alt text since #1320. But a lot of badges in READMES have a colon in the URL: https://img.shields.io/gem/v/tzinfo?logo=rubygems&label=Gem:RubyGems. So it outputs: <img src="https:", alt="//img.shields.io/gem/v/tzinfo?logo=rubygems&label=Gem:RubyGems"/>. The colon is also authorized in some file systems such as ext4.

It would be better to switch to a character illegal in URLs such as | which have to be encoded. But I could not find a reference of RDoc format explaining the alt text. The newest I found is https://docs.ruby-lang.org/en/3.1/RDoc/Markup.html#class-RDoc::Markup-label-Links but there is no mention of alt text.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions