Skip to content

Conversation

@threefjefff
Copy link
Collaborator

@threefjefff threefjefff commented Mar 25, 2025

Describe your changes

A number of Quality of Life improvements split out from #400. The aim here is to pull in these improvements and de-bloat that feature PR.

  • We're pulling plugins to their own top level object, in preperation for creating first-party plugins (e.g. Snippets).
  • Simplify the "language" attribute on code blocks. We have a number of features planned in the future around making the language on a block upcoming, including not alway using detecting the language. Simplifying the wording.
  • Make getFinalizedMenu non-mutating.
  • Allow the editor to append (rather than just set) content.

PR Checklist

  • All new/changed functionality includes unit and (optionally) e2e tests as appropriate
  • All new/changed functions have /** ... */ docs
  • I've added the bug/enhancement and other labels as appropriate

Environment(s) tested

  • Device: desktop
  • OS: Windows 10
  • Browser: Chrome
  • Version: 134.0.6998.37

threefjefff and others added 5 commits March 21, 2025 16:48
- Allow pasteHandlers from external plugins to consume the events first
- Normalize attrs on code blocks for setting language
- Normalize and provide Core menus to external menu block callbacks
@threefjefff threefjefff added the enhancement New feature or request label Mar 25, 2025
Copy link
Contributor

@giamir giamir left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @threefjefff for the PR. What you have looks good.

I have added guidance to ensure plugins can be consumed easily by consumers.
Let me know if you need me to clarify sync what I am suggesting.

I took the time to test things in Core so what I have written up should be working. 🤞

@threefjefff threefjefff requested a review from giamir March 26, 2025 16:29
Copy link
Contributor

@giamir giamir left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

small thing missing

@threefjefff threefjefff requested a review from giamir March 26, 2025 16:48
Copy link
Contributor

@giamir giamir left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @threefjefff for this great improvement. I am really happy to see the path forward for writing editor plugins taking shape. 🎉

@threefjefff threefjefff merged commit 67e607d into StackExchange:main Mar 26, 2025
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants