Logo Frontend Design

Frontend Design

Cộng đồng
opensesh
frontend-design

Dùng khi xây dựng component giao diện, đưa ra quyết định thiết kế cho công việc frontend, đánh giá chất lượng triển khai giao diện hoặc lên kế hoạch cho các mẫu tương tác.

Add to TypingMind

Tổng quan

Nhà phát hànhopensesh
Kho mãDESIGN-OPS
Tên kỹ năngfrontend-design
Sao
23
Bản fork
5
Tệp đi kèm
Chỉ có hướng dẫn
Giấy phépApache-2.0
Liên kết
  • Hướng dẫn bằng Markdown

    Tệp SKILL.md được mô hình tải khi cần, nên chỉ tốn token khi có yêu cầu thực sự phù hợp.

  • Dùng được với mọi LLM

    Kỹ năng AI dùng hướng dẫn viết bằng Markdown thay vì mã dành riêng cho một nhà cung cấp, nên dùng được với GPT, Claude, Gemini, Grok hoặc mô hình cục bộ.

  • Hướng dẫn có đủ mọi thứ cần thiết

    Mọi thứ mô hình cần đều nằm trong hướng dẫn — không có tệp bổ sung cần đồng bộ.

  • Mã nguồn mở

    Được opensesh công bố trên GitHub. Hãy đọc các tệp nguồn trước khi cài đặt.

Cài đặt

Cài đặt kỹ năng AI Frontend Design trong TypingMind để dùng với bất kỳ LLM nào, hoặc thêm vào một tác nhân AI khác có thể đọc SKILL.md.

1

Cài đặt trong TypingMind

TypingMind cài đặt kỹ năng trực tiếp từ thư mục GitHub — đọc SKILL.md, đóng gói các tệp tài nguyên và lưu kết quả trên máy.

  1. Mở ứng dụng và vào Plugin → Kỹ năng.
  2. Chọn "Cài đặt từ GitHub".
  3. Dán URL của thư mục kỹ năng được hiển thị bên dưới rồi xác nhận.
    https://github.com/opensesh/DESIGN-OPS/tree/main/skills/frontend-design
  4. Bật kỹ năng trong từng cuộc trò chuyện mà bạn muốn sử dụng kỹ năng đó.
Plugin → Kỹ năng → Thêm kỹ năng → Từ URL GitHub, sau đó dán URL thư mục và nhấn Tiếp tục.
2

Cài đặt trong tác nhân AI khác

Bất kỳ tác nhân AI nào đọc được định dạng Agent Skills đều có thể dùng kỹ năng này — hãy sao chép thư mục vào thư mục kỹ năng của tác nhân AI đó.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/opensesh/DESIGN-OPS.git /tmp/DESIGN-OPS
mkdir -p .claude/skills
cp -r /tmp/DESIGN-OPS/skills/frontend-design .claude/skills/frontend-design
Khởi động lại Claude Code sau khi sao chép để ứng dụng nhận kỹ năng mới.

Sử dụng trong TypingMind

Bật Frontend Design trong bất kỳ cuộc trò chuyện nào trên TypingMind, mô hình sẽ tự xử lý phần còn lại. Tên và mô tả của kỹ năng nằm trong prompt hệ thống. Ngay khi có yêu cầu phù hợp, mô hình tự tải toàn bộ hướng dẫn — bạn không cần gọi thủ công và kỹ năng không tốn token cho đến khi thực sự được dùng.

Mô hình tự nạp Frontend Design ngay khi có yêu cầu phù hợp.

Dùng được với mọi mô hình AI

Kỹ năng AI là các hướng dẫn Markdown thuần túy, không phải mã dành riêng cho một nhà cung cấp, nên bạn có thể dùng Frontend Design với cả những mô hình khác ngoài mô hình ban đầu. Chỉ cần cài đặt một lần trong TypingMind rồi dùng với GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama hoặc mô hình cục bộ do bạn tự chạy — tất cả đều dùng khóa API của riêng bạn.

  • Chỉ tải khi cần

    Prompt hệ thống chỉ chứa tên và mô tả. Hướng dẫn được tải khi có yêu cầu phù hợp đầu tiên, nên khi kỹ năng chưa được dùng, bạn không tốn token cho phần hướng dẫn.

  • Đổi mô hình ngay trong cuộc trò chuyện

    Vì kỹ năng là hướng dẫn chứ không phải mã, việc đổi mô hình không làm kỹ năng ngừng hoạt động — mô hình tiếp theo vẫn đọc cùng tệp SKILL.md.

