Sha256: 915219293bcbd0f1c14b7a45c90b05be1a95c5a13aeb3f39f163a9468915d0e5
Contents?: true
Size: 417 Bytes
Versions: 16
Compression:
Stored size: 417 Bytes
Contents
module Qbrick class VideoBrick < Brick YOUTUBE = 'youtube' VIMEO = 'vimeo' EXTERNAL = 'external' validates :any_source, presence: true # a video id, an embed code or a link to a video is required def any_source embed_src.presence || href.presence end def self.source_types [YOUTUBE, VIMEO, EXTERNAL] end def user_can_add_childs? false end end end
Version data entries
16 entries across 16 versions & 1 rubygems