touying-fn-wrapper
touying-fn-wrapper(fn, last-subslide: none, repetitions: none, advances-flow: false, ..args)(source)Wrapper for a function to make it can receive self as an argument.
It is useful when you want to use self to get current subslide index, like uncover and only functions.
Example: #let alternatives = touying-fn-wrapper.with(utils.alternatives)
fn : function
The function that will be called like (self: none, ..args) => { .. }.
last-subslide : int default: none
The max subslide count for the slide. Used by functions like uncover, only, and alternatives-match to determine the total number of subslides needed.
repetitions : function default: none
The repetitions for the function. It is useful for functions like alternatives with start: auto.
It accepts a (repetitions, args) and should return a (nextrepetitions, extra-args).
advances-flow : bool default: false
Whether this wrapper takes up the slide's pause flow, so that a following #pause continues after its last subslide rather than after the current one — true for item-by-item, which stands in for a run of pauses, and false for wrappers like uncover and only, which only animate their own body.
Returns: content