Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Docusaurus3.0 #500

Merged
merged 20 commits into from
Dec 3, 2023
3 changes: 2 additions & 1 deletion docs/docs/overview/Introduction.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,8 @@ import { CustomCard } from '@site/src/CustomComponents/CustomCard.tsx';
import { CustomCardList } from '@site/src/CustomComponents/CustomCardList.tsx';
import { DocPageHeader } from '@site/src/CustomComponents/DocPageHeader.tsx';
import { HeroImage } from '@site/src/CustomComponents/HeroImage.tsx';
<DocPageHeader title="Welcome to the Neosync Docs" />;

<DocPageHeader title="Welcome to the Neosync Docs" />

Neosync is an open-source, developer-first way to create safe, anonymized test data from production data and sync it across all environments for high-quality local, stage and CI testing.

Expand Down
1 change: 1 addition & 0 deletions docs/docs/overview/platform.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ slug: /platform
---

import { DocPageHeader } from '@site/src/CustomComponents/DocPageHeader.tsx';
import { HeroImage } from '@site/src/CustomComponents/HeroImage.tsx';

<DocPageHeader title="Platform Overview" />

Expand Down
77 changes: 37 additions & 40 deletions docs/docusaurus.config.js → docs/docusaurus.config.ts
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
// @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');
import type * as Preset from '@docusaurus/preset-classic';
import { Config } from '@docusaurus/types';
import { themes } from 'prism-react-renderer';

/** @type {import('@docusaurus/types').Config} */
const config = {
const config: Config = {
title: 'Neosync',
tagline: 'Open source Test Data Management',
favicon: 'img/logo_light_mode.png',
Expand All @@ -32,7 +32,7 @@ const config = {
locales: ['en'],
},
plugins: [
async function myPlugin(context, options) {
async function tailwindcssPlugin(context, options) {
return {
name: 'docusaurus-tailwindcss',
configurePostCss(postcssOptions) {
Expand All @@ -48,54 +48,51 @@ const config = {
presets: [
[
'classic',
/** @type {import('@docusaurus/preset-classic').Options} */
({
{
docs: {
routeBasePath: '/',
sidebarPath: require.resolve('./sidebars.js'),
sidebarPath: './sidebars.ts',
// Please change this to your repo.
// Remove this to remove the "edit this page" links.
editUrl: 'https://github.com/nucleuscloud/neosync/docs',
editUrl: 'https://github.com/nucleuscloud/neosync/blob/main/docs',
},
blog: false,
theme: {
customCss: require.resolve('./src/css/custom.css'),
},
}),
} satisfies Preset.Options,
],
],

themeConfig:
/** @type {import('@docusaurus/preset-classic').ThemeConfig} */
({
image: 'img/docusaurus-social-card.jpg',
colorMode: {
defaultMode: 'light',
disableSwitch: true,
respectPrefersColorScheme: false,
themeConfig: {
image: 'img/docusaurus-social-card.jpg',
colorMode: {
defaultMode: 'light',
disableSwitch: true,
respectPrefersColorScheme: false,
},
navbar: {
logo: {
alt: 'Neosync',
srcDark: 'img/logo_and_text_dark_mode.png',
src: 'img/logo_and_text_light_mode.png',
},
navbar: {
logo: {
alt: 'Neosync',
srcDark: 'img/logo_and_text_dark_mode.png',
src: 'img/logo_and_text_light_mode.png',
items: [
{
type: 'custom-Gitlink',
position: 'right',
},
items: [
{
type: 'custom-Gitlink',
position: 'right',
},
],
},
footer: {
style: 'dark',
copyright: `Copyright © Nucleus Cloud Corp ${new Date().getFullYear()}`,
},
prism: {
theme: lightCodeTheme,
darkTheme: darkCodeTheme,
},
}),
],
},
footer: {
style: 'dark',
copyright: `Copyright © Nucleus Cloud Corp ${new Date().getFullYear()}`,
},
prism: {
theme: themes.github,
darkTheme: themes.dracula,
},
} satisfies Preset.ThemeConfig,
};

module.exports = config;
export default config;
4 changes: 2 additions & 2 deletions docs/knip.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
const config = {
ignore: [
'babel.config.js',
'docusaurus.config.js',
'sidebars.js',
'docusaurus.config.ts',
'sidebars.ts',
'static/sync-dark-mode.js',
'src/**',
'src/theme/**',
Expand Down
Loading