What should our position be regarding the Khalifahs who perpetrated unjust acts against Imam Ali (A.S)? Ought we to respect them as companions despite their wrong doing?

All the companions of the Prophet (PBUH) are respected other than those who perpetrated injustices against the Prophet Muhammad’s progeny.