swedbank-pay-design-guide-jekyll-theme 1.10.3 → 1.11.0

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
  SHA256:
3
- metadata.gz: 107fe32dcdd6919798c50bc86a8933442abadabf1120a24b6dfbbcf634e427b3
4
- data.tar.gz: 0f1c6521f1eded78dfef148a0f17537c2cacdcadb2eb7a344060fac494257a51
3
+ metadata.gz: c2ee6679ef278504784472157d6ba46c66eae68896a025b462d4828ce2d0c96b
4
+ data.tar.gz: 5eee87773c997ffab402e64301405fd01f72c6f82470d25165604c1750ea696f
5
5
  SHA512:
6
- metadata.gz: 6aaac38681e036d6e1a3db0e0919a02cf89f47d3db876a85d67142219a44fd129698a4f69ff9ee63d6b13798248ea185ba4df8e0bb67429f2f50a1a345aa6522
7
- data.tar.gz: 3dc72e03582095cb5ea5721bf1b63d63a1827f51282623035124eb875cfd4ca23a0d89a889a7186a6000b5317b1bd8e7a80cf777ef5c69b54a4ad183e4926dea
6
+ metadata.gz: 5d07c2b3f9bbc47ee9a838bb2235bba35876f71cdd1b32f9386b2e2ad4b1fe54a9281b360f9606d2b4c737058fc2993c062cdb715abe434509b96b965654f4f7
7
+ data.tar.gz: 965e9fc06d52e736f7a803d2fd4b140d1d2ed8a9b10f41f1ac3758b2449f72be0fb4b46b3a30d0ba4f78328563f947a5ae06e0485f0b96e71285d9ef14dcaa1b
data/lib/gem_version.rb CHANGED
@@ -4,7 +4,7 @@ module Gem
4
4
  # Gem Specification
5
5
  class Specification
6
6
  def self.gem_version
7
- '1.10.3'
7
+ '1.11.0'
8
8
  end
9
9
  end
10
10
  end
data/lib/sidebar_page.rb CHANGED
@@ -31,6 +31,7 @@ module SwedbankPay
31
31
  @order = menu_order(jekyll_page)
32
32
  @children = SidebarPageCollection.new(self)
33
33
  @card_overview = jekyll_page['card_overview'].nil? ? false : jekyll_page['card_overview']
34
+ @anchor_headings = jekyll_page['anchor_headings'].nil? ? true : jekyll_page['anchor_headings']
34
35
  end
35
36
 
36
37
  def active?(current, is_leaf: false)
@@ -155,6 +156,10 @@ module SwedbankPay
155
156
  @card_overview
156
157
  end
157
158
 
159
+ def anchor_headings?
160
+ @anchor_headings
161
+ end
162
+
158
163
  private
159
164
 
160
165
  def menu_order(jekyll_page)
@@ -60,7 +60,7 @@ module SwedbankPay
60
60
  headers = []
61
61
 
62
62
  # Don't include headers in the sidebar if we're on a card overview page.
63
- return headers if page.card_overview?
63
+ return headers if page.card_overview? || !page.anchor_headings?
64
64
 
65
65
  page.doc.xpath('//h2').each do |header|
66
66
  id = header['id']
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: swedbank-pay-design-guide-jekyll-theme
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.10.3
4
+ version: 1.11.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Swedbank Pay
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-04-22 00:00:00.000000000 Z
11
+ date: 2021-05-21 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: faraday