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
@@ -10,6 +10,14 @@
10
10
  // Kill the scroll on the body
11
11
  .modal-open {
12
12
  overflow: hidden;
13
+
14
+
15
+ // Account for hiding of scrollbar
16
+ body&,
17
+ .navbar-fixed-top,
18
+ .navbar-fixed-bottom {
19
+ margin-right: 15px
20
+ }
13
21
  }
14
22
 
15
23
  // Container that the modal scrolls within
@@ -23,22 +31,19 @@
23
31
  bottom: 0;
24
32
  left: 0;
25
33
  z-index: @zindex-modal-background;
26
- -webkit-overflow-scrolling: touch;
27
34
 
28
35
  // When fading in the modal, animate it to slide down
29
- &.fade {
30
- top: -25%;
31
- .transition(~"opacity 0.3s linear, top 0.3s ease-out");
36
+ &.fade .modal-dialog {
37
+ .translate(0, -25%);
38
+ .transition-transform(~"0.3s ease-out");
32
39
  }
33
- &.fade.in { top: 0; }
40
+ &.in .modal-dialog { .translate(0, 0)}
34
41
  }
35
42
 
36
43
  // Shell div to position the modal with bottom padding
37
44
  .modal-dialog {
38
- position: relative;
39
- top: 0;
40
- left: 0;
41
- right: 0;
45
+ margin-left: auto;
46
+ margin-right: auto;
42
47
  width: auto;
43
48
  padding: 10px;
44
49
  z-index: (@zindex-modal-background + 10);
@@ -47,12 +52,12 @@
47
52
  // Actual modal
48
53
  .modal-content {
49
54
  position: relative;
50
- background-color: #fff;
51
- border: 1px solid #999;
52
- border: 1px solid rgba(0,0,0,.2);
53
- border-radius: 6px;
55
+ background-color: @modal-content-bg;
56
+ border: 1px solid @modal-content-fallback-border-color; //old browsers fallback (ie8 etc)
57
+ border: 1px solid @modal-content-border-color;
58
+ border-radius: @border-radius-large;
54
59
  .box-shadow(0 3px 9px rgba(0,0,0,.5));
55
- .background-clip(padding-box);
60
+ background-clip: padding-box;
56
61
  // Remove focus outline from opened modal
57
62
  outline: none;
58
63
  }
@@ -65,17 +70,17 @@
65
70
  bottom: 0;
66
71
  left: 0;
67
72
  z-index: (@zindex-modal-background - 10);
68
- background-color: #000;
73
+ background-color: @modal-backdrop-bg;
69
74
  // Fade for backdrop
70
75
  &.fade { .opacity(0); }
71
- &.fade.in { .opacity(.5); }
76
+ &.in { .opacity(.5); }
72
77
  }
73
78
 
74
79
  // Modal header
75
80
  // Top section of the modal w/ title and dismiss
76
81
  .modal-header {
77
82
  padding: @modal-title-padding;
78
- border-bottom: 1px solid #e5e5e5;
83
+ border-bottom: 1px solid @modal-header-border-color;
79
84
  min-height: (@modal-title-padding + @modal-title-line-height);
80
85
  }
81
86
  // Close icon
@@ -101,7 +106,7 @@
101
106
  margin-top: 15px;
102
107
  padding: (@modal-inner-padding - 1) @modal-inner-padding @modal-inner-padding;
103
108
  text-align: right; // right align buttons
104
- border-top: 1px solid #e5e5e5;
109
+ border-top: 1px solid @modal-footer-border-color;
105
110
  .clearfix(); // clear it in case folks use .pull-* classes on buttons
106
111
 
107
112
  // Properly space out buttons
@@ -125,8 +130,7 @@
125
130
  .modal-dialog {
126
131
  left: 50%;
127
132
  right: auto;
128
- width: 560px;
129
- margin-left: -280px;
133
+ width: 600px;
130
134
  padding-top: 30px;
131
135
  padding-bottom: 30px;
132
136
  }