Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add ability to block publishing per-checklist item #8

Open
mikeselander opened this issue May 5, 2020 · 2 comments
Open

Add ability to block publishing per-checklist item #8

mikeselander opened this issue May 5, 2020 · 2 comments

Comments

@mikeselander
Copy link

From our documentation, it appears that we can turn on blocking of publishing a post for all checklist items or not at all via altis.publication-checklist.block_on_failing config option.

However, it would be quite useful to make some checklist items blocking, but not all.

As an example, let's say we have two items on a publication checkilst:

  1. Require a featured image.
  2. Embargo date, whereby a post should never be published before it is over.

Item one is an important reminder, but should not block publishing a post in some situations. Item two is an absolute 100% must-never-happen item and this should always block an editor from publishing.

@huubl
Copy link
Contributor

huubl commented Dec 21, 2020

This would be very useful!

@roborourke
Copy link
Contributor

This should be possible now that wp.data.dispatch('core/editor').lockPostSaving() accepts a string, so you can have multiple separate locks on publishing eg.:

wp.data.dispatch('core/editor').lockPostSaving('publication-checklist.featured-image')

// unlocking
wp.data.dispatch('core/editor').unlockPostSaving('publication-checklist.featured-image')

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants