summaryrefslogtreecommitdiff
path: root/underlays/basewiki/directive/toggle.mdwn
diff options
context:
space:
mode:
authorWilliam Uther <willu@cse.unsw.edu.au>2008-09-11 17:04:23 -0400
committerJoey Hess <joey@kodama.kitenet.net>2008-09-11 17:05:19 -0400
commit4f0ac7fe59c196a602e07cc6c4abfc248999ec6b (patch)
tree725f523faeb8e8db0efd81be4024257799c93ef8 /underlays/basewiki/directive/toggle.mdwn
parent595b0359157d1f57ee5a87c63e665dfa1d2130ec (diff)
add underlay files for listdirectives
As was noted, 'listdirectives' didn't include the underlay files that make it really worthwhile. I've just gone through all the plugin documentation, modified it to remove installation information and renamed the files to match the directives rather than the plugins. This can now serve as useful underlay. I've only gone through plugins in the 'plugins' dir. I did not go through the 'contrib' dir.
Diffstat (limited to 'underlays/basewiki/directive/toggle.mdwn')
-rw-r--r--underlays/basewiki/directive/toggle.mdwn32
1 files changed, 32 insertions, 0 deletions
diff --git a/underlays/basewiki/directive/toggle.mdwn b/underlays/basewiki/directive/toggle.mdwn
new file mode 100644
index 000000000..f4602ba29
--- /dev/null
+++ b/underlays/basewiki/directive/toggle.mdwn
@@ -0,0 +1,32 @@
+The `toggle` and `toggleable` directives are supplied by the [[!iki plugins/toggle]] plugin.
+
+With these directives you can create links on pages that, when clicked, toggle
+display of other parts of the page.
+
+It uses javascript to accomplish this; browsers without javascript will
+always see the full page content.
+
+Example use:
+
+ \[[!toggle id="ipsum" text="show"]]
+
+ \[[!toggleable id="ipsum" text="""
+ Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do
+ eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim
+ ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut
+ aliquip ex ea commodo consequat.
+
+ [[!toggle id="ipsum" text="hide"]]
+ """]]
+
+Note that you can include wiki markup in the toggleable text,
+including even additional toggles, as shown in the above example.
+
+Also, the toggle and the togglable definitions do not need to be next to
+each other, but can be located anywhere on the page. There can also be
+mutiple toggles that all toggle a single togglable.
+
+The id has a default value of "default", so can be omitted in simple cases.
+
+If you'd like a toggleable to be displayed by default, and toggle to
+hidden, then pass a parameter "open=yes" when setting up the toggleable.