1
0
Fork 0

chore(ursula): Port to v3 stage 2

This commit is contained in:
Benjamin F 2022-09-11 08:23:04 -07:00
parent 8ad4e6c45c
commit c91e244491
4 changed files with 60 additions and 50 deletions

View file

@ -1,7 +1,6 @@
import { front } from './front.mjs' import { front } from './front.mjs'
function ursulaBack(part) { function ursulaBack({
const {
options, options,
Point, Point,
Path, Path,
@ -16,7 +15,8 @@ function ursulaBack(part) {
sa, sa,
paperless, paperless,
macro, macro,
} = part.shorthand() part,
}) {
// Design pattern here // Design pattern here

View file

@ -1,7 +1,17 @@
import { gusset } from './gusset.mjs' import { gusset } from './gusset.mjs'
function ursulaElastic(part) { function ursulaElastic({
const { options, Point, points, store, utils, units, sa, paperless, macro } = part.shorthand() options,
Point,
points,
store,
utils,
units,
sa,
paperless,
macro,
part,
}) {
// Stretch utility method // Stretch utility method
store.set('elasticScale', utils.stretchToScale(options.elasticStretch)) store.set('elasticScale', utils.stretchToScale(options.elasticStretch))

View file

@ -1,7 +1,6 @@
import { pluginBundle } from '@freesewing/plugin-bundle' import { pluginBundle } from '@freesewing/plugin-bundle'
function ursulaFront(part) { function ursulaFront({
const {
options, options,
Point, Point,
Path, Path,
@ -16,7 +15,8 @@ function ursulaFront(part) {
sa, sa,
paperless, paperless,
macro, macro,
} = part.shorthand() part,
}) {
// Stretch utility method // Stretch utility method

View file

@ -1,7 +1,6 @@
import { back } from './back.mjs' import { back } from './back.mjs'
function ursulaGusset(part) { function ursulaGusset({
const {
options, options,
Point, Point,
Path, Path,
@ -13,7 +12,8 @@ function ursulaGusset(part) {
sa, sa,
paperless, paperless,
macro, macro,
} = part.shorthand() part,
}) {
// Create points // Create points
points.frontGussetLeft = new Point(store.get('frontGussetLeft').x, 0) points.frontGussetLeft = new Point(store.get('frontGussetLeft').x, 0)