From 606995e176322f8389cd7c9cc5aeb5521f4aa3b6 Mon Sep 17 00:00:00 2001 From: Abe Jellinek Date: Fri, 2 Aug 2024 11:23:23 -0400 Subject: [PATCH] Create View with Uint8Array, not ArrayBuffer --- src/index.android.js | 2 +- src/index.ios.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/index.android.js b/src/index.android.js index 25fbf980..d6e0ab17 100644 --- a/src/index.android.js +++ b/src/index.android.js @@ -11,7 +11,7 @@ window.createView = (options) => { // TODO: Implement a more efficient way to transfer large files data: { ...options.data, - buf: new Uint8Array(options.buf).buffer + buf: new Uint8Array(options.buf) }, onSaveAnnotations: (annotations) => { postMessage('onSaveAnnotations', { annotations }); diff --git a/src/index.ios.js b/src/index.ios.js index 40d0fe7c..0ee569b7 100644 --- a/src/index.ios.js +++ b/src/index.ios.js @@ -10,7 +10,7 @@ window.createView = (options) => { container: document.getElementById('view'), data: { // TODO: Implement a more efficient way to transfer large files - buf: new Uint8Array(options.buf).buffer + buf: new Uint8Array(options.buf) }, onSaveAnnotations: (annotations) => { postMessage('onSaveAnnotations', { annotations });