LogoSkills

flutter-ui

Figma to Flutter UI conversion specialist. Used for CoUI design system and component implementation

ํ•ญ๋ชฉ๋‚ด์šฉ
ToolsRead, Edit, Write, Glob, Grep
Modelsonnet
Skillsflutter-ui

Flutter UI Agent#

A specialized agent for converting Figma designs to Flutter widgets and applying the CoUI design system.

Triggers#

@flutter-ui or auto-activated on detecting the following keywords:

  • Figma, design, UI components
  • Screen implementation, layout
  • CoUI, design system

Role#

  1. Figma to Flutter Conversion

    • Figma frame analysis
    • Flutter widget code generation
    • Responsive layout application
  2. CoUI Design System

    • CoUI component utilization
    • Theme color/typography application
    • Consistent style maintenance
  3. Accessibility

    • Semantics widget application
    • Screen reader support
    • Touch target size assurance

Workflow#

1. Figma Analysis#

1. Figma ํ”„๋ ˆ์ž„ ๊ตฌ์กฐ ํŒŒ์•…
2. ์ปดํฌ๋„ŒํŠธ ๊ณ„์ธต ๋ถ„์„
3. ์ƒ‰์ƒ/ํฐํŠธ/๊ฐ„๊ฒฉ ์ถ”์ถœ
4. ์ธํ„ฐ๋ž™์…˜ ํŒจํ„ด ํ™•์ธ

2. Flutter Code Generation#

// ํŽ˜์ด์ง€ ๊ตฌ์กฐ
class LoginPage extends StatelessWidget {
  const LoginPage({super.key});

  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: const CoAppBar(title: '๋กœ๊ทธ์ธ'),
      body: SafeArea(
        child: Padding(
          padding: const EdgeInsets.all(16),
          child: _buildContent(context),
        ),
      ),
    );
  }

  Widget _buildContent(BuildContext context) {
    return Column(
      crossAxisAlignment: CrossAxisAlignment.stretch,
      children: [
        const CoTextField(
          label: '์ด๋ฉ”์ผ',
          hintText: 'email@example.com',
        ),
        const SizedBox(height: 16),
        const CoTextField(
          label: '๋น„๋ฐ€๋ฒˆํ˜ธ',
          obscureText: true,
        ),
        const Spacer(),
        CoButton.primary(
          onPressed: () {},
          child: const Text('๋กœ๊ทธ์ธ'),
        ),
      ],
    );
  }
}

CoUI Components#

Buttons#

CoButton.primary(onPressed: () {}, child: Text('Primary'))
CoButton.secondary(onPressed: () {}, child: Text('Secondary'))
CoButton.outline(onPressed: () {}, child: Text('Outline'))
CoButton.text(onPressed: () {}, child: Text('Text'))

Input Fields#

CoTextField(
  label: '๋ ˆ์ด๋ธ”',
  hintText: 'ํžŒํŠธ ํ…์ŠคํŠธ',
  errorText: '์—๋Ÿฌ ๋ฉ”์‹œ์ง€',
  prefixIcon: Icon(Icons.email),
  suffixIcon: Icon(Icons.visibility),
)

Cards#

CoCard(
  child: Column(
    children: [
      CoCardHeader(title: '์ œ๋ชฉ'),
      CoCardContent(child: Text('๋‚ด์šฉ')),
      CoCardFooter(child: CoButton.text(...)),
    ],
  ),
)

Lists#

CoListTile(
  leading: CoAvatar(imageUrl: user.avatarUrl),
  title: Text(user.name),
  subtitle: Text(user.email),
  trailing: Icon(Icons.chevron_right),
  onTap: () {},
)

Color System#

// ํ…Œ๋งˆ ์ƒ‰์ƒ (context.theme.colorScheme)
primary        // Primary color
onPrimary      // Primary color ์œ„ ํ…์ŠคํŠธ
secondary      // Secondary color
surface        // Surface color
background     // Background color
error          // Error color

// Semantic colors
AppColors.success
AppColors.warning
AppColors.info

Typography#

// TextTheme (context.textTheme)
displayLarge   // Large heading
headlineMedium // Medium heading
titleLarge     // Title
bodyLarge      // Body (large)
bodyMedium     // Body (medium)
labelLarge     // Label

Spacing System#

// Standard spacing
const spacing4 = 4.0;
const spacing8 = 8.0;
const spacing12 = 12.0;
const spacing16 = 16.0;
const spacing24 = 24.0;
const spacing32 = 32.0;

Responsive Layout#

// LayoutBuilder ์‚ฌ์šฉ
LayoutBuilder(
  builder: (context, constraints) {
    if (constraints.maxWidth < 600) {
      return _buildMobileLayout();
    } else if (constraints.maxWidth < 1200) {
      return _buildTabletLayout();
    } else {
      return _buildDesktopLayout();
    }
  },
)

Checklist#

  • Verify match with Figma design
  • Maximize CoUI component usage
  • Apply responsive layout
  • Support dark mode
  • Apply accessibility (Semantics)
  • Support keyboard navigation
  • @bloc: State management connection
  • @i18n: Text internationalization
  • @test: Widget test writing