Toggles

描述

You can use this block to hide and reveal content as needed. Create FAQ pages, hide spoilers in posts, or create simple accordion elements.

The block uses <details> and <summary> HTML elements and doesn’t require any additional JavaScript or CSS on the theme side.

屏幕截图

  • The block with no styles.
  • The block with custom styling.
  • Block Editor.

区块

该插件提供了 1 个区块.

  • Toggles An easy way to hide and reveal content.

常见问题

Want to change default styles?

You can add some basic styling with just a few lines of CSS. Example:

.wp-block-toggles {
    background: #fafafa;
    border: 1px solid #eaeaea;
    border-radius: 3px;
    margin: 1.5rem 0;
    padding: 0.5rem 1rem;
}

.wp-block-toggles summary {
    cursor: pointer;
}

Want to report a bug?

Create an issue at the Mamaduka/toggles repo.

评价

2025 年 1 月 23 日
The plugin is perfect. However, I would still like to be able to make a few design changes within the shortcode. But that’s complaining on a high level! And it works great with version 6.7.1!
2024 年 4 月 26 日
A wonderful, much needed block.It can be even better if you use the toggle-off / toggle-on icon, because everyone is used to such a switch on smartphones.And make the title styled like a link, for example blue and underlined (so that users understand that the title is clickable).
2023 年 8 月 11 日
A simple, clean solution for Toggles everything! It increases creativity in content design by 377%! No, really, simple does not mean boring! A basic tool to rethink design without installing bloated graphics plugins.I feel lucky I found it. Many thanks!
2023 年 3 月 4 日 1 回复
You know how you spend 3 days installing and uninstalling plugin after plugin trying to do the simplest task? Changing themes, chasing promises, getting befuddled, exhausted, frustrated and disappointed. Well that is my story with toggles until I found this gem. Looks great, works great, saves time and effort. Reliable and covers all the essential bases. Love it! 10 stars! Thank you!!!
2022 年 10 月 30 日 1 回复
Awesome plugin. I use it to add simple, minimalistic toggles that show/hide additional info on my site. Thank you!
阅读所有7条评价

贡献者及开发者

「Toggles」是开源软件。 以下人员对此插件做出了贡献。

贡献者

「Toggles」插件已被翻译至 1 种本地化语言。 感谢所有译者为本插件所做的贡献。

帮助将「Toggles」翻译成简体中文。

对开发感兴趣吗?

您可以浏览代码,查看SVN仓库,或通过RSS订阅开发日志

更新日志

1.1.1 – 2024-07-16

  • Bumped minimum required WordPress version to 6.4.

1.1.0 – 2023-06-17

  • Bumped minimum required WordPress version to 6.1.
  • Fixes an error when selecting deeply nested inner blocks.
  • Block support enhancements.

1.0.1 – 2022-02-14

  • Bumped minimum required WordPress version to 5.8.
  • Pass component to renderAppender.

1.0.0 – 2021-02-05

  • Initial release.