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

colorette

Package Overview
Dependencies
Maintainers
1
Versions
37
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

colorette - npm Package Compare versions

Comparing version 1.2.0 to 1.2.1

index.cjs

95

index.js

@@ -1,3 +0,1 @@

"use strict"
let enabled =

@@ -30,48 +28,47 @@ !("NO_COLOR" in process.env) &&

module.exports = {
options: Object.defineProperty({}, "enabled", {
get: () => enabled,
set: (value) => (enabled = value),
}),
reset: init(0, 0),
bold: raw("\x1b[1m", "\x1b[22m", /\x1b\[22m/g, "\x1b[22m\x1b[1m"),
dim: raw("\x1b[2m", "\x1b[22m", /\x1b\[22m/g, "\x1b[22m\x1b[2m"),
italic: init(3, 23),
underline: init(4, 24),
inverse: init(7, 27),
hidden: init(8, 28),
strikethrough: init(9, 29),
black: init(30, 39),
red: init(31, 39),
green: init(32, 39),
yellow: init(33, 39),
blue: init(34, 39),
magenta: init(35, 39),
cyan: init(36, 39),
white: init(37, 39),
gray: init(90, 39),
bgBlack: init(40, 49),
bgRed: init(41, 49),
bgGreen: init(42, 49),
bgYellow: init(43, 49),
bgBlue: init(44, 49),
bgMagenta: init(45, 49),
bgCyan: init(46, 49),
bgWhite: init(47, 49),
blackBright: init(90, 39),
redBright: init(91, 39),
greenBright: init(92, 39),
yellowBright: init(93, 39),
blueBright: init(94, 39),
magentaBright: init(95, 39),
cyanBright: init(96, 39),
whiteBright: init(97, 39),
bgBlackBright: init(100, 49),
bgRedBright: init(101, 49),
bgGreenBright: init(102, 49),
bgYellowBright: init(103, 49),
bgBlueBright: init(104, 49),
bgMagentaBright: init(105, 49),
bgCyanBright: init(106, 49),
bgWhiteBright: init(107, 49),
}
export const options = Object.defineProperty({}, "enabled", {
get: () => enabled,
set: (value) => (enabled = value),
})
export const reset = init(0, 0)
export const bold = raw("\x1b[1m", "\x1b[22m", /\x1b\[22m/g, "\x1b[22m\x1b[1m")
export const dim = raw("\x1b[2m", "\x1b[22m", /\x1b\[22m/g, "\x1b[22m\x1b[2m")
export const italic = init(3, 23)
export const underline = init(4, 24)
export const inverse = init(7, 27)
export const hidden = init(8, 28)
export const strikethrough = init(9, 29)
export const black = init(30, 39)
export const red = init(31, 39)
export const green = init(32, 39)
export const yellow = init(33, 39)
export const blue = init(34, 39)
export const magenta = init(35, 39)
export const cyan = init(36, 39)
export const white = init(37, 39)
export const gray = init(90, 39)
export const bgBlack = init(40, 49)
export const bgRed = init(41, 49)
export const bgGreen = init(42, 49)
export const bgYellow = init(43, 49)
export const bgBlue = init(44, 49)
export const bgMagenta = init(45, 49)
export const bgCyan = init(46, 49)
export const bgWhite = init(47, 49)
export const blackBright = init(90, 39)
export const redBright = init(91, 39)
export const greenBright = init(92, 39)
export const yellowBright = init(93, 39)
export const blueBright = init(94, 39)
export const magentaBright = init(95, 39)
export const cyanBright = init(96, 39)
export const whiteBright = init(97, 39)
export const bgBlackBright = init(100, 49)
export const bgRedBright = init(101, 49)
export const bgGreenBright = init(102, 49)
export const bgYellowBright = init(103, 49)
export const bgBlueBright = init(104, 49)
export const bgMagentaBright = init(105, 49)
export const bgCyanBright = init(106, 49)
export const bgWhiteBright = init(107, 49)
{
"name": "colorette",
"version": "1.2.0",
"version": "1.2.1",
"description": "Color your terminal using pure idiomatic JavaScript.",
"main": "index.js",
"main": "index.cjs",
"type": "module",
"module": "index.js",
"exports": {
"./package.json": "./package.json",
".": {
"require": "./index.cjs",
"import": "./index.js"
}
},
"types": "colorette.d.ts",
"scripts": {
"test": "nyc -r lcov testmatrix test/index.js",
"test": "c8 testmatrix test/*.cjs",
"build": "node -e \"fs.writeFileSync('index.cjs',fs.readFileSync('index.js','utf8').replace(/export const /g,'exports.'),'utf8')\"",
"release": "v=$npm_package_version; git commit -am $v && git tag -s $v -m $v && git push && git push --tags && npm publish"

@@ -16,3 +26,3 @@ },

"files": [
"index.js",
"index.*",
"colorette.d.ts"

@@ -34,5 +44,5 @@ ],

"devDependencies": {
"nyc": "14.1.1",
"c8": "7.2.0",
"testmatrix": "0.1.2"
}
}

@@ -1,2 +0,2 @@

# Colorette [![](https://img.shields.io/npm/v/colorette.svg?label=&color=0080ff)](https://www.npmjs.org/package/colorette)
# Colorette [![](https://img.shields.io/npm/v/colorette.svg?label=&color=2a64e6)](https://www.npmjs.org/package/colorette)

@@ -22,3 +22,3 @@ > Color your terminal using pure idiomatic JavaScript.

```js
const { red, blue, bold } = require("colorette")
import { red, blue, bold } from "colorette"
```

@@ -91,3 +91,3 @@

```js
const { options } = require("colorette")
import { options } from "colorette"

@@ -94,0 +94,0 @@ options.enabled = false

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