simple_form_bootstrap3 0.3.3 → 0.3.4
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.
    
        checksums.yaml
    CHANGED
    
    | 
         @@ -1,7 +1,7 @@ 
     | 
|
| 
       1 
1 
     | 
    
         
             
            ---
         
     | 
| 
       2 
2 
     | 
    
         
             
            SHA1:
         
     | 
| 
       3 
     | 
    
         
            -
              metadata.gz:  
     | 
| 
       4 
     | 
    
         
            -
              data.tar.gz:  
     | 
| 
      
 3 
     | 
    
         
            +
              metadata.gz: 725a4c5ceb7e09aafd93b13edf45b8b18efeceea
         
     | 
| 
      
 4 
     | 
    
         
            +
              data.tar.gz: bb00d269b04df3d96cb6150460f1f212df0c0df0
         
     | 
| 
       5 
5 
     | 
    
         
             
            SHA512:
         
     | 
| 
       6 
     | 
    
         
            -
              metadata.gz:  
     | 
| 
       7 
     | 
    
         
            -
              data.tar.gz:  
     | 
| 
      
 6 
     | 
    
         
            +
              metadata.gz: 842bd2ada6aaec277889c21b889deb8dfa204b35e17be6af1b21f6e57daf5a0f31926881115524eea93f5de0f4fa5d573f55dccdf0ee5a66fc0b7d876aaa13e0
         
     | 
| 
      
 7 
     | 
    
         
            +
              data.tar.gz: 1456a0266c5023159a2b3d4410e226ddfef771429e0b26bbb91a582dba7c7a8d9a2b3de53ae828540b9756dd20b852fa6301552984e407523076ea427529bcbe
         
     | 
| 
         @@ -23,31 +23,39 @@ module SimpleForm 
     | 
|
| 
       23 
23 
     | 
    
         
             
                end
         
     | 
| 
       24 
24 
     | 
    
         | 
| 
       25 
25 
     | 
    
         
             
                def collection_check_boxes(method, collection, value_method, text_method, options = {}, html_options = {}, &block)
         
     | 
| 
       26 
     | 
    
         
            -
                  options[:collection_wrapper_tag]  
     | 
| 
       27 
     | 
    
         
            -
                  options[:collection_wrapper_class]  
     | 
