import { Pipe, PipeTransform } from '@angular/core';

@Pipe({
  name: 'appShowScanButton',
})
export class ShowScanButtonPipe implements PipeTransform {
  transform(isIpad: boolean, searchQuery: string, errorMessage: string): boolean {
    if (!isIpad) {
      return false;
    }

    if (!!searchQuery || !!errorMessage) {
      return false;
    }

    return true;
  }
}
