Closed Pierre9344 closed 1 year ago
That would be pretty nice! Right now, there isn't a great cross language way to add attributes to figure output, but I think if you're using knitr
you should be able to use out-extra
to do something like (haven't tried it, but worth giving a shot):
#| out-extra: "group='my-gallery'"
Thank for the pointer, the following works perfectly for me:
This was solved by #13 and this is now possible.
Example with several plot in a single chunk
---
title: Simple Lightbox Example
filters:
- lightbox
lightbox: auto
---
```{r}
#| fig-cap:
#| - Caption for first plot
#| - Caption for second plot
#| lightbox:
#| group: cars
#| description:
#| - This is the decription for first graph
#| - This is the decription for second graph
plot(mtcars)
plot(cars)
Hello,
Is it possible to indicate groups for graph generated by one or multiple r code chunk? The idea would be reproduce the behavior of the 3 lines bellow with an argument similar to '#| lightbox-group: "picture 1"'