diff --git a/dist/js/editormd.js b/dist/js/editormd.js
index b2dfae6..811d4ff 100644
--- a/dist/js/editormd.js
+++ b/dist/js/editormd.js
@@ -1402,17 +1402,24 @@
var text = toc[i].text;
var level = toc[i].level;
- if (level < startLevel) { continue; }
+ if (level < startLevel) {
+ continue;
+ }
- if (level > lastLevel) {
+ if (level > lastLevel)
+ {
html += "";
- } else if (level < lastLevel) {
+ }
+ else if (level < lastLevel)
+ {
html += (new Array(lastLevel - level + 2)).join("");
- } else {
+ }
+ else
+ {
html += "";
}
- html += "
" + text + "";
+ html += "- " + text + "
";
lastLevel = level;
}
diff --git a/src/js/editormd.js b/src/js/editormd.js
index 3c66750..f65eec6 100644
--- a/src/js/editormd.js
+++ b/src/js/editormd.js
@@ -1391,17 +1391,24 @@
var text = toc[i].text;
var level = toc[i].level;
- if (level < startLevel) { continue; }
+ if (level < startLevel) {
+ continue;
+ }
- if (level > lastLevel) {
+ if (level > lastLevel)
+ {
html += "";
- } else if (level < lastLevel) {
+ }
+ else if (level < lastLevel)
+ {
html += (new Array(lastLevel - level + 2)).join("
");
- } else {
+ }
+ else
+ {
html += "
";
}
- html += "" + text + "