Skip to content

Commit

Permalink
update files to new rules
Browse files Browse the repository at this point in the history
  • Loading branch information
Kr0nox committed Dec 1, 2024
1 parent dc3b295 commit f98b7af
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 11 deletions.
9 changes: 1 addition & 8 deletions report-viewer/eslint.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -42,12 +42,5 @@ export default [
rules: {
'@typescript-eslint/no-unused-expressions': 'off'
}
},
{
files: ['**/*.html'],
rules: {
'vue/comment-directive': 'off',
},
},

}
]
6 changes: 6 additions & 0 deletions report-viewer/src/components/ClusterGraph.vue
Original file line number Diff line number Diff line change
Expand Up @@ -238,8 +238,11 @@ const graphData = computed(() => {
y: calculateYPosition(index)
})),
edges: edges.value,
/* eslint-disable-next-line @typescript-eslint/no-explicit-any */ // needs to be any since it is defined like that in the library
edgeLineBorderColor: (ctx: any) => getEdgeColor(ctx.raw.source, ctx.raw.target),
/* eslint-disable-next-line @typescript-eslint/no-explicit-any */ // needs to be any since it is defined like that in the library
edgeLineBorderWidth: (ctx: any) => getEdgeWidth(ctx.raw.source, ctx.raw.target),
/* eslint-disable-next-line @typescript-eslint/no-explicit-any */ // needs to be any since it is defined like that in the library
edgeLineBorderDash: (ctx: any) => getEdgeDashStyle(ctx.raw.source, ctx.raw.target)
}
]
Expand Down Expand Up @@ -268,6 +271,7 @@ const graphOptions = computed(() => {
right: xPadding.value
}
},
/* eslint-disable-next-line @typescript-eslint/no-explicit-any */ // needs to be any since it is defined like that in the library
onHover: (event: any, elements: any) => {
if (!event) {
hoveredEdge.value = null
Expand Down Expand Up @@ -315,9 +319,11 @@ const graphOptions = computed(() => {
weight: 'bold' as const,
size: 12
},
/* eslint-disable-next-line @typescript-eslint/no-explicit-any */ // needs to be any since it is defined like that in the library
formatter: (value: any, ctx: any) => {
return labels.value[ctx.dataIndex]
},
/* eslint-disable-next-line @typescript-eslint/no-explicit-any */ // needs to be any since it is defined like that in the library
align: (ctx: any) => degreeAroundCircle(ctx.dataIndex),
offset: 8,
color: graphColors.ticksAndFont.value
Expand Down
7 changes: 5 additions & 2 deletions report-viewer/src/components/ComparisonsTable.vue
Original file line number Diff line number Diff line change
Expand Up @@ -188,15 +188,17 @@ const props = defineProps({
},
clusters: {
type: Array<Cluster>,
required: false
required: false,
default: undefined
},
header: {
type: String,
default: 'Top Comparisons:'
},
highlightedRowIds: {
type: Object as PropType<{ firstId: string; secondId: string }>,
required: false
required: false,
default: undefined
}
})

Expand Down Expand Up @@ -369,6 +371,7 @@ function isHighlightedRow(item: ComparisonListElement) {
)
}

// eslint-disable-next-line @typescript-eslint/no-explicit-any
const dynamicScroller: Ref<any | null> = ref(null)

watch(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,8 @@ const options = computed(() => {
autoSkipPadding: 10,
color: graphColors.ticksAndFont.value,
// ensures that in log mode ticks are placed evenly apart
callback: function (value: unknown) {
/* eslint-disable @typescript-eslint/no-explicit-any */ // needs to be any since it is defined like that in chart.js
callback: function (value: any) {
if (graphOptions.value.xScale === 'logarithmic' && (value + '').match(/1(0)*[^1-9.]/)) {
return value
}
Expand All @@ -111,6 +112,7 @@ const options = computed(() => {
y: {
ticks: {
color: graphColors.ticksAndFont.value,
/* eslint-disable @typescript-eslint/no-explicit-any */ // needs to be any since it is defined like that in chart.js
callback: function (reversedValue: any) {
const value = distributionData.value.length - reversedValue - 1
if (graphOptions.value.bucketCount <= 10) {
Expand Down
1 change: 1 addition & 0 deletions report-viewer/src/components/fileDisplaying/CodeLine.vue
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
<!-- eslint-disable vue/no-v-html -->
<template>
<div
ref="lineRef"
Expand Down

0 comments on commit f98b7af

Please sign in to comment.