Is it possible / feature request: Make fragment initially large then small. #11623
axiomtutor
started this conversation in
Feature Requests
Replies: 1 comment
-
This repo is for the editor integrations (VS code, positron, RStudio). Can you post future discussions/feature requests at https://github.com/quarto-dev/quarto-cli? Thanks. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
What I'm trying to do:
I'm trying to style my slides in a Quarto presentation, so that when text first appears in a fragment, it shows very large so that the audience can immediately and easily read the part that I want them to pay attention to. Afterward, I want the text to shrink, so that it's still visible, in case I need the audience to refer to it later. But the next text should appear and again be large. This way I can both direct the audience's eye to the stuff I'm currently discussing, while also allowing them to refer back to previous text if they need to.
What I've tried:
I tried using nested grow and shrink fragments, but these did not render in the ways that I wanted -- and besides, the scaling transformation gave everything a strange alignment.
I tried fiddling with the CSS by changing grow. Instead of scaling, I just had it set the font size large. Likewise I had shrink set the font size small. I know this won't do anything for non-text elements, but I think that's probably fine for my purposes.
But still the "grow" feature did not show the text as large when it initially reveals.
Here is my QMD:
And here is how I tried to fiddle with the CSS in
reveal.css
. I only edited the.fragment.visible
,.fragment.grow
,.fragment.grow.visible
,fragment.shrink
, andfragment.shrink.visible
classes.Sorry, I know that's kind of monstrous, but I thought leaving in all the rest of the default CSS would be convenient if anyone wanted to copy-paste exactly what I have in order to see what it's currently doing.
[Edit:]
The more I play with the more I wonder if this is actually a kind of bug?
In the docs for working with fragments, it says that you can apply fragments in the way that I am here, so that the effects apply one-at-a-time. https://quarto.org/docs/presentations/revealjs/advanced.html#nested-fragments
However, it seems like what I'm doing here does not show the first fragment style, and instead only shows the last fragment style.
Er ... as I think even more about it, I wonder if it's because both of the things I'm doing here are adjusting the style of the same property fo the style? Because both fragments adjust the font-size, could that mean that for some reason only one of them is being applied?
Never mind, I realized I had some bugs in my CSS and fixed it with this:
Now this seems to work for regular text in fragments. But it doesn't change the way that list items are revealed. Does anyone know how to give list item reveals their own style?
Beta Was this translation helpful? Give feedback.
All reactions