import { MessageModalLayout, Text, } from '@wix/design-system';
import React from 'react';
import { observer } from 'mobx-react-lite';
import { ModalWrapper } from '../CollectionModal';
function _MessageActionModal({ state, content, onAfterClose, primaryButtonOnClick, secondaryButtonOnClick, onCloseButtonClick, ...rest }) {
    const { modal } = state;
    return (React.createElement(ModalWrapper, { state: modal, onAfterClose: () => {
            state.afterClose();
            onAfterClose?.();
        } },
        React.createElement(MessageModalLayout, { dataHook: "collection-action-modal", ...rest, onCloseButtonClick: (e) => {
                modal.close();
                onCloseButtonClick?.(e);
            }, primaryButtonOnClick: () => {
                modal.confirm();
                primaryButtonOnClick?.();
            }, secondaryButtonOnClick: rest.secondaryButtonText
                ? () => {
                    modal.decline();
                    secondaryButtonOnClick?.();
                }
                : undefined, content: typeof content === 'string' ? (React.createElement(Text, { dataHook: "action-modal-content" }, content)) : (content) })));
}
export const MessageActionModal = observer(_MessageActionModal);
//# sourceMappingURL=MessageActionModal.js.map