Moved calculate channel out of parent component