Files
YouTube.js/src/parser/classes/SegmentedLikeDislikeButton.ts
LuanRT 91847ae3cc feat(LiveChat): add SegmentedLikeDislikeButton and LiveChatDialog (#181)
* feat: add `LiveChatDialog`

* feat: add `SegmentedLikeDislikeButton`
2022-09-10 14:54:13 -03:00

18 lines
547 B
TypeScript

import Parser from '..';
import ToggleButton from './ToggleButton';
import { YTNode } from '../helpers';
class SegmentedLikeDislikeButton extends YTNode {
static type = 'SegmentedLikeDislikeButton';
like_button: ToggleButton | null;
dislike_button: ToggleButton | null;
constructor (data: any) {
super();
this.like_button = Parser.parseItem<ToggleButton>(data.likeButton, ToggleButton);
this.dislike_button = Parser.parseItem<ToggleButton>(data.dislikeButton, ToggleButton);
}
}
export default SegmentedLikeDislikeButton;