"use strict";

var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
Object.defineProperty(exports, "__esModule", {
  value: true
});
exports.InlineImageCardErrorView = void 0;
var _react = require("@emotion/react");
var _statusWarning = _interopRequireDefault(require("@atlaskit/icon/core/status-warning"));
var _tooltip = _interopRequireDefault(require("@atlaskit/tooltip"));
var _frame = require("./frame");
var _iconWrapper = require("./icon-wrapper");
/**
 * @jsxRuntime classic
 * @jsx jsx
 */

// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports -- Ignored via go/DSP-18766; jsx required at runtime for @jsxRuntime classic

var InlineImageCardErrorView = exports.InlineImageCardErrorView = function InlineImageCardErrorView(_ref) {
  var _ref$testId = _ref.testId,
    testId = _ref$testId === void 0 ? 'media-inline-image-card-error-view' : _ref$testId,
    message = _ref.message,
    icon = _ref.icon;
  return (0, _react.jsx)(_frame.Frame, {
    testId: testId
  }, (0, _react.jsx)(_tooltip.default, {
    content: message,
    position: "top",
    tag: "span",
    hideTooltipOnClick: true
  }, (0, _react.jsx)(_iconWrapper.IconWrapper, null, icon || (0, _react.jsx)(_statusWarning.default, {
    label: "error",
    color: "var(--ds-icon-danger, #C9372C)"
  }))));
};