Featured article page block
What's new
Page layouts accept a new block, FeaturedArticleBlock, which pins one article to a spot on the page. Point it at a single page with article_id, or hand it a collection_id and a rotation_period in seconds and it cycles through that collection on its own. hide_date drops the publication date from the card.
The block also joins the page_block union on AddPageBlockNode, so a page's graph_rules can insert one for a targeted audience.
Impact
This is the pages counterpart of FeaturedNewsBlock, which only ever took a fixed news_id. A featured slot can now be filled from a collection and rotate without anyone editing the layout.
Changes
| Resource | Change |
|---|---|
| get_pages, get_page, create_page, update_page, bulk_update_page, translate_page | Added FeaturedArticleBlock to the layout.blocks discriminator and oneOf |
| get_pages, get_page, create_page, update_page, bulk_update_page, translate_page | Added FeaturedArticleBlock to the page_block union on AddPageBlockNode inside DynamicBlock.graph_rules |
| Components | Added the FeaturedArticleBlock schema, with article_id, collection_id, rotation_period, and hide_date |
Upgrade
- No action required. To use the block, add an entry to
layout.blockswithblockset toFeaturedArticleBlock. - Clients that validate page responses against a generated model should regenerate, since this block type can now appear in
layout.blocksand in a parent page's layout.
需要技术支持?
联系我们的集成技术团队: [email protected]