Retrospring/app/javascript/retrospring/features/inbox/index.ts

15 lines
628 B
TypeScript

import registerEvents from 'utilities/registerEvents';
import registerInboxEntryEvents from './entry';
import { authorSearchHandler } from './author';
import { deleteAllAuthorQuestionsHandler, deleteAllQuestionsHandler } from './delete';
export default (): void => {
registerEvents([
{ type: 'click', target: '#ib-delete-all', handler: deleteAllQuestionsHandler, global: true },
{ type: 'click', target: '#ib-delete-all-author', handler: deleteAllAuthorQuestionsHandler, global: true },
{ type: 'submit', target: '#author-form', handler: authorSearchHandler, global: true }
]);
registerInboxEntryEvents();
}