Skip to content

Commit

Permalink
Change CNCF logo for dark mode (main page only)
Browse files Browse the repository at this point in the history
Co-authored-by: Tamilselvan Thangamony <[email protected]>
  • Loading branch information
sftim and tamilselvan1102 committed Jan 28, 2025
1 parent efb0708 commit 4710274
Show file tree
Hide file tree
Showing 6 changed files with 125 additions and 5 deletions.
24 changes: 24 additions & 0 deletions assets/scss/_custom.scss
Original file line number Diff line number Diff line change
Expand Up @@ -284,6 +284,30 @@ input[type="search"]{
}


.cncf-logo-details {
display: flex;
flex-direction: column;
align-items: center;

p {
text-align: center;
}

a {
color: inherit;
background: transparent;
text-decoration: underline; // exception from usual convention
}

picture {
display: block;
> * {
min-height: 4em;
width: calc(clamp(20em,18em+20mm,100vw));
}
}
}

/* FOOTER */
footer {
background-color: #202020;
Expand Down
6 changes: 1 addition & 5 deletions layouts/index.html
Original file line number Diff line number Diff line change
@@ -1,11 +1,7 @@
{{ define "main" }}
{{ .Content }}
<section id="cncf">
<div class="main-section">
<center>
<p style="font-size: 20px">{{ T "main_cncf_project" | safeHTML }}
</center>
</div>
{{ partial "cncf.html" . }}
</section>

<section id="kubeweekly">
Expand Down
9 changes: 9 additions & 0 deletions layouts/partials/cncf.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<div class="main-section">
<div class="cncf-logo-details">
<p>{{ T "main_cncf_project" | safeHTML }}</p>
<picture>
<source srcset="/images/cncf-logo-dark.svg" media="(prefers-color-scheme: dark)">
<img src="/images/cncf-logo-white.svg" class="cncf-img">
</picture>
</div>
</div>
91 changes: 91 additions & 0 deletions static/images/cncf-logo-dark.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
File renamed without changes
Binary file removed static/images/cncf-white.png
Binary file not shown.

0 comments on commit 4710274

Please sign in to comment.