export function checkClipboardTypes(type, item) {
  const isDOMStringList = t => !t.indexOf && !!t.contains;
  return isDOMStringList(type) ? type.contains(item) : type.indexOf(item) > -1;
}
export function isPastedFile(rawEvent) {
  const {
    clipboardData
  } = rawEvent;
  if (!clipboardData) {
    return false;
  }
  return checkClipboardTypes(clipboardData.types, 'Files');
}