small fixes to books
Moved indexing into BookItem class. Added a type to every BookComponent.