2023-08-02 06:58:51 +00:00
|
|
|
import ColorScheme from 'color-scheme';
|
|
|
|
|
2023-08-04 03:49:39 +00:00
|
|
|
export const get_colours = (basis) => {
|
|
|
|
const scheme = new ColorScheme;
|
|
|
|
const hexbasis = basis.toString(16).padStart(6, "0");
|
|
|
|
scheme.from_hex(hexbasis).scheme('analogic').variation('hard').distance(0.1);
|
|
|
|
console.log(scheme.colors());
|
2023-08-02 06:58:51 +00:00
|
|
|
return scheme.colors().map((cs) => parseInt('0x' + cs));
|
|
|
|
}
|
|
|
|
|