Skip to content

WordPress 7.1: dynamic galleries and post-attached media iteration issue #77117

@ramonjd

Description

@ramonjd

This issue tracks the scope for improvements to media inserter and galleries, and associated updates to attachments post type etc for WordPress 7.1.

See:

It will be expanded as explorations take place.

Media inserter

Add the following functionality (TBD):

  • Display images attached to the current post in the inserter sidebar
  • Use thumbnail grid similar to external media items in pre-publish flow
  • Support inserting a gallery with all attached images
  • Support adding/detaching images from the post
  • Support dragging a single item into the canvas to insert as a block
  • Support dragging a single item to set as a cover background

Dynamic galleries

Add the following functionality (TBD):

  • Add a dynamic toggle to the gallery block, make it clear tot he user how dynamic mode works when toggled
  • Show all images attached to the current post
  • Mimic [gallery] shortcode behavior with no image IDs and dynamic rendering
  • Support sorting: reverse order, random order?

Nice-to-haves / stretch goals

  • Allow other kinds of dynamic gallery queries (e.g. by year, month, date), or (even bigger stretch) by categories or tags

Related issues

Some of the above features might require fixing bugs / adding additional functionality to GB or WP core, especially in how attached to behaviour works.

Explore options for tracking/storing attachment post relationships

wp_posts.post_parent is the only first-class mechanism for recording that a media item is attached to a post. It's a single integer column — no many-to-many relationship exists in core today.

If we want features such as displaying images attached to the current post directly in the sidebar, or creating galleries dynamically based on this relationship, it'll be a blocking requirement.

Metadata

Metadata

Assignees

No one assigned

    Labels

    [Feature] MediaAnything that impacts the experience of managing media[Type] IterationScoped iteration of an effort from a tracking issue or overview issue ideally for a major release.

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions