-
Notifications
You must be signed in to change notification settings - Fork 228
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #491 from semaphore-protocol/chore/docs
Semaphore Docusaurus documentation
- Loading branch information
Showing
149 changed files
with
18,330 additions
and
237 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
checksumBehavior: update | ||
|
||
nodeLinker: node-modules | ||
|
||
yarnPath: .yarn/releases/yarn-3.2.1.cjs |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,75 @@ | ||
<p align="center"> | ||
<h1 align="center"> | ||
<picture> | ||
<source media="(prefers-color-scheme: dark)" srcset="https://github.com/semaphore-protocol/.github/blob/main/assets/semaphore-logo-light.svg"> | ||
<source media="(prefers-color-scheme: light)" srcset="https://github.com/semaphore-protocol/.github/blob/main/assets/semaphore-logo-dark.svg"> | ||
<img width="250" alt="Semaphore icon" src="https://github.com/semaphore-protocol/.github/blob/main/assets/semaphore-logo-dark.svg"> | ||
</picture> | ||
</h1> | ||
</p> | ||
|
||
<p align="center"> | ||
<a href="https://github.com/semaphore-protocol" target="_blank"> | ||
<img src="https://img.shields.io/badge/project-Semaphore-blue.svg?style=flat-square"> | ||
</a> | ||
<a href="https://github.com/semaphore-protocol/semaphore/blob/main/LICENSE"> | ||
<img alt="Github license" src="https://img.shields.io/github/license/semaphore-protocol/semaphore.svg?style=flat-square"> | ||
</a> | ||
<a href="https://eslint.org/"> | ||
<img alt="Linter eslint" src="https://img.shields.io/badge/linter-eslint-8080f2?style=flat-square&logo=eslint" /> | ||
</a> | ||
<a href="https://prettier.io/"> | ||
<img alt="Code style prettier" src="https://img.shields.io/badge/code%20style-prettier-f8bc45?style=flat-square&logo=prettier" /> | ||
</a> | ||
</p> | ||
|
||
<div align="center"> | ||
<h4> | ||
<a href="https://github.com/semaphore-protocol/semaphore/blob/main/CONTRIBUTING.md"> | ||
👥 Contributing | ||
</a> | ||
<span> | </span> | ||
<a href="https://github.com/semaphore-protocol/semaphore/blob/main/CODE_OF_CONDUCT.md"> | ||
🤝 Code of conduct | ||
</a> | ||
<span> | </span> | ||
<a href="https://github.com/semaphore-protocol/semaphore/contribute"> | ||
🔎 Issues | ||
</a> | ||
<span> | </span> | ||
<a href="https://semaphore.pse.dev/discord"> | ||
🗣️ Chat & Support | ||
</a> | ||
</h4> | ||
</div> | ||
|
||
| This repository contains the code for the Semaphore documentation published at [docs.semaphore.pse.dev](https://docs.semaphore.pse.dev). It uses Markdown syntax and the [Docusaurus](https://docusaurus.io/) site generator. | | ||
| ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | ||
|
||
## 📜 Usage | ||
|
||
### Start the website | ||
|
||
To generate the HTML and start the site, run: | ||
|
||
```sh | ||
yarn start | ||
``` | ||
|
||
Visit the Semaphore docs site in your browser at [http://localhost:3000](http://localhost:3000). | ||
|
||
### Build | ||
|
||
``` | ||
yarn build | ||
``` | ||
|
||
The `build` command generates static content into the `build` directory that can be served by any static content hosting service. | ||
|
||
### Deploy | ||
|
||
``` | ||
$ GIT_USER=<Your GitHub username> USE_SSH=true yarn deploy | ||
``` | ||
|
||
If you use GitHub pages for hosting, this command lets you build the website and push to the `gh-pages` branch. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
module.exports = { | ||
presets: [require.resolve("@docusaurus/core/lib/babel/preset")] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,102 @@ | ||
// @ts-check | ||
// Note: type annotations allow type checking and IDEs autocompletion | ||
|
||
const lightCodeTheme = require("prism-react-renderer/themes/github") | ||
const darkCodeTheme = require("prism-react-renderer/themes/dracula") | ||
|
||
/** @type {import('@docusaurus/types').Config} */ | ||
module.exports = { | ||
title: "Semaphore", | ||
tagline: "Documentation and Guides", | ||
url: "https://semaphore.pse.dev/", | ||
baseUrl: "/", | ||
favicon: "/img/favicon.ico", | ||
onBrokenLinks: "throw", | ||
onBrokenMarkdownLinks: "warn", | ||
organizationName: "semaphore-protocol", | ||
projectName: "semaphore", | ||
trailingSlash: false, | ||
|
||
plugins: ["docusaurus-plugin-sass"], | ||
|
||
i18n: { | ||
defaultLocale: "en", | ||
locales: ["en", "es"] | ||
}, | ||
|
||
presets: [ | ||
[ | ||
"classic", | ||
/** @type {import('@docusaurus/preset-classic').Options} */ | ||
({ | ||
docs: { | ||
routeBasePath: "docs/", | ||
sidebarPath: require.resolve("./sidebars.js"), | ||
editUrl: "https://github.com/semaphore-protocol/website/edit/main/", | ||
includeCurrentVersion: false | ||
}, | ||
theme: { | ||
customCss: [require.resolve("./src/css/custom.scss")] | ||
} | ||
}) | ||
] | ||
], | ||
|
||
themeConfig: | ||
/** @type {import('@docusaurus/preset-classic').ThemeConfig} */ | ||
({ | ||
// announcementBar: { | ||
// id: "semaphore-v3", | ||
// content: | ||
// '<b>We are pleased to announce the release of <a target="_blank" rel="noopener noreferrer" href="https://github.com/semaphore-protocol/semaphore/releases/tag/v3.0.0">Semaphore V3</a> 🎉</b>', | ||
// backgroundColor: "#DAE0FF", | ||
// textColor: "#000000" | ||
// }, | ||
navbar: { | ||
logo: { | ||
alt: "Semaphore Logo", | ||
src: "img/semaphore-logo.svg" | ||
}, | ||
items: [ | ||
{ | ||
label: "Whitepaper", | ||
to: "https://semaphore.pse.dev/whitepaper-v1.pdf", | ||
position: "right", | ||
className: "V1" | ||
}, | ||
{ | ||
label: "Documentation", | ||
href: "/docs/introduction", | ||
position: "right", | ||
className: "homepage" | ||
}, | ||
{ | ||
label: "Github", | ||
href: "https://github.com/semaphore-protocol", | ||
position: "right" | ||
}, | ||
{ | ||
type: "localeDropdown", | ||
position: "right" | ||
} | ||
] | ||
}, | ||
colorMode: { | ||
defaultMode: "dark", | ||
// Should we use the prefers-color-scheme media-query, | ||
// using user system preferences, instead of the hardcoded defaultMode | ||
respectPrefersColorScheme: true | ||
}, | ||
prism: { | ||
theme: lightCodeTheme, | ||
darkTheme: darkCodeTheme, | ||
additionalLanguages: ["solidity"] | ||
}, | ||
algolia: { | ||
appId: "6P229KVKCB", | ||
apiKey: "879bb5b002b6370f181f0f79f5c2afe2", | ||
indexName: "semaphoreliedzkp", | ||
contextualSearch: true | ||
} | ||
}) | ||
} |
Oops, something went wrong.