clovercms-dashboard 0.0.1
Sign up to get free protection for your applications and to get access to all the features.
- data/Gemfile +12 -0
- data/MIT-LICENSE +20 -0
- data/README.rdoc +3 -0
- data/Rakefile +29 -0
- data/lib/clovercms/dashboard/app/views/layouts/dashboard.html.erb +33 -0
- data/lib/clovercms/dashboard/app/views/layouts/dashboard/_flashes.html.erb +12 -0
- data/lib/clovercms/dashboard/app/views/layouts/dashboard/_head.html.erb +8 -0
- data/lib/clovercms/dashboard/app/views/layouts/dashboard/_navigation.html.erb +4 -0
- data/lib/clovercms/dashboard/app/views/layouts/dashboard/_top.html.erb +11 -0
- data/lib/dashboard.rb +12 -0
- data/lib/generators/clover_cms/dashboard/install_generator.rb +30 -0
- data/lib/generators/clover_cms/dashboard/templates/haml/layouts/dashboard.html.haml +25 -0
- data/lib/generators/clover_cms/dashboard/templates/haml/layouts/dashboard/_flashes.html.haml +7 -0
- data/lib/generators/clover_cms/dashboard/templates/haml/layouts/dashboard/_head.html.haml +6 -0
- data/lib/generators/clover_cms/dashboard/templates/haml/layouts/dashboard/_navigation.html.haml +3 -0
- data/lib/generators/clover_cms/dashboard/templates/haml/layouts/dashboard/_top.html.haml +8 -0
- data/lib/generators/clover_cms/dashboard/templates/images/error.png +0 -0
- data/lib/generators/clover_cms/dashboard/templates/images/html-bg.jpg +0 -0
- data/lib/generators/clover_cms/dashboard/templates/images/icons/accept.png +0 -0
- data/lib/generators/clover_cms/dashboard/templates/images/icons/add.png +0 -0
- data/lib/generators/clover_cms/dashboard/templates/images/icons/delete.png +0 -0
- data/lib/generators/clover_cms/dashboard/templates/images/icons/disk.png +0 -0
- data/lib/generators/clover_cms/dashboard/templates/images/icons/pencil.png +0 -0
- data/lib/generators/clover_cms/dashboard/templates/images/info.png +0 -0
- data/lib/generators/clover_cms/dashboard/templates/images/logo.png +0 -0
- data/lib/generators/clover_cms/dashboard/templates/images/module-top.png +0 -0
- data/lib/generators/clover_cms/dashboard/templates/images/nav-li-bg.png +0 -0
- data/lib/generators/clover_cms/dashboard/templates/images/success.png +0 -0
- data/lib/generators/clover_cms/dashboard/templates/images/warning.png +0 -0
- data/lib/generators/clover_cms/dashboard/templates/sass/dashboard.scss +412 -0
- data/lib/generators/clover_cms/dashboard/views_generator.rb +21 -0
- metadata +97 -0
data/Gemfile
ADDED
data/MIT-LICENSE
ADDED
@@ -0,0 +1,20 @@
|
|
1
|
+
Copyright 2011 cloverinteractive and its contributors
|
2
|
+
|
3
|
+
Permission is hereby granted, free of charge, to any person obtaining
|
4
|
+
a copy of this software and associated documentation files (the
|
5
|
+
"Software"), to deal in the Software without restriction, including
|
6
|
+
without limitation the rights to use, copy, modify, merge, publish,
|
7
|
+
distribute, sublicense, and/or sell copies of the Software, and to
|
8
|
+
permit persons to whom the Software is furnished to do so, subject to
|
9
|
+
the following conditions:
|
10
|
+
|
11
|
+
The above copyright notice and this permission notice shall be
|
12
|
+
included in all copies or substantial portions of the Software.
|
13
|
+
|
14
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
15
|
+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
16
|
+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
17
|
+
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
18
|
+
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
19
|
+
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
20
|
+
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
data/README.rdoc
ADDED
data/Rakefile
ADDED
@@ -0,0 +1,29 @@
|
|
1
|
+
# encoding: UTF-8
|
2
|
+
require 'rubygems'
|
3
|
+
begin
|
4
|
+
require 'bundler/setup'
|
5
|
+
rescue LoadError
|
6
|
+
puts 'You must `gem install bundler` and `bundle install` to run rake tasks'
|
7
|
+
end
|
8
|
+
|
9
|
+
require 'rake'
|
10
|
+
require 'rake/rdoctask'
|
11
|
+
|
12
|
+
require 'rake/testtask'
|
13
|
+
|
14
|
+
Rake::TestTask.new(:test) do |t|
|
15
|
+
t.libs << 'lib'
|
16
|
+
t.libs << 'test'
|
17
|
+
t.pattern = 'test/**/*_test.rb'
|
18
|
+
t.verbose = false
|
19
|
+
end
|
20
|
+
|
21
|
+
task :default => :test
|
22
|
+
|
23
|
+
Rake::RDocTask.new(:rdoc) do |rdoc|
|
24
|
+
rdoc.rdoc_dir = 'rdoc'
|
25
|
+
rdoc.title = 'Clovercms-dashboard'
|
26
|
+
rdoc.options << '--line-numbers' << '--inline-source'
|
27
|
+
rdoc.rdoc_files.include('README.rdoc')
|
28
|
+
rdoc.rdoc_files.include('lib/**/*.rb')
|
29
|
+
end
|
@@ -0,0 +1,33 @@
|
|
1
|
+
<% selected_tab = ( controller_name == 'registrations' ) ? 'users' : controller_name %>
|
2
|
+
<%= render 'layouts/dashboard/head', :selected_tab => selected_tab %>
|
3
|
+
<%= render 'layouts/dashboard/navigation' %>
|
4
|
+
<%= render 'layouts/dashboard/top' %>
|
5
|
+
|
6
|
+
<!DOCTYPE html>
|
7
|
+
<html>
|
8
|
+
<head>
|
9
|
+
<title><%= content_for?(:title) ? yield(:title) : 'Dashboard' %></title>
|
10
|
+
<%= javascript_include_tag :defaults %>
|
11
|
+
<%= stylesheet_link_tag 'dashboard' %>
|
12
|
+
<%= yield :head %>
|
13
|
+
<%= csrf_meta_tag %>
|
14
|
+
</head>
|
15
|
+
<body>
|
16
|
+
<div id="wrapper">
|
17
|
+
<div id="top"><%= yield :top %></div>
|
18
|
+
<div id="nav_wrap"><%= yield :nav_wrap %></div>
|
19
|
+
<div id="content_wrap">
|
20
|
+
<div id="content">
|
21
|
+
<%= render :partial => 'layouts/dashboard/flashes' %>
|
22
|
+
<div class="module">
|
23
|
+
<h2 class="title"><%= content_for?(:module_title) ? yield(:module_title) : t( "activerecord.models.#{ selected_tab.singularize }" ) %></h2>
|
24
|
+
<div class="module_body"><%= yield %></div>
|
25
|
+
</div>
|
26
|
+
</div>
|
27
|
+
</div>
|
28
|
+
<div id="footer_wrap">
|
29
|
+
<div id="footer"><%= content_for?(:footer) ? yield(:footer) : 'CloverInteractive' %></div>
|
30
|
+
</div>
|
31
|
+
</div>
|
32
|
+
</body>
|
33
|
+
<html>
|
@@ -0,0 +1,12 @@
|
|
1
|
+
<div id="flash">
|
2
|
+
<% flash.each do |(status, message)| %>
|
3
|
+
<%
|
4
|
+
css_class = case status.to_s
|
5
|
+
when 'alert' then 'error'
|
6
|
+
when 'notice' then 'success'
|
7
|
+
else status.to_s
|
8
|
+
end
|
9
|
+
%>
|
10
|
+
<%= content_tag :div, flash[status], :class => css_class %>
|
11
|
+
<% end %>
|
12
|
+
</div>
|
@@ -0,0 +1,11 @@
|
|
1
|
+
<% content_for :top do %>
|
2
|
+
<div id="logo"></div>
|
3
|
+
<div id="account_info">
|
4
|
+
<% if defined?( current_user ) and defined?( edit_user_registration_path ) and defined?( destroy_user_registration_path ) %>
|
5
|
+
<%= t 'common.messages.hi' %>
|
6
|
+
<%= link_to current_user.username, edit_user_registration_path %>
|
7
|
+
<%= t 'common.messages.not_you' %>
|
8
|
+
<%= link_to t('links.logout'), destroy_user_session_path %>
|
9
|
+
<% end %>
|
10
|
+
</div>
|
11
|
+
<% end %>
|
data/lib/dashboard.rb
ADDED
@@ -0,0 +1,12 @@
|
|
1
|
+
module CloverCms
|
2
|
+
module Dashboard
|
3
|
+
class Engine < Rails::Engine
|
4
|
+
$DASHBOARD_APP_PATH = 'lib/clovercms/dashboard'
|
5
|
+
$DASHBOARD_TEMPLATE_PATH = 'lib/generators/clover_cms/dashboard/templates/'
|
6
|
+
$DASHBOARD_SASS_PATH = File.join $DASHBOARD_TEMPLATE_PATH, 'sass'
|
7
|
+
$DASHBOARD_IMAGES_PATH = File.join $DASHBOARD_TEMPLATE_PATH, 'images'
|
8
|
+
|
9
|
+
paths.app.views << File.join( $DASHBOARD_APP_PATH, 'app', 'views' )
|
10
|
+
end
|
11
|
+
end
|
12
|
+
end
|
@@ -0,0 +1,30 @@
|
|
1
|
+
require 'rails/generators/migration'
|
2
|
+
|
3
|
+
module CloverCms
|
4
|
+
module Dashboard
|
5
|
+
module Generators
|
6
|
+
class InstallGenerator < Rails::Generators::Base
|
7
|
+
source_root File.expand_path('../templates', __FILE__)
|
8
|
+
desc "Copies clovercms-dashboard sass to current project"
|
9
|
+
argument :path, :type => :string, :default => "stylesheets", :desc => "The path inside app to put your sass"
|
10
|
+
class_option :asset_pipeline, :type => :boolean, :default => false, :desc => "It sticks to the asset pipeline introduced in rails 3.1"
|
11
|
+
|
12
|
+
def copy_sass
|
13
|
+
if options.asset_pipeline?
|
14
|
+
directory 'sass', "app/assets/stylesheets"
|
15
|
+
else
|
16
|
+
directory 'sass', "app/#{ path }"
|
17
|
+
end
|
18
|
+
end
|
19
|
+
|
20
|
+
def copy_images
|
21
|
+
if options.asset_pipeline?
|
22
|
+
directory 'images', 'app/assets/images/dashboard'
|
23
|
+
else
|
24
|
+
directory 'images', 'public/images/dashboard'
|
25
|
+
end
|
26
|
+
end
|
27
|
+
end
|
28
|
+
end
|
29
|
+
end
|
30
|
+
end
|
@@ -0,0 +1,25 @@
|
|
1
|
+
- selected_tab = ( controller_name == 'registrations' ) ? 'users' : controller_name
|
2
|
+
= render 'layouts/dashboard/head', :selected_tab => selected_tab
|
3
|
+
= render 'layouts/dashboard/navigation'
|
4
|
+
= render 'layouts/dashboard/top'
|
5
|
+
|
6
|
+
!!!
|
7
|
+
%html
|
8
|
+
%head
|
9
|
+
%title= content_for?(:title) ? yield(:title) : 'Dashboard'
|
10
|
+
= javascript_include_tag :defaults
|
11
|
+
= stylesheet_link_tag 'dashboard'
|
12
|
+
= yield :head
|
13
|
+
= csrf_meta_tag
|
14
|
+
%body
|
15
|
+
#wrapper
|
16
|
+
#top=yield :top
|
17
|
+
#nav_wrap= yield :nav_wrap
|
18
|
+
#content_wrap
|
19
|
+
#content
|
20
|
+
= render :partial => 'layouts/dashboard/flashes'
|
21
|
+
.module
|
22
|
+
%h2.title= content_for?(:module_title) ? yield(:module_title) : t( "activerecord.models.#{ selected_tab.singularize }" )
|
23
|
+
.module_body= yield
|
24
|
+
#footer_wrap
|
25
|
+
#footer= content_for?(:footer) ? yield(:footer) : 'CloverInteractive'
|
@@ -0,0 +1,8 @@
|
|
1
|
+
- content_for :top do
|
2
|
+
#logo
|
3
|
+
#account_info
|
4
|
+
- if defined?( current_user ) and defined?( edit_user_registration_path ) and defined?( destroy_user_session_path )
|
5
|
+
= t 'common.messages.hi'
|
6
|
+
= link_to current_user.username, edit_user_registration_path
|
7
|
+
= t 'common.messages.not_you'
|
8
|
+
= link_to t('links.logout'), destroy_user_session_path
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
@@ -0,0 +1,412 @@
|
|
1
|
+
@import "compass/reset";
|
2
|
+
@import "compass/css3/border-radius";
|
3
|
+
|
4
|
+
html {
|
5
|
+
height: 100%;
|
6
|
+
|
7
|
+
body {
|
8
|
+
background: #F2F2F2 url('/images/dashboard/html-bg.jpg') repeat-x left top;
|
9
|
+
height: 100%;
|
10
|
+
font-family: helvetica,arial,freesans,clean,sans-serif;
|
11
|
+
font-size: 13.34px;
|
12
|
+
|
13
|
+
|
14
|
+
#wrapper {
|
15
|
+
min-height:100%;
|
16
|
+
position:relative;
|
17
|
+
overflow:hidden;
|
18
|
+
|
19
|
+
input[type=text], input[type=password] {
|
20
|
+
border: 2px solid #BBB;
|
21
|
+
padding: 6px;
|
22
|
+
display: block;
|
23
|
+
width: 350px;
|
24
|
+
margin: 5px 0;
|
25
|
+
}
|
26
|
+
|
27
|
+
textarea {
|
28
|
+
border: 2px solid #DDD;
|
29
|
+
width: 98%;
|
30
|
+
padding: 10px;
|
31
|
+
margin: 5px 0px 15px;
|
32
|
+
display: block;
|
33
|
+
height: 80px;
|
34
|
+
overflow: auto;
|
35
|
+
}
|
36
|
+
|
37
|
+
select {
|
38
|
+
display: block;
|
39
|
+
margin: 10px 0;
|
40
|
+
}
|
41
|
+
|
42
|
+
h1, h2, h3, h4, h5, h6 {
|
43
|
+
padding-bottom:10px;
|
44
|
+
margin-bottom:10px;
|
45
|
+
position:relative;
|
46
|
+
}
|
47
|
+
|
48
|
+
h1, h2 { border-bottom:1px solid #CCC; }
|
49
|
+
|
50
|
+
h1 { font-size: 26px; }
|
51
|
+
|
52
|
+
h2 { font-size: 20px; }
|
53
|
+
|
54
|
+
h3 { font-size: 16px; }
|
55
|
+
|
56
|
+
h4 { font-size: 14px; }
|
57
|
+
|
58
|
+
h5 { font-size: 12px; }
|
59
|
+
|
60
|
+
h6 { font-size: 10px; }
|
61
|
+
|
62
|
+
#top, #nav, #footer, #content, .sub_nav {
|
63
|
+
width: 98%;
|
64
|
+
margin: 0 auto;
|
65
|
+
position: relative;
|
66
|
+
}
|
67
|
+
|
68
|
+
#top {
|
69
|
+
background-color: #2C3030;
|
70
|
+
color: white;
|
71
|
+
height: 74px;
|
72
|
+
width: 100%;
|
73
|
+
}
|
74
|
+
|
75
|
+
#logo {
|
76
|
+
background: transparent url('/images/dashboard/logo.png') no-repeat 0px 4px;
|
77
|
+
font-family: "Cetury Gothic", sans-serif, arial;
|
78
|
+
font-size: 15px;
|
79
|
+
line-height: 14px;
|
80
|
+
display: inline;
|
81
|
+
margin-left: 10px;
|
82
|
+
width: 352px;
|
83
|
+
padding: 30px 0px;
|
84
|
+
float: left;
|
85
|
+
}
|
86
|
+
|
87
|
+
#account_info {
|
88
|
+
float: right;
|
89
|
+
padding: 27px;
|
90
|
+
|
91
|
+
a { color: #BBB; }
|
92
|
+
}
|
93
|
+
|
94
|
+
#nav_wrap {
|
95
|
+
height: 89px;
|
96
|
+
clear: both;
|
97
|
+
|
98
|
+
#nav {
|
99
|
+
list-style: none;
|
100
|
+
overflow: hidden;
|
101
|
+
|
102
|
+
a, a:active, a:visited {
|
103
|
+
color: white;
|
104
|
+
text-decoration: none;
|
105
|
+
padding: 12px 16px 9px 16px;
|
106
|
+
font-size: 17px;
|
107
|
+
display: block;
|
108
|
+
}
|
109
|
+
|
110
|
+
a:hover, li.active a {
|
111
|
+
background: #0057A9 url('/images/dashboard/nav-li-bg.png') repeat-x left top;
|
112
|
+
padding: 10px 14px 9px 14px;
|
113
|
+
@include border-radius(10px 10px 0px 0px);
|
114
|
+
}
|
115
|
+
|
116
|
+
li {
|
117
|
+
float: left;
|
118
|
+
margin-top: 10px;
|
119
|
+
margin-right: 10px;
|
120
|
+
@include border-radius(10px 10px 0px 0px);
|
121
|
+
}
|
122
|
+
|
123
|
+
li:hover, li.active {
|
124
|
+
padding: 0px;
|
125
|
+
border: 1px solid #33472C;
|
126
|
+
border-bottom: 0px;
|
127
|
+
}
|
128
|
+
}
|
129
|
+
|
130
|
+
.sub_nav {
|
131
|
+
list-style: none;
|
132
|
+
height: 36px;
|
133
|
+
overflow: hidden;
|
134
|
+
|
135
|
+
li {
|
136
|
+
float: left;
|
137
|
+
padding: 0 10px;
|
138
|
+
margin-top: 10px;
|
139
|
+
font-size: 12px;
|
140
|
+
|
141
|
+
a {
|
142
|
+
text-decoration: none;
|
143
|
+
color: #BDF58F;
|
144
|
+
}
|
145
|
+
}
|
146
|
+
|
147
|
+
li a:hover {
|
148
|
+
color: white;
|
149
|
+
}
|
150
|
+
|
151
|
+
li.current span {
|
152
|
+
color: #FFF;
|
153
|
+
}
|
154
|
+
}
|
155
|
+
}
|
156
|
+
|
157
|
+
#content_wrap {
|
158
|
+
background-color: #F2F2F2;
|
159
|
+
padding-bottom: 70px;
|
160
|
+
|
161
|
+
#content {
|
162
|
+
padding: 10px 0px;
|
163
|
+
overflow: hidden;
|
164
|
+
|
165
|
+
.buttonset label {
|
166
|
+
margin-bottom: 5px;
|
167
|
+
padding: 0px;
|
168
|
+
font-weight: normal;
|
169
|
+
}
|
170
|
+
|
171
|
+
div.box {
|
172
|
+
border: 1px solid gray;
|
173
|
+
padding: 15px;
|
174
|
+
background-color: #EEE;
|
175
|
+
color: #333;
|
176
|
+
|
177
|
+
p { line-height: 19px; }
|
178
|
+
}
|
179
|
+
|
180
|
+
#roles.box {
|
181
|
+
ul li {
|
182
|
+
list-style: none;
|
183
|
+
|
184
|
+
label {
|
185
|
+
display: inline;
|
186
|
+
cursor: pointer;
|
187
|
+
text-decoration: underline;
|
188
|
+
font-size: 12px;
|
189
|
+
font-weight: normal;
|
190
|
+
}
|
191
|
+
}
|
192
|
+
}
|
193
|
+
|
194
|
+
.ui-widget { font-size: 13px; }
|
195
|
+
|
196
|
+
p {
|
197
|
+
margin-bottom: 10px;
|
198
|
+
font-size: 13px;
|
199
|
+
}
|
200
|
+
|
201
|
+
.module {
|
202
|
+
border: 1px solid #CCC;
|
203
|
+
background-color: white;
|
204
|
+
margin-bottom: #393939;
|
205
|
+
|
206
|
+
.module_body {
|
207
|
+
background-color:#fefefe;
|
208
|
+
margin:10px;
|
209
|
+
color:#393939;
|
210
|
+
|
211
|
+
#keyword_button {
|
212
|
+
position: relative;
|
213
|
+
top: -5px;
|
214
|
+
}
|
215
|
+
}
|
216
|
+
|
217
|
+
h2.title {
|
218
|
+
background: #ededed url('/images/dashboard/module-top.png') repeat-x left top;
|
219
|
+
padding: 10px;
|
220
|
+
display: block;
|
221
|
+
border-bottom: 1px solid #CCC;
|
222
|
+
color: #6A9158;
|
223
|
+
}
|
224
|
+
|
225
|
+
.tabular {
|
226
|
+
width: 100%;
|
227
|
+
margin-bottom: 10px;
|
228
|
+
border-right: 1px solid #CCC;
|
229
|
+
border-top: 1px solid #CCC;
|
230
|
+
|
231
|
+
th {
|
232
|
+
text-align: left;
|
233
|
+
background-color: #EEE;
|
234
|
+
padding: 10px 5px;
|
235
|
+
border-right: 1px solid white;
|
236
|
+
border-left: 1px solid #CCC;
|
237
|
+
}
|
238
|
+
|
239
|
+
td {
|
240
|
+
padding: 5px;
|
241
|
+
border-left: 1px solid #CCC;
|
242
|
+
border-bottom: 1px solid #CCC;
|
243
|
+
}
|
244
|
+
|
245
|
+
tr.even {
|
246
|
+
background-color: #EDF8FF;
|
247
|
+
}
|
248
|
+
}
|
249
|
+
}
|
250
|
+
}
|
251
|
+
}
|
252
|
+
|
253
|
+
#footer_wrap {
|
254
|
+
background-color: #2C3030;
|
255
|
+
color: white;
|
256
|
+
width: 100%;
|
257
|
+
height: 70px;
|
258
|
+
overflow: hidden;
|
259
|
+
position: absolute;
|
260
|
+
bottom: 0px;
|
261
|
+
|
262
|
+
#footer {
|
263
|
+
padding-top: 30px;
|
264
|
+
}
|
265
|
+
}
|
266
|
+
}
|
267
|
+
}
|
268
|
+
}
|
269
|
+
|
270
|
+
a, a:active, a:visited {
|
271
|
+
color: #0069CB;
|
272
|
+
text-decoration: none;
|
273
|
+
}
|
274
|
+
|
275
|
+
a:hover {
|
276
|
+
text-decoration: underline;
|
277
|
+
}
|
278
|
+
|
279
|
+
label {
|
280
|
+
font-size: 14px;
|
281
|
+
line-height: 19px;
|
282
|
+
font-weight: bold;
|
283
|
+
display: block;
|
284
|
+
|
285
|
+
small {
|
286
|
+
font-size: 12px;
|
287
|
+
color: gray;
|
288
|
+
font-weight: normal;
|
289
|
+
}
|
290
|
+
}
|
291
|
+
|
292
|
+
/* Global status styles */
|
293
|
+
|
294
|
+
#wrapper {
|
295
|
+
.error, .warning, .info, .success {
|
296
|
+
padding:10px;
|
297
|
+
padding-left:40px;
|
298
|
+
margin:10px 0px;
|
299
|
+
}
|
300
|
+
|
301
|
+
.error{
|
302
|
+
border:1px solid #ff9b9b;
|
303
|
+
background:#ffd3d3 url('/images/dashboard/error.png') no-repeat 10px 7px;
|
304
|
+
color:#de1414;
|
305
|
+
}
|
306
|
+
|
307
|
+
.info {
|
308
|
+
border:1px solid #5abef3;
|
309
|
+
background:#d9f4ff url('/images/dashboard/info.png') no-repeat 10px 7px;
|
310
|
+
color:#0069cb;
|
311
|
+
}
|
312
|
+
|
313
|
+
.success {
|
314
|
+
border:1px solid #78ce4d;
|
315
|
+
background:#e8ffe2 url('/images/dashboard/success.png') no-repeat 10px 7px;
|
316
|
+
color:#007e1b;
|
317
|
+
}
|
318
|
+
|
319
|
+
.warning {
|
320
|
+
border: 1px solid #c4bc16;
|
321
|
+
background: #fffed7 url('/images/dashboard/warning.png') no-repeat 10px 7px;
|
322
|
+
color: #6e6000;
|
323
|
+
}
|
324
|
+
|
325
|
+
.clear {
|
326
|
+
clear:both;
|
327
|
+
line-height:1px;
|
328
|
+
font-size:1px;
|
329
|
+
}
|
330
|
+
|
331
|
+
.center { text-align: center; }
|
332
|
+
|
333
|
+
.left { text-align: left; }
|
334
|
+
|
335
|
+
.right { text-align: right; }
|
336
|
+
|
337
|
+
.float_right { float: right; }
|
338
|
+
|
339
|
+
.float_left { float: left; }
|
340
|
+
|
341
|
+
.bold { font-weight: bolder; }
|
342
|
+
|
343
|
+
#content {
|
344
|
+
.columns{
|
345
|
+
overflow:hidden;
|
346
|
+
.half {
|
347
|
+
display: inline;
|
348
|
+
width: 49%;
|
349
|
+
float: left;
|
350
|
+
margin-right: 1%;
|
351
|
+
|
352
|
+
h1 span.right, h2 span.right, h3 span.right, h4 span.right, h5 span.right, h6 span.right {
|
353
|
+
position: absolute;
|
354
|
+
float: right;
|
355
|
+
margin-top: 0px;
|
356
|
+
right: 0px;
|
357
|
+
}
|
358
|
+
}
|
359
|
+
}
|
360
|
+
|
361
|
+
.icon {
|
362
|
+
background-position: 0 40%;
|
363
|
+
padding-left: 20px;
|
364
|
+
padding-right: 5px;
|
365
|
+
padding-bottom: 5px;
|
366
|
+
}
|
367
|
+
|
368
|
+
.icon.pencil {
|
369
|
+
background: url('/images/dashboard/icons/pencil.png') no-repeat;
|
370
|
+
}
|
371
|
+
|
372
|
+
.icon.delete {
|
373
|
+
background: url('/images/dashboard/icons/delete.png') no-repeat;
|
374
|
+
}
|
375
|
+
|
376
|
+
.icon.add {
|
377
|
+
background: url('/images/dashboard/icons/add.png') no-repeat;
|
378
|
+
}
|
379
|
+
|
380
|
+
.icon.accept {
|
381
|
+
background: url('/images/dashboard/icons/accept.png') no-repeat;
|
382
|
+
}
|
383
|
+
|
384
|
+
.icon.disk {
|
385
|
+
background: url('/images/dashboard/icons/disk.png') no-repeat;
|
386
|
+
}
|
387
|
+
}
|
388
|
+
}
|
389
|
+
|
390
|
+
.field_with_errors input, .field_with_errors textarea {
|
391
|
+
background-color: #FFAAAA;
|
392
|
+
border: 2px solid #A00000 !important;
|
393
|
+
color: #AA0000;
|
394
|
+
}
|
395
|
+
|
396
|
+
.wym_section.wym_dropdown {
|
397
|
+
display: none;
|
398
|
+
}
|
399
|
+
|
400
|
+
.wym_skin_compact {
|
401
|
+
border: 0px !important;
|
402
|
+
padding: 5px 15px;
|
403
|
+
}
|
404
|
+
|
405
|
+
ul{
|
406
|
+
list-style: disc outside none;
|
407
|
+
}
|
408
|
+
|
409
|
+
ol{
|
410
|
+
list-style: decimal outside none;
|
411
|
+
margin-left:25px;
|
412
|
+
}
|
@@ -0,0 +1,21 @@
|
|
1
|
+
module CloverCms
|
2
|
+
module Dashboard
|
3
|
+
module Generators
|
4
|
+
class ViewsGenerator < ::Rails::Generators::Base
|
5
|
+
LIB_ROOT_APP_PATH = '../../../../clovercms/dashboard/'
|
6
|
+
source_root File.expand_path( '../templates', __FILE__ )
|
7
|
+
|
8
|
+
desc "Generates dashboard views"
|
9
|
+
class_option :haml, :type => :boolean, :default => false, :desc => 'Generates views in haml format'
|
10
|
+
|
11
|
+
def copy_views
|
12
|
+
if options.haml
|
13
|
+
directory 'haml', "app/views"
|
14
|
+
else
|
15
|
+
directory File.expand_path( File.join( LIB_ROOT_APP_PATH, 'app/views' ), __FILE__ ), 'app/views'
|
16
|
+
end
|
17
|
+
end
|
18
|
+
end
|
19
|
+
end
|
20
|
+
end
|
21
|
+
end
|
metadata
ADDED
@@ -0,0 +1,97 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: clovercms-dashboard
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
hash: 29
|
5
|
+
prerelease:
|
6
|
+
segments:
|
7
|
+
- 0
|
8
|
+
- 0
|
9
|
+
- 1
|
10
|
+
version: 0.0.1
|
11
|
+
platform: ruby
|
12
|
+
authors:
|
13
|
+
- Enrique Vidal
|
14
|
+
autorequire:
|
15
|
+
bindir: bin
|
16
|
+
cert_chain: []
|
17
|
+
|
18
|
+
date: 2011-06-27 00:00:00 -07:00
|
19
|
+
default_executable:
|
20
|
+
dependencies: []
|
21
|
+
|
22
|
+
description: Dashboard look n' feel for Rails 3
|
23
|
+
email: enrique@cloverinteractive.com
|
24
|
+
executables: []
|
25
|
+
|
26
|
+
extensions: []
|
27
|
+
|
28
|
+
extra_rdoc_files: []
|
29
|
+
|
30
|
+
files:
|
31
|
+
- lib/clovercms/dashboard/app/views/layouts/dashboard/_flashes.html.erb
|
32
|
+
- lib/clovercms/dashboard/app/views/layouts/dashboard/_head.html.erb
|
33
|
+
- lib/clovercms/dashboard/app/views/layouts/dashboard/_navigation.html.erb
|
34
|
+
- lib/clovercms/dashboard/app/views/layouts/dashboard/_top.html.erb
|
35
|
+
- lib/clovercms/dashboard/app/views/layouts/dashboard.html.erb
|
36
|
+
- lib/dashboard.rb
|
37
|
+
- lib/generators/clover_cms/dashboard/install_generator.rb
|
38
|
+
- lib/generators/clover_cms/dashboard/templates/haml/layouts/dashboard/_flashes.html.haml
|
39
|
+
- lib/generators/clover_cms/dashboard/templates/haml/layouts/dashboard/_head.html.haml
|
40
|
+
- lib/generators/clover_cms/dashboard/templates/haml/layouts/dashboard/_navigation.html.haml
|
41
|
+
- lib/generators/clover_cms/dashboard/templates/haml/layouts/dashboard/_top.html.haml
|
42
|
+
- lib/generators/clover_cms/dashboard/templates/haml/layouts/dashboard.html.haml
|
43
|
+
- lib/generators/clover_cms/dashboard/templates/images/error.png
|
44
|
+
- lib/generators/clover_cms/dashboard/templates/images/html-bg.jpg
|
45
|
+
- lib/generators/clover_cms/dashboard/templates/images/icons/accept.png
|
46
|
+
- lib/generators/clover_cms/dashboard/templates/images/icons/add.png
|
47
|
+
- lib/generators/clover_cms/dashboard/templates/images/icons/delete.png
|
48
|
+
- lib/generators/clover_cms/dashboard/templates/images/icons/disk.png
|
49
|
+
- lib/generators/clover_cms/dashboard/templates/images/icons/pencil.png
|
50
|
+
- lib/generators/clover_cms/dashboard/templates/images/info.png
|
51
|
+
- lib/generators/clover_cms/dashboard/templates/images/logo.png
|
52
|
+
- lib/generators/clover_cms/dashboard/templates/images/module-top.png
|
53
|
+
- lib/generators/clover_cms/dashboard/templates/images/nav-li-bg.png
|
54
|
+
- lib/generators/clover_cms/dashboard/templates/images/success.png
|
55
|
+
- lib/generators/clover_cms/dashboard/templates/images/warning.png
|
56
|
+
- lib/generators/clover_cms/dashboard/templates/sass/dashboard.scss
|
57
|
+
- lib/generators/clover_cms/dashboard/views_generator.rb
|
58
|
+
- MIT-LICENSE
|
59
|
+
- Rakefile
|
60
|
+
- Gemfile
|
61
|
+
- README.rdoc
|
62
|
+
has_rdoc: true
|
63
|
+
homepage: http://github.com/cloverinteractive/clovercms-dashboard
|
64
|
+
licenses: []
|
65
|
+
|
66
|
+
post_install_message:
|
67
|
+
rdoc_options: []
|
68
|
+
|
69
|
+
require_paths:
|
70
|
+
- lib
|
71
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
72
|
+
none: false
|
73
|
+
requirements:
|
74
|
+
- - ">="
|
75
|
+
- !ruby/object:Gem::Version
|
76
|
+
hash: 3
|
77
|
+
segments:
|
78
|
+
- 0
|
79
|
+
version: "0"
|
80
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
81
|
+
none: false
|
82
|
+
requirements:
|
83
|
+
- - ">="
|
84
|
+
- !ruby/object:Gem::Version
|
85
|
+
hash: 3
|
86
|
+
segments:
|
87
|
+
- 0
|
88
|
+
version: "0"
|
89
|
+
requirements: []
|
90
|
+
|
91
|
+
rubyforge_project:
|
92
|
+
rubygems_version: 1.5.2
|
93
|
+
signing_key:
|
94
|
+
specification_version: 3
|
95
|
+
summary: Dashboard theme for Rails 3.x
|
96
|
+
test_files: []
|
97
|
+
|