@prismicio/vue 5.3.0-canary.320f423 → 5.3.0-canary.553482e

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 (74) hide show
  1. package/dist/PrismicImage.vue.d.cts +4 -4
  2. package/dist/PrismicLink.vue.d.cts +4 -4
  3. package/dist/PrismicRichText/PrismicRichText.vue.d.cts +6 -10
  4. package/dist/PrismicRichText/PrismicRichText.vue.d.cts.map +1 -1
  5. package/dist/PrismicRichText/types.d.cts +25 -26
  6. package/dist/PrismicRichText/types.d.cts.map +1 -1
  7. package/dist/PrismicTable/PrismicTable.vue.d.cts +2 -6
  8. package/dist/PrismicTable/PrismicTable.vue.d.cts.map +1 -1
  9. package/dist/PrismicTable/types.d.cts +7 -8
  10. package/dist/PrismicTable/types.d.cts.map +1 -1
  11. package/dist/PrismicText.vue.d.cts +2 -2
  12. package/dist/PrismicText.vue.d.cts.map +1 -1
  13. package/dist/SliceZone/SliceZone.vue.d.cts +2 -2
  14. package/dist/SliceZone/SliceZone.vue.d.cts.map +1 -1
  15. package/dist/package.cjs +1 -1
  16. package/dist/package.cjs.map +1 -1
  17. package/dist/package.js +1 -1
  18. package/dist/package.js.map +1 -1
  19. package/dist/src/PrismicImage.vue.d.ts +4 -4
  20. package/dist/src/PrismicLink.vue.d.ts +4 -4
  21. package/dist/src/PrismicLink.vue.d.ts.map +1 -1
  22. package/dist/src/PrismicRichText/PrismicRichText.cjs.map +1 -1
  23. package/dist/src/PrismicRichText/PrismicRichText.js.map +1 -1
  24. package/dist/src/PrismicRichText/PrismicRichText.vue.d.ts +6 -10
  25. package/dist/src/PrismicRichText/PrismicRichText.vue.d.ts.map +1 -1
  26. package/dist/src/PrismicRichText/PrismicRichText.vue_vue_type_script_setup_true_lang.cjs +2 -4
  27. package/dist/src/PrismicRichText/PrismicRichText.vue_vue_type_script_setup_true_lang.cjs.map +1 -1
  28. package/dist/src/PrismicRichText/PrismicRichText.vue_vue_type_script_setup_true_lang.js +2 -4
  29. package/dist/src/PrismicRichText/PrismicRichText.vue_vue_type_script_setup_true_lang.js.map +1 -1
  30. package/dist/src/PrismicRichText/PrismicRichTextDefaultComponent.cjs.map +1 -1
  31. package/dist/src/PrismicRichText/PrismicRichTextDefaultComponent.js.map +1 -1
  32. package/dist/src/PrismicRichText/PrismicRichTextDefaultComponent.vue_vue_type_script_setup_true_lang.cjs +2 -2
  33. package/dist/src/PrismicRichText/PrismicRichTextDefaultComponent.vue_vue_type_script_setup_true_lang.cjs.map +1 -1
  34. package/dist/src/PrismicRichText/PrismicRichTextDefaultComponent.vue_vue_type_script_setup_true_lang.js +2 -2
  35. package/dist/src/PrismicRichText/PrismicRichTextDefaultComponent.vue_vue_type_script_setup_true_lang.js.map +1 -1
  36. package/dist/src/PrismicRichText/PrismicRichTextSerialize.cjs.map +1 -1
  37. package/dist/src/PrismicRichText/PrismicRichTextSerialize.js.map +1 -1
  38. package/dist/src/PrismicRichText/PrismicRichTextSerialize.vue_vue_type_script_setup_true_lang.cjs +10 -4
  39. package/dist/src/PrismicRichText/PrismicRichTextSerialize.vue_vue_type_script_setup_true_lang.cjs.map +1 -1
  40. package/dist/src/PrismicRichText/PrismicRichTextSerialize.vue_vue_type_script_setup_true_lang.js +11 -5
  41. package/dist/src/PrismicRichText/PrismicRichTextSerialize.vue_vue_type_script_setup_true_lang.js.map +1 -1
  42. package/dist/src/PrismicRichText/types.d.ts +25 -26
  43. package/dist/src/PrismicRichText/types.d.ts.map +1 -1
  44. package/dist/src/PrismicTable/PrismicTable.cjs.map +1 -1
  45. package/dist/src/PrismicTable/PrismicTable.js.map +1 -1
  46. package/dist/src/PrismicTable/PrismicTable.vue.d.ts +4 -8
  47. package/dist/src/PrismicTable/PrismicTable.vue.d.ts.map +1 -1
  48. package/dist/src/PrismicTable/PrismicTable.vue_vue_type_script_setup_true_lang.cjs +8 -8
  49. package/dist/src/PrismicTable/PrismicTable.vue_vue_type_script_setup_true_lang.cjs.map +1 -1
  50. package/dist/src/PrismicTable/PrismicTable.vue_vue_type_script_setup_true_lang.js +8 -8
  51. package/dist/src/PrismicTable/PrismicTable.vue_vue_type_script_setup_true_lang.js.map +1 -1
  52. package/dist/src/PrismicTable/PrismicTableDefaultComponents.cjs +12 -30
  53. package/dist/src/PrismicTable/PrismicTableDefaultComponents.cjs.map +1 -1
  54. package/dist/src/PrismicTable/PrismicTableDefaultComponents.js +12 -30
  55. package/dist/src/PrismicTable/PrismicTableDefaultComponents.js.map +1 -1
  56. package/dist/src/PrismicTable/types.d.ts +7 -8
  57. package/dist/src/PrismicTable/types.d.ts.map +1 -1
  58. package/dist/src/PrismicText.vue.d.ts +2 -2
  59. package/dist/src/SliceZone/SliceZone.vue.d.ts +2 -2
  60. package/dist/src/types.cjs.map +1 -1
  61. package/dist/src/types.d.ts +11 -1
  62. package/dist/src/types.d.ts.map +1 -1
  63. package/dist/src/types.js.map +1 -1
  64. package/dist/types.d.cts +11 -1
  65. package/dist/types.d.cts.map +1 -1
  66. package/package.json +1 -3
  67. package/src/PrismicRichText/PrismicRichText.vue +13 -15
  68. package/src/PrismicRichText/PrismicRichTextDefaultComponent.vue +8 -4
  69. package/src/PrismicRichText/PrismicRichTextSerialize.vue +4 -3
  70. package/src/PrismicRichText/types.ts +57 -29
  71. package/src/PrismicTable/PrismicTable.vue +14 -18
  72. package/src/PrismicTable/PrismicTableDefaultComponents.ts +14 -39
  73. package/src/PrismicTable/types.ts +41 -23
  74. package/src/types.ts +13 -1
@@ -1,4 +1,4 @@
1
- import * as vue16 from "vue";
1
+ import * as vue21 from "vue";
2
2
  import { ImageField, asImagePixelDensitySrcSet, asImageSrc, asImageWidthSrcSet } from "@prismicio/client";
3
3
 
4
4
  //#region src/PrismicImage.vue.d.ts
@@ -64,7 +64,7 @@ type PrismicImageProps = {
64
64
  */
65
65
  pixelDensities: NonNullable<Parameters<typeof asImagePixelDensitySrcSet>[1]>["pixelDensities"] | "defaults";
66
66
  });
67
- declare const __VLS_export: vue16.DefineComponent<({
67
+ declare const __VLS_export: vue21.DefineComponent<({
68
68
  /** The Prismic image field or thumbnail to render. */
69
69
  field: ImageField | ImageField<string>;
70
70
  /**
@@ -162,7 +162,7 @@ declare const __VLS_export: vue16.DefineComponent<({
162
162
  * densities will be used: 1, 2, 3.
163
163
  */
164
164
  pixelDensities: NonNullable<Parameters<typeof asImagePixelDensitySrcSet>[1]>["pixelDensities"] | "defaults";
165
- }), {}, {}, {}, {}, vue16.ComponentOptionsMixin, vue16.ComponentOptionsMixin, {}, string, vue16.PublicProps, Readonly<({
165
+ }), {}, {}, {}, {}, vue21.ComponentOptionsMixin, vue21.ComponentOptionsMixin, {}, string, vue21.PublicProps, Readonly<({
166
166
  /** The Prismic image field or thumbnail to render. */
167
167
  field: ImageField | ImageField<string>;
168
168
  /**
@@ -260,7 +260,7 @@ declare const __VLS_export: vue16.DefineComponent<({
260
260
  * densities will be used: 1, 2, 3.
261
261
  */
262
262
  pixelDensities: NonNullable<Parameters<typeof asImagePixelDensitySrcSet>[1]>["pixelDensities"] | "defaults";
263
- })> & Readonly<{}>, {}, {}, {}, {}, string, vue16.ComponentProvideOptions, false, {}, any>;
263
+ })> & Readonly<{}>, {}, {}, {}, {}, string, vue21.ComponentProvideOptions, false, {}, any>;
264
264
  declare const _default: typeof __VLS_export;
265
265
  //#endregion
266
266
  export { PrismicImageProps, _default };
@@ -1,5 +1,5 @@
1
1
  import { ComponentOrTagName } from "./types.cjs";
2
- import * as vue11 from "vue";
2
+ import * as vue26 from "vue";
3
3
  import { AsLinkAttrsConfig, LinkField, LinkResolverFunction, PrismicDocument } from "@prismicio/client";
4
4
 
5
5
  //#region src/PrismicLink.vue.d.ts
@@ -49,7 +49,7 @@ declare var __VLS_8: {};
49
49
  type __VLS_Slots = {} & {
50
50
  default?: (props: typeof __VLS_8) => any;
51
51
  };
52
- declare const __VLS_base: vue11.DefineComponent<({
52
+ declare const __VLS_base: vue26.DefineComponent<({
53
53
  /**
54
54
  * The link resolver used to resolve links.
55
55
  *
@@ -121,7 +121,7 @@ declare const __VLS_base: vue11.DefineComponent<({
121
121
  /** The Prismic document to render as a link. */
122
122
  document: PrismicDocument;
123
123
  field?: never;
124
- }), {}, {}, {}, {}, vue11.ComponentOptionsMixin, vue11.ComponentOptionsMixin, {}, string, vue11.PublicProps, Readonly<({
124
+ }), {}, {}, {}, {}, vue26.ComponentOptionsMixin, vue26.ComponentOptionsMixin, {}, string, vue26.PublicProps, Readonly<({
125
125
  /**
126
126
  * The link resolver used to resolve links.
127
127
  *
@@ -193,7 +193,7 @@ declare const __VLS_base: vue11.DefineComponent<({
193
193
  /** The Prismic document to render as a link. */
194
194
  document: PrismicDocument;
195
195
  field?: never;
196
- })> & Readonly<{}>, {}, {}, {}, {}, string, vue11.ComponentProvideOptions, false, {}, any>;
196
+ })> & Readonly<{}>, {}, {}, {}, {}, string, vue26.ComponentProvideOptions, false, {}, any>;
197
197
  declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
198
198
  declare const _default: typeof __VLS_export;
