diff --git a/customize.dist/src/less2/include/markdown.less b/customize.dist/src/less2/include/markdown.less index a1735ae34..c95f83645 100644 --- a/customize.dist/src/less2/include/markdown.less +++ b/customize.dist/src/less2/include/markdown.less @@ -13,9 +13,13 @@ div.cp-md-toc { background: #f3f3f3; padding: 20px; - float: right; + //float: right; margin: 5px; margin-right: 0; + max-width: 100%; + min-width: 200px; + white-space: nowrap; + & > p { &.cp-md-toc-1 { margin-left: 0; @@ -36,6 +40,8 @@ margin-left: 125px; } margin: 0; + overflow-x: hidden; + text-overflow: ellipsis; } } } diff --git a/www/common/diffMarked.js b/www/common/diffMarked.js index 994e35e62..39df0d10e 100644 --- a/www/common/diffMarked.js +++ b/www/common/diffMarked.js @@ -45,8 +45,9 @@ define([ var a = h('a.cp-md-toc-link', { href: '#', 'data-href': obj.id, + title: obj.title }, obj.title); - content.push(h('p.cp-md-toc-'+level, a)); + content.push(h('p.cp-md-toc-'+level, ['• ', a])); }); return h('div.cp-md-toc', content).outerHTML; };