"use strict";

Object.defineProperty(exports, "__esModule", {
  value: true
});
exports["default"] = exports.VehicleExtButton = void 0;
var _react = _interopRequireDefault(require("react"));
var _vtxBaseModal = _interopRequireDefault(require("../vtx-base-modal"));
var _components = require("./components");
var _useSettings2 = _interopRequireDefault(require("../vm-hooks/useSettings"));
require("../style");
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
var TABS_BASE = 'road-base';
var TABS_STATIC = 'road-statistical';
var VtxRoadModal = function VtxRoadModal(props) {
  var _contents;
  var id = props.id,
    title = props.title,
    subTitle = props.subTitle,
    visible = props.visible,
    onCancel = props.onCancel;
  // const isDark = theme === 'dark';
  return /*#__PURE__*/_react["default"].createElement(_react["default"].Fragment, null, visible && /*#__PURE__*/_react["default"].createElement(_vtxBaseModal["default"], {
    title: title,
    subTitle: subTitle,
    width: 1355,
    visible: visible,
    onCancel: onCancel,
    tabs: [{
      key: TABS_BASE,
      title: '总览信息'
    }, {
      key: TABS_STATIC,
      title: '统计信息'
    }
    // { key: TABS_WARNNING, title: '报警信息' },
    ],
    contents: (_contents = {}, _defineProperty(_contents, TABS_BASE, /*#__PURE__*/_react["default"].createElement(_components.BaseInfo, {
      id: id
    })), _defineProperty(_contents, TABS_STATIC, /*#__PURE__*/_react["default"].createElement(_components.Statistical, {
      id: id
    })), _contents)
  }));
};
var VehicleExtButton = function VehicleExtButton(props) {
  var img = props.img,
    text = props.text,
    onClick = props.onClick;
  var _useSettings = (0, _useSettings2["default"])(),
    theme = _useSettings.theme;
  return /*#__PURE__*/_react["default"].createElement("div", {
    className: "vtx-vehicle-ext-btn ".concat(theme),
    onClick: onClick
  }, /*#__PURE__*/_react["default"].createElement("img", {
    src: img,
    alt: ""
  }), /*#__PURE__*/_react["default"].createElement("span", null, text));
};
exports.VehicleExtButton = VehicleExtButton;
var _default = VtxRoadModal;
exports["default"] = _default;
//# sourceMappingURL=index.js.map
