Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 17 additions & 0 deletions docs/_sass/_dark-mode.scss
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,23 @@
opacity: 0.5;
}

// Improve sidebar TOC readability
.docs__sidebar-title {
color: #a8bcc9;
}

.docs__toc a {
color: #b0c4d1;

&:hover {
color: var(--color-primary);
}

&.is-active {
color: var(--color-primary);
}
}

.code-panel {
background: $dark-code-bg;
border-color: $dark-border;
Expand Down
44 changes: 13 additions & 31 deletions docs/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -311,40 +311,22 @@ <h3>Run &amp; See the Trace &#128007;</h3>
</div>
</section>

<!-- ==================== BLOCK TRACKING HIGHLIGHT ==================== -->
<section class="section features" id="block-tracking">
<!-- ==================== EXPLORE MORE ==================== -->
<section class="section" id="explore-more" style="text-align: center;">
<div class="container">
<div class="section__header animate-fade-up">
<span class="badge">Advanced Feature</span>
<h2>Block Tracking with<br><span class="text-gradient">TimerNinjaBlock</span></h2>
<p>Measure any code block — no need to extract separate methods.</p>
<span class="badge">There's More</span>
<h2>Explore All <span class="text-gradient">Features</span></h2>
<p>Block tracking, custom thresholds, constructor tracking, global configuration, and more — Timer Ninja has everything you need for method-level performance insights.</p>
</div>

<div class="comparison__panels">
<div class="code-panel code-panel--after animate-fade-left" style="grid-column: 1 / -1; max-width: 720px; margin: 0 auto;">
<div class="code-panel__header">
<span>&#129513;</span> Block Tracking Example
</div>
<div class="code-panel__body">
<pre><code class="language-java">@TimerNinjaTracker(includeArgs = true, threshold = 100)
public void processLoanApplication(int userId, double amount, int months) {
User user = userService.findUser(userId);

TimerNinjaBlock.measure("credit score check", () -&gt; {
simulateDelay(60);
});

TimerNinjaBlock.measure("income verification", () -&gt; {
simulateDelay(80);
});

String status = TimerNinjaBlock.measure("final approval", () -&gt; {
simulateDelay(50);
return "APPROVED";
});
}</code></pre>
</div>
</div>
<div class="hero__actions animate-fade-up">
<a href="{{ '/user-guide/' | relative_url }}" class="btn btn--primary">
Read the Full User Guide
<span>&rarr;</span>
</a>
<a href="{{ '/examples/' | relative_url }}" class="btn btn--outline">
Browse Examples
</a>
</div>
</div>
</section>
Expand Down
Loading