🎨 Updated prettier config
This commit is contained in:
parent
b8e632998b
commit
6710d76b08
401 changed files with 13193 additions and 15620 deletions
|
@ -11,12 +11,12 @@ export default part => {
|
|||
paperless,
|
||||
macro,
|
||||
options
|
||||
} = part.shorthand();
|
||||
} = part.shorthand()
|
||||
|
||||
for (let id of Object.keys(part.paths)) delete part.paths[id];
|
||||
for (let id of Object.keys(part.paths)) delete part.paths[id]
|
||||
|
||||
// Cut off at yoke
|
||||
points.cbYoke = new Point(0, points.armholePitch.y);
|
||||
points.cbYoke = new Point(0, points.armholePitch.y)
|
||||
|
||||
// Paths
|
||||
paths.saBase = new Path()
|
||||
|
@ -24,95 +24,94 @@ export default part => {
|
|||
.line(points.armholePitch)
|
||||
.curve(points.armholePitchCp2, points.shoulderCp1, points.shoulder)
|
||||
.line(points.neck)
|
||||
.curve_(points.neckCp2, points.cbNeck);
|
||||
if (options.splitYoke)
|
||||
paths.saBase = paths.saBase.line(points.cbYoke).close();
|
||||
paths.seam = paths.saBase.clone();
|
||||
paths.saBase.render = false;
|
||||
paths.seam = paths.seam.close().attr("class", "fabric");
|
||||
.curve_(points.neckCp2, points.cbNeck)
|
||||
if (options.splitYoke) paths.saBase = paths.saBase.line(points.cbYoke).close()
|
||||
paths.seam = paths.saBase.clone()
|
||||
paths.saBase.render = false
|
||||
paths.seam = paths.seam.close().attr('class', 'fabric')
|
||||
|
||||
// Complete pattern?
|
||||
if (complete) {
|
||||
delete snippets.armholePitchNotch;
|
||||
points.title = new Point(points.neck.x, points.cbYoke.y / 3);
|
||||
macro("title", { at: points.title, nr: 4, title: "yoke", scale: 0.8 });
|
||||
points.logo = points.title.shift(-90, 50);
|
||||
snippets.logo = new Snippet("logo", points.logo);
|
||||
snippets.logo.attr("data-scale", 0.8);
|
||||
delete snippets.armholePitchNotch
|
||||
points.title = new Point(points.neck.x, points.cbYoke.y / 3)
|
||||
macro('title', { at: points.title, nr: 4, title: 'yoke', scale: 0.8 })
|
||||
points.logo = points.title.shift(-90, 50)
|
||||
snippets.logo = new Snippet('logo', points.logo)
|
||||
snippets.logo.attr('data-scale', 0.8)
|
||||
if (options.splitYoke) {
|
||||
points.grainlineFrom = points.cbYoke.shift(0, 20);
|
||||
points.grainlineTo = points.cbNeck.shift(0, 20);
|
||||
macro("grainline", {
|
||||
points.grainlineFrom = points.cbYoke.shift(0, 20)
|
||||
points.grainlineTo = points.cbNeck.shift(0, 20)
|
||||
macro('grainline', {
|
||||
from: points.grainlineFrom,
|
||||
to: points.grainlineTo
|
||||
});
|
||||
})
|
||||
} else {
|
||||
macro("cutonfold", {
|
||||
macro('cutonfold', {
|
||||
from: points.cbNeck,
|
||||
to: points.cbYoke,
|
||||
grainline: true
|
||||
});
|
||||
})
|
||||
}
|
||||
|
||||
macro("sprinkle", {
|
||||
snippet: "notch",
|
||||
on: ["neck", "shoulder"]
|
||||
});
|
||||
macro('sprinkle', {
|
||||
snippet: 'notch',
|
||||
on: ['neck', 'shoulder']
|
||||
})
|
||||
|
||||
if (sa) {
|
||||
paths.sa = paths.saBase.offset(sa).attr("class", "fabric sa");
|
||||
paths.sa = paths.saBase.offset(sa).attr('class', 'fabric sa')
|
||||
if (options.splitYoke) {
|
||||
paths.sa = paths.sa
|
||||
.line(points.cbNeck)
|
||||
.move(points.cbYoke)
|
||||
.line(paths.sa.start());
|
||||
.line(paths.sa.start())
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Paperless?
|
||||
if (paperless) {
|
||||
macro("pd", {
|
||||
macro('pd', {
|
||||
path: new Path().move(points.cbNeck)._curve(points.neckCp2, points.neck),
|
||||
d: 15
|
||||
});
|
||||
macro("hd", {
|
||||
})
|
||||
macro('hd', {
|
||||
from: points.cbNeck,
|
||||
to: points.neck,
|
||||
y: points.neck.y - 15 - sa
|
||||
});
|
||||
macro("ld", {
|
||||
})
|
||||
macro('ld', {
|
||||
from: points.neck,
|
||||
to: points.shoulder,
|
||||
d: 15 + sa
|
||||
});
|
||||
macro("hd", {
|
||||
})
|
||||
macro('hd', {
|
||||
from: points.cbYoke,
|
||||
to: points.armholePitch,
|
||||
y: points.cbYoke.y + 15 + sa
|
||||
});
|
||||
macro("hd", {
|
||||
})
|
||||
macro('hd', {
|
||||
from: points.cbYoke,
|
||||
to: points.shoulder,
|
||||
y: points.cbYoke.y + 30 + sa
|
||||
});
|
||||
macro("vd", {
|
||||
})
|
||||
macro('vd', {
|
||||
from: points.cbYoke,
|
||||
to: points.cbNeck,
|
||||
x: points.cbYoke.x - 15 - sa
|
||||
});
|
||||
macro("pd", {
|
||||
})
|
||||
macro('pd', {
|
||||
path: new Path()
|
||||
.move(points.armholePitch)
|
||||
.curve(points.armholePitchCp2, points.shoulderCp1, points.shoulder),
|
||||
d: 15 + sa
|
||||
});
|
||||
macro("vd", {
|
||||
})
|
||||
macro('vd', {
|
||||
from: points.armholePitch,
|
||||
to: points.shoulder,
|
||||
x: points.shoulder.x + 30 + sa
|
||||
});
|
||||
})
|
||||
}
|
||||
|
||||
return part;
|
||||
};
|
||||
return part
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue