tj_bootstrap_helper 0.0.9 → 0.1.0

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,29 +1,27 @@
1
- if defined?(WillPaginate)
2
- module WillPaginate
3
- module ActionView
4
- def will_paginate(collection = nil, options = {})
5
- options[:renderer] ||= BootstrapLinkRenderer
6
- super(collection, options).try(:html_safe)
7
- end
1
+ module WillPaginate
2
+ module ActionView
3
+ def will_paginate(collection = nil, options = {})
4
+ options[:renderer] ||= BootstrapLinkRenderer
5
+ super(collection, options).try(:html_safe)
6
+ end
8
7
 
9
- class BootstrapLinkRenderer < LinkRenderer
10
- protected
8
+ class BootstrapLinkRenderer < LinkRenderer
9
+ protected
11
10
 
12
- def html_container(html)
13
- tag :div, tag(:ul, html), container_attributes
14
- end
11
+ def html_container(html)
12
+ tag :div, tag(:ul, html), container_attributes
13
+ end
15
14
 
16
- def page_number(page)
17
- tag :li, link(page, page, :rel => rel_value(page)), :class => ('active' if page == current_page)
18
- end
15
+ def page_number(page)
16
+ tag :li, link(page, page, :rel => rel_value(page)), :class => ('active' if page == current_page)
17
+ end
19
18
 
20
- def previous_or_next_page(page, text, classname)
21
- tag :li, link(text, page || '#'), :class => [classname[0..3], classname, ('disabled' unless page)].join(' ')
22
- end
19
+ def previous_or_next_page(page, text, classname)
20
+ tag :li, link(text, page || '#'), :class => [classname[0..3], classname, ('disabled' unless page)].join(' ')
21
+ end
23
22
 
24
- def gap
25
- tag :li, link(super, '#'), :class => 'disabled'
26
- end
23
+ def gap
24
+ tag :li, link(super, '#'), :class => 'disabled'
27
25
  end
28
26
  end
29
27
  end
@@ -1,7 +1,7 @@
1
1
  require "tj_bootstrap_helper/version"
2
- require "tj_bootstrap_helper/helper"
3
2
 
4
3
  module TJBootstrapHelper
5
- class Engine < Rails::Engine
4
+ module Rails
5
+ require "tj_bootstrap_helper/engine"
6
6
  end
7
7
  end
@@ -0,0 +1,8 @@
1
+ require "tj_bootstrap_helper/helper"
2
+
3
+ module TJBootstrapHelper
4
+ module Rails
5
+ class Engine < ::Rails::Engine
6
+ end
7
+ end
8
+ end
@@ -105,6 +105,6 @@ module TJBootstrapHelper
105
105
  end
106
106
  ret
107
107
  end
108
+ ::ActionView::Base.send :include, self
108
109
  end
109
- end
110
- ActionView::Base.send :include, TJBootstrapHelper::Helper
110
+ end
@@ -1,3 +1,3 @@
1
1
  module TJBootstrapHelper
2
- VERSION = "0.0.9"
2
+ VERSION = "0.1.0"
3
3
  end
