GigiKit Guides

gk:nexus-ui

Add Nexus UI components to your project — a VNG-internal component library built on Radix UI and Tailwind CSS.

When to Use

Activate this skill whenever you want to add UI components to a project using Nexus UI:

/gk:nexus-ui
/gk:nexus-ui button
/gk:nexus-ui "I need a modal and a data table"

Prerequisites

Install the CLI

# Set registry (one time)
npm config set @gpp:registry https://registry-aawp.vnggames.net/

# Install CLI globally
npm install -g @gpp/vng-nexus-cli

No GitLab token needed. No VPN required.

Verify installation:

nexus-ui --version

Workflow Overview

Nexus UI Skill Flow

graph LR A[Check CLI] —> B{Initialized?} B — No —> C[Select theme] C —> D[nexus-ui init —theme] B — Yes —> E[What do you need?] D —> E E —> F[Browse / select components] F —> G[nexus-ui add …] G —> H[Auto-fix peer deps] H —> I[Show usage example]

Step 1: Initialize (First Time Only)

If nexus-ui-config.json doesn’t exist in your project root, the skill will ask you to pick a theme:

ThemeColorDescription
nexusBlue #155dfcDefault / neutral
fpnaOrange #f54900FPNA brand
hraRed #e7000bHRA brand
midnight-anvilDarkDark theme
novaNova theme

Then runs:

nexus-ui init --theme <selected_theme> --path src/components --no-local --yes

Files created by init:

FilePurpose
nexus-ui-config.jsonTheme & install path config
src/lib/utils.tscn() utility (clsx + tailwind-merge)
src/globals.cssTheme CSS import + Tailwind directives
src/styles/<theme>-theme.cssCSS variables for chosen theme
tailwind.config.jsUpdated with withOpacity() helper

Step 2: Browse & Select Components

The skill presents an interactive component picker. You can also describe what you need in plain language:

Natural LanguageMaps To
”popup / modal”dialog
”navigation bar / nav”navigation-menu
”info card”card
”text input / form field”input
”data table / grid”data-table
”loading / placeholder”skeleton or spinner
”notification / alert”toast or alert
”dropdown”dropdown-menu or select

Full Component List (57 components)

accordion, alert, alert-dialog, aspect-ratio, avatar, badge, breadcrumb,
button, calendar, card, chart, checkbox, code, collapsible, combobox, command,
context-menu, data-table, date-picker, date-range-picker, dialog, drawer,
dropdown-menu, event-calendar, file-uploader, filter-multi-select,
filter-multi-select-search, follower-select, hover-card, input, kbd, label,
navigation-menu, pagination, permission-selector, popover, progress,
radio-group, scroll-area, rich-text-editor, search-input, select,
select-with-chips, separator, service-selector, sheet, skeleton, spinner,
switch, table, tabs, textarea, toast, tooltip, typography

Step 3: Install Components

Single or multiple components

nexus-ui add button
nexus-ui add button card badge tabs

Components install to src/components/<name>/<name>.tsx.

Install all components at once

nexus-ui add accordion alert alert-dialog aspect-ratio avatar badge breadcrumb button calendar card chart checkbox code collapsible combobox command context-menu data-table date-picker date-range-picker dialog drawer dropdown-menu event-calendar file-uploader filter-multi-select filter-multi-select-search follower-select hover-card input kbd label navigation-menu pagination permission-selector popover progress radio-group scroll-area rich-text-editor search-input select select-with-chips separator service-selector sheet skeleton spinner switch table tabs textarea toast tooltip typography

Peer dependencies

The skill automatically detects and installs missing peer deps after nexus-ui add — no manual action required. Example output:

pnpm add @radix-ui/react-tabs @radix-ui/react-dialog

Usage Examples

After installation the skill shows you how to import and use each component:

// Button
import { Button } from '@/components/button/button'
<Button variant="default">Click me</Button>
<Button variant="secondary">Secondary</Button>
<Button variant="destructive">Delete</Button>
<Button variant="outline">Outline</Button>
<Button variant="ghost">Ghost</Button>

// Card
import { Card, CardHeader, CardTitle, CardContent } from '@/components/card/card'

// Tabs
import { Tabs, TabsList, TabsTrigger, TabsContent } from '@/components/tabs/tabs'

// Badge
import { Badge } from '@/components/badge/badge'
<Badge variant="default">Active</Badge>
<Badge variant="secondary">Draft</Badge>

// Avatar
import { Avatar, AvatarFallback } from '@/components/avatar/avatar'

Error Reference

ErrorCauseFix
nexus-ui: command not foundCLI not installedSet registry then npm install -g @gpp/vng-nexus-cli
Cannot reach Verdaccio registryNetwork issueCheck connection, retry
Component not foundWrong nameRefer to the full component list above
Theme not applyingWrong CSS importCheck globals.css has correct @import for theme
Missing peer dependencyRadix UI missingnpm add @radix-ui/react-<name>