@prismicio/vue 6.1.5 → 6.2.0-canary.5a93fe7
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/PrismicImage.cjs +1 -2
- package/dist/PrismicImage.cjs.map +1 -1
- package/dist/PrismicImage.js +1 -2
- package/dist/PrismicImage.js.map +1 -1
- package/dist/PrismicImage.vue.d.cts +2 -4
- package/dist/PrismicImage.vue.d.cts.map +1 -1
- package/dist/PrismicImage.vue.d.ts +2 -4
- package/dist/PrismicImage.vue.d.ts.map +1 -1
- package/dist/PrismicImage.vue_vue_type_script_setup_true_lang.cjs +1 -2
- package/dist/PrismicImage.vue_vue_type_script_setup_true_lang.cjs.map +1 -1
- package/dist/PrismicImage.vue_vue_type_script_setup_true_lang.js +1 -2
- package/dist/PrismicImage.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/PrismicLink.cjs +1 -2
- package/dist/PrismicLink.cjs.map +1 -1
- package/dist/PrismicLink.js +1 -2
- package/dist/PrismicLink.js.map +1 -1
- package/dist/PrismicLink.vue.d.cts +4 -6
- package/dist/PrismicLink.vue.d.cts.map +1 -1
- package/dist/PrismicLink.vue.d.ts +4 -6
- package/dist/PrismicLink.vue.d.ts.map +1 -1
- package/dist/PrismicLink.vue_vue_type_script_setup_true_lang.cjs +1 -2
- package/dist/PrismicLink.vue_vue_type_script_setup_true_lang.cjs.map +1 -1
- package/dist/PrismicLink.vue_vue_type_script_setup_true_lang.js +1 -2
- package/dist/PrismicLink.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/PrismicRichText/PrismicRichText.cjs +1 -2
- package/dist/PrismicRichText/PrismicRichText.cjs.map +1 -1
- package/dist/PrismicRichText/PrismicRichText.js +1 -2
- package/dist/PrismicRichText/PrismicRichText.js.map +1 -1
- package/dist/PrismicRichText/PrismicRichText.vue.d.cts +2 -4
- package/dist/PrismicRichText/PrismicRichText.vue.d.cts.map +1 -1
- package/dist/PrismicRichText/PrismicRichText.vue.d.ts +2 -4
- package/dist/PrismicRichText/PrismicRichText.vue.d.ts.map +1 -1
- package/dist/PrismicRichText/PrismicRichText.vue_vue_type_script_setup_true_lang.cjs +1 -2
- package/dist/PrismicRichText/PrismicRichText.vue_vue_type_script_setup_true_lang.cjs.map +1 -1
- package/dist/PrismicRichText/PrismicRichText.vue_vue_type_script_setup_true_lang.js +1 -2
- package/dist/PrismicRichText/PrismicRichText.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/PrismicRichText/PrismicRichTextDefaultComponent.cjs +1 -2
- package/dist/PrismicRichText/PrismicRichTextDefaultComponent.cjs.map +1 -1
- package/dist/PrismicRichText/PrismicRichTextDefaultComponent.js +1 -2
- package/dist/PrismicRichText/PrismicRichTextDefaultComponent.js.map +1 -1
- package/dist/PrismicRichText/PrismicRichTextDefaultComponent.vue_vue_type_script_setup_true_lang.cjs +1 -2
- package/dist/PrismicRichText/PrismicRichTextDefaultComponent.vue_vue_type_script_setup_true_lang.cjs.map +1 -1
- package/dist/PrismicRichText/PrismicRichTextDefaultComponent.vue_vue_type_script_setup_true_lang.js +1 -2
- package/dist/PrismicRichText/PrismicRichTextDefaultComponent.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/PrismicRichText/PrismicRichTextSerialize.cjs +1 -2
- package/dist/PrismicRichText/PrismicRichTextSerialize.cjs.map +1 -1
- package/dist/PrismicRichText/PrismicRichTextSerialize.js +1 -2
- package/dist/PrismicRichText/PrismicRichTextSerialize.js.map +1 -1
- package/dist/PrismicRichText/PrismicRichTextSerialize.vue_vue_type_script_setup_true_lang.cjs +1 -2
- package/dist/PrismicRichText/PrismicRichTextSerialize.vue_vue_type_script_setup_true_lang.cjs.map +1 -1
- package/dist/PrismicRichText/PrismicRichTextSerialize.vue_vue_type_script_setup_true_lang.js +1 -2
- package/dist/PrismicRichText/PrismicRichTextSerialize.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/PrismicRichText/getRichTextComponentProps.cjs +1 -2
- package/dist/PrismicRichText/getRichTextComponentProps.d.cts +2 -4
- package/dist/PrismicRichText/getRichTextComponentProps.d.cts.map +1 -1
- package/dist/PrismicRichText/getRichTextComponentProps.d.ts +2 -4
- package/dist/PrismicRichText/getRichTextComponentProps.d.ts.map +1 -1
- package/dist/PrismicRichText/getRichTextComponentProps.js +1 -2
- package/dist/PrismicRichText/types.d.cts +3 -6
- package/dist/PrismicRichText/types.d.cts.map +1 -1
- package/dist/PrismicRichText/types.d.ts +3 -6
- package/dist/PrismicRichText/types.d.ts.map +1 -1
- package/dist/PrismicTable/PrismicTable.cjs +1 -2
- package/dist/PrismicTable/PrismicTable.cjs.map +1 -1
- package/dist/PrismicTable/PrismicTable.js +1 -2
- package/dist/PrismicTable/PrismicTable.js.map +1 -1
- package/dist/PrismicTable/PrismicTable.vue.d.cts +2 -4
- package/dist/PrismicTable/PrismicTable.vue.d.cts.map +1 -1
- package/dist/PrismicTable/PrismicTable.vue.d.ts +2 -4
- package/dist/PrismicTable/PrismicTable.vue.d.ts.map +1 -1
- package/dist/PrismicTable/PrismicTable.vue_vue_type_script_setup_true_lang.cjs +1 -2
- package/dist/PrismicTable/PrismicTable.vue_vue_type_script_setup_true_lang.cjs.map +1 -1
- package/dist/PrismicTable/PrismicTable.vue_vue_type_script_setup_true_lang.js +1 -2
- package/dist/PrismicTable/PrismicTable.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/PrismicTable/PrismicTableDefaultComponents.cjs +1 -2
- package/dist/PrismicTable/PrismicTableDefaultComponents.js +1 -2
- package/dist/PrismicTable/PrismicTableRow.cjs +1 -2
- package/dist/PrismicTable/PrismicTableRow.cjs.map +1 -1
- package/dist/PrismicTable/PrismicTableRow.js +1 -2
- package/dist/PrismicTable/PrismicTableRow.js.map +1 -1
- package/dist/PrismicTable/PrismicTableRow.vue_vue_type_script_setup_true_lang.cjs +1 -2
- package/dist/PrismicTable/PrismicTableRow.vue_vue_type_script_setup_true_lang.cjs.map +1 -1
- package/dist/PrismicTable/PrismicTableRow.vue_vue_type_script_setup_true_lang.js +1 -2
- package/dist/PrismicTable/PrismicTableRow.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/PrismicTable/getTableComponentProps.cjs +1 -2
- package/dist/PrismicTable/getTableComponentProps.d.cts +7 -8
- package/dist/PrismicTable/getTableComponentProps.d.cts.map +1 -1
- package/dist/PrismicTable/getTableComponentProps.d.ts +7 -8
- package/dist/PrismicTable/getTableComponentProps.d.ts.map +1 -1
- package/dist/PrismicTable/getTableComponentProps.js +1 -2
- package/dist/PrismicTable/types.d.cts +1 -4
- package/dist/PrismicTable/types.d.cts.map +1 -1
- package/dist/PrismicTable/types.d.ts +1 -4
- package/dist/PrismicTable/types.d.ts.map +1 -1
- package/dist/PrismicText.cjs +1 -2
- package/dist/PrismicText.cjs.map +1 -1
- package/dist/PrismicText.js +1 -2
- package/dist/PrismicText.js.map +1 -1
- package/dist/PrismicText.vue.d.cts +2 -4
- package/dist/PrismicText.vue.d.cts.map +1 -1
- package/dist/PrismicText.vue.d.ts +2 -4
- package/dist/PrismicText.vue.d.ts.map +1 -1
- package/dist/PrismicText.vue_vue_type_script_setup_true_lang.cjs +1 -2
- package/dist/PrismicText.vue_vue_type_script_setup_true_lang.cjs.map +1 -1
- package/dist/PrismicText.vue_vue_type_script_setup_true_lang.js +1 -2
- package/dist/PrismicText.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/SliceSimulator.cjs +1 -2
- package/dist/SliceSimulator.cjs.map +1 -1
- package/dist/SliceSimulator.js +1 -2
- package/dist/SliceSimulator.js.map +1 -1
- package/dist/SliceSimulator.vue.d.cts +2 -4
- package/dist/SliceSimulator.vue.d.cts.map +1 -1
- package/dist/SliceSimulator.vue.d.ts +2 -4
- package/dist/SliceSimulator.vue.d.ts.map +1 -1
- package/dist/SliceSimulator.vue_vue_type_script_setup_true_lang.cjs +1 -2
- package/dist/SliceSimulator.vue_vue_type_script_setup_true_lang.cjs.map +1 -1
- package/dist/SliceSimulator.vue_vue_type_script_setup_true_lang.js +1 -2
- package/dist/SliceSimulator.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/SliceZone/SliceBoundary.cjs +11 -0
- package/dist/SliceZone/SliceBoundary.cjs.map +1 -0
- package/dist/SliceZone/SliceBoundary.js +11 -0
- package/dist/SliceZone/SliceBoundary.js.map +1 -0
- package/dist/SliceZone/SliceZone.cjs +1 -2
- package/dist/SliceZone/SliceZone.cjs.map +1 -1
- package/dist/SliceZone/SliceZone.js +1 -2
- package/dist/SliceZone/SliceZone.js.map +1 -1
- package/dist/SliceZone/SliceZone.vue.d.cts +2 -4
- package/dist/SliceZone/SliceZone.vue.d.cts.map +1 -1
- package/dist/SliceZone/SliceZone.vue.d.ts +2 -4
- package/dist/SliceZone/SliceZone.vue.d.ts.map +1 -1
- package/dist/SliceZone/SliceZone.vue_vue_type_script_setup_true_lang.cjs +17 -4
- package/dist/SliceZone/SliceZone.vue_vue_type_script_setup_true_lang.cjs.map +1 -1
- package/dist/SliceZone/SliceZone.vue_vue_type_script_setup_true_lang.js +18 -5
- package/dist/SliceZone/SliceZone.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/SliceZone/TODOSliceComponent.cjs +1 -2
- package/dist/SliceZone/TODOSliceComponent.cjs.map +1 -1
- package/dist/SliceZone/TODOSliceComponent.d.cts +1 -4
- package/dist/SliceZone/TODOSliceComponent.d.cts.map +1 -1
- package/dist/SliceZone/TODOSliceComponent.d.ts +1 -4
- package/dist/SliceZone/TODOSliceComponent.d.ts.map +1 -1
- package/dist/SliceZone/TODOSliceComponent.js +1 -2
- package/dist/SliceZone/defineSliceZoneComponents.cjs +1 -2
- package/dist/SliceZone/defineSliceZoneComponents.d.cts +1 -4
- package/dist/SliceZone/defineSliceZoneComponents.d.cts.map +1 -1
- package/dist/SliceZone/defineSliceZoneComponents.d.ts +1 -4
- package/dist/SliceZone/defineSliceZoneComponents.d.ts.map +1 -1
- package/dist/SliceZone/defineSliceZoneComponents.js +1 -2
- package/dist/SliceZone/getSliceComponentProps.cjs +1 -2
- package/dist/SliceZone/getSliceComponentProps.d.cts +2 -4
- package/dist/SliceZone/getSliceComponentProps.d.cts.map +1 -1
- package/dist/SliceZone/getSliceComponentProps.d.ts +2 -4
- package/dist/SliceZone/getSliceComponentProps.d.ts.map +1 -1
- package/dist/SliceZone/getSliceComponentProps.js +1 -2
- package/dist/SliceZone/types.d.cts +8 -10
- package/dist/SliceZone/types.d.cts.map +1 -1
- package/dist/SliceZone/types.d.ts +8 -10
- package/dist/SliceZone/types.d.ts.map +1 -1
- package/dist/_virtual/_rolldown/runtime.cjs +1 -2
- package/dist/_virtual/_rolldown/runtime.js +1 -2
- package/dist/createPrismic.cjs +1 -2
- package/dist/createPrismic.d.cts +5 -7
- package/dist/createPrismic.d.cts.map +1 -1
- package/dist/createPrismic.d.ts +5 -7
- package/dist/createPrismic.d.ts.map +1 -1
- package/dist/createPrismic.js +1 -2
- package/dist/lib/devMsg.cjs +1 -2
- package/dist/lib/devMsg.js +1 -2
- package/dist/lib/isInternalURL.cjs +1 -2
- package/dist/lib/isInternalURL.js +1 -2
- package/dist/package.cjs +2 -3
- package/dist/package.js +2 -3
- package/dist/types.cjs +1 -2
- package/dist/types.d.cts +3 -5
- package/dist/types.d.cts.map +1 -1
- package/dist/types.d.ts +3 -5
- package/dist/types.d.ts.map +1 -1
- package/dist/types.js +1 -2
- package/package.json +14 -14
- package/src/SliceZone/SliceBoundary.ts +10 -0
- package/src/SliceZone/SliceZone.vue +13 -10
|
@@ -1,12 +1,11 @@
|
|
|
1
1
|
import { Component, ComponentShorthand } from "../types.js";
|
|
2
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
|
-
//#region src/PrismicRichText/types.d.ts
|
|
4
3
|
/**
|
|
5
4
|
* A map of Rich Text block types to Vue Components. It is used to render Rich Text or title fields.
|
|
6
5
|
*
|
|
7
6
|
* @see Templating Rich Text and title fields from Prismic {@link https://prismic.io/docs/rich-text}
|
|
8
7
|
*/
|
|
9
|
-
type RichTextComponents = {
|
|
8
|
+
export type RichTextComponents = {
|
|
10
9
|
heading1?: RichTextComponent<RTHeading1Node> | ComponentShorthand;
|
|
11
10
|
heading2?: RichTextComponent<RTHeading2Node> | ComponentShorthand;
|
|
12
11
|
heading3?: RichTextComponent<RTHeading3Node> | ComponentShorthand;
|
|
@@ -28,7 +27,7 @@ type RichTextComponents = {
|
|
|
28
27
|
span?: RichTextComponent<RTSpanNode>;
|
|
29
28
|
};
|
|
30
29
|
/** Props for a component rendering nodes from a Prismic rich text field. */
|
|
31
|
-
type RichTextComponentProps<TRTNode extends RTAnyNode = RTAnyNode> = {
|
|
30
|
+
export type RichTextComponentProps<TRTNode extends RTAnyNode = RTAnyNode> = {
|
|
32
31
|
node: TRTNode;
|
|
33
32
|
};
|
|
34
33
|
/**
|
|
@@ -36,7 +35,5 @@ type RichTextComponentProps<TRTNode extends RTAnyNode = RTAnyNode> = {
|
|
|
36
35
|
*
|
|
37
36
|
* @typeParam TRTNode - The type of rich text node(s) this component handles
|
|
38
37
|
*/
|
|
39
|
-
type RichTextComponent<TRTNode extends RTAnyNode = RTAnyNode> = Component<RichTextComponentProps<TRTNode>>;
|
|
40
|
-
//#endregion
|
|
41
|
-
export { RichTextComponent, RichTextComponentProps, RichTextComponents };
|
|
38
|
+
export type RichTextComponent<TRTNode extends RTAnyNode = RTAnyNode> = Component<RichTextComponentProps<TRTNode>>;
|
|
42
39
|
//# sourceMappingURL=types.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","names":[],"sources":["../../src/PrismicRichText/types.ts"],"mappings":"
|
|
1
|
+
{"version":3,"file":"types.d.ts","names":[],"sources":["../../src/PrismicRichText/types.ts"],"mappings":";;;;;;;YAgCY;EACX,WAAW,kBAAkB,kBAAkB;EAC/C,WAAW,kBAAkB,kBAAkB;EAC/C,WAAW,kBAAkB,kBAAkB;EAC/C,WAAW,kBAAkB,kBAAkB;EAC/C,WAAW,kBAAkB,kBAAkB;EAC/C,WAAW,kBAAkB,kBAAkB;EAC/C,YAAY,kBAAkB,mBAAmB;EACjD,eAAe,kBAAkB,sBAAsB;EACvD,SAAS,kBAAkB,gBAAgB;EAC3C,KAAK,kBAAkB,YAAY;EACnC,WAAW,kBAAkB,kBAAkB;EAC/C,YAAY,kBAAkB,mBAAmB;EACjD,OAAO,kBAAkB,cAAc;EACvC,QAAQ,kBAAkB,eAAe;EACzC,QAAQ,kBAAkB,eAAe,KAAK;EAC9C,QAAQ,kBAAkB,eAAe;EACzC,YAAY,kBAAkB,cAAc,KAAK;EACjD,QAAQ,kBAAkB,eAAe,KAAK;EAC9C,OAAO,kBAAkB;;;YAId,uBAAuB,gBAAgB,YAAY;EAC9D,MAAM;;;;;;;YAQK,kBAAkB,gBAAgB,YAAY,aAAa,UACtE,uBAAuB"}
|
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
|
|
1
|
+
// src/PrismicTable/PrismicTable.vue
|
|
2
2
|
var PrismicTable_default = require("./PrismicTable.vue_vue_type_script_setup_true_lang.cjs").default;
|
|
3
|
-
//#endregion
|
|
4
3
|
exports.default = PrismicTable_default;
|
|
5
4
|
|
|
6
5
|
//# sourceMappingURL=PrismicTable.cjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PrismicTable.cjs","names":[],"sources":["../../src/PrismicTable/PrismicTable.vue"],"sourcesContent":["<script lang=\"ts\" setup>\nimport { type TableField, isFilled } from \"@prismicio/client\"\nimport { computed } from \"vue\"\n\nimport { usePrismic } from \"../createPrismic\"\nimport type { RichTextComponents } from \"../PrismicRichText\"\nimport type { ComponentOrTagName, ComponentShorthand } from \"../types\"\nimport { isComponent } from \"../types\"\nimport { defaultTableComponents } from \"./PrismicTableDefaultComponents\"\nimport PrismicTableRow from \"./PrismicTableRow.vue\"\nimport type { InternalTableComponents, TableComponents } from \"./types\"\n\n/** Props for `<PrismicTable />`. */\nexport type PrismicTableProps = {\n\t/** The Prismic table field to render. */\n\tfield: TableField | undefined\n\n\t/**\n\t * An object that maps a table block type to a Vue component or a shorthand definition.\n\t *\n\t * @example\n\t * \t```javascript\n\t * \t;({\n\t * \t\ttable: Table,\n\t * \t\tthead: { class: \"bg-black text-white\" },\n\t * \t\tth: { as: \"td\", class: \"font-bold\" }\n\t * \t})\n\t * \t```\n\t */\n\tcomponents?: TableComponents & RichTextComponents\n\n\t/**\n\t * The value to be rendered when the field is empty. If a fallback is not given, `null` (nothing)\n\t * will be rendered.\n\t */\n\tfallback?: ComponentOrTagName\n}\n\nconst props = defineProps<PrismicTableProps>()\ndefineOptions({ name: \"PrismicTable\" })\n\nconst {\n\tcomponents: { richTextComponents },\n} = usePrismic()\n\nconst resolvedComponents = computed<TableComponents & RichTextComponents>(() => {\n\treturn { ...richTextComponents, ...props.components }\n})\n\nfunction getInternalComponent(type: keyof TableComponents) {\n\tconst maybeComponentOrShorthand = resolvedComponents.value?.[type]\n\n\tif (isComponent(maybeComponentOrShorthand)) {\n\t\treturn { is: maybeComponentOrShorthand }\n\t}\n\n\treturn {\n\t\tis: defaultTableComponents[type],\n\t\tshorthand: maybeComponentOrShorthand as ComponentShorthand,\n\t}\n}\n\nconst internalTableComponents = computed<InternalTableComponents>(() => {\n\treturn {\n\t\ttable: getInternalComponent(\"table\"),\n\t\tthead: getInternalComponent(\"thead\"),\n\t\ttbody: getInternalComponent(\"tbody\"),\n\t\ttr: getInternalComponent(\"tr\"),\n\t\tth: getInternalComponent(\"th\"),\n\t\ttd: getInternalComponent(\"td\"),\n\t}\n})\n</script>\n\n<template>\n\t<component\n\t\tv-if=\"isFilled.table(field)\"\n\t\t:is=\"internalTableComponents.table.is\"\n\t\t:table=\"field\"\n\t\tv-bind=\"{ ...$attrs, ...internalTableComponents.table.shorthand }\"\n\t>\n\t\t<component\n\t\t\tv-if=\"field.head\"\n\t\t\t:is=\"internalTableComponents.thead.is\"\n\t\t\t:head=\"field.head\"\n\t\t\tv-bind=\"internalTableComponents.thead.shorthand\"\n\t\t>\n\t\t\t<PrismicTableRow\n\t\t\t\tv-for=\"row in field.head.rows\"\n\t\t\t\t:key=\"row.key\"\n\t\t\t\t:row=\"row\"\n\t\t\t\t:internalTableComponents=\"internalTableComponents\"\n\t\t\t\t:components=\"components\"\n\t\t\t/>\n\t\t</component>\n\t\t<component\n\t\t\t:is=\"internalTableComponents.tbody.is\"\n\t\t\t:body=\"field.body\"\n\t\t\tv-bind=\"internalTableComponents.tbody.shorthand\"\n\t\t>\n\t\t\t<PrismicTableRow\n\t\t\t\tv-for=\"row in field.body.rows\"\n\t\t\t\t:key=\"row.key\"\n\t\t\t\t:row=\"row\"\n\t\t\t\t:internalTableComponents=\"internalTableComponents\"\n\t\t\t\t:components=\"components\"\n\t\t\t/>\n\t\t</component>\n\t</component>\n\t<component v-else-if=\"fallback\" :is=\"fallback\" v-bind=\"$attrs\" />\n</template>\n"],"mappings":""}
|
|
1
|
+
{"version":3,"file":"PrismicTable.cjs","names":["_sfc_main"],"sources":["../../src/PrismicTable/PrismicTable.vue"],"sourcesContent":["<script lang=\"ts\" setup>\nimport { type TableField, isFilled } from \"@prismicio/client\"\nimport { computed } from \"vue\"\n\nimport { usePrismic } from \"../createPrismic\"\nimport type { RichTextComponents } from \"../PrismicRichText\"\nimport type { ComponentOrTagName, ComponentShorthand } from \"../types\"\nimport { isComponent } from \"../types\"\nimport { defaultTableComponents } from \"./PrismicTableDefaultComponents\"\nimport PrismicTableRow from \"./PrismicTableRow.vue\"\nimport type { InternalTableComponents, TableComponents } from \"./types\"\n\n/** Props for `<PrismicTable />`. */\nexport type PrismicTableProps = {\n\t/** The Prismic table field to render. */\n\tfield: TableField | undefined\n\n\t/**\n\t * An object that maps a table block type to a Vue component or a shorthand definition.\n\t *\n\t * @example\n\t * \t```javascript\n\t * \t;({\n\t * \t\ttable: Table,\n\t * \t\tthead: { class: \"bg-black text-white\" },\n\t * \t\tth: { as: \"td\", class: \"font-bold\" }\n\t * \t})\n\t * \t```\n\t */\n\tcomponents?: TableComponents & RichTextComponents\n\n\t/**\n\t * The value to be rendered when the field is empty. If a fallback is not given, `null` (nothing)\n\t * will be rendered.\n\t */\n\tfallback?: ComponentOrTagName\n}\n\nconst props = defineProps<PrismicTableProps>()\ndefineOptions({ name: \"PrismicTable\" })\n\nconst {\n\tcomponents: { richTextComponents },\n} = usePrismic()\n\nconst resolvedComponents = computed<TableComponents & RichTextComponents>(() => {\n\treturn { ...richTextComponents, ...props.components }\n})\n\nfunction getInternalComponent(type: keyof TableComponents) {\n\tconst maybeComponentOrShorthand = resolvedComponents.value?.[type]\n\n\tif (isComponent(maybeComponentOrShorthand)) {\n\t\treturn { is: maybeComponentOrShorthand }\n\t}\n\n\treturn {\n\t\tis: defaultTableComponents[type],\n\t\tshorthand: maybeComponentOrShorthand as ComponentShorthand,\n\t}\n}\n\nconst internalTableComponents = computed<InternalTableComponents>(() => {\n\treturn {\n\t\ttable: getInternalComponent(\"table\"),\n\t\tthead: getInternalComponent(\"thead\"),\n\t\ttbody: getInternalComponent(\"tbody\"),\n\t\ttr: getInternalComponent(\"tr\"),\n\t\tth: getInternalComponent(\"th\"),\n\t\ttd: getInternalComponent(\"td\"),\n\t}\n})\n</script>\n\n<template>\n\t<component\n\t\tv-if=\"isFilled.table(field)\"\n\t\t:is=\"internalTableComponents.table.is\"\n\t\t:table=\"field\"\n\t\tv-bind=\"{ ...$attrs, ...internalTableComponents.table.shorthand }\"\n\t>\n\t\t<component\n\t\t\tv-if=\"field.head\"\n\t\t\t:is=\"internalTableComponents.thead.is\"\n\t\t\t:head=\"field.head\"\n\t\t\tv-bind=\"internalTableComponents.thead.shorthand\"\n\t\t>\n\t\t\t<PrismicTableRow\n\t\t\t\tv-for=\"row in field.head.rows\"\n\t\t\t\t:key=\"row.key\"\n\t\t\t\t:row=\"row\"\n\t\t\t\t:internalTableComponents=\"internalTableComponents\"\n\t\t\t\t:components=\"components\"\n\t\t\t/>\n\t\t</component>\n\t\t<component\n\t\t\t:is=\"internalTableComponents.tbody.is\"\n\t\t\t:body=\"field.body\"\n\t\t\tv-bind=\"internalTableComponents.tbody.shorthand\"\n\t\t>\n\t\t\t<PrismicTableRow\n\t\t\t\tv-for=\"row in field.body.rows\"\n\t\t\t\t:key=\"row.key\"\n\t\t\t\t:row=\"row\"\n\t\t\t\t:internalTableComponents=\"internalTableComponents\"\n\t\t\t\t:components=\"components\"\n\t\t\t/>\n\t\t</component>\n\t</component>\n\t<component v-else-if=\"fallback\" :is=\"fallback\" v-bind=\"$attrs\" />\n</template>\n"],"mappings":""}
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import PrismicTable_vue_vue_type_script_setup_true_lang_default from "./PrismicTable.vue_vue_type_script_setup_true_lang.js";
|
|
2
|
-
|
|
2
|
+
// src/PrismicTable/PrismicTable.vue
|
|
3
3
|
var PrismicTable_default = PrismicTable_vue_vue_type_script_setup_true_lang_default;
|
|
4
|
-
//#endregion
|
|
5
4
|
export { PrismicTable_default as default };
|
|
6
5
|
|
|
7
6
|
//# sourceMappingURL=PrismicTable.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PrismicTable.js","names":[],"sources":["../../src/PrismicTable/PrismicTable.vue"],"sourcesContent":["<script lang=\"ts\" setup>\nimport { type TableField, isFilled } from \"@prismicio/client\"\nimport { computed } from \"vue\"\n\nimport { usePrismic } from \"../createPrismic\"\nimport type { RichTextComponents } from \"../PrismicRichText\"\nimport type { ComponentOrTagName, ComponentShorthand } from \"../types\"\nimport { isComponent } from \"../types\"\nimport { defaultTableComponents } from \"./PrismicTableDefaultComponents\"\nimport PrismicTableRow from \"./PrismicTableRow.vue\"\nimport type { InternalTableComponents, TableComponents } from \"./types\"\n\n/** Props for `<PrismicTable />`. */\nexport type PrismicTableProps = {\n\t/** The Prismic table field to render. */\n\tfield: TableField | undefined\n\n\t/**\n\t * An object that maps a table block type to a Vue component or a shorthand definition.\n\t *\n\t * @example\n\t * \t```javascript\n\t * \t;({\n\t * \t\ttable: Table,\n\t * \t\tthead: { class: \"bg-black text-white\" },\n\t * \t\tth: { as: \"td\", class: \"font-bold\" }\n\t * \t})\n\t * \t```\n\t */\n\tcomponents?: TableComponents & RichTextComponents\n\n\t/**\n\t * The value to be rendered when the field is empty. If a fallback is not given, `null` (nothing)\n\t * will be rendered.\n\t */\n\tfallback?: ComponentOrTagName\n}\n\nconst props = defineProps<PrismicTableProps>()\ndefineOptions({ name: \"PrismicTable\" })\n\nconst {\n\tcomponents: { richTextComponents },\n} = usePrismic()\n\nconst resolvedComponents = computed<TableComponents & RichTextComponents>(() => {\n\treturn { ...richTextComponents, ...props.components }\n})\n\nfunction getInternalComponent(type: keyof TableComponents) {\n\tconst maybeComponentOrShorthand = resolvedComponents.value?.[type]\n\n\tif (isComponent(maybeComponentOrShorthand)) {\n\t\treturn { is: maybeComponentOrShorthand }\n\t}\n\n\treturn {\n\t\tis: defaultTableComponents[type],\n\t\tshorthand: maybeComponentOrShorthand as ComponentShorthand,\n\t}\n}\n\nconst internalTableComponents = computed<InternalTableComponents>(() => {\n\treturn {\n\t\ttable: getInternalComponent(\"table\"),\n\t\tthead: getInternalComponent(\"thead\"),\n\t\ttbody: getInternalComponent(\"tbody\"),\n\t\ttr: getInternalComponent(\"tr\"),\n\t\tth: getInternalComponent(\"th\"),\n\t\ttd: getInternalComponent(\"td\"),\n\t}\n})\n</script>\n\n<template>\n\t<component\n\t\tv-if=\"isFilled.table(field)\"\n\t\t:is=\"internalTableComponents.table.is\"\n\t\t:table=\"field\"\n\t\tv-bind=\"{ ...$attrs, ...internalTableComponents.table.shorthand }\"\n\t>\n\t\t<component\n\t\t\tv-if=\"field.head\"\n\t\t\t:is=\"internalTableComponents.thead.is\"\n\t\t\t:head=\"field.head\"\n\t\t\tv-bind=\"internalTableComponents.thead.shorthand\"\n\t\t>\n\t\t\t<PrismicTableRow\n\t\t\t\tv-for=\"row in field.head.rows\"\n\t\t\t\t:key=\"row.key\"\n\t\t\t\t:row=\"row\"\n\t\t\t\t:internalTableComponents=\"internalTableComponents\"\n\t\t\t\t:components=\"components\"\n\t\t\t/>\n\t\t</component>\n\t\t<component\n\t\t\t:is=\"internalTableComponents.tbody.is\"\n\t\t\t:body=\"field.body\"\n\t\t\tv-bind=\"internalTableComponents.tbody.shorthand\"\n\t\t>\n\t\t\t<PrismicTableRow\n\t\t\t\tv-for=\"row in field.body.rows\"\n\t\t\t\t:key=\"row.key\"\n\t\t\t\t:row=\"row\"\n\t\t\t\t:internalTableComponents=\"internalTableComponents\"\n\t\t\t\t:components=\"components\"\n\t\t\t/>\n\t\t</component>\n\t</component>\n\t<component v-else-if=\"fallback\" :is=\"fallback\" v-bind=\"$attrs\" />\n</template>\n"],"mappings":""}
|
|
1
|
+
{"version":3,"file":"PrismicTable.js","names":["_sfc_main"],"sources":["../../src/PrismicTable/PrismicTable.vue"],"sourcesContent":["<script lang=\"ts\" setup>\nimport { type TableField, isFilled } from \"@prismicio/client\"\nimport { computed } from \"vue\"\n\nimport { usePrismic } from \"../createPrismic\"\nimport type { RichTextComponents } from \"../PrismicRichText\"\nimport type { ComponentOrTagName, ComponentShorthand } from \"../types\"\nimport { isComponent } from \"../types\"\nimport { defaultTableComponents } from \"./PrismicTableDefaultComponents\"\nimport PrismicTableRow from \"./PrismicTableRow.vue\"\nimport type { InternalTableComponents, TableComponents } from \"./types\"\n\n/** Props for `<PrismicTable />`. */\nexport type PrismicTableProps = {\n\t/** The Prismic table field to render. */\n\tfield: TableField | undefined\n\n\t/**\n\t * An object that maps a table block type to a Vue component or a shorthand definition.\n\t *\n\t * @example\n\t * \t```javascript\n\t * \t;({\n\t * \t\ttable: Table,\n\t * \t\tthead: { class: \"bg-black text-white\" },\n\t * \t\tth: { as: \"td\", class: \"font-bold\" }\n\t * \t})\n\t * \t```\n\t */\n\tcomponents?: TableComponents & RichTextComponents\n\n\t/**\n\t * The value to be rendered when the field is empty. If a fallback is not given, `null` (nothing)\n\t * will be rendered.\n\t */\n\tfallback?: ComponentOrTagName\n}\n\nconst props = defineProps<PrismicTableProps>()\ndefineOptions({ name: \"PrismicTable\" })\n\nconst {\n\tcomponents: { richTextComponents },\n} = usePrismic()\n\nconst resolvedComponents = computed<TableComponents & RichTextComponents>(() => {\n\treturn { ...richTextComponents, ...props.components }\n})\n\nfunction getInternalComponent(type: keyof TableComponents) {\n\tconst maybeComponentOrShorthand = resolvedComponents.value?.[type]\n\n\tif (isComponent(maybeComponentOrShorthand)) {\n\t\treturn { is: maybeComponentOrShorthand }\n\t}\n\n\treturn {\n\t\tis: defaultTableComponents[type],\n\t\tshorthand: maybeComponentOrShorthand as ComponentShorthand,\n\t}\n}\n\nconst internalTableComponents = computed<InternalTableComponents>(() => {\n\treturn {\n\t\ttable: getInternalComponent(\"table\"),\n\t\tthead: getInternalComponent(\"thead\"),\n\t\ttbody: getInternalComponent(\"tbody\"),\n\t\ttr: getInternalComponent(\"tr\"),\n\t\tth: getInternalComponent(\"th\"),\n\t\ttd: getInternalComponent(\"td\"),\n\t}\n})\n</script>\n\n<template>\n\t<component\n\t\tv-if=\"isFilled.table(field)\"\n\t\t:is=\"internalTableComponents.table.is\"\n\t\t:table=\"field\"\n\t\tv-bind=\"{ ...$attrs, ...internalTableComponents.table.shorthand }\"\n\t>\n\t\t<component\n\t\t\tv-if=\"field.head\"\n\t\t\t:is=\"internalTableComponents.thead.is\"\n\t\t\t:head=\"field.head\"\n\t\t\tv-bind=\"internalTableComponents.thead.shorthand\"\n\t\t>\n\t\t\t<PrismicTableRow\n\t\t\t\tv-for=\"row in field.head.rows\"\n\t\t\t\t:key=\"row.key\"\n\t\t\t\t:row=\"row\"\n\t\t\t\t:internalTableComponents=\"internalTableComponents\"\n\t\t\t\t:components=\"components\"\n\t\t\t/>\n\t\t</component>\n\t\t<component\n\t\t\t:is=\"internalTableComponents.tbody.is\"\n\t\t\t:body=\"field.body\"\n\t\t\tv-bind=\"internalTableComponents.tbody.shorthand\"\n\t\t>\n\t\t\t<PrismicTableRow\n\t\t\t\tv-for=\"row in field.body.rows\"\n\t\t\t\t:key=\"row.key\"\n\t\t\t\t:row=\"row\"\n\t\t\t\t:internalTableComponents=\"internalTableComponents\"\n\t\t\t\t:components=\"components\"\n\t\t\t/>\n\t\t</component>\n\t</component>\n\t<component v-else-if=\"fallback\" :is=\"fallback\" v-bind=\"$attrs\" />\n</template>\n"],"mappings":""}
|
|
@@ -3,9 +3,8 @@ import { RichTextComponents } from "../PrismicRichText/types.cjs";
|
|
|
3
3
|
import "../PrismicRichText/index.cjs";
|
|
4
4
|
import { TableComponents } from "./types.cjs";
|
|
5
5
|
import { TableField } from "@prismicio/client";
|
|
6
|
-
//#region src/PrismicTable/PrismicTable.vue.d.ts
|
|
7
6
|
/** Props for `<PrismicTable />`. */
|
|
8
|
-
type PrismicTableProps = {
|
|
7
|
+
export type PrismicTableProps = {
|
|
9
8
|
/** The Prismic table field to render. */
|
|
10
9
|
field: TableField | undefined;
|
|
11
10
|
/**
|
|
@@ -29,6 +28,5 @@ type PrismicTableProps = {
|
|
|
29
28
|
};
|
|
30
29
|
declare const __VLS_export: import("vue").DefineComponent<PrismicTableProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<PrismicTableProps> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
31
30
|
declare const _default: typeof __VLS_export;
|
|
32
|
-
|
|
33
|
-
export { PrismicTableProps, _default as default };
|
|
31
|
+
export { _default as default };
|
|
34
32
|
//# sourceMappingURL=PrismicTable.vue.d.cts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PrismicTable.vue.d.cts","names":[],"sources":["../../src/PrismicTable/PrismicTable.vue"],"mappings":"
|
|
1
|
+
{"version":3,"file":"PrismicTable.vue.d.cts","names":[],"sources":["../../src/PrismicTable/PrismicTable.vue"],"mappings":";;;;;;YA8HY;;EAEX,OAAO;;;;;;;;;;;;;EAcP,aAAa,kBAAkB;;;;;EAM/B,WAAW;;cAiJN,4BAAY,gBAAA,iDAAA,qCAAA,iDAAA,aAAA,SAAA,qBAAA,oDAAA;cAGG,iBAAO"}
|
|
@@ -3,9 +3,8 @@ import { RichTextComponents } from "../PrismicRichText/types.js";
|
|
|
3
3
|
import "../PrismicRichText/index.js";
|
|
4
4
|
import { TableComponents } from "./types.js";
|
|
5
5
|
import { TableField } from "@prismicio/client";
|
|
6
|
-
//#region src/PrismicTable/PrismicTable.vue.d.ts
|
|
7
6
|
/** Props for `<PrismicTable />`. */
|
|
8
|
-
type PrismicTableProps = {
|
|
7
|
+
export type PrismicTableProps = {
|
|
9
8
|
/** The Prismic table field to render. */
|
|
10
9
|
field: TableField | undefined;
|
|
11
10
|
/**
|
|
@@ -29,6 +28,5 @@ type PrismicTableProps = {
|
|
|
29
28
|
};
|
|
30
29
|
declare const __VLS_export: import("vue").DefineComponent<PrismicTableProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<PrismicTableProps> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
31
30
|
declare const _default: typeof __VLS_export;
|
|
32
|
-
|
|
33
|
-
export { PrismicTableProps, _default as default };
|
|
31
|
+
export { _default as default };
|
|
34
32
|
//# sourceMappingURL=PrismicTable.vue.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PrismicTable.vue.d.ts","names":[],"sources":["../../src/PrismicTable/PrismicTable.vue"],"mappings":"
|
|
1
|
+
{"version":3,"file":"PrismicTable.vue.d.ts","names":[],"sources":["../../src/PrismicTable/PrismicTable.vue"],"mappings":";;;;;;YA8HY;;EAEX,OAAO;;;;;;;;;;;;;EAcP,aAAa,kBAAkB;;;;;EAM/B,WAAW;;cAiJN,4BAAY,gBAAA,iDAAA,qCAAA,iDAAA,aAAA,SAAA,qBAAA,oDAAA;cAGG,iBAAO"}
|
|
@@ -4,7 +4,7 @@ const require_PrismicTableDefaultComponents = require("./PrismicTableDefaultComp
|
|
|
4
4
|
const require_PrismicTableRow = require("./PrismicTableRow.cjs");
|
|
5
5
|
let vue = require("vue");
|
|
6
6
|
let _prismicio_client = require("@prismicio/client");
|
|
7
|
-
|
|
7
|
+
// src/PrismicTable/PrismicTable.vue?vue&type=script&setup=true&lang.ts
|
|
8
8
|
var PrismicTable_vue_vue_type_script_setup_true_lang_default = /*@__PURE__*/ (0, vue.defineComponent)({
|
|
9
9
|
name: "PrismicTable",
|
|
10
10
|
__name: "PrismicTable",
|
|
@@ -94,7 +94,6 @@ var PrismicTable_vue_vue_type_script_setup_true_lang_default = /*@__PURE__*/ (0,
|
|
|
94
94
|
};
|
|
95
95
|
}
|
|
96
96
|
});
|
|
97
|
-
//#endregion
|
|
98
97
|
exports.default = PrismicTable_vue_vue_type_script_setup_true_lang_default;
|
|
99
98
|
|
|
100
99
|
//# sourceMappingURL=PrismicTable.vue_vue_type_script_setup_true_lang.cjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PrismicTable.vue_vue_type_script_setup_true_lang.cjs","names":["$attrs"],"sources":["../../src/PrismicTable/PrismicTable.vue"],"sourcesContent":["<script lang=\"ts\" setup>\nimport { type TableField, isFilled } from \"@prismicio/client\"\nimport { computed } from \"vue\"\n\nimport { usePrismic } from \"../createPrismic\"\nimport type { RichTextComponents } from \"../PrismicRichText\"\nimport type { ComponentOrTagName, ComponentShorthand } from \"../types\"\nimport { isComponent } from \"../types\"\nimport { defaultTableComponents } from \"./PrismicTableDefaultComponents\"\nimport PrismicTableRow from \"./PrismicTableRow.vue\"\nimport type { InternalTableComponents, TableComponents } from \"./types\"\n\n/** Props for `<PrismicTable />`. */\nexport type PrismicTableProps = {\n\t/** The Prismic table field to render. */\n\tfield: TableField | undefined\n\n\t/**\n\t * An object that maps a table block type to a Vue component or a shorthand definition.\n\t *\n\t * @example\n\t * \t```javascript\n\t * \t;({\n\t * \t\ttable: Table,\n\t * \t\tthead: { class: \"bg-black text-white\" },\n\t * \t\tth: { as: \"td\", class: \"font-bold\" }\n\t * \t})\n\t * \t```\n\t */\n\tcomponents?: TableComponents & RichTextComponents\n\n\t/**\n\t * The value to be rendered when the field is empty. If a fallback is not given, `null` (nothing)\n\t * will be rendered.\n\t */\n\tfallback?: ComponentOrTagName\n}\n\nconst props = defineProps<PrismicTableProps>()\ndefineOptions({ name: \"PrismicTable\" })\n\nconst {\n\tcomponents: { richTextComponents },\n} = usePrismic()\n\nconst resolvedComponents = computed<TableComponents & RichTextComponents>(() => {\n\treturn { ...richTextComponents, ...props.components }\n})\n\nfunction getInternalComponent(type: keyof TableComponents) {\n\tconst maybeComponentOrShorthand = resolvedComponents.value?.[type]\n\n\tif (isComponent(maybeComponentOrShorthand)) {\n\t\treturn { is: maybeComponentOrShorthand }\n\t}\n\n\treturn {\n\t\tis: defaultTableComponents[type],\n\t\tshorthand: maybeComponentOrShorthand as ComponentShorthand,\n\t}\n}\n\nconst internalTableComponents = computed<InternalTableComponents>(() => {\n\treturn {\n\t\ttable: getInternalComponent(\"table\"),\n\t\tthead: getInternalComponent(\"thead\"),\n\t\ttbody: getInternalComponent(\"tbody\"),\n\t\ttr: getInternalComponent(\"tr\"),\n\t\tth: getInternalComponent(\"th\"),\n\t\ttd: getInternalComponent(\"td\"),\n\t}\n})\n</script>\n\n<template>\n\t<component\n\t\tv-if=\"isFilled.table(field)\"\n\t\t:is=\"internalTableComponents.table.is\"\n\t\t:table=\"field\"\n\t\tv-bind=\"{ ...$attrs, ...internalTableComponents.table.shorthand }\"\n\t>\n\t\t<component\n\t\t\tv-if=\"field.head\"\n\t\t\t:is=\"internalTableComponents.thead.is\"\n\t\t\t:head=\"field.head\"\n\t\t\tv-bind=\"internalTableComponents.thead.shorthand\"\n\t\t>\n\t\t\t<PrismicTableRow\n\t\t\t\tv-for=\"row in field.head.rows\"\n\t\t\t\t:key=\"row.key\"\n\t\t\t\t:row=\"row\"\n\t\t\t\t:internalTableComponents=\"internalTableComponents\"\n\t\t\t\t:components=\"components\"\n\t\t\t/>\n\t\t</component>\n\t\t<component\n\t\t\t:is=\"internalTableComponents.tbody.is\"\n\t\t\t:body=\"field.body\"\n\t\t\tv-bind=\"internalTableComponents.tbody.shorthand\"\n\t\t>\n\t\t\t<PrismicTableRow\n\t\t\t\tv-for=\"row in field.body.rows\"\n\t\t\t\t:key=\"row.key\"\n\t\t\t\t:row=\"row\"\n\t\t\t\t:internalTableComponents=\"internalTableComponents\"\n\t\t\t\t:components=\"components\"\n\t\t\t/>\n\t\t</component>\n\t</component>\n\t<component v-else-if=\"fallback\" :is=\"fallback\" v-bind=\"$attrs\" />\n</template>\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;EAsCA,MAAM,QAAQ;EAGd,MAAM,EACL,YAAY,EAAE,
|
|
1
|
+
{"version":3,"file":"PrismicTable.vue_vue_type_script_setup_true_lang.cjs","names":["$attrs","usePrismic","computed","isComponent","defaultTableComponents","_unref","isFilled","_openBlock","_createBlock","_resolveDynamicComponent","_mergeProps","_withCtx","_createElementBlock","_Fragment","_renderList","PrismicTableRow","_createCommentVNode","_normalizeProps"],"sources":["../../src/PrismicTable/PrismicTable.vue"],"sourcesContent":["<script lang=\"ts\" setup>\nimport { type TableField, isFilled } from \"@prismicio/client\"\nimport { computed } from \"vue\"\n\nimport { usePrismic } from \"../createPrismic\"\nimport type { RichTextComponents } from \"../PrismicRichText\"\nimport type { ComponentOrTagName, ComponentShorthand } from \"../types\"\nimport { isComponent } from \"../types\"\nimport { defaultTableComponents } from \"./PrismicTableDefaultComponents\"\nimport PrismicTableRow from \"./PrismicTableRow.vue\"\nimport type { InternalTableComponents, TableComponents } from \"./types\"\n\n/** Props for `<PrismicTable />`. */\nexport type PrismicTableProps = {\n\t/** The Prismic table field to render. */\n\tfield: TableField | undefined\n\n\t/**\n\t * An object that maps a table block type to a Vue component or a shorthand definition.\n\t *\n\t * @example\n\t * \t```javascript\n\t * \t;({\n\t * \t\ttable: Table,\n\t * \t\tthead: { class: \"bg-black text-white\" },\n\t * \t\tth: { as: \"td\", class: \"font-bold\" }\n\t * \t})\n\t * \t```\n\t */\n\tcomponents?: TableComponents & RichTextComponents\n\n\t/**\n\t * The value to be rendered when the field is empty. If a fallback is not given, `null` (nothing)\n\t * will be rendered.\n\t */\n\tfallback?: ComponentOrTagName\n}\n\nconst props = defineProps<PrismicTableProps>()\ndefineOptions({ name: \"PrismicTable\" })\n\nconst {\n\tcomponents: { richTextComponents },\n} = usePrismic()\n\nconst resolvedComponents = computed<TableComponents & RichTextComponents>(() => {\n\treturn { ...richTextComponents, ...props.components }\n})\n\nfunction getInternalComponent(type: keyof TableComponents) {\n\tconst maybeComponentOrShorthand = resolvedComponents.value?.[type]\n\n\tif (isComponent(maybeComponentOrShorthand)) {\n\t\treturn { is: maybeComponentOrShorthand }\n\t}\n\n\treturn {\n\t\tis: defaultTableComponents[type],\n\t\tshorthand: maybeComponentOrShorthand as ComponentShorthand,\n\t}\n}\n\nconst internalTableComponents = computed<InternalTableComponents>(() => {\n\treturn {\n\t\ttable: getInternalComponent(\"table\"),\n\t\tthead: getInternalComponent(\"thead\"),\n\t\ttbody: getInternalComponent(\"tbody\"),\n\t\ttr: getInternalComponent(\"tr\"),\n\t\tth: getInternalComponent(\"th\"),\n\t\ttd: getInternalComponent(\"td\"),\n\t}\n})\n</script>\n\n<template>\n\t<component\n\t\tv-if=\"isFilled.table(field)\"\n\t\t:is=\"internalTableComponents.table.is\"\n\t\t:table=\"field\"\n\t\tv-bind=\"{ ...$attrs, ...internalTableComponents.table.shorthand }\"\n\t>\n\t\t<component\n\t\t\tv-if=\"field.head\"\n\t\t\t:is=\"internalTableComponents.thead.is\"\n\t\t\t:head=\"field.head\"\n\t\t\tv-bind=\"internalTableComponents.thead.shorthand\"\n\t\t>\n\t\t\t<PrismicTableRow\n\t\t\t\tv-for=\"row in field.head.rows\"\n\t\t\t\t:key=\"row.key\"\n\t\t\t\t:row=\"row\"\n\t\t\t\t:internalTableComponents=\"internalTableComponents\"\n\t\t\t\t:components=\"components\"\n\t\t\t/>\n\t\t</component>\n\t\t<component\n\t\t\t:is=\"internalTableComponents.tbody.is\"\n\t\t\t:body=\"field.body\"\n\t\t\tv-bind=\"internalTableComponents.tbody.shorthand\"\n\t\t>\n\t\t\t<PrismicTableRow\n\t\t\t\tv-for=\"row in field.body.rows\"\n\t\t\t\t:key=\"row.key\"\n\t\t\t\t:row=\"row\"\n\t\t\t\t:internalTableComponents=\"internalTableComponents\"\n\t\t\t\t:components=\"components\"\n\t\t\t/>\n\t\t</component>\n\t</component>\n\t<component v-else-if=\"fallback\" :is=\"fallback\" v-bind=\"$attrs\" />\n</template>\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;EAsCA,MAAM,QAAQ;EAGd,MAAM,EACL,YAAY,EAAE,yBACXC,sBAAAA,WAAW;EAEf,MAAM,sBAAA,GAAqBC,IAAAA,SAAAA,OAAqD;GAC/E,OAAO;IAAE,GAAG;IAAoB,GAAG,MAAM;GAAW;EACrD,CAAC;EAED,SAAS,qBAAqB,MAA6B;GAC1D,MAAM,4BAA4B,mBAAmB,QAAQ;GAE7D,IAAIC,cAAAA,YAAY,yBAAyB,GACxC,OAAO,EAAE,IAAI,0BAA0B;GAGxC,OAAO;IACN,IAAIC,sCAAAA,uBAAuB;IAC3B,WAAW;GACZ;EACD;EAEA,MAAM,2BAAA,GAA0BF,IAAAA,SAAAA,OAAwC;GACvE,OAAO;IACN,OAAO,qBAAqB,OAAO;IACnC,OAAO,qBAAqB,OAAO;IACnC,OAAO,qBAAqB,OAAO;IACnC,IAAI,qBAAqB,IAAI;IAC7B,IAAI,qBAAqB,IAAI;IAC7B,IAAI,qBAAqB,IAAI;GAC9B;EACD,CAAC;;GAKO,QAAA,GAAAG,IAAAA,MAAAA,CAAAC,kBAAAA,QAAA,CAAQ,CAAC,MAAM,QAAA,KAAK,MAAA,GAD3BC,IAAAA,UAAAA,CAAA,IAAA,GAAAC,IAAAA,YAAAA,EAAAA,GAiCYC,IAAAA,wBAAAA,CA/BN,wBAAA,MAAwB,MAAM,EAAE,IAAA,GAFtCC,IAAAA,WAAAA,CAiCY;;IA9BV,OAAO,QAAA;GACKV,GAAAA;IAAAA,GAAAA,KAAAA;IAAM,GAAK,wBAAA,MAAwB,MAAM;GAAS,CAAA,GAAA;IAE/D,UAAA,GAAAW,IAAAA,QAAAA,OAaY,CAZL,QAAA,MAAM,SAAA,GADbJ,IAAAA,UAAAA,CAAA,IAAA,GAAAC,IAAAA,YAAAA,EAAAA,GAaYC,IAAAA,wBAAAA,CAXN,wBAAA,MAAwB,MAAM,EAAE,IAAA,GAFtCC,IAAAA,WAAAA,CAaY;;KAVV,MAAM,QAAA,MAAM;IACL,GAAA,wBAAA,MAAwB,MAAM,SAAS,GAAA;KAG9C,UAAA,GAAAC,IAAAA,QAAAA,OAA8B,GAAA,GAD/BJ,IAAAA,UAAAA,CAAA,IAAA,IAAA,GAAAK,IAAAA,mBAAAA,CAMEC,IAAAA,UAAA,OAAA,GAAAC,IAAAA,WAAAA,CALa,QAAA,MAAM,KAAK,OAAlB,QAAG;MADX,QAAA,GAAAP,IAAAA,UAAAA,CAAA,IAAA,GAAAC,IAAAA,YAAAA,CAMEO,wBAAAA,SAAA;OAJA,KAAK,IAAI;OACJ;OACL,yBAAyB,wBAAA;OACzB,YAAY,QAAA;;;;;;;;I,oEAGfR,IAAAA,UAAAA,CAAA,IAAA,GAAAC,IAAAA,YAAAA,EAAAA,GAYYC,IAAAA,wBAAAA,CAXN,wBAAA,MAAwB,MAAM,EAAE,IAAA,GADtCC,IAAAA,WAAAA,CAYY,EAVV,MAAM,QAAA,MAAM,KACL,GAAA,wBAAA,MAAwB,MAAM,SAAS,GAAA;KAG9C,UAAA,GAAAC,IAAAA,QAAAA,OAA8B,GAAA,GAD/BJ,IAAAA,UAAAA,CAAA,IAAA,IAAA,GAAAK,IAAAA,mBAAAA,CAMEC,IAAAA,UAAA,OAAA,GAAAC,IAAAA,WAAAA,CALa,QAAA,MAAM,KAAK,OAAlB,QAAG;MADX,QAAA,GAAAP,IAAAA,UAAAA,CAAA,IAAA,GAAAC,IAAAA,YAAAA,CAMEO,wBAAAA,SAAA;OAJA,KAAK,IAAI;OACJ;OACL,yBAAyB,wBAAA;OACzB,YAAY,QAAA;;;;;;;;;;G,qBAIM,QAAA,aAAA,GAAtBR,IAAAA,UAAAA,CAAA,IAAA,GAAAC,IAAAA,YAAAA,EAAAA,GAAiEC,IAAAA,wBAAAA,CAA5B,QAAA,QAAQ,IAAA,GAAAQ,IAAAA,eAAAA,EAAAA,GAAAP,IAAAA,WAAAA,CAAA,EAAA,KAAA,EAAA,GAAUV,KAAAA,MAAM,CAAA,GAAA,MAAA,EAAA,MAAA,G"}
|
|
@@ -4,7 +4,7 @@ import { defaultTableComponents } from "./PrismicTableDefaultComponents.js";
|
|
|
4
4
|
import PrismicTableRow_default from "./PrismicTableRow.js";
|
|
5
5
|
import { Fragment, computed, createBlock, createCommentVNode, createElementBlock, defineComponent, mergeProps, normalizeProps, openBlock, renderList, resolveDynamicComponent, unref, withCtx } from "vue";
|
|
6
6
|
import { isFilled } from "@prismicio/client";
|
|
7
|
-
|
|
7
|
+
// src/PrismicTable/PrismicTable.vue?vue&type=script&setup=true&lang.ts
|
|
8
8
|
var PrismicTable_vue_vue_type_script_setup_true_lang_default = /*@__PURE__*/ defineComponent({
|
|
9
9
|
name: "PrismicTable",
|
|
10
10
|
__name: "PrismicTable",
|
|
@@ -94,7 +94,6 @@ var PrismicTable_vue_vue_type_script_setup_true_lang_default = /*@__PURE__*/ def
|
|
|
94
94
|
};
|
|
95
95
|
}
|
|
96
96
|
});
|
|
97
|
-
//#endregion
|
|
98
97
|
export { PrismicTable_vue_vue_type_script_setup_true_lang_default as default };
|
|
99
98
|
|
|
100
99
|
//# sourceMappingURL=PrismicTable.vue_vue_type_script_setup_true_lang.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PrismicTable.vue_vue_type_script_setup_true_lang.js","names":["$attrs"],"sources":["../../src/PrismicTable/PrismicTable.vue"],"sourcesContent":["<script lang=\"ts\" setup>\nimport { type TableField, isFilled } from \"@prismicio/client\"\nimport { computed } from \"vue\"\n\nimport { usePrismic } from \"../createPrismic\"\nimport type { RichTextComponents } from \"../PrismicRichText\"\nimport type { ComponentOrTagName, ComponentShorthand } from \"../types\"\nimport { isComponent } from \"../types\"\nimport { defaultTableComponents } from \"./PrismicTableDefaultComponents\"\nimport PrismicTableRow from \"./PrismicTableRow.vue\"\nimport type { InternalTableComponents, TableComponents } from \"./types\"\n\n/** Props for `<PrismicTable />`. */\nexport type PrismicTableProps = {\n\t/** The Prismic table field to render. */\n\tfield: TableField | undefined\n\n\t/**\n\t * An object that maps a table block type to a Vue component or a shorthand definition.\n\t *\n\t * @example\n\t * \t```javascript\n\t * \t;({\n\t * \t\ttable: Table,\n\t * \t\tthead: { class: \"bg-black text-white\" },\n\t * \t\tth: { as: \"td\", class: \"font-bold\" }\n\t * \t})\n\t * \t```\n\t */\n\tcomponents?: TableComponents & RichTextComponents\n\n\t/**\n\t * The value to be rendered when the field is empty. If a fallback is not given, `null` (nothing)\n\t * will be rendered.\n\t */\n\tfallback?: ComponentOrTagName\n}\n\nconst props = defineProps<PrismicTableProps>()\ndefineOptions({ name: \"PrismicTable\" })\n\nconst {\n\tcomponents: { richTextComponents },\n} = usePrismic()\n\nconst resolvedComponents = computed<TableComponents & RichTextComponents>(() => {\n\treturn { ...richTextComponents, ...props.components }\n})\n\nfunction getInternalComponent(type: keyof TableComponents) {\n\tconst maybeComponentOrShorthand = resolvedComponents.value?.[type]\n\n\tif (isComponent(maybeComponentOrShorthand)) {\n\t\treturn { is: maybeComponentOrShorthand }\n\t}\n\n\treturn {\n\t\tis: defaultTableComponents[type],\n\t\tshorthand: maybeComponentOrShorthand as ComponentShorthand,\n\t}\n}\n\nconst internalTableComponents = computed<InternalTableComponents>(() => {\n\treturn {\n\t\ttable: getInternalComponent(\"table\"),\n\t\tthead: getInternalComponent(\"thead\"),\n\t\ttbody: getInternalComponent(\"tbody\"),\n\t\ttr: getInternalComponent(\"tr\"),\n\t\tth: getInternalComponent(\"th\"),\n\t\ttd: getInternalComponent(\"td\"),\n\t}\n})\n</script>\n\n<template>\n\t<component\n\t\tv-if=\"isFilled.table(field)\"\n\t\t:is=\"internalTableComponents.table.is\"\n\t\t:table=\"field\"\n\t\tv-bind=\"{ ...$attrs, ...internalTableComponents.table.shorthand }\"\n\t>\n\t\t<component\n\t\t\tv-if=\"field.head\"\n\t\t\t:is=\"internalTableComponents.thead.is\"\n\t\t\t:head=\"field.head\"\n\t\t\tv-bind=\"internalTableComponents.thead.shorthand\"\n\t\t>\n\t\t\t<PrismicTableRow\n\t\t\t\tv-for=\"row in field.head.rows\"\n\t\t\t\t:key=\"row.key\"\n\t\t\t\t:row=\"row\"\n\t\t\t\t:internalTableComponents=\"internalTableComponents\"\n\t\t\t\t:components=\"components\"\n\t\t\t/>\n\t\t</component>\n\t\t<component\n\t\t\t:is=\"internalTableComponents.tbody.is\"\n\t\t\t:body=\"field.body\"\n\t\t\tv-bind=\"internalTableComponents.tbody.shorthand\"\n\t\t>\n\t\t\t<PrismicTableRow\n\t\t\t\tv-for=\"row in field.body.rows\"\n\t\t\t\t:key=\"row.key\"\n\t\t\t\t:row=\"row\"\n\t\t\t\t:internalTableComponents=\"internalTableComponents\"\n\t\t\t\t:components=\"components\"\n\t\t\t/>\n\t\t</component>\n\t</component>\n\t<component v-else-if=\"fallback\" :is=\"fallback\" v-bind=\"$attrs\" />\n</template>\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;EAsCA,MAAM,QAAQ;EAGd,MAAM,EACL,YAAY,EAAE,yBACX,WAAW;EAEf,MAAM,qBAAqB,eAAqD;GAC/E,OAAO;IAAE,GAAG;IAAoB,GAAG,MAAM;GAAW;EACrD,CAAC;EAED,SAAS,qBAAqB,MAA6B;GAC1D,MAAM,4BAA4B,mBAAmB,QAAQ;GAE7D,IAAI,YAAY,yBAAyB,GACxC,OAAO,EAAE,IAAI,0BAA0B;GAGxC,OAAO;IACN,IAAI,uBAAuB;IAC3B,WAAW;GACZ;EACD;EAEA,MAAM,0BAA0B,eAAwC;GACvE,OAAO;IACN,OAAO,qBAAqB,OAAO;IACnC,OAAO,qBAAqB,OAAO;IACnC,OAAO,qBAAqB,OAAO;IACnC,IAAI,qBAAqB,IAAI;IAC7B,IAAI,qBAAqB,IAAI;IAC7B,IAAI,qBAAqB,IAAI;GAC9B;EACD,CAAC;;GAKO,
|
|
1
|
+
{"version":3,"file":"PrismicTable.vue_vue_type_script_setup_true_lang.js","names":["$attrs","_unref","_openBlock","_createBlock","_resolveDynamicComponent","_mergeProps","_withCtx","_createElementBlock","_Fragment","_renderList","PrismicTableRow","_createCommentVNode","_normalizeProps"],"sources":["../../src/PrismicTable/PrismicTable.vue"],"sourcesContent":["<script lang=\"ts\" setup>\nimport { type TableField, isFilled } from \"@prismicio/client\"\nimport { computed } from \"vue\"\n\nimport { usePrismic } from \"../createPrismic\"\nimport type { RichTextComponents } from \"../PrismicRichText\"\nimport type { ComponentOrTagName, ComponentShorthand } from \"../types\"\nimport { isComponent } from \"../types\"\nimport { defaultTableComponents } from \"./PrismicTableDefaultComponents\"\nimport PrismicTableRow from \"./PrismicTableRow.vue\"\nimport type { InternalTableComponents, TableComponents } from \"./types\"\n\n/** Props for `<PrismicTable />`. */\nexport type PrismicTableProps = {\n\t/** The Prismic table field to render. */\n\tfield: TableField | undefined\n\n\t/**\n\t * An object that maps a table block type to a Vue component or a shorthand definition.\n\t *\n\t * @example\n\t * \t```javascript\n\t * \t;({\n\t * \t\ttable: Table,\n\t * \t\tthead: { class: \"bg-black text-white\" },\n\t * \t\tth: { as: \"td\", class: \"font-bold\" }\n\t * \t})\n\t * \t```\n\t */\n\tcomponents?: TableComponents & RichTextComponents\n\n\t/**\n\t * The value to be rendered when the field is empty. If a fallback is not given, `null` (nothing)\n\t * will be rendered.\n\t */\n\tfallback?: ComponentOrTagName\n}\n\nconst props = defineProps<PrismicTableProps>()\ndefineOptions({ name: \"PrismicTable\" })\n\nconst {\n\tcomponents: { richTextComponents },\n} = usePrismic()\n\nconst resolvedComponents = computed<TableComponents & RichTextComponents>(() => {\n\treturn { ...richTextComponents, ...props.components }\n})\n\nfunction getInternalComponent(type: keyof TableComponents) {\n\tconst maybeComponentOrShorthand = resolvedComponents.value?.[type]\n\n\tif (isComponent(maybeComponentOrShorthand)) {\n\t\treturn { is: maybeComponentOrShorthand }\n\t}\n\n\treturn {\n\t\tis: defaultTableComponents[type],\n\t\tshorthand: maybeComponentOrShorthand as ComponentShorthand,\n\t}\n}\n\nconst internalTableComponents = computed<InternalTableComponents>(() => {\n\treturn {\n\t\ttable: getInternalComponent(\"table\"),\n\t\tthead: getInternalComponent(\"thead\"),\n\t\ttbody: getInternalComponent(\"tbody\"),\n\t\ttr: getInternalComponent(\"tr\"),\n\t\tth: getInternalComponent(\"th\"),\n\t\ttd: getInternalComponent(\"td\"),\n\t}\n})\n</script>\n\n<template>\n\t<component\n\t\tv-if=\"isFilled.table(field)\"\n\t\t:is=\"internalTableComponents.table.is\"\n\t\t:table=\"field\"\n\t\tv-bind=\"{ ...$attrs, ...internalTableComponents.table.shorthand }\"\n\t>\n\t\t<component\n\t\t\tv-if=\"field.head\"\n\t\t\t:is=\"internalTableComponents.thead.is\"\n\t\t\t:head=\"field.head\"\n\t\t\tv-bind=\"internalTableComponents.thead.shorthand\"\n\t\t>\n\t\t\t<PrismicTableRow\n\t\t\t\tv-for=\"row in field.head.rows\"\n\t\t\t\t:key=\"row.key\"\n\t\t\t\t:row=\"row\"\n\t\t\t\t:internalTableComponents=\"internalTableComponents\"\n\t\t\t\t:components=\"components\"\n\t\t\t/>\n\t\t</component>\n\t\t<component\n\t\t\t:is=\"internalTableComponents.tbody.is\"\n\t\t\t:body=\"field.body\"\n\t\t\tv-bind=\"internalTableComponents.tbody.shorthand\"\n\t\t>\n\t\t\t<PrismicTableRow\n\t\t\t\tv-for=\"row in field.body.rows\"\n\t\t\t\t:key=\"row.key\"\n\t\t\t\t:row=\"row\"\n\t\t\t\t:internalTableComponents=\"internalTableComponents\"\n\t\t\t\t:components=\"components\"\n\t\t\t/>\n\t\t</component>\n\t</component>\n\t<component v-else-if=\"fallback\" :is=\"fallback\" v-bind=\"$attrs\" />\n</template>\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;EAsCA,MAAM,QAAQ;EAGd,MAAM,EACL,YAAY,EAAE,yBACX,WAAW;EAEf,MAAM,qBAAqB,eAAqD;GAC/E,OAAO;IAAE,GAAG;IAAoB,GAAG,MAAM;GAAW;EACrD,CAAC;EAED,SAAS,qBAAqB,MAA6B;GAC1D,MAAM,4BAA4B,mBAAmB,QAAQ;GAE7D,IAAI,YAAY,yBAAyB,GACxC,OAAO,EAAE,IAAI,0BAA0B;GAGxC,OAAO;IACN,IAAI,uBAAuB;IAC3B,WAAW;GACZ;EACD;EAEA,MAAM,0BAA0B,eAAwC;GACvE,OAAO;IACN,OAAO,qBAAqB,OAAO;IACnC,OAAO,qBAAqB,OAAO;IACnC,OAAO,qBAAqB,OAAO;IACnC,IAAI,qBAAqB,IAAI;IAC7B,IAAI,qBAAqB,IAAI;IAC7B,IAAI,qBAAqB,IAAI;GAC9B;EACD,CAAC;;GAKO,OAAAC,MAAA,QAAA,CAAQ,CAAC,MAAM,QAAA,KAAK,KAD3BC,UAAA,GAAAC,YAiCYC,wBA/BN,wBAAA,MAAwB,MAAM,EAAE,GAFtCC,WAiCY;;IA9BV,OAAO,QAAA;GACKL,GAAAA;IAAAA,GAAAA,KAAAA;IAAM,GAAK,wBAAA,MAAwB,MAAM;GAAS,CAAA,GAAA;IAE/D,SAAAM,cAaY,CAZL,QAAA,MAAM,QADbJ,UAAA,GAAAC,YAaYC,wBAXN,wBAAA,MAAwB,MAAM,EAAE,GAFtCC,WAaY;;KAVV,MAAM,QAAA,MAAM;IACL,GAAA,wBAAA,MAAwB,MAAM,SAAS,GAAA;KAG9C,SAAAC,cAA8B,EAD/BJ,UAAA,IAAA,GAAAK,mBAMEC,UAAA,MAAAC,WALa,QAAA,MAAM,KAAK,OAAlB,QAAG;MADX,OAAAP,UAAA,GAAAC,YAMEO,yBAAA;OAJA,KAAK,IAAI;OACJ;OACL,yBAAyB,wBAAA;OACzB,YAAY,QAAA;;;;;;;;I,uDAGfR,UAAA,GAAAC,YAYYC,wBAXN,wBAAA,MAAwB,MAAM,EAAE,GADtCC,WAYY,EAVV,MAAM,QAAA,MAAM,KACL,GAAA,wBAAA,MAAwB,MAAM,SAAS,GAAA;KAG9C,SAAAC,cAA8B,EAD/BJ,UAAA,IAAA,GAAAK,mBAMEC,UAAA,MAAAC,WALa,QAAA,MAAM,KAAK,OAAlB,QAAG;MADX,OAAAP,UAAA,GAAAC,YAMEO,yBAAA;OAJA,KAAK,IAAI;OACJ;OACL,yBAAyB,wBAAA;OACzB,YAAY,QAAA;;;;;;;;;;G,qBAIM,QAAA,YAAtBR,UAAA,GAAAC,YAAiEC,wBAA5B,QAAA,QAAQ,GAAAQ,eAAAP,WAAA,EAAA,KAAA,EAAA,GAAUL,KAAAA,MAAM,CAAA,GAAA,MAAA,EAAA,K"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
const require_getTableComponentProps = require("./getTableComponentProps.cjs");
|
|
2
2
|
let vue = require("vue");
|
|
3
|
-
|
|
3
|
+
// src/PrismicTable/PrismicTableDefaultComponents.ts
|
|
4
4
|
const defaultTableComponents = {
|
|
5
5
|
table: (0, vue.defineComponent)({
|
|
6
6
|
props: require_getTableComponentProps.table(),
|
|
@@ -39,7 +39,6 @@ const defaultTableComponents = {
|
|
|
39
39
|
}
|
|
40
40
|
})
|
|
41
41
|
};
|
|
42
|
-
//#endregion
|
|
43
42
|
exports.defaultTableComponents = defaultTableComponents;
|
|
44
43
|
|
|
45
44
|
//# sourceMappingURL=PrismicTableDefaultComponents.cjs.map
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { table, tbody, td, th, thead, tr } from "./getTableComponentProps.js";
|
|
2
2
|
import { defineComponent, h } from "vue";
|
|
3
|
-
|
|
3
|
+
// src/PrismicTable/PrismicTableDefaultComponents.ts
|
|
4
4
|
const defaultTableComponents = {
|
|
5
5
|
table: defineComponent({
|
|
6
6
|
props: table(),
|
|
@@ -39,7 +39,6 @@ const defaultTableComponents = {
|
|
|
39
39
|
}
|
|
40
40
|
})
|
|
41
41
|
};
|
|
42
|
-
//#endregion
|
|
43
42
|
export { defaultTableComponents };
|
|
44
43
|
|
|
45
44
|
//# sourceMappingURL=PrismicTableDefaultComponents.js.map
|
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
|
|
1
|
+
// src/PrismicTable/PrismicTableRow.vue
|
|
2
2
|
var PrismicTableRow_default = require("./PrismicTableRow.vue_vue_type_script_setup_true_lang.cjs").default;
|
|
3
|
-
//#endregion
|
|
4
3
|
exports.default = PrismicTableRow_default;
|
|
5
4
|
|
|
6
5
|
//# sourceMappingURL=PrismicTableRow.cjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PrismicTableRow.cjs","names":[],"sources":["../../src/PrismicTable/PrismicTableRow.vue"],"sourcesContent":["<script lang=\"ts\" setup>\nimport type { TableFieldBodyRow, TableFieldHeadRow } from \"@prismicio/client\"\n\nimport type { RichTextComponents } from \"../PrismicRichText\"\nimport PrismicRichText from \"../PrismicRichText/PrismicRichText.vue\"\nimport type { InternalTableComponents } from \"./types\"\n\nexport type PrismicTableRowProps = {\n\trow: TableFieldHeadRow | TableFieldBodyRow\n\tinternalTableComponents: InternalTableComponents\n\tcomponents?: RichTextComponents\n}\n\nconst props = defineProps<PrismicTableRowProps>()\ndefineOptions({ name: \"PrismicTableRow\" })\n</script>\n\n<template>\n\t<component\n\t\t:is=\"internalTableComponents.tr.is\"\n\t\t:row=\"row\"\n\t\tv-bind=\"internalTableComponents.tr.shorthand\"\n\t>\n\t\t<template v-for=\"cell in row.cells\" :key=\"cell.key\">\n\t\t\t<component\n\t\t\t\tv-if=\"cell.type === 'header'\"\n\t\t\t\t:is=\"internalTableComponents.th.is\"\n\t\t\t\t:cell=\"cell\"\n\t\t\t\tv-bind=\"internalTableComponents.th.shorthand\"\n\t\t\t>\n\t\t\t\t<PrismicRichText :field=\"cell.content\" :components=\"components\" />\n\t\t\t</component>\n\t\t\t<component\n\t\t\t\tv-else\n\t\t\t\t:is=\"internalTableComponents.td.is\"\n\t\t\t\t:cell=\"cell\"\n\t\t\t\tv-bind=\"internalTableComponents.td.shorthand\"\n\t\t\t>\n\t\t\t\t<PrismicRichText :field=\"cell.content\" :components=\"components\" />\n\t\t\t</component>\n\t\t</template>\n\t</component>\n</template>\n"],"mappings":""}
|
|
1
|
+
{"version":3,"file":"PrismicTableRow.cjs","names":["_sfc_main"],"sources":["../../src/PrismicTable/PrismicTableRow.vue"],"sourcesContent":["<script lang=\"ts\" setup>\nimport type { TableFieldBodyRow, TableFieldHeadRow } from \"@prismicio/client\"\n\nimport type { RichTextComponents } from \"../PrismicRichText\"\nimport PrismicRichText from \"../PrismicRichText/PrismicRichText.vue\"\nimport type { InternalTableComponents } from \"./types\"\n\nexport type PrismicTableRowProps = {\n\trow: TableFieldHeadRow | TableFieldBodyRow\n\tinternalTableComponents: InternalTableComponents\n\tcomponents?: RichTextComponents\n}\n\nconst props = defineProps<PrismicTableRowProps>()\ndefineOptions({ name: \"PrismicTableRow\" })\n</script>\n\n<template>\n\t<component\n\t\t:is=\"internalTableComponents.tr.is\"\n\t\t:row=\"row\"\n\t\tv-bind=\"internalTableComponents.tr.shorthand\"\n\t>\n\t\t<template v-for=\"cell in row.cells\" :key=\"cell.key\">\n\t\t\t<component\n\t\t\t\tv-if=\"cell.type === 'header'\"\n\t\t\t\t:is=\"internalTableComponents.th.is\"\n\t\t\t\t:cell=\"cell\"\n\t\t\t\tv-bind=\"internalTableComponents.th.shorthand\"\n\t\t\t>\n\t\t\t\t<PrismicRichText :field=\"cell.content\" :components=\"components\" />\n\t\t\t</component>\n\t\t\t<component\n\t\t\t\tv-else\n\t\t\t\t:is=\"internalTableComponents.td.is\"\n\t\t\t\t:cell=\"cell\"\n\t\t\t\tv-bind=\"internalTableComponents.td.shorthand\"\n\t\t\t>\n\t\t\t\t<PrismicRichText :field=\"cell.content\" :components=\"components\" />\n\t\t\t</component>\n\t\t</template>\n\t</component>\n</template>\n"],"mappings":""}
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import PrismicTableRow_vue_vue_type_script_setup_true_lang_default from "./PrismicTableRow.vue_vue_type_script_setup_true_lang.js";
|
|
2
|
-
|
|
2
|
+
// src/PrismicTable/PrismicTableRow.vue
|
|
3
3
|
var PrismicTableRow_default = PrismicTableRow_vue_vue_type_script_setup_true_lang_default;
|
|
4
|
-
//#endregion
|
|
5
4
|
export { PrismicTableRow_default as default };
|
|
6
5
|
|
|
7
6
|
//# sourceMappingURL=PrismicTableRow.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PrismicTableRow.js","names":[],"sources":["../../src/PrismicTable/PrismicTableRow.vue"],"sourcesContent":["<script lang=\"ts\" setup>\nimport type { TableFieldBodyRow, TableFieldHeadRow } from \"@prismicio/client\"\n\nimport type { RichTextComponents } from \"../PrismicRichText\"\nimport PrismicRichText from \"../PrismicRichText/PrismicRichText.vue\"\nimport type { InternalTableComponents } from \"./types\"\n\nexport type PrismicTableRowProps = {\n\trow: TableFieldHeadRow | TableFieldBodyRow\n\tinternalTableComponents: InternalTableComponents\n\tcomponents?: RichTextComponents\n}\n\nconst props = defineProps<PrismicTableRowProps>()\ndefineOptions({ name: \"PrismicTableRow\" })\n</script>\n\n<template>\n\t<component\n\t\t:is=\"internalTableComponents.tr.is\"\n\t\t:row=\"row\"\n\t\tv-bind=\"internalTableComponents.tr.shorthand\"\n\t>\n\t\t<template v-for=\"cell in row.cells\" :key=\"cell.key\">\n\t\t\t<component\n\t\t\t\tv-if=\"cell.type === 'header'\"\n\t\t\t\t:is=\"internalTableComponents.th.is\"\n\t\t\t\t:cell=\"cell\"\n\t\t\t\tv-bind=\"internalTableComponents.th.shorthand\"\n\t\t\t>\n\t\t\t\t<PrismicRichText :field=\"cell.content\" :components=\"components\" />\n\t\t\t</component>\n\t\t\t<component\n\t\t\t\tv-else\n\t\t\t\t:is=\"internalTableComponents.td.is\"\n\t\t\t\t:cell=\"cell\"\n\t\t\t\tv-bind=\"internalTableComponents.td.shorthand\"\n\t\t\t>\n\t\t\t\t<PrismicRichText :field=\"cell.content\" :components=\"components\" />\n\t\t\t</component>\n\t\t</template>\n\t</component>\n</template>\n"],"mappings":""}
|
|
1
|
+
{"version":3,"file":"PrismicTableRow.js","names":["_sfc_main"],"sources":["../../src/PrismicTable/PrismicTableRow.vue"],"sourcesContent":["<script lang=\"ts\" setup>\nimport type { TableFieldBodyRow, TableFieldHeadRow } from \"@prismicio/client\"\n\nimport type { RichTextComponents } from \"../PrismicRichText\"\nimport PrismicRichText from \"../PrismicRichText/PrismicRichText.vue\"\nimport type { InternalTableComponents } from \"./types\"\n\nexport type PrismicTableRowProps = {\n\trow: TableFieldHeadRow | TableFieldBodyRow\n\tinternalTableComponents: InternalTableComponents\n\tcomponents?: RichTextComponents\n}\n\nconst props = defineProps<PrismicTableRowProps>()\ndefineOptions({ name: \"PrismicTableRow\" })\n</script>\n\n<template>\n\t<component\n\t\t:is=\"internalTableComponents.tr.is\"\n\t\t:row=\"row\"\n\t\tv-bind=\"internalTableComponents.tr.shorthand\"\n\t>\n\t\t<template v-for=\"cell in row.cells\" :key=\"cell.key\">\n\t\t\t<component\n\t\t\t\tv-if=\"cell.type === 'header'\"\n\t\t\t\t:is=\"internalTableComponents.th.is\"\n\t\t\t\t:cell=\"cell\"\n\t\t\t\tv-bind=\"internalTableComponents.th.shorthand\"\n\t\t\t>\n\t\t\t\t<PrismicRichText :field=\"cell.content\" :components=\"components\" />\n\t\t\t</component>\n\t\t\t<component\n\t\t\t\tv-else\n\t\t\t\t:is=\"internalTableComponents.td.is\"\n\t\t\t\t:cell=\"cell\"\n\t\t\t\tv-bind=\"internalTableComponents.td.shorthand\"\n\t\t\t>\n\t\t\t\t<PrismicRichText :field=\"cell.content\" :components=\"components\" />\n\t\t\t</component>\n\t\t</template>\n\t</component>\n</template>\n"],"mappings":""}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
const require_PrismicRichText = require("../PrismicRichText/PrismicRichText.cjs");
|
|
2
2
|
let vue = require("vue");
|
|
3
|
-
|
|
3
|
+
// src/PrismicTable/PrismicTableRow.vue?vue&type=script&setup=true&lang.ts
|
|
4
4
|
var PrismicTableRow_vue_vue_type_script_setup_true_lang_default = /*@__PURE__*/ (0, vue.defineComponent)({
|
|
5
5
|
name: "PrismicTableRow",
|
|
6
6
|
__name: "PrismicTableRow",
|
|
@@ -47,7 +47,6 @@ var PrismicTableRow_vue_vue_type_script_setup_true_lang_default = /*@__PURE__*/
|
|
|
47
47
|
};
|
|
48
48
|
}
|
|
49
49
|
});
|
|
50
|
-
//#endregion
|
|
51
50
|
exports.default = PrismicTableRow_vue_vue_type_script_setup_true_lang_default;
|
|
52
51
|
|
|
53
52
|
//# sourceMappingURL=PrismicTableRow.vue_vue_type_script_setup_true_lang.cjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PrismicTableRow.vue_vue_type_script_setup_true_lang.cjs","names":[],"sources":["../../src/PrismicTable/PrismicTableRow.vue"],"sourcesContent":["<script lang=\"ts\" setup>\nimport type { TableFieldBodyRow, TableFieldHeadRow } from \"@prismicio/client\"\n\nimport type { RichTextComponents } from \"../PrismicRichText\"\nimport PrismicRichText from \"../PrismicRichText/PrismicRichText.vue\"\nimport type { InternalTableComponents } from \"./types\"\n\nexport type PrismicTableRowProps = {\n\trow: TableFieldHeadRow | TableFieldBodyRow\n\tinternalTableComponents: InternalTableComponents\n\tcomponents?: RichTextComponents\n}\n\nconst props = defineProps<PrismicTableRowProps>()\ndefineOptions({ name: \"PrismicTableRow\" })\n</script>\n\n<template>\n\t<component\n\t\t:is=\"internalTableComponents.tr.is\"\n\t\t:row=\"row\"\n\t\tv-bind=\"internalTableComponents.tr.shorthand\"\n\t>\n\t\t<template v-for=\"cell in row.cells\" :key=\"cell.key\">\n\t\t\t<component\n\t\t\t\tv-if=\"cell.type === 'header'\"\n\t\t\t\t:is=\"internalTableComponents.th.is\"\n\t\t\t\t:cell=\"cell\"\n\t\t\t\tv-bind=\"internalTableComponents.th.shorthand\"\n\t\t\t>\n\t\t\t\t<PrismicRichText :field=\"cell.content\" :components=\"components\" />\n\t\t\t</component>\n\t\t\t<component\n\t\t\t\tv-else\n\t\t\t\t:is=\"internalTableComponents.td.is\"\n\t\t\t\t:cell=\"cell\"\n\t\t\t\tv-bind=\"internalTableComponents.td.shorthand\"\n\t\t\t>\n\t\t\t\t<PrismicRichText :field=\"cell.content\" :components=\"components\" />\n\t\t\t</component>\n\t\t</template>\n\t</component>\n</template>\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;GAkBC,QAAA,
|
|
1
|
+
{"version":3,"file":"PrismicTableRow.vue_vue_type_script_setup_true_lang.cjs","names":["_openBlock","_createBlock","_resolveDynamicComponent","_mergeProps","_withCtx","_createElementBlock","_Fragment","_renderList","_createVNode","PrismicRichText"],"sources":["../../src/PrismicTable/PrismicTableRow.vue"],"sourcesContent":["<script lang=\"ts\" setup>\nimport type { TableFieldBodyRow, TableFieldHeadRow } from \"@prismicio/client\"\n\nimport type { RichTextComponents } from \"../PrismicRichText\"\nimport PrismicRichText from \"../PrismicRichText/PrismicRichText.vue\"\nimport type { InternalTableComponents } from \"./types\"\n\nexport type PrismicTableRowProps = {\n\trow: TableFieldHeadRow | TableFieldBodyRow\n\tinternalTableComponents: InternalTableComponents\n\tcomponents?: RichTextComponents\n}\n\nconst props = defineProps<PrismicTableRowProps>()\ndefineOptions({ name: \"PrismicTableRow\" })\n</script>\n\n<template>\n\t<component\n\t\t:is=\"internalTableComponents.tr.is\"\n\t\t:row=\"row\"\n\t\tv-bind=\"internalTableComponents.tr.shorthand\"\n\t>\n\t\t<template v-for=\"cell in row.cells\" :key=\"cell.key\">\n\t\t\t<component\n\t\t\t\tv-if=\"cell.type === 'header'\"\n\t\t\t\t:is=\"internalTableComponents.th.is\"\n\t\t\t\t:cell=\"cell\"\n\t\t\t\tv-bind=\"internalTableComponents.th.shorthand\"\n\t\t\t>\n\t\t\t\t<PrismicRichText :field=\"cell.content\" :components=\"components\" />\n\t\t\t</component>\n\t\t\t<component\n\t\t\t\tv-else\n\t\t\t\t:is=\"internalTableComponents.td.is\"\n\t\t\t\t:cell=\"cell\"\n\t\t\t\tv-bind=\"internalTableComponents.td.shorthand\"\n\t\t\t>\n\t\t\t\t<PrismicRichText :field=\"cell.content\" :components=\"components\" />\n\t\t\t</component>\n\t\t</template>\n\t</component>\n</template>\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;GAkBC,QAAA,GAAAA,IAAAA,UAAAA,CAAA,IAAA,GAAAC,IAAAA,YAAAA,EAAAA,GAuBYC,IAAAA,wBAAAA,CAtBN,QAAA,wBAAwB,GAAG,EAAE,IAAA,GADnCC,IAAAA,WAAAA,CAuBY,EArBV,KAAK,QAAA,IAAG,GACD,QAAA,wBAAwB,GAAG,SAAS,GAAA;IAElC,UAAA,GAAAC,IAAAA,QAAAA,OAAyB,GAAA,GAAnCJ,IAAAA,UAAAA,CAAA,IAAA,IAAA,GAAAK,IAAAA,mBAAAA,CAiBWC,IAAAA,UAAA,OAAA,GAAAC,IAAAA,WAAAA,CAjBc,QAAA,IAAI,QAAZ,SAAI;K,yEAAqB,KAAA,KAAK,I,IAEvC,KAAK,SAAI,aAAA,GADhBP,IAAAA,UAAAA,CAAA,IAAA,GAAAC,IAAAA,YAAAA,EAAAA,GAOYC,IAAAA,wBAAAA,CALN,QAAA,wBAAwB,GAAG,EAAE,IAAA,GAFnCC,IAAAA,WAAAA,CAOY;;MAJJ;KACC,GAAA,EAAA,SAAA,KAAA,GAAA,QAAA,wBAAwB,GAAG,SAAS,GAAA;MAE5C,UAAA,GAAAC,IAAAA,QAAAA,OAAkE,EAAA,GAAlEI,IAAAA,YAAAA,CAAkEC,wBAAAA,SAAA;OAAhD,OAAO,KAAK;OAAU,YAAY,QAAA;;;K,2BAErDT,IAAAA,UAAAA,CAAA,IAAA,GAAAC,IAAAA,YAAAA,EAAAA,GAOYC,IAAAA,wBAAAA,CALN,QAAA,wBAAwB,GAAG,EAAE,IAAA,GAFnCC,IAAAA,WAAAA,CAOY;;MAJJ;KACC,GAAA,EAAA,SAAA,KAAA,GAAA,QAAA,wBAAwB,GAAG,SAAS,GAAA;MAE5C,UAAA,GAAAC,IAAAA,QAAAA,OAAkE,EAAA,GAAlEI,IAAAA,YAAAA,CAAkEC,wBAAAA,SAAA;OAAhD,OAAO,KAAK;OAAU,YAAY,QAAA"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import PrismicRichText_default from "../PrismicRichText/PrismicRichText.js";
|
|
2
2
|
import { Fragment, createBlock, createElementBlock, createVNode, defineComponent, mergeProps, openBlock, renderList, resolveDynamicComponent, withCtx } from "vue";
|
|
3
|
-
|
|
3
|
+
// src/PrismicTable/PrismicTableRow.vue?vue&type=script&setup=true&lang.ts
|
|
4
4
|
var PrismicTableRow_vue_vue_type_script_setup_true_lang_default = /*@__PURE__*/ defineComponent({
|
|
5
5
|
name: "PrismicTableRow",
|
|
6
6
|
__name: "PrismicTableRow",
|
|
@@ -47,7 +47,6 @@ var PrismicTableRow_vue_vue_type_script_setup_true_lang_default = /*@__PURE__*/
|
|
|
47
47
|
};
|
|
48
48
|
}
|
|
49
49
|
});
|
|
50
|
-
//#endregion
|
|
51
50
|
export { PrismicTableRow_vue_vue_type_script_setup_true_lang_default as default };
|
|
52
51
|
|
|
53
52
|
//# sourceMappingURL=PrismicTableRow.vue_vue_type_script_setup_true_lang.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PrismicTableRow.vue_vue_type_script_setup_true_lang.js","names":[],"sources":["../../src/PrismicTable/PrismicTableRow.vue"],"sourcesContent":["<script lang=\"ts\" setup>\nimport type { TableFieldBodyRow, TableFieldHeadRow } from \"@prismicio/client\"\n\nimport type { RichTextComponents } from \"../PrismicRichText\"\nimport PrismicRichText from \"../PrismicRichText/PrismicRichText.vue\"\nimport type { InternalTableComponents } from \"./types\"\n\nexport type PrismicTableRowProps = {\n\trow: TableFieldHeadRow | TableFieldBodyRow\n\tinternalTableComponents: InternalTableComponents\n\tcomponents?: RichTextComponents\n}\n\nconst props = defineProps<PrismicTableRowProps>()\ndefineOptions({ name: \"PrismicTableRow\" })\n</script>\n\n<template>\n\t<component\n\t\t:is=\"internalTableComponents.tr.is\"\n\t\t:row=\"row\"\n\t\tv-bind=\"internalTableComponents.tr.shorthand\"\n\t>\n\t\t<template v-for=\"cell in row.cells\" :key=\"cell.key\">\n\t\t\t<component\n\t\t\t\tv-if=\"cell.type === 'header'\"\n\t\t\t\t:is=\"internalTableComponents.th.is\"\n\t\t\t\t:cell=\"cell\"\n\t\t\t\tv-bind=\"internalTableComponents.th.shorthand\"\n\t\t\t>\n\t\t\t\t<PrismicRichText :field=\"cell.content\" :components=\"components\" />\n\t\t\t</component>\n\t\t\t<component\n\t\t\t\tv-else\n\t\t\t\t:is=\"internalTableComponents.td.is\"\n\t\t\t\t:cell=\"cell\"\n\t\t\t\tv-bind=\"internalTableComponents.td.shorthand\"\n\t\t\t>\n\t\t\t\t<PrismicRichText :field=\"cell.content\" :components=\"components\" />\n\t\t\t</component>\n\t\t</template>\n\t</component>\n</template>\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;GAkBC,
|
|
1
|
+
{"version":3,"file":"PrismicTableRow.vue_vue_type_script_setup_true_lang.js","names":["_openBlock","_createBlock","_resolveDynamicComponent","_mergeProps","_withCtx","_createElementBlock","_Fragment","_renderList","_createVNode","PrismicRichText"],"sources":["../../src/PrismicTable/PrismicTableRow.vue"],"sourcesContent":["<script lang=\"ts\" setup>\nimport type { TableFieldBodyRow, TableFieldHeadRow } from \"@prismicio/client\"\n\nimport type { RichTextComponents } from \"../PrismicRichText\"\nimport PrismicRichText from \"../PrismicRichText/PrismicRichText.vue\"\nimport type { InternalTableComponents } from \"./types\"\n\nexport type PrismicTableRowProps = {\n\trow: TableFieldHeadRow | TableFieldBodyRow\n\tinternalTableComponents: InternalTableComponents\n\tcomponents?: RichTextComponents\n}\n\nconst props = defineProps<PrismicTableRowProps>()\ndefineOptions({ name: \"PrismicTableRow\" })\n</script>\n\n<template>\n\t<component\n\t\t:is=\"internalTableComponents.tr.is\"\n\t\t:row=\"row\"\n\t\tv-bind=\"internalTableComponents.tr.shorthand\"\n\t>\n\t\t<template v-for=\"cell in row.cells\" :key=\"cell.key\">\n\t\t\t<component\n\t\t\t\tv-if=\"cell.type === 'header'\"\n\t\t\t\t:is=\"internalTableComponents.th.is\"\n\t\t\t\t:cell=\"cell\"\n\t\t\t\tv-bind=\"internalTableComponents.th.shorthand\"\n\t\t\t>\n\t\t\t\t<PrismicRichText :field=\"cell.content\" :components=\"components\" />\n\t\t\t</component>\n\t\t\t<component\n\t\t\t\tv-else\n\t\t\t\t:is=\"internalTableComponents.td.is\"\n\t\t\t\t:cell=\"cell\"\n\t\t\t\tv-bind=\"internalTableComponents.td.shorthand\"\n\t\t\t>\n\t\t\t\t<PrismicRichText :field=\"cell.content\" :components=\"components\" />\n\t\t\t</component>\n\t\t</template>\n\t</component>\n</template>\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;GAkBC,OAAAA,UAAA,GAAAC,YAuBYC,wBAtBN,QAAA,wBAAwB,GAAG,EAAE,GADnCC,WAuBY,EArBV,KAAK,QAAA,IAAG,GACD,QAAA,wBAAwB,GAAG,SAAS,GAAA;IAElC,SAAAC,cAAyB,EAAnCJ,UAAA,IAAA,GAAAK,mBAiBWC,UAAA,MAAAC,WAjBc,QAAA,IAAI,QAAZ,SAAI;K,mDAAqB,KAAA,KAAK,I,IAEvC,KAAK,SAAI,YADhBP,UAAA,GAAAC,YAOYC,wBALN,QAAA,wBAAwB,GAAG,EAAE,GAFnCC,WAOY;;MAJJ;KACC,GAAA,EAAA,SAAA,KAAA,GAAA,QAAA,wBAAwB,GAAG,SAAS,GAAA;MAE5C,SAAAC,cAAkE,CAAlEI,YAAkEC,yBAAA;OAAhD,OAAO,KAAK;OAAU,YAAY,QAAA;;;K,uBAErDT,UAAA,GAAAC,YAOYC,wBALN,QAAA,wBAAwB,GAAG,EAAE,GAFnCC,WAOY;;MAJJ;KACC,GAAA,EAAA,SAAA,KAAA,GAAA,QAAA,wBAAwB,GAAG,SAAS,GAAA;MAE5C,SAAAC,cAAkE,CAAlEI,YAAkEC,yBAAA;OAAhD,OAAO,KAAK;OAAU,YAAY,QAAA"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
|
|
1
|
+
// src/PrismicTable/getTableComponentProps.ts
|
|
2
2
|
var getTableComponentProps_exports = /* @__PURE__ */ require("../_virtual/_rolldown/runtime.cjs").__exportAll({
|
|
3
3
|
table: () => table,
|
|
4
4
|
tbody: () => tbody,
|
|
@@ -115,7 +115,6 @@ const td = () => ({ cell: {
|
|
|
115
115
|
type: Object,
|
|
116
116
|
required: true
|
|
117
117
|
} });
|
|
118
|
-
//#endregion
|
|
119
118
|
Object.defineProperty(exports, "getTableComponentProps_exports", {
|
|
120
119
|
enumerable: true,
|
|
121
120
|
get: function() {
|
|
@@ -17,7 +17,7 @@ declare namespace getTableComponentProps_d_exports {
|
|
|
17
17
|
* defineProps(getTableComponentProps.table())
|
|
18
18
|
* ```
|
|
19
19
|
*/
|
|
20
|
-
declare const table: () => {
|
|
20
|
+
export declare const table: () => {
|
|
21
21
|
table: {
|
|
22
22
|
type: PropType<TableField<"filled">>;
|
|
23
23
|
required: true;
|
|
@@ -37,7 +37,7 @@ declare const table: () => {
|
|
|
37
37
|
* defineProps(getTableComponentProps.thead())
|
|
38
38
|
* ```
|
|
39
39
|
*/
|
|
40
|
-
declare const thead: () => {
|
|
40
|
+
export declare const thead: () => {
|
|
41
41
|
head: {
|
|
42
42
|
type: PropType<TableFieldHead>;
|
|
43
43
|
required: true;
|
|
@@ -57,7 +57,7 @@ declare const thead: () => {
|
|
|
57
57
|
* defineProps(getTableComponentProps.body())
|
|
58
58
|
* ```
|
|
59
59
|
*/
|
|
60
|
-
declare const tbody: () => {
|
|
60
|
+
export declare const tbody: () => {
|
|
61
61
|
body: {
|
|
62
62
|
type: PropType<TableFieldBody>;
|
|
63
63
|
required: true;
|
|
@@ -77,7 +77,7 @@ declare const tbody: () => {
|
|
|
77
77
|
* defineProps(getTableComponentProps.tr())
|
|
78
78
|
* ```
|
|
79
79
|
*/
|
|
80
|
-
declare const tr: () => {
|
|
80
|
+
export declare const tr: () => {
|
|
81
81
|
row: {
|
|
82
82
|
type: PropType<TableFieldHeadRow | TableFieldBodyRow>;
|
|
83
83
|
required: true;
|
|
@@ -97,7 +97,7 @@ declare const tr: () => {
|
|
|
97
97
|
* defineProps(getTableComponentProps.th())
|
|
98
98
|
* ```
|
|
99
99
|
*/
|
|
100
|
-
declare const th: () => {
|
|
100
|
+
export declare const th: () => {
|
|
101
101
|
cell: {
|
|
102
102
|
type: PropType<TableFieldHeaderCell>;
|
|
103
103
|
required: true;
|
|
@@ -117,12 +117,11 @@ declare const th: () => {
|
|
|
117
117
|
* defineProps(getTableComponentProps.td())
|
|
118
118
|
* ```
|
|
119
119
|
*/
|
|
120
|
-
declare const td: () => {
|
|
120
|
+
export declare const td: () => {
|
|
121
121
|
cell: {
|
|
122
122
|
type: PropType<TableFieldDataCell>;
|
|
123
123
|
required: true;
|
|
124
124
|
};
|
|
125
125
|
};
|
|
126
|
-
|
|
127
|
-
export { getTableComponentProps_d_exports, table, tbody, td, th, thead, tr };
|
|
126
|
+
export { getTableComponentProps_d_exports };
|
|
128
127
|
//# sourceMappingURL=getTableComponentProps.d.cts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getTableComponentProps.d.cts","names":[],"sources":["../../src/PrismicTable/getTableComponentProps.ts"],"mappings":";;;;;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"getTableComponentProps.d.cts","names":[],"sources":["../../src/PrismicTable/getTableComponentProps.ts"],"mappings":";;;;;;;;;;;;;;;;;;;qBAyBa;EACZ;IAAS,MAAM,SAAS;IAAuB;;;;;;;;;;;;;;;;;qBAmBnC;EACZ;IAAQ,MAAM,SAAS;IAAiB;;;;;;;;;;;;;;;;;qBAmB5B;EACZ;IAAQ,MAAM,SAAS;IAAiB;;;;;;;;;;;;;;;;;qBAmB5B;EACZ;IACC,MAAM,SAAS,oBAAoB;IACnC;;;;;;;;;;;;;;;;;qBAuBW;EACZ;IAAQ,MAAM,SAAS;IAAuB;;;;;;;;;;;;;;;;;qBAmBlC;EACZ;IAAQ,MAAM,SAAS;IAAqB"}
|
|
@@ -17,7 +17,7 @@ declare namespace getTableComponentProps_d_exports {
|
|
|
17
17
|
* defineProps(getTableComponentProps.table())
|
|
18
18
|
* ```
|
|
19
19
|
*/
|
|
20
|
-
declare const table: () => {
|
|
20
|
+
export declare const table: () => {
|
|
21
21
|
table: {
|
|
22
22
|
type: PropType<TableField<"filled">>;
|
|
23
23
|
required: true;
|
|
@@ -37,7 +37,7 @@ declare const table: () => {
|
|
|
37
37
|
* defineProps(getTableComponentProps.thead())
|
|
38
38
|
* ```
|
|
39
39
|
*/
|
|
40
|
-
declare const thead: () => {
|
|
40
|
+
export declare const thead: () => {
|
|
41
41
|
head: {
|
|
42
42
|
type: PropType<TableFieldHead>;
|
|
43
43
|
required: true;
|
|
@@ -57,7 +57,7 @@ declare const thead: () => {
|
|
|
57
57
|
* defineProps(getTableComponentProps.body())
|
|
58
58
|
* ```
|
|
59
59
|
*/
|
|
60
|
-
declare const tbody: () => {
|
|
60
|
+
export declare const tbody: () => {
|
|
61
61
|
body: {
|
|
62
62
|
type: PropType<TableFieldBody>;
|
|
63
63
|
required: true;
|
|
@@ -77,7 +77,7 @@ declare const tbody: () => {
|
|
|
77
77
|
* defineProps(getTableComponentProps.tr())
|
|
78
78
|
* ```
|
|
79
79
|
*/
|
|
80
|
-
declare const tr: () => {
|
|
80
|
+
export declare const tr: () => {
|
|
81
81
|
row: {
|
|
82
82
|
type: PropType<TableFieldHeadRow | TableFieldBodyRow>;
|
|
83
83
|
required: true;
|
|
@@ -97,7 +97,7 @@ declare const tr: () => {
|
|
|
97
97
|
* defineProps(getTableComponentProps.th())
|
|
98
98
|
* ```
|
|
99
99
|
*/
|
|
100
|
-
declare const th: () => {
|
|
100
|
+
export declare const th: () => {
|
|
101
101
|
cell: {
|
|
102
102
|
type: PropType<TableFieldHeaderCell>;
|
|
103
103
|
required: true;
|
|
@@ -117,12 +117,11 @@ declare const th: () => {
|
|
|
117
117
|
* defineProps(getTableComponentProps.td())
|
|
118
118
|
* ```
|
|
119
119
|
*/
|
|
120
|
-
declare const td: () => {
|
|
120
|
+
export declare const td: () => {
|
|
121
121
|
cell: {
|
|
122
122
|
type: PropType<TableFieldDataCell>;
|
|
123
123
|
required: true;
|
|
124
124
|
};
|
|
125
125
|
};
|
|
126
|
-
|
|
127
|
-
export { getTableComponentProps_d_exports, table, tbody, td, th, thead, tr };
|
|
126
|
+
export { getTableComponentProps_d_exports };
|
|
128
127
|
//# sourceMappingURL=getTableComponentProps.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getTableComponentProps.d.ts","names":[],"sources":["../../src/PrismicTable/getTableComponentProps.ts"],"mappings":";;;;;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"getTableComponentProps.d.ts","names":[],"sources":["../../src/PrismicTable/getTableComponentProps.ts"],"mappings":";;;;;;;;;;;;;;;;;;;qBAyBa;EACZ;IAAS,MAAM,SAAS;IAAuB;;;;;;;;;;;;;;;;;qBAmBnC;EACZ;IAAQ,MAAM,SAAS;IAAiB;;;;;;;;;;;;;;;;;qBAmB5B;EACZ;IAAQ,MAAM,SAAS;IAAiB;;;;;;;;;;;;;;;;;qBAmB5B;EACZ;IACC,MAAM,SAAS,oBAAoB;IACnC;;;;;;;;;;;;;;;;;qBAuBW;EACZ;IAAQ,MAAM,SAAS;IAAuB;;;;;;;;;;;;;;;;;qBAmBlC;EACZ;IAAQ,MAAM,SAAS;IAAqB"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { __exportAll } from "../_virtual/_rolldown/runtime.js";
|
|
2
|
-
|
|
2
|
+
// src/PrismicTable/getTableComponentProps.ts
|
|
3
3
|
var getTableComponentProps_exports = /* @__PURE__ */ __exportAll({
|
|
4
4
|
table: () => table,
|
|
5
5
|
tbody: () => tbody,
|
|
@@ -116,7 +116,6 @@ const td = () => ({ cell: {
|
|
|
116
116
|
type: Object,
|
|
117
117
|
required: true
|
|
118
118
|
} });
|
|
119
|
-
//#endregion
|
|
120
119
|
export { getTableComponentProps_exports, table, tbody, td, th, thead, tr };
|
|
121
120
|
|
|
122
121
|
//# sourceMappingURL=getTableComponentProps.js.map
|
|
@@ -1,12 +1,11 @@
|
|
|
1
1
|
import { Component, ComponentShorthand } from "../types.cjs";
|
|
2
2
|
import { TableField, TableFieldBody, TableFieldBodyRow, TableFieldDataCell, TableFieldHead, TableFieldHeadRow, TableFieldHeaderCell } from "@prismicio/client";
|
|
3
|
-
//#region src/PrismicTable/types.d.ts
|
|
4
3
|
/**
|
|
5
4
|
* A map of Table block types to Vue Components. It is used to render table fields.
|
|
6
5
|
*
|
|
7
6
|
* @see Templating Table fields from Prismic {@link https://prismic.io/docs/table}
|
|
8
7
|
*/
|
|
9
|
-
type TableComponents = {
|
|
8
|
+
export type TableComponents = {
|
|
10
9
|
table?: Component<{
|
|
11
10
|
table: TableField<"filled">;
|
|
12
11
|
}> | Omit<ComponentShorthand, "as">;
|
|
@@ -26,6 +25,4 @@ type TableComponents = {
|
|
|
26
25
|
cell: TableFieldDataCell;
|
|
27
26
|
}> | Omit<ComponentShorthand, "as">;
|
|
28
27
|
};
|
|
29
|
-
//#endregion
|
|
30
|
-
export { TableComponents };
|
|
31
28
|
//# sourceMappingURL=types.d.cts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.cts","names":[],"sources":["../../src/PrismicTable/types.ts"],"mappings":"
|
|
1
|
+
{"version":3,"file":"types.d.cts","names":[],"sources":["../../src/PrismicTable/types.ts"],"mappings":";;;;;;;YAiBY;EACX,QAAQ;IAAY,OAAO;OAA0B,KAAK;EAC1D,QAAQ;IAAY,MAAM;OAAoB,KAAK;EACnD,QAAQ;IAAY,MAAM;OAAoB,KAAK;EACnD,KAAK;IAAY,KAAK,oBAAoB;OAAuB,KAAK;EACtE,KAAK;IAAY,MAAM;OAA0B,KAAK;EACtD,KAAK;IAAY,MAAM;OAAwB,KAAK"}
|