Back to .md Directory

šŸ“± Mobile Phone Preview - Quick Start

āœ… **You're already viewing this in VS Code!**

May 2, 2026
0 downloads
3 views
ai prompt
View source

šŸ“± Mobile Phone Preview - Quick Start

⚔ Fastest Way to See Live Morphing

Option 1: Web Browser (Already Running!)

āœ… You're already viewing this in VS Code!

  1. Go to the Simple Browser at: http://localhost:8081
  2. Wait for the app to load (may take 10-30 seconds)
  3. Scroll to the bottom of the screen
  4. You'll see 4 large buttons: CLASS | MESS | STUDY | NEUTRAL
  5. Click any button to see the entire UI morph instantly
    • Background color changes
    • All text recolors
    • Cards transform
    • Buttons update
    • Tab bars shift colors

šŸ’” Pro Tip: Edit colors in frontend/src/theme/colors.ts and the web app hot-reloads instantly!


Option 2: iOS (iPhone/iPad)

Step 1: Install Expo Go

  • Open App Store
  • Search: "Expo Go"
  • Download the official app (published by Expo, Inc.)
  • Open the app

Step 2: Get the Tunnel URL

In VS Code terminal, look for the output when you ran npm start. It should show:

 ╔─────────────────────────────────────────────────────────┐
 │ QR code (scan me):                                     │
 │                                                        │
 │   ā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆ              │
 │   ā–ˆā–ˆā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘  ā–ˆā–ˆ              │
 │   ā–ˆā–ˆā–‘  ā”Œā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā” ā–‘  ā–ˆā–ˆ              │
 │   ā–ˆā–ˆā–‘  │  exp://192.168.x.x:8081│ ā–‘  ā–ˆā–ˆ              │
 │   ā–ˆā–ˆā–‘  ā””ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”˜ ā–‘  ā–ˆā–ˆ              │
 │   ā–ˆā–ˆā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘ā–‘  ā–ˆā–ˆ              │
 │   ā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆā–ˆ              │
 │                                                        │
 │ Or use this URL:                                       │
 │ exp://192.168.x.x:8081                                │
 ā””ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”˜

Step 3: Scan or Open Link

  • Option A (Scan QR):

    • In Expo Go app → tap camera icon
    • Point at QR code shown in terminal
    • Tap link that appears
  • Option B (Copy URL):

    • Copy the exp://... URL from terminal
    • Open in Safari/Chrome
    • Tap "Open in Expo Go" when prompted

Step 4: Wait for App to Load

  • First load: 30-60 seconds (downloads and bundles code)
  • Subsequent loads: 5-10 seconds
  • You'll see splash screen, then the app

Step 5: Scroll Down & Tap Buttons

  • Scroll to bottom of Neutral (Hub) screen
  • Tap buttons in order: CLASS, MESS, STUDY, NEUTRAL
  • Watch the theme morph in real-time šŸŽØ

Option 3: Android (Phone/Tablet)

Step 1: Install Expo Go

  • Open Play Store
  • Search: "Expo"
  • Install "Expo" app (published by Expo, Inc.)
  • Open the app

Step 2: Connect to Same Wi-Fi (Important!)

Make sure your phone is on the same Wi-Fi network as your computer

Step 3: Scan QR Code or Open Link

Same as iOS above:

  • Either scan the QR code from terminal
  • Or copy exp://... URL and open in Expo Go

Step 4: Watch App Load

  • First time: might take 1-2 minutes
  • Should eventually show the app

Step 5: Test Mode Morphing

  • Scroll down
  • Tap color buttons
  • See live theme changes

Option 4: Android Emulator (If you have Android Studio)

Setup (if you haven't already)

# Install Android Studio from https://developer.android.com/studio
# Create AVD (Android Virtual Device) through Android Studio UI
# Or use command line:
emulator -avd Pixel_4_API_31  # or your created emulator name

Run App

cd C:\Users\mohit\Downloads\MorphingUI\frontend
npm run android

The app will:

  1. Build the app
  2. Detect running emulator
  3. Install APK
  4. Launch the app
  5. Show the Morphing UI

šŸ“± Phone Testing Checklist

Before You Start

  • Node.js and npm installed
  • npm start running in terminal (check for npm start output)
  • Phone/emulator connected to same Wi-Fi as computer
  • Expo Go app installed on phone

Testing Morphing Features

  • App loads and shows Neutral mode (hub screen)
  • Scroll to bottom and see 4 big buttons
  • Click "CLASS" → background changes to navy, orange accents appear
  • Click "MESS" → background changes to brown, golden orange with crowd card
  • Click "STUDY" → background changes to indigo, purple timer appears
  • Click "NEUTRAL" → back to hub with balanced colors
  • All transitions are smooth (no delays, instant color shift)

Verify Functionality

  • Class screen has recording button + tabs
  • Mess screen shows crowd density indicator
  • Study screen has focus timer and streak counter
  • Neutral screen has dashboard cards + mode buttons
  • Text is readable in all modes (no low contrast)
  • Bottom navigation tab icon and label change color

Performance Check

  • Mode switching feels instant (< 300ms)
  • No visual glitches when changing modes
  • Scrolling is smooth
  • Memory usage reasonable (check phone settings)

Troubleshooting Phone Preview

āŒ App Won't Load / "Connection Refused"

Problem: Can't connect to dev server Solutions:

  1. Check if npm start is still running in terminal
  2. Verify phone is on same Wi-Fi as computer
  3. Check firewall isn't blocking port 8081:
    # In Windows Terminal:
    netstat -ano | findstr "8081"
    
  4. If no output, Expo server died. Run npm start again
  5. Try tunnel mode: npm start -- --tunnel (slower but more reliable)

āŒ QR Code Doesn't Work

Problem: Camera app doesn't recognize QR code from terminal Solutions:

  1. Use URL method instead: Copy exp://... link and paste in Expo Go
  2. Make sure QR code is fully visible on screen
  3. Get closer/at angle
  4. Take a screenshot and scan from another device
  5. Manually type the IP address shown in terminal

āŒ App Shows Blank White Screen

Problem: App loaded but nothing appears Solutions:

  1. Wait 5-10 more seconds (still bundling)
  2. Close Expo Go completely and re-open link
  3. Clear cache: npm start -- -c (then scan QR again)
  4. Check browser console for errors (tap 3 dots → Settings → Logs)
  5. Restart both terminal (npm start) and Expo Go app

āŒ Mode Buttons Don't Work

Problem: Tapping buttons does nothing Solutions:

  1. Make sure you're on Neutral (Hub) mode first
  2. Scroll all the way down to see the buttons
  3. Tap the blue buttons clearly (not the text inside)
  4. Check that the button appears to respond (color change/highlight)
  5. If still not working, check terminal for errors (red text)

āŒ Colors Don't Change/Wrong Colors Showing

Problem: Tapped button but colors didn't update Solutions:

  1. Verify you tapped the right button (check which mode label shows)
  2. Clear Metro cache: Ctrl+C in terminal, then npm start -- -c
  3. Force refresh on phone: Shake phone and select "Refresh"
  4. Fully restart: Kill Expo Go, kill terminal, restart both
  5. Check frontend/src/theme/colors.ts that colors are defined

āŒ Can't See QR Code in Terminal

Problem: Terminal output not showing QR code Solutions:

  1. Look for exp:// URL in terminal output (that's your link)
  2. Copy the full URL: exp://[IP]:[PORT]
  3. Go to Expo Go app → paste URL in search bar
  4. If terminal has no output, kill all node processes:
    Get-Process node | Stop-Process
    npm start  # restart
    

šŸŽÆ How to Demo to Others

Show the Morphing Live (3 min demo)

  1. Open on your phone (already scanned QR code)
  2. Show Neutral mode: "This is the campus hub - balanced colors"
  3. Scroll down: "Watch what happens when I change the context..."
  4. Tap CLASS: "Now we're in a classroom - warm, focused orange and academic vibe"
  5. Tap MESS: "When you're at the food canteen - warm browns and dynamic crowd visualization"
  6. Tap STUDY: "Deep focus environment - cool purples and peaceful"
  7. Tap NEUTRAL: "Back to the hub"
  8. Explain: "The same codebase, 4 completely different looks. The UI morphs, not you."

Key Talking Points

  • Design: "Rare, rare color palettes - not Material Design blues"
  • Architecture: "XState FSM + Zustand for state, theme system hooks for colors"
  • Performance: "Zero delay morphing - instant color updates"
  • Accessibility: "All colors tested for WCAG AA contrast"
  • Portfolio: "This kind of polish shows deep UI/UX thinking"

Advanced: Local Network Debugging

If you want to see the app URL clearly:

# In terminal, run:
npm start

# Look for output like:
# ────────────────────────────────────────────────────────────
# localhost:19000
# Mac OS: exp://192.168.1.100:19000
# Android: exp://192.168.1.100:19000
# Or scan this QR code:
# [QR CODE SHOWN]
# ────────────────────────────────────────────────────────────

Copy that URL and:

  • On Phone: Open Expo Go → search icon → paste URL → Enter
  • In Web Browser: Paste into address bar directly

Pro Tips ✨

  1. Hot Reload: Change colors in colors.ts and watch phone update instantly
  2. Test Color Blindness: Settings → Accessibility → Color filters
  3. Screen Record: Record your phone while switching modes for portfolio video
  4. Performance: Use React DevTools Profiler to see component re-rendering
  5. Multiple Phones: If others have Expo Go, they can scan same QR to test simultaneously

Success Indicators

āœ… You'll see live morphing when:

  1. App loads and shows "Good evening!" greeting (Neutral mode)
  2. Buttons at bottom are visible and tappable
  3. Tapping buttons changes colors instantly
  4. No lag between tap and color change
  5. All text remains readable in each mode
  6. Mode label updates in header

šŸŽ‰ If all of the above work, you have a production-ready morphing UI!


Next Steps:

  • Connect backend API to show real data
  • Add animations to color morphing
  • Implement automatic mode detection (GPS-based)
  • Add custom theme selector
  • Create production build for TestFlight/Play Store

Questions? Check IMPLEMENTATION_GUIDE.md for code details.

Related Documents