fetty-generators 1.7.1 → 2.0.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.
Files changed (167) hide show
  1. data/Gemfile +2 -0
  2. data/README.rdoc +42 -36
  3. data/Rakefile +1 -3
  4. data/lib/generators/fetty.rb +160 -10
  5. data/lib/generators/fetty/authentication/USAGE +4 -0
  6. data/lib/generators/fetty/authentication/authentication_generator.rb +171 -0
  7. data/lib/generators/fetty/authentication/templates/controllers/reset_passwords_controller.rb +45 -0
  8. data/lib/generators/fetty/authentication/templates/controllers/sessions_controller.rb +30 -0
  9. data/lib/generators/fetty/authentication/templates/controllers/users_controller.rb +78 -0
  10. data/lib/generators/fetty/authentication/templates/helpers/reset_passwords_helper.rb +2 -0
  11. data/lib/generators/fetty/authentication/templates/helpers/sessions_helper.rb +2 -0
  12. data/lib/generators/fetty/authentication/templates/helpers/users_helper.rb +2 -0
  13. data/lib/generators/fetty/authentication/templates/lib/sessions_authentication.rb +53 -0
  14. data/lib/generators/fetty/authentication/templates/lib/users_authentication.rb +110 -0
  15. data/lib/generators/fetty/authentication/templates/mailers/setup_mail.rb +11 -0
  16. data/lib/generators/fetty/authentication/templates/mailers/user_mailer.rb +14 -0
  17. data/lib/generators/fetty/authentication/templates/models/active_record/create_users.rb +17 -0
  18. data/lib/generators/fetty/authentication/templates/models/active_record/user.rb +15 -0
  19. data/lib/generators/fetty/authentication/templates/models/mongoid/user.rb +23 -0
  20. data/lib/generators/fetty/authentication/templates/spec/controllers/reset_passwords_controller_spec.rb +93 -0
  21. data/lib/generators/fetty/authentication/templates/spec/controllers/sessions_controller_spec.rb +61 -0
  22. data/lib/generators/fetty/authentication/templates/spec/controllers/users_controller_spec.rb +158 -0
  23. data/lib/generators/fetty/authentication/templates/spec/models/user_spec.rb +108 -0
  24. data/lib/generators/fetty/authentication/templates/spec/routing/reset_passwords_routing_spec.rb +21 -0
  25. data/lib/generators/fetty/authentication/templates/spec/routing/sessions_routing_spec.rb +17 -0
  26. data/lib/generators/fetty/authentication/templates/spec/routing/users_routing_spec.rb +37 -0
  27. data/lib/generators/fetty/authentication/templates/spec/support/user_factories.rb +6 -0
  28. data/lib/generators/fetty/authentication/templates/views/layouts/application.html.erb +33 -0
  29. data/lib/generators/fetty/authentication/templates/views/reset_passwords/edit.html.erb +19 -0
  30. data/lib/generators/fetty/authentication/templates/views/reset_passwords/new.html.erb +14 -0
  31. data/lib/generators/fetty/authentication/templates/views/sessions/new.html.erb +22 -0
  32. data/lib/generators/fetty/authentication/templates/views/user_mailer/user_activation.text.erb +4 -0
  33. data/lib/generators/fetty/authentication/templates/views/user_mailer/user_forgot_password.text.erb +7 -0
  34. data/lib/generators/fetty/authentication/templates/views/users/_table.html.erb +23 -0
  35. data/lib/generators/fetty/authentication/templates/views/users/edit.html.erb +21 -0
  36. data/lib/generators/fetty/authentication/templates/views/users/index.html.erb +7 -0
  37. data/lib/generators/fetty/authentication/templates/views/users/index.js.erb +1 -0
  38. data/lib/generators/fetty/authentication/templates/views/users/new.html.erb +23 -0
  39. data/lib/generators/fetty/authentication/templates/views/users/show.html.erb +19 -0
  40. data/lib/generators/fetty/messages/USAGE +4 -0
  41. data/lib/generators/fetty/messages/messages_generator.rb +136 -0
  42. data/lib/generators/fetty/messages/templates/assets/javascripts/jquery.tokeninput.js +718 -0
  43. data/lib/generators/fetty/messages/templates/assets/javascripts/messages.js +19 -0
  44. data/lib/generators/fetty/messages/templates/assets/stylesheets/messages.css +87 -0
  45. data/lib/generators/fetty/messages/templates/assets/stylesheets/token-input-facebook.css +122 -0
  46. data/lib/generators/fetty/messages/templates/controllers/messages_controller.rb +109 -0
  47. data/lib/generators/fetty/messages/templates/helpers/messages_helper.rb +2 -0
  48. data/lib/generators/fetty/messages/templates/lib/users_messages.rb +67 -0
  49. data/lib/generators/fetty/messages/templates/models/active_record/create_messages.rb +24 -0
  50. data/lib/generators/fetty/messages/templates/models/active_record/message.rb +67 -0
  51. data/lib/generators/fetty/messages/templates/models/mongoid/message.rb +81 -0
  52. data/lib/generators/fetty/messages/templates/spec/controllers/messages_controller_spec.rb +78 -0
  53. data/lib/generators/fetty/messages/templates/spec/models/message_spec.rb +53 -0
  54. data/lib/generators/fetty/messages/templates/spec/routing/messages_routing_spec.rb +61 -0
  55. data/lib/generators/fetty/messages/templates/spec/support/message_factories.rb +8 -0
  56. data/lib/generators/fetty/messages/templates/views/_head.html.erb +20 -0
  57. data/lib/generators/fetty/messages/templates/views/_messages.html.erb +56 -0
  58. data/lib/generators/fetty/messages/templates/views/_tabs_panel.html.erb +11 -0
  59. data/lib/generators/fetty/messages/templates/views/index.html.erb +10 -0
  60. data/lib/generators/fetty/messages/templates/views/index.js.erb +1 -0
  61. data/lib/generators/fetty/messages/templates/views/new.html.erb +26 -0
  62. data/lib/generators/fetty/messages/templates/views/show.html.erb +35 -0
  63. data/lib/generators/fetty/scaffold/USAGE +2 -52
  64. data/lib/generators/fetty/scaffold/scaffold_generator.rb +96 -329
  65. data/lib/generators/fetty/scaffold/templates/controllers/active_record/controller.rb +60 -0
  66. data/lib/generators/fetty/scaffold/templates/controllers/mongoid/controller.rb +60 -0
  67. data/lib/generators/fetty/scaffold/templates/helpers/helper.rb +2 -0
  68. data/lib/generators/fetty/scaffold/templates/models/active_record/migration.rb +16 -0
  69. data/lib/generators/fetty/scaffold/templates/models/active_record/model.rb +10 -0
  70. data/lib/generators/fetty/scaffold/templates/models/mongoid/model.rb +16 -0
  71. data/lib/generators/fetty/scaffold/templates/test/rspec/controller.rb +98 -0
  72. data/lib/generators/fetty/scaffold/templates/test/rspec/factories.rb +26 -0
  73. data/lib/generators/fetty/scaffold/templates/test/rspec/helper.rb +15 -0
  74. data/lib/generators/fetty/scaffold/templates/test/rspec/model.rb +9 -0
  75. data/lib/generators/fetty/scaffold/templates/test/rspec/request.rb +11 -0
  76. data/lib/generators/fetty/scaffold/templates/test/rspec/routing.rb +41 -0
  77. data/lib/generators/fetty/scaffold/templates/test/test_unit/controller.rb +62 -0
  78. data/lib/generators/fetty/scaffold/templates/{fixtures.yml → test/test_unit/fixtures.yml} +2 -0
  79. data/lib/generators/fetty/scaffold/templates/test/test_unit/helper.rb +4 -0
  80. data/lib/generators/fetty/scaffold/templates/test/test_unit/model.rb +7 -0
  81. data/lib/generators/fetty/scaffold/templates/views/_form.html.erb +20 -0
  82. data/lib/generators/fetty/scaffold/templates/views/_table.html.erb +48 -0
  83. data/lib/generators/fetty/scaffold/templates/views/edit.html.erb +13 -0
  84. data/lib/generators/fetty/scaffold/templates/views/index.html.erb +15 -0
  85. data/lib/generators/fetty/scaffold/templates/views/{erb/index.js.erb → index.js.erb} +0 -0
  86. data/lib/generators/fetty/scaffold/templates/views/new.html.erb +9 -0
  87. data/lib/generators/fetty/scaffold/templates/views/show.html.erb +28 -0
  88. data/lib/generators/fetty/setup/USAGE +3 -20
  89. data/lib/generators/fetty/setup/setup_generator.rb +122 -61
  90. data/lib/generators/fetty/setup/templates/ability.rb +0 -0
  91. data/lib/generators/fetty/setup/templates/ckeditor.rb +54 -0
  92. data/lib/generators/fetty/setup/templates/ckeditor.tar.gz +0 -0
  93. data/lib/generators/fetty/setup/templates/escape_utils.rb +7 -0
  94. data/lib/generators/fetty/setup/templates/file_uploader.rb +15 -0
  95. data/lib/generators/fetty/setup/templates/image_uploader.rb +48 -0
  96. data/lib/generators/fetty/setup/templates/spec_helper.rb +44 -0
  97. data/lib/generators/fetty/views/USAGE +5 -0
  98. data/lib/generators/fetty/{layout/templates/stylesheet.css → views/templates/application.css} +184 -166
  99. data/lib/generators/fetty/views/templates/application.html.erb +23 -0
  100. data/lib/generators/fetty/{layout → views}/templates/application.js +0 -0
  101. data/lib/generators/fetty/views/templates/application_helper.rb +10 -0
  102. data/lib/generators/fetty/views/templates/down_arrow.gif +0 -0
  103. data/lib/generators/fetty/{layout → views}/templates/error_messages_helper.rb +0 -0
  104. data/lib/generators/fetty/{layout → views}/templates/layout_helper.rb +0 -0
  105. data/lib/generators/fetty/views/templates/up_arrow.gif +0 -0
  106. data/lib/generators/fetty/views/views_generator.rb +51 -0
  107. data/lib/generators/scaffold.rb +204 -0
  108. metadata +126 -111
  109. data/LICENSE +0 -20
  110. data/lib/generators/fetty/layout/USAGE +0 -26
  111. data/lib/generators/fetty/layout/layout_generator.rb +0 -44
  112. data/lib/generators/fetty/layout/templates/layout.html.erb +0 -32
  113. data/lib/generators/fetty/layout/templates/layout.html.haml +0 -34
  114. data/lib/generators/fetty/layout/templates/no-devise-links-layout.html.erb +0 -23
  115. data/lib/generators/fetty/layout/templates/no-devise-links-layout.html.haml +0 -23
  116. data/lib/generators/fetty/layout/templates/stylesheet.sass +0 -163
  117. data/lib/generators/fetty/scaffold/templates/actions/create.rb +0 -8
  118. data/lib/generators/fetty/scaffold/templates/actions/destroy.rb +0 -5
  119. data/lib/generators/fetty/scaffold/templates/actions/edit.rb +0 -3
  120. data/lib/generators/fetty/scaffold/templates/actions/index.rb +0 -10
  121. data/lib/generators/fetty/scaffold/templates/actions/new.rb +0 -3
  122. data/lib/generators/fetty/scaffold/templates/actions/show.rb +0 -3
  123. data/lib/generators/fetty/scaffold/templates/actions/update.rb +0 -8
  124. data/lib/generators/fetty/scaffold/templates/controller.rb +0 -7
  125. data/lib/generators/fetty/scaffold/templates/helper.rb +0 -2
  126. data/lib/generators/fetty/scaffold/templates/migration.rb +0 -16
  127. data/lib/generators/fetty/scaffold/templates/model.rb +0 -7
  128. data/lib/generators/fetty/scaffold/templates/tests/rspec/actions/create.rb +0 -11
  129. data/lib/generators/fetty/scaffold/templates/tests/rspec/actions/destroy.rb +0 -6
  130. data/lib/generators/fetty/scaffold/templates/tests/rspec/actions/edit.rb +0 -4
  131. data/lib/generators/fetty/scaffold/templates/tests/rspec/actions/index.rb +0 -4
  132. data/lib/generators/fetty/scaffold/templates/tests/rspec/actions/new.rb +0 -4
  133. data/lib/generators/fetty/scaffold/templates/tests/rspec/actions/show.rb +0 -4
  134. data/lib/generators/fetty/scaffold/templates/tests/rspec/actions/update.rb +0 -11
  135. data/lib/generators/fetty/scaffold/templates/tests/rspec/controller.rb +0 -8
  136. data/lib/generators/fetty/scaffold/templates/tests/rspec/model.rb +0 -7
  137. data/lib/generators/fetty/scaffold/templates/tests/shoulda/actions/create.rb +0 -13
  138. data/lib/generators/fetty/scaffold/templates/tests/shoulda/actions/destroy.rb +0 -8
  139. data/lib/generators/fetty/scaffold/templates/tests/shoulda/actions/edit.rb +0 -6
  140. data/lib/generators/fetty/scaffold/templates/tests/shoulda/actions/index.rb +0 -6
  141. data/lib/generators/fetty/scaffold/templates/tests/shoulda/actions/new.rb +0 -6
  142. data/lib/generators/fetty/scaffold/templates/tests/shoulda/actions/show.rb +0 -6
  143. data/lib/generators/fetty/scaffold/templates/tests/shoulda/actions/update.rb +0 -13
  144. data/lib/generators/fetty/scaffold/templates/tests/shoulda/controller.rb +0 -5
  145. data/lib/generators/fetty/scaffold/templates/tests/shoulda/model.rb +0 -7
  146. data/lib/generators/fetty/scaffold/templates/tests/testunit/actions/create.rb +0 -11
  147. data/lib/generators/fetty/scaffold/templates/tests/testunit/actions/destroy.rb +0 -6
  148. data/lib/generators/fetty/scaffold/templates/tests/testunit/actions/edit.rb +0 -4
  149. data/lib/generators/fetty/scaffold/templates/tests/testunit/actions/index.rb +0 -4
  150. data/lib/generators/fetty/scaffold/templates/tests/testunit/actions/new.rb +0 -4
  151. data/lib/generators/fetty/scaffold/templates/tests/testunit/actions/show.rb +0 -4
  152. data/lib/generators/fetty/scaffold/templates/tests/testunit/actions/update.rb +0 -11
  153. data/lib/generators/fetty/scaffold/templates/tests/testunit/controller.rb +0 -5
  154. data/lib/generators/fetty/scaffold/templates/tests/testunit/model.rb +0 -7
  155. data/lib/generators/fetty/scaffold/templates/views/erb/_form.html.erb +0 -22
  156. data/lib/generators/fetty/scaffold/templates/views/erb/_table.html.erb +0 -50
  157. data/lib/generators/fetty/scaffold/templates/views/erb/edit.html.erb +0 -12
  158. data/lib/generators/fetty/scaffold/templates/views/erb/index.html.erb +0 -13
  159. data/lib/generators/fetty/scaffold/templates/views/erb/new.html.erb +0 -9
  160. data/lib/generators/fetty/scaffold/templates/views/erb/show.html.erb +0 -26
  161. data/lib/generators/fetty/scaffold/templates/views/haml/_form.html.haml +0 -8
  162. data/lib/generators/fetty/scaffold/templates/views/haml/_table.html.haml +0 -33
  163. data/lib/generators/fetty/scaffold/templates/views/haml/edit.html.haml +0 -14
  164. data/lib/generators/fetty/scaffold/templates/views/haml/index.html.haml +0 -12
  165. data/lib/generators/fetty/scaffold/templates/views/haml/index.js.haml +0 -1
  166. data/lib/generators/fetty/scaffold/templates/views/haml/new.html.haml +0 -8
  167. data/lib/generators/fetty/scaffold/templates/views/haml/show.html.haml +0 -23
@@ -0,0 +1,7 @@
1
+ module Rack
2
+ module Utils
3
+ def escape(s)
4
+ EscapeUtils.escape_url(s)
5
+ end
6
+ end
7
+ end
@@ -0,0 +1,15 @@
1
+ # encoding: utf-8
2
+
3
+ class FileUploader < CarrierWave::Uploader::Base
4
+
5
+ # Choose what kind of storage to use for this uploader:
6
+ storage :file
7
+ # storage :fog
8
+
9
+ # Override the directory where uploaded files will be stored.
10
+ # This is a sensible default for uploaders that are meant to be mounted:
11
+ def store_dir
12
+ "uploads/#{model.class.to_s.underscore}/#{mounted_as}/#{model.id}"
13
+ end
14
+
15
+ end
@@ -0,0 +1,48 @@
1
+ # encoding: utf-8
2
+
3
+ class ImageUploader < CarrierWave::Uploader::Base
4
+
5
+ # Include RMagick or ImageScience support:
6
+ include CarrierWave::MiniMagick
7
+ # include CarrierWave::ImageScience
8
+
9
+ # Choose what kind of storage to use for this uploader:
10
+ storage :file
11
+ # storage :fog
12
+
13
+ # Override the directory where uploaded files will be stored.
14
+ # This is a sensible default for uploaders that are meant to be mounted:
15
+ def store_dir
16
+ "uploads/#{model.class.to_s.underscore}/#{mounted_as}/#{model.id}"
17
+ end
18
+
19
+ # Provide a default URL as a default if there hasn't been a file uploaded:
20
+ # def default_url
21
+ # "/images/fallback/" + [version_name, "default.png"].compact.join('_')
22
+ # end
23
+
24
+ # Process files as they are uploaded:
25
+ # process :scale => [200, 300]
26
+ #
27
+ # def scale(width, height)
28
+ # # do something
29
+ # end
30
+
31
+ # Create different versions of your uploaded files:
32
+ version :small do
33
+ process :resize_to_limit => [100, 100]
34
+ end
35
+
36
+ # Add a white list of extensions which are allowed to be uploaded.
37
+ # For images you might use something like this:
38
+ # def extension_white_list
39
+ # %w(jpg jpeg gif png)
40
+ # end
41
+
42
+ # Override the filename of the uploaded files:
43
+ # Avoid using model.id or version_name here, see uploader/store.rb for details.
44
+ # def filename
45
+ # "something.jpg" if original_filename
46
+ # end
47
+
48
+ end
@@ -0,0 +1,44 @@
1
+ # This file is copied to spec/ when you run 'rails generate rspec:install'
2
+ ENV["RAILS_ENV"] ||= 'test'
3
+ require File.expand_path("../../config/environment", __FILE__)
4
+ require 'rspec/rails'
5
+
6
+ # Requires supporting ruby files with custom matchers and macros, etc,
7
+ # in spec/support/ and its subdirectories.
8
+ Dir[Rails.root.join("spec/support/**/*.rb")].each {|f| require f}
9
+
10
+ RSpec.configure do |config|
11
+ # == Mock Framework
12
+ #
13
+ # If you prefer to use mocha, flexmock or RR, uncomment the appropriate line:
14
+ #
15
+ # config.mock_with :mocha
16
+ # config.mock_with :flexmock
17
+ # config.mock_with :rr
18
+ config.mock_with :rspec
19
+
20
+ # Remove this line if you're not using ActiveRecord or ActiveRecord fixtures
21
+ # config.fixture_path = "#{::Rails.root}/spec/fixtures"
22
+
23
+ # If you're not using ActiveRecord, or you'd prefer not to run each of your
24
+ # examples within a transaction, remove the following line or assign false
25
+ # instead of true.
26
+ # config.use_transactional_fixtures = true
27
+
28
+ config.before(:suite) do
29
+ DatabaseCleaner.strategy = <%= using_mongoid? ? ':truncation' : ':transaction' %>
30
+ end
31
+
32
+ config.before(:each) do
33
+ DatabaseCleaner.start
34
+ end
35
+
36
+ config.after(:each) do
37
+ DatabaseCleaner.clean
38
+ end
39
+
40
+ end
41
+
42
+ def stub_authenticate_user
43
+ controller.stub(:authenticate_user!).and_return(true)
44
+ end
@@ -0,0 +1,5 @@
1
+ Description:
2
+ The fetty:views generator creates a basic layout, stylesheet and
3
+ helper which will give some structure to starting your Rails app.
4
+
5
+ Also able to convert your template views from ERB to HAML or vice versa.
@@ -1,166 +1,184 @@
1
- body {
2
- background-color: #D0D0D0;
3
- font-family: Verdana, Helvetica, Arial;
4
- font-size: 14px;
5
- }
6
-
7
- a img {
8
- border: none;
9
- }
10
-
11
- a {
12
- color: #0000FF;
13
- }
14
-
15
- input.hint {
16
- color: #999;
17
- font-style :italic;
18
- }
19
-
20
- .clear {
21
- clear: both;
22
- height: 0;
23
- overflow: hidden;
24
- }
25
-
26
- #container {
27
- width: 75%;
28
- margin: 0 auto;
29
- background-color: #FFF;
30
- padding: 20px 40px;
31
- border: solid 1px black;
32
- margin-top: 20px;
33
- }
34
-
35
- #loginbox {
36
- float: right;
37
- }
38
-
39
- #flash_notice {
40
- background-color: #CCEECC;
41
- color: #006600;
42
- text-shadow: 1px 1px 1px #FFFFFF;
43
- }
44
-
45
- #flash_error {
46
- background-color: #FFFFD7;
47
- color: #555555;
48
- text-shadow: 1px 1px 1px #FFFFFF;
49
- }
50
-
51
- #flash_alert {
52
- background-color: #F7E1DF;
53
- color: #B81010;
54
- text-shadow: 1px 1px 1px #FCF4F3;
55
- }
56
-
57
- .flash {
58
- border: 1px solid #D5D5D5;
59
- color: #555555;
60
- font-size: 13px;
61
- font-weight: bold;
62
- margin: 10px 0;
63
- padding: 10px;
64
- }
65
-
66
- .closable {
67
- position: relative;
68
- }
69
- .closable .closelink {
70
- cursor: pointer;
71
- height: 16px;
72
- margin-top: -4px;
73
- opacity: 0.3;
74
- position: absolute;
75
- right: 8px;
76
- top: 15px;
77
- }
78
- .closelink:hover {
79
- opacity: 1;
80
- }
81
-
82
-
83
- .fieldWithErrors {
84
- display: inline;
85
- }
86
-
87
- .error_messages {
88
- width: 400px;
89
- border: 2px solid #CF0000;
90
- padding: 0px;
91
- padding-bottom: 12px;
92
- margin-bottom: 20px;
93
- background-color: #f0f0f0;
94
- font-size: 12px;
95
- }
96
-
97
- .error_messages h2 {
98
- text-align: left;
99
- font-weight: bold;
100
- padding: 5px 10px;
101
- font-size: 12px;
102
- margin: 0;
103
- background-color: #c00;
104
- color: #fff;
105
- }
106
-
107
- .error_messages p {
108
- margin: 8px 10px;
109
- }
110
-
111
- .error_messages ul {
112
- margin: 0;
113
- }
114
-
115
- /* pretty-table */
116
- table.pretty {
117
- border-collapse: collapse;
118
- }
119
-
120
- .pretty td, .pretty th {
121
- padding: 4px 10px;
122
- border: solid 1px #AAA;
123
- }
124
-
125
- /* simple-form */
126
- .simple_form label {
127
- float: left;
128
- width: 100px;
129
- text-align: right;
130
- margin: 2px 10px;
131
- }
132
-
133
- .simple_form div.input {
134
- margin-bottom: 10px;
135
- }
136
-
137
- .simple_form div.boolean, .simple_form input[type='submit'] {
138
- margin-left: 120px;
139
- }
140
-
141
- .simple_form div.boolean label, .simple_form label.collection_radio {
142
- float: none;
143
- margin: 0;
144
- }
145
-
146
- .simple_form label.collection_radio {
147
- margin-right: 10px;
148
- margin-left: 2px;
149
- }
150
-
151
- .simple_form .error {
152
- clear: left;
153
- margin-left: 120px;
154
- font-size: 12px;
155
- color: #D00;
156
- display: block;
157
- }
158
-
159
- .simple_form .hint {
160
- clear: left;
161
- margin-left: 120px;
162
- font-size: 12px;
163
- color: #555;
164
- display: block;
165
- font-style: italic;
166
- }
1
+ body {
2
+ background-color: #D0D0D0;
3
+ font-family: Verdana, Helvetica, Arial;
4
+ font-size: 14px;
5
+ }
6
+
7
+ a img {
8
+ border: none;
9
+ }
10
+
11
+ a {
12
+ color: #0000FF;
13
+ }
14
+
15
+ input.hint {
16
+ color: #999;
17
+ font-style :italic;
18
+ }
19
+
20
+ .clear {
21
+ clear: both;
22
+ height: 0;
23
+ overflow: hidden;
24
+ }
25
+
26
+ #container {
27
+ width: 75%;
28
+ margin: 0 auto;
29
+ background-color: #FFF;
30
+ padding: 20px 40px;
31
+ border: solid 1px black;
32
+ margin-top: 20px;
33
+ }
34
+
35
+ #loginbox {
36
+ float: right;
37
+ }
38
+
39
+ #flash_notice {
40
+ background-color: #CCEECC;
41
+ color: #006600;
42
+ text-shadow: 1px 1px 1px #FFFFFF;
43
+ }
44
+
45
+ #flash_error {
46
+ background-color: #FFFFD7;
47
+ color: #555555;
48
+ text-shadow: 1px 1px 1px #FFFFFF;
49
+ }
50
+
51
+ #flash_alert {
52
+ background-color: #F7E1DF;
53
+ color: #B81010;
54
+ text-shadow: 1px 1px 1px #FCF4F3;
55
+ }
56
+
57
+ .flash {
58
+ border: 1px solid #D5D5D5;
59
+ color: #555555;
60
+ font-size: 13px;
61
+ font-weight: bold;
62
+ margin: 10px 0;
63
+ padding: 10px;
64
+ }
65
+
66
+ .closable {
67
+ position: relative;
68
+ }
69
+ .closable .closelink {
70
+ cursor: pointer;
71
+ height: 16px;
72
+ margin-top: -4px;
73
+ opacity: 0.3;
74
+ position: absolute;
75
+ right: 8px;
76
+ top: 15px;
77
+ }
78
+ .closelink:hover {
79
+ opacity: 1;
80
+ }
81
+
82
+
83
+ .fieldWithErrors {
84
+ display: inline;
85
+ }
86
+
87
+ .error_messages {
88
+ width: 400px;
89
+ border: 2px solid #CF0000;
90
+ padding: 0px;
91
+ padding-bottom: 12px;
92
+ margin-bottom: 20px;
93
+ background-color: #f0f0f0;
94
+ font-size: 12px;
95
+ }
96
+
97
+ .error_messages h2 {
98
+ text-align: left;
99
+ font-weight: bold;
100
+ padding: 5px 10px;
101
+ font-size: 12px;
102
+ margin: 0;
103
+ background-color: #c00;
104
+ color: #fff;
105
+ }
106
+
107
+ .error_messages p {
108
+ margin: 8px 10px;
109
+ }
110
+
111
+ .error_messages ul {
112
+ margin: 0;
113
+ }
114
+
115
+ /* pretty-table */
116
+ table.pretty {
117
+ border-collapse: collapse;
118
+ }
119
+
120
+ .pretty td, .pretty th {
121
+ padding: 4px 10px;
122
+ border: solid 1px #AAA;
123
+ }
124
+
125
+ .pretty th .current {
126
+ padding-right: 12px;
127
+ background-repeat: no-repeat;
128
+ background-position: right center;
129
+ }
130
+
131
+ .pretty th .asc {
132
+ background-image: url('/images/up_arrow.gif');
133
+ }
134
+
135
+ .pretty th .desc {
136
+ background-image: url('/images/down_arrow.gif');
137
+ }
138
+
139
+ .pretty tr.alt { background-color: #EBEBEB; }
140
+
141
+ .pretty tr.unread { font-weight: bold; }
142
+
143
+ /* simple-form */
144
+ .simple_form label {
145
+ float: left;
146
+ width: 100px;
147
+ text-align: right;
148
+ margin: 2px 10px;
149
+ }
150
+
151
+ .simple_form div.input {
152
+ margin-bottom: 10px;
153
+ }
154
+
155
+ .simple_form div.boolean, .simple_form input[type='submit'] {
156
+ margin-left: 120px;
157
+ }
158
+
159
+ .simple_form div.boolean label, .simple_form label.collection_radio {
160
+ float: none;
161
+ margin: 0;
162
+ }
163
+
164
+ .simple_form label.collection_radio {
165
+ margin-right: 10px;
166
+ margin-left: 2px;
167
+ }
168
+
169
+ .simple_form .error {
170
+ clear: left;
171
+ margin-left: 120px;
172
+ font-size: 12px;
173
+ color: #D00;
174
+ display: block;
175
+ }
176
+
177
+ .simple_form .hint {
178
+ clear: left;
179
+ margin-left: 120px;
180
+ font-size: 12px;
181
+ color: #555;
182
+ display: block;
183
+ font-style: italic;
184
+ }