Skip to content

Conversation

@ComputelessComputer
Copy link
Collaborator

• Added calendar icons
• Removed unnecessary routes and redirected to external links
• Fixed button sizing
• Refactored icons
• Updated calendar and integrations functionality

@coderabbitai
Copy link

coderabbitai bot commented Oct 21, 2025

📝 Walkthrough

Walkthrough

This PR refactors the settings UI system by introducing new Calendar and Integrations settings components, adding a shared ConnectedServiceCard component for consistent UI, replacing custom icon components with Iconify-based icons, and reorganizing settings navigation to handle external URL tabs while removing placeholder components.

Changes

Cohort / File(s) Summary
Icon Component Updates
packages/ui/src/components/icons/linkedin.tsx, packages/ui/src/components/icons/outlook.tsx, apps/desktop/src/components/main/body/sessions/floating/listen.tsx, apps/desktop/src/components/main/body/sessions/outer-header/metadata.tsx
Removed custom LinkedInIcon component; added new OutlookIcon SVG component; replaced static image icons with Iconify-based Icon components in listen and metadata components; consolidated imports.
Settings UI Components
apps/desktop/src/components/settings/calendar.tsx, apps/desktop/src/components/settings/integrations.tsx, apps/desktop/src/components/settings/shared.tsx
Implemented full Calendar and Integrations settings UIs with mock data, provider icons, and interactive cards; added reusable ConnectedServiceCard component with sync/reconnect/disconnect lifecycle handlers and advanced sections.
Settings Navigation & Routing
apps/desktop/src/routes/app/settings/_layout.tsx, apps/desktop/src/routes/app/settings/_layout.index.tsx
Added external URL handling for feedback/developers tabs via handleTabClick; removed conditional renders for SettingsFeedback and SettingsDevelopers tabs.
Removed Settings Components
apps/desktop/src/components/settings/developers.tsx, apps/desktop/src/components/settings/feedback.tsx
Deleted SettingsDevelopers and SettingsFeedback components (auth window and null render respectively).

Sequence Diagram(s)

sequenceDiagram
    participant User
    participant SettingsLayout as Settings Layout
    participant External as External URL
    participant Navigation as Search Navigation
    participant Tab as Settings Tab Component

    User->>SettingsLayout: Click tab (e.g., "feedback" or "developers")
    SettingsLayout->>SettingsLayout: handleTabClick()
    alt External Tab
        SettingsLayout->>External: openUrl(externalLink)
        External-->>User: Open in browser
    else Regular Tab
        SettingsLayout->>Navigation: navigate via search param
        Navigation->>Tab: render selected tab content
        Tab-->>User: display content
    end
Loading

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~25 minutes

Changes span multiple file categories (icons, settings components, routing) with heterogeneous modifications. Calendar and Integrations components introduce new UI logic with mock data structures and event handlers; ConnectedServiceCard adds reusable dialog/state management patterns. Icon replacements are straightforward but distributed across files. Settings route changes introduce conditional navigation logic. No single change is complex, but the variety of concerns across settings, icons, and routing requires separate reasoning per cohort.

Possibly related PRs

Suggested reviewers

  • yujonglee

Pre-merge checks and finishing touches

❌ Failed checks (1 warning)
Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. You can run @coderabbitai generate docstrings to improve docstring coverage.
✅ Passed checks (2 passed)
Check name Status Explanation
Title Check ✅ Passed The PR title "Refactored icons and updated calendar & integrations functionality" directly aligns with the main changes in the changeset. The title accurately highlights the two primary modification areas: extensive icon refactoring across multiple component files (replacing img tags with Icon components, removing LinkedInIcon, adding OutlookIcon) and the implementation of calendar and integrations settings UIs with mock data and interactive features. While the title does not capture all aspects of the PR (such as route removals and component deletions), this is expected and acceptable per the evaluation criteria. The title is concise, clear, and specific enough for a teammate to understand the primary changes when scanning the commit history.
Description Check ✅ Passed The PR description is related to the changeset and covers several key modifications: icon refactoring is confirmed across multiple files, calendar functionality updates are evident in the new Calendar Settings UI implementation, integrations functionality is added with search and filtering capabilities, and routes have been removed with external URL redirects implemented. While one point about "fixed button sizing" is not evident in the provided summaries and "added calendar icons" is somewhat vague, the overall description remains clearly related to the actual changes made in the PR. The description demonstrates a reasonable understanding of the modifications, meeting the lenient threshold for this check that requires only that the description be related in some way to the changeset.
✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch jj-branch-25

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 0

