dotcom-rendering
dotcom-rendering copied to clipboard
DCAR - migrate `filterSeenArticles` for user service
For the related content links at the bottom of an AR article, the cards are faded (opacity changed to 0.7 for both title and image) if a user has already "seen" or visited the article that the card represents.
This uses the filterSeenArticles
method on the Bridget userClient
in order to find which articles have been seen or not.
Example URL: https://mobile.guardianapis.com/uk/rendered-items/society/2023/aug/29/scrapping-of-housebuilder-water-pollution-rules-to-cost-taxpayer-140m
Try adding the class fade
to the cards in the "More on this story" section to see the effect