rails-bootstrap-widgets 0.0.1 → 0.0.2

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,4 +1,4 @@
1
- Copyright 2013 YOURNAME
1
+ Copyright 2013 Andrew Kozin, andrew.kozin@gmail.com
2
2
 
3
3
  Permission is hereby granted, free of charge, to any person obtaining
4
4
  a copy of this software and associated documentation files (the
data/README.md CHANGED
@@ -1,4 +1,4 @@
1
- # About [![Build Status](https://travis-ci.org/nepalez/widgets.png?branch=master)](https://travis-ci.org/nepalez/rails-bootstrap-widgets)
1
+ # About [![Build Status](https://travis-ci.org/nepalez/rails-bootstrap-widgets.png)](https://travis-ci.org/nepalez/rails-bootstrap-widgets) [![Dependency Status](https://gemnasium.com/nepalez/rails-bootstrap-widgets.png)](https://gemnasium.com/nepalez/rails-bootstrap-widgets) [![Code Climate](https://codeclimate.com/github/nepalez/rails-bootstrap-widgets.png)](https://codeclimate.com/github/nepalez/rails-bootstrap-widgets) [![Coverage Status](https://coveralls.io/repos/nepalez/rails-bootstrap-widgets/badge.png)](https://coveralls.io/r/nepalez/rails-bootstrap-widgets)
2
2
 
3
3
  The project defines a collection of widgets to be used inside views. It also contains some js files to provide additional behavior for html elemets, created by those widgets. Both helpers and js are compatible with Twitter Bootstrap framework.
4
4
 
@@ -23,15 +23,15 @@ This group consists of two widgets to be used in views that contain items lists.
23
23
  ```Ruby
24
24
  pagination_widget(items, options = {})
25
25
  ```
26
- The widget simply wraps pager (from the ```will-paginate``` gem) into the aside tag with some class.
26
+ The widget simply wraps pager (from the ```will-paginate``` gem) into the ```<aside>``` tag.
27
27
  #### Example
28
28
  ```Ruby
29
- pagination_widget @items, class: 'pagination-top'
29
+ pagination_widget @items, class: 'span4'
30
30
  ```
31
31
  This will create
32
32
  ```Html
33
- <aside class="pagination-top">
34
- <!-- Standard result of 'will_paginate(items, inner_window: 0, outer_window: 0)' call -->
33
+ <aside class="span4">
34
+ <!-- Standard result of 'will_paginate(@items, inner_window: 0, outer_window: 0)' call -->
35
35
  </aside>
36
36
  ```
37
37
  ### filters_widget (helper method)
@@ -217,4 +217,4 @@ showModal('<%= post_path(@item) %>', "<%= j render 'modal/show' %>")
217
217
  5. Create new Pull Request
218
218
 
219
219
  # License
220
- This project rocks and uses MIT-LICENSE.
220
+ This project rocks and uses <a href='MIT-LICENSE'>MIT-LICENSE</a>.
@@ -1,58 +1,127 @@
1
1
  # encoding: utf-8
2
2
  module RailsBootstrapWidgets
3
- module FiltersHelper
4
-
5
- def pagination_widget(items, options = {})
6
- if items.present?
7
- content_tag(:aside, (options[:class].to_s.present? ? { class: options[:class] } : {})) do
8
- will_paginate(items, inner_window: 0, outer_window: 0).html_safe
9
- end
10
- end
11
- end
12
-
13
- def filters_widget(items, options = {})
14
- if (options = _prepare(options)).present?
15
- form_tag(url_for("/"), method: :get, id: :filters, class: :span8) do
16
- (_selector(:filter, options[:filters], options[:filter]) << _selector(:order, options[:orders], options[:order]) << _reset << _reload).html_safe
17
- end
3
+ module FiltersHelper
4
+
5
+ # To add pager to a view call <tt>pagination_widget(items, options = {})</tt> with parameters:
6
+ #
7
+ # pagination_widget items, class: 'class name'
8
+ #
9
+ # This will simply wrap standard pagination from the 'will-paginate' gem into <tt><aside class='class name'></tt> tag
10
+ #
11
+ # <aside class='class name'>
12
+ # <!-- Standard result of 'will_paginate(items, inner_window: 0, outer_window: 0)' call -->
13
+ # </aside>
14
+ def pagination_widget(items, options = {})
15
+ if items.present?
16
+ content_tag(:aside, (options[:class].to_s.present? ? { class: options[:class] } : {})) do
17
+ will_paginate(items, inner_window: 0, outer_window: 0).html_safe
18
+ end
19
+ end
20
+ end
21
+
22
+ # To create html header for filtering, ordering and paging a list of items call <tt>filters_widget(items, options = {})</tt> with parameters:
23
+ #
24
+ # filters_widget (
25
+ # @items, # list of items (required)
26
+ # filters: { published: :Published, unpublished: :Unpublished}, # list of filters to select from in a format { key: :name }
27
+ # filter: 'published', # key of the current filter to apply to items
28
+ # orders: { tree: :Tree, feed: :Feed }, # list of types of items ordering to select from
29
+ # order: 'tree' # key of the current order type
30
+ # )
31
+ #
32
+ # This will provide html, that contains:
33
+ # 1. Input field to select filter from those are available
34
+ # 2. Input field to select order from those are available
35
+ # 3. Hidden button to reset filter values (it will authomatically displayed via js)
36
+ # 4. Button to reload the page with new filter values (it will authomatically removed via js)
37
+ # 5. Items pager
38
+ #
39
+ # <b>Use only one such a call on the page</p>
40
+ #
41
+ # For example, the call of the code above will provide html:
42
+ #
43
+ # <form accept-charset="UTF-8" action="/" class="span8" id="filters" method="get">
44
+ # <div style="margin:0;padding:0;display:inline">
45
+ # <input name="utf8" type="hidden" value="&#x2713;" />
46
+ # </div>
47
+ # <div class="input-prepend">
48
+ # <span class="add-on">
49
+ # <i class="icon-filter"></i>
50
+ # </span>
51
+ # <select id="filter" name="filter">
52
+ # <option value="published" selected="selected">Published</option>
53
+ # <option value="unpublished">Unpublished</option>
54
+ # </select>
55
+ # </div>
56
+ # <div class="input-prepend">
57
+ # <span class="add-on">
58
+ # <i class="icon-order"></i>
59
+ # </span>
60
+ # <select id="order" name="order">
61
+ # <option value="tree" selected="selected">Tree</option>
62
+ # <option value="feed">Feed</option>
63
+ # </select>
64
+ # </div>
65
+ # <a href="#" class="btn add-on hide" id="reset">
66
+ # <i class="icon-reset"></i>
67
+ # </a>
68
+ # <div class="input-prepend" id="reload">
69
+ # <span class="add-on">
70
+ # <i class="icon-reload"></i>
71
+ # </span>
72
+ # <input class="btn" name="commit" type="submit" value="Reload" />
73
+ # </div>
74
+ # </form>
75
+ # <aside class="span4">
76
+ # <!-- Standard result of 'will_paginate(items, inner_window: 0, outer_window: 0)' call -->
77
+ # </aside>
78
+ #
79
+ # This code provides basic html functionality for browsers with js suppord disabled.
80
+ # For those with js support is enabled, the file <tt>app/assets/javascripts/rails-bootstrap-widgets/filters.js.coffee</tt> turns on extended ajax behavior.
81
+ def filters_widget(items, options = {})
82
+ if (options = _prepare(options)).present?
83
+ form_tag(url_for("/"), method: :get, id: :filters, class: :span8) do
84
+ (_selector(:filter, options[:filters], options[:filter]) << _selector(:order, options[:orders], options[:order]) << _reset << _reload).html_safe
85
+ end
18
86
  else
19
- ""
20
- end << pagination_widget(items, class: :span4)
21
- end
22
-
23
- private
24
-
25
- def _prepare(options = {})
26
- _options = {}
27
- _options.merge!({ filters: options[:filters], filter: options[:filter].to_s }) if _consistent?(options[:filters], options[:filter])
28
- _options.merge!({ orders: options[:orders], order: options[:order].to_s }) if _consistent?(options[:orders], options[:order])
29
- return _options
30
- end
31
-
32
- def _consistent?(list, item)
33
- list.class == Hash && item.to_s.present? && list.keys.collect{ |key| key.to_s }.include?(item.to_s)
34
- end
35
-
36
- def _selector(type, list, item)
37
- if list
38
- content_tag(:div, class: "input-prepend") do
39
- content_tag(:span, class: "add-on") { "<i class=\"icon-#{ type }\"></i>".html_safe } <<
40
- select_tag(type, options_for_select(list.to_a.collect{ |i| i.reverse }, item))
41
- end
42
- else
43
- ""
44
- end
45
- end
46
-
47
- def _reset
48
- link_to("<i class=\"icon-reset\"></i>".html_safe, '#', class: "btn add-on hide", id: :reset)
49
- end
50
-
51
- def _reload
52
- content_tag(:div, id: :reload, class: "input-prepend") do
53
- content_tag(:span, class: "add-on") { "<i class=\"icon-reload\"></i>".html_safe } <<
54
- submit_tag(I18n.t("buttons.reload"), class: "btn")
55
- end
56
- end
57
- end
87
+ ""
88
+ end << pagination_widget(items, class: :span4)
89
+ end
90
+
91
+ private
92
+
93
+ def _prepare(options = {})
94
+ _check(_check(options, :filters, :filter), :orders, :order)
95
+ end
96
+
97
+ def _check(options, key_list, key_item)
98
+ if (options[key_list].class != Hash && options[key_item].to_s.blank?) || !options[key_list].keys.collect{ |key| key.to_s }.include?(options[key_item].to_s)
99
+ options.delete(key_list)
100
+ options.delete(key_item)
101
+ end
102
+ options
103
+ end
104
+
105
+ def _selector(type, list, item)
106
+ if list
107
+ content_tag(:div, class: "input-prepend") do
108
+ content_tag(:span, class: "add-on") { "<i class=\"icon-#{ type }\"></i>".html_safe } <<
109
+ select_tag(type, options_for_select(list.to_a.collect{ |i| i.reverse }, item))
110
+ end
111
+ else
112
+ ""
113
+ end
114
+ end
115
+
116
+ def _reset
117
+ link_to("<i class=\"icon-reset\"></i>".html_safe, '#', class: "btn add-on hide", id: :reset)
118
+ end
119
+
120
+ def _reload
121
+ content_tag(:div, id: :reload, class: "input-prepend") do
122
+ content_tag(:span, class: "add-on") { "<i class=\"icon-reload\"></i>".html_safe } <<
123
+ submit_tag(I18n.t("buttons.reload"), class: "btn")
124
+ end
125
+ end
126
+ end
58
127
  end
@@ -1,61 +1,128 @@
1
1
  # encoding: utf-8
2
2
  module RailsBootstrapWidgets
3
- module ModalHelper
4
-
5
- def modal_form_widget(options = {}, &block)
6
- if (options = _prepare(options, :form)) && (content = block_given? ? capture(&block) : nil)
7
- form_tag(options[:action], method: :post, id: "modal", class: "modal fade", remote: true) do
8
- (_hidden(options[:method]) << _header(options[:title]) << _body(content) << _footer(:submit, options[:button], options[:cancel])).html_safe
9
- end
10
- else
11
- ''
12
- end
13
- end
14
-
15
- def modal_view_widget(options = {}, &block)
16
- content = block_given? ? capture(&block) : nil
17
- if (options = _prepare(options, :view)) && content
18
- content_tag(:div, id: "modal", class: "modal fade") do
19
- (_header(options[:title]) << _body(content) << _footer(:button, options[:button], options[:cancel], options[:href], options[:redirect])).html_safe
20
- end
21
- else
22
- ''
23
- end
24
- end
25
-
26
- private
27
-
28
- def _prepare(options, type)
29
- if (options.class == Hash) && %w(form view).include?(type.to_s)
30
- options[:redirect] = true unless options[:redirect] == false
31
- options[:method] = 'post' unless %w(get put delete).include?(options[:method].to_s)
32
- options[:cancel] ||= I18n.t('buttons.cancel')
33
- options[:button] ||= (type == :form ? I18n.t('buttons.submit') : I18n.t('buttons.details'))
34
- return options if options[:title].present? && (((type == :view) && options[:href].present?) || ((type == :form) && options[:action].present? && options[:cancel].present?))
35
- end
36
- return nil
37
- end
38
-
39
- def _hidden(method)
40
- method.to_s == "post" ? "" : hidden_field_tag(:_method, method.to_s)
41
- end
42
-
43
- def _header(title)
44
- content_tag(:header, class: 'modal-header') do
45
- button_tag(type: :button, class: :close, "data-dismiss" => :modal, "aria-hidden" => 'true') { "\&times;".html_safe } <<
46
- content_tag(:h1, title)
47
- end
48
- end
49
-
50
- def _body(content)
51
- content_tag(:div, class: "modal-body") { content }
52
- end
53
-
54
- def _footer(type, button, cancel, href = nil, redirect = true)
55
- content_tag(:div, class: 'modal-footer') do
56
- link_to(cancel, "#", class: "btn", "data-dismiss" => "modal", "aria-hidden" => "true") <<
57
- (type == :submit ? submit_tag(button, id: :submit, class: "btn btn-primary") : (redirect ? link_to(button, href, class: "btn btn-primary") : ""))
58
- end
59
- end
60
- end
3
+ module ModalHelper
4
+
5
+ # To create modal form in a view, put your fields into <tt>modal_form_widget(options = {}, &block)</tt>.
6
+ #
7
+ # modal_form_widget (
8
+ # title: 'modal window title', # required
9
+ # action: 'path to corresponding route', # required
10
+ # method: 'request method for the form', # "post" by default, "post", "get", "put" or "delete" extected
11
+ # button: 'text on the submit button', # I18n.t("buttons.submit") by default
12
+ # cancel: 'text on the cancel form button' # I18n.t("buttons.cancel") by default
13
+ # ) { "" } # html code of form fields
14
+ #
15
+ # The widget puts a list of fields (inputs, selectors etc.) into a modal form window (presented by <tt><form id='modal' class='modal fade'...></tt>)
16
+ # For example, the call
17
+ #
18
+ # modal_form_widget(title: 'Title', button: 'Button', method: :put, action: '/some_addr', cancel: "Cancel") { "content" }
19
+ #
20
+ # Will provide html:
21
+ #
22
+ # <form accept-charset="UTF-8" action="/some_addr" class="modal fade" data-remote="true" id="modal" method="post">
23
+ # <div style="margin:0;padding:0;display:inline">
24
+ # <input name="utf8" type="hidden" value="&#x2713;" />
25
+ # </div>
26
+ # <input id="_method" name="_method" type="hidden" value="put" />
27
+ # <header class="modal-header">
28
+ # <button aria-hidden="true" class="close" data-dismiss="modal" type="button">&times;</button>
29
+ # <h1>Title</h1>
30
+ # </header>
31
+ # <div class="modal-body">content</div>
32
+ # <div class="modal-footer">
33
+ # <a href="#" aria-hidden="true" class="btn" data-dismiss="modal">Cancel</a>
34
+ # <input class="btn btn-primary" id="submit" name="commit" type="submit" value="Button" />
35
+ # </div>
36
+ # </form>
37
+ def modal_form_widget(options = {}, &block)
38
+ if (options = _prepare(options, :form)) && (content = block_given? ? capture(&block) : nil)
39
+ form_tag(options[:action], method: :post, id: "modal", class: "modal fade", remote: true) do
40
+ (_hidden(options[:method]) << _header(options[:title]) << _body(content) << _footer(:submit, options[:button], options[:cancel])).html_safe
41
+ end
42
+ else
43
+ ''
44
+ end
45
+ end
46
+
47
+ # To create modal window in a view, put its content into <tt>modal_view_widget(options = {}, &block)</tt>.
48
+ #
49
+ # modal_view_widget (
50
+ # title: 'modal window title', # required
51
+ # href: 'path for redirection to details', # required
52
+ # redirect: true|false, # whether redirect button should be shown in the modal window footer (true by default),
53
+ # button: 'text on the redirect button', # I18n.t("buttons.details") by default
54
+ # cancel: 'text on the cancel form button' # I18n.t("buttons.cancel") by default
55
+ # ) { "" } # html code of form fields
56
+ #
57
+ # The widget puts html code into a modal window (presented by <tt><div id='modal' class='modal fade'></tt>)
58
+ # For example, the call
59
+ #
60
+ # modal_view_widget(title: 'Title', button: 'Button', href: '/some_addr', cancel: "Cancel") { "content" }
61
+ #
62
+ # Will provide html:
63
+ #
64
+ # <div class="modal fade" id="modal">
65
+ # <header class="modal-header">
66
+ # <button aria-hidden="true" class="close" data-dismiss="modal" type="button">&times;</button>
67
+ # <h1>Title</h1>
68
+ # </header>
69
+ # <div class="modal-body">content</div>
70
+ # <div class="modal-footer">
71
+ # <a href="#" aria-hidden="true" class="btn" data-dismiss="modal">Cancel</a>
72
+ # <a href="/some_addr" class="btn btn-primary">Button</a>
73
+ # </div>
74
+ # </div>
75
+ def modal_view_widget(options = {}, &block)
76
+ content = block_given? ? capture(&block) : nil
77
+ if (options = _prepare(options, :view)) && content
78
+ content_tag(:div, id: "modal", class: "modal fade") do
79
+ (_header(options[:title]) << _body(content) << _footer(:button, options[:button], options[:cancel], options[:href], options[:redirect])).html_safe
80
+ end
81
+ else
82
+ ''
83
+ end
84
+ end
85
+
86
+ private
87
+
88
+ def _prepare(options, type)
89
+ if (options.class == Hash) && %w(form view).include?(type.to_s) && options[:title].present?
90
+ options[:redirect] = true unless options[:redirect] == false
91
+ options[:method] = 'post' unless %w(get put delete).include?(options[:method].to_s)
92
+ options[:cancel] ||= I18n.t('buttons.cancel')
93
+ options[:button] ||= (type == :form ? I18n.t('buttons.submit') : I18n.t('buttons.details'))
94
+ _filter(options, type)
95
+ end
96
+ end
97
+
98
+ def _filter(options, type)
99
+ if type == :view
100
+ options[:href].present? ? options : nil
101
+ else
102
+ options[:action].present? && options[:cancel].present? ? options : nil
103
+ end
104
+ end
105
+
106
+ def _hidden(method)
107
+ method.to_s == "post" ? "" : hidden_field_tag(:_method, method.to_s)
108
+ end
109
+
110
+ def _header(title)
111
+ content_tag(:header, class: 'modal-header') do
112
+ button_tag(type: :button, class: :close, "data-dismiss" => :modal, "aria-hidden" => 'true') { "\&times;".html_safe } <<
113
+ content_tag(:h1, title)
114
+ end
115
+ end
116
+
117
+ def _body(content)
118
+ content_tag(:div, class: "modal-body") { content }
119
+ end
120
+
121
+ def _footer(type, button, cancel, href = nil, redirect = true)
122
+ content_tag(:div, class: 'modal-footer') do
123
+ link_to(cancel, "#", class: "btn", "data-dismiss" => "modal", "aria-hidden" => "true") <<
124
+ (type == :submit ? submit_tag(button, id: :submit, class: "btn btn-primary") : (redirect ? link_to(button, href, class: "btn btn-primary") : ""))
125
+ end
126
+ end
127
+ end
61
128
  end
@@ -1,3 +1,3 @@
1
1
  module RailsBootstrapWidgets
2
- VERSION = "0.0.1"
2
+ VERSION = "0.0.2"
3
3
  end
@@ -45,3 +45,145 @@ Connecting to database specified by database.yml
45
45
   (0.0ms) rollback transaction
46
46
   (0.0ms) begin transaction
47
47
   (0.0ms) rollback transaction
48
+ Connecting to database specified by database.yml
49
+ Connecting to database specified by database.yml
50
+  (0.0ms) begin transaction
51
+  (0.0ms) rollback transaction
52
+  (0.0ms) begin transaction
53
+  (0.0ms) rollback transaction
54
+  (0.0ms) begin transaction
55
+  (0.0ms) rollback transaction
56
+  (0.0ms) begin transaction
57
+  (0.0ms) rollback transaction
58
+  (0.0ms) begin transaction
59
+  (0.0ms) rollback transaction
60
+  (0.0ms) begin transaction
61
+  (0.0ms) rollback transaction
62
+  (0.0ms) begin transaction
63
+  (0.0ms) rollback transaction
64
+  (0.0ms) begin transaction
65
+  (0.0ms) rollback transaction
66
+  (0.0ms) begin transaction
67
+  (0.0ms) rollback transaction
68
+  (0.0ms) begin transaction
69
+  (0.0ms) rollback transaction
70
+  (0.0ms) begin transaction
71
+  (1.0ms) rollback transaction
72
+  (0.0ms) begin transaction
73
+  (0.0ms) rollback transaction
74
+  (0.0ms) begin transaction
75
+  (0.0ms) rollback transaction
76
+  (0.0ms) begin transaction
77
+  (0.0ms) rollback transaction
78
+  (0.0ms) begin transaction
79
+  (0.0ms) rollback transaction
80
+  (0.0ms) begin transaction
81
+  (0.0ms) rollback transaction
82
+  (0.0ms) begin transaction
83
+  (0.0ms) rollback transaction
84
+  (0.0ms) begin transaction
85
+  (0.0ms) rollback transaction
86
+  (0.0ms) begin transaction
87
+  (0.0ms) rollback transaction
88
+  (0.0ms) begin transaction
89
+  (0.0ms) rollback transaction
90
+  (0.0ms) begin transaction
91
+  (0.0ms) rollback transaction
92
+  (0.0ms) begin transaction
93
+  (0.0ms) rollback transaction
94
+  (0.0ms) begin transaction
95
+  (0.0ms) rollback transaction
96
+ Connecting to database specified by database.yml
97
+  (0.0ms) begin transaction
98
+  (0.0ms) rollback transaction
99
+  (1.0ms) begin transaction
100
+  (0.0ms) rollback transaction
101
+  (0.0ms) begin transaction
102
+  (1.0ms) rollback transaction
103
+  (0.0ms) begin transaction
104
+  (0.0ms) rollback transaction
105
+  (0.0ms) begin transaction
106
+  (0.0ms) rollback transaction
107
+  (0.0ms) begin transaction
108
+  (0.0ms) rollback transaction
109
+  (0.0ms) begin transaction
110
+  (0.0ms) rollback transaction
111
+  (0.0ms) begin transaction
112
+  (0.0ms) rollback transaction
113
+  (0.0ms) begin transaction
114
+  (0.0ms) rollback transaction
115
+  (0.0ms) begin transaction
116
+  (0.0ms) rollback transaction
117
+  (0.0ms) begin transaction
118
+  (0.0ms) rollback transaction
119
+  (0.0ms) begin transaction
120
+  (0.0ms) rollback transaction
121
+  (0.0ms) begin transaction
122
+  (0.0ms) rollback transaction
123
+  (0.0ms) begin transaction
124
+  (0.0ms) rollback transaction
125
+  (0.0ms) begin transaction
126
+  (0.0ms) rollback transaction
127
+  (0.0ms) begin transaction
128
+  (0.0ms) rollback transaction
129
+  (0.0ms) begin transaction
130
+  (0.0ms) rollback transaction
131
+  (0.0ms) begin transaction
132
+  (0.0ms) rollback transaction
133
+  (0.0ms) begin transaction
134
+  (0.0ms) rollback transaction
135
+  (0.0ms) begin transaction
136
+  (0.0ms) rollback transaction
137
+  (0.0ms) begin transaction
138
+  (0.0ms) rollback transaction
139
+  (0.0ms) begin transaction
140
+  (0.0ms) rollback transaction
141
+  (0.0ms) begin transaction
142
+  (0.0ms) rollback transaction
143
+ Connecting to database specified by database.yml
144
+  (1.0ms) begin transaction
145
+  (0.0ms) rollback transaction
146
+  (0.0ms) begin transaction
147
+  (0.0ms) rollback transaction
148
+  (0.0ms) begin transaction
149
+  (0.0ms) rollback transaction
150
+  (0.0ms) begin transaction
151
+  (0.0ms) rollback transaction
152
+  (0.0ms) begin transaction
153
+  (0.0ms) rollback transaction
154
+  (0.0ms) begin transaction
155
+  (0.0ms) rollback transaction
156
+  (0.0ms) begin transaction
157
+  (1.0ms) rollback transaction
158
+  (0.0ms) begin transaction
159
+  (0.0ms) rollback transaction
160
+  (0.0ms) begin transaction
161
+  (0.0ms) rollback transaction
162
+  (0.0ms) begin transaction
163
+  (0.0ms) rollback transaction
164
+  (0.0ms) begin transaction
165
+  (0.0ms) rollback transaction
166
+  (0.0ms) begin transaction
167
+  (0.0ms) rollback transaction
168
+  (0.0ms) begin transaction
169
+  (0.0ms) rollback transaction
170
+  (0.0ms) begin transaction
171
+  (0.0ms) rollback transaction
172
+  (0.0ms) begin transaction
173
+  (0.0ms) rollback transaction
174
+  (0.0ms) begin transaction
175
+  (0.0ms) rollback transaction
176
+  (0.0ms) begin transaction
177
+  (0.0ms) rollback transaction
178
+  (0.0ms) begin transaction
179
+  (0.0ms) rollback transaction
180
+  (0.0ms) begin transaction
181
+  (0.0ms) rollback transaction
182
+  (0.0ms) begin transaction
183
+  (0.0ms) rollback transaction
184
+  (0.0ms) begin transaction
185
+  (0.0ms) rollback transaction
186
+  (0.0ms) begin transaction
187
+  (0.0ms) rollback transaction
188
+  (0.0ms) begin transaction
189
+  (0.0ms) rollback transaction
@@ -1,3 +1,6 @@
1
+ require 'coveralls'
2
+ Coveralls.wear!('rails')
3
+
1
4
  # This file is copied to spec/ when you run 'rails generate rspec:install'
2
5
  ENV["RAILS_ENV"] ||= 'test'
3
6
  require File.expand_path("../dummy/config/environment.rb", __FILE__)
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rails-bootstrap-widgets
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.0.2
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2013-06-08 00:00:00.000000000 Z
12
+ date: 2013-06-10 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: rails
@@ -188,39 +188,39 @@ dependencies:
188
188
  - !ruby/object:Gem::Version
189
189
  version: '0'
190
190
  - !ruby/object:Gem::Dependency
191
- name: sqlite3
191
+ name: rspec-rails
192
192
  requirement: !ruby/object:Gem::Requirement
193
193
  none: false
194
194
  requirements:
195
- - - ! '>='
195
+ - - ~>
196
196
  - !ruby/object:Gem::Version
197
- version: '0'
197
+ version: 2.11.0
198
198
  type: :development
199
199
  prerelease: false
200
200
  version_requirements: !ruby/object:Gem::Requirement
201
201
  none: false
202
202
  requirements:
203
- - - ! '>='
203
+ - - ~>
204
204
  - !ruby/object:Gem::Version
205
- version: '0'
205
+ version: 2.11.0
206
206
  - !ruby/object:Gem::Dependency
207
- name: rspec-rails
207
+ name: sqlite3
208
208
  requirement: !ruby/object:Gem::Requirement
209
209
  none: false
210
210
  requirements:
211
- - - ~>
211
+ - - ! '>='
212
212
  - !ruby/object:Gem::Version
213
- version: 2.11.0
213
+ version: '0'
214
214
  type: :development
215
215
  prerelease: false
216
216
  version_requirements: !ruby/object:Gem::Requirement
217
217
  none: false
218
218
  requirements:
219
- - - ~>
219
+ - - ! '>='
220
220
  - !ruby/object:Gem::Version
221
- version: 2.11.0
221
+ version: '0'
222
222
  - !ruby/object:Gem::Dependency
223
- name: rails3-generators
223
+ name: coveralls
224
224
  requirement: !ruby/object:Gem::Requirement
225
225
  none: false
226
226
  requirements:
@@ -304,7 +304,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
304
304
  version: '0'
305
305
  segments:
306
306
  - 0
307
- hash: -363547011
307
+ hash: 488228417
308
308
  required_rubygems_version: !ruby/object:Gem::Requirement
309
309
  none: false
310
310
  requirements:
@@ -313,7 +313,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
313
313
  version: '0'
314
314
  segments:
315
315
  - 0
316
- hash: -363547011
316
+ hash: 488228417
317
317
  requirements: []
318
318
  rubyforge_project:
319
319
  rubygems_version: 1.8.24