Skip to content

Unable to provide lipgloss background on text highlighted by Chroma #124

Open
@noahgorstein

Description

@noahgorstein

I attempted to highlight some JSON using Chroma and seemed to be unable to highlight the background of the highlighted text using lipgloss.

Code roughly looked like:

buf := new(bytes.Buffer)
quick.Highlight(buf, prettyJSON.String(), "json", utils.GetTerminalColorSupport(), chromaStyle.Name)
fmt.Println(lipgloss.NewStyle().Background(lipgloss.Color("22")).Render(buf.String()))

Resulted in:

image

Using a hex color for the background also did not work.

I can definitely try and provide more info if needed.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions