Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Image/figure directive align behaviour does not let text float / flow around it #1668

Open
anjackson opened this issue Nov 21, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@anjackson
Copy link

Description

Under Sphinx/Jupyter Book 1, using left or right alignment on an image or figure causes it to float so that text can flow around it. e.g. this source which comes out like this.

Using a simpler example:

```{image} https://github.com/rowanc1/pics/blob/main/grapes-wide.png?raw=true
:alt: Grapes on a vineyard
:width: 500px
:align: right
```
test

The current version of MystMD (v1.3.18) appears to generate markup that sets margins so the item pushes to the the right, but it does not float it.

Proposed solution

Use float for left/right alignment as under Sphinx rather than by setting margins.

Additional notes

❯ myst -v
v1.3.18
@anjackson anjackson added the bug Something isn't working label Nov 21, 2024
@choldgraf choldgraf changed the title Image/figure directive align behaviour inconsistent with Sphinx/JupyterBook 1 Image/figure directive align behaviour does not let text float / flow around it Nov 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant