import React from 'react';
import styles from "./index.module.less";
import { FileIcons } from "../../../constant";
function DatasourceCard(props) {
  var type = props.type,
    title = props.title,
    desc = props.desc,
    onDelete = props.onDelete;
  return /*#__PURE__*/React.createElement("div", {
    className: styles.datasourceCard
  }, /*#__PURE__*/React.createElement("img", {
    src: FileIcons[type],
    alt: type
  }), /*#__PURE__*/React.createElement("div", {
    className: styles.title,
    title: title
  }, title), desc && /*#__PURE__*/React.createElement("div", {
    className: styles.desc
  }, desc), onDelete && /*#__PURE__*/React.createElement("img", {
    className: styles.delete,
    onClick: onDelete,
    src: "https://mdn.alipayobjects.com/huamei_2yzvel/afts/img/A*xfBPTJxWAjoAAAAAAAAAAAAAeriAAQ/original"
  }));
}
export { DatasourceCard };