import React from "react";
import { connect } from "redux-bundler-react";
import {
  BasicToolbarButton,
  BasicToolbarMenu,
} from "../../application-controls";
import AddGeoJsonButton from "./add-geojson";
import AddShapefileButton from "./add-shapefile";
import AddKmlFileButton from "./add-kmlfile";

class AddDataButton extends React.Component {
  constructor(props) {
    super(props);
  }

  render() {
    return (
      <BasicToolbarButton
        enabled={true}
        iconClass="mdi mdi-plus-box-multiple"
        title="Add Data"
        onDeactivate={() => {}}
      >
        <BasicToolbarMenu>
          <AddGeoJsonButton />
          <AddShapefileButton />
          <AddKmlFileButton />
        </BasicToolbarMenu>
      </BasicToolbarButton>
    );
  }
}

export default connect("doNotificationsFire", AddDataButton);
