Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

Rough outlines

  • Loading branch information...
commit 4c14c8ae7414a2225e7af3aaef4b0d0549b5c8c6 0 parents
Jeff Rafter authored June 13, 2011

Showing 130 changed files with 4,131 additions and 0 deletions. Show diff stats Hide diff stats

  1. 5  .gitignore
  2. 4  Gemfile
  3. 21  README.rdoc
  4. 2  Rakefile
  5. 2  TODO.rdoc
  6. BIN  app/assets/images/simple_admin/active_admin/admin_notes_icon.png
  7. BIN  app/assets/images/simple_admin/active_admin/loading.gif
  8. BIN  app/assets/images/simple_admin/active_admin/nested_menu_arrow.gif
  9. BIN  app/assets/images/simple_admin/active_admin/nested_menu_arrow_dark.gif
  10. BIN  app/assets/images/simple_admin/active_admin/orderable.png
  11. 51  app/assets/javascripts/simple_admin/active_admin.js
  12. 382  app/assets/javascripts/simple_admin/active_admin_vendor.js
  13. 4  app/assets/stylesheets/simple_admin/active_admin.css
  14. 433  app/assets/stylesheets/simple_admin/active_admin.scss
  15. 40  app/assets/stylesheets/simple_admin/active_admin/_comments.scss
  16. 13  app/assets/stylesheets/simple_admin/active_admin/_flash_messages.scss
  17. 168  app/assets/stylesheets/simple_admin/active_admin/_forms.scss
  18. 108  app/assets/stylesheets/simple_admin/active_admin/_header.scss
  19. 100  app/assets/stylesheets/simple_admin/active_admin/_typography.scss
  20. 0  app/assets/stylesheets/simple_admin/active_admin/mixins/_all.scss
  21. 27  app/assets/stylesheets/simple_admin/active_admin/mixins/_buttons.scss
  22. 21  app/assets/stylesheets/simple_admin/active_admin/mixins/_gradients.scss
  23. 20  app/assets/stylesheets/simple_admin/active_admin/mixins/_icons.scss
  24. 165  app/assets/stylesheets/simple_admin/active_admin/mixins/_reset.scss
  25. 43  app/assets/stylesheets/simple_admin/active_admin/mixins/_rounded.scss
  26. 27  app/assets/stylesheets/simple_admin/active_admin/mixins/_sections.scss
  27. 21  app/assets/stylesheets/simple_admin/active_admin/mixins/_shadows.scss
  28. 12  app/assets/stylesheets/simple_admin/active_admin/mixins/_variables.scss
  29. 56  app/controllers/simple_admin/admin_controller.rb
  30. 313  app/helpers/simple_admin/application_helper.rb
  31. 41  app/views/layouts/simple_admin.html.erb
  32. 16  app/views/simple_admin/admin/_form.html.erb
  33. 6  app/views/simple_admin/admin/edit.html.erb
  34. 80  app/views/simple_admin/admin/index.html.erb
  35. 6  app/views/simple_admin/admin/new.html.erb
  36. 21  app/views/simple_admin/admin/show.html.erb
  37. 8  config/routes.rb
  38. 12  lib/rails/generators/simple_admin/simple_admin_generator.rb
  39. 6  lib/rails/generators/simple_admin/templates/initializer.rb
  40. 91  lib/simple_admin.rb
  41. 24  lib/simple_admin/breadcrumbs.rb
  42. 19  lib/simple_admin/controller.rb
  43. 8  lib/simple_admin/engine.rb
  44. 84  lib/simple_admin/interface.rb
  45. 3  lib/simple_admin/version.rb
  46. 2  rails/init.rb
  47. 21  simple_admin.gemspec
  48. 0  tasks/.gitkeep b/test/sample/lib/tasks/.gitkeep
  49. 5  test/sample/.gitignore
  50. 29  test/sample/Gemfile
  51. 261  test/sample/README
  52. 7  test/sample/Rakefile
  53. 2  test/sample/app/admin/outfit_admin.rb
  54. 2  test/sample/app/admin/thing_admin.rb
  55. BIN  test/sample/app/assets/images/rails.png
  56. 9  test/sample/app/assets/javascripts/application.js
  57. 3  test/sample/app/assets/javascripts/outfits.js.coffee
  58. 3  test/sample/app/assets/javascripts/things.js.coffee
  59. 7  test/sample/app/assets/stylesheets/application.css
  60. 5  test/sample/app/assets/stylesheets/outfits.css.scss
  61. 58  test/sample/app/assets/stylesheets/scaffold.css.scss
  62. 5  test/sample/app/assets/stylesheets/things.css.scss
  63. 16  test/sample/app/controllers/application_controller.rb
  64. 83  test/sample/app/controllers/outfits_controller.rb
  65. 83  test/sample/app/controllers/things_controller.rb
  66. 2  test/sample/app/helpers/application_helper.rb
  67. 2  test/sample/app/helpers/outfits_helper.rb
  68. 2  test/sample/app/helpers/things_helper.rb
  69. 0  test/sample/app/mailers/.gitkeep
  70. 0  test/sample/app/models/.gitkeep
  71. 3  test/sample/app/models/outfit.rb
  72. 3  test/sample/app/models/thing.rb
  73. 14  test/sample/app/views/layouts/application.html.erb
  74. 25  test/sample/app/views/outfits/_form.html.erb
  75. 6  test/sample/app/views/outfits/edit.html.erb
  76. 25  test/sample/app/views/outfits/index.html.erb
  77. 5  test/sample/app/views/outfits/new.html.erb
  78. 15  test/sample/app/views/outfits/show.html.erb
  79. 25  test/sample/app/views/things/_form.html.erb
  80. 6  test/sample/app/views/things/edit.html.erb
  81. 25  test/sample/app/views/things/index.html.erb
  82. 5  test/sample/app/views/things/new.html.erb
  83. 15  test/sample/app/views/things/show.html.erb
  84. 4  test/sample/config.ru
  85. 49  test/sample/config/application.rb
  86. 6  test/sample/config/boot.rb
  87. 25  test/sample/config/database.yml
  88. 5  test/sample/config/environment.rb
  89. 24  test/sample/config/environments/development.rb
  90. 52  test/sample/config/environments/production.rb
  91. 39  test/sample/config/environments/test.rb
  92. 7  test/sample/config/initializers/backtrace_silencers.rb
  93. 10  test/sample/config/initializers/inflections.rb
  94. 5  test/sample/config/initializers/mime_types.rb
  95. 7  test/sample/config/initializers/secret_token.rb
  96. 8  test/sample/config/initializers/session_store.rb
  97. 6  test/sample/config/initializers/simple_admin.rb
  98. 12  test/sample/config/initializers/wrap_parameters.rb
  99. 5  test/sample/config/locales/en.yml
  100. 68  test/sample/config/routes.rb
  101. 10  test/sample/db/migrate/20110608002201_create_things.rb
  102. 10  test/sample/db/migrate/20110610135847_create_outfits.rb
  103. 29  test/sample/db/schema.rb
  104. 12  test/sample/db/seeds.rb
  105. 2  test/sample/doc/README_FOR_APP
  106. 0  test/sample/log/.gitkeep
  107. 26  test/sample/public/404.html
  108. 26  test/sample/public/422.html
  109. 26  test/sample/public/500.html
  110. 0  test/sample/public/favicon.ico
  111. 241  test/sample/public/index.html
  112. 5  test/sample/public/robots.txt
  113. 6  test/sample/script/rails
  114. 0  test/sample/test/fixtures/.gitkeep
  115. 9  test/sample/test/fixtures/outfits.yml
  116. 9  test/sample/test/fixtures/things.yml
  117. 0  test/sample/test/functional/.gitkeep
  118. 49  test/sample/test/functional/outfits_controller_test.rb
  119. 49  test/sample/test/functional/things_controller_test.rb
  120. 0  test/sample/test/integration/.gitkeep
  121. 12  test/sample/test/performance/browsing_test.rb
  122. 13  test/sample/test/test_helper.rb
  123. 0  test/sample/test/unit/.gitkeep
  124. 4  test/sample/test/unit/helpers/outfits_helper_test.rb
  125. 4  test/sample/test/unit/helpers/things_helper_test.rb
  126. 7  test/sample/test/unit/outfit_test.rb
  127. 7  test/sample/test/unit/thing_test.rb
  128. 0  test/sample/vendor/assets/stylesheets/.gitkeep
  129. 0  test/sample/vendor/plugins/.gitkeep
  130. 1  test/sample/vendor/plugins/simple_admin
