Skip to content

Commit 5d7204a

Browse files
committed
Style: Add Mainframe homepage
1 parent 7b3023f commit 5d7204a

File tree

3 files changed

+161
-21
lines changed

3 files changed

+161
-21
lines changed

assets/css/v2/style.css

+83-10
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,6 @@
6060
--color-shadow: #d2d2d2;
6161
--color-codeblock-border: #888;
6262
--color-codeblock-shadow: #e5e5e5;
63-
--color-codeblock-highlight: #fffed9;
6463
--color-footer: #1d1d1d;
6564
--color-footer-text: #e2e2e2;
6665
--color-product-title: #8d8d8d;
@@ -281,6 +280,86 @@ header {
281280
}
282281
}
283282

283+
/* MARK: Home page
284+
*/
285+
.home-layout {
286+
display: grid;
287+
grid-template-columns: var(--grid-content);
288+
margin: 4rem 2rem;
289+
290+
row-gap: var(--flow-gap);
291+
}
292+
293+
.home-layout h1 {
294+
margin: 0;
295+
}
296+
297+
.cta {
298+
margin: 1rem 0;
299+
}
300+
301+
.jump-links {
302+
display: flex;
303+
column-gap: 2.5rem;
304+
305+
margin: 1rem 0;
306+
}
307+
308+
.jump-links ul {
309+
list-style: none;
310+
}
311+
312+
.get-started-button {
313+
background-color: white;
314+
border: 1px solid black;
315+
padding: 0.25rem 0.5rem;
316+
cursor: pointer;
317+
font-size: 1.25rem;
318+
font-weight: 400;
319+
color: #000;
320+
margin-top: 8px;
321+
z-index: 1;
322+
--color-codeblock-shadow: 0% 0 0;
323+
box-shadow: 0px 2px 0px oklch(var(--color-codeblock-shadow) / 0.15);
324+
325+
text-decoration: none;
326+
}
327+
328+
#products {
329+
margin: 2rem 0 0 0;
330+
}
331+
332+
.product-grid {
333+
margin: 1.5rem 0 0 0;
334+
}
335+
336+
.product-grid ul {
337+
list-style: none;
338+
}
339+
340+
.tiny-pill {
341+
display: inline-block;
342+
font-size: 0.625rem;
343+
font-weight: 800;
344+
345+
margin: 0 0.25rem;
346+
vertical-align: 2px;
347+
348+
border-radius: 3px;
349+
padding: 0 2px;
350+
background-color: oklch(var(--color-brand) / 0.8);
351+
color: var(--color-background);
352+
}
353+
354+
.get-started-button:hover {
355+
box-shadow: 0px 2px 0px oklch(var(--color-brand) / 0.3);
356+
}
357+
358+
.get-started-button:focus {
359+
outline: none;
360+
box-shadow: 0px 2px 0px oklch(var(--color-brand) / 0.8);
361+
}
362+
284363
/* MARK: Footer
285364
*/
286365
footer {
@@ -437,7 +516,7 @@ nav {
437516

438517
.text-content {
439518
grid-template-columns: var(--grid-content) var(--grid-side-callout);
440-
grid-template-rows: 70px max-content;
519+
grid-template-rows: 70px auto;
441520
column-gap: var(--grid-column-gutter);
442521
}
443522

@@ -484,7 +563,7 @@ nav {
484563

485564
/* Handles different flow-gap of list page */
486565
.list-page.text-content {
487-
grid-template-rows: calc(70px + var(--flow-gap)) max-content;
566+
grid-template-rows: calc(70px + var(--flow-gap)) auto;
488567
}
489568

490569
.api {
@@ -505,7 +584,7 @@ nav {
505584
}
506585

507586
.main {
508-
display: flex;
587+
margin: 0 auto;
509588
}
510589

511590
/* MARK: Coveo
@@ -1461,12 +1540,6 @@ ul .code-block {
14611540
padding: 0;
14621541
}
14631542

1464-
.highlight code .hl {
1465-
width: fit-content;
1466-
min-width: 100%;
1467-
background-color: var(--color-codeblock-highlight);
1468-
}
1469-
14701543
/* MARK: Images
14711544
*/
14721545
figure {

exampleSite/layouts/index.html

+78-11
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,83 @@
11
{{ define "main" }}
2+
{{ $nginxProducts := slice
3+
(dict "title" "NGINX One Console" "url" "/nginx-one" "type" "nginx-one")
4+
(dict "title" "NGINX Plus" "url" "/nginx" "type" "nginx-one")
5+
(dict "title" "NGINX Instance Manager" "url" "/nginx-instance-manager" "type" "nginx-one")
6+
(dict "title" "NGINX Ingress Controller" "url" "/nginx-ingress-controller" "type" "nginx-one")
7+
(dict "title" "NGINX Gateway Fabric" "url" "/nginx-gateway-fabric" "type" "nginx-one")
8+
(dict "title" "NGINX Open Source" "url" "https://nginx.org/en/docs/" "type" "nginx-one")
9+
(dict "title" "NGINX Agent" "url" "/nginx-agent" "type" "nginx-one")
10+
(dict "title" "NGINX App Protect WAF" "url" "/nginx-app-protect-waf" "type" "nginx-app-protect")
11+
(dict "title" "NGINX App Protect DoS" "url" "/nginx-app-protect-dos" "type" "nginx-app-protect")
12+
(dict "title" "NGINX as a Service for Azure" "url" "/nginxaas/azure/" "type" "nginx-as-a-service")
13+
(dict "title" "NGINX Unit" "url" "https://unit.nginx.org/" "type" "nginx-other")
14+
}}
215

3-
<h1>Homepage Example</h1>
4-
<p>
5-
<ul>
6-
<li>
7-
<a href="{{ relref . "nginx" }}">NGINX and NGINX Plus</a>
8-
</li>
9-
<li>
10-
<a href="{{ relref . "test-product" }}">Test Product</a>
11-
</li>
12-
</ul>
13-
</p>
16+
{{ $nginxCategories :=
17+
(dict
18+
"nginx-one" "NGINX One"
19+
"nginx-app-protect" "NGINX App Protect"
20+
"nginx-as-a-service" "NGINX as a Service"
21+
"nginx-other" "Other NGINX Projects"
22+
)
23+
}}
1424

25+
<div class="main">
26+
<div class="home-layout">
27+
<h1>Documentation</h1>
28+
<p>This is a short call to action to explore our examples and guides.</p>
29+
30+
<div class="cta">
31+
<a href="https://nginx.org" class="get-started-button">Get started with NGINX One →</a> or <a href="#products">explore all products</a>.
32+
</div>
33+
34+
<div class="jump-links">
35+
<ul>
36+
<h3>Instance management</h3>
37+
<li><a href="https://docs.nginx.com/nginx-one/how-to/certificates/manage-certificates/">Manage certificates<span class="tiny-pill">One</span></a></li>
38+
<li><a href="#">Role-based access control</a></li>
39+
<li><a href="#">Create a new data plane key</a></li>
40+
</ul>
41+
<ul>
42+
<h3>Kubernetes</h3>
43+
<li><a href="https://docs.nginx.com/nginx-one/how-to/certificates/manage-certificates/">Manage certificates</a></li>
44+
<li><a href="#">Role-based access control</a></li>
45+
<li><a href="#">Create a new data plane key</a></li>
46+
</ul>
47+
<ul>
48+
<h3>Load balancing</h3>
49+
<li><a href="#">NGINX HTTP Load Balancing</a></li>
50+
<li><a href="#">NGINX TCP and UDP Load Balancing</a></li>
51+
<li><a href="#">GSLB with NS1 and NGINX Plus<span class="tiny-pill">N+</span></a></li>
52+
</ul>
53+
</div>
1554

55+
<p>The F5 NGINX One Console makes it easy to manage NGINX instances across locations and environments. The console lets you monitor and control your NGINX fleet from one place—you can check configurations, track performance metrics, identify security vulnerabilities, manage SSL certificates, and more.</p>
56+
57+
<div id="products">
58+
<h2>All products</h2>
59+
{{ $groupedProducts := dict
60+
"nginx-one" (where $nginxProducts "type" "nginx-one")
61+
"nginx-app-protect" (where $nginxProducts "type" "nginx-app-protect")
62+
"nginx-as-a-service" (where $nginxProducts "type" "nginx-as-a-service")
63+
"nginx-other" (where $nginxProducts "type" "nginx-other")
64+
}}
65+
{{ $orderedKeys := slice "nginx-one" "nginx-app-protect" "nginx-as-a-service" "nginx-other" }}
66+
{{ range $orderedKeys }}
67+
{{ $type := . }}
68+
{{ $products := index $groupedProducts $type }}
69+
<div class="product-grid">
70+
<p>{{ index $nginxCategories $type }}</p>
71+
<ul>
72+
{{ range $products }}
73+
<li>
74+
<a href="{{ .url }}">{{ .title }}</a>
75+
</li>
76+
{{ end }}
77+
</ul>
78+
</div>
79+
{{ end }}
80+
</div>
81+
</div>
82+
</div>
1683
{{end}}

layouts/partials/homepage/bigcta.html

Whitespace-only changes.

0 commit comments

Comments
 (0)