199
199
  type __VLS_WithSlots<T, S> = T & {
@@ -1,17 +1,13 @@
1
1
  import { ComponentOrTagName } from "../types.cjs";
2
2
  import { VueRichTextSerializer } from "./types.cjs";
3
- import * as vue4 from "vue";
3
+ import * as vue14 from "vue";
4
4
  import { PropType } from "vue";
5
5
  import { LinkResolverFunction, RichTextField } from "@prismicio/client";
6
6
 
7
7
  //#region src/PrismicRichText/PrismicRichText.vue.d.ts
8
- /**
9
- * Props for `<PrismicRichText />`.
10
- */
8
+ /** Props for `<PrismicRichText />`. */
11
9
  type PrismicRichTextProps = {
12
- /**
13
- * The Prismic rich text field to render.
14
- */
10
+ /** The Prismic rich text field to render. */
15
11
  field: RichTextField | null | undefined;
16
12
  /**
17
13
  * The link resolver used to resolve links.
@@ -44,7 +40,7 @@ type PrismicRichTextProps = {
44
40
  */
45
41
  fallback?: ComponentOrTagName;
46
42
  };
47
- declare const __VLS_export: vue4.DefineComponent<vue4.ExtractPropTypes<{
43
+ declare const __VLS_export: vue14.DefineComponent<vue14.ExtractPropTypes<{
48
44
  field: {
49
45
  type: PropType<PrismicRichTextProps["field"]>;
50
46
  };
@@ -57,7 +53,7 @@ declare const __VLS_export: vue4.DefineComponent<vue4.ExtractPropTypes<{
57
53
  fallback: {
58
54
  type: PropType<PrismicRichTextProps["fallback"]>;
59
55
  };
60
- }>, {}, {}, {}, {}, vue4.ComponentOptionsMixin, vue4.ComponentOptionsMixin, {}, string, vue4.PublicProps, Readonly<vue4.ExtractPropTypes<{
56
+ }>, {}, {}, {}, {}, vue14.ComponentOptionsMixin, vue14.ComponentOptionsMixin, {}, string, vue14.PublicProps, Readonly<vue14.ExtractPropTypes<{
61
57
  field: {
62
58
  type: PropType<PrismicRichTextProps["field"]>;
63
59
  };
@@ -70,7 +66,7 @@ declare const __VLS_export: vue4.DefineComponent<vue4.ExtractPropTypes<{
70
66
  fallback: {
71
67
  type: PropType<PrismicRichTextProps["fallback"]>;
72
68
  };
73
- }>> & Readonly<{}>, {}, {}, {}, {}, string, vue4.ComponentProvideOptions, true, {}, any>;
69
+ }>> & Readonly<{}>, {}, {}, {}, {}, string, vue14.ComponentProvideOptions, true, {}, any>;
74
70
  declare const _default: typeof __VLS_export;
75
71
  //#endregion
76
72
  export { PrismicRichTextProps, _default };
@@ -1 +1 @@
1
- {"version":3,"file":"PrismicRichText.vue.d.cts","names":[],"sources":["../../src/PrismicRichText/PrismicRichText.vue"],"sourcesContent":[],"mappings":";;;;;;;;;;AAgKY,KAAA,oBAAA,GAAoB;EAIxB;;;EAiCI,KAAA,EAjCJ,aAiCI,GAAA,IAAA,GAAA,SAAA;EAAkB;AAC7B;;;;;;;;EA2HqC,YAAA,CAAA,EAlJtB,oBAkJsB;EAAQ;;;;;;;;;;;;;;eAlIhC;;;;AAsHI;aAhHN;;cAgHN,mBAAY,gBAY4B,IAAA,CAZ5B;;UAGU,SAAS;;;UAGjB,SAAS;;;UAGX,SAAS;;;UAGW,SACnC;;oBAbe,IAAA,CAAA,qBAAA,qEAY4B,IAAA,CAAA;;UATlB,SAAS;;;UAGjB,SAAS;;;UAGX,SAAS;;;UAGW,SACnC;;;cAbe,iBAkBU"}
1
+ {"version":3,"file":"PrismicRichText.vue.d.cts","names":[],"sources":["../../src/PrismicRichText/PrismicRichText.vue"],"sourcesContent":[],"mappings":";;;;;;;;KA6JY,oBAAA;;EAAA,KAAA,EAEJ,aAFI,GAAoB,IAAA,GAAA,SAAA;EAExB;;;;;AAkCP;;;;EAsHmB,YAAA,CAAA,EA7IJ,oBA6II;EAGO;;;;;;;;;;;;;;EAIxB,UAAA,CAAA,EApIW,qBAoIX;EADmC;;;;aA7H1B;;cAiHN,YAAY,QAAA,eAAA,CAY4B,KAAA,CAZ5B,gBAAA,CAAA;EAAA,KAAA,EAAA;UAGU,SAAS;;;UAGjB,SAAS;;;UAGX,SAAS;;;UAGW,SACnC;;oBAbe,KAAA,CAAA,qBAAA,uEAY4B,KAAA,CAAA;;UATlB,SAAS;;;UAGjB,SAAS;;;UAGX,SAAS;;;UAGW,SACnC;;;cAbe,iBAkBU"}
@@ -1,5 +1,5 @@
1
- import { VueComponent } from "../types.cjs";
2
- import { LinkResolverFunction, RTAnyNode, RichTextNodeType } from "@prismicio/client";
1
+ import { VueComponentShorthand } from "../types.cjs";
2
+ import { LinkResolverFunction, RTAnyNode, RTEmNode, RTEmbedNode, RTHeading1Node, RTHeading2Node, RTHeading3Node, RTHeading4Node, RTHeading5Node, RTHeading6Node, RTImageNode, RTLabelNode, RTLinkNode, RTListItemNode, RTListNode, RTOListItemNode, RTOListNode, RTParagraphNode, RTPreformattedNode, RTSpanNode, RTStrongNode } from "@prismicio/client";
3
3
 
4
4
  //#region src/PrismicRichText/types.d.ts
5
5
 
@@ -9,32 +9,31 @@ import { LinkResolverFunction, RTAnyNode, RichTextNodeType } from "@prismicio/cl
9
9
  *
10
10
  * @see Templating Rich Text and title fields from Prismic {@link https://prismic.io/docs/rich-text}
11
11
  */
12
- type VueRichTextSerializer = Partial<Record<keyof typeof RichTextNodeType, VueRichTextComponent | VueShorthand>>;
13
- /**
14
- * Props for a component rendering nodes from a Prismic rich text field.
15
- */
12
+ type VueRichTextSerializer = {
13
+ heading1?: RichTextComponentProps<RTHeading1Node> | VueComponentShorthand;
14
+ heading2?: RichTextComponentProps<RTHeading2Node> | VueComponentShorthand;
15
+ heading3?: RichTextComponentProps<RTHeading3Node> | VueComponentShorthand;
16
+ heading4?: RichTextComponentProps<RTHeading4Node> | VueComponentShorthand;
17
+ heading5?: RichTextComponentProps<RTHeading5Node> | VueComponentShorthand;
18
+ heading6?: RichTextComponentProps<RTHeading6Node> | VueComponentShorthand;
19
+ paragraph?: RichTextComponentProps<RTParagraphNode> | VueComponentShorthand;
20
+ preformatted?: RichTextComponentProps<RTPreformattedNode> | VueComponentShorthand;
21
+ strong?: RichTextComponentProps<RTStrongNode> | VueComponentShorthand;
22
+ em?: RichTextComponentProps<RTEmNode> | VueComponentShorthand;
23
+ listItem?: RichTextComponentProps<RTListItemNode> | VueComponentShorthand;
24
+ oListItem?: RichTextComponentProps<RTOListItemNode> | VueComponentShorthand;
25
+ list?: RichTextComponentProps<RTListNode> | VueComponentShorthand;
26
+ oList?: RichTextComponentProps<RTOListNode> | VueComponentShorthand;
27
+ image?: RichTextComponentProps<RTImageNode> | Omit<VueComponentShorthand, "as">;
28
+ embed?: RichTextComponentProps<RTEmbedNode> | VueComponentShorthand;
29
+ hyperlink?: RichTextComponentProps<RTLinkNode> | Omit<VueComponentShorthand, "as">;
30
+ label?: RichTextComponentProps<RTLabelNode> | Omit<VueComponentShorthand, "as">;
31
+ span?: RichTextComponentProps<RTSpanNode>;
32
+ };
33
+ /** Props for a component rendering nodes from a Prismic rich text field. */
16
34
  type RichTextComponentProps<TRTNode extends RTAnyNode = RTAnyNode> = {
17
35
  node: TRTNode;
18
36
  };
19
- /**
20
- * A Vue component rendering a node from a Prismic rich text field.
21
- *
22
- * @typeParam TRTNode - The type of rich text node(s) this component handles
23
- */
24
- type VueRichTextComponent<TRTNode extends RTAnyNode = RTAnyNode> = VueComponent<RichTextComponentProps<TRTNode>>;
25
- /**
26
- * A shorthand definition for {@link VueRichTextSerializer} component types.
27
- */
28
- type VueShorthand = {
29
- /**
30
- * The HTML element type rendered for this node type.
31
- */
32
- as?: string;
33
- /**
34
- * Other attributes to apply to the element type.
35
- */
36
- [Attribute: string]: string | boolean | null | undefined;
37
- };
38
37
  //#endregion
39
- export { RichTextComponentProps, VueRichTextSerializer, VueShorthand };
38
+ export { RichTextComponentProps, VueRichTextSerializer };
40
39
  //# sourceMappingURL=types.d.cts.map
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.cts","names":[],"sources":["../../src/PrismicRichText/types.ts"],"sourcesContent":[],"mappings":";;;;;;;AAcA;;;;AACC,KADW,qBAAA,GAAwB,OACnC,CAAA,MAAA,CAAA,MAAA,OAAoB,gBAApB,EAAsC,oBAAtC,GAA6D,YAA7D,CAAA,CAAA;;;AAMD;AAAmD,KAAvC,sBAAuC,CAAA,gBAAA,SAAA,GAAY,SAAZ,CAAA,GAAA;EAAY,IAAA,EACxD,OADwD;CACxD;;AACN;;;;KAOI,oBACJ,CAAA,gBADyC,SACzC,GADqD,SACrD,CAAA,GADkE,YAClE,CAAA,sBAAA,CAAuB,OAAvB,CAAA,CAAA;;;AAMD;KAAY,YAAA"}
1
+ {"version":3,"file":"types.d.cts","names":[],"sources":["../../src/PrismicRichText/types.ts"],"sourcesContent":[],"mappings":";;;;;;;AAiCA;;;;AAEmC,KAFvB,qBAAA,GAEuB;EAAvB,QAAA,CAAA,EADA,sBACA,CADuB,cACvB,CAAA,GADyC,qBACzC;EAAyC,QAAA,CAAA,EAAzC,sBAAyC,CAAlB,cAAkB,CAAA,GAAA,qBAAA;EAClB,QAAA,CAAA,EAAvB,sBAAuB,CAAA,cAAA,CAAA,GAAkB,qBAAlB;EAAvB,QAAA,CAAA,EACA,sBADA,CACuB,cADvB,CAAA,GACyC,qBADzC;EAAyC,QAAA,CAAA,EAEzC,sBAFyC,CAElB,cAFkB,CAAA,GAEA,qBAFA;EAClB,QAAA,CAAA,EAEvB,sBAFuB,CAEA,cAFA,CAAA,GAEkB,qBAFlB;EAAvB,SAAA,CAAA,EAGC,sBAHD,CAGwB,eAHxB,CAAA,GAG2C,qBAH3C;EAAyC,YAAA,CAAA,EAKjD,sBALiD,CAK1B,kBAL0B,CAAA,GAMjD,qBANiD;EAClB,MAAA,CAAA,EAMzB,sBANyB,CAMF,YANE,CAAA,GAMc,qBANd;EAAvB,EAAA,CAAA,EAON,sBAPM,CAOiB,QAPjB,CAAA,GAO6B,qBAP7B;EAAyC,QAAA,CAAA,EAQzC,sBARyC,CAQlB,cARkB,CAAA,GAQA,qBARA;EAClB,SAAA,CAAA,EAQtB,sBARsB,CAQC,eARD,CAAA,GAQoB,qBARpB;EAAvB,IAAA,CAAA,EASJ,sBATI,CASmB,UATnB,CAAA,GASiC,qBATjC;EAAyC,KAAA,CAAA,EAU5C,sBAV4C,CAUrB,WAVqB,CAAA,GAUN,qBAVM;EACjB,KAAA,CAAA,EAWhC,sBAXgC,CAWT,WAXS,CAAA,GAYhC,IAZgC,CAY3B,qBAZ2B,EAAA,IAAA,CAAA;EAAvB,KAAA,CAAA,EAaJ,sBAbI,CAamB,WAbnB,CAAA,GAakC,qBAblC;EAA0C,SAAA,CAAA,EAenD,sBAfmD,CAe5B,UAf4B,CAAA,GAgBnD,IAhBmD,CAgB9C,qBAhB8C,EAAA,IAAA,CAAA;EAE5B,KAAA,CAAA,EAgBvB,sBAhBuB,CAgBA,WAhBA,CAAA,GAiBvB,IAjBuB,CAiBlB,qBAjBkB,EAAA,IAAA,CAAA;EAAvB,IAAA,CAAA,EAkBI,sBAlBJ,CAkB2B,UAlB3B,CAAA;CACA;;AACM,KAoBE,sBApBF,CAAA,gBAoByC,SApBzC,GAoBqD,SApBrD,CAAA,GAAA;EAAuC,IAAA,EAqB1C,OArB0C;CACpB"}
@@ -5,13 +5,9 @@ import * as vue0 from "vue";
5
5
  import { TableField } from "@prismicio/client";
6
6
 
7
7
  //#region src/PrismicTable/PrismicTable.vue.d.ts
8
- /**
9
- * Props for `<PrismicTable />`.
10
- */
8
+ /** Props for `<PrismicTable />`. */
11
9
  type PrismicTableProps = {
12
- /**
13
- * The Prismic table field to render.
14
- */
10
+ /** The Prismic table field to render. */
15
11
  field: TableField | undefined;
16
12
  /**
17
13
  * An object that maps a table block type to a Vue component or a shorthand
@@ -1 +1 @@
1
- {"version":3,"file":"PrismicTable.vue.d.cts","names":[],"sources":["../../src/PrismicTable/PrismicTable.vue"],"sourcesContent":[],"mappings":";;;;;;;;;;AA+HY,KAAA,iBAAA,GAAiB;EAIrB;;;EAsBI,KAAA,EAtBJ,UAsBI,GAAA,SAAA;EAAkB;AAC7B;;;;;;;;;;;AAkJiB;;eAzJJ,qBAAqB;;;;;aAMvB;;cAmJN,cAAY,IAAA,CAAA,gBAAA,mCAAA,IAAA,CAAA,qBAAA,EAAA,IAAA,CAAA,qBAAA,cAAA,IAAA,CAAA,WAAA,EAAA,SAAA,qBAAA,sCAAA,IAAA,CAAA,uBAAA;cAAA,iBAGU"}
1
+ {"version":3,"file":"PrismicTable.vue.d.cts","names":[],"sources":["../../src/PrismicTable/PrismicTable.vue"],"sourcesContent":[],"mappings":";;;;;;;;KAyHY,iBAAA;;EAAA,KAAA,EAEJ,UAFI,GAAiB,SAAA;EAErB;;;;;AAuBP;;;;;;;;;EAkJiB,UAAA,CAAA,EAzJJ,kBAyJI,GAzJiB,qBAyJjB;EAAA;AAAA;;;aAnJN;;cAmJN,cAAY,IAAA,CAAA,gBAAA,mCAAA,IAAA,CAAA,qBAAA,EAAA,IAAA,CAAA,qBAAA,cAAA,IAAA,CAAA,WAAA,EAAA,SAAA,qBAAA,sCAAA,IAAA,CAAA,uBAAA;cAAA,iBAGU"}
@@ -1,5 +1,4 @@
1
- import { VueComponent } from "../types.cjs";
2
- import { VueShorthand } from "../PrismicRichText/types.cjs";
1
+ import { VueComponent, VueComponentShorthand } from "../types.cjs";
3
2
  import { TableField, TableFieldBody, TableFieldBodyRow, TableFieldDataCell, TableFieldHead, TableFieldHeadRow, TableFieldHeaderCell } from "@prismicio/client";
4
3
 
5
4
  //#region src/PrismicTable/types.d.ts
@@ -13,22 +12,22 @@ import { TableField, TableFieldBody, TableFieldBodyRow, TableFieldDataCell, Tabl
13
12
  type VueTableComponents = {
14
13
  table?: VueComponent<{
15
14
  table: TableField<"filled">;
16
- }> | VueShorthand;
15
+ }> | Omit<VueComponentShorthand, "as">;
17
16
  thead?: VueComponent<{
18
17
  head: TableFieldHead;
19
- }> | VueShorthand;
18
+ }> | Omit<VueComponentShorthand, "as">;
20
19
  tbody?: VueComponent<{
21
20
  body: TableFieldBody;
22
- }> | VueShorthand;
21
+ }> | Omit<VueComponentShorthand, "as">;
23
22
  tr?: VueComponent<{
24
23
  row: TableFieldBodyRow | TableFieldHeadRow;
25
- }> | VueShorthand;
24
+ }> | Omit<VueComponentShorthand, "as">;
26
25
  th?: VueComponent<{
27
26
  cell: TableFieldHeaderCell;
28
- }> | VueShorthand;
27
+ }> | Omit<VueComponentShorthand, "as">;
29
28
  td?: VueComponent<{
30
29
  cell: TableFieldDataCell;
31
- }> | VueShorthand;
30
+ }> | Omit<VueComponentShorthand, "as">;
32
31
  };
33
32
  //#endregion
34
33
  export { VueTableComponents };
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.cts","names":[],"sources":["../../src/PrismicTable/types.ts"],"sourcesContent":[],"mappings":";;;;;;;;AAmBA;;;;AAE8B,KAFlB,kBAAA,GAEkB;EAArB,KAAA,CAAA,EADA,YACA,CAAA;IAAyC,KAAA,EADnB,UACmB,CAAA,QAAA,CAAA;EACpB,CAAA,CAAA,GAF2B,YAE3B;EAArB,KAAA,CAAA,EADA,YACA,CAAA;IAAyC,IAAA,EADpB,cACoB;EAE1B,CAAA,CAAA,GAH0B,YAG1B;EAAoB,KAAA,CAAA,EAFnC,YAEmC,CAAA;IAAxC,IAAA,EAF0B,cAE1B;EACA,CAAA,CAAA,GAH8C,YAG9C;EACuB,EAAA,CAAA,EAFvB,YAEuB,CAAA;IAArB,GAAA,EAFkB,iBAElB,GAFsC,iBAEtC;EAA+C,CAAA,CAAA,GADjD,YACiD;EAC1B,EAAA,CAAA,EADrB,YACqB,CAAA;IAArB,IAAA,EADqB,oBACrB;EAA6C,CAAA,CAAA,GADE,YACF;EAAY,EAAA,CAAA,EAAzD,YAAyD,CAAA;UAApC;OAAwB"}
1
+ {"version":3,"file":"types.d.cts","names":[],"sources":["../../src/PrismicTable/types.ts"],"sourcesContent":[],"mappings":";;;;;;;AAkBA;;;;AAGI,KAHQ,kBAAA,GAGR;EAEqB,KAAA,CAAA,EAHrB,YAGqB,CAAA;IAArB,KAAA,EAHsB,UAGtB,CAAA,QAAA,CAAA;EACK,CAAA,CAAA,GAHL,IAGK,CAHA,qBAGA,EAAA,IAAA,CAAA;EAAL,KAAA,CAAA,EADA,YACA,CAAA;IAEqB,IAAA,EAHA,cAGA;EAArB,CAAA,CAAA,GAFA,IAEA,CAFK,qBAEL,EAAA,IAAA,CAAA;EACK,KAAA,CAAA,EADL,YACK,CAAA;IAAL,IAAA,EADqB,cACrB;EAEoB,CAAA,CAAA,GAFpB,IAEoB,CAFf,qBAEe,EAAA,IAAA,CAAA;EAAoB,EAAA,CAAA,EAAxC,YAAwC,CAAA;IAAxC,GAAA,EAAoB,iBAApB,GAAwC,iBAAxC;EACK,CAAA,CAAA,GAAL,IAAK,CAAA,qBAAA,EAAA,IAAA,CAAA;EAAL,EAAA,CAAA,EAEA,YAFA,CAAA;IAEqB,IAAA,EAAA,oBAAA;EAArB,CAAA,CAAA,GACA,IADA,CACK,qBADL,EAAA,IAAA,CAAA;EACK,EAAA,CAAA,EAEL,YAFK,CAAA;IAAL,IAAA,EAEqB,kBAFrB;EAEqB,CAAA,CAAA,GACrB,IADqB,CAChB,qBADgB,EAAA,IAAA,CAAA;CAArB"}
@@ -1,4 +1,4 @@
1
- import * as vue21 from "vue";
1
+ import * as vue4 from "vue";
2
2
  import { RichTextField } from "@prismicio/client";
3
3
 
4
4
  //#region src/PrismicText.vue.d.ts
@@ -18,7 +18,7 @@ type PrismicTextProps = {
18
18
  */
19
19
  separator?: string;
20
20
  };
21
- declare const __VLS_export: vue21.DefineComponent<PrismicTextProps, {}, {}, {}, {}, vue21.ComponentOptionsMixin, vue21.ComponentOptionsMixin, {}, string, vue21.PublicProps, Readonly<PrismicTextProps> & Readonly<{}>, {}, {}, {}, {}, string, vue21.ComponentProvideOptions, false, {}, any>;
21
+ declare const __VLS_export: vue4.DefineComponent<PrismicTextProps, {}, {}, {}, {}, vue4.ComponentOptionsMixin, vue4.ComponentOptionsMixin, {}, string, vue4.PublicProps, Readonly<PrismicTextProps> & Readonly<{}>, {}, {}, {}, {}, string, vue4.ComponentProvideOptions, false, {}, any>;
22
22
  declare const _default: typeof __VLS_export;
23
23
  //#endregion
24
24
  export { PrismicTextProps, _default };
@@ -1 +1 @@
1
- {"version":3,"file":"PrismicText.vue.d.cts","names":[],"sources":["../src/PrismicText.vue"],"sourcesContent":[],"mappings":";;;;;KAwDY,gBAAA;;EAAA,KAAA,EAEJ,aAFoB,GAAA,IAAA,GAAA,SAEpB;EAmDF;;;;EAAY,QAAA,CAAA,EAAA,MAAA;EAAA;;;;;EAAA,SAAA,CAAA,EAAA,MAAA;AAAA,CAAA;cAAZ,cAAY,KAAA,CAAA,gBAAA,kCAAA,KAAA,CAAA,qBAAA,EAAA,KAAA,CAAA,qBAAA,cAAA,KAAA,CAAA,WAAA,EAAA,SAAA,oBAAA,sCAAA,KAAA,CAAA,uBAAA;cAAA,iBAGU"}
1
+ {"version":3,"file":"PrismicText.vue.d.cts","names":[],"sources":["../src/PrismicText.vue"],"sourcesContent":[],"mappings":";;;;;KAwDY,gBAAA;;EAAA,KAAA,EAEJ,aAFoB,GAAA,IAAA,GAEpB,SAAA;EAmDF;;;;EAAY,QAAA,CAAA,EAAA,MAAA;EAAA;;;;;EAAA,SAAA,CAAA,EAAA,MAAA;AAAA,CAAA;cAAZ,cAAY,IAAA,CAAA,gBAAA,kCAAA,IAAA,CAAA,qBAAA,EAAA,IAAA,CAAA,qBAAA,cAAA,IAAA,CAAA,WAAA,EAAA,SAAA,oBAAA,sCAAA,IAAA,CAAA,uBAAA;cAAA,iBAGU"}
@@ -1,5 +1,5 @@
1
1
  import { SliceComponentType, SliceLike, SliceZoneComponents, SliceZoneLike } from "./types.cjs";
2
- import * as vue26 from "vue";
2
+ import * as vue9 from "vue";
3
3
 
4
4
  //#region src/SliceZone/SliceZone.vue.d.ts
5
5
 
@@ -22,7 +22,7 @@ type SliceZoneProps<TContext = unknown> = {
22
22
  context?: TContext;
23
23
  };
24
24
  type __VLS_Props = SliceZoneProps;
25
- declare const __VLS_export: vue26.DefineComponent<__VLS_Props, {}, {}, {}, {}, vue26.ComponentOptionsMixin, vue26.ComponentOptionsMixin, {}, string, vue26.PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, vue26.ComponentProvideOptions, false, {}, any>;
25
+ declare const __VLS_export: vue9.DefineComponent<__VLS_Props, {}, {}, {}, {}, vue9.ComponentOptionsMixin, vue9.ComponentOptionsMixin, {}, string, vue9.PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, vue9.ComponentProvideOptions, false, {}, any>;
26
26
  declare const _default: typeof __VLS_export;
27
27
  //#endregion
28
28
  export { SliceZoneProps, _default };
@@ -1 +1 @@
1
- {"version":3,"file":"SliceZone.vue.d.cts","names":[],"sources":["../../src/SliceZone/SliceZone.vue"],"sourcesContent":[],"mappings":";;;;;;;;AAsGA;;AAEoC,KAFxB,cAEwB,CAAA,WAAA,OAAA,CAAA,GAAA;EAAY;EAAvC,MAAA,EAAA,aAAA,CAAc,SAAd,GAAA,CAA2B,SAA3B,GAAuC,MAAvC,CAAA,MAAA,EAAA,OAAA,CAAA,CAAA,CAAA;EAGK;EAO8B,UAAA,CAAA,EAP9B,mBAO8B;EAAxB;;;AAInB;EA2EK,gBAEJ,CAAA,EAjFkB,kBAiFlB,CAAA,GAAA,EAjF0C,QAiF1C,CAAA;EAFgB;EAAA,OAAA,CAAA,EA5EP,QA4EO;CAAA;KAzEb,WAAA,GAAc,cAyED;cAAZ,YAAY,EAAA,KAAA,CAAA,eAAA,CAAA,WAAA,EAAA,CAAA,CAAA,EAAA,CAAA,CAAA,EAAA,CAAA,CAAA,EAAA,CAAA,CAAA,EAAA,KAAA,CAAA,qBAAA,EAAA,KAAA,CAAA,qBAAA,EAAA,CAAA,CAAA,EAAA,MAAA,EAAA,KAAA,CAAA,WAAA,EAAA,QAAA,CAAA,WAAA,CAAA,GAAA,QAAA,CAAA,CAAA,CAAA,CAAA,EAAA,CAAA,CAAA,EAAA,CAAA,CAAA,EAAA,CAAA,CAAA,EAAA,CAAA,CAAA,EAAA,MAAA,EAAA,KAAA,CAAA,uBAAA,EAAA,KAAA,EAAA,CAAA,CAAA,EAAA,GAAA,CAAA;cAAA,QAAA,EAAA,OAGU,YAHV"}
1
+ {"version":3,"file":"SliceZone.vue.d.cts","names":[],"sources":["../../src/SliceZone/SliceZone.vue"],"sourcesContent":[],"mappings":";;;;;;;;AAsGA;;AAEoC,KAFxB,cAEwB,CAAA,WAAA,OAAA,CAAA,GAAA;EAAY;EAAvC,MAAA,EAAA,aAAA,CAAc,SAAd,GAAA,CAA2B,SAA3B,GAAuC,MAAvC,CAAA,MAAA,EAAA,OAAA,CAAA,CAAA,CAAA;EAGK;EAO8B,UAAA,CAAA,EAP9B,mBAO8B;EAAxB;;;AAInB;EA2EK,gBAEJ,CAAA,EAjFkB,kBAiFlB,CAAA,GAAA,EAjF0C,QAiF1C,CAAA;EAFgB;EAAA,OAAA,CAAA,EA5EP,QA4EO;CAAA;KAzEb,WAAA,GAAc,cAyED;cAAZ,YAAY,EAAA,IAAA,CAAA,eAAA,CAAA,WAAA,EAAA,CAAA,CAAA,EAAA,CAAA,CAAA,EAAA,CAAA,CAAA,EAAA,CAAA,CAAA,EAAA,IAAA,CAAA,qBAAA,EAAA,IAAA,CAAA,qBAAA,EAAA,CAAA,CAAA,EAAA,MAAA,EAAA,IAAA,CAAA,WAAA,EAAA,QAAA,CAAA,WAAA,CAAA,GAAA,QAAA,CAAA,CAAA,CAAA,CAAA,EAAA,CAAA,CAAA,EAAA,CAAA,CAAA,EAAA,CAAA,CAAA,EAAA,CAAA,CAAA,EAAA,MAAA,EAAA,IAAA,CAAA,uBAAA,EAAA,KAAA,EAAA,CAAA,CAAA,EAAA,GAAA,CAAA;cAAA,QAAA,EAAA,OAGU,YAHV"}
package/dist/package.cjs CHANGED
@@ -1,6 +1,6 @@
1
1
 
2
2
  //#region package.json
3
- var version = "5.3.0-canary.320f423";
3
+ var version = "5.3.0-canary.553482e";
4
4
 
5
5
  //#endregion
6
6
  Object.defineProperty(exports, 'version', {
@@ -1 +1 @@
1
- {"version":3,"file":"package.cjs","names":[],"sources":["../package.json"],"sourcesContent":["{\n\t\"name\": \"@prismicio/vue\",\n\t\"version\": \"5.3.0-canary.320f423\",\n\t\"description\": \"Vue plugin, components, and composables to fetch and present Prismic content\",\n\t\"keywords\": [\n\t\t\"typescript\",\n\t\t\"prismic\",\n\t\t\"vue\",\n\t\t\"plugin\"\n\t],\n\t\"repository\": {\n\t\t\"type\": \"git\",\n\t\t\"url\": \"ssh://git@github.com/prismicio/prismic-vue.git\"\n\t},\n\t\"license\": \"Apache-2.0\",\n\t\"author\": \"Prismic <contact@prismic.io> (https://prismic.io)\",\n\t\"sideEffects\": false,\n\t\"type\": \"module\",\n\t\"exports\": {\n\t\t\".\": {\n\t\t\t\"require\": \"./dist/index.cjs\",\n\t\t\t\"import\": \"./dist/index.js\"\n\t\t},\n\t\t\"./package.json\": \"./package.json\"\n\t},\n\t\"main\": \"./dist/index.cjs\",\n\t\"module\": \"./dist/index.js\",\n\t\"types\": \"./dist/index.d.cts\",\n\t\"files\": [\n\t\t\"./dist\",\n\t\t\"./src\"\n\t],\n\t\"scripts\": {\n\t\t\"build\": \"tsdown\",\n\t\t\"dev\": \"tsdown --watch\",\n\t\t\"format\": \"prettier --write .\",\n\t\t\"playground:build\": \"vite build playground\",\n\t\t\"playground:dev\": \"vite playground\",\n\t\t\"prepare\": \"npm run build\",\n\t\t\"lint\": \"oxlint --deny-warnings\",\n\t\t\"types\": \"vue-tsc --noEmit\",\n\t\t\"unit\": \"vitest run --coverage\",\n\t\t\"unit:watch\": \"vitest watch\",\n\t\t\"test\": \"npm run lint && npm run types && npm run unit && npm run build\"\n\t},\n\t\"dependencies\": {\n\t\t\"esm-env\": \"^1.2.2\"\n\t},\n\t\"devDependencies\": {\n\t\t\"@prismicio/client\": \"^7.21.0\",\n\t\t\"@prismicio/mock\": \"^0.7.1\",\n\t\t\"@trivago/prettier-plugin-sort-imports\": \"^6.0.0\",\n\t\t\"@types/jsdom-global\": \"^3.0.7\",\n\t\t\"@vitejs/plugin-vue\": \"^6.0.2\",\n\t\t\"@vitest/coverage-v8\": \"^4.0.15\",\n\t\t\"@vue/test-utils\": \"^2.4.6\",\n\t\t\"jsdom\": \"^27.3.0\",\n\t\t\"jsdom-global\": \"^3.0.2\",\n\t\t\"oxlint\": \"1.32.0\",\n\t\t\"prettier\": \"^3.7.4\",\n\t\t\"prettier-plugin-jsdoc\": \"^1.8.0\",\n\t\t\"tsdown\": \"0.17.2\",\n\t\t\"typescript\": \"^5.9.3\",\n\t\t\"vite\": \"^7.2.7\",\n\t\t\"vitest\": \"^4.0.15\",\n\t\t\"vue\": \"^3.5.25\",\n\t\t\"vue-router\": \"^4.6.3\",\n\t\t\"vue-tsc\": \"^3.1.8\"\n\t},\n\t\"peerDependencies\": {\n\t\t\"@prismicio/client\": \"^7\",\n\t\t\"vue\": \"^3\"\n\t},\n\t\"engines\": {\n\t\t\"node\": \">=20\"\n\t},\n\t\"publishConfig\": {\n\t\t\"access\": \"public\"\n\t}\n}\n"],"mappings":";;cAEY"}
1
+ {"version":3,"file":"package.cjs","names":[],"sources":["../package.json"],"sourcesContent":["{\n\t\"name\": \"@prismicio/vue\",\n\t\"version\": \"5.3.0-canary.553482e\",\n\t\"description\": \"Vue plugin, components, and composables to fetch and present Prismic content\",\n\t\"keywords\": [\n\t\t\"typescript\",\n\t\t\"prismic\",\n\t\t\"vue\",\n\t\t\"plugin\"\n\t],\n\t\"repository\": {\n\t\t\"type\": \"git\",\n\t\t\"url\": \"ssh://git@github.com/prismicio/prismic-vue.git\"\n\t},\n\t\"license\": \"Apache-2.0\",\n\t\"author\": \"Prismic <contact@prismic.io> (https://prismic.io)\",\n\t\"sideEffects\": false,\n\t\"type\": \"module\",\n\t\"exports\": {\n\t\t\".\": {\n\t\t\t\"require\": \"./dist/index.cjs\",\n\t\t\t\"import\": \"./dist/index.js\"\n\t\t},\n\t\t\"./package.json\": \"./package.json\"\n\t},\n\t\"main\": \"./dist/index.cjs\",\n\t\"module\": \"./dist/index.js\",\n\t\"types\": \"./dist/index.d.cts\",\n\t\"files\": [\n\t\t\"./dist\",\n\t\t\"./src\"\n\t],\n\t\"scripts\": {\n\t\t\"build\": \"tsdown\",\n\t\t\"dev\": \"tsdown --watch\",\n\t\t\"format\": \"prettier --write .\",\n\t\t\"prepare\": \"npm run build\",\n\t\t\"lint\": \"oxlint --deny-warnings\",\n\t\t\"types\": \"vue-tsc --noEmit\",\n\t\t\"unit\": \"vitest run --coverage\",\n\t\t\"unit:watch\": \"vitest watch\",\n\t\t\"test\": \"npm run lint && npm run types && npm run unit && npm run build\"\n\t},\n\t\"dependencies\": {\n\t\t\"esm-env\": \"^1.2.2\"\n\t},\n\t\"devDependencies\": {\n\t\t\"@prismicio/client\": \"^7.21.0\",\n\t\t\"@prismicio/mock\": \"^0.7.1\",\n\t\t\"@trivago/prettier-plugin-sort-imports\": \"^6.0.0\",\n\t\t\"@types/jsdom-global\": \"^3.0.7\",\n\t\t\"@vitejs/plugin-vue\": \"^6.0.2\",\n\t\t\"@vitest/coverage-v8\": \"^4.0.15\",\n\t\t\"@vue/test-utils\": \"^2.4.6\",\n\t\t\"jsdom\": \"^27.3.0\",\n\t\t\"jsdom-global\": \"^3.0.2\",\n\t\t\"oxlint\": \"1.32.0\",\n\t\t\"prettier\": \"^3.7.4\",\n\t\t\"prettier-plugin-jsdoc\": \"^1.8.0\",\n\t\t\"tsdown\": \"0.17.2\",\n\t\t\"typescript\": \"^5.9.3\",\n\t\t\"vite\": \"^7.2.7\",\n\t\t\"vitest\": \"^4.0.15\",\n\t\t\"vue\": \"^3.5.25\",\n\t\t\"vue-router\": \"^4.6.3\",\n\t\t\"vue-tsc\": \"^3.1.8\"\n\t},\n\t\"peerDependencies\": {\n\t\t\"@prismicio/client\": \"^7\",\n\t\t\"vue\": \"^3\"\n\t},\n\t\"engines\": {\n\t\t\"node\": \">=20\"\n\t},\n\t\"publishConfig\": {\n\t\t\"access\": \"public\"\n\t}\n}\n"],"mappings":";;cAEY"}
package/dist/package.js CHANGED
@@ -1,5 +1,5 @@
1
1
  //#region package.json
2
- var version = "5.3.0-canary.320f423";
2
+ var version = "5.3.0-canary.553482e";
3
3
 
4
4
  //#endregion
5
5
  export { version };
@@ -1 +1 @@
1
- {"version":3,"file":"package.js","names":[],"sources":["../package.json"],"sourcesContent":["{\n\t\"name\": \"@prismicio/vue\",\n\t\"version\": \"5.3.0-canary.320f423\",\n\t\"description\": \"Vue plugin, components, and composables to fetch and present Prismic content\",\n\t\"keywords\": [\n\t\t\"typescript\",\n\t\t\"prismic\",\n\t\t\"vue\",\n\t\t\"plugin\"\n\t],\n\t\"repository\": {\n\t\t\"type\": \"git\",\n\t\t\"url\": \"ssh://git@github.com/prismicio/prismic-vue.git\"\n\t},\n\t\"license\": \"Apache-2.0\",\n\t\"author\": \"Prismic <contact@prismic.io> (https://prismic.io)\",\n\t\"sideEffects\": false,\n\t\"type\": \"module\",\n\t\"exports\": {\n\t\t\".\": {\n\t\t\t\"require\": \"./dist/index.cjs\",\n\t\t\t\"import\": \"./dist/index.js\"\n\t\t},\n\t\t\"./package.json\": \"./package.json\"\n\t},\n\t\"main\": \"./dist/index.cjs\",\n\t\"module\": \"./dist/index.js\",\n\t\"types\": \"./dist/index.d.cts\",\n\t\"files\": [\n\t\t\"./dist\",\n\t\t\"./src\"\n\t],\n\t\"scripts\": {\n\t\t\"build\": \"tsdown\",\n\t\t\"dev\": \"tsdown --watch\",\n\t\t\"format\": \"prettier --write .\",\n\t\t\"playground:build\": \"vite build playground\",\n\t\t\"playground:dev\": \"vite playground\",\n\t\t\"prepare\": \"npm run build\",\n\t\t\"lint\": \"oxlint --deny-warnings\",\n\t\t\"types\": \"vue-tsc --noEmit\",\n\t\t\"unit\": \"vitest run --coverage\",\n\t\t\"unit:watch\": \"vitest watch\",\n\t\t\"test\": \"npm run lint && npm run types && npm run unit && npm run build\"\n\t},\n\t\"dependencies\": {\n\t\t\"esm-env\": \"^1.2.2\"\n\t},\n\t\"devDependencies\": {\n\t\t\"@prismicio/client\": \"^7.21.0\",\n\t\t\"@prismicio/mock\": \"^0.7.1\",\n\t\t\"@trivago/prettier-plugin-sort-imports\": \"^6.0.0\",\n\t\t\"@types/jsdom-global\": \"^3.0.7\",\n\t\t\"@vitejs/plugin-vue\": \"^6.0.2\",\n\t\t\"@vitest/coverage-v8\": \"^4.0.15\",\n\t\t\"@vue/test-utils\": \"^2.4.6\",\n\t\t\"jsdom\": \"^27.3.0\",\n\t\t\"jsdom-global\": \"^3.0.2\",\n\t\t\"oxlint\": \"1.32.0\",\n\t\t\"prettier\": \"^3.7.4\",\n\t\t\"prettier-plugin-jsdoc\": \"^1.8.0\",\n\t\t\"tsdown\": \"0.17.2\",\n\t\t\"typescript\": \"^5.9.3\",\n\t\t\"vite\": \"^7.2.7\",\n\t\t\"vitest\": \"^4.0.15\",\n\t\t\"vue\": \"^3.5.25\",\n\t\t\"vue-router\": \"^4.6.3\",\n\t\t\"vue-tsc\": \"^3.1.8\"\n\t},\n\t\"peerDependencies\": {\n\t\t\"@prismicio/client\": \"^7\",\n\t\t\"vue\": \"^3\"\n\t},\n\t\"engines\": {\n\t\t\"node\": \">=20\"\n\t},\n\t\"publishConfig\": {\n\t\t\"access\": \"public\"\n\t}\n}\n"],"mappings":";cAEY"}
1
+ {"version":3,"file":"package.js","names":[],"sources":["../package.json"],"sourcesContent":["{\n\t\"name\": \"@prismicio/vue\",\n\t\"version\": \"5.3.0-canary.553482e\",\n\t\"description\": \"Vue plugin, components, and composables to fetch and present Prismic content\",\n\t\"keywords\": [\n\t\t\"typescript\",\n\t\t\"prismic\",\n\t\t\"vue\",\n\t\t\"plugin\"\n\t],\n\t\"repository\": {\n\t\t\"type\": \"git\",\n\t\t\"url\": \"ssh://git@github.com/prismicio/prismic-vue.git\"\n\t},\n\t\"license\": \"Apache-2.0\",\n\t\"author\": \"Prismic <contact@prismic.io> (https://prismic.io)\",\n\t\"sideEffects\": false,\n\t\"type\": \"module\",\n\t\"exports\": {\n\t\t\".\": {\n\t\t\t\"require\": \"./dist/index.cjs\",\n\t\t\t\"import\": \"./dist/index.js\"\n\t\t},\n\t\t\"./package.json\": \"./package.json\"\n\t},\n\t\"main\": \"./dist/index.cjs\",\n\t\"module\": \"./dist/index.js\",\n\t\"types\": \"./dist/index.d.cts\",\n\t\"files\": [\n\t\t\"./dist\",\n\t\t\"./src\"\n\t],\n\t\"scripts\": {\n\t\t\"build\": \"tsdown\",\n\t\t\"dev\": \"tsdown --watch\",\n\t\t\"format\": \"prettier --write .\",\n\t\t\"prepare\": \"npm run build\",\n\t\t\"lint\": \"oxlint --deny-warnings\",\n\t\t\"types\": \"vue-tsc --noEmit\",\n\t\t\"unit\": \"vitest run --coverage\",\n\t\t\"unit:watch\": \"vitest watch\",\n\t\t\"test\": \"npm run lint && npm run types && npm run unit && npm run build\"\n\t},\n\t\"dependencies\": {\n\t\t\"esm-env\": \"^1.2.2\"\n\t},\n\t\"devDependencies\": {\n\t\t\"@prismicio/client\": \"^7.21.0\",\n\t\t\"@prismicio/mock\": \"^0.7.1\",\n\t\t\"@trivago/prettier-plugin-sort-imports\": \"^6.0.0\",\n\t\t\"@types/jsdom-global\": \"^3.0.7\",\n\t\t\"@vitejs/plugin-vue\": \"^6.0.2\",\n\t\t\"@vitest/coverage-v8\": \"^4.0.15\",\n\t\t\"@vue/test-utils\": \"^2.4.6\",\n\t\t\"jsdom\": \"^27.3.0\",\n\t\t\"jsdom-global\": \"^3.0.2\",\n\t\t\"oxlint\": \"1.32.0\",\n\t\t\"prettier\": \"^3.7.4\",\n\t\t\"prettier-plugin-jsdoc\": \"^1.8.0\",\n\t\t\"tsdown\": \"0.17.2\",\n\t\t\"typescript\": \"^5.9.3\",\n\t\t\"vite\": \"^7.2.7\",\n\t\t\"vitest\": \"^4.0.15\",\n\t\t\"vue\": \"^3.5.25\",\n\t\t\"vue-router\": \"^4.6.3\",\n\t\t\"vue-tsc\": \"^3.1.8\"\n\t},\n\t\"peerDependencies\": {\n\t\t\"@prismicio/client\": \"^7\",\n\t\t\"vue\": \"^3\"\n\t},\n\t\"engines\": {\n\t\t\"node\": \">=20\"\n\t},\n\t\"publishConfig\": {\n\t\t\"access\": \"public\"\n\t}\n}\n"],"mappings":";cAEY"}
@@ -1,4 +1,4 @@
1
- import * as vue26 from "vue";
1
+ import * as vue21 from "vue";
2
2
  import { ImageField, asImagePixelDensitySrcSet, asImageSrc, asImageWidthSrcSet } from "@prismicio/client";
3
3
 
4
4
  //#region src/PrismicImage.vue.d.ts
@@ -64,7 +64,7 @@ type PrismicImageProps = {
64
64
  */
65
65
  pixelDensities: NonNullable<Parameters<typeof asImagePixelDensitySrcSet>[1]>["pixelDensities"] | "defaults";
66
66
  });
67
- declare const __VLS_export: vue26.DefineComponent<({
67
+ declare const __VLS_export: vue21.DefineComponent<({
68
68
  /** The Prismic image field or thumbnail to render. */
69
69
  field: ImageField | ImageField<string>;
70
70
  /**
@@ -162,7 +162,7 @@ declare const __VLS_export: vue26.DefineComponent<({
162
162
  * densities will be used: 1, 2, 3.
163
163
  */
164
164
  pixelDensities: NonNullable<Parameters<typeof asImagePixelDensitySrcSet>[1]>["pixelDensities"] | "defaults";
165
- }), {}, {}, {}, {}, vue26.ComponentOptionsMixin, vue26.ComponentOptionsMixin, {}, string, vue26.PublicProps, Readonly<({
165
+ }), {}, {}, {}, {}, vue21.ComponentOptionsMixin, vue21.ComponentOptionsMixin, {}, string, vue21.PublicProps, Readonly<({
166
166
  /** The Prismic image field or thumbnail to render. */
167
167
  field: ImageField | ImageField<string>;
168
168
  /**
@@ -260,7 +260,7 @@ declare const __VLS_export: vue26.DefineComponent<({
260
260
  * densities will be used: 1, 2, 3.
261
261
  */
262
262
  pixelDensities: NonNullable<Parameters<typeof asImagePixelDensitySrcSet>[1]>["pixelDensities"] | "defaults";
263
- })> & Readonly<{}>, {}, {}, {}, {}, string, vue26.ComponentProvideOptions, false, {}, any>;
263
+ })> & Readonly<{}>, {}, {}, {}, {}, string, vue21.ComponentProvideOptions, false, {}, any>;
264
264
  declare const _default: typeof __VLS_export;
265
265
  //#endregion
266
266
  export { PrismicImageProps, _default };
@@ -1,5 +1,5 @@
1
1
  import { ComponentOrTagName } from "./types.js";
2
- import * as vue11 from "vue";
2
+ import * as vue6 from "vue";
3
3
  import { AsLinkAttrsConfig, LinkField, LinkResolverFunction, PrismicDocument } from "@prismicio/client";
4
4
 
5
5
  //#region src/PrismicLink.vue.d.ts
@@ -49,7 +49,7 @@ declare var __VLS_8: {};
49
49
  type __VLS_Slots = {} & {
50
50
  default?: (props: typeof __VLS_8) => any;
51
51
  };
52
- declare const __VLS_base: vue11.DefineComponent<({
52
+ declare const __VLS_base: vue6.DefineComponent<({
53
53
  /**
54
54
  * The link resolver used to resolve links.
55
55
  *
@@ -121,7 +121,7 @@ declare const __VLS_base: vue11.DefineComponent<({
121
121
  /** The Prismic document to render as a link. */
122
122
  document: PrismicDocument;
123
123
  field?: never;
124
- }), {}, {}, {}, {}, vue11.ComponentOptionsMixin, vue11.ComponentOptionsMixin, {}, string, vue11.PublicProps, Readonly<({
124
+ }), {}, {}, {}, {}, vue6.ComponentOptionsMixin, vue6.ComponentOptionsMixin, {}, string, vue6.PublicProps, Readonly<({
125
125
  /**
126
126
  * The link resolver used to resolve links.
127
127
  *
@@ -193,7 +193,7 @@ declare const __VLS_base: vue11.DefineComponent<({
193
193
  /** The Prismic document to render as a link. */
194
194
  document: PrismicDocument;
195
195
  field?: never;
196
- })> & Readonly<{}>, {}, {}, {}, {}, string, vue11.ComponentProvideOptions, false, {}, any>;
196
+ })> & Readonly<{}>, {}, {}, {}, {}, string, vue6.ComponentProvideOptions, false, {}, any>;
197
197
  declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
198
198
  declare const _default: typeof __VLS_export;
199
199
  type __VLS_WithSlots<T, S> = T & {
@@ -1 +1 @@
1
- {"version":3,"file":"PrismicLink.vue.d.ts","names":[],"sources":["../../src/PrismicLink.vue"],"sourcesContent":[],"mappings":";;;;;;KA8IY,gBAAA;EAAA;;;;;;;;AA8CX;EA2EI,YAAA,CAAA,EA/GW,oBAgHoB;EAK9B;;;;;EAzFI,GAAA,CAAA,EAAA,MAAA,GArBM,iBAqBN,CAAA,KAAA,CAAA;EA5BM;;;;;;;;EAAA,iBAAA,CAAA,EAiBK,kBAjBL;EAOA;;;;;EAAA,iBAAA,CAAA,EAiBK,kBAjBL;CAUK,GAAA,CAAA;EAOA;EASR,KAAA,EALH,SAKG;;;;UAoFG,EApFH,eAoFG;EAAA,KAAA,CAAA,EAAA,KAAA;AAAA,CAAA,CAAA;YAPZ,OAU8C,EAAA,CAAA,CAAA;KAT7C,WAAA,GASyD,CAAA,CAAA,GAAA;EAAnC,OAAA,CAAA,EAAA,CAAA,KAAA,EAAA,OARE,OAQF,EAAA,GAAA,GAAA;CAAe;AAAA,cAHpC,UAIkC,QAJxB,eAIwB,CAAA,CAAA;EACnC;;;;;;;;;iBA1HW;;;;;;iBAOA;;;;;;;;;sBAUK;;;;;;sBAOA;;;SAIX;;;;;;;;;;;;iBA5BM;;;;;;iBAOA;;;;;;;;;sBAUK;;;;;;sBAOA;;;YASR;;oBAAe,KAAA,CAAA,qBAAA;;;;;;;;;;iBAjCZ;;;;;;iBAOA;;;;;;;;;sBAUK;;;;;;sBAOA;;;SAIX;;;;;;;;;;;;iBA5BM;;;;;;iBAOA;;;;;;;;;sBAUK;;;;;;sBAOA;;;YASR;;;cAuFP,cAAqB,uBAAuB,YAAY;cAApB,iBACd;KACvB,wBAAwB;;YAEnB"}
1
+ {"version":3,"file":"PrismicLink.vue.d.ts","names":[],"sources":["../../src/PrismicLink.vue"],"sourcesContent":[],"mappings":";;;;;;KA8IY,gBAAA;EAAA;;;;;;;;AA8CX;EA2EI,YAAA,CAAA,EA/GW,oBAgHoB;EAK9B;;;;;EAzFI,GAAA,CAAA,EAAA,MAAA,GArBM,iBAqBN,CAAA,KAAA,CAAA;EA5BM;;;;;;;;EAAA,iBAAA,CAAA,EAiBK,kBAjBL;EAOA;;;;;EAAA,iBAAA,CAAA,EAiBK,kBAjBL;CAUK,GAAA,CAAA;EAOA;EASR,KAAA,EALH,SAKG;;;;UAoFG,EApFH,eAoFG;EAAA,KAAA,CAAA,EAAA,KAAA;AAAA,CAAA,CAAA;YAPZ,OAU8C,EAAA,CAAA,CAAA;KAT7C,WAAA,GASyD,CAAA,CAAA,GAAA;EAAnC,OAAA,CAAA,EAAA,CAAA,KAAA,EAAA,OARE,OAQF,EAAA,GAAA,GAAA;CAAe;AAAA,cAHpC,UAIkC,OAJxB,eAIwB,CAAA,CAAA;EACnC;;;;;;;;;iBA1HW;;;;;;iBAOA;;;;;;;;;sBAUK;;;;;;sBAOA;;;SAIX;;;;;;;;;;;;iBA5BM;;;;;;iBAOA;;;;;;;;;sBAUK;;;;;;sBAOA;;;YASR;;oBAAe,IAAA,CAAA,qBAAA;;;;;;;;;;iBAjCZ;;;;;;iBAOA;;;;;;;;;sBAUK;;;;;;sBAOA;;;SAIX;;;;;;;;;;;;iBA5BM;;;;;;iBAOA;;;;;;;;;sBAUK;;;;;;sBAOA;;;YASR;;;cAuFP,cAAqB,uBAAuB,YAAY;cAApB,iBACd;KACvB,wBAAwB;;YAEnB"}
@@ -1 +1 @@
1
- {"version":3,"file":"PrismicRichText.cjs","names":[],"sources":["../../../src/PrismicRichText/PrismicRichText.vue"],"sourcesContent":["<script lang=\"ts\" setup>\nimport type {\n\tLinkResolverFunction,\n\tRichTextField,\n\tRichTextNodeType,\n} from \"@prismicio/client\"\nimport { asTree } from \"@prismicio/client/richtext\"\nimport type { PropType } from \"vue\"\nimport { computed } from \"vue\"\n\nimport { type ComponentOrTagName, isVueComponent } from \"../types\"\nimport type {\n\tInternalVueRichTextComponent,\n\tVueRichTextSerializer,\n\tVueShorthand,\n} from \"./types\"\n\nimport PrismicRichTextDefaultComponent from \"./PrismicRichTextDefaultComponent.vue\"\nimport PrismicRichTextSerialize from \"./PrismicRichTextSerialize.vue\"\n\n/**\n * Props for `<PrismicRichText />`.\n */\nexport type PrismicRichTextProps = {\n\t/**\n\t * The Prismic rich text field to render.\n\t */\n\tfield: RichTextField | null | undefined\n\n\t/**\n\t * The link resolver used to resolve links.\n\t *\n\t * @remarks\n\t * If your app uses route resolvers when querying for your Prismic\n\t * repository's content, a link resolver does not need to be provided.\n\t *\n\t * @see Learn about link resolvers and route resolvers {@link https://prismic.io/docs/routes}\n\t */\n\tlinkResolver?: LinkResolverFunction\n\n\t/**\n\t * An object that maps a rich text block type to a Vue component or a\n\t * shorthand definition.\n\t *\n\t * @example\n\t *\n\t * ```javascript\n\t * {\n\t * heading1: Heading1,\n\t * paragraph: { class: 'prose'},\n\t * strong: { as: 'em', class: 'font-bold' },\n\t * }\n\t * ```\n\t */\n\tcomponents?: VueRichTextSerializer\n\n\t/**\n\t * The value to be rendered when the field is empty. If a fallback is not\n\t * given, `null` will be rendered.\n\t */\n\tfallback?: ComponentOrTagName\n}\n\n// We're forced to declare props using the JavaScript syntax because `@vue/compiler-sfc`\n// has limitations for inferring types from complex objects.\nconst props = defineProps({\n\tfield: {\n\t\ttype: Array as unknown as PropType<PrismicRichTextProps[\"field\"]>,\n\t},\n\tlinkResolver: {\n\t\ttype: Function as PropType<PrismicRichTextProps[\"linkResolver\"]>,\n\t},\n\tcomponents: {\n\t\ttype: Object as PropType<PrismicRichTextProps[\"components\"]>,\n\t},\n\tfallback: {\n\t\ttype: [String, Object, Function] as PropType<\n\t\t\tPrismicRichTextProps[\"fallback\"]\n\t\t>,\n\t},\n})\ndefineOptions({ name: \"PrismicRichText\" })\n\nconst children = computed(() => {\n\treturn asTree(props.field || []).children\n})\n\nfunction getInternalComponent(type: keyof typeof RichTextNodeType) {\n\tconst maybeComponentOrShorthand = props.components?.[type]\n\n\tif (isVueComponent(maybeComponentOrShorthand)) {\n\t\treturn { is: maybeComponentOrShorthand }\n\t}\n\n\treturn {\n\t\tis: PrismicRichTextDefaultComponent,\n\t\tprops: {\n\t\t\tlinkResolver: props.linkResolver,\n\t\t\tshorthand: maybeComponentOrShorthand as VueShorthand,\n\t\t},\n\t}\n}\n\nconst internalComponents = computed<InternalVueRichTextComponent>(() => {\n\treturn {\n\t\theading1: getInternalComponent(\"heading1\"),\n\t\theading2: getInternalComponent(\"heading2\"),\n\t\theading3: getInternalComponent(\"heading3\"),\n\t\theading4: getInternalComponent(\"heading4\"),\n\t\theading5: getInternalComponent(\"heading5\"),\n\t\theading6: getInternalComponent(\"heading6\"),\n\t\tparagraph: getInternalComponent(\"paragraph\"),\n\t\tpreformatted: getInternalComponent(\"preformatted\"),\n\t\tstrong: getInternalComponent(\"strong\"),\n\t\tem: getInternalComponent(\"em\"),\n\t\t\"list-item\": getInternalComponent(\"listItem\"),\n\t\t\"o-list-item\": getInternalComponent(\"oListItem\"),\n\t\t\"group-list-item\": getInternalComponent(\"list\"),\n\t\t\"group-o-list-item\": getInternalComponent(\"oList\"),\n\t\timage: getInternalComponent(\"image\"),\n\t\tembed: getInternalComponent(\"embed\"),\n\t\thyperlink: getInternalComponent(\"hyperlink\"),\n\t\tlabel: getInternalComponent(\"label\"),\n\t\tspan: getInternalComponent(\"span\"),\n\t}\n})\n</script>\n\n<template>\n\t<PrismicRichTextSerialize\n\t\tv-if=\"children.length\"\n\t\t:children=\"children\"\n\t\t:internal-components=\"internalComponents\"\n\t/>\n\t<component v-else-if=\"fallback\" :is=\"fallback\" />\n</template>\n"],"mappings":""}
1
+ {"version":3,"file":"PrismicRichText.cjs","names":[],"sources":["../../../src/PrismicRichText/PrismicRichText.vue"],"sourcesContent":["<script lang=\"ts\" setup>\nimport type {\n\tLinkResolverFunction,\n\tRichTextField,\n\tRichTextNodeType,\n} from \"@prismicio/client\"\nimport { asTree } from \"@prismicio/client/richtext\"\nimport type { PropType } from \"vue\"\nimport { computed } from \"vue\"\n\nimport type { ComponentOrTagName, VueComponentShorthand } from \"../types\"\nimport { isVueComponent } from \"../types\"\nimport type {\n\tInternalVueRichTextComponents,\n\tVueRichTextComponent,\n\tVueRichTextSerializer,\n} from \"./types\"\n\nimport PrismicRichTextDefaultComponent from \"./PrismicRichTextDefaultComponent.vue\"\nimport PrismicRichTextSerialize from \"./PrismicRichTextSerialize.vue\"\n\n/** Props for `<PrismicRichText />`. */\nexport type PrismicRichTextProps = {\n\t/** The Prismic rich text field to render. */\n\tfield: RichTextField | null | undefined\n\n\t/**\n\t * The link resolver used to resolve links.\n\t *\n\t * @remarks\n\t * If your app uses route resolvers when querying for your Prismic\n\t * repository's content, a link resolver does not need to be provided.\n\t *\n\t * @see Learn about link resolvers and route resolvers {@link https://prismic.io/docs/routes}\n\t */\n\tlinkResolver?: LinkResolverFunction\n\n\t/**\n\t * An object that maps a rich text block type to a Vue component or a\n\t * shorthand definition.\n\t *\n\t * @example\n\t *\n\t * ```javascript\n\t * {\n\t * heading1: Heading1,\n\t * paragraph: { class: 'prose'},\n\t * strong: { as: 'em', class: 'font-bold' },\n\t * }\n\t * ```\n\t */\n\tcomponents?: VueRichTextSerializer\n\n\t/**\n\t * The value to be rendered when the field is empty. If a fallback is not\n\t * given, `null` will be rendered.\n\t */\n\tfallback?: ComponentOrTagName\n}\n\n// We're forced to declare props using the JavaScript syntax because `@vue/compiler-sfc`\n// has limitations for inferring types from complex objects.\nconst props = defineProps({\n\tfield: {\n\t\ttype: Array as unknown as PropType<PrismicRichTextProps[\"field\"]>,\n\t},\n\tlinkResolver: {\n\t\ttype: Function as PropType<PrismicRichTextProps[\"linkResolver\"]>,\n\t},\n\tcomponents: {\n\t\ttype: Object as PropType<PrismicRichTextProps[\"components\"]>,\n\t},\n\tfallback: {\n\t\ttype: [String, Object, Function] as PropType<\n\t\t\tPrismicRichTextProps[\"fallback\"]\n\t\t>,\n\t},\n})\ndefineOptions({ name: \"PrismicRichText\" })\n\nconst children = computed(() => {\n\treturn asTree(props.field || []).children\n})\n\nfunction getInternalComponent(type: keyof typeof RichTextNodeType) {\n\tconst maybeComponentOrShorthand = props.components?.[type] as\n\t\t| VueRichTextComponent\n\t\t| VueComponentShorthand\n\t\t| undefined\n\n\tif (isVueComponent(maybeComponentOrShorthand)) {\n\t\treturn { is: maybeComponentOrShorthand }\n\t}\n\n\treturn {\n\t\tis: PrismicRichTextDefaultComponent,\n\t\tlinkResolver: props.linkResolver,\n\t\tshorthand: maybeComponentOrShorthand,\n\t}\n}\n\nconst internalComponents = computed<InternalVueRichTextComponents>(() => {\n\treturn {\n\t\theading1: getInternalComponent(\"heading1\"),\n\t\theading2: getInternalComponent(\"heading2\"),\n\t\theading3: getInternalComponent(\"heading3\"),\n\t\theading4: getInternalComponent(\"heading4\"),\n\t\theading5: getInternalComponent(\"heading5\"),\n\t\theading6: getInternalComponent(\"heading6\"),\n\t\tparagraph: getInternalComponent(\"paragraph\"),\n\t\tpreformatted: getInternalComponent(\"preformatted\"),\n\t\tstrong: getInternalComponent(\"strong\"),\n\t\tem: getInternalComponent(\"em\"),\n\t\t\"list-item\": getInternalComponent(\"listItem\"),\n\t\t\"o-list-item\": getInternalComponent(\"oListItem\"),\n\t\t\"group-list-item\": getInternalComponent(\"list\"),\n\t\t\"group-o-list-item\": getInternalComponent(\"oList\"),\n\t\timage: getInternalComponent(\"image\"),\n\t\tembed: getInternalComponent(\"embed\"),\n\t\thyperlink: getInternalComponent(\"hyperlink\"),\n\t\tlabel: getInternalComponent(\"label\"),\n\t\tspan: getInternalComponent(\"span\"),\n\t}\n})\n</script>\n\n<template>\n\t<PrismicRichTextSerialize\n\t\tv-if=\"children.length\"\n\t\t:children=\"children\"\n\t\t:internal-components=\"internalComponents\"\n\t/>\n\t<component v-else-if=\"fallback\" :is=\"fallback\" />\n</template>\n"],"mappings":""}
@@ -1 +1 @@
1
- {"version":3,"file":"PrismicRichText.js","names":[],"sources":["../../../src/PrismicRichText/PrismicRichText.vue"],"sourcesContent":["<script lang=\"ts\" setup>\nimport type {\n\tLinkResolverFunction,\n\tRichTextField,\n\tRichTextNodeType,\n} from \"@prismicio/client\"\nimport { asTree } from \"@prismicio/client/richtext\"\nimport type { PropType } from \"vue\"\nimport { computed } from \"vue\"\n\nimport { type ComponentOrTagName, isVueComponent } from \"../types\"\nimport type {\n\tInternalVueRichTextComponent,\n\tVueRichTextSerializer,\n\tVueShorthand,\n} from \"./types\"\n\nimport PrismicRichTextDefaultComponent from \"./PrismicRichTextDefaultComponent.vue\"\nimport PrismicRichTextSerialize from \"./PrismicRichTextSerialize.vue\"\n\n/**\n * Props for `<PrismicRichText />`.\n */\nexport type PrismicRichTextProps = {\n\t/**\n\t * The Prismic rich text field to render.\n\t */\n\tfield: RichTextField | null | undefined\n\n\t/**\n\t * The link resolver used to resolve links.\n\t *\n\t * @remarks\n\t * If your app uses route resolvers when querying for your Prismic\n\t * repository's content, a link resolver does not need to be provided.\n\t *\n\t * @see Learn about link resolvers and route resolvers {@link https://prismic.io/docs/routes}\n\t */\n\tlinkResolver?: LinkResolverFunction\n\n\t/**\n\t * An object that maps a rich text block type to a Vue component or a\n\t * shorthand definition.\n\t *\n\t * @example\n\t *\n\t * ```javascript\n\t * {\n\t * heading1: Heading1,\n\t * paragraph: { class: 'prose'},\n\t * strong: { as: 'em', class: 'font-bold' },\n\t * }\n\t * ```\n\t */\n\tcomponents?: VueRichTextSerializer\n\n\t/**\n\t * The value to be rendered when the field is empty. If a fallback is not\n\t * given, `null` will be rendered.\n\t */\n\tfallback?: ComponentOrTagName\n}\n\n// We're forced to declare props using the JavaScript syntax because `@vue/compiler-sfc`\n// has limitations for inferring types from complex objects.\nconst props = defineProps({\n\tfield: {\n\t\ttype: Array as unknown as PropType<PrismicRichTextProps[\"field\"]>,\n\t},\n\tlinkResolver: {\n\t\ttype: Function as PropType<PrismicRichTextProps[\"linkResolver\"]>,\n\t},\n\tcomponents: {\n\t\ttype: Object as PropType<PrismicRichTextProps[\"components\"]>,\n\t},\n\tfallback: {\n\t\ttype: [String, Object, Function] as PropType<\n\t\t\tPrismicRichTextProps[\"fallback\"]\n\t\t>,\n\t},\n})\ndefineOptions({ name: \"PrismicRichText\" })\n\nconst children = computed(() => {\n\treturn asTree(props.field || []).children\n})\n\nfunction getInternalComponent(type: keyof typeof RichTextNodeType) {\n\tconst maybeComponentOrShorthand = props.components?.[type]\n\n\tif (isVueComponent(maybeComponentOrShorthand)) {\n\t\treturn { is: maybeComponentOrShorthand }\n\t}\n\n\treturn {\n\t\tis: PrismicRichTextDefaultComponent,\n\t\tprops: {\n\t\t\tlinkResolver: props.linkResolver,\n\t\t\tshorthand: maybeComponentOrShorthand as VueShorthand,\n\t\t},\n\t}\n}\n\nconst internalComponents = computed<InternalVueRichTextComponent>(() => {\n\treturn {\n\t\theading1: getInternalComponent(\"heading1\"),\n\t\theading2: getInternalComponent(\"heading2\"),\n\t\theading3: getInternalComponent(\"heading3\"),\n\t\theading4: getInternalComponent(\"heading4\"),\n\t\theading5: getInternalComponent(\"heading5\"),\n\t\theading6: getInternalComponent(\"heading6\"),\n\t\tparagraph: getInternalComponent(\"paragraph\"),\n\t\tpreformatted: getInternalComponent(\"preformatted\"),\n\t\tstrong: getInternalComponent(\"strong\"),\n\t\tem: getInternalComponent(\"em\"),\n\t\t\"list-item\": getInternalComponent(\"listItem\"),\n\t\t\"o-list-item\": getInternalComponent(\"oListItem\"),\n\t\t\"group-list-item\": getInternalComponent(\"list\"),\n\t\t\"group-o-list-item\": getInternalComponent(\"oList\"),\n\t\timage: getInternalComponent(\"image\"),\n\t\tembed: getInternalComponent(\"embed\"),\n\t\thyperlink: getInternalComponent(\"hyperlink\"),\n\t\tlabel: getInternalComponent(\"label\"),\n\t\tspan: getInternalComponent(\"span\"),\n\t}\n})\n</script>\n\n<template>\n\t<PrismicRichTextSerialize\n\t\tv-if=\"children.length\"\n\t\t:children=\"children\"\n\t\t:internal-components=\"internalComponents\"\n\t/>\n\t<component v-else-if=\"fallback\" :is=\"fallback\" />\n</template>\n"],"mappings":""}
1
+ {"version":3,"file":"PrismicRichText.js","names":[],"sources":["../../../src/PrismicRichText/PrismicRichText.vue"],"sourcesContent":["<script lang=\"ts\" setup>\nimport type {\n\tLinkResolverFunction,\n\tRichTextField,\n\tRichTextNodeType,\n} from \"@prismicio/client\"\nimport { asTree } from \"@prismicio/client/richtext\"\nimport type { PropType } from \"vue\"\nimport { computed } from \"vue\"\n\nimport type { ComponentOrTagName, VueComponentShorthand } from \"../types\"\nimport { isVueComponent } from \"../types\"\nimport type {\n\tInternalVueRichTextComponents,\n\tVueRichTextComponent,\n\tVueRichTextSerializer,\n} from \"./types\"\n\nimport PrismicRichTextDefaultComponent from \"./PrismicRichTextDefaultComponent.vue\"\nimport PrismicRichTextSerialize from \"./PrismicRichTextSerialize.vue\"\n\n/** Props for `<PrismicRichText />`. */\nexport type PrismicRichTextProps = {\n\t/** The Prismic rich text field to render. */\n\tfield: RichTextField | null | undefined\n\n\t/**\n\t * The link resolver used to resolve links.\n\t *\n\t * @remarks\n\t * If your app uses route resolvers when querying for your Prismic\n\t * repository's content, a link resolver does not need to be provided.\n\t *\n\t * @see Learn about link resolvers and route resolvers {@link https://prismic.io/docs/routes}\n\t */\n\tlinkResolver?: LinkResolverFunction\n\n\t/**\n\t * An object that maps a rich text block type to a Vue component or a\n\t * shorthand definition.\n\t *\n\t * @example\n\t *\n\t * ```javascript\n\t * {\n\t * heading1: Heading1,\n\t * paragraph: { class: 'prose'},\n\t * strong: { as: 'em', class: 'font-bold' },\n\t * }\n\t * ```\n\t */\n\tcomponents?: VueRichTextSerializer\n\n\t/**\n\t * The value to be rendered when the field is empty. If a fallback is not\n\t * given, `null` will be rendered.\n\t */\n\tfallback?: ComponentOrTagName\n}\n\n// We're forced to declare props using the JavaScript syntax because `@vue/compiler-sfc`\n// has limitations for inferring types from complex objects.\nconst props = defineProps({\n\tfield: {\n\t\ttype: Array as unknown as PropType<PrismicRichTextProps[\"field\"]>,\n\t},\n\tlinkResolver: {\n\t\ttype: Function as PropType<PrismicRichTextProps[\"linkResolver\"]>,\n\t},\n\tcomponents: {\n\t\ttype: Object as PropType<PrismicRichTextProps[\"components\"]>,\n\t},\n\tfallback: {\n\t\ttype: [String, Object, Function] as PropType<\n\t\t\tPrismicRichTextProps[\"fallback\"]\n\t\t>,\n\t},\n})\ndefineOptions({ name: \"PrismicRichText\" })\n\nconst children = computed(() => {\n\treturn asTree(props.field || []).children\n})\n\nfunction getInternalComponent(type: keyof typeof RichTextNodeType) {\n\tconst maybeComponentOrShorthand = props.components?.[type] as\n\t\t| VueRichTextComponent\n\t\t| VueComponentShorthand\n\t\t| undefined\n\n\tif (isVueComponent(maybeComponentOrShorthand)) {\n\t\treturn { is: maybeComponentOrShorthand }\n\t}\n\n\treturn {\n\t\tis: PrismicRichTextDefaultComponent,\n\t\tlinkResolver: props.linkResolver,\n\t\tshorthand: maybeComponentOrShorthand,\n\t}\n}\n\nconst internalComponents = computed<InternalVueRichTextComponents>(() => {\n\treturn {\n\t\theading1: getInternalComponent(\"heading1\"),\n\t\theading2: getInternalComponent(\"heading2\"),\n\t\theading3: getInternalComponent(\"heading3\"),\n\t\theading4: getInternalComponent(\"heading4\"),\n\t\theading5: getInternalComponent(\"heading5\"),\n\t\theading6: getInternalComponent(\"heading6\"),\n\t\tparagraph: getInternalComponent(\"paragraph\"),\n\t\tpreformatted: getInternalComponent(\"preformatted\"),\n\t\tstrong: getInternalComponent(\"strong\"),\n\t\tem: getInternalComponent(\"em\"),\n\t\t\"list-item\": getInternalComponent(\"listItem\"),\n\t\t\"o-list-item\": getInternalComponent(\"oListItem\"),\n\t\t\"group-list-item\": getInternalComponent(\"list\"),\n\t\t\"group-o-list-item\": getInternalComponent(\"oList\"),\n\t\timage: getInternalComponent(\"image\"),\n\t\tembed: getInternalComponent(\"embed\"),\n\t\thyperlink: getInternalComponent(\"hyperlink\"),\n\t\tlabel: getInternalComponent(\"label\"),\n\t\tspan: getInternalComponent(\"span\"),\n\t}\n})\n</script>\n\n<template>\n\t<PrismicRichTextSerialize\n\t\tv-if=\"children.length\"\n\t\t:children=\"children\"\n\t\t:internal-components=\"internalComponents\"\n\t/>\n\t<component v-else-if=\"fallback\" :is=\"fallback\" />\n</template>\n"],"mappings":""}
@@ -1,17 +1,13 @@
1
1
  import { ComponentOrTagName } from "../types.js";
2
2
  import { VueRichTextSerializer } from "./types.js";
3
- import * as vue4 from "vue";
3
+ import * as vue0 from "vue";
4
4
  import { PropType } from "vue";
5
5
  import { LinkResolverFunction, RichTextField } from "@prismicio/client";
6
6
 
7
7
  //#region src/PrismicRichText/PrismicRichText.vue.d.ts
8
- /**
9
- * Props for `<PrismicRichText />`.
10
- */
8
+ /** Props for `<PrismicRichText />`. */
11
9
  type PrismicRichTextProps = {
12
- /**
13
- * The Prismic rich text field to render.
14
- */
10
+ /** The Prismic rich text field to render. */
15
11
  field: RichTextField | null | undefined;
16
12
  /**
17
13
  * The link resolver used to resolve links.
@@ -44,7 +40,7 @@ type PrismicRichTextProps = {
44
40
  */
45
41
  fallback?: ComponentOrTagName;
46
42
  };
47
- declare const __VLS_export: vue4.DefineComponent<vue4.ExtractPropTypes<{
43
+ declare const __VLS_export: vue0.DefineComponent<vue0.ExtractPropTypes<{
48
44
  field: {
49
45
  type: PropType<PrismicRichTextProps["field"]>;
50
46
  };
@@ -57,7 +53,7 @@ declare const __VLS_export: vue4.DefineComponent<vue4.ExtractPropTypes<{
57
53
  fallback: {
58
54
  type: PropType<PrismicRichTextProps["fallback"]>;
59
55
  };
60
- }>, {}, {}, {}, {}, vue4.ComponentOptionsMixin, vue4.ComponentOptionsMixin, {}, string, vue4.PublicProps, Readonly<vue4.ExtractPropTypes<{
56
+ }>, {}, {}, {}, {}, vue0.ComponentOptionsMixin, vue0.ComponentOptionsMixin, {}, string, vue0.PublicProps, Readonly<vue0.ExtractPropTypes<{
61
57
  field: {
62
58
  type: PropType<PrismicRichTextProps["field"]>;
63
59
  };
@@ -70,7 +66,7 @@ declare const __VLS_export: vue4.DefineComponent<vue4.ExtractPropTypes<{
70
66
  fallback: {
71
67
  type: PropType<PrismicRichTextProps["fallback"]>;
72
68
  };
73
- }>> & Readonly<{}>, {}, {}, {}, {}, string, vue4.ComponentProvideOptions, true, {}, any>;
69
+ }>> & Readonly<{}>, {}, {}, {}, {}, string, vue0.ComponentProvideOptions, true, {}, any>;
74
70
  declare const _default: typeof __VLS_export;
75
71
  //#endregion
76
72
  export { PrismicRichTextProps, _default };
@@ -1 +1 @@
1
- {"version":3,"file":"PrismicRichText.vue.d.ts","names":[],"sources":["../../../src/PrismicRichText/PrismicRichText.vue"],"sourcesContent":[],"mappings":";;;;;;;;;;AAgKY,KAAA,oBAAA,GAAoB;EAIxB;;;EAiCI,KAAA,EAjCJ,aAiCI,GAAA,IAAA,GAAA,SAAA;EAAkB;AAC7B;;;;;;;;EA2HqC,YAAA,CAAA,EAlJtB,oBAkJsB;EAAQ;;;;;;;;;;;;;;eAlIhC;;;;AAsHI;aAhHN;;cAgHN,mBAAY,gBAY4B,IAAA,CAZ5B;;UAGU,SAAS;;;UAGjB,SAAS;;;UAGX,SAAS;;;UAGW,SACnC;;oBAbe,IAAA,CAAA,qBAAA,qEAY4B,IAAA,CAAA;;UATlB,SAAS;;;UAGjB,SAAS;;;UAGX,SAAS;;;UAGW,SACnC;;;cAbe,iBAkBU"}
1
+ {"version":3,"file":"PrismicRichText.vue.d.ts","names":[],"sources":["../../../src/PrismicRichText/PrismicRichText.vue"],"sourcesContent":[],"mappings":";;;;;;;;KA6JY,oBAAA;;EAAA,KAAA,EAEJ,aAFI,GAAoB,IAAA,GAAA,SAAA;EAExB;;;;;AAkCP;;;;EAsHmB,YAAA,CAAA,EA7IJ,oBA6II;EAGO;;;;;;;;;;;;;;EAIxB,UAAA,CAAA,EApIW,qBAoIX;EADmC;;;;aA7H1B;;cAiHN,YAAY,OAAA,eAAA,CAY4B,IAAA,CAZ5B,gBAAA,CAAA;EAAA,KAAA,EAAA;UAGU,SAAS;;;UAGjB,SAAS;;;UAGX,SAAS;;;UAGW,SACnC;;oBAbe,IAAA,CAAA,qBAAA,qEAY4B,IAAA,CAAA;;UATlB,SAAS;;;UAGjB,SAAS;;;UAGX,SAAS;;;UAGW,SACnC;;;cAbe,iBAkBU"}
@@ -28,10 +28,8 @@ var PrismicRichText_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ *
28
28
  if (require_types.isVueComponent(maybeComponentOrShorthand)) return { is: maybeComponentOrShorthand };
29
29
  return {
30
30
  is: require_PrismicRichTextDefaultComponent.default,
31
- props: {
32
- linkResolver: props.linkResolver,
33
- shorthand: maybeComponentOrShorthand
34
- }
31
+ linkResolver: props.linkResolver,
32
+ shorthand: maybeComponentOrShorthand
35
33
  };
36
34
  }
37
35
  const internalComponents = (0, vue.computed)(() => {
@@ -1 +1 @@
1
- {"version":3,"file":"PrismicRichText.vue_vue_type_script_setup_true_lang.cjs","names":[],"sources":["../../../src/PrismicRichText/PrismicRichText.vue"],"sourcesContent":["<script lang=\"ts\" setup>\nimport type {\n\tLinkResolverFunction,\n\tRichTextField,\n\tRichTextNodeType,\n} from \"@prismicio/client\"\nimport { asTree } from \"@prismicio/client/richtext\"\nimport type { PropType } from \"vue\"\nimport { computed } from \"vue\"\n\nimport { type ComponentOrTagName, isVueComponent } from \"../types\"\nimport type {\n\tInternalVueRichTextComponent,\n\tVueRichTextSerializer,\n\tVueShorthand,\n} from \"./types\"\n\nimport PrismicRichTextDefaultComponent from \"./PrismicRichTextDefaultComponent.vue\"\nimport PrismicRichTextSerialize from \"./PrismicRichTextSerialize.vue\"\n\n/**\n * Props for `<PrismicRichText />`.\n */\nexport type PrismicRichTextProps = {\n\t/**\n\t * The Prismic rich text field to render.\n\t */\n\tfield: RichTextField | null | undefined\n\n\t/**\n\t * The link resolver used to resolve links.\n\t *\n\t * @remarks\n\t * If your app uses route resolvers when querying for your Prismic\n\t * repository's content, a link resolver does not need to be provided.\n\t *\n\t * @see Learn about link resolvers and route resolvers {@link https://prismic.io/docs/routes}\n\t */\n\tlinkResolver?: LinkResolverFunction\n\n\t/**\n\t * An object that maps a rich text block type to a Vue component or a\n\t * shorthand definition.\n\t *\n\t * @example\n\t *\n\t * ```javascript\n\t * {\n\t * heading1: Heading1,\n\t * paragraph: { class: 'prose'},\n\t * strong: { as: 'em', class: 'font-bold' },\n\t * }\n\t * ```\n\t */\n\tcomponents?: VueRichTextSerializer\n\n\t/**\n\t * The value to be rendered when the field is empty. If a fallback is not\n\t * given, `null` will be rendered.\n\t */\n\tfallback?: ComponentOrTagName\n}\n\n// We're forced to declare props using the JavaScript syntax because `@vue/compiler-sfc`\n// has limitations for inferring types from complex objects.\nconst props = defineProps({\n\tfield: {\n\t\ttype: Array as unknown as PropType<PrismicRichTextProps[\"field\"]>,\n\t},\n\tlinkResolver: {\n\t\ttype: Function as PropType<PrismicRichTextProps[\"linkResolver\"]>,\n\t},\n\tcomponents: {\n\t\ttype: Object as PropType<PrismicRichTextProps[\"components\"]>,\n\t},\n\tfallback: {\n\t\ttype: [String, Object, Function] as PropType<\n\t\t\tPrismicRichTextProps[\"fallback\"]\n\t\t>,\n\t},\n})\ndefineOptions({ name: \"PrismicRichText\" })\n\nconst children = computed(() => {\n\treturn asTree(props.field || []).children\n})\n\nfunction getInternalComponent(type: keyof typeof RichTextNodeType) {\n\tconst maybeComponentOrShorthand = props.components?.[type]\n\n\tif (isVueComponent(maybeComponentOrShorthand)) {\n\t\treturn { is: maybeComponentOrShorthand }\n\t}\n\n\treturn {\n\t\tis: PrismicRichTextDefaultComponent,\n\t\tprops: {\n\t\t\tlinkResolver: props.linkResolver,\n\t\t\tshorthand: maybeComponentOrShorthand as VueShorthand,\n\t\t},\n\t}\n}\n\nconst internalComponents = computed<InternalVueRichTextComponent>(() => {\n\treturn {\n\t\theading1: getInternalComponent(\"heading1\"),\n\t\theading2: getInternalComponent(\"heading2\"),\n\t\theading3: getInternalComponent(\"heading3\"),\n\t\theading4: getInternalComponent(\"heading4\"),\n\t\theading5: getInternalComponent(\"heading5\"),\n\t\theading6: getInternalComponent(\"heading6\"),\n\t\tparagraph: getInternalComponent(\"paragraph\"),\n\t\tpreformatted: getInternalComponent(\"preformatted\"),\n\t\tstrong: getInternalComponent(\"strong\"),\n\t\tem: getInternalComponent(\"em\"),\n\t\t\"list-item\": getInternalComponent(\"listItem\"),\n\t\t\"o-list-item\": getInternalComponent(\"oListItem\"),\n\t\t\"group-list-item\": getInternalComponent(\"list\"),\n\t\t\"group-o-list-item\": getInternalComponent(\"oList\"),\n\t\timage: getInternalComponent(\"image\"),\n\t\tembed: getInternalComponent(\"embed\"),\n\t\thyperlink: getInternalComponent(\"hyperlink\"),\n\t\tlabel: getInternalComponent(\"label\"),\n\t\tspan: getInternalComponent(\"span\"),\n\t}\n})\n</script>\n\n<template>\n\t<PrismicRichTextSerialize\n\t\tv-if=\"children.length\"\n\t\t:children=\"children\"\n\t\t:internal-components=\"internalComponents\"\n\t/>\n\t<component v-else-if=\"fallback\" :is=\"fallback\" />\n</template>\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;EAiEA,MAAM,QAAQ;EAkBd,MAAM,mCAA0B;AAC/B,kDAAc,MAAM,SAAS,EAAE,CAAC,CAAC;IACjC;EAED,SAAS,qBAAqB,MAAqC;GAClE,MAAM,4BAA4B,MAAM,aAAa;AAErD,OAAI,6BAAe,0BAA0B,CAC5C,QAAO,EAAE,IAAI,2BAA0B;AAGxC,UAAO;IACN,IAAI;IACJ,OAAO;KACN,cAAc,MAAM;KACpB,WAAW;KACX;IACF;;EAGD,MAAM,6CAAkE;AACvE,UAAO;IACN,UAAU,qBAAqB,WAAW;IAC1C,UAAU,qBAAqB,WAAW;IAC1C,UAAU,qBAAqB,WAAW;IAC1C,UAAU,qBAAqB,WAAW;IAC1C,UAAU,qBAAqB,WAAW;IAC1C,UAAU,qBAAqB,WAAW;IAC1C,WAAW,qBAAqB,YAAY;IAC5C,cAAc,qBAAqB,eAAe;IAClD,QAAQ,qBAAqB,SAAS;IACtC,IAAI,qBAAqB,KAAK;IAC9B,aAAa,qBAAqB,WAAW;IAC7C,eAAe,qBAAqB,YAAY;IAChD,mBAAmB,qBAAqB,OAAO;IAC/C,qBAAqB,qBAAqB,QAAQ;IAClD,OAAO,qBAAqB,QAAQ;IACpC,OAAO,qBAAqB,QAAQ;IACpC,WAAW,qBAAqB,YAAY;IAC5C,OAAO,qBAAqB,QAAQ;IACpC,MAAM,qBAAqB,OAAO;IACnC;IACA;;UAKO,SAAA,MAAS,qDAGd,0CAAA;;IAFA,UAAU,SAAA;IACV,uBAAqB,mBAAA;uDAED,QAAA,wFAAe,QAAA,SAAQ,EAAA,EAAA,KAAA,GAAA,CAAA"}
1
+ {"version":3,"file":"PrismicRichText.vue_vue_type_script_setup_true_lang.cjs","names":[],"sources":["../../../src/PrismicRichText/PrismicRichText.vue"],"sourcesContent":["<script lang=\"ts\" setup>\nimport type {\n\tLinkResolverFunction,\n\tRichTextField,\n\tRichTextNodeType,\n} from \"@prismicio/client\"\nimport { asTree } from \"@prismicio/client/richtext\"\nimport type { PropType } from \"vue\"\nimport { computed } from \"vue\"\n\nimport type { ComponentOrTagName, VueComponentShorthand } from \"../types\"\nimport { isVueComponent } from \"../types\"\nimport type {\n\tInternalVueRichTextComponents,\n\tVueRichTextComponent,\n\tVueRichTextSerializer,\n} from \"./types\"\n\nimport PrismicRichTextDefaultComponent from \"./PrismicRichTextDefaultComponent.vue\"\nimport PrismicRichTextSerialize from \"./PrismicRichTextSerialize.vue\"\n\n/** Props for `<PrismicRichText />`. */\nexport type PrismicRichTextProps = {\n\t/** The Prismic rich text field to render. */\n\tfield: RichTextField | null | undefined\n\n\t/**\n\t * The link resolver used to resolve links.\n\t *\n\t * @remarks\n\t * If your app uses route resolvers when querying for your Prismic\n\t * repository's content, a link resolver does not need to be provided.\n\t *\n\t * @see Learn about link resolvers and route resolvers {@link https://prismic.io/docs/routes}\n\t */\n\tlinkResolver?: LinkResolverFunction\n\n\t/**\n\t * An object that maps a rich text block type to a Vue component or a\n\t * shorthand definition.\n\t *\n\t * @example\n\t *\n\t * ```javascript\n\t * {\n\t * heading1: Heading1,\n\t * paragraph: { class: 'prose'},\n\t * strong: { as: 'em', class: 'font-bold' },\n\t * }\n\t * ```\n\t */\n\tcomponents?: VueRichTextSerializer\n\n\t/**\n\t * The value to be rendered when the field is empty. If a fallback is not\n\t * given, `null` will be rendered.\n\t */\n\tfallback?: ComponentOrTagName\n}\n\n// We're forced to declare props using the JavaScript syntax because `@vue/compiler-sfc`\n// has limitations for inferring types from complex objects.\nconst props = defineProps({\n\tfield: {\n\t\ttype: Array as unknown as PropType<PrismicRichTextProps[\"field\"]>,\n\t},\n\tlinkResolver: {\n\t\ttype: Function as PropType<PrismicRichTextProps[\"linkResolver\"]>,\n\t},\n\tcomponents: {\n\t\ttype: Object as PropType<PrismicRichTextProps[\"components\"]>,\n\t},\n\tfallback: {\n\t\ttype: [String, Object, Function] as PropType<\n\t\t\tPrismicRichTextProps[\"fallback\"]\n\t\t>,\n\t},\n})\ndefineOptions({ name: \"PrismicRichText\" })\n\nconst children = computed(() => {\n\treturn asTree(props.field || []).children\n})\n\nfunction getInternalComponent(type: keyof typeof RichTextNodeType) {\n\tconst maybeComponentOrShorthand = props.components?.[type] as\n\t\t| VueRichTextComponent\n\t\t| VueComponentShorthand\n\t\t| undefined\n\n\tif (isVueComponent(maybeComponentOrShorthand)) {\n\t\treturn { is: maybeComponentOrShorthand }\n\t}\n\n\treturn {\n\t\tis: PrismicRichTextDefaultComponent,\n\t\tlinkResolver: props.linkResolver,\n\t\tshorthand: maybeComponentOrShorthand,\n\t}\n}\n\nconst internalComponents = computed<InternalVueRichTextComponents>(() => {\n\treturn {\n\t\theading1: getInternalComponent(\"heading1\"),\n\t\theading2: getInternalComponent(\"heading2\"),\n\t\theading3: getInternalComponent(\"heading3\"),\n\t\theading4: getInternalComponent(\"heading4\"),\n\t\theading5: getInternalComponent(\"heading5\"),\n\t\theading6: getInternalComponent(\"heading6\"),\n\t\tparagraph: getInternalComponent(\"paragraph\"),\n\t\tpreformatted: getInternalComponent(\"preformatted\"),\n\t\tstrong: getInternalComponent(\"strong\"),\n\t\tem: getInternalComponent(\"em\"),\n\t\t\"list-item\": getInternalComponent(\"listItem\"),\n\t\t\"o-list-item\": getInternalComponent(\"oListItem\"),\n\t\t\"group-list-item\": getInternalComponent(\"list\"),\n\t\t\"group-o-list-item\": getInternalComponent(\"oList\"),\n\t\timage: getInternalComponent(\"image\"),\n\t\tembed: getInternalComponent(\"embed\"),\n\t\thyperlink: getInternalComponent(\"hyperlink\"),\n\t\tlabel: getInternalComponent(\"label\"),\n\t\tspan: getInternalComponent(\"span\"),\n\t}\n})\n</script>\n\n<template>\n\t<PrismicRichTextSerialize\n\t\tv-if=\"children.length\"\n\t\t:children=\"children\"\n\t\t:internal-components=\"internalComponents\"\n\t/>\n\t<component v-else-if=\"fallback\" :is=\"fallback\" />\n</template>\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;EA8DA,MAAM,QAAQ;EAkBd,MAAM,mCAA0B;AAC/B,kDAAc,MAAM,SAAS,EAAE,CAAC,CAAC;IACjC;EAED,SAAS,qBAAqB,MAAqC;GAClE,MAAM,4BAA4B,MAAM,aAAa;AAKrD,OAAI,6BAAe,0BAA0B,CAC5C,QAAO,EAAE,IAAI,2BAA0B;AAGxC,UAAO;IACN,IAAI;IACJ,cAAc,MAAM;IACpB,WAAW;IACZ;;EAGD,MAAM,6CAAmE;AACxE,UAAO;IACN,UAAU,qBAAqB,WAAW;IAC1C,UAAU,qBAAqB,WAAW;IAC1C,UAAU,qBAAqB,WAAW;IAC1C,UAAU,qBAAqB,WAAW;IAC1C,UAAU,qBAAqB,WAAW;IAC1C,UAAU,qBAAqB,WAAW;IAC1C,WAAW,qBAAqB,YAAY;IAC5C,cAAc,qBAAqB,eAAe;IAClD,QAAQ,qBAAqB,SAAS;IACtC,IAAI,qBAAqB,KAAK;IAC9B,aAAa,qBAAqB,WAAW;IAC7C,eAAe,qBAAqB,YAAY;IAChD,mBAAmB,qBAAqB,OAAO;IAC/C,qBAAqB,qBAAqB,QAAQ;IAClD,OAAO,qBAAqB,QAAQ;IACpC,OAAO,qBAAqB,QAAQ;IACpC,WAAW,qBAAqB,YAAY;IAC5C,OAAO,qBAAqB,QAAQ;IACpC,MAAM,qBAAqB,OAAO;IACnC;IACA;;UAKO,SAAA,MAAS,qDAGd,0CAAA;;IAFA,UAAU,SAAA;IACV,uBAAqB,mBAAA;uDAED,QAAA,wFAAe,QAAA,SAAQ,EAAA,EAAA,KAAA,GAAA,CAAA"}
@@ -28,10 +28,8 @@ var PrismicRichText_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ *
28
28
  if (isVueComponent(maybeComponentOrShorthand)) return { is: maybeComponentOrShorthand };
29
29
  return {
30
30
  is: PrismicRichTextDefaultComponent_default,
31
- props: {
32
- linkResolver: props.linkResolver,
33
- shorthand: maybeComponentOrShorthand
34
- }
31
+ linkResolver: props.linkResolver,
32
+ shorthand: maybeComponentOrShorthand
35
33
  };
36
34
  }
37
35
  const internalComponents = computed(() => {