gutenberg icon indicating copy to clipboard operation
gutenberg copied to clipboard

Add DocumentActions to Style Book

Open richtabor opened this issue 2 years ago • 3 comments

As discussed in https://github.com/WordPress/gutenberg/issues/51667#issuecomment-1598801110, lets add the DocumentActions to the Style Book editor header.

Before:

CleanShot 2023-09-15 at 15 45 39

After:

CleanShot 2023-09-15 at 15 46 03

richtabor avatar Sep 15 '23 19:09 richtabor

It would also have the "Back" button at the left, to go back to the previous view.

richtabor avatar Mar 25 '24 19:03 richtabor

At one point should we consider this view "style book" as opening the "global styles" entity in the editor. Similar to how we open a "page", a "post", a "pattern" or "template part".

This would make the "back" button (focus mode) and the action bar work.

It might have side effects elsewhere though (save buttons and such)

youknowriad avatar May 01 '24 12:05 youknowriad

The other noticeable impact such a change makes is that it will also change the "document" panel and its content in the "settings" sidebar. That said, currently it's not possible to open that sidebar while the style book is open.

I actually wonder if it's a better modal to avoid having a separate "global styles" sidebar and instead just use that "document" panel as the global styles sidebar. I think it would be a better model (mental model that can translate to a UI model) but granted that it might be a bigger change.

youknowriad avatar May 01 '24 12:05 youknowriad

I'm exploring a fix for this and https://github.com/WordPress/gutenberg/issues/51667 over in https://github.com/WordPress/gutenberg/pull/62669.

I didn't take on any refactoring, instead trying to resolve this issue with minimal changes while trying to not make anything worse for when we eventually rework how Style Book/Revisions UI is loaded.

creativecoder avatar Jun 19 '24 02:06 creativecoder

Resolved by #62669

creativecoder avatar Jun 25 '24 15:06 creativecoder