@playpilot/tpi 8.29.0-beta.2 → 8.29.0-beta.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/editorial.mount.js +3 -3
- package/dist/link-injections.js +1 -1
- package/dist/mount.js +3 -3
- package/package.json +1 -1
- package/src/lib/injection.ts +6 -2
package/package.json
CHANGED
package/src/lib/injection.ts
CHANGED
|
@@ -218,15 +218,19 @@ function createLinkInjectionElement(injection: LinkInjection): { injectionElemen
|
|
|
218
218
|
|
|
219
219
|
const openInExplore = !!window.PlayPilotLinkInjections?.config?.open_tpi_links_in_explore
|
|
220
220
|
|
|
221
|
-
const href =
|
|
221
|
+
const href =
|
|
222
|
+
injection.type === 'title' ?
|
|
223
|
+
openInExplore ? exploreTitleUrl(injection.title_details!) : titleUrl(injection.title_details!) :
|
|
224
|
+
'' // FIXME: We don't have participant streaming guide pages yet
|
|
222
225
|
|
|
223
226
|
const linkElement = document.createElement('a')
|
|
224
|
-
linkElement.dataset.playpilotPosterUrl = injection.title_details?.standing_poster
|
|
225
227
|
linkElement.innerText = injection.title
|
|
226
228
|
linkElement.href = href
|
|
227
229
|
linkElement.target = openInExplore ? '' : '_blank'
|
|
228
230
|
linkElement.rel = 'noopener nofollow noreferrer'
|
|
229
231
|
|
|
232
|
+
if (injection.type === 'title') linkElement.dataset.playpilotPosterUrl = injection.title_details?.standing_poster
|
|
233
|
+
|
|
230
234
|
injectionElement.insertAdjacentElement('beforeend', linkElement)
|
|
231
235
|
|
|
232
236
|
return { injectionElement, linkElement }
|