Skip to content

Commit 3ca8789

Browse files
committed
lint
1 parent 7e548d1 commit 3ca8789

6 files changed

Lines changed: 21 additions & 28 deletions

File tree

packages/devextreme/js/__internal/scheduler/appointments_new/appointment/base_appointment.ts

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,14 +18,13 @@ import { DateFormatType, getDateTextFromTargetAppointment } from '../utils/get_d
1818

1919
export interface BaseAppointmentViewProperties
2020
// eslint-disable-next-line @typescript-eslint/no-explicit-any
21-
extends DOMComponentProperties<BaseAppointmentView<any>>
22-
{
21+
extends DOMComponentProperties<BaseAppointmentView<any>> {
2322
appointmentData: SafeAppointment;
2423
targetedAppointmentData: TargetedAppointment;
2524
appointmentTemplate: TemplateBase;
2625

2726
onAppointmentRendered: (e: {
28-
element: DxElement,
27+
element: DxElement;
2928
appointmentData: SafeAppointment;
3029
targetedAppointmentData: TargetedAppointment;
3130
}) => void;

packages/devextreme/js/__internal/scheduler/appointments_new/appointment/grid_appointment.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ export interface GridAppointmentViewProperties extends BaseAppointmentViewProper
1616
};
1717
modifiers: {
1818
empty: boolean;
19-
}
19+
};
2020
}
2121

2222
export class GridAppointmentView extends BaseAppointmentView<GridAppointmentViewProperties> {

packages/devextreme/js/__internal/scheduler/appointments_new/appointment_collector.ts

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -14,16 +14,15 @@ import type { TargetedAppointment } from '@ts/scheduler/types';
1414
import { APPOINTMENT_COLLECTOR_CLASSES } from './const';
1515

1616
export interface AppointmentCollectorProperties
17-
extends DOMComponentProperties<AppointmentCollector>
18-
{
17+
extends DOMComponentProperties<AppointmentCollector> {
1918
appointmentsCount: number;
2019
isCompact: boolean;
2120
geometry: {
2221
height: number;
2322
width: number;
2423
top: number;
2524
left: number;
26-
},
25+
};
2726
targetedAppointmentData: TargetedAppointment;
2827
appointmentCollectorTemplate: TemplateBase;
2928
}
@@ -70,9 +69,8 @@ export class AppointmentCollector
7069
}
7170

7271
private applyElementAria(): void {
73-
const localizeDate = (date: Date): string => (
74-
`${dateLocalization.format(date, 'monthAndDay')}, ${dateLocalization.format(date, 'year')}`
75-
);
72+
const localizeDate = (date: Date): string =>
73+
`${dateLocalization.format(date, 'monthAndDay')}, ${dateLocalization.format(date, 'year')}`;
7674

7775
const { targetedAppointmentData } = this.option();
7876

packages/devextreme/js/__internal/scheduler/appointments_new/appointments.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ const mockAppointmentDataSource = (): AppointmentDataSource => ({
2727
} as unknown as AppointmentDataSource);
2828

2929
const getProperties = (options: {
30-
resources?: ResourceConfig[]
30+
resources?: ResourceConfig[];
3131
} = {}): AppointmentsProperties => ({
3232
getAppointmentDataSource: mockAppointmentDataSource,
3333
getResourceManager: () => getResourceManagerMock(options.resources ?? []),

packages/devextreme/js/__internal/scheduler/appointments_new/utils/get_view_model_diff.ts

Lines changed: 11 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -59,11 +59,11 @@ const isAppointmentDataChanged = (
5959
};
6060

6161
function getArraysDiff(options: {
62-
a: Item[],
63-
b: Item[],
64-
match: (x: Item, y: Item) => boolean,
65-
equal: (x: Item, y: Item) => boolean,
66-
canResize: (x: Item, y: Item) => boolean,
62+
a: Item[];
63+
b: Item[];
64+
match: (x: Item, y: Item) => boolean;
65+
equal: (x: Item, y: Item) => boolean;
66+
canResize: (x: Item, y: Item) => boolean;
6767
}): DiffItem[] {
6868
const {
6969
a, b, match, equal, canResize,
@@ -129,17 +129,14 @@ export const getViewModelDiff = (
129129
newViewModel: Item[],
130130
appointmentDataSource: AppointmentDataSource,
131131
): DiffItem[] => {
132-
const match = (a: Item, b: Item): boolean => (
133-
a.itemData === b.itemData && !isAppointmentDataChanged(b.itemData, appointmentDataSource)
134-
);
132+
const match = (a: Item, b: Item): boolean =>
133+
a.itemData === b.itemData && !isAppointmentDataChanged(b.itemData, appointmentDataSource);
135134

136-
const equal = (a: Item, b: Item): boolean => (
137-
equalByValue(getObjectToCompare(a, true), getObjectToCompare(b, true))
138-
);
135+
const equal = (a: Item, b: Item): boolean =>
136+
equalByValue(getObjectToCompare(a, true), getObjectToCompare(b, true));
139137

140-
const canResize = (a: Item, b: Item): boolean => (
141-
equalByValue(getObjectToCompare(a, false), getObjectToCompare(b, false))
142-
);
138+
const canResize = (a: Item, b: Item): boolean =>
139+
equalByValue(getObjectToCompare(a, false), getObjectToCompare(b, false));
143140

144141
const result = getArraysDiff({
145142
a: oldViewModel,

packages/devextreme/js/__internal/scheduler/appointments_new/utils/type_helpers.ts

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,5 @@ export const isCollectorViewModel = (appointmentViewModel: AppointmentViewModelP
1212
appointmentViewModel is AppointmentCollectorViewModel => 'isCompact' in appointmentViewModel;
1313

1414
export const isGridAppointmentViewModel = (appointmentViewModel: AppointmentViewModelPlain):
15-
appointmentViewModel is AppointmentItemViewModel => (
16-
!isAgendaAppointmentViewModel(appointmentViewModel) && !isCollectorViewModel(appointmentViewModel)
17-
);
15+
appointmentViewModel is AppointmentItemViewModel =>
16+
!isAgendaAppointmentViewModel(appointmentViewModel) && !isCollectorViewModel(appointmentViewModel);

0 commit comments

Comments
 (0)