Commit e4f0e800 by Tobias Munk

refactored panels to achieve a consistent look

parent 18a3e9aa
...@@ -3,6 +3,7 @@ ...@@ -3,6 +3,7 @@
use yii\helpers\Html; use yii\helpers\Html;
use yii\grid\GridView; use yii\grid\GridView;
use yii\data\ArrayDataProvider; use yii\data\ArrayDataProvider;
use yii\debug\panels\ConfigPanel;
/** /**
* @var \yii\web\View $this * @var \yii\web\View $this
...@@ -14,15 +15,18 @@ use yii\data\ArrayDataProvider; ...@@ -14,15 +15,18 @@ use yii\data\ArrayDataProvider;
$this->title = 'Yii Debugger'; $this->title = 'Yii Debugger';
?> ?>
<div class="default-index"> <div class="default-index">
<div id="yii-debug-toolbar" class="yii-debug-toolbar-top">
<div class="yii-debug-toolbar-block title">
<a href="<?= Yii::$app->homeUrl ?>"> <div id="yii-debug-toolbar" class="yii-debug-toolbar-top">
<span class="glyphicon glyphicon-home"></span> <div class="yii-debug-toolbar-block title">
</a> <a href="#">
</div> <img width="29" height="30" alt="" src="<?= \yii\debug\Module::getYiiLogo() ?>">
<div class="yii-debug-toolbar-block title"> Yii Debugger
Yii Debugger </a>
</div> </div>
<?php foreach ($panels as $panel): ?>
<?= $panel->getSummary() ?>
<?php endforeach; ?>
</div> </div>
<div class="container"> <div class="container">
......
...@@ -6,15 +6,11 @@ use yii\helpers\Html; ...@@ -6,15 +6,11 @@ use yii\helpers\Html;
* @var yii\debug\panels\ConfigPanel $panel * @var yii\debug\panels\ConfigPanel $panel
*/ */
?> ?>
<div class="yii-debug-toolbar-block title">
<?= Html::a('Yii Debugger', ['index'], ['title' => 'Back to main debug page']) ?>
</div>
<div class="yii-debug-toolbar-block"> <div class="yii-debug-toolbar-block">
<a href="<?= $panel->getUrl() ?>"> <a href="<?= $panel->getUrl() ?>">
<img width="29" height="30" alt="" src="<?= $panel->getYiiLogo() ?>"> Yii
<span><?= $panel->data['application']['yii'] ?></span> <span class="label label-info"><?= $panel->data['application']['yii'] ?></span>
PHP
<span class="label label-info"><?= $panel->data['php']['version'] ?></span>
</a> </a>
</div> </div>
<div class="yii-debug-toolbar-block">
<?= Html::a('PHP ' . $panel->data['php']['version'], ['phpinfo'], ['title' => 'Show phpinfo()', 'target' => 'phpinfo']) ?>
</div>
...@@ -5,6 +5,7 @@ ...@@ -5,6 +5,7 @@
* @var string $tag * @var string $tag
* @var string $position * @var string $position
*/ */
use yii\helpers\Html;
use yii\debug\panels\ConfigPanel; use yii\debug\panels\ConfigPanel;
$minJs = <<<EOD $minJs = <<<EOD
...@@ -27,19 +28,21 @@ $firstPanel = reset($panels); ...@@ -27,19 +28,21 @@ $firstPanel = reset($panels);
$url = $firstPanel->getUrl(); $url = $firstPanel->getUrl();
?> ?>
<div id="yii-debug-toolbar" class="yii-debug-toolbar-<?= $position ?>"> <div id="yii-debug-toolbar" class="yii-debug-toolbar-<?= $position ?>">
<div class="yii-debug-toolbar-block"> <div class="yii-debug-toolbar-block title">
<a href="<?= Yii::$app->homeUrl ?>"> <a href="<?= Html::url(['index']) ?>">
<span class="glyphicon glyphicon-home"></span> <img width="29" height="30" alt="" src="<?= \yii\debug\Module::getYiiLogo() ?>">
</a> Yii Debugger
</div> </a>
</div>
<?php foreach ($panels as $panel): ?> <?php foreach ($panels as $panel): ?>
<?= $panel->getSummary() ?> <?= $panel->getSummary() ?>
<?php endforeach; ?> <?php endforeach; ?>
<span class="yii-debug-toolbar-toggler" onclick="<?= $minJs ?>"></span> <span class="yii-debug-toolbar-toggler" onclick="<?= $minJs ?>"></span>
</div> </div>
<div id="yii-debug-toolbar-min"> <div id="yii-debug-toolbar-min">
<a href="<?= $url ?>" title="Open Yii Debugger" id="yii-debug-toolbar-logo"> <a href="<?= $url ?>" title="Open Yii Debugger" id="yii-debug-toolbar-logo">
<img width="29" height="30" alt="" src="<?= ConfigPanel::getYiiLogo() ?>"> <img width="29" height="30" alt="" src="<?= \yii\debug\Module::getYiiLogo() ?>">
</a> </a>
<span class="yii-debug-toolbar-toggler" onclick="<?= $maxJs ?>"></span> <span class="yii-debug-toolbar-toggler" onclick="<?= $maxJs ?>"></span>
</div> </div>
...@@ -17,11 +17,14 @@ $this->title = 'Yii Debugger'; ...@@ -17,11 +17,14 @@ $this->title = 'Yii Debugger';
?> ?>
<div class="default-view"> <div class="default-view">
<div id="yii-debug-toolbar" class="yii-debug-toolbar-top"> <div id="yii-debug-toolbar" class="yii-debug-toolbar-top">
<div class="yii-debug-toolbar-block">
<a href="<?= Yii::$app->homeUrl ?>"> <div class="yii-debug-toolbar-block title">
<span class="glyphicon glyphicon-home"></span> <a href="<?= Html::url(['index']) ?>">
</a> <img width="29" height="30" alt="" src="<?= \yii\debug\Module::getYiiLogo() ?>">
</div> Yii Debugger
</a>
</div>
<?php foreach ($panels as $panel): ?> <?php foreach ($panels as $panel): ?>
<?= $panel->getSummary() ?> <?= $panel->getSummary() ?>
<?php endforeach; ?> <?php endforeach; ?>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment