@thi.ng/imago 0.7.7 → 0.7.9

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.
package/CHANGELOG.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # Change Log
2
2
 
3
- - **Last updated**: 2024-05-08T18:24:32Z
3
+ - **Last updated**: 2024-06-29T09:28:36Z
4
4
  - **Generator**: [thi.ng/monopub](https://thi.ng/monopub)
5
5
 
6
6
  All notable changes to this project will be documented in this file.
@@ -9,6 +9,12 @@ See [Conventional Commits](https://conventionalcommits.org/) for commit guidelin
9
9
  **Note:** Unlisted _patch_ versions only involve non-code or otherwise excluded changes
10
10
  and/or version bumps of transitive dependencies.
11
11
 
12
+ ### [0.7.8](https://github.com/thi-ng/umbrella/tree/@thi.ng/imago@0.7.8) (2024-06-21)
13
+
14
+ #### ♻️ Refactoring
15
+
16
+ - enforce uniform naming convention of internal functions ([56992b2](https://github.com/thi-ng/umbrella/commit/56992b2))
17
+
12
18
  ### [0.7.3](https://github.com/thi-ng/umbrella/tree/@thi.ng/imago@0.7.3) (2024-04-20)
13
19
 
14
20
  #### ♻️ Refactoring
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 192 standalone projects, maintained as part
10
+ > This is one of 189 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
  >
@@ -357,7 +357,7 @@ For Node.js REPL:
357
357
  const imago = await import("@thi.ng/imago");
358
358
  ```
359
359
 
360
- Package sizes (brotli'd, pre-treeshake): ESM: 4.93 KB
360
+ Package sizes (brotli'd, pre-treeshake): ESM: 4.92 KB
361
361
 
362
362
  ## Dependencies
363
363
 
package/api.d.ts CHANGED
@@ -1,4 +1,3 @@
1
- /// <reference types="node" />
2
1
  import type { Fn, Fn3, IObjectOf, Keys, Range1_4, TypedArray } from "@thi.ng/api";
3
2
  import type { ILogger } from "@thi.ng/logger";
4
3
  import type { AvifOptions, Blend, Exif, ExtendWith, FitEnum, GifOptions, Jp2Options, JpegOptions, JxlOptions, KernelEnum, Metadata, OverlayOptions, PngOptions, Sharp, TiffOptions, TileOptions, WebpOptions } from "sharp";
package/ops/output.js CHANGED
@@ -9,12 +9,12 @@ const outputProc = async (spec, input, ctx) => {
9
9
  const outDir = resolve(ctx.opts.outDir || ".");
10
10
  let output = input.clone();
11
11
  if (opts.blurhash) {
12
- await outputBlurHash(opts, output, ctx);
12
+ await __outputBlurHash(opts, output, ctx);
13
13
  return [input, false];
14
14
  }
15
15
  if (!opts.path) illegalArgs("output path missing");
16
16
  if (opts.raw) {
17
- await outputRaw(opts, output, ctx, outDir);
17
+ await __outputRaw(opts, output, ctx, outDir);
18
18
  return [input, false];
19
19
  }
20
20
  if (ctx.meta.exif && ctx.opts.keepEXIF) {
@@ -69,7 +69,7 @@ const outputProc = async (spec, input, ctx) => {
69
69
  ctx.outputs[opts.id] = path;
70
70
  return [input, false];
71
71
  };
72
- const outputRaw = async (opts, output, ctx, outDir) => {
72
+ const __outputRaw = async (opts, output, ctx, outDir) => {
73
73
  const { alpha = false, meta = false } = isPlainObject(opts.raw) ? opts.raw : {};
74
74
  if (alpha) output = output.ensureAlpha();
75
75
  const { data, info } = await output.raw().toBuffer({ resolveWithObject: true });
@@ -86,7 +86,7 @@ const outputRaw = async (opts, output, ctx, outDir) => {
86
86
  );
87
87
  }
88
88
  };
89
- const outputBlurHash = async (opts, output, ctx) => {
89
+ const __outputBlurHash = async (opts, output, ctx) => {
90
90
  const { data, info } = await output.ensureAlpha().raw().toBuffer({ resolveWithObject: true });
91
91
  const detail = opts.blurhash === true ? 4 : opts.blurhash;
92
92
  const [dx, dy] = isNumber(detail) ? [detail, detail] : detail;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@thi.ng/imago",
3
- "version": "0.7.7",
3
+ "version": "0.7.9",
4
4
  "description": "JSON & API-based declarative and extensible image processing trees/pipelines",
5
5
  "type": "module",
6
6
  "module": "./index.js",
@@ -10,7 +10,7 @@
10
10
  "type": "git",
11
11
  "url": "https://github.com/thi-ng/umbrella.git"
12
12
  },
13
- "homepage": "https://github.com/thi-ng/umbrella/tree/develop/packages/imago#readme",
13
+ "homepage": "https://thi.ng/imago",
14
14
  "funding": [
15
15
  {
16
16
  "type": "github",
@@ -36,26 +36,26 @@
36
36
  "tool:tangle": "../../node_modules/.bin/tangle src/**/*.ts"
37
37
  },
38
38
  "dependencies": {
39
- "@thi.ng/api": "^8.11.2",
40
- "@thi.ng/associative": "^6.3.60",
41
- "@thi.ng/blurhash": "^0.1.24",
42
- "@thi.ng/checks": "^3.6.4",
43
- "@thi.ng/date": "^2.7.18",
44
- "@thi.ng/defmulti": "^3.0.39",
45
- "@thi.ng/errors": "^2.5.7",
46
- "@thi.ng/file-io": "^2.1.2",
47
- "@thi.ng/logger": "^3.0.12",
48
- "@thi.ng/pixel": "^6.1.32",
49
- "@thi.ng/pixel-dither": "^1.1.130",
50
- "@thi.ng/prefixes": "^2.3.19",
51
- "sharp": "^0.33.3"
39
+ "@thi.ng/api": "^8.11.4",
40
+ "@thi.ng/associative": "^6.3.62",
41
+ "@thi.ng/blurhash": "^0.1.26",
42
+ "@thi.ng/checks": "^3.6.6",
43
+ "@thi.ng/date": "^2.7.20",
44
+ "@thi.ng/defmulti": "^3.0.41",
45
+ "@thi.ng/errors": "^2.5.9",
46
+ "@thi.ng/file-io": "^2.1.4",
47
+ "@thi.ng/logger": "^3.0.14",
48
+ "@thi.ng/pixel": "^6.1.34",
49
+ "@thi.ng/pixel-dither": "^1.1.132",
50
+ "@thi.ng/prefixes": "^2.3.21",
51
+ "sharp": "^0.33.4"
52
52
  },
53
53
  "devDependencies": {
54
- "@microsoft/api-extractor": "^7.43.2",
55
- "@thi.ng/vectors": "^7.10.31",
56
- "esbuild": "^0.21.1",
54
+ "@microsoft/api-extractor": "^7.47.0",
55
+ "@thi.ng/vectors": "^7.11.1",
56
+ "esbuild": "^0.21.5",
57
57
  "typedoc": "^0.25.13",
58
- "typescript": "^5.4.5"
58
+ "typescript": "^5.5.2"
59
59
  },
60
60
  "keywords": [
61
61
  "avif",
@@ -185,5 +185,5 @@
185
185
  "status": "alpha",
186
186
  "year": 2024
187
187
  },
188
- "gitHead": "df34b4a9e650cc7323575356de207d78933bdcf3\n"
188
+ "gitHead": "7b950c112fba0b2e7c450765b15624c3382f1354\n"
189
189
  }
package/path.d.ts CHANGED
@@ -1,4 +1,3 @@
1
- /// <reference types="node" />
2
1
  import type { TypedArray } from "@thi.ng/api";
3
2
  import type { ImgProcCtx, OutputSpec } from "./api.js";
4
3
  /**
package/units.d.ts CHANGED
@@ -6,7 +6,7 @@ export declare const coerceColor: (col: Color) => string | {
6
6
  r: number;
7
7
  g: number;
8
8
  b: number;
9
- alpha?: number | undefined;
9
+ alpha?: number;
10
10
  };
11
11
  /**
12
12
  *