Skip to content

Commit dbf118e

Browse files
authored
adding unhealthy and health filters - percentage status on top. Docs update (#84)
Signed-off-by: Daniel Guns <danbguns@gmail.com>
1 parent 19dd4ec commit dbf118e

12 files changed

Lines changed: 553 additions & 66 deletions

File tree

docs/assets/scss/_styles_project.scss

Lines changed: 100 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,17 @@
3333
text-align: center !important;
3434
}
3535

36+
// Button container - proper flexbox alignment
37+
.d-flex {
38+
display: flex !important;
39+
align-items: center;
40+
justify-content: center;
41+
42+
&.gap-3 {
43+
gap: 1rem !important;
44+
}
45+
}
46+
3647
// Make content wider - less squashed
3748
.row {
3849
max-width: 1200px;
@@ -456,10 +467,44 @@ code:not(pre code) {
456467
}
457468
}
458469

459-
// Main wrapper - let Docsy handle layout naturally
470+
// Main wrapper - ensure proper width constraints
460471
.td-main {
461472
background-color: var(--bs-body-bg);
462473

474+
// Ensure main content area uses more width on larger screens
475+
// Docsy uses Bootstrap grid: col-xl-8 (66.7%), we'll make it wider
476+
main[role="main"] {
477+
// On xl screens and above, use more width for better readability
478+
@media (min-width: 1200px) {
479+
// Override Docsy's col-xl-8 to use more space
480+
flex: 0 0 auto;
481+
width: 70% !important; // Use 70% instead of 66.7%
482+
max-width: 70% !important;
483+
}
484+
485+
@media (min-width: 1400px) {
486+
width: 72% !important;
487+
max-width: 72% !important;
488+
}
489+
}
490+
491+
// Adjust sidebar widths to accommodate wider content
492+
.td-sidebar {
493+
@media (min-width: 1200px) {
494+
flex: 0 0 auto;
495+
width: 15% !important; // Reduce from 16.67% to 15%
496+
max-width: 15% !important;
497+
}
498+
}
499+
500+
.td-sidebar-toc {
501+
@media (min-width: 1200px) {
502+
flex: 0 0 auto;
503+
width: 15% !important; // Reduce from 16.67% to 15%
504+
max-width: 15% !important;
505+
}
506+
}
507+
463508
[data-bs-theme="dark"] & {
464509
background-color: #{$dark-bg};
465510
}
@@ -480,12 +525,34 @@ code:not(pre code) {
480525
display: block !important;
481526
}
482527

483-
// Content area - wider, less squashed (Docsy handles layout)
528+
// Content area - proper width constraints following Hugo/Docsy best practices
484529
.td-content {
485530
background-color: var(--bs-body-bg);
486531
padding: 3rem 2rem;
487-
// Wider content - less squashed
488-
max-width: 100%;
532+
533+
// Docsy wraps content in td-content__inner - ensure it uses available space
534+
// but doesn't get too wide (readability: ~80-100 chars = ~800-1000px)
535+
.td-content__inner {
536+
max-width: 100%;
537+
538+
// On larger screens, allow content to use more width
539+
@media (min-width: 1200px) {
540+
max-width: 100%;
541+
}
542+
}
543+
544+
// Ensure container-fluid doesn't constrain content unnecessarily
545+
.container-fluid {
546+
max-width: 100%;
547+
padding-left: 2rem;
548+
padding-right: 2rem;
549+
550+
// On larger screens, use more horizontal space
551+
@media (min-width: 1400px) {
552+
padding-left: 3rem;
553+
padding-right: 3rem;
554+
}
555+
}
489556

490557
[data-bs-theme="dark"] & {
491558
background-color: #{$dark-bg};
@@ -658,7 +725,7 @@ code:not(pre code) {
658725
opacity: 0.9;
659726
}
660727

661-
// Feature blocks
728+
// Feature blocks - make screenshots larger
662729
.feature {
663730
text-align: left;
664731

@@ -667,6 +734,34 @@ code:not(pre code) {
667734
}
668735
}
669736

737+
// Make screenshots in feature blocks larger
738+
// Feature blocks use col-lg-4 (3 columns), so we override to make screenshots bigger
739+
// Target screenshots section specifically
740+
section.td-box {
741+
.col-lg-4 {
742+
// Make feature blocks wider for screenshots
743+
@media (min-width: 992px) {
744+
flex: 0 0 auto;
745+
width: 50% !important; // Change from 33.33% (col-lg-4) to 50% (2 columns)
746+
max-width: 50% !important;
747+
}
748+
749+
img {
750+
max-width: 100% !important;
751+
width: 100% !important;
752+
height: auto;
753+
margin: 1.5rem auto;
754+
display: block;
755+
border-radius: $border-radius;
756+
box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
757+
758+
[data-bs-theme="dark"] & {
759+
box-shadow: 0 4px 6px rgba(0, 0, 0, 0.3);
760+
}
761+
}
762+
}
763+
}
764+
670765
// Breadcrumbs
671766
.td-breadcrumb {
672767
margin-bottom: 1rem;

docs/content/_index.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,11 +23,11 @@ notoc: true
2323
<p class="lead mb-5">A K9s-inspired terminal UI for monitoring Flux GitOps resources</p>
2424

2525
<!-- Action Buttons -->
26-
<div class="mb-5">
27-
<a class="btn btn-lg btn-primary me-3 mb-3" href="{{< relref \"getting-started/\" >}}">
26+
<div class="d-flex flex-wrap justify-content-center gap-3 mb-5">
27+
<a class="btn btn-lg btn-primary" href="{{< relref \"getting-started/\" >}}">
2828
Get Started <i class="fas fa-arrow-alt-circle-right ms-2"></i>
2929
</a>
30-
<a class="btn btn-lg btn-outline-primary mb-3" href="https://github.com/dgunzy/flux9s">
30+
<a class="btn btn-lg btn-outline-primary" href="https://github.com/dgunzy/flux9s">
3131
<i class="fab fa-github me-2"></i>View on GitHub
3232
</a>
3333
</div>

docs/content/configuration/_index.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,8 @@ flux9s stores its configuration in a YAML file. The location depends on your ope
2121

2222
### Read-Only Mode
2323

24-
By default, flux9s launches in readonly mode to prevent accidental changes. You can change this:
24+
By default, flux9s launches in readonly mode to prevent accidental changes (Delete operations always have a confirmation screen).
25+
You can change this:
2526

2627
**Via command line:**
2728

docs/content/user-guide/_index.md

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,11 +34,26 @@ Type these commands in command mode (press `:`):
3434
| `:ns <namespace>` | Switch to a specific namespace |
3535
| `:ns all` | View all namespaces |
3636
| `:all` | Show all resources |
37+
| `:healthy` | Show only healthy resources |
38+
| `:unhealthy` | Show only unhealthy resources |
3739
| `:skin <name>` | Change theme/skin |
3840
| `:readonly` | Toggle readonly mode |
3941
| `:help` | Show/hide help |
4042
| `:q` or `:q!` | Quit application |
4143

44+
## Health Filtering
45+
46+
Filter resources by health status:
47+
48+
- **`:healthy`** - Show only healthy resources (ready=true, not suspended, or null status)
49+
- **`:unhealthy`** - Show only unhealthy resources (ready=false or suspended=true)
50+
- **`:all`** - Clear health filter and show all resources
51+
52+
The header displays a health percentage indicator showing the overall health of your resources. The indicator uses color coding:
53+
- **Green (●)** - 90% or higher health
54+
- **Yellow (⚠)** - 70-89% health
55+
- **Red (✗)** - Below 70% health
56+
4257
## Operations
4358

4459
Perform actions on selected resources:

docs/images/filter-screenshot.png

806 Bytes
Loading

docs/images/screenshot.png

32.1 KB
Loading

0 commit comments

Comments
 (0)