| 
       28 
     | 
    
         
            -
                  options[: 
     | 
| 
       29 
     | 
    
         
            -
             
     | 
| 
      
 26 
     | 
    
         
            +
                  options[:collection_wrapper_tag] = :div unless options.key? :collection_wrapper_tag
         
     | 
| 
      
 27 
     | 
    
         
            +
                  options[:collection_wrapper_class] = 'form-group' unless options.key? :collection_wrapper_class
         
     | 
| 
      
 28 
     | 
    
         
            +
                  if options[:inline]
         
     | 
| 
      
 29 
     | 
    
         
            +
                    options[:item_wrapper_tag] = nil
         
     | 
| 
      
 30 
     | 
    
         
            +
                  else
         
     | 
| 
      
 31 
     | 
    
         
            +
                    options[:item_wrapper_tag] = :div unless options.key? :item_wrapper_tag
         
     | 
| 
      
 32 
     | 
    
         
            +
                    options[:item_wrapper_class] = 'checkbox' unless options.key? :item_wrapper_class
         
     | 
| 
      
 33 
     | 
    
         
            +
                  end
         
     | 
| 
       30 
34 
     | 
    
         | 
| 
       31 
35 
     | 
    
         
             
                  if block_given?
         
     | 
| 
       32 
36 
     | 
    
         
             
                    super
         
     | 
| 
       33 
37 
     | 
    
         
             
                  else
         
     | 
| 
       34 
38 
     | 
    
         
             
                    super do |input|
         
     | 
| 
       35 
     | 
    
         
            -
                      input.label { input.check_box + input.text }
         
     | 
| 
      
 39 
     | 
    
         
            +
                      input.label(options[:inline] ? { class: 'checkbox-inline' } : {} ) { input.check_box + input.text }
         
     | 
| 
       36 
40 
     | 
    
         
             
                    end
         
     | 
| 
       37 
41 
     | 
    
         
             
                  end
         
     | 
| 
       38 
42 
     | 
    
         
             
                end
         
     | 
| 
       39 
43 
     | 
    
         | 
| 
       40 
44 
     | 
    
         
             
                def collection_radio_buttons(method, collection, value_method, text_method, options = {}, html_options = {}, &block)
         
     | 
| 
       41 
     | 
    
         
            -
                  options[:collection_wrapper_tag]  
     | 
| 
       42 
     | 
    
         
            -
                  options[:collection_wrapper_class]  
     | 
| 
       43 
     | 
    
         
            -
                  options[: 
     | 
| 
       44 
     | 
    
         
            -
             
     | 
| 
      
 45 
     | 
    
         
            +
                  options[:collection_wrapper_tag] = :div unless options.key? :collection_wrapper_tag
         
     | 
| 
      
 46 
     | 
    
         
            +
                  options[:collection_wrapper_class] = 'form-group' unless options.key? :collection_wrapper_class
         
     | 
| 
      
 47 
     | 
    
         
            +
                  if options[:inline]
         
     | 
| 
      
 48 
     | 
    
         
            +
                    options[:item_wrapper_tag] = nil
         
     | 
| 
      
 49 
     | 
    
         
            +
                  else
         
     | 
| 
      
 50 
     | 
    
         
            +
                    options[:item_wrapper_tag] = :div unless options.key? :item_wrapper_tag
         
     | 
| 
      
 51 
     | 
    
         
            +
                    options[:item_wrapper_class] = 'radio' unless options.key? :item_wrapper_class
         
     | 
| 
      
 52 
     | 
    
         
            +
                  end
         
     | 
| 
       45 
53 
     | 
    
         | 
| 
       46 
54 
     | 
    
         
             
                  if block_given?
         
     | 
| 
       47 
55 
     | 
    
         
             
                    super
         
     | 
| 
       48 
56 
     | 
    
         
             
                  else
         
     | 
| 
       49 
57 
     | 
    
         
             
                    super do |input|
         
     | 
| 
       50 
     | 
    
         
            -
                      input.label { input.radio_button + input.text }
         
     | 
| 
      
 58 
     | 
    
         
            +
                      input.label(options[:inline] ? { class: 'radio-inline' } : {} ) { input.radio_button + input.text }
         
     | 
| 
       51 
59 
     | 
    
         
             
                    end
         
     | 
| 
       52 
60 
     | 
    
         
             
                  end
         
     | 
| 
       53 
61 
     | 
    
         
             
                end
         
     | 
| 
         @@ -14,11 +14,13 @@ module SimpleForm 
     | 
|
| 
       14 
14 
     | 
    
         
             
                end
         
     | 
| 
       15 
15 
     | 
    
         | 
| 
       16 
16 
     | 
    
         
             
                def collection_check_boxes(method, collection, value_method, text_method, options = {}, html_options = {}, &block)
         
     | 
| 
      
 17 
     | 
    
         
            +
                  raise ::ArgumentError, 'Inline is unsupported for horizontal form' if options.key? :inline
         
     | 
| 
       17 
18 
     | 
    
         
             
                  options[:item_wrapper_class] ||= 'col-sm-offset-3 col-sm-9 col-md-offset-3 col-md-9 col-lg-offset-2 col-lg-10 checkbox'
         
     | 
| 
       18 
19 
     | 
    
         
             
                  super
         
     | 
| 
       19 
20 
     | 
    
         
             
                end
         
     | 
| 
       20 
21 
     | 
    
         | 
| 
       21 
22 
     | 
    
         
             
                def collection_radio_buttons(method, collection, value_method, text_method, options = {}, html_options = {}, &block)
         
     | 
| 
      
 23 
     | 
    
         
            +
                  raise ::ArgumentError, 'Inline is unsupported for horizontal form' if options.key? :inline
         
     | 
| 
       22 
24 
     | 
    
         
             
                  options[:item_wrapper_class] ||= 'col-sm-offset-3 col-sm-9 col-md-offset-3 col-md-9 col-lg-offset-2 col-lg-10 radio'
         
     | 
| 
       23 
25 
     | 
    
         
             
                  super
         
     | 
| 
       24 
26 
     | 
    
         
             
                end
         
     | 
    
        metadata
    CHANGED
    
    | 
         @@ -1,14 +1,14 @@ 
     | 
|
| 
       1 
1 
     | 
    
         
             
            --- !ruby/object:Gem::Specification
         
     | 
| 
       2 
2 
     | 
    
         
             
            name: simple_form_bootstrap3
         
     | 
| 
       3 
3 
     | 
    
         
             
            version: !ruby/object:Gem::Version
         
     | 
| 
       4 
     | 
    
         
            -
              version: 0.3. 
     | 
| 
      
 4 
     | 
    
         
            +
              version: 0.3.4
         
     | 
| 
       5 
5 
     | 
    
         
             
            platform: ruby
         
     | 
| 
       6 
6 
     | 
    
         
             
            authors:
         
     | 
| 
       7 
7 
     | 
    
         
             
            - Yuriy Kolodovskyy
         
     | 
| 
       8 
8 
     | 
    
         
             
            autorequire: 
         
     | 
| 
       9 
9 
     | 
    
         
             
            bindir: bin
         
     | 
| 
       10 
10 
     | 
    
         
             
            cert_chain: []
         
     | 
| 
       11 
     | 
    
         
            -
            date: 2014-09- 
     | 
| 
      
 11 
     | 
    
         
            +
            date: 2014-09-16 00:00:00.000000000 Z
         
     | 
| 
       12 
12 
     | 
    
         
             
            dependencies:
         
     | 
| 
       13 
13 
     | 
    
         
             
            - !ruby/object:Gem::Dependency
         
     | 
| 
       14 
14 
     | 
    
         
             
              name: bootstrap-sass
         
     |