navigator 5.5.0 → 6.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- checksums.yaml.gz.sig +0 -0
- data.tar.gz.sig +0 -0
- data/lib/navigator/identity.rb +1 -1
- data/lib/navigator/menu.rb +31 -9
- metadata +6 -6
- metadata.gz.sig +0 -0
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 6ee02c41b532e95fefe52fb97b3cf417280a700b11676c5c1de437b3db5e9a47
|
4
|
+
data.tar.gz: 95a01b5614e1b220f9f90d3841f4b92706230fde8a925542ccc19ff01eea1528
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e94df980f74d11a7519d8c36b4a23b840a57d2473cae43213fd028f1748a3598545d5f2b2e39aea2dca0da60de830adf74b3fc775e2773ae17aca38a5f213f42
|
7
|
+
data.tar.gz: 7bd58c0e413a8f27b6af5391c573458f49a8b6a8c878e4fee3f8e0ed140fc0df5ae98c2d2c47e9b98ea309e5098c31197d338b6c44d227100d6df2c9549f841b
|
checksums.yaml.gz.sig
CHANGED
Binary file
|
data.tar.gz.sig
CHANGED
Binary file
|
data/lib/navigator/identity.rb
CHANGED
data/lib/navigator/menu.rb
CHANGED
@@ -3,11 +3,33 @@
|
|
3
3
|
module Navigator
|
4
4
|
# Renders a HTML menu.
|
5
5
|
class Menu
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
6
|
+
ALLOWED_ELEMENTS = /
|
7
|
+
^(
|
8
|
+
div|
|
9
|
+
section|
|
10
|
+
header|
|
11
|
+
h[1-6]|
|
12
|
+
nav|
|
13
|
+
ul|
|
14
|
+
li|
|
15
|
+
a|
|
16
|
+
img|
|
17
|
+
b|
|
18
|
+
em|
|
19
|
+
s|
|
20
|
+
small|
|
21
|
+
span|
|
22
|
+
strong|
|
23
|
+
sub|
|
24
|
+
sup|
|
25
|
+
form|
|
26
|
+
label|
|
27
|
+
select|
|
28
|
+
option|
|
29
|
+
input|
|
30
|
+
button
|
31
|
+
)$
|
32
|
+
/x
|
11
33
|
|
12
34
|
def initialize template,
|
13
35
|
tag: "ul",
|
@@ -62,11 +84,11 @@ module Navigator
|
|
62
84
|
end
|
63
85
|
end
|
64
86
|
|
65
|
-
def method_missing name, *
|
87
|
+
def method_missing name, *positionals, **keywords, &block
|
66
88
|
if respond_to_missing? name
|
67
|
-
add(name, *
|
89
|
+
add(name, *positionals, **keywords, &block)
|
68
90
|
else
|
69
|
-
template.public_send(name, *
|
91
|
+
template.public_send(name, *positionals, **keywords) || super
|
70
92
|
end
|
71
93
|
end
|
72
94
|
|
@@ -79,7 +101,7 @@ module Navigator
|
|
79
101
|
attr_accessor :template, :tag, :menu_activator, :items
|
80
102
|
|
81
103
|
def respond_to_missing? name, include_private = false
|
82
|
-
|
104
|
+
ALLOWED_ELEMENTS.match?(name) || super
|
83
105
|
end
|
84
106
|
|
85
107
|
def activate_item_attributes! attributes, url, activator
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: navigator
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version:
|
4
|
+
version: 6.0.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Brooke Kuhlmann
|
@@ -28,7 +28,7 @@ cert_chain:
|
|
28
28
|
2XV8FRa7/JimI07sPLC13eLY3xd/aYTi85Z782KIA4j0G8XEEWAX0ouBhlXPocZv
|
29
29
|
QWc=
|
30
30
|
-----END CERTIFICATE-----
|
31
|
-
date: 2020-12-
|
31
|
+
date: 2020-12-30 00:00:00.000000000 Z
|
32
32
|
dependencies:
|
33
33
|
- !ruby/object:Gem::Dependency
|
34
34
|
name: rails
|
@@ -50,14 +50,14 @@ dependencies:
|
|
50
50
|
requirements:
|
51
51
|
- - "~>"
|
52
52
|
- !ruby/object:Gem::Version
|
53
|
-
version: '
|
53
|
+
version: '8.0'
|
54
54
|
type: :runtime
|
55
55
|
prerelease: false
|
56
56
|
version_requirements: !ruby/object:Gem::Requirement
|
57
57
|
requirements:
|
58
58
|
- - "~>"
|
59
59
|
- !ruby/object:Gem::Version
|
60
|
-
version: '
|
60
|
+
version: '8.0'
|
61
61
|
description:
|
62
62
|
email:
|
63
63
|
- brooke@alchemists.io
|
@@ -92,14 +92,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
92
92
|
requirements:
|
93
93
|
- - "~>"
|
94
94
|
- !ruby/object:Gem::Version
|
95
|
-
version: '
|
95
|
+
version: '3.0'
|
96
96
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
97
97
|
requirements:
|
98
98
|
- - ">="
|
99
99
|
- !ruby/object:Gem::Version
|
100
100
|
version: '0'
|
101
101
|
requirements: []
|
102
|
-
rubygems_version: 3.2.
|
102
|
+
rubygems_version: 3.2.3
|
103
103
|
signing_key:
|
104
104
|
specification_version: 4
|
105
105
|
summary: Enhances Rails with a DSL for menu navigation.
|
metadata.gz.sig
CHANGED
Binary file
|