5  .gitignore
... ...
@@ -0,0 +1,5 @@
  1
+.DS_Store
  2
+*.gem
  3
+.bundle
  4
+Gemfile.lock
  5
+pkg/*
4  Gemfile
... ...
@@ -0,0 +1,4 @@
  1
+source "http://rubygems.org"
  2
+
  3
+# Gem's dependencies in simple_admin.gemspec
  4
+gemspec
21  README.rdoc
Source Rendered
... ...
@@ -0,0 +1,21 @@
  1
+== SimpleAdmin
  2
+
  3
+I need an admin module for Rails and it has to be simple. ActiveAdmin is
  4
+beautiful and has a great DSL, but complex under the covers.
  5
+
  6
+Goals:
  7
+
  8
+* Minimal meta-programming
  9
+* Beautiful interface (hey, just use the ActiveAdmin interfaces!)
  10
+* Themeable
  11
+* Nice DSL
  12
+* Rails-friendly
  13
+* Fewer dependencies
  14
+* Fewer options
  15
+
  16
+= What this means to you
  17
+
  18
+If you want to customize a bunch of stuff, you might want to keep looking.
  19
+
  20
+Ultimately, there is always a need for projects like ActiveAdmin. Sometimes
  21
+you can get away with something simpler, sometimes you can't.
2  Rakefile
... ...
@@ -0,0 +1,2 @@
  1
+require 'bundler'
  2
+Bundler::GemHelper.install_tasks
2  TODO.rdoc
Source Rendered
... ...
@@ -0,0 +1,2 @@
  1
+* Enable themes
  2
+* Add configuration for load_paths and remove app/admin as a hardcoded value (make it default)
BIN  app/assets/images/simple_admin/active_admin/admin_notes_icon.png
BIN  app/assets/images/simple_admin/active_admin/loading.gif
BIN  app/assets/images/simple_admin/active_admin/nested_menu_arrow.gif
BIN  app/assets/images/simple_admin/active_admin/nested_menu_arrow_dark.gif
BIN  app/assets/images/simple_admin/active_admin/orderable.png
51  app/assets/javascripts/simple_admin/active_admin.js
... ...
@@ -0,0 +1,51 @@
  1
+/* Active Admin JS */
  2
+
  3
