From 640d20492f292b28b236f828675e42d4f732c697 Mon Sep 17 00:00:00 2001 From: bernhard Date: Fri, 2 Aug 2024 10:10:59 +0200 Subject: [PATCH] Accept suggestions from CodePolicy --- CHANGES.md | 2 -- Kernel/System/Web/UploadCache/FS.pm | 2 +- var/httpd/htdocs/common/css/CKEditor.min.css | 2 +- var/httpd/htdocs/js/Core.UI.RichTextEditor.js | 2 +- 4 files changed, 3 insertions(+), 5 deletions(-) diff --git a/CHANGES.md b/CHANGES.md index 90e18c1d64..0135ef3828 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -2216,5 +2216,3 @@ # OTOBO 10.0.0 beta1 2020-01-30 - First official OTOBO release, yippie! - - diff --git a/Kernel/System/Web/UploadCache/FS.pm b/Kernel/System/Web/UploadCache/FS.pm index 5b7fb6e142..e37d1f9666 100644 --- a/Kernel/System/Web/UploadCache/FS.pm +++ b/Kernel/System/Web/UploadCache/FS.pm @@ -20,7 +20,7 @@ use strict; use warnings; use File::Basename qw(basename); -use List::Util qw(sum); +use List::Util qw(sum); our @ObjectDependencies = ( 'Kernel::Config', diff --git a/var/httpd/htdocs/common/css/CKEditor.min.css b/var/httpd/htdocs/common/css/CKEditor.min.css index 1e3964e3f1..7a1fc073fd 100644 --- a/var/httpd/htdocs/common/css/CKEditor.min.css +++ b/var/httpd/htdocs/common/css/CKEditor.min.css @@ -1 +1 @@ -:root{--ck-color-image-caption-background:hsl(0,0%,97%);--ck-color-image-caption-text:hsl(0,0%,20%);--ck-color-mention-background:hsla(341,100%,30%,.1);--ck-color-mention-text:hsl(341,100%,30%);--ck-color-selector-caption-background:hsl(0,0%,97%);--ck-color-selector-caption-text:hsl(0,0%,20%);--ck-highlight-marker-blue:hsl(201,97%,72%);--ck-highlight-marker-green:hsl(120,93%,68%);--ck-highlight-marker-pink:hsl(345,96%,73%);--ck-highlight-marker-yellow:hsl(60,97%,73%);--ck-highlight-pen-green:hsl(112,100%,27%);--ck-highlight-pen-red:hsl(0,85%,49%);--ck-image-style-spacing:1.5em;--ck-inline-image-style-spacing:calc(var(--ck-image-style-spacing) / 2);--ck-todo-list-checkmark-size:16px;--otobo-colMainLight:#001bff}.table .ck-table-resized{table-layout:fixed}.table table{overflow:hidden;border-collapse:collapse;border-spacing:0;width:100%;height:100%;border:1px double #b2b2b2}.image img,img.image_resized{height:auto}.table td,.table th{overflow-wrap:break-word;position:relative}.table{margin:.9em auto;display:table;}table{font-size:inherit;}.table table td,.table table th{min-width:2em;padding:.4em;border:1px solid #bfbfbf}.table table th{font-weight:700;background:hsla(0,0%,0%,5%)}.table[dir=rtl] th{text-align:right}.table[dir=ltr] th,pre{text-align:left}.page-break{position:relative;clear:both;padding:5px 0;display:flex;align-items:center;justify-content:center}.image img,.image.image_resized>figcaption,.media,.page-break__label{display:block}.page-break::after{content:'';position:absolute;border-bottom:2px dashed #c4c4c4;width:100%}.page-break__label{position:relative;z-index:1;padding:.3em .6em;text-transform:uppercase;border:1px solid #c4c4c4;border-radius:2px;font-family:Helvetica,Arial,Tahoma,Verdana,Sans-Serif;font-size:.75em;font-weight:700;color:#333;background:#fff;box-shadow:2px 2px 1px hsla(0,0%,0%,.15);-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.media{clear:both;margin:.9em 0;min-width:15em}ol{list-style-type:decimal}ol ol{list-style-type:lower-latin}ol ol ol{list-style-type:lower-roman}ol ol ol ol{list-style-type:upper-latin}ol ol ol ol ol{list-style-type:upper-roman}ul{list-style-type:disc}ul ul{list-style-type:circle}ul ul ul,ul ul ul ul{list-style-type:square}.image{display:table;clear:both;text-align:center;margin:.9em auto;min-width:50px}.image img{margin:0 auto;max-width:100%;min-width:100%}.image-inline{display:inline-flex;max-width:100%;align-items:flex-start}.image-inline picture{display:flex}.image-inline img,.image-inline picture{flex-grow:1;flex-shrink:1;max-width:100%}.image.image_resized{max-width:100%;display:block;box-sizing:border-box}.image.image_resized img{width:100%}.image>figcaption{display:table-caption;caption-side:bottom;word-break:break-word;color:var(--ck-color-image-caption-text);background-color:var(--ck-color-image-caption-background);padding:.6em;font-size:.75em;outline-offset:-1px}.image-style-block-align-left,.image-style-block-align-right{max-width:calc(100% - var(--ck-image-style-spacing))}.image-style-align-left,.image-style-align-right{clear:none}.image-style-side{float:right;margin-left:var(--ck-image-style-spacing);max-width:50%}.image-style-align-left{float:left;margin-right:var(--ck-image-style-spacing)}.image-style-align-center{margin-left:auto;margin-right:auto}.image-style-align-right{float:right;margin-left:var(--ck-image-style-spacing)}.image-style-block-align-right{margin-right:0;margin-left:auto}.image-style-block-align-left{margin-left:0;margin-right:auto}p+.image-style-align-left,p+.image-style-align-right,p+.image-style-side{margin-top:0}.image-inline.image-style-align-left,.image-inline.image-style-align-right{margin-top:var(--ck-inline-image-style-spacing);margin-bottom:var(--ck-inline-image-style-spacing)}.image-inline.image-style-align-left{margin-right:var(--ck-inline-image-style-spacing)}.image-inline.image-style-align-right{margin-left:var(--ck-inline-image-style-spacing)}.marker-yellow{background-color:var(--ck-highlight-marker-yellow)}.marker-green{background-color:var(--ck-highlight-marker-green)}.marker-pink{background-color:var(--ck-highlight-marker-pink)}.marker-blue{background-color:var(--ck-highlight-marker-blue)}.pen-green,.pen-red{background-color:transparent}.pen-red{color:var(--ck-highlight-pen-red)}.pen-green{color:var(--ck-highlight-pen-green)}blockquote{overflow:hidden;padding:0 0 0 4pt;margin-left:0;margin-right:0;font-style:normal;border-left:solid var(--otobo-colMainLight) 1.5pt}.ck-content[dir=rtl] blockquote{border-left:0;border-right:solid var(--otobo-colMainLight) 1.5pt}code{background-color:hsla(0,0%,78%,.3);padding:.15em;border-radius:2px}hr{margin:15px 0;height:4px;background:#ddd;border:0}pre{padding:1em;color:hsl(0,0%,20.8%);background:hsla(0,0%,78%,.3);border:1px solid #c4c4c4;border-radius:2px;direction:ltr;tab-size:4;white-space:pre-wrap;font-style:normal;min-width:200px}pre code{background:unset;padding:0;border-radius:0}@media print{.page-break{padding:0}.page-break::after{display:none}} \ No newline at end of file +:root{--ck-color-image-caption-background:hsl(0,0%,97%);--ck-color-image-caption-text:hsl(0,0%,20%);--ck-color-mention-background:hsla(341,100%,30%,.1);--ck-color-mention-text:hsl(341,100%,30%);--ck-color-selector-caption-background:hsl(0,0%,97%);--ck-color-selector-caption-text:hsl(0,0%,20%);--ck-highlight-marker-blue:hsl(201,97%,72%);--ck-highlight-marker-green:hsl(120,93%,68%);--ck-highlight-marker-pink:hsl(345,96%,73%);--ck-highlight-marker-yellow:hsl(60,97%,73%);--ck-highlight-pen-green:hsl(112,100%,27%);--ck-highlight-pen-red:hsl(0,85%,49%);--ck-image-style-spacing:1.5em;--ck-inline-image-style-spacing:calc(var(--ck-image-style-spacing) / 2);--ck-todo-list-checkmark-size:16px;--otobo-colMainLight:#001bff}.table .ck-table-resized{table-layout:fixed}.table table{overflow:hidden;border-collapse:collapse;border-spacing:0;width:100%;height:100%;border:1px double #b2b2b2}.image img,img.image_resized{height:auto}.table td,.table th{overflow-wrap:break-word;position:relative}.table{margin:.9em auto;display:table;}table{font-size:inherit;}.table table td,.table table th{min-width:2em;padding:.4em;border:1px solid #bfbfbf}.table table th{font-weight:700;background:hsla(0,0%,0%,5%)}.table[dir=rtl] th{text-align:right}.table[dir=ltr] th,pre{text-align:left}.page-break{position:relative;clear:both;padding:5px 0;display:flex;align-items:center;justify-content:center}.image img,.image.image_resized>figcaption,.media,.page-break__label{display:block}.page-break::after{content:'';position:absolute;border-bottom:2px dashed #c4c4c4;width:100%}.page-break__label{position:relative;z-index:1;padding:.3em .6em;text-transform:uppercase;border:1px solid #c4c4c4;border-radius:2px;font-family:Helvetica,Arial,Tahoma,Verdana,Sans-Serif;font-size:.75em;font-weight:700;color:#333;background:#fff;box-shadow:2px 2px 1px hsla(0,0%,0%,.15);-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.media{clear:both;margin:.9em 0;min-width:15em}ol{list-style-type:decimal}ol ol{list-style-type:lower-latin}ol ol ol{list-style-type:lower-roman}ol ol ol ol{list-style-type:upper-latin}ol ol ol ol ol{list-style-type:upper-roman}ul{list-style-type:disc}ul ul{list-style-type:circle}ul ul ul,ul ul ul ul{list-style-type:square}.image{display:table;clear:both;text-align:center;margin:.9em auto;min-width:50px}.image img{margin:0 auto;max-width:100%;min-width:100%}.image-inline{display:inline-flex;max-width:100%;align-items:flex-start}.image-inline picture{display:flex}.image-inline img,.image-inline picture{flex-grow:1;flex-shrink:1;max-width:100%}.image.image_resized{max-width:100%;display:block;box-sizing:border-box}.image.image_resized img{width:100%}.image>figcaption{display:table-caption;caption-side:bottom;word-break:break-word;color:var(--ck-color-image-caption-text);background-color:var(--ck-color-image-caption-background);padding:.6em;font-size:.75em;outline-offset:-1px}.image-style-block-align-left,.image-style-block-align-right{max-width:calc(100% - var(--ck-image-style-spacing))}.image-style-align-left,.image-style-align-right{clear:none}.image-style-side{float:right;margin-left:var(--ck-image-style-spacing);max-width:50%}.image-style-align-left{float:left;margin-right:var(--ck-image-style-spacing)}.image-style-align-center{margin-left:auto;margin-right:auto}.image-style-align-right{float:right;margin-left:var(--ck-image-style-spacing)}.image-style-block-align-right{margin-right:0;margin-left:auto}.image-style-block-align-left{margin-left:0;margin-right:auto}p+.image-style-align-left,p+.image-style-align-right,p+.image-style-side{margin-top:0}.image-inline.image-style-align-left,.image-inline.image-style-align-right{margin-top:var(--ck-inline-image-style-spacing);margin-bottom:var(--ck-inline-image-style-spacing)}.image-inline.image-style-align-left{margin-right:var(--ck-inline-image-style-spacing)}.image-inline.image-style-align-right{margin-left:var(--ck-inline-image-style-spacing)}.marker-yellow{background-color:var(--ck-highlight-marker-yellow)}.marker-green{background-color:var(--ck-highlight-marker-green)}.marker-pink{background-color:var(--ck-highlight-marker-pink)}.marker-blue{background-color:var(--ck-highlight-marker-blue)}.pen-green,.pen-red{background-color:transparent}.pen-red{color:var(--ck-highlight-pen-red)}.pen-green{color:var(--ck-highlight-pen-green)}blockquote{overflow:hidden;padding:0 0 0 4pt;margin-left:0;margin-right:0;font-style:normal;border-left:solid var(--otobo-colMainLight) 1.5pt}.ck-content[dir=rtl] blockquote{border-left:0;border-right:solid var(--otobo-colMainLight) 1.5pt}code{background-color:hsla(0,0%,78%,.3);padding:.15em;border-radius:2px}hr{margin:15px 0;height:4px;background:#ddd;border:0}pre{padding:1em;color:hsl(0,0%,20.8%);background:hsla(0,0%,78%,.3);border:1px solid #c4c4c4;border-radius:2px;direction:ltr;tab-size:4;white-space:pre-wrap;font-style:normal;min-width:200px}pre code{background:unset;padding:0;border-radius:0}@media print{.page-break{padding:0}.page-break::after{display:none}} diff --git a/var/httpd/htdocs/js/Core.UI.RichTextEditor.js b/var/httpd/htdocs/js/Core.UI.RichTextEditor.js index c04ba45b9a..3c48d05de3 100644 --- a/var/httpd/htdocs/js/Core.UI.RichTextEditor.js +++ b/var/httpd/htdocs/js/Core.UI.RichTextEditor.js @@ -332,7 +332,7 @@ Core.UI.RichTextEditor = (function (TargetNS) { $domEditableElement.css("height", Math.max(editorMinHeight, Core.Config.Get("RichText.Height"))); $domEditableElement.css("width", Math.min(editorMaxWidth, Core.Config.Get("RichText.Width"))); } - + Core.App.Publish('Event.UI.RichTextEditor.InstanceCreated', [editor]); // workaround for ckeditor not using data filter correctly on prefilled content