Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions docs/bun.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

24 changes: 22 additions & 2 deletions docs/docusaurus.config.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import { themes as prismThemes } from 'prism-react-renderer';
import type { Config } from '@docusaurus/types';
import type * as Preset from '@docusaurus/preset-classic';
import type { Options as RedirectsOptions } from '@docusaurus/plugin-client-redirects';
import reactNativeWeb from './plugins/react-native-web.mjs';
import swmGeo from './plugins/swm-geo.mjs';

Expand All @@ -24,15 +25,28 @@ const config: Config = {
locales: ['en'],
},

plugins: [reactNativeWeb, swmGeo],
plugins: [
reactNativeWeb,
swmGeo,
[
'@docusaurus/plugin-client-redirects',
{
// The docs used to sit at the root, with the overview at /overview.
createRedirects: (path) => {
if (path === '/docs' || path === '/docs/') return '/overview';
if (path.startsWith('/docs/')) return path.slice('/docs'.length);
return undefined;
},
} satisfies RedirectsOptions,
],
],

presets: [
[
'classic',
{
docs: {
path: './content',
routeBasePath: '/',
breadcrumbs: false,
sidebarPath: './sidebars.ts',
editUrl:
Expand All @@ -54,6 +68,12 @@ const config: Config = {
navbar: {
title: 'React Native Bottom Sheet',
items: [
{
type: 'docSidebar',
sidebarId: 'docsSidebar',
label: 'Docs',
position: 'left',
},
{
href: 'https://github.com/software-mansion-labs/react-native-bottom-sheet',
label: 'GitHub',
Expand Down
1 change: 1 addition & 0 deletions docs/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
"dependencies": {
"@docusaurus/core": "3.10.2",
"@docusaurus/faster": "3.10.2",
"@docusaurus/plugin-client-redirects": "3.10.2",
"@docusaurus/preset-classic": "3.10.2",
"@mdx-js/react": "^3.1.1",
"clsx": "^2.1.1",
Expand Down
8 changes: 8 additions & 0 deletions docs/src/css/custom.css
Original file line number Diff line number Diff line change
Expand Up @@ -232,6 +232,14 @@
--docusaurus-highlighted-code-line-bg: rgba(0, 0, 0, 0.3);
}

/* The landing page's navbar floats over the hero. */
html.landing-page .navbar {
position: fixed;
inset: 0 0 auto;
background-color: transparent;
box-shadow: none;
}

.footer {
--ifm-footer-background-color: var(--ifm-background-color);
border-top: 1px solid var(--ifm-toc-border-color);
Expand Down
Loading
Loading