@prismicio/vue 6.1.3 → 6.1.4-pr.98.764fac2
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.map +1 -1
- package/dist/PrismicImage.js.map +1 -1
- package/dist/PrismicImage.vue.d.cts +14 -11
- package/dist/PrismicImage.vue.d.cts.map +1 -1
- package/dist/PrismicImage.vue.d.ts +14 -11
- package/dist/PrismicImage.vue.d.ts.map +1 -1
- package/dist/PrismicImage.vue_vue_type_script_setup_true_lang.cjs +1 -1
- 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 -1
- package/dist/PrismicImage.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/PrismicLink.cjs.map +1 -1
- package/dist/PrismicLink.js.map +1 -1
- package/dist/PrismicLink.vue.d.cts +17 -13
- package/dist/PrismicLink.vue.d.cts.map +1 -1
- package/dist/PrismicLink.vue.d.ts +17 -13
- package/dist/PrismicLink.vue.d.ts.map +1 -1
- package/dist/PrismicLink.vue_vue_type_script_setup_true_lang.cjs +3 -3
- 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 +3 -3
- package/dist/PrismicLink.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/PrismicRichText/PrismicRichText.cjs.map +1 -1
- package/dist/PrismicRichText/PrismicRichText.js.map +1 -1
- package/dist/PrismicRichText/PrismicRichText.vue.d.cts +8 -9
- package/dist/PrismicRichText/PrismicRichText.vue.d.cts.map +1 -1
- package/dist/PrismicRichText/PrismicRichText.vue.d.ts +7 -8
- package/dist/PrismicRichText/PrismicRichText.vue.d.ts.map +1 -1
- package/dist/PrismicRichText/PrismicRichText.vue_vue_type_script_setup_true_lang.cjs +1 -1
- 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 -1
- package/dist/PrismicRichText/PrismicRichText.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/PrismicRichText/PrismicRichTextDefaultComponent.vue_vue_type_script_setup_true_lang.cjs +1 -1
- 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 -1
- package/dist/PrismicRichText/PrismicRichTextDefaultComponent.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/PrismicRichText/PrismicRichTextSerialize.vue_vue_type_script_setup_true_lang.cjs +1 -1
- 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 -1
- package/dist/PrismicRichText/PrismicRichTextSerialize.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/PrismicRichText/getRichTextComponentProps.cjs +2 -2
- package/dist/PrismicRichText/getRichTextComponentProps.cjs.map +1 -1
- package/dist/PrismicRichText/getRichTextComponentProps.d.cts +3 -4
- package/dist/PrismicRichText/getRichTextComponentProps.d.cts.map +1 -1
- package/dist/PrismicRichText/getRichTextComponentProps.d.ts +2 -3
- package/dist/PrismicRichText/getRichTextComponentProps.d.ts.map +1 -1
- package/dist/PrismicRichText/getRichTextComponentProps.js +2 -2
- package/dist/PrismicRichText/getRichTextComponentProps.js.map +1 -1
- package/dist/PrismicRichText/index.d.cts +2 -1
- package/dist/PrismicRichText/index.d.ts +2 -1
- package/dist/PrismicRichText/types.d.cts +1 -2
- package/dist/PrismicRichText/types.d.cts.map +1 -1
- package/dist/PrismicRichText/types.d.ts +1 -2
- package/dist/PrismicRichText/types.d.ts.map +1 -1
- package/dist/PrismicTable/PrismicTable.cjs.map +1 -1
- package/dist/PrismicTable/PrismicTable.js.map +1 -1
- package/dist/PrismicTable/PrismicTable.vue.d.cts +6 -6
- package/dist/PrismicTable/PrismicTable.vue.d.cts.map +1 -1
- package/dist/PrismicTable/PrismicTable.vue.d.ts +6 -6
- package/dist/PrismicTable/PrismicTable.vue.d.ts.map +1 -1
- package/dist/PrismicTable/PrismicTable.vue_vue_type_script_setup_true_lang.cjs +1 -1
- 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 -1
- package/dist/PrismicTable/PrismicTable.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/PrismicTable/PrismicTableDefaultComponents.cjs.map +1 -1
- package/dist/PrismicTable/PrismicTableDefaultComponents.js.map +1 -1
- package/dist/PrismicTable/PrismicTableRow.vue_vue_type_script_setup_true_lang.cjs +1 -1
- 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 -1
- package/dist/PrismicTable/PrismicTableRow.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/PrismicTable/getTableComponentProps.cjs +6 -6
- package/dist/PrismicTable/getTableComponentProps.cjs.map +1 -1
- package/dist/PrismicTable/getTableComponentProps.d.cts +8 -10
- package/dist/PrismicTable/getTableComponentProps.d.cts.map +1 -1
- package/dist/PrismicTable/getTableComponentProps.d.ts +7 -9
- package/dist/PrismicTable/getTableComponentProps.d.ts.map +1 -1
- package/dist/PrismicTable/getTableComponentProps.js +6 -6
- package/dist/PrismicTable/getTableComponentProps.js.map +1 -1
- package/dist/PrismicTable/index.d.cts +2 -1
- package/dist/PrismicTable/index.d.ts +2 -1
- package/dist/PrismicTable/types.d.cts +0 -1
- package/dist/PrismicTable/types.d.cts.map +1 -1
- package/dist/PrismicTable/types.d.ts +0 -1
- package/dist/PrismicTable/types.d.ts.map +1 -1
- package/dist/PrismicText.vue.d.cts +4 -5
- package/dist/PrismicText.vue.d.cts.map +1 -1
- package/dist/PrismicText.vue.d.ts +4 -5
- package/dist/PrismicText.vue.d.ts.map +1 -1
- package/dist/PrismicText.vue_vue_type_script_setup_true_lang.cjs +1 -1
- 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 -1
- package/dist/PrismicText.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/SliceSimulator.vue.d.cts +14 -15
- package/dist/SliceSimulator.vue.d.cts.map +1 -1
- package/dist/SliceSimulator.vue.d.ts +14 -15
- package/dist/SliceSimulator.vue.d.ts.map +1 -1
- package/dist/SliceSimulator.vue_vue_type_script_setup_true_lang.cjs +1 -1
- 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 -1
- package/dist/SliceSimulator.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/SliceZone/SliceZone.vue.d.cts +9 -7
- package/dist/SliceZone/SliceZone.vue.d.cts.map +1 -1
- package/dist/SliceZone/SliceZone.vue.d.ts +9 -7
- package/dist/SliceZone/SliceZone.vue.d.ts.map +1 -1
- package/dist/SliceZone/SliceZone.vue_vue_type_script_setup_true_lang.cjs +1 -1
- 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 +1 -1
- package/dist/SliceZone/SliceZone.vue_vue_type_script_setup_true_lang.js.map +1 -1
- package/dist/SliceZone/TODOSliceComponent.cjs.map +1 -1
- package/dist/SliceZone/TODOSliceComponent.d.cts +0 -1
- package/dist/SliceZone/TODOSliceComponent.d.cts.map +1 -1
- package/dist/SliceZone/TODOSliceComponent.d.ts +0 -1
- package/dist/SliceZone/TODOSliceComponent.d.ts.map +1 -1
- package/dist/SliceZone/TODOSliceComponent.js.map +1 -1
- package/dist/SliceZone/defineSliceZoneComponents.cjs +1 -1
- package/dist/SliceZone/defineSliceZoneComponents.cjs.map +1 -1
- package/dist/SliceZone/defineSliceZoneComponents.d.cts +1 -2
- package/dist/SliceZone/defineSliceZoneComponents.d.cts.map +1 -1
- package/dist/SliceZone/defineSliceZoneComponents.d.ts +1 -2
- package/dist/SliceZone/defineSliceZoneComponents.d.ts.map +1 -1
- package/dist/SliceZone/defineSliceZoneComponents.js +1 -1
- package/dist/SliceZone/defineSliceZoneComponents.js.map +1 -1
- package/dist/SliceZone/getSliceComponentProps.cjs +2 -2
- package/dist/SliceZone/getSliceComponentProps.cjs.map +1 -1
- package/dist/SliceZone/getSliceComponentProps.d.cts +2 -3
- package/dist/SliceZone/getSliceComponentProps.d.cts.map +1 -1
- package/dist/SliceZone/getSliceComponentProps.d.ts +2 -3
- package/dist/SliceZone/getSliceComponentProps.d.ts.map +1 -1
- package/dist/SliceZone/getSliceComponentProps.js +2 -2
- package/dist/SliceZone/getSliceComponentProps.js.map +1 -1
- package/dist/SliceZone/index.d.cts +2 -1
- package/dist/SliceZone/index.d.ts +2 -1
- package/dist/SliceZone/types.d.cts +8 -5
- package/dist/SliceZone/types.d.cts.map +1 -1
- package/dist/SliceZone/types.d.ts +8 -5
- package/dist/SliceZone/types.d.ts.map +1 -1
- package/dist/createPrismic.cjs +1 -1
- package/dist/createPrismic.cjs.map +1 -1
- package/dist/createPrismic.d.cts +18 -9
- package/dist/createPrismic.d.cts.map +1 -1
- package/dist/createPrismic.d.ts +17 -8
- package/dist/createPrismic.d.ts.map +1 -1
- package/dist/createPrismic.js +1 -1
- package/dist/createPrismic.js.map +1 -1
- package/dist/index.cjs +7 -7
- package/dist/index.d.cts +10 -7
- package/dist/index.d.ts +10 -7
- package/dist/lib/devMsg.cjs +1 -1
- package/dist/lib/devMsg.cjs.map +1 -1
- package/dist/lib/devMsg.js +1 -1
- package/dist/lib/devMsg.js.map +1 -1
- package/dist/lib/isInternalURL.cjs.map +1 -1
- package/dist/lib/isInternalURL.js.map +1 -1
- package/dist/package.cjs +1 -1
- package/dist/package.js +1 -1
- package/dist/types.cjs.map +1 -1
- package/dist/types.d.cts +3 -2
- package/dist/types.d.cts.map +1 -1
- package/dist/types.d.ts +3 -2
- package/dist/types.d.ts.map +1 -1
- package/dist/types.js.map +1 -1
- package/package.json +17 -17
- package/src/PrismicImage.vue +1 -1
- package/src/PrismicLink.vue +2 -2
- package/src/PrismicRichText/PrismicRichText.vue +1 -1
- package/src/PrismicRichText/getRichTextComponentProps.ts +2 -2
- package/src/PrismicTable/PrismicTable.vue +1 -1
- package/src/PrismicTable/getTableComponentProps.ts +6 -6
- package/src/SliceZone/defineSliceZoneComponents.ts +1 -1
- package/src/SliceZone/getSliceComponentProps.ts +2 -2
- package/src/createPrismic.ts +1 -1
- package/src/lib/devMsg.ts +1 -1
|
@@ -1,7 +1,5 @@
|
|
|
1
|
-
import { PropType } from "vue";
|
|
2
1
|
import { TableField, TableFieldBody, TableFieldBodyRow, TableFieldDataCell, TableFieldHead, TableFieldHeadRow, TableFieldHeaderCell } from "@prismicio/client";
|
|
3
|
-
|
|
4
|
-
//#region src/PrismicTable/getTableComponentProps.d.ts
|
|
2
|
+
import { PropType } from "vue";
|
|
5
3
|
declare namespace getTableComponentProps_d_exports {
|
|
6
4
|
export { table, tbody, td, th, thead, tr };
|
|
7
5
|
}
|
|
@@ -12,7 +10,7 @@ declare namespace getTableComponentProps_d_exports {
|
|
|
12
10
|
* Props are: `["table"]`
|
|
13
11
|
*
|
|
14
12
|
* @example
|
|
15
|
-
*
|
|
13
|
+
* ```javascript
|
|
16
14
|
* // Defining a new rich text component
|
|
17
15
|
* import { getTableComponentProps } from "@prismicio/vue"
|
|
18
16
|
*
|
|
@@ -32,7 +30,7 @@ declare const table: () => {
|
|
|
32
30
|
* Props are: `["head"]`
|
|
33
31
|
*
|
|
34
32
|
* @example
|
|
35
|
-
*
|
|
33
|
+
* ```javascript
|
|
36
34
|
* // Defining a new rich text component
|
|
37
35
|
* import { getTableComponentProps } from "@prismicio/vue"
|
|
38
36
|
*
|
|
@@ -52,7 +50,7 @@ declare const thead: () => {
|
|
|
52
50
|
* Props are: `["body"]`
|
|
53
51
|
*
|
|
54
52
|
* @example
|
|
55
|
-
*
|
|
53
|
+
* ```javascript
|
|
56
54
|
* // Defining a new rich text component
|
|
57
55
|
* import { getTableComponentProps } from "@prismicio/vue"
|
|
58
56
|
*
|
|
@@ -72,7 +70,7 @@ declare const tbody: () => {
|
|
|
72
70
|
* Props are: `["row"]`
|
|
73
71
|
*
|
|
74
72
|
* @example
|
|
75
|
-
*
|
|
73
|
+
* ```javascript
|
|
76
74
|
* // Defining a new rich text component
|
|
77
75
|
* import { getTableComponentProps } from "@prismicio/vue"
|
|
78
76
|
*
|
|
@@ -92,7 +90,7 @@ declare const tr: () => {
|
|
|
92
90
|
* Props are: `["cell"]`
|
|
93
91
|
*
|
|
94
92
|
* @example
|
|
95
|
-
*
|
|
93
|
+
* ```javascript
|
|
96
94
|
* // Defining a new rich text component
|
|
97
95
|
* import { getTableComponentProps } from "@prismicio/vue"
|
|
98
96
|
*
|
|
@@ -112,7 +110,7 @@ declare const th: () => {
|
|
|
112
110
|
* Props are: `["cell"]`
|
|
113
111
|
*
|
|
114
112
|
* @example
|
|
115
|
-
*
|
|
113
|
+
* ```javascript
|
|
116
114
|
* // Defining a new rich text component
|
|
117
115
|
* import { getTableComponentProps } from "@prismicio/vue"
|
|
118
116
|
*
|
|
@@ -126,5 +124,5 @@ declare const td: () => {
|
|
|
126
124
|
};
|
|
127
125
|
};
|
|
128
126
|
//#endregion
|
|
129
|
-
export { getTableComponentProps_d_exports };
|
|
127
|
+
export { getTableComponentProps_d_exports, table, tbody, td, th, thead, tr };
|
|
130
128
|
//# 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":";;;;;;;;;;;;;;;;;;;cAyBa;EACZ;IAAS,MAAM,SAAS;IAAuB;;;;;;;;;;;;;;;;;cAmBnC;EACZ;IAAQ,MAAM,SAAS;IAAiB;;;;;;;;;;;;;;;;;cAmB5B;EACZ;IAAQ,MAAM,SAAS;IAAiB;;;;;;;;;;;;;;;;;cAmB5B;EACZ;IACC,MAAM,SAAS,oBAAoB;IACnC;;;;;;;;;;;;;;;;;cAuBW;EACZ;IAAQ,MAAM,SAAS;IAAuB;;;;;;;;;;;;;;;;;cAmBlC;EACZ;IAAQ,MAAM,SAAS;IAAqB"}
|
|
@@ -1,7 +1,5 @@
|
|
|
1
1
|
import { PropType } from "vue";
|
|
2
2
|
import { TableField, TableFieldBody, TableFieldBodyRow, TableFieldDataCell, TableFieldHead, TableFieldHeadRow, TableFieldHeaderCell } from "@prismicio/client";
|
|
3
|
-
|
|
4
|
-
//#region src/PrismicTable/getTableComponentProps.d.ts
|
|
5
3
|
declare namespace getTableComponentProps_d_exports {
|
|
6
4
|
export { table, tbody, td, th, thead, tr };
|
|
7
5
|
}
|
|
@@ -12,7 +10,7 @@ declare namespace getTableComponentProps_d_exports {
|
|
|
12
10
|
* Props are: `["table"]`
|
|
13
11
|
*
|
|
14
12
|
* @example
|
|
15
|
-
*
|
|
13
|
+
* ```javascript
|
|
16
14
|
* // Defining a new rich text component
|
|
17
15
|
* import { getTableComponentProps } from "@prismicio/vue"
|
|
18
16
|
*
|
|
@@ -32,7 +30,7 @@ declare const table: () => {
|
|
|
32
30
|
* Props are: `["head"]`
|
|
33
31
|
*
|
|
34
32
|
* @example
|
|
35
|
-
*
|
|
33
|
+
* ```javascript
|
|
36
34
|
* // Defining a new rich text component
|
|
37
35
|
* import { getTableComponentProps } from "@prismicio/vue"
|
|
38
36
|
*
|
|
@@ -52,7 +50,7 @@ declare const thead: () => {
|
|
|
52
50
|
* Props are: `["body"]`
|
|
53
51
|
*
|
|
54
52
|
* @example
|
|
55
|
-
*
|
|
53
|
+
* ```javascript
|
|
56
54
|
* // Defining a new rich text component
|
|
57
55
|
* import { getTableComponentProps } from "@prismicio/vue"
|
|
58
56
|
*
|
|
@@ -72,7 +70,7 @@ declare const tbody: () => {
|
|
|
72
70
|
* Props are: `["row"]`
|
|
73
71
|
*
|
|
74
72
|
* @example
|
|
75
|
-
*
|
|
73
|
+
* ```javascript
|
|
76
74
|
* // Defining a new rich text component
|
|
77
75
|
* import { getTableComponentProps } from "@prismicio/vue"
|
|
78
76
|
*
|
|
@@ -92,7 +90,7 @@ declare const tr: () => {
|
|
|
92
90
|
* Props are: `["cell"]`
|
|
93
91
|
*
|
|
94
92
|
* @example
|
|
95
|
-
*
|
|
93
|
+
* ```javascript
|
|
96
94
|
* // Defining a new rich text component
|
|
97
95
|
* import { getTableComponentProps } from "@prismicio/vue"
|
|
98
96
|
*
|
|
@@ -112,7 +110,7 @@ declare const th: () => {
|
|
|
112
110
|
* Props are: `["cell"]`
|
|
113
111
|
*
|
|
114
112
|
* @example
|
|
115
|
-
*
|
|
113
|
+
* ```javascript
|
|
116
114
|
* // Defining a new rich text component
|
|
117
115
|
* import { getTableComponentProps } from "@prismicio/vue"
|
|
118
116
|
*
|
|
@@ -126,5 +124,5 @@ declare const td: () => {
|
|
|
126
124
|
};
|
|
127
125
|
};
|
|
128
126
|
//#endregion
|
|
129
|
-
export { getTableComponentProps_d_exports };
|
|
127
|
+
export { getTableComponentProps_d_exports, table, tbody, td, th, thead, tr };
|
|
130
128
|
//# 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":";;;;;;;;;;;;;;;;;;;cAyBa;EACZ;IAAS,MAAM,SAAS;IAAuB;;;;;;;;;;;;;;;;;cAmBnC;EACZ;IAAQ,MAAM,SAAS;IAAiB;;;;;;;;;;;;;;;;;cAmB5B;EACZ;IAAQ,MAAM,SAAS;IAAiB;;;;;;;;;;;;;;;;;cAmB5B;EACZ;IACC,MAAM,SAAS,oBAAoB;IACnC;;;;;;;;;;;;;;;;;cAuBW;EACZ;IAAQ,MAAM,SAAS;IAAuB;;;;;;;;;;;;;;;;;cAmBlC;EACZ;IAAQ,MAAM,SAAS;IAAqB"}
|
|
@@ -15,7 +15,7 @@ var getTableComponentProps_exports = /* @__PURE__ */ __exportAll({
|
|
|
15
15
|
* Props are: `["table"]`
|
|
16
16
|
*
|
|
17
17
|
* @example
|
|
18
|
-
*
|
|
18
|
+
* ```javascript
|
|
19
19
|
* // Defining a new rich text component
|
|
20
20
|
* import { getTableComponentProps } from "@prismicio/vue"
|
|
21
21
|
*
|
|
@@ -33,7 +33,7 @@ const table = () => ({ table: {
|
|
|
33
33
|
* Props are: `["head"]`
|
|
34
34
|
*
|
|
35
35
|
* @example
|
|
36
|
-
*
|
|
36
|
+
* ```javascript
|
|
37
37
|
* // Defining a new rich text component
|
|
38
38
|
* import { getTableComponentProps } from "@prismicio/vue"
|
|
39
39
|
*
|
|
@@ -51,7 +51,7 @@ const thead = () => ({ head: {
|
|
|
51
51
|
* Props are: `["body"]`
|
|
52
52
|
*
|
|
53
53
|
* @example
|
|
54
|
-
*
|
|
54
|
+
* ```javascript
|
|
55
55
|
* // Defining a new rich text component
|
|
56
56
|
* import { getTableComponentProps } from "@prismicio/vue"
|
|
57
57
|
*
|
|
@@ -69,7 +69,7 @@ const tbody = () => ({ body: {
|
|
|
69
69
|
* Props are: `["row"]`
|
|
70
70
|
*
|
|
71
71
|
* @example
|
|
72
|
-
*
|
|
72
|
+
* ```javascript
|
|
73
73
|
* // Defining a new rich text component
|
|
74
74
|
* import { getTableComponentProps } from "@prismicio/vue"
|
|
75
75
|
*
|
|
@@ -87,7 +87,7 @@ const tr = () => ({ row: {
|
|
|
87
87
|
* Props are: `["cell"]`
|
|
88
88
|
*
|
|
89
89
|
* @example
|
|
90
|
-
*
|
|
90
|
+
* ```javascript
|
|
91
91
|
* // Defining a new rich text component
|
|
92
92
|
* import { getTableComponentProps } from "@prismicio/vue"
|
|
93
93
|
*
|
|
@@ -105,7 +105,7 @@ const th = () => ({ cell: {
|
|
|
105
105
|
* Props are: `["cell"]`
|
|
106
106
|
*
|
|
107
107
|
* @example
|
|
108
|
-
*
|
|
108
|
+
* ```javascript
|
|
109
109
|
* // Defining a new rich text component
|
|
110
110
|
* import { getTableComponentProps } from "@prismicio/vue"
|
|
111
111
|
*
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getTableComponentProps.js","names":[],"sources":["../../src/PrismicTable/getTableComponentProps.ts"],"sourcesContent":["import type {\n\tTableField,\n\tTableFieldBody,\n\tTableFieldBodyRow,\n\tTableFieldDataCell,\n\tTableFieldHead,\n\tTableFieldHeadRow,\n\tTableFieldHeaderCell,\n} from \"@prismicio/client\"\nimport type { PropType } from \"vue\"\n\n/**\n * Gets native Vue props for a component rendering `table` elements from a Prismic table field with\n * `<PrismicTable />`.\n *\n * Props are: `[\"table\"]`\n *\n * @example\n * \t
|
|
1
|
+
{"version":3,"file":"getTableComponentProps.js","names":[],"sources":["../../src/PrismicTable/getTableComponentProps.ts"],"sourcesContent":["import type {\n\tTableField,\n\tTableFieldBody,\n\tTableFieldBodyRow,\n\tTableFieldDataCell,\n\tTableFieldHead,\n\tTableFieldHeadRow,\n\tTableFieldHeaderCell,\n} from \"@prismicio/client\"\nimport type { PropType } from \"vue\"\n\n/**\n * Gets native Vue props for a component rendering `table` elements from a Prismic table field with\n * `<PrismicTable />`.\n *\n * Props are: `[\"table\"]`\n *\n * @example\n * \t```javascript\n * \t// Defining a new rich text component\n * \timport { getTableComponentProps } from \"@prismicio/vue\"\n *\n * \tdefineProps(getTableComponentProps.table())\n * \t```\n */\nexport const table = (): {\n\ttable: { type: PropType<TableField<\"filled\">>; required: true }\n} => ({\n\ttable: { type: Object as PropType<TableField<\"filled\">>, required: true },\n})\n\n/**\n * Gets native Vue props for a component rendering `thead` elements from a Prismic table field with\n * `<PrismicTable />`.\n *\n * Props are: `[\"head\"]`\n *\n * @example\n * \t```javascript\n * \t// Defining a new rich text component\n * \timport { getTableComponentProps } from \"@prismicio/vue\"\n *\n * \tdefineProps(getTableComponentProps.thead())\n * \t```\n */\nexport const thead = (): {\n\thead: { type: PropType<TableFieldHead>; required: true }\n} => ({\n\thead: { type: Object as PropType<TableFieldHead>, required: true },\n})\n\n/**\n * Gets native Vue props for a component rendering `tbody` elements from a Prismic table field with\n * `<PrismicTable />`.\n *\n * Props are: `[\"body\"]`\n *\n * @example\n * \t```javascript\n * \t// Defining a new rich text component\n * \timport { getTableComponentProps } from \"@prismicio/vue\"\n *\n * \tdefineProps(getTableComponentProps.body())\n * \t```\n */\nexport const tbody = (): {\n\tbody: { type: PropType<TableFieldBody>; required: true }\n} => ({\n\tbody: { type: Object as PropType<TableFieldBody>, required: true },\n})\n\n/**\n * Gets native Vue props for a component rendering `tr` elements from a Prismic table field with\n * `<PrismicTable />`.\n *\n * Props are: `[\"row\"]`\n *\n * @example\n * \t```javascript\n * \t// Defining a new rich text component\n * \timport { getTableComponentProps } from \"@prismicio/vue\"\n *\n * \tdefineProps(getTableComponentProps.tr())\n * \t```\n */\nexport const tr = (): {\n\trow: {\n\t\ttype: PropType<TableFieldHeadRow | TableFieldBodyRow>\n\t\trequired: true\n\t}\n} => ({\n\trow: {\n\t\ttype: Object as PropType<TableFieldHeadRow | TableFieldBodyRow>,\n\t\trequired: true,\n\t},\n})\n\n/**\n * Gets native Vue props for a component rendering `th` elements from a Prismic table field with\n * `<PrismicTable />`.\n *\n * Props are: `[\"cell\"]`\n *\n * @example\n * \t```javascript\n * \t// Defining a new rich text component\n * \timport { getTableComponentProps } from \"@prismicio/vue\"\n *\n * \tdefineProps(getTableComponentProps.th())\n * \t```\n */\nexport const th = (): {\n\tcell: { type: PropType<TableFieldHeaderCell>; required: true }\n} => ({\n\tcell: { type: Object as PropType<TableFieldHeaderCell>, required: true },\n})\n\n/**\n * Gets native Vue props for a component rendering `td` elements from a Prismic table field with\n * `<PrismicTable />`.\n *\n * Props are: `[\"cell\"]`\n *\n * @example\n * \t```javascript\n * \t// Defining a new rich text component\n * \timport { getTableComponentProps } from \"@prismicio/vue\"\n *\n * \tdefineProps(getTableComponentProps.td())\n * \t```\n */\nexport const td = (): {\n\tcell: { type: PropType<TableFieldDataCell>; required: true }\n} => ({\n\tcell: { type: Object as PropType<TableFieldDataCell>, required: true },\n})\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;AAyBA,MAAa,eAEP,EACL,OAAO;CAAE,MAAM;CAA0C,UAAU;AAAK,EACzE;;;;;;;;;;;;;;;AAgBA,MAAa,eAEP,EACL,MAAM;CAAE,MAAM;CAAoC,UAAU;AAAK,EAClE;;;;;;;;;;;;;;;AAgBA,MAAa,eAEP,EACL,MAAM;CAAE,MAAM;CAAoC,UAAU;AAAK,EAClE;;;;;;;;;;;;;;;AAgBA,MAAa,YAKP,EACL,KAAK;CACJ,MAAM;CACN,UAAU;AACX,EACD;;;;;;;;;;;;;;;AAgBA,MAAa,YAEP,EACL,MAAM;CAAE,MAAM;CAA0C,UAAU;AAAK,EACxE;;;;;;;;;;;;;;;AAgBA,MAAa,YAEP,EACL,MAAM;CAAE,MAAM;CAAwC,UAAU;AAAK,EACtE"}
|
|
@@ -1,2 +1,3 @@
|
|
|
1
1
|
import { TableComponents } from "./types.cjs";
|
|
2
|
-
import { getTableComponentProps_d_exports } from "./getTableComponentProps.cjs";
|
|
2
|
+
import { getTableComponentProps_d_exports } from "./getTableComponentProps.cjs";
|
|
3
|
+
export { type TableComponents, getTableComponentProps_d_exports as getTableComponentProps };
|
|
@@ -1,2 +1,3 @@
|
|
|
1
1
|
import { TableComponents } from "./types.js";
|
|
2
|
-
import { getTableComponentProps_d_exports } from "./getTableComponentProps.js";
|
|
2
|
+
import { getTableComponentProps_d_exports } from "./getTableComponentProps.js";
|
|
3
|
+
export { type TableComponents, getTableComponentProps_d_exports as getTableComponentProps };
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { Component, ComponentShorthand } from "../types.cjs";
|
|
2
2
|
import { TableField, TableFieldBody, TableFieldBodyRow, TableFieldDataCell, TableFieldHead, TableFieldHeadRow, TableFieldHeaderCell } from "@prismicio/client";
|
|
3
|
-
|
|
4
3
|
//#region src/PrismicTable/types.d.ts
|
|
5
4
|
/**
|
|
6
5
|
* A map of Table block types to Vue Components. It is used to render table fields.
|
|
@@ -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":";;;;;;;;KAiBY;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"}
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { Component, ComponentShorthand } from "../types.js";
|
|
2
2
|
import { TableField, TableFieldBody, TableFieldBodyRow, TableFieldDataCell, TableFieldHead, TableFieldHeadRow, TableFieldHeaderCell } from "@prismicio/client";
|
|
3
|
-
|
|
4
3
|
//#region src/PrismicTable/types.d.ts
|
|
5
4
|
/**
|
|
6
5
|
* A map of Table block types to Vue Components. It is used to render table fields.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","names":[],"sources":["../../src/PrismicTable/types.ts"],"mappings":"
|
|
1
|
+
{"version":3,"file":"types.d.ts","names":[],"sources":["../../src/PrismicTable/types.ts"],"mappings":";;;;;;;;KAiBY;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"}
|
|
@@ -1,10 +1,9 @@
|
|
|
1
|
-
import * as _$vue from "vue";
|
|
2
1
|
import { RichTextField } from "@prismicio/client";
|
|
3
|
-
|
|
4
2
|
//#region src/PrismicText.vue.d.ts
|
|
5
3
|
/** Props for `<PrismicText />`. */
|
|
6
4
|
type PrismicTextProps = {
|
|
7
|
-
/** The Prismic rich text field to render. */
|
|
5
|
+
/** The Prismic rich text field to render. */
|
|
6
|
+
field: RichTextField | null | undefined;
|
|
8
7
|
/**
|
|
9
8
|
* The string value to be rendered when the field is empty. If a fallback is not given, `""`
|
|
10
9
|
* (nothing) will be rendered.
|
|
@@ -17,8 +16,8 @@ type PrismicTextProps = {
|
|
|
17
16
|
*/
|
|
18
17
|
separator?: string;
|
|
19
18
|
};
|
|
20
|
-
declare const __VLS_export:
|
|
19
|
+
declare const __VLS_export: import("vue").DefineComponent<PrismicTextProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<PrismicTextProps> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
21
20
|
declare const _default: typeof __VLS_export;
|
|
22
21
|
//#endregion
|
|
23
|
-
export { PrismicTextProps, _default };
|
|
22
|
+
export { PrismicTextProps, _default as default };
|
|
24
23
|
//# sourceMappingURL=PrismicText.vue.d.cts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PrismicText.vue.d.cts","names":[],"sources":["../src/PrismicText.vue"],"mappings":"
|
|
1
|
+
{"version":3,"file":"PrismicText.vue.d.cts","names":[],"sources":["../src/PrismicText.vue"],"mappings":";;;KAyDY;;EAEX,OAAO;;;;;EAMP;;;;;;EAOA;;cAuCK,4BAAY,gBAAA,gDAAA,qCAAA,iDAAA,aAAA,SAAA,oBAAA,oDAAA;cAGG,iBAAO"}
|
|
@@ -1,10 +1,9 @@
|
|
|
1
|
-
import * as _$vue from "vue";
|
|
2
1
|
import { RichTextField } from "@prismicio/client";
|
|
3
|
-
|
|
4
2
|
//#region src/PrismicText.vue.d.ts
|
|
5
3
|
/** Props for `<PrismicText />`. */
|
|
6
4
|
type PrismicTextProps = {
|
|
7
|
-
/** The Prismic rich text field to render. */
|
|
5
|
+
/** The Prismic rich text field to render. */
|
|
6
|
+
field: RichTextField | null | undefined;
|
|
8
7
|
/**
|
|
9
8
|
* The string value to be rendered when the field is empty. If a fallback is not given, `""`
|
|
10
9
|
* (nothing) will be rendered.
|
|
@@ -17,8 +16,8 @@ type PrismicTextProps = {
|
|
|
17
16
|
*/
|
|
18
17
|
separator?: string;
|
|
19
18
|
};
|
|
20
|
-
declare const __VLS_export:
|
|
19
|
+
declare const __VLS_export: import("vue").DefineComponent<PrismicTextProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<PrismicTextProps> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
21
20
|
declare const _default: typeof __VLS_export;
|
|
22
21
|
//#endregion
|
|
23
|
-
export { PrismicTextProps, _default };
|
|
22
|
+
export { PrismicTextProps, _default as default };
|
|
24
23
|
//# sourceMappingURL=PrismicText.vue.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PrismicText.vue.d.ts","names":[],"sources":["../src/PrismicText.vue"],"mappings":"
|
|
1
|
+
{"version":3,"file":"PrismicText.vue.d.ts","names":[],"sources":["../src/PrismicText.vue"],"mappings":";;;KAyDY;;EAEX,OAAO;;;;;EAMP;;;;;;EAOA;;cAuCK,4BAAY,gBAAA,gDAAA,qCAAA,iDAAA,aAAA,SAAA,oBAAA,oDAAA;cAGG,iBAAO"}
|
|
@@ -3,7 +3,7 @@ let vue = require("vue");
|
|
|
3
3
|
let _prismicio_client = require("@prismicio/client");
|
|
4
4
|
let esm_env = require("esm-env");
|
|
5
5
|
//#region src/PrismicText.vue?vue&type=script&setup=true&lang.ts
|
|
6
|
-
var PrismicText_vue_vue_type_script_setup_true_lang_default =
|
|
6
|
+
var PrismicText_vue_vue_type_script_setup_true_lang_default = /*@__PURE__*/ (0, vue.defineComponent)({
|
|
7
7
|
name: "PrismicText",
|
|
8
8
|
__name: "PrismicText",
|
|
9
9
|
props: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PrismicText.vue_vue_type_script_setup_true_lang.cjs","names":[],"sources":["../src/PrismicText.vue"],"sourcesContent":["<script lang=\"ts\" setup>\nimport type { RichTextField } from \"@prismicio/client\"\nimport { asText } from \"@prismicio/client\"\nimport { DEV } from \"esm-env\"\nimport { watchEffect } from \"vue\"\n\nimport { devMsg } from \"./lib/devMsg\"\n\n/** Props for `<PrismicText />`. */\nexport type PrismicTextProps = {\n\t/** The Prismic rich text field to render. */\n\tfield: RichTextField | null | undefined\n\n\t/**\n\t * The string value to be rendered when the field is empty. If a fallback is not given, `\"\"`\n\t * (nothing) will be rendered.\n\t */\n\tfallback?: string\n\n\t/**\n\t * The separator used between blocks.\n\t *\n\t * @defaultValue `\" \"` (a whitespace)\n\t */\n\tseparator?: string\n}\n\nconst props = defineProps<PrismicTextProps>()\ndefineOptions({ name: \"PrismicText\" })\n\nif (DEV) {\n\twatchEffect(() => {\n\t\tif (typeof props.field === \"string\") {\n\t\t\tthrow new Error(\n\t\t\t\t`[PrismicText] The \"field\" prop only accepts a Rich Text or title field's value but was provided a different type of field instead (e.g. a Key Text or Select field). You can resolve this error by rendering the field value inline without <PrismicText>. For more details, see ${devMsg(\n\t\t\t\t\t\"prismictext-works-only-with-rich-text-and-title-fields\",\n\t\t\t\t)}`,\n\t\t\t)\n\t\t}\n\t}, {})\n}\n</script>\n\n<template>\n\t{{ asText(field) || fallback || \"\" }}\n</template>\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;EA2BA,MAAM,QAAQ;
|
|
1
|
+
{"version":3,"file":"PrismicText.vue_vue_type_script_setup_true_lang.cjs","names":[],"sources":["../src/PrismicText.vue"],"sourcesContent":["<script lang=\"ts\" setup>\nimport type { RichTextField } from \"@prismicio/client\"\nimport { asText } from \"@prismicio/client\"\nimport { DEV } from \"esm-env\"\nimport { watchEffect } from \"vue\"\n\nimport { devMsg } from \"./lib/devMsg\"\n\n/** Props for `<PrismicText />`. */\nexport type PrismicTextProps = {\n\t/** The Prismic rich text field to render. */\n\tfield: RichTextField | null | undefined\n\n\t/**\n\t * The string value to be rendered when the field is empty. If a fallback is not given, `\"\"`\n\t * (nothing) will be rendered.\n\t */\n\tfallback?: string\n\n\t/**\n\t * The separator used between blocks.\n\t *\n\t * @defaultValue `\" \"` (a whitespace)\n\t */\n\tseparator?: string\n}\n\nconst props = defineProps<PrismicTextProps>()\ndefineOptions({ name: \"PrismicText\" })\n\nif (DEV) {\n\twatchEffect(() => {\n\t\tif (typeof props.field === \"string\") {\n\t\t\tthrow new Error(\n\t\t\t\t`[PrismicText] The \"field\" prop only accepts a Rich Text or title field's value but was provided a different type of field instead (e.g. a Key Text or Select field). You can resolve this error by rendering the field value inline without <PrismicText>. For more details, see ${devMsg(\n\t\t\t\t\t\"prismictext-works-only-with-rich-text-and-title-fields\",\n\t\t\t\t)}`,\n\t\t\t)\n\t\t}\n\t}, {})\n}\n</script>\n\n<template>\n\t{{ asText(field) || fallback || \"\" }}\n</template>\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;EA2BA,MAAM,QAAQ;EAGd,IAAI,QAAA,KACH,CAAA,GAAA,IAAA,YAAA,OAAkB;GACjB,IAAI,OAAO,MAAM,UAAU,UAC1B,MAAM,IAAI,MACT,oRAAoR,eAAA,OACnR,wDACD,GACD;EAEF,GAAG,CAAC,CAAC;;GAKF,QAAA,GAAA,IAAA,gBAAA,EAAA,GAAA,IAAA,MAAA,CAAA,kBAAA,MAAA,CAAM,CAAC,QAAA,KAAK,KAAK,QAAA,YAAQ,EAAA"}
|
|
@@ -3,7 +3,7 @@ import { defineComponent, toDisplayString, unref, watchEffect } from "vue";
|
|
|
3
3
|
import { asText } from "@prismicio/client";
|
|
4
4
|
import { DEV } from "esm-env";
|
|
5
5
|
//#region src/PrismicText.vue?vue&type=script&setup=true&lang.ts
|
|
6
|
-
var PrismicText_vue_vue_type_script_setup_true_lang_default =
|
|
6
|
+
var PrismicText_vue_vue_type_script_setup_true_lang_default = /*@__PURE__*/ defineComponent({
|
|
7
7
|
name: "PrismicText",
|
|
8
8
|
__name: "PrismicText",
|
|
9
9
|
props: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PrismicText.vue_vue_type_script_setup_true_lang.js","names":[],"sources":["../src/PrismicText.vue"],"sourcesContent":["<script lang=\"ts\" setup>\nimport type { RichTextField } from \"@prismicio/client\"\nimport { asText } from \"@prismicio/client\"\nimport { DEV } from \"esm-env\"\nimport { watchEffect } from \"vue\"\n\nimport { devMsg } from \"./lib/devMsg\"\n\n/** Props for `<PrismicText />`. */\nexport type PrismicTextProps = {\n\t/** The Prismic rich text field to render. */\n\tfield: RichTextField | null | undefined\n\n\t/**\n\t * The string value to be rendered when the field is empty. If a fallback is not given, `\"\"`\n\t * (nothing) will be rendered.\n\t */\n\tfallback?: string\n\n\t/**\n\t * The separator used between blocks.\n\t *\n\t * @defaultValue `\" \"` (a whitespace)\n\t */\n\tseparator?: string\n}\n\nconst props = defineProps<PrismicTextProps>()\ndefineOptions({ name: \"PrismicText\" })\n\nif (DEV) {\n\twatchEffect(() => {\n\t\tif (typeof props.field === \"string\") {\n\t\t\tthrow new Error(\n\t\t\t\t`[PrismicText] The \"field\" prop only accepts a Rich Text or title field's value but was provided a different type of field instead (e.g. a Key Text or Select field). You can resolve this error by rendering the field value inline without <PrismicText>. For more details, see ${devMsg(\n\t\t\t\t\t\"prismictext-works-only-with-rich-text-and-title-fields\",\n\t\t\t\t)}`,\n\t\t\t)\n\t\t}\n\t}, {})\n}\n</script>\n\n<template>\n\t{{ asText(field) || fallback || \"\" }}\n</template>\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;EA2BA,MAAM,QAAQ;
|
|
1
|
+
{"version":3,"file":"PrismicText.vue_vue_type_script_setup_true_lang.js","names":[],"sources":["../src/PrismicText.vue"],"sourcesContent":["<script lang=\"ts\" setup>\nimport type { RichTextField } from \"@prismicio/client\"\nimport { asText } from \"@prismicio/client\"\nimport { DEV } from \"esm-env\"\nimport { watchEffect } from \"vue\"\n\nimport { devMsg } from \"./lib/devMsg\"\n\n/** Props for `<PrismicText />`. */\nexport type PrismicTextProps = {\n\t/** The Prismic rich text field to render. */\n\tfield: RichTextField | null | undefined\n\n\t/**\n\t * The string value to be rendered when the field is empty. If a fallback is not given, `\"\"`\n\t * (nothing) will be rendered.\n\t */\n\tfallback?: string\n\n\t/**\n\t * The separator used between blocks.\n\t *\n\t * @defaultValue `\" \"` (a whitespace)\n\t */\n\tseparator?: string\n}\n\nconst props = defineProps<PrismicTextProps>()\ndefineOptions({ name: \"PrismicText\" })\n\nif (DEV) {\n\twatchEffect(() => {\n\t\tif (typeof props.field === \"string\") {\n\t\t\tthrow new Error(\n\t\t\t\t`[PrismicText] The \"field\" prop only accepts a Rich Text or title field's value but was provided a different type of field instead (e.g. a Key Text or Select field). You can resolve this error by rendering the field value inline without <PrismicText>. For more details, see ${devMsg(\n\t\t\t\t\t\"prismictext-works-only-with-rich-text-and-title-fields\",\n\t\t\t\t)}`,\n\t\t\t)\n\t\t}\n\t}, {})\n}\n</script>\n\n<template>\n\t{{ asText(field) || fallback || \"\" }}\n</template>\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;EA2BA,MAAM,QAAQ;EAGd,IAAI,KACH,kBAAkB;GACjB,IAAI,OAAO,MAAM,UAAU,UAC1B,MAAM,IAAI,MACT,oRAAoR,OACnR,wDACD,GACD;EAEF,GAAG,CAAC,CAAC;;GAKF,OAAA,gBAAA,MAAA,MAAA,CAAM,CAAC,QAAA,KAAK,KAAK,QAAA,YAAQ,EAAA"}
|
|
@@ -1,10 +1,9 @@
|
|
|
1
|
-
import * as _$vue from "vue";
|
|
2
|
-
import * as _$_prismicio_client0 from "@prismicio/client";
|
|
3
|
-
|
|
4
1
|
//#region src/SliceSimulator.vue.d.ts
|
|
5
2
|
/** Props for `<SliceSimulator />`. */
|
|
6
3
|
type SliceSimulatorProps = {
|
|
7
|
-
/** The z-index value of the simulator so that it's displayed above layout elements. */
|
|
4
|
+
/** The z-index value of the simulator so that it's displayed above layout elements. */
|
|
5
|
+
zIndex?: number;
|
|
6
|
+
/** The background color of the simulator to match website design. */
|
|
8
7
|
background?: string;
|
|
9
8
|
};
|
|
10
9
|
declare var __VLS_1: {
|
|
@@ -12,43 +11,43 @@ declare var __VLS_1: {
|
|
|
12
11
|
slice_type: string;
|
|
13
12
|
slice_label: string | null;
|
|
14
13
|
id: string;
|
|
15
|
-
primary: Record<string,
|
|
16
|
-
items: Record<string,
|
|
14
|
+
primary: Record<string, import("@prismicio/client").AnyRegularField>;
|
|
15
|
+
items: Record<string, import("@prismicio/client").AnyRegularField>[];
|
|
17
16
|
} | {
|
|
18
17
|
slice_type: string;
|
|
19
18
|
slice_label: null;
|
|
20
19
|
id: string;
|
|
21
20
|
variation: string;
|
|
22
21
|
version: string;
|
|
23
|
-
primary: Record<string,
|
|
24
|
-
items: Record<string,
|
|
22
|
+
primary: Record<string, import("@prismicio/client").AnySlicePrimaryField>;
|
|
23
|
+
items: Record<string, import("@prismicio/client").AnyRegularField>[];
|
|
25
24
|
}, ...({
|
|
26
25
|
slice_type: string;
|
|
27
26
|
slice_label: string | null;
|
|
28
27
|
id: string;
|
|
29
|
-
primary: Record<string,
|
|
30
|
-
items: Record<string,
|
|
28
|
+
primary: Record<string, import("@prismicio/client").AnyRegularField>;
|
|
29
|
+
items: Record<string, import("@prismicio/client").AnyRegularField>[];
|
|
31
30
|
} | {
|
|
32
31
|
slice_type: string;
|
|
33
32
|
slice_label: null;
|
|
34
33
|
id: string;
|
|
35
34
|
variation: string;
|
|
36
35
|
version: string;
|
|
37
|
-
primary: Record<string,
|
|
38
|
-
items: Record<string,
|
|
36
|
+
primary: Record<string, import("@prismicio/client").AnySlicePrimaryField>;
|
|
37
|
+
items: Record<string, import("@prismicio/client").AnyRegularField>[];
|
|
39
38
|
})[]];
|
|
40
39
|
};
|
|
41
40
|
type __VLS_Slots = {} & {
|
|
42
41
|
default?: (props: typeof __VLS_1) => any;
|
|
43
42
|
};
|
|
44
|
-
declare const __VLS_base:
|
|
43
|
+
declare const __VLS_base: import("vue").DefineComponent<SliceSimulatorProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<SliceSimulatorProps> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
45
44
|
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
46
45
|
declare const _default: typeof __VLS_export;
|
|
47
46
|
type __VLS_WithSlots<T, S> = T & {
|
|
48
47
|
new (): {
|
|
49
48
|
$slots: S;
|
|
50
49
|
};
|
|
51
|
-
};
|
|
50
|
+
};
|
|
52
51
|
//#endregion
|
|
53
|
-
export { SliceSimulatorProps, _default };
|
|
52
|
+
export { SliceSimulatorProps, _default as default };
|
|
54
53
|
//# sourceMappingURL=SliceSimulator.vue.d.cts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SliceSimulator.vue.d.cts","names":[],"sources":["../src/SliceSimulator.vue"],"mappings":"
|
|
1
|
+
{"version":3,"file":"SliceSimulator.vue.d.cts","names":[],"sources":["../src/SliceSimulator.vue"],"mappings":";;KAmGY;;EAEX;;EAEA;;YA0FG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KACC;EACD,WAAW,cAAc;;cAKvB,0BAAU,gBAAA,mDAAA,qCAAA,iDAAA,aAAA,SAAA,uBAAA,oDAAA;cAGV,cAAqB,uBAAuB,YAAY;cACzC,iBAAO;KACvB,gBAAgB,GAAG,KAAK;;IAE3B,QAAQ"}
|
|
@@ -1,10 +1,9 @@
|
|
|
1
|
-
import * as _$vue from "vue";
|
|
2
|
-
import * as _$_prismicio_client0 from "@prismicio/client";
|
|
3
|
-
|
|
4
1
|
//#region src/SliceSimulator.vue.d.ts
|
|
5
2
|
/** Props for `<SliceSimulator />`. */
|
|
6
3
|
type SliceSimulatorProps = {
|
|
7
|
-
/** The z-index value of the simulator so that it's displayed above layout elements. */
|
|
4
|
+
/** The z-index value of the simulator so that it's displayed above layout elements. */
|
|
5
|
+
zIndex?: number;
|
|
6
|
+
/** The background color of the simulator to match website design. */
|
|
8
7
|
background?: string;
|
|
9
8
|
};
|
|
10
9
|
declare var __VLS_1: {
|
|
@@ -12,43 +11,43 @@ declare var __VLS_1: {
|
|
|
12
11
|
slice_type: string;
|
|
13
12
|
slice_label: string | null;
|
|
14
13
|
id: string;
|
|
15
|
-
primary: Record<string,
|
|
16
|
-
items: Record<string,
|
|
14
|
+
primary: Record<string, import("@prismicio/client").AnyRegularField>;
|
|
15
|
+
items: Record<string, import("@prismicio/client").AnyRegularField>[];
|
|
17
16
|
} | {
|
|
18
17
|
slice_type: string;
|
|
19
18
|
slice_label: null;
|
|
20
19
|
id: string;
|
|
21
20
|
variation: string;
|
|
22
21
|
version: string;
|
|
23
|
-
primary: Record<string,
|
|
24
|
-
items: Record<string,
|
|
22
|
+
primary: Record<string, import("@prismicio/client").AnySlicePrimaryField>;
|
|
23
|
+
items: Record<string, import("@prismicio/client").AnyRegularField>[];
|
|
25
24
|
}, ...({
|
|
26
25
|
slice_type: string;
|
|
27
26
|
slice_label: string | null;
|
|
28
27
|
id: string;
|
|
29
|
-
primary: Record<string,
|
|
30
|
-
items: Record<string,
|
|
28
|
+
primary: Record<string, import("@prismicio/client").AnyRegularField>;
|
|
29
|
+
items: Record<string, import("@prismicio/client").AnyRegularField>[];
|
|
31
30
|
} | {
|
|
32
31
|
slice_type: string;
|
|
33
32
|
slice_label: null;
|
|
34
33
|
id: string;
|
|
35
34
|
variation: string;
|
|
36
35
|
version: string;
|
|
37
|
-
primary: Record<string,
|
|
38
|
-
items: Record<string,
|
|
36
|
+
primary: Record<string, import("@prismicio/client").AnySlicePrimaryField>;
|
|
37
|
+
items: Record<string, import("@prismicio/client").AnyRegularField>[];
|
|
39
38
|
})[]];
|
|
40
39
|
};
|
|
41
40
|
type __VLS_Slots = {} & {
|
|
42
41
|
default?: (props: typeof __VLS_1) => any;
|
|
43
42
|
};
|
|
44
|
-
declare const __VLS_base:
|
|
43
|
+
declare const __VLS_base: import("vue").DefineComponent<SliceSimulatorProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<SliceSimulatorProps> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
45
44
|
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
46
45
|
declare const _default: typeof __VLS_export;
|
|
47
46
|
type __VLS_WithSlots<T, S> = T & {
|
|
48
47
|
new (): {
|
|
49
48
|
$slots: S;
|
|
50
49
|
};
|
|
51
|
-
};
|
|
50
|
+
};
|
|
52
51
|
//#endregion
|
|
53
|
-
export { SliceSimulatorProps, _default };
|
|
52
|
+
export { SliceSimulatorProps, _default as default };
|
|
54
53
|
//# sourceMappingURL=SliceSimulator.vue.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SliceSimulator.vue.d.ts","names":[],"sources":["../src/SliceSimulator.vue"],"mappings":"
|
|
1
|
+
{"version":3,"file":"SliceSimulator.vue.d.ts","names":[],"sources":["../src/SliceSimulator.vue"],"mappings":";;KAmGY;;EAEX;;EAEA;;YA0FG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KACC;EACD,WAAW,cAAc;;cAKvB,0BAAU,gBAAA,mDAAA,qCAAA,iDAAA,aAAA,SAAA,uBAAA,oDAAA;cAGV,cAAqB,uBAAuB,YAAY;cACzC,iBAAO;KACvB,gBAAgB,GAAG,KAAK;;IAE3B,QAAQ"}
|
|
@@ -2,7 +2,7 @@ let vue = require("vue");
|
|
|
2
2
|
let _prismicio_simulator_kit = require("@prismicio/simulator/kit");
|
|
3
3
|
//#region src/SliceSimulator.vue?vue&type=script&setup=true&lang.ts
|
|
4
4
|
const _hoisted_1 = ["innerHTML"];
|
|
5
|
-
var SliceSimulator_vue_vue_type_script_setup_true_lang_default =
|
|
5
|
+
var SliceSimulator_vue_vue_type_script_setup_true_lang_default = /*@__PURE__*/ (0, vue.defineComponent)({
|
|
6
6
|
name: "SliceSimulator",
|
|
7
7
|
__name: "SliceSimulator",
|
|
8
8
|
props: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SliceSimulator.vue_vue_type_script_setup_true_lang.cjs","names":[],"sources":["../src/SliceSimulator.vue"],"sourcesContent":["<script lang=\"ts\" setup>\nimport {\n\tgetDefaultProps,\n\tgetDefaultSlices,\n\tgetDefaultMessage,\n\tonClickHandler,\n\tdisableEventHandler,\n\tsimulatorClass,\n\tsimulatorRootClass,\n\tStateEventType,\n\tSimulatorManager,\n} from \"@prismicio/simulator/kit\"\nimport { ref, onMounted, onUnmounted } from \"vue\"\n\n/** Props for `<SliceSimulator />`. */\nexport type SliceSimulatorProps = {\n\t/** The z-index value of the simulator so that it's displayed above layout elements. */\n\tzIndex?: number\n\t/** The background color of the simulator to match website design. */\n\tbackground?: string\n}\n\nconst props = defineProps<SliceSimulatorProps>()\ndefineOptions({ name: \"SliceSimulator\" })\n\nconst slices = ref(getDefaultSlices())\nconst message = ref(getDefaultMessage())\n\nconst simulatorManager = new SimulatorManager()\n\nonMounted(() => {\n\tsimulatorManager.state.on(\n\t\tStateEventType.Slices,\n\t\t(_slices) => {\n\t\t\tslices.value = _slices\n\t\t},\n\t\t\"simulator-slices\",\n\t)\n\tsimulatorManager.state.on(\n\t\tStateEventType.Message,\n\t\t(_message) => {\n\t\t\tmessage.value = _message\n\t\t},\n\t\t\"simulator-message\",\n\t)\n\n\tsimulatorManager.init()\n})\n\nonUnmounted(() => {\n\tsimulatorManager.state.off(StateEventType.Slices, \"simulator-slices\")\n\n\tsimulatorManager.state.off(StateEventType.Message, \"simulator-message\")\n})\n</script>\n\n<template>\n\t<div\n\t\t:class=\"simulatorClass\"\n\t\t:style=\"{\n\t\t\tzIndex: props.zIndex || getDefaultProps().zIndex,\n\t\t\tposition: 'fixed',\n\t\t\ttop: 0,\n\t\t\tleft: 0,\n\t\t\twidth: '100%',\n\t\t\theight: '100vh',\n\t\t\toverflow: 'auto',\n\t\t\tbackground: props.background || getDefaultProps().background,\n\t\t}\"\n\t>\n\t\t<article v-if=\"message\" v-html=\"message\" />\n\t\t<div\n\t\t\tv-else-if=\"slices.length\"\n\t\t\tid=\"root\"\n\t\t\t:class=\"simulatorRootClass\"\n\t\t\t@click.capture=\"onClickHandler\"\n\t\t\t@submit.capture=\"disableEventHandler\"\n\t\t>\n\t\t\t<slot :slices=\"slices\" />\n\t\t</div>\n\t</div>\n</template>\n"],"mappings":";;;;;;;;;;;;;;;;;;EAsBA,MAAM,QAAQ;EAGd,MAAM,UAAA,
|
|
1
|
+
{"version":3,"file":"SliceSimulator.vue_vue_type_script_setup_true_lang.cjs","names":[],"sources":["../src/SliceSimulator.vue"],"sourcesContent":["<script lang=\"ts\" setup>\nimport {\n\tgetDefaultProps,\n\tgetDefaultSlices,\n\tgetDefaultMessage,\n\tonClickHandler,\n\tdisableEventHandler,\n\tsimulatorClass,\n\tsimulatorRootClass,\n\tStateEventType,\n\tSimulatorManager,\n} from \"@prismicio/simulator/kit\"\nimport { ref, onMounted, onUnmounted } from \"vue\"\n\n/** Props for `<SliceSimulator />`. */\nexport type SliceSimulatorProps = {\n\t/** The z-index value of the simulator so that it's displayed above layout elements. */\n\tzIndex?: number\n\t/** The background color of the simulator to match website design. */\n\tbackground?: string\n}\n\nconst props = defineProps<SliceSimulatorProps>()\ndefineOptions({ name: \"SliceSimulator\" })\n\nconst slices = ref(getDefaultSlices())\nconst message = ref(getDefaultMessage())\n\nconst simulatorManager = new SimulatorManager()\n\nonMounted(() => {\n\tsimulatorManager.state.on(\n\t\tStateEventType.Slices,\n\t\t(_slices) => {\n\t\t\tslices.value = _slices\n\t\t},\n\t\t\"simulator-slices\",\n\t)\n\tsimulatorManager.state.on(\n\t\tStateEventType.Message,\n\t\t(_message) => {\n\t\t\tmessage.value = _message\n\t\t},\n\t\t\"simulator-message\",\n\t)\n\n\tsimulatorManager.init()\n})\n\nonUnmounted(() => {\n\tsimulatorManager.state.off(StateEventType.Slices, \"simulator-slices\")\n\n\tsimulatorManager.state.off(StateEventType.Message, \"simulator-message\")\n})\n</script>\n\n<template>\n\t<div\n\t\t:class=\"simulatorClass\"\n\t\t:style=\"{\n\t\t\tzIndex: props.zIndex || getDefaultProps().zIndex,\n\t\t\tposition: 'fixed',\n\t\t\ttop: 0,\n\t\t\tleft: 0,\n\t\t\twidth: '100%',\n\t\t\theight: '100vh',\n\t\t\toverflow: 'auto',\n\t\t\tbackground: props.background || getDefaultProps().background,\n\t\t}\"\n\t>\n\t\t<article v-if=\"message\" v-html=\"message\" />\n\t\t<div\n\t\t\tv-else-if=\"slices.length\"\n\t\t\tid=\"root\"\n\t\t\t:class=\"simulatorRootClass\"\n\t\t\t@click.capture=\"onClickHandler\"\n\t\t\t@submit.capture=\"disableEventHandler\"\n\t\t>\n\t\t\t<slot :slices=\"slices\" />\n\t\t</div>\n\t</div>\n</template>\n"],"mappings":";;;;;;;;;;;;;;;;;;EAsBA,MAAM,QAAQ;EAGd,MAAM,UAAA,GAAS,IAAA,IAAA,EAAA,GAAI,yBAAA,iBAAA,CAAiB,CAAC;EACrC,MAAM,WAAA,GAAU,IAAA,IAAA,EAAA,GAAI,yBAAA,kBAAA,CAAkB,CAAC;EAEvC,MAAM,mBAAmB,IAAI,yBAAA,iBAAiB;EAE9C,CAAA,GAAA,IAAA,UAAA,OAAgB;GACf,iBAAiB,MAAM,GACtB,yBAAA,eAAe,SACd,YAAY;IACZ,OAAO,QAAQ;GAChB,GACA,kBACD;GACA,iBAAiB,MAAM,GACtB,yBAAA,eAAe,UACd,aAAa;IACb,QAAQ,QAAQ;GACjB,GACA,mBACD;GAEA,iBAAiB,KAAK;EACvB,CAAC;EAED,CAAA,GAAA,IAAA,YAAA,OAAkB;GACjB,iBAAiB,MAAM,IAAI,yBAAA,eAAe,QAAQ,kBAAkB;GAEpE,iBAAiB,MAAM,IAAI,yBAAA,eAAe,SAAS,mBAAmB;EACvE,CAAC;;GAIA,QAAA,GAAA,IAAA,UAAA,CAAA,IAAA,GAAA,IAAA,mBAAA,CAuBM,OAAA;IAtBJ,QAAA,GAAK,IAAA,eAAA,EAAA,GAAE,IAAA,MAAA,CAAA,yBAAA,cAAA,CAAc;IACrB,QAAA,GAAK,IAAA,eAAA,CAAA;KAAe,QAAA,MAAM,WAAA,GAAU,IAAA,MAAA,CAAA,yBAAA,eAAA,CAAe,CAAA,CAAA,CAAG;;;;;;;KAA+H,YAAA,MAAM,eAAA,GAAc,IAAA,MAAA,CAAA,yBAAA,eAAA,CAAe,CAAA,CAAA,CAAG;;GAW7M,GAAA,CAAA,QAAA,UAAA,GAAf,IAAA,UAAA,CAAA,IAAA,GAAA,IAAA,mBAAA,CAA2C,WAAA;;IAAnB,WAAQ,QAAA;GAEpB,GAAA,MAAA,GAAA,UAAA,KAAA,OAAA,MAAO,WAAA,GADnB,IAAA,UAAA,CAAA,IAAA,GAAA,IAAA,mBAAA,CAQM,OAAA;;IANL,IAAG;IACF,QAAA,GAAK,IAAA,eAAA,EAAA,GAAE,IAAA,MAAA,CAAA,yBAAA,kBAAA,CAAkB;IACV,gBAAA,OAAA,OAAA,OAAA,MAAA,GAAA,UAAA,GAAA,IAAA,MAAA,CAAA,yBAAA,cAAA,MAAA,GAAA,IAAA,MAAA,CAAA,yBAAA,cAAA,CAAA,CAAA,GAAA,IAAA;IACC,iBAAA,OAAA,OAAA,OAAA,MAAA,GAAA,UAAA,GAAA,IAAA,MAAA,CAAA,yBAAA,mBAAA,MAAA,GAAA,IAAA,MAAA,CAAA,yBAAA,mBAAA,CAAA,CAAA,GAAA,IAAA;GAEjB,GAAA,EAAA,GAAA,IAAA,WAAA,CAAyB,KAAA,QAAA,WAAA,EAAlB,QAAQ,OAAA,MAAM,CAAA,CAAA,GAAA,EAAA,MAAA,GAAA,IAAA,mBAAA,CAAA,QAAA,IAAA,CAAA,GAAA,CAAA"}
|
|
@@ -2,7 +2,7 @@ import { createCommentVNode, createElementBlock, defineComponent, normalizeClass
|
|
|
2
2
|
import { SimulatorManager, StateEventType, disableEventHandler, getDefaultMessage, getDefaultProps, getDefaultSlices, onClickHandler, simulatorClass, simulatorRootClass } from "@prismicio/simulator/kit";
|
|
3
3
|
//#region src/SliceSimulator.vue?vue&type=script&setup=true&lang.ts
|
|
4
4
|
const _hoisted_1 = ["innerHTML"];
|
|
5
|
-
var SliceSimulator_vue_vue_type_script_setup_true_lang_default =
|
|
5
|
+
var SliceSimulator_vue_vue_type_script_setup_true_lang_default = /*@__PURE__*/ defineComponent({
|
|
6
6
|
name: "SliceSimulator",
|
|
7
7
|
__name: "SliceSimulator",
|
|
8
8
|
props: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SliceSimulator.vue_vue_type_script_setup_true_lang.js","names":[],"sources":["../src/SliceSimulator.vue"],"sourcesContent":["<script lang=\"ts\" setup>\nimport {\n\tgetDefaultProps,\n\tgetDefaultSlices,\n\tgetDefaultMessage,\n\tonClickHandler,\n\tdisableEventHandler,\n\tsimulatorClass,\n\tsimulatorRootClass,\n\tStateEventType,\n\tSimulatorManager,\n} from \"@prismicio/simulator/kit\"\nimport { ref, onMounted, onUnmounted } from \"vue\"\n\n/** Props for `<SliceSimulator />`. */\nexport type SliceSimulatorProps = {\n\t/** The z-index value of the simulator so that it's displayed above layout elements. */\n\tzIndex?: number\n\t/** The background color of the simulator to match website design. */\n\tbackground?: string\n}\n\nconst props = defineProps<SliceSimulatorProps>()\ndefineOptions({ name: \"SliceSimulator\" })\n\nconst slices = ref(getDefaultSlices())\nconst message = ref(getDefaultMessage())\n\nconst simulatorManager = new SimulatorManager()\n\nonMounted(() => {\n\tsimulatorManager.state.on(\n\t\tStateEventType.Slices,\n\t\t(_slices) => {\n\t\t\tslices.value = _slices\n\t\t},\n\t\t\"simulator-slices\",\n\t)\n\tsimulatorManager.state.on(\n\t\tStateEventType.Message,\n\t\t(_message) => {\n\t\t\tmessage.value = _message\n\t\t},\n\t\t\"simulator-message\",\n\t)\n\n\tsimulatorManager.init()\n})\n\nonUnmounted(() => {\n\tsimulatorManager.state.off(StateEventType.Slices, \"simulator-slices\")\n\n\tsimulatorManager.state.off(StateEventType.Message, \"simulator-message\")\n})\n</script>\n\n<template>\n\t<div\n\t\t:class=\"simulatorClass\"\n\t\t:style=\"{\n\t\t\tzIndex: props.zIndex || getDefaultProps().zIndex,\n\t\t\tposition: 'fixed',\n\t\t\ttop: 0,\n\t\t\tleft: 0,\n\t\t\twidth: '100%',\n\t\t\theight: '100vh',\n\t\t\toverflow: 'auto',\n\t\t\tbackground: props.background || getDefaultProps().background,\n\t\t}\"\n\t>\n\t\t<article v-if=\"message\" v-html=\"message\" />\n\t\t<div\n\t\t\tv-else-if=\"slices.length\"\n\t\t\tid=\"root\"\n\t\t\t:class=\"simulatorRootClass\"\n\t\t\t@click.capture=\"onClickHandler\"\n\t\t\t@submit.capture=\"disableEventHandler\"\n\t\t>\n\t\t\t<slot :slices=\"slices\" />\n\t\t</div>\n\t</div>\n</template>\n"],"mappings":";;;;;;;;;;;;;;;;;;EAsBA,MAAM,QAAQ;EAGd,MAAM,SAAS,IAAI,
|
|
1
|
+
{"version":3,"file":"SliceSimulator.vue_vue_type_script_setup_true_lang.js","names":[],"sources":["../src/SliceSimulator.vue"],"sourcesContent":["<script lang=\"ts\" setup>\nimport {\n\tgetDefaultProps,\n\tgetDefaultSlices,\n\tgetDefaultMessage,\n\tonClickHandler,\n\tdisableEventHandler,\n\tsimulatorClass,\n\tsimulatorRootClass,\n\tStateEventType,\n\tSimulatorManager,\n} from \"@prismicio/simulator/kit\"\nimport { ref, onMounted, onUnmounted } from \"vue\"\n\n/** Props for `<SliceSimulator />`. */\nexport type SliceSimulatorProps = {\n\t/** The z-index value of the simulator so that it's displayed above layout elements. */\n\tzIndex?: number\n\t/** The background color of the simulator to match website design. */\n\tbackground?: string\n}\n\nconst props = defineProps<SliceSimulatorProps>()\ndefineOptions({ name: \"SliceSimulator\" })\n\nconst slices = ref(getDefaultSlices())\nconst message = ref(getDefaultMessage())\n\nconst simulatorManager = new SimulatorManager()\n\nonMounted(() => {\n\tsimulatorManager.state.on(\n\t\tStateEventType.Slices,\n\t\t(_slices) => {\n\t\t\tslices.value = _slices\n\t\t},\n\t\t\"simulator-slices\",\n\t)\n\tsimulatorManager.state.on(\n\t\tStateEventType.Message,\n\t\t(_message) => {\n\t\t\tmessage.value = _message\n\t\t},\n\t\t\"simulator-message\",\n\t)\n\n\tsimulatorManager.init()\n})\n\nonUnmounted(() => {\n\tsimulatorManager.state.off(StateEventType.Slices, \"simulator-slices\")\n\n\tsimulatorManager.state.off(StateEventType.Message, \"simulator-message\")\n})\n</script>\n\n<template>\n\t<div\n\t\t:class=\"simulatorClass\"\n\t\t:style=\"{\n\t\t\tzIndex: props.zIndex || getDefaultProps().zIndex,\n\t\t\tposition: 'fixed',\n\t\t\ttop: 0,\n\t\t\tleft: 0,\n\t\t\twidth: '100%',\n\t\t\theight: '100vh',\n\t\t\toverflow: 'auto',\n\t\t\tbackground: props.background || getDefaultProps().background,\n\t\t}\"\n\t>\n\t\t<article v-if=\"message\" v-html=\"message\" />\n\t\t<div\n\t\t\tv-else-if=\"slices.length\"\n\t\t\tid=\"root\"\n\t\t\t:class=\"simulatorRootClass\"\n\t\t\t@click.capture=\"onClickHandler\"\n\t\t\t@submit.capture=\"disableEventHandler\"\n\t\t>\n\t\t\t<slot :slices=\"slices\" />\n\t\t</div>\n\t</div>\n</template>\n"],"mappings":";;;;;;;;;;;;;;;;;;EAsBA,MAAM,QAAQ;EAGd,MAAM,SAAS,IAAI,iBAAiB,CAAC;EACrC,MAAM,UAAU,IAAI,kBAAkB,CAAC;EAEvC,MAAM,mBAAmB,IAAI,iBAAiB;EAE9C,gBAAgB;GACf,iBAAiB,MAAM,GACtB,eAAe,SACd,YAAY;IACZ,OAAO,QAAQ;GAChB,GACA,kBACD;GACA,iBAAiB,MAAM,GACtB,eAAe,UACd,aAAa;IACb,QAAQ,QAAQ;GACjB,GACA,mBACD;GAEA,iBAAiB,KAAK;EACvB,CAAC;EAED,kBAAkB;GACjB,iBAAiB,MAAM,IAAI,eAAe,QAAQ,kBAAkB;GAEpE,iBAAiB,MAAM,IAAI,eAAe,SAAS,mBAAmB;EACvE,CAAC;;GAIA,OAAA,UAAA,GAAA,mBAuBM,OAAA;IAtBJ,OAAK,eAAE,MAAA,cAAA,CAAc;IACrB,OAAK,eAAA;KAAe,QAAA,MAAM,UAAU,MAAA,eAAA,CAAe,CAAA,CAAA,CAAG;;;;;;;KAA+H,YAAA,MAAM,cAAc,MAAA,eAAA,CAAe,CAAA,CAAA,CAAG;;GAW7M,GAAA,CAAA,QAAA,SAAf,UAAA,GAAA,mBAA2C,WAAA;;IAAnB,WAAQ,QAAA;GAEpB,GAAA,MAAA,GAAA,UAAA,KAAA,OAAA,MAAO,UADnB,UAAA,GAAA,mBAQM,OAAA;;IANL,IAAG;IACF,OAAK,eAAE,MAAA,kBAAA,CAAkB;IACV,gBAAA,OAAA,OAAA,OAAA,MAAA,GAAA,SAAA,MAAA,cAAA,KAAA,MAAA,cAAA,CAAA,CAAA,GAAA,IAAA;IACC,iBAAA,OAAA,OAAA,OAAA,MAAA,GAAA,SAAA,MAAA,mBAAA,KAAA,MAAA,mBAAA,CAAA,CAAA,GAAA,IAAA;GAEjB,GAAA,CAAA,WAAyB,KAAA,QAAA,WAAA,EAAlB,QAAQ,OAAA,MAAM,CAAA,CAAA,GAAA,EAAA,KAAA,mBAAA,QAAA,IAAA,CAAA,GAAA,CAAA"}
|