livedesk 0.1.80 → 0.1.81

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -535,6 +535,8 @@ function normalizeRemoteInputEvent(value = {}) {
535
535
  const normalizedY = Number(input.normalizedY ?? input.NormalizedY);
536
536
  const deltaX = Number(input.deltaX ?? input.DeltaX);
537
537
  const deltaY = Number(input.deltaY ?? input.DeltaY);
538
+ const keyCode = Number(input.keyCode ?? input.KeyCode);
539
+ const location = Number(input.location ?? input.Location);
538
540
  return {
539
541
  type,
540
542
  normalizedX: Number.isFinite(normalizedX) ? Math.max(0, Math.min(1, normalizedX)) : undefined,
@@ -544,6 +546,8 @@ function normalizeRemoteInputEvent(value = {}) {
544
546
  deltaY: Number.isFinite(deltaY) ? Math.max(-4096, Math.min(4096, deltaY)) : 0,
545
547
  key: safeString(input.key || input.Key, 80),
546
548
  code: safeString(input.code || input.Code, 80),
549
+ keyCode: Number.isFinite(keyCode) ? Math.max(0, Math.min(65535, Math.trunc(keyCode))) : 0,
550
+ location: Number.isFinite(location) ? Math.max(0, Math.min(255, Math.trunc(location))) : 0,
547
551
  text: safeText(input.text || input.Text, 256),
548
552
  repeat: input.repeat === true || input.Repeat === true,
549
553
  controlLeaseId: safeString(input.controlLeaseId || input.ControlLeaseId, 128),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "livedesk",
3
- "version": "0.1.80",
3
+ "version": "0.1.81",
4
4
  "description": "LiveDesk Hub and client launcher",
5
5
  "type": "module",
6
6
  "bin": {
@@ -30,7 +30,7 @@
30
30
  "node": ">=20"
31
31
  },
32
32
  "dependencies": {
33
- "@livedesk/client": "0.1.60",
33
+ "@livedesk/client": "0.1.61",
34
34
  "cors": "^2.8.5",
35
35
  "express": "^4.21.2",
36
36
  "ws": "^8.18.3"