Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

pandacss-preset-radix-colors

Package Overview
Dependencies
Maintainers
1
Versions
16
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

pandacss-preset-radix-colors

[![Contributors][contributors-shield]][contributors-url] [![Forks][forks-shield]][forks-url] [![Stargazers][stars-shield]][stars-url] [![Issues][issues-shield]][issues-url] [![MIT License][license-shield]][license-url] [![LinkedIn][linkedin-shield]][linke

  • 0.0.1
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
1.9K
decreased by-12.95%
Maintainers
1
Weekly downloads
 
Created
Source

Contributors Forks Stargazers Issues MIT License LinkedIn

Radix Colors preset for PandaCSS

Brings Radix Colors to PandaCSS

Installation

npm install --save-dev pandacss-preset-radix-colors @radix-ui/colors

Usage

Add the preset to your PandaCSS configuration (panda.config.ts)

import { defineConfig } from "@pandacss/dev";

// Import the preset. The name can be anything you want
import radixColorsPreset from "pandacss-preset-radix-colors";

export default defineConfig({
  presets: [
    radixColorsPreset(),
    // Re-add the base and panda presets because otherwise
    // they will be removed entirely
    "@pandacss/preset-base",
    "@pandacss/preset-panda",
  ],
});

Options

Dark mode

You can add dark mode support by setting darkMode to true. The default condition has been set to .dark &, which can be changed as shown below

...
presets: [
  radixColorsPreset({
    darkMode: true,
    // darkMode: {
    //   condition: ".dark &"
    // }
  }),
],

And then you can conditionally style for dark mode using the _dark modifier. Learn more

// Also works with cva or config recipes
css({
  color: "slate.1",
  // Overwrite the color when the mode is set to dark
  _dark: {
    color: "slate.11",
  },
});

Attributions

  • Radix team for creating the wonderfully crafted colors
  • Chakra team for creating PandaCSS

Keywords

FAQs

Package last updated on 16 Jul 2023

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc