Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/dannorthern/accordion-block

Experimenting with the Interactivity API to build an Accordion block.
https://github.com/dannorthern/accordion-block

accordion block interactivity-api plugin toggle wordpress wordpress-block wordpress-plugin

Last synced: 17 days ago
JSON representation

Experimenting with the Interactivity API to build an Accordion block.

Awesome Lists containing this project

README

        

# Accordion Block

WordPress plugin that adds two blocks for building accordions. The main Accordion block is the parent for the Accordion Item block.

![Screenshot of accordion block](https://i.imgur.com/2BxktJc.png)

## Features

- Block styles for the main accordion to choose toggle style
- Default (chevron)
- Chevron Right
- Plus/Minus
- Support for color & background color.
- Support for shadow, border, spacing, etc.
- Option to set default open/closed state for each accordion-item
- Innerblock support, so any blocks can be nested within the accordion-item block's content.

## How to Use

1. Get the plugin by downloading the zip or cloning, `git clone [email protected]:dannorthern/accordion-block.git`
2. Install and activate the plugin in WordPress
3. Add an Accordion block to your page
4. Insert Accordion Item blocks inside the accordion. By default the template adds two.

## Requirements

- WordPress 6.1+
- PHP 7.0+