| Current Path : /home/w/u/e/wuectly/www/03cbe/ |
| Current File : /home/w/u/e/wuectly/www/03cbe/editors.zip |
PK C�!]#��h\ \ + tinymce/field/tinymcebuilder/setoptions.phpnu &1i� <?php
/**
* @package Joomla.Plugin
* @subpackage Editors.tinymce
*
* @copyright (C) 2016 Open Source Matters, Inc. <https://www.joomla.org>
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
defined('_JEXEC') or die;
extract($displayData);
/**
* Layout variables
* -----------------
* @var JForm $form Form with extra options for the set
* @var JLayoutFile $this Context
*/
?>
<div class="setoptions-form-wrapper">
<?php foreach ($form->getGroup(null) as $field) : ?>
<?php echo $field->renderField(); ?>
<?php endforeach; ?>
</div>
PK C�!]� �� � tinymce/field/tinymcebuilder.phpnu &1i� <?php
/**
* @package Joomla.Plugin
* @subpackage Editors.tinymce
*
* @copyright (C) 2016 Open Source Matters, Inc. <https://www.joomla.org>
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
defined('_JEXEC') or die;
extract($displayData);
/**
* Layout variables
* -----------------
* @var string $autocomplete Autocomplete attribute for the field.
* @var boolean $autofocus Is autofocus enabled?
* @var string $class Classes for the input.
* @var string $description Description of the field.
* @var boolean $disabled Is this field disabled?
* @var string $group Group the field belongs to. <fields> section in form XML.
* @var boolean $hidden Is this field hidden in the form?
* @var string $hint Placeholder for the field.
* @var string $id DOM id of the field.
* @var string $label Label of the field.
* @var string $labelclass Classes to apply to the label.
* @var boolean $multiple Does this field support multiple values?
* @var string $name Name of the input field.
* @var string $onchange Onchange attribute for the field.
* @var string $onclick Onclick attribute for the field.
* @var string $pattern Pattern (Reg Ex) of value of the form field.
* @var boolean $readonly Is this field read only?
* @var boolean $repeat Allows extensions to duplicate elements.
* @var boolean $required Is this field required?
* @var integer $size Size attribute of the input.
* @var boolean $spellcheck Spellcheck state for the form field.
* @var string $validate Validation rules to apply.
* @var array $value Value of the field.
*
* @var array $menus List of the menu items
* @var array $menubarSource Menu items for builder
* @var array $buttons List of the buttons
* @var array $buttonsSource Buttons by group, for the builder
* @var array $toolbarPreset Toolbar preset (default values)
* @var int $setsAmount Amount of sets
* @var array $setsNames List of Sets names
* @var JForm[] $setsForms Form with extra options for an each set
* @var string $languageFile TinyMCE language file to translate the buttons
*
* @var JLayoutFile $this Context
*/
JHtml::_('behavior.core');
JHtml::_('stylesheet', 'media/editors/tinymce/skins/lightgray/skin.min.css', array('version' => 'auto', 'relative' => false));
JHtml::_('jquery.ui', array('core', 'sortable'));
JHtml::_('script', 'editors/tinymce/tinymce-builder.js', array('version' => 'auto', 'relative' => true));
if ($languageFile)
{
JHtml::_('script', $languageFile, array('version' => 'auto', 'relative' => false));
}
$doc = JFactory::getDocument();
$doc->addScriptOptions('plg_editors_tinymce_builder', array(
'menus' => $menus,
'buttons' => $buttons,
'toolbarPreset' => $toolbarPreset,
'formControl' => $name . '[toolbars]',
)
);
$doc->addStyleDeclaration('
#joomla-tinymce-builder{
margin-left: -180px;
}
.mce-menubar,
.mce-panel {
min-height: 18px;
border-bottom: 1px solid rgba(217,217,217,0.52);
white-space: normal;
}
.mce-tinymce {
margin-bottom: 20px;
}
.mce-panel .drop-area-highlight{
background-color: #d0d0d0;
}
.mce-panel .mce-btn.ui-state-highlight{
height: 28px;
width: 40px;
background-color: #409740;
border: 1px solid #f0f0f0;
}
.tinymce-builder-toolbar .mce-btn.ui-state-highlight{
height: 22px;
width: 28px;
}
');
?>
<div id="joomla-tinymce-builder">
<p><?php echo JText::_('PLG_TINY_SET_SOURCE_PANEL_DESCRIPTION'); ?></p>
<div class="mce-tinymce mce-container mce-panel">
<div class="mce-container-body mce-stack-layout">
<div class="mce-container mce-menubar mce-toolbar mce-stack-layout-item">
<div class="mce-container-body mce-flow-layout tinymce-builder-menu source" data-group="menu"
data-value="<?php echo $this->escape(json_encode($menubarSource)); ?>">
</div>
</div>
<div class="mce-toolbar-grp mce-container mce-panel mce-stack-layout-item">
<div class="mce-container-body mce-flow-layout tinymce-builder-toolbar source" data-group="toolbar"
data-value="<?php echo $this->escape(json_encode($buttonsSource)); ?>">
</div>
</div>
</div>
</div>
<hr />
<p><?php echo JText::_('PLG_TINY_SET_TARGET_PANEL_DESCRIPTION'); ?></p>
<!-- Render tabs for each set -->
<ul class="nav nav-tabs" id="set-tabs">
<?php foreach ( $setsNames as $num => $title ) : ?>
<li class="<?php echo $num === $setsAmount - 1 ? 'active' : ''; ?>">
<a href="#set-<?php echo $num; ?>"><?php echo $title; ?></a>
</li>
<?php endforeach; ?>
</ul>
<!-- Render tab content for each set -->
<div class="tab-content">
<?php
$presetButtonClases = array(
'simple' => 'btn-success',
'medium' => 'btn-info',
'advanced' => 'btn-warning',
);
foreach ( $setsNames as $num => $title ) :
// Check whether the values exists, and if empty then use from preset
if (empty($value['toolbars'][$num]['menu'])
&& empty($value['toolbars'][$num]['toolbar1'])
&& empty($value['toolbars'][$num]['toolbar2']))
{
// Take the preset for default value
switch ($num) {
case 0:
$preset = $toolbarPreset['advanced'];
break;
case 1:
$preset = $toolbarPreset['medium'];
break;
default:
$preset = $toolbarPreset['simple'];
}
$value['toolbars'][$num] = $preset;
}
// Take existing values
$valMenu = empty($value['toolbars'][$num]['menu']) ? array() : $value['toolbars'][$num]['menu'];
$valBar1 = empty($value['toolbars'][$num]['toolbar1']) ? array() : $value['toolbars'][$num]['toolbar1'];
$valBar2 = empty($value['toolbars'][$num]['toolbar2']) ? array() : $value['toolbars'][$num]['toolbar2'];
?>
<div class="tab-pane <?php echo $num === $setsAmount - 1 ? 'active' : ''; ?>" id="set-<?php echo $num; ?>">
<div class="btn-toolbar clearfix">
<div class="btn-group pull-right">
<?php foreach(array_keys($toolbarPreset) as $presetName) :
$btnClass = empty($presetButtonClases[$presetName]) ? 'btn-primary' : $presetButtonClases[$presetName];
?>
<button type="button" class="btn btn-mini <?php echo $btnClass; ?> button-action"
data-action="setPreset" data-preset="<?php echo $presetName; ?>" data-set="<?php echo $num; ?>">
<?php echo JText::_('PLG_TINY_SET_PRESET_BUTTON_' . $presetName); ?>
</button>
<?php endforeach; ?>
<button type="button" class="btn btn-mini btn-danger button-action"
data-action="clearPane" data-set="<?php echo $num; ?>">
<?php echo JText::_('JCLEAR'); ?></button>
</div>
</div>
<div class="mce-tinymce mce-container mce-panel">
<div class="mce-container-body mce-stack-layout">
<div class="mce-container mce-menubar mce-toolbar tinymce-builder-menu target"
data-group="menu" data-set="<?php echo $num; ?>"
data-value="<?php echo $this->escape(json_encode($valMenu)); ?>">
</div>
<div class="mce-toolbar-grp mce-container mce-panel tinymce-builder-toolbar target"
data-group="toolbar1" data-set="<?php echo $num; ?>"
data-value="<?php echo $this->escape(json_encode($valBar1)); ?>">
</div>
<div class="mce-toolbar-grp mce-container mce-panel tinymce-builder-toolbar target"
data-group="toolbar2" data-set="<?php echo $num; ?>"
data-value="<?php echo $this->escape(json_encode($valBar2)); ?>">
</div>
</div>
</div>
<!-- Render the form for extra options -->
<?php echo $this->sublayout('setoptions', array('form' => $setsForms[$num])); ?>
</div>
<?php endforeach; ?>
</div>
</div>
PK ʠ!]GL:* * codemirror/element.phpnu &1i� <?php
/**
* @package Joomla.Plugin
* @subpackage Editors.codemirror
*
* @copyright (C) 2015 Open Source Matters, Inc. <https://www.joomla.org>
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
// No direct access
defined('_JEXEC') or die;
$options = $displayData->options;
$params = $displayData->params;
$name = $displayData->name;
$id = $displayData->id;
$cols = $displayData->cols;
$rows = $displayData->rows;
$content = $displayData->content;
$buttons = $displayData->buttons;
$modifier = $params->get('fullScreenMod', array()) ? implode(' + ', $params->get('fullScreenMod', array())) . ' + ' : '';
?>
<p class="label">
<?php echo JText::sprintf('PLG_CODEMIRROR_TOGGLE_FULL_SCREEN', $modifier, $params->get('fullScreen', 'F10')); ?>
</p>
<?php
echo '<textarea class="codemirror-source" name="', $name,
'" id="', $id,
'" cols="', $cols,
'" rows="', $rows,
'" data-options="', htmlspecialchars(json_encode($options)),
'">', $content, '</textarea>';
?>
<?php echo $buttons; ?>
PK ʠ!]�1nB B codemirror/styles.phpnu &1i� <?php
/**
* @package Joomla.Plugin
* @subpackage Editors.codemirror
*
* @copyright (C) 2015 Open Source Matters, Inc. <https://www.joomla.org>
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
// No direct access
defined('_JEXEC') or die;
$params = $displayData->params;
$fontFamily = isset($displayData->fontFamily) ? $displayData->fontFamily : 'monospace';
$fontSize = $params->get('fontSize', 13) . 'px;';
$lineHeight = $params->get('lineHeight', 1.2) . 'em;';
// Set the active line color.
$color = $params->get('activeLineColor', '#a4c2eb');
$r = hexdec($color[1] . $color[2]);
$g = hexdec($color[3] . $color[4]);
$b = hexdec($color[5] . $color[6]);
$activeLineColor = 'rgba(' . $r . ', ' . $g . ', ' . $b . ', .5)';
// Set the color for matched tags.
$color = $params->get('highlightMatchColor', '#fa542f');
$r = hexdec($color[1] . $color[2]);
$g = hexdec($color[3] . $color[4]);
$b = hexdec($color[5] . $color[6]);
$highlightMatchColor = 'rgba(' . $r . ', ' . $g . ', ' . $b . ', .5)';
JFactory::getDocument()->addStyleDeclaration(
<<<CSS
.CodeMirror
{
font-family: $fontFamily;
font-size: $fontSize;
line-height: $lineHeight;
border: 1px solid #ccc;
}
/* In order to hid the Joomla menu */
.CodeMirror-fullscreen
{
z-index: 1040;
}
/* Make the fold marker a little more visible/nice */
.CodeMirror-foldmarker
{
background: rgb(255, 128, 0);
background: rgba(255, 128, 0, .5);
box-shadow: inset 0 0 2px rgba(255, 255, 255, .5);
font-family: serif;
font-size: 90%;
border-radius: 1em;
padding: 0 1em;
vertical-align: middle;
color: white;
text-shadow: none;
}
.CodeMirror-foldgutter, .CodeMirror-markergutter { width: 1.2em; text-align: center; }
.CodeMirror-markergutter { cursor: pointer; }
.CodeMirror-markergutter-mark { cursor: pointer; text-align: center; }
.CodeMirror-markergutter-mark:after { content: "\25CF"; }
.CodeMirror-activeline-background { background: $activeLineColor; }
.CodeMirror-matchingtag { background: $highlightMatchColor; }
.cm-matchhighlight {background-color: $highlightMatchColor; }
.CodeMirror-selection-highlight-scrollbar {background-color: $highlightMatchColor; }
CSS
);
PK ʠ!]��'d� � codemirror/init.phpnu &1i� <?php
/**
* @package Joomla.Plugin
* @subpackage Editors.codemirror
*
* @copyright (C) 2015 Open Source Matters, Inc. <https://www.joomla.org>
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
// No direct access
defined('_JEXEC') or die;
$params = $displayData->params;
$basePath = $params->get('basePath', 'media/editors/codemirror/');
$modePath = $params->get('modePath', 'media/editors/codemirror/mode/%N/%N');
$extJS = JDEBUG ? '.js' : '.min.js';
$extCSS = JDEBUG ? '.css' : '.min.css';
JHtml::_('script', $basePath . 'lib/codemirror' . $extJS, array('version' => 'auto'));
JHtml::_('script', $basePath . 'lib/addons' . $extJS, array('version' => 'auto'));
JHtml::_('stylesheet', $basePath . 'lib/codemirror' . $extCSS, array('version' => 'auto'));
JHtml::_('stylesheet', $basePath . 'lib/addons' . $extCSS, array('version' => 'auto'));
$fskeys = $params->get('fullScreenMod', array());
$fskeys[] = $params->get('fullScreen', 'F10');
$fullScreenCombo = implode('-', $fskeys);
$fsCombo = json_encode($fullScreenCombo);
$modPath = json_encode(JUri::root(true) . '/' . $modePath . $extJS);
JFactory::getDocument()->addScriptDeclaration(
<<<JS
;(function (cm, $) {
cm.commands.toggleFullScreen = function (cm) {
cm.setOption('fullScreen', !cm.getOption('fullScreen'));
};
cm.commands.closeFullScreen = function (cm) {
cm.getOption('fullScreen') && cm.setOption('fullScreen', false);
};
cm.keyMap.default['Ctrl-Q'] = 'toggleFullScreen';
cm.keyMap.default[$fsCombo] = 'toggleFullScreen';
cm.keyMap.default['Esc'] = 'closeFullScreen';
// For mode autoloading.
cm.modeURL = $modPath;
// Fire this function any time an editor is created.
cm.defineInitHook(function (editor)
{
// Try to set up the mode
var mode = cm.findModeByMIME(editor.options.mode || '') ||
cm.findModeByName(editor.options.mode || '') ||
cm.findModeByExtension(editor.options.mode || '');
cm.autoLoadMode(editor, mode ? mode.mode : editor.options.mode);
if (mode && mode.mime)
{
editor.setOption('mode', mode.mime);
}
// Handle gutter clicks (place or remove a marker).
editor.on('gutterClick', function (ed, n, gutter) {
if (gutter != 'CodeMirror-markergutter') { return; }
var info = ed.lineInfo(n),
hasMarker = !!info.gutterMarkers && !!info.gutterMarkers['CodeMirror-markergutter'];
ed.setGutterMarker(n, 'CodeMirror-markergutter', hasMarker ? null : makeMarker());
});
// jQuery's ready function.
$(function () {
// Some browsers do something weird with the fieldset which doesn't work well with CodeMirror. Fix it.
$(editor.getWrapperElement()).parent('fieldset').css('min-width', 0);
// Listen for Bootstrap's 'shown' event. If this editor was in a hidden element when created, it may need to be refreshed.
$(document.body).on('shown shown.bs.tab shown.bs.modal', function () { editor.refresh(); });
});
});
function makeMarker()
{
var marker = document.createElement('div');
marker.className = 'CodeMirror-markergutter-mark';
return marker;
}
// Initialize any CodeMirrors on page load and when a subform is added
$(function ($) {
initCodeMirror();
$('body').on('subform-row-add', initCodeMirror);
});
function initCodeMirror(event, container)
{
container = container || document;
$(container).find('textarea.codemirror-source').each(function () {
var input = $(this).removeClass('codemirror-source');
var id = input.prop('id');
Joomla.editors.instances[id] = cm.fromTextArea(this, input.data('options'));
});
}
}(CodeMirror, jQuery));
JS
);
PK C�!]#��h\ \ + tinymce/field/tinymcebuilder/setoptions.phpnu &1i� PK C�!]� �� � � tinymce/field/tinymcebuilder.phpnu &1i� PK ʠ!]GL:* * �! codemirror/element.phpnu &1i� PK ʠ!]�1nB B F&