sinatra-hexacta 1.1.2 → 1.2.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/sinatra/handlers/constants.rb +1 -1
- data/lib/sinatra/handlers/init.rb +1 -0
- data/lib/sinatra/handlers/user_configurations.rb +26 -0
- data/lib/sinatra/helpers/init.rb +1 -0
- data/lib/sinatra/helpers/user_configurations.rb +21 -0
- data/lib/sinatra/public/css/app.min.1.css +0 -4
- data/lib/sinatra/public/css/darkmode.css +262 -0
- data/lib/sinatra/public/css/wieldy.css +121 -0
- data/lib/sinatra/public/img/finder.png +0 -0
- data/lib/sinatra/public/img/teams.png +0 -0
- data/lib/sinatra/views/charts/pie.slim +37 -34
- data/lib/sinatra/views/constants/group.slim +1 -1
- data/lib/sinatra/views/user_configurations/edit.slim +51 -0
- data/lib/sinatra/views/user_configurations/include.slim +21 -0
- metadata +9 -2
- data/lib/sinatra/public/img/finder.jpg +0 -0
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 8331478af6878415f2a47eed822f942c8ba0e295c46ff6fcee4c5c97db2cc6c4
|
4
|
+
data.tar.gz: d27a3b1c60dbda7deadd4ddd1d7eca7cee96d48a4fd1d9aead1e95aac20494d5
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7c34c5bd46b1e26092dbc99ea123fb51a14318bb20a94bcd7390f6036502a91a9befaa9d1057ef868804bc491fcdf2d872555e109fbb5bfd664b5412b8a2b1d8
|
7
|
+
data.tar.gz: b94f1c5af15ddf9337e0c7e7694e1f92d2c1b9f8dd9f717c908c3745a96179ba97df798afe2333e9ba6e611d9b10cd6a1693833b24fe73d21dd0f2e739b06ace
|
@@ -9,7 +9,7 @@ module Sinatra
|
|
9
9
|
ConstantHandler.copy_all_files("/lib/sinatra/views/constants","/app/views/#{Hexacta::GEM_FILE_DIR}/constants")
|
10
10
|
|
11
11
|
before '/constant*' do
|
12
|
-
error(403) if authenticated(User).permissions.empty?
|
12
|
+
error(403) if authenticated(User).permissions.empty?
|
13
13
|
end
|
14
14
|
|
15
15
|
get '/constants' do
|
@@ -0,0 +1,26 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
module Sinatra
|
3
|
+
module UserConfigurationHandler
|
4
|
+
extend Hexacta
|
5
|
+
|
6
|
+
def enable_user_configuration
|
7
|
+
p "Enabling user configurations..."
|
8
|
+
|
9
|
+
get '/user/configuration' do
|
10
|
+
user = authenticated(User)
|
11
|
+
slim :'users/configuration', locals: { :user => user }
|
12
|
+
end
|
13
|
+
|
14
|
+
post '/user/configuration' do
|
15
|
+
user_configuration_params = params.select { |attribute| UserConfiguration.columns.include?(attribute.to_sym) }
|
16
|
+
user_configuration = UserConfiguration.find_or_create(:user_id => authenticated(User).id)
|
17
|
+
user_configuration.update_fields(user_configuration_params, UserConfiguration.columns, :missing => :skip)
|
18
|
+
redirect back
|
19
|
+
end
|
20
|
+
|
21
|
+
end
|
22
|
+
|
23
|
+
end
|
24
|
+
register UserConfigurationHandler
|
25
|
+
end
|
26
|
+
|
data/lib/sinatra/helpers/init.rb
CHANGED
@@ -0,0 +1,21 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
module Sinatra
|
3
|
+
module UserConfigurationHelper
|
4
|
+
extend Hexacta
|
5
|
+
|
6
|
+
def include_user_configuration
|
7
|
+
slim "#{Hexacta::GEM_FILE_DIR}/user_configurations/include".to_sym
|
8
|
+
end
|
9
|
+
|
10
|
+
def edit_user_configuration
|
11
|
+
slim "#{Hexacta::GEM_FILE_DIR}/user_configurations/edit".to_sym
|
12
|
+
end
|
13
|
+
|
14
|
+
p "Setting up user configurations directory..."
|
15
|
+
copy_dir_structure("/lib/sinatra/public","/app/public/#{Hexacta::GEM_FILE_DIR}")
|
16
|
+
setup_dir("/app/views/#{Hexacta::GEM_FILE_DIR}/user_configurations")
|
17
|
+
copy_all_files("/lib/sinatra/views/user_configurations","/app/views/#{Hexacta::GEM_FILE_DIR}/libraries")
|
18
|
+
end
|
19
|
+
|
20
|
+
helpers UserConfigurationHelper
|
21
|
+
end
|
@@ -0,0 +1,262 @@
|
|
1
|
+
body {
|
2
|
+
color: #eee;
|
3
|
+
background: #616161;
|
4
|
+
}
|
5
|
+
|
6
|
+
a {
|
7
|
+
color: #809fff !Important;
|
8
|
+
}
|
9
|
+
|
10
|
+
.sidebar {
|
11
|
+
background: #424242;
|
12
|
+
}
|
13
|
+
|
14
|
+
.main-menu > li > a {
|
15
|
+
color: #bdbdbd;
|
16
|
+
}
|
17
|
+
|
18
|
+
.main-menu > li > a:hover, .main-menu > li.active > a {
|
19
|
+
color: #e0e0e0;
|
20
|
+
background-color: #616161;
|
21
|
+
}
|
22
|
+
|
23
|
+
.sub-menu ul > li > a, .sub-menu > a:before, .sub-menu > a:after {
|
24
|
+
color: #bdbdbd;
|
25
|
+
}
|
26
|
+
|
27
|
+
.sub-menu ul > li > a.active, .sub-menu ul > li > a:hover {
|
28
|
+
color: #eeeeee;
|
29
|
+
}
|
30
|
+
|
31
|
+
.sub-menu ul > li ul {
|
32
|
+
background: #616161;
|
33
|
+
}
|
34
|
+
|
35
|
+
.card {
|
36
|
+
background: #424242;
|
37
|
+
}
|
38
|
+
|
39
|
+
#profile-main .pm-overview {
|
40
|
+
background: #757575;
|
41
|
+
border-right: 1px solid #757575;
|
42
|
+
}
|
43
|
+
|
44
|
+
.tab-nav {
|
45
|
+
box-shadow: inset 0 -2px 0 0 #616161;
|
46
|
+
}
|
47
|
+
|
48
|
+
.tab-nav li > a {
|
49
|
+
color: #9e9e9e;
|
50
|
+
}
|
51
|
+
|
52
|
+
.tab-nav li.active > a {
|
53
|
+
color: white;
|
54
|
+
}
|
55
|
+
|
56
|
+
.t-view .tv-header {
|
57
|
+
border-bottom: 1px solid #757575;
|
58
|
+
background: #616161;
|
59
|
+
}
|
60
|
+
|
61
|
+
.t-view {
|
62
|
+
border: 1px solid #757575;
|
63
|
+
}
|
64
|
+
|
65
|
+
.bgm-lightgray {
|
66
|
+
background: #757575 !Important;
|
67
|
+
}
|
68
|
+
|
69
|
+
h1, h2, h3, h4, h5, h6, .h1, .h2, .h3, .h4, .h5, .h6 {
|
70
|
+
color: #fafafa;
|
71
|
+
}
|
72
|
+
|
73
|
+
.btn-default {
|
74
|
+
color: white;
|
75
|
+
background-color: #9e9e9e;
|
76
|
+
border-color: #cccccc;
|
77
|
+
}
|
78
|
+
|
79
|
+
.footer-text .text {
|
80
|
+
opacity: 0.8;
|
81
|
+
}
|
82
|
+
|
83
|
+
.block-header h2 {
|
84
|
+
color: #bdbdbd !Important;
|
85
|
+
}
|
86
|
+
|
87
|
+
#header .results, #header .results .card .card-header.ch-alt {
|
88
|
+
background: #424242 !Important;
|
89
|
+
}
|
90
|
+
|
91
|
+
#messages-main .ms-menu {
|
92
|
+
background: #757575;
|
93
|
+
border-right: 1px solid #757575;
|
94
|
+
}
|
95
|
+
|
96
|
+
.lvhs-input {
|
97
|
+
background: #424242;
|
98
|
+
border-bottom: 1px solid #757575;
|
99
|
+
}
|
100
|
+
|
101
|
+
.lvh-search {
|
102
|
+
background: #616161;
|
103
|
+
}
|
104
|
+
|
105
|
+
#messages-main .ms-menu .lv-item.active {
|
106
|
+
background: #616161;
|
107
|
+
}
|
108
|
+
|
109
|
+
#messages-main .ms-menu .lv-item:not(.active):hover {
|
110
|
+
background: #616161;
|
111
|
+
}
|
112
|
+
|
113
|
+
.chosen-container-multi .chosen-choices, .chosen-container-single .chosen-single {
|
114
|
+
border-bottom: 1px solid #616161 !Important;
|
115
|
+
}
|
116
|
+
|
117
|
+
.form-control, .pagination > li > a, .pagination > li > span {
|
118
|
+
background-color: transparent;
|
119
|
+
border: 1px solid #9e9e9e;
|
120
|
+
color: white;
|
121
|
+
}
|
122
|
+
|
123
|
+
.chosen-container .chosen-drop {
|
124
|
+
background: #757575;
|
125
|
+
}
|
126
|
+
|
127
|
+
.chosen-container .chosen-results {
|
128
|
+
color: white;
|
129
|
+
}
|
130
|
+
|
131
|
+
.chosen-container .chosen-results li.result-selected {
|
132
|
+
color: #bdbdbd;
|
133
|
+
}
|
134
|
+
|
135
|
+
.chosen-container .chosen-results li.highlighted {
|
136
|
+
color: #eeeeee;
|
137
|
+
}
|
138
|
+
|
139
|
+
.chosen-container-multi .chosen-choices li.search-choice {
|
140
|
+
background: #757575 !Important;
|
141
|
+
color: #bdbdbd !Important;
|
142
|
+
}
|
143
|
+
|
144
|
+
.chosen-container-single .chosen-search {
|
145
|
+
background: #9e9e9e;
|
146
|
+
}
|
147
|
+
|
148
|
+
.chosen-container-single .chosen-search {
|
149
|
+
-webkit-box-shadow: 0 1px 0 #757575 inset;
|
150
|
+
box-shadow: 0 1px 0 #757575 inset;
|
151
|
+
}
|
152
|
+
|
153
|
+
.chosen-container-single .chosen-single {
|
154
|
+
color: white;
|
155
|
+
}
|
156
|
+
|
157
|
+
.listview:not(.lv-message) .lv-title {
|
158
|
+
color: #eeeeee;
|
159
|
+
}
|
160
|
+
|
161
|
+
.listview a.lv-item:hover {
|
162
|
+
background: #757575;
|
163
|
+
}
|
164
|
+
|
165
|
+
.modal-content {
|
166
|
+
background-color: #424242;
|
167
|
+
}
|
168
|
+
|
169
|
+
.modal .modal-footer .btn-link {
|
170
|
+
color: white;
|
171
|
+
}
|
172
|
+
|
173
|
+
.modal:not([data-modal-color]) .modal-footer .btn-link:hover {
|
174
|
+
background-color: #9e9e9e;
|
175
|
+
}
|
176
|
+
|
177
|
+
.dropdown-menu {
|
178
|
+
background-color: #616161;
|
179
|
+
}
|
180
|
+
|
181
|
+
.lv-header {
|
182
|
+
border-bottom: 1px solid #424242;
|
183
|
+
color: white;
|
184
|
+
}
|
185
|
+
|
186
|
+
.lv-footer {
|
187
|
+
border-top: 1px solid #424242;
|
188
|
+
color: white;
|
189
|
+
}
|
190
|
+
|
191
|
+
.twitter-typeahead .tt-menu {
|
192
|
+
background: #757575;
|
193
|
+
}
|
194
|
+
|
195
|
+
.c-black {
|
196
|
+
color: white !Important;
|
197
|
+
}
|
198
|
+
|
199
|
+
.pt-inner .pti-header > h2 small {
|
200
|
+
border-left: 1px solid white !important;
|
201
|
+
}
|
202
|
+
|
203
|
+
.table-striped > tbody > tr:nth-of-type(odd) {
|
204
|
+
background-color: #757575;
|
205
|
+
}
|
206
|
+
|
207
|
+
.ct-label {
|
208
|
+
color: white;
|
209
|
+
}
|
210
|
+
|
211
|
+
.table {
|
212
|
+
background-color: #616161;
|
213
|
+
}
|
214
|
+
|
215
|
+
.table > thead > tr > th, .card-header h4 {
|
216
|
+
background-color: #424242;
|
217
|
+
color: white;
|
218
|
+
}
|
219
|
+
|
220
|
+
.listview:not(.lv-lg):not(.lv-message) .lv-item {
|
221
|
+
border-bottom: 1px solid #424242 !important;
|
222
|
+
}
|
223
|
+
|
224
|
+
.weekend {
|
225
|
+
background: #424242;
|
226
|
+
}
|
227
|
+
|
228
|
+
.table-hover > tbody > tr:hover {
|
229
|
+
background-color: #757575;
|
230
|
+
}
|
231
|
+
|
232
|
+
.listview.lv-bordered .lv-item:not(:last-child) {
|
233
|
+
border-bottom: 1px solid #757575;
|
234
|
+
}
|
235
|
+
|
236
|
+
.striped .row:nth-child(odd) {
|
237
|
+
background-color: #757575;
|
238
|
+
}
|
239
|
+
|
240
|
+
.striped .row:nth-child(even) {
|
241
|
+
background-color: #616161;
|
242
|
+
}
|
243
|
+
|
244
|
+
#notifications-list a.lv-item {
|
245
|
+
background-color: #616161 !important;
|
246
|
+
}
|
247
|
+
|
248
|
+
.hiring_semaphore div[status='pending'] {
|
249
|
+
background-color: #ff9800 !important
|
250
|
+
}
|
251
|
+
|
252
|
+
#best-selling {
|
253
|
+
background-color: #424242;
|
254
|
+
}
|
255
|
+
|
256
|
+
.role {
|
257
|
+
background-color: #424242 !Important;
|
258
|
+
}
|
259
|
+
|
260
|
+
.listview.lv-lg .lv-item:hover {
|
261
|
+
background-color: #243B53 !Important;
|
262
|
+
}
|
@@ -0,0 +1,121 @@
|
|
1
|
+
|
2
|
+
#header {
|
3
|
+
margin-top: 10px;
|
4
|
+
border-radius: 6px;
|
5
|
+
width: 95%;
|
6
|
+
left: 50%;
|
7
|
+
margin-left: -48%;
|
8
|
+
}
|
9
|
+
|
10
|
+
#sidebar {
|
11
|
+
overflow: visible;
|
12
|
+
margin-left: 2%;
|
13
|
+
margin-top: 30px;
|
14
|
+
border-radius: 6px;
|
15
|
+
overflow: hidden !Important;
|
16
|
+
height: auto;
|
17
|
+
max-height: calc(100% - 65px);
|
18
|
+
}
|
19
|
+
|
20
|
+
.card {
|
21
|
+
box-shadow: 0 0 5px 5px rgba(0, 0, 0, 0.03);
|
22
|
+
border-radius: 6px;
|
23
|
+
}
|
24
|
+
|
25
|
+
.card .tab-nav {
|
26
|
+
border-radius: 6px;
|
27
|
+
}
|
28
|
+
|
29
|
+
|
30
|
+
#profile-main {
|
31
|
+
background: none;
|
32
|
+
box-shadow: none;
|
33
|
+
}
|
34
|
+
|
35
|
+
@media (min-width: 1200px) {
|
36
|
+
#profile-main .pm-body {
|
37
|
+
padding-left: 220px;
|
38
|
+
}
|
39
|
+
}
|
40
|
+
|
41
|
+
@media (min-width: 768px) and (max-width: 1200px) {
|
42
|
+
#profile-main .pm-body {
|
43
|
+
padding-left: 220px;
|
44
|
+
}
|
45
|
+
}
|
46
|
+
|
47
|
+
@media (max-width: 767px) {
|
48
|
+
#profile-main .pm-body {
|
49
|
+
padding-left: 0;
|
50
|
+
}
|
51
|
+
}
|
52
|
+
|
53
|
+
#profile-main .pm-body .tab-nav {
|
54
|
+
box-shadow: 0 0 5px 5px rgba(0, 0, 0, 0.03);
|
55
|
+
border-radius: 6px;
|
56
|
+
margin-bottom: 10px;
|
57
|
+
}
|
58
|
+
|
59
|
+
#profile-main .pm-body .tab-content {
|
60
|
+
box-shadow: 0 0 5px 5px rgba(0, 0, 0, 0.03);
|
61
|
+
border-radius: 6px;
|
62
|
+
overflow: hidden;
|
63
|
+
}
|
64
|
+
|
65
|
+
#profile-main .pm-overview {
|
66
|
+
box-shadow: none;
|
67
|
+
border-radius: 6px;
|
68
|
+
background: none;
|
69
|
+
}
|
70
|
+
|
71
|
+
#profile-main .pmo-pic, #profile-main .pmo-block{
|
72
|
+
box-shadow: 0 0 5px 5px rgba(0, 0, 0, 0.03);
|
73
|
+
border-radius: 6px;
|
74
|
+
overflow: hidden;
|
75
|
+
margin-bottom: 10px;
|
76
|
+
}
|
77
|
+
|
78
|
+
#profile-main .pmo-contact {
|
79
|
+
margin-top: 10px;
|
80
|
+
}
|
81
|
+
|
82
|
+
.btn, .lv-item, .btn-group, .t-view, .tvb-stats li,
|
83
|
+
.footer-text .text, .t-view:before, .actions > li > a:before,
|
84
|
+
.actions > a:before, .pagination > li > a, .pagination > li > span,
|
85
|
+
.listview [class*="lv-img"], .profile-pic > img, .form-control,
|
86
|
+
#header input[type="text"], #header .results, .img-circle, .dropdown.open .dropdown-menu,
|
87
|
+
.modal .modal-content, .profile-view .pv-header > .pv-main, .pt-inner .pti-header, .ptih-title {
|
88
|
+
border-radius: 6px !Important;
|
89
|
+
}
|
90
|
+
|
91
|
+
.pagination > li > a, .pagination > li > span {
|
92
|
+
border: 0px;
|
93
|
+
width: 36px;
|
94
|
+
height: 35px;
|
95
|
+
line-height: 34px;
|
96
|
+
}
|
97
|
+
|
98
|
+
.form-control {
|
99
|
+
}
|
100
|
+
|
101
|
+
#loader {
|
102
|
+
top: 10px !Important;
|
103
|
+
left: 26px !Important;
|
104
|
+
}
|
105
|
+
|
106
|
+
.profile-pic > img {
|
107
|
+
border: 0px;
|
108
|
+
}
|
109
|
+
|
110
|
+
.profile-pic {
|
111
|
+
box-shadow: 0 0 5px 5px rgba(0, 0, 0, 0.03);
|
112
|
+
}
|
113
|
+
|
114
|
+
.results .card {
|
115
|
+
box-shadow: none;
|
116
|
+
}
|
117
|
+
|
118
|
+
.profile-view {
|
119
|
+
overflow: hidden;
|
120
|
+
}
|
121
|
+
|
Binary file
|
Binary file
|
@@ -1,38 +1,41 @@
|
|
1
|
-
|
1
|
+
-if serie.empty?
|
2
|
+
== empty_alert({ :title => "Sin datos suficientes", :message => "No hay suficientes datos para mostrar esta información."})
|
3
|
+
-else
|
4
|
+
.ct-chart.pie id="#{id}"
|
2
5
|
|
3
|
-
.table-responsive.chart-table
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
6
|
+
.table-responsive.chart-table
|
7
|
+
table.table.table-striped
|
8
|
+
tbody
|
9
|
+
tr
|
10
|
+
-for label in labels
|
11
|
+
th #{label}
|
12
|
+
tr
|
13
|
+
-for element in serie
|
14
|
+
td #{element}
|
15
|
+
tr
|
16
|
+
-total = [1,serie.reduce(:+)].max
|
17
|
+
-for element in serie
|
18
|
+
td #{(element.to_f*100/total).round(0)}%
|
16
19
|
|
17
|
-
javascript:
|
18
|
-
|
19
|
-
|
20
|
+
javascript:
|
21
|
+
var labels = #{{labels}};
|
22
|
+
var serie = #{{serie}};
|
20
23
|
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
24
|
+
new Chartist.Pie("##{id}", {
|
25
|
+
labels: labels,
|
26
|
+
series: serie
|
27
|
+
}, {
|
28
|
+
fullWidth: true,
|
29
|
+
showLabel: false,
|
30
|
+
height: '300px',
|
31
|
+
plugins: [
|
32
|
+
Chartist.plugins.legend()
|
33
|
+
]
|
34
|
+
}
|
35
|
+
);
|
33
36
|
|
34
|
-
css:
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
37
|
+
css:
|
38
|
+
.pie .ct-legend.ct-legend-inside {
|
39
|
+
position: absolute;
|
40
|
+
top: 60px;
|
41
|
+
}
|
@@ -46,7 +46,7 @@ a.btn.btn-float.bgm-blue.m-btn.waves-effect.waves-circle.waves-float data-toggle
|
|
46
46
|
|
47
47
|
javascript:
|
48
48
|
function editConstant(constant_id,kind,value) {
|
49
|
-
$('#edit-constant
|
49
|
+
$('#edit-constant .action').attr('action', '/constants/' + constant_id);
|
50
50
|
|
51
51
|
$('#edit-constant #edit_kind').val(kind);
|
52
52
|
$('#edit-constant #edit_value').val(value);
|
@@ -0,0 +1,51 @@
|
|
1
|
+
-user_configuration = authenticated(User).user_configurations.last
|
2
|
+
|
3
|
+
.container
|
4
|
+
.block-header
|
5
|
+
h2
|
6
|
+
| Configuración
|
7
|
+
|
8
|
+
.card
|
9
|
+
form.card-body.card-padding action="/user/configuration" method="POST" data-toggle="validator"
|
10
|
+
.row
|
11
|
+
.col-xs-2
|
12
|
+
.pull-right
|
13
|
+
h5.c-gray Tema
|
14
|
+
|
15
|
+
.col-xs-4
|
16
|
+
== select_input({ :name => "css", :elements => [{ :text => "Default", :value => nil}, { :text => "Wieldy", :value => 'wieldy'}], :placeholder => "" , :chosen => user_configuration.nil?? nil : user_configuration.css })
|
17
|
+
|
18
|
+
.col-xs-6
|
19
|
+
|
20
|
+
.row
|
21
|
+
.col-xs-2
|
22
|
+
.pull-right
|
23
|
+
h5.c-gray Fuentes
|
24
|
+
|
25
|
+
.col-xs-4
|
26
|
+
-fonts = ['Roboto', 'Concert One','Lato','Montserrat', 'Nunito', 'Open Sans', 'Oswald', 'PT Sans', 'Quicksand', 'Raleway', 'Roboto', 'Rubik', 'Slabo 27px', 'Source Sans Pro', 'Ubuntu' ]
|
27
|
+
== select_input({ :name => "fonts", :elements => [{ :text => "Default", :value => nil} ] + fonts.collect { |font| { :text => font, :value => font } }, :placeholder => "" , :chosen => user_configuration.nil?? nil : user_configuration.fonts })
|
28
|
+
|
29
|
+
.col-xs-6
|
30
|
+
|
31
|
+
.row
|
32
|
+
.col-xs-2
|
33
|
+
.pull-right
|
34
|
+
h5.c-gray Darkmode
|
35
|
+
|
36
|
+
.col-xs-4
|
37
|
+
== radio_input({ :name => "dark_mode", :elements => [ { :name => "Deshabilitado", :value => 'disable'},{ :name => "Siempre", :value => 'always'},{ :name => "Habilitado", :value => 'enable'}], :filters => { 'dark_mode' => user_configuration.nil?? 'enable' : user_configuration.dark_mode }})
|
38
|
+
|
39
|
+
.col-xs-6
|
40
|
+
|
41
|
+
.footer-btn
|
42
|
+
button.btn.btn-float.bgm-green.m-btn.waves-effect.waves-circle.waves-float type="submit"
|
43
|
+
i.zmdi.zmdi-floppy
|
44
|
+
.footer-text
|
45
|
+
button.text.btn.bgm-white.c-gray type="submit" Guardar
|
46
|
+
|
47
|
+
css:
|
48
|
+
.radio-inline {
|
49
|
+
display: block;
|
50
|
+
margin-left: 0px !important;
|
51
|
+
}
|
@@ -0,0 +1,21 @@
|
|
1
|
+
link rel="preconnect" href="https://fonts.gstatic.com"
|
2
|
+
|
3
|
+
/https://fonts.google.com/specimen/Quicksand?selection.family=Concert+One|Lato:ital,wght@0,100;0,300;0,400;0,700;1,100;1,300;1,400;1,700|Montserrat:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;1,100;1,200;1,300;1,400;1,500;1,600;1,700|Nunito:ital,wght@0,200;0,300;0,400;0,600;0,700;1,200;1,300;1,400;1,600;1,700|Open+Sans:ital,wght@0,300;0,400;0,600;0,700;1,300;1,400;1,600;1,700|Oswald:wght@200;300;400;500;600;700|PT+Sans:ital,wght@0,400;0,700;1,400;1,700|Quicksand:wght@300;400;500;600;700|Raleway:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;1,100;1,200;1,300;1,400;1,500;1,600;1,700|Roboto:wght@100;400;500;700|Rubik:ital,wght@0,300;0,400;0,500;0,600;0,700;1,300;1,400;1,500;1,600;1,700|Slabo+27px|Source+Sans+Pro:ital,wght@0,200;0,300;0,400;0,600;0,700;1,200;1,300;1,400;1,600;1,700|Ubuntu:ital,wght@0,300;0,400;0,500;0,700;1,300;1,400;1,500;1,700&sidebar.open=true
|
4
|
+
|
5
|
+
link href="https://fonts.googleapis.com/css2?family=Concert+One&family=Lato:ital,wght@0,100;0,300;0,400;0,700;1,100;1,300;1,400;1,700&family=Montserrat:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;1,100;1,200;1,300;1,400;1,500;1,600;1,700&family=Nunito:ital,wght@0,200;0,300;0,400;0,600;0,700;1,200;1,300;1,400;1,600;1,700&family=Open+Sans:ital,wght@0,300;0,400;0,600;0,700;1,300;1,400;1,600;1,700&family=Oswald:wght@200;300;400;500;600;700&family=PT+Sans:ital,wght@0,400;0,700;1,400;1,700&family=Quicksand:wght@300;400;500;600;700&family=Raleway:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;1,100;1,200;1,300;1,400;1,500;1,600;1,700&family=Roboto:wght@100;400;500;700&family=Rubik:ital,wght@0,300;0,400;0,500;0,600;0,700;1,300;1,400;1,500;1,600;1,700&family=Slabo+27px&family=Source+Sans+Pro:ital,wght@0,200;0,300;0,400;0,600;0,700;1,200;1,300;1,400;1,600;1,700&family=Ubuntu:ital,wght@0,300;0,400;0,500;0,700;1,300;1,400;1,500;1,700&display=swap" rel="stylesheet"
|
6
|
+
|
7
|
+
-user_configuration = authenticated(User).user_configurations.last
|
8
|
+
-unless user_configuration.nil?
|
9
|
+
|
10
|
+
-unless user_configuration.css.blank?
|
11
|
+
link href="/sinatra-hexacta/css/#{user_configuration.css}.css?version=#{settings.version}" rel="stylesheet"
|
12
|
+
|
13
|
+
-unless user_configuration.fonts.blank?
|
14
|
+
css:
|
15
|
+
body {
|
16
|
+
font-family: "#{user_configuration.fonts}", sans-serif !important;
|
17
|
+
}
|
18
|
+
|
19
|
+
-if ((user_configuration.dark_mode == 'enable') && Time.now.hour > 16) || user_configuration.dark_mode == 'always'
|
20
|
+
link href="/sinatra-hexacta/css/darkmode.css?version=#{settings.version}" rel="stylesheet"
|
21
|
+
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: sinatra-hexacta
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.1
|
4
|
+
version: 1.2.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Marco Zanger
|
@@ -90,6 +90,7 @@ files:
|
|
90
90
|
- lib/sinatra/handlers/params.rb
|
91
91
|
- lib/sinatra/handlers/processes.rb
|
92
92
|
- lib/sinatra/handlers/reports.rb
|
93
|
+
- lib/sinatra/handlers/user_configurations.rb
|
93
94
|
- lib/sinatra/helpers/alerts.rb
|
94
95
|
- lib/sinatra/helpers/cas.rb
|
95
96
|
- lib/sinatra/helpers/charts.rb
|
@@ -99,10 +100,13 @@ files:
|
|
99
100
|
- lib/sinatra/helpers/menu.rb
|
100
101
|
- lib/sinatra/helpers/reports.rb
|
101
102
|
- lib/sinatra/helpers/schedule.rb
|
103
|
+
- lib/sinatra/helpers/user_configurations.rb
|
102
104
|
- lib/sinatra/hexacta.rb
|
103
105
|
- lib/sinatra/public/css/app.min.1.css
|
104
106
|
- lib/sinatra/public/css/app.min.2.css
|
107
|
+
- lib/sinatra/public/css/darkmode.css
|
105
108
|
- lib/sinatra/public/css/shell.css
|
109
|
+
- lib/sinatra/public/css/wieldy.css
|
106
110
|
- lib/sinatra/public/fonts/montserrat/Montserrat-Black.otf
|
107
111
|
- lib/sinatra/public/fonts/montserrat/Montserrat-ExtraLight.otf
|
108
112
|
- lib/sinatra/public/fonts/montserrat/Montserrat-Light.otf
|
@@ -127,10 +131,11 @@ files:
|
|
127
131
|
- lib/sinatra/public/fonts/roboto/Roboto-Thin-webfont.svg
|
128
132
|
- lib/sinatra/public/fonts/roboto/Roboto-Thin-webfont.ttf
|
129
133
|
- lib/sinatra/public/fonts/roboto/Roboto-Thin-webfont.woff
|
130
|
-
- lib/sinatra/public/img/finder.
|
134
|
+
- lib/sinatra/public/img/finder.png
|
131
135
|
- lib/sinatra/public/img/noimage.jpg
|
132
136
|
- lib/sinatra/public/img/select.png
|
133
137
|
- lib/sinatra/public/img/select@2x.png
|
138
|
+
- lib/sinatra/public/img/teams.png
|
134
139
|
- lib/sinatra/public/js/app.js
|
135
140
|
- lib/sinatra/public/js/finder.js
|
136
141
|
- lib/sinatra/public/js/process.js
|
@@ -219,6 +224,8 @@ files:
|
|
219
224
|
- lib/sinatra/views/reports/pick_dates.slim
|
220
225
|
- lib/sinatra/views/reports/pick_month.slim
|
221
226
|
- lib/sinatra/views/reports/pick_year.slim
|
227
|
+
- lib/sinatra/views/user_configurations/edit.slim
|
228
|
+
- lib/sinatra/views/user_configurations/include.slim
|
222
229
|
homepage: https://rubygems.org/gems/sinatra-hexacta
|
223
230
|
licenses:
|
224
231
|
- MIT
|
Binary file
|