Commit Graph

18 Commits

Author SHA1 Message Date
hobokenchicken 95f97fa897 fix(avatar): declarative canvas element in JSX; remove manual DOM append
React was potentially clearing the canvas on re-render because we
appended it manually to a div. Now using a <canvas ref={canvasRef}>
element directly in JSX that React manages. Pixi app uses .
Scale set to 82% of container.
2026-06-05 10:10:03 -04:00
hobokenchicken e00dc37e68 fix(avatar): use Pixi resizeTo for native canvas sizing; remove all manual CSS/ResizeObserver
Previous approach set CSS width:100% on a low-res canvas, causing the browser
to stretch/pixelate the model. Now using Pixi's built-in resizeTo so the
canvas internal resolution always matches the container. Model scaled to 90%
of container with centered anchor.
2026-06-05 09:57:54 -04:00
hobokenchicken 3a6a1cd6c3 fix(avatar): reduce model margin to 45% to prevent clipping in narrow sidebar 2026-06-05 09:51:39 -04:00
hobokenchicken 13dbcdb7f5 fix(avatar): re-apply CSS 100% after Pixi resize(); use fitModel helper; 65% margin
Pixi renderer.resize() overwrites canvas inline width/height styles,
locking the canvas to the initial size and leaving empty space below.
Now we re-apply width:100%;height:100% after every resize so the canvas
always fills its container. Removed unused appRef.
2026-06-05 09:47:51 -04:00
hobokenchicken f2ff91730b fix(avatar): use ResizeObserver for accurate container sizing; force canvas CSS 100%; reduce margin to 68%
Problem: flex layout wasn't ready on first paint, so clientWidth fell back
to 400px. Canvas was 400px wide but parent was only 288px, causing the
avatar to be clipped on the right.

Fix: ResizeObserver measures real laid-out size before init. Canvas forced
to width/height 100% via CSS so it never overflows. Model scaled to 68%
with centered anchor. Resize handled dynamically.
2026-06-05 09:43:12 -04:00
hobokenchicken dc2cb3bbb3 fix(avatar): reduce model scale to 72% (from 85%) and tighten anchor to prevent right-side clipping in narrow sidebar 2026-06-05 09:36:37 -04:00
hobokenchicken dfd014ac82 feat(ui): complete layout redesign — three-panel desk layout
Replaced the hero + scrollable grid with a fixed-height three-column
workspace:
- Left (fixed 288px): Kira avatar + compact chat + text input
- Center (flex): Large focus timer + notes
- Right (fixed 256px): Music, white noise, wardrobe, pets

Thin top bar: scene selector dots + clock
Thin bottom bar: status + connection indicator

No cards, no scrollable grid, no wasted space. Clean, modern,
everything visible at once. Avatar fills full sidebar height.
2026-06-05 09:33:42 -04:00
hobokenchicken db23034e36 feat(ui): ditch all glass-card containers — flat, modern, card-free layout
All 15+ glass-card instances removed across every component (Timer, Music,
Notes, WhiteNoise, PetZone, Clock, ChatBubble, Wardrobe, Toolbar, KiraAvatar,
BackgroundScene, WelcomeScreen, App text input + bottom bar).

New design: widgets sit directly on the gradient background with only padding,
no frosted-glass backgrounds, borders, or shadows. Cleaner, more modern look.
2026-06-05 09:26:51 -04:00
hobokenchicken f5930d6190 fix(avatar): center Live2D model in card, overlay controls on canvas; scale model to 85% of container; remove card padding; clean template literals to avoid TS parsing issues 2026-06-05 09:16:16 -04:00
hobokenchicken baaa89756f feat(ui): center avatar as hero, ~1/3 viewport height; tools grid below
- Avatar now centered in its own row above the tools grid (was crammed in column 1)
- KiraAvatar container: min-height 33vh, canvas up to 500px wide
- Tools reorganized into 4 columns below: Chat, Timer+Music, Notes+Noise, Clock+Pets+Wardrobe
- WelcomeScreen restored to full (not compact) for first-time users
2026-06-05 09:03:32 -04:00
hobokenchicken 895fb9ac0b fix: Live2D Ticker registration + outfit texture swap path
- Registered pixi Ticker via (Live2DModel as any).registerTicker()
  to fix 'No Ticker registered' warning and animation issues
- Fixed outfit texture swap: textures live on model.textures[]
  not model.internalModel.textures[]
2026-06-04 12:10:20 -04:00
hobokenchicken 3d3df64d7c fix: missing mic toggle in Live2D view + YouTube autoplay
KiraAvatar: Added Talk mic button to Live2D view (was only in
AnimatedAvatar fallback). Includes listening-pulse animation.

MusicPlayer: Replaced hidden YouTube iframe with proper IFrame
Player API. Now starts on explicit user click (Start Lo-Fi button),
complying with browser autoplay policies. Supports station
switching and volume control after playback starts.
2026-06-04 12:06:16 -04:00
hobokenchicken bee428ae0c fix: outfit texture swap via internalModel.textures array
model.internalModel.coreModel.setTexture() expects a raw WebGL
texture, not a PixiJS Texture. Instead, set the new PixiJS Texture
directly on the model's internalModel.textures[2] array. The render
loop's bindTexture() call extracts the WebGL handle from the PixiJS
BaseTexture and passes it to the Cubism core.

This eliminates the cascade of try-catch fallbacks and the
'coreModel.setTexture is not a function' TypeError.
2026-06-04 12:02:48 -04:00
hobokenchicken 0a6946b580 fix: pixi v7 isInteractive TypeError + outfit texture swap
- Added isInteractive() stub on Live2DModel to prevent
  'e.isInteractive is not a function' errors in pixi v7
- Swapped outfit texture loading to use Assets.load() with
  cascading fallbacks (model.setTexture -> internalModel -> coreModel)
- Removed unused Texture import
2026-06-04 11:57:33 -04:00
hobokenchicken d519258942 fix: TypeScript build errors in Docker
- useRef(null) initial values for Strict TS 6.0
- Removed deprecated transparent option in pixi v7
- Cast Live2DModel to any for addChild type compat
- Cast coreModel for getTexture access
- Fixed types/index.ts import path to scenes
- Added vite-env.d.ts with CSS module declarations
- Added null-coalesce for clearInterval calls
2026-06-04 11:46:58 -04:00
hobokenchicken b7edf6a82d feat: Live2D outfit textures + expression system + canvas tweaks
- Generated 5 outfit texture variants via HSL recolor (saved skin tones)
- Dynamic texture_02 swapping when outfit changes
- Expression buttons (Normal, Smile, Sad, Angry, Surprised, Blushing)
- Random idle expression changes every 8-15s
- Responsive canvas sizing with devicePixelRatio support
- Outfit generation script in scripts/gen_outfits.py
- Smoother lip-sync with phase-based mouth animation
2026-06-04 11:40:10 -04:00
hobokenchicken 9653f80abd feat: Live2D model integration with pixi-live2d-display
- Added Epsilon Live2D model (Cubism 4) with full motion/expression set
- KiraAvatar now loads Live2D via PixiJS + cubism4 renderer
- Idle animation auto-plays on load
- Lip-sync: PARAM_MOUTH_OPEN_Y driven by speaking state
- 8 expressions (Normal, Smile, Sad, Angry, Surprised, Blushing, f01, f02)
- 15 motion files including idle, tap, flick, shake
- Physics, eye blink, and LipSync parameter groups configured
- Falls back to animated SVG placeholder if model isn't available
2026-06-04 11:34:59 -04:00
hobokenchicken 97424cb98f init: Kira — AI body double with Honcho memory
Full voice pipeline (Whisper STT -> DeepSeek LLM -> OpenAI TTS),
animated SVG avatar (Live2D-ready), girly-pop UI, lofi music,
timer/notes/pets/wardrobe widgets, 10 background scenes with
particle effects, Honcho cross-session memory.
2026-06-04 10:51:38 -04:00