import React from 'react';
import PropTypes from 'prop-types';
import { Link } from 'react-router-dom';
import { Breadcrumb } from 'antd';
import { jsx as _jsx } from "react/jsx-runtime";
export default function BreadcrumbWrapper(props) {
  const {
    dbName,
    tableName,
    action
  } = props;
  return /*#__PURE__*/_jsx(Breadcrumb, {
    style: {
      margin: '16px 0'
    },
    items: [{
      title: /*#__PURE__*/_jsx(Link, {
        to: "/",
        children: "Home"
      })
    }, {
      title: dbName ? /*#__PURE__*/_jsx(Link, {
        to: `/${dbName}`,
        children: dbName
      }) : null
    }, {
      title: tableName ? /*#__PURE__*/_jsx(Link, {
        to: `/${dbName}/${tableName}`,
        children: tableName
      }) : null
    }, {
      title: action || null
    }]
  });
}
BreadcrumbWrapper.propTypes = {
  dbName: PropTypes.string,
  tableName: PropTypes.string,
  action: PropTypes.string
};
BreadcrumbWrapper.defaultProps = {
  dbName: '',
  tableName: '',
  action: ''
};
//# sourceMappingURL=BreadcrumbWrapper.js.map