fumadocs-core 12.5.2 → 12.5.3

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.
@@ -12,10 +12,14 @@ var Link = forwardRef(
12
12
  (_a, ref) => {
13
13
  var _b = _a, {
14
14
  href = "#",
15
- external = !(href.startsWith("/") || href.startsWith("#") || href.startsWith("."))
15
+ external = !(href.startsWith("/") || href.startsWith("#") || href.startsWith(".")),
16
+ prefetch,
17
+ replace
16
18
  } = _b, props = __objRest(_b, [
17
19
  "href",
18
- "external"
20
+ "external",
21
+ "prefetch",
22
+ "replace"
19
23
  ]);
20
24
  if (external) {
21
25
  return /* @__PURE__ */ jsx(
@@ -30,7 +34,15 @@ var Link = forwardRef(
30
34
  })
31
35
  );
32
36
  }
33
- return /* @__PURE__ */ jsx(Original, __spreadValues({ ref, href }, props));
37
+ return /* @__PURE__ */ jsx(
38
+ Original,
39
+ __spreadValues({
40
+ ref,
41
+ href,
42
+ prefetch,
43
+ replace
44
+ }, props)
45
+ );
34
46
  }
35
47
  );
36
48
  Link.displayName = "Link";
@@ -1,5 +1,6 @@
1
1
  import * as react from 'react';
2
2
  import { LinkProps } from './link.js';
3
+ import 'next/link';
3
4
 
4
5
  type DynamicLinkProps = LinkProps;
5
6
  /**
@@ -7,8 +8,6 @@ type DynamicLinkProps = LinkProps;
7
8
  *
8
9
  * It supports dynamic hrefs, which means you can use `/[lang]/my-page` with `dynamicHrefs` enabled
9
10
  */
10
- declare const DynamicLink: react.ForwardRefExoticComponent<react.AnchorHTMLAttributes<HTMLAnchorElement> & {
11
- external?: boolean;
12
- } & react.RefAttributes<HTMLAnchorElement>>;
11
+ declare const DynamicLink: react.ForwardRefExoticComponent<LinkProps & react.RefAttributes<HTMLAnchorElement>>;
13
12
 
14
13
  export { DynamicLink, type DynamicLinkProps, DynamicLink as default };
@@ -1,7 +1,7 @@
1
1
  "use client";
2
2
  import {
3
3
  Link
4
- } from "./chunk-XB7CNOKH.js";
4
+ } from "./chunk-UMTVJNLA.js";
5
5
  import {
6
6
  __objRest,
7
7
  __spreadValues
package/dist/link.d.ts CHANGED
@@ -1,24 +1,18 @@
1
1
  import * as react from 'react';
2
2
  import { AnchorHTMLAttributes } from 'react';
3
+ import { LinkProps as LinkProps$1 } from 'next/link';
3
4
 
4
- type LinkProps = AnchorHTMLAttributes<HTMLAnchorElement> & {
5
+ interface LinkProps extends Pick<LinkProps$1, 'prefetch' | 'replace'>, AnchorHTMLAttributes<HTMLAnchorElement> {
5
6
  /**
6
7
  * If the href is an external URL
7
8
  *
8
9
  * automatically determined by default
9
10
  */
10
11
  external?: boolean;
11
- };
12
+ }
12
13
  /**
13
- * Wraps `next/link` and safe to use in mdx documents
14
+ * Wraps `next/link` and safe to use in MDX documents
14
15
  */
15
- declare const Link: react.ForwardRefExoticComponent<AnchorHTMLAttributes<HTMLAnchorElement> & {
16
- /**
17
- * If the href is an external URL
18
- *
19
- * automatically determined by default
20
- */
21
- external?: boolean;
22
- } & react.RefAttributes<HTMLAnchorElement>>;
16
+ declare const Link: react.ForwardRefExoticComponent<LinkProps & react.RefAttributes<HTMLAnchorElement>>;
23
17
 
24
18
  export { type LinkProps, Link as default };
package/dist/link.js CHANGED
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  Link
3
- } from "./chunk-XB7CNOKH.js";
3
+ } from "./chunk-UMTVJNLA.js";
4
4
  import "./chunk-CWMXXUWU.js";
5
5
  export {
6
6
  Link as default
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "fumadocs-core",
3
- "version": "12.5.2",
3
+ "version": "12.5.3",
4
4
  "description": "The library for building a documentation website in Next.js",
5
5
  "keywords": [
6
6
  "NextJs",