@@ -16525,3 +16525,159 @@ ActionController::RoutingError (No route matches [GET] "/assets/ico/favicon.ico"
16525
16525
 
16526
16526
 
16527
16527
  Rendered C:/Ruby193/lib/ruby/gems/1.9.1/gems/actionpack-3.2.6/lib/action_dispatch/middleware/templates/rescues/routing_error.erb within rescues/layout (19.5ms)
16528
+ Connecting to database specified by database.yml
16529
+ Connecting to database specified by database.yml
16530
+ Connecting to database specified by database.yml
16531
+ Connecting to database specified by database.yml
16532
+ Connecting to database specified by database.yml
16533
+ Connecting to database specified by database.yml
16534
+
16535
+
16536
+ Started GET "/" for 127.0.0.1 at 2012-07-26 08:23:13 +0800
16537
+ Connecting to database specified by database.yml
16538
+ Processing by HomeController#index as HTML
16539
+  (1.0ms) SELECT COUNT(*) FROM "posts" 
16540
+ Post Load (0.0ms) SELECT "posts".* FROM "posts" LIMIT 12 OFFSET 0
16541
+ Rendered home/index.html.erb within layouts/application (413.1ms)
16542
+ Rendered home/_topbar.html.erb (2.0ms)
16543
+ Rendered home/_sidebar.html.erb (1.0ms)
16544
+ Completed 200 OK in 800ms (Views: 760.7ms | ActiveRecord: 33.2ms)
16545
+
16546
+
16547
+ Started GET "/assets/jquery.js?body=1" for 127.0.0.1 at 2012-07-26 08:23:16 +0800
16548
+ Served asset /jquery.js - 200 OK (95ms)
16549
+
16550
+
16551
+ Started GET "/assets/bootstrap-responsive.min.css?body=1" for 127.0.0.1 at 2012-07-26 08:23:16 +0800
16552
+ Served asset /bootstrap-responsive.min.css - 200 OK (2ms)
16553
+
16554
+
16555
+ Started GET "/assets/application.css?body=1" for 127.0.0.1 at 2012-07-26 08:23:16 +0800
16556
+ Served asset /application.css - 200 OK (33ms)
16557
+
16558
+
16559
+ Started GET "/assets/jquery_ujs.js?body=1" for 127.0.0.1 at 2012-07-26 08:23:16 +0800
16560
+ Served asset /jquery_ujs.js - 200 OK (22ms)
16561
+
16562
+
16563
+ Started GET "/assets/bootstrap.min.css?body=1" for 127.0.0.1 at 2012-07-26 08:23:16 +0800
16564
+ Served asset /bootstrap.min.css - 200 OK (21ms)
16565
+
16566
+
16567
+ Started GET "/assets/bootstrap.min.js?body=1" for 127.0.0.1 at 2012-07-26 08:23:16 +0800
16568
+ Served asset /bootstrap.min.js - 200 OK (27ms)
16569
+
16570
+
16571
+ Started GET "/assets/home.js?body=1" for 127.0.0.1 at 2012-07-26 08:23:16 +0800
16572
+ Served asset /home.js - 200 OK (2ms)
16573
+
16574
+
16575
+ Started GET "/assets/application.js?body=1" for 127.0.0.1 at 2012-07-26 08:23:16 +0800
16576
+ Served asset /application.js - 200 OK (91ms)
16577
+
16578
+
16579
+ Started GET "/assets/glyphicons-halflings.png" for 127.0.0.1 at 2012-07-26 08:23:17 +0800
16580
+ Served asset /glyphicons-halflings.png - 200 OK (0ms)
16581
+
16582
+
16583
+ Started GET "/assets/ico/favicon.ico" for 127.0.0.1 at 2012-07-26 08:23:17 +0800
16584
+ Served asset /ico/favicon.ico - 404 Not Found (2ms)
16585
+
16586
+ ActionController::RoutingError (No route matches [GET] "/assets/ico/favicon.ico"):
16587
+ actionpack (3.2.6) lib/action_dispatch/middleware/debug_exceptions.rb:21:in `call'
16588
+ actionpack (3.2.6) lib/action_dispatch/middleware/show_exceptions.rb:56:in `call'
16589
+ railties (3.2.6) lib/rails/rack/logger.rb:26:in `call_app'
16590
+ railties (3.2.6) lib/rails/rack/logger.rb:16:in `call'
16591
+ actionpack (3.2.6) lib/action_dispatch/middleware/request_id.rb:22:in `call'
16592
+ rack (1.4.1) lib/rack/methodoverride.rb:21:in `call'
16593
+ rack (1.4.1) lib/rack/runtime.rb:17:in `call'
16594
+ activesupport (3.2.6) lib/active_support/cache/strategy/local_cache.rb:72:in `call'
16595
+ rack (1.4.1) lib/rack/lock.rb:15:in `call'
16596
+ actionpack (3.2.6) lib/action_dispatch/middleware/static.rb:62:in `call'
16597
+ railties (3.2.6) lib/rails/engine.rb:479:in `call'
16598
+ railties (3.2.6) lib/rails/application.rb:220:in `call'
16599
+ rack (1.4.1) lib/rack/content_length.rb:14:in `call'
16600
+ railties (3.2.6) lib/rails/rack/log_tailer.rb:17:in `call'
16601
+ rack (1.4.1) lib/rack/handler/webrick.rb:59:in `service'
16602
+ C:/Ruby193/lib/ruby/1.9.1/webrick/httpserver.rb:138:in `service'
16603
+ C:/Ruby193/lib/ruby/1.9.1/webrick/httpserver.rb:94:in `run'
16604
+ C:/Ruby193/lib/ruby/1.9.1/webrick/server.rb:191:in `block in start_thread'
16605
+
16606
+
16607
+ Rendered C:/Ruby193/lib/ruby/gems/1.9.1/gems/actionpack-3.2.6/lib/action_dispatch/middleware/templates/rescues/routing_error.erb within rescues/layout (1.0ms)
16608
+
16609
+
16610
+ Started GET "/home/index?page=2" for 127.0.0.1 at 2012-07-26 08:23:19 +0800
16611
+ Processing by HomeController#index as HTML
16612
+ Parameters: {"page"=>"2"}
16613
+  (0.0ms) SELECT COUNT(*) FROM "posts" 
16614
+ Post Load (1.0ms) SELECT "posts".* FROM "posts" LIMIT 12 OFFSET 12
16615
+ Rendered home/index.html.erb within layouts/application (43.9ms)
16616
+ Rendered home/_topbar.html.erb (1.0ms)
16617
+ Rendered home/_sidebar.html.erb (1.0ms)
16618
+ Completed 200 OK in 62ms (Views: 59.6ms | ActiveRecord: 1.0ms)
16619
+
16620
+
16621
+ Started GET "/assets/ico/favicon.ico" for 127.0.0.1 at 2012-07-26 08:23:20 +0800
16622
+ Served asset /ico/favicon.ico - 404 Not Found (2ms)
16623
+
16624
+ ActionController::RoutingError (No route matches [GET] "/assets/ico/favicon.ico"):
16625
+ actionpack (3.2.6) lib/action_dispatch/middleware/debug_exceptions.rb:21:in `call'
16626
+ actionpack (3.2.6) lib/action_dispatch/middleware/show_exceptions.rb:56:in `call'
16627
+ railties (3.2.6) lib/rails/rack/logger.rb:26:in `call_app'
16628
+ railties (3.2.6) lib/rails/rack/logger.rb:16:in `call'
16629
+ actionpack (3.2.6) lib/action_dispatch/middleware/request_id.rb:22:in `call'
16630
+ rack (1.4.1) lib/rack/methodoverride.rb:21:in `call'
16631
+ rack (1.4.1) lib/rack/runtime.rb:17:in `call'
16632
+ activesupport (3.2.6) lib/active_support/cache/strategy/local_cache.rb:72:in `call'
16633
+ rack (1.4.1) lib/rack/lock.rb:15:in `call'
16634
+ actionpack (3.2.6) lib/action_dispatch/middleware/static.rb:62:in `call'
16635
+ railties (3.2.6) lib/rails/engine.rb:479:in `call'
16636
+ railties (3.2.6) lib/rails/application.rb:220:in `call'
16637
+ rack (1.4.1) lib/rack/content_length.rb:14:in `call'
16638
+ railties (3.2.6) lib/rails/rack/log_tailer.rb:17:in `call'
16639
+ rack (1.4.1) lib/rack/handler/webrick.rb:59:in `service'
16640
+ C:/Ruby193/lib/ruby/1.9.1/webrick/httpserver.rb:138:in `service'
16641
+ C:/Ruby193/lib/ruby/1.9.1/webrick/httpserver.rb:94:in `run'
16642
+ C:/Ruby193/lib/ruby/1.9.1/webrick/server.rb:191:in `block in start_thread'
16643
+
16644
+
16645
+ Rendered C:/Ruby193/lib/ruby/gems/1.9.1/gems/actionpack-3.2.6/lib/action_dispatch/middleware/templates/rescues/routing_error.erb within rescues/layout (1.0ms)
16646
+
16647
+
16648
+ Started GET "/home/index?page=3" for 127.0.0.1 at 2012-07-26 08:23:21 +0800
16649
+ Processing by HomeController#index as HTML
16650
+ Parameters: {"page"=>"3"}
16651
+  (0.0ms) SELECT COUNT(*) FROM "posts" 
16652
+ Post Load (1.0ms) SELECT "posts".* FROM "posts" LIMIT 12 OFFSET 24
16653
+ Rendered home/index.html.erb within layouts/application (25.4ms)
16654
+ Rendered home/_topbar.html.erb (2.0ms)
16655
+ Rendered home/_sidebar.html.erb (0.0ms)
16656
+ Completed 200 OK in 62ms (Views: 60.5ms | ActiveRecord: 1.0ms)
16657
+
16658
+
16659
+ Started GET "/assets/ico/favicon.ico" for 127.0.0.1 at 2012-07-26 08:23:21 +0800
16660
+ Served asset /ico/favicon.ico - 404 Not Found (3ms)
16661
+
16662
+ ActionController::RoutingError (No route matches [GET] "/assets/ico/favicon.ico"):
16663
+ actionpack (3.2.6) lib/action_dispatch/middleware/debug_exceptions.rb:21:in `call'
16664
+ actionpack (3.2.6) lib/action_dispatch/middleware/show_exceptions.rb:56:in `call'
16665
+ railties (3.2.6) lib/rails/rack/logger.rb:26:in `call_app'
16666
+ railties (3.2.6) lib/rails/rack/logger.rb:16:in `call'
16667
+ actionpack (3.2.6) lib/action_dispatch/middleware/request_id.rb:22:in `call'
16668
+ rack (1.4.1) lib/rack/methodoverride.rb:21:in `call'
16669
+ rack (1.4.1) lib/rack/runtime.rb:17:in `call'
16670
+ activesupport (3.2.6) lib/active_support/cache/strategy/local_cache.rb:72:in `call'
16671
+ rack (1.4.1) lib/rack/lock.rb:15:in `call'
16672
+ actionpack (3.2.6) lib/action_dispatch/middleware/static.rb:62:in `call'
16673
+ railties (3.2.6) lib/rails/engine.rb:479:in `call'
16674
+ railties (3.2.6) lib/rails/application.rb:220:in `call'
16675
+ rack (1.4.1) lib/rack/content_length.rb:14:in `call'
16676
+ railties (3.2.6) lib/rails/rack/log_tailer.rb:17:in `call'
16677
+ rack (1.4.1) lib/rack/handler/webrick.rb:59:in `service'
16678
+ C:/Ruby193/lib/ruby/1.9.1/webrick/httpserver.rb:138:in `service'
16679
+ C:/Ruby193/lib/ruby/1.9.1/webrick/httpserver.rb:94:in `run'
16680
+ C:/Ruby193/lib/ruby/1.9.1/webrick/server.rb:191:in `block in start_thread'
16681
+
16682
+
16683
+ Rendered C:/Ruby193/lib/ruby/gems/1.9.1/gems/actionpack-3.2.6/lib/action_dispatch/middleware/templates/rescues/routing_error.erb within rescues/layout (0.0ms)
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: tj_bootstrap_helper
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.9
4
+ version: 0.1.0
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: 2012-07-24 00:00:00.000000000 Z
12
+ date: 2012-07-26 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: rails
@@ -84,6 +84,7 @@ extra_rdoc_files: []
84
84
  files:
85
85
  - config/initializers/bootstrap_will_paginate.rb
86
86
  - lib/tasks/bootstrap-helper_tasks.rake
87
+ - lib/tj_bootstrap_helper/engine.rb
87
88
  - lib/tj_bootstrap_helper/helper.rb
88
89
  - lib/tj_bootstrap_helper/version.rb
89
90
  - lib/tj_bootstrap_helper.rb
@@ -183,7 +184,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
183
184
  version: '0'
184
185
  segments:
185
186
  - 0
186
- hash: 742043027
187
+ hash: -248601647
187
188
  required_rubygems_version: !ruby/object:Gem::Requirement
188
189
  none: false
189
190
  requirements:
@@ -192,7 +193,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
192
193
  version: '0'
193
194
  segments:
194
195
  - 0
195
- hash: 742043027
196
+ hash: -248601647
196
197
  requirements: []
197
198
  rubyforge_project:
198
199
  rubygems_version: 1.8.24