Skip to content

Commit

Permalink
Update style to cover Bootstrap 5.
Browse files Browse the repository at this point in the history
  • Loading branch information
ve3 committed Jan 30, 2024
1 parent af2d277 commit 9d532f4
Show file tree
Hide file tree
Showing 3 changed files with 54 additions and 0 deletions.
2 changes: 2 additions & 0 deletions Rundiz/Profiler/views/rdprofiler.css
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ body {
border-top: 1px solid #bbb;
border-image: none;
box-shadow: 0 -1px rgba(255,255,255,0.2);
box-sizing: content-box;
bottom: 0;
clear: both;
color: #333;
Expand Down Expand Up @@ -54,6 +55,7 @@ body {
}
.rdprofiler a {
color: inherit;
text-decoration: none;
}
.rdprofiler a.rdprofiler-highlight {
color: #896139;
Expand Down
1 change: 1 addition & 0 deletions tests/via-http/index.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
<ul>
<li><a href="styles/basic-bootstrap3.php">Bootstrap 3</a></li>
<li><a href="styles/basic-bootstrap4.php">Bootstrap 4</a></li>
<li><a href="styles/basic-bootstrap5.php">Bootstrap 5</a></li>
<li><a href="styles/basic-foundation5.php">Foundation 5</a></li>
<li><a href="styles/basic-foundation6.php">Foundation 6</a></li>
<li><a href="styles/basic-skeleton1.php">Skeleton 1</a></li>
Expand Down
51 changes: 51 additions & 0 deletions tests/via-http/styles/basic-bootstrap5.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
<?php

// require the class files. you may no need these if you install via composer.
require dirname(dirname(dirname(__DIR__))).'/Rundiz/Profiler/ProfilerBase.php';
require dirname(dirname(dirname(__DIR__))).'/Rundiz/Profiler/Profiler.php';

$profiler = new \Rundiz\Profiler\Profiler();
$profiler->Console->registerLogSections(['Logs', 'Time Load', 'Memory Usage', 'Files']);

// -----------------------------------------------------------------------------------------------------
// lazy to write same test on every page, use common test functions
// you can change this to other coding style in your real project.
require dirname(__DIR__).'/common-test-functions.php';

// css doc https://getbootstrap.com/docs/5.2/getting-started/introduction/
?>
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Rundiz\Profiler test</title>

<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.2.3/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-rbsA2VBKQhggwzxH7pPCaAqO46MgnOM80zW1RWuH61DGLwZJEdK2Kadq2F9CUG65" crossorigin="anonymous">
</head>
<body>
<h1>Rundiz\Profiler test</h1>
<p>This page test followings:</p>
<ul>
<li>Log</li>
<li>Time Load</li>
<li>Memory usage</li>
<li>Files</li>
</ul>

<?php
rdpBasicLogs($profiler);
rdpTimeLoadLogs($profiler);
rdpMemoryUsage($profiler);

$profiler->gatherAll();

// just checking.
echo '<pre class="profiler-data-dump-test">'.htmlspecialchars(print_r($profiler->dumptest(), true)).'</pre>';
echo "\n\n\n";

// display profiler window.
echo $profiler->display();
?>
</body>
</html>

0 comments on commit 9d532f4

Please sign in to comment.