ggrossetie / asciidoctor-web-pdf

Convert AsciiDoc documents to PDF using web technologies
https://asciidoctor.org
MIT License
443 stars 90 forks source link

Dot leader (dotted line) does not show when the TOC is manually positioned (using `toc::` macro) #655

Open diguage opened 2 years ago

diguage commented 2 years ago

The error example

= This is a demo project for Asciidoctor Web PDF
:toc:
:toc-placement!:

[preface]
== Preface

* 作者: **[.big]#D瓜哥#**
* 博客: [.big]#https://www.diguage.com/["地瓜哥"博客网 · https://www.diguage.com/^]#

This is a preface.

toc::[]

<<<

:sectnums:

== Sect 1

. 这是一个列表。
. 这是一个列表。
. 这是一个列表。
. 这是一个列表。

== Sect 2

. 这是一个列表。
. 这是一个列表。
. 这是一个列表。
. 这是一个列表。

== Sect 3

. 这是一个列表。
. 这是一个列表。
. 这是一个列表。
. 这是一个列表。

== Sect 4

. 这是一个列表。
. 这是一个列表。
. 这是一个列表。

image

The OK example

I commented out two configuration items :toc-placement!: and toc::[], then it is OK.

= This is a demo project for Asciidoctor Web PDF
:toc:
// :toc-placement!:

[preface]
== Preface

* 作者: **[.big]#D瓜哥#**
* 博客: [.big]#https://www.diguage.com/["地瓜哥"博客网 · https://www.diguage.com/^]#

This is a preface.

// toc::[]

<<<

:sectnums:

== Sect 1

. 这是一个列表。
. 这是一个列表。
. 这是一个列表。
. 这是一个列表。

== Sect 2

. 这是一个列表。
. 这是一个列表。
. 这是一个列表。
. 这是一个列表。

== Sect 3

. 这是一个列表。
. 这是一个列表。
. 这是一个列表。
. 这是一个列表。

== Sect 4

. 这是一个列表。
. 这是一个列表。
. 这是一个列表。

image

ggrossetie commented 2 years ago

The following style might not apply correctly in this case:

https://github.com/Mogztter/asciidoctor-web-pdf/blob/0a27de7423f12fe1f8b5ff7bcb720b786fb63e5b/css/document.css#L236-L247

Not sure exactly why but feel free to submit a pull request if you find a solution.