DokuWiki Wrap Plugin の使い方
特定のコンテンツに対し、クラスを指定しつつ div タグや span タグでラップしてくれるプラグイン。
https://www.dokuwiki.org/plugin:wrap
- <WRPA class-A class-B></WRAP> は <div class="wrap_class_A wrap_class_B"></div> へ
- <wrap class-A class-B></wrap> は <span class="wrap_class_A wrap_class_B"></span> へ
それぞれ変換される.
上述の wrap_ という クラスのプレフィクスを削除したい場合は、管理画面のサイト設定から指定クラスの場合はプレフィクスを付けない設定が可能.
コード
<WRAP row> <WRAP col-sm-6> Sample Text Left </WRAP> <WRAP col-sm-6> Sample Text Right </WRAP> </WRAP>
実装1
Sample Text Left
Sample Text Right
実装2
<WRAP> のネストも可能な様だが、以下のケースの場合は上手く行かず.右に寄ってしまう.
<html><style>
h2.page-header {
font-weight: 600; font-size: 2.4rem; position: relative; padding: 10px 0 10px 16px; margin-top: 3rem !important; margin-bottom: 2rem !important;
}
h2:before {
content: ""; position: absolute; top: 0; left: 0; width: 6px; height: 100%; background: #ccc;
}
div#disqus__thread {
width: 100% !important;
}
</style></html>