Skip to content

Conversation

@chmurson
Copy link
Collaborator

@chmurson chmurson commented Aug 28, 2025

Summary by CodeRabbit

  • New Features

    • None
  • Style

    • Themed modal overlay and content for improved readability and contrast.
    • Enforced dark color scheme on Undo, Redo, and Pin buttons for consistent header visuals.
    • Refreshed Settings modal typography and close button positioning.
    • Applied sidebar-foreground text color to the Remote Sources section.
  • Chores

    • Updated shared UI dependency to the latest patch version.

@netlify
Copy link

netlify bot commented Aug 28, 2025

Deploy Preview for graypaper-reader ready!

Name Link
🔨 Latest commit 5447a5c
🔍 Latest deploy log https://app.netlify.com/projects/graypaper-reader/deploys/68b0b6486bd83e0008fd8137
😎 Deploy Preview https://deploy-preview-304--graypaper-reader.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@coderabbitai
Copy link

coderabbitai bot commented Aug 28, 2025

Walkthrough

Updates the shared UI dependency version, adds modal styling in CSS, forces dark color scheme on specific header buttons, adjusts Settings modal class names, and wraps RemoteSources content in a div with a sidebar-foreground text class.

Changes

Cohort / File(s) Summary
Dependency bump
package.json
Update dependency @fluffylabs/shared-ui from ^0.1.5 to ^0.1.6.
Modal CSS theming
src/App.css
Add .ReactModal__Overlay and .ReactModal__Content styles with light-dark backgrounds and border color; use !important.
Header buttons color scheme
src/components/Header/components/NotesButtonsGroup.tsx
Add forcedColorScheme="dark" to Undo, Redo, and Pin toggle buttons.
Settings modal class updates
src/components/Header/components/SettingsModal.tsx
Change close button and title classNames; layout/positioning via classes only; behavior unchanged.
RemoteSources wrapper styling
src/components/RemoteSources/RemoteSources.tsx
Replace fragment with <div className="text-sidebar-foreground"> wrapper; content unchanged.

Sequence Diagram(s)

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Possibly related PRs

Suggested reviewers

  • DrEverr
  • mateuszsikora

Poem

A bunny taps keys with a gentle cheer,
Dark buttons gleam, the modals draw near.
Sidebar whispers, colors align,
Packages hop to a newer sign.
With tidier threads and styles that sing,
I twitch my nose—ship the spring! 🐇✨

✨ Finishing Touches
  • 📝 Generate Docstrings
🧪 Generate unit tests
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch fix-colors-in-notes-top-bar-buttons

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
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbit in a new review comment at the desired location with your query.
  • PR comments: Tag @coderabbit in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbit gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbit read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

CodeRabbit Commands (Invoked using PR/Issue comments)

Type @coderabbit help to get the list of available commands.

Other keywords and placeholders

  • Add @coderabbit ignore or @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbit summary or @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbit or @coderabbitai anywhere in the PR title to generate the title automatically.

Status, Documentation and Community

  • Visit our Status Page to check the current availability of CodeRabbit.
  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

@chmurson chmurson merged commit 46c90ba into main Aug 28, 2025
7 of 8 checks passed
@chmurson chmurson deleted the fix-colors-in-notes-top-bar-buttons branch August 28, 2025 20:07
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: 1

🧹 Nitpick comments (5)
src/components/Header/components/NotesButtonsGroup.tsx (3)

17-27: Add accessible name to the Undo button.

Tooltips aren’t read by screen readers. Provide an aria-label.

         <Button
           forcedColorScheme="dark"
           variant="outline"
           onClick={handleUndo}
           disabled={!canUndo}
           className="h-[32px]"
+          aria-label="Undo"
           data-tooltip-id="notes-button-tooltip"
           data-tooltip-content="Undo"

30-41: Add accessible name to the Redo button.

Mirror the Undo change for consistency and a11y.

         <Button
           forcedColorScheme="dark"
           variant="outline"
           onClick={handleRedo}
           disabled={!canRedo}
           className="h-[32px]"
+          aria-label="Redo"
           data-tooltip-id="notes-button-tooltip"
           data-tooltip-content="Redo"

