@thi.ng/hiccup-svg 5.3.13 → 5.4.0
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 +7 -1
- package/README.md +21 -20
- package/api.d.ts +1 -0
- package/circle.d.ts +2 -2
- package/ellipse.d.ts +2 -2
- package/format.d.ts +4 -3
- package/format.js +1 -1
- package/gradients.d.ts +3 -3
- package/group.d.ts +3 -2
- package/image.d.ts +2 -2
- package/index.d.ts +1 -0
- package/index.js +1 -0
- package/line.d.ts +2 -2
- package/package.json +6 -3
- package/path.d.ts +2 -2
- package/pattern.d.ts +3 -0
- package/pattern.js +9 -0
- package/points.d.ts +3 -3
- package/points.js +1 -1
- package/polygon.d.ts +2 -2
- package/polyline.d.ts +2 -2
- package/rect.d.ts +2 -2
- package/svg.d.ts +2 -1
- package/text.d.ts +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Change Log
|
|
2
2
|
|
|
3
|
-
- **Last updated**: 2024-
|
|
3
|
+
- **Last updated**: 2024-09-16T13:25:24Z
|
|
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
|
+
## [5.4.0](https://github.com/thi-ng/umbrella/tree/@thi.ng/hiccup-svg@5.4.0) (2024-09-16)
|
|
13
|
+
|
|
14
|
+
#### 🚀 Features
|
|
15
|
+
|
|
16
|
+
- add pattern(), add/use Attribs type alias ([4c40840](https://github.com/thi-ng/umbrella/commit/4c40840))
|
|
17
|
+
|
|
12
18
|
## [5.3.0](https://github.com/thi-ng/umbrella/tree/@thi.ng/hiccup-svg@5.3.0) (2024-06-21)
|
|
13
19
|
|
|
14
20
|
#### 🚀 Features
|
package/README.md
CHANGED
|
@@ -179,7 +179,7 @@ For Node.js REPL:
|
|
|
179
179
|
const svg = await import("@thi.ng/hiccup-svg");
|
|
180
180
|
```
|
|
181
181
|
|
|
182
|
-
Package sizes (brotli'd, pre-treeshake): ESM: 2.
|
|
182
|
+
Package sizes (brotli'd, pre-treeshake): ESM: 2.49 KB
|
|
183
183
|
|
|
184
184
|
## Dependencies
|
|
185
185
|
|
|
@@ -192,28 +192,29 @@ Note: @thi.ng/api is in _most_ cases a type-only import (not used at runtime)
|
|
|
192
192
|
|
|
193
193
|
## Usage examples
|
|
194
194
|
|
|
195
|
-
|
|
195
|
+
17 projects in this repo's
|
|
196
196
|
[/examples](https://github.com/thi-ng/umbrella/tree/develop/examples)
|
|
197
197
|
directory are using this package:
|
|
198
198
|
|
|
199
|
-
| Screenshot | Description
|
|
200
|
-
|
|
201
|
-
| <img src="https://raw.githubusercontent.com/thi-ng/umbrella/develop/assets/examples/color-
|
|
202
|
-
| <img src="https://raw.githubusercontent.com/thi-ng/umbrella/develop/assets/examples/
|
|
203
|
-
| <img src="https://raw.githubusercontent.com/thi-ng/umbrella/develop/assets/examples/
|
|
204
|
-
| <img src="https://raw.githubusercontent.com/thi-ng/umbrella/develop/assets/examples/
|
|
205
|
-
| <img src="https://raw.githubusercontent.com/thi-ng/umbrella/develop/assets/examples/
|
|
206
|
-
| <img src="https://raw.githubusercontent.com/thi-ng/umbrella/develop/assets/
|
|
207
|
-
| <img src="https://raw.githubusercontent.com/thi-ng/umbrella/develop/assets/
|
|
208
|
-
| <img src="https://raw.githubusercontent.com/thi-ng/umbrella/develop/assets/examples/
|
|
209
|
-
| <img src="https://raw.githubusercontent.com/thi-ng/umbrella/develop/assets/examples/
|
|
210
|
-
| <img src="https://raw.githubusercontent.com/thi-ng/umbrella/develop/assets/examples/
|
|
211
|
-
| <img src="https://raw.githubusercontent.com/thi-ng/umbrella/develop/assets/examples/rdom-svg
|
|
212
|
-
| <img src="https://raw.githubusercontent.com/thi-ng/umbrella/develop/assets/examples/
|
|
213
|
-
| <img src="https://raw.githubusercontent.com/thi-ng/umbrella/develop/assets/examples/
|
|
214
|
-
| <img src="https://raw.githubusercontent.com/thi-ng/umbrella/develop/assets/examples/svg-
|
|
215
|
-
| <img src="https://raw.githubusercontent.com/thi-ng/umbrella/develop/assets/examples/
|
|
216
|
-
| <img src="https://raw.githubusercontent.com/thi-ng/umbrella/develop/assets/examples/viz-
|
|
199
|
+
| Screenshot | Description | Live demo | Source |
|
|
200
|
+
|:-------------------------------------------------------------------------------------------------------------------------------------|:---------------------------------------------------------------------------------|:---------------------------------------------------------|:--------------------------------------------------------------------------------------|
|
|
201
|
+
| <img src="https://raw.githubusercontent.com/thi-ng/umbrella/develop/assets/examples/color-contrast.avif" width="240"/> | Tool to interactively compute & visualize color contrasts against WCAG threshold | [Demo](https://demo.thi.ng/umbrella/color-contrast/) | [Source](https://github.com/thi-ng/umbrella/tree/develop/examples/color-contrast) |
|
|
202
|
+
| <img src="https://raw.githubusercontent.com/thi-ng/umbrella/develop/assets/examples/color-themes.png" width="240"/> | Probabilistic color theme generator | [Demo](https://demo.thi.ng/umbrella/color-themes/) | [Source](https://github.com/thi-ng/umbrella/tree/develop/examples/color-themes) |
|
|
203
|
+
| <img src="https://raw.githubusercontent.com/thi-ng/umbrella/develop/assets/examples/commit-heatmap.png" width="240"/> | Heatmap visualization of this mono-repo's commits | | [Source](https://github.com/thi-ng/umbrella/tree/develop/examples/commit-heatmap) |
|
|
204
|
+
| <img src="https://raw.githubusercontent.com/thi-ng/umbrella/develop/assets/examples/crypto-chart.png" width="240"/> | Basic crypto-currency candle chart with multiple moving averages plots | [Demo](https://demo.thi.ng/umbrella/crypto-chart/) | [Source](https://github.com/thi-ng/umbrella/tree/develop/examples/crypto-chart) |
|
|
205
|
+
| <img src="https://raw.githubusercontent.com/thi-ng/umbrella/develop/assets/examples/dominant-colors.png" width="240"/> | Color palette generation via dominant color extraction from uploaded images | [Demo](https://demo.thi.ng/umbrella/dominant-colors/) | [Source](https://github.com/thi-ng/umbrella/tree/develop/examples/dominant-colors) |
|
|
206
|
+
| <img src="https://raw.githubusercontent.com/thi-ng/umbrella/develop/assets/examples/gesture-analysis.png" width="240"/> | Mouse gesture / stroke analysis, simplification, corner detection | [Demo](https://demo.thi.ng/umbrella/gesture-analysis/) | [Source](https://github.com/thi-ng/umbrella/tree/develop/examples/gesture-analysis) |
|
|
207
|
+
| <img src="https://raw.githubusercontent.com/thi-ng/umbrella/develop/assets/hdom-canvas/hdom-canvas-shapes-results.png" width="240"/> | Various hdom-canvas shape drawing examples & SVG conversion / export | [Demo](https://demo.thi.ng/umbrella/hdom-canvas-shapes/) | [Source](https://github.com/thi-ng/umbrella/tree/develop/examples/hdom-canvas-shapes) |
|
|
208
|
+
| <img src="https://raw.githubusercontent.com/thi-ng/umbrella/develop/assets/examples/package-stats.png" width="240"/> | CLI util to visualize umbrella pkg stats | | [Source](https://github.com/thi-ng/umbrella/tree/develop/examples/package-stats) |
|
|
209
|
+
| <img src="https://raw.githubusercontent.com/thi-ng/umbrella/develop/assets/examples/pointfree-svg.png" width="240"/> | Generate SVG using pointfree DSL | | [Source](https://github.com/thi-ng/umbrella/tree/develop/examples/pointfree-svg) |
|
|
210
|
+
| <img src="https://raw.githubusercontent.com/thi-ng/umbrella/develop/assets/examples/poly-spline.png" width="240"/> | Polygon to cubic curve conversion & visualization | [Demo](https://demo.thi.ng/umbrella/poly-spline/) | [Source](https://github.com/thi-ng/umbrella/tree/develop/examples/poly-spline) |
|
|
211
|
+
| <img src="https://raw.githubusercontent.com/thi-ng/umbrella/develop/assets/examples/rdom-reactive-svg.jpg" width="240"/> | Animated SVG elements with reactive attributes | [Demo](https://demo.thi.ng/umbrella/rdom-reactive-svg/) | [Source](https://github.com/thi-ng/umbrella/tree/develop/examples/rdom-reactive-svg) |
|
|
212
|
+
| <img src="https://raw.githubusercontent.com/thi-ng/umbrella/develop/assets/examples/rdom-svg-nodes.png" width="240"/> | rdom powered SVG graph with draggable nodes | [Demo](https://demo.thi.ng/umbrella/rdom-svg-nodes/) | [Source](https://github.com/thi-ng/umbrella/tree/develop/examples/rdom-svg-nodes) |
|
|
213
|
+
| <img src="https://raw.githubusercontent.com/thi-ng/umbrella/develop/assets/examples/rstream-grid.jpg" width="240"/> | Interactive grid generator, SVG generation & export, undo/redo support | [Demo](https://demo.thi.ng/umbrella/rstream-grid/) | [Source](https://github.com/thi-ng/umbrella/tree/develop/examples/rstream-grid) |
|
|
214
|
+
| <img src="https://raw.githubusercontent.com/thi-ng/umbrella/develop/assets/examples/svg-resample.png" width="240"/> | SVG path parsing & dynamic resampling | [Demo](https://demo.thi.ng/umbrella/svg-resample/) | [Source](https://github.com/thi-ng/umbrella/tree/develop/examples/svg-resample) |
|
|
215
|
+
| <img src="https://raw.githubusercontent.com/thi-ng/umbrella/develop/assets/examples/svg-waveform.jpg" width="240"/> | Additive waveform synthesis & SVG visualization with undo/redo | [Demo](https://demo.thi.ng/umbrella/svg-waveform/) | [Source](https://github.com/thi-ng/umbrella/tree/develop/examples/svg-waveform) |
|
|
216
|
+
| <img src="https://raw.githubusercontent.com/thi-ng/umbrella/develop/assets/examples/viz-ridge-lines.avif" width="240"/> | Interactive ridge-line plot | [Demo](https://demo.thi.ng/umbrella/viz-ridge-lines/) | [Source](https://github.com/thi-ng/umbrella/tree/develop/examples/viz-ridge-lines) |
|
|
217
|
+
| <img src="https://raw.githubusercontent.com/thi-ng/umbrella/develop/assets/examples/viz-scatter-plot.avif" width="240"/> | Interactive scatter & line plot of low-discrepancy samples | [Demo](https://demo.thi.ng/umbrella/viz-scatter-plot/) | [Source](https://github.com/thi-ng/umbrella/tree/develop/examples/viz-scatter-plot) |
|
|
217
218
|
|
|
218
219
|
## API
|
|
219
220
|
|
package/api.d.ts
CHANGED
package/circle.d.ts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import type { Vec2Like } from "./api.js";
|
|
2
|
-
export declare const circle: (p: Vec2Like, r: number, attribs?:
|
|
1
|
+
import type { Attribs, Vec2Like } from "./api.js";
|
|
2
|
+
export declare const circle: (p: Vec2Like, r: number, attribs?: Attribs, ...body: any[]) => any[];
|
|
3
3
|
//# sourceMappingURL=circle.d.ts.map
|
package/ellipse.d.ts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import type { Vec2Like } from "./api.js";
|
|
2
|
-
export declare const ellipse: (p: Vec2Like, rx: number, ry: number, attribs?:
|
|
1
|
+
import type { Attribs, Vec2Like } from "./api.js";
|
|
2
|
+
export declare const ellipse: (p: Vec2Like, rx: number, ry: number, attribs?: Attribs, ...body: any[]) => any[];
|
|
3
3
|
//# sourceMappingURL=ellipse.d.ts.map
|
package/format.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import type { Vec2Like } from "./api.js";
|
|
1
|
+
import type { Attribs, Vec2Like } from "./api.js";
|
|
2
|
+
import type { Maybe } from "@thi.ng/api";
|
|
2
3
|
export declare let PRECISION: number;
|
|
3
4
|
/**
|
|
4
5
|
* Sets the number of fractional digits used for formatting various floating
|
|
@@ -51,7 +52,7 @@ export declare const fpoints: (pts: Vec2Like[], sep?: string) => string;
|
|
|
51
52
|
*
|
|
52
53
|
* @internal
|
|
53
54
|
*/
|
|
54
|
-
export declare const fattribs: (attribs:
|
|
55
|
+
export declare const fattribs: (attribs: Maybe<Attribs>, ...numericIDs: string[]) => Attribs;
|
|
55
56
|
/**
|
|
56
57
|
* Attempts to convert a single color attrib value. If `col` is prefixed with
|
|
57
58
|
* `$`, the value will be converted into a `url(#...)` reference. If not a
|
|
@@ -66,5 +67,5 @@ export declare const fattribs: (attribs: any, ...numericIDs: string[]) => any;
|
|
|
66
67
|
*/
|
|
67
68
|
export declare const fcolor: (col: any) => string;
|
|
68
69
|
/** @internal */
|
|
69
|
-
export declare const withoutKeys: (src:
|
|
70
|
+
export declare const withoutKeys: (src: Record<string, any>, keys: Set<PropertyKey>) => any;
|
|
70
71
|
//# sourceMappingURL=format.d.ts.map
|
package/format.js
CHANGED
|
@@ -20,7 +20,7 @@ const __numericAttribs = (attribs, ids) => {
|
|
|
20
20
|
return attribs;
|
|
21
21
|
};
|
|
22
22
|
const fattribs = (attribs, ...numericIDs) => {
|
|
23
|
-
if (!attribs) return;
|
|
23
|
+
if (!attribs) return {};
|
|
24
24
|
const res = __ftransforms(attribs);
|
|
25
25
|
let v;
|
|
26
26
|
(v = attribs.fill) && (res.fill = fcolor(v));
|
package/gradients.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { GradientStop, Vec2Like } from "./api.js";
|
|
2
|
-
export declare const linearGradient: (id: string, from: Vec2Like, to: Vec2Like, stops: GradientStop[], attribs?:
|
|
3
|
-
export declare const radialGradient: (id: string, from: Vec2Like, to: Vec2Like, fr: number, r: number, stops: GradientStop[], attribs?:
|
|
1
|
+
import type { Attribs, GradientStop, Vec2Like } from "./api.js";
|
|
2
|
+
export declare const linearGradient: (id: string, from: Vec2Like, to: Vec2Like, stops: GradientStop[], attribs?: Attribs) => any[];
|
|
3
|
+
export declare const radialGradient: (id: string, from: Vec2Like, to: Vec2Like, fr: number, r: number, stops: GradientStop[], attribs?: Attribs) => any[];
|
|
4
4
|
//# sourceMappingURL=gradients.d.ts.map
|
package/group.d.ts
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { Attribs } from "./api.js";
|
|
1
2
|
/**
|
|
2
3
|
* Creates a new SVG group element in hiccup format.
|
|
3
4
|
*
|
|
@@ -9,7 +10,7 @@
|
|
|
9
10
|
* @param attribs
|
|
10
11
|
* @param body
|
|
11
12
|
*/
|
|
12
|
-
export declare const group: (attribs:
|
|
13
|
+
export declare const group: (attribs: Attribs, ...body: any[]) => any[];
|
|
13
14
|
/** @internal */
|
|
14
|
-
export declare const __groupLayerID: (attribs:
|
|
15
|
+
export declare const __groupLayerID: (attribs: Attribs) => Attribs;
|
|
15
16
|
//# sourceMappingURL=group.d.ts.map
|
package/image.d.ts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import type { Vec2Like } from "./api.js";
|
|
2
|
-
export declare const image: (pos: Vec2Like, url: string, attribs?:
|
|
1
|
+
import type { Attribs, Vec2Like } from "./api.js";
|
|
2
|
+
export declare const image: (pos: Vec2Like, url: string, attribs?: Attribs, ...body: any[]) => any[];
|
|
3
3
|
//# sourceMappingURL=image.d.ts.map
|
package/index.d.ts
CHANGED
package/index.js
CHANGED
package/line.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import type { Vec2Like } from "./api.js";
|
|
2
|
-
export declare const line: (a: Vec2Like, b: Vec2Like, attribs?:
|
|
1
|
+
import type { Attribs, Vec2Like } from "./api.js";
|
|
2
|
+
export declare const line: (a: Vec2Like, b: Vec2Like, attribs?: Attribs, ...body: any[]) => any[];
|
|
3
3
|
export declare const hline: (y: number, attribs?: any) => any[];
|
|
4
4
|
export declare const vline: (x: number, attribs?: any) => any[];
|
|
5
5
|
//# sourceMappingURL=line.d.ts.map
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@thi.ng/hiccup-svg",
|
|
3
|
-
"version": "5.
|
|
3
|
+
"version": "5.4.0",
|
|
4
4
|
"description": "SVG element functions for @thi.ng/hiccup & related tooling",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"module": "./index.js",
|
|
@@ -38,7 +38,7 @@
|
|
|
38
38
|
"dependencies": {
|
|
39
39
|
"@thi.ng/api": "^8.11.9",
|
|
40
40
|
"@thi.ng/checks": "^3.6.11",
|
|
41
|
-
"@thi.ng/color": "^5.7.
|
|
41
|
+
"@thi.ng/color": "^5.7.4",
|
|
42
42
|
"@thi.ng/prefixes": "^2.3.26"
|
|
43
43
|
},
|
|
44
44
|
"devDependencies": {
|
|
@@ -113,6 +113,9 @@
|
|
|
113
113
|
"./path": {
|
|
114
114
|
"default": "./path.js"
|
|
115
115
|
},
|
|
116
|
+
"./pattern": {
|
|
117
|
+
"default": "./pattern.js"
|
|
118
|
+
},
|
|
116
119
|
"./points": {
|
|
117
120
|
"default": "./points.js"
|
|
118
121
|
},
|
|
@@ -137,5 +140,5 @@
|
|
|
137
140
|
"parent": "@thi.ng/hiccup",
|
|
138
141
|
"year": 2016
|
|
139
142
|
},
|
|
140
|
-
"gitHead": "
|
|
143
|
+
"gitHead": "8335e9571c2b9b13844ee4d8d24f99143c5f8816\n"
|
|
141
144
|
}
|
package/path.d.ts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import type { PathSegment } from "./api.js";
|
|
2
|
-
export declare const path: (segments: PathSegment[], attribs?:
|
|
1
|
+
import type { Attribs, PathSegment } from "./api.js";
|
|
2
|
+
export declare const path: (segments: PathSegment[], attribs?: Attribs, ...body: any[]) => any[];
|
|
3
3
|
//# sourceMappingURL=path.d.ts.map
|
package/pattern.d.ts
ADDED
package/pattern.js
ADDED
package/points.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { Vec2Like } from "./api.js";
|
|
1
|
+
import type { Attribs, Vec2Like } from "./api.js";
|
|
2
2
|
/**
|
|
3
3
|
* Shape instancing group.
|
|
4
4
|
*
|
|
@@ -14,7 +14,7 @@ import type { Vec2Like } from "./api.js";
|
|
|
14
14
|
* @param size - point size/radius
|
|
15
15
|
* @param attribs - attributes
|
|
16
16
|
*/
|
|
17
|
-
export declare const points: (pts: Iterable<Vec2Like>, shape: string, size?: number, attribs?:
|
|
17
|
+
export declare const points: (pts: Iterable<Vec2Like>, shape: string, size?: number, attribs?: Attribs, ...body: any[]) => any[];
|
|
18
18
|
/**
|
|
19
19
|
* Similar to {@link points}, but takes points from a single large flat
|
|
20
20
|
* buffer of coordinates with arbitrary striding.
|
|
@@ -33,5 +33,5 @@ export declare const points: (pts: Iterable<Vec2Like>, shape: string, size?: num
|
|
|
33
33
|
* @param size - point size/radius
|
|
34
34
|
* @param attribs - other attributes
|
|
35
35
|
*/
|
|
36
|
-
export declare const packedPoints: (pts: ArrayLike<number>, shape: string, size?: number, attribs?:
|
|
36
|
+
export declare const packedPoints: (pts: ArrayLike<number>, shape: string, size?: number, attribs?: Attribs, ...body: any[]) => any[];
|
|
37
37
|
//# sourceMappingURL=points.d.ts.map
|
package/points.js
CHANGED
|
@@ -2,7 +2,7 @@ import { fattribs, ff, withoutKeys } from "./format.js";
|
|
|
2
2
|
const points = (pts, shape, size = 1, attribs, ...body) => {
|
|
3
3
|
const group = [
|
|
4
4
|
"g",
|
|
5
|
-
fattribs(withoutKeys(attribs, /* @__PURE__ */ new Set(["shape", "size"]))),
|
|
5
|
+
fattribs(withoutKeys(attribs ?? {}, /* @__PURE__ */ new Set(["shape", "size"]))),
|
|
6
6
|
...body
|
|
7
7
|
];
|
|
8
8
|
const href = __buildSymbol(group, shape, size);
|
package/polygon.d.ts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import type { Vec2Like } from "./api.js";
|
|
2
|
-
export declare const polygon: (pts: Vec2Like[], attribs?:
|
|
1
|
+
import type { Attribs, Vec2Like } from "./api.js";
|
|
2
|
+
export declare const polygon: (pts: Vec2Like[], attribs?: Attribs, ...body: any[]) => any[];
|
|
3
3
|
//# sourceMappingURL=polygon.d.ts.map
|
package/polyline.d.ts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import type { Vec2Like } from "./api.js";
|
|
2
|
-
export declare const polyline: (pts: Vec2Like[], attribs?:
|
|
1
|
+
import type { Attribs, Vec2Like } from "./api.js";
|
|
2
|
+
export declare const polyline: (pts: Vec2Like[], attribs?: Attribs, ...body: any[]) => any[];
|
|
3
3
|
//# sourceMappingURL=polyline.d.ts.map
|
package/rect.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { Vec2Like } from "./api.js";
|
|
2
|
-
export declare const rect: (p: Vec2Like, width: number, height: number, attribs?:
|
|
1
|
+
import type { Attribs, Vec2Like } from "./api.js";
|
|
2
|
+
export declare const rect: (p: Vec2Like, width: number, height: number, attribs?: Attribs, ...body: any[]) => any[];
|
|
3
3
|
export declare const roundedRect: (p: Vec2Like, width: number, height: number, rx: number, ry: number, attribs?: any, ...body: any[]) => any[];
|
|
4
4
|
//# sourceMappingURL=rect.d.ts.map
|
package/svg.d.ts
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { Attribs } from "./api.js";
|
|
1
2
|
/**
|
|
2
3
|
* Defines an <svg> root element with default XML namespaces. By default
|
|
3
4
|
* currently still defaults to SVG version to 1.1 to support Safari and other
|
|
@@ -19,5 +20,5 @@
|
|
|
19
20
|
* @param attribs - attributes object
|
|
20
21
|
* @param body - shape primitives
|
|
21
22
|
*/
|
|
22
|
-
export declare const svg: (attribs:
|
|
23
|
+
export declare const svg: (attribs: Attribs, ...body: any[]) => any[];
|
|
23
24
|
//# sourceMappingURL=svg.d.ts.map
|
package/text.d.ts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import type { Vec2Like } from "./api.js";
|
|
2
|
-
export declare const text: (p: Vec2Like, body: string, attribs?:
|
|
1
|
+
import type { Attribs, Vec2Like } from "./api.js";
|
|
2
|
+
export declare const text: (p: Vec2Like, body: string, attribs?: Attribs, ...children: any[]) => any[];
|
|
3
3
|
//# sourceMappingURL=text.d.ts.map
|