2022-10-06 15:34:41 +02:00
|
|
|
// Import Design constructor
|
|
|
|
import { Design } from '@freesewing/core'
|
|
|
|
// Import parts
|
|
|
|
import { box } from './box.mjs'
|
|
|
|
|
|
|
|
// Create the new design
|
2022-10-08 04:24:49 +02:00
|
|
|
const Pattern = new Design({
|
2022-10-06 15:34:41 +02:00
|
|
|
data: {
|
|
|
|
/*
|
|
|
|
* If you like, you can add any data you want to your design.
|
|
|
|
* We'll add the name here as an example.
|
|
|
|
*
|
|
|
|
* If you don't use this,
|
|
|
|
* you can remove this data key enterely.
|
|
|
|
*/
|
|
|
|
name: "{{ name }}",
|
|
|
|
},
|
|
|
|
// A list of parts is all that is required.
|
|
|
|
parts: [ box ],
|
|
|
|
})
|
|
|
|
|
|
|
|
/*
|
|
|
|
* Named exports
|
|
|
|
*
|
|
|
|
* We export the design itself as well as each part individually.
|
|
|
|
* This allows us to re-use these parts in other designs.
|
|
|
|
*/
|
|
|
|
export { box, Pattern }
|
|
|
|
|