implement Page::when