diff --git a/NUXT/components/CompactRenderers/compactChannelRenderer.vue b/NUXT/components/CompactRenderers/compactChannelRenderer.vue index 15abe95..19c9d23 100644 --- a/NUXT/components/CompactRenderers/compactChannelRenderer.vue +++ b/NUXT/components/CompactRenderers/compactChannelRenderer.vue @@ -36,8 +36,7 @@
{{ title.text }}
diff --git a/NUXT/pages/channel/channels.vue b/NUXT/pages/channel/channels.vue index 7b8b46c..c2c9e7c 100644 --- a/NUXT/pages/channel/channels.vue +++ b/NUXT/pages/channel/channels.vue @@ -1,3 +1,21 @@ + + diff --git a/NUXT/store/channel/index.js b/NUXT/store/channel/index.js index 568c402..642f640 100644 --- a/NUXT/store/channel/index.js +++ b/NUXT/store/channel/index.js @@ -10,6 +10,7 @@ const getDefaultState = () => { descriptionPreview: null, subscribers: null, videosCount: null, + featuredChannels: null, }; }; export const state = () => { @@ -25,7 +26,7 @@ export const actions = { this.$youtube .getChannel(channelRequest) .then((channel) => { - console.log(channel); + // console.log(channel); state.loading = false; state.banner = channel.header.channelMobileHeaderRenderer.channelHeader.elementRenderer.newElement.type.componentType.model.channelHeaderModel.channelBanner?.image.sources[0].url; @@ -43,6 +44,19 @@ export const actions = { channel.header.channelMobileHeaderRenderer.channelHeader.elementRenderer.newElement.type.componentType.model.channelHeaderModel.channelProfile.metadata.subscriberCountText; state.videosCount = channel.header.channelMobileHeaderRenderer.channelHeader.elementRenderer.newElement.type.componentType.model.channelHeaderModel.channelProfile.metadata.videosCountText; + const featuredSection = + channel.contents.singleColumnBrowseResultsRenderer.tabs[0].tabRenderer.content.sectionListRenderer.contents.find( + (i) => { + return !!i?.shelfRenderer?.content?.horizontalListRenderer + ?.items[0].gridChannelRenderer; + } + ); + console.log("CHANNEL INDEX"); + console.log(featuredSection); + state.featuredChannels = + featuredSection.shelfRenderer.content.horizontalListRenderer.items; + console.log("ITEMS ITEMS"); + console.log(state.featuredChannels); }) .catch((err) => { state.loading = false;