chore: Port FreeSewing.dev to docusaurus
The replaces the NextJS site powering FreeSewing.dev with a Docusaurus setup. It's part of my efforts to simplify FreeSewing's setup so we can focus on our core value proposition.
This commit is contained in:
parent
497633d1d3
commit
ab3204f9f1
692 changed files with 11037 additions and 20674 deletions
61
sites/dev/docs/reference/macros/pd/readme.mdx
Normal file
61
sites/dev/docs/reference/macros/pd/readme.mdx
Normal file
|
@ -0,0 +1,61 @@
|
|||
---
|
||||
title: pd
|
||||
---
|
||||
|
||||
The `pd` macro adds a _path dimension_ to your pattern, indicating the length
|
||||
of a path.
|
||||
|
||||
It is provided by [plugin-annotations](/reference/plugins/annotations), which is
|
||||
part of [core-plugins](/reference/plugins/core) (so it is available by default).
|
||||
|
||||
## Signature
|
||||
|
||||
```js
|
||||
macro('pd', {
|
||||
Number d,
|
||||
String id,
|
||||
Path path,
|
||||
Boolean noEndMarker,
|
||||
Boolean noStartMarker,
|
||||
String text,
|
||||
Boolean force = false,
|
||||
})
|
||||
```
|
||||
|
||||
## Example
|
||||
|
||||
<Example caption="An example of a path dimension with the pd macro">
|
||||
```js
|
||||
({ Point, Path, paths, macro, part }) => {
|
||||
|
||||
paths.example = new Path()
|
||||
.move(new Point(0,0))
|
||||
.curve(new Point(20,10), new Point(60,10), new Point(80,0))
|
||||
|
||||
macro('pd', {
|
||||
path: paths.example,
|
||||
d: 15,
|
||||
force: true,
|
||||
})
|
||||
|
||||
return part
|
||||
}
|
||||
```
|
||||
</Example>
|
||||
|
||||
## Configuration
|
||||
|
||||
| Property | Default | Type | Description |
|
||||
|----------------:|---------|---------------------|-------------|
|
||||
| `path` | | [Path](/reference/api/path) | The path to draw the dimension along |
|
||||
| `d` | 10 | Number | The offset at which to draw the dimension |
|
||||
| `text` | Path length | Number | The text to go on the dimension if not the length of the path |
|
||||
| `id` | `pd` | `string` | The ID of this macro instance |
|
||||
| `noStartMarker` | `false` | Boolean | Whether to not draw a start marker |
|
||||
| `noEndMarker` | `false` | Boolean | Whether to not draw an end marker |
|
||||
| `force` | `false` | `boolean` | Set this to `true` to display the macro output even when `paperless` is `false` |
|
||||
|
||||
## Notes
|
||||
|
||||
This macro takes the `paperless` setting into account and won't output anything when both `paperless` and `force` are `false`.
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue