1
0
Fork 0

fixes attr and props

This commit is contained in:
Zee 2023-04-16 17:34:13 +00:00
parent 92980289e5
commit 8cfb5342bf
2 changed files with 19 additions and 12 deletions

View file

@ -28,14 +28,23 @@ Part Part.attr(
```js
({ Point, points, Path, paths, part }) => {
({ part, points, Point, Path, paths }) => {
const part = {
name: 'examples.attribute',
draft: ({ attribute, part }
) => part.attr()
}
points.A = new Point(0,0)
points.B = new Point(0,40)
points.C = new Point(100,40)
paths.line = new Path()
.move(points.B)
.line(points.C)
.line(points.A)
.line(points.B)
.close()
.addText('I have been flipped!', 'left')
part.attr('transform', 'scale(1,-1) translate(0,-40)')
return part
}
```