@prismicio/editor-fields 0.3.0 → 0.4.0
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/DocumentEditor.d.ts +8 -8
- package/dist/EditorConfig.d.ts +10 -0
- package/dist/SectionEditor.d.ts +2 -0
- package/dist/Selection.d.ts +5 -0
- package/dist/fields/ColorField/ColorField.d.ts +10 -0
- package/dist/fields/ColorField/index.d.ts +1 -0
- package/dist/fields/DateField.d.ts +4 -4
- package/dist/fields/EmbedField/EmbedField.d.ts +11 -0
- package/dist/fields/EmbedField/index.d.ts +1 -0
- package/dist/fields/TimestampField.d.ts +11 -0
- package/dist/index.d.ts +2 -1
- package/dist/index.es.js +24996 -24102
- package/dist/index.umd.js +41 -41
- package/dist/slices/SharedSliceEditor.d.ts +4 -0
- package/dist/zones/SliceZoneEditor.d.ts +1 -0
- package/package.json +5 -5
- package/dist/DocumentEditorConfig.d.ts +0 -8
package/dist/DocumentEditor.d.ts
CHANGED
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
import type { Document } from "@prismicio/types-internal/lib/content";
|
|
2
|
-
import
|
|
2
|
+
import type { StaticCustomType } from "@prismicio/types-internal/lib/customtypes";
|
|
3
3
|
import { type FC } from "react";
|
|
4
|
-
import {
|
|
5
|
-
|
|
4
|
+
import { EditorConfig } from "./EditorConfig";
|
|
5
|
+
import type { Selection } from "./Selection";
|
|
6
6
|
declare type DocumentEditorProps = Readonly<{
|
|
7
|
+
config: EditorConfig;
|
|
8
|
+
readOnly?: boolean;
|
|
9
|
+
customType: StaticCustomType;
|
|
10
|
+
sectionName: string;
|
|
11
|
+
selection?: Selection;
|
|
7
12
|
content: Document;
|
|
8
|
-
customType: CustomType;
|
|
9
13
|
onContentChange: (content: Document) => void;
|
|
10
|
-
readOnly?: boolean;
|
|
11
|
-
sectionName: string | undefined;
|
|
12
|
-
sharedSlices: SharedSlices;
|
|
13
|
-
config?: DocumentEditorConfig;
|
|
14
14
|
}>;
|
|
15
15
|
export declare const DocumentEditor: FC<DocumentEditorProps>;
|
|
16
16
|
export {};
|
package/dist/SectionEditor.d.ts
CHANGED
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
import { type Document } from "@prismicio/types-internal/lib/content";
|
|
2
2
|
import type { StaticSection } from "@prismicio/types-internal/lib/customtypes";
|
|
3
3
|
import { type FC } from "react";
|
|
4
|
+
import type { Selection } from "./Selection";
|
|
4
5
|
declare type SectionEditorProps = Readonly<{
|
|
5
6
|
id: string;
|
|
6
7
|
readOnly: boolean;
|
|
8
|
+
selection?: Selection;
|
|
7
9
|
section: StaticSection;
|
|
8
10
|
content: Document;
|
|
9
11
|
onContentChange: (content: Document) => void;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import type { ColorContent } from "@prismicio/types-internal/lib/content";
|
|
2
|
+
import type { Color as ColorT } from "@prismicio/types-internal/lib/customtypes";
|
|
3
|
+
declare type Props = Readonly<{
|
|
4
|
+
id: string;
|
|
5
|
+
field: ColorT;
|
|
6
|
+
content?: ColorContent;
|
|
7
|
+
onContentChange: (content?: ColorContent) => void;
|
|
8
|
+
}>;
|
|
9
|
+
export declare const ColorField: ({ id, field, content, onContentChange }: Props) => JSX.Element;
|
|
10
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { ColorField } from "./ColorField";
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import type { DateContent } from "@prismicio/types-internal/lib/content";
|
|
2
2
|
import type { Date as DateT } from "@prismicio/types-internal/lib/customtypes";
|
|
3
3
|
declare type Props = Readonly<{
|
|
4
|
-
content?: DateContent;
|
|
5
|
-
field: DateT;
|
|
6
4
|
id: string;
|
|
7
|
-
onContentChange: (content?: DateContent) => void;
|
|
8
5
|
readOnly: boolean;
|
|
6
|
+
field: DateT;
|
|
7
|
+
content?: DateContent;
|
|
8
|
+
onContentChange: (content?: DateContent) => void;
|
|
9
9
|
}>;
|
|
10
|
-
export declare const DateField: ({
|
|
10
|
+
export declare const DateField: ({ id, readOnly, field, content, onContentChange }: Props) => JSX.Element;
|
|
11
11
|
export {};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { EmbedContent } from "@prismicio/types-internal/lib/content";
|
|
2
|
+
import type { Embed as EmbedT } from "@prismicio/types-internal/lib/customtypes";
|
|
3
|
+
declare type Props = Readonly<{
|
|
4
|
+
id: string;
|
|
5
|
+
readOnly: boolean;
|
|
6
|
+
field: EmbedT;
|
|
7
|
+
content?: EmbedContent;
|
|
8
|
+
onContentChange: (content?: EmbedContent) => void;
|
|
9
|
+
}>;
|
|
10
|
+
export declare const EmbedField: ({ id, readOnly, field, content, onContentChange }: Props) => JSX.Element;
|
|
11
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { EmbedField } from "./EmbedField";
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { TimestampContent } from "@prismicio/types-internal/lib/content";
|
|
2
|
+
import type { Timestamp } from "@prismicio/types-internal/lib/customtypes";
|
|
3
|
+
declare type Props = Readonly<{
|
|
4
|
+
id: string;
|
|
5
|
+
readOnly: boolean;
|
|
6
|
+
field: Timestamp;
|
|
7
|
+
content?: TimestampContent;
|
|
8
|
+
onContentChange: (content?: TimestampContent) => void;
|
|
9
|
+
}>;
|
|
10
|
+
export declare const TimestampField: ({ id, readOnly, field, content, onContentChange }: Props) => JSX.Element;
|
|
11
|
+
export {};
|
package/dist/index.d.ts
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
1
|
export { DocumentEditor } from "./DocumentEditor";
|
|
2
|
-
export type {
|
|
2
|
+
export type { EditorConfig } from "./EditorConfig";
|
|
3
|
+
export type { Selection } from "./Selection";
|
|
3
4
|
export { SharedSliceEditor } from "./slices/SharedSliceEditor";
|