+$(function(){
  4
+    $(".datepicker").datepicker({dateFormat: 'yy-mm-dd'});
  5
+
  6
+    $(".clear_filters_btn").click(function(){
  7
+      window.location.search = "";
  8
+      return false;
  9
+    });
  10
+
  11
+    // AJAX Comments
  12
+    $('form#admin_note_new').submit(function() {
  13
+
  14
+      if ($(this).find('#admin_note_body').val() != "") {
  15
+        $(this).fadeOut('slow', function() {
  16
+          $('.loading_indicator').fadeIn();
  17
+          $.ajax({
  18
+            url: $(this).attr('action'),
  19
+            type: 'POST',
  20
+            dataType: 'json',
  21
+            data: $(this).serialize(),
  22
+            success: function(data, textStatus, xhr) {
  23
+              $('.loading_indicator').fadeOut('slow', function(){
  24
+
  25
+                // Hide the empty message
  26
+                $('.admin_notes_list li.empty').fadeOut().remove();
  27
+
  28
+                // Add the note
  29
+                $('.admin_notes_list').append(data['note']);
  30
+
  31
+                // Update the number of notes
  32
+                $('.admin_notes h3 span.admin_notes_count').html("(" + data['number_of_notes'] + ")");
  33
+
  34
+                // Reset the form
  35
+                $('form#new_active_admin_admin_note').find('#active_admin_admin_note_body').val("");
  36
+
  37
+                // Show the form
  38
+                $('form#new_active_admin_admin_note').fadeIn('slow');
  39
+              })
  40
+            },
  41
+            error: function(xhr, textStatus, errorThrown) {
  42
+              //called when there is an error
  43
+            }
  44
+          });
  45
+        });
  46
+
  47
+      };
  48
+
  49
+      return false;
  50
+    });
  51
+});
382  app/assets/javascripts/simple_admin/active_admin_vendor.js
382 additions, 0 deletions not shown
4  app/assets/stylesheets/simple_admin/active_admin.css
... ...
@@ -0,0 +1,4 @@
  1
+/*
  2
+ *= require './active_admin.scss'
  3
+*/
  4
+
433  app/assets/stylesheets/simple_admin/active_admin.scss
... ...
@@ -0,0 +1,433 @@
  1
+/* Active Admin CSS */
  2
+
  3
+// Bring in all the shared goodness
  4
+@import "active_admin/mixins/variables";
  5
+@import "active_admin/mixins/reset";
  6
+@import "active_admin/mixins/gradients";
  7
+@import "active_admin/mixins/shadows";
  8
+@import "active_admin/mixins/icons";
  9
+@import "active_admin/mixins/rounded";
  10
+@import "active_admin/mixins/buttons";
  11
+@import "active_admin/mixins/sections";
  12
+
  13
+// Reset Away!
  14
+@include global-reset;
  15
+
  16
+// Partials
  17
+@import "active_admin/typography";
  18
+@import "active_admin/header";
  19
+@import "active_admin/forms";
  20
+@import "active_admin/comments";
  21
+@import "active_admin/flash_messages";
  22
+
  23
+body {
  24
+  font-family: Helvetica, Arial, sans-serif;
  25
+  line-height: 150%;
  26
+  font-size: 72%;
  27
+  background: #fff;
  28
+  margin: 0;
  29
+  padding: 0;
  30
+  color: $text-color;
  31
+}
  32
+
  33
+// ----------------------------------- Page Title Bar
  34
+#title_bar {
  35
+  @include section-header;
  36
+  position: relative;
  37
+  margin: 0;
  38
+  padding: 10px $horizontal-page-margin;
  39
+
  40
+  h2 {
  41
+    margin: 12px 0 5px 0;
  42
+    padding: 0;
  43
+    font-size: 2.6em;
  44
+    font-weight: bold;
  45
+  }
  46
+
  47
+  .action_items {
  48
+    position: absolute;
  49
+    right: $horizontal-page-margin;
  50
+    top: 28px;
  51
+
  52
+    a {
  53
+      @include light-button;
  54
+      @include icon(#777, 0.8em);
  55
+      @include gradient(#f9f9f9, #dddbdb);
  56
+      padding: .8em 1.5em .7em 1.5em;
  57
+      border: 1px solid #f8f8f8;
  58
+      span.icon { vertical-align: bottom; margin-right: 4px;}
  59
+      &:hover{ @include icon-color(#000); }
  60
+      &:active { border: inherit; }
  61
+    }
  62
+  }
  63
+}
  64
+
  65
+// ----------------------------------- Main Structure
  66
+#active_admin_content {
  67
+  margin: 0;
  68
+  padding: 25px $horizontal-page-margin;
  69
+
  70
+  #main_content_wrapper {
  71
+    float: left;
  72
+    width: 100%;
  73
+
  74
+    #main_content{
  75
+      margin-right: 300px;
  76
+    }
  77
+  }
  78
+
  79
+  &.without_sidebar #main_content_wrapper #main_content{ margin-right: 0; }
  80
+
  81
+  #sidebar {
  82
+    float: left;
  83
+    width: 270px;
  84
+    margin-left: -270px;
  85
+  }
  86
+}
  87
+
  88
+// ----------------------------------- Footer
  89
+#footer {
  90
+  padding: 30px 30px;
  91
+  font-size: 0.8em;
  92
+  clear: both;
  93
+
  94
+  p {
  95
+    padding-top: 10px
  96
+  }
  97
+}
  98
+
  99
+// ----------------------------------- Links
  100
+a, a:link, a:visited {
  101
+  color: $link-color;
  102
+  text-decoration: underline;
  103
+}
  104
+a:hover { text-decoration: none; }
  105
+
  106
+// ----------------------------------- Buttons
  107
+
  108
