Sha256: 1b7153c4ac4e9063c46707ab1dc970a1c1dab1215b7f06ba7c375a472a2f0a75

Contents?: true

Size: 586 Bytes

Versions: 3

Compression:

Stored size: 586 Bytes

Contents

module AbAdmin
  module Views
    module Inputs
      class CkeditorInput < ::SimpleForm::Inputs::Base
        def input
          unless @builder.template.instance_variable_get(:@ckeditor_init)
            @builder.template.concat @builder.template.javascript_include_tag('/javascripts/ckeditor/init')
            @builder.template.instance_variable_set(:@ckeditor_init, true)
          end
          input_html_options.reverse_merge!({width: 800, height: 200, toolbar: 'Easy'})
          @builder.cktext_area(attribute_name, input_html_options)
        end
      end
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
ab_admin-0.5.0 lib/ab_admin/views/inputs/ckeditor_input.rb
ab_admin-0.4.0 lib/ab_admin/views/inputs/ckeditor_input.rb
ab_admin-0.3.6 lib/ab_admin/views/inputs/ckeditor_input.rb