From 2e1607c20665fc95b0ea2f014c60359cd6a29e13 Mon Sep 17 00:00:00 2001 From: Julio Montoya Date: Thu, 18 Apr 2019 10:09:29 +0200 Subject: [PATCH] Updating from 1.11.x, ckeditor plugins --- .../image2_chamilo/dialogs/image2_chamilo.js | 2 +- .../ckeditor/plugins/image2_chamilo/plugin.js | 4 +- .../qmarkersrolls/dialogs/qmarkersrolls.js | 388 +++++++++++++++ .../plugins/qmarkersrolls/images/icon.png | Bin 0 -> 1272 bytes .../ckeditor/plugins/qmarkersrolls/lang/en.js | 19 + .../ckeditor/plugins/qmarkersrolls/lang/es.js | 20 + .../ckeditor/plugins/qmarkersrolls/plugin.js | 51 ++ .../ckeditor/plugins/video/dialogs/video.js | 2 +- .../ckeditor/plugins/video/plugin.js | 2 +- .../plugins/wordcount/css/wordcount.css | 3 + .../ckeditor/plugins/wordcount/lang/ca.js | 11 + .../ckeditor/plugins/wordcount/lang/de.js | 11 + .../ckeditor/plugins/wordcount/lang/en.js | 11 + .../ckeditor/plugins/wordcount/lang/es.js | 11 + .../ckeditor/plugins/wordcount/lang/fr.js | 9 + .../ckeditor/plugins/wordcount/lang/it.js | 12 + .../ckeditor/plugins/wordcount/lang/jp.js | 10 + .../ckeditor/plugins/wordcount/lang/no.js | 8 + .../ckeditor/plugins/wordcount/lang/pl.js | 11 + .../ckeditor/plugins/wordcount/lang/pt-BR.js | 10 + .../ckeditor/plugins/wordcount/lang/ru.js | 11 + .../ckeditor/plugins/wordcount/plugin.js | 211 +++++++++ .../plugins/youtube/images/icon-hdpi.png | Bin 0 -> 1258 bytes .../ckeditor/plugins/youtube/images/icon.png | Bin 0 -> 1165 bytes .../ckeditor/plugins/youtube/lang/ar.js | 24 + .../ckeditor/plugins/youtube/lang/cs.js | 25 + .../ckeditor/plugins/youtube/lang/de.js | 24 + .../ckeditor/plugins/youtube/lang/el.js | 23 + .../ckeditor/plugins/youtube/lang/en.js | 25 + .../ckeditor/plugins/youtube/lang/es.js | 24 + .../ckeditor/plugins/youtube/lang/et.js | 24 + .../ckeditor/plugins/youtube/lang/eu.js | 25 + .../ckeditor/plugins/youtube/lang/fi.js | 24 + .../ckeditor/plugins/youtube/lang/fr.js | 24 + .../ckeditor/plugins/youtube/lang/he.js | 24 + .../ckeditor/plugins/youtube/lang/hu.js | 24 + .../ckeditor/plugins/youtube/lang/it.js | 24 + .../ckeditor/plugins/youtube/lang/ja.js | 24 + .../ckeditor/plugins/youtube/lang/ko.js | 25 + .../ckeditor/plugins/youtube/lang/nb.js | 24 + .../ckeditor/plugins/youtube/lang/nl.js | 25 + .../ckeditor/plugins/youtube/lang/nn.js | 24 + .../ckeditor/plugins/youtube/lang/pl.js | 24 + .../ckeditor/plugins/youtube/lang/pt-br.js | 25 + .../ckeditor/plugins/youtube/lang/pt.js | 25 + .../ckeditor/plugins/youtube/lang/ru.js | 25 + .../ckeditor/plugins/youtube/lang/sk.js | 24 + .../ckeditor/plugins/youtube/lang/tr.js | 24 + .../ckeditor/plugins/youtube/lang/vi.js | 24 + .../ckeditor/plugins/youtube/lang/zh.js | 24 + .../ckeditor/plugins/youtube/plugin.js | 448 ++++++++++++++++++ .../views/Layout/legacy_js.html.twig | 1 - tests/datafiller/users_import_big_example.csv | 201 ++++++++ 53 files changed, 2092 insertions(+), 6 deletions(-) create mode 100644 main/inc/lib/javascript/ckeditor/plugins/qmarkersrolls/dialogs/qmarkersrolls.js create mode 100644 main/inc/lib/javascript/ckeditor/plugins/qmarkersrolls/images/icon.png create mode 100644 main/inc/lib/javascript/ckeditor/plugins/qmarkersrolls/lang/en.js create mode 100644 main/inc/lib/javascript/ckeditor/plugins/qmarkersrolls/lang/es.js create mode 100644 main/inc/lib/javascript/ckeditor/plugins/qmarkersrolls/plugin.js create mode 100644 main/inc/lib/javascript/ckeditor/plugins/wordcount/css/wordcount.css create mode 100644 main/inc/lib/javascript/ckeditor/plugins/wordcount/lang/ca.js create mode 100644 main/inc/lib/javascript/ckeditor/plugins/wordcount/lang/de.js create mode 100644 main/inc/lib/javascript/ckeditor/plugins/wordcount/lang/en.js create mode 100644 main/inc/lib/javascript/ckeditor/plugins/wordcount/lang/es.js create mode 100644 main/inc/lib/javascript/ckeditor/plugins/wordcount/lang/fr.js create mode 100644 main/inc/lib/javascript/ckeditor/plugins/wordcount/lang/it.js create mode 100644 main/inc/lib/javascript/ckeditor/plugins/wordcount/lang/jp.js create mode 100644 main/inc/lib/javascript/ckeditor/plugins/wordcount/lang/no.js create mode 100644 main/inc/lib/javascript/ckeditor/plugins/wordcount/lang/pl.js create mode 100644 main/inc/lib/javascript/ckeditor/plugins/wordcount/lang/pt-BR.js create mode 100644 main/inc/lib/javascript/ckeditor/plugins/wordcount/lang/ru.js create mode 100644 main/inc/lib/javascript/ckeditor/plugins/wordcount/plugin.js create mode 100644 main/inc/lib/javascript/ckeditor/plugins/youtube/images/icon-hdpi.png create mode 100644 main/inc/lib/javascript/ckeditor/plugins/youtube/images/icon.png create mode 100644 main/inc/lib/javascript/ckeditor/plugins/youtube/lang/ar.js create mode 100644 main/inc/lib/javascript/ckeditor/plugins/youtube/lang/cs.js create mode 100644 main/inc/lib/javascript/ckeditor/plugins/youtube/lang/de.js create mode 100644 main/inc/lib/javascript/ckeditor/plugins/youtube/lang/el.js create mode 100644 main/inc/lib/javascript/ckeditor/plugins/youtube/lang/en.js create mode 100644 main/inc/lib/javascript/ckeditor/plugins/youtube/lang/es.js create mode 100644 main/inc/lib/javascript/ckeditor/plugins/youtube/lang/et.js create mode 100644 main/inc/lib/javascript/ckeditor/plugins/youtube/lang/eu.js create mode 100644 main/inc/lib/javascript/ckeditor/plugins/youtube/lang/fi.js create mode 100644 main/inc/lib/javascript/ckeditor/plugins/youtube/lang/fr.js create mode 100644 main/inc/lib/javascript/ckeditor/plugins/youtube/lang/he.js create mode 100644 main/inc/lib/javascript/ckeditor/plugins/youtube/lang/hu.js create mode 100644 main/inc/lib/javascript/ckeditor/plugins/youtube/lang/it.js create mode 100644 main/inc/lib/javascript/ckeditor/plugins/youtube/lang/ja.js create mode 100644 main/inc/lib/javascript/ckeditor/plugins/youtube/lang/ko.js create mode 100644 main/inc/lib/javascript/ckeditor/plugins/youtube/lang/nb.js create mode 100644 main/inc/lib/javascript/ckeditor/plugins/youtube/lang/nl.js create mode 100644 main/inc/lib/javascript/ckeditor/plugins/youtube/lang/nn.js create mode 100644 main/inc/lib/javascript/ckeditor/plugins/youtube/lang/pl.js create mode 100644 main/inc/lib/javascript/ckeditor/plugins/youtube/lang/pt-br.js create mode 100644 main/inc/lib/javascript/ckeditor/plugins/youtube/lang/pt.js create mode 100644 main/inc/lib/javascript/ckeditor/plugins/youtube/lang/ru.js create mode 100644 main/inc/lib/javascript/ckeditor/plugins/youtube/lang/sk.js create mode 100644 main/inc/lib/javascript/ckeditor/plugins/youtube/lang/tr.js create mode 100644 main/inc/lib/javascript/ckeditor/plugins/youtube/lang/vi.js create mode 100644 main/inc/lib/javascript/ckeditor/plugins/youtube/lang/zh.js create mode 100644 main/inc/lib/javascript/ckeditor/plugins/youtube/plugin.js create mode 100644 tests/datafiller/users_import_big_example.csv diff --git a/main/inc/lib/javascript/ckeditor/plugins/image2_chamilo/dialogs/image2_chamilo.js b/main/inc/lib/javascript/ckeditor/plugins/image2_chamilo/dialogs/image2_chamilo.js index cd69b27ccb..17a58dbd21 100644 --- a/main/inc/lib/javascript/ckeditor/plugins/image2_chamilo/dialogs/image2_chamilo.js +++ b/main/inc/lib/javascript/ckeditor/plugins/image2_chamilo/dialogs/image2_chamilo.js @@ -551,7 +551,7 @@ CKEDITOR.dialog.add( 'image2_chamilo', function( editor ) { img = widget.element.$.firstChild; } - img.className += ' img-fluid '; + img.className += ' img-responsive '; widget.setData( 'isResponsive', this.getValue() ); } } diff --git a/main/inc/lib/javascript/ckeditor/plugins/image2_chamilo/plugin.js b/main/inc/lib/javascript/ckeditor/plugins/image2_chamilo/plugin.js index d1a3c1f9c2..4571415e10 100644 --- a/main/inc/lib/javascript/ckeditor/plugins/image2_chamilo/plugin.js +++ b/main/inc/lib/javascript/ckeditor/plugins/image2_chamilo/plugin.js @@ -347,7 +347,7 @@ this.parts.image.setAttributes( { src: this.data.src, - class: this.data.isResponsive ? 'img-fluid' : '', + class: this.data.isResponsive ? 'img-responsive' : '', // This internal is required by the editor. 'data-cke-saved-src': this.data.src, @@ -394,7 +394,7 @@ alt: image.getAttribute( 'alt' ) || '', width: image.getAttribute( 'width' ) || '', height: image.getAttribute( 'height' ) || '', - isResponsive: !!image.$.className.match(/img-fluid/i), + isResponsive: !!image.$.className.match(/img-responsive/i), // Lock ratio is on by default (#10833). lock: this.ready ? helpers.checkHasNaturalRatio( image ) : true, borderWidth: !this.parts.caption ? image.getStyle('border-width') : '', diff --git a/main/inc/lib/javascript/ckeditor/plugins/qmarkersrolls/dialogs/qmarkersrolls.js b/main/inc/lib/javascript/ckeditor/plugins/qmarkersrolls/dialogs/qmarkersrolls.js new file mode 100644 index 0000000000..dee7c6389e --- /dev/null +++ b/main/inc/lib/javascript/ckeditor/plugins/qmarkersrolls/dialogs/qmarkersrolls.js @@ -0,0 +1,388 @@ +/** + * Plugin created by BeezNest Latino S.A.C + * + * For licensing terms, see /license.txt + * + * This plugin allows set quizzes markers in video with mediaelement. + */ + +CKEDITOR.dialog.add('qMarkersrollsDialog', function (editor) { + var lang = editor.lang.qmarkersrolls, + player = null, + pgbProgress = null, + fakeImage = null, + videoNode = null, + quizzesList = [], + currentMarkers = [], + colorDialog = editor.plugins.colordialog; + + function initPlayer(selectedElement) { + fakeImage = selectedElement; + + if (!fakeImage || + !fakeImage.data( 'cke-real-element-type' ) || + fakeImage.data( 'cke-real-element-type' ) != 'video' + ) { + return; + } + + videoNode = editor.restoreRealElement(fakeImage); + + var sourcesList = videoNode.getElementsByTag('source', ''); + + if (sourcesList.count() === 0) { + sourcesList = videoNode.getElementsByTag('source', 'cke'); + } + + if (sourcesList.count() === 0) { + return; + } + + var sourceNode = sourcesList.getItem(0); + + if (!sourceNode) { + return; + } + + pgbProgress = document.getElementById('ck-qmr-progress'); + pgbProgress.value = 0; + pgbProgress.min = 0; + pgbProgress.step = 1; + pgbProgress.onchange = function () { + player.currentTime = this.value; + + document.getElementById('ck-qmr-current-time').textContent = encodeTime(this.value); + }; + + var playerContainer = document.getElementById('ck-qmr-player-container'); + playerContainer.innerHTML = ''; + + player = document.createElement('video'); + player.className = 'skip'; + player.controls = false; + player.style.maxWidth = '100%'; + player.style.minWidth = '100%'; + player.onloadedmetadata = function () { + pgbProgress.max = Math.floor(player.duration); + playerContainer.appendChild(player); + }; + player.src = sourceNode.getAttribute('src'); + } + + function decodeTime(time) { + var parts = time.split(':'); + + if (parts.length != 3) { + return 0; + } + + var hours = parseInt(parts[0]), + minutes = parseInt(parts[1]), + seconds = parseInt(parts[2]); + + if (seconds > 59 || minutes > 59) { + return 0; + } + + hours *= 60 * 60; + minutes *= 60; + + return hours + minutes + seconds; + } + + function encodeTime(time) { + if (time < 60) { + if (time < 10) { + time = '0' + time; + } + + return '00:00:' + time; + } + + var hours = 0, + minutes = Math.floor(time / 60), + seconds = Math.floor(time % 60); + + if (minutes > 60) { + hours = Math.floor(minutes / 60); + minutes = minutes - (hours * 60); + } + + return (hours < 10 ? '0' + hours : hours) + ':' + + (minutes < 10 ? '0' + minutes : minutes) + ':' + + (seconds < 10 ? '0' + seconds : seconds); + } + + function displayQuizzes() { + var container = document.getElementById('ck-qmr-quizzes-container'); + container.innerHTML = ''; + + quizzesList.forEach(function (quiz) { + var alreadyAdded = false; + + currentMarkers.forEach(function (markerRoll) { + if (quiz.id == markerRoll[1]) { + alreadyAdded = true; + } + }); + + if (alreadyAdded) { + return; + } + + var label = document.createElement('label'); + label.textContent = quiz.title; + label.htmlFor = 'ck-qmr-quiz-' + quiz.id; + label.style.verticalAlign = 'super'; + + var radio = document.createElement('input'); + radio.type = 'radio'; + radio.name = 'ck_qmr_quiz'; + radio.id = 'ck-qmr-quiz-' + quiz.id; + radio.value = quiz.id; + + var row = document.createElement('div'); + row.appendChild(radio); + row.appendChild(label); + + container.appendChild(row); + }); + } + + function displayCurrentMarkersList() { + var quizzesAddedContainer = document.getElementById('ck-qmr-quizzes-added-container'); + quizzesAddedContainer.innerHTML = ''; + + currentMarkers.forEach(function (markerRoll) { + var makerForQuiz = null; + + quizzesList.forEach(function (quiz) { + if (markerRoll[1] == quiz.id) { + makerForQuiz = quiz; + } + }); + + if (!makerForQuiz) { + return; + } + + var btnRemove = document.createElement('a'); + btnRemove.className = 'cke_dialog_ui_button'; + btnRemove.type = 'button'; + btnRemove.innerHTML = '' + lang.delete + ''; + btnRemove.setAttribute('role', 'button'); + btnRemove.addEventListener('click', function (e) { + e.preventDefault(); + e.stopPropagation(); + + for (var i = 0; i < currentMarkers.length; i++) { + if (currentMarkers[i][1] == markerRoll[1]) { + currentMarkers.splice(i, 1); + i--; + } + } + + displayQuizzes(); + displayCurrentMarkersList(); + }, false); + + var divMarker = document.createElement('span'); + divMarker.innerHTML = ' ' + encodeTime(markerRoll[0]) + ' — ' + + makerForQuiz.title; + + var pMarker = document.createElement('p'); + pMarker.appendChild(btnRemove); + pMarker.appendChild(divMarker); + + quizzesAddedContainer.appendChild(pMarker); + }); + } + + return { + title: lang.dialogTitle, + minWidth: 400, + minHeight: 500, + resizable: CKEDITOR.DIALOG_RESIZE_NONE, + contents: [ + { + id: 'tab-markers', + label: lang.markers, + elements: [ + { + type: 'vbox', + width: '100%', + children: [ + { + type: 'html', + id: 'html', + html: '
' + }, + { + type: 'hbox', + widths: ['100%', '200px'], + children: [ + { + type: 'html', + html: '' + }, + { + type: 'html', + title: 'Current Time', + html: '00:00:00' + }, + ] + }, + { + type: 'hbox', + widths: ['100%', '200px'], + children: [ + { + type: 'html', + html: lang.embeddableQuizzes + ' ' + + '
' + }, + { + type: 'button', + id: 'btn-assign', + label: lang.assignQuiz, + title: lang.assignQuiz, + onClick: function () { + var radioQuizzes = document.getElementsByName('ck_qmr_quiz'), + selected = null; + + radioQuizzes.forEach(function (radio) { + if (!radio.checked) { + return; + } + + selected = radio; + }); + + if (!selected) { + return; + } + + currentMarkers.push([ + parseInt(pgbProgress.value), + parseInt(selected.value) + ]); + + displayCurrentMarkersList(); + + selected.parentElement.remove(); + } + } + ] + }, + { + type: 'html', + html: lang.currentMarkers + ' ' + + '
' + } + ] + }, + ] + }, + { + id: 'tab-settings', + label: lang.settings, + elements: [ + { + type: 'hbox', + widths: ['200px', '100%'], + children: [ + { + type: 'text', + id: 'markerColor', + label: lang.markerColor, + 'default': '', + setup: function (widget) { + this.setValue(widget.getAttribute('data-q-markersrolls-color')); + }, + commit: function (widget) { + widget.setAttribute('data-q-markersrolls-color', this.getValue()); + } + }, + colorDialog ? { + type: 'button', + id: 'markerColorChoose', + 'class': 'colorChooser', + label: lang.choose, + onLoad: function() { + // Stick the element to the bottom + this.getElement() + .getParent() + .setStyle('vertical-align', 'bottom'); + }, + onClick: function () { + editor.getColorFromDialog(function (color) { + if (color) { + this.getDialog() + .getContentElement('tab-settings', 'markerColor') + .setValue(color); + } + + this.focus(); + }, this) + } + } : { + type: 'html', + html: ' ' + } + ] + }, + ] + }, + ], + onShow: function () { + var dialog = this; + + document.getElementById('ck-qmr-quizzes-container').innerHTML = ''; + + initPlayer( + dialog.getSelectedElement() + ); + + currentMarkers = JSON.parse( + videoNode.getAttribute('data-q-markersrolls') || '[]' + ); + + CKEDITOR.ajax.load( + editor.config.qMarkersRollsUrl, + function (response) { + quizzesList = JSON.parse(response); + + displayQuizzes(); + + displayCurrentMarkersList(); + + dialog.setupContent(videoNode); + } + ); + }, + onHide: function () { + player = null; + pgbProgress = null; + }, + onOk: function () { + if (!fakeImage) { + return; + } + + this.commitContent(videoNode); + + videoNode.setAttribute('data-q-markersrolls', JSON.stringify(currentMarkers)); + + var newFakeImage = editor.createFakeElement(videoNode, 'cke_video', 'video', false); + newFakeImage.setStyles({ + width: fakeImage.getStyle('width'), + height: fakeImage.getStyle('height') + }); + + newFakeImage.replace(fakeImage); + editor.getSelection().selectElement(newFakeImage); + } + }; +}); diff --git a/main/inc/lib/javascript/ckeditor/plugins/qmarkersrolls/images/icon.png b/main/inc/lib/javascript/ckeditor/plugins/qmarkersrolls/images/icon.png new file mode 100644 index 0000000000000000000000000000000000000000..d59bd6de46e19fc7e3396dbb20ea5b165310feb1 GIT binary patch literal 1272 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!63?wyl`GbKJdx@v7EBkFmK`}Gc-O)$C0fjgV zJR*x37`Q%wFr(8NlNk&Q%nSiOA+E~G%4%wAIzXUrU|?iyVq#)wZfRj*VP$P&VQX(` zYj0)mXzk!+Hs8N-JD!pon77C+}xbqJzU*AoISkU zJUrdKyxhIKJ%GT|(*wxx_VM)b@$m8U^!4-d1pyy_e?LDze}8{({{SEV0RO-s|KN}S zAP5Q$3JMAi4h{$j2@DMj3JD1c4G#t~!oovBLPA4B!^6Xa!y-Z=BEq9%A|fIpV`8IY zVxnT=Vq#+A;^N}tKp-(CH8C|cB^3a&mznKR+)oFF!v&JHH?|zaX!mAitofprD|zu&|)0 zxTvV8xVX5a3ILrHf`FB88c=A!R*8wmD*z|o^e zj~_pN^39Q7kcwN$8jVd`vzINckUE;5!mue^XNK|S z4SKT{=PGJ{E^0d}d)8HSu2fe2^YNyJKgL!!qPW~x7 z`cHSJ+3NJn?bU`y3QnG$8NEy6bjAv=SKb|)45yr^+HrpF9-Y%>+NXCNyfJg~LYK4q zD=z;kz56zHt8eeMdv|zLcQrE3F5Xqlt>$x6AXDhT;eaH8pnDuFYcE%aPm^@}U_2$F zC7QXhvvcF@tqc7m config.wordLimit) { + limitReached(editor, limitReachedNotified); + } else if (config.showWordCount && wordCount == config.wordLimit) { + // create snapshot to make sure only the content after the limit gets deleted + editorInstance.fire('saveSnapshot'); + } else if (!limitRestoredNotified && wordCount < config.wordLimit) { + limitRestored(editor); + } + + // Check for char limit + if (config.showCharCount && charCount > config.charLimit) { + limitReached(editor, limitReachedNotified); + } else if (config.showCharCount && charCount == config.charLimit) { + // create snapshot to make sure only the content after the limit gets deleted + editorInstance.fire('saveSnapshot'); + } else if (!limitRestoredNotified && charCount < config.charLimit) { + limitRestored(editor); + } + + return true; + } + + function limitReached(editorInstance, notify) { + limitReachedNotified = true; + limitRestoredNotified = false; + + editorInstance.execCommand('undo'); + + if (!notify) { + //counterElement(editorInstance).className = "cke_wordcount cke_wordcountLimitReached"; + + editorInstance.fire('limitReached', {}, editor); + } + + // lock editor + editorInstance.config.Locked = 1; + } + + function limitRestored(editorInstance) { + + limitRestoredNotified = true; + limitReachedNotified = false; + editorInstance.config.Locked = 0; + + counterElement(editorInstance).className = "cke_wordcount"; + } + + editor.on('key', function (event) { + + updateCounter(event.editor); + }, editor, null, 100); + + editor.on('uiSpace', function (event) { + if (event.data.space == 'bottom') { + event.data.html += '
 
'; + } + }, editor, null, 100); + editor.on('dataReady', function (event) { + updateCounter(event.editor); + }, editor, null, 100); + /*editor.on('change', function (event) { + + updateCounter(event.editor); + }, editor, null, 100);*/ + + editor.on('afterPaste', function (event) { + updateCounter(event.editor); + }, editor, null, 100); + /*editor.on('focus', function (event) { + editorHasFocus = true; + intervalId = window.setInterval(function () { + updateCounter(editor); + }, 300, event.editor); + }, editor, null, 300);*/ + editor.on('blur', function () { + if (intervalId) { + window.clearInterval(intervalId); + } + }, editor, null, 300); + + if (!String.prototype.trim) { + String.prototype.trim = function () { + return this.replace(/^\s+|\s+$/g, ''); + }; + } + } +}); diff --git a/main/inc/lib/javascript/ckeditor/plugins/youtube/images/icon-hdpi.png b/main/inc/lib/javascript/ckeditor/plugins/youtube/images/icon-hdpi.png new file mode 100644 index 0000000000000000000000000000000000000000..d439185547f29833a45ce20db54dfc3bfd6958b1 GIT binary patch literal 1258 zcmaJ=TWB0r7@iValDaKgC|D60XG5~Z?A-P;7qZ6boQd5g8<)*Owj@F)Gbh<0nTs=% z>?Y=+7DTk#LW81IrBopxT12$qHqeC>YY7$62PJt42+;^?)FeL1dM4S8eTY49?*I4y z-+y~0+xN_&gO47>FzitJB*>v14`y={TEPdeeu=hYzEbe}?GeAEx)76edl=$rQyqml zsOnSC-+`SN)>Jg|1;3E#6*b!=)j)LSMzp=D6jF7*DF@cJN-HCG=IbD+C! z3*Ayg(f1vZqDrL_S&EUiJ4!KvAW$?*v1}AcM7=4?SIbe$3pX?X=xMIu_=auafkt)M zp72uyV!Gpk>0~myiY>1mC=@cPtU44!(v)cier-#8eh&UeV^3)>KjlCw2R(bj)lfc0 z!VNHr-Te&(f{2aytZSg8sN=xaCQNAgX^ODB1T;aOG!jGSZ> z3JtmwprK&0o=dPN;tG&>nQmaymglRM1{-z_WVen@-WMy% zE>wNn&D-{PqXM!;+qb=D#?kShX6RN@BxLf?_vfDn; zLOtW6=D5wg(}Nm|&i3Y&p`jr~Q5F{$CnqOoXJ^;e*4Ee8E0szp6q=ixYj1CFYinz5 zZLQU6kw^rsm%r#C5cVNI*Vm7(_YQ0&{M<40S4{&cUtXI3PCBxHH}C)E;xO3n)t2A9 ze!e)nq>TPKpq67Tr#`7Q|F&=NtC!yX@sZU_3tI<-+|AGvUD6-7r{7q8{nPL!JmL;+ zetvc{vfT1y`0$nUGv}HgdpcYBIYc)tU+ulMFH`L}Gjs9Vmbc)g>ko`{Oti3{MXMVR zA6`A)aaWr;Tm0y%`S@S_oeu%=@s?ffS^MdIvNCUV7q$kg7mnf!@2$MxynA6|>6euU qfBpWHJil@G>%adwU3>9mtO>i;!~AghwF3jl7c8yxfomtuock9|&$dYb literal 0 HcmV?d00001 diff --git a/main/inc/lib/javascript/ckeditor/plugins/youtube/images/icon.png b/main/inc/lib/javascript/ckeditor/plugins/youtube/images/icon.png new file mode 100644 index 0000000000000000000000000000000000000000..6a0877959b238b11c8201249a614d5c84ba733f9 GIT binary patch literal 1165 zcmaJ=OK1~87+w*i_-NIGq6HndhekBnM>daL8_RZQqfyg_Bw|2>Zg;26((c3EX_NM1 z5wVB|4~iF0#e)?==t=5>_&8Xxf@1NY7mq!N3f@$#vuRR2R0rnq&-~y2fAc>s<$8~7 z*|>WnMNwNaM`51qTZ7rMo~)s8TY+r5uv)?eXAoC34^gt=3?PuPv>}v7nlXO%1?r-x z^<}eI!lmp9Nq4M>7U)E(mP^nS)zw{fHGLRiFo1?kJ4JtaP@{oqr07$zESq%|R5p)J zc&ISZThu3pbEHPECjjA*qN;I-W@M^u*$;*o^IC&DK%VuSxtiu)=?_lHwr^J6_RoMw%6n zD?8Zn%Z>|_LL7v$nr_;`#r_~cEB}SaGslpT_8be;BP^L~FyN9&1&XqeOh%)1_D~R1 z7)vNonH6L{NjI>@8c}OtWB$fd`}+E3XJ;1{7D#PQO-;?u&(F=xEiNwBYPF@MrRnME&d$#E_V(rF+YAHF){{ k;f5PGJ1_tG@!|O7I%?;)O?d47vnX*#Wz=4Hx2OO7Zx>yLfB*mh literal 0 HcmV?d00001 diff --git a/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/ar.js b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/ar.js new file mode 100644 index 0000000000..7f72386ef2 --- /dev/null +++ b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/ar.js @@ -0,0 +1,24 @@ +CKEDITOR.plugins.setLang('youtube', 'ar', { + button : 'شيفرة تضمين اليوتيوب', + title : 'شيفرة تضمين اليوتيوب', + txtEmbed : 'الصق شيفرة التضمين هنا', + txtUrl : 'الصق رابط فيديو اليوتيوب', + txtWidth : 'العرض', + txtHeight : 'الطول', + chkRelated : 'اظهر الفيديوهات المقترحة في نهاية الفيديو', + txtStartAt : 'ابدأ عند (ss او mm:ss او hh:mm:ss)', + chkPrivacy : 'تفعيل وضع تحسين الخصوصية', + chkOlderCode : 'استخدم شيفرة التضمين القديمة', + chkAutoplay : 'Autoplay', + chkControls: 'إظهار عناصر التحكم بالمشغّل', + noCode : 'يجب عليك ادخال شيفرة التضمين او الرابط', + invalidEmbed : 'شيفرة التضمين التي قمت بإدخالها تبدو غير صحيحة', + invalidUrl : 'الرابط الذي قمت بإدخاله يبدو غير صحيح', + or : 'او', + noWidth : 'يجب عليك ادخال العرض', + invalidWidth : 'يجب عليك ادخال عرض صحيح', + noHeight : 'يجب عليك ادخال الطول', + invalidHeight : 'يجب عليك ادخال طول صحيح', + invalidTime : 'يجب عليك ادخال وقت بداية صحيح', + txtResponsive : 'Responsive video' +}); diff --git a/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/cs.js b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/cs.js new file mode 100644 index 0000000000..d6d935d01b --- /dev/null +++ b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/cs.js @@ -0,0 +1,25 @@ +CKEDITOR.plugins.setLang('youtube', 'cs', { + button : 'Vložit video YouTube', + title : 'Vložit video YouTube', + txtEmbed : 'Zde vložte kód pro vložení', + txtUrl : 'Vložte adresu URL videa YouTube', + txtWidth : 'Šířka', + txtHeight : 'Výška', + chkRelated : 'Po dohrání videa zobrazit navrhovaná videa', + txtStartAt : 'Začít přehrávat v čase (ss nebo mm:ss nebo hh:mm:ss)', + chkPrivacy : 'Povolit režim s rozšířeným soukromím', + chkOlderCode : 'Použít starý kód pro vložení', + chkAutoplay : 'Automatické spuštění přehrávání', + chkControls : 'Zobrazit ovladače přehrávání', + noCode : 'Musíte vložit kód pro vložení nebo adresu URL', + invalidEmbed : 'Vložený kód pro vložení zřejmě není platný', + invalidUrl : 'Zadaná adresa URL zřejmě není platná', + or : 'nebo', + noWidth : 'Musíte zadat šířku', + invalidWidth : 'Zadejte platnou šířku', + noHeight : 'Musíte zadat výšku', + invalidHeight : 'Zadejte platnou výšku', + invalidTime : 'Zadejte platný počáteční čas', + txtResponsive : 'Responzivní design (ignorovat výšku a šířku, uzpůsobit šířce)', + txtNoEmbed : 'Pouze obrázek videa s odkazem' +}); diff --git a/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/de.js b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/de.js new file mode 100644 index 0000000000..6ad4f3c851 --- /dev/null +++ b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/de.js @@ -0,0 +1,24 @@ +CKEDITOR.plugins.setLang('youtube', 'de', { + button : 'YouTube Video einbinden', + title : 'YouTube Video einbinden', + txtEmbed : 'Embed Code hier einfügen', + txtUrl : 'YouTube Video URL hier einfügen', + txtWidth : 'Breite', + txtHeight : 'Höhe', + chkRelated : 'Vorschläge am Ende des Videos einblenden', + txtStartAt : 'Start bei Position (ss oder mm:ss oder hh:mm:ss)', + chkPrivacy : 'Erweiterten Datenschutzmodus aktivieren', + chkOlderCode : 'Benutze alten Embed Code', + chkAutoplay : 'Autoplay', + chkControls : 'Player-Steuerelemente anzeigen', + noCode : 'Sie müssen einen Embed Code oder URL angeben', + invalidEmbed : 'Der angegebene Embed Code scheint nicht gültig zu sein.', + invalidUrl : 'Die angegebene URL scheint nicht gültig zu sein.', + or : 'oder', + noWidth : 'Geben Sie eine Breite an', + invalidWidth : 'Geben Sie eine gültige Breite an', + noHeight : 'Geben Sie eine Höhe an', + invalidHeight : 'Geben Sie eine gültige Höhe an', + invalidTime : 'Geben Sie eine gültige Startzeit an', + txtResponsive : 'Automatische Größe (ignoriert Breite und Höhe)' +}); diff --git a/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/el.js b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/el.js new file mode 100644 index 0000000000..48716b42cc --- /dev/null +++ b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/el.js @@ -0,0 +1,23 @@ +CKEDITOR.plugins.setLang('youtube', 'el', { + button: 'Ενσωμάτωση Youtube βίντεο', + title: 'Ενσωμάτωση Youtube βίντεο', + txtEmbed: 'Επικόλλησε τον κώδικα ενσωμάτωσης', + txtUrl: 'Επικόλλησε το URL του βίντεο', + txtWidth: 'Πλάτος', + txtHeight: 'Ύψος', + chkRelated: 'Εμφάνιση προτεινόμενων βίντεο μόλις ολοκληρωθεί', + txtStartAt: 'Χρόνος εκκίνησης (ss or mm:ss or hh:mm:ss)', + chkPrivacy: 'Ενεργοποίηση λειτουργίας ενισχυμένου απορρήτου', + chkOlderCode: 'Χρήση παλαιού κώδικα ενσωμάτωσης', + chkAutoplay: 'Αυτόματη εκκίνηση', + chkControls: 'Εμφάνιση στοιχείων ελέγχου προγράμματος αναπαραγωγής', + noCode: 'Χρειάζεται κώδικας ενσωμάτωσης ή URL', + invalidEmbed: 'Ο κώδικας ενσωμάτωσης που εισήγατε δεν μοιάζει σωστός', + invalidUrl: 'Το URL που εισήγατε δεν μοιάζει σωστό', + or: 'ή', + noWidth: 'Συμπληρώστε το πλάτος', + invalidWidth: 'Λανθασμένο πλάτος', + noHeight: 'Συμπληρώστε το ύψος', + invalidHeight: 'Λανθασμένο ύψος', + invalidTime: 'Λανθασμένος χρόνος εκκίνησης' +}); diff --git a/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/en.js b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/en.js new file mode 100644 index 0000000000..4b68236353 --- /dev/null +++ b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/en.js @@ -0,0 +1,25 @@ +CKEDITOR.plugins.setLang('youtube', 'en', { + button : 'Embed YouTube Video', + title : 'Embed YouTube Video', + txtEmbed : 'Paste Embed Code Here', + txtUrl : 'Paste YouTube Video URL', + txtWidth : 'Width', + txtHeight : 'Height', + chkRelated : 'Show suggested videos at the video\'s end', + txtStartAt : 'Start at (ss or mm:ss or hh:mm:ss)', + chkPrivacy : 'Enable privacy-enhanced mode', + chkOlderCode : 'Use old embed code', + chkAutoplay: 'Autoplay', + chkControls: 'Show player controls', + noCode : 'You must input an embed code or URL', + invalidEmbed : 'The embed code you\'ve entered doesn\'t appear to be valid', + invalidUrl : 'The URL you\'ve entered doesn\'t appear to be valid', + or : 'or', + noWidth : 'You must inform the width', + invalidWidth : 'Inform a valid width', + noHeight : 'You must inform the height', + invalidHeight : 'Inform a valid height', + invalidTime : 'Inform a valid start time', + txtResponsive : 'Make Responsive (ignore width and height, fit to width)', + txtNoEmbed : 'Video image and link only' +}); diff --git a/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/es.js b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/es.js new file mode 100644 index 0000000000..b419a3bd67 --- /dev/null +++ b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/es.js @@ -0,0 +1,24 @@ +CKEDITOR.plugins.setLang('youtube', 'es', { + button : 'Embed YouTube video', + title : 'Embed YouTube video', + txtEmbed : 'Pegar el código embed', + txtUrl : 'Pegar la URL al video de Youtube', + txtWidth : 'Anchura', + txtHeight : 'Altura', + chkRelated : 'Mostrar videos sugeridos al final de este video', + txtStartAt : 'Comenzar en (ss or mm:ss or hh:mm:ss)', + chkPrivacy : 'Habilitar el modo privacy-enhanced', + chkOlderCode : 'Usar código embed viejo', + chkAutoplay: 'Autoplay', + chkControls: 'Mostrar controles del reproductor', + noCode : 'Debes de introducir un código embed o URL', + invalidEmbed : 'El código embed introducido parece no ser valido', + invalidUrl : 'La URL introducida parece no ser valida', + or : 'o', + noWidth : 'Debes de dar la anchura', + invalidWidth : 'Da una anchura valida', + noHeight : 'Debes dar una altura valida', + invalidHeight : 'Da una altura valida', + invalidTime : 'Da un tiempo de valido', + txtResponsive : 'Hacer responsivo (ignorar anchura y altura, ajustar a la anchura)' +}); diff --git a/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/et.js b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/et.js new file mode 100644 index 0000000000..c89b3ca71a --- /dev/null +++ b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/et.js @@ -0,0 +1,24 @@ +CKEDITOR.plugins.setLang('youtube', 'et', { + button : 'Lisa YouTube video', + title : 'YouTube video lisamine', + txtEmbed : 'Kleepige manustatud kood siia', + txtUrl : 'Kleepige YouTube video veebiaadress', + txtWidth : 'Laius', + txtHeight : 'Kõrgus', + chkRelated : 'Näita soovitatud videosi antud video lõppus', + txtStartAt : 'Alguskoht: (ss või mm:ss või hh:mm:ss)', + chkPrivacy : 'Aktiveerige privaatsust täiendav režiim', + chkOlderCode : 'Kasutage vana manuskoodi', + chkAutoplay: 'Automaatesitlus', + chkControls : 'Kuva pleieri nupud', + noCode : 'Te peate sisestama video manuskoodi või veebiaadressi', + invalidEmbed : 'Manuskood mille sisestasite ei paista olevat korrektne', + invalidUrl : 'Veebiaadress mille sisestasite ei paista olevat korrektne', + or : 'või', + noWidth : 'Te peate sisestama video laiuse', + invalidWidth : 'Sisestage korrektne laius', + noHeight : 'Te peate sisestama video kõrguse', + invalidHeight : 'Sisestage korrektne kõrgus', + invalidTime : 'Sisestage korrektne algusaeg', + txtResponsive : 'Aktiveerige ekraani laiusega ühilduv režiim' +}); diff --git a/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/eu.js b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/eu.js new file mode 100644 index 0000000000..d5abe816a1 --- /dev/null +++ b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/eu.js @@ -0,0 +1,25 @@ +CKEDITOR.plugins.setLang('youtube', 'eu', { + button : 'Kapsulatu YouTube-ko bideoa', + title : 'Kapsulatu YouTube-ko bideoa', + txtEmbed : 'Itsatsi kapsulatzeko kodea hemen', + txtUrl : 'Itsatsi YouTube-ko bideoaren URLa', + txtWidth : 'Zabalera', + txtHeight : 'Altuera', + chkRelated : 'Erakutsi gomendatutako bideoak amaieran', + txtStartAt : 'Hasi hemendik (ss edo mm:ss edo hh:mm:ss)', + chkPrivacy : 'Gaitu pribatutasun hobetuko modua', + chkOlderCode : 'Erabili kapsulatzeko kode zaharra', + chkAutoplay: 'Erreproduzitu automatikoki', + chkControls: 'Erakutsi erreproduzigailuaren kontrolak', + noCode : 'Kapsulatzeko kode bat edo URL bat sartu behar duzu', + invalidEmbed : 'Sartu duzun kapsulatzeko kodea ez da baliozkoa', + invalidUrl : 'Sartu duzun URLa ez da baliozkoa', + or : 'edo', + noWidth : 'Zabalera sartu behar duzu', + invalidWidth : 'Sartu baliozko zabalera bat', + noHeight : 'Altuera sartu behar duzu', + invalidHeight : 'Sartu baliozko altuera bat', + invalidTime : 'Sartu baliozko hasierako denbora bat', + txtResponsive : 'Egin moldagarria (ez ikusia egin zabalera eta altuerari, zabalerara doitu)', + txtNoEmbed : 'Bideoaren irudia eta esteka soilik' +}); diff --git a/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/fi.js b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/fi.js new file mode 100644 index 0000000000..cd7ec484be --- /dev/null +++ b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/fi.js @@ -0,0 +1,24 @@ +CKEDITOR.plugins.setLang('youtube', 'fi', { + button : 'Upota YouTube-video', + title : 'Upota YouTube-video', + txtEmbed : 'Syötä YouTube-videon upotuskoodi', + txtUrl : 'Syötä YouTube-videon www-osoite', + txtWidth : 'Leveys', + txtHeight : 'Korkeus', + chkRelated : 'Näytä suositukset lopussa', + txtStartAt : 'Aloitusaika (ss tai mm:ss tai tt:mm:ss)', + chkPrivacy : 'Aktivoi yksityisyyttä parantava tila', + chkOlderCode : 'Käytä vanhaa upotuskoodia', + chkAutoplay: 'Soita automaattisesti', + chkControls : 'Näytä soittimen ohjaimet', + noCode : 'Sinun täytyy syötää upotuskoodi tai www-osoite', + invalidEmbed : 'Upotuskoodi on virheellinen', + invalidUrl : 'Www-osoite on virheellinen', + or : 'tai', + noWidth : 'Syötä leveys', + invalidWidth : 'Leveys on virheellinen', + noHeight : 'Syötä korkeus', + invalidHeight : 'Korkeus on virheellinen', + invalidTime : 'Aloitusaika on virheellinen', + txtResponsive : 'Responsiivinen leveys (sovita leveys)' +}); \ No newline at end of file diff --git a/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/fr.js b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/fr.js new file mode 100644 index 0000000000..05e1866bda --- /dev/null +++ b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/fr.js @@ -0,0 +1,24 @@ +CKEDITOR.plugins.setLang('youtube', 'fr', { + button : 'Insérer une vidéo Youtube', + title : 'Insérer une vidéo youtube', + txtEmbed : 'Coller le code embed ici', + txtUrl : 'Coller l\'url de la vidéo ici', + txtWidth : 'Largeur', + txtHeight : 'Hauteur', + chkRelated : 'Montrer les suggestions de vidéo à la fin', + txtStartAt : 'Commencer à (ss ou mm:ss ou hh:mm:ss)', + chkPrivacy : 'Activer la protection de la vie privée', + chkOlderCode : 'Utiliser l\'ancien code embed', + chkAutoplay : 'Autoplay', + chkControls : 'Afficher les commandes du lecteur', + noCode : 'Vous devez entrer un code embed ou une url', + invalidEmbed : 'Le code embed est invalide', + invalidUrl : 'L\'url est invalide', + or : 'ou', + noWidth : 'Vous devez saisir une largeur', + invalidWidth : 'La largeur saisie est invalide', + noHeight : 'Vous devez saisir une hauteur', + invalidHeight : 'La hauteur saisie est invalide', + invalidTime : 'Le temps de départ de la vidéo est invalide', + txtResponsive : 'Responsive video' +}); diff --git a/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/he.js b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/he.js new file mode 100644 index 0000000000..f73009a449 --- /dev/null +++ b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/he.js @@ -0,0 +1,24 @@ +CKEDITOR.plugins.setLang('youtube', 'he', { + button : 'שבץ וידאו של YouTube', + title : 'שבץ וידאו של YouTube', + txtEmbed : 'הדבק את קוד השיבוץ כאן', + txtUrl : 'הדבק כתובת וידאו YouTube', + txtWidth : 'אורך', + txtHeight : 'גובה', + chkRelated : 'הצג סרטונים מומלצים בסוף הודיאו', + txtStartAt : 'התחל ב (ss או mm:ss או hh:mm:ss)', + chkPrivacy : 'הפעל מצב פרטיות המשופרת', + chkOlderCode : 'השתמש בקוד הטמעה ישן', + chkAutoplay: 'הפעלה אוטומטית', + chkControls : 'הצג פקדי נגן', + noCode : 'אתה חייב להזין קוד embed כתובת וידאו אתר', + invalidEmbed : 'קוד ההטמעה שהוזן אינו נראה חוקי', + invalidUrl : 'כתובת הוידאו אינה נראת חוקית', + or : 'או', + noWidth : 'חובה להזין אורך', + invalidWidth : 'האורך שהוזן שגוי', + noHeight : 'חובה להזין גובה', + invalidHeight : 'הגובה שהוזן שגוי', + invalidTime : 'זמן התחלה שהוזן שגוי', + txtResponsive : 'הפוך לרספונסיבי (התעלם מרוחב וגובה, התאם לרוחב)' +}); diff --git a/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/hu.js b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/hu.js new file mode 100644 index 0000000000..34e4bec880 --- /dev/null +++ b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/hu.js @@ -0,0 +1,24 @@ +CKEDITOR.plugins.setLang('youtube', 'hu', { + button : 'Youtube videó beillesztése', + title : 'Youtube videó beillesztése', + txtEmbed : 'Illessze be a beágyazott kódot', + txtUrl : 'Illessze be a Youtube videó URL-jét', + txtWidth : 'Szélesség', + txtHeight : 'Magasság', + txtStartAt : 'Kezdő időpont (ss vagy mm:ss vagy hh:mm:ss)', + chkRelated : 'Ajánlott videók megjelenítése, amikor a videó befejeződik', + chkPrivacy : 'Fokozott adatvédelmi mód engedélyezése', + chkOlderCode : 'Régi beágyazott kód használata', + chkAutoplay : 'Automatikus lejátszás', + chkControls : 'Lejátszásvezérlők mutatása', + noCode : 'A beágyazott kód, vagy az URL megadása kötelező', + invalidEmbed : 'A beágyazott kód érvénytelen', + invalidUrl : 'A megadott URL érvénytelen', + or : 'vagy', + noWidth : 'A szélesség megadása kötelező', + invalidWidth : 'Érvényes szélességet adjon meg', + noHeight : 'A magasság megadása kötelező', + invalidHeight : 'Érvényes magasságot adjon meg', + invalidTime : 'Érvényes kezdő időpontot adjon meg', + txtResponsive : 'Responsive video' +}); diff --git a/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/it.js b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/it.js new file mode 100644 index 0000000000..68b37d326a --- /dev/null +++ b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/it.js @@ -0,0 +1,24 @@ +CKEDITOR.plugins.setLang('youtube', 'it', { + button : 'Incorpora video Youtube', + title : 'Incorpora video Youtube', + txtEmbed : 'Incolla qui il codice di incorporamento', + txtUrl : 'Incolla l\'URL del video Youtube', + txtWidth : 'Larghezza', + txtHeight : 'Altezza', + chkRelated : 'Mostra i video suggeriti dopo il video', + txtStartAt : 'Inizia a (ss o mm:ss o hh:mm:ss)', + chkPrivacy : 'Abilita la protezione della privacy', + chkOlderCode : 'Usa il vecchio codice di incorporamento', + chkAutoplay : 'Autoplay', + chkControls : 'Mostra i controlli del player', + noCode : 'Devi inserire un codice di incorporamento o un URL', + invalidEmbed : 'Il codice di incorporamento inserito non sembra valido', + invalidUrl : 'L\'URL inserito non sembra valido', + or : 'o', + noWidth : 'Devi indicare la larghezza', + invalidWidth : 'Indica una larghezza valida', + noHeight : 'Devi indicare l\'altezza', + invalidHeight : 'Indica un\'altezza valida', + invalidTime : 'Indica un tempo di inizio valido', + txtResponsive : 'Responsive video' +}); diff --git a/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/ja.js b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/ja.js new file mode 100644 index 0000000000..4e2b1d1641 --- /dev/null +++ b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/ja.js @@ -0,0 +1,24 @@ +CKEDITOR.plugins.setLang('youtube', 'ja', { + button : 'Youtube動画埋め込み', + title : 'Youtube動画埋め込み', + txtEmbed : '埋め込みコードを貼り付けてください', + txtUrl : 'URLを貼り付けてください', + txtWidth : '幅', + txtHeight : '高さ', + chkRelated : '動画が終わったら関連動画を表示する', + txtStartAt : '開始時間(秒)', + chkPrivacy : 'プライバシー強化モードを有効にする', + chkOlderCode : '以前の埋め込みコードを使用する', + chkAutoplay : '自動再生', + chkControls: 'プレーヤーのコントロールを表示する', + noCode : '埋め込みコードまたはURLを入力してください', + invalidEmbed : '不適切な埋め込みコードが入力されました', + invalidUrl : '不適切なURLが入力されました', + or : 'または', + noWidth : '幅を指定してください', + invalidWidth : '幅指定に誤りがあります', + noHeight : '高さを指定してください', + invalidHeight : '高さ指定に誤りがあります', + invalidTime : '開始時間を正の整数で入力してください', + txtResponsive : 'レスポンシブ表示' +}); diff --git a/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/ko.js b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/ko.js new file mode 100644 index 0000000000..335c5a3b2d --- /dev/null +++ b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/ko.js @@ -0,0 +1,25 @@ +CKEDITOR.plugins.setLang('youtube', 'ko', { + button : '유투브 비디오 삽입', + title : '유투브 비디오 삽입', + txtEmbed : '여기 embed 코드를 붙여넣으세요', + txtUrl : '유투브 주소(URL)를 붙여넣으세요', + txtWidth : '너비', + txtHeight : '높이', + chkRelated : '비디오 마지막에 추천 영상 보이기', + txtStartAt : '시작 시점 (ss 또는 mm:ss 또는 hh:mm:ss)', + chkPrivacy : '개인정보 보호 모드 활성화', + chkOlderCode : '옛날 embed 코드 사용', + chkAutoplay: '자동 재생', + chkControls: '플레이어 컨트롤 표시', + noCode : 'embed 코드 또는 URL을 입력해야 합니다', + invalidEmbed : '입력하신 embed 코드가 유효하지 않습니다', + invalidUrl : '입력하신 주소(URL)가 유효하지 않습니다', + or : '또는', + noWidth : '너비를 알려주세요', + invalidWidth : '너비가 유효하지 않습니다', + noHeight : '높이를 알려주세요', + invalidHeight : '높이가 유효하지 않습니다', + invalidTime : '시작 시점이 유효하지 않습니다', + txtResponsive : '반응형 너비 (입력한 너비와 높이를 무시하고 창 너비에 맞춤)', + txtNoEmbed : '비디오 이미지와 링크만 달기' +}); diff --git a/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/nb.js b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/nb.js new file mode 100644 index 0000000000..3a5afc2861 --- /dev/null +++ b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/nb.js @@ -0,0 +1,24 @@ +CKEDITOR.plugins.setLang('youtube', 'nb', { + button : 'Bygg inn YouTube-video', + title : 'Bygg inn YouTube-video', + txtEmbed : 'Lim inn embed-kode her', + txtUrl : 'Lim inn YouTube video-URL', + txtWidth : 'Bredde', + txtHeight : 'Høyde', + chkRelated : 'Vis foreslåtte videoer når videoen er ferdig', + txtStartAt : 'Start ved (ss eller mm:ss eller hh:mm:ss)', + chkPrivacy : 'Bruk personverntilpasset modus', + chkOlderCode : 'Bruk gammel embedkode', + chkAutoplay: 'Spill automatisk', + chkControls: 'Vis spillerkontrollene', + noCode : 'Du må legge inn en embed-kode eller URL', + invalidEmbed : 'Emded-koden du la inn ser ikke ut til å være gyldig', + invalidUrl : 'URLen du la inn ser ikke ut til å være gyldig', + or : 'eller', + noWidth : 'Du må legge inn bredde', + invalidWidth : 'Legg inn en gyldig bredde', + noHeight : 'Du må legge inn høyde', + invalidHeight : 'Legg inn en gyldig høyde', + invalidTime : 'Legg inn gyldig starttid', + txtResponsive : 'Gjør responsiv (ignorer bredde og høyde, tilpass bredde på sida)' +}); diff --git a/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/nl.js b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/nl.js new file mode 100644 index 0000000000..6b2c65a03d --- /dev/null +++ b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/nl.js @@ -0,0 +1,25 @@ +CKEDITOR.plugins.setLang('youtube', 'nl', { + button : 'Youtube video insluiten', + title : 'Youtube video insluiten', + txtEmbed : 'Plak embedcode hier', + txtUrl : 'Plak video URL', + txtWidth : 'Breedte', + txtHeight : 'Hoogte', + chkRelated : 'Toon gesuggereerde video aan het einde van de video', + txtStartAt : 'Starten op (ss of mm:ss of hh:mm:ss)', + chkPrivacy : 'Privacy-enhanced mode inschakelen', + chkOlderCode : 'Gebruik oude embedcode', + chkAutoplay: 'Automatisch starten', + chkControls: 'Afspeelbediening weergeven', + noCode : 'U moet een embedcode of url ingeven', + invalidEmbed : 'De ingegeven embedcode lijkt niet geldig', + invalidUrl : 'De ingegeven url lijkt niet geldig', + or : 'of', + noWidth : 'U moet een breedte ingeven', + invalidWidth : 'U moet een geldige breedte ingeven', + noHeight : 'U moet een hoogte ingeven', + invalidHeight : 'U moet een geldige starttijd ingeven', + invalidTime : 'Inform a valid start time', + txtResponsive : 'Responsive video', + txtNoEmbed : 'Alleen video afbeelding en link' +}); diff --git a/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/nn.js b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/nn.js new file mode 100644 index 0000000000..7efc3ba0eb --- /dev/null +++ b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/nn.js @@ -0,0 +1,24 @@ +CKEDITOR.plugins.setLang('youtube', 'nn', { + button : 'Bygg inn YouTube-video', + title : 'Bygg inn YouTube-video', + txtEmbed : 'Lim inn embed-kode her', + txtUrl : 'Lim inn YouTube video-URL', + txtWidth : 'Breidde', + txtHeight : 'Høgde', + chkRelated : 'Vis foreslåtte videoar når videoen er ferdig', + txtStartAt : 'Start ved (ss eller mm:ss eller hh:mm:ss)', + chkPrivacy : 'Bruk personverntilpassa modus', + chkOlderCode : 'Bruk gamal embedkode', + chkAutoplay: 'Spel automatisk', + chkControls: 'Vis spillerkontrollene', + noCode : 'Du må leggja inn ein embed-kode eller URL', + invalidEmbed : 'Emded-koden du la inn ser ikkje ut til å vera gyldig', + invalidUrl : 'URLen du la inn ser ikkje ut til å vera gyldig', + or : 'eller', + noWidth : 'Du må leggja inn breidde', + invalidWidth : 'Legg inn ei gyldig breidde', + noHeight : 'Du må leggja inn høgde', + invalidHeight : 'Legg inn ei gyldig høgde', + invalidTime : 'Legg inn gyldig starttid', + txtResponsive : 'Gjer responsiv (ignorer breidde og høgde, tilpass breidda på sida)' +}); diff --git a/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/pl.js b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/pl.js new file mode 100644 index 0000000000..6470c2152f --- /dev/null +++ b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/pl.js @@ -0,0 +1,24 @@ +CKEDITOR.plugins.setLang('youtube', 'pl', { + button : 'Załącznik wideo z YouTube', + title : 'Załącznik wideo z YouTube', + txtEmbed : 'Wklej kod do umieszczenia', + txtUrl : 'Wklej adres URL do wideo z YouTube', + txtWidth : 'Szerokość', + txtHeight : 'Wysokość', + chkRelated : 'Pokaż sugerowane filmy po zakończeniu odtwarzania', + txtStartAt : 'Rozpocznij od (ss lub mm:ss lub gg:mm:ss)', + chkPrivacy : 'Włącz rozszerzony tryb prywatności', + chkOlderCode : 'Użyj starego kodu', + chkAutoplay: 'Autoodtwarzanie', + chkControls: 'Pokaż elementy sterujące odtwarzacza', + noCode : 'Musisz wprowadzić kod lub adres URL', + invalidEmbed : 'Wprowadzony kod nie jest poprawny', + invalidUrl : 'Wprowadzony adres URL nie jest poprawny', + or : 'lub', + noWidth : 'Musisz wpisać szerokość', + invalidWidth : 'Wprowadzona szerokość nie jest poprawna', + noHeight : 'Musisz wprowadzić wysokość', + invalidHeight : 'Wprowadzona wysokość nie jest poprawna', + invalidTime : 'Musisz wprowadzić poprawny czas rozpoczęcia', + txtResponsive : 'El. responsywny (ignoruj szerokość i wysokość, dopasuj do szerokości)' +}); \ No newline at end of file diff --git a/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/pt-br.js b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/pt-br.js new file mode 100644 index 0000000000..52cda7c007 --- /dev/null +++ b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/pt-br.js @@ -0,0 +1,25 @@ +CKEDITOR.plugins.setLang('youtube', 'pt-br', { + button : 'Inserir Vídeo do Youtube', + title : 'Inserir Vídeo do Youtube', + txtEmbed : 'Cole aqui o código embed de um vídeo do Youtube', + txtUrl : 'Cole aqui uma URL de um vídeo do Youtube', + txtWidth : 'Largura', + txtHeight : 'Altura', + chkRelated : 'Mostrar vídeos sugeridos ao final do vídeo', + txtStartAt : 'Iniciar em (ss ou mm:ss ou hh:mm:ss)', + chkPrivacy : 'Ativar o modo de privacidade aprimorada', + chkOlderCode : 'Usar código de incorporação antigo', + chkAutoplay : 'Reproduzir automaticamente', + chkControls: 'Mostrar controles do player', + noCode : 'Você precisa informar um código embed ou uma URL', + invalidEmbed : 'O código informado não parece ser válido', + invalidUrl : 'A URL informada não parece ser válida', + or : 'ou', + noWidth : 'Você deve informar a largura do vídeo', + invalidWidth : 'Informe uma largura válida', + noHeight : 'Você deve informar a altura do vídeo', + invalidHeight : 'Informe uma altura válida', + invalidTime : 'O tempo informado é inválido', + txtResponsive : 'Vídeo responsivo', + txtNoEmbed : 'Somente imagem e link para o vídeo' +}); diff --git a/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/pt.js b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/pt.js new file mode 100644 index 0000000000..6043b8ee02 --- /dev/null +++ b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/pt.js @@ -0,0 +1,25 @@ +CKEDITOR.plugins.setLang('youtube', 'pt', { + button : 'Inserir Vídeo do Youtube', + title : 'Inserir Vídeo do Youtube', + txtEmbed : 'Cole aqui o código embed de um vídeo do Youtube', + txtUrl : 'Cole aqui uma URL de um vídeo do Youtube', + txtWidth : 'Largura', + txtHeight : 'Altura', + chkRelated : 'Mostrar vídeos sugeridos quando o vídeo terminar', + txtStartAt : 'Iniciar em (ss ou mm:ss ou hh:mm:ss)', + chkPrivacy : 'Ativar o modo de privacidade otimizada', + chkOlderCode : 'Usar código de incorporação antigo', + chkAutoplay : 'Reproduzir automaticamente', + chkControls: 'Mostrar controles do player', + noCode : 'Você precisa informar um código embed ou uma URL', + invalidEmbed : 'O código informado não parece ser válido', + invalidUrl : 'A URL informada não parece ser válida', + or : 'ou', + noWidth : 'Você deve informar a largura do vídeo', + invalidWidth : 'Informe uma largura válida', + noHeight : 'Você deve informar a altura do vídeo', + invalidHeight : 'Informe uma altura válida', + invalidTime : 'O tempo informado é inválido', + txtResponsive : 'Vídeo responsivo', + txtNoEmbed : 'Somente imagem e link para o vídeo' +}); diff --git a/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/ru.js b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/ru.js new file mode 100644 index 0000000000..6637f4ac04 --- /dev/null +++ b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/ru.js @@ -0,0 +1,25 @@ +CKEDITOR.plugins.setLang('youtube', 'ru', { + button : 'Вставить YouTube видео', + title : 'Вставить YouTube видео', + txtEmbed : 'Вставьте HTML-код сюда', + txtUrl : 'Вставьте адрес видео (URL)', + txtWidth : 'Ширина', + txtHeight : 'Высота', + chkRelated : 'Показать похожие видео после завершения просмотра', + txtStartAt : 'Начать с (сс или мм:сс или чч:мм:сс)', + chkPrivacy : 'Включить режим повышенной конфиденциальности', + chkOlderCode : 'Использовать старый код вставки', + chkAutoplay: 'Автозапуск', + chkControls: 'Показать панель управления', + noCode : 'Вы должны ввести HTML-код или адрес', + invalidEmbed : 'Ваш HTML-код не похож на правильный', + invalidUrl : 'Ваш адрес видео не похож на правильный', + or : 'или', + noWidth : 'Вы должны указать ширину', + invalidWidth : 'Укажите правильную ширину', + noHeight : 'Вы должны указать высоту', + invalidHeight : 'Укажите правильную высоту', + invalidTime : 'Укажите правильное время начала', + txtResponsive : 'Растягиваемое видео', + txtNoEmbed : 'Не встраивать видео (обложка-ссылка на YouTube)' +}); diff --git a/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/sk.js b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/sk.js new file mode 100644 index 0000000000..e7f93ad686 --- /dev/null +++ b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/sk.js @@ -0,0 +1,24 @@ +CKEDITOR.plugins.setLang('youtube', 'sk', { + button : 'Vložiť YouTube video', + title : 'Vložiť YouTube video', + txtEmbed : 'Vložiť Youtube Embed Video kódu', + txtUrl : 'Vložiť pomocou YouTube video URL', + txtWidth : 'Šírka', + txtHeight : 'Výška', + chkRelated : 'Zobraziť odporúčané videá po prehratí', + txtStartAt : 'Začať prehrávanie videa (ss alebo mm:ss alebo hh:mm:ss)', + chkPrivacy : 'Povoliť pokročilý mód súkromia', + chkOlderCode : 'Použiť starú metódu vkladania', + chkAutoplay: 'Automatické prehrávanie', + chkControls: 'Zobraziť ovládacie prvky prehrávača', + noCode : 'Musíte vložiť Youtube Embed kód alebo URL', + invalidEmbed : 'Vložený kód nie je valídny', + invalidUrl : 'Vložená URL nie je platná', + or : 'alebo', + noWidth : 'Prosím, zadajte šírku videa', + invalidWidth : 'Zadajte valídnu šírku videa', + noHeight : 'Prosím, zadajte výšku videa', + invalidHeight : 'Zadajte valídnu výšku videa', + invalidTime : 'Zadajte valídny formát začiatku prehrávania videa', + txtResponsive : 'Prispôsobit rozmery videa rozmerom obrazovky (ignoruje šírku a výšku, prispôsobí sa šírke obrazovky)' +}); diff --git a/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/tr.js b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/tr.js new file mode 100644 index 0000000000..86086919d7 --- /dev/null +++ b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/tr.js @@ -0,0 +1,24 @@ +CKEDITOR.plugins.setLang('youtube', 'tr', { + button : 'Youtube Video Gömün (Embed)', + title : 'Youtube Video', + txtEmbed : 'Youtube gömülü kodu (embed) buraya yapıştırınız', + txtUrl : 'Youtube linkinizi buraya yapıştırınız', + txtWidth : 'Genişlik', + txtHeight : 'Yükseklik', + chkRelated : 'Önerilen videoları video bitiminde göster', + txtStartAt : 'Video başlangıç anı (ss ya da dd:ss ya da ss:dd:ss)', + chkPrivacy : 'Gizlilik modunu etkinleştir', + chkOlderCode : 'Eski gömülü kodu (embed) kullan', + chkAutoplay: 'Otomatik', + chkControls: 'Oynatıcı kontrollerini göster', + noCode : 'Gömülü kod (embed) veya url yapıştırmak zorundasınız', + invalidEmbed : 'Verdiğiniz gömülü kod (embed) ile video bulunamadı', + invalidUrl : 'Verdiğiniz linkte video bulunamadı', + or : 'ya da', + noWidth : 'Genişliği belirtmek zorundasınız', + invalidWidth : 'Bir genişlik belirtin', + noHeight : 'Yükseliği belirtmek zorundasınız', + invalidHeight : 'Yükseklik belirtin', + invalidTime : 'Başlangıç anını doğru girin, örneğin: 13 (13. saniye) ya da 12:25 (12. dakika 25. saniye) ya da 01.25.33 (1 saat 25 dakika 33 saniye)', + txtResponsive : 'Responsive video' +}); diff --git a/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/vi.js b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/vi.js new file mode 100644 index 0000000000..8d95d22f9f --- /dev/null +++ b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/vi.js @@ -0,0 +1,24 @@ +CKEDITOR.plugins.setLang('youtube', 'vi', { + button : 'Embed Youtube Video', + title : 'Nhúng Video Youtube', + txtEmbed : 'Dãn mã nhúng Embed vào đây', + txtUrl : 'Dãn đường dẫn video Youtube', + txtWidth : 'Rộng', + txtHeight : 'Cao', + chkRelated : 'Hiển thị các video được đề xuất khi video kết thúc', + txtStartAt : 'Bắt đầu (ss hoặc mm:ss hoặc hh:mm:ss)', + chkPrivacy : 'Kích hoạt chế độ bảo mật nâng cao', + chkOlderCode : 'Sử dụng mã nhúng cũ', + chkAutoplay: 'Tự động chạy video', + chkControls: 'Hiển thị các điều khiển trình phát', + noCode : 'Bạn phải nhập mã nhúng hoặc URL', + invalidEmbed : 'Mã nhúng bạn đã nhập không đúng', + invalidUrl : 'URL bạn đã nhập không đúng', + or : 'hoặc', + noWidth : 'Bạn phải chiều rộng', + invalidWidth : 'Chiều rộng hợp lệ', + noHeight : 'Bạn phải chiều cao', + invalidHeight : 'Chiều cao hợp lệ', + invalidTime : 'Thời gian bắt đầu không đúng', + txtResponsive : 'Responsive video' +}); diff --git a/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/zh.js b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/zh.js new file mode 100644 index 0000000000..dfab8be633 --- /dev/null +++ b/main/inc/lib/javascript/ckeditor/plugins/youtube/lang/zh.js @@ -0,0 +1,24 @@ +CKEDITOR.plugins.setLang('youtube', 'zh', { + button: '嵌入 Youtube 影片', + title: '嵌入 Youtube 影片', + txtEmbed: '貼上嵌入碼', + txtUrl: '貼上 Youtube 影片 URL', + txtWidth: '寬', + txtHeight: '高', + txtResponsive: '使用自適應縮放模式 (忽略設定的長寬, 以寬為基準縮放)', + chkRelated: '影片結束時顯示建議影片', + txtStartAt: '開始時間 (ss or mm:ss or hh:mm:ss)', + chkPrivacy: '啟用加強隱私模式', + chkOlderCode: '使用舊的嵌入碼', + chkAutoplay: '自動播放', + chkControls: '显示播放器控件', + noCode: '必須輸入嵌入碼', + invalidEmbed: '錯誤的嵌入碼', + invalidUrl: '錯誤的URL', + or: '或', + noWidth: '必須設定寬', + invalidWidth: '寬設定錯誤', + noHeight: '必須設定高', + invalidHeight: '高設定錯誤', + invalidTime: '開始時間設定錯誤' +}); diff --git a/main/inc/lib/javascript/ckeditor/plugins/youtube/plugin.js b/main/inc/lib/javascript/ckeditor/plugins/youtube/plugin.js new file mode 100644 index 0000000000..e86563c079 --- /dev/null +++ b/main/inc/lib/javascript/ckeditor/plugins/youtube/plugin.js @@ -0,0 +1,448 @@ +/* +* Youtube Embed Plugin +* +* @author Jonnas Fonini +* @version 2.1.8 +*/ +(function () { + CKEDITOR.plugins.add('youtube', { + lang: [ 'en', 'pt', 'pt-br', 'ja', 'hu', 'it', 'fr', 'tr', 'ru', 'de', 'ar', 'nl', 'pl', 'vi', 'zh', 'el', 'he', 'es', 'nb', 'nn', 'fi', 'et', 'sk', 'cs', 'ko', 'eu' ], + init: function (editor) { + editor.addCommand('youtube', new CKEDITOR.dialogCommand('youtube', { + allowedContent: 'div{*}(*); iframe{*}[!width,!height,!src,!frameborder,!allowfullscreen]; object param[*]; a[*]; img[*]' + })); + + editor.ui.addButton('Youtube', { + label : editor.lang.youtube.button, + toolbar : 'insert', + command : 'youtube', + icon : this.path + 'images/icon.png' + }); + + CKEDITOR.dialog.add('youtube', function (instance) { + var video, + disabled = editor.config.youtube_disabled_fields || []; + + return { + title : editor.lang.youtube.title, + minWidth : 510, + minHeight : 200, + onShow: function () { + for (var i = 0; i < disabled.length; i++) { + this.getContentElement('youtubePlugin', disabled[i]).disable(); + } + }, + contents : + [{ + id : 'youtubePlugin', + expand : true, + elements : + [{ + id : 'txtEmbed', + type : 'textarea', + label : editor.lang.youtube.txtEmbed, + onChange : function (api) { + handleEmbedChange(this, api); + }, + onKeyUp : function (api) { + handleEmbedChange(this, api); + }, + validate : function () { + if (this.isEnabled()) { + if (!this.getValue()) { + alert(editor.lang.youtube.noCode); + return false; + } + else + if (this.getValue().length === 0 || this.getValue().indexOf('//') === -1) { + alert(editor.lang.youtube.invalidEmbed); + return false; + } + } + } + }, + { + type : 'html', + html : editor.lang.youtube.or + '
' + }, + { + type : 'hbox', + widths : [ '70%', '15%', '15%' ], + children : + [ + { + id : 'txtUrl', + type : 'text', + label : editor.lang.youtube.txtUrl, + onChange : function (api) { + handleLinkChange(this, api); + }, + onKeyUp : function (api) { + handleLinkChange(this, api); + }, + validate : function () { + if (this.isEnabled()) { + if (!this.getValue()) { + alert(editor.lang.youtube.noCode); + return false; + } + else{ + video = ytVidId(this.getValue()); + + if (this.getValue().length === 0 || video === false) + { + alert(editor.lang.youtube.invalidUrl); + return false; + } + } + } + } + }, + { + type : 'text', + id : 'txtWidth', + width : '60px', + label : editor.lang.youtube.txtWidth, + 'default' : editor.config.youtube_width != null ? editor.config.youtube_width : '640', + validate : function () { + if (this.getValue()) { + var width = parseInt (this.getValue()) || 0; + + if (width === 0) { + alert(editor.lang.youtube.invalidWidth); + return false; + } + } + else { + alert(editor.lang.youtube.noWidth); + return false; + } + } + }, + { + type : 'text', + id : 'txtHeight', + width : '60px', + label : editor.lang.youtube.txtHeight, + 'default' : editor.config.youtube_height != null ? editor.config.youtube_height : '360', + validate : function () { + if (this.getValue()) { + var height = parseInt(this.getValue()) || 0; + + if (height === 0) { + alert(editor.lang.youtube.invalidHeight); + return false; + } + } + else { + alert(editor.lang.youtube.noHeight); + return false; + } + } + } + ] + }, + { + type : 'hbox', + widths : [ '55%', '45%' ], + children : + [ + { + id : 'chkResponsive', + type : 'checkbox', + label : editor.lang.youtube.txtResponsive, + 'default' : editor.config.youtube_responsive != null ? editor.config.youtube_responsive : false + }, + { + id : 'chkNoEmbed', + type : 'checkbox', + label : editor.lang.youtube.txtNoEmbed, + 'default' : editor.config.youtube_noembed != null ? editor.config.youtube_noembed : false + } + ] + }, + { + type : 'hbox', + widths : [ '55%', '45%' ], + children : + [ + { + id : 'chkRelated', + type : 'checkbox', + 'default' : editor.config.youtube_related != null ? editor.config.youtube_related : true, + label : editor.lang.youtube.chkRelated + }, + { + id : 'chkOlderCode', + type : 'checkbox', + 'default' : editor.config.youtube_older != null ? editor.config.youtube_older : false, + label : editor.lang.youtube.chkOlderCode + } + ] + }, + { + type : 'hbox', + widths : [ '55%', '45%' ], + children : + [ + { + id : 'chkPrivacy', + type : 'checkbox', + label : editor.lang.youtube.chkPrivacy, + 'default' : editor.config.youtube_privacy != null ? editor.config.youtube_privacy : false + }, + { + id : 'chkAutoplay', + type : 'checkbox', + 'default' : editor.config.youtube_autoplay != null ? editor.config.youtube_autoplay : false, + label : editor.lang.youtube.chkAutoplay + } + ] + }, + { + type : 'hbox', + widths : [ '55%', '45%'], + children : + [ + { + id : 'txtStartAt', + type : 'text', + label : editor.lang.youtube.txtStartAt, + validate : function () { + if (this.getValue()) { + var str = this.getValue(); + + if (!/^(?:(?:([01]?\d|2[0-3]):)?([0-5]?\d):)?([0-5]?\d)$/i.test(str)) { + alert(editor.lang.youtube.invalidTime); + return false; + } + } + } + }, + { + id : 'chkControls', + type : 'checkbox', + 'default' : editor.config.youtube_controls != null ? editor.config.youtube_controls : true, + label : editor.lang.youtube.chkControls + } + ] + } + ] + } + ], + onOk: function() + { + var content = ''; + var responsiveStyle = ''; + + if (this.getContentElement('youtubePlugin', 'txtEmbed').isEnabled()) { + content = this.getValueOf('youtubePlugin', 'txtEmbed'); + } + else { + var url = 'https://', params = [], startSecs; + var width = this.getValueOf('youtubePlugin', 'txtWidth'); + var height = this.getValueOf('youtubePlugin', 'txtHeight'); + + if (this.getContentElement('youtubePlugin', 'chkPrivacy').getValue() === true) { + url += 'www.youtube-nocookie.com/'; + } + else { + url += 'www.youtube.com/'; + } + + url += 'embed/' + video; + + if (this.getContentElement('youtubePlugin', 'chkRelated').getValue() === false) { + params.push('rel=0'); + } + + if (this.getContentElement('youtubePlugin', 'chkAutoplay').getValue() === true) { + params.push('autoplay=1'); + } + + if (this.getContentElement('youtubePlugin', 'chkControls').getValue() === false) { + params.push('controls=0'); + } + + startSecs = this.getValueOf('youtubePlugin', 'txtStartAt'); + + if (startSecs) { + var seconds = hmsToSeconds(startSecs); + + params.push('start=' + seconds); + } + + if (params.length > 0) { + url = url + '?' + params.join('&'); + } + + if (this.getContentElement('youtubePlugin', 'chkResponsive').getValue() === true) { + content += '
'; + responsiveStyle = 'style="position:absolute;top:0;left:0;width:100%;height:100%"'; + } + + if (this.getContentElement('youtubePlugin', 'chkOlderCode').getValue() === true) { + url = url.replace('embed/', 'v/'); + url = url.replace(/&/g, '&'); + + if (url.indexOf('?') === -1) { + url += '?'; + } + else { + url += '&'; + } + url += 'hl=' + (this.getParentEditor().config.language ? this.getParentEditor().config.language : 'en') + '&version=3'; + + content += ''; + content += ''; + content += ''; + content += ''; + content += ''; + } + else { + content += '