touying-typ / touying

Touying is a powerful package for creating presentation slides in Typst.
https://touying-typ.github.io/
MIT License
795 stars 18 forks source link

uncover/only hides more content than it should #85

Closed karuboniru closed 1 month ago

karuboniru commented 1 month ago

Reproduce:

#import "@preview/touying:0.5.2": *
#import themes.simple: *

#show: simple-theme.with(aspect-ratio: "16-9")

#slide[
  - text #uncover("2-")[covered test] text
  - text
  - text
]

#slide[
  - text #only("2-")[covered test] text
  - text
  - text
]

The uncover or only seems to be applied to also the text in the following bullets.

OrangeX4 commented 1 month ago

Thanks for finding this bug, I'll try to fix it in the next release. Currently you can use callback-style uncover and only:

#slide(repeat: 2, self => [
  #let (uncover, only) = utils.methods(self)
  - text #uncover("2-")[covered test] text
  - text
  - text
])