rails_modular_admin 0.2.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (118) hide show
  1. checksums.yaml +7 -0
  2. data/MIT-LICENSE +20 -0
  3. data/README.md +71 -0
  4. data/Rakefile +34 -0
  5. data/app/assets/config/rails_modular_admin_manifest.js +2 -0
  6. data/app/assets/javascripts/index.js +87 -0
  7. data/app/assets/javascripts/rails_modular_admin.js +3 -0
  8. data/app/assets/javascripts/rails_modular_admin/_common/_helpers/code-helper.js +36 -0
  9. data/app/assets/javascripts/rails_modular_admin/_common/_helpers/for-helper.js +8 -0
  10. data/app/assets/javascripts/rails_modular_admin/_common/_helpers/is-helper.js +98 -0
  11. data/app/assets/javascripts/rails_modular_admin/_common/_helpers/times-helper.js +11 -0
  12. data/app/assets/javascripts/rails_modular_admin/_common/animations/animations.js +14 -0
  13. data/app/assets/javascripts/rails_modular_admin/_common/items-list/items-list.js +19 -0
  14. data/app/assets/javascripts/rails_modular_admin/_common/nprogress/nprogress.js +9 -0
  15. data/app/assets/javascripts/rails_modular_admin/_common/sameheight-items/sameheight-items.js +44 -0
  16. data/app/assets/javascripts/rails_modular_admin/app.js +1429 -0
  17. data/app/assets/javascripts/rails_modular_admin/app/_common/editor/editor-helper.js +10 -0
  18. data/app/assets/javascripts/rails_modular_admin/app/_common/editor/editor.js +34 -0
  19. data/app/assets/javascripts/rails_modular_admin/app/_common/header/nav/nav.js +14 -0
  20. data/app/assets/javascripts/rails_modular_admin/app/_common/modals/modal-media/modal-media.js +23 -0
  21. data/app/assets/javascripts/rails_modular_admin/app/_common/sidebar/customize/customize.js +155 -0
  22. data/app/assets/javascripts/rails_modular_admin/app/_common/sidebar/sidebar.js +38 -0
  23. data/app/assets/javascripts/rails_modular_admin/app/charts/charts-flot/charts-flot.js +329 -0
  24. data/app/assets/javascripts/rails_modular_admin/app/charts/charts-morris/charts-morris.js +125 -0
  25. data/app/assets/javascripts/rails_modular_admin/app/dashboard/history/history.js +145 -0
  26. data/app/assets/javascripts/rails_modular_admin/app/dashboard/items/items.js +41 -0
  27. data/app/assets/javascripts/rails_modular_admin/app/dashboard/sales-breakdown/sales-breakdown.js +37 -0
  28. data/app/assets/javascripts/rails_modular_admin/app/dashboard/sales-by-countries/sales-by-countries.js +50 -0
  29. data/app/assets/javascripts/rails_modular_admin/app/dashboard/tasks/tasks.js +13 -0
  30. data/app/assets/javascripts/rails_modular_admin/app/forms/input-groups/input-groups.js +14 -0
  31. data/app/assets/javascripts/rails_modular_admin/app/items/editor/item-editor.js +34 -0
  32. data/app/assets/javascripts/rails_modular_admin/app/items/list/items-list.js +44 -0
  33. data/app/assets/javascripts/rails_modular_admin/app/pages/error.js +18 -0
  34. data/app/assets/javascripts/rails_modular_admin/auth/login/login.js +35 -0
  35. data/app/assets/javascripts/rails_modular_admin/auth/reset/reset.js +31 -0
  36. data/app/assets/javascripts/rails_modular_admin/auth/signup/signup.js +88 -0
  37. data/app/assets/javascripts/rails_modular_admin/config.js +51 -0
  38. data/app/assets/javascripts/rails_modular_admin/main.js +16 -0
  39. data/app/assets/javascripts/rails_modular_admin/vendor.js +60485 -0
  40. data/app/assets/stylesheets/rails_modular_admin.scss +1 -0
  41. data/app/assets/stylesheets/rails_modular_admin/_common/_styles/_mixins.scss +103 -0
  42. data/app/assets/stylesheets/rails_modular_admin/_common/_styles/layout.scss +74 -0
  43. data/app/assets/stylesheets/rails_modular_admin/_common/_styles/misc.scss +115 -0
  44. data/app/assets/stylesheets/rails_modular_admin/_common/_styles/typography.scss +60 -0
  45. data/app/assets/stylesheets/rails_modular_admin/_common/alert/alert.scss +27 -0
  46. data/app/assets/stylesheets/rails_modular_admin/_common/animations/animations.scss +4 -0
  47. data/app/assets/stylesheets/rails_modular_admin/_common/button/button.scss +117 -0
  48. data/app/assets/stylesheets/rails_modular_admin/_common/card/card.scss +200 -0
  49. data/app/assets/stylesheets/rails_modular_admin/_common/chart/chart.scss +9 -0
  50. data/app/assets/stylesheets/rails_modular_admin/_common/dropdown/dropdown.scss +28 -0
  51. data/app/assets/stylesheets/rails_modular_admin/_common/flex/flex.scss +14 -0
  52. data/app/assets/stylesheets/rails_modular_admin/_common/form/form.scss +235 -0
  53. data/app/assets/stylesheets/rails_modular_admin/_common/images-container/images-container.scss +129 -0
  54. data/app/assets/stylesheets/rails_modular_admin/_common/items-list/items-list.scss +388 -0
  55. data/app/assets/stylesheets/rails_modular_admin/_common/logo/logo.scss +46 -0
  56. data/app/assets/stylesheets/rails_modular_admin/_common/modal/modal-tabs.scss +27 -0
  57. data/app/assets/stylesheets/rails_modular_admin/_common/navigation/navigation.scss +114 -0
  58. data/app/assets/stylesheets/rails_modular_admin/_common/nprogress/nprogress.scss +22 -0
  59. data/app/assets/stylesheets/rails_modular_admin/_common/pagination/pagination.scss +20 -0
  60. data/app/assets/stylesheets/rails_modular_admin/_common/sameheight-items/sameheight-items.scss +5 -0
  61. data/app/assets/stylesheets/rails_modular_admin/_common/scrollbar/scrollbar.scss +24 -0
  62. data/app/assets/stylesheets/rails_modular_admin/_common/table/table.scss +12 -0
  63. data/app/assets/stylesheets/rails_modular_admin/_main.scss +41 -0
  64. data/app/assets/stylesheets/rails_modular_admin/_themes/blue-theme.scss +1 -0
  65. data/app/assets/stylesheets/rails_modular_admin/_themes/custom-theme.scss +0 -0
  66. data/app/assets/stylesheets/rails_modular_admin/_themes/green-theme.scss +10 -0
  67. data/app/assets/stylesheets/rails_modular_admin/_themes/orange-theme.scss +12 -0
  68. data/app/assets/stylesheets/rails_modular_admin/_themes/purple-theme.scss +6 -0
  69. data/app/assets/stylesheets/rails_modular_admin/_themes/red-theme.scss +11 -0
  70. data/app/assets/stylesheets/rails_modular_admin/_themes/seagreen-theme.scss +9 -0
  71. data/app/assets/stylesheets/rails_modular_admin/_variables.scss +109 -0
  72. data/app/assets/stylesheets/rails_modular_admin/app/_common/editor/editor.scss +28 -0
  73. data/app/assets/stylesheets/rails_modular_admin/app/_common/footer/footer.scss +68 -0
  74. data/app/assets/stylesheets/rails_modular_admin/app/_common/header/buttons/buttons.scss +30 -0
  75. data/app/assets/stylesheets/rails_modular_admin/app/_common/header/collapse/collapse.scss +23 -0
  76. data/app/assets/stylesheets/rails_modular_admin/app/_common/header/header.scss +33 -0
  77. data/app/assets/stylesheets/rails_modular_admin/app/_common/header/nav/nav.scss +64 -0
  78. data/app/assets/stylesheets/rails_modular_admin/app/_common/header/nav/notifications/notifications.scss +126 -0
  79. data/app/assets/stylesheets/rails_modular_admin/app/_common/header/nav/profile/profile.scss +93 -0
  80. data/app/assets/stylesheets/rails_modular_admin/app/_common/header/search/search.scss +68 -0
  81. data/app/assets/stylesheets/rails_modular_admin/app/_common/modals/modal-media/modal-media.scss +56 -0
  82. data/app/assets/stylesheets/rails_modular_admin/app/_common/modals/modals.scss +19 -0
  83. data/app/assets/stylesheets/rails_modular_admin/app/_common/sidebar/customize/customize.scss +157 -0
  84. data/app/assets/stylesheets/rails_modular_admin/app/_common/sidebar/header/header.scss +14 -0
  85. data/app/assets/stylesheets/rails_modular_admin/app/_common/sidebar/sidebar.scss +240 -0
  86. data/app/assets/stylesheets/rails_modular_admin/app/app.scss +72 -0
  87. data/app/assets/stylesheets/rails_modular_admin/app/charts/charts-flot/charts-flot.scss +18 -0
  88. data/app/assets/stylesheets/rails_modular_admin/app/dashboard/dashboard.scss +7 -0
  89. data/app/assets/stylesheets/rails_modular_admin/app/dashboard/history/history.scss +6 -0
  90. data/app/assets/stylesheets/rails_modular_admin/app/dashboard/items/items-header.scss +81 -0
  91. data/app/assets/stylesheets/rails_modular_admin/app/dashboard/items/items-list.scss +102 -0
  92. data/app/assets/stylesheets/rails_modular_admin/app/dashboard/sales-breakdown/sales-breakdown.scss +7 -0
  93. data/app/assets/stylesheets/rails_modular_admin/app/dashboard/sales-by-countries/sales-by-countries.scss +14 -0
  94. data/app/assets/stylesheets/rails_modular_admin/app/dashboard/stats/stats.scss +70 -0
  95. data/app/assets/stylesheets/rails_modular_admin/app/dashboard/tasks/tasks.scss +47 -0
  96. data/app/assets/stylesheets/rails_modular_admin/app/items/editor/item-editor.scss +3 -0
  97. data/app/assets/stylesheets/rails_modular_admin/app/items/list/items-list.scss +330 -0
  98. data/app/assets/stylesheets/rails_modular_admin/app/pages/error.scss +73 -0
  99. data/app/assets/stylesheets/rails_modular_admin/app/pages/screenful/screenful.scss +101 -0
  100. data/app/assets/stylesheets/rails_modular_admin/app/tables/responsive-tables/responsive-tables.scss +77 -0
  101. data/app/assets/stylesheets/rails_modular_admin/application.scss +26 -0
  102. data/app/assets/stylesheets/rails_modular_admin/auth/auth.scss +72 -0
  103. data/app/controllers/rails_modular_admin/application_controller.rb +5 -0
  104. data/app/helpers/rails_modular_admin/application_helper.rb +4 -0
  105. data/app/jobs/rails_modular_admin/application_job.rb +4 -0
  106. data/app/mailers/rails_modular_admin/application_mailer.rb +6 -0
  107. data/app/models/rails_modular_admin/application_record.rb +5 -0
  108. data/app/views/layouts/rails_modular_admin/application.html.erb +16 -0
  109. data/config/initializers/assets.rb +1 -0
  110. data/config/routes.rb +2 -0
  111. data/lib/generators/rails_modular_admin/USAGE +8 -0
  112. data/lib/generators/rails_modular_admin/install_generator.rb +12 -0
  113. data/lib/generators/rails_modular_admin/templates/custom-theme.scss +14 -0
  114. data/lib/rails_modular_admin.rb +11 -0
  115. data/lib/rails_modular_admin/engine.rb +5 -0
  116. data/lib/rails_modular_admin/version.rb +3 -0
  117. data/lib/tasks/rails_modular_admin_tasks.rake +47 -0
  118. metadata +205 -0
@@ -0,0 +1,28 @@
1
+ .wyswyg {
2
+ border: 1px solid $color-divider;
3
+
4
+ .toolbar,
5
+ .ql-picker-label,
6
+ .ql-picker-options {
7
+ // background-color: lighten($color-divider, 10%) !important;
8
+ }
9
+
10
+ .ql-container {
11
+ border-top: 1px solid $color-divider;
12
+ }
13
+
14
+ .toolbar {
15
+ .btn {
16
+ margin: 0;
17
+ }
18
+ }
19
+
20
+
21
+ .ql-container {
22
+ font-size: 1rem;
23
+
24
+ .ql-editor {
25
+ min-height: 200px;
26
+ }
27
+ }
28
+ }
@@ -0,0 +1,68 @@
1
+ .footer {
2
+ background-color: #fff;
3
+ position: absolute;
4
+ left: $sidebar-width;
5
+ right: 0;
6
+ bottom: 0;
7
+ height: $footer-height;
8
+ display: flex;
9
+ justify-content: space-between;
10
+ align-items: center;
11
+
12
+ .footer-fixed & {
13
+ position: fixed;
14
+ }
15
+
16
+
17
+ .footer-block {
18
+ vertical-align: middle;
19
+ margin-left: 20px;
20
+ margin-right: 20px;
21
+ // line-height: 30px;
22
+ }
23
+
24
+ .footer-github-btn {
25
+ vertical-align: middle;
26
+ }
27
+
28
+ @include media-down(md) {
29
+ left: 0;
30
+ }
31
+
32
+ .author > ul {
33
+ list-style: none;
34
+ margin: 0;
35
+ padding: 0;
36
+
37
+ li {
38
+ display: inline-block;
39
+
40
+ &:after {
41
+ content: "|";
42
+ }
43
+
44
+ &:last-child:after {
45
+ content: "";
46
+ }
47
+
48
+
49
+ @include media-down(md) {
50
+ display: block;
51
+ text-align: right;
52
+
53
+ &:after {
54
+ content: "";
55
+ }
56
+ }
57
+ }
58
+
59
+ @include media-down(md) {
60
+ display: block;
61
+ }
62
+
63
+ @include media-down(sm) {
64
+ display: none;
65
+ }
66
+ }
67
+
68
+ }
@@ -0,0 +1,30 @@
1
+ .header .header-block-buttons {
2
+ text-align: center;
3
+ margin-left: auto;
4
+ margin-right: auto;
5
+ white-space: nowrap;
6
+
7
+ .btn.header-btn {
8
+ background-color: transparent;
9
+ border: 1px solid lighten($color-text, 10%);
10
+ color: lighten($color-text, 10%);
11
+ margin: 0 5px;
12
+ border-radius: 0.2rem;
13
+ // border-radius: 25px;
14
+
15
+ &:hover,
16
+ &:focus {
17
+ border: 1px solid darken($color-text, 10%);
18
+ color: darken($color-text, 10%);
19
+ }
20
+
21
+
22
+ @include media-down(sm) {
23
+ span {
24
+ display: none;
25
+ }
26
+ }
27
+ }
28
+
29
+
30
+ }
@@ -0,0 +1,23 @@
1
+ .header .header-block-collapse {
2
+
3
+ padding-right: 5px;
4
+
5
+ @include media-down(sm) {
6
+ width: 155px;
7
+ }
8
+
9
+ .collapse-btn {
10
+ background: none;
11
+ border: none;
12
+ box-shadow: none;
13
+ color: $color-primary;
14
+ font-size: 24px;
15
+ line-height: 40px;
16
+ border-radius: 0;
17
+ outline: none;
18
+ padding: 0;
19
+ padding-left: 10px;
20
+ padding-right: 10px;
21
+ vertical-align: initial;
22
+ }
23
+ }
@@ -0,0 +1,33 @@
1
+ .header {
2
+ background-color: $color-divider;
3
+ height: $header-height;
4
+ position: absolute;
5
+ left: $sidebar-width;
6
+ right: 0;
7
+ transition: left 0.3s ease;
8
+ z-index: 10;
9
+
10
+ display: flex;
11
+ align-items: center;
12
+ justify-content: space-between;
13
+
14
+
15
+ @include media-down(md) {
16
+ left: 0;
17
+ }
18
+
19
+ @include media-down(sm) {
20
+ left: 0;
21
+ height: $header-height-xs;
22
+ }
23
+
24
+ .header-fixed & {
25
+ position: fixed;
26
+ }
27
+
28
+ .header-block {
29
+ @include media-down(sm) {
30
+ padding: 5px;
31
+ }
32
+ }
33
+ }
@@ -0,0 +1,64 @@
1
+ .header .header-block-nav {
2
+ margin-left: auto;
3
+ white-space: nowrap;
4
+ padding-right: 15px;
5
+
6
+ @include media-down(sm) {
7
+ padding-right: 25px;
8
+ }
9
+
10
+ @include clearfix();
11
+
12
+ a {
13
+ text-decoration: none;
14
+ }
15
+
16
+ // All lists
17
+ ul {
18
+ margin: 0;
19
+ padding: 0;
20
+ list-style: none;
21
+ }
22
+
23
+ & > ul {
24
+ display: table;
25
+ }
26
+
27
+ // First level items
28
+ & > ul > li {
29
+ display: table-cell;
30
+ position: relative;
31
+
32
+ &:before {
33
+ display: block;
34
+ content: " ";
35
+ width: 1px;
36
+ height: 24px;
37
+ top: 50%;
38
+ margin-top: -12px;
39
+ background-color: darken($color-divider, 25%);
40
+ position: absolute;
41
+ left: 0;
42
+ }
43
+
44
+ &:first-child:before {
45
+ display: none;
46
+ }
47
+ }
48
+
49
+ // First leve items links
50
+ & > ul > li > a {
51
+ padding: 0 15px;
52
+ color: $color-text;
53
+
54
+ &:hover {
55
+ color: $color-primary;
56
+ }
57
+ }
58
+
59
+ // Dropdown menus
60
+ .dropdown-menu {
61
+ margin-top: 15px;
62
+ }
63
+
64
+ }
@@ -0,0 +1,126 @@
1
+ .header .header-block-nav {
2
+
3
+ .notifications {
4
+ font-size: 16px;
5
+
6
+
7
+ a {
8
+ padding-right: 10px;
9
+ }
10
+
11
+ .counter {
12
+ font-weight: bold;
13
+ font-size: 14px;
14
+ position: relative;
15
+ top: -3px;
16
+ left: -2px;
17
+ }
18
+
19
+ &.new .counter {
20
+ color: $color-primary;
21
+ font-weight: bold;
22
+ }
23
+
24
+ @include media-down(sm) {
25
+ position: static;
26
+ }
27
+ }
28
+
29
+
30
+ .notifications-dropdown-menu {
31
+ white-space: normal;
32
+ left: auto;
33
+ right: 0;
34
+ min-width: 350px;
35
+
36
+ &:before {
37
+ position: absolute;
38
+ right: 20px;
39
+ bottom: 100%;
40
+ margin-right: -1px;
41
+ // @include triangle(up, 10px, $dropdown-border);
42
+ }
43
+
44
+ &:after {
45
+ position: absolute;
46
+ right: 20px;
47
+ bottom: 100%;
48
+ // @include triangle(up, 9px, $dropdown-bg);
49
+ }
50
+
51
+
52
+ .notifications-container {
53
+ .notification-item {
54
+ border-bottom: 1px solid $dropbown-color-border;
55
+ padding: 5px;
56
+
57
+ &:hover {
58
+ background-color: $dropdown-link-hover-color-bg;
59
+ }
60
+ }
61
+
62
+
63
+ .img-col {
64
+ display: table-cell;
65
+ padding: 5px;
66
+ }
67
+
68
+ .body-col {
69
+ padding: 5px;
70
+ display: table-cell;
71
+ }
72
+
73
+ .img {
74
+ width: 40px;
75
+ height: 40px;
76
+ border-radius: 3px;
77
+ vertical-align: top;
78
+ display: inline-block;
79
+
80
+ @include bg-cover();
81
+ }
82
+
83
+
84
+ p {
85
+ color: $color-text;
86
+ display: inline-block;
87
+ line-height: 18px;
88
+ font-size: 13px;
89
+ margin: 0;
90
+ vertical-align: top;
91
+
92
+ .accent {
93
+ font-weight: bold;
94
+ }
95
+ }
96
+
97
+ }
98
+
99
+
100
+
101
+ footer {
102
+ text-align: center;
103
+
104
+ a {
105
+ color: $dropdown-link-color;
106
+ transition: none;
107
+
108
+ &:hover {
109
+ background-color: $dropdown-link-hover-color-bg;
110
+ color: $color-primary;
111
+ }
112
+ }
113
+ }
114
+
115
+ @include media-down(sm) {
116
+ min-width: 100px;
117
+ width: 100%;
118
+ margin-top: 5px;
119
+
120
+ &:before,
121
+ &:after {
122
+ right: 107px;
123
+ }
124
+ }
125
+ }
126
+ }
@@ -0,0 +1,93 @@
1
+ .header .header-block-nav {
2
+ .profile {
3
+ .img {
4
+ display: inline-block;
5
+ width: 30px;
6
+ height: 30px;
7
+ line-height: 30px;
8
+ border-radius: 4px;
9
+ background-color: darken($color-divider, 25%);
10
+ color: $color-text-inverse;
11
+ text-align: center;
12
+ margin-right: 10px;
13
+ background-repeat: no-repeat;
14
+ background-position: center;
15
+ background-size: cover;
16
+ vertical-align: middle;
17
+ }
18
+
19
+ .name {
20
+ display: inline-block;
21
+ margin-right: 9px;
22
+ font-weight: bold;
23
+
24
+ @include media-down(sm) {
25
+ display: none;
26
+ }
27
+ }
28
+
29
+ .arrow {
30
+ color: $color-primary;
31
+ }
32
+ }
33
+
34
+ .profile-dropdown-menu {
35
+ left: auto;
36
+ right: 0;
37
+ min-width: 180px;
38
+ white-space: normal;
39
+
40
+ &:before {
41
+ position: absolute;
42
+ right: 10px;
43
+ bottom: 100%;
44
+ margin-right: -1px;
45
+ // @include triangle(up, 10px, $dropdown-border);
46
+ }
47
+
48
+ &:after {
49
+ position: absolute;
50
+ right: 10px;
51
+ bottom: 100%;
52
+ // @include triangle(up, 9px, $dropdown-bg);
53
+ }
54
+
55
+ a {
56
+ padding: 10px 15px;
57
+ .icon {
58
+ color: $color-primary;
59
+ text-align: center;
60
+ width: 16px;
61
+ }
62
+
63
+ span {
64
+ display: inline-block;
65
+ padding-left: 5px;
66
+ text-align: left;
67
+ color: $color-text-light;
68
+ }
69
+ }
70
+
71
+ .profile-dropdown-menu-icon {
72
+ padding: 0;
73
+ }
74
+
75
+ .profile-dropdown-menu-topic {
76
+ color: #7e8e9f;
77
+ padding: 0;
78
+ }
79
+
80
+ .dropdown-divider {
81
+ margin: 0;
82
+ }
83
+
84
+ .logout {
85
+ border-top: 1px solid $dropbown-color-border;
86
+ }
87
+
88
+
89
+ @include media-down(sm) {
90
+ margin-top: 8px;
91
+ }
92
+ }
93
+ }