Sha256: 27ea0ab4cc9d882ef21b9a7b949b939a636e45ffeadbfb2a1b83d2dd9824c8c1

Contents?: true

Size: 452 Bytes

Versions: 6

Compression:

Stored size: 452 Bytes

Contents

module ExpressTemplates
  module Components
    module Forms
      class Submit < FormComponent

        emits -> {
          div(class: field_wrapper_class) {
            submit_tag(value, html_options)
          }
        }

        def value
          if @args.first.is_a?(String)
            @args.first
          else
            'Save'
          end
        end

        def html_options
          @config
        end
      end
    end
  end
end

Version data entries

6 entries across 6 versions & 2 rubygems

Version Path
express_admin-1.2.1 vendor/gems/express_templates/lib/express_templates/components/forms/submit.rb
express_admin-1.2.0 vendor/gems/express_templates/lib/express_templates/components/forms/submit.rb
express_templates-0.5.0 lib/express_templates/components/forms/submit.rb
express_templates-0.4.2 lib/express_templates/components/forms/submit.rb
express_templates-0.4.1 lib/express_templates/components/forms/submit.rb
express_templates-0.4.0 lib/express_templates/components/forms/submit.rb