Skip to content

Enhancement: Better setup options for custom scripts (and actions) #517

Description

@davidsneighbour

Currently (it seems) all custom scripts are added to the Actions box and available in all content types. Shutting it off is only possible by removing that meta box from the view (with a custom view mode for instance).

The following is a current sample in my system:

20230227-18:15:41-Selection-001

  • I would love to remove the "Optimize slug" button. It is an internal action, so I can't just delete the config option
  • Starting and stopping the server might be done outside of the CMS. Even if not, it would use up less space by being a "switch" button. "Start server" if it's off, "Stop server" if it's on.
  • "Open Preview" should be only available when the server is running
  • Custom action youtube - I would love to show these buttons only where they are needed, based on content type. The youtube preview button for instance would show up only in type: video posts.
  • Or: based on frontmatter. The unsplash button only if a field/group unsplash is defined in the frontmatter of the current post.

In general the sidebar tends to be very long and cluttered on post pages. Showing things conditionally or collapse all boxes might help.

In short:

  • custom actions based on content type
  • disable/enable internal actions (like server start/stop) and optimize how they show up
  • conditional rules where to show custom actions based on frontmatter variables
  • a config option to collapse all boxes by default (or all boxes after a selected one) would be nice.

Metadata

Metadata

Assignees

No one assigned

    Projects

    Status
    Done

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions