anyui-author-component
Manages AnyUI component development, including creation, modification, and cross-framework porting.
Install
mkdir -p .claude/skills/anyui-author-component && curl -L -o skill.zip "https://agentskills.codes/api/skills/download/12513" && unzip -o skill.zip -d .claude/skills/anyui-author-component && rm skill.zipInstalls to .claude/skills/anyui-author-component
Activation
This is the description your AI agent reads to decide when to run this skill — the better it matches your request, the more reliably it fires.
Create, modify, or port AnyUI components inside this repository. Use when adding a component, changing component props, slots, events, styles, React or Svelte implementations, Vue package exports, shared type surfaces, demos, generation safety, or cross-framework behavior.Key capabilities
- →Create new Vue, React, or Svelte components
- →Modify component props, slots, events, and styles
- →Port components between Vue, React, and Svelte
- →Update shared type surfaces and Vue package exports
- →Add demos for all supported frameworks
- →Ensure generation safety before running `pnpm run generate`
How it works
The skill guides the creation, modification, or porting of AnyUI components within the monorepo, ensuring consistency across Vue, React, and Svelte implementations and managing generation processes.
Inputs & outputs
When to use anyui-author-component
- →Adding a new UI component
- →Updating component props
- →Porting Vue components to React
- →Modifying shared themes
About this skill
AnyUI Author Component
Overview
Use this skill for component work in the AnyUI monorepo. Vue components are the primary API reference, but React and Svelte implementations may be either generator-owned or already hand-completed. Decide ownership before running generation.
Source Ownership
- Canonical component implementation:
packages/vue/src/packages/<folder>/. - Component styles: Vue single-file component
<style lang="scss">blocks. The build extracts them intostyles/components/*. - Shared theme and token source:
packages/vue/src/styles/. - React and Svelte package sources:
packages/react/src/andpackages/svelte/src/. - Cross-framework generator:
scripts/generate-framework-packages.mjs. - Testground demos:
packages/testground/src/demos/{vue,react,svelte}/.
Treat pnpm run generate as destructive for React and Svelte sources. It rewrites generated package files. If a component already has a complete, maintained React or Svelte implementation, do not use generation to recreate it. Patch the complete implementation directly and keep its behavior aligned with Vue.
Only update scripts/generate-framework-packages.mjs and run pnpm run generate when the target React/Svelte implementation is clearly generator-owned, incomplete, or intentionally being regenerated.
Generation Safety Rule
Before running pnpm run generate:
- Inspect the relevant React and Svelte implementation files.
- Check whether they are placeholders, obviously generated, incomplete, or already complete.
- If they are already complete, do not run generation for that change.
- If generation is still needed for another component, protect or restore unrelated complete implementations before finishing.
- After generation, inspect the diff carefully and revert unintended overwrites only for files changed by that generation step.
Naming Contract
Components use an A prefix in Vue component names and docs, with non-prefixed package exports:
- Vue file:
AButton.vue. - Folder:
buttonor lower camel case such asradioButtonGroup. - Export:
ButtonandAButton. - CSS namespace:
a-button, with BEM-like elements such asa-button__innerand modifiers such asa-button--primary. - Docs path:
docs/components/button/AButton/AButton_English.mdandAButton_Chinese.md. - Testground demo id: lower camel case, for example
button.vue,radioButtonGroup.tsx,otpInput.svelte.
New component names must start with A and use PascalCase.
Adding a Component
Prefer the scaffold:
pnpm run new
The scaffold creates the Vue package files, a Vue testground stub, updates packages/vue/src/index.ts, and adds a placeholder to the framework generator.
After scaffolding:
- Implement the Vue component in
packages/vue/src/packages/<folder>/. - Keep props, slots, and events portable across Vue, React, and Svelte.
- Decide whether the new React and Svelte implementations should be generator-owned or hand-completed.
- If generator-owned, add or update the templates in
scripts/generate-framework-packages.mjs, then runpnpm run generateand inspect the diff. - If hand-completed, create or patch
packages/react/srcandpackages/svelte/srcdirectly and do not run generation for those implementations. - Add demos for all supported frameworks in
packages/testground/src/demos/*. - Add docs and website metadata using
$anyui-docs-website. - Run
pnpm run typecheckand use/testground/for visual behavior checks.
If the scaffold is not practical, mirror the same outputs manually and keep the index, ownership decision, demos, and docs in sync.
Updating a Component
Start from the Vue source, then trace the API outward:
- Update
A<Component>.vue, nearbytypes.ts, and packageindex.ts. - Inspect React and Svelte ownership for the same component before editing.
- If the implementation is generator-owned, update
scripts/generate-framework-packages.mjs, runpnpm run generate, and inspect the diff. - If the implementation is already complete, patch
packages/react/srcorpackages/svelte/srcdirectly and do not regenerate it. - Update shared type generation only when the public type surface is actually generator-owned.
- Update testground demos and docs examples.
Use model-style APIs consistently:
- Vue:
v-model,modelValue, andupdate:modelValue. - React:
modelValue,onUpdateModelValue, andonChange. - Svelte: keep exported props and callback names aligned with the generated package conventions.
Styling Rules
Keep styling in the component SFC style block and rely on shared tokens:
- Use
var(--a-radius*),var(--a-shadow*),var(--a-focus-ring),var(--a-surface*), and color tokens such asvar(--primary)orvar(--bg-bright). - Provide fallbacks for new CSS variables when a component consumes them.
- Add
:focus-visiblewhere keyboard interaction exists. - Keep disabled and loading states non-interactive and visually distinct.
- Avoid hard-coded one-off colors when a theme token can express the state.
- Use small transform-based motion for hover, press, enter, and leave states.
The root styles/ directory is a build output copied from Vue styles and compiled by scripts/afterBuild.mjs. Make source changes under packages/vue/src/styles or in component SFC styles.
Cross-Framework Checks
The testground renders Vue, React, and Svelte demos side by side from source aliases:
pnpm run dev
Open /testground/, enable all frameworks, and compare:
- visual spacing and state parity;
- controlled and uncontrolled value behavior;
- keyboard and pointer interaction;
- dark mode and liquid glass mode;
- docs examples against the live component API.
When not to use it
- →When working outside the AnyUI monorepo
- →When modifying components that are not part of AnyUI
- →When the component is not intended for cross-framework use
Limitations
- →The skill is specific to the AnyUI monorepo
- →It requires manual inspection before running generation for React and Svelte sources
- →It assumes Vue components as the primary API reference
How it compares
This skill coordinates component development across multiple frameworks within a monorepo, providing specific rules for source ownership, generation safety, and naming conventions.
Compared to similar skills
anyui-author-component side by side with the closest alternatives in the catalog.
| Skill | Installs | Updated | Safety | Difficulty |
|---|---|---|---|---|
| anyui-author-component (this skill) | 0 | 1mo | Review | Advanced |
| screenshot-to-code | 204 | 2mo | No flags | Beginner |
| uncodixfy | 0 | 3mo | No flags | Intermediate |
| ui-ux-pro-max | 1,909 | 5mo | Review | Intermediate |
Try saying
Example prompts that trigger this skill in your AI assistant.
You might also like
screenshot-to-code
OneWave-AI
Convert UI screenshots into working HTML/CSS/React/Vue code. Detects design patterns, components, and generates responsive layouts. Use this when users provide screenshots of websites, apps, or UI designs and want code implementation.
uncodixfy
BrammekeTV
Prevents generic AI/Codex UI patterns when generating frontend code. Use this skill whenever generating HTML, CSS, React, Vue, Svelte, or any frontend UI code to enforce clean, human-designed aesthetics inspired by Linear, Raycast, Stripe, and GitHub instead of typical AI-generated UI.
ui-ux-pro-max
nextlevelbuilder
UI/UX design intelligence. 50 styles, 21 palettes, 50 font pairings, 20 charts, 8 stacks (React, Next.js, Vue, Svelte, SwiftUI, React Native, Flutter, Tailwind). Actions: plan, build, create, design, implement, review, fix, improve, optimize, enhance, refactor, check UI/UX code. Projects: website, landing page, dashboard, admin panel, e-commerce, SaaS, portfolio, blog, mobile app, .html, .tsx, .vue, .svelte. Elements: button, modal, navbar, sidebar, card, table, form, chart. Styles: glassmorphism, claymorphism, minimalism, brutalism, neumorphism, bento grid, dark mode, responsive, skeuomorphism, flat design. Topics: color palette, accessibility, animation, layout, typography, font pairing, spacing, hover, shadow, gradient.
visual-design-foundations
wshobson
Apply typography, color theory, spacing systems, and iconography principles to create cohesive visual designs. Use when establishing design tokens, building style guides, or improving visual hierarchy and consistency.
ui-design
TencentCloudBase
Professional UI design and frontend interface guidelines. Use this skill when creating web pages, mini-program interfaces, prototypes, or any frontend UI components that require distinctive, production-grade design with exceptional aesthetic quality.
ui-molecule
grvpanchal
Atomic-design guidance for Molecules — functional groups of atoms (SearchBar = input + button + icon; FormField = label + input + error) with a single cohesive purpose. Use when authoring or reviewing components under ui/molecules, composing atoms, or deciding atom vs molecule vs organism.