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

fix: re-use of texteditor with markdown ext breaks markdown toolbar items #34

Merged
merged 2 commits into from
Dec 29, 2021

Conversation

davwheat
Copy link
Member

Changes proposed in this pull request:

Re-use of the TextEditor outside the standard composer, along with the Markdown extension, results in errors since Markdown is hard-coded to use app.composer.

This PR switched app.composer out for a dynamic system which fetches the appropriate data from the current TextEditor instance state.

Reviewers should focus on:

N/A

Screenshot

Necessity

  • Has the problem that is being solved here been clearly explained?
  • If applicable, have various options for solving this problem been considered?
  • For core PRs, does this need to be in core, or could it be in an extension?
  • Are we willing to maintain this for years / potentially forever?

Confirmed

  • Frontend changes: tested on a local Flarum installation.
  • Backend changes: tests are green (run composer test).
  • Core developer confirmed locally this works as intended.
  • Tests have been added, or are not appropriate here.

js/src/forum/index.js Outdated Show resolved Hide resolved
@davwheat davwheat merged commit 66595e3 into master Dec 29, 2021
@davwheat davwheat deleted the dw/fix-encapsulation branch December 29, 2021 20:41
askvortsov1 pushed a commit that referenced this pull request Mar 11, 2022
…tems (#34)

* fix: re-use of texteditor with markdown ext breaks markdown toolbar items

* code review
askvortsov1 pushed a commit that referenced this pull request May 10, 2022
…tems (#34)

* fix: re-use of texteditor with markdown ext breaks markdown toolbar items

* code review
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants