chore: Formatting
This commit is contained in:
parent
969d5ecf9f
commit
56ae493f55
37 changed files with 164 additions and 107 deletions
|
@ -20,7 +20,10 @@ export default (part) => {
|
|||
// Add pct options (that used to be mm) to the store
|
||||
store.set('buttonPlacketWidth', measurements.neck * options.buttonPlacketWidth)
|
||||
store.set('buttonholePlacketWidth', measurements.neck * options.buttonholePlacketWidth)
|
||||
store.set('buttonholePlacketFoldWidth', store.get('buttonholePlacketWidth') * options.buttonholePlacketFoldWidth)
|
||||
store.set(
|
||||
'buttonholePlacketFoldWidth',
|
||||
store.get('buttonholePlacketWidth') * options.buttonholePlacketFoldWidth
|
||||
)
|
||||
store.set('collarStandWidth', measurements.neck * options.collarStandWidth)
|
||||
store.set('sleevePlacketWidth', measurements.wrist * options.sleevePlacketWidth)
|
||||
store.set('boxPleatWidth', measurements.shoulderToShoulder * options.boxPleatWidth)
|
||||
|
|
|
@ -1,6 +1,18 @@
|
|||
export default (part) => {
|
||||
const { store, measurements, utils, sa, Point, points, Path, paths, complete, paperless, macro, options } =
|
||||
part.shorthand()
|
||||
const {
|
||||
store,
|
||||
measurements,
|
||||
utils,
|
||||
sa,
|
||||
Point,
|
||||
points,
|
||||
Path,
|
||||
paths,
|
||||
complete,
|
||||
paperless,
|
||||
macro,
|
||||
options,
|
||||
} = part.shorthand()
|
||||
|
||||
const draft = function (tweak = 1) {
|
||||
const length = measurements.neck * (1 + options.collarEase - options.collarGap) * tweak
|
||||
|
|
|
@ -35,7 +35,10 @@ export default (part) => {
|
|||
points.rightBottomHinge = points.hinge.shift(180 + hinge, width / 2)
|
||||
points.rightTopCf = points.rightCf.shift(curve + 90, width / 2)
|
||||
points.rightBottomCf = points.rightCf.shift(curve - 90, width / 2)
|
||||
points.rightBottomEdge = points.rightBottomCf.shift(curve, store.get('buttonholePlacketWidth') / 2)
|
||||
points.rightBottomEdge = points.rightBottomCf.shift(
|
||||
curve,
|
||||
store.get('buttonholePlacketWidth') / 2
|
||||
)
|
||||
|
||||
// Add control points (right side only)
|
||||
points.bottomMidCp2 = points.bottomMid.shift(0, half * 0.2)
|
||||
|
@ -48,7 +51,10 @@ export default (part) => {
|
|||
points.rightTopHingeCp2 = points.rightTopHinge.shift(90 + hinge, half * 0.2)
|
||||
points.rightTopHingeCp1 = points.rightTopHinge.shift(hinge - 90, half * 0.1)
|
||||
points.topEdgeCp1 = points.rightTopCf.rotate(-90, points.rightBottomEdge)
|
||||
points.rightTopCfCp2 = points.rightTopCf.shift(180 + curve, store.get('buttonholePlacketWidth') / 2)
|
||||
points.rightTopCfCp2 = points.rightTopCf.shift(
|
||||
180 + curve,
|
||||
store.get('buttonholePlacketWidth') / 2
|
||||
)
|
||||
|
||||
// Now do the left side
|
||||
points.leftCf = points.rightCf.flipX()
|
||||
|
@ -59,7 +65,10 @@ export default (part) => {
|
|||
points.leftTopCfCp1 = points.rightTopCfCp2.flipX()
|
||||
points.leftTopCf = points.rightTopCf.flipX()
|
||||
points.leftBottomCf = points.rightBottomCf.flipX()
|
||||
points.leftBottomEdge = points.leftBottomCf.shift(bend + 180, store.get('buttonPlacketWidth') / 2)
|
||||
points.leftBottomEdge = points.leftBottomCf.shift(
|
||||
bend + 180,
|
||||
store.get('buttonPlacketWidth') / 2
|
||||
)
|
||||
points.leftTopCfCp2 = points.leftTopCf.shift(bend + 180, store.get('buttonPlacketWidth') / 2)
|
||||
points.leftBottomEdgeCp1 = points.leftBottomCf.rotate(90, points.leftBottomEdge)
|
||||
points.leftBottomCfCp2 = points.rightBottomCfCp1.flipX()
|
||||
|
|
|
@ -1,8 +1,19 @@
|
|||
import { calculateReduction } from './shared'
|
||||
|
||||
export default (part) => {
|
||||
const { store, measurements, sa, Point, points, Path, paths, complete, macro, snippets, options } =
|
||||
part.shorthand()
|
||||
const {
|
||||
store,
|
||||
measurements,
|
||||
sa,
|
||||
Point,
|
||||
points,
|
||||
Path,
|
||||
paths,
|
||||
complete,
|
||||
macro,
|
||||
snippets,
|
||||
options,
|
||||
} = part.shorthand()
|
||||
|
||||
// Clean up
|
||||
for (const i in paths) {
|
||||
|
|
|
@ -1,6 +1,18 @@
|
|||
export default (part) => {
|
||||
const { utils, sa, Point, points, Path, paths, store, snippets, complete, paperless, macro, options } =
|
||||
part.shorthand()
|
||||
const {
|
||||
utils,
|
||||
sa,
|
||||
Point,
|
||||
points,
|
||||
Path,
|
||||
paths,
|
||||
store,
|
||||
snippets,
|
||||
complete,
|
||||
paperless,
|
||||
macro,
|
||||
options,
|
||||
} = part.shorthand()
|
||||
|
||||
const fold = store.get('buttonholePlacketFoldWidth')
|
||||
points.neckEdge = utils.lineIntersectsCurve(
|
||||
|
|
|
@ -1,7 +1,8 @@
|
|||
import { addButtons } from './shared'
|
||||
|
||||
export default (part) => {
|
||||
const { sa, store, Point, points, Path, paths, complete, paperless, macro, options } = part.shorthand()
|
||||
const { sa, store, Point, points, Path, paths, complete, paperless, macro, options } =
|
||||
part.shorthand()
|
||||
|
||||
const width = store.get('buttonPlacketWidth')
|
||||
points.placketTopFold1 = points.cfNeck.shift(0, width / 2)
|
||||
|
|
|
@ -12,7 +12,7 @@ export default (part) => {
|
|||
paperless,
|
||||
macro,
|
||||
options,
|
||||
store
|
||||
store,
|
||||
} = part.shorthand()
|
||||
|
||||
const width = store.get('sleevePlacketWidth')
|
||||
|
|
|
@ -12,7 +12,7 @@ export default (part) => {
|
|||
paperless,
|
||||
macro,
|
||||
options,
|
||||
store
|
||||
store,
|
||||
} = part.shorthand()
|
||||
|
||||
const width = store.get('sleevePlacketWidth') > 20 ? 10 : store.get('sleevePlacketWidth') / 4
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue