Description of the need

If a Layout made its contexts available to its custom blocks, this would allow people to use tokens related to the entities in the context. Use case: create a custom block that displays some node properties like the created date, which are otherwise not selectively available.

Currently the layout contexts are not available to BlockText, which is the class that custom blocks use. While BlockText::getContent() does invoke token_replace() it does so without any context, meaning that only global tokens are fulfilled.

GitHub Issue #: 
5666