Skip to content

Commit aa82b8f

Browse files
authoredSep 27, 2023
Merge pull request #818 from scala-js/issue/807
Fix type of `ImageData#data`
2 parents 048d183 + 9c8796d commit aa82b8f

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed
 

‎api-reports/2_12.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -15465,7 +15465,7 @@ ImageBitmap[JT] def width: Double
1546515465
ImageCapture[JC] def grabFrame(): js.Promise[ImageBitmap]
1546615466
ImageCapture[JC] def takePhoto(): js.Promise[Blob]
1546715467
ImageCapture[JC] val track: MediaStreamTrack
15468-
ImageData[JC] def data: js.Array[Int]
15468+
ImageData[JC] def data: js.typedarray.Uint8ClampedArray
1546915469
ImageData[JC] def height: Int
1547015470
ImageData[JC] def width: Int
1547115471
InputEvent[JC] def bubbles: Boolean

‎api-reports/2_13.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -15465,7 +15465,7 @@ ImageBitmap[JT] def width: Double
1546515465
ImageCapture[JC] def grabFrame(): js.Promise[ImageBitmap]
1546615466
ImageCapture[JC] def takePhoto(): js.Promise[Blob]
1546715467
ImageCapture[JC] val track: MediaStreamTrack
15468-
ImageData[JC] def data: js.Array[Int]
15468+
ImageData[JC] def data: js.typedarray.Uint8ClampedArray
1546915469
ImageData[JC] def height: Int
1547015470
ImageData[JC] def width: Int
1547115471
InputEvent[JC] def bubbles: Boolean

‎dom/src/main/scala/org/scalajs/dom/ImageData.scala

+1-1
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ class ImageData extends js.Object {
2323
/** Is a Uint8ClampedArray representing a one-dimensional array containing the data in the RGBA order, with integer
2424
* values between 0 and 255 (included).
2525
*/
26-
def data: js.Array[Int] = js.native
26+
def data: js.typedarray.Uint8ClampedArray = js.native
2727

2828
/** Is an unsigned long representing the actual height, in pixels, of the ImageData. */
2929
def height: Int = js.native

0 commit comments

Comments
 (0)
Failed to load comments.