sibu 0.9.2 → 0.9.3
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: b5863fe5be538035f122d5bca9adf79b3003d14c
|
4
|
+
data.tar.gz: c54c068d10c247f59e1ff89993ce824421d9f8c6
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0f610a0d5e30ae5d3808bd3dace1aaad977cb12f0ad9dcca17cc538c87b38fda947476768dd517a062406ce48c21a7c23563d6ff16b7e260b85a183752ace900
|
7
|
+
data.tar.gz: a399ffcf3ddc03508e37a404ad5c934d506af3cd1c4ca4a61f7d52437a74b798dcc073b2ff0f262b0a3fba1898c460aa55d2677fdf88fb8adee6cbf676936224
|
@@ -139,14 +139,6 @@ module Sibu
|
|
139
139
|
content_tag(tag, capture(self, &block), opts)
|
140
140
|
end
|
141
141
|
|
142
|
-
def sections(id, tag, html_opts = {}, &block)
|
143
|
-
(@sb_entity.find_or_init(id)["elements"].map.with_index do |elt, i|
|
144
|
-
@sb_section = [id, elt["id"]]
|
145
|
-
opts = action_name != 'show' ? html_opts.merge({"data-sb-id" => @sb_section.join('|'), "data-sb-repeat" => true, "data-sb-entity" => @sb_entity == @site ? 'site' : 'page'}) : html_opts
|
146
|
-
content_tag(tag, capture(self, i, &block), opts)
|
147
|
-
end).join('').html_safe
|
148
|
-
end
|
149
|
-
|
150
142
|
def elts(id)
|
151
143
|
items = []
|
152
144
|
element_id = elt_id(id)
|
@@ -16,6 +16,9 @@ module Sibu
|
|
16
16
|
sections_list += Dir.glob(dir + "*.erb").map {|f| f.split('/').last}.
|
17
17
|
map {|f| f[1..-1].gsub('.html.erb', '')}.map {|f| {"id" => "sibu_template_#{f}", "category" => cat, "template" => f}}
|
18
18
|
end
|
19
|
+
if Rails.application.config.sibu[:sections_ordering]
|
20
|
+
sections_list = Rails.application.config.sibu[:sections_ordering].call(sections_list)
|
21
|
+
end
|
19
22
|
sections_list
|
20
23
|
end
|
21
24
|
end
|
@@ -2,10 +2,10 @@
|
|
2
2
|
<html>
|
3
3
|
<head>
|
4
4
|
<title><%= conf[:title] %></title>
|
5
|
-
<%= stylesheet_link_tag "#{conf[:stylesheet]}-edit", media: 'all' %>
|
6
5
|
<%= stylesheet_link_tag 'sibu/sibu', media: 'all' %>
|
7
|
-
<%=
|
6
|
+
<%= stylesheet_link_tag "#{conf[:stylesheet]}-edit", media: 'all' %>
|
8
7
|
<%= javascript_include_tag 'sibu/sibu' %>
|
8
|
+
<%= javascript_include_tag "#{conf[:javascript]}-edit" %>
|
9
9
|
<% if @site %>
|
10
10
|
<%= stylesheet_link_tag (conf[:custom_styles] ? @site.style_url : @site.site_template.path), media: "all" %>
|
11
11
|
<%= javascript_include_tag "#{@site.site_template.path}-core" %>
|
data/lib/sibu/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: sibu
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.9.
|
4
|
+
version: 0.9.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jean-Baptiste Vilain
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-10
|
11
|
+
date: 2019-11-10 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|