Post by Virgil Sovereign on Feb 10, 2013 5:03:38 GMT -8
|VSpoiler v1.0.0 |
Author: Virgil Sovereign
Plugin: VSpoiler v1.0.0 Release - VSpoiler.pbp (3.54 KB)
Keys Used: None
|VSpoiler is an alternative to Todge's Spoiler Tags, providing a different set of features and circumventing certain plugin compatibility issues. It is open-source and fully editable. Styles associated with the plugin are contained in its 'Build' interface and hence some familiarity with CSS and Proboards' plugin builder is required for full configurability. Some users may find 'Spoiler Tags' to be a more user-friendly option.|
The plugin adds a button to the WYSIWYG editor (and if present, the augmented Quick Reply) that inserts a [spoìler] block in BBCode mode and spoiler container in Visual mode. When posted, the contents of a spoiler block are hidden until a user expressly chooses to show them (see screenshots).
The plugin supports two configurable options in its configuration section:
Additionally, the editor style (for the Visual mode of the WYSIWYG editor) and display style (for spoilers as displayed in posts, etc.) are configurable using the style components in the 'Build' interface for the plugin.
Fig. 1 - An editor button allows for simple insertion of spoilers in both editor modes. Visual mode is shown here, with the default 'insert' resource (packaged with the plugin) used as a button graphic. The simplest way to insert a spoiler is to select the desired content and click the button. This will wrap the content in a spoiler block without need of a dialog.
Incidentally, don't be alarmed by the lack of a smiley button. We have a custom smiley system on my home board.
Fig. 2 - Spoiler blocks appear in their 'opened' state in the editor, with a look and feel defined by the editor stylesheet in the 'Build' section of the plugin. The default L&F is shown here.
Fig. 3 - The editor is shown in BBCode mode, where spoiler blocks are represented by [spoìler] tags. If nothing is selected when the 'Insert Spoiler' button is clicked, a standard modeless dialog is opened to obtain the spoiler contents. The spoiler is inserted at the caret (cursor) location.
Fig. 4 - In display modes, spoiler blocks appear closed by default but can opened by clicking on them. Opened spoiler blocks can be closed with a second click. The opened and closed spoiler blocks (including labels, etc.) have a look and feel defined by the display stylesheet in the 'Build' section of the plugin. The default L&F is shown here.
Fig. 5 - The plugin settings (all two of them ) are fully documented.
Fig. 6 - The editor stylesheet and display stylesheet are defined inline in the global header component of the plugin. Developers with knowledge of CSS can tweak the look and feel to their heart's content.
Bugs and Feedback:
|This plugin is marked 'release' since it is relatively simple and has been tested in several configurations. Nevertheless, if problems do occur, please notify me in this thread and I will do my best to resolve any issues promptly.|
I may also consider certain feature requests if they are reasonable and won't bulk up the code too much.
Aside from that, happy spoiling!