Skip to content

Commit

Permalink
~ fix last style tag position
Browse files Browse the repository at this point in the history
+ added data: to image source (csp) -> fix icons not shown

Signed-off-by: Christoph Potas <christoph286@googlemail.com>
  • Loading branch information
puschie286 committed Aug 2, 2018
1 parent 37ba642 commit 14328f9
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 7 deletions.
5 changes: 5 additions & 0 deletions system/Debug/Toolbar.php
Original file line number Diff line number Diff line change
Expand Up @@ -196,6 +196,11 @@ public function run($startTime, $totalTime, $request, $response): string

$data['config'] = \CodeIgniter\Debug\Toolbar\Collectors\Config::display();

if( $response->CSP !== null )
{
$response->CSP->addImageSrc( 'data:' );
}

return json_encode($data);
}

Expand Down
14 changes: 7 additions & 7 deletions system/Debug/Toolbar/Views/toolbar.tpl.php
Original file line number Diff line number Diff line change
Expand Up @@ -270,11 +270,11 @@

<?= $parser->setData($config)->render('_config.tpl') ?>
</div>
<style type="text/css">
<?php foreach( $styles as $name => $style ) : ?>
.<?= $name ?> {
<?= $style ?>
}
<?php endforeach ?>
</style>
</div>
<style type="text/css">
<?php foreach( $styles as $name => $style ) : ?>
.<?= $name ?> {
<?= $style ?>
}
<?php endforeach ?>
</style>

0 comments on commit 14328f9

Please sign in to comment.