Skip to content

Commit a9708bd

Browse files
authored
chore(docs): style updates (#16768)
Please read [contributing guidelines](CONTRIBUTING.md) and remove this line. For audit-related pull requests, please use the [audit PR template](?expand=1&template=audit.md).
2 parents c29739c + b154b58 commit a9708bd

29 files changed

Lines changed: 170 additions & 272 deletions

barretenberg/docs/docusaurus.config.ts

Lines changed: 13 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -15,30 +15,32 @@ const versions = require("./versions.json");
1515
// To redirect /api to the static/api directory in dev mode (netlify handles it in prod)
1616
function apiPlugin(context: any, options: any) {
1717
return {
18-
name: 'api-static-plugin',
18+
name: "api-static-plugin",
1919
configureWebpack(config: any, isServer: boolean, utils: any) {
2020
if (!isServer) {
2121
return {
22-
mergeStrategy: { 'devServer.setupMiddlewares': 'replace' },
22+
mergeStrategy: { "devServer.setupMiddlewares": "replace" },
2323
devServer: {
2424
setupMiddlewares: (middlewares: any, devServer: any) => {
25-
const express = require('express');
26-
devServer.app.use('/api', express.static(path.join(__dirname, 'static/api')));
25+
const express = require("express");
26+
devServer.app.use(
27+
"/api",
28+
express.static(path.join(__dirname, "static/api"))
29+
);
2730
return middlewares;
2831
},
2932
},
3033
} as any;
3134
}
3235
return {};
33-
}
34-
}
36+
},
37+
};
3538
}
3639

