Skip to content

The open alternative to Salesforce, designed for AI.

222 B
Raw Blame
import { expect, waitFor } from 'storybook/test';

export const focusWithoutScrolling = async (element: HTMLElement) => {
  element.focus({ preventScroll: true });

  await waitFor(() => expect(element).toHaveFocus());
};