mirror of
https://github.com/GitbookIO/gitbook.git
synced 2026-10-03 12:10:34 +00:00
@@ -1,5 +1,6 @@
|
||||
import { RevisionPage, RevisionPageDocument, RevisionPageGroup } from '@gitbook/api';
|
||||
|
||||
import { Emoji } from '@/components/primitives';
|
||||
import { pageHref } from '@/lib/links';
|
||||
import { getPagePath } from '@/lib/pages';
|
||||
import { ContentRefContext } from '@/lib/references';
|
||||
@@ -39,7 +40,14 @@ export function PageDocumentItem(props: {
|
||||
) : null
|
||||
}
|
||||
>
|
||||
{page.title}
|
||||
{page.emoji ? (
|
||||
<span className={tcls('flex', 'gap-3', 'flex-row')}>
|
||||
<Emoji code={page.emoji} />
|
||||
{page.title}
|
||||
</span>
|
||||
) : (
|
||||
page.title
|
||||
)}
|
||||
</ToggleableLinkItem>
|
||||
</li>
|
||||
);
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
import { RevisionPage, RevisionPageDocument, RevisionPageGroup } from '@gitbook/api';
|
||||
|
||||
import { Emoji } from '@/components/primitives';
|
||||
import { ContentRefContext } from '@/lib/references';
|
||||
import { tcls } from '@/lib/tailwind';
|
||||
|
||||
@@ -36,6 +37,7 @@ export function PageGroupItem(props: {
|
||||
'dark:to-transparent',
|
||||
)}
|
||||
>
|
||||
{page.emoji ? <Emoji code={page.emoji} style={['mr-3']} /> : null}
|
||||
{page.title}
|
||||
</div>
|
||||
{page.pages && page.pages.length ? (
|
||||
|
||||
@@ -2,6 +2,7 @@ import IconExternal from '@geist-ui/icons/externalLink';
|
||||
import { RevisionPageLink } from '@gitbook/api';
|
||||
import Link from 'next/link';
|
||||
|
||||
import { Emoji } from '@/components/primitives';
|
||||
import { ContentRefContext, resolveContentRef } from '@/lib/references';
|
||||
import { tcls } from '@/lib/tailwind';
|
||||
|
||||
@@ -35,6 +36,7 @@ export async function PageLinkItem(props: { page: RevisionPageLink; context: Con
|
||||
'dark:hover:bg-light/2',
|
||||
)}
|
||||
>
|
||||
{page.emoji ? <Emoji code={page.emoji} /> : null}
|
||||
{page.title}
|
||||
<IconExternal
|
||||
className={tcls(
|
||||
|
||||
Reference in New Issue
Block a user