# Back to Top Block

[![Playground Demo Link](https://img.shields.io/badge/Playground_Demo-v1.0.3-blue?logo=wordpress&logoColor=%23fff&labelColor=%233858e9&color=%233858e9)](https://playground.wordpress.net/?blueprint-url=https://raw.githubusercontent.com/philhoyt/Back-to-Top-Block/main/_playground/blueprint.json)
![WordPress Plugin: Required WP Version](https://img.shields.io/badge/WordPress-%3E%3D6.6-blue)
![License](https://img.shields.io/badge/license-GPL--2.0%2B-green)

A customizable "Back to Top" button block for WordPress that helps users quickly navigate to the top of your pages.

## Description

The Back to Top Block is a simple yet powerful WordPress block that adds a customizable button allowing users to smoothly scroll back to the top of your page. It's perfect for long-form content and enhancing user experience.

![Demo of Block](https://github.com/philhoyt/Back-to-Top-Block/blob/main/assets/demo.gif)

### Block Settings

![Block Settings](https://github.com/philhoyt/Back-to-Top-Block/blob/main/assets/setting.png)

### Features

- 🎨 **Fully Customizable**
  - Show/hide arrow icon
  - Show/hide button text
  - Custom button text
  - Custom icon upload support

- 🔄 **Smooth Scrolling**
  - Built-in smooth scrolling animation
  - Respects user's reduced motion preferences

- ♿ **Accessibility**
  - Screen reader compatible
  - Proper ARIA labels
  - Keyboard navigation support

## Installation

1. Upload the plugin files to the `/wp-content/plugins/back-to-top-block` directory
2. Activate the plugin through the 'Plugins' screen in WordPress
3. Use the Block Editor to add the Back to Top Block to your pages

## License

This project is licensed under the GPL-2.0-or-later - see the [LICENSE](LICENSE) file for details.
