Test internal D&D in the editor, dropping content from an external source (helpers, MS Word) and D&D between editors. Keep in mind that internal D&D is the most complex operation because editor have to handle two ranges at the same time.
+
Expected behavior:
+
+
proper drop position,
+
in the internal and cross editor D&D: dragged content should be removed,
+
dropped content should be (more less) the same as dragged content,
+
paste event should be fired,
+
undo should work properly (one undo operation for one D&D),
+
no crashes, nor errors,
+
+
Drag scenarios:
+
+
drag simple text,
+
drag table cell/cells,
+
drag link,
+
drag helpers textarea content,
+
drag helpers html content,
+
drag content from MS Word.
+
+
Drop scenarios:
+
+
drop in the different paragraph (before and after),
+
drop in the same paragraph (before and after),
+
drop in the same text node (before and after),
+
drop between text lines,
+
drop on the whitespace next to the header,
+
drop on the whitespace on the left side from the quote,
+
drop into a cell.
+
+
Known issues (not part of this ticket):
+
+
because of #11636 dragged content is not correct in some cases (e.g. when you drag part of the link),
+
drag position needs clean up after D&D (e.g. remove empty paragraphs, fix table),
+
drop position needs clean up after D&D (e.g. add spaces before/after dropped content, apply parents styles, break paragraph when one paragraph is dropped at the end to the other paragraph),
+
in the external D&D: Chrome add plenty of addition tags.
Apollo 11 was the spaceflight that landed the first humans, Americans Neil Armstrong and Buzz Aldrin, on the Moon on July 20, 1969, at 20:18 UTC. Armstrong became the first to step onto the lunar surface 6 hours later on July 21 at 02:56 UTC.
+
+
Armstrong spent about three and a half two and a half hours outside the spacecraft, Aldrin slightly less; and together they collected 47.5 pounds (21.5 kg) of lunar material for return to Earth. A third member of the mission, Michael Collins, piloted the command spacecraft alone in lunar orbit until Armstrong and Aldrin returned to it for the trip back to Earth.
+
+
Broadcasting and quotes
+
+
Broadcast on live TV to a world-wide audience, Armstrong stepped onto the lunar surface and described the event as:
+
+
+
One small step for [a] man, one giant leap for mankind.
+
+
+
Apollo 11 effectively ended the Space Race and fulfilled a national goal proposed in 1961 by the late U.S. President John F. Kennedy in a speech before the United States Congress:
+
+
+
[...] before this decade is out, of landing a man on the Moon and returning him safely to the Earth.
+
+
+
Technical details
+
+
+
Mission crew
+
+
+
Position
+
Astronaut
+
+
+
+
+
Commander
+
Neil A. Armstrong
+
+
+
Command Module Pilot
+
Michael Collins
+
+
+
Lunar Module Pilot
+
Edwin "Buzz" E. Aldrin, Jr.
+
+
+
+
+
Launched by a Saturn V rocket from Kennedy Space Center in Merritt Island, Florida on July 16, Apollo 11 was the fifth manned mission of NASA's Apollo program. The Apollo spacecraft had three parts:
+
+
+
Command Module with a cabin for the three astronauts which was the only part which landed back on Earth
+
Service Module which supported the Command Module with propulsion, electrical power, oxygen and water
+
Lunar Module for landing on the Moon.
+
+
+
After being sent to the Moon by the Saturn V's upper stage, the astronauts separated the spacecraft from it and travelled for three days until they entered into lunar orbit. Armstrong and Aldrin then moved into the Lunar Module and landed in the Sea of Tranquility. They stayed a total of about 21 and a half hours on the lunar surface. After lifting off in the upper part of the Lunar Module and rejoining Collins in the Command Module, they returned to Earth and landed in the Pacific Ocean on July 24.
'
+ },
+ {
+ type: 'html',
+ id: 'editing_area',
+ style: 'width:100%;height:100%',
+ html: '',
+ focus: function() {
+ var iframe = this.getInputElement(),
+ doc = iframe.getFrameDocument(),
+ body = doc.getBody();
+
+ // Frame content may not loaded at the moment.
+ if ( !body || body.isReadOnly() )
+ iframe.setCustomData( 'pendingFocus', 1 );
+ else
+ body.focus();
+ },
+ setup: function() {
+ var dialog = this.getDialog();
+ var htmlToLoad = '' +
+ '' +
+ '' +
+ '';
+
+ var src =
+ CKEDITOR.env.air ?
+ 'javascript:void(0)' : // jshint ignore:line
+ ( CKEDITOR.env.ie && !CKEDITOR.env.edge ) ?
+ 'javascript:void((function(){' + encodeURIComponent( // jshint ignore:line
+ 'document.open();' +
+ '(' + CKEDITOR.tools.fixDomain + ')();' +
+ 'document.close();'
+ ) + '})())"'
+ : '';
+
+ var iframe = CKEDITOR.dom.element.createFromHtml( '' );
+
+ // Reset last data transfer.
+ lastDataTransfer = null;
+
+ iframe.on( 'load', function( e ) {
+ e.removeListener();
+
+ var doc = iframe.getFrameDocument();
+ doc.write( htmlToLoad );
+
+ editor.focusManager.add( doc.getBody() );
+
+ if ( CKEDITOR.env.air )
+ onPasteFrameLoad.call( this, doc.getWindow().$ );
+ }, dialog );
+
+ iframe.setCustomData( 'dialog', dialog );
+
+ var container = this.getElement();
+ container.setHtml( '' );
+ container.append( iframe );
+
+ // IE need a redirect on focus to make
+ // the cursor blinking inside iframe. (#5461)
+ if ( CKEDITOR.env.ie && !CKEDITOR.env.edge ) {
+ var focusGrabber = CKEDITOR.dom.element.createFromHtml( '' );
+ focusGrabber.on( 'focus', function() {
+ // Since fixDomain is called in src attribute,
+ // IE needs some slight delay to correctly move focus.
+ setTimeout( function() {
+ iframe.$.contentWindow.focus();
+ } );
+ } );
+ container.append( focusGrabber );
+
+ // Override focus handler on field.
+ this.focus = function() {
+ focusGrabber.focus();
+ this.fire( 'focus' );
+ };
+ }
+
+ this.getInputElement = function() {
+ return iframe;
+ };
+
+ // Force container to scale in IE.
+ if ( CKEDITOR.env.ie ) {
+ container.setStyle( 'display', 'block' );
+ container.setStyle( 'height', ( iframe.$.offsetHeight + 2 ) + 'px' );
+ }
+ },
+ commit: function() {
+ var editor = this.getDialog().getParentEditor(),
+ body = this.getInputElement().getFrameDocument().getBody(),
+ bogus = body.getBogus(),
+ html;
+ bogus && bogus.remove();
+
+ // Saving the contents so changes until paste is complete will not take place (#7500)
+ html = body.getHtml();
+
+ // Opera needs some time to think about what has happened and what it should do now.
+ setTimeout( function() {
+ editor.fire( 'pasteDialogCommit', {
+ dataValue: html,
+ // Avoid error if there was no paste so lastDataTransfer is null.
+ dataTransfer: lastDataTransfer || clipboard.initPasteDataTransfer()
+ } );
+ }, 0 );
+ }
+ }
+ ]
+ } ]
+ };
+} );
+
+/**
+ * Internal event to pass paste dialog's data to the listeners.
+ *
+ * @private
+ * @event pasteDialogCommit
+ * @member CKEDITOR.editor
+ * @param {CKEDITOR.editor} editor This editor instance.
+ */
diff --git a/assets/ckeditor-contrib/plugins/clipboard/icons/copy-rtl.png b/assets/ckeditor-contrib/plugins/clipboard/icons/copy-rtl.png
new file mode 100644
index 00000000..ef724460
Binary files /dev/null and b/assets/ckeditor-contrib/plugins/clipboard/icons/copy-rtl.png differ
diff --git a/assets/ckeditor-contrib/plugins/clipboard/icons/copy.png b/assets/ckeditor-contrib/plugins/clipboard/icons/copy.png
new file mode 100644
index 00000000..ef724460
Binary files /dev/null and b/assets/ckeditor-contrib/plugins/clipboard/icons/copy.png differ
diff --git a/assets/ckeditor-contrib/plugins/clipboard/icons/cut-rtl.png b/assets/ckeditor-contrib/plugins/clipboard/icons/cut-rtl.png
new file mode 100644
index 00000000..0b719653
Binary files /dev/null and b/assets/ckeditor-contrib/plugins/clipboard/icons/cut-rtl.png differ
diff --git a/assets/ckeditor-contrib/plugins/clipboard/icons/cut.png b/assets/ckeditor-contrib/plugins/clipboard/icons/cut.png
new file mode 100644
index 00000000..0b719653
Binary files /dev/null and b/assets/ckeditor-contrib/plugins/clipboard/icons/cut.png differ
diff --git a/assets/ckeditor-contrib/plugins/clipboard/icons/hidpi/copy-rtl.png b/assets/ckeditor-contrib/plugins/clipboard/icons/hidpi/copy-rtl.png
new file mode 100644
index 00000000..29026cc0
Binary files /dev/null and b/assets/ckeditor-contrib/plugins/clipboard/icons/hidpi/copy-rtl.png differ
diff --git a/assets/ckeditor-contrib/plugins/clipboard/icons/hidpi/copy.png b/assets/ckeditor-contrib/plugins/clipboard/icons/hidpi/copy.png
new file mode 100644
index 00000000..29026cc0
Binary files /dev/null and b/assets/ckeditor-contrib/plugins/clipboard/icons/hidpi/copy.png differ
diff --git a/assets/ckeditor-contrib/plugins/clipboard/icons/hidpi/cut-rtl.png b/assets/ckeditor-contrib/plugins/clipboard/icons/hidpi/cut-rtl.png
new file mode 100644
index 00000000..bfec0cfb
Binary files /dev/null and b/assets/ckeditor-contrib/plugins/clipboard/icons/hidpi/cut-rtl.png differ
diff --git a/assets/ckeditor-contrib/plugins/clipboard/icons/hidpi/cut.png b/assets/ckeditor-contrib/plugins/clipboard/icons/hidpi/cut.png
new file mode 100644
index 00000000..bfec0cfb
Binary files /dev/null and b/assets/ckeditor-contrib/plugins/clipboard/icons/hidpi/cut.png differ
diff --git a/assets/ckeditor-contrib/plugins/clipboard/icons/hidpi/paste-rtl.png b/assets/ckeditor-contrib/plugins/clipboard/icons/hidpi/paste-rtl.png
new file mode 100644
index 00000000..f18dac37
Binary files /dev/null and b/assets/ckeditor-contrib/plugins/clipboard/icons/hidpi/paste-rtl.png differ
diff --git a/assets/ckeditor-contrib/plugins/clipboard/icons/hidpi/paste.png b/assets/ckeditor-contrib/plugins/clipboard/icons/hidpi/paste.png
new file mode 100644
index 00000000..f18dac37
Binary files /dev/null and b/assets/ckeditor-contrib/plugins/clipboard/icons/hidpi/paste.png differ
diff --git a/assets/ckeditor-contrib/plugins/clipboard/icons/paste-rtl.png b/assets/ckeditor-contrib/plugins/clipboard/icons/paste-rtl.png
new file mode 100644
index 00000000..b2bfef20
Binary files /dev/null and b/assets/ckeditor-contrib/plugins/clipboard/icons/paste-rtl.png differ
diff --git a/assets/ckeditor-contrib/plugins/clipboard/icons/paste.png b/assets/ckeditor-contrib/plugins/clipboard/icons/paste.png
new file mode 100644
index 00000000..b2bfef20
Binary files /dev/null and b/assets/ckeditor-contrib/plugins/clipboard/icons/paste.png differ
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/af.js b/assets/ckeditor-contrib/plugins/clipboard/lang/af.js
new file mode 100644
index 00000000..20788e49
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/af.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'af', {
+ copy: 'Kopiëer',
+ copyError: 'U blaaier se sekuriteitsinstelling belet die kopiëringsaksie. Gebruik die sleutelbordkombinasie (Ctrl/Cmd+C).',
+ cut: 'Knip',
+ cutError: 'U blaaier se sekuriteitsinstelling belet die outomatiese knip-aksie. Gebruik die sleutelbordkombinasie (Ctrl/Cmd+X).',
+ paste: 'Plak',
+ pasteArea: 'Plak-area',
+ pasteMsg: 'Plak die teks in die volgende teks-area met die sleutelbordkombinasie (Ctrl/Cmd+V) en druk OK.',
+ securityMsg: 'Weens u blaaier se sekuriteitsinstelling is data op die knipbord nie toeganklik nie. U kan dit eers weer in hierdie venster plak.',
+ title: 'Byvoeg'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/ar.js b/assets/ckeditor-contrib/plugins/clipboard/lang/ar.js
new file mode 100644
index 00000000..6bcda427
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/ar.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'ar', {
+ copy: 'نسخ',
+ copyError: 'الإعدادات الأمنية للمتصفح الذي تستخدمه تمنع عمليات النسخ التلقائي. فضلاً إستخدم لوحة المفاتيح لفعل ذلك (Ctrl/Cmd+C).',
+ cut: 'قص',
+ cutError: 'الإعدادات الأمنية للمتصفح الذي تستخدمه تمنع القص التلقائي. فضلاً إستخدم لوحة المفاتيح لفعل ذلك (Ctrl/Cmd+X).',
+ paste: 'لصق',
+ pasteArea: 'منطقة اللصق',
+ pasteMsg: 'الصق داخل الصندوق بإستخدام زرائر (Ctrl/Cmd+V) في لوحة المفاتيح، ثم اضغط زر موافق.',
+ securityMsg: 'نظراً لإعدادات الأمان الخاصة بمتصفحك، لن يتمكن هذا المحرر من الوصول لمحتوى حافظتك، لذلك يجب عليك لصق المحتوى مرة أخرى في هذه النافذة.',
+ title: 'لصق'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/bg.js b/assets/ckeditor-contrib/plugins/clipboard/lang/bg.js
new file mode 100644
index 00000000..a53b8860
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/bg.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'bg', {
+ copy: 'Копирай',
+ copyError: 'Настройките за сигурност на вашия бразуър не разрешават на редактора да изпълни запаметяването. За целта използвайте клавиатурата (Ctrl/Cmd+C).',
+ cut: 'Отрежи',
+ cutError: 'Настройките за сигурност на Вашия браузър не позволяват на редактора автоматично да изъплни действията за отрязване. Моля ползвайте клавиатурните команди за целта (ctrl+x).',
+ paste: 'Вмъкни',
+ pasteArea: 'Зона за вмъкване',
+ pasteMsg: 'Вмъкнете тук съдъжанието с клавиатуарата (Ctrl/Cmd+V) и натиснете OK.',
+ securityMsg: 'Заради настройките за сигурност на Вашия браузър, редакторът не може да прочете данните от клипборда коректно.',
+ title: 'Вмъкни'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/bn.js b/assets/ckeditor-contrib/plugins/clipboard/lang/bn.js
new file mode 100644
index 00000000..e947b503
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/bn.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'bn', {
+ copy: 'কপি',
+ copyError: 'আপনার ব্রাউজারের নিরাপত্তা সেটিংসমূহ এডিটরকে স্বয়ংক্রিয়ভাবে কপি করার প্রক্রিয়া চালনা করার অনুমতি দেয় না। অনুগ্রহপূর্বক এই কাজের জন্য কিবোর্ড ব্যবহার করুন (Ctrl/Cmd+C)।',
+ cut: 'কাট',
+ cutError: 'আপনার ব্রাউজারের সুরক্ষা সেটিংস এডিটরকে অটোমেটিক কাট করার অনুমতি দেয়নি। দয়া করে এই কাজের জন্য কিবোর্ড ব্যবহার করুন (Ctrl/Cmd+X)।',
+ paste: 'পেস্ট',
+ pasteArea: 'Paste Area', // MISSING
+ pasteMsg: 'অনুগ্রহ করে নীচের বাক্সে কিবোর্ড ব্যবহার করে (Ctrl/Cmd+V) পেস্ট করুন এবং OK চাপ দিন',
+ securityMsg: 'Because of your browser security settings, the editor is not able to access your clipboard data directly. You are required to paste it again in this window.', // MISSING
+ title: 'পেস্ট'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/bs.js b/assets/ckeditor-contrib/plugins/clipboard/lang/bs.js
new file mode 100644
index 00000000..abfab5e6
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/bs.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'bs', {
+ copy: 'Kopiraj',
+ copyError: 'Sigurnosne postavke Vašeg pretraživaèa ne dozvoljavaju operacije automatskog kopiranja. Molimo koristite kraticu na tastaturi (Ctrl/Cmd+C).',
+ cut: 'Izreži',
+ cutError: 'Sigurnosne postavke vašeg pretraživaèa ne dozvoljavaju operacije automatskog rezanja. Molimo koristite kraticu na tastaturi (Ctrl/Cmd+X).',
+ paste: 'Zalijepi',
+ pasteArea: 'Paste Area', // MISSING
+ pasteMsg: 'Please paste inside the following box using the keyboard (Ctrl/Cmd+V) and hit OK', // MISSING
+ securityMsg: 'Because of your browser security settings, the editor is not able to access your clipboard data directly. You are required to paste it again in this window.', // MISSING
+ title: 'Zalijepi'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/ca.js b/assets/ckeditor-contrib/plugins/clipboard/lang/ca.js
new file mode 100644
index 00000000..2e172374
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/ca.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'ca', {
+ copy: 'Copiar',
+ copyError: 'La configuració de seguretat del vostre navegador no permet executar automàticament les operacions de copiar. Si us plau, utilitzeu el teclat (Ctrl/Cmd+C).',
+ cut: 'Retallar',
+ cutError: 'La configuració de seguretat del vostre navegador no permet executar automàticament les operacions de retallar. Si us plau, utilitzeu el teclat (Ctrl/Cmd+X).',
+ paste: 'Enganxar',
+ pasteArea: 'Àrea d\'enganxat',
+ pasteMsg: 'Si us plau, enganxi dins del següent camp utilitzant el teclat (Ctrl/Cmd+V) i premi OK.',
+ securityMsg: 'A causa de la configuració de seguretat del vostre navegador, l\'editor no pot accedir a les dades del porta-retalls directament. Enganxeu-ho un altre cop en aquesta finestra.',
+ title: 'Enganxar'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/cs.js b/assets/ckeditor-contrib/plugins/clipboard/lang/cs.js
new file mode 100644
index 00000000..1f8a325d
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/cs.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'cs', {
+ copy: 'Kopírovat',
+ copyError: 'Bezpečnostní nastavení vašeho prohlížeče nedovolují editoru spustit funkci pro kopírování zvoleného textu do schránky. Prosím zkopírujte zvolený text do schránky pomocí klávesnice (Ctrl/Cmd+C).',
+ cut: 'Vyjmout',
+ cutError: 'Bezpečnostní nastavení vašeho prohlížeče nedovolují editoru spustit funkci pro vyjmutí zvoleného textu do schránky. Prosím vyjměte zvolený text do schránky pomocí klávesnice (Ctrl/Cmd+X).',
+ paste: 'Vložit',
+ pasteArea: 'Oblast vkládání',
+ pasteMsg: 'Do následujícího pole vložte požadovaný obsah pomocí klávesnice (Ctrl/Cmd+V) a stiskněte OK.',
+ securityMsg: 'Z důvodů nastavení bezpečnosti vašeho prohlížeče nemůže editor přistupovat přímo do schránky. Obsah schránky prosím vložte znovu do tohoto okna.',
+ title: 'Vložit'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/cy.js b/assets/ckeditor-contrib/plugins/clipboard/lang/cy.js
new file mode 100644
index 00000000..3e7e51a3
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/cy.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'cy', {
+ copy: 'Copïo',
+ copyError: '\'Dyw gosodiadau diogelwch eich porwr ddim yn caniatàu\'r golygydd i gynnal \'gweithredoedd copïo\' yn awtomatig. Defnyddiwch y bysellfwrdd (Ctrl/Cmd+C).',
+ cut: 'Torri',
+ cutError: 'Nid yw gosodiadau diogelwch eich porwr yn caniatàu\'r golygydd i gynnal \'gweithredoedd torri\' yn awtomatig. Defnyddiwch y bysellfwrdd (Ctrl/Cmd+X).',
+ paste: 'Gludo',
+ pasteArea: 'Ardal Gludo',
+ pasteMsg: 'Gludwch i mewn i\'r blwch canlynol gan ddefnyddio\'r bysellfwrdd (Ctrl/Cmd+V) a phwyso Iawn.',
+ securityMsg: 'Oherwydd gosodiadau diogelwch eich porwr, \'dyw\'r porwr ddim yn gallu ennill mynediad i\'r data ar y clipfwrdd yn uniongyrchol. Mae angen i chi ei ludo eto i\'r ffenestr hon.',
+ title: 'Gludo'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/da.js b/assets/ckeditor-contrib/plugins/clipboard/lang/da.js
new file mode 100644
index 00000000..ade5d2c0
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/da.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'da', {
+ copy: 'Kopiér',
+ copyError: 'Din browsers sikkerhedsindstillinger tillader ikke editoren at få automatisk adgang til udklipsholderen.
Brug i stedet tastaturet til at kopiere teksten (Ctrl/Cmd+C).',
+ cut: 'Klip',
+ cutError: 'Din browsers sikkerhedsindstillinger tillader ikke editoren at få automatisk adgang til udklipsholderen.
Brug i stedet tastaturet til at klippe teksten (Ctrl/Cmd+X).',
+ paste: 'Indsæt',
+ pasteArea: 'Indsæt område',
+ pasteMsg: 'Indsæt i feltet herunder (Ctrl/Cmd+V) og klik på OK.',
+ securityMsg: 'Din browsers sikkerhedsindstillinger tillader ikke editoren at få automatisk adgang til udklipsholderen.
Du skal indsætte udklipsholderens indhold i dette vindue igen.',
+ title: 'Indsæt'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/de-ch.js b/assets/ckeditor-contrib/plugins/clipboard/lang/de-ch.js
new file mode 100644
index 00000000..8899b418
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/de-ch.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'de-ch', {
+ copy: 'Kopieren',
+ copyError: 'Die Sicherheitseinstellungen Ihres Browsers lassen es nicht zu, den Text automatisch kopieren. Bitte benutzen Sie die System-Zwischenablage über STRG-C (kopieren).',
+ cut: 'Ausschneiden',
+ cutError: 'Die Sicherheitseinstellungen Ihres Browsers lassen es nicht zu, den Text automatisch auszuschneiden. Bitte benutzen Sie die System-Zwischenablage über STRG-X (ausschneiden) und STRG-V (einfügen).',
+ paste: 'Einfügen',
+ pasteArea: 'Einfügebereich',
+ pasteMsg: 'Bitte fügen Sie den Text in der folgenden Box über die Tastatur (mit Strg+V) ein und bestätigen Sie mit OK.',
+ securityMsg: 'Aufgrund von Sicherheitsbeschränkungen Ihres Browsers kann der Editor nicht direkt auf die Zwischenablage zugreifen. Bitte fügen Sie den Inhalt erneut in diesem Fenster ein.',
+ title: 'Einfügen'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/de.js b/assets/ckeditor-contrib/plugins/clipboard/lang/de.js
new file mode 100644
index 00000000..02ad62bd
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/de.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'de', {
+ copy: 'Kopieren',
+ copyError: 'Die Sicherheitseinstellungen Ihres Browsers lassen es nicht zu, den Text automatisch kopieren. Bitte benutzen Sie die System-Zwischenablage über STRG-C (kopieren).',
+ cut: 'Ausschneiden',
+ cutError: 'Die Sicherheitseinstellungen Ihres Browsers lassen es nicht zu, den Text automatisch auszuschneiden. Bitte benutzen Sie die System-Zwischenablage über STRG-X (ausschneiden) und STRG-V (einfügen).',
+ paste: 'Einfügen',
+ pasteArea: 'Einfügebereich',
+ pasteMsg: 'Bitte fügen Sie den Text in der folgenden Box über die Tastatur (mit Strg+V) ein und bestätigen Sie mit OK.',
+ securityMsg: 'Aufgrund von Sicherheitsbeschränkungen Ihres Browsers kann der Editor nicht direkt auf die Zwischenablage zugreifen. Bitte fügen Sie den Inhalt erneut in diesem Fenster ein.',
+ title: 'Einfügen'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/el.js b/assets/ckeditor-contrib/plugins/clipboard/lang/el.js
new file mode 100644
index 00000000..3345e6c5
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/el.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'el', {
+ copy: 'Αντιγραφή',
+ copyError: 'Οι ρυθμίσεις ασφαλείας του περιηγητή σας δεν επιτρέπουν την επιλεγμένη εργασία αντιγραφής. Παρακαλώ χρησιμοποιείστε το πληκτρολόγιο (Ctrl/Cmd+C).',
+ cut: 'Αποκοπή',
+ cutError: 'Οι ρυθμίσεις ασφαλείας του περιηγητή σας δεν επιτρέπουν την επιλεγμένη εργασία αποκοπής. Παρακαλώ χρησιμοποιείστε το πληκτρολόγιο (Ctrl/Cmd+X).',
+ paste: 'Επικόλληση',
+ pasteArea: 'Περιοχή Επικόλλησης',
+ pasteMsg: 'Παρακαλώ επικολλήστε στο ακόλουθο κουτί χρησιμοποιώντας το πληκτρολόγιο (Ctrl/Cmd+V) και πατήστε OK.',
+ securityMsg: 'Λόγων των ρυθμίσεων ασφάλειας του περιηγητή σας, ο επεξεργαστής δεν μπορεί να έχει πρόσβαση στην μνήμη επικόλλησης. Χρειάζεται να επικολλήσετε ξανά σε αυτό το παράθυρο.',
+ title: 'Επικόλληση'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/en-au.js b/assets/ckeditor-contrib/plugins/clipboard/lang/en-au.js
new file mode 100644
index 00000000..d69123d9
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/en-au.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'en-au', {
+ copy: 'Copy',
+ copyError: 'Your browser security settings don\'t permit the editor to automatically execute copying operations. Please use the keyboard for that (Ctrl/Cmd+C).',
+ cut: 'Cut',
+ cutError: 'Your browser security settings don\'t permit the editor to automatically execute cutting operations. Please use the keyboard for that (Ctrl/Cmd+X).',
+ paste: 'Paste',
+ pasteArea: 'Paste Area', // MISSING
+ pasteMsg: 'Please paste inside the following box using the keyboard (Ctrl/Cmd+V) and hit OK',
+ securityMsg: 'Because of your browser security settings, the editor is not able to access your clipboard data directly. You are required to paste it again in this window.',
+ title: 'Paste'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/en-ca.js b/assets/ckeditor-contrib/plugins/clipboard/lang/en-ca.js
new file mode 100644
index 00000000..bbf3ca72
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/en-ca.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'en-ca', {
+ copy: 'Copy',
+ copyError: 'Your browser security settings don\'t permit the editor to automatically execute copying operations. Please use the keyboard for that (Ctrl/Cmd+C).',
+ cut: 'Cut',
+ cutError: 'Your browser security settings don\'t permit the editor to automatically execute cutting operations. Please use the keyboard for that (Ctrl/Cmd+X).',
+ paste: 'Paste',
+ pasteArea: 'Paste Area', // MISSING
+ pasteMsg: 'Please paste inside the following box using the keyboard (Ctrl/Cmd+V) and hit OK',
+ securityMsg: 'Because of your browser security settings, the editor is not able to access your clipboard data directly. You are required to paste it again in this window.',
+ title: 'Paste'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/en-gb.js b/assets/ckeditor-contrib/plugins/clipboard/lang/en-gb.js
new file mode 100644
index 00000000..3bd9d302
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/en-gb.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'en-gb', {
+ copy: 'Copy',
+ copyError: 'Your browser security settings don\'t permit the editor to automatically execute copying operations. Please use the keyboard for that (Ctrl/Cmd+C).',
+ cut: 'Cut',
+ cutError: 'Your browser security settings don\'t permit the editor to automatically execute cutting operations. Please use the keyboard for that (Ctrl/Cmd+X).',
+ paste: 'Paste',
+ pasteArea: 'Paste Area',
+ pasteMsg: 'Please paste inside the following box using the keyboard (Ctrl/Cmd+V) and hit OK',
+ securityMsg: 'Because of your browser security settings, the editor is not able to access your clipboard data directly. You are required to paste it again in this window.',
+ title: 'Paste'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/en.js b/assets/ckeditor-contrib/plugins/clipboard/lang/en.js
new file mode 100644
index 00000000..6246f97a
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/en.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'en', {
+ copy: 'Copy',
+ copyError: 'Your browser security settings don\'t permit the editor to automatically execute copying operations. Please use the keyboard for that (Ctrl/Cmd+C).',
+ cut: 'Cut',
+ cutError: 'Your browser security settings don\'t permit the editor to automatically execute cutting operations. Please use the keyboard for that (Ctrl/Cmd+X).',
+ paste: 'Paste',
+ pasteArea: 'Paste Area',
+ pasteMsg: 'Please paste inside the following box using the keyboard (Ctrl/Cmd+V) and hit OK',
+ securityMsg: 'Because of your browser security settings, the editor is not able to access your clipboard data directly. You are required to paste it again in this window.',
+ title: 'Paste'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/eo.js b/assets/ckeditor-contrib/plugins/clipboard/lang/eo.js
new file mode 100644
index 00000000..eed67d9a
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/eo.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'eo', {
+ copy: 'Kopii',
+ copyError: 'La sekurecagordo de via TTT-legilo ne permesas, ke la redaktilo faras kopiajn operaciojn. Bonvolu uzi la klavaron por tio (Ctrl/Cmd-C).',
+ cut: 'Eltondi',
+ cutError: 'La sekurecagordo de via TTT-legilo ne permesas, ke la redaktilo faras eltondajn operaciojn. Bonvolu uzi la klavaron por tio (Ctrl/Cmd-X).',
+ paste: 'Interglui',
+ pasteArea: 'Intergluoareo',
+ pasteMsg: 'Bonvolu glui la tekston en la jenan areon per uzado de la klavaro (Ctrl/Cmd+V) kaj premu OK',
+ securityMsg: 'Pro la sekurecagordo de via TTT-legilo, la redaktilo ne povas rekte atingi viajn datenojn en la poŝo. Bonvolu denove interglui la datenojn en tiun fenestron.',
+ title: 'Interglui'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/es.js b/assets/ckeditor-contrib/plugins/clipboard/lang/es.js
new file mode 100644
index 00000000..994032a9
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/es.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'es', {
+ copy: 'Copiar',
+ copyError: 'La configuración de seguridad de este navegador no permite la ejecución automática de operaciones de copiado.\r\nPor favor use el teclado (Ctrl/Cmd+C).',
+ cut: 'Cortar',
+ cutError: 'La configuración de seguridad de este navegador no permite la ejecución automática de operaciones de cortado.\r\nPor favor use el teclado (Ctrl/Cmd+X).',
+ paste: 'Pegar',
+ pasteArea: 'Zona de pegado',
+ pasteMsg: 'Por favor pegue dentro del cuadro utilizando el teclado (Ctrl/Cmd+V);\r\nluego presione Aceptar.',
+ securityMsg: 'Debido a la configuración de seguridad de su navegador, el editor no tiene acceso al portapapeles.\r\nEs necesario que lo pegue de nuevo en esta ventana.',
+ title: 'Pegar'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/et.js b/assets/ckeditor-contrib/plugins/clipboard/lang/et.js
new file mode 100644
index 00000000..b60710b2
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/et.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'et', {
+ copy: 'Kopeeri',
+ copyError: 'Sinu veebisirvija turvaseaded ei luba redaktoril automaatselt kopeerida. Palun kasutage selleks klaviatuuri klahvikombinatsiooni (Ctrl/Cmd+C).',
+ cut: 'Lõika',
+ cutError: 'Sinu veebisirvija turvaseaded ei luba redaktoril automaatselt lõigata. Palun kasutage selleks klaviatuuri klahvikombinatsiooni (Ctrl/Cmd+X).',
+ paste: 'Aseta',
+ pasteArea: 'Asetamise ala',
+ pasteMsg: 'Palun aseta tekst järgnevasse kasti kasutades klaviatuuri klahvikombinatsiooni (Ctrl/Cmd+V) ja vajuta seejärel OK.',
+ securityMsg: 'Sinu veebisirvija turvaseadete tõttu ei oma redaktor otsest ligipääsu lõikelaua andmetele. Sa pead asetama need uuesti siia aknasse.',
+ title: 'Asetamine'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/eu.js b/assets/ckeditor-contrib/plugins/clipboard/lang/eu.js
new file mode 100644
index 00000000..9746931a
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/eu.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'eu', {
+ copy: 'Kopiatu',
+ copyError: 'Zure web nabigatzailearen segurtasun ezarpenek ez dute baimentzen testuak automatikoki kopiatzea. Mesedez teklatua erabil ezazu (Ctrl/Cmd+C).',
+ cut: 'Ebaki',
+ cutError: 'Zure web nabigatzailearen segurtasun ezarpenek ez dute baimentzen testuak automatikoki moztea. Mesedez teklatua erabil ezazu (Ctrl/Cmd+X).',
+ paste: 'Itsatsi',
+ pasteArea: 'Itsasteko area',
+ pasteMsg: 'Mesedez teklatua erabiliz (Ctrl/Cmd+V) ondorengo eremuan testua itsatsi eta sakatu Ados.',
+ securityMsg: 'Nabigatzailearen segurtasun ezarpenak direla eta, editoreak ezin du arbela zuzenean erabili. Leiho honetan berriro itsatsi behar duzu.',
+ title: 'Itsatsi'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/fa.js b/assets/ckeditor-contrib/plugins/clipboard/lang/fa.js
new file mode 100644
index 00000000..1bd18a90
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/fa.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'fa', {
+ copy: 'رونوشت',
+ copyError: 'تنظیمات امنیتی مرورگر شما اجازه نمیدهد که ویرایشگر به طور خودکار عملکردهای کپی کردن را انجام دهد. لطفا با دکمههای صفحه کلید این کار را انجام دهید (Ctrl/Cmd+C).',
+ cut: 'برش',
+ cutError: 'تنظیمات امنیتی مرورگر شما اجازه نمیدهد که ویرایشگر به طور خودکار عملکردهای برش را انجام دهد. لطفا با دکمههای صفحه کلید این کار را انجام دهید (Ctrl/Cmd+X).',
+ paste: 'چسباندن',
+ pasteArea: 'محل چسباندن',
+ pasteMsg: 'لطفا متن را با کلیدهای (Ctrl/Cmd+V) در این جعبهٴ متنی بچسبانید و پذیرش را بزنید.',
+ securityMsg: 'به خاطر تنظیمات امنیتی مرورگر شما، ویرایشگر نمیتواند دسترسی مستقیم به دادههای clipboard داشته باشد. شما باید دوباره آنرا در این پنجره بچسبانید.',
+ title: 'چسباندن'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/fi.js b/assets/ckeditor-contrib/plugins/clipboard/lang/fi.js
new file mode 100644
index 00000000..15a2daf3
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/fi.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'fi', {
+ copy: 'Kopioi',
+ copyError: 'Selaimesi turva-asetukset eivät salli editorin toteuttaa kopioimista. Käytä näppäimistöä kopioimiseen (Ctrl+C).',
+ cut: 'Leikkaa',
+ cutError: 'Selaimesi turva-asetukset eivät salli editorin toteuttaa leikkaamista. Käytä näppäimistöä leikkaamiseen (Ctrl+X).',
+ paste: 'Liitä',
+ pasteArea: 'Leikealue',
+ pasteMsg: 'Liitä painamalla (Ctrl+V) ja painamalla OK.',
+ securityMsg: 'Selaimesi turva-asetukset eivät salli editorin käyttää leikepöytää suoraan. Sinun pitää suorittaa liittäminen tässä ikkunassa.',
+ title: 'Liitä'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/fo.js b/assets/ckeditor-contrib/plugins/clipboard/lang/fo.js
new file mode 100644
index 00000000..ddc726ba
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/fo.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'fo', {
+ copy: 'Avrita',
+ copyError: 'Trygdaruppseting alnótskagans forðar tekstviðgeranum í at avrita tekstin. Vinarliga nýt knappaborðið til at avrita tekstin (Ctrl/Cmd+C).',
+ cut: 'Kvett',
+ cutError: 'Trygdaruppseting alnótskagans forðar tekstviðgeranum í at kvetta tekstin. Vinarliga nýt knappaborðið til at kvetta tekstin (Ctrl/Cmd+X).',
+ paste: 'Innrita',
+ pasteArea: 'Avritingarumráði',
+ pasteMsg: 'Vinarliga koyr tekstin í hendan rútin við knappaborðinum (Ctrl/Cmd+V) og klikk á Góðtak.',
+ securityMsg: 'Trygdaruppseting alnótskagans forðar tekstviðgeranum í beinleiðis atgongd til avritingarminnið. Tygum mugu royna aftur í hesum rútinum.',
+ title: 'Innrita'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/fr-ca.js b/assets/ckeditor-contrib/plugins/clipboard/lang/fr-ca.js
new file mode 100644
index 00000000..f78f4b46
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/fr-ca.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'fr-ca', {
+ copy: 'Copier',
+ copyError: 'Les paramètres de sécurité de votre navigateur empêchent l\'éditeur de copier automatiquement vos données. Veuillez utiliser les équivalents claviers (Ctrl/Cmd+C).',
+ cut: 'Couper',
+ cutError: 'Les paramètres de sécurité de votre navigateur empêchent l\'éditeur de couper automatiquement vos données. Veuillez utiliser les équivalents claviers (Ctrl/Cmd+X).',
+ paste: 'Coller',
+ pasteArea: 'Coller la zone',
+ pasteMsg: 'Veuillez coller dans la zone ci-dessous en utilisant le clavier (Ctrl/Cmd+V) et appuyer sur OK.',
+ securityMsg: 'A cause des paramètres de sécurité de votre navigateur, l\'éditeur ne peut accéder au presse-papier directement. Vous devez coller à nouveau le contenu dans cette fenêtre.',
+ title: 'Coller'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/fr.js b/assets/ckeditor-contrib/plugins/clipboard/lang/fr.js
new file mode 100644
index 00000000..5a254ebc
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/fr.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'fr', {
+ copy: 'Copier',
+ copyError: 'Les paramètres de sécurité de votre navigateur n\'autorisent pas l\'éditeur à exécuter automatiquement l\'opération « Copier ». Veuillez utiliser le raccourci clavier à cet effet (Ctrl/Cmd+C).',
+ cut: 'Couper',
+ cutError: 'Les paramètres de sécurité de votre navigateur n\'autorisent pas l\'éditeur à exécuter automatiquement l\'opération « Couper ». Veuillez utiliser le raccourci clavier à cet effet (Ctrl/Cmd+X).',
+ paste: 'Coller',
+ pasteArea: 'Coller la zone',
+ pasteMsg: 'Veuillez coller le texte dans la zone suivante en utilisant le raccourci clavier (Ctrl/Cmd+V) et cliquez sur OK.',
+ securityMsg: 'Les paramètres de sécurité de votre navigateur empêchent l\'éditeur d\'accéder directement aux données du presse-papier. Vous devez les coller à nouveau dans cette fenêtre.',
+ title: 'Coller'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/gl.js b/assets/ckeditor-contrib/plugins/clipboard/lang/gl.js
new file mode 100644
index 00000000..09c21a61
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/gl.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'gl', {
+ copy: 'Copiar',
+ copyError: 'Os axustes de seguranza do seu navegador non permiten que o editor realice automaticamente as tarefas de copia. Use o teclado para iso (Ctrl/Cmd+C).',
+ cut: 'Cortar',
+ cutError: 'Os axustes de seguranza do seu navegador non permiten que o editor realice automaticamente as tarefas de corte. Use o teclado para iso (Ctrl/Cmd+X).',
+ paste: 'Pegar',
+ pasteArea: 'Zona de pegado',
+ pasteMsg: 'Pegue dentro do seguinte cadro usando o teclado (Ctrl/Cmd+V) e prema en Aceptar',
+ securityMsg: 'Por mor da configuración de seguranza do seu navegador, o editor non ten acceso ao portapapeis. É necesario pegalo novamente nesta xanela.',
+ title: 'Pegar'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/gu.js b/assets/ckeditor-contrib/plugins/clipboard/lang/gu.js
new file mode 100644
index 00000000..96c417e0
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/gu.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'gu', {
+ copy: 'નકલ',
+ copyError: 'તમારા બ્રાઉઝર ની સુરક્ષિત સેટિંગસ કોપી કરવાની પરવાનગી નથી આપતી. (Ctrl/Cmd+C) का प्रयोग करें।',
+ cut: 'કાપવું',
+ cutError: 'તમારા બ્રાઉઝર ની સુરક્ષિત સેટિંગસ કટ કરવાની પરવાનગી નથી આપતી. (Ctrl/Cmd+X) નો ઉપયોગ કરો.',
+ paste: 'પેસ્ટ',
+ pasteArea: 'પેસ્ટ કરવાની જગ્યા',
+ pasteMsg: 'Ctrl/Cmd+V નો પ્રયોગ કરી પેસ્ટ કરો',
+ securityMsg: 'તમારા બ્રાઉઝર ની સુરક્ષિત સેટિંગસના કારણે,એડિટર તમારા કિલ્પબોર્ડ ડેટા ને કોપી નથી કરી શકતો. તમારે આ વિન્ડોમાં ફરીથી પેસ્ટ કરવું પડશે.',
+ title: 'પેસ્ટ'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/he.js b/assets/ckeditor-contrib/plugins/clipboard/lang/he.js
new file mode 100644
index 00000000..cd855100
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/he.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'he', {
+ copy: 'העתקה',
+ copyError: 'הגדרות האבטחה בדפדפן שלך לא מאפשרות לעורך לבצע פעולות העתקה אוטומטיות. יש להשתמש במקלדת לשם כך (Ctrl/Cmd+C).',
+ cut: 'גזירה',
+ cutError: 'הגדרות האבטחה בדפדפן שלך לא מאפשרות לעורך לבצע פעולות גזירה אוטומטיות. יש להשתמש במקלדת לשם כך (Ctrl/Cmd+X).',
+ paste: 'הדבקה',
+ pasteArea: 'איזור הדבקה',
+ pasteMsg: 'נא להדביק בתוך הקופסה באמצעות (Ctrl/Cmd+V) וללחוץ על אישור.',
+ securityMsg: 'עקב הגדרות אבטחה בדפדפן, לא ניתן לגשת אל לוח הגזירים (Clipboard) בצורה ישירה. נא להדביק שוב בחלון זה.',
+ title: 'הדבקה'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/hi.js b/assets/ckeditor-contrib/plugins/clipboard/lang/hi.js
new file mode 100644
index 00000000..198f0416
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/hi.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'hi', {
+ copy: 'कॉपी',
+ copyError: 'आपके ब्राआउज़र की सुरक्षा सॅटिन्ग्स ने कॉपी करने की अनुमति नहीं प्रदान की है। (Ctrl/Cmd+C) का प्रयोग करें।',
+ cut: 'कट',
+ cutError: 'आपके ब्राउज़र की सुरक्षा सॅटिन्ग्स ने कट करने की अनुमति नहीं प्रदान की है। (Ctrl/Cmd+X) का प्रयोग करें।',
+ paste: 'पेस्ट',
+ pasteArea: 'Paste Area', // MISSING
+ pasteMsg: 'Ctrl/Cmd+V का प्रयोग करके पेस्ट करें और ठीक है करें.',
+ securityMsg: 'आपके ब्राउज़र की सुरक्षा आपके ब्राउज़र की सुरKश सैटिंग के कारण, एडिटर आपके क्लिपबोर्ड डेटा को नहीं पा सकता है. आपको उसे इस विन्डो में दोबारा पेस्ट करना होगा.',
+ title: 'पेस्ट'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/hr.js b/assets/ckeditor-contrib/plugins/clipboard/lang/hr.js
new file mode 100644
index 00000000..31034f25
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/hr.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'hr', {
+ copy: 'Kopiraj',
+ copyError: 'Sigurnosne postavke Vašeg pretraživača ne dozvoljavaju operacije automatskog kopiranja. Molimo koristite kraticu na tipkovnici (Ctrl/Cmd+C).',
+ cut: 'Izreži',
+ cutError: 'Sigurnosne postavke Vašeg pretraživača ne dozvoljavaju operacije automatskog izrezivanja. Molimo koristite kraticu na tipkovnici (Ctrl/Cmd+X).',
+ paste: 'Zalijepi',
+ pasteArea: 'Prostor za ljepljenje',
+ pasteMsg: 'Molimo zaljepite unutar doljnjeg okvira koristeći tipkovnicu (Ctrl/Cmd+V) i kliknite OK.',
+ securityMsg: 'Zbog sigurnosnih postavki Vašeg pretraživača, editor nema direktan pristup Vašem međuspremniku. Potrebno je ponovno zalijepiti tekst u ovaj prozor.',
+ title: 'Zalijepi'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/hu.js b/assets/ckeditor-contrib/plugins/clipboard/lang/hu.js
new file mode 100644
index 00000000..2d5ad720
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/hu.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'hu', {
+ copy: 'Másolás',
+ copyError: 'A böngésző biztonsági beállításai nem engedélyezik a szerkesztőnek, hogy végrehajtsa a másolás műveletet. Használja az alábbi billentyűkombinációt (Ctrl/Cmd+X).',
+ cut: 'Kivágás',
+ cutError: 'A böngésző biztonsági beállításai nem engedélyezik a szerkesztőnek, hogy végrehajtsa a kivágás műveletet. Használja az alábbi billentyűkombinációt (Ctrl/Cmd+X).',
+ paste: 'Beillesztés',
+ pasteArea: 'Beszúrás mező',
+ pasteMsg: 'Másolja be az alábbi mezőbe a Ctrl/Cmd+V billentyűk lenyomásával, majd nyomjon Rendben-t.',
+ securityMsg: 'A böngésző biztonsági beállításai miatt a szerkesztő nem képes hozzáférni a vágólap adataihoz. Illeszd be újra ebben az ablakban.',
+ title: 'Beillesztés'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/id.js b/assets/ckeditor-contrib/plugins/clipboard/lang/id.js
new file mode 100644
index 00000000..1c23826f
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/id.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'id', {
+ copy: 'Salin',
+ copyError: 'Pengaturan keamanan peramban anda tidak mengizinkan editor untuk mengeksekusi operasi menyalin secara otomatis. Mohon gunakan papan tuts (Ctrl/Cmd+C)',
+ cut: 'Potong',
+ cutError: 'Your browser security settings don\'t permit the editor to automatically execute cutting operations. Please use the keyboard for that (Ctrl/Cmd+X).', // MISSING
+ paste: 'Tempel',
+ pasteArea: 'Area Tempel',
+ pasteMsg: 'Please paste inside the following box using the keyboard (Ctrl/Cmd+V) and hit OK', // MISSING
+ securityMsg: 'Karena pengaturan keamanan peramban anda, editor tida dapat mengakses data clipboard anda secara langsung. Anda harus mem-paste kembali pada halaman ini',
+ title: 'Tempel'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/is.js b/assets/ckeditor-contrib/plugins/clipboard/lang/is.js
new file mode 100644
index 00000000..c93790d6
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/is.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'is', {
+ copy: 'Afrita',
+ copyError: 'Öryggisstillingar vafrans þíns leyfa ekki afritun texta með músaraðgerð. Notaðu lyklaborðið í afrita (Ctrl/Cmd+C).',
+ cut: 'Klippa',
+ cutError: 'Öryggisstillingar vafrans þíns leyfa ekki klippingu texta með músaraðgerð. Notaðu lyklaborðið í klippa (Ctrl/Cmd+X).',
+ paste: 'Líma',
+ pasteArea: 'Paste Area', // MISSING
+ pasteMsg: 'Límdu í svæðið hér að neðan og (Ctrl/Cmd+V) og smelltu á OK.',
+ securityMsg: 'Vegna öryggisstillinga í vafranum þínum fær ritillinn ekki beinan aðgang að klippuborðinu. Þú verður að líma innihaldið aftur inn í þennan glugga.',
+ title: 'Líma'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/it.js b/assets/ckeditor-contrib/plugins/clipboard/lang/it.js
new file mode 100644
index 00000000..3a707fff
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/it.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'it', {
+ copy: 'Copia',
+ copyError: 'Le impostazioni di sicurezza del browser non permettono di copiare automaticamente il testo. Usa la tastiera (Ctrl/Cmd+C).',
+ cut: 'Taglia',
+ cutError: 'Le impostazioni di sicurezza del browser non permettono di tagliare automaticamente il testo. Usa la tastiera (Ctrl/Cmd+X).',
+ paste: 'Incolla',
+ pasteArea: 'Incolla',
+ pasteMsg: 'Incolla il testo all\'interno dell\'area sottostante usando la scorciatoia di tastiere (Ctrl/Cmd+V) e premi OK.',
+ securityMsg: 'A causa delle impostazioni di sicurezza del browser,l\'editor non è in grado di accedere direttamente agli appunti. E\' pertanto necessario incollarli di nuovo in questa finestra.',
+ title: 'Incolla'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/ja.js b/assets/ckeditor-contrib/plugins/clipboard/lang/ja.js
new file mode 100644
index 00000000..879fe947
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/ja.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'ja', {
+ copy: 'コピー',
+ copyError: 'ブラウザーのセキュリティ設定によりエディタのコピー操作を自動で実行することができません。実行するには手動でキーボードの(Ctrl/Cmd+C)を使用してください。',
+ cut: '切り取り',
+ cutError: 'ブラウザーのセキュリティ設定によりエディタの切り取り操作を自動で実行することができません。実行するには手動でキーボードの(Ctrl/Cmd+X)を使用してください。',
+ paste: '貼り付け',
+ pasteArea: '貼り付け場所',
+ pasteMsg: 'キーボード(Ctrl/Cmd+V)を使用して、次の入力エリア内で貼り付けて、OKを押してください。',
+ securityMsg: 'ブラウザのセキュリティ設定により、エディタはクリップボードデータに直接アクセスすることができません。このウィンドウは貼り付け操作を行う度に表示されます。',
+ title: '貼り付け'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/ka.js b/assets/ckeditor-contrib/plugins/clipboard/lang/ka.js
new file mode 100644
index 00000000..021ea1f9
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/ka.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'ka', {
+ copy: 'ასლი',
+ copyError: 'თქვენი ბროუზერის უსაფრთხოების პარამეტრები არ იძლევა ასლის ოპერაციის ავტომატურად განხორციელების საშუალებას. გამოიყენეთ კლავიატურა ამისთვის (Ctrl/Cmd+C).',
+ cut: 'ამოჭრა',
+ cutError: 'თქვენი ბროუზერის უსაფრთხოების პარამეტრები არ იძლევა ამოჭრის ოპერაციის ავტომატურად განხორციელების საშუალებას. გამოიყენეთ კლავიატურა ამისთვის (Ctrl/Cmd+X).',
+ paste: 'ჩასმა',
+ pasteArea: 'ჩასმის არე',
+ pasteMsg: 'ჩასვით ამ არის შიგნით კლავიატურის გამოყენებით (Ctrl/Cmd+V) და დააჭირეთ OK-ს',
+ securityMsg: 'თქვენი ბროუზერის უსაფრთხოების პარამეტრები არ იძლევა clipboard-ის მონაცემების წვდომის უფლებას. კიდევ უნდა ჩასვათ ტექსტი ამ ფანჯარაში.',
+ title: 'ჩასმა'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/km.js b/assets/ckeditor-contrib/plugins/clipboard/lang/km.js
new file mode 100644
index 00000000..173d6a73
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/km.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'km', {
+ copy: 'ចម្លង',
+ copyError: 'ការកំណត់សុវត្ថភាពរបស់កម្មវិធីរុករករបស់លោកអ្នក នេះមិនអាចធ្វើកម្មវិធីតាក់តែងអត្ថបទ ចំលងអត្ថបទយកដោយស្វ័យប្រវត្តបានឡើយ ។ សូមប្រើប្រាស់បន្សំ ឃីដូចនេះ (Ctrl/Cmd+C)។',
+ cut: 'កាត់យក',
+ cutError: 'ការកំណត់សុវត្ថភាពរបស់កម្មវិធីរុករករបស់លោកអ្នក នេះមិនអាចធ្វើកម្មវិធីតាក់តែងអត្ថបទ កាត់អត្ថបទយកដោយស្វ័យប្រវត្តបានឡើយ ។ សូមប្រើប្រាស់បន្សំ ឃីដូចនេះ (Ctrl/Cmd+X) ។',
+ paste: 'បិទភ្ជាប់',
+ pasteArea: 'តំបន់បិទភ្ជាប់',
+ pasteMsg: 'សូមចំលងអត្ថបទទៅដាក់ក្នុងប្រអប់ដូចខាងក្រោមដោយប្រើប្រាស់ ឃី (Ctrl/Cmd+V) ហើយចុច OK ។',
+ securityMsg: 'ព្រោះតែការកំណត់សុវត្ថិភាព ប្រអប់សរសេរមិនអាចចាប់យកទិន្នន័យពីក្តារតម្បៀតខ្ទាស់អ្នកដោយផ្ទាល់បានទេ។ អ្នកត្រូវចំលងដាក់វាម្តងទៀត ក្នុងផ្ទាំងនេះ។',
+ title: 'បិទភ្ជាប់'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/ko.js b/assets/ckeditor-contrib/plugins/clipboard/lang/ko.js
new file mode 100644
index 00000000..85832910
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/ko.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'ko', {
+ copy: '복사',
+ copyError: '브라우저의 보안설정 때문에 복사할 수 없습니다. 키보드(Ctrl/Cmd+C)를 이용해서 복사하십시오.',
+ cut: '잘라내기',
+ cutError: '브라우저의 보안설정 때문에 잘라내기 기능을 실행할 수 없습니다. 키보드(Ctrl/Cmd+X)를 이용해서 잘라내기 하십시오',
+ paste: '붙여넣기',
+ pasteArea: '붙여넣기 범위',
+ pasteMsg: '키보드(Ctrl/Cmd+V)를 이용해서 상자안에 붙여넣고 확인 를 누르세요.',
+ securityMsg: '브라우저 보안 설정으로 인해, 클립보드에 직접 접근할 수 없습니다. 이 창에 다시 붙여넣기 하십시오.',
+ title: '붙여넣기'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/ku.js b/assets/ckeditor-contrib/plugins/clipboard/lang/ku.js
new file mode 100644
index 00000000..20fc54ea
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/ku.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'ku', {
+ copy: 'لەبەرگرتنەوە',
+ copyError: 'پارێزی وێبگەڕەکەت ڕێگەنادات بەسەرنووسەکە لە لکاندنی دەقی خۆکارارنە. تکایە لەبری ئەمە ئەم فەرمانە بەکاربهێنە بەداگرتنی کلیلی (Ctrl/Cmd+C).',
+ cut: 'بڕین',
+ cutError: 'پارێزی وێبگەڕەکەت ڕێگەنادات بە سەرنووسەکە لەبڕینی خۆکارانە. تکایە لەبری ئەمە ئەم فەرمانە بەکاربهێنە بەداگرتنی کلیلی (Ctrl/Cmd+X).',
+ paste: 'لکاندن',
+ pasteArea: 'ناوچەی لکاندن',
+ pasteMsg: 'تکایە بیلکێنە لەناوەوەی ئەم سنوقە لەڕێی تەختەکلیلەکەت بە بەکارهێنانی کلیلی (Ctrl/Cmd+V) دووای کلیکی باشە بکە.',
+ securityMsg: 'بەهۆی شێوەپێدانی پارێزی وێبگەڕەکەت، سەرنووسەکه ناتوانێت دەستبگەیەنێت بەهەڵگیراوەکە ڕاستەوخۆ. بۆیه پێویسته دووباره بیلکێنیت لەم پەنجەرەیه.',
+ title: 'لکاندن'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/lt.js b/assets/ckeditor-contrib/plugins/clipboard/lang/lt.js
new file mode 100644
index 00000000..7430e35c
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/lt.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'lt', {
+ copy: 'Kopijuoti',
+ copyError: 'Jūsų naršyklės saugumo nustatymai neleidžia redaktoriui automatiškai įvykdyti kopijavimo operacijų. Tam prašome naudoti klaviatūrą (Ctrl/Cmd+C).',
+ cut: 'Iškirpti',
+ cutError: 'Jūsų naršyklės saugumo nustatymai neleidžia redaktoriui automatiškai įvykdyti iškirpimo operacijų. Tam prašome naudoti klaviatūrą (Ctrl/Cmd+X).',
+ paste: 'Įdėti',
+ pasteArea: 'Įkelti dalį',
+ pasteMsg: 'Žemiau esančiame įvedimo lauke įdėkite tekstą, naudodami klaviatūrą (Ctrl/Cmd+V) ir paspauskite mygtuką OK.',
+ securityMsg: 'Dėl jūsų naršyklės saugumo nustatymų, redaktorius negali tiesiogiai pasiekti laikinosios atminties. Jums reikia nukopijuoti dar kartą į šį langą.',
+ title: 'Įdėti'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/lv.js b/assets/ckeditor-contrib/plugins/clipboard/lang/lv.js
new file mode 100644
index 00000000..4c472bc9
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/lv.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'lv', {
+ copy: 'Kopēt',
+ copyError: 'Jūsu pārlūkprogrammas drošības iestatījumi nepieļauj redaktoram automātiski veikt kopēšanas darbību. Lūdzu, izmantojiet (Ctrl/Cmd+C), lai veiktu šo darbību.',
+ cut: 'Izgriezt',
+ cutError: 'Jūsu pārlūkprogrammas drošības iestatījumi nepieļauj redaktoram automātiski veikt izgriezšanas darbību. Lūdzu, izmantojiet (Ctrl/Cmd+X), lai veiktu šo darbību.',
+ paste: 'Ielīmēt',
+ pasteArea: 'Ielīmēšanas zona',
+ pasteMsg: 'Lūdzu, ievietojiet tekstu šajā laukumā, izmantojot klaviatūru (Ctrl/Cmd+V) un apstipriniet ar Darīts!.',
+ securityMsg: 'Jūsu pārlūka drošības uzstādījumu dēļ, nav iespējams tieši piekļūt jūsu starpliktuvei. Jums jāielīmē atkārtoti šajā logā.',
+ title: 'Ievietot'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/mk.js b/assets/ckeditor-contrib/plugins/clipboard/lang/mk.js
new file mode 100644
index 00000000..7b166d6b
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/mk.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'mk', {
+ copy: 'Копирај (Copy)',
+ copyError: 'Опциите за безбедност на вашиот прелистувач не дозволуваат уредувачот автоматски да изврши копирање. Ве молиме употребете ја тастатурата. (Ctrl/Cmd+C)',
+ cut: 'Исечи (Cut)',
+ cutError: 'Опциите за безбедност на вашиот прелистувач не дозволуваат уредувачот автоматски да изврши сечење. Ве молиме употребете ја тастатурата. (Ctrl/Cmd+C)',
+ paste: 'Залепи (Paste)',
+ pasteArea: 'Простор за залепување',
+ pasteMsg: 'Ве молиме да залепите во следниот квадрат користејќи ја тастатурата (Ctrl/Cmd+V) и да притиснете OK',
+ securityMsg: 'Опциите за безбедност на вашиот прелистувач не дозволуваат уредувачот директно да пристапи до копираните податоци. Потребно е повторно да се обидете во овој прозорец.',
+ title: 'Залепи (Paste)'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/mn.js b/assets/ckeditor-contrib/plugins/clipboard/lang/mn.js
new file mode 100644
index 00000000..cea4e69a
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/mn.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'mn', {
+ copy: 'Хуулах',
+ copyError: 'Таны browser-ын хамгаалалтын тохиргоо editor-д автоматаар хуулах үйлдэлийг зөвшөөрөхгүй байна. (Ctrl/Cmd+C) товчны хослолыг ашиглана уу.',
+ cut: 'Хайчлах',
+ cutError: 'Таны browser-ын хамгаалалтын тохиргоо editor-д автоматаар хайчлах үйлдэлийг зөвшөөрөхгүй байна. (Ctrl/Cmd+X) товчны хослолыг ашиглана уу.',
+ paste: 'Буулгах',
+ pasteArea: 'Paste Area', // MISSING
+ pasteMsg: '(Ctrl/Cmd+V) товчийг ашиглан paste хийнэ үү. Мөн OK дар.',
+ securityMsg: 'Таны үзүүлэгч/browser/-н хамгаалалтын тохиргооноос болоод editor clipboard өгөгдөлрүү шууд хандах боломжгүй. Энэ цонход дахин paste хийхийг оролд.',
+ title: 'Буулгах'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/ms.js b/assets/ckeditor-contrib/plugins/clipboard/lang/ms.js
new file mode 100644
index 00000000..98f7cfda
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/ms.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'ms', {
+ copy: 'Salin',
+ copyError: 'Keselamatan perisian browser anda tidak membenarkan operasi salinan text/imej. Sila gunakan papan kekunci (Ctrl/Cmd+C).',
+ cut: 'Potong',
+ cutError: 'Keselamatan perisian browser anda tidak membenarkan operasi suntingan text/imej. Sila gunakan papan kekunci (Ctrl/Cmd+X).',
+ paste: 'Tampal',
+ pasteArea: 'Paste Area', // MISSING
+ pasteMsg: 'Please paste inside the following box using the keyboard (Ctrl/Cmd+V) and hit OK', // MISSING
+ securityMsg: 'Because of your browser security settings, the editor is not able to access your clipboard data directly. You are required to paste it again in this window.', // MISSING
+ title: 'Tampal'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/nb.js b/assets/ckeditor-contrib/plugins/clipboard/lang/nb.js
new file mode 100644
index 00000000..e429bc70
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/nb.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'nb', {
+ copy: 'Kopier',
+ copyError: 'Din nettlesers sikkerhetsinstillinger tillater ikke automatisk kopiering av tekst. Vennligst bruk tastatursnarveien (Ctrl/Cmd+C).',
+ cut: 'Klipp ut',
+ cutError: 'Din nettlesers sikkerhetsinstillinger tillater ikke automatisk utklipping av tekst. Vennligst bruk tastatursnarveien (Ctrl/Cmd+X).',
+ paste: 'Lim inn',
+ pasteArea: 'Innlimingsområde',
+ pasteMsg: 'Vennligst lim inn i følgende boks med tastaturet (Ctrl/Cmd+V) og trykk OK.',
+ securityMsg: 'Din nettlesers sikkerhetsinstillinger gir ikke redigeringsverktøyet direkte tilgang til utklippstavlen. Du må derfor lime det inn på nytt i dette vinduet.',
+ title: 'Lim inn'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/nl.js b/assets/ckeditor-contrib/plugins/clipboard/lang/nl.js
new file mode 100644
index 00000000..5ff04e08
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/nl.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'nl', {
+ copy: 'Kopiëren',
+ copyError: 'De beveiligingsinstelling van de browser verhinderen het automatisch kopiëren. Gebruik de sneltoets Ctrl/Cmd+C van het toetsenbord.',
+ cut: 'Knippen',
+ cutError: 'De beveiligingsinstelling van de browser verhinderen het automatisch knippen. Gebruik de sneltoets Ctrl/Cmd+X van het toetsenbord.',
+ paste: 'Plakken',
+ pasteArea: 'Plakgebied',
+ pasteMsg: 'Plak de tekst in het volgende vak gebruikmakend van uw toetsenbord (Ctrl/Cmd+V) en klik op OK.',
+ securityMsg: 'Door de beveiligingsinstellingen van uw browser is het niet mogelijk om direct vanuit het klembord in de editor te plakken. Middels opnieuw plakken in dit venster kunt u de tekst alsnog plakken in de editor.',
+ title: 'Plakken'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/no.js b/assets/ckeditor-contrib/plugins/clipboard/lang/no.js
new file mode 100644
index 00000000..3fb8d835
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/no.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'no', {
+ copy: 'Kopier',
+ copyError: 'Din nettlesers sikkerhetsinstillinger tillater ikke automatisk kopiering av tekst. Vennligst bruk snarveien (Ctrl/Cmd+C).',
+ cut: 'Klipp ut',
+ cutError: 'Din nettlesers sikkerhetsinstillinger tillater ikke automatisk utklipping av tekst. Vennligst bruk snarveien (Ctrl/Cmd+X).',
+ paste: 'Lim inn',
+ pasteArea: 'Innlimingsområde',
+ pasteMsg: 'Vennligst lim inn i følgende boks med tastaturet (Ctrl/Cmd+V) og trykk OK.',
+ securityMsg: 'Din nettlesers sikkerhetsinstillinger gir ikke redigeringsverktøyet direkte tilgang til utklippstavlen. Du må derfor lime det inn på nytt i dette vinduet.',
+ title: 'Lim inn'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/pl.js b/assets/ckeditor-contrib/plugins/clipboard/lang/pl.js
new file mode 100644
index 00000000..8f91d30e
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/pl.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'pl', {
+ copy: 'Kopiuj',
+ copyError: 'Ustawienia bezpieczeństwa Twojej przeglądarki nie pozwalają na automatyczne kopiowanie tekstu. Użyj skrótu klawiszowego Ctrl/Cmd+C.',
+ cut: 'Wytnij',
+ cutError: 'Ustawienia bezpieczeństwa Twojej przeglądarki nie pozwalają na automatyczne wycinanie tekstu. Użyj skrótu klawiszowego Ctrl/Cmd+X.',
+ paste: 'Wklej',
+ pasteArea: 'Obszar wklejania',
+ pasteMsg: 'Wklej tekst w poniższym polu, używając skrótu klawiaturowego (Ctrl/Cmd+V), i kliknij OK.',
+ securityMsg: 'Zabezpieczenia przeglądarki uniemożliwiają wklejenie danych bezpośrednio do edytora. Proszę ponownie wkleić dane w tym oknie.',
+ title: 'Wklej'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/pt-br.js b/assets/ckeditor-contrib/plugins/clipboard/lang/pt-br.js
new file mode 100644
index 00000000..3de6be4c
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/pt-br.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'pt-br', {
+ copy: 'Copiar',
+ copyError: 'As configurações de segurança do seu navegador não permitem que o editor execute operações de copiar automaticamente. Por favor, utilize o teclado para copiar (Ctrl/Cmd+C).',
+ cut: 'Recortar',
+ cutError: 'As configurações de segurança do seu navegador não permitem que o editor execute operações de recortar automaticamente. Por favor, utilize o teclado para recortar (Ctrl/Cmd+X).',
+ paste: 'Colar',
+ pasteArea: 'Área para Colar',
+ pasteMsg: 'Transfira o link usado na caixa usando o teclado com (Ctrl/Cmd+V) e OK.',
+ securityMsg: 'As configurações de segurança do seu navegador não permitem que o editor acesse os dados da área de transferência diretamente. Por favor cole o conteúdo manualmente nesta janela.',
+ title: 'Colar'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/pt.js b/assets/ckeditor-contrib/plugins/clipboard/lang/pt.js
new file mode 100644
index 00000000..6289b387
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/pt.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'pt', {
+ copy: 'Copiar',
+ copyError: 'A configuração de segurança do navegador não permite a execução automática de operações de copiar. Por favor use o teclado (Ctrl/Cmd+C).',
+ cut: 'Cortar',
+ cutError: 'A configuração de segurança do navegador não permite a execução automática de operações de cortar. Por favor use o teclado (Ctrl/Cmd+X).',
+ paste: 'Colar',
+ pasteArea: 'Colar área',
+ pasteMsg: 'Por favor, cole dentro da seguinte caixa usando o teclado (Ctrl/Cmd+V) e carregue em OK.',
+ securityMsg: 'Devido ás definições de segurança do teu browser, o editor não pode aceder ao clipboard diretamente. É necessário que voltes a colar as informações nesta janela.',
+ title: 'Colar'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/ro.js b/assets/ckeditor-contrib/plugins/clipboard/lang/ro.js
new file mode 100644
index 00000000..d57f2326
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/ro.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'ro', {
+ copy: 'Copiază',
+ copyError: 'Setările de securitate ale navigatorului (browser) pe care îl folosiţi nu permit editorului să execute automat operaţiunea de copiere. Vă rugăm folosiţi tastatura (Ctrl/Cmd+C).',
+ cut: 'Taie',
+ cutError: 'Setările de securitate ale navigatorului (browser) pe care îl folosiţi nu permit editorului să execute automat operaţiunea de tăiere. Vă rugăm folosiţi tastatura (Ctrl/Cmd+X).',
+ paste: 'Adaugă',
+ pasteArea: 'Suprafața de adăugare',
+ pasteMsg: 'Vă rugăm adăugaţi în căsuţa următoare folosind tastatura (Ctrl/Cmd+V) şi apăsaţi OK',
+ securityMsg: 'Din cauza setărilor de securitate ale programului dvs. cu care navigaţi pe internet (browser), editorul nu poate accesa direct datele din clipboard. Va trebui să adăugaţi din nou datele în această fereastră.',
+ title: 'Adaugă'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/ru.js b/assets/ckeditor-contrib/plugins/clipboard/lang/ru.js
new file mode 100644
index 00000000..d778270b
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/ru.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'ru', {
+ copy: 'Копировать',
+ copyError: 'Настройки безопасности вашего браузера не разрешают редактору выполнять операции по копированию текста. Пожалуйста, используйте для этого клавиатуру (Ctrl/Cmd+C).',
+ cut: 'Вырезать',
+ cutError: 'Настройки безопасности вашего браузера не разрешают редактору выполнять операции по вырезке текста. Пожалуйста, используйте для этого клавиатуру (Ctrl/Cmd+X).',
+ paste: 'Вставить',
+ pasteArea: 'Зона для вставки',
+ pasteMsg: 'Пожалуйста, вставьте текст в зону ниже, используя клавиатуру (Ctrl/Cmd+V) и нажмите кнопку "OK".',
+ securityMsg: 'Настройки безопасности вашего браузера не разрешают редактору напрямую обращаться к буферу обмена. Вы должны вставить текст снова в это окно.',
+ title: 'Вставить'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/si.js b/assets/ckeditor-contrib/plugins/clipboard/lang/si.js
new file mode 100644
index 00000000..315881ac
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/si.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'si', {
+ copy: 'පිටපත් කරන්න',
+ copyError: 'Your browser security settings don\'t permit the editor to automatically execute copying operations. Please use the keyboard for that (Ctrl/Cmd+C).', // MISSING
+ cut: 'කපාගන්න',
+ cutError: 'Your browser security settings don\'t permit the editor to automatically execute cutting operations. Please use the keyboard for that (Ctrl/Cmd+X).', // MISSING
+ paste: 'අලවන්න',
+ pasteArea: 'අලවන ප්රදේශ',
+ pasteMsg: 'Please paste inside the following box using the keyboard (Ctrl/Cmd+V) and hit OK', // MISSING
+ securityMsg: 'Because of your browser security settings, the editor is not able to access your clipboard data directly. You are required to paste it again in this window.', // MISSING
+ title: 'අලවන්න'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/sk.js b/assets/ckeditor-contrib/plugins/clipboard/lang/sk.js
new file mode 100644
index 00000000..ac0a1790
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/sk.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'sk', {
+ copy: 'Kopírovať',
+ copyError: 'Bezpečnostné nastavenia vášho prehliadača nedovoľujú editoru automaticky spustiť operáciu kopírovania. Použite na to klávesnicu (Ctrl/Cmd+C).',
+ cut: 'Vystrihnúť',
+ cutError: 'Bezpečnostné nastavenia vášho prehliadača nedovoľujú editoru automaticky spustiť operáciu vystrihnutia. Použite na to klávesnicu (Ctrl/Cmd+X).',
+ paste: 'Vložiť',
+ pasteArea: 'Miesto na vloženie',
+ pasteMsg: 'Použitím klávesnice (Ctrl/Cmd+V) vložte text do rámčeka a stlačte OK.',
+ securityMsg: 'Kvôli bezpečnostným nastaveniam vášho prehliadača editor nemôže pristupovať k schránke na kopírovanie priamo. Vložte to preto do tohto okna.',
+ title: 'Vložiť'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/sl.js b/assets/ckeditor-contrib/plugins/clipboard/lang/sl.js
new file mode 100644
index 00000000..443f096e
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/sl.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'sl', {
+ copy: 'Kopiraj',
+ copyError: 'Varnostne nastavitve brskalnika ne dopuščajo samodejnega kopiranja. Uporabite kombinacijo tipk na tipkovnici (Ctrl/Cmd+C).',
+ cut: 'Izreži',
+ cutError: 'Varnostne nastavitve brskalnika ne dopuščajo samodejnega izrezovanja. Uporabite kombinacijo tipk na tipkovnici (Ctrl/Cmd+X).',
+ paste: 'Prilepi',
+ pasteArea: 'Prilepi območje',
+ pasteMsg: 'Prosimo, prilepite v sleči okvir s pomočjo tipkovnice (Ctrl/Cmd+V) in pritisnite V redu.',
+ securityMsg: 'Zaradi varnostnih nastavitev vašega brskalnika urejevalnik ne more neposredno dostopati do odložišča. Vsebino odložišča ponovno prilepite v to okno.',
+ title: 'Prilepi'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/sq.js b/assets/ckeditor-contrib/plugins/clipboard/lang/sq.js
new file mode 100644
index 00000000..b9a684e7
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/sq.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'sq', {
+ copy: 'Kopjo',
+ copyError: 'Të dhënat e sigurisë së shfletuesit tuaj nuk lejojnë që redaktuesi automatikisht të kryej veprimin e kopjimit. Ju lutemi shfrytëzoni tastierën për këtë veprim (Ctrl/Cmd+C).',
+ cut: 'Preje',
+ cutError: 'Të dhënat e sigurisë së shfletuesit tuaj nuk lejojnë që redaktuesi automatikisht të kryej veprimin e prerjes. Ju lutemi shfrytëzoni tastierën për këtë veprim (Ctrl/Cmd+X).',
+ paste: 'Hidhe',
+ pasteArea: 'Hapësira Hedhëse',
+ pasteMsg: 'Ju lutemi hidhni brenda kutizës në vijim duke shfrytëzuar tastierën (Ctrl/Cmd+V) dhe shtypni Mirë.',
+ securityMsg: 'Për shkak të dhënave të sigurisë së shfletuesit tuaj, redaktuesi nuk është në gjendje të i qaset drejtpërdrejtë të dhanve të tabelës suaj të punës. Ju duhet të hidhni atë përsëri në këtë dritare.',
+ title: 'Hidhe'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/sr-latn.js b/assets/ckeditor-contrib/plugins/clipboard/lang/sr-latn.js
new file mode 100644
index 00000000..0245a6e6
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/sr-latn.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'sr-latn', {
+ copy: 'Kopiraj',
+ copyError: 'Sigurnosna podešavanja Vašeg pretraživača ne dozvoljavaju operacije automatskog kopiranja teksta. Molimo Vas da koristite prečicu sa tastature (Ctrl/Cmd+C).',
+ cut: 'Iseci',
+ cutError: 'Sigurnosna podešavanja Vašeg pretraživača ne dozvoljavaju operacije automatskog isecanja teksta. Molimo Vas da koristite prečicu sa tastature (Ctrl/Cmd+X).',
+ paste: 'Zalepi',
+ pasteArea: 'Prostor za lepljenje',
+ pasteMsg: 'Molimo Vas da zalepite unutar donje povrine koristeći tastaturnu prečicu (Ctrl/Cmd+V) i da pritisnete OK.',
+ securityMsg: 'Zbog sigurnosnih postavki vašeg pregledača, editor nije u mogućnosti da direktno pristupi podacima u klipbordu. Potrebno je da zalepite još jednom u ovom prozoru.',
+ title: 'Zalepi'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/sr.js b/assets/ckeditor-contrib/plugins/clipboard/lang/sr.js
new file mode 100644
index 00000000..aabe83f9
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/sr.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'sr', {
+ copy: 'Копирај',
+ copyError: 'Сигурносна подешавања Вашег претраживача не дозвољавају операције аутоматског копирања текста. Молимо Вас да користите пречицу са тастатуре (Ctrl/Cmd+C).',
+ cut: 'Исеци',
+ cutError: 'Сигурносна подешавања Вашег претраживача не дозвољавају операције аутоматског исецања текста. Молимо Вас да користите пречицу са тастатуре (Ctrl/Cmd+X).',
+ paste: 'Залепи',
+ pasteArea: 'Залепи зону',
+ pasteMsg: 'Молимо Вас да залепите унутар доње површине користећи тастатурну пречицу (Ctrl/Cmd+V) и да притиснете OK.',
+ securityMsg: 'Због сигурносних подешавања претраживача, едитор не може да приступи оставу. Требате да га поново залепите у овом прозору.',
+ title: 'Залепи'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/sv.js b/assets/ckeditor-contrib/plugins/clipboard/lang/sv.js
new file mode 100644
index 00000000..4c14c72c
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/sv.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'sv', {
+ copy: 'Kopiera',
+ copyError: 'Säkerhetsinställningar i Er webbläsare tillåter inte åtgärden kopiera. Använd (Ctrl/Cmd+C) istället.',
+ cut: 'Klipp ut',
+ cutError: 'Säkerhetsinställningar i Er webbläsare tillåter inte åtgärden klipp ut. Använd (Ctrl/Cmd+X) istället.',
+ paste: 'Klistra in',
+ pasteArea: 'Paste Area',
+ pasteMsg: 'Var god och klistra in Er text i rutan nedan genom att använda (Ctrl/Cmd+V) klicka sen på OK.',
+ securityMsg: 'På grund av din webbläsares säkerhetsinställningar kan verktyget inte få åtkomst till urklippsdatan. Var god och använd detta fönster istället.',
+ title: 'Klistra in'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/th.js b/assets/ckeditor-contrib/plugins/clipboard/lang/th.js
new file mode 100644
index 00000000..0420220e
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/th.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'th', {
+ copy: 'สำเนา',
+ copyError: 'ไม่สามารถสำเนาข้อความที่เลือกไว้ได้เนื่องจากการกำหนดค่าระดับความปลอดภัย. กรุณาใช้ปุ่มลัดเพื่อวางข้อความแทน (กดปุ่ม Ctrl/Cmd และตัว C พร้อมกัน).',
+ cut: 'ตัด',
+ cutError: 'ไม่สามารถตัดข้อความที่เลือกไว้ได้เนื่องจากการกำหนดค่าระดับความปลอดภัย. กรุณาใช้ปุ่มลัดเพื่อวางข้อความแทน (กดปุ่ม Ctrl/Cmd และตัว X พร้อมกัน).',
+ paste: 'วาง',
+ pasteArea: 'Paste Area', // MISSING
+ pasteMsg: 'กรุณาใช้คีย์บอร์ดเท่านั้น โดยกดปุ๋ม (Ctrl/Cmd และ V)พร้อมๆกัน และกด OK.',
+ securityMsg: 'Because of your browser security settings, the editor is not able to access your clipboard data directly. You are required to paste it again in this window.', // MISSING
+ title: 'วาง'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/tr.js b/assets/ckeditor-contrib/plugins/clipboard/lang/tr.js
new file mode 100644
index 00000000..b0e85d9d
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/tr.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'tr', {
+ copy: 'Kopyala',
+ copyError: 'Gezgin yazılımınızın güvenlik ayarları düzenleyicinin otomatik kopyalama işlemine izin vermiyor. İşlem için (Ctrl/Cmd+C) tuşlarını kullanın.',
+ cut: 'Kes',
+ cutError: 'Gezgin yazılımınızın güvenlik ayarları düzenleyicinin otomatik kesme işlemine izin vermiyor. İşlem için (Ctrl/Cmd+X) tuşlarını kullanın.',
+ paste: 'Yapıştır',
+ pasteArea: 'Yapıştırma Alanı',
+ pasteMsg: 'Lütfen aşağıdaki kutunun içine yapıştırın. (Ctrl/Cmd+V) ve Tamam butonunu tıklayın.',
+ securityMsg: 'Gezgin yazılımınızın güvenlik ayarları düzenleyicinin direkt olarak panoya erişimine izin vermiyor. Bu pencere içine tekrar yapıştırmalısınız..',
+ title: 'Yapıştır'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/tt.js b/assets/ckeditor-contrib/plugins/clipboard/lang/tt.js
new file mode 100644
index 00000000..3faee060
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/tt.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'tt', {
+ copy: 'Күчермәләү',
+ copyError: 'Браузерыгызның иминлек үзлекләре автоматик рәвештә күчермәләү үтәүне тыя. Тиз төймәләрне (Ctrl/Cmd+C) кулланыгыз.',
+ cut: 'Кисеп алу',
+ cutError: 'Браузерыгызның иминлек үзлекләре автоматик рәвештә күчермәләү үтәүне тыя. Тиз төймәләрне (Ctrl/Cmd+C) кулланыгыз.',
+ paste: 'Өстәү',
+ pasteArea: 'Өстәү мәйданы',
+ pasteMsg: 'Please paste inside the following box using the keyboard (Ctrl/Cmd+V) and hit OK', // MISSING
+ securityMsg: 'Because of your browser security settings, the editor is not able to access your clipboard data directly. You are required to paste it again in this window.', // MISSING
+ title: 'Өстәү'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/ug.js b/assets/ckeditor-contrib/plugins/clipboard/lang/ug.js
new file mode 100644
index 00000000..e2607df7
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/ug.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'ug', {
+ copy: 'كۆچۈر',
+ copyError: 'تور كۆرگۈڭىزنىڭ بىخەتەرلىك تەڭشىكى تەھرىرلىگۈچنىڭ كۆچۈر مەشغۇلاتىنى ئۆزلۈكىدىن ئىجرا قىلىشىغا يول قويمايدۇ، ھەرپتاختا تېز كۇنۇپكا (Ctrl/Cmd+C) ئارقىلىق تاماملاڭ',
+ cut: 'كەس',
+ cutError: 'تور كۆرگۈڭىزنىڭ بىخەتەرلىك تەڭشىكى تەھرىرلىگۈچنىڭ كەس مەشغۇلاتىنى ئۆزلۈكىدىن ئىجرا قىلىشىغا يول قويمايدۇ، ھەرپتاختا تېز كۇنۇپكا (Ctrl/Cmd+X) ئارقىلىق تاماملاڭ',
+ paste: 'چاپلا',
+ pasteArea: 'چاپلاش دائىرىسى',
+ pasteMsg: 'ھەرپتاختا تېز كۇنۇپكا (Ctrl/Cmd+V) نى ئىشلىتىپ مەزمۇننى تۆۋەندىكى رامكىغا كۆچۈرۈڭ، ئاندىن جەزملەنى بېسىڭ',
+ securityMsg: 'توركۆرگۈڭىزنىڭ بىخەتەرلىك تەڭشىكى سەۋەبىدىن بۇ تەھرىرلىگۈچ چاپلاش تاختىسىدىكى مەزمۇننى بىۋاستە زىيارەت قىلالمايدۇ، بۇ كۆزنەكتە قايتا بىر قېتىم چاپلىشىڭىز كېرەك.',
+ title: 'چاپلا'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/uk.js b/assets/ckeditor-contrib/plugins/clipboard/lang/uk.js
new file mode 100644
index 00000000..ba78ed3c
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/uk.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'uk', {
+ copy: 'Копіювати',
+ copyError: 'Налаштування безпеки Вашого браузера не дозволяють редактору автоматично виконувати операції копіювання. Будь ласка, використовуйте клавіатуру для цього (Ctrl/Cmd+C).',
+ cut: 'Вирізати',
+ cutError: 'Налаштування безпеки Вашого браузера не дозволяють редактору автоматично виконувати операції вирізування. Будь ласка, використовуйте клавіатуру для цього (Ctrl/Cmd+X)',
+ paste: 'Вставити',
+ pasteArea: 'Область вставки',
+ pasteMsg: 'Будь ласка, вставте інформацію з буфера обміну в цю область, користуючись комбінацією клавіш (Ctrl/Cmd+V), та натисніть OK.',
+ securityMsg: 'Редактор не може отримати прямий доступ до буферу обміну у зв\'язку з налаштуваннями Вашого браузера. Вам потрібно вставити інформацію в це вікно.',
+ title: 'Вставити'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/vi.js b/assets/ckeditor-contrib/plugins/clipboard/lang/vi.js
new file mode 100644
index 00000000..4bbd0908
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/vi.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'vi', {
+ copy: 'Sao chép',
+ copyError: 'Các thiết lập bảo mật của trình duyệt không cho phép trình biên tập tự động thực thi lệnh sao chép. Hãy sử dụng bàn phím cho lệnh này (Ctrl/Cmd+C).',
+ cut: 'Cắt',
+ cutError: 'Các thiết lập bảo mật của trình duyệt không cho phép trình biên tập tự động thực thi lệnh cắt. Hãy sử dụng bàn phím cho lệnh này (Ctrl/Cmd+X).',
+ paste: 'Dán',
+ pasteArea: 'Khu vực dán',
+ pasteMsg: 'Hãy dán nội dung vào trong khung bên dưới, sử dụng tổ hợp phím (Ctrl/Cmd+V) và nhấn vào nút Đồng ý.',
+ securityMsg: 'Do thiết lập bảo mật của trình duyệt nên trình biên tập không thể truy cập trực tiếp vào nội dung đã sao chép. Bạn cần phải dán lại nội dung vào cửa sổ này.',
+ title: 'Dán'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/zh-cn.js b/assets/ckeditor-contrib/plugins/clipboard/lang/zh-cn.js
new file mode 100644
index 00000000..11fa55bf
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/zh-cn.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'zh-cn', {
+ copy: '复制',
+ copyError: '您的浏览器安全设置不允许编辑器自动执行复制操作,请使用键盘快捷键(Ctrl/Cmd+C)来完成。',
+ cut: '剪切',
+ cutError: '您的浏览器安全设置不允许编辑器自动执行剪切操作,请使用键盘快捷键(Ctrl/Cmd+X)来完成。',
+ paste: '粘贴',
+ pasteArea: '粘贴区域',
+ pasteMsg: '请使用键盘快捷键(Ctrl/Cmd+V)把内容粘贴到下面的方框里,再按 确定',
+ securityMsg: '因为您的浏览器的安全设置原因,本编辑器不能直接访问您的剪贴板内容,你需要在本窗口重新粘贴一次。',
+ title: '粘贴'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/lang/zh.js b/assets/ckeditor-contrib/plugins/clipboard/lang/zh.js
new file mode 100644
index 00000000..087a478b
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/lang/zh.js
@@ -0,0 +1,15 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'clipboard', 'zh', {
+ copy: '複製',
+ copyError: '瀏覽器的安全性設定不允許編輯器自動執行複製動作。請使用鍵盤快捷鍵 (Ctrl/Cmd+C) 複製。',
+ cut: '剪下',
+ cutError: '瀏覽器的安全性設定不允許編輯器自動執行剪下動作。請使用鏐盤快捷鍵 (Ctrl/Cmd+X) 剪下。',
+ paste: '貼上',
+ pasteArea: '貼上區',
+ pasteMsg: '請使用鍵盤快捷鍵 (Ctrl/Cmd+V) 貼到下方區域中並按下「確定」。',
+ securityMsg: '因為瀏覽器的安全性設定,本編輯器無法直接存取您的剪貼簿資料,請您自行在本視窗進行貼上動作。',
+ title: '貼上'
+} );
diff --git a/assets/ckeditor-contrib/plugins/clipboard/plugin.js b/assets/ckeditor-contrib/plugins/clipboard/plugin.js
new file mode 100644
index 00000000..6ba3b148
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/clipboard/plugin.js
@@ -0,0 +1,2727 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+/**
+ * @ignore
+ * File overview: Clipboard support.
+ */
+
+//
+// COPY & PASTE EXECUTION FLOWS:
+// -- CTRL+C
+// * if ( isCustomCopyCutSupported )
+// * dataTransfer.setData( 'text/html', getSelectedHtml )
+// * else
+// * browser's default behavior
+// -- CTRL+X
+// * listen onKey (onkeydown)
+// * fire 'saveSnapshot' on editor
+// * if ( isCustomCopyCutSupported )
+// * dataTransfer.setData( 'text/html', getSelectedHtml )
+// * extractSelectedHtml // remove selected contents
+// * else
+// * browser's default behavior
+// * deferred second 'saveSnapshot' event
+// -- CTRL+V
+// * listen onKey (onkeydown)
+// * simulate 'beforepaste' for non-IEs on editable
+// * listen 'onpaste' on editable ('onbeforepaste' for IE)
+// * fire 'beforePaste' on editor
+// * if ( !canceled && ( htmlInDataTransfer || !external paste) && dataTransfer is not empty ) getClipboardDataByPastebin
+// * fire 'paste' on editor
+// * !canceled && fire 'afterPaste' on editor
+// -- Copy command
+// * tryToCutCopy
+// * execCommand
+// * !success && notification
+// -- Cut command
+// * fixCut
+// * tryToCutCopy
+// * execCommand
+// * !success && notification
+// -- Paste command
+// * fire 'paste' on editable ('beforepaste' for IE)
+// * !canceled && execCommand 'paste'
+// * !success && fire 'pasteDialog' on editor
+// -- Paste from native context menu & menubar
+// (Fx & Webkits are handled in 'paste' default listener.
+// Opera cannot be handled at all because it doesn't fire any events
+// Special treatment is needed for IE, for which is this part of doc)
+// * listen 'onpaste'
+// * cancel native event
+// * fire 'beforePaste' on editor
+// * if ( !canceled && ( htmlInDataTransfer || !external paste) && dataTransfer is not empty ) getClipboardDataByPastebin
+// * execIECommand( 'paste' ) -> this fires another 'paste' event, so cancel it
+// * fire 'paste' on editor
+// * !canceled && fire 'afterPaste' on editor
+//
+//
+// PASTE EVENT - PREPROCESSING:
+// -- Possible dataValue types: auto, text, html.
+// -- Possible dataValue contents:
+// * text (possible \n\r)
+// * htmlified text (text + br,div,p - no presentational markup & attrs - depends on browser)
+// * html
+// -- Possible flags:
+// * htmlified - if true then content is a HTML even if no markup inside. This flag is set
+// for content from editable pastebins, because they 'htmlify' pasted content.
+//
+// -- Type: auto:
+// * content: htmlified text -> filter, unify text markup (brs, ps, divs), set type: text
+// * content: html -> filter, set type: html
+// -- Type: text:
+// * content: htmlified text -> filter, unify text markup
+// * content: html -> filter, strip presentational markup, unify text markup
+// -- Type: html:
+// * content: htmlified text -> filter, unify text markup
+// * content: html -> filter
+//
+// -- Phases:
+// * if dataValue is empty copy data from dataTransfer to dataValue (priority 1)
+// * filtering (priorities 3-5) - e.g. pastefromword filters
+// * content type sniffing (priority 6)
+// * markup transformations for text (priority 6)
+//
+// DRAG & DROP EXECUTION FLOWS:
+// -- Drag
+// * save to the global object:
+// * drag timestamp (with 'cke-' prefix),
+// * selected html,
+// * drag range,
+// * editor instance.
+// * put drag timestamp into event.dataTransfer.text
+// -- Drop
+// * if events text == saved timestamp && editor == saved editor
+// internal drag & drop occurred
+// * getRangeAtDropPosition
+// * create bookmarks for drag and drop ranges starting from the end of the document
+// * dragRange.deleteContents()
+// * fire 'paste' with saved html and drop range
+// * if events text == saved timestamp && editor != saved editor
+// cross editor drag & drop occurred
+// * getRangeAtDropPosition
+// * fire 'paste' with saved html
+// * dragRange.deleteContents()
+// * FF: refreshCursor on afterPaste
+// * if events text != saved timestamp
+// drop form external source occurred
+// * getRangeAtDropPosition
+// * if event contains html data then fire 'paste' with html
+// * else if event contains text data then fire 'paste' with encoded text
+// * FF: refreshCursor on afterPaste
+
+'use strict';
+
+( function() {
+ // Register the plugin.
+ CKEDITOR.plugins.add( 'clipboard', {
+ requires: 'dialog',
+ // jscs:disable maximumLineLength
+ lang: 'af,ar,bg,bn,bs,ca,cs,cy,da,de,de-ch,el,en,en-au,en-ca,en-gb,eo,es,et,eu,fa,fi,fo,fr,fr-ca,gl,gu,he,hi,hr,hu,id,is,it,ja,ka,km,ko,ku,lt,lv,mk,mn,ms,nb,nl,no,pl,pt,pt-br,ro,ru,si,sk,sl,sq,sr,sr-latn,sv,th,tr,tt,ug,uk,vi,zh,zh-cn', // %REMOVE_LINE_CORE%
+ // jscs:enable maximumLineLength
+ icons: 'copy,copy-rtl,cut,cut-rtl,paste,paste-rtl', // %REMOVE_LINE_CORE%
+ hidpi: true, // %REMOVE_LINE_CORE%
+ init: function( editor ) {
+ var filterType,
+ filtersFactory = filtersFactoryFactory();
+
+ if ( editor.config.forcePasteAsPlainText ) {
+ filterType = 'plain-text';
+ } else if ( editor.config.pasteFilter ) {
+ filterType = editor.config.pasteFilter;
+ }
+ // On Webkit the pasteFilter defaults 'semantic-content' because pasted data is so terrible
+ // that it must be always filtered.
+ else if ( CKEDITOR.env.webkit && !( 'pasteFilter' in editor.config ) ) {
+ filterType = 'semantic-content';
+ }
+
+ editor.pasteFilter = filtersFactory.get( filterType );
+
+ initPasteClipboard( editor );
+ initDragDrop( editor );
+
+ CKEDITOR.dialog.add( 'paste', CKEDITOR.getUrl( this.path + 'dialogs/paste.js' ) );
+
+ editor.on( 'paste', function( evt ) {
+ // Init `dataTransfer` if `paste` event was fired without it, so it will be always available.
+ if ( !evt.data.dataTransfer ) {
+ evt.data.dataTransfer = new CKEDITOR.plugins.clipboard.dataTransfer();
+ }
+
+ // If dataValue is already set (manually or by paste bin), so do not override it.
+ if ( evt.data.dataValue ) {
+ return;
+ }
+
+ var dataTransfer = evt.data.dataTransfer,
+ // IE support only text data and throws exception if we try to get html data.
+ // This html data object may also be empty if we drag content of the textarea.
+ value = dataTransfer.getData( 'text/html' );
+
+ if ( value ) {
+ evt.data.dataValue = value;
+ evt.data.type = 'html';
+ } else {
+ // Try to get text data otherwise.
+ value = dataTransfer.getData( 'text/plain' );
+
+ if ( value ) {
+ evt.data.dataValue = editor.editable().transformPlainTextToHtml( value );
+ evt.data.type = 'text';
+ }
+ }
+ }, null, null, 1 );
+
+ editor.on( 'paste', function( evt ) {
+ var data = evt.data.dataValue,
+ blockElements = CKEDITOR.dtd.$block;
+
+ // Filter webkit garbage.
+ if ( data.indexOf( 'Apple-' ) > -1 ) {
+ // Replace special webkit's with simple space, because webkit
+ // produces them even for normal spaces.
+ data = data.replace( / <\/span>/gi, ' ' );
+
+ // Strip around white-spaces when not in forced 'html' content type.
+ // This spans are created only when pasting plain text into Webkit,
+ // but for safety reasons remove them always.
+ if ( evt.data.type != 'html' ) {
+ data = data.replace( /]*>([^<]*)<\/span>/gi, function( all, spaces ) {
+ // Replace tabs with 4 spaces like Fx does.
+ return spaces.replace( /\t/g, ' ' );
+ } );
+ }
+
+ // This br is produced only when copying & pasting HTML content.
+ if ( data.indexOf( ' ' ) > -1 ) {
+ evt.data.startsWithEOL = 1;
+ evt.data.preSniffing = 'html'; // Mark as not text.
+ data = data.replace( / /, '' );
+ }
+
+ // Remove all other classes.
+ data = data.replace( /(<[^>]+) class="Apple-[^"]*"/gi, '$1' );
+ }
+
+ // Strip editable that was copied from inside. (#9534)
+ if ( data.match( /^<[^<]+cke_(editable|contents)/i ) ) {
+ var tmp,
+ editable_wrapper,
+ wrapper = new CKEDITOR.dom.element( 'div' );
+
+ wrapper.setHtml( data );
+ // Verify for sure and check for nested editor UI parts. (#9675)
+ while ( wrapper.getChildCount() == 1 &&
+ ( tmp = wrapper.getFirst() ) &&
+ tmp.type == CKEDITOR.NODE_ELEMENT && // Make sure first-child is element.
+ ( tmp.hasClass( 'cke_editable' ) || tmp.hasClass( 'cke_contents' ) ) ) {
+ wrapper = editable_wrapper = tmp;
+ }
+
+ // If editable wrapper was found strip it and bogus (added on FF).
+ if ( editable_wrapper )
+ data = editable_wrapper.getHtml().replace( / $/i, '' );
+ }
+
+ if ( CKEDITOR.env.ie ) {
+ //
->
(br.cke-pasted-remove will be removed later)
+ data = data.replace( /^ (?: |\r\n)?<(\w+)/g, function( match, elementName ) {
+ if ( elementName.toLowerCase() in blockElements ) {
+ evt.data.preSniffing = 'html'; // Mark as not a text.
+ return '<' + elementName;
+ }
+ return match;
+ } );
+ } else if ( CKEDITOR.env.webkit ) {
+ //
->
+ // We don't mark br, because this situation can happen for htmlified text too.
+ data = data.replace( /<\/(\w+)>
<\/div>$/, function( match, elementName ) {
+ if ( elementName in blockElements ) {
+ evt.data.endsWithEOL = 1;
+ return '' + elementName + '>';
+ }
+ return match;
+ } );
+ } else if ( CKEDITOR.env.gecko ) {
+ // Firefox adds bogus when user pasted text followed by space(s).
+ data = data.replace( /(\s) $/, '$1' );
+ }
+
+ evt.data.dataValue = data;
+ }, null, null, 3 );
+
+ editor.on( 'paste', function( evt ) {
+ var dataObj = evt.data,
+ type = dataObj.type,
+ data = dataObj.dataValue,
+ trueType,
+ // Default is 'html'.
+ defaultType = editor.config.clipboard_defaultContentType || 'html',
+ transferType = dataObj.dataTransfer.getTransferType( editor );
+
+ // If forced type is 'html' we don't need to know true data type.
+ if ( type == 'html' || dataObj.preSniffing == 'html' ) {
+ trueType = 'html';
+ } else {
+ trueType = recogniseContentType( data );
+ }
+
+ // Unify text markup.
+ if ( trueType == 'htmlifiedtext' ) {
+ data = htmlifiedTextHtmlification( editor.config, data );
+ }
+
+ // Strip presentational markup & unify text markup.
+ // Forced plain text (dialog or forcePAPT).
+ // Note: we do not check dontFilter option in this case, because forcePAPT was implemented
+ // before pasteFilter and pasteFilter is automatically used on Webkit&Blink since 4.5, so
+ // forcePAPT should have priority as it had before 4.5.
+ if ( type == 'text' && trueType == 'html' ) {
+ data = filterContent( editor, data, filtersFactory.get( 'plain-text' ) );
+ }
+ // External paste and pasteFilter exists and filtering isn't disabled.
+ else if ( transferType == CKEDITOR.DATA_TRANSFER_EXTERNAL && editor.pasteFilter && !dataObj.dontFilter ) {
+ data = filterContent( editor, data, editor.pasteFilter );
+ }
+
+ if ( dataObj.startsWithEOL ) {
+ data = ' ' + data;
+ }
+ if ( dataObj.endsWithEOL ) {
+ data += ' ';
+ }
+
+ if ( type == 'auto' ) {
+ type = ( trueType == 'html' || defaultType == 'html' ) ? 'html' : 'text';
+ }
+
+ dataObj.type = type;
+ dataObj.dataValue = data;
+ delete dataObj.preSniffing;
+ delete dataObj.startsWithEOL;
+ delete dataObj.endsWithEOL;
+ }, null, null, 6 );
+
+ // Inserts processed data into the editor at the end of the
+ // events chain.
+ editor.on( 'paste', function( evt ) {
+ var data = evt.data;
+
+ if ( data.dataValue ) {
+ editor.insertHtml( data.dataValue, data.type, data.range );
+
+ // Defer 'afterPaste' so all other listeners for 'paste' will be fired first.
+ // Fire afterPaste only if paste inserted some HTML.
+ setTimeout( function() {
+ editor.fire( 'afterPaste' );
+ }, 0 );
+ }
+ }, null, null, 1000 );
+
+ editor.on( 'pasteDialog', function( evt ) {
+ // TODO it's possible that this setTimeout is not needed any more,
+ // because of changes introduced in the same commit as this comment.
+ // Editor.getClipboardData adds listener to the dialog's events which are
+ // fired after a while (not like 'showDialog').
+ setTimeout( function() {
+ // Open default paste dialog.
+ editor.openDialog( 'paste', evt.data );
+ }, 0 );
+ } );
+ }
+ } );
+
+ function firePasteEvents( editor, data, withBeforePaste ) {
+ if ( !data.type ) {
+ data.type = 'auto';
+ }
+
+ if ( withBeforePaste ) {
+ // Fire 'beforePaste' event so clipboard flavor get customized
+ // by other plugins.
+ if ( editor.fire( 'beforePaste', data ) === false )
+ return false; // Event canceled
+ }
+
+ // Do not fire paste if there is no data (dataValue and dataTranfser are empty).
+ // This check should be done after firing 'beforePaste' because for native paste
+ // 'beforePaste' is by default fired even for empty clipboard.
+ if ( !data.dataValue && data.dataTransfer.isEmpty() ) {
+ return false;
+ }
+
+ if ( !data.dataValue ) {
+ data.dataValue = '';
+ }
+
+ // Because of FF bug we need to use this hack, otherwise cursor is hidden
+ // or it is not possible to move it (#12420).
+ // Also, check that editor.toolbox exists, because the toolbar plugin might not be loaded (#13305).
+ if ( CKEDITOR.env.gecko && data.method == 'drop' && editor.toolbox ) {
+ editor.once( 'afterPaste', function() {
+ editor.toolbox.focus();
+ } );
+ }
+
+ return editor.fire( 'paste', data );
+ }
+
+ function initPasteClipboard( editor ) {
+ var clipboard = CKEDITOR.plugins.clipboard,
+ preventBeforePasteEvent = 0,
+ preventPasteEvent = 0,
+ inReadOnly = 0;
+
+ addListeners();
+ addButtonsCommands();
+
+ /**
+ * Gets clipboard data by directly accessing the clipboard (IE only) or opening the paste dialog window.
+ *
+ * editor.getClipboardData( { title: 'Get my data' }, function( data ) {
+ * if ( data )
+ * alert( data.type + ' ' + data.dataValue );
+ * } );
+ *
+ * @member CKEDITOR.editor
+ * @param {Object} options
+ * @param {String} [options.title] The title of the paste dialog window.
+ * @param {Function} callback A function that will be executed with `data.type` and `data.dataValue`
+ * or `null` if none of the capturing methods succeeded.
+ */
+ editor.getClipboardData = function( options, callback ) {
+ var beforePasteNotCanceled = false,
+ dataType = 'auto',
+ dialogCommited = false;
+
+ // Options are optional - args shift.
+ if ( !callback ) {
+ callback = options;
+ options = null;
+ }
+
+ // Listen with maximum priority to handle content before everyone else.
+ // This callback will handle paste event that will be fired if direct
+ // access to the clipboard succeed in IE.
+ editor.on( 'paste', onPaste, null, null, 0 );
+
+ // Listen at the end of listeners chain to see if event wasn't canceled
+ // and to retrieve modified data.type.
+ editor.on( 'beforePaste', onBeforePaste, null, null, 1000 );
+
+ // getClipboardDataDirectly() will fire 'beforePaste' synchronously, so we can
+ // check if it was canceled and if any listener modified data.type.
+
+ // If command didn't succeed (only IE allows to access clipboard and only if
+ // user agrees) open and handle paste dialog.
+ if ( getClipboardDataDirectly() === false ) {
+ // Direct access to the clipboard wasn't successful so remove listener.
+ editor.removeListener( 'paste', onPaste );
+
+ // If beforePaste was canceled do not open dialog.
+ // Add listeners only if dialog really opened. 'pasteDialog' can be canceled.
+ if ( beforePasteNotCanceled && editor.fire( 'pasteDialog', onDialogOpen ) ) {
+ editor.on( 'pasteDialogCommit', onDialogCommit );
+
+ // 'dialogHide' will be fired after 'pasteDialogCommit'.
+ editor.on( 'dialogHide', function( evt ) {
+ evt.removeListener();
+ evt.data.removeListener( 'pasteDialogCommit', onDialogCommit );
+
+ // Because Opera has to wait a while in pasteDialog we have to wait here.
+ setTimeout( function() {
+ // Notify even if user canceled dialog (clicked 'cancel', ESC, etc).
+ if ( !dialogCommited )
+ callback( null );
+ }, 10 );
+ } );
+ } else {
+ callback( null );
+ }
+ }
+
+ function onPaste( evt ) {
+ evt.removeListener();
+ evt.cancel();
+ callback( evt.data );
+ }
+
+ function onBeforePaste( evt ) {
+ evt.removeListener();
+ beforePasteNotCanceled = true;
+ dataType = evt.data.type;
+ }
+
+ function onDialogCommit( evt ) {
+ evt.removeListener();
+ // Cancel pasteDialogCommit so paste dialog won't automatically fire
+ // 'paste' evt by itself.
+ evt.cancel();
+ dialogCommited = true;
+ callback( {
+ type: dataType,
+ dataValue: evt.data.dataValue,
+ dataTransfer: evt.data.dataTransfer,
+ method: 'paste'
+ } );
+ }
+
+ function onDialogOpen() {
+ this.customTitle = ( options && options.title );
+ }
+ };
+
+ function addButtonsCommands() {
+ addButtonCommand( 'Cut', 'cut', createCutCopyCmd( 'cut' ), 10, 1 );
+ addButtonCommand( 'Copy', 'copy', createCutCopyCmd( 'copy' ), 20, 4 );
+ addButtonCommand( 'Paste', 'paste', createPasteCmd(), 30, 8 );
+
+ function addButtonCommand( buttonName, commandName, command, toolbarOrder, ctxMenuOrder ) {
+ var lang = editor.lang.clipboard[ commandName ];
+
+ editor.addCommand( commandName, command );
+ editor.ui.addButton && editor.ui.addButton( buttonName, {
+ label: lang,
+ command: commandName,
+ toolbar: 'clipboard,' + toolbarOrder
+ } );
+
+ // If the "menu" plugin is loaded, register the menu item.
+ if ( editor.addMenuItems ) {
+ editor.addMenuItem( commandName, {
+ label: lang,
+ command: commandName,
+ group: 'clipboard',
+ order: ctxMenuOrder
+ } );
+ }
+ }
+ }
+
+ function addListeners() {
+ editor.on( 'key', onKey );
+ editor.on( 'contentDom', addPasteListenersToEditable );
+
+ // For improved performance, we're checking the readOnly state on selectionChange instead of hooking a key event for that.
+ editor.on( 'selectionChange', function( evt ) {
+ inReadOnly = evt.data.selection.getRanges()[ 0 ].checkReadOnly();
+ setToolbarStates();
+ } );
+
+ // If the "contextmenu" plugin is loaded, register the listeners.
+ if ( editor.contextMenu ) {
+ editor.contextMenu.addListener( function( element, selection ) {
+ inReadOnly = selection.getRanges()[ 0 ].checkReadOnly();
+ return {
+ cut: stateFromNamedCommand( 'cut' ),
+ copy: stateFromNamedCommand( 'copy' ),
+ paste: stateFromNamedCommand( 'paste' )
+ };
+ } );
+ }
+ }
+
+ // Add events listeners to editable.
+ function addPasteListenersToEditable() {
+ var editable = editor.editable();
+
+ if ( CKEDITOR.plugins.clipboard.isCustomCopyCutSupported ) {
+ var initOnCopyCut = function( evt ) {
+ // If user tries to cut in read-only editor, we must prevent default action. (#13872)
+ if ( !editor.readOnly || evt.name != 'cut' ) {
+ clipboard.initPasteDataTransfer( evt, editor );
+ }
+ evt.data.preventDefault();
+ };
+
+ editable.on( 'copy', initOnCopyCut );
+ editable.on( 'cut', initOnCopyCut );
+
+ // Delete content with the low priority so one can overwrite cut data.
+ editable.on( 'cut', function() {
+ // If user tries to cut in read-only editor, we must prevent default action. (#13872)
+ if ( !editor.readOnly ) {
+ editor.extractSelectedHtml();
+ }
+ }, null, null, 999 );
+ }
+
+ // We'll be catching all pasted content in one line, regardless of whether
+ // it's introduced by a document command execution (e.g. toolbar buttons) or
+ // user paste behaviors (e.g. CTRL+V).
+ editable.on( clipboard.mainPasteEvent, function( evt ) {
+ if ( clipboard.mainPasteEvent == 'beforepaste' && preventBeforePasteEvent ) {
+ return;
+ }
+
+ // If you've just asked yourself why preventPasteEventNow() is not here, but
+ // in listener for CTRL+V and exec method of 'paste' command
+ // you've asked the same question we did.
+ //
+ // THE ANSWER:
+ //
+ // First thing to notice - this answer makes sense only for IE,
+ // because other browsers don't listen for 'paste' event.
+ //
+ // What would happen if we move preventPasteEventNow() here?
+ // For:
+ // * CTRL+V - IE fires 'beforepaste', so we prevent 'paste' and pasteDataFromClipboard(). OK.
+ // * editor.execCommand( 'paste' ) - we fire 'beforepaste', so we prevent
+ // 'paste' and pasteDataFromClipboard() and doc.execCommand( 'Paste' ). OK.
+ // * native context menu - IE fires 'beforepaste', so we prevent 'paste', but unfortunately
+ // on IE we fail with pasteDataFromClipboard() here, because of... we don't know why, but
+ // we just fail, so... we paste nothing. FAIL.
+ // * native menu bar - the same as for native context menu.
+ //
+ // But don't you know any way to distinguish first two cases from last two?
+ // Only one - special flag set in CTRL+V handler and exec method of 'paste'
+ // command. And that's what we did using preventPasteEventNow().
+
+ pasteDataFromClipboard( evt );
+ } );
+
+ // It's not possible to clearly handle all four paste methods (ctrl+v, native menu bar
+ // native context menu, editor's command) in one 'paste/beforepaste' event in IE.
+ //
+ // For ctrl+v & editor's command it's easy to handle pasting in 'beforepaste' listener,
+ // so we do this. For another two methods it's better to use 'paste' event.
+ //
+ // 'paste' is always being fired after 'beforepaste' (except of weird one on opening native
+ // context menu), so for two methods handled in 'beforepaste' we're canceling 'paste'
+ // using preventPasteEvent state.
+ //
+ // 'paste' event in IE is being fired before getClipboardDataByPastebin executes its callback.
+ //
+ // QUESTION: Why didn't you handle all 4 paste methods in handler for 'paste'?
+ // Wouldn't this just be simpler?
+ // ANSWER: Then we would have to evt.data.preventDefault() only for native
+ // context menu and menu bar pastes. The same with execIECommand().
+ // That would force us to mark CTRL+V and editor's paste command with
+ // special flag, other than preventPasteEvent. But we still would have to
+ // have preventPasteEvent for the second event fired by execIECommand.
+ // Code would be longer and not cleaner.
+ if ( clipboard.mainPasteEvent == 'beforepaste' ) {
+ editable.on( 'paste', function( evt ) {
+ if ( preventPasteEvent ) {
+ return;
+ }
+
+ // Cancel next 'paste' event fired by execIECommand( 'paste' )
+ // at the end of this callback.
+ preventPasteEventNow();
+
+ // Prevent native paste.
+ evt.data.preventDefault();
+
+ pasteDataFromClipboard( evt );
+
+ // Force IE to paste content into pastebin so pasteDataFromClipboard will work.
+ if ( !execIECommand( 'paste' ) ) {
+ editor.openDialog( 'paste' );
+ }
+ } );
+
+ // If mainPasteEvent is 'beforePaste' (IE before Edge),
+ // dismiss the (wrong) 'beforepaste' event fired on context/toolbar menu open. (#7953)
+ editable.on( 'contextmenu', preventBeforePasteEventNow, null, null, 0 );
+
+ editable.on( 'beforepaste', function( evt ) {
+ // Do not prevent event on CTRL+V and SHIFT+INS because it blocks paste (#11970).
+ if ( evt.data && !evt.data.$.ctrlKey && !evt.data.$.shiftKey )
+ preventBeforePasteEventNow();
+ }, null, null, 0 );
+ }
+
+ editable.on( 'beforecut', function() {
+ !preventBeforePasteEvent && fixCut( editor );
+ } );
+
+ var mouseupTimeout;
+
+ // Use editor.document instead of editable in non-IEs for observing mouseup
+ // since editable won't fire the event if selection process started within
+ // iframe and ended out of the editor (#9851).
+ editable.attachListener( CKEDITOR.env.ie ? editable : editor.document.getDocumentElement(), 'mouseup', function() {
+ mouseupTimeout = setTimeout( function() {
+ setToolbarStates();
+ }, 0 );
+ } );
+
+ // Make sure that deferred mouseup callback isn't executed after editor instance
+ // had been destroyed. This may happen when editor.destroy() is called in parallel
+ // with mouseup event (i.e. a button with onclick callback) (#10219).
+ editor.on( 'destroy', function() {
+ clearTimeout( mouseupTimeout );
+ } );
+
+ editable.on( 'keyup', setToolbarStates );
+ }
+
+ // Create object representing Cut or Copy commands.
+ function createCutCopyCmd( type ) {
+ return {
+ type: type,
+ canUndo: type == 'cut', // We can't undo copy to clipboard.
+ startDisabled: true,
+ exec: function() {
+ // Attempts to execute the Cut and Copy operations.
+ function tryToCutCopy( type ) {
+ if ( CKEDITOR.env.ie )
+ return execIECommand( type );
+
+ // non-IEs part
+ try {
+ // Other browsers throw an error if the command is disabled.
+ return editor.document.$.execCommand( type, false, null );
+ } catch ( e ) {
+ return false;
+ }
+ }
+
+ this.type == 'cut' && fixCut();
+
+ var success = tryToCutCopy( this.type );
+
+ if ( !success ) {
+ // Show cutError or copyError.
+ editor.showNotification( editor.lang.clipboard[ this.type + 'Error' ] ); // jshint ignore:line
+ }
+
+ return success;
+ }
+ };
+ }
+
+ function createPasteCmd() {
+ return {
+ // Snapshots are done manually by editable.insertXXX methods.
+ canUndo: false,
+ async: true,
+
+ exec: function( editor, data ) {
+ var cmd = this,
+ fire = function( data, withBeforePaste ) {
+ data && firePasteEvents( editor, data, !!withBeforePaste );
+
+ editor.fire( 'afterCommandExec', {
+ name: 'paste',
+ command: cmd,
+ returnValue: !!data
+ } );
+ };
+
+ // Check data precisely - don't open dialog on empty string.
+ if ( typeof data == 'string' )
+ fire( {
+ dataValue: data,
+ method: 'paste',
+ dataTransfer: clipboard.initPasteDataTransfer()
+ }, 1 );
+ else
+ editor.getClipboardData( fire );
+ }
+ };
+ }
+
+ function preventPasteEventNow() {
+ preventPasteEvent = 1;
+ // For safety reason we should wait longer than 0/1ms.
+ // We don't know how long execution of quite complex getClipboardData will take
+ // and in for example 'paste' listener execCommand() (which fires 'paste') is called
+ // after getClipboardData finishes.
+ // Luckily, it's impossible to immediately fire another 'paste' event we want to handle,
+ // because we only handle there native context menu and menu bar.
+ setTimeout( function() {
+ preventPasteEvent = 0;
+ }, 100 );
+ }
+
+ function preventBeforePasteEventNow() {
+ preventBeforePasteEvent = 1;
+ setTimeout( function() {
+ preventBeforePasteEvent = 0;
+ }, 10 );
+ }
+
+ // Tries to execute any of the paste, cut or copy commands in IE. Returns a
+ // boolean indicating that the operation succeeded.
+ // @param {String} command *LOWER CASED* name of command ('paste', 'cut', 'copy').
+ function execIECommand( command ) {
+ var doc = editor.document,
+ body = doc.getBody(),
+ enabled = false,
+ onExec = function() {
+ enabled = true;
+ };
+
+ // The following seems to be the only reliable way to detect that
+ // clipboard commands are enabled in IE. It will fire the
+ // onpaste/oncut/oncopy events only if the security settings allowed
+ // the command to execute.
+ body.on( command, onExec );
+
+ // IE7: document.execCommand has problem to paste into positioned element.
+ if ( CKEDITOR.env.version > 7 ) {
+ doc.$.execCommand( command );
+ } else {
+ doc.$.selection.createRange().execCommand( command );
+ }
+
+ body.removeListener( command, onExec );
+
+ return enabled;
+ }
+
+ // Cutting off control type element in IE standards breaks the selection entirely. (#4881)
+ function fixCut() {
+ if ( !CKEDITOR.env.ie || CKEDITOR.env.quirks )
+ return;
+
+ var sel = editor.getSelection(),
+ control, range, dummy;
+
+ if ( ( sel.getType() == CKEDITOR.SELECTION_ELEMENT ) && ( control = sel.getSelectedElement() ) ) {
+ range = sel.getRanges()[ 0 ];
+ dummy = editor.document.createText( '' );
+ dummy.insertBefore( control );
+ range.setStartBefore( dummy );
+ range.setEndAfter( control );
+ sel.selectRanges( [ range ] );
+
+ // Clear up the fix if the paste wasn't succeeded.
+ setTimeout( function() {
+ // Element still online?
+ if ( control.getParent() ) {
+ dummy.remove();
+ sel.selectElement( control );
+ }
+ }, 0 );
+ }
+ }
+
+ // Allow to peek clipboard content by redirecting the
+ // pasting content into a temporary bin and grab the content of it.
+ function getClipboardDataByPastebin( evt, callback ) {
+ var doc = editor.document,
+ editable = editor.editable(),
+ cancel = function( evt ) {
+ evt.cancel();
+ },
+ blurListener;
+
+ // Avoid recursions on 'paste' event or consequent paste too fast. (#5730)
+ if ( doc.getById( 'cke_pastebin' ) )
+ return;
+
+ var sel = editor.getSelection();
+ var bms = sel.createBookmarks();
+
+ // #11384. On IE9+ we use native selectionchange (i.e. editor#selectionCheck) to cache the most
+ // recent selection which we then lock on editable blur. See selection.js for more info.
+ // selectionchange fired before getClipboardDataByPastebin() cached selection
+ // before creating bookmark (cached selection will be invalid, because bookmarks modified the DOM),
+ // so we need to fire selectionchange one more time, to store current seleciton.
+ // Selection will be locked when we focus pastebin.
+ if ( CKEDITOR.env.ie )
+ sel.root.fire( 'selectionchange' );
+
+ // Create container to paste into.
+ // For rich content we prefer to use "body" since it holds
+ // the least possibility to be splitted by pasted content, while this may
+ // breaks the text selection on a frame-less editable, "div" would be
+ // the best one in that case.
+ // In another case on old IEs moving the selection into a "body" paste bin causes error panic.
+ // Body can't be also used for Opera which fills it with
+ // what is indistinguishable from pasted (copying in Opera isn't possible,
+ // but it can be copied from other browser).
+ var pastebin = new CKEDITOR.dom.element(
+ ( CKEDITOR.env.webkit || editable.is( 'body' ) ) && !CKEDITOR.env.ie ? 'body' : 'div', doc );
+
+ pastebin.setAttributes( {
+ id: 'cke_pastebin',
+ 'data-cke-temp': '1'
+ } );
+
+ var containerOffset = 0,
+ offsetParent,
+ win = doc.getWindow();
+
+ if ( CKEDITOR.env.webkit ) {
+ // It's better to paste close to the real paste destination, so inherited styles
+ // (which Webkits will try to compensate by styling span) differs less from the destination's one.
+ editable.append( pastebin );
+ // Style pastebin like .cke_editable, to minimize differences between origin and destination. (#9754)
+ pastebin.addClass( 'cke_editable' );
+
+ // Compensate position of offsetParent.
+ if ( !editable.is( 'body' ) ) {
+ // We're not able to get offsetParent from pastebin (body element), so check whether
+ // its parent (editable) is positioned.
+ if ( editable.getComputedStyle( 'position' ) != 'static' )
+ offsetParent = editable;
+ // And if not - safely get offsetParent from editable.
+ else
+ offsetParent = CKEDITOR.dom.element.get( editable.$.offsetParent );
+
+ containerOffset = offsetParent.getDocumentPosition().y;
+ }
+ } else {
+ // Opera and IE doesn't allow to append to html element.
+ editable.getAscendant( CKEDITOR.env.ie ? 'body' : 'html', 1 ).append( pastebin );
+ }
+
+ pastebin.setStyles( {
+ position: 'absolute',
+ // Position the bin at the top (+10 for safety) of viewport to avoid any subsequent document scroll.
+ top: ( win.getScrollPosition().y - containerOffset + 10 ) + 'px',
+ width: '1px',
+ // Caret has to fit in that height, otherwise browsers like Chrome & Opera will scroll window to show it.
+ // Set height equal to viewport's height - 20px (safety gaps), minimum 1px.
+ height: Math.max( 1, win.getViewPaneSize().height - 20 ) + 'px',
+ overflow: 'hidden',
+ // Reset styles that can mess up pastebin position.
+ margin: 0,
+ padding: 0
+ } );
+
+ // Paste fails in Safari when the body tag has 'user-select: none'. (#12506)
+ if ( CKEDITOR.env.safari )
+ pastebin.setStyles( CKEDITOR.tools.cssVendorPrefix( 'user-select', 'text' ) );
+
+ // Check if the paste bin now establishes new editing host.
+ var isEditingHost = pastebin.getParent().isReadOnly();
+
+ if ( isEditingHost ) {
+ // Hide the paste bin.
+ pastebin.setOpacity( 0 );
+ // And make it editable.
+ pastebin.setAttribute( 'contenteditable', true );
+ }
+ // Transparency is not enough since positioned non-editing host always shows
+ // resize handler, pull it off the screen instead.
+ else {
+ pastebin.setStyle( editor.config.contentsLangDirection == 'ltr' ? 'left' : 'right', '-10000px' );
+ }
+
+ editor.on( 'selectionChange', cancel, null, null, 0 );
+
+ // Webkit fill fire blur on editable when moving selection to
+ // pastebin (if body is used). Cancel it because it causes incorrect
+ // selection lock in case of inline editor (#10644).
+ // The same seems to apply to Firefox (#10787).
+ if ( CKEDITOR.env.webkit || CKEDITOR.env.gecko )
+ blurListener = editable.once( 'blur', cancel, null, null, -100 );
+
+ // Temporarily move selection to the pastebin.
+ isEditingHost && pastebin.focus();
+ var range = new CKEDITOR.dom.range( pastebin );
+ range.selectNodeContents( pastebin );
+ var selPastebin = range.select();
+
+ // If non-native paste is executed, IE will open security alert and blur editable.
+ // Editable will then lock selection inside itself and after accepting security alert
+ // this selection will be restored. We overwrite stored selection, so it's restored
+ // in pastebin. (#9552)
+ if ( CKEDITOR.env.ie ) {
+ blurListener = editable.once( 'blur', function() {
+ editor.lockSelection( selPastebin );
+ } );
+ }
+
+ var scrollTop = CKEDITOR.document.getWindow().getScrollPosition().y;
+
+ // Wait a while and grab the pasted contents.
+ setTimeout( function() {
+ // Restore main window's scroll position which could have been changed
+ // by browser in cases described in #9771.
+ if ( CKEDITOR.env.webkit )
+ CKEDITOR.document.getBody().$.scrollTop = scrollTop;
+
+ // Blur will be fired only on non-native paste. In other case manually remove listener.
+ blurListener && blurListener.removeListener();
+
+ // Restore properly the document focus. (#8849)
+ if ( CKEDITOR.env.ie )
+ editable.focus();
+
+ // IE7: selection must go before removing pastebin. (#8691)
+ sel.selectBookmarks( bms );
+ pastebin.remove();
+
+ // Grab the HTML contents.
+ // We need to look for a apple style wrapper on webkit it also adds
+ // a div wrapper if you copy/paste the body of the editor.
+ // Remove hidden div and restore selection.
+ var bogusSpan;
+ if ( CKEDITOR.env.webkit && ( bogusSpan = pastebin.getFirst() ) && ( bogusSpan.is && bogusSpan.hasClass( 'Apple-style-span' ) ) )
+ pastebin = bogusSpan;
+
+ editor.removeListener( 'selectionChange', cancel );
+ callback( pastebin.getHtml() );
+ }, 0 );
+ }
+
+ // Try to get content directly on IE from clipboard, without native event
+ // being fired before. In other words - synthetically get clipboard data, if it's possible.
+ // mainPasteEvent will be fired, so if forced native paste:
+ // * worked, getClipboardDataByPastebin will grab it,
+ // * didn't work, dataValue and dataTransfer will be empty and editor#paste won't be fired.
+ // Clipboard data can be accessed directly only on IEs older than Edge.
+ // On other browsers we should fire beforePaste event and return false.
+ function getClipboardDataDirectly() {
+ if ( clipboard.mainPasteEvent == 'paste' ) {
+ // beforePaste should be fired when dialog open so it can be canceled.
+ editor.fire( 'beforePaste', { type: 'auto', method: 'paste' } );
+ return false;
+ }
+
+ // Prevent IE from pasting at the begining of the document.
+ editor.focus();
+
+ // Command will be handled by 'beforepaste', but as
+ // execIECommand( 'paste' ) will fire also 'paste' event
+ // we're canceling it.
+ preventPasteEventNow();
+
+ // #9247: Lock focus to prevent IE from hiding toolbar for inline editor.
+ var focusManager = editor.focusManager;
+ focusManager.lock();
+
+ if ( editor.editable().fire( clipboard.mainPasteEvent ) && !execIECommand( 'paste' ) ) {
+ focusManager.unlock();
+ return false;
+ }
+ focusManager.unlock();
+
+ return true;
+ }
+
+ // Listens for some clipboard related keystrokes, so they get customized.
+ // Needs to be bind to keydown event.
+ function onKey( event ) {
+ if ( editor.mode != 'wysiwyg' )
+ return;
+
+ switch ( event.data.keyCode ) {
+ // Paste
+ case CKEDITOR.CTRL + 86: // CTRL+V
+ case CKEDITOR.SHIFT + 45: // SHIFT+INS
+ var editable = editor.editable();
+
+ // Cancel 'paste' event because ctrl+v is for IE handled
+ // by 'beforepaste'.
+ preventPasteEventNow();
+
+ // Simulate 'beforepaste' event for all browsers using 'paste' as main event.
+ if ( clipboard.mainPasteEvent == 'paste' ) {
+ editable.fire( 'beforepaste' );
+ }
+
+ return;
+
+ // Cut
+ case CKEDITOR.CTRL + 88: // CTRL+X
+ case CKEDITOR.SHIFT + 46: // SHIFT+DEL
+ // Save Undo snapshot.
+ editor.fire( 'saveSnapshot' ); // Save before cut
+ setTimeout( function() {
+ editor.fire( 'saveSnapshot' ); // Save after cut
+ }, 50 ); // OSX is slow (#11416).
+ }
+ }
+
+ function pasteDataFromClipboard( evt ) {
+ // Default type is 'auto', but can be changed by beforePaste listeners.
+ var eventData = {
+ type: 'auto',
+ method: 'paste',
+ dataTransfer: clipboard.initPasteDataTransfer( evt )
+ };
+
+ eventData.dataTransfer.cacheData();
+
+ // Fire 'beforePaste' event so clipboard flavor get customized by other plugins.
+ // If 'beforePaste' is canceled continue executing getClipboardDataByPastebin and then do nothing
+ // (do not fire 'paste', 'afterPaste' events). This way we can grab all - synthetically
+ // and natively pasted content and prevent its insertion into editor
+ // after canceling 'beforePaste' event.
+ var beforePasteNotCanceled = editor.fire( 'beforePaste', eventData ) !== false;
+
+ // Do not use paste bin if the browser let us get HTML or files from dataTranfer.
+ if ( beforePasteNotCanceled && clipboard.canClipboardApiBeTrusted( eventData.dataTransfer, editor ) ) {
+ evt.data.preventDefault();
+ setTimeout( function() {
+ firePasteEvents( editor, eventData );
+ }, 0 );
+ } else {
+ getClipboardDataByPastebin( evt, function( data ) {
+ // Clean up.
+ eventData.dataValue = data.replace( /]+data-cke-bookmark[^<]*?<\/span>/ig, '' );
+
+ // Fire remaining events (without beforePaste)
+ beforePasteNotCanceled && firePasteEvents( editor, eventData );
+ } );
+ }
+ }
+
+ function setToolbarStates() {
+ if ( editor.mode != 'wysiwyg' )
+ return;
+
+ var pasteState = stateFromNamedCommand( 'paste' );
+
+ editor.getCommand( 'cut' ).setState( stateFromNamedCommand( 'cut' ) );
+ editor.getCommand( 'copy' ).setState( stateFromNamedCommand( 'copy' ) );
+ editor.getCommand( 'paste' ).setState( pasteState );
+ editor.fire( 'pasteState', pasteState );
+ }
+
+ function stateFromNamedCommand( command ) {
+ if ( inReadOnly && command in { paste: 1, cut: 1 } )
+ return CKEDITOR.TRISTATE_DISABLED;
+
+ if ( command == 'paste' )
+ return CKEDITOR.TRISTATE_OFF;
+
+ // Cut, copy - check if the selection is not empty.
+ var sel = editor.getSelection(),
+ ranges = sel.getRanges(),
+ selectionIsEmpty = sel.getType() == CKEDITOR.SELECTION_NONE || ( ranges.length == 1 && ranges[ 0 ].collapsed );
+
+ return selectionIsEmpty ? CKEDITOR.TRISTATE_DISABLED : CKEDITOR.TRISTATE_OFF;
+ }
+ }
+
+ // Returns:
+ // * 'htmlifiedtext' if content looks like transformed by browser from plain text.
+ // See clipboard/paste.html TCs for more info.
+ // * 'html' if it is not 'htmlifiedtext'.
+ function recogniseContentType( data ) {
+ if ( CKEDITOR.env.webkit ) {
+ // Plain text or (
and text inside
).
+ if ( !data.match( /^[^<]*$/g ) && !data.match( /^(
<\/div>|
[^<]*<\/div>)*$/gi ) )
+ return 'html';
+ } else if ( CKEDITOR.env.ie ) {
+ // Text and or ( text and in
- paragraphs can be separated by new \r\n ).
+ if ( !data.match( /^([^<]| )*$/gi ) && !data.match( /^(
([^<]| )*<\/p>|(\r\n))*$/gi ) )
+ return 'html';
+ } else if ( CKEDITOR.env.gecko ) {
+ // Text or .
+ if ( !data.match( /^([^<]| )*$/gi ) )
+ return 'html';
+ } else {
+ return 'html';
+ }
+
+ return 'htmlifiedtext';
+ }
+
+ // This function transforms what browsers produce when
+ // pasting plain text into editable element (see clipboard/paste.html TCs
+ // for more info) into correct HTML (similar to that produced by text2Html).
+ function htmlifiedTextHtmlification( config, data ) {
+ function repeatParagraphs( repeats ) {
+ // Repeat blocks floor((n+1)/2) times.
+ // Even number of repeats - add at the beginning of last
.
+ return CKEDITOR.tools.repeat( '
', ~~( repeats / 2 ) ) + ( repeats % 2 == 1 ? ' ' : '' );
+ }
+
+ // Replace adjacent white-spaces (EOLs too - Fx sometimes keeps them) with one space.
+ data = data.replace( /\s+/g, ' ' )
+ // Remove spaces from between tags.
+ .replace( /> +<' )
+ // Normalize XHTML syntax and upper cased tags.
+ .replace( / /gi, ' ' );
+
+ // IE - lower cased tags.
+ data = data.replace( /<\/?[A-Z]+>/g, function( match ) {
+ return match.toLowerCase();
+ } );
+
+ // Don't touch single lines (no ) - nothing to do here.
+ if ( data.match( /^[^<]$/ ) )
+ return data;
+
+ // Webkit.
+ if ( CKEDITOR.env.webkit && data.indexOf( '
' ) > -1 ) {
+ // One line break at the beginning - insert
+ data = data.replace( /^(
( |)<\/div>)(?!$|(
( |)<\/div>))/g, ' ' )
+ // Two or more - reduce number of new lines by one.
+ .replace( /^(
( |)<\/div>){2}(?!$)/g, '' );
+
+ // Two line breaks create one paragraph in Webkit.
+ if ( data.match( /
' ).length + 1 );
+ } ) + '';
+ }
+
+ // One line break create br.
+ data = data.replace( /<\/div>
/g, ' ' );
+
+ // Remove remaining divs.
+ data = data.replace( /<\/?div>/g, '' );
+ }
+
+ // Opera and Firefox and enterMode != BR.
+ if ( CKEDITOR.env.gecko && config.enterMode != CKEDITOR.ENTER_BR ) {
+ // Remove bogus - Fx generates two for one line break.
+ // For two line breaks it still produces two , but it's better to ignore this case than the first one.
+ if ( CKEDITOR.env.gecko )
+ data = data.replace( /^
$/, ' ' );
+
+ // This line satisfy edge case when for Opera we have two line breaks
+ //data = data.replace( /)
+
+ if ( data.indexOf( '
' ) > -1 ) {
+ // Two line breaks create one paragraph, three - 2, four - 3, etc.
+ data = '
';
+ }
+ }
+
+ return switchEnterMode( config, data );
+ }
+
+ function filtersFactoryFactory() {
+ var filters = {};
+
+ function setUpTags() {
+ var tags = {};
+
+ for ( var tag in CKEDITOR.dtd ) {
+ if ( tag.charAt( 0 ) != '$' && tag != 'div' && tag != 'span' ) {
+ tags[ tag ] = 1;
+ }
+ }
+
+ return tags;
+ }
+
+ function createSemanticContentFilter() {
+ var filter = new CKEDITOR.filter();
+
+ filter.allow( {
+ $1: {
+ elements: setUpTags(),
+ attributes: true,
+ styles: false,
+ classes: false
+ }
+ } );
+
+ return filter;
+ }
+
+ return {
+ get: function( type ) {
+ if ( type == 'plain-text' ) {
+ // Does this look confusing to you? Did we forget about enter mode?
+ // It is a trick that let's us creating one filter for edidtor, regardless of its
+ // activeEnterMode (which as the name indicates can change during runtime).
+ //
+ // How does it work?
+ // The active enter mode is passed to the filter.applyTo method.
+ // The filter first marks all elements except as disallowed and then tries to remove
+ // them. However, it cannot remove e.g. a
element completely, because it's a basic structural element,
+ // so it tries to replace it with an element created based on the active enter mode, eventually doing nothing.
+ //
+ // Now you can sleep well.
+ return filters.plainText || ( filters.plainText = new CKEDITOR.filter( 'br' ) );
+ } else if ( type == 'semantic-content' ) {
+ return filters.semanticContent || ( filters.semanticContent = createSemanticContentFilter() );
+ } else if ( type ) {
+ // Create filter based on rules (string or object).
+ return new CKEDITOR.filter( type );
+ }
+
+ return null;
+ }
+ };
+ }
+
+ function filterContent( editor, data, filter ) {
+ var fragment = CKEDITOR.htmlParser.fragment.fromHtml( data ),
+ writer = new CKEDITOR.htmlParser.basicWriter();
+
+ filter.applyTo( fragment, true, false, editor.activeEnterMode );
+ fragment.writeHtml( writer );
+
+ return writer.getHtml();
+ }
+
+ function switchEnterMode( config, data ) {
+ if ( config.enterMode == CKEDITOR.ENTER_BR ) {
+ data = data.replace( /(<\/p>
)+/g, function( match ) {
+ return CKEDITOR.tools.repeat( ' ', match.length / 7 * 2 );
+ } ).replace( /<\/?p>/g, '' );
+ } else if ( config.enterMode == CKEDITOR.ENTER_DIV ) {
+ data = data.replace( /<(\/)?p>/g, '<$1div>' );
+ }
+
+ return data;
+ }
+
+ function preventDefaultSetDropEffectToNone( evt ) {
+ evt.data.preventDefault();
+ evt.data.$.dataTransfer.dropEffect = 'none';
+ }
+
+ function initDragDrop( editor ) {
+ var clipboard = CKEDITOR.plugins.clipboard;
+
+ editor.on( 'contentDom', function() {
+ var editable = editor.editable(),
+ dropTarget = CKEDITOR.plugins.clipboard.getDropTarget( editor ),
+ top = editor.ui.space( 'top' ),
+ bottom = editor.ui.space( 'bottom' );
+
+ // -------------- DRAGOVER TOP & BOTTOM --------------
+
+ // Not allowing dragging on toolbar and bottom (#12613).
+ clipboard.preventDefaultDropOnElement( top );
+ clipboard.preventDefaultDropOnElement( bottom );
+
+ // -------------- DRAGSTART --------------
+ // Listed on dragstart to mark internal and cross-editor drag & drop
+ // and save range and selected HTML.
+
+ editable.attachListener( dropTarget, 'dragstart', fireDragEvent );
+
+ // Make sure to reset data transfer (in case dragend was not called or was canceled).
+ editable.attachListener( editor, 'dragstart', clipboard.resetDragDataTransfer, clipboard, null, 1 );
+
+ // Create a dataTransfer object and save it globally.
+ editable.attachListener( editor, 'dragstart', function( evt ) {
+ clipboard.initDragDataTransfer( evt, editor );
+ }, null, null, 2 );
+
+ editable.attachListener( editor, 'dragstart', function() {
+ // Save drag range globally for cross editor D&D.
+ var dragRange = clipboard.dragRange = editor.getSelection().getRanges()[ 0 ];
+
+ // Store number of children, so we can later tell if any text node was split on drop. (#13011, #13447)
+ if ( CKEDITOR.env.ie && CKEDITOR.env.version < 10 ) {
+ clipboard.dragStartContainerChildCount = dragRange ? getContainerChildCount( dragRange.startContainer ) : null;
+ clipboard.dragEndContainerChildCount = dragRange ? getContainerChildCount( dragRange.endContainer ) : null;
+ }
+ }, null, null, 100 );
+
+ // -------------- DRAGEND --------------
+ // Clean up on dragend.
+
+ editable.attachListener( dropTarget, 'dragend', fireDragEvent );
+
+ // Init data transfer if someone wants to use it in dragend.
+ editable.attachListener( editor, 'dragend', clipboard.initDragDataTransfer, clipboard, null, 1 );
+
+ // When drag & drop is done we need to reset dataTransfer so the future
+ // external drop will be not recognize as internal.
+ editable.attachListener( editor, 'dragend', clipboard.resetDragDataTransfer, clipboard, null, 100 );
+
+ // -------------- DRAGOVER --------------
+ // We need to call preventDefault on dragover because otherwise if
+ // we drop image it will overwrite document.
+
+ editable.attachListener( dropTarget, 'dragover', function( evt ) {
+ var target = evt.data.getTarget();
+
+ // Prevent reloading page when dragging image on empty document (#12619).
+ if ( target && target.is && target.is( 'html' ) ) {
+ evt.data.preventDefault();
+ return;
+ }
+
+ // If we do not prevent default dragover on IE the file path
+ // will be loaded and we will lose content. On the other hand
+ // if we prevent it the cursor will not we shown, so we prevent
+ // dragover only on IE, on versions which support file API and only
+ // if the event contains files.
+ if ( CKEDITOR.env.ie &&
+ CKEDITOR.plugins.clipboard.isFileApiSupported &&
+ evt.data.$.dataTransfer.types.contains( 'Files' ) ) {
+ evt.data.preventDefault();
+ }
+ } );
+
+ // -------------- DROP --------------
+
+ editable.attachListener( dropTarget, 'drop', function( evt ) {
+ // Do nothing if event was already prevented. (#13879)
+ if ( evt.data.$.defaultPrevented ) {
+ return;
+ }
+
+ // Cancel native drop.
+ evt.data.preventDefault();
+
+ var target = evt.data.getTarget(),
+ readOnly = target.isReadOnly();
+
+ // Do nothing if drop on non editable element (#13015).
+ // The tag isn't editable (body is), but we want to allow drop on it
+ // (so it is possible to drop below editor contents).
+ if ( readOnly && !( target.type == CKEDITOR.NODE_ELEMENT && target.is( 'html' ) ) ) {
+ return;
+ }
+
+ // Getting drop position is one of the most complex parts.
+ var dropRange = clipboard.getRangeAtDropPosition( evt, editor ),
+ dragRange = clipboard.dragRange;
+
+ // Do nothing if it was not possible to get drop range.
+ if ( !dropRange ) {
+ return;
+ }
+
+ // Fire drop.
+ fireDragEvent( evt, dragRange, dropRange );
+ }, null, null, 9999 );
+
+ // Create dataTransfer or get it, if it was created before.
+ editable.attachListener( editor, 'drop', clipboard.initDragDataTransfer, clipboard, null, 1 );
+
+ // Execute drop action, fire paste.
+ editable.attachListener( editor, 'drop', function( evt ) {
+ var data = evt.data;
+
+ if ( !data ) {
+ return;
+ }
+
+ // Let user modify drag and drop range.
+ var dropRange = data.dropRange,
+ dragRange = data.dragRange,
+ dataTransfer = data.dataTransfer;
+
+ if ( dataTransfer.getTransferType( editor ) == CKEDITOR.DATA_TRANSFER_INTERNAL ) {
+ // Execute drop with a timeout because otherwise selection, after drop,
+ // on IE is in the drag position, instead of drop position.
+ setTimeout( function() {
+ clipboard.internalDrop( dragRange, dropRange, dataTransfer, editor );
+ }, 0 );
+ } else if ( dataTransfer.getTransferType( editor ) == CKEDITOR.DATA_TRANSFER_CROSS_EDITORS ) {
+ crossEditorDrop( dragRange, dropRange, dataTransfer );
+ } else {
+ externalDrop( dropRange, dataTransfer );
+ }
+ }, null, null, 9999 );
+
+ // Cross editor drag and drop (drag in one Editor and drop in the other).
+ function crossEditorDrop( dragRange, dropRange, dataTransfer ) {
+ // Paste event should be fired before delete contents because otherwise
+ // Chrome have a problem with drop range (Chrome split the drop
+ // range container so the offset is bigger then container length).
+ dropRange.select();
+ firePasteEvents( editor, { dataTransfer: dataTransfer, method: 'drop' }, 1 );
+
+ // Remove dragged content and make a snapshot.
+ dataTransfer.sourceEditor.fire( 'saveSnapshot' );
+
+ dataTransfer.sourceEditor.editable().extractHtmlFromRange( dragRange );
+
+ // Make some selection before saving snapshot, otherwise error will be thrown, because
+ // there will be no valid selection after content is removed.
+ dataTransfer.sourceEditor.getSelection().selectRanges( [ dragRange ] );
+ dataTransfer.sourceEditor.fire( 'saveSnapshot' );
+ }
+
+ // Drop from external source.
+ function externalDrop( dropRange, dataTransfer ) {
+ // Paste content into the drop position.
+ dropRange.select();
+
+ firePasteEvents( editor, { dataTransfer: dataTransfer, method: 'drop' }, 1 );
+
+ // Usually we reset DataTranfer on dragend,
+ // but dragend is called on the same element as dragstart
+ // so it will not be called on on external drop.
+ clipboard.resetDragDataTransfer();
+ }
+
+ // Fire drag/drop events (dragstart, dragend, drop).
+ function fireDragEvent( evt, dragRange, dropRange ) {
+ var eventData = {
+ $: evt.data.$,
+ target: evt.data.getTarget()
+ };
+
+ if ( dragRange ) {
+ eventData.dragRange = dragRange;
+ }
+ if ( dropRange ) {
+ eventData.dropRange = dropRange;
+ }
+
+ if ( editor.fire( evt.name, eventData ) === false ) {
+ evt.data.preventDefault();
+ }
+ }
+
+ function getContainerChildCount( container ) {
+ if ( container.type != CKEDITOR.NODE_ELEMENT ) {
+ container = container.getParent();
+ }
+
+ return container.getChildCount();
+ }
+ } );
+ }
+
+ /**
+ * @singleton
+ * @class CKEDITOR.plugins.clipboard
+ */
+ CKEDITOR.plugins.clipboard = {
+ /**
+ * True if the environment allows to set data on copy or cut manually. This value is false in IE, because this browser
+ * shows the security dialog window when the script tries to set clipboard data and on iOS, because custom data is
+ * not saved to clipboard there.
+ *
+ * @since 4.5
+ * @readonly
+ * @property {Boolean}
+ */
+ isCustomCopyCutSupported: !CKEDITOR.env.ie && !CKEDITOR.env.iOS,
+
+ /**
+ * True if the environment supports MIME types and custom data types in dataTransfer/cliboardData getData/setData methods.
+ *
+ * @since 4.5
+ * @readonly
+ * @property {Boolean}
+ */
+ isCustomDataTypesSupported: !CKEDITOR.env.ie,
+
+ /**
+ * True if the environment supports File API.
+ *
+ * @since 4.5
+ * @readonly
+ * @property {Boolean}
+ */
+ isFileApiSupported: !CKEDITOR.env.ie || CKEDITOR.env.version > 9,
+
+ /**
+ * Main native paste event editable should listen to.
+ *
+ * **Note:** Safari does not like the {@link CKEDITOR.editor#beforePaste} event — it sometimes does not
+ * handle Ctrl+C properly. This is probably caused by some race condition between events.
+ * Chrome, Firefox and Edge work well with both events, so it is better to use {@link CKEDITOR.editor#paste}
+ * which will handle pasting from e.g. browsers' menu bars.
+ * IE7/8 does not like the {@link CKEDITOR.editor#paste} event for which it is throwing random errors.
+ *
+ * @since 4.5
+ * @readonly
+ * @property {String}
+ */
+ mainPasteEvent: ( CKEDITOR.env.ie && !CKEDITOR.env.edge ) ? 'beforepaste' : 'paste',
+
+ /**
+ * Returns `true` if it is expected that a browser provides HTML data through the Clipboard API.
+ * If not, this method returns `false` and as a result CKEditor will use the paste bin. Read more in
+ * the [Clipboard Integration](http://docs.ckeditor.com/#!/guide/dev_clipboard-section-clipboard-api) guide.
+ *
+ * @since 4.5.2
+ * @returns {Boolean}
+ */
+ canClipboardApiBeTrusted: function( dataTransfer, editor ) {
+ // If it's an internal or cross-editor data transfer, then it means that custom cut/copy/paste support works
+ // and that the data were put manually on the data transfer so we can be sure that it's available.
+ if ( dataTransfer.getTransferType( editor ) != CKEDITOR.DATA_TRANSFER_EXTERNAL ) {
+ return true;
+ }
+
+ // In Chrome we can trust Clipboard API, with the exception of Chrome on Android (in both - mobile and desktop modes), where
+ // clipboard API is not available so we need to check it (#13187).
+ if ( CKEDITOR.env.chrome && !dataTransfer.isEmpty() ) {
+ return true;
+ }
+
+ // Because of a Firefox bug HTML data are not available in some cases (e.g. paste from Word), in such cases we
+ // need to use the pastebin (#13528, https://bugzilla.mozilla.org/show_bug.cgi?id=1183686).
+ if ( CKEDITOR.env.gecko && ( dataTransfer.getData( 'text/html' ) || dataTransfer.getFilesCount() ) ) {
+ return true;
+ }
+
+ // In Safari and IE HTML data is not available though the Clipboard API.
+ // In Edge things are a bit messy at the moment -
+ // https://connect.microsoft.com/IE/feedback/details/1572456/edge-clipboard-api-text-html-content-messed-up-in-event-clipboarddata
+ // It is safer to use the paste bin in unknown cases.
+ return false;
+ },
+
+ /**
+ * Returns the element that should be used as the target for the drop event.
+ *
+ * @since 4.5
+ * @param {CKEDITOR.editor} editor The editor instance.
+ * @returns {CKEDITOR.dom.domObject} the element that should be used as the target for the drop event.
+ */
+ getDropTarget: function( editor ) {
+ var editable = editor.editable();
+
+ // #11123 Firefox needs to listen on document, because otherwise event won't be fired.
+ // #11086 IE8 cannot listen on document.
+ if ( ( CKEDITOR.env.ie && CKEDITOR.env.version < 9 ) || editable.isInline() ) {
+ return editable;
+ } else {
+ return editor.document;
+ }
+ },
+
+ /**
+ * IE 8 & 9 split text node on drop so the first node contains the
+ * text before the drop position and the second contains the rest. If you
+ * drag the content from the same node you will be not be able to get
+ * it (the range becomes invalid), so you need to join them back.
+ *
+ * Note that the first node in IE 8 & 9 is the original node object
+ * but with shortened content.
+ *
+ * Before:
+ * --- Text Node A ----------------------------------
+ * /\
+ * Drag position
+ *
+ * After (IE 8 & 9):
+ * --- Text Node A ----- --- Text Node B -----------
+ * /\ /\
+ * Drop position Drag position
+ * (invalid)
+ *
+ * After (other browsers):
+ * --- Text Node A ----------------------------------
+ * /\ /\
+ * Drop position Drag position
+ *
+ * **Note:** This function is in the public scope for tests usage only.
+ *
+ * @since 4.5
+ * @private
+ * @param {CKEDITOR.dom.range} dragRange The drag range.
+ * @param {CKEDITOR.dom.range} dropRange The drop range.
+ * @param {Number} preDragStartContainerChildCount The number of children of the drag range start container before the drop.
+ * @param {Number} preDragEndContainerChildCount The number of children of the drag range end container before the drop.
+ */
+ fixSplitNodesAfterDrop: function( dragRange, dropRange, preDragStartContainerChildCount, preDragEndContainerChildCount ) {
+ var dropContainer = dropRange.startContainer;
+
+ if (
+ typeof preDragEndContainerChildCount != 'number' ||
+ typeof preDragStartContainerChildCount != 'number'
+ ) {
+ return;
+ }
+
+ // We are only concerned about ranges anchored in elements.
+ if ( dropContainer.type != CKEDITOR.NODE_ELEMENT ) {
+ return;
+ }
+
+ if ( handleContainer( dragRange.startContainer, dropContainer, preDragStartContainerChildCount ) ) {
+ return;
+ }
+
+ if ( handleContainer( dragRange.endContainer, dropContainer, preDragEndContainerChildCount ) ) {
+ return;
+ }
+
+ function handleContainer( dragContainer, dropContainer, preChildCount ) {
+ var dragElement = dragContainer;
+ if ( dragElement.type == CKEDITOR.NODE_TEXT ) {
+ dragElement = dragContainer.getParent();
+ }
+
+ if ( dragElement.equals( dropContainer ) && preChildCount != dropContainer.getChildCount() ) {
+ applyFix( dropRange );
+ return true;
+ }
+ }
+
+ function applyFix( dropRange ) {
+ var nodeBefore = dropRange.startContainer.getChild( dropRange.startOffset - 1 ),
+ nodeAfter = dropRange.startContainer.getChild( dropRange.startOffset );
+
+ if (
+ nodeBefore && nodeBefore.type == CKEDITOR.NODE_TEXT &&
+ nodeAfter && nodeAfter.type == CKEDITOR.NODE_TEXT
+ ) {
+ var offset = nodeBefore.getLength();
+
+ nodeBefore.setText( nodeBefore.getText() + nodeAfter.getText() );
+ nodeAfter.remove();
+
+ dropRange.setStart( nodeBefore, offset );
+ dropRange.collapse( true );
+ }
+ }
+ },
+
+ /**
+ * Checks whether turning the drag range into bookmarks will invalidate the drop range.
+ * This usually happens when the drop range shares the container with the drag range and is
+ * located after the drag range, but there are countless edge cases.
+ *
+ * This function is stricly related to {@link #internalDrop} which toggles
+ * order in which it creates bookmarks for both ranges based on a value returned
+ * by this method. In some cases this method returns a value which is not necessarily
+ * true in terms of what it was meant to check, but it is convenient, because
+ * we know how it is interpreted in {@link #internalDrop}, so the correct
+ * behavior of the entire algorithm is assured.
+ *
+ * **Note:** This function is in the public scope for tests usage only.
+ *
+ * @since 4.5
+ * @private
+ * @param {CKEDITOR.dom.range} dragRange The first range to compare.
+ * @param {CKEDITOR.dom.range} dropRange The second range to compare.
+ * @returns {Boolean} `true` if the first range is before the second range.
+ */
+ isDropRangeAffectedByDragRange: function( dragRange, dropRange ) {
+ var dropContainer = dropRange.startContainer,
+ dropOffset = dropRange.endOffset;
+
+ // Both containers are the same and drop offset is at the same position or later.
+ // " A L] A " " M A "
+ // ^ ^
+ if ( dragRange.endContainer.equals( dropContainer ) && dragRange.endOffset <= dropOffset ) {
+ return true;
+ }
+
+ // Bookmark for drag start container will mess up with offsets.
+ // " O [L A " " M A "
+ // ^ ^
+ if (
+ dragRange.startContainer.getParent().equals( dropContainer ) &&
+ dragRange.startContainer.getIndex() < dropOffset
+ ) {
+ return true;
+ }
+
+ // Bookmark for drag end container will mess up with offsets.
+ // " O] L A " " M A "
+ // ^ ^
+ if (
+ dragRange.endContainer.getParent().equals( dropContainer ) &&
+ dragRange.endContainer.getIndex() < dropOffset
+ ) {
+ return true;
+ }
+
+ return false;
+ },
+
+ /**
+ * Internal drag and drop (drag and drop in the same editor instance).
+ *
+ * **Note:** This function is in the public scope for tests usage only.
+ *
+ * @since 4.5
+ * @private
+ * @param {CKEDITOR.dom.range} dragRange The first range to compare.
+ * @param {CKEDITOR.dom.range} dropRange The second range to compare.
+ * @param {CKEDITOR.plugins.clipboard.dataTransfer} dataTransfer
+ * @param {CKEDITOR.editor} editor
+ */
+ internalDrop: function( dragRange, dropRange, dataTransfer, editor ) {
+ var clipboard = CKEDITOR.plugins.clipboard,
+ editable = editor.editable(),
+ dragBookmark, dropBookmark, isDropRangeAffected;
+
+ // Save and lock snapshot so there will be only
+ // one snapshot for both remove and insert content.
+ editor.fire( 'saveSnapshot' );
+ editor.fire( 'lockSnapshot', { dontUpdate: 1 } );
+
+ if ( CKEDITOR.env.ie && CKEDITOR.env.version < 10 ) {
+ this.fixSplitNodesAfterDrop(
+ dragRange,
+ dropRange,
+ clipboard.dragStartContainerChildCount,
+ clipboard.dragEndContainerChildCount
+ );
+ }
+
+ // Because we manipulate multiple ranges we need to do it carefully,
+ // changing one range (event creating a bookmark) may make other invalid.
+ // We need to change ranges into bookmarks so we can manipulate them easily in the future.
+ // We can change the range which is later in the text before we change the preceding range.
+ // We call isDropRangeAffectedByDragRange to test the order of ranges.
+ isDropRangeAffected = this.isDropRangeAffectedByDragRange( dragRange, dropRange );
+ if ( !isDropRangeAffected ) {
+ dragBookmark = dragRange.createBookmark( false );
+ }
+ dropBookmark = dropRange.clone().createBookmark( false );
+ if ( isDropRangeAffected ) {
+ dragBookmark = dragRange.createBookmark( false );
+ }
+
+ // Check if drop range is inside range.
+ // This is an edge case when we drop something on editable's margin/padding.
+ // That space is not treated as a part of the range we drag, so it is possible to drop there.
+ // When we drop, browser tries to find closest drop position and it finds it inside drag range. (#13453)
+ var startNode = dragBookmark.startNode,
+ endNode = dragBookmark.endNode,
+ dropNode = dropBookmark.startNode,
+ dropInsideDragRange =
+ // Must check endNode because dragRange could be collapsed in some edge cases (simulated DnD).
+ endNode &&
+ ( startNode.getPosition( dropNode ) & CKEDITOR.POSITION_PRECEDING ) &&
+ ( endNode.getPosition( dropNode ) & CKEDITOR.POSITION_FOLLOWING );
+
+ // If the drop range happens to be inside drag range change it's position to the beginning of the drag range.
+ if ( dropInsideDragRange ) {
+ // We only change position of bookmark span that is connected with dropBookmark.
+ // dropRange will be overwritten and set to the dropBookmark later.
+ dropNode.insertBefore( startNode );
+ }
+
+ // No we can safely delete content for the drag range...
+ dragRange = editor.createRange();
+ dragRange.moveToBookmark( dragBookmark );
+ editable.extractHtmlFromRange( dragRange, 1 );
+
+ // ...and paste content into the drop position.
+ dropRange = editor.createRange();
+ dropRange.moveToBookmark( dropBookmark );
+
+ // We do not select drop range, because of may be in the place we can not set the selection
+ // (e.g. between blocks, in case of block widget D&D). We put range to the paste event instead.
+ firePasteEvents( editor, { dataTransfer: dataTransfer, method: 'drop', range: dropRange }, 1 );
+
+ editor.fire( 'unlockSnapshot' );
+ },
+
+ /**
+ * Gets the range from the `drop` event.
+ *
+ * @since 4.5
+ * @param {Object} domEvent A native DOM drop event object.
+ * @param {CKEDITOR.editor} editor The source editor instance.
+ * @returns {CKEDITOR.dom.range} range at drop position.
+ */
+ getRangeAtDropPosition: function( dropEvt, editor ) {
+ var $evt = dropEvt.data.$,
+ x = $evt.clientX,
+ y = $evt.clientY,
+ $range,
+ defaultRange = editor.getSelection( true ).getRanges()[ 0 ],
+ range = editor.createRange();
+
+ // Make testing possible.
+ if ( dropEvt.data.testRange )
+ return dropEvt.data.testRange;
+
+ // Webkits.
+ if ( document.caretRangeFromPoint ) {
+ $range = editor.document.$.caretRangeFromPoint( x, y );
+ range.setStart( CKEDITOR.dom.node( $range.startContainer ), $range.startOffset );
+ range.collapse( true );
+ }
+ // FF.
+ else if ( $evt.rangeParent ) {
+ range.setStart( CKEDITOR.dom.node( $evt.rangeParent ), $evt.rangeOffset );
+ range.collapse( true );
+ }
+ // IEs 9+.
+ // We check if editable is focused to make sure that it's an internal DnD. External DnD must use the second
+ // mechanism because of http://dev.ckeditor.com/ticket/13472#comment:6.
+ else if ( CKEDITOR.env.ie && CKEDITOR.env.version > 8 && defaultRange && editor.editable().hasFocus ) {
+ // On IE 9+ range by default is where we expected it.
+ // defaultRange may be undefined if dragover was canceled (file drop).
+ return defaultRange;
+ }
+ // IE 8 and all IEs if !defaultRange or external DnD.
+ else if ( document.body.createTextRange ) {
+ // To use this method we need a focus (which may be somewhere else in case of external drop).
+ editor.focus();
+
+ $range = editor.document.getBody().$.createTextRange();
+ try {
+ var sucess = false;
+
+ // If user drop between text line IEs moveToPoint throws exception:
+ //
+ // Lorem ipsum pulvinar purus et euismod
+ //
+ // dolor sit amet,| consectetur adipiscing
+ // *
+ // vestibulum tincidunt augue eget tempus.
+ //
+ // * - drop position
+ // | - expected cursor position
+ //
+ // So we try to call moveToPoint with +-1px up to +-20px above or
+ // below original drop position to find nearest good drop position.
+ for ( var i = 0; i < 20 && !sucess; i++ ) {
+ if ( !sucess ) {
+ try {
+ $range.moveToPoint( x, y - i );
+ sucess = true;
+ } catch ( err ) {
+ }
+ }
+ if ( !sucess ) {
+ try {
+ $range.moveToPoint( x, y + i );
+ sucess = true;
+ } catch ( err ) {
+ }
+ }
+ }
+
+ if ( sucess ) {
+ var id = 'cke-temp-' + ( new Date() ).getTime();
+ $range.pasteHTML( '\u200b' );
+
+ var span = editor.document.getById( id );
+ range.moveToPosition( span, CKEDITOR.POSITION_BEFORE_START );
+ span.remove();
+ } else {
+ // If the fist method does not succeed we might be next to
+ // the short element (like header):
+ //
+ // Lorem ipsum pulvinar purus et euismod.
+ //
+ //
+ // SOME HEADER| *
+ //
+ //
+ // vestibulum tincidunt augue eget tempus.
+ //
+ // * - drop position
+ // | - expected cursor position
+ //
+ // In such situation elementFromPoint returns proper element. Using getClientRect
+ // it is possible to check if the cursor should be at the beginning or at the end
+ // of paragraph.
+ var $element = editor.document.$.elementFromPoint( x, y ),
+ element = new CKEDITOR.dom.element( $element ),
+ rect;
+
+ if ( !element.equals( editor.editable() ) && element.getName() != 'html' ) {
+ rect = element.getClientRect();
+
+ if ( x < rect.left ) {
+ range.setStartAt( element, CKEDITOR.POSITION_AFTER_START );
+ range.collapse( true );
+ } else {
+ range.setStartAt( element, CKEDITOR.POSITION_BEFORE_END );
+ range.collapse( true );
+ }
+ }
+ // If drop happens on no element elementFromPoint returns html or body.
+ //
+ // * |Lorem ipsum pulvinar purus et euismod.
+ //
+ // vestibulum tincidunt augue eget tempus.
+ //
+ // * - drop position
+ // | - expected cursor position
+ //
+ // In such case we can try to use default selection. If startContainer is not
+ // 'editable' element it is probably proper selection.
+ else if ( defaultRange && defaultRange.startContainer &&
+ !defaultRange.startContainer.equals( editor.editable() ) ) {
+ return defaultRange;
+
+ // Otherwise we can not find any drop position and we have to return null
+ // and cancel drop event.
+ } else {
+ return null;
+ }
+
+ }
+ } catch ( err ) {
+ return null;
+ }
+ } else {
+ return null;
+ }
+
+ return range;
+ },
+
+ /**
+ * This function tries to link the `evt.data.dataTransfer` property of the {@link CKEDITOR.editor#dragstart},
+ * {@link CKEDITOR.editor#dragend} and {@link CKEDITOR.editor#drop} events to a single
+ * {@link CKEDITOR.plugins.clipboard.dataTransfer} object.
+ *
+ * This method is automatically used by the core of the drag and drop functionality and
+ * usually does not have to be called manually when using the drag and drop events.
+ *
+ * This method behaves differently depending on whether the drag and drop events were fired
+ * artificially (to represent a non-native drag and drop) or whether they were caused by the native drag and drop.
+ *
+ * If the native event is not available, then it will create a new {@link CKEDITOR.plugins.clipboard.dataTransfer}
+ * instance (if it does not exist already) and will link it to this and all following event objects until
+ * the {@link #resetDragDataTransfer} method is called. It means that all three drag and drop events must be fired
+ * in order to ensure that the data transfer is bound correctly.
+ *
+ * If the native event is available, then the {@link CKEDITOR.plugins.clipboard.dataTransfer} is identified
+ * by its ID and a new instance is assigned to the `evt.data.dataTransfer` only if the ID changed or
+ * the {@link #resetDragDataTransfer} method was called.
+ *
+ * @since 4.5
+ * @param {CKEDITOR.dom.event} [evt] A drop event object.
+ * @param {CKEDITOR.editor} [sourceEditor] The source editor instance.
+ */
+ initDragDataTransfer: function( evt, sourceEditor ) {
+ // Create a new dataTransfer object based on the drop event.
+ // If this event was used on dragstart to create dataTransfer
+ // both dataTransfer objects will have the same id.
+ var nativeDataTransfer = evt.data.$ ? evt.data.$.dataTransfer : null,
+ dataTransfer = new this.dataTransfer( nativeDataTransfer, sourceEditor );
+
+ if ( !nativeDataTransfer ) {
+ // No native event.
+ if ( this.dragData ) {
+ dataTransfer = this.dragData;
+ } else {
+ this.dragData = dataTransfer;
+ }
+ } else {
+ // Native event. If there is the same id we will replace dataTransfer with the one
+ // created on drag, because it contains drag editor, drag content and so on.
+ // Otherwise (in case of drag from external source) we save new object to
+ // the global clipboard.dragData.
+ if ( this.dragData && dataTransfer.id == this.dragData.id ) {
+ dataTransfer = this.dragData;
+ } else {
+ this.dragData = dataTransfer;
+ }
+ }
+
+ evt.data.dataTransfer = dataTransfer;
+ },
+
+ /**
+ * Removes the global {@link #dragData} so the next call to {@link #initDragDataTransfer}
+ * always creates a new instance of {@link CKEDITOR.plugins.clipboard.dataTransfer}.
+ *
+ * @since 4.5
+ */
+ resetDragDataTransfer: function() {
+ this.dragData = null;
+ },
+
+ /**
+ * Global object storing the data transfer of the current drag and drop operation.
+ * Do not use it directly, use {@link #initDragDataTransfer} and {@link #resetDragDataTransfer}.
+ *
+ * Note: This object is global (meaning that it is not related to a single editor instance)
+ * in order to handle drag and drop from one editor into another.
+ *
+ * @since 4.5
+ * @private
+ * @property {CKEDITOR.plugins.clipboard.dataTransfer} dragData
+ */
+
+ /**
+ * Range object to save the drag range and remove its content after the drop.
+ *
+ * @since 4.5
+ * @private
+ * @property {CKEDITOR.dom.range} dragRange
+ */
+
+ /**
+ * Initializes and links data transfer objects based on the paste event. If the data
+ * transfer object was already initialized on this event, the function will
+ * return that object. In IE it is not possible to link copy/cut and paste events
+ * so the method always returns a new object. The same happens if there is no paste event
+ * passed to the method.
+ *
+ * @since 4.5
+ * @param {CKEDITOR.dom.event} [evt] A paste event object.
+ * @param {CKEDITOR.editor} [sourceEditor] The source editor instance.
+ * @returns {CKEDITOR.plugins.clipboard.dataTransfer} The data transfer object.
+ */
+ initPasteDataTransfer: function( evt, sourceEditor ) {
+ if ( !this.isCustomCopyCutSupported ) {
+ // Edge does not support custom copy/cut, but it have some useful data in the clipboardData (#13755).
+ return new this.dataTransfer( ( CKEDITOR.env.edge && evt && evt.data.$ && evt.data.$.clipboardData ) || null, sourceEditor );
+ } else if ( evt && evt.data && evt.data.$ ) {
+ var dataTransfer = new this.dataTransfer( evt.data.$.clipboardData, sourceEditor );
+
+ if ( this.copyCutData && dataTransfer.id == this.copyCutData.id ) {
+ dataTransfer = this.copyCutData;
+ dataTransfer.$ = evt.data.$.clipboardData;
+ } else {
+ this.copyCutData = dataTransfer;
+ }
+
+ return dataTransfer;
+ } else {
+ return new this.dataTransfer( null, sourceEditor );
+ }
+ },
+
+ /**
+ * Prevents dropping on the specified element.
+ *
+ * @since 4.5
+ * @param {CKEDITOR.dom.element} element The element on which dropping should be disabled.
+ */
+ preventDefaultDropOnElement: function( element ) {
+ element && element.on( 'dragover', preventDefaultSetDropEffectToNone );
+ }
+ };
+
+ // Data type used to link drag and drop events.
+ //
+ // In IE URL data type is buggie and there is no way to mark drag & drop without
+ // modifying text data (which would be displayed if user drop content to the textarea)
+ // so we just read dragged text.
+ //
+ // In Chrome and Firefox we can use custom data types.
+ var clipboardIdDataType = CKEDITOR.plugins.clipboard.isCustomDataTypesSupported ? 'cke/id' : 'Text';
+ /**
+ * Facade for the native `dataTransfer`/`clipboadData` object to hide all differences
+ * between browsers.
+ *
+ * @since 4.5
+ * @class CKEDITOR.plugins.clipboard.dataTransfer
+ * @constructor Creates a class instance.
+ * @param {Object} [nativeDataTransfer] A native data transfer object.
+ * @param {CKEDITOR.editor} [editor] The source editor instance. If the editor is defined, dataValue will
+ * be created based on the editor content and the type will be 'html'.
+ */
+ CKEDITOR.plugins.clipboard.dataTransfer = function( nativeDataTransfer, editor ) {
+ if ( nativeDataTransfer ) {
+ this.$ = nativeDataTransfer;
+ }
+
+ this._ = {
+ metaRegExp: /^/i,
+ bodyRegExp: /([\s\S]*)<\/body>/i,
+ fragmentRegExp: //g,
+
+ data: {},
+ files: [],
+
+ normalizeType: function( type ) {
+ type = type.toLowerCase();
+
+ if ( type == 'text' || type == 'text/plain' ) {
+ return 'Text'; // IE support only Text and URL;
+ } else if ( type == 'url' ) {
+ return 'URL'; // IE support only Text and URL;
+ } else {
+ return type;
+ }
+ }
+ };
+
+ // Check if ID is already created.
+ this.id = this.getData( clipboardIdDataType );
+
+ // If there is no ID we need to create it. Different browsers needs different ID.
+ if ( !this.id ) {
+ if ( clipboardIdDataType == 'Text' ) {
+ // For IE10+ only Text data type is supported and we have to compare dragged
+ // and dropped text. If the ID is not set it means that empty string was dragged
+ // (ex. image with no alt). We change null to empty string.
+ this.id = '';
+ } else {
+ // String for custom data type.
+ this.id = 'cke-' + CKEDITOR.tools.getUniqueId();
+ }
+ }
+
+ // In IE10+ we can not use any data type besides text, so we do not call setData.
+ if ( clipboardIdDataType != 'Text' ) {
+ // Try to set ID so it will be passed from the drag to the drop event.
+ // On some browsers with some event it is not possible to setData so we
+ // need to catch exceptions.
+ try {
+ this.$.setData( clipboardIdDataType, this.id );
+ } catch ( err ) {}
+ }
+
+ if ( editor ) {
+ this.sourceEditor = editor;
+
+ this.setData( 'text/html', editor.getSelectedHtml( 1 ) );
+
+ // Without setData( 'text', ... ) on dragstart there is no drop event in Safari.
+ // Also 'text' data is empty as drop to the textarea does not work if we do not put there text.
+ if ( clipboardIdDataType != 'Text' && !this.getData( 'text/plain' ) ) {
+ this.setData( 'text/plain', editor.getSelection().getSelectedText() );
+ }
+ }
+
+ /**
+ * Data transfer ID used to bind all dataTransfer
+ * objects based on the same event (e.g. in drag and drop events).
+ *
+ * @readonly
+ * @property {String} id
+ */
+
+ /**
+ * A native DOM event object.
+ *
+ * @readonly
+ * @property {Object} $
+ */
+
+ /**
+ * Source editor — the editor where the drag starts.
+ * Might be undefined if the drag starts outside the editor (e.g. when dropping files to the editor).
+ *
+ * @readonly
+ * @property {CKEDITOR.editor} sourceEditor
+ */
+
+ /**
+ * Private properties and methods.
+ *
+ * @private
+ * @property {Object} _
+ */
+ };
+
+ /**
+ * Data transfer operation (drag and drop or copy and paste) started and ended in the same
+ * editor instance.
+ *
+ * @since 4.5
+ * @readonly
+ * @property {Number} [=1]
+ * @member CKEDITOR
+ */
+ CKEDITOR.DATA_TRANSFER_INTERNAL = 1;
+
+ /**
+ * Data transfer operation (drag and drop or copy and paste) started in one editor
+ * instance and ended in another.
+ *
+ * @since 4.5
+ * @readonly
+ * @property {Number} [=2]
+ * @member CKEDITOR
+ */
+ CKEDITOR.DATA_TRANSFER_CROSS_EDITORS = 2;
+
+ /**
+ * Data transfer operation (drag and drop or copy and paste) started outside of the editor.
+ * The source of the data may be a textarea, HTML, another application, etc.
+ *
+ * @since 4.5
+ * @readonly
+ * @property {Number} [=3]
+ * @member CKEDITOR
+ */
+ CKEDITOR.DATA_TRANSFER_EXTERNAL = 3;
+
+ CKEDITOR.plugins.clipboard.dataTransfer.prototype = {
+ /**
+ * Facade for the native `getData` method.
+ *
+ * @param {String} type The type of data to retrieve.
+ * @returns {String} type Stored data for the given type or an empty string if the data for that type does not exist.
+ */
+ getData: function( type ) {
+ function isEmpty( data ) {
+ return data === undefined || data === null || data === '';
+ }
+
+ type = this._.normalizeType( type );
+
+ var data = this._.data[ type ],
+ result;
+
+ if ( isEmpty( data ) ) {
+ try {
+ data = this.$.getData( type );
+ } catch ( e ) {}
+ }
+
+ if ( isEmpty( data ) ) {
+ data = '';
+ }
+
+ // Some browsers add at the begging of the HTML data
+ // or surround it with ...(some content) and (some content)
+ // This code removes meta tags and returns only the contents of the element if found. Note that
+ // some significant content may be placed outside Start/EndFragment comments so it's kept.
+ //
+ // See #13583 for more details.
+ if ( type == 'text/html' ) {
+ data = data.replace( this._.metaRegExp, '' );
+
+ // Keep only contents of the element
+ result = this._.bodyRegExp.exec( data );
+ if ( result && result.length ) {
+ data = result[ 1 ];
+
+ // Remove also comments.
+ data = data.replace( this._.fragmentRegExp, '' );
+ }
+ }
+ // Firefox on Linux put files paths as a text/plain data if there are files
+ // in the dataTransfer object. We need to hide it, because files should be
+ // handled on paste only if dataValue is empty.
+ else if ( type == 'Text' && CKEDITOR.env.gecko && this.getFilesCount() &&
+ data.substring( 0, 7 ) == 'file://' ) {
+ data = '';
+ }
+
+ return data;
+ },
+
+ /**
+ * Facade for the native `setData` method.
+ *
+ * @param {String} type The type of data to retrieve.
+ * @param {String} value The data to add.
+ */
+ setData: function( type, value ) {
+ type = this._.normalizeType( type );
+
+ this._.data[ type ] = value;
+
+ // There is "Unexpected call to method or property access." error if you try
+ // to set data of unsupported type on IE.
+ if ( !CKEDITOR.plugins.clipboard.isCustomDataTypesSupported && type != 'URL' && type != 'Text' ) {
+ return;
+ }
+
+ // If we use the text type to bind the ID, then if someone tries to set the text, we must also
+ // update ID accordingly. #13468.
+ if ( clipboardIdDataType == 'Text' && type == 'Text' ) {
+ this.id = value;
+ }
+
+ try {
+ this.$.setData( type, value );
+ } catch ( e ) {}
+ },
+
+ /**
+ * Gets the data transfer type.
+ *
+ * @param {CKEDITOR.editor} targetEditor The drop/paste target editor instance.
+ * @returns {Number} Possible values: {@link CKEDITOR#DATA_TRANSFER_INTERNAL},
+ * {@link CKEDITOR#DATA_TRANSFER_CROSS_EDITORS}, {@link CKEDITOR#DATA_TRANSFER_EXTERNAL}.
+ */
+ getTransferType: function( targetEditor ) {
+ if ( !this.sourceEditor ) {
+ return CKEDITOR.DATA_TRANSFER_EXTERNAL;
+ } else if ( this.sourceEditor == targetEditor ) {
+ return CKEDITOR.DATA_TRANSFER_INTERNAL;
+ } else {
+ return CKEDITOR.DATA_TRANSFER_CROSS_EDITORS;
+ }
+ },
+
+ /**
+ * Copies the data from the native data transfer to a private cache.
+ * This function is needed because the data from the native data transfer
+ * is available only synchronously to the event listener. It is not possible
+ * to get the data asynchronously, after a timeout, and the {@link CKEDITOR.editor#paste}
+ * event is fired asynchronously — hence the need for caching the data.
+ */
+ cacheData: function() {
+ if ( !this.$ ) {
+ return;
+ }
+
+ var that = this,
+ i, file;
+
+ function getAndSetData( type ) {
+ type = that._.normalizeType( type );
+
+ var data = that.getData( type );
+ if ( data ) {
+ that._.data[ type ] = data;
+ }
+ }
+
+ // Copy data.
+ if ( CKEDITOR.plugins.clipboard.isCustomDataTypesSupported ) {
+ if ( this.$.types ) {
+ for ( i = 0; i < this.$.types.length; i++ ) {
+ getAndSetData( this.$.types[ i ] );
+ }
+ }
+ } else {
+ getAndSetData( 'Text' );
+ getAndSetData( 'URL' );
+ }
+
+ // Copy files references.
+ file = this._getImageFromClipboard();
+ if ( ( this.$ && this.$.files ) || file ) {
+ this._.files = [];
+
+ // Edge have empty files property with no length (#13755).
+ if ( this.$.files && this.$.files.length ) {
+ for ( i = 0; i < this.$.files.length; i++ ) {
+ this._.files.push( this.$.files[ i ] );
+ }
+ }
+
+ // Don't include $.items if both $.files and $.items contains files, because,
+ // according to spec and browsers behavior, they contain the same files.
+ if ( this._.files.length === 0 && file ) {
+ this._.files.push( file );
+ }
+ }
+ },
+
+ /**
+ * Gets the number of files in the dataTransfer object.
+ *
+ * @returns {Number} The number of files.
+ */
+ getFilesCount: function() {
+ if ( this._.files.length ) {
+ return this._.files.length;
+ }
+
+ if ( this.$ && this.$.files && this.$.files.length ) {
+ return this.$.files.length;
+ }
+
+ return this._getImageFromClipboard() ? 1 : 0;
+ },
+
+ /**
+ * Gets the file at the index given.
+ *
+ * @param {Number} i Index.
+ * @returns {File} File instance.
+ */
+ getFile: function( i ) {
+ if ( this._.files.length ) {
+ return this._.files[ i ];
+ }
+
+ if ( this.$ && this.$.files && this.$.files.length ) {
+ return this.$.files[ i ];
+ }
+
+ // File or null if the file was not found.
+ return i === 0 ? this._getImageFromClipboard() : undefined;
+ },
+
+ /**
+ * Checks if the data transfer contains any data.
+ *
+ * @returns {Boolean} `true` if the object contains no data.
+ */
+ isEmpty: function() {
+ var typesToCheck = {},
+ type;
+
+ // If dataTransfer contains files it is not empty.
+ if ( this.getFilesCount() ) {
+ return false;
+ }
+
+ // Add custom types.
+ for ( type in this._.data ) {
+ typesToCheck[ type ] = 1;
+ }
+
+ // Add native types.
+ if ( this.$ ) {
+ if ( CKEDITOR.plugins.clipboard.isCustomDataTypesSupported ) {
+ if ( this.$.types ) {
+ for ( var i = 0; i < this.$.types.length; i++ ) {
+ typesToCheck[ this.$.types[ i ] ] = 1;
+ }
+ }
+ } else {
+ typesToCheck.Text = 1;
+ typesToCheck.URL = 1;
+ }
+ }
+
+ // Remove ID.
+ if ( clipboardIdDataType != 'Text' ) {
+ typesToCheck[ clipboardIdDataType ] = 0;
+ }
+
+ for ( type in typesToCheck ) {
+ if ( typesToCheck[ type ] && this.getData( type ) !== '' ) {
+ return false;
+ }
+ }
+
+ return true;
+ },
+
+ /**
+ * When the content of the clipboard is pasted in Chrome, the clipboard data object has an empty `files` property,
+ * but it is possible to get the file as `items[0].getAsFile();` (#12961).
+ *
+ * @private
+ * @returns {File} File instance or `null` if not found.
+ */
+ _getImageFromClipboard: function() {
+ var file;
+
+ if ( this.$ && this.$.items && this.$.items[ 0 ] ) {
+ try {
+ file = this.$.items[ 0 ].getAsFile();
+ // Duck typing
+ if ( file && file.type ) {
+ return file;
+ }
+ } catch ( err ) {
+ // noop
+ }
+ }
+
+ return undefined;
+ }
+ };
+} )();
+
+/**
+ * The default content type that is used when pasted data cannot be clearly recognized as HTML or text.
+ *
+ * For example: `'foo'` may come from a plain text editor or a website. It is not possible to recognize the content
+ * type in this case, so the default type will be used. At the same time it is clear that `'example text'` is
+ * HTML and its origin is a web page, email or another rich text editor.
+ *
+ * **Note:** If content type is text, then styles of the paste context are preserved.
+ *
+ * CKEDITOR.config.clipboard_defaultContentType = 'text';
+ *
+ * See also the {@link CKEDITOR.editor#paste} event and read more about the integration with clipboard
+ * in the [Clipboard Deep Dive guide](#!/guide/dev_clipboard).
+ *
+ * @since 4.0
+ * @cfg {'html'/'text'} [clipboard_defaultContentType='html']
+ * @member CKEDITOR.config
+ */
+
+/**
+ * Fired after the user initiated a paste action, but before the data is inserted into the editor.
+ * The listeners to this event are able to process the content before its insertion into the document.
+ *
+ * Read more about the integration with clipboard in the [Clipboard Deep Dive guide](#!/guide/dev_clipboard).
+ *
+ * See also:
+ *
+ * * the {@link CKEDITOR.config#pasteFilter} option,
+ * * the {@link CKEDITOR.editor#drop} event,
+ * * the {@link CKEDITOR.plugins.clipboard.dataTransfer} class.
+ *
+ * @since 3.1
+ * @event paste
+ * @member CKEDITOR.editor
+ * @param {CKEDITOR.editor} editor This editor instance.
+ * @param data
+ * @param {String} data.type The type of data in `data.dataValue`. Usually `'html'` or `'text'`, but for listeners
+ * with a priority smaller than `6` it may also be `'auto'` which means that the content type has not been recognised yet
+ * (this will be done by the content type sniffer that listens with priority `6`).
+ * @param {String} data.dataValue HTML to be pasted.
+ * @param {String} data.method Indicates the data transfer method. It could be drag and drop or copy and paste.
+ * Possible values: `'drop'`, `'paste'`. Introduced in CKEditor 4.5.
+ * @param {CKEDITOR.plugins.clipboard.dataTransfer} data.dataTransfer Facade for the native dataTransfer object
+ * which provides access to various data types and files, and passes some data between linked events
+ * (like drag and drop). Introduced in CKEditor 4.5.
+ * @param {Boolean} [data.dontFilter=false] Whether the {@link CKEDITOR.editor#pasteFilter paste filter} should not
+ * be applied to data. This option has no effect when `data.type` equals `'text'` which means that for instance
+ * {@link CKEDITOR.config#forcePasteAsPlainText} has a higher priority. Introduced in CKEditor 4.5.
+ */
+
+/**
+ * Fired before the {@link #paste} event. Allows to preset data type.
+ *
+ * **Note:** This event is deprecated. Add a `0` priority listener for the
+ * {@link #paste} event instead.
+ *
+ * @deprecated
+ * @event beforePaste
+ * @member CKEDITOR.editor
+ */
+
+ /**
+ * Fired after the {@link #paste} event if content was modified. Note that if the paste
+ * event does not insert any data, the `afterPaste` event will not be fired.
+ *
+ * @event afterPaste
+ * @member CKEDITOR.editor
+ */
+
+/**
+ * Internal event to open the Paste dialog window.
+ *
+ * @private
+ * @event pasteDialog
+ * @member CKEDITOR.editor
+ * @param {CKEDITOR.editor} editor This editor instance.
+ * @param {Function} [data] Callback that will be passed to {@link CKEDITOR.editor#openDialog}.
+ */
+
+/**
+ * Facade for the native `drop` event. Fired when the native `drop` event occurs.
+ *
+ * **Note:** To manipulate dropped data, use the {@link CKEDITOR.editor#paste} event.
+ * Use the `drop` event only to control drag and drop operations (e.g. to prevent the ability to drop some content).
+ *
+ * Read more about integration with drag and drop in the [Clipboard Deep Dive guide](#!/guide/dev_clipboard).
+ *
+ * See also:
+ *
+ * * The {@link CKEDITOR.editor#paste} event,
+ * * The {@link CKEDITOR.editor#dragstart} and {@link CKEDITOR.editor#dragend} events,
+ * * The {@link CKEDITOR.plugins.clipboard.dataTransfer} class.
+ *
+ * @since 4.5
+ * @event drop
+ * @member CKEDITOR.editor
+ * @param {CKEDITOR.editor} editor This editor instance.
+ * @param data
+ * @param {Object} data.$ Native drop event.
+ * @param {CKEDITOR.dom.node} data.target Drop target.
+ * @param {CKEDITOR.plugins.clipboard.dataTransfer} data.dataTransfer DataTransfer facade.
+ * @param {CKEDITOR.dom.range} data.dragRange Drag range, lets you manipulate the drag range.
+ * Note that dragged HTML is saved as `text/html` data on `dragstart` so if you change the drag range
+ * on drop, dropped HTML will not change. You need to change it manually using
+ * {@link CKEDITOR.plugins.clipboard.dataTransfer#setData dataTransfer.setData}.
+ * @param {CKEDITOR.dom.range} data.dropRange Drop range, lets you manipulate the drop range.
+ */
+
+/**
+ * Facade for the native `dragstart` event. Fired when the native `dragstart` event occurs.
+ *
+ * This event can be canceled in order to block the drag start operation. It can also be fired to mimic the start of the drag and drop
+ * operation. For instance, the `widget` plugin uses this option to integrate its custom block widget drag and drop with
+ * the entire system.
+ *
+ * Read more about integration with drag and drop in the [Clipboard Deep Dive guide](#!/guide/dev_clipboard).
+ *
+ * See also:
+ *
+ * * The {@link CKEDITOR.editor#paste} event,
+ * * The {@link CKEDITOR.editor#drop} and {@link CKEDITOR.editor#dragend} events,
+ * * The {@link CKEDITOR.plugins.clipboard.dataTransfer} class.
+ *
+ * @since 4.5
+ * @event dragstart
+ * @member CKEDITOR.editor
+ * @param {CKEDITOR.editor} editor This editor instance.
+ * @param data
+ * @param {Object} data.$ Native dragstart event.
+ * @param {CKEDITOR.dom.node} data.target Drag target.
+ * @param {CKEDITOR.plugins.clipboard.dataTransfer} data.dataTransfer DataTransfer facade.
+ */
+
+/**
+ * Facade for the native `dragend` event. Fired when the native `dragend` event occurs.
+ *
+ * Read more about integration with drag and drop in the [Clipboard Deep Dive guide](#!/guide/dev_clipboard).
+ *
+ * See also:
+ *
+ * * The {@link CKEDITOR.editor#paste} event,
+ * * The {@link CKEDITOR.editor#drop} and {@link CKEDITOR.editor#dragend} events,
+ * * The {@link CKEDITOR.plugins.clipboard.dataTransfer} class.
+ *
+ * @since 4.5
+ * @event dragend
+ * @member CKEDITOR.editor
+ * @param {CKEDITOR.editor} editor This editor instance.
+ * @param data
+ * @param {Object} data.$ Native dragend event.
+ * @param {CKEDITOR.dom.node} data.target Drag target.
+ * @param {CKEDITOR.plugins.clipboard.dataTransfer} data.dataTransfer DataTransfer facade.
+ */
+
+/**
+ * Defines a filter which is applied to external data pasted or dropped into the editor. Possible values are:
+ *
+ * * `'plain-text'` – Content will be pasted as a plain text.
+ * * `'semantic-content'` – Known tags (except `div`, `span`) with all attributes (except
+ * `style` and `class`) will be kept.
+ * * `'h1 h2 p div'` – Custom rules compatible with {@link CKEDITOR.filter}.
+ * * `null` – Content will not be filtered by the paste filter (but it still may be filtered
+ * by [Advanced Content Filter](#!/guide/dev_advanced_content_filter)). This value can be used to
+ * disable the paste filter in Chrome and Safari, where this option defaults to `'semantic-content'`.
+ *
+ * Example:
+ *
+ * config.pasteFilter = 'plain-text';
+ *
+ * Custom setting:
+ *
+ * config.pasteFilter = 'h1 h2 p ul ol li; img[!src, alt]; a[!href]';
+ *
+ * Based on this configuration option, a proper {@link CKEDITOR.filter} instance will be defined and assigned to the editor
+ * as a {@link CKEDITOR.editor#pasteFilter}. You can tweak the paste filter settings on the fly on this object
+ * as well as delete or replace it.
+ *
+ * var editor = CKEDITOR.replace( 'editor', {
+ * pasteFilter: 'semantic-content'
+ * } );
+ *
+ * editor.on( 'instanceReady', function() {
+ * // The result of this will be that all semantic content will be preserved
+ * // except tables.
+ * editor.pasteFilter.disallow( 'table' );
+ * } );
+ *
+ * Note that the paste filter is applied only to **external** data. There are three data sources:
+ *
+ * * copied and pasted in the same editor (internal),
+ * * copied from one editor and pasted into another (cross-editor),
+ * * coming from all other sources like websites, MS Word, etc. (external).
+ *
+ * If {@link CKEDITOR.config#allowedContent Advanced Content Filter} is not disabled, then
+ * it will also be applied to pasted and dropped data. The paste filter job is to "normalize"
+ * external data which often needs to be handled differently than content produced by the editor.
+ *
+ * This setting defaults to `'semantic-content'` in Chrome, Opera and Safari (all Blink and Webkit based browsers)
+ * due to messy HTML which these browsers keep in the clipboard. In other browsers it defaults to `null`.
+ *
+ * @since 4.5
+ * @cfg {String} [pasteFilter='semantic-content' in Chrome and Safari and `null` in other browsers]
+ * @member CKEDITOR.config
+ */
+
+/**
+ * {@link CKEDITOR.filter Content filter} which is used when external data is pasted or dropped into the editor
+ * or a forced paste as plain text occurs.
+ *
+ * This object might be used on the fly to define rules for pasted external content.
+ * This object is available and used if the {@link CKEDITOR.plugins.clipboard clipboard} plugin is enabled and
+ * {@link CKEDITOR.config#pasteFilter} or {@link CKEDITOR.config#forcePasteAsPlainText} was defined.
+ *
+ * To enable the filter:
+ *
+ * var editor = CKEDITOR.replace( 'editor', {
+ * pasteFilter: 'plain-text'
+ * } );
+ *
+ * You can also modify the filter on the fly later on:
+ *
+ * editor.pasteFilter = new CKEDITOR.filter( 'p h1 h2; a[!href]' );
+ *
+ * Note that the paste filter is only applied to **external** data. There are three data sources:
+ *
+ * * copied and pasted in the same editor (internal),
+ * * copied from one editor and pasted into another (cross-editor),
+ * * coming from all other sources like websites, MS Word, etc. (external).
+ *
+ * If {@link CKEDITOR.config#allowedContent Advanced Content Filter} is not disabled, then
+ * it will also be applied to pasted and dropped data. The paste filter job is to "normalize"
+ * external data which often needs to be handled differently than content produced by the editor.
+ *
+ * @since 4.5
+ * @readonly
+ * @property {CKEDITOR.filter} [pasteFilter]
+ * @member CKEDITOR.editor
+ */
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/dialogs/codesnippet.js b/assets/ckeditor-contrib/plugins/codesnippet/dialogs/codesnippet.js
new file mode 100644
index 00000000..d0e35b3f
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/dialogs/codesnippet.js
@@ -0,0 +1,83 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+'use strict';
+
+( function() {
+ CKEDITOR.dialog.add( 'codeSnippet', function( editor ) {
+ var snippetLangs = editor._.codesnippet.langs,
+ lang = editor.lang.codesnippet,
+ clientHeight = document.documentElement.clientHeight,
+ langSelectItems = [],
+ snippetLangId;
+
+ langSelectItems.push( [ editor.lang.common.notSet, '' ] );
+
+ for ( snippetLangId in snippetLangs )
+ langSelectItems.push( [ snippetLangs[ snippetLangId ], snippetLangId ] );
+
+ // Size adjustments.
+ var size = CKEDITOR.document.getWindow().getViewPaneSize(),
+ // Make it maximum 800px wide, but still fully visible in the viewport.
+ width = Math.min( size.width - 70, 800 ),
+ // Make it use 2/3 of the viewport height.
+ height = size.height / 1.5;
+
+ // Low resolution settings.
+ if ( clientHeight < 650 ) {
+ height = clientHeight - 220;
+ }
+
+ return {
+ title: lang.title,
+ minHeight: 200,
+ resizable: CKEDITOR.DIALOG_RESIZE_NONE,
+ contents: [
+ {
+ id: 'info',
+ elements: [
+ {
+ id: 'lang',
+ type: 'select',
+ label: lang.language,
+ items: langSelectItems,
+ setup: function( widget ) {
+ if ( widget.ready && widget.data.lang )
+ this.setValue( widget.data.lang );
+
+ // The only way to have an empty select value in Firefox is
+ // to set a negative selectedIndex.
+ if ( CKEDITOR.env.gecko && ( !widget.data.lang || !widget.ready ) )
+ this.getInputElement().$.selectedIndex = -1;
+ },
+ commit: function( widget ) {
+ widget.setData( 'lang', this.getValue() );
+ }
+ },
+ {
+ id: 'code',
+ type: 'textarea',
+ label: lang.codeContents,
+ setup: function( widget ) {
+ this.setValue( widget.data.code );
+ },
+ commit: function( widget ) {
+ widget.setData( 'code', this.getValue() );
+ },
+ required: true,
+ validate: CKEDITOR.dialog.validate.notEmpty( lang.emptySnippetError ),
+ inputStyle: 'cursor:auto;' +
+ 'width:' + width + 'px;' +
+ 'height:' + height + 'px;' +
+ 'tab-size:4;' +
+ 'text-align:left;',
+ 'class': 'cke_source'
+ }
+ ]
+ }
+ ]
+ };
+ } );
+}() );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/icons/codesnippet.png b/assets/ckeditor-contrib/plugins/codesnippet/icons/codesnippet.png
new file mode 100644
index 00000000..187d1880
Binary files /dev/null and b/assets/ckeditor-contrib/plugins/codesnippet/icons/codesnippet.png differ
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/icons/hidpi/codesnippet.png b/assets/ckeditor-contrib/plugins/codesnippet/icons/hidpi/codesnippet.png
new file mode 100644
index 00000000..7f0c8810
Binary files /dev/null and b/assets/ckeditor-contrib/plugins/codesnippet/icons/hidpi/codesnippet.png differ
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/ar.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/ar.js
new file mode 100644
index 00000000..c850e04d
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/ar.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'ar', {
+ button: 'أدمج قصاصة الشيفرة',
+ codeContents: 'محتوى الشيفرة',
+ emptySnippetError: 'قصاصة الشيفرة لايمكن أن تكون فارغة.',
+ language: 'لغة',
+ title: 'قصاصة الشيفرة',
+ pathName: 'قصاصة الشيفرة'
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/bg.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/bg.js
new file mode 100644
index 00000000..d51ca5e6
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/bg.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'bg', {
+ button: 'Въвеждане на блок с код',
+ codeContents: 'Съдържание на кода',
+ emptySnippetError: 'Блока с код не може да бъде празен.',
+ language: 'Език',
+ title: 'Блок с код',
+ pathName: 'блок с код'
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/ca.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/ca.js
new file mode 100644
index 00000000..c6385005
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/ca.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'ca', {
+ button: 'Insereix el fragment de codi',
+ codeContents: 'Contingut del codi',
+ emptySnippetError: 'El fragment de codi no pot estar buit.',
+ language: 'Idioma',
+ title: 'Fragment de codi',
+ pathName: 'fragment de codi'
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/cs.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/cs.js
new file mode 100644
index 00000000..13b5811e
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/cs.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'cs', {
+ button: 'Vložit úryvek kódu',
+ codeContents: 'Obsah kódu',
+ emptySnippetError: 'Úryvek kódu nemůže být prázdný.',
+ language: 'Jazyk',
+ title: 'Úryvek kódu',
+ pathName: 'úryvek kódu'
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/da.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/da.js
new file mode 100644
index 00000000..2b0758bb
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/da.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'da', {
+ button: 'Indsæt kodestykket her',
+ codeContents: 'Koden',
+ emptySnippetError: 'Kodestykket kan ikke være tomt.',
+ language: 'Sprog',
+ title: 'Kodestykke',
+ pathName: 'kodestykke'
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/de-ch.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/de-ch.js
new file mode 100644
index 00000000..2c5abbb0
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/de-ch.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'de-ch', {
+ button: 'Codeschnipsel einfügen',
+ codeContents: 'Codeinhalt',
+ emptySnippetError: 'Ein Codeschnipsel darf nicht leer sein.',
+ language: 'Sprache',
+ title: 'Codeschnipsel',
+ pathName: 'Codeschnipsel'
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/de.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/de.js
new file mode 100644
index 00000000..355d0054
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/de.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'de', {
+ button: 'Codeschnipsel einfügen',
+ codeContents: 'Codeinhalt',
+ emptySnippetError: 'Ein Codeschnipsel darf nicht leer sein.',
+ language: 'Sprache',
+ title: 'Codeschnipsel',
+ pathName: 'Codeschnipsel'
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/el.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/el.js
new file mode 100644
index 00000000..75926ea4
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/el.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'el', {
+ button: 'Εισαγωγή Αποσπάσματος Κώδικα',
+ codeContents: 'Περιεχόμενο κώδικα',
+ emptySnippetError: 'Δεν γίνεται να είναι κενά τα αποσπάσματα κώδικα.',
+ language: 'Γλώσσα',
+ title: 'Απόσπασμα κώδικα',
+ pathName: 'απόσπασμα κώδικα'
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/en-gb.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/en-gb.js
new file mode 100644
index 00000000..7a26bb88
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/en-gb.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'en-gb', {
+ button: 'Insert Code Snippet',
+ codeContents: 'Code content',
+ emptySnippetError: 'A code snippet cannot be empty.',
+ language: 'Language',
+ title: 'Code snippet',
+ pathName: 'code snippet'
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/en.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/en.js
new file mode 100644
index 00000000..99bc508e
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/en.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'en', {
+ button: 'Insert Code Snippet',
+ codeContents: 'Code content',
+ emptySnippetError: 'A code snippet cannot be empty.',
+ language: 'Language',
+ title: 'Code snippet',
+ pathName: 'code snippet'
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/eo.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/eo.js
new file mode 100644
index 00000000..6e7d279f
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/eo.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'eo', {
+ button: 'Enmeti kodaĵeron',
+ codeContents: 'Kodenhavo',
+ emptySnippetError: 'Kodaĵero ne povas esti malplena.',
+ language: 'Lingvo',
+ title: 'Kodaĵero',
+ pathName: 'kodaĵero'
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/es.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/es.js
new file mode 100644
index 00000000..dedf1868
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/es.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'es', {
+ button: 'Insertar fragmento de código',
+ codeContents: 'Contenido del código',
+ emptySnippetError: 'Un fragmento de código no puede estar vacío.',
+ language: 'Lenguaje',
+ title: 'Fragmento de código',
+ pathName: 'fragmento de código'
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/et.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/et.js
new file mode 100644
index 00000000..2e61cfcf
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/et.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'et', {
+ button: 'Koodilõigu sisestamine',
+ codeContents: 'Code content', // MISSING
+ emptySnippetError: 'A code snippet cannot be empty.', // MISSING
+ language: 'Language', // MISSING
+ title: 'Code snippet', // MISSING
+ pathName: 'code snippet' // MISSING
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/eu.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/eu.js
new file mode 100644
index 00000000..daecd03a
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/eu.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'eu', {
+ button: 'Txertatu kode zatia',
+ codeContents: 'Kode edukia',
+ emptySnippetError: 'Kode zatiak ezin du hutsik egon.',
+ language: 'Lengoaia',
+ title: 'Kode zatia',
+ pathName: 'kode zatia'
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/fa.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/fa.js
new file mode 100644
index 00000000..44cfc4e7
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/fa.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'fa', {
+ button: 'قرار دادن کد قطعه',
+ codeContents: 'محتوای کد',
+ emptySnippetError: 'کد نمی تواند خالی باشد.',
+ language: 'زبان',
+ title: 'کد قطعه',
+ pathName: 'کد قطعه'
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/fi.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/fi.js
new file mode 100644
index 00000000..e25fd298
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/fi.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'fi', {
+ button: 'Lisää koodileike',
+ codeContents: 'Koodisisältö',
+ emptySnippetError: 'Koodileike ei voi olla tyhjä.',
+ language: 'Kieli',
+ title: 'Koodileike',
+ pathName: 'koodileike'
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/fr-ca.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/fr-ca.js
new file mode 100644
index 00000000..8d57dadc
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/fr-ca.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'fr-ca', {
+ button: 'Insérer du code',
+ codeContents: 'Code content', // MISSING
+ emptySnippetError: 'A code snippet cannot be empty.', // MISSING
+ language: 'Language', // MISSING
+ title: 'Code snippet', // MISSING
+ pathName: 'code snippet' // MISSING
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/fr.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/fr.js
new file mode 100644
index 00000000..c8fb6093
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/fr.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'fr', {
+ button: 'Insérer un extrait de code',
+ codeContents: 'Code',
+ emptySnippetError: 'Un extrait de code ne peut pas être vide.',
+ language: 'Langue',
+ title: 'Extrait de code',
+ pathName: 'extrait de code'
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/gl.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/gl.js
new file mode 100644
index 00000000..e96109bc
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/gl.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'gl', {
+ button: 'Inserir fragmento de código',
+ codeContents: 'Contido do código',
+ emptySnippetError: 'Un fragmento de código non pode estar baleiro.',
+ language: 'Linguaxe',
+ title: 'Fragmento de código',
+ pathName: 'fragmento de código'
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/he.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/he.js
new file mode 100644
index 00000000..2bd76619
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/he.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'he', {
+ button: 'הכנס קטע קוד',
+ codeContents: 'תוכן קוד',
+ emptySnippetError: 'קטע קוד לא יכול להיות ריק.',
+ language: 'שפה',
+ title: 'קטע קוד',
+ pathName: 'code snippet' // MISSING
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/hr.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/hr.js
new file mode 100644
index 00000000..d185621e
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/hr.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'hr', {
+ button: 'Ubaci isječak kôda',
+ codeContents: 'Code content', // MISSING
+ emptySnippetError: 'A code snippet cannot be empty.', // MISSING
+ language: 'Language', // MISSING
+ title: 'Code snippet', // MISSING
+ pathName: 'code snippet' // MISSING
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/hu.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/hu.js
new file mode 100644
index 00000000..7af667e4
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/hu.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'hu', {
+ button: 'Illeszd be a kódtöredéket',
+ codeContents: 'Kód tartalom',
+ emptySnippetError: 'A kódtöredék nem lehet üres.',
+ language: 'Nyelv',
+ title: 'Kódtöredék',
+ pathName: 'kódtöredék'
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/id.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/id.js
new file mode 100644
index 00000000..28bc831c
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/id.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'id', {
+ button: 'Masukkan potongan kode',
+ codeContents: 'Konten kode',
+ emptySnippetError: 'Potongan kode tidak boleh kosong',
+ language: 'Bahasa',
+ title: 'Potongan kode',
+ pathName: 'potongan kode'
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/it.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/it.js
new file mode 100644
index 00000000..7c28d2cb
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/it.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'it', {
+ button: 'Inserisci frammento di codice',
+ codeContents: 'Contenuto del codice',
+ emptySnippetError: 'Un frammento di codice non può essere vuoto.',
+ language: 'Lingua',
+ title: 'Frammento di codice',
+ pathName: 'frammento di codice'
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/ja.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/ja.js
new file mode 100644
index 00000000..fef23a2c
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/ja.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'ja', {
+ button: 'コードスニペットを挿入',
+ codeContents: 'コード内容',
+ emptySnippetError: 'コードスニペットを入力してください。',
+ language: '言語',
+ title: 'コードスニペット',
+ pathName: 'コードスニペット'
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/km.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/km.js
new file mode 100644
index 00000000..4b048295
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/km.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'km', {
+ button: 'Insert Code Snippet', // MISSING
+ codeContents: 'មាតិកាកូដ',
+ emptySnippetError: 'A code snippet cannot be empty.', // MISSING
+ language: 'ភាសា',
+ title: 'Code snippet', // MISSING
+ pathName: 'code snippet' // MISSING
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/ko.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/ko.js
new file mode 100644
index 00000000..84db4c0b
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/ko.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'ko', {
+ button: '코드 스니펫 삽입',
+ codeContents: '코드 본문',
+ emptySnippetError: '코드 스니펫은 빈칸일 수 없습니다.',
+ language: '언어',
+ title: '코드 스니펫',
+ pathName: '코드 스니펫'
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/ku.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/ku.js
new file mode 100644
index 00000000..3f6cfaa0
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/ku.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'ku', {
+ button: 'تێخستنی تیتکی کۆد',
+ codeContents: 'ناوەڕۆکی کۆد',
+ emptySnippetError: 'تیتکی کۆد نابێت بەتاڵ بێت.',
+ language: 'زمان',
+ title: 'تیتکی کۆد',
+ pathName: 'تیتکی کۆد'
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/lt.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/lt.js
new file mode 100644
index 00000000..62f80d08
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/lt.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'lt', {
+ button: 'Įterpkite kodo gabaliuką',
+ codeContents: 'Kodo turinys',
+ emptySnippetError: 'Kodo fragmentas negali būti tusčias.',
+ language: 'Kalba',
+ title: 'Kodo fragmentas',
+ pathName: 'kodo fragmentas'
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/lv.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/lv.js
new file mode 100644
index 00000000..67a898e7
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/lv.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'lv', {
+ button: 'Ievietot koda fragmentu',
+ codeContents: 'Code content', // MISSING
+ emptySnippetError: 'A code snippet cannot be empty.', // MISSING
+ language: 'Language', // MISSING
+ title: 'Code snippet', // MISSING
+ pathName: 'code snippet' // MISSING
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/nb.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/nb.js
new file mode 100644
index 00000000..55d9da5d
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/nb.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'nb', {
+ button: 'Sett inn kodesnutt',
+ codeContents: 'Kodeinnhold',
+ emptySnippetError: 'En kodesnutt kan ikke være tom.',
+ language: 'Språk',
+ title: 'Kodesnutt',
+ pathName: 'kodesnutt'
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/nl.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/nl.js
new file mode 100644
index 00000000..3535c588
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/nl.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'nl', {
+ button: 'Stuk code invoegen',
+ codeContents: 'Code',
+ emptySnippetError: 'Een stuk code kan niet leeg zijn.',
+ language: 'Taal',
+ title: 'Stuk code',
+ pathName: 'stuk code'
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/no.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/no.js
new file mode 100644
index 00000000..c2fa354d
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/no.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'no', {
+ button: 'Sett inn kodesnutt',
+ codeContents: 'Code content', // MISSING
+ emptySnippetError: 'A code snippet cannot be empty.', // MISSING
+ language: 'Language', // MISSING
+ title: 'Code snippet', // MISSING
+ pathName: 'code snippet' // MISSING
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/pl.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/pl.js
new file mode 100644
index 00000000..f548ac2b
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/pl.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'pl', {
+ button: 'Wstaw fragment kodu',
+ codeContents: 'Treść kodu',
+ emptySnippetError: 'Kod nie może być pusty.',
+ language: 'Język',
+ title: 'Fragment kodu',
+ pathName: 'fragment kodu'
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/pt-br.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/pt-br.js
new file mode 100644
index 00000000..7ca2ec30
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/pt-br.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'pt-br', {
+ button: 'Inserir fragmento de código',
+ codeContents: 'Conteúdo do código',
+ emptySnippetError: 'Um fragmento de código não pode ser vazio',
+ language: 'Idioma',
+ title: 'Fragmento de código',
+ pathName: 'fragmento de código'
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/pt.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/pt.js
new file mode 100644
index 00000000..8456838b
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/pt.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'pt', {
+ button: 'Inserir fragmento de código',
+ codeContents: 'Code content', // MISSING
+ emptySnippetError: 'A code snippet cannot be empty.', // MISSING
+ language: 'Idioma',
+ title: 'Segmento de código',
+ pathName: 'Fragmento de código'
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/ro.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/ro.js
new file mode 100644
index 00000000..e9252f9e
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/ro.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'ro', {
+ button: 'Adaugă segment de cod',
+ codeContents: 'Conținutul codului',
+ emptySnippetError: 'Un segment de cod nu poate fi gol.',
+ language: 'Limba',
+ title: 'Segment de cod',
+ pathName: 'segment de cod'
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/ru.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/ru.js
new file mode 100644
index 00000000..d6e34965
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/ru.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'ru', {
+ button: 'Вставить сниппет',
+ codeContents: 'Содержимое кода',
+ emptySnippetError: 'Сниппет не может быть пустым',
+ language: 'Язык',
+ title: 'Сниппет',
+ pathName: 'сниппет'
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/sk.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/sk.js
new file mode 100644
index 00000000..4eb8b887
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/sk.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'sk', {
+ button: 'Vložte ukážku programového kódu',
+ codeContents: 'Obsah kódu',
+ emptySnippetError: 'Ukážka kódu nesmie byť prázdna.',
+ language: 'Jazyk',
+ title: 'Ukážka programového kódu',
+ pathName: 'ukážka programového kódu'
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/sl.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/sl.js
new file mode 100644
index 00000000..3ad5457f
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/sl.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'sl', {
+ button: 'Vstavi odsek kode',
+ codeContents: 'Vsebina kode',
+ emptySnippetError: 'Odsek kode ne more biti prazen.',
+ language: 'Jezik',
+ title: 'Odsek kode',
+ pathName: 'odsek kode'
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/sq.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/sq.js
new file mode 100644
index 00000000..e89c0135
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/sq.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'sq', {
+ button: 'Shto kod copëze',
+ codeContents: 'Përmbajtja e kodit',
+ emptySnippetError: 'A code snippet cannot be empty.', // MISSING
+ language: 'Gjuha',
+ title: 'Code snippet', // MISSING
+ pathName: 'code snippet' // MISSING
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/sv.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/sv.js
new file mode 100644
index 00000000..b9e46a65
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/sv.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'sv', {
+ button: 'Infoga kodsnutt',
+ codeContents: 'Kodinnehålll',
+ emptySnippetError: 'Innehåll krävs för kodsnutt',
+ language: 'Språk',
+ title: 'Kodsnutt',
+ pathName: 'kodsnutt'
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/th.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/th.js
new file mode 100644
index 00000000..61e68723
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/th.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'th', {
+ button: 'แทรกชิ้นส่วนของรหัสหรือโค้ด',
+ codeContents: 'Code content', // MISSING
+ emptySnippetError: 'A code snippet cannot be empty.', // MISSING
+ language: 'Language', // MISSING
+ title: 'Code snippet', // MISSING
+ pathName: 'code snippet' // MISSING
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/tr.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/tr.js
new file mode 100644
index 00000000..b466a1f6
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/tr.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'tr', {
+ button: 'Kod parçacığı ekle',
+ codeContents: 'Kod',
+ emptySnippetError: 'Kod parçacığı boş bırakılamaz',
+ language: 'Dil',
+ title: 'Kod parçacığı',
+ pathName: 'kod parçacığı'
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/tt.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/tt.js
new file mode 100644
index 00000000..59e6115b
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/tt.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'tt', {
+ button: 'Код өзеген өстәү',
+ codeContents: 'Код эчтәлеге',
+ emptySnippetError: 'Код өзеге буш булмаска тиеш.',
+ language: 'Тел',
+ title: 'Код өзеге',
+ pathName: 'код өзеге'
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/ug.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/ug.js
new file mode 100644
index 00000000..20ba17c3
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/ug.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'ug', {
+ button: 'كود پارچىسى قىستۇرۇش',
+ codeContents: 'كود مەزمۇنى',
+ emptySnippetError: 'كود پارچىسى بوش قالمايدۇ',
+ language: 'تىل',
+ title: 'كود پارچىسى',
+ pathName: 'كود پارچىسى'
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/uk.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/uk.js
new file mode 100644
index 00000000..b0ed6e43
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/uk.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'uk', {
+ button: 'Вставити фрагмент коду',
+ codeContents: 'Код',
+ emptySnippetError: 'Фрагмент коду не можи бути порожнім.',
+ language: 'Мова',
+ title: 'Фрагмент коду',
+ pathName: 'фрагмент коду'
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/vi.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/vi.js
new file mode 100644
index 00000000..7f6b5ff6
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/vi.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'vi', {
+ button: 'Chèn đoạn mã',
+ codeContents: 'Nội dung mã',
+ emptySnippetError: 'Một đoạn mã không thể để trống.',
+ language: 'Ngôn ngữ',
+ title: 'Đoạn mã',
+ pathName: 'mã dính'
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/zh-cn.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/zh-cn.js
new file mode 100644
index 00000000..3fe3ee91
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/zh-cn.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'zh-cn', {
+ button: '插入代码段',
+ codeContents: '代码内容',
+ emptySnippetError: '插入的代码不能为空。',
+ language: '代码语言',
+ title: '代码段',
+ pathName: '代码段'
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lang/zh.js b/assets/ckeditor-contrib/plugins/codesnippet/lang/zh.js
new file mode 100644
index 00000000..5983790f
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lang/zh.js
@@ -0,0 +1,13 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.setLang( 'codesnippet', 'zh', {
+ button: '插入程式碼片段',
+ codeContents: '程式碼內容',
+ emptySnippetError: '程式碼片段不可為空白。',
+ language: '語言',
+ title: '程式碼片段',
+ pathName: '程式碼片段'
+} );
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lib/highlight/CHANGES.md b/assets/ckeditor-contrib/plugins/codesnippet/lib/highlight/CHANGES.md
new file mode 100644
index 00000000..f878062b
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lib/highlight/CHANGES.md
@@ -0,0 +1,827 @@
+## Version 8.0 beta
+
+This new major release is quite a big overhaul bringing both new features and
+some backwards incompatible changes. However, chances are that the majority of
+users won't be affected by the latter: the basic scenario described in the
+README is left intact.
+
+Here's what did change in an incompatible way:
+
+- We're now prefixing all classes located in [CSS classes reference][cr] with
+ `hljs-`, by default, because some class names would collide with other
+ people's stylesheets. If you were using an older version, you might still want
+ the previous behavior, but still want to upgrade. To suppress this new
+ behavior, you would initialize like so:
+
+ ```html
+
+ ```
+
+- `tabReplace` and `useBR` that were used in different places are also unified
+ into the global options object and are to be set using `configure(options)`.
+ This function is documented in our [API docs][]. Also note that these
+ parameters are gone from `highlightBlock` and `fixMarkup` which are now also
+ rely on `configure`.
+
+- We removed public-facing (though undocumented) object `hljs.LANGUAGES` which
+ was used to register languages with the library in favor of two new methods:
+ `registerLanguage` and `getLanguage`. Both are documented in our [API docs][].
+
+- Result returned from `highlight` and `highlightAuto` no longer contains two
+ separate attributes contributing to relevance score, `relevance` and
+ `keyword_count`. They are now unified in `relevance`.
+
+Another technically compatible change that nonetheless might need attention:
+
+- The structure of the NPM package was refactored, so if you had installed it
+ locally, you'll have to update your paths. The usual `require('highlight.js')`
+ works as before. This is contributed by [Dmitry Smolin][].
+
+New features:
+
+- Languages now can be recognized by multiple names like "js" for JavaScript or
+ "html" for, well, HTML (which earlier insisted on calling it "xml"). These
+ aliases can be specified in the class attribute of the code container in your
+ HTML as well as in various API calls. For now there are only a few very common
+ aliases but we'll expand it in the future. All of them are listed in the
+ [class reference][].
+
+- Language detection can now be restricted to a subset of languages relevant in
+ a given context — a web page or even a single highlighting call. This is
+ especially useful for node.js build that includes all the known languages.
+ Another example is a StackOverflow-style site where users specify languages
+ as tags rather than in the markdown-formatted code snippets. This is
+ documented in the [API reference][] (see methods `highlightAuto` and
+ `configure`).
+
+- Language definition syntax streamlined with [variants][] and
+ [beginKeywords][].
+
+New languages and styles:
+
+- *Oxygene* by [Carlo Kok][]
+- *Mathematica* by [Daniel Kvasnička][]
+- *Autohotkey* by [Seongwon Lee][]
+- *Atelier* family of styles in 10 variants by [Bram de Haan][]
+- *Paraíso* styles by [Jan T. Sott][]
+
+Miscelleanous improvements:
+
+- Highlighting `=>` prompts in Clojure.
+- [Jeremy Hull][] fixed a lot of styles for consistency.
+- Finally, highlighting PHP and HTML [mixed in peculiar ways][php-html].
+- Objective C and C# now properly highlight titles in method definition.
+- Big overhaul of relevance counting for a number of languages. Please do report
+ bugs about mis-detection of non-trivial code snippets!
+
+[cr]: http://highlightjs.readthedocs.org/en/latest/css-classes-reference.html
+[api docs]: http://highlightjs.readthedocs.org/en/latest/api.html
+[variants]: https://groups.google.com/d/topic/highlightjs/VoGC9-1p5vk/discussion
+[beginKeywords]: https://github.com/isagalaev/highlight.js/commit/6c7fdea002eb3949577a85b3f7930137c7c3038d
+[php-html]: https://twitter.com/highlightjs/status/408890903017689088
+
+[Carlo Kok]: https://github.com/carlokok
+[Bram de Haan]: https://github.com/atelierbram
+[Daniel Kvasnička]: https://github.com/dkvasnicka
+[Dmitry Smolin]: https://github.com/dimsmol
+[Jeremy Hull]: https://github.com/sourrust
+[Seongwon Lee]: https://github.com/dlimpid
+[Jan T. Sott]: https://github.com/idleberg
+
+
+## Version 7.5
+
+A catch-up release dealing with some of the accumulated contributions. This one
+is probably will be the last before the 8.0 which will be slightly backwards
+incompatible regarding some advanced use-cases.
+
+One outstanding change in this version is the addition of 6 languages to the
+[hosted script][d]: Markdown, ObjectiveC, CoffeeScript, Apache, Nginx and
+Makefile. It now weighs about 6K more but we're going to keep it under 30K.
+
+New languages:
+
+- OCaml by [Mehdi Dogguy][mehdid] and [Nicolas Braud-Santoni][nbraud]
+- [LiveCode Server][lcs] by [Ralf Bitter][revig]
+- Scilab by [Sylvestre Ledru][sylvestre]
+- basic support for Makefile by [Ivan Sagalaev][isagalaev]
+
+Improvements:
+
+- Ruby's got support for characters like `?A`, `?1`, `?\012` etc. and `%r{..}`
+ regexps.
+- Clojure now allows a function call in the beginning of s-expressions
+ `(($filter "myCount") (arr 1 2 3 4 5))`.
+- Haskell's got new keywords and now recognizes more things like pragmas,
+ preprocessors, modules, containers, FFIs etc. Thanks to [Zena Treep][treep]
+ for the implementation and to [Jeremy Hull][sourrust] for guiding it.
+- Miscelleanous fixes in PHP, Brainfuck, SCSS, Asciidoc, CMake, Python and F#.
+
+[mehdid]: https://github.com/mehdid
+[nbraud]: https://github.com/nbraud
+[revig]: https://github.com/revig
+[lcs]: http://livecode.com/developers/guides/server/
+[sylvestre]: https://github.com/sylvestre
+[isagalaev]: https://github.com/isagalaev
+[treep]: https://github.com/treep
+[sourrust]: https://github.com/sourrust
+[d]: http://highlightjs.org/download/
+
+
+## New core developers
+
+The latest long period of almost complete inactivity in the project coincided
+with growing interest to it led to a decision that now seems completely obvious:
+we need more core developers.
+
+So without further ado let me welcome to the core team two long-time
+contributors: [Jeremy Hull][] and [Oleg
+Efimov][].
+
+Hope now we'll be able to work through stuff faster!
+
+P.S. The historical commit is [here][1] for the record.
+
+[Jeremy Hull]: https://github.com/sourrust
+[Oleg Efimov]: https://github.com/sannis
+[1]: https://github.com/isagalaev/highlight.js/commit/f3056941bda56d2b72276b97bc0dd5f230f2473f
+
+
+## Version 7.4
+
+This long overdue version is a snapshot of the current source tree with all the
+changes that happened during the past year. Sorry for taking so long!
+
+Along with the changes in code highlight.js has finally got its new home at
+, moving from its craddle on Software Maniacs which it
+outgrew a long time ago. Be sure to report any bugs about the site to
+.
+
+On to what's new…
+
+New languages:
+
+- Handlebars templates by [Robin Ward][]
+- Oracle Rules Language by [Jason Jacobson][]
+- F# by [Joans Follesø][]
+- AsciiDoc and Haml by [Dan Allen][]
+- Lasso by [Eric Knibbe][]
+- SCSS by [Kurt Emch][]
+- VB.NET by [Poren Chiang][]
+- Mizar by [Kelley van Evert][]
+
+[Robin Ward]: https://github.com/eviltrout
+[Jason Jacobson]: https://github.com/jayce7
+[Joans Follesø]: https://github.com/follesoe
+[Dan Allen]: https://github.com/mojavelinux
+[Eric Knibbe]: https://github.com/EricFromCanada
+[Kurt Emch]: https://github.com/kemch
+[Poren Chiang]: https://github.com/rschiang
+[Kelley van Evert]: https://github.com/kelleyvanevert
+
+New style themes:
+
+- Monokai Sublime by [noformnocontent][]
+- Railscasts by [Damien White][]
+- Obsidian by [Alexander Marenin][]
+- Docco by [Simon Madine][]
+- Mono Blue by [Ivan Sagalaev][] (uses a single color hue for everything)
+- Foundation by [Dan Allen][]
+
+[noformnocontent]: http://nn.mit-license.org/
+[Damien White]: https://github.com/visoft
+[Alexander Marenin]: https://github.com/ioncreature
+[Simon Madine]: https://github.com/thingsinjars
+[Ivan Sagalaev]: https://github.com/isagalaev
+
+Other notable changes:
+
+- Corrected many corner cases in CSS.
+- Dropped Python 2 version of the build tool.
+- Implemented building for the AMD format.
+- Updated Rust keywords (thanks to [Dmitry Medvinsky][]).
+- Literal regexes can now be used in language definitions.
+- CoffeeScript highlighting is now significantly more robust and rich due to
+ input from [Cédric Néhémie][].
+
+[Dmitry Medvinsky]: https://github.com/dmedvinsky
+[Cédric Néhémie]: https://github.com/abe33
+
+
+## Version 7.3
+
+- Since this version highlight.js no longer works in IE version 8 and older.
+ It's made it possible to reduce the library size and dramatically improve code
+ readability and made it easier to maintain. Time to go forward!
+
+- New languages: AppleScript (by [Nathan Grigg][ng] and [Dr. Drang][dd]) and
+ Brainfuck (by [Evgeny Stepanischev][bolk]).
+
+- Improvements to existing languages:
+
+ - interpreter prompt in Python (`>>>` and `...`)
+ - @-properties and classes in CoffeeScript
+ - E4X in JavaScript (by [Oleg Efimov][oe])
+ - new keywords in Perl (by [Kirk Kimmel][kk])
+ - big Ruby syntax update (by [Vasily Polovnyov][vast])
+ - small fixes in Bash
+
+- Also Oleg Efimov did a great job of moving all the docs for language and style
+ developers and contributors from the old wiki under the source code in the
+ "docs" directory. Now these docs are nicely presented at
+ .
+
+[ng]: https://github.com/nathan11g
+[dd]: https://github.com/drdrang
+[bolk]: https://github.com/bolknote
+[oe]: https://github.com/Sannis
+[kk]: https://github.com/kimmel
+[vast]: https://github.com/vast
+
+
+## Version 7.2
+
+A regular bug-fix release without any significant new features. Enjoy!
+
+
+## Version 7.1
+
+A Summer crop:
+
+- [Marc Fornos][mf] made the definition for Clojure along with the matching
+ style Rainbow (which, of course, works for other languages too).
+- CoffeeScript support continues to improve getting support for regular
+ expressions.
+- Yoshihide Jimbo ported to highlight.js [five Tomorrow styles][tm] from the
+ [project by Chris Kempson][tm0].
+- Thanks to [Casey Duncun][cd] the library can now be built in the popular
+ [AMD format][amd].
+- And last but not least, we've got a fair number of correctness and consistency
+ fixes, including a pretty significant refactoring of Ruby.
+
+[mf]: https://github.com/mfornos
+[tm]: http://jmblog.github.com/color-themes-for-highlightjs/
+[tm0]: https://github.com/ChrisKempson/Tomorrow-Theme
+[cd]: https://github.com/caseman
+[amd]: http://requirejs.org/docs/whyamd.html
+
+
+## Version 7.0
+
+The reason for the new major version update is a global change of keyword syntax
+which resulted in the library getting smaller once again. For example, the
+hosted build is 2K less than at the previous version while supporting two new
+languages.
+
+Notable changes:
+
+- The library now works not only in a browser but also with [node.js][]. It is
+ installable with `npm install highlight.js`. [API][] docs are available on our
+ wiki.
+
+- The new unique feature (apparently) among syntax highlighters is highlighting
+ *HTTP* headers and an arbitrary language in the request body. The most useful
+ languages here are *XML* and *JSON* both of which highlight.js does support.
+ Here's [the detailed post][p] about the feature.
+
+- Two new style themes: a dark "south" *[Pojoaque][]* by Jason Tate and an
+ emulation of*XCode* IDE by [Angel Olloqui][ao].
+
+- Three new languages: *D* by [Aleksandar Ružičić][ar], *R* by [Joe Cheng][jc]
+ and *GLSL* by [Sergey Tikhomirov][st].
+
+- *Nginx* syntax has become a million times smaller and more universal thanks to
+ remaking it in a more generic manner that doesn't require listing all the
+ directives in the known universe.
+
+- Function titles are now highlighted in *PHP*.
+
+- *Haskell* and *VHDL* were significantly reworked to be more rich and correct
+ by their respective maintainers [Jeremy Hull][sr] and [Igor Kalnitsky][ik].
+
+And last but not least, many bugs have been fixed around correctness and
+language detection.
+
+Overall highlight.js currently supports 51 languages and 20 style themes.
+
+[node.js]: http://nodejs.org/
+[api]: http://softwaremaniacs.org/wiki/doku.php/highlight.js:api
+[p]: http://softwaremaniacs.org/blog/2012/05/10/http-and-json-in-highlight-js/en/
+[pojoaque]: http://web-cms-designs.com/ftopict-10-pojoaque-style-for-highlight-js-code-highlighter.html
+[ao]: https://github.com/angelolloqui
+[ar]: https://github.com/raleksandar
+[jc]: https://github.com/jcheng5
+[st]: https://github.com/tikhomirov
+[sr]: https://github.com/sourrust
+[ik]: https://github.com/ikalnitsky
+
+
+## Version 6.2
+
+A lot of things happened in highlight.js since the last version! We've got nine
+new contributors, the discussion group came alive, and the main branch on GitHub
+now counts more than 350 followers. Here are most significant results coming
+from all this activity:
+
+- 5 (five!) new languages: Rust, ActionScript, CoffeeScript, MatLab and
+ experimental support for markdown. Thanks go to [Andrey Vlasovskikh][av],
+ [Alexander Myadzel][am], [Dmytrii Nagirniak][dn], [Oleg Efimov][oe], [Denis
+ Bardadym][db] and [John Crepezzi][jc].
+
+- 2 new style themes: Monokai by [Luigi Maselli][lm] and stylistic imitation of
+ another well-known highlighter Google Code Prettify by [Aahan Krish][ak].
+
+- A vast number of [correctness fixes and code refactorings][log], mostly made
+ by [Oleg Efimov][oe] and [Evgeny Stepanischev][es].
+
+[av]: https://github.com/vlasovskikh
+[am]: https://github.com/myadzel
+[dn]: https://github.com/dnagir
+[oe]: https://github.com/Sannis
+[db]: https://github.com/btd
+[jc]: https://github.com/seejohnrun
+[lm]: http://grigio.org/
+[ak]: https://github.com/geekpanth3r
+[es]: https://github.com/bolknote
+[log]: https://github.com/isagalaev/highlight.js/commits/
+
+
+## Version 6.1 — Solarized
+
+[Jeremy Hull][jh] has implemented my dream feature — a port of [Solarized][]
+style theme famous for being based on the intricate color theory to achieve
+correct contrast and color perception. It is now available for highlight.js in
+both variants — light and dark.
+
+This version also adds a new original style Arta. Its author pumbur maintains a
+[heavily modified fork of highlight.js][pb] on GitHub.
+
+[jh]: https://github.com/sourrust
+[solarized]: http://ethanschoonover.com/solarized
+[pb]: https://github.com/pumbur/highlight.js
+
+
+## Version 6.0
+
+New major version of the highlighter has been built on a significantly
+refactored syntax. Due to this it's even smaller than the previous one while
+supporting more languages!
+
+New languages are:
+
+- Haskell by [Jeremy Hull][sourrust]
+- Erlang in two varieties — module and REPL — made collectively by [Nikolay
+ Zakharov][desh], [Dmitry Kovega][arhibot] and [Sergey Ignatov][ignatov]
+- Objective C by [Valerii Hiora][vhbit]
+- Vala by [Antono Vasiljev][antono]
+- Go by [Stephan Kountso][steplg]
+
+[sourrust]: https://github.com/sourrust
+[desh]: http://desh.su/
+[arhibot]: https://github.com/arhibot
+[ignatov]: https://github.com/ignatov
+[vhbit]: https://github.com/vhbit
+[antono]: https://github.com/antono
+[steplg]: https://github.com/steplg
+
+Also this version is marginally faster and fixes a number of small long-standing
+bugs.
+
+Developer overview of the new language syntax is available in a [blog post about
+recent beta release][beta].
+
+[beta]: http://softwaremaniacs.org/blog/2011/04/25/highlight-js-60-beta/en/
+
+P.S. New version is not yet available on a Yandex' CDN, so for now you have to
+download [your own copy][d].
+
+[d]: /soft/highlight/en/download/
+
+
+## Version 5.14
+
+Fixed bugs in HTML/XML detection and relevance introduced in previous
+refactoring.
+
+Also test.html now shows the second best result of language detection by
+relevance.
+
+
+## Version 5.13
+
+Past weekend began with a couple of simple additions for existing languages but
+ended up in a big code refactoring bringing along nice improvements for language
+developers.
+
+### For users
+
+- Description of C++ has got new keywords from the upcoming [C++ 0x][] standard.
+- Description of HTML has got new tags from [HTML 5][].
+- CSS-styles have been unified to use consistent padding and also have lost
+ pop-outs with names of detected languages.
+- [Igor Kalnitsky][ik] has sent two new language descriptions: CMake и VHDL.
+
+This makes total number of languages supported by highlight.js to reach 35.
+
+Bug fixes:
+
+- Custom classes on `
` tags are not being overridden anymore
+- More correct highlighting of code blocks inside non-`
` containers:
+ highlighter now doesn't insist on replacing them with its own container and
+ just replaces the contents.
+- Small fixes in browser compatibility and heuristics.
+
+[c++ 0x]: http://ru.wikipedia.org/wiki/C%2B%2B0x
+[html 5]: http://en.wikipedia.org/wiki/HTML5
+[ik]: http://kalnitsky.org.ua/
+
+### For developers
+
+The most significant change is the ability to include language submodes right
+under `contains` instead of defining explicit named submodes in the main array:
+
+ contains: [
+ 'string',
+ 'number',
+ {begin: '\\n', end: hljs.IMMEDIATE_RE}
+ ]
+
+This is useful for auxiliary modes needed only in one place to define parsing.
+Note that such modes often don't have `className` and hence won't generate a
+separate `` in the resulting markup. This is similar in effect to
+`noMarkup: true`. All existing languages have been refactored accordingly.
+
+Test file test.html has at last become a real test. Now it not only puts the
+detected language name under the code snippet but also tests if it matches the
+expected one. Test summary is displayed right above all language snippets.
+
+
+## CDN
+
+Fine people at [Yandex][] agreed to host highlight.js on their big fast servers.
+[Link up][l]!
+
+[yandex]: http://yandex.com/
+[l]: http://softwaremaniacs.org/soft/highlight/en/download/
+
+
+## Version 5.10 — "Paris".
+
+Though I'm on a vacation in Paris, I decided to release a new version with a
+couple of small fixes:
+
+- Tomas Vitvar discovered that TAB replacement doesn't always work when used
+ with custom markup in code
+- SQL parsing is even more rigid now and doesn't step over SmallTalk in tests
+
+
+## Version 5.9
+
+A long-awaited version is finally released.
+
+New languages:
+
+- Andrew Fedorov made a definition for Lua
+- a long-time highlight.js contributor [Peter Leonov][pl] made a definition for
+ Nginx config
+- [Vladimir Moskva][vm] made a definition for TeX
+
+[pl]: http://kung-fu-tzu.ru/
+[vm]: http://fulc.ru/
+
+Fixes for existing languages:
+
+- [Loren Segal][ls] reworked the Ruby definition and added highlighting for
+ [YARD][] inline documentation
+- the definition of SQL has become more solid and now it shouldn't be overly
+ greedy when it comes to language detection
+
+[ls]: http://gnuu.org/
+[yard]: http://yardoc.org/
+
+The highlighter has become more usable as a library allowing to do highlighting
+from initialization code of JS frameworks and in ajax methods (see.
+readme.eng.txt).
+
+Also this version drops support for the [WordPress][wp] plugin. Everyone is
+welcome to [pick up its maintenance][p] if needed.
+
+[wp]: http://wordpress.org/
+[p]: http://bazaar.launchpad.net/~isagalaev/+junk/highlight/annotate/342/src/wp_highlight.js.php
+
+
+## Version 5.8
+
+- Jan Berkel has contributed a definition for Scala. +1 to hotness!
+- All CSS-styles are rewritten to work only inside `
` tags to avoid
+ conflicts with host site styles.
+
+
+## Version 5.7.
+
+Fixed escaping of quotes in VBScript strings.
+
+
+## Version 5.5
+
+This version brings a small change: now .ini-files allow digits, underscores and
+square brackets in key names.
+
+
+## Version 5.4
+
+Fixed small but upsetting bug in the packer which caused incorrect highlighting
+of explicitly specified languages. Thanks to Andrew Fedorov for precise
+diagnostics!
+
+
+## Version 5.3
+
+The version to fulfil old promises.
+
+The most significant change is that highlight.js now preserves custom user
+markup in code along with its own highlighting markup. This means that now it's
+possible to use, say, links in code. Thanks to [Vladimir Dolzhenko][vd] for the
+[initial proposal][1] and for making a proof-of-concept patch.
+
+Also in this version:
+
+- [Vasily Polovnyov][vp] has sent a GitHub-like style and has implemented
+ support for CSS @-rules and Ruby symbols.
+- Yura Zaripov has sent two styles: Brown Paper and School Book.
+- Oleg Volchkov has sent a definition for [Parser 3][p3].
+
+[1]: http://softwaremaniacs.org/forum/highlightjs/6612/
+[p3]: http://www.parser.ru/
+[vp]: http://vasily.polovnyov.ru/
+[vd]: http://dolzhenko.blogspot.com/
+
+
+## Version 5.2
+
+- at last it's possible to replace indentation TABs with something sensible (e.g. 2 or 4 spaces)
+- new keywords and built-ins for 1C by Sergey Baranov
+- a couple of small fixes to Apache highlighting
+
+
+## Version 5.1
+
+This is one of those nice version consisting entirely of new and shiny
+contributions!
+
+- [Vladimir Ermakov][vooon] created highlighting for AVR Assembler
+- [Ruslan Keba][rukeba] created highlighting for Apache config file. Also his
+ original visual style for it is now available for all highlight.js languages
+ under the name "Magula".
+- [Shuen-Huei Guan][drake] (aka Drake) sent new keywords for RenderMan
+ languages. Also thanks go to [Konstantin Evdokimenko][ke] for his advice on
+ the matter.
+
+[vooon]: http://vehq.ru/about/
+[rukeba]: http://rukeba.com/
+[drake]: http://drakeguan.org/
+[ke]: http://k-evdokimenko.moikrug.ru/
+
+
+## Version 5.0
+
+The main change in the new major version of highlight.js is a mechanism for
+packing several languages along with the library itself into a single compressed
+file. Now sites using several languages will load considerably faster because
+the library won't dynamically include additional files while loading.
+
+Also this version fixes a long-standing bug with Javascript highlighting that
+couldn't distinguish between regular expressions and division operations.
+
+And as usually there were a couple of minor correctness fixes.
+
+Great thanks to all contributors! Keep using highlight.js.
+
+
+## Version 4.3
+
+This version comes with two contributions from [Jason Diamond][jd]:
+
+- language definition for C# (yes! it was a long-missed thing!)
+- Visual Studio-like highlighting style
+
+Plus there are a couple of minor bug fixes for parsing HTML and XML attributes.
+
+[jd]: http://jason.diamond.name/weblog/
+
+
+## Version 4.2
+
+The biggest news is highlighting for Lisp, courtesy of Vasily Polovnyov. It's
+somewhat experimental meaning that for highlighting "keywords" it doesn't use
+any pre-defined set of a Lisp dialect. Instead it tries to highlight first word
+in parentheses wherever it makes sense. I'd like to ask people programming in
+Lisp to confirm if it's a good idea and send feedback to [the forum][f].
+
+Other changes:
+
+- Smalltalk was excluded from DEFAULT_LANGUAGES to save traffic
+- [Vladimir Epifanov][voldmar] has implemented javascript style switcher for
+ test.html
+- comments now allowed inside Ruby function definition
+- [MEL][] language from [Shuen-Huei Guan][drake]
+- whitespace now allowed between `
` and ``
+- better auto-detection of C++ and PHP
+- HTML allows embedded VBScript (`<% .. %>`)
+
+[f]: http://softwaremaniacs.org/forum/highlightjs/
+[voldmar]: http://voldmar.ya.ru/
+[mel]: http://en.wikipedia.org/wiki/Maya_Embedded_Language
+[drake]: http://drakeguan.org/
+
+
+## Version 4.1
+
+Languages:
+
+- Bash from Vah
+- DOS bat-files from Alexander Makarov (Sam)
+- Diff files from Vasily Polovnyov
+- Ini files from myself though initial idea was from Sam
+
+Styles:
+
+- Zenburn from Vladimir Epifanov, this is an imitation of a
+ [well-known theme for Vim][zenburn].
+- Ascetic from myself, as a realization of ideals of non-flashy highlighting:
+ just one color in only three gradations :-)
+
+In other news. [One small bug][bug] was fixed, built-in keywords were added for
+Python and C++ which improved auto-detection for the latter (it was shame that
+[my wife's blog][alenacpp] had issues with it from time to time). And lastly
+thanks go to Sam for getting rid of my stylistic comments in code that were
+getting in the way of [JSMin][].
+
+[zenburn]: http://en.wikipedia.org/wiki/Zenburn
+[alenacpp]: http://alenacpp.blogspot.com/
+[bug]: http://softwaremaniacs.org/forum/viewtopic.php?id=1823
+[jsmin]: http://code.google.com/p/jsmin-php/
+
+
+## Version 4.0
+
+New major version is a result of vast refactoring and of many contributions.
+
+Visible new features:
+
+- Highlighting of embedded languages. Currently is implemented highlighting of
+ Javascript and CSS inside HTML.
+- Bundled 5 ready-made style themes!
+
+Invisible new features:
+
+- Highlight.js no longer pollutes global namespace. Only one object and one
+ function for backward compatibility.
+- Performance is further increased by about 15%.
+
+Changing of a major version number caused by a new format of language definition
+files. If you use some third-party language files they should be updated.
+
+
+## Version 3.5
+
+A very nice version in my opinion fixing a number of small bugs and slightly
+increased speed in a couple of corner cases. Thanks to everybody who reports
+bugs in he [forum][f] and by email!
+
+There is also a new language — XML. A custom XML formerly was detected as HTML
+and didn't highlight custom tags. In this version I tried to make custom XML to
+be detected and highlighted by its own rules. Which by the way include such
+things as CDATA sections and processing instructions (` ... ?>`).
+
+[f]: http://softwaremaniacs.org/forum/viewforum.php?id=6
+
+
+## Version 3.3
+
+[Vladimir Gubarkov][xonix] has provided an interesting and useful addition.
+File export.html contains a little program that shows and allows to copy and
+paste an HTML code generated by the highlighter for any code snippet. This can
+be useful in situations when one can't use the script itself on a site.
+
+
+[xonix]: http://xonixx.blogspot.com/
+
+
+## Version 3.2 consists completely of contributions:
+
+- Vladimir Gubarkov has described SmallTalk
+- Yuri Ivanov has described 1C
+- Peter Leonov has packaged the highlighter as a Firefox extension
+- Vladimir Ermakov has compiled a mod for phpBB
+
+Many thanks to you all!
+
+
+## Version 3.1
+
+Three new languages are available: Django templates, SQL and Axapta. The latter
+two are sent by [Dmitri Roudakov][1]. However I've almost entirely rewrote an
+SQL definition but I'd never started it be it from the ground up :-)
+
+The engine itself has got a long awaited feature of grouping keywords
+("keyword", "built-in function", "literal"). No more hacks!
+
+[1]: http://roudakov.ru/
+
+
+## Version 3.0
+
+It is major mainly because now highlight.js has grown large and has become
+modular. Now when you pass it a list of languages to highlight it will
+dynamically load into a browser only those languages.
+
+Also:
+
+- Konstantin Evdokimenko of [RibKit][] project has created a highlighting for
+ RenderMan Shading Language and RenderMan Interface Bytestream. Yay for more
+ languages!
+- Heuristics for C++ and HTML got better.
+- I've implemented (at last) a correct handling of backslash escapes in C-like
+ languages.
+
+There is also a small backwards incompatible change in the new version. The
+function initHighlighting that was used to initialize highlighting instead of
+initHighlightingOnLoad a long time ago no longer works. If you by chance still
+use it — replace it with the new one.
+
+[RibKit]: http://ribkit.sourceforge.net/
+
+
+## Version 2.9
+
+Highlight.js is a parser, not just a couple of regular expressions. That said
+I'm glad to announce that in the new version 2.9 has support for:
+
+- in-string substitutions for Ruby -- `#{...}`
+- strings from from numeric symbol codes (like #XX) for Delphi
+
+
+## Version 2.8
+
+A maintenance release with more tuned heuristics. Fully backwards compatible.
+
+
+## Version 2.7
+
+- Nikita Ledyaev presents highlighting for VBScript, yay!
+- A couple of bugs with escaping in strings were fixed thanks to Mickle
+- Ongoing tuning of heuristics
+
+Fixed bugs were rather unpleasant so I encourage everyone to upgrade!
+
+
+## Version 2.4
+
+- Peter Leonov provides another improved highlighting for Perl
+- Javascript gets a new kind of keywords — "literals". These are the words
+ "true", "false" and "null"
+
+Also highlight.js homepage now lists sites that use the library. Feel free to
+add your site by [dropping me a message][mail] until I find the time to build a
+submit form.
+
+[mail]: mailto:Maniac@SoftwareManiacs.Org
+
+
+## Version 2.3
+
+This version fixes IE breakage in previous version. My apologies to all who have
+already downloaded that one!
+
+
+## Version 2.2
+
+- added highlighting for Javascript
+- at last fixed parsing of Delphi's escaped apostrophes in strings
+- in Ruby fixed highlighting of keywords 'def' and 'class', same for 'sub' in
+ Perl
+
+
+## Version 2.0
+
+- Ruby support by [Anton Kovalyov][ak]
+- speed increased by orders of magnitude due to new way of parsing
+- this same way allows now correct highlighting of keywords in some tricky
+ places (like keyword "End" at the end of Delphi classes)
+
+[ak]: http://anton.kovalyov.net/
+
+
+## Version 1.0
+
+Version 1.0 of javascript syntax highlighter is released!
+
+It's the first version available with English description. Feel free to post
+your comments and question to [highlight.js forum][forum]. And don't be afraid
+if you find there some fancy Cyrillic letters -- it's for Russian users too :-)
+
+[forum]: http://softwaremaniacs.org/forum/viewforum.php?id=6
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lib/highlight/LICENSE b/assets/ckeditor-contrib/plugins/codesnippet/lib/highlight/LICENSE
new file mode 100644
index 00000000..422deb73
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lib/highlight/LICENSE
@@ -0,0 +1,24 @@
+Copyright (c) 2006, Ivan Sagalaev
+All rights reserved.
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are met:
+
+ * Redistributions of source code must retain the above copyright
+ notice, this list of conditions and the following disclaimer.
+ * Redistributions in binary form must reproduce the above copyright
+ notice, this list of conditions and the following disclaimer in the
+ documentation and/or other materials provided with the distribution.
+ * Neither the name of highlight.js nor the names of its contributors
+ may be used to endorse or promote products derived from this software
+ without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND ANY
+EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+DISCLAIMED. IN NO EVENT SHALL THE REGENTS AND CONTRIBUTORS BE LIABLE FOR ANY
+DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lib/highlight/README.md b/assets/ckeditor-contrib/plugins/codesnippet/lib/highlight/README.md
new file mode 100644
index 00000000..0ee96377
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lib/highlight/README.md
@@ -0,0 +1,167 @@
+# Highlight.js
+
+Highlight.js highlights syntax in code examples on blogs, forums and,
+in fact, on any web page. It's very easy to use because it works
+automatically: finds blocks of code, detects a language, highlights it.
+
+Autodetection can be fine tuned when it fails by itself (see "Heuristics").
+
+
+## Basic usage
+
+Link the library and a stylesheet from your page and hook highlighting to
+the page load event:
+
+```html
+
+
+
+```
+
+This will highlight all code on the page marked up as `
..
`.
+If you use different markup or need to apply highlighting dynamically, read
+"Custom initialization" below.
+
+- You can download your own customized version of "highlight.pack.js" or
+ use the hosted one as described on the download page:
+
+
+- Style themes are available in the download package or as hosted files.
+ To create a custom style for your site see the class reference in the file
+ [CSS classes reference][cr] from the downloaded package.
+
+[cr]: http://highlightjs.readthedocs.org/en/latest/css-classes-reference.html
+
+
+## node.js
+
+Highlight.js can be used under node.js. The package with all supported languages is
+installable from NPM:
+
+ npm install highlight.js
+
+Alternatively, you can build it from the source with only languages you need:
+
+ python3 tools/build.py -tnode lang1 lang2 ..
+
+Using the library:
+
+```javascript
+var hljs = require('highlight.js');
+
+// If you know the language
+hljs.highlight(lang, code).value;
+
+// Automatic language detection
+hljs.highlightAuto(code).value;
+```
+
+
+## AMD
+
+Highlight.js can be used with an AMD loader. You will need to build it from
+source in order to do so:
+
+```bash
+$ python3 tools/build.py -tamd lang1 lang2 ..
+```
+
+Which will generate a `build/highlight.pack.js` which will load as an AMD
+module with support for the built languages and can be used like so:
+
+```javascript
+require(["highlight.js/build/highlight.pack"], function(hljs){
+
+ // If you know the language
+ hljs.highlight(lang, code).value;
+
+ // Automatic language detection
+ hljs.highlightAuto(code).value;
+});
+```
+
+
+## Tab replacement
+
+You can replace TAB ('\x09') characters used for indentation in your code
+with some fixed number of spaces or with a `` to give them special
+styling:
+
+```html
+
+```
+
+## Custom initialization
+
+If you use different markup for code blocks you can initialize them manually
+with `highlightBlock(code)` function. It takes a DOM element containing the
+code to highlight and optionally a string with which to replace TAB
+characters.
+
+Initialization using, for example, jQuery might look like this:
+
+```javascript
+$(document).ready(function() {
+ $('pre code').each(function(i, e) {hljs.highlightBlock(e)});
+});
+```
+
+You can use `highlightBlock` to highlight blocks dynamically inserted into
+the page. Just make sure you don't do it twice for already highlighted
+blocks.
+
+If your code container relies on ` ` tags instead of line breaks (i.e. if
+it's not `
`) set the `useBR` option to `true`:
+
+```javascript
+hljs.configure({useBR: true});
+$('div.code').each(function(i, e) {hljs.highlightBlock(e)});
+```
+
+
+## Heuristics
+
+Autodetection of a code's language is done using a simple heuristic:
+the program tries to highlight a fragment with all available languages and
+counts all syntactic structures that it finds along the way. The language
+with greatest count wins.
+
+This means that in short fragments the probability of an error is high
+(and it really happens sometimes). In this cases you can set the fragment's
+language explicitly by assigning a class to the `` element:
+
+```html
+
...
+```
+
+You can use class names recommended in HTML5: "language-html",
+"language-php". Classes also can be assigned to the `
` element.
+
+To disable highlighting of a fragment altogether use "no-highlight" class:
+
+```html
+
...
+```
+
+
+## Export
+
+File export.html contains a little program that allows you to paste in a code
+snippet and then copy and paste the resulting HTML code generated by the
+highlighter. This is useful in situations when you can't use the script itself
+on a site.
+
+
+## Meta
+
+- Version: 8.0
+- URL: http://highlightjs.org/
+
+For the license terms see LICENSE files.
+For authors and contributors see AUTHORS.en.txt file.
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lib/highlight/README.ru.md b/assets/ckeditor-contrib/plugins/codesnippet/lib/highlight/README.ru.md
new file mode 100644
index 00000000..0d0e0fea
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lib/highlight/README.ru.md
@@ -0,0 +1,171 @@
+# Highlight.js
+
+Highlight.js нужен для подсветки синтаксиса в примерах кода в блогах,
+форумах и вообще на любых веб-страницах. Пользоваться им очень просто,
+потому что работает он автоматически: сам находит блоки кода, сам
+определяет язык, сам подсвечивает.
+
+Автоопределением языка можно управлять, когда оно не справляется само (см.
+дальше "Эвристика").
+
+
+## Простое использование
+
+Подключите библиотеку и стиль на страницу и повесть вызов подсветки на
+загрузку страницы:
+
+```html
+
+
+
+```
+
+Весь код на странице, обрамлённый в теги `
..
`
+будет автоматически подсвечен. Если вы используете другие теги или хотите
+подсвечивать блоки кода динамически, читайте "Инициализацию вручную" ниже.
+
+- Вы можете скачать собственную версию "highlight.pack.js" или сослаться
+ на захостенный файл, как описано на странице загрузки:
+
+
+- Стилевые темы можно найти в загруженном архиве или также использовать
+ захостенные. Чтобы сделать собственный стиль для своего сайта, вам
+ будет полезен [CSS classes reference][cr], который тоже есть в архиве.
+
+[cr]: http://highlightjs.readthedocs.org/en/latest/css-classes-reference.html
+
+
+## node.js
+
+Highlight.js можно использовать в node.js. Библиотеку со всеми возможными языками можно
+установить с NPM:
+
+ npm install highlight.js
+
+Также её можно собрать из исходников с только теми языками, которые нужны:
+
+ python3 tools/build.py -tnode lang1 lang2 ..
+
+Использование библиотеки:
+
+```javascript
+var hljs = require('highlight.js');
+
+// Если вы знаете язык
+hljs.highlight(lang, code).value;
+
+// Автоопределение языка
+hljs.highlightAuto(code).value;
+```
+
+
+## AMD
+
+Highlight.js можно использовать с загрузчиком AMD-модулей. Для этого его
+нужно собрать из исходников следующей командой:
+
+```bash
+$ python3 tools/build.py -tamd lang1 lang2 ..
+```
+
+Она создаст файл `build/highlight.pack.js`, который является загружаемым
+AMD-модулем и содержит все выбранные при сборке языки. Используется он так:
+
+```javascript
+require(["highlight.js/build/highlight.pack"], function(hljs){
+
+ // Если вы знаете язык
+ hljs.highlight(lang, code).value;
+
+ // Автоопределение языка
+ hljs.highlightAuto(code).value;
+});
+```
+
+
+## Замена TABов
+
+Также вы можете заменить символы TAB ('\x09'), используемые для отступов, на
+фиксированное количество пробелов или на отдельный ``, чтобы задать ему
+какой-нибудь специальный стиль:
+
+```html
+
+```
+
+
+## Инициализация вручную
+
+Если вы используете другие теги для блоков кода, вы можете инициализировать их
+явно с помощью функции `highlightBlock(code)`. Она принимает DOM-элемент с
+текстом расцвечиваемого кода и опционально - строчку для замены символов TAB.
+
+Например с использованием jQuery код инициализации может выглядеть так:
+
+```javascript
+$(document).ready(function() {
+ $('pre code').each(function(i, e) {hljs.highlightBlock(e)});
+});
+```
+
+`highlightBlock` можно также использовать, чтобы подсветить блоки кода,
+добавленные на страницу динамически. Только убедитесь, что вы не делаете этого
+повторно для уже раскрашенных блоков.
+
+Если ваш блок кода использует ` ` вместо переводов строки (т.е. если это не
+`
`), включите опцию `useBR`:
+
+```javascript
+hljs.configure({useBR: true});
+$('div.code').each(function(i, e) {hljs.highlightBlock(e)});
+```
+
+
+## Эвристика
+
+Определение языка, на котором написан фрагмент, делается с помощью
+довольно простой эвристики: программа пытается расцветить фрагмент всеми
+языками подряд, и для каждого языка считает количество подошедших
+синтаксически конструкций и ключевых слов. Для какого языка нашлось больше,
+тот и выбирается.
+
+Это означает, что в коротких фрагментах высока вероятность ошибки, что
+периодически и случается. Чтобы указать язык фрагмента явно, надо написать
+его название в виде класса к элементу ``:
+
+```html
+
...
+```
+
+Можно использовать рекомендованные в HTML5 названия классов:
+"language-html", "language-php". Также можно назначать классы на элемент
+`
`.
+
+Чтобы запретить расцветку фрагмента вообще, используется класс "no-highlight":
+
+```html
+
...
+```
+
+
+## Экспорт
+
+В файле export.html находится небольшая программка, которая показывает и дает
+скопировать непосредственно HTML-код подсветки для любого заданного фрагмента кода.
+Это может понадобится например на сайте, на котором нельзя подключить сам скрипт
+highlight.js.
+
+
+## Координаты
+
+- Версия: 8.0
+- URL: http://highlightjs.org/
+
+Лицензионное соглашение читайте в файле LICENSE.
+Список авторов и соавторов читайте в файле AUTHORS.ru.txt
diff --git a/assets/ckeditor-contrib/plugins/codesnippet/lib/highlight/highlight.pack.js b/assets/ckeditor-contrib/plugins/codesnippet/lib/highlight/highlight.pack.js
new file mode 100644
index 00000000..2f0a664d
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/codesnippet/lib/highlight/highlight.pack.js
@@ -0,0 +1,2 @@
+// %LEAVE_UNMINIFIED% %REMOVE_LINE%
+var hljs=new function(){function k(v){return v.replace(/&/gm,"&").replace(//gm,">")}function t(v){return v.nodeName.toLowerCase()}function i(w,x){var v=w&&w.exec(x);return v&&v.index==0}function d(v){return Array.prototype.map.call(v.childNodes,function(w){if(w.nodeType==3){return b.useBR?w.nodeValue.replace(/\n/g,""):w.nodeValue}if(t(w)=="br"){return"\n"}return d(w)}).join("")}function r(w){var v=(w.className+" "+(w.parentNode?w.parentNode.className:"")).split(/\s+/);v=v.map(function(x){return x.replace(/^language-/,"")});return v.filter(function(x){return j(x)||x=="no-highlight"})[0]}function o(x,y){var v={};for(var w in x){v[w]=x[w]}if(y){for(var w in y){v[w]=y[w]}}return v}function u(x){var v=[];(function w(y,z){for(var A=y.firstChild;A;A=A.nextSibling){if(A.nodeType==3){z+=A.nodeValue.length}else{if(t(A)=="br"){z+=1}else{if(A.nodeType==1){v.push({event:"start",offset:z,node:A});z=w(A,z);v.push({event:"stop",offset:z,node:A})}}}}return z})(x,0);return v}function q(w,y,C){var x=0;var F="";var z=[];function B(){if(!w.length||!y.length){return w.length?w:y}if(w[0].offset!=y[0].offset){return(w[0].offset"}function E(G){F+=""+t(G)+">"}function v(G){(G.event=="start"?A:E)(G.node)}while(w.length||y.length){var D=B();F+=k(C.substr(x,D[0].offset-x));x=D[0].offset;if(D==w){z.reverse().forEach(E);do{v(D.splice(0,1)[0]);D=B()}while(D==w&&D.length&&D[0].offset==x);z.reverse().forEach(A)}else{if(D[0].event=="start"){z.push(D[0].node)}else{z.pop()}v(D.splice(0,1)[0])}}return F+k(C.substr(x))}function m(y){function v(z){return(z&&z.source)||z}function w(A,z){return RegExp(v(A),"m"+(y.cI?"i":"")+(z?"g":""))}function x(D,C){if(D.compiled){return}D.compiled=true;D.k=D.k||D.bK;if(D.k){var z={};function E(G,F){if(y.cI){F=F.toLowerCase()}F.split(" ").forEach(function(H){var I=H.split("|");z[I[0]]=[G,I[1]?Number(I[1]):1]})}if(typeof D.k=="string"){E("keyword",D.k)}else{Object.keys(D.k).forEach(function(F){E(F,D.k[F])})}D.k=z}D.lR=w(D.l||/\b[A-Za-z0-9_]+\b/,true);if(C){if(D.bK){D.b=D.bK.split(" ").join("|")}if(!D.b){D.b=/\B|\b/}D.bR=w(D.b);if(!D.e&&!D.eW){D.e=/\B|\b/}if(D.e){D.eR=w(D.e)}D.tE=v(D.e)||"";if(D.eW&&C.tE){D.tE+=(D.e?"|":"")+C.tE}}if(D.i){D.iR=w(D.i)}if(D.r===undefined){D.r=1}if(!D.c){D.c=[]}var B=[];D.c.forEach(function(F){if(F.v){F.v.forEach(function(G){B.push(o(F,G))})}else{B.push(F=="self"?D:F)}});D.c=B;D.c.forEach(function(F){x(F,D)});if(D.starts){x(D.starts,C)}var A=D.c.map(function(F){return F.bK?"\\.?\\b("+F.b+")\\b\\.?":F.b}).concat([D.tE]).concat([D.i]).map(v).filter(Boolean);D.t=A.length?w(A.join("|"),true):{exec:function(F){return null}};D.continuation={}}x(y)}function c(S,L,J,R){function v(U,V){for(var T=0;T";U+=Z+'">';return U+X+Y}function N(){var U=k(C);if(!I.k){return U}var T="";var X=0;I.lR.lastIndex=0;var V=I.lR.exec(U);while(V){T+=U.substr(X,V.index-X);var W=E(I,V);if(W){H+=W[1];T+=w(W[0],V[0])}else{T+=V[0]}X=I.lR.lastIndex;V=I.lR.exec(U)}return T+U.substr(X)}function F(){if(I.sL&&!f[I.sL]){return k(C)}var T=I.sL?c(I.sL,C,true,I.continuation.top):g(C);if(I.r>0){H+=T.r}if(I.subLanguageMode=="continuous"){I.continuation.top=T.top}return w(T.language,T.value,false,true)}function Q(){return I.sL!==undefined?F():N()}function P(V,U){var T=V.cN?w(V.cN,"",true):"";if(V.rB){D+=T;C=""}else{if(V.eB){D+=k(U)+T;C=""}else{D+=T;C=U}}I=Object.create(V,{parent:{value:I}})}function G(T,X){C+=T;if(X===undefined){D+=Q();return 0}var V=v(X,I);if(V){D+=Q();P(V,X);return V.rB?0:X.length}var W=z(I,X);if(W){var U=I;if(!(U.rE||U.eE)){C+=X}D+=Q();do{if(I.cN){D+="
"}H+=I.r;I=I.parent}while(I!=W.parent);if(U.eE){D+=k(X)}C="";if(W.starts){P(W.starts,"")}return U.rE?0:X.length}if(A(X,I)){throw new Error('Illegal lexeme "'+X+'" for mode "'+(I.cN||"")+'"')}C+=X;return X.length||1}var M=j(S);if(!M){throw new Error('Unknown language: "'+S+'"')}m(M);var I=R||M;var D="";for(var K=I;K!=M;K=K.parent){if(K.cN){D=w(K.cN,D,true)}}var C="";var H=0;try{var B,y,x=0;while(true){I.t.lastIndex=x;B=I.t.exec(L);if(!B){break}y=G(L.substr(x,B.index-x),B[0]);x=B.index+y}G(L.substr(x));for(var K=I;K.parent;K=K.parent){if(K.cN){D+="
"}}return{r:H,value:D,language:S,top:I}}catch(O){if(O.message.indexOf("Illegal")!=-1){return{r:0,value:k(L)}}else{throw O}}}function g(y,x){x=x||b.languages||Object.keys(f);var v={r:0,value:k(y)};var w=v;x.forEach(function(z){if(!j(z)){return}var A=c(z,y,false);A.language=z;if(A.r>w.r){w=A}if(A.r>v.r){w=v;v=A}});if(w.language){v.second_best=w}return v}function h(v){if(b.tabReplace){v=v.replace(/^((<[^>]+>|\t)+)/gm,function(w,z,y,x){return z.replace(/\t/g,b.tabReplace)})}if(b.useBR){v=v.replace(/\n/g," ")}return v}function p(z){var y=d(z);var A=r(z);if(A=="no-highlight"){return}var v=A?c(A,y,true):g(y);var w=u(z);if(w.length){var x=document.createElementNS("http://www.w3.org/1999/xhtml","pre");x.innerHTML=v.value;v.value=q(w,u(x),y)}v.value=h(v.value);z.innerHTML=v.value;z.className+=" hljs "+(!A&&v.language||"");z.result={language:v.language,re:v.r};if(v.second_best){z.second_best={language:v.second_best.language,re:v.second_best.r}}}var b={classPrefix:"hljs-",tabReplace:null,useBR:false,languages:undefined};function s(v){b=o(b,v)}function l(){if(l.called){return}l.called=true;var v=document.querySelectorAll("pre code");Array.prototype.forEach.call(v,p)}function a(){addEventListener("DOMContentLoaded",l,false);addEventListener("load",l,false)}var f={};var n={};function e(v,x){var w=f[v]=x(this);if(w.aliases){w.aliases.forEach(function(y){n[y]=v})}}function j(v){return f[v]||f[n[v]]}this.highlight=c;this.highlightAuto=g;this.fixMarkup=h;this.highlightBlock=p;this.configure=s;this.initHighlighting=l;this.initHighlightingOnLoad=a;this.registerLanguage=e;this.getLanguage=j;this.inherit=o;this.IR="[a-zA-Z][a-zA-Z0-9_]*";this.UIR="[a-zA-Z_][a-zA-Z0-9_]*";this.NR="\\b\\d+(\\.\\d+)?";this.CNR="(\\b0[xX][a-fA-F0-9]+|(\\b\\d+(\\.\\d*)?|\\.\\d+)([eE][-+]?\\d+)?)";this.BNR="\\b(0b[01]+)";this.RSR="!|!=|!==|%|%=|&|&&|&=|\\*|\\*=|\\+|\\+=|,|-|-=|/=|/|:|;|<<|<<=|<=|<|===|==|=|>>>=|>>=|>=|>>>|>>|>|\\?|\\[|\\{|\\(|\\^|\\^=|\\||\\|=|\\|\\||~";this.BE={b:"\\\\[\\s\\S]",r:0};this.ASM={cN:"string",b:"'",e:"'",i:"\\n",c:[this.BE]};this.QSM={cN:"string",b:'"',e:'"',i:"\\n",c:[this.BE]};this.CLCM={cN:"comment",b:"//",e:"$"};this.CBLCLM={cN:"comment",b:"/\\*",e:"\\*/"};this.HCM={cN:"comment",b:"#",e:"$"};this.NM={cN:"number",b:this.NR,r:0};this.CNM={cN:"number",b:this.CNR,r:0};this.BNM={cN:"number",b:this.BNR,r:0};this.REGEXP_MODE={cN:"regexp",b:/\//,e:/\/[gim]*/,i:/\n/,c:[this.BE,{b:/\[/,e:/\]/,r:0,c:[this.BE]}]};this.TM={cN:"title",b:this.IR,r:0};this.UTM={cN:"title",b:this.UIR,r:0}}();hljs.registerLanguage("bash",function(b){var a={cN:"variable",v:[{b:/\$[\w\d#@][\w\d_]*/},{b:/\$\{(.*?)\}/}]};var d={cN:"string",b:/"/,e:/"/,c:[b.BE,a,{cN:"variable",b:/\$\(/,e:/\)/,c:[b.BE]}]};var c={cN:"string",b:/'/,e:/'/};return{l:/-?[a-z\.]+/,k:{keyword:"if then else elif fi for break continue while in do done exit return set declare case esac export exec",literal:"true false",built_in:"printf echo read cd pwd pushd popd dirs let eval unset typeset readonly getopts source shopt caller type hash bind help sudo",operator:"-ne -eq -lt -gt -f -d -e -s -l -a"},c:[{cN:"shebang",b:/^#![^\n]+sh\s*$/,r:10},{cN:"function",b:/\w[\w\d_]*\s*\(\s*\)\s*\{/,rB:true,c:[b.inherit(b.TM,{b:/\w[\w\d_]*/})],r:0},b.HCM,b.NM,d,c,a]}});hljs.registerLanguage("cs",function(b){var a="abstract as base bool break byte case catch char checked const continue decimal default delegate do double else enum event explicit extern false finally fixed float for foreach goto if implicit in int interface internal is lock long new null object operator out override params private protected public readonly ref return sbyte sealed short sizeof stackalloc static string struct switch this throw true try typeof uint ulong unchecked unsafe ushort using virtual volatile void while async await ascending descending from get group into join let orderby partial select set value var where yield";return{k:a,c:[{cN:"comment",b:"///",e:"$",rB:true,c:[{cN:"xmlDocTag",b:"///|"},{cN:"xmlDocTag",b:"?",e:">"}]},b.CLCM,b.CBLCLM,{cN:"preprocessor",b:"#",e:"$",k:"if else elif endif define undef warning error line region endregion pragma checksum"},{cN:"string",b:'@"',e:'"',c:[{b:'""'}]},b.ASM,b.QSM,b.CNM,{bK:"protected public private internal",e:/[{;=]/,k:a,c:[{bK:"class namespace interface",starts:{c:[b.TM]}},{b:b.IR+"\\s*\\(",rB:true,c:[b.TM]}]}]}});hljs.registerLanguage("ruby",function(e){var h="[a-zA-Z_]\\w*[!?=]?|[-+~]\\@|<<|>>|=~|===?|<=>|[<>]=?|\\*\\*|[-/+%^&*~`|]|\\[\\]=?";var g="and false then defined module in return redo if BEGIN retry end for true self when next until do begin unless END rescue nil else break undef not super class case require yield alias while ensure elsif or include attr_reader attr_writer attr_accessor";var a={cN:"yardoctag",b:"@[A-Za-z]+"};var i={cN:"comment",v:[{b:"#",e:"$",c:[a]},{b:"^\\=begin",e:"^\\=end",c:[a],r:10},{b:"^__END__",e:"\\n$"}]};var c={cN:"subst",b:"#\\{",e:"}",k:g};var d={cN:"string",c:[e.BE,c],v:[{b:/'/,e:/'/},{b:/"/,e:/"/},{b:"%[qw]?\\(",e:"\\)"},{b:"%[qw]?\\[",e:"\\]"},{b:"%[qw]?{",e:"}"},{b:"%[qw]?<",e:">",r:10},{b:"%[qw]?/",e:"/",r:10},{b:"%[qw]?%",e:"%",r:10},{b:"%[qw]?-",e:"-",r:10},{b:"%[qw]?\\|",e:"\\|",r:10},{b:/\B\?(\\\d{1,3}|\\x[A-Fa-f0-9]{1,2}|\\u[A-Fa-f0-9]{4}|\\?\S)\b/}]};var b={cN:"params",b:"\\(",e:"\\)",k:g};var f=[d,i,{cN:"class",bK:"class module",e:"$|;",i:/=/,c:[e.inherit(e.TM,{b:"[A-Za-z_]\\w*(::\\w+)*(\\?|\\!)?"}),{cN:"inheritance",b:"<\\s*",c:[{cN:"parent",b:"("+e.IR+"::)?"+e.IR}]},i]},{cN:"function",bK:"def",e:" |$|;",r:0,c:[e.inherit(e.TM,{b:h}),b,i]},{cN:"constant",b:"(::)?(\\b[A-Z]\\w*(::)?)+",r:0},{cN:"symbol",b:":",c:[d,{b:h}],r:0},{cN:"symbol",b:e.UIR+"(\\!|\\?)?:",r:0},{cN:"number",b:"(\\b0[0-7_]+)|(\\b0x[0-9a-fA-F_]+)|(\\b[1-9][0-9_]*(\\.[0-9_]+)?)|[0_]\\b",r:0},{cN:"variable",b:"(\\$\\W)|((\\$|\\@\\@?)(\\w+))"},{b:"("+e.RSR+")\\s*",c:[i,{cN:"regexp",c:[e.BE,c],i:/\n/,v:[{b:"/",e:"/[a-z]*"},{b:"%r{",e:"}[a-z]*"},{b:"%r\\(",e:"\\)[a-z]*"},{b:"%r!",e:"![a-z]*"},{b:"%r\\[",e:"\\][a-z]*"}]}],r:0}];c.c=f;b.c=f;return{k:g,c:f}});hljs.registerLanguage("diff",function(a){return{c:[{cN:"chunk",r:10,v:[{b:/^\@\@ +\-\d+,\d+ +\+\d+,\d+ +\@\@$/},{b:/^\*\*\* +\d+,\d+ +\*\*\*\*$/},{b:/^\-\-\- +\d+,\d+ +\-\-\-\-$/}]},{cN:"header",v:[{b:/Index: /,e:/$/},{b:/=====/,e:/=====$/},{b:/^\-\-\-/,e:/$/},{b:/^\*{3} /,e:/$/},{b:/^\+\+\+/,e:/$/},{b:/\*{5}/,e:/\*{5}$/}]},{cN:"addition",b:"^\\+",e:"$"},{cN:"deletion",b:"^\\-",e:"$"},{cN:"change",b:"^\\!",e:"$"}]}});hljs.registerLanguage("javascript",function(a){return{aliases:["js"],k:{keyword:"in if for while finally var new function do return void else break catch instanceof with throw case default try this switch continue typeof delete let yield const class",literal:"true false null undefined NaN Infinity",built_in:"eval isFinite isNaN parseFloat parseInt decodeURI decodeURIComponent encodeURI encodeURIComponent escape unescape Object Function Boolean Error EvalError InternalError RangeError ReferenceError StopIteration SyntaxError TypeError URIError Number Math Date String RegExp Array Float32Array Float64Array Int16Array Int32Array Int8Array Uint16Array Uint32Array Uint8Array Uint8ClampedArray ArrayBuffer DataView JSON Intl arguments require"},c:[{cN:"pi",b:/^\s*('|")use strict('|")/,r:10},a.ASM,a.QSM,a.CLCM,a.CBLCLM,a.CNM,{b:"("+a.RSR+"|\\b(case|return|throw)\\b)\\s*",k:"return throw case",c:[a.CLCM,a.CBLCLM,a.REGEXP_MODE,{b:/,e:/>;/,r:0,sL:"xml"}],r:0},{cN:"function",bK:"function",e:/\{/,c:[a.inherit(a.TM,{b:/[A-Za-z$_][0-9A-Za-z$_]*/}),{cN:"params",b:/\(/,e:/\)/,c:[a.CLCM,a.CBLCLM],i:/["'\(]/}],i:/\[|%/},{b:/\$[(.]/},{b:"\\."+a.IR,r:0}]}});hljs.registerLanguage("xml",function(a){var c="[A-Za-z0-9\\._:-]+";var d={b:/<\?(php)?(?!\w)/,e:/\?>/,sL:"php",subLanguageMode:"continuous"};var b={eW:true,i:/,r:0,c:[d,{cN:"attribute",b:c,r:0},{b:"=",r:0,c:[{cN:"value",v:[{b:/"/,e:/"/},{b:/'/,e:/'/},{b:/[^\s\/>]+/}]}]}]};return{aliases:["html"],cI:true,c:[{cN:"doctype",b:"",r:10,c:[{b:"\\[",e:"\\]"}]},{cN:"comment",b:"",r:10},{cN:"cdata",b:"<\\!\\[CDATA\\[",e:"\\]\\]>",r:10},{cN:"tag",b:"",rE:true,sL:"css"}},{cN:"tag",b:"
+
+
+
+
+
+
+
+
+
+
+
+ This editor is using the Code Snippet plugin which introduces beautiful code snippets.
+ By default the codesnippet plugin depends on the built-in client-side syntax highlighting
+ library highlight.js.
+
+ Please note that this plugin is not compatible with Internet Explorer 8.
+
+
+
+
+
+
Inline editor
+
+
+
+ The following sample shows the Code Snippet plugin running inside
+ an inline CKEditor instance. The CKEditor instance below was created by using the following configuration settings:
+
+ Note: The highlight.js themes
+ must be loaded manually to be applied inside an inline editor instance, as the
+ codeSnippet_theme setting will not work in that case.
+ You need to include the stylesheet in the <head> section of the page, for example:
+
+
+
+
+
+
+
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/af.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/af.js
new file mode 100644
index 00000000..4ce214a9
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/af.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'af', {
+ options: 'Konteks Spyskaart-opsies'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/ar.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/ar.js
new file mode 100644
index 00000000..d4feef53
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/ar.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'ar', {
+ options: 'خصائص قائمة السياق'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/bg.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/bg.js
new file mode 100644
index 00000000..8292835e
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/bg.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'bg', {
+ options: 'Опции на контекстното меню'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/bn.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/bn.js
new file mode 100644
index 00000000..34627223
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/bn.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'bn', {
+ options: 'Context Menu Options' // MISSING
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/bs.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/bs.js
new file mode 100644
index 00000000..1f1c5d89
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/bs.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'bs', {
+ options: 'Context Menu Options' // MISSING
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/ca.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/ca.js
new file mode 100644
index 00000000..524bc0e6
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/ca.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'ca', {
+ options: 'Opcions del menú contextual'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/cs.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/cs.js
new file mode 100644
index 00000000..26482a27
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/cs.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'cs', {
+ options: 'Nastavení kontextové nabídky'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/cy.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/cy.js
new file mode 100644
index 00000000..cd543d32
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/cy.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'cy', {
+ options: 'Opsiynau Dewislen Cyd-destun'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/da.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/da.js
new file mode 100644
index 00000000..0e718914
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/da.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'da', {
+ options: 'Muligheder for hjælpemenu'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/de-ch.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/de-ch.js
new file mode 100644
index 00000000..d171be2b
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/de-ch.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'de-ch', {
+ options: 'Kontextmenüoptionen'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/de.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/de.js
new file mode 100644
index 00000000..0d59f050
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/de.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'de', {
+ options: 'Kontextmenüoptionen'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/el.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/el.js
new file mode 100644
index 00000000..ea7ceab2
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/el.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'el', {
+ options: 'Επιλογές Αναδυόμενου Μενού'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/en-au.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/en-au.js
new file mode 100644
index 00000000..dceb58b2
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/en-au.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'en-au', {
+ options: 'Context Menu Options' // MISSING
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/en-ca.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/en-ca.js
new file mode 100644
index 00000000..0ea37982
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/en-ca.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'en-ca', {
+ options: 'Context Menu Options' // MISSING
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/en-gb.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/en-gb.js
new file mode 100644
index 00000000..2eef537d
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/en-gb.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'en-gb', {
+ options: 'Context Menu Options'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/en.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/en.js
new file mode 100644
index 00000000..a52ba37e
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/en.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'en', {
+ options: 'Context Menu Options'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/eo.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/eo.js
new file mode 100644
index 00000000..f3625acf
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/eo.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'eo', {
+ options: 'Opcioj de Kunteksta Menuo'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/es.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/es.js
new file mode 100644
index 00000000..7e882461
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/es.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'es', {
+ options: 'Opciones del menú contextual'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/et.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/et.js
new file mode 100644
index 00000000..3285cc9f
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/et.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'et', {
+ options: 'Kontekstimenüü valikud'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/eu.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/eu.js
new file mode 100644
index 00000000..1f9fe921
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/eu.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'eu', {
+ options: 'Testuinguru-menuaren aukerak'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/fa.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/fa.js
new file mode 100644
index 00000000..636af2de
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/fa.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'fa', {
+ options: 'گزینههای منوی زمینه'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/fi.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/fi.js
new file mode 100644
index 00000000..9673b4c5
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/fi.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'fi', {
+ options: 'Pikavalikon ominaisuudet'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/fo.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/fo.js
new file mode 100644
index 00000000..12db3caa
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/fo.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'fo', {
+ options: 'Context Menu Options'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/fr-ca.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/fr-ca.js
new file mode 100644
index 00000000..d2ffc88f
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/fr-ca.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'fr-ca', {
+ options: 'Options du menu contextuel'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/fr.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/fr.js
new file mode 100644
index 00000000..117f01a1
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/fr.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'fr', {
+ options: 'Options du menu contextuel'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/gl.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/gl.js
new file mode 100644
index 00000000..df27cdef
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/gl.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'gl', {
+ options: 'Opcións do menú contextual'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/gu.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/gu.js
new file mode 100644
index 00000000..49a24acf
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/gu.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'gu', {
+ options: 'કોન્તેક્ષ્ત્ મેનુના વિકલ્પો'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/he.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/he.js
new file mode 100644
index 00000000..26e806ab
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/he.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'he', {
+ options: 'אפשרויות תפריט ההקשר'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/hi.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/hi.js
new file mode 100644
index 00000000..1b3a4f98
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/hi.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'hi', {
+ options: 'Context Menu Options' // MISSING
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/hr.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/hr.js
new file mode 100644
index 00000000..28c9cb9a
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/hr.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'hr', {
+ options: 'Opcije izbornika'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/hu.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/hu.js
new file mode 100644
index 00000000..bfb6b068
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/hu.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'hu', {
+ options: 'Helyi menü opciók'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/id.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/id.js
new file mode 100644
index 00000000..ce73be24
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/id.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'id', {
+ options: 'Opsi Konteks Pilihan'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/is.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/is.js
new file mode 100644
index 00000000..c6645ec6
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/is.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'is', {
+ options: 'Context Menu Options' // MISSING
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/it.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/it.js
new file mode 100644
index 00000000..d8a8ee05
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/it.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'it', {
+ options: 'Opzioni del menù contestuale'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/ja.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/ja.js
new file mode 100644
index 00000000..967f3747
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/ja.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'ja', {
+ options: 'コンテキストメニューオプション'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/ka.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/ka.js
new file mode 100644
index 00000000..c35e64d8
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/ka.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'ka', {
+ options: 'კონტექსტური მენიუს პარამეტრები'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/km.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/km.js
new file mode 100644
index 00000000..84868846
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/km.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'km', {
+ options: 'ជម្រើសម៉ឺនុយបរិបទ'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/ko.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/ko.js
new file mode 100644
index 00000000..b7d1c82f
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/ko.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'ko', {
+ options: '컨텍스트 메뉴 옵션'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/ku.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/ku.js
new file mode 100644
index 00000000..c8a35d0f
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/ku.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'ku', {
+ options: 'هەڵبژاردەی لیستەی کلیکی دەستی ڕاست'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/lt.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/lt.js
new file mode 100644
index 00000000..cb9cb8cd
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/lt.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'lt', {
+ options: 'Kontekstinio meniu parametrai'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/lv.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/lv.js
new file mode 100644
index 00000000..03645f82
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/lv.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'lv', {
+ options: 'Uznirstošās izvēlnes uzstādījumi'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/mk.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/mk.js
new file mode 100644
index 00000000..1e920a01
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/mk.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'mk', {
+ options: 'Контекст-мени опции'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/mn.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/mn.js
new file mode 100644
index 00000000..c4b0f2fa
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/mn.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'mn', {
+ options: 'Context Menu Options' // MISSING
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/ms.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/ms.js
new file mode 100644
index 00000000..381d0a35
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/ms.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'ms', {
+ options: 'Context Menu Options' // MISSING
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/nb.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/nb.js
new file mode 100644
index 00000000..f37fc4a2
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/nb.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'nb', {
+ options: 'Alternativer for høyreklikkmeny'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/nl.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/nl.js
new file mode 100644
index 00000000..84ce8271
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/nl.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'nl', {
+ options: 'Contextmenu opties'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/no.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/no.js
new file mode 100644
index 00000000..1f04ace1
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/no.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'no', {
+ options: 'Alternativer for høyreklikkmeny'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/pl.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/pl.js
new file mode 100644
index 00000000..0f2a902a
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/pl.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'pl', {
+ options: 'Opcje menu kontekstowego'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/pt-br.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/pt-br.js
new file mode 100644
index 00000000..23bb6cb0
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/pt-br.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'pt-br', {
+ options: 'Opções Menu de Contexto'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/pt.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/pt.js
new file mode 100644
index 00000000..a53100b5
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/pt.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'pt', {
+ options: 'Menu de opções de contexto'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/ro.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/ro.js
new file mode 100644
index 00000000..e6344374
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/ro.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'ro', {
+ options: 'Opțiuni Meniu Contextual'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/ru.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/ru.js
new file mode 100644
index 00000000..a308378b
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/ru.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'ru', {
+ options: 'Параметры контекстного меню'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/si.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/si.js
new file mode 100644
index 00000000..fed5c4b4
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/si.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'si', {
+ options: 'අනතර්ග ලේඛණ විකල්ප'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/sk.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/sk.js
new file mode 100644
index 00000000..766bd90a
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/sk.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'sk', {
+ options: 'Možnosti kontextového menu'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/sl.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/sl.js
new file mode 100644
index 00000000..9158e285
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/sl.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'sl', {
+ options: 'Možnosti kontekstnega menija'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/sq.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/sq.js
new file mode 100644
index 00000000..3076996b
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/sq.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'sq', {
+ options: 'Mundësitë e Menysë së Kontekstit'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/sr-latn.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/sr-latn.js
new file mode 100644
index 00000000..0359d8b9
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/sr-latn.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'sr-latn', {
+ options: 'Context Menu Options' // MISSING
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/sr.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/sr.js
new file mode 100644
index 00000000..d7805e1a
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/sr.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'sr', {
+ options: 'Context Menu Options' // MISSING
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/sv.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/sv.js
new file mode 100644
index 00000000..2502ee49
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/sv.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'sv', {
+ options: 'Context Menu Options'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/th.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/th.js
new file mode 100644
index 00000000..4b5bcce1
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/th.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'th', {
+ options: 'Context Menu Options' // MISSING
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/tr.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/tr.js
new file mode 100644
index 00000000..29a8d31e
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/tr.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'tr', {
+ options: 'İçerik Menüsü Seçenekleri'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/tt.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/tt.js
new file mode 100644
index 00000000..befd9345
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/tt.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'tt', {
+ options: 'Контекст меню үзлекләре'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/ug.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/ug.js
new file mode 100644
index 00000000..f1934aee
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/ug.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'ug', {
+ options: 'قىسقا يول تىزىملىك تاللانمىسى'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/uk.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/uk.js
new file mode 100644
index 00000000..d165225e
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/uk.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'uk', {
+ options: 'Опції контекстного меню'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/vi.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/vi.js
new file mode 100644
index 00000000..4ad18cab
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/vi.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'vi', {
+ options: 'Tùy chọn menu bổ xung'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/zh-cn.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/zh-cn.js
new file mode 100644
index 00000000..c9d93f5b
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/zh-cn.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'zh-cn', {
+ options: '快捷菜单选项'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/lang/zh.js b/assets/ckeditor-contrib/plugins/contextmenu/lang/zh.js
new file mode 100644
index 00000000..ce3e1cae
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/lang/zh.js
@@ -0,0 +1,7 @@
+/*
+Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.md or http://ckeditor.com/license
+*/
+CKEDITOR.plugins.setLang( 'contextmenu', 'zh', {
+ options: '內容功能表選項'
+} );
diff --git a/assets/ckeditor-contrib/plugins/contextmenu/plugin.js b/assets/ckeditor-contrib/plugins/contextmenu/plugin.js
new file mode 100644
index 00000000..06c2ec26
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/contextmenu/plugin.js
@@ -0,0 +1,159 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+CKEDITOR.plugins.add( 'contextmenu', {
+ requires: 'menu',
+
+ // jscs:disable maximumLineLength
+ lang: 'af,ar,bg,bn,bs,ca,cs,cy,da,de,de-ch,el,en,en-au,en-ca,en-gb,eo,es,et,eu,fa,fi,fo,fr,fr-ca,gl,gu,he,hi,hr,hu,id,is,it,ja,ka,km,ko,ku,lt,lv,mk,mn,ms,nb,nl,no,pl,pt,pt-br,ro,ru,si,sk,sl,sq,sr,sr-latn,sv,th,tr,tt,ug,uk,vi,zh,zh-cn', // %REMOVE_LINE_CORE%
+ // jscs:enable maximumLineLength
+
+ // Make sure the base class (CKEDITOR.menu) is loaded before it (#3318).
+ onLoad: function() {
+ /**
+ * Class replacing the non-configurable native context menu with a configurable CKEditor's equivalent.
+ *
+ * @class
+ * @extends CKEDITOR.menu
+ */
+ CKEDITOR.plugins.contextMenu = CKEDITOR.tools.createClass( {
+ base: CKEDITOR.menu,
+
+ /**
+ * Creates the CKEDITOR.plugins.contextMenu class instance.
+ *
+ * @constructor
+ * @param {CKEDITOR.editor} editor
+ */
+ $: function( editor ) {
+ this.base.call( this, editor, {
+ panel: {
+ className: 'cke_menu_panel',
+ attributes: {
+ 'aria-label': editor.lang.contextmenu.options
+ }
+ }
+ } );
+ },
+
+ proto: {
+ /**
+ * Starts watching on native context menu triggers (Option key, right click) on the given element.
+ *
+ * @param {CKEDITOR.dom.element} element
+ * @param {Boolean} [nativeContextMenuOnCtrl] Whether to open native context menu if the
+ * Ctrl key is held on opening the context menu. See {@link CKEDITOR.config#browserContextMenuOnCtrl}.
+ */
+ addTarget: function( element, nativeContextMenuOnCtrl ) {
+ element.on( 'contextmenu', function( event ) {
+ var domEvent = event.data,
+ isCtrlKeyDown =
+ // Safari on Windows always show 'ctrlKey' as true in 'contextmenu' event,
+ // which make this property unreliable. (#4826)
+ ( CKEDITOR.env.webkit ? holdCtrlKey : ( CKEDITOR.env.mac ? domEvent.$.metaKey : domEvent.$.ctrlKey ) );
+
+ if ( nativeContextMenuOnCtrl && isCtrlKeyDown )
+ return;
+
+ // Cancel the browser context menu.
+ domEvent.preventDefault();
+
+ // Fix selection when non-editable element in Webkit/Blink (Mac) (#11306).
+ if ( CKEDITOR.env.mac && CKEDITOR.env.webkit ) {
+ var editor = this.editor,
+ contentEditableParent = new CKEDITOR.dom.elementPath( domEvent.getTarget(), editor.editable() ).contains( function( el ) {
+ // Return when non-editable or nested editable element is found.
+ return el.hasAttribute( 'contenteditable' );
+ }, true ); // Exclude editor's editable.
+
+ // Fake selection for non-editables only (to exclude nested editables).
+ if ( contentEditableParent && contentEditableParent.getAttribute( 'contenteditable' ) == 'false' )
+ editor.getSelection().fake( contentEditableParent );
+ }
+
+ var doc = domEvent.getTarget().getDocument(),
+ offsetParent = domEvent.getTarget().getDocument().getDocumentElement(),
+ fromFrame = !doc.equals( CKEDITOR.document ),
+ scroll = doc.getWindow().getScrollPosition(),
+ offsetX = fromFrame ? domEvent.$.clientX : domEvent.$.pageX || scroll.x + domEvent.$.clientX,
+ offsetY = fromFrame ? domEvent.$.clientY : domEvent.$.pageY || scroll.y + domEvent.$.clientY;
+
+ CKEDITOR.tools.setTimeout( function() {
+ this.open( offsetParent, null, offsetX, offsetY );
+
+ // IE needs a short while to allow selection change before opening menu. (#7908)
+ }, CKEDITOR.env.ie ? 200 : 0, this );
+ }, this );
+
+ if ( CKEDITOR.env.webkit ) {
+ var holdCtrlKey,
+ onKeyDown = function( event ) {
+ holdCtrlKey = CKEDITOR.env.mac ? event.data.$.metaKey : event.data.$.ctrlKey;
+ },
+ resetOnKeyUp = function() {
+ holdCtrlKey = 0;
+ };
+
+ element.on( 'keydown', onKeyDown );
+ element.on( 'keyup', resetOnKeyUp );
+ element.on( 'contextmenu', resetOnKeyUp );
+ }
+ },
+
+ /**
+ * Opens the context menu in the given location. See the {@link CKEDITOR.menu#show} method.
+ *
+ * @param {CKEDITOR.dom.element} offsetParent
+ * @param {Number} [corner]
+ * @param {Number} [offsetX]
+ * @param {Number} [offsetY]
+ */
+ open: function( offsetParent, corner, offsetX, offsetY ) {
+ this.editor.focus();
+ offsetParent = offsetParent || CKEDITOR.document.getDocumentElement();
+
+ // #9362: Force selection check to update commands' states in the new context.
+ this.editor.selectionChange( 1 );
+
+ this.show( offsetParent, corner, offsetX, offsetY );
+ }
+ }
+ } );
+ },
+
+ beforeInit: function( editor ) {
+ /**
+ * @readonly
+ * @property {CKEDITOR.plugins.contextMenu} contextMenu
+ * @member CKEDITOR.editor
+ */
+ var contextMenu = editor.contextMenu = new CKEDITOR.plugins.contextMenu( editor );
+
+ editor.on( 'contentDom', function() {
+ contextMenu.addTarget( editor.editable(), editor.config.browserContextMenuOnCtrl !== false );
+ } );
+
+ editor.addCommand( 'contextMenu', {
+ exec: function() {
+ editor.contextMenu.open( editor.document.getBody() );
+ }
+ } );
+
+ editor.setKeystroke( CKEDITOR.SHIFT + 121 /*F10*/, 'contextMenu' );
+ editor.setKeystroke( CKEDITOR.CTRL + CKEDITOR.SHIFT + 121 /*F10*/, 'contextMenu' );
+ }
+} );
+
+/**
+ * Whether to show the browser native context menu when the Ctrl or
+ * Meta (Mac) key is pressed on opening the context menu with the
+ * right mouse button click or the Menu key.
+ *
+ * config.browserContextMenuOnCtrl = false;
+ *
+ * @since 3.0.2
+ * @cfg {Boolean} [browserContextMenuOnCtrl=true]
+ * @member CKEDITOR.config
+ */
diff --git a/assets/ckeditor-contrib/plugins/dialog/dialogDefinition.js b/assets/ckeditor-contrib/plugins/dialog/dialogDefinition.js
new file mode 100644
index 00000000..ded0464b
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/dialog/dialogDefinition.js
@@ -0,0 +1,1032 @@
+// jscs:disable disallowMixedSpacesAndTabs
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+/**
+ * @fileOverview Defines the "virtual" dialog, dialog content and dialog button
+ * definition classes.
+ */
+
+/**
+ * The definition of a dialog window.
+ *
+ * This class is not really part of the API. It just illustrates the properties
+ * that developers can use to define and create dialogs.
+ *
+ * // There is no constructor for this class, the user just has to define an
+ * // object with the appropriate properties.
+ *
+ * CKEDITOR.dialog.add( 'testOnly', function( editor ) {
+ * return {
+ * title: 'Test Dialog',
+ * resizable: CKEDITOR.DIALOG_RESIZE_BOTH,
+ * minWidth: 500,
+ * minHeight: 400,
+ * contents: [
+ * {
+ * id: 'tab1',
+ * label: 'First Tab',
+ * title: 'First Tab Title',
+ * accessKey: 'Q',
+ * elements: [
+ * {
+ * type: 'text',
+ * label: 'Test Text 1',
+ * id: 'testText1',
+ * 'default': 'hello world!'
+ * }
+ * ]
+ * }
+ * ]
+ * };
+ * } );
+ *
+ * @class CKEDITOR.dialog.definition
+ */
+
+/**
+ * The dialog title, displayed in the dialog's header. Required.
+ *
+ * @property {String} title
+ */
+
+/**
+ * How the dialog can be resized, must be one of the four contents defined below.
+ *
+ * * {@link CKEDITOR#DIALOG_RESIZE_NONE}
+ * * {@link CKEDITOR#DIALOG_RESIZE_WIDTH}
+ * * {@link CKEDITOR#DIALOG_RESIZE_HEIGHT}
+ * * {@link CKEDITOR#DIALOG_RESIZE_BOTH}
+ *
+ * @property {Number} [resizable=CKEDITOR.DIALOG_RESIZE_NONE]
+ */
+
+/**
+ * The minimum width of the dialog, in pixels.
+ *
+ * @property {Number} [minWidth=600]
+ */
+
+/**
+ * The minimum height of the dialog, in pixels.
+ *
+ * @property {Number} [minHeight=400]
+ */
+
+
+/**
+ * The initial width of the dialog, in pixels.
+ *
+ * @since 3.5.3
+ * @property {Number} [width=CKEDITOR.dialog.definition#minWidth]
+ */
+
+/**
+ * The initial height of the dialog, in pixels.
+ *
+ * @since 3.5.3
+ * @property {Number} [height=CKEDITOR.dialog.definition.minHeight]
+ */
+
+/**
+ * The buttons in the dialog, defined as an array of
+ * {@link CKEDITOR.dialog.definition.button} objects.
+ *
+ * @property {Array} [buttons=[ CKEDITOR.dialog.okButton, CKEDITOR.dialog.cancelButton ]]
+ */
+
+/**
+ * The contents in the dialog, defined as an array of
+ * {@link CKEDITOR.dialog.definition.content} objects. Required.
+ *
+ * @property {Array} contents
+ */
+
+/**
+ * The function to execute when OK is pressed.
+ *
+ * @property {Function} onOk
+ */
+
+/**
+ * The function to execute when Cancel is pressed.
+ *
+ * @property {Function} onCancel
+ */
+
+/**
+ * The function to execute when the dialog is displayed for the first time.
+ *
+ * @property {Function} onLoad
+ */
+
+/**
+ * The function to execute when the dialog is loaded (executed every time the dialog is opened).
+ *
+ * @property {Function} onShow
+ */
+
+/**
+ * This class is not really part of the API. It just illustrates the properties
+ * that developers can use to define and create dialog content pages.
+ *
+ * @class CKEDITOR.dialog.definition.content.
+ */
+
+/**
+ * The id of the content page.
+ *
+ * @property {String} id
+ */
+
+/**
+ * The tab label of the content page.
+ *
+ * @property {String} label
+ */
+
+/**
+ * The popup message of the tab label.
+ *
+ * @property {String} title
+ */
+
+/**
+ * The CTRL hotkey for switching to the tab.
+ *
+ * contentDefinition.accessKey = 'Q'; // Switch to this page when CTRL-Q is pressed.
+ *
+ * @property {String} accessKey
+ */
+
+/**
+ * The UI elements contained in this content page, defined as an array of
+ * {@link CKEDITOR.dialog.definition.uiElement} objects.
+ *
+ * @property {Array} elements
+ */
+
+/**
+ * The definition of user interface element (textarea, radio etc).
+ *
+ * This class is not really part of the API. It just illustrates the properties
+ * that developers can use to define and create dialog UI elements.
+ *
+ * @class CKEDITOR.dialog.definition.uiElement
+ * @see CKEDITOR.ui.dialog.uiElement
+ */
+
+/**
+ * The id of the UI element.
+ *
+ * @property {String} id
+ */
+
+/**
+ * The type of the UI element. Required.
+ *
+ * @property {String} type
+ */
+
+/**
+ * The popup label of the UI element.
+ *
+ * @property {String} title
+ */
+
+/**
+ * The content that needs to be allowed to enable this UI element.
+ * All formats accepted by {@link CKEDITOR.filter#check} may be used.
+ *
+ * When all UI elements in a tab are disabled, this tab will be disabled automatically.
+ *
+ * @property {String/Object/CKEDITOR.style} requiredContent
+ */
+
+/**
+ * CSS class names to append to the UI element.
+ *
+ * @property {String} className
+ */
+
+/**
+ * Inline CSS classes to append to the UI element.
+ *
+ * @property {String} style
+ */
+
+/**
+ * Horizontal alignment (in container) of the UI element.
+ *
+ * @property {String} align
+ */
+
+/**
+ * Function to execute the first time the UI element is displayed.
+ *
+ * @property {Function} onLoad
+ */
+
+/**
+ * Function to execute whenever the UI element's parent dialog is displayed.
+ *
+ * @property {Function} onShow
+ */
+
+/**
+ * Function to execute whenever the UI element's parent dialog is closed.
+ *
+ * @property {Function} onHide
+ */
+
+/**
+ * Function to execute whenever the UI element's parent
+ * dialog's {@link CKEDITOR.dialog#setupContent} method is executed.
+ * It usually takes care of the respective UI element as a standalone element.
+ *
+ * @property {Function} setup
+ */
+
+/**
+ * Function to execute whenever the UI element's parent
+ * dialog's {@link CKEDITOR.dialog#commitContent} method is executed.
+ * It usually takes care of the respective UI element as a standalone element.
+ *
+ * @property {Function} commit
+ */
+
+// ----- hbox -----------------------------------------------------------------
+
+/**
+ * Horizontal layout box for dialog UI elements, auto-expends to available width of container.
+ *
+ * This class is not really part of the API. It just illustrates the properties
+ * that developers can use to define and create horizontal layouts.
+ *
+ * Once the dialog is opened, the created element becomes a {@link CKEDITOR.ui.dialog.hbox} object and can be accessed with {@link CKEDITOR.dialog#getContentElement}.
+ *
+ * // There is no constructor for this class, the user just has to define an
+ * // object with the appropriate properties.
+ *
+ * // Example:
+ * {
+ * type: 'hbox',
+ * widths: [ '25%', '25%', '50%' ],
+ * children: [
+ * {
+ * type: 'text',
+ * id: 'id1',
+ * width: '40px',
+ * },
+ * {
+ * type: 'text',
+ * id: 'id2',
+ * width: '40px',
+ * },
+ * {
+ * type: 'text',
+ * id: 'id3'
+ * }
+ * ]
+ * }
+ *
+ * @class CKEDITOR.dialog.definition.hbox
+ * @extends CKEDITOR.dialog.definition.uiElement
+ */
+
+/**
+ * Array of {@link CKEDITOR.ui.dialog.uiElement} objects inside this container.
+ *
+ * @property {Array} children
+ */
+
+/**
+ * (Optional) The widths of child cells.
+ *
+ * @property {Array} widths
+ */
+
+/**
+ * (Optional) The height of the layout.
+ *
+ * @property {Number} height
+ */
+
+/**
+ * The CSS styles to apply to this element.
+ *
+ * @property {String} styles
+ */
+
+/**
+ * (Optional) The padding width inside child cells. Example: 0, 1.
+ *
+ * @property {Number} padding
+ */
+
+/**
+ * (Optional) The alignment of the whole layout. Example: center, top.
+ *
+ * @property {String} align
+ */
+
+// ----- vbox -----------------------------------------------------------------
+
+/**
+ * Vertical layout box for dialog UI elements.
+ *
+ * This class is not really part of the API. It just illustrates the properties
+ * that developers can use to define and create vertical layouts.
+ *
+ * Once the dialog is opened, the created element becomes a {@link CKEDITOR.ui.dialog.vbox} object and can
+ * be accessed with {@link CKEDITOR.dialog#getContentElement}.
+ *
+ * // There is no constructor for this class, the user just has to define an
+ * // object with the appropriate properties.
+ *
+ * // Example:
+ * {
+ * type: 'vbox',
+ * align: 'right',
+ * width: '200px',
+ * children: [
+ * {
+ * type: 'text',
+ * id: 'age',
+ * label: 'Age'
+ * },
+ * {
+ * type: 'text',
+ * id: 'sex',
+ * label: 'Sex'
+ * },
+ * {
+ * type: 'text',
+ * id: 'nationality',
+ * label: 'Nationality'
+ * }
+ * ]
+ * }
+ *
+ * @class CKEDITOR.dialog.definition.vbox
+ * @extends CKEDITOR.dialog.definition.uiElement
+ */
+
+/**
+ * Array of {@link CKEDITOR.ui.dialog.uiElement} objects inside this container.
+ *
+ * @property {Array} children
+ */
+
+/**
+ * (Optional) The width of the layout.
+ *
+ * @property {Array} width
+ */
+
+/**
+ * (Optional) The heights of individual cells.
+ *
+ * @property {Number} heights
+ */
+
+/**
+ * The CSS styles to apply to this element.
+ *
+ * @property {String} styles
+ */
+
+/**
+ * (Optional) The padding width inside child cells. Example: 0, 1.
+ *
+ * @property {Number} padding
+ */
+
+/**
+ * (Optional) The alignment of the whole layout. Example: center, top.
+ *
+ * @property {String} align
+ */
+
+/**
+ * (Optional) Whether the layout should expand vertically to fill its container.
+ *
+ * @property {Boolean} expand
+ */
+
+// ----- labeled element ------------------------------------------------------
+
+/**
+ * The definition of labeled user interface element (textarea, textInput etc).
+ *
+ * This class is not really part of the API. It just illustrates the properties
+ * that developers can use to define and create dialog UI elements.
+ *
+ * @class CKEDITOR.dialog.definition.labeledElement
+ * @extends CKEDITOR.dialog.definition.uiElement
+ * @see CKEDITOR.ui.dialog.labeledElement
+ */
+
+/**
+ * The label of the UI element.
+ *
+ * {
+ * type: 'text',
+ * label: 'My Label'
+ * }
+ *
+ * @property {String} label
+ */
+
+/**
+ * (Optional) Specify the layout of the label. Set to `'horizontal'` for horizontal layout.
+ * The default layout is vertical.
+ *
+ * {
+ * type: 'text',
+ * label: 'My Label',
+ * labelLayout: 'horizontal'
+ * }
+ *
+ * @property {String} labelLayout
+ */
+
+/**
+ * (Optional) Applies only to horizontal layouts: a two elements array of lengths to specify the widths of the
+ * label and the content element. See also {@link CKEDITOR.dialog.definition.labeledElement#labelLayout}.
+ *
+ * {
+ * type: 'text',
+ * label: 'My Label',
+ * labelLayout: 'horizontal',
+ * widths: [100, 200]
+ * }
+ *
+ * @property {Array} widths
+ */
+
+/**
+ * Specify the inline style of the uiElement label.
+ *
+ * {
+ * type: 'text',
+ * label: 'My Label',
+ * labelStyle: 'color: red'
+ * }
+ *
+ * @property {String} labelStyle
+ */
+
+
+/**
+ * Specify the inline style of the input element.
+ *
+ * {
+ * type: 'text',
+ * label: 'My Label',
+ * inputStyle: 'text-align: center'
+ * }
+ *
+ * @since 3.6.1
+ * @property {String} inputStyle
+ */
+
+/**
+ * Specify the inline style of the input element container.
+ *
+ * {
+ * type: 'text',
+ * label: 'My Label',
+ * controlStyle: 'width: 3em'
+ * }
+ *
+ * @since 3.6.1
+ * @property {String} controlStyle
+ */
+
+// ----- button ---------------------------------------------------------------
+
+/**
+ * The definition of a button.
+ *
+ * This class is not really part of the API. It just illustrates the properties
+ * that developers can use to define and create buttons.
+ *
+ * Once the dialog is opened, the created element becomes a {@link CKEDITOR.ui.dialog.button} object
+ * and can be accessed with {@link CKEDITOR.dialog#getContentElement}.
+ *
+ * For a complete example of dialog definition, please check {@link CKEDITOR.dialog#add}.
+ *
+ * // There is no constructor for this class, the user just has to define an
+ * // object with the appropriate properties.
+ *
+ * // Example:
+ * {
+ * type: 'button',
+ * id: 'buttonId',
+ * label: 'Click me',
+ * title: 'My title',
+ * onClick: function() {
+ * // this = CKEDITOR.ui.dialog.button
+ * alert( 'Clicked: ' + this.id );
+ * }
+ * }
+ *
+ * @class CKEDITOR.dialog.definition.button
+ * @extends CKEDITOR.dialog.definition.uiElement
+ */
+
+/**
+ * Whether the button is disabled.
+ *
+ * @property {Boolean} disabled
+ */
+
+/**
+ * The label of the UI element.
+ *
+ * @property {String} label
+ */
+
+// ----- checkbox ------
+/**
+ * The definition of a checkbox element.
+ *
+ * This class is not really part of the API. It just illustrates the properties
+ * that developers can use to define and create groups of checkbox buttons.
+ *
+ * Once the dialog is opened, the created element becomes a {@link CKEDITOR.ui.dialog.checkbox} object
+ * and can be accessed with {@link CKEDITOR.dialog#getContentElement}.
+ *
+ * For a complete example of dialog definition, please check {@link CKEDITOR.dialog#add}.
+ *
+ * // There is no constructor for this class, the user just has to define an
+ * // object with the appropriate properties.
+ *
+ * // Example:
+ * {
+ * type: 'checkbox',
+ * id: 'agree',
+ * label: 'I agree',
+ * 'default': 'checked',
+ * onClick: function() {
+ * // this = CKEDITOR.ui.dialog.checkbox
+ * alert( 'Checked: ' + this.getValue() );
+ * }
+ * }
+ *
+ * @class CKEDITOR.dialog.definition.checkbox
+ * @extends CKEDITOR.dialog.definition.uiElement
+ */
+
+/**
+ * (Optional) The validation function.
+ *
+ * @property {Function} validate
+ */
+
+/**
+ * The label of the UI element.
+ *
+ * @property {String} label
+ */
+
+/**
+ * The default state.
+ *
+ * @property {String} [default='' (unchecked)]
+ */
+
+// ----- file -----------------------------------------------------------------
+
+/**
+ * The definition of a file upload input.
+ *
+ * This class is not really part of the API. It just illustrates the properties
+ * that developers can use to define and create file upload elements.
+ *
+ * Once the dialog is opened, the created element becomes a {@link CKEDITOR.ui.dialog.file} object
+ * and can be accessed with {@link CKEDITOR.dialog#getContentElement}.
+ *
+ * For a complete example of dialog definition, please check {@link CKEDITOR.dialog#add}.
+ *
+ * // There is no constructor for this class, the user just has to define an
+ * // object with the appropriate properties.
+ *
+ * // Example:
+ * {
+ * type: 'file',
+ * id: 'upload',
+ * label: 'Select file from your computer',
+ * size: 38
+ * },
+ * {
+ * type: 'fileButton',
+ * id: 'fileId',
+ * label: 'Upload file',
+ * 'for': [ 'tab1', 'upload' ],
+ * filebrowser: {
+ * onSelect: function( fileUrl, data ) {
+ * alert( 'Successfully uploaded: ' + fileUrl );
+ * }
+ * }
+ * }
+ *
+ * @class CKEDITOR.dialog.definition.file
+ * @extends CKEDITOR.dialog.definition.labeledElement
+ */
+
+/**
+ * (Optional) The validation function.
+ *
+ * @property {Function} validate
+ */
+
+/**
+ * (Optional) The action attribute of the form element associated with this file upload input.
+ * If empty, CKEditor will use path to server connector for currently opened folder.
+ *
+ * @property {String} action
+ */
+
+/**
+ * The size of the UI element.
+ *
+ * @property {Number} size
+ */
+
+// ----- fileButton -----------------------------------------------------------
+
+/**
+ * The definition of a button for submitting the file in a file upload input.
+ *
+ * This class is not really part of the API. It just illustrates the properties
+ * that developers can use to define and create a button for submitting the file in a file upload input.
+ *
+ * Once the dialog is opened, the created element becomes a {@link CKEDITOR.ui.dialog.fileButton} object
+ * and can be accessed with {@link CKEDITOR.dialog#getContentElement}.
+ *
+ * For a complete example of dialog definition, please check {@link CKEDITOR.dialog#add}.
+ *
+ * @class CKEDITOR.dialog.definition.fileButton
+ * @extends CKEDITOR.dialog.definition.uiElement
+ */
+
+/**
+ * (Optional) The validation function.
+ *
+ * @property {Function} validate
+ */
+
+/**
+ * The label of the UI element.
+ *
+ * @property {String} label
+ */
+
+/**
+ * The instruction for CKEditor how to deal with file upload.
+ * By default, the file and fileButton elements will not work "as expected" if this attribute is not set.
+ *
+ * // Update field with id 'txtUrl' in the 'tab1' tab when file is uploaded.
+ * filebrowser: 'tab1:txtUrl'
+ *
+ * // Call custom onSelect function when file is successfully uploaded.
+ * filebrowser: {
+ * onSelect: function( fileUrl, data ) {
+ * alert( 'Successfully uploaded: ' + fileUrl );
+ * }
+ * }
+ *
+ * @property {String} filebrowser/Object
+ */
+
+/**
+ * An array that contains pageId and elementId of the file upload input element for which this button is created.
+ *
+ * [ pageId, elementId ]
+ *
+ * @property {String} for
+ */
+
+// ----- html -----------------------------------------------------------------
+
+/**
+ * The definition of a raw HTML element.
+ *
+ * This class is not really part of the API. It just illustrates the properties
+ * that developers can use to define and create elements made from raw HTML code.
+ *
+ * Once the dialog is opened, the created element becomes a {@link CKEDITOR.ui.dialog.html} object
+ * and can be accessed with {@link CKEDITOR.dialog#getContentElement}.
+ *
+ * For a complete example of dialog definition, please check {@link CKEDITOR.dialog#add}.
+ * To access HTML elements use {@link CKEDITOR.dom.document#getById}.
+ *
+ * // There is no constructor for this class, the user just has to define an
+ * // object with the appropriate properties.
+ *
+ * // Example 1:
+ * {
+ * type: 'html',
+ * html: '
This is some sample HTML content.
'
+ * }
+ *
+ * // Example 2:
+ * // Complete sample with document.getById() call when the "Ok" button is clicked.
+ * var dialogDefinition = {
+ * title: 'Sample dialog',
+ * minWidth: 300,
+ * minHeight: 200,
+ * onOk: function() {
+ * // "this" is now a CKEDITOR.dialog object.
+ * var document = this.getElement().getDocument();
+ * // document = CKEDITOR.dom.document
+ * var element = document.getById( 'myDiv' );
+ * if ( element )
+ * alert( element.getHtml() );
+ * },
+ * contents: [
+ * {
+ * id: 'tab1',
+ * label: '',
+ * title: '',
+ * elements: [
+ * {
+ * type: 'html',
+ * html: '
Sample text.
Another div.
'
+ * }
+ * ]
+ * }
+ * ],
+ * buttons: [ CKEDITOR.dialog.cancelButton, CKEDITOR.dialog.okButton ]
+ * };
+ *
+ * @class CKEDITOR.dialog.definition.html
+ * @extends CKEDITOR.dialog.definition.uiElement
+ */
+
+/**
+ * (Required) HTML code of this element.
+ *
+ * @property {String} html
+ */
+
+// ----- radio ----------------------------------------------------------------
+
+/**
+ * The definition of a radio group.
+ *
+ * This class is not really part of the API. It just illustrates the properties
+ * that developers can use to define and create groups of radio buttons.
+ *
+ * Once the dialog is opened, the created element becomes a {@link CKEDITOR.ui.dialog.radio} object
+ * and can be accessed with {@link CKEDITOR.dialog#getContentElement}.
+ *
+ * For a complete example of dialog definition, please check {@link CKEDITOR.dialog#add}.
+ *
+ * // There is no constructor for this class, the user just has to define an
+ * // object with the appropriate properties.
+ *
+ * // Example:
+ * {
+ * type: 'radio',
+ * id: 'country',
+ * label: 'Which country is bigger',
+ * items: [ [ 'France', 'FR' ], [ 'Germany', 'DE' ] ],
+ * style: 'color: green',
+ * 'default': 'DE',
+ * onClick: function() {
+ * // this = CKEDITOR.ui.dialog.radio
+ * alert( 'Current value: ' + this.getValue() );
+ * }
+ * }
+ *
+ * @class CKEDITOR.dialog.definition.radio
+ * @extends CKEDITOR.dialog.definition.labeledElement
+ */
+
+/**
+ * The default value.
+ *
+ * @property {String} default
+ */
+
+/**
+ * (Optional) The validation function.
+ *
+ * @property {Function} validate
+ */
+
+/**
+ * An array of options. Each option is a 1- or 2-item array of format `[ 'Description', 'Value' ]`.
+ * If `'Value'` is missing, then the value would be assumed to be the same as the description.
+ *
+ * @property {Array} items
+ */
+
+// ----- selectElement --------------------------------------------------------
+
+/**
+ * The definition of a select element.
+ *
+ * This class is not really part of the API. It just illustrates the properties
+ * that developers can use to define and create select elements.
+ *
+ * Once the dialog is opened, the created element becomes a {@link CKEDITOR.ui.dialog.select} object
+ * and can be accessed with {@link CKEDITOR.dialog#getContentElement}.
+ *
+ * For a complete example of dialog definition, please check {@link CKEDITOR.dialog#add}.
+ *
+ * // There is no constructor for this class, the user just has to define an
+ * // object with the appropriate properties.
+ *
+ * // Example:
+ * {
+ * type: 'select',
+ * id: 'sport',
+ * label: 'Select your favourite sport',
+ * items: [ [ 'Basketball' ], [ 'Baseball' ], [ 'Hockey' ], [ 'Football' ] ],
+ * 'default': 'Football',
+ * onChange: function( api ) {
+ * // this = CKEDITOR.ui.dialog.select
+ * alert( 'Current value: ' + this.getValue() );
+ * }
+ * }
+ *
+ * @class CKEDITOR.dialog.definition.select
+ * @extends CKEDITOR.dialog.definition.labeledElement
+ */
+
+/**
+ * The default value.
+ *
+ * @property {String} default
+ */
+
+/**
+ * (Optional) The validation function.
+ *
+ * @property {Function} validate
+ */
+
+/**
+ * An array of options. Each option is a 1- or 2-item array of format `[ 'Description', 'Value' ]`.
+ * If `'Value'` is missing, then the value would be assumed to be the same as the description.
+ *
+ * @property {Array} items
+ */
+
+/**
+ * (Optional) Set this to true if you'd like to have a multiple-choice select box.
+ *
+ * @property {Boolean} [multiple=false]
+ */
+
+/**
+ * (Optional) The number of items to display in the select box.
+ *
+ * @property {Number} size
+ */
+
+// ----- textInput ------------------------------------------------------------
+
+/**
+ * The definition of a text field (single line).
+ *
+ * This class is not really part of the API. It just illustrates the properties
+ * that developers can use to define and create text fields.
+ *
+ * Once the dialog is opened, the created element becomes a {@link CKEDITOR.ui.dialog.textInput} object
+ * and can be accessed with {@link CKEDITOR.dialog#getContentElement}.
+ *
+ * For a complete example of dialog definition, please check {@link CKEDITOR.dialog#add}.
+ *
+ * // There is no constructor for this class, the user just has to define an
+ * // object with the appropriate properties.
+ *
+ * {
+ * type: 'text',
+ * id: 'name',
+ * label: 'Your name',
+ * 'default': '',
+ * validate: function() {
+ * if ( !this.getValue() ) {
+ * api.openMsgDialog( '', 'Name cannot be empty.' );
+ * return false;
+ * }
+ * }
+ * }
+ *
+ * @class CKEDITOR.dialog.definition.textInput
+ * @extends CKEDITOR.dialog.definition.labeledElement
+ */
+
+/**
+ * The default value.
+ *
+ * @property {String} default
+ */
+
+/**
+ * (Optional) The maximum length.
+ *
+ * @property {Number} maxLength
+ */
+
+/**
+ * (Optional) The size of the input field.
+ *
+ * @property {Number} size
+ */
+
+/**
+ * (Optional) The validation function.
+ *
+ * @property {Function} validate
+ */
+
+/**
+ * @property bidi
+ * @inheritdoc CKEDITOR.dialog.definition.textarea#bidi
+ */
+
+// ----- textarea -------------------------------------------------------------
+
+/**
+ * The definition of a text field (multiple lines).
+ *
+ * This class is not really part of the API. It just illustrates the properties
+ * that developers can use to define and create textarea.
+ *
+ * Once the dialog is opened, the created element becomes a {@link CKEDITOR.ui.dialog.textarea} object
+ * and can be accessed with {@link CKEDITOR.dialog#getContentElement}.
+ *
+ * For a complete example of dialog definition, please check {@link CKEDITOR.dialog#add}.
+ *
+* // There is no constructor for this class, the user just has to define an
+* // object with the appropriate properties.
+*
+* // Example:
+* {
+* type: 'textarea',
+* id: 'message',
+* label: 'Your comment',
+* 'default': '',
+* validate: function() {
+* if ( this.getValue().length < 5 ) {
+* api.openMsgDialog( 'The comment is too short.' );
+* return false;
+* }
+* }
+* }
+ *
+ * @class CKEDITOR.dialog.definition.textarea
+ * @extends CKEDITOR.dialog.definition.labeledElement
+ */
+
+/**
+ * The number of rows.
+ *
+ * @property {Number} rows
+ */
+
+/**
+ * The number of columns.
+ *
+ * @property {Number} cols
+ */
+
+/**
+ * (Optional) The validation function.
+ *
+ * @property {Function} validate
+ */
+
+/**
+ * The default value.
+ *
+ * @property {String} default
+ */
+
+/**
+ * Whether the text direction of this input should be togglable using the following keystrokes:
+ *
+ * * *Shift+Alt+End* – switch to Right-To-Left,
+ * * *Shift+Alt+Home* – switch to Left-To-Right.
+ *
+ * By default the input will be loaded without any text direction set, which means that
+ * the direction will be inherited from the editor's text direction.
+ *
+ * If the direction was set, a marker will be prepended to every non-empty value of this input:
+ *
+ * * [`\u202A`](http://unicode.org/cldr/utility/character.jsp?a=202A) – for Right-To-Left,
+ * * [`\u202B`](http://unicode.org/cldr/utility/character.jsp?a=202B) – for Left-To-Right.
+ *
+ * This marker allows for restoring the same text direction upon the next dialog opening.
+ *
+ * @since 4.5
+ * @property {Boolean} bidi
+ */
diff --git a/assets/ckeditor-contrib/plugins/dialog/plugin.js b/assets/ckeditor-contrib/plugins/dialog/plugin.js
new file mode 100644
index 00000000..eb2e85e5
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/dialog/plugin.js
@@ -0,0 +1,3398 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+/**
+ * @fileOverview The floating dialog plugin.
+ */
+
+/**
+ * No resize for this dialog.
+ *
+ * @readonly
+ * @property {Number} [=0]
+ * @member CKEDITOR
+ */
+CKEDITOR.DIALOG_RESIZE_NONE = 0;
+
+/**
+ * Only allow horizontal resizing for this dialog, disable vertical resizing.
+ *
+ * @readonly
+ * @property {Number} [=1]
+ * @member CKEDITOR
+ */
+CKEDITOR.DIALOG_RESIZE_WIDTH = 1;
+
+/**
+ * Only allow vertical resizing for this dialog, disable horizontal resizing.
+ *
+ * @readonly
+ * @property {Number} [=2]
+ * @member CKEDITOR
+ */
+CKEDITOR.DIALOG_RESIZE_HEIGHT = 2;
+
+/**
+ * Allow the dialog to be resized in both directions.
+ *
+ * @readonly
+ * @property {Number} [=3]
+ * @member CKEDITOR
+ */
+CKEDITOR.DIALOG_RESIZE_BOTH = 3;
+
+/**
+ * Dialog state when idle.
+ *
+ * @readonly
+ * @property {Number} [=1]
+ * @member CKEDITOR
+ */
+CKEDITOR.DIALOG_STATE_IDLE = 1;
+
+/**
+ * Dialog state when busy.
+ *
+ * @readonly
+ * @property {Number} [=2]
+ * @member CKEDITOR
+ */
+CKEDITOR.DIALOG_STATE_BUSY = 2;
+
+( function() {
+ var cssLength = CKEDITOR.tools.cssLength;
+
+ function isTabVisible( tabId ) {
+ return !!this._.tabs[ tabId ][ 0 ].$.offsetHeight;
+ }
+
+ function getPreviousVisibleTab() {
+ var tabId = this._.currentTabId,
+ length = this._.tabIdList.length,
+ tabIndex = CKEDITOR.tools.indexOf( this._.tabIdList, tabId ) + length;
+
+ for ( var i = tabIndex - 1; i > tabIndex - length; i-- ) {
+ if ( isTabVisible.call( this, this._.tabIdList[ i % length ] ) )
+ return this._.tabIdList[ i % length ];
+ }
+
+ return null;
+ }
+
+ function getNextVisibleTab() {
+ var tabId = this._.currentTabId,
+ length = this._.tabIdList.length,
+ tabIndex = CKEDITOR.tools.indexOf( this._.tabIdList, tabId );
+
+ for ( var i = tabIndex + 1; i < tabIndex + length; i++ ) {
+ if ( isTabVisible.call( this, this._.tabIdList[ i % length ] ) )
+ return this._.tabIdList[ i % length ];
+ }
+
+ return null;
+ }
+
+
+ function clearOrRecoverTextInputValue( container, isRecover ) {
+ var inputs = container.$.getElementsByTagName( 'input' );
+ for ( var i = 0, length = inputs.length; i < length; i++ ) {
+ var item = new CKEDITOR.dom.element( inputs[ i ] );
+
+ if ( item.getAttribute( 'type' ).toLowerCase() == 'text' ) {
+ if ( isRecover ) {
+ item.setAttribute( 'value', item.getCustomData( 'fake_value' ) || '' );
+ item.removeCustomData( 'fake_value' );
+ } else {
+ item.setCustomData( 'fake_value', item.getAttribute( 'value' ) );
+ item.setAttribute( 'value', '' );
+ }
+ }
+ }
+ }
+
+ // Handle dialog element validation state UI changes.
+ function handleFieldValidated( isValid, msg ) {
+ var input = this.getInputElement();
+ if ( input )
+ isValid ? input.removeAttribute( 'aria-invalid' ) : input.setAttribute( 'aria-invalid', true );
+
+ if ( !isValid ) {
+ if ( this.select )
+ this.select();
+ else
+ this.focus();
+ }
+
+ msg && alert( msg ); // jshint ignore:line
+
+ this.fire( 'validated', { valid: isValid, msg: msg } );
+ }
+
+ function resetField() {
+ var input = this.getInputElement();
+ input && input.removeAttribute( 'aria-invalid' );
+ }
+
+ var templateSource = '
+ This sample shows how to use the
+ CKEditor Dialog API
+ to customize CKEditor dialog windows without changing the original editor code.
+ The following customizations are being done in the example below:
+
+
+ For details on how to create this setup check the source code of this sample page.
+
+
+
A custom dialog is added to the editors using the pluginsLoaded event, from an external dialog definition file:
+
+
Creating a custom dialog window – "My Dialog" dialog window opened with the "My Dialog" toolbar button.
+
Creating a custom button – Add button to open the dialog with "My Dialog" toolbar button.
+
+
+
+
The below editor modify the dialog definition of the above added dialog using the dialogDefinition event:
+
+
Adding dialog tab – Add new tab "My Tab" to dialog window.
+
Removing a dialog window tab – Remove "Second Tab" page from the dialog window.
+
Adding dialog window fields – Add "My Custom Field" to the dialog window.
+
Removing dialog window field – Remove "Select Field" selection field from the dialog window.
+
Setting default values for dialog window fields – Set default value of "Text Field" text field.
+
Setup initial focus for dialog window – Put initial focus on "My Custom Field" text field.
+
+
+
+
+
+
diff --git a/assets/ckeditor-contrib/plugins/dialogui/plugin.js b/assets/ckeditor-contrib/plugins/dialogui/plugin.js
new file mode 100644
index 00000000..efae40f9
--- /dev/null
+++ b/assets/ckeditor-contrib/plugins/dialogui/plugin.js
@@ -0,0 +1,1530 @@
+/**
+ * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md or http://ckeditor.com/license
+ */
+
+/**
+ * @fileOverview The Dialog User Interface plugin.
+ */
+
+CKEDITOR.plugins.add( 'dialogui', {
+ onLoad: function() {
+
+ var initPrivateObject = function( elementDefinition ) {
+ this._ || ( this._ = {} );
+ this._[ 'default' ] = this._.initValue = elementDefinition[ 'default' ] || '';
+ this._.required = elementDefinition.required || false;
+ var args = [ this._ ];
+ for ( var i = 1; i < arguments.length; i++ )
+ args.push( arguments[ i ] );
+ args.push( true );
+ CKEDITOR.tools.extend.apply( CKEDITOR.tools, args );
+ return this._;
+ },
+ textBuilder = {
+ build: function( dialog, elementDefinition, output ) {
+ return new CKEDITOR.ui.dialog.textInput( dialog, elementDefinition, output );
+ }
+ },
+ commonBuilder = {
+ build: function( dialog, elementDefinition, output ) {
+ return new CKEDITOR.ui.dialog[ elementDefinition.type ]( dialog, elementDefinition, output );
+ }
+ },
+ containerBuilder = {
+ build: function( dialog, elementDefinition, output ) {
+ var children = elementDefinition.children,
+ child,
+ childHtmlList = [],
+ childObjList = [];
+ for ( var i = 0;
+ ( i < children.length && ( child = children[ i ] ) ); i++ ) {
+ var childHtml = [];
+ childHtmlList.push( childHtml );
+ childObjList.push( CKEDITOR.dialog._.uiElementBuilders[ child.type ].build( dialog, child, childHtml ) );
+ }
+ return new CKEDITOR.ui.dialog[ elementDefinition.type ]( dialog, childObjList, childHtmlList, output, elementDefinition );
+ }
+ },
+ commonPrototype = {
+ isChanged: function() {
+ return this.getValue() != this.getInitValue();
+ },
+
+ reset: function( noChangeEvent ) {
+ this.setValue( this.getInitValue(), noChangeEvent );
+ },
+
+ setInitValue: function() {
+ this._.initValue = this.getValue();
+ },
+
+ resetInitValue: function() {
+ this._.initValue = this._[ 'default' ];
+ },
+
+ getInitValue: function() {
+ return this._.initValue;
+ }
+ },
+ commonEventProcessors = CKEDITOR.tools.extend( {}, CKEDITOR.ui.dialog.uiElement.prototype.eventProcessors, {
+ onChange: function( dialog, func ) {
+ if ( !this._.domOnChangeRegistered ) {
+ dialog.on( 'load', function() {
+ this.getInputElement().on( 'change', function() {
+ // Make sure 'onchange' doesn't get fired after dialog closed. (#5719)
+ if ( !dialog.parts.dialog.isVisible() )
+ return;
+
+ this.fire( 'change', { value: this.getValue() } );
+ }, this );
+ }, this );
+ this._.domOnChangeRegistered = true;
+ }
+
+ this.on( 'change', func );
+ }
+ }, true ),
+ eventRegex = /^on([A-Z]\w+)/,
+ cleanInnerDefinition = function( def ) {
+ // An inner UI element should not have the parent's type, title or events.
+ for ( var i in def ) {
+ if ( eventRegex.test( i ) || i == 'title' || i == 'type' )
+ delete def[ i ];
+ }
+ return def;
+ },
+ // @context {CKEDITOR.dialog.uiElement} UI element (textarea or textInput)
+ // @param {CKEDITOR.dom.event} evt
+ toggleBidiKeyUpHandler = function( evt ) {
+ var keystroke = evt.data.getKeystroke();
+
+ // ALT + SHIFT + Home for LTR direction.
+ if ( keystroke == CKEDITOR.SHIFT + CKEDITOR.ALT + 36 )
+ this.setDirectionMarker( 'ltr' );
+
+ // ALT + SHIFT + End for RTL direction.
+ else if ( keystroke == CKEDITOR.SHIFT + CKEDITOR.ALT + 35 )
+ this.setDirectionMarker( 'rtl' );
+ };
+
+ CKEDITOR.tools.extend( CKEDITOR.ui.dialog, {
+ /**
+ * Base class for all dialog window elements with a textual label on the left.
+ *
+ * @class CKEDITOR.ui.dialog.labeledElement
+ * @extends CKEDITOR.ui.dialog.uiElement
+ * @constructor Creates a labeledElement class instance.
+ * @param {CKEDITOR.dialog} dialog Parent dialog window object.
+ * @param {CKEDITOR.dialog.definition.uiElement} elementDefinition
+ * The element definition. Accepted fields:
+ *
+ * * `label` (Required) The label string.
+ * * `labelLayout` (Optional) Put 'horizontal' here if the
+ * label element is to be laid out horizontally. Otherwise a vertical
+ * layout will be used.
+ * * `widths` (Optional) This applies only to horizontal
+ * layouts — a two-element array of lengths to specify the widths of the
+ * label and the content element.
+ * * `role` (Optional) Value for the `role` attribute.
+ * * `includeLabel` (Optional) If set to `true`, the `aria-labelledby` attribute
+ * will be included.
+ *
+ * @param {Array} htmlList The list of HTML code to output to.
+ * @param {Function} contentHtml
+ * A function returning the HTML code string to be added inside the content
+ * cell.
+ */
+ labeledElement: function( dialog, elementDefinition, htmlList, contentHtml ) {
+ if ( arguments.length < 4 )
+ return;
+
+ var _ = initPrivateObject.call( this, elementDefinition );
+ _.labelId = CKEDITOR.tools.getNextId() + '_label';
+ this._.children = [];
+
+ var innerHTML = function() {
+ var html = [],
+ requiredClass = elementDefinition.required ? ' cke_required' : '';
+ if ( elementDefinition.labelLayout != 'horizontal' ) {
+ html.push(
+ '',
+ '