37-
3840
const config: Config = {
3941
title: "Barretenberg",
4042
tagline: "Barretenberg is a fast, private and scalable zk-SNARK library.",
41-
favicon: "img/icon.svg",
43+
favicon: "img/Aztec_Symbol_Dark.png",
4244

4345
// Set the production url of your site here
4446
url: "https://bb.aztec.network",
@@ -82,7 +84,7 @@ const config: Config = {
8284
],
8385
versions: {
8486
current: {
85-
label: "dev"
87+
label: "dev",
8688
},
8789
},
8890
editUrl: (params) => {
@@ -133,7 +135,6 @@ const config: Config = {
133135
],
134136

135137
apiPlugin,
136-
137138
],
138139
themeConfig: {
139140
metadata: [
@@ -164,9 +165,9 @@ const config: Config = {
164165
navbar: {
165166
logo: {
166167
alt: "Aztec Logo",
167-
srcDark: "img/logo-light.svg",
168+
srcDark: "img/Aztec Wordmark_Light.svg",
168169
href: "/docs",
169-
src: "img/logo-dark.svg",
170+
src: "img/Aztec Wordmark_Dark.svg",
170171
},
171172
items: [
172173
{

barretenberg/docs/src/css/custom.css

Lines changed: 52 additions & 55 deletions
Original file line numberDiff line numberDiff line change
@@ -6,19 +6,20 @@
66

77
/* You can override the default Infima variables here. */
88
:root {
9-
--ifm-font-family-base: "Plain-Regular";
10-
--ifm-color-primary: #8c7eff;
11-
--ifm-color-primary-dark: #6e5bff;
12-
--ifm-color-primary-darker: #5f4aff;
13-
--ifm-color-primary-darkest: #3216ff;
14-
--ifm-color-primary-light: #aaa1ff;
15-
--ifm-color-primary-lighter: #b9b2ff;
16-
--ifm-color-primary-lightest: #e6e3ff;
9+
--ifm-font-family-base: "Oracle";
10+
--ifm-color-primary: #1a1400;
11+
--ifm-color-primary-dark: #171200;
12+
--ifm-color-primary-darker: #161100;
13+
--ifm-color-primary-darkest: #120e00;
14+
--ifm-color-primary-light: #1d1600;
15+
--ifm-color-primary-lighter: #1e1700;
16+
--ifm-color-primary-lightest: #221a00;
1717
--ifm-code-font-size: 95%;
1818
--docusaurus-highlighted-code-line-bg: rgba(0, 0, 0, 0.1);
19-
--ifm-link-color: #8c7eff;
20-
--ifm-menu-color-active: #8c7eff;
21-
--ifm-navbar-link-hover-color: #8c7eff;
19+
--ifm-link-color: #cc24c3;
20+
--ifm-link-hover-color: #ff2df4;
21+
--ifm-menu-color-active: #cc24c3;
22+
--ifm-navbar-link-hover-color: #cc24c3;
2223
--docsearch-modal-background: white;
2324
}
2425

@@ -93,26 +94,34 @@
9394
}
9495

9596
[data-theme="light"] {
96-
--ifm-background-color: #ffffff;
97-
--ifm-navbar-background-color: #ffffff;
98-
--ifm-footer-background-color: #ffffff;
99-
--ifm-menu-color: #2f1f49;
100-
--ifm-breadcrumb-item-background-active: #eeedf1;
101-
color: #2f1f49;
97+
--ifm-background-color: #f2eee1;
98+
--ifm-navbar-background-color: #f2eee1;
99+
--ifm-footer-background-color: #f2eee1;
100+
--ifm-menu-color: #1a1400;
101+
--ifm-breadcrumb-item-background-active: #f2eee1;
102+
--brand-background: #f2eee1;
102103
}
103104
[data-theme="dark"] {
104-
--ifm-color-primary: #9ba5e9;
105-
--ifm-color-primary-dark: #7b88e2;
106-
--ifm-color-primary-darker: #6b7adf;
107-
--ifm-color-primary-darkest: #3c4fd4;
108-
--ifm-color-primary-light: #bbc2f0;
109-
--ifm-color-primary-lighter: #cbd0f3;
110-
--ifm-color-primary-lightest: #fafbfe;
111-
background: #211733;
105+
--ifm-color-primary: #f2eee1;
106+
--ifm-color-primary-dark: #e4dcc0;
107+
--ifm-color-primary-darker: #ddd2b0;
108+
--ifm-color-primary-darkest: #c8b77f;
109+
--ifm-color-primary-light: #ffffff;
110+
--ifm-color-primary-lighter: #ffffff;
111+
--ifm-color-primary-lightest: #ffffff;
112+
--ifm-link-color: #a9cc1f;
113+
--ifm-link-hover-color: #d4ff28;
114+
--ifm-menu-color-active: #a9cc1f;
115+
--ifm-navbar-link-hover-color: #a9cc1f;
116+
--ifm-navbar-background-color: #1a1400;
117+
--ifm-footer-background-color: #1a1400;
118+
--brand-background: #1a1400;
119+
--ifm-font-color-base: #f2eee1;
120+
background: #1a1400;
112121
}
113122

114123
[data-theme="dark"] .navbar {
115-
background-color: #2f1f49;
124+
background-color: var(--brand-background);
116125
box-shadow: var(--ifm-navbar-shadow);
117126
display: flex;
118127
height: var(--ifm-navbar-height);
@@ -121,25 +130,25 @@
121130
}
122131

123132
[data-theme="dark"] .footer {
124-
--ifm-footer-background-color: #211733;
133+
--ifm-footer-background-color: var(--brand-background);
125134
--ifm-footer-color: var(--ifm-footer-link-color);
126135
--ifm-footer-link-color: var(--ifm-color-secondary);
127136
--ifm-footer-title-color: var(--ifm-color-white);
128137
}
129138

130139
[data-theme="light"] .navbar {
131-
background-color: #fcfbfc;
140+
background-color: var(--brand-background);
132141
}
133142

134143
[data-theme="light"] .footer {
135-
--ifm-footer-background-color: #fcfbfc;
136-
--ifm-footer-color: #2f1f49;
137-
--ifm-footer-link-color: #2f1f49;
138-
--ifm-footer-title-color: #2f1f49;
144+
--ifm-footer-background-color: var(--brand-background);
145+
--ifm-footer-color: #1a1400;
146+
--ifm-footer-link-color: #1a1400;
147+
--ifm-footer-title-color: #1a1400;
139148
}
140149

141150
[data-theme="dark"] .card {
142-
background-color: #321e4c;
151+
background-color: color-mix(in srgb, var(--brand-background) 85%, white);
143152
}
144153

145154
[data-theme="light"] {
@@ -154,24 +163,12 @@
154163
--docusaurus-highlighted-code-line-bg: rgb(72, 77, 91);
155164
}
156165

157-
[data-theme="light"] h1,
158-
[data-theme="light"] h2 {
159-
color: #321e4c;
160-
}
161-
162-
[data-theme="light"] h3,
163-
[data-theme="light"] h4,
164-
[data-theme="light"] h5,
165-
[data-theme="light"] h6 {
166-
color: #514167;
167-
}
168-
169166
ul li::marker {
170-
color: #8c7eff;
167+
color: #cc24c3;
171168
}
172169

173-
a {
174-
color: #8c7eff;
170+
[data-theme="dark"] ul li::marker {
171+
color: #a9cc1f;
175172
}
176173

177174
.code-block-error-line {
@@ -183,30 +180,30 @@ a {
183180
}
184181

185182
@font-face {
186-
font-family: "Plain-Regular";
187-
src: url("../../static/font/Plain-Regular.otf");
183+
font-family: "Oracle";
184+
src: url("../../static/font/ABCOracle-Book.otf");
188185
}
189186

190187
.sidebar-divider {
191-
border-top: 1px solid var(--ifm-color-gray-200);
188+
border-top: 1px solid var(--ifm-color-primary);
192189
display: block;
193190
margin: 0.5rem 0 0.25rem 1rem;
194191
}
195192

196193
html[data-theme="dark"] .sidebar-divider {
197-
border-top: 1px solid var(--ifm-color-gray-800);
194+
border-top: 1px solid var(--ifm-color-primary);
198195
}
199196

200197
.sidebar-title {
201198
font-size: 0.8rem;
202199
letter-spacing: 0.05rem;
203200
text-transform: uppercase;
204201
font-weight: 600;
205-
color: var(--ifm-color-gray-600);
202+
color: var(--ifm-color-primary);
206203
}
207204

208205
html[data-theme="dark"] .sidebar-divider {
209-
color: var(--ifm-color-gray-200);
206+
color: var(--ifm-color-primary);
210207
}
211208

212209
[data-theme="dark"] #optout-form {
@@ -399,6 +396,6 @@ html[data-theme="dark"] .sidebar-divider {
399396
text-decoration: none;
400397
}
401398
.divider {
402-
border-top: 2px solid #eee;
399+
border-top: 2px solid var(--ifm-color-primary);
403400
margin: 0.5em 0;
404401
}

barretenberg/docs/src/theme/DocBreadcrumbs/Items/Home/index.js

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,13 @@ import React from "react";
22
import Link from "@docusaurus/Link";
33
import useBaseUrl from "@docusaurus/useBaseUrl";
44
import { translate } from "@docusaurus/Translate";
5-
import IconHome from "@theme/Icon/Home";
5+
import ThemedImage from "@theme/ThemedImage";
66
import styles from "./styles.module.css";
7-
import AztecLogo from "@site/static/img/icon.svg";
87

98
export default function HomeBreadcrumbItem() {
109
const homeHref = useBaseUrl("/");
10+
const lightLogoSrc = useBaseUrl("img/Aztec Symbol_Light.png");
11+
const darkLogoSrc = useBaseUrl("img/Aztec_Symbol_Dark.png");
1112
return (
1213
<li className="breadcrumbs__item" itemProp="itemListElement">
1314
<Link
@@ -17,9 +18,13 @@ export default function HomeBreadcrumbItem() {
1718
description: "The ARIA label for the home page in the breadcrumbs",
1819
})}
1920
className="breadcrumbs__link"
20-
href={homeHref}
21+
to={homeHref}
2122
>
22-
<AztecLogo className={styles.breadcrumbHomeIcon} />
23+
<ThemedImage
24+
className={styles.breadcrumbHomeIcon}
25+
alt="Home"
26+
sources={{ light: darkLogoSrc, dark: lightLogoSrc }}
27+
/>
2328
</Link>
2429
</li>
2530
);
148 KB
Binary file not shown.
-80.6 KB
Binary file not shown.
3.5 KB
Loading
Lines changed: 3 additions & 0 deletions
Loading
Lines changed: 3 additions & 0 deletions
Loading
3.56 KB
Loading
4.29 MB
Loading

0 commit comments

Comments
 (0)