From c93d8fb61279b3ad470641d5ca72507ed58571dc Mon Sep 17 00:00:00 2001 From: Michael Hetherington Date: Tue, 21 Jun 2022 07:33:35 -0400 Subject: [PATCH 01/49] Added many new products, added support for raildriver, added rotary control event, wip for trackball --- package.json | 1 + packages/core/src/api.ts | 17 +- packages/core/src/products.ts | 429 +++++++++++++++++- packages/core/src/xkeys.ts | 149 +++++- .../node/examples/basic-log-all-events.js | 4 + 5 files changed, 572 insertions(+), 28 deletions(-) diff --git a/package.json b/package.json index a46062c..96b0d46 100644 --- a/package.json +++ b/package.json @@ -9,6 +9,7 @@ "scripts": { "prepare": "husky install", "build": "lerna run build --stream", + "build:core": "yarn build --scope=@xkeys-lib/core", "lint:raw": "lerna exec --stream -- eslint --ext .ts --ext .js --ext .tsx --ext .jsx --ignore-pattern dist", "lint": "yarn lint:raw .", "lintfix": "yarn lint --fix", diff --git a/packages/core/src/api.ts b/packages/core/src/api.ts index 28782d8..a4fc78e 100644 --- a/packages/core/src/api.ts +++ b/packages/core/src/api.ts @@ -14,10 +14,12 @@ export interface AnalogStates { joystick: JoystickValue[] /** 0 to 255 */ tbar: number[] + /** 0 to 255 */ + rotary: number[] // todo: Implement these: // slider?: number[] // x with feedback - // trackball?: {x: number, y: number}[] + trackball: TrackballValue[] // trackpad?: {x: number, y: number, z: number}[] // z: proximity/force } export interface JoystickValue { @@ -31,6 +33,13 @@ export interface JoystickValue { */ z: number } +export interface TrackballValue { + /** X (delta horisontal movement). 2 byte */ + x: number + /** Y (delta vertical movement), positive value is "up". 2 byte */ + y: number + +} export interface JoystickValueEmit extends JoystickValue { /** Joystick delta Z, a delta value that behaves properly when Z rolls over 255 to 0 */ deltaZ: number @@ -60,6 +69,8 @@ export interface XKeysEvents { shuttle: (index: number, value: number, eventMetadata: EventMetadata) => void joystick: (index: number, value: JoystickValueEmit, eventMetadata: EventMetadata) => void tbar: (index: number, value: number, eventMetadata: EventMetadata) => void + trackball: (index: number, value: TrackballValue, eventMetadata: EventMetadata) => void + rotary: (index: number, value: number, eventMetadata: EventMetadata) => void disconnected: () => void reconnected: () => void @@ -111,12 +122,16 @@ export interface XKeysInfo { hasPS: boolean /** The number of joysticks available on the device */ hasJoystick: number + /** The number of trackballs available on the device */ + hasTrackball: number /** The number of jog wheels available on the device */ hasJog: number /** The number of shuttles available on the device */ hasShuttle: number /** The number of T-bars available on the device */ hasTbar: number + /** The number of rotary knobs available on the device */ + hasRotary: number /** If the device has an LCD display */ hasLCD: boolean /** If the device has GPIO support */ diff --git a/packages/core/src/products.ts b/packages/core/src/products.ts index 83720fa..79c5ec5 100644 --- a/packages/core/src/products.ts +++ b/packages/core/src/products.ts @@ -44,6 +44,30 @@ export interface Product { joyYbyte: number joyZbyte: number }[] + /** If the X-keys panel has a Trackball. */ + hasTrackball?: { + trackXbyte_L: number // the index of the low byte of 2 byte X position + trackXbyte_H: number // the index of the high byte of 2 byte X position + trackYbyte_L: number // the index of the low byte of 2 byte Y position + trackYbyte_H: number // the index of the high byte of 2 byte Y position + }[] + /** If the X-keys panel has a Trackpad. */ + hasTrackpad?: { + padXbyte_L: number // the index of the low byte of 2 byte X position + padXbyte_H: number // the index of the high byte of 2 byte X position + padYbyte_L: number // the index of the low byte of 2 byte Y position + padYbyte_H: number // the index of the high byte of 2 byte Y position + pinchByte: number // the index of the pinch byte + scrollByte: number // the index of the scroll byte + + }[] + /** If the X-keys device has an Analog to Digital converter. Often used to measure voltage*/ + hasADC?: { + adcByte_L: number // the index of the low byte of 2 byte ACD Value + adcByte_H: number // the index of the high byte of 2 byte ACD Value + }[] + /** If the X-keys panel has any Rotary Knobs. */ + hasRotary?: { rotaryByte: number }[] // the index of any rotary control bytes (twist knob) /** used to determine what keyIndex to back light mapping should be used. */ backLightType: BackLightType @@ -52,10 +76,7 @@ export interface Product { hasJog?: { jogByte: number }[] hasShuttle?: { shuttleByte: number }[] - hasTbar?: { - tbarByte: number - tbarByteRaw: number - }[] + hasTbar?: { tbarByte: number}[] hasLCD?: boolean hasGPIO?: boolean hasSerialData?: boolean @@ -72,6 +93,8 @@ export enum BackLightType { LINEAR = 4, /** Backlight LED type 5 is the RGB 24 buttons */ REMAP_24 = 5, + /** Backlight LED type 6 is the RGB 2 banks most XKB modules */ + RGBx2 = 6, } export const PRODUCTS: { [name: string]: Product } = { @@ -389,7 +412,7 @@ export const PRODUCTS: { [name: string]: Product } = { hasTbar: [ { tbarByte: 28, //this gives a clean 0-255 value - tbarByteRaw: 29, // should only use cal t-bar on byte index 28 + //tbarByteRaw: 29, // should only use cal t-bar on byte index 28 }, ], @@ -544,7 +567,7 @@ export const PRODUCTS: { [name: string]: Product } = { ], bBytes: 2, bBits: 8, // see documentation - colCount: 1, // difficult to describe with Rows and Columns, so just a list may be the bests + colCount: 1, // difficult to describe with Rows and Columns, so just a list may be the best rowCount: 14, // 14 inputs hasPS: false, // none backLightType: BackLightType.NONE, // no back light LEDs but has 2 digital outputs on the HD 15 wire. See documentation @@ -559,7 +582,7 @@ export const PRODUCTS: { [name: string]: Product } = { ], bBytes: 2, bBits: 8, // see documentation - colCount: 1, // difficult to describe with Rows and Columns, so just a list may be the bests + colCount: 1, // difficult to describe with Rows and Columns, so just a list may be the best rowCount: 14, // 14 inputs possible, check config hasPS: false, // none backLightType: BackLightType.NONE, // no back light LEDs but has 2 or more digital outputs on the HD 15 wire. See documentation @@ -714,7 +737,7 @@ export const PRODUCTS: { [name: string]: Product } = { hasTbar: [ { tbarByte: 17, - tbarByteRaw: 15, // should only use cal t-bar on byte index 17 + // tbarByteRaw: 15, // should only use cal t-bar on byte index 17 }, ], backLightType: BackLightType.LEGACY, @@ -722,4 +745,394 @@ export const PRODUCTS: { [name: string]: Product } = { timestampByte: 31, // ms time since device boot 4 byte BE disableButtons: [6, 7, 8, 14, 15, 16, 22, 23, 24, 30, 31, 32, 73, 74, 75, 73], // These bits are messy, better to ignore them }), + + XBK4X6: literal({ //new product, expected release Q4 2022 + name: 'X-blox XBK-4x6 Module', // 24 key module with RGB backLight LEDs + hidDevices: [ + [1365, 0], + [1366, 0], + [1327, 0], + [1328, 0], + [1329, 0], + [1330, 0], + [1331, 0], + ], + bBytes: 4, // number of button bytes + bBits: 6, // number button bits per byte + colCount: 4, // number of physical columns + rowCount: 6, // number of physical rows + hasPS: false, + backLightType: BackLightType.RGBx2, //RGB 2 Bank, Standard Index + backLight2offset: 0, // RGBs have no offset. + timestampByte: 31, // index of first of 4 bytes, ms time since device boot, 4 byte BE + }), + XBK3X6: literal({ //new product, expected release Q4 2022 + name: 'X-blox XBK-3x6 Module', // 18 key module with RGB backLight LEDs + hidDevices: [ + [1378, 0], + [1379, 0], + [1380, 0], + [1381, 0], + [1382, 0], + [1383, 0], + [1384, 0], + ], + bBytes: 3, // number of button bytes + bBits: 6, // number button bits per byte + colCount: 3, // number of physical columns + rowCount: 6, // number of physical rows + hasPS: false, + backLightType: BackLightType.RGBx2, //RGB 2 Bank,Standard Index + backLight2offset: 0, // RGBs have no offset. + timestampByte: 31, // index of first of 4 bytes, ms time since device boot, 4 byte BE + }), + XBA4X3JOG: literal({//new product, expected release Q4 2022 + name: 'X-blox XBA-4x3 Jog-Shuttle Module', // 12 key module with Jog Shuttle & RGB backLight LEDs + hidDevices: [ + [1388, 0], + [1389, 0], + [1390, 0], + [1391, 0], + [1392, 0], + [1393, 0], + [1394, 0], + ], + bBytes: 4, // number of button bytes + bBits: 3, // number button bits per byte + colCount: 4, // number of physical columns + rowCount: 3, // number of physical rows + hasPS: false, + hasJog: [{ jogByte: 12 }], + hasShuttle: [{ shuttleByte: 13 }], + backLightType: BackLightType.RGBx2, //RGB 2 Bank, Standard Index + backLight2offset: 0, // RGBs have no offset. + timestampByte: 31, // index of first of 4 bytes, ms time since device boot, 4 byte BE + }), + XBA3X6TBAR: literal({//new product, expected release Q4 2022 + name: 'X-blox XBA-3x6 T-bar Module', // 14 key module with T-bar, RGB backLight LEDs + hidDevices: [ + [1396, 0], + [1397, 0], + [1398, 0], + [1399, 0], + [1400, 0], + [1401, 0], + [1402, 0], + ], + bBytes: 3, // number of button bytes + bBits: 6, // number button bits per byte + colCount: 3, // number of physical columns + rowCount: 6, // number of physical rows + hasPS: false, + hasTbar: [ + { + tbarByte: 9, + //tbarByteRaw: 7, // should only use cal t-bar on byte index 9 + }, + ], + backLightType: BackLightType.RGBx2, //RGB 2 Bank,Standard Index + backLight2offset: 0, // RGBs have no offset. + timestampByte: 31, // index of first of 4 bytes, ms time since device boot, 4 byte BE + }), + XBA4X3TRACKBALL: literal({//new product, expected release Q4 2022 + name: 'X-blox XBA-4x3 Trackball Module', // 12 key module with Trackball & RGB backLight LEDs + hidDevices: [ + [1488, 0], + [1489, 0], + [1490, 0], + [1491, 0], + [1492, 0], + [1493, 0], + [1494, 0], + ], + bBytes: 4, // number of button bytes + bBits: 3, // number button bits per byte + colCount: 4, // number of physical columns + rowCount: 3, // number of physical rows + hasPS: false, + hasTrackball: [ + { + trackXbyte_L: 6, //Delta X motion, Low byte of 2 byte date, X ball motion = 256*DELTA_X_H + DELTA_X_L. + trackXbyte_H: 7, //Delta X motion, High byte of 2 byte date, X ball motion = 256*DELTA_X_H + DELTA_X_L. + trackYbyte_L: 8, //Delta Y motion, Low byte of 2 byte date, Y ball motion = 256*DELTA_Y_H + DELTA_Y_L. + trackYbyte_H: 9, //Delta Y motion, High byte of 2 byte date, Y ball motion = 256*DELTA_Y_H + DELTA_Y_L. + }, + ], + backLightType: BackLightType.RGBx2, //RGB 2 Bank, Standard Index + backLight2offset: 0, // RGBs have no offset. + timestampByte: 31, // index of first of 4 bytes, ms time since device boot, 4 byte BE + }), + XBK_QWERTY: literal({ //new product, expected release Q1 2023 + name: 'X-blox XBK-QWERTY Module', // Typing Keyboard module with up to 32 columns & RGB backLight LEDs, basic module has only 16 columns, extra satilite boards add extra columns, see documentation + hidDevices: [ + [1343, 0], + [1344, 0], + [1345, 0], + [1346, 0], + [1347, 0], + [1348, 0], + [1349, 0], + ], + bBytes: 32, // number of button bytes + bBits: 6, // number button bits per byte + layouts: [ + ['Keys', 0, 1, 1, 6, 8], // left side satellite keys, optional + ['QWERTY-85', 0, 1, 9, 6, 24], // Main QWERTY section, required + ['Keys', 1, 1, 25, 6, 32],// right side satellite keys, optional + + ], // control name, control index, startRow, startCol, endRow, endCol + colCount: 32, // number of physical columns, not all rows have all columns because of the offset of the keys and large keys such space bar and shifts. + rowCount: 6, // number of physical rows + hasPS: false, + + backLightType: BackLightType.RGBx2, //RGB 1 Bank, Standard Index + backLight2offset: 0, // RGBs have no offset. + timestampByte: 36, // index of first of 4 bytes, ms time since device boot, 4 byte BE + }), + XBK16X6: literal({ //new product, expected release Q1 2023 + name: 'X-blox XBK-16x6 Module', // 96 key module with RGB backLight LEDs + hidDevices: [ + [1496, 0], + [1497, 0], + [1498, 0], + [1499, 0], + [1500, 0], + [1501, 0], + [1502, 0], + ], + bBytes: 16, // number of button bytes + bBits: 6, // number button bits per byte + colCount: 16, // number of physical columns + rowCount: 6, // number of physical rows + hasPS: false, + backLightType: BackLightType.RGBx2, //RGB 2 Bank, Standard Index + backLight2offset: 0, // RGBs have no offset. + timestampByte: 31, // index of first of 4 bytes, ms time since device boot, 4 byte BE + }), + XCDRCSERVO: literal({ //new product, expected release Q1 2023 + name: 'XC-RC Servo', // Connections for 16 RC Servo Motors and four 3.5 mm ports, contacts for a stereo Plug + hidDevices: [[1364, 0]], + bBytes: 1, + bBits: 8, // see documentation + colCount: 4, // 2 ports per side of unit , + rowCount: 2, // each port has 2 switches + hasPS: true, // may be inside box and require extra wires if needed. + backLightType: BackLightType.NONE, // no back light LEDs + backLight2offset: 0, + btnLocation: [ + // columns are port number and row 1 is the first switch on the port and 2 is second + [0, 0], + [2, 1], + [1, 1], + [2, 2], + [1, 2], + [2, 3], + [1, 3], + [2, 4], + [1, 4], + ] + }), + XCRELAY: literal({ //prototype product, + name: 'XC-Relay', // Connections 2 DPDT Relays and four 3.5 mm input ports, contacts for a stereo Plug + hidDevices: [[1363, 0]], + bBytes: 1, + bBits: 8, // see documentation + colCount: 4, // 2 ports per side of unit , + rowCount: 2, // each port has 2 switches + hasPS: true, // may be inside box and require extra wires if needed. + backLightType: BackLightType.NONE, // no back light LEDs + backLight2offset: 0, + btnLocation: [ + // columns are port number and row 1 is the first switch on the port and 2 is second + [0, 0], + [2, 1], + [1, 1], + [2, 2], + [1, 2], + [2, 3], + [1, 3], + [2, 4], + [1, 4], + ] + }), + XCMOTORDRIVER: literal({ //prototype product, + name: 'XC-Motor Driver', // Connections for 4 DC Motors or 2 Stepper Motors, 4 Analog to Digital voltages, and 5 GPIOs + hidDevices: [[1364, 0]], + bBytes: 1, + bBits: 8, // see documentation + colCount: 4, // 2 ports per side of unit , + rowCount: 2, // each port has 2 switches + hasPS: true, // may be inside box and require extra wires if needed. + hasGPIO:true, + hasADC: [ + { + adcByte_L: 6, //ADC Value, Low byte of 2 byte date, + adcByte_H: 7, //ADC Value, High byte of 2 byte date, + }, + { + adcByte_L: 8, //ADC Value, Low byte of 2 byte date, + adcByte_H: 9, //ADC Value, High byte of 2 byte date, + }, + { + adcByte_L: 10, //ADC Value, Low byte of 2 byte date, + adcByte_H: 11, //ADC Value, High byte of 2 byte date, + }, + { + adcByte_L: 12, //ADC Value, Low byte of 2 byte date, + adcByte_H: 13, //ADC Value, High byte of 2 byte date, + }, + ], + backLightType: BackLightType.NONE, // no back light LEDs + backLight2offset: 0, + btnLocation: [ + // columns are port number and row 1 is the first switch on the port and 2 is second + [0, 0], + [2, 1], + [1, 1], + [2, 2], + [1, 2], + [2, 3], + [1, 3], + [2, 4], + [1, 4], + ] + }), + XBA4X3TRACKPAD: literal({ //prototype product, + name: 'X-blox XBA-Track Pad Module', // 12 key module with Trackball & RGB backLight LEDs + hidDevices: [ + [1422, 0], + [1423, 0], + [1424, 0], + [1425, 0], + [1426, 0], + [1427, 0], + [1428, 0], + ], + bBytes: 4, // number of button bytes + bBits: 3, // number button bits per byte + colCount: 4, // number of physical columns + rowCount: 3, // number of physical rows + hasPS: false, + hasTrackpad: [ + { + padXbyte_L: 6, //Delta X motion, Low byte of 2 byte date, X ball motion = 256*DELTA_X_H + DELTA_X_L. + padXbyte_H: 7, //Delta X motion, High byte of 2 byte date, X ball motion = 256*DELTA_X_H + DELTA_X_L. + padYbyte_L: 8, //Delta Y motion, Low byte of 2 byte date, Y ball motion = 256*DELTA_Y_H + DELTA_Y_L. + padYbyte_H: 9, //Delta Y motion, High byte of 2 byte date, Y ball motion = 256*DELTA_Y_H + DELTA_Y_L. + pinchByte: 10, // the index of the pinch byte + scrollByte: 11,// the index of the scroll byte + }, + ], + backLightType: BackLightType.RGBx2, //RGB 2 Bank, Standard Index + backLight2offset: 0, // RGBs have no offset. + timestampByte: 31, // index of first of 4 bytes, ms time since device boot, 4 byte BE + }), + + XK433REMOTE: literal({ //prototype product, + name: 'XK-433RF Remote', // 8 RF remote buttons and four 3.5 mm ports, contacts for a stereo Plug + hidDevices: [ + [1505, 0], + [1506, 0], + [1507, 0], + [1508, 0], + [1509, 0], + [1510, 0], + ], + bBytes: 2, // byte 1 is RF buttons + bBits: 8, // see documentation + layouts: [ + ['Remote', 0, 1, 1, 2, 4], + ['SwitchPorts', 0, 1, 1, 2, 2], + ['SwitchPorts', 1, 1, 3, 2, 4], + + ], // control name, control index, startRow, startCol, endRow, endCol + colCount: 4, // 2 ports per side of unit , numbered 1-2 and 3-4 + rowCount: 2, // each port has 2 switches + hasPS: true, // maybe inside box, extra wired required + backLightType: BackLightType.NONE, // no back light LEDs + backLight2offset: 0, + timestampByte: 31, // ms time since device boot 4 byte BE + btnLocation: [ + [0, 0], + [2, 1], + [1, 1], + [2, 2], + [1, 2], + [2, 3], + [1, 3], + [2, 4], + [1, 4], + [2, 5], + [1, 5], + [2, 6], + [1, 6], + ], // column indicates port #, mono plugs map to row 1, stereo plugs to row 1 and 2 + // due to the stereo jack some buttons may always be down when a single pole (mono) plug is plugged in. + }), + RailDriver: literal({ //In production: www.raildriver.com + name: 'RailDriver Cab Controller', // The RailDriver is a special product that does not conform the the standard X-keys format. It is described here assuming the buttons are remapped and 2 header bytes are added to the data message. + hidDevices: [ + [210, 0], + [210, -1], + + ], + bBytes: 6, // this asssumes the button bytes will be remapped. + bBits: 8, // see documentation + layouts: [ + ['Cab Buttons', 0, 1, 1, 2, 4], + ['Horn', 0, 1, 3, 2, 3], + ['Reverser', 0, 1, 4, 4, 4], + ['Throttle', 0, 1, 5, 4, 5], + ['Auto Brake', 0, 1, 6, 4, 6], + ['Ind Brake', 0, 1, 7, 4, 7], + ['Bail Off', 0, 1, 8, 4, 8], + ['Wiper', 0, 1, 9, 4, 9], + ['Lights', 0, 3, 9, 4, 9], + + + + ], // control name, control index, startRow, startCol, endRow, endCol + colCount: 6, // not valid here because the cab layout, see documentation + rowCount: 8, // + hasPS: false, // + hasTbar: [ // the raildriver has 5 lever controls, we will call them T-bars for this mapping + { + tbarByte: 8, //Reverser Lever + + }, + { + tbarByte: 9, //Throttle Lever + + }, + { + tbarByte: 10, //Auto Brake Lever + + }, + { + tbarByte: 11, //Independent Brake + + }, + //{ + // tbarByte: 12, //Bail Off, moving Ind Brake to Right, + + //}, + ], + hasRotary: [ // the raildriver has 2 rotary controls, + { + rotaryByte: 12, //Upper twist knob + + }, + { + rotaryByte: 13, //Lower twist knob + + }, + + ], + backLightType: BackLightType.NONE, // no back light LEDs + backLight2offset: 0, + //timestamp: none, RailDriver has no time stamp + + }), + + } diff --git a/packages/core/src/xkeys.ts b/packages/core/src/xkeys.ts index 1d159bc..b796a84 100644 --- a/packages/core/src/xkeys.ts +++ b/packages/core/src/xkeys.ts @@ -29,17 +29,21 @@ export class XKeys extends EventEmitter { joystick: [], shuttle: [], tbar: [], + rotary: [], + trackball: [], } private receivedVersionResolve?: () => void private receivedGenerateDataResolve?: () => void private _initialized = false - private _unidId = 0 // is set after init() private _firmwareVersion = 0 // is set after init() + private _firmwareVersionIsSet = false + private _unidId = 0 // is set after init() + private _unitIdIsSet = false private _disconnected = false - /** Vendor id for the X-keys panels */ + /** Vendor id for the X-keys panels */ static get vendorId(): number { return XKEYS_VENDOR_ID } @@ -73,6 +77,47 @@ export class XKeys extends EventEmitter { const found = findProdct() this.device.on('data', (data: Buffer) => { + if(deviceInfo.productId===210) { + // Note: THe RailDriver is an older device, which doesn't follow the rest of xkeys data structure. + // To make it easy for us, we'll just remap the data to work for us. + + var rdData = new Uint8Array(32); + rdData[0]=0 // this sets the Unit ID to 0 always + if (!this._firmwareVersionIsSet) { + rdData[1]=214 // Fake initial message to set _firmwareVersion + } else if (!this._unitIdIsSet) { + rdData[1]=3 // Fake initial message to set _unitId + } else { + rdData[1]=0 // no pg switch, byte is always 0 + } + rdData[2]=data.readUInt8(7) // remap button bits + rdData[3]=data.readUInt8(8) // remap button bits + rdData[4]=data.readUInt8(9) // remap button bits + rdData[5]=data.readUInt8(10) // remap button bits + rdData[6]=data.readUInt8(11) // remap button bits + rdData[7]=data.readUInt8(12) // remap button bits + // Add Bailoff to button byte, + if (data.readUInt8(4)>=160){ + // set bit 5 to 1 + + rdData[7]= rdData[7]|16 + + } + rdData[8]=data.readUInt8(0) // remap analog bytes + rdData[9]=data.readUInt8(1) // remap analog bytes + rdData[10]=data.readUInt8(2) // remap analog bytes + rdData[11]=data.readUInt8(3) // remap analog bytes + rdData[12]=data.readUInt8(5) // remap analog bytes + rdData[13]=data.readUInt8(6) // remap analog bytes + + + + for (let i = 0; i < 15; i++) { + data[i]=rdData[i] + } + } + + //------------------------ if (data.readUInt8(1) === 214) { // this is a special report that does not correlate to the regular data report, it is created by sending getVersion() @@ -80,12 +125,17 @@ export class XKeys extends EventEmitter { // data.readUInt8(0) the unit ID is the first byte, index 0, used to tell between 2 identical X-keys, UID is set by user // data.readUInt16LE(11) // PID is also in this report as a double check. - this._firmwareVersion = firmVersion // Firmware version + this._firmwareVersion = firmVersion || 1 // Firmware version + this._firmwareVersionIsSet = true this.receivedVersionResolve?.() return // quit here because this data would be interperted as button data and give bad results. } + // TODO: Add other special reports here. + // A standard data report will be sent when something physical happens on the keys, button press, or lever moved for example + // other special reports may be sent in responce to a request or some data input on the device. + // if (data.readUInt8(1) > 3) return // Protect against all special data reports now and into the future. const newButtonStates: ButtonStates = new Map() @@ -94,6 +144,8 @@ export class XKeys extends EventEmitter { joystick: [], shuttle: [], tbar: [], + rotary: [], + trackball: [], } // UID, unit id, is used to uniquely identify a certain panel, from factory it's set to 0, it can be set by a user with this.setUID() @@ -112,6 +164,7 @@ export class XKeys extends EventEmitter { // Note, the generateData is used to get the full state this._unidId = UID + this._unitIdIsSet = true this.receivedGenerateDataResolve?.() } @@ -156,10 +209,26 @@ export class XKeys extends EventEmitter { z: z, // joystick z is a continuous value that rolls over to 0 after 255 } }) + this.product.hasTrackball?.forEach((trackball, index) => { + let x = 256*data.readUInt8(trackball.trackXbyte_H)+data.readUInt8(trackball.trackXbyte_L) // Trackball X //Delta X motion, X ball motion = 256*DELTA_X_H + DELTA_X_L. + let y = 256*data.readUInt8(trackball.trackYbyte_H)+data.readUInt8(trackball.trackYbyte_L) // Trackball Y + + + + newAnalogStates.trackball[index] = { + x:x, + y:y, + + } + }) this.product.hasTbar?.forEach((tBar, index) => { const d = data.readUInt8(tBar.tbarByte) // T-bar (calibrated) newAnalogStates.tbar[index] = d }) + this.product.hasRotary?.forEach((rotary, index) => { + const d = data.readUInt8(rotary.rotaryByte) + newAnalogStates.rotary[index] = d + }) // Disabled/nonexisting buttons: important as some "buttons" in the jog & shuttle devices are used for shuttle events in hardware. if (this.product.disableButtons) { @@ -207,7 +276,7 @@ export class XKeys extends EventEmitter { const oldValue = this._analogStates.joystick[index] if (!oldValue) { const emitValue: JoystickValueEmit = { - ...newValue, + ...newValue, // Calculate deltaZ, since that is not trivial to do: deltaZ: 0, } @@ -225,6 +294,15 @@ export class XKeys extends EventEmitter { const oldValue = this._analogStates.tbar[index] if (newValue !== oldValue) this.emit('tbar', index, newValue, eventMetadata) }) + newAnalogStates.rotary.forEach((newValue, index) => { + const oldValue = this._analogStates.rotary[index] + if (newValue !== oldValue) this.emit('rotary', index, newValue, eventMetadata) + }) + newAnalogStates.trackball.forEach((newValue, index) => { + const oldValue = this._analogStates.trackball[index] + if (oldValue.x !== newValue.x || oldValue.y !== newValue.y) this.emit('trackball', index, newValue, eventMetadata) + }) + // Store the new states: this._buttonStates = newButtonStates @@ -251,6 +329,7 @@ export class XKeys extends EventEmitter { /** Initialize the device. This ensures that the essential information from the device about its state has been received. */ public async init(): Promise { + console.log('initialization start..........') const pReceivedVersion = new Promise((resolve) => { this.receivedVersionResolve = resolve }) @@ -265,6 +344,7 @@ export class XKeys extends EventEmitter { await pReceivedGenerateData this._initialized = true + console.log('initialization done!!!!!!!!') } /** Closes the device. Subsequent commands will raise errors. */ public async close(): Promise { @@ -310,9 +390,11 @@ export class XKeys extends EventEmitter { emitsTimestamp: this.product.timestampByte !== undefined, hasPS: this.product.hasPS, hasJoystick: this.product.hasJoystick?.length || 0, + hasTrackball: this.product.hasTrackball?.length || 0, hasJog: this.product.hasJog?.length || 0, hasShuttle: this.product.hasShuttle?.length || 0, hasTbar: this.product.hasTbar?.length || 0, + hasRotary: this.product.hasRotary?.length || 0, hasLCD: this.product.hasLCD || false, hasGPIO: this.product.hasGPIO || false, hasSerialData: this.product.hasSerialData || false, @@ -329,7 +411,7 @@ export class XKeys extends EventEmitter { /** * Sets the indicator-LED on the device, usually a red and green LED at the top of many X-keys - * @param ledIndex the LED to set (1 = green, 2 = red) + * @param ledIndex the LED to set (1 = green (top), 2 = red (bottom)) * @param on boolean: on or off * @param flashing boolean: flashing or not (if on) * @returns undefined @@ -346,6 +428,7 @@ export class XKeys extends EventEmitter { * Sets the backlight of a button * @param keyIndex The button of which to set the backlight color * @param color r,g,b or string (RGB, RRGGBB, #RRGGBB) + * @param bankIndex number: Which LED bank (top or bottom) to set the color of. (Only applicable to RGB-based panels. ) * @param flashing boolean: flashing or not (if on) * @returns undefined */ @@ -353,7 +436,8 @@ export class XKeys extends EventEmitter { keyIndex: number, /** RGB, RRGGBB, #RRGGBB */ color: Color | string | boolean | null, - flashing?: boolean + flashing?: boolean, + bankIndex?: number ): void { this.ensureInitialized() if (keyIndex === 0) return // PS-button has no backlight @@ -363,14 +447,21 @@ export class XKeys extends EventEmitter { const location = this._findBtnLocation(keyIndex) - if (this.product.backLightType === BackLightType.REMAP_24) { + if (this.product.backLightType === BackLightType.REMAP_24) { // obsloete, Consier removing MHH const ledIndex = (location.col - 1) * 8 + location.row - 1 // backlight LED type 5 is the RGB 24 buttons this._write([0, 181, ledIndex, color.g, color.r, color.b, flashing ? 1 : 0]) // Byte order is actually G,R,B,F) - return - } - - if (this.product.backLightType === BackLightType.STICK_BUTTONS) { + } else if (this.product.backLightType === BackLightType.RGBx2) {// backlight LED type 6, 2 banks of full RGB LEDs + const ledIndex = keyIndex - 1 // 0 based linear numbering sort of... + + if (bankIndex !== undefined) { + this._write([0, 165, ledIndex, bankIndex, color.r, color.g, color.b, flashing ? 1 : 0]) + } else { + // There are 2 leds in under a key, 0 for top and 1 for bottom. + this._write([0, 165, ledIndex, 0, color.r, color.g, color.b, flashing ? 1 : 0]) + this._write([0, 165, ledIndex, 1, color.r, color.g, color.b, flashing ? 1 : 0]) + } + } else if (this.product.backLightType === BackLightType.STICK_BUTTONS) { // The stick buttons, that requires special mapping. let ledIndex = location.col - 1 // 0 based linear numbering sort of... @@ -403,15 +494,22 @@ export class XKeys extends EventEmitter { /** * Sets the backlight of all buttons * @param color r,g,b or string (RGB, RRGGBB, #RRGGBB) + * @param bankIndex number: Which LED bank (top or bottom) to control. */ - public setAllBacklights(color: Color | string | boolean | null): void { + public setAllBacklights(color: Color | string | boolean | null,bankIndex?: number): void { this.ensureInitialized() color = this._interpretColor(color, this.product.backLightType) - if (this.product.backLightType === BackLightType.REMAP_24) { - // backlight LED type 5 is the RGB 24 buttons + if (this.product.backLightType === BackLightType.RGBx2) { + // backlight LED type 6 is the RGB devices - this._write([0, 182, color.g, color.r, color.b]) // Byte order is actually G,R,B + if (bankIndex !== undefined) { + this._write([0, 166, bankIndex, color.r, color.g, color.b]) + } else { + // There are 2 leds in under a key, 0 for top and 1 for bottom. + this._write([0, 166, 0, color.r, color.g, color.b] ) + this._write([0, 166, 1, color.r, color.g, color.b] ) + } } else { // Blue LEDs: this._write([0, 182, 0, color.b]) @@ -470,7 +568,7 @@ export class XKeys extends EventEmitter { /** * Sets the UID (unit Id) value in the X-keys hardware * Note: EEPROM command, don't call this function too often, or you'll kill the EEPROM! - * (An EEPROM only support a few thousands of write operations.) + * (An EEPROM only supports a few thousands of write operations.) * @param unitId Unit id ("UID"). Allowed values: 0-255. 0 is factory default * @returns undefined */ @@ -527,7 +625,7 @@ export class XKeys extends EventEmitter { /** * Writes a Buffer of data bytes to the X-keys device - * Used to send custom messages to X-keys for testing and development + * Used to send custom messages to X-keys for testing and development, see documentation for valid messages * @param buffer The buffer written to the device * @returns undefined */ @@ -643,11 +741,17 @@ export class XKeys extends EventEmitter { if (color) return { r: 0, g: 0, b: 255 } else return { r: 0, g: 0, b: 0 } } else if (typeof color === 'string') { - // Handle a few "worded" colors: + // Note: Handle a few "worded" colors, these colors are tweaked to look nice with the X-keys LEDs: if (color === 'red') color = 'ff0000' else if (color === 'blue') color = '0000ff' - else if (color === 'purple') color = 'ff00ff' + else if (color === 'violet') color = '600096' + else if (color === 'aquamarine') color = '00ff45' + else if (color === 'turquoise') color = '00ff81' + else if (color === 'purple') color = '960096' else if (color === 'redblue') color = 'ff00ff' + else if (color === 'pink') color = 'ff0828' + else if (color === 'orange') color = 'ff1400' + else if (color === 'yellow') color = 'ff8000' else if (color === 'green') color = '00ff00' else if (color === 'black') color = '000000' else if (color === 'white') color = 'ffffff' @@ -669,6 +773,13 @@ export class XKeys extends EventEmitter { g: parseInt(m[2] + m[2], 16), b: parseInt(m[3] + m[3], 16), } + } else if ((m = color.match(/([0-9]{1,3}),([0-9]{1,3}),([0-9]{1,3})/))) { + // '255,127,0' // comma separated integers + return { + r: parseInt(m[1], 10), + g: parseInt(m[2], 10), + b: parseInt(m[3], 10), + } } else { // Fallback: this.emit('error', new Error(`Unable to interpret color "${color}"`)) diff --git a/packages/node/examples/basic-log-all-events.js b/packages/node/examples/basic-log-all-events.js index f7c38db..aad0f2e 100644 --- a/packages/node/examples/basic-log-all-events.js +++ b/packages/node/examples/basic-log-all-events.js @@ -56,6 +56,10 @@ watcher.on('connected', (xkeysPanel) => { xkeysPanel.on('tbar', (index, position, metadata) => { console.log(`T-bar ${index} position has changed`, position, metadata) }) + // Listen to rotary changes: + xkeysPanel.on('rotary', (index, position, metadata) => { + console.log(`Rotary ${index} position has changed`, position, metadata) + }) }) // To stop watching, call From 8447d1de688200a6ada9e331ff2a7709cf6a20aa Mon Sep 17 00:00:00 2001 From: Johan Nyman Date: Tue, 21 Jun 2022 14:17:03 +0200 Subject: [PATCH 02/49] chore: format & minor fixes --- packages/core/src/api.ts | 4 +- packages/core/src/products.ts | 107 +++++++++++++++++----------------- packages/core/src/xkeys.ts | 30 +++++----- 3 files changed, 69 insertions(+), 72 deletions(-) diff --git a/packages/core/src/api.ts b/packages/core/src/api.ts index a4fc78e..d04d7b7 100644 --- a/packages/core/src/api.ts +++ b/packages/core/src/api.ts @@ -19,7 +19,7 @@ export interface AnalogStates { // todo: Implement these: // slider?: number[] // x with feedback - trackball: TrackballValue[] + trackball: TrackballValue[] // trackpad?: {x: number, y: number, z: number}[] // z: proximity/force } export interface JoystickValue { @@ -38,7 +38,7 @@ export interface TrackballValue { x: number /** Y (delta vertical movement), positive value is "up". 2 byte */ y: number - + } export interface JoystickValueEmit extends JoystickValue { /** Joystick delta Z, a delta value that behaves properly when Z rolls over 255 to 0 */ diff --git a/packages/core/src/products.ts b/packages/core/src/products.ts index 79c5ec5..d4d518e 100644 --- a/packages/core/src/products.ts +++ b/packages/core/src/products.ts @@ -46,25 +46,25 @@ export interface Product { }[] /** If the X-keys panel has a Trackball. */ hasTrackball?: { - trackXbyte_L: number // the index of the low byte of 2 byte X position - trackXbyte_H: number // the index of the high byte of 2 byte X position + trackXbyte_L: number // the index of the low byte of 2 byte X position + trackXbyte_H: number // the index of the high byte of 2 byte X position trackYbyte_L: number // the index of the low byte of 2 byte Y position trackYbyte_H: number // the index of the high byte of 2 byte Y position }[] /** If the X-keys panel has a Trackpad. */ hasTrackpad?: { - padXbyte_L: number // the index of the low byte of 2 byte X position - padXbyte_H: number // the index of the high byte of 2 byte X position + padXbyte_L: number // the index of the low byte of 2 byte X position + padXbyte_H: number // the index of the high byte of 2 byte X position padYbyte_L: number // the index of the low byte of 2 byte Y position padYbyte_H: number // the index of the high byte of 2 byte Y position - pinchByte: number // the index of the pinch byte + pinchByte: number // the index of the pinch byte scrollByte: number // the index of the scroll byte - + }[] /** If the X-keys device has an Analog to Digital converter. Often used to measure voltage*/ - hasADC?: { - adcByte_L: number // the index of the low byte of 2 byte ACD Value - adcByte_H: number // the index of the high byte of 2 byte ACD Value + hasADC?: { + adcByte_L: number // the index of the low byte of 2 byte ACD Value + adcByte_H: number // the index of the high byte of 2 byte ACD Value }[] /** If the X-keys panel has any Rotary Knobs. */ hasRotary?: { rotaryByte: number }[] // the index of any rotary control bytes (twist knob) @@ -412,7 +412,6 @@ export const PRODUCTS: { [name: string]: Product } = { hasTbar: [ { tbarByte: 28, //this gives a clean 0-255 value - //tbarByteRaw: 29, // should only use cal t-bar on byte index 28 }, ], @@ -737,7 +736,6 @@ export const PRODUCTS: { [name: string]: Product } = { hasTbar: [ { tbarByte: 17, - // tbarByteRaw: 15, // should only use cal t-bar on byte index 17 }, ], backLightType: BackLightType.LEGACY, @@ -745,9 +743,9 @@ export const PRODUCTS: { [name: string]: Product } = { timestampByte: 31, // ms time since device boot 4 byte BE disableButtons: [6, 7, 8, 14, 15, 16, 22, 23, 24, 30, 31, 32, 73, 74, 75, 73], // These bits are messy, better to ignore them }), - + XBK4X6: literal({ //new product, expected release Q4 2022 - name: 'X-blox XBK-4x6 Module', // 24 key module with RGB backLight LEDs + name: 'X-blox XBK-4x6 Module', // 24 key module with RGB backLight LEDs hidDevices: [ [1365, 0], [1366, 0], @@ -767,7 +765,7 @@ export const PRODUCTS: { [name: string]: Product } = { timestampByte: 31, // index of first of 4 bytes, ms time since device boot, 4 byte BE }), XBK3X6: literal({ //new product, expected release Q4 2022 - name: 'X-blox XBK-3x6 Module', // 18 key module with RGB backLight LEDs + name: 'X-blox XBK-3x6 Module', // 18 key module with RGB backLight LEDs hidDevices: [ [1378, 0], [1379, 0], @@ -787,7 +785,7 @@ export const PRODUCTS: { [name: string]: Product } = { timestampByte: 31, // index of first of 4 bytes, ms time since device boot, 4 byte BE }), XBA4X3JOG: literal({//new product, expected release Q4 2022 - name: 'X-blox XBA-4x3 Jog-Shuttle Module', // 12 key module with Jog Shuttle & RGB backLight LEDs + name: 'X-blox XBA-4x3 Jog-Shuttle Module', // 12 key module with Jog Shuttle & RGB backLight LEDs hidDevices: [ [1388, 0], [1389, 0], @@ -809,7 +807,7 @@ export const PRODUCTS: { [name: string]: Product } = { timestampByte: 31, // index of first of 4 bytes, ms time since device boot, 4 byte BE }), XBA3X6TBAR: literal({//new product, expected release Q4 2022 - name: 'X-blox XBA-3x6 T-bar Module', // 14 key module with T-bar, RGB backLight LEDs + name: 'X-blox XBA-3x6 T-bar Module', // 14 key module with T-bar, RGB backLight LEDs hidDevices: [ [1396, 0], [1397, 0], @@ -827,7 +825,6 @@ export const PRODUCTS: { [name: string]: Product } = { hasTbar: [ { tbarByte: 9, - //tbarByteRaw: 7, // should only use cal t-bar on byte index 9 }, ], backLightType: BackLightType.RGBx2, //RGB 2 Bank,Standard Index @@ -835,7 +832,7 @@ export const PRODUCTS: { [name: string]: Product } = { timestampByte: 31, // index of first of 4 bytes, ms time since device boot, 4 byte BE }), XBA4X3TRACKBALL: literal({//new product, expected release Q4 2022 - name: 'X-blox XBA-4x3 Trackball Module', // 12 key module with Trackball & RGB backLight LEDs + name: 'X-blox XBA-4x3 Trackball Module', // 12 key module with Trackball & RGB backLight LEDs hidDevices: [ [1488, 0], [1489, 0], @@ -879,18 +876,18 @@ export const PRODUCTS: { [name: string]: Product } = { ['Keys', 0, 1, 1, 6, 8], // left side satellite keys, optional ['QWERTY-85', 0, 1, 9, 6, 24], // Main QWERTY section, required ['Keys', 1, 1, 25, 6, 32],// right side satellite keys, optional - + ], // control name, control index, startRow, startCol, endRow, endCol - colCount: 32, // number of physical columns, not all rows have all columns because of the offset of the keys and large keys such space bar and shifts. + colCount: 32, // number of physical columns, not all rows have all columns because of the offset of the keys and large keys such space bar and shifts. rowCount: 6, // number of physical rows hasPS: false, - + backLightType: BackLightType.RGBx2, //RGB 1 Bank, Standard Index backLight2offset: 0, // RGBs have no offset. timestampByte: 36, // index of first of 4 bytes, ms time since device boot, 4 byte BE }), XBK16X6: literal({ //new product, expected release Q1 2023 - name: 'X-blox XBK-16x6 Module', // 96 key module with RGB backLight LEDs + name: 'X-blox XBK-16x6 Module', // 96 key module with RGB backLight LEDs hidDevices: [ [1496, 0], [1497, 0], @@ -916,7 +913,7 @@ export const PRODUCTS: { [name: string]: Product } = { bBits: 8, // see documentation colCount: 4, // 2 ports per side of unit , rowCount: 2, // each port has 2 switches - hasPS: true, // may be inside box and require extra wires if needed. + hasPS: true, // may be inside box and require extra wires if needed. backLightType: BackLightType.NONE, // no back light LEDs backLight2offset: 0, btnLocation: [ @@ -939,7 +936,7 @@ export const PRODUCTS: { [name: string]: Product } = { bBits: 8, // see documentation colCount: 4, // 2 ports per side of unit , rowCount: 2, // each port has 2 switches - hasPS: true, // may be inside box and require extra wires if needed. + hasPS: true, // may be inside box and require extra wires if needed. backLightType: BackLightType.NONE, // no back light LEDs backLight2offset: 0, btnLocation: [ @@ -962,24 +959,24 @@ export const PRODUCTS: { [name: string]: Product } = { bBits: 8, // see documentation colCount: 4, // 2 ports per side of unit , rowCount: 2, // each port has 2 switches - hasPS: true, // may be inside box and require extra wires if needed. + hasPS: true, // may be inside box and require extra wires if needed. hasGPIO:true, hasADC: [ { - adcByte_L: 6, //ADC Value, Low byte of 2 byte date, - adcByte_H: 7, //ADC Value, High byte of 2 byte date, + adcByte_L: 6, //ADC Value, Low byte of 2 byte date, + adcByte_H: 7, //ADC Value, High byte of 2 byte date, }, { - adcByte_L: 8, //ADC Value, Low byte of 2 byte date, - adcByte_H: 9, //ADC Value, High byte of 2 byte date, + adcByte_L: 8, //ADC Value, Low byte of 2 byte date, + adcByte_H: 9, //ADC Value, High byte of 2 byte date, }, { - adcByte_L: 10, //ADC Value, Low byte of 2 byte date, - adcByte_H: 11, //ADC Value, High byte of 2 byte date, + adcByte_L: 10, //ADC Value, Low byte of 2 byte date, + adcByte_H: 11, //ADC Value, High byte of 2 byte date, }, { - adcByte_L: 12, //ADC Value, Low byte of 2 byte date, - adcByte_H: 13, //ADC Value, High byte of 2 byte date, + adcByte_L: 12, //ADC Value, Low byte of 2 byte date, + adcByte_H: 13, //ADC Value, High byte of 2 byte date, }, ], backLightType: BackLightType.NONE, // no back light LEDs @@ -998,7 +995,7 @@ export const PRODUCTS: { [name: string]: Product } = { ] }), XBA4X3TRACKPAD: literal({ //prototype product, - name: 'X-blox XBA-Track Pad Module', // 12 key module with Trackball & RGB backLight LEDs + name: 'X-blox XBA-Track Pad Module', // 12 key module with Trackball & RGB backLight LEDs hidDevices: [ [1422, 0], [1423, 0], @@ -1019,7 +1016,7 @@ export const PRODUCTS: { [name: string]: Product } = { padXbyte_H: 7, //Delta X motion, High byte of 2 byte date, X ball motion = 256*DELTA_X_H + DELTA_X_L. padYbyte_L: 8, //Delta Y motion, Low byte of 2 byte date, Y ball motion = 256*DELTA_Y_H + DELTA_Y_L. padYbyte_H: 9, //Delta Y motion, High byte of 2 byte date, Y ball motion = 256*DELTA_Y_H + DELTA_Y_L. - pinchByte: 10, // the index of the pinch byte + pinchByte: 10, // the index of the pinch byte scrollByte: 11,// the index of the scroll byte }, ], @@ -1027,7 +1024,7 @@ export const PRODUCTS: { [name: string]: Product } = { backLight2offset: 0, // RGBs have no offset. timestampByte: 31, // index of first of 4 bytes, ms time since device boot, 4 byte BE }), - + XK433REMOTE: literal({ //prototype product, name: 'XK-433RF Remote', // 8 RF remote buttons and four 3.5 mm ports, contacts for a stereo Plug hidDevices: [ @@ -1044,7 +1041,7 @@ export const PRODUCTS: { [name: string]: Product } = { ['Remote', 0, 1, 1, 2, 4], ['SwitchPorts', 0, 1, 1, 2, 2], ['SwitchPorts', 1, 1, 3, 2, 4], - + ], // control name, control index, startRow, startCol, endRow, endCol colCount: 4, // 2 ports per side of unit , numbered 1-2 and 3-4 rowCount: 2, // each port has 2 switches @@ -1070,13 +1067,13 @@ export const PRODUCTS: { [name: string]: Product } = { // due to the stereo jack some buttons may always be down when a single pole (mono) plug is plugged in. }), RailDriver: literal({ //In production: www.raildriver.com - name: 'RailDriver Cab Controller', // The RailDriver is a special product that does not conform the the standard X-keys format. It is described here assuming the buttons are remapped and 2 header bytes are added to the data message. + name: 'RailDriver Cab Controller', // The RailDriver is a special product that does not conform the the standard X-keys format. It is described here assuming the buttons are remapped and 2 header bytes are added to the data message. hidDevices: [ [210, 0], [210, -1], ], - bBytes: 6, // this asssumes the button bytes will be remapped. + bBytes: 6, // this asssumes the button bytes will be remapped. bBits: 8, // see documentation layouts: [ ['Cab Buttons', 0, 1, 1, 2, 4], @@ -1089,50 +1086,50 @@ export const PRODUCTS: { [name: string]: Product } = { ['Wiper', 0, 1, 9, 4, 9], ['Lights', 0, 3, 9, 4, 9], - - + + ], // control name, control index, startRow, startCol, endRow, endCol colCount: 6, // not valid here because the cab layout, see documentation - rowCount: 8, // - hasPS: false, // + rowCount: 8, // + hasPS: false, // hasTbar: [ // the raildriver has 5 lever controls, we will call them T-bars for this mapping { tbarByte: 8, //Reverser Lever - + }, { tbarByte: 9, //Throttle Lever - + }, { tbarByte: 10, //Auto Brake Lever - + }, { tbarByte: 11, //Independent Brake - + }, //{ - // tbarByte: 12, //Bail Off, moving Ind Brake to Right, - + // tbarByte: 12, //Bail Off, moving Ind Brake to Right, + //}, ], - hasRotary: [ // the raildriver has 2 rotary controls, + hasRotary: [ // the raildriver has 2 rotary controls, { rotaryByte: 12, //Upper twist knob - + }, { rotaryByte: 13, //Lower twist knob - + }, - + ], backLightType: BackLightType.NONE, // no back light LEDs backLight2offset: 0, //timestamp: none, RailDriver has no time stamp - + }), - + } diff --git a/packages/core/src/xkeys.ts b/packages/core/src/xkeys.ts index b796a84..0993655 100644 --- a/packages/core/src/xkeys.ts +++ b/packages/core/src/xkeys.ts @@ -43,7 +43,7 @@ export class XKeys extends EventEmitter { private _unitIdIsSet = false private _disconnected = false - /** Vendor id for the X-keys panels */ + /** Vendor id for the X-keys panels */ static get vendorId(): number { return XKEYS_VENDOR_ID } @@ -96,10 +96,10 @@ export class XKeys extends EventEmitter { rdData[5]=data.readUInt8(10) // remap button bits rdData[6]=data.readUInt8(11) // remap button bits rdData[7]=data.readUInt8(12) // remap button bits - // Add Bailoff to button byte, + // Add Bailoff to button byte, if (data.readUInt8(4)>=160){ - // set bit 5 to 1 - + // set bit 5 to 1 + rdData[7]= rdData[7]|16 } @@ -109,7 +109,7 @@ export class XKeys extends EventEmitter { rdData[11]=data.readUInt8(3) // remap analog bytes rdData[12]=data.readUInt8(5) // remap analog bytes rdData[13]=data.readUInt8(6) // remap analog bytes - + for (let i = 0; i < 15; i++) { @@ -132,10 +132,10 @@ export class XKeys extends EventEmitter { return // quit here because this data would be interperted as button data and give bad results. } - // TODO: Add other special reports here. + // TODO: Add other special reports here. // A standard data report will be sent when something physical happens on the keys, button press, or lever moved for example - // other special reports may be sent in responce to a request or some data input on the device. - // + // other special reports may be sent in responce to a request or some data input on the device. + // if (data.readUInt8(1) > 3) return // Protect against all special data reports now and into the future. const newButtonStates: ButtonStates = new Map() @@ -212,13 +212,13 @@ export class XKeys extends EventEmitter { this.product.hasTrackball?.forEach((trackball, index) => { let x = 256*data.readUInt8(trackball.trackXbyte_H)+data.readUInt8(trackball.trackXbyte_L) // Trackball X //Delta X motion, X ball motion = 256*DELTA_X_H + DELTA_X_L. let y = 256*data.readUInt8(trackball.trackYbyte_H)+data.readUInt8(trackball.trackYbyte_L) // Trackball Y - - + + newAnalogStates.trackball[index] = { x:x, y:y, - + } }) this.product.hasTbar?.forEach((tBar, index) => { @@ -226,7 +226,7 @@ export class XKeys extends EventEmitter { newAnalogStates.tbar[index] = d }) this.product.hasRotary?.forEach((rotary, index) => { - const d = data.readUInt8(rotary.rotaryByte) + const d = data.readUInt8(rotary.rotaryByte) newAnalogStates.rotary[index] = d }) @@ -276,7 +276,7 @@ export class XKeys extends EventEmitter { const oldValue = this._analogStates.joystick[index] if (!oldValue) { const emitValue: JoystickValueEmit = { - ...newValue, + ...newValue, // Calculate deltaZ, since that is not trivial to do: deltaZ: 0, } @@ -453,7 +453,7 @@ export class XKeys extends EventEmitter { this._write([0, 181, ledIndex, color.g, color.r, color.b, flashing ? 1 : 0]) // Byte order is actually G,R,B,F) } else if (this.product.backLightType === BackLightType.RGBx2) {// backlight LED type 6, 2 banks of full RGB LEDs const ledIndex = keyIndex - 1 // 0 based linear numbering sort of... - + if (bankIndex !== undefined) { this._write([0, 165, ledIndex, bankIndex, color.r, color.g, color.b, flashing ? 1 : 0]) } else { @@ -494,7 +494,7 @@ export class XKeys extends EventEmitter { /** * Sets the backlight of all buttons * @param color r,g,b or string (RGB, RRGGBB, #RRGGBB) - * @param bankIndex number: Which LED bank (top or bottom) to control. + * @param bankIndex number: Which LED bank (top or bottom) to control. */ public setAllBacklights(color: Color | string | boolean | null,bankIndex?: number): void { this.ensureInitialized() From 5e2021af49d12a7367d39f638c375210db343714 Mon Sep 17 00:00:00 2001 From: Johan Nyman Date: Tue, 21 Jun 2022 14:17:18 +0200 Subject: [PATCH 03/49] fix: issue with trackball --- packages/core/src/xkeys.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/core/src/xkeys.ts b/packages/core/src/xkeys.ts index 0993655..df697d5 100644 --- a/packages/core/src/xkeys.ts +++ b/packages/core/src/xkeys.ts @@ -299,10 +299,10 @@ export class XKeys extends EventEmitter { if (newValue !== oldValue) this.emit('rotary', index, newValue, eventMetadata) }) newAnalogStates.trackball.forEach((newValue, index) => { - const oldValue = this._analogStates.trackball[index] - if (oldValue.x !== newValue.x || oldValue.y !== newValue.y) this.emit('trackball', index, newValue, eventMetadata) + // We only need to emit the value when not zero, since the trackball motion are relative values. + if (newValue.x !== 0 || newValue.y !== 0) this.emit('trackball', index, newValue, eventMetadata) }) - + // Store the new states: this._buttonStates = newButtonStates From 126d2d3f92291ff6793da394a36a5769d5e431ce Mon Sep 17 00:00:00 2001 From: Johan Nyman Date: Tue, 21 Jun 2022 15:49:13 +0200 Subject: [PATCH 04/49] chore: update code-standard-preset dependency and apply new reformatting --- package.json | 2 +- packages/core/src/api.ts | 1 - packages/core/src/products.ts | 80 +++++----- packages/core/src/xkeys.ts | 71 +++++---- yarn.lock | 271 +++++++++++++++++----------------- 5 files changed, 210 insertions(+), 215 deletions(-) diff --git a/package.json b/package.json index 537492e..0693c57 100644 --- a/package.json +++ b/package.json @@ -25,7 +25,7 @@ "lerna": "lerna" }, "devDependencies": { - "@sofie-automation/code-standard-preset": "~1.0", + "@sofie-automation/code-standard-preset": "~2.0.2", "@types/jest": "^26.0.20", "cross-env": "^7.0.3", "glob": "^7.1.6", diff --git a/packages/core/src/api.ts b/packages/core/src/api.ts index 2fc5eab..ad623b6 100644 --- a/packages/core/src/api.ts +++ b/packages/core/src/api.ts @@ -38,7 +38,6 @@ export interface TrackballValue { x: number /** Y (delta vertical movement), positive value is "up". 2 byte */ y: number - } export interface JoystickValueEmit extends JoystickValue { /** Joystick delta Z, a delta value that behaves properly when Z rolls over 255 to 0 */ diff --git a/packages/core/src/products.ts b/packages/core/src/products.ts index d4d518e..0373a19 100644 --- a/packages/core/src/products.ts +++ b/packages/core/src/products.ts @@ -57,9 +57,8 @@ export interface Product { padXbyte_H: number // the index of the high byte of 2 byte X position padYbyte_L: number // the index of the low byte of 2 byte Y position padYbyte_H: number // the index of the high byte of 2 byte Y position - pinchByte: number // the index of the pinch byte + pinchByte: number // the index of the pinch byte scrollByte: number // the index of the scroll byte - }[] /** If the X-keys device has an Analog to Digital converter. Often used to measure voltage*/ hasADC?: { @@ -76,7 +75,7 @@ export interface Product { hasJog?: { jogByte: number }[] hasShuttle?: { shuttleByte: number }[] - hasTbar?: { tbarByte: number}[] + hasTbar?: { tbarByte: number }[] hasLCD?: boolean hasGPIO?: boolean hasSerialData?: boolean @@ -744,7 +743,8 @@ export const PRODUCTS: { [name: string]: Product } = { disableButtons: [6, 7, 8, 14, 15, 16, 22, 23, 24, 30, 31, 32, 73, 74, 75, 73], // These bits are messy, better to ignore them }), - XBK4X6: literal({ //new product, expected release Q4 2022 + XBK4X6: literal({ + //new product, expected release Q4 2022 name: 'X-blox XBK-4x6 Module', // 24 key module with RGB backLight LEDs hidDevices: [ [1365, 0], @@ -764,7 +764,8 @@ export const PRODUCTS: { [name: string]: Product } = { backLight2offset: 0, // RGBs have no offset. timestampByte: 31, // index of first of 4 bytes, ms time since device boot, 4 byte BE }), - XBK3X6: literal({ //new product, expected release Q4 2022 + XBK3X6: literal({ + //new product, expected release Q4 2022 name: 'X-blox XBK-3x6 Module', // 18 key module with RGB backLight LEDs hidDevices: [ [1378, 0], @@ -784,7 +785,8 @@ export const PRODUCTS: { [name: string]: Product } = { backLight2offset: 0, // RGBs have no offset. timestampByte: 31, // index of first of 4 bytes, ms time since device boot, 4 byte BE }), - XBA4X3JOG: literal({//new product, expected release Q4 2022 + XBA4X3JOG: literal({ + //new product, expected release Q4 2022 name: 'X-blox XBA-4x3 Jog-Shuttle Module', // 12 key module with Jog Shuttle & RGB backLight LEDs hidDevices: [ [1388, 0], @@ -806,7 +808,8 @@ export const PRODUCTS: { [name: string]: Product } = { backLight2offset: 0, // RGBs have no offset. timestampByte: 31, // index of first of 4 bytes, ms time since device boot, 4 byte BE }), - XBA3X6TBAR: literal({//new product, expected release Q4 2022 + XBA3X6TBAR: literal({ + //new product, expected release Q4 2022 name: 'X-blox XBA-3x6 T-bar Module', // 14 key module with T-bar, RGB backLight LEDs hidDevices: [ [1396, 0], @@ -831,7 +834,8 @@ export const PRODUCTS: { [name: string]: Product } = { backLight2offset: 0, // RGBs have no offset. timestampByte: 31, // index of first of 4 bytes, ms time since device boot, 4 byte BE }), - XBA4X3TRACKBALL: literal({//new product, expected release Q4 2022 + XBA4X3TRACKBALL: literal({ + //new product, expected release Q4 2022 name: 'X-blox XBA-4x3 Trackball Module', // 12 key module with Trackball & RGB backLight LEDs hidDevices: [ [1488, 0], @@ -859,7 +863,8 @@ export const PRODUCTS: { [name: string]: Product } = { backLight2offset: 0, // RGBs have no offset. timestampByte: 31, // index of first of 4 bytes, ms time since device boot, 4 byte BE }), - XBK_QWERTY: literal({ //new product, expected release Q1 2023 + XBK_QWERTY: literal({ + //new product, expected release Q1 2023 name: 'X-blox XBK-QWERTY Module', // Typing Keyboard module with up to 32 columns & RGB backLight LEDs, basic module has only 16 columns, extra satilite boards add extra columns, see documentation hidDevices: [ [1343, 0], @@ -875,8 +880,7 @@ export const PRODUCTS: { [name: string]: Product } = { layouts: [ ['Keys', 0, 1, 1, 6, 8], // left side satellite keys, optional ['QWERTY-85', 0, 1, 9, 6, 24], // Main QWERTY section, required - ['Keys', 1, 1, 25, 6, 32],// right side satellite keys, optional - + ['Keys', 1, 1, 25, 6, 32], // right side satellite keys, optional ], // control name, control index, startRow, startCol, endRow, endCol colCount: 32, // number of physical columns, not all rows have all columns because of the offset of the keys and large keys such space bar and shifts. rowCount: 6, // number of physical rows @@ -886,7 +890,8 @@ export const PRODUCTS: { [name: string]: Product } = { backLight2offset: 0, // RGBs have no offset. timestampByte: 36, // index of first of 4 bytes, ms time since device boot, 4 byte BE }), - XBK16X6: literal({ //new product, expected release Q1 2023 + XBK16X6: literal({ + //new product, expected release Q1 2023 name: 'X-blox XBK-16x6 Module', // 96 key module with RGB backLight LEDs hidDevices: [ [1496, 0], @@ -906,7 +911,8 @@ export const PRODUCTS: { [name: string]: Product } = { backLight2offset: 0, // RGBs have no offset. timestampByte: 31, // index of first of 4 bytes, ms time since device boot, 4 byte BE }), - XCDRCSERVO: literal({ //new product, expected release Q1 2023 + XCDRCSERVO: literal({ + //new product, expected release Q1 2023 name: 'XC-RC Servo', // Connections for 16 RC Servo Motors and four 3.5 mm ports, contacts for a stereo Plug hidDevices: [[1364, 0]], bBytes: 1, @@ -927,9 +933,10 @@ export const PRODUCTS: { [name: string]: Product } = { [1, 3], [2, 4], [1, 4], - ] + ], }), - XCRELAY: literal({ //prototype product, + XCRELAY: literal({ + //prototype product, name: 'XC-Relay', // Connections 2 DPDT Relays and four 3.5 mm input ports, contacts for a stereo Plug hidDevices: [[1363, 0]], bBytes: 1, @@ -950,9 +957,10 @@ export const PRODUCTS: { [name: string]: Product } = { [1, 3], [2, 4], [1, 4], - ] + ], }), - XCMOTORDRIVER: literal({ //prototype product, + XCMOTORDRIVER: literal({ + //prototype product, name: 'XC-Motor Driver', // Connections for 4 DC Motors or 2 Stepper Motors, 4 Analog to Digital voltages, and 5 GPIOs hidDevices: [[1364, 0]], bBytes: 1, @@ -960,7 +968,7 @@ export const PRODUCTS: { [name: string]: Product } = { colCount: 4, // 2 ports per side of unit , rowCount: 2, // each port has 2 switches hasPS: true, // may be inside box and require extra wires if needed. - hasGPIO:true, + hasGPIO: true, hasADC: [ { adcByte_L: 6, //ADC Value, Low byte of 2 byte date, @@ -992,9 +1000,10 @@ export const PRODUCTS: { [name: string]: Product } = { [1, 3], [2, 4], [1, 4], - ] + ], }), - XBA4X3TRACKPAD: literal({ //prototype product, + XBA4X3TRACKPAD: literal({ + //prototype product, name: 'X-blox XBA-Track Pad Module', // 12 key module with Trackball & RGB backLight LEDs hidDevices: [ [1422, 0], @@ -1017,7 +1026,7 @@ export const PRODUCTS: { [name: string]: Product } = { padYbyte_L: 8, //Delta Y motion, Low byte of 2 byte date, Y ball motion = 256*DELTA_Y_H + DELTA_Y_L. padYbyte_H: 9, //Delta Y motion, High byte of 2 byte date, Y ball motion = 256*DELTA_Y_H + DELTA_Y_L. pinchByte: 10, // the index of the pinch byte - scrollByte: 11,// the index of the scroll byte + scrollByte: 11, // the index of the scroll byte }, ], backLightType: BackLightType.RGBx2, //RGB 2 Bank, Standard Index @@ -1025,7 +1034,8 @@ export const PRODUCTS: { [name: string]: Product } = { timestampByte: 31, // index of first of 4 bytes, ms time since device boot, 4 byte BE }), - XK433REMOTE: literal({ //prototype product, + XK433REMOTE: literal({ + //prototype product, name: 'XK-433RF Remote', // 8 RF remote buttons and four 3.5 mm ports, contacts for a stereo Plug hidDevices: [ [1505, 0], @@ -1041,7 +1051,6 @@ export const PRODUCTS: { [name: string]: Product } = { ['Remote', 0, 1, 1, 2, 4], ['SwitchPorts', 0, 1, 1, 2, 2], ['SwitchPorts', 1, 1, 3, 2, 4], - ], // control name, control index, startRow, startCol, endRow, endCol colCount: 4, // 2 ports per side of unit , numbered 1-2 and 3-4 rowCount: 2, // each port has 2 switches @@ -1066,13 +1075,13 @@ export const PRODUCTS: { [name: string]: Product } = { ], // column indicates port #, mono plugs map to row 1, stereo plugs to row 1 and 2 // due to the stereo jack some buttons may always be down when a single pole (mono) plug is plugged in. }), - RailDriver: literal({ //In production: www.raildriver.com + RailDriver: literal({ + //In production: www.raildriver.com name: 'RailDriver Cab Controller', // The RailDriver is a special product that does not conform the the standard X-keys format. It is described here assuming the buttons are remapped and 2 header bytes are added to the data message. hidDevices: [ [210, 0], [210, -1], - - ], + ], bBytes: 6, // this asssumes the button bytes will be remapped. bBits: 8, // see documentation layouts: [ @@ -1085,51 +1094,40 @@ export const PRODUCTS: { [name: string]: Product } = { ['Bail Off', 0, 1, 8, 4, 8], ['Wiper', 0, 1, 9, 4, 9], ['Lights', 0, 3, 9, 4, 9], - - - ], // control name, control index, startRow, startCol, endRow, endCol colCount: 6, // not valid here because the cab layout, see documentation rowCount: 8, // hasPS: false, // - hasTbar: [ // the raildriver has 5 lever controls, we will call them T-bars for this mapping + hasTbar: [ + // the raildriver has 5 lever controls, we will call them T-bars for this mapping { tbarByte: 8, //Reverser Lever - }, { tbarByte: 9, //Throttle Lever - }, { tbarByte: 10, //Auto Brake Lever - }, { tbarByte: 11, //Independent Brake - }, //{ // tbarByte: 12, //Bail Off, moving Ind Brake to Right, //}, ], - hasRotary: [ // the raildriver has 2 rotary controls, + hasRotary: [ + // the raildriver has 2 rotary controls, { rotaryByte: 12, //Upper twist knob - }, { rotaryByte: 13, //Lower twist knob - }, - ], backLightType: BackLightType.NONE, // no back light LEDs backLight2offset: 0, //timestamp: none, RailDriver has no time stamp - }), - - } diff --git a/packages/core/src/xkeys.ts b/packages/core/src/xkeys.ts index 0f88d7a..e34652e 100644 --- a/packages/core/src/xkeys.ts +++ b/packages/core/src/xkeys.ts @@ -77,43 +77,40 @@ export class XKeys extends EventEmitter { const found = findProdct() this.device.on('data', (data: Buffer) => { - if(deviceInfo.productId===210) { + if (deviceInfo.productId === 210) { // Note: THe RailDriver is an older device, which doesn't follow the rest of xkeys data structure. // To make it easy for us, we'll just remap the data to work for us. - var rdData = new Uint8Array(32); - rdData[0]=0 // this sets the Unit ID to 0 always + var rdData = new Uint8Array(32) + rdData[0] = 0 // this sets the Unit ID to 0 always if (!this._firmwareVersionIsSet) { - rdData[1]=214 // Fake initial message to set _firmwareVersion + rdData[1] = 214 // Fake initial message to set _firmwareVersion } else if (!this._unitIdIsSet) { - rdData[1]=3 // Fake initial message to set _unitId + rdData[1] = 3 // Fake initial message to set _unitId } else { - rdData[1]=0 // no pg switch, byte is always 0 + rdData[1] = 0 // no pg switch, byte is always 0 } - rdData[2]=data.readUInt8(7) // remap button bits - rdData[3]=data.readUInt8(8) // remap button bits - rdData[4]=data.readUInt8(9) // remap button bits - rdData[5]=data.readUInt8(10) // remap button bits - rdData[6]=data.readUInt8(11) // remap button bits - rdData[7]=data.readUInt8(12) // remap button bits + rdData[2] = data.readUInt8(7) // remap button bits + rdData[3] = data.readUInt8(8) // remap button bits + rdData[4] = data.readUInt8(9) // remap button bits + rdData[5] = data.readUInt8(10) // remap button bits + rdData[6] = data.readUInt8(11) // remap button bits + rdData[7] = data.readUInt8(12) // remap button bits // Add Bailoff to button byte, - if (data.readUInt8(4)>=160){ + if (data.readUInt8(4) >= 160) { // set bit 5 to 1 - rdData[7]= rdData[7]|16 - + rdData[7] = rdData[7] | 16 } - rdData[8]=data.readUInt8(0) // remap analog bytes - rdData[9]=data.readUInt8(1) // remap analog bytes - rdData[10]=data.readUInt8(2) // remap analog bytes - rdData[11]=data.readUInt8(3) // remap analog bytes - rdData[12]=data.readUInt8(5) // remap analog bytes - rdData[13]=data.readUInt8(6) // remap analog bytes - - + rdData[8] = data.readUInt8(0) // remap analog bytes + rdData[9] = data.readUInt8(1) // remap analog bytes + rdData[10] = data.readUInt8(2) // remap analog bytes + rdData[11] = data.readUInt8(3) // remap analog bytes + rdData[12] = data.readUInt8(5) // remap analog bytes + rdData[13] = data.readUInt8(6) // remap analog bytes for (let i = 0; i < 15; i++) { - data[i]=rdData[i] + data[i] = rdData[i] } } @@ -210,15 +207,12 @@ export class XKeys extends EventEmitter { } }) this.product.hasTrackball?.forEach((trackball, index) => { - let x = 256*data.readUInt8(trackball.trackXbyte_H)+data.readUInt8(trackball.trackXbyte_L) // Trackball X //Delta X motion, X ball motion = 256*DELTA_X_H + DELTA_X_L. - let y = 256*data.readUInt8(trackball.trackYbyte_H)+data.readUInt8(trackball.trackYbyte_L) // Trackball Y - - + let x = 256 * data.readUInt8(trackball.trackXbyte_H) + data.readUInt8(trackball.trackXbyte_L) // Trackball X //Delta X motion, X ball motion = 256*DELTA_X_H + DELTA_X_L. + let y = 256 * data.readUInt8(trackball.trackYbyte_H) + data.readUInt8(trackball.trackYbyte_L) // Trackball Y newAnalogStates.trackball[index] = { - x:x, - y:y, - + x: x, + y: y, } }) this.product.hasTbar?.forEach((tBar, index) => { @@ -303,7 +297,6 @@ export class XKeys extends EventEmitter { if (newValue.x !== 0 || newValue.y !== 0) this.emit('trackball', index, newValue, eventMetadata) }) - // Store the new states: this._buttonStates = newButtonStates this._analogStates = newAnalogStates @@ -448,11 +441,13 @@ export class XKeys extends EventEmitter { const location = this._findBtnLocation(keyIndex) - if (this.product.backLightType === BackLightType.REMAP_24) { // obsloete, Consier removing MHH + if (this.product.backLightType === BackLightType.REMAP_24) { + // obsloete, Consier removing MHH const ledIndex = (location.col - 1) * 8 + location.row - 1 // backlight LED type 5 is the RGB 24 buttons this._write([0, 181, ledIndex, color.g, color.r, color.b, flashing ? 1 : 0]) // Byte order is actually G,R,B,F) - } else if (this.product.backLightType === BackLightType.RGBx2) {// backlight LED type 6, 2 banks of full RGB LEDs + } else if (this.product.backLightType === BackLightType.RGBx2) { + // backlight LED type 6, 2 banks of full RGB LEDs const ledIndex = keyIndex - 1 // 0 based linear numbering sort of... if (bankIndex !== undefined) { @@ -495,9 +490,9 @@ export class XKeys extends EventEmitter { /** * Sets the backlight of all buttons * @param color r,g,b or string (RGB, RRGGBB, #RRGGBB) - * @param bankIndex number: Which LED bank (top or bottom) to control. + * @param bankIndex number: Which LED bank (top or bottom) to control. */ - public setAllBacklights(color: Color | string | boolean | null,bankIndex?: number): void { + public setAllBacklights(color: Color | string | boolean | null, bankIndex?: number): void { this.ensureInitialized() color = this._interpretColor(color, this.product.backLightType) @@ -508,8 +503,8 @@ export class XKeys extends EventEmitter { this._write([0, 166, bankIndex, color.r, color.g, color.b]) } else { // There are 2 leds in under a key, 0 for top and 1 for bottom. - this._write([0, 166, 0, color.r, color.g, color.b] ) - this._write([0, 166, 1, color.r, color.g, color.b] ) + this._write([0, 166, 0, color.r, color.g, color.b]) + this._write([0, 166, 1, color.r, color.g, color.b]) } } else { // Blue LEDs: diff --git a/yarn.lock b/yarn.lock index a9caeb4..309fdc3 100644 --- a/yarn.lock +++ b/yarn.lock @@ -301,19 +301,19 @@ resolved "https://registry.yarnpkg.com/@discoveryjs/json-ext/-/json-ext-0.5.7.tgz#1d572bfbbe14b7704e0ba0f39b74815b84870d70" integrity sha512-dBVuXR082gk3jsFp7Rd/JI4kytwGHecnCoTtXFb7DB6CNHp4rg5k1bhg0nWdLGLnOV71lmDzGQaLMy8iPLY0pw== -"@eslint/eslintrc@^1.2.1": - version "1.2.1" - resolved "https://registry.yarnpkg.com/@eslint/eslintrc/-/eslintrc-1.2.1.tgz#8b5e1c49f4077235516bc9ec7d41378c0f69b8c6" - integrity sha512-bxvbYnBPN1Gibwyp6NrpnFzA3YtRL3BBAyEAFVIpNTm2Rn4Vy87GA5M4aSn3InRrlsbX5N0GW7XIx+U4SAEKdQ== +"@eslint/eslintrc@^1.3.0": + version "1.3.0" + resolved "https://registry.yarnpkg.com/@eslint/eslintrc/-/eslintrc-1.3.0.tgz#29f92c30bb3e771e4a2048c95fa6855392dfac4f" + integrity sha512-UWW0TMTmk2d7hLcWD1/e2g5HDM/HQ3csaLSqXCfqwh4uNDuNqlaKWXmEsL4Cs41Z0KnILNvwbHAah3C2yt06kw== dependencies: ajv "^6.12.4" debug "^4.3.2" - espree "^9.3.1" - globals "^13.9.0" + espree "^9.3.2" + globals "^13.15.0" ignore "^5.2.0" import-fresh "^3.2.1" js-yaml "^4.1.0" - minimatch "^3.0.4" + minimatch "^3.1.2" strip-json-comments "^3.1.1" "@gar/promisify@^1.0.1": @@ -1445,24 +1445,24 @@ dependencies: "@sinonjs/commons" "^1.7.0" -"@sofie-automation/code-standard-preset@~1.0": - version "1.0.0" - resolved "https://registry.yarnpkg.com/@sofie-automation/code-standard-preset/-/code-standard-preset-1.0.0.tgz#13d565d0a55c1bf95e2667338c28e44ca4f82cfa" - integrity sha512-tu6NEoMU1LWv+yar1DFCYpBZUE5D1+NyXRJSfq+c+dDDPfUw0jHVkzpozQWopINwBy1c/oiJBW6kdcJWmLlAuQ== +"@sofie-automation/code-standard-preset@~2.0.2": + version "2.0.2" + resolved "https://registry.yarnpkg.com/@sofie-automation/code-standard-preset/-/code-standard-preset-2.0.2.tgz#e2bff6e75bd7cd8638fc624a40aea087fddb3a7b" + integrity sha512-ksQ8feMBxDVjZACMQhP5Irebjwde6OaS9mAASicS2MNs9VEaltl4sgwlbYIL5jkxISrdzvLiYk2PtdWm4rJHew== dependencies: - "@typescript-eslint/eslint-plugin" "^5.10.0" - "@typescript-eslint/parser" "^5.10.0" - eslint "^8.7.0" + "@typescript-eslint/eslint-plugin" "^5.24.0" + "@typescript-eslint/parser" "^5.24.0" + eslint "^8.9.0" eslint-config-prettier "^8.3.0" - eslint-plugin-jest "^25.7.0" + eslint-plugin-jest "^26.1.1" eslint-plugin-node "^11.1.0" eslint-plugin-prettier "^4.0.0" husky "^7.0.4" license-checker "^25.0.1" - lint-staged "^12.2.0" + lint-staged "^12.3.4" meow "^10.1.2" prettier "^2.5.1" - read-pkg-up "^9.0.0" + read-pkg-up "^9.1.0" shelljs "^0.8.5" "@szmarczak/http-timer@^1.1.2": @@ -1637,92 +1637,85 @@ dependencies: "@types/yargs-parser" "*" -"@typescript-eslint/eslint-plugin@^5.10.0": - version "5.19.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/eslint-plugin/-/eslint-plugin-5.19.0.tgz#9608a4b6d0427104bccf132f058cba629a6553c0" - integrity sha512-w59GpFqDYGnWFim9p6TGJz7a3qWeENJuAKCqjGSx+Hq/bwq3RZwXYqy98KIfN85yDqz9mq6QXiY5h0FjGQLyEg== +"@typescript-eslint/eslint-plugin@^5.24.0": + version "5.29.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/eslint-plugin/-/eslint-plugin-5.29.0.tgz#c67794d2b0fd0b4a47f50266088acdc52a08aab6" + integrity sha512-kgTsISt9pM53yRFQmLZ4npj99yGl3x3Pl7z4eA66OuTzAGC4bQB5H5fuLwPnqTKU3yyrrg4MIhjF17UYnL4c0w== dependencies: - "@typescript-eslint/scope-manager" "5.19.0" - "@typescript-eslint/type-utils" "5.19.0" - "@typescript-eslint/utils" "5.19.0" - debug "^4.3.2" + "@typescript-eslint/scope-manager" "5.29.0" + "@typescript-eslint/type-utils" "5.29.0" + "@typescript-eslint/utils" "5.29.0" + debug "^4.3.4" functional-red-black-tree "^1.0.1" - ignore "^5.1.8" + ignore "^5.2.0" regexpp "^3.2.0" - semver "^7.3.5" + semver "^7.3.7" tsutils "^3.21.0" -"@typescript-eslint/experimental-utils@^5.0.0": - version "5.19.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/experimental-utils/-/experimental-utils-5.19.0.tgz#b7c8f1e22624d4f3d1b3683438530f5636086cb7" - integrity sha512-F+X/TTzmb2UXbghY1LrNLNDjMcGZMhKzXuzvu0xD+YEB77EamLM7zMOLuz2kP5807IJRDLBoAFFPYa7HT62sYg== - dependencies: - "@typescript-eslint/utils" "5.19.0" - -"@typescript-eslint/parser@^5.10.0": - version "5.19.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/parser/-/parser-5.19.0.tgz#05e587c1492868929b931afa0cb5579b0f728e75" - integrity sha512-yhktJjMCJX8BSBczh1F/uY8wGRYrBeyn84kH6oyqdIJwTGKmzX5Qiq49LRQ0Jh0LXnWijEziSo6BRqny8nqLVQ== +"@typescript-eslint/parser@^5.24.0": + version "5.29.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/parser/-/parser-5.29.0.tgz#41314b195b34d44ff38220caa55f3f93cfca43cf" + integrity sha512-ruKWTv+x0OOxbzIw9nW5oWlUopvP/IQDjB5ZqmTglLIoDTctLlAJpAQFpNPJP/ZI7hTT9sARBosEfaKbcFuECw== dependencies: - "@typescript-eslint/scope-manager" "5.19.0" - "@typescript-eslint/types" "5.19.0" - "@typescript-eslint/typescript-estree" "5.19.0" - debug "^4.3.2" + "@typescript-eslint/scope-manager" "5.29.0" + "@typescript-eslint/types" "5.29.0" + "@typescript-eslint/typescript-estree" "5.29.0" + debug "^4.3.4" -"@typescript-eslint/scope-manager@5.19.0": - version "5.19.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/scope-manager/-/scope-manager-5.19.0.tgz#97e59b0bcbcb54dbcdfba96fc103b9020bbe9cb4" - integrity sha512-Fz+VrjLmwq5fbQn5W7cIJZ066HxLMKvDEmf4eu1tZ8O956aoX45jAuBB76miAECMTODyUxH61AQM7q4/GOMQ5g== +"@typescript-eslint/scope-manager@5.29.0": + version "5.29.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/scope-manager/-/scope-manager-5.29.0.tgz#2a6a32e3416cb133e9af8dcf54bf077a916aeed3" + integrity sha512-etbXUT0FygFi2ihcxDZjz21LtC+Eps9V2xVx09zFoN44RRHPrkMflidGMI+2dUs821zR1tDS6Oc9IXxIjOUZwA== dependencies: - "@typescript-eslint/types" "5.19.0" - "@typescript-eslint/visitor-keys" "5.19.0" + "@typescript-eslint/types" "5.29.0" + "@typescript-eslint/visitor-keys" "5.29.0" -"@typescript-eslint/type-utils@5.19.0": - version "5.19.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/type-utils/-/type-utils-5.19.0.tgz#80f2125b0dfe82494bbae1ea99f1c0186d420282" - integrity sha512-O6XQ4RI4rQcBGshTQAYBUIGsKqrKeuIOz9v8bckXZnSeXjn/1+BDZndHLe10UplQeJLXDNbaZYrAytKNQO2T4Q== +"@typescript-eslint/type-utils@5.29.0": + version "5.29.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/type-utils/-/type-utils-5.29.0.tgz#241918001d164044020b37d26d5b9f4e37cc3d5d" + integrity sha512-JK6bAaaiJozbox3K220VRfCzLa9n0ib/J+FHIwnaV3Enw/TO267qe0pM1b1QrrEuy6xun374XEAsRlA86JJnyg== dependencies: - "@typescript-eslint/utils" "5.19.0" - debug "^4.3.2" + "@typescript-eslint/utils" "5.29.0" + debug "^4.3.4" tsutils "^3.21.0" -"@typescript-eslint/types@5.19.0": - version "5.19.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/types/-/types-5.19.0.tgz#12d3d600d754259da771806ee8b2c842d3be8d12" - integrity sha512-zR1ithF4Iyq1wLwkDcT+qFnhs8L5VUtjgac212ftiOP/ZZUOCuuF2DeGiZZGQXGoHA50OreZqLH5NjDcDqn34w== +"@typescript-eslint/types@5.29.0": + version "5.29.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/types/-/types-5.29.0.tgz#7861d3d288c031703b2d97bc113696b4d8c19aab" + integrity sha512-X99VbqvAXOMdVyfFmksMy3u8p8yoRGITgU1joBJPzeYa0rhdf5ok9S56/itRoUSh99fiDoMtarSIJXo7H/SnOg== -"@typescript-eslint/typescript-estree@5.19.0": - version "5.19.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/typescript-estree/-/typescript-estree-5.19.0.tgz#fc987b8f62883f9ea6a5b488bdbcd20d33c0025f" - integrity sha512-dRPuD4ocXdaE1BM/dNR21elSEUPKaWgowCA0bqJ6YbYkvtrPVEvZ+zqcX5a8ECYn3q5iBSSUcBBD42ubaOp0Hw== +"@typescript-eslint/typescript-estree@5.29.0": + version "5.29.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/typescript-estree/-/typescript-estree-5.29.0.tgz#e83d19aa7fd2e74616aab2f25dfbe4de4f0b5577" + integrity sha512-mQvSUJ/JjGBdvo+1LwC+GY2XmSYjK1nAaVw2emp/E61wEVYEyibRHCqm1I1vEKbXCpUKuW4G7u9ZCaZhJbLoNQ== dependencies: - "@typescript-eslint/types" "5.19.0" - "@typescript-eslint/visitor-keys" "5.19.0" - debug "^4.3.2" - globby "^11.0.4" + "@typescript-eslint/types" "5.29.0" + "@typescript-eslint/visitor-keys" "5.29.0" + debug "^4.3.4" + globby "^11.1.0" is-glob "^4.0.3" - semver "^7.3.5" + semver "^7.3.7" tsutils "^3.21.0" -"@typescript-eslint/utils@5.19.0": - version "5.19.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/utils/-/utils-5.19.0.tgz#fe87f1e3003d9973ec361ed10d36b4342f1ded1e" - integrity sha512-ZuEckdupXpXamKvFz/Ql8YnePh2ZWcwz7APICzJL985Rp5C2AYcHO62oJzIqNhAMtMK6XvrlBTZeNG8n7gS3lQ== +"@typescript-eslint/utils@5.29.0", "@typescript-eslint/utils@^5.10.0": + version "5.29.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/utils/-/utils-5.29.0.tgz#775046effd5019667bd086bcf326acbe32cd0082" + integrity sha512-3Eos6uP1nyLOBayc/VUdKZikV90HahXE5Dx9L5YlSd/7ylQPXhLk1BYb29SDgnBnTp+jmSZUU0QxUiyHgW4p7A== dependencies: "@types/json-schema" "^7.0.9" - "@typescript-eslint/scope-manager" "5.19.0" - "@typescript-eslint/types" "5.19.0" - "@typescript-eslint/typescript-estree" "5.19.0" + "@typescript-eslint/scope-manager" "5.29.0" + "@typescript-eslint/types" "5.29.0" + "@typescript-eslint/typescript-estree" "5.29.0" eslint-scope "^5.1.1" eslint-utils "^3.0.0" -"@typescript-eslint/visitor-keys@5.19.0": - version "5.19.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/visitor-keys/-/visitor-keys-5.19.0.tgz#c84ebc7f6c744707a361ca5ec7f7f64cd85b8af6" - integrity sha512-Ym7zZoMDZcAKWsULi2s7UMLREdVQdScPQ/fKWMYefarCztWlHPFVJo8racf8R0Gc8FAEJ2eD4of8As1oFtnQlQ== +"@typescript-eslint/visitor-keys@5.29.0": + version "5.29.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/visitor-keys/-/visitor-keys-5.29.0.tgz#7a4749fa7ef5160c44a451bf060ac1dc6dfb77ee" + integrity sha512-Hpb/mCWsjILvikMQoZIE3voc9wtQcS0A9FUw3h8bhr9UxBdtI/tw1ZDZUOXHXLOVMedKCH5NxyzATwnU78bWCQ== dependencies: - "@typescript-eslint/types" "5.19.0" - eslint-visitor-keys "^3.0.0" + "@typescript-eslint/types" "5.29.0" + eslint-visitor-keys "^3.3.0" "@webassemblyjs/ast@1.11.1": version "1.11.1" @@ -1911,7 +1904,7 @@ acorn-import-assertions@^1.7.6: resolved "https://registry.yarnpkg.com/acorn-import-assertions/-/acorn-import-assertions-1.8.0.tgz#ba2b5939ce62c238db6d93d81c9b111b29b855e9" integrity sha512-m7VZ3jwz4eK6A4Vtt8Ew1/mNbP24u0FhdyfA7fSvnJR6LMdfOYnmuIrrJAgrYfYJ10F/otaHTtrtrtmHdMNzEw== -acorn-jsx@^5.3.1: +acorn-jsx@^5.3.2: version "5.3.2" resolved "https://registry.yarnpkg.com/acorn-jsx/-/acorn-jsx-5.3.2.tgz#7ed5bb55908b3b2f1bc55c6af1653bada7f07937" integrity sha512-rq9s+JNhf0IChjtDXxllJ7g41oZk5SlXtp0LHwyA5cejwn7vKmKp4pPri6YEePv2PU65sAsegbXtIinmDFDXgQ== @@ -1926,11 +1919,16 @@ acorn@^7.1.1: resolved "https://registry.yarnpkg.com/acorn/-/acorn-7.4.1.tgz#feaed255973d2e77555b83dbc08851a6c63520fa" integrity sha512-nQyp0o1/mNdbTO1PO6kHkwSrmgZ0MT/jCCpNiwbUjGoRN4dlBhqJtoQuCnEOKzgTVwg0ZWiCoQy6SxMebQVh8A== -acorn@^8.2.4, acorn@^8.4.1, acorn@^8.5.0, acorn@^8.7.0: +acorn@^8.2.4, acorn@^8.4.1, acorn@^8.5.0: version "8.7.0" resolved "https://registry.yarnpkg.com/acorn/-/acorn-8.7.0.tgz#90951fde0f8f09df93549481e5fc141445b791cf" integrity sha512-V/LGr1APy+PXIwKebEWrkZPwoeoF+w1jiOBUmuxuiUIaOHtob8Qc9BTrYo7VuI5fR8tqsy+buA2WFooR5olqvQ== +acorn@^8.7.1: + version "8.7.1" + resolved "https://registry.yarnpkg.com/acorn/-/acorn-8.7.1.tgz#0197122c843d1bf6d0a5e83220a788f278f63c30" + integrity sha512-Xx54uLJQZ19lKygFXOWsscKUbsBZW0CPykPhVQdhIeIwrbPmJzqeASDInc8nKBnp/JT6igTs82qPXz069H8I/A== + add-stream@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/add-stream/-/add-stream-1.0.0.tgz#6a7990437ca736d5e1288db92bd3266d5f5cb2aa" @@ -2935,10 +2933,10 @@ commander@^7.0.0: resolved "https://registry.yarnpkg.com/commander/-/commander-7.2.0.tgz#a36cb57d0b501ce108e4d20559a150a391d97ab7" integrity sha512-QrWXB+ZQSVPmIWIhtEO9H+gwHaMGYiF5ChvoJ+K9ZGHG/sVsa6yiesAD1GC/x46sET00Xlwo1u49RVVVzvcSkw== -commander@^8.3.0: - version "8.3.0" - resolved "https://registry.yarnpkg.com/commander/-/commander-8.3.0.tgz#4837ea1b2da67b9c616a67afbb0fafee567bca66" - integrity sha512-OkTL9umf+He2DZkUq8f8J9of7yL6RJKI24dVITBmNfZBmri9zYZQrKkuXiKhyfPSu8tUhnVBB1iKXevvnlR4Ww== +commander@^9.3.0: + version "9.3.0" + resolved "https://registry.yarnpkg.com/commander/-/commander-9.3.0.tgz#f619114a5a2d2054e0d9ff1b31d5ccf89255e26b" + integrity sha512-hv95iU5uXPbK83mjrJKuZyFM/LBAoCV/XhVGkS5Je6tl7sxr6A0ITMw5WoRV46/UaJ46Nllm3Xt7IaJhXTIkzw== compare-func@^2.0.0: version "2.0.0" @@ -3234,7 +3232,7 @@ debug@2.6.9, debug@^2.2.0, debug@^2.3.3: dependencies: ms "2.0.0" -debug@4, debug@^4.1.0, debug@^4.1.1, debug@^4.3.1, debug@^4.3.2, debug@^4.3.3: +debug@4, debug@^4.1.0, debug@^4.1.1, debug@^4.3.1, debug@^4.3.2, debug@^4.3.4: version "4.3.4" resolved "https://registry.yarnpkg.com/debug/-/debug-4.3.4.tgz#1319f6579357f2338d3337d2cdd4914bb5dcc865" integrity sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ== @@ -3811,12 +3809,12 @@ eslint-plugin-es@^3.0.0: eslint-utils "^2.0.0" regexpp "^3.0.0" -eslint-plugin-jest@^25.7.0: - version "25.7.0" - resolved "https://registry.yarnpkg.com/eslint-plugin-jest/-/eslint-plugin-jest-25.7.0.tgz#ff4ac97520b53a96187bad9c9814e7d00de09a6a" - integrity sha512-PWLUEXeeF7C9QGKqvdSbzLOiLTx+bno7/HC9eefePfEb257QFHg7ye3dh80AZVkaa/RQsBB1Q/ORQvg2X7F0NQ== +eslint-plugin-jest@^26.1.1: + version "26.5.3" + resolved "https://registry.yarnpkg.com/eslint-plugin-jest/-/eslint-plugin-jest-26.5.3.tgz#a3ceeaf4a757878342b8b00eca92379b246e5505" + integrity sha512-sICclUqJQnR1bFRZGLN2jnSVsYOsmPYYnroGCIMVSvTS3y8XR3yjzy1EcTQmk6typ5pRgyIWzbjqxK6cZHEZuQ== dependencies: - "@typescript-eslint/experimental-utils" "^5.0.0" + "@typescript-eslint/utils" "^5.10.0" eslint-plugin-node@^11.1.0: version "11.1.0" @@ -3877,17 +3875,17 @@ eslint-visitor-keys@^2.0.0: resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-2.1.0.tgz#f65328259305927392c938ed44eb0a5c9b2bd303" integrity sha512-0rSmRBzXgDzIsD6mGdJgevzgezI534Cer5L/vyMX0kHzT/jiB43jRhd9YUlMGYLQy2zprNmoT8qasCGtY+QaKw== -eslint-visitor-keys@^3.0.0, eslint-visitor-keys@^3.3.0: +eslint-visitor-keys@^3.3.0: version "3.3.0" resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-3.3.0.tgz#f6480fa6b1f30efe2d1968aa8ac745b862469826" integrity sha512-mQ+suqKJVyeuwGYHAdjMFqjCyfl8+Ldnxuyp3ldiMBFKkvytrXUZWaiPCEav8qDHKty44bD+qV1IP4T+w+xXRA== -eslint@^8.7.0: - version "8.13.0" - resolved "https://registry.yarnpkg.com/eslint/-/eslint-8.13.0.tgz#6fcea43b6811e655410f5626cfcf328016badcd7" - integrity sha512-D+Xei61eInqauAyTJ6C0q6x9mx7kTUC1KZ0m0LSEexR0V+e94K12LmWX076ZIsldwfQ2RONdaJe0re0TRGQbRQ== +eslint@^8.9.0: + version "8.18.0" + resolved "https://registry.yarnpkg.com/eslint/-/eslint-8.18.0.tgz#78d565d16c993d0b73968c523c0446b13da784fd" + integrity sha512-As1EfFMVk7Xc6/CvhssHUjsAQSkpfXvUGMFC3ce8JDe6WvqCgRrLOBQbVpsBFr1X1V+RACOadnzVvcUS5ni2bA== dependencies: - "@eslint/eslintrc" "^1.2.1" + "@eslint/eslintrc" "^1.3.0" "@humanwhocodes/config-array" "^0.9.2" ajv "^6.10.0" chalk "^4.0.0" @@ -3898,14 +3896,14 @@ eslint@^8.7.0: eslint-scope "^7.1.1" eslint-utils "^3.0.0" eslint-visitor-keys "^3.3.0" - espree "^9.3.1" + espree "^9.3.2" esquery "^1.4.0" esutils "^2.0.2" fast-deep-equal "^3.1.3" file-entry-cache "^6.0.1" functional-red-black-tree "^1.0.1" glob-parent "^6.0.1" - globals "^13.6.0" + globals "^13.15.0" ignore "^5.2.0" import-fresh "^3.0.0" imurmurhash "^0.1.4" @@ -3914,7 +3912,7 @@ eslint@^8.7.0: json-stable-stringify-without-jsonify "^1.0.1" levn "^0.4.1" lodash.merge "^4.6.2" - minimatch "^3.0.4" + minimatch "^3.1.2" natural-compare "^1.4.0" optionator "^0.9.1" regexpp "^3.2.0" @@ -3923,13 +3921,13 @@ eslint@^8.7.0: text-table "^0.2.0" v8-compile-cache "^2.0.3" -espree@^9.3.1: - version "9.3.1" - resolved "https://registry.yarnpkg.com/espree/-/espree-9.3.1.tgz#8793b4bc27ea4c778c19908e0719e7b8f4115bcd" - integrity sha512-bvdyLmJMfwkV3NCRl5ZhJf22zBFo1y8bYh3VYb+bfzqNB4Je68P2sSuXyuFquzWLebHpNd2/d5uv7yoP9ISnGQ== +espree@^9.3.2: + version "9.3.2" + resolved "https://registry.yarnpkg.com/espree/-/espree-9.3.2.tgz#f58f77bd334731182801ced3380a8cc859091596" + integrity sha512-D211tC7ZwouTIuY5x9XnS0E9sWNChB7IYKX/Xp5eQj3nFXhqmiUDB9q27y76oFl8jTg3pXcQx/bpxMfs3CIZbA== dependencies: - acorn "^8.7.0" - acorn-jsx "^5.3.1" + acorn "^8.7.1" + acorn-jsx "^5.3.2" eslint-visitor-keys "^3.3.0" esprima@^4.0.0, esprima@^4.0.1: @@ -4742,14 +4740,14 @@ globals@^11.1.0: resolved "https://registry.yarnpkg.com/globals/-/globals-11.12.0.tgz#ab8795338868a0babd8525758018c2a7eb95c42e" integrity sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA== -globals@^13.6.0, globals@^13.9.0: - version "13.13.0" - resolved "https://registry.yarnpkg.com/globals/-/globals-13.13.0.tgz#ac32261060d8070e2719dd6998406e27d2b5727b" - integrity sha512-EQ7Q18AJlPwp3vUDL4mKA0KXrXyNIQyWon6T6XQiBQF0XHvRsiCSrWmmeATpUzdJN2HhWZU6Pdl0a9zdep5p6A== +globals@^13.15.0: + version "13.15.0" + resolved "https://registry.yarnpkg.com/globals/-/globals-13.15.0.tgz#38113218c907d2f7e98658af246cef8b77e90bac" + integrity sha512-bpzcOlgDhMG070Av0Vy5Owklpv1I6+j96GhUI7Rh7IzDCKLzboflLrrfqMu8NquDbiR4EOQk7XzJwqVJxicxog== dependencies: type-fest "^0.20.2" -globby@^11.0.1, globby@^11.0.2, globby@^11.0.4: +globby@^11.0.1, globby@^11.0.2, globby@^11.1.0: version "11.1.0" resolved "https://registry.yarnpkg.com/globby/-/globby-11.1.0.tgz#bd4be98bb042f83d796f7e3811991fbe82a0d34b" integrity sha512-jhIXaOzy1sb8IyocaruWSn1TjmnBVs8Ayhcy83rmxNJ8q2uWKCAj3CnJY+KpGSXCueAPc0i05kVvVKtP1t9S3g== @@ -5138,7 +5136,7 @@ ignore@^4.0.3: resolved "https://registry.yarnpkg.com/ignore/-/ignore-4.0.6.tgz#750e3db5862087b4737ebac8207ffd1ef27b25fc" integrity sha512-cyFDKrqc/YdcWFniJhzI42+AzS+gNwmUzOSFcRCQYwySuBBBy/KjuxWLZ/FHEH6Moq1NizMOBWyTcv8O4OZIMg== -ignore@^5.1.1, ignore@^5.1.8, ignore@^5.2.0: +ignore@^5.1.1, ignore@^5.2.0: version "5.2.0" resolved "https://registry.yarnpkg.com/ignore/-/ignore-5.2.0.tgz#6d3bac8fa7fe0d45d9f9be7bac2fc279577e345a" integrity sha512-CmxgYGiEPCLhfLnpPp1MoRmifwEIOgjcHXxOBjv7mY96c+eWScsOP9c112ZyLdWHi0FxHjI+4uVhKYp/gcdRmQ== @@ -6375,37 +6373,37 @@ license-checker@^25.0.1: spdx-satisfies "^4.0.0" treeify "^1.1.0" -lilconfig@2.0.4: - version "2.0.4" - resolved "https://registry.yarnpkg.com/lilconfig/-/lilconfig-2.0.4.tgz#f4507d043d7058b380b6a8f5cb7bcd4b34cee082" - integrity sha512-bfTIN7lEsiooCocSISTWXkiWJkRqtL9wYtYy+8EK3Y41qh3mpwPU0ycTOgjdY9ErwXCc8QyrQp82bdL0Xkm9yA== +lilconfig@2.0.5: + version "2.0.5" + resolved "https://registry.yarnpkg.com/lilconfig/-/lilconfig-2.0.5.tgz#19e57fd06ccc3848fd1891655b5a447092225b25" + integrity sha512-xaYmXZtTHPAw5m+xLN8ab9C+3a8YmV3asNSPOATITbtwrfbwaLJj8h66H1WMIpALCkqsIzK3h7oQ+PdX+LQ9Eg== lines-and-columns@^1.1.6: version "1.2.4" resolved "https://registry.yarnpkg.com/lines-and-columns/-/lines-and-columns-1.2.4.tgz#eca284f75d2965079309dc0ad9255abb2ebc1632" integrity sha512-7ylylesZQ/PV29jhEDl3Ufjo6ZX7gCqJr5F7PKrqc93v7fzSymt1BpwEU8nAUXs8qzzvqhbjhK5QZg6Mt/HkBg== -lint-staged@^12.2.0: - version "12.3.8" - resolved "https://registry.yarnpkg.com/lint-staged/-/lint-staged-12.3.8.tgz#ee3fe2e16c9d76f99d8348072900b017d6d76901" - integrity sha512-0+UpNaqIwKRSGAFOCcpuYNIv/j5QGVC+xUVvmSdxHO+IfIGoHbFLo3XcPmV/LLnsVj5EAncNHVtlITSoY5qWGQ== +lint-staged@^12.3.4: + version "12.5.0" + resolved "https://registry.yarnpkg.com/lint-staged/-/lint-staged-12.5.0.tgz#d6925747480ae0e380d13988522f9dd8ef9126e3" + integrity sha512-BKLUjWDsKquV/JuIcoQW4MSAI3ggwEImF1+sB4zaKvyVx1wBk3FsG7UK9bpnmBTN1pm7EH2BBcMwINJzCRv12g== dependencies: cli-truncate "^3.1.0" colorette "^2.0.16" - commander "^8.3.0" - debug "^4.3.3" + commander "^9.3.0" + debug "^4.3.4" execa "^5.1.1" - lilconfig "2.0.4" - listr2 "^4.0.1" - micromatch "^4.0.4" + lilconfig "2.0.5" + listr2 "^4.0.5" + micromatch "^4.0.5" normalize-path "^3.0.0" - object-inspect "^1.12.0" + object-inspect "^1.12.2" pidtree "^0.5.0" string-argv "^0.3.1" - supports-color "^9.2.1" + supports-color "^9.2.2" yaml "^1.10.2" -listr2@^4.0.1: +listr2@^4.0.5: version "4.0.5" resolved "https://registry.yarnpkg.com/listr2/-/listr2-4.0.5.tgz#9dcc50221583e8b4c71c43f9c7dfd0ef546b75d5" integrity sha512-juGHV1doQdpNT3GSTs9IUN43QJb7KHdF9uqg7Vufs/tG9VTzpFphqF4pm/ICdAABGQxsyNn9CiYA3StkI6jpwA== @@ -6768,7 +6766,7 @@ micromatch@^3.1.10, micromatch@^3.1.4: snapdragon "^0.8.1" to-regex "^3.0.2" -micromatch@^4.0.0, micromatch@^4.0.2, micromatch@^4.0.4: +micromatch@^4.0.0, micromatch@^4.0.2, micromatch@^4.0.4, micromatch@^4.0.5: version "4.0.5" resolved "https://registry.yarnpkg.com/micromatch/-/micromatch-4.0.5.tgz#bc8999a7cbbf77cdc89f132f6e467051b49090c6" integrity sha512-DMy+ERcEW2q8Z2Po+WNXuw3c5YaUSFjAO5GsJqfEl7UjvtIuFKO6ZrKvcItdy98dwFI2N1tg3zNIdKaQT+aNdA== @@ -6833,7 +6831,7 @@ minimalistic-assert@^1.0.0: resolved "https://registry.yarnpkg.com/minimalistic-assert/-/minimalistic-assert-1.0.1.tgz#2e194de044626d4a10e7f7fbc00ce73e83e4d5c7" integrity sha512-UtJcAD4yEaGtjPezWuO9wC4nwUnVH/8/Im3yEHQP4b67cXlD/Qr9hdITCU1xDbSEXg2XKNaP8jsReV7vQd00/A== -minimatch@^3.0.4: +minimatch@^3.0.4, minimatch@^3.1.2: version "3.1.2" resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.1.2.tgz#19cd194bfd3e428f049a70817c038d89ab4be35b" integrity sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw== @@ -7405,6 +7403,11 @@ object-inspect@^1.12.0, object-inspect@^1.9.0: resolved "https://registry.yarnpkg.com/object-inspect/-/object-inspect-1.12.0.tgz#6e2c120e868fd1fd18cb4f18c31741d0d6e776f0" integrity sha512-Ho2z80bVIvJloH+YzRmpZVQe87+qASmBUKZDWgx9cu+KDrX2ZDH/3tMy+gXbZETVGs2M8YdxObOh7XAtim9Y0g== +object-inspect@^1.12.2: + version "1.12.2" + resolved "https://registry.yarnpkg.com/object-inspect/-/object-inspect-1.12.2.tgz#c0641f26394532f28ab8d796ab954e43c009a8ea" + integrity sha512-z+cPxW0QGUp0mcqcsgQyLVRDoXFQbXOwBaqyF7VIgI4TWNQsDHrBpUQslRmIfAoYWdYzs6UlKJtB2XJpTaNSpQ== + object-is@^1.0.1: version "1.1.5" resolved "https://registry.yarnpkg.com/object-is/-/object-is-1.1.5.tgz#b9deeaa5fc7f1846a0faecdceec138e5778f53ac" @@ -8311,7 +8314,7 @@ read-pkg-up@^8.0.0: read-pkg "^6.0.0" type-fest "^1.0.1" -read-pkg-up@^9.0.0: +read-pkg-up@^9.1.0: version "9.1.0" resolved "https://registry.yarnpkg.com/read-pkg-up/-/read-pkg-up-9.1.0.tgz#38ca48e0bc6c6b260464b14aad9bcd4e5b1fbdc3" integrity sha512-vaMRR1AC1nrd5CQM0PhlRsO5oc2AAigqr7cCrZ/MW/Rsaflz4RlgzkpL4qoU/z1F6wrbd85iFv1OQj/y5RdGvg== @@ -8747,7 +8750,7 @@ selfsigned@^1.10.8: resolved "https://registry.yarnpkg.com/semver/-/semver-5.7.1.tgz#a954f931aeba508d307bbf069eff0c01c96116f7" integrity sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ== -semver@7.x, semver@^7.1.1, semver@^7.1.3, semver@^7.3.2, semver@^7.3.4, semver@^7.3.5: +semver@7.x, semver@^7.1.1, semver@^7.1.3, semver@^7.3.2, semver@^7.3.4, semver@^7.3.5, semver@^7.3.7: version "7.3.7" resolved "https://registry.yarnpkg.com/semver/-/semver-7.3.7.tgz#12c5b649afdbf9049707796e22a4028814ce523f" integrity sha512-QlYTucUYOews+WeEujDoEGziz4K6c47V/Bd+LjSSYcA94p+DmINdf7ncaUinThfvZyu13lN9OY1XDxt8C0Tw0g== @@ -9473,7 +9476,7 @@ supports-color@^8.0.0: dependencies: has-flag "^4.0.0" -supports-color@^9.2.1: +supports-color@^9.2.2: version "9.2.2" resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-9.2.2.tgz#502acaf82f2b7ee78eb7c83dcac0f89694e5a7bb" integrity sha512-XC6g/Kgux+rJXmwokjm9ECpD6k/smUoS5LKlUCcsYr4IY3rW0XyAympon2RmxGrlnZURMpg5T18gWDP9CsHXFA== From ac0e40953038569373fe6002fd7855554c65398f Mon Sep 17 00:00:00 2001 From: Johan Nyman Date: Tue, 21 Jun 2022 15:49:57 +0200 Subject: [PATCH 05/49] chore: fix a few minor build issues --- packages/core/src/xkeys.ts | 11 ++---- packages/node-record-test/src/index.ts | 5 ++- packages/node/src/node-hid-wrapper.ts | 1 + packages/webhid-demo/src/app.ts | 54 +++++++++++++------------- packages/webhid/src/web-hid-wrapper.ts | 3 +- 5 files changed, 37 insertions(+), 37 deletions(-) diff --git a/packages/core/src/xkeys.ts b/packages/core/src/xkeys.ts index e34652e..d500948 100644 --- a/packages/core/src/xkeys.ts +++ b/packages/core/src/xkeys.ts @@ -81,7 +81,7 @@ export class XKeys extends EventEmitter { // Note: THe RailDriver is an older device, which doesn't follow the rest of xkeys data structure. // To make it easy for us, we'll just remap the data to work for us. - var rdData = new Uint8Array(32) + const rdData = new Uint8Array(32) rdData[0] = 0 // this sets the Unit ID to 0 always if (!this._firmwareVersionIsSet) { rdData[1] = 214 // Fake initial message to set _firmwareVersion @@ -207,12 +207,9 @@ export class XKeys extends EventEmitter { } }) this.product.hasTrackball?.forEach((trackball, index) => { - let x = 256 * data.readUInt8(trackball.trackXbyte_H) + data.readUInt8(trackball.trackXbyte_L) // Trackball X //Delta X motion, X ball motion = 256*DELTA_X_H + DELTA_X_L. - let y = 256 * data.readUInt8(trackball.trackYbyte_H) + data.readUInt8(trackball.trackYbyte_L) // Trackball Y - newAnalogStates.trackball[index] = { - x: x, - y: y, + x: 256 * data.readUInt8(trackball.trackXbyte_H) + data.readUInt8(trackball.trackXbyte_L), // Trackball X //Delta X motion, X ball motion = 256*DELTA_X_H + DELTA_X_L. + y: 256 * data.readUInt8(trackball.trackYbyte_H) + data.readUInt8(trackball.trackYbyte_L), // Trackball Y } }) this.product.hasTbar?.forEach((tBar, index) => { @@ -322,7 +319,6 @@ export class XKeys extends EventEmitter { /** Initialize the device. This ensures that the essential information from the device about its state has been received. */ public async init(): Promise { - console.log('initialization start..........') const pReceivedVersion = new Promise((resolve) => { this.receivedVersionResolve = resolve }) @@ -337,7 +333,6 @@ export class XKeys extends EventEmitter { await pReceivedGenerateData this._initialized = true - console.log('initialization done!!!!!!!!') } /** Closes the device. Subsequent commands will raise errors. */ public async close(): Promise { diff --git a/packages/node-record-test/src/index.ts b/packages/node-record-test/src/index.ts index 1e05f40..7a07c04 100644 --- a/packages/node-record-test/src/index.ts +++ b/packages/node-record-test/src/index.ts @@ -165,6 +165,7 @@ async function startRecording(panel: HID_Device) { // @ts-expect-error hack const xkeysDevice = xkeys.device as HIDDevice + // eslint-disable-next-line @typescript-eslint/unbound-method const orgWrite = xkeysDevice.write xkeysDevice.write = (data: number[]) => { bufferedWrites.push(Buffer.from(data)) @@ -299,7 +300,7 @@ async function startRecording(panel: HID_Device) { handleEvent('disconnected') } -function askQuestion(query: string): Promise { +async function askQuestion(query: string): Promise { const rl = readline.createInterface({ input: process.stdin, output: process.stdout, @@ -359,6 +360,6 @@ function doColorLoop(xkeys: XKeys, keyIndex: number) { }, } } -function waitTime(time: number) { +async function waitTime(time: number) { return new Promise((resolve) => setTimeout(resolve, time)) } diff --git a/packages/node/src/node-hid-wrapper.ts b/packages/node/src/node-hid-wrapper.ts index c694ea8..6cee3ad 100644 --- a/packages/node/src/node-hid-wrapper.ts +++ b/packages/node/src/node-hid-wrapper.ts @@ -1,3 +1,4 @@ +/* eslint-disable @typescript-eslint/unbound-method */ import { HIDDevice } from '@xkeys-lib/core' import { EventEmitter } from 'events' import * as HID from 'node-hid' diff --git a/packages/webhid-demo/src/app.ts b/packages/webhid-demo/src/app.ts index bbd3136..1aff658 100644 --- a/packages/webhid-demo/src/app.ts +++ b/packages/webhid-demo/src/app.ts @@ -38,47 +38,49 @@ async function openDevice(device: HIDDevice): Promise { }) } -window.addEventListener('load', async () => { +window.addEventListener('load', () => { appendLog('Page loaded') - // Attempt to open a previously selected device: - const devices = await getOpenedXKeysPanels() - if (devices.length > 0) { - appendLog(`"${devices[0].productName}" already granted in a previous session`) - console.log(devices[0]) - openDevice(devices[0]).catch(console.error) - } + getOpenedXKeysPanels() + .then((devices) => { + if (devices.length > 0) { + appendLog(`"${devices[0].productName}" already granted in a previous session`) + console.log(devices[0]) + openDevice(devices[0]).catch(console.error) + } + }) + .catch(console.error) }) const consentButton = document.getElementById('consent-button') -consentButton?.addEventListener('click', async () => { +consentButton?.addEventListener('click', () => { if (currentXkeys) { appendLog('Closing device') - await currentXkeys.close() + currentXkeys.close().catch(console.error) currentXkeys = null } - let devices: HIDDevice[] // Prompt for a device - try { - appendLog('Asking user for permissions...') - devices = await requestXkeysPanels() - } catch (error) { - appendLog(`No device access granted: ${error}`) - return - } - if (devices.length === 0) { - appendLog('No device was selected') - return - } - appendLog(`Access granted to "${devices[0].productName}"`) - openDevice(devices[0]).catch(console.error) + + appendLog('Asking user for permissions...') + requestXkeysPanels() + .then((devices) => { + if (devices.length === 0) { + appendLog('No device was selected') + return + } + appendLog(`Access granted to "${devices[0].productName}"`) + openDevice(devices[0]).catch(console.error) + }) + .catch((error) => { + appendLog(`No device access granted: ${error}`) + }) }) const closeButton = document.getElementById('close-button') -closeButton?.addEventListener('click', async () => { +closeButton?.addEventListener('click', () => { if (currentXkeys) { appendLog('Closing device') - await currentXkeys.close() + currentXkeys.close().catch(console.error) currentXkeys = null } }) diff --git a/packages/webhid/src/web-hid-wrapper.ts b/packages/webhid/src/web-hid-wrapper.ts index db33e14..806ef67 100644 --- a/packages/webhid/src/web-hid-wrapper.ts +++ b/packages/webhid/src/web-hid-wrapper.ts @@ -1,3 +1,4 @@ +/* eslint-disable @typescript-eslint/unbound-method */ import { HIDDevice as CoreHIDDevice } from '@xkeys-lib/core' import { EventEmitter } from 'events' import Queue from 'p-queue' @@ -35,7 +36,7 @@ export class WebHIDDevice extends EventEmitter implements CoreHIDDevice { public async close(): Promise { await this.device.close() - this.device.removeEventListener('inputreport', this._handleInputreport) + this.device.removeEventListener('inputreport', this._handleInputreport.bind(this)) } private _handleInputreport(event: HIDInputReportEvent) { const buf = WebBuffer.from(event.data.buffer) From fbbabb6ff38f445845ebddffeaa86f0a40daa26b Mon Sep 17 00:00:00 2001 From: Johan Nyman Date: Tue, 21 Jun 2022 15:50:19 +0200 Subject: [PATCH 06/49] chore: update tests --- .../src/__tests__/__snapshots__/xkeys.spec.ts.snap | 4 +++- packages/node/src/__tests__/products.spec.ts | 12 +++++++----- packages/node/src/__tests__/recordings.spec.ts | 2 +- packages/node/src/__tests__/xkeys.spec.ts | 2 +- 4 files changed, 12 insertions(+), 8 deletions(-) diff --git a/packages/node/src/__tests__/__snapshots__/xkeys.spec.ts.snap b/packages/node/src/__tests__/__snapshots__/xkeys.spec.ts.snap index 97c7bb9..d10c810 100644 --- a/packages/node/src/__tests__/__snapshots__/xkeys.spec.ts.snap +++ b/packages/node/src/__tests__/__snapshots__/xkeys.spec.ts.snap @@ -4,16 +4,18 @@ exports[`Unit tests XKeys methods 1`] = ` Object { "colCount": 4, "emitsTimestamp": true, - "firmwareVersion": 0, + "firmwareVersion": 1, "hasDMX": false, "hasGPIO": false, "hasJog": 0, "hasJoystick": 0, "hasLCD": false, "hasPS": true, + "hasRotary": 0, "hasSerialData": false, "hasShuttle": 0, "hasTbar": 0, + "hasTrackball": 0, "interface": 0, "layout": Array [ Object { diff --git a/packages/node/src/__tests__/products.spec.ts b/packages/node/src/__tests__/products.spec.ts index 6e0cfd4..26b5f74 100644 --- a/packages/node/src/__tests__/products.spec.ts +++ b/packages/node/src/__tests__/products.spec.ts @@ -2,19 +2,21 @@ import { BackLightType, PRODUCTS } from '@xkeys-lib/core' describe('products.ts', () => { test('productIds should be unique', async () => { - const productIds = new Set() + const productIds = new Map() for (const product of Object.values(PRODUCTS)) { for (const hidDevice of product.hidDevices) { const productId: number = hidDevice[0] - // const interface: number = hidDevice[1] + const productInterface: number = hidDevice[1] + const idPair = `${productId}-${productInterface}` + // console.log('idPair', idPair) try { - expect(productIds.has(productId)).toBeFalsy() + expect(productIds.has(idPair)).toBeFalsy() } catch (err) { - console.log('productid', productId) + console.log('productid', idPair, productIds.get(idPair)) throw err } - productIds.add(productId) + productIds.set(idPair, product.name) } } }) diff --git a/packages/node/src/__tests__/recordings.spec.ts b/packages/node/src/__tests__/recordings.spec.ts index 72383c7..98a6c00 100644 --- a/packages/node/src/__tests__/recordings.spec.ts +++ b/packages/node/src/__tests__/recordings.spec.ts @@ -172,6 +172,6 @@ describe('Recorded tests', () => { ) // This number should be decreased as more recordings are added - expect(Object.values(products).length).toBeLessThanOrEqual(8) + expect(Object.values(products).length).toBeLessThanOrEqual(21) }) }) diff --git a/packages/node/src/__tests__/xkeys.spec.ts b/packages/node/src/__tests__/xkeys.spec.ts index ef690f8..ab36b3b 100644 --- a/packages/node/src/__tests__/xkeys.spec.ts +++ b/packages/node/src/__tests__/xkeys.spec.ts @@ -33,7 +33,7 @@ describe('Unit tests', () => { resetSentData() - expect(myXkeysPanel.firmwareVersion).toBe(0) + expect(myXkeysPanel.firmwareVersion).toBe(1) resetSentData() expect(myXkeysPanel.unitId).toBe(0) resetSentData() From e7e3541615e747f7d1c738d841574caaeb293355 Mon Sep 17 00:00:00 2001 From: Michael Hetherington Date: Tue, 21 Jun 2022 16:35:47 -0400 Subject: [PATCH 07/49] Made changes to trackball, fixed bad PIDs, added "extra buttons" for special bit buttons not in norma matrix --- packages/core/src/api.ts | 3 ++ packages/core/src/products.ts | 47 +++++++++++++------ packages/core/src/xkeys.ts | 20 +++++++- .../node/examples/basic-log-all-events.js | 3 ++ 4 files changed, 57 insertions(+), 16 deletions(-) diff --git a/packages/core/src/api.ts b/packages/core/src/api.ts index ad623b6..2dffc9a 100644 --- a/packages/core/src/api.ts +++ b/packages/core/src/api.ts @@ -133,6 +133,9 @@ export interface XKeysInfo { hasTbar: number /** The number of rotary knobs available on the device */ hasRotary: number + /** The number of extra buttons available on the device */ + hasExtraButtons: number + /** If the device has an LCD display */ hasLCD: boolean /** If the device has GPIO support */ diff --git a/packages/core/src/products.ts b/packages/core/src/products.ts index 0373a19..41a7a61 100644 --- a/packages/core/src/products.ts +++ b/packages/core/src/products.ts @@ -51,6 +51,13 @@ export interface Product { trackYbyte_L: number // the index of the low byte of 2 byte Y position trackYbyte_H: number // the index of the high byte of 2 byte Y position }[] + + /** If the X-keys panel has special buttons or digital inputs that do not map to the standand matrix. */ + hasExtraButtons?: { + ebByte: number // the index of the byte to find the extra button + ebBit: number // the index of the bit in that byte + + }[] /** If the X-keys panel has a Trackpad. */ hasTrackpad?: { padXbyte_L: number // the index of the low byte of 2 byte X position @@ -749,11 +756,11 @@ export const PRODUCTS: { [name: string]: Product } = { hidDevices: [ [1365, 0], [1366, 0], - [1327, 0], - [1328, 0], - [1329, 0], - [1330, 0], - [1331, 0], + [1367, 0], + [1368, 0], + [1369, 0], + [1370, 0], + [1371, 0], ], bBytes: 4, // number of button bytes bBits: 6, // number button bits per byte @@ -836,7 +843,7 @@ export const PRODUCTS: { [name: string]: Product } = { }), XBA4X3TRACKBALL: literal({ //new product, expected release Q4 2022 - name: 'X-blox XBA-4x3 Trackball Module', // 12 key module with Trackball & RGB backLight LEDs + name: 'X-blox XBA-4x3 Trackball Module', // 12 key module with Trackball + 2 buttons & RGB backLight LEDs hidDevices: [ [1488, 0], [1489, 0], @@ -847,21 +854,33 @@ export const PRODUCTS: { [name: string]: Product } = { [1494, 0], ], bBytes: 4, // number of button bytes - bBits: 3, // number button bits per byte + bBits: 3, // number button bits per byte, : the 2 extra trackball buttons are on the 4 and 5 bits of byte 4, colCount: 4, // number of physical columns - rowCount: 3, // number of physical rows + rowCount: 3, // number of physical rows, sort of not counting the trackball buttons hasPS: false, hasTrackball: [ { - trackXbyte_L: 6, //Delta X motion, Low byte of 2 byte date, X ball motion = 256*DELTA_X_H + DELTA_X_L. - trackXbyte_H: 7, //Delta X motion, High byte of 2 byte date, X ball motion = 256*DELTA_X_H + DELTA_X_L. - trackYbyte_L: 8, //Delta Y motion, Low byte of 2 byte date, Y ball motion = 256*DELTA_Y_H + DELTA_Y_L. - trackYbyte_H: 9, //Delta Y motion, High byte of 2 byte date, Y ball motion = 256*DELTA_Y_H + DELTA_Y_L. + trackXbyte_L: 7, //Delta X motion, Low byte of 2 byte date, X ball motion = 256*DELTA_X_H + DELTA_X_L. + trackXbyte_H: 8, //Delta X motion, High byte of 2 byte date, X ball motion = 256*DELTA_X_H + DELTA_X_L. + trackYbyte_L: 9, //Delta Y motion, Low byte of 2 byte date, Y ball motion = 256*DELTA_Y_H + DELTA_Y_L. + trackYbyte_H: 10, //Delta Y motion, High byte of 2 byte date, Y ball motion = 256*DELTA_Y_H + DELTA_Y_L. + }, + ], + hasExtraButtons: // this handles extra button like would be beside the track ball. + [ + { + ebByte: 5, // the byte for the extra button + ebBit: 3 // the bit of the extra button + }, + { + ebByte: 5, // the byte for the extra button + ebBit: 4 // the bit of the extra button }, ], backLightType: BackLightType.RGBx2, //RGB 2 Bank, Standard Index backLight2offset: 0, // RGBs have no offset. timestampByte: 31, // index of first of 4 bytes, ms time since device boot, 4 byte BE + }), XBK_QWERTY: literal({ //new product, expected release Q1 2023 @@ -962,7 +981,7 @@ export const PRODUCTS: { [name: string]: Product } = { XCMOTORDRIVER: literal({ //prototype product, name: 'XC-Motor Driver', // Connections for 4 DC Motors or 2 Stepper Motors, 4 Analog to Digital voltages, and 5 GPIOs - hidDevices: [[1364, 0]], + hidDevices: [[1456, 0]], bBytes: 1, bBits: 8, // see documentation colCount: 4, // 2 ports per side of unit , @@ -1113,7 +1132,7 @@ export const PRODUCTS: { [name: string]: Product } = { tbarByte: 11, //Independent Brake }, //{ - // tbarByte: 12, //Bail Off, moving Ind Brake to Right, + // tbarByte: 12, //Bail Off, moving Ind Brake to Right, this is changed to a single bit in the remapping. //}, ], diff --git a/packages/core/src/xkeys.ts b/packages/core/src/xkeys.ts index d500948..491e0b6 100644 --- a/packages/core/src/xkeys.ts +++ b/packages/core/src/xkeys.ts @@ -185,6 +185,18 @@ export class XKeys extends EventEmitter { const bit = d & (1 << 0) ? true : false // get first bit only newButtonStates.set(0, bit) // always keyIndex of PS to 0 } + this.product.hasExtraButtons?.forEach((exButton, index) => { + //const d = data[jog.jogByte] // Jog + //newAnalogStates.jog[index] = d < 128 ? d : d - 256 + + const d = data.readUInt8(exButton.ebByte) + const bit = d & (1 << exButton.ebBit) ? true : false + const startIndex = this.product.bBytes*this.product.bBits + 1 // find the end of the button array + + + newButtonStates.set(startIndex +index, bit) // start the extra buttons after that. + }) + this.product.hasJog?.forEach((jog, index) => { const d = data[jog.jogByte] // Jog newAnalogStates.jog[index] = d < 128 ? d : d - 256 @@ -207,9 +219,12 @@ export class XKeys extends EventEmitter { } }) this.product.hasTrackball?.forEach((trackball, index) => { + const x = 256 * data.readUInt8(trackball.trackXbyte_H) + data.readUInt8(trackball.trackXbyte_L) // Trackball X //Delta X motion, X ball motion = 256*DELTA_X_H + DELTA_X_L. + const y= 256 * data.readUInt8(trackball.trackYbyte_H) + data.readUInt8(trackball.trackYbyte_L) // Trackball Y + newAnalogStates.trackball[index] = { - x: 256 * data.readUInt8(trackball.trackXbyte_H) + data.readUInt8(trackball.trackXbyte_L), // Trackball X //Delta X motion, X ball motion = 256*DELTA_X_H + DELTA_X_L. - y: 256 * data.readUInt8(trackball.trackYbyte_H) + data.readUInt8(trackball.trackYbyte_L), // Trackball Y + x: x < 32768 ? x : x - 65536, // -32768 to 32768// Trackball X //Delta X motion, X ball motion = 256*DELTA_X_H + DELTA_X_L. + y: y < 32768 ? y : y - 65536, // -32768 to 32768// Trackball Y } }) this.product.hasTbar?.forEach((tBar, index) => { @@ -380,6 +395,7 @@ export class XKeys extends EventEmitter { hasPS: this.product.hasPS, hasJoystick: this.product.hasJoystick?.length || 0, hasTrackball: this.product.hasTrackball?.length || 0, + hasExtraButtons: this.product.hasExtraButtons?.length || 0, hasJog: this.product.hasJog?.length || 0, hasShuttle: this.product.hasShuttle?.length || 0, hasTbar: this.product.hasTbar?.length || 0, diff --git a/packages/node/examples/basic-log-all-events.js b/packages/node/examples/basic-log-all-events.js index aad0f2e..26d0dd2 100644 --- a/packages/node/examples/basic-log-all-events.js +++ b/packages/node/examples/basic-log-all-events.js @@ -60,6 +60,9 @@ watcher.on('connected', (xkeysPanel) => { xkeysPanel.on('rotary', (index, position, metadata) => { console.log(`Rotary ${index} position has changed`, position, metadata) }) + xkeysPanel.on('trackball', (index, position, metadata) => { + console.log(`trackball ${index} position has changed`, position, metadata) // {x, y} + }) }) // To stop watching, call From 73bdb56825aba9c15fbc4679a7662a9ddea1f3d5 Mon Sep 17 00:00:00 2001 From: Johan Nyman Date: Wed, 22 Jun 2022 07:48:24 +0200 Subject: [PATCH 08/49] chore: formatting --- packages/core/src/products.ts | 16 +++++++--------- packages/core/src/xkeys.ts | 13 ++++++------- 2 files changed, 13 insertions(+), 16 deletions(-) diff --git a/packages/core/src/products.ts b/packages/core/src/products.ts index 41a7a61..4176551 100644 --- a/packages/core/src/products.ts +++ b/packages/core/src/products.ts @@ -56,7 +56,6 @@ export interface Product { hasExtraButtons?: { ebByte: number // the index of the byte to find the extra button ebBit: number // the index of the bit in that byte - }[] /** If the X-keys panel has a Trackpad. */ hasTrackpad?: { @@ -854,9 +853,9 @@ export const PRODUCTS: { [name: string]: Product } = { [1494, 0], ], bBytes: 4, // number of button bytes - bBits: 3, // number button bits per byte, : the 2 extra trackball buttons are on the 4 and 5 bits of byte 4, + bBits: 3, // number button bits per byte, : the 2 extra trackball buttons are on the 4 and 5 bits of byte 4, colCount: 4, // number of physical columns - rowCount: 3, // number of physical rows, sort of not counting the trackball buttons + rowCount: 3, // number of physical rows, sort of not counting the trackball buttons hasPS: false, hasTrackball: [ { @@ -866,21 +865,20 @@ export const PRODUCTS: { [name: string]: Product } = { trackYbyte_H: 10, //Delta Y motion, High byte of 2 byte date, Y ball motion = 256*DELTA_Y_H + DELTA_Y_L. }, ], - hasExtraButtons: // this handles extra button like would be beside the track ball. - [ + // this handles extra button like would be beside the track ball. + hasExtraButtons: [ { ebByte: 5, // the byte for the extra button - ebBit: 3 // the bit of the extra button + ebBit: 3, // the bit of the extra button }, { ebByte: 5, // the byte for the extra button - ebBit: 4 // the bit of the extra button + ebBit: 4, // the bit of the extra button }, ], backLightType: BackLightType.RGBx2, //RGB 2 Bank, Standard Index backLight2offset: 0, // RGBs have no offset. timestampByte: 31, // index of first of 4 bytes, ms time since device boot, 4 byte BE - }), XBK_QWERTY: literal({ //new product, expected release Q1 2023 @@ -1132,7 +1130,7 @@ export const PRODUCTS: { [name: string]: Product } = { tbarByte: 11, //Independent Brake }, //{ - // tbarByte: 12, //Bail Off, moving Ind Brake to Right, this is changed to a single bit in the remapping. + // tbarByte: 12, //Bail Off, moving Ind Brake to Right, this is changed to a single bit in the remapping. //}, ], diff --git a/packages/core/src/xkeys.ts b/packages/core/src/xkeys.ts index 491e0b6..eaa31e6 100644 --- a/packages/core/src/xkeys.ts +++ b/packages/core/src/xkeys.ts @@ -191,12 +191,11 @@ export class XKeys extends EventEmitter { const d = data.readUInt8(exButton.ebByte) const bit = d & (1 << exButton.ebBit) ? true : false - const startIndex = this.product.bBytes*this.product.bBits + 1 // find the end of the button array + const startIndex = this.product.bBytes * this.product.bBits + 1 // find the end of the button array - - newButtonStates.set(startIndex +index, bit) // start the extra buttons after that. + newButtonStates.set(startIndex + index, bit) // start the extra buttons after that. }) - + this.product.hasJog?.forEach((jog, index) => { const d = data[jog.jogByte] // Jog newAnalogStates.jog[index] = d < 128 ? d : d - 256 @@ -220,11 +219,11 @@ export class XKeys extends EventEmitter { }) this.product.hasTrackball?.forEach((trackball, index) => { const x = 256 * data.readUInt8(trackball.trackXbyte_H) + data.readUInt8(trackball.trackXbyte_L) // Trackball X //Delta X motion, X ball motion = 256*DELTA_X_H + DELTA_X_L. - const y= 256 * data.readUInt8(trackball.trackYbyte_H) + data.readUInt8(trackball.trackYbyte_L) // Trackball Y + const y = 256 * data.readUInt8(trackball.trackYbyte_H) + data.readUInt8(trackball.trackYbyte_L) // Trackball Y newAnalogStates.trackball[index] = { - x: x < 32768 ? x : x - 65536, // -32768 to 32768// Trackball X //Delta X motion, X ball motion = 256*DELTA_X_H + DELTA_X_L. - y: y < 32768 ? y : y - 65536, // -32768 to 32768// Trackball Y + x: x < 32768 ? x : x - 65536, // -32768 to 32768// Trackball X //Delta X motion, X ball motion = 256*DELTA_X_H + DELTA_X_L. + y: y < 32768 ? y : y - 65536, // -32768 to 32768// Trackball Y } }) this.product.hasTbar?.forEach((tBar, index) => { From a0581126c9eaba2c6d1c653dc0ef41e605a32b03 Mon Sep 17 00:00:00 2001 From: Johan Nyman Date: Wed, 22 Jun 2022 07:52:59 +0200 Subject: [PATCH 09/49] chore: fix test --- packages/node/src/__tests__/__snapshots__/xkeys.spec.ts.snap | 1 + 1 file changed, 1 insertion(+) diff --git a/packages/node/src/__tests__/__snapshots__/xkeys.spec.ts.snap b/packages/node/src/__tests__/__snapshots__/xkeys.spec.ts.snap index d10c810..d2ba82d 100644 --- a/packages/node/src/__tests__/__snapshots__/xkeys.spec.ts.snap +++ b/packages/node/src/__tests__/__snapshots__/xkeys.spec.ts.snap @@ -6,6 +6,7 @@ Object { "emitsTimestamp": true, "firmwareVersion": 1, "hasDMX": false, + "hasExtraButtons": 0, "hasGPIO": false, "hasJog": 0, "hasJoystick": 0, From f6fd350f1e5cdf007bf23b354ba2c2a3cbf6c8c4 Mon Sep 17 00:00:00 2001 From: Johan Nyman Date: Wed, 22 Jun 2022 07:59:00 +0200 Subject: [PATCH 10/49] feat!: Drop support for Node 10, 12 --- .github/workflows/lint-and-test.yml | 2 +- .github/workflows/publish-prerelease.yml | 2 +- .github/workflows/publish-release.yml | 2 +- packages/core/package.json | 2 +- packages/node-record-test/package.json | 2 +- packages/node/package.json | 2 +- packages/webhid/package.json | 2 +- 7 files changed, 7 insertions(+), 7 deletions(-) diff --git a/.github/workflows/lint-and-test.yml b/.github/workflows/lint-and-test.yml index fc8776c..ba9a204 100644 --- a/.github/workflows/lint-and-test.yml +++ b/.github/workflows/lint-and-test.yml @@ -45,7 +45,7 @@ jobs: runs-on: ${{ matrix.os }} strategy: matrix: - node_version: ['10', '12', '14'] + node_version: ['14', '16', '18'] os: [ubuntu-latest] # [windows-latest, macOS-latest] timeout-minutes: 10 steps: diff --git a/.github/workflows/publish-prerelease.yml b/.github/workflows/publish-prerelease.yml index a26c0ef..1c7a400 100644 --- a/.github/workflows/publish-prerelease.yml +++ b/.github/workflows/publish-prerelease.yml @@ -12,7 +12,7 @@ jobs: runs-on: ${{ matrix.os }} strategy: matrix: - node_version: ['10', '12', '14'] + node_version: ['14', '16', '18'] os: [ubuntu-latest] # [windows-latest, macOS-latest] timeout-minutes: 10 steps: diff --git a/.github/workflows/publish-release.yml b/.github/workflows/publish-release.yml index 0a5809e..ad87530 100644 --- a/.github/workflows/publish-release.yml +++ b/.github/workflows/publish-release.yml @@ -41,7 +41,7 @@ jobs: runs-on: ${{ matrix.os }} strategy: matrix: - node_version: ['10', '12', '14'] + node_version: ['14', '16', '18'] os: [ubuntu-latest] # [windows-latest, macOS-latest] timeout-minutes: 10 steps: diff --git a/packages/core/package.json b/packages/core/package.json index 974e5e2..c3aeb2e 100644 --- a/packages/core/package.json +++ b/packages/core/package.json @@ -37,7 +37,7 @@ }, "prettier": "@sofie-automation/code-standard-preset/.prettierrc.json", "engines": { - "node": ">=10" + "node": ">=14" }, "keywords": [ "xkeys", diff --git a/packages/node-record-test/package.json b/packages/node-record-test/package.json index 7f17e2d..1391641 100644 --- a/packages/node-record-test/package.json +++ b/packages/node-record-test/package.json @@ -38,7 +38,7 @@ "dist" ], "engines": { - "node": ">=10" + "node": ">=14" }, "dependencies": { "@xkeys-lib/core": "2.3.4", diff --git a/packages/node/package.json b/packages/node/package.json index c7ae5da..e94159b 100644 --- a/packages/node/package.json +++ b/packages/node/package.json @@ -37,7 +37,7 @@ "dist" ], "engines": { - "node": ">=10" + "node": ">=14" }, "dependencies": { "@types/node-hid": "^1.3.1", diff --git a/packages/webhid/package.json b/packages/webhid/package.json index ac10c66..a5ea184 100644 --- a/packages/webhid/package.json +++ b/packages/webhid/package.json @@ -42,6 +42,6 @@ "p-queue": "^6.6.2" }, "engines": { - "node": ">=10.10" + "node": ">=14" } } From 85ae15de2604d3da702ef3ca6eaf25a608bd5d6e Mon Sep 17 00:00:00 2001 From: Johan Nyman Date: Wed, 22 Jun 2022 08:08:33 +0200 Subject: [PATCH 11/49] chore: remove Node 18 from CI unit tests Due to an issue with installing usb-detection --- .github/workflows/lint-and-test.yml | 2 +- .github/workflows/publish-prerelease.yml | 2 +- .github/workflows/publish-release.yml | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/lint-and-test.yml b/.github/workflows/lint-and-test.yml index ba9a204..8c9d88c 100644 --- a/.github/workflows/lint-and-test.yml +++ b/.github/workflows/lint-and-test.yml @@ -45,7 +45,7 @@ jobs: runs-on: ${{ matrix.os }} strategy: matrix: - node_version: ['14', '16', '18'] + node_version: ['14', '16'] os: [ubuntu-latest] # [windows-latest, macOS-latest] timeout-minutes: 10 steps: diff --git a/.github/workflows/publish-prerelease.yml b/.github/workflows/publish-prerelease.yml index 1c7a400..9bc19d4 100644 --- a/.github/workflows/publish-prerelease.yml +++ b/.github/workflows/publish-prerelease.yml @@ -12,7 +12,7 @@ jobs: runs-on: ${{ matrix.os }} strategy: matrix: - node_version: ['14', '16', '18'] + node_version: ['14', '16'] os: [ubuntu-latest] # [windows-latest, macOS-latest] timeout-minutes: 10 steps: diff --git a/.github/workflows/publish-release.yml b/.github/workflows/publish-release.yml index ad87530..1a2afaa 100644 --- a/.github/workflows/publish-release.yml +++ b/.github/workflows/publish-release.yml @@ -41,7 +41,7 @@ jobs: runs-on: ${{ matrix.os }} strategy: matrix: - node_version: ['14', '16', '18'] + node_version: ['14', '16'] os: [ubuntu-latest] # [windows-latest, macOS-latest] timeout-minutes: 10 steps: From aa39c26f9abd5e83216a1ef132aaf219761ba625 Mon Sep 17 00:00:00 2001 From: Johan Nyman Date: Wed, 22 Jun 2022 08:13:13 +0200 Subject: [PATCH 12/49] v3.0.0-alpha.0 --- CHANGELOG.md | 157 ++++++++----------------- lerna.json | 2 +- packages/core/CHANGELOG.md | 62 ++-------- packages/core/package.json | 2 +- packages/node-record-test/CHANGELOG.md | 55 +-------- packages/node-record-test/package.json | 6 +- packages/node/CHANGELOG.md | 77 ++---------- packages/node/package.json | 4 +- packages/webhid-demo/CHANGELOG.md | 49 +------- packages/webhid-demo/package.json | 4 +- packages/webhid/CHANGELOG.md | 52 +------- packages/webhid/package.json | 4 +- 12 files changed, 99 insertions(+), 375 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index ef8512e..737be52 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -3,187 +3,132 @@ All notable changes to this project will be documented in this file. See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. -## [2.3.4](https://github.com/SuperFlyTV/xkeys/compare/v2.3.3...v2.3.4) (2022-06-06) - +# [3.0.0-alpha.0](https://github.com/SuperFlyTV/xkeys/compare/v2.3.4...v3.0.0-alpha.0) (2022-06-22) -### Bug Fixes - -* ignore engines for node10 in ci ([8c88b43](https://github.com/SuperFlyTV/xkeys/commit/8c88b43f9d694ac82d094b82042c82bde25e5bd1)) -* pre-commit hook ([887fbb2](https://github.com/SuperFlyTV/xkeys/commit/887fbb2f9b89369dfaa0ccf851646252af9686af)) -* Watcher: async handling of adding/removing devices ([61f0b28](https://github.com/SuperFlyTV/xkeys/commit/61f0b28571a3df72b49f4bd84b6d842408e86acd)) +### Features +- BREAKING CHANGE: Dropped support for EOL versions of Node.js (<14). +- Add support for the [RailDriver](https://raildriver.com/). +- Add support for panels with multiple background-light banks (added an argument for bankIndex to `.setBacklight()` & `.setAllBacklights()`) +- Add support for a few upcoming X-keys panels, including features like trackball, rotary +## [2.3.4](https://github.com/SuperFlyTV/xkeys/compare/v2.3.3...v2.3.4) (2022-06-06) +### Bug Fixes +- ignore engines for node10 in ci ([8c88b43](https://github.com/SuperFlyTV/xkeys/commit/8c88b43f9d694ac82d094b82042c82bde25e5bd1)) +- pre-commit hook ([887fbb2](https://github.com/SuperFlyTV/xkeys/commit/887fbb2f9b89369dfaa0ccf851646252af9686af)) +- Watcher: async handling of adding/removing devices ([61f0b28](https://github.com/SuperFlyTV/xkeys/commit/61f0b28571a3df72b49f4bd84b6d842408e86acd)) ## [2.3.2](https://github.com/SuperFlyTV/xkeys/compare/v2.3.0...v2.3.2) (2021-12-12) - ### Bug Fixes -* add XKeys.writeData() method, used for testing and development ([fba879c](https://github.com/SuperFlyTV/xkeys/commit/fba879c0f93ee64fbcdbd7faf5863998300c2016)) - - - - +- add XKeys.writeData() method, used for testing and development ([fba879c](https://github.com/SuperFlyTV/xkeys/commit/fba879c0f93ee64fbcdbd7faf5863998300c2016)) # [2.3.0](https://github.com/SuperFlyTV/xkeys/compare/v2.2.1...v2.3.0) (2021-11-28) - ### Features -* add usePolling option to the XKeysWatcher to fall back to polling, since "usb-detection" might not work on all OS:es ([ab31223](https://github.com/SuperFlyTV/xkeys/commit/ab312236b14cb8f961d0b0bf878c611487a5983f)) - - - - +- add usePolling option to the XKeysWatcher to fall back to polling, since "usb-detection" might not work on all OS:es ([ab31223](https://github.com/SuperFlyTV/xkeys/commit/ab312236b14cb8f961d0b0bf878c611487a5983f)) ## [2.2.1](https://github.com/SuperFlyTV/xkeys/compare/v2.2.0...v2.2.1) (2021-09-22) **Note:** Version bump only for package xkeys-monorepo - - - - # [2.2.0](https://github.com/SuperFlyTV/xkeys/compare/v2.2.0-alpha.1...v2.2.0) (2021-09-08) **Note:** Version bump only for package xkeys-monorepo - - - - # [2.2.0-alpha.1](https://github.com/SuperFlyTV/xkeys/compare/v2.2.0-alpha.0...v2.2.0-alpha.1) (2021-09-06) - ### Bug Fixes -* re-add devicePath ([349f6a9](https://github.com/SuperFlyTV/xkeys/commit/349f6a93ace9480e18d5ed695186920165fea6e7)) - - - - +- re-add devicePath ([349f6a9](https://github.com/SuperFlyTV/xkeys/commit/349f6a93ace9480e18d5ed695186920165fea6e7)) # [2.2.0-alpha.0](https://github.com/SuperFlyTV/xkeys/compare/v2.1.1...v2.2.0-alpha.0) (2021-09-06) - ### Features -* add feature: "Automatic UnitId mode" ([f7c3a86](https://github.com/SuperFlyTV/xkeys/commit/f7c3a869e8820f856831aad576ce7978dfb9d75c)) -* add XKeys.uniqueId property, to be used with automaticUnitIdMode ([a2e6d7a](https://github.com/SuperFlyTV/xkeys/commit/a2e6d7a6ec917d82bc2a71c1922c22c061232908)) - - - - +- add feature: "Automatic UnitId mode" ([f7c3a86](https://github.com/SuperFlyTV/xkeys/commit/f7c3a869e8820f856831aad576ce7978dfb9d75c)) +- add XKeys.uniqueId property, to be used with automaticUnitIdMode ([a2e6d7a](https://github.com/SuperFlyTV/xkeys/commit/a2e6d7a6ec917d82bc2a71c1922c22c061232908)) ## [2.1.1](https://github.com/SuperFlyTV/xkeys/compare/v2.1.1-alpha.1...v2.1.1) (2021-05-24) **Note:** Version bump only for package xkeys-monorepo - - - - ## [2.1.1-alpha.1](https://github.com/SuperFlyTV/xkeys/compare/v2.1.1-alpha.0...v2.1.1-alpha.1) (2021-05-23) - ### Bug Fixes -* hack to fix issue in Electron ([501f06d](https://github.com/SuperFlyTV/xkeys/commit/501f06de9a2413832dab4b6a0ef4ef7d2b668967)) -* make XKeysWatcher.stop() close all the devices it has called setupXkeysPanel() for. ([f69b599](https://github.com/SuperFlyTV/xkeys/commit/f69b59912a62b8dcc5ff00a2083c793851bba15c)) - - - - +- hack to fix issue in Electron ([501f06d](https://github.com/SuperFlyTV/xkeys/commit/501f06de9a2413832dab4b6a0ef4ef7d2b668967)) +- make XKeysWatcher.stop() close all the devices it has called setupXkeysPanel() for. ([f69b599](https://github.com/SuperFlyTV/xkeys/commit/f69b59912a62b8dcc5ff00a2083c793851bba15c)) ## [2.1.1-alpha.0](https://github.com/SuperFlyTV/xkeys/compare/v2.1.0...v2.1.1-alpha.0) (2021-05-23) - ### Bug Fixes -* remove listeners on watcher.stop() ([c8d36a3](https://github.com/SuperFlyTV/xkeys/commit/c8d36a3602b8c460233b82a48f6c28a04f52c9de)) - - - - +- remove listeners on watcher.stop() ([c8d36a3](https://github.com/SuperFlyTV/xkeys/commit/c8d36a3602b8c460233b82a48f6c28a04f52c9de)) # [2.1.0](https://github.com/SuperFlyTV/xkeys/compare/v2.1.0-alpha.0...v2.1.0) (2021-05-15) **Note:** Version bump only for package xkeys-monorepo - - - - # [2.1.0-alpha.1](https://github.com/SuperFlyTV/xkeys/compare/v2.1.0-alpha.0...v2.1.0-alpha.1) (2021-05-10) **Note:** Version bump only for package xkeys-monorepo +# [2.1.0-alpha.0](https://github.com/SuperFlyTV/xkeys/compare/v2.0.0...v2.1.0-alpha.0) (2021-05-10) +### Bug Fixes +- publication-script for the node-record-test executable (wip) ([e4a8071](https://github.com/SuperFlyTV/xkeys/commit/e4a80719686048b010976d464adb6a40bf86b3c0)) +- refactor repo into lerna mono-repo ([d5bffc1](https://github.com/SuperFlyTV/xkeys/commit/d5bffc1798e7c8e89ae9fcc4355afd438ea82d3a)) +### Features -# [2.1.0-alpha.0](https://github.com/SuperFlyTV/xkeys/compare/v2.0.0...v2.1.0-alpha.0) (2021-05-10) - +- add package with web-HID support ([1f27199](https://github.com/SuperFlyTV/xkeys/commit/1f2719969faf93ba45a2bc767f64543fb9ffe6ea)) -### Bug Fixes +# Changelog -* publication-script for the node-record-test executable (wip) ([e4a8071](https://github.com/SuperFlyTV/xkeys/commit/e4a80719686048b010976d464adb6a40bf86b3c0)) -* refactor repo into lerna mono-repo ([d5bffc1](https://github.com/SuperFlyTV/xkeys/commit/d5bffc1798e7c8e89ae9fcc4355afd438ea82d3a)) +All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines. +## [2.0.0](https://github.com/SuperFlyTV/xkeys/compare/v1.1.1...v2.0.0) (2021-04-16) ### Features -* add package with web-HID support ([1f27199](https://github.com/SuperFlyTV/xkeys/commit/1f2719969faf93ba45a2bc767f64543fb9ffe6ea)) - - +- emit precalculated deltaZ for joystick ([2dad07b](https://github.com/SuperFlyTV/xkeys/commit/2dad07b895ba1c284a708a017eb6e7008e2e15a9)) +- Refactor & improve ([0ce375e](https://github.com/SuperFlyTV/xkeys/commit/0ce375ef4f16ccdfa05623f4382084fecbe4162d)) +### Bug Fixes +- bug for joystick deltaZ ([41cd561](https://github.com/SuperFlyTV/xkeys/commit/41cd5618e48f8b07c9bcbe9a5760c02e3cadb529)) +- compare new values with old, not the other way around ([71e1801](https://github.com/SuperFlyTV/xkeys/commit/71e1801e2fbf5a8c3e9e1f71cc839ada72eb796c)) +- joystick bug ([84d2150](https://github.com/SuperFlyTV/xkeys/commit/84d21503ff670f1e4b6d1f021d1b98b1c661fc55)) +- the emitted timestamp is undefined for some products ([a45ee1f](https://github.com/SuperFlyTV/xkeys/commit/a45ee1fd7982d40ef9b3f97f0ffa6c2a7d928d71)) +- use type imports ([373e6b4](https://github.com/SuperFlyTV/xkeys/commit/373e6b40144e9d51ec064cb50deb315a50f24868)) +- use XKeys.listAllConnectedPanels to DRY it up ([d49827d](https://github.com/SuperFlyTV/xkeys/commit/d49827d093474eeebd9d294c4f7c391c54c5daec)) -# Changelog +### [1.1.1](https://github.com/SuperFlyTV/xkeys/compare/v1.1.0...v1.1.1) (2021-01-15) -All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines. +### Bug Fixes -## [2.0.0](https://github.com/SuperFlyTV/xkeys/compare/v1.1.1...v2.0.0) (2021-04-16) +- remove spammy console.log [release] ([e3a0feb](https://github.com/SuperFlyTV/xkeys/commit/e3a0feb0b48686adc1eb2b431a140c25c721c906)) +## [1.1.0](https://github.com/SuperFlyTV/xkeys/compare/v1.0.0...v1.1.0) (2021-01-06) -### Features +### [1.1.0-0](https://github.com/SuperFlyTV/xkeys/compare/v1.0.0...v1.0.1-0) (2021-01-06) -* emit precalculated deltaZ for joystick ([2dad07b](https://github.com/SuperFlyTV/xkeys/commit/2dad07b895ba1c284a708a017eb6e7008e2e15a9)) -* Refactor & improve ([0ce375e](https://github.com/SuperFlyTV/xkeys/commit/0ce375ef4f16ccdfa05623f4382084fecbe4162d)) +- Add support for XKE-124 T-bar ([PR](https://github.com/SuperFlyTV/xkeys/pull/23)) +## [1.0.0](https://github.com/SuperFlyTV/xkeys/compare/v0.1.1...v1.0.0) (2020-10-27) ### Bug Fixes -* bug for joystick deltaZ ([41cd561](https://github.com/SuperFlyTV/xkeys/commit/41cd5618e48f8b07c9bcbe9a5760c02e3cadb529)) -* compare new values with old, not the other way around ([71e1801](https://github.com/SuperFlyTV/xkeys/commit/71e1801e2fbf5a8c3e9e1f71cc839ada72eb796c)) -* joystick bug ([84d2150](https://github.com/SuperFlyTV/xkeys/commit/84d21503ff670f1e4b6d1f021d1b98b1c661fc55)) -* the emitted timestamp is undefined for some products ([a45ee1f](https://github.com/SuperFlyTV/xkeys/commit/a45ee1fd7982d40ef9b3f97f0ffa6c2a7d928d71)) -* use type imports ([373e6b4](https://github.com/SuperFlyTV/xkeys/commit/373e6b40144e9d51ec064cb50deb315a50f24868)) -* use XKeys.listAllConnectedPanels to DRY it up ([d49827d](https://github.com/SuperFlyTV/xkeys/commit/d49827d093474eeebd9d294c4f7c391c54c5daec)) - -### [1.1.1](https://github.com/SuperFlyTV/xkeys/compare/v1.1.0...v1.1.1) (2021-01-15) - - -### Bug Fixes - -* remove spammy console.log [release] ([e3a0feb](https://github.com/SuperFlyTV/xkeys/commit/e3a0feb0b48686adc1eb2b431a140c25c721c906)) - -## [1.1.0](https://github.com/SuperFlyTV/xkeys/compare/v1.0.0...v1.1.0) (2021-01-06) - -### [1.1.0-0](https://github.com/SuperFlyTV/xkeys/compare/v1.0.0...v1.0.1-0) (2021-01-06) -* Add support for XKE-124 T-bar ([PR](https://github.com/SuperFlyTV/xkeys/pull/23)) - -## [1.0.0](https://github.com/SuperFlyTV/xkeys/compare/v0.1.1...v1.0.0) (2020-10-27) - - -### Bug Fixes - -* add (guessed) banks for XK16, XK8 & XK4 ([a47834b](https://github.com/SuperFlyTV/xkeys/commit/a47834be031d29033dd04f5978dd7156c473a282)) -* add best-guesses for banks property, for untested products ([8ecffec](https://github.com/SuperFlyTV/xkeys/commit/8ecffeca442b1b5b06fe683b30a4d05e55fb010f)) -* setBacklightIntensity improvements (thanks to [@jonwyett](https://github.com/jonwyett)) ([a75d330](https://github.com/SuperFlyTV/xkeys/commit/a75d330f2161cf8b9d191feec2985ff14a36689d)) -* typings fixes ([a8a7193](https://github.com/SuperFlyTV/xkeys/commit/a8a7193ba44bc691676161dcb3955d7184c1dbae)) -* updated node-hid dependencies ([0ec22e1](https://github.com/SuperFlyTV/xkeys/commit/0ec22e10e9f471ed6a9555847a7f37a645e75228)) -* upgrade dependencies ([98bb387](https://github.com/SuperFlyTV/xkeys/commit/98bb3878ece0f4e5032d31200ba641b881e40006)) -* use device.interface instead of device.usage ([2883c46](https://github.com/SuperFlyTV/xkeys/commit/2883c466f2ea26585a14b6e9765fa4146ba17554)) +- add (guessed) banks for XK16, XK8 & XK4 ([a47834b](https://github.com/SuperFlyTV/xkeys/commit/a47834be031d29033dd04f5978dd7156c473a282)) +- add best-guesses for banks property, for untested products ([8ecffec](https://github.com/SuperFlyTV/xkeys/commit/8ecffeca442b1b5b06fe683b30a4d05e55fb010f)) +- setBacklightIntensity improvements (thanks to [@jonwyett](https://github.com/jonwyett)) ([a75d330](https://github.com/SuperFlyTV/xkeys/commit/a75d330f2161cf8b9d191feec2985ff14a36689d)) +- typings fixes ([a8a7193](https://github.com/SuperFlyTV/xkeys/commit/a8a7193ba44bc691676161dcb3955d7184c1dbae)) +- updated node-hid dependencies ([0ec22e1](https://github.com/SuperFlyTV/xkeys/commit/0ec22e10e9f471ed6a9555847a7f37a645e75228)) +- upgrade dependencies ([98bb387](https://github.com/SuperFlyTV/xkeys/commit/98bb3878ece0f4e5032d31200ba641b881e40006)) +- use device.interface instead of device.usage ([2883c46](https://github.com/SuperFlyTV/xkeys/commit/2883c466f2ea26585a14b6e9765fa4146ba17554)) diff --git a/lerna.json b/lerna.json index 3f66046..cf98193 100644 --- a/lerna.json +++ b/lerna.json @@ -4,5 +4,5 @@ ], "npmClient": "yarn", "useWorkspaces": true, - "version": "2.3.4" + "version": "3.0.0-alpha.0" } diff --git a/packages/core/CHANGELOG.md b/packages/core/CHANGELOG.md index 523f126..6f5537c 100644 --- a/packages/core/CHANGELOG.md +++ b/packages/core/CHANGELOG.md @@ -3,107 +3,65 @@ All notable changes to this project will be documented in this file. See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. -## [2.3.4](https://github.com/SuperFlyTV/xkeys/compare/v2.3.3...v2.3.4) (2022-06-06) - -**Note:** Version bump only for package @xkeys-lib/core +## [3.0.0-alpha.0](https://github.com/SuperFlyTV/xkeys/compare/v2.3.4...v3.0.0-alpha.0) (2022-06-22) +### Bug Fixes +- issue with trackball ([5e2021a](https://github.com/SuperFlyTV/xkeys/commit/5e2021af49d12a7367d39f638c375210db343714)) +## [2.3.4](https://github.com/SuperFlyTV/xkeys/compare/v2.3.3...v2.3.4) (2022-06-06) +**Note:** Version bump only for package @xkeys-lib/core ## [2.3.2](https://github.com/SuperFlyTV/xkeys/compare/v2.3.0...v2.3.2) (2021-12-12) - ### Bug Fixes -* add XKeys.writeData() method, used for testing and development ([fba879c](https://github.com/SuperFlyTV/xkeys/commit/fba879c0f93ee64fbcdbd7faf5863998300c2016)) - - - - +- add XKeys.writeData() method, used for testing and development ([fba879c](https://github.com/SuperFlyTV/xkeys/commit/fba879c0f93ee64fbcdbd7faf5863998300c2016)) # [2.3.0](https://github.com/SuperFlyTV/xkeys/compare/v2.2.1...v2.3.0) (2021-11-28) **Note:** Version bump only for package @xkeys-lib/core - - - - ## [2.2.1](https://github.com/SuperFlyTV/xkeys/compare/v2.2.0...v2.2.1) (2021-09-22) **Note:** Version bump only for package @xkeys-lib/core - - - - # [2.2.0](https://github.com/SuperFlyTV/xkeys/compare/v2.2.0-alpha.1...v2.2.0) (2021-09-08) **Note:** Version bump only for package @xkeys-lib/core - - - - # [2.2.0-alpha.1](https://github.com/SuperFlyTV/xkeys/compare/v2.2.0-alpha.0...v2.2.0-alpha.1) (2021-09-06) - ### Bug Fixes -* re-add devicePath ([349f6a9](https://github.com/SuperFlyTV/xkeys/commit/349f6a93ace9480e18d5ed695186920165fea6e7)) - - - - +- re-add devicePath ([349f6a9](https://github.com/SuperFlyTV/xkeys/commit/349f6a93ace9480e18d5ed695186920165fea6e7)) # [2.2.0-alpha.0](https://github.com/SuperFlyTV/xkeys/compare/v2.1.1...v2.2.0-alpha.0) (2021-09-06) - ### Features -* add feature: "Automatic UnitId mode" ([f7c3a86](https://github.com/SuperFlyTV/xkeys/commit/f7c3a869e8820f856831aad576ce7978dfb9d75c)) -* add XKeys.uniqueId property, to be used with automaticUnitIdMode ([a2e6d7a](https://github.com/SuperFlyTV/xkeys/commit/a2e6d7a6ec917d82bc2a71c1922c22c061232908)) - - - - +- add feature: "Automatic UnitId mode" ([f7c3a86](https://github.com/SuperFlyTV/xkeys/commit/f7c3a869e8820f856831aad576ce7978dfb9d75c)) +- add XKeys.uniqueId property, to be used with automaticUnitIdMode ([a2e6d7a](https://github.com/SuperFlyTV/xkeys/commit/a2e6d7a6ec917d82bc2a71c1922c22c061232908)) ## [2.1.1](https://github.com/SuperFlyTV/xkeys/compare/v2.1.1-alpha.1...v2.1.1) (2021-05-24) **Note:** Version bump only for package @xkeys-lib/core - - - - ## [2.1.1-alpha.0](https://github.com/SuperFlyTV/xkeys/compare/v2.1.0...v2.1.1-alpha.0) (2021-05-23) **Note:** Version bump only for package @xkeys-lib/core - - - - # [2.1.0](https://github.com/SuperFlyTV/xkeys/compare/v2.1.0-alpha.0...v2.1.0) (2021-05-15) **Note:** Version bump only for package @xkeys-lib/core - - - - # [2.1.0-alpha.1](https://github.com/SuperFlyTV/xkeys/compare/v2.1.0-alpha.0...v2.1.0-alpha.1) (2021-05-10) **Note:** Version bump only for package @xkeys-lib/core - - - - # [2.1.0-alpha.0](https://github.com/SuperFlyTV/xkeys/compare/v2.0.0...v2.1.0-alpha.0) (2021-05-10) - ### Bug Fixes -* refactor repo into lerna mono-repo ([d5bffc1](https://github.com/SuperFlyTV/xkeys/commit/d5bffc1798e7c8e89ae9fcc4355afd438ea82d3a)) +- refactor repo into lerna mono-repo ([d5bffc1](https://github.com/SuperFlyTV/xkeys/commit/d5bffc1798e7c8e89ae9fcc4355afd438ea82d3a)) diff --git a/packages/core/package.json b/packages/core/package.json index c3aeb2e..8cbfa56 100644 --- a/packages/core/package.json +++ b/packages/core/package.json @@ -1,6 +1,6 @@ { "name": "@xkeys-lib/core", - "version": "2.3.4", + "version": "3.0.0-alpha.0", "description": "NPM package to interact with the X-keys panels", "main": "dist/index.js", "typings": "dist/index.d.ts", diff --git a/packages/node-record-test/CHANGELOG.md b/packages/node-record-test/CHANGELOG.md index ee4c515..99e8592 100644 --- a/packages/node-record-test/CHANGELOG.md +++ b/packages/node-record-test/CHANGELOG.md @@ -3,106 +3,61 @@ All notable changes to this project will be documented in this file. See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. -## [2.3.4](https://github.com/SuperFlyTV/xkeys/compare/v2.3.3...v2.3.4) (2022-06-06) +## [3.0.0-alpha.0](https://github.com/SuperFlyTV/xkeys/compare/v2.3.4...v3.0.0-alpha.0) (2022-06-22) **Note:** Version bump only for package @xkeys-lib/record-test +## [2.3.4](https://github.com/SuperFlyTV/xkeys/compare/v2.3.3...v2.3.4) (2022-06-06) - - +**Note:** Version bump only for package @xkeys-lib/record-test ## [2.3.2](https://github.com/SuperFlyTV/xkeys/compare/v2.3.0...v2.3.2) (2021-12-12) **Note:** Version bump only for package @xkeys-lib/record-test - - - - # [2.3.0](https://github.com/SuperFlyTV/xkeys/compare/v2.2.1...v2.3.0) (2021-11-28) **Note:** Version bump only for package @xkeys-lib/record-test - - - - ## [2.2.1](https://github.com/SuperFlyTV/xkeys/compare/v2.2.0...v2.2.1) (2021-09-22) **Note:** Version bump only for package @xkeys-lib/record-test - - - - # [2.2.0](https://github.com/SuperFlyTV/xkeys/compare/v2.2.0-alpha.1...v2.2.0) (2021-09-08) **Note:** Version bump only for package @xkeys-lib/record-test - - - - # [2.2.0-alpha.1](https://github.com/SuperFlyTV/xkeys/compare/v2.2.0-alpha.0...v2.2.0-alpha.1) (2021-09-06) **Note:** Version bump only for package @xkeys-lib/record-test - - - - # [2.2.0-alpha.0](https://github.com/SuperFlyTV/xkeys/compare/v2.1.1...v2.2.0-alpha.0) (2021-09-06) **Note:** Version bump only for package @xkeys-lib/record-test - - - - ## [2.1.1](https://github.com/SuperFlyTV/xkeys/compare/v2.1.1-alpha.1...v2.1.1) (2021-05-24) **Note:** Version bump only for package @xkeys-lib/record-test - - - - ## [2.1.1-alpha.1](https://github.com/SuperFlyTV/xkeys/compare/v2.1.1-alpha.0...v2.1.1-alpha.1) (2021-05-23) **Note:** Version bump only for package @xkeys-lib/record-test - - - - ## [2.1.1-alpha.0](https://github.com/SuperFlyTV/xkeys/compare/v2.1.0...v2.1.1-alpha.0) (2021-05-23) **Note:** Version bump only for package @xkeys-lib/record-test - - - - # [2.1.0](https://github.com/SuperFlyTV/xkeys/compare/v2.1.0-alpha.0...v2.1.0) (2021-05-15) **Note:** Version bump only for package @xkeys-lib/record-test - - - - # [2.1.0-alpha.1](https://github.com/SuperFlyTV/xkeys/compare/v2.1.0-alpha.0...v2.1.0-alpha.1) (2021-05-10) **Note:** Version bump only for package @xkeys-lib/record-test - - - - # [2.1.0-alpha.0](https://github.com/SuperFlyTV/xkeys/compare/v2.0.0...v2.1.0-alpha.0) (2021-05-10) - ### Bug Fixes -* publication-script for the node-record-test executable (wip) ([e4a8071](https://github.com/SuperFlyTV/xkeys/commit/e4a80719686048b010976d464adb6a40bf86b3c0)) -* refactor repo into lerna mono-repo ([d5bffc1](https://github.com/SuperFlyTV/xkeys/commit/d5bffc1798e7c8e89ae9fcc4355afd438ea82d3a)) +- publication-script for the node-record-test executable (wip) ([e4a8071](https://github.com/SuperFlyTV/xkeys/commit/e4a80719686048b010976d464adb6a40bf86b3c0)) +- refactor repo into lerna mono-repo ([d5bffc1](https://github.com/SuperFlyTV/xkeys/commit/d5bffc1798e7c8e89ae9fcc4355afd438ea82d3a)) diff --git a/packages/node-record-test/package.json b/packages/node-record-test/package.json index 1391641..6c39d50 100644 --- a/packages/node-record-test/package.json +++ b/packages/node-record-test/package.json @@ -1,6 +1,6 @@ { "name": "@xkeys-lib/record-test", - "version": "2.3.4", + "version": "3.0.0-alpha.0", "private": true, "description": "A script for recording tests", "main": "dist/index.js", @@ -41,10 +41,10 @@ "node": ">=14" }, "dependencies": { - "@xkeys-lib/core": "2.3.4", + "@xkeys-lib/core": "3.0.0-alpha.0", "readline": "^1.3.0", "tslib": "^2.3.1", - "xkeys": "2.3.4" + "xkeys": "3.0.0-alpha.0" }, "optionalDependencies": { "find": "^0.3.0", diff --git a/packages/node/CHANGELOG.md b/packages/node/CHANGELOG.md index 2bc8b98..6747438 100644 --- a/packages/node/CHANGELOG.md +++ b/packages/node/CHANGELOG.md @@ -3,125 +3,74 @@ All notable changes to this project will be documented in this file. See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. -## [2.3.4](https://github.com/SuperFlyTV/xkeys/compare/v2.3.3...v2.3.4) (2022-06-06) - - -### Bug Fixes - -* Watcher: async handling of adding/removing devices ([61f0b28](https://github.com/SuperFlyTV/xkeys/commit/61f0b28571a3df72b49f4bd84b6d842408e86acd)) +## [3.0.0-alpha.0](https://github.com/SuperFlyTV/xkeys/compare/v2.3.4...v3.0.0-alpha.0) (2022-06-22) +**Note:** Version bump only for package xkeys +## [2.3.4](https://github.com/SuperFlyTV/xkeys/compare/v2.3.3...v2.3.4) (2022-06-06) +### Bug Fixes +- Watcher: async handling of adding/removing devices ([61f0b28](https://github.com/SuperFlyTV/xkeys/commit/61f0b28571a3df72b49f4bd84b6d842408e86acd)) ## [2.3.2](https://github.com/SuperFlyTV/xkeys/compare/v2.3.0...v2.3.2) (2021-12-12) **Note:** Version bump only for package xkeys - - - - # [2.3.0](https://github.com/SuperFlyTV/xkeys/compare/v2.2.1...v2.3.0) (2021-11-28) - ### Features -* add usePolling option to the XKeysWatcher to fall back to polling, since "usb-detection" might not work on all OS:es ([ab31223](https://github.com/SuperFlyTV/xkeys/commit/ab312236b14cb8f961d0b0bf878c611487a5983f)) - - - - +- add usePolling option to the XKeysWatcher to fall back to polling, since "usb-detection" might not work on all OS:es ([ab31223](https://github.com/SuperFlyTV/xkeys/commit/ab312236b14cb8f961d0b0bf878c611487a5983f)) ## [2.2.1](https://github.com/SuperFlyTV/xkeys/compare/v2.2.0...v2.2.1) (2021-09-22) **Note:** Version bump only for package xkeys - - - - # [2.2.0](https://github.com/SuperFlyTV/xkeys/compare/v2.2.0-alpha.1...v2.2.0) (2021-09-08) **Note:** Version bump only for package xkeys - - - - # [2.2.0-alpha.1](https://github.com/SuperFlyTV/xkeys/compare/v2.2.0-alpha.0...v2.2.0-alpha.1) (2021-09-06) - ### Bug Fixes -* re-add devicePath ([349f6a9](https://github.com/SuperFlyTV/xkeys/commit/349f6a93ace9480e18d5ed695186920165fea6e7)) - - - - +- re-add devicePath ([349f6a9](https://github.com/SuperFlyTV/xkeys/commit/349f6a93ace9480e18d5ed695186920165fea6e7)) # [2.2.0-alpha.0](https://github.com/SuperFlyTV/xkeys/compare/v2.1.1...v2.2.0-alpha.0) (2021-09-06) - ### Features -* add feature: "Automatic UnitId mode" ([f7c3a86](https://github.com/SuperFlyTV/xkeys/commit/f7c3a869e8820f856831aad576ce7978dfb9d75c)) -* add XKeys.uniqueId property, to be used with automaticUnitIdMode ([a2e6d7a](https://github.com/SuperFlyTV/xkeys/commit/a2e6d7a6ec917d82bc2a71c1922c22c061232908)) - - - - +- add feature: "Automatic UnitId mode" ([f7c3a86](https://github.com/SuperFlyTV/xkeys/commit/f7c3a869e8820f856831aad576ce7978dfb9d75c)) +- add XKeys.uniqueId property, to be used with automaticUnitIdMode ([a2e6d7a](https://github.com/SuperFlyTV/xkeys/commit/a2e6d7a6ec917d82bc2a71c1922c22c061232908)) ## [2.1.1](https://github.com/SuperFlyTV/xkeys/compare/v2.1.1-alpha.1...v2.1.1) (2021-05-24) **Note:** Version bump only for package xkeys - - - - ## [2.1.1-alpha.1](https://github.com/SuperFlyTV/xkeys/compare/v2.1.1-alpha.0...v2.1.1-alpha.1) (2021-05-23) - ### Bug Fixes -* hack to fix issue in Electron ([501f06d](https://github.com/SuperFlyTV/xkeys/commit/501f06de9a2413832dab4b6a0ef4ef7d2b668967)) -* make XKeysWatcher.stop() close all the devices it has called setupXkeysPanel() for. ([f69b599](https://github.com/SuperFlyTV/xkeys/commit/f69b59912a62b8dcc5ff00a2083c793851bba15c)) - - - - +- hack to fix issue in Electron ([501f06d](https://github.com/SuperFlyTV/xkeys/commit/501f06de9a2413832dab4b6a0ef4ef7d2b668967)) +- make XKeysWatcher.stop() close all the devices it has called setupXkeysPanel() for. ([f69b599](https://github.com/SuperFlyTV/xkeys/commit/f69b59912a62b8dcc5ff00a2083c793851bba15c)) ## [2.1.1-alpha.0](https://github.com/SuperFlyTV/xkeys/compare/v2.1.0...v2.1.1-alpha.0) (2021-05-23) - ### Bug Fixes -* remove listeners on watcher.stop() ([c8d36a3](https://github.com/SuperFlyTV/xkeys/commit/c8d36a3602b8c460233b82a48f6c28a04f52c9de)) - - - - +- remove listeners on watcher.stop() ([c8d36a3](https://github.com/SuperFlyTV/xkeys/commit/c8d36a3602b8c460233b82a48f6c28a04f52c9de)) # [2.1.0](https://github.com/SuperFlyTV/xkeys/compare/v2.1.0-alpha.0...v2.1.0) (2021-05-15) **Note:** Version bump only for package xkeys - - - - # [2.1.0-alpha.1](https://github.com/SuperFlyTV/xkeys/compare/v2.1.0-alpha.0...v2.1.0-alpha.1) (2021-05-10) **Note:** Version bump only for package xkeys - - - - # [2.1.0-alpha.0](https://github.com/SuperFlyTV/xkeys/compare/v2.0.0...v2.1.0-alpha.0) (2021-05-10) - ### Bug Fixes -* refactor repo into lerna mono-repo ([d5bffc1](https://github.com/SuperFlyTV/xkeys/commit/d5bffc1798e7c8e89ae9fcc4355afd438ea82d3a)) +- refactor repo into lerna mono-repo ([d5bffc1](https://github.com/SuperFlyTV/xkeys/commit/d5bffc1798e7c8e89ae9fcc4355afd438ea82d3a)) diff --git a/packages/node/package.json b/packages/node/package.json index e94159b..e3fe889 100644 --- a/packages/node/package.json +++ b/packages/node/package.json @@ -1,6 +1,6 @@ { "name": "xkeys", - "version": "2.3.4", + "version": "3.0.0-alpha.0", "description": "An npm module for interfacing with the X-keys panels in Node.js", "main": "dist/index.js", "typings": "dist/index.d.ts", @@ -41,7 +41,7 @@ }, "dependencies": { "@types/node-hid": "^1.3.1", - "@xkeys-lib/core": "2.3.4", + "@xkeys-lib/core": "3.0.0-alpha.0", "node-hid": "^2.1.1", "tslib": "^2.3.1" }, diff --git a/packages/webhid-demo/CHANGELOG.md b/packages/webhid-demo/CHANGELOG.md index 0b65dce..a558b61 100644 --- a/packages/webhid-demo/CHANGELOG.md +++ b/packages/webhid-demo/CHANGELOG.md @@ -3,97 +3,56 @@ All notable changes to this project will be documented in this file. See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. -## [2.3.4](https://github.com/SuperFlyTV/xkeys/compare/v2.3.3...v2.3.4) (2022-06-06) +## [3.0.0-alpha.0](https://github.com/SuperFlyTV/xkeys/compare/v2.3.4...v3.0.0-alpha.0) (2022-06-22) **Note:** Version bump only for package @xkeys-lib/webhid-demo +## [2.3.4](https://github.com/SuperFlyTV/xkeys/compare/v2.3.3...v2.3.4) (2022-06-06) - - +**Note:** Version bump only for package @xkeys-lib/webhid-demo ## [2.3.2](https://github.com/SuperFlyTV/xkeys/compare/v2.3.0...v2.3.2) (2021-12-12) **Note:** Version bump only for package @xkeys-lib/webhid-demo - - - - # [2.3.0](https://github.com/SuperFlyTV/xkeys/compare/v2.2.1...v2.3.0) (2021-11-28) **Note:** Version bump only for package @xkeys-lib/webhid-demo - - - - ## [2.2.1](https://github.com/SuperFlyTV/xkeys/compare/v2.2.0...v2.2.1) (2021-09-22) **Note:** Version bump only for package @xkeys-lib/webhid-demo - - - - # [2.2.0](https://github.com/SuperFlyTV/xkeys/compare/v2.2.0-alpha.1...v2.2.0) (2021-09-08) **Note:** Version bump only for package @xkeys-lib/webhid-demo - - - - # [2.2.0-alpha.1](https://github.com/SuperFlyTV/xkeys/compare/v2.2.0-alpha.0...v2.2.0-alpha.1) (2021-09-06) **Note:** Version bump only for package @xkeys-lib/webhid-demo - - - - # [2.2.0-alpha.0](https://github.com/SuperFlyTV/xkeys/compare/v2.1.1...v2.2.0-alpha.0) (2021-09-06) **Note:** Version bump only for package @xkeys-lib/webhid-demo - - - - ## [2.1.1](https://github.com/SuperFlyTV/xkeys/compare/v2.1.1-alpha.1...v2.1.1) (2021-05-24) **Note:** Version bump only for package @xkeys-lib/webhid-demo - - - - ## [2.1.1-alpha.0](https://github.com/SuperFlyTV/xkeys/compare/v2.1.0...v2.1.1-alpha.0) (2021-05-23) **Note:** Version bump only for package @xkeys-lib/webhid-demo - - - - # [2.1.0](https://github.com/SuperFlyTV/xkeys/compare/v2.1.0-alpha.0...v2.1.0) (2021-05-15) **Note:** Version bump only for package @xkeys-lib/webhid-demo - - - - # [2.1.0-alpha.1](https://github.com/SuperFlyTV/xkeys/compare/v2.1.0-alpha.0...v2.1.0-alpha.1) (2021-05-10) **Note:** Version bump only for package @xkeys-lib/webhid-demo - - - - # [2.1.0-alpha.0](https://github.com/SuperFlyTV/xkeys/compare/v2.0.0...v2.1.0-alpha.0) (2021-05-10) - ### Features -* add package with web-HID support ([1f27199](https://github.com/SuperFlyTV/xkeys/commit/1f2719969faf93ba45a2bc767f64543fb9ffe6ea)) +- add package with web-HID support ([1f27199](https://github.com/SuperFlyTV/xkeys/commit/1f2719969faf93ba45a2bc767f64543fb9ffe6ea)) diff --git a/packages/webhid-demo/package.json b/packages/webhid-demo/package.json index 1372e5f..edacaba 100644 --- a/packages/webhid-demo/package.json +++ b/packages/webhid-demo/package.json @@ -1,6 +1,6 @@ { "name": "@xkeys-lib/webhid-demo", - "version": "2.3.4", + "version": "3.0.0-alpha.0", "private": true, "license": "MIT", "homepage": "https://github.com/SuperFlyTV/xkeys#readme", @@ -22,7 +22,7 @@ }, "dependencies": { "buffer": "^6.0.3", - "xkeys-webhid": "2.3.4" + "xkeys-webhid": "3.0.0-alpha.0" }, "devDependencies": { "copy-webpack-plugin": "^7.0.0", diff --git a/packages/webhid/CHANGELOG.md b/packages/webhid/CHANGELOG.md index cf5fd69..8b8abd0 100644 --- a/packages/webhid/CHANGELOG.md +++ b/packages/webhid/CHANGELOG.md @@ -3,100 +3,58 @@ All notable changes to this project will be documented in this file. See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. -## [2.3.4](https://github.com/SuperFlyTV/xkeys/compare/v2.3.3...v2.3.4) (2022-06-06) +## [3.0.0-alpha.0](https://github.com/SuperFlyTV/xkeys/compare/v2.3.4...v3.0.0-alpha.0) (2022-06-22) **Note:** Version bump only for package xkeys-webhid +## [2.3.4](https://github.com/SuperFlyTV/xkeys/compare/v2.3.3...v2.3.4) (2022-06-06) - - +**Note:** Version bump only for package xkeys-webhid ## [2.3.2](https://github.com/SuperFlyTV/xkeys/compare/v2.3.0...v2.3.2) (2021-12-12) **Note:** Version bump only for package xkeys-webhid - - - - # [2.3.0](https://github.com/SuperFlyTV/xkeys/compare/v2.2.1...v2.3.0) (2021-11-28) **Note:** Version bump only for package xkeys-webhid - - - - ## [2.2.1](https://github.com/SuperFlyTV/xkeys/compare/v2.2.0...v2.2.1) (2021-09-22) **Note:** Version bump only for package xkeys-webhid - - - - # [2.2.0](https://github.com/SuperFlyTV/xkeys/compare/v2.2.0-alpha.1...v2.2.0) (2021-09-08) **Note:** Version bump only for package xkeys-webhid - - - - # [2.2.0-alpha.1](https://github.com/SuperFlyTV/xkeys/compare/v2.2.0-alpha.0...v2.2.0-alpha.1) (2021-09-06) - ### Bug Fixes -* re-add devicePath ([349f6a9](https://github.com/SuperFlyTV/xkeys/commit/349f6a93ace9480e18d5ed695186920165fea6e7)) - - - - +- re-add devicePath ([349f6a9](https://github.com/SuperFlyTV/xkeys/commit/349f6a93ace9480e18d5ed695186920165fea6e7)) # [2.2.0-alpha.0](https://github.com/SuperFlyTV/xkeys/compare/v2.1.1...v2.2.0-alpha.0) (2021-09-06) **Note:** Version bump only for package xkeys-webhid - - - - ## [2.1.1](https://github.com/SuperFlyTV/xkeys/compare/v2.1.1-alpha.1...v2.1.1) (2021-05-24) **Note:** Version bump only for package xkeys-webhid - - - - ## [2.1.1-alpha.0](https://github.com/SuperFlyTV/xkeys/compare/v2.1.0...v2.1.1-alpha.0) (2021-05-23) **Note:** Version bump only for package xkeys-webhid - - - - # [2.1.0](https://github.com/SuperFlyTV/xkeys/compare/v2.1.0-alpha.0...v2.1.0) (2021-05-15) **Note:** Version bump only for package xkeys-webhid - - - - # [2.1.0-alpha.1](https://github.com/SuperFlyTV/xkeys/compare/v2.1.0-alpha.0...v2.1.0-alpha.1) (2021-05-10) **Note:** Version bump only for package xkeys-webhid - - - - # [2.1.0-alpha.0](https://github.com/SuperFlyTV/xkeys/compare/v2.0.0...v2.1.0-alpha.0) (2021-05-10) - ### Features -* add package with web-HID support ([1f27199](https://github.com/SuperFlyTV/xkeys/commit/1f2719969faf93ba45a2bc767f64543fb9ffe6ea)) +- add package with web-HID support ([1f27199](https://github.com/SuperFlyTV/xkeys/commit/1f2719969faf93ba45a2bc767f64543fb9ffe6ea)) diff --git a/packages/webhid/package.json b/packages/webhid/package.json index a5ea184..70b328f 100644 --- a/packages/webhid/package.json +++ b/packages/webhid/package.json @@ -1,6 +1,6 @@ { "name": "xkeys-webhid", - "version": "2.3.4", + "version": "3.0.0-alpha.0", "description": "An npm module for interfacing with the X-keys panels in a browser", "main": "dist/index.js", "typings": "dist/index.d.ts", @@ -37,7 +37,7 @@ ], "dependencies": { "@types/w3c-web-hid": "^1.0.3", - "@xkeys-lib/core": "2.3.4", + "@xkeys-lib/core": "3.0.0-alpha.0", "buffer": "^6.0.3", "p-queue": "^6.6.2" }, From 1d806143e54383f3999f1b0df57967d5b9e2d48d Mon Sep 17 00:00:00 2001 From: Johan Nyman Date: Wed, 22 Jun 2022 08:29:40 +0200 Subject: [PATCH 13/49] chore: use Node 16 in CI --- .github/workflows/publish-nightly.yml | 4 ++-- .github/workflows/publish-prerelease.yml | 4 ++-- .github/workflows/publish-release.yml | 6 +++--- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/.github/workflows/publish-nightly.yml b/.github/workflows/publish-nightly.yml index 608be14..696d406 100644 --- a/.github/workflows/publish-nightly.yml +++ b/.github/workflows/publish-nightly.yml @@ -16,10 +16,10 @@ jobs: steps: - uses: actions/checkout@v2 - - name: Use Node.js 12.x + - name: Use Node.js 16.x uses: actions/setup-node@v1 with: - node-version: 12.x + node-version: 16.x - name: Check if token is set id: check-npm-token run: | diff --git a/.github/workflows/publish-prerelease.yml b/.github/workflows/publish-prerelease.yml index 9bc19d4..7741a0a 100644 --- a/.github/workflows/publish-prerelease.yml +++ b/.github/workflows/publish-prerelease.yml @@ -65,10 +65,10 @@ jobs: steps: - uses: actions/checkout@v2 - - name: Use Node.js 12.x + - name: Use Node.js 16.x uses: actions/setup-node@v1 with: - node-version: 12.x + node-version: 16.x - name: Check if token is set id: check-npm-token run: | diff --git a/.github/workflows/publish-release.yml b/.github/workflows/publish-release.yml index 1a2afaa..6010add 100644 --- a/.github/workflows/publish-release.yml +++ b/.github/workflows/publish-release.yml @@ -17,7 +17,7 @@ jobs: - name: Use Node.js uses: actions/setup-node@v1 with: - node-version: 14 + node-version: 16 - name: Cache node_modules uses: actions/cache@v2 with: @@ -98,10 +98,10 @@ jobs: steps: - uses: actions/checkout@v2 - - name: Use Node.js 12.x + - name: Use Node.js 16.x uses: actions/setup-node@v1 with: - node-version: 12.x + node-version: 16.x - name: Check if token is set id: check-npm-token run: | From 6b625ea6a1392f5601aafb4054fe278b3529f161 Mon Sep 17 00:00:00 2001 From: Michael Hetherington Date: Thu, 1 Sep 2022 15:55:01 -0400 Subject: [PATCH 14/49] fixed bad t-bar byte in Products.ts --- packages/core/src/products.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/packages/core/src/products.ts b/packages/core/src/products.ts index 4176551..93272d5 100644 --- a/packages/core/src/products.ts +++ b/packages/core/src/products.ts @@ -833,7 +833,8 @@ export const PRODUCTS: { [name: string]: Product } = { hasPS: false, hasTbar: [ { - tbarByte: 9, + tbarByte: 8, // value Was incorrect, 8 is correct + }, ], backLightType: BackLightType.RGBx2, //RGB 2 Bank,Standard Index From ee92b85ce4cb6d4ef86c89eff80b8ae54c4802e1 Mon Sep 17 00:00:00 2001 From: Johan Nyman Date: Wed, 26 Oct 2022 08:53:59 +0200 Subject: [PATCH 15/49] chore: use Node 16 in CI --- .github/workflows/lint-and-test.yml | 2 +- .github/workflows/publish-demo.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/lint-and-test.yml b/.github/workflows/lint-and-test.yml index 8c9d88c..d07877a 100644 --- a/.github/workflows/lint-and-test.yml +++ b/.github/workflows/lint-and-test.yml @@ -21,7 +21,7 @@ jobs: - name: Use Node.js uses: actions/setup-node@v1 with: - node-version: 14 + node-version: 16 - name: Cache node_modules uses: actions/cache@v2 with: diff --git a/.github/workflows/publish-demo.yml b/.github/workflows/publish-demo.yml index a6c962a..3649bd7 100644 --- a/.github/workflows/publish-demo.yml +++ b/.github/workflows/publish-demo.yml @@ -18,7 +18,7 @@ jobs: - name: Use Node.js 14.x uses: actions/setup-node@v1 with: - node-version: 14.x + node-version: 16.x - name: Prepare build run: | yarn install From edcca6c38d8042fcc215046f390aa77b633e0c2f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 17 Nov 2022 05:29:50 +0000 Subject: [PATCH 16/49] chore(deps): bump loader-utils from 2.0.2 to 2.0.4 Bumps [loader-utils](https://github.com/webpack/loader-utils) from 2.0.2 to 2.0.4. - [Release notes](https://github.com/webpack/loader-utils/releases) - [Changelog](https://github.com/webpack/loader-utils/blob/v2.0.4/CHANGELOG.md) - [Commits](https://github.com/webpack/loader-utils/compare/v2.0.2...v2.0.4) --- updated-dependencies: - dependency-name: loader-utils dependency-type: indirect ... Signed-off-by: dependabot[bot] --- yarn.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/yarn.lock b/yarn.lock index 7a4a568..f7d2561 100644 --- a/yarn.lock +++ b/yarn.lock @@ -6513,9 +6513,9 @@ loader-runner@^4.2.0: integrity sha512-3R/1M+yS3j5ou80Me59j7F9IMs4PXs3VqRrm0TU3AbKPxlmpoY1TNscJV/oGJXo8qCatFGTfDbY6W6ipGOYXfg== loader-utils@^2.0.0: - version "2.0.2" - resolved "https://registry.yarnpkg.com/loader-utils/-/loader-utils-2.0.2.tgz#d6e3b4fb81870721ae4e0868ab11dd638368c129" - integrity sha512-TM57VeHptv569d/GKh6TAYdzKblwDNiumOdkFnejjD0XwTH87K90w3O7AiJRqdQoXygvi1VQTJTLGhJl7WqA7A== + version "2.0.4" + resolved "https://registry.yarnpkg.com/loader-utils/-/loader-utils-2.0.4.tgz#8b5cb38b5c34a9a018ee1fc0e6a066d1dfcc528c" + integrity sha512-xXqpXoINfFhgua9xiqD8fPFHgkoq1mmmpE92WlDbm9rNRd/EbRb+Gqf908T2DMfuHjjJlksiK2RbHVOdD/MqSw== dependencies: big.js "^5.2.2" emojis-list "^3.0.0" From 5794d7c4ea6dd3c7ff3af775afa45342f904bdb8 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 7 Dec 2022 02:11:52 +0000 Subject: [PATCH 17/49] chore(deps): bump decode-uri-component from 0.2.0 to 0.2.2 Bumps [decode-uri-component](https://github.com/SamVerschueren/decode-uri-component) from 0.2.0 to 0.2.2. - [Release notes](https://github.com/SamVerschueren/decode-uri-component/releases) - [Commits](https://github.com/SamVerschueren/decode-uri-component/compare/v0.2.0...v0.2.2) --- updated-dependencies: - dependency-name: decode-uri-component dependency-type: indirect ... Signed-off-by: dependabot[bot] --- yarn.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/yarn.lock b/yarn.lock index 7a4a568..a0085b8 100644 --- a/yarn.lock +++ b/yarn.lock @@ -3335,9 +3335,9 @@ decimal.js@^10.2.1: integrity sha512-V0pfhfr8suzyPGOx3nmq4aHqabehUZn6Ch9kyFpV79TGDTWFmHqUqXdabR7QHqxzrYolF4+tVmJhUG4OURg5dQ== decode-uri-component@^0.2.0: - version "0.2.0" - resolved "https://registry.yarnpkg.com/decode-uri-component/-/decode-uri-component-0.2.0.tgz#eb3913333458775cb84cd1a1fae062106bb87545" - integrity sha512-hjf+xovcEn31w/EUYdTXQh/8smFL/dzYjohQGEIgjyNavaJfBY2p5F527Bo1VPATxv0VYTUC2bOcXvqFwk78Og== + version "0.2.2" + resolved "https://registry.yarnpkg.com/decode-uri-component/-/decode-uri-component-0.2.2.tgz#e69dbe25d37941171dd540e024c444cd5188e1e9" + integrity sha512-FqUYQ+8o158GyGTrMFJms9qh3CqTKvAqgqsTnkLI8sKu0028orqBhxNMFkFen0zGyg6epACD32pjVk58ngIErQ== decompress-response@^3.3.0: version "3.3.0" From fee505ddf7551d446786f53127adafac65a3dbfc Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Sun, 8 Jan 2023 15:25:38 +0000 Subject: [PATCH 18/49] chore(deps): bump json5 from 2.2.1 to 2.2.3 Bumps [json5](https://github.com/json5/json5) from 2.2.1 to 2.2.3. - [Release notes](https://github.com/json5/json5/releases) - [Changelog](https://github.com/json5/json5/blob/main/CHANGELOG.md) - [Commits](https://github.com/json5/json5/compare/v2.2.1...v2.2.3) --- updated-dependencies: - dependency-name: json5 dependency-type: indirect ... Signed-off-by: dependabot[bot] --- yarn.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/yarn.lock b/yarn.lock index 7a4a568..ca68c1e 100644 --- a/yarn.lock +++ b/yarn.lock @@ -6285,9 +6285,9 @@ json-stringify-safe@^5.0.1, json-stringify-safe@~5.0.1: integrity sha512-ZClg6AaYvamvYEE82d3Iyd3vSSIjQ+odgjaTzRuO3s7toCdFKczob2i0zCh7JE8kWn17yvAWhUVxvqGwUalsRA== json5@2.x, json5@^2.1.2, json5@^2.2.1: - version "2.2.1" - resolved "https://registry.yarnpkg.com/json5/-/json5-2.2.1.tgz#655d50ed1e6f95ad1a3caababd2b0efda10b395c" - integrity sha512-1hqLFMSrGHRHxav9q9gNjJ5EXznIxGVO09xQRrwplcS8qs28pZ8s8hupZAmqDwZUmVZ2Qb2jnyPOWcDH8m8dlA== + version "2.2.3" + resolved "https://registry.yarnpkg.com/json5/-/json5-2.2.3.tgz#78cd6f1a19bdc12b73db5ad0c61efd66c1e29283" + integrity sha512-XmOWe7eyHYH14cLdVPoyg+GOH3rYX++KpzrylJwSW98t3Nk+U8XOl8FWKOgwtzdb8lXGf6zYwDUzeHMWfxasyg== jsonfile@^6.0.1: version "6.1.0" From 67c2bfc5a0e113c25393400199d8d51f5258d34b Mon Sep 17 00:00:00 2001 From: Johan Nyman Date: Wed, 3 May 2023 08:25:37 +0200 Subject: [PATCH 19/49] chore: add error listener to XKeysWatcher in examples and doc closes #74 --- README.md | 6 ++++++ packages/node/examples/basic-log-all-events.js | 3 +++ packages/node/examples/multiple-panels.js | 3 +++ packages/node/examples/reset-unitId.js | 3 +++ 4 files changed, 15 insertions(+) diff --git a/README.md b/README.md index 21ed192..62d4933 100644 --- a/README.md +++ b/README.md @@ -74,6 +74,9 @@ const watcher = new XKeysWatcher({ // usePolling: false // pollingInterval= 1000 }) +watcher.on('error', (e) => { + console.log('Error in XKeysWatcher', e) +}) watcher.on('connected', (xkeysPanel) => { console.log(`X-keys panel of type ${xkeysPanel.info.name} connected`) @@ -193,6 +196,9 @@ const watcher = new XKeysWatcher({ // usePolling: false // pollingInterval= 1000 }) +watcher.on('error', (e) => { + console.log('Error in XKeysWatcher', e) +}) watcher.on('connected', (xkeysPanel) => { // xkeysPanel connected... }) diff --git a/packages/node/examples/basic-log-all-events.js b/packages/node/examples/basic-log-all-events.js index f7c38db..ffff5d8 100644 --- a/packages/node/examples/basic-log-all-events.js +++ b/packages/node/examples/basic-log-all-events.js @@ -12,6 +12,9 @@ const watcher = new XKeysWatcher({ // pollingInterval= 1000 }) +watcher.on('error', (e) => { + console.log('Error in XKeysWatcher', e) +}) watcher.on('connected', (xkeysPanel) => { console.log(`X-keys panel of type ${xkeysPanel.info.name} connected`) diff --git a/packages/node/examples/multiple-panels.js b/packages/node/examples/multiple-panels.js index 1d1b251..1ab51f4 100644 --- a/packages/node/examples/multiple-panels.js +++ b/packages/node/examples/multiple-panels.js @@ -23,6 +23,9 @@ const watcher = new XKeysWatcher({ // usePolling: true, // pollingInterval: 1000, }) +watcher.on('error', (e) => { + console.log('Error in XKeysWatcher', e) +}) watcher.on('connected', (xkeysPanel) => { // This callback is called when a panel is initially connected. diff --git a/packages/node/examples/reset-unitId.js b/packages/node/examples/reset-unitId.js index c4c176d..6648160 100644 --- a/packages/node/examples/reset-unitId.js +++ b/packages/node/examples/reset-unitId.js @@ -6,6 +6,9 @@ const { XKeysWatcher } = require('xkeys') */ const watcher = new XKeysWatcher() +watcher.on('error', (e) => { + console.log('Error in XKeysWatcher', e) +}) watcher.on('connected', (xkeysPanel) => { console.log( From 8e9afb81bb75f22710841cb4d9aa132e4fca83f6 Mon Sep 17 00:00:00 2001 From: Johan Nyman Date: Wed, 3 May 2023 08:51:10 +0200 Subject: [PATCH 20/49] chore: refactor: move things around in package.json files to unify them --- packages/core/package.json | 21 +++++++++++---------- packages/node-record-test/package.json | 21 +++++++++++---------- packages/node/package.json | 21 +++++++++++---------- packages/webhid/package.json | 15 ++++++++------- 4 files changed, 41 insertions(+), 37 deletions(-) diff --git a/packages/core/package.json b/packages/core/package.json index 0584773..94ac4d2 100644 --- a/packages/core/package.json +++ b/packages/core/package.json @@ -4,10 +4,15 @@ "description": "NPM package to interact with the X-keys panels", "main": "dist/index.js", "typings": "dist/index.d.ts", + "license": "MIT", + "homepage": "https://github.com/SuperFlyTV/xkeys", "repository": { "type": "git", "url": "git+https://github.com/SuperFlyTV/xkeys.git" }, + "bugs": { + "url": "https://github.com/SuperFlyTV/xkeys/issues" + }, "author": { "name": "Johan Nyman", "email": "johan@superfly.tv", @@ -23,22 +28,15 @@ "url": "https://github.com/cyraxx" } ], - "license": "MIT", - "bugs": { - "url": "https://github.com/SuperFlyTV/xkeys/issues" - }, - "homepage": "https://github.com/SuperFlyTV/xkeys#readme", "scripts": { "build": "rimraf dist && yarn build:main", - "build:main": "tsc -p tsconfig.json" + "build:main": "tsc -p tsconfig.json", + "__test": "jest" }, - "dependencies": { - "tslib": "^2.4.0" - }, - "prettier": "@sofie-automation/code-standard-preset/.prettierrc.json", "engines": { "node": ">=10" }, + "prettier": "@sofie-automation/code-standard-preset/.prettierrc.json", "keywords": [ "xkeys", "x-keys", @@ -48,6 +46,9 @@ "interface", "controller" ], + "dependencies": { + "tslib": "^2.4.0" + }, "publishConfig": { "access": "public" } diff --git a/packages/node-record-test/package.json b/packages/node-record-test/package.json index c831d8b..c84297c 100644 --- a/packages/node-record-test/package.json +++ b/packages/node-record-test/package.json @@ -40,6 +40,16 @@ "engines": { "node": ">=10" }, + "prettier": "@sofie-automation/code-standard-preset/.prettierrc.json", + "keywords": [ + "xkeys", + "x-keys", + "hid", + "usb", + "hardware", + "interface", + "controller" + ], "dependencies": { "@xkeys-lib/core": "2.4.0", "readline": "^1.3.0", @@ -49,14 +59,5 @@ "optionalDependencies": { "find": "^0.3.0", "nexe": "^3.3.7" - }, - "keywords": [ - "xkeys", - "x-keys", - "hid", - "usb", - "hardware", - "interface", - "controller" - ] + } } diff --git a/packages/node/package.json b/packages/node/package.json index 48dc261..87c4bfa 100644 --- a/packages/node/package.json +++ b/packages/node/package.json @@ -39,15 +39,7 @@ "engines": { "node": ">=10" }, - "dependencies": { - "@types/node-hid": "^1.3.1", - "@xkeys-lib/core": "2.4.0", - "node-hid": "^2.1.1", - "tslib": "^2.4.0" - }, - "optionalDependencies": { - "usb": "^2.5.2" - }, + "prettier": "@sofie-automation/code-standard-preset/.prettierrc.json", "keywords": [ "xkeys", "x-keys", @@ -56,5 +48,14 @@ "hardware", "interface", "controller" - ] + ], + "dependencies": { + "@types/node-hid": "^1.3.1", + "@xkeys-lib/core": "2.4.0", + "node-hid": "^2.1.1", + "tslib": "^2.4.0" + }, + "optionalDependencies": { + "usb": "^2.5.2" + } } diff --git a/packages/webhid/package.json b/packages/webhid/package.json index a5da4ed..7d95687 100644 --- a/packages/webhid/package.json +++ b/packages/webhid/package.json @@ -18,6 +18,14 @@ "email": "johan@superfly.tv", "url": "https://github.com/nytamin" }, + "scripts": { + "build": "rimraf dist && yarn build:main", + "build:main": "tsc -p tsconfig.json" + }, + "files": [ + "dist" + ], + "prettier": "@sofie-automation/code-standard-preset/.prettierrc.json", "keywords": [ "xkeys", "x-keys", @@ -28,13 +36,6 @@ "controller", "webhid" ], - "scripts": { - "build": "rimraf dist && yarn build:main", - "build:main": "tsc -p tsconfig.json" - }, - "files": [ - "dist" - ], "dependencies": { "@types/w3c-web-hid": "^1.0.3", "@xkeys-lib/core": "2.4.0", From 358a686072b1a7fd76f9b657d2c52175fa562998 Mon Sep 17 00:00:00 2001 From: Johan Nyman Date: Wed, 3 May 2023 09:08:18 +0200 Subject: [PATCH 21/49] chore: improve build pipeline, to ignore some unnecessary files (unit tests) when publishing --- package.json | 1 - packages/core/package.json | 5 ++++- packages/core/tsconfig.build.json | 9 ++++++++ packages/core/tsconfig.json | 5 +---- packages/node-record-test/package.json | 4 ++-- packages/node-record-test/tsconfig.build.json | 9 ++++++++ packages/node-record-test/tsconfig.json | 5 +---- packages/node/package.json | 4 ++-- packages/node/tsconfig.build.json | 9 ++++++++ packages/node/tsconfig.json | 5 +---- packages/webhid/package.json | 4 ++-- packages/webhid/tsconfig.build.json | 17 ++++++++++++++ packages/webhid/tsconfig.json | 1 - tsconfig.build.json | 22 ++++++++++++++----- 14 files changed, 74 insertions(+), 26 deletions(-) create mode 100644 packages/core/tsconfig.build.json create mode 100644 packages/node-record-test/tsconfig.build.json create mode 100644 packages/node/tsconfig.build.json create mode 100644 packages/webhid/tsconfig.build.json diff --git a/package.json b/package.json index 24f0a58..becbabd 100644 --- a/package.json +++ b/package.json @@ -45,7 +45,6 @@ "yarn lint --fix" ] }, - "main": "dist/index.js", "author": "Johan Nyman ", "license": "MIT" } diff --git a/packages/core/package.json b/packages/core/package.json index 94ac4d2..e8d7ce8 100644 --- a/packages/core/package.json +++ b/packages/core/package.json @@ -30,9 +30,12 @@ ], "scripts": { "build": "rimraf dist && yarn build:main", - "build:main": "tsc -p tsconfig.json", + "build:main": "tsc -p tsconfig.build.json", "__test": "jest" }, + "files": [ + "dist/**" + ], "engines": { "node": ">=10" }, diff --git a/packages/core/tsconfig.build.json b/packages/core/tsconfig.build.json new file mode 100644 index 0000000..c093348 --- /dev/null +++ b/packages/core/tsconfig.build.json @@ -0,0 +1,9 @@ +{ + "extends": "../../tsconfig.build.json", + "include": [ + "./src/**/*" + ], + "compilerOptions": { + "outDir": "./dist", + } +} diff --git a/packages/core/tsconfig.json b/packages/core/tsconfig.json index 67e52fd..ce665af 100644 --- a/packages/core/tsconfig.json +++ b/packages/core/tsconfig.json @@ -2,8 +2,5 @@ "extends": "../../tsconfig.json", "include": [ "./src/**/*" - ], - "compilerOptions": { - "outDir": "./dist", - } + ] } diff --git a/packages/node-record-test/package.json b/packages/node-record-test/package.json index c84297c..13125da 100644 --- a/packages/node-record-test/package.json +++ b/packages/node-record-test/package.json @@ -31,11 +31,11 @@ ], "scripts": { "build": "rimraf dist && yarn build:main", - "build:main": "tsc -p tsconfig.json", + "build:main": "tsc -p tsconfig.build.json", "build-record-test": "npm run build && rimraf ./deploy/xkeys-nodejs-test-recorder.exe && nexe dist/record-test.js -t windows-x64-12.18.1 -o ./deploy/xkeys-nodejs-test-recorder.exe && node scripts/copy-natives.js win32-x64" }, "files": [ - "dist" + "dist/**" ], "engines": { "node": ">=10" diff --git a/packages/node-record-test/tsconfig.build.json b/packages/node-record-test/tsconfig.build.json new file mode 100644 index 0000000..c093348 --- /dev/null +++ b/packages/node-record-test/tsconfig.build.json @@ -0,0 +1,9 @@ +{ + "extends": "../../tsconfig.build.json", + "include": [ + "./src/**/*" + ], + "compilerOptions": { + "outDir": "./dist", + } +} diff --git a/packages/node-record-test/tsconfig.json b/packages/node-record-test/tsconfig.json index 67e52fd..ce665af 100644 --- a/packages/node-record-test/tsconfig.json +++ b/packages/node-record-test/tsconfig.json @@ -2,8 +2,5 @@ "extends": "../../tsconfig.json", "include": [ "./src/**/*" - ], - "compilerOptions": { - "outDir": "./dist", - } + ] } diff --git a/packages/node/package.json b/packages/node/package.json index 87c4bfa..3c383e5 100644 --- a/packages/node/package.json +++ b/packages/node/package.json @@ -30,11 +30,11 @@ ], "scripts": { "build": "rimraf dist && yarn build:main", - "build:main": "tsc -p tsconfig.json", + "build:main": "tsc -p tsconfig.build.json", "test": "jest" }, "files": [ - "dist" + "dist/**" ], "engines": { "node": ">=10" diff --git a/packages/node/tsconfig.build.json b/packages/node/tsconfig.build.json new file mode 100644 index 0000000..d478e7c --- /dev/null +++ b/packages/node/tsconfig.build.json @@ -0,0 +1,9 @@ +{ + "extends": "../../tsconfig.build.json", + "include": [ + "./src/**/*" + ], + "compilerOptions": { + "outDir": "./dist" + } +} diff --git a/packages/node/tsconfig.json b/packages/node/tsconfig.json index 8cca428..ce665af 100644 --- a/packages/node/tsconfig.json +++ b/packages/node/tsconfig.json @@ -2,8 +2,5 @@ "extends": "../../tsconfig.json", "include": [ "./src/**/*" - ], - "compilerOptions": { - "outDir": "./dist" - } + ] } diff --git a/packages/webhid/package.json b/packages/webhid/package.json index 7d95687..9ebb19d 100644 --- a/packages/webhid/package.json +++ b/packages/webhid/package.json @@ -20,10 +20,10 @@ }, "scripts": { "build": "rimraf dist && yarn build:main", - "build:main": "tsc -p tsconfig.json" + "build:main": "tsc -p tsconfig.build.json" }, "files": [ - "dist" + "dist/**" ], "prettier": "@sofie-automation/code-standard-preset/.prettierrc.json", "keywords": [ diff --git a/packages/webhid/tsconfig.build.json b/packages/webhid/tsconfig.build.json new file mode 100644 index 0000000..9f80412 --- /dev/null +++ b/packages/webhid/tsconfig.build.json @@ -0,0 +1,17 @@ +{ + "extends": "../../tsconfig.build.json", + "include": [ + "./src/**/*" + ], + "compilerOptions": { + "outDir": "./dist", + "lib": [ + "es2015", + "dom" + ], + "types": [ + "jest", + "w3c-web-hid" + ] + } +} diff --git a/packages/webhid/tsconfig.json b/packages/webhid/tsconfig.json index ff4647d..2beaa64 100644 --- a/packages/webhid/tsconfig.json +++ b/packages/webhid/tsconfig.json @@ -4,7 +4,6 @@ "./src/**/*" ], "compilerOptions": { - "outDir": "./dist", "lib": [ "es2015", "dom" diff --git a/tsconfig.build.json b/tsconfig.build.json index 6dc6a0e..2d06519 100644 --- a/tsconfig.build.json +++ b/tsconfig.build.json @@ -1,19 +1,31 @@ { "extends": "@sofie-automation/code-standard-preset/ts/tsconfig.lib", - "exclude": ["node_modules/**", "src/**/*spec.ts", "src/**/__tests__/*", "src/**/__mocks__/*"], - "include": ["/src/**/*"], + "exclude": [ + "node_modules/**", + "**/__tests__", + "**/__mocks__" + ], + "include": [ + "/src/**/*" + ], "compilerOptions": { "outDir": "./dist", "baseUrl": "./", "paths": { - "*": ["./node_modules/*"] + "*": [ + "./node_modules/*" + ] }, - "types": ["node"], + "types": [ + "node" + ], "importHelpers": false, "declarationMap": true, // Target: node 10 "target": "es2018", - "lib": ["es2018"], + "lib": [ + "es2018" + ], "skipLibCheck": true } } From bf13ce78ad1ebdf4747305c2beec0270ae43dbe6 Mon Sep 17 00:00:00 2001 From: Johan Nyman Date: Wed, 3 May 2023 09:16:08 +0200 Subject: [PATCH 22/49] chore: update CI actions --- .github/workflows/lint-and-test.yml | 12 ++++++------ .github/workflows/publish-demo.yml | 4 ++-- .github/workflows/publish-nightly.yml | 5 ++--- .github/workflows/publish-prerelease.yml | 10 +++++----- .github/workflows/publish-release.yml | 16 ++++++++-------- 5 files changed, 23 insertions(+), 24 deletions(-) diff --git a/.github/workflows/lint-and-test.yml b/.github/workflows/lint-and-test.yml index fc8776c..67878f9 100644 --- a/.github/workflows/lint-and-test.yml +++ b/.github/workflows/lint-and-test.yml @@ -17,13 +17,13 @@ jobs: timeout-minutes: 10 steps: # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - name: Use Node.js - uses: actions/setup-node@v1 + uses: actions/setup-node@v3 with: node-version: 14 - name: Cache node_modules - uses: actions/cache@v2 + uses: actions/cache@v3 with: path: '**/node_modules' key: ${{ runner.os }}-modules-${{ hashFiles('**/yarn.lock') }} @@ -50,13 +50,13 @@ jobs: timeout-minutes: 10 steps: # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - name: Use Node.js ${{ matrix.node_version }} - uses: actions/setup-node@v1 + uses: actions/setup-node@v3 with: node-version: ${{ matrix.node_version }} - name: Cache node_modules - uses: actions/cache@v2 + uses: actions/cache@v3 with: path: '**/node_modules' key: ${{ runner.os }}-modules-${{ hashFiles('**/yarn.lock') }} diff --git a/.github/workflows/publish-demo.yml b/.github/workflows/publish-demo.yml index a6c962a..23af82c 100644 --- a/.github/workflows/publish-demo.yml +++ b/.github/workflows/publish-demo.yml @@ -14,9 +14,9 @@ jobs: timeout-minutes: 15 steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - name: Use Node.js 14.x - uses: actions/setup-node@v1 + uses: actions/setup-node@v3 with: node-version: 14.x - name: Prepare build diff --git a/.github/workflows/publish-nightly.yml b/.github/workflows/publish-nightly.yml index 608be14..de46cf9 100644 --- a/.github/workflows/publish-nightly.yml +++ b/.github/workflows/publish-nightly.yml @@ -7,7 +7,6 @@ on: # A workflow run is made up of one or more jobs that can run sequentially or in parallel jobs: - publish: name: Publish to NPM (nightly) runs-on: ubuntu-latest @@ -15,9 +14,9 @@ jobs: timeout-minutes: 15 steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - name: Use Node.js 12.x - uses: actions/setup-node@v1 + uses: actions/setup-node@v3 with: node-version: 12.x - name: Check if token is set diff --git a/.github/workflows/publish-prerelease.yml b/.github/workflows/publish-prerelease.yml index a26c0ef..4a77d50 100644 --- a/.github/workflows/publish-prerelease.yml +++ b/.github/workflows/publish-prerelease.yml @@ -17,13 +17,13 @@ jobs: timeout-minutes: 10 steps: # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - name: Use Node.js ${{ matrix.node_version }} - uses: actions/setup-node@v1 + uses: actions/setup-node@v3 with: node-version: ${{ matrix.node_version }} - name: Cache node_modules - uses: actions/cache@v2 + uses: actions/cache@v3 with: path: '**/node_modules' key: ${{ runner.os }}-modules-${{ hashFiles('**/yarn.lock') }} @@ -64,9 +64,9 @@ jobs: - test steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - name: Use Node.js 12.x - uses: actions/setup-node@v1 + uses: actions/setup-node@v3 with: node-version: 12.x - name: Check if token is set diff --git a/.github/workflows/publish-release.yml b/.github/workflows/publish-release.yml index 0a5809e..95f93a5 100644 --- a/.github/workflows/publish-release.yml +++ b/.github/workflows/publish-release.yml @@ -13,13 +13,13 @@ jobs: timeout-minutes: 10 steps: # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - name: Use Node.js - uses: actions/setup-node@v1 + uses: actions/setup-node@v3 with: node-version: 14 - name: Cache node_modules - uses: actions/cache@v2 + uses: actions/cache@v3 with: path: '**/node_modules' key: ${{ runner.os }}-modules-${{ hashFiles('**/yarn.lock') }} @@ -46,13 +46,13 @@ jobs: timeout-minutes: 10 steps: # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - name: Use Node.js ${{ matrix.node_version }} - uses: actions/setup-node@v1 + uses: actions/setup-node@v3 with: node-version: ${{ matrix.node_version }} - name: Cache node_modules - uses: actions/cache@v2 + uses: actions/cache@v3 with: path: '**/node_modules' key: ${{ runner.os }}-modules-${{ hashFiles('**/yarn.lock') }} @@ -97,9 +97,9 @@ jobs: - test steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - name: Use Node.js 12.x - uses: actions/setup-node@v1 + uses: actions/setup-node@v3 with: node-version: 12.x - name: Check if token is set From b8d377704c7ec302ee88bb819a9782a925db3f6d Mon Sep 17 00:00:00 2001 From: Johan Nyman Date: Wed, 3 May 2023 09:48:34 +0200 Subject: [PATCH 23/49] chore: nightly publish, commit changes before publishing to make lerna happy --- .github/workflows/publish-nightly.yml | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/.github/workflows/publish-nightly.yml b/.github/workflows/publish-nightly.yml index 608be14..bbc7dd4 100644 --- a/.github/workflows/publish-nightly.yml +++ b/.github/workflows/publish-nightly.yml @@ -7,7 +7,6 @@ on: # A workflow run is made up of one or more jobs that can run sequentially or in parallel jobs: - publish: name: Publish to NPM (nightly) runs-on: ubuntu-latest @@ -60,6 +59,15 @@ jobs: run: | echo "//registry.npmjs.org/:_authToken=${{ secrets.NPM_TOKEN }}" > .npmrc npm whoami + - name: Git commit + if: ${{ steps.check-npm-token.outputs.is-ok }} + run: | + git config --global user.email "ci@github.com" + git config --global user.name "Github CI" + git add -A + git commit -m "Make lerna happy" + env: + CI: true - name: Publish nightly to NPM if: ${{ steps.check-npm-token.outputs.is-ok }} run: yarn lerna:publish from-package --dist-tag nightly --no-verify-access --yes From 4a8348f338c7836f017c55c1767be9583af7042c Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 3 May 2023 07:52:51 +0000 Subject: [PATCH 24/49] chore(deps-dev): bump webpack from 5.74.0 to 5.76.0 Bumps [webpack](https://github.com/webpack/webpack) from 5.74.0 to 5.76.0. - [Release notes](https://github.com/webpack/webpack/releases) - [Commits](https://github.com/webpack/webpack/compare/v5.74.0...v5.76.0) --- updated-dependencies: - dependency-name: webpack dependency-type: direct:development ... Signed-off-by: dependabot[bot] --- yarn.lock | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/yarn.lock b/yarn.lock index 23535f9..2ca53a1 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1958,12 +1958,7 @@ acorn@^7.1.1: resolved "https://registry.yarnpkg.com/acorn/-/acorn-7.4.1.tgz#feaed255973d2e77555b83dbc08851a6c63520fa" integrity sha512-nQyp0o1/mNdbTO1PO6kHkwSrmgZ0MT/jCCpNiwbUjGoRN4dlBhqJtoQuCnEOKzgTVwg0ZWiCoQy6SxMebQVh8A== -acorn@^8.2.4, acorn@^8.5.0: - version "8.7.0" - resolved "https://registry.yarnpkg.com/acorn/-/acorn-8.7.0.tgz#90951fde0f8f09df93549481e5fc141445b791cf" - integrity sha512-V/LGr1APy+PXIwKebEWrkZPwoeoF+w1jiOBUmuxuiUIaOHtob8Qc9BTrYo7VuI5fR8tqsy+buA2WFooR5olqvQ== - -acorn@^8.7.1: +acorn@^8.2.4, acorn@^8.5.0, acorn@^8.7.1: version "8.7.1" resolved "https://registry.yarnpkg.com/acorn/-/acorn-8.7.1.tgz#0197122c843d1bf6d0a5e83220a788f278f63c30" integrity sha512-Xx54uLJQZ19lKygFXOWsscKUbsBZW0CPykPhVQdhIeIwrbPmJzqeASDInc8nKBnp/JT6igTs82qPXz069H8I/A== @@ -10348,9 +10343,9 @@ webpack-sources@^3.2.3: integrity sha512-/DyMEOrDgLKKIG0fmvtz+4dUX/3Ghozwgm6iPp8KRhvn+eQf9+Q7GWxVNMk3+uCPWfdXYC4ExGBckIXdFEfH1w== webpack@^5.74.0: - version "5.74.0" - resolved "https://registry.yarnpkg.com/webpack/-/webpack-5.74.0.tgz#02a5dac19a17e0bb47093f2be67c695102a55980" - integrity sha512-A2InDwnhhGN4LYctJj6M1JEaGL7Luj6LOmyBHjcI8529cm5p6VXiTIW2sn6ffvEAKmveLzvu4jrihwXtPojlAA== + version "5.76.0" + resolved "https://registry.yarnpkg.com/webpack/-/webpack-5.76.0.tgz#f9fb9fb8c4a7dbdcd0d56a98e56b8a942ee2692c" + integrity sha512-l5sOdYBDunyf72HW8dF23rFtWq/7Zgvt/9ftMof71E/yUb1YLOBmTgA2K4vQthB3kotMrSj609txVE0dnr2fjA== dependencies: "@types/eslint-scope" "^3.7.3" "@types/estree" "^0.0.51" From fd5c595208d303bc32bc9a2a73d531bc25383a24 Mon Sep 17 00:00:00 2001 From: Johan Nyman Date: Wed, 3 May 2023 10:05:00 +0200 Subject: [PATCH 25/49] v3.0.0 --- CHANGELOG.md | 6 +++++- lerna.json | 2 +- packages/core/CHANGELOG.md | 9 ++++----- packages/core/package.json | 2 +- packages/node-record-test/CHANGELOG.md | 4 +++- packages/node-record-test/package.json | 6 +++--- packages/node/CHANGELOG.md | 14 ++++++-------- packages/node/package.json | 4 ++-- packages/webhid-demo/CHANGELOG.md | 4 +++- packages/webhid-demo/package.json | 4 ++-- packages/webhid/CHANGELOG.md | 4 +++- packages/webhid/package.json | 4 ++-- 12 files changed, 35 insertions(+), 28 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 609bb04..2f545cf 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -3,7 +3,11 @@ All notable changes to this project will be documented in this file. See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. -# [3.0.0-alpha.0](https://github.com/SuperFlyTV/xkeys/compare/v2.3.4...v3.0.0-alpha.0) (2022-06-22) +# [3.0.0](https://github.com/SuperFlyTV/xkeys/compare/v2.4.0...v3.0.0) (2023-05-03) + +### Bug Fixes + +- issue with trackball ([5e2021a](https://github.com/SuperFlyTV/xkeys/commit/5e2021af49d12a7367d39f638c375210db343714)) ### Features diff --git a/lerna.json b/lerna.json index cf98193..7028971 100644 --- a/lerna.json +++ b/lerna.json @@ -4,5 +4,5 @@ ], "npmClient": "yarn", "useWorkspaces": true, - "version": "3.0.0-alpha.0" + "version": "3.0.0" } diff --git a/packages/core/CHANGELOG.md b/packages/core/CHANGELOG.md index 007327e..fde7cd2 100644 --- a/packages/core/CHANGELOG.md +++ b/packages/core/CHANGELOG.md @@ -1,21 +1,20 @@ # Change Log +**NOTE: (The full changelog is published here!)[https://github.com/SuperFlyTV/xkeys/blob/master/CHANGELOG.md]** + All notable changes to this project will be documented in this file. See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. -## [3.0.0-alpha.0](https://github.com/SuperFlyTV/xkeys/compare/v2.3.4...v3.0.0-alpha.0) (2022-06-22) +# [3.0.0](https://github.com/SuperFlyTV/xkeys/compare/v2.4.0...v3.0.0) (2023-05-03) ### Bug Fixes - issue with trackball ([5e2021a](https://github.com/SuperFlyTV/xkeys/commit/5e2021af49d12a7367d39f638c375210db343714)) + # [2.4.0](https://github.com/SuperFlyTV/xkeys/compare/v2.3.4...v2.4.0) (2022-10-26) **Note:** Version bump only for package @xkeys-lib/core - - - - ## [2.3.4](https://github.com/SuperFlyTV/xkeys/compare/v2.3.3...v2.3.4) (2022-06-06) **Note:** Version bump only for package @xkeys-lib/core diff --git a/packages/core/package.json b/packages/core/package.json index ccfab8a..0ad3df3 100644 --- a/packages/core/package.json +++ b/packages/core/package.json @@ -1,6 +1,6 @@ { "name": "@xkeys-lib/core", - "version": "3.0.0-alpha.0", + "version": "3.0.0", "description": "NPM package to interact with the X-keys panels", "main": "dist/index.js", "typings": "dist/index.d.ts", diff --git a/packages/node-record-test/CHANGELOG.md b/packages/node-record-test/CHANGELOG.md index d5ea3ee..c7e462a 100644 --- a/packages/node-record-test/CHANGELOG.md +++ b/packages/node-record-test/CHANGELOG.md @@ -1,9 +1,11 @@ # Change Log +**NOTE: (The full changelog is published here!)[https://github.com/SuperFlyTV/xkeys/blob/master/CHANGELOG.md]** + All notable changes to this project will be documented in this file. See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. -## [3.0.0-alpha.0](https://github.com/SuperFlyTV/xkeys/compare/v2.3.4...v3.0.0-alpha.0) (2022-06-22) +# [3.0.0](https://github.com/SuperFlyTV/xkeys/compare/v2.4.0...v3.0.0) (2023-05-03) **Note:** Version bump only for package @xkeys-lib/record-test diff --git a/packages/node-record-test/package.json b/packages/node-record-test/package.json index 8cb899a..67b1a80 100644 --- a/packages/node-record-test/package.json +++ b/packages/node-record-test/package.json @@ -1,6 +1,6 @@ { "name": "@xkeys-lib/record-test", - "version": "3.0.0-alpha.0", + "version": "3.0.0", "private": true, "description": "A script for recording tests", "main": "dist/index.js", @@ -51,10 +51,10 @@ "controller" ], "dependencies": { - "@xkeys-lib/core": "3.0.0-alpha.0", + "@xkeys-lib/core": "3.0.0", "readline": "^1.3.0", "tslib": "^2.4.0", - "xkeys": "3.0.0-alpha.0" + "xkeys": "3.0.0" }, "optionalDependencies": { "find": "^0.3.0", diff --git a/packages/node/CHANGELOG.md b/packages/node/CHANGELOG.md index ad697e8..bd03bfd 100644 --- a/packages/node/CHANGELOG.md +++ b/packages/node/CHANGELOG.md @@ -1,25 +1,23 @@ # Change Log +**NOTE: (The full changelog is published here!)[https://github.com/SuperFlyTV/xkeys/blob/master/CHANGELOG.md]** + All notable changes to this project will be documented in this file. See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. -## [3.0.0-alpha.0](https://github.com/SuperFlyTV/xkeys/compare/v2.3.4...v3.0.0-alpha.0) (2022-06-22) +# [3.0.0](https://github.com/SuperFlyTV/xkeys/compare/v2.4.0...v3.0.0) (2023-05-03) -**Note:** Version bump only for package xkeys +- BREAKING CHANGE: Dropped support for EOL versions of Node.js (<14). # [2.4.0](https://github.com/SuperFlyTV/xkeys/compare/v2.3.4...v2.4.0) (2022-10-26) - ### Bug Fixes -* update usb dep ([e1bc906](https://github.com/SuperFlyTV/xkeys/commit/e1bc9060e4ef82dce690a2bb76fb01601ed28f7a)) - +- update usb dep ([e1bc906](https://github.com/SuperFlyTV/xkeys/commit/e1bc9060e4ef82dce690a2bb76fb01601ed28f7a)) ### Features -* replace usb-detection with usb ([d6349ef](https://github.com/SuperFlyTV/xkeys/commit/d6349ef0b0477045dd8a540887918cc2af8370aa)) - - +- replace usb-detection with usb ([d6349ef](https://github.com/SuperFlyTV/xkeys/commit/d6349ef0b0477045dd8a540887918cc2af8370aa)) ## [2.3.4](https://github.com/SuperFlyTV/xkeys/compare/v2.3.3...v2.3.4) (2022-06-06) diff --git a/packages/node/package.json b/packages/node/package.json index a8cbb37..ec2259d 100644 --- a/packages/node/package.json +++ b/packages/node/package.json @@ -1,6 +1,6 @@ { "name": "xkeys", - "version": "3.0.0-alpha.0", + "version": "3.0.0", "description": "An npm module for interfacing with the X-keys panels in Node.js", "main": "dist/index.js", "typings": "dist/index.d.ts", @@ -51,7 +51,7 @@ ], "dependencies": { "@types/node-hid": "^1.3.1", - "@xkeys-lib/core": "3.0.0-alpha.0", + "@xkeys-lib/core": "3.0.0", "node-hid": "^2.1.1", "tslib": "^2.4.0" }, diff --git a/packages/webhid-demo/CHANGELOG.md b/packages/webhid-demo/CHANGELOG.md index 8cc2d67..4d21995 100644 --- a/packages/webhid-demo/CHANGELOG.md +++ b/packages/webhid-demo/CHANGELOG.md @@ -1,9 +1,11 @@ # Change Log +**NOTE: (The full changelog is published here!)[https://github.com/SuperFlyTV/xkeys/blob/master/CHANGELOG.md]** + All notable changes to this project will be documented in this file. See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. -## [3.0.0-alpha.0](https://github.com/SuperFlyTV/xkeys/compare/v2.3.4...v3.0.0-alpha.0) (2022-06-22) +# [3.0.0](https://github.com/SuperFlyTV/xkeys/compare/v2.4.0...v3.0.0) (2023-05-03) **Note:** Version bump only for package @xkeys-lib/webhid-demo diff --git a/packages/webhid-demo/package.json b/packages/webhid-demo/package.json index edacaba..510f722 100644 --- a/packages/webhid-demo/package.json +++ b/packages/webhid-demo/package.json @@ -1,6 +1,6 @@ { "name": "@xkeys-lib/webhid-demo", - "version": "3.0.0-alpha.0", + "version": "3.0.0", "private": true, "license": "MIT", "homepage": "https://github.com/SuperFlyTV/xkeys#readme", @@ -22,7 +22,7 @@ }, "dependencies": { "buffer": "^6.0.3", - "xkeys-webhid": "3.0.0-alpha.0" + "xkeys-webhid": "3.0.0" }, "devDependencies": { "copy-webpack-plugin": "^7.0.0", diff --git a/packages/webhid/CHANGELOG.md b/packages/webhid/CHANGELOG.md index 86e9906..29b5a52 100644 --- a/packages/webhid/CHANGELOG.md +++ b/packages/webhid/CHANGELOG.md @@ -1,9 +1,11 @@ # Change Log +**NOTE: (The full changelog is published here!)[https://github.com/SuperFlyTV/xkeys/blob/master/CHANGELOG.md]** + All notable changes to this project will be documented in this file. See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. -## [3.0.0-alpha.0](https://github.com/SuperFlyTV/xkeys/compare/v2.3.4...v3.0.0-alpha.0) (2022-06-22) +# [3.0.0](https://github.com/SuperFlyTV/xkeys/compare/v2.4.0...v3.0.0) (2023-05-03) **Note:** Version bump only for package xkeys-webhid diff --git a/packages/webhid/package.json b/packages/webhid/package.json index 6c5526f..44130ef 100644 --- a/packages/webhid/package.json +++ b/packages/webhid/package.json @@ -1,6 +1,6 @@ { "name": "xkeys-webhid", - "version": "3.0.0-alpha.0", + "version": "3.0.0", "description": "An npm module for interfacing with the X-keys panels in a browser", "main": "dist/index.js", "typings": "dist/index.d.ts", @@ -38,7 +38,7 @@ ], "dependencies": { "@types/w3c-web-hid": "^1.0.3", - "@xkeys-lib/core": "3.0.0-alpha.0", + "@xkeys-lib/core": "3.0.0", "buffer": "^6.0.3", "p-queue": "^6.6.2" }, From c9a865d982fc4dc69446496ecff3445c42b9bc2e Mon Sep 17 00:00:00 2001 From: Johan Nyman Date: Wed, 3 May 2023 10:13:43 +0200 Subject: [PATCH 26/49] chore: lint --- packages/core/src/products.ts | 1 - 1 file changed, 1 deletion(-) diff --git a/packages/core/src/products.ts b/packages/core/src/products.ts index 93272d5..4366a5c 100644 --- a/packages/core/src/products.ts +++ b/packages/core/src/products.ts @@ -834,7 +834,6 @@ export const PRODUCTS: { [name: string]: Product } = { hasTbar: [ { tbarByte: 8, // value Was incorrect, 8 is correct - }, ], backLightType: BackLightType.RGBx2, //RGB 2 Bank,Standard Index From b1c6637f1770cf0ed9b5e3b278d5f01d4eaede0a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 11 Jul 2023 04:11:06 +0000 Subject: [PATCH 27/49] chore(deps): bump semver from 5.7.1 to 5.7.2 Bumps [semver](https://github.com/npm/node-semver) from 5.7.1 to 5.7.2. - [Release notes](https://github.com/npm/node-semver/releases) - [Changelog](https://github.com/npm/node-semver/blob/v5.7.2/CHANGELOG.md) - [Commits](https://github.com/npm/node-semver/compare/v5.7.1...v5.7.2) --- updated-dependencies: - dependency-name: semver dependency-type: indirect ... Signed-off-by: dependabot[bot] --- yarn.lock | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/yarn.lock b/yarn.lock index 2ca53a1..8b5cc8e 100644 --- a/yarn.lock +++ b/yarn.lock @@ -8784,21 +8784,21 @@ selfsigned@^1.10.8: node-forge "^0.10.0" "semver@2 || 3 || 4 || 5", semver@^5.4.1, semver@^5.5.0, semver@^5.6.0, semver@^5.7.1: - version "5.7.1" - resolved "https://registry.yarnpkg.com/semver/-/semver-5.7.1.tgz#a954f931aeba508d307bbf069eff0c01c96116f7" - integrity sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ== + version "5.7.2" + resolved "https://registry.yarnpkg.com/semver/-/semver-5.7.2.tgz#48d55db737c3287cd4835e17fa13feace1c41ef8" + integrity sha512-cBznnQ9KjJqU67B52RMC65CMarK2600WFnbkcaiwWq3xy/5haFJlshgnpjovMVJ+Hff49d8GEn0b87C5pDQ10g== semver@7.x, semver@^7.1.1, semver@^7.1.3, semver@^7.3.2, semver@^7.3.4, semver@^7.3.5, semver@^7.3.7: - version "7.3.7" - resolved "https://registry.yarnpkg.com/semver/-/semver-7.3.7.tgz#12c5b649afdbf9049707796e22a4028814ce523f" - integrity sha512-QlYTucUYOews+WeEujDoEGziz4K6c47V/Bd+LjSSYcA94p+DmINdf7ncaUinThfvZyu13lN9OY1XDxt8C0Tw0g== + version "7.5.4" + resolved "https://registry.yarnpkg.com/semver/-/semver-7.5.4.tgz#483986ec4ed38e1c6c48c34894a9182dbff68a6e" + integrity sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA== dependencies: lru-cache "^6.0.0" semver@^6.0.0, semver@^6.1.0, semver@^6.3.0: - version "6.3.0" - resolved "https://registry.yarnpkg.com/semver/-/semver-6.3.0.tgz#ee0a64c8af5e8ceea67687b133761e1becbd1d3d" - integrity sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw== + version "6.3.1" + resolved "https://registry.yarnpkg.com/semver/-/semver-6.3.1.tgz#556d2ef8689146e46dcea4bfdd095f3434dffcb4" + integrity sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA== send@0.18.0: version "0.18.0" From 10c3cfbbc8e4c4be8468e1b78040e6d684d3c425 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 19 Jul 2023 00:09:20 +0000 Subject: [PATCH 28/49] chore(deps): bump word-wrap from 1.2.3 to 1.2.4 Bumps [word-wrap](https://github.com/jonschlinkert/word-wrap) from 1.2.3 to 1.2.4. - [Release notes](https://github.com/jonschlinkert/word-wrap/releases) - [Commits](https://github.com/jonschlinkert/word-wrap/compare/1.2.3...1.2.4) --- updated-dependencies: - dependency-name: word-wrap dependency-type: indirect ... Signed-off-by: dependabot[bot] --- yarn.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/yarn.lock b/yarn.lock index 8b5cc8e..fb699a1 100644 --- a/yarn.lock +++ b/yarn.lock @@ -10458,9 +10458,9 @@ wildcard@^2.0.0: integrity sha512-JcKqAHLPxcdb9KM49dufGXn2x3ssnfjbcaQdLlfZsL9rH9wgDQjUtDxbo8NE0F6SFvydeu1VhZe7hZuHsB2/pw== word-wrap@^1.2.3, word-wrap@~1.2.3: - version "1.2.3" - resolved "https://registry.yarnpkg.com/word-wrap/-/word-wrap-1.2.3.tgz#610636f6b1f703891bd34771ccb17fb93b47079c" - integrity sha512-Hz/mrNwitNRh/HUAtM/VT/5VH+ygD6DV7mYKZAtHOrbs8U7lvPS6xf7EJKMF0uW1KJCl0H701g3ZGus+muE5vQ== + version "1.2.4" + resolved "https://registry.yarnpkg.com/word-wrap/-/word-wrap-1.2.4.tgz#cb4b50ec9aca570abd1f52f33cd45b6c61739a9f" + integrity sha512-2V81OA4ugVo5pRo46hAoD2ivUJx8jXmWXfUkY4KFNw0hEptvN0QfH3K4nHiwzGeKl5rFKedV48QVoqYavy4YpA== wordwrap@^1.0.0: version "1.0.0" From 7381264dd0f48008df1268422153e4d30c101f84 Mon Sep 17 00:00:00 2001 From: Peter Newman Date: Wed, 9 Aug 2023 12:50:34 +0100 Subject: [PATCH 29/49] Fix some typos in README.md --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 62d4933..9976bba 100644 --- a/README.md +++ b/README.md @@ -312,7 +312,7 @@ xkeysPanel.setFrequency(8) ```javascript // Sets the UID (unit Id) value in the X-keys hardware -// Note: This writes to the EEPROM, don't call this function too often, or you'll kill thEEPROM! (An EEPROM only support a few thousands of write operations.) +// Note: This writes to the EEPROM, don't call this function too often, or you'll kill the EEPROM! (An EEPROM only support a few thousands of write operations.) xkeysPanel.setUnitId(unitId) ``` @@ -320,7 +320,7 @@ xkeysPanel.setUnitId(unitId) ```javascript // Save the backlights (so they are restored to this after a power cycle). -// Note: This writes to the EEPROM, don't call this function too often, or you'll kill thEEPROM! (An EEPROM only support a few thousands of write operations.) +// Note: This writes to the EEPROM, don't call this function too often, or you'll kill the EEPROM! (An EEPROM only support a few thousands of write operations.) xkeysPanel.saveBackLights() ``` From 18888e43ef76ac0e3a9abdf41251231b65bafe41 Mon Sep 17 00:00:00 2001 From: Peter Newman Date: Wed, 9 Aug 2023 13:16:49 +0100 Subject: [PATCH 30/49] Add codespell to lint run --- .github/workflows/lint-and-test.yml | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/.github/workflows/lint-and-test.yml b/.github/workflows/lint-and-test.yml index 24092cc..4b67a25 100644 --- a/.github/workflows/lint-and-test.yml +++ b/.github/workflows/lint-and-test.yml @@ -40,6 +40,22 @@ jobs: env: CI: true + # GitHub Action to automate the identification of common misspellings in text files. + # https://github.com/codespell-project/actions-codespell + # https://github.com/codespell-project/codespell + codespell: + name: Check for spelling errors + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + with: + persist-credentials: false + - uses: codespell-project/actions-codespell@master + with: + check_filenames: true + # When using this Action in other repos, the --skip option below can be removed + skip: "./.git,./codespell_lib/data,./example/code.c,test_basic.py,*.pyc,README.rst,pyproject-codespell.precommit-toml" + test: name: Test on node ${{ matrix.node_version }} and ${{ matrix.os }} runs-on: ${{ matrix.os }} From f5d53201c0e0aeffa2686d3f9abe0e52f34489ff Mon Sep 17 00:00:00 2001 From: Peter Newman Date: Wed, 9 Aug 2023 13:25:59 +0100 Subject: [PATCH 31/49] Fix some typos --- README.md | 2 +- packages/core/src/api.ts | 2 +- packages/core/src/products.ts | 14 +++++++------- packages/core/src/xkeys.ts | 8 ++++---- packages/node/examples/multiple-panels.js | 2 +- packages/node/src/watcher.ts | 6 +++--- scripts/install-ci.js | 2 +- 7 files changed, 18 insertions(+), 18 deletions(-) diff --git a/README.md b/README.md index 62d4933..b099bcf 100644 --- a/README.md +++ b/README.md @@ -441,7 +441,7 @@ If you're adding a new functionality, adding unit tests for it is much appreciat #### Making a Pre-release -- Update the branch (preferrably the master branch) +- Update the branch (preferably the master branch) - `yarn release:bump-prerelease` and push the changes (including the tag) - Trigger a run of [CI: publish-prerelease](https://github.com/SuperFlyTV/xkeys/actions/workflows/publish-prerelease.yml) diff --git a/packages/core/src/api.ts b/packages/core/src/api.ts index 2dffc9a..21d0ca9 100644 --- a/packages/core/src/api.ts +++ b/packages/core/src/api.ts @@ -119,7 +119,7 @@ export interface XKeysInfo { /** If the X-keys panel emits timestamps (if not, timestamp will be undefined) */ emitsTimestamp: boolean - /** If the product has the Program Switch button, this is a special switch not in the normal switch matrix. If exsists, only one per X-keys. */ + /** If the product has the Program Switch button, this is a special switch not in the normal switch matrix. If exists, only one per X-keys. */ hasPS: boolean /** The number of joysticks available on the device */ hasJoystick: number diff --git a/packages/core/src/products.ts b/packages/core/src/products.ts index 4366a5c..75e182e 100644 --- a/packages/core/src/products.ts +++ b/packages/core/src/products.ts @@ -22,7 +22,7 @@ export interface Product { colCount: number /** The number of physical rows */ rowCount: number - /** If the X-keys panel has the Program Switch button. This is a special switch not in the normal switch matrix, if exsists, there's only ever one per panel. */ + /** If the X-keys panel has the Program Switch button. This is a special switch not in the normal switch matrix, if exists, there's only ever one per panel. */ hasPS: boolean /** Byte offset for legacy backLight, bank 2 */ backLight2offset: number @@ -183,7 +183,7 @@ export const PRODUCTS: { [name: string]: Product } = { [1213, 0], [1216, 0], ], - bBytes: 4, // 4 buttton data bytes + bBytes: 4, // 4 button data bytes bBits: 4, // not really rows, but the data comes like that (it is physically one row) row1= 0,1,2,3 row2=4,5,6,7 row3= 8,9,10,11 row4=12,13,14,15 colCount: 16, // number of physical columns rowCount: 1, // number of physical rows @@ -286,7 +286,7 @@ export const PRODUCTS: { [name: string]: Product } = { [1279, 0], [1282, 0], ], - bBytes: 4, // 4 buttton data bytes + bBytes: 4, // 4 button data bytes bBits: 8, colCount: 16, // number of physical columns, rowCount: 2, // number of physical rows @@ -306,7 +306,7 @@ export const PRODUCTS: { [name: string]: Product } = { [1360, 0], [1361, 0], ], - bBytes: 5, // 5 buttton data bytes + bBytes: 5, // 5 button data bytes bBits: 8, // row1=0,8,16,24,32 row2=1,9,17,25,33 row3=2,10,18,26,34 row4=3,11,19,27,35 row5=4,12,20,28,36 row6=5,13,21,29,37 row7=6,14,22,30,38 row8=7,15,23,31,39 colCount: 20, // number of physical columns, rowCount: 2, // number of physical rows @@ -497,7 +497,7 @@ export const PRODUCTS: { [name: string]: Product } = { timestampByte: 18, // ms time since device boot 4 byte BE btnLocation: [ [0, 0], - [0, 0], // the keyIndex of 1 on this panel does not exsit + [0, 0], // the keyIndex of 1 on this panel does not exist [1, 1], [1, 2], [1, 3], @@ -526,7 +526,7 @@ export const PRODUCTS: { [name: string]: Product } = { [2, 0], [1, 3], ], // bit 3 has been mapped to R1,C0 this is the bit that is set if any plug is in the 3.5 mm socket. Helps tell between no switch attached or just no switches pressed. - disableButtons: [4], // Exclude index 4, redundent on index 3, note some or all of the buttons may be triggered when plugging switch into 3.5 mm socket + disableButtons: [4], // Exclude index 4, redundant on index 3, note some or all of the buttons may be triggered when plugging switch into 3.5 mm socket }), XK12SI: literal({ name: 'XK-12 Switch Interface', // six 3.5 mm ports, contacts for a stereo Plug @@ -1099,7 +1099,7 @@ export const PRODUCTS: { [name: string]: Product } = { [210, 0], [210, -1], ], - bBytes: 6, // this asssumes the button bytes will be remapped. + bBytes: 6, // this assumes the button bytes will be remapped. bBits: 8, // see documentation layouts: [ ['Cab Buttons', 0, 1, 1, 2, 4], diff --git a/packages/core/src/xkeys.ts b/packages/core/src/xkeys.ts index eaa31e6..9f50059 100644 --- a/packages/core/src/xkeys.ts +++ b/packages/core/src/xkeys.ts @@ -131,7 +131,7 @@ export class XKeys extends EventEmitter { } // TODO: Add other special reports here. // A standard data report will be sent when something physical happens on the keys, button press, or lever moved for example - // other special reports may be sent in responce to a request or some data input on the device. + // other special reports may be sent in response to a request or some data input on the device. // if (data.readUInt8(1) > 3) return // Protect against all special data reports now and into the future. @@ -452,7 +452,7 @@ export class XKeys extends EventEmitter { const location = this._findBtnLocation(keyIndex) if (this.product.backLightType === BackLightType.REMAP_24) { - // obsloete, Consier removing MHH + // obsloete, Consider removing MHH const ledIndex = (location.col - 1) * 8 + location.row - 1 // backlight LED type 5 is the RGB 24 buttons this._write([0, 181, ledIndex, color.g, color.r, color.b, flashing ? 1 : 0]) // Byte order is actually G,R,B,F) @@ -619,7 +619,7 @@ export class XKeys extends EventEmitter { liteByte = 0 } byteVals[3] = liteByte // set the LCD backlight on or off. - // loop throught the string and load array with acsii byte values + // loop through the string and load array with acsii byte values let i for (i = 0; i < displayChar.length; i++) { byteVals[i + 4] = displayChar.charCodeAt(i) @@ -803,7 +803,7 @@ export class XKeys extends EventEmitter { private ensureInitialized() { if (!this._initialized) throw new Error('XKeys.init() must be run first!') } - /** Calcuate delta value */ + /** Calculate delta value */ static calculateDelta(newValue: number, oldValue: number, overflow = 256): number { let delta = newValue - oldValue if (delta < -overflow * 0.5) delta += overflow // Deal with when the new value overflows diff --git a/packages/node/examples/multiple-panels.js b/packages/node/examples/multiple-panels.js index 1ab51f4..7c9377c 100644 --- a/packages/node/examples/multiple-panels.js +++ b/packages/node/examples/multiple-panels.js @@ -12,7 +12,7 @@ const { XKeysWatcher } = require('xkeys') To reset the unitId of the panels, run the reset-unitId.js example. */ -/** A persistant memory to store data for connected panels */ +/** A persistent memory to store data for connected panels */ const memory = {} // Set up the watcher for xkeys: diff --git a/packages/node/src/watcher.ts b/packages/node/src/watcher.ts index d4743a9..9fcafe8 100644 --- a/packages/node/src/watcher.ts +++ b/packages/node/src/watcher.ts @@ -24,7 +24,7 @@ function USBDetect(): typeof usb { // else emit error: throw `XKeysWatcher requires the dependency "usb" to be installed, it might have been skipped due to your platform being unsupported (this is an issue with "usb", not the X-keys library). Possible solutions are: -* You can try to install the depencency manually, by running "npm install usb". +* You can try to install the dependency manually, by running "npm install usb". * Use the fallback "usePolling" functionality instead: new XKeysWatcher({ usePolling: true}) * Otherwise you can still connect to X-keys panels manually by using XKeys.setupXkeysPanel(). ` @@ -170,7 +170,7 @@ export class XKeysWatcher extends EventEmitter { this.debugLog('updateConnectedDevices') // Note: // This implementation is a bit awkward, - // there isnt a good way to relate the output from usb to node-hid devices + // there isn't a good way to relate the output from usb to node-hid devices // So we're just using the events to trigger a re-check for new devices and cache the seen devices listAllConnectedPanels().forEach((xkeysDevice) => { @@ -236,7 +236,7 @@ export class XKeysWatcher extends EventEmitter { if (this.options?.automaticUnitIdMode) { if (xkeysPanel.unitId === 0) { // if it is 0, we assume that it's new from the factory and can be safely changed - xkeysPanel.setUnitId(this._getNextUniqueId(xkeysPanel)) // the lookup-cache is stored either in memory, or preferrably on disk + xkeysPanel.setUnitId(this._getNextUniqueId(xkeysPanel)) // the lookup-cache is stored either in memory, or preferably on disk } // the PID+UID pair is enough to uniquely identify a panel. const uniqueIdentifier: string = xkeysPanel.uniqueId diff --git a/scripts/install-ci.js b/scripts/install-ci.js index ba26cb9..b35319e 100644 --- a/scripts/install-ci.js +++ b/scripts/install-ci.js @@ -5,7 +5,7 @@ const { exec } = require('child_process') const fsReadFile = promisify(fs.readFile) const fsWriteFile = promisify(fs.writeFile) -// This function installs all dependencies exept node-hid +// This function installs all dependencies except node-hid // It is used during CI/tests, where the binaries aren't used anyway function run(command) { From 60e142ce3dfc7ce4f5e05b62a41fb1a3d0bf1ebb Mon Sep 17 00:00:00 2001 From: Peter Newman Date: Wed, 9 Aug 2023 13:32:26 +0100 Subject: [PATCH 32/49] Fix more typos --- packages/core/src/products.ts | 4 ++-- packages/core/src/xkeys.ts | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/packages/core/src/products.ts b/packages/core/src/products.ts index 75e182e..81ffe4e 100644 --- a/packages/core/src/products.ts +++ b/packages/core/src/products.ts @@ -114,7 +114,7 @@ export const PRODUCTS: { [name: string]: Product } = { ], bBytes: 4, // number of button bytes bBits: 6, // number button bits per byte - layouts: [['Keys', 0, 1, 1, 6, 4]], // reigon type name, index, startRow, startCol, endRow, endCol + layouts: [['Keys', 0, 1, 1, 6, 4]], // region type name, index, startRow, startCol, endRow, endCol colCount: 4, // number of physical columns rowCount: 6, // number of physical rows hasPS: true, @@ -262,7 +262,7 @@ export const PRODUCTS: { [name: string]: Product } = { layouts: [ ['Keys', 0, 1, 1, 8, 10], ['Joystick', 0, 4, 4, 6, 7], - ], // reigon type name, index, startRow, startCol, endRow, endCol + ], // region type name, index, startRow, startCol, endRow, endCol colCount: 10, // number of physical columns, rowCount: 8, // number of physical rows hasPS: true, diff --git a/packages/core/src/xkeys.ts b/packages/core/src/xkeys.ts index 9f50059..84189fc 100644 --- a/packages/core/src/xkeys.ts +++ b/packages/core/src/xkeys.ts @@ -127,7 +127,7 @@ export class XKeys extends EventEmitter { this.receivedVersionResolve?.() - return // quit here because this data would be interperted as button data and give bad results. + return // quit here because this data would be interpreted as button data and give bad results. } // TODO: Add other special reports here. // A standard data report will be sent when something physical happens on the keys, button press, or lever moved for example @@ -374,7 +374,7 @@ export class XKeys extends EventEmitter { interface: this.product.interface, unitId: this.unitId, - firmwareVersion: this._firmwareVersion, // added this imporant to defend against older firmware bugs + firmwareVersion: this._firmwareVersion, // added this important to defend against older firmware bugs colCount: this.product.colCount, rowCount: this.product.rowCount, @@ -733,7 +733,7 @@ export class XKeys extends EventEmitter { this._write([0, 177]) } /** - * Gets the frimware version and UID : forces the unit to send a special data report with firmware version and Unit ID. + * Gets the firmware version and UID : forces the unit to send a special data report with firmware version and Unit ID. * @param none * @returns undefined //an input report will be generated by the X-keys with byte 2 set to 214. This has the firmware version and UID. */ From 2496351f0d25e34780dbb0147938c139175409eb Mon Sep 17 00:00:00 2001 From: Peter Newman Date: Wed, 9 Aug 2023 13:32:51 +0100 Subject: [PATCH 33/49] Ignore a false positive and a file --- .github/workflows/lint-and-test.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/lint-and-test.yml b/.github/workflows/lint-and-test.yml index 4b67a25..2dc41b7 100644 --- a/.github/workflows/lint-and-test.yml +++ b/.github/workflows/lint-and-test.yml @@ -53,8 +53,8 @@ jobs: - uses: codespell-project/actions-codespell@master with: check_filenames: true - # When using this Action in other repos, the --skip option below can be removed - skip: "./.git,./codespell_lib/data,./example/code.c,test_basic.py,*.pyc,README.rst,pyproject-codespell.precommit-toml" + skip: "./.git,./yarn.lock" + ignore_words_list: ans test: name: Test on node ${{ matrix.node_version }} and ${{ matrix.os }} From 7fc348bbaaf1056de050c1df6a06718cf0d1d87d Mon Sep 17 00:00:00 2001 From: Peter Newman Date: Wed, 9 Aug 2023 14:17:56 +0100 Subject: [PATCH 34/49] Fix another minor typo --- packages/core/src/xkeys.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/core/src/xkeys.ts b/packages/core/src/xkeys.ts index 84189fc..87f10a0 100644 --- a/packages/core/src/xkeys.ts +++ b/packages/core/src/xkeys.ts @@ -78,7 +78,7 @@ export class XKeys extends EventEmitter { this.device.on('data', (data: Buffer) => { if (deviceInfo.productId === 210) { - // Note: THe RailDriver is an older device, which doesn't follow the rest of xkeys data structure. + // Note: The RailDriver is an older device, which doesn't follow the rest of xkeys data structure. // To make it easy for us, we'll just remap the data to work for us. const rdData = new Uint8Array(32) From a95e99153c8238f44b6d75cfe5d76c7d2d286788 Mon Sep 17 00:00:00 2001 From: Peter Newman Date: Wed, 9 Aug 2023 15:11:28 +0100 Subject: [PATCH 35/49] Fix another typo --- packages/core/src/xkeys.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/core/src/xkeys.ts b/packages/core/src/xkeys.ts index 87f10a0..ab1c209 100644 --- a/packages/core/src/xkeys.ts +++ b/packages/core/src/xkeys.ts @@ -452,7 +452,7 @@ export class XKeys extends EventEmitter { const location = this._findBtnLocation(keyIndex) if (this.product.backLightType === BackLightType.REMAP_24) { - // obsloete, Consider removing MHH + // obsolete, Consider removing MHH const ledIndex = (location.col - 1) * 8 + location.row - 1 // backlight LED type 5 is the RGB 24 buttons this._write([0, 181, ledIndex, color.g, color.r, color.b, flashing ? 1 : 0]) // Byte order is actually G,R,B,F) From 2c15018b162864a5c9cd6c7f960493ad8756aa5f Mon Sep 17 00:00:00 2001 From: Peter Newman Date: Wed, 9 Aug 2023 15:16:24 +0100 Subject: [PATCH 36/49] Fix a possible typo --- packages/core/src/xkeys.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/packages/core/src/xkeys.ts b/packages/core/src/xkeys.ts index eaa31e6..7749f0e 100644 --- a/packages/core/src/xkeys.ts +++ b/packages/core/src/xkeys.ts @@ -39,7 +39,7 @@ export class XKeys extends EventEmitter { private _initialized = false private _firmwareVersion = 0 // is set after init() private _firmwareVersionIsSet = false - private _unidId = 0 // is set after init() + private _unitId = 0 // is set after init() private _unitIdIsSet = false private _disconnected = false @@ -160,7 +160,7 @@ export class XKeys extends EventEmitter { if (genData) { // Note, the generateData is used to get the full state - this._unidId = UID + this._unitId = UID this._unitIdIsSet = true this.receivedGenerateDataResolve?.() @@ -361,7 +361,7 @@ export class XKeys extends EventEmitter { * From factory it's set to 0, but it can be changed using this.setUnitId() */ public get unitId(): number { - return this._unidId + return this._unitId } /** Various information about the device and its capabilities */ public get info(): XKeysInfo { @@ -585,7 +585,7 @@ export class XKeys extends EventEmitter { } this._write([0, 189, unitId]) - this._unidId = unitId + this._unitId = unitId } /** * Reboots the device From ee94a59ab96099b56e82a3aff53a217d74fdbb75 Mon Sep 17 00:00:00 2001 From: Peter Newman Date: Wed, 9 Aug 2023 16:33:45 +0100 Subject: [PATCH 37/49] Fix another minor typo --- packages/core/src/xkeys.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/core/src/xkeys.ts b/packages/core/src/xkeys.ts index ab1c209..2fc713b 100644 --- a/packages/core/src/xkeys.ts +++ b/packages/core/src/xkeys.ts @@ -54,7 +54,7 @@ export class XKeys extends EventEmitter { this.product = this._setupDevice(deviceInfo) } private _setupDevice(deviceInfo: DeviceInfo) { - const findProdct = (): { product: Product; productId: number; interface: number } => { + const findProduct = (): { product: Product; productId: number; interface: number } => { for (const product of Object.values(PRODUCTS)) { for (const hidDevice of product.hidDevices) { if ( @@ -74,7 +74,7 @@ export class XKeys extends EventEmitter { `Unknown/Unsupported X-keys: "${deviceInfo.product}" (productId: "${deviceInfo.productId}", interface: "${deviceInfo.interface}").\nPlease report this as an issue on our github page!` ) } - const found = findProdct() + const found = findProduct() this.device.on('data', (data: Buffer) => { if (deviceInfo.productId === 210) { From cdcadfc06290e0d4ecd1e3724d4eab57284ee85d Mon Sep 17 00:00:00 2001 From: Peter Newman Date: Wed, 9 Aug 2023 16:51:44 +0100 Subject: [PATCH 38/49] Fix another minor typo --- packages/core/src/products.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/core/src/products.ts b/packages/core/src/products.ts index 81ffe4e..1610088 100644 --- a/packages/core/src/products.ts +++ b/packages/core/src/products.ts @@ -451,7 +451,7 @@ export const PRODUCTS: { [name: string]: Product } = { colCount: 16, // number of virtual columns rowCount: 8, // number of virtual rows hasPS: true, // slide switch on board - backLightType: BackLightType.NONE, // no back light, only the 2 standard indicator LEDs, also availe on header, see documentation + backLightType: BackLightType.NONE, // no back light, only the 2 standard indicator LEDs, also available on header, see documentation backLight2offset: 0, timestampByte: 18, // ms time since device boot 4 byte BE // many buttons may be disabled or not as the custom wiring determines this. From f29e903d8977b8fd89e01ee8314b399c37bcd29a Mon Sep 17 00:00:00 2001 From: Johan Nyman Date: Mon, 21 Aug 2023 07:34:27 +0200 Subject: [PATCH 39/49] chore: fix "build-record-test" script. closes #90 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index b6836c4..e9f0112 100644 --- a/package.json +++ b/package.json @@ -19,7 +19,7 @@ "send-coverage": "jest && codecov", "release:bump-release": "lerna version --exact --conventional-commits --conventional-graduate --no-push", "release:bump-prerelease": "lerna version --exact --conventional-commits --conventional-prerelease --no-push", - "build-record-test": "lerna exec build-record-test", + "build-record-test": "cd packages/node-record-test && yarn build-record-test", "lerna:version": "lerna version --exact", "lerna:publish": "lerna publish", "lerna": "lerna" From 0e2eb807df821e5ff57f12e5f05c6ceb9b62a74e Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 1 Nov 2023 15:42:12 +0000 Subject: [PATCH 40/49] chore(deps): bump @babel/traverse from 7.18.9 to 7.23.2 (#91) Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- yarn.lock | 136 +++++++++++++++++++++++++++++++++++++++++++++--------- 1 file changed, 113 insertions(+), 23 deletions(-) diff --git a/yarn.lock b/yarn.lock index fb699a1..715be9d 100644 --- a/yarn.lock +++ b/yarn.lock @@ -17,6 +17,14 @@ dependencies: "@babel/highlight" "^7.18.6" +"@babel/code-frame@^7.22.13": + version "7.22.13" + resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.22.13.tgz#e3c1c099402598483b7a8c46a721d1038803755e" + integrity sha512-XktuhWlJ5g+3TJXc5upd9Ks1HutSArik6jf2eAjYFyIOf4ej3RN+184cZbzDvbPnuTJIUhPKKJE3cIsYTiAT3w== + dependencies: + "@babel/highlight" "^7.22.13" + chalk "^2.4.2" + "@babel/compat-data@^7.18.8": version "7.18.8" resolved "https://registry.yarnpkg.com/@babel/compat-data/-/compat-data-7.18.8.tgz#2483f565faca607b8535590e84e7de323f27764d" @@ -52,6 +60,16 @@ "@jridgewell/gen-mapping" "^0.3.2" jsesc "^2.5.1" +"@babel/generator@^7.23.0": + version "7.23.0" + resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.23.0.tgz#df5c386e2218be505b34837acbcb874d7a983420" + integrity sha512-lN85QRR+5IbYrMWM6Y4pE/noaQtg4pNiqeNGX60eqOfo6gtEj6uw/JagelB8vVztSd7R6M5n1+PQkDbHbBRU4g== + dependencies: + "@babel/types" "^7.23.0" + "@jridgewell/gen-mapping" "^0.3.2" + "@jridgewell/trace-mapping" "^0.3.17" + jsesc "^2.5.1" + "@babel/helper-compilation-targets@^7.18.9": version "7.18.9" resolved "https://registry.yarnpkg.com/@babel/helper-compilation-targets/-/helper-compilation-targets-7.18.9.tgz#69e64f57b524cde3e5ff6cc5a9f4a387ee5563bf" @@ -67,20 +85,25 @@ resolved "https://registry.yarnpkg.com/@babel/helper-environment-visitor/-/helper-environment-visitor-7.18.9.tgz#0c0cee9b35d2ca190478756865bb3528422f51be" integrity sha512-3r/aACDJ3fhQ/EVgFy0hpj8oHyHpQc+LPtJoY9SzTThAsStm4Ptegq92vqKoE3vD706ZVFWITnMnxucw+S9Ipg== -"@babel/helper-function-name@^7.18.9": - version "7.18.9" - resolved "https://registry.yarnpkg.com/@babel/helper-function-name/-/helper-function-name-7.18.9.tgz#940e6084a55dee867d33b4e487da2676365e86b0" - integrity sha512-fJgWlZt7nxGksJS9a0XdSaI4XvpExnNIgRP+rVefWh5U7BL8pPuir6SJUmFKRfjWQ51OtWSzwOxhaH/EBWWc0A== +"@babel/helper-environment-visitor@^7.22.20": + version "7.22.20" + resolved "https://registry.yarnpkg.com/@babel/helper-environment-visitor/-/helper-environment-visitor-7.22.20.tgz#96159db61d34a29dba454c959f5ae4a649ba9167" + integrity sha512-zfedSIzFhat/gFhWfHtgWvlec0nqB9YEIVrpuwjruLlXfUSnA8cJB0miHKwqDnQ7d32aKo2xt88/xZptwxbfhA== + +"@babel/helper-function-name@^7.23.0": + version "7.23.0" + resolved "https://registry.yarnpkg.com/@babel/helper-function-name/-/helper-function-name-7.23.0.tgz#1f9a3cdbd5b2698a670c30d2735f9af95ed52759" + integrity sha512-OErEqsrxjZTJciZ4Oo+eoZqeW9UIiOcuYKRJA4ZAgV9myA+pOXhhmpfNCKjEH/auVfEYVFJ6y1Tc4r0eIApqiw== dependencies: - "@babel/template" "^7.18.6" - "@babel/types" "^7.18.9" + "@babel/template" "^7.22.15" + "@babel/types" "^7.23.0" -"@babel/helper-hoist-variables@^7.18.6": - version "7.18.6" - resolved "https://registry.yarnpkg.com/@babel/helper-hoist-variables/-/helper-hoist-variables-7.18.6.tgz#d4d2c8fb4baeaa5c68b99cc8245c56554f926678" - integrity sha512-UlJQPkFqFULIcyW5sbzgbkxn2FKRgwWiRexcuaR8RNJRy8+LLveqPjwZV/bwrLZCN0eUHD/x8D0heK1ozuoo6Q== +"@babel/helper-hoist-variables@^7.22.5": + version "7.22.5" + resolved "https://registry.yarnpkg.com/@babel/helper-hoist-variables/-/helper-hoist-variables-7.22.5.tgz#c01a007dac05c085914e8fb652b339db50d823bb" + integrity sha512-wGjk9QZVzvknA6yKIUURb8zY3grXCcOZt+/7Wcy8O2uctxhplmUPkOdlgoNhmdVee2c92JXbf1xpMtVNbfoxRw== dependencies: - "@babel/types" "^7.18.6" + "@babel/types" "^7.22.5" "@babel/helper-module-imports@^7.18.6": version "7.18.6" @@ -122,11 +145,28 @@ dependencies: "@babel/types" "^7.18.6" +"@babel/helper-split-export-declaration@^7.22.6": + version "7.22.6" + resolved "https://registry.yarnpkg.com/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.22.6.tgz#322c61b7310c0997fe4c323955667f18fcefb91c" + integrity sha512-AsUnxuLhRYsisFiaJwvp1QF+I3KjD5FOxut14q/GzovUe6orHLesW2C7d754kRm53h5gqrz6sFl6sxc4BVtE/g== + dependencies: + "@babel/types" "^7.22.5" + +"@babel/helper-string-parser@^7.22.5": + version "7.22.5" + resolved "https://registry.yarnpkg.com/@babel/helper-string-parser/-/helper-string-parser-7.22.5.tgz#533f36457a25814cf1df6488523ad547d784a99f" + integrity sha512-mM4COjgZox8U+JcXQwPijIZLElkgEpO5rsERVDJTc2qfCDfERyob6k5WegS14SX18IIjv+XD+GrqNumY5JRCDw== + "@babel/helper-validator-identifier@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.18.6.tgz#9c97e30d31b2b8c72a1d08984f2ca9b574d7a076" integrity sha512-MmetCkz9ej86nJQV+sFCxoGGrUbU3q02kgLciwkrt9QqEB7cP39oKEY0PakknEO0Gu20SskMRi+AYZ3b1TpN9g== +"@babel/helper-validator-identifier@^7.22.20": + version "7.22.20" + resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.22.20.tgz#c4ae002c61d2879e724581d96665583dbc1dc0e0" + integrity sha512-Y4OZ+ytlatR8AI+8KZfKuL5urKp7qey08ha31L8b3BwewJAoJamTzyvxPR/5D+KkdJCGPq/+8TukHBlY10FX9A== + "@babel/helper-validator-option@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/helper-validator-option/-/helper-validator-option-7.18.6.tgz#bf0d2b5a509b1f336099e4ff36e1a63aa5db4db8" @@ -150,11 +190,25 @@ chalk "^2.0.0" js-tokens "^4.0.0" +"@babel/highlight@^7.22.13": + version "7.22.20" + resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.22.20.tgz#4ca92b71d80554b01427815e06f2df965b9c1f54" + integrity sha512-dkdMCN3py0+ksCgYmGG8jKeGA/8Tk+gJwSYYlFGxG5lmhfKNoAy004YpLxpS1W2J8m/EK2Ew+yOs9pVRwO89mg== + dependencies: + "@babel/helper-validator-identifier" "^7.22.20" + chalk "^2.4.2" + js-tokens "^4.0.0" + "@babel/parser@^7.1.0", "@babel/parser@^7.14.7", "@babel/parser@^7.18.6", "@babel/parser@^7.18.9": version "7.18.9" resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.18.9.tgz#f2dde0c682ccc264a9a8595efd030a5cc8fd2539" integrity sha512-9uJveS9eY9DJ0t64YbIBZICtJy8a5QrDEVdiLCG97fVLpDTpGX7t8mMSb6OWw6Lrnjqj4O8zwjELX3dhoMgiBg== +"@babel/parser@^7.22.15", "@babel/parser@^7.23.0": + version "7.23.0" + resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.23.0.tgz#da950e622420bf96ca0d0f2909cdddac3acd8719" + integrity sha512-vvPKKdMemU85V9WE/l5wZEmImpCtLqbnTvqDS2U1fJ96KrxoW7KrXhNsNCblQlg8Ck4b85yxdTyelsMUgFUXiw== + "@babel/plugin-syntax-async-generators@^7.8.4": version "7.8.4" resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-async-generators/-/plugin-syntax-async-generators-7.8.4.tgz#a983fb1aeb2ec3f6ed042a210f640e90e786fe0d" @@ -248,19 +302,28 @@ "@babel/parser" "^7.18.6" "@babel/types" "^7.18.6" -"@babel/traverse@^7.1.0", "@babel/traverse@^7.18.9": - version "7.18.9" - resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.18.9.tgz#deeff3e8f1bad9786874cb2feda7a2d77a904f98" - integrity sha512-LcPAnujXGwBgv3/WHv01pHtb2tihcyW1XuL9wd7jqh1Z8AQkTd+QVjMrMijrln0T7ED3UXLIy36P9Ao7W75rYg== +"@babel/template@^7.22.15": + version "7.22.15" + resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.22.15.tgz#09576efc3830f0430f4548ef971dde1350ef2f38" + integrity sha512-QPErUVm4uyJa60rkI73qneDacvdvzxshT3kksGqlGWYdOTIUOwJ7RDUL8sGqslY1uXWSL6xMFKEXDS3ox2uF0w== dependencies: - "@babel/code-frame" "^7.18.6" - "@babel/generator" "^7.18.9" - "@babel/helper-environment-visitor" "^7.18.9" - "@babel/helper-function-name" "^7.18.9" - "@babel/helper-hoist-variables" "^7.18.6" - "@babel/helper-split-export-declaration" "^7.18.6" - "@babel/parser" "^7.18.9" - "@babel/types" "^7.18.9" + "@babel/code-frame" "^7.22.13" + "@babel/parser" "^7.22.15" + "@babel/types" "^7.22.15" + +"@babel/traverse@^7.1.0", "@babel/traverse@^7.18.9": + version "7.23.2" + resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.23.2.tgz#329c7a06735e144a506bdb2cad0268b7f46f4ad8" + integrity sha512-azpe59SQ48qG6nu2CzcMLbxUudtN+dOM9kDbUqGq3HXUJRlo7i8fvPoxQUzYgLZ4cMVmuZgm8vvBpNeRhd6XSw== + dependencies: + "@babel/code-frame" "^7.22.13" + "@babel/generator" "^7.23.0" + "@babel/helper-environment-visitor" "^7.22.20" + "@babel/helper-function-name" "^7.23.0" + "@babel/helper-hoist-variables" "^7.22.5" + "@babel/helper-split-export-declaration" "^7.22.6" + "@babel/parser" "^7.23.0" + "@babel/types" "^7.23.0" debug "^4.1.0" globals "^11.1.0" @@ -272,6 +335,15 @@ "@babel/helper-validator-identifier" "^7.18.6" to-fast-properties "^2.0.0" +"@babel/types@^7.22.15", "@babel/types@^7.22.5", "@babel/types@^7.23.0": + version "7.23.0" + resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.23.0.tgz#8c1f020c9df0e737e4e247c0619f58c68458aaeb" + integrity sha512-0oIyUfKoI3mSqMvsxBdclDwxXKXAUA8v/apZbc+iSyARYou1o8ZGDxbUYyLFoW2arqS2jDGqJuZvv1d/io1axg== + dependencies: + "@babel/helper-string-parser" "^7.22.5" + "@babel/helper-validator-identifier" "^7.22.20" + to-fast-properties "^2.0.0" + "@bcoe/v8-coverage@^0.2.3": version "0.2.3" resolved "https://registry.yarnpkg.com/@bcoe/v8-coverage/-/v8-coverage-0.2.3.tgz#75a2e8b51cb758a7553d6804a5932d7aace75c39" @@ -548,6 +620,11 @@ resolved "https://registry.yarnpkg.com/@jridgewell/resolve-uri/-/resolve-uri-3.1.0.tgz#2203b118c157721addfe69d47b70465463066d78" integrity sha512-F2msla3tad+Mfht5cJq7LSXcdudKTWCVYUgw6pLFOOHSTtZlj6SWNYAp+AhuqLmWdBO2X5hPrLcu8cVP8fy28w== +"@jridgewell/resolve-uri@^3.1.0": + version "3.1.1" + resolved "https://registry.yarnpkg.com/@jridgewell/resolve-uri/-/resolve-uri-3.1.1.tgz#c08679063f279615a3326583ba3a90d1d82cc721" + integrity sha512-dSYZh7HhCDtCKm4QakX0xFpsRDqjjtZf/kjI/v3T3Nwt5r8/qz/M19F9ySyOqU94SXBmeG9ttTul+YnR4LOxFA== + "@jridgewell/set-array@^1.0.0", "@jridgewell/set-array@^1.0.1": version "1.1.2" resolved "https://registry.yarnpkg.com/@jridgewell/set-array/-/set-array-1.1.2.tgz#7c6cf998d6d20b914c0a55a91ae928ff25965e72" @@ -566,6 +643,19 @@ resolved "https://registry.yarnpkg.com/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.14.tgz#add4c98d341472a289190b424efbdb096991bb24" integrity sha512-XPSJHWmi394fuUuzDnGz1wiKqWfo1yXecHQMRf2l6hztTO+nPru658AyDngaBe7isIxEkRsPR3FZh+s7iVa4Uw== +"@jridgewell/sourcemap-codec@^1.4.14": + version "1.4.15" + resolved "https://registry.yarnpkg.com/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.15.tgz#d7c6e6755c78567a951e04ab52ef0fd26de59f32" + integrity sha512-eF2rxCRulEKXHTRiDrDy6erMYWqNw4LPdQ8UQA4huuxaQsVeRPFl2oM8oDGxMFhJUWZf9McpLtJasDDZb/Bpeg== + +"@jridgewell/trace-mapping@^0.3.17": + version "0.3.20" + resolved "https://registry.yarnpkg.com/@jridgewell/trace-mapping/-/trace-mapping-0.3.20.tgz#72e45707cf240fa6b081d0366f8265b0cd10197f" + integrity sha512-R8LcPeWZol2zR8mmH3JeKQ6QRCFb7XgUhV9ZlGhHLGyg4wpPiPZNQOOWhFZhxKw8u//yTbNGI42Bx/3paXEQ+Q== + dependencies: + "@jridgewell/resolve-uri" "^3.1.0" + "@jridgewell/sourcemap-codec" "^1.4.14" + "@jridgewell/trace-mapping@^0.3.7", "@jridgewell/trace-mapping@^0.3.9": version "0.3.14" resolved "https://registry.yarnpkg.com/@jridgewell/trace-mapping/-/trace-mapping-0.3.14.tgz#b231a081d8f66796e475ad588a1ef473112701ed" From 2f5219757783c9277482c0390e8340442d0b7b02 Mon Sep 17 00:00:00 2001 From: Julian Waller Date: Wed, 1 Nov 2023 15:45:19 +0000 Subject: [PATCH 41/49] chore: fix some typos --- README.md | 2 +- packages/core/src/xkeys.ts | 2 +- packages/node/examples/basic-log-all-events.js | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 252309c..16ef82f 100644 --- a/README.md +++ b/README.md @@ -64,7 +64,7 @@ _Note: The watcher depends on the [node-usb](https://github.com/node-usb/node-us const { XKeysWatcher } = require('xkeys') /* - This example connects to any conncted x-keys panels and logs + This example connects to any connected x-keys panels and logs whenever a button is pressed or analog thing is moved */ diff --git a/packages/core/src/xkeys.ts b/packages/core/src/xkeys.ts index 2b25218..86a6358 100644 --- a/packages/core/src/xkeys.ts +++ b/packages/core/src/xkeys.ts @@ -619,7 +619,7 @@ export class XKeys extends EventEmitter { liteByte = 0 } byteVals[3] = liteByte // set the LCD backlight on or off. - // loop through the string and load array with acsii byte values + // loop through the string and load array with ascii byte values let i for (i = 0; i < displayChar.length; i++) { byteVals[i + 4] = displayChar.charCodeAt(i) diff --git a/packages/node/examples/basic-log-all-events.js b/packages/node/examples/basic-log-all-events.js index cbfbaa7..02982c0 100644 --- a/packages/node/examples/basic-log-all-events.js +++ b/packages/node/examples/basic-log-all-events.js @@ -1,7 +1,7 @@ const { XKeysWatcher } = require('xkeys') /* - This example connects to any conncted x-keys panels and logs + This example connects to any connected x-keys panels and logs whenever a button is pressed or analog thing is moved */ From 68f3e869139b2a846e2be4209f5201f7e4893494 Mon Sep 17 00:00:00 2001 From: Julian Waller Date: Wed, 1 Nov 2023 15:26:25 +0000 Subject: [PATCH 42/49] fix: filter for correct usage/usagePage when finding xkeys devices --- packages/webhid/src/methods.ts | 20 ++++++++++++++++---- 1 file changed, 16 insertions(+), 4 deletions(-) diff --git a/packages/webhid/src/methods.ts b/packages/webhid/src/methods.ts index 4156db9..45818f8 100644 --- a/packages/webhid/src/methods.ts +++ b/packages/webhid/src/methods.ts @@ -3,25 +3,32 @@ import { WebHIDDevice } from './web-hid-wrapper' /** Prompts the user for which X-keys panel to select */ export async function requestXkeysPanels(): Promise { - return navigator.hid.requestDevice({ + const allDevices = await navigator.hid.requestDevice({ filters: [ { vendorId: XKEYS_VENDOR_ID, }, ], }) + return allDevices.filter(isValidXkeysUsage) } /** * Reopen previously selected devices. * The browser remembers what the user previously allowed your site to access, and this will open those without the request dialog */ export async function getOpenedXKeysPanels(): Promise { - return await navigator.hid.getDevices() + const allDevices = await navigator.hid.getDevices() + return allDevices.filter(isValidXkeysUsage) +} + +function isValidXkeysUsage(device: HIDDevice): boolean { + return device.vendorId === XKEYS_VENDOR_ID && !!device.collections.find((collection) => collection.usagePage === 12) } /** Sets up a connection to a HID device (the X-keys panel) */ export async function setupXkeysPanel(browserDevice: HIDDevice): Promise { if (!browserDevice?.collections?.length) throw Error(`device collections is empty`) + if (!isValidXkeysUsage(browserDevice)) throw new Error(`Device has incorrect usage/interface`) if (!browserDevice.productId) throw Error(`Device has no productId!`) const productId = browserDevice.productId @@ -43,7 +50,12 @@ export async function setupXkeysPanel(browserDevice: HIDDevice): Promise ) // Wait for the device to initialize: - await xkeys.init() + try { + await xkeys.init() - return xkeys + return xkeys + } catch (e) { + await deviceWrap.close() + throw new Error('Failed to initialise device') + } } From 8b9fdd1eb69abf03cfbc67f5b503bd01a8623bc5 Mon Sep 17 00:00:00 2001 From: Julian Waller Date: Wed, 1 Nov 2023 16:20:52 +0000 Subject: [PATCH 43/49] fix: filter for correct usage/usagePage when finding xkeys devices --- packages/webhid/src/methods.ts | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/packages/webhid/src/methods.ts b/packages/webhid/src/methods.ts index 45818f8..1cf211a 100644 --- a/packages/webhid/src/methods.ts +++ b/packages/webhid/src/methods.ts @@ -22,7 +22,14 @@ export async function getOpenedXKeysPanels(): Promise { } function isValidXkeysUsage(device: HIDDevice): boolean { - return device.vendorId === XKEYS_VENDOR_ID && !!device.collections.find((collection) => collection.usagePage === 12) + if (device.vendorId !== XKEYS_VENDOR_ID) return false + + return !!device.collections.find((collection) => { + if (collection.usagePage !== 12) return false + + // Check the write-length of the device is > 20 + return !!collection.outputReports?.find((report) => !!report.items?.find((item) => item.reportCount ?? 0 > 20)) + }) } /** Sets up a connection to a HID device (the X-keys panel) */ From 1147671a865035b8893a0e40e3088a7af4763ab4 Mon Sep 17 00:00:00 2001 From: Johan Nyman Date: Thu, 2 Nov 2023 09:20:47 +0100 Subject: [PATCH 44/49] chore: throw original error --- packages/webhid/src/methods.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/webhid/src/methods.ts b/packages/webhid/src/methods.ts index 1cf211a..96b57df 100644 --- a/packages/webhid/src/methods.ts +++ b/packages/webhid/src/methods.ts @@ -63,6 +63,6 @@ export async function setupXkeysPanel(browserDevice: HIDDevice): Promise return xkeys } catch (e) { await deviceWrap.close() - throw new Error('Failed to initialise device') + throw e } } From e30f2b0298c88350a8c8faba433f6a6b8566cc68 Mon Sep 17 00:00:00 2001 From: Johan Nyman Date: Wed, 3 May 2023 09:53:23 +0200 Subject: [PATCH 45/49] chore: add node 18 & 20 to tests in CI --- .github/workflows/lint-and-test.yml | 2 +- .github/workflows/publish-prerelease.yml | 2 +- .github/workflows/publish-release.yml | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/lint-and-test.yml b/.github/workflows/lint-and-test.yml index 2dc41b7..2f621ac 100644 --- a/.github/workflows/lint-and-test.yml +++ b/.github/workflows/lint-and-test.yml @@ -61,7 +61,7 @@ jobs: runs-on: ${{ matrix.os }} strategy: matrix: - node_version: ['14', '16'] + node_version: ['14', '16', '18', '20'] os: [ubuntu-latest] # [windows-latest, macOS-latest] timeout-minutes: 10 steps: diff --git a/.github/workflows/publish-prerelease.yml b/.github/workflows/publish-prerelease.yml index 67c04ec..347607d 100644 --- a/.github/workflows/publish-prerelease.yml +++ b/.github/workflows/publish-prerelease.yml @@ -12,7 +12,7 @@ jobs: runs-on: ${{ matrix.os }} strategy: matrix: - node_version: ['14', '16'] + node_version: ['14', '16', '18', '20'] os: [ubuntu-latest] # [windows-latest, macOS-latest] timeout-minutes: 10 steps: diff --git a/.github/workflows/publish-release.yml b/.github/workflows/publish-release.yml index b7b9c06..8ffaab6 100644 --- a/.github/workflows/publish-release.yml +++ b/.github/workflows/publish-release.yml @@ -41,7 +41,7 @@ jobs: runs-on: ${{ matrix.os }} strategy: matrix: - node_version: ['14', '16'] + node_version: ['14', '16', '18', '20'] os: [ubuntu-latest] # [windows-latest, macOS-latest] timeout-minutes: 10 steps: From 7566e7d340c97e811419901982a06cf14de7abe1 Mon Sep 17 00:00:00 2001 From: Johan Nyman Date: Thu, 2 Nov 2023 09:37:12 +0100 Subject: [PATCH 46/49] chore: update dependency: @sofie-automation/code-standard-preset --- package.json | 2 +- yarn.lock | 730 +++++++++++++++++++++++++++++++++------------------ 2 files changed, 474 insertions(+), 258 deletions(-) diff --git a/package.json b/package.json index e9f0112..6c6e41e 100644 --- a/package.json +++ b/package.json @@ -25,7 +25,7 @@ "lerna": "lerna" }, "devDependencies": { - "@sofie-automation/code-standard-preset": "~2.0.2", + "@sofie-automation/code-standard-preset": "^2.5.2", "@types/jest": "^26.0.20", "cross-env": "^7.0.3", "jest": "^26.6.3", diff --git a/yarn.lock b/yarn.lock index 715be9d..556a464 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2,6 +2,11 @@ # yarn lockfile v1 +"@aashutoshrathi/word-wrap@^1.2.3": + version "1.2.6" + resolved "https://registry.yarnpkg.com/@aashutoshrathi/word-wrap/-/word-wrap-1.2.6.tgz#bd9154aec9983f77b3a034ecaa015c2e4201f6cf" + integrity sha512-1Yjs2SvM8TflER/OD3cOjhWWOZb58A2t7wpE2S9XfBYTiIl+XFhQG2bjy4Pu1I+EAlCNUzRDYDdFwFYUKvXcIA== + "@ampproject/remapping@^2.1.0": version "2.2.0" resolved "https://registry.yarnpkg.com/@ampproject/remapping/-/remapping-2.2.0.tgz#56c133824780de3174aed5ab6834f3026790154d" @@ -293,6 +298,13 @@ dependencies: "@babel/helper-plugin-utils" "^7.14.5" +"@babel/runtime@^7.21.0": + version "7.23.2" + resolved "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.23.2.tgz#062b0ac103261d68a966c4c7baf2ae3e62ec3885" + integrity sha512-mM8eg4yl5D6i3lu2QKPuPH4FArvJ8KhTofbE7jwMUv9KX5mBvwPAqnV3MlyBNqdp9RyRKP6Yck8TrfYrPvX3bg== + dependencies: + regenerator-runtime "^0.14.0" + "@babel/template@^7.18.6", "@babel/template@^7.3.3": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.18.6.tgz#1283f4993e00b929d6e2d3c72fdc9168a2977a31" @@ -372,39 +384,61 @@ resolved "https://registry.yarnpkg.com/@discoveryjs/json-ext/-/json-ext-0.5.7.tgz#1d572bfbbe14b7704e0ba0f39b74815b84870d70" integrity sha512-dBVuXR082gk3jsFp7Rd/JI4kytwGHecnCoTtXFb7DB6CNHp4rg5k1bhg0nWdLGLnOV71lmDzGQaLMy8iPLY0pw== -"@eslint/eslintrc@^1.3.0": - version "1.3.0" - resolved "https://registry.yarnpkg.com/@eslint/eslintrc/-/eslintrc-1.3.0.tgz#29f92c30bb3e771e4a2048c95fa6855392dfac4f" - integrity sha512-UWW0TMTmk2d7hLcWD1/e2g5HDM/HQ3csaLSqXCfqwh4uNDuNqlaKWXmEsL4Cs41Z0KnILNvwbHAah3C2yt06kw== +"@eslint-community/eslint-utils@^4.2.0": + version "4.4.0" + resolved "https://registry.yarnpkg.com/@eslint-community/eslint-utils/-/eslint-utils-4.4.0.tgz#a23514e8fb9af1269d5f7788aa556798d61c6b59" + integrity sha512-1/sA4dwrzBAyeUoQ6oxahHKmrZvsnLCg4RfxW3ZFGGmQkSNQPFNLV9CUEFQP1x9EYXHTo5p6xdhZM1Ne9p/AfA== + dependencies: + eslint-visitor-keys "^3.3.0" + +"@eslint-community/regexpp@^4.4.0", "@eslint-community/regexpp@^4.6.1": + version "4.10.0" + resolved "https://registry.yarnpkg.com/@eslint-community/regexpp/-/regexpp-4.10.0.tgz#548f6de556857c8bb73bbee70c35dc82a2e74d63" + integrity sha512-Cu96Sd2By9mCNTx2iyKOmq10v22jUVQv0lQnlGNy16oE9589yE+QADPbrMGCkA51cKZSg3Pu/aTJVTGfL/qjUA== + +"@eslint/eslintrc@^2.1.2": + version "2.1.2" + resolved "https://registry.yarnpkg.com/@eslint/eslintrc/-/eslintrc-2.1.2.tgz#c6936b4b328c64496692f76944e755738be62396" + integrity sha512-+wvgpDsrB1YqAMdEUCcnTlpfVBH7Vqn6A/NT3D8WVXFIaKMlErPIZT3oCIAVCOtarRpMtelZLqJeU3t7WY6X6g== dependencies: ajv "^6.12.4" debug "^4.3.2" - espree "^9.3.2" - globals "^13.15.0" + espree "^9.6.0" + globals "^13.19.0" ignore "^5.2.0" import-fresh "^3.2.1" js-yaml "^4.1.0" minimatch "^3.1.2" strip-json-comments "^3.1.1" +"@eslint/js@8.52.0": + version "8.52.0" + resolved "https://registry.yarnpkg.com/@eslint/js/-/js-8.52.0.tgz#78fe5f117840f69dc4a353adf9b9cd926353378c" + integrity sha512-mjZVbpaeMZludF2fsWLD0Z9gCref1Tk4i9+wddjRvpUNqqcndPkBD09N/Mapey0b3jaXbLm2kICwFv2E64QinA== + "@gar/promisify@^1.0.1": version "1.1.3" resolved "https://registry.yarnpkg.com/@gar/promisify/-/promisify-1.1.3.tgz#555193ab2e3bb3b6adc3d551c9c030d9e860daf6" integrity sha512-k2Ty1JcVojjJFwrg/ThKi2ujJ7XNLYaFGNB/bWT9wGR+oSMJHMa5w+CUq6p/pVrKeNNgA7pCqEcjSnHVoqJQFw== -"@humanwhocodes/config-array@^0.9.2": - version "0.9.5" - resolved "https://registry.yarnpkg.com/@humanwhocodes/config-array/-/config-array-0.9.5.tgz#2cbaf9a89460da24b5ca6531b8bbfc23e1df50c7" - integrity sha512-ObyMyWxZiCu/yTisA7uzx81s40xR2fD5Cg/2Kq7G02ajkNubJf6BopgDTmDyc3U7sXpNKM8cYOw7s7Tyr+DnCw== +"@humanwhocodes/config-array@^0.11.13": + version "0.11.13" + resolved "https://registry.yarnpkg.com/@humanwhocodes/config-array/-/config-array-0.11.13.tgz#075dc9684f40a531d9b26b0822153c1e832ee297" + integrity sha512-JSBDMiDKSzQVngfRjOdFXgFfklaXI4K9nLF49Auh21lmBWRLIK3+xTErTWD4KU54pb6coM6ESE7Awz/FNU3zgQ== dependencies: - "@humanwhocodes/object-schema" "^1.2.1" + "@humanwhocodes/object-schema" "^2.0.1" debug "^4.1.1" - minimatch "^3.0.4" + minimatch "^3.0.5" -"@humanwhocodes/object-schema@^1.2.1": - version "1.2.1" - resolved "https://registry.yarnpkg.com/@humanwhocodes/object-schema/-/object-schema-1.2.1.tgz#b520529ec21d8e5945a1851dfd1c32e94e39ff45" - integrity sha512-ZnQMnLV4e7hDlUvw8H+U8ASL02SS2Gn6+9Ac3wGGLIe7+je2AeAOxPY+izIPJDfFDb7eDjev0Us8MO1iFRN8hA== +"@humanwhocodes/module-importer@^1.0.1": + version "1.0.1" + resolved "https://registry.yarnpkg.com/@humanwhocodes/module-importer/-/module-importer-1.0.1.tgz#af5b2691a22b44be847b0ca81641c5fb6ad0172c" + integrity sha512-bxveV4V8v5Yb4ncFTT3rPSgZBOpCkjfK0y4oVVVJwIuDVBRMDXrPyXRL988i5ap9m9bnyEEjWfm5WkBmtffLfA== + +"@humanwhocodes/object-schema@^2.0.1": + version "2.0.1" + resolved "https://registry.yarnpkg.com/@humanwhocodes/object-schema/-/object-schema-2.0.1.tgz#e5211452df060fa8522b55c7b3c0c4d1981cb044" + integrity sha512-dvuCeX5fC9dXgJn9t+X5atfmgQAzUOWqS1254Gh0m6i8wKd10ebXkfNKiRK+1GWi/yTvvLDHpoxLr0xxxeslWw== "@hutson/parse-repository-url@^3.0.0": version "3.0.2" @@ -1361,7 +1395,7 @@ resolved "https://registry.yarnpkg.com/@nodelib/fs.stat/-/fs.stat-1.1.3.tgz#2b5a3ab3f918cca48a8c754c08168e3f03eba61b" integrity sha512-shAmDyaQC4H92APFoIaVDHCx5bStIocgvbwQyxPRrbUY20V1EYTbSDchWbuwlMG3V17cprZhA6+78JfB+3DTPw== -"@nodelib/fs.walk@^1.2.3": +"@nodelib/fs.walk@^1.2.3", "@nodelib/fs.walk@^1.2.8": version "1.2.8" resolved "https://registry.yarnpkg.com/@nodelib/fs.walk/-/fs.walk-1.2.8.tgz#e95737e8bb6746ddedf69c556953494f196fe69a" integrity sha512-oGB+UxlgWcgQkgwo8GcEGwemoTFt3FIO9ababBmaGwXIoBKZ+GTy0pP185beGg7Llih/NSHSV2XAs1lnznocSg== @@ -1564,25 +1598,33 @@ dependencies: "@sinonjs/commons" "^1.7.0" -"@sofie-automation/code-standard-preset@~2.0.2": - version "2.0.2" - resolved "https://registry.yarnpkg.com/@sofie-automation/code-standard-preset/-/code-standard-preset-2.0.2.tgz#e2bff6e75bd7cd8638fc624a40aea087fddb3a7b" - integrity sha512-ksQ8feMBxDVjZACMQhP5Irebjwde6OaS9mAASicS2MNs9VEaltl4sgwlbYIL5jkxISrdzvLiYk2PtdWm4rJHew== - dependencies: - "@typescript-eslint/eslint-plugin" "^5.24.0" - "@typescript-eslint/parser" "^5.24.0" - eslint "^8.9.0" - eslint-config-prettier "^8.3.0" - eslint-plugin-jest "^26.1.1" +"@sofie-automation/code-standard-preset@~2.5.2": + version "2.5.2" + resolved "https://registry.yarnpkg.com/@sofie-automation/code-standard-preset/-/code-standard-preset-2.5.2.tgz#468bd1c4c32be976431f50f76ff54329c2cfffe0" + integrity sha512-xzAMUp/FHvNwkMC2pl8isOVLcWUmoQ9Mw1FdiYwDSHyOkLmbJ/nwYrl6iWR/7LbkGk45RAKkbkfFyhsqTh4xzA== + dependencies: + "@sofie-automation/eslint-plugin" "^0.1.1" + "@typescript-eslint/eslint-plugin" "^5.62.0" + "@typescript-eslint/parser" "^5.62.0" + "@typescript-eslint/utils" "^5.62.0" + date-fns "^2.30.0" + eslint "^8.50.0" + eslint-config-prettier "^8.10.0" + eslint-plugin-jest "^27.4.0" eslint-plugin-node "^11.1.0" - eslint-plugin-prettier "^4.0.0" - husky "^7.0.4" + eslint-plugin-prettier "^4.2.1" + husky "^8.0.3" license-checker "^25.0.1" - lint-staged "^12.3.4" - meow "^10.1.2" - prettier "^2.5.1" + lint-staged "13.2.2" + meow "^11.0.0" + prettier "^2.8.8" read-pkg-up "^9.1.0" - shelljs "^0.8.5" + semver "^7.5.4" + +"@sofie-automation/eslint-plugin@^0.1.1": + version "0.1.1" + resolved "https://registry.yarnpkg.com/@sofie-automation/eslint-plugin/-/eslint-plugin-0.1.1.tgz#32cbb94fc3dd35e2dbcb95239512d2ec65133c54" + integrity sha512-Abl0/5KDQrktJ0YoA8ULXygi2s5Q7tADsrhDnighzdR745eeYuP8MlW17NCVxzGbwkm+UKNPtGA+TRixTKJCFw== "@szmarczak/http-timer@^1.1.2": version "1.1.2" @@ -1739,6 +1781,11 @@ resolved "https://registry.yarnpkg.com/@types/prettier/-/prettier-2.6.4.tgz#ad899dad022bab6b5a9f0a0fe67c2f7a4a8950ed" integrity sha512-fOwvpvQYStpb/zHMx0Cauwywu9yLDmzWiiQBC7gJyq5tYLUXFZvDG7VK1B7WBxxjBJNKFOZ0zLoOQn8vmATbhw== +"@types/semver@^7.3.12": + version "7.5.4" + resolved "https://registry.yarnpkg.com/@types/semver/-/semver-7.5.4.tgz#0a41252ad431c473158b22f9bfb9a63df7541cff" + integrity sha512-MMzuxN3GdFwskAnb6fz0orFvhfqi752yjaXylr0Rp4oDg5H0Zn1IuyRhDVvYOwAXoJirx2xuS16I3WjxnAIHiQ== + "@types/stack-utils@^2.0.0": version "2.0.1" resolved "https://registry.yarnpkg.com/@types/stack-utils/-/stack-utils-2.0.1.tgz#20f18294f797f2209b5f65c8e3b5c8e8261d127c" @@ -1766,29 +1813,30 @@ dependencies: "@types/yargs-parser" "*" -"@typescript-eslint/eslint-plugin@^5.24.0": - version "5.29.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/eslint-plugin/-/eslint-plugin-5.29.0.tgz#c67794d2b0fd0b4a47f50266088acdc52a08aab6" - integrity sha512-kgTsISt9pM53yRFQmLZ4npj99yGl3x3Pl7z4eA66OuTzAGC4bQB5H5fuLwPnqTKU3yyrrg4MIhjF17UYnL4c0w== +"@typescript-eslint/eslint-plugin@^5.62.0": + version "5.62.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/eslint-plugin/-/eslint-plugin-5.62.0.tgz#aeef0328d172b9e37d9bab6dbc13b87ed88977db" + integrity sha512-TiZzBSJja/LbhNPvk6yc0JrX9XqhQ0hdh6M2svYfsHGejaKFIAGd9MQ+ERIMzLGlN/kZoYIgdxFV0PuljTKXag== dependencies: - "@typescript-eslint/scope-manager" "5.29.0" - "@typescript-eslint/type-utils" "5.29.0" - "@typescript-eslint/utils" "5.29.0" + "@eslint-community/regexpp" "^4.4.0" + "@typescript-eslint/scope-manager" "5.62.0" + "@typescript-eslint/type-utils" "5.62.0" + "@typescript-eslint/utils" "5.62.0" debug "^4.3.4" - functional-red-black-tree "^1.0.1" + graphemer "^1.4.0" ignore "^5.2.0" - regexpp "^3.2.0" + natural-compare-lite "^1.4.0" semver "^7.3.7" tsutils "^3.21.0" -"@typescript-eslint/parser@^5.24.0": - version "5.29.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/parser/-/parser-5.29.0.tgz#41314b195b34d44ff38220caa55f3f93cfca43cf" - integrity sha512-ruKWTv+x0OOxbzIw9nW5oWlUopvP/IQDjB5ZqmTglLIoDTctLlAJpAQFpNPJP/ZI7hTT9sARBosEfaKbcFuECw== +"@typescript-eslint/parser@^5.62.0": + version "5.62.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/parser/-/parser-5.62.0.tgz#1b63d082d849a2fcae8a569248fbe2ee1b8a56c7" + integrity sha512-VlJEV0fOQ7BExOsHYAGrgbEiZoi8D+Bl2+f6V2RrXerRSylnp+ZBHmPvaIa8cz0Ajx7WO7Z5RqfgYg7ED1nRhA== dependencies: - "@typescript-eslint/scope-manager" "5.29.0" - "@typescript-eslint/types" "5.29.0" - "@typescript-eslint/typescript-estree" "5.29.0" + "@typescript-eslint/scope-manager" "5.62.0" + "@typescript-eslint/types" "5.62.0" + "@typescript-eslint/typescript-estree" "5.62.0" debug "^4.3.4" "@typescript-eslint/scope-manager@5.29.0": @@ -1799,12 +1847,21 @@ "@typescript-eslint/types" "5.29.0" "@typescript-eslint/visitor-keys" "5.29.0" -"@typescript-eslint/type-utils@5.29.0": - version "5.29.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/type-utils/-/type-utils-5.29.0.tgz#241918001d164044020b37d26d5b9f4e37cc3d5d" - integrity sha512-JK6bAaaiJozbox3K220VRfCzLa9n0ib/J+FHIwnaV3Enw/TO267qe0pM1b1QrrEuy6xun374XEAsRlA86JJnyg== +"@typescript-eslint/scope-manager@5.62.0": + version "5.62.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/scope-manager/-/scope-manager-5.62.0.tgz#d9457ccc6a0b8d6b37d0eb252a23022478c5460c" + integrity sha512-VXuvVvZeQCQb5Zgf4HAxc04q5j+WrNAtNh9OwCsCgpKqESMTu3tF/jhZ3xG6T4NZwWl65Bg8KuS2uEvhSfLl0w== + dependencies: + "@typescript-eslint/types" "5.62.0" + "@typescript-eslint/visitor-keys" "5.62.0" + +"@typescript-eslint/type-utils@5.62.0": + version "5.62.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/type-utils/-/type-utils-5.62.0.tgz#286f0389c41681376cdad96b309cedd17d70346a" + integrity sha512-xsSQreu+VnfbqQpW5vnCJdq1Z3Q0U31qiWmRhr98ONQmcp/yhiPJFPq8MXiJVLiksmOKSjIldZzkebzHuCGzew== dependencies: - "@typescript-eslint/utils" "5.29.0" + "@typescript-eslint/typescript-estree" "5.62.0" + "@typescript-eslint/utils" "5.62.0" debug "^4.3.4" tsutils "^3.21.0" @@ -1813,6 +1870,11 @@ resolved "https://registry.yarnpkg.com/@typescript-eslint/types/-/types-5.29.0.tgz#7861d3d288c031703b2d97bc113696b4d8c19aab" integrity sha512-X99VbqvAXOMdVyfFmksMy3u8p8yoRGITgU1joBJPzeYa0rhdf5ok9S56/itRoUSh99fiDoMtarSIJXo7H/SnOg== +"@typescript-eslint/types@5.62.0": + version "5.62.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/types/-/types-5.62.0.tgz#258607e60effa309f067608931c3df6fed41fd2f" + integrity sha512-87NVngcbVXUahrRTqIK27gD2t5Cu1yuCXxbLcFtCzZGlfyVWWh8mLHkoxzjsB6DDNnvdL+fW8MiwPEJyGJQDgQ== + "@typescript-eslint/typescript-estree@5.29.0": version "5.29.0" resolved "https://registry.yarnpkg.com/@typescript-eslint/typescript-estree/-/typescript-estree-5.29.0.tgz#e83d19aa7fd2e74616aab2f25dfbe4de4f0b5577" @@ -1826,7 +1888,34 @@ semver "^7.3.7" tsutils "^3.21.0" -"@typescript-eslint/utils@5.29.0", "@typescript-eslint/utils@^5.10.0": +"@typescript-eslint/typescript-estree@5.62.0": + version "5.62.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/typescript-estree/-/typescript-estree-5.62.0.tgz#7d17794b77fabcac615d6a48fb143330d962eb9b" + integrity sha512-CmcQ6uY7b9y694lKdRB8FEel7JbU/40iSAPomu++SjLMntB+2Leay2LO6i8VnJk58MtE9/nQSFIH6jpyRWyYzA== + dependencies: + "@typescript-eslint/types" "5.62.0" + "@typescript-eslint/visitor-keys" "5.62.0" + debug "^4.3.4" + globby "^11.1.0" + is-glob "^4.0.3" + semver "^7.3.7" + tsutils "^3.21.0" + +"@typescript-eslint/utils@5.62.0", "@typescript-eslint/utils@^5.62.0": + version "5.62.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/utils/-/utils-5.62.0.tgz#141e809c71636e4a75daa39faed2fb5f4b10df86" + integrity sha512-n8oxjeb5aIbPFEtmQxQYOLI0i9n5ySBEY/ZEHHZqKQSFnxio1rv6dthascc9dLuwrL0RC5mPCxB7vnAVGAYWAQ== + dependencies: + "@eslint-community/eslint-utils" "^4.2.0" + "@types/json-schema" "^7.0.9" + "@types/semver" "^7.3.12" + "@typescript-eslint/scope-manager" "5.62.0" + "@typescript-eslint/types" "5.62.0" + "@typescript-eslint/typescript-estree" "5.62.0" + eslint-scope "^5.1.1" + semver "^7.3.7" + +"@typescript-eslint/utils@^5.10.0": version "5.29.0" resolved "https://registry.yarnpkg.com/@typescript-eslint/utils/-/utils-5.29.0.tgz#775046effd5019667bd086bcf326acbe32cd0082" integrity sha512-3Eos6uP1nyLOBayc/VUdKZikV90HahXE5Dx9L5YlSd/7ylQPXhLk1BYb29SDgnBnTp+jmSZUU0QxUiyHgW4p7A== @@ -1846,6 +1935,19 @@ "@typescript-eslint/types" "5.29.0" eslint-visitor-keys "^3.3.0" +"@typescript-eslint/visitor-keys@5.62.0": + version "5.62.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/visitor-keys/-/visitor-keys-5.62.0.tgz#2174011917ce582875954ffe2f6912d5931e353e" + integrity sha512-07ny+LHRzQXepkGg6w0mFY41fVUNBrL2Roj/++7V1txKugfjm/Ci/qSND03r2RhlJhJYMcTn9AhhSSqQp0Ysyw== + dependencies: + "@typescript-eslint/types" "5.62.0" + eslint-visitor-keys "^3.3.0" + +"@ungap/structured-clone@^1.2.0": + version "1.2.0" + resolved "https://registry.yarnpkg.com/@ungap/structured-clone/-/structured-clone-1.2.0.tgz#756641adb587851b5ccb3e095daf27ae581c8406" + integrity sha512-zuVdFrMJiuCDQUMCzQaD6KL28MjnqqN8XnAqiEq9PNm/hCPTSGfrXCOfwj1ow4LFb/tNymJPwsNbVePc1xFqrQ== + "@webassemblyjs/ast@1.11.1": version "1.11.1" resolved "https://registry.yarnpkg.com/@webassemblyjs/ast/-/ast-1.11.1.tgz#2bfd767eae1a6996f432ff7e8d7fc75679c0b6a7" @@ -2053,6 +2155,11 @@ acorn@^8.2.4, acorn@^8.5.0, acorn@^8.7.1: resolved "https://registry.yarnpkg.com/acorn/-/acorn-8.7.1.tgz#0197122c843d1bf6d0a5e83220a788f278f63c30" integrity sha512-Xx54uLJQZ19lKygFXOWsscKUbsBZW0CPykPhVQdhIeIwrbPmJzqeASDInc8nKBnp/JT6igTs82qPXz069H8I/A== +acorn@^8.9.0: + version "8.11.2" + resolved "https://registry.yarnpkg.com/acorn/-/acorn-8.11.2.tgz#ca0d78b51895be5390a5903c5b3bdcdaf78ae40b" + integrity sha512-nc0Axzp/0FILLEVsm4fNwLCwMttvhEI263QtVPQcbpfZZ3ts0hLsZGOpE6czNlid7CJ9MlyH8reXkpsf3YUY4w== + add-stream@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/add-stream/-/add-stream-1.0.0.tgz#6a7990437ca736d5e1288db92bd3266d5f5cb2aa" @@ -2092,7 +2199,7 @@ ajv-keywords@^3.1.0, ajv-keywords@^3.5.2: resolved "https://registry.yarnpkg.com/ajv-keywords/-/ajv-keywords-3.5.2.tgz#31f29da5ab6e00d1c2d329acf7b5929614d5014d" integrity sha512-5p6WTN0DdTGVQk6VjcEju19IgaHudalcfabD7yhDGeA6bcQnmL+CpveLJq/3hvfwd1aof6L386Ougkx6RfyMIQ== -ajv@^6.1.0, ajv@^6.10.0, ajv@^6.12.3, ajv@^6.12.4, ajv@^6.12.5: +ajv@^6.1.0, ajv@^6.12.3, ajv@^6.12.4, ajv@^6.12.5: version "6.12.6" resolved "https://registry.yarnpkg.com/ajv/-/ajv-6.12.6.tgz#baf5a62e802b07d977034586f8c3baf5adf26df4" integrity sha512-j3fVLgvTo527anyYyJOGTYJbG+vnnQYvE0m5mmkc1TK+nxAppkCLMIL0aZ4dblVCNoGShhm+kzE4ZUykBoMg4g== @@ -2759,26 +2866,31 @@ camelcase-keys@^6.2.2: map-obj "^4.0.0" quick-lru "^4.0.1" -camelcase-keys@^7.0.0: - version "7.0.2" - resolved "https://registry.yarnpkg.com/camelcase-keys/-/camelcase-keys-7.0.2.tgz#d048d8c69448745bb0de6fc4c1c52a30dfbe7252" - integrity sha512-Rjs1H+A9R+Ig+4E/9oyB66UC5Mj9Xq3N//vcLf2WzgdTi/3gUu3Z9KoqmlrEG4VuuLK8wJHofxzdQXz/knhiYg== +camelcase-keys@^8.0.2: + version "8.0.2" + resolved "https://registry.yarnpkg.com/camelcase-keys/-/camelcase-keys-8.0.2.tgz#a7140ba7c797aea32161d4ce5cdbda11d09eb414" + integrity sha512-qMKdlOfsjlezMqxkUGGMaWWs17i2HoL15tM+wtx8ld4nLrUwU58TFdvyGOz/piNP842KeO8yXvggVQSdQ828NA== dependencies: - camelcase "^6.3.0" - map-obj "^4.1.0" - quick-lru "^5.1.1" - type-fest "^1.2.1" + camelcase "^7.0.0" + map-obj "^4.3.0" + quick-lru "^6.1.1" + type-fest "^2.13.0" camelcase@^5.0.0, camelcase@^5.3.1: version "5.3.1" resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-5.3.1.tgz#e3c9b31569e106811df242f715725a1f4c494320" integrity sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg== -camelcase@^6.0.0, camelcase@^6.3.0: +camelcase@^6.0.0: version "6.3.0" resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-6.3.0.tgz#5685b95eb209ac9c0c177467778c9c84df58ba9a" integrity sha512-Gmy6FhYlCY7uOElZUSbxo2UCDH8owEk996gkbrpsgGtrJLM3J7jGxl9Ic7Qwwj4ivOE5AWZWRMecDdF7hqGjFA== +camelcase@^7.0.0: + version "7.0.1" + resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-7.0.1.tgz#f02e50af9fd7782bc8b88a3558c32fd3a388f048" + integrity sha512-xlx1yCK2Oc1APsPXDL2LdlNP6+uu8OCDdhOBSVT279M/S+y75O30C2VuD8T2ogdePBBl7PfPF4504tnLgX3zfw== + caniuse-lite@^1.0.30001370: version "1.0.30001373" resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001373.tgz#2dc3bc3bfcb5d5a929bec11300883040d7b4b4be" @@ -2806,6 +2918,11 @@ caw@^2.0.1: tunnel-agent "^0.6.0" url-to-options "^1.0.1" +chalk@5.2.0: + version "5.2.0" + resolved "https://registry.yarnpkg.com/chalk/-/chalk-5.2.0.tgz#249623b7d66869c673699fb66d65723e54dfcfb3" + integrity sha512-ree3Gqw/nazQAPuJJEy+avdl7QfZMcUvmHIKgEZkGL+xOBzRvup5Hxo6LHuMceSxOabuJLJm5Yp/92R9eMmMvA== + chalk@^2.0.0, chalk@^2.0.1, chalk@^2.4.1, chalk@^2.4.2: version "2.4.2" resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.4.2.tgz#cd42541677a54333cf541a49108c1432b44c9424" @@ -3046,11 +3163,16 @@ color-name@~1.1.4: resolved "https://registry.yarnpkg.com/color-name/-/color-name-1.1.4.tgz#c2a09a87acbde69543de6f63fa3995c826c536a2" integrity sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA== -colorette@^2.0.14, colorette@^2.0.16: +colorette@^2.0.14: version "2.0.19" resolved "https://registry.yarnpkg.com/colorette/-/colorette-2.0.19.tgz#cdf044f47ad41a0f4b56b3a0d5b4e6e1a2d5a798" integrity sha512-3tlv/dIP7FWvj3BsbHrGLJ6l/oKh1O3TcgBqMn+yyCagOxc23fyzDS6HypQbgxWbkpDnf52p1LuR4eWDQ/K9WQ== +colorette@^2.0.19: + version "2.0.20" + resolved "https://registry.yarnpkg.com/colorette/-/colorette-2.0.20.tgz#9eb793e6833067f7235902fcd3b09917a000a95a" + integrity sha512-IfEDxwoWIjkeXL1eXcDiow4UbKjhLdq6/EuSVR9GMN7KVH3r9gQ83e73hsz1Nd1T3ijd5xv1wcWRYO+D6kCI2w== + columnify@^1.5.4: version "1.6.0" resolved "https://registry.yarnpkg.com/columnify/-/columnify-1.6.0.tgz#6989531713c9008bb29735e61e37acf5bd553cf3" @@ -3066,6 +3188,11 @@ combined-stream@^1.0.6, combined-stream@^1.0.8, combined-stream@~1.0.6: dependencies: delayed-stream "~1.0.0" +commander@^10.0.0: + version "10.0.1" + resolved "https://registry.yarnpkg.com/commander/-/commander-10.0.1.tgz#881ee46b4f77d1c1dccc5823433aa39b022cbe06" + integrity sha512-y4Mg2tXshplEbSGzx7amzPwKKOCGuoSRP/CjEdwwk0FOGlUbq6lKuoyDZTNZkmxHdJtp54hdfY/JUrdL7Xfdug== + commander@^2.20.0, commander@^2.8.1: version "2.20.3" resolved "https://registry.yarnpkg.com/commander/-/commander-2.20.3.tgz#fd485e84c03eb4881c20722ba48035e8531aeb33" @@ -3076,11 +3203,6 @@ commander@^7.0.0: resolved "https://registry.yarnpkg.com/commander/-/commander-7.2.0.tgz#a36cb57d0b501ce108e4d20559a150a391d97ab7" integrity sha512-QrWXB+ZQSVPmIWIhtEO9H+gwHaMGYiF5ChvoJ+K9ZGHG/sVsa6yiesAD1GC/x46sET00Xlwo1u49RVVVzvcSkw== -commander@^9.3.0: - version "9.3.0" - resolved "https://registry.yarnpkg.com/commander/-/commander-9.3.0.tgz#f619114a5a2d2054e0d9ff1b31d5ccf89255e26b" - integrity sha512-hv95iU5uXPbK83mjrJKuZyFM/LBAoCV/XhVGkS5Je6tl7sxr6A0ITMw5WoRV46/UaJ46Nllm3Xt7IaJhXTIkzw== - compare-func@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/compare-func/-/compare-func-2.0.0.tgz#fb65e75edbddfd2e568554e8b5b05fff7a51fcb3" @@ -3363,6 +3485,13 @@ data-urls@^2.0.0: whatwg-mimetype "^2.3.0" whatwg-url "^8.0.0" +date-fns@^2.30.0: + version "2.30.0" + resolved "https://registry.yarnpkg.com/date-fns/-/date-fns-2.30.0.tgz#f367e644839ff57894ec6ac480de40cae4b0f4d0" + integrity sha512-fnULvOpxnC5/Vg3NCiWelDsLiUc9bRwAPs/+LfTLNvetFCtCTN+yQz15C/fs4AwX1R9K5GLtLfn8QW+dWisaAw== + dependencies: + "@babel/runtime" "^7.21.0" + dateformat@^3.0.0: version "3.0.3" resolved "https://registry.yarnpkg.com/dateformat/-/dateformat-3.0.3.tgz#a6e37499a4d9a9cf85ef5872044d62901c9889ae" @@ -3407,10 +3536,10 @@ decamelize@^1.1.0, decamelize@^1.2.0: resolved "https://registry.yarnpkg.com/decamelize/-/decamelize-1.2.0.tgz#f6534d15148269b20352e7bee26f501f9a191290" integrity sha512-z2S+W9X73hAUUki+N+9Za2lBlun89zigOyGrsax+KUQ6wKW4ZoWpEYBkGhQjwAjjDCkWxhY0VKEhk8wzY7F5cA== -decamelize@^5.0.0: - version "5.0.1" - resolved "https://registry.yarnpkg.com/decamelize/-/decamelize-5.0.1.tgz#db11a92e58c741ef339fb0a2868d8a06a9a7b1e9" - integrity sha512-VfxadyCECXgQlkoEAjeghAr5gY3Hf+IKjKb+X8tGVDtveCjN+USwprd2q3QXBR9T1+x2DG0XZF5/w+7HAtSaXA== +decamelize@^6.0.0: + version "6.0.0" + resolved "https://registry.yarnpkg.com/decamelize/-/decamelize-6.0.0.tgz#8cad4d916fde5c41a264a43d0ecc56fe3d31749e" + integrity sha512-Fv96DCsdOgB6mdGl67MT5JaTNKRzrzill5OH5s8bjYJXVlcXyPYGyPsUkWyGV5p1TXI5esYIYMMeDJL0hEIwaA== decimal.js@^10.2.1: version "10.3.1" @@ -3940,10 +4069,10 @@ escodegen@^2.0.0: optionalDependencies: source-map "~0.6.1" -eslint-config-prettier@^8.3.0: - version "8.5.0" - resolved "https://registry.yarnpkg.com/eslint-config-prettier/-/eslint-config-prettier-8.5.0.tgz#5a81680ec934beca02c7b1a61cf8ca34b66feab1" - integrity sha512-obmWKLUNCnhtQRKc+tmnYuQl0pFU1ibYJQ5BGhTVB08bHe9wC8qUeG7c08dj9XX+AuPj1YSGSQIHl1pnDHZR0Q== +eslint-config-prettier@^8.10.0: + version "8.10.0" + resolved "https://registry.yarnpkg.com/eslint-config-prettier/-/eslint-config-prettier-8.10.0.tgz#3a06a662130807e2502fc3ff8b4143d8a0658e11" + integrity sha512-SM8AMJdeQqRYT9O9zguiruQZaN7+z+E4eAP9oiLNGKMtomwaB1E9dcgUD6ZAn/eQAb52USbvezbiljfZUhbJcg== eslint-plugin-es@^3.0.0: version "3.0.1" @@ -3953,10 +4082,10 @@ eslint-plugin-es@^3.0.0: eslint-utils "^2.0.0" regexpp "^3.0.0" -eslint-plugin-jest@^26.1.1: - version "26.5.3" - resolved "https://registry.yarnpkg.com/eslint-plugin-jest/-/eslint-plugin-jest-26.5.3.tgz#a3ceeaf4a757878342b8b00eca92379b246e5505" - integrity sha512-sICclUqJQnR1bFRZGLN2jnSVsYOsmPYYnroGCIMVSvTS3y8XR3yjzy1EcTQmk6typ5pRgyIWzbjqxK6cZHEZuQ== +eslint-plugin-jest@^27.4.0: + version "27.6.0" + resolved "https://registry.yarnpkg.com/eslint-plugin-jest/-/eslint-plugin-jest-27.6.0.tgz#e5c0cf735b3c8cad0ef9db5b565b2fc99f5e55ed" + integrity sha512-MTlusnnDMChbElsszJvrwD1dN3x6nZl//s4JD23BxB6MgR66TZlL064su24xEIS3VACfAoHV1vgyMgPw8nkdng== dependencies: "@typescript-eslint/utils" "^5.10.0" @@ -3972,7 +4101,7 @@ eslint-plugin-node@^11.1.0: resolve "^1.10.1" semver "^6.1.0" -eslint-plugin-prettier@^4.0.0: +eslint-plugin-prettier@^4.2.1: version "4.2.1" resolved "https://registry.yarnpkg.com/eslint-plugin-prettier/-/eslint-plugin-prettier-4.2.1.tgz#651cbb88b1dab98bfd42f017a12fa6b2d993f94b" integrity sha512-f/0rXLXUt0oFYs8ra4w49wYZBG5GKZpAYsJSm6rnYL5uVDjd+zowwMwVZHnAjf4edNrKpCDYfXDgmRE/Ak7QyQ== @@ -3987,10 +4116,10 @@ eslint-scope@5.1.1, eslint-scope@^5.1.1: esrecurse "^4.3.0" estraverse "^4.1.1" -eslint-scope@^7.1.1: - version "7.1.1" - resolved "https://registry.yarnpkg.com/eslint-scope/-/eslint-scope-7.1.1.tgz#fff34894c2f65e5226d3041ac480b4513a163642" - integrity sha512-QKQM/UXpIiHcLqJ5AOyIW7XZmzjkzQXYE54n1++wb0u9V/abW3l9uQnxX8Z5Xd18xyKIMTUAyQ0k1e8pz6LUrw== +eslint-scope@^7.2.2: + version "7.2.2" + resolved "https://registry.yarnpkg.com/eslint-scope/-/eslint-scope-7.2.2.tgz#deb4f92563390f32006894af62a22dba1c46423f" + integrity sha512-dOt21O7lTMhDM+X9mB4GX+DZrZtCUJPL/wlcTqxyrx5IvO0IYtILdtrQGQp+8n5S0gwSVmOf9NQrjMOgfQZlIg== dependencies: esrecurse "^4.3.0" estraverse "^5.2.0" @@ -4024,65 +4153,73 @@ eslint-visitor-keys@^3.3.0: resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-3.3.0.tgz#f6480fa6b1f30efe2d1968aa8ac745b862469826" integrity sha512-mQ+suqKJVyeuwGYHAdjMFqjCyfl8+Ldnxuyp3ldiMBFKkvytrXUZWaiPCEav8qDHKty44bD+qV1IP4T+w+xXRA== -eslint@^8.9.0: - version "8.18.0" - resolved "https://registry.yarnpkg.com/eslint/-/eslint-8.18.0.tgz#78d565d16c993d0b73968c523c0446b13da784fd" - integrity sha512-As1EfFMVk7Xc6/CvhssHUjsAQSkpfXvUGMFC3ce8JDe6WvqCgRrLOBQbVpsBFr1X1V+RACOadnzVvcUS5ni2bA== - dependencies: - "@eslint/eslintrc" "^1.3.0" - "@humanwhocodes/config-array" "^0.9.2" - ajv "^6.10.0" +eslint-visitor-keys@^3.4.1, eslint-visitor-keys@^3.4.3: + version "3.4.3" + resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-3.4.3.tgz#0cd72fe8550e3c2eae156a96a4dddcd1c8ac5800" + integrity sha512-wpc+LXeiyiisxPlEkUzU6svyS1frIO3Mgxj1fdy7Pm8Ygzguax2N3Fa/D/ag1WqbOprdI+uY6wMUl8/a2G+iag== + +eslint@^8.50.0: + version "8.52.0" + resolved "https://registry.yarnpkg.com/eslint/-/eslint-8.52.0.tgz#d0cd4a1fac06427a61ef9242b9353f36ea7062fc" + integrity sha512-zh/JHnaixqHZsolRB/w9/02akBk9EPrOs9JwcTP2ek7yL5bVvXuRariiaAjjoJ5DvuwQ1WAE/HsMz+w17YgBCg== + dependencies: + "@eslint-community/eslint-utils" "^4.2.0" + "@eslint-community/regexpp" "^4.6.1" + "@eslint/eslintrc" "^2.1.2" + "@eslint/js" "8.52.0" + "@humanwhocodes/config-array" "^0.11.13" + "@humanwhocodes/module-importer" "^1.0.1" + "@nodelib/fs.walk" "^1.2.8" + "@ungap/structured-clone" "^1.2.0" + ajv "^6.12.4" chalk "^4.0.0" cross-spawn "^7.0.2" debug "^4.3.2" doctrine "^3.0.0" escape-string-regexp "^4.0.0" - eslint-scope "^7.1.1" - eslint-utils "^3.0.0" - eslint-visitor-keys "^3.3.0" - espree "^9.3.2" - esquery "^1.4.0" + eslint-scope "^7.2.2" + eslint-visitor-keys "^3.4.3" + espree "^9.6.1" + esquery "^1.4.2" esutils "^2.0.2" fast-deep-equal "^3.1.3" file-entry-cache "^6.0.1" - functional-red-black-tree "^1.0.1" - glob-parent "^6.0.1" - globals "^13.15.0" + find-up "^5.0.0" + glob-parent "^6.0.2" + globals "^13.19.0" + graphemer "^1.4.0" ignore "^5.2.0" - import-fresh "^3.0.0" imurmurhash "^0.1.4" is-glob "^4.0.0" + is-path-inside "^3.0.3" js-yaml "^4.1.0" json-stable-stringify-without-jsonify "^1.0.1" levn "^0.4.1" lodash.merge "^4.6.2" minimatch "^3.1.2" natural-compare "^1.4.0" - optionator "^0.9.1" - regexpp "^3.2.0" + optionator "^0.9.3" strip-ansi "^6.0.1" - strip-json-comments "^3.1.0" text-table "^0.2.0" - v8-compile-cache "^2.0.3" -espree@^9.3.2: - version "9.3.2" - resolved "https://registry.yarnpkg.com/espree/-/espree-9.3.2.tgz#f58f77bd334731182801ced3380a8cc859091596" - integrity sha512-D211tC7ZwouTIuY5x9XnS0E9sWNChB7IYKX/Xp5eQj3nFXhqmiUDB9q27y76oFl8jTg3pXcQx/bpxMfs3CIZbA== +espree@^9.6.0, espree@^9.6.1: + version "9.6.1" + resolved "https://registry.yarnpkg.com/espree/-/espree-9.6.1.tgz#a2a17b8e434690a5432f2f8018ce71d331a48c6f" + integrity sha512-oruZaFkjorTpF32kDSI5/75ViwGeZginGGy2NoOSg3Q9bnwlnmDm4HLnkl0RE3n+njDXR037aY1+x58Z/zFdwQ== dependencies: - acorn "^8.7.1" + acorn "^8.9.0" acorn-jsx "^5.3.2" - eslint-visitor-keys "^3.3.0" + eslint-visitor-keys "^3.4.1" esprima@^4.0.0, esprima@^4.0.1: version "4.0.1" resolved "https://registry.yarnpkg.com/esprima/-/esprima-4.0.1.tgz#13b04cdb3e6c5d19df91ab6987a8695619b0aa71" integrity sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A== -esquery@^1.4.0: - version "1.4.0" - resolved "https://registry.yarnpkg.com/esquery/-/esquery-1.4.0.tgz#2148ffc38b82e8c7057dfed48425b3e61f0f24a5" - integrity sha512-cCDispWt5vHHtwMY2YrAQ4ibFkAL8RbH5YGBnZBc90MolvvfkkQcJro/aZiAQUlQ3qgrYS6D6v8Gc5G5CQsc9w== +esquery@^1.4.2: + version "1.5.0" + resolved "https://registry.yarnpkg.com/esquery/-/esquery-1.5.0.tgz#6ce17738de8577694edd7361c57182ac8cb0db0b" + integrity sha512-YQLXUplAwJgCydQ78IMJywZCceoqk1oH01OERdSAJc/7U2AylwjhSCLDEtqwg811idIS/9fIU5GjG73IgjKMVg== dependencies: estraverse "^5.1.0" @@ -4161,7 +4298,7 @@ execa@^4.0.0: signal-exit "^3.0.2" strip-final-newline "^2.0.0" -execa@^5.0.0, execa@^5.1.1: +execa@^5.0.0: version "5.1.1" resolved "https://registry.yarnpkg.com/execa/-/execa-5.1.1.tgz#f80ad9cbf4298f7bd1d4c9555c21e93741c411dd" integrity sha512-8uSpZZocAZRBAPIEINJj3Lo9HyGitllczc27Eh5YYojjMFMn8yHMDMaUHE2Jqfq05D/wucwI4JGURyXt1vchyg== @@ -4176,6 +4313,21 @@ execa@^5.0.0, execa@^5.1.1: signal-exit "^3.0.3" strip-final-newline "^2.0.0" +execa@^7.0.0: + version "7.2.0" + resolved "https://registry.yarnpkg.com/execa/-/execa-7.2.0.tgz#657e75ba984f42a70f38928cedc87d6f2d4fe4e9" + integrity sha512-UduyVP7TLB5IcAQl+OzLyLcS/l32W/GLg+AhHJ+ow40FOk2U3SAllPwR44v4vmdFwIWqpdwxxpQbF1n5ta9seA== + dependencies: + cross-spawn "^7.0.3" + get-stream "^6.0.1" + human-signals "^4.3.0" + is-stream "^3.0.0" + merge-stream "^2.0.0" + npm-run-path "^5.1.0" + onetime "^6.0.0" + signal-exit "^3.0.7" + strip-final-newline "^3.0.0" + exit@^0.1.2: version "0.1.2" resolved "https://registry.yarnpkg.com/exit/-/exit-0.1.2.tgz#0632638f8d877cc82107d30a0fff1a17cba1cd0c" @@ -4653,6 +4805,11 @@ function-bind@^1.1.1: resolved "https://registry.yarnpkg.com/function-bind/-/function-bind-1.1.1.tgz#a56899d3ea3c9bab874bb9773b7c5ede92f4895d" integrity sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A== +function-bind@^1.1.2: + version "1.1.2" + resolved "https://registry.yarnpkg.com/function-bind/-/function-bind-1.1.2.tgz#2c02d864d97f3ea6c8830c464cbd11ab6eab7a1c" + integrity sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA== + function.prototype.name@^1.1.5: version "1.1.5" resolved "https://registry.yarnpkg.com/function.prototype.name/-/function.prototype.name-1.1.5.tgz#cce0505fe1ffb80503e6f9e46cc64e46a12a9621" @@ -4663,11 +4820,6 @@ function.prototype.name@^1.1.5: es-abstract "^1.19.0" functions-have-names "^1.2.2" -functional-red-black-tree@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/functional-red-black-tree/-/functional-red-black-tree-1.0.1.tgz#1b0ab3bd553b2a0d6399d29c0e3ea0b252078327" - integrity sha512-dsKNQNdj6xA3T+QlADDA7mOSlX0qiMINjn0cgr+eGHGsbSHzTabcIogz2+p/iqP1Xs6EP/sS2SbqH+brGTbq0g== - functions-have-names@^1.2.2: version "1.2.3" resolved "https://registry.yarnpkg.com/functions-have-names/-/functions-have-names-1.2.3.tgz#0404fe4ee2ba2f607f0e0ec3c80bae994133b834" @@ -4760,7 +4912,7 @@ get-stream@^5.0.0, get-stream@^5.1.0: dependencies: pump "^3.0.0" -get-stream@^6.0.0: +get-stream@^6.0.0, get-stream@^6.0.1: version "6.0.1" resolved "https://registry.yarnpkg.com/get-stream/-/get-stream-6.0.1.tgz#a262d8eef67aced57c2852ad6167526a43cbf7b7" integrity sha512-ts6Wi+2j3jQjqi70w5AlN8DFnkSwC+MqmxEzdEALB2qXZYV3X/b1CTfgPLGJNMeAWxdPfU8FO1ms3NUfaHCPYg== @@ -4854,7 +5006,7 @@ glob-parent@^5.1.1, glob-parent@^5.1.2: dependencies: is-glob "^4.0.1" -glob-parent@^6.0.1: +glob-parent@^6.0.2: version "6.0.2" resolved "https://registry.yarnpkg.com/glob-parent/-/glob-parent-6.0.2.tgz#6d237d99083950c79290f24c7642a3de9a28f9e3" integrity sha512-XxwI8EOhVQgWp6iDL+3b0r86f4d6AX6zSU55HfB4ydCEuXLXc5FcYeOu+nnGftS4TEju/11rt4KJPTMgbfmv4A== @@ -4871,7 +5023,7 @@ glob-to-regexp@^0.4.1: resolved "https://registry.yarnpkg.com/glob-to-regexp/-/glob-to-regexp-0.4.1.tgz#c75297087c851b9a578bd217dd59a92f59fe546e" integrity sha512-lkX1HJXwyMcprw/5YUZc2s7DrpAiHB21/V+E1rHUrVNokkvB6bqMzT0VfV6/86ZNabt1k14YOIaT7nDvOX3Iiw== -glob@^7.0.0, glob@^7.0.3, glob@^7.1.1, glob@^7.1.2, glob@^7.1.3, glob@^7.1.4, glob@^7.1.6: +glob@^7.0.3, glob@^7.1.1, glob@^7.1.2, glob@^7.1.3, glob@^7.1.4, glob@^7.1.6: version "7.2.3" resolved "https://registry.yarnpkg.com/glob/-/glob-7.2.3.tgz#b8df0fb802bbfa8e89bd1d938b4e16578ed44f2b" integrity sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q== @@ -4888,10 +5040,10 @@ globals@^11.1.0: resolved "https://registry.yarnpkg.com/globals/-/globals-11.12.0.tgz#ab8795338868a0babd8525758018c2a7eb95c42e" integrity sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA== -globals@^13.15.0: - version "13.15.0" - resolved "https://registry.yarnpkg.com/globals/-/globals-13.15.0.tgz#38113218c907d2f7e98658af246cef8b77e90bac" - integrity sha512-bpzcOlgDhMG070Av0Vy5Owklpv1I6+j96GhUI7Rh7IzDCKLzboflLrrfqMu8NquDbiR4EOQk7XzJwqVJxicxog== +globals@^13.19.0: + version "13.23.0" + resolved "https://registry.yarnpkg.com/globals/-/globals-13.23.0.tgz#ef31673c926a0976e1f61dab4dca57e0c0a8af02" + integrity sha512-XAmF0RjlrjY23MA51q3HltdlGxUpXPvg0GioKiD9X6HD28iMjo2dKC8Vqwm7lne4GNr78+RHTfliktR6ZH09wA== dependencies: type-fest "^0.20.2" @@ -4977,6 +5129,11 @@ graceful-fs@^4.1.10, graceful-fs@^4.1.11, graceful-fs@^4.1.15, graceful-fs@^4.1. resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.2.10.tgz#147d3a006da4ca3ce14728c7aefc287c367d7a6c" integrity sha512-9ByhssR2fPVsNZj478qUUbKfmL0+t5BDVyjShtyZZLiK7ZDAArFFfopyOTj0M05wE2tJPisA4iTnnXl2YoPvOA== +graphemer@^1.4.0: + version "1.4.0" + resolved "https://registry.yarnpkg.com/graphemer/-/graphemer-1.4.0.tgz#fb2f1d55e0e3a1849aeffc90c4fa0dd53a0e66c6" + integrity sha512-EtKwoO6kxCL9WO5xipiHTZlSzBm7WLT627TqC/uVRd0HKmq8NXyebnNYxDoBi7wt8eTWrUrKXCOVaFq9x1kgag== + growly@^1.3.0: version "1.3.0" resolved "https://registry.yarnpkg.com/growly/-/growly-1.3.0.tgz#f10748cbe76af964b7c96c93c6bcc28af120c081" @@ -5106,6 +5263,13 @@ has@^1.0.3: dependencies: function-bind "^1.1.1" +hasown@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/hasown/-/hasown-2.0.0.tgz#f4c513d454a57b7c7e1650778de226b11700546c" + integrity sha512-vUptKVTpIJhcczKBbgnS+RtcuYMB8+oNzPK2/Hp3hanz8JmpATdmmgLgSaadVREkDm+e2giHwY3ZRkyjSIDDFA== + dependencies: + function-bind "^1.1.2" + hosted-git-info@^2.1.4: version "2.8.9" resolved "https://registry.yarnpkg.com/hosted-git-info/-/hosted-git-info-2.8.9.tgz#dffc0bf9a21c02209090f2aa69429e1414daf3f9" @@ -5118,6 +5282,13 @@ hosted-git-info@^4.0.0, hosted-git-info@^4.0.1: dependencies: lru-cache "^6.0.0" +hosted-git-info@^5.0.0: + version "5.2.1" + resolved "https://registry.yarnpkg.com/hosted-git-info/-/hosted-git-info-5.2.1.tgz#0ba1c97178ef91f3ab30842ae63d6a272341156f" + integrity sha512-xIcQYMnhcx2Nr4JTjsFmwwnr9vldugPy9uVm0o87bjqqWMv9GaqsTeT+i99wTl0mk1uLxJtHxLb8kymqTENQsw== + dependencies: + lru-cache "^7.5.1" + hpack.js@^2.1.6: version "2.1.6" resolved "https://registry.yarnpkg.com/hpack.js/-/hpack.js-2.1.6.tgz#87774c0949e513f42e84575b3c45681fade2a0b2" @@ -5241,6 +5412,11 @@ human-signals@^2.1.0: resolved "https://registry.yarnpkg.com/human-signals/-/human-signals-2.1.0.tgz#dc91fcba42e4d06e4abaed33b3e7a3c02f514ea0" integrity sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw== +human-signals@^4.3.0: + version "4.3.1" + resolved "https://registry.yarnpkg.com/human-signals/-/human-signals-4.3.1.tgz#ab7f811e851fca97ffbd2c1fe9a958964de321b2" + integrity sha512-nZXjEF2nbo7lIw3mgYjItAfgQXog3OjJogSbKa2CQIIvSGWcKgeJnQlNXip6NglNzYH45nSRiEVimMvYL8DDqQ== + humanize-ms@^1.2.1: version "1.2.1" resolved "https://registry.yarnpkg.com/humanize-ms/-/humanize-ms-1.2.1.tgz#c46e3159a293f6b896da29316d8b6fe8bb79bbed" @@ -5248,10 +5424,10 @@ humanize-ms@^1.2.1: dependencies: ms "^2.0.0" -husky@^7.0.4: - version "7.0.4" - resolved "https://registry.yarnpkg.com/husky/-/husky-7.0.4.tgz#242048245dc49c8fb1bf0cc7cfb98dd722531535" - integrity sha512-vbaCKN2QLtP/vD4yvs6iz6hBEo6wkSzs8HpRah1Z6aGmF2KW5PdYuAd7uX5a+OyBZHBhd+TFLqgjUgytQr4RvQ== +husky@^8.0.3: + version "8.0.3" + resolved "https://registry.yarnpkg.com/husky/-/husky-8.0.3.tgz#4936d7212e46d1dea28fef29bb3a108872cd9184" + integrity sha512-+dQSyqPh4x1hlO1swXBiNb2HzTDN1I2IGLQx1GrBuiqFJfoMrnZWwVmatvSiO+Iz8fBUnf+lekwNo4c2LlXItg== iconv-lite@0.4.24, iconv-lite@^0.4.24: version "0.4.24" @@ -5289,7 +5465,7 @@ ignore@^5.1.1, ignore@^5.2.0: resolved "https://registry.yarnpkg.com/ignore/-/ignore-5.2.0.tgz#6d3bac8fa7fe0d45d9f9be7bac2fc279577e345a" integrity sha512-CmxgYGiEPCLhfLnpPp1MoRmifwEIOgjcHXxOBjv7mY96c+eWScsOP9c112ZyLdWHi0FxHjI+4uVhKYp/gcdRmQ== -import-fresh@^3.0.0, import-fresh@^3.2.1: +import-fresh@^3.2.1: version "3.3.0" resolved "https://registry.yarnpkg.com/import-fresh/-/import-fresh-3.3.0.tgz#37162c25fcb9ebaa2e6e53d5b4d88ce17d9e0c2b" integrity sha512-veYYhQa+D1QBKznvhUHxb8faxlrwUnxseDAbAp457E0wLNio2bOSKnjYDhMj+YiAq61xrMGhQk9iXVk5FzgQMw== @@ -5405,11 +5581,6 @@ internal-slot@^1.0.3: has "^1.0.3" side-channel "^1.0.4" -interpret@^1.0.0: - version "1.4.0" - resolved "https://registry.yarnpkg.com/interpret/-/interpret-1.4.0.tgz#665ab8bc4da27a774a40584e812e3e0fa45b1a1e" - integrity sha512-agE4QfB2Lkp9uICn7BAqoscw4SZP9kTE2hxiFI3jBPmXJfdqiahTbUuKGsMoN2GtqL9AxhYioAcVvgsb1HvRbA== - interpret@^2.2.0: version "2.2.0" resolved "https://registry.yarnpkg.com/interpret/-/interpret-2.2.0.tgz#1a78a0b5965c40a5416d007ad6f50ad27c417df9" @@ -5521,6 +5692,13 @@ is-core-module@^2.5.0, is-core-module@^2.9.0: dependencies: has "^1.0.3" +is-core-module@^2.8.1: + version "2.13.1" + resolved "https://registry.yarnpkg.com/is-core-module/-/is-core-module-2.13.1.tgz#ad0d7532c6fea9da1ebdc82742d74525c6273384" + integrity sha512-hHrIjvZsftOsvKSn2TRYl63zvxsgE0K+0mYMoH6gD4omR5IWB2KynivBQczo3+wF1cCkjzvptnI9Q0sPU66ilw== + dependencies: + hasown "^2.0.0" + is-data-descriptor@^0.1.4: version "0.1.4" resolved "https://registry.yarnpkg.com/is-data-descriptor/-/is-data-descriptor-0.1.4.tgz#0b5ee648388e2c860282e793f1856fec3f301b56" @@ -5686,6 +5864,11 @@ is-path-inside@^2.1.0: dependencies: path-is-inside "^1.0.2" +is-path-inside@^3.0.3: + version "3.0.3" + resolved "https://registry.yarnpkg.com/is-path-inside/-/is-path-inside-3.0.3.tgz#d231362e53a07ff2b0e0ea7fed049161ffd16283" + integrity sha512-Fd4gABb+ycGAmKou8eMftCupSir5lRxqf4aD/vd0cD2qc4HL07OjCeuHMr8Ro4CoMaeCKDB0/ECBOVWjTwUvPQ== + is-plain-obj@^1.0.0, is-plain-obj@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/is-plain-obj/-/is-plain-obj-1.1.0.tgz#71a50c8429dfca773c92a390a4a03b39fcd51d3e" @@ -5750,6 +5933,11 @@ is-stream@^2.0.0: resolved "https://registry.yarnpkg.com/is-stream/-/is-stream-2.0.1.tgz#fac1e3d53b97ad5a9d0ae9cef2389f5810a5c077" integrity sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg== +is-stream@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/is-stream/-/is-stream-3.0.0.tgz#e6bfd7aa6bef69f4f472ce9bb681e3e57b4319ac" + integrity sha512-LnQR4bZ9IADDRSkvpqMGvt/tEJWclzklNgSw48V5EAaAeDd6qGvN8ei6k5p0tvxSR171VmGyHuTiAOfxAbr8kA== + is-string@^1.0.5, is-string@^1.0.7: version "1.0.7" resolved "https://registry.yarnpkg.com/is-string/-/is-string-1.0.7.tgz#0dd12bf2006f255bb58f695110eff7491eebc0fd" @@ -6526,47 +6714,46 @@ license-checker@^25.0.1: spdx-satisfies "^4.0.0" treeify "^1.1.0" -lilconfig@2.0.5: - version "2.0.5" - resolved "https://registry.yarnpkg.com/lilconfig/-/lilconfig-2.0.5.tgz#19e57fd06ccc3848fd1891655b5a447092225b25" - integrity sha512-xaYmXZtTHPAw5m+xLN8ab9C+3a8YmV3asNSPOATITbtwrfbwaLJj8h66H1WMIpALCkqsIzK3h7oQ+PdX+LQ9Eg== +lilconfig@2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/lilconfig/-/lilconfig-2.1.0.tgz#78e23ac89ebb7e1bfbf25b18043de756548e7f52" + integrity sha512-utWOt/GHzuUxnLKxB6dk81RoOeoNeHgbrXiuGk4yyF5qlRz+iIVWu56E2fqGHFrXz0QNUhLB/8nKqvRH66JKGQ== lines-and-columns@^1.1.6: version "1.2.4" resolved "https://registry.yarnpkg.com/lines-and-columns/-/lines-and-columns-1.2.4.tgz#eca284f75d2965079309dc0ad9255abb2ebc1632" integrity sha512-7ylylesZQ/PV29jhEDl3Ufjo6ZX7gCqJr5F7PKrqc93v7fzSymt1BpwEU8nAUXs8qzzvqhbjhK5QZg6Mt/HkBg== -lint-staged@^12.3.4: - version "12.5.0" - resolved "https://registry.yarnpkg.com/lint-staged/-/lint-staged-12.5.0.tgz#d6925747480ae0e380d13988522f9dd8ef9126e3" - integrity sha512-BKLUjWDsKquV/JuIcoQW4MSAI3ggwEImF1+sB4zaKvyVx1wBk3FsG7UK9bpnmBTN1pm7EH2BBcMwINJzCRv12g== +lint-staged@13.2.2: + version "13.2.2" + resolved "https://registry.yarnpkg.com/lint-staged/-/lint-staged-13.2.2.tgz#5e711d3139c234f73402177be2f8dd312e6508ca" + integrity sha512-71gSwXKy649VrSU09s10uAT0rWCcY3aewhMaHyl2N84oBk4Xs9HgxvUp3AYu+bNsK4NrOYYxvSgg7FyGJ+jGcA== dependencies: + chalk "5.2.0" cli-truncate "^3.1.0" - colorette "^2.0.16" - commander "^9.3.0" + commander "^10.0.0" debug "^4.3.4" - execa "^5.1.1" - lilconfig "2.0.5" - listr2 "^4.0.5" + execa "^7.0.0" + lilconfig "2.1.0" + listr2 "^5.0.7" micromatch "^4.0.5" normalize-path "^3.0.0" - object-inspect "^1.12.2" - pidtree "^0.5.0" + object-inspect "^1.12.3" + pidtree "^0.6.0" string-argv "^0.3.1" - supports-color "^9.2.2" - yaml "^1.10.2" + yaml "^2.2.2" -listr2@^4.0.5: - version "4.0.5" - resolved "https://registry.yarnpkg.com/listr2/-/listr2-4.0.5.tgz#9dcc50221583e8b4c71c43f9c7dfd0ef546b75d5" - integrity sha512-juGHV1doQdpNT3GSTs9IUN43QJb7KHdF9uqg7Vufs/tG9VTzpFphqF4pm/ICdAABGQxsyNn9CiYA3StkI6jpwA== +listr2@^5.0.7: + version "5.0.8" + resolved "https://registry.yarnpkg.com/listr2/-/listr2-5.0.8.tgz#a9379ffeb4bd83a68931a65fb223a11510d6ba23" + integrity sha512-mC73LitKHj9w6v30nLNGPetZIlfpUniNSsxxrbaPcWOjDb92SHPzJPi/t+v1YC/lxKz/AJ9egOjww0qUuFxBpA== dependencies: cli-truncate "^2.1.0" - colorette "^2.0.16" + colorette "^2.0.19" log-update "^4.0.0" p-map "^4.0.0" rfdc "^1.3.0" - rxjs "^7.5.5" + rxjs "^7.8.0" through "^2.3.8" wrap-ansi "^7.0.0" @@ -6720,6 +6907,11 @@ lru-cache@^6.0.0: dependencies: yallist "^4.0.0" +lru-cache@^7.5.1: + version "7.18.3" + resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-7.18.3.tgz#f793896e0fd0e954a59dfdd82f0773808df6aa89" + integrity sha512-jumlc0BIUrS3qJGgIkWZsyfAM7NCWiBcCDhnd+3NNM5KbBmLTgHVfWBcg6W+rLUsIpzpERPsvwUP7CckAQSOoA== + make-dir@^1.0.0, make-dir@^1.2.0: version "1.3.0" resolved "https://registry.yarnpkg.com/make-dir/-/make-dir-1.3.0.tgz#79c1033b80515bd6d24ec9933e860ca75ee27f0c" @@ -6807,7 +6999,7 @@ map-obj@^1.0.0: resolved "https://registry.yarnpkg.com/map-obj/-/map-obj-1.0.1.tgz#d933ceb9205d82bdcf4886f6742bdc2b4dea146d" integrity sha512-7N/q3lyZ+LVCp7PzuxrJr4KMbBE2hW7BT7YNia330OFxIf4d3r5zVpicP2650l7CPN6RM9zOJRl3NGpqSiw3Eg== -map-obj@^4.0.0, map-obj@^4.1.0: +map-obj@^4.0.0, map-obj@^4.3.0: version "4.3.0" resolved "https://registry.yarnpkg.com/map-obj/-/map-obj-4.3.0.tgz#9304f906e93faae70880da102a9f1df0ea8bb05a" integrity sha512-hdN1wVrZbb29eBGiGjJbeP8JbKjq1urkHJ/LIP/NY48MZ1QVXUsQBV1G1zvYFHn1XE06cwjBsOI2K3Ulnj1YXQ== @@ -6840,23 +7032,23 @@ memory-fs@^0.5.0: errno "^0.1.3" readable-stream "^2.0.1" -meow@^10.1.2: - version "10.1.3" - resolved "https://registry.yarnpkg.com/meow/-/meow-10.1.3.tgz#21689959a7d00e8901aff30d208acb2122eb8088" - integrity sha512-0WL7RMCPPdUTE00+GxJjL4d5Dm6eUbmAzxlzywJWiRUKCW093owmZ7/q74tH9VI91vxw9KJJNxAcvdpxb2G4iA== +meow@^11.0.0: + version "11.0.0" + resolved "https://registry.yarnpkg.com/meow/-/meow-11.0.0.tgz#273a19c12d49d013c56effe9f011994022887157" + integrity sha512-Cl0yeeIrko6d94KpUo1M+0X1sB14ikoaqlIGuTH1fW4I+E3+YljL54/hb/BWmVfrV9tTV9zU04+xjw08Fh2WkA== dependencies: "@types/minimist" "^1.2.2" - camelcase-keys "^7.0.0" - decamelize "^5.0.0" + camelcase-keys "^8.0.2" + decamelize "^6.0.0" decamelize-keys "^1.1.0" hard-rejection "^2.1.0" minimist-options "4.1.0" - normalize-package-data "^3.0.2" - read-pkg-up "^8.0.0" + normalize-package-data "^4.0.1" + read-pkg-up "^9.1.0" redent "^4.0.0" trim-newlines "^4.0.2" - type-fest "^1.2.2" - yargs-parser "^20.2.9" + type-fest "^3.1.0" + yargs-parser "^21.1.1" meow@^8.0.0: version "8.1.2" @@ -6959,6 +7151,11 @@ mimic-fn@^2.1.0: resolved "https://registry.yarnpkg.com/mimic-fn/-/mimic-fn-2.1.0.tgz#7ed2c2ccccaf84d3ffcb7a69b57711fc2083401b" integrity sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg== +mimic-fn@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/mimic-fn/-/mimic-fn-4.0.0.tgz#60a90550d5cb0b239cca65d893b1a53b29871ecc" + integrity sha512-vqiC06CuhBTUdZH+RYl8sFrL096vA45Ok5ISO6sE/Mr1jRbGH4Csnhi8f3wKVl7x8mO4Au7Ir9D3Oyv1VYMFJw== + mimic-response@^1.0.0, mimic-response@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/mimic-response/-/mimic-response-1.0.1.tgz#4923538878eef42063cb8a3e3b0798781487ab1b" @@ -6979,7 +7176,7 @@ minimalistic-assert@^1.0.0: resolved "https://registry.yarnpkg.com/minimalistic-assert/-/minimalistic-assert-1.0.1.tgz#2e194de044626d4a10e7f7fbc00ce73e83e4d5c7" integrity sha512-UtJcAD4yEaGtjPezWuO9wC4nwUnVH/8/Im3yEHQP4b67cXlD/Qr9hdITCU1xDbSEXg2XKNaP8jsReV7vQd00/A== -minimatch@^3.0.4, minimatch@^3.1.1, minimatch@^3.1.2: +minimatch@^3.0.4, minimatch@^3.0.5, minimatch@^3.1.1, minimatch@^3.1.2: version "3.1.2" resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.1.2.tgz#19cd194bfd3e428f049a70817c038d89ab4be35b" integrity sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw== @@ -7195,6 +7392,11 @@ napi-build-utils@^1.0.1: resolved "https://registry.yarnpkg.com/napi-build-utils/-/napi-build-utils-1.0.2.tgz#b1fddc0b2c46e380a0b7a76f984dd47c41a13806" integrity sha512-ONmRUqK7zj7DWX0D9ADe03wbwOBZxNAfF20PlGfCWQcD3+/MakShIHrMqx9YwPTfxDdF1zLeL+RGZiR9kGMLdg== +natural-compare-lite@^1.4.0: + version "1.4.0" + resolved "https://registry.yarnpkg.com/natural-compare-lite/-/natural-compare-lite-1.4.0.tgz#17b09581988979fddafe0201e931ba933c96cbb4" + integrity sha512-Tj+HTDSJJKaZnfiuw+iaF9skdPpTo2GtEly5JHnWV/hfv2Qj/9RKsGISQtLh2ox3l5EAGw487hnBee0sIJ6v2g== + natural-compare@^1.4.0: version "1.4.0" resolved "https://registry.yarnpkg.com/natural-compare/-/natural-compare-1.4.0.tgz#4abebfeed7541f2c27acfb29bdbbd15c8d5ba4f7" @@ -7369,6 +7571,16 @@ normalize-package-data@^3.0.0, normalize-package-data@^3.0.2: semver "^7.3.4" validate-npm-package-license "^3.0.1" +normalize-package-data@^4.0.1: + version "4.0.1" + resolved "https://registry.yarnpkg.com/normalize-package-data/-/normalize-package-data-4.0.1.tgz#b46b24e0616d06cadf9d5718b29b6d445a82a62c" + integrity sha512-EBk5QKKuocMJhB3BILuKhmaPjI8vNRSpIfO9woLC6NyHVkKKdVEdAO1mrT0ZfxNR1lKwCcTkuZfmGIFdizZ8Pg== + dependencies: + hosted-git-info "^5.0.0" + is-core-module "^2.8.1" + semver "^7.3.5" + validate-npm-package-license "^3.0.4" + normalize-path@^2.1.1: version "2.1.1" resolved "https://registry.yarnpkg.com/normalize-path/-/normalize-path-2.1.1.tgz#1ab28b556e198363a8c1a6f7e6fa20137fe6aed9" @@ -7510,6 +7722,13 @@ npm-run-path@^4.0.0, npm-run-path@^4.0.1: dependencies: path-key "^3.0.0" +npm-run-path@^5.1.0: + version "5.1.0" + resolved "https://registry.yarnpkg.com/npm-run-path/-/npm-run-path-5.1.0.tgz#bc62f7f3f6952d9894bd08944ba011a6ee7b7e00" + integrity sha512-sJOdmRGrY2sjNTRMbSvluQqg+8X7ZK61yvzBEIDhz4f8z1TZFYABsqjjCBd/0PUNE9M6QDgHJXQkGUEm7Q+l9Q== + dependencies: + path-key "^4.0.0" + npmlog@^4.0.1, npmlog@^4.1.2: version "4.1.2" resolved "https://registry.yarnpkg.com/npmlog/-/npmlog-4.1.2.tgz#08a7f2a8bf734604779a9efa4ad5cc717abb954b" @@ -7549,11 +7768,16 @@ object-copy@^0.1.0: define-property "^0.2.5" kind-of "^3.0.3" -object-inspect@^1.12.0, object-inspect@^1.12.2, object-inspect@^1.9.0: +object-inspect@^1.12.0, object-inspect@^1.9.0: version "1.12.2" resolved "https://registry.yarnpkg.com/object-inspect/-/object-inspect-1.12.2.tgz#c0641f26394532f28ab8d796ab954e43c009a8ea" integrity sha512-z+cPxW0QGUp0mcqcsgQyLVRDoXFQbXOwBaqyF7VIgI4TWNQsDHrBpUQslRmIfAoYWdYzs6UlKJtB2XJpTaNSpQ== +object-inspect@^1.12.3: + version "1.13.1" + resolved "https://registry.yarnpkg.com/object-inspect/-/object-inspect-1.13.1.tgz#b96c6109324ccfef6b12216a956ca4dc2ff94bc2" + integrity sha512-5qoj1RUiKOMsCCNLV1CBiPYE10sziTsnmNxkAI/rZhiD63CF7IqdFGC/XzjWjpSgLf0LxXX3bDFIh0E18f6UhQ== + object-is@^1.0.1: version "1.1.5" resolved "https://registry.yarnpkg.com/object-is/-/object-is-1.1.5.tgz#b9deeaa5fc7f1846a0faecdceec138e5778f53ac" @@ -7639,6 +7863,13 @@ onetime@^5.1.0, onetime@^5.1.2: dependencies: mimic-fn "^2.1.0" +onetime@^6.0.0: + version "6.0.0" + resolved "https://registry.yarnpkg.com/onetime/-/onetime-6.0.0.tgz#7c24c18ed1fd2e9bca4bd26806a33613c77d34b4" + integrity sha512-1FlR+gjXK7X+AsAHso35MnyN5KqGwJRi/31ft6x0M194ht7S+rWAvd7PHss9xSKMzE0asv1pyIHaJYq+BbacAQ== + dependencies: + mimic-fn "^4.0.0" + opn@^5.5.0: version "5.5.0" resolved "https://registry.yarnpkg.com/opn/-/opn-5.5.0.tgz#fc7164fab56d235904c51c3b27da6758ca3b9bfc" @@ -7658,17 +7889,17 @@ optionator@^0.8.1: type-check "~0.3.2" word-wrap "~1.2.3" -optionator@^0.9.1: - version "0.9.1" - resolved "https://registry.yarnpkg.com/optionator/-/optionator-0.9.1.tgz#4f236a6373dae0566a6d43e1326674f50c291499" - integrity sha512-74RlY5FCnhq4jRxVUPKDaRwrVNXMqsGsiW6AJw4XK8hmtm10wC0ypZBLw5IIp85NZMr91+qd1RvvENwg7jjRFw== +optionator@^0.9.3: + version "0.9.3" + resolved "https://registry.yarnpkg.com/optionator/-/optionator-0.9.3.tgz#007397d44ed1872fdc6ed31360190f81814e2c64" + integrity sha512-JjCoypp+jKn1ttEFExxhetCKeJt9zhAgAve5FXHixTvFDW/5aEktX9bufBKLRRMdU7bNtpLfcGu94B3cdEJgjg== dependencies: + "@aashutoshrathi/word-wrap" "^1.2.3" deep-is "^0.1.3" fast-levenshtein "^2.0.6" levn "^0.4.1" prelude-ls "^1.2.1" type-check "^0.4.0" - word-wrap "^1.2.3" ora@^3.4.0: version "3.4.0" @@ -7993,6 +8224,11 @@ path-key@^3.0.0, path-key@^3.1.0: resolved "https://registry.yarnpkg.com/path-key/-/path-key-3.1.1.tgz#581f6ade658cbba65a0d3380de7753295054f375" integrity sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q== +path-key@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/path-key/-/path-key-4.0.0.tgz#295588dc3aee64154f877adb9d780b81c554bf18" + integrity sha512-haREypq7xkM7ErfgIyA0z+Bj4AGKlMSdlQE2jvJo6huWD1EdkKYV+G/T4nq0YEF2vgTT8kqMFKo1uHn950r4SQ== + path-parse@^1.0.7: version "1.0.7" resolved "https://registry.yarnpkg.com/path-parse/-/path-parse-1.0.7.tgz#fbc114b60ca42b30d9daf5858e4bd68bbedb6735" @@ -8035,10 +8271,10 @@ picomatch@^2.0.4, picomatch@^2.3.1: resolved "https://registry.yarnpkg.com/picomatch/-/picomatch-2.3.1.tgz#3ba3833733646d9d3e4995946c1365a67fb07a42" integrity sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA== -pidtree@^0.5.0: - version "0.5.0" - resolved "https://registry.yarnpkg.com/pidtree/-/pidtree-0.5.0.tgz#ad5fbc1de78b8a5f99d6fbdd4f6e4eee21d1aca1" - integrity sha512-9nxspIM7OpZuhBxPg73Zvyq7j1QMPMPsGKTqRc2XOaFQauDvoNz9fM1Wdkjmeo7l9GXOZiRs97sPkuayl39wjA== +pidtree@^0.6.0: + version "0.6.0" + resolved "https://registry.yarnpkg.com/pidtree/-/pidtree-0.6.0.tgz#90ad7b6d42d5841e69e0a2419ef38f8883aa057c" + integrity sha512-eG2dWTVw5bzqGRztnHExczNxt5VGsE6OwTeCG3fdUf9KBsZzO3R5OIIIzWR+iZA0NtZ+RDVdaoE2dK1cn6jH4g== pify@^2.0.0, pify@^2.3.0: version "2.3.0" @@ -8146,10 +8382,10 @@ prettier-linter-helpers@^1.0.0: dependencies: fast-diff "^1.1.2" -prettier@^2.5.1: - version "2.7.1" - resolved "https://registry.yarnpkg.com/prettier/-/prettier-2.7.1.tgz#e235806850d057f97bb08368a4f7d899f7760c64" - integrity sha512-ujppO+MkdPqoVINuDFDRLClm7D78qbDt0/NR+wp5FqEZOoTNAjPHWj17QRhu7geIHJfcNhRk1XVQmF8Bp3ye+g== +prettier@^2.8.8: + version "2.8.8" + resolved "https://registry.yarnpkg.com/prettier/-/prettier-2.8.8.tgz#e8c5d7e98a4305ffe3de2e1fc4aca1a71c28b1da" + integrity sha512-tdN8qQGvNjw4CHbY+XXk0JgCXn9QiF21a55rBe5LJAU+kDyC4WQn4+awm2Xfk2lQMk5fKup9XgzTZtGkjBdP9Q== pretty-format@^26.0.0, pretty-format@^26.6.2: version "26.6.2" @@ -8308,10 +8544,10 @@ quick-lru@^4.0.1: resolved "https://registry.yarnpkg.com/quick-lru/-/quick-lru-4.0.1.tgz#5b8878f113a58217848c6482026c73e1ba57727f" integrity sha512-ARhCpm70fzdcvNQfPoy49IaanKkTlRWF2JMzqhcJbhSFRZv7nPTvZJdcY7301IPmvW+/p0RgIWnQDLJxifsQ7g== -quick-lru@^5.1.1: - version "5.1.1" - resolved "https://registry.yarnpkg.com/quick-lru/-/quick-lru-5.1.1.tgz#366493e6b3e42a3a6885e2e99d18f80fb7a8c932" - integrity sha512-WuyALRjWPDGtt/wzJiadO5AXY+8hZ80hVpe6MyivgraREW751X3SbhRvG3eLKOYN+8VEvqLcf3wdnt44Z4S4SA== +quick-lru@^6.1.1: + version "6.1.2" + resolved "https://registry.yarnpkg.com/quick-lru/-/quick-lru-6.1.2.tgz#e9a90524108629be35287d0b864e7ad6ceb3659e" + integrity sha512-AAFUA5O1d83pIHEhJwWCq/RQcRukCkn/NSm2QsTEMle5f2hP0ChI2+3Xb051PZCkLryI/Ir1MVKviT2FIloaTQ== randombytes@^2.1.0: version "2.1.0" @@ -8433,15 +8669,6 @@ read-pkg-up@^7.0.1: read-pkg "^5.2.0" type-fest "^0.8.1" -read-pkg-up@^8.0.0: - version "8.0.0" - resolved "https://registry.yarnpkg.com/read-pkg-up/-/read-pkg-up-8.0.0.tgz#72f595b65e66110f43b052dd9af4de6b10534670" - integrity sha512-snVCqPczksT0HS2EC+SxUndvSzn6LRCwpfSvLrIfR5BKDQQZMaI6jPRC9dYvYFDRAuFEAnkwww8kBBNE/3VvzQ== - dependencies: - find-up "^5.0.0" - read-pkg "^6.0.0" - type-fest "^1.0.1" - read-pkg-up@^9.1.0: version "9.1.0" resolved "https://registry.yarnpkg.com/read-pkg-up/-/read-pkg-up-9.1.0.tgz#38ca48e0bc6c6b260464b14aad9bcd4e5b1fbdc3" @@ -8470,16 +8697,6 @@ read-pkg@^5.2.0: parse-json "^5.0.0" type-fest "^0.6.0" -read-pkg@^6.0.0: - version "6.0.0" - resolved "https://registry.yarnpkg.com/read-pkg/-/read-pkg-6.0.0.tgz#a67a7d6a1c2b0c3cd6aa2ea521f40c458a4a504c" - integrity sha512-X1Fu3dPuk/8ZLsMhEj5f4wFAF0DWoK7qhGJvgaijocXxBmSToKfbFtqbxMO7bVjNA1dmE5huAzjXj/ey86iw9Q== - dependencies: - "@types/normalize-package-data" "^2.4.0" - normalize-package-data "^3.0.2" - parse-json "^5.2.0" - type-fest "^1.0.1" - read-pkg@^7.1.0: version "7.1.0" resolved "https://registry.yarnpkg.com/read-pkg/-/read-pkg-7.1.0.tgz#438b4caed1ad656ba359b3e00fd094f3c427a43e" @@ -8543,13 +8760,6 @@ readline@^1.3.0: resolved "https://registry.yarnpkg.com/readline/-/readline-1.3.0.tgz#c580d77ef2cfc8752b132498060dc9793a7ac01c" integrity sha512-k2d6ACCkiNYz222Fs/iNze30rRJ1iIicW7JuX/7/cozvih6YCkFZH+J6mAFDVgv0dRBaAyr4jDqC95R2y4IADg== -rechoir@^0.6.2: - version "0.6.2" - resolved "https://registry.yarnpkg.com/rechoir/-/rechoir-0.6.2.tgz#85204b54dba82d5742e28c96756ef43af50e3384" - integrity sha512-HFM8rkZ+i3zrV+4LQjwQ0W+ez98pApMGM3HUrN04j3CqzPOzl9nmP15Y8YXNm8QHGv/eacOVEjqhmWpkRV0NAw== - dependencies: - resolve "^1.1.6" - rechoir@^0.7.0: version "0.7.1" resolved "https://registry.yarnpkg.com/rechoir/-/rechoir-0.7.1.tgz#9478a96a1ca135b5e88fc027f03ee92d6c645686" @@ -8573,6 +8783,11 @@ redent@^4.0.0: indent-string "^5.0.0" strip-indent "^4.0.0" +regenerator-runtime@^0.14.0: + version "0.14.0" + resolved "https://registry.yarnpkg.com/regenerator-runtime/-/regenerator-runtime-0.14.0.tgz#5e19d68eb12d486f797e15a3c6a918f7cec5eb45" + integrity sha512-srw17NI0TUWHuGa5CFGGmhfNIeja30WMBfbslPNhf6JrqQlLN5gcrvig1oqPxiVaXb0oW0XRKtH6Nngs5lKCIA== + regex-not@^1.0.0, regex-not@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/regex-not/-/regex-not-1.0.2.tgz#1f4ece27e00b0b65e0247a6810e6a85d83a5752c" @@ -8590,7 +8805,7 @@ regexp.prototype.flags@^1.2.0, regexp.prototype.flags@^1.4.3: define-properties "^1.1.3" functions-have-names "^1.2.2" -regexpp@^3.0.0, regexpp@^3.2.0: +regexpp@^3.0.0: version "3.2.0" resolved "https://registry.yarnpkg.com/regexpp/-/regexpp-3.2.0.tgz#0425a2768d8f23bad70ca4b90461fa2f1213e1b2" integrity sha512-pq2bWo9mVD43nbts2wGv17XLiNLya+GklZ8kaDLV2Z08gDCsGpnKn9BFMepvWuHCbyVvY7J5o5+BVvoQbmlJLg== @@ -8695,7 +8910,7 @@ resolve-url@^0.2.1: resolved "https://registry.yarnpkg.com/resolve-url/-/resolve-url-0.2.1.tgz#2c637fe77c893afd2a663fe21aa9080068e2052a" integrity sha512-ZuF55hVUQaaczgOIwqWzkEcEidmlD/xl44x1UZnhOXcYuFN2S6+rcxpG+C1N3So0wvNI3DmJICUFfu2SxhBmvg== -resolve@^1.1.6, resolve@^1.10.0, resolve@^1.10.1, resolve@^1.18.1, resolve@^1.9.0: +resolve@^1.10.0, resolve@^1.10.1, resolve@^1.18.1, resolve@^1.9.0: version "1.22.1" resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.22.1.tgz#27cb2ebb53f91abb49470a928bba7558066ac177" integrity sha512-nBpuuYuY5jFsli/JIs1oldw6fOQCBioohqWZg/2hiaOybXOft4lonv85uDOKXdf8rhyK159cxU5cDcK/NKk8zw== @@ -8785,10 +9000,10 @@ rxjs@^6.6.0: dependencies: tslib "^1.9.0" -rxjs@^7.5.5: - version "7.5.6" - resolved "https://registry.yarnpkg.com/rxjs/-/rxjs-7.5.6.tgz#0446577557862afd6903517ce7cae79ecb9662bc" - integrity sha512-dnyv2/YsXhnm461G+R/Pe5bWP41Nm6LBXEYWI6eiFP4fiwx6WRI/CD0zbdVAudd9xwLEF2IDcKXLHit0FYjUzw== +rxjs@^7.8.0: + version "7.8.1" + resolved "https://registry.yarnpkg.com/rxjs/-/rxjs-7.8.1.tgz#6f6f3d99ea8044291efd92e7c7fcf562c4057543" + integrity sha512-AA3TVj+0A2iuIoQkWEK/tqFjBq2j+6PO6Y0zJcvzLAFhEFIO3HL0vls9hWLncZbAAbK0mar7oZ4V079I/qPMxg== dependencies: tslib "^2.1.0" @@ -8878,7 +9093,7 @@ selfsigned@^1.10.8: resolved "https://registry.yarnpkg.com/semver/-/semver-5.7.2.tgz#48d55db737c3287cd4835e17fa13feace1c41ef8" integrity sha512-cBznnQ9KjJqU67B52RMC65CMarK2600WFnbkcaiwWq3xy/5haFJlshgnpjovMVJ+Hff49d8GEn0b87C5pDQ10g== -semver@7.x, semver@^7.1.1, semver@^7.1.3, semver@^7.3.2, semver@^7.3.4, semver@^7.3.5, semver@^7.3.7: +semver@7.x, semver@^7.1.1, semver@^7.1.3, semver@^7.3.2, semver@^7.3.4, semver@^7.3.5, semver@^7.3.7, semver@^7.5.4: version "7.5.4" resolved "https://registry.yarnpkg.com/semver/-/semver-7.5.4.tgz#483986ec4ed38e1c6c48c34894a9182dbff68a6e" integrity sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA== @@ -9002,15 +9217,6 @@ shebang-regex@^3.0.0: resolved "https://registry.yarnpkg.com/shebang-regex/-/shebang-regex-3.0.0.tgz#ae16f1644d873ecad843b0307b143362d4c42172" integrity sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A== -shelljs@^0.8.5: - version "0.8.5" - resolved "https://registry.yarnpkg.com/shelljs/-/shelljs-0.8.5.tgz#de055408d8361bed66c669d2f000538ced8ee20c" - integrity sha512-TiwcRcrkhHvbrZbnRcFYMLl30Dfov3HKqzp5tO5b4pt6G/SezKcYhmDg15zXVBswHmctSAQKznqNW2LO5tTDow== - dependencies: - glob "^7.0.0" - interpret "^1.0.0" - rechoir "^0.6.2" - shellwords@^0.1.1: version "0.1.1" resolved "https://registry.yarnpkg.com/shellwords/-/shellwords-0.1.1.tgz#d6b9181c1a48d397324c84871efbcfc73fc0654b" @@ -9025,7 +9231,7 @@ side-channel@^1.0.4: get-intrinsic "^1.0.2" object-inspect "^1.9.0" -signal-exit@^3.0.0, signal-exit@^3.0.2, signal-exit@^3.0.3: +signal-exit@^3.0.0, signal-exit@^3.0.2, signal-exit@^3.0.3, signal-exit@^3.0.7: version "3.0.7" resolved "https://registry.yarnpkg.com/signal-exit/-/signal-exit-3.0.7.tgz#a9a1767f8af84155114eaabd73f99273c8f59ad9" integrity sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ== @@ -9534,6 +9740,11 @@ strip-final-newline@^2.0.0: resolved "https://registry.yarnpkg.com/strip-final-newline/-/strip-final-newline-2.0.0.tgz#89b852fb2fcbe936f6f4b3187afb0a12c1ab58ad" integrity sha512-BrpvfNAE3dcvq7ll3xVumzjKjZQ5tI1sEUIKr3Uoks0XUl45St3FlatVqef9prk4jRDzhW6WZg+3bk93y6pLjA== +strip-final-newline@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/strip-final-newline/-/strip-final-newline-3.0.0.tgz#52894c313fbff318835280aed60ff71ebf12b8fd" + integrity sha512-dOESqjYr96iWYylGObzd39EuNTa5VJxyvVAEm5Jnh7KGo75V43Hk1odPQkNDyXNmUR6k+gEiDVXnjB8HJ3crXw== + strip-indent@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/strip-indent/-/strip-indent-3.0.0.tgz#c32e1cee940b6b3432c771bc2c54bcce73cd3001" @@ -9548,7 +9759,7 @@ strip-indent@^4.0.0: dependencies: min-indent "^1.0.1" -strip-json-comments@^3.1.0, strip-json-comments@^3.1.1: +strip-json-comments@^3.1.1: version "3.1.1" resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-3.1.1.tgz#31f1281b3832630434831c310c01cccda8cbe006" integrity sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig== @@ -9602,11 +9813,6 @@ supports-color@^8.0.0: dependencies: has-flag "^4.0.0" -supports-color@^9.2.2: - version "9.2.2" - resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-9.2.2.tgz#502acaf82f2b7ee78eb7c83dcac0f89694e5a7bb" - integrity sha512-XC6g/Kgux+rJXmwokjm9ECpD6k/smUoS5LKlUCcsYr4IY3rW0XyAympon2RmxGrlnZURMpg5T18gWDP9CsHXFA== - supports-hyperlinks@^2.0.0: version "2.2.0" resolved "https://registry.yarnpkg.com/supports-hyperlinks/-/supports-hyperlinks-2.2.0.tgz#4f77b42488765891774b70c79babd87f9bd594bb" @@ -10018,16 +10224,21 @@ type-fest@^0.8.1: resolved "https://registry.yarnpkg.com/type-fest/-/type-fest-0.8.1.tgz#09e249ebde851d3b1e48d27c105444667f17b83d" integrity sha512-4dbzIzqvjtgiM5rw1k5rEHtBANKmdudhGyBEajN01fEyhaAIhsoKNy6y7+IN93IfpFtwY9iqi7kD+xwKhQsNJA== -type-fest@^1.0.1, type-fest@^1.2.1, type-fest@^1.2.2: - version "1.4.0" - resolved "https://registry.yarnpkg.com/type-fest/-/type-fest-1.4.0.tgz#e9fb813fe3bf1744ec359d55d1affefa76f14be1" - integrity sha512-yGSza74xk0UG8k+pLh5oeoYirvIiWo5t0/o3zHHAO2tRDiZcxWP7fywNlXhqb6/r6sWvwi+RsyQMWhVLe4BVuA== - type-fest@^2.0.0, type-fest@^2.5.0: version "2.18.0" resolved "https://registry.yarnpkg.com/type-fest/-/type-fest-2.18.0.tgz#fdef3a74e0a9e68ebe46054836650fb91ac3881e" integrity sha512-pRS+/yrW5TjPPHNOvxhbNZexr2bS63WjrMU8a+VzEBhUi9Tz1pZeD+vQz3ut0svZ46P+SRqMEPnJmk2XnvNzTw== +type-fest@^2.13.0: + version "2.19.0" + resolved "https://registry.yarnpkg.com/type-fest/-/type-fest-2.19.0.tgz#88068015bb33036a598b952e55e9311a60fd3a9b" + integrity sha512-RAH822pAdBgcNMAfWnCBU3CFZcfZ/i1eZjwFU/dsLKumyuuP3niueg2UAukXYF0E2AAoc82ZSSf9J0WQBinzHA== + +type-fest@^3.1.0: + version "3.13.1" + resolved "https://registry.yarnpkg.com/type-fest/-/type-fest-3.13.1.tgz#bb744c1f0678bea7543a2d1ec24e83e68e8c8706" + integrity sha512-tLq3bSNx+xSpwvAJnzrK0Ep5CLNWjvFTOp71URMaAEWBfRb9nnJiBoUe0tF8bI4ZFO3omgBR6NvnbzVUT3Ly4g== + type-is@~1.6.18: version "1.6.18" resolved "https://registry.yarnpkg.com/type-is/-/type-is-1.6.18.tgz#4e552cd05df09467dcbc4ef739de89f2cf37c131" @@ -10242,11 +10453,6 @@ uuid@^8.3.0, uuid@^8.3.2: resolved "https://registry.yarnpkg.com/uuid/-/uuid-8.3.2.tgz#80d5b5ced271bb9af6c445f21a1a04c606cefbe2" integrity sha512-+NYs2QeMWy+GWFOEm9xnn6HCDp0l7QBD7ml8zLUmJ+93Q5NF0NocErnwkTkXVFNiX3/fpC6afS8Dhb/gz7R7eg== -v8-compile-cache@^2.0.3: - version "2.3.0" - resolved "https://registry.yarnpkg.com/v8-compile-cache/-/v8-compile-cache-2.3.0.tgz#2de19618c66dc247dcfb6f99338035d8245a2cee" - integrity sha512-l8lCEmLcLYZh4nbunNZvQCJc5pv7+RCwa8q/LdUx8u7lsWvPDKmpodJAJNwkAhJC//dFY48KuIEmjtd4RViDrA== - v8-to-istanbul@^7.0.0: version "7.1.2" resolved "https://registry.yarnpkg.com/v8-to-istanbul/-/v8-to-istanbul-7.1.2.tgz#30898d1a7fa0c84d225a2c1434fb958f290883c1" @@ -10547,7 +10753,7 @@ wildcard@^2.0.0: resolved "https://registry.yarnpkg.com/wildcard/-/wildcard-2.0.0.tgz#a77d20e5200c6faaac979e4b3aadc7b3dd7f8fec" integrity sha512-JcKqAHLPxcdb9KM49dufGXn2x3ssnfjbcaQdLlfZsL9rH9wgDQjUtDxbo8NE0F6SFvydeu1VhZe7hZuHsB2/pw== -word-wrap@^1.2.3, word-wrap@~1.2.3: +word-wrap@~1.2.3: version "1.2.4" resolved "https://registry.yarnpkg.com/word-wrap/-/word-wrap-1.2.4.tgz#cb4b50ec9aca570abd1f52f33cd45b6c61739a9f" integrity sha512-2V81OA4ugVo5pRo46hAoD2ivUJx8jXmWXfUkY4KFNw0hEptvN0QfH3K4nHiwzGeKl5rFKedV48QVoqYavy4YpA== @@ -10688,17 +10894,22 @@ yallist@^4.0.0: resolved "https://registry.yarnpkg.com/yallist/-/yallist-4.0.0.tgz#9bb92790d9c0effec63be73519e11a35019a3a72" integrity sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A== -yaml@^1.10.0, yaml@^1.10.2: +yaml@^1.10.0: version "1.10.2" resolved "https://registry.yarnpkg.com/yaml/-/yaml-1.10.2.tgz#2301c5ffbf12b467de8da2333a459e29e7920e4b" integrity sha512-r3vXyErRCYJ7wg28yvBY5VSoAF8ZvlcW9/BwUzEtUsjvX/DKs24dIkuwjtuprwJJHsbyUbLApepYTR1BN4uHrg== +yaml@^2.2.2: + version "2.3.3" + resolved "https://registry.yarnpkg.com/yaml/-/yaml-2.3.3.tgz#01f6d18ef036446340007db8e016810e5d64aad9" + integrity sha512-zw0VAJxgeZ6+++/su5AFoqBbZbrEakwu+X0M5HmcwUiBL7AzcuPKjj5we4xfQLp78LkEMpD0cOnUhmgOVy3KdQ== + yargs-parser@20.2.4: version "20.2.4" resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-20.2.4.tgz#b42890f14566796f85ae8e3a25290d205f154a54" integrity sha512-WOkpgNhPTlE73h4VFAFsOnomJVaovO8VqLDzy5saChRBFQFBoMYirowyW+Q9HB4HFF4Z7VZTiG3iSzJJA29yRA== -yargs-parser@20.x, yargs-parser@^20.2.2, yargs-parser@^20.2.3, yargs-parser@^20.2.9: +yargs-parser@20.x, yargs-parser@^20.2.2, yargs-parser@^20.2.3: version "20.2.9" resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-20.2.9.tgz#2eb7dc3b0289718fc295f362753845c41a0c94ee" integrity sha512-y11nGElTIV+CT3Zv9t7VKl+Q3hTQoT9a1Qzezhhl6Rp21gJ/IVTW7Z3y9EWXhuUBC2Shnf+DX0antecpAwSP8w== @@ -10719,6 +10930,11 @@ yargs-parser@^18.1.2: camelcase "^5.0.0" decamelize "^1.2.0" +yargs-parser@^21.1.1: + version "21.1.1" + resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-21.1.1.tgz#9096bceebf990d21bb31fa9516e0ede294a77d35" + integrity sha512-tVpsJW7DdjecAiFpbIB1e3qxIQsE6NoPc5/eTdrbbIC4h0LVsWhnoa3g+m2HclBIujHzsxZ4VJVA+GUuc2/LBw== + yargs@^13.3.2: version "13.3.2" resolved "https://registry.yarnpkg.com/yargs/-/yargs-13.3.2.tgz#ad7ffefec1aa59565ac915f82dccb38a9c31a2dd" From 36a5b95997c4fa15e0f36d378a15b6c2b0c0506c Mon Sep 17 00:00:00 2001 From: Johan Nyman Date: Thu, 2 Nov 2023 09:37:40 +0100 Subject: [PATCH 47/49] chore: linting --- README.md | 2 +- packages/core/src/lib.ts | 5 ++++- packages/core/src/xkeys.ts | 2 +- packages/node/src/methods.ts | 4 ++-- packages/node/src/watcher.ts | 2 +- 5 files changed, 9 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index 16ef82f..9f45914 100644 --- a/README.md +++ b/README.md @@ -432,7 +432,7 @@ yarn test # To ensure that your code passes the unit tests. If you're adding a new functionality, adding unit tests for it is much appreciated. -### Notes to maintainers +### Notes for maintainers #### Making a nightly build diff --git a/packages/core/src/lib.ts b/packages/core/src/lib.ts index 8aa4cc4..0c44342 100644 --- a/packages/core/src/lib.ts +++ b/packages/core/src/lib.ts @@ -9,8 +9,11 @@ export function literal(o: T): T { export function describeEvent(event: string, args: any[]): string { const metadataStr = (metadata: any) => { + if (typeof metadata == 'object') return `${metadata}` + if (metadata === null) return 'null' + const strs: string[] = [] - Object.entries(metadata).forEach(([key, value]) => { + Object.entries(metadata).forEach(([key, value]) => { strs.push(`${key}: ${value}`) }) return strs.join(', ') diff --git a/packages/core/src/xkeys.ts b/packages/core/src/xkeys.ts index 86a6358..3348278 100644 --- a/packages/core/src/xkeys.ts +++ b/packages/core/src/xkeys.ts @@ -55,7 +55,7 @@ export class XKeys extends EventEmitter { } private _setupDevice(deviceInfo: DeviceInfo) { const findProduct = (): { product: Product; productId: number; interface: number } => { - for (const product of Object.values(PRODUCTS)) { + for (const product of Object.values(PRODUCTS)) { for (const hidDevice of product.hidDevices) { if ( hidDevice[0] === deviceInfo.productId && diff --git a/packages/node/src/methods.ts b/packages/node/src/methods.ts index 2688f76..fca8304 100644 --- a/packages/node/src/methods.ts +++ b/packages/node/src/methods.ts @@ -1,4 +1,4 @@ -import { XKeys } from '@xkeys-lib/core' +import { Product, XKeys } from '@xkeys-lib/core' import { PRODUCTS } from '@xkeys-lib/core' import * as HID from 'node-hid' import { NodeHIDDevice } from './node-hid-wrapper' @@ -103,7 +103,7 @@ export function listAllConnectedPanels(): HID_Device[] { if (!device.path) return false let found = false - for (const product of Object.values(PRODUCTS)) { + for (const product of Object.values(PRODUCTS)) { for (const hidDevice of product.hidDevices) { if (hidDevice[0] === device.productId && hidDevice[1] === device.interface) { found = true diff --git a/packages/node/src/watcher.ts b/packages/node/src/watcher.ts index 9fcafe8..ea03ba5 100644 --- a/packages/node/src/watcher.ts +++ b/packages/node/src/watcher.ts @@ -184,7 +184,7 @@ export class XKeysWatcher extends EventEmitter { let removed = 0 let added = 0 // Removed devices: - for (const [devicePath, o] of Object.entries(this.seenDevicePaths)) { + for (const [devicePath, o] of Object.entries<{ xkeys?: XKeys }>(this.seenDevicePaths)) { if (!pathMap[devicePath]) { // A device has been removed this.debugLog('removed') From 641876bc263519dd5eeb5947819ce2bbe7133312 Mon Sep 17 00:00:00 2001 From: Johan Nyman Date: Thu, 2 Nov 2023 09:43:15 +0100 Subject: [PATCH 48/49] chore: lint bug fix --- packages/core/src/lib.ts | 2 +- yarn.lock | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/core/src/lib.ts b/packages/core/src/lib.ts index 0c44342..99a6dab 100644 --- a/packages/core/src/lib.ts +++ b/packages/core/src/lib.ts @@ -9,7 +9,7 @@ export function literal(o: T): T { export function describeEvent(event: string, args: any[]): string { const metadataStr = (metadata: any) => { - if (typeof metadata == 'object') return `${metadata}` + if (typeof metadata !== 'object') return `${metadata}` if (metadata === null) return 'null' const strs: string[] = [] diff --git a/yarn.lock b/yarn.lock index 556a464..be62887 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1598,7 +1598,7 @@ dependencies: "@sinonjs/commons" "^1.7.0" -"@sofie-automation/code-standard-preset@~2.5.2": +"@sofie-automation/code-standard-preset@^2.5.2": version "2.5.2" resolved "https://registry.yarnpkg.com/@sofie-automation/code-standard-preset/-/code-standard-preset-2.5.2.tgz#468bd1c4c32be976431f50f76ff54329c2cfffe0" integrity sha512-xzAMUp/FHvNwkMC2pl8isOVLcWUmoQ9Mw1FdiYwDSHyOkLmbJ/nwYrl6iWR/7LbkGk45RAKkbkfFyhsqTh4xzA== From bcfb831bc9fb76ab1e384b2e4394816e7648fb2b Mon Sep 17 00:00:00 2001 From: Johan Nyman Date: Thu, 2 Nov 2023 09:47:09 +0100 Subject: [PATCH 49/49] v3.0.1 --- CHANGELOG.md | 12 ++++++++++++ lerna.json | 2 +- packages/core/CHANGELOG.md | 10 ++++++++-- packages/core/package.json | 2 +- packages/node-record-test/CHANGELOG.md | 10 ++++++++-- packages/node-record-test/package.json | 6 +++--- packages/node/CHANGELOG.md | 10 ++++++++-- packages/node/package.json | 4 ++-- packages/webhid-demo/CHANGELOG.md | 10 ++++++++-- packages/webhid-demo/package.json | 4 ++-- packages/webhid/CHANGELOG.md | 14 ++++++++++++-- packages/webhid/package.json | 4 ++-- 12 files changed, 67 insertions(+), 21 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 2f545cf..37869f9 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -3,6 +3,18 @@ All notable changes to this project will be documented in this file. See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. +## [3.0.1](https://github.com/SuperFlyTV/xkeys/compare/v3.0.0...v3.0.1) (2023-11-02) + + +### Bug Fixes + +* filter for correct usage/usagePage when finding xkeys devices ([8b9fdd1](https://github.com/SuperFlyTV/xkeys/commit/8b9fdd1eb69abf03cfbc67f5b503bd01a8623bc5)) +* filter for correct usage/usagePage when finding xkeys devices ([68f3e86](https://github.com/SuperFlyTV/xkeys/commit/68f3e869139b2a846e2be4209f5201f7e4893494)) + + + + + # [3.0.0](https://github.com/SuperFlyTV/xkeys/compare/v2.4.0...v3.0.0) (2023-05-03) ### Bug Fixes diff --git a/lerna.json b/lerna.json index 7028971..27e3054 100644 --- a/lerna.json +++ b/lerna.json @@ -4,5 +4,5 @@ ], "npmClient": "yarn", "useWorkspaces": true, - "version": "3.0.0" + "version": "3.0.1" } diff --git a/packages/core/CHANGELOG.md b/packages/core/CHANGELOG.md index fde7cd2..1265aee 100644 --- a/packages/core/CHANGELOG.md +++ b/packages/core/CHANGELOG.md @@ -1,10 +1,16 @@ # Change Log -**NOTE: (The full changelog is published here!)[https://github.com/SuperFlyTV/xkeys/blob/master/CHANGELOG.md]** - All notable changes to this project will be documented in this file. See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. +## [3.0.1](https://github.com/SuperFlyTV/xkeys/compare/v3.0.0...v3.0.1) (2023-11-02) + +**Note:** Version bump only for package @xkeys-lib/core + + + + + # [3.0.0](https://github.com/SuperFlyTV/xkeys/compare/v2.4.0...v3.0.0) (2023-05-03) ### Bug Fixes diff --git a/packages/core/package.json b/packages/core/package.json index 0ad3df3..71b48cc 100644 --- a/packages/core/package.json +++ b/packages/core/package.json @@ -1,6 +1,6 @@ { "name": "@xkeys-lib/core", - "version": "3.0.0", + "version": "3.0.1", "description": "NPM package to interact with the X-keys panels", "main": "dist/index.js", "typings": "dist/index.d.ts", diff --git a/packages/node-record-test/CHANGELOG.md b/packages/node-record-test/CHANGELOG.md index c7e462a..cc7d69d 100644 --- a/packages/node-record-test/CHANGELOG.md +++ b/packages/node-record-test/CHANGELOG.md @@ -1,10 +1,16 @@ # Change Log -**NOTE: (The full changelog is published here!)[https://github.com/SuperFlyTV/xkeys/blob/master/CHANGELOG.md]** - All notable changes to this project will be documented in this file. See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. +## [3.0.1](https://github.com/SuperFlyTV/xkeys/compare/v3.0.0...v3.0.1) (2023-11-02) + +**Note:** Version bump only for package @xkeys-lib/record-test + + + + + # [3.0.0](https://github.com/SuperFlyTV/xkeys/compare/v2.4.0...v3.0.0) (2023-05-03) **Note:** Version bump only for package @xkeys-lib/record-test diff --git a/packages/node-record-test/package.json b/packages/node-record-test/package.json index 67b1a80..6df7591 100644 --- a/packages/node-record-test/package.json +++ b/packages/node-record-test/package.json @@ -1,6 +1,6 @@ { "name": "@xkeys-lib/record-test", - "version": "3.0.0", + "version": "3.0.1", "private": true, "description": "A script for recording tests", "main": "dist/index.js", @@ -51,10 +51,10 @@ "controller" ], "dependencies": { - "@xkeys-lib/core": "3.0.0", + "@xkeys-lib/core": "3.0.1", "readline": "^1.3.0", "tslib": "^2.4.0", - "xkeys": "3.0.0" + "xkeys": "3.0.1" }, "optionalDependencies": { "find": "^0.3.0", diff --git a/packages/node/CHANGELOG.md b/packages/node/CHANGELOG.md index bd03bfd..5e2481c 100644 --- a/packages/node/CHANGELOG.md +++ b/packages/node/CHANGELOG.md @@ -1,10 +1,16 @@ # Change Log -**NOTE: (The full changelog is published here!)[https://github.com/SuperFlyTV/xkeys/blob/master/CHANGELOG.md]** - All notable changes to this project will be documented in this file. See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. +## [3.0.1](https://github.com/SuperFlyTV/xkeys/compare/v3.0.0...v3.0.1) (2023-11-02) + +**Note:** Version bump only for package xkeys + + + + + # [3.0.0](https://github.com/SuperFlyTV/xkeys/compare/v2.4.0...v3.0.0) (2023-05-03) - BREAKING CHANGE: Dropped support for EOL versions of Node.js (<14). diff --git a/packages/node/package.json b/packages/node/package.json index ec2259d..a4fe743 100644 --- a/packages/node/package.json +++ b/packages/node/package.json @@ -1,6 +1,6 @@ { "name": "xkeys", - "version": "3.0.0", + "version": "3.0.1", "description": "An npm module for interfacing with the X-keys panels in Node.js", "main": "dist/index.js", "typings": "dist/index.d.ts", @@ -51,7 +51,7 @@ ], "dependencies": { "@types/node-hid": "^1.3.1", - "@xkeys-lib/core": "3.0.0", + "@xkeys-lib/core": "3.0.1", "node-hid": "^2.1.1", "tslib": "^2.4.0" }, diff --git a/packages/webhid-demo/CHANGELOG.md b/packages/webhid-demo/CHANGELOG.md index 4d21995..84501ba 100644 --- a/packages/webhid-demo/CHANGELOG.md +++ b/packages/webhid-demo/CHANGELOG.md @@ -1,10 +1,16 @@ # Change Log -**NOTE: (The full changelog is published here!)[https://github.com/SuperFlyTV/xkeys/blob/master/CHANGELOG.md]** - All notable changes to this project will be documented in this file. See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. +## [3.0.1](https://github.com/SuperFlyTV/xkeys/compare/v3.0.0...v3.0.1) (2023-11-02) + +**Note:** Version bump only for package @xkeys-lib/webhid-demo + + + + + # [3.0.0](https://github.com/SuperFlyTV/xkeys/compare/v2.4.0...v3.0.0) (2023-05-03) **Note:** Version bump only for package @xkeys-lib/webhid-demo diff --git a/packages/webhid-demo/package.json b/packages/webhid-demo/package.json index 510f722..7f0076b 100644 --- a/packages/webhid-demo/package.json +++ b/packages/webhid-demo/package.json @@ -1,6 +1,6 @@ { "name": "@xkeys-lib/webhid-demo", - "version": "3.0.0", + "version": "3.0.1", "private": true, "license": "MIT", "homepage": "https://github.com/SuperFlyTV/xkeys#readme", @@ -22,7 +22,7 @@ }, "dependencies": { "buffer": "^6.0.3", - "xkeys-webhid": "3.0.0" + "xkeys-webhid": "3.0.1" }, "devDependencies": { "copy-webpack-plugin": "^7.0.0", diff --git a/packages/webhid/CHANGELOG.md b/packages/webhid/CHANGELOG.md index 29b5a52..29bb6dd 100644 --- a/packages/webhid/CHANGELOG.md +++ b/packages/webhid/CHANGELOG.md @@ -1,10 +1,20 @@ # Change Log -**NOTE: (The full changelog is published here!)[https://github.com/SuperFlyTV/xkeys/blob/master/CHANGELOG.md]** - All notable changes to this project will be documented in this file. See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. +## [3.0.1](https://github.com/SuperFlyTV/xkeys/compare/v3.0.0...v3.0.1) (2023-11-02) + + +### Bug Fixes + +* filter for correct usage/usagePage when finding xkeys devices ([8b9fdd1](https://github.com/SuperFlyTV/xkeys/commit/8b9fdd1eb69abf03cfbc67f5b503bd01a8623bc5)) +* filter for correct usage/usagePage when finding xkeys devices ([68f3e86](https://github.com/SuperFlyTV/xkeys/commit/68f3e869139b2a846e2be4209f5201f7e4893494)) + + + + + # [3.0.0](https://github.com/SuperFlyTV/xkeys/compare/v2.4.0...v3.0.0) (2023-05-03) **Note:** Version bump only for package xkeys-webhid diff --git a/packages/webhid/package.json b/packages/webhid/package.json index 44130ef..ad89c79 100644 --- a/packages/webhid/package.json +++ b/packages/webhid/package.json @@ -1,6 +1,6 @@ { "name": "xkeys-webhid", - "version": "3.0.0", + "version": "3.0.1", "description": "An npm module for interfacing with the X-keys panels in a browser", "main": "dist/index.js", "typings": "dist/index.d.ts", @@ -38,7 +38,7 @@ ], "dependencies": { "@types/w3c-web-hid": "^1.0.3", - "@xkeys-lib/core": "3.0.0", + "@xkeys-lib/core": "3.0.1", "buffer": "^6.0.3", "p-queue": "^6.6.2" },