Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ordered lists are not aligned properly when exported to PDF #94

Open
theoctober19th opened this issue Jan 19, 2022 · 2 comments
Open

Ordered lists are not aligned properly when exported to PDF #94

theoctober19th opened this issue Jan 19, 2022 · 2 comments

Comments

@theoctober19th
Copy link

theoctober19th commented Jan 19, 2022

When building the docs using mkdocs-with-pdf, the ordered lists appear far left than where they are supposed to be.

Here is what my markdown file looks like:

When SFTech is being setup for the first time, there are three phases of setup that need to be completed.

1. Login with the default `admin` user and then create new password for it.
2. Set the following parameters for the system: 

    a. Impact Assessment Date  
    b. Compounding frequency to be used. (Compounding daily or compounding each interval)  
    c. Computaion model (Retrospective, Modified Retrospective or Prospective)  

These steps are described in detail in the sections that follow.

When viewed on browser, the alignment of ordered list is correct:
image

But when exported to PDF, the alignment of ordered list is not correct:
image

Here is my mkdocs.yml file:

site_name: SFTech Docs
site_url: https://sftechtepal.com/docs
site_description: The official documentation of SFTech
site_author: SFTech
copyright: Copyright © 2022 Supreme Fintech Private Limited
docs_dir: docs

nav:
  - Home: index.md
  - Setup: setup.md
  - Dashboard: dashboard.md
  - Authentication: authentication.md
  - Leases: leases.md
  - Reports: reports.md
  - Approvals: approvals.md
  - User Management: user_management.md


theme:
    name: material
    logo: assets/img/sft_logo_white.svg
    favicon: assets/img/favicon.ico
    font:
        text: Nunito
    palette:
      - scheme: default
        primary: deep orange
        toggle: 
            icon: material/brightness-4 
            name: Switch to dark mode
      - scheme: slate 
        primary: deep orange
        toggle:
          icon: material/brightness-7
          name: Switch to light mode
    features:
      - toc.integrate
      - navigation.top
      - search.suggest

markdown_extensions:
    - toc:
        permalink: "#"

plugins:
  - search
  - with-pdf

The following were used when this issue appeared:

mkdocs-with-pdf: 0.9.3
macOS Big Sur 11.6
@DanielFichtner
Copy link

DanielFichtner commented Jan 31, 2022

Encountering the same problem.

mkdocs: 1.2.3
mkdocs-material: 8.1.7
mkdocs-with-pdf: 0.9.3

Arch Linux

@DanielFichtner
Copy link

Fix:
add the ol to "content indent" in mkdocs_with_pdf/themes/material.scss in line 69

    &>ul,
    &>ol {
      margin-left: 1.5rem;
    }

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants