Skip to content

Commit

Permalink
🐛 fix(collection.ts): filterBy now works
Browse files Browse the repository at this point in the history
  • Loading branch information
prjctimg committed Sep 29, 2024
1 parent 290db94 commit 430b765
Show file tree
Hide file tree
Showing 13 changed files with 748 additions and 2,831 deletions.
472 changes: 231 additions & 241 deletions lib/collection.ts

Large diffs are not rendered by default.

10 changes: 5 additions & 5 deletions lib/generators.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,14 +25,14 @@ import {
min,
max,
values,
factorIterator,
iterator,
entries,
and,
eq,
adjustHue,
rand,
inRange,
isValidArgs,

not,
keys,
} from "./internal.js";
Expand Down Expand Up @@ -398,7 +398,7 @@ function discover(
colors: Collection = [],
options: DiscoverOptions
): Collection {
if (isValidArgs(colors, 4)) {

// Initialize and sanitize parameters
const colorTokenValues = values(colors),
colorTokenKeys = keys(colors);
Expand Down Expand Up @@ -451,7 +451,7 @@ function discover(

// @ts-ignore
return palettes;
}

}

/**
Expand Down Expand Up @@ -596,7 +596,7 @@ function scheme(
return palettes;
};

return factorIterator(kind, callback, keys(PALETTE_TYPES));
return iterator(kind, callback, keys(PALETTE_TYPES));
}

export { pair, discover, hueshift, pastel, earthtone, scheme, interpolator };
Loading

1 comment on commit 430b765

@vercel
Copy link

@vercel vercel bot commented on 430b765 Sep 29, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

huetiful – ./

huetiful-git-main-my-team-84794c1e.vercel.app
huetiful-my-team-84794c1e.vercel.app
huetiful-js.com

Please sign in to comment.