xwp / wp-customize-snapshots

Customize Snapshots WordPress Plugin
https://wordpress.org/plugins/customize-snapshots/
52 stars 11 forks source link

Preview future site state #95

Closed PatelUtkarsh closed 6 years ago

PatelUtkarsh commented 8 years ago

Fixes #21

Todos

Dependent on PR #93

coveralls commented 8 years ago

Coverage Status

Coverage increased (+1.8%) to 92.383% when pulling f63f40bb08bf9b33c4c7ff4ef1f61754ef53ecbb on feature/preview-future-site-state into 59006710c619d54029b765740fd6a850ba1c5f5e on develop.

coveralls commented 8 years ago

Coverage Status

Coverage increased (+1.5%) to 92.135% when pulling dada7d2084d3c160877a179f3425c98b791471c7 on feature/preview-future-site-state into 59006710c619d54029b765740fd6a850ba1c5f5e on develop.

coveralls commented 8 years ago

Coverage Status

Coverage increased (+1.6%) to 92.17% when pulling a2e56ee7ad3950ac25a41a2c54634ba3c7391ff3 on feature/preview-future-site-state into 59006710c619d54029b765740fd6a850ba1c5f5e on develop.

coveralls commented 8 years ago

Coverage Status

Coverage increased (+1.3%) to 91.92% when pulling 550db718080ce5fc0ed1b90af0035a05c7a9d5e0 on feature/preview-future-site-state into 59006710c619d54029b765740fd6a850ba1c5f5e on develop.

coveralls commented 8 years ago

Coverage Status

Coverage increased (+1.9%) to 92.53% when pulling 10f99f33ee419fcd7f94cf7ac558bd46aae53d39 on feature/preview-future-site-state into 59006710c619d54029b765740fd6a850ba1c5f5e on develop.

coveralls commented 8 years ago

Coverage Status

Coverage increased (+2.08%) to 92.678% when pulling 8d5d7e7e08b98d4b256a0db129d420f309f558c0 on feature/preview-future-site-state into 59006710c619d54029b765740fd6a850ba1c5f5e on develop.

miina commented 8 years ago

@PatelUtkarsh Bringing the conversation over to here:

M: When checking the future preview with 1 Snapshot (without conflicts), I could still edit it in Customizer and change a value with clicking "Schedule", is this expected behavior? Maybe it is :)

U: I haven't got approval on that one yet, So if there is only one snapshot we are directly previewing it right now in (#95), Maybe we should fork/duplicate it and preview it. I thought because it is just previewing we can skip extra steps of duplication.

M: When checking the future preview with multiple Snapshots scheduled and when I click Customize and make some edits, it's going to create a new merged Snapshot, is this expected? However, this new Snapshot will not be Scheduled unless scheduled specifically, so it won't actually make any changes. Maybe this can be confusing? Thoughts?

U: Yes, so when you preview from dashboard it creates new merge snapshot with auto-draft status(merging all future snapshots comparing to date). If you start editing it, it will put that in draft status and will allow you to edit.

Okay, thinking that it would be great if previewing a future site would have consistency. So that if I make edits in Customizer while previewing a future site, always X happens. Otherwise it's confusing in terms of UX that in case in code only a single Snapshot is found, then X happens but if more Snapshots are found, Y happens. Also, it would be good to know somehow that I'm not previewing a Snapshot I've created but the site preview. For example when live previewing a theme, the Customizer has this button instead of the usual Save & Publish: live-preview Maybe when making edits while previewing, it'd also be useful to use a similar logic and change the button text? Thoughts?

PatelUtkarsh commented 8 years ago

So in a case of a single snapshot we should create a duplicate snapshot to remove that inconsistency (depends on #90), I will add to-do.

About UX I am not sure, @westonruter thoughts?

coveralls commented 8 years ago

Coverage Status

Coverage increased (+2.1%) to 92.694% when pulling c53b51383430a3e432f29c4fee93e5e98c4ad8f3 on feature/preview-future-site-state into 8a253fdb85d5a64ea1e5ec8fb555966055b4a051 on develop.

westonruter commented 8 years ago

Should previewing future state where multiple changesets/snapshots are combined have a readonly mode? Should previewing this open on the frontend with the snapshot UUID supplied rather than opening the customizer with the UUID supplied? I should think that the virtual future-merged changesets would be represented in a new auto-draft snapshot/changeset that would be readonly and wouldn't be used for making edits. If you did want to explicitly edit the merged state, then you could click multiple future snapshots to then merge together into a new snapshot to make that explicit. Some ideas.

PatelUtkarsh commented 8 years ago

Yes, read-only makes sense. In the case of the read-only preview, I've removed wp_admin_bar link for inspect snapshot(post-edit) link and customize (don't add UUID in this case). I've done that in 1e043e9.

coveralls commented 8 years ago

Coverage Status

Coverage increased (+2.3%) to 92.894% when pulling 5ecf583d74f7dad328103b84f65bc73c8c133e1c on feature/preview-future-site-state into 629033dd3704945aa78e72986441425925c1b1a2 on develop.

coveralls commented 8 years ago

Coverage Status

Coverage increased (+2.2%) to 92.779% when pulling 90277a67e027c05aa08ee3caeb4849bd0e2d3b0f on feature/preview-future-site-state into 629033dd3704945aa78e72986441425925c1b1a2 on develop.

coveralls commented 7 years ago

Coverage Status

Coverage decreased (-10.7%) to 79.882% when pulling 2011a9aad7699186e71473ce510e88a4be6c2368 on feature/preview-future-site-state into 629033dd3704945aa78e72986441425925c1b1a2 on develop.

coveralls commented 7 years ago

Coverage Status

Coverage decreased (-10.8%) to 79.753% when pulling 022be77712add9c2368cbc8e2ab1d46368debfaa on feature/preview-future-site-state into 629033dd3704945aa78e72986441425925c1b1a2 on develop.

coveralls commented 7 years ago

Coverage Status

Coverage decreased (-10.8%) to 79.753% when pulling bf75821430bf99c9a3f4413ab9b7853aa970724b on feature/preview-future-site-state into 629033dd3704945aa78e72986441425925c1b1a2 on develop.

coveralls commented 7 years ago

Coverage Status

Coverage decreased (-10.8%) to 79.753% when pulling 9d9477c3e61b56cb83eae0afef09f951ee8febcf on feature/preview-future-site-state into 629033dd3704945aa78e72986441425925c1b1a2 on develop.

valendesigns commented 7 years ago

@PatelUtkarsh Please fix merge conflicts so I can review. Thanks!

coveralls commented 7 years ago

Coverage Status

Coverage increased (+2.9%) to 77.803% when pulling 98879c5a0b57c80c7c612123b46af69ab1de5eda on feature/preview-future-site-state into 1784a74e739ae47f91193db47e5a8ee5083bbc15 on develop.

PatelUtkarsh commented 6 years ago

Todo: