import { TextButton } from '@wix/design-system';
import React from 'react';
import { useWixPatternsContainer } from '@wix/bex-core/react';
import { observer } from 'mobx-react-lite';
function _FilterAccordionResetButton(props) {
    const { state } = props;
    const { translate: t } = useWixPatternsContainer();
    const filter = state.getPendingFilter(props.filter);
    if (filter.isEmpty) {
        return null;
    }
    return (React.createElement(TextButton, { dataHook: `reset-filter-${filter.name}`, size: "medium", onClick: (e) => {
            e.stopPropagation();
            filter.reset({ emitEvents: ['change', 'refresh'] });
        } }, t('cairo.filtersPanel.reset')));
}
export const FilterAccordionResetButton = observer(_FilterAccordionResetButton);
//# sourceMappingURL=FilterAccordionResetButton.js.map