fix(tracker): fix asist canvas layer (#1923)
This commit is contained in:
parent
deb9f37d8f
commit
7c2db1d67c
5 changed files with 8 additions and 1 deletions
|
|
@ -1,3 +1,7 @@
|
|||
## 8.0.3
|
||||
|
||||
- make assist canvas layer hidden from canvas capturer
|
||||
|
||||
## 8.0.2
|
||||
|
||||
- another fix for peer reconnection strategy
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"name": "@openreplay/tracker-assist",
|
||||
"description": "Tracker plugin for screen assistance through the WebRTC",
|
||||
"version": "8.0.2",
|
||||
"version": "8.0.3",
|
||||
"keywords": [
|
||||
"WebRTC",
|
||||
"assistance",
|
||||
|
|
|
|||
|
|
@ -4,6 +4,7 @@ export default class AnnotationCanvas {
|
|||
private painting = false
|
||||
constructor() {
|
||||
this.canvas = document.createElement('canvas')
|
||||
this.canvas.setAttribute('data-openreplay-hidden', '1')
|
||||
Object.assign(this.canvas.style, {
|
||||
position: 'fixed',
|
||||
left: 0,
|
||||
|
|
|
|||
|
|
@ -6,6 +6,7 @@ declare global {
|
|||
|
||||
function dummyTrack(): MediaStreamTrack {
|
||||
const canvas = document.createElement('canvas')//, { width: 0, height: 0})
|
||||
canvas.setAttribute('data-openreplay-hidden', '1')
|
||||
canvas.width=canvas.height=2 // Doesn't work when 1 (?!)
|
||||
const ctx = canvas.getContext('2d')
|
||||
ctx?.fillRect(0, 0, canvas.width, canvas.height)
|
||||
|
|
|
|||
|
|
@ -15,6 +15,7 @@ describe('AnnotationCanvas', () => {
|
|||
style: {},
|
||||
getContext: jest.fn(() => contextMock as unknown as HTMLCanvasElement),
|
||||
parentNode: document,
|
||||
setAttribute: jest.fn()
|
||||
}
|
||||
|
||||
contextMock = {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue