Skip to content

Commit

Permalink
Merge branch '4.0-dev' into fix#23850
Browse files Browse the repository at this point in the history
  • Loading branch information
infograf768 committed Mar 7, 2019
2 parents bd045b0 + 8452e9c commit df6aeb8
Show file tree
Hide file tree
Showing 6 changed files with 21 additions and 9 deletions.
Expand Up @@ -9,7 +9,7 @@
ref="browserItems">
<div class="media-dragoutline">
<span class="fa fa-cloud-upload upload-icon" aria-hidden="true"></span>
<p>Drop file(s) to Upload</p>
<p>{{ translate('COM_MEDIA_DROP_FILE') }}</p>
</div>
<div v-if="listView === 'table'" class="media-browser-table">
<div class="media-browser-table-head">
Expand Down
Expand Up @@ -11,6 +11,7 @@
use Joomla\CMS\Language\Text;

Text::script('COM_MEDIA_ACTION_DELETE', true);
Text::script('COM_MEDIA_ACTION_DOWNLOAD', true);
Text::script('COM_MEDIA_ACTION_EDIT', true);
Text::script('COM_MEDIA_ACTION_PREVIEW', true);
Text::script('COM_MEDIA_ACTION_RENAME', true);
Expand All @@ -25,6 +26,7 @@
Text::script('COM_MEDIA_DECREASE_GRID', true);
Text::script('COM_MEDIA_DELETE_ERROR', true);
Text::script('COM_MEDIA_DELETE_SUCCESS', true);
Text::script('COM_MEDIA_DROP_FILE', true);
Text::script('COM_MEDIA_ERROR', true);
Text::script('COM_MEDIA_ERROR_NOT_AUTHENTICATED', true);
Text::script('COM_MEDIA_ERROR_NOT_AUTHORIZED', true);
Expand Down
2 changes: 2 additions & 0 deletions administrator/language/en-GB/en-GB.com_media.ini
Expand Up @@ -5,6 +5,7 @@

COM_MEDIA="Media"
COM_MEDIA_ACTION_DELETE="Delete item"
COM_MEDIA_ACTION_DOWNLOAD="Download item"
COM_MEDIA_ACTION_EDIT="Edit item"
COM_MEDIA_ACTION_PREVIEW="Preview item"
COM_MEDIA_ACTION_RENAME="Rename item"
Expand All @@ -20,6 +21,7 @@ COM_MEDIA_CREATE_NEW_FOLDER_SUCCESS="Folder created."
COM_MEDIA_DECREASE_GRID="Decrease grid size"
COM_MEDIA_DELETE_ERROR="Error deleting the item."
COM_MEDIA_DELETE_SUCCESS="Item deleted."
COM_MEDIA_DROP_FILE="Drop file(s) to Upload"
COM_MEDIA_EDIT="Media Edit"
COM_MEDIA_ERROR="An error occurred."
COM_MEDIA_ERROR_NO_PROVIDERS="No filesystem providers have been found. Please enable at least one <a href=\"%s\">filesystem plugin</a>."
Expand Down
2 changes: 2 additions & 0 deletions language/en-GB/en-GB.com_media.ini
Expand Up @@ -5,6 +5,7 @@

COM_MEDIA="Media"
COM_MEDIA_ACTION_DELETE="Delete item"
COM_MEDIA_ACTION_DOWNLOAD="Download item"
COM_MEDIA_ACTION_EDIT="Edit item"
COM_MEDIA_ACTION_PREVIEW="Preview item"
COM_MEDIA_ACTION_RENAME="Rename item"
Expand Down Expand Up @@ -34,6 +35,7 @@ COM_MEDIA_DESCFTPTITLE="FTP Login Details"
COM_MEDIA_DETAIL_VIEW="Detail View"
COM_MEDIA_DIRECTORY="Folder"
COM_MEDIA_DIRECTORY_UP="Folder Up"
COM_MEDIA_DROP_FILE="Drop file(s) to Upload"
COM_MEDIA_ERROR="An error occurred."
COM_MEDIA_ERROR_BAD_REQUEST="Bad Request"
COM_MEDIA_ERROR_FILE_EXISTS="File already exists."
Expand Down
2 changes: 1 addition & 1 deletion plugins/filesystem/local/local.xml
Expand Up @@ -30,7 +30,7 @@
multiple="true"
layout="joomla.form.field.subform.repeatable-table"
buttons="add,remove,move"
default='[{"directory":{"directory": "images"}}]'
default='{"directories0":{"directory":"images"}}'
>
<form>
<field
Expand Down
20 changes: 13 additions & 7 deletions plugins/system/debug/debug.php
Expand Up @@ -198,6 +198,11 @@ public function onAfterDispatch()
// Only if debugging or language debug is enabled.
if ((JDEBUG || $this->debugLang) && $this->isAuthorisedDisplayDebug())
{
// Use our own jQuery and font-awesome instead of the debug bar shipped version
$assetManager = $this->app->getDocument()->getWebAssetManager();
$assetManager->enableAsset('jquery-noconflict');
$assetManager->enableAsset('font-awesome');

HTMLHelper::_('stylesheet', 'plg_system_debug/debug.css', array('version' => 'auto', 'relative' => true));
HTMLHelper::_('script', 'plg_system_debug/debug.min.js', array('version' => 'auto', 'relative' => true));
}
Expand Down Expand Up @@ -284,14 +289,17 @@ public function onAfterRespond()
$debugBarRenderer->setOpenHandlerUrl($openHandlerUrl);
$debugBarRenderer->setBaseUrl(JUri::root(true) . '/media/vendor/debugbar/');

// Use our own jQuery and font-awesome instead of the debug bar shipped version
$assetManager = $this->app->getDocument()->getWebAssetManager();
$assetManager->enableAsset('jquery-noconflict');
$assetManager->enableAsset('font-awesome');
$debugBarRenderer->disableVendor('jquery');
$debugBarRenderer->setEnableJqueryNoConflict(false);
$debugBarRenderer->disableVendor('fontawesome');

/**
* @todo disable highlightjs from the DebugBar, import it through NPM
* and deliver it through Joomla's API
* Also every DebuBar script and stylesheet needs to use Joomla's API
* $debugBarRenderer->disableVendor('highlightjs');
*/

// Only render for HTML output.
if (Factory::getDocument()->getType() !== 'html')
{
Expand All @@ -318,9 +326,7 @@ public function onAfterRespond()
return;
}

$contents = str_replace('</head>', $debugBarRenderer->renderHead() . '</head>', $contents);

echo str_replace('</body>', $debugBarRenderer->render() . '</body>', $contents);
echo str_replace('</body>', $debugBarRenderer->renderHead() . $debugBarRenderer->render() . '</body>', $contents);
}

/**
Expand Down

0 comments on commit df6aeb8

Please sign in to comment.