ecm_contact 1.0.3.pre → 1.0.4.pre

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,9 +1,9 @@
1
1
  <%= simple_form_for @contact_request, :html_class => 'well' do |f| %>
2
- <%= f.input :name, :input_html => { :class => 'span6' } %>
3
- <%= f.input :email, :input_html => { :class => 'span6' } %>
4
- <%= f.input :phone, :input_html => { :class => 'span6' } %>
5
- <%= f.input :message, :as => :text, :input_html => { :class => 'span12' } %>
6
- <%= f.input :terms_of_service, :as => :boolean %>
2
+ <%= f.input :name, :input_html => { :class => Ecm::Contact::Configuration.input_name_css_classes } %>
3
+ <%= f.input :email, :input_html => { :class => Ecm::Contact::Configuration.input_email_css_classes } %>
4
+ <%= f.input :phone, :input_html => { :class => Ecm::Contact::Configuration.input_phone_css_classes } %>
5
+ <%= f.input :message, :as => :text, :input_html => { :class => Ecm::Contact::Configuration.input_message_css_classes } %>
6
+ <%= f.input :terms_of_service, :as => :boolean, :input_html => { :class => Ecm::Contact::Configuration.input_terms_of_service_css_classes } %>
7
7
 
8
8
  <div class="controls">
9
9
  <%= button_tag(:type => 'submit', :class => 'input btn btn-primary', :id => 'ecm_contact_request_submit') do %>
@@ -8,6 +8,20 @@ module Ecm
8
8
  def configure
9
9
  yield self
10
10
  end
11
+ mattr_accessor :input_name_css_classes
12
+ @@input_name_css_classes = nil
13
+
14
+ mattr_accessor :input_email_css_classes
15
+ @@input_email_css_classes = nil
16
+
17
+ mattr_accessor :input_phone_css_classes
18
+ @@input_phone_css_classes = nil
19
+
20
+ mattr_accessor :input_message_css_classes
21
+ @@input_message_css_classes = nil
22
+
23
+ mattr_accessor :input_terms_of_service_css_classes
24
+ @@input_terms_of_service_css_classes = nil
11
25
 
12
26
  mattr_accessor :recipients
13
27
  @@recipients = {}
@@ -1,5 +1,5 @@
1
1
  module Ecm
2
2
  module Contact
3
- VERSION = '1.0.3.pre'
3
+ VERSION = '1.0.4.pre'
4
4
  end
5
5
  end
@@ -3,8 +3,15 @@ Ecm::Contact.configure do |config|
3
3
  #
4
4
  # You can specify multiple recipients and multiple environments.
5
5
  config.recipients = {
6
- :development => %w( info@development.example.com ),
7
- :test => %w( info@test.example.com ),
8
- :production => %w( info@production.example.com )
6
+ :development => %w[ info@development.example.com ],
7
+ :test => %w[ info@test.example.com ],
8
+ :production => %w[ info@production.example.com ]
9
9
  }
10
+
11
+ # Configure your input field css classes here.
12
+ config.input_name_css_classes = 'span6'
13
+ config.input_email_css_classes = 'span6'
14
+ config.input_phone_css_classes = 'span6'
15
+ config.input_message_css_classes = 'span12'
16
+ config.input_terms_of_service_css_classes = ''
10
17
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ecm_contact
3
3
  version: !ruby/object:Gem::Version
4
- hash: 961915992
4
+ hash: 961915972
5
5
  prerelease: 6
6
6
  segments:
7
7
  - 1
8
8
  - 0
9
- - 3
9
+ - 4
10
10
  - pre
11
- version: 1.0.3.pre
11
+ version: 1.0.4.pre
12
12
  platform: ruby
13
13
  authors:
14
14
  - Roberto Vasquez Angel