Sha256: 3ea5205ef44da9909a5d138e3953b8e222a7ddee3dc147452819d9653e2bde95

Contents?: true

Size: 385 Bytes

Versions: 9

Compression:

Stored size: 385 Bytes

Contents

module Onebox
  module Engine
    class FiveHundredPxOnebox
      include Engine
      include StandardEmbed

      matches_regexp(/^https?:\/\/500px\.com\/photo\/\d+\//)
      always_https

      def to_html
        og = get_opengraph
        "<img src='#{og.image}' width='#{og.image_width}' height='#{og.image_height}' class='onebox' #{og.title_attr}>"
      end

    end
  end
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
onebox-1.8.89 lib/onebox/engine/five_hundred_px_onebox.rb
onebox-1.8.88 lib/onebox/engine/five_hundred_px_onebox.rb
onebox-1.8.87 lib/onebox/engine/five_hundred_px_onebox.rb
onebox-1.8.86 lib/onebox/engine/five_hundred_px_onebox.rb
onebox-1.8.85 lib/onebox/engine/five_hundred_px_onebox.rb
onebox-1.8.84 lib/onebox/engine/five_hundred_px_onebox.rb
onebox-1.8.83 lib/onebox/engine/five_hundred_px_onebox.rb
onebox-1.8.82 lib/onebox/engine/five_hundred_px_onebox.rb
onebox-1.8.80 lib/onebox/engine/five_hundred_px_onebox.rb