Skip to content

last commit to deploy#7

Merged
gorrawith merged 1 commit intomainfrom
hosting-images
Apr 2, 2026
Merged

last commit to deploy#7
gorrawith merged 1 commit intomainfrom
hosting-images

Conversation

@gorrawith
Copy link
Copy Markdown
Owner

@gorrawith gorrawith commented Apr 2, 2026

Summary by CodeRabbit

  • New Features

    • Improved export functionality with enhanced file handling capabilities.
  • Updates

    • Rebranded application identity from "Roomify" to "3DRoom" across all pages.
    • Updated hero messaging to reflect new 2D to 3D floor plan conversion focus.
    • Removed navigation links from the header.
    • Disabled projects management panel on the home page.
    • Enhanced document metadata management for better page identification.

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented Apr 2, 2026

📝 Walkthrough

Walkthrough

This PR rebrands the application from "Roomify" to "3DRoom," integrates react-helmet for document metadata management (favicon, page titles), refactors the export flow to fetch and blob-convert images, and disables the projects management UI by commenting out related sections and functions.

Changes

Cohort / File(s) Summary
Branding & Metadata
app/routes/home.tsx, app/routes/visualizer.$id.tsx, components/Navbar.tsx
Updated brand name from "Roomify" to "3DRoom", added react-helmet integration for favicon and title management, changed hero text copy, and commented out navbar navigation links.
Export & Route Refactoring
app/routes/visualizer.$id.tsx
Converted handleExport from synchronous direct download to async fetch-blob pattern with error handling; commented out project panel header content.
Project Management Removal
app/routes/home.tsx
Disabled projects list UI and handleDelete function by commenting out the entire projects section block.
Dependencies
package.json
Added react-helmet to dependencies and @types/react-helmet to devDependencies.
Formatting
lib/puter.action.ts, lib/puter.worker.js
Applied whitespace and newline formatting adjustments; no functional logic changes.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Possibly related PRs

Poem

🐰 From Roomify's humble beginnings tall,
Now 3DRoom doth grace us all!
With helmets donned for metadata care,
And exports floating through the air,
A rebrand fresh, a new frontier—
The 3D future's drawing near! ✨

🚥 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 'last commit to deploy' is vague and does not clearly describe the main changes in the pull request, which involve rebranding from 'Roomify' to '3DRoom', updating UI components, and adding react-helmet for metadata management. Use a more descriptive title that captures the primary changes, such as 'Rebrand to 3DRoom and add Helmet metadata management' or 'Update branding and add react-helmet dependency'.
✅ Passed checks (1 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.

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

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch hosting-images

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

Caution

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

⚠️ Outside diff range comments (1)
app/routes/home.tsx (1)

10-15: ⚠️ Potential issue | 🟡 Minor

Update meta() to reflect the new branding.

The meta() function still returns "New React Router App" as the page title, which is inconsistent with the "3DRoom" branding applied elsewhere. Update this to match:

♻️ Proposed fix
 export function meta({}: Route.MetaArgs) {
   return [
-    { title: "New React Router App" },
-    { name: "description", content: "Welcome to React Router!" },
+    { title: "3DRoom" },
+    { name: "description", content: "AI-powered 2D to 3D floor plan visualization" },
   ];
 }
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@app/routes/home.tsx` around lines 10 - 15, The meta() function currently
returns the old title "New React Router App"; update the returned metadata in
meta({}: Route.MetaArgs) to use the new branding (e.g., set the title to
"3DRoom") and adjust the description content to match the app branding so the
page metadata reflects "3DRoom" consistently across the app.
🧹 Nitpick comments (6)
app/routes/home.tsx (2)

73-83: Redundant document title setting — consolidate with meta() or Helmet.

The title is set three ways: meta() (line 12), document.title (line 74), and commented-out Helmet (line 81). For React Router, the meta() export is the idiomatic approach. Remove the useEffect and uncomment the Helmet title if you need it for the favicon, or rely solely on meta():

♻️ Proposed fix
-  useEffect(() => {
-    document.title = "3DRoom";
-    
-  }, []);

   return (
     <>
     <Helmet>
-      {/* <title>3DRoom</title> */}
       <link rel="icon" href="/home.png" />
     </Helmet>
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@app/routes/home.tsx` around lines 73 - 83, The component currently sets the
page title imperatively in the useEffect hook via document.title while title is
already provided by the meta() export and there is a commented-out <title>
inside the Helmet block; remove the useEffect that sets document.title and
either uncomment/add the <title> element inside the Helmet wrapper or rely
solely on the existing meta() export to manage the document title so you don't
set the title in multiple places (refer to useEffect, document.title, Helmet,
and meta()).

129-180: Remove or extract large commented-out section.

This 50+ line commented block contains a reference to handleDelete (line 151) which no longer exists in the component. If uncommented, this code would fail. Either:

  1. Remove the section entirely (use git history if needed later)
  2. Create a tracking issue if this feature is planned for re-enablement
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@app/routes/home.tsx` around lines 129 - 180, The large commented-out JSX
block in this file contains dead code that references removed symbols (notably
handleDelete inside the projects.map render and usages of
projects/navigate/Clock/ArrowUpRight), so remove or extract that entire
commented section; either delete it outright (rely on git history if you need it
later) or move it into a separate feature/archived file and create a tracking
issue for re-enablement, and after removal verify there are no stale imports or
references to handleDelete or related components left in the module.
app/routes/visualizer.$id.tsx (2)

161-163: Remove commented-out JSX or add tracking comments.

Multiple UI sections are commented out (project panel meta, Share button). Either remove this dead code or add TODO comments explaining when/why they'll be re-enabled.

Also applies to: 175-178

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@app/routes/visualizer`.$id.tsx around lines 161 - 163, In
app/routes/visualizer.$id.tsx remove the dead commented-out JSX (the project
panel meta block around the h2/project name and the commented Share button
block) or replace each commented block with a single-line TODO comment
describing why it’s disabled and when to re-enable (include a ticket/issue ID if
available); locate the commented blocks near the project header and the Share
button comments (the JSX surrounding project?.name / `Residence ${id}` and the
Share button markup) and either delete them or convert them to clear TODO
comments so future reviewers know intent.

133-143: Redundant document title setting — use only Helmet.

document.title is set imperatively in useEffect (line 134) while also using Helmet (lines 140-143). The Helmet approach is declarative and preferred. Remove the useEffect and set the title in Helmet instead:

♻️ Proposed fix
-  useEffect(() => {
-    document.title = "3DRoom";
-    
-  }, []);

   return (
     <>
     <Helmet>
-      
+      <title>3DRoom</title>
       <link rel="icon" href="/home.png" />
     </Helmet>
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@app/routes/visualizer`.$id.tsx around lines 133 - 143, Remove the imperative
document.title set inside the useEffect and instead declare the page title via
the existing Helmet element: delete the useEffect block that calls
document.title (the useEffect wrapper and its contents) and add a
<title>3DRoom</title> inside the Helmet component so the title is managed
declaratively; update any references to useEffect in this file if they become
unused imports.
components/Navbar.tsx (1)

34-39: Remove commented-out code or track with a TODO.

Commented-out code adds clutter and becomes stale. If these links are intended to be re-enabled later, add a TODO comment with context (e.g., // TODO: Re-enable after launch). Otherwise, remove them entirely — version control preserves the history.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@components/Navbar.tsx` around lines 34 - 39, In the Navbar component remove
the commented-out <ul className="links"> block (the block containing the <a>
anchors for Product, Pricing, Community, Enterprise) to avoid stale clutter; if
you intend to bring these links back later, replace the comment with a
single-line TODO (e.g., // TODO: Re-enable nav links after launch) above where
the <ul className="links"> would go so intent is tracked instead of leaving
large commented HTML.
lib/puter.action.ts (1)

141-147: Remove trailing blank lines.

The file has 5 unnecessary blank lines after the closing brace. This appears to be accidental whitespace that should be cleaned up.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@lib/puter.action.ts` around lines 141 - 147, Remove the extra trailing blank
lines after the file's final closing brace (the "};" at the end of
lib/puter.action.ts); delete the 5 blank lines so the file ends immediately
after the closing brace and ensure there is a single newline at EOF.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@app/routes/visualizer`.$id.tsx:
- Around line 28-49: handleExport currently fetches currentImage which will fail
for cross-origin hosted URLs set by createProject; update handleExport to detect
if currentImage is a data URI (starts with "data:") and continue using
fetch/blobs for that case, but for non-data URIs attempt to create an
HTMLImageElement with image.crossOrigin = "anonymous", draw it to a canvas and
call canvas.toBlob()/toDataURL to generate the downloadable file (handle
potential tainting errors), and if that fails fall back to opening the image in
a new tab or routing the URL through a server-side proxy; refer to handleExport,
currentImage and the code path that sets currentImage in createProject to locate
where to implement these checks and fallbacks.

In `@package.json`:
- Line 20: The project depends on the legacy "react-helmet" entry in
package.json which is incompatible with React 19; replace "react-helmet":
"^6.1.0" with "react-helmet-async": ">=3.0.0" (or remove the dependency and use
native <title>/<meta>/<link> in components) and update code imports/usages:
change any imports from react-helmet to react-helmet-async and wrap the app root
with HelmetProvider and continue to use Helmet for SSR/context features (or
remove Helmet usage and render head tags directly in your components when opting
for native metadata support).

---

Outside diff comments:
In `@app/routes/home.tsx`:
- Around line 10-15: The meta() function currently returns the old title "New
React Router App"; update the returned metadata in meta({}: Route.MetaArgs) to
use the new branding (e.g., set the title to "3DRoom") and adjust the
description content to match the app branding so the page metadata reflects
"3DRoom" consistently across the app.

---

Nitpick comments:
In `@app/routes/home.tsx`:
- Around line 73-83: The component currently sets the page title imperatively in
the useEffect hook via document.title while title is already provided by the
meta() export and there is a commented-out <title> inside the Helmet block;
remove the useEffect that sets document.title and either uncomment/add the
<title> element inside the Helmet wrapper or rely solely on the existing meta()
export to manage the document title so you don't set the title in multiple
places (refer to useEffect, document.title, Helmet, and meta()).
- Around line 129-180: The large commented-out JSX block in this file contains
dead code that references removed symbols (notably handleDelete inside the
projects.map render and usages of projects/navigate/Clock/ArrowUpRight), so
remove or extract that entire commented section; either delete it outright (rely
on git history if you need it later) or move it into a separate feature/archived
file and create a tracking issue for re-enablement, and after removal verify
there are no stale imports or references to handleDelete or related components
left in the module.

In `@app/routes/visualizer`.$id.tsx:
- Around line 161-163: In app/routes/visualizer.$id.tsx remove the dead
commented-out JSX (the project panel meta block around the h2/project name and
the commented Share button block) or replace each commented block with a
single-line TODO comment describing why it’s disabled and when to re-enable
(include a ticket/issue ID if available); locate the commented blocks near the
project header and the Share button comments (the JSX surrounding project?.name
/ `Residence ${id}` and the Share button markup) and either delete them or
convert them to clear TODO comments so future reviewers know intent.
- Around line 133-143: Remove the imperative document.title set inside the
useEffect and instead declare the page title via the existing Helmet element:
delete the useEffect block that calls document.title (the useEffect wrapper and
its contents) and add a <title>3DRoom</title> inside the Helmet component so the
title is managed declaratively; update any references to useEffect in this file
if they become unused imports.

In `@components/Navbar.tsx`:
- Around line 34-39: In the Navbar component remove the commented-out <ul
className="links"> block (the block containing the <a> anchors for Product,
Pricing, Community, Enterprise) to avoid stale clutter; if you intend to bring
these links back later, replace the comment with a single-line TODO (e.g., //
TODO: Re-enable nav links after launch) above where the <ul className="links">
would go so intent is tracked instead of leaving large commented HTML.

In `@lib/puter.action.ts`:
- Around line 141-147: Remove the extra trailing blank lines after the file's
final closing brace (the "};" at the end of lib/puter.action.ts); delete the 5
blank lines so the file ends immediately after the closing brace and ensure
there is a single newline at EOF.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: b7b8bec9-809e-4205-81c3-3d3cf781809d

📥 Commits

Reviewing files that changed from the base of the PR and between 0c6934e and 61d7c11.

⛔ Files ignored due to path filters (2)
  • package-lock.json is excluded by !**/package-lock.json
  • public/home.png is excluded by !**/*.png
📒 Files selected for processing (6)
  • app/routes/home.tsx
  • app/routes/visualizer.$id.tsx
  • components/Navbar.tsx
  • lib/puter.action.ts
  • lib/puter.worker.js
  • package.json

Comment on lines +28 to +49
const handleExport = async () => {
if (!currentImage) return;

try {
const response = await fetch(currentImage);
const blob = await response.blob();

const url = window.URL.createObjectURL(blob);

const link = document.createElement("a");
link.href = url;
link.download = `roomify-${id || "design"}.png`;

document.body.appendChild(link);
link.click();
document.body.removeChild(link);

window.URL.revokeObjectURL(url);
} catch (err) {
console.error("Export failed:", err);
}
};
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

handleExport will fail with CORS error for hosted images.

After createProject saves, currentImage is set to a Puter-hosted URL (e.g., https://{subdomain}.puter.site/...) at line 77. The fetch(currentImage) call on line 32 will fail with a CORS error for these cross-origin URLs, silently breaking the export functionality.

Consider checking if the image is a data URI (which can be fetched safely) versus a hosted URL, and handle accordingly:

🐛 Proposed fix
 const handleExport = async () => {
   if (!currentImage) return;

   try {
-    const response = await fetch(currentImage);
-    const blob = await response.blob();
-
-    const url = window.URL.createObjectURL(blob);
+    let downloadUrl: string;
+    
+    if (currentImage.startsWith('data:')) {
+      // Data URI - convert to blob URL
+      const response = await fetch(currentImage);
+      const blob = await response.blob();
+      downloadUrl = window.URL.createObjectURL(blob);
+    } else {
+      // External URL - download directly (browser handles it)
+      downloadUrl = currentImage;
+    }

     const link = document.createElement("a");
-    link.href = url;
+    link.href = downloadUrl;
     link.download = `roomify-${id || "design"}.png`;

     document.body.appendChild(link);
     link.click();
     document.body.removeChild(link);

-    window.URL.revokeObjectURL(url);
+    if (currentImage.startsWith('data:')) {
+      window.URL.revokeObjectURL(downloadUrl);
+    }
   } catch (err) {
     console.error("Export failed:", err);
+    // Consider showing user-facing error notification
   }
 };
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@app/routes/visualizer`.$id.tsx around lines 28 - 49, handleExport currently
fetches currentImage which will fail for cross-origin hosted URLs set by
createProject; update handleExport to detect if currentImage is a data URI
(starts with "data:") and continue using fetch/blobs for that case, but for
non-data URIs attempt to create an HTMLImageElement with image.crossOrigin =
"anonymous", draw it to a canvas and call canvas.toBlob()/toDataURL to generate
the downloadable file (handle potential tainting errors), and if that fails fall
back to opening the image in a new tab or routing the URL through a server-side
proxy; refer to handleExport, currentImage and the code path that sets
currentImage in createProject to locate where to implement these checks and
fallbacks.

Comment thread package.json
"react": "^19.2.4",
"react-compare-slider": "^4.0.0",
"react-dom": "^19.2.4",
"react-helmet": "^6.1.0",
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

🌐 Web query:

Is react-helmet compatible with React 19? What is the recommended alternative?

💡 Result:

No, react-helmet is not compatible with React 19. The original react-helmet package (nfl/react-helmet, last updated 2020) has peer dependency on React >=16.3.0 but lacks React 19 support and maintenance. Installation with React 19 fails due to peer dependency conflicts, and there are no updates addressing React 19. The recommended alternative is React 19's built-in document metadata support, where you can render native <title>, , elements directly in components, and React automatically hoists them to . This eliminates the need for third-party libraries for basic use cases. For advanced features (e.g., tag deduplication, title templates, html/body attributes, SSR context), use react-helmet-async v3.0.0+ (published March 2026), which now supports React 19 via runtime detection: renders native elements on React 19+ while preserving legacy behavior on 16-18.

Citations:


react-helmet is incompatible with React 19 — migrate to react-helmet-async v3.0.0+ or use React 19's native metadata support.

react-helmet v6.1.0 uses legacy React lifecycle methods removed in React 19, causing peer dependency conflicts and runtime errors. The package hasn't been maintained since 2020.

For basic metadata (title, meta tags), leverage React 19's built-in document metadata support: render native <title>, <meta>, <link> elements directly in components—React automatically hoists them to <head>. This is now the recommended approach and eliminates the need for a third-party library.

If you need advanced features (tag deduplication, title templates, html/body attributes, SSR context), use react-helmet-async v3.0.0+, which now supports React 19:

🔧 Proposed fix (if using react-helmet-async)
-    "react-helmet": "^6.1.0",
+    "react-helmet-async": "^3.0.0",

And in devDependencies:

-    "@types/react-helmet": "^6.1.11",
+    "@types/react-helmet-async": "^3.0.3",

Usage in components:

-import { Helmet } from "react-helmet";
+import { Helmet } from "react-helmet-async";

Wrap your app with HelmetProvider at the root.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@package.json` at line 20, The project depends on the legacy "react-helmet"
entry in package.json which is incompatible with React 19; replace
"react-helmet": "^6.1.0" with "react-helmet-async": ">=3.0.0" (or remove the
dependency and use native <title>/<meta>/<link> in components) and update code
imports/usages: change any imports from react-helmet to react-helmet-async and
wrap the app root with HelmetProvider and continue to use Helmet for SSR/context
features (or remove Helmet usage and render head tags directly in your
components when opting for native metadata support).

@gorrawith gorrawith merged commit db3f73c into main Apr 2, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant