From fd206a76bfff8a8963cce18b819bf08a4235e81d Mon Sep 17 00:00:00 2001 From: lodev09 Date: Tue, 23 Apr 2024 02:09:00 +0800 Subject: [PATCH] docs: styles 2 --- docs/.gitattributes | 2 ++ docs/docusaurus.config.ts | 6 ------ docs/src/css/custom.css | 17 +++++++++++++---- .../theme/DocSidebar/Desktop/Content/index.tsx | 14 ++++++++++++++ 4 files changed, 29 insertions(+), 10 deletions(-) create mode 100644 docs/.gitattributes create mode 100644 docs/src/theme/DocSidebar/Desktop/Content/index.tsx diff --git a/docs/.gitattributes b/docs/.gitattributes new file mode 100644 index 0000000..0f278cb --- /dev/null +++ b/docs/.gitattributes @@ -0,0 +1,2 @@ +# This is just so that GitHub shows the language "Swift" as the repo language. +*.mdx linguist-language=Swift diff --git a/docs/docusaurus.config.ts b/docs/docusaurus.config.ts index 457c692..c99dd6f 100644 --- a/docs/docusaurus.config.ts +++ b/docs/docusaurus.config.ts @@ -34,12 +34,6 @@ const config: Config = { routeBasePath: '/', sidebarPath: './sidebars.ts', editUrl: 'https://github.com/lodev09/react-native-true-sheet/blob/main/docs/', - versions: { - current: { - label: pkg.version, - badge: true, - }, - }, }, blog: { showReadingTime: true, diff --git a/docs/src/css/custom.css b/docs/src/css/custom.css index e616466..083b7da 100644 --- a/docs/src/css/custom.css +++ b/docs/src/css/custom.css @@ -36,10 +36,19 @@ --ifm-alert-background-color: #11663f; } -.menu_node_modules-\@docusaurus-theme-classic-lib-theme-DocSidebar-Desktop-Content-styles-module { - padding: 1rem !important; +.padding-top--md { + padding: 1.5rem !important; } -.docSidebarContainer_node_modules-\@docusaurus-theme-classic-lib-theme-DocRoot-Layout-Sidebar-styles-module { - border-right-width: 0px !important; +.doc-sidebar-content { + padding: 1.5rem !important; +} + +.theme-doc-sidebar-container { + border-right-width: 0 !important; +} + +.pagination-nav__link { + background-color: var(--ifm-menu-color-background-active); + border-width: 0; } diff --git a/docs/src/theme/DocSidebar/Desktop/Content/index.tsx b/docs/src/theme/DocSidebar/Desktop/Content/index.tsx new file mode 100644 index 0000000..01d0cb6 --- /dev/null +++ b/docs/src/theme/DocSidebar/Desktop/Content/index.tsx @@ -0,0 +1,14 @@ +import React from 'react' +import Content from '@theme-original/DocSidebar/Desktop/Content' +import type ContentType from '@theme/DocSidebar/Desktop/Content' +import type { WrapperProps } from '@docusaurus/types' + +type Props = WrapperProps + +export default function ContentWrapper(props: Props): React.ReactElement { + return ( + <> + + + ) +}