Browse Source

Remove unimplemented Analyze section from the sidebar.

Post Analyzer and Subreddit Insights were placeholders with no real tools behind them.

Co-authored-by: Cursor <cursoragent@cursor.com>
AhtashamShahzad1 1 month ago
parent
commit
ef9bc71441

+ 0 - 1
Reddit App/Models/NavigationModels.swift

@@ -10,7 +10,6 @@ struct SidebarNavItem: Identifiable, Hashable {
 enum SidebarSection: String, CaseIterable, Identifiable {
     case quickAccess = "QUICK ACCESS"
     case create = "CREATE"
-    case analyze = "ANALYZE"
 
     var id: String { rawValue }
 }

+ 0 - 6
Reddit App/Models/SidebarIconKind.swift

@@ -4,16 +4,12 @@ enum SidebarIconKind: Hashable {
     case postGenerator
     case titleOptimizer
     case commentWriter
-    case postAnalyzer
-    case subredditInsights
 
     var systemImage: String {
         switch self {
         case .postGenerator: "square.and.pencil"
         case .titleOptimizer: "textformat.size"
         case .commentWriter: "bubble.left.and.bubble.right.fill"
-        case .postAnalyzer: "chart.bar.doc.horizontal.fill"
-        case .subredditInsights: "person.3.fill"
         }
     }
 
@@ -22,8 +18,6 @@ enum SidebarIconKind: Hashable {
         case .postGenerator: [Color(hex: 0xC4B5FD), Color(hex: 0x7C3AED)]
         case .titleOptimizer: [Color(hex: 0x93C5FD), Color(hex: 0x2563EB)]
         case .commentWriter: [Color(hex: 0x86EFAC), Color(hex: 0x16A34A)]
-        case .postAnalyzer: [Color(hex: 0xFDBA74), Color(hex: 0xEA580C)]
-        case .subredditInsights: [Color(hex: 0x5EEAD4), Color(hex: 0x0D9488)]
         }
     }
 

+ 0 - 5
Reddit App/ViewModels/FrontPageViewModel.swift

@@ -27,9 +27,4 @@ final class FrontPageViewModel {
         SidebarNavItem(title: "Title Optimizer", subtitle: "Create viral titles", iconKind: .titleOptimizer),
         SidebarNavItem(title: "Comment Writer", subtitle: "Write smart replies", iconKind: .commentWriter),
     ]
-
-    let analyzeItems: [SidebarNavItem] = [
-        SidebarNavItem(title: "Post Analyzer", subtitle: "Analyze any post", iconKind: .postAnalyzer),
-        SidebarNavItem(title: "Subreddit Insights", subtitle: "Understand any subreddit", iconKind: .subredditInsights),
-    ]
 }

+ 0 - 8
Reddit App/Views/SidebarView.swift

@@ -69,14 +69,6 @@ struct SidebarView: View {
                         }
                     }
                 }
-
-                sidebarSection(title: SidebarSection.analyze.rawValue) {
-                    ForEach(viewModel.analyzeItems) { item in
-                        SidebarNavItemView(item: item, isSelected: viewModel.selectedNavItem == item) {
-                            viewModel.selectNavItem(item)
-                        }
-                    }
-                }
             }
             .padding(.horizontal, AppTheme.sidebarContentInset)
             .padding(.top, 4)