Refactored to better support task card events