0.0.0 • Published 5 months ago
@nclslbrn/iconic-palettes v0.0.0
iconic-palettes
A package to get random palette from iconic painting of art history
Installation
npm install @nclslbrn/iconic-palettes
- or -
yarn add @nclslbrn/iconic-palettes
How use it
import { getPalette } from '@nclslbrn/iconic-palettes'
// No filter
const palette = getPalette()
// Specify a random value ($fx.rand() for exemple)
const palette = getPalette({ rand: 0.6 })
// Specify temperature of palette
const palette = getPalette({ temp: 'warm' })
// Specify if you want an inverted palette (dark background with bright colors)
const palette = getPalette({ theme: 'dark' })
// Specify an artist
const palette = getPalette({ artist: "Albrecht Dürer"})
Returned palette object
The function getPalette return a palette or false if nothing match your criteria.
Every color is defined by an hexadecimal value (# include) without alpha.
Each palette has a background
and a stroke
(single color) and colors
with multiple colors.
There is also some informations about the origin of the palette in meta
(title, artist, year and techniques)
0.0.0
5 months ago