Sha256: b7a31d4cabe3f832dcbf02ab58af4d121f1671eeb8aa77ab3f8345ec60cf36e5

Contents?: true

Size: 1.33 KB

Versions: 17

Compression:

Stored size: 1.33 KB

Contents

require 'active_support/core_ext/module/delegation'
require 'active_support/core_ext/module/attribute_accessors'

module Cmor
  module Contact
    module Configuration
      def configure
        yield self
      end

      mattr_accessor :input_name_css_classes do
        'form-control'
      end

      mattr_accessor :input_email_css_classes do
        'form-control'
      end

      mattr_accessor :input_phone_css_classes do
        'form-control'
      end

      mattr_accessor :input_message_css_classes do
        'form-control'
      end

      mattr_accessor :input_terms_of_service_css_classes do
        ''
      end

      mattr_accessor :form_actions_wrapper_css_classes do
        'controls form-actions well'
      end

      mattr_accessor :recipients do
        ->(environment) { "jane.doe@domain.local" }
      end

      mattr_accessor :sender do
        ->(mail_form) { %("#{mail_form.name}" <#{mail_form.email}>) }
      end

      mattr_accessor :base_controller do
        'ApplicationController'
      end

      mattr_accessor :additional_contact_information do
        nil
      end

      mattr_accessor :after_create_url do
        ->(controller) { controller.root_path }
      end

      mattr_accessor :contact_request_include_modules do
        ->() { [Cmor::Contact::ContactRequest::PhoneConcern] }
      end
    end
  end
end

Version data entries

17 entries across 17 versions & 1 rubygems

Version Path
cmor_contact-0.0.40.pre lib/cmor/contact/configuration.rb
cmor_contact-0.0.39.pre lib/cmor/contact/configuration.rb
cmor_contact-0.0.38.pre lib/cmor/contact/configuration.rb
cmor_contact-0.0.37.pre lib/cmor/contact/configuration.rb
cmor_contact-0.0.36.pre lib/cmor/contact/configuration.rb
cmor_contact-0.0.35.pre lib/cmor/contact/configuration.rb
cmor_contact-0.0.34.pre lib/cmor/contact/configuration.rb
cmor_contact-0.0.33.pre lib/cmor/contact/configuration.rb
cmor_contact-0.0.32.pre lib/cmor/contact/configuration.rb
cmor_contact-0.0.31.pre lib/cmor/contact/configuration.rb
cmor_contact-0.0.30.pre lib/cmor/contact/configuration.rb
cmor_contact-0.0.29.pre lib/cmor/contact/configuration.rb
cmor_contact-0.0.28.pre lib/cmor/contact/configuration.rb
cmor_contact-0.0.27.pre lib/cmor/contact/configuration.rb
cmor_contact-0.0.26.pre lib/cmor/contact/configuration.rb
cmor_contact-0.0.25.pre lib/cmor/contact/configuration.rb
cmor_contact-0.0.24.pre lib/cmor/contact/configuration.rb