formotion 0.5.1 → 1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (85) hide show
  1. data/CHANGELOG.md +24 -0
  2. data/LIST_OF_ROW_TYPES.md +1 -1
  3. data/Rakefile +20 -5
  4. data/app/app_delegate.rb +89 -17
  5. data/examples/FormModel/.gitignore +5 -0
  6. data/examples/FormModel/Rakefile +9 -0
  7. data/examples/FormModel/app/app_delegate.rb +11 -0
  8. data/examples/FormModel/app/user.rb +18 -0
  9. data/examples/FormModel/app/users_controller.rb +52 -0
  10. data/examples/FormModel/spec/main_spec.rb +9 -0
  11. data/examples/KitchenSink/app/app_delegate.rb +2 -2
  12. data/gh-pages/assets/css/bootstrap-responsive.css +815 -0
  13. data/gh-pages/assets/css/bootstrap-responsive.min.css +9 -0
  14. data/gh-pages/assets/css/bootstrap.css +4983 -0
  15. data/gh-pages/assets/css/bootstrap.min.css +9 -0
  16. data/gh-pages/assets/css/formotion.css +117 -0
  17. data/gh-pages/assets/css/pygments.css +62 -0
  18. data/gh-pages/assets/img/glyphicons-halflings-white.png +0 -0
  19. data/gh-pages/assets/img/glyphicons-halflings.png +0 -0
  20. data/gh-pages/assets/js/bootstrap-alert.js +90 -0
  21. data/gh-pages/assets/js/bootstrap-button.js +96 -0
  22. data/gh-pages/assets/js/bootstrap-carousel.js +169 -0
  23. data/gh-pages/assets/js/bootstrap-collapse.js +157 -0
  24. data/gh-pages/assets/js/bootstrap-dropdown.js +100 -0
  25. data/gh-pages/assets/js/bootstrap-modal.js +218 -0
  26. data/gh-pages/assets/js/bootstrap-popover.js +98 -0
  27. data/gh-pages/assets/js/bootstrap-scrollspy.js +151 -0
  28. data/gh-pages/assets/js/bootstrap-tab.js +135 -0
  29. data/gh-pages/assets/js/bootstrap-tooltip.js +275 -0
  30. data/gh-pages/assets/js/bootstrap-transition.js +61 -0
  31. data/gh-pages/assets/js/bootstrap-typeahead.js +285 -0
  32. data/gh-pages/assets/js/bootstrap.js +1825 -0
  33. data/gh-pages/assets/js/bootstrap.min.js +6 -0
  34. data/gh-pages/index.html +205 -0
  35. data/lib/formotion.rb +15 -2
  36. data/lib/formotion/base.rb +5 -5
  37. data/lib/formotion/{form_controller.rb → controller/form_controller.rb} +22 -3
  38. data/lib/formotion/controller/formable_controller.rb +21 -0
  39. data/lib/formotion/form/form.rb +31 -8
  40. data/lib/formotion/form/form_delegate.rb +26 -3
  41. data/lib/formotion/model/formable.rb +78 -0
  42. data/lib/formotion/row/row.rb +54 -21
  43. data/lib/formotion/row/row_cell_builder.rb +1 -1
  44. data/lib/formotion/row_type/back_row.rb +11 -0
  45. data/lib/formotion/row_type/base.rb +42 -1
  46. data/lib/formotion/row_type/button.rb +30 -0
  47. data/lib/formotion/row_type/check_row.rb +9 -5
  48. data/lib/formotion/row_type/date_row.rb +5 -0
  49. data/lib/formotion/row_type/edit_row.rb +14 -0
  50. data/lib/formotion/row_type/image_row.rb +7 -7
  51. data/lib/formotion/row_type/options_row.rb +18 -8
  52. data/lib/formotion/row_type/slider_row.rb +14 -5
  53. data/lib/formotion/row_type/string_row.rb +17 -5
  54. data/lib/formotion/row_type/subform_row.rb +16 -0
  55. data/lib/formotion/row_type/submit_row.rb +1 -24
  56. data/lib/formotion/row_type/switch_row.rb +10 -2
  57. data/lib/formotion/row_type/template_row.rb +77 -0
  58. data/lib/formotion/row_type/text_row.rb +12 -4
  59. data/lib/formotion/section/section.rb +9 -1
  60. data/lib/formotion/version.rb +1 -1
  61. data/spec/form_spec.rb +24 -0
  62. data/spec/formable_spec.rb +100 -0
  63. data/spec/functional/formable_controller_spec.rb +47 -0
  64. data/spec/functional/image_row_spec.rb +2 -2
  65. data/spec/functional/subform_row.rb +33 -0
  66. data/spec/functional/template_row_spec.rb +57 -0
  67. data/spec/helpers/row_test_helpers.rb +26 -0
  68. data/spec/row_type/back_spec.rb +31 -0
  69. data/spec/row_type/check_spec.rb +9 -9
  70. data/spec/row_type/date_spec.rb +3 -10
  71. data/spec/row_type/email_spec.rb +1 -9
  72. data/spec/row_type/image_spec.rb +3 -12
  73. data/spec/row_type/number_spec.rb +1 -9
  74. data/spec/row_type/options_spec.rb +18 -10
  75. data/spec/row_type/phone_spec.rb +1 -9
  76. data/spec/row_type/picker_spec.rb +2 -11
  77. data/spec/row_type/slider_spec.rb +11 -10
  78. data/spec/row_type/static_spec.rb +1 -9
  79. data/spec/row_type/string_spec.rb +13 -9
  80. data/spec/row_type/subform_spec.rb +47 -0
  81. data/spec/row_type/submit_spec.rb +1 -9
  82. data/spec/row_type/switch_spec.rb +9 -9
  83. data/spec/row_type/template_spec.rb +14 -0
  84. data/spec/row_type/text_spec.rb +9 -9
  85. metadata +58 -6
data/CHANGELOG.md CHANGED
@@ -1,3 +1,27 @@
1
+ ## 1.1 - ???
2
+
3
+ ### Bug Fixes
4
+
5
+ ## 1.0 - August 11, 2012
6
+
7
+ ### Features
8
+
9
+ - `:subform` `RowType`. Tapping this row will push a new form with the information given in the row's `subform` property.
10
+ - `:template` `RowType`. This type of row allows you to add more "child" rows according to a specification given in the `:template` key.
11
+ - `Formotion::Formable` module for to `include` in models. This adds a `.to_form` method and can be used with a `Formotion::FormableController` to automatically create a form synced to a model.
12
+
13
+ ### Improvements
14
+
15
+ - `reuseIdentifier` is now based on `#object_id`, so dynamically adding rows at runtime should work.
16
+ - Every `RowType` now has an appropriate binding between `row.value` and it's display. So if you have a `StringRow` and change it's `row.value` programmatically, the view will update accordingly.
17
+ - `rake spec:units` and `rake spec:functionals` for running tests faster.
18
+ - renamed `rowHeight` to `row_height`
19
+
20
+ ### Bug Fixes
21
+
22
+ - Fixed crash when `form.submit` called without a `on_submit` callback set.
23
+ - Add more thorough file dependencies
24
+
1
25
  ## 0.5.1 - July 19, 2012
2
26
 
3
27
  ### Improvements
data/LIST_OF_ROW_TYPES.md CHANGED
@@ -40,7 +40,7 @@
40
40
  key: :text,
41
41
  type: :text,
42
42
  placeholder: "Enter your text here",
43
- rowHeight: 100
43
+ row_height: 100
44
44
  }
45
45
  ```
46
46
 
data/Rakefile CHANGED
@@ -9,9 +9,24 @@ require './lib/formotion'
9
9
  Motion::Project::App.setup do |app|
10
10
  # Use `rake config' to see complete project settings.
11
11
  app.name = 'Formotion'
12
+ end
12
13
 
13
- # Temporary, until RubyMotion patches its test loader
14
- spec_files = app.spec_files + Dir.glob(File.join(app.specs_dir, '**/*.rb'))
15
- spec_files.uniq!
16
- app.instance_variable_set(:@spec_files, spec_files)
17
- end
14
+ namespace :spec do
15
+ task :units do
16
+ App.config.spec_mode = true
17
+ spec_files = App.config.spec_files
18
+ functional_files = Dir.glob('./spec/functional/**/*.rb')
19
+ spec_files -= functional_files
20
+ App.config.instance_variable_set("@spec_files", spec_files)
21
+ Rake::Task["simulator"].invoke
22
+ end
23
+
24
+ task :functionals do
25
+ App.config.spec_mode = true
26
+ spec_files = App.config.spec_files
27
+ row_type_files = Dir.glob('./spec/row_type/**/*.rb')
28
+ spec_files -= row_type_files
29
+ App.config.instance_variable_set("@spec_files", spec_files)
30
+ Rake::Task["simulator"].invoke
31
+ end
32
+ end
data/app/app_delegate.rb CHANGED
@@ -1,4 +1,6 @@
1
1
  class AppDelegate
2
+
3
+ attr_accessor :view_controller
2
4
  def application(application, didFinishLaunchingWithOptions:launchOptions)
3
5
  @window = UIWindow.alloc.initWithFrame(UIScreen.mainScreen.bounds)
4
6
 