+td, p {
  109
+  @include icon(#B3BCC1, 0.8em);
  110
+  span.icon { margin: 0 3px; }
  111
+}
  112
+
  113
+a.member_link {
  114
+  margin-right: 7px;
  115
+  white-space: nowrap;
  116
+}
  117
+
  118
+a.button, input[type=submit] { @include dark-button; }
  119
+
  120
+// ----------------------------------- Breadcrumbs
  121
+.breadcrumb {
  122
+  text-transform: uppercase;
  123
+  font-size: 0.9em;
  124
+  font-weight: normal;
  125
+
  126
+  a, a:link {
  127
+    color: #8a949e ;
  128
+    text-decoration: none;
  129
+  }
  130
+
  131
+  a:hover { text-decoration: underline; }
  132
+
  133
+  .breadcrumb_sep {
  134
+    margin: 0 2px;
  135
+    color: #aab2ba;
  136
+  }
  137
+}
  138
+
  139
+// ----------------------------------- Sections & Panels
  140
+// Helper class to apply to elements to make them sections
  141
+.section, .panel{ @include section; }
  142
+
  143
+// ----------------------------------- Tables
  144
+table {
  145
+  width: 100%;
  146
+  margin-bottom: 10px;
  147
+  border: 0;
  148
+  border-spacing: 0;
  149
+
  150
+
  151
+  th {
  152
+    @include section-header;
  153
+    text-align: left;
  154
+    padding-left: $cell-horizontal-padding;
  155
+    padding-right: $cell-horizontal-padding;
  156
+
  157
+    a, a:link, a:visited {
  158
+      color: $section-header-text-color;
  159
+      text-decoration: none;
  160
+      display: block;
  161
+    }
  162
+
  163
+    &.sortable a {
  164
+      background: url('/assets/simple_admin/active_admin/orderable.png') no-repeat 0 4px; padding-left: 13px;
  165
+    }
  166
+
  167
+    &.sorted-asc a { background-position: 0 -27px; }
  168
+    &.sorted-desc a {  background-position: 0 -56px;}
  169
+
  170
+    &.sorted-asc, &.sorted-desc {
  171
+      @include gradient(darken($secondary-gradient-start, 5%), darken($secondary-gradient-stop, 5%));
  172
+      border-bottom: 1px solid $secondary-gradient-stop;
  173
+    }
  174
+  }
  175
+
  176
+  tr.even td { background: $table-stripe-color; }
  177
+
  178
+  td {
  179
+    padding: 10px $cell-horizontal-padding 8px $cell-horizontal-padding;
  180
+    border-bottom: 1px solid #e8e8e8;
  181
+    vertical-align: top;
  182
+  }
  183
+}
  184
+
  185
+// ----------------------------------- Tables inside Panels
  186
+
  187
+.panel_contents table {
  188
+  margin-top: 5px;
  189
+  th {
  190
+    padding-top: 10px;
  191
+    background: none;
  192
+    color: $primary-color;
  193
+    @include no-shadow;
  194
+    @include text-shadow;
  195
+    text-transform: uppercase;
  196
+    border-bottom: 1px solid #ccc;
  197
+  }
  198
+  tr.odd td { background: darken($table-stripe-color, 3%); }
  199
+  tr.even td { background: $table-stripe-color; }
  200
+}
  201
+
  202
+// ----------------------------------- Sidebar Sections
  203
+.sidebar_section { @include section; }
  204
+
  205
+// -------------------------------------- Pagination
  206
+.pagination_information {
  207
+  float: right;
  208
+  margin-bottom: 5px;
  209
+  font-size: 0.95em;
  210
+  color: #b3bcc1;
  211
+  b { color: #5c6469; }
  212
+}
  213
+
  214
+.pagination {
  215
+  display: inline;
  216
+  font-size: 0.9;
  217
+  margin-left: 10px;
  218
+
  219
+  a { @include light-button; }
  220
+  span.page.current { @include default-button; }
  221
+  a, span.page.current {
  222
+    @include rounded(0px);
  223
+    margin-right: 4px;
  224
+    padding: 2px 5px;
  225
+  }
  226
+  span.page.current { padding-left: 7px; }
  227
+}
  228
+
  229
+// -------------------------------------- Index Footer (Under Table)
  230
+#index_footer { padding-top: 5px; text-align: right; font-size: 0.85em; }
  231
+
  232
+
  233
+
  234
+.index_content { clear: both; }
  235
+
  236
+// -------------------------------------- Index as Grid
  237
+table.index_grid td { border: none; background: none; padding: 0 20px 20px 0; margin: 0;}
  238
+
  239
+
  240
+// -------------------------------------- Filter Forms
  241
+form {
  242
+  .buttons {
  243
+    margin-top: 15px;
  244
+    input[type=submit] { margin-right: 10px; }
  245
+  }
  246
+  .filter_form_field {
  247
+    margin-bottom: 10px;
  248
+    clear: both;
  249
+
  250
+
  251
+    label {
  252
+      display: block;
  253
+      text-transform: uppercase;
  254
+      color: $section-header-text-color;
  255
+      font-size: 0.9em;
  256
+      font-weight: bold;
  257
+    }
  258
+    .datepicker { width: 80px; }
  259
+    &.filter_numeric { input[type=text] { width: 80px; margin-left: 5px; } }
  260
+    &.filter_check_boxes {
  261
+      label { margin-bottom: 3px; }
  262
+      .check_boxes_wrapper label {
  263
+        font-weight: normal;
  264
+        margin-bottom: 3px;
  265
+        text-transform: none;
  266
+        font-size: 1.0em;
  267
+        input { vertical-align: baseline; }
  268
+      }
  269
+    }
  270
+  }
  271
+  a.clear_filters_btn { @include light-button; }
  272
+}
  273
+
  274
+
  275
+// -------------------------------------- Logged Out
  276
+body.logged_out {
  277
+  background: #e8e9ea;
  278
+
  279
+  #content_wrapper{
  280
+    width: 500px;
  281
+    margin: 70px auto;
  282
+    #active_admin_content {
  283
+      @include shadow;
  284
+      background: #fff;
  285
+      padding: 13px 30px;
  286
+    }
  287
+  }
  288
+
  289
+  h2 {
  290
+    @include section-header;
  291
+    @include primary-gradient;
  292
+    @include text-shadow(#000);
  293
+    color: #fff;
  294
+    margin: -13px -30px 20px -30px;
  295
+  }
  296
+
  297
+  .flash {
  298
+    @include no-shadow;
  299
+    @include text-shadow(#fff);
  300
+    padding: 0;
  301
+    color: #666;
  302
+    background: none;
  303
+  }
  304
+
  305
+  #login {
  306
+    /* Login Form */
  307
+    form {
  308
+      fieldset {
  309
+        @include no-shadow;
  310
+        background: none;
  311
+        padding: 0;
  312
+        li { padding: 10px 0; }
  313
+
  314
+        input[type=text], input[type=email], input[type=password] {
  315
+          width: 70%;
  316
+        }
  317
+        &.buttons { margin-left: 20%; }
  318
+        margin-bottom: 0;
  319
+      }
  320
+    }
  321
+
  322
+    a { float: right; margin-top: -32px; }
  323
+  }
  324
+
  325
+}
  326
+
  327
+// -------------------------------------- Date Picker
  328
+.ui-datepicker {
  329
+  @include primary-gradient;
  330
+  padding: 5px 5px 0 5px;
  331
+  color: #fff;
  332
+  display: none;
  333
+  a {
  334
+    color: #fff;
  335
+    text-decoration: none;
  336
+    &:hover {
  337
+      cursor: pointer;
  338
+    }
  339
+    &.ui-datepicker-prev { float: left; }
  340
+    &.ui-datepicker-next { float: right; }
  341
+  }
  342
+  .ui-datepicker-title { text-align: center; display: block;}
  343
+  table {
  344
+    td, th { padding: 1px 3px; }
  345
+    td { border: none; }
  346
+  }
  347
+}
  348
+
  349
+// -------------------------------------- Dashboard
  350
+table.dashboard {
  351
+  width: 100%;
  352
+  td { border-bottom: none; }
  353
+  .dashboard_section { @include section; }
  354
+}
  355
+
  356
+
  357
+// -------------------------------------- Resource Attributes Table
  358
+.attributes_table { overflow: hidden; }
  359
+
  360
+.attributes_table table {
  361
+  th, td {
  362
+    padding: 8px $cell-horizontal-padding 6px $cell-horizontal-padding;
  363
+    vertical-align: top;
  364
+    border-bottom: 1px solid #e8e8e8;
  365
+  }
  366
+  th {
  367
+    @include no-shadow;
  368
+    background: none;
  369
+    width: 150px;
  370
+    font-size: 0.9em;
  371
+    padding-left: 0;
  372
+    text-transform: uppercase;
  373
+    color: $primary-color;
  374
+    @include text-shadow;
  375
+  }
  376
+  td {
  377
+    .empty {
  378
+      color: #bbb;
  379
+      font-size: 0.8em;
  380
+      text-transform: uppercase;
  381
+      letter-spacing: 0.2em;
  382
+    }
  383
+  }
  384
+}
  385
+
  386
+.sidebar_section .attributes_table th { width: 50px; }
  387
+
  388
+
  389
+// -------------------------------------- Status Tags
  390
+.status {
  391
+  background: darken($secondary-color, 15%);
  392
+  color: #fff;
  393
+  text-transform: uppercase;
  394
+  letter-spacing: 0.15em;
  395
+  padding: 3px 5px 2px 5px;
  396
+  font-size: 0.8em;
  397
+
  398
+  &.published, &.complete, &.completed, &.green { background: #8daa92; }
  399
+  &.error, &.errored, &.red { background: #d45f53;}
  400
+}
  401
+
  402
+
  403
+// -------------------------------------- Scopes
  404
+.scopes {
  405
+  float: left;
  406
+  margin-bottom: 10px;
  407
+  font-size: 1.0em;
  408
+
  409
+  .scope {
  410
+    padding: 4px 8px 3px 8px;
  411
+    margin-right: 4px;
  412
+    a { text-decoration: none; font-weight: bold; color: #888; }
  413
+    a:hover { text-decoration: underline; ; }
  414
+    &.selected {
  415
+      @include rounded(5px);
  416
+      @include inset-shadow(0,1px,0,#ccc);
  417
+      @include text-shadow;
  418
+      background: #efefef;
  419
+      color: #666;
  420
+      em { font-weight: bold; font-style: normal;
  421
+      }
  422
+    }
  423
+    .count{ color: #aaa; font-size: 0.9em; }
  424
+  }
  425
+  .scopes_seperator { display: none; }
  426
+}
  427
+
  428
+// -------------------------------------- Columns
  429
+.columns {
  430
+  clear: both;
  431
+  padding: 0;
  432
+  .column { float: left; }
  433
+}
40  app/assets/stylesheets/simple_admin/active_admin/_comments.scss
... ...
@@ -0,0 +1,40 @@
  1
+// -------------------------------------- Admin Notes 
  2
+.comments {
  3
+
  4
+  .active_admin_comment {
  5
+    clear: both;
  6
+    margin-top: 10px;
  7
+    margin-bottom: 40px;
  8
+    max-width: 700px;
  9
+
  10
+    .active_admin_comment_meta {
  11
+      width: 130px;
  12
+      float: left;
  13
+      font-size: 0.9em;
  14
+      color: lighten($primary-color, 10%);
  15
+      .active_admin_comment_author {
  16
+        font-size: 1.2em;
  17
+        font-weight: bold;
  18
+        margin: 0;
  19
+        color: $primary-color;
  20
+      }
  21
+    }
  22
+    .active_admin_comment_body {
  23
+      margin-left: 150px;
  24
+    }
  25
+  }
  26
+  form.active_admin_comment {
  27
+    margin: 0;
  28
+    padding: 0;
  29
+    margin-left: 150px;
  30
+
  31
+    fieldset.inputs {
  32
+      margin: 0;
  33
+      padding: 0;
  34
+      background: none;
  35
+      @include no-shadow;
  36
+    }
  37
+    li { padding: 0; }
  38
+    fieldset.buttons { padding: 0; margin-top: 5px;}
  39
+  }
  40
+}
13  app/assets/stylesheets/simple_admin/active_admin/_flash_messages.scss
... ...
@@ -0,0 +1,13 @@
  1
+.flash {
  2
+  @include primary-gradient;
  3
+  @include shadow;
  4
+  @include text-shadow(#222);
  5
+  border: none;
  6
+  font-weight: bold;
  7
+  padding: 10px 10px 8px 10px;
  8
+  margin-bottom: 10px;
  9
+  color: #fff;
  10
+
  11
+  &.flash_notice { @include gradient(#87a28b, #657b6a); }
  12
+  &.flash_error { @include gradient(#ca5b4f, #97443c); }
  13
+}
168  app/assets/stylesheets/simple_admin/active_admin/_forms.scss
... ...
@@ -0,0 +1,168 @@
  1
+// -------------------------------------- Active Admin Forms
  2
+form {
  3
+  /* Reset margins & Padding */
  4
+  ul, ol, li, fieldset, legend, input, textarea, select, p { margin:0; padding:0; }
  5
+  ol, ul { list-style: none }
  6
+
  7
+  fieldset { 
  8
+    border: 0; 
  9
+    padding: 10px 0;
  10
+    margin-bottom: 20px;
  11
+
  12
+    &.inputs { @include section-background; }
  13
+
  14
+    legend {
  15
+      width: 100%;
  16
+      span { display: block; @include section-header; }
  17
+    }
  18
+
  19
+    ol > li {
  20
+      padding: 10px;
  21
+      label {
  22
+        display: block;
  23
+        width: 20%;
  24
+        float: left;
  25
+        font-size: 1.0em;
  26
+        font-weight: bold;
  27
+        color: $section-header-text-color;
  28
+        abbr { border: none; color: #aaa; }
  29
+      }
  30
+    }
  31
+
  32
+
  33
+    ol > li > li label { 
  34
+      line-height:100%; 
  35
+      padding-top:0; 
  36
+      input { 
  37
+        line-height:100%; 
  38
+        vertical-align:middle; 
  39
+        margin-top:-0.1em;
  40
+      }
  41
+    }
  42
+  }
  43
+
  44
+  /* Nested Fieldsets and Legends */
  45
+  fieldset > ol > li {
  46
+    fieldset { 
  47
+      position:relative; 
  48
+      padding: 0;
  49
+      margin-bottom: 0;
  50
+
  51
+      legend { 
  52
+        position:absolute; 
  53
+        width:95%; 
  54
+        padding-top:0.1em; 
  55
+        left: 0px; 
  56
+        font-size: 100%; 
  57
+        font-weight: normal;
  58
+        span { position:absolute; }
  59
+        &.label label { position:absolute; }
  60
+      }
  61
+
  62
+      ol { 
  63
+        float:left; 
  64
+        width:74%; 
  65
+        margin:0; 
  66
+        padding:0 0 0 20%; 
  67
+
  68
+        li {
  69
+          padding:0; 
  70
+          border:0; 
  71
+        }
  72
+      }
  73
+    }
  74
+  }
  75
+
  76
+  /* Text Fields */
  77
+  input[type=text], input[type=password], input[type=email], input[type=url], input[type=tel], textarea {
  78
+    width: 76%;
  79
+    border: 1px solid #c9d0d6;
  80
+    font-size: 0.95em;
  81
+    outline: none;
  82
+    padding: 8px 10px;
  83
+    
  84
+    &:focus {
  85
+      border: 1px solid #99a2aa;
  86
+      @include shadow(0,0,4px,#99a2aa);
  87
+    }
  88
+  }
  89
+
  90
+  fieldset > ol > li {
  91
+
  92
+    /* Hints */
  93
+    p.inline-hints { 
  94
+      font-size: 0.95em;
  95
+      font-style: italic;
  96
+      color:#666; 
  97
+      margin: 0.5em 0 0 20%;  
  98
+    }
  99
+
  100
+    /* Date and Time Fields */
  101
+    &.date, &.time, &.datetime {
  102
+      fieldset ol li {
  103
+        float:left; width:auto; margin:0 0.5em 0 0; 
  104
+        label { display: none; }
  105
+        input { display:inline; margin:0; padding:0;  }
  106
+      }
  107
+    }
  108
+
  109
+    /* Check Boxes or Radio fields */
  110
+    &.check_boxes, &.radio {
  111
+      fieldset ol { 
  112
+        margin-bottom:-0.6em;
  113
+        li { 
  114
+          margin:0.1em 0 0.5em 0; 
  115
+          label { 
  116
+            float:none; 
  117
+            width:100%; 
  118
+            input { margin-right:0.2em; }
  119
+          }
  120
+        }
  121
+      }
  122
+    }
  123
+
  124
+    /* Boolean Field */
  125
+    &.boolean {
  126
+      height: 1.1em;
  127
+      label { 
  128
+        width: 100%;
  129
+        padding-left:20%; 
  130
+        padding-right: 10px; 
  131
+        text-transform: none !important;
  132
+        font-weight: normal;
  133
+        input { margin:0 0.5em 0 0.2em; }
  134
+      }
  135
+    }
  136
+
  137
+    &.hidden { display: none; }
  138
+
  139
+    /* Errors */
  140
+    p.inline-errors { 
  141
+      text-transform:capitalize;
  142
+      color:#cc0000; 
  143
+      margin:0.5em 0 0 20%; 
  144
+    }
  145
+    ul.errors { 
  146
+      color:#cc0000; 
  147
+      margin:0.5em 0 0 20%; 
  148
+      list-style:square; 
  149
+      li { padding:0; border:none; display:list-item; }
  150
+    }
  151
+
  152
+    &.error {
  153
+      input[type=text], input[type=password], input[type=email], input[type=url], input[type=tel], textarea {
  154
+        border: 1px solid #cc0000;
  155
+      }
  156
+    }
  157
+  }
  158
+
  159
+  /* Buttons */
  160
+  input[type=submit] { @include dark-button; }
  161
+  fieldset.buttons li { 
  162
+    float:left; 
  163
+    padding-right:0.5em;
  164
+    padding-top: 0;
  165
+    &.cancel { margin-left: 0.3em; padding: 5px; a { @include light-button; @include icon(#777, 9px);} }
  166
+  }
  167
+
  168
+}
108  app/assets/stylesheets/simple_admin/active_admin/_header.scss
... ...
@@ -0,0 +1,108 @@
  1
+// ----------------------------------- Header
  2
+#header {
  3
+  @include primary-gradient;
  4
+  @include shadow;
  5
+  @include text-shadow(#000);
  6
+  padding: 9px $horizontal-page-margin;
  7
+  position: relative;
  8
+  z-index: 900;
  9
+
  10
+  h1 {
  11
+    display: inline;
  12
+    color: #cdcdcd;
  13
+    margin-right: 20px;
  14
+    font-size: 1.3em;
  15
+    font-weight: normal;
  16
+  }
  17
+
  18
+  a, a:link { color: #cdcdcd; }
  19
+
  20
+  ul#tabs {
  21
+    margin: 0;
  22
+    padding: 0;
  23
+    display: inline;
  24
+    height: 100%;
  25
+
  26
+    & > li {
  27
+      display: inline-block;
  28
+      margin-right: 4px;
  29
+      font-size: 1.0em;
  30
+      position: relative;
  31
+
  32
+      a {
  33
+        text-decoration: none;
  34
+        padding: 6px 10px 4px 10px;
  35
+        position: relative;
  36
+        @include rounded(10px);
  37
+      }
  38
+
  39
+      &.current > a {
  40
+        background: $current-menu-item-background;
  41
+        color: #fff;
  42
+      }
  43
+
  44
+      &.has_nested > a {
  45
+        background: url('/assets/simple_admin/active_admin/nested_menu_arrow.gif') no-repeat 89% 50%;
  46
+        padding-right: 20px;
  47
+      }
  48
+
  49
+      &.has_nested.current > a {
  50
+        background: $current-menu-item-background url('/assets/simple_admin/active_admin/nested_menu_arrow_dark.gif') no-repeat 89% 50%;
  51
+        padding-right: 20px;
  52
+      }
  53
+
  54
+      &:hover > a {
  55
+        background: $hover-menu-item-background;
  56
+        color: #fff;
  57
+      }
  58
+
  59
+      &.has_nested:hover > a {
  60
+        @include rounded-top(10px);
  61
+        z-index: 800;
  62
+        border-bottom: 5px solid $hover-menu-item-background;
  63
+        background: $hover-menu-item-background url('/assets/simple_admin/active_admin/nested_menu_arrow_dark.gif') no-repeat 89% 50%;
  64
+      }
  65
+
  66
+
  67
+      /* Hover on li, display the ul */
  68
+      &:hover ul { display: block;}
  69
+      /* Drop down menus */
  70
+      ul {
  71
+        background: $hover-menu-item-background;
  72
+        @include rounded-all(0,10px,10px,10px);
  73
+        @include shadow(0, 1px, 3px, #444);
  74
+        position: absolute;
  75
+        width: 175px;
  76
+        margin-top: 4px;
  77
+        float: left;
  78
+        display: none;
  79
+        padding: 3px 0px 5px 0;
  80
+        list-style: none;
  81
+
  82
+        li {
  83
+          margin: 0px;
  84
+          a {
  85
+            background: none;
  86
+            display: block;
  87
+            &:hover { color: #fff; background: none; }
  88
+          }
  89
+
  90
+          &.current {
  91
+            a { @include rounded(0) }
  92
+          }
  93
+        }
  94
+      }
  95
+    }
  96
+
  97
+  }
  98
+
  99
+  #utility_nav {
  100
+    position: absolute; right: 25px; top: 10px;
  101
+    color: #aaa;
  102
+    span, a { margin-left: 10px; }
  103
+
  104
+    a { text-decoration: none; }
  105
+    a:hover { color: #fff; }
  106
+  }
  107
+
  108
+}
100  app/assets/stylesheets/simple_admin/active_admin/_typography.scss
... ...
@@ -0,0 +1,100 @@
  1
+// Adapted from Blueprint CSS Framework
  2
+//
  3
+// Copyright (c) 2007 - 2010 blueprintcss.org
  4
+// 
  5
+// Permission is hereby granted, free of charge, to any person
  6
+// obtaining a copy of this software and associated documentation
  7
+// files (the "Software"), to deal in the Software without
  8
+// restriction, including without limitation the rights to use,
  9
+// copy, modify, merge, publish, distribute, sublicense, and/or sell
  10
+// copies of the Software, and to permit persons to whom the
  11
+// Software is furnished to do so, subject to the following
  12
+// conditions:
  13
+// 
  14
+// The above copyright notice and this permission notice shall be
  15
+// included in all copies or substantial portions of the Software.
  16
+// 
  17
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
  18
+// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
  19
+// OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
  20
+// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
  21
+// HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
  22
+// WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
  23
+// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
  24
+// OTHER DEALINGS IN THE SOFTWARE.
  25
+
  26
+// Default font settings.  The font-size percentage is of 16px. (0.75 * 16px = 12px) */
  27
+html { font-size:100.01%; }
  28
+body { font-size: 75%; font-family: "Helvetica Neue", Arial, Helvetica, sans-serif; }
  29
+
  30
+// Headings
  31
+h1,h2,h3,h4,h5,h6 { 
  32
+  font-weight: normal; 
  33
+  color: $primary-color; 
  34
+  img { margin: 0; }
  35
+}
  36
+
  37
+h1 { font-size: 3em; line-height: 1; margin-bottom: 0.5em; }
  38
+h2 { font-size: 2em; margin-bottom: 0.75em; }
  39
+h3 { font-size: 1.5em; line-height: 1; margin-bottom: 1em; }
  40
+h4 { font-size: 1.2em; line-height: 1.25; margin-bottom: 1.25em; }
  41
+h5 { font-size: 1em; font-weight: bold; margin-bottom: 1.5em; }
  42
+h6 { font-size: 1em; font-weight: bold; }
  43
+
  44
+
  45
+p { 
  46
+  margin: 0 0 1.5em; 
  47
+
  48
+  .left     { margin: 1.5em 1.5em 1.5em 0; padding: 0; }
  49
+  .right { margin: 1.5em 0 1.5em 1.5em; padding: 0; }
  50
+}
  51
+
  52
+.left              { float: left !important; }
  53
+.right             { float: right !important; }
  54
+
  55
+blockquote  { margin: 1.5em; color: #666; font-style: italic; }
  56
+strong,dfn    { font-weight: bold; }
  57
+em,dfn      { font-style: italic; }
  58
+sup, sub    { line-height: 0; }
  59
+
  60
+abbr,
  61
+acronym     { border-bottom: 1px dotted #666; }
  62
+address     { margin: 0 0 1.5em; font-style: italic; }
  63
+del         { color:#666; }
  64
+
  65
+pre         { margin: 1.5em 0; white-space: pre; }
  66
+pre,code,tt { font: 1em 'andale mono', 'lucida console', monospace; line-height: 1.5; }
  67
+
  68
+// Lists
  69
+li ul,
  70
+li ol       { margin: 0; }
  71
+ul, ol      { margin: 0 1.5em 1.5em 0; padding-left: 1.5em; }
  72
+
  73
+ul          { list-style-type: disc; }
  74
+ol          { list-style-type: decimal; }
  75
+
  76
+dl          { margin: 0 0 1.5em 0; }
  77
+dl dt       { font-weight: bold; }
  78
+dd          { margin-left: 1.5em;}
  79
+
  80
+// Tables
  81
+table       { margin-bottom: 1.4em; width:100%; }
  82
+th          { font-weight: bold; }
  83
+thead th    { background: #c3d9ff; }
  84
+th,td,caption { padding: 4px 10px 4px 5px; }
  85
+
  86
+// Helper Classes
  87
+.small      { font-size: .8em; margin-bottom: 1.875em; line-height: 1.875em; }
  88
+.large      { font-size: 1.2em; line-height: 2.5em; margin-bottom: 1.25em; }
  89
+.hide       { display: none; }
  90
+
  91
+.quiet      { color: #666; }
  92
+.loud       { color: #000; }
  93
+.highlight  { background:#ff0; }
  94
+.added      { background:#060; color: #fff; }
  95
+.removed    { background:#900; color: #fff; }
  96
+
  97
+.first      { margin-left:0; padding-left:0; }
  98
+.last       { margin-right:0; padding-right:0; }
  99
+.top        { margin-top:0; padding-top:0; }
  100
+.bottom     { margin-bottom:0; padding-bottom:0; }
0  app/assets/stylesheets/simple_admin/active_admin/mixins/_all.scss
No changes.
27  app/assets/stylesheets/simple_admin/active_admin/mixins/_buttons.scss
... ...
@@ -0,0 +1,27 @@
  1
+@mixin default-button {
  2
+  @include shadow;
  3
+  @include gradient(lighten($primary-color, 15%), darken($primary-color, 12%));
  4
+  @include rounded(200px);
  5
+  @include text-shadow(#000);
  6
+  text-decoration: none;
  7
+  margin-right: 3px;
  8
+  font-weight: bold;
  9
+  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); }
  16
+}
  17
+
  18
+@mixin light-button {
  19
+  @include default-button;
  20
+  @include gradient(#f9f9f9, #dddbdb);
  21
+  @include text-shadow;
  22
+  color: #777;
  23
+  &:hover { color: #444; @include icon-color(#444) }