MCPcopy Create free account
hub / github.com/dailydotdev/apps / forYouMenu

Function forYouMenu

packages/shared/src/components/shell/HomeSegments.tsx:215–227  ·  view source on GitHub ↗
(isDefaultCustom: boolean)

Source from the content-addressed store, hash-verified

213 // A caller with its own For you sheet owns that tab's menu, and shows the
214 // feed's settings itself while a custom default feed is the page.
215 const forYouMenu = (isDefaultCustom: boolean): RowItem['menu'] => {
216 if (forYou) {
217 return isForYouMenu
218 ? { ariaLabel: forYou.ariaLabel, onOpen: forYou.onMenu }
219 : undefined;
220 }
221 return feedMenu(
222 'For you',
223 isDefaultCustom
224 ? `${webappUrl}feeds/${defaultFeedId}/edit`
225 : `${webappUrl}feeds/${user?.id}/edit?dview=${FeedSettingsMenu.Tags}`,
226 );
227 };
228
229 if (user) {
230 const isDefaultCustom = isCustomDefaultFeed && path === '/';

Callers 1

HomeSegmentsFunction · 0.85

Calls 1

feedMenuFunction · 0.85

Tested by

no test coverage detected