@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.
- package/dist/PrismicNextImage.d.cts +2 -3
- package/dist/PrismicNextImage.d.cts.map +1 -1
- package/dist/PrismicNextImage.d.ts +2 -3
- package/dist/PrismicNextImage.d.ts.map +1 -1
- package/dist/PrismicNextLink.d.cts +2 -3
- package/dist/PrismicNextLink.d.cts.map +1 -1
- package/dist/PrismicNextLink.d.ts +2 -3
- package/dist/PrismicNextLink.d.ts.map +1 -1
- package/dist/PrismicPreview.d.cts +2 -3
- package/dist/PrismicPreview.d.cts.map +1 -1
- package/dist/PrismicPreview.d.ts +2 -3
- package/dist/PrismicPreview.d.ts.map +1 -1
- package/dist/SliceSimulator.d.cts +3 -3
- package/dist/SliceSimulator.d.cts.map +1 -1
- package/dist/SliceSimulator.d.ts +3 -3
- package/dist/SliceSimulator.d.ts.map +1 -1
- package/dist/cacheTagPrismicPages.d.cts +1 -2
- package/dist/cacheTagPrismicPages.d.cts.map +1 -1
- package/dist/cacheTagPrismicPages.d.ts +1 -2
- package/dist/cacheTagPrismicPages.d.ts.map +1 -1
- package/dist/createLocaleRedirect.d.cts +2 -3
- package/dist/createLocaleRedirect.d.cts.map +1 -1
- package/dist/createLocaleRedirect.d.ts +2 -3
- package/dist/createLocaleRedirect.d.ts.map +1 -1
- package/dist/enableAutoPreviews.d.cts +2 -3
- package/dist/enableAutoPreviews.d.cts.map +1 -1
- package/dist/enableAutoPreviews.d.ts +2 -3
- package/dist/enableAutoPreviews.d.ts.map +1 -1
- package/dist/exitPreview.d.cts +1 -2
- package/dist/exitPreview.d.cts.map +1 -1
- package/dist/exitPreview.d.ts +1 -2
- package/dist/exitPreview.d.ts.map +1 -1
- package/dist/getPreviewRef.d.cts +1 -2
- package/dist/getPreviewRef.d.cts.map +1 -1
- package/dist/getPreviewRef.d.ts +1 -2
- package/dist/getPreviewRef.d.ts.map +1 -1
- package/dist/getPrismicCacheTags.d.cts +1 -2
- package/dist/getPrismicCacheTags.d.cts.map +1 -1
- package/dist/getPrismicCacheTags.d.ts +1 -2
- package/dist/getPrismicCacheTags.d.ts.map +1 -1
- package/dist/getSlices.d.cts +1 -2
- package/dist/getSlices.d.cts.map +1 -1
- package/dist/getSlices.d.ts +1 -2
- package/dist/getSlices.d.ts.map +1 -1
- package/dist/imgixLoader.d.cts +1 -2
- package/dist/imgixLoader.d.cts.map +1 -1
- package/dist/imgixLoader.d.ts +1 -2
- package/dist/imgixLoader.d.ts.map +1 -1
- package/dist/package.cjs +1 -1
- package/dist/package.js +1 -1
- package/dist/redirectToPreviewURL.d.cts +2 -3
- package/dist/redirectToPreviewURL.d.cts.map +1 -1
- package/dist/redirectToPreviewURL.d.ts +2 -3
- package/dist/redirectToPreviewURL.d.ts.map +1 -1
- package/dist/revalidatePrismicPages.d.cts +1 -2
- package/dist/revalidatePrismicPages.d.cts.map +1 -1
- package/dist/revalidatePrismicPages.d.ts +1 -2
- package/dist/revalidatePrismicPages.d.ts.map +1 -1
- package/dist/{pages → router-pages}/PrismicPreview.cjs +1 -1
- package/dist/router-pages/PrismicPreview.cjs.map +1 -0
- package/dist/{pages → router-pages}/PrismicPreview.d.cts +3 -4
- package/dist/router-pages/PrismicPreview.d.cts.map +1 -0
- package/dist/{pages → router-pages}/PrismicPreview.d.ts +3 -4
- package/dist/router-pages/PrismicPreview.d.ts.map +1 -0
- package/dist/{pages → router-pages}/PrismicPreview.js +1 -1
- package/dist/router-pages/PrismicPreview.js.map +1 -0
- package/dist/{pages → router-pages}/SliceSimulator.cjs +1 -1
- package/dist/router-pages/SliceSimulator.cjs.map +1 -0
- package/dist/{pages → router-pages}/SliceSimulator.d.cts +4 -4
- package/dist/router-pages/SliceSimulator.d.cts.map +1 -0
- package/dist/{pages → router-pages}/SliceSimulator.d.ts +4 -4
- package/dist/router-pages/SliceSimulator.d.ts.map +1 -0
- package/dist/{pages → router-pages}/SliceSimulator.js +1 -1
- package/dist/router-pages/SliceSimulator.js.map +1 -0
- package/dist/{pages → router-pages}/enableAutoPreviews.cjs +1 -1
- package/dist/router-pages/enableAutoPreviews.cjs.map +1 -0
- package/dist/{pages → router-pages}/enableAutoPreviews.d.cts +3 -4
- package/dist/router-pages/enableAutoPreviews.d.cts.map +1 -0
- package/dist/{pages → router-pages}/enableAutoPreviews.d.ts +3 -4
- package/dist/router-pages/enableAutoPreviews.d.ts.map +1 -0
- package/dist/{pages → router-pages}/enableAutoPreviews.js +1 -1
- package/dist/router-pages/enableAutoPreviews.js.map +1 -0
- package/dist/{pages → router-pages}/exitPreview.cjs +1 -1
- package/dist/router-pages/exitPreview.cjs.map +1 -0
- package/dist/{pages → router-pages}/exitPreview.d.cts +3 -4
- package/dist/router-pages/exitPreview.d.cts.map +1 -0
- package/dist/{pages → router-pages}/exitPreview.d.ts +3 -4
- package/dist/router-pages/exitPreview.d.ts.map +1 -0
- package/dist/{pages → router-pages}/exitPreview.js +1 -1
- package/dist/router-pages/exitPreview.js.map +1 -0
- package/dist/{pages → router-pages}/redirectToPreviewURL.cjs +1 -1
- package/dist/router-pages/redirectToPreviewURL.cjs.map +1 -0
- package/dist/{pages → router-pages}/redirectToPreviewURL.d.cts +3 -4
- package/dist/router-pages/redirectToPreviewURL.d.cts.map +1 -0
- package/dist/{pages → router-pages}/redirectToPreviewURL.d.ts +3 -4
- package/dist/router-pages/redirectToPreviewURL.d.ts.map +1 -0
- package/dist/{pages → router-pages}/redirectToPreviewURL.js +1 -1
- package/dist/router-pages/redirectToPreviewURL.js.map +1 -0
- package/dist/{pages → router-pages}/setPreviewData.cjs +1 -1
- package/dist/router-pages/setPreviewData.cjs.map +1 -0
- package/dist/{pages → router-pages}/setPreviewData.d.cts +3 -4
- package/dist/router-pages/setPreviewData.d.cts.map +1 -0
- package/dist/{pages → router-pages}/setPreviewData.d.ts +3 -4
- package/dist/router-pages/setPreviewData.d.ts.map +1 -0
- package/dist/{pages → router-pages}/setPreviewData.js +1 -1
- package/dist/router-pages/setPreviewData.js.map +1 -0
- package/dist/{pages → router-pages}/types.d.cts +4 -5
- package/dist/router-pages/types.d.cts.map +1 -0
- package/dist/{pages → router-pages}/types.d.ts +4 -5
- package/dist/router-pages/types.d.ts.map +1 -0
- package/dist/{pages.cjs → router-pages.cjs} +6 -6
- package/dist/{pages.d.cts → router-pages.d.cts} +7 -7
- package/dist/{pages.d.ts → router-pages.d.ts} +7 -7
- package/dist/router-pages.js +11 -0
- package/dist/types.d.cts +2 -3
- package/dist/types.d.cts.map +1 -1
- package/dist/types.d.ts +2 -3
- package/dist/types.d.ts.map +1 -1
- package/package.json +5 -4
- package/dist/pages/PrismicPreview.cjs.map +0 -1
- package/dist/pages/PrismicPreview.d.cts.map +0 -1
- package/dist/pages/PrismicPreview.d.ts.map +0 -1
- package/dist/pages/PrismicPreview.js.map +0 -1
- package/dist/pages/SliceSimulator.cjs.map +0 -1
- package/dist/pages/SliceSimulator.d.cts.map +0 -1
- package/dist/pages/SliceSimulator.d.ts.map +0 -1
- package/dist/pages/SliceSimulator.js.map +0 -1
- package/dist/pages/enableAutoPreviews.cjs.map +0 -1
- package/dist/pages/enableAutoPreviews.d.cts.map +0 -1
- package/dist/pages/enableAutoPreviews.d.ts.map +0 -1
- package/dist/pages/enableAutoPreviews.js.map +0 -1
- package/dist/pages/exitPreview.cjs.map +0 -1
- package/dist/pages/exitPreview.d.cts.map +0 -1
- package/dist/pages/exitPreview.d.ts.map +0 -1
- package/dist/pages/exitPreview.js.map +0 -1
- package/dist/pages/redirectToPreviewURL.cjs.map +0 -1
- package/dist/pages/redirectToPreviewURL.d.cts.map +0 -1
- package/dist/pages/redirectToPreviewURL.d.ts.map +0 -1
- package/dist/pages/redirectToPreviewURL.js.map +0 -1
- package/dist/pages/setPreviewData.cjs.map +0 -1
- package/dist/pages/setPreviewData.d.cts.map +0 -1
- package/dist/pages/setPreviewData.d.ts.map +0 -1
- package/dist/pages/setPreviewData.js.map +0 -1
- package/dist/pages/types.d.cts.map +0 -1
- package/dist/pages/types.d.ts.map +0 -1
- package/dist/pages.js +0 -11
- /package/src/{pages → router-pages}/PrismicPreview.tsx +0 -0
- /package/src/{pages → router-pages}/SliceSimulator.tsx +0 -0
- /package/src/{pages → router-pages}/enableAutoPreviews.ts +0 -0
- /package/src/{pages → router-pages}/exitPreview.ts +0 -0
- /package/src/{pages → router-pages}/index.ts +0 -0
- /package/src/{pages → router-pages}/redirectToPreviewURL.ts +0 -0
- /package/src/{pages → router-pages}/setPreviewData.ts +0 -0
- /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":";;;;;
|
|
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":";;;;;
|
|
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":";;;;
|
|
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":";;;;
|
|
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":";;;
|
|
1
|
+
{"version":3,"file":"PrismicPreview.d.cts","names":[],"sources":["../src/PrismicPreview.tsx"],"mappings":";;;YAUY;;;;;EAKX;;;;;EAMA;;;;;EAMA;;EAGA,WAAW;;;;;;;;;;qBAWC,gBAAgB,GAAG"}
|
package/dist/PrismicPreview.d.ts
CHANGED
|
@@ -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":";;;
|
|
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 {
|
|
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":";;;;
|
|
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"}
|
package/dist/SliceSimulator.d.ts
CHANGED
|
@@ -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 {
|
|
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":";;;;
|
|
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":";;;;;;;;;;;;;;
|
|
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":";;;;;;;;;;;;;;
|
|
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":";;;;;
|
|
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":";;;;;
|
|
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":";;;
|
|
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":";;;
|
|
1
|
+
{"version":3,"file":"enableAutoPreviews.d.ts","names":[],"sources":["../src/enableAutoPreviews.ts"],"mappings":";;;YAKY;;EAKX,QAAQ,KAAK;;;;;;;wBAQE,mBAAmB,QAAQ"}
|
package/dist/exitPreview.d.cts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"exitPreview.d.cts","names":[],"sources":["../src/exitPreview.ts"],"mappings":";;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"exitPreview.d.cts","names":[],"sources":["../src/exitPreview.ts"],"mappings":";;;;;;;;;;;;;;;;wBAiBsB,eAAe,QAAQ"}
|
package/dist/exitPreview.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"exitPreview.d.ts","names":[],"sources":["../src/exitPreview.ts"],"mappings":";;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"exitPreview.d.ts","names":[],"sources":["../src/exitPreview.ts"],"mappings":";;;;;;;;;;;;;;;;wBAiBsB,eAAe,QAAQ"}
|
package/dist/getPreviewRef.d.cts
CHANGED
|
@@ -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":";;;;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"getPreviewRef.d.cts","names":[],"sources":["../src/getPreviewRef.ts"],"mappings":";;;;;;;;;;;;;;;;;;wBAmBsB,iBAAiB"}
|
package/dist/getPreviewRef.d.ts
CHANGED
|
@@ -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":";;;;;;;;;;;;;;;;;;
|
|
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":";;;;;;;;;;;
|
|
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":";;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"getPrismicCacheTags.d.ts","names":[],"sources":["../src/getPrismicCacheTags.ts"],"mappings":";;;;;;;;;;;wBAagB,oBAAoB,OAAO"}
|
package/dist/getSlices.d.cts
CHANGED
|
@@ -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
|
package/dist/getSlices.d.cts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getSlices.d.cts","names":[],"sources":["../src/getSlices.ts"],"mappings":";;
|
|
1
|
+
{"version":3,"file":"getSlices.d.cts","names":[],"sources":["../src/getSlices.ts"],"mappings":";;qBAIa,YAAS,qCAAuC,YAAY,eAAe"}
|
package/dist/getSlices.d.ts
CHANGED
|
@@ -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
|
package/dist/getSlices.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getSlices.d.ts","names":[],"sources":["../src/getSlices.ts"],"mappings":";;
|
|
1
|
+
{"version":3,"file":"getSlices.d.ts","names":[],"sources":["../src/getSlices.ts"],"mappings":";;qBAIa,YAAS,qCAAuC,YAAY,eAAe"}
|
package/dist/imgixLoader.d.cts
CHANGED
|
@@ -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":";;;;;;;;;
|
|
1
|
+
{"version":3,"file":"imgixLoader.d.cts","names":[],"sources":["../src/imgixLoader.ts"],"mappings":";;;;;;;;;qBAWa,cAAW,MAAU"}
|
package/dist/imgixLoader.d.ts
CHANGED
|
@@ -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":";;;;;;;;;
|
|
1
|
+
{"version":3,"file":"imgixLoader.d.ts","names":[],"sources":["../src/imgixLoader.ts"],"mappings":";;;;;;;;;qBAWa,cAAW,MAAU"}
|
package/dist/package.cjs
CHANGED
package/dist/package.js
CHANGED
|
@@ -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":";;;
|
|
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":";;;
|
|
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":";;;;;;;;;;
|
|
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":";;;;;;;;;;
|
|
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"}
|