@thi.ng/pixel-dominant-colors 2.0.23 → 2.0.24

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. package/README.md +1 -1
  2. package/package.json +6 -6
  3. package/utils.js +1 -1
package/README.md CHANGED
@@ -7,7 +7,7 @@
7
7
  [![Mastodon Follow](https://img.shields.io/mastodon/follow/109331703950160316?domain=https%3A%2F%2Fmastodon.thi.ng&style=social)](https://mastodon.thi.ng/@toxi)
8
8
 
9
9
  > [!NOTE]
10
- > This is one of 210 standalone projects, maintained as part
10
+ > This is one of 211 standalone projects, maintained as part
11
11
  > of the [@thi.ng/umbrella](https://github.com/thi-ng/umbrella/) monorepo
12
12
  > and anti-framework.
13
13
  >
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@thi.ng/pixel-dominant-colors",
3
- "version": "2.0.23",
3
+ "version": "2.0.24",
4
4
  "description": "k-means based dominant color extraction from images/pixel buffers",
5
5
  "type": "module",
6
6
  "module": "./index.js",
@@ -39,10 +39,10 @@
39
39
  "tool:tangle": "../../node_modules/.bin/tangle src/**/*.ts"
40
40
  },
41
41
  "dependencies": {
42
- "@thi.ng/api": "^8.12.9",
43
- "@thi.ng/k-means": "^2.0.22",
44
- "@thi.ng/pixel": "^7.5.18",
45
- "@thi.ng/vectors": "^8.6.14"
42
+ "@thi.ng/api": "^8.12.10",
43
+ "@thi.ng/k-means": "^2.0.23",
44
+ "@thi.ng/pixel": "^7.5.19",
45
+ "@thi.ng/vectors": "^8.6.15"
46
46
  },
47
47
  "devDependencies": {
48
48
  "esbuild": "^0.27.0",
@@ -98,5 +98,5 @@
98
98
  "year": 2021,
99
99
  "screenshot": "pixel/dominant-colors-01.jpg"
100
100
  },
101
- "gitHead": "fdca77cabf47dd23a9ab17a5ca13e3060075c12c\n"
101
+ "gitHead": "824bf9047b5a10f777c5c5b4aeecf0c750a22c75\n"
102
102
  }
package/utils.js CHANGED
@@ -1,7 +1,7 @@
1
1
  const filterSamples = (pred, img) => {
2
2
  const samples = [];
3
3
  let i = 0;
4
- for (let p of img) {
4
+ for (const p of img) {
5
5
  if (pred(p, i)) samples.push(p);
6
6
  i++;
7
7
  }