import ChinaMapChart from "./ChinaMapChart/index";
import PieChart from "./PieChart/index";
import LineBarChart from "./LineBarChart/index";
import FunnelChart from "./FunnelChart/index";
import TopChart from "./TopChart/index";
import BaseChart from "./BaseChart/index";

const components = [
  ChinaMapChart,
  PieChart,
  LineBarChart,
  FunnelChart,
  TopChart,
  BaseChart,
];
const install = function (Vue) {
  if (install.installed) {
    return (install.installed = true);
  }
  components.forEach((component) => Vue.use(component));
};

if (typeof window !== "undefined" && window.Vue) {
  install(window.Vue);
}
export * from "./utils/index";
export default {
  install,
  ChinaMapChart,
  PieChart,
  LineBarChart,
  FunnelChart,
  TopChart,
  BaseChart,
};
