문제

I love the combination of Slidify with the reveal.js framework.

That said, I can't figure out how to change the background to an image or color using slidify.

For reveal.js, I'd just do:

<section data-background="#007777">

as documented here

I modified the reveal.js slide layout to include the data-background argument as such:

<section class='{{slide.class}}' data-state='{{slide.ds}}' id='{{slide.id}}' data-background='{{slide.background}}'>

and call a new slide like this:

--- .background "#007777"

But no change in the background. Any ideas what I'm doing wrong here?

도움이 되었습니까?

해결책

Specify it as --- {background: "#007777"}.

The dot/hash syntax I use is a shortcut for commonly specified slide properties. So --- .myclass #myid would actually expand to --- {class: myclass, myid: id}. The long-form syntax is more flexible as you can specify any valid YAML after the --- including lists.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top