Skip to content

99 sync reconcile navbar#109

Merged
InfinityBowman merged 7 commits into
mainfrom
99-sync-reconcile-navbar
Dec 19, 2025
Merged

99 sync reconcile navbar#109
InfinityBowman merged 7 commits into
mainfrom
99-sync-reconcile-navbar

Conversation

@InfinityBowman
Copy link
Copy Markdown
Owner

@InfinityBowman InfinityBowman commented Dec 19, 2025

Summary by CodeRabbit

  • Bug Fixes

    • Per-user project cache and improved offline/error handling; fixed checklist syncing edge cases to avoid runtime access errors.
  • New Features

    • Streamlined reconciliation with dedicated reconciled checklists, automatic creation/selection, and simplified save/finish flow. Navigation state for reconciliation pages is now persisted.
  • UI

    • Minor spacing/typography tweaks, smaller final badges, a small check indicator for answered items, improved tooltip/overlay stacking and positioning, and smoother split-panel transitions.
  • Chores

    • Lint config updated to recognize browser globals (fetch, URL, caches).

✏️ Tip: You can customize this high-level summary in your review settings.

@InfinityBowman InfinityBowman linked an issue Dec 19, 2025 that may be closed by this pull request
@cloudflare-workers-and-pages
Copy link
Copy Markdown

cloudflare-workers-and-pages Bot commented Dec 19, 2025

Deploying with  Cloudflare Workers  Cloudflare Workers

The latest updates on your project. Learn more about integrating Git with Workers.

Status Name Latest Commit Preview URL Updated (UTC)
✅ Deployment successful!
View logs
corates bba6c35 Commit Preview URL Dec 19 2025, 10:17 PM

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented Dec 19, 2025

Walkthrough

Adds browser globals to ESLint, hardens Yjs checklist initialization, scopes project cache by userId, replaces reconciliation progress with reconciledChecklistId and new question-note/update APIs, and applies multiple UI/z-index and split-screen/tooltip layout updates.

Changes

Cohort / File(s) Summary
ESLint config
eslint.config.js
Added readonly browser globals: fetch, URL, and caches to languageOptions.globals.
Yjs checklist init
packages/web/src/primitives/useProject/checklists.js
Attach answers Y.Map earlier; add addedKeys tracking to avoid Yjs race checks; replace map.has guard with addedKeys.has; remove redundant final map set.
Project actions error handling
packages/web/src/stores/projectActionsStore/checklists.js
Wrap getData in try/catch; return null when error message includes "No active project", rethrow otherwise.
User-scoped project cache
packages/web/src/stores/projectStore.js
Persist userId with cached projects (cachedUserId in state); update loadCachedProjectList/saveCachedProjectList; invalidate or refresh cache when userId mismatches; propagate cachedUserId through add/update/remove flows.
Reconciliation storage & API
packages/web/src/primitives/useProject/reconciliation.js
Replace detailed progress shape with minimal progress storing reconciledChecklistId; remove finalAnswers and getReconciliationNote; update save/get signatures and return shape.
useProject public API
packages/web/src/primitives/useProject/index.js
Removed exported getReconciliationNote wrapper from the public API.
Reconciliation orchestration & props
packages/web/src/components/checklist-ui/compare/ReconciliationWrapper.jsx, packages/web/src/components/checklist-ui/compare/ReconciliationWithPdf.jsx, packages/web/src/components/checklist-ui/compare/ChecklistReconciliation.jsx
Add reconciled-checklist state machine: find/reuse or create reconciled checklist, persist reconciledChecklistId, mitigate races, expose reconciledChecklist/reconciledChecklistId, pass getQuestionNote and updateChecklistAnswer into children; save calls onSaveReconciled(reconciledName).
Saved-progress → reconciled-driven navigation
packages/web/src/components/checklist-ui/compare/ChecklistReconciliation.jsx
Replace saved-progress state with reconciled-driven flow; store per-pair navigation in localStorage; derive finalAnswers from reconciled checklist and write updates through updateChecklistAnswer.
Navbar & question pill UI
packages/web/src/components/checklist-ui/compare/Navbar.jsx, packages/web/src/components/checklist-ui/compare/navbar-utils.js
Add small check badge on pills when answered; simplify getQuestionPillStyle to ignore hasAnswer styling branch and always use lighter style for non-current pages.
Compare UI spacing/typography
packages/web/src/components/checklist-ui/compare/AnswerPanel.jsx, packages/web/src/components/checklist-ui/compare/ReconciliationQuestionPage.jsx
Minor spacing and typography tweaks (header margins, badge sizing, question title/final label sizes).
Reconciliation PDF layout & props
packages/web/src/components/checklist-ui/compare/ReconciliationWithPdf.jsx
Replace split-panel drag logic with SplitScreenLayout; add reconciledChecklist/reconciledChecklistId props; forward getQuestionNotegetQuestionNote and add updateChecklistAnswer prop.
Reconciliation wrapper UI logic
packages/web/src/components/checklist-ui/compare/ReconciliationWrapper.jsx
New loading states/signals for reconciled checklist, creation/reuse logic, race handling, reconciledChecklistData/meta helpers, and handleSaveReconciled to complete reconciled checklist.
Navbar persistence & navigation state
packages/web/src/components/checklist-ui/compare/ChecklistReconciliation.jsx (localStorage usage)
Persist currentPage and viewMode keyed by checklist pair ids; initialize and auto-save on change.
Split screen animations & resizing
packages/web/src/components/checklist-ui/SplitScreenLayout.jsx
Add transition/animation classes; always render divider when second panel exists; animate second panel show/hide with transform/opacity and inner scroll container.
Tooltip portal & z-index
packages/ui/src/zag/Tooltip.jsx, packages/ui/src/constants/zIndex.js, packages/ui/src/index.js
New Z_INDEX constant file; tooltip content moved into a Portal, fixed positioning strategy, use Z_INDEX.TOOLTIP. Z_INDEX re-exported from UI package.
Centralized z-index adoption
multiple zag components and consumers
Replace hard-coded z-classes with Z_INDEX.* in: packages/ui/src/zag/{Combobox,Dialog,Drawer,Menu,Popover,Toast,Tour}.jsx, and consumers packages/web/src/components/{admin-ui/ImpersonationBanner.jsx,charts/ChartSettingsModal.jsx}.
Reconcile count predicate
packages/web/src/components/project-ui/ProjectView.jsx, packages/web/src/components/project-ui/reconcile-tab/ReconcileTab.jsx, packages/web/src/utils/reconciliation.js
Add isStudyInReconciliation(study) util; replace inline filtering with this predicate to determine studies shown in reconciliation and counts.

Sequence Diagram(s)

sequenceDiagram
  participant UI as Reconciliation UI
  participant Wrapper as ReconciliationWrapper
  participant Project as useProject (reconciliation)
  participant Yjs as Yjs (checklist docs)

  UI->>Wrapper: open reconciliation for checklist1 & checklist2
  Wrapper->>Project: getReconciliationProgress(studyId, checklist1Id, checklist2Id)
  Project-->>Wrapper: { reconciledChecklistId | null }
  alt reconciledChecklistId present
    Wrapper->>Yjs: load reconciled checklist by id
    Yjs-->>Wrapper: reconciledChecklist data
    Wrapper->>UI: render with reconciledChecklistId & data
  else none
    Wrapper->>Yjs: search for existing reconciled checklists in study
    Yjs-->>Wrapper: list (maybe empty)
    alt found existing
      Wrapper->>Project: saveReconciliationProgress(reconciledChecklistId)
      Project-->>Wrapper: updated progress
      Wrapper->>UI: render with reconciledChecklistId & data
    else not found
      Wrapper->>Yjs: create reconciled checklist (seed answers/meta)
      Yjs-->>Wrapper: new reconciledChecklistId
      Wrapper->>Project: saveReconciliationProgress(reconciledChecklistId)
      Project-->>Wrapper: updated progress
      Wrapper->>UI: render with reconciledChecklistId & data
    end
  end
  UI->>Wrapper: user edits answer -> updateChecklistAnswer(questionKey, data)
  Wrapper->>Yjs: write answer into reconciled checklist answers map
  Yjs-->>Wrapper: ack
  Wrapper->>UI: reflect updated finalAnswers (derived from Yjs)
Loading

Estimated code review effort

🎯 4 (Complex) | ⏱️ ~45 minutes

Areas to focus review on:

  • packages/web/src/primitives/useProject/reconciliation.js — API shape change, removal of per-question note APIs, and callers update.
  • packages/web/src/components/checklist-ui/compare/ReconciliationWrapper.jsx — reconciliation creation/reuse, race resolution, and correct persistence of reconciledChecklistId.
  • packages/web/src/stores/projectStore.js — userId-scoped caching, load/save/invalidation edge cases and offline fallback.
  • packages/web/src/primitives/useProject/checklists.js — early Y.Map insertion and addedKeys correctness under concurrent Yjs updates.
  • UI z-index consolidation — ensure all overlays use appropriate Z_INDEX tokens and no regressions in stacking.

Possibly related PRs

Poem

🐰 I planted maps before they woke,

seeded answers, fixed the yoke,
caches learned which user’s name,
tooltips found their proper plane,
lint now knows fetch, URL, and caches — hop, hop, hooray!

Pre-merge checks and finishing touches

❌ Failed checks (1 warning, 1 inconclusive)
Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 77.27% which is insufficient. The required threshold is 80.00%. You can run @coderabbitai generate docstrings to improve docstring coverage.
Title check ❓ Inconclusive The title "99 sync reconcile navbar" is vague and uses non-descriptive terms. It references a branch name/ticket number rather than clearly summarizing the main change. Revise the title to describe the primary change. For example: "Refactor reconciliation workflow with synchronized checklist state and reactive navbar" or "Implement reconciled checklist state management and responsive UI updates".
✅ Passed checks (1 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
✨ 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 99-sync-reconcile-navbar

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

Copy link
Copy Markdown

@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 (2)
packages/web/src/stores/projectStore.js (1)

372-383: Consider resetting loading and error when clearing cache for user mismatch.

When the userId changes and the cache is cleared, the setStore call at lines 378-382 doesn't reset loading or error. If a previous fetch was in progress or had an error, those states could persist incorrectly.

Proposed fix
     if (cachedUserId && cachedUserId !== userId) {
       setStore('projectList', {
         items: [],
         loaded: false,
+        loading: false,
+        error: null,
         cachedUserId: null,
       });
     }
packages/web/src/stores/projectActionsStore/checklists.js (1)

78-89: String-based error matching is fragile.

Matching error messages with err.message?.includes('No active project') is brittle—if the error message changes elsewhere, this handler will silently fail to catch the intended case. Consider using a custom error class or error code for more reliable matching.

Alternative approach using error codes
// In the throwing code:
const error = new Error('No active project');
error.code = 'NO_ACTIVE_PROJECT';
throw error;

// In getData:
function getData(studyId, checklistId) {
  try {
    const ops = getActiveConnection();
    return ops?.getChecklistData?.(studyId, checklistId);
  } catch (err) {
    if (err.code === 'NO_ACTIVE_PROJECT') {
      return null;
    }
    throw err;
  }
}
📜 Review details

Configuration used: defaults

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between be8bf45 and c3cdeb4.

📒 Files selected for processing (4)
  • eslint.config.js (1 hunks)
  • packages/web/src/primitives/useProject/checklists.js (3 hunks)
  • packages/web/src/stores/projectActionsStore/checklists.js (1 hunks)
  • packages/web/src/stores/projectStore.js (9 hunks)
🧰 Additional context used
📓 Path-based instructions (8)
**/*

📄 CodeRabbit inference engine (.cursorrules)

Do not use emojis in code, comments, documentation, or commit messages

Files:

  • packages/web/src/stores/projectActionsStore/checklists.js
  • packages/web/src/primitives/useProject/checklists.js
  • eslint.config.js
  • packages/web/src/stores/projectStore.js
packages/web/src/**/*.{jsx,tsx,js,ts}

📄 CodeRabbit inference engine (.cursorrules)

packages/web/src/**/*.{jsx,tsx,js,ts}: For UI icons, use the solid-icons library or SVGs only. Do not use emojis
Import stores directly where needed instead of passing values through multiple components
When you need to compute a value based on props or state in SolidJS, use createMemo to ensure it updates reactively
For complex state or state objects in SolidJS, use Solid's createStore for better performance and reactivity
You may create reusable logic in 'primitives' (hooks) that can be shared across components to keep components clean and focused on rendering

Files:

  • packages/web/src/stores/projectActionsStore/checklists.js
  • packages/web/src/primitives/useProject/checklists.js
  • packages/web/src/stores/projectStore.js
packages/**/*.{js,jsx,ts,tsx}

📄 CodeRabbit inference engine (.cursorrules)

packages/**/*.{js,jsx,ts,tsx}: Prefer modern ES6+ syntax and features
Use aliases for imports when appropriate to improve readability
Prefer using config files rather than hardcoding values
Keep files small, focused, and modular. If a file exceeds a high number of lines, consider refactoring by extracting sub-modules into a folder with index.jsx and helper components, moving complex logic into separate utility files or primitives, or splitting large forms into section components
Each file should handle one coherent responsibility
Use Zod for schema and input validation

Files:

  • packages/web/src/stores/projectActionsStore/checklists.js
  • packages/web/src/primitives/useProject/checklists.js
  • packages/web/src/stores/projectStore.js
packages/web/src/**/*.{jsx,tsx,js,ts,css}

📄 CodeRabbit inference engine (.cursorrules)

Ensure browser compatibility for all frontend code (Safari is usually problematic)

Files:

  • packages/web/src/stores/projectActionsStore/checklists.js
  • packages/web/src/primitives/useProject/checklists.js
  • packages/web/src/stores/projectStore.js
packages/web/src/**/*.{js,jsx,ts,tsx}

📄 CodeRabbit inference engine (.github/copilot-instructions.md)

packages/web/src/**/*.{js,jsx,ts,tsx}: For UI icons, use the solid-icons library or SVGs only. Do not use emojis
Ensure browser compatibility for all frontend code (Safari is usually problematic)
Keep files small, focused, and modular. If a file exceeds a high number of lines, consider refactoring by extracting sub-modules into a folder with index.jsx and helper components, moving complex logic into separate utility files or primitives, or splitting large forms into section components
Do NOT prop-drill application state. Shared or cross-feature state must live in external stores under packages/web/src/stores/ or relative to the component file
Use createMemo for derived values to ensure they update reactively

Files:

  • packages/web/src/stores/projectActionsStore/checklists.js
  • packages/web/src/primitives/useProject/checklists.js
  • packages/web/src/stores/projectStore.js
**/*.{js,jsx,ts,tsx}

📄 CodeRabbit inference engine (.github/copilot-instructions.md)

**/*.{js,jsx,ts,tsx}: Prefer modern ES6+ syntax and features
Use aliases for imports when appropriate to improve readability

Files:

  • packages/web/src/stores/projectActionsStore/checklists.js
  • packages/web/src/primitives/useProject/checklists.js
  • eslint.config.js
  • packages/web/src/stores/projectStore.js
packages/web/src/stores/**/*.{js,ts}

📄 CodeRabbit inference engine (.github/copilot-instructions.md)

Use Solid's createStore for complex state or state objects for better performance and reactivity

Files:

  • packages/web/src/stores/projectActionsStore/checklists.js
  • packages/web/src/stores/projectStore.js
packages/web/src/primitives/**/*.{js,ts}

📄 CodeRabbit inference engine (.github/copilot-instructions.md)

Create reusable logic in primitives (hooks) that can be shared across components to keep components clean and focused on rendering

Files:

  • packages/web/src/primitives/useProject/checklists.js
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
  • GitHub Check: Workers Builds: corates
🔇 Additional comments (6)
eslint.config.js (1)

44-47: LGTM!

The addition of fetch, URL, and caches as readonly globals is appropriate for browser code that uses these standard Web APIs.

packages/web/src/primitives/useProject/checklists.js (2)

93-95: Good fix for Yjs document structure initialization.

Attaching answersYMap to checklistYMap early ensures the map is part of the document structure before subsequent operations access it, preventing potential Yjs errors when the map is not yet connected.


104-130: Solid approach using a local Set for tracking.

Using addedKeys to track which question keys have been processed avoids potential timing issues with Y.Map.has() during document initialization. This is a clean, defensive pattern.

packages/web/src/stores/projectStore.js (3)

27-49: LGTM on user-scoped cache loading.

The cache now includes userId validation and returns a structured object with both projects and userId, enabling proper user-scoped cache behavior.


303-340: Good cache consistency in mutation handlers.

The list mutation functions (addProjectToList, updateProjectInList, removeProjectFromList) correctly preserve the cachedUserId when updating the cache, maintaining user-scoped cache integrity.


399-419: Good security: offline fallback validates user identity.

The offline handling correctly validates that cached data belongs to the current user (cached.userId === userId) before using it, preventing potential cross-user data exposure.

Copy link
Copy Markdown

@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

🧹 Nitpick comments (4)
packages/web/src/components/checklist-ui/compare/Navbar.jsx (1)

65-72: Consider adding an explicit border color for cross-browser consistency.

The badge uses border-[0.5px] without specifying a color. Browser defaults may vary, and Safari in particular can render this inconsistently.

Suggested fix
          <span
-           class='absolute -top-0.5 -right-0.5 flex h-3.5 w-3.5 items-center justify-center rounded-full border-[0.5px] bg-white shadow-sm'
+           class='absolute -top-0.5 -right-0.5 flex h-3.5 w-3.5 items-center justify-center rounded-full border-[0.5px] border-gray-200 bg-white shadow-sm'
            aria-hidden='true'
          >
packages/web/src/components/checklist-ui/compare/navbar-utils.js (1)

35-47: Unused parameter hasAnswer in getQuestionPillStyle.

The hasAnswer parameter is now unused since styling no longer depends on it (checkmark overlay handles this). While keeping it maintains backward compatibility, it could confuse future maintainers.

Consider removing it if no external callers depend on the signature, or mark it as deprecated in the JSDoc.

packages/web/src/components/checklist-ui/compare/ReconciliationWithPdf.jsx (1)

171-173: Unnecessary wrapper function for updateChecklistAnswer.

The inline arrow function is redundant since it only forwards the call with optional chaining. You can simplify by passing props.updateChecklistAnswer directly, as the child should handle undefined gracefully.

Suggested simplification
            getQuestionNote={props.getQuestionNote}
-           updateChecklistAnswer={(questionKey, questionData) =>
-             props.updateChecklistAnswer?.(questionKey, questionData)
-           }
+           updateChecklistAnswer={props.updateChecklistAnswer}
          />

The child component (ChecklistReconciliation) should use optional chaining when calling this prop, which is the standard pattern in this codebase.

packages/web/src/components/checklist-ui/compare/ChecklistReconciliation.jsx (1)

256-256: Consider using structuredClone for deep copying if browser support allows.

The current JSON.parse(JSON.stringify(defaultAnswer)) approach works for checklist data but has limitations (cannot handle functions, undefined, symbols, or circular references). If the codebase supports modern browsers, structuredClone(defaultAnswer) would be more robust.

As per coding guidelines, ensure browser compatibility for all frontend code (Safari is usually problematic). Safari supports structuredClone from version 15.4+. If targeting older Safari versions, the current approach is acceptable.

📜 Review details

Configuration used: defaults

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between c3cdeb4 and 674b7de.

📒 Files selected for processing (9)
  • packages/web/src/components/checklist-ui/compare/AnswerPanel.jsx (2 hunks)
  • packages/web/src/components/checklist-ui/compare/ChecklistReconciliation.jsx (8 hunks)
  • packages/web/src/components/checklist-ui/compare/Navbar.jsx (2 hunks)
  • packages/web/src/components/checklist-ui/compare/ReconciliationQuestionPage.jsx (1 hunks)
  • packages/web/src/components/checklist-ui/compare/ReconciliationWithPdf.jsx (3 hunks)
  • packages/web/src/components/checklist-ui/compare/ReconciliationWrapper.jsx (4 hunks)
  • packages/web/src/components/checklist-ui/compare/navbar-utils.js (1 hunks)
  • packages/web/src/primitives/useProject/index.js (0 hunks)
  • packages/web/src/primitives/useProject/reconciliation.js (4 hunks)
💤 Files with no reviewable changes (1)
  • packages/web/src/primitives/useProject/index.js
🧰 Additional context used
📓 Path-based instructions (11)
**/*

📄 CodeRabbit inference engine (.cursorrules)

Do not use emojis in code, comments, documentation, or commit messages

Files:

  • packages/web/src/components/checklist-ui/compare/Navbar.jsx
  • packages/web/src/components/checklist-ui/compare/AnswerPanel.jsx
  • packages/web/src/components/checklist-ui/compare/navbar-utils.js
  • packages/web/src/components/checklist-ui/compare/ReconciliationQuestionPage.jsx
  • packages/web/src/components/checklist-ui/compare/ReconciliationWithPdf.jsx
  • packages/web/src/components/checklist-ui/compare/ChecklistReconciliation.jsx
  • packages/web/src/components/checklist-ui/compare/ReconciliationWrapper.jsx
  • packages/web/src/primitives/useProject/reconciliation.js
packages/web/src/**/*.{jsx,tsx,js,ts}

📄 CodeRabbit inference engine (.cursorrules)

packages/web/src/**/*.{jsx,tsx,js,ts}: For UI icons, use the solid-icons library or SVGs only. Do not use emojis
Import stores directly where needed instead of passing values through multiple components
When you need to compute a value based on props or state in SolidJS, use createMemo to ensure it updates reactively
For complex state or state objects in SolidJS, use Solid's createStore for better performance and reactivity
You may create reusable logic in 'primitives' (hooks) that can be shared across components to keep components clean and focused on rendering

Files:

  • packages/web/src/components/checklist-ui/compare/Navbar.jsx
  • packages/web/src/components/checklist-ui/compare/AnswerPanel.jsx
  • packages/web/src/components/checklist-ui/compare/navbar-utils.js
  • packages/web/src/components/checklist-ui/compare/ReconciliationQuestionPage.jsx
  • packages/web/src/components/checklist-ui/compare/ReconciliationWithPdf.jsx
  • packages/web/src/components/checklist-ui/compare/ChecklistReconciliation.jsx
  • packages/web/src/components/checklist-ui/compare/ReconciliationWrapper.jsx
  • packages/web/src/primitives/useProject/reconciliation.js
packages/**/*.{js,jsx,ts,tsx}

📄 CodeRabbit inference engine (.cursorrules)

packages/**/*.{js,jsx,ts,tsx}: Prefer modern ES6+ syntax and features
Use aliases for imports when appropriate to improve readability
Prefer using config files rather than hardcoding values
Keep files small, focused, and modular. If a file exceeds a high number of lines, consider refactoring by extracting sub-modules into a folder with index.jsx and helper components, moving complex logic into separate utility files or primitives, or splitting large forms into section components
Each file should handle one coherent responsibility
Use Zod for schema and input validation

Files:

  • packages/web/src/components/checklist-ui/compare/Navbar.jsx
  • packages/web/src/components/checklist-ui/compare/AnswerPanel.jsx
  • packages/web/src/components/checklist-ui/compare/navbar-utils.js
  • packages/web/src/components/checklist-ui/compare/ReconciliationQuestionPage.jsx
  • packages/web/src/components/checklist-ui/compare/ReconciliationWithPdf.jsx
  • packages/web/src/components/checklist-ui/compare/ChecklistReconciliation.jsx
  • packages/web/src/components/checklist-ui/compare/ReconciliationWrapper.jsx
  • packages/web/src/primitives/useProject/reconciliation.js
packages/web/src/components/**/*.{jsx,tsx}

📄 CodeRabbit inference engine (.cursorrules)

packages/web/src/components/**/*.{jsx,tsx}: Use responsive design principles for UI components
Use Zag.js for UI components and design system
Zag components exist in packages/web/src/components/zag/* and should be reused; check the README.md in that folder for a list of existing components before adding new components and when debugging
Components should receive at most 1–5 props, and only for local configuration, not shared state
If a component would need more than 5 props, move the shared data into an external store, a primitive, or Solid context
Components should be lean and focused and should not implement business logic; move business logic into stores, utilities, or primitives
Never have a component act as a 'God component' coordinating multiple large concerns

Files:

  • packages/web/src/components/checklist-ui/compare/Navbar.jsx
  • packages/web/src/components/checklist-ui/compare/AnswerPanel.jsx
  • packages/web/src/components/checklist-ui/compare/ReconciliationQuestionPage.jsx
  • packages/web/src/components/checklist-ui/compare/ReconciliationWithPdf.jsx
  • packages/web/src/components/checklist-ui/compare/ChecklistReconciliation.jsx
  • packages/web/src/components/checklist-ui/compare/ReconciliationWrapper.jsx
packages/web/src/**/*.{jsx,tsx,js,ts,css}

📄 CodeRabbit inference engine (.cursorrules)

Ensure browser compatibility for all frontend code (Safari is usually problematic)

Files:

  • packages/web/src/components/checklist-ui/compare/Navbar.jsx
  • packages/web/src/components/checklist-ui/compare/AnswerPanel.jsx
  • packages/web/src/components/checklist-ui/compare/navbar-utils.js
  • packages/web/src/components/checklist-ui/compare/ReconciliationQuestionPage.jsx
  • packages/web/src/components/checklist-ui/compare/ReconciliationWithPdf.jsx
  • packages/web/src/components/checklist-ui/compare/ChecklistReconciliation.jsx
  • packages/web/src/components/checklist-ui/compare/ReconciliationWrapper.jsx
  • packages/web/src/primitives/useProject/reconciliation.js
packages/web/src/components/**/*.{jsx,tsx,js}

📄 CodeRabbit inference engine (.cursorrules)

Group related components in subdirectories with an index.js barrel export

Files:

  • packages/web/src/components/checklist-ui/compare/Navbar.jsx
  • packages/web/src/components/checklist-ui/compare/AnswerPanel.jsx
  • packages/web/src/components/checklist-ui/compare/navbar-utils.js
  • packages/web/src/components/checklist-ui/compare/ReconciliationQuestionPage.jsx
  • packages/web/src/components/checklist-ui/compare/ReconciliationWithPdf.jsx
  • packages/web/src/components/checklist-ui/compare/ChecklistReconciliation.jsx
  • packages/web/src/components/checklist-ui/compare/ReconciliationWrapper.jsx
packages/web/src/**/*.{jsx,tsx}

📄 CodeRabbit inference engine (.cursorrules)

packages/web/src/**/*.{jsx,tsx}: Do NOT prop-drill application state. Shared or cross-feature state must live in external stores under packages/web/src/stores/ or relative to the component file
Do not destructure props in SolidJS components as it breaks reactivity. Instead, access props directly from the props object or wrap them in a function to ensure they are always up-to-date

Files:

  • packages/web/src/components/checklist-ui/compare/Navbar.jsx
  • packages/web/src/components/checklist-ui/compare/AnswerPanel.jsx
  • packages/web/src/components/checklist-ui/compare/ReconciliationQuestionPage.jsx
  • packages/web/src/components/checklist-ui/compare/ReconciliationWithPdf.jsx
  • packages/web/src/components/checklist-ui/compare/ChecklistReconciliation.jsx
  • packages/web/src/components/checklist-ui/compare/ReconciliationWrapper.jsx
packages/web/src/**/*.{js,jsx,ts,tsx}

📄 CodeRabbit inference engine (.github/copilot-instructions.md)

packages/web/src/**/*.{js,jsx,ts,tsx}: For UI icons, use the solid-icons library or SVGs only. Do not use emojis
Ensure browser compatibility for all frontend code (Safari is usually problematic)
Keep files small, focused, and modular. If a file exceeds a high number of lines, consider refactoring by extracting sub-modules into a folder with index.jsx and helper components, moving complex logic into separate utility files or primitives, or splitting large forms into section components
Do NOT prop-drill application state. Shared or cross-feature state must live in external stores under packages/web/src/stores/ or relative to the component file
Use createMemo for derived values to ensure they update reactively

Files:

  • packages/web/src/components/checklist-ui/compare/Navbar.jsx
  • packages/web/src/components/checklist-ui/compare/AnswerPanel.jsx
  • packages/web/src/components/checklist-ui/compare/navbar-utils.js
  • packages/web/src/components/checklist-ui/compare/ReconciliationQuestionPage.jsx
  • packages/web/src/components/checklist-ui/compare/ReconciliationWithPdf.jsx
  • packages/web/src/components/checklist-ui/compare/ChecklistReconciliation.jsx
  • packages/web/src/components/checklist-ui/compare/ReconciliationWrapper.jsx
  • packages/web/src/primitives/useProject/reconciliation.js
**/*.{js,jsx,ts,tsx}

📄 CodeRabbit inference engine (.github/copilot-instructions.md)

**/*.{js,jsx,ts,tsx}: Prefer modern ES6+ syntax and features
Use aliases for imports when appropriate to improve readability

Files:

  • packages/web/src/components/checklist-ui/compare/Navbar.jsx
  • packages/web/src/components/checklist-ui/compare/AnswerPanel.jsx
  • packages/web/src/components/checklist-ui/compare/navbar-utils.js
  • packages/web/src/components/checklist-ui/compare/ReconciliationQuestionPage.jsx
  • packages/web/src/components/checklist-ui/compare/ReconciliationWithPdf.jsx
  • packages/web/src/components/checklist-ui/compare/ChecklistReconciliation.jsx
  • packages/web/src/components/checklist-ui/compare/ReconciliationWrapper.jsx
  • packages/web/src/primitives/useProject/reconciliation.js
packages/web/src/components/**/*.{js,jsx,ts,tsx}

📄 CodeRabbit inference engine (.github/copilot-instructions.md)

packages/web/src/components/**/*.{js,jsx,ts,tsx}: Use responsive design principles for UI components
Group related components in subdirectories with an index.js barrel export
Use Zag.js for UI components and design system
Zag component exist in packages/web/src/components/zag/* and should be reused. Check the README.md in that folder for a list of existing components before adding new components and when debugging
Components should receive at most 1–5 props, and only for local configuration, not shared state. If a component would need more than 5 props, move the shared data into an external store, a primitive, or Solid context
Do not destructure props in SolidJS components as it breaks reactivity. Instead, access props directly from the props object or wrap them in a function to ensure they are always up-to-date
Components should be lean and focused. They should not implement business logic; move that into stores, utilities, or primitives
Never have a component act as a God component coordinating multiple large concerns

Files:

  • packages/web/src/components/checklist-ui/compare/Navbar.jsx
  • packages/web/src/components/checklist-ui/compare/AnswerPanel.jsx
  • packages/web/src/components/checklist-ui/compare/navbar-utils.js
  • packages/web/src/components/checklist-ui/compare/ReconciliationQuestionPage.jsx
  • packages/web/src/components/checklist-ui/compare/ReconciliationWithPdf.jsx
  • packages/web/src/components/checklist-ui/compare/ChecklistReconciliation.jsx
  • packages/web/src/components/checklist-ui/compare/ReconciliationWrapper.jsx
packages/web/src/primitives/**/*.{js,ts}

📄 CodeRabbit inference engine (.github/copilot-instructions.md)

Create reusable logic in primitives (hooks) that can be shared across components to keep components clean and focused on rendering

Files:

  • packages/web/src/primitives/useProject/reconciliation.js
🧠 Learnings (4)
📚 Learning: 2025-12-19T12:38:18.491Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .cursorrules:0-0
Timestamp: 2025-12-19T12:38:18.491Z
Learning: Applies to packages/web/src/components/**/*.{jsx,tsx} : Zag components exist in `packages/web/src/components/zag/*` and should be reused; check the README.md in that folder for a list of existing components before adding new components and when debugging

Applied to files:

  • packages/web/src/components/checklist-ui/compare/Navbar.jsx
📚 Learning: 2025-12-19T12:38:18.491Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .cursorrules:0-0
Timestamp: 2025-12-19T12:38:18.491Z
Learning: Applies to packages/web/src/**/*.{jsx,tsx,js,ts} : When you need to compute a value based on props or state in SolidJS, use `createMemo` to ensure it updates reactively

Applied to files:

  • packages/web/src/components/checklist-ui/compare/Navbar.jsx
📚 Learning: 2025-12-19T12:38:18.491Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .cursorrules:0-0
Timestamp: 2025-12-19T12:38:18.491Z
Learning: Applies to packages/web/src/components/**/*.{jsx,tsx} : Use responsive design principles for UI components

Applied to files:

  • packages/web/src/components/checklist-ui/compare/ReconciliationQuestionPage.jsx
📚 Learning: 2025-12-19T14:49:49.717Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2025-12-19T14:49:49.717Z
Learning: Applies to packages/web/src/components/**/*.{js,jsx,ts,tsx} : Use responsive design principles for UI components

Applied to files:

  • packages/web/src/components/checklist-ui/compare/ReconciliationQuestionPage.jsx
🧬 Code graph analysis (5)
packages/web/src/components/checklist-ui/compare/navbar-utils.js (1)
packages/web/src/components/checklist-ui/compare/Navbar.jsx (3)
  • isCurrentPage (41-42)
  • hasAnswer (46-46)
  • isAgreement (44-44)
packages/web/src/components/checklist-ui/compare/ReconciliationQuestionPage.jsx (3)
packages/web/src/components/checklist-ui/compare/AnswerPanel.jsx (1)
  • question (28-28)
packages/web/src/components/checklist-ui/compare/MultiPartQuestionPage.jsx (2)
  • question (13-13)
  • isCritical (153-159)
packages/web/src/components/checklist-ui/AMSTAR2Checklist.jsx (14)
  • question (10-10)
  • question (41-41)
  • question (74-74)
  • question (105-105)
  • question (140-140)
  • question (170-170)
  • question (200-200)
  • question (234-234)
  • question (269-269)
  • question (371-371)
  • question (402-402)
  • question (501-501)
  • question (539-539)
  • question (569-569)
packages/web/src/components/checklist-ui/compare/ReconciliationWithPdf.jsx (2)
packages/web/src/components/checklist-ui/compare/MultiPartQuestionPage.jsx (1)
  • questionKey (12-12)
packages/web/src/components/checklist-ui/AMSTAR2Checklist.jsx (1)
  • questionKey (669-673)
packages/web/src/components/checklist-ui/compare/ReconciliationWrapper.jsx (2)
packages/web/src/components/project-ui/overview-tab/OverviewTab.jsx (1)
  • getChecklistData (78-80)
packages/web/src/components/checklist-ui/compare/ReconciliationWithPdf.jsx (1)
  • ReconciliationWithPdf (14-216)
packages/web/src/primitives/useProject/reconciliation.js (1)
packages/web/src/primitives/useProject/sync.js (1)
  • reconciliationMap (132-132)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
  • GitHub Check: Workers Builds: corates
🔇 Additional comments (18)
packages/web/src/components/checklist-ui/compare/AnswerPanel.jsx (1)

101-103: LGTM! Clean UI refinements.

The styling adjustments appropriately tighten the layout for the final answer state and consistently scale down the badge to match the text-xs typography. These changes improve visual hierarchy without introducing any functional or reactivity concerns.

Also applies to: 130-130

packages/web/src/components/checklist-ui/compare/ReconciliationQuestionPage.jsx (1)

155-163: LGTM - Typography adjustments are appropriate.

The font size reductions (text-lgtext-md for header, text-smtext-xs for status label) create a more compact UI that aligns with the navbar reconciliation flow changes in this PR.

packages/web/src/components/checklist-ui/compare/Navbar.jsx (1)

38-76: Well-structured QuestionPill component.

Good use of createMemo for derived values (pillStyle, tooltip) ensuring reactive updates. The store pattern avoids prop drilling, and the conditional check badge provides clear visual feedback for answered questions.

packages/web/src/components/checklist-ui/compare/navbar-utils.js (1)

56-67: Tooltip logic correctly uses hasAnswer for descriptive text.

The tooltip function appropriately differentiates between "Reconciled", "Reviewers agreed", and "Reviewers disagree" states, providing clear user feedback.

packages/web/src/components/checklist-ui/compare/ReconciliationWithPdf.jsx (1)

160-174: Props correctly wired for reconciled checklist flow.

The component properly forwards the new reconciliation props (reconciledChecklist, reconciledChecklistId, getQuestionNote, updateChecklistAnswer) to ChecklistReconciliation, aligning with the updated data model in this PR.

packages/web/src/primitives/useProject/reconciliation.js (1)

43-45: Conditional storage pattern is appropriate.

Only storing reconciledChecklistId when truthy prevents orphaned empty entries in the Y.Map. The getter correctly handles this with || null fallback on line 74.

packages/web/src/components/checklist-ui/compare/ChecklistReconciliation.jsx (4)

38-84: LGTM! Navigation state persistence is well-implemented.

The localStorage implementation properly:

  • Guards against missing checklist IDs
  • Handles errors gracefully
  • Initializes state on mount only when data is available
  • Saves state reactively when it changes

115-145: LGTM! Reactive finalAnswers derivation is correct.

The memo properly:

  • Derives from Yjs-backed reconciledChecklist for reactive updates
  • Handles multi-part questions by nesting parts under parent keys
  • Guards against missing data

224-242: LGTM! Direct Yjs write via updateChecklistAnswer is correct.

The function properly:

  • Guards against missing updateChecklistAnswer prop
  • Handles multi-part questions by writing each part separately
  • Relies on Yjs reactive sync (no local state mutation needed)

284-314: LGTM! Reset logic correctly clears all answers.

The function:

  • Uses dynamic import for code splitting
  • Creates a temporary checklist to obtain the default empty structure
  • Properly handles multi-part questions
  • Writes defaults via updateChecklistAnswer to sync with Yjs

The approach of creating a temporary checklist to get defaults is indirect but functional.

packages/web/src/components/checklist-ui/compare/ReconciliationWrapper.jsx (8)

205-285: LGTM! Reconciled checklist initialization is well-designed.

The effect properly:

  • Guards against re-running with hasCheckedForReconciled flag
  • Checks reconciliation progress first to reuse existing ID
  • Verifies checklist still exists in study before using cached ID
  • Checks study checklists for existing reconciled checklist from other clients
  • Creates new reconciled checklist only if none exists
  • Updates metadata and progress atomically
  • Handles errors gracefully

The logic prevents duplicate checklist creation while supporting concurrent clients.


287-316: LGTM! Race condition prevention is well-implemented.

The effect properly:

  • Watches for store updates reactively
  • Filters out completed reconciled checklists
  • Deterministically selects the earliest created checklist when multiple exist
  • Updates progress to maintain consistency across clients

This handles concurrent checklist creation gracefully.


318-344: LGTM! Reconciled checklist data handling is consistent.

The memos:

  • Follow the same pattern as checklist1Data and checklist2Data
  • Properly guard against missing ID or data
  • Flatten answers into the expected format

346-351: LGTM! Reviewer name lookup is defensive.

The function properly:

  • Looks up member by userId
  • Provides multiple fallback options (displayName → name → email → 'Unknown')
  • Handles unassigned case

353-377: LGTM! Save handler properly finalizes reconciliation.

The function:

  • Guards against missing reconciled checklist ID
  • Updates checklist status to completed with custom title
  • Clears reconciliation progress after completion
  • Navigates to completed tab
  • Has proper error handling

410-416: LGTM! Render condition properly gates on all required data.

The condition ensures:

  • Connection is synced
  • Both checklists are loaded
  • Reconciled checklist setup is complete
  • Reconciled checklist ID is available

421-425: LGTM! Differentiated loading messages improve UX.

The conditional message:

  • Shows "Setting up reconciliation..." during reconciled checklist creation/selection
  • Shows "Loading checklists..." during data loading
  • Helps users understand the loading state

445-452: LGTM! Props are correctly wired to child components.

The prop functions:

  • Bind studyId and reconciledChecklistId for convenience
  • Guard against missing ID in updateChecklistAnswer
  • Provide clean API for child components

Comment on lines +40 to +46
// Save the progress data (minimal - just references)
reconciliationMap.set('checklist1Id', progressData.checklist1Id);
reconciliationMap.set('checklist2Id', progressData.checklist2Id);
reconciliationMap.set('currentPage', progressData.currentPage);
reconciliationMap.set('viewMode', progressData.viewMode || 'questions');
reconciliationMap.set('updatedAt', Date.now());

// Store finalAnswers as a nested Y.Map for collaborative editing
let finalAnswersMap = reconciliationMap.get('finalAnswers');
if (!finalAnswersMap || !(finalAnswersMap instanceof Y.Map)) {
finalAnswersMap = new Y.Map();
reconciliationMap.set('finalAnswers', finalAnswersMap);
if (progressData.reconciledChecklistId) {
reconciliationMap.set('reconciledChecklistId', progressData.reconciledChecklistId);
}

// Update each question's answers
const finalAnswers = progressData.finalAnswers || {};
Object.entries(finalAnswers).forEach(([questionKey, questionData]) => {
let questionYMap = finalAnswersMap.get(questionKey);
if (!questionYMap || !(questionYMap instanceof Y.Map)) {
questionYMap = new Y.Map();
finalAnswersMap.set(questionKey, questionYMap);
}

// Store answers and critical flag
if (questionData.answers !== undefined) {
questionYMap.set('answers', questionData.answers);
}
if (questionData.critical !== undefined) {
questionYMap.set('critical', questionData.critical);
}

// Initialize Y.Text for note if not present (for collaborative editing)
if (!questionYMap.get('note')) {
questionYMap.set('note', new Y.Text());
}
});
reconciliationMap.set('updatedAt', Date.now());
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟠 Major

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Find all usages of saveReconciliationProgress
rg -n 'saveReconciliationProgress' --type=js --type=ts -B 2 -A 8

Repository: InfinityBowman/corates

Length of output: 13208


Update tests to use the new saveReconciliationProgress signature.

Production code in ReconciliationWrapper.jsx correctly uses the new signature { checklist1Id, checklist2Id, reconciledChecklistId }. However, tests in useProject.test.js still pass the old shape with currentPage, viewMode, and finalAnswers (lines 510–516, 531–537, 574–579). Update these test calls to only include checklist1Id, checklist2Id, and reconciledChecklistId.

🤖 Prompt for AI Agents
In packages/web/src/primitives/useProject/reconciliation.js around lines 40–46
and in tests at packages/web/src/__tests__/useProject.test.js around lines
510–516, 531–537, and 574–579, update the test calls to match the new
saveReconciliationProgress signature; replace objects that pass the old shape
(currentPage, viewMode, finalAnswers) with an object containing only
checklist1Id, checklist2Id, and reconciledChecklistId (use null or undefined for
reconciledChecklistId when not applicable) so tests mirror the production call
site pattern { checklist1Id, checklist2Id, reconciledChecklistId }.

Comment on lines 71 to 77
return {
checklist1Id,
checklist2Id,
currentPage: reconciliationMap.get('currentPage') || 0,
viewMode: reconciliationMap.get('viewMode') || 'questions',
finalAnswers,
reconciledChecklistId: reconciliationMap.get('reconciledChecklistId') || null,
updatedAt: reconciliationMap.get('updatedAt'),
};
}
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🔴 Critical

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Find usages of getReconciliationProgress and the file itself
rg -n "getReconciliationProgress" packages/web/src --type=js --type=ts

Repository: InfinityBowman/corates

Length of output: 1419


🏁 Script executed:

#!/bin/bash
# Read the reconciliation.js file to see the function implementation
cat -n packages/web/src/primitives/useProject/reconciliation.js

Repository: InfinityBowman/corates

Length of output: 4098


🏁 Script executed:

#!/bin/bash
# Read ReconciliationWrapper.jsx to see how it uses getReconciliationProgress
sed -n '210,250p' packages/web/src/components/checklist-ui/compare/ReconciliationWrapper.jsx

Repository: InfinityBowman/corates

Length of output: 1547


🏁 Script executed:

#!/bin/bash
# Check the test file to see what return shapes are expected
sed -n '535,595p' packages/web/src/primitives/__tests__/useProject.test.js

Repository: InfinityBowman/corates

Length of output: 1880


🏁 Script executed:

#!/bin/bash
# Let's check when and how the test was written relative to the implementation
# Look for any other consumers that might still use old fields
rg -n "currentPage|viewMode|finalAnswers" packages/web/src/components/checklist-ui/compare/ --type=js --type=jsx -A 2 -B 2

Repository: InfinityBowman/corates

Length of output: 93


🏁 Script executed:

#!/bin/bash
# Search for old field references in the compare components
rg -n "currentPage|viewMode|finalAnswers" packages/web/src/components/checklist-ui/compare/ -A 2 -B 2

Repository: InfinityBowman/corates

Length of output: 22601


🏁 Script executed:

#!/bin/bash
# Let's look at the full test case that's checking the old fields
sed -n '525,560p' packages/web/src/primitives/__tests__/useProject.test.js

Repository: InfinityBowman/corates

Length of output: 1237


🏁 Script executed:

#!/bin/bash
# Check how saveReconciliationProgress is called in the test file - does it use old fields?
sed -n '530,545p' packages/web/src/primitives/__tests__/useProject.test.js

Repository: InfinityBowman/corates

Length of output: 613


🏁 Script executed:

#!/bin/bash
# Check if there are any other calls to saveReconciliationProgress with the old fields
rg -n "saveReconciliationProgress" packages/web/src --type=js -A 5 | head -50

Repository: InfinityBowman/corates

Length of output: 4445


🏁 Script executed:

#!/bin/bash
# Let's verify the final piece - check the stores/projectActionsStore/reconciliation.js to see if it wraps the function differently
cat -n packages/web/src/stores/projectActionsStore/reconciliation.js

Repository: InfinityBowman/corates

Length of output: 1475


Return shape changed - update tests and verify parameter consistency.

The return object now includes reconciledChecklistId instead of currentPage, viewMode, and finalAnswers. While ReconciliationWrapper.jsx correctly handles the new shape, the test expectations in useProject.test.js (lines 539-548) are outdated and expect the old fields that no longer exist. Additionally, the store wrapper in projectActionsStore/reconciliation.js calls this function with 3 parameters, but the actual implementation only accepts 1 parameter (studyId).

🤖 Prompt for AI Agents
In packages/web/src/primitives/useProject/reconciliation.js around lines 71 to
77, the hook now returns reconciledChecklistId and updatedAt instead of
currentPage, viewMode, and finalAnswers; update the tests and call sites to
match this new shape and parameter signature: change useProject.test.js (lines
~539-548) to assert for checklist1Id, checklist2Id, reconciledChecklistId (or
null) and updatedAt instead of the removed fields, and in
projectActionsStore/reconciliation.js adjust the call to this function to pass
only studyId (or update the function signature to accept the three parameters if
intended) so the number of arguments matches the implementation — ensure all
references expecting currentPage/viewMode/finalAnswers are removed or migrated
to use reconciledChecklistId/updatedAt.

Copy link
Copy Markdown

@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 (1)
packages/web/src/components/project-ui/reconcile-tab/ReconcileTab.jsx (1)

25-47: Duplicate reconciliation filtering logic.

This filtering logic is identical to getReconcileCount in ProjectView.jsx (lines 194-211). See the review comment on that file for the refactoring recommendation to extract this shared logic into a utility or primitive.

📜 Review details

Configuration used: defaults

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 674b7de and b0b0240.

📒 Files selected for processing (3)
  • packages/ui/src/zag/Tooltip.jsx (2 hunks)
  • packages/web/src/components/project-ui/ProjectView.jsx (1 hunks)
  • packages/web/src/components/project-ui/reconcile-tab/ReconcileTab.jsx (1 hunks)
🧰 Additional context used
📓 Path-based instructions (10)
**/*

📄 CodeRabbit inference engine (.cursorrules)

Do not use emojis in code, comments, documentation, or commit messages

Files:

  • packages/web/src/components/project-ui/reconcile-tab/ReconcileTab.jsx
  • packages/ui/src/zag/Tooltip.jsx
  • packages/web/src/components/project-ui/ProjectView.jsx
packages/web/src/**/*.{jsx,tsx,js,ts}

📄 CodeRabbit inference engine (.cursorrules)

packages/web/src/**/*.{jsx,tsx,js,ts}: For UI icons, use the solid-icons library or SVGs only. Do not use emojis
Import stores directly where needed instead of passing values through multiple components
When you need to compute a value based on props or state in SolidJS, use createMemo to ensure it updates reactively
For complex state or state objects in SolidJS, use Solid's createStore for better performance and reactivity
You may create reusable logic in 'primitives' (hooks) that can be shared across components to keep components clean and focused on rendering

Files:

  • packages/web/src/components/project-ui/reconcile-tab/ReconcileTab.jsx
  • packages/web/src/components/project-ui/ProjectView.jsx
packages/**/*.{js,jsx,ts,tsx}

📄 CodeRabbit inference engine (.cursorrules)

packages/**/*.{js,jsx,ts,tsx}: Prefer modern ES6+ syntax and features
Use aliases for imports when appropriate to improve readability
Prefer using config files rather than hardcoding values
Keep files small, focused, and modular. If a file exceeds a high number of lines, consider refactoring by extracting sub-modules into a folder with index.jsx and helper components, moving complex logic into separate utility files or primitives, or splitting large forms into section components
Each file should handle one coherent responsibility
Use Zod for schema and input validation

Files:

  • packages/web/src/components/project-ui/reconcile-tab/ReconcileTab.jsx
  • packages/ui/src/zag/Tooltip.jsx
  • packages/web/src/components/project-ui/ProjectView.jsx
packages/web/src/components/**/*.{jsx,tsx}

📄 CodeRabbit inference engine (.cursorrules)

packages/web/src/components/**/*.{jsx,tsx}: Use responsive design principles for UI components
Use Zag.js for UI components and design system
Zag components exist in packages/web/src/components/zag/* and should be reused; check the README.md in that folder for a list of existing components before adding new components and when debugging
Components should receive at most 1–5 props, and only for local configuration, not shared state
If a component would need more than 5 props, move the shared data into an external store, a primitive, or Solid context
Components should be lean and focused and should not implement business logic; move business logic into stores, utilities, or primitives
Never have a component act as a 'God component' coordinating multiple large concerns

Files:

  • packages/web/src/components/project-ui/reconcile-tab/ReconcileTab.jsx
  • packages/web/src/components/project-ui/ProjectView.jsx
packages/web/src/**/*.{jsx,tsx,js,ts,css}

📄 CodeRabbit inference engine (.cursorrules)

Ensure browser compatibility for all frontend code (Safari is usually problematic)

Files:

  • packages/web/src/components/project-ui/reconcile-tab/ReconcileTab.jsx
  • packages/web/src/components/project-ui/ProjectView.jsx
packages/web/src/components/**/*.{jsx,tsx,js}

📄 CodeRabbit inference engine (.cursorrules)

Group related components in subdirectories with an index.js barrel export

Files:

  • packages/web/src/components/project-ui/reconcile-tab/ReconcileTab.jsx
  • packages/web/src/components/project-ui/ProjectView.jsx
packages/web/src/**/*.{jsx,tsx}

📄 CodeRabbit inference engine (.cursorrules)

packages/web/src/**/*.{jsx,tsx}: Do NOT prop-drill application state. Shared or cross-feature state must live in external stores under packages/web/src/stores/ or relative to the component file
Do not destructure props in SolidJS components as it breaks reactivity. Instead, access props directly from the props object or wrap them in a function to ensure they are always up-to-date

Files:

  • packages/web/src/components/project-ui/reconcile-tab/ReconcileTab.jsx
  • packages/web/src/components/project-ui/ProjectView.jsx
packages/web/src/**/*.{js,jsx,ts,tsx}

📄 CodeRabbit inference engine (.github/copilot-instructions.md)

packages/web/src/**/*.{js,jsx,ts,tsx}: For UI icons, use the solid-icons library or SVGs only. Do not use emojis
Ensure browser compatibility for all frontend code (Safari is usually problematic)
Keep files small, focused, and modular. If a file exceeds a high number of lines, consider refactoring by extracting sub-modules into a folder with index.jsx and helper components, moving complex logic into separate utility files or primitives, or splitting large forms into section components
Do NOT prop-drill application state. Shared or cross-feature state must live in external stores under packages/web/src/stores/ or relative to the component file
Use createMemo for derived values to ensure they update reactively

Files:

  • packages/web/src/components/project-ui/reconcile-tab/ReconcileTab.jsx
  • packages/web/src/components/project-ui/ProjectView.jsx
**/*.{js,jsx,ts,tsx}

📄 CodeRabbit inference engine (.github/copilot-instructions.md)

**/*.{js,jsx,ts,tsx}: Prefer modern ES6+ syntax and features
Use aliases for imports when appropriate to improve readability

Files:

  • packages/web/src/components/project-ui/reconcile-tab/ReconcileTab.jsx
  • packages/ui/src/zag/Tooltip.jsx
  • packages/web/src/components/project-ui/ProjectView.jsx
packages/web/src/components/**/*.{js,jsx,ts,tsx}

📄 CodeRabbit inference engine (.github/copilot-instructions.md)

packages/web/src/components/**/*.{js,jsx,ts,tsx}: Use responsive design principles for UI components
Group related components in subdirectories with an index.js barrel export
Use Zag.js for UI components and design system
Zag component exist in packages/web/src/components/zag/* and should be reused. Check the README.md in that folder for a list of existing components before adding new components and when debugging
Components should receive at most 1–5 props, and only for local configuration, not shared state. If a component would need more than 5 props, move the shared data into an external store, a primitive, or Solid context
Do not destructure props in SolidJS components as it breaks reactivity. Instead, access props directly from the props object or wrap them in a function to ensure they are always up-to-date
Components should be lean and focused. They should not implement business logic; move that into stores, utilities, or primitives
Never have a component act as a God component coordinating multiple large concerns

Files:

  • packages/web/src/components/project-ui/reconcile-tab/ReconcileTab.jsx
  • packages/web/src/components/project-ui/ProjectView.jsx
🧬 Code graph analysis (2)
packages/web/src/components/project-ui/reconcile-tab/ReconcileTab.jsx (2)
packages/web/src/components/project-ui/reconcile-tab/ReconcileStudyCard.jsx (1)
  • completedChecklists (17-19)
packages/web/src/components/project-ui/reconcile-tab/ReconcileStatusTag.jsx (1)
  • completedChecklists (11-12)
packages/web/src/components/project-ui/ProjectView.jsx (3)
packages/web/src/primitives/useProject/sync.js (1)
  • study (59-88)
packages/web/src/components/project-ui/reconcile-tab/ReconcileStudyCard.jsx (1)
  • completedChecklists (17-19)
packages/web/src/components/project-ui/reconcile-tab/ReconcileStatusTag.jsx (1)
  • completedChecklists (11-12)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
  • GitHub Check: Workers Builds: corates
🔇 Additional comments (2)
packages/ui/src/zag/Tooltip.jsx (2)

4-4: LGTM! Portal import added correctly.

The Portal import is necessary for rendering the tooltip outside the normal DOM hierarchy to avoid stacking context issues.


7-17: Clarify the purpose of the fixed positioning strategy.

The fixed positioning strategy is supported by zag-js and is a valid approach for tooltips. However, the comment conflates two separate CSS concepts. Fixed strategy positions the floating element relative to its nearest containing block (usually the viewport), which is useful when the reference element is also fixed and will "break" the floating element out of a clipping ancestor. This benefit relates to escaping clipping contexts (overflow boundaries), not z-index stacking contexts, which are different mechanisms. Consider revising the comment to reference "clipping ancestors" or "overflow boundaries" for technical accuracy.

Likely an incorrect or invalid review comment.

Comment thread packages/ui/src/zag/Tooltip.jsx
Comment thread packages/web/src/components/project-ui/ProjectView.jsx Outdated
Copy link
Copy Markdown

@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 (2)
packages/web/src/components/checklist-ui/compare/ReconciliationWithPdf.jsx (2)

50-79: Header construction looks good; consider adding aria-label for accessibility.

The header content is well-structured with appropriate icon usage from solid-icons, good null safety with optional chaining, and proper reactive prop access.

Optional: Enhance accessibility of back button

Consider adding an aria-label to the back button for better screen reader support:

 <button
   onClick={() => props.onCancel?.()}
   class='shrink-0 rounded-lg p-2 transition-colors hover:bg-gray-100'
   title='Go back'
+  aria-label='Go back to previous page'
 >

14-30: Consider refactoring to reduce prop count.

This component receives 16 props, which significantly exceeds the coding guideline of 1-5 props per component. While the component functions correctly, this high prop count increases coupling and maintenance burden.

Consider grouping related props into stores or configuration objects:

  • Reconciliation data: reconciledChecklist, reconciledChecklistId, checklist1, checklist2, getQuestionNote, updateChecklistAnswerreconciliationStore
  • PDF data: pdfData, pdfFileName, pdfLoading, pdfs, selectedPdfId, onPdfSelectpdfStore or pdfConfig
  • UI config: reviewer1Name, reviewer2Name, onSaveReconciled, onCanceluiConfig or context

As per coding guidelines: "If a component would need more than 5 props, move the shared data into an external store, a primitive, or Solid context."

📜 Review details

Configuration used: defaults

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between b0b0240 and f3faaf3.

📒 Files selected for processing (1)
  • packages/web/src/components/checklist-ui/compare/ReconciliationWithPdf.jsx (3 hunks)
🧰 Additional context used
📓 Path-based instructions (10)
**/*

📄 CodeRabbit inference engine (.cursorrules)

Do not use emojis in code, comments, documentation, or commit messages

Files:

  • packages/web/src/components/checklist-ui/compare/ReconciliationWithPdf.jsx
packages/web/src/**/*.{jsx,tsx,js,ts}

📄 CodeRabbit inference engine (.cursorrules)

packages/web/src/**/*.{jsx,tsx,js,ts}: For UI icons, use the solid-icons library or SVGs only. Do not use emojis
Import stores directly where needed instead of passing values through multiple components
When you need to compute a value based on props or state in SolidJS, use createMemo to ensure it updates reactively
For complex state or state objects in SolidJS, use Solid's createStore for better performance and reactivity
You may create reusable logic in 'primitives' (hooks) that can be shared across components to keep components clean and focused on rendering

Files:

  • packages/web/src/components/checklist-ui/compare/ReconciliationWithPdf.jsx
packages/**/*.{js,jsx,ts,tsx}

📄 CodeRabbit inference engine (.cursorrules)

packages/**/*.{js,jsx,ts,tsx}: Prefer modern ES6+ syntax and features
Use aliases for imports when appropriate to improve readability
Prefer using config files rather than hardcoding values
Keep files small, focused, and modular. If a file exceeds a high number of lines, consider refactoring by extracting sub-modules into a folder with index.jsx and helper components, moving complex logic into separate utility files or primitives, or splitting large forms into section components
Each file should handle one coherent responsibility
Use Zod for schema and input validation

Files:

  • packages/web/src/components/checklist-ui/compare/ReconciliationWithPdf.jsx
packages/web/src/components/**/*.{jsx,tsx}

📄 CodeRabbit inference engine (.cursorrules)

packages/web/src/components/**/*.{jsx,tsx}: Use responsive design principles for UI components
Use Zag.js for UI components and design system
Zag components exist in packages/web/src/components/zag/* and should be reused; check the README.md in that folder for a list of existing components before adding new components and when debugging
Components should receive at most 1–5 props, and only for local configuration, not shared state
If a component would need more than 5 props, move the shared data into an external store, a primitive, or Solid context
Components should be lean and focused and should not implement business logic; move business logic into stores, utilities, or primitives
Never have a component act as a 'God component' coordinating multiple large concerns

Files:

  • packages/web/src/components/checklist-ui/compare/ReconciliationWithPdf.jsx
packages/web/src/**/*.{jsx,tsx,js,ts,css}

📄 CodeRabbit inference engine (.cursorrules)

Ensure browser compatibility for all frontend code (Safari is usually problematic)

Files:

  • packages/web/src/components/checklist-ui/compare/ReconciliationWithPdf.jsx
packages/web/src/components/**/*.{jsx,tsx,js}

📄 CodeRabbit inference engine (.cursorrules)

Group related components in subdirectories with an index.js barrel export

Files:

  • packages/web/src/components/checklist-ui/compare/ReconciliationWithPdf.jsx
packages/web/src/**/*.{jsx,tsx}

📄 CodeRabbit inference engine (.cursorrules)

packages/web/src/**/*.{jsx,tsx}: Do NOT prop-drill application state. Shared or cross-feature state must live in external stores under packages/web/src/stores/ or relative to the component file
Do not destructure props in SolidJS components as it breaks reactivity. Instead, access props directly from the props object or wrap them in a function to ensure they are always up-to-date

Files:

  • packages/web/src/components/checklist-ui/compare/ReconciliationWithPdf.jsx
packages/web/src/**/*.{js,jsx,ts,tsx}

📄 CodeRabbit inference engine (.github/copilot-instructions.md)

packages/web/src/**/*.{js,jsx,ts,tsx}: For UI icons, use the solid-icons library or SVGs only. Do not use emojis
Ensure browser compatibility for all frontend code (Safari is usually problematic)
Keep files small, focused, and modular. If a file exceeds a high number of lines, consider refactoring by extracting sub-modules into a folder with index.jsx and helper components, moving complex logic into separate utility files or primitives, or splitting large forms into section components
Do NOT prop-drill application state. Shared or cross-feature state must live in external stores under packages/web/src/stores/ or relative to the component file
Use createMemo for derived values to ensure they update reactively

Files:

  • packages/web/src/components/checklist-ui/compare/ReconciliationWithPdf.jsx
**/*.{js,jsx,ts,tsx}

📄 CodeRabbit inference engine (.github/copilot-instructions.md)

**/*.{js,jsx,ts,tsx}: Prefer modern ES6+ syntax and features
Use aliases for imports when appropriate to improve readability

Files:

  • packages/web/src/components/checklist-ui/compare/ReconciliationWithPdf.jsx
packages/web/src/components/**/*.{js,jsx,ts,tsx}

📄 CodeRabbit inference engine (.github/copilot-instructions.md)

packages/web/src/components/**/*.{js,jsx,ts,tsx}: Use responsive design principles for UI components
Group related components in subdirectories with an index.js barrel export
Use Zag.js for UI components and design system
Zag component exist in packages/web/src/components/zag/* and should be reused. Check the README.md in that folder for a list of existing components before adding new components and when debugging
Components should receive at most 1–5 props, and only for local configuration, not shared state. If a component would need more than 5 props, move the shared data into an external store, a primitive, or Solid context
Do not destructure props in SolidJS components as it breaks reactivity. Instead, access props directly from the props object or wrap them in a function to ensure they are always up-to-date
Components should be lean and focused. They should not implement business logic; move that into stores, utilities, or primitives
Never have a component act as a God component coordinating multiple large concerns

Files:

  • packages/web/src/components/checklist-ui/compare/ReconciliationWithPdf.jsx
🧠 Learnings (1)
📓 Common learnings
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .cursorrules:0-0
Timestamp: 2025-12-19T12:38:18.491Z
Learning: Applies to packages/web/src/**/*.{jsx,tsx,js,ts,css} : Ensure browser compatibility for all frontend code (Safari is usually problematic)
🧬 Code graph analysis (1)
packages/web/src/components/checklist-ui/compare/ReconciliationWithPdf.jsx (4)
packages/web/src/components/checklist-ui/compare/Navbar.jsx (1)
  • Navbar (23-33)
packages/web/src/components/checklist-ui/SplitScreenLayout.jsx (1)
  • SplitScreenLayout (9-136)
packages/web/src/components/checklist-ui/compare/ChecklistReconciliation.jsx (1)
  • ChecklistReconciliation (19-462)
packages/web/src/components/checklist-ui/pdf/PdfViewer.jsx (1)
  • PdfViewer (17-116)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
  • GitHub Check: Workers Builds: corates
🔇 Additional comments (3)
packages/web/src/components/checklist-ui/compare/ReconciliationWithPdf.jsx (3)

6-6: LGTM: Imports are appropriate.

The addition of createMemo for reactive derived values and SplitScreenLayout for simplified layout management are both correct and align with the refactoring objectives.

Also applies to: 12-12


47-48: LGTM: Correct use of createMemo for reactive derived value.

The hasPdf memo properly tracks whether the PDF panel should be shown, ensuring reactive updates when pdfData or pdfLoading change. This follows the coding guideline to use createMemo for derived values.


83-130: LGTM: SplitScreenLayout integration is well-implemented.

The refactoring to use SplitScreenLayout simplifies the code by removing custom split-view logic. The conditional rendering, prop forwarding, and loading states are all correctly implemented. The inline arrow function at lines 102-104 is acceptable in SolidJS contexts.

Copy link
Copy Markdown

@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)
packages/web/src/components/checklist-ui/SplitScreenLayout.jsx (1)

107-111: Consider specifying transition properties for better performance.

Using transition-all transitions every animatable CSS property. Since only width or height changes here, specifying the exact properties can improve performance, especially on lower-end devices.

Suggested improvement
-          class='overflow-auto transition-all duration-300 ease-in-out'
+          class='overflow-auto transition-[width,height] duration-300 ease-in-out'
📜 Review details

Configuration used: defaults

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between f3faaf3 and eb55b8c.

📒 Files selected for processing (1)
  • packages/web/src/components/checklist-ui/SplitScreenLayout.jsx (2 hunks)
🧰 Additional context used
📓 Path-based instructions (10)
**/*

📄 CodeRabbit inference engine (.cursorrules)

Do not use emojis in code, comments, documentation, or commit messages

Files:

  • packages/web/src/components/checklist-ui/SplitScreenLayout.jsx
packages/web/src/**/*.{jsx,tsx,js,ts}

📄 CodeRabbit inference engine (.cursorrules)

packages/web/src/**/*.{jsx,tsx,js,ts}: For UI icons, use the solid-icons library or SVGs only. Do not use emojis
Import stores directly where needed instead of passing values through multiple components
When you need to compute a value based on props or state in SolidJS, use createMemo to ensure it updates reactively
For complex state or state objects in SolidJS, use Solid's createStore for better performance and reactivity
You may create reusable logic in 'primitives' (hooks) that can be shared across components to keep components clean and focused on rendering

Files:

  • packages/web/src/components/checklist-ui/SplitScreenLayout.jsx
packages/**/*.{js,jsx,ts,tsx}

📄 CodeRabbit inference engine (.cursorrules)

packages/**/*.{js,jsx,ts,tsx}: Prefer modern ES6+ syntax and features
Use aliases for imports when appropriate to improve readability
Prefer using config files rather than hardcoding values
Keep files small, focused, and modular. If a file exceeds a high number of lines, consider refactoring by extracting sub-modules into a folder with index.jsx and helper components, moving complex logic into separate utility files or primitives, or splitting large forms into section components
Each file should handle one coherent responsibility
Use Zod for schema and input validation

Files:

  • packages/web/src/components/checklist-ui/SplitScreenLayout.jsx
packages/web/src/components/**/*.{jsx,tsx}

📄 CodeRabbit inference engine (.cursorrules)

packages/web/src/components/**/*.{jsx,tsx}: Use responsive design principles for UI components
Use Zag.js for UI components and design system
Zag components exist in packages/web/src/components/zag/* and should be reused; check the README.md in that folder for a list of existing components before adding new components and when debugging
Components should receive at most 1–5 props, and only for local configuration, not shared state
If a component would need more than 5 props, move the shared data into an external store, a primitive, or Solid context
Components should be lean and focused and should not implement business logic; move business logic into stores, utilities, or primitives
Never have a component act as a 'God component' coordinating multiple large concerns

Files:

  • packages/web/src/components/checklist-ui/SplitScreenLayout.jsx
packages/web/src/**/*.{jsx,tsx,js,ts,css}

