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

Indented List breaks by #line-by-line #187

Open
JeffreyAnimal opened this issue Oct 23, 2024 · 3 comments
Open

Indented List breaks by #line-by-line #187

JeffreyAnimal opened this issue Oct 23, 2024 · 3 comments

Comments

@JeffreyAnimal
Copy link

Bug Report

Summary

Indentation of Lists break the #line-by-line function.

Code Example

#polylux-slide[
  - bullet point 1
  #line-by-line[
      - indent bullet point 1
      - indent bullet point2
      - indent bullet point 3
    ]
  - bullet point 2
  - bullet point 3
]

Expected Result

Uncovered indented Bullet Points to be Indented.

bug_expected

Actual Result

All Bullet Points are at the Same Level.

bug1
bug2
bug3

Environment

  • Operating System: Debian12
  • Typst: 0.11.1
  • Version: 0.3.1

Additional Information

Not shure if this is related or similar to Issues #128 or #162, therefore created this Issue.

@andreasKroepelin
Copy link
Owner

#line-by-line is a hack and will fail in many situations... Prefer using the more explicit variants.

@JeffreyAnimal
Copy link
Author

Alright thank you.

I now used the following Code instead to solve my Problem:

#polylux-slide[
  - bullet point 1
      #list-one-by-one(marker:[-])[
      indent bullet point 1][
      indent bullet point 2][
      indent bullet point 3]
  - bullet point 2
  - bullet point 3
]
``

@GabrielDTB
Copy link

Your first list wasn't properly indented because you didn't indent the line-by-line function.
Your second list was properly indented because you did indent the list-one-by-one function.

The first snippet works for me when indented like:

#polylux-slide[
  - bullet point 1
    #line-by-line[
      - indent bullet point 1
      - indent bullet point2
      - indent bullet point 3
    ]
  - bullet point 2
  - bullet point 3
]

The second snippet doesn't work for me if I don't indent the function:

#polylux-slide[
  - bullet point 1
  #list-one-by-one(marker:[-])[
    indent bullet point 1][
    indent bullet point 2][
    indent bullet point 3]
  - bullet point 2
  - bullet point 3
]```

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

3 participants