import useTranslateValue from "../../Utils/Translation";
import React from "react";
const ErrorMessage = (props) => {
    var _a, _b;
    const { translateValue, translateString } = useTranslateValue();
    const translatedMessage = typeof props.message === "string"
        ? (_a = translateValue(props.message)) !== null && _a !== void 0 ? _a : props.message
        : props.message;
    return (React.createElement("div", { className: "text-center my-10 text-gray-500 text-sm" },
        translatedMessage,
        props.onRefreshClick ? (React.createElement("div", { role: "refresh-button", onClick: () => {
                if (props.onRefreshClick) {
                    props.onRefreshClick();
                }
            }, className: "underline cursor-pointer hover:text-gray-700 mt-3" }, (_b = translateString("Refresh?")) !== null && _b !== void 0 ? _b : "Refresh?")) : (React.createElement(React.Fragment, null))));
};
export default ErrorMessage;
//# sourceMappingURL=ErrorMessage.js.map