{"_id":"@antonbuks/jitsi-electron-sdk","name":"@antonbuks/jitsi-electron-sdk","dist-tags":{"latest":"1.0.0"},"versions":{"1.0.0":{"name":"@antonbuks/jitsi-electron-sdk","version":"1.0.0","description":"Utilities for jitsi-meet-electron project","main":"index.js","scripts":{"lint":"eslint .","test":"TESTING=true mocha","validate":"npm ls","install":"node-gyp-build","prebuild-darwin-universal":"prebuildify -t 16.0.0 --napi --strip --arch x64+arm64","prebuild-darwin-x64":"prebuildify -t 16.0.0 --napi --strip --arch x64 && lipo -remove arm64 prebuilds/darwin-x64/node.napi.node -output prebuilds/darwin-x64/node.napi.node","prebuild-linux-x64":"prebuildify -t 16.0.0 --napi --strip","prebuild-win32-x86":"prebuildify -t 16.0.0 --napi --strip","prebuild-win32-x64":"prebuildify -t 16.0.0 --napi --strip"},"pre-commit":["lint"],"repository":{"type":"git","url":"git+https://github.com/antonbuks/jitsi-meet-electron-sdk.git"},"keywords":["jingle","webrtc","xmpp","electron","jitsi-meet","utils"],"author":{"name":"antonbuks"},"license":"Apache-2.0","gypfile":true,"binary":{"napi_versions":[3]},"dependencies":{"@jitsi/logger":"^2.0.0","@jitsi/robotjs":"^0.6.9","electron-store":"^8.0.1","node-addon-api":"^4.2.0","node-gyp-build":"^4.3.0","postis":"^2.2.0"},"devDependencies":{"eslint":">=3","eslint-plugin-jsdoc":"*","mocha":"^9.1.3","prebuildify":"^5.0.0","precommit-hook":"3.0.0"},"gitHead":"d93de05f15a72f83c4509a1fa2a4ed1b2792aec5","bugs":{"url":"https://github.com/antonbuks/jitsi-meet-electron-sdk/issues"},"homepage":"https://github.com/antonbuks/jitsi-meet-electron-sdk#readme","_id":"@antonbuks/jitsi-electron-sdk@1.0.0","_nodeVersion":"16.15.0","_npmVersion":"8.5.5","dist":{"integrity":"sha512-KS3nGCUEjdSLm+l4okenmkS5Jjgv1R4pUBI/WjMjkA++bXSRHsK1BeV3ZQCOx6Gyd5ptxS1+AWszUQwt91DGFA==","shasum":"5e61b32d3acc2cc2b8eab700eb68f8db3f65c896","tarball":"https://registry.npmjs.org/@antonbuks/jitsi-electron-sdk/-/jitsi-electron-sdk-1.0.0.tgz","fileCount":58,"unpackedSize":562848,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIB8KQut8RZksRGQVUSyoUQpR/XAr2EBOQmziXFfnQOb+AiAs7QAPyQtPRbyGPQs+o1ABHyhFmaRvMz8otIFjrk7ANA=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJijKwmACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmqWyw/8DVSg595rmKShOtV1xFhIVxNnb5mxxZ8PAFQnEd6h0kRFqXSf\r\nyrs2cPBoVxciCWx+2IxDPakznTx5LwvxmGSZV6biTCdZABl7Vx04LmxDKP6I\r\nXgMrXsrGKCOezpMPcLkykTqZdyEdbMVFSpkSuCpLH6nlEv7Rj65GCIC72tTw\r\nF6TJAh8bAW8O5jznfx7hxYtewJDeZXj0eL3/N7xDqRFCdg+5Z2+Dvlhpa7it\r\ng8vc6C2iwOZn297SQdcOnz0QcAieLFgHekWYW5k23cLM57+Y5THaKIUxJAjv\r\n7yq4+Af87qJ0EpjfhY3SKd1lnYqP8yrd3ubu/lgoHHm9U1khZ6QVnVJM5wbU\r\nvBXDkil0wZgkdI+PqkZcwyXVl4aDMN/9qLdbzh90A9/DR7naviCAjAhd2bXw\r\n4sKT75F2y98JIAchxRPFtyzKairHBdV2b74o6M2hjWiPhhjBNm/WKeJbZwuk\r\nADompyJSAcwWNDcZjSVSMG8lm8W3aNgyWLfyyktMsPe6EC7RsmoP3zh76Fm/\r\nzDGCjcCDVOfqlqW6cjxk43lHPRyXPP7wZmQfYxGXOxFDOTSuqAxMVKNzi2F4\r\nGx5dL3nUwOptZWw03NZL8yOoNP90lCvx63RH8Pb27btzaKhdOWIz9yTPZRpY\r\nQngcmGP+frrYIqP3yFcRXOyBzL6whXH5v2o=\r\n=vWTs\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"antonbks","email":"antonbks@gmail.com"},"directories":{},"maintainers":[{"name":"antonbks","email":"antonbks@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/jitsi-electron-sdk_1.0.0_1653386278072_0.8689568091444386"},"_hasShrinkwrap":false}},"time":{"created":"2022-05-24T09:57:58.003Z","1.0.0":"2022-05-24T09:57:58.289Z","modified":"2022-05-24T09:57:58.430Z"},"maintainers":[{"name":"antonbks","email":"antonbks@gmail.com"}],"description":"Utilities for jitsi-meet-electron project","homepage":"https://github.com/antonbuks/jitsi-meet-electron-sdk#readme","keywords":["jingle","webrtc","xmpp","electron","jitsi-meet","utils"],"repository":{"type":"git","url":"git+https://github.com/antonbuks/jitsi-meet-electron-sdk.git"},"author":{"name":"antonbuks"},"bugs":{"url":"https://github.com/antonbuks/jitsi-meet-electron-sdk/issues"},"license":"Apache-2.0","readme":"# Jitsi Meet Electron SDK\n\nSDK for integrating Jitsi Meet into Electron applications.\n\nSupported Electron versions: >= 11.\n\n## Installation\n\nInstall from npm:\n\n    npm install @jitsi/electron-sdk\n\nNote: This package contains native code for the remote control module. Binary prebuilds are downloaded during install for Windows x64 and ia32, Linux x64 and Mac x64 and arm64.\n\n## Usage\n#### Remote Control\n\n**Requirements**:\nThe remote control utility requires iframe HTML Element that will load Jitsi Meet.\n\n**Enable the remote control:**\n\nIn the **render** electron process of the window where Jitsi Meet is displayed:\n\n```Javascript\nconst {\n    RemoteControl\n} = require(\"@jitsi/electron-sdk\");\n\n// iframe - the Jitsi Meet iframe\nconst remoteControl = new RemoteControl(iframe);\n```\n\nTo disable the remote control:\n```Javascript\nremoteControl.dispose();\n```\n\nNOTE: `dispose` method will be called automatically when the Jitsi Meet iframe unload.\n\nIn the **main** electron process:\n\n```Javascript\nconst {\n    RemoteControlMain\n} = require(\"@jitsi/electron-sdk\");\n\n// jitsiMeetWindow - The BrowserWindow instance of the window where Jitsi Meet is loaded.\nconst remoteControl = new RemoteControlMain(mainWindow);\n```\n\n#### Screen Sharing\n\n**Requirements**:\nThe screen sharing utility requires iframe HTML Element that will load Jitsi Meet.\n\n**Enable the screen sharing:**\n\nIn the **render** electron process of the window where Jitsi Meet is displayed:\n\n```Javascript\nconst {\n    setupScreenSharingRender\n} = require(\"@jitsi/electron-sdk\");\n\n// api - The Jitsi Meet iframe api object.\nsetupScreenSharingRender(api);\n```\nIn the **main** electron process:\n\n```Javascript\nconst {\n    setupScreenSharingMain\n} = require(\"@jitsi/electron-sdk\");\n\n// jitsiMeetWindow - The BrowserWindow instance of the window where Jitsi Meet is loaded.\n// appName - Application name which will be displayed inside the content sharing tracking window\n// i.e. [appName] is sharing your screen.\n// osxBundleId - Mac Application bundleId for which screen capturer permissions will be reset if user denied them.  \nsetupScreenSharingMain(mainWindow, appName, osxBundleId);\n```\n\n\n#### Always On Top\nDisplays a small window with the current active speaker video when the main Jitsi Meet window is not focused.\n\n**Requirements**:\n1. Jitsi Meet should be initialized through our [iframe API](https://github.com/jitsi/jitsi-meet/blob/master/doc/api.md)\n2. The `BrowserWindow` instance where Jitsi Meet is displayed should use the [Chrome's window.open implementation](https://github.com/electron/electron/blob/master/docs/api/window-open.md#using-chromes-windowopen-implementation) (set `nativeWindowOpen` option of `BrowserWindow`'s constructor to `true`).\n3. If you have a custom handler for opening windows you have to filter the always on top window. You can do this by its `frameName` argument which will be set to `AlwaysOnTop`.\n\n**Enable the aways on top:**\n\nIn the **main** electron process:\n```Javascript\nconst {\n    setupAlwaysOnTopMain\n} = require(\"@jitsi/electron-sdk\");\n\n// jitsiMeetWindow - The BrowserWindow instance\n// of the window where Jitsi Meet is loaded.\nsetupAlwaysOnTopMain(jitsiMeetWindow);\n```\n\nIn the **render** electron process of the window where Jitsi Meet is displayed:\n```Javascript\nconst {\n    setupAlwaysOnTopRender\n} = require(\"@jitsi/electron-sdk\");\n\nconst api = new JitsiMeetExternalAPI(...);\nconst alwaysOnTop = setupAlwaysOnTopRender(api);\n\nalwaysOnTop.on('will-close', handleAlwaysOnTopClose);\n```\n\n`setupAlwaysOnTopRender` return an instance of EventEmitter with the following events:\n\n* _dismissed_ - emitted when the always on top window is explicitly dismissed via its close button\n\n* _will-close_ - emitted right before the always on top window is going to close\n\n#### WiFi Stats\nProvides a function to query for wifi stats on the host computer. Returns information like interface name, addresses, signal quality, noise (not available on all OS).\n\n**WiFi Stats:**\n\nIn the **render** electron process of the window where Jitsi Meet is displayed:\n```Javascript\nconst {\n    setupWiFiStats\n} = require(\"@jitsi/electron-sdk\");\n\nconst api = new JitsiMeetExternalAPI(...);\nsetupWiFiStats(api.getIFrame());\n```\n\n#### Power Monitor\nProvides a way to query electron for system idle and receive power monitor events.\n\n**enable power monitor:**\nIn the **main** electron process:\n```Javascript\nconst {\n    setupPowerMonitorMain\n} = require(\"@jitsi/electron-sdk\");\n\n// jitsiMeetWindow - The BrowserWindow instance\n// of the window where Jitsi Meet is loaded.\nsetupPowerMonitorMain(jitsiMeetWindow);\n```\n\nIn the **render** electron process of the window where Jitsi Meet is displayed:\n```Javascript\nconst {\n    setupPowerMonitorRender\n} = require(\"@jitsi/electron-sdk\");\n\nconst api = new JitsiMeetExternalAPI(...);\nsetupPowerMonitorRender(api);\n```\n\n### NOTE:\nYou'll need to add 'disable-site-isolation-trials' switch because of [https://github.com/electron/electron/issues/18214](https://github.com/electron/electron/issues/18214):\n```\napp.commandLine.appendSwitch('disable-site-isolation-trials')\n```\n\n## Example\n\nFor examples of installation and usage checkout the [Jitsi Meet Electron](https://github.com/jitsi/jitsi-meet-electron) project.\n\n## Development\n\nTo rebuild the native code, use:\n\n    npx node-gyp rebuild\n\n## Publishing\n\n1. Create release branch: `git checkout -b release-1-2-3`, replacing 1-2-3 with the desired release version\n2. Increment the version: `npm version patch`, replacing `patch` with `minor` or `major` as required\n3. Push to github: `git push`\n4. Create PR: `gh pr create`\n5. Once PR is merged, create and publish Github release: `gh release create v1.2.3`, replacing v1.2.3 with the desired release version\n7. Github action will prebuildify and publish release to npm\n","readmeFilename":"README.md"}