Index: lams_central/web/ckeditor/README.md =================================================================== diff -u -r80be094030483dbe5d093595a0f49d533c8ad00f -rdca7fef745b8fcefbfd8aeba9df093b5ae204b0a --- lams_central/web/ckeditor/README.md (.../README.md) (revision 80be094030483dbe5d093595a0f49d533c8ad00f) +++ lams_central/web/ckeditor/README.md (.../README.md) (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -312,4 +312,9 @@ ``` type:CKEDITOR.NODE_ELEMENT,addClass:g?function(a){if(a)this.$.classList.(a);return this} ``` -(As in [https://code.lamsfoundation.org/fisheye/changelog/lams-github?cs=cfec5d4c0ffe681e5e2604dc1163b309974e21f0](https://code.lamsfoundation.org/fisheye/changelog/lams-github?cs=cfec5d4c0ffe681e5e2604dc1163b309974e21f0)) \ No newline at end of file +(As in [https://code.lamsfoundation.org/fisheye/changelog/lams-github?cs=cfec5d4c0ffe681e5e2604dc1163b309974e21f0](https://code.lamsfoundation.org/fisheye/changelog/lams-github?cs=cfec5d4c0ffe681e5e2604dc1163b309974e21f0)) + +- Add wordcount and notification plugins +These plugins are required for checking max word count in essay questions. +They are a part of CKEditor build file already, but they can be added manually too. +The sking office2013 does not have a notification.css file nor its import is added to editor.css. It can be taken from existing LAMS code or directly from another skin. \ No newline at end of file Index: lams_central/web/ckeditor/build-config.js =================================================================== diff -u -r5727272c3f2b0021f872d499995b3f4b82738274 -rdca7fef745b8fcefbfd8aeba9df093b5ae204b0a --- lams_central/web/ckeditor/build-config.js (.../build-config.js) (revision 5727272c3f2b0021f872d499995b3f4b82738274) +++ lams_central/web/ckeditor/build-config.js (.../build-config.js) (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -89,6 +89,8 @@ 'list' : 1, 'liststyle' : 1, 'maximize' : 1, + 'maxwords' : 1, + 'notification' : 1, 'pastefromword' : 1, 'preview' : 1, 'resize' : 1, Index: lams_central/web/ckeditor/plugins/notification/lang/az.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/lang/az.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/lang/az.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,7 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ +CKEDITOR.plugins.setLang( 'notification', 'az', { + closed: 'Xəbərdarlıq pəncərəsi bağlanıb' +} ); Index: lams_central/web/ckeditor/plugins/notification/lang/bg.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/lang/bg.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/lang/bg.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,7 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ +CKEDITOR.plugins.setLang( 'notification', 'bg', { + closed: 'Известието е затворено.' +} ); Index: lams_central/web/ckeditor/plugins/notification/lang/ca.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/lang/ca.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/lang/ca.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,7 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ +CKEDITOR.plugins.setLang( 'notification', 'ca', { + closed: 'Notificació tancada.' +} ); Index: lams_central/web/ckeditor/plugins/notification/lang/cs.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/lang/cs.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/lang/cs.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,7 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ +CKEDITOR.plugins.setLang( 'notification', 'cs', { + closed: 'Oznámení zavřeno.' +} ); Index: lams_central/web/ckeditor/plugins/notification/lang/da.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/lang/da.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/lang/da.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,7 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ +CKEDITOR.plugins.setLang( 'notification', 'da', { + closed: 'Notifikation lukket.' +} ); Index: lams_central/web/ckeditor/plugins/notification/lang/de-ch.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/lang/de-ch.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/lang/de-ch.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,7 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ +CKEDITOR.plugins.setLang( 'notification', 'de-ch', { + closed: 'Benachrichtigung geschlossen.' +} ); Index: lams_central/web/ckeditor/plugins/notification/lang/de.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/lang/de.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/lang/de.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,7 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ +CKEDITOR.plugins.setLang( 'notification', 'de', { + closed: 'Benachrichtigung geschlossen.' +} ); Index: lams_central/web/ckeditor/plugins/notification/lang/en-au.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/lang/en-au.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/lang/en-au.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,7 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ +CKEDITOR.plugins.setLang( 'notification', 'en-au', { + closed: 'Notification closed.' +} ); Index: lams_central/web/ckeditor/plugins/notification/lang/en.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/lang/en.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/lang/en.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,7 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ +CKEDITOR.plugins.setLang( 'notification', 'en', { + closed: 'Notification closed.' +} ); Index: lams_central/web/ckeditor/plugins/notification/lang/eo.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/lang/eo.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/lang/eo.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,7 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ +CKEDITOR.plugins.setLang( 'notification', 'eo', { + closed: 'Sciigo fermita' +} ); Index: lams_central/web/ckeditor/plugins/notification/lang/es-mx.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/lang/es-mx.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/lang/es-mx.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,7 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ +CKEDITOR.plugins.setLang( 'notification', 'es-mx', { + closed: 'Notificación cerrada.' +} ); Index: lams_central/web/ckeditor/plugins/notification/lang/es.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/lang/es.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/lang/es.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,7 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ +CKEDITOR.plugins.setLang( 'notification', 'es', { + closed: 'Notificación cerrada.' +} ); Index: lams_central/web/ckeditor/plugins/notification/lang/et.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/lang/et.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/lang/et.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,7 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ +CKEDITOR.plugins.setLang( 'notification', 'et', { + closed: 'Teavitused on suletud.' +} ); Index: lams_central/web/ckeditor/plugins/notification/lang/eu.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/lang/eu.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/lang/eu.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,7 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ +CKEDITOR.plugins.setLang( 'notification', 'eu', { + closed: 'Jakinarazpena itxita.' +} ); Index: lams_central/web/ckeditor/plugins/notification/lang/fa.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/lang/fa.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/lang/fa.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,7 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ +CKEDITOR.plugins.setLang( 'notification', 'fa', { + closed: 'آگاه‌سازی بسته شد' +} ); Index: lams_central/web/ckeditor/plugins/notification/lang/fr.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/lang/fr.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/lang/fr.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,7 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ +CKEDITOR.plugins.setLang( 'notification', 'fr', { + closed: 'Notification fermée.' +} ); Index: lams_central/web/ckeditor/plugins/notification/lang/gl.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/lang/gl.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/lang/gl.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,7 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ +CKEDITOR.plugins.setLang( 'notification', 'gl', { + closed: 'Notificación pechada.' +} ); Index: lams_central/web/ckeditor/plugins/notification/lang/hr.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/lang/hr.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/lang/hr.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,7 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ +CKEDITOR.plugins.setLang( 'notification', 'hr', { + closed: 'Obavijest zatvorena.' +} ); Index: lams_central/web/ckeditor/plugins/notification/lang/hu.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/lang/hu.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/lang/hu.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,7 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ +CKEDITOR.plugins.setLang( 'notification', 'hu', { + closed: 'Értesítés bezárva.' +} ); Index: lams_central/web/ckeditor/plugins/notification/lang/id.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/lang/id.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/lang/id.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,7 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ +CKEDITOR.plugins.setLang( 'notification', 'id', { + closed: 'Pemberitahuan ditutup' +} ); Index: lams_central/web/ckeditor/plugins/notification/lang/it.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/lang/it.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/lang/it.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,7 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ +CKEDITOR.plugins.setLang( 'notification', 'it', { + closed: 'Notifica chiusa.' +} ); Index: lams_central/web/ckeditor/plugins/notification/lang/ja.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/lang/ja.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/lang/ja.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,7 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ +CKEDITOR.plugins.setLang( 'notification', 'ja', { + closed: '通知を閉じました。' +} ); Index: lams_central/web/ckeditor/plugins/notification/lang/km.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/lang/km.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/lang/km.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,7 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ +CKEDITOR.plugins.setLang( 'notification', 'km', { + closed: 'បាន​បិទ​ការ​ផ្ដល់​ដំណឹង។' +} ); Index: lams_central/web/ckeditor/plugins/notification/lang/ko.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/lang/ko.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/lang/ko.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,7 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ +CKEDITOR.plugins.setLang( 'notification', 'ko', { + closed: '알림이 닫힘.' +} ); Index: lams_central/web/ckeditor/plugins/notification/lang/ku.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/lang/ku.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/lang/ku.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,7 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ +CKEDITOR.plugins.setLang( 'notification', 'ku', { + closed: 'ئاگادارکەرەوەکە داخرا.' +} ); Index: lams_central/web/ckeditor/plugins/notification/lang/lt.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/lang/lt.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/lang/lt.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,7 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ +CKEDITOR.plugins.setLang( 'notification', 'lt', { + closed: 'Pranešimas uždarytas.' +} ); Index: lams_central/web/ckeditor/plugins/notification/lang/lv.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/lang/lv.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/lang/lv.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,7 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ +CKEDITOR.plugins.setLang( 'notification', 'lv', { + closed: 'Paziņojums aizvērts.' +} ); Index: lams_central/web/ckeditor/plugins/notification/lang/nb.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/lang/nb.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/lang/nb.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,7 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ +CKEDITOR.plugins.setLang( 'notification', 'nb', { + closed: 'Varsling lukket.' +} ); Index: lams_central/web/ckeditor/plugins/notification/lang/nl.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/lang/nl.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/lang/nl.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,7 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ +CKEDITOR.plugins.setLang( 'notification', 'nl', { + closed: 'Melding gesloten.' +} ); Index: lams_central/web/ckeditor/plugins/notification/lang/oc.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/lang/oc.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/lang/oc.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,7 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ +CKEDITOR.plugins.setLang( 'notification', 'oc', { + closed: 'Notificacion tampada.' +} ); Index: lams_central/web/ckeditor/plugins/notification/lang/pl.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/lang/pl.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/lang/pl.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,7 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ +CKEDITOR.plugins.setLang( 'notification', 'pl', { + closed: 'Powiadomienie zostało zamknięte.' +} ); Index: lams_central/web/ckeditor/plugins/notification/lang/pt-br.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/lang/pt-br.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/lang/pt-br.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,7 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ +CKEDITOR.plugins.setLang( 'notification', 'pt-br', { + closed: 'Notificação fechada.' +} ); Index: lams_central/web/ckeditor/plugins/notification/lang/pt.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/lang/pt.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/lang/pt.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,7 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ +CKEDITOR.plugins.setLang( 'notification', 'pt', { + closed: 'Notificação encerrada.' +} ); Index: lams_central/web/ckeditor/plugins/notification/lang/ro.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/lang/ro.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/lang/ro.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,7 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ +CKEDITOR.plugins.setLang( 'notification', 'ro', { + closed: 'Notificare închisă.' +} ); Index: lams_central/web/ckeditor/plugins/notification/lang/ru.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/lang/ru.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/lang/ru.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,7 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ +CKEDITOR.plugins.setLang( 'notification', 'ru', { + closed: 'Уведомление закрыто' +} ); Index: lams_central/web/ckeditor/plugins/notification/lang/sk.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/lang/sk.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/lang/sk.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,7 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ +CKEDITOR.plugins.setLang( 'notification', 'sk', { + closed: 'Notifikácia zatvorená.' +} ); Index: lams_central/web/ckeditor/plugins/notification/lang/sq.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/lang/sq.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/lang/sq.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,7 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ +CKEDITOR.plugins.setLang( 'notification', 'sq', { + closed: 'Njoftimi është mbyllur.' +} ); Index: lams_central/web/ckeditor/plugins/notification/lang/sr-latn.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/lang/sr-latn.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/lang/sr-latn.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,7 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ +CKEDITOR.plugins.setLang( 'notification', 'sr-latn', { + closed: 'Obaveštenje zatvoreno' +} ); Index: lams_central/web/ckeditor/plugins/notification/lang/sr.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/lang/sr.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/lang/sr.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,7 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ +CKEDITOR.plugins.setLang( 'notification', 'sr', { + closed: 'Обавештење затворено' +} ); Index: lams_central/web/ckeditor/plugins/notification/lang/sv.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/lang/sv.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/lang/sv.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,7 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ +CKEDITOR.plugins.setLang( 'notification', 'sv', { + closed: 'Notifiering stängd.' +} ); Index: lams_central/web/ckeditor/plugins/notification/lang/tr.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/lang/tr.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/lang/tr.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,7 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ +CKEDITOR.plugins.setLang( 'notification', 'tr', { + closed: 'Uyarılar kapatıldı.' +} ); Index: lams_central/web/ckeditor/plugins/notification/lang/ug.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/lang/ug.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/lang/ug.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,7 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ +CKEDITOR.plugins.setLang( 'notification', 'ug', { + closed: 'ئوقتۇرۇش تاقالدى.' +} ); Index: lams_central/web/ckeditor/plugins/notification/lang/uk.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/lang/uk.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/lang/uk.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,7 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ +CKEDITOR.plugins.setLang( 'notification', 'uk', { + closed: 'Сповіщення закрито.' +} ); Index: lams_central/web/ckeditor/plugins/notification/lang/zh-cn.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/lang/zh-cn.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/lang/zh-cn.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,7 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ +CKEDITOR.plugins.setLang( 'notification', 'zh-cn', { + closed: '通知已关闭' +} ); Index: lams_central/web/ckeditor/plugins/notification/lang/zh.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/lang/zh.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/lang/zh.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,7 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ +CKEDITOR.plugins.setLang( 'notification', 'zh', { + closed: '通知已關閉。' +} ); Index: lams_central/web/ckeditor/plugins/notification/plugin.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/notification/plugin.js (revision 0) +++ lams_central/web/ckeditor/plugins/notification/plugin.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,933 @@ +/** + * @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. + * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license + */ + +/** + * @fileOverview The "Notification" plugin. + * + */ + +'use strict'; + +( function() { + + CKEDITOR.plugins.add( 'notification', { + lang: 'az,bg,ca,cs,da,de,de-ch,en,en-au,eo,es,es-mx,et,eu,fa,fr,gl,hr,hu,id,it,ja,km,ko,ku,lt,lv,nb,nl,oc,pl,pt,pt-br,ro,ru,sk,sq,sr,sr-latn,sv,tr,ug,uk,zh,zh-cn', // %REMOVE_LINE_CORE% + + init: function( editor ) { + editor._.notificationArea = new Area( editor ); + + // Overwrites default `editor.showNotification`. + editor.showNotification = function( message, type, progressOrDuration ) { + var progress, duration; + + if ( type == 'progress' ) { + progress = progressOrDuration; + } else { + duration = progressOrDuration; + } + + var notification = new CKEDITOR.plugins.notification( editor, { + message: message, + type: type, + progress: progress, + duration: duration + } ); + + notification.show(); + + return notification; + }; + + // Close the last notification on ESC. + editor.on( 'key', function( evt ) { + if ( evt.data.keyCode == 27 ) { /* ESC */ + var notifications = editor._.notificationArea.notifications; + + if ( !notifications.length ) { + return; + } + + // As long as this is not a common practice to inform screen-reader users about actions, in this case + // this is the best solution (unfortunately there is no standard for accessibility for notifications). + // Notification has an `alert` aria role what means that it does not get a focus nor is needed to be + // closed (unlike `alertdialog`). However notification will capture ESC key so we need to inform user + // why it does not do other actions. + say( editor.lang.notification.closed ); + + // Hide last. + notifications[ notifications.length - 1 ].hide(); + + evt.cancel(); + } + } ); + + // Send the message to the screen readers. + function say( text ) { + var message = new CKEDITOR.dom.element( 'div' ); + message.setStyles( { + position: 'fixed', + 'margin-left': '-9999px' + } ); + message.setAttributes( { + 'aria-live': 'assertive', + 'aria-atomic': 'true' + } ); + message.setText( text ); + + CKEDITOR.document.getBody().append( message ); + + setTimeout( function() { + message.remove(); + }, 100 ); + } + } + } ); + + /** + * Notification class. Notifications are used to display short messages to the user. They might be used to show the result of + * asynchronous actions or information about changes in the editor content. It is recommended to use them instead of + * alert dialogs. They should **not** be used if a user response is required nor with dialog windows (e.g. in dialog validation). + * + * There are four types of notifications available, see the {@link #type} property. + * + * Note that the notification constructor only creates a notification instance. To show it, use the {@link #show} method: + * + * var notification = new CKEDITOR.plugins.notification( editor, { message: 'Foo' } ); + * notification.show(); + * + * You can also use the {@link CKEDITOR.editor#showNotification} method: + * + * editor.showNotification( 'Foo' ); + * + * All of the notification actions: ({@link #show}, {@link #update} and {@link #hide}) fire cancelable events + * on the related {@link CKEDITOR.editor} instance so you can integrate editor notifications with your website notifications. + * + * Refer to the [Notifications](https://ckeditor.com/docs/ckeditor4/latest/guide/dev_notifications.html) article for more information about this feature. + * + * @since 4.5.0 + * @class CKEDITOR.plugins.notification + * @constructor Create a notification object. Call {@link #show} to show the created notification. + * @param {CKEDITOR.editor} editor The editor instance. + * @param {Object} options + * @param {String} options.message The message displayed in the notification. + * @param {String} [options.type='info'] Notification type, see {@link #type}. + * @param {Number} [options.progress=0] If the type is `progress` this may be a progress from 0 to 1. + * @param {Number} [options.duration] How long the notification will be visible, see {@link #duration}. + */ + function Notification( editor, options ) { + CKEDITOR.tools.extend( this, options, { + editor: editor, + id: 'cke-' + CKEDITOR.tools.getUniqueId(), + area: editor._.notificationArea + } ); + + if ( !options.type ) { + this.type = 'info'; + } + + this.element = this._createElement(); + + // Don't allow dragging on notification (https://dev.ckeditor.com/ticket/13184). + editor.plugins.clipboard && CKEDITOR.plugins.clipboard.preventDefaultDropOnElement( this.element ); + } + + /** + * The editor instance. + * + * @readonly + * @property {CKEDITOR.editor} editor + */ + + /** + * Message displayed in the notification. + * + * @readonly + * @property {String} message + */ + + /** + * Notification type. There are four types available: + * + * * `info` (default) – Information for the user (e.g. "File is uploading.", "ACF modified content."), + * * `warning` – Warning or error message (e.g. "This type of file is not supported.", + * "You cannot paste the script."), + * * `success` – Information that an operation finished successfully (e.g. "File uploaded.", "Data imported."). + * * `progress` – Information about the progress of an operation. When the operation is done, the notification + * type should be changed to `success`. + * + * @readonly + * @property {String} type + */ + + /** + * If the notification {@link #type} is `'progress'`, this is the progress from `0` to `1`. + * + * @readonly + * @property {Number} progress + */ + + /** + * Notification duration. Determines after how many milliseconds the notification should close automatically. + * `0` means that the notification will not close automatically and that the user needs to close it manually. + * The default value for `warning` and `progress` notifications is `0`. For `info` and `success` the value can + * either be set through the {@link CKEDITOR.config#notification_duration} configuration option or equals `5000` + * if the configuration option is not set. + * + * @readonly + * @property {Number} duration + */ + + /** + * Unique notification ID. + * + * @readonly + * @property {Number} id + */ + + /** + * Notification DOM element. There is one element per notification. It is created when the notification is created, + * even if it is not shown. If the notification is hidden, the element is detached from the document but not deleted. + * It will be reused if the notification is shown again. + * + * @readonly + * @property {CKEDITOR.dom.element} element + */ + + /** + * {@link CKEDITOR.plugins.notification.area Notification area} reference. + * + * @readonly + * @property {CKEDITOR.plugins.notification.area} area + */ + + Notification.prototype = { + /** + * Adds the notification element to the notification area. The notification will be hidden automatically if + * {@link #duration} is set. + * + * Fires the {@link CKEDITOR.editor#notificationShow} event. + */ + show: function() { + if ( this.editor.fire( 'notificationShow', { notification: this } ) === false ) { + return; + } + + this.area.add( this ); + + this._hideAfterTimeout(); + }, + + /** + * Updates the notification object and element. + * + * Fires the {@link CKEDITOR.editor#notificationUpdate} event. + * + * @param {Object} options + * @param {String} [options.message] {@link #message} + * @param {String} [options.type] {@link #type} + * @param {Number} [options.progress] {@link #progress} + * @param {Number} [options.duration] {@link #duration} + * @param {Boolean} [options.important=false] If the update is important, the notification will be shown + * if it was hidden and read by screen readers. + */ + update: function( options ) { + var show = true; + + if ( this.editor.fire( 'notificationUpdate', { notification: this, options: options } ) === false ) { + // The idea of cancelable event is to let user create his own way of displaying notification, so if + // `notificationUpdate` event will be canceled there will be no interaction with notification area, but on + // the other hand the logic should work anyway so object will be updated (including `element` property). + // Note: we can safely update the element's attributes below, because this element is created inside + // the constructor. If the notificatinShow event was canceled as well, the element is detached from DOM. + show = false; + } + + var element = this.element, + messageElement = element.findOne( '.cke_notification_message' ), + progressElement = element.findOne( '.cke_notification_progress' ), + type = options.type; + + element.removeAttribute( 'role' ); + + // Change type to progress if `options.progress` is set. + if ( options.progress && this.type != 'progress' ) { + type = 'progress'; + } + + if ( type ) { + element.removeClass( this._getClass() ); + element.removeAttribute( 'aria-label' ); + + this.type = type; + + element.addClass( this._getClass() ); + element.setAttribute( 'aria-label', this.type ); + + if ( this.type == 'progress' && !progressElement ) { + progressElement = this._createProgressElement(); + progressElement.insertBefore( messageElement ); + } else if ( this.type != 'progress' && progressElement ) { + progressElement.remove(); + } + } + + if ( options.message !== undefined ) { + this.message = options.message; + messageElement.setHtml( this.message ); + } + + if ( options.progress !== undefined ) { + this.progress = options.progress; + + if ( progressElement ) { + progressElement.setStyle( 'width', this._getPercentageProgress() ); + } + } + + if ( show && options.important ) { + element.setAttribute( 'role', 'alert' ); + + if ( !this.isVisible() ) { + this.area.add( this ); + } + } + + // Overwrite even if it is undefined. + this.duration = options.duration; + + this._hideAfterTimeout(); + }, + + /** + * Removes the notification element from the notification area. + * + * Fires the {@link CKEDITOR.editor#notificationHide} event. + */ + hide: function() { + if ( this.editor.fire( 'notificationHide', { notification: this } ) === false ) { + return; + } + + this.area.remove( this ); + }, + + /** + * Returns `true` if the notification is in the notification area. + * + * @returns {Boolean} `true` if the notification is in the notification area. + */ + isVisible: function() { + return CKEDITOR.tools.indexOf( this.area.notifications, this ) >= 0; + }, + + /** + * Creates the notification DOM element. + * + * @private + * @returns {CKEDITOR.dom.element} Notification DOM element. + */ + _createElement: function() { + var notification = this, + notificationElement, notificationMessageElement, notificationCloseElement, + close = this.editor.lang.common.close; + + notificationElement = new CKEDITOR.dom.element( 'div' ); + notificationElement.addClass( 'cke_notification' ); + notificationElement.addClass( this._getClass() ); + notificationElement.setAttributes( { + id: this.id, + role: 'alert', + 'aria-label': this.type + } ); + + if ( this.type == 'progress' ) + notificationElement.append( this._createProgressElement() ); + + notificationMessageElement = new CKEDITOR.dom.element( 'p' ); + notificationMessageElement.addClass( 'cke_notification_message' ); + notificationMessageElement.setHtml( this.message ); + notificationElement.append( notificationMessageElement ); + + notificationCloseElement = CKEDITOR.dom.element.createFromHtml( + '' + + 'X' + + '' ); + notificationElement.append( notificationCloseElement ); + + notificationCloseElement.on( 'click', function() { + // Focus editor on close (https://dev.ckeditor.com/ticket/12865) + notification.editor.focus(); + + notification.hide(); + } ); + + return notificationElement; + }, + + /** + * Gets the notification CSS class. + * + * @private + * @returns {String} Notification CSS class. + */ + _getClass: function() { + return ( this.type == 'progress' ) ? + 'cke_notification_info' : + ( 'cke_notification_' + this.type ); + }, + + /** + * Creates a progress element for the notification element. + * + * @private + * @returns {CKEDITOR.dom.element} Progress element for the notification element. + */ + _createProgressElement: function() { + var element = new CKEDITOR.dom.element( 'span' ); + element.addClass( 'cke_notification_progress' ); + element.setStyle( 'width', this._getPercentageProgress() ); + return element; + }, + + /** + * Gets the progress as a percentage (ex. `0.3` -> `30%`). + * + * @private + * @returns {String} Progress as a percentage. + */ + _getPercentageProgress: function() { + return Math.round( ( this.progress || 0 ) * 100 ) + '%'; + }, + + /** + * Hides the notification after a timeout. + * + * @private + */ + _hideAfterTimeout: function() { + var notification = this, + duration; + + if ( this._hideTimeoutId ) { + clearTimeout( this._hideTimeoutId ); + } + + if ( typeof this.duration == 'number' ) { + duration = this.duration; + } else if ( this.type == 'info' || this.type == 'success' ) { + duration = ( typeof this.editor.config.notification_duration == 'number' ) ? + this.editor.config.notification_duration : + 5000; + } + + if ( duration ) { + notification._hideTimeoutId = setTimeout( function() { + notification.hide(); + }, duration ); + } + } + }; + + /** + * Notification area is an area where all notifications are put. The area is laid out dynamically. + * When the first notification is added, the area is shown and all listeners are added. + * When the last notification is removed, the area is hidden and all listeners are removed. + * + * @since 4.5.0 + * @private + * @class CKEDITOR.plugins.notification.area + * @constructor + * @param {CKEDITOR.editor} editor The editor instance. + */ + function Area( editor ) { + var that = this; + + this.editor = editor; + this.notifications = []; + this.element = this._createElement(); + this._uiBuffer = CKEDITOR.tools.eventsBuffer( 10, this._layout, this ); + this._changeBuffer = CKEDITOR.tools.eventsBuffer( 500, this._layout, this ); + + editor.on( 'destroy', function() { + that._removeListeners(); + that.element.remove(); + } ); + } + + /** + * The editor instance. + * + * @readonly + * @property {CKEDITOR.editor} editor + */ + + /** + * The array of added notifications. + * + * @readonly + * @property {Array} notifications + */ + + /** + * Notification area DOM element. This element is created when the area object is created. It will be attached to the document + * when the first notification is added and removed when the last notification is removed. + * + * @readonly + * @property {CKEDITOR.dom.element} element + */ + + /** + * Notification width. Cached for performance reasons. + * + * @private + * @property {CKEDITOR.dom.element} _notificationWidth + */ + + /** + * Notification margin. Cached for performance reasons. + * + * @private + * @property {CKEDITOR.dom.element} _notificationMargin + */ + + /** + * Event buffer object for UI events to optimize performance. + * + * @private + * @property {Object} _uiBuffer + */ + + /** + * Event buffer object for editor change events to optimize performance. + * + * @private + * @property {Object} _changeBuffer + */ + + Area.prototype = { + /** + * Adds the notification to the notification area. If it is the first notification, the area will also be attached to + * the document and listeners will be attached. + * + * Note that the proper way to show a notification is to call the {@link CKEDITOR.plugins.notification#show} method. + * + * @param {CKEDITOR.plugins.notification} notification Notification to add. + */ + add: function( notification ) { + this.notifications.push( notification ); + + this.element.append( notification.element ); + + if ( this.element.getChildCount() == 1 ) { + CKEDITOR.document.getBody().append( this.element ); + this._attachListeners(); + } + + this._layout(); + }, + + /** + * Removes the notification from the notification area. If it is the last notification, the area will also be + * detached from the document and listeners will be detached. + * + * Note that the proper way to hide a notification is to call the {@link CKEDITOR.plugins.notification#hide} method. + * + * @param {CKEDITOR.plugins.notification} notification Notification to remove. + */ + remove: function( notification ) { + var i = CKEDITOR.tools.indexOf( this.notifications, notification ); + + if ( i < 0 ) { + return; + } + + this.notifications.splice( i, 1 ); + + notification.element.remove(); + + if ( !this.element.getChildCount() ) { + this._removeListeners(); + this.element.remove(); + } + }, + + /** + * Creates the notification area element. + * + * @private + * @returns {CKEDITOR.dom.element} Notification area element. + */ + _createElement: function() { + var editor = this.editor, + config = editor.config, + notificationArea = new CKEDITOR.dom.element( 'div' ); + + notificationArea.addClass( 'cke_notifications_area' ); + notificationArea.setAttribute( 'id', 'cke_notifications_area_' + editor.name ); + notificationArea.setStyle( 'z-index', config.baseFloatZIndex - 2 ); + + return notificationArea; + }, + + /** + * Attaches listeners to the notification area. + * + * @private + */ + _attachListeners: function() { + var win = CKEDITOR.document.getWindow(), + editor = this.editor; + + win.on( 'scroll', this._uiBuffer.input ); + win.on( 'resize', this._uiBuffer.input ); + editor.on( 'change', this._changeBuffer.input ); + editor.on( 'floatingSpaceLayout', this._layout, this, null, 20 ); + editor.on( 'blur', this._layout, this, null, 20 ); + }, + + /** + * Detaches listeners from the notification area. + * + * @private + */ + _removeListeners: function() { + var win = CKEDITOR.document.getWindow(), + editor = this.editor; + + win.removeListener( 'scroll', this._uiBuffer.input ); + win.removeListener( 'resize', this._uiBuffer.input ); + editor.removeListener( 'change', this._changeBuffer.input ); + editor.removeListener( 'floatingSpaceLayout', this._layout ); + editor.removeListener( 'blur', this._layout ); + }, + + /** + * Sets the position of the notification area based on the editor content, toolbar as well as + * viewport position and dimensions. + * + * @private + */ + _layout: function() { + var area = this.element, + editor = this.editor, + contentsRect = editor.ui.contentsElement.getClientRect(), + contentsPos = editor.ui.contentsElement.getDocumentPosition(), + top, + topRect, + areaRect = area.getClientRect(), + notification, + notificationWidth = this._notificationWidth, + notificationMargin = this._notificationMargin, + win = CKEDITOR.document.getWindow(), + scrollPos = win.getScrollPosition(), + viewRect = win.getViewPaneSize(), + body = CKEDITOR.document.getBody(), + bodyPos = body.getDocumentPosition(), + cssLength = CKEDITOR.tools.cssLength; + + // Cache for optimization + if ( !notificationWidth || !notificationMargin ) { + notification = this.element.getChild( 0 ); + notificationWidth = this._notificationWidth = notification.getClientRect().width; + notificationMargin = this._notificationMargin = + parseInt( notification.getComputedStyle( 'margin-left' ), 10 ) + + parseInt( notification.getComputedStyle( 'margin-right' ), 10 ); + } + + // Check if toolbar exist and if so, then assign values to it (#491). + if ( editor.toolbar ) { + top = editor.ui.space( editor.config.toolbarLocation ); + topRect = top.getClientRect(); + } + + + // --------------------------------------- Horizontal layout ---------------------------------------- + + // +---Viewport-------------------------------+ +---Viewport-------------------------------+ + // | | | | + // | +---Toolbar----------------------------+ | | +---Content----------------------------+ | + // | | | | | | | | + // | +---Content----------------------------+ | | | | | + // | | | | | +---Toolbar----------------------+ | | + // | | +------Notification------+ | | | | | | | + // | | | | OR | +--------------------------------+ | | + // | | | | | | | | + // | | | | | | +------Notification------+ | | + // | | | | | | | | + // | | | | | | | | + // | +--------------------------------------+ | | +--------------------------------------+ | + // +------------------------------------------+ +------------------------------------------+ + if ( top && top.isVisible() && + topRect.bottom > contentsRect.top && + topRect.bottom < contentsRect.bottom - areaRect.height ) { + setBelowToolbar(); + + // +---Viewport-------------------------------+ + // | | + // | +---Content----------------------------+ | + // | | | | + // | | +------Notification------+ | | + // | | | | + // | | | | + // | | | | + // | +--------------------------------------+ | + // | | + // +------------------------------------------+ + } else if ( contentsRect.top > 0 ) { + setTopStandard(); + + // +---Content----------------------------+ + // | | + // +---Viewport-------------------------------+ + // | | | | + // | | +------Notification------+ | | + // | | | | + // | | | | + // | | | | + // | +--------------------------------------+ | + // | | + // +------------------------------------------+ + } else if ( contentsPos.y + contentsRect.height - areaRect.height > scrollPos.y ) { + setTopFixed(); + + // +---Content----------------------------+ +---Content----------------------------+ + // | | | | + // | | | | + // | | | +------Notification------+ | + // | | | | + // | | OR +--------------------------------------+ + // +---Viewport-------------------------------+ + // | | +------Notification------+ | | +---Viewport-------------------------------+ + // | | | | | | + // | +--------------------------------------+ | | | + // | | | | + // +------------------------------------------+ +------------------------------------------+ + } else { + setBottom(); + } + + function setTopStandard() { + area.setStyles( { + position: 'absolute', + top: cssLength( contentsPos.y ) + } ); + } + + function setBelowToolbar() { + area.setStyles( { + position: 'fixed', + top: cssLength( topRect.bottom ) + } ); + } + + function setTopFixed() { + area.setStyles( { + position: 'fixed', + top: 0 + } ); + } + + function setBottom() { + area.setStyles( { + position: 'absolute', + top: cssLength( contentsPos.y + contentsRect.height - areaRect.height ) + } ); + } + + // ---------------------------------------- Vertical layout ----------------------------------------- + + var leftBase = area.getStyle( 'position' ) == 'fixed' ? + contentsRect.left : + body.getComputedStyle( 'position' ) != 'static' ? contentsPos.x - bodyPos.x : contentsPos.x; + + // Content is narrower than notification + if ( contentsRect.width < notificationWidth + notificationMargin ) { + + // +---Viewport-------------------------------+ + // | | + // | +---Content------------+ | + // | | | | + // | +------Notification------+ | | + // | | | | + // | +----------------------+ | + // | | + // +------------------------------------------+ + if ( contentsPos.x + notificationWidth + notificationMargin > scrollPos.x + viewRect.width ) { + setRight(); + + // +---Viewport-------------------------------+ +---Viewport--------------------------+ + // | | | | + // | +---Content------------+ | +---Content------------+ | + // | | | | | | | | + // | | +------Notification------+ | OR | +------Notification------+ | + // | | | | | | | | + // | +----------------------+ | +----------------------+ | + // | | | | + // +------------------------------------------+ +-------------------------------------+ + } else { + setLeft(); + } + + // Content is wider than notification. + } else { + + // +--+Viewport+------------------------+ + // | | + // | +---Content-----------------------------------------+ + // | | | | + // | | +-----+Notification+-----+ | + // | | | | + // | | | | + // | | | | + // | +---------------------------------------------------+ + // | | + // +------------------------------------+ + if ( contentsPos.x + notificationWidth + notificationMargin > scrollPos.x + viewRect.width ) { + setLeft(); + + // +---Viewport-------------------------+ + // | | + // | +---Content----------------------------------------------+ + // | | | | + // | | +------Notification------+ | | + // | | | | + // | | | | + // | +--------------------------------------------------------+ + // | | + // +------------------------------------+ + } else if ( contentsPos.x + contentsRect.width / 2 + + notificationWidth / 2 + notificationMargin > scrollPos.x + viewRect.width ) { + setRightFixed(); + + // +---Viewport-------------------------+ + // | | + // +---Content----------------------------+ | + // | | | | + // | +------Notification------+ | | + // | | | | + // | | | | + // +--------------------------------------+ | + // | | + // +------------------------------------+ + } else if ( contentsRect.left + contentsRect.width - notificationWidth - notificationMargin < 0 ) { + setRight(); + + // +---Viewport-------------------------+ + // | | + // +---Content---------------------------------------------+ | + // | | | | + // | | +------Notification------+ | | + // | | | | + // | | | | + // +-------------------------------------------------------+ | + // | | + // +------------------------------------+ + } else if ( contentsRect.left + contentsRect.width / 2 - notificationWidth / 2 < 0 ) { + setLeftFixed(); + + // +---Viewport-------------------------+ + // | | + // | +---Content----------------------+ | + // | | | | + // | | +-----Notification-----+ | | + // | | | | + // | | | | + // | +--------------------------------+ | + // | | + // +------------------------------------+ + } else { + setCenter(); + } + } + + function setLeft() { + area.setStyle( 'left', cssLength( leftBase ) ); + } + + function setLeftFixed() { + area.setStyle( 'left', cssLength( leftBase - contentsPos.x + scrollPos.x ) ); + } + + function setCenter() { + area.setStyle( 'left', cssLength( leftBase + contentsRect.width / 2 - notificationWidth / 2 - notificationMargin / 2 ) ); + } + + function setRight() { + area.setStyle( 'left', cssLength( leftBase + contentsRect.width - notificationWidth - notificationMargin ) ); + } + + function setRightFixed() { + area.setStyle( 'left', cssLength( leftBase - contentsPos.x + scrollPos.x + viewRect.width - + notificationWidth - notificationMargin ) ); + } + } + }; + + CKEDITOR.plugins.notification = Notification; + + /** + * After how many milliseconds the notification of the `info` and `success` + * {@link CKEDITOR.plugins.notification#type type} should close automatically. + * `0` means that notifications will not close automatically. + * Note that `warning` and `progress` notifications will never close automatically. + * + * Refer to the [Notifications](https://ckeditor.com/docs/ckeditor4/latest/guide/dev_notifications.html) article + * for more information about this feature. + * + * @since 4.5.0 + * @cfg {Number} [notification_duration=5000] + * @member CKEDITOR.config + */ + + /** + * Event fired when the {@link CKEDITOR.plugins.notification#show} method is called, before the + * notification is shown. If this event is canceled, the notification will not be shown. + * + * Using this event allows you to fully customize how a notification will be shown. It may be used to integrate + * the CKEditor notification system with your web page notifications. + * + * @since 4.5.0 + * @event notificationShow + * @member CKEDITOR.editor + * @param data + * @param {CKEDITOR.plugins.notification} data.notification Notification which will be shown. + * @param {CKEDITOR.editor} editor The editor instance. + */ + + /** + * Event fired when the {@link CKEDITOR.plugins.notification#update} method is called, before the + * notification is updated. If this event is canceled, the notification will not be shown even if the update was important, + * but the object will be updated anyway. Note that canceling this event does not prevent updating {@link #element} + * attributes, but if {@link #notificationShow} was canceled as well, this element is detached from the DOM. + * + * Using this event allows you to fully customize how a notification will be updated. It may be used to integrate + * the CKEditor notification system with your web page notifications. + * + * @since 4.5.0 + * @event notificationUpdate + * @member CKEDITOR.editor + * @param data + * @param {CKEDITOR.plugins.notification} data.notification Notification which will be updated. + * Note that it contains the data that has not been updated yet. + * @param {Object} data.options Update options, see {@link CKEDITOR.plugins.notification#update}. + * @param {CKEDITOR.editor} editor The editor instance. + */ + + /** + * Event fired when the {@link CKEDITOR.plugins.notification#hide} method is called, before the + * notification is hidden. If this event is canceled, the notification will not be hidden. + * + * Using this event allows you to fully customize how a notification will be hidden. It may be used to integrate + * the CKEditor notification system with your web page notifications. + * + * @since 4.5.0 + * @event notificationHide + * @member CKEDITOR.editor + * @param data + * @param {CKEDITOR.plugins.notification} data.notification Notification which will be hidden. + * @param {CKEDITOR.editor} editor The editor instance. + */ + +} )(); Index: lams_central/web/ckeditor/plugins/wordcount/css/wordcount.css =================================================================== diff -u --- lams_central/web/ckeditor/plugins/wordcount/css/wordcount.css (revision 0) +++ lams_central/web/ckeditor/plugins/wordcount/css/wordcount.css (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,3 @@ +.cke_wordcount {display:block;float:right;margin-top:-2px;margin-right:3px;color:black;} +.cke_wordcount_rtl {float:left;} +.cke_wordcountLimitReached {color:red! important} Index: lams_central/web/ckeditor/plugins/wordcount/lang/ar.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/wordcount/lang/ar.js (revision 0) +++ lams_central/web/ckeditor/plugins/wordcount/lang/ar.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,12 @@ +// Arabic Translation by Amine BENHAMIDA + +CKEDITOR.plugins.setLang('wordcount', 'ar', { + WordCount: 'كلمات:', + CharCount: 'حروف:', + CharCountWithHTML: 'حروف مع إتش تي إم إل', + Paragraphs: 'فقرات', + ParagraphsRemaining: 'Paragraphs remaining', + pasteWarning: 'لا يمكن اضافة هذا المحتوى لانه تجاوز الحد الاقصى', + Selected: 'محدد: ', + title: 'احصائيات' +}); Index: lams_central/web/ckeditor/plugins/wordcount/lang/bg.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/wordcount/lang/bg.js (revision 0) +++ lams_central/web/ckeditor/plugins/wordcount/lang/bg.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,17 @@ +/* +Copyright (c) 2003-2012, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.html or http://ckeditor.com/license +*/ +CKEDITOR.plugins.setLang('wordcount', 'bg', { + WordCount: 'Думи:', + WordCountRemaining: 'Оставащи думи', + CharCount: 'Знаци:', + CharCountRemaining: 'Знаци', + CharCountWithHTML: 'Знаци (с HTML):', + CharCountWithHTMLRemaining: 'Оставащи знаци (с HTML)', + Paragraphs: 'Параграфи:', + ParagraphsRemaining: 'Paragraphs remaining', + pasteWarning: 'Съдържанието не може да бъде поставено, защото е над разрешения лимит', + Selected: 'Избрани: ', + title: 'Статистика' +}); Index: lams_central/web/ckeditor/plugins/wordcount/lang/ca.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/wordcount/lang/ca.js (revision 0) +++ lams_central/web/ckeditor/plugins/wordcount/lang/ca.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,14 @@ +/* +Copyright (c) 2003-2012, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.html or http://ckeditor.com/license +*/ +CKEDITOR.plugins.setLang('wordcount', 'ca', { + WordCount: 'Paraules:', + CharCount: 'Caràcters:', + CharCountWithHTML: 'Caràcters (including HTML):', + Paragraphs: 'Paragraphs:', + ParagraphsRemaining: 'Paragraphs remaining', + pasteWarning: 'Content can not be pasted because it is above the allowed limit', + Selected: 'Selected: ', + title: 'Estadístiques' +}); Index: lams_central/web/ckeditor/plugins/wordcount/lang/cs.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/wordcount/lang/cs.js (revision 0) +++ lams_central/web/ckeditor/plugins/wordcount/lang/cs.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,15 @@ +/* +Copyright (c) 2003-2012, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.html or http://ckeditor.com/license +*/ +CKEDITOR.plugins.setLang('wordcount', 'cs', + { + WordCount: 'Slov: ', + CharCount: 'Znaků: ', + CharCountWithHTML: 'Znaků (s HTML): ', + Paragraphs: 'Odstavců: ', + ParagraphsRemaining: 'Paragraphs remaining', + pasteWarning: 'Obsah nelze vložit', + Selected: 'Výběr: ', + title: 'Statistika' + }); \ No newline at end of file Index: lams_central/web/ckeditor/plugins/wordcount/lang/da.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/wordcount/lang/da.js (revision 0) +++ lams_central/web/ckeditor/plugins/wordcount/lang/da.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,14 @@ +/* +Copyright (c) 2003-2012, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.html or http://ckeditor.com/license +*/ +CKEDITOR.plugins.setLang('wordcount', 'da', { + WordCount: 'Ord:', + CharCount: 'Karakterer:', + CharCountWithHTML: 'Karakterer (med HTML):', + Paragraphs: 'Afsnit:', + ParagraphsRemaining: 'Paragraphs remaining', + pasteWarning: 'Indholdet kan ikke indsættes da det er længere end den tilladte grænse.', + Selected: 'Markeret: ', + title: 'Statistik' +}); Index: lams_central/web/ckeditor/plugins/wordcount/lang/de.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/wordcount/lang/de.js (revision 0) +++ lams_central/web/ckeditor/plugins/wordcount/lang/de.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,14 @@ +/* +Copyright (c) 2003-2012, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.html or http://ckeditor.com/license +*/ +CKEDITOR.plugins.setLang('wordcount', 'de', { + WordCount: 'Wörter:', + CharCount: 'Zeichen:', + CharCountWithHTML: 'Zeichen (inkl. HTML):', + Paragraphs: 'Absätze:', + ParagraphsRemaining: 'Verbleibende Absätze', + pasteWarning: 'Text kann nicht eingefügt werden. Text ist zu lang.', + Selected: 'Ausgewählt: ', + title: 'Statistik' +}); Index: lams_central/web/ckeditor/plugins/wordcount/lang/el.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/wordcount/lang/el.js (revision 0) +++ lams_central/web/ckeditor/plugins/wordcount/lang/el.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,14 @@ +/* +Copyright (c) 2003-2012, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.html or http://ckeditor.com/license +*/ +CKEDITOR.plugins.setLang('wordcount', 'el', { + WordCount: 'Λέξεις:', + CharCount: 'Χαρακτήρες:', + CharCountWithHTML: 'Χαρακτήρες (μαζί με HTML):', + Paragraphs: 'Paragraphs:', + ParagraphsRemaining: 'Paragraphs remaining', + pasteWarning: 'Content can not be pasted because it is above the allowed limit', + Selected: 'Selected: ', + title: 'Στατιστικά' +}); Index: lams_central/web/ckeditor/plugins/wordcount/lang/en.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/wordcount/lang/en.js (revision 0) +++ lams_central/web/ckeditor/plugins/wordcount/lang/en.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,17 @@ +/* +Copyright (c) 2003-2012, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.html or http://ckeditor.com/license +*/ +CKEDITOR.plugins.setLang('wordcount', 'en', { + WordCount: 'Words:', + WordCountRemaining: 'Words remaining', + CharCount: 'Characters:', + CharCountRemaining: 'Characters remaining', + CharCountWithHTML: 'Characters (with HTML):', + CharCountWithHTMLRemaining: 'Characters (with HTML) remaining', + Paragraphs: 'Paragraphs:', + ParagraphsRemaining: 'Paragraphs remaining', + pasteWarning: 'Content cannot be pasted because it is above the allowed limit', + Selected: 'Selected: ', + title: 'Statistics' +}); Index: lams_central/web/ckeditor/plugins/wordcount/lang/es.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/wordcount/lang/es.js (revision 0) +++ lams_central/web/ckeditor/plugins/wordcount/lang/es.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,14 @@ +/* +Copyright (c) 2003-2012, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.html or http://ckeditor.com/license +*/ +CKEDITOR.plugins.setLang('wordcount', 'es', { + WordCount: 'Palabras:', + CharCount: 'Carácteres:', + CharCountWithHTML: 'Carácteres (con HTML):', + Paragraphs: 'Párrafos:', + ParagraphsRemaining: 'Paragraphs remaining', + pasteWarning: 'El contenido no se puede pegar, ya que se encuentra fuera del límite permitido', + Selected: 'Seleccionado: ', + title: 'Estadísticas' +}); Index: lams_central/web/ckeditor/plugins/wordcount/lang/eu.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/wordcount/lang/eu.js (revision 0) +++ lams_central/web/ckeditor/plugins/wordcount/lang/eu.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,17 @@ +/* +Copyright (c) 2003-2012, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.html or http://ckeditor.com/license +*/ +CKEDITOR.plugins.setLang('wordcount', 'eu', { + WordCount: 'Hitzak:', + WordCountRemaining: 'Gelditzen diren hitzak', + CharCount: 'Karaktereak:', + CharCountRemaining: 'Gelditzen diren karaktereak', + CharCountWithHTML: 'Karaktereak (HTMLarekin):', + CharCountWithHTMLRemaining: 'Gelditzen diren karaktereak (HTMLarekin)', + Paragraphs: 'Paragrafoak:', + ParagraphsRemaining: 'Gelditzen diren paragrafoak', + pasteWarning: 'Ezin da edukia itsatsi, onartutako muga gainditu duelako', + Selected: 'Hautatuta: ', + title: 'Estatistikak' +}); Index: lams_central/web/ckeditor/plugins/wordcount/lang/fa.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/wordcount/lang/fa.js (revision 0) +++ lams_central/web/ckeditor/plugins/wordcount/lang/fa.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,13 @@ +/* +Its The Persian (Farsi) Language Translate For Iranian By "Mohsen Esmaili" +*/ +CKEDITOR.plugins.setLang('wordcount', 'fa', { + WordCount: 'لغت:', + CharCount: 'کاراکتر:', + CharCountWithHTML: 'کاراکترها (با HTML):', + Paragraphs: 'پاراگراف:', + ParagraphsRemaining: 'Paragraphs remaining', + pasteWarning: 'محتوای مورد نظر را نمی توان چسباند. زیرا این بیشتر از حد مجاز است.', + Selected: 'انتخاب شده: ', + title: 'آمار' +}); \ No newline at end of file Index: lams_central/web/ckeditor/plugins/wordcount/lang/fi.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/wordcount/lang/fi.js (revision 0) +++ lams_central/web/ckeditor/plugins/wordcount/lang/fi.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,15 @@ +/** + * Finnish localisation. + * + * @author Joel Posti / Response200.pro + */ +CKEDITOR.plugins.setLang('wordcount', 'fi', { + WordCount: 'Sanoja:', + CharCount: 'Merkkejä:', + CharCountWithHTML: 'Merkkejä (ml. HTML):', + Paragraphs: 'Kappaleita:', + ParagraphsRemaining: 'Paragraphs remaining', + pasteWarning: 'Sisältöä ei voida liittää, koska se ylittää sallitun rajan.', + Selected: 'Valittuna: ', + title: 'Statistiikkaa' +}); Index: lams_central/web/ckeditor/plugins/wordcount/lang/fr.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/wordcount/lang/fr.js (revision 0) +++ lams_central/web/ckeditor/plugins/wordcount/lang/fr.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,12 @@ +// French Translation by Nicolas M. et Pierre-Luc Auclair + +CKEDITOR.plugins.setLang('wordcount', 'fr', { + WordCount: 'Mots :', + CharCount: 'Caractères :', + CharCountWithHTML: 'Caractères (incluant HTML) :', + Paragraphs: 'Paragraphes :', + ParagraphsRemaining: 'Paragraphs remaining', + pasteWarning: 'Le contenu ne peut pas être collé car il dépasse la limite autorisée', + Selected: 'Sélectionné :', + title: 'Statistiques' +}); Index: lams_central/web/ckeditor/plugins/wordcount/lang/he.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/wordcount/lang/he.js (revision 0) +++ lams_central/web/ckeditor/plugins/wordcount/lang/he.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,14 @@ +/* +Copyright (c) 2003-2012, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.html or http://ckeditor.com/license +*/ +CKEDITOR.plugins.setLang('wordcount', 'he', { + WordCount: 'מילים:', + CharCount: 'תווים:', + CharCountWithHTML: 'תווים (כולל HTML):', + Paragraphs: 'פסקאות:', + ParagraphsRemaining: 'Paragraphs remaining', + pasteWarning: 'לא ניתן להדביק תוכן בשל עודף תווים', + Selected: 'נבחר: ', + title: 'סטטיסטיקות' +}); \ No newline at end of file Index: lams_central/web/ckeditor/plugins/wordcount/lang/hr.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/wordcount/lang/hr.js (revision 0) +++ lams_central/web/ckeditor/plugins/wordcount/lang/hr.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,14 @@ +/* +Copyright (c) 2003-2012, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.html or http://ckeditor.com/license +*/ +CKEDITOR.plugins.setLang("wordcount", "hr", { + WordCount: "Riječi:", + CharCount: "Znakova:", + CharCountWithHTML: "Znakova (uključujući HTML):", + Paragraphs: "Paragraphs:", + ParagraphsRemaining: "Paragraphs remaining", + pasteWarning: "Content can not be pasted because it is above the allowed limit", + Selected: "Selected: ", + title: "Statistika" +}); Index: lams_central/web/ckeditor/plugins/wordcount/lang/hu.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/wordcount/lang/hu.js (revision 0) +++ lams_central/web/ckeditor/plugins/wordcount/lang/hu.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,14 @@ +/* +Copyright (c) 2003-2012, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.html or http://ckeditor.com/license +*/ +CKEDITOR.plugins.setLang('wordcount', 'hu', { + WordCount: 'Szavak:', + CharCount: 'Karakaterek:', + CharCountWithHTML: 'Karakterek (HTML tagekkel):', + Paragraphs: 'Bekezdések:', + ParagraphsRemaining: 'Paragraphs remaining', + pasteWarning: 'A szöveget nem lehet beilleszteni, mert a megadott limit felett van', + Selected: 'Kiválasztva: ', + title: 'Statisztika' +}); Index: lams_central/web/ckeditor/plugins/wordcount/lang/it.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/wordcount/lang/it.js (revision 0) +++ lams_central/web/ckeditor/plugins/wordcount/lang/it.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,15 @@ +/* +Copyright (c) 2003-2012, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.html or http://ckeditor.com/license +@author translation: Davide Montorio +*/ +CKEDITOR.plugins.setLang('wordcount', 'it', { + WordCount: 'Parole:', + CharCount: 'Caratteri:', + CharCountWithHTML: 'Caratteri (HTML incluso):', + Paragraphs: 'Paragrafi:', + ParagraphsRemaining: 'Paragraphs remaining', + pasteWarning: 'Il contenuto non può essere incollato poiché supera il limite massimo di caratteri disponibili', + Selected: 'Selezionato: ', + title: 'Statistiche' +}); Index: lams_central/web/ckeditor/plugins/wordcount/lang/ja.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/wordcount/lang/ja.js (revision 0) +++ lams_central/web/ckeditor/plugins/wordcount/lang/ja.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,14 @@ +/* +Copyright (c) 2003-2012, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.html or http://ckeditor.com/license +*/ +CKEDITOR.plugins.setLang('wordcount', 'ja', { + WordCount: '単語数:', + CharCount: '文字数:', + CharCountWithHTML: '文字数 (HTMLタグを含む):', + Paragraphs: '段落数:', + ParagraphsRemaining: 'Paragraphs remaining', + pasteWarning: '文字数/単語数の上限を超えるため、貼り付けできません。', + Selected: '選択中の字数:', + title: 'ワードカウント' +}); Index: lams_central/web/ckeditor/plugins/wordcount/lang/ka.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/wordcount/lang/ka.js (revision 0) +++ lams_central/web/ckeditor/plugins/wordcount/lang/ka.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,18 @@ +/* +Copyright (c) 2003-2012, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.html or http://ckeditor.com/license +GEO Translation by E404R +*/ +CKEDITOR.plugins.setLang('wordcount', 'ka', { + WordCount: 'სიტყვები:', + WordCountRemaining: 'დარჩენილი სიტყვები', + CharCount: 'სიმბოლო:', + CharCountRemaining: 'დარჩენილი სიმბოლო', + CharCountWithHTML: 'სიმბოლოები (HTML ით):', + CharCountWithHTMLRemaining: 'სიმბოლოები (HTML ით) დარჩენილი', + Paragraphs: 'პარაგრაფი:', + ParagraphsRemaining: 'დარჩენილი პარაგრაფი', + pasteWarning: 'ჩასმა შეუძლებელია, რადგან ის აღემატება დასაშვებ ლიმიტს', + Selected: 'არჩეული: ', + title: 'სტატისტიკა' +}); Index: lams_central/web/ckeditor/plugins/wordcount/lang/ko.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/wordcount/lang/ko.js (revision 0) +++ lams_central/web/ckeditor/plugins/wordcount/lang/ko.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,16 @@ +/* +Korean translation by Maxime Houdais +*/ +CKEDITOR.plugins.setLang('wordcount', 'ko', { + WordCount: '단어:', + WordCountRemaining: '남은 단어', + CharCount: '글자:', + CharCountRemaining: '자 남음', + CharCountWithHTML: '글자 와 HTML:', + CharCountWithHTMLRemaining: '남은 글자 와 HTML', + Paragraphs: '단락:', + ParagraphsRemaining: 'Paragraphs remaining', + pasteWarning: '허용 된 한도를 초과하여 콘텐츠를 붙여 넣을 수 없습니다.', + Selected: '선택:', + title: '통계' +}); Index: lams_central/web/ckeditor/plugins/wordcount/lang/nl.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/wordcount/lang/nl.js (revision 0) +++ lams_central/web/ckeditor/plugins/wordcount/lang/nl.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,14 @@ +/* +Copyright (c) 2003-2012, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.html or http://ckeditor.com/license +*/ +CKEDITOR.plugins.setLang('wordcount', 'nl', { + WordCount: 'Woorden:', + CharCount: 'Tekens:', + CharCountWithHTML: 'Tekens (inclusief HTML):', + Paragraphs: 'Paragrafen:', + ParagraphsRemaining: 'Paragraphs remaining', + pasteWarning: 'De tekst kan niet worden geplakt omdat de limiet is overschreden', + Selected: 'Geselecteerd: ', + title: 'Statistieken' +}); Index: lams_central/web/ckeditor/plugins/wordcount/lang/no.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/wordcount/lang/no.js (revision 0) +++ lams_central/web/ckeditor/plugins/wordcount/lang/no.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,11 @@ +// Norwegian translation by Vegard S. +CKEDITOR.plugins.setLang('wordcount', 'no', { + WordCount: 'Ord:', + CharCount: 'Tegn:', + CharCountWithHTML: 'Tegn (including HTML):', + Paragraphs: 'Paragraphs:', + ParagraphsRemaining: 'Paragraphs remaining', + pasteWarning: 'Content can not be pasted because it is above the allowed limit', + Selected: 'Selected: ', + title: 'Statistikk' +}); Index: lams_central/web/ckeditor/plugins/wordcount/lang/pl.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/wordcount/lang/pl.js (revision 0) +++ lams_central/web/ckeditor/plugins/wordcount/lang/pl.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,14 @@ +/* +Copyright (c) 2003-2012, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.html or http://ckeditor.com/license +*/ +CKEDITOR.plugins.setLang('wordcount', 'pl', { + WordCount: 'Słów:', + CharCount: 'Znaków:', + CharCountWithHTML: 'Znaków (wraz z kodem HTML):', + Paragraphs: 'Paragrafy:', + ParagraphsRemaining: 'Paragraphs remaining', + pasteWarning: 'Zawartość nie może zostać wklejona, ponieważ przekracza dozwolony limit', + Selected: 'Zaznaczono: ', + title: 'Statystyka' +}); Index: lams_central/web/ckeditor/plugins/wordcount/lang/pt-br.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/wordcount/lang/pt-br.js (revision 0) +++ lams_central/web/ckeditor/plugins/wordcount/lang/pt-br.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,14 @@ +/* +Copyright (c) 2003-2012, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.html or http://ckeditor.com/license +*/ +CKEDITOR.plugins.setLang('wordcount', 'pt-br', { + WordCount: 'Contagem de palavras:', + CharCount: 'Contagem de caracteres:', + CharCountWithHTML: 'Caracteres (incluindo HTML):', + Paragraphs: 'Parágrafos:', + ParagraphsRemaining: 'Paragraphs remaining', + pasteWarning: 'Conteúdo não pode ser colado porque ultrapassa o limite permitido', + Selected: 'Selecionado: ', + title: 'Estatísticas' +}); Index: lams_central/web/ckeditor/plugins/wordcount/lang/pt.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/wordcount/lang/pt.js (revision 0) +++ lams_central/web/ckeditor/plugins/wordcount/lang/pt.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,10 @@ +CKEDITOR.plugins.setLang('wordcount', 'pt', { + WordCount: 'Palavras:', + CharCount: 'Caracteres:', + CharCountWithHTML: 'Carateres (incluindo HTML):', + Paragraphs: 'Parágrafos:', + ParagraphsRemaining: 'Paragraphs remaining', + pasteWarning: 'O conteúdo não pode ser colado porque ultrapassa o limite permitido', + Selected: 'Selecionado: ', + title: 'Estatísticas' +}); Index: lams_central/web/ckeditor/plugins/wordcount/lang/ro.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/wordcount/lang/ro.js (revision 0) +++ lams_central/web/ckeditor/plugins/wordcount/lang/ro.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,15 @@ +// Romanian Translation by Bogdanov Mihail + +CKEDITOR.plugins.setLang('wordcount', 'ro', { + WordCount: 'Numar cuvinte', + WordCountRemaining: 'Cuvinte ramase', + CharCount: 'Numar caracter:', + CharCountRemaining: 'Caractere ramase:', + CharCountWithHTML: 'Numar caractere (cu HTML):', + CharCountWithHTMLRemaining: 'Caractere (cu HTML) ramase', + Paragraphs: 'Paragrafe:', + ParagraphsRemaining: 'Paragrafe ramase', + pasteWarning: 'Continutul nu poate fi adaugat deoarece este mai mare decat limita setata', + Selected: 'Selectat:', + title: 'Statistici' +}); \ No newline at end of file Index: lams_central/web/ckeditor/plugins/wordcount/lang/ru.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/wordcount/lang/ru.js (revision 0) +++ lams_central/web/ckeditor/plugins/wordcount/lang/ru.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,14 @@ +/* +Copyright (c) 2003-2013, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.html or http://ckeditor.com/license +*/ +CKEDITOR.plugins.setLang('wordcount', 'ru', { + WordCount: 'Слов:', + CharCount: 'Символов:', + CharCountWithHTML: ' (включая HTML-разметку):', + Paragraphs: 'Параграфов:', + ParagraphsRemaining: 'Параграфов осталось', + pasteWarning: 'Контент не может быть вставлен, т.к. привышает допустимый лимит', + Selected: 'Выделено: ', + title: 'Статистика' +}); Index: lams_central/web/ckeditor/plugins/wordcount/lang/sk.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/wordcount/lang/sk.js (revision 0) +++ lams_central/web/ckeditor/plugins/wordcount/lang/sk.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,15 @@ +/* +Copyright (c) 2003-2012, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.html or http://ckeditor.com/license +*/ +CKEDITOR.plugins.setLang('wordcount', 'sk', { + WordCount: 'Slov:', + CharCount: 'Znakov:', + CharCountWithHTML: 'Znakov (vrátane HTML):', + Paragraphs: 'Odstavcov:', + ParagraphsRemaining: 'Paragraphs remaining', + pasteWarning: 'Obsah sa nedá prilepiť.', + Selected: 'Výber: ', + title: 'Štatistika' +}); + Index: lams_central/web/ckeditor/plugins/wordcount/lang/sv.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/wordcount/lang/sv.js (revision 0) +++ lams_central/web/ckeditor/plugins/wordcount/lang/sv.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,15 @@ +/* +Copyright (c) 2003-2012, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.html or http://ckeditor.com/license +*/ +CKEDITOR.plugins.setLang('wordcount', 'sv', { + WordCount: 'Ord:', + CharCount: 'Tecken:', + CharCountRemaining: 'tecken återstår', + CharCountWithHTML: 'Tecken (inklusive HTML):', + Paragraphs: 'Paragraf:', + ParagraphsRemaining: 'Paragraphs remaining', + pasteWarning: 'Innehåll kan inte klistras in eftersom det överskrider den tillåtna gränsen', + Selected: 'Valt: ', + title: 'Statistik' +}); Index: lams_central/web/ckeditor/plugins/wordcount/lang/tr.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/wordcount/lang/tr.js (revision 0) +++ lams_central/web/ckeditor/plugins/wordcount/lang/tr.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,14 @@ +/* +Mesut ÇAKIR +mesut.cakir@hotmail.com.tr +*/ +CKEDITOR.plugins.setLang('wordcount', 'tr', { + WordCount: 'Kelime:', + CharCount: 'Karakter:', + CharCountWithHTML: 'Karakter (HTML dahil):', + Paragraphs: 'Paragraf:', + ParagraphsRemaining: 'Paragraphs remaining', + pasteWarning: 'Content can not be pasted because it is above the allowed limit', + Selected: 'Selected: ', + title: 'İstatistik' +}); Index: lams_central/web/ckeditor/plugins/wordcount/lang/uk.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/wordcount/lang/uk.js (revision 0) +++ lams_central/web/ckeditor/plugins/wordcount/lang/uk.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,17 @@ +/* + Copyright (c) 2003-2013, CKSource - Frederico Knabben. All rights reserved. + For licensing, see LICENSE.html or http://ckeditor.com/license + */ +CKEDITOR.plugins.setLang('wordcount', 'uk', { + WordCount: 'Слів:', + WordCountRemaining: 'Слів залишилося', + CharCount: 'Символів:', + CharCountRemaining: 'Символів залишилося', + CharCountWithHTML: 'Символів (включаючи HTML-розмітку):', + CharCountWithHTMLRemaining: 'Символів (включаючи HTML-розмітку) залишилося', + Paragraphs: 'Параграфів:', + ParagraphsRemaining: 'Параграфів залишилося', + pasteWarning: 'Контент не може бути вставлено, оскільки перевищує допустимий ліміт', + Selected: 'Виділено: ', + title: 'Статистика' +}); Index: lams_central/web/ckeditor/plugins/wordcount/lang/zh-cn.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/wordcount/lang/zh-cn.js (revision 0) +++ lams_central/web/ckeditor/plugins/wordcount/lang/zh-cn.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,17 @@ +/* +Copyright (c) 2003-2012, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.html or http://ckeditor.com/license +*/ +CKEDITOR.plugins.setLang('wordcount', 'zh-cn', { + WordCount: '词数:', + WordCountRemaining: 'Words remaining', + CharCount: '字符:', + CharCountRemaining: '个剩余字符', + CharCountWithHTML: '字符 (含HTML)', + CharCountWithHTMLRemaining: 'Characters (with HTML) remaining', + Paragraphs: '段落:', + ParagraphsRemaining: 'Paragraphs remaining', + pasteWarning: '由于上限允许,内容不能粘贴', + Selected: '已选择: ', + title: '统计' +}); Index: lams_central/web/ckeditor/plugins/wordcount/lang/zh.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/wordcount/lang/zh.js (revision 0) +++ lams_central/web/ckeditor/plugins/wordcount/lang/zh.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,17 @@ +/* +Copyright (c) 2003-2012, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.html or http://ckeditor.com/license +*/ +CKEDITOR.plugins.setLang('wordcount', 'zh', { + WordCount: '詞數:', + WordCountRemaining: 'Words remaining', + CharCount: '字數:', + CharCountRemaining: '個剩餘字元', + CharCountWithHTML: '字數 (含HTML)', + CharCountWithHTMLRemaining: 'Characters (with HTML) remaining', + Paragraphs: '段落:', + ParagraphsRemaining: 'Paragraphs remaining', + pasteWarning: '由於字數達到上限,內容不能粘貼', + Selected: '已選擇: ', + title: '統計' +}); \ No newline at end of file Index: lams_central/web/ckeditor/plugins/wordcount/plugin.js =================================================================== diff -u --- lams_central/web/ckeditor/plugins/wordcount/plugin.js (revision 0) +++ lams_central/web/ckeditor/plugins/wordcount/plugin.js (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,638 @@ +/** + * @license Copyright (c) CKSource - Frederico Knabben. All rights reserved. + * For licensing, see LICENSE.html or http://ckeditor.com/license + */ + +CKEDITOR.plugins.add("wordcount", + { + lang: "ar,bg,ca,cs,da,de,el,en,es,eu,fa,fi,fr,he,hr,hu,it,ka,ko,ja,nl,no,pl,pt,pt-br,ru,sk,sv,tr,uk,zh-cn,zh,ro", // %REMOVE_LINE_CORE% + version: "1.17.9", + requires: "htmlwriter,notification,undo", + bbcodePluginLoaded: false, + onLoad: function() { + CKEDITOR.document.appendStyleSheet(this.path + "css/wordcount.css"); + }, + init: function(editor) { + var defaultFormat = "", + lastWordCount = -1, + lastCharCount = -1, + lastParagraphs = -1, + limitReachedNotified = false, + limitRestoredNotified = false, + timeoutId = 0, + notification = null; + + + var dispatchEvent = function(type, currentLength, maxLength) { + if (typeof document.dispatchEvent == "undefined") { + return; + } + + type = "ckeditor.wordcount." + type; + + var cEvent; + var eventInitDict = { + bubbles: false, + cancelable: true, + detail: { + currentLength: currentLength, + maxLength: maxLength + } + }; + + try { + cEvent = new CustomEvent(type, eventInitDict); + } catch (o_O) { + cEvent = document.createEvent("CustomEvent"); + cEvent.initCustomEvent( + type, + eventInitDict.bubbles, + eventInitDict.cancelable, + eventInitDict.detail + ); + } + + document.dispatchEvent(cEvent); + }; + + // Default Config + var defaultConfig = { + showRemaining: false, + showParagraphs: true, + showWordCount: true, + showCharCount: false, + countBytesAsChars: false, + countSpacesAsChars: false, + countHTML: false, + countLineBreaks: false, + hardLimit: true, + warnOnLimitOnly: false, + wordDelims: '', + + //MAXLENGTH Properties + maxWordCount: -1, + maxCharCount: -1, + maxParagraphs: -1, + + // Filter + filter: null, + + // How long to show the 'paste' warning + pasteWarningDuration: 0, + + //DisAllowed functions + wordCountGreaterThanMaxLengthEvent: function(currentLength, maxLength) { + dispatchEvent("wordCountGreaterThanMaxLengthEvent", currentLength, maxLength); + }, + charCountGreaterThanMaxLengthEvent: function(currentLength, maxLength) { + dispatchEvent("charCountGreaterThanMaxLengthEvent", currentLength, maxLength); + }, + + //Allowed Functions + wordCountLessThanMaxLengthEvent: function(currentLength, maxLength) { + dispatchEvent("wordCountLessThanMaxLengthEvent", currentLength, maxLength); + }, + charCountLessThanMaxLengthEvent: function(currentLength, maxLength) { + dispatchEvent("charCountLessThanMaxLengthEvent", currentLength, maxLength); + } + }; + + // Get Config & Lang + var config = CKEDITOR.tools.extend(defaultConfig, editor.config.wordcount || {}, true); + + if (config.showParagraphs) { + if (config.maxParagraphs > -1) { + if (config.showRemaining) { + defaultFormat += "%paragraphsCount% " + editor.lang.wordcount.ParagraphsRemaining; + } else { + defaultFormat += editor.lang.wordcount.Paragraphs + " %paragraphsCount%"; + + defaultFormat += "/" + config.maxParagraphs; + } + } else { + defaultFormat += editor.lang.wordcount.Paragraphs + " %paragraphsCount%"; + } + } + + if (config.showParagraphs && (config.showWordCount || config.showCharCount)) { + defaultFormat += ", "; + } + + if (config.showWordCount) { + if (config.maxWordCount > -1) { + if (config.showRemaining) { + defaultFormat += "%wordCount% " + editor.lang.wordcount.WordCountRemaining; + } else { + defaultFormat += editor.lang.wordcount.WordCount + " %wordCount%"; + + defaultFormat += "/" + config.maxWordCount; + } + } else { + defaultFormat += editor.lang.wordcount.WordCount + " %wordCount%"; + } + } + + if (config.showCharCount && config.showWordCount) { + defaultFormat += ", "; + } + + if (config.showCharCount) { + if (config.maxCharCount > -1) { + if (config.showRemaining) { + defaultFormat += "%charCount% " + + editor.lang.wordcount[config.countHTML + ? "CharCountWithHTMLRemaining" + : "CharCountRemaining"]; + } else { + defaultFormat += editor.lang.wordcount[config.countHTML + ? "CharCountWithHTML" + : "CharCount"] + + " %charCount%"; + + defaultFormat += "/" + config.maxCharCount; + } + } else { + defaultFormat += editor.lang.wordcount[config.countHTML ? "CharCountWithHTML" : "CharCount"] + + " %charCount%"; + } + } + + var format = defaultFormat; + + bbcodePluginLoaded = typeof editor.plugins.bbcode != "undefined"; + + function counterId(editorInstance) { + return "cke_wordcount_" + editorInstance.name; + } + + function counterElement(editorInstance) { + return document.getElementById(counterId(editorInstance)); + } + + function strip(html) { + if (bbcodePluginLoaded) { + // stripping out BBCode tags [...][/...] + return html.replace(/\[.*?\]/gi, ""); + } + + var tmp = document.createElement("div"); + + // Add filter before strip + html = filter(html); + + tmp.innerHTML = html; + + if (tmp.textContent == "" && typeof tmp.innerText == "undefined") { + return ""; + } + + return tmp.textContent || tmp.innerText; + } + + /** + * Implement filter to add or remove before counting + * @param html + * @returns string + */ + function filter(html) { + if (config.filter instanceof CKEDITOR.htmlParser.filter) { + var fragment = CKEDITOR.htmlParser.fragment.fromHtml(html), + writer = new CKEDITOR.htmlParser.basicWriter(); + config.filter.applyTo(fragment); + fragment.writeHtml(writer); + return writer.getHtml(); + } + return html; + } + + function countCharacters(text) { + if (config.countHTML) { + return config.countBytesAsChars ? countBytes(filter(text)) : filter(text).length; + } + + var normalizedText; + + // strip body tags + if (editor.config.fullPage) { + var i = text.search(new RegExp("", "i")); + if (i != -1) { + var j = text.search(new RegExp("", "i")); + text = text.substring(i + 6, j); + } + + } + + normalizedText = text; + + if (!config.countSpacesAsChars) { + normalizedText = text.replace(/\s/g, "").replace(/ /g, ""); + } + + if (config.countLineBreaks) { + normalizedText = normalizedText.replace(/(\r\n|\n|\r)/gm, " "); + } else { + normalizedText = normalizedText.replace(/(\r\n|\n|\r)/gm, "").replace(/ /gi, " "); + } + + normalizedText = strip(normalizedText).replace(/^([\t\r\n]*)$/, ""); + + return config.countBytesAsChars ? countBytes(normalizedText) : normalizedText.length; + } + + function countBytes(text) { + var count = 0, stringLength = text.length, i; + text = String(text || ""); + for (i = 0; i < stringLength; i++) { + var partCount = encodeURI(text[i]).split("%").length; + count += partCount == 1 ? 1 : partCount - 1; + } + return count; + } + + function countParagraphs(text) { + return (text.replace(/ /g, " ").replace(/(<([^>]+)>)/ig, "").replace(/^\s*$[\n\r]{1,}/gm, "++") + .split("++").length); + } + + function countWords(text) { + var normalizedText = text.replace(/(\r\n|\n|\r)/gm, " ").replace(/^\s+|\s+$/g, "") + .replace(" ", " "); + + normalizedText = strip(normalizedText); + + var re = config.wordDelims ? new RegExp('[\\s'+config.wordDelims+']+') : /\s+/; + var words = normalizedText.split(re); + + re = config.wordDelims ? new RegExp('^([\\s\\t\\r\\n'+config.wordDelims+']*)$') : /^([\s\t\r\n]*)$/; + for (var wordIndex = words.length - 1; wordIndex >= 0; wordIndex--) { + if (!words[wordIndex] || words[wordIndex].match(re)) { + words.splice(wordIndex, 1); + } + } + + return (words.length); + } + + function limitReached(editorInstance, notify) { + limitReachedNotified = true; + limitRestoredNotified = false; + + if (!config.warnOnLimitOnly) { + if (config.hardLimit) { + if (editor.mode === "source" && editor.plugins.codemirror) { + window["codemirror_" + editor.id].undo(); + } else { + editorInstance.execCommand("undo"); + editorInstance.execCommand("undo"); + } + + } + } + + if (!notify) { + counterElement(editorInstance).className = "cke_path_item cke_wordcountLimitReached"; + editorInstance.fire("limitReached", { firedBy: "wordCount.limitReached" }, editor); + } + } + + function limitRestored(editorInstance) { + limitRestoredNotified = true; + limitReachedNotified = false; + + if (!config.warnOnLimitOnly) { + editorInstance.fire("saveSnapshot"); + } + + counterElement(editorInstance).className = "cke_path_item"; + } + + function updateCounter(editorInstance) { + if (!counterElement(editorInstance)) { + return; + } + + var paragraphs = 0, + wordCount = 0, + charCount = 0, + text; + + // BeforeGetData and getData events are fired when calling + // getData(). We can prevent this by passing true as an + // argument to getData(). This allows us to fire the events + // manually with additional event data: firedBy. This additional + // data helps differentiate calls to getData() made by + // wordCount plugin from calls made by other plugins/code. + editorInstance.fire("beforeGetData", { firedBy: "wordCount.updateCounter" }, editor); + text = editorInstance.getData(true); + editorInstance.fire("getData", { dataValue: text, firedBy: "wordCount.updateCounter" }, editor); + + if (text) { + if (config.showCharCount) { + charCount = countCharacters(text); + } + + if (config.showParagraphs) { + paragraphs = countParagraphs(text); + } + + if (config.showWordCount) { + wordCount = countWords(text); + } + } + + var html = format; + if (config.showRemaining) { + if (config.maxCharCount >= 0) { + html = html.replace("%charCount%", config.maxCharCount - charCount); + } else { + html = html.replace("%charCount%", charCount); + } + + if (config.maxWordCount >= 0) { + html = html.replace("%wordCount%", config.maxWordCount - wordCount); + } else { + html = html.replace("%wordCount%", wordCount); + } + + if (config.maxParagraphs >= 0) { + html = html.replace("%paragraphsCount%", config.maxParagraphs - paragraphs); + } else { + html = html.replace("%paragraphsCount%", paragraphs); + } + } else { + html = html.replace("%wordCount%", wordCount).replace("%charCount%", charCount).replace("%paragraphsCount%", paragraphs); + } + + (editorInstance.config.wordcount || (editorInstance.config.wordcount = {})).wordCount = wordCount; + (editorInstance.config.wordcount || (editorInstance.config.wordcount = {})).charCount = charCount; + + if (CKEDITOR.env.gecko) { + counterElement(editorInstance).innerHTML = html; + } else { + counterElement(editorInstance).innerText = html; + } + + if (charCount == lastCharCount && wordCount == lastWordCount && paragraphs == lastParagraphs) { + if (charCount == config.maxCharCount || wordCount == config.maxWordCount || paragraphs > config.maxParagraphs) { + editorInstance.fire("saveSnapshot"); + } + return true; + } + + //If the limit is already over, allow the deletion of characters/words. Otherwise, + //the user would have to delete at one go the number of offending characters + var deltaWord = wordCount - lastWordCount; + var deltaChar = charCount - lastCharCount; + var deltaParagraphs = paragraphs - lastParagraphs; + + lastWordCount = wordCount; + lastCharCount = charCount; + lastParagraphs = paragraphs; + + if (lastWordCount == -1) { + lastWordCount = wordCount; + } + if (lastCharCount == -1) { + lastCharCount = charCount; + } + if (lastParagraphs == -1) { + lastParagraphs = paragraphs; + } + + // Check for word limit and/or char limit + if ((config.maxWordCount > -1 && wordCount > config.maxWordCount && deltaWord > 0) || + (config.maxCharCount > -1 && charCount > config.maxCharCount && deltaChar > 0) || + (config.maxParagraphs > -1 && paragraphs > config.maxParagraphs && deltaParagraphs > 0)) { + + limitReached(editorInstance, limitReachedNotified); + } else if ((config.maxWordCount == -1 || wordCount <= config.maxWordCount) && + (config.maxCharCount == -1 || charCount <= config.maxCharCount) && + (config.maxParagraphs == -1 || paragraphs <= config.maxParagraphs)) { + + limitRestored(editorInstance); + } else { + editorInstance.fire("saveSnapshot"); + } + + // update instance + editorInstance.wordCount = + { + paragraphs: paragraphs, + wordCount: wordCount, + charCount: charCount + }; + + + // Fire Custom Events + if (config.charCountGreaterThanMaxLengthEvent && config.charCountLessThanMaxLengthEvent) { + if (charCount > config.maxCharCount && config.maxCharCount > -1) { + config.charCountGreaterThanMaxLengthEvent(charCount, config.maxCharCount); + } else { + config.charCountLessThanMaxLengthEvent(charCount, config.maxCharCount); + } + } + + if (config.wordCountGreaterThanMaxLengthEvent && config.wordCountLessThanMaxLengthEvent) { + if (wordCount > config.maxWordCount && config.maxWordCount > -1) { + config.wordCountGreaterThanMaxLengthEvent(wordCount, config.maxWordCount); + + } else { + config.wordCountLessThanMaxLengthEvent(wordCount, config.maxWordCount); + } + } + + return true; + } + + function isCloseToLimits() { + if (config.maxWordCount > -1 && config.maxWordCount - lastWordCount < 5) { + return true; + } + + if (config.maxCharCount > -1 && config.maxCharCount - lastCharCount < 20) { + return true; + } + + if (config.maxParagraphs > -1 && config.maxParagraphs - lastParagraphs < 1) { + return true; + } + + return false; + } + + editor.on("key", + function (event) { + var ms = isCloseToLimits() ? 5 : 250; + + if (editor.mode === "source") { + clearTimeout(timeoutId); + timeoutId = setTimeout( + updateCounter.bind(this, event.editor), + ms + ); + } + + if (event.data.keyCode == 13) { + clearTimeout(timeoutId); + timeoutId = setTimeout( + updateCounter.bind(this, event.editor), + ms + ); + } + }, + editor); + + editor.on("change", + function(event) { + var ms = isCloseToLimits() ? 5 : 250; + clearTimeout(timeoutId); + timeoutId = setTimeout( + updateCounter.bind(this, event.editor), + ms + ); + }, + editor); + + editor.on("uiSpace", + function (event) { + var wordcountClass = "cke_wordcount"; + + if (editor.lang.dir == "rtl") { + wordcountClass = wordcountClass + " cke_wordcount_rtl"; + } + + if (editor.elementMode === CKEDITOR.ELEMENT_MODE_INLINE) { + if (event.data.space == "top") { + event.data.html += "
 
"; + } + } else { + if (event.data.space == "bottom") { + event.data.html += "
 
"; + } + } + + }, + editor, + null, + 100); + + editor.on("dataReady", + function(event) { + updateCounter(event.editor); + }, + editor, + null, + 100); + + editor.on("paste", + function(event) { + if (!config.warnOnLimitOnly && (config.maxWordCount > 0 || config.maxCharCount > 0 || config.maxParagraphs > 0)) { + + // Check if pasted content is above the limits + var wordCount = -1, + charCount = -1, + paragraphs = -1; + + var mySelection = event.editor.getSelection(), + selectedText = mySelection.getNative().toString().trim(); + + + // BeforeGetData and getData events are fired when calling + // getData(). We can prevent this by passing true as an + // argument to getData(). This allows us to fire the events + // manually with additional event data: firedBy. This additional + // data helps differentiate calls to getData() made by + // wordCount plugin from calls made by other plugins/code. + event.editor.fire("beforeGetData", { firedBy: "wordCount.onPaste" }, event.editor); + var text = event.editor.getData(true); + event.editor.fire("getData", { dataValue: text, firedBy: "wordCount.onPaste" }, event.editor); + + if (selectedText.length > 0) { + var plaintext = event.editor.document.getBody().getText(); + + if (plaintext.length === selectedText.length) { + text = ""; + } + } + + + text += event.data.dataValue; + + if (config.showCharCount) { + charCount = countCharacters(text); + } + + if (config.showWordCount) { + wordCount = countWords(text); + } + + if (config.showParagraphs) { + paragraphs = countParagraphs(text); + } + + + // Instantiate the notification when needed and only have one instance + if (notification === null) { + notification = new CKEDITOR.plugins.notification(event.editor, + { + message: event.editor.lang.wordcount.pasteWarning, + type: "warning", + duration: config.pasteWarningDuration + }); + } + + if (config.maxCharCount > 0 && charCount > config.maxCharCount && config.hardLimit) { + if (!notification.isVisible()) { + notification.show(); + } + event.cancel(); + } + + if (config.maxWordCount > 0 && wordCount > config.maxWordCount && config.hardLimit) { + if (!notification.isVisible()) { + notification.show(); + } + event.cancel(); + } + + if (config.maxParagraphs > 0 && paragraphs > config.maxParagraphs && config.hardLimit) { + if (!notification.isVisible()) { + notification.show(); + } + event.cancel(); + } + } + }, + editor, + null, + 100); + + editor.on("afterPaste", + function(event) { + updateCounter(event.editor); + }, + editor, + null, + 100); + + editor.on("afterPasteFromWord", + function (event) { + updateCounter(event.editor); + }, + editor, + null, + 100); + } + }); Index: lams_central/web/ckeditor/plugins/wordcount/samples/maxParagraphs.html =================================================================== diff -u --- lams_central/web/ckeditor/plugins/wordcount/samples/maxParagraphs.html (revision 0) +++ lams_central/web/ckeditor/plugins/wordcount/samples/maxParagraphs.html (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,26 @@ + + + + + CKEditor + + + + + + + + \ No newline at end of file Index: lams_central/web/ckeditor/plugins/wordcount/samples/wordcount.html =================================================================== diff -u --- lams_central/web/ckeditor/plugins/wordcount/samples/wordcount.html (revision 0) +++ lams_central/web/ckeditor/plugins/wordcount/samples/wordcount.html (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,61 @@ + + + + + + WordCount — CKEditor Sample + + + + + + + + + +

+ CKEditor Samples » WordCount Plugin +

+ +
+

+ WordCount Plugin for CKEditor that counts the words an shows the word count in the footer of the editor.. +

+

+ In order to use the new plugin, include it in the config.extraPlugins configuration setting. +

+
+CKEDITOR.replace( 'textarea_id', {
+	extraPlugins: 'wordcount'
+} );
+
+
+ + + + + + + Index: lams_central/web/ckeditor/plugins/wordcount/samples/wordcountWithMaxCount.html =================================================================== diff -u --- lams_central/web/ckeditor/plugins/wordcount/samples/wordcountWithMaxCount.html (revision 0) +++ lams_central/web/ckeditor/plugins/wordcount/samples/wordcountWithMaxCount.html (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,110 @@ + + + + + + WordCount — CKEditor Sample + + + + + + + + + + +

+ CKEditor Samples » WordCount Plugin +

+ +
+

+ WordCount Plugin for CKEditor that counts the words an shows the word count in the footer of the editor.. +

+

+ In order to use the new plugin, include it in the config.extraPlugins configuration setting. +

+
+CKEDITOR.replace( 'textarea_id', {
+	extraPlugins: 'wordcount', 
+                maxWordCount: 4,
+	        maxCharCount: 10,
+                // optional events
+	        paragraphsCountGreaterThanMaxLengthEvent: function (currentLength, maxLength) {
+	                $("#informationparagraphs").css("background-color", "crimson").css("color", "white").text(currentLength + "/" + maxLength + " - paragraphs").show();
+	        },
+	        wordCountGreaterThanMaxLengthEvent: function (currentLength, maxLength) {
+	                $("#informationword").css("background-color", "crimson").css("color", "white").text(currentLength + "/" + maxLength + " - word").show();
+	        },
+	        charCountGreaterThanMaxLengthEvent: function (currentLength, maxLength) {
+	                $("#informationchar").css("background-color", "crimson").css("color", "white").text(currentLength + "/" + maxLength + " - char").show();
+	        },
+	        charCountLessThanMaxLengthEvent: function (currentLength, maxLength) {
+	                $("#informationchar").css("background-color", "white").css("color", "black").hide();
+	        },
+	        paragraphsCountLessThanMaxLengthEvent: function (currentLength, maxLength) {
+	                $("#informationparagraphs").css("background-color", "white").css("color", "black").hide();
+	        },
+	        wordCountLessThanMaxLengthEvent: function (currentLength, maxLength) {
+	                $("#informationword").css("background-color", "white").css("color", "black").hide();
+	        }
+} );
+
+
+ + +
+
+
+ + + + + Index: lams_central/web/ckeditor/skins/office2013/editor.css =================================================================== diff -u -rd238b1112e6f8a225ecfb67ad14b8a1ed6c01177 -rdca7fef745b8fcefbfd8aeba9df093b5ae204b0a --- lams_central/web/ckeditor/skins/office2013/editor.css (.../editor.css) (revision d238b1112e6f8a225ecfb67ad14b8a1ed6c01177) +++ lams_central/web/ckeditor/skins/office2013/editor.css (.../editor.css) (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -2,4 +2,5 @@ Copyright (c) 2003-2014, CKSource - Frederico Knabben. All rights reserved. For licensing, see LICENSE.md or http://ckeditor.com/license */ +@import url("notification.css"); .cke_reset{margin:0;padding:0;border:0;background:transparent;text-decoration:none;width:auto;height:auto;vertical-align:baseline;-moz-box-sizing:content-box;-webkit-box-sizing:content-box;box-sizing:content-box;position:static;-webkit-transition:none;-moz-transition:none;-ms-transition:none;transition:none}.cke_reset_all,.cke_reset_all *{margin:0;padding:0;border:0;background:transparent;text-decoration:none;width:auto;height:auto;vertical-align:baseline;-moz-box-sizing:content-box;-webkit-box-sizing:content-box;box-sizing:content-box;position:static;-webkit-transition:none;-moz-transition:none;-ms-transition:none;transition:none;border-collapse:collapse;font:normal normal normal 12px Arial,Helvetica,Tahoma,Verdana,Sans-Serif;color:#000;text-align:left;white-space:nowrap;cursor:auto;float:none}.cke_reset_all .cke_rtl *{text-align:right}.cke_reset_all iframe{vertical-align:inherit}.cke_reset_all textarea{white-space:pre}.cke_reset_all textarea,.cke_reset_all input[type="text"],.cke_reset_all input[type="password"]{cursor:text}.cke_reset_all textarea[disabled],.cke_reset_all input[type="text"][disabled],.cke_reset_all input[type="password"][disabled]{cursor:default}.cke_reset_all fieldset{padding:10px;border:2px groove #e0dfe3}.cke_reset_all select{-moz-box-sizing:border-box;-webkit-box-sizing:border-box;box-sizing:border-box}.cke_chrome{display:block;padding:0;border:1px solid #2b579a;box-shadow:0 0 6px 1px rgba(172,181,194,0.56)}.cke_inner{display:block;-webkit-touch-callout:none;background:#fff;padding:0}.cke_float{border:0}.cke_float .cke_inner{padding-bottom:0}.cke_top,.cke_contents,.cke_bottom{display:block;overflow:hidden}.cke_top{border-bottom:1px solid #e1e1e1;padding:6px 8px 2px;white-space:normal;background:#fff}.cke_float .cke_top{border:1px solid #b6b6b6;border-bottom-color:#999}.cke_bottom{padding:6px 8px 2px;position:relative;background:#2b579a}.cke_browser_ios .cke_contents{overflow-y:auto;-webkit-overflow-scrolling:touch}.cke_resizer{width:0;height:0;overflow:hidden;border-width:10px 10px 0 0;border-color:transparent #fff transparent transparent;border-style:dashed solid dashed dashed;font-size:0;vertical-align:bottom;margin-top:6px;margin-bottom:2px}.cke_hc .cke_resizer{font-size:15px;width:auto;height:auto;border-width:0}.cke_resizer_ltr{cursor:se-resize;float:right;margin-right:-4px}.cke_resizer_rtl{border-width:10px 0 0 10px;border-color:transparent transparent transparent #a5a5a5;border-style:dashed dashed dashed solid;cursor:sw-resize;float:left;margin-left:-4px;right:auto}.cke_wysiwyg_div{display:block;height:100%;overflow:auto;padding:0 8px;outline-style:none;-moz-box-sizing:border-box;-webkit-box-sizing:border-box;box-sizing:border-box}.cke_panel{visibility:visible;width:120px;height:100px;background-color:#fff;border:1px solid #c6c6c6}.cke_menu_panel{padding:0;margin:0}.cke_combopanel{width:150px;height:170px}.cke_panel_frame{width:100%;height:100%;font-size:12px;overflow:auto;overflow-x:hidden}.cke_panel_container{overflow-y:auto;overflow-x:hidden}.cke_panel_block{outline:0;display:table;width:100%;-moz-box-sizing:border-box;-webkit-box-sizing:border-box;box-sizing:border-box}.cke_panel_list{list-style-type:none;padding:0;margin:0;white-space:nowrap}.cke_panel_listItem{margin:0}.cke_panel_listItem a{padding:4px;margin:1px;display:block;color:inherit!important;text-decoration:none;overflow:hidden;text-overflow:ellipsis;cursor:default}.cke_panel_listItem.cke_selected a{background-color:#d3d3d3}.cke_panel_listItem a:hover,.cke_panel_listItem a:focus,.cke_panel_listItem a:active{background-color:#d5e1f2;outline:0}.cke_hc .cke_panel_listItem a{border-style:none}.cke_hc .cke_panel_listItem a:hover,.cke_hc .cke_panel_listItem a:focus,.cke_hc .cke_panel_listItem a:active{border:2px solid;padding:1px 2px}.cke_panel_grouptitle{font-size:11px;font-weight:bold;white-space:nowrap;margin:0;padding:8px 4px;color:#444;background:#f0f0f0;cursor:default}.cke_panel_listItem p,.cke_panel_listItem h1,.cke_panel_listItem h2,.cke_panel_listItem h3,.cke_panel_listItem h4,.cke_panel_listItem h5,.cke_panel_listItem h6,.cke_panel_listItem pre{margin-top:0;margin-bottom:0}.cke_colorblock{padding:3px;font-size:11px;font-family:'Microsoft Sans Serif',Tahoma,Arial,Verdana,Sans-Serif}.cke_colorblock,.cke_colorblock a{text-decoration:none;color:#000}span.cke_colorbox{width:10px;height:10px;border:#808080 1px solid;float:left}.cke_rtl span.cke_colorbox{float:right}a.cke_colorbox{border:#fff 1px solid;padding:2px;float:left;width:12px;height:12px}.cke_rtl a.cke_colorbox{float:right}a:hover.cke_colorbox,a:focus.cke_colorbox,a:active.cke_colorbox{border:#b6b6b6 1px solid;background-color:#e5e5e5}a.cke_colorauto,a.cke_colormore{border:#fff 1px solid;padding:2px 4px;display:block;cursor:pointer}a:hover.cke_colorauto,a:hover.cke_colormore,a:focus.cke_colorauto,a:focus.cke_colormore,a:active.cke_colorauto,a:active.cke_colormore{border:#d5e1f2 1px solid;background-color:#d5e1f2}.cke_toolbar{float:left}.cke_rtl .cke_toolbar{float:right}.cke_toolgroup{float:left;margin:0 6px 5px 0}.cke_hc .cke_toolgroup{border:0;margin-right:10px;margin-bottom:10px}.cke_rtl .cke_toolgroup{float:right;margin-left:6px;margin-right:0}a.cke_button{display:inline-block;height:16px;padding:2px;outline:0;cursor:default;float:left;border:1px solid transparent;margin:1px}.cke_rtl .cke_button{float:right}.cke_hc .cke_button{border:1px solid transparent;padding:2px}.cke_button_on{background:#c2d5f2}.cke_hc .cke_button_on,.cke_hc a.cke_button_off:hover,.cke_hc a.cke_button_off:focus,.cke_hc a.cke_button_off:active,.cke_hc a.cke_button_disabled:hover,.cke_hc a.cke_button_disabled:focus,.cke_hc a.cke_button_disabled:active{border-width:3px;padding:1px 3px}.cke_button_disabled .cke_button_icon{opacity:.3}.cke_hc .cke_button_disabled{opacity:.5}a.cke_button_off:hover,a.cke_button_off:focus,a.cke_button_off:active,a.cke_button_disabled:hover,a.cke_button_disabled:focus,a.cke_button_disabled:active{background:#d5e1f2}.cke_button_icon{cursor:inherit;background-repeat:no-repeat;width:16px;height:16px;float:left;display:inline-block}.cke_rtl .cke_button_icon{float:right}.cke_hc .cke_button_icon{display:none}.cke_button_label{display:none;padding-left:3px;margin-top:1px;line-height:17px;vertical-align:middle;float:left;cursor:default;color:#474747;text-shadow:0 1px 0 rgba(255,255,255,.5)}.cke_rtl .cke_button_label{padding-right:3px;padding-left:0;float:right}.cke_hc .cke_button_label{padding:0;display:inline-block;font-size:12px}.cke_button_arrow{display:inline-block;margin:8px 0 0 1px;width:0;height:0;cursor:default;vertical-align:top;border-left:3px solid transparent;border-right:3px solid transparent;border-top:3px solid #474747}.cke_rtl .cke_button_arrow{margin-right:5px;margin-left:0}.cke_hc .cke_button_arrow{font-size:10px;margin:3px -2px 0 3px;width:auto;border:0}.cke_toolbar_separator{float:left;background-color:#c0c0c0;background-color:rgba(0,0,0,.2);margin:5px 2px 0;height:18px;width:1px;box-shadow:1px 0 1px rgba(255,255,255,.5)}.cke_rtl .cke_toolbar_separator{float:right;box-shadow:-1px 0 1px rgba(255,255,255,.1)}.cke_hc .cke_toolbar_separator{width:0;border-left:1px solid;margin:1px 5px 0 0}.cke_toolbar_break{display:block;clear:left}.cke_rtl .cke_toolbar_break{clear:right}.cke_toolbox_collapser{width:12px;height:11px;float:right;margin:11px 0 0;font-size:0;cursor:default;text-align:center;border:1px solid #a6a6a6;background:#e4e4e4}.cke_toolbox_collapser:hover{background:#ccc}.cke_toolbox_collapser.cke_toolbox_collapser_min{margin:0 2px 4px}.cke_rtl .cke_toolbox_collapser{float:left}.cke_toolbox_collapser .cke_arrow{display:inline-block;height:0;width:0;font-size:0;margin-top:1px;border-left:3px solid transparent;border-right:3px solid transparent;border-bottom:3px solid #474747;border-top:3px solid transparent}.cke_toolbox_collapser.cke_toolbox_collapser_min .cke_arrow{margin-top:4px;border-bottom-color:transparent;border-top-color:#474747}.cke_hc .cke_toolbox_collapser .cke_arrow{font-size:8px;width:auto;border:0;margin-top:0;margin-right:2px}.cke_menubutton{display:block;margin:1px}.cke_menuitem span{cursor:default}.cke_menubutton:hover,.cke_menubutton:focus,.cke_menubutton:active{background-color:#d3d3d3;display:block;cursor:default}.cke_hc .cke_menubutton{padding:2px}.cke_hc .cke_menubutton:hover,.cke_hc .cke_menubutton:focus,.cke_hc .cke_menubutton:active{border:2px solid;padding:0}.cke_menubutton_inner{display:table-row}.cke_menubutton_icon,.cke_menubutton_label,.cke_menuarrow{display:table-cell}.cke_menubutton_icon{padding:4px}.cke_hc .cke_menubutton_icon{height:16px;width:0;padding:4px 0}.cke_menubutton_disabled:hover .cke_menubutton_icon,.cke_menubutton_disabled:focus .cke_menubutton_icon,.cke_menubutton_disabled:active .cke_menubutton_icon{opacity:.3;filter:alpha(opacity=30)}.cke_menubutton_label{padding:0 5px;background-color:transparent;width:100%;vertical-align:middle;color:#444}.cke_menubutton_disabled .cke_menubutton_label{opacity:.3;filter:alpha(opacity=30)}.cke_menubutton_on{background-color:#d5e1f2}.cke_menubutton_on .cke_menubutton_icon{padding-right:3px}.cke_menubutton:hover,.cke_menubutton:focus,.cke_menubutton:active{background-color:#d5e1f2;outline:0}.cke_panel_frame .cke_menubutton_label{display:none}.cke_menuseparator{background-color:#d3d3d3;height:1px;filter:alpha(opacity=70);opacity:.70}.cke_menuarrow{background-image:url(images/arrow.png);background-position:0 10px;background-repeat:no-repeat;padding:0 5px}.cke_rtl .cke_menuarrow{background-position:5px -13px;background-repeat:no-repeat}.cke_menuarrow span{display:none}.cke_hc .cke_menuarrow span{vertical-align:middle;display:inline}.cke_combo{display:inline-block;float:left}.cke_rtl .cke_combo{float:right}.cke_hc .cke_combo{margin-top:-2px}.cke_combo_label{display:none;float:left;line-height:26px;vertical-align:top;margin-right:5px}.cke_rtl .cke_combo_label{float:right;margin-left:5px;margin-right:0}.cke_combo_button{display:inline-block;float:left;margin:0 6px 5px 0;border:1px solid #e1e1e1;cursor:default;background:#fff}.cke_combo_off a.cke_combo_button:hover,.cke_combo_off a.cke_combo_button:focus{border-color:#a3bde3;outline:0}.cke_combo_off a.cke_combo_button:hover .cke_combo_open,.cke_combo_off a.cke_combo_button:focus .cke_combo_open{background:#d5e1f2;outline:0}.cke_combo_off a.cke_combo_button:active .cke_combo_open,.cke_combo_on a.cke_combo_button .cke_combo_open{background:#a3bde3}.cke_rtl .cke_combo_button{float:right;margin-left:5px;margin-right:0}.cke_hc a.cke_combo_button{padding:3px}.cke_hc .cke_combo_on a.cke_combo_button,.cke_hc .cke_combo_off a.cke_combo_button:hover,.cke_hc .cke_combo_off a.cke_combo_button:focus,.cke_hc .cke_combo_off a.cke_combo_button:active{border-width:3px;padding:1px}.cke_combo_text{line-height:22px;padding-left:10px;text-overflow:ellipsis;overflow:hidden;float:left;cursor:default;color:#474747;text-shadow:0 1px 0 rgba(255,255,255,.5);width:60px}.cke_rtl .cke_combo_text{float:right;text-align:right;padding-left:0;padding-right:10px}.cke_hc .cke_combo_text{line-height:18px;font-size:12px;vertical-align:top}.cke_combo_open{cursor:default;display:inline-block;vertical-align:top;font-size:0;height:22px;line-height:17px;padding:0 7px 0;width:5px}.cke_hc .cke_combo_open{height:12px}.cke_combo_arrow{margin:9px 0 0;float:left;height:0;width:0;font-size:0;border-left:3px solid transparent;border-right:3px solid transparent;border-top:3px solid #474747;cursor:default}.cke_hc .cke_combo_arrow{font-size:10px;width:auto;border:0;margin-top:3px}.cke_combo_disabled .cke_combo_inlinelabel,.cke_combo_disabled .cke_combo_open{opacity:.3}.cke_path{float:left;margin:-2px 0 2px}.cke_path_item,.cke_path_empty{display:inline-block;float:left;padding:3px 4px;margin-right:2px;cursor:default;text-decoration:none;outline:0;border:0;color:#fff;font-size:11px}.cke_rtl .cke_path,.cke_rtl .cke_path_item,.cke_rtl .cke_path_empty{float:right}a.cke_path_item:hover,a.cke_path_item:focus,a.cke_path_item:active{background-color:#fff;color:#2b579a}.cke_hc a.cke_path_item:hover,.cke_hc a.cke_path_item:focus,.cke_hc a.cke_path_item:active{border:2px solid;padding:1px 2px}.cke_button__source_label,.cke_button__sourcedialog_label{display:inline}.cke_combo__fontsize .cke_combo_text{width:30px}.cke_combopanel__fontsize{width:120px}.cke_source{font-family:'Courier New',Monospace;font-size:small;background-color:#fff;white-space:pre}.cke_wysiwyg_frame,.cke_wysiwyg_div{background-color:#fff}.cke_chrome{visibility:inherit}.cke_voice_label{display:none}legend.cke_voice_label{display:none}.cke_rtl .cke_button__copy_icon, .cke_mixed_dir_content .cke_rtl .cke_button__copy_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -0px !important;}.cke_ltr .cke_button__copy_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -128px !important;}.cke_rtl .cke_button__cut_icon, .cke_mixed_dir_content .cke_rtl .cke_button__cut_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -256px !important;}.cke_ltr .cke_button__cut_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -384px !important;}.cke_rtl .cke_button__paste_icon, .cke_mixed_dir_content .cke_rtl .cke_button__paste_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -512px !important;}.cke_ltr .cke_button__paste_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -640px !important;}.cke_rtl .cke_button__anchor_icon, .cke_mixed_dir_content .cke_rtl .cke_button__anchor_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -768px !important;}.cke_ltr .cke_button__anchor_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -896px !important;}.cke_button__link_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -1024px !important;}.cke_button__unlink_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -1152px !important;}.cke_rtl .cke_button__redo_icon, .cke_mixed_dir_content .cke_rtl .cke_button__redo_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -1280px !important;}.cke_ltr .cke_button__redo_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -1408px !important;}.cke_rtl .cke_button__undo_icon, .cke_mixed_dir_content .cke_rtl .cke_button__undo_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -1536px !important;}.cke_ltr .cke_button__undo_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -1664px !important;}.cke_button__bold_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -1792px !important;}.cke_button__italic_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -1920px !important;}.cke_button__strike_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -2048px !important;}.cke_button__subscript_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -2176px !important;}.cke_button__superscript_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -2304px !important;}.cke_button__underline_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -2432px !important;}.cke_button__bootstrapTabs_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -2560px !important;}.cke_button__bgcolor_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -2688px !important;}.cke_button__textcolor_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -2816px !important;}.cke_button__copyformatting_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -2944px !important;}.cke_button__creatediv_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -3072px !important;}.cke_button__embed_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -3200px !important;}.cke_button__emojione_icon {background: url(../../plugins/emojione/icons/emojione.png?t=dee79e2) no-repeat 0 0 !important; background-size: 100% !important;}.cke_rtl .cke_button__find_icon, .cke_mixed_dir_content .cke_rtl .cke_button__find_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -3456px !important;}.cke_ltr .cke_button__find_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -3584px !important;}.cke_button__replace_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -3712px !important;}.cke_button__flash_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -3840px !important;}.cke_button__button_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -3968px !important;}.cke_button__checkbox_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -4096px !important;}.cke_button__form_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -4224px !important;}.cke_button__hiddenfield_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -4352px !important;}.cke_button__imagebutton_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -4480px !important;}.cke_button__radio_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -4608px !important;}.cke_rtl .cke_button__select_icon, .cke_mixed_dir_content .cke_rtl .cke_button__select_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -4736px !important;}.cke_ltr .cke_button__select_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -4864px !important;}.cke_rtl .cke_button__textarea_icon, .cke_mixed_dir_content .cke_rtl .cke_button__textarea_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -4992px !important;}.cke_ltr .cke_button__textarea_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -5120px !important;}.cke_rtl .cke_button__textfield_icon, .cke_mixed_dir_content .cke_rtl .cke_button__textfield_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -5248px !important;}.cke_ltr .cke_button__textfield_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -5376px !important;}.cke_button__horizontalrule_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -5504px !important;}.cke_button__html5audio_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -5632px !important;}.cke_button__iframe_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -5760px !important;}.cke_button__image_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -5888px !important;}.cke_rtl .cke_button__indent_icon, .cke_mixed_dir_content .cke_rtl .cke_button__indent_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -6016px !important;}.cke_ltr .cke_button__indent_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -6144px !important;}.cke_rtl .cke_button__outdent_icon, .cke_mixed_dir_content .cke_rtl .cke_button__outdent_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -6272px !important;}.cke_ltr .cke_button__outdent_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -6400px !important;}.cke_button__justifyblock_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -6528px !important;}.cke_button__justifycenter_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -6656px !important;}.cke_button__justifyleft_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -6784px !important;}.cke_button__justifyright_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -6912px !important;}.cke_rtl .cke_button__bulletedlist_icon, .cke_mixed_dir_content .cke_rtl .cke_button__bulletedlist_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -7040px !important;}.cke_ltr .cke_button__bulletedlist_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -7168px !important;}.cke_rtl .cke_button__numberedlist_icon, .cke_mixed_dir_content .cke_rtl .cke_button__numberedlist_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -7296px !important;}.cke_ltr .cke_button__numberedlist_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -7424px !important;}.cke_button__maximize_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -7552px !important;}.cke_rtl .cke_button__pastefromword_icon, .cke_mixed_dir_content .cke_rtl .cke_button__pastefromword_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -7680px !important;}.cke_ltr .cke_button__pastefromword_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -7808px !important;}.cke_rtl .cke_button__preview_icon, .cke_mixed_dir_content .cke_rtl .cke_button__preview_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -7936px !important;}.cke_ltr .cke_button__preview_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -8064px !important;}.cke_rtl .cke_button__source_icon, .cke_mixed_dir_content .cke_rtl .cke_button__source_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -8192px !important;}.cke_ltr .cke_button__source_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -8320px !important;}.cke_rtl .cke_button__sourcedialog_icon, .cke_mixed_dir_content .cke_rtl .cke_button__sourcedialog_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -8448px !important;}.cke_ltr .cke_button__sourcedialog_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -8576px !important;}.cke_button__table_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -8704px !important;}.cke_rtl .cke_button__templates_icon, .cke_mixed_dir_content .cke_rtl .cke_button__templates_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -8832px !important;}.cke_ltr .cke_button__templates_icon {background: url(icons.png?t=17a1555f7f) no-repeat 0 -8960px !important;}.cke_rtl.cke_hidpi .cke_button__copy_icon, .cke_hidpi .cke_mixed_dir_content .cke_rtl .cke_button__copy_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -0px !important;background-size: 60px !important;}.cke_hidpi .cke_ltr .cke_button__copy_icon,.cke_ltr.cke_hidpi .cke_button__copy_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -68px !important;background-size: 60px !important;}.cke_rtl.cke_hidpi .cke_button__cut_icon, .cke_hidpi .cke_mixed_dir_content .cke_rtl .cke_button__cut_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -136px !important;background-size: 60px !important;}.cke_hidpi .cke_ltr .cke_button__cut_icon,.cke_ltr.cke_hidpi .cke_button__cut_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -204px !important;background-size: 60px !important;}.cke_rtl.cke_hidpi .cke_button__paste_icon, .cke_hidpi .cke_mixed_dir_content .cke_rtl .cke_button__paste_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -272px !important;background-size: 60px !important;}.cke_hidpi .cke_ltr .cke_button__paste_icon,.cke_ltr.cke_hidpi .cke_button__paste_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -340px !important;background-size: 60px !important;}.cke_rtl.cke_hidpi .cke_button__anchor_icon, .cke_hidpi .cke_mixed_dir_content .cke_rtl .cke_button__anchor_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -408px !important;background-size: 60px !important;}.cke_hidpi .cke_ltr .cke_button__anchor_icon,.cke_ltr.cke_hidpi .cke_button__anchor_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -476px !important;background-size: 60px !important;}.cke_hidpi .cke_button__link_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -544px !important;background-size: 60px !important;}.cke_hidpi .cke_button__unlink_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -612px !important;background-size: 60px !important;}.cke_rtl.cke_hidpi .cke_button__redo_icon, .cke_hidpi .cke_mixed_dir_content .cke_rtl .cke_button__redo_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -680px !important;background-size: 60px !important;}.cke_hidpi .cke_ltr .cke_button__redo_icon,.cke_ltr.cke_hidpi .cke_button__redo_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -748px !important;background-size: 60px !important;}.cke_rtl.cke_hidpi .cke_button__undo_icon, .cke_hidpi .cke_mixed_dir_content .cke_rtl .cke_button__undo_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -816px !important;background-size: 60px !important;}.cke_hidpi .cke_ltr .cke_button__undo_icon,.cke_ltr.cke_hidpi .cke_button__undo_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -884px !important;background-size: 60px !important;}.cke_hidpi .cke_button__bold_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -952px !important;background-size: 60px !important;}.cke_hidpi .cke_button__italic_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -1020px !important;background-size: 60px !important;}.cke_hidpi .cke_button__strike_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -1088px !important;background-size: 60px !important;}.cke_hidpi .cke_button__subscript_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -1156px !important;background-size: 60px !important;}.cke_hidpi .cke_button__superscript_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -1224px !important;background-size: 60px !important;}.cke_hidpi .cke_button__underline_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -1292px !important;background-size: 60px !important;}.cke_hidpi .cke_button__bootstrapTabs_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -2720px !important;}.cke_hidpi .cke_button__bgcolor_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -1428px !important;background-size: 60px !important;}.cke_hidpi .cke_button__textcolor_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -1496px !important;background-size: 60px !important;}.cke_hidpi .cke_button__copyformatting_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -1564px !important;background-size: 60px !important;}.cke_hidpi .cke_button__creatediv_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -1632px !important;background-size: 60px !important;}.cke_hidpi .cke_button__embed_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -1700px !important;background-size: 60px !important;}.cke_hidpi .cke_button__emojione_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -3536px !important;}.cke_rtl.cke_hidpi .cke_button__find_icon, .cke_hidpi .cke_mixed_dir_content .cke_rtl .cke_button__find_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -1836px !important;background-size: 60px !important;}.cke_hidpi .cke_ltr .cke_button__find_icon,.cke_ltr.cke_hidpi .cke_button__find_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -1904px !important;background-size: 60px !important;}.cke_hidpi .cke_button__replace_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -1972px !important;background-size: 60px !important;}.cke_hidpi .cke_button__flash_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -2040px !important;background-size: 60px !important;}.cke_hidpi .cke_button__button_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -2108px !important;background-size: 60px !important;}.cke_hidpi .cke_button__checkbox_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -2176px !important;background-size: 60px !important;}.cke_hidpi .cke_button__form_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -2244px !important;background-size: 60px !important;}.cke_hidpi .cke_button__hiddenfield_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -2312px !important;background-size: 60px !important;}.cke_hidpi .cke_button__imagebutton_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -2380px !important;background-size: 60px !important;}.cke_hidpi .cke_button__radio_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -2448px !important;background-size: 60px !important;}.cke_rtl.cke_hidpi .cke_button__select_icon, .cke_hidpi .cke_mixed_dir_content .cke_rtl .cke_button__select_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -2516px !important;background-size: 60px !important;}.cke_hidpi .cke_ltr .cke_button__select_icon,.cke_ltr.cke_hidpi .cke_button__select_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -2584px !important;background-size: 60px !important;}.cke_rtl.cke_hidpi .cke_button__textarea_icon, .cke_hidpi .cke_mixed_dir_content .cke_rtl .cke_button__textarea_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -2652px !important;background-size: 60px !important;}.cke_hidpi .cke_ltr .cke_button__textarea_icon,.cke_ltr.cke_hidpi .cke_button__textarea_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -2720px !important;background-size: 60px !important;}.cke_rtl.cke_hidpi .cke_button__textfield_icon, .cke_hidpi .cke_mixed_dir_content .cke_rtl .cke_button__textfield_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -2788px !important;background-size: 60px !important;}.cke_hidpi .cke_ltr .cke_button__textfield_icon,.cke_ltr.cke_hidpi .cke_button__textfield_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -2856px !important;background-size: 60px !important;}.cke_hidpi .cke_button__horizontalrule_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -2924px !important;background-size: 60px !important;}.cke_hidpi .cke_button__html5audio_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -2992px !important;background-size: 60px !important;}.cke_hidpi .cke_button__iframe_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -3060px !important;background-size: 60px !important;}.cke_hidpi .cke_button__image_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -3128px !important;background-size: 60px !important;}.cke_rtl.cke_hidpi .cke_button__indent_icon, .cke_hidpi .cke_mixed_dir_content .cke_rtl .cke_button__indent_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -3196px !important;background-size: 60px !important;}.cke_hidpi .cke_ltr .cke_button__indent_icon,.cke_ltr.cke_hidpi .cke_button__indent_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -3264px !important;background-size: 60px !important;}.cke_rtl.cke_hidpi .cke_button__outdent_icon, .cke_hidpi .cke_mixed_dir_content .cke_rtl .cke_button__outdent_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -3332px !important;background-size: 60px !important;}.cke_hidpi .cke_ltr .cke_button__outdent_icon,.cke_ltr.cke_hidpi .cke_button__outdent_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -3400px !important;background-size: 60px !important;}.cke_hidpi .cke_button__justifyblock_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -3468px !important;background-size: 60px !important;}.cke_hidpi .cke_button__justifycenter_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -3536px !important;background-size: 60px !important;}.cke_hidpi .cke_button__justifyleft_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -3604px !important;background-size: 60px !important;}.cke_hidpi .cke_button__justifyright_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -3672px !important;background-size: 60px !important;}.cke_rtl.cke_hidpi .cke_button__bulletedlist_icon, .cke_hidpi .cke_mixed_dir_content .cke_rtl .cke_button__bulletedlist_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -3740px !important;background-size: 60px !important;}.cke_hidpi .cke_ltr .cke_button__bulletedlist_icon,.cke_ltr.cke_hidpi .cke_button__bulletedlist_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -3808px !important;background-size: 60px !important;}.cke_rtl.cke_hidpi .cke_button__numberedlist_icon, .cke_hidpi .cke_mixed_dir_content .cke_rtl .cke_button__numberedlist_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -3876px !important;background-size: 60px !important;}.cke_hidpi .cke_ltr .cke_button__numberedlist_icon,.cke_ltr.cke_hidpi .cke_button__numberedlist_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -3944px !important;background-size: 60px !important;}.cke_hidpi .cke_button__maximize_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -4012px !important;background-size: 60px !important;}.cke_rtl.cke_hidpi .cke_button__pastefromword_icon, .cke_hidpi .cke_mixed_dir_content .cke_rtl .cke_button__pastefromword_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -4080px !important;background-size: 60px !important;}.cke_hidpi .cke_ltr .cke_button__pastefromword_icon,.cke_ltr.cke_hidpi .cke_button__pastefromword_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -4148px !important;background-size: 60px !important;}.cke_rtl.cke_hidpi .cke_button__preview_icon, .cke_hidpi .cke_mixed_dir_content .cke_rtl .cke_button__preview_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -4216px !important;background-size: 60px !important;}.cke_hidpi .cke_ltr .cke_button__preview_icon,.cke_ltr.cke_hidpi .cke_button__preview_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -4284px !important;background-size: 60px !important;}.cke_rtl.cke_hidpi .cke_button__source_icon, .cke_hidpi .cke_mixed_dir_content .cke_rtl .cke_button__source_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -4352px !important;background-size: 60px !important;}.cke_hidpi .cke_ltr .cke_button__source_icon,.cke_ltr.cke_hidpi .cke_button__source_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -4420px !important;background-size: 60px !important;}.cke_rtl.cke_hidpi .cke_button__sourcedialog_icon, .cke_hidpi .cke_mixed_dir_content .cke_rtl .cke_button__sourcedialog_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -4488px !important;background-size: 60px !important;}.cke_hidpi .cke_ltr .cke_button__sourcedialog_icon,.cke_ltr.cke_hidpi .cke_button__sourcedialog_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -4556px !important;background-size: 60px !important;}.cke_hidpi .cke_button__table_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -4624px !important;background-size: 60px !important;}.cke_rtl.cke_hidpi .cke_button__templates_icon, .cke_hidpi .cke_mixed_dir_content .cke_rtl .cke_button__templates_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -4692px !important;background-size: 60px !important;}.cke_hidpi .cke_ltr .cke_button__templates_icon,.cke_ltr.cke_hidpi .cke_button__templates_icon {background: url(icons_hidpi.png?t=17a1555f7f) no-repeat 0 -4760px !important;background-size: 60px !important;} \ No newline at end of file Index: lams_central/web/ckeditor/skins/office2013/notification.css =================================================================== diff -u --- lams_central/web/ckeditor/skins/office2013/notification.css (revision 0) +++ lams_central/web/ckeditor/skins/office2013/notification.css (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -0,0 +1,168 @@ +/* +Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license +*/ + +/** + * Progress notification structure: + * + * +---div.cke_notification cke_notification_info--------------------------+ + * | | + * | +---div.cke_notification_progress-----------------------------------+ | + * | | | | + * | +-------------------------------------------------------------------+ | + * | | + * | +---p.cke_notification_message--------------------------------------+ | + * | | Foo | | + * | +-------------------------------------------------------------------+ | + * | | + * | +---a.cke_notification_close----------------------------------------+ | + * | | +---span.cke_label----------------------------------------------+ | | + * | | | X | | | + * | | +---------------------------------------------------------------+ | | + * | +-------------------------------------------------------------------+ | + * | | + * +-----------------------------------------------------------------------+ + * + * + * Warning notification structure: + * + * +---div.cke_notification cke_notification_warning-----------------------+ + * | | + * | +---p.cke_notification_message--------------------------------------+ | + * | | Foo | | + * | +-------------------------------------------------------------------+ | + * | | + * | +---a.cke_notification_close----------------------------------------+ | + * | | +---span.cke_label----------------------------------------------+ | | + * | | | X | | | + * | | +---------------------------------------------------------------+ | | + * | +-------------------------------------------------------------------+ | + * | | + * +-----------------------------------------------------------------------+ + * + * Success and info notifications have the same structure as warning, but use + * `cke_notification_success` and `cke_notification_info` instead of `cke_notification_warning`. + */ +.cke_notifications_area +{ + /* Prevent notification margin capture clicking. */ + pointer-events: none; +} +.cke_notification +{ + pointer-events: auto; + position: relative; + margin: 10px; + width: 300px; + color: white; + border-radius: 3px; + text-align: center; + opacity: 0.95; + filter: alpha(opacity = 95); + box-shadow: 2px 2px 3px 0px rgba(50, 50, 50, 0.3); + + -webkit-animation: fadeIn 0.7s; + animation: fadeIn 0.7s; +} + +.cke_notification_message a +{ + color: #12306F; +} + +@-webkit-keyframes fadeIn +{ + from { opacity: 0.4; } + to { opacity: 0.95; } +} + +@keyframes fadeIn +{ + from { opacity: 0.4; } + to { opacity: 0.95; } +} + +.cke_notification_success +{ + background: #72B572; + border: 1px solid #63A563; +} + +.cke_notification_warning +{ + background: #C83939; + border: 1px solid #902B2B; +} + +.cke_notification_info +{ + background: #2E9AD0; + border: 1px solid #0F74A8; +} + +.cke_notification_info span.cke_notification_progress +{ + background-color: #0F74A8; + display: block; + padding: 0; + margin: 0; + height: 100%; + overflow: hidden; + position: absolute; + z-index: 1; +} + +.cke_notification_message +{ + position: relative; + margin: 4px 23px 3px; + font-family: Arial, Helvetica, sans-serif; + font-size: 12px; + line-height: 18px; + z-index: 4; + text-overflow: ellipsis; + overflow: hidden; +} + +.cke_notification_close +{ + background-image: url(images/close.png); + background-repeat: no-repeat; + background-position: 50%; + position: absolute; + cursor: pointer; + text-align: center; + height: 20px; + width: 20px; + top: 1px; + right: 1px; + padding: 0; + margin: 0; + z-index: 5; + opacity: 0.6; + filter: alpha(opacity = 60); +} + +.cke_notification_close:hover +{ + opacity: 1; + filter: alpha(opacity = 100); +} + +.cke_notification_close span +{ + display: none; +} + +.cke_notification_warning a.cke_notification_close +{ + opacity: 0.8; + filter: alpha(opacity = 80); +} + +.cke_notification_warning a.cke_notification_close:hover +{ + opacity: 1; + filter: alpha(opacity = 100); +} \ No newline at end of file Index: lams_central/web/includes/javascript/ckconfig_custom.js =================================================================== diff -u -r92525f17be9db4e57a8551ff92d004f319fb4b73 -rdca7fef745b8fcefbfd8aeba9df093b5ae204b0a --- lams_central/web/includes/javascript/ckconfig_custom.js (.../ckconfig_custom.js) (revision 92525f17be9db4e57a8551ff92d004f319fb4b73) +++ lams_central/web/includes/javascript/ckconfig_custom.js (.../ckconfig_custom.js) (revision dca7fef745b8fcefbfd8aeba9df093b5ae204b0a) @@ -119,7 +119,7 @@ CKEDITOR.config.format_tags = 'div;h1;h2;h3;h4;h5;h6;pre;address;p' ; CKEDITOR.plugins.addExternal('wikilink', CKEDITOR.basePath + '../tool/lawiki10/wikilink/', 'plugin.js'); // html5audio is available but not used anymore; it probably needs fixes as in CKEditor README doc -CKEDITOR.config.extraPlugins = 'wikilink,jlatexmath,image2,confighelper,bootstrapTabs,bootpanel,bootsnippets,wavepanel'; +CKEDITOR.config.extraPlugins = 'wikilink,jlatexmath,image2,confighelper,bootstrapTabs,bootpanel,bootsnippets,wavepanel,wordcount,notification'; CKEDITOR.config.enterMode = CKEDITOR.ENTER_DIV; CKEDITOR.config.removePlugins = 'elementspath,about,specialchar'; CKEDITOR.config.allowedContent = true;