Palette overview
A Palette is a type that groups several styles under an id. It is mainly used to build ContextStylers (see ContextStyler.ts).
With the make function, you can define your own instances if the provided ones don’t suit your needs.
Table of contents
Constructors
make
Constructor
Signature
export declare const make: (...styles: ASStyles.Type) => Type
Destructors
styles
Gets the underlying styles of self
Signature
export declare const styles: MTypes.OneArgFunction<Type, MTypes.OverTwo<ASStyle.Type>>
toId
Gets the id of self
Signature
export declare const toId: MTypes.OneArgFunction<Type, string>
Equivalences
equivalence
Equivalence
Signature
export declare const equivalence: Equivalence.Equivalence<Type>
Guards
has
Type guard
Signature
export declare const has: (u: unknown) => u is Type
Instances
allBrightOriginalColors
Palette instance which contains all bright original colors
Signature
export declare const allBrightOriginalColors: Type
allOriginalColors
Palette instance which contains all original colors
Signature
export declare const allOriginalColors: Type
allStandardOriginalColors
Palette instance which contains all standard original colors
Signature
export declare const allStandardOriginalColors: Type
Models
Type (interface)
Type that represents a Palette.
Signature
export interface Type extends Equal.Equal, MInspectable.Inspectable, Pipeable.Pipeable {
/** Array of styles contained by this Palette */
readonly styles: ASStyles.Type
/** @internal */
readonly [_TypeId]: _TypeId
}
moduleTag
Module tag
Signature
export declare const moduleTag: "@parischap/ansi-styles/Palette/"
Utils
append
Appends that
to self
Signature
export declare const append: (that: Type) => (self: Type) => Type