Skip to content

Commit

Permalink
refactor: also allow FILAMENT_LOAD and FILAMENT_UNLOAD macors in extr…
Browse files Browse the repository at this point in the history
…uder panel

Signed-off-by: Stefan Dej <[email protected]>
  • Loading branch information
meteyou committed Nov 3, 2023
1 parent e31e8ec commit b1975a9
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions src/components/panels/ExtruderControlPanel.vue
Original file line number Diff line number Diff line change
Expand Up @@ -99,11 +99,15 @@ export default class ExtruderControlPanel extends Mixins(BaseMixin, ControlMixin
}
get loadFilamentMacro(): PrinterStateMacro | undefined {
return this.macros.find((macro: PrinterStateMacro) => macro.name.toUpperCase() === 'LOAD_FILAMENT')
const macros = ['LOAD_FILAMENT', 'FILAMENT_LOAD']
return this.macros.find((macro: PrinterStateMacro) => macros.includes(macro.name.toUpperCase()))
}
get unloadFilamentMacro(): PrinterStateMacro | undefined {
return this.macros.find((macro: PrinterStateMacro) => macro.name.toUpperCase() === 'UNLOAD_FILAMENT')
const macros = ['UNLOAD_FILAMENT', 'FILAMENT_UNLOAD']
return this.macros.find((macro: PrinterStateMacro) => macros.includes(macro.name.toUpperCase()))
}
/**
Expand Down

0 comments on commit b1975a9

Please sign in to comment.