[wp-trac] [WordPress Trac] #34882: make registered editor stylesheets available to frontend
WordPress Trac
noreply at wordpress.org
Thu Jun 2 05:07:17 UTC 2016
#34882: make registered editor stylesheets available to frontend
--------------------------+---------------------------------
Reporter: ungestaltbar | Owner:
Type: enhancement | Status: closed
Priority: normal | Milestone:
Component: TinyMCE | Version: 4.4
Severity: normal | Resolution: maybelater
Keywords: | Focuses: ui, administration
--------------------------+---------------------------------
Comment (by webmandesign):
Adding an editor stylesheet(s) is responsibility of the theme, right?
In that case a plugin using the TinyMCE editor on frontend doesn't know
about what editor stylesheets the theme includes. So, using `mce_css`
filter in plugin doesn't make sense really.
Likewise, if the theme wants its editor stylesheets to be frontend
available, it should hook to `mce_css` right from the start. Then what
point there is to use `add_editor_style()`?
[https://github.com/WordPress/WordPress/pull/213 I've proposed the way]
which filters the `! is_admin()` conditional inside `add_editor_style()`,
so a theme can use `add_editor_style()` as usually, while a plugin which
uses TinyMCE editor on frontend can hook onto the conditional and change
it when needed so it allows theme editor stylesheets in frontend editor.
What do you think about that?
#36985 => https://github.com/WordPress/WordPress/pull/213
--
Ticket URL: <https://core.trac.wordpress.org/ticket/34882#comment:3>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list