Sha256: 4bd2db0aa2a74fbce0c864c69efab2f7f6a9adec61e5368299520be4beeb2d58

Contents?: true

Size: 841 Bytes

Versions: 38

Compression:

Stored size: 841 Bytes

Contents

# encoding: utf-8

class Sanitize
  module Config
    BASIC = freeze_config(
      :elements => RESTRICTED[:elements] + %w[
        a abbr blockquote br cite code dd dfn dl dt kbd li mark ol p pre q s
        samp small strike sub sup time ul var
      ],

      :attributes => {
        'a'          => %w[href],
        'abbr'       => %w[title],
        'blockquote' => %w[cite],
        'dfn'        => %w[title],
        'q'          => %w[cite],
        'time'       => %w[datetime pubdate]
      },

      :add_attributes => {
        'a' => {'rel' => 'nofollow'}
      },

      :protocols => {
        'a'          => {'href' => ['ftp', 'http', 'https', 'mailto', :relative]},
        'blockquote' => {'cite' => ['http', 'https', :relative]},
        'q'          => {'cite' => ['http', 'https', :relative]}
      }
    )
  end
end

Version data entries

38 entries across 38 versions & 2 rubygems

Version Path
sanitize-6.1.3 lib/sanitize/config/basic.rb
sanitize-6.1.2 lib/sanitize/config/basic.rb
sanitize-6.1.1 lib/sanitize/config/basic.rb
sanitize-6.1.0 lib/sanitize/config/basic.rb
sanitize-6.0.2 lib/sanitize/config/basic.rb
mumukit-content-type-1.12.1 vendor/bundle/ruby/2.7.0/gems/sanitize-6.0.1/lib/sanitize/config/basic.rb
mumukit-content-type-1.12.0 vendor/bundle/ruby/2.7.0/gems/sanitize-6.0.1/lib/sanitize/config/basic.rb
sanitize-6.0.1 lib/sanitize/config/basic.rb
mumukit-content-type-1.11.1 vendor/bundle/ruby/2.6.0/gems/sanitize-6.0.0/lib/sanitize/config/basic.rb
sanitize-6.0.0 lib/sanitize/config/basic.rb
sanitize-5.2.3 lib/sanitize/config/basic.rb
sanitize-5.2.2 lib/sanitize/config/basic.rb
sanitize-5.2.1 lib/sanitize/config/basic.rb
sanitize-5.2.0 lib/sanitize/config/basic.rb
sanitize-5.1.0 lib/sanitize/config/basic.rb
sanitize-5.0.0 lib/sanitize/config/basic.rb
sanitize-4.6.6 lib/sanitize/config/basic.rb
sanitize-4.6.5 lib/sanitize/config/basic.rb
sanitize-4.6.4 lib/sanitize/config/basic.rb
sanitize-4.6.3 lib/sanitize/config/basic.rb