Skip to content

Commit 9f9c688

Browse files
committed
UPD | docs: search
1 parent 3b67f70 commit 9f9c688

File tree

5 files changed

+9
-5
lines changed

5 files changed

+9
-5
lines changed

docs/src/app/(home)/page.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,8 @@ export default function HomePage() {
1717
Build and run microservices written in C++ with different HTTP implementations
1818
</div>
1919
<div className="flex gap-2 justify-center md:justify-start">
20-
<a className="text-white font-bold bg-red-300 transition-colors py-2 px-4 rounded-[1.8rem] bg-gradient-to-r from-red-500 to-purple-500 dark:from-red-400 dark:to-purple-800 hover:bg-red-200" href="./docs/intro/quick-start">Quick Start</a>
21-
<a className="bg-gray-300 fond-bold text-black hover:bg-gray-200 dark:bg-gray-800 transition-colors py-2 px-4 rounded-[1.8rem] dark:hover:bg-gray-700 dark:text-white" href="./docs/intro/install">Documentation</a>
20+
<a className="text-white font-medium bg-red-300 transition-colors py-2 px-4 rounded-[1.8rem] bg-gradient-to-r from-red-500 to-purple-500 dark:from-red-400 dark:to-purple-800 hover:bg-red-200" href="./docs/intro/quick-start">Quick Start</a>
21+
<a className="bg-gray-300 font-medium text-black hover:bg-gray-200 dark:bg-gray-800 transition-colors py-2 px-4 rounded-[1.8rem] dark:hover:bg-gray-700 dark:text-white" href="./docs/intro/install">Documentation</a>
2222
</div>
2323
</div>
2424
<div className="order-[-1] md:order-1 max-h-[350px] flex justify-center items-center">

docs/src/app/layout.config.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,5 +9,5 @@ export const baseOptions: BaseLayoutProps = {
99
</span>
1010
)
1111
},
12-
githubUrl: "https://github.com/xiadnoring/manapi-http"
12+
githubUrl: "https://github.com/xiadnoring/manapi-http",
1313
};

docs/src/app/layout.tsx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,8 @@ import type { ReactNode } from 'react';
55
import { useDocsSearch } from 'fumadocs-core/search/client';
66
import { create } from '@orama/orama';
77
import SearchDialog from '@/components/search';
8+
import icon from './favicon.ico';
9+
810

911
const inter = Inter({
1012
subsets: ['latin'],
@@ -13,7 +15,7 @@ const inter = Inter({
1315
export default function Layout({ children }: { children: ReactNode }) {
1416
return (
1517
<html lang="en" className={inter.className} suppressHydrationWarning>
16-
<link rel="icon" href="/favicon.ico" sizes="any" />
18+
<link rel="icon" href={icon.src} sizes="any" />
1719
<body className="flex flex-col min-h-screen">
1820
<RootProvider search={{SearchDialog}}>{children}</RootProvider>
1921
</body>

docs/src/components/search.tsx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,11 @@ function initOrama(locale?: string) {
1313
export default function DefaultSearchDialog(props: SharedProps) {
1414
const client = useDocsSearch({
1515
type: 'static',
16-
initOrama
16+
initOrama,
17+
from: '/manapi-http/api/search'
1718
});
1819

20+
1921
return (<SearchDialog
2022
onSearchChange={client.setSearch}
2123
search={client.search}

0 commit comments

Comments
 (0)