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

Document Outline: Implement the document outline as a plugin #6278

Closed
wants to merge 1 commit into from

Conversation

youknowriad
Copy link
Contributor

refs #4287

This PR rewrites the document outline as a sidebar plugin. The original intent of the issue was to use a "PopoverPlugin" instead of "SidbarPlugin".

If we don't want to use the SidebarPlugin for now as the PopoverPlugin, This PR is still useful to help build the PopoverPlugin extensibility slot.

One issue I see with the PopoverPlugin though, is that it has no existence without an opening menu item as opposed to the sidebar. Also, where do you show the popover if the menu item is not pinned?

screen shot 2018-04-19 at 12 09 40

@youknowriad youknowriad added the [Feature] Extensibility The ability to extend blocks or the editing experience label Apr 19, 2018
@youknowriad youknowriad self-assigned this Apr 19, 2018
@gziolo
Copy link
Member

gziolo commented Apr 19, 2018

Not that much work to convert it to a plugin. Do we want to do the same for Document Settings and Block Setting? I didn't take that step, but if we are fine with using plugins mechanism for core features I can open PR to align with what this PR does.

Popover vs Sidebar is a design decision. Indeed, opening popover through More Menu can cause some UI challenges.

@youknowriad youknowriad force-pushed the update/document-outline-as-plugin branch from c67d1bf to ef24693 Compare April 19, 2018 11:34
@jasmussen
Copy link
Contributor

Thank you for working on this. Love intent. I would want Matías to be allowed to chime in with a final word, as I know that this is close to his heart.

In this case, I see two major improvements right off the bat. This area feels much more intentional:

screen shot 2018-04-19 at 13 43 49

It features global actions — to add to the document, or to go back and forth. Previously it felt a bit imbalanced, both optically and in that it was a mix of actions:

screen shot 2018-04-19 at 13 46 00

@gziolo brings up a good point, though, about this being a sidebar, and a popover being a bit weird to open from the more menu. I would note that this is an extra reason why it's healthy to open this PR, so that we can refine those interactions, and test our ideas about how extensibility should be. Right now this is in part modeled after Chrome extensions:

chrome extensions

In our case, it feels like we have a few missing pieces:

  • We don't yet have pinning and unpinning of extension icons. This would be a pinned-by-default extension
  • The ability to, sidebar open or not, quickly click the little (i) and see an overview, feels good. So popover would be good for this.
  • We don't yet have the Star button to pin or unpin an icon to the toolbar, as mocked up here

The way popovers could work in the ellipsis menu is that they simply pop up as little popups (with no triangle connector) until you pin them or dismiss them. Similar to the Chrome example above. This is sort of a standard pattern for other apps as well. Here's what it looks like when you open the keyboard shortcuts in Google Docs:

keyboard shortcuts

In fact it would be nice if we could write a keyboard shortcuts tool just like this, that would work in the same way. Pinnable or not.


So to summarize:

  • Popover would be good
  • Good to wait for pinning feature
  • Popup window when invoked from More menu, Pop-out window when invoked from its pinned position in the toolbar.

@gziolo
Copy link
Member

gziolo commented Apr 24, 2018

So to summarize:

  • Popover would be good
  • Good to wait for pinning feature
  • Popup window when invoked from More menu, Pop-out window when invoked from its pinned position in the toolbar.
  • Pinned by default

It all sounds like a great plan 💯 I'm starting on pinning feature tomorrow, thanks for sharing all details how it is supposed to work 👍

@gziolo gziolo added the [Feature] Document Outline An option that outlines content based on a title and headings used in the post/page label Apr 24, 2018
@gziolo gziolo modified the milestones: 2.9, Bonus Features May 7, 2018
@gziolo gziolo added the [Status] Blocked Used to indicate that a current effort isn't able to move forward label Jun 12, 2018
@ZebulanStanphill
Copy link
Member

Is this still blocked, and if so, by what?

@gziolo
Copy link
Member

gziolo commented Aug 10, 2018

@jasmussen, I think this is no longer blocked since we have Modal component. Is that right?

@jasmussen
Copy link
Contributor

I think this is no longer blocked since we have Modal component. Is that right?

That depends — is the modal able to show as a "popover"?

While I'm personally okay with the document outline becoming a true modal with a close button (though I'd want us to be able to show it more compact than it is now), I think @mtias was dreaming of a version of this that could behave identically to how it works now, only as a plugin.

@jasmussen
Copy link
Contributor

An alternative to converting it to a plugin, is to just move the icon over there on the right, between the cog and the ellipsis, even if it isn't a plugin.

@ZebulanStanphill
Copy link
Member

@jasmussen I think it should be a plugin at some point in the long run, just because it makes more sense to me from a technical perspective, and would provide an example in core of a simple plugin. It would allow you to unpin it from the toolbar if desired.

That said, I do think it makes more sense being on the right than on the left anyway.

@mtias mtias removed this from the Bonus Features milestone Oct 7, 2018
@mtias mtias added Future and removed Future labels Oct 7, 2018
@youknowriad
Copy link
Contributor Author

Closing, we might want to revisit at some point.

@youknowriad youknowriad closed this Nov 1, 2018
@youknowriad youknowriad deleted the update/document-outline-as-plugin branch November 1, 2018 11:01
@gziolo
Copy link
Member

gziolo commented Nov 1, 2018

We should get back to it 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Feature] Document Outline An option that outlines content based on a title and headings used in the post/page [Feature] Extensibility The ability to extend blocks or the editing experience [Status] Blocked Used to indicate that a current effort isn't able to move forward
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants