sinatra-hexacta 0.9.0 → 0.9.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/sinatra/extensions/menu.rb +2 -2
- data/lib/sinatra/public/css/app.min.1.css +16 -0
- data/lib/sinatra/views/menu/menu.slim +61 -35
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d79ff3433bcac2fb8f84b38f2847eb2807a481f952d7940e9015f703c189afd3
|
4
|
+
data.tar.gz: 5b14042aab9d75bf41cc2804f10e6df792f833c480de934ec14c0d03b9df22d3
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 60566a5a7826baa9993d1d5f4b61dc57cfde3a99ced5af08daa80d5436099ca74d1f8625c2f76007d5662f2278356a1f8e4de61d8de277fef15973b309e39dd3
|
7
|
+
data.tar.gz: 4b5263301f5e43d3541f252d404f02028565adf9728b01e96fb145040eea19e774201b42ca727402f618b08247cbadc7800a99867b12809be0e8d6f957ba7ef4
|
@@ -1,7 +1,7 @@
|
|
1
1
|
# encoding: utf-8
|
2
2
|
class MenuBuilder
|
3
3
|
|
4
|
-
def
|
4
|
+
def initialize
|
5
5
|
@elements = []
|
6
6
|
end
|
7
7
|
|
@@ -11,7 +11,7 @@ class MenuBuilder
|
|
11
11
|
end
|
12
12
|
|
13
13
|
def link(text,icon,link,target)
|
14
|
-
@elements << { :type => '
|
14
|
+
@elements << { :type => 'link' , :text => text, :icon => icon, :link => link, :target => target }
|
15
15
|
return self
|
16
16
|
end
|
17
17
|
|
@@ -13894,6 +13894,22 @@ fieldset[disabled] .btn-inverse:active {
|
|
13894
13894
|
bottom: 340px;
|
13895
13895
|
}
|
13896
13896
|
|
13897
|
+
.footer-text :nth-child(7), .footer-btn :nth-child(7) {
|
13898
|
+
bottom: 400px;
|
13899
|
+
}
|
13900
|
+
|
13901
|
+
.footer-text :nth-child(8), .footer-btn :nth-child(8) {
|
13902
|
+
bottom: 460px;
|
13903
|
+
}
|
13904
|
+
|
13905
|
+
.footer-text :nth-child(9), .footer-btn :nth-child(9) {
|
13906
|
+
bottom: 520px;
|
13907
|
+
}
|
13908
|
+
|
13909
|
+
.footer-text :nth-child(10), .footer-btn :nth-child(10) {
|
13910
|
+
bottom: 580px;
|
13911
|
+
}
|
13912
|
+
|
13897
13913
|
.footer-text .text {
|
13898
13914
|
position: fixed;
|
13899
13915
|
right: 100px;
|
@@ -1,42 +1,68 @@
|
|
1
|
-
.
|
2
|
-
.btn-
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
| #{item[:text]}
|
1
|
+
.footer-text
|
2
|
+
a.text.btn.bgm-white.c-gray onclick='toggle_menu()' Menu
|
3
|
+
|
4
|
+
.actions-menu.hidden
|
5
|
+
-for item in menu
|
6
|
+
-idx = menu.index(item) + 1
|
7
|
+
-if item[:type] == 'link'
|
8
|
+
a.text.btn.bgm-white.c-gray type="button" href="#{item[:link]}" target="#{item[:target]}" style="bottom:#{50+idx*45}px;animation-duration: #{(idx.to_f/10.0).round(2)}s" #{item[:text]}
|
9
|
+
-if item[:type] == 'modal'
|
10
|
+
a.text.btn.bgm-white.c-gray type="button" data-toggle="modal" data-target="#{item[:link]}" style="bottom:#{50+idx*45}px;animation-duration: #{(idx.to_f/10.0).round(2)}s" #{item[:text]}
|
11
|
+
|
12
|
+
.footer-btn
|
13
|
+
a.btn.btn-float.bgm-blue.m-btn.waves-effect.waves-circle.waves-float onclick='toggle_menu()'
|
14
|
+
i.zmdi.zmdi-menu
|
15
|
+
|
16
|
+
.actions-menu.hidden
|
17
|
+
-for item in menu
|
18
|
+
-idx = menu.index(item) + 1
|
19
|
+
-if item[:type] == 'link'
|
20
|
+
a.btn.btn-float.bgm-blue.m-btn.waves-effect.waves-circle.waves-float type="button" href="#{item[:link]}" target="#{item[:target]}" style="bottom:#{50+idx*45}px;animation-duration: #{(idx.to_f/10.0).round(2)}s"
|
21
|
+
i.zmdi class="zmdi-#{item[:icon]}"
|
22
|
+
|
23
|
+
-if item[:type] == 'modal'
|
24
|
+
a.btn.btn-float.bgm-blue.m-btn.waves-effect.waves-circle.waves-float type="button" data-toggle="modal" data-target="#{item[:link]}" style="bottom:#{50+idx*45}px;animation-duration: #{(idx.to_f/10.0).round(2)}s"
|
25
|
+
i.zmdi class="zmdi-#{item[:icon]}"
|
27
26
|
|
28
27
|
|
29
28
|
css:
|
30
|
-
.actions-menu {
|
31
|
-
|
29
|
+
.actions-menu .btn-float {
|
30
|
+
width: 40px;
|
31
|
+
height: 40px;
|
32
|
+
line-height : 30px !Important;
|
33
|
+
margin-right: 5px;
|
32
34
|
}
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
border-left: 1px solid #eee;
|
35
|
+
|
36
|
+
.actions-menu .btn-float i {
|
37
|
+
font-size: 17px;
|
37
38
|
}
|
38
39
|
|
39
|
-
.actions-menu
|
40
|
-
|
41
|
-
|
40
|
+
.actions-menu .text {
|
41
|
+
position: fixed;
|
42
|
+
right: 100px;
|
43
|
+
margin-bottom: 6px;
|
44
|
+
border-radius: 20px;
|
45
|
+
font-size: 8pt;
|
46
|
+
z-index: 9;
|
47
|
+
}
|
48
|
+
|
49
|
+
javascript:
|
50
|
+
function toggle_menu() {
|
51
|
+
if ($(".actions-menu.hidden")[0]) {
|
52
|
+
show_menu();
|
53
|
+
} else {
|
54
|
+
hide_menu();
|
55
|
+
}
|
56
|
+
}
|
57
|
+
function hide_menu() {
|
58
|
+
$(".actions-menu a" ).removeClass('animated fadeInUp')
|
59
|
+
$(".actions-menu a" ).addClass('animated fadeOutDown');
|
60
|
+
setTimeout(function(){
|
61
|
+
$(".actions-menu" ).addClass("hidden");
|
62
|
+
}, 300);
|
63
|
+
}
|
64
|
+
function show_menu() {
|
65
|
+
$(".actions-menu a" ).removeClass('animated fadeOutDown')
|
66
|
+
$(".actions-menu a" ).addClass('animated fadeInUp');
|
67
|
+
$(".actions-menu" ).removeClass("hidden");
|
42
68
|
}
|