leaflets: Let ContextItems inherit from object