mirror of
https://github.com/LuanRT/YouTube.js.git
synced 2026-06-24 07:11:48 +00:00
@@ -1,13 +1,22 @@
|
||||
import { YTNode } from '../helpers.js';
|
||||
import { RawNode } from '../index.js';
|
||||
import Text from './misc/Text.js';
|
||||
|
||||
class ThumbnailOverlayBottomPanel extends YTNode {
|
||||
static type = 'ThumbnailOverlayBottomPanel';
|
||||
|
||||
icon_type: string;
|
||||
text?: Text;
|
||||
icon_type?: string;
|
||||
|
||||
constructor(data: any) {
|
||||
constructor(data: RawNode) {
|
||||
super();
|
||||
this.icon_type = data.icon.iconType;
|
||||
if (Reflect.has(data, 'text')) {
|
||||
this.text = new Text(data.text);
|
||||
}
|
||||
|
||||
if (Reflect.has(data, 'icon') && Reflect.has(data.icon, 'iconType')) {
|
||||
this.icon_type = data.icon.iconType;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user