📄 CodeRabbit inference engine (.cursorrules)

Ensure browser compatibility for all frontend code (Safari is usually problematic)

Files:

  • packages/web/src/components/checklist-ui/SplitScreenLayout.jsx
packages/web/src/components/**/*.{jsx,tsx,js}

📄 CodeRabbit inference engine (.cursorrules)

Group related components in subdirectories with an index.js barrel export

Files:

  • packages/web/src/components/checklist-ui/SplitScreenLayout.jsx
packages/web/src/**/*.{jsx,tsx}

📄 CodeRabbit inference engine (.cursorrules)

packages/web/src/**/*.{jsx,tsx}: Do NOT prop-drill application state. Shared or cross-feature state must live in external stores under packages/web/src/stores/ or relative to the component file
Do not destructure props in SolidJS components as it breaks reactivity. Instead, access props directly from the props object or wrap them in a function to ensure they are always up-to-date

Files:

  • packages/web/src/components/checklist-ui/SplitScreenLayout.jsx
packages/web/src/**/*.{js,jsx,ts,tsx}

📄 CodeRabbit inference engine (.github/copilot-instructions.md)

packages/web/src/**/*.{js,jsx,ts,tsx}: For UI icons, use the solid-icons library or SVGs only. Do not use emojis
Ensure browser compatibility for all frontend code (Safari is usually problematic)
Keep files small, focused, and modular. If a file exceeds a high number of lines, consider refactoring by extracting sub-modules into a folder with index.jsx and helper components, moving complex logic into separate utility files or primitives, or splitting large forms into section components
Do NOT prop-drill application state. Shared or cross-feature state must live in external stores under packages/web/src/stores/ or relative to the component file
Use createMemo for derived values to ensure they update reactively

