samuele-cozzi / obsidian-marp-slides

Create markdown-based Marp presentations in Obsidian
MIT License
74 stars 6 forks source link

Change slide size #153

Open simonla82 opened 3 months ago

simonla82 commented 3 months ago

In Marp I can change the slide size quite simply: https://marpit.marp.app/theme-css?id=slide-size

However, if I try to achieve the same in obsidian marp slides, using either the style property or using a scoped <style> block for each slide, it seems to have no effect.

Is is possible to modify the slide size in an easy way?

phifuh commented 3 months ago
  1. Go into settings and enable HTML
  2. ->
    <style>
    :root { 
      background-color: #f80;
      width: 960px;
      height:300px;
      } 
    </style>
simonla82 commented 2 months ago

Thanks for your reply. This indeed allows me to change the slide size. However, when I open the slide preview, the slide container still has the size 1280x720, which causes the slide to overflow the boundary, when I increase the slide size over that size.

image

image