Financial-Times/dotcom-page-kit

Support for custom sticky headers

Opened this issue · 1 comments

The article page currently has a custom markup injected into the sticky header. This markup contains social and share links which replaces the MyFT logo on the right-hand side.

Because this feature is currently broken and had previously been switched off for 12 months or more we have not re-implemented it as part of the migration, however we may need to in future.

Adding an option (customStickyHeaderRightHandSideContent) and passing it down through the tree of components would be brittle and hard to rationalise. Because it is a rarely used feature it would also create a supportability problem.

I propose that if we do need this feature then we create a generic CustomStickyHeader component. It would maintain the drawer menu and search bar buttons but otherwise be a blank container for implementations to insert custom content.

Example:

import { Header, CustomStickyHeader } from '@financial-times/dotcom-ui-header';

<Header showStickyHeader={false} />
<CustomStickyHeader>{myContent}</CustomStickyHeader>

The MyFT Page Timeline and Topic views have a sticky element. Maybe that could use this.
Also Content Packages on article page.