@argent/x-ui
TypeScript icon, indicating that this package has built-in type declarations

1.0.0 • Public • Published

@argent/x-ui

This package provides a theme and components for use with Chakra UI

Usage

Set up the global theme

import { Button, H1, theme } from "@argent/x-ui"
import { ChakraProvider } from "@chakra-ui/react"
import { FC } from "react"

export const App: FC = () => {
  return (
    <ChakraProvider theme={theme}>
      <H1>Hello world</H1>
      <Button>Click me</Button>
    </ChakraProvider>
  )
}

Theme and utilities

The theme contains standard set of attributes which are accessed using a name or key as decribed by chakra-ui. This allows the system to change the underlying values and units without changing the component markup.

See chakra style props for examples

Components

You can use primitives and components from chakra - see chakra components for examples

Custom components and examples unique to this package are in Storybook

pnpm storybook

Design System tokens

The tokens in /src/theme/colors.generated.ts and /src/theme/semanticTokens.generated.ts are generated from master artwork in Supernova. To regenerate these (requires an access key - see .env):

You can get that access token from: https://cloud.supernova.io/user-profile/authentication

pnpm gen:tokens

Icons

The icons in /src/components/icons are generated from master artwork in Figma. To regenerate these (requires an access key - see .env):

You can get that access token from: https://www.figma.com/developers/api#access-tokens

pnpm gen:icons

Dependencies

To update all @argent-x/* dependencies to latest

pnpm update:argent

Readme

Keywords

none

Package Sidebar

Install

npm i @argent/x-ui

Weekly Downloads

540

Version

1.0.0

License

MIT

Unpacked Size

4.22 MB

Total Files

251

Last publish

Collaborators

  • gergold