2282 Rename components to use the new naming convention part 3 (#2296)
part 3 of the renaming
This commit is contained in:
@ -0,0 +1,24 @@
|
||||
import { ReactNode } from 'react';
|
||||
|
||||
import { ObjectMetadataItemScopeInternalContext } from './scope-internal-context/ObjectMetadataItemScopeInternalContext';
|
||||
|
||||
type ObjectMetadataItemScopeProps = {
|
||||
children: ReactNode;
|
||||
objectMetadataItemNamePlural: string;
|
||||
};
|
||||
|
||||
export const ObjectMetadataItemScope = ({
|
||||
children,
|
||||
objectMetadataItemNamePlural,
|
||||
}: ObjectMetadataItemScopeProps) => {
|
||||
return (
|
||||
<ObjectMetadataItemScopeInternalContext.Provider
|
||||
value={{
|
||||
scopeId: objectMetadataItemNamePlural,
|
||||
objectNamePlural: objectMetadataItemNamePlural,
|
||||
}}
|
||||
>
|
||||
{children}
|
||||
</ObjectMetadataItemScopeInternalContext.Provider>
|
||||
);
|
||||
};
|
||||
Reference in New Issue
Block a user