Skip to content
Permalink
Browse files

First fixes for the tinymce builder

  • Loading branch information...
bembelimen committed Mar 9, 2019
1 parent 9750aa9 commit e1fdcb43c0233c93b32bf4595c4ec9739de4187b
@@ -16,15 +16,15 @@
margin-bottom: 20px;
clear: both;
}
.mce-panel .drop-area-highlight {
#joomla-tinymce-builder .drop-area-highlight {
background-color: #d0d0d0;
}
.mce-panel .mce-btn.ui-state-highlight {
#joomla-tinymce-builder .tox-mbtn.ui-state-highlight {
height: 28px;
width: 40px;
background-color: #409740;
border: 1px solid #f0f0f0;
}
.timymce-builder-toolbar .mce-btn.ui-state-highlight {
.timymce-builder-toolbar .tox-mbtn.ui-state-highlight {
height: 22px;
}
@@ -64,9 +64,9 @@
var $copyHelper = null, removeIntent = false, self = this;
this.$sourceMenu.sortable({
connectWith: this.$targetMenu,
items: '.mce-btn',
items: '.tox-mbtn',
cancel: '',
placeholder: 'mce-btn ui-state-highlight',
placeholder: 'tox-mbtn ui-state-highlight',
start: function(event, ui) {
self.$targetMenu.addClass('drop-area-highlight');
},
@@ -82,9 +82,9 @@

this.$sourceToolbar.sortable({
connectWith: this.$targetToolbar,
items: '.mce-btn',
items: '.tox-mbtn',
cancel: '',
placeholder: 'mce-btn ui-state-highlight',
placeholder: 'tox-mbtn ui-state-highlight',
start: function(event, ui) {
self.$targetToolbar.addClass('drop-area-highlight');
},
@@ -99,9 +99,9 @@
});

$().add(this.$targetMenu).add(this.$targetToolbar).sortable({
items: '.mce-btn',
items: '.tox-mbtn',
cancel: '',
placeholder: 'mce-btn ui-state-highlight',
placeholder: 'tox-mbtn ui-state-highlight',
receive: function(event, ui) {
$copyHelper = null;
var $el = ui.item, $cont = $(this);
@@ -189,12 +189,15 @@
'class': 'mce-btn',
'data-name': name,
'data-toggle': 'tooltip',
'title': tinymce.translate(info.label)
'title': tinymce.translate(info.label),
});
var $btn = $('<button/>', {
'type': 'button'
'type': 'button',
'data-name': name,
'class': 'tox-mbtn tox-mbtn--select',
'data-toggle': 'tooltip',
'title': tinymce.translate(info.label),
});
$element.append($btn);

if (type === 'menu') {
$btn.html('<span class="mce-txt">' + tinymce.translate(info.label) + '</span> <i class="mce-caret"></i>');
@@ -203,7 +206,7 @@
$btn.html(info.text ? tinymce.translate(info.text) : '<i class="mce-ico mce-i-' + name + '"></i>');
}

return $element;
return $btn;
};

/**
@@ -83,10 +83,8 @@
<div class="tox tox-tinymce">
<div class="tox-editor-container">

<div class="tox-menubar">
<div class="timymce-builder-menu source" data-group="menu"
data-value="<?php echo $this->escape(json_encode($menubarSource)); ?>">
</div>
<div class="tox-menubar timymce-builder-menu source" data-group="menu"
data-value="<?php echo $this->escape(json_encode($menubarSource)); ?>">
</div>

<div class="tox-toolbar">
@@ -7,6 +7,7 @@
multiple="true"
class="access-select"
labelclass="badge badge-success"
layout="joomla.form.field.list-fancy-select"

This comment has been minimized.

Copy link
@brianteeman

brianteeman Mar 9, 2019

Contributor

there is an extra tab ;)

/>

<field

0 comments on commit e1fdcb4

Please sign in to comment.
You can’t perform that action at this time.