(slotProps: AdSlotRootProps = {})
| 445 | ); |
| 446 | |
| 447 | const card = (slotProps: AdSlotRootProps = {}) => ( |
| 448 | <ActivePostContextProvider post={itemPost}> |
| 449 | {WideCard ? ( |
| 450 | <WideCard {...postCardProps} wideColSpan={wideColSpan}> |
| 451 | {explainCard} |
| 452 | </WideCard> |
| 453 | ) : ( |
| 454 | <PostTag {...postCardProps} domProps={slotProps}> |
| 455 | {explainCard} |
| 456 | {item.type === FeedItemType.Ad && ( |
| 457 | <> |
| 458 | <AdPixel ad={item.ad} /> |
| 459 | <AdMeasurement ad={item.ad} /> |
| 460 | <AdViewability |
| 461 | ad={item.ad} |
| 462 | onViewable={(data) => onAdViewable(item.ad, data)} |
| 463 | /> |
| 464 | </> |
| 465 | )} |
| 466 | </PostTag> |
| 467 | )} |
| 468 | </ActivePostContextProvider> |
| 469 | ); |
| 470 | return item.type === FeedItemType.Ad ? ( |
| 471 | <AdSlot ad={item.ad}>{card}</AdSlot> |
| 472 | ) : ( |
no test coverage detected