一键导入
erne-component
ERNE — Design and test UI components using parallel ui-designer and tdd-guide agents
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
ERNE — Design and test UI components using parallel ui-designer and tdd-guide agents
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
Apple HIG design intelligence — build, review, animate, and analyze with Apple Human Interface Guidelines for React Native/Expo
Video-based visual debugging — extract key frames from screen recordings and analyze UI bugs over time. Detects animation glitches, race conditions, gesture issues, scroll jank, keyboard overlap, and navigation transitions that screenshots cannot capture.
Auto-generate skills and rules from observed React Native development patterns
ERNE — Implement animations using the ui-designer agent with Reanimated and Gesture Handler
ERNE — Diagnose and fix build failures using the expo-config-resolver agent
ERNE — Comprehensive code review combining code quality and performance analysis
| name | erne-component |
| description | ERNE — Design and test UI components using parallel ui-designer and tdd-guide agents |
You are executing the /erne-component command. Run ui-designer and tdd-guide in parallel. One designs the component, the other writes tests.
import { View, Text, Pressable } from 'react-native';
interface CardProps {
title: string;
subtitle?: string;
onPress?: () => void;
variant?: 'default' | 'outlined' | 'elevated';
}
export function Card({ title, subtitle, onPress, variant = 'default' }: CardProps) {
return (
<Pressable
onPress={onPress}
className={cn(
'rounded-2xl p-4',
variant === 'default' && 'bg-card',
variant === 'outlined' && 'border border-border bg-transparent',
variant === 'elevated' && 'bg-card shadow-md',
)}
>
<Text className="text-lg font-semibold text-foreground">{title}</Text>
{subtitle && (
<Text className="mt-1 text-sm text-muted-foreground">{subtitle}</Text>
)}
</Pressable>
);
}
accessibilityRole, accessibilityLabel, accessibilityStatePlatform.select or NativeWind responsive for platform differencesWrite comprehensive tests alongside the component:
import { render, screen, fireEvent } from '@testing-library/react-native';
import { Card } from './Card';
describe('Card', () => {
it('renders title', () => {
render(<Card title="Test Title" />);
expect(screen.getByText('Test Title')).toBeTruthy();
});
it('renders subtitle when provided', () => {
render(<Card title="Title" subtitle="Subtitle" />);
expect(screen.getByText('Subtitle')).toBeTruthy();
});
it('hides subtitle when not provided', () => {
render(<Card title="Title" />);
expect(screen.queryByText('Subtitle')).toBeNull();
});
it('calls onPress when tapped', () => {
const onPress = jest.fn();
render(<Card title="Title" onPress={onPress} />);
fireEvent.press(screen.getByText('Title'));
expect(onPress).toHaveBeenCalledTimes(1);
});
it('applies variant styles', () => {
// Test each variant renders correctly
});
});