= withSkeletonComponent(
+ (props) => {
+ const { t } = useMapTranslation();
+ const { mapType } = props;
- const Component = useMemo(() => {
- return MapBlocks[mapType];
- }, [mapType]);
+ const Component = useMemo(() => {
+ return MapBlocks[mapType];
+ }, [mapType]);
- if (!Component) {
- return {t(`The ${mapType} cannot found`)}
;
- }
+ if (!Component) {
+ return {t(`The ${mapType} cannot found`)}
;
+ }
- return (
-
-
-
- );
-};
+ return (
+
+
+
+ );
+ },
+ {
+ displayName: 'MapBlockComponent',
+ },
+);