diff --git a/packages/core/client/src/collection-manager/CollectionProvider.tsx b/packages/core/client/src/collection-manager/CollectionProvider.tsx
index 8b9e8271e..2150ce225 100644
--- a/packages/core/client/src/collection-manager/CollectionProvider.tsx
+++ b/packages/core/client/src/collection-manager/CollectionProvider.tsx
@@ -3,11 +3,11 @@ import { CollectionContext } from './context';
import { useCollectionManager } from './hooks';
import { CollectionOptions } from './types';
-export const CollectionProvider: React.FC<{ name?: string; collection?: CollectionOptions }> = (props) => {
- const { name, collection, children } = props;
+export const CollectionProvider: React.FC<{ allowNull?: boolean; name?: string; collection?: CollectionOptions }> = (props) => {
+ const { allowNull, name, collection, children } = props;
const { getCollection } = useCollectionManager();
const value = getCollection(collection || name);
- if (!value) {
+ if (!value && !allowNull) {
return null;
}
return {children};
diff --git a/packages/core/client/src/schema-component/antd/record-picker/InputRecordPicker.tsx b/packages/core/client/src/schema-component/antd/record-picker/InputRecordPicker.tsx
index 4f01cf241..53d6b4072 100644
--- a/packages/core/client/src/schema-component/antd/record-picker/InputRecordPicker.tsx
+++ b/packages/core/client/src/schema-component/antd/record-picker/InputRecordPicker.tsx
@@ -97,7 +97,7 @@ export const InputRecordPicker: React.FC = (props) => {
open={false}
/>
-
+