Closed westonruter closed 7 years ago
I created a gist that has some light extensions for changesets to add some snapshots UI, just for testing. Some of the code may be helpful: https://gist.github.com/westonruter/b2c9edb9a2ee83236dd9b2b4f177ae76
The changesets post on Make/Core has some example API calls that should be used for creating drafts and scheduling changes via wp.customize.previewer.save()
: https://make.wordpress.org/core/2016/10/12/customize-changesets-technical-design-decisions/
This is an important issue to complete before the 4.7 release in December.
The underlying architecture in snapshots was committed to core in WordPress 4.7-alpha. As such, the redundant code in snapshots should be only run if on 4.6 or less. All of the redundant code should be extracted into one or more back-compat classes.
Also, now that the post type is
customize_changeset
as opposed tocustomize_snapshot
, there should be a data migration strategy. Also, any filters that apply oncustomize_snapshot_save
should also apply ontocustomize_changeset_save_data
.Whenever a
$_REQUEST['customize_snapshot_uuid']
is present we should duringplugins_loaded
make sure this gets mapped over tocustomize_changeset_uuid
in$_GET
,$_POST
, and$_REQUEST
.In the end, the plugin should be reformulated to anticipate that more and more of the features of the plugin will be incorporated into core. So the more that we can facilitate turning off aspects of the code that are already in core, the better.