asciidoctor-reveal.js – matoken's blog https://matoken.org/blog Is there no plan B? Fri, 30 Jun 2023 14:50:42 +0000 ja hourly 1 https://wordpress.org/?v=6.9.4 https://matoken.org/blog/wp-content/uploads/2025/03/cropped-1865f695c4eecc844385acef2f078255036adccd42c254580ea3844543ab56d9-32x32.jpeg asciidoctor-reveal.js – matoken's blog https://matoken.org/blog 32 32 asciidoctor-reveal.js v5.0.1 の新機能いくつか https://matoken.org/blog/2023/06/30/some-new-features-in-asciidoctor-reveal-js-v5-0-1/ https://matoken.org/blog/2023/06/30/some-new-features-in-asciidoctor-reveal-js-v5-0-1/#respond Fri, 30 Jun 2023 14:50:40 +0000 https://matoken.org/blog/?p=3909

ここしばらくスライド作成に使っているAsciidoctor のReveal.js コンバーターのasciidoctor-reveal.js が久々のメジャーアップデートでv5.0.1 がリリースされました.

新機能をいくつか試してみました.

以下の新機能を試しました.

  • Auto-Animate
  • search plugin
  • favicon

Auto-Animate

静的なpdfや画像にしたときにページが増えるので自分はあまり使わない機能ですがよく見かけるので一応.

Add support for the Auto-Animate feature (#439)

以下のあたりが参考になります.

[%auto-animate]
=== cats emoji

[data-id=foo]
* 😺
* 🐈

[%auto-animate]
=== cats emoji+ascii

[data-id=foo]
* 😺
* 🐈
* (ΦωΦ)
* (=^・・^=)
アニメーション中のスクリーンショット

adoc reveraljs autoanimate

以下のIssue によるとsource code block でも動作するようですが,手元ではうまく行っていません.

search plugin

スライド内で検索ができるプラグインです.

  • Add support for the built-in search plugin (#441)** You can enable this plugin using :revealjs_plugin_search: enabled.

既定値では無効になっているのでスライドのヘッダ部分に以下を書いて有効にします.

:revealjs_plugin_search: enable

生成されたhtml スライをを開いた状態で ctrl + shift + f で模擬上に検索ボックスが出てきて検索できます.

adoc reveraljs search

favicon

favicon が使えるようになりました.

Add favicon to HTML if its attribute is present in AsciiDoc

ヘッダ部分で以下のようにfavicon を設定します.:favicon には :imagesdir: は効かないようです.

:favicon: resources/favicon.ico

adoc reveraljs favicon

環境

$ asciidoctor-revealjs-linux --version
Asciidoctor reveal.js 5.0.1 using Asciidoctor.js 2.2.6 (Asciidoctor 2.0.17) [https://asciidoctor.org]
Runtime Environment (node v12.13.1 on linux)
CLI version 3.2.0
]]>
https://matoken.org/blog/2023/06/30/some-new-features-in-asciidoctor-reveal-js-v5-0-1/feed/ 0