=== SKY Blocks ===
Contributors: skycolor318
Tags: blocks, gallery, comic, novel, creator
Requires at least: 6.9
Tested up to: 7.1
Requires PHP: 8.3
Stable tag: 1.1.0
License: GPL-2.0-or-later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Blocks for creators' websites: comic spread galleries, name changer for novels, content warnings, clap button, speech balloons and more.

== Description ==

**SKY Blocks turns the block editor into a toolkit for creators' websites.**

Comics, illustrations, novels, fan works... Creator sites need features that ordinary blog themes don't have: a gallery that reads like a book, a "name changer" for dream novels, a content warning before sensitive works, a clap button to receive feedback. SKY Blocks brings all of them into the block editor — no shortcodes, no extra plugins, no coding.

Available in English and Japanese (日本語).

= Made for comics & illustrations =

* **Decorative Gallery** – Show comics and illustrations in a full-screen viewer. Choose horizontal scroll, two-page spread (reads like a book), vertical one-page-at-a-time, or continuous vertical scroll. Images are lazy-loaded, so long comics stay fast.
* **Simple Image** – A lightweight image block with an optional lightbox (with previous/next navigation) and an option to preload the first-view image for better page speed.

= Made for novels & stories =

* **Name Changer** – Readers type their own name, and every `[change]` in the page is replaced with it. The name is remembered in the reader's browser.
* **Spoiler** – Hide text with `[hide]...[/hide]` and reveal it with a button. Great for spoilers, quiz answers and hidden notes.
* **Speech Balloon** – Conversation-style balloons with character icons. 9 styles including "thinking" bubbles, chat-app style and interview style.

= Protect your readers =

* **Content Warning (One Cushion)** – Blur the content and show a confirmation message first. Readers who agree see the content; others are sent to a page you choose. Their choice is remembered.

= Connect with your fans =

* **Clap Button (Web Clap)** – A "like" button for your works. Claps are counted per post, and you can check daily, monthly and all-time rankings in the admin screen. Optionally redirect fans to a thank-you page.
* **Share Buttons** – X, Threads, Bluesky, LINE, Misskey, Taittsuu, Hatena Bookmark, Pinterest, Facebook and a copy-URL button. Choose the services and their order.
* **Visitor Counter** – A simple site visitor counter, just like the classic personal sites. (Requires the "Post view counter" feature.)
* **Last Updated Date** – Show when your site was last updated (last post date or last modified date).

= Layout & design =

* Accordion, Message Box, Banner List, Definition List and Simple Columns.
* Every block has style variations, color settings, borders, rounded corners, shadows and spacing controls.
* Set your own preset colors once, and use them across all blocks.

= Handy site tools (all optional) =

Turn on only what you need from the settings screen:

* Post view counter (shown in the posts list and the dashboard)
* Duplicate posts and pages with one click
* Disable right-click
* Clean up `<head>`: remove the WordPress version, emoji scripts, RSD links, REST API link, DNS prefetch and more
* Disable RSS feeds, self-pingbacks, automatic quote conversion (wptexturize) and the default block patterns

= Lightweight by design =

* Turn individual blocks on or off. Disabled blocks are not loaded at all.
* Front-end scripts are small, plain JavaScript with no jQuery.

== Installation ==

1. Install SKY Blocks from **Plugins > Add New**, or upload the plugin folder to `/wp-content/plugins/`.
2. Activate the plugin.
3. Open **SKY Blocks** in the admin menu to choose the blocks and features you want to use.
4. In the block editor, find the blocks in the **SKY Blocks** category.

== Frequently Asked Questions ==

= Does it work with any theme? =

Yes. SKY Blocks works with both block themes and classic themes that support the block editor.

= How do I use the Name Changer? =

Add the Name Changer block to a page, then write `[change]` wherever the name should appear. When a reader enters a name, all `[change]` parts on that page are replaced.

= How do I use the Spoiler block? =

Inside the Spoiler block, wrap the text you want to hide with `[hide]` and `[/hide]`. Readers can reveal it with the button.

= Where can I see the clap statistics? =

Open **SKY Blocks** in the admin menu and select the **Clap Statistics** tab. The tab appears when the Clap Button block is enabled. You can see the last 7 days, all-time totals, daily / monthly counts and rankings per post.

= Can I limit how often the same person can clap? =

Yes. Set the limit (in days) in the block settings. Set it to 0 for no limit.

= Which languages are supported? =

English and Japanese. The Japanese translation is included in the plugin. Translations for other languages are welcome on translate.wordpress.org.

== Privacy ==

* **Clap Button**: when a visitor claps, the post ID, IP address, browser information (user agent) and date are saved in your site's database, and a cookie is set to limit repeated claps.
* **Post view counter / Visitor Counter**: cookies are used to avoid counting the same visitor repeatedly. No personal data is stored.
* **Content Warning and Name Changer**: the reader's choice and entered name are saved only in the reader's own browser (localStorage) and are never sent to your server.
* **Share Buttons**: no data is sent to external services until the visitor clicks a button.

SKY Blocks does not send any data to external servers.

Please mention the above in your site's privacy policy if necessary.

== Changelog ==

= 1.1.0 =
* New: The plugin is now translation-ready. The admin screens and block editor are in English, with a bundled Japanese translation.
* Fixed: Clap button did not record claps (wrong table name).
* Fixed: Clap button now uses a signed POST form (no counting by crawlers, works with page cache) and respects the clap limit days setting.
* Fixed: Open redirect via the clap button thank-you page parameter.
* Fixed: Default-enabled features (post view counter, generator removal) were not active until settings were saved.
* Fixed: Unchecking all blocks/features was shown as all checked in the settings screen.
* Fixed: Disable feeds, disable emojis and auto-sizes CSS removal options did not work on recent WordPress versions.
* Fixed: Simple image preload, last updated date timezone, gallery scroll lock on Esc and gallery class handling.
* Fixed: Post duplication removed backslashes from block content.
* Fixed: "Last 7 days" and daily ranking in clap statistics used wrong dates.
* Added: Capability check for deleting clap statistics, uninstall cleanup.

= 1.0.1 =
* Added an icon.

= 1.0.0 =
* Initial release.

== Upgrade Notice ==

= 1.1.0 =
Important fixes: the Clap Button now records claps correctly, and a security issue (open redirect) has been fixed. The plugin is now available in English and Japanese. Please update.
