Skip to content

Commit

Permalink
Put relatedTo in vs section feed block in at bottom of content
Browse files Browse the repository at this point in the history
  • Loading branch information
B77Mills committed Dec 4, 2023
1 parent 5f96c13 commit 8a3884b
Showing 1 changed file with 9 additions and 31 deletions.
40 changes: 9 additions & 31 deletions packages/global/components/layouts/content/default.marko
Original file line number Diff line number Diff line change
Expand Up @@ -278,37 +278,15 @@ $ const withRecommended = defaultValue(input.withRecommended, true);
</@section>
</if>

<!-- <@section|{ content }|>
<marko-web-identity-x-context|{ user, hasUser }|>
<if(user)>
$ const userAnswer = user.customSelectFieldAnswers.find(({id, answers}) => answers.length && id === recommendedQuestionId);
$ const answers = getAsArray(userAnswer, "answers");
$ const answer = shuffle(answers)[0];
$ const queryParams = {
limit: 4,
...get(idxConfig, `options.answerToQueryParamsMap.${recommendedQuestionId}.${answer.id}.queryParams`),
excludeContentIds: [content.id],
};
$ const title = user.givenName ? `Suggested for ${user.givenName}` : 'Suggested for You';
<theme-content-card-deck-block
title=title
query-params=queryParams
cols=4
view-more=false
with-native-x=false
/>
</if>
<else>
<theme-related-stories-block
content-id=content.id
section-id=content.primarySection.id
with-native-x=true
/>
</else>
</marko-web-identity-x-context>
</@section> -->
<@section|{ content }|>
<theme-related-stories-block
content-id=content.id
section-id=content.primarySection.id
with-native-x=true
/>
</@section>

<@section|{ content, aliases }|>
<!-- <@section|{ content, aliases }|>
<global-section-feed-wrapper aliases=aliases alias=content.primarySection.alias ad-name="rotation">
<@header>More in ${content.primarySection.name}</@header>
<@query-params excludeContentIds=[content.id] />
Expand All @@ -327,7 +305,7 @@ $ const withRecommended = defaultValue(input.withRecommended, true);
<theme-client-side-most-popular-list-block class="sticky-top" />
</@rail>
</global-section-feed-wrapper>
</@section>
</@section> -->

<for|s| of=sections>
<@section|{ blockName, content, aliases }| modifiers=s.modifiers>
Expand Down

0 comments on commit 8a3884b

Please sign in to comment.