"use strict";

Object.defineProperty(exports, "__esModule", {
  value: true
});
exports.default = void 0;

require("antd/es/drawer/style");

var _drawer = _interopRequireDefault(require("antd/es/drawer"));

var _react = _interopRequireDefault(require("react"));

var _reactCodemirror = _interopRequireDefault(require("@uiw/react-codemirror"));

function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }

var CodeMirrorDrawer = function CodeMirrorDrawer(_ref) {
  var visiable = _ref.visiable,
      _ref$data = _ref.data,
      data = _ref$data === void 0 ? {} : _ref$data,
      onClose = _ref.onClose;
  return /*#__PURE__*/_react.default.createElement(_drawer.default, {
    visible: visiable,
    width: 500,
    onClose: onClose
  }, /*#__PURE__*/_react.default.createElement(_reactCodemirror.default, {
    value: JSON.stringify(data),
    options: {
      mode: 'json-ld',
      readonly: true
    }
  }));
};

var _default = CodeMirrorDrawer;
exports.default = _default;