Hướng dẫn của kỹ năng

Đây là nội dung SKILL.md mà mô hình tải. Hãy đọc trước khi cài đặt — kỹ năng là những hướng dẫn mà mô hình của bạn sẽ làm theo.

Frontend Design

Create distinctive, production-grade frontend interfaces with intentional aesthetics.

Purpose

This skill guides creation of frontend interfaces that feel genuinely designed—not auto-generated. It covers design thinking, interaction patterns, motion, forms, layout, accessibility, and performance.

When to Activate

Use this skill when:

  • Building UI components or pages
  • Making design decisions for frontend work
  • Reviewing UI implementation quality
  • Planning interaction patterns

1. Design Thinking

Before writing any code, establish your design intent:

Purpose & Context

What problem are we solving? Who uses this? Think about the user's emotional state, their goals, and what success looks like.

Aesthetic Direction

Choose a clear visual direction:

DirectionFeelWhen to Use
Warm MinimalClean, inviting, focusedDashboard UIs, tools, productivity
EditorialMagazine-like, typographicContent-heavy pages, portfolios
Soft/OrganicRounded, gentle, approachableConsumer apps, onboarding
Industrial/RawUtilitarian, honest, functionalDeveloper tools, technical docs
Luxury/RefinedSpacious, elegant, deliberateBrand sites, premium products

Key insight: Bold maximalism and refined minimalism both work—the magic is in commitment, not intensity.

The Memorable Detail

Ask yourself: What's the one thing someone will remember about this interface? Maybe it's a delightful hover state, an unexpected color choice, or how perfectly the typography flows.


2. Design System Integration

Color Philosophy

css
/* Use semantic tokens, not arbitrary colors */
--bg-primary      /* Main background */
--bg-secondary    /* Elevated surfaces */
--fg-primary      /* Primary text */
--fg-secondary    /* Secondary text */
--border-primary  /* Interactive borders */
--border-secondary /* Container borders */
--brand-primary   /* Accent/CTA color */

Typography Hierarchy

CategoryUsage
DisplayHeadlines, titles, hero text
BodyParagraphs, inputs, tabs
SmallLabels, captions, hints, metadata
AccentSpecial callouts, tech feel (use sparingly)

Border Philosophy

Borders should support, not dominate:

jsx
// Default: nearly invisible
className="border border-border-secondary"

// Hover: slightly more visible
className="hover:border-border-primary"

// Focus: full visibility
className="focus:border-border-primary"

3. Interaction Patterns

Hit Targets & Touch

ContextMinimum SizeNotes
Desktop24×24pxVisual can be smaller if hit area is expanded
Mobile44×44pxApple HIG standard
Input font≥16pxPrevents iOS Safari auto-zoom
jsx
// Expand hit target beyond visual bounds
<button className="p-2 -m-2">
  <Icon className="w-6 h-6" /> {/* Visual is 24px, hit area is 40px */}
</button>

Focus Management

  • Use :focus-visible over :focus to avoid focus rings on click
  • Use :focus-within for grouped controls (e.g., input with icon)
  • Every focusable element requires a visible focus state
  • Implement focus traps in modals/drawers per WAI-ARIA patterns

Loading States

TimingValuePurpose
Show delay150–300msPrevent flash on fast responses
Minimum visible300–500msAvoid jarring disappearance
jsx
// Don't: Show spinner immediately
{isLoading && <Spinner />}

// Do: Delay spinner appearance
const showSpinner = isLoading && loadingDuration > 200;

Optimistic Updates

Update the UI immediately when success is likely:

  1. Show change instantly
  2. Send request to server
  3. On success: confirm (subtle)
  4. On failure: rollback + show error + offer retry

Destructive Actions

PatternWhen to Use
Confirmation dialogPermanent deletion, irreversible changes
Undo with timeoutSoft deletes, sends, publishes
Type-to-confirmAccount deletion, production deployments

4. Motion & Animation

When to Animate

Animate only when it serves a purpose:

  • Clarify cause/effect: Show where something came from or went
  • Maintain context: Help users track changes during transitions
  • Deliberate delight: Reward interactions meaningfully

Don't animate for decoration or to fill silence.

Easing Selection

Property ChangingRecommended Easing
Opacity onlylinear or gentle ease
Size/ScaleeaseOut (fast start, slow end)
PositioneaseOut or spring
EntereaseOut
ExiteaseIn (slow start, fast end)

Performance Rules

GPU-accelerated (prefer these):

css
transform: translate(), scale(), rotate();
opacity;
filter;

Layout-triggering (avoid animating):

css
width, height, padding, margin;
top, left, right, bottom;
font-size, line-height;

Anti-patterns:

css
/* Never: Animates everything including layout */
transition: all 0.3s;

/* Do: Explicit properties only */
transition: transform 0.3s, opacity 0.3s;

Accessibility (prefers-reduced-motion)

Always honor the user's motion preference:

jsx
const prefersReducedMotion = window.matchMedia(
  '(prefers-reduced-motion: reduce)'
).matches;

5. Form Design

Submission Behavior

Input TypeEnter Key Behavior
Single text inputSubmits form
Multiple inputsSubmits on last field
<textarea>Creates new line
<textarea> + Cmd/Ctrl+EnterSubmits form

Validation Patterns

TimingWhat to Validate
On blurFormat, required fields
On submitAll validation, server errors
Real-timeOnly for character limits or live search

Rules:

  • Show errors adjacent to the field, not in a summary
  • On submit error, focus the first invalid field
  • Don't pre-disable submit—let users discover issues

Mobile Considerations

  • Input font ≥16px prevents iOS auto-zoom
  • Use correct type and inputmode for better keyboards:
Datatypeinputmode
Emailemail—
Phonetel—
Numbertextnumeric
Credit cardtextnumeric

6. Layout Principles

Optical Alignment

Geometry lies. Adjust ±1–2px when perception beats math:

  • Circles and triangles appear smaller than squares at same dimensions
  • Text with descenders needs more bottom padding
  • Icons may need nudging to appear centered

Nested Border Radius

Child radius must be ≤ parent radius, and curves should be concentric:

Outer radius: 16px
Gap (padding): 8px
Inner radius: 16px - 8px = 8px

Layered Shadows

Use ≥2 shadow layers to mimic real light (ambient + direct):

css
box-shadow:
  0 1px 2px rgba(0,0,0,0.06),    /* Tight, direct light */
  0 4px 12px rgba(0,0,0,0.08);   /* Soft, ambient light */

7. Accessibility

Contrast Standards

  • Prefer APCA over WCAG 2 for more accurate perceptual contrast
  • Interactive states must have more contrast than rest state

Color Independence

Never rely on color alone for meaning:

  • Error states: color + icon + text
  • Status indicators: color + label
  • Charts: color + pattern or label

Screen Reader Support

  • Icon-only buttons require aria-label
  • Decorative elements get aria-hidden="true"
  • Use native elements (button, a, label) before ARIA
  • Maintain logical heading hierarchy (h1 → h2 → h3)

8. Performance

Response Time Targets

OperationTarget
UI response to input<100ms
API mutations<500ms
Page load (LCP)<2.5s

Rendering Optimization

  • Virtualize lists >100 items
  • Use content-visibility: auto for off-screen content
  • Minimize React re-renders

Asset Loading

AssetStrategy
Above-fold imagesPreload
Below-fold imagesLazy load
FontsPreload critical, subset via unicode-range
Third-party scriptsdefer or async

9. What to Avoid

Generic AI aesthetics:

  • Overused fonts (Inter, Roboto, Arial as primary)
  • Purple gradients on white backgrounds
  • Predictable layouts without character
  • Cookie-cutter component patterns

Interaction anti-patterns:

  • transition: all (performance killer)
  • Autoplay animations
  • Disabled submit buttons before user tries
  • Blocking paste on any input
  • Color-only status indicators

Instead:

  • Make unexpected choices that feel genuinely designed
  • Match implementation complexity to aesthetic vision
  • Commit fully to your visual direction

