[wp-trac] [WordPress Trac] #34247: Make <!--nextpage--> work in visual editor
WordPress Trac
noreply at wordpress.org
Fri Oct 16 07:45:47 UTC 2015
#34247: Make <!--nextpage--> work in visual editor
------------------------------------+-----------------------------
Reporter: prasad-nevase | Owner:
Type: enhancement | Status: new
Priority: normal | Milestone: Future Release
Component: Editor | Version:
Severity: normal | Resolution:
Keywords: has-patch dev-feedback | Focuses:
------------------------------------+-----------------------------
Changes (by swissspidy):
* keywords: needs-patch => has-patch dev-feedback
* milestone: Awaiting Review => Future Release
Comment:
Interestingly, this is already supported by the editor, but is somewhat
broken.
When inserting (i.e. pasting) `<!--nextpage-->` or `<!--more-->`, the
editor should replace the tags with the preview. That doesn't work though,
because TinyMCE receives it as `<!--nextpage-->`.
Besides that, there are configurations for a dedicated button to add a
page break. It's just missing from the `$mce_buttons` array.
[attachment:34247.diff] fixes this by:
* Changing the `indexOf` check when inserting the tags
* Adding the page break button back to the editor.
I don't know why or when the button was removed from the editor, but with
the recent efforts to improve pagination there's no harm in adding it
back.
@iseulde Would you mind having a look at this?
--
Ticket URL: <https://core.trac.wordpress.org/ticket/34247#comment:3>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list