Aspects of predicative algebraic set theory III: sheaves