"""Check delivered frontend-design UI code against this skill's house rules:
no banned generic font, and at least one deliberate motion/interaction detail
Usage: check_frontend_design.py <file-or-dir>
BANNED_FONTS = ["Inter", "Roboto", "Arial", "Helvetica Neue"]
print("Usage: check_frontend_design.py <file-or-dir>", file=sys.stderr)
target = Path(sys.argv[1])
files = [target] if target.is_file() else list(target.rglob("*.tsx")) + list(target.rglob("*.css"))
text = f.read_text(encoding="utf-8", errors="ignore")
for font in BANNED_FONTS:
if font.lower() in text.lower():
banned_hits.append((f, font))
print(f"❌ banned generic font(s) found: {[(str(f), font) for f, font in banned_hits]}")
print("✅ no banned generic fonts (Inter/Roboto/Arial/Helvetica Neue) found")
re.search(r"transition|animate|@keyframes|framer-motion|motion\.", f.read_text(encoding="utf-8", errors="ignore"))
print("✅ at least one motion/interaction detail found (transition/animation/framer-motion)")
print("⚠️ no motion/interaction detail found — confirm a static design was intentional")
if __name__ == "__main__":