@firecms/core 3.0.0-canary.49 → 3.0.0-canary.50
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/index.es.js +8 -6
- package/dist/index.es.js.map +1 -1
- package/dist/index.umd.js +2 -2
- package/dist/index.umd.js.map +1 -1
- package/dist/util/resolutions.d.ts +0 -1
- package/package.json +4 -4
- package/src/components/EntityCollectionView/EntityCollectionView.tsx +5 -3
- package/src/form/components/StorageUploadProgress.tsx +1 -1
- package/src/util/resolutions.ts +2 -3
|
@@ -12,7 +12,6 @@ export declare const resolveCollection: <M extends Record<string, any>>({ collec
|
|
|
12
12
|
* Resolve property builders, enums and arrays.
|
|
13
13
|
* @param propertyOrBuilder
|
|
14
14
|
* @param propertyValue
|
|
15
|
-
* @param values
|
|
16
15
|
*/
|
|
17
16
|
export declare function resolveProperty<T extends CMSType = CMSType, M extends Record<string, any> = any>({ propertyOrBuilder, fromBuilder, ...props }: {
|
|
18
17
|
propertyKey?: string;
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@firecms/core",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "3.0.0-canary.
|
|
4
|
+
"version": "3.0.0-canary.50",
|
|
5
5
|
"description": "Awesome Firebase/Firestore-based headless open-source CMS",
|
|
6
6
|
"funding": {
|
|
7
7
|
"url": "https://github.com/sponsors/firecmsco"
|
|
@@ -46,8 +46,8 @@
|
|
|
46
46
|
"./package.json": "./package.json"
|
|
47
47
|
},
|
|
48
48
|
"dependencies": {
|
|
49
|
-
"@firecms/formex": "^3.0.0-canary.
|
|
50
|
-
"@firecms/ui": "^3.0.0-canary.
|
|
49
|
+
"@firecms/formex": "^3.0.0-canary.50",
|
|
50
|
+
"@firecms/ui": "^3.0.0-canary.50",
|
|
51
51
|
"@fontsource/jetbrains-mono": "^5.0.20",
|
|
52
52
|
"@hello-pangea/dnd": "^16.6.0",
|
|
53
53
|
"@radix-ui/react-portal": "^1.0.4",
|
|
@@ -111,7 +111,7 @@
|
|
|
111
111
|
"dist",
|
|
112
112
|
"src"
|
|
113
113
|
],
|
|
114
|
-
"gitHead": "
|
|
114
|
+
"gitHead": "e5d125d95a0c858bbcc9a57acc1adb3b61c64f23",
|
|
115
115
|
"publishConfig": {
|
|
116
116
|
"access": "public"
|
|
117
117
|
},
|
|
@@ -799,7 +799,7 @@ function EntityIdHeaderWidget({
|
|
|
799
799
|
if (!searchString) return;
|
|
800
800
|
setOpenPopup(false);
|
|
801
801
|
return sideEntityController.open({
|
|
802
|
-
entityId: searchString,
|
|
802
|
+
entityId: searchString.trim(),
|
|
803
803
|
path,
|
|
804
804
|
collection,
|
|
805
805
|
updateUrl: true,
|
|
@@ -812,11 +812,13 @@ function EntityIdHeaderWidget({
|
|
|
812
812
|
autoFocus={openPopup}
|
|
813
813
|
placeholder={"Find entity by ID"}
|
|
814
814
|
// size={"small"}
|
|
815
|
-
onChange={(e) =>
|
|
815
|
+
onChange={(e) => {
|
|
816
|
+
setSearchString(e.target.value);
|
|
817
|
+
}}
|
|
816
818
|
value={searchString}
|
|
817
819
|
className={"flex-grow bg-transparent outline-none p-1"}/>
|
|
818
820
|
<Button variant={"outlined"}
|
|
819
|
-
disabled={!searchString}
|
|
821
|
+
disabled={!(searchString.trim())}
|
|
820
822
|
type={"submit"}
|
|
821
823
|
>Go</Button>
|
|
822
824
|
</div>
|
|
@@ -49,7 +49,7 @@ export function StorageUploadProgress({
|
|
|
49
49
|
metadata
|
|
50
50
|
})
|
|
51
51
|
.then(async ({ path }) => {
|
|
52
|
-
console.debug("Upload successful");
|
|
52
|
+
console.debug("Upload successful", path);
|
|
53
53
|
await onFileUploadComplete(path, entry, metadata);
|
|
54
54
|
if (mounted.current)
|
|
55
55
|
setLoading(false);
|
package/src/util/resolutions.ts
CHANGED
|
@@ -93,7 +93,6 @@ export const resolveCollection = <M extends Record<string, any>, >
|
|
|
93
93
|
* Resolve property builders, enums and arrays.
|
|
94
94
|
* @param propertyOrBuilder
|
|
95
95
|
* @param propertyValue
|
|
96
|
-
* @param values
|
|
97
96
|
*/
|
|
98
97
|
export function resolveProperty<T extends CMSType = CMSType, M extends Record<string, any> = any>({
|
|
99
98
|
propertyOrBuilder,
|
|
@@ -177,11 +176,11 @@ export function resolveProperty<T extends CMSType = CMSType, M extends Record<st
|
|
|
177
176
|
if (resolvedProperty.propertyConfig && !isDefaultFieldConfigId(resolvedProperty.propertyConfig)) {
|
|
178
177
|
const cmsFields = props.fields;
|
|
179
178
|
if (!cmsFields) {
|
|
180
|
-
throw Error(`Trying to resolve a property with key ${resolvedProperty.propertyConfig} that inherits from a custom property config but no custom property configs were provided. Use the property
|
|
179
|
+
throw Error(`Trying to resolve a property with key '${resolvedProperty.propertyConfig}' that inherits from a custom property config but no custom property configs were provided. Use the property 'propertyConfigs' in your app config to provide them`);
|
|
181
180
|
}
|
|
182
181
|
const customField: PropertyConfig<any> = cmsFields[resolvedProperty.propertyConfig];
|
|
183
182
|
if (!customField) {
|
|
184
|
-
console.warn(`Trying to resolve a property with key ${resolvedProperty.propertyConfig} that inherits from a custom property config but no custom property config with that key was found. Check the
|
|
183
|
+
console.warn(`Trying to resolve a property with key '${resolvedProperty.propertyConfig}' that inherits from a custom property config but no custom property config with that key was found. Check the 'propertyConfigs' in your app config`)
|
|
185
184
|
console.warn("Available property configs", cmsFields);
|
|
186
185
|
return null;
|
|
187
186
|
}
|