@windrun-huaiin/third-ui 5.6.0 → 5.6.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@windrun-huaiin/third-ui",
3
- "version": "5.6.0",
3
+ "version": "5.6.1",
4
4
  "description": "Third-party integrated UI components for windrun-huaiin projects",
5
5
  "main": "./dist/index.js",
6
6
  "module": "./dist/index.mjs",
@@ -1,8 +1,8 @@
1
- import { TocFooter } from '@third-ui/fuma/mdx/toc';
2
1
  import { DocsBody, DocsDescription, DocsPage, DocsTitle } from 'fumadocs-ui/page';
3
2
  import { ReactNode } from 'react';
3
+ import { TocFooterWrapper } from '@third-ui/fuma/mdx';
4
4
 
5
- interface FumaPageParams {
5
+ interface FumaPageParams {
6
6
  /*
7
7
  * The source of the mdx content
8
8
  */
@@ -51,7 +51,7 @@ export function createFumaPage({
51
51
 
52
52
  const path = githubBaseUrl ? `${mdxSourceDir}/${page.file.path}` : undefined;
53
53
  const tocFooterElement = (
54
- <TocFooter
54
+ <TocFooterWrapper
55
55
  lastModified={page.data.date}
56
56
  showCopy={showCopy}
57
57
  editPath={path}
@@ -6,9 +6,9 @@ export * from './trophy-card';
6
6
  export * from './image-grid';
7
7
  export * from './zia-card';
8
8
  export * from './gradient-button';
9
- export * from './toc';
10
9
  export * from './toc-base';
11
10
  export * from './fuma-banner-suit';
12
11
  export * from './fuma-github-info';
13
12
  export * from './site-x';
14
- export * from './zia-file';
13
+ export * from './zia-file';
14
+ export * from './toc-footer-wrapper';
@@ -0,0 +1,20 @@
1
+ 'use client';
2
+ import { EditOnGitHub, LastUpdatedDate, LLMCopyButton } from '@third-ui/fuma/mdx/toc-base';
3
+
4
+ interface TocFooterProps {
5
+ lastModified: string | undefined;
6
+ editPath?: string;
7
+ githubBaseUrl?: string;
8
+ showCopy?: boolean;
9
+ }
10
+
11
+ export function TocFooterWrapper({ lastModified, editPath, githubBaseUrl, showCopy }: TocFooterProps) {
12
+ const showEdit = githubBaseUrl && editPath;
13
+ return (
14
+ <div className="flex flex-col gap-y-2 items-start m-4">
15
+ <LastUpdatedDate date={lastModified} />
16
+ {showCopy && <LLMCopyButton />}
17
+ {showEdit && <EditOnGitHub url={`${githubBaseUrl}${editPath}`} />}
18
+ </div>
19
+ );
20
+ }
@@ -1,35 +0,0 @@
1
- 'use client';
2
-
3
- import { EditOnGitHub, LastUpdatedDate, LLMCopyButton } from '@third-ui/fuma/mdx/toc-base';
4
-
5
- interface TocFooterProps {
6
- /**
7
- * The last modified date of the page.
8
- */
9
- lastModified: string | undefined;
10
- /**
11
- * The path to the file for the \"Edit on GitHub\" link.
12
- * This should be the relative path from the repository root, e.g., 'src/mdx/docs/your-page.mdx'.
13
- */
14
- editPath?: string | undefined;
15
- /**
16
- * Whether to show the copy button.
17
- */
18
- showCopy?: boolean | undefined;
19
- /**
20
- * GitHub base URL for edit links
21
- */
22
- githubBaseUrl?: string;
23
- }
24
-
25
- export function TocFooter({ lastModified, showCopy, editPath, githubBaseUrl }: TocFooterProps) {
26
- const showEdit = githubBaseUrl && editPath;
27
-
28
- return (
29
- <div className="flex flex-col gap-y-2 items-start m-4">
30
- <LastUpdatedDate date={lastModified} />
31
- {showCopy && <LLMCopyButton />}
32
- {showEdit && <EditOnGitHub url={`${githubBaseUrl}${editPath}`} />}
33
- </div>
34
- );
35
- }