chore: update deps #228

This commit is contained in:
vben
2021-02-04 21:46:35 +08:00
parent 4909a4cb25
commit 1b71db73bc
5 changed files with 62 additions and 47 deletions

View File

@@ -36,22 +36,22 @@ export function generateColors({
mixDarken,
tinycolor,
}: GenerateColorsParams) {
const lightens = new Array(19).fill(0).map((t, i) => {
const arr = new Array(19).fill(0);
const lightens = arr.map((t, i) => {
return mixLighten(color, i / 5);
});
const darkens = new Array(19).fill(0).map((t, i) => {
const darkens = arr.map((t, i) => {
return mixDarken(color, i / 5);
});
const alphaColors = new Array(19).fill(0).map((t, i) => {
const alphaColors = arr.map((t, i) => {
return tinycolor(color)
.setAlpha(i / 20)
.toRgbString();
});
const tinycolorLightens = new Array(19)
.fill(0)
const tinycolorLightens = arr
.map((t, i) => {
return tinycolor(color)
.lighten(i * 5)
@@ -59,8 +59,7 @@ export function generateColors({
})
.filter((item) => item !== '#ffffff');
const tinycolorDarkens = new Array(19)
.fill(0)
const tinycolorDarkens = arr
.map((t, i) => {
return tinycolor(color)
.darken(i * 5)