simple_toc 0.2.0 → 0.2.1

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 6dbfde6098820f377ffd3935b4745596d551bce9
4
- data.tar.gz: 8428f488a7fe955a8e8475c9ffbdfe33cd0157ea
3
+ metadata.gz: 6009c6dff090bdd4c19fe1701caf569a7ad71b36
4
+ data.tar.gz: 57d30fd65a38b341d2029665b5ef4c294854b491
5
5
  SHA512:
6
- metadata.gz: e209fb5edf423b0c8333a6ad29fdbb80714bfa0069a8da6d41f789ec3d56fab04b94cdaec743c64ef660cbadf9b7832def15cfb8f11f33ae45505bdbb813992c
7
- data.tar.gz: 92d8f524624d53b76ea5af101e6448b24af539f804695cdb1c0b9a9955684eeb68a60bd65209a2abc2a7083ee4f8a0e29a754b1f8f2df702633b9c98fe4fe89f
6
+ metadata.gz: 90e978a86cd4abb3c472bf211343e09075d0f233de5369a90ce2f84b5a996c14624ce67e4ea7d40b5a2d4bf7fa932b19cc8f0cad4fec93e4187c1ca1c6f72347
7
+ data.tar.gz: 8037e66edee03343587f39b66137d45451c27f77d966206d3cd93b46de3aecb77244ce8c9807eee123d76a0ccb00a748890c3013a424add7d7561d8c6f70453d
data/README.md CHANGED
@@ -45,7 +45,7 @@ $(function() {
45
45
  ```
46
46
 
47
47
  ``` html
48
- <div class="#toc"></div>
48
+ <div id="toc"></div>
49
49
 
50
50
  <h2>hoge</h2>
51
51
  <h2>fuga</h2>
@@ -1,3 +1,3 @@
1
1
  module SimpleToc
2
- VERSION = "0.2.0"
2
+ VERSION = "0.2.1"
3
3
  end
@@ -32,6 +32,9 @@
32
32
  var ul = $(plugin.settings.listType);
33
33
 
34
34
  headers.each(function(i, header) {
35
+ if (plugin.settings.headerText($h).length <= 0) {
36
+ continue;
37
+ }
35
38
  var $h = $(header);
36
39
  var anchorName = plugin.settings.anchorName(i, plugin.settings.prefix);
37
40
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: simple_toc
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.2.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - miraoto
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-02-14 00:00:00.000000000 Z
11
+ date: 2017-07-26 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: railties