Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add latest podcast video on home page #357

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,21 @@ $ const blockName = "callout-cards";
$ const uri = nxConfig.getUri();
$ const placement = nxConfig.getPlacement({ name: placementName, aliases });

$ const { site } = out.global;
$ const podcastVideoID = site.get('podcastVideoID')
$ const podcastVideoPlaylist = site.get('podcastVideoPlaylist') ? site.get('podcastVideoPlaylist') : podcastVideoID;

<marko-web-block name=blockName>
<marko-web-element block-name=blockName name="row">
<marko-web-element block-name=blockName name="col">

<div class="ad-container__wrapper" style="background-color:#f0f1f2; border-radius: 3px;">
<div style="border: 0pt none;">
<theme-latest-podcast-block alias="podcasts" />
<div align="center"> <iframe width="95%" height="180" src=`https://www.youtube.com/embed/${podcastVideoID}?playlist=${podcastVideoPlaylist}&widget_referrer=podcast&rel=0&autoplay=1&mute=1` title="Youtube Player" frameBorder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" allowFullScreen></iframe>
</div> </div>
</div>

</marko-web-element>
<marko-web-native-x-fetch-elements|{ ads }| uri=uri id=placement.id>
$ const hasAd = ads && ads.length && ads[0] && ads[0].hasCampaign;
Expand Down
Loading