andrewroth_activeadmin 0.3.4 → 0.3.4.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (201) hide show
  1. data/CHANGELOG.md +159 -3
  2. data/CONTRIBUTING.md +113 -0
  3. data/LICENSE +1 -1
  4. data/README.rdoc +19 -20
  5. data/activeadmin.gemspec +3 -1
  6. data/app/assets/javascripts/active_admin/application.js +9 -0
  7. data/app/assets/javascripts/active_admin/base.js +4 -12
  8. data/app/assets/stylesheets/active_admin/_base.css.scss +16 -340
  9. data/app/assets/stylesheets/active_admin/_forms.css.scss +13 -7
  10. data/app/assets/stylesheets/active_admin/_header.css.scss +23 -4
  11. data/app/assets/stylesheets/active_admin/components/_blank_slates.scss +31 -0
  12. data/app/assets/stylesheets/active_admin/components/_breadcrumbs.scss +20 -0
  13. data/app/assets/stylesheets/active_admin/components/_buttons.scss +12 -0
  14. data/app/assets/stylesheets/active_admin/components/_flash_messages.css.scss +2 -0
  15. data/app/assets/stylesheets/active_admin/components/_grid.scss +9 -0
  16. data/app/assets/stylesheets/active_admin/components/_links.scss +5 -0
  17. data/app/assets/stylesheets/active_admin/components/_pagination.scss +34 -0
  18. data/app/assets/stylesheets/active_admin/components/_panels.scss +6 -0
  19. data/app/assets/stylesheets/active_admin/components/_scopes.scss +10 -0
  20. data/app/assets/stylesheets/active_admin/components/_status_tags.scss +12 -0
  21. data/app/assets/stylesheets/active_admin/components/_table_tools.css.scss +101 -0
  22. data/app/assets/stylesheets/active_admin/mixins/_all.css.scss +2 -1
  23. data/app/assets/stylesheets/active_admin/mixins/_buttons.css.scss +50 -13
  24. data/app/assets/stylesheets/active_admin/mixins/_gradients.css.scss +9 -1
  25. data/app/assets/stylesheets/active_admin/mixins/_sections.css.scss +7 -5
  26. data/app/assets/stylesheets/active_admin/mixins/_shadows.css.scss +1 -0
  27. data/app/assets/stylesheets/active_admin/mixins/_typography.scss +3 -0
  28. data/app/assets/stylesheets/active_admin/mixins/_variables.css.scss +1 -0
  29. data/app/assets/stylesheets/active_admin/pages/_dashboard.scss +5 -0
  30. data/app/assets/stylesheets/active_admin/pages/_logged_out.scss +44 -0
  31. data/app/assets/stylesheets/active_admin/structure/_footer.scss +14 -0
  32. data/app/assets/stylesheets/active_admin/structure/_main_structure.scss +26 -0
  33. data/app/assets/stylesheets/active_admin/structure/_title_bar.scss +44 -0
  34. data/app/views/active_admin/devise/passwords/edit.html.erb +1 -1
  35. data/app/views/active_admin/devise/passwords/new.html.erb +1 -1
  36. data/app/views/active_admin/devise/sessions/new.html.erb +1 -1
  37. data/app/views/active_admin/devise/shared/_links.erb +1 -1
  38. data/app/views/active_admin/devise/unlocks/new.html.erb +1 -1
  39. data/app/views/active_admin/page/index.html.arb +1 -0
  40. data/app/views/layouts/active_admin_logged_out.html.erb +2 -2
  41. data/cucumber.yml +3 -2
  42. data/docs/1-general-configuration.md +46 -10
  43. data/docs/6-show-screens.md +7 -0
  44. data/docs/8-custom-actions.md +12 -2
  45. data/docs/9-custom-pages.md +84 -0
  46. data/features/belongs_to.feature +27 -0
  47. data/features/comments/commenting.feature +3 -2
  48. data/features/dashboard.feature +18 -0
  49. data/features/development_reloading.feature +19 -0
  50. data/features/index/filter_with_check_boxes.feature +25 -0
  51. data/features/index/index_as_table.feature +14 -0
  52. data/features/index/index_scopes.feature +42 -0
  53. data/features/index/pagination.feature +19 -1
  54. data/features/menu.feature +22 -2
  55. data/features/registering_assets.feature +2 -2
  56. data/features/registering_pages.feature +66 -0
  57. data/features/specifying_actions.feature +5 -0
  58. data/features/step_definitions/action_item_steps.rb +2 -6
  59. data/features/step_definitions/action_link_steps.rb +7 -0
  60. data/features/step_definitions/additional_web_steps.rb +8 -0
  61. data/features/step_definitions/asset_steps.rb +5 -1
  62. data/features/step_definitions/breadcrumb_steps.rb +5 -0
  63. data/features/step_definitions/configuration_steps.rb +56 -8
  64. data/features/step_definitions/dashboard_steps.rb +5 -1
  65. data/features/step_definitions/factory_steps.rb +9 -2
  66. data/features/step_definitions/flash_steps.rb +9 -1
  67. data/features/step_definitions/index_scope_steps.rb +16 -4
  68. data/features/step_definitions/member_link_steps.rb +7 -0
  69. data/features/step_definitions/site_title_steps.rb +15 -0
  70. data/features/support/paths.rb +6 -0
  71. data/features/users/logging_out.feature +11 -0
  72. data/lib/active_admin.rb +25 -10
  73. data/lib/active_admin/application.rb +63 -20
  74. data/lib/active_admin/arbre/html/element.rb +10 -0
  75. data/lib/active_admin/asset_registration.rb +15 -2
  76. data/lib/active_admin/base_controller.rb +61 -0
  77. data/lib/active_admin/{resource_controller → base_controller}/menu.rb +1 -1
  78. data/lib/active_admin/comments.rb +48 -54
  79. data/lib/active_admin/comments/comment.rb +13 -2
  80. data/lib/active_admin/comments/namespace_helper.rb +1 -1
  81. data/lib/active_admin/comments/views/active_admin_comments.rb +7 -3
  82. data/lib/active_admin/dashboards.rb +4 -0
  83. data/lib/active_admin/dashboards/dashboard_controller.rb +20 -4
  84. data/lib/active_admin/dsl.rb +6 -159
  85. data/lib/active_admin/event.rb +5 -3
  86. data/lib/active_admin/filter_form_builder.rb +53 -0
  87. data/lib/active_admin/form_builder.rb +25 -19
  88. data/lib/active_admin/inputs.rb +14 -0
  89. data/lib/active_admin/inputs/datepicker_input.rb +11 -0
  90. data/lib/active_admin/inputs/filter_base.rb +46 -0
  91. data/lib/active_admin/inputs/filter_check_boxes_input.rb +40 -0
  92. data/lib/active_admin/inputs/filter_date_range_input.rb +34 -0
  93. data/lib/active_admin/inputs/filter_numeric_input.rb +55 -0
  94. data/lib/active_admin/inputs/filter_select_input.rb +23 -0
  95. data/lib/active_admin/inputs/filter_string_input.rb +22 -0
  96. data/lib/active_admin/locales/ca.yml +44 -0
  97. data/lib/active_admin/locales/cs.yml +14 -10
  98. data/lib/active_admin/locales/de.yml +43 -0
  99. data/lib/active_admin/locales/en.yml +5 -0
  100. data/lib/active_admin/locales/hr.yml +40 -0
  101. data/lib/active_admin/locales/ko.yml +40 -0
  102. data/lib/active_admin/locales/lv.yml +43 -0
  103. data/lib/active_admin/locales/nl.yml +40 -0
  104. data/lib/active_admin/locales/no-NB.yml +40 -0
  105. data/lib/active_admin/locales/pl.yml +7 -1
  106. data/lib/active_admin/locales/pt-BR.yml +6 -2
  107. data/lib/active_admin/namespace.rb +48 -33
  108. data/lib/active_admin/page.rb +54 -0
  109. data/lib/active_admin/page_controller.rb +15 -0
  110. data/lib/active_admin/page_dsl.rb +21 -0
  111. data/lib/active_admin/page_presenter.rb +30 -0
  112. data/lib/active_admin/resource.rb +38 -44
  113. data/lib/active_admin/resource/action_items.rb +5 -0
  114. data/lib/active_admin/resource/belongs_to.rb +4 -2
  115. data/lib/active_admin/resource/controllers.rb +35 -0
  116. data/lib/active_admin/resource/menu.rb +1 -2
  117. data/lib/active_admin/resource/naming.rb +43 -31
  118. data/lib/active_admin/resource/page_presenters.rb +28 -0
  119. data/lib/active_admin/resource/scopes.rb +16 -3
  120. data/lib/active_admin/resource/sidebars.rb +4 -0
  121. data/lib/active_admin/resource_collection.rb +88 -0
  122. data/lib/active_admin/resource_controller.rb +18 -54
  123. data/lib/active_admin/resource_controller/action_builder.rb +1 -1
  124. data/lib/active_admin/resource_controller/actions.rb +1 -1
  125. data/lib/active_admin/resource_controller/callbacks.rb +1 -1
  126. data/lib/active_admin/resource_controller/collection.rb +8 -4
  127. data/lib/active_admin/resource_controller/filters.rb +1 -1
  128. data/lib/active_admin/resource_controller/resource_class_methods.rb +24 -0
  129. data/lib/active_admin/resource_controller/scoping.rb +1 -1
  130. data/lib/active_admin/resource_controller/sidebars.rb +1 -1
  131. data/lib/active_admin/resource_dsl.rb +157 -0
  132. data/lib/active_admin/router.rb +21 -14
  133. data/lib/active_admin/scope.rb +15 -3
  134. data/lib/active_admin/version.rb +1 -1
  135. data/lib/active_admin/view_factory.rb +4 -3
  136. data/lib/active_admin/view_helpers/auto_link_helper.rb +1 -10
  137. data/lib/active_admin/view_helpers/breadcrumb_helper.rb +25 -21
  138. data/lib/active_admin/view_helpers/filter_form_helper.rb +0 -150
  139. data/lib/active_admin/views/components/attributes_table.rb +1 -1
  140. data/lib/active_admin/views/components/paginated_collection.rb +42 -13
  141. data/lib/active_admin/views/components/scopes.rb +17 -17
  142. data/lib/active_admin/views/components/status_tag.rb +6 -5
  143. data/lib/active_admin/views/components/table_for.rb +6 -2
  144. data/lib/active_admin/views/header_renderer.rb +31 -12
  145. data/lib/active_admin/views/index_as_block.rb +2 -2
  146. data/lib/active_admin/views/index_as_blog.rb +3 -3
  147. data/lib/active_admin/views/index_as_grid.rb +4 -4
  148. data/lib/active_admin/views/index_as_table.rb +13 -6
  149. data/lib/active_admin/views/pages/base.rb +4 -4
  150. data/lib/active_admin/views/pages/form.rb +49 -0
  151. data/lib/active_admin/views/pages/index.rb +18 -6
  152. data/lib/active_admin/views/pages/page.rb +24 -0
  153. data/lib/active_admin/views/pages/show.rb +1 -1
  154. data/lib/generators/active_admin/assets/assets_generator.rb +19 -1
  155. data/lib/generators/active_admin/install/templates/active_admin.rb.erb +38 -12
  156. data/lib/generators/active_admin/install/templates/dashboards.rb +6 -0
  157. data/spec/spec_helper.rb +4 -0
  158. data/spec/support/rails_template.rb +11 -0
  159. data/spec/support/templates/cucumber_with_reloading.rb +5 -0
  160. data/spec/unit/active_admin_spec.rb +8 -0
  161. data/spec/unit/application_spec.rb +48 -2
  162. data/spec/unit/arbre/html/element_finder_methods_spec.rb +58 -2
  163. data/spec/unit/asset_registration_spec.rb +9 -3
  164. data/spec/unit/auto_link_spec.rb +2 -2
  165. data/spec/unit/base_controller_shared_examples.rb +28 -0
  166. data/spec/unit/base_controller_spec.rb +8 -0
  167. data/spec/unit/belongs_to_spec.rb +30 -33
  168. data/spec/unit/comments_spec.rb +45 -15
  169. data/spec/unit/config_shared_examples.rb +108 -0
  170. data/spec/unit/dashboard_controller_spec.rb +44 -0
  171. data/spec/unit/event_spec.rb +6 -0
  172. data/spec/unit/filter_form_builder_spec.rb +9 -0
  173. data/spec/unit/form_builder_spec.rb +8 -14
  174. data/spec/unit/namespace/register_page_spec.rb +102 -0
  175. data/spec/unit/namespace/register_resource_spec.rb +188 -0
  176. data/spec/unit/namespace_spec.rb +11 -183
  177. data/spec/unit/page_controller_spec.rb +8 -0
  178. data/spec/unit/page_spec.rb +60 -0
  179. data/spec/unit/resource/menu_spec.rb +1 -51
  180. data/spec/unit/resource/naming_spec.rb +24 -19
  181. data/spec/unit/resource/page_presenters_spec.rb +32 -0
  182. data/spec/unit/resource/scopes_spec.rb +13 -0
  183. data/spec/unit/resource_collection_spec.rb +101 -0
  184. data/spec/unit/resource_controller_spec.rb +40 -32
  185. data/spec/unit/{registration_spec.rb → resource_registration_spec.rb} +0 -0
  186. data/spec/unit/resource_spec.rb +8 -24
  187. data/spec/unit/routing_spec.rb +50 -1
  188. data/spec/unit/scope_spec.rb +18 -4
  189. data/spec/unit/views/components/paginated_collection_spec.rb +150 -0
  190. data/spec/unit/views/components/status_tag_spec.rb +9 -0
  191. data/tasks/test.rake +43 -27
  192. metadata +140 -31
  193. data/app/assets/javascripts/active_admin/vendor.js +0 -382
  194. data/lib/active_admin/comments/configuration.rb +0 -18
  195. data/lib/active_admin/page_config.rb +0 -15
  196. data/lib/active_admin/resource_controller/form.rb +0 -42
  197. data/lib/active_admin/resource_controller/page_configurations.rb +0 -53
  198. data/lib/active_admin/views/pages/edit.rb +0 -28
  199. data/lib/active_admin/views/pages/new.rb +0 -28
  200. data/lib/generators/active_admin/assets/templates/3.0/active_admin.js +0 -427
  201. data/spec/integration/belongs_to_spec.rb +0 -42
