charmbracelet / glamour

Stylesheet-based markdown rendering for your CLI apps 💇🏻‍♀️
MIT License
2.48k stars 181 forks source link

Code within quotes doesn't render #342

Open ainar-g opened 1 year ago

ainar-g commented 1 year ago

Hi, and thanks for the cool tool!

It seems like Glow cannot handle code blocks within blockquotes. For example, consider the following document:

```go
fmt.Println("normal code")
```

> ```go
> fmt.Println("code within quote")
> ```

1.  List.

2.  ```go
    fmt.Println("code within list")
    ```

3.  > Quote within list.

4.  > ```go
    > fmt.Println("code within quote within list")
    > ```

Consider the difference between how Dingus renders it and how Glow renders it:

Dingus Glow v1.4.1
![Screenshot at 2022-12-10 16-05-33](https://user-images.githubusercontent.com/4964986/206856692-f53039e0-2a6a-4c37-8c53-33f7303c6ec8.png) ![Screenshot at 2022-12-10 16-06-29](https://user-images.githubusercontent.com/4964986/206856689-fd47761f-0d27-43e0-81e2-3e97e11d4ef4.png)

Using Debian 11 with MATE Terminal v1.24.1. Setting XTERM to something like xterm-256color doesn't seem to matter.

meowgorithm commented 2 months ago

Transferring this to Glamour, which does the markdown rendering.