Files:

  • packages/web/src/components/checklist-ui/SplitScreenLayout.jsx
**/*.{js,jsx,ts,tsx}

📄 CodeRabbit inference engine (.github/copilot-instructions.md)

**/*.{js,jsx,ts,tsx}: Prefer modern ES6+ syntax and features
Use aliases for imports when appropriate to improve readability

Files:

  • packages/web/src/components/checklist-ui/SplitScreenLayout.jsx
packages/web/src/components/**/*.{js,jsx,ts,tsx}

📄 CodeRabbit inference engine (.github/copilot-instructions.md)

packages/web/src/components/**/*.{js,jsx,ts,tsx}: Use responsive design principles for UI components
Group related components in subdirectories with an index.js barrel export
Use Zag.js for UI components and design system
Zag component exist in packages/web/src/components/zag/* and should be reused. Check the README.md in that folder for a list of existing components before adding new components and when debugging
Components should receive at most 1–5 props, and only for local configuration, not shared state. If a component would need more than 5 props, move the shared data into an external store, a primitive, or Solid context
Do not destructure props in SolidJS components as it breaks reactivity. Instead, access props directly from the props object or wrap them in a function to ensure they are always up-to-date
Components should be lean and focused. They should not implement business logic; move that into stores, utilities, or primitives
Never have a component act as a God component coordinating multiple large concerns

Files:

  • packages/web/src/components/checklist-ui/SplitScreenLayout.jsx
🧠 Learnings (3)
📓 Common learnings
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .cursorrules:0-0
Timestamp: 2025-12-19T12:38:18.491Z
Learning: Applies to packages/web/src/**/*.{jsx,tsx,js,ts,css} : Ensure browser compatibility for all frontend code (Safari is usually problematic)
📚 Learning: 2025-12-19T12:38:18.491Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .cursorrules:0-0
Timestamp: 2025-12-19T12:38:18.491Z
Learning: Applies to packages/web/src/components/**/*.{jsx,tsx} : Use responsive design principles for UI components

Applied to files:

  • packages/web/src/components/checklist-ui/SplitScreenLayout.jsx
📚 Learning: 2025-12-19T14:49:49.717Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2025-12-19T14:49:49.717Z
Learning: Applies to packages/web/src/components/**/*.{js,jsx,ts,tsx} : Use responsive design principles for UI components

Applied to files:

  • packages/web/src/components/checklist-ui/SplitScreenLayout.jsx
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
  • GitHub Check: Workers Builds: corates
🔇 Additional comments (2)
packages/web/src/components/checklist-ui/SplitScreenLayout.jsx (2)

116-127: LGTM - Clean divider animation implementation.

The divider correctly animates its visibility with opacity, pointer-events, and dimension transitions. Setting width/height to undefined when visible properly defers to the CSS class dimensions (w-1/h-1).


129-145: Good animation implementation with GPU-accelerated transforms.

The slide animation using transform is well-suited for smooth performance and Safari compatibility. The inner wrapper div on line 143 properly ensures the second panel content scrolls independently. The combined opacity, dimension, and transform transitions create a polished show/hide effect.

Copy link
Copy Markdown

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

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between eb55b8c and bba6c35.

📒 Files selected for processing (15)
  • packages/ui/src/constants/zIndex.js (1 hunks)
  • packages/ui/src/index.js (1 hunks)
  • packages/ui/src/zag/Combobox.jsx (2 hunks)
  • packages/ui/src/zag/Dialog.jsx (3 hunks)
  • packages/ui/src/zag/Drawer.jsx (2 hunks)
  • packages/ui/src/zag/Menu.jsx (2 hunks)
  • packages/ui/src/zag/Popover.jsx (2 hunks)
  • packages/ui/src/zag/Toast.jsx (2 hunks)
  • packages/ui/src/zag/Tooltip.jsx (2 hunks)
  • packages/ui/src/zag/Tour.jsx (2 hunks)
  • packages/web/src/components/admin-ui/ImpersonationBanner.jsx (2 hunks)
  • packages/web/src/components/charts/ChartSettingsModal.jsx (2 hunks)
  • packages/web/src/components/project-ui/ProjectView.jsx (2 hunks)
  • packages/web/src/components/project-ui/reconcile-tab/ReconcileTab.jsx (2 hunks)
  • packages/web/src/utils/reconciliation.js (1 hunks)
🚧 Files skipped from review as they are similar to previous changes (2)
  • packages/ui/src/zag/Tooltip.jsx
  • packages/web/src/components/project-ui/reconcile-tab/ReconcileTab.jsx
🧰 Additional context used
📓 Path-based instructions (10)
**/*

📄 CodeRabbit inference engine (.cursorrules)

Do not use emojis in code, comments, documentation, or commit messages

Files:

  • packages/ui/src/zag/Menu.jsx
  • packages/ui/src/constants/zIndex.js
  • packages/ui/src/zag/Dialog.jsx
  • packages/ui/src/zag/Toast.jsx
  • packages/web/src/components/project-ui/ProjectView.jsx
  • packages/ui/src/zag/Popover.jsx
  • packages/web/src/utils/reconciliation.js
  • packages/ui/src/index.js
  • packages/web/src/components/charts/ChartSettingsModal.jsx
  • packages/ui/src/zag/Tour.jsx
  • packages/ui/src/zag/Combobox.jsx
  • packages/ui/src/zag/Drawer.jsx
  • packages/web/src/components/admin-ui/ImpersonationBanner.jsx
packages/**/*.{js,jsx,ts,tsx}

📄 CodeRabbit inference engine (.cursorrules)

packages/**/*.{js,jsx,ts,tsx}: Prefer modern ES6+ syntax and features
Use aliases for imports when appropriate to improve readability
Prefer using config files rather than hardcoding values
Keep files small, focused, and modular. If a file exceeds a high number of lines, consider refactoring by extracting sub-modules into a folder with index.jsx and helper components, moving complex logic into separate utility files or primitives, or splitting large forms into section components
Each file should handle one coherent responsibility
Use Zod for schema and input validation

Files:

  • packages/ui/src/zag/Menu.jsx
  • packages/ui/src/constants/zIndex.js
  • packages/ui/src/zag/Dialog.jsx
  • packages/ui/src/zag/Toast.jsx
  • packages/web/src/components/project-ui/ProjectView.jsx
  • packages/ui/src/zag/Popover.jsx
  • packages/web/src/utils/reconciliation.js
  • packages/ui/src/index.js
  • packages/web/src/components/charts/ChartSettingsModal.jsx
  • packages/ui/src/zag/Tour.jsx
  • packages/ui/src/zag/Combobox.jsx
  • packages/ui/src/zag/Drawer.jsx
  • packages/web/src/components/admin-ui/ImpersonationBanner.jsx
**/*.{js,jsx,ts,tsx}

📄 CodeRabbit inference engine (.github/copilot-instructions.md)

**/*.{js,jsx,ts,tsx}: Prefer modern ES6+ syntax and features
Use aliases for imports when appropriate to improve readability

Files:

  • packages/ui/src/zag/Menu.jsx
  • packages/ui/src/constants/zIndex.js
  • packages/ui/src/zag/Dialog.jsx
  • packages/ui/src/zag/Toast.jsx
  • packages/web/src/components/project-ui/ProjectView.jsx
  • packages/ui/src/zag/Popover.jsx
  • packages/web/src/utils/reconciliation.js
  • packages/ui/src/index.js
  • packages/web/src/components/charts/ChartSettingsModal.jsx
  • packages/ui/src/zag/Tour.jsx
  • packages/ui/src/zag/Combobox.jsx
  • packages/ui/src/zag/Drawer.jsx
  • packages/web/src/components/admin-ui/ImpersonationBanner.jsx
packages/web/src/**/*.{jsx,tsx,js,ts}

📄 CodeRabbit inference engine (.cursorrules)

packages/web/src/**/*.{jsx,tsx,js,ts}: For UI icons, use the solid-icons library or SVGs only. Do not use emojis
Import stores directly where needed instead of passing values through multiple components
When you need to compute a value based on props or state in SolidJS, use createMemo to ensure it updates reactively
For complex state or state objects in SolidJS, use Solid's createStore for better performance and reactivity
You may create reusable logic in 'primitives' (hooks) that can be shared across components to keep components clean and focused on rendering

Files:

  • packages/web/src/components/project-ui/ProjectView.jsx
  • packages/web/src/utils/reconciliation.js
  • packages/web/src/components/charts/ChartSettingsModal.jsx
  • packages/web/src/components/admin-ui/ImpersonationBanner.jsx
packages/web/src/components/**/*.{jsx,tsx}

📄 CodeRabbit inference engine (.cursorrules)

packages/web/src/components/**/*.{jsx,tsx}: Use responsive design principles for UI components
Use Zag.js for UI components and design system
Zag components exist in packages/web/src/components/zag/* and should be reused; check the README.md in that folder for a list of existing components before adding new components and when debugging
Components should receive at most 1–5 props, and only for local configuration, not shared state
If a component would need more than 5 props, move the shared data into an external store, a primitive, or Solid context
Components should be lean and focused and should not implement business logic; move business logic into stores, utilities, or primitives
Never have a component act as a 'God component' coordinating multiple large concerns

Files:

  • packages/web/src/components/project-ui/ProjectView.jsx
  • packages/web/src/components/charts/ChartSettingsModal.jsx
  • packages/web/src/components/admin-ui/ImpersonationBanner.jsx
packages/web/src/**/*.{jsx,tsx,js,ts,css}

📄 CodeRabbit inference engine (.cursorrules)

Ensure browser compatibility for all frontend code (Safari is usually problematic)

Files:

  • packages/web/src/components/project-ui/ProjectView.jsx
  • packages/web/src/utils/reconciliation.js
  • packages/web/src/components/charts/ChartSettingsModal.jsx
  • packages/web/src/components/admin-ui/ImpersonationBanner.jsx
packages/web/src/components/**/*.{jsx,tsx,js}

📄 CodeRabbit inference engine (.cursorrules)

Group related components in subdirectories with an index.js barrel export

Files:

  • packages/web/src/components/project-ui/ProjectView.jsx
  • packages/web/src/components/charts/ChartSettingsModal.jsx
  • packages/web/src/components/admin-ui/ImpersonationBanner.jsx
packages/web/src/**/*.{jsx,tsx}

📄 CodeRabbit inference engine (.cursorrules)

packages/web/src/**/*.{jsx,tsx}: Do NOT prop-drill application state. Shared or cross-feature state must live in external stores under packages/web/src/stores/ or relative to the component file
Do not destructure props in SolidJS components as it breaks reactivity. Instead, access props directly from the props object or wrap them in a function to ensure they are always up-to-date

Files:

  • packages/web/src/components/project-ui/ProjectView.jsx
  • packages/web/src/components/charts/ChartSettingsModal.jsx
  • packages/web/src/components/admin-ui/ImpersonationBanner.jsx
packages/web/src/**/*.{js,jsx,ts,tsx}

📄 CodeRabbit inference engine (.github/copilot-instructions.md)

packages/web/src/**/*.{js,jsx,ts,tsx}: For UI icons, use the solid-icons library or SVGs only. Do not use emojis
Ensure browser compatibility for all frontend code (Safari is usually problematic)
Keep files small, focused, and modular. If a file exceeds a high number of lines, consider refactoring by extracting sub-modules into a folder with index.jsx and helper components, moving complex logic into separate utility files or primitives, or splitting large forms into section components
Do NOT prop-drill application state. Shared or cross-feature state must live in external stores under packages/web/src/stores/ or relative to the component file
Use createMemo for derived values to ensure they update reactively

Files:

  • packages/web/src/components/project-ui/ProjectView.jsx
  • packages/web/src/utils/reconciliation.js
  • packages/web/src/components/charts/ChartSettingsModal.jsx
  • packages/web/src/components/admin-ui/ImpersonationBanner.jsx
packages/web/src/components/**/*.{js,jsx,ts,tsx}

📄 CodeRabbit inference engine (.github/copilot-instructions.md)

packages/web/src/components/**/*.{js,jsx,ts,tsx}: Use responsive design principles for UI components
Group related components in subdirectories with an index.js barrel export
Use Zag.js for UI components and design system
Zag component exist in packages/web/src/components/zag/* and should be reused. Check the README.md in that folder for a list of existing components before adding new components and when debugging
Components should receive at most 1–5 props, and only for local configuration, not shared state. If a component would need more than 5 props, move the shared data into an external store, a primitive, or Solid context
Do not destructure props in SolidJS components as it breaks reactivity. Instead, access props directly from the props object or wrap them in a function to ensure they are always up-to-date
Components should be lean and focused. They should not implement business logic; move that into stores, utilities, or primitives
Never have a component act as a God component coordinating multiple large concerns

Files:

  • packages/web/src/components/project-ui/ProjectView.jsx
  • packages/web/src/components/charts/ChartSettingsModal.jsx
  • packages/web/src/components/admin-ui/ImpersonationBanner.jsx
🧠 Learnings (8)
📓 Common learnings
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .cursorrules:0-0
Timestamp: 2025-12-19T12:38:18.491Z
Learning: Applies to packages/web/src/**/*.{jsx,tsx,js,ts,css} : Ensure browser compatibility for all frontend code (Safari is usually problematic)
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2025-12-19T14:49:49.717Z
Learning: Applies to packages/web/src/**/*.{js,jsx,ts,tsx} : Ensure browser compatibility for all frontend code (Safari is usually problematic)
📚 Learning: 2025-12-19T12:38:18.491Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .cursorrules:0-0
Timestamp: 2025-12-19T12:38:18.491Z
Learning: Applies to packages/web/src/components/**/*.{jsx,tsx} : Use Zag.js for UI components and design system

Applied to files:

  • packages/ui/src/zag/Menu.jsx
  • packages/ui/src/constants/zIndex.js
  • packages/ui/src/zag/Dialog.jsx
  • packages/ui/src/zag/Toast.jsx
  • packages/ui/src/zag/Popover.jsx
  • packages/web/src/components/charts/ChartSettingsModal.jsx
  • packages/ui/src/zag/Tour.jsx
  • packages/ui/src/zag/Combobox.jsx
  • packages/ui/src/zag/Drawer.jsx
  • packages/web/src/components/admin-ui/ImpersonationBanner.jsx
📚 Learning: 2025-12-19T14:49:49.717Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2025-12-19T14:49:49.717Z
Learning: Applies to packages/web/src/components/**/*.{js,jsx,ts,tsx} : Use Zag.js for UI components and design system

Applied to files:

  • packages/ui/src/zag/Menu.jsx
  • packages/ui/src/constants/zIndex.js
  • packages/ui/src/zag/Dialog.jsx
  • packages/ui/src/zag/Toast.jsx
  • packages/ui/src/zag/Popover.jsx
  • packages/web/src/components/charts/ChartSettingsModal.jsx
  • packages/ui/src/zag/Tour.jsx
  • packages/ui/src/zag/Combobox.jsx
  • packages/ui/src/zag/Drawer.jsx
📚 Learning: 2025-12-19T12:38:18.491Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .cursorrules:0-0
Timestamp: 2025-12-19T12:38:18.491Z
Learning: Applies to packages/web/src/components/**/*.{jsx,tsx} : Zag components exist in `packages/web/src/components/zag/*` and should be reused; check the README.md in that folder for a list of existing components before adding new components and when debugging

Applied to files:

  • packages/ui/src/zag/Menu.jsx
  • packages/ui/src/zag/Dialog.jsx
  • packages/ui/src/zag/Toast.jsx
  • packages/ui/src/zag/Popover.jsx
  • packages/ui/src/zag/Tour.jsx
  • packages/ui/src/zag/Combobox.jsx
  • packages/ui/src/zag/Drawer.jsx
📚 Learning: 2025-12-19T14:49:49.717Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2025-12-19T14:49:49.717Z
Learning: Applies to packages/web/src/components/**/*.{js,jsx,ts,tsx} : Zag component exist in `packages/web/src/components/zag/*` and should be reused. Check the README.md in that folder for a list of existing components before adding new components and when debugging

Applied to files:

  • packages/ui/src/zag/Menu.jsx
  • packages/ui/src/zag/Toast.jsx
  • packages/ui/src/zag/Popover.jsx
  • packages/ui/src/zag/Tour.jsx
  • packages/ui/src/zag/Combobox.jsx
  • packages/ui/src/zag/Drawer.jsx
📚 Learning: 2025-12-19T14:49:49.717Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2025-12-19T14:49:49.717Z
Learning: Applies to packages/web/src/stores/**/*.{js,ts} : Use Solid's `createStore` for complex state or state objects for better performance and reactivity

Applied to files:

  • packages/ui/src/zag/Toast.jsx
📚 Learning: 2025-12-19T12:38:18.491Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .cursorrules:0-0
Timestamp: 2025-12-19T12:38:18.491Z
Learning: Applies to packages/web/src/**/*.{jsx,tsx,js,ts} : For complex state or state objects in SolidJS, use Solid's `createStore` for better performance and reactivity

Applied to files:

  • packages/ui/src/zag/Toast.jsx
📚 Learning: 2025-12-19T14:49:49.717Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2025-12-19T14:49:49.717Z
Learning: Applies to packages/web/src/components/**/*.{js,jsx,ts,tsx} : Group related components in subdirectories with an index.js barrel export

Applied to files:

  • packages/ui/src/index.js
🧬 Code graph analysis (9)
packages/ui/src/zag/Menu.jsx (1)
packages/ui/src/constants/zIndex.js (2)
  • Z_INDEX (15-44)
  • Z_INDEX (15-44)
packages/ui/src/zag/Dialog.jsx (1)
packages/ui/src/constants/zIndex.js (2)
  • Z_INDEX (15-44)
  • Z_INDEX (15-44)
packages/ui/src/zag/Toast.jsx (1)
packages/ui/src/constants/zIndex.js (2)
  • Z_INDEX (15-44)
  • Z_INDEX (15-44)
packages/web/src/components/project-ui/ProjectView.jsx (1)
packages/web/src/utils/reconciliation.js (1)
  • isStudyInReconciliation (11-39)
packages/web/src/components/charts/ChartSettingsModal.jsx (1)
packages/ui/src/constants/zIndex.js (2)
  • Z_INDEX (15-44)
  • Z_INDEX (15-44)
packages/ui/src/zag/Tour.jsx (1)
packages/ui/src/constants/zIndex.js (2)
  • Z_INDEX (15-44)
  • Z_INDEX (15-44)
packages/ui/src/zag/Combobox.jsx (1)
packages/ui/src/constants/zIndex.js (2)
  • Z_INDEX (15-44)
  • Z_INDEX (15-44)
packages/ui/src/zag/Drawer.jsx (1)
packages/ui/src/constants/zIndex.js (2)
  • Z_INDEX (15-44)
  • Z_INDEX (15-44)
packages/web/src/components/admin-ui/ImpersonationBanner.jsx (1)
packages/ui/src/constants/zIndex.js (2)
  • Z_INDEX (15-44)
  • Z_INDEX (15-44)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
  • GitHub Check: Workers Builds: corates
🔇 Additional comments (13)
packages/web/src/utils/reconciliation.js (1)

11-39: LGTM! Successfully addresses the duplication concern.

The reconciliation eligibility logic has been cleanly extracted into a reusable utility function. The implementation correctly handles edge cases (missing checklists, missing reviewers) and explicitly filters out reconciled checklists when counting completed ones, which makes the intent clear and robust.

packages/web/src/components/project-ui/ProjectView.jsx (2)

21-21: LGTM! Clean import using proper alias.

The import correctly uses the @/ alias and references the newly extracted reconciliation utility.


195-197: LGTM! Successfully addresses the previous duplication concern.

The reconciliation count logic has been cleanly refactored to delegate to the extracted isStudyInReconciliation utility. This addresses the past review comment about duplicated filtering logic and aligns with the coding guideline to move business logic out of components and into utilities.

packages/ui/src/index.js (1)

11-13: LGTM!

The export addition follows the existing barrel export pattern and correctly exposes the centralized Z_INDEX constants for use across the UI package.

packages/web/src/components/admin-ui/ImpersonationBanner.jsx (1)

12-12: LGTM!

The refactor correctly replaces the hardcoded z-100 with Z_INDEX.BANNER, maintaining the same z-index value while improving maintainability through centralized constants.

Also applies to: 30-32

packages/ui/src/zag/Toast.jsx (1)

5-5: LGTM!

The refactor correctly replaces the hardcoded z-50 with Z_INDEX.TOAST, maintaining the same z-index value while centralizing the constant definition.

Also applies to: 120-120

packages/ui/src/zag/Dialog.jsx (1)

6-6: LGTM!

The refactor correctly replaces hardcoded z-50 values with Z_INDEX.BACKDROP and Z_INDEX.DIALOG, maintaining the same z-index values for both the standard Dialog and ConfirmDialog components while centralizing the constant definitions.

Also applies to: 55-55, 60-60, 174-174, 179-179

packages/ui/src/zag/Drawer.jsx (1)

6-6: LGTM!

The refactor correctly replaces hardcoded z-50 values with Z_INDEX.BACKDROP and Z_INDEX.DIALOG, maintaining the same z-index values while centralizing the constant definitions and ensuring consistency with the Dialog component.

Also applies to: 83-83, 87-90

packages/ui/src/zag/Menu.jsx (1)

5-5: Remove this review comment—the premise is incorrect.

Menu.jsx is a new component added as part of the z-index tier refactor, not a change from a previous z-index value. The Z_INDEX.MENU value of z-40 is intentional per the documented tier system in zIndex.js, which explicitly designates z-40 for menus (non-blocking overlays) and z-50 for dialogs (modal overlays). This stacking order is by design.

Likely an incorrect or invalid review comment.

packages/ui/src/zag/Popover.jsx (1)

6-6: Stacking order change is intentional and properly addressed.

The z-40 tier for Popover is documented in the Z_INDEX tier system (z-40 for "non-blocking" overlays like Popovers/Tooltips; z-50 for "modal overlays and notifications" like Dialogs/Toasts). The inDialog prop exists specifically to handle Popover rendering within Dialog contexts by skipping Portal wrapping. Since the component is currently unused in the codebase, ensure developers use inDialog={true} when nesting Popover inside Dialog components to maintain the intended stacking behavior.

packages/ui/src/zag/Tour.jsx (1)

14-14: LGTM! Centralized z-index constants improve maintainability.

The refactoring to use Z_INDEX.TOUR_BACKDROP, Z_INDEX.TOUR_SPOTLIGHT, and Z_INDEX.TOUR_CONTENT centralizes z-index management and ensures proper layering of tour elements (z-100, z-101, z-102). The three-tier system correctly positions tour overlays above all other UI elements.

Based on learnings, ensure browser compatibility for all frontend code (Safari is usually problematic).

Also applies to: 79-79, 84-84, 89-89

packages/ui/src/zag/Combobox.jsx (1)

6-6: Combobox z-index set correctly to z-40 per design system.

The combobox dropdown correctly uses Z_INDEX.COMBOBOX (z-40) as defined in the centralized z-index constants. This z-index value is intentional and documented: z-40 is designated for non-blocking overlay components (dropdowns, menus, tooltips, popovers), while z-50 is reserved for modal overlays (dialogs, drawers, toasts). This hierarchy ensures dropdowns remain below modals when both are present—appropriate behavior for combobox usage.

The implementation is sound and the centralized constant improves maintainability. For Safari, verify that parent elements don't introduce stacking context issues via CSS properties like transform, opacity < 1, or -webkit-overflow-scrolling: touch, which can interfere with z-index ordering.

packages/web/src/components/charts/ChartSettingsModal.jsx (1)

3-3: Remove incorrect z-index increase concern; confirm design system implementation is correct.

The backdrop and dialog are already set to z-50 in the design system (not increased from z-40). The change imports centralized Z_INDEX constants rather than modifying values. Z-index tiers are intentional: tooltips, popovers, menus at z-40 (lower tier) and dialogs, backdrops at z-50 (modal tier). Both backdrop and dialog use the same z-index but rely on correct DOM order—backdrop renders first (line 46), dialog second (lines 49-50)—ensuring proper visual stacking. When no z-index differentiation exists, document source order determines stacking, with later elements appearing on top. This design is intentional, correct, and no z-40 elements will be affected since they are already positioned below the modal tier by design.

Comment on lines +33 to +43
/** Tour Backdrop - Tour overlay backdrop */
TOUR_BACKDROP: 'z-100',

/** Tour Spotlight - Tour spotlight effect */
TOUR_SPOTLIGHT: 'z-101',

/** Tour Content - Tour content (highest overlay) */
TOUR_CONTENT: 'z-102',

/** Banner - System-level banners (e.g., ImpersonationBanner) */
BANNER: 'z-100',
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟡 Minor

Clarify z-index precedence for TOUR_BACKDROP and BANNER.

Both TOUR_BACKDROP and BANNER are assigned z-100, which could cause ambiguous stacking behavior if both are rendered simultaneously. Consider whether:

  • The tour backdrop should always be above system banners (use z-101 for TOUR_BACKDROP and shift other tour layers up), or
  • System banners should always be above tour backdrops (reduce BANNER to z-90 or similar)

The intended stacking order should be clarified to avoid visual conflicts.

🤖 Prompt for AI Agents
In packages/ui/src/constants/zIndex.js around lines 33 to 43, TOUR_BACKDROP and
BANNER currently share 'z-100', causing ambiguous stacking; update the z-indexes
so tour layers are always above system banners: set BANNER to remain 'z-100',
bump TOUR_BACKDROP to 'z-101' and increment TOUR_SPOTLIGHT and TOUR_CONTENT one
step higher (e.g., 'z-102' and 'z-103') so the backdrop, spotlight, and content
maintain correct precedence without colliding with banners.

@InfinityBowman InfinityBowman merged commit 03a8854 into main Dec 19, 2025
3 checks passed
@InfinityBowman InfinityBowman deleted the 99-sync-reconcile-navbar branch December 19, 2025 22:20
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.

Sync reconcile navbar

2 participants