Commit 2852de91 authored by julien's avatar julien

Merge branch 'master' of gitlab.pagedmedia.org:tools/experiments

parents cc2a93f2 10404351
......@@ -3,7 +3,7 @@
#list-toc-generated{ list-style: none;}
#list-toc-generated .toc-element a::after{
content: "p. " target-counter(attr(href), page);
content: " p. " target-counter(attr(href), page);
float: right;
}
......@@ -18,11 +18,12 @@
/* target-text(attr(href), before) doesn't work for now, replace with counters (see below)*/
#list-toc-generated .toc-element a::before{
/* #list-toc-generated .toc-element a::before{
content: target-text(attr(href), before);
}
} */
/* counters */
#list-toc-generated{
counter-reset: counterTocLevel1;
}
......@@ -34,6 +35,7 @@
#list-toc-generated .toc-element-level-1::before{
content: counter(counterTocLevel1) ". ";
padding-right: 5px;
}
#list-toc-generated .toc-element-level-2{
......@@ -42,7 +44,42 @@
#list-toc-generated .toc-element-level-2::before{
content: counter(counterTocLevel1) ". " counter(counterTocLevel2) ". ";
padding-right: 5px;
}
/* leader() doesn't work for now, replace with the hack bellow */
/* #list-toc-generated .toc-element a::after{
content: leader('.') " p. " target-counter(attr(href), page);
float: right;
} */
/* hack for leaders */
#list-toc-generated{
overflow-x: hidden;
}
#list-toc-generated .toc-element::after{
content: ".................................................................................................................................................";
float: left;
width: 0;
padding-left: 5px;
letter-spacing: 2px;
}
#list-toc-generated .toc-element{
display: flex;
}
#list-toc-generated .toc-element a::after{
position: absolute;
right: 0;
background-color: white;
padding-left: 6px;
}
#list-toc-generated .toc-element a{
right: 0;
}
}
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment