From 3a9d733a9761e1fb334e033b5a89478645f530c2 Mon Sep 17 00:00:00 2001 From: divyap Date: Tue, 7 Apr 2026 11:35:45 +0530 Subject: [PATCH] docs: added thob builder notes for task 1 --- Week-2/Task-1/thob/notes.md | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/Week-2/Task-1/thob/notes.md b/Week-2/Task-1/thob/notes.md index e69de29..f29027c 100644 --- a/Week-2/Task-1/thob/notes.md +++ b/Week-2/Task-1/thob/notes.md @@ -0,0 +1,22 @@ +# Thob Builder Notes: Task 1 - Material Variant Switcher + +## Overview +Implemented the basic material configuration pattern using Thob's built-in `MaterialVariant` and `Material` properties. + +## Visual Observations +- **Lighting Limitation**: I observed that by default, the light only hits the object from one side, leaving the other side completely dark. +- **Surface Definition**: Standard material properties (color, roughness, metalness) were easy to edit via the sidebar properties panel. + +## Technical Observations (Console Logs) +During development in the builder, several warnings and errors were observed: +- **404 Errors**: `GET https://builder.thob.studio/builder/... 404 (Not Found)`. +- **Hydration Warnings**: `No HydrateFallback element provided to render during initial hydration`. +- **Component State**: `undefined is changing from uncontrolled to controlled`. This suggests a potential issue in how the builder manages internal component state when swapping materials. + +## Builder Workflow +- **Node Structure**: The scene was built using a `Canvas` -> `mesh` -> `sphereGeometry` hierarchy. +- **Variant Linking**: A `MaterialVariant` node was used to manage the switching logic. +- **UI Integration**: A simple `Button` was added under the `UI` group to trigger the material change. + +## Conclusion +The builder makes it very easy to define and link material variants without writing code, but the default lighting environment needs more control (e.g., adding more lights or an environment map) to avoid the "dark side" effect.