UNPKG

@np-dev/youtubei-js

Version:

A wrapper around YouTube's private API. Supports YouTube, YouTube Music, YouTube Kids and YouTube Studio (WIP).

15 lines 683 B
import { Parser } from '../index.js'; import { YTNode, observe } from '../helpers.js'; import PlaylistPanelVideo from './PlaylistPanelVideo.js'; class PlaylistPanelVideoWrapper extends YTNode { constructor(data) { super(); this.primary = Parser.parseItem(data.primaryRenderer, PlaylistPanelVideo); if (Reflect.has(data, 'counterpart')) { this.counterpart = observe(data.counterpart.map((item) => Parser.parseItem(item.counterpartRenderer, PlaylistPanelVideo)) || []); } } } PlaylistPanelVideoWrapper.type = 'PlaylistPanelVideoWrapper'; export default PlaylistPanelVideoWrapper; //# sourceMappingURL=PlaylistPanelVideoWrapper.js.map