Skip to content

logonoff/obsidian-inline-spoilers

Repository files navigation

Inline spoilers for Obsidian

Plugin version Minimum Obsidian version GitHub License GitHub Repo stars

This plugin adds support for inline spoilers in Obsidian using the || syntax.

Demo gif

Usage

To create an inline spoiler, wrap the text you want to hide in ||, or by performing the Inline spoilers: Create spoiler command. For example:

||This text will be hidden||

If you want to combine various formatting options, you can nest them, but make sure they are outside the spoiler:

**||This text will be hidden and bolded||**

*||This text will be hidden and italicized||*

To reveal or hide a spoiler, click on it. You may opt to always show all spoilers by enabling the Always show spoilers setting.

Theming

There are CSS variables and classes you can use to style spoilers to your liking. These can be used in a CSS snippet to override to customize the appearance of spoilers, without needing to modify the plugin.

Refer to the styles.css file for more details.

Bugs and feature requests

Please report any bugs or request features on the GitHub issues page. The plugin author is no longer an active Obsidian user, the best way to get a feature or bug fix implemented is to submit a pull request. Contributions are always welcome :)

Stars on GitHub are also appreciated!