行内折叠模块
Rating: +33
这是行内折叠模块。

一个[[include :scp-wiki-cn:component:coltop show = 行内折叠| hide= | nohide = true ]]
酷酷的

WikiJump include 未展开: 跨站引用未启用(:scp-jp:component:colend-deep)

示例。

当然,[[include :scp-wiki-cn:component:coltop show = 你也可以让它包含换行| hide= | nohide = true ]]
它也可以换行。
就像这样

WikiJump include 未展开: 跨站引用未启用(:scp-jp:component:colend-deep)

它在需要权限验证的地方很有用,比如特殊收容措施中仅限相关人员查看的部分。

使用方法

在需要行内折叠处放置以下代码:

[[div class="inline-colmod"]]
折叠块前的文字
[[include component:inline-colmod show=点击前显示的文字 | content=点击后显示的文字]]
折叠块后的文字
[[/div]]

注意,[[include …]]必须独立成行。

特别的,如果你想要连续使用它

你需要在两个之间加上一些别的东西,比如~~~~或者四个@符号,也可以是下面这段代码,不同的方式产生的效果不同。
[[div style="height: .8em"]]
[[/div]]

如果你想要在特殊的位置换行

首先在代码顶部加入这段代码引入行内折叠模块的CSS,然后从下面选择你需要的方式:

[[div style="display: none;"]]
[[include :scp-wiki-cn:component:inline-colmod css-only=true]]
[[/div]]

在头部换行,[[include :scp-wiki-cn:component:coltop show = 看看效果,| hide= | nohide = true ]]

就像这样,

WikiJump include 未展开: 跨站引用未启用(:scp-jp:component:colend-deep)

在头部换行。

[[div class="inline-colmod"]]
在头部换行,
[[include :scp-wiki-cn:component:coltop show = 看看效果,| hide= | nohide = true ]]
@@@@
就像这样,
[[include :scp-wiki-cn:component:colend]]
在头部换行。
[[/div]]

在末尾换行,[[include :scp-wiki-cn:component:coltop show = 看看效果,| hide= | nohide = true ]]
就像这样

WikiJump include 未展开: 跨站引用未启用(:scp-jp:component:colend-deep)

在末尾换行。

[[div class="inline-colmod"]]
在末尾换行,
[[include :scp-wiki-cn:component:coltop show = 看看效果,| hide= | nohide = true ]]
就像这样
@@@@
[[include :scp-wiki-cn:component:colend]]
在末尾换行。
[[/div]]

一种我不知道该怎么形容的用法:

[[include :scp-wiki-cn:component:coltop show = 看看效果| hide= | nohide = true ]]
就像这样

WikiJump include 未展开: 跨站引用未启用(:scp-jp:component:colend-deep)

虽然但是,这显得很奇怪。

一种我不知道该怎么形容的用法:
[[div class="inline-colmod"]]
[[include :scp-wiki-cn:component:coltop show = 看看效果| hide= | nohide = true ]]
就像这样
[[include :scp-wiki-cn:component:colend]]
[[/div]]
虽然但是,这显得很奇怪。

技术细节

它基于component:colstyle并配以CSS的「display: inline」属性。

鸣谢

感谢hoah2333hoah2333将此组件整合为一个页面!

[[include :scp-wiki-cn:component:coltop show = {$show} | hide= | nohide = true ]]
{$content}

WikiJump include 未展开: 跨站引用未启用(:scp-jp:component:colend-deep)

页面版本:⁨0⁩, 最后编辑于: ⁨2021/8/21 23:10:49⁩ (⁨⁨1851⁩ 日前⁩), 现时评分: 33