padrino-admin 0.11.3 → 0.11.4

Sign up to get free protection for your applications and to get access to all the features.
Files changed (89) hide show
  1. checksums.yaml +7 -0
  2. data/README.rdoc +3 -3
  3. data/lib/padrino-admin/access_control.rb +46 -47
  4. data/lib/padrino-admin/bootstrap-less/alerts.less +29 -55
  5. data/lib/padrino-admin/bootstrap-less/badges.less +13 -15
  6. data/lib/padrino-admin/bootstrap-less/bootstrap.less +17 -21
  7. data/lib/padrino-admin/bootstrap-less/breadcrumbs.less +6 -11
  8. data/lib/padrino-admin/bootstrap-less/button-groups.less +114 -32
  9. data/lib/padrino-admin/bootstrap-less/buttons.less +41 -41
  10. data/lib/padrino-admin/bootstrap-less/carousel.less +43 -18
  11. data/lib/padrino-admin/bootstrap-less/close.less +4 -4
  12. data/lib/padrino-admin/bootstrap-less/code.less +8 -10
  13. data/lib/padrino-admin/bootstrap-less/component-animations.less +10 -4
  14. data/lib/padrino-admin/bootstrap-less/dropdowns.less +78 -51
  15. data/lib/padrino-admin/bootstrap-less/forms.less +183 -274
  16. data/lib/padrino-admin/bootstrap-less/glyphicons.less +232 -0
  17. data/lib/padrino-admin/bootstrap-less/grid.less +230 -88
  18. data/lib/padrino-admin/bootstrap-less/input-groups.less +127 -0
  19. data/lib/padrino-admin/bootstrap-less/jumbotron.less +16 -8
  20. data/lib/padrino-admin/bootstrap-less/labels.less +25 -37
  21. data/lib/padrino-admin/bootstrap-less/list-group.less +34 -35
  22. data/lib/padrino-admin/bootstrap-less/media.less +7 -5
  23. data/lib/padrino-admin/bootstrap-less/mixins.less +321 -108
  24. data/lib/padrino-admin/bootstrap-less/modals.less +24 -20
  25. data/lib/padrino-admin/bootstrap-less/navbar.less +474 -216
  26. data/lib/padrino-admin/bootstrap-less/navs.less +67 -85
  27. data/lib/padrino-admin/bootstrap-less/pager.less +4 -4
  28. data/lib/padrino-admin/bootstrap-less/pagination.less +64 -69
  29. data/lib/padrino-admin/bootstrap-less/panels.less +114 -62
  30. data/lib/padrino-admin/bootstrap-less/popovers.less +18 -18
  31. data/lib/padrino-admin/bootstrap-less/print.less +22 -7
  32. data/lib/padrino-admin/bootstrap-less/progress-bars.less +10 -33
  33. data/lib/padrino-admin/bootstrap-less/responsive-utilities.less +141 -40
  34. data/lib/padrino-admin/bootstrap-less/scaffolding.less +66 -19
  35. data/lib/padrino-admin/bootstrap-less/tables.less +154 -158
  36. data/lib/padrino-admin/bootstrap-less/theme.less +232 -0
  37. data/lib/padrino-admin/bootstrap-less/thumbnails.less +9 -20
  38. data/lib/padrino-admin/bootstrap-less/tooltip.less +3 -3
  39. data/lib/padrino-admin/bootstrap-less/type.less +47 -55
  40. data/lib/padrino-admin/bootstrap-less/utilities.less +2 -2
  41. data/lib/padrino-admin/bootstrap-less/variables.less +289 -93
  42. data/lib/padrino-admin/bootstrap-less/wells.less +2 -2
  43. data/lib/padrino-admin/generators/actions.rb +11 -10
  44. data/lib/padrino-admin/generators/admin_app.rb +11 -11
  45. data/lib/padrino-admin/generators/admin_page.rb +9 -9
  46. data/lib/padrino-admin/generators/orm.rb +6 -7
  47. data/lib/padrino-admin/generators/templates/account/activerecord.rb.tt +7 -7
  48. data/lib/padrino-admin/generators/templates/account/couchrest.rb.tt +16 -16
  49. data/lib/padrino-admin/generators/templates/account/datamapper.rb.tt +7 -7
  50. data/lib/padrino-admin/generators/templates/account/minirecord.rb.tt +7 -7
  51. data/lib/padrino-admin/generators/templates/account/mongoid.rb.tt +8 -8
  52. data/lib/padrino-admin/generators/templates/account/mongomapper.rb.tt +7 -7
  53. data/lib/padrino-admin/generators/templates/account/ohm.rb.tt +9 -9
  54. data/lib/padrino-admin/generators/templates/account/sequel.rb.tt +8 -8
  55. data/lib/padrino-admin/generators/templates/assets/javascripts/bootstrap/affix.js +9 -3
  56. data/lib/padrino-admin/generators/templates/assets/javascripts/bootstrap/alert.js +4 -2
  57. data/lib/padrino-admin/generators/templates/assets/javascripts/bootstrap/bootstrap.min.js +4 -4
  58. data/lib/padrino-admin/generators/templates/assets/javascripts/bootstrap/button.js +9 -5
  59. data/lib/padrino-admin/generators/templates/assets/javascripts/bootstrap/carousel.js +19 -12
  60. data/lib/padrino-admin/generators/templates/assets/javascripts/bootstrap/collapse.js +68 -45
  61. data/lib/padrino-admin/generators/templates/assets/javascripts/bootstrap/dropdown.js +6 -7
  62. data/lib/padrino-admin/generators/templates/assets/javascripts/bootstrap/modal.js +43 -40
  63. data/lib/padrino-admin/generators/templates/assets/javascripts/bootstrap/popover.js +16 -10
  64. data/lib/padrino-admin/generators/templates/assets/javascripts/bootstrap/scrollspy.js +6 -4
  65. data/lib/padrino-admin/generators/templates/assets/javascripts/bootstrap/tab.js +4 -2
  66. data/lib/padrino-admin/generators/templates/assets/javascripts/bootstrap/tooltip.js +78 -48
  67. data/lib/padrino-admin/generators/templates/assets/javascripts/bootstrap/transition.js +10 -1
  68. data/lib/padrino-admin/generators/templates/assets/stylesheets/application.css +1 -0
  69. data/lib/padrino-admin/generators/templates/assets/stylesheets/bootstrap.css +622 -334
  70. data/lib/padrino-admin/generators/templates/erb/app/layouts/error.erb.tt +2 -2
  71. data/lib/padrino-admin/generators/templates/erb/app/sessions/new.erb.tt +9 -9
  72. data/lib/padrino-admin/generators/templates/erb/page/_form.erb.tt +3 -3
  73. data/lib/padrino-admin/generators/templates/erb/page/index.erb.tt +3 -3
  74. data/lib/padrino-admin/generators/templates/haml/app/layouts/error.haml.tt +1 -1
  75. data/lib/padrino-admin/generators/templates/haml/app/sessions/new.haml.tt +9 -7
  76. data/lib/padrino-admin/generators/templates/haml/page/_form.haml.tt +2 -2
  77. data/lib/padrino-admin/generators/templates/haml/page/index.haml.tt +2 -2
  78. data/lib/padrino-admin/generators/templates/page/controller.rb.tt +3 -3
  79. data/lib/padrino-admin/generators/templates/slim/app/layouts/error.slim.tt +1 -1
  80. data/lib/padrino-admin/generators/templates/slim/app/sessions/new.slim.tt +9 -7
  81. data/lib/padrino-admin/generators/templates/slim/page/_form.slim.tt +2 -2
  82. data/lib/padrino-admin/generators/templates/slim/page/index.slim.tt +2 -2
  83. data/lib/padrino-admin/helpers/authentication_helpers.rb +35 -35
  84. data/lib/padrino-admin/helpers/view_helpers.rb +12 -19
  85. data/lib/padrino-admin/utils/crypt.rb +10 -9
  86. data/lib/padrino-admin.rb +4 -5
  87. data/test/fixtures/data_mapper.rb +10 -9
  88. data/test/generators/test_account_model_generator.rb +2 -2
  89. metadata +14 -21
@@ -11,9 +11,13 @@ p {
11
11
  }
12
12
  .lead {
13
13
  margin-bottom: @line-height-computed;
14
- font-size: (@font-size-base * 1.5);
14
+ font-size: (@font-size-base * 1.15);
15
15
  font-weight: 200;
16
16
  line-height: 1.4;
17
+
18
+ @media (min-width: 768px) {
19
+ font-size: (@font-size-base * 1.5);
20
+ }
17
21
  }
18
22
 
19
23
 
@@ -23,25 +27,18 @@ p {
23
27
  // Ex: 14px base font * 85% = about 12px
24
28
  small { font-size: 85%; }
25
29
 
30
+ // Undo browser default styling
26
31
  cite { font-style: normal; }
27
32
 
28
- // Utility classes
29
- .text-muted { color: @gray-light; }
30
- a.text-muted:hover,
31
- a.text-muted:focus { color: darken(@gray-light, 10%); }
32
-
33
+ // Contextual emphasis
34
+ .text-muted { color: @text-muted; }
35
+ .text-primary { color: @brand-primary; }
33
36
  .text-warning { color: @state-warning-text; }
34
- a.text-warning:hover,
35
- a.text-warning:focus { color: darken(@state-warning-text, 10%); }
36
-
37
37
  .text-danger { color: @state-danger-text; }
38
- a.text-danger:hover,
39
- a.text-danger:focus { color: darken(@state-danger-text, 10%); }
40
-
41
38
  .text-success { color: @state-success-text; }
42
- a.text-success:hover,
43
- a.text-success:focus { color: darken(@state-success-text, 10%); }
39
+ .text-info { color: @state-info-text; }
44
40
 
41
+ // Alignment
45
42
  .text-left { text-align: left; }
46
43
  .text-right { text-align: right; }
47
44
  .text-center { text-align: center; }
@@ -58,7 +55,7 @@ h1, h2, h3, h4, h5, h6,
58
55
  small {
59
56
  font-weight: normal;
60
57
  line-height: 1;
61
- color: @gray-light;
58
+ color: @headings-small-color;
62
59
  }
63
60
  }
64
61
 
@@ -75,8 +72,8 @@ h6 {
75
72
  margin-bottom: (@line-height-computed / 2);
76
73
  }
77
74
 
78
- h1, .h1 { font-size: ceil(@font-size-base * 2.70); } // ~38px
79
- h2, .h2 { font-size: ceil(@font-size-base * 2.25); } // ~32px
75
+ h1, .h1 { font-size: floor(@font-size-base * 2.60); } // ~36px
76
+ h2, .h2 { font-size: floor(@font-size-base * 2.15); } // ~30px
80
77
  h3, .h3 { font-size: ceil(@font-size-base * 1.70); } // ~24px
81
78
  h4, .h4 { font-size: ceil(@font-size-base * 1.25); } // ~18px
82
79
  h5, .h5 { font-size: @font-size-base; }
@@ -94,7 +91,7 @@ h4 small, .h4 small { font-size: @font-size-base; }
94
91
  .page-header {
95
92
  padding-bottom: ((@line-height-computed / 2) - 1);
96
93
  margin: (@line-height-computed * 2) 0 @line-height-computed;
97
- border-bottom: 1px solid @gray-lighter;
94
+ border-bottom: 1px solid @page-header-border-color;
98
95
  }
99
96
 
100
97
 
@@ -107,12 +104,10 @@ ul,
107
104
  ol {
108
105
  margin-top: 0;
109
106
  margin-bottom: (@line-height-computed / 2);
110
- }
111
- ul ul,
112
- ul ol,
113
- ol ol,
114
- ol ul {
115
- margin-bottom: 0;
107
+ ul,
108
+ ol{
109
+ margin-bottom: 0;
110
+ }
116
111
  }
117
112
 
118
113
  // List options
@@ -144,41 +139,39 @@ dt {
144
139
  font-weight: bold;
145
140
  }
146
141
  dd {
147
- margin-left: (@line-height-computed / 2);
148
- }
149
- // Horizontal layout (like forms)
150
- .dl-horizontal {
151
- dt {
152
- float: left;
153
- width: (@component-offset-horizontal - 20);
154
- clear: left;
155
- text-align: right;
156
- .text-overflow();
157
- }
158
- dd {
159
- .clearfix(); // Clear the floated `dt` if an empty `dd` is present
160
- margin-left: @component-offset-horizontal;
142
+ margin-left: 0; // Undo browser default
143
+ }
144
+
145
+ // Horizontal description lists
146
+ //
147
+ // Defaults to being stacked without any of the below styles applied, until the
148
+ // grid breakpoint is reached (default of ~768px).
149
+
150
+ @media (min-width: @grid-float-breakpoint) {
151
+ .dl-horizontal {
152
+ dt {
153
+ float: left;
154
+ width: (@component-offset-horizontal - 20);
155
+ clear: left;
156
+ text-align: right;
157
+ .text-overflow();
158
+ }
159
+ dd {
160
+ margin-left: @component-offset-horizontal;
161
+ .clearfix(); // Clear the floated `dt` if an empty `dd` is present
162
+ }
161
163
  }
162
164
  }
163
165
 
164
166
  // MISC
165
167
  // ----
166
168
 
167
- // Horizontal rules
168
- hr {
169
- margin: @line-height-computed 0;
170
- border: 0;
171
- border-top: 1px solid @hr-border;
172
- border-bottom: 1px solid #fff;
173
- border-bottom: 1px solid rgba(255,255,255,.5);
174
- }
175
-
176
169
  // Abbreviations and acronyms
177
170
  abbr[title],
178
- // Added data-* attribute to help out our tooltip plugin, per https://github.com/twitter/bootstrap/issues/5257
171
+ // Added data-* attribute to help out our tooltip plugin, per https://github.com/twbs/bootstrap/issues/5257
179
172
  abbr[data-original-title] {
180
173
  cursor: help;
181
- border-bottom: 1px dotted @gray-light;
174
+ border-bottom: 1px dotted @abbr-border-color;
182
175
  }
183
176
  abbr.initialism {
184
177
  font-size: 90%;
@@ -189,7 +182,7 @@ abbr.initialism {
189
182
  blockquote {
190
183
  padding: (@line-height-computed / 2) @line-height-computed;
191
184
  margin: 0 0 @line-height-computed;
192
- border-left: 5px solid @gray-lighter;
185
+ border-left: 5px solid @blockquote-border-color;
193
186
  p {
194
187
  font-size: (@font-size-base * 1.25);
195
188
  font-weight: 300;
@@ -201,18 +194,17 @@ blockquote {
201
194
  small {
202
195
  display: block;
203
196
  line-height: @line-height-base;
204
- color: @gray-light;
197
+ color: @blockquote-small-color;
205
198
  &:before {
206
- content: '\2014 \00A0';
199
+ content: '\2014 \00A0';// EM DASH, NBSP
207
200
  }
208
201
  }
209
202
 
210
203
  // Float right with text-align: right
211
204
  &.pull-right {
212
- float: right;
213
205
  padding-right: 15px;
214
206
  padding-left: 0;
215
- border-right: 5px solid @gray-lighter;
207
+ border-right: 5px solid @blockquote-border-color;
216
208
  border-left: 0;
217
209
  p,
218
210
  small {
@@ -223,7 +215,7 @@ blockquote {
223
215
  content: '';
224
216
  }
225
217
  &:after {
226
- content: '\00A0 \2014';
218
+ content: '\00A0 \2014';// NBSP, EM DASH
227
219
  }
228
220
  }
229
221
  }
@@ -10,10 +10,10 @@
10
10
  .clearfix();
11
11
  }
12
12
  .pull-right {
13
- float: right;
13
+ float: right !important;
14
14
  }
15
15
  .pull-left {
16
- float: left;
16
+ float: left !important;
17
17
  }
18
18
 
19
19