Skip to content

Commit

Permalink
Fix linter requirements
Browse files Browse the repository at this point in the history
  • Loading branch information
moggieuk committed Mar 1, 2025
1 parent 896d9a2 commit 3236efe
Show file tree
Hide file tree
Showing 7 changed files with 33 additions and 44 deletions.
4 changes: 2 additions & 2 deletions src/components/dialogs/MmuEditGateMapDialog.vue
Original file line number Diff line number Diff line change
Expand Up @@ -280,8 +280,8 @@

<!-- SPOOLMAN (ADAPTED) SPOOL SELECTOR -->
<spoolman-change-spool-dialog
:showDialog="showSpoolmanSpoolChooserDialog"
:setActiveSpool="false"
:show-dialog="showSpoolmanSpoolChooserDialog"
:set-active-spool="false"
@select-spool="selectSpoolmanSpool"
@close="showSpoolmanSpoolChooserDialog = false" />

Expand Down
14 changes: 2 additions & 12 deletions src/components/dialogs/MmuEditTtgMapDialog.vue
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@
</v-col>
<v-col cols="4" class="d-flex justify-end align-center no-padding pr-10">
<v-switch
:disabled="allToolsDisabled"
v-model="allTools"
:disabled="allToolsDisabled"
:label="$t('Panels.MmuPanel.TtgMapDialog.AllTools')"
hide-details
class="short-switch"></v-switch>
Expand All @@ -36,9 +36,9 @@
<v-row>
<template v-for="(g, t) in localTtgMap">
<v-col
cols="1"
v-if="toolMetaData[t].inUse || allTools"
:key="t"
cols="1"
class="no-padding min-width-card">
<v-card :class="toolCardClass(t)" @click="selectTool(t)">
<v-card-title class="justify-center">{{ toolText(t) }}</v-card-title>
Expand Down Expand Up @@ -192,8 +192,6 @@
:details="item"
:selected-es-group="localEndlessSpoolGroups[selectedGate] ?? null"
:selected-gate="selectedGate ?? null"
@mouseover="onGateHover"
@mouseleave="onGateLeave"
@select-gate="selectGate" />
</template>
</v-data-table>
Expand Down Expand Up @@ -359,14 +357,6 @@ export default class MmuEditTtgMapDialog extends Mixins(BaseMixin, MmuMixin) {
}
}
private onGateHover(gate) {
// TODO: Maybe tooltip to indicate compatibility
}
private onGateLeave(gate) {
// TODO: Maybe tooltip to indicate compatibility
}
private selectGate(gate, item) {

Check warning on line 360 in src/components/dialogs/MmuEditTtgMapDialog.vue

View workflow job for this annotation

GitHub Actions / ESLint

src/components/dialogs/MmuEditTtgMapDialog.vue#L360

'item' is defined but never used (@typescript-eslint/no-unused-vars)
this.selectedGate = gate
Vue.set(this.localTtgMap, this.selectedTool, gate)
Expand Down
4 changes: 2 additions & 2 deletions src/components/dialogs/MmuRecoverStateDialog.vue
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,8 @@
</v-col>
<v-col class="col-5 d-flex justify-end align-center">
<v-select
:items="toolsList"
v-model="selectedTool"
:items="toolsList"
:error-messages="toolErrorMessage"
outlined
dense />
Expand All @@ -52,8 +52,8 @@
</v-col>
<v-col class="col-5 d-flex justify-end align-center">
<v-select
:items="gatesList"
v-model="selectedGate"
:items="gatesList"
:error-messages="gateErrorMessage"
outlined
dense />
Expand Down
11 changes: 5 additions & 6 deletions src/components/panels/Mmu/MmuClogMeter.vue
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,15 @@
:stroke-dasharray="circumference"
:stroke-dashoffset="dialArc"></circle>
<circle
ref="dialCircle"
cx="70"
cy="70"
r="50"
class="primary-color"
fill="transparent"
stroke-width="18"
:stroke-dasharray="circumference"
:stroke-dashoffset="dashOffset"
ref="dialCircle"></circle>
:stroke-dashoffset="dashOffset" />
</g>
<g :transform="'rotate(' + headroomRotate + ' 70 70)'">
<circle
Expand All @@ -35,20 +35,19 @@
stroke-width="18"
opacity="0.4"
:stroke-dasharray="circumference"
:stroke-dashoffset="headroomArc"></circle>
:stroke-dashoffset="headroomArc" />
</g>

<line
ref="minHeadroomLine"
:x1="x1MinHeadroom"
:y1="y1MinHeadroom"
x2="70"
y2="70"
:class="{ 'warning-color': headroomWarning, 'primary-color': !headroomWarning }"
stroke-width="4"
stroke-dashoffset="0"
stroke-dasharray="25,65"
ref="minHeadroomLine" />

stroke-dasharray="25,65" />
<line
:x1="x1Start"
:y1="y1Start"
Expand Down
30 changes: 15 additions & 15 deletions src/components/panels/Mmu/MmuControls.vue
Original file line number Diff line number Diff line change
Expand Up @@ -3,19 +3,19 @@
<v-row dense>
<v-col cols="6">
<v-tooltip top color="secondary">
<template v-slot:activator="{ on }">
<template activator="{ on }">

Check warning on line 6 in src/components/panels/Mmu/MmuControls.vue

View workflow job for this annotation

GitHub Actions / ESLint

src/components/panels/Mmu/MmuControls.vue#L6

`<template>` require directive (vue/no-lone-template)
<v-btn
block
small
color="secondary"
:class="btnClass"
ref="refBtn"

Check warning on line 12 in src/components/panels/Mmu/MmuControls.vue

View workflow job for this annotation

GitHub Actions / ESLint

src/components/panels/Mmu/MmuControls.vue#L12

Attribute "ref" should go before ":class" (vue/attributes-order)
class="base-btn"
v-on="showTooltip ? on : {}"
:disabled="
!canSend || [GATE_AVAILABLE, GATE_AVAILABLE_FROM_BUFFER].includes(currentGateStatus)
"
:loading="loadings.includes('mmu_preload')"
v-on="showTooltip ? on : {}"
@click="doLoadingSend('MMU_PRELOAD', 'mmu_preload')">
<v-icon left>{{ mdiDownloadOutline }}</v-icon>
{{ $t('Panels.MmuPanel.ButtonPreload') }}
Expand All @@ -26,16 +26,16 @@
</v-col>
<v-col cols="6">
<v-tooltip top color="secondary">
<template v-slot:activator="{ on }">
<template activator="{ on }">

Check warning on line 29 in src/components/panels/Mmu/MmuControls.vue

View workflow job for this annotation

GitHub Actions / ESLint

src/components/panels/Mmu/MmuControls.vue#L29

`<template>` require directive (vue/no-lone-template)
<v-btn
block
small
color="secondary"
:class="btnClass"
class="base-btn"
v-on="showTooltip ? on : {}"
:disabled="!canSend || [GATE_EMPTY].includes(currentGateStatus)"
:loading="loadings.includes('mmu_eject')"
v-on="showTooltip ? on : {}"
@click="doLoadingSend('MMU_EJECT', 'mmu_eject')">
<v-icon left>{{ mdiEject }}</v-icon>
{{ $t('Panels.MmuPanel.ButtonEject') }}
Expand All @@ -48,16 +48,16 @@
<v-row dense>
<v-col cols="6">
<v-tooltip top color="secondary">
<template v-slot:activator="{ on }">
<template activator="{ on }">

Check warning on line 51 in src/components/panels/Mmu/MmuControls.vue

View workflow job for this annotation

GitHub Actions / ESLint

src/components/panels/Mmu/MmuControls.vue#L51

`<template>` require directive (vue/no-lone-template)
<v-btn
block
small
color="secondary"
:class="btnClass"
class="base-btn"
v-on="showTooltip ? on : {}"
:disabled="!canSend"
:loading="loadings.includes('mmu_check_gate')"
v-on="showTooltip ? on : {}"
@click="doLoadingSend('MMU_CHECK_GATE', 'mmu_check_gate')">
<v-icon left>{{ mdiCheck }}</v-icon>
{{ $t('Panels.MmuPanel.ButtonCheckGate') }}
Expand All @@ -68,16 +68,16 @@
</v-col>
<v-col cols="6">
<v-tooltip top color="secondary">
<template v-slot:activator="{ on }">
<template activator="{ on }">

Check warning on line 71 in src/components/panels/Mmu/MmuControls.vue

View workflow job for this annotation

GitHub Actions / ESLint

src/components/panels/Mmu/MmuControls.vue#L71

`<template>` require directive (vue/no-lone-template)
<v-btn
block
small
color="secondary"
:class="btnClass"
class="base-btn"
v-on="showTooltip ? on : {}"
:disabled="!canSend"
:loading="loadings.includes('mmu_recover')"
v-on="showTooltip ? on : {}"
@click="doLoadingSend('MMU_RECOVER', 'mmu_recover')">
<v-icon left>{{ mdiAutoFix }}</v-icon>
{{ $t('Panels.MmuPanel.ButtonRecover') }}
Expand All @@ -91,16 +91,16 @@
<v-col cols="2"></v-col>
<v-col cols="8">
<v-tooltip top color="secondary">
<template v-slot:activator="{ on }">
<template activator="{ on }">

Check warning on line 94 in src/components/panels/Mmu/MmuControls.vue

View workflow job for this annotation

GitHub Actions / ESLint

src/components/panels/Mmu/MmuControls.vue#L94

`<template>` require directive (vue/no-lone-template)
<v-btn
block
small
color="secondary"
:class="btnClass"
class="base-btn"
v-on="showTooltip ? on : {}"
:disabled="!canSend || !isMmuPausedAndLocked"
:loading="loadings.includes('mmu_unlock')"
v-on="showTooltip ? on : {}"
@click="doLoadingSend('MMU_UNLOCK', 'mmu_unlock')">
<v-icon left>{{ mdiThermometerPlus }}</v-icon>
{{ $t('Panels.MmuPanel.ButtonUnlock') }}
Expand All @@ -114,16 +114,16 @@
<v-row>
<v-col cols="6">
<v-tooltip top color="secondary">
<template v-slot:activator="{ on }">
<template activator="{ on }">

Check warning on line 117 in src/components/panels/Mmu/MmuControls.vue

View workflow job for this annotation

GitHub Actions / ESLint

src/components/panels/Mmu/MmuControls.vue#L117

`<template>` require directive (vue/no-lone-template)
<v-btn
large
block
color="secondary"
:class="btnClass"
class="base-btn wrap-text-btn"
v-on="showTooltip ? on : {}"
:disabled="!canSend || filamentPos === FILAMENT_POS_UNLOADED"
:loading="loadings.includes('mmu_unload')"
v-on="showTooltip ? on : {}"
@click="doLoadingSend('MMU_UNLOAD', 'mmu_unload')">
<v-icon left>{{ mdiUpload }}</v-icon>
{{ unloadButtonText }}
Expand All @@ -134,16 +134,16 @@
</v-col>
<v-col cols="6">
<v-tooltip top color="secondary">
<template v-slot:activator="{ on }">
<template activator="{ on }">

Check warning on line 137 in src/components/panels/Mmu/MmuControls.vue

View workflow job for this annotation

GitHub Actions / ESLint

src/components/panels/Mmu/MmuControls.vue#L137

`<template>` require directive (vue/no-lone-template)
<v-btn
large
block
color="secondary"
:class="btnClass"
class="base-btn wrap-text-btn"
v-on="showTooltip ? on : {}"
:disabled="!canSend || filamentPos !== FILAMENT_POS_UNLOADED"
:loading="loadings.includes('mmu_load')"
v-on="showTooltip ? on : {}"
@click="doLoadingSend('MMU_LOAD', 'mmu_load')">
<v-icon left>{{ mdiDownload }}</v-icon>
{{ loadButtonText }}
Expand Down Expand Up @@ -222,7 +222,7 @@ export default class MmuControls extends Mixins(BaseMixin, MmuMixin) {
}
@Watch('$store.state.gui.view.mmu.largeFilamentStatus')
onFilamentStatusSizeChange(newSize: boolead): void {
onFilamentStatusSizeChange(): void {
this.checkButtonWidth()
}
Expand Down
12 changes: 6 additions & 6 deletions src/components/panels/Mmu/MmuFilamentStatus.vue
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<template>
<svg viewBox="140 20 285 421" preserveAspectRatio="xMidYMid meet" ref="filStatusSvg">
<svg ref="filStatusSvg" viewBox="140 20 285 421" preserveAspectRatio="xMidYMid meet">
<defs>
<g
id="sync-feedback"
Expand Down Expand Up @@ -34,7 +34,7 @@
<rect style="fill: rgb(88, 110, 117)" x="181" y="108" width="639" height="142" />
<path style="fill: rgb(88, 110, 117)" d="m 322 762 h 355 l -118 142 h -118 z" />
</g>
<g transform="matrix(23.2058 0 0 23.2058 329.7195 325.9517)" id="375155">
<g transform="matrix(23.2058 0 0 23.2058 329.7195 325.9517)">
<path
style="
stroke: rgb(0, 0, 0);
Expand Down Expand Up @@ -172,8 +172,8 @@
<transition name="fade">
<g
v-if="isSensorTriggered('filament_tension') || isSensorTriggered('filament_compression')"
style="font-size: 14px"
key="feedback">
style="font-size: 14px"
<text
v-if="isSensorTriggered('filament_tension') && isSensorTriggered('filament_compression')"
x="288"
Expand All @@ -190,7 +190,7 @@
</g>

<transition name="fade">
<use v-if="!syncDrive" xlink:href="#sync-extruder" ref="sync" transform="translate(278, 385) scale(.030)" />
<use v-if="!syncDrive" ref="sync" xlink:href="#sync-extruder" transform="translate(278, 385) scale(.030)" />
</transition>

<use v-if="action == ACTION_CUTTING_FILAMENT" ref="cut" xlink:href="#sissors" class="cut1-effect" />
Expand Down Expand Up @@ -244,7 +244,7 @@ export default class MmuFilamentStatus extends Mixins(BaseMixin, MmuMixin) {
readonly BOWDEN_RANGE = 173 as const
@Watch('$store.state.printer.mmu.bowden_progress')
onBowdenProgress(newProgress: number): void {
onBowdenProgress(): void {
// Percentage movement in the bowden
this.calcFilamentHeight(this.filamentPos)
}
Expand All @@ -256,7 +256,7 @@ export default class MmuFilamentStatus extends Mixins(BaseMixin, MmuMixin) {
}
@Watch('$store.state.printer.mmu.sensors')
onFilamentPosChanged(newSensors: object): void {
onSensorsChanged(): void {
// Update on sensor change
this.calcFilamentHeight(this.filamentPos)
}
Expand Down
2 changes: 1 addition & 1 deletion src/components/panels/Mmu/MmuGateStatus.vue
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<template>
<svg viewBox="0 0 120 54" xml:space="preserve" preserveAspectRatio="xMidYMid meet" ref="mmuGateStatusSvg">
<svg ref="mmuGateStatusSvg" viewBox="0 0 120 54" xml:space="preserve" preserveAspectRatio="xMidYMid meet">
<rect
x="20"
y="18"
Expand Down

0 comments on commit 3236efe

Please sign in to comment.