Skip to content

Conversation

@kyrers
Copy link

@kyrers kyrers commented Oct 23, 2025

Resolves #88.


PR-Codex overview

This PR primarily focuses on refactoring the styling approach of the application by replacing styled-components with Tailwind CSS utility classes, enhancing the overall design consistency and maintainability.

Detailed summary

  • Removed several styled-components files and their usages.
  • Introduced Tailwind CSS for styling across various components.
  • Updated the Overlay component to use Tailwind classes.
  • Modified the Logo and InfoCard components to utilize Tailwind.
  • Refactored the MobileHeader, Menu, and Settings components for better styling with Tailwind.
  • Updated LightButton to use Tailwind classes instead of styled-components.
  • Removed StyledComponentsProvider and integrated ThemeProvider for theme management.
  • Adjusted various components to ensure consistent theme usage and responsiveness with Tailwind.
  • Added utility functions for class merging (cn function) and introduced tailwindcss and tailwind-merge as dependencies.

The following files were skipped due to too many changes: yarn.lock

✨ Ask PR-Codex anything about this PR by commenting with /codex {your question}

Summary by CodeRabbit

  • Chores

    • Updated dependencies: added Tailwind tooling, tailwind-merge, clsx; upgraded UI library; removed legacy modal and styled‑components packages.
  • New Features

    • Added a ThemeProvider and consolidated global stylesheet with persisted light/dark mode, design tokens, scrollbar and toast styling.
  • Refactor

    • Migrated styling from CSS‑in‑JS to utility/class-based styles across layout and many components.
  • Other

    • Added a cn utility for className merging; minor Button prop change for disabling.

@kyrers kyrers self-assigned this Oct 23, 2025
@netlify
Copy link

netlify bot commented Oct 23, 2025

Deploy Preview for curate-v2 failed. Why did it fail? →

Name Link
🔨 Latest commit 4474759
🔍 Latest deploy log https://app.netlify.com/projects/curate-v2/deploys/69125fcc5b8feb00075cabd0

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Oct 23, 2025

Walkthrough

Replaces styled-components and react-modal with Tailwind/className styling, upgrades @kleros/ui-components-library to v3, adds Tailwind tooling and global.css, removes styled-components themes/helpers and type augmentation, introduces a DOM-class ThemeProvider, and adds a cn utility; many components migrated to class-based markup.

Changes

Cohort / File(s) Change Summary
Dependencies & Build
web/package.json, web/vite.config.js
Add Tailwind tooling (tailwindcss, @tailwindcss/vite), clsx, tailwind-merge; upgrade @kleros/ui-components-library to v3; remove react-modal and some styled-components type deps; register Tailwind plugin in Vite.
Root & Providers
web/src/app.tsx, web/src/context/StyledComponentsProvider.tsx (deleted), web/src/context/ThemeProvider.tsx
Replace StyledComponentsProvider with new ThemeProvider that persists theme in localStorage, toggles light/dark, and applies/removes dark class on document.documentElement.
Global styles & tokens
web/src/global.css (new), web/global.d.ts
Add global.css with Tailwind imports, design tokens, dark-mode rules, and third-party overrides (Toastify, skeleton); convert global.d.ts from styled-components augmentation to a module (export {}).
Remove CSS-in-JS themes & helpers
web/src/styles/* (deleted: themes.ts, global-style.ts, commonStyles.ts, customScrollbar.ts, landscapeStyle.ts)
Remove styled-components-based themes, global styles, helpers and exports; visual tokens and rules migrated into global.css and class-based styling.
Modal setup removed
web/src/index.tsx
Remove react-modal import and Modal.setAppElement(container) setup.
Web3 provider tweak
web/src/context/Web3Provider.tsx
Replace theme import usage with hardcoded color #4D00B4 in themeVariables.
Layout & component styling migration
web/src/layout/**, web/src/components/** (examples)
Migrate many components (headers, menus, settings, buttons, overlays, portals, Product, AccountDisplay, InfoCard, LightButton, etc.) from styled-components to plain JSX with utility/className-based styling; preserve logic and public APIs (minor prop additions like optional className).
Utility helper added
web/src/utils/index.ts
Add cn(...inputs) helper that composes clsx and tailwind-merge for className merging.
Minor prop adjustments
web/src/components/EnsureAuth.tsx, web/src/components/InfoCard.tsx
Button usage changed to isDisabled; InfoCard accepts optional className prop.

Sequence Diagram(s)

sequenceDiagram
    participant App as App.tsx
    participant Theme as ThemeProvider
    participant ToggleCtx as ToggleThemeProvider
    participant Doc as document.documentElement

    App->>Theme: render <ThemeProvider>{children}
    Theme->>Theme: read saved theme from localStorage (default "dark")
    Theme->>ToggleCtx: provide { theme, toggleTheme }
    Theme->>Doc: add/remove "dark" class on root

    rect rgba(46,125,50,0.08)
    Note right of Theme: User invokes toggleTheme → updates state → persists to localStorage
    end
Loading

Estimated code review effort

🎯 4 (Complex) | ⏱️ ~45 minutes

  • Areas to focus:
    • web/src/global.css — large token surface, dark-mode rules, and third-party overrides (Toastify, skeleton).
    • Type impacts from removing styled-components augmentation: web/global.d.ts and any remaining DefaultTheme usages.
    • Visual/regression checks across header/menu/layout components after migration from styled-components to classNames.
    • Vite/Tailwind plugin registration and dependency alignment in package.json.
    • web/src/context/Web3Provider.tsx — verify the hardcoded color change is intentional.

Possibly related issues

Possibly related PRs

Suggested labels

Package: Web, Type: Enhancement :sparkles:

Suggested reviewers

  • kemuru
  • Harman-singh-waraich
  • jaybuidl

Poem

🐇 I hopped through styles and swapped each thread,
Tailwind seeds were planted where old themes once spread.
The root wears "dark", cn sorts classes tight,
Buttons, headers, portals — reborn in light. 🥕

Pre-merge checks and finishing touches

✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The PR title 'chore: migrate from styled components to tailwind' clearly and concisely describes the main refactoring objective of the entire changeset.
Linked Issues check ✅ Passed All code changes align with issue #88 objectives: migrated to @kleros/ui-components-library v3, removed styled-components, replaced with Tailwind utility classes, integrated Tailwind into build pipeline, and updated theme handling.
Out of Scope Changes check ✅ Passed All changes directly support the migration objectives. Dependency updates (@kleros/ui-components-library v3, tailwindcss tooling, clsx, tailwind-merge), removal of styled-components packages, and consistent component refactoring are all in-scope for the Tailwind migration.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
✨ 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 chore/migrate-from-styled-components-to-tailwind

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

Copy link
Contributor

@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 (2)
web/src/global.css (1)

60-62: Consider reducing !important usage.

The !important declarations on lines 61 and 147 override library defaults for ReactModal and Toastify. While sometimes necessary for third-party library overrides, consider if these can be achieved through higher CSS specificity instead.

If the library CSS is loaded before your global styles, you may be able to increase specificity without !important:

/* Instead of: */
.ReactModal__Overlay {
  background-color: #1b003fcc !important;
}

/* Try: */
.ReactModal__Overlay.ReactModal__Overlay {
  background-color: #1b003fcc;
}

Also applies to: 145-148

web/src/context/ThemeProvider.tsx (1)

8-8: Improve type safety for theme values.

The theme is currently typed as string, which allows any string value. This should be constrained to the valid theme values for better type safety and developer experience.

Apply this diff to add proper typing:

+type Theme = "light" | "dark";
+
 const ThemeProvider: React.FC<{
   children: React.ReactNode;
 }> = ({ children }) => {
-  const [theme, setTheme] = useLocalStorage<string>("theme", "dark");
+  const [theme, setTheme] = useLocalStorage<Theme>("theme", "dark");
📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between bc5502a and ad2c61b.

⛔ Files ignored due to path filters (1)
  • yarn.lock is excluded by !**/yarn.lock, !**/*.lock
📒 Files selected for processing (11)
  • web/package.json (2 hunks)
  • web/src/app.tsx (3 hunks)
  • web/src/context/StyledComponentsProvider.tsx (0 hunks)
  • web/src/context/ThemeProvider.tsx (1 hunks)
  • web/src/global.css (1 hunks)
  • web/src/styles/commonStyles.ts (0 hunks)
  • web/src/styles/customScrollbar.ts (0 hunks)
  • web/src/styles/global-style.ts (0 hunks)
  • web/src/styles/landscapeStyle.ts (0 hunks)
  • web/src/styles/themes.ts (0 hunks)
  • web/vite.config.js (2 hunks)
💤 Files with no reviewable changes (6)
  • web/src/styles/global-style.ts
  • web/src/styles/landscapeStyle.ts
  • web/src/styles/themes.ts
  • web/src/styles/commonStyles.ts
  • web/src/styles/customScrollbar.ts
  • web/src/context/StyledComponentsProvider.tsx
⏰ 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). (3)
  • GitHub Check: Redirect rules - curate-v2
  • GitHub Check: Header rules - curate-v2
  • GitHub Check: Pages changed - curate-v2
🔇 Additional comments (6)
web/vite.config.js (1)

5-5: LGTM! Tailwind v4 Vite integration is correct.

The Tailwind CSS integration follows the standard pattern for v4 with Vite using the @tailwindcss/vite plugin.

Also applies to: 32-32

web/src/global.css (1)

1-20: LGTM! Tailwind v4 @theme directive and imports are correctly structured.

The global CSS setup follows Tailwind v4 best practices: importing the UI library theme, importing Tailwind, and defining custom design tokens via the @theme directive. The token definitions are comprehensive and well-organized.

web/package.json (2)

78-78: LGTM! Tailwind CSS dependencies are correctly added.

Both tailwindcss and @tailwindcss/vite are on the same version (4.1.16), which ensures consistency. The @tailwindcss/vite package is appropriately placed in both dependencies and devDependencies for build tooling access.

Also applies to: 107-107


73-73: Manually verify component compatibility after Tailwind migration to v3.6.0.

The upgrade to v3.6.0 involved a major migration from styled-components to Tailwind CSS. The library was migrated to Tailwind CSS, which includes changes to component styling and theming. Tailwind is already configured in the project (v4.1.16).

The codebase uses 23+ components from the library across 40+ files, including several internal components prefixed with underscore (_TimelineItem1, _IItem1). However, no public changelog documents specific breaking changes and component API modifications for v3.6.0.

Actions required:

  • Test all component usages throughout the application (run tests and manual QA)
  • Verify visual regressions from CSS token/spacing changes
  • Confirm internal components (_TimelineItem1, _IItem1) remain stable and exported in v3
  • Check for any prop renames or removed component APIs against the library's Storybook or GitHub repository
web/src/context/ThemeProvider.tsx (1)

10-22: LGTM! Dark mode implementation is correct.

The theme toggling logic and the useEffect that applies the dark class to document.documentElement correctly implements Tailwind's class-based dark mode strategy. The implementation will work seamlessly with Tailwind's dark: variant.

web/src/app.tsx (1)

4-4: LGTM! Theme provider migration is correctly implemented.

The migration from StyledComponentsProvider to the new ThemeProvider is clean and correct. The global.css import is properly placed early in the file, and the ThemeProvider correctly wraps the entire application as the outermost provider to ensure theme context is available throughout the component tree.

Also applies to: 7-7, 26-26, 59-59

Copy link
Contributor

@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 (2)
web/src/context/Web3Provider.tsx (1)

62-62: Consider adding the brand color to the theme system for maintainability.

The hardcoded color #4D00B4 is correct—it matches the primary brand color used throughout SVG assets. However, since the codebase has migrated to Tailwind with a theme system (defined in web/src/global.css), consider adding this color to the @theme block for consistency and easier maintenance:

/* In web/src/global.css @theme block */
--color-primary: #4D00B4;

Then reference it in Web3Provider:

"--w3m-color-mix": "var(--color-primary)",

This keeps brand colors centralized and easier to maintain across the codebase. The color itself doesn't need to change between light/dark modes—this is a brand constant, not a theme-dependent color.

web/src/layout/index.tsx (1)

22-22: Consider extracting the hardcoded spacing value.

The hardcoded pt-[70px] value appears to offset the ToastContainer from the header. For better maintainability and theme consistency, consider defining this as a CSS variable or Tailwind theme extension that matches the header height.

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between ad2c61b and d2d2579.

📒 Files selected for processing (3)
  • web/global.d.ts (1 hunks)
  • web/src/context/Web3Provider.tsx (1 hunks)
  • web/src/layout/index.tsx (1 hunks)
⏰ 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). (3)
  • GitHub Check: Redirect rules - curate-v2
  • GitHub Check: Header rules - curate-v2
  • GitHub Check: Pages changed - curate-v2
🔇 Additional comments (2)
web/src/layout/index.tsx (1)

23-23: Consider adding dark mode variant.

The background class bg-klerosUIComponentsLightBackground implies a light theme background. Based on the PR's ThemeProvider that toggles a document-level dark class, consider whether this element needs a corresponding dark mode variant (e.g., dark:bg-klerosUIComponentsDarkBackground).

web/global.d.ts (1)

1-12: LGTM!

The removal of styled-components module augmentation is appropriate for the Tailwind migration. The file correctly preserves the necessary ambient declarations for SVG and PNG imports while maintaining proper module structure with the export {} statement.

@kleros kleros deleted a comment from coderabbitai bot Oct 24, 2025
@kleros kleros deleted a comment from coderabbitai bot Oct 24, 2025
coderabbitai[bot]
coderabbitai bot previously approved these changes Oct 30, 2025
Copy link
Contributor

@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: 20

🧹 Nitpick comments (3)
web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/FormContact.tsx (1)

45-45: Consider using standard spacing scale instead of arbitrary value.

The arbitrary value mb-[10px] works correctly in Tailwind v4, but using the standard spacing scale improves consistency across the codebase. Since 10px equals 2.5rem (2.5 × 4px), consider using mb-2.5 instead.

-      <label className="flex justify-between mb-[10px]">{contactLabel}</label>
+      <label className="flex justify-between mb-2.5">{contactLabel}</label>
web/src/layout/Header/Logo.tsx (2)

8-13: Remove unnecessary whitespace literal.

The {" "} on line 9 serves no purpose and can be removed for cleaner code.

Apply this diff:

  <div className="flex flex-row items-center gap-4">
-    {" "}
    <Link to={"/"}>
      <CurateLogo className="transition duration-100 max-h-12 w-auto hover:fill-white/75" />
    </Link>
  </div>

10-12: Add accessible label for the logo link.

The logo link lacks descriptive text for screen readers. Add an aria-label to improve accessibility.

Apply this diff:

-    <Link to={"/"}>
+    <Link to={"/"} aria-label="Home">
      <CurateLogo className="transition duration-100 max-h-12 w-auto hover:fill-white/75" />
    </Link>
📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between f638cb8 and bb0901b.

📒 Files selected for processing (23)
  • web/src/app.tsx (3 hunks)
  • web/src/components/ConnectWallet/AccountDisplay.tsx (2 hunks)
  • web/src/components/InfoCard.tsx (1 hunks)
  • web/src/components/LightButton.tsx (1 hunks)
  • web/src/components/Overlay.tsx (1 hunks)
  • web/src/components/OverlayPortal.tsx (1 hunks)
  • web/src/context/ThemeProvider.tsx (1 hunks)
  • web/src/global.css (1 hunks)
  • web/src/layout/Header/DesktopHeader.tsx (1 hunks)
  • web/src/layout/Header/Logo.tsx (1 hunks)
  • web/src/layout/Header/index.tsx (1 hunks)
  • web/src/layout/Header/navbar/DappList.tsx (1 hunks)
  • web/src/layout/Header/navbar/Debug.tsx (2 hunks)
  • web/src/layout/Header/navbar/Explore.tsx (2 hunks)
  • web/src/layout/Header/navbar/Menu/Help.tsx (1 hunks)
  • web/src/layout/Header/navbar/Menu/Settings/General.tsx (1 hunks)
  • web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/EmailVerificationInfo.tsx (1 hunks)
  • web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/FormContact.tsx (1 hunks)
  • web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/index.tsx (3 hunks)
  • web/src/layout/Header/navbar/Menu/Settings/Notifications/index.tsx (1 hunks)
  • web/src/layout/Header/navbar/Menu/Settings/index.tsx (1 hunks)
  • web/src/layout/Header/navbar/Menu/index.tsx (1 hunks)
  • web/src/layout/Header/navbar/Product.tsx (1 hunks)
🚧 Files skipped from review as they are similar to previous changes (2)
  • web/src/context/ThemeProvider.tsx
  • web/src/app.tsx
🧰 Additional context used
🧠 Learnings (8)
📓 Common learnings
Learnt from: kyrers
Repo: kleros/curate-v2 PR: 89
File: web/src/layout/index.tsx:15-28
Timestamp: 2025-10-24T21:25:59.174Z
Learning: In Tailwind v4, when using CSS variables from external libraries like kleros/ui-components-library, add the `source` directive in global.css to tell Tailwind to scan and generate utility classes from those variables. Example: `source "../node_modules/kleros/ui-components-library";`
📚 Learning: 2024-11-04T13:31:54.080Z
Learnt from: Harman-singh-waraich
Repo: kleros/curate-v2 PR: 65
File: web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/index.tsx:72-96
Timestamp: 2024-11-04T13:31:54.080Z
Learning: In the React TypeScript component `FormContactDetails` in `web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/index.tsx`, error handling and user feedback are implemented within the `addUser` and `updateEmail` functions, which display toasts to the user.

Applied to files:

  • web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/FormContact.tsx
  • web/src/layout/Header/navbar/Menu/Settings/index.tsx
  • web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/EmailVerificationInfo.tsx
  • web/src/layout/Header/navbar/Menu/Settings/Notifications/index.tsx
  • web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/index.tsx
📚 Learning: 2024-11-04T13:41:31.226Z
Learnt from: Harman-singh-waraich
Repo: kleros/curate-v2 PR: 65
File: web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/index.tsx:126-126
Timestamp: 2024-11-04T13:41:31.226Z
Learning: In `web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/index.tsx`, the `isUndefined` function effectively handles `null` or `undefined` values. Therefore, using the non-null assertion `!` on `user?.emailUpdateableAt` when calling `timeLeftUntil(user?.emailUpdateableAt!)` is acceptable, as potential `null` or `undefined` cases are already managed.

Applied to files:

  • web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/FormContact.tsx
  • web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/EmailVerificationInfo.tsx
  • web/src/layout/Header/navbar/Menu/Settings/Notifications/index.tsx
  • web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/index.tsx
📚 Learning: 2024-11-04T13:33:39.755Z
Learnt from: Harman-singh-waraich
Repo: kleros/curate-v2 PR: 65
File: web/src/pages/Settings/index.tsx:18-26
Timestamp: 2024-11-04T13:33:39.755Z
Learning: In `web/src/pages/Settings/index.tsx`, the parent route handles the default `/settings` route, error boundaries, and loading states, so it's not necessary to include them in this component.

Applied to files:

  • web/src/layout/Header/navbar/Menu/Settings/index.tsx
  • web/src/layout/Header/navbar/Menu/Settings/Notifications/index.tsx
📚 Learning: 2024-11-04T13:39:19.748Z
Learnt from: Harman-singh-waraich
Repo: kleros/curate-v2 PR: 65
File: web/src/utils/atlas/updateEmail.ts:21-38
Timestamp: 2024-11-04T13:39:19.748Z
Learning: For the `updateEmail` function in `web/src/utils/atlas/updateEmail.ts`, input validation and error handling are performed in the component that utilizes it. Therefore, additional checks within this utility function are unnecessary.

Applied to files:

  • web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/EmailVerificationInfo.tsx
📚 Learning: 2024-11-04T13:34:45.425Z
Learnt from: Harman-singh-waraich
Repo: kleros/curate-v2 PR: 65
File: web/src/utils/atlas/confirmEmail.ts:24-36
Timestamp: 2024-11-04T13:34:45.425Z
Learning: In the `confirmEmail` function in `web/src/utils/atlas/confirmEmail.ts`, input validation for the address is performed in the calling component, and additional checks are done in the API call itself. Input validation does not need to be repeated in this function.

Applied to files:

  • web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/EmailVerificationInfo.tsx
📚 Learning: 2024-11-04T13:29:55.971Z
Learnt from: Harman-singh-waraich
Repo: kleros/curate-v2 PR: 65
File: web/src/context/AtlasProvider.tsx:176-193
Timestamp: 2024-11-04T13:29:55.971Z
Learning: In the `web/src/context/AtlasProvider.tsx` file of the React application, the `authoriseUser` function handles session invalidation and delegates error handling and user notifications to the functions that invoke it. Therefore, adding error notifications within `authoriseUser` is unnecessary.

Applied to files:

  • web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/EmailVerificationInfo.tsx
  • web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/index.tsx
📚 Learning: 2025-10-24T21:25:59.174Z
Learnt from: kyrers
Repo: kleros/curate-v2 PR: 89
File: web/src/layout/index.tsx:15-28
Timestamp: 2025-10-24T21:25:59.174Z
Learning: In Tailwind v4, when using CSS variables from external libraries like kleros/ui-components-library, add the `source` directive in global.css to tell Tailwind to scan and generate utility classes from those variables. Example: `source "../node_modules/kleros/ui-components-library";`

Applied to files:

  • web/src/global.css
🧬 Code graph analysis (5)
web/src/layout/Header/navbar/Debug.tsx (1)
web/src/consts/index.ts (2)
  • RELEASE_VERSION (12-12)
  • GIT_URL (11-11)
web/src/layout/Header/navbar/Menu/Settings/General.tsx (2)
web/src/components/EnsureChain.tsx (1)
  • EnsureChain (10-14)
web/src/components/ConnectWallet/AccountDisplay.tsx (3)
  • IdenticonOrAvatar (16-34)
  • AddressOrName (40-50)
  • ChainDisplay (52-56)
web/src/layout/Header/navbar/Menu/Settings/Notifications/index.tsx (2)
web/src/layout/Header/navbar/index.tsx (1)
  • ISettings (54-56)
web/src/components/EnsureChain.tsx (1)
  • EnsureChain (10-14)
web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/index.tsx (1)
web/src/utils/date.ts (1)
  • timeLeftUntil (43-69)
web/src/layout/Header/index.tsx (1)
web/src/utils/getGraphqlUrl.ts (1)
  • getGraphqlUrl (3-7)
🔇 Additional comments (12)
web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/FormContact.tsx (1)

45-52: Migration looks clean, but verify label-input association for accessibility.

The migration from styled-components to Tailwind classes is well-executed. However, the <label> on line 45 lacks a htmlFor attribute to associate it with the input field. If the Field component renders an input element, ensure proper label-input association for accessibility.

Consider adding a htmlFor attribute if the Field component exposes an id:

-      <label className="flex justify-between mb-[10px]">{contactLabel}</label>
+      <label htmlFor="contact-input" className="flex justify-between mb-[10px]">{contactLabel}</label>
       <Field
         className="flex flex-col items-center w-full"
+        id="contact-input"
         variant={fieldVariant}

Alternatively, if the Field component from @kleros/ui-components-library handles accessibility internally or doesn't support id props, you may disregard this suggestion.

web/src/layout/Header/navbar/DappList.tsx (1)

98-98: LGTM!

The h1 header uses standard Tailwind utility classes correctly.

web/src/layout/Header/navbar/Menu/Help.tsx (1)

52-53: The breakpoint is already properly configured—no action needed.

The custom landscape-900: breakpoint is correctly defined in web/src/global.css using Tailwind v4's @theme block with the --breakpoint-landscape-900: 900px; variable, which automatically creates the responsive modifier. The review comment incorrectly assumes traditional Tailwind configuration (JS/TS config file), which is not applicable to Tailwind v4's CSS-first approach. The code at lines 52-53 in Help.tsx correctly uses this pre-configured breakpoint.

Likely an incorrect or invalid review comment.

web/src/layout/Header/navbar/Debug.tsx (1)

5-20: LGTM!

The migration from styled-components to className-based styling is implemented correctly. The arbitrary font-family syntax font-[Roboto_Mono,monospace] is proper Tailwind v4 usage.

web/src/components/Overlay.tsx (1)

1-5: LGTM!

Clean conversion from styled-component to a functional component with Tailwind classes. The bg-black-low-opacity custom color should be defined in your theme configuration.

web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/EmailVerificationInfo.tsx (1)

36-49: LGTM!

Successful migration from styled-components to utility classes. The SVG fill and layout classes are properly applied.

web/src/global.css (2)

1-67: Well-structured Tailwind v4 integration.

The global stylesheet properly:

  • Imports the UI library theme and Tailwind v4 using the new @import syntax
  • Defines custom theme tokens via @theme directive
  • Implements accessible focus management with :focus-visible (addressing the previous review concern)

The focus styling (lines 60-67) now correctly preserves keyboard navigation accessibility while removing focus outlines for mouse users.


138-142: Verify browser support for CSS nesting.

The nested selector syntax ul { li { ... } } requires modern browsers. Based on your Tailwind v4 adoption (which targets Chrome 111+, Safari 16.4+, Firefox 128+), this should be supported, but confirm this aligns with your browser compatibility requirements.

web/src/layout/Header/index.tsx (1)

12-33: LGTM! Clean migration to Tailwind v4 syntax.

The header structure correctly uses Tailwind v4 features including advanced selector syntax for StatusBanner styling and CSS variables for theme integration. The sticky positioning and backdrop blur effects are properly configured.

web/src/layout/Header/navbar/Menu/Settings/General.tsx (1)

20-49: LGTM! Proper use of Tailwind v4 advanced features.

The component correctly uses Tailwind v4's advanced selector syntax ([&>label], [&_label]) and pseudo-element utilities (before:content-['']) to style nested elements. The layout structure is clean and maintains the original functionality.

web/src/layout/Header/DesktopHeader.tsx (1)

43-43: LGTM! Correct Tailwind v4 important modifier syntax.

The important modifier is correctly placed at the end of the utility class (fill-white!), which is the proper Tailwind v4 syntax.

web/src/layout/Header/navbar/Menu/Settings/Notifications/index.tsx (1)

18-30: LGTM!

The migration to Tailwind utilities is well-executed. The flexbox layout structure correctly preserves the component's intended design with proper centering and spacing.

Copy link
Contributor

@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: 5

♻️ Duplicate comments (1)
web/src/components/ConnectWallet/AccountDisplay.tsx (1)

78-80: Fix merged utility class separator.

The concatenated strings still miss a trailing space before landscape-900:hidden, so the output becomes before:ml-[3px]landscape-900:hidden and Tailwind drops both utilities. Add the separator (or switch to a template literal) so each class stays intact.

-          "before:content-[''] before:w-2 before:h-2 before:rounded-[50%] before:bg-klerosUIComponentsSuccess before:my-0 before:mr-[13px] before:ml-[3px]" +
+          "before:content-[''] before:w-2 before:h-2 before:rounded-[50%] before:bg-klerosUIComponentsSuccess before:my-0 before:mr-[13px] before:ml-[3px] " +
📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between bb0901b and 318211a.

📒 Files selected for processing (13)
  • web/src/components/ConnectWallet/AccountDisplay.tsx (2 hunks)
  • web/src/components/InfoCard.tsx (1 hunks)
  • web/src/components/LightButton.tsx (1 hunks)
  • web/src/global.css (1 hunks)
  • web/src/layout/Header/DesktopHeader.tsx (1 hunks)
  • web/src/layout/Header/Logo.tsx (1 hunks)
  • web/src/layout/Header/navbar/DappList.tsx (1 hunks)
  • web/src/layout/Header/navbar/Explore.tsx (2 hunks)
  • web/src/layout/Header/navbar/Menu/Help.tsx (1 hunks)
  • web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/index.tsx (3 hunks)
  • web/src/layout/Header/navbar/Menu/Settings/index.tsx (1 hunks)
  • web/src/layout/Header/navbar/Menu/index.tsx (1 hunks)
  • web/src/layout/Header/navbar/Product.tsx (1 hunks)
🚧 Files skipped from review as they are similar to previous changes (5)
  • web/src/components/InfoCard.tsx
  • web/src/layout/Header/navbar/Explore.tsx
  • web/src/layout/Header/Logo.tsx
  • web/src/components/LightButton.tsx
  • web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/index.tsx
🧰 Additional context used
🧠 Learnings (5)
📓 Common learnings
Learnt from: kyrers
Repo: kleros/curate-v2 PR: 89
File: web/src/layout/index.tsx:15-28
Timestamp: 2025-10-24T21:25:59.174Z
Learning: In Tailwind v4, when using CSS variables from external libraries like kleros/ui-components-library, add the `source` directive in global.css to tell Tailwind to scan and generate utility classes from those variables. Example: `source "../node_modules/kleros/ui-components-library";`
📚 Learning: 2025-10-24T21:25:59.174Z
Learnt from: kyrers
Repo: kleros/curate-v2 PR: 89
File: web/src/layout/index.tsx:15-28
Timestamp: 2025-10-24T21:25:59.174Z
Learning: In Tailwind v4, when using CSS variables from external libraries like kleros/ui-components-library, add the `source` directive in global.css to tell Tailwind to scan and generate utility classes from those variables. Example: `source "../node_modules/kleros/ui-components-library";`

Applied to files:

  • web/src/global.css
📚 Learning: 2024-11-04T13:33:39.755Z
Learnt from: Harman-singh-waraich
Repo: kleros/curate-v2 PR: 65
File: web/src/pages/Settings/index.tsx:18-26
Timestamp: 2024-11-04T13:33:39.755Z
Learning: In `web/src/pages/Settings/index.tsx`, the parent route handles the default `/settings` route, error boundaries, and loading states, so it's not necessary to include them in this component.

Applied to files:

  • web/src/layout/Header/navbar/Menu/Settings/index.tsx
📚 Learning: 2024-11-04T13:31:54.080Z
Learnt from: Harman-singh-waraich
Repo: kleros/curate-v2 PR: 65
File: web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/index.tsx:72-96
Timestamp: 2024-11-04T13:31:54.080Z
Learning: In the React TypeScript component `FormContactDetails` in `web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/index.tsx`, error handling and user feedback are implemented within the `addUser` and `updateEmail` functions, which display toasts to the user.

Applied to files:

  • web/src/layout/Header/navbar/Menu/Settings/index.tsx
📚 Learning: 2024-11-04T13:41:31.226Z
Learnt from: Harman-singh-waraich
Repo: kleros/curate-v2 PR: 65
File: web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/index.tsx:126-126
Timestamp: 2024-11-04T13:41:31.226Z
Learning: In `web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/index.tsx`, the `isUndefined` function effectively handles `null` or `undefined` values. Therefore, using the non-null assertion `!` on `user?.emailUpdateableAt` when calling `timeLeftUntil(user?.emailUpdateableAt!)` is acceptable, as potential `null` or `undefined` cases are already managed.

Applied to files:

  • web/src/layout/Header/navbar/Menu/Settings/index.tsx
⏰ 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). (3)
  • GitHub Check: Redirect rules - curate-v2
  • GitHub Check: Header rules - curate-v2
  • GitHub Check: Pages changed - curate-v2
🔇 Additional comments (2)
web/src/layout/Header/navbar/Menu/Help.tsx (1)

48-69: LGTM! Previous issues resolved.

The Tailwind utility classes are now correct, and the className concatenation includes proper spacing.

web/src/layout/Header/navbar/Menu/Settings/index.tsx (1)

39-39: Previous issues resolved.

The invalid width-[calc(...)] utility has been corrected to w-[calc(...)].

Copy link
Contributor

@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: 4

🧹 Nitpick comments (1)
web/src/layout/Header/navbar/Product.tsx (1)

39-39: Consider removing unnecessary flex class.

The <small> element contains only text and uses text-center for alignment. The flex class appears unnecessary since text-center alone handles text alignment for inline content.

-      <small className="flex font-normal text-center leading-[19px]">{text}</small>
+      <small className="font-normal text-center leading-[19px]">{text}</small>
📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 318211a and dba15bb.

📒 Files selected for processing (7)
  • web/src/components/LightButton.tsx (1 hunks)
  • web/src/layout/Header/navbar/DappList.tsx (1 hunks)
  • web/src/layout/Header/navbar/Explore.tsx (2 hunks)
  • web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/index.tsx (3 hunks)
  • web/src/layout/Header/navbar/Menu/Settings/index.tsx (1 hunks)
  • web/src/layout/Header/navbar/Menu/index.tsx (1 hunks)
  • web/src/layout/Header/navbar/Product.tsx (1 hunks)
🚧 Files skipped from review as they are similar to previous changes (3)
  • web/src/layout/Header/navbar/DappList.tsx
  • web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/index.tsx
  • web/src/components/LightButton.tsx
🧰 Additional context used
🧠 Learnings (4)
📓 Common learnings
Learnt from: kyrers
Repo: kleros/curate-v2 PR: 89
File: web/src/layout/index.tsx:15-28
Timestamp: 2025-10-24T21:25:59.174Z
Learning: In Tailwind v4, when using CSS variables from external libraries like kleros/ui-components-library, add the `source` directive in global.css to tell Tailwind to scan and generate utility classes from those variables. Example: `source "../node_modules/kleros/ui-components-library";`
📚 Learning: 2024-11-04T13:33:39.755Z
Learnt from: Harman-singh-waraich
Repo: kleros/curate-v2 PR: 65
File: web/src/pages/Settings/index.tsx:18-26
Timestamp: 2024-11-04T13:33:39.755Z
Learning: In `web/src/pages/Settings/index.tsx`, the parent route handles the default `/settings` route, error boundaries, and loading states, so it's not necessary to include them in this component.

Applied to files:

  • web/src/layout/Header/navbar/Menu/Settings/index.tsx
📚 Learning: 2024-11-04T13:31:54.080Z
Learnt from: Harman-singh-waraich
Repo: kleros/curate-v2 PR: 65
File: web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/index.tsx:72-96
Timestamp: 2024-11-04T13:31:54.080Z
Learning: In the React TypeScript component `FormContactDetails` in `web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/index.tsx`, error handling and user feedback are implemented within the `addUser` and `updateEmail` functions, which display toasts to the user.

Applied to files:

  • web/src/layout/Header/navbar/Menu/Settings/index.tsx
📚 Learning: 2024-11-04T13:41:31.226Z
Learnt from: Harman-singh-waraich
Repo: kleros/curate-v2 PR: 65
File: web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/index.tsx:126-126
Timestamp: 2024-11-04T13:41:31.226Z
Learning: In `web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/index.tsx`, the `isUndefined` function effectively handles `null` or `undefined` values. Therefore, using the non-null assertion `!` on `user?.emailUpdateableAt` when calling `timeLeftUntil(user?.emailUpdateableAt!)` is acceptable, as potential `null` or `undefined` cases are already managed.

Applied to files:

  • web/src/layout/Header/navbar/Menu/Settings/index.tsx
⏰ 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). (3)
  • GitHub Check: Redirect rules - curate-v2
  • GitHub Check: Header rules - curate-v2
  • GitHub Check: Pages changed - curate-v2
🔇 Additional comments (4)
web/src/layout/Header/navbar/Explore.tsx (2)

17-18: LGTM! Clean active route detection.

The isActive helper correctly handles both the root path (exact match) and nested routes (first segment comparison), which prevents false positives in navigation highlighting.


36-49: Custom utilities are properly configured—no changes required, but consider adding @source directive.

The className structure is correct and all custom utilities are properly defined in your Tailwind v4 setup:

  • text-klerosUIComponentsPrimaryText, text-primary-text-73, text-white-73 are configured via CSS variables in the @theme block
  • landscape-900: breakpoint is defined as --breakpoint-landscape-900: 900px
  • All utilities are actively used and functional throughout the codebase

Based on the learning context, consider adding the @source directive in web/src/global.css to explicitly tell Tailwind to scan the @kleros/ui-components-library for utility classes:

@source "../node_modules/@kleros/ui-components-library";
@import "@kleros/ui-components-library/theme.css";
@import "tailwindcss";

This ensures Tailwind can generate utilities from CSS variables in the external library, though the current setup appears to be working without it.

web/src/layout/Header/navbar/Product.tsx (1)

16-25: Previous critical issues successfully resolved!

All three issues from the previous review have been properly addressed:

  1. ✅ Security: rel="noopener noreferrer" added
  2. ✅ Styling: className construction fixed and dynamic width moved to style prop
  3. ✅ This segment demonstrates proper Tailwind v4 migration pattern
web/src/layout/Header/navbar/Menu/index.tsx (1)

37-37: Clean responsive layout structure.

The flex layout with responsive breakpoint is well-structured for converting the menu from vertical to horizontal orientation.

coderabbitai[bot]
coderabbitai bot previously approved these changes Oct 31, 2025
Copy link
Contributor

@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: 2

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
web/src/layout/Header/navbar/index.tsx (1)

2-2: Remove unused styled-components import.

The styled import is no longer used after migrating to Tailwind utility classes.

Apply this diff to remove the unused import:

-import styled from "styled-components";
📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between dba15bb and f3b7df3.

📒 Files selected for processing (3)
  • web/src/layout/Header/MobileHeader.tsx (1 hunks)
  • web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/FormContact.tsx (2 hunks)
  • web/src/layout/Header/navbar/index.tsx (2 hunks)
🚧 Files skipped from review as they are similar to previous changes (1)
  • web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/FormContact.tsx
🧰 Additional context used
🧠 Learnings (1)
📓 Common learnings
Learnt from: kyrers
Repo: kleros/curate-v2 PR: 89
File: web/src/layout/index.tsx:15-28
Timestamp: 2025-10-24T21:25:59.174Z
Learning: In Tailwind v4, when using CSS variables from external libraries like kleros/ui-components-library, add the `source` directive in global.css to tell Tailwind to scan and generate utility classes from those variables. Example: `source "../node_modules/kleros/ui-components-library";`
🧬 Code graph analysis (1)
web/src/layout/Header/navbar/index.tsx (1)
web/src/layout/Header/navbar/Menu/Settings/General.tsx (1)
  • DisconnectWalletButton (7-10)
⏰ 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). (3)
  • GitHub Check: Redirect rules - curate-v2
  • GitHub Check: Header rules - curate-v2
  • GitHub Check: Pages changed - curate-v2
🔇 Additional comments (2)
web/src/layout/Header/navbar/index.tsx (1)

59-66: LGTM! Wallet container refactoring is correct.

The replacement of styled components with Tailwind flex utilities is appropriate, and the wrapper div for vertical alignment maintains the intended layout.

web/src/layout/Header/MobileHeader.tsx (1)

29-29: Custom breakpoint is properly configured.

The landscape-900 breakpoint is defined as a CSS variable in web/src/global.css (line 21: --breakpoint-landscape-900: 900px;) and is successfully used across the codebase in multiple files (DesktopHeader, DappList, Explore, Menu, Settings, LightButton, AccountDisplay). The consistent usage throughout the project confirms proper Tailwind integration.

However, the icon-only button on line 33 lacks accessibility attributes — add aria-label or title to the LightButton since text="":

<LightButton className="p-0 [&_.button-svg]:mr-0" text="" Icon={HamburgerIcon} onClick={toggleIsOpen} aria-label="Toggle menu" />

coderabbitai[bot]
coderabbitai bot previously approved these changes Oct 31, 2025
Copy link
Contributor

@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

♻️ Duplicate comments (1)
web/package.json (1)

51-51: @tailwindcss/vite is correctly placed in devDependencies.

The past review comment requesting this move has been addressed. The @tailwindcss/vite plugin is properly positioned as a build-time dependency.

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between bf5b6d0 and 5a6d51a.

⛔ Files ignored due to path filters (1)
  • yarn.lock is excluded by !**/yarn.lock, !**/*.lock
📒 Files selected for processing (1)
  • web/package.json (4 hunks)
🧰 Additional context used
🧠 Learnings (1)
📓 Common learnings
Learnt from: kyrers
Repo: kleros/curate-v2 PR: 89
File: web/src/layout/index.tsx:15-28
Timestamp: 2025-10-24T21:25:59.174Z
Learning: In Tailwind v4, when using CSS variables from external libraries like kleros/ui-components-library, add the `source` directive in global.css to tell Tailwind to scan and generate utility classes from those variables. Example: `source "../node_modules/kleros/ui-components-library";`
⏰ 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). (3)
  • GitHub Check: Redirect rules - curate-v2
  • GitHub Check: Header rules - curate-v2
  • GitHub Check: Pages changed - curate-v2
🔇 Additional comments (2)
web/package.json (2)

73-73: @kleros/ui-components-library v3 upgrade is correctly aligned with PR objectives.

The upgrade from ^2.20.0 to ^3.6.0 fulfills the requirement to migrate to the Tailwind-based v3 of the UI component library and ensures component styling consistency with the new Tailwind-first approach.


84-84: Runtime utilities clsx and tailwind-merge are correctly placed in dependencies.

Both clsx (for conditional class names) and tailwind-merge (for the cn utility to resolve Tailwind class conflicts at runtime) are used in client-side code and belong in dependencies.

Also applies to: 106-107

coderabbitai[bot]
coderabbitai bot previously approved these changes Nov 5, 2025
Copy link
Contributor

@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: 2

♻️ Duplicate comments (4)
web/src/layout/Header/navbar/Menu/Settings/index.tsx (1)

31-38: Invalid z-index utility still present.

Line 34 uses z-1 which is not in Tailwind's default z-index scale (z-0, z-10, z-20, z-30, z-40, z-50, z-auto). Use z-[1] for an arbitrary z-index value of 1, or choose a standard value like z-10.

Apply this diff:

       className={clsx(
-        "flex flex-col absolute max-h-[80vh] overflow-y-auto top-[5%] left-1/2 transform -translate-x-1/2 z-1",
+        "flex flex-col absolute max-h-[80vh] overflow-y-auto top-[5%] left-1/2 transform -translate-x-1/2 z-[1]",
         "bg-klerosUIComponentsWhiteBackground border border-solid border-klerosUIComponentsStroke rounded-[3px]",
web/src/layout/Header/navbar/Menu/Help.tsx (1)

59-64: Add security attributes for external links.

Using target="_blank" without rel="noopener noreferrer" creates a security vulnerability. The opened page can access the window.opener object and potentially redirect the original page.

Apply this diff:

           <a
             href={item.url}
             key={item.text}
             target="_blank"
+            rel="noopener noreferrer"
             className="flex gap-2 py-3 px-2 cursor-pointer transition-transform duration-200 hover:scale-[1.02]"
           >
web/src/layout/Header/navbar/DappList.tsx (1)

90-100: Add ARIA attributes for modal accessibility.

This popup container lacks proper accessibility attributes for screen readers and assistive technologies. Without role="dialog", aria-modal="true", and aria-labelledby, users with disabilities cannot properly navigate or understand this modal overlay.

Apply this diff to add the required ARIA attributes:

     <div
       ref={containerRef}
+      role="dialog"
+      aria-modal="true"
+      aria-labelledby="dapp-list-heading"
       className={clsx(

Also add an id to the h1 on line 101:

-      <h1 className="pt-6 text-2xl font-semibold leading-8">Kleros Solutions</h1>
+      <h1 id="dapp-list-heading" className="pt-6 text-2xl font-semibold leading-8">Kleros Solutions</h1>
web/src/layout/Header/navbar/Product.tsx (1)

21-25: Transition should be in base state, not hover state.

This issue was flagged in a previous review but remains unaddressed. The hover: prefix on line 24 means the transition property is only defined during hover, causing asymmetric animation: smooth on hover-enter but instant snap-back on hover-exit.

Apply this diff to move the transition to the base state:

       className={clsx(
         "flex flex-col items-center pt-4 pb-7 px-2 max-w-[100px] rounded-[3px] gap-2",
         "cursor-pointer bg-klerosUIComponentsLightBackground hover:bg-klerosUIComponentsLightGrey",
-        "hover:transition-[transform_0.15s,background-color_0.3s] hover:scale-[1.02]"
+        "transition-[transform_0.15s,background-color_0.3s] hover:scale-[1.02]"
       )}
🧹 Nitpick comments (4)
web/src/components/InfoCard.tsx (1)

13-22: Excellent fix! Migration implemented correctly.

The previous critical issue with dynamic gap value has been properly resolved by using inline styles. The implementation now follows Tailwind best practices:

  • cn() correctly merges static utilities with the optional className prop
  • Dynamic responsiveSize() value correctly applied via inline style
  • Grid layout with arbitrary column template grid-cols-[16px_auto] is valid syntax
  • Custom color class text-klerosUIComponentsSecondaryText should work correctly with the source directive configuration

Minor note: The text-start utility is redundant for this simple grid layout but harmless.

If desired, you can simplify by removing text-start:

       className={cn(
-        "grid grid-cols-[16px_auto] items-center justify-start text-start text-klerosUIComponentsSecondaryText",
+        "grid grid-cols-[16px_auto] items-center justify-start text-klerosUIComponentsSecondaryText",
         className
       )}
web/src/layout/Header/navbar/Menu/index.tsx (1)

40-50: Use stable identifier for key prop.

Line 41 uses key={Icon} where Icon is a React component reference. Component references are not stable unique identifiers and can cause reconciliation issues.

Apply this diff to use the text prop as a stable key:

       {buttons.map(({ text, Icon, onClick }) => (
         <div
-          key={Icon}
+          key={text}
           className={clsx(
web/src/layout/Header/navbar/Product.tsx (1)

1-1: Consider using the centralized cn() utility for consistency.

The PR introduces a cn() utility (tailwind-merge + clsx) for className composition. Consider using it instead of clsx directly for automatic Tailwind class conflict resolution and codebase consistency.

Apply this diff if the cn utility is available in utils/index.ts:

-import clsx from "clsx";
+import { cn } from "utils";

Then update line 21:

-      className={clsx(
+      className={cn(
web/src/components/ConnectWallet/AccountDisplay.tsx (1)

64-64: Consider removing redundant lg:content-center utility.

The content-center utility (align-content: center) only affects multi-line flex containers when flex-wrap is enabled. Since this container has no wrapping and items-center already handles cross-axis alignment, lg:content-center has no effect and can be removed for clarity.

-    "lg:flex-row lg:content-center lg:rounded-[300px] lg:gap-0 lg:py-0 lg:px-3",
+    "lg:flex-row lg:rounded-[300px] lg:gap-0 lg:py-0 lg:px-3",
📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 52538dc and 7512ebc.

📒 Files selected for processing (10)
  • web/src/components/ConnectWallet/AccountDisplay.tsx (3 hunks)
  • web/src/components/InfoCard.tsx (2 hunks)
  • web/src/components/LightButton.tsx (2 hunks)
  • web/src/layout/Header/navbar/DappList.tsx (2 hunks)
  • web/src/layout/Header/navbar/Explore.tsx (3 hunks)
  • web/src/layout/Header/navbar/Menu/Help.tsx (2 hunks)
  • web/src/layout/Header/navbar/Menu/Settings/index.tsx (2 hunks)
  • web/src/layout/Header/navbar/Menu/index.tsx (2 hunks)
  • web/src/layout/Header/navbar/Product.tsx (2 hunks)
  • web/src/layout/Header/navbar/index.tsx (3 hunks)
🚧 Files skipped from review as they are similar to previous changes (2)
  • web/src/layout/Header/navbar/index.tsx
  • web/src/components/LightButton.tsx
🧰 Additional context used
🧠 Learnings (7)
📓 Common learnings
Learnt from: kyrers
Repo: kleros/curate-v2 PR: 89
File: web/src/layout/index.tsx:15-28
Timestamp: 2025-10-24T21:25:59.174Z
Learning: In Tailwind v4, when using CSS variables from external libraries like kleros/ui-components-library, add the `source` directive in global.css to tell Tailwind to scan and generate utility classes from those variables. Example: `source "../node_modules/kleros/ui-components-library";`
📚 Learning: 2025-10-24T21:25:59.174Z
Learnt from: kyrers
Repo: kleros/curate-v2 PR: 89
File: web/src/layout/index.tsx:15-28
Timestamp: 2025-10-24T21:25:59.174Z
Learning: In Tailwind v4, when using CSS variables from external libraries like kleros/ui-components-library, add the `source` directive in global.css to tell Tailwind to scan and generate utility classes from those variables. Example: `source "../node_modules/kleros/ui-components-library";`

Applied to files:

  • web/src/layout/Header/navbar/Menu/index.tsx
  • web/src/layout/Header/navbar/Menu/Settings/index.tsx
📚 Learning: 2025-10-31T19:54:12.499Z
Learnt from: kyrers
Repo: kleros/curate-v2 PR: 89
File: web/src/layout/Header/DesktopHeader.tsx:43-44
Timestamp: 2025-10-31T19:54:12.499Z
Learning: In Tailwind CSS v4, the important modifier uses a trailing `!` after the utility class (e.g., `fill-white!`), unlike v3 which used a leading `!` prefix (e.g., `!fill-white`). This applies to all utilities including arbitrary values and after variants (e.g., `sm:hover:bg-green-500!`).

Applied to files:

  • web/src/layout/Header/navbar/Menu/index.tsx
  • web/src/components/InfoCard.tsx
  • web/src/layout/Header/navbar/DappList.tsx
📚 Learning: 2024-11-04T13:33:39.755Z
Learnt from: Harman-singh-waraich
Repo: kleros/curate-v2 PR: 65
File: web/src/pages/Settings/index.tsx:18-26
Timestamp: 2024-11-04T13:33:39.755Z
Learning: In `web/src/pages/Settings/index.tsx`, the parent route handles the default `/settings` route, error boundaries, and loading states, so it's not necessary to include them in this component.

Applied to files:

  • web/src/layout/Header/navbar/Menu/Settings/index.tsx
📚 Learning: 2024-11-04T13:31:54.080Z
Learnt from: Harman-singh-waraich
Repo: kleros/curate-v2 PR: 65
File: web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/index.tsx:72-96
Timestamp: 2024-11-04T13:31:54.080Z
Learning: In the React TypeScript component `FormContactDetails` in `web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/index.tsx`, error handling and user feedback are implemented within the `addUser` and `updateEmail` functions, which display toasts to the user.

Applied to files:

  • web/src/layout/Header/navbar/Menu/Settings/index.tsx
📚 Learning: 2024-11-04T13:41:31.226Z
Learnt from: Harman-singh-waraich
Repo: kleros/curate-v2 PR: 65
File: web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/index.tsx:126-126
Timestamp: 2024-11-04T13:41:31.226Z
Learning: In `web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/index.tsx`, the `isUndefined` function effectively handles `null` or `undefined` values. Therefore, using the non-null assertion `!` on `user?.emailUpdateableAt` when calling `timeLeftUntil(user?.emailUpdateableAt!)` is acceptable, as potential `null` or `undefined` cases are already managed.

Applied to files:

  • web/src/layout/Header/navbar/Menu/Settings/index.tsx
📚 Learning: 2025-10-31T20:37:01.310Z
Learnt from: kyrers
Repo: kleros/curate-v2 PR: 89
File: web/src/components/OverlayPortal.tsx:5-8
Timestamp: 2025-10-31T20:37:01.310Z
Learning: In Tailwind CSS v4, the `z-<number>` syntax directly sets `z-index: <number>;` for any numeric value (e.g., `z-9999` results in `z-index: 9999;`). Arbitrary value brackets `z-[<value>]` are not required for numeric z-index values in v4.
```
<!-- [remove_learning]
dcbe3a95-44f6-47d5-806e-64b74d549e4b

Applied to files:

  • web/src/layout/Header/navbar/Menu/Settings/index.tsx
🧬 Code graph analysis (2)
web/src/layout/Header/navbar/Explore.tsx (1)
web/src/utils/index.ts (1)
  • cn (44-46)
web/src/components/InfoCard.tsx (1)
web/src/utils/index.ts (1)
  • cn (44-46)
⏰ 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). (3)
  • GitHub Check: Redirect rules - curate-v2
  • GitHub Check: Header rules - curate-v2
  • GitHub Check: Pages changed - curate-v2
🔇 Additional comments (14)
web/src/components/InfoCard.tsx (2)

1-4: LGTM! Clean import migration.

The removal of styled-components and addition of the cn utility correctly supports the Tailwind migration.


6-11: LGTM! Proper prop interface extension.

Adding the optional className prop enables flexible style composition, which is the recommended pattern for Tailwind components.

web/src/layout/Header/navbar/Explore.tsx (3)

17-18: LGTM: Active route detection logic is correct.

The function properly handles the home route with an exact match and uses segment comparison for other routes, which correctly identifies active navigation states.


32-34: LGTM: Responsive layout structure is well-implemented.

The flex direction changes appropriately between mobile and desktop, and the title visibility is correctly scoped to mobile viewports.


38-44: All concerns verified—code changes are correct.

The breakpoint change from landscape-900: to lg: is intentional and complete. The custom breakpoint has been entirely removed from the codebase; all remaining orientation-based styling uses the landscapeStyle helper function in styled-components instead. The standard lg: breakpoint (1024px+) is the appropriate choice for this Tailwind component.

All custom color utilities (text-klerosUIComponentsPrimaryText, text-primary-text-73, text-white-73) are properly configured via CSS variables defined in web/src/global.css. The @source and @theme directives in the Tailwind configuration correctly enable these utilities to be generated automatically.

web/src/layout/Header/navbar/Menu/Help.tsx (1)

49-57: Invalid z-index utility.

Line 52 uses z-1, which is not a valid Tailwind utility. The default z-index scale in Tailwind uses values like z-0, z-10, z-20, etc. For a z-index of 1, use the arbitrary value syntax.

Apply this diff:

         className={clsx(
-          "flex flex-col absolute max-h-[80vh] overflow-y-auto w-[86vw] max-w-[444px] top-[5%] left-1/2 transform -translate-x-1/2 z-1 p-3 pb-6",
+          "flex flex-col absolute max-h-[80vh] overflow-y-auto w-[86vw] max-w-[444px] top-[5%] left-1/2 transform -translate-x-1/2 z-[1] p-3 pb-6",
           "border border-klerosUIComponentsStroke rounded-[3px]",
           "bg-klerosUIComponentsWhiteBackground shadow-[0px_2px_3px_rgba(0,0,0,0.06)]",
           "lg:mt-16 lg:top-0 lg:right-0 lg:left-auto lg:transform-none lg:max-w-[260px]"
         )}
⛔ Skipped due to learnings
Learnt from: kyrers
Repo: kleros/curate-v2 PR: 89
File: web/src/components/OverlayPortal.tsx:5-8
Timestamp: 2025-10-31T20:37:01.310Z
Learning: In Tailwind CSS v4, the `z-<number>` syntax directly sets `z-index: <number>;` for any numeric value (e.g., `z-9999` results in `z-index: 9999;`). Arbitrary value brackets `z-[<value>]` are not required for numeric z-index values in v4.
```
<!-- [remove_learning]
dcbe3a95-44f6-47d5-806e-64b74d549e4b
web/src/layout/Header/navbar/DappList.tsx (2)

102-105: Grid layout implementation looks good.

The grid container correctly uses inline styles for dynamic values from responsiveSize(), which is the right approach for Tailwind's JIT compiler. The padding template literal properly uses spaces, and the grid utilities are appropriate for the responsive layout.


94-95: No issues found. CSS variable utilities are properly configured.

The @source directive is correctly configured in web/src/global.css (line 2) to scan the kleros/ui-components-library for CSS variables. The utilities border-klerosUIComponentsStroke and bg-klerosUIComponentsWhiteBackground at lines 94-95 will work as intended.

web/src/layout/Header/navbar/Product.tsx (2)

26-26: Code is correct as-is; no changes needed.

The responsiveSize() function returns a template string containing a calc() expression with proper CSS units. React's style prop accepts string values with units, making this implementation fully compatible.


22-23: No issues found — @source directive is correctly configured.

The custom color utilities bg-klerosUIComponentsLightBackground and bg-klerosUIComponentsLightGrey at lines 22-23 are properly supported. The required @source directive is correctly configured in web/src/global.css:2, pointing to the @kleros/ui-components-library. These utilities are actively used throughout the codebase without errors.

web/src/components/ConnectWallet/AccountDisplay.tsx (4)

62-68: Verify responsive behavior with standard lg: breakpoint.

The code now uses the standard Tailwind lg: breakpoint (1024px) instead of the custom landscape-900: breakpoint referenced in previous reviews. Ensure this change doesn't negatively impact the responsive layout, especially if landscape-900: had specific viewport dimensions that differ from the standard 1024px breakpoint.


61-89: Well-executed migration to Tailwind and clsx.

The migration from styled-components to Tailwind utility classes is clean and well-organized. The use of clsx for className composition is appropriate, and the previous critical issues with className concatenation and invalid utilities have been properly addressed. The class organization by responsive breakpoints and pseudo-selectors enhances readability.


82-83: Color configuration verified and properly defined.

The klerosUIComponentsSuccess color is properly configured through the imported theme from the @kleros/ui-components-library package (declared at the top of web/src/global.css). The color is consistently used across the codebase and no configuration issues exist.


65-66: The custom theme colors are already properly configured.

The review comment asks to verify and add the @source directive, but the @source directive is already present in global.css. Additionally, the theme is imported from @kleros/ui-components-library, and the colors white-low-opacity-subtle and white-low-opacity-strong are defined in the @theme block. The bg-klerosUIComponentsWhiteBackground utility is sourced from the imported library. The configuration is complete and correct.

Likely an incorrect or invalid review comment.

Copy link
Contributor

@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

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 7512ebc and df464f8.

📒 Files selected for processing (1)
  • web/src/layout/Header/navbar/Menu/Help.tsx (2 hunks)
🧰 Additional context used
🧠 Learnings (1)
📓 Common learnings
Learnt from: kyrers
Repo: kleros/curate-v2 PR: 89
File: web/src/layout/index.tsx:15-28
Timestamp: 2025-10-24T21:25:59.174Z
Learning: In Tailwind v4, when using CSS variables from external libraries like kleros/ui-components-library, add the `source` directive in global.css to tell Tailwind to scan and generate utility classes from those variables. Example: `source "../node_modules/kleros/ui-components-library";`
⏰ 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). (3)
  • GitHub Check: Redirect rules - curate-v2
  • GitHub Check: Header rules - curate-v2
  • GitHub Check: Pages changed - curate-v2
🔇 Additional comments (3)
web/src/layout/Header/navbar/Menu/Help.tsx (3)

1-13: LGTM!

The imports are clean and appropriate for the Tailwind migration. The addition of clsx for class composition is the correct approach.


52-52: Fix invalid z-index utility.

z-1 is not a valid Tailwind utility. Standard Tailwind z-index utilities are z-0, z-10, z-20, etc. Use either a standard utility or an arbitrary value.

Apply this diff:

-          "flex flex-col absolute max-h-[80vh] overflow-y-auto w-[86vw] max-w-[444px] top-[5%] left-1/2 transform -translate-x-1/2 z-1 p-3 pb-6",
+          "flex flex-col absolute max-h-[80vh] overflow-y-auto w-[86vw] max-w-[444px] top-[5%] left-1/2 transform -translate-x-1/2 z-10 p-3 pb-6",

Alternatively, if you specifically need z-index of 1:

-          "flex flex-col absolute max-h-[80vh] overflow-y-auto w-[86vw] max-w-[444px] top-[5%] left-1/2 transform -translate-x-1/2 z-1 p-3 pb-6",
+          "flex flex-col absolute max-h-[80vh] overflow-y-auto w-[86vw] max-w-[444px] top-[5%] left-1/2 transform -translate-x-1/2 z-[1] p-3 pb-6",
⛔ Skipped due to learnings
Learnt from: kyrers
Repo: kleros/curate-v2 PR: 89
File: web/src/components/OverlayPortal.tsx:5-8
Timestamp: 2025-10-31T20:37:01.310Z
Learning: In Tailwind CSS v4, the `z-<number>` syntax directly sets `z-index: <number>;` for any numeric value (e.g., `z-9999` results in `z-index: 9999;`). Arbitrary value brackets `z-[<value>]` are not required for numeric z-index values in v4.
```
<!-- [remove_learning]
dcbe3a95-44f6-47d5-806e-64b74d549e4b
Learnt from: kyrers
Repo: kleros/curate-v2 PR: 89
File: web/src/layout/Header/DesktopHeader.tsx:43-44
Timestamp: 2025-10-31T19:54:12.499Z
Learning: In Tailwind CSS v4, the important modifier uses a trailing `!` after the utility class (e.g., `fill-white!`), unlike v3 which used a leading `!` prefix (e.g., `!fill-white`). This applies to all utilities including arbitrary values and after variants (e.g., `sm:hover:bg-green-500!`).

55-55: Responsive breakpoint migration verified—no issues found.

The codebase shows a complete and intentional migration from custom landscape- breakpoints to standard Tailwind lg: breakpoints (1024px). No remaining landscape- prefixed breakpoints were found, confirming the change has been consistently applied throughout the project.

coderabbitai[bot]
coderabbitai bot previously approved these changes Nov 6, 2025
Copy link
Contributor

@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

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 41dd11c and 2ec1c2f.

📒 Files selected for processing (5)
  • web/src/global.css (1 hunks)
  • web/src/layout/Header/DesktopHeader.tsx (1 hunks)
  • web/src/layout/Header/Logo.tsx (1 hunks)
  • web/src/layout/Header/index.tsx (1 hunks)
  • web/src/layout/Header/navbar/Menu/index.tsx (1 hunks)
🚧 Files skipped from review as they are similar to previous changes (1)
  • web/src/layout/Header/navbar/Menu/index.tsx
🧰 Additional context used
🧠 Learnings (4)
📓 Common learnings
Learnt from: kyrers
Repo: kleros/curate-v2 PR: 89
File: web/src/layout/index.tsx:15-28
Timestamp: 2025-10-24T21:25:59.174Z
Learning: In Tailwind v4, when using CSS variables from external libraries like kleros/ui-components-library, add the `source` directive in global.css to tell Tailwind to scan and generate utility classes from those variables. Example: `source "../node_modules/kleros/ui-components-library";`
📚 Learning: 2025-10-31T19:54:12.499Z
Learnt from: kyrers
Repo: kleros/curate-v2 PR: 89
File: web/src/layout/Header/DesktopHeader.tsx:43-44
Timestamp: 2025-10-31T19:54:12.499Z
Learning: In Tailwind CSS v4, the important modifier uses a trailing `!` after the utility class (e.g., `fill-white!`), unlike v3 which used a leading `!` prefix (e.g., `!fill-white`). This applies to all utilities including arbitrary values and after variants (e.g., `sm:hover:bg-green-500!`).

Applied to files:

  • web/src/layout/Header/Logo.tsx
  • web/src/layout/Header/DesktopHeader.tsx
  • web/src/global.css
📚 Learning: 2025-10-24T21:25:59.174Z
Learnt from: kyrers
Repo: kleros/curate-v2 PR: 89
File: web/src/layout/index.tsx:15-28
Timestamp: 2025-10-24T21:25:59.174Z
Learning: In Tailwind v4, when using CSS variables from external libraries like kleros/ui-components-library, add the `source` directive in global.css to tell Tailwind to scan and generate utility classes from those variables. Example: `source "../node_modules/kleros/ui-components-library";`

Applied to files:

  • web/src/layout/Header/DesktopHeader.tsx
  • web/src/global.css
📚 Learning: 2025-10-31T20:37:01.310Z
Learnt from: kyrers
Repo: kleros/curate-v2 PR: 89
File: web/src/components/OverlayPortal.tsx:5-8
Timestamp: 2025-10-31T20:37:01.310Z
Learning: In Tailwind CSS v4, the `z-<number>` syntax directly sets `z-index: <number>;` for any numeric value (e.g., `z-9999` results in `z-index: 9999;`). Arbitrary value brackets `z-[<value>]` are not required for numeric z-index values in v4.
```
<!-- [remove_learning]
dcbe3a95-44f6-47d5-806e-64b74d549e4b

Applied to files:

  • web/src/layout/Header/DesktopHeader.tsx
🧬 Code graph analysis (1)
web/src/layout/Header/index.tsx (1)
web/src/utils/getGraphqlUrl.ts (1)
  • getGraphqlUrl (3-7)
🪛 Biome (2.1.2)
web/src/global.css

[error] 3-3: expected , but instead found (

Remove (

(parse)


[error] 3-3: This @import is in the wrong position.

Any @import rules must precede all other valid at-rules and style rules in a stylesheet (ignoring @charset and @layer), or else the @import rule is invalid.
Consider moving import position.

(lint/correctness/noInvalidPositionAtImportRule)

⏰ 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). (3)
  • GitHub Check: Redirect rules - curate-v2
  • GitHub Check: Header rules - curate-v2
  • GitHub Check: Pages changed - curate-v2
🔇 Additional comments (3)
web/src/layout/Header/Logo.tsx (1)

8-13: LGTM! Clean migration to Tailwind.

The component structure is straightforward and the hover effect using hover:[&_path]:fill-white/75 correctly targets SVG path elements with Tailwind's arbitrary variant syntax.

web/src/layout/Header/index.tsx (1)

12-33: LGTM! Well-structured header with proper Tailwind v4 syntax.

The migration effectively uses Tailwind utilities including:

  • Correct important modifier syntax (sticky!)
  • Arbitrary variants for nested element targeting
  • CSS variables for theme integration
  • Responsive dark mode variants
web/src/layout/Header/DesktopHeader.tsx (1)

35-62: LGTM! Effective migration to utility-based layout.

The desktop header successfully migrates from styled-components to Tailwind:

  • Proper responsive visibility controls
  • Correct use of inline styles for dynamic values (line 53)
  • Valid arbitrary variant syntax for nested element targeting (line 55)
  • Clean three-section layout structure

coderabbitai[bot]
coderabbitai bot previously approved these changes Nov 6, 2025
Copy link
Contributor

@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

♻️ Duplicate comments (1)
web/src/layout/Header/navbar/DappList.tsx (1)

90-100: Add ARIA attributes for modal accessibility.

This modal container still lacks proper accessibility attributes that were flagged in a previous review. Screen readers cannot identify this as a dialog without role="dialog", aria-modal="true", and aria-labelledby pointing to the heading.

Apply this diff to add the required ARIA attributes:

     <div
       ref={containerRef}
+      role="dialog"
+      aria-modal="true"
+      aria-labelledby="dapp-list-heading"
       className={clsx(
         "flex flex-col items-center absolute max-h-[340px] top-[5%] left-1/2 transform -translate-x-1/2 z-1 w-[86vw] max-w-[480px]",
         "border border-klerosUIComponentsStroke rounded-[3px]",
         "bg-klerosUIComponentsWhiteBackground shadow-[0px_2px_3px_rgba(0,0,0,0.06)]",
         "[&_svg]:visible",
         "lg:mt-16 lg:top-0 lg:left-0 lg:right-auto lg:transform-none lg:translate-x-0 lg:max-h-[80vh]"
       )}
     >
-      <h1 className="pt-6 text-2xl font-semibold leading-8">Kleros Solutions</h1>
+      <h1 id="dapp-list-heading" className="pt-6 text-2xl font-semibold leading-8">Kleros Solutions</h1>
🧹 Nitpick comments (2)
web/src/layout/Header/navbar/DappList.tsx (2)

93-93: Consolidate redundant width constraints.

Both the outer container (line 93) and inner grid (lines 102-103) define width constraints with overlapping max-w-[480px]. The outer div uses w-[86vw] max-w-[480px] while the inner div uses max-w-[480px] min-w-[300px] plus width: responsiveSize(300, 480). This creates a confusing layout model where the effective width depends on which constraint is tighter.

Consider consolidating all width logic to a single element:

Option 1: Move all width constraints to the outer container

       className={clsx(
-        "flex flex-col items-center absolute max-h-[340px] top-[5%] left-1/2 transform -translate-x-1/2 z-1 w-[86vw] max-w-[480px]",
+        "flex flex-col items-center absolute max-h-[340px] top-[5%] left-1/2 transform -translate-x-1/2 z-1 max-w-[480px] min-w-[300px]",
         ...
       )}
+      style={{ width: responsiveSize(300, 480) }}
     >
       ...
       <div
-        className="grid overflow-y-auto gap-y-2 gap-x-0.5 justify-items-center max-w-[480px] min-w-[300px] grid-cols-[repeat(auto-fit,minmax(100px,1fr))]"
+        className="grid overflow-y-auto gap-y-2 gap-x-0.5 justify-items-center w-full grid-cols-[repeat(auto-fit,minmax(100px,1fr))]"
-        style={{ padding: `4px ${responsiveSize(8, 24)} 16px`, width: responsiveSize(300, 480) }}
+        style={{ padding: `4px ${responsiveSize(8, 24)} 16px` }}
       >

Option 2: Remove outer width, keep only inner

       className={clsx(
-        "flex flex-col items-center absolute max-h-[340px] top-[5%] left-1/2 transform -translate-x-1/2 z-1 w-[86vw] max-w-[480px]",
+        "flex flex-col items-center absolute max-h-[340px] top-[5%] left-1/2 transform -translate-x-1/2 z-1",
         ...
       )}

Also applies to: 102-103


92-98: Consider simplifying clsx usage (optional).

The clsx call here only receives static string arguments without any conditional logic. While using clsx consistently is fine, you could simplify this to a template literal or plain string concatenation since there are no dynamic classes:

-      className={clsx(
-        "flex flex-col items-center absolute max-h-[340px] top-[5%] left-1/2 transform -translate-x-1/2 z-1 w-[86vw] max-w-[480px]",
-        "border border-klerosUIComponentsStroke rounded-[3px]",
-        "bg-klerosUIComponentsWhiteBackground shadow-[0px_2px_3px_rgba(0,0,0,0.06)]",
-        "[&_svg]:visible",
-        "lg:mt-16 lg:top-0 lg:left-0 lg:right-auto lg:transform-none lg:translate-x-0 lg:max-h-[80vh]"
-      )}
+      className="flex flex-col items-center absolute max-h-[340px] top-[5%] left-1/2 transform -translate-x-1/2 z-1 w-[86vw] max-w-[480px] border border-klerosUIComponentsStroke rounded-[3px] bg-klerosUIComponentsWhiteBackground shadow-[0px_2px_3px_rgba(0,0,0,0.06)] [&_svg]:visible lg:mt-16 lg:top-0 lg:left-0 lg:right-auto lg:transform-none lg:translate-x-0 lg:max-h-[80vh]"
📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 2ec1c2f and 6802e43.

📒 Files selected for processing (1)
  • web/src/layout/Header/navbar/DappList.tsx (2 hunks)
🧰 Additional context used
🧠 Learnings (2)
📓 Common learnings
Learnt from: kyrers
Repo: kleros/curate-v2 PR: 89
File: web/src/layout/index.tsx:15-28
Timestamp: 2025-10-24T21:25:59.174Z
Learning: In Tailwind v4, when using CSS variables from external libraries like kleros/ui-components-library, add the `source` directive in global.css to tell Tailwind to scan and generate utility classes from those variables. Example: `source "../node_modules/kleros/ui-components-library";`
📚 Learning: 2025-10-31T19:54:12.499Z
Learnt from: kyrers
Repo: kleros/curate-v2 PR: 89
File: web/src/layout/Header/DesktopHeader.tsx:43-44
Timestamp: 2025-10-31T19:54:12.499Z
Learning: In Tailwind CSS v4, the important modifier uses a trailing `!` after the utility class (e.g., `fill-white!`), unlike v3 which used a leading `!` prefix (e.g., `!fill-white`). This applies to all utilities including arbitrary values and after variants (e.g., `sm:hover:bg-green-500!`).

Applied to files:

  • web/src/layout/Header/navbar/DappList.tsx
⏰ 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). (3)
  • GitHub Check: Redirect rules - curate-v2
  • GitHub Check: Header rules - curate-v2
  • GitHub Check: Pages changed - curate-v2

coderabbitai[bot]
coderabbitai bot previously approved these changes Nov 7, 2025
coderabbitai[bot]
coderabbitai bot previously approved these changes Nov 7, 2025
coderabbitai[bot]
coderabbitai bot previously approved these changes Nov 7, 2025
Copy link
Contributor

@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: 3

♻️ Duplicate comments (2)
web/src/layout/Header/navbar/Product.tsx (2)

21-25: Move transition to base state for symmetric hover animations.

The hover: prefix on the transition utility means it only applies during hover, causing smooth scaling on hover-in but instant snap-back on hover-out.

Apply this diff to move the transition to the base state:

       className={clsx(
         "flex flex-col items-center pt-4 pb-7 px-2 max-w-[100px] rounded-[3px] gap-2",
         "cursor-pointer bg-klerosUIComponentsLightBackground hover:bg-light-grey dark:hover:bg-klerosUIComponentsLightGrey",
-        "hover:transition-[transform_0.15s,background-color_0.3s] hover:scale-[1.02]"
+        "transition-[transform_0.15s,background-color_0.3s] hover:scale-[1.02]"
       )}

30-30: Fix Skeleton height for circular placeholder.

The Skeleton uses height={46} with width={48} and the circle prop, creating an ellipse. The actual icon (line 32) is w-12 h-12 (48×48px), so the Skeleton should match.

Apply this diff:

-          {!isImgLoaded ? <Skeleton width={48} height={46} circle /> : null}
+          {!isImgLoaded ? <Skeleton width={48} height={48} circle /> : null}
🧹 Nitpick comments (3)
web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/index.tsx (1)

80-91: Consider removing commented-out Telegram contact code.

This commented block reduces code readability. If Telegram contact support is not planned for the near future, remove it. If it's needed later, consider tracking it in an issue instead.

web/src/layout/Header/navbar/Explore.tsx (2)

36-49: Consider adding aria-current for active links.

For better accessibility, active navigation links should include aria-current="page" to help screen reader users identify the current page.

Apply this diff to add the accessibility attribute:

        <Link
          key={text}
          className={cn(
            "flex items-center p-2 pl-0 rounded-[7px] lg:py-4 lg:px-2",
            "no-underline text-base leading-tight",
            isActive(to) ? "text-klerosUIComponentsPrimaryText lg:text-white" : "text-primary-text-73 lg:text-white-73",
            isMobileNavbar ? "hover:text-klerosUIComponentsPrimaryText" : "hover:text-white",
            isMobileNavbar && isActive(to) ? "font-semibold" : "font-normal"
          )}
+         aria-current={isActive(to) ? "page" : undefined}
          onClick={toggleIsOpen}
          {...{ to }}
        >

46-46: Simplify prop spreading.

The syntax {...{ to }} is unconventional. Consider using the more direct to={to} for clarity.

Apply this diff to simplify:

          onClick={toggleIsOpen}
-         {...{ to }}
+         to={to}
        >
📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 90e561f and 971297a.

📒 Files selected for processing (10)
  • web/src/components/EnsureAuth.tsx (1 hunks)
  • web/src/layout/Header/navbar/Explore.tsx (3 hunks)
  • web/src/layout/Header/navbar/Menu/Settings/General.tsx (2 hunks)
  • web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/EmailVerificationInfo.tsx (2 hunks)
  • web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/FormContact.tsx (2 hunks)
  • web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/index.tsx (3 hunks)
  • web/src/layout/Header/navbar/Menu/Settings/index.tsx (2 hunks)
  • web/src/layout/Header/navbar/Menu/index.tsx (1 hunks)
  • web/src/layout/Header/navbar/Product.tsx (2 hunks)
  • web/src/layout/Header/navbar/index.tsx (3 hunks)
🚧 Files skipped from review as they are similar to previous changes (2)
  • web/src/layout/Header/navbar/index.tsx
  • web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/EmailVerificationInfo.tsx
🧰 Additional context used
🧠 Learnings (11)
📓 Common learnings
Learnt from: kyrers
Repo: kleros/curate-v2 PR: 89
File: web/src/layout/index.tsx:15-28
Timestamp: 2025-10-24T21:25:59.174Z
Learning: In Tailwind v4, when using CSS variables from external libraries like kleros/ui-components-library, add the `source` directive in global.css to tell Tailwind to scan and generate utility classes from those variables. Example: `source "../node_modules/kleros/ui-components-library";`
📚 Learning: 2024-11-04T13:33:39.755Z
Learnt from: Harman-singh-waraich
Repo: kleros/curate-v2 PR: 65
File: web/src/pages/Settings/index.tsx:18-26
Timestamp: 2024-11-04T13:33:39.755Z
Learning: In `web/src/pages/Settings/index.tsx`, the parent route handles the default `/settings` route, error boundaries, and loading states, so it's not necessary to include them in this component.

Applied to files:

  • web/src/layout/Header/navbar/Menu/Settings/index.tsx
📚 Learning: 2024-11-04T13:31:54.080Z
Learnt from: Harman-singh-waraich
Repo: kleros/curate-v2 PR: 65
File: web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/index.tsx:72-96
Timestamp: 2024-11-04T13:31:54.080Z
Learning: In the React TypeScript component `FormContactDetails` in `web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/index.tsx`, error handling and user feedback are implemented within the `addUser` and `updateEmail` functions, which display toasts to the user.

Applied to files:

  • web/src/layout/Header/navbar/Menu/Settings/index.tsx
  • web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/FormContact.tsx
  • web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/index.tsx
📚 Learning: 2025-10-31T20:37:01.310Z
Learnt from: kyrers
Repo: kleros/curate-v2 PR: 89
File: web/src/components/OverlayPortal.tsx:5-8
Timestamp: 2025-10-31T20:37:01.310Z
Learning: In Tailwind CSS v4, the `z-<number>` syntax directly sets `z-index: <number>;` for any numeric value (e.g., `z-9999` results in `z-index: 9999;`). Arbitrary value brackets `z-[<value>]` are not required for numeric z-index values in v4.
```
<!-- [remove_learning]
dcbe3a95-44f6-47d5-806e-64b74d549e4b

Applied to files:

  • web/src/layout/Header/navbar/Menu/Settings/index.tsx
📚 Learning: 2025-10-24T21:25:59.174Z
Learnt from: kyrers
Repo: kleros/curate-v2 PR: 89
File: web/src/layout/index.tsx:15-28
Timestamp: 2025-10-24T21:25:59.174Z
Learning: In Tailwind v4, when using CSS variables from external libraries like kleros/ui-components-library, add the `source` directive in global.css to tell Tailwind to scan and generate utility classes from those variables. Example: `source "../node_modules/kleros/ui-components-library";`

Applied to files:

  • web/src/layout/Header/navbar/Menu/Settings/index.tsx
  • web/src/layout/Header/navbar/Menu/index.tsx
📚 Learning: 2024-11-04T13:41:31.226Z
Learnt from: Harman-singh-waraich
Repo: kleros/curate-v2 PR: 65
File: web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/index.tsx:126-126
Timestamp: 2024-11-04T13:41:31.226Z
Learning: In `web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/index.tsx`, the `isUndefined` function effectively handles `null` or `undefined` values. Therefore, using the non-null assertion `!` on `user?.emailUpdateableAt` when calling `timeLeftUntil(user?.emailUpdateableAt!)` is acceptable, as potential `null` or `undefined` cases are already managed.

Applied to files:

  • web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/FormContact.tsx
  • web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/index.tsx
📚 Learning: 2024-11-04T13:39:19.748Z
Learnt from: Harman-singh-waraich
Repo: kleros/curate-v2 PR: 65
File: web/src/utils/atlas/updateEmail.ts:21-38
Timestamp: 2024-11-04T13:39:19.748Z
Learning: For the `updateEmail` function in `web/src/utils/atlas/updateEmail.ts`, input validation and error handling are performed in the component that utilizes it. Therefore, additional checks within this utility function are unnecessary.

Applied to files:

  • web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/FormContact.tsx
📚 Learning: 2025-10-31T19:54:12.499Z
Learnt from: kyrers
Repo: kleros/curate-v2 PR: 89
File: web/src/layout/Header/DesktopHeader.tsx:43-44
Timestamp: 2025-10-31T19:54:12.499Z
Learning: In Tailwind CSS v4, the important modifier uses a trailing `!` after the utility class (e.g., `fill-white!`), unlike v3 which used a leading `!` prefix (e.g., `!fill-white`). This applies to all utilities including arbitrary values and after variants (e.g., `sm:hover:bg-green-500!`).

Applied to files:

  • web/src/layout/Header/navbar/Menu/index.tsx
📚 Learning: 2025-11-06T23:06:51.514Z
Learnt from: kyrers
Repo: kleros/curate-v2 PR: 89
File: web/src/global.css:3-3
Timestamp: 2025-11-06T23:06:51.514Z
Learning: In Tailwind v4, you can use `import "tailwindcss" source("path")` syntax to control automatic content detection by passing the source() argument directly on the import statement. This is in addition to the standalone `source "path"` directive. Both syntaxes are valid: `import "tailwindcss" source("../../node_modules/kleros/ui-components-library");` and `source "../../node_modules/kleros/ui-components-library";`

Applied to files:

  • web/src/layout/Header/navbar/Menu/index.tsx
📚 Learning: 2024-11-04T13:41:01.846Z
Learnt from: Harman-singh-waraich
Repo: kleros/curate-v2 PR: 65
File: web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/EmailVerificationInfo.tsx:67-80
Timestamp: 2024-11-04T13:41:01.846Z
Learning: In React components, when a button is used within a form, calling `e.preventDefault()` in the event handler is necessary to prevent the default form submission, even when using an `onClick` handler.

Applied to files:

  • web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/index.tsx
📚 Learning: 2024-11-04T13:29:55.971Z
Learnt from: Harman-singh-waraich
Repo: kleros/curate-v2 PR: 65
File: web/src/context/AtlasProvider.tsx:176-193
Timestamp: 2024-11-04T13:29:55.971Z
Learning: In the `web/src/context/AtlasProvider.tsx` file of the React application, the `authoriseUser` function handles session invalidation and delegates error handling and user notifications to the functions that invoke it. Therefore, adding error notifications within `authoriseUser` is unnecessary.

Applied to files:

  • web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/index.tsx
🧬 Code graph analysis (3)
web/src/layout/Header/navbar/Menu/Settings/General.tsx (2)
web/src/components/EnsureChain.tsx (1)
  • EnsureChain (10-14)
web/src/components/ConnectWallet/AccountDisplay.tsx (3)
  • IdenticonOrAvatar (17-35)
  • AddressOrName (41-51)
  • ChainDisplay (53-57)
web/src/layout/Header/navbar/Explore.tsx (1)
web/src/utils/index.ts (1)
  • cn (44-46)
web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/index.tsx (1)
web/src/utils/date.ts (1)
  • timeLeftUntil (43-69)
⏰ 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). (3)
  • GitHub Check: Redirect rules - curate-v2
  • GitHub Check: Header rules - curate-v2
  • GitHub Check: Pages changed - curate-v2
🔇 Additional comments (14)
web/src/components/EnsureAuth.tsx (1)

33-33: LGTM! Button prop updated for library v3 compatibility.

The prop rename from disabled to isDisabled correctly aligns with the upgraded @kleros/ui-components-library v3 API while preserving the same disable logic.

web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/FormContact.tsx (1)

41-47: LGTM! Clean migration to Tailwind utilities.

The TextField implementation correctly uses Tailwind classes and the simplified onChange handler appropriately passes the value directly to setContactInput. The arbitrary variant [&_input]:text-sm is valid Tailwind syntax for styling descendant input elements.

web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/index.tsx (3)

75-79: LGTM! Critical form submission issue resolved.

The form element has been correctly restored with the onSubmit handler, fixing the previously flagged critical issue. The form will now properly handle submission both on Enter key press and button click.


92-103: LGTM!

Clean wrapper implementation with appropriate Tailwind classes.


110-118: LGTM! Button submit functionality properly configured.

The Button now has type="submit" and is wrapped in the correct form element, ensuring proper form submission behavior. The disabled conditions appropriately prevent submission when validation fails or operations are in progress.

web/src/layout/Header/navbar/Explore.tsx (4)

6-6: LGTM: Proper utility imports for Tailwind migration.

The cn utility correctly enables conditional class merging, and isUndefined provides type-safe checks.


17-18: LGTM: Active route detection logic is correct.

The function properly handles exact matching for the home route and segment-based matching for other routes.


38-44: Previous critical issue resolved: className construction is now correct.

The use of cn() properly merges all conditional classes with correct spacing. The logic is clear and maintainable.


39-39: Verify Tailwind configuration and completeness of responsive breakpoint migration.

Automated search found no landscape-900: usage in the codebase and could not locate the Tailwind configuration file to confirm actual breakpoint values (landscape-900 claimed as 900px, lg as 1024px). Before merging, manually verify:

  • The Tailwind config location and whether landscape-900 is still defined as a custom breakpoint
  • The actual pixel value assigned to lg in your breakpoints configuration
  • Whether this is the only location requiring migration from landscape-900: to lg:
  • Whether the 124px shift in responsive behavior aligns with your design intent
web/src/layout/Header/navbar/Menu/index.tsx (1)

37-37: LGTM: Clean responsive flex container.

The outer wrapper correctly uses standard Tailwind utilities for responsive layout direction changes.

web/src/layout/Header/navbar/Menu/Settings/General.tsx (2)

7-10: LGTM: Clean button implementation.

The DisconnectWalletButton correctly uses a custom color from the Kleros UI library theme, which is available via the theme.css import.


12-49: LGTM: Well-structured layout with proper Tailwind migration.

The component structure successfully migrates from styled-components to Tailwind utilities:

  • Proper use of arbitrary selectors like [&>label]: and [&_label]: for nested element styling
  • Correct pseudo-element syntax with before:content-[''] for the status indicator
  • Appropriate nesting and responsive layout classes
  • Custom Kleros UI colors are correctly referenced

The migration preserves functionality while adopting Tailwind patterns effectively.

web/src/layout/Header/navbar/Menu/Settings/index.tsx (2)

8-8: Good additions: clsx import and tab IDs.

The addition of the clsx import enables cleaner className composition, and adding explicit id fields to the TABS array provides stable identifiers for tab management and React keys.

Also applies to: 12-12, 16-16


31-51: LGTM: Successfully migrated with improved class composition.

The Settings component has been successfully migrated from styled-components to Tailwind utilities with several improvements:

  1. clsx composition (lines 33-37): Cleaner multi-line className organization compared to string concatenation
  2. Fixed breakpoint usage (line 36): Changed from landscape-900: to standard lg: prefix, resolving the custom variant configuration issue from previous reviews
  3. Valid z-index (line 34): z-1 is correct in Tailwind v4, which supports direct numeric z-index values
  4. Proper width utilities (line 41): Uses w-[86vw] and w-[calc(...)] with correct w- prefix

All critical issues from previous reviews have been addressed.

Based on learnings

Copy link
Contributor

@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 (1)
web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/FormContact.tsx (1)

40-50: The hardcoded ID is a latent bug; apply dynamic ID to prevent future duplicates.

The label correctly links to the TextField via htmlFor="contact-input" / id="contact-input", fixing the accessibility concern. However, the codebase shows a latent issue:

  • Currently, FormContact renders only once (Email field; Telegram is commented out on lines 80–91).
  • The commented code demonstrates the component was designed to support multiple contact fields (Email + Telegram with identical hardcoded IDs).
  • When Telegram is uncommented, duplicate IDs will break HTML validation and accessibility.

Apply a dynamic ID to prevent this problem from manifesting:

interface IForm {
  contactLabel: string;
  contactPlaceholder: string;
  contactInput: string;
  contactIsValid: boolean;
  setContactInput: Dispatch<SetStateAction<string>>;
  setContactIsValid: Dispatch<SetStateAction<boolean>>;
  validator: RegExp;
  isEditing?: boolean;
+  fieldId?: string;
}

const FormContact: React.FC<IForm> = ({
  contactLabel,
  contactPlaceholder,
  contactInput,
  contactIsValid,
  setContactInput,
  setContactIsValid,
  validator,
  isEditing,
+  fieldId = "contact-input",
}) => {
  return (
    <>
-      <label htmlFor="contact-input" className="flex mb-[10px]">
+      <label htmlFor={fieldId} className="mb-[10px]">
         {contactLabel}
       </label>
       <TextField
         className="flex flex-col items-center w-full [&_input]:text-sm"
-        id="contact-input"
+        id={fieldId}
         variant={fieldVariant}
         value={contactInput}
         onChange={(value) => setContactInput(value)}
         placeholder={contactPlaceholder}
       />
    </>
  );
};

Then pass unique IDs when calling FormContact (e.g., fieldId="contact-email", fieldId="contact-telegram").

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 971297a and 4474759.

📒 Files selected for processing (1)
  • web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/FormContact.tsx (2 hunks)
🧰 Additional context used
🧠 Learnings (4)
📓 Common learnings
Learnt from: kyrers
Repo: kleros/curate-v2 PR: 89
File: web/src/layout/index.tsx:15-28
Timestamp: 2025-10-24T21:25:59.174Z
Learning: In Tailwind v4, when using CSS variables from external libraries like kleros/ui-components-library, add the `source` directive in global.css to tell Tailwind to scan and generate utility classes from those variables. Example: `source "../node_modules/kleros/ui-components-library";`
📚 Learning: 2024-11-04T13:31:54.080Z
Learnt from: Harman-singh-waraich
Repo: kleros/curate-v2 PR: 65
File: web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/index.tsx:72-96
Timestamp: 2024-11-04T13:31:54.080Z
Learning: In the React TypeScript component `FormContactDetails` in `web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/index.tsx`, error handling and user feedback are implemented within the `addUser` and `updateEmail` functions, which display toasts to the user.

Applied to files:

  • web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/FormContact.tsx
📚 Learning: 2024-11-04T13:41:31.226Z
Learnt from: Harman-singh-waraich
Repo: kleros/curate-v2 PR: 65
File: web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/index.tsx:126-126
Timestamp: 2024-11-04T13:41:31.226Z
Learning: In `web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/index.tsx`, the `isUndefined` function effectively handles `null` or `undefined` values. Therefore, using the non-null assertion `!` on `user?.emailUpdateableAt` when calling `timeLeftUntil(user?.emailUpdateableAt!)` is acceptable, as potential `null` or `undefined` cases are already managed.

Applied to files:

  • web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/FormContact.tsx
📚 Learning: 2024-11-04T13:39:19.748Z
Learnt from: Harman-singh-waraich
Repo: kleros/curate-v2 PR: 65
File: web/src/utils/atlas/updateEmail.ts:21-38
Timestamp: 2024-11-04T13:39:19.748Z
Learning: For the `updateEmail` function in `web/src/utils/atlas/updateEmail.ts`, input validation and error handling are performed in the component that utilizes it. Therefore, additional checks within this utility function are unnecessary.

Applied to files:

  • web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/FormContact.tsx
⏰ 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). (3)
  • GitHub Check: Redirect rules - curate-v2
  • GitHub Check: Header rules - curate-v2
  • GitHub Check: Pages changed - curate-v2
🔇 Additional comments (1)
web/src/layout/Header/navbar/Menu/Settings/Notifications/FormContactDetails/FormContact.tsx (1)

3-3: LGTM! Import aligns with Tailwind migration.

The TextField import from @kleros/ui-components-library correctly replaces styled-components usage as part of the migration objective.

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.

Frontend migration to the major update of @kleros/ui-components-library v3 with Tailwind

2 participants