=== Shed Coming Soon ===
Contributors: teamstaccato
Tags: coming soon, maintenance, under construction
Requires at least: 6.0
Tested up to: 7.0
Requires PHP: 8.1
Stable tag: 1.4.7
License: GPL-2.0-or-later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Simple coming soon and maintenance page. Customize the title, message, background, and colors from the admin dashboard.

== Description ==

Shed Coming Soon is a lightweight plugin for displaying a coming soon or maintenance page while your site is being built or updated.

= Features =
* Coming Soon mode and Maintenance mode
* Set a custom title and rich-text message (HTML editor)
* Background image or background color
* Custom text color
* Site name: show, hide, or override with custom text
* Title font size selector (S / M / L / XL)
* Schedule automatic start and end times
* Bypass URL with cookie for previewing the live site
* Returns 503 status with Retry-After header (SEO-friendly)
* Cache purge on save for popular caching plugins
* Admin-only live preview panel with desktop / tablet / smartphone switching
* Logged-in administrators always see the full site

== Installation ==

1. Upload the plugin to the `/wp-content/plugins/` directory or install via the WordPress plugin screen.
2. Activate the plugin.
3. Go to Settings → Shed Coming Soon to configure.

== Frequently Asked Questions ==

= Does it work with page caching plugins? =

Yes. When settings are saved, the plugin automatically triggers cache purge hooks for popular caching plugins if they are installed and active. No data is sent to any external service.

= Does it work with CDN services? =

The plugin returns a 503 status with `Cache-Control: no-store` headers, which prevents most CDN configurations from caching the coming soon page. If you use aggressive full-page caching rules on your CDN or hosting environment, you may need to configure a cache bypass rule based on the `shedsoon_bypass` cookie. Please refer to your CDN or hosting provider's documentation for cache bypass settings.

= Will search engines index my coming soon page? =

No. The plugin returns a 503 status with a `Retry-After` header, which instructs search engines to come back later and not index the page.

= Can I let specific users preview the site while it is in coming soon mode? =

Yes. Generate a bypass URL from the settings page. Anyone with that URL will receive a 24-hour cookie that lets them view the full site.

== Screenshots ==

1. Admin settings page with live preview panel.
2. Example coming soon page displayed to visitors.

== Upgrade Notice ==

= 1.4.7 =
WP.org compliance: remove discouraged load_plugin_textdomain() call.

= 1.4.6 =
WP.org compliance: English i18n base, Clipboard API copy, sanitized superglobal access, phpcs fixes.

= 1.4.5 =
WP.org compliance: move inline scripts and styles to enqueued files, add LICENSE, update Tested up to 7.0.

= 1.4.4 =
Confirmed compatibility with WordPress 7.0.

= 1.4.3 =
WP.org compliance: full i18n support, uninstall cleanup, and minor security hardening.

== Changelog ==

= 1.4.7 =
* Fix: Remove discouraged load_plugin_textdomain() call (WordPress auto-loads translations since 4.6)

= 1.4.6 =
* Fix: Convert all Japanese msgids to English base strings for WP.org i18n compliance
* Fix: Add languages/ja.po with Japanese translations
* Fix: Replace hardcoded lang="ja" in JS preview builder with dynamic site language
* Fix: Replace deprecated document.execCommand with Clipboard API (execCommand fallback retained)
* Fix: Sanitize $_GET['shedsoon_preview'] via sanitize_key() + wp_unslash() before use
* Fix: Add phpcs:ignore with justification to raw header() calls for 503 SEO headers
* Fix: wp_die() calls now pass HTTP status via ['response' => 403] argument
* Fix: Add phpcs:ignore to inline style block in standalone 503 template
* Fix: Move onclick="this.select()" from inline HTML to JS file

= 1.4.5 =
* Fix: Move inline admin script to enqueued JS file (WP.org compliance)
* Fix: Move inline admin styles to enqueued CSS file (WP.org compliance)
* Fix: Add LICENSE file (GPL-2.0)
* Fix: Plugin header Description updated to English
* Fix: Wrap default message string in template with translation function
* Tested: Confirmed compatibility with WordPress 7.0

= 1.4.4 =
* Tested: Confirmed compatibility with WordPress 7.0

= 1.4.3 =
* Fix: Full i18n — wrap all user-visible strings with translation functions
* Fix: Add uninstall.php to clean up all options on plugin delete
* Fix: Plugin header — GPL-2.0-or-later, License URI, Domain Path, Tested up to
* Fix: Create languages/index.php (Silence is golden)
* Fix: Sanitize $_COOKIE value before comparison

= 1.4.2 =
* Fix: Plugin Check — remove link rel stylesheet literal from admin JS preview builder

= 1.4.1 =
* Fix: Plugin Check compliance — variable prefix, wp_unslash, wp_safe_redirect, phpcs ignore for standalone template

= 1.4.0 =
* Added: Site name display toggle and custom text override

= 1.3.0 =
* Changed: Resizable 2-column admin layout with desktop / tablet / smartphone preview switching
* Added: "Open in new tab" button for full-size preview (admin-only endpoint)

= 1.2.0 =
* Added: Title font size selector (S / M / L / XL)
* Added: WP visual editor (TinyMCE) for message field
* Added: Live preview panel in admin

= 1.1.0 =
* Added: Option to allow or block REST API requests during coming soon mode

= 1.0.5 =
* Added: Cache purge on save for popular caching plugins
* Added: CDN/hosting cache bypass setup guide in admin UI

= 1.0.4 =
* Changed: All function, class, constant, hook, and option prefixes renamed from wscs_/WSCS_ to shedsoon_/SHEDSOON_/Shedsoon_.

= 1.0.0 =
* Initial release.
