Andrew Ozz
0186bbcb95
TinyMCE wpView:
...
- Fix editor undo levels.
- Remove views and markers in the DOM before serialization.
- Unbind views before removing them on hide.
- Empty the content in the timeout, so it doesn't render iframes twice.
Props iseulde. Fixes #31669 .
Built from https://develop.svn.wordpress.org/trunk@32022
git-svn-id: http://core.svn.wordpress.org/trunk@32001 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-04-04 23:00:26 +00:00
Scott Taylor
5855cb0e60
When editing an image from the editor, and the image has a value for alignment (but not for width
or caption
), don't bail without first checking that the alignment's value is not alignnone
. If so, add the class
to the <a>
before bailing.
...
See #21848 .
Built from https://develop.svn.wordpress.org/trunk@31958
git-svn-id: http://core.svn.wordpress.org/trunk@31937 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-04-01 16:04:27 +00:00
Andrew Ozz
e053979219
Emoji:
...
- Enhance twemoji.js to support passing of additional attributes for the replacement images.
- Use that to add the needed attributes when replacing emoji inside the editor.
Fixes #31627 .
Built from https://develop.svn.wordpress.org/trunk@31948
git-svn-id: http://core.svn.wordpress.org/trunk@31927 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-04-01 02:39:28 +00:00
Andrew Ozz
5fe7be9757
TinyMCE emoji: fix caret position after replacing emoji in Chrome on Windows 8.
...
See #31627 .
Built from https://develop.svn.wordpress.org/trunk@31946
git-svn-id: http://core.svn.wordpress.org/trunk@31925 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-03-31 23:35:26 +00:00
Andrew Ozz
b5643f9a13
TinyMCE wpView: add back the removal of selected views on inserting new content. Was removed when reverting the first fix for embedding of pasted URLs.
...
Props mattheu. Fixes #31796 .
Built from https://develop.svn.wordpress.org/trunk@31931
git-svn-id: http://core.svn.wordpress.org/trunk@31910 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-03-30 18:22:27 +00:00
Andrew Ozz
8ff664171d
Remove unused vars. See #31627 .
...
Built from https://develop.svn.wordpress.org/trunk@31923
git-svn-id: http://core.svn.wordpress.org/trunk@31902 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-03-30 02:50:27 +00:00
Andrew Ozz
f128f08c2c
TinyMCE emoji: catch the inserting of emoji chars with the Windows 8 onscreen keyboard and replace if needed.
...
Fixes #31627 .
Built from https://develop.svn.wordpress.org/trunk@31922
git-svn-id: http://core.svn.wordpress.org/trunk@31901 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-03-30 02:39:28 +00:00
Andrew Ozz
1b2d93fbca
TinyMCE: make sure the editor is not completely empty before checking if the user clicked above or below a wpView.
...
Fixes #31765 .
Built from https://develop.svn.wordpress.org/trunk@31888
git-svn-id: http://core.svn.wordpress.org/trunk@31867 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-03-25 18:55:29 +00:00
Andrew Ozz
990f1b43a8
TinyMCE: pad empty paragraphs with <br>
in Chrome to stop it from inserting non-breaking spaces in them.
...
Props iseulde. Fixes #31255 .
Built from https://develop.svn.wordpress.org/trunk@31878
git-svn-id: http://core.svn.wordpress.org/trunk@31857 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-03-25 01:18:26 +00:00
Andrew Ozz
4bb5d76abc
TinyMCE: when pasting an URL, check if the node it is pasted at is empty and remove any empty inline child elements.
...
Fixes #31158 .
Built from https://develop.svn.wordpress.org/trunk@31856
git-svn-id: http://core.svn.wordpress.org/trunk@31835 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-03-20 20:34:28 +00:00
Andrew Ozz
78f0ca13c5
TinyMCE: revert stripping of tags from pasted URLs on beforeSetContent
[31817] and [31819]. Clean up URLs on pastePreProcess
.
...
See #31158 .
Built from https://develop.svn.wordpress.org/trunk@31832
git-svn-id: http://core.svn.wordpress.org/trunk@31814 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-03-19 07:08:26 +00:00
Andrew Ozz
8d9fc7e51b
TinyMCE emoji: fix highlighting of selected replacement images in Chrome.
...
Props iseulde. Fixes #31628 .
Built from https://develop.svn.wordpress.org/trunk@31822
git-svn-id: http://core.svn.wordpress.org/trunk@31804 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-03-18 21:54:26 +00:00
Andrew Ozz
aa9e920e57
TinyMCE: small cleanup for stripping of tags from pasted URLs. See #31158 .
...
Built from https://develop.svn.wordpress.org/trunk@31819
git-svn-id: http://core.svn.wordpress.org/trunk@31801 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-03-18 20:53:27 +00:00
Andrew Ozz
b30d15cd4a
TinyMCE: strip tags from pasted URLs before testing if they are embeddable.
...
Props siobhan, iseulde. Fixes #31158 .
Built from https://develop.svn.wordpress.org/trunk@31817
git-svn-id: http://core.svn.wordpress.org/trunk@31799 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-03-18 20:26:26 +00:00
Andrew Ozz
c18ef513a0
Emoji: fix few typos. See #31242 .
...
Built from https://develop.svn.wordpress.org/trunk@31787
git-svn-id: http://core.svn.wordpress.org/trunk@31767 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-03-15 23:29:26 +00:00
Andrew Ozz
a7fd4a3774
Emoji:
...
- Add the styling for the replacement images to the admin CSS.
- Revert to using `.emoji` as replacement image class.
- When pasting in the editor, convert emoji images to our format so we can replace them with chars on saving.
- Some more clean up of both the plugin and wp-emoji.js.
See #31242 .
Built from https://develop.svn.wordpress.org/trunk@31786
git-svn-id: http://core.svn.wordpress.org/trunk@31766 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-03-15 23:16:29 +00:00
Andrew Ozz
8a402aa701
Emoji:
...
- Move the TinyMCE plugin CSS to wp-content.css.
- Change the replacement images class to `wp-emoji` inside the editor.
- Clean up both the plugin and wp-emoji.js, abstract and restructure a bit.
See #31242 .
Built from https://develop.svn.wordpress.org/trunk@31779
git-svn-id: http://core.svn.wordpress.org/trunk@31759 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-03-14 23:49:30 +00:00
Andrew Ozz
731f7c500d
TinyMCE: fix emoji parsing in IE typo. See #31242 .
...
Built from https://develop.svn.wordpress.org/trunk@31762
git-svn-id: http://core.svn.wordpress.org/trunk@31743 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-03-12 23:03:26 +00:00
Andrew Ozz
b20119d92f
TinyMCE: fix emoji parsing in IE. See #31242 .
...
Built from https://develop.svn.wordpress.org/trunk@31761
git-svn-id: http://core.svn.wordpress.org/trunk@31742 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-03-12 23:00:27 +00:00
Gary Pendergast
b7546d798f
Emoji: Instead of having custom hooks for Ajax callbacks, use MutationObserver to re-parse any changed elements in the DOM.
...
Props iseulde
See #31242
Built from https://develop.svn.wordpress.org/trunk@31750
git-svn-id: http://core.svn.wordpress.org/trunk@31731 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-03-12 12:52:26 +00:00
Andrew Nacin
78679bfb3f
Emoji JS cleanup.
...
* Filename: emoji.js => wp-emoji.js
* Script handle: emoji => wp-emoji
* Object: WPEmoji => wp.emoji
* Script settings: EmojiSettings => _wpemojiSettings
* Setting key: base_url => baseUrl
* Remove executable bit from files
see #31242 .
Built from https://develop.svn.wordpress.org/trunk@31744
git-svn-id: http://core.svn.wordpress.org/trunk@31725 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-03-12 03:17:26 +00:00
Andrew Ozz
8b53e5470d
TinyMCE: remove blocking of commands on placeholder images. Breaks some execCommand.
...
Props iseulde. Fixes #31571 .
Built from https://develop.svn.wordpress.org/trunk@31738
git-svn-id: http://core.svn.wordpress.org/trunk@31719 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-03-11 23:33:28 +00:00
Gary Pendergast
46e2a65cf1
Add emoji support, with Twemoji fallback.
...
Replace exisiting smilies with equivalent emoji, or with shiny new smiley images where no emoji existed.
Props batmoo, joen and mkaz for the original plugin upon which this is based.
Props pento, iseulde, kraftbj and peterwilsoncc for making the internet's dreams come true.
See #31242
Built from https://develop.svn.wordpress.org/trunk@31733
git-svn-id: http://core.svn.wordpress.org/trunk@31714 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-03-11 22:49:28 +00:00
Andrew Ozz
7d2b380330
TinyMCE: initialize the floating toolbars on preinit so we can attach other events on init.
...
Props iseulde. Fixes #30619 .
Built from https://develop.svn.wordpress.org/trunk@31732
git-svn-id: http://core.svn.wordpress.org/trunk@31713 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-03-11 22:41:26 +00:00
Andrew Ozz
9c09d0ea2c
TinyMCE, floating toolbars: return early if no selected element in the editor. See #30619 .
...
Built from https://develop.svn.wordpress.org/trunk@31727
git-svn-id: http://core.svn.wordpress.org/trunk@31708 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-03-11 20:08:27 +00:00
Andrew Ozz
6e14ff9234
TinyMCE:
...
- Abstract the code for creating floating toolbars.
- Introduce `editor.wp` namespace to hold exported methods from our plugins.
- Create the wpView toolbar(s) with the new method. This makes them work the same as the image toolbar: shortcuts, esc key, etc.
Props iseulde. See #30619 .
Built from https://develop.svn.wordpress.org/trunk@31725
git-svn-id: http://core.svn.wordpress.org/trunk@31706 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-03-11 19:12:28 +00:00
Andrew Ozz
eb878043a5
wpLink: change the text label to Link text, always focus the URK field, fix Ctrl/Cmd + K shortcut. See #28206 .
...
Built from https://develop.svn.wordpress.org/trunk@31714
git-svn-id: http://core.svn.wordpress.org/trunk@31695 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-03-11 03:01:27 +00:00
Andrew Ozz
9029c07592
wpLink: replace the "Title" field with a "Text" field and populate it with the link text when editing an existing link or with the selected text if any.
...
Props iseulde. See #28206 .
Built from https://develop.svn.wordpress.org/trunk@31713
git-svn-id: http://core.svn.wordpress.org/trunk@31694 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-03-11 02:40:27 +00:00
Andrew Ozz
9da43ab993
TinyMCE: Remove old placeholder functions and callbacks.
...
Props iseulde. Fixes #31576 .
Built from https://develop.svn.wordpress.org/trunk@31703
git-svn-id: http://core.svn.wordpress.org/trunk@31684 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-03-10 20:28:26 +00:00
Andrew Ozz
5de66d4176
TinyMCE: update to 4.1.9. Fixes #31551 .
...
Built from https://develop.svn.wordpress.org/trunk@31700
git-svn-id: http://core.svn.wordpress.org/trunk@31681 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-03-10 19:20:28 +00:00
Andrew Ozz
d08bb970ae
TinyMCE: when pasting an URL over a selection, insert a link with the URL instead of replacing the selection with it. Props iseulde. Fixes #31571 .
...
Built from https://develop.svn.wordpress.org/trunk@31691
git-svn-id: http://core.svn.wordpress.org/trunk@31672 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-03-09 20:00:27 +00:00
Andrew Ozz
a226da32d3
TinyMCE: wpView improvements: introduce getText() and remove() methods, improved getInstance(), better docs. Props iseulde. See #31412 .
...
Built from https://develop.svn.wordpress.org/trunk@31559
git-svn-id: http://core.svn.wordpress.org/trunk@31540 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-02-26 19:32:24 +00:00
Andrew Ozz
5f27c59f49
TinyMCE: wpView improvements: remove the (obsolete) get/setViewText methods. Update stopping/pausing of multiple ME media players. Props iseulde. See #31412 .
...
Built from https://develop.svn.wordpress.org/trunk@31548
git-svn-id: http://core.svn.wordpress.org/trunk@31529 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-02-26 00:31:31 +00:00
Andrew Ozz
b799bd8e33
TinyMCE: wpView improvements:
...
- Better structure, simpler "view" registration, better extensibility.
- Better inline documentation.
- Don't show a placeholder for pasted link until we know the link is "embeddable'.
And many more improvements. Props iseulde. See #31412 .
Built from https://develop.svn.wordpress.org/trunk@31546
git-svn-id: http://core.svn.wordpress.org/trunk@31527 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-02-25 23:13:25 +00:00
Andrew Ozz
c8892dfaa2
TinyMCE: ensure the image toolbar stays visible when the image is much wider than the editor. Props iseulde, fixes #20696 for trunk.
...
Built from https://develop.svn.wordpress.org/trunk@31362
git-svn-id: http://core.svn.wordpress.org/trunk@31343 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-02-06 23:00:23 +00:00
Andrew Ozz
00436f6886
TinyMCE: fix vertical positioning of the image toolbar when there are several instances of the editor. Props avryl, fixes #31028 .
...
Built from https://develop.svn.wordpress.org/trunk@31235
git-svn-id: http://core.svn.wordpress.org/trunk@31216 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-01-18 17:56:23 +00:00
Andrew Ozz
a7dcd2d736
TinyMCE: select the iframe element by id. Needed as some browser extensions insert extra elements in the page. Props avryl, see #30785 .
...
Built from https://develop.svn.wordpress.org/trunk@31180
git-svn-id: http://core.svn.wordpress.org/trunk@31161 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-01-14 21:33:25 +00:00
Andrew Ozz
d079899553
TinyMCE wpView: when clicking in the editor optimize the caret placement before or after a view. Props avryl, fixes #30938 .
...
Built from https://develop.svn.wordpress.org/trunk@31143
git-svn-id: http://core.svn.wordpress.org/trunk@31124 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-01-11 20:42:23 +00:00
Scott Taylor
618c5b4333
When outputting JS with a Content-Type
header:
...
`text/javascript` is obsolete, `application/x-javascript` was experimental. `application/javascript` is the recommended type per RFC 4329.
Props sergej.mueller.
Fixes #29196 .
Built from https://develop.svn.wordpress.org/trunk@31029
git-svn-id: http://core.svn.wordpress.org/trunk@31010 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-01-03 02:57:21 +00:00
Andrew Ozz
441b47b28f
TinyMCE wpView: when clicking on the Edit button, move the focus back to the editor before opening the modal. This is needed for IE so TinyMCE can save the proper DOM "bookmark", and makes it possible to move the focus to the modal after it is opened.
...
See #30817 .
Built from https://develop.svn.wordpress.org/trunk@30986
git-svn-id: http://core.svn.wordpress.org/trunk@30972 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-22 21:31:26 +00:00
Andrew Nacin
8c3027c3c7
Call it 'Distraction-free writing mode' and update the help string. fixes #30657 .
...
Built from https://develop.svn.wordpress.org/trunk@30890
git-svn-id: http://core.svn.wordpress.org/trunk@30880 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-16 10:07:23 +00:00
Andrew Ozz
9f2fc255f8
TinyMCE: add another Edit
translatable string for the tooltip of the Edit button on the image toolbar. Props pavelevap, see #30694 .
...
Built from https://develop.svn.wordpress.org/trunk@30839
git-svn-id: http://core.svn.wordpress.org/trunk@30829 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-13 00:47:22 +00:00
Andrew Ozz
b90c024d38
TinyMCE: remove reposition delay on showing the image toolbar. Not needed when no animation. Fixes #30670 .
...
Built from https://develop.svn.wordpress.org/trunk@30829
git-svn-id: http://core.svn.wordpress.org/trunk@30819 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-12 00:10:25 +00:00
Andrew Ozz
498c5d719c
TinyMCE: return focus to the editor after closing the image toolbar. Props afercia, see #27642 .
...
Built from https://develop.svn.wordpress.org/trunk@30775
git-svn-id: http://core.svn.wordpress.org/trunk@30765 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-07 20:08:42 +00:00
Andrew Ozz
efe8fd4694
TinyMCE, improve accessibility:
...
- Return focus to the editor on pressing Escape while the image toolbar is focused.
- Add a Close button to the Help modal and close it on Escape.
- Override the title on the editor iframe (read by screen reader apps), replace with the Alt+Shift+H shortcut.
- Add focus shortcuts descriptions to the Help modal.
Fixes #27642 .
Built from https://develop.svn.wordpress.org/trunk@30757
git-svn-id: http://core.svn.wordpress.org/trunk@30747 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-06 23:53:22 +00:00
Andrew Ozz
91b8617f29
TinyMCE: manually fire ExecCommand
when aligning images as we do preventDefault()
on BeforeExecCommand
for them. Props avryl, fixes #30565 .
...
Built from https://develop.svn.wordpress.org/trunk@30748
git-svn-id: http://core.svn.wordpress.org/trunk@30738 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-06 00:33:24 +00:00
Andrew Ozz
d16c8cf1fc
TinyMCE: update the wpView toolbar to look the same as the new image toolbar.
...
Fixes #30561 .
Built from https://develop.svn.wordpress.org/trunk@30694
git-svn-id: http://core.svn.wordpress.org/trunk@30684 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-12-02 00:26:22 +00:00
Andrew Ozz
3ad5115eaf
TinyMCE: update to 4.1.7, changelog: https://github.com/tinymce/tinymce/blob/master/changelog.txt . Fixes #30560 .
...
Built from https://develop.svn.wordpress.org/trunk@30675
git-svn-id: http://core.svn.wordpress.org/trunk@30665 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-11-30 23:28:24 +00:00
Andrew Ozz
9e8f2c7794
Editor: use the Alt+Shift+W keyboard shortcut for new DFW from both the Visual and Text editors. Props afercia, fixes #30450 .
...
Built from https://develop.svn.wordpress.org/trunk@30593
git-svn-id: http://core.svn.wordpress.org/trunk@30583 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-11-28 01:44:22 +00:00
Andrew Ozz
92bcf2dbcb
Remove unused CSS and JS from wp-mce-help.php, see #30517 .
...
Built from https://develop.svn.wordpress.org/trunk@30584
git-svn-id: http://core.svn.wordpress.org/trunk@30574 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-11-26 23:23:23 +00:00