@catppuccin/palette
TypeScript icon, indicating that this package has built-in type declarations

1.1.1 • Public • Published

Logo
Catppuccin Palettes

Usage

Node

Get the NPM package:

npm install @catppuccin/palette
import { flavors, flavorEntries } from "@catppuccin/palette";
import chalk from "chalk";

// an object containing all catppuccin flavors
console.log(flavors);

// typed helper when iterating flavors
flavorEntries.map(([_, flavor]) => {
  console.log(`${flavor.name} is a ${flavor.dark ? "dark" : "light"} theme.`);
  console.log(`It has ${flavor.colorEntries.length} colors:`);

  // same for the colors
  flavor.colorEntries.map(([colorName, { hex, rgb, accent }]) => {
    console.log(
      chalk.bgRgb(rgb.r, rgb.b, rgb.g)(` ${hex} `),
      colorName,
      accent
    );
  });
  console.log("\n");
});

Deno

The library gets published to deno.land/x/catppuccin.

import { flavors, flavorEntries } from "https://deno.land/x/catppuccin/mod.ts";
import { bgRgb24 } from "https://deno.land/std/fmt/colors.ts";

// an object containing all catppuccin flavors
console.log(flavors);

// typed helper when iterating flavors
flavorEntries.map(([_, flavor]) => {
  console.log(`${flavor.name} is a ${flavor.dark ? "dark" : "light"} theme.`);
  console.log(`It has ${flavor.colorEntries.length} colors:`);

  // same for the colors
  flavor.colorEntries.map(([colorName, { hex, rgb, accent }]) => {
    console.log(bgRgb24(`  ${hex}  `, { ...rgb }), colorName, accent);
  });
  console.log("\n");
});

Other available formats

Graphics editors

Please use the respective files in the latest GitHub Release:

Programs Directory
Adobe Suite, Affinity Suite, Sip ase/
Aseprite, Gimp, Inkscape, Krita gimp/
Procreate procreate/

 

Copyright © 2021-present Catppuccin Org

Readme

Keywords

none

Package Sidebar

Install

npm i @catppuccin/palette

Weekly Downloads

1,359

Version

1.1.1

License

MIT

Unpacked Size

367 kB

Total Files

25

Last publish

Collaborators

  • hamothy
  • aekstrom
  • andreasgrafen
  • nekowinston
  • pocco81