44-54: Pin toggle: a11y label and visual consistency with other header buttons.

  1. Add an aria-label that tracks the current state. 2) Consider aligning MoreButtonNotesActionsButton with the same forcedColorScheme="dark" for a consistent top bar look.
         <Button
           forcedColorScheme="dark"
           variant="outline"
           onClick={() => setNotesPinned(!notesPinned)}
           className="h-[32px]"
+          aria-label={notesPinned ? "Unpin notes" : "Pin notes"}
           data-tooltip-id="notes-button-tooltip"
           data-tooltip-content={notesPinned ? "Unpin" : "Pin"}
src/components/RemoteSources/RemoteSources.tsx (1)

22-44: Replace undefined Tailwind token with CSS variable
Replace text-sidebar-foreground with the arbitrary value class text-[var(--sidebar-foreground)], since no text-sidebar-foreground token is defined in your tailwind.config.js.

-    <div className="text-sidebar-foreground">
+    <div className="text-[var(--sidebar-foreground)]">
src/App.css (1)

67-71: Border color: add fallback and remove stale commented rule.

Provide a non-light-dark() fallback and delete the commented line to reduce confusion.

 .ReactModal__Content {
   background: var(--sidebar) !important;
-  /* border-color: light-dark(rgba(204, 204, 204), #111) !important; */
-  border-color: light-dark(rgba(204, 204, 204), #666) !important;
+  /* Fallback for browsers without light-dark() */
+  border-color: #666;
+  border-color: light-dark(rgba(204, 204, 204), #666) !important;
 }
📜 Review details

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

💡 Knowledge Base configuration:

  • MCP integration is disabled by default for public repositories
  • Jira integration is disabled by default for public repositories
  • Linear integration is disabled by default for public repositories

You can enable these sources in your CodeRabbit configuration.

📥 Commits

Reviewing files that changed from the base of the PR and between 3ea78a0 and 5447a5c.

⛔ Files ignored due to path filters (1)
  • package-lock.json is excluded by !**/package-lock.json
📒 Files selected for processing (5)
  • package.json (1 hunks)
  • src/App.css (1 hunks)
  • src/components/Header/components/NotesButtonsGroup.tsx (3 hunks)
  • src/components/Header/components/SettingsModal.tsx (1 hunks)
  • src/components/RemoteSources/RemoteSources.tsx (2 hunks)
🧰 Additional context used
📓 Path-based instructions (2)
**/*.css

⚙️ CodeRabbit configuration file

Review CSS code with focus on Tailwind CSS 4.x best practices and conventions. Ensure compatibility with Tailwind 4.x features and syntax.

Files:

  • src/App.css
**/*.{js,jsx,ts,tsx}

⚙️ CodeRabbit configuration file

When reviewing Tailwind CSS classes, ensure they follow Tailwind 4.x conventions and suggest modern 4.x alternatives for deprecated patterns.

Files:

  • src/components/RemoteSources/RemoteSources.tsx
  • src/components/Header/components/SettingsModal.tsx
  • src/components/Header/components/NotesButtonsGroup.tsx
🔇 Additional comments (2)
package.json (1)

22-22: Verify forcedColorScheme API support in @fluffylabs/shared-ui@^0.1.6 and update lockfile

  • Ensure the Button component accepts forcedColorScheme="dark" and that no peer dependencies have changed.
  • Regenerate and commit the updated package-lock.json.
src/components/Header/components/SettingsModal.tsx (1)

11-15: Refactor header to use flex layout and add aria-label
Replace the float-based header with a flex container to prevent title overlap and improve accessibility:

-      <button className="default-button float-right" onClick={onClose}>
-        ✖︎
-      </button>
-      <div className="text-2xl font-bold mb-4">Settings</div>
+      <div className="mb-4 flex items-start justify-between gap-2">
+        <div className="text-2xl font-bold">Settings</div>
+        <button
+          className="default-button shrink-0"
+          onClick={onClose}
+          aria-label="Close settings"
+        >
+          ✖︎
+        </button>
+      </div>

Verify the modal layout after this change to catch any regressions.

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.

1 participant