expo-gl 15.1.8-canary-20250701-6a945c5 → 15.1.8-canary-20250713-8f814f8

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.
Files changed (45) hide show
  1. package/CHANGELOG.md +2 -0
  2. package/android/build.gradle +2 -2
  3. package/build/Canvas.d.ts.map +1 -1
  4. package/build/Canvas.js +2 -2
  5. package/build/Canvas.js.map +1 -1
  6. package/expo-module.config.json +1 -1
  7. package/local-maven-repo/host/exp/exponent/expo.modules.gl/{15.1.8-canary-20250701-6a945c5/expo.modules.gl-15.1.8-canary-20250701-6a945c5.aar → 15.1.8-canary-20250713-8f814f8/expo.modules.gl-15.1.8-canary-20250713-8f814f8.aar} +0 -0
  8. package/local-maven-repo/host/exp/exponent/expo.modules.gl/15.1.8-canary-20250713-8f814f8/expo.modules.gl-15.1.8-canary-20250713-8f814f8.aar.md5 +1 -0
  9. package/local-maven-repo/host/exp/exponent/expo.modules.gl/15.1.8-canary-20250713-8f814f8/expo.modules.gl-15.1.8-canary-20250713-8f814f8.aar.sha1 +1 -0
  10. package/local-maven-repo/host/exp/exponent/expo.modules.gl/15.1.8-canary-20250713-8f814f8/expo.modules.gl-15.1.8-canary-20250713-8f814f8.aar.sha256 +1 -0
  11. package/local-maven-repo/host/exp/exponent/expo.modules.gl/15.1.8-canary-20250713-8f814f8/expo.modules.gl-15.1.8-canary-20250713-8f814f8.aar.sha512 +1 -0
  12. package/local-maven-repo/host/exp/exponent/expo.modules.gl/{15.1.8-canary-20250701-6a945c5/expo.modules.gl-15.1.8-canary-20250701-6a945c5.module → 15.1.8-canary-20250713-8f814f8/expo.modules.gl-15.1.8-canary-20250713-8f814f8.module} +17 -17
  13. package/local-maven-repo/host/exp/exponent/expo.modules.gl/15.1.8-canary-20250713-8f814f8/expo.modules.gl-15.1.8-canary-20250713-8f814f8.module.md5 +1 -0
  14. package/local-maven-repo/host/exp/exponent/expo.modules.gl/15.1.8-canary-20250713-8f814f8/expo.modules.gl-15.1.8-canary-20250713-8f814f8.module.sha1 +1 -0
  15. package/local-maven-repo/host/exp/exponent/expo.modules.gl/15.1.8-canary-20250713-8f814f8/expo.modules.gl-15.1.8-canary-20250713-8f814f8.module.sha256 +1 -0
  16. package/local-maven-repo/host/exp/exponent/expo.modules.gl/15.1.8-canary-20250713-8f814f8/expo.modules.gl-15.1.8-canary-20250713-8f814f8.module.sha512 +1 -0
  17. package/local-maven-repo/host/exp/exponent/expo.modules.gl/{15.1.8-canary-20250701-6a945c5/expo.modules.gl-15.1.8-canary-20250701-6a945c5.pom → 15.1.8-canary-20250713-8f814f8/expo.modules.gl-15.1.8-canary-20250713-8f814f8.pom} +1 -1
  18. package/local-maven-repo/host/exp/exponent/expo.modules.gl/15.1.8-canary-20250713-8f814f8/expo.modules.gl-15.1.8-canary-20250713-8f814f8.pom.md5 +1 -0
  19. package/local-maven-repo/host/exp/exponent/expo.modules.gl/15.1.8-canary-20250713-8f814f8/expo.modules.gl-15.1.8-canary-20250713-8f814f8.pom.sha1 +1 -0
  20. package/local-maven-repo/host/exp/exponent/expo.modules.gl/15.1.8-canary-20250713-8f814f8/expo.modules.gl-15.1.8-canary-20250713-8f814f8.pom.sha256 +1 -0
  21. package/local-maven-repo/host/exp/exponent/expo.modules.gl/15.1.8-canary-20250713-8f814f8/expo.modules.gl-15.1.8-canary-20250713-8f814f8.pom.sha512 +1 -0
  22. package/local-maven-repo/host/exp/exponent/expo.modules.gl/maven-metadata.xml +4 -4
  23. package/local-maven-repo/host/exp/exponent/expo.modules.gl/maven-metadata.xml.md5 +1 -1
  24. package/local-maven-repo/host/exp/exponent/expo.modules.gl/maven-metadata.xml.sha1 +1 -1
  25. package/local-maven-repo/host/exp/exponent/expo.modules.gl/maven-metadata.xml.sha256 +1 -1
  26. package/local-maven-repo/host/exp/exponent/expo.modules.gl/maven-metadata.xml.sha512 +1 -1
  27. package/package.json +3 -3
  28. package/src/Canvas.tsx +6 -5
  29. package/local-maven-repo/host/exp/exponent/expo.modules.gl/15.1.8-canary-20250701-6a945c5/expo.modules.gl-15.1.8-canary-20250701-6a945c5.aar.md5 +0 -1
  30. package/local-maven-repo/host/exp/exponent/expo.modules.gl/15.1.8-canary-20250701-6a945c5/expo.modules.gl-15.1.8-canary-20250701-6a945c5.aar.sha1 +0 -1
  31. package/local-maven-repo/host/exp/exponent/expo.modules.gl/15.1.8-canary-20250701-6a945c5/expo.modules.gl-15.1.8-canary-20250701-6a945c5.aar.sha256 +0 -1
  32. package/local-maven-repo/host/exp/exponent/expo.modules.gl/15.1.8-canary-20250701-6a945c5/expo.modules.gl-15.1.8-canary-20250701-6a945c5.aar.sha512 +0 -1
  33. package/local-maven-repo/host/exp/exponent/expo.modules.gl/15.1.8-canary-20250701-6a945c5/expo.modules.gl-15.1.8-canary-20250701-6a945c5.module.md5 +0 -1
  34. package/local-maven-repo/host/exp/exponent/expo.modules.gl/15.1.8-canary-20250701-6a945c5/expo.modules.gl-15.1.8-canary-20250701-6a945c5.module.sha1 +0 -1
  35. package/local-maven-repo/host/exp/exponent/expo.modules.gl/15.1.8-canary-20250701-6a945c5/expo.modules.gl-15.1.8-canary-20250701-6a945c5.module.sha256 +0 -1
  36. package/local-maven-repo/host/exp/exponent/expo.modules.gl/15.1.8-canary-20250701-6a945c5/expo.modules.gl-15.1.8-canary-20250701-6a945c5.module.sha512 +0 -1
  37. package/local-maven-repo/host/exp/exponent/expo.modules.gl/15.1.8-canary-20250701-6a945c5/expo.modules.gl-15.1.8-canary-20250701-6a945c5.pom.md5 +0 -1
  38. package/local-maven-repo/host/exp/exponent/expo.modules.gl/15.1.8-canary-20250701-6a945c5/expo.modules.gl-15.1.8-canary-20250701-6a945c5.pom.sha1 +0 -1
  39. package/local-maven-repo/host/exp/exponent/expo.modules.gl/15.1.8-canary-20250701-6a945c5/expo.modules.gl-15.1.8-canary-20250701-6a945c5.pom.sha256 +0 -1
  40. package/local-maven-repo/host/exp/exponent/expo.modules.gl/15.1.8-canary-20250701-6a945c5/expo.modules.gl-15.1.8-canary-20250701-6a945c5.pom.sha512 +0 -1
  41. /package/local-maven-repo/host/exp/exponent/expo.modules.gl/{15.1.8-canary-20250701-6a945c5/expo.modules.gl-15.1.8-canary-20250701-6a945c5-sources.jar → 15.1.8-canary-20250713-8f814f8/expo.modules.gl-15.1.8-canary-20250713-8f814f8-sources.jar} +0 -0
  42. /package/local-maven-repo/host/exp/exponent/expo.modules.gl/{15.1.8-canary-20250701-6a945c5/expo.modules.gl-15.1.8-canary-20250701-6a945c5-sources.jar.md5 → 15.1.8-canary-20250713-8f814f8/expo.modules.gl-15.1.8-canary-20250713-8f814f8-sources.jar.md5} +0 -0
  43. /package/local-maven-repo/host/exp/exponent/expo.modules.gl/{15.1.8-canary-20250701-6a945c5/expo.modules.gl-15.1.8-canary-20250701-6a945c5-sources.jar.sha1 → 15.1.8-canary-20250713-8f814f8/expo.modules.gl-15.1.8-canary-20250713-8f814f8-sources.jar.sha1} +0 -0
  44. /package/local-maven-repo/host/exp/exponent/expo.modules.gl/{15.1.8-canary-20250701-6a945c5/expo.modules.gl-15.1.8-canary-20250701-6a945c5-sources.jar.sha256 → 15.1.8-canary-20250713-8f814f8/expo.modules.gl-15.1.8-canary-20250713-8f814f8-sources.jar.sha256} +0 -0
  45. /package/local-maven-repo/host/exp/exponent/expo.modules.gl/{15.1.8-canary-20250701-6a945c5/expo.modules.gl-15.1.8-canary-20250701-6a945c5-sources.jar.sha512 → 15.1.8-canary-20250713-8f814f8/expo.modules.gl-15.1.8-canary-20250713-8f814f8-sources.jar.sha512} +0 -0
package/CHANGELOG.md CHANGED
@@ -10,6 +10,8 @@
10
10
 
11
11
  ### 💡 Others
12
12
 
13
+ - Use pointerEvents style instead of prop for components on web. ([#38023](https://github.com/expo/expo/pull/38023) by [@EvanBacon](https://github.com/EvanBacon))
14
+
13
15
  ## 15.1.7 - 2025-07-01
14
16
 
15
17
  ### 🐛 Bug fixes
@@ -9,7 +9,7 @@ def reactNativeArchitectures() {
9
9
  }
10
10
 
11
11
  group = 'host.exp.exponent'
12
- version = '15.1.8-canary-20250701-6a945c5'
12
+ version = '15.1.8-canary-20250713-8f814f8'
13
13
 
14
14
  android {
15
15
  if (rootProject.hasProperty("ndkPath")) {
@@ -22,7 +22,7 @@ android {
22
22
  namespace "expo.modules.gl"
23
23
  defaultConfig {
24
24
  versionCode 31
25
- versionName "15.1.8-canary-20250701-6a945c5"
25
+ versionName "15.1.8-canary-20250713-8f814f8"
26
26
 
27
27
  externalNativeBuild {
28
28
  cmake {
@@ -1 +1 @@
1
- {"version":3,"file":"Canvas.d.ts","sourceRoot":"","sources":["../src/Canvas.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAE/B,OAAO,EAAmD,SAAS,EAAE,MAAM,cAAc,CAAC;AAgD1F,QAAA,MAAM,aAAa,EAAE,KAAK,CAAC,iBAAiB,CAC1C,SAAS,GAAG;IACV,SAAS,EAAE,KAAK,CAAC,GAAG,CAAC,iBAAiB,CAAC,CAAC;CACzC,CAmEF,CAAC;AAQF,eAAe,aAAa,CAAC"}
1
+ {"version":3,"file":"Canvas.d.ts","sourceRoot":"","sources":["../src/Canvas.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAE/B,OAAO,EAAmD,SAAS,EAAE,MAAM,cAAc,CAAC;AAiD1F,QAAA,MAAM,aAAa,EAAE,KAAK,CAAC,iBAAiB,CAC1C,SAAS,GAAG;IACV,SAAS,EAAE,KAAK,CAAC,GAAG,CAAC,iBAAiB,CAAC,CAAC;CACzC,CAmEF,CAAC;AAQF,eAAe,aAAa,CAAC"}
package/build/Canvas.js CHANGED
@@ -32,7 +32,7 @@ function getSize({ size, ref }) {
32
32
  const { offsetWidth: width = 0, offsetHeight: height = 0 } = element;
33
33
  return { width, height };
34
34
  }
35
- const Canvas = React.forwardRef((props, ref) => createElement('canvas', { ...props, ref }));
35
+ const Canvas = (props) => createElement('canvas', props);
36
36
  const CanvasWrapper = ({ pointerEvents, children, style, ...props }) => {
37
37
  const [size, setSize] = React.useState(null);
38
38
  const ref = React.useRef(null);
@@ -76,7 +76,7 @@ const CanvasWrapper = ({ pointerEvents, children, style, ...props }) => {
76
76
  setRef(props.canvasRef, canvas);
77
77
  }, [_canvasRef]);
78
78
  return (<View {...props} style={[styles.wrapper, style]} ref={ref} onLayout={onLayout}>
79
- <Canvas ref={_canvasRef} pointerEvents={pointerEvents} style={StyleSheet.absoluteFill}/>
79
+ <Canvas ref={_canvasRef} style={[StyleSheet.absoluteFill, { pointerEvents }]}/>
80
80
  {children}
81
81
  </View>);
82
82
  };
@@ -1 +1 @@
1
- {"version":3,"file":"Canvas.js","sourceRoot":"","sources":["../src/Canvas.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,EAAE,WAAW,EAAE,MAAM,WAAW,CAAC;AACxC,OAAO,EAAqB,UAAU,EAAE,UAAU,EAAE,IAAI,EAAa,MAAM,cAAc,CAAC;AAC1F,OAAO,aAAa,MAAM,6CAA6C,CAAC;AAYxE,SAAS,UAAU,CAAC,SAA8B;IAChD,IAAI,CAAC;QACH,OAAO,WAAW,CAAC,SAAS,CAAC,CAAC;IAChC,CAAC;IAAC,MAAM,CAAC;QACP,OAAO,SAAS,CAAC;IACnB,CAAC;AACH,CAAC;AAED,SAAS,MAAM,CAAI,OAAqB,EAAE,GAAa;IACrD,IAAI,CAAC,OAAO;QAAE,OAAO;IAErB,IAAI,OAAO,OAAO,KAAK,UAAU,EAAE,CAAC;QAClC,OAAO,CAAC,GAAG,CAAC,CAAC;IACf,CAAC;SAAM,IAAI,SAAS,IAAI,OAAO,EAAE,CAAC;QAChC,aAAa;QACb,OAAO,CAAC,OAAO,GAAG,GAAG,CAAC;IACxB,CAAC;AACH,CAAC;AAED,SAAS,OAAO,CAAC,EAAE,IAAI,EAAE,GAAG,EAAiB;IAC3C,IAAI,IAAI,EAAE,CAA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SAAS,CAAC,GAAG,EAAE;QACnB,gBAAgB,EAAE,CAAC;IACrB,CAAC,EAAE,CAAC,IAAI,CAAC,CAAC,CAAC;IAEX,KAAK,CAAC,SAAS,CAAC,GAAG,EAAE;QACnB,MAAM,MAAM,GAAG,UAAU,CAAC,OAAO,CAAC;QAClC,IAAI,MAAM,EAAE,CAAC;YACX,gBAAgB,EAAE,CAAC;QACrB,CAAC;QACD,MAAM,CAAC,KAAK,CAAC,SAAS,EAAE,MAAM,CAAC,CAAC;IAClC,CAAC,EAAE,CAAC,UAAU,CAAC,CAAC,CAAC;IAEjB,OAAO,CACL,CAAC,IAAI,CAAC,IAAI,KAAK,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,CAAC,OAAO,EAAE,KAAK,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,GAAG,CAAC,CAAC,QAAQ,CAAC,CAAC,QAAQ,CAAC,CAC5E;MAAA,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,UAAU,CAAC,CAAC,aAAa,CAAC,CAAC,aAAa,CAAC,CAAC,KAAK,CAAC,CAAC,UAAU,CAAC,YAAY,CAAC,EACtF;MAAA,CAAC,QAAQ,CACX;IAAA,EAAE,IAAI,CAAC,CACR,CAAC;AACJ,CAAC,CAAC;AAEF,MAAM,MAAM,GAAG,UAAU,CAAC,MAAM,CAAC;IAC/B,OAAO,EAAE;QACP,aAAa,EAAE,UAAU;KAC1B;CACF,CAAC,CAAC;AAEH,eAAe,aAAa,CAAC","sourcesContent":["import * as React from 'react';\nimport { findDOMNode } from 'react-dom';\nimport { LayoutChangeEvent, PixelRatio, StyleSheet, View, ViewProps } from 'react-native';\nimport createElement from 'react-native-web/dist/exports/createElement';\n\ninterface Size {\n width: number;\n height: number;\n}\n\ninterface GetSizeParams {\n size: Size | null;\n ref: React.RefObject<View | null>;\n}\n\nfunction getElement(component: React.ReactInstance): React.ReactInstance | Element | null | Text {\n try {\n return findDOMNode(component);\n } catch {\n return component;\n }\n}\n\nfunction setRef<T>(refProp: React.Ref<T>, ref: T | null) {\n if (!refProp) return;\n\n if (typeof refProp === 'function') {\n refProp(ref);\n } else if ('current' in refProp) {\n // @ts-ignore\n refProp.current = ref;\n }\n}\n\nfunction getSize({ size, ref }: GetSizeParams): Size {\n if (size) {\n return size;\n } else if (!ref.current || typeof window === 'undefined') {\n return { width: 0, height: 0 };\n }\n const element = getElement(ref.current);\n const { offsetWidth: width = 0, offsetHeight: height = 0 } = element as HTMLElement;\n return { width, height };\n}\n\nconst Canvas = React.forwardRef(\n (props: React.ComponentProps<typeof View>, ref: React.Ref<HTMLCanvasElement>) =>\n createElement('canvas', { ...props, ref })\n);\n\nconst CanvasWrapper: React.FunctionComponent<\n ViewProps & {\n canvasRef: React.Ref<HTMLCanvasElement>;\n }\n> = ({ pointerEvents, children, style, ...props }) => {\n const [size, setSize] = React.useState<Size | null>(null);\n\n const ref = React.useRef<View>(null);\n const _canvasRef = React.useRef<HTMLCanvasElement>(null);\n\n const updateCanvasSize = React.useCallback(() => {\n const canvas = _canvasRef.current;\n if (typeof HTMLCanvasElement !== 'undefined' && canvas instanceof HTMLCanvasElement) {\n const currentSize = getSize({\n size,\n ref,\n });\n const scale = PixelRatio.get();\n\n canvas.style.width = `${currentSize.width}px`;\n canvas.style.height = `${currentSize.height}px`;\n\n canvas.width = currentSize.width * scale;\n canvas.height = currentSize.height * scale;\n }\n }, [size?.width, size?.height]);\n\n const onLayout = React.useCallback(\n (event: LayoutChangeEvent) => {\n const {\n nativeEvent: {\n layout: { width, height },\n },\n } = event;\n\n if (width !== size?.width || height !== size?.height) {\n setSize({ width, height });\n\n if (props.onLayout) {\n props.onLayout(event);\n }\n }\n },\n [size?.width, size?.height, props.onLayout]\n );\n\n React.useEffect(() => {\n if (ref.current != null) {\n setSize(getSize({ size, ref }));\n }\n }, [ref]);\n\n React.useEffect(() => {\n updateCanvasSize();\n }, [size]);\n\n React.useEffect(() => {\n const canvas = _canvasRef.current;\n if (canvas) {\n updateCanvasSize();\n }\n setRef(props.canvasRef, canvas);\n }, [_canvasRef]);\n\n return (\n <View {...props} style={[styles.wrapper, style]} ref={ref} onLayout={onLayout}>\n <Canvas ref={_canvasRef} pointerEvents={pointerEvents} style={StyleSheet.absoluteFill} />\n {children}\n </View>\n );\n};\n\nconst styles = StyleSheet.create({\n wrapper: {\n pointerEvents: 'box-none',\n },\n});\n\nexport default CanvasWrapper;\n"]}
1
+ {"version":3,"file":"Canvas.js","sourceRoot":"","sources":["../src/Canvas.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,EAAE,WAAW,EAAE,MAAM,WAAW,CAAC;AACxC,OAAO,EAAqB,UAAU,EAAE,UAAU,EAAE,IAAI,EAAa,MAAM,cAAc,CAAC;AAC1F,OAAO,aAAa,MAAM,6CAA6C,CAAC;AAYxE,SAAS,UAAU,CAAC,SAA8B;IAChD,IAAI,CAAC;QACH,OAAO,WAAW,CAAC,SAAS,CAAC,CAAC;IAChC,CAAC;IAAC,MAAM,CAAC;QACP,OAAO,SAAS,CAAC;IACnB,CAAC;AACH,CAAC;AAED,SAAS,MAAM,CAAI,OAAqB,EAAE,GAAa;IACrD,IAAI,CAAC,OAAO;QAAE,OAAO;IAErB,IAAI,OAAO,OAAO,KAAK,UAAU,EAAE,CAAC;QAClC,OAAO,CAAC,GAAG,CAAC,CAAC;IACf,CAAC;SAAM,IAAI,SAAS,IAAI,OAAO,EAAE,CAAC;QAChC,aAAa;QACb,OAAO,CAAC,OAAO,GAAG,GAAG,CAAC;IACxB,CAAC;AACH,CAAC;AAED,SAAS,OAAO,CAAC,EAAE,IAAI,EAAE,GAAG,EAAiB;IAC3C,IAAI,IAAI,EAAE,CAAC;QACT,OAAO,IAAI,CAAC;IACd,CAAC;SAAM,IAAI,CAAC,GAAG,CAAC,OAAO,IAAI,OAAO,MAAM,KAAK,WAAW,EAAE,CAAC;QACzD,OAAO,EAAE,KAAK,EAAE,CAAC,EAAE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AE,CAAC;QACrB,CAAC;QACD,MAAM,CAAC,KAAK,CAAC,SAAS,EAAE,MAAM,CAAC,CAAC;IAClC,CAAC,EAAE,CAAC,UAAU,CAAC,CAAC,CAAC;IAEjB,OAAO,CACL,CAAC,IAAI,CAAC,IAAI,KAAK,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,CAAC,OAAO,EAAE,KAAK,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,GAAG,CAAC,CAAC,QAAQ,CAAC,CAAC,QAAQ,CAAC,CAC5E;MAAA,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,UAAU,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,UAAU,CAAC,YAAY,EAAE,EAAE,aAAa,EAAE,CAAC,CAAC,EAC7E;MAAA,CAAC,QAAQ,CACX;IAAA,EAAE,IAAI,CAAC,CACR,CAAC;AACJ,CAAC,CAAC;AAEF,MAAM,MAAM,GAAG,UAAU,CAAC,MAAM,CAAC;IAC/B,OAAO,EAAE;QACP,aAAa,EAAE,UAAU;KAC1B;CACF,CAAC,CAAC;AAEH,eAAe,aAAa,CAAC","sourcesContent":["import * as React from 'react';\nimport { findDOMNode } from 'react-dom';\nimport { LayoutChangeEvent, PixelRatio, StyleSheet, View, ViewProps } from 'react-native';\nimport createElement from 'react-native-web/dist/exports/createElement';\n\ninterface Size {\n width: number;\n height: number;\n}\n\ninterface GetSizeParams {\n size: Size | null;\n ref: React.RefObject<View | null>;\n}\n\nfunction getElement(component: React.ReactInstance): React.ReactInstance | Element | null | Text {\n try {\n return findDOMNode(component);\n } catch {\n return component;\n }\n}\n\nfunction setRef<T>(refProp: React.Ref<T>, ref: T | null) {\n if (!refProp) return;\n\n if (typeof refProp === 'function') {\n refProp(ref);\n } else if ('current' in refProp) {\n // @ts-ignore\n refProp.current = ref;\n }\n}\n\nfunction getSize({ size, ref }: GetSizeParams): Size {\n if (size) {\n return size;\n } else if (!ref.current || typeof window === 'undefined') {\n return { width: 0, height: 0 };\n }\n const element = getElement(ref.current);\n const { offsetWidth: width = 0, offsetHeight: height = 0 } = element as HTMLElement;\n return { width, height };\n}\n\nconst Canvas = (\n props: React.ComponentProps<typeof View> & {\n ref?: React.Ref<HTMLCanvasElement>;\n }\n) => createElement('canvas', props);\n\nconst CanvasWrapper: React.FunctionComponent<\n ViewProps & {\n canvasRef: React.Ref<HTMLCanvasElement>;\n }\n> = ({ pointerEvents, children, style, ...props }) => {\n const [size, setSize] = React.useState<Size | null>(null);\n\n const ref = React.useRef<View>(null);\n const _canvasRef = React.useRef<HTMLCanvasElement>(null);\n\n const updateCanvasSize = React.useCallback(() => {\n const canvas = _canvasRef.current;\n if (typeof HTMLCanvasElement !== 'undefined' && canvas instanceof HTMLCanvasElement) {\n const currentSize = getSize({\n size,\n ref,\n });\n const scale = PixelRatio.get();\n\n canvas.style.width = `${currentSize.width}px`;\n canvas.style.height = `${currentSize.height}px`;\n\n canvas.width = currentSize.width * scale;\n canvas.height = currentSize.height * scale;\n }\n }, [size?.width, size?.height]);\n\n const onLayout = React.useCallback(\n (event: LayoutChangeEvent) => {\n const {\n nativeEvent: {\n layout: { width, height },\n },\n } = event;\n\n if (width !== size?.width || height !== size?.height) {\n setSize({ width, height });\n\n if (props.onLayout) {\n props.onLayout(event);\n }\n }\n },\n [size?.width, size?.height, props.onLayout]\n );\n\n React.useEffect(() => {\n if (ref.current != null) {\n setSize(getSize({ size, ref }));\n }\n }, [ref]);\n\n React.useEffect(() => {\n updateCanvasSize();\n }, [size]);\n\n React.useEffect(() => {\n const canvas = _canvasRef.current;\n if (canvas) {\n updateCanvasSize();\n }\n setRef(props.canvasRef, canvas);\n }, [_canvasRef]);\n\n return (\n <View {...props} style={[styles.wrapper, style]} ref={ref} onLayout={onLayout}>\n <Canvas ref={_canvasRef} style={[StyleSheet.absoluteFill, { pointerEvents }]} />\n {children}\n </View>\n );\n};\n\nconst styles = StyleSheet.create({\n wrapper: {\n pointerEvents: 'box-none',\n },\n});\n\nexport default CanvasWrapper;\n"]}
@@ -9,7 +9,7 @@
9
9
  "publication": {
10
10
  "groupId": "host.exp.exponent",
11
11
  "artifactId": "expo.modules.gl",
12
- "version": "15.1.8-canary-20250701-6a945c5",
12
+ "version": "15.1.8-canary-20250713-8f814f8",
13
13
  "repository": "local-maven-repo"
14
14
  }
15
15
  }
@@ -0,0 +1 @@
1
+ 2202e3eb08e28665adb7aa95e5478a45c57cec3d10894422a9b2c3ae94fe8945f3c517285fc5a37198ded7e55d3e8cd2ac719fe7b06d9366131c24ea59923476
@@ -3,7 +3,7 @@
3
3
  "component": {
4
4
  "group": "host.exp.exponent",
5
5
  "module": "expo.modules.gl",
6
- "version": "15.1.8-canary-20250701-6a945c5",
6
+ "version": "15.1.8-canary-20250713-8f814f8",
7
7
  "attributes": {
8
8
  "org.gradle.status": "release"
9
9
  }
@@ -24,13 +24,13 @@
24
24
  },
25
25
  "files": [
26
26
  {
27
- "name": "expo.modules.gl-15.1.8-canary-20250701-6a945c5.aar",
28
- "url": "expo.modules.gl-15.1.8-canary-20250701-6a945c5.aar",
29
- "size": 1044171,
30
- "sha512": "51525c18d1b76adc2f2ae9fdfd86eff951d289473ea8c8f4176ebd9dac85ef1b7e9e54dad0af7829443a8c969aacb1ab5f936b7ed5578f47c4792e05386d7178",
31
- "sha256": "f2be8e193e6c0f6dd7a85d8e16c9abc7005a6f6a576aa1835f83a148b3e38aea",
32
- "sha1": "3ca224d1c7e4ec705285a8ca7e2f57a0a1e3afa0",
33
- "md5": "03365c21b0ac6f0c67c27373c990a7d3"
27
+ "name": "expo.modules.gl-15.1.8-canary-20250713-8f814f8.aar",
28
+ "url": "expo.modules.gl-15.1.8-canary-20250713-8f814f8.aar",
29
+ "size": 1044170,
30
+ "sha512": "2202e3eb08e28665adb7aa95e5478a45c57cec3d10894422a9b2c3ae94fe8945f3c517285fc5a37198ded7e55d3e8cd2ac719fe7b06d9366131c24ea59923476",
31
+ "sha256": "527fcd582585cac3e26b3ecfe4ce8c3383c849a23ab4094015d3265803b84bcb",
32
+ "sha1": "3d787c06258621ded9817aad8f7fbc71565228df",
33
+ "md5": "ed6bc657fa8295e2861be6563e676bee"
34
34
  }
35
35
  ]
36
36
  },
@@ -53,13 +53,13 @@
53
53
  ],
54
54
  "files": [
55
55
  {
56
- "name": "expo.modules.gl-15.1.8-canary-20250701-6a945c5.aar",
57
- "url": "expo.modules.gl-15.1.8-canary-20250701-6a945c5.aar",
58
- "size": 1044171,
59
- "sha512": "51525c18d1b76adc2f2ae9fdfd86eff951d289473ea8c8f4176ebd9dac85ef1b7e9e54dad0af7829443a8c969aacb1ab5f936b7ed5578f47c4792e05386d7178",
60
- "sha256": "f2be8e193e6c0f6dd7a85d8e16c9abc7005a6f6a576aa1835f83a148b3e38aea",
61
- "sha1": "3ca224d1c7e4ec705285a8ca7e2f57a0a1e3afa0",
62
- "md5": "03365c21b0ac6f0c67c27373c990a7d3"
56
+ "name": "expo.modules.gl-15.1.8-canary-20250713-8f814f8.aar",
57
+ "url": "expo.modules.gl-15.1.8-canary-20250713-8f814f8.aar",
58
+ "size": 1044170,
59
+ "sha512": "2202e3eb08e28665adb7aa95e5478a45c57cec3d10894422a9b2c3ae94fe8945f3c517285fc5a37198ded7e55d3e8cd2ac719fe7b06d9366131c24ea59923476",
60
+ "sha256": "527fcd582585cac3e26b3ecfe4ce8c3383c849a23ab4094015d3265803b84bcb",
61
+ "sha1": "3d787c06258621ded9817aad8f7fbc71565228df",
62
+ "md5": "ed6bc657fa8295e2861be6563e676bee"
63
63
  }
64
64
  ]
65
65
  },
@@ -73,8 +73,8 @@
73
73
  },
74
74
  "files": [
75
75
  {
76
- "name": "expo.modules.gl-15.1.8-canary-20250701-6a945c5-sources.jar",
77
- "url": "expo.modules.gl-15.1.8-canary-20250701-6a945c5-sources.jar",
76
+ "name": "expo.modules.gl-15.1.8-canary-20250713-8f814f8-sources.jar",
77
+ "url": "expo.modules.gl-15.1.8-canary-20250713-8f814f8-sources.jar",
78
78
  "size": 12381,
79
79
  "sha512": "1cab724074b050f7459a884ac9e98fbf2d009d8239810ca6384c5113f52dd33e5ac40a72ec7174b297e1b10521e56682d73f533715316be5be66ce0e482356d8",
80
80
  "sha256": "e8892c6837d1eb5093b2c3b063883d7511799b0e246940c5b70f1515cb4451cd",
@@ -0,0 +1 @@
1
+ 4ec912e85b94f39aa51e96425395a809d065cda2ca683467bf8f19b7d17fdb3322f6fce268b53664b6ec7ace85e5bcbf7e7bdb1faed23596df8454ce10e9d65c
@@ -9,7 +9,7 @@
9
9
  <modelVersion>4.0.0</modelVersion>
10
10
  <groupId>host.exp.exponent</groupId>
11
11
  <artifactId>expo.modules.gl</artifactId>
12
- <version>15.1.8-canary-20250701-6a945c5</version>
12
+ <version>15.1.8-canary-20250713-8f814f8</version>
13
13
  <packaging>aar</packaging>
14
14
  <name>expo.modules.gl</name>
15
15
  <url>https://github.com/expo/expo</url>
@@ -0,0 +1 @@
1
+ cf90edebe2063df28257a94c53731a5a18cac65f7755b91302d88971f1d1c064f39216029e21bb5c1f3b0528aabc09b60e14588638b062ad502e625db82b0a42
@@ -3,11 +3,11 @@
3
3
  <groupId>host.exp.exponent</groupId>
4
4
  <artifactId>expo.modules.gl</artifactId>
5
5
  <versioning>
6
- <latest>15.1.8-canary-20250701-6a945c5</latest>
7
- <release>15.1.8-canary-20250701-6a945c5</release>
6
+ <latest>15.1.8-canary-20250713-8f814f8</latest>
7
+ <release>15.1.8-canary-20250713-8f814f8</release>
8
8
  <versions>
9
- <version>15.1.8-canary-20250701-6a945c5</version>
9
+ <version>15.1.8-canary-20250713-8f814f8</version>
10
10
  </versions>
11
- <lastUpdated>20250701174230</lastUpdated>
11
+ <lastUpdated>20250713133652</lastUpdated>
12
12
  </versioning>
13
13
  </metadata>
@@ -1 +1 @@
1
- d41d8a5f9880ca6384586166e7d45345
1
+ 13377881f7e9b5e4c5876489ff43dfdf
@@ -1 +1 @@
1
- d5384ffae3a15e3e155e1535d8ef3a54fd5ae0cd
1
+ 2e942d4eecc486588df719b232996fa5d95aec2c
@@ -1 +1 @@
1
- ab805c7590912fedbd41f501acfc68f7c5a4a7107991de423ee3f1392f8efc4e
1
+ 1d716c259edfcf4bba855da8fb5ab8b04d368c2c8574ed8de47540c28142bf45
@@ -1 +1 @@
1
- 0e479dac880568f9b2dfbf482325e6f1c4d1af1eebb7cbe3aaff5627c877d6769e0416d3066a1912de76d11e999f3786c5cc9d75e510af96e9d4927b884771a9
1
+ ac9d69e695c9ee0b1fa7ca7453e85756992b60524ff83462569062b572ca1138c1c24b68482824a6ef2eb55c0a375224ef01956aa5843a7efe182a9e8e1d0d2c
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "expo-gl",
3
- "version": "15.1.8-canary-20250701-6a945c5",
3
+ "version": "15.1.8-canary-20250713-8f814f8",
4
4
  "description": "Provides GLView that acts as OpenGL ES render target and gives GL context object implementing WebGL 2.0 specification.",
5
5
  "main": "build/index.js",
6
6
  "types": "build/index.d.ts",
@@ -43,11 +43,11 @@
43
43
  "@types/invariant": "^2.2.33",
44
44
  "@types/offscreencanvas": "2019.6.4",
45
45
  "@types/webgl2": "^0.0.6",
46
- "expo-module-scripts": "4.1.9-canary-20250701-6a945c5",
46
+ "expo-module-scripts": "4.1.10-canary-20250713-8f814f8",
47
47
  "react-test-renderer": "19.1.0"
48
48
  },
49
49
  "peerDependencies": {
50
- "expo": "54.0.0-canary-20250701-6a945c5",
50
+ "expo": "54.0.0-canary-20250713-8f814f8",
51
51
  "react": "*",
52
52
  "react-native": "*",
53
53
  "react-native-web": "*"
package/src/Canvas.tsx CHANGED
@@ -43,10 +43,11 @@ function getSize({ size, ref }: GetSizeParams): Size {
43
43
  return { width, height };
44
44
  }
45
45
 
46
- const Canvas = React.forwardRef(
47
- (props: React.ComponentProps<typeof View>, ref: React.Ref<HTMLCanvasElement>) =>
48
- createElement('canvas', { ...props, ref })
49
- );
46
+ const Canvas = (
47
+ props: React.ComponentProps<typeof View> & {
48
+ ref?: React.Ref<HTMLCanvasElement>;
49
+ }
50
+ ) => createElement('canvas', props);
50
51
 
51
52
  const CanvasWrapper: React.FunctionComponent<
52
53
  ViewProps & {
@@ -114,7 +115,7 @@ const CanvasWrapper: React.FunctionComponent<
114
115
 
115
116
  return (
116
117
  <View {...props} style={[styles.wrapper, style]} ref={ref} onLayout={onLayout}>
117
- <Canvas ref={_canvasRef} pointerEvents={pointerEvents} style={StyleSheet.absoluteFill} />
118
+ <Canvas ref={_canvasRef} style={[StyleSheet.absoluteFill, { pointerEvents }]} />
118
119
  {children}
119
120
  </View>
120
121
  );
@@ -1 +0,0 @@
1
- 51525c18d1b76adc2f2ae9fdfd86eff951d289473ea8c8f4176ebd9dac85ef1b7e9e54dad0af7829443a8c969aacb1ab5f936b7ed5578f47c4792e05386d7178
@@ -1 +0,0 @@
1
- 24ba851d19e8e88077cb930015a2e40ed7fc30724d9f486541e75494f86aed97fa277286bdb3eaec71b4e342cce4293f81badbc718551cb8834f55b302faee8e
@@ -1 +0,0 @@
1
- a7b902df4a82cd7aa503452392fd2c6d372df54406d49db97053c133f106178e3045648ae1737ecadbe0fa785064bf284590a759559b943df8db76db39c621a6