Skip to content

Commit 20c0fcd

Browse files
authored
CardView: hotfix react + nextjs ssr critical issue [BETA BRANCH PR] (#29862)
1 parent 8969e7f commit 20c0fcd

File tree

4 files changed

+15
-5
lines changed

4 files changed

+15
-5
lines changed

packages/devextreme/js/__internal/grids/new/grid_core/keyboard_navigation/kbn_focus_trap.tsx

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -77,8 +77,10 @@ export class KbnFocusTrapEnabled extends Component<KbnFocusTrapBaseProps> {
7777
);
7878
}
7979

80+
// TODO: KeyboardEvent
8081
@eventHandler
81-
private onKeyDown(event: KeyboardEvent): void {
82+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
83+
private onKeyDown(event: any): void {
8284
if (event.key === 'Enter' && !event.shiftKey) {
8385
this.focusLastChild();
8486
eventUtils.markHandled(event);
@@ -87,8 +89,10 @@ export class KbnFocusTrapEnabled extends Component<KbnFocusTrapBaseProps> {
8789
this.props.onKeyDown?.(event);
8890
}
8991

92+
// TODO: KeyboardEvent
9093
@eventHandler
91-
private onContentKeyDown(event: KeyboardEvent): void {
94+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
95+
private onContentKeyDown(event: any): void {
9296
if (event.key === 'Escape') {
9397
this.getActualRef().current?.focus();
9498
eventUtils.markHandled(event);

packages/devextreme/js/__internal/grids/new/grid_core/keyboard_navigation/kbn_navigation_container.tsx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,8 +90,10 @@ export class KbnNavigationContainerEnabled extends Component<KbnNavigationContai
9090
);
9191
}
9292

93+
// TODO: KeyboardEvent
9394
@eventHandler
94-
private onKeyDown(event: KeyboardEvent): void {
95+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
96+
private onKeyDown(event: any): void {
9597
const { navigationStrategy, onKeyDown } = this.props;
9698
const elementRef = this.getActualRef();
9799

packages/devextreme/js/__internal/grids/new/grid_core/keyboard_navigation/with_key_down_handler.tsx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,8 +40,10 @@ export const withKeyDownHandler = <
4040
);
4141
}
4242

43+
// TODO: KeyboardEvent
4344
@eventHandler
44-
private onKeyDown(event: KeyboardEvent): void {
45+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
46+
private onKeyDown(event: any): void {
4547
const { keyDownConfig, onKeyDown, caughtEventPreventDefault } = this.props;
4648
const ref = this.getActualRef();
4749
const fullKeyName = getKeyWithModifications(event);

packages/devextreme/js/__internal/grids/new/grid_core/keyboard_navigation/with_navigation_item.tsx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,8 +76,10 @@ export const withKbnNavigationItem = <
7676
);
7777
}
7878

79+
// TODO: KeyboardEvent
7980
@eventHandler
80-
private onKeyDown(event: KeyboardEvent): void {
81+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
82+
private onKeyDown(event: any): void {
8183
const {
8284
navigationStrategy, onKeyDown, onFocusMoved,
8385
} = this.props;

0 commit comments

Comments
 (0)