Skip to content

Transparent background of png image in header is rendered with a white background #345

Answered by yhatt
jweickm asked this question in Q&A
Discussion options

You must be logged in to vote

Marp's default theme is based on GitHub's Markdown style, and its images always have a constant background color.

For getting backward compatibility of visibility with the slide made by classic Marp app, we are keeping this implicit background color over 6 years (when using regular color scheme). If you want, you can tweak the style of <img> elements to make image's background transparency.

<style>
  img {
    background-color: transparent;
  }
</style>

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@jweickm
Comment options

Answer selected by jweickm
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants