#!/usr/bin/env python3 """Rewrite Little Fig UI to be fully mobile responsive.""" import subprocess, os TOKEN = "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" subprocess.run(["git", "clone", f"https://{TOKEN}@github.com/ticketguy/littlefig.git", "/app/littlefig"], check=True) os.chdir("/app/littlefig") subprocess.run(["git", "config", "user.name", "0xticketguy"], check=True) subprocess.run(["git", "config", "user.email", "0xticketguy@harboria.dev"], check=True) ui_path = "src/little_fig/web/static/index.html" with open(ui_path, "r") as f: html = f.read() # The UI uses Tailwind CSS via CDN. We need to add responsive classes. # Key changes: # 1. Sidebar: hidden on mobile, shown on md+ (with hamburger toggle) # 2. Chat sidebar (history): hidden on mobile # 3. Touch-friendly tap targets # 4. Full-width content on mobile # Replace the sidebar aside — add responsive classes old_sidebar_start = '