Commit Graph

150 Commits

Author SHA1 Message Date
Andrew Ozz
53ce07bf36 TinyMCE:
- Tighten up button styles, add :hover for .mce-active buttons.
- Pad only the first toolbar row and remove the padding in both toolbars if the editor doesn't have a DFW mode.
Part props avryl, see #27279

git-svn-id: https://develop.svn.wordpress.org/trunk@27978 602fd350-edb4-49c9-b593-d223f7449a82
2014-04-07 01:09:38 +00:00
Andrew Ozz
36f0a60829 Throw a user notice when the editor ID used for TinyMCE contains brackets, props nacin, fixes #27601
git-svn-id: https://develop.svn.wordpress.org/trunk@27950 602fd350-edb4-49c9-b593-d223f7449a82
2014-04-05 01:10:19 +00:00
Andrew Ozz
f57853519f TinyMCE: update translatable strings, see #27453, #24067
git-svn-id: https://develop.svn.wordpress.org/trunk@27927 602fd350-edb4-49c9-b593-d223f7449a82
2014-04-03 05:15:59 +00:00
Andrew Ozz
74ec183ee7 TinyMCE:
- Bring back loading of /langs/[locale].js and /langs/[locale]_dlg.js from PHP. Prevents errors with missing translation files when custom plugins use requireLangPack() without second argument.
- Back to using ISO 639-1 (two letter) locales as the locale is used as part of the translation file name.
See #24067, fixes #27610

git-svn-id: https://develop.svn.wordpress.org/trunk@27922 602fd350-edb4-49c9-b593-d223f7449a82
2014-04-03 03:39:21 +00:00
Andrew Ozz
7b272d3a26 Drag and drop files on the editor to upload: add new argument to wp_editor() to enable, fixes #27465
git-svn-id: https://develop.svn.wordpress.org/trunk@27901 602fd350-edb4-49c9-b593-d223f7449a82
2014-04-02 02:41:24 +00:00
Andrew Ozz
5977c4332e TinyMCE: update to 4.0.21, see #24067
git-svn-id: https://develop.svn.wordpress.org/trunk@27897 602fd350-edb4-49c9-b593-d223f7449a82
2014-04-01 22:46:00 +00:00
Andrew Ozz
02a46f5368 Add class wp-core-ui to DFW and wpLink as it is required by buttons.css. Props avryl, see #27279
git-svn-id: https://develop.svn.wordpress.org/trunk@27858 602fd350-edb4-49c9-b593-d223f7449a82
2014-03-30 00:36:12 +00:00
Andrew Ozz
d6e6560980 Editor:
- Use standard button styles for the Quicktags buttons.
- Better style for the TinyMCE buttons (hover/focus/active/disabled).
- Move the fullscreen (DFW) button to the right.
- Better style for the Visual/Text buttons in DFW.
Props avryl, see #27279

git-svn-id: https://develop.svn.wordpress.org/trunk@27857 602fd350-edb4-49c9-b593-d223f7449a82
2014-03-29 23:57:13 +00:00
Drew Jaynes (DrewAPicture)
2fc82bee56 Inline documentation for hooks in wp-includes/class-wp-editor.php.
Props kpdesign for some cleanup.
Fixes #27523.


git-svn-id: https://develop.svn.wordpress.org/trunk@27828 602fd350-edb4-49c9-b593-d223f7449a82
2014-03-28 21:32:39 +00:00
Drew Jaynes (DrewAPicture)
815ccdf8f3 Wow. One more time with the typos.
I can, in fact, spell 'instance'.

See #27566.


git-svn-id: https://develop.svn.wordpress.org/trunk@27810 602fd350-edb4-49c9-b593-d223f7449a82
2014-03-28 05:53:42 +00:00
Drew Jaynes (DrewAPicture)
01e30d23b4 Better description and fixed typo for _WP_Editors::parse_settings().
See [27808]. See #27566.


git-svn-id: https://develop.svn.wordpress.org/trunk@27809 602fd350-edb4-49c9-b593-d223f7449a82
2014-03-28 05:50:12 +00:00
Drew Jaynes (DrewAPicture)
f36a1ab9b5 Convert wp_editor() default arguments documentation to a hash notation in the _WP_Editors::parse_settings() PHPDoc.
See #27566.


