From 28cd7549f5bb07ca4f8446a250d234c6879250cb Mon Sep 17 00:00:00 2001 From: Almar Klein Date: Wed, 18 Mar 2026 22:29:45 +0100 Subject: [PATCH 1/3] Send close event and fix show/hide timestamp key --- src/renderview.js | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/renderview.js b/src/renderview.js index c90e18e..4d45363 100644 --- a/src/renderview.js +++ b/src/renderview.js @@ -177,6 +177,11 @@ class BaseRenderView { this.wrapperElement.innerHTML = '' this.wrapperElement = null } + const event = { + type: 'close', + timestamp: getTimestamp() + } + this.onEvent(event) } /** @@ -395,7 +400,7 @@ class BaseRenderView { this._isVisible = isVisible const event = { type: isVisible ? 'show' : 'hide', - t: getTimestamp() + timestamp: getTimestamp() } this.onEvent(event) } From 7e6a7cc9ab1a080412e9dc473d18036fd44bac2e Mon Sep 17 00:00:00 2001 From: Almar Klein Date: Thu, 19 Mar 2026 09:34:42 +0100 Subject: [PATCH 2/3] Also rename pixelratio -> ratio --- src/renderview.js | 2 +- src/spec.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/renderview.js b/src/renderview.js index 4d45363..ee21f26 100644 --- a/src/renderview.js +++ b/src/renderview.js @@ -466,7 +466,7 @@ class BaseRenderView { height: logicalHeight, pwidth: physicalWidth, pheight: physicalHeight, - pixelratio: ratio, + ratio, timestamp: getTimestamp() } this.onEvent(event) diff --git a/src/spec.md b/src/spec.md index 52ad3ef..dc9cdf9 100644 --- a/src/spec.md +++ b/src/spec.md @@ -70,7 +70,7 @@ Fields: * `height`: The height in logical pixels. * `pwidth`: The width in physical pixels. * `pheight`: The height in physical pixels. -* `pixelratio`: The pixel ratio between logical and physical pixels. +* `ratio`: The pixel ratio between logical and physical pixels. * `timestamp`: A timestamp in seconds. From 6b915416f0102306f67f338bd6c307c4470dfcee Mon Sep 17 00:00:00 2001 From: Almar Klein Date: Thu, 19 Mar 2026 09:37:14 +0100 Subject: [PATCH 3/3] update date --- src/spec.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/spec.md b/src/spec.md index dc9cdf9..c26f7d3 100644 --- a/src/spec.md +++ b/src/spec.md @@ -3,7 +3,7 @@ A protocol for interactive rendering surfaces. -*Last update: 18-03-2026* +*Last update: 19-03-2026* *This spec was previously known as the jupyter_rfb event spec, but was rolled into a separate project.*