takumi-js 2.0.1 → 2.0.2
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/dist/backend/node.d.cts +1 -2
- package/dist/backend/node.d.mts +1 -2
- package/dist/backend/wasm.d.cts +1 -2
- package/dist/backend/wasm.d.mts +1 -2
- package/dist/index.d.cts +1 -2
- package/dist/index.d.mts +1 -2
- package/dist/{render-Dl2tI2sa.d.cts → render-Cb_LVX55.d.mts} +11 -7
- package/dist/{render-ZztpvN2e.d.mts → render-sRfulirT.d.cts} +11 -7
- package/dist/response.d.cts +1 -2
- package/dist/response.d.mts +1 -2
- package/dist/{types-BQoM2g3W.d.cts → types-BRKMNBAj.d.cts} +0 -1
- package/dist/{types-BQoM2g3W.d.mts → types-BRKMNBAj.d.mts} +0 -1
- package/package.json +5 -5
package/dist/backend/node.d.cts
CHANGED
package/dist/backend/node.d.mts
CHANGED
package/dist/backend/wasm.d.cts
CHANGED
package/dist/backend/wasm.d.mts
CHANGED
package/dist/index.d.cts
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
import { a as RenderOptions, c as renderAnimation, i as RenderInput, l as renderSvg, n as ImagesInput, o as RenderSvgOptions, r as RenderAnimationOptions, s as render, t as AnimationScene } from "./render-
|
|
1
|
+
import { a as RenderOptions, c as renderAnimation, i as RenderInput, l as renderSvg, n as ImagesInput, o as RenderSvgOptions, r as RenderAnimationOptions, s as render, t as AnimationScene } from "./render-sRfulirT.cjs";
|
|
2
2
|
import { AnimationOutputFormat, DitheringAlgorithm, Font, FontDetails, FontLoader, ImageSource, Keyframes, KeyframesMap, KeyframesRuleList, MeasuredNode, MeasuredTextRun, OutputFormat } from "@takumi-rs/core";
|
|
3
3
|
import { ContainerNode, FetchOptions, ImageNode, Node, NodeAttributes, NodeMetadata, ReactElementLike, TextNode } from "@takumi-rs/helpers";
|
|
4
|
-
|
|
5
4
|
//#region src/index.d.ts
|
|
6
5
|
declare module "react" {
|
|
7
6
|
interface DOMAttributes<T> {
|
package/dist/index.d.mts
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
import { a as RenderOptions, c as renderAnimation, i as RenderInput, l as renderSvg, n as ImagesInput, o as RenderSvgOptions, r as RenderAnimationOptions, s as render, t as AnimationScene } from "./render-
|
|
1
|
+
import { a as RenderOptions, c as renderAnimation, i as RenderInput, l as renderSvg, n as ImagesInput, o as RenderSvgOptions, r as RenderAnimationOptions, s as render, t as AnimationScene } from "./render-Cb_LVX55.mjs";
|
|
2
2
|
import { ContainerNode, FetchOptions, ImageNode, Node, NodeAttributes, NodeMetadata, ReactElementLike, TextNode } from "@takumi-rs/helpers";
|
|
3
3
|
import { AnimationOutputFormat, DitheringAlgorithm, Font, FontDetails, FontLoader, ImageSource, Keyframes, KeyframesMap, KeyframesRuleList, MeasuredNode, MeasuredTextRun, OutputFormat } from "@takumi-rs/core";
|
|
4
|
-
|
|
5
4
|
//#region src/index.d.ts
|
|
6
5
|
declare module "react" {
|
|
7
6
|
interface DOMAttributes<T> {
|
|
@@ -1,10 +1,9 @@
|
|
|
1
|
-
import * as napi from "@takumi-rs/core";
|
|
2
|
-
import * as wasm from "@takumi-rs/wasm";
|
|
3
1
|
import { EmojiType } from "@takumi-rs/helpers/emoji";
|
|
4
2
|
import { FetchOptions, ImageFetchCache, Node, ReactElementLike } from "@takumi-rs/helpers";
|
|
5
3
|
import { FromJsxOptions } from "@takumi-rs/helpers/jsx";
|
|
4
|
+
import * as napi from "@takumi-rs/core";
|
|
5
|
+
import * as wasm from "@takumi-rs/wasm";
|
|
6
6
|
import { ReactNode } from "react";
|
|
7
|
-
|
|
8
7
|
//#region src/render.d.ts
|
|
9
8
|
type Renderer = napi.Renderer | wasm.Renderer;
|
|
10
9
|
type ImageLoader = napi.ImageLoader | wasm.ImageLoader;
|
|
@@ -13,8 +12,11 @@ type ImageLoader = napi.ImageLoader | wasm.ImageLoader;
|
|
|
13
12
|
* (and emoji glyphs) are fetched and cached.
|
|
14
13
|
*/
|
|
15
14
|
type ImagesInput = ImageLoader[] | (FetchOptions & {
|
|
16
|
-
/** Pre-fetched entries, same as the array form. */
|
|
17
|
-
|
|
15
|
+
/** Pre-fetched entries, same as the array form. */
|
|
16
|
+
sources?: ImageLoader[];
|
|
17
|
+
/** Single-flight byte cache shared across renders. */
|
|
18
|
+
fetchCache?: ImageFetchCache;
|
|
19
|
+
/** Decode-cache default for every image this render; a source's own `cache` wins. */
|
|
18
20
|
cache?: NonNullable<ImageLoader["cache"]>;
|
|
19
21
|
});
|
|
20
22
|
/** The managed-renderer plumbing shared by every entry point. */
|
|
@@ -55,10 +57,12 @@ type RenderOptions = Managed<InnerRenderOptions>;
|
|
|
55
57
|
type RenderSvgOptions = Managed<InnerSvgRenderOptions>;
|
|
56
58
|
/** A single animation scene whose content is any renderable input. */
|
|
57
59
|
type AnimationScene = Omit<napi.AnimationScene, "node"> & {
|
|
58
|
-
/** The content to render for this scene: JSX, an HTML string, or a node tree. */
|
|
60
|
+
/** The content to render for this scene: JSX, an HTML string, or a node tree. */
|
|
61
|
+
node: RenderInput;
|
|
59
62
|
};
|
|
60
63
|
type RenderAnimationOptions = Managed<DistributiveOmit<InnerRenderAnimationOptions, "scenes"> & {
|
|
61
|
-
/** The scenes to render sequentially. */
|
|
64
|
+
/** The scenes to render sequentially. */
|
|
65
|
+
scenes: AnimationScene[];
|
|
62
66
|
}>;
|
|
63
67
|
type RenderInput = ReactNode | ReactElementLike | Node | string;
|
|
64
68
|
/**
|
|
@@ -1,10 +1,9 @@
|
|
|
1
|
+
import * as napi from "@takumi-rs/core";
|
|
2
|
+
import * as wasm from "@takumi-rs/wasm";
|
|
1
3
|
import { EmojiType } from "@takumi-rs/helpers/emoji";
|
|
2
4
|
import { FetchOptions, ImageFetchCache, Node, ReactElementLike } from "@takumi-rs/helpers";
|
|
3
5
|
import { FromJsxOptions } from "@takumi-rs/helpers/jsx";
|
|
4
|
-
import * as napi from "@takumi-rs/core";
|
|
5
|
-
import * as wasm from "@takumi-rs/wasm";
|
|
6
6
|
import { ReactNode } from "react";
|
|
7
|
-
|
|
8
7
|
//#region src/render.d.ts
|
|
9
8
|
type Renderer = napi.Renderer | wasm.Renderer;
|
|
10
9
|
type ImageLoader = napi.ImageLoader | wasm.ImageLoader;
|
|
@@ -13,8 +12,11 @@ type ImageLoader = napi.ImageLoader | wasm.ImageLoader;
|
|
|
13
12
|
* (and emoji glyphs) are fetched and cached.
|
|
14
13
|
*/
|
|
15
14
|
type ImagesInput = ImageLoader[] | (FetchOptions & {
|
|
16
|
-
/** Pre-fetched entries, same as the array form. */
|
|
17
|
-
|
|
15
|
+
/** Pre-fetched entries, same as the array form. */
|
|
16
|
+
sources?: ImageLoader[];
|
|
17
|
+
/** Single-flight byte cache shared across renders. */
|
|
18
|
+
fetchCache?: ImageFetchCache;
|
|
19
|
+
/** Decode-cache default for every image this render; a source's own `cache` wins. */
|
|
18
20
|
cache?: NonNullable<ImageLoader["cache"]>;
|
|
19
21
|
});
|
|
20
22
|
/** The managed-renderer plumbing shared by every entry point. */
|
|
@@ -55,10 +57,12 @@ type RenderOptions = Managed<InnerRenderOptions>;
|
|
|
55
57
|
type RenderSvgOptions = Managed<InnerSvgRenderOptions>;
|
|
56
58
|
/** A single animation scene whose content is any renderable input. */
|
|
57
59
|
type AnimationScene = Omit<napi.AnimationScene, "node"> & {
|
|
58
|
-
/** The content to render for this scene: JSX, an HTML string, or a node tree. */
|
|
60
|
+
/** The content to render for this scene: JSX, an HTML string, or a node tree. */
|
|
61
|
+
node: RenderInput;
|
|
59
62
|
};
|
|
60
63
|
type RenderAnimationOptions = Managed<DistributiveOmit<InnerRenderAnimationOptions, "scenes"> & {
|
|
61
|
-
/** The scenes to render sequentially. */
|
|
64
|
+
/** The scenes to render sequentially. */
|
|
65
|
+
scenes: AnimationScene[];
|
|
62
66
|
}>;
|
|
63
67
|
type RenderInput = ReactNode | ReactElementLike | Node | string;
|
|
64
68
|
/**
|
package/dist/response.d.cts
CHANGED
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
import { a as RenderOptions, i as RenderInput } from "./render-
|
|
2
|
-
|
|
1
|
+
import { a as RenderOptions, i as RenderInput } from "./render-sRfulirT.cjs";
|
|
3
2
|
//#region src/response/index.d.ts
|
|
4
3
|
type ImageResponseResult = Response & {
|
|
5
4
|
readonly ready: Promise<void>;
|
package/dist/response.d.mts
CHANGED
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
import { a as RenderOptions, i as RenderInput } from "./render-
|
|
2
|
-
|
|
1
|
+
import { a as RenderOptions, i as RenderInput } from "./render-Cb_LVX55.mjs";
|
|
3
2
|
//#region src/response/index.d.ts
|
|
4
3
|
type ImageResponseResult = Response & {
|
|
5
4
|
readonly ready: Promise<void>;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "takumi-js",
|
|
3
|
-
"version": "2.0.
|
|
3
|
+
"version": "2.0.2",
|
|
4
4
|
"description": "All-in-one Takumi package for Node.js and WebAssembly runtimes.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"css",
|
|
@@ -202,15 +202,15 @@
|
|
|
202
202
|
"publish-lint": "attw --pack . && publint --strict ."
|
|
203
203
|
},
|
|
204
204
|
"dependencies": {
|
|
205
|
-
"@takumi-rs/core": "2.0.
|
|
206
|
-
"@takumi-rs/helpers": "2.0.
|
|
207
|
-
"@takumi-rs/wasm": "2.0.
|
|
205
|
+
"@takumi-rs/core": "2.0.2",
|
|
206
|
+
"@takumi-rs/helpers": "2.0.2",
|
|
207
|
+
"@takumi-rs/wasm": "2.0.2"
|
|
208
208
|
},
|
|
209
209
|
"devDependencies": {
|
|
210
210
|
"@types/bun": "^1.3.14",
|
|
211
211
|
"@types/react": "^19.2.17",
|
|
212
212
|
"react": "^19.2.7",
|
|
213
|
-
"tsdown": "^0.22.
|
|
213
|
+
"tsdown": "^0.22.4",
|
|
214
214
|
"unrun": "^0.3.1"
|
|
215
215
|
},
|
|
216
216
|
"engines": {
|