Sha256: 3ff1632b86195fb7bdbdce94cae907b22c4e72e32ae12e3447e2ec2d87e66897

Contents?: true

Size: 398 Bytes

Versions: 5

Compression:

Stored size: 398 Bytes

Contents

module Onebox
  module Engine
    class GoogleCalendarOnebox
      include Engine

      matches_regexp /^(https?:)?\/\/(www\.google\.[\w.]{2,}|goo\.gl)\/calendar\/.+$/
      always_https

      def to_html
        url = @url.split('&').first
        "<iframe src='#{url}&rm=minimal' style='border: 0' width='800' height='600' frameborder='0' scrolling='no' ></iframe>"
      end

    end
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
onebox-1.5.26 lib/onebox/engine/google_calendar_onebox.rb
onebox-1.5.25 lib/onebox/engine/google_calendar_onebox.rb
onebox-1.5.24 lib/onebox/engine/google_calendar_onebox.rb
onebox-1.5.23 lib/onebox/engine/google_calendar_onebox.rb
onebox-1.5.22 lib/onebox/engine/google_calendar_onebox.rb