diff --git a/superset-frontend/temporary_superset_ui/superset-ui/plugins/legacy-plugin-chart-world-map/package.json b/superset-frontend/temporary_superset_ui/superset-ui/plugins/legacy-plugin-chart-world-map/package.json
index 445aaba2d1738..b5e18f3280759 100644
--- a/superset-frontend/temporary_superset_ui/superset-ui/plugins/legacy-plugin-chart-world-map/package.json
+++ b/superset-frontend/temporary_superset_ui/superset-ui/plugins/legacy-plugin-chart-world-map/package.json
@@ -36,6 +36,8 @@
"@superset-ui/chart": "^0.14.0",
"@superset-ui/chart-controls": "^0.14.0",
"@superset-ui/number-format": "^0.14.0",
- "@superset-ui/translation": "^0.14.0"
+ "@superset-ui/translation": "^0.14.0",
+ "@superset-ui/style": "^0.14.3",
+ "react": "^16.13.1"
}
}
diff --git a/superset-frontend/temporary_superset_ui/superset-ui/plugins/legacy-plugin-chart-world-map/src/ReactWorldMap.js b/superset-frontend/temporary_superset_ui/superset-ui/plugins/legacy-plugin-chart-world-map/src/ReactWorldMap.jsx
similarity index 61%
rename from superset-frontend/temporary_superset_ui/superset-ui/plugins/legacy-plugin-chart-world-map/src/ReactWorldMap.js
rename to superset-frontend/temporary_superset_ui/superset-ui/plugins/legacy-plugin-chart-world-map/src/ReactWorldMap.jsx
index 72bf90bac5e36..46f0ff9fef7c4 100644
--- a/superset-frontend/temporary_superset_ui/superset-ui/plugins/legacy-plugin-chart-world-map/src/ReactWorldMap.js
+++ b/superset-frontend/temporary_superset_ui/superset-ui/plugins/legacy-plugin-chart-world-map/src/ReactWorldMap.jsx
@@ -16,7 +16,31 @@
* specific language governing permissions and limitations
* under the License.
*/
+import React from 'react';
+import PropTypes from 'prop-types';
+import styled from '@superset-ui/style';
import { reactify } from '@superset-ui/chart';
import WorldMap from './WorldMap';
-export default reactify(WorldMap);
+const ReactWorldMap = reactify(WorldMap);
+
+const WorldMapComponent = ({ className, ...otherProps }) => {
+ return (
+
+
+
+ );
+};
+
+WorldMapComponent.propTypes = {
+ className: PropTypes.string.isRequired,
+};
+
+export default styled(WorldMapComponent)`
+ .superset-legacy-chart-world-map {
+ position: relative;
+ svg {
+ background-color: #feffff;
+ }
+ }
+`;
diff --git a/superset-frontend/temporary_superset_ui/superset-ui/plugins/legacy-plugin-chart-world-map/src/WorldMap.css b/superset-frontend/temporary_superset_ui/superset-ui/plugins/legacy-plugin-chart-world-map/src/WorldMap.css
deleted file mode 100644
index 42801ac90df3b..0000000000000
--- a/superset-frontend/temporary_superset_ui/superset-ui/plugins/legacy-plugin-chart-world-map/src/WorldMap.css
+++ /dev/null
@@ -1,26 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-.superset-legacy-chart-world-map {
- position: relative;
-}
-
-.superset-legacy-chart-world-map svg {
- background-color: #feffff;
-}
diff --git a/superset-frontend/temporary_superset_ui/superset-ui/plugins/legacy-plugin-chart-world-map/src/WorldMap.js b/superset-frontend/temporary_superset_ui/superset-ui/plugins/legacy-plugin-chart-world-map/src/WorldMap.js
index 649d60e03a417..97433892fa53d 100644
--- a/superset-frontend/temporary_superset_ui/superset-ui/plugins/legacy-plugin-chart-world-map/src/WorldMap.js
+++ b/superset-frontend/temporary_superset_ui/superset-ui/plugins/legacy-plugin-chart-world-map/src/WorldMap.js
@@ -21,7 +21,6 @@ import d3 from 'd3';
import PropTypes from 'prop-types';
import Datamap from 'datamaps/dist/datamaps.world.min';
import { getNumberFormatter } from '@superset-ui/number-format';
-import './WorldMap.css';
const propTypes = {
data: PropTypes.arrayOf(
diff --git a/superset-frontend/temporary_superset_ui/superset-ui/plugins/legacy-plugin-chart-world-map/src/index.js b/superset-frontend/temporary_superset_ui/superset-ui/plugins/legacy-plugin-chart-world-map/src/index.js
index cb1ffdf10d610..bda51f8f946b5 100644
--- a/superset-frontend/temporary_superset_ui/superset-ui/plugins/legacy-plugin-chart-world-map/src/index.js
+++ b/superset-frontend/temporary_superset_ui/superset-ui/plugins/legacy-plugin-chart-world-map/src/index.js
@@ -33,7 +33,7 @@ const metadata = new ChartMetadata({
export default class WorldMapChartPlugin extends ChartPlugin {
constructor() {
super({
- loadChart: () => import('./ReactWorldMap.js'),
+ loadChart: () => import('./ReactWorldMap'),
metadata,
transformProps,
controlPanel,