Several built-in themes are supported auto-scaling for code blocks and math typesettings.
Too long code block will be scaled-down automatically. ------------>
Too long code block will be scaled-down automatically. ------------------------>
Too long code block will be scaled-down automatically. ------------------------------------------------>
<!--fit-->
in headings.## <!--fit--> Auto-fitting header (only for Marp Core)
Marp uses <section>
as the container of each slide. And others are same as styling for plain Markdown. The customized theme can use in Marp CLI and Marp for VS Code.
/* @theme your-theme */
@import 'default';
section {
/* Specify slide size */
width: 960px;
height: 720px;
}
h1 {
font-size: 30px;
color: #c33;
}
<style>
tag in Markdown will work in the context of theme CSS.
---
theme: default
---
<style>
section {
background: yellow;
}
</style>
Re-painted yellow background, ha-ha.
You can also add custom styling by class like
section.custom-class { ... }
.
Apply style through<!-- _class: custom-class -->
.
If you want one-shot styling for current page, you can use <style scoped>
.
<style scoped>
a {
color: green;
}
</style>