🧹 Nitpick comments (6)
apps/desktop/src/routes/app/settings/_layout.tsx (1)

87-95: Add error handling for external URL navigation.

The openUrl calls in handleTabClick could fail (e.g., invalid URL, permission issues) but errors are not caught or handled. Consider wrapping the calls in try-catch to gracefully handle failures.

Apply this diff to add error handling:

  const handleTabClick = async (tab: typeof TABS[number]) => {
-   if (tab === "feedback") {
-     await openUrl("https://hyprnote.canny.io/feature-requests");
-   } else if (tab === "developers") {
-     await openUrl("https://cal.com/team/hyprnote/welcome");
-   } else {
-     navigate({ search: { tab } });
-   }
+   try {
+     if (tab === "feedback") {
+       await openUrl("https://hyprnote.canny.io/feature-requests");
+     } else if (tab === "developers") {
+       await openUrl("https://cal.com/team/hyprnote/welcome");
+     } else {
+       navigate({ search: { tab } });
+     }
+   } catch (error) {
+     console.error("Failed to open URL:", error);
+     // Optionally: Show user-facing error notification
+   }
  };
apps/desktop/src/components/settings/shared.tsx (1)

123-145: Consider surfacing async errors to users.

While the try/finally blocks ensure state cleanup, errors from onSync and onReconnect are silently swallowed. Consider adding error handling to provide user feedback when operations fail.

Example enhancement:

  const handleSync = async () => {
    if (!onSync) {
      return;
    }
    setIsSyncing(true);
    try {
      await onSync();
    } catch (error) {
      console.error("Sync failed:", error);
      // Optionally: Show toast/notification to user
    } finally {
      setIsSyncing(false);
    }
  };
apps/desktop/src/components/settings/calendar.tsx (2)

74-90: Track TODO items for implementation.

Multiple TODO comments indicate placeholder logic for adding, removing, and toggling calendar accounts. These console.log statements should be replaced with actual implementations before release.

Would you like me to open an issue to track the implementation of these calendar management features?


144-154: Add error handling to mock async operations.

The mock sync and reconnect operations simulate delays but lack error handling. While these are placeholders, adding error handling now will make the transition to real implementations smoother.

Apply this pattern:

  const handleSync = async () => {
-   // Mock sync process - simulate API call
-   await new Promise((resolve) => setTimeout(resolve, 2000));
-   console.log("Synced account:", account.id);
+   try {
+     // Mock sync process - simulate API call
+     await new Promise((resolve) => setTimeout(resolve, 2000));
+     console.log("Synced account:", account.id);
+   } catch (error) {
+     console.error("Sync failed:", error);
+   }
  };
apps/desktop/src/components/settings/integrations.tsx (2)

103-111: Track TODO items for implementation.

The placeholder connect and disconnect handlers need real implementations. These should be tracked and implemented before release.

Would you like me to open an issue to track the implementation of integration connection management?


170-192: Add error handling to async operations.

The handleConnect function performs async operations but doesn't handle potential errors. This could leave the component in an inconsistent state if the connection fails.

Apply this diff:

  const handleConnect = async () => {
    setIsConnecting(true);
-   // Mock connect process - simulate API call
-   await new Promise((resolve) => setTimeout(resolve, 1500));
-   setIsConnecting(false);
-   onConnect(integration.id);
+   try {
+     // Mock connect process - simulate API call
+     await new Promise((resolve) => setTimeout(resolve, 1500));
+     onConnect(integration.id);
+   } catch (error) {
+     console.error("Connection failed:", error);
+     // Optionally: Show error notification to user
+   } finally {
+     setIsConnecting(false);
+   }
  };
📜 Review details

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 5e3ee05 and 10d5ac8.

⛔ Files ignored due to path filters (6)
  • apps/desktop/public/assets/conferencing-platforms/meet.png is excluded by !**/*.png
  • apps/desktop/public/assets/conferencing-platforms/teams.png is excluded by !**/*.png
  • apps/desktop/public/assets/conferencing-platforms/webex.png is excluded by !**/*.png
  • apps/desktop/public/assets/conferencing-platforms/zoom.png is excluded by !**/*.png
  • packages/ui/src/components/ui/button.tsx is excluded by !packages/ui/src/components/ui/**
  • pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
📒 Files selected for processing (11)
  • apps/desktop/src/components/main/body/sessions/floating/listen.tsx (5 hunks)
  • apps/desktop/src/components/main/body/sessions/outer-header/metadata.tsx (2 hunks)
  • apps/desktop/src/components/settings/calendar.tsx (1 hunks)
  • apps/desktop/src/components/settings/developers.tsx (0 hunks)
  • apps/desktop/src/components/settings/feedback.tsx (0 hunks)
  • apps/desktop/src/components/settings/integrations.tsx (1 hunks)
  • apps/desktop/src/components/settings/shared.tsx (2 hunks)
  • apps/desktop/src/routes/app/settings/_layout.index.tsx (0 hunks)
  • apps/desktop/src/routes/app/settings/_layout.tsx (3 hunks)
  • packages/ui/src/components/icons/linkedin.tsx (0 hunks)
  • packages/ui/src/components/icons/outlook.tsx (1 hunks)
💤 Files with no reviewable changes (4)
  • apps/desktop/src/components/settings/developers.tsx
  • apps/desktop/src/routes/app/settings/_layout.index.tsx
  • apps/desktop/src/components/settings/feedback.tsx
  • packages/ui/src/components/icons/linkedin.tsx
🧰 Additional context used
📓 Path-based instructions (1)
apps/desktop/**/*.{tsx,jsx}

📄 CodeRabbit inference engine (apps/desktop/.cursor/rules/style.mdc)

apps/desktop/**/*.{tsx,jsx}: When there are many Tailwind classNames with conditional logic, use the utility cn imported as import { cn } from "@hypr/utils"
When using cn for Tailwind classNames, always pass an array
Group Tailwind classNames by logical sections when using cn (split array items by grouping)

Files:

  • apps/desktop/src/routes/app/settings/_layout.tsx
  • apps/desktop/src/components/settings/calendar.tsx
  • apps/desktop/src/components/main/body/sessions/outer-header/metadata.tsx
  • apps/desktop/src/components/settings/shared.tsx
  • apps/desktop/src/components/settings/integrations.tsx
  • apps/desktop/src/components/main/body/sessions/floating/listen.tsx
🧬 Code graph analysis (4)
apps/desktop/src/routes/app/settings/_layout.tsx (1)
plugins/windows/src/ext.rs (1)
  • navigate (19-41)
apps/desktop/src/components/settings/calendar.tsx (2)
packages/ui/src/components/icons/outlook.tsx (1)
  • OutlookIcon (7-117)
apps/desktop/src/components/settings/shared.tsx (1)
  • ConnectedServiceCard (105-268)
apps/desktop/src/components/settings/shared.tsx (4)
packages/ui/src/components/ui/button.tsx (1)
  • Button (53-53)
packages/ui/src/components/ui/spinner.tsx (1)
  • Spinner (58-58)
packages/utils/src/cn.ts (1)
  • cn (20-22)
packages/ui/src/components/ui/dialog.tsx (6)
  • Dialog (107-107)
  • DialogContent (109-109)
  • DialogHeader (112-112)
  • DialogTitle (115-115)
  • DialogDescription (110-110)
  • DialogFooter (111-111)
apps/desktop/src/components/settings/integrations.tsx (1)
apps/desktop/src/components/settings/shared.tsx (1)
  • ConnectedServiceCard (105-268)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
  • GitHub Check: ci (macos, macos-14)
🔇 Additional comments (3)
apps/desktop/src/components/main/body/sessions/outer-header/metadata.tsx (1)

13-13: LGTM! Clean icon refactoring.

The migration from LinkedInIcon to the generic Icon component with icon="logos:linkedin-icon" is consistent with the broader icon consolidation effort across the codebase.

Also applies to: 131-131

apps/desktop/src/components/main/body/sessions/floating/listen.tsx (1)

1-5: LGTM! Consistent icon migration.

The refactoring from image-based icons to Icon components for Zoom, Google Meet, Webex, and Teams is clean and consistent. The iconify icon names are appropriate for each provider.

Also applies to: 57-57, 68-68, 79-79, 90-90

packages/ui/src/components/icons/outlook.tsx (1)

1-119: LGTM! Well-structured icon component.

The OutlookIcon component follows best practices:

  • Proper use of forwardRef for ref forwarding
  • Flexible size prop with sensible default
  • displayName set for debugging
  • SVG attributes properly spread

@yujonglee yujonglee merged commit 01f1330 into main Oct 22, 2025
7 checks passed
@yujonglee yujonglee deleted the jj-branch-25 branch October 22, 2025 00:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants