N°7552 - Move CKEditor from to npm dependencies

This commit is contained in:
Stephen Abello
2024-07-24 14:19:52 +02:00
parent 35a7d907cd
commit 054fd8798b
126 changed files with 210 additions and 7981 deletions

View File

@@ -253,7 +253,7 @@ HTML;
{
// all js file needed by ckeditor
$aJSRelPaths = [
'js/ckeditor/build/ckeditor.js',
'node_modules/ckeditor5-itop-build/build/ckeditor.js',
'js/highlight/highlight.js',
'js/ckeditor.handler.js',
'js/ckeditor.feeds.js'
@@ -267,12 +267,12 @@ HTML;
// add corresponding ckeditor language file
// P1 language + country
// P2 language
$sLanguageFileRelPath = 'js/ckeditor/build/translations/' . $sLanguage . '-' . $sCountry . '.js';
$sLanguageFileRelPath = 'node_modules/ckeditor5-itop-build/build/translations/' . $sLanguage . '-' . $sCountry . '.js';
if(file_exists(APPROOT . $sLanguageFileRelPath)){
$aJSRelPaths[] = $sLanguageFileRelPath;
}
else {
$sLanguageFileRelPath = 'js/ckeditor/build/translations/' . $sLanguage . '.js';
$sLanguageFileRelPath = 'node_modules/ckeditor5-itop-build/build/translations/' . $sLanguage . '.js';
if(file_exists(APPROOT . $sLanguageFileRelPath)){
$aJSRelPaths[] = $sLanguageFileRelPath;
}