yihui / xaringan

Presentation Ninja 幻灯忍者 · 写轮眼
https://slides.yihui.org/xaringan/
Other
1.49k stars 280 forks source link

Title's position #95

Closed Livia14 closed 6 years ago

Livia14 commented 6 years ago

Hello! I'd like to insert my tittle before the regular spot (class: left, top), in the beginning of the slide, without any margin.

Am I allowed to do this in the xaringan presentation template without change the CSS specifications? If so, may you please tell me which would be the best way to do this?

Thanks :)

yihui commented 6 years ago

See ?xaringan::moon_reader, disable the default title slide (use the seal option), and provide your own title side.

For future questions, please do me a favor to ask on StackOverflow instead. Thanks!

gadenbuie commented 6 years ago

Hi @Livia14, we just added titleSlideClass as an option to the nature argument of moon_reader that allows you to make this change to the title slide classes from your YAML header.

To achieve your example you can now add the following to the YAML of your slides:

output:
  xaringan::moon_reader:
    nature:
      titleSlideClass: [top, left]

To remove the margin, you would still need a custom CSS file to remove the margin from the .title-slide class.

.title-slide {
  margin: 0
}