@prismicio/next 2.3.3-pr.163.1cfdf21 → 2.3.3-pr.164.0cfb408

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.
Files changed (154) hide show
  1. package/dist/PrismicNextImage.d.cts +2 -3
  2. package/dist/PrismicNextImage.d.cts.map +1 -1
  3. package/dist/PrismicNextImage.d.ts +2 -3
  4. package/dist/PrismicNextImage.d.ts.map +1 -1
  5. package/dist/PrismicNextLink.d.cts +2 -3
  6. package/dist/PrismicNextLink.d.cts.map +1 -1
  7. package/dist/PrismicNextLink.d.ts +2 -3
  8. package/dist/PrismicNextLink.d.ts.map +1 -1
  9. package/dist/PrismicPreview.d.cts +2 -3
  10. package/dist/PrismicPreview.d.cts.map +1 -1
  11. package/dist/PrismicPreview.d.ts +2 -3
  12. package/dist/PrismicPreview.d.ts.map +1 -1
  13. package/dist/SliceSimulator.d.cts +3 -3
  14. package/dist/SliceSimulator.d.cts.map +1 -1
  15. package/dist/SliceSimulator.d.ts +3 -3
  16. package/dist/SliceSimulator.d.ts.map +1 -1
  17. package/dist/cacheTagPrismicPages.d.cts +1 -2
  18. package/dist/cacheTagPrismicPages.d.cts.map +1 -1
  19. package/dist/cacheTagPrismicPages.d.ts +1 -2
  20. package/dist/cacheTagPrismicPages.d.ts.map +1 -1
  21. package/dist/createLocaleRedirect.d.cts +2 -3
  22. package/dist/createLocaleRedirect.d.cts.map +1 -1
  23. package/dist/createLocaleRedirect.d.ts +2 -3
  24. package/dist/createLocaleRedirect.d.ts.map +1 -1
  25. package/dist/enableAutoPreviews.d.cts +2 -3
  26. package/dist/enableAutoPreviews.d.cts.map +1 -1
  27. package/dist/enableAutoPreviews.d.ts +2 -3
  28. package/dist/enableAutoPreviews.d.ts.map +1 -1
  29. package/dist/exitPreview.d.cts +1 -2
  30. package/dist/exitPreview.d.cts.map +1 -1
  31. package/dist/exitPreview.d.ts +1 -2
  32. package/dist/exitPreview.d.ts.map +1 -1
  33. package/dist/getPreviewRef.d.cts +1 -2
  34. package/dist/getPreviewRef.d.cts.map +1 -1
  35. package/dist/getPreviewRef.d.ts +1 -2
  36. package/dist/getPreviewRef.d.ts.map +1 -1
  37. package/dist/getPrismicCacheTags.d.cts +1 -2
  38. package/dist/getPrismicCacheTags.d.cts.map +1 -1
  39. package/dist/getPrismicCacheTags.d.ts +1 -2
  40. package/dist/getPrismicCacheTags.d.ts.map +1 -1
  41. package/dist/getSlices.d.cts +1 -2
  42. package/dist/getSlices.d.cts.map +1 -1
  43. package/dist/getSlices.d.ts +1 -2
  44. package/dist/getSlices.d.ts.map +1 -1
  45. package/dist/imgixLoader.d.cts +1 -2
  46. package/dist/imgixLoader.d.cts.map +1 -1
  47. package/dist/imgixLoader.d.ts +1 -2
  48. package/dist/imgixLoader.d.ts.map +1 -1
  49. package/dist/package.cjs +1 -1
  50. package/dist/package.js +1 -1
  51. package/dist/redirectToPreviewURL.d.cts +2 -3
  52. package/dist/redirectToPreviewURL.d.cts.map +1 -1
  53. package/dist/redirectToPreviewURL.d.ts +2 -3
  54. package/dist/redirectToPreviewURL.d.ts.map +1 -1
  55. package/dist/revalidatePrismicPages.d.cts +1 -2
  56. package/dist/revalidatePrismicPages.d.cts.map +1 -1
  57. package/dist/revalidatePrismicPages.d.ts +1 -2
  58. package/dist/revalidatePrismicPages.d.ts.map +1 -1
  59. package/dist/{pages → router-pages}/PrismicPreview.cjs +1 -1
  60. package/dist/router-pages/PrismicPreview.cjs.map +1 -0
  61. package/dist/{pages → router-pages}/PrismicPreview.d.cts +3 -4
  62. package/dist/router-pages/PrismicPreview.d.cts.map +1 -0
  63. package/dist/{pages → router-pages}/PrismicPreview.d.ts +3 -4
  64. package/dist/router-pages/PrismicPreview.d.ts.map +1 -0
  65. package/dist/{pages → router-pages}/PrismicPreview.js +1 -1
  66. package/dist/router-pages/PrismicPreview.js.map +1 -0
  67. package/dist/{pages → router-pages}/SliceSimulator.cjs +1 -1
  68. package/dist/router-pages/SliceSimulator.cjs.map +1 -0
  69. package/dist/{pages → router-pages}/SliceSimulator.d.cts +4 -4
  70. package/dist/router-pages/SliceSimulator.d.cts.map +1 -0
  71. package/dist/{pages → router-pages}/SliceSimulator.d.ts +4 -4
  72. package/dist/router-pages/SliceSimulator.d.ts.map +1 -0
  73. package/dist/{pages → router-pages}/SliceSimulator.js +1 -1
  74. package/dist/router-pages/SliceSimulator.js.map +1 -0
  75. package/dist/{pages → router-pages}/enableAutoPreviews.cjs +1 -1
  76. package/dist/router-pages/enableAutoPreviews.cjs.map +1 -0
  77. package/dist/{pages → router-pages}/enableAutoPreviews.d.cts +3 -4
  78. package/dist/router-pages/enableAutoPreviews.d.cts.map +1 -0
  79. package/dist/{pages → router-pages}/enableAutoPreviews.d.ts +3 -4
  80. package/dist/router-pages/enableAutoPreviews.d.ts.map +1 -0
  81. package/dist/{pages → router-pages}/enableAutoPreviews.js +1 -1
  82. package/dist/router-pages/enableAutoPreviews.js.map +1 -0
  83. package/dist/{pages → router-pages}/exitPreview.cjs +1 -1
  84. package/dist/router-pages/exitPreview.cjs.map +1 -0
  85. package/dist/{pages → router-pages}/exitPreview.d.cts +3 -4
  86. package/dist/router-pages/exitPreview.d.cts.map +1 -0
  87. package/dist/{pages → router-pages}/exitPreview.d.ts +3 -4
  88. package/dist/router-pages/exitPreview.d.ts.map +1 -0
  89. package/dist/{pages → router-pages}/exitPreview.js +1 -1
  90. package/dist/router-pages/exitPreview.js.map +1 -0
  91. package/dist/{pages → router-pages}/redirectToPreviewURL.cjs +1 -1
  92. package/dist/router-pages/redirectToPreviewURL.cjs.map +1 -0
  93. package/dist/{pages → router-pages}/redirectToPreviewURL.d.cts +3 -4
  94. package/dist/router-pages/redirectToPreviewURL.d.cts.map +1 -0
  95. package/dist/{pages → router-pages}/redirectToPreviewURL.d.ts +3 -4
  96. package/dist/router-pages/redirectToPreviewURL.d.ts.map +1 -0
  97. package/dist/{pages → router-pages}/redirectToPreviewURL.js +1 -1
  98. package/dist/router-pages/redirectToPreviewURL.js.map +1 -0
  99. package/dist/{pages → router-pages}/setPreviewData.cjs +1 -1
  100. package/dist/router-pages/setPreviewData.cjs.map +1 -0
  101. package/dist/{pages → router-pages}/setPreviewData.d.cts +3 -4
  102. package/dist/router-pages/setPreviewData.d.cts.map +1 -0
  103. package/dist/{pages → router-pages}/setPreviewData.d.ts +3 -4
  104. package/dist/router-pages/setPreviewData.d.ts.map +1 -0
  105. package/dist/{pages → router-pages}/setPreviewData.js +1 -1
  106. package/dist/router-pages/setPreviewData.js.map +1 -0
  107. package/dist/{pages → router-pages}/types.d.cts +4 -5
  108. package/dist/router-pages/types.d.cts.map +1 -0
  109. package/dist/{pages → router-pages}/types.d.ts +4 -5
  110. package/dist/router-pages/types.d.ts.map +1 -0
  111. package/dist/{pages.cjs → router-pages.cjs} +6 -6
  112. package/dist/{pages.d.cts → router-pages.d.cts} +7 -7
  113. package/dist/{pages.d.ts → router-pages.d.ts} +7 -7
  114. package/dist/router-pages.js +11 -0
  115. package/dist/types.d.cts +2 -3
  116. package/dist/types.d.cts.map +1 -1
  117. package/dist/types.d.ts +2 -3
  118. package/dist/types.d.ts.map +1 -1
  119. package/package.json +5 -4
  120. package/dist/pages/PrismicPreview.cjs.map +0 -1
  121. package/dist/pages/PrismicPreview.d.cts.map +0 -1
  122. package/dist/pages/PrismicPreview.d.ts.map +0 -1
  123. package/dist/pages/PrismicPreview.js.map +0 -1
  124. package/dist/pages/SliceSimulator.cjs.map +0 -1
  125. package/dist/pages/SliceSimulator.d.cts.map +0 -1
  126. package/dist/pages/SliceSimulator.d.ts.map +0 -1
  127. package/dist/pages/SliceSimulator.js.map +0 -1
  128. package/dist/pages/enableAutoPreviews.cjs.map +0 -1
  129. package/dist/pages/enableAutoPreviews.d.cts.map +0 -1
  130. package/dist/pages/enableAutoPreviews.d.ts.map +0 -1
  131. package/dist/pages/enableAutoPreviews.js.map +0 -1
  132. package/dist/pages/exitPreview.cjs.map +0 -1
  133. package/dist/pages/exitPreview.d.cts.map +0 -1
  134. package/dist/pages/exitPreview.d.ts.map +0 -1
  135. package/dist/pages/exitPreview.js.map +0 -1
  136. package/dist/pages/redirectToPreviewURL.cjs.map +0 -1
  137. package/dist/pages/redirectToPreviewURL.d.cts.map +0 -1
  138. package/dist/pages/redirectToPreviewURL.d.ts.map +0 -1
  139. package/dist/pages/redirectToPreviewURL.js.map +0 -1
  140. package/dist/pages/setPreviewData.cjs.map +0 -1
  141. package/dist/pages/setPreviewData.d.cts.map +0 -1
  142. package/dist/pages/setPreviewData.d.ts.map +0 -1
  143. package/dist/pages/setPreviewData.js.map +0 -1
  144. package/dist/pages/types.d.cts.map +0 -1
  145. package/dist/pages/types.d.ts.map +0 -1
  146. package/dist/pages.js +0 -11
  147. /package/src/{pages → router-pages}/PrismicPreview.tsx +0 -0
  148. /package/src/{pages → router-pages}/SliceSimulator.tsx +0 -0
  149. /package/src/{pages → router-pages}/enableAutoPreviews.ts +0 -0
  150. /package/src/{pages → router-pages}/exitPreview.ts +0 -0
  151. /package/src/{pages → router-pages}/index.ts +0 -0
  152. /package/src/{pages → router-pages}/redirectToPreviewURL.ts +0 -0
  153. /package/src/{pages → router-pages}/setPreviewData.ts +0 -0
  154. /package/src/{pages → router-pages}/types.ts +0 -0
@@ -3,7 +3,7 @@ import { ImageFieldImage } from "@prismicio/client";
3
3
  import { ImgixURLParams } from "imgix-url-builder";
4
4
  import { ImageProps } from "next/image.js";
5
5
  //#region src/PrismicNextImage.d.ts
6
- type PrismicNextImageProps = Omit<ImageProps, "src" | "alt" | "loader"> & {
6
+ export type PrismicNextImageProps = Omit<ImageProps, "src" | "alt" | "loader"> & {
7
7
  /** The Prismic Image field or thumbnail to render. */
8
8
  field: ImageFieldImage | null | undefined;
9
9
  /**
@@ -43,7 +43,6 @@ type PrismicNextImageProps = Omit<ImageProps, "src" | "alt" | "loader"> & {
43
43
  * field.
44
44
  * @see To learn more about `next/image`, see: https://nextjs.org/docs/api-reference/next/image
45
45
  */
46
- declare const PrismicNextImage: ForwardRefExoticComponent<PropsWithoutRef<PrismicNextImageProps> & RefAttributes<HTMLImageElement>>;
46
+ export declare const PrismicNextImage: ForwardRefExoticComponent<PropsWithoutRef<PrismicNextImageProps> & RefAttributes<HTMLImageElement>>;
47
47
  //#endregion
48
- export { PrismicNextImage, PrismicNextImageProps };
49
48
  //# sourceMappingURL=PrismicNextImage.d.cts.map
@@ -1 +1 @@
1
- {"version":3,"file":"PrismicNextImage.d.cts","names":[],"sources":["../src/PrismicNextImage.tsx"],"mappings":";;;;;KA+BY,wBAAwB,KAAK;;EAExC,OAAO;;;;;;EAOP,iBAAiB,WAAW,iBAAiB,eAAe;;;;;;EAO5D;;;;;;;EAQA;;EAGA,WAAW,MAAM;EAEjB,SAAS;;;;;;;;;;;;;;;;cAkBG,kBAAkB,0BAC9B,gBAAgB,yBAAyB,cAAc"}
1
+ {"version":3,"file":"PrismicNextImage.d.cts","names":[],"sources":["../src/PrismicNextImage.tsx"],"mappings":";;;;;YA+BY,wBAAwB,KAAK;;EAExC,OAAO;;;;;;EAOP,iBAAiB,WAAW,iBAAiB,eAAe;;;;;;EAO5D;;;;;;;EAQA;;EAGA,WAAW,MAAM;EAEjB,SAAS;;;;;;;;;;;;;;;;qBAkBG,kBAAkB,0BAC9B,gBAAgB,yBAAyB,cAAc"}
@@ -3,7 +3,7 @@ import { ForwardRefExoticComponent, PropsWithoutRef, RefAttributes } from "react
3
3
  import { ImgixURLParams } from "imgix-url-builder";
4
4
  import { ImageProps } from "next/image.js";
5
5
  //#region src/PrismicNextImage.d.ts
6
- type PrismicNextImageProps = Omit<ImageProps, "src" | "alt" | "loader"> & {
6
+ export type PrismicNextImageProps = Omit<ImageProps, "src" | "alt" | "loader"> & {
7
7
  /** The Prismic Image field or thumbnail to render. */
8
8
  field: ImageFieldImage | null | undefined;
9
9
  /**
@@ -43,7 +43,6 @@ type PrismicNextImageProps = Omit<ImageProps, "src" | "alt" | "loader"> & {
43
43
  * field.
44
44
  * @see To learn more about `next/image`, see: https://nextjs.org/docs/api-reference/next/image
45
45
  */
46
- declare const PrismicNextImage: ForwardRefExoticComponent<PropsWithoutRef<PrismicNextImageProps> & RefAttributes<HTMLImageElement>>;
46
+ export declare const PrismicNextImage: ForwardRefExoticComponent<PropsWithoutRef<PrismicNextImageProps> & RefAttributes<HTMLImageElement>>;
47
47
  //#endregion
48
- export { PrismicNextImage, PrismicNextImageProps };
49
48
  //# sourceMappingURL=PrismicNextImage.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"PrismicNextImage.d.ts","names":[],"sources":["../src/PrismicNextImage.tsx"],"mappings":";;;;;KA+BY,wBAAwB,KAAK;;EAExC,OAAO;;;;;;EAOP,iBAAiB,WAAW,iBAAiB,eAAe;;;;;;EAO5D;;;;;;;EAQA;;EAGA,WAAW,MAAM;EAEjB,SAAS;;;;;;;;;;;;;;;;cAkBG,kBAAkB,0BAC9B,gBAAgB,yBAAyB,cAAc"}
1
+ {"version":3,"file":"PrismicNextImage.d.ts","names":[],"sources":["../src/PrismicNextImage.tsx"],"mappings":";;;;;YA+BY,wBAAwB,KAAK;;EAExC,OAAO;;;;;;EAOP,iBAAiB,WAAW,iBAAiB,eAAe;;;;;;EAO5D;;;;;;;EAQA;;EAGA,WAAW,MAAM;EAEjB,SAAS;;;;;;;;;;;;;;;;qBAkBG,kBAAkB,0BAC9B,gBAAgB,yBAAyB,cAAc"}
@@ -2,7 +2,7 @@ import { ComponentProps } from "react";
2
2
  import { AsLinkAttrsConfig, LinkField, LinkResolverFunction, PrismicDocument } from "@prismicio/client";
3
3
  import Link from "next/link.js";
4
4
  //#region src/PrismicNextLink.d.ts
5
- type PrismicNextLinkProps = Omit<ComponentProps<typeof Link>, "field" | "document" | "href" | "rel"> & {
5
+ export type PrismicNextLinkProps = Omit<ComponentProps<typeof Link>, "field" | "document" | "href" | "rel"> & {
6
6
  linkResolver?: LinkResolverFunction;
7
7
  rel?: string | AsLinkAttrsConfig["rel"];
8
8
  } & ({
@@ -18,7 +18,7 @@ type PrismicNextLinkProps = Omit<ComponentProps<typeof Link>, "field" | "documen
18
18
  document?: never;
19
19
  href: ComponentProps<typeof Link>["href"];
20
20
  });
21
- declare const PrismicNextLink: import("react").ForwardRefExoticComponent<(Omit<Omit<Omit<import("react").AnchorHTMLAttributes<HTMLAnchorElement>, keyof import("next/link").LinkProps<any>> & import("next/link").LinkProps<any> & {
21
+ export declare const PrismicNextLink: import("react").ForwardRefExoticComponent<(Omit<Omit<Omit<import("react").AnchorHTMLAttributes<HTMLAnchorElement>, keyof import("next/link").LinkProps<any>> & import("next/link").LinkProps<any> & {
22
22
  children?: React.ReactNode | undefined;
23
23
  } & import("react").RefAttributes<HTMLAnchorElement>, "document" | "field" | "href" | "rel"> & {
24
24
  linkResolver?: LinkResolverFunction;
@@ -47,5 +47,4 @@ declare const PrismicNextLink: import("react").ForwardRefExoticComponent<(Omit<O
47
47
  href: ComponentProps<typeof Link>["href"];
48
48
  }, "ref">) & import("react").RefAttributes<HTMLAnchorElement>>;
49
49
  //#endregion
50
- export { PrismicNextLink, PrismicNextLinkProps };
51
50
  //# sourceMappingURL=PrismicNextLink.d.cts.map
@@ -1 +1 @@
1
- {"version":3,"file":"PrismicNextLink.d.cts","names":[],"sources":["../src/PrismicNextLink.tsx"],"mappings":";;;;KAeY,uBAAuB,KAClC,sBAAsB;EAGtB,eAAe;EACf,eAAe;;EAGZ,OAAO;EACP;EACA;;EAGA;EACA,UAAU;EACV;;EAGA;EACA;EACA,MAAM,sBAAsB;;cAInB,iCAAe,2BAAA,KAAA,KAAA,qBAAA,qBAAA,8CAAA,sCAAA;;;EApBZ,eAAA;EACT,eAAS;;EAGL,OAAA;EACI;EACJ;;;;;;;EAGC;EACE,UAAA;EACH;;;;;;;EAGC;EACG;EACL,MAAA,sBAAsB;6BA6B/B,cAAA"}
1
+ {"version":3,"file":"PrismicNextLink.d.cts","names":[],"sources":["../src/PrismicNextLink.tsx"],"mappings":";;;;YAeY,uBAAuB,KAClC,sBAAsB;EAGtB,eAAe;EACf,eAAe;;EAGZ,OAAO;EACP;EACA;;EAGA;EACA,UAAU;EACV;;EAGA;EACA;EACA,MAAM,sBAAsB;;qBAInB,iCAAe,2BAAA,KAAA,KAAA,qBAAA,qBAAA,8CAAA,sCAAA;;;EApBZ,eAAA;EACT,eAAS;;EAGL,OAAA;EACI;EACJ;;;;;;;EAGC;EACE,UAAA;EACH;;;;;;;EAGC;EACG;EACL,MAAA,sBAAsB;6BA6B/B,cAAA"}
@@ -2,7 +2,7 @@ import { AsLinkAttrsConfig, LinkField, LinkResolverFunction, PrismicDocument } f
2
2
  import { ComponentProps } from "react";
3
3
  import Link from "next/link.js";
4
4
  //#region src/PrismicNextLink.d.ts
5
- type PrismicNextLinkProps = Omit<ComponentProps<typeof Link>, "field" | "document" | "href" | "rel"> & {
5
+ export type PrismicNextLinkProps = Omit<ComponentProps<typeof Link>, "field" | "document" | "href" | "rel"> & {
6
6
  linkResolver?: LinkResolverFunction;
7
7
  rel?: string | AsLinkAttrsConfig["rel"];
8
8
  } & ({
@@ -18,7 +18,7 @@ type PrismicNextLinkProps = Omit<ComponentProps<typeof Link>, "field" | "documen
18
18
  document?: never;
19
19
  href: ComponentProps<typeof Link>["href"];
20
20
  });
21
- declare const PrismicNextLink: import("react").ForwardRefExoticComponent<(Omit<Omit<Omit<import("react").AnchorHTMLAttributes<HTMLAnchorElement>, keyof import("next/link").LinkProps<any>> & import("next/link").LinkProps<any> & {
21
+ export declare const PrismicNextLink: import("react").ForwardRefExoticComponent<(Omit<Omit<Omit<import("react").AnchorHTMLAttributes<HTMLAnchorElement>, keyof import("next/link").LinkProps<any>> & import("next/link").LinkProps<any> & {
22
22
  children?: React.ReactNode | undefined;
23
23
  } & import("react").RefAttributes<HTMLAnchorElement>, "document" | "field" | "href" | "rel"> & {
24
24
  linkResolver?: LinkResolverFunction;
@@ -47,5 +47,4 @@ declare const PrismicNextLink: import("react").ForwardRefExoticComponent<(Omit<O
47
47
  href: ComponentProps<typeof Link>["href"];
48
48
  }, "ref">) & import("react").RefAttributes<HTMLAnchorElement>>;
49
49
  //#endregion
50
- export { PrismicNextLink, PrismicNextLinkProps };
51
50
  //# sourceMappingURL=PrismicNextLink.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"PrismicNextLink.d.ts","names":[],"sources":["../src/PrismicNextLink.tsx"],"mappings":";;;;KAeY,uBAAuB,KAClC,sBAAsB;EAGtB,eAAe;EACf,eAAe;;EAGZ,OAAO;EACP;EACA;;EAGA;EACA,UAAU;EACV;;EAGA;EACA;EACA,MAAM,sBAAsB;;cAInB,iCAAe,2BAAA,KAAA,KAAA,qBAAA,qBAAA,8CAAA,sCAAA;;;EApBZ,eAAA;EACT,eAAS;;EAGL,OAAA;EACI;EACJ;;;;;;;EAGC;EACE,UAAA;EACH;;;;;;;EAGC;EACG;EACL,MAAA,sBAAsB;6BA6B/B,cAAA"}
1
+ {"version":3,"file":"PrismicNextLink.d.ts","names":[],"sources":["../src/PrismicNextLink.tsx"],"mappings":";;;;YAeY,uBAAuB,KAClC,sBAAsB;EAGtB,eAAe;EACf,eAAe;;EAGZ,OAAO;EACP;EACA;;EAGA;EACA,UAAU;EACV;;EAGA;EACA;EACA,MAAM,sBAAsB;;qBAInB,iCAAe,2BAAA,KAAA,KAAA,qBAAA,qBAAA,8CAAA,sCAAA;;;EApBZ,eAAA;EACT,eAAS;;EAGL,OAAA;EACI;EACJ;;;;;;;EAGC;EACE,UAAA;EACH;;;;;;;EAGC;EACG;EACL,MAAA,sBAAsB;6BA6B/B,cAAA"}
@@ -1,7 +1,7 @@
1
1
  import { FC, ReactNode } from "react";
2
2
  //#region src/PrismicPreview.d.ts
3
3
  /** Props for `<PrismicPreview>`. */
4
- type PrismicPreviewProps = {
4
+ export type PrismicPreviewProps = {
5
5
  /**
6
6
  * The name of your Prismic repository. A Prismic Toolbar will be registered using this
7
7
  * repository.
@@ -28,7 +28,6 @@ type PrismicPreviewProps = {
28
28
  * This component can be wrapped around your app or added anywhere in your app's tree. It must be
29
29
  * rendered on every page.
30
30
  */
31
- declare const PrismicPreview: FC<PrismicPreviewProps>;
31
+ export declare const PrismicPreview: FC<PrismicPreviewProps>;
32
32
  //#endregion
33
- export { PrismicPreview, PrismicPreviewProps };
34
33
  //# sourceMappingURL=PrismicPreview.d.cts.map
@@ -1 +1 @@
1
- {"version":3,"file":"PrismicPreview.d.cts","names":[],"sources":["../src/PrismicPreview.tsx"],"mappings":";;;KAUY;;;;;EAKX;;;;;EAMA;;;;;EAMA;;EAGA,WAAW;;;;;;;;;;cAWC,gBAAgB,GAAG"}
1
+ {"version":3,"file":"PrismicPreview.d.cts","names":[],"sources":["../src/PrismicPreview.tsx"],"mappings":";;;YAUY;;;;;EAKX;;;;;EAMA;;;;;EAMA;;EAGA,WAAW;;;;;;;;;;qBAWC,gBAAgB,GAAG"}
@@ -1,7 +1,7 @@
1
1
  import { FC, ReactNode } from "react";
2
2
  //#region src/PrismicPreview.d.ts
3
3
  /** Props for `<PrismicPreview>`. */
4
- type PrismicPreviewProps = {
4
+ export type PrismicPreviewProps = {
5
5
  /**
6
6
  * The name of your Prismic repository. A Prismic Toolbar will be registered using this
7
7
  * repository.
@@ -28,7 +28,6 @@ type PrismicPreviewProps = {
28
28
  * This component can be wrapped around your app or added anywhere in your app's tree. It must be
29
29
  * rendered on every page.
30
30
  */
31
- declare const PrismicPreview: FC<PrismicPreviewProps>;
31
+ export declare const PrismicPreview: FC<PrismicPreviewProps>;
32
32
  //#endregion
33
- export { PrismicPreview, PrismicPreviewProps };
34
33
  //# sourceMappingURL=PrismicPreview.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"PrismicPreview.d.ts","names":[],"sources":["../src/PrismicPreview.tsx"],"mappings":";;;KAUY;;;;;EAKX;;;;;EAMA;;;;;EAMA;;EAGA,WAAW;;;;;;;;;;cAWC,gBAAgB,GAAG"}
1
+ {"version":3,"file":"PrismicPreview.d.ts","names":[],"sources":["../src/PrismicPreview.tsx"],"mappings":";;;YAUY;;;;;EAKX;;;;;EAMA;;;;;EAMA;;EAGA,WAAW;;;;;;;;;;qBAWC,gBAAgB,GAAG"}
@@ -2,7 +2,7 @@ import { FC, ReactNode } from "react";
2
2
  import { SliceSimulatorProps } from "@prismicio/simulator/kit";
3
3
  //#region src/SliceSimulator.d.ts
4
4
  /** Parameters provided to the Slice Simulator page. */
5
- type SliceSimulatorParams = {
5
+ export type SliceSimulatorParams = {
6
6
  searchParams: Promise<{
7
7
  state?: string;
8
8
  }>;
@@ -15,7 +15,7 @@ type SliceSimulatorProps$1 = SliceSimulatorProps & {
15
15
  * Simulate slices in isolation. The slice simulator enables live slice development in Slice Machine
16
16
  * and live previews in the Page Builder.
17
17
  */
18
- declare const SliceSimulator: FC<SliceSimulatorProps$1>;
18
+ export declare const SliceSimulator: FC<SliceSimulatorProps$1>;
19
19
  //#endregion
20
- export { SliceSimulator, SliceSimulatorParams, SliceSimulatorProps$1 as SliceSimulatorProps };
20
+ export { SliceSimulatorProps$1 as SliceSimulatorProps };
21
21
  //# sourceMappingURL=SliceSimulator.d.cts.map
@@ -1 +1 @@
1
- {"version":3,"file":"SliceSimulator.d.cts","names":[],"sources":["../src/SliceSimulator.tsx"],"mappings":";;;;KAiBY;EACX,cAAc;IACb;;;KAIU,wBAAsB;EACjC,UAAU;EACV;;;;;;cAOY,gBAAgB,GAAG"}
1
+ {"version":3,"file":"SliceSimulator.d.cts","names":[],"sources":["../src/SliceSimulator.tsx"],"mappings":";;;;YAiBY;EACX,cAAc;IACb;;;KAIU,wBAAsB;EACjC,UAAU;EACV;;;;;;qBAOY,gBAAgB,GAAG"}
@@ -2,7 +2,7 @@ import { FC, ReactNode } from "react";
2
2
  import { SliceSimulatorProps } from "@prismicio/simulator/kit";
3
3
  //#region src/SliceSimulator.d.ts
4
4
  /** Parameters provided to the Slice Simulator page. */
5
- type SliceSimulatorParams = {
5
+ export type SliceSimulatorParams = {
6
6
  searchParams: Promise<{
7
7
  state?: string;
8
8
  }>;
@@ -15,7 +15,7 @@ type SliceSimulatorProps$1 = SliceSimulatorProps & {
15
15
  * Simulate slices in isolation. The slice simulator enables live slice development in Slice Machine
16
16
  * and live previews in the Page Builder.
17
17
  */
18
- declare const SliceSimulator: FC<SliceSimulatorProps$1>;
18
+ export declare const SliceSimulator: FC<SliceSimulatorProps$1>;
19
19
  //#endregion
20
- export { SliceSimulator, SliceSimulatorParams, SliceSimulatorProps$1 as SliceSimulatorProps };
20
+ export { SliceSimulatorProps$1 as SliceSimulatorProps };
21
21
  //# sourceMappingURL=SliceSimulator.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"SliceSimulator.d.ts","names":[],"sources":["../src/SliceSimulator.tsx"],"mappings":";;;;KAiBY;EACX,cAAc;IACb;;;KAIU,wBAAsB;EACjC,UAAU;EACV;;;;;;cAOY,gBAAgB,GAAG"}
1
+ {"version":3,"file":"SliceSimulator.d.ts","names":[],"sources":["../src/SliceSimulator.tsx"],"mappings":";;;;YAiBY;EACX,cAAc;IACb;;;KAIU,wBAAsB;EACjC,UAAU;EACV;;;;;;qBAOY,gBAAgB,GAAG"}
@@ -12,7 +12,6 @@ import { PrismicDocument } from "@prismicio/client";
12
12
  *
13
13
  * @see {@link https://nextjs.org/docs/app/api-reference/functions/cacheTag}
14
14
  */
15
- declare function cacheTagPrismicPages(pages: PrismicDocument[]): void;
15
+ export declare function cacheTagPrismicPages(pages: PrismicDocument[]): void;
16
16
  //#endregion
17
- export { cacheTagPrismicPages };
18
17
  //# sourceMappingURL=cacheTagPrismicPages.d.cts.map
@@ -1 +1 @@
1
- {"version":3,"file":"cacheTagPrismicPages.d.cts","names":[],"sources":["../src/cacheTagPrismicPages.ts"],"mappings":";;;;;;;;;;;;;;iBAkBgB,qBAAqB,OAAO"}
1
+ {"version":3,"file":"cacheTagPrismicPages.d.cts","names":[],"sources":["../src/cacheTagPrismicPages.ts"],"mappings":";;;;;;;;;;;;;;wBAkBgB,qBAAqB,OAAO"}
@@ -12,7 +12,6 @@ import { PrismicDocument } from "@prismicio/client";
12
12
  *
13
13
  * @see {@link https://nextjs.org/docs/app/api-reference/functions/cacheTag}
14
14
  */
15
- declare function cacheTagPrismicPages(pages: PrismicDocument[]): void;
15
+ export declare function cacheTagPrismicPages(pages: PrismicDocument[]): void;
16
16
  //#endregion
17
- export { cacheTagPrismicPages };
18
17
  //# sourceMappingURL=cacheTagPrismicPages.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"cacheTagPrismicPages.d.ts","names":[],"sources":["../src/cacheTagPrismicPages.ts"],"mappings":";;;;;;;;;;;;;;iBAkBgB,qBAAqB,OAAO"}
1
+ {"version":3,"file":"cacheTagPrismicPages.d.ts","names":[],"sources":["../src/cacheTagPrismicPages.ts"],"mappings":";;;;;;;;;;;;;;wBAkBgB,qBAAqB,OAAO"}
@@ -3,12 +3,11 @@
3
3
  * @deprecated `createLocaleRedirect()` has been removed due to performance
4
4
  * issues.
5
5
  */
6
- declare function createLocaleRedirect(): never;
6
+ export declare function createLocaleRedirect(): never;
7
7
  /**
8
8
  * @deprecated `createLocaleRedirect()` has been removed due to performance
9
9
  * issues.
10
10
  */
11
- type CreateLocaleRedirectConfig = never;
11
+ export type CreateLocaleRedirectConfig = never;
12
12
  //#endregion
13
- export { CreateLocaleRedirectConfig, createLocaleRedirect };
14
13
  //# sourceMappingURL=createLocaleRedirect.d.cts.map
@@ -1 +1 @@
1
- {"version":3,"file":"createLocaleRedirect.d.cts","names":[],"sources":["../src/createLocaleRedirect.ts"],"mappings":";;;;;iBAMgB;;;;;KAWJ"}
1
+ {"version":3,"file":"createLocaleRedirect.d.cts","names":[],"sources":["../src/createLocaleRedirect.ts"],"mappings":";;;;;wBAMgB;;;;;YAWJ"}
@@ -3,12 +3,11 @@
3
3
  * @deprecated `createLocaleRedirect()` has been removed due to performance
4
4
  * issues.
5
5
  */
6
- declare function createLocaleRedirect(): never;
6
+ export declare function createLocaleRedirect(): never;
7
7
  /**
8
8
  * @deprecated `createLocaleRedirect()` has been removed due to performance
9
9
  * issues.
10
10
  */
11
- type CreateLocaleRedirectConfig = never;
11
+ export type CreateLocaleRedirectConfig = never;
12
12
  //#endregion
13
- export { CreateLocaleRedirectConfig, createLocaleRedirect };
14
13
  //# sourceMappingURL=createLocaleRedirect.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"createLocaleRedirect.d.ts","names":[],"sources":["../src/createLocaleRedirect.ts"],"mappings":";;;;;iBAMgB;;;;;KAWJ"}
1
+ {"version":3,"file":"createLocaleRedirect.d.ts","names":[],"sources":["../src/createLocaleRedirect.ts"],"mappings":";;;;;wBAMgB;;;;;YAWJ"}
@@ -1,7 +1,7 @@
1
1
  import { Client } from "@prismicio/client";
2
2
  //#region src/enableAutoPreviews.d.ts
3
3
  /** Configuration for `enableAutoPreviews`. */
4
- type EnableAutoPreviewsConfig = {
4
+ export type EnableAutoPreviewsConfig = {
5
5
  /** Prismic client with which automatic previews will be enabled. */
6
6
  client: Pick<Client, "queryContentFromRef" | "enableAutoPreviewsFromReq">;
7
7
  };
@@ -10,7 +10,6 @@ type EnableAutoPreviewsConfig = {
10
10
  *
11
11
  * @param config - Configuration for the function.
12
12
  */
13
- declare function enableAutoPreviews(config: EnableAutoPreviewsConfig): void;
13
+ export declare function enableAutoPreviews(config: EnableAutoPreviewsConfig): void;
14
14
  //#endregion
15
- export { EnableAutoPreviewsConfig, enableAutoPreviews };
16
15
  //# sourceMappingURL=enableAutoPreviews.d.cts.map
@@ -1 +1 @@
1
- {"version":3,"file":"enableAutoPreviews.d.cts","names":[],"sources":["../src/enableAutoPreviews.ts"],"mappings":";;;KAKY;;EAKX,QAAQ,KAAK;;;;;;;iBAQE,mBAAmB,QAAQ"}
1
+ {"version":3,"file":"enableAutoPreviews.d.cts","names":[],"sources":["../src/enableAutoPreviews.ts"],"mappings":";;;YAKY;;EAKX,QAAQ,KAAK;;;;;;;wBAQE,mBAAmB,QAAQ"}
@@ -1,7 +1,7 @@
1
1
  import { Client } from "@prismicio/client";
2
2
  //#region src/enableAutoPreviews.d.ts
3
3
  /** Configuration for `enableAutoPreviews`. */
4
- type EnableAutoPreviewsConfig = {
4
+ export type EnableAutoPreviewsConfig = {
5
5
  /** Prismic client with which automatic previews will be enabled. */
6
6
  client: Pick<Client, "queryContentFromRef" | "enableAutoPreviewsFromReq">;
7
7
  };
@@ -10,7 +10,6 @@ type EnableAutoPreviewsConfig = {
10
10
  *
11
11
  * @param config - Configuration for the function.
12
12
  */
13
- declare function enableAutoPreviews(config: EnableAutoPreviewsConfig): void;
13
+ export declare function enableAutoPreviews(config: EnableAutoPreviewsConfig): void;
14
14
  //#endregion
15
- export { EnableAutoPreviewsConfig, enableAutoPreviews };
16
15
  //# sourceMappingURL=enableAutoPreviews.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"enableAutoPreviews.d.ts","names":[],"sources":["../src/enableAutoPreviews.ts"],"mappings":";;;KAKY;;EAKX,QAAQ,KAAK;;;;;;;iBAQE,mBAAmB,QAAQ"}
1
+ {"version":3,"file":"enableAutoPreviews.d.ts","names":[],"sources":["../src/enableAutoPreviews.ts"],"mappings":";;;YAKY;;EAKX,QAAQ,KAAK;;;;;;;wBAQE,mBAAmB,QAAQ"}
@@ -14,7 +14,6 @@
14
14
  * }
15
15
  * ```
16
16
  */
17
- declare function exitPreview(): Promise<Response>;
17
+ export declare function exitPreview(): Promise<Response>;
18
18
  //#endregion
19
- export { exitPreview };
20
19
  //# sourceMappingURL=exitPreview.d.cts.map
@@ -1 +1 @@
1
- {"version":3,"file":"exitPreview.d.cts","names":[],"sources":["../src/exitPreview.ts"],"mappings":";;;;;;;;;;;;;;;;iBAiBsB,eAAe,QAAQ"}
1
+ {"version":3,"file":"exitPreview.d.cts","names":[],"sources":["../src/exitPreview.ts"],"mappings":";;;;;;;;;;;;;;;;wBAiBsB,eAAe,QAAQ"}
@@ -14,7 +14,6 @@
14
14
  * }
15
15
  * ```
16
16
  */
17
- declare function exitPreview(): Promise<Response>;
17
+ export declare function exitPreview(): Promise<Response>;
18
18
  //#endregion
19
- export { exitPreview };
20
19
  //# sourceMappingURL=exitPreview.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"exitPreview.d.ts","names":[],"sources":["../src/exitPreview.ts"],"mappings":";;;;;;;;;;;;;;;;iBAiBsB,eAAe,QAAQ"}
1
+ {"version":3,"file":"exitPreview.d.ts","names":[],"sources":["../src/exitPreview.ts"],"mappings":";;;;;;;;;;;;;;;;wBAiBsB,eAAe,QAAQ"}
@@ -16,7 +16,6 @@
16
16
  * @returns The active preview ref, or `undefined` if no preview session is active.
17
17
  * @experimental
18
18
  */
19
- declare function getPreviewRef(): Promise<string | undefined>;
19
+ export declare function getPreviewRef(): Promise<string | undefined>;
20
20
  //#endregion
21
- export { getPreviewRef };
22
21
  //# sourceMappingURL=getPreviewRef.d.cts.map
@@ -1 +1 @@
1
- {"version":3,"file":"getPreviewRef.d.cts","names":[],"sources":["../src/getPreviewRef.ts"],"mappings":";;;;;;;;;;;;;;;;;;iBAmBsB,iBAAiB"}
1
+ {"version":3,"file":"getPreviewRef.d.cts","names":[],"sources":["../src/getPreviewRef.ts"],"mappings":";;;;;;;;;;;;;;;;;;wBAmBsB,iBAAiB"}
@@ -16,7 +16,6 @@
16
16
  * @returns The active preview ref, or `undefined` if no preview session is active.
17
17
  * @experimental
18
18
  */
19
- declare function getPreviewRef(): Promise<string | undefined>;
19
+ export declare function getPreviewRef(): Promise<string | undefined>;
20
20
  //#endregion
21
- export { getPreviewRef };
22
21
  //# sourceMappingURL=getPreviewRef.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"getPreviewRef.d.ts","names":[],"sources":["../src/getPreviewRef.ts"],"mappings":";;;;;;;;;;;;;;;;;;iBAmBsB,iBAAiB"}
1
+ {"version":3,"file":"getPreviewRef.d.ts","names":[],"sources":["../src/getPreviewRef.ts"],"mappings":";;;;;;;;;;;;;;;;;;wBAmBsB,iBAAiB"}
@@ -9,7 +9,6 @@ import { PrismicDocument } from "@prismicio/client";
9
9
  *
10
10
  * @see {@link https://nextjs.org/docs/app/api-reference/functions/cacheTag}
11
11
  */
12
- declare function getPrismicCacheTags(pages: PrismicDocument[]): string[];
12
+ export declare function getPrismicCacheTags(pages: PrismicDocument[]): string[];
13
13
  //#endregion
14
- export { getPrismicCacheTags };
15
14
  //# sourceMappingURL=getPrismicCacheTags.d.cts.map
@@ -1 +1 @@
1
- {"version":3,"file":"getPrismicCacheTags.d.cts","names":[],"sources":["../src/getPrismicCacheTags.ts"],"mappings":";;;;;;;;;;;iBAagB,oBAAoB,OAAO"}
1
+ {"version":3,"file":"getPrismicCacheTags.d.cts","names":[],"sources":["../src/getPrismicCacheTags.ts"],"mappings":";;;;;;;;;;;wBAagB,oBAAoB,OAAO"}
@@ -9,7 +9,6 @@ import { PrismicDocument } from "@prismicio/client";
9
9
  *
10
10
  * @see {@link https://nextjs.org/docs/app/api-reference/functions/cacheTag}
11
11
  */
12
- declare function getPrismicCacheTags(pages: PrismicDocument[]): string[];
12
+ export declare function getPrismicCacheTags(pages: PrismicDocument[]): string[];
13
13
  //#endregion
14
- export { getPrismicCacheTags };
15
14
  //# sourceMappingURL=getPrismicCacheTags.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"getPrismicCacheTags.d.ts","names":[],"sources":["../src/getPrismicCacheTags.ts"],"mappings":";;;;;;;;;;;iBAagB,oBAAoB,OAAO"}
1
+ {"version":3,"file":"getPrismicCacheTags.d.ts","names":[],"sources":["../src/getPrismicCacheTags.ts"],"mappings":";;;;;;;;;;;wBAagB,oBAAoB,OAAO"}
@@ -1,6 +1,5 @@
1
1
  import { StateEventType, StateEvents } from "@prismicio/simulator/kit";
2
2
  //#region src/getSlices.d.ts
3
- declare const getSlices: (state: string | null | undefined) => StateEvents[StateEventType.Slices];
3
+ export declare const getSlices: (state: string | null | undefined) => StateEvents[StateEventType.Slices];
4
4
  //#endregion
5
- export { getSlices };
6
5
  //# sourceMappingURL=getSlices.d.cts.map
@@ -1 +1 @@
1
- {"version":3,"file":"getSlices.d.cts","names":[],"sources":["../src/getSlices.ts"],"mappings":";;cAIa,YAAS,qCAAuC,YAAY,eAAe"}
1
+ {"version":3,"file":"getSlices.d.cts","names":[],"sources":["../src/getSlices.ts"],"mappings":";;qBAIa,YAAS,qCAAuC,YAAY,eAAe"}
@@ -1,6 +1,5 @@
1
1
  import { StateEventType, StateEvents } from "@prismicio/simulator/kit";
2
2
  //#region src/getSlices.d.ts
3
- declare const getSlices: (state: string | null | undefined) => StateEvents[StateEventType.Slices];
3
+ export declare const getSlices: (state: string | null | undefined) => StateEvents[StateEventType.Slices];
4
4
  //#endregion
5
- export { getSlices };
6
5
  //# sourceMappingURL=getSlices.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"getSlices.d.ts","names":[],"sources":["../src/getSlices.ts"],"mappings":";;cAIa,YAAS,qCAAuC,YAAY,eAAe"}
1
+ {"version":3,"file":"getSlices.d.ts","names":[],"sources":["../src/getSlices.ts"],"mappings":";;qBAIa,YAAS,qCAAuC,YAAY,eAAe"}
@@ -7,7 +7,6 @@ import { ImageLoaderProps } from "next/image.js";
7
7
  * @see To learn about `next/image` loaders: https://nextjs.org/docs/api-reference/next/image#loader
8
8
  * @see To learn about Imgix's URL API: https://docs.imgix.com/apis/rendering
9
9
  */
10
- declare const imgixLoader: (args: ImageLoaderProps) => string;
10
+ export declare const imgixLoader: (args: ImageLoaderProps) => string;
11
11
  //#endregion
12
- export { imgixLoader };
13
12
  //# sourceMappingURL=imgixLoader.d.cts.map
@@ -1 +1 @@
1
- {"version":3,"file":"imgixLoader.d.cts","names":[],"sources":["../src/imgixLoader.ts"],"mappings":";;;;;;;;;cAWa,cAAW,MAAU"}
1
+ {"version":3,"file":"imgixLoader.d.cts","names":[],"sources":["../src/imgixLoader.ts"],"mappings":";;;;;;;;;qBAWa,cAAW,MAAU"}
@@ -7,7 +7,6 @@ import { ImageLoaderProps } from "next/image.js";
7
7
  * @see To learn about `next/image` loaders: https://nextjs.org/docs/api-reference/next/image#loader
8
8
  * @see To learn about Imgix's URL API: https://docs.imgix.com/apis/rendering
9
9
  */
10
- declare const imgixLoader: (args: ImageLoaderProps) => string;
10
+ export declare const imgixLoader: (args: ImageLoaderProps) => string;
11
11
  //#endregion
12
- export { imgixLoader };
13
12
  //# sourceMappingURL=imgixLoader.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"imgixLoader.d.ts","names":[],"sources":["../src/imgixLoader.ts"],"mappings":";;;;;;;;;cAWa,cAAW,MAAU"}
1
+ {"version":3,"file":"imgixLoader.d.ts","names":[],"sources":["../src/imgixLoader.ts"],"mappings":";;;;;;;;;qBAWa,cAAW,MAAU"}
package/dist/package.cjs CHANGED
@@ -1,5 +1,5 @@
1
1
  //#region package.json
2
- var version = "2.3.3-pr.163.1cfdf21";
2
+ var version = "2.3.3-pr.164.0cfb408";
3
3
  //#endregion
4
4
  Object.defineProperty(exports, "version", {
5
5
  enumerable: true,
package/dist/package.js CHANGED
@@ -1,5 +1,5 @@
1
1
  //#region package.json
2
- var version = "2.3.3-pr.163.1cfdf21";
2
+ var version = "2.3.3-pr.164.0cfb408";
3
3
  //#endregion
4
4
  export { version };
5
5
 
@@ -1,7 +1,7 @@
1
1
  import { NextRequestLike } from "./types.cjs";
2
2
  import { Client, LinkResolverFunction } from "@prismicio/client";
3
3
  //#region src/redirectToPreviewURL.d.ts
4
- type RedirectToPreviewURLConfig = {
4
+ export type RedirectToPreviewURLConfig = {
5
5
  /** The Prismic client configured for the preview session's repository. */
6
6
  client: Pick<Client, "resolvePreviewURL">;
7
7
  /**
@@ -24,7 +24,6 @@ type RedirectToPreviewURLConfig = {
24
24
  */
25
25
  defaultURL?: string;
26
26
  };
27
- declare function redirectToPreviewURL(config: RedirectToPreviewURLConfig): Promise<never>;
27
+ export declare function redirectToPreviewURL(config: RedirectToPreviewURLConfig): Promise<never>;
28
28
  //#endregion
29
- export { RedirectToPreviewURLConfig, redirectToPreviewURL };
30
29
  //# sourceMappingURL=redirectToPreviewURL.d.cts.map
@@ -1 +1 @@
1
- {"version":3,"file":"redirectToPreviewURL.d.cts","names":[],"sources":["../src/redirectToPreviewURL.ts"],"mappings":";;;KAIY;;EAKX,QAAQ,KAAK;;;;;;EAOb,SAAS;;;;;;EAOT,eAAe;;;;;;;EAQf;;iBAGqB,qBAAqB,QAAQ,6BAA6B"}
1
+ {"version":3,"file":"redirectToPreviewURL.d.cts","names":[],"sources":["../src/redirectToPreviewURL.ts"],"mappings":";;;YAIY;;EAKX,QAAQ,KAAK;;;;;;EAOb,SAAS;;;;;;EAOT,eAAe;;;;;;;EAQf;;wBAGqB,qBAAqB,QAAQ,6BAA6B"}
@@ -1,7 +1,7 @@
1
1
  import { NextRequestLike } from "./types.js";
2
2
  import { Client, LinkResolverFunction } from "@prismicio/client";
3
3
  //#region src/redirectToPreviewURL.d.ts
4
- type RedirectToPreviewURLConfig = {
4
+ export type RedirectToPreviewURLConfig = {
5
5
  /** The Prismic client configured for the preview session's repository. */
6
6
  client: Pick<Client, "resolvePreviewURL">;
7
7
  /**
@@ -24,7 +24,6 @@ type RedirectToPreviewURLConfig = {
24
24
  */
25
25
  defaultURL?: string;
26
26
  };
27
- declare function redirectToPreviewURL(config: RedirectToPreviewURLConfig): Promise<never>;
27
+ export declare function redirectToPreviewURL(config: RedirectToPreviewURLConfig): Promise<never>;
28
28
  //#endregion
29
- export { RedirectToPreviewURLConfig, redirectToPreviewURL };
30
29
  //# sourceMappingURL=redirectToPreviewURL.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"redirectToPreviewURL.d.ts","names":[],"sources":["../src/redirectToPreviewURL.ts"],"mappings":";;;KAIY;;EAKX,QAAQ,KAAK;;;;;;EAOb,SAAS;;;;;;EAOT,eAAe;;;;;;;EAQf;;iBAGqB,qBAAqB,QAAQ,6BAA6B"}
1
+ {"version":3,"file":"redirectToPreviewURL.d.ts","names":[],"sources":["../src/redirectToPreviewURL.ts"],"mappings":";;;YAIY;;EAKX,QAAQ,KAAK;;;;;;EAOb,SAAS;;;;;;EAOT,eAAe;;;;;;;EAQf;;wBAGqB,qBAAqB,QAAQ,6BAA6B"}
@@ -8,7 +8,6 @@
8
8
  *
9
9
  * @see {@link https://nextjs.org/docs/app/api-reference/functions/revalidateTag}
10
10
  */
11
- declare function revalidatePrismicPages(ids: string[]): void;
11
+ export declare function revalidatePrismicPages(ids: string[]): void;
12
12
  //#endregion
13
- export { revalidatePrismicPages };
14
13
  //# sourceMappingURL=revalidatePrismicPages.d.cts.map
@@ -1 +1 @@
1
- {"version":3,"file":"revalidatePrismicPages.d.cts","names":[],"sources":["../src/revalidatePrismicPages.ts"],"mappings":";;;;;;;;;;iBAagB,uBAAuB"}
1
+ {"version":3,"file":"revalidatePrismicPages.d.cts","names":[],"sources":["../src/revalidatePrismicPages.ts"],"mappings":";;;;;;;;;;wBAagB,uBAAuB"}
@@ -8,7 +8,6 @@
8
8
  *
9
9
  * @see {@link https://nextjs.org/docs/app/api-reference/functions/revalidateTag}
10
10
  */
11
- declare function revalidatePrismicPages(ids: string[]): void;
11
+ export declare function revalidatePrismicPages(ids: string[]): void;
12
12
  //#endregion
13
- export { revalidatePrismicPages };
14
13
  //# sourceMappingURL=revalidatePrismicPages.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"revalidatePrismicPages.d.ts","names":[],"sources":["../src/revalidatePrismicPages.ts"],"mappings":";;;;;;;;;;iBAagB,uBAAuB"}
1
+ {"version":3,"file":"revalidatePrismicPages.d.ts","names":[],"sources":["../src/revalidatePrismicPages.ts"],"mappings":";;;;;;;;;;wBAagB,uBAAuB"}
@@ -5,7 +5,7 @@ next_script_js = require_runtime.__toESM(next_script_js, 1);
5
5
  let react = require("react");
6
6
  let react_jsx_runtime = require("react/jsx-runtime");
7
7
  let next_router_js = require("next/router.js");
8
- //#region src/pages/PrismicPreview.tsx
8
+ //#region src/router-pages/PrismicPreview.tsx
9
9
  /**
10
10
  * React component that sets up Prismic Previews using the Prismic Toolbar. When the Prismic Toolbar
11
11
  * send events to the browser, such as on preview updates and exiting, this component will
@@ -0,0 +1 @@
1
+ {"version":3,"file":"PrismicPreview.cjs","names":["useRouter","getToolbarSrc","Script","prismicCookie"],"sources":["../../src/router-pages/PrismicPreview.tsx"],"sourcesContent":["import { getToolbarSrc, cookie as prismicCookie } from \"@prismicio/client\"\nimport { useRouter } from \"next/router\"\nimport Script from \"next/script\"\nimport type { FC } from \"react\"\nimport { type ReactNode, useEffect } from \"react\"\n\n/** Props for `<PrismicPreview>`. */\nexport type PrismicPreviewProps = {\n\t/**\n\t * The name of your Prismic repository. A Prismic Toolbar will be registered using this\n\t * repository.\n\t */\n\trepositoryName: string\n\n\t/**\n\t * The URL of your app's Prismic preview endpoint (default: `/api/preview`). This URL will be\n\t * fetched on preview update events.\n\t */\n\tupdatePreviewURL?: string\n\n\t/**\n\t * The URL of your app's exit preview endpoint (default: `/api/exit-preview`). This URL will be\n\t * fetched on preview exit events.\n\t */\n\texitPreviewURL?: string\n\n\t/** Children to render adjacent to the Prismic Toolbar. */\n\tchildren?: ReactNode\n}\n\n/**\n * React component that sets up Prismic Previews using the Prismic Toolbar. When the Prismic Toolbar\n * send events to the browser, such as on preview updates and exiting, this component will\n * automatically refresh the page with the changes.\n *\n * This component can be wrapped around your app or added anywhere in your app's tree. It must be\n * rendered on every page.\n */\nexport const PrismicPreview: FC<PrismicPreviewProps> = (props) => {\n\tconst {\n\t\trepositoryName,\n\t\tupdatePreviewURL = \"/api/preview\",\n\t\texitPreviewURL = \"/api/exit-preview\",\n\t\tchildren,\n\t} = props\n\n\tconst router = useRouter()\n\n\tconst toolbarSrc = getToolbarSrc(repositoryName)\n\n\tuseEffect(() => {\n\t\tconst controller = new AbortController()\n\n\t\twindow.addEventListener(\"prismicPreviewUpdate\", onUpdate, {\n\t\t\tsignal: controller.signal,\n\t\t})\n\t\twindow.addEventListener(\"prismicPreviewEnd\", onEnd, {\n\t\t\tsignal: controller.signal,\n\t\t})\n\n\t\t// Start the preview for preview share links. Previews from\n\t\t// share links do not go to the `updatePreviewURL` like a normal\n\t\t// preview.\n\t\t//\n\t\t// We check that the current URL is a descendant of the base\n\t\t// path to prevent infinite refrehes.\n\t\tif (\n\t\t\twindow.location.href.startsWith(window.location.origin + router.basePath) &&\n\t\t\tgetPreviewCookieRepositoryName() === repositoryName &&\n\t\t\t!router.isPreview\n\t\t) {\n\t\t\tstart()\n\t\t}\n\n\t\tfunction onEnd(event: Event) {\n\t\t\tevent.preventDefault()\n\t\t\tfetch(router.basePath + exitPreviewURL, { signal: controller.signal })\n\t\t\t\t.then((res) => {\n\t\t\t\t\tif (!res.ok) {\n\t\t\t\t\t\tconsole.error(\n\t\t\t\t\t\t\t`[<PrismicPreview>] Failed to exit Preview Mode using the \"${exitPreviewURL}\" API endpoint. Does it exist?`,\n\t\t\t\t\t\t)\n\n\t\t\t\t\t\treturn\n\t\t\t\t\t}\n\n\t\t\t\t\trefresh()\n\t\t\t\t})\n\t\t\t\t.catch(() => {})\n\t\t}\n\n\t\tfunction onUpdate(event: Event) {\n\t\t\tevent.preventDefault()\n\t\t\tstart()\n\t\t}\n\n\t\tfunction start() {\n\t\t\t// We check `opaqueredirect` because we don't care if\n\t\t\t// the redirect was successful or not. As long as it\n\t\t\t// redirects, we know the endpoint exists and at least\n\t\t\t// attempted to set preview data.\n\t\t\tfetch(router.basePath + updatePreviewURL, {\n\t\t\t\tredirect: \"manual\",\n\t\t\t\tsignal: controller.signal,\n\t\t\t})\n\t\t\t\t.then((res) => {\n\t\t\t\t\tif (res.type !== \"opaqueredirect\") {\n\t\t\t\t\t\tconsole.error(\n\t\t\t\t\t\t\t`[<PrismicPreview>] Failed to start or update the preview using \"${updatePreviewURL}\". Does it exist?`,\n\t\t\t\t\t\t)\n\n\t\t\t\t\t\treturn\n\t\t\t\t\t}\n\n\t\t\t\t\trefresh()\n\t\t\t\t})\n\t\t\t\t.catch(() => {})\n\t\t}\n\n\t\tfunction refresh() {\n\t\t\trouter.replace(router.asPath, undefined, { scroll: false })\n\t\t}\n\n\t\treturn () => controller.abort()\n\t}, [exitPreviewURL, updatePreviewURL, repositoryName, router])\n\n\treturn (\n\t\t<>\n\t\t\t{children}\n\t\t\t<Script src={toolbarSrc} strategy=\"lazyOnload\" />\n\t\t</>\n\t)\n}\n\nfunction getPreviewCookieRepositoryName() {\n\tconst cookie = window.document.cookie\n\t\t.split(\"; \")\n\t\t.find((row) => row.startsWith(`${prismicCookie.preview}=`))\n\t\t?.split(\"=\")[1]\n\n\treturn (decodeURIComponent(cookie ?? \"\").match(/\"([^\"]+)\\.prismic\\.io\"/) || [])[1]\n}\n"],"mappings":";;;;;;;;;;;;;;;;AAsCA,MAAa,kBAA2C,UAAU;CACjE,MAAM,EACL,gBACA,mBAAmB,gBACnB,iBAAiB,qBACjB,aACG;CAEJ,MAAM,UAAA,GAASA,eAAAA,UAAAA,CAAU;CAEzB,MAAM,cAAA,GAAaC,kBAAAA,cAAAA,CAAc,cAAc;CAE/C,CAAA,GAAA,MAAA,UAAA,OAAgB;EACf,MAAM,aAAa,IAAI,gBAAgB;EAEvC,OAAO,iBAAiB,wBAAwB,UAAU,EACzD,QAAQ,WAAW,OACpB,CAAC;EACD,OAAO,iBAAiB,qBAAqB,OAAO,EACnD,QAAQ,WAAW,OACpB,CAAC;EAQD,IACC,OAAO,SAAS,KAAK,WAAW,OAAO,SAAS,SAAS,OAAO,QAAQ,KACxE,+BAA+B,MAAM,kBACrC,CAAC,OAAO,WAER,MAAM;EAGP,SAAS,MAAM,OAAc;GAC5B,MAAM,eAAe;GACrB,MAAM,OAAO,WAAW,gBAAgB,EAAE,QAAQ,WAAW,OAAO,CAAC,CAAC,CACpE,MAAM,QAAQ;IACd,IAAI,CAAC,IAAI,IAAI;KACZ,QAAQ,MACP,6DAA6D,eAAe,+BAC7E;KAEA;IACD;IAEA,QAAQ;GACT,CAAC,CAAC,CACD,YAAY,CAAC,CAAC;EACjB;EAEA,SAAS,SAAS,OAAc;GAC/B,MAAM,eAAe;GACrB,MAAM;EACP;EAEA,SAAS,QAAQ;GAKhB,MAAM,OAAO,WAAW,kBAAkB;IACzC,UAAU;IACV,QAAQ,WAAW;GACpB,CAAC,CAAC,CACA,MAAM,QAAQ;IACd,IAAI,IAAI,SAAS,kBAAkB;KAClC,QAAQ,MACP,mEAAmE,iBAAiB,kBACrF;KAEA;IACD;IAEA,QAAQ;GACT,CAAC,CAAC,CACD,YAAY,CAAC,CAAC;EACjB;EAEA,SAAS,UAAU;GAClB,OAAO,QAAQ,OAAO,QAAQ,KAAA,GAAW,EAAE,QAAQ,MAAM,CAAC;EAC3D;EAEA,aAAa,WAAW,MAAM;CAC/B,GAAG;EAAC;EAAgB;EAAkB;EAAgB;CAAM,CAAC;CAE7D,OACC,iBAAA,GAAA,kBAAA,KAAA,CAAA,kBAAA,UAAA,EAAA,UAAA,CACE,UACD,iBAAA,GAAA,kBAAA,IAAA,CAACC,eAAAA,SAAD;EAAQ,KAAK;EAAY,UAAS;CAAc,CAAA,CAC/C,EAAA,CAAA;AAEJ;AAEA,SAAS,iCAAiC;CACzC,MAAM,SAAS,OAAO,SAAS,OAC7B,MAAM,IAAI,CAAC,CACX,MAAM,QAAQ,IAAI,WAAW,GAAGC,kBAAAA,OAAc,QAAQ,EAAE,CAAC,CAAC,EACzD,MAAM,GAAG,CAAC,CAAC;CAEd,QAAQ,mBAAmB,UAAU,EAAE,CAAC,CAAC,MAAM,wBAAwB,KAAK,CAAC,EAAA,CAAG;AACjF"}