@@ -8,7 +10,8 @@ class AppDelegate
8
10
  rows: [{
9
11
  title: "Photo",
10
12
  key: :photo,
11
- type: :image
13
+ type: :image,
14
+ deletable: true
12
15
  },{
13
16
  title: "Picker",
14
17
  key: :pick,
@@ -44,7 +47,7 @@ class AppDelegate
44
47
  key: :bio,
45
48
  type: :text,
46
49
  placeholder: "Enter your Bio here...",
47
- rowHeight: 100
50
+ row_height: 100
48
51
  }, {
49
52
  title: "Date Full",
50
53
  value: 326937600,
@@ -57,24 +60,93 @@ class AppDelegate
57
60
  key: :date_short,
58
61
  type: :date,
59
62
  format: :short
63
+ }, {
64
+ title: "Slider",
65
+ key: :slider,
66
+ type: :slider
67
+ }, {
68
+ title: "Account type",
69
+ type: :subform,
70
+ key: :account,
71
+ subform: {
72
+ title: "Account Type",
73
+ sections: [{
74
+ key: :type,
75
+ select_one: true,
76
+ rows: [{
77
+ title: "Free",
78
+ key: :free,
79
+ type: :check,
80
+ }, {
81
+ title: "Basic",
82
+ value: true,
83
+ key: :basic,
84
+ type: :check,
85
+ }, {
86
+ title: "Pro",
87
+ key: :pro,
88
+ type: :check,
89
+ }]
90
+ }, {
91
+ rows: [{
92
+ title: "Advanced",
93
+ type: :subform,
94
+ key: :advanced,
95
+ subform: {
96
+ title: "Advanced",
97
+ sections: [{
98
+ key: :currency,
99
+ select_one: true,
100
+ rows: [{
101
+ title: "USD",
102
+ value: true,
103
+ key: :usd,
104
+ type: :check,
105
+ }, {
106
+ title: "EUR",
107
+ key: :eur,
108
+ type: :check,
109
+ }, {
110
+ title: "CHF",
111
+ key: :chf,
112
+ type: :check,
113
+ }]
114
+ }, {
115
+ rows: [{
116
+ title: 'Back',
117
+ type: :back
118
+ }]
119
+ }]
120
+ }
121
+ }]
122
+ }, {
123
+ rows: [{
124
+ title: 'Back',
125
+ type: :back
126
+ }]
127
+ }]
128
+ }
129
+ }]
130
+ },{
131
+ title: 'Your nicknames',
132
+ rows: [{
133
+ title: "Add nickname",
134
+ key: :nicknames,
135
+ type: :template,
136
+ value: ['Nici', 'Sam'],
137
+ template: {
138
+ title: 'Nickname',
139
+ type: :string,
140
+ placeholder: 'Enter here',
141
+ indented: true,
142
+ deletable: true
143
+ }
60
144
  }]
61
145
  }, {
62
- title: "Account Type",
63
- key: :account_type,
64
- select_one: true,
65
146
  rows: [{
66
- title: "Free",
67
- key: :free,
68
- type: :check,
69
- }, {
70
- title: "Basic",
71
- value: true,
72
- key: :basic,
73
- type: :check,
74
- }, {
75
- title: "Pro",
76
- key: :pro,
77
- type: :check,
147
+ title: "Edit",
148
+ alt_title: "Done",
149
+ type: :edit,
78
150
  }]
79
151
  }, {
80
152
  rows: [{
@@ -0,0 +1,5 @@
1
+ .repl_history
2
+ build
3
+ resources/*.nib
4
+ resources/*.momd
5
+ resources/*.storyboardc
@@ -0,0 +1,9 @@
1
+ # -*- coding: utf-8 -*-
2
+ $:.unshift("/Library/RubyMotion/lib")
3
+ require 'motion/project'
4
+ require '../../lib/formotion'
5
+
6
+ Motion::Project::App.setup do |app|
7
+ # Use `rake config' to see complete project settings.
8
+ app.name = 'FormModel'
9
+ end
@@ -0,0 +1,11 @@
1
+ class AppDelegate
2
+ def application(application, didFinishLaunchingWithOptions:launchOptions)
3
+ @window = UIWindow.alloc.initWithFrame(UIScreen.mainScreen.bounds)
4
+
5
+ @navigation_controller = UINavigationController.alloc.initWithRootViewController(UsersController.alloc.initWithNibName(nil, bundle:nil))
6
+ @window.rootViewController = @navigation_controller
7
+ @window.makeKeyAndVisible
8
+
9
+ true
10
+ end
11
+ end
@@ -0,0 +1,18 @@
1
+ class User
2
+ include Formotion::Formable
3
+
4
+ attr_accessor :name, :score, :team
5
+
6
+ form_property :name, :string
7
+ form_property :score, :number, transform: lambda { |value| value.to_i }
8
+
9
+ form_property :team, :picker, items: ["Red", "Blue", "Green"]
10
+
11
+ form_title "Edit User"
12
+
13
+ def initialize(name, score, team)
14
+ self.name = name
15
+ self.score = score
16
+ self.team = team
17
+ end
18
+ end
@@ -0,0 +1,52 @@
1
+ class UsersController < UITableViewController
2
+ def users
3
+ @users ||= [User.new("Harry", 100, "Green"),
4
+ User.new("Ron", 80, "Blue"),
5
+ User.new("Hermione", 120, "Red")]
6
+ end
7
+
8
+ def viewDidLoad
9
+ super
10
+ self.title = "Scoreboard"
11
+ end
12
+
13
+ def viewDidAppear(animated)
14
+ super
15
+ self.users.sort_by! { |x| x.score }.reverse!
16
+ self.tableView.reloadData
17
+ end
18
+
19
+ def tableView(tableView, numberOfRowsInSection:section)
20
+ self.users.count
21
+ end
22
+
23
+ def tableView(tableView, cellForRowAtIndexPath:indexPath)
24
+ @identifier ||= "IDENTIFIER"
25
+
26
+ cell = tableView.dequeueReusableCellWithIdentifier(@indentifier) || begin
27
+ UITableViewCell.alloc.initWithStyle(UITableViewCellStyleSubtitle, reuseIdentifier:@identifier)
28
+ end
29
+
30
+ user = self.users[indexPath.row]
31
+ cell.textLabel.text = "##{indexPath.row + 1}: #{user.name}"
32
+ cell.detailTextLabel.text = user.team
33
+ cell.accessoryType = UITableViewCellAccessoryDetailDisclosureButton
34
+
35
+ cell
36
+ end
37
+
38
+ def tableView(tableView, didSelectRowAtIndexPath:indexPath)
39
+ tableView.deselectRowAtIndexPath(indexPath, animated:true)
40
+
41
+ user = self.users[indexPath.row]
42
+ alert = UIAlertView.alloc.initWithTitle(user.name, message:"Score: #{user.score}", delegate:nil, cancelButtonTitle:"OK", otherButtonTitles:nil)
43
+ alert.show
44
+ end
45
+
46
+ def tableView(tableView, accessoryButtonTappedForRowWithIndexPath:indexPath)
47
+ # WHERE THE MAGIC HAPPENS!
48
+ user = self.users[indexPath.row]
49
+ controller = Formotion::FormableController.alloc.initWithModel(user)
50
+ self.navigationController.pushViewController(controller, animated:true)
51
+ end
52
+ end
@@ -0,0 +1,9 @@
1
+ describe "Application 'FormModel'" do
2
+ before do
3
+ @app = UIApplication.sharedApplication
4
+ end
5
+
6
+ it "has one window" do
7
+ @app.windows.size.should == 1
8
+ end
9
+ end
@@ -54,13 +54,13 @@ class AppDelegate
54
54
  key: :row_height,
55
55
  placeholder: "60px",
56
56
  type: :string,
57
- rowHeight: 60
57
+ row_height: 60
58
58
  }, {
59
59
  title: "Text",
60
60
  key: :text,
61
61
  type: :text,
62
62
  placeholder: "Enter your text here",
63
- rowHeight: 100
63
+ row_height: 100
64
64
  }, {
65
65
  title: "Check",
66
66
  key: :check,
@@ -0,0 +1,815 @@
1
+ /*!
2
+ * Bootstrap Responsive v2.0.4
3
+ *
4
+ * Copyright 2012 Twitter, Inc
5
+ * Licensed under the Apache License v2.0
6
+ * http://www.apache.org/licenses/LICENSE-2.0
7
+ *
8
+ * Designed and built with all the love in the world @twitter by @mdo and @fat.
9
+ */
10
+
11
+ .clearfix {
12
+ *zoom: 1;
13
+ }
14
+
15
+ .clearfix:before,
16
+ .clearfix:after {
17
+ display: table;
18
+ content: "";
19
+ }
20
+
21
+ .clearfix:after {
22
+ clear: both;
23
+ }
24
+
25
+ .hide-text {
26
+ font: 0/0 a;
27
+ color: transparent;
28
+ text-shadow: none;
29
+ background-color: transparent;
30
+ border: 0;
31
+ }
32
+
33
+ .input-block-level {
34
+ display: block;
35
+ width: 100%;
36
+ min-height: 28px;
37
+ -webkit-box-sizing: border-box;
38
+ -moz-box-sizing: border-box;
39
+ -ms-box-sizing: border-box;
40
+ box-sizing: border-box;
41
+ }
42
+
43
+ .hidden {
44
+ display: none;
45
+ visibility: hidden;
46
+ }
47
+
48
+ .visible-phone {
49
+ display: none !important;
50
+ }
51
+
52
+ .visible-tablet {
53
+ display: none !important;
54
+ }
55
+
56
+ .hidden-desktop {
57
+ display: none !important;
58
+ }
59
+
60
+ @media (max-width: 767px) {
61
+ .visible-phone {
62
+ display: inherit !important;
63
+ }
64
+ .hidden-phone {
65
+ display: none !important;
66
+ }
67
+ .hidden-desktop {
68
+ display: inherit !important;
69
+ }
70
+ .visible-desktop {
71
+ display: none !important;
72
+ }
73
+ }
74
+
75
+ @media (min-width: 768px) and (max-width: 979px) {
76
+ .visible-tablet {
77
+ display: inherit !important;
78
+ }
79
+ .hidden-tablet {
80
+ display: none !important;
81
+ }
82
+ .hidden-desktop {
83
+ display: inherit !important;
84
+ }
85
+ .visible-desktop {
86
+ display: none !important ;
87
+ }
88
+ }
89
+
90
+ @media (max-width: 480px) {
91
+ .nav-collapse {
92
+ -webkit-transform: translate3d(0, 0, 0);
93
+ }
94
+ .page-header h1 small {
95
+ display: block;
96
+ line-height: 18px;
97
+ }
98
+ input[type="checkbox"],
99
+ input[type="radio"] {
100
+ border: 1px solid #ccc;
101
+ }
102
+ .form-horizontal .control-group > label {
103
+ float: none;
104
+ width: auto;
105
+ padding-top: 0;
106
+ text-align: left;
107
+ }
108
+ .form-horizontal .controls {
109
+ margin-left: 0;
110
+ }
111
+ .form-horizontal .control-list {
112
+ padding-top: 0;
113
+ }
114
+ .form-horizontal .form-actions {
115
+ padding-right: 10px;
116
+ padding-left: 10px;
117
+ }
118
+ .modal {
119
+ position: absolute;
120
+ top: 10px;
121
+ right: 10px;
122
+ left: 10px;
123
+ width: auto;
124
+ margin: 0;
125
+ }
126
+ .modal.fade.in {
127
+ top: auto;
128
+ }
129
+ .modal-header .close {
130
+ padding: 10px;
131
+ margin: -10px;
132
+ }
133
+ .carousel-caption {
134
+ position: static;
135
+ }
136
+ }
137
+
138
+ @media (max-width: 767px) {
139
+ body {
140
+ padding-right: 20px;
141
+ padding-left: 20px;
142
+ }
143
+ .navbar-fixed-top,
144
+ .navbar-fixed-bottom {
145
+ margin-right: -20px;
146
+ margin-left: -20px;
147
+ }
148
+ .container-fluid {
149
+ padding: 0;
150
+ }
151
+ .dl-horizontal dt {
152
+ float: none;
153
+ width: auto;
154
+ clear: none;
155
+ text-align: left;
156
+ }
157
+ .dl-horizontal dd {
158
+ margin-left: 0;
159
+ }
160
+ .container {
161
+ width: auto;
162
+ }
163
+ .row-fluid {
164
+ width: 100%;
165
+ }
166
+ .row,
167
+ .thumbnails {
168
+ margin-left: 0;
169
+ }
170
+ [class*="span"],
171
+ .row-fluid [class*="span"] {
172
+ display: block;
173
+ float: none;
174
+ width: auto;
175
+ margin-left: 0;
176
+ }
177
+ .input-large,
178
+ .input-xlarge,
179
+ .input-xxlarge,
180
+ input[class*="span"],
181
+ select[class*="span"],
182
+ textarea[class*="span"],
183
+ .uneditable-input {
184
+ display: block;
185
+ width: 100%;
186
+ min-height: 28px;
187
+ -webkit-box-sizing: border-box;
188
+ -moz-box-sizing: border-box;
189
+ -ms-box-sizing: border-box;
190
+ box-sizing: border-box;
191
+ }
192
+ .input-prepend input,
193
+ .input-append input,
194
+ .input-prepend input[class*="span"],
195
+ .input-append input[class*="span"] {
196
+ display: inline-block;
197
+ width: auto;
198
+ }
199
+ }
200
+
201
+ @media (min-width: 768px) and (max-width: 979px) {
202
+ .row {
203
+ margin-left: -20px;
204
+ *zoom: 1;
205
+ }
206
+ .row:before,
207
+ .row:after {
208
+ display: table;
209
+ content: "";
210
+ }
211
+ .row:after {
212
+ clear: both;
213
+ }
214
+ [class*="span"] {
215
+ float: left;
216
+ margin-left: 20px;
217
+ }
218
+ .container,
219
+ .navbar-fixed-top .container,
220
+ .navbar-fixed-bottom .container {
221
+ width: 724px;
222
+ }
223
+ .span12 {
224
+ width: 724px;
225
+ }
226
+ .span11 {
227
+ width: 662px;
228
+ }
229
+ .span10 {
230
+ width: 600px;
231
+ }
232
+ .span9 {
233
+ width: 538px;
234
+ }
235
+ .span8 {
236
+ width: 476px;
237
+ }
238
+ .span7 {
239
+ width: 414px;
240
+ }
241
+ .span6 {
242
+ width: 352px;
243
+ }
244
+ .span5 {
245
+ width: 290px;
246
+ }
247
+ .span4 {
248
+ width: 228px;
249
+ }
250
+ .span3 {
251
+ width: 166px;
252
+ }
253
+ .span2 {
254
+ width: 104px;
255
+ }
256
+ .span1 {
257
+ width: 42px;
258
+ }
259
+ .offset12 {
260
+ margin-left: 764px;
261
+ }
262
+ .offset11 {
263
+ margin-left: 702px;
264
+ }
265
+ .offset10 {
266
+ margin-left: 640px;
267
+ }
268
+ .offset9 {
269
+ margin-left: 578px;
270
+ }
271
+ .offset8 {
272
+ margin-left: 516px;
273
+ }
274
+ .offset7 {
275
+ margin-left: 454px;
276
+ }
277
+ .offset6 {
278
+ margin-left: 392px;
279
+ }
280
+ .offset5 {
281
+ margin-left: 330px;
282
+ }
283
+ .offset4 {
284
+ margin-left: 268px;
285
+ }
286
+ .offset3 {
287
+ margin-left: 206px;
288
+ }
289
+ .offset2 {
290
+ margin-left: 144px;
291
+ }
292
+ .offset1 {
293
+ margin-left: 82px;
294
+ }
295
+ .row-fluid {
296
+ width: 100%;
297
+ *zoom: 1;
298
+ }
299
+ .row-fluid:before,
300
+ .row-fluid:after {
301
+ display: table;
302
+ content: "";
303
+ }
304
+ .row-fluid:after {
305
+ clear: both;
306
+ }
307
+ .row-fluid [class*="span"] {
308
+ display: block;
309
+ float: left;
310
+ width: 100%;
311
+ min-height: 28px;
312
+ margin-left: 2.762430939%;
313
+ *margin-left: 2.709239449638298%;
314
+ -webkit-box-sizing: border-box;
315
+ -moz-box-sizing: border-box;
316
+ -ms-box-sizing: border-box;
317
+ box-sizing: border-box;
318
+ }
319
+ .row-fluid [class*="span"]:first-child {
320
+ margin-left: 0;
321
+ }
322
+ .row-fluid .span12 {
323
+ width: 99.999999993%;
324
+ *width: 99.9468085036383%;
325
+ }
326
+ .row-fluid .span11 {
327
+ width: 91.436464082%;
328
+ *width: 91.38327259263829%;
329
+ }
330
+ .row-fluid .span10 {
331
+ width: 82.87292817100001%;
332
+ *width: 82.8197366816383%;
333
+ }
334
+ .row-fluid .span9 {
335
+ width: 74.30939226%;
336
+ *width: 74.25620077063829%;
337
+ }
338
+ .row-fluid .span8 {
339
+ width: 65.74585634900001%;
340
+ *width: 65.6926648596383%;
341
+ }
342
+ .row-fluid .span7 {
343
+ width: 57.182320438000005%;
344
+ *width: 57.129128948638304%;
345
+ }
346
+ .row-fluid .span6 {
347
+ width: 48.618784527%;
348
+ *width: 48.5655930376383%;
349
+ }
350
+ .row-fluid .span5 {
351
+ width: 40.055248616%;
352
+ *width: 40.0020571266383%;
353
+ }
354
+ .row-fluid .span4 {
355
+ width: 31.491712705%;
356
+ *width: 31.4385212156383%;
357
+ }
358
+ .row-fluid .span3 {
359
+ width: 22.928176794%;
360
+ *width: 22.874985304638297%;
361
+ }
362
+ .row-fluid .span2 {
363
+ width: 14.364640883%;
364
+ *width: 14.311449393638298%;
365
+ }
366
+ .row-fluid .span1 {
367
+ width: 5.801104972%;
368
+ *width: 5.747913482638298%;
369
+ }
370
+ input,
371
+ textarea,
372
+ .uneditable-input {
373
+ margin-left: 0;
374
+ }
375
+ input.span12,
376
+ textarea.span12,
377
+ .uneditable-input.span12 {
378
+ width: 714px;
379
+ }
380
+ input.span11,
381
+ textarea.span11,
382
+ .uneditable-input.span11 {
383
+ width: 652px;
384
+ }
385
+ input.span10,
386
+ textarea.span10,
387
+ .uneditable-input.span10 {
388
+ width: 590px;
389
+ }
390
+ input.span9,
391
+ textarea.span9,
392
+ .uneditable-input.span9 {
393
+ width: 528px;
394
+ }
395
+ input.span8,
396
+ textarea.span8,
397
+ .uneditable-input.span8 {
398
+ width: 466px;
399
+ }
400
+ input.span7,
401
+ textarea.span7,
402
+ .uneditable-input.span7 {
403
+ width: 404px;
404
+ }
405
+ input.span6,
406
+ textarea.span6,
407
+ .uneditable-input.span6 {
408
+ width: 342px;
409
+ }
410
+ input.span5,
411
+ textarea.span5,
412
+ .uneditable-input.span5 {
413
+ width: 280px;
414
+ }
415
+ input.span4,
416
+ textarea.span4,
417
+ .uneditable-input.span4 {
418
+ width: 218px;
419
+ }
420
+ input.span3,
421
+ textarea.span3,
422
+ .uneditable-input.span3 {
423
+ width: 156px;
424
+ }
425
+ input.span2,
426
+ textarea.span2,
427
+ .uneditable-input.span2 {
428
+ width: 94px;
429
+ }
430
+ input.span1,
431
+ textarea.span1,
432
+ .uneditable-input.span1 {
433
+ width: 32px;
434
+ }
435
+ }
436
+
437
+ @media (min-width: 1200px) {
438
+ .row {
439
+ margin-left: -30px;
440
+ *zoom: 1;
441
+ }
442
+ .row:before,
443
+ .row:after {
444
+ display: table;
445
+ content: "";
446
+ }
447
+ .row:after {
448
+ clear: both;
449
+ }
450
+ [class*="span"] {
451
+ float: left;
452
+ margin-left: 30px;
453
+ }
454
+ .container,
455
+ .navbar-fixed-top .container,
456
+ .navbar-fixed-bottom .container {
457
+ width: 1170px;
458
+ }
459
+ .span12 {
460
+ width: 1170px;
461
+ }
462
+ .span11 {
463
+ width: 1070px;
464
+ }
465
+ .span10 {
466
+ width: 970px;
467
+ }
468
+ .span9 {
469
+ width: 870px;
470
+ }
471
+ .span8 {
472
+ width: 770px;
473
+ }
474
+ .span7 {
475
+ width: 670px;
476
+ }
477
+ .span6 {
478
+ width: 570px;
479
+ }
480
+ .span5 {
481
+ width: 470px;
482
+ }
483
+ .span4 {
484
+ width: 370px;
485
+ }
486
+ .span3 {
487
+ width: 270px;
488
+ }
489
+ .span2 {
490
+ width: 170px;
491
+ }
492
+ .span1 {
493
+ width: 70px;
494
+ }
495
+ .offset12 {
496
+ margin-left: 1230px;
497
+ }
498
+ .offset11 {
499
+ margin-left: 1130px;
500
+ }
501
+ .offset10 {
502
+ margin-left: 1030px;
503
+ }
504
+ .offset9 {
505
+ margin-left: 930px;
506
+ }
507
+ .offset8 {
508
+ margin-left: 830px;
509
+ }
510
+ .offset7 {
511
+ margin-left: 730px;
512
+ }
513
+ .offset6 {
514
+ margin-left: 630px;
515
+ }
516
+ .offset5 {
517
+ margin-left: 530px;
518
+ }
519
+ .offset4 {
520
+ margin-left: 430px;
521
+ }
522
+ .offset3 {
523
+ margin-left: 330px;
524
+ }
525
+ .offset2 {
526
+ margin-left: 230px;
527
+ }
528
+ .offset1 {
529
+ margin-left: 130px;
530
+ }
531
+ .row-fluid {
532
+ width: 100%;
533
+ *zoom: 1;
534
+ }
535
+ .row-fluid:before,
536
+ .row-fluid:after {
537
+ display: table;
538
+ content: "";
539
+ }
540
+ .row-fluid:after {
541
+ clear: both;
542
+ }
543
+ .row-fluid [class*="span"] {
544
+ display: block;
545
+ float: left;
546
+ width: 100%;
547
+ min-height: 28px;
548
+ margin-left: 2.564102564%;
549
+ *margin-left: 2.510911074638298%;
550
+ -webkit-box-sizing: border-box;
551
+ -moz-box-sizing: border-box;
552
+ -ms-box-sizing: border-box;
553
+ box-sizing: border-box;
554
+ }
555
+ .row-fluid [class*="span"]:first-child {
556
+ margin-left: 0;
557
+ }
558
+ .row-fluid .span12 {
559
+ width: 100%;
560
+ *width: 99.94680851063829%;
561
+ }
562
+ .row-fluid .span11 {
563
+ width: 91.45299145300001%;
564
+ *width: 91.3997999636383%;
565
+ }
566
+ .row-fluid .span10 {
567
+ width: 82.905982906%;
568
+ *width: 82.8527914166383%;
569
+ }
570
+ .row-fluid .span9 {
571
+ width: 74.358974359%;
572
+ *width: 74.30578286963829%;
573
+ }
574
+ .row-fluid .span8 {
575
+ width: 65.81196581200001%;
576
+ *width: 65.7587743226383%;
577
+ }
578
+ .row-fluid .span7 {
579
+ width: 57.264957265%;
580
+ *width: 57.2117657756383%;
581
+ }
582
+ .row-fluid .span6 {
583
+ width: 48.717948718%;
584
+ *width: 48.6647572286383%;
585
+ }
586
+ .row-fluid .span5 {
587
+ width: 40.170940171000005%;
588
+ *width: 40.117748681638304%;
589
+ }
590
+ .row-fluid .span4 {
591
+ width: 31.623931624%;
592
+ *width: 31.5707401346383%;
593
+ }
594
+ .row-fluid .span3 {
595
+ width: 23.076923077%;
596
+ *width: 23.0237315876383%;
597
+ }
598
+ .row-fluid .span2 {
599
+ width: 14.529914530000001%;
600
+ *width: 14.4767230406383%;
601
+ }
602
+ .row-fluid .span1 {
603
+ width: 5.982905983%;
604
+ *width: 5.929714493638298%;
605
+ }
606
+ input,
607
+ textarea,
608
+ .uneditable-input {
609
+ margin-left: 0;
610
+ }
611
+ input.span12,
612
+ textarea.span12,
613
+ .uneditable-input.span12 {
614
+ width: 1160px;
615
+ }
616
+ input.span11,
617
+ textarea.span11,
618
+ .uneditable-input.span11 {
619
+ width: 1060px;
620
+ }
621
+ input.span10,
622
+ textarea.span10,
623
+ .uneditable-input.span10 {
624
+ width: 960px;
625
+ }
626
+ input.span9,
627
+ textarea.span9,
628
+ .uneditable-input.span9 {
629
+ width: 860px;
630
+ }
631
+ input.span8,
632
+ textarea.span8,
633
+ .uneditable-input.span8 {
634
+ width: 760px;
635
+ }
636
+ input.span7,
637
+ textarea.span7,
638
+ .uneditable-input.span7 {
639
+ width: 660px;
640
+ }
641
+ input.span6,
642
+ textarea.span6,
643
+ .uneditable-input.span6 {
644
+ width: 560px;
645
+ }
646
+ input.span5,
647
+ textarea.span5,
648
+ .uneditable-input.span5 {
649
+ width: 460px;
650
+ }
651
+ input.span4,
652
+ textarea.span4,
653
+ .uneditable-input.span4 {
654
+ width: 360px;
655
+ }
656
+ input.span3,
657
+ textarea.span3,
658
+ .uneditable-input.span3 {
659
+ width: 260px;
660
+ }
661
+ input.span2,
662
+ textarea.span2,
663
+ .uneditable-input.span2 {
664
+ width: 160px;
665
+ }
666
+ input.span1,
667
+ textarea.span1,
668
+ .uneditable-input.span1 {
669
+ width: 60px;
670
+ }
671
+ .thumbnails {
672
+ margin-left: -30px;
673
+ }
674
+ .thumbnails > li {
675
+ margin-left: 30px;
676
+ }
677
+ .row-fluid .thumbnails {
678
+ margin-left: 0;
679
+ }
680
+ }
681
+
682
+ @media (max-width: 979px) {
683
+ body {
684
+ padding-top: 0;
685
+ }
686
+ .navbar-fixed-top,
687
+ .navbar-fixed-bottom {
688
+ position: static;
689
+ }
690
+ .navbar-fixed-top {
691
+ margin-bottom: 18px;
692
+ }
693
+ .navbar-fixed-bottom {
694
+ margin-top: 18px;
695
+ }
696
+ .navbar-fixed-top .navbar-inner,
697
+ .navbar-fixed-bottom .navbar-inner {
698
+ padding: 5px;
699
+ }
700
+ .navbar .container {
701
+ width: auto;
702
+ padding: 0;
703
+ }
704
+ .navbar .brand {
705
+ padding-right: 10px;
706
+ padding-left: 10px;
707
+ margin: 0 0 0 -5px;
708
+ }
709
+ .nav-collapse {
710
+ clear: both;
711
+ }
712
+ .nav-collapse .nav {
713
+ float: none;
714
+ margin: 0 0 9px;
715
+ }
716
+ .nav-collapse .nav > li {
717
+ float: none;
718
+ }
719
+ .nav-collapse .nav > li > a {
720
+ margin-bottom: 2px;
721
+ }
722
+ .nav-collapse .nav > .divider-vertical {
723
+ display: none;
724
+ }
725
+ .nav-collapse .nav .nav-header {
726
+ color: #999999;
727
+ text-shadow: none;
728
+ }
729
+ .nav-collapse .nav > li > a,
730
+ .nav-collapse .dropdown-menu a {
731
+ padding: 6px 15px;
732
+ font-weight: bold;
733
+ color: #999999;
734
+ -webkit-border-radius: 3px;
735
+ -moz-border-radius: 3px;
736
+ border-radius: 3px;
737
+ }
738
+ .nav-collapse .btn {
739
+ padding: 4px 10px 4px;
740
+ font-weight: normal;
741
+ -webkit-border-radius: 4px;
742
+ -moz-border-radius: 4px;
743
+ border-radius: 4px;
744
+ }
745
+ .nav-collapse .dropdown-menu li + li a {
746
+ margin-bottom: 2px;
747
+ }
748
+ .nav-collapse .nav > li > a:hover,
749
+ .nav-collapse .dropdown-menu a:hover {
750
+ background-color: #222222;
751
+ }
752
+ .nav-collapse.in .btn-group {
753
+ padding: 0;
754
+ margin-top: 5px;
755
+ }
756
+ .nav-collapse .dropdown-menu {
757
+ position: static;
758
+ top: auto;
759
+ left: auto;
760
+ display: block;
761
+ float: none;
762
+ max-width: none;
763
+ padding: 0;
764
+ margin: 0 15px;
765
+ background-color: transparent;
766
+ border: none;
767
+ -webkit-border-radius: 0;
768
+ -moz-border-radius: 0;
769
+ border-radius: 0;
770
+ -webkit-box-shadow: none;
771
+ -moz-box-shadow: none;
772
+ box-shadow: none;
773
+ }
774
+ .nav-collapse .dropdown-menu:before,
775
+ .nav-collapse .dropdown-menu:after {
776
+ display: none;
777
+ }
778
+ .nav-collapse .dropdown-menu .divider {
779
+ display: none;
780
+ }
781
+ .nav-collapse .navbar-form,
782
+ .nav-collapse .navbar-search {
783
+ float: none;
784
+ padding: 9px 15px;
785
+ margin: 9px 0;
786
+ border-top: 1px solid #222222;
787
+ border-bottom: 1px solid #222222;
788
+ -webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1), 0 1px 0 rgba(255, 255, 255, 0.1);
789
+ -moz-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1), 0 1px 0 rgba(255, 255, 255, 0.1);
790
+ box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1), 0 1px 0 rgba(255, 255, 255, 0.1);
791
+ }
792
+ .navbar .nav-collapse .nav.pull-right {
793
+ float: none;
794
+ margin-left: 0;
795
+ }
796
+ .nav-collapse,
797
+ .nav-collapse.collapse {
798
+ height: 0;
799
+ overflow: hidden;
800
+ }
801
+ .navbar .btn-navbar {
802
+ display: block;
803
+ }
804
+ .navbar-static .navbar-inner {
805
+ padding-right: 10px;
806
+ padding-left: 10px;
807
+ }
808
+ }
809
+
810
+ @media (min-width: 980px) {
811
+ .nav-collapse.collapse {
812
+ height: auto !important;
813
+ overflow: visible !important;
814
+ }
815
+ }