import { jsx as _jsx } from "react/jsx-runtime";
// (C) 2024-2025 GoodData Corporation
import { FormattedMessage, defineMessages, useIntl } from "react-intl";
import { Notification } from "./Notification.js";
import { bem } from "../bem.js";
const { b, e } = bem("gd-ui-ext-notification");
/**
 * Default implementation of the Notification component.
 *
 * @public
 */
export function DefaultNotification({ notification, markNotificationAsRead, onNotificationClick, closeNotificationsPanel, }) {
    if (notification.notificationType === "testNotification") {
        return _jsx(UnsupportedNotificationType, {});
    }
    return (_jsx(Notification, { notification: notification, markNotificationAsRead: markNotificationAsRead, onNotificationClick: onNotificationClick, closeNotificationsPanel: closeNotificationsPanel }));
}
function UnsupportedNotificationType() {
    const { formatMessage } = useIntl();
    return (_jsx("div", { className: b({ isUnsupported: true }), role: "listitem", tabIndex: 0, "aria-label": formatMessage(messages.unsupportedNotificationType), children: _jsx("div", { className: e("unsupported"), children: _jsx(FormattedMessage, { id: messages.unsupportedNotificationType.id }) }) }));
}
const messages = defineMessages({
    unsupportedNotificationType: {
        id: "notifications.panel.unsupported.notification.type",
    },
});
//# sourceMappingURL=DefaultNotification.js.map