Skip to content

Commit

Permalink
fix(LockupMetadataView): Parse menuButton
Browse files Browse the repository at this point in the history
  • Loading branch information
LuanRT committed Jan 25, 2025
1 parent 083aec1 commit 3ffdee9
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions src/parser/classes/LockupMetadataView.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,19 +3,21 @@ import { Parser, type RawNode } from '../index.js';
import ContentMetadataView from './ContentMetadataView.js';
import DecoratedAvatarView from './DecoratedAvatarView.js';
import Text from './misc/Text.js';
import ButtonView from './ButtonView.js';

export default class LockupMetadataView extends YTNode {
static type = 'LockupMetadataView';

title: Text;
metadata: ContentMetadataView | null;
image: DecoratedAvatarView | null;
public title: Text;
public metadata: ContentMetadataView | null;
public image: DecoratedAvatarView | null;
public menu_button: ButtonView | null;

constructor(data: RawNode) {
super();

this.title = Text.fromAttributed(data.title);
this.metadata = Parser.parseItem(data.metadata, ContentMetadataView);
this.image = Parser.parseItem(data.image, DecoratedAvatarView);
this.menu_button = Parser.parseItem(data.menuButton, ButtonView);
}
}

0 comments on commit 3ffdee9

Please sign in to comment.