{"version":3,"names":["_defineProperty","obj","key","value","_toPropertyKey","Object","defineProperty","enumerable","configurable","writable","arg","_toPrimitive","String","input","hint","prim","Symbol","toPrimitive","undefined","res","call","TypeError","Number","isChromeDebugger","isJest","isWeb","isWindowAvailable","SensorType","mockedRequestAnimationFrame","requestAnimationFrameImpl","globalThis","requestAnimationFrame","JSReanimated","constructor","Map","sensor","sensorType","eventHandler","ACCELEROMETER","GRAVITY","x","y","z","platform","Platform","WEB_ANDROID","interfaceOrientation","GYROSCOPE","MAGNETIC_FIELD","ROTATION","qw","qx","qy","qz","quaternion","yaw","Math","atan2","pitch","sin","roll","makeShareableClone","Error","scheduleOnUI","worklet","createWorkletRuntime","_name","_initializer","scheduleOnRuntime","registerEventHandler","_eventHandler","_eventName","_emitterReactTag","unregisterEventHandler","_","enableLayoutAnimations","console","warn","configureLayoutAnimation","configureLayoutAnimationBatch","setShouldAnimateExitingForTag","registerSensor","interval","_iosReferenceFrame","detectPlatform","getSensorName","window","location","protocol","WEB_IOS","initializeSensor","addEventListener","getSensorCallback","start","sensors","set","nextSensorId","unregisterSensor","id","get","stop","delete","subscribeForKeyboardEvents","unsubscribeFromKeyboardEvents","config","referenceFrame","frequency","Accelerometer","Gyroscope","GravitySensor","Magnetometer","AbsoluteOrientationSensor","userAgent","navigator","vendor","opera","UNKNOWN","test","WEB","getViewProp","_viewTag","_propName","_callback","configureProps","executeOnUIRuntimeSync","_shareable"],"sources":["JSReanimated.ts"],"sourcesContent":["'use strict';\nimport {\n isChromeDebugger,\n isJest,\n isWeb,\n isWindowAvailable,\n} from '../PlatformChecker';\nimport type { ShareableRef, Value3D, ValueRotation } from '../commonTypes';\nimport { SensorType } from '../commonTypes';\nimport type { WebSensor } from './WebSensor';\nimport { mockedRequestAnimationFrame } from '../mockedRequestAnimationFrame';\nimport type { WorkletRuntime } from '../runtimes';\n\n// In Node.js environments (like when static rendering with Expo Router)\n// requestAnimationFrame is unavailable, so we use our mock.\n// It also has to be mocked for Jest purposes (see `initializeUIRuntime`).\nconst requestAnimationFrameImpl =\n isJest() || !globalThis.requestAnimationFrame\n ? mockedRequestAnimationFrame\n : globalThis.requestAnimationFrame;\n\nexport default class JSReanimated {\n nextSensorId = 0;\n sensors = new Map();\n platform?: Platform = undefined;\n\n makeShareableClone(): ShareableRef {\n throw new Error(\n '[Reanimated] makeShareableClone should never be called in JSReanimated.'\n );\n }\n\n scheduleOnUI(worklet: ShareableRef) {\n // @ts-ignore web implementation has still not been updated after the rewrite, this will be addressed once the web implementation updates are ready\n requestAnimationFrameImpl(worklet);\n }\n\n createWorkletRuntime(\n _name: string,\n _initializer: ShareableRef<() => void>\n ): WorkletRuntime {\n throw new Error(\n '[Reanimated] createWorkletRuntime is not available in JSReanimated.'\n );\n }\n\n scheduleOnRuntime() {\n throw new Error(\n '[Reanimated] scheduleOnRuntime is not available in JSReanimated.'\n );\n }\n\n registerEventHandler(\n _eventHandler: ShareableRef,\n _eventName: string,\n _emitterReactTag: number\n ): number {\n // noop\n return -1;\n }\n\n unregisterEventHandler(_: number): void {\n // noop\n }\n\n enableLayoutAnimations() {\n if (isWeb()) {\n console.warn(\n '[Reanimated] Layout Animations are not supported on web yet.'\n );\n } else if (isJest()) {\n console.warn(\n '[Reanimated] Layout Animations are no-ops when using Jest.'\n );\n } else if (isChromeDebugger()) {\n console.warn(\n '[Reanimated] Layout Animations are no-ops when using Chrome Debugger.'\n );\n } else {\n console.warn(\n '[Reanimated] Layout Animations are not supported on this configuration.'\n );\n }\n }\n\n configureLayoutAnimation() {\n // no-op\n }\n\n configureLayoutAnimationBatch() {\n // no-op\n }\n\n setShouldAnimateExitingForTag() {\n // no-op\n }\n\n registerSensor(\n sensorType: SensorType,\n interval: number,\n _iosReferenceFrame: number,\n eventHandler: ShareableRef<(data: Value3D | ValueRotation) => void>\n ): number {\n if (!isWindowAvailable()) {\n // the window object is unavailable when building the server portion of a site that uses SSG\n // this check is here to ensure that the server build won't fail\n return -1;\n }\n\n if (this.platform === undefined) {\n this.detectPlatform();\n }\n\n if (!(this.getSensorName(sensorType) in window)) {\n // https://w3c.github.io/sensors/#secure-context\n console.warn(\n '[Reanimated] Sensor is not available.' +\n (isWeb() && location.protocol !== 'https:'\n ? ' Make sure you use secure origin with `npx expo start --web --https`.'\n : '') +\n (this.platform === Platform.WEB_IOS\n ? ' For iOS web, you will also have to also grant permission in the browser: https://dev.to/li/how-to-requestpermission-for-devicemotion-and-deviceorientation-events-in-ios-13-46g2.'\n : '')\n );\n return -1;\n }\n\n if (this.platform === undefined) {\n this.detectPlatform();\n }\n\n const sensor: WebSensor = this.initializeSensor(sensorType, interval);\n sensor.addEventListener(\n 'reading',\n this.getSensorCallback(sensor, sensorType, eventHandler)\n );\n sensor.start();\n\n this.sensors.set(this.nextSensorId, sensor);\n return this.nextSensorId++;\n }\n\n getSensorCallback = (\n sensor: WebSensor,\n sensorType: SensorType,\n eventHandler: ShareableRef<(data: Value3D | ValueRotation) => void>\n ) => {\n switch (sensorType) {\n case SensorType.ACCELEROMETER:\n case SensorType.GRAVITY:\n return () => {\n let { x, y, z } = sensor;\n\n // Web Android sensors have a different coordinate system than iOS\n if (this.platform === Platform.WEB_ANDROID) {\n [x, y, z] = [-x, -y, -z];\n }\n // TODO TYPESCRIPT on web ShareableRef is the value itself so we call it directly\n (eventHandler as any)({ x, y, z, interfaceOrientation: 0 });\n };\n case SensorType.GYROSCOPE:\n case SensorType.MAGNETIC_FIELD:\n return () => {\n const { x, y, z } = sensor;\n // TODO TYPESCRIPT on web ShareableRef is the value itself so we call it directly\n (eventHandler as any)({ x, y, z, interfaceOrientation: 0 });\n };\n case SensorType.ROTATION:\n return () => {\n let [qw, qx, qy, qz] = sensor.quaternion;\n\n // Android sensors have a different coordinate system than iOS\n if (this.platform === Platform.WEB_ANDROID) {\n [qy, qz] = [qz, -qy];\n }\n\n // reference: https://stackoverflow.com/questions/5782658/extracting-yaw-from-a-quaternion\n const yaw = -Math.atan2(\n 2.0 * (qy * qz + qw * qx),\n qw * qw - qx * qx - qy * qy + qz * qz\n );\n const pitch = Math.sin(-2.0 * (qx * qz - qw * qy));\n const roll = -Math.atan2(\n 2.0 * (qx * qy + qw * qz),\n qw * qw + qx * qx - qy * qy - qz * qz\n );\n // TODO TYPESCRIPT on web ShareableRef is the value itself so we call it directly\n (eventHandler as any)({\n qw,\n qx,\n qy,\n qz,\n yaw,\n pitch,\n roll,\n interfaceOrientation: 0,\n });\n };\n }\n };\n\n unregisterSensor(id: number): void {\n const sensor: WebSensor | undefined = this.sensors.get(id);\n if (sensor !== undefined) {\n sensor.stop();\n this.sensors.delete(id);\n }\n }\n\n subscribeForKeyboardEvents(_: ShareableRef): number {\n if (isWeb()) {\n console.warn(\n '[Reanimated] useAnimatedKeyboard is not available on web yet.'\n );\n } else if (isJest()) {\n console.warn(\n '[Reanimated] useAnimatedKeyboard is not available when using Jest.'\n );\n } else if (isChromeDebugger()) {\n console.warn(\n '[Reanimated] useAnimatedKeyboard is not available when using Chrome Debugger.'\n );\n } else {\n console.warn(\n '[Reanimated] useAnimatedKeyboard is not available on this configuration.'\n );\n }\n return -1;\n }\n\n unsubscribeFromKeyboardEvents(_: number): void {\n // noop\n }\n\n initializeSensor(sensorType: SensorType, interval: number): WebSensor {\n const config =\n interval <= 0\n ? { referenceFrame: 'device' }\n : { frequency: 1000 / interval };\n switch (sensorType) {\n case SensorType.ACCELEROMETER:\n return new window.Accelerometer(config);\n case SensorType.GYROSCOPE:\n return new window.Gyroscope(config);\n case SensorType.GRAVITY:\n return new window.GravitySensor(config);\n case SensorType.MAGNETIC_FIELD:\n return new window.Magnetometer(config);\n case SensorType.ROTATION:\n return new window.AbsoluteOrientationSensor(config);\n }\n }\n\n getSensorName(sensorType: SensorType): string {\n switch (sensorType) {\n case SensorType.ACCELEROMETER:\n return 'Accelerometer';\n case SensorType.GRAVITY:\n return 'GravitySensor';\n case SensorType.GYROSCOPE:\n return 'Gyroscope';\n case SensorType.MAGNETIC_FIELD:\n return 'Magnetometer';\n case SensorType.ROTATION:\n return 'AbsoluteOrientationSensor';\n }\n }\n\n detectPlatform() {\n const userAgent = navigator.userAgent || navigator.vendor || window.opera;\n if (userAgent === undefined) {\n this.platform = Platform.UNKNOWN;\n } else if (/iPad|iPhone|iPod/.test(userAgent)) {\n this.platform = Platform.WEB_IOS;\n } else if (/android/i.test(userAgent)) {\n this.platform = Platform.WEB_ANDROID;\n } else {\n this.platform = Platform.WEB;\n }\n }\n\n getViewProp(\n _viewTag: number,\n _propName: string,\n _callback?: (result: T) => void\n ): Promise {\n throw new Error(\n '[Reanimated] getViewProp is not available in JSReanimated.'\n );\n }\n\n configureProps() {\n throw new Error(\n '[Reanimated] configureProps is not available in JSReanimated.'\n );\n }\n\n executeOnUIRuntimeSync(_shareable: ShareableRef): R {\n throw new Error(\n '[Reanimated] `executeOnUIRuntimeSync` is not available in JSReanimated.'\n );\n }\n}\n\nenum Platform {\n WEB_IOS = 'web iOS',\n WEB_ANDROID = 'web Android',\n WEB = 'web',\n UNKNOWN = 'unknown',\n}\n\ndeclare global {\n interface Navigator {\n userAgent?: string;\n vendor?: string;\n }\n}\n"],"mappings":"AAAA,YAAY;;AAAC,SAAAA,gBAAAC,GAAA,EAAAC,GAAA,EAAAC,KAAA,IAAAD,GAAA,GAAAE,cAAA,CAAAF,GAAA,OAAAA,GAAA,IAAAD,GAAA,IAAAI,MAAA,CAAAC,cAAA,CAAAL,GAAA,EAAAC,GAAA,IAAAC,KAAA,EAAAA,KAAA,EAAAI,UAAA,QAAAC,YAAA,QAAAC,QAAA,oBAAAR,GAAA,CAAAC,GAAA,IAAAC,KAAA,WAAAF,GAAA;AAAA,SAAAG,eAAAM,GAAA,QAAAR,GAAA,GAAAS,YAAA,CAAAD,GAAA,2BAAAR,GAAA,gBAAAA,GAAA,GAAAU,MAAA,CAAAV,GAAA;AAAA,SAAAS,aAAAE,KAAA,EAAAC,IAAA,eAAAD,KAAA,iBAAAA,KAAA,kBAAAA,KAAA,MAAAE,IAAA,GAAAF,KAAA,CAAAG,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