schematic-symbols 0.0.77 → 0.0.79
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/index.d.ts +3 -1
- package/dist/index.js +1242 -1099
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
- package/symbols/battery_horz.ts +20 -0
- package/symbols/battery_vert.ts +4 -0
- package/symbols/potentiometer_horz.ts +1 -1
package/package.json
CHANGED
@@ -0,0 +1,20 @@
|
|
1
|
+
import { defineSymbol } from "drawing/defineSymbol"
|
2
|
+
import svgJson from "assets/generated/battery.json"
|
3
|
+
import { Primitive } from "drawing/types"
|
4
|
+
|
5
|
+
const { paths, texts, bounds, refblocks, circles } = svgJson
|
6
|
+
|
7
|
+
export default defineSymbol({
|
8
|
+
primitives: [
|
9
|
+
...Object.values(paths),
|
10
|
+
...Object.values(circles),
|
11
|
+
{ ...texts.top1, anchor: "middle_bottom" },
|
12
|
+
{ ...texts.bottom1, anchor: "middle_top" },
|
13
|
+
] as Primitive[],
|
14
|
+
ports: [
|
15
|
+
{ ...refblocks.left1, labels: ["1"] }, // TODO add more "standard" labels
|
16
|
+
{ ...refblocks.right1, labels: ["2"] }, // TODO add more "standard" labels
|
17
|
+
],
|
18
|
+
size: { width: bounds.width, height: bounds.height },
|
19
|
+
center: { x: bounds.centerX, y: bounds.centerY },
|
20
|
+
})
|
@@ -7,7 +7,7 @@ export default defineSymbol({
|
|
7
7
|
primitives: [
|
8
8
|
...Object.values(paths),
|
9
9
|
{ ...texts.bottom1, y: 0.35, anchor: "middle_top" },
|
10
|
-
{ ...texts.
|
10
|
+
{ ...texts.top1, anchor: "middle_left" },
|
11
11
|
] as any,
|
12
12
|
ports: [
|
13
13
|
{ ...refblocks.left1, labels: ["1"] }, // TODO add more "standard" labels
|