From d73f39f61db46f41788f705badd193845a0366df Mon Sep 17 00:00:00 2001 From: Cameron Date: Sun, 17 Dec 2017 13:12:47 -0800 Subject: [PATCH] TinyMce left/right image alignment class added. bbcode-img-left bbcode-img-right --- e107_plugins/tinymce4/editor.css | 4 ++++ e107_plugins/tinymce4/wysiwyg.php | 6 +++--- e107_web/css/e107.css | 4 ++++ 3 files changed, 11 insertions(+), 3 deletions(-) diff --git a/e107_plugins/tinymce4/editor.css b/e107_plugins/tinymce4/editor.css index ecfbe128b..bd9d1b51a 100644 --- a/e107_plugins/tinymce4/editor.css +++ b/e107_plugins/tinymce4/editor.css @@ -4,6 +4,10 @@ div.clearfix { margin-bottom:10px; } ul.fa-ul { padding-left:5px} li { padding:4px } ul { padding-bottom:8px } + +.bbcode-img-left { margin: 0 10px 5px 0 !important; float:left !important } +.bbcode-img-right { margin: 0 0 5px 10px !important; float:right !important} + .mce-visualblocks li { outline: 1px dashed silver; } .mce-visualblocks ul.fa-ul { padding-left:30px } .mce-visualblocks .animated, diff --git a/e107_plugins/tinymce4/wysiwyg.php b/e107_plugins/tinymce4/wysiwyg.php index 171ffe189..c6a5bdbe9 100644 --- a/e107_plugins/tinymce4/wysiwyg.php +++ b/e107_plugins/tinymce4/wysiwyg.php @@ -549,8 +549,8 @@ class wysiwyg {title: 'Justify', block: 'div', classes: 'text-justify', icon: 'alignjustify'}, {title: 'No Text-Wrap', block: 'div', classes: 'text-nowrap', icon: ''}, {title: 'Clear Float', block: 'div', classes: 'clearfix'}, - {title: 'Image Left', selector: 'img', classes: 'pull-left', styles: {'margin': '0 10px 5px 0' }, icon: 'alignleft'}, - {title: 'Image Right', selector: 'img', classes: 'pull-right', styles: { 'margin': '0 0 5px 10px'}, icon: 'alignright'} + {title: 'Image Left', selector: 'img', classes: 'bbcode-img-left', icon: 'alignleft'}, + {title: 'Image Right', selector: 'img', classes: 'bbcode-img-right', icon: 'alignright'} ]}, @@ -854,7 +854,7 @@ class wysiwyg 0 => $pathBS . '/dist/css/bootstrap.min.css', 1 => $pathFA . '/css/font-awesome.min.css', 2 => e_PLUGIN_ABS . 'tinymce4/editor.css', - 3 => $pathAn . '/animate.min.css', + 3 => $pathAn . 'animate.min.css', ); diff --git a/e107_web/css/e107.css b/e107_web/css/e107.css index e15c92bc5..e95db761d 100644 --- a/e107_web/css/e107.css +++ b/e107_web/css/e107.css @@ -123,6 +123,10 @@ div.bbarea.large, .tbox.large, .helpbox.large { width: 95% } div.bbarea.medium, .tbox.medium, .helpbox.medium { width: 60% !important; } div.bbarea.small, .tbox.small, .helpbox.small { width: 250px !important; } img.bbcode-img { max-width:100%} +img.bbcode-img-left { float:left !important; margin: 0 10px 5px 0; } +img.bbcode-img-right { float:right !important; margin: 0 0 5px 10px; } + + .bbcode-panel { width: 100% } .input-block-level { width: 100% !important }