Files
lens/packages/business-features/keyboard-shortcuts/src/keyboard-shortcut-scope.tsx
T
2023-05-15 11:56:30 -04:00

14 lines
390 B
TypeScript

import type { StrictReactNode } from "@k8slens/utilities";
import React from "react";
export interface KeyboardShortcutScopeProps {
id: string;
children: StrictReactNode;
}
export const KeyboardShortcutScope = ({ id, children }: KeyboardShortcutScopeProps) => (
<div data-keyboard-shortcut-scope={id} data-keyboard-shortcut-scope-test={id} tabIndex={-1}>
{children}
</div>
);