-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
bugfix: figure env messes up grid (#82)
* initial commit * WIP figure environment fix * Revert "WIP figure environment fix" This reverts commit d5583d1. * Tweak bug reprex to demo for Quarto team * Rwplace class injection with grid style injection * Add .page-columns.page-full to main * Demo of partial fix * Replace custom styles with custom class * Propogate Quarto layout classes back * Only apply layout to direct .cr-section parents * Force .cr-section full width * Adjust comment on JS code * Remove extraneous JS function * Remove extraneous ref to manual style string * Return captionsed examples to demo --------- Co-authored-by: James Goldie <[email protected]> Co-authored-by: James Goldie <[email protected]>
- Loading branch information
1 parent
f047262
commit 026d24f
Showing
6 changed files
with
90 additions
and
4 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,64 @@ | ||
--- | ||
title: Sticky Block Types | ||
format: | ||
closeread-html: | ||
code-tools: true | ||
toc: true | ||
keep-md: true | ||
--- | ||
|
||
Just about any type of element that can be included in a Quarto doc can be flagged as a sticky. This demo shows many examples. | ||
|
||
The current fix allows `.cr-section` to work, provided it's a "first level" child of the `main` content. For example: | ||
|
||
::::{.cr-section} | ||
|
||
This is an image that includes a caption. @cr-inline-working | ||
|
||
:::{#cr-inline-working} | ||
This works: ![a caption](trees.png) | ||
::: | ||
|
||
This does too! @cr-nocaption-working | ||
|
||
:::{#cr-nocaption-working} | ||
![](trees.png) | ||
::: | ||
|
||
Does this one, which has a caption but no content? @cr-caption-working | ||
|
||
:::{#cr-caption-working} | ||
![Look at this tree!](trees.png) | ||
::: | ||
|
||
:::: | ||
|
||
## This header becomes a section | ||
|
||
We've reimplemented `.column-screen` so that we can even make `.cr-section` work if you've used an `h2` (which puts parts of the doc inside a `section`): | ||
|
||
::::{.cr-section} | ||
|
||
This is an image that includes a caption. @cr-inline-working2 | ||
|
||
:::{#cr-inline-working2} | ||
This works: ![a caption](trees.png) | ||
::: | ||
|
||
This does too! @cr-nocaption-working2 | ||
|
||
:::{#cr-nocaption-working2} | ||
![](trees.png) | ||
::: | ||
|
||
Does this one, which has a caption but no content? @cr-caption-working2 | ||
|
||
:::{#cr-caption-working2} | ||
![Look at this tree!](trees.png) | ||
::: | ||
|
||
:::: | ||
|
||
## Another section | ||
|
||
{{< lipsum 1 >}} |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.