Fluxo UIFluxo UIv0.4.93

Installation

Get started with Fluxo UI in your React project

Prerequisites

Before installing Fluxo UI, make sure you have the following:

  • React 16.8+ or React 17+
  • TypeScript 4.0+ (recommended)

NPM Installation

Install Fluxo UI using your preferred package manager. View the package on npm.

npm
npm install fluxo-ui
yarn
yarn add fluxo-ui
pnpm
pnpm add fluxo-ui

Setup

Styles are automatic

There is no required global stylesheet import. Importing any component applies that component's CSS along with the base design tokens and dark-mode support, and your bundler includes only the CSS for the components you actually import. To use a brand theme other than the default blue, see the Theming section below.

Start using components

Import and use components in your React application:

import React, { useState } from 'react';
import { Button, TextInput, Checkbox } from 'fluxo-ui';

function MyForm() {
  const [name, setName] = useState('');
  const [agreed, setAgreed] = useState(false);

  return (
    <div>
      <TextInput
        label="Full Name"
        value={name}
        onChange={(e) => setName(e.target.value)}
        placeholder="Enter your name"
      />

      <Checkbox
        checked={agreed}
        onChange={(e) => setAgreed(e.target.checked)}
        label="I agree to the terms and conditions"
      />

      <Button
        variant="primary"
        disabled={!name || !agreed}
        onClick={() => console.log('Submit')}
      >
        Submit
      </Button>
    </div>
  );
}

export default MyForm;

Theming & Dark Mode

Components render in the default blue palette out of the box. To switch to another brand theme, import that theme's CSS once at your app entry, then add the matching class to the body element. Each theme is a separate import, so only the theme you actually use is bundled.

import 'fluxo-ui/themes/purple';

document.body.classList.add('theme-purple');

Available themes

ThemeImportBody class
Blue (default)fluxo-ui/themes/bluetheme-blue
Greenfluxo-ui/themes/greentheme-green
Orangefluxo-ui/themes/orangetheme-orange
Purplefluxo-ui/themes/purpletheme-purple
Larafluxo-ui/themes/laratheme-lara
Indigofluxo-ui/themes/indigotheme-indigo
Rosefluxo-ui/themes/rosetheme-rose
Amberfluxo-ui/themes/ambertheme-amber
Tealfluxo-ui/themes/tealtheme-teal
Emeraldfluxo-ui/themes/emeraldtheme-emerald
Fuchsiafluxo-ui/themes/fuchsiatheme-fuchsia
Slatefluxo-ui/themes/slatetheme-slate

Dark mode

Add the mode-dark class to the body element. It works with or without a brand theme — no extra import is needed because dark-mode tokens ship with every component.

document.body.classList.add('theme-purple', 'mode-dark');

Loading every theme (theme switcher)

If you let users switch themes at runtime, import the all-themes bundle once instead of an individual theme:

import 'fluxo-ui/styles';

TypeScript Support

Fluxo UI is built with TypeScript and provides complete type definitions out of the box. No additional @types packages are needed.

// All components are fully typed
import { Button, ButtonProps } from 'fluxo-ui';

// Props are strongly typed with IntelliSense support
const MyButton: React.FC<ButtonProps> = (props) => {
  return <Button {...props} />;
};

AI / MCP Integration

Built-in

Fluxo UI ships with an MCP server bundled inside the package — so Claude Code, GitHub Copilot, Cursor, and any other AI assistant can write correct Fluxo UI code on the first try. No extra install, no separate package.

Enable it in Claude Code with one command:

claude mcp add fluxo-ui -- npx fluxo-ui-mcp

Next Steps

Explore Components

Browse through all available components and their documentation.

View Components →

Customization

Learn how to customize themes and styling to match your brand.

Theming Guide →

Troubleshooting

Styles not loading?

Component styles are injected automatically when you import a component, so confirm your bundler is configured to handle the CSS imports that ship inside the package (the default for Vite, Next.js, and Create React App). If only the brand colors look wrong, you likely added a theme-* class to the body without importing that theme — import it once at your entry point:

import 'fluxo-ui/themes/purple';

TypeScript errors?

Ensure your TypeScript version is 4.0+ and your tsconfig.json includes:

{
  "compilerOptions": {
    "moduleResolution": "node",
    "esModuleInterop": true,
    "allowSyntheticDefaultImports": true,
    "jsx": "react-jsx"
  }
}