@contentful/field-editor-reference 2.20.11 → 3.0.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/CHANGELOG.md +74 -399
- package/dist/__fixtures__/FakeSdk.d.ts +51 -36
- package/dist/assets/WrappedAssetCard/AssetCardActions.d.ts +2 -2
- package/dist/assets/WrappedAssetCard/FetchingWrappedAssetCard.d.ts +3 -3
- package/dist/assets/WrappedAssetCard/WrappedAssetCard.d.ts +3 -3
- package/dist/assets/WrappedAssetCard/WrappedAssetLink.d.ts +3 -3
- package/dist/common/MultipleReferenceEditor.d.ts +3 -3
- package/dist/common/SingleReferenceEditor.d.ts +3 -3
- package/dist/common/customCardTypes.d.ts +2 -2
- package/dist/common/useAccessApi.d.ts +1 -0
- package/dist/common/useContentTypePermissions.d.ts +2 -2
- package/dist/common/useEditorPermissions.d.ts +2 -2
- package/dist/components/CreateEntryLinkButton/CreateEntryLinkButton.d.ts +2 -3
- package/dist/components/CreateEntryLinkButton/CreateEntryMenuTrigger.d.ts +2 -3
- package/dist/components/LinkActions/LinkActions.d.ts +2 -2
- package/dist/components/LinkActions/LinkEntityActions.d.ts +2 -2
- package/dist/components/LinkActions/helpers.d.ts +11 -8
- package/dist/components/MissingEntityCard/MissingEntityCard.d.ts +2 -2
- package/dist/components/ScheduledIconWithTooltip/ScheduleTooltip.d.ts +2 -2
- package/dist/components/index.d.ts +1 -1
- package/dist/entries/WrappedEntryCard/FetchingWrappedEntryCard.d.ts +3 -3
- package/dist/entries/WrappedEntryCard/WrappedEntryCard.d.ts +3 -3
- package/dist/field-editor-reference.cjs.development.js +268 -363
- package/dist/field-editor-reference.cjs.development.js.map +1 -1
- package/dist/field-editor-reference.cjs.production.min.js +1 -1
- package/dist/field-editor-reference.cjs.production.min.js.map +1 -1
- package/dist/field-editor-reference.esm.js +256 -351
- package/dist/field-editor-reference.esm.js.map +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/types.d.ts +13 -8
- package/package.json +9 -9
package/dist/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { CreateEntryMenuTrigger, CreateEntryLinkButton,
|
|
1
|
+
export { CreateEntryMenuTrigger, CreateEntryLinkButton, getScheduleTooltipContent, ScheduledIconWithTooltip, AssetThumbnail, MissingEntityCard, CombinedLinkActions, } from './components';
|
|
2
2
|
export { SingleEntryReferenceEditor, MultipleEntryReferenceEditor, WrappedEntryCard, } from './entries';
|
|
3
3
|
export { SingleMediaEditor, MultipleMediaEditor, WrappedAssetCard } from './assets';
|
|
4
4
|
export { EntityProvider, useEntities } from './common/EntityStore';
|
package/dist/types.d.ts
CHANGED
|
@@ -1,12 +1,13 @@
|
|
|
1
|
-
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { NavigatorSlideInfo, ContentEntityType } from '@contentful/app-sdk';
|
|
2
3
|
import { Entry, Asset } from '@contentful/field-editor-shared';
|
|
3
|
-
export { BaseExtensionSDK, FieldExtensionSDK, ContentType, ContentTypeField, Link,
|
|
4
|
+
export { BaseExtensionSDK, FieldExtensionSDK, ContentType, ContentTypeField, Link, ContentEntityType, NavigatorSlideInfo, ScheduledAction, } from '@contentful/app-sdk';
|
|
4
5
|
export { Entry, File, Asset } from '@contentful/field-editor-shared';
|
|
5
6
|
export declare type ReferenceValue = {
|
|
6
7
|
sys: {
|
|
7
8
|
type: 'Link';
|
|
8
9
|
id: string;
|
|
9
|
-
linkType:
|
|
10
|
+
linkType: ContentEntityType;
|
|
10
11
|
};
|
|
11
12
|
};
|
|
12
13
|
export declare type EntryReferenceValue = {
|
|
@@ -26,29 +27,29 @@ export declare type AssetReferenceValue = {
|
|
|
26
27
|
export declare type ViewType = 'card' | 'link';
|
|
27
28
|
export declare type Action = {
|
|
28
29
|
type: 'create_and_link';
|
|
29
|
-
entity:
|
|
30
|
+
entity: ContentEntityType;
|
|
30
31
|
entityData: Entry | Asset;
|
|
31
32
|
slide?: NavigatorSlideInfo;
|
|
32
33
|
index?: number;
|
|
33
34
|
} | {
|
|
34
35
|
type: 'select_and_link';
|
|
35
|
-
entity:
|
|
36
|
+
entity: ContentEntityType;
|
|
36
37
|
entityData: Entry | Asset;
|
|
37
38
|
index?: number;
|
|
38
39
|
} | {
|
|
39
40
|
type: 'edit';
|
|
40
41
|
contentTypeId: string;
|
|
41
42
|
id: string;
|
|
42
|
-
entity:
|
|
43
|
+
entity: ContentEntityType;
|
|
43
44
|
slide?: NavigatorSlideInfo;
|
|
44
45
|
} | {
|
|
45
46
|
type: 'delete';
|
|
46
47
|
contentTypeId: string;
|
|
47
48
|
id: string;
|
|
48
|
-
entity:
|
|
49
|
+
entity: ContentEntityType;
|
|
49
50
|
} | {
|
|
50
51
|
type: 'rendered';
|
|
51
|
-
entity:
|
|
52
|
+
entity: ContentEntityType;
|
|
52
53
|
};
|
|
53
54
|
export declare type ActionLabels = {
|
|
54
55
|
createNew: (props?: {
|
|
@@ -58,3 +59,7 @@ export declare type ActionLabels = {
|
|
|
58
59
|
canLinkMultiple?: boolean;
|
|
59
60
|
}) => string;
|
|
60
61
|
};
|
|
62
|
+
export declare type RenderDragFn = (props: {
|
|
63
|
+
drag: React.ReactElement;
|
|
64
|
+
isDragging?: boolean;
|
|
65
|
+
}) => React.ReactElement;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@contentful/field-editor-reference",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "3.0.0",
|
|
4
4
|
"main": "dist/index.js",
|
|
5
5
|
"module": "dist/field-editor-reference.esm.js",
|
|
6
6
|
"typings": "dist/index.d.ts",
|
|
@@ -21,9 +21,10 @@
|
|
|
21
21
|
"tsc": "tsc -p ./ --noEmit"
|
|
22
22
|
},
|
|
23
23
|
"dependencies": {
|
|
24
|
-
"@contentful/
|
|
25
|
-
"@contentful/
|
|
26
|
-
"@contentful/
|
|
24
|
+
"@contentful/f36-components": "beta",
|
|
25
|
+
"@contentful/f36-icons": "beta",
|
|
26
|
+
"@contentful/f36-tokens": "beta",
|
|
27
|
+
"@contentful/field-editor-shared": "^0.26.0",
|
|
27
28
|
"@contentful/mimetype": "^1.4.0",
|
|
28
29
|
"@types/deep-equal": "^1.0.1",
|
|
29
30
|
"array-move": "^3.0.0",
|
|
@@ -36,13 +37,12 @@
|
|
|
36
37
|
"react-sortable-hoc": "^2.0.0"
|
|
37
38
|
},
|
|
38
39
|
"devDependencies": {
|
|
39
|
-
"@contentful/app-sdk": "^
|
|
40
|
-
"@contentful/field-editor-test-utils": "^0.
|
|
40
|
+
"@contentful/app-sdk": "^4.2.0",
|
|
41
|
+
"@contentful/field-editor-test-utils": "^0.19.0",
|
|
41
42
|
"@testing-library/react-hooks": "^5.0.3"
|
|
42
43
|
},
|
|
43
44
|
"peerDependencies": {
|
|
44
|
-
"@contentful/app-sdk": "^
|
|
45
|
-
"@contentful/field-editor-test-utils": "^0.12.0",
|
|
45
|
+
"@contentful/app-sdk": "^4.2.0",
|
|
46
46
|
"react": ">=16.8.0"
|
|
47
47
|
},
|
|
48
48
|
"jest": {
|
|
@@ -55,5 +55,5 @@
|
|
|
55
55
|
}
|
|
56
56
|
}
|
|
57
57
|
},
|
|
58
|
-
"gitHead": "
|
|
58
|
+
"gitHead": "f86ba28db3f34cffc0dc2580bf21297542f331c9"
|
|
59
59
|
}
|