()
| 312 | } |
| 313 | |
| 314 | build(): Pattern { |
| 315 | const output = new Pattern(); |
| 316 | const marginType = this.marginTypeInput.value(); |
| 317 | const marginDistance = |
| 318 | marginType == 'None' ? 0 : this.marginDistanceInput.numberValue(); |
| 319 | const layout = new CableLayout( |
| 320 | this.cableCountInput.numberValue(), |
| 321 | this.rowsBetweenCablesInput.numberValue(), |
| 322 | this.cableEdgeRowsInput.numberValue(), |
| 323 | this.smoothingRowsInput.numberValue(), |
| 324 | this.innerCablesInput.value() == 'Enable', marginType as 'None' | 'ICord' | 'Knit', marginDistance); |
| 325 | for (let row = 0; row < 2 * layout.rowsCount; row++) |
| 326 | output.addRow(layout.computeRow(row)); |
| 327 | return output; |
| 328 | } |
| 329 | } |
| 330 | |
| 331 | PatternFactoryRegistry.register('Cables', CablePatternFactory); |
nothing calls this directly
no test coverage detected