UNPKG

@atlaskit/global-search

Version:

A cross-product search component (batteries included)

31 lines (29 loc) 1.43 kB
import _extends from "@babel/runtime/helpers/extends"; import React from 'react'; import { FormattedMessage } from 'react-intl'; import Button from '@atlaskit/button/custom-theme-button'; // AFP-2532 TODO: Fix automatic suppressions below // eslint-disable-next-line @atlassian/tangerine/import/entry-points import { gridSize, math } from '@atlaskit/theme'; import styled from 'styled-components'; import { messages } from '../messages'; import ErrorImage from '../assets/ErrorImage'; const ErrorWrapper = styled.div` text-align: center; margin-top: ${math.multiply(gridSize, 4)}px; `; export default class SearchError extends React.Component { render() { const { onRetryClick } = this.props; return /*#__PURE__*/React.createElement(ErrorWrapper, null, /*#__PURE__*/React.createElement(ErrorImage, null), /*#__PURE__*/React.createElement("h3", null, /*#__PURE__*/React.createElement(FormattedMessage, messages.search_error_title)), /*#__PURE__*/React.createElement("p", null, /*#__PURE__*/React.createElement("span", null, /*#__PURE__*/React.createElement(FormattedMessage, _extends({}, messages.search_error_body, { values: { link: /*#__PURE__*/React.createElement(Button, { appearance: "link", spacing: "none", onClick: onRetryClick }, /*#__PURE__*/React.createElement(FormattedMessage, messages.search_error_body_link)) } }))))); } }