export const headlessActions = {
  GOTO: 'GOTO',
  VIEWPORT: 'VIEWPORT',
  WAITFORSELECTOR: 'WAITFORSELECTOR',
  NAVIGATION: 'NAVIGATION',
  NAVIGATION_PROMISE: 'NAVIGATION_PROMISE',
  FRAME_SET: 'FRAME_SET',
  SCREENSHOT: 'SCREENSHOT',
};

export const eventsToRecord = {
  CLICK: 'click',
  DBLCLICK: 'dblclick',
  // CHANGE: 'change',
  INPUT: 'input',
  KEYDOWN: 'keydown',
  // KEYUP: 'keyup',
  // SELECT: 'select',
  // SUBMIT: 'submit',
  // NAVIGATION: 'navigation',
  // LOAD: 'load',
  BEFORE_UNLOAD: 'beforeunload',
  EXTRACT_DATA: 'extract-data',
};

export const headlessTypes = {
  PUPPETEER: 'puppeteer',
  // PLAYWRIGHT: 'playwright',
};

export const inputKeyCodes = [
  16,
  32,
  48,
  49,
  50,
  51,
  52,
  53,
  54,
  55,
  56,
  57, // Space, 0-9
  65,
  66,
  67,
  68,
  69,
  70,
  71,
  72,
  73,
  74,
  75,
  76,
  77,
  78,
  79,
  80,
  81,
  82,
  83,
  84,
  85,
  86,
  87,
  88,
  89,
  90, // A-Z
  96,
  97,
  98,
  99,
  100,
  101,
  102,
  103,
  104,
  105, // Numpad 0-9
  186,
  187,
  188,
  189,
  190,
  191,
  192,
  219,
  220,
  221,
  222, // Symbol keys (;=,-./` etc.)
  17, // Ctrl
  91, // Command on MacOS, or Windows key on Windows
  93, // Right Command on MacOS, or Right Windows key on Windows
];
