import { UniDriver } from '@wix/wix-ui-test-utils/unidriver';
import {
  ButtonUniDriver,
  IconButtonUniDriver,
  TooltipUniDriver,
} from '@wix/design-system/dist/testkit/unidriver';

export function ResponsiveButtonUniDriver(
  base: UniDriver,
  body: UniDriver,
  {
    dataHook,
  }: {
    dataHook: string;
  },
) {
  return {
    getTooltip: () =>
      TooltipUniDriver(base.$(`[data-hook="${dataHook}-tooltip"]`), body),
    getButton: () => ButtonUniDriver(base.$(`[data-hook="${dataHook}"]`), body),
    getIconButton: () =>
      IconButtonUniDriver(base.$(`[data-hook="${dataHook}"]`), body),
  };
}
