Skip to content

Add support for Template Activation #797

@mikachan

Description

@mikachan

We should add support for Template Activation, which is currently under an experiment in Gutenberg: WordPress/gutenberg#73252

When this is stabilised, it will likely land in WordPress 7.0, so we should make sure the plugin works with this new template functionality before then.

Tasks

  • Update get_block_templates() calls to explicitly request inactive templates when needed (e.g., when clearing customisations or exporting all templates): Template Activation: Update get_theme_templates #798
  • Modify clear_user_templates_customizations() and clear_user_template_parts_customizations() to include inactive templates: Template Activation: Update get_theme_templates #798
  • Add activation state checking to template filtering logic by modifying should_include_template()
  • Add options to control whether inactive templates are included in exports
  • Consider how to handle duplicate templates (same slug, different IDs) when saving to theme files

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions