diff options
| author | Fuwn <[email protected]> | 2026-02-08 00:06:53 -0800 |
|---|---|---|
| committer | Fuwn <[email protected]> | 2026-02-08 00:06:53 -0800 |
| commit | 2f3acb221af8cac85d3653ce8e7c7c30eb73ea77 (patch) | |
| tree | 92ceab132fb4b6583cfaff46f5ac1adaed0a7d9e /apps/web/app/reader/_components/sidebar-content.tsx | |
| parent | fix: enforce same-origin on all service worker cache routes (diff) | |
| download | asa.news-2f3acb221af8cac85d3653ce8e7c7c30eb73ea77.tar.xz asa.news-2f3acb221af8cac85d3653ce8e7c7c30eb73ea77.zip | |
feat: display folders above ungrouped feeds in sidebar, add delete-all-custom-feeds to danger zone
Diffstat (limited to 'apps/web/app/reader/_components/sidebar-content.tsx')
| -rw-r--r-- | apps/web/app/reader/_components/sidebar-content.tsx | 78 |
1 files changed, 39 insertions, 39 deletions
diff --git a/apps/web/app/reader/_components/sidebar-content.tsx b/apps/web/app/reader/_components/sidebar-content.tsx index 4b58934..844f8b3 100644 --- a/apps/web/app/reader/_components/sidebar-content.tsx +++ b/apps/web/app/reader/_components/sidebar-content.tsx @@ -214,45 +214,6 @@ export function SidebarContent() { </div> )} - {ungroupedSubscriptions.length > 0 && ( - <div className="mt-3 space-y-0.5"> - {ungroupedSubscriptions.map((subscription) => ( - <Link - key={subscription.subscriptionIdentifier} - href={`/reader?feed=${subscription.feedIdentifier}`} - data-sidebar-nav-item - {...((unreadCounts?.[subscription.feedIdentifier] ?? 0) > 0 ? { "data-has-unreads": "" } : {})} - onClick={closeSidebarOnMobile} - className={classNames( - NAVIGATION_LINK_CLASS, - "flex items-center truncate pl-4 text-[0.85em]", - activeFeedIdentifier === subscription.feedIdentifier && - ACTIVE_LINK_CLASS, - sidebarFocusClass(focusedPanel, focusedSidebarIndex, navIndex++) - )} - > - {showFeedFavicons && ( - <FeedFavicon feedUrl={subscription.feedUrl} /> - )} - <span className={classNames("truncate", showFeedFavicons && "ml-2")}> - {displayNameForSubscription(subscription)} - </span> - {subscription.feedType === "podcast" && ( - <span className="ml-1 shrink-0 text-text-dim" title="podcast">♫</span> - )} - {subscription.consecutiveFailures > 0 && ( - <span className="ml-1 shrink-0 text-status-warning" title={subscription.lastFetchError ?? "feed error"}> - [!] - </span> - )} - <UnreadBadge - count={unreadCounts?.[subscription.feedIdentifier] ?? 0} - /> - </Link> - ))} - </div> - )} - {folders.map((folder) => { const isExpanded = expandedFolderIdentifiers.includes( folder.folderIdentifier @@ -347,6 +308,45 @@ export function SidebarContent() { ) })} + {ungroupedSubscriptions.length > 0 && ( + <div className="mt-3 space-y-0.5"> + {ungroupedSubscriptions.map((subscription) => ( + <Link + key={subscription.subscriptionIdentifier} + href={`/reader?feed=${subscription.feedIdentifier}`} + data-sidebar-nav-item + {...((unreadCounts?.[subscription.feedIdentifier] ?? 0) > 0 ? { "data-has-unreads": "" } : {})} + onClick={closeSidebarOnMobile} + className={classNames( + NAVIGATION_LINK_CLASS, + "flex items-center truncate pl-4 text-[0.85em]", + activeFeedIdentifier === subscription.feedIdentifier && + ACTIVE_LINK_CLASS, + sidebarFocusClass(focusedPanel, focusedSidebarIndex, navIndex++) + )} + > + {showFeedFavicons && ( + <FeedFavicon feedUrl={subscription.feedUrl} /> + )} + <span className={classNames("truncate", showFeedFavicons && "ml-2")}> + {displayNameForSubscription(subscription)} + </span> + {subscription.feedType === "podcast" && ( + <span className="ml-1 shrink-0 text-text-dim" title="podcast">♫</span> + )} + {subscription.consecutiveFailures > 0 && ( + <span className="ml-1 shrink-0 text-status-warning" title={subscription.lastFetchError ?? "feed error"}> + [!] + </span> + )} + <UnreadBadge + count={unreadCounts?.[subscription.feedIdentifier] ?? 0} + /> + </Link> + ))} + </div> + )} + <div className="mt-3 space-y-0.5"> <button type="button" |