Skip to content

Commit 71a417c

Browse files
committed
chore: Update sonar config
1 parent f0e9712 commit 71a417c

File tree

5 files changed

+12
-11
lines changed

5 files changed

+12
-11
lines changed

sonar-project.properties

+3
Original file line numberDiff line numberDiff line change
@@ -4,3 +4,6 @@ sonar.exclusions=docs/**
44
sonar.javascript.lcov.reportPaths=coverage/lcov.info
55
sonar.coverage.exclusions=tests/**
66
sonar.test.exclusions=tests/**
7+
sonar.issue.ignore.block=a1
8+
sonar.issue.ignore.block.a1.beginBlockRegexp=@SONAR_START@
9+
sonar.issue.ignore.block.a1.endBlockRegexp=@SONAR_STOP@

src/VueDatePicker/components/Calendar.vue

+3-3
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@
105105
import { MergedProps } from '@/utils/props';
106106
107107
import type { PropType, UnwrapRef } from 'vue';
108-
import type { DynamicClass, ICalendarDate, ICalendarDay, IMarker, Transition } from '@/interfaces';
108+
import type { DynamicClass, ICalendarDate, ICalendarDay, IMarker } from '@/interfaces';
109109
110110
const emit = defineEmits([
111111
'select-date',
@@ -170,8 +170,8 @@
170170
if (props.transitions) {
171171
const newDate = resetDateTime(setDateMonthOrYear(getDate(), props.month, props.year));
172172
transitionName.value = isDateAfter(resetDateTime(setDateMonthOrYear(getDate(), month, year)), newDate)
173-
? (props.transitions as Transition)[getTransitionName(true)]
174-
: (props.transitions as Transition)[getTransitionName(false)];
173+
? props.transitions[getTransitionName(true)]
174+
: props.transitions[getTransitionName(false)];
175175
showCalendar.value = false;
176176
nextTick(() => {
177177
showCalendar.value = true;

src/VueDatePicker/components/MonthYearPicker/MonthYearPicker.vue

+3-3
Original file line numberDiff line numberDiff line change
@@ -275,9 +275,9 @@
275275
: [];
276276
});
277277
278-
// START-NOSCAN
278+
// @SONAR_START@
279279
const reverseList = (list: IDefaultSelect[]) => list.reverse();
280-
// END-NOSCAN
280+
// @SONAR_STOP@
281281
282282
const getGroupedList = (items: IDefaultSelect[], reverse = false): IDefaultSelect[][] => {
283283
const list = [];
@@ -314,7 +314,7 @@
314314
315315
const showRightIcon = computed((): boolean => {
316316
if (props.multiCalendars) {
317-
return !props.multiCalendarsSolo ? props.instance === (props.multiCalendars as number) - 1 : true;
317+
return !props.multiCalendarsSolo ? props.instance === props.multiCalendars - 1 : true;
318318
}
319319
return true;
320320
});

src/VueDatePicker/components/MonthYearPicker/RegularPicker.vue

+1-2
Original file line numberDiff line numberDiff line change
@@ -50,8 +50,7 @@
5050
import { useTransitions } from '@/components/composables';
5151
5252
import type { PropType } from 'vue';
53-
import type { IDefaultSelect, Transition } from '@/interfaces';
54-
import { AriaLabels } from '@/interfaces';
53+
import type { IDefaultSelect, Transition, AriaLabels } from '@/interfaces';
5554
5655
const emit = defineEmits(['update:model-value', 'toggle', 'set-ref']);
5756
const props = defineProps({

src/VueDatePicker/components/composables/calendar.ts

+2-3
Original file line numberDiff line numberDiff line change
@@ -32,14 +32,14 @@ import type {
3232
} from '@/interfaces';
3333
import type { UnwrapRef } from 'vue';
3434

35-
// BEGIN-NOSCAN
35+
// @SONAR_START@
3636
export const useCalendar = (
3737
props: ExtendedProps,
3838
emit: VueEmit,
3939
updateFlow: () => void,
4040
triggerCalendarTransition: (inst?: number) => void,
4141
) => {
42-
// END-NOSCAN
42+
// @SONAR_STOP@
4343

4444
const {
4545
getDate,
@@ -63,7 +63,6 @@ export const useCalendar = (
6363
set: (value: InternalModuleValue): void => {
6464
if (!props.readonly && !props.disabled) {
6565
emit('update:internal-model-value', value);
66-
// props.internalModelValue = value;
6766
}
6867
},
6968
});

0 commit comments

Comments
 (0)