reveal.js 调整字体大小以适合幻灯片

reveal.js resize fonts to fit the slide

我正在尝试了解如何自动调整字体大小以适合我的幻灯片。 我正在使用来自 https://github.com/thehung111/remote-presentation-controller

我已经尝试添加到 /punlic/css/main.cc

@media screen and (max-width: 1024px), (max-height: 600px) {
    .reveal .slides {
        font-size: 0.82em;
    }
}

@media screen and (max-width: 700px), (max-height: 400px) {
    .reveal .slides {
        font-size: 0.66em;
    }
}

但是不行。 知道我需要做什么吗? 谢谢,

你可以随时尝试一下。

它看起来与您要实现的目标非常相似。

更改屏幕宽度进行测试。 样本: https://chunksnbits.github.io/jquery-quickfit/

安装: https://github.com/chunksnbits/jquery-quickfit