Sha256: 1cecc9499569c6c96bb82e6c6e17abddf5f542d5f76a01a3368d74fbefcde1d4
Contents?: true
Size: 513 Bytes
Versions: 38
Compression:
Stored size: 513 Bytes
Contents
# frozen_string_literal: true module Onebox module Engine class GiphyOnebox include Engine include StandardEmbed matches_regexp(/^https?:\/\/(giphy\.com\/gifs|gph\.is)\//) always_https def to_html oembed = get_oembed <<-HTML <a href="#{oembed.url}" target="_blank" class="onebox"> <img src="#{oembed.url}" width="#{oembed.width}" height="#{oembed.height}" #{oembed.title_attr}> </a> HTML end end end end
Version data entries
38 entries across 38 versions & 1 rubygems