=== WCAGpatch — WCAG Accessibility Scanner & AI Fixer ===
Contributors: (your WordPress.org username)
Tags: accessibility, wcag, ada, aria, compliance
Requires at least: 5.8
Tested up to: 7.1
Requires PHP: 8.0
Stable tag: 1.0.6
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Scan your WordPress site for WCAG 2.1 accessibility violations and auto-fix them with AI.

== Description ==

WCAGpatch scans every page of your WordPress site for WCAG 2.1 AA accessibility violations — missing alt text, poor color contrast, broken ARIA labels, and more — and shows you a score dashboard with prioritized fixes.

**Free — no license needed:**

* Full site scan with the built-in PHP scanner (unlimited pages)
* WCAG 2.1 AA violation reports
* Accessibility score dashboard
* Page-by-page violation breakdown
* Priority sorting by severity
* Scan history

**Starter (1 site):** everything in Free, plus

* PDF compliance certificate
* Email alerts when new violations are detected

**Pro (5 sites):** everything in Starter, plus

* axe-core deep scanner (runs in the browser, catches contrast and ARIA issues the PHP scanner cannot see)
* AI-powered auto-fix for image alt text (bring your own OpenAI key)
* PDF remediation report for compliance documentation

**Agency (unlimited sites):** everything in Pro, on as many sites as you like.

Upgrade at wcagpatch.com.

== Installation ==

1. Upload the plugin files to `/wp-content/plugins/wp-accessibility-shield/`
2. Activate the plugin through the Plugins menu
3. Go to Accessibility in your admin menu
4. Click "Scan All Pages" to run your first accessibility audit

== Frequently Asked Questions ==

= Is the scanner free? =
Yes. The PHP scanner, the dashboard and the scan history are free forever. The PDF certificate and email alerts start at Starter; the axe-core deep scanner, the AI auto-fix and the remediation report are Pro and above.

= What WCAG standard does it check? =
WCAG 2.1 Level AA — the standard required for ADA and Section 508 compliance.

= Does it slow down my site? =
No. Scanning runs server-side on demand, not on the frontend.

= Does this plugin call external APIs? =
Two, both only when you ask for them. The AI auto-fix feature uses the OpenAI Vision API with your own API key (BYOK) to generate alt text for images. License activation, deactivation and a once-daily license check talk to wcagpatch.com. Nothing about your content is sent to either service unless you use those features.

= What PHP version do I need? =
PHP 8.0 or later.

== Changelog ==

= 1.0.6 =
* Certificate PDF fits on one page again, with the shield mark restored.

= 1.0.5 =
* AI alt text now works on sites OpenAI cannot reach (localhost, staging behind a login): the image is sent inline instead of by URL.
* The OpenAI model is a setting (default gpt-4o-mini) for projects that restrict model access.
* The certificate PDF no longer shows a missing-glyph box where the shield icon was.

= 1.0.4 =
* Dashboard restyled: white score panel, higher-contrast metric tiles.

= 1.0.3 =
* Fixed: the plugin declared PHP 7.4 support but needs PHP 8.0. On PHP 7.4 it took the whole site down on activation. The requirement is now stated correctly, so WordPress will not let an incompatible site activate it.
* Fixed: changing the scan schedule now actually changes the schedule. Previously the saved setting and the running schedule disagreed, and picking "Daily" straight after "Manual" quietly left you with no scheduled scan at all.
* Fixed: PDF certificates and remediation reports no longer fail when another active plugin also bundles the dompdf library.
* Fixed: license server outages are now reported as outages ("Could not reach the license server, try again in a minute") instead of telling you your code is invalid, and they no longer wipe your license from the site.
* Fixed: deactivating a license only releases the seat once the server confirms it. A failed deactivation used to strand the seat and there was no way to get it back.
* Added: a once-daily license check. If a license stops being valid, paid features switch off and an admin notice explains why. If the license server is unreachable, nothing changes — an outage will never switch off features you paid for.
* Fixed: "License" appeared twice in the admin menu, and the top-level "Accessibility" menu opened the License page instead of the Dashboard.
* Fixed: an empty, unlabelled link in the admin menu — a WCAG 2.4.4 failure in an accessibility plugin.
* Fixed: removed a PHP 8.2 deprecation notice that the scanner logged once for every page it scanned, and which could corrupt scan responses on servers that display errors.
* Fixed: invalid license codes and a missing OpenAI key now return a proper client error instead of a server error.
* Changed: the "Fix with AI" button is now a flat, solid control that meets AA contrast, instead of an animated gradient.
* Removed: an unused licensing table that was never created and never read. Uninstall now cleans up every table the plugin has ever made.

= 1.0.2 =
* Packaging fix — the archive now contains the plugin and nothing else. The previous download included unrelated project files.
* Ships the freemium changes listed under 1.0.1, which were never published in a working release archive.

= 1.0.1 =
* Added freemium model — full scanning is free, Pro features gated
* Bug fix: duplicate license entry in settings

= 1.0.0 =
* Initial release

== Upgrade Notice ==

= 1.0.4 =
Dashboard restyled: white score panel, higher-contrast metric tiles.

= 1.0.3 =
Important fixes. Scheduled scans now use the schedule you picked, PDF export no longer breaks when another plugin bundles dompdf, and license server outages no longer look like a bad license code. Requires PHP 8.0.

= 1.0.2 =
Replaces the 1.0.1 download, which shipped the wrong build. Upgrade to get the freemium scanner and a correctly packaged plugin.

= 1.0.1 =
Freemium update — scanning is now free for all users. Pro features require a license.
