=== Change Ledger – Targeted Rollback ===
Tags: rollback, audit log, revisions, elementor, divi
Requires at least: 6.5
Tested up to: 7.0
Requires PHP: 7.4
Stable tag: 0.1.0
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Reverse one recorded WordPress change without replacing unrelated newer work.

== Description ==

Change Ledger records supported before-and-after values and gives administrators a targeted recovery action for each entry.

Unlike a site-wide restore, a targeted rollback changes only the paths named by the ledger entry. Before writing, the plugin compares the live target with the recorded after-state. If that target changed again, rollback is blocked rather than overwriting newer work.

Version 0.1 supports:

* Posts, pages, admin-visible custom post types, featured images, supported metadata, and taxonomies.
* Classic menus and block navigation.
* Widgets and sidebar placement.
* Curated WordPress settings, registered plugin settings, theme modifications, and adapter-supplied options.
* Plugin activation and deactivation state while the plugin files remain installed.
* Elementor structured page data with path-level rollback.
* Divi 4 and Divi 5 detection. Layout-content changes use an explicit complete-page layout rollback; non-layout changes remain targeted.
* Searchable administrator history, conflict status, rollback chains, retention, privacy tools, Site Health, and WP-CLI.

Change Ledger is not a backup product. It does not restore files, plugin or theme code, media binaries, deleted posts, or a damaged database. Keep normal backups.

Known credential-like option names and paths are excluded. Because extensions can store secrets under arbitrary names, integrations must identify any additional secret-bearing fields they add.

== Installation ==

1. Upload the plugin ZIP through Plugins > Add New > Upload Plugin.
2. Activate Change Ledger – Targeted Rollback.
3. Open Tools > Change Ledger.
4. Review Settings and choose a retention period.
5. Make a controlled test edit on staging before relying on rollback in production.

== Frequently Asked Questions ==

= What happens when the same value was edited again? =

Rollback is blocked. The plugin will not overwrite a target that no longer matches the recorded after-state.

= Does it replace backups? =

No. It is a targeted operational recovery layer, not disaster recovery.

= How does Elementor support work? =

Elementor JSON is normalized and compared by path, allowing an individual recorded widget setting to be restored when its live path still matches. Large layout reorders can produce broader path changes because Elementor elements are stored in ordered arrays.

= How does Divi support work? =

When Divi layout content changes, Change Ledger restores the recorded page-layout content as one target. It does not claim module-level Divi rollback. Divi settings or ordinary post fields that changed independently remain targeted.

= Can a rollback be undone? =

Yes. Every successful rollback creates a new reversible recovery entry, producing an auditable undo/redo chain.

= Does uninstall delete history? =

Not by default. Enable the explicit delete-on-uninstall setting before uninstalling when the ledger and settings should be removed.

== Privacy ==

The plugin stores supported before-and-after site values, WordPress user ID, request context, and timestamps. The WordPress personal-data exporter reports user attribution; the eraser anonymizes that attribution while retaining operational recovery history. Known credential-like option names and paths are excluded heuristically.

== Changelog ==

= 0.1.0 =

* Initial release.
* Added conflict-safe path-level rollback and reversible recovery chains.
* Added WordPress, menu, widget, option, plugin-state, Elementor, and Divi adapters.
* Added retention, privacy, Site Health, WP-CLI, and release verification tools.
