Skip to content

refactor/local-dev-env-setup#8666

Open
sshadmand wants to merge 5 commits intomakeplane:previewfrom
InternodeLabs:preview
Open

refactor/local-dev-env-setup#8666
sshadmand wants to merge 5 commits intomakeplane:previewfrom
InternodeLabs:preview

Conversation

@sshadmand
Copy link

@sshadmand sshadmand commented Feb 26, 2026

Description

  • Code Cleanup: Dockerfile should use double quotes in array.
  • Developer configurability: Allow local developers to override ports when they conflict for docker-compose-local.yml. Defaults set so will not hinder experience or existing deployments"

Type of Change

  • Bug fix (non-breaking change which fixes an issue)
  • Feature (non-breaking change which adds functionality)
  • Improvement (change that would cause existing functionality to not work as expected)
  • Code refactoring
  • Performance improvements
  • Documentation update

Summary by CodeRabbit

  • Chores

    • Local development now supports configurable service ports via environment variables with sensible defaults (Redis, object storage, database, API).
    • The web dev server port is now configurable via an environment variable with a default fallback.
    • Minor formatting tweak in container configuration (no behavioral change).
  • Bug Fixes

    • Improved accessibility and keyboard focus for image editing/resizing controls in the editor.

- Allow local developers to override ports when they conflict. Defaults set so will not hinder experience or existing deployments
…efaults set so will not hinder experience or existing deployments
@CLAassistant
Copy link

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
You have signed the CLA already but the status is still pending? Let us recheck it.

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Feb 26, 2026

📝 Walkthrough

Walkthrough

Switched a Dockerfile VOLUME quoting style; replaced hardcoded host ports in docker-compose with env-var overrides and defaults; updated web dev script to use an env-var-backed port; added accessibility/focus attributes and minor typings/handler tweaks to an editor image block component.

Changes

Cohort / File(s) Summary
Dockerfile formatting
deployments/aio/community/Dockerfile
Changed VOLUME JSON-style quoting from single quotes to double quotes.
Compose port overrides
docker-compose-local.yml
Replaced fixed host port mappings with environment-variable overrides and defaults: ${REDIS_PORT:-6379}, ${MINIO_PORT:-9090}, ${POSTGRES_PORT:-5432}, ${API_PORT:-8000}.
Web dev port env
apps/web/package.json
Updated dev script to use ${WEB_PORT:-3000} instead of a hardcoded 3000.
Editor image accessibility & types
packages/editor/src/core/extensions/custom-image/components/block.tsx
Added role="button", tabIndex, and aria-roledescription for accessibility; cast closest(...) result to `HTMLDivElement

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

Poem

🐰
I nudge a quote, I hop a port,
Small tweaks that help the stack cavort.
Focus added, defaults set true,
A tiny patch — a brighter view.

🚥 Pre-merge checks | ✅ 1 | ❌ 2

❌ Failed checks (1 warning, 1 inconclusive)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
Title check ❓ Inconclusive The title 'refactor/local-dev-env-setup' is overly generic and doesn't clearly convey the main changes; it reads more like a branch name than a descriptive PR title. Consider using a more descriptive title such as 'Allow port overrides in docker-compose and fix Dockerfile quotes' or 'Make local dev ports configurable via environment variables'.
✅ Passed checks (1 passed)
Check name Status Explanation
Description check ✅ Passed The PR description covers the main changes and includes required type-of-change selections, but lacks Screenshots/Media, Test Scenarios, and References sections from the template.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment

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

❤️ Share

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

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Caution

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

⚠️ Outside diff range comments (1)
packages/editor/src/core/extensions/custom-image/components/block.tsx (1)

338-354: ⚠️ Potential issue | 🟡 Minor

Focusable resize handle lacks keyboard interaction.

With tabIndex={0}, this element appears in the tab order, but keyboard users cannot operate it since there are no onKeyDown handlers for resizing. This creates a confusing experience where the element is announced as a button but provides no keyboard interaction.

Consider one of these approaches:

  1. Add keyboard support (e.g., arrow keys to resize incrementally).
  2. Use tabIndex={-1} if keyboard resizing isn't intended (keeps it out of tab order).
  3. Use role="slider" with aria-valuenow, aria-valuemin, aria-valuemax for proper resize semantics.
💡 Option 2: Remove from tab order if keyboard resizing isn't supported
               role="button"
               aria-roledescription="Resize image"
-              tabIndex={0}
+              tabIndex={-1}
               onMouseDown={handleResizeStart}
               onTouchStart={handleResizeStart}
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@packages/editor/src/core/extensions/custom-image/components/block.tsx` around
lines 338 - 354, The resize handle is focusable (tabIndex={0}) but lacks
keyboard handlers; either remove it from the tab order or add proper keyboard
support. Add an onKeyDown handler (e.g., handleResizeKeyDown or extend
handleResizeStart) on the same element to handle
ArrowLeft/ArrowRight/ArrowUp/ArrowDown (and Enter/Space if needed) to perform
incremental resizing using the same resize logic, and update ARIA semantics
accordingly (keep role="button" and add aria-label, or change to role="slider"
and provide aria-valuemin/aria-valuemax/aria-valuenow if exposing value).
Alternatively, if keyboard resizing is not supported, change tabIndex to -1 to
remove it from the tab order. Ensure references to isResizing and nodeAlignment
remain unchanged.
🧹 Nitpick comments (1)
packages/editor/src/core/extensions/custom-image/components/block.tsx (1)

238-248: Consider keyboard support or alternative role.

Adding role="button" implies keyboard interactivity (Enter/Space activation). While tabIndex={-1} keeps this out of the tab order, screen readers may still announce it as a button. Consider either:

  • Adding an onKeyDown handler for Enter/Space to match the onMouseDown behavior, or
  • Using a more appropriate role (e.g., role="img" with aria-label, or no explicit role since this is primarily for selection).
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@packages/editor/src/core/extensions/custom-image/components/block.tsx` around
lines 238 - 248, The element with ref containerRef and className
"group/image-component" currently uses role="button" but tabIndex={-1} without
keyboard handlers; either add an onKeyDown handler that listens for Enter and
Space and delegates to handleImageMouseDown (so keyboard activation matches
mouse behavior and preserves role="button"), or change the role to a
non-interactive/semantic alternative (e.g., role="img") and add an appropriate
aria-label or remove the explicit role so screen readers treat it as an
image/selection-only element; update the JSX for the element using the chosen
approach and ensure handleImageMouseDown is invoked for keyboard activation if
you keep role="button".
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Outside diff comments:
In `@packages/editor/src/core/extensions/custom-image/components/block.tsx`:
- Around line 338-354: The resize handle is focusable (tabIndex={0}) but lacks
keyboard handlers; either remove it from the tab order or add proper keyboard
support. Add an onKeyDown handler (e.g., handleResizeKeyDown or extend
handleResizeStart) on the same element to handle
ArrowLeft/ArrowRight/ArrowUp/ArrowDown (and Enter/Space if needed) to perform
incremental resizing using the same resize logic, and update ARIA semantics
accordingly (keep role="button" and add aria-label, or change to role="slider"
and provide aria-valuemin/aria-valuemax/aria-valuenow if exposing value).
Alternatively, if keyboard resizing is not supported, change tabIndex to -1 to
remove it from the tab order. Ensure references to isResizing and nodeAlignment
remain unchanged.

---

Nitpick comments:
In `@packages/editor/src/core/extensions/custom-image/components/block.tsx`:
- Around line 238-248: The element with ref containerRef and className
"group/image-component" currently uses role="button" but tabIndex={-1} without
keyboard handlers; either add an onKeyDown handler that listens for Enter and
Space and delegates to handleImageMouseDown (so keyboard activation matches
mouse behavior and preserves role="button"), or change the role to a
non-interactive/semantic alternative (e.g., role="img") and add an appropriate
aria-label or remove the explicit role so screen readers treat it as an
image/selection-only element; update the JSX for the element using the chosen
approach and ensure handleImageMouseDown is invoked for keyboard activation if
you keep role="button".

ℹ️ Review info

Configuration used: defaults

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 89a5c94 and cb29a92.

📒 Files selected for processing (1)
  • packages/editor/src/core/extensions/custom-image/components/block.tsx

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.

2 participants