Sha256: 4a01cc0b0c58ef3659cfc999608ea55bb3b8d1219d2d7fbbe735a1fd8e84bbe5

Contents?: true

Size: 841 Bytes

Versions: 8

Compression:

Stored size: 841 Bytes

Contents

class Embeditor.Adapters.Storify extends Embeditor.Adapters.StaticTemplate
    className: "Storify"

    @Template = Embeditor.Template('storify')

    @QueryDefaults =
        maxwidth  : 550
        maxheight : 750

    # For storify, we just use the full URL, so no matchers are needed.
    @Matchers = []


    swap: ->
        # Storify's embed code doesn't provide a protocol (http/s), so let's
        # strip it out. We also want to make sure that there is no trailing
        # slash so that we can concatenate other things to the URL.
        url = Embeditor.Utility.stripProtocol(
                Embeditor.Utility.stripTrailingSlash(@href))

        # Storify embed is responsive, so we don't need to provide a width.
        @embed Storify.Template
            maxheight   : @queryParams.maxheight
            url         : url

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
embeditor-rails-2.2.0 app/assets/javascripts/embeditor/adapters/storify.js.coffee
embeditor-rails-2.0.1 app/assets/javascripts/embeditor/adapters/storify.js.coffee
embeditor-rails-2.0.0 app/assets/javascripts/embeditor/adapters/storify.js.coffee
embeditor-rails-2.0.0.beta app/assets/javascripts/embeditor/adapters/storify.js.coffee
embeditor-rails-1.1.1 app/assets/javascripts/embeditor/adapters/storify.js.coffee
embeditor-rails-1.1.0 app/assets/javascripts/embeditor/adapters/storify.js.coffee
embeditor-rails-1.0.1 app/assets/javascripts/embeditor/adapters/storify.js.coffee
embeditor-rails-0.1.0 app/assets/javascripts/embeditor/adapters/storify.js.coffee