feat(parser): Add LiveChatSponsorshipsGiftPurchaseAnnouncement and LiveChatSponsorshipsHeader nodes (#793)

* feat(parser): Add `LiveChatSponsorshipsGiftPurchaseAnnouncement` and `LiveChatSponsorshipsHeader` nodes

* refactor: flatten nested field

* refactor: attempt to replace `author_*` fields with a single `Author` class

* fix: add back `author_*` fields in `LiveChatSponsorshipsHeader`

* fix: use `parseArray` to parse author_badges data

* refactor: revert `Author` logic

---------

Co-authored-by: absidue <48293849+absidue@users.noreply.github.com>
This commit is contained in:
jonz94
2024-11-02 19:08:41 +08:00
committed by GitHub
parent 34ae38cbf4
commit 4e9c2a585b
3 changed files with 53 additions and 0 deletions

View File

@@ -187,6 +187,8 @@ export { default as LiveChatPaidSticker } from './classes/livechat/items/LiveCha
export { default as LiveChatPlaceholderItem } from './classes/livechat/items/LiveChatPlaceholderItem.js';
export { default as LiveChatProductItem } from './classes/livechat/items/LiveChatProductItem.js';
export { default as LiveChatRestrictedParticipation } from './classes/livechat/items/LiveChatRestrictedParticipation.js';
export { default as LiveChatSponsorshipsGiftPurchaseAnnouncement } from './classes/livechat/items/LiveChatSponsorshipsGiftPurchaseAnnouncement.js';
export { default as LiveChatSponsorshipsHeader } from './classes/livechat/items/LiveChatSponsorshipsHeader.js';
export { default as LiveChatTextMessage } from './classes/livechat/items/LiveChatTextMessage.js';
export { default as LiveChatTickerPaidMessageItem } from './classes/livechat/items/LiveChatTickerPaidMessageItem.js';
export { default as LiveChatTickerPaidStickerItem } from './classes/livechat/items/LiveChatTickerPaidStickerItem.js';