Remove _MagicForm and refactor custom_form_factory