mirror of
https://github.com/LuanRT/YouTube.js.git
synced 2026-07-01 02:15:42 +00:00
feat(parser): Add ListView, ListItemView and SubscribeButtonView (#1025)
This commit is contained in:
@@ -3,6 +3,7 @@ import { Parser, type RawNode } from '../index.js';
|
||||
import DialogHeaderView from './DialogHeaderView.js';
|
||||
import FormFooterView from './FormFooterView.js';
|
||||
import CreatePlaylistDialogFormView from './CreatePlaylistDialogFormView.js';
|
||||
import ListView from './ListView.js';
|
||||
import PanelFooterView from './PanelFooterView.js';
|
||||
|
||||
export default class DialogView extends YTNode {
|
||||
@@ -10,12 +11,12 @@ export default class DialogView extends YTNode {
|
||||
|
||||
public header: DialogHeaderView | null;
|
||||
public footer: FormFooterView | PanelFooterView | null;
|
||||
public custom_content: CreatePlaylistDialogFormView | null;
|
||||
public custom_content: CreatePlaylistDialogFormView | ListView | null;
|
||||
|
||||
constructor (data: RawNode) {
|
||||
super();
|
||||
this.header = Parser.parseItem(data.header, DialogHeaderView);
|
||||
this.footer = Parser.parseItem(data.footer, [ FormFooterView, PanelFooterView ]);
|
||||
this.custom_content = Parser.parseItem(data.customContent, CreatePlaylistDialogFormView);
|
||||
this.custom_content = Parser.parseItem(data.customContent, [ CreatePlaylistDialogFormView, ListView ]);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user