Skip to content

Commit 0645169

Browse files
committed
uniform style
1 parent 9766d60 commit 0645169

9 files changed

+262
-50
lines changed

docs/intro.md

-8
This file was deleted.

docusaurus.config.js

+11-3
Original file line numberDiff line numberDiff line change
@@ -31,12 +31,11 @@ const config = {
3131
routeBasePath: "/",
3232
// Please change this to your repo.
3333
// Remove this to remove the "edit this page" links.
34-
editUrl:
35-
"https://github.com/facebook/docusaurus/tree/main/packages/create-docusaurus/templates/shared/",
34+
editUrl: "https://github.com/signalwire/freeswitch-docs/tree/main/",
3635
},
3736
blog: false,
3837
theme: {
39-
customCss: require.resolve("./src/css/custom.css"),
38+
customCss: require.resolve("./src/css/custom.scss"),
4039
},
4140
}),
4241
],
@@ -64,13 +63,20 @@ const config = {
6463
position: "left",
6564
label: "Variables",
6665
},
66+
{
67+
href: "pathname:///../guides",
68+
label: "SignalWire",
69+
position: "left",
70+
target: "_self",
71+
},
6772
{
6873
href: "https://github.com/signalwire/freeswitch",
6974
label: "GitHub",
7075
position: "right",
7176
},
7277
],
7378
},
79+
colorMode: { disableSwitch: true, defaultMode: "light" },
7480
footer: {
7581
style: "dark",
7682
links: [
@@ -121,6 +127,8 @@ const config = {
121127
darkTheme: darkCodeTheme,
122128
},
123129
}),
130+
131+
plugins: ["docusaurus-plugin-sass"],
124132
};
125133

126134
module.exports = config;

package-lock.json

+136-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

