feat: Flat import of markdown repo
This is a flat (without history) import of (some of) the content from our markdown module. We've imported this without history because the repo contains our blog posts and showcases posts content prior to porting them to strapi. Since this contains many images, it would balloon the size of this repo to import the full history. Instead, please refer to the history of the (archived) markdown repo at: https://github.com/freesewing/markdown
This commit is contained in:
parent
1671a896b5
commit
b34a2ee2ed
6132 changed files with 244167 additions and 0 deletions
16
markdown/dev/reference/config/options/boolean/en.md
Normal file
16
markdown/dev/reference/config/options/boolean/en.md
Normal file
|
@ -0,0 +1,16 @@
|
|||
---
|
||||
title: boolean
|
||||
---
|
||||
|
||||
If your option is either `true` or `false`, or **on** or **off** or **yes** or **no**, you can use a boolean:
|
||||
|
||||
Your boolean option should be an object with these properties:
|
||||
|
||||
- `bool` : Either `true` or `false` which will be the default
|
||||
|
||||
```js
|
||||
options: {
|
||||
withLining: { bool: true }
|
||||
}
|
||||
```
|
||||
|
231
markdown/dev/reference/config/options/co
Normal file
231
markdown/dev/reference/config/options/co
Normal file
|
@ -0,0 +1,231 @@
|
|||
---
|
||||
title: options
|
||||
---
|
||||
|
||||
Options come in 6 varities:
|
||||
|
||||
- [Constants](#constants) : A value that can't be changed
|
||||
- [Booleans](#booleans) : A value that is either `true` or `false`
|
||||
- [Percentages](#percentages) : A value in percent, with minimum and maximum values
|
||||
- [Millimeters](#millimeters) : A value in millimeter, with minimum and maximum values
|
||||
- [Degrees](#degrees) : A value in degrees, with minimum and maximum values
|
||||
- [Counters](#counters) : An integer value, with minimum and maximum values
|
||||
- [Lists](#lists) : A list of options with a default
|
||||
|
||||
Under the hood, millimeters, degrees, and counters are handled the same way.
|
||||
We use different types because it easier to understand the nature of a given option.
|
||||
|
||||
|
||||
### Constants
|
||||
|
||||
If your option is a scalar value (like a string or a number), it will be treated as a constant:
|
||||
|
||||
```js
|
||||
options: {
|
||||
collarFactor: 4.8
|
||||
}
|
||||
```
|
||||
|
||||
Rather than define constants in your code, it's good practice to set them in your configuration file.
|
||||
This way, people who extend your pattern can change them if they would like to.
|
||||
|
||||
### Booleans
|
||||
|
||||
If your option is either `true` or `false, or **on** or **off** or **yes** or **no**, you can use a boolean:
|
||||
|
||||
Your boolean option should be an object with these properties:
|
||||
|
||||
- `bool` : Either `true` or `false` which will be the default
|
||||
|
||||
```js
|
||||
options: {
|
||||
withLining: { bool: true }
|
||||
}
|
||||
```
|
||||
|
||||
### Percentages
|
||||
|
||||
Percentage options are the bread and butter of freesewing.
|
||||
Almost all your options will probably be percentages.
|
||||
They make sure that your pattern will scale regardless of size,
|
||||
and pass [the ant-man test](https://github.com/freesewing/antman).
|
||||
|
||||
Your percentage option should be an object with these properties:
|
||||
|
||||
- `pct` : The percentage
|
||||
- `min` : The minimul that's allowed
|
||||
- `max` : The maximum that's allowed
|
||||
|
||||
```js
|
||||
options: {
|
||||
acrossBackFactor: {
|
||||
pct: 97,
|
||||
min: 93,
|
||||
max: 100
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
<Note>
|
||||
|
||||
###### Percentage options will be divided by 100 when loaded
|
||||
|
||||
You specify percentages in your config file. For example, `50` means 50%.
|
||||
When your configuration is loaded, those percentages will by divided by 100.
|
||||
|
||||
So a percentage of `50` in your config file will be `0.5` when you read out that option in your pattern.
|
||||
|
||||
</Note>
|
||||
|
||||
### Millimeters
|
||||
|
||||
While we recommend using percentages where possible, sometimes that doesn't make sense.
|
||||
For those cases, you can use millimeters.
|
||||
|
||||
Your millimeter option should be an object with these properties:
|
||||
|
||||
- `mm` : The default value in millimeter
|
||||
- `min` : The minimul that's allowed
|
||||
- `max` : The maximum that's allowed
|
||||
|
||||
```js
|
||||
options: {
|
||||
elasticWidth: {
|
||||
mm: 35,
|
||||
min: 5,
|
||||
max: 80
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
### Degrees
|
||||
|
||||
For angles, use degrees.
|
||||
|
||||
Your degree option should be an object with these properties:
|
||||
|
||||
- `deg` : The default value in degrees
|
||||
- `min` : The minimul that's allowed
|
||||
- `max` : The maximum that's allowed
|
||||
|
||||
```js
|
||||
options: {
|
||||
collarAngle: {
|
||||
deg: 85,
|
||||
min: 60
|
||||
max: 130
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
### Counters
|
||||
|
||||
For a given number of things, use counters.
|
||||
Counters are for integers only. Things like number of buttons and so on.
|
||||
|
||||
Your counter option should be an object with these properties:
|
||||
|
||||
- `count` : The default integer value
|
||||
- `min` : The minimal integer value that's allowed
|
||||
- `max` : The maximum integer value that's allowed
|
||||
|
||||
```js
|
||||
options: {
|
||||
butttons: {
|
||||
count: 7,
|
||||
min: 4,
|
||||
max: 12
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
### Lists
|
||||
|
||||
Use a list option when you want to offer an array of choices.
|
||||
|
||||
Your list option should be an object with these properties:
|
||||
|
||||
- `dflt` : The default for this option
|
||||
- `list` : An array of available values options
|
||||
|
||||
```js
|
||||
options: {
|
||||
cuffStyle: {
|
||||
dflt: "angledBarrelCuff",
|
||||
list: [
|
||||
"roundedBarrelCuff",
|
||||
"angledBarrelCuff"
|
||||
"straightBarrelCuff"
|
||||
"roundedFrenchCuff"
|
||||
"angledFrenchCuff"
|
||||
"straightFrenchCuff"
|
||||
]
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
## Extra
|
||||
|
||||
Patterns also take these configuration options to facilitate frontend integration:
|
||||
|
||||
### design
|
||||
|
||||
The name of the designer:
|
||||
|
||||
```js
|
||||
design: "Joost De Cock"
|
||||
```
|
||||
|
||||
### code
|
||||
|
||||
The name of the developer:
|
||||
|
||||
```js
|
||||
code: "Joost De Cock"
|
||||
```
|
||||
|
||||
### type
|
||||
|
||||
Either `pattern` or `block`.
|
||||
|
||||
```js
|
||||
type: "pattern"
|
||||
```
|
||||
|
||||
### difficulty
|
||||
|
||||
A `1` to `5` difficulty score that indicates how hard it is to make the pattern:
|
||||
|
||||
```js
|
||||
difficulty: 3
|
||||
```
|
||||
|
||||
### tags
|
||||
|
||||
A set of tags to allow filtering of patterns on the website:
|
||||
|
||||
```js
|
||||
tags: ["underwear", "top", "basics"],
|
||||
```
|
||||
|
||||
### optionGroups
|
||||
|
||||
Organises your pattern options in groups. It expects an object where the key is the group title,
|
||||
and the value an array of options:
|
||||
|
||||
```js
|
||||
optionGroups: {
|
||||
fit: ["chestEase", "hipsEase", "stretchFactor"],
|
||||
style: [
|
||||
"armholeDrop",
|
||||
"backlineBend",
|
||||
"necklineBend",
|
||||
"necklineDrop",
|
||||
"shoulderStrapWidth",
|
||||
"shoulderStrapPlacement",
|
||||
"lengthBonus"
|
||||
]
|
||||
}
|
||||
```
|
||||
|
||||
|
17
markdown/dev/reference/config/options/constant/en.md
Normal file
17
markdown/dev/reference/config/options/constant/en.md
Normal file
|
@ -0,0 +1,17 @@
|
|||
---
|
||||
title: constant
|
||||
---
|
||||
|
||||
If your option is a scalar value (like a string or a number), it will be treated as a constant:
|
||||
|
||||
```js
|
||||
options: {
|
||||
collarFactor: 4.8
|
||||
}
|
||||
```
|
||||
|
||||
<Tip>
|
||||
Rather than define constants in your code, it's good practice to set them in your configuration file.
|
||||
This way, people who extend your pattern can change them if they would like to.
|
||||
</Tip>
|
||||
|
22
markdown/dev/reference/config/options/counter/en.md
Normal file
22
markdown/dev/reference/config/options/counter/en.md
Normal file
|
@ -0,0 +1,22 @@
|
|||
---
|
||||
title: counter
|
||||
---
|
||||
|
||||
For a given number of things, use a counter.
|
||||
Counters are for integers only. Things like number of buttons and so on.
|
||||
|
||||
Your counter option should be an object with these properties:
|
||||
|
||||
- `count` : The default integer value
|
||||
- `min` : The minimal integer value that's allowed
|
||||
- `max` : The maximum integer value that's allowed
|
||||
|
||||
```js
|
||||
options: {
|
||||
butttons: {
|
||||
count: 7,
|
||||
min: 4,
|
||||
max: 12
|
||||
}
|
||||
}
|
||||
```
|
21
markdown/dev/reference/config/options/degrees/en.md
Normal file
21
markdown/dev/reference/config/options/degrees/en.md
Normal file
|
@ -0,0 +1,21 @@
|
|||
---
|
||||
title: degrees
|
||||
---
|
||||
|
||||
For angles, use degrees.
|
||||
|
||||
Your degree option should be an object with these properties:
|
||||
|
||||
- `deg` : The default value in degrees
|
||||
- `min` : The minimul that's allowed
|
||||
- `max` : The maximum that's allowed
|
||||
|
||||
```js
|
||||
options: {
|
||||
collarAngle: {
|
||||
deg: 85,
|
||||
min: 60
|
||||
max: 130
|
||||
}
|
||||
}
|
||||
```
|
14
markdown/dev/reference/config/options/en.md
Normal file
14
markdown/dev/reference/config/options/en.md
Normal file
|
@ -0,0 +1,14 @@
|
|||
---
|
||||
title: options
|
||||
---
|
||||
|
||||
Options come in 6 varities:
|
||||
|
||||
<ReadMore list />
|
||||
|
||||
<Note>
|
||||
|
||||
Under the hood, millimeters, degrees, and counters are handled the same way.
|
||||
We use different types because it easier to understand the nature of a given option.
|
||||
|
||||
</Note>
|
26
markdown/dev/reference/config/options/list/en.md
Normal file
26
markdown/dev/reference/config/options/list/en.md
Normal file
|
@ -0,0 +1,26 @@
|
|||
---
|
||||
title: list
|
||||
---
|
||||
|
||||
Use a list option when you want to offer an array of choices.
|
||||
|
||||
Your list option should be an object with these properties:
|
||||
|
||||
- `dflt` : The default for this option
|
||||
- `list` : An array of available values options
|
||||
|
||||
```js
|
||||
options: {
|
||||
cuffStyle: {
|
||||
dflt: "angledBarrelCuff",
|
||||
list: [
|
||||
"roundedBarrelCuff",
|
||||
"angledBarrelCuff"
|
||||
"straightBarrelCuff"
|
||||
"roundedFrenchCuff"
|
||||
"angledFrenchCuff"
|
||||
"straightFrenchCuff"
|
||||
]
|
||||
}
|
||||
}
|
||||
```
|
31
markdown/dev/reference/config/options/millimeter/en.md
Normal file
31
markdown/dev/reference/config/options/millimeter/en.md
Normal file
|
@ -0,0 +1,31 @@
|
|||
---
|
||||
title: millimeter
|
||||
---
|
||||
|
||||
While we recommend using percentages where possible, sometimes that doesn't make sense.
|
||||
|
||||
For those cases, you can use a millimeter option which
|
||||
should be an object with these properties:
|
||||
|
||||
- `mm` : The default value in millimeter
|
||||
- `min` : The minimul that's allowed
|
||||
- `max` : The maximum that's allowed
|
||||
|
||||
```js
|
||||
options: {
|
||||
elasticWidth: {
|
||||
mm: 35,
|
||||
min: 5,
|
||||
max: 80
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
<Tip>
|
||||
|
||||
##### When to use a millimeter option
|
||||
|
||||
You should only use millimeter when the option refers to a physical object
|
||||
that comes in certain sizes.
|
||||
|
||||
</Tip>
|
36
markdown/dev/reference/config/options/percentage/en.md
Normal file
36
markdown/dev/reference/config/options/percentage/en.md
Normal file
|
@ -0,0 +1,36 @@
|
|||
---
|
||||
title: percentage
|
||||
---
|
||||
|
||||
Percentage options are the bread and butter of freesewing.
|
||||
|
||||
Almost all your options will probably be percentages.
|
||||
They make sure that your pattern will scale regardless of size.
|
||||
|
||||
Your percentage option should be an object with these properties:
|
||||
|
||||
- `pct` : The percentage
|
||||
- `min` : The minimul that's allowed
|
||||
- `max` : The maximum that's allowed
|
||||
|
||||
```js
|
||||
options: {
|
||||
acrossBackFactor: {
|
||||
pct: 97,
|
||||
min: 93,
|
||||
max: 100
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
<Note>
|
||||
|
||||
###### Percentage options will be divided by 100 when loaded
|
||||
|
||||
You specify percentages in your config file. For example, `50` means 50%.
|
||||
When your configuration is loaded, those percentages will by divided by 100.
|
||||
|
||||
So a percentage of `50` in your config file will be `0.5` when you read out that option in your pattern.
|
||||
|
||||
</Note>
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue