mirror of
https://github.com/LuanRT/YouTube.js.git
synced 2026-06-16 19:12:24 +00:00
* feat: add settings page parsers * fix(AccountManager): small ts error * feat: add `CopyLink` & `SettingsCheckbox` * deps: remove “flat” dependency
23 lines
523 B
TypeScript
23 lines
523 B
TypeScript
import Parser from '../index';
|
|
import Text from './misc/Text';
|
|
import CompactLink from './CompactLink';
|
|
import { ObservedArray, YTNode } from '../helpers';
|
|
|
|
class SettingsSidebar extends YTNode {
|
|
static type = 'SettingsSidebar';
|
|
|
|
title: Text;
|
|
items: ObservedArray<CompactLink>;
|
|
|
|
constructor(data: any) {
|
|
super();
|
|
this.title = new Text(data.title);
|
|
this.items = Parser.parseArray<CompactLink>(data.items, CompactLink);
|
|
}
|
|
|
|
get contents() {
|
|
return this.items;
|
|
}
|
|
}
|
|
|
|
export default SettingsSidebar; |