+3-1
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,11 @@
1818
"@docusaurus/preset-classic": "2.2.0",
1919
"@mdx-js/react": "^1.6.22",
2020
"clsx": "^1.2.1",
21+
"docusaurus-plugin-sass": "^0.2.2",
2122
"prism-react-renderer": "^1.3.5",
2223
"react": "^17.0.2",
23-
"react-dom": "^17.0.2"
24+
"react-dom": "^17.0.2",
25+
"sass": "^1.56.2"
2426
},
2527
"devDependencies": {
2628
"@docusaurus/module-type-aliases": "2.2.0"

src/css/custom.css

-30
This file was deleted.

src/css/custom.scss

+53
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
/**
2+
* Any CSS included here will be global. The classic template
3+
* bundles Infima by default. Infima is a CSS framework designed to
4+
* work well for content-centric websites.
5+
*/
6+
7+
/* You can override the default Infima variables here. */
8+
:root {
9+
--ifm-font-family-base: 'Inter',sans-serif;
10+
--ifm-heading-font-family: 'Neue Einstellung',sans-serif;
11+
12+
--ifm-color-primary: rgb(28,81,121);
13+
/* --ifm-color-primary-dark: #29784c;
14+
--ifm-color-primary-darker: #277148;
15+
--ifm-color-primary-darkest: #205d3b;
16+
--ifm-color-primary-light: #33925d;
17+
--ifm-color-primary-lighter: #359962;
18+
--ifm-color-primary-lightest: #3cad6e; */
19+
--ifm-code-font-size: 95%;
20+
--docusaurus-highlighted-code-line-bg: rgba(0, 0, 0, 0.1);
21+
}
22+
23+
/* For readability concerns, you should choose a lighter palette in dark mode. */
24+
[data-theme='dark'] {
25+
--ifm-color-primary: rgb(28,81,121);
26+
--ifm-color-primary-dark: #21af90;
27+
--ifm-color-primary-darker: #1fa588;
28+
--ifm-color-primary-darkest: #1a8870;
29+
--ifm-color-primary-light: #29d5b0;
30+
--ifm-color-primary-lighter: #32d8b4;
31+
--ifm-color-primary-lightest: #4fddbf;
32+
--docusaurus-highlighted-code-line-bg: rgba(0, 0, 0, 0.3);
33+
}
34+
35+
h1, h2 {
36+
font-weight: var(--ifm-font-weight-semibold);
37+
}
38+
39+
/* Neue Einstellung font-face */
40+
@font-face {
41+
font-family:"Neue Einstellung";font-style:normal;font-weight:500;font-display:swap;src:url(//cdn.signalwire.com/fonts/neue-einstellung/NeueEinstellung-Medium.woff2) format("woff2"),url(//cdn.signalwire.com/fonts/neue-einstellung/NeueEinstellung-Medium.woff) format("woff")}@font-face{font-family:"Neue Einstellung";font-style:normal;font-weight:700;font-display:swap;src:url(//cdn.signalwire.com/fonts/neue-einstellung/NeueEinstellung-Bold.woff2) format("woff2"),url(//cdn.signalwire.com/fonts/neue-einstellung/NeueEinstellung-Bold.woff) format("woff")}@font-face{font-family:"Neue Einstellung";font-style:normal;font-weight:100;font-display:swap;src:url(//cdn.signalwire.com/fonts/neue-einstellung/NeueEinstellung-Thin.woff2) format("woff2"),url(//cdn.signalwire.com/fonts/neue-einstellung/NeueEinstellung-Thin.woff) format("woff"),url(//cdn.signalwire.com/fonts/neue-einstellung/NeueEinstellung-Thin.eot) format("eot"),url(//cdn.signalwire.com/fonts/neue-einstellung/NeueEinstellung-Thin.ttf) format("ttf")}@font-face{font-family:"Neue Einstellung";font-style:normal;font-weight:200;font-display:swap;src:url(//cdn.signalwire.com/fonts/neue-einstellung/NeueEinstellung-Light.woff2) format("woff2"),url(//cdn.signalwire.com/fonts/neue-einstellung/NeueEinstellung-Light.woff) format("woff"),url(//cdn.signalwire.com/fonts/neue-einstellung/NeueEinstellung-Light.eot) format("eot"),url(//cdn.signalwire.com/fonts/neue-einstellung/NeueEinstellung-Light.ttf) format("ttf")}@font-face{font-family:"Neue Einstellung";font-style:normal;font-weight:300;font-display:swap;src:url(//cdn.signalwire.com/fonts/neue-einstellung/NeueEinstellung-Normal.woff2) format("woff2"),url(//cdn.signalwire.com/fonts/neue-einstellung/NeueEinstellung-Normal.woff) format("woff"),url(//cdn.signalwire.com/fonts/neue-einstellung/NeueEinstellung-Normal.eot) format("eot"),url(//cdn.signalwire.com/fonts/neue-einstellung/NeueEinstellung-Normal.ttf) format("ttf")}@font-face{font-family:"Neue Einstellung";font-style:normal;font-weight:400;font-display:swap;src:url(//cdn.signalwire.com/fonts/neue-einstellung/NeueEinstellung-Regular.woff2) format("woff2"),url(//cdn.signalwire.com/fonts/neue-einstellung/NeueEinstellung-Regular.woff) format("woff"),url(//cdn.signalwire.com/fonts/neue-einstellung/NeueEinstellung-Regular.eot) format("eot"),url(//cdn.signalwire.com/fonts/neue-einstellung/NeueEinstellung-Regular.ttf) format("ttf")}@font-face{font-family:"Neue Einstellung";font-style:normal;font-weight:500;font-display:swap;src:url(//cdn.signalwire.com/fonts/neue-einstellung/NeueEinstellung-Medium.woff2) format("woff2"),url(//cdn.signalwire.com/fonts/neue-einstellung/NeueEinstellung-Medium.woff) format("woff"),url(//cdn.signalwire.com/fonts/neue-einstellung/NeueEinstellung-Medium.eot) format("eot"),url(//cdn.signalwire.com/fonts/neue-einstellung/NeueEinstellung-Medium.ttf) format("ttf")}@font-face{font-family:"Neue Einstellung";font-style:normal;font-weight:600;font-display:swap;src:url(//cdn.signalwire.com/fonts/neue-einstellung/NeueEinstellung-SemiBold.woff2) format("woff2"),url(//cdn.signalwire.com/fonts/neue-einstellung/NeueEinstellung-SemiBold.woff) format("woff"),url(//cdn.signalwire.com/fonts/neue-einstellung/NeueEinstellung-SemiBold.eot) format("eot"),url(//cdn.signalwire.com/fonts/neue-einstellung/NeueEinstellung-SemiBold.ttf) format("ttf")}@font-face{font-family:"Neue Einstellung";font-style:normal;font-weight:700;font-display:swap;src:url(//cdn.signalwire.com/fonts/neue-einstellung/NeueEinstellung-Bold.woff2) format("woff2"),url(//cdn.signalwire.com/fonts/neue-einstellung/NeueEinstellung-Bold.woff) format("woff"),url(//cdn.signalwire.com/fonts/neue-einstellung/NeueEinstellung-Bold.eot) format("eot"),url(//cdn.signalwire.com/fonts/neue-einstellung/NeueEinstellung-Bold.ttf) format("ttf")}@font-face{font-family:"Neue Einstellung";font-style:normal;font-weight:800;font-display:swap;src:url(//cdn.signalwire.com/fonts/neue-einstellung/NeueEinstellung-ExtraBold.woff2) format("woff2"),url(//cdn.signalwire.com/fonts/neue-einstellung/NeueEinstellung-ExtraBold.woff) format("woff"),url(//cdn.signalwire.com/fonts/neue-einstellung/NeueEinstellung-ExtraBold.eot) format("eot"),url(//cdn.signalwire.com/fonts/neue-einstellung/NeueEinstellung-ExtraBold.ttf) format("ttf")}@font-face{font-family:"Neue Einstellung";font-style:normal;font-weight:900;font-display:swap;src:url(//cdn.signalwire.com/fonts/neue-einstellung/NeueEinstellung-Black.woff2) format("woff2"),url(//cdn.signalwire.com/fonts/neue-einstellung/NeueEinstellung-Black.woff) format("woff"),url(//cdn.signalwire.com/fonts/neue-einstellung/NeueEinstellung-Black.eot) format("eot"),url(//cdn.signalwire.com/fonts/neue-einstellung/NeueEinstellung-Black.ttf) format("ttf")
42+
}
43+
44+
/** Navbar **/
45+
.navbar {
46+
//border-bottom: 4px solid #f72a72;
47+
border-bottom: 4px solid var(--ifm-color-primary);
48+
font-size: 14px;
49+
50+
.navbar__items a > svg {
51+
display: none;
52+
}
53+
}

src/pages/index.js

+36
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
import React from "react";
2+
import clsx from "clsx";
3+
import Link from "@docusaurus/Link";
4+
import useDocusaurusContext from "@docusaurus/useDocusaurusContext";
5+
import Layout from "@theme/Layout";
6+
7+
import styles from "./index.module.css";
8+
9+
function HomepageHeader() {
10+
const { siteConfig } = useDocusaurusContext();
11+
return (
12+
<header className={clsx("hero hero--primary", styles.heroBanner)}>
13+
<div className="container">
14+
<h1 className="hero__title">{siteConfig.title}</h1>
15+
<p className="hero__subtitle">{siteConfig.tagline}</p>
16+
<div className={styles.buttons}>
17+
<Link
18+
className="button button--secondary button--lg"
19+
to="/FreeSWITCH-Explained/"
20+
>
21+
Get Started
22+
</Link>
23+
</div>
24+
</div>
25+
</header>
26+
);
27+
}
28+
29+
export default function Home() {
30+
const { siteConfig } = useDocusaurusContext();
31+
return (
32+
<Layout>
33+
<HomepageHeader />
34+
</Layout>
35+
);
36+
}

0 commit comments

Comments
 (0)