git-svn-id: https://develop.svn.wordpress.org/trunk@27808 602fd350-edb4-49c9-b593-d223f7449a82
2014-03-28 05:45:54 +00:00
Andrew Ozz
42055c8c93 Add aria-label to the DFW buttons, props joedolson, fixes #26555
git-svn-id: https://develop.svn.wordpress.org/trunk@27766 602fd350-edb4-49c9-b593-d223f7449a82
2014-03-27 01:13:44 +00:00
Andrew Nacin
71917873d4 Introduce HTML5 caption support.
When a theme supports HTML5 captions via add_theme_support( 'html5', 'caption' ), figure and figcaption will be used instead of div and p.

There's a bonus. But first, some history: Captions were introduced with an inline style set for the container. This remains, as it is there to force captions to wrap. But this inline style included an extra 10 pixels, which have vexxed theme developers for years. While these pixels were designed to ensure padding around floated images, modern themes handle this with grace. The additional pixels thus feel encumbering.

As the new HTML5 gallery support avoids outputting default gallery styles (again, irking theme developers for years; see #26697), the new HTML5 caption support will also ditch these 10 pixels of unwanted hand-holding. 

The 10 pixels are also removed entirely in the visual editor (and more styles may also disappear here; see #26642), giving themes the power necessary to match the frontend styles.

The filter img_caption_shortcode_width added in 3.7 to work around this madness (see #14380) is skipped entirely when the theme supports HTML5 captions.

props obenland, azaozz.
see #26642. also fixes #9066.


git-svn-id: https://develop.svn.wordpress.org/trunk@27668 602fd350-edb4-49c9-b593-d223f7449a82
2014-03-24 02:04:56 +00:00
Andrew Ozz
00cb862f5e TinyMCE:
- Fix PressThis styling when the popup is resized.
- Don't force loading of the media JS.
- Add the 'image' plugin as fallback when no media button(s).
- Add back the link icon tooltip/menu item string for translation.
See #24067, see #24409


git-svn-id: https://develop.svn.wordpress.org/trunk@27660 602fd350-edb4-49c9-b593-d223f7449a82
2014-03-23 07:09:23 +00:00
Helen Hou-Sandi
ae8cea0f82 Add the version string to wp-content.css to avoid tenacious caching woes. see #27320.
git-svn-id: https://develop.svn.wordpress.org/trunk@27629 602fd350-edb4-49c9-b593-d223f7449a82
2014-03-20 01:07:36 +00:00
Andrew Nacin
506d92e2fe TinyMCE strings: Merge, remove, reorganize, restore, clarify.
see #27453, #24067.


git-svn-id: https://develop.svn.wordpress.org/trunk@27618 602fd350-edb4-49c9-b593-d223f7449a82
2014-03-19 07:17:07 +00:00
Scott Taylor
86722dfaaa Load MediaElement's CSS when TinyMCE is loaded via $mce_css in editor_settings(). Add some baseline styles in wp-content.css for audio, video, and embed tags to ensure their max-width is 100%, regardless of whether MEjs is implemented in TinyMCE.
See #27389.



git-svn-id: https://develop.svn.wordpress.org/trunk@27534 602fd350-edb4-49c9-b593-d223f7449a82
2014-03-14 12:33:24 +00:00
Andrew Ozz
83501070d5 Modals: darken all overlays, update all box-shadows and headings, correct thickbox styling, make the link modal narrower and bring back the animation (css transition). Props avryl, see #26952
git-svn-id: https://develop.svn.wordpress.org/trunk@27532 602fd350-edb4-49c9-b593-d223f7449a82
2014-03-14 05:54:16 +00:00
Scott Taylor
bb02b06ad4 Revert [27528] until Flash in Firefox behaves :(
See #27389.



git-svn-id: https://develop.svn.wordpress.org/trunk@27530 602fd350-edb4-49c9-b593-d223f7449a82
2014-03-13 23:38:14 +00:00
Scott Taylor
1c7d92ba50 Add MCE Views for audio and video. Please clear your browser cache so that you get the latest TinyMCE stylesheet.
* Move TinyMCE shortcode handling from `wpgallery` plugin to `mce-view.js`
* Force `preload="none"` when rendering media in the editor to ensure fast loading (I realize this sounds illogical)
* Move audio and video tag builder logic in `media-template.php` into PHP funcs that can be reused by any code passing `data.model` to an Underscore template
* Pause all players when moving between editor tabs and when moving from the editor to editing in the media modal.
* Rename `wp.media.audio|video.shortcode()` to the more appropriate `wp.media.audio|video.update()` that now returns a `wp.shortcode` object instead of a string.
* Add necessary MediaElement css files to `$mce_css`
* In `wp.mce.View.render()`, support multiple instances of the same shortcode
* When rendering `wp.mce.View`s, fire a ready event that passes the current MCE View root element as context 

See #27389.



git-svn-id: https://develop.svn.wordpress.org/trunk@27528 602fd350-edb4-49c9-b593-d223f7449a82
2014-03-13 23:09:06 +00:00
Andrew Ozz
0336d4c265 wpLink: bring back the Cancel link, improve responsive styles, see #26952
git-svn-id: https://develop.svn.wordpress.org/trunk@27510 602fd350-edb4-49c9-b593-d223f7449a82
2014-03-12 03:06:11 +00:00
Andrew Ozz
7812a3fa77 wpLink: stop using UI dialog, restyle the modal, add better responsive behaviour.
Fix UI dialog styling to match the rest of the admin styling.
Props avryl, see #26952

git-svn-id: https://develop.svn.wordpress.org/trunk@27494 602fd350-edb4-49c9-b593-d223f7449a82
2014-03-11 00:03:54 +00:00
Andrew Ozz
bb00c66c6a TinyMCE:
- Restore the "link" button state to disabled by default and enabled when text or image is selected.
- Remove the (recently added) default `link` plugin, not needed for `wpLink`.
See #27309

git-svn-id: https://develop.svn.wordpress.org/trunk@27447 602fd350-edb4-49c9-b593-d223f7449a82
2014-03-07 02:01:07 +00:00
Andrew Ozz
0074157b8d TinyMCE: add the <hr> plugin and button, see #27159
git-svn-id: https://develop.svn.wordpress.org/trunk@27428 602fd350-edb4-49c9-b593-d223f7449a82
2014-03-06 00:53:40 +00:00
Andrew Ozz
57ac5b6015 Update mce-view.js and the wpview TinyMCE plugin, and use them to show gallery previews in the Visual editor, props gcorne, see #26959
git-svn-id: https://develop.svn.wordpress.org/trunk@27408 602fd350-edb4-49c9-b593-d223f7449a82
2014-03-05 07:00:18 +00:00
Andrew Ozz
f0c491968a DFW: revert adding the 'image' button, images are edited in the media modal. See #24067.
git-svn-id: https://develop.svn.wordpress.org/trunk@27391 602fd350-edb4-49c9-b593-d223f7449a82
2014-03-04 04:07:31 +00:00
Andrew Ozz
e1028cfc7b Editor: when TinyMCE is used, add autocomplete="off" to the textarea to prevent problems with missing <p> tags when the user reloads the page or uses Go Back/Go Forward buttons, and when editing the same post from two different windows. The autocomplete can be removed with the the_editor filter. Part props xsonic, fixes #27251.
git-svn-id: https://develop.svn.wordpress.org/trunk@27366 602fd350-edb4-49c9-b593-d223f7449a82
2014-03-03 01:14:27 +00:00
Andrew Ozz
8cae5c7ab7 Editor: look at the class of the wrapper element instead of getUserSetting('editor') to determine the default editor, fixes #27257
git-svn-id: https://develop.svn.wordpress.org/trunk@27364 602fd350-edb4-49c9-b593-d223f7449a82
2014-03-02 23:25:25 +00:00
Andrew Ozz
58fe64750d Set wpActiveEditor to the id of the first instance on init, props kovshenin, fixes #27210.
git-svn-id: https://develop.svn.wordpress.org/trunk@27270 602fd350-edb4-49c9-b593-d223f7449a82
2014-02-25 19:30:46 +00:00
Andrew Ozz
377c5520ea TinyMCE: revert style for the blocks drop-down in the toolbar, limit the styles imported for the same drop-down, make the menu highlight color grey. Part props avryl, see #26952
git-svn-id: https://develop.svn.wordpress.org/trunk@27193 602fd350-edb4-49c9-b593-d223f7449a82
2014-02-19 03:50:09 +00:00
Andrew Ozz
fd19c371d1 Edit image in TinyMCE:
- Add a "toolbar" at the top of the image with two buttons: Edit and Delete.
- Don't open the edit modal on second click on the image. Makes the "edit" button somewhat pointless and can sometimes trigger after resizing the image.
- When the image has caption: attempt to prevent IE11 from making the caption element resizable and wrapping it in thick border.
- When the caret is inside a caption next to the image, pressing Enter will create a new <p> tag above the caption.
- Hide the image toolbar on drag, cut, align.
Props gcorne, see #24409.

git-svn-id: https://develop.svn.wordpress.org/trunk@27159 602fd350-edb4-49c9-b593-d223f7449a82
2014-02-10 23:47:34 +00:00
Andrew Ozz
b33135c08d When using wp_editor(), make it easier to specify which editor is shown first, fixes #20822
git-svn-id: https://develop.svn.wordpress.org/trunk@27093 602fd350-edb4-49c9-b593-d223f7449a82
2014-02-05 00:33:49 +00:00
Andrew Ozz
ced0079d88 TinyMCE: update to 4.0.14. Remove the fix for using init.setup in old plugins, now fixed upstream. See #24067.
git-svn-id: https://develop.svn.wordpress.org/trunk@27060 602fd350-edb4-49c9-b593-d223f7449a82
2014-01-31 00:05:17 +00:00
Andrew Ozz
20f89d7c4b Introduce Edit Image (single mode) in the media modal and use it to edit images inserted in the editor. Adds new feature: replace an image in the editor. Props gcorne, see #24409.
git-svn-id: https://develop.svn.wordpress.org/trunk@27050 602fd350-edb4-49c9-b593-d223f7449a82
2014-01-28 21:16:42 +00:00
Andrew Ozz
be31ef4b65 TinyMCE: fix the compat3x plugin appending 'en.' to button titles. Set charset to UTF-8 in html_entity_decode() for translated strings. See #24067, see #26875.
git-svn-id: https://develop.svn.wordpress.org/trunk@27030 602fd350-edb4-49c9-b593-d223f7449a82
2014-01-25 01:20:04 +00:00
Andrew Ozz
5aa4902c7d TinyMCE: fix initializing TinyMCE when the default editor in getUserSetting() is overridden from PHP by using the 'wp_default_editor' filter. See #24067.
git-svn-id: https://develop.svn.wordpress.org/trunk@27004 602fd350-edb4-49c9-b593-d223f7449a82
2014-01-22 18:16:39 +00:00
Andrew Ozz
ae49162491 TinyMCE: fix 3.x callbacks added with init.setup as they run before the compat3x plugin is loaded. Ideally this will be fixed internally in TinyMCE, see #24067.
git-svn-id: https://develop.svn.wordpress.org/trunk@26982 602fd350-edb4-49c9-b593-d223f7449a82
2014-01-18 22:19:07 +00:00
Andrew Ozz
57a26d2e31 TinyMCE: remove the 'spellchecker' plugin. It has been disabled for a while and the back-end currently doesn't work. See #24067.
git-svn-id: https://develop.svn.wordpress.org/trunk@26958 602fd350-edb4-49c9-b593-d223f7449a82
2014-01-15 19:06:26 +00:00
Andrew Ozz
1e3460cea3 TinyMCE: re-enable soft resizing of images inside the editor. See #24067.
git-svn-id: https://develop.svn.wordpress.org/trunk@26934 602fd350-edb4-49c9-b593-d223f7449a82
2014-01-13 01:12:20 +00:00
Andrew Ozz
f6d42a08e9 TinyMCE: back-compat, refresh and re-enable the 'wpdialogs' plugin, and mark it as deprecated. See #24067.
git-svn-id: https://develop.svn.wordpress.org/trunk@26899 602fd350-edb4-49c9-b593-d223f7449a82
2014-01-03 02:33:00 +00:00
Andrew Ozz
9bf024f8f3 Thickbox is needed for the media modal back-compat. Are there plugins that still use this? Also needed for PressThis. See #24067.
git-svn-id: https://develop.svn.wordpress.org/trunk@26898 602fd350-edb4-49c9-b593-d223f7449a82
2014-01-02 22:49:00 +00:00
Andrew Ozz
17f36f016a DFW: fix buttons and the title width, make the fade out/in when opening and closing a bit faster. See #24067.
git-svn-id: https://develop.svn.wordpress.org/trunk@26896 602fd350-edb4-49c9-b593-d223f7449a82
2014-01-02 04:17:28 +00:00
Andrew Ozz
6409324446 Set wpActiveEditor as soon as any editor associated button is clicked, including Add Media, switching Text to Visual, etc. Fixes #26747.
git-svn-id: https://develop.svn.wordpress.org/trunk@26881 602fd350-edb4-49c9-b593-d223f7449a82
2013-12-30 19:16:49 +00:00
Andrew Ozz
14ace125ee TinyMCE 4.0.12, first run.
- Removes wp-tinymce-schema.js and mark-loaded.js, no longer needed.
- Removes the inlinepopups and most of the wpdialogs plugins; wpdialog.js is moved to wp-includes/js.
- Adds charmap, compat3x, image, link and textcolor plugins, previously contained in /themes/advanced.
- Updates the wordpress, wpeditimage, wpfullscreen, wpgallery and wplink plugins.
- Updates DFW, wp-admin/js/wp-fullscreen.js.
See #24067.

git-svn-id: https://develop.svn.wordpress.org/trunk@26876 602fd350-edb4-49c9-b593-d223f7449a82
2013-12-28 23:52:04 +00:00
Andrew Ozz
36536bce2f Fix the editor switching tabs position on small screens, props ryelle, fixes #26151.
git-svn-id: https://develop.svn.wordpress.org/trunk@26315 602fd350-edb4-49c9-b593-d223f7449a82
2013-11-22 02:22:15 +00:00
Andrew Nacin
23ad7058fb Internal linking: Remove explicit orderby, thus allowing the relevancy improvements in #7394 to work.
see #25763.


git-svn-id: https://develop.svn.wordpress.org/trunk@25988 602fd350-edb4-49c9-b593-d223f7449a82
2013-10-29 21:20:59 +00:00
Sergey Biryukov
6f6decc3f2 Document 'wp_link_query_args' and 'wp_link_query' filters. props DrewAPicture. fixes #18042.
git-svn-id: https://develop.svn.wordpress.org/trunk@25299 602fd350-edb4-49c9-b593-d223f7449a82
2013-09-07 19:46:26 +00:00
Sergey Biryukov
f6b4d33ae9 Add 'wp_link_query_args' and 'wp_link_query' filters to allow for customizing the internal linking dialog. props CoenJacobs, goldenapples. fixes #18042.
git-svn-id: https://develop.svn.wordpress.org/trunk@25293 602fd350-edb4-49c9-b593-d223f7449a82
2013-09-07 12:20:57 +00:00
Andrew Nacin
b43712e0f7 New develop.svn.wordpress.org repository based on the old core.svn repository.
* All WordPress files move to a src/ directory.
 * New task runner (Grunt), configured to copy a built WordPress to build/.
 * svn:ignore and .gitignore for Gruntfile.js, wp-config.php, and node.js.
 * Remove Akismet external from develop.svn. Still exists in core.svn.
 * Drop minified files from src/. The build process will now generate these.

props koop.
see #24976.

and see http://wp.me/p2AvED-1AI.



git-svn-id: https://develop.svn.wordpress.org/trunk@25001 602fd350-edb4-49c9-b593-d223f7449a82
2013-08-07 05:25:25 +00:00