Skip to content
Permalink
Browse files

RoutingPanel: Add better panel responsivity (#225)

  • Loading branch information...
janbarasek authored and dg committed Aug 5, 2019
1 parent 14f6ce4 commit af851cba10aa6674412c24ee61b766acc225756c
Showing with 13 additions and 3 deletions.
  1. +13 −3 src/Bridges/ApplicationTracy/templates/RoutingPanel.panel.phtml
@@ -22,14 +22,22 @@ use Tracy\Helpers;
background: #C1D3FF !important;
}
#tracy-debug .nette-RoutingPanel td:first-child {
width: 20px;
}
#tracy-debug .nette-RoutingPanel td:nth-child(2) {
white-space: nowrap;
}
#tracy-debug .nette-RoutingPanel pre, #tracy-debug .nette-RoutingPanel code {
display: inline;
background: transparent;
}
#tracy-debug .nette-RoutingPanel-rel {
background: #eee;
white-space: nowrap
white-space: nowrap;
}
</style>

@@ -63,7 +71,7 @@ use Tracy\Helpers;
<tr class="<?= $router['matched'] ?>">
<td><?= $router['matched'] === 'yes' ? '' : ($router['matched'] === 'may' ? '' : '') ?></td>

<td><code title="<?= Helpers::escapeHtml($router['class']) ?>"><?= Helpers::escapeHtml($router['mask'] ?? $router['class']) ?></code></td>
<td><code title="<?= Helpers::escapeHtml($router['class']) ?>"><?= isset($router['mask']) ? str_replace('/', '<wbr>/', Helpers::escapeHtml($router['mask'])) : str_replace('\\', '<wbr>\\', Helpers::escapeHtml($router['class'])) ?></code></td>

<td><code>
<?php foreach ($router['defaults'] as $key => $value): ?>
@@ -88,9 +96,11 @@ use Tracy\Helpers;
</tbody>
</table>
<?php endif ?>
</div>

<div class="tracy-inner-container">
<p><code><?= Helpers::escapeHtml($method) ?></code>
<code><?= Helpers::escapeHtml($url->getBaseUrl()) ?><span class="nette-RoutingPanel-rel"><?= Helpers::escapeHtml($url->getRelativeUrl()) ?></span></code></p>
<code><?= Helpers::escapeHtml($url->getBaseUrl()) ?><wbr><span class="nette-RoutingPanel-rel"><?= str_replace(['&amp;', '?'], ['<wbr>&amp;', '<wbr>?'], Helpers::escapeHtml($url->getRelativeUrl())) ?></span></code></p>

<?php if ($source): ?>
<p><a href="<?= Helpers::escapeHtml(Tracy\Helpers::editorUri($source->getFileName(), $source->getStartLine())) ?>"><?= $source instanceof \ReflectionClass ? $source->getName() : $source->getDeclaringClass()->getName() . '::' . $source->getName() . '()' ?></a></p>

0 comments on commit af851cb

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