Related Skills

  • design-system-quality
  • brand-guidelines
  • brand-voice

Version: 1.0.0 | Interaction patterns adapted from Vercel Web Interface Guidelines

Câu hỏi thường gặp

Kỹ năng AI Frontend Design làm được gì?

Dùng khi xây dựng component giao diện, đưa ra quyết định thiết kế cho công việc frontend, đánh giá chất lượng triển khai giao diện hoặc lên kế hoạch cho các mẫu tương tác.

Vì sao nên dùng Frontend Design trên TypingMind?

Vì bạn chỉ cần cài một lần rồi dùng với bất kỳ mô hình nào. Frontend Design là nội dung Markdown chứ không phải mã dành riêng cho từng nhà cung cấp, nên cùng một kỹ năng có thể chạy trên GPT-5, Claude, Gemini, Grok hoặc mô hình trên thiết bị — và bạn có thể đổi mô hình ngay trong cuộc trò chuyện mà kỹ năng vẫn hoạt động. TypingMind dùng khóa API riêng của bạn, nên bạn thanh toán trực tiếp cho nhà cung cấp thay vì trả phí thuê bao theo suất người dùng, đồng thời kỹ năng và các cuộc trò chuyện vẫn nằm trong bộ lưu trữ của bạn.

Làm thế nào để cài Frontend Design trong TypingMind?

Mở Plugin → Kỹ năng → Cài đặt từ GitHub trong TypingMind rồi dán https://github.com/opensesh/DESIGN-OPS/tree/main/skills/frontend-design. TypingMind đọc tệp SKILL.md rồi cài đặt kỹ năng để bạn có thể bật cho từng cuộc trò chuyện.

Những mô hình AI nào có thể dùng Frontend Design?

Bất kỳ mô hình nào bạn kết nối trong TypingMind. Kỹ năng AI là các hướng dẫn bằng Markdown chứ không phải mã dành riêng cho từng nhà cung cấp, nên GPT, Claude, Gemini, Grok và các mô hình chạy trên thiết bị đều có thể tải kỹ năng này khi có yêu cầu phù hợp.

Có thể dùng Frontend Design với bao nhiêu mô hình AI?

Bao nhiêu cũng được. Miễn là mô hình hỗ trợ kỹ năng, bạn có thể dùng Frontend Design với mô hình đó — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama và nhiều mô hình khác — tất cả đều trên TypingMind với khóa API riêng của bạn.

Kỹ năng AI Frontend Design có miễn phí không?

Có. Kỹ năng này được opensesh phát hành trên GitHub theo giấy phép Apache-2.0. Bạn chỉ trả tiền cho nhà cung cấp AI của mình theo số token đã dùng.

Kỹ năng AI là gì?

Kỹ năng AI là một gói hướng dẫn có thể tái sử dụng, chỉ cho mô hình AI cách thực hiện một tác vụ cụ thể. Kỹ năng tuân theo định dạng mở Agent Skills: một tệp SKILL.md chứa tên và mô tả, cùng các tập lệnh, mẫu hoặc tệp tham khảo mà mô hình có thể cần. Mô hình chỉ đọc hướng dẫn khi yêu cầu của bạn phù hợp với kỹ năng, nên kỹ năng đã cài đặt không phát sinh chi phí cho đến khi được sử dụng.

Kỹ năng AI khác gì với plugin hoặc máy chủ MCP?

Plugin hoặc máy chủ MCP cung cấp các công cụ mới mà mô hình có thể gọi. Khi mô hình gọi một công cụ, mã của công cụ đó chạy ở đâu đó và trả về kết quả. Còn kỹ năng AI cung cấp kiến thức và quy trình: cách tiếp cận tác vụ, các bước cần thực hiện và những tiêu chí mà kết quả cần đáp ứng. Kỹ năng chỉ là nội dung Markdown, nên không cần máy chủ, khóa API hay môi trường thực thi và hoạt động với mọi mô hình.

Xem tất cả

Tạo ngay không gian làm việc AI riêng

Đăng ký bản tin của chúng tôi để nhận thông báo về tính năng mới và các đợt tặng quà sắp tới 👇