@@ -81,7 +81,7 @@ form {
81
81
  border: 1px solid #c9d0d6;
82
82
  @include rounded;
83
83
  font-size: 0.95em;
84
- font-family: Helvetica, Arial, sans-serif;
84
+ @include sans-family;
85
85
  outline: none;
86
86
  padding: 8px $text-input-horizontal-padding 7px;
87
87
 
@@ -138,8 +138,6 @@ form {
138
138
  }
139
139
  }
140
140
 
141
- &.hidden { display: none; }
142
-
143
141
  /* Errors */
144
142
  p.inline-errors {
145
143
  text-transform:capitalize;
@@ -163,7 +161,11 @@ form {
163
161
 
164
162
  /* Buttons */
165
163
 
166
- input[type=submit] { @include dark-button; }
164
+ input[type=submit] {
165
+ @include dark-button;
166
+ cursor: pointer;
167
+
168
+ }
167
169
 
168
170
  .buttons {
169
171
  margin-top: 15px;
@@ -172,9 +174,13 @@ form {
172
174
 
173
175
  fieldset.buttons li {
174
176
  float:left;
175
- padding-right:0.5em;
176
- padding-top: 0;
177
- &.cancel { margin-left: 0.3em; padding: 5px; a { @include light-button; @include icon(#777, 9px);} }
177
+ padding: 0;
178
+
179
+ &.cancel {
180
+ a {
181
+ @include light-button; @include icon(#777, 9px);
182
+ }
183
+ }
178
184
  }
179
185
 
180
186
  }
@@ -5,15 +5,20 @@
5
5
  @include primary-gradient;
6
6
  @include shadow;
7
7
  @include text-shadow(#000);
8
+ height: 20px;
8
9
  overflow: visible;
10
+ position: relative;
9
11
  padding: 9px $horizontal-page-margin;
12
+ position: relative;
10
13
  z-index: 900;
11
14
 
12
15
  h1 {
13
16
  display: inline-block;
14
17
  color: #cdcdcd;
18
+ float: left;
15
19
  margin-right: 20px;
16
20
  margin-bottom: 0px;
21
+ padding-top: 3px;
17
22
  font-size: 1.3em;
18
23
  font-weight: normal;
19
24
 
@@ -23,17 +28,28 @@
23
28
  &:hover {
24
29
  color: #fff;
25
30
  }
26
-
27
31
  }
32
+
33
+ img {
34
+ position: relative;
35
+ top: -2px;
36
+ }
28
37
  }
29
38
 
30
39
  a, a:link { color: #cdcdcd; }
31
40
 
41
+ .header-item {
42
+ float: left;
43
+ top: 2px;
44
+ position: relative;
45
+ height: 20px
46
+ }
47
+
32
48
  ul#tabs {
33
- margin: 0;
34
- padding: 0;
35
49
  display: inline-block;
36
50
  height: 100%;
51
+ margin: 0;
52
+ padding: 0;
37
53
 
38
54
  & > li {
39
55
  display: inline-block;
@@ -110,8 +126,11 @@
110
126
  }
111
127
 
112
128
  #utility_nav {
113
- position: absolute; right: 25px; top: 10px;
114
129
  color: #aaa;
130
+ float: right;
131
+ display: inline-block;
132
+ margin: 0;
133
+ padding: 0;
115
134
  span, a { margin-left: 10px; }
116
135
 
117
136
  a { text-decoration: none; }
@@ -0,0 +1,31 @@
1
+ .blank_slate_container {
2
+ clear: both;
3
+ text-align: center;
4
+
5
+ .blank_slate {
6
+ @include rounded;
7
+ -webkit-font-smoothing: antialiased;
8
+ border: 1px dashed #DADADA;
9
+ color: #AAA;
10
+ display: inline-block;
11
+ font-size: 1.2em;
12
+ font-weight: bold;
13
+ padding: 14px 25px;
14
+ text-align: center;
15
+
16
+ small {
17
+ display: block;
18
+ font-size: 0.9em;
19
+ font-weight: normal;
20
+ }
21
+ }
22
+ }
23
+
24
+ .admin_dashboard .blank_slate_container .blank_slate {
25
+ margin-top: 40px;
26
+ margin-bottom: 40px;
27
+ }
28
+
29
+ .with_sidebar .blank_slate_container .blank_slate {
30
+ margin-top: 80px;
31
+ }
@@ -0,0 +1,20 @@
1
+ .breadcrumb {
2
+ display: block;
3
+ font-size: 0.9em;
4
+ font-weight: normal;
5
+ line-height: 1.0em;
6
+ margin-bottom: 12px;
7
+ text-transform: uppercase;
8
+
9
+ a, a:link, a:visited, a:active {
10
+ color: #8a949e ;
11
+ text-decoration: none;
12
+ }
13
+
14
+ a:hover { text-decoration: underline; }
15
+
16
+ .breadcrumb_sep {
17
+ margin: 0 2px;
18
+ color: #aab2ba;
19
+ }
20
+ }
@@ -0,0 +1,12 @@
1
+
2
+ td, p {
3
+ @include icon(#B3BCC1, 0.8em);
4
+ span.icon { margin: 0 3px; }
5
+ }
6
+
7
+ a.member_link {
8
+ margin-right: 7px;
9
+ white-space: nowrap;
10
+ }
11
+
12
+ a.button, a:link.button, a:visited.button, input[type=submit] { @include dark-button; }
@@ -11,6 +11,8 @@ body.logged_in {
11
11
  line-height: 1.0em;
12
12
  margin-bottom: 10px;
13
13
  padding: 13px 30px 11px;
14
+ position: relative;
15
+ top: -15px;
14
16
 
15
17
  &.flash_notice {
16
18
  @include gradient(#dce9dd, #ccdfcd);
@@ -0,0 +1,9 @@
1
+ // -------------------------------------- Index as Grid
2
+ table.index_grid td { border: none; background: none; padding: 0 20px 20px 0; margin: 0;}
3
+
4
+ // -------------------------------------- Columns
5
+ .columns {
6
+ clear: both;
7
+ padding: 0;
8
+ .column { float: left; }
9
+ }
@@ -0,0 +1,5 @@
1
+ a, a:link, a:visited {
2
+ color: $link-color;
3
+ text-decoration: underline;
4
+ }
5
+ a:hover { text-decoration: none; }
@@ -0,0 +1,34 @@
1
+ .paginated_collection_contents {
2
+ clear: both;
3
+ }
4
+
5
+ .pagination {
6
+ float: right;
7
+ font-size: 0.9em;
8
+ margin-left: 10px;
9
+
10
+ a {
11
+ @include light-button;
12
+ }
13
+
14
+ span.page.current {
15
+ @include default-button;
16
+ }
17
+
18
+ a, span.page.current {
19
+ @include rounded(0px);
20
+ margin-right: 4px;
21
+ padding: 2px 5px;
22
+ }
23
+ }
24
+
25
+ .pagination_information {
26
+ float: right;
27
+ margin-bottom: 5px;
28
+ color: #b3bcc1;
29
+ b { color: #5c6469; }
30
+ }
31
+
32
+ .download_links {
33
+ float: left;
34
+ }
@@ -0,0 +1,6 @@
1
+ // ----------------------------------- Helper class to apply to elements to make them sections
2
+ .section, .panel{ @include section; }
3
+
4
+ // ----------------------------------- Sidebar Sections
5
+
6
+ .sidebar_section { @include section; }
@@ -0,0 +1,10 @@
1
+ .scopes {
2
+ li {
3
+ .count {
4
+ color: #8e979e;
5
+ font-weight: normal;
6
+ font-size: 0.9em;
7
+ line-height: 10px;
8
+ }
9
+ }
10
+ }
@@ -0,0 +1,12 @@
1
+ .status {
2
+ background: darken($secondary-color, 15%);
3
+ color: #fff;
4
+ text-transform: uppercase;
5
+ letter-spacing: 0.15em;
6
+ padding: 3px 5px 2px 5px;
7
+ font-size: 0.8em;
8
+
9
+ &.ok, &.published, &.complete, &.completed, &.green { background: #8daa92; }
10
+ &.warn, &.warning, &.orange { background: #e29b20; }
11
+ &.error, &.errored, &.red { background: #d45f53; }
12
+ }
@@ -0,0 +1,101 @@
1
+ .table_tools {
2
+ display: block;
3
+ margin-bottom: 14px;
4
+ width: 100%;
5
+ }
6
+
7
+ .table_tools {
8
+ .table_tools_button + .table_tools_button {
9
+ margin-left: 6px;
10
+ }
11
+
12
+ .table_tools_button + .table_tools_segmented_control {
13
+ margin-left: 6px;
14
+ }
15
+
16
+ .table_tools_segmented_control + .table_tools_button {
17
+ margin-left: 6px;
18
+ }
19
+ }
20
+
21
+ a.table_tools_button {
22
+ @include light-button;
23
+ font-size: 0.9em;
24
+ color: #777;
25
+ text-decoration: none;
26
+ padding: 4px 14px 4px;
27
+ position: relative;
28
+
29
+ &.selected {
30
+ @include box-shadow(0 1px 0px rgba(0,0,0,0.10), 0 0 0 1px #FFF inset, 0 0 10px rgba(120,175,220,0.36));
31
+
32
+ &:active {
33
+ @include box-shadow(0 1px 0px rgba(0,0,0,0.10), 0 0 0 1px #FFF inset, 0 0 10px rgba(120,175,220,0.36), 0, 1px, 2px, rgba(0,0,0,0.30));
34
+ }
35
+ }
36
+
37
+ &.dropdown_button {
38
+ padding-right: 20px;
39
+
40
+ .arrow {
41
+ border-color: #777 transparent transparent;
42
+ border-style: solid;
43
+ border-width: 3px 3px 0;
44
+ height: 0;
45
+ position: absolute;
46
+ top: 8px;
47
+ right: 9px;
48
+ width: 0;
49
+ }
50
+ }
51
+
52
+ }
53
+
54
+ .table_tools_segmented_control {
55
+ display: inline-block;
56
+ list-style-type: none;
57
+ margin: 0;
58
+ padding: 0;
59
+
60
+ li {
61
+ display: inline-block;
62
+ list-style-image: none;
63
+ list-style-type: none;
64
+ margin-left: -7px;
65
+ white-space: nowrap;
66
+
67
+ a {
68
+ border-radius: 0px;
69
+ }
70
+
71
+ &:first-child {
72
+ margin-left: 0;
73
+
74
+ a {
75
+ border-top-left-radius: 12px;
76
+ border-bottom-left-radius: 12px;
77
+ }
78
+ }
79
+
80
+ &:last-child {
81
+ a {
82
+ border-top-right-radius: 12px;
83
+ border-bottom-right-radius: 12px;
84
+ }
85
+ }
86
+
87
+ &.selected {
88
+ a {
89
+ background: #F0F0F0;
90
+ @include box-shadow(0 1px 1px 0 rgba(0,0,0,0.1) inset);
91
+ color: #8a8a8a;
92
+ cursor: default;
93
+
94
+ &:hover {
95
+ color: #8a8a8a;
96
+ }
97
+ }
98
+ }
99
+ }
100
+
101
+ }
@@ -7,4 +7,5 @@
7
7
  @import "active_admin/mixins/buttons";
8
8
  @import "active_admin/mixins/sections";
9
9
  @import "active_admin/mixins/utilities";
10
-
10
+ @import "active_admin/mixins/typography";
11
+ @import "bourbon";
@@ -1,27 +1,64 @@
1
1
  @mixin default-button {
2
- @include shadow;
3
2
  @include gradient(lighten($primary-color, 15%), darken($primary-color, 12%));
4
3
  @include rounded(200px);
5
4
  @include text-shadow(#000);
6
- text-decoration: none;
7
- margin-right: 3px;
5
+ @include box-shadow(0 1px 0px rgba(0,0,0,0.10), 0 0 0 1px rgba(255,255,255, 0.2) inset);
6
+ border: solid 1px #484e53;
7
+ @include border-colors(#616a71, #484e53, #363b3f);
8
+ color: #efefef;
9
+ display: inline-block;
8
10
  font-weight: bold;
9
11
  font-size: 1.0em;
10
- cursor: pointer;
11
- padding: .6em 1.4em .5em 1.3em;
12
- border: none;
13
- color: #efefef;
14
- &:hover { color: #fff; @include icon-color(#fff); @include shadow(0, 1px, 3px, #888) }
15
- &:active { @include inset-shadow(0, 1px, 2px, #000); }
12
+ @include sans-family;
13
+ line-height: 12px;
14
+ margin-right: 3px;
15
+ padding: 7px 16px 6px;
16
+ text-decoration: none;
17
+ -webkit-font-smoothing: antialiased;
18
+
19
+ &:hover {
20
+ color: #FFF;
21
+ @include icon-color(#fff);
22
+ @include gradient(lighten($primary-color, 18%), darken($primary-color, 9%));
23
+ }
24
+
25
+ &:active {
26
+ @include box-shadow(0 1px 3px rgba(0,0,0,0.40) inset, 0 1px 0 0px #FFF);
27
+ @include gradient(lighten($primary-color, 13%), darken($primary-color, 14%));
28
+ }
16
29
  }
17
30
 
18
31
  @mixin light-button {
19
32
  @include default-button;
20
- @include gradient(#f9f9f9, #dddbdb);
33
+ @include gradient(#fdfdfd, #e8e8e8);
34
+ @include box-shadow(0 1px 0px rgba(0,0,0,0.10), 0 0 0 1px rgba(255,255,255, 0.8) inset);
35
+ @include border-colors(#d3d3d3, #c7c7c7, #c2c2c2);
21
36
  @include text-shadow;
22
37
  color: #777;
23
- &:hover { color: #444; @include icon-color(#444) }
24
- &:active { @include inset-shadow; }
38
+ &:hover {
39
+ @include icon-color(#444);
40
+ color: #444;
41
+ @include gradient(#fdfdfd, #eaeaea);
42
+ }
43
+ &:active {
44
+ @include box-shadow(0 1px 3px rgba(0,0,0,0.18) inset, 0 1px 0 0px #EEE);
45
+ @include gradient(#fcfcfc, #e5e4e5);
46
+ }
47
+
48
+ &.disabled {
49
+ color: #777;
50
+ cursor: default;
51
+ opacity: 0.6;
52
+
53
+ &:hover {
54
+ color: #777;
55
+ }
56
+ &:active {
57
+ @include box-shadow(0 1px 0px rgba(0,0,0,0.10), 0 0 0 1px #FFF inset);
58
+ }
59
+ }
25
60
  }
26
61
 
27
- @mixin dark-button { @include default-button; }
62
+ @mixin dark-button {
63
+ @include default-button;
64
+ }