@100mslive/roomkit-react 0.2.2-alpha.4 → 0.2.2-alpha.6
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/{HLSView-DPM6YJWZ.js → HLSView-U346BIZQ.js} +2 -2
- package/dist/Prebuilt/components/Chat/ChatActions.d.ts +1 -1
- package/dist/Prebuilt/components/Polls/common/utils.d.ts +1 -0
- package/dist/{chunk-S5NNUR2M.js → chunk-DY3FWEXJ.js} +317 -263
- package/dist/{chunk-S5NNUR2M.js.map → chunk-DY3FWEXJ.js.map} +4 -4
- package/dist/index.cjs.js +554 -493
- package/dist/index.cjs.js.map +4 -4
- package/dist/index.js +1 -1
- package/dist/meta.cjs.json +60 -26
- package/dist/meta.esbuild.json +66 -32
- package/package.json +6 -6
- package/src/Prebuilt/common/utils.js +13 -0
- package/src/Prebuilt/components/Chat/ChatActions.tsx +3 -3
- package/src/Prebuilt/components/Chat/ChatBody.tsx +9 -5
- package/src/Prebuilt/components/Polls/Voting/LeaderboardEntry.tsx +3 -2
- package/src/Prebuilt/components/Polls/Voting/PeerParticipationSummary.tsx +4 -3
- package/src/Prebuilt/components/Polls/Voting/QuestionCard.jsx +16 -21
- package/src/Prebuilt/components/Polls/Voting/StatisticBox.tsx +1 -1
- package/src/Prebuilt/components/Polls/Voting/TimedVoting.tsx +31 -20
- package/src/Prebuilt/components/Polls/Voting/Voting.tsx +7 -8
- package/src/Prebuilt/components/Polls/common/MultipleChoiceOptions.jsx +2 -2
- package/src/Prebuilt/components/Polls/common/SingleChoiceOptions.jsx +4 -5
- package/src/Prebuilt/components/Polls/common/utils.ts +16 -0
- /package/dist/{HLSView-DPM6YJWZ.js.map → HLSView-U346BIZQ.js.map} +0 -0
package/dist/index.cjs.js
CHANGED
@@ -108,7 +108,7 @@ var __async = (__this, __arguments, generator) => {
|
|
108
108
|
var define_process_env_default;
|
109
109
|
var init_define_process_env = __esm({
|
110
110
|
"<define:process.env>"() {
|
111
|
-
define_process_env_default = { NVM_INC: "/Users/ravitheja/.nvm/versions/node/v18.17.0/include/node", npm_package_devDependencies_typedoc_plugin_markdown: "^3.14.0", npm_package_devDependencies_lint_staged: "^12.0.3", NX_CLI_SET: "true", npm_package_dependencies_emoji_mart: "^5.2.2", npm_package_devDependencies_rollup_plugin_import_css: "^3.3.1", npm_package_devDependencies__storybook_testing_library: "^0.2.0", npm_package_devDependencies__storybook_addon_links: "^7.0.27", npm_package_scripts_size: "size-limit", npm_package_devDependencies_prettier: "^2.4.1", npm_package_dependencies_react_swipeable: "^7.0.1", npm_package_dependencies__100mslive_types_prebuilt: "0.12.5", npm_package_dependencies__radix_ui_react_tabs: "1.0.0", npm_package_devDependencies_rollup_plugin_terser: "^7.0.2", TERM_PROGRAM: "vscode", npm_package_size_limit_0_limit: "20 KB", npm_package_size_limit_0_path: "packages/hms-video-store/dist/index.cjs.js", npm_package_scripts_prebuilt: "cd packages/roomkit-react && yarn start", NODE: "/Users/ravitheja/.nvm/versions/node/v18.17.0/bin/node", npm_package_dependencies_worker_timers: "^7.0.40", npm_package_scripts_types_build: "tsc -p tsconfig.json", INIT_CWD: "/Users/ravitheja/Documents/web-sdks/examples", NVM_CD_FLAGS: "-q", npm_package_devDependencies_typescript: "~4.7.4", npm_config_version_git_tag: "true", npm_package_devDependencies__rollup_plugin_typescript: "^8.3.1", TERM: "xterm-256color", SHELL: "/bin/zsh", npm_package_devDependencies_jest: "26.6.0", npm_package_dependencies__radix_ui_react_dialog: "1.0.4", npm_package_devDependencies__storybook_react_webpack5: "^7.0.27", npm_package_devDependencies__storybook_addon_essentials: "^7.0.27", npm_package_size_limit_4_limit: "20 KB", npm_package_devDependencies_babel_plugin_istanbul: "^6.1.1", npm_package_dependencies_eventemitter2: "^6.4.9", npm_package_dependencies__radix_ui_react_toast: "1.0.0", TMPDIR: "/var/folders/_k/lv0n3xdx0n9c5c6nzjvb629r0000gn/T/", npm_package_devDependencies_esbuild: "^0.18.13", npm_package_dependencies_react_virtualized_auto_sizer: "^1.0.7", npm_package_dependencies__100mslive_react_icons: "0.9.2-alpha.4", npm_package_size_limit_6_limit: "150 KB", npm_package_scripts_store: "cd packages/hms-video-store && yarn start", npm_package_scripts_lint: "eslint -c .eslintrc --no-error-on-unmatched-pattern src --ext .js --ext .jsx --ext .ts --ext .tsx", npm_config_init_license: "MIT", npm_package_devDependencies__babel_preset_typescript: "^7.22.5", TERM_PROGRAM_VERSION: "1.85.2", npm_package_devDependencies_concurrently: "^6.4.0", npm_package_dependencies_screenfull: "^5.1.0", npm_package_scripts_ybys: "yarn && yarn build --no-private && yarn storybook", npm_package_dependencies_react_intersection_observer: "^9.4.3", npm_package_scripts_dev: "node ../../scripts/dev", npm_package_scripts_prestart: "rm -rf dist && yarn types:build", ZDOTDIR: "/Users/ravitheja", ORIGINAL_XDG_CURRENT_DESKTOP: "undefined", MallocNanoZone: "0", npm_package_dependencies_uuid: "^8.3.2", npm_package_private: "true", npm_config_registry: "https://registry.yarnpkg.com", npm_package_dependencies__radix_ui_react_select: "1.0.0", npm_package_devDependencies__storybook_addon_interactions: "^7.0.27", npm_package_sideEffects: "false", ZSH: "/Users/ravitheja/.oh-my-zsh", npm_package_devDependencies_size_limit: "^5.0.3", npm_package_repository_url: "https://github.com/100mslive/web-sdks.git", npm_package_readmeFilename: "README.md", NVM_DIR: "/Users/ravitheja/.nvm", USER: "ravitheja", npm_package_description: "100ms Room Kit provides simple & easy to use UI components to build Live Streaming & Video Conferencing experiences in your apps.", npm_package_devDependencies_react: "^18.1.0", npm_package_license: "MIT", npm_package_devDependencies_dotenv: "^14.2.0", npm_package_devDependencies__types_react: "^18.1.0", COMMAND_MODE: "unix2003", npm_package_lint_staged____js_ts_jsx_tsx_: "eslint", npm_package_scripts_build_storybook: "sb build", npm_package_devDependencies_postcss_loader: "^6.2.1", npm_package_dependencies__radix_ui_react_tooltip: "1.0.6", npm_package_exports___import: "./dist/index.js", npm_package_devDependencies_babel_jest: "^26.6.0", npm_package_devDependencies__babel_core: "^7.18.2", NX_TASK_HASH: "2cac5cbb6f8b3a94641136a9fb8d9d96ac69e3cf6ddd3f3ae9754eeb6d618fbc", npm_package_repository_directory: "packages/roomkit-react", SSH_AUTH_SOCK: "/private/tmp/com.apple.launchd.5lUeYdLBIu/Listeners", npm_package_devDependencies_esbuild_plugin_postcss2: "0.1.1", npm_package_devDependencies_esbuild_loader: "^4.0.2", npm_package_devDependencies_babel_loader: "^8.2.5", npm_package_devDependencies__storybook_addon_actions: "^7.0.27", npm_package_devDependencies__rollup_plugin_commonjs: "^21.0.3", __CF_USER_TEXT_ENCODING: "0x1F5:0x0:0x0", npm_package_devDependencies_postcss: "^8.4.5", npm_package_devDependencies_eslint_plugin_simple_import_sort: "^8.0.0", npm_package_devDependencies_eslint: "^8.9.0", npm_package_devDependencies__types_jest: "^27.0.3", npm_execpath: "/usr/local/Cellar/yarn/1.22.19/libexec/bin/yarn.js", npm_package_size_limit_5_path: "packages/hms-virtual-background/dist/index.js", npm_package_devDependencies_tslib: "^2.2.0", npm_package_devDependencies__typescript_eslint_eslint_plugin: "^5.4.0", PAGER: "less", npm_package_module: "dist/index.js", npm_package_dependencies_react_use: "^17.4.0", npm_package_devDependencies__types_mdx: "2.0.2", npm_package_devDependencies__rollup_plugin_json: "^6.0.0", npm_package_author_name: "100ms", LSCOLORS: "Gxfxcxdxbxegedabagacad", npm_package_devDependencies_eslint_plugin_prettier: "^4.0.0", npm_package_dependencies__stitches_react: "^1.2.8", npm_package_size_limit_1_path: "packages/hms-video-store/dist/index.js", npm_package_devDependencies__typescript_eslint_parser: "^5.4.0", NX_TASK_TARGET_PROJECT: "@100mslive/roomkit-react", PATH: "/var/folders/_k/lv0n3xdx0n9c5c6nzjvb629r0000gn/T/yarn--1706079013181-0.1639248454412272:/Users/ravitheja/Documents/web-sdks/packages/roomkit-react/node_modules/.bin:/Users/ravitheja/.config/yarn/link/node_modules/.bin:/Users/ravitheja/Documents/web-sdks/node_modules/.bin:/Users/ravitheja/.nvm/versions/node/v18.17.0/libexec/lib/node_modules/npm/bin/node-gyp-bin:/Users/ravitheja/.nvm/versions/node/v18.17.0/lib/node_modules/npm/bin/node-gyp-bin:/Users/ravitheja/.nvm/versions/node/v18.17.0/bin/node_modules/npm/bin/node-gyp-bin:/var/folders/_k/lv0n3xdx0n9c5c6nzjvb629r0000gn/T/yarn--1706079012682-0.5987315984824728:/Users/ravitheja/Documents/web-sdks/packages/roomkit-react/node_modules/.bin:/Users/ravitheja/.config/yarn/link/node_modules/.bin:/Users/ravitheja/Documents/web-sdks/node_modules/.bin:/Users/ravitheja/.nvm/versions/node/v18.17.0/libexec/lib/node_modules/npm/bin/node-gyp-bin:/Users/ravitheja/.nvm/versions/node/v18.17.0/lib/node_modules/npm/bin/node-gyp-bin:/Users/ravitheja/.nvm/versions/node/v18.17.0/bin/node_modules/npm/bin/node-gyp-bin:/var/folders/_k/lv0n3xdx0n9c5c6nzjvb629r0000gn/T/yarn--1706078992416-0.16177324076315092:/Users/ravitheja/Documents/web-sdks/node_modules/.bin:/Users/ravitheja/.config/yarn/link/node_modules/.bin:/Users/ravitheja/Documents/web-sdks/node_modules/.bin:/Users/ravitheja/.nvm/versions/node/v18.17.0/libexec/lib/node_modules/npm/bin/node-gyp-bin:/Users/ravitheja/.nvm/versions/node/v18.17.0/lib/node_modules/npm/bin/node-gyp-bin:/Users/ravitheja/.nvm/versions/node/v18.17.0/bin/node_modules/npm/bin/node-gyp-bin:/Users/ravitheja/.nvm/versions/node/v18.17.0/bin:/usr/local/bin:/System/Cryptexes/App/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin:/Library/Apple/usr/bin:/Applications/Wireshark.app/Contents/MacOS:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/local/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/appleinternal/bin:/Users/ravitheja/.nvm/versions/node/v18.17.0/bin:/Users/ravitheja/.cargo/bin", npm_config_argv: '{"remain":[],"cooked":["run","build"],"original":["build","--no-private"]}', npm_package_scripts_postinstall: "husky install && lerna bootstrap", npm_package_scripts_lint_fix: "yarn lint --fix", npm_package_dependencies__emoji_mart_react: "^1.0.1", npm_package_size_limit_7_path: "packages/react-icons/dist/index.js", npm_package_size_limit_5_limit: "20 KB", npm_package_devDependencies_typedoc: "^0.24.8", npm_package_devDependencies_nx: "^14.5.1", npm_config_workspaces_experimental: "true", npm_package_dependencies__radix_ui_react_switch: "1.0.0", npm_package_devDependencies_rollup: "^2.70.1", _: "/var/folders/_k/lv0n3xdx0n9c5c6nzjvb629r0000gn/T/yarn--1706079013181-0.1639248454412272/node", npm_package_size_limit_4_path: "packages/hms-virtual-background/dist/index.cjs.js", NX_WORKSPACE_ROOT: "/Users/ravitheja/Documents/web-sdks", npm_package_dependencies__radix_ui_react_progress: "1.0.0", USER_ZDOTDIR: "/Users/ravitheja", __CFBundleIdentifier: "com.microsoft.VSCode", npm_package_size_limit_7_limit: "100 KB", npm_package_scripts_lerna_publish: "lerna publish from-package --dist-tag $PUBLISH_FLAG --yes --no-verify-access", npm_package_devDependencies_ts_jest: "26.5.6", PWD: "/Users/ravitheja/Documents/web-sdks/packages/roomkit-react", npm_package_devDependencies_cypress: "^9.5.2", npm_package_devDependencies__types_react_window: "^1.8.5", npm_package_devDependencies__rollup_plugin_node_resolve: "^13.1.3", npm_package_dependencies__100mslive_react_sdk: "0.9.2-alpha.4", npm_package_devDependencies__storybook_cli: "^7.0.27", npm_lifecycle_event: "build:only", npm_package_scripts_build_only: "rm -rf dist && node ../../scripts/build-webapp", LANG: "en_US.UTF-8", npm_package_name: "@100mslive/roomkit-react", npm_package_repository_type: "git", npm_package_keywords_0: "100mslive", npm_package_size_limit_2_limit: "400 KB", npm_package_dependencies__100mslive_hms_virtual_background: "1.12.2-alpha.4", npm_package_devDependencies__babel_preset_react: "^7.22.5", npm_package_devDependencies__babel_preset_env: "^7.22.5", npm_package_keywords_1: "react", npm_package_resolutions_loader_utils: "^2.0.4", npm_package_scripts_controller: "cd packages/hls-controller && yarn start", npm_package_scripts_build: "yarn build:only && yarn types:build", npm_package_scripts_start: 'concurrently "yarn dev" "yarn types"', npm_config_version_commit_hooks: "true", npm_package_devDependencies_babel_plugin_react_require: "3.1.3", npm_package_keywords_2: "prebuilt", VSCODE_GIT_ASKPASS_EXTRA_ARGS: "--ms-enable-electron-run-as-node", XPC_FLAGS: "0x0", npm_package_keywords_3: "roomkit", npm_package_devDependencies_eslint_config_react_app: "^7.0.0", npm_config_bin_links: "true", npm_package_engines_node: ">=16", FORCE_COLOR: "true", npm_package_devDependencies__storybook_react: "^7.0.27", npm_config_wrap_output: "", npm_package_scripts_cypress_open: "cypress open", npm_package_dependencies__radix_ui_react_collapsible: "1.0.0", npm_package_main: "dist/index.cjs.js", XPC_SERVICE_NAME: "0", npm_package_version: "0.2.2-alpha.4", npm_package_dependencies_recordrtc: "^5.6.2", VSCODE_INJECTION: "1", SHLVL: "5", HOME: "/Users/ravitheja", npm_package_devDependencies__size_limit_file: "^5.0.3", npm_package_dependencies_react_window: "^1.8.7", VSCODE_GIT_ASKPASS_MAIN: "/Applications/Visual Studio Code.app/Contents/Resources/app/extensions/git/dist/askpass-main.js", npm_package_scripts_storybook: "sb dev -p 6006", npm_package_scripts_test: "yarn build --no-private && lerna run test", npm_package_source: "src/index.ts", npm_config_save_prefix: "^", npm_config_strict_ssl: "true", npm_package_dependencies_lodash_merge: "^4.6.2", npm_package_dependencies__100mslive_hls_player: "0.2.2-alpha.4", npm_package_devDependencies_husky: "^6.0.0", npm_package_devDependencies__commitlint_cli: "^15.0.0", npm_config_version_git_message: "v%s", npm_package_dependencies__radix_ui_react_accordion: "1.0.0", npm_package_dependencies__emoji_mart_data: "^1.0.6", npm_package_dependencies__radix_ui_react_popover: "1.0.6", npm_package_size_limit_3_path: "packages/roomkit-react/dist/index.js", npm_package_devDependencies_ts_node: "^10.4.0", npm_package_exports___default: "./dist/index.js", LESS: "-R", LOGNAME: "ravitheja", YARN_WRAP_OUTPUT: "false", npm_package_scripts_format: "prettier -w src/**", npm_package_dependencies_qrcode_react: "^3.1.0", npm_package_devDependencies__types_lodash_merge: "^4.6.6", npm_package_devDependencies__rollup_plugin_image: "^3.0.2", npm_package_typings: "dist/index.d.ts", PREFIX: "/usr/local", npm_lifecycle_script: "rm -rf dist && node ../../scripts/build-webapp", npm_package_exports___require: "./dist/index.cjs.js", VSCODE_GIT_IPC_HANDLE: "/var/folders/_k/lv0n3xdx0n9c5c6nzjvb629r0000gn/T/vscode-git-4dbfa2fdda.sock", npm_package_size_limit_6_path: "packages/react-icons/dist/index.cjs.js", npm_package_dependencies__radix_ui_react_slider: "1.0.0", npm_package_dependencies__radix_ui_react_checkbox: "1.0.0", npm_package_peerDependencies_react: ">=17.0.2 <19.0.0", npm_package_scripts_babel: "npx storybook@latest babelrc", NVM_BIN: "/Users/ravitheja/.nvm/versions/node/v18.17.0/bin", LERNA_PACKAGE_NAME: "@100mslive/roomkit-react", npm_config_version_git_sign: "", npm_config_ignore_scripts: "", npm_config_user_agent: "yarn/1.22.19 npm/? node/v18.17.0 darwin x64", npm_package_dependencies__radix_ui_react_label: "1.0.0", VSCODE_GIT_ASKPASS_NODE: "/Applications/Visual Studio Code.app/Contents/Frameworks/Code Helper (Plugin).app/Contents/MacOS/Code Helper (Plugin)", GIT_ASKPASS: "/Applications/Visual Studio Code.app/Contents/Resources/app/extensions/git/dist/askpass.sh", npm_package_size_limit_2_path: "packages/roomkit-react/dist/index.cjs.js", npm_package_scripts_reactsdk: "cd packages/react-sdk && yarn start", npm_package_devDependencies__types_node: "^16.11.17", npm_package_dependencies__radix_ui_react_dropdown_menu: "2.0.5", npm_package_devDependencies_rollup_plugin_esbuild: "^5.0.0", npm_package_devDependencies__storybook_addon_a11y: "^7.0.27", npm_package_scripts_types: "tsc -w", npm_package_size_limit_1_limit: "20 KB", npm_package_devDependencies_lerna: "^5.6.2", npm_package_files_1: "src", npm_package_devDependencies_storybook_dark_mode: "^3.0.0", npm_package_files_0: "dist", npm_package_size_limit_3_limit: "20 KB", npm_config_init_version: "1.0.0", npm_config_ignore_optional: "", npm_package_devDependencies__commitlint_config_conventional: "^15.0.0", npm_package_workspaces_0: "packages/*", npm_package_dependencies_react_draggable: "^4.4.5", COLORTERM: "truecolor", npm_node_execpath: "/Users/ravitheja/.nvm/versions/node/v18.17.0/bin/node", npm_package_workspaces_1: "examples/*", npm_config_version_tag_prefix: "v", npm_package_dependencies__radix_ui_react_radio_group: "1.0.0", REACT_APP_TILE_SHAPE: "16-9", REACT_APP_THEME: "dark", REACT_APP_COLOR: "#FF0000", REACT_APP_LOGO: "", REACT_APP_FONT: "Roboto", REACT_APP_SHOW_CHAT: "true", REACT_APP_SHOW_SCREENSHARE: "true", REACT_APP_VIDEO_AVATAR: "true", REACT_APP_TOKEN_GENERATION_ENDPOINT: "https://qa-in2.100ms.live/hmsapi/hrashi-studystream.qa-app.100ms.live/", REACT_APP_ENV: "qa", REACT_APP_LOGROCKET_ID: "<Your Logrocket project ID>", REACT_APP_POLICY_CONFIG: "", REACT_APP_WEBINAR_PROPS: "{}", REACT_APP_ENABLE_STATS_FOR_NERDS: "true", REACT_APP_AUDIO_PLAYLIST: '[{"name":"Audio1","id":"audio1","metadata":{"description":"Artist1"},"url":"https://d2qi07yyjujoxr.cloudfront.net/webapp/playlist/audio1.mp3","type":"audio"},{"name":"Audio2","id":"audio2","metadata":{"description":"Artist2"},"url":"https://d2qi07yyjujoxr.cloudfront.net/webapp/playlist/audio2.mp3","type":"audio"},{"name":"Audio3","id":"audio3","metadata":{"description":"Artist3"},"url":"https://d2qi07yyjujoxr.cloudfront.net/webapp/playlist/audio3.mp3","type":"audio"},{"name":"Audio4","id":"audio4","metadata":{"description":"Artist4"},"url":"https://d2qi07yyjujoxr.cloudfront.net/webapp/playlist/audio4.mp3","type":"audio"},{"name":"Audio5","id":"audio5","metadata":{"description":"Artist5"},"url":"https://d2qi07yyjujoxr.cloudfront.net/webapp/playlist/audio5.mp3","type":"audio"},{"name":"Audio6","id":"audio6","metadata":{"description":"Artist6"},"url":"https://d2qi07yyjujoxr.cloudfront.net/webapp/playlist/audio6.mp3","type":"audio"}]', REACT_APP_VIDEO_PLAYLIST: '[{"name":"Video1","id":"video1","url":"https://d2qi07yyjujoxr.cloudfront.net/webapp/playlist/video1.mp4","type":"video"}]', REACT_APP_HOST_NAME: "ravi.qa-app.100ms.live", REACT_APP_DEFAULT_APP_DETAILS: '{"headlessConfig":{"uiMode":"activespeaker","hideAudioLevel":true,"hideTileAudioMute":true}}', REACT_APP_TOKEN_GENERATION_ENDPOINT_DOMAIN: "ravi.qa-app.100ms.live", REACT_APP_ZIPY_KEY: "", REACT_APP_PUSHER_APP_KEY: "4ae6f78bb2b7f2d9ed11", REACT_APP_PUSHER_AUTHENDPOINT: "https://whiteboard-server.vercel.app/api/pusher/auth", REACT_APP_ENABLE_WHITEBOARD: "true", REACT_APP_TRANSCRIPTION_ROOM_ID: "644df1027cebfa471fcc52fd", STORYBOOK_ROOM_LAYOUT_ENDPOINT: "https://api-nonprod.100ms.live/v2/layouts/ui", STORYBOOK_TOKEN_BY_ROOM_CODE_ENDPOINT: "https://auth-nonprod.100ms.live/v2/token", STORYBOOK_INIT_API_ENDPOINT: "https://qa-init.100ms.live/init", STORYBOOK_SAMPLE_ROOM_CODE: "dkz-teqx-wap" };
|
111
|
+
define_process_env_default = { GITHUB_STATE: "/home/runner/work/_temp/_runner_file_commands/save_state_1c9b8f07-72cd-4449-bf50-0ca387bbfe35", npm_package_devDependencies_ts_node: "^10.4.0", npm_package_devDependencies__types_node: "^16.11.17", npm_package_devDependencies_rollup: "^2.70.1", npm_package_exports___require: "./dist/index.cjs.js", STATS_TRP: "true", DEPLOYMENT_BASEPATH: "/opt/runner", DOTNET_NOLOGO: "1", npm_package_dependencies_screenfull: "^5.1.0", npm_package_dependencies_react_draggable: "^4.4.5", npm_package_dependencies__radix_ui_react_switch: "1.0.0", USER: "runner", npm_package_devDependencies_jest: "26.6.0", npm_config_version_commit_hooks: "true", npm_config_user_agent: "yarn/1.22.21 npm/? node/v18.19.0 linux x64", npm_config_always_auth: "", NX_WORKSPACE_ROOT: "/home/runner/work/web-sdks/web-sdks", npm_package_devDependencies__rollup_plugin_node_resolve: "^13.1.3", npm_package_scripts_babel: "npx storybook@latest babelrc", CI: "true", npm_package_devDependencies__size_limit_file: "^5.0.3", npm_config_bin_links: "true", npm_config_wrap_output: "", npm_package_dependencies__radix_ui_react_tabs: "1.0.0", npm_package_dependencies__100mslive_react_sdk: "0.9.2-alpha.6", RUNNER_ENVIRONMENT: "github-hosted", GITHUB_ENV: "/home/runner/work/_temp/_runner_file_commands/set_env_1c9b8f07-72cd-4449-bf50-0ca387bbfe35", PIPX_HOME: "/opt/pipx", npm_node_execpath: "/opt/hostedtoolcache/node/18.19.0/x64/bin/node", npm_config_init_version: "1.0.0", npm_package_dependencies__emoji_mart_react: "^1.0.1", npm_package_dependencies__emoji_mart_data: "^1.0.6", npm_package_dependencies__100mslive_hms_virtual_background: "1.12.2-alpha.6", JAVA_HOME_8_X64: "/usr/lib/jvm/temurin-8-jdk-amd64", NODE_AUTH_TOKEN: "XXXXX-XXXXX-XXXXX-XXXXX", SHLVL: "1", npm_package_dependencies__radix_ui_react_tooltip: "1.0.6", npm_package_dependencies__radix_ui_react_popover: "1.0.6", npm_package_dependencies__100mslive_types_prebuilt: "0.12.5", npm_package_peerDependencies_react: ">=17.0.2 <19.0.0", npm_package_devDependencies__storybook_addon_links: "^7.0.27", npm_package_files_0: "dist", HOME: "/home/runner", npm_package_devDependencies__typescript_eslint_parser: "^5.4.0", npm_package_dependencies__radix_ui_react_dialog: "1.0.4", npm_package_devDependencies__types_react_window: "^1.8.5", npm_package_files_1: "src", npm_package_repository_directory: "packages/roomkit-react", RUNNER_TEMP: "/home/runner/work/_temp", GITHUB_EVENT_PATH: "/home/runner/work/_temp/_github_workflow/event.json", npm_package_scripts_controller: "cd packages/hls-controller && yarn start", npm_package_dependencies__stitches_react: "^1.2.8", JAVA_HOME_11_X64: "/usr/lib/jvm/temurin-11-jdk-amd64", PIPX_BIN_DIR: "/opt/pipx_bin", GITHUB_REPOSITORY_OWNER: "100mslive", npm_package_engines_node: ">=16", npm_package_devDependencies_typedoc_plugin_markdown: "^3.14.0", npm_config_init_license: "MIT", GRADLE_HOME: "/usr/share/gradle-8.5", ANDROID_NDK_LATEST_HOME: "/usr/local/lib/android/sdk/ndk/26.1.10909125", JAVA_HOME_21_X64: "/usr/lib/jvm/temurin-21-jdk-amd64", STATS_RDCL: "true", GITHUB_RETENTION_DAYS: "90", YARN_WRAP_OUTPUT: "false", npm_config_version_tag_prefix: "v", GITHUB_REPOSITORY_OWNER_ID: "73883131", POWERSHELL_DISTRIBUTION_CHANNEL: "GitHub-Actions-ubuntu22", AZURE_EXTENSION_DIR: "/opt/az/azcliextensions", GITHUB_HEAD_REF: "", npm_package_scripts_lint_fix: "yarn lint --fix", npm_config_userconfig: "/home/runner/work/_temp/.npmrc", npm_package_devDependencies__storybook_addon_a11y: "^7.0.27", SYSTEMD_EXEC_PID: "602", npm_package_scripts_postinstall: "husky install && lerna bootstrap", npm_package_devDependencies_husky: "^6.0.0", npm_package_dependencies_recordrtc: "^5.6.2", npm_package_dependencies_eventemitter2: "^6.4.9", npm_package_dependencies__radix_ui_react_label: "1.0.0", npm_package_dependencies__radix_ui_react_dropdown_menu: "2.0.5", npm_package_keywords_0: "100mslive", GITHUB_GRAPHQL_URL: "https://api.github.com/graphql", npm_package_description: "100ms Room Kit provides simple & easy to use UI components to build Live Streaming & Video Conferencing experiences in your apps.", npm_package_devDependencies_typescript: "~4.7.4", npm_package_devDependencies_typedoc: "^0.24.8", npm_package_devDependencies_babel_loader: "^8.2.5", npm_package_devDependencies__rollup_plugin_image: "^3.0.2", npm_package_keywords_1: "react", GOROOT_1_20_X64: "/opt/hostedtoolcache/go/1.20.13/x64", NVM_DIR: "/home/runner/.nvm", npm_package_readmeFilename: "README.md", npm_package_devDependencies_react: "^18.1.0", npm_package_devDependencies__babel_preset_env: "^7.22.5", npm_package_keywords_2: "prebuilt", DOTNET_SKIP_FIRST_TIME_EXPERIENCE: "1", GOROOT_1_21_X64: "/opt/hostedtoolcache/go/1.21.6/x64", JAVA_HOME_17_X64: "/usr/lib/jvm/temurin-17-jdk-amd64", ImageVersion: "20240122.3.0", npm_package_devDependencies_prettier: "^2.4.1", npm_package_devDependencies_babel_jest: "^26.6.0", npm_package_scripts_dev: "node ../../scripts/dev", npm_package_keywords_3: "roomkit", RUNNER_OS: "Linux", GITHUB_API_URL: "https://api.github.com", SWIFT_PATH: "/usr/share/swift/usr/bin", FORCE_COLOR: "true", npm_package_dependencies__radix_ui_react_toast: "1.0.0", npm_package_dependencies__radix_ui_react_radio_group: "1.0.0", npm_package_devDependencies__babel_preset_typescript: "^7.22.5", npm_package_exports___default: "./dist/index.js", RUNNER_USER: "runner", STATS_V3PS: "true", CHROMEWEBDRIVER: "/usr/local/share/chromedriver-linux64", JOURNAL_STREAM: "8:18737", GITHUB_WORKFLOW: "Publish Packages", _: "/usr/local/bin/yarn", npm_package_devDependencies_ts_jest: "26.5.6", npm_package_devDependencies_lerna: "^5.6.2", npm_package_devDependencies__types_jest: "^27.0.3", npm_package_devDependencies__commitlint_config_conventional: "^15.0.0", npm_package_private: "true", npm_package_dependencies__radix_ui_react_accordion: "1.0.0", npm_package_devDependencies__rollup_plugin_commonjs: "^21.0.3", npm_package_devDependencies__babel_preset_react: "^7.22.5", npm_package_module: "dist/index.js", npm_package_scripts_lint: "eslint -c .eslintrc --no-error-on-unmatched-pattern src --ext .js --ext .jsx --ext .ts --ext .tsx", npm_package_devDependencies__typescript_eslint_eslint_plugin: "^5.4.0", npm_config_registry: "https://registry.yarnpkg.com", npm_package_dependencies_react_window: "^1.8.7", npm_package_dependencies__100mslive_hls_player: "0.2.2-alpha.6", npm_package_devDependencies__types_lodash_merge: "^4.6.6", npm_package_devDependencies__storybook_cli: "^7.0.27", npm_package_devDependencies__rollup_plugin_json: "^6.0.0", ACTIONS_RUNNER_ACTION_ARCHIVE_CACHE: "/opt/actionarchivecache", GITHUB_RUN_ID: "7653355023", npm_package_workspaces_0: "packages/*", npm_package_scripts_store: "cd packages/hms-video-store && yarn start", npm_package_devDependencies__babel_core: "^7.18.2", npm_package_devDependencies__storybook_addon_interactions: "^7.0.27", npm_package_devDependencies__storybook_addon_actions: "^7.0.27", GITHUB_REF_TYPE: "branch", BOOTSTRAP_HASKELL_NONINTERACTIVE: "1", GITHUB_WORKFLOW_SHA: "6398566b05595e4d9ab9c6b293142a657933eb15", GITHUB_BASE_REF: "", ImageOS: "ubuntu22", npm_package_workspaces_1: "examples/*", npm_package_scripts_start: 'concurrently "yarn dev" "yarn types"', npm_config_ignore_scripts: "", NX_TASK_HASH: "e96a6dbeb622aa275c62fd98df0475ad1b1ff49c17c77f84ee8ad5c24f40035d", npm_package_exports___import: "./dist/index.js", GITHUB_WORKFLOW_REF: "100mslive/web-sdks/.github/workflows/publish.yml@refs/heads/publish-alpha", PERFLOG_LOCATION_SETTING: "RUNNER_PERFLOG", GITHUB_ACTION_REPOSITORY: "", npm_package_scripts_prebuilt: "cd packages/roomkit-react && yarn start", npm_package_devDependencies_postcss_loader: "^6.2.1", npm_package_devDependencies_esbuild_loader: "^4.0.2", PATH: "/tmp/yarn--1706179561305-0.5559343089129356:/home/runner/work/web-sdks/web-sdks/packages/roomkit-react/node_modules/.bin:/home/runner/.config/yarn/link/node_modules/.bin:/home/runner/work/web-sdks/web-sdks/node_modules/.bin:/opt/hostedtoolcache/node/18.19.0/x64/libexec/lib/node_modules/npm/bin/node-gyp-bin:/opt/hostedtoolcache/node/18.19.0/x64/lib/node_modules/npm/bin/node-gyp-bin:/opt/hostedtoolcache/node/18.19.0/x64/bin/node_modules/npm/bin/node-gyp-bin:/tmp/yarn--1706179561108-0.329559105644069:/home/runner/work/web-sdks/web-sdks/packages/roomkit-react/node_modules/.bin:/home/runner/.config/yarn/link/node_modules/.bin:/home/runner/work/web-sdks/web-sdks/node_modules/.bin:/opt/hostedtoolcache/node/18.19.0/x64/libexec/lib/node_modules/npm/bin/node-gyp-bin:/opt/hostedtoolcache/node/18.19.0/x64/lib/node_modules/npm/bin/node-gyp-bin:/opt/hostedtoolcache/node/18.19.0/x64/bin/node_modules/npm/bin/node-gyp-bin:/tmp/yarn--1706179539127-0.40070722217174426:/home/runner/work/web-sdks/web-sdks/node_modules/.bin:/home/runner/.config/yarn/link/node_modules/.bin:/home/runner/work/web-sdks/web-sdks/node_modules/.bin:/opt/hostedtoolcache/node/18.19.0/x64/libexec/lib/node_modules/npm/bin/node-gyp-bin:/opt/hostedtoolcache/node/18.19.0/x64/lib/node_modules/npm/bin/node-gyp-bin:/opt/hostedtoolcache/node/18.19.0/x64/bin/node_modules/npm/bin/node-gyp-bin:/tmp/yarn--1706179538951-0.7560126397977354:/home/runner/work/web-sdks/web-sdks/node_modules/.bin:/home/runner/.config/yarn/link/node_modules/.bin:/home/runner/work/web-sdks/web-sdks/node_modules/.bin:/opt/hostedtoolcache/node/18.19.0/x64/libexec/lib/node_modules/npm/bin/node-gyp-bin:/opt/hostedtoolcache/node/18.19.0/x64/lib/node_modules/npm/bin/node-gyp-bin:/opt/hostedtoolcache/node/18.19.0/x64/bin/node_modules/npm/bin/node-gyp-bin:/opt/hostedtoolcache/node/18.19.0/x64/bin:/snap/bin:/home/runner/.local/bin:/opt/pipx_bin:/home/runner/.cargo/bin:/home/runner/.config/composer/vendor/bin:/usr/local/.ghcup/bin:/home/runner/.dotnet/tools:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin", NODE: "/opt/hostedtoolcache/node/18.19.0/x64/bin/node", ANT_HOME: "/usr/share/ant", DOTNET_MULTILEVEL_LOOKUP: "0", RUNNER_TRACKING_ID: "github_f76ebfa3-e445-4f40-afeb-fdd57785c70f", INVOCATION_ID: "f27fb32fb8ad496990075e88082579fc", NPM_CONFIG_USERCONFIG: "/home/runner/work/_temp/.npmrc", RUNNER_TOOL_CACHE: "/opt/hostedtoolcache", GOROOT_1_19_X64: "/opt/hostedtoolcache/go/1.19.13/x64", npm_package_scripts_size: "size-limit", npm_package_devDependencies_size_limit: "^5.0.3", npm_package_name: "@100mslive/roomkit-react", npm_package_devDependencies__storybook_react_webpack5: "^7.0.27", npm_package_repository_type: "git", GITHUB_ACTION: "__run_3", GITHUB_RUN_NUMBER: "415", GITHUB_TRIGGERING_ACTOR: "KaustubhKumar05", RUNNER_ARCH: "X64", XDG_RUNTIME_DIR: "/run/user/1001", AGENT_TOOLSDIRECTORY: "/opt/hostedtoolcache", npm_package_lint_staged____js_ts_jsx_tsx_: "eslint", npm_package_devDependencies_babel_plugin_istanbul: "^6.1.1", LERNA_PACKAGE_NAME: "@100mslive/roomkit-react", npm_package_dependencies__radix_ui_react_select: "1.0.0", npm_package_size_limit_0_limit: "20 KB", npm_package_devDependencies__commitlint_cli: "^15.0.0", npm_package_devDependencies__rollup_plugin_typescript: "^8.3.1", LANG: "C.UTF-8", VCPKG_INSTALLATION_ROOT: "/usr/local/share/vcpkg", npm_package_size_limit_1_limit: "20 KB", npm_package_devDependencies_eslint_plugin_simple_import_sort: "^8.0.0", npm_package_devDependencies_eslint: "^8.9.0", npm_package_dependencies_react_intersection_observer: "^9.4.3", npm_package_devDependencies_rollup_plugin_terser: "^7.0.2", npm_package_devDependencies__types_mdx: "2.0.2", CONDA: "/usr/share/miniconda", RUNNER_NAME: "GitHub Actions 191", XDG_CONFIG_HOME: "/home/runner/.config", STATS_VMD: "true", GITHUB_REF_NAME: "publish-alpha", GITHUB_REPOSITORY: "100mslive/web-sdks", npm_lifecycle_script: "rm -rf dist && node ../../scripts/build-webapp", npm_package_size_limit_2_limit: "400 KB", npm_package_resolutions_loader_utils: "^2.0.4", npm_package_devDependencies_dotenv: "^14.2.0", npm_package_dependencies__radix_ui_react_slider: "1.0.0", npm_package_devDependencies_rollup_plugin_import_css: "^3.3.1", npm_package_scripts_types_build: "tsc -p tsconfig.json", npm_package_main: "dist/index.cjs.js", STATS_UE: "true", ANDROID_NDK_ROOT: "/usr/local/lib/android/sdk/ndk/25.2.9519653", GITHUB_ACTION_REF: "", DEBIAN_FRONTEND: "noninteractive", npm_package_size_limit_3_limit: "20 KB", npm_package_size_limit_0_path: "packages/hms-video-store/dist/index.cjs.js", npm_package_scripts_cypress_open: "cypress open", npm_package_scripts_lerna_publish: "lerna publish from-package --dist-tag $PUBLISH_FLAG --yes --no-verify-access", npm_package_scripts_test: "yarn build --no-private && lerna run test", npm_package_devDependencies_concurrently: "^6.4.0", npm_config_version_git_message: "v%s", npm_package_dependencies__radix_ui_react_checkbox: "1.0.0", npm_package_dependencies__100mslive_react_icons: "0.9.2-alpha.6", npm_package_scripts_types: "tsc -w", GITHUB_REPOSITORY_ID: "429826515", GITHUB_ACTIONS: "true", npm_lifecycle_event: "build:only", npm_package_version: "0.2.2-alpha.6", npm_package_size_limit_4_limit: "20 KB", npm_package_size_limit_1_path: "packages/hms-video-store/dist/index.js", npm_package_scripts_build_only: "rm -rf dist && node ../../scripts/build-webapp", npm_package_devDependencies__types_react: "^18.1.0", npm_package_sideEffects: "false", npm_package_repository_url: "https://github.com/100mslive/web-sdks.git", npm_package_source: "src/index.ts", GITHUB_REF_PROTECTED: "false", npm_config_argv: '{"remain":[],"cooked":["run","test"],"original":["test"]}', npm_package_size_limit_5_limit: "20 KB", npm_package_size_limit_2_path: "packages/roomkit-react/dist/index.cjs.js", npm_package_scripts_build: "yarn build:only && yarn types:build", npm_package_devDependencies_tslib: "^2.2.0", npm_package_devDependencies_nx: "^14.5.1", npm_package_devDependencies_lint_staged: "^12.0.3", NX_CLI_SET: "true", npm_package_dependencies_uuid: "^8.3.2", npm_package_dependencies_react_virtualized_auto_sizer: "^1.0.7", npm_package_dependencies_lodash_merge: "^4.6.2", npm_package_dependencies_emoji_mart: "^5.2.2", GITHUB_WORKSPACE: "/home/runner/work/web-sdks/web-sdks", ACCEPT_EULA: "Y", GITHUB_JOB: "publish_packages", RUNNER_PERFLOG: "/home/runner/perflog", npm_package_size_limit_6_limit: "150 KB", npm_package_size_limit_3_path: "packages/roomkit-react/dist/index.js", npm_package_devDependencies_cypress: "^9.5.2", npm_package_devDependencies_rollup_plugin_esbuild: "^5.0.0", GITHUB_SHA: "6398566b05595e4d9ab9c6b293142a657933eb15", GITHUB_RUN_ATTEMPT: "1", npm_package_size_limit_7_limit: "100 KB", npm_package_size_limit_4_path: "packages/hms-virtual-background/dist/index.cjs.js", npm_config_version_git_tag: "true", npm_config_version_git_sign: "", npm_package_dependencies_qrcode_react: "^3.1.0", GITHUB_REF: "refs/heads/publish-alpha", GITHUB_ACTOR: "KaustubhKumar05", ANDROID_SDK_ROOT: "/usr/local/lib/android/sdk", npm_package_license: "MIT", npm_package_size_limit_5_path: "packages/hms-virtual-background/dist/index.js", npm_config_strict_ssl: "true", LEIN_HOME: "/usr/local/lib/lein", npm_package_size_limit_6_path: "packages/react-icons/dist/index.cjs.js", npm_package_scripts_format: "prettier -w src/**", npm_package_devDependencies_eslint_plugin_prettier: "^4.0.0", npm_package_devDependencies_eslint_config_react_app: "^7.0.0", NX_TASK_TARGET_PROJECT: "@100mslive/roomkit-react", GITHUB_PATH: "/home/runner/work/_temp/_runner_file_commands/add_path_1c9b8f07-72cd-4449-bf50-0ca387bbfe35", JAVA_HOME: "/usr/lib/jvm/temurin-11-jdk-amd64", PWD: "/home/runner/work/web-sdks/web-sdks/packages/roomkit-react", GITHUB_ACTOR_ID: "57426646", RUNNER_WORKSPACE: "/home/runner/work/web-sdks", npm_execpath: "/usr/local/lib/node_modules/yarn/bin/yarn.js", npm_package_size_limit_7_path: "packages/react-icons/dist/index.js", npm_package_scripts_ybys: "yarn && yarn build --no-private && yarn storybook", npm_package_dependencies__radix_ui_react_progress: "1.0.0", HOMEBREW_CLEANUP_PERIODIC_FULL_DAYS: "3650", STATS_TIS: "mining", GITHUB_EVENT_NAME: "workflow_dispatch", HOMEBREW_NO_AUTO_UPDATE: "1", ANDROID_HOME: "/usr/local/lib/android/sdk", GITHUB_SERVER_URL: "https://github.com", GECKOWEBDRIVER: "/usr/local/share/gecko_driver", LEIN_JAR: "/usr/local/lib/lein/self-installs/leiningen-2.10.0-standalone.jar", GHCUP_INSTALL_BASE_PREFIX: "/usr/local", GITHUB_OUTPUT: "/home/runner/work/_temp/_runner_file_commands/set_output_1c9b8f07-72cd-4449-bf50-0ca387bbfe35", npm_package_scripts_prestart: "rm -rf dist && yarn types:build", npm_package_author_name: "100ms", EDGEWEBDRIVER: "/usr/local/share/edge_driver", STATS_EXT: "true", npm_package_scripts_build_storybook: "sb build", npm_package_devDependencies_postcss: "^8.4.5", npm_package_devDependencies_esbuild: "^0.18.13", npm_config_save_prefix: "^", npm_config_ignore_optional: "", npm_package_dependencies_worker_timers: "^7.0.40", npm_package_typings: "dist/index.d.ts", ANDROID_NDK: "/usr/local/lib/android/sdk/ndk/25.2.9519653", SGX_AESM_ADDR: "1", CHROME_BIN: "/usr/bin/google-chrome", npm_package_scripts_storybook: "sb dev -p 6006", npm_package_devDependencies_esbuild_plugin_postcss2: "0.1.1", npm_package_dependencies_react_swipeable: "^7.0.1", npm_package_devDependencies_babel_plugin_react_require: "3.1.3", npm_package_devDependencies__storybook_testing_library: "^0.2.0", npm_package_devDependencies__storybook_addon_essentials: "^7.0.27", SELENIUM_JAR_PATH: "/usr/share/java/selenium-server.jar", STATS_EXTP: "https://provjobdsettingscdn.blob.core.windows.net/settings/provjobdsettings-0.5.154/provjobd.data", npm_package_scripts_reactsdk: "cd packages/react-sdk && yarn start", npm_package_dependencies_react_use: "^17.4.0", npm_package_dependencies__radix_ui_react_collapsible: "1.0.0", npm_package_devDependencies_storybook_dark_mode: "^3.0.0", npm_package_devDependencies__storybook_react: "^7.0.27", INIT_CWD: "/home/runner/work/web-sdks/web-sdks", ANDROID_NDK_HOME: "/usr/local/lib/android/sdk/ndk/25.2.9519653", GITHUB_STEP_SUMMARY: "/home/runner/work/_temp/_runner_file_commands/step_summary_1c9b8f07-72cd-4449-bf50-0ca387bbfe35" };
|
112
112
|
}
|
113
113
|
});
|
114
114
|
|
@@ -18321,7 +18321,7 @@ var init_dist = __esm({
|
|
18321
18321
|
};
|
18322
18322
|
ya = (a2, e) => () => (e || a2((e = { exports: {} }).exports, e), e.exports);
|
18323
18323
|
nr = ya((jc, Va) => {
|
18324
|
-
Va.exports = { version: "0.11.2-alpha.
|
18324
|
+
Va.exports = { version: "0.11.2-alpha.6", license: "MIT", repository: { type: "git", url: "https://github.com/100mslive/web-sdks.git", directory: "packages/hms-video-store" }, main: "dist/index.cjs.js", module: "dist/index.js", typings: "dist/index.d.ts", files: ["dist", "src"], engines: { node: ">=12" }, exports: { ".": { require: "./dist/index.cjs.js", import: "./dist/index.js", default: "./dist/index.js" } }, sideEffects: false, scripts: { prestart: "rm -rf dist && yarn types:build", start: 'concurrently "yarn dev" "yarn types"', dev: "node ../../scripts/dev", "build:only": "node ../../scripts/build", build: "yarn build:only && yarn types:build", types: "tsc -w", "types:build": "tsc -p tsconfig.json", format: "prettier --write src/**/*.ts", test: "jest --maxWorkers=1", "test:watch": "jest --watch", "test:coverage": "jest --coverage", lint: "eslint -c ../../.eslintrc .", "lint:fix": "yarn lint --fix", prepare: "yarn build", size: "size-limit", analyze: "size-limit --why", docs: "rm -rf ./docs && typedoc && rm -f ./docs/README.md && mkdir ./docs/home &&mv ./docs/modules.md ./docs/home/content.md && node ../../scripts/docs-store && npx prettier --write './docs/**/*'" }, name: "@100mslive/hms-video-store", author: "100ms", dependencies: { eventemitter2: "^6.4.9", immer: "^9.0.6", reselect: "4.0.0", "sdp-transform": "^2.14.1", "ua-parser-js": "^1.0.1", uuid: "^8.3.2", "webrtc-adapter": "^8.0.0", zustand: "3.5.7" }, devDependencies: { "@types/dom-screen-wake-lock": "^1.0.1", "@types/sdp-transform": "^2.4.4", "@types/ua-parser-js": "^0.7.36", "@types/uuid": "^8.3.0", "jest-canvas-mock": "^2.3.1", "jsdom-worker": "^0.3.0", tslib: "^2.2.0" }, description: "@100mslive Core SDK which abstracts the complexities of webRTC while providing a reactive store for data management with a unidirectional data flow", keywords: ["video", "webrtc", "conferencing", "100ms"] };
|
18325
18325
|
});
|
18326
18326
|
zi = ((n) => (n.Disconnected = "Disconnected", n.Preview = "Preview", n.Connecting = "Connecting", n.Connected = "Connected", n.Reconnecting = "Reconnecting", n.Disconnecting = "Disconnecting", n.Failed = "Failed", n))(zi || {});
|
18327
18327
|
ka = ((e) => (e.CHAT = "chat", e))(ka || {});
|
@@ -19480,7 +19480,7 @@ var init_AdditionalRoomState = __esm({
|
|
19480
19480
|
});
|
19481
19481
|
|
19482
19482
|
// src/Prebuilt/common/utils.js
|
19483
|
-
var getMetadata, isScreenshareSupported, getFormattedCount, formatTime, compareArrays, checkCorrectAnswer, isValidTextInput, calculateAvatarAndAttribBoxSize, isMobileUserAgent;
|
19483
|
+
var getMetadata, isScreenshareSupported, getFormattedCount, formatTime, compareArrays, checkCorrectAnswer, isValidTextInput, calculateAvatarAndAttribBoxSize, isMobileUserAgent, getPeerResponses, getLastAttemptedIndex;
|
19484
19484
|
var init_utils3 = __esm({
|
19485
19485
|
"src/Prebuilt/common/utils.js"() {
|
19486
19486
|
"use strict";
|
@@ -19547,6 +19547,28 @@ var init_utils3 = __esm({
|
|
19547
19547
|
return [avatarSize, attribBoxSize];
|
19548
19548
|
};
|
19549
19549
|
isMobileUserAgent = /Mobi|Android|iPhone/i.test(navigator.userAgent);
|
19550
|
+
getPeerResponses = (questions, peerid, userid) => {
|
19551
|
+
return questions.map(
|
19552
|
+
(question) => {
|
19553
|
+
var _a8;
|
19554
|
+
return (_a8 = question.responses) == null ? void 0 : _a8.filter(
|
19555
|
+
(response) => {
|
19556
|
+
var _a9, _b7;
|
19557
|
+
return (response && ((_a9 = response.peer) == null ? void 0 : _a9.peerid) === peerid || ((_b7 = response.peer) == null ? void 0 : _b7.userid) === userid) && !response.skipped;
|
19558
|
+
}
|
19559
|
+
);
|
19560
|
+
}
|
19561
|
+
);
|
19562
|
+
};
|
19563
|
+
getLastAttemptedIndex = (questions, peerid, userid = "") => {
|
19564
|
+
const peerResponses = getPeerResponses(questions, peerid, userid) || [];
|
19565
|
+
for (let i = 0; i < peerResponses.length; i++) {
|
19566
|
+
if (peerResponses[i] === void 0 || peerResponses[i].length === 0) {
|
19567
|
+
return i + 1;
|
19568
|
+
}
|
19569
|
+
}
|
19570
|
+
return questions.length + 1;
|
19571
|
+
};
|
19550
19572
|
}
|
19551
19573
|
});
|
19552
19574
|
|
@@ -22444,12 +22466,12 @@ var init_MultipleChoiceOptions = __esm({
|
|
22444
22466
|
}
|
22445
22467
|
},
|
22446
22468
|
/* @__PURE__ */ import_react104.default.createElement(Checkbox.Indicator, null, /* @__PURE__ */ import_react104.default.createElement(import_react_icons50.CheckIcon, { width: 16, height: 16 }))
|
22447
|
-
) : null, isStopped && (correctOptionIndexes == null ? void 0 : correctOptionIndexes.includes(option.index)) ? /* @__PURE__ */ import_react104.default.createElement(Flex, { css: { color: "$on_surface_high" } }, /* @__PURE__ */ import_react104.default.createElement(import_react_icons50.CheckCircleIcon,
|
22469
|
+
) : null, isStopped && (correctOptionIndexes == null ? void 0 : correctOptionIndexes.includes(option.index)) ? /* @__PURE__ */ import_react104.default.createElement(Flex, { css: { color: "$on_surface_high" } }, /* @__PURE__ */ import_react104.default.createElement(import_react_icons50.CheckCircleIcon, { height: 20, width: 20 })) : null, /* @__PURE__ */ import_react104.default.createElement(Flex, { direction: "column", css: { flexGrow: "1" } }, /* @__PURE__ */ import_react104.default.createElement(Flex, { css: { w: "100%" } }, /* @__PURE__ */ import_react104.default.createElement(Text, { css: { display: "flex", flexGrow: "1" } }, /* @__PURE__ */ import_react104.default.createElement(Label3, { htmlFor: `${questionIndex}-${option.index}` }, option.text)), showVoteCount && /* @__PURE__ */ import_react104.default.createElement(VoteCount, { voteCount: option.voteCount })), showVoteCount && /* @__PURE__ */ import_react104.default.createElement(VoteProgress, { option, totalResponses })), isStopped && isQuiz && (localPeerResponse == null ? void 0 : localPeerResponse.options.includes(option.index)) ? /* @__PURE__ */ import_react104.default.createElement(Text, { variant: "sm", css: { color: "$on_surface_medium", maxWidth: "max-content" } }, "Your Answer") : null);
|
22448
22470
|
}));
|
22449
22471
|
};
|
22450
22472
|
MultipleChoiceOptionInputs = ({ isQuiz, options, selectAnswer, handleOptionTextChange, removeOption }) => {
|
22451
22473
|
return /* @__PURE__ */ import_react104.default.createElement(Flex, { direction: "column", css: { gap: "$md", w: "100%", mb: "$md" } }, options.map((option, index) => {
|
22452
|
-
return /* @__PURE__ */ import_react104.default.createElement(Flex, { align: "center", key: index, css: { w: "100%", gap: "$
|
22474
|
+
return /* @__PURE__ */ import_react104.default.createElement(Flex, { align: "center", key: index, css: { w: "100%", gap: "$4" } }, isQuiz && /* @__PURE__ */ import_react104.default.createElement(
|
22453
22475
|
Checkbox.Root,
|
22454
22476
|
{
|
22455
22477
|
onCheckedChange: (checked) => selectAnswer(checked, index),
|
@@ -22496,11 +22518,10 @@ var init_SingleChoiceOptions = __esm({
|
|
22496
22518
|
correctOptionIndex,
|
22497
22519
|
isStopped,
|
22498
22520
|
isQuiz,
|
22499
|
-
localPeerResponse
|
22500
|
-
answer
|
22521
|
+
localPeerResponse
|
22501
22522
|
}) => {
|
22502
|
-
return /* @__PURE__ */ import_react105.default.createElement(RadioGroup.Root, { value:
|
22503
|
-
return /* @__PURE__ */ import_react105.default.createElement(Flex, { align: "start", key: `${questionIndex}-${option.index}`, css: { w: "100%", gap: "$
|
22523
|
+
return /* @__PURE__ */ import_react105.default.createElement(RadioGroup.Root, { value: localPeerResponse == null ? void 0 : localPeerResponse.option, onValueChange: (value) => setAnswer(value) }, /* @__PURE__ */ import_react105.default.createElement(Flex, { direction: "column", css: { gap: "$md", w: "100%", mb: "$md" } }, options.map((option) => {
|
22524
|
+
return /* @__PURE__ */ import_react105.default.createElement(Flex, { align: "start", key: `${questionIndex}-${option.index}`, css: { w: "100%", gap: "$4" } }, !isStopped || !isQuiz ? /* @__PURE__ */ import_react105.default.createElement(
|
22504
22525
|
RadioGroup.Item,
|
22505
22526
|
{
|
22506
22527
|
css: {
|
@@ -22533,13 +22554,13 @@ var init_SingleChoiceOptions = __esm({
|
|
22533
22554
|
}
|
22534
22555
|
}
|
22535
22556
|
)
|
22536
|
-
) : null, isStopped && correctOptionIndex === option.index && isQuiz ? /* @__PURE__ */ import_react105.default.createElement(Flex, { css: { color: "$on_surface_high" } }, /* @__PURE__ */ import_react105.default.createElement(import_react_icons51.CheckCircleIcon,
|
22557
|
+
) : null, isStopped && correctOptionIndex === option.index && isQuiz ? /* @__PURE__ */ import_react105.default.createElement(Flex, { css: { color: "$on_surface_high" } }, /* @__PURE__ */ import_react105.default.createElement(import_react_icons51.CheckCircleIcon, { height: 20, width: 20 })) : null, /* @__PURE__ */ import_react105.default.createElement(Flex, { direction: "column", css: { flexGrow: "1" } }, /* @__PURE__ */ import_react105.default.createElement(Flex, { css: { w: "100%" } }, /* @__PURE__ */ import_react105.default.createElement(Text, { css: { display: "flex", flexGrow: "1", color: "$on_surface_high" } }, /* @__PURE__ */ import_react105.default.createElement(Label3, { style: { color: "inherit" }, htmlFor: `${questionIndex}-${option.index}` }, option.text)), showVoteCount && /* @__PURE__ */ import_react105.default.createElement(VoteCount, { voteCount: option.voteCount })), showVoteCount && /* @__PURE__ */ import_react105.default.createElement(VoteProgress, { option, totalResponses })), isStopped && isQuiz && (localPeerResponse == null ? void 0 : localPeerResponse.option) === option.index ? /* @__PURE__ */ import_react105.default.createElement(Text, { variant: "sm", css: { color: "$on_surface_medium", maxWidth: "max-content" } }, "Your Answer") : null);
|
22537
22558
|
})));
|
22538
22559
|
};
|
22539
22560
|
SingleChoiceOptionInputs = ({ isQuiz, options, selectAnswer, handleOptionTextChange, removeOption }) => {
|
22540
22561
|
const correctOptionIndex = options.findIndex((option) => option.isCorrectAnswer);
|
22541
22562
|
return /* @__PURE__ */ import_react105.default.createElement(RadioGroup.Root, { value: correctOptionIndex, onValueChange: selectAnswer }, /* @__PURE__ */ import_react105.default.createElement(Flex, { direction: "column", css: { gap: "$md", w: "100%", mb: "$md" } }, options.map((option, index) => {
|
22542
|
-
return /* @__PURE__ */ import_react105.default.createElement(Flex, { align: "center", key: `option-${index}`, css: { w: "100%", gap: "$
|
22563
|
+
return /* @__PURE__ */ import_react105.default.createElement(Flex, { align: "center", key: `option-${index}`, css: { w: "100%", gap: "$4" } }, isQuiz && /* @__PURE__ */ import_react105.default.createElement(
|
22543
22564
|
RadioGroup.Item,
|
22544
22565
|
{
|
22545
22566
|
css: {
|
@@ -22980,6 +23001,29 @@ var init_CreateQuestions = __esm({
|
|
22980
23001
|
}
|
22981
23002
|
});
|
22982
23003
|
|
23004
|
+
// src/Prebuilt/components/Polls/common/utils.ts
|
23005
|
+
var getFormattedTime;
|
23006
|
+
var init_utils4 = __esm({
|
23007
|
+
"src/Prebuilt/components/Polls/common/utils.ts"() {
|
23008
|
+
"use strict";
|
23009
|
+
init_define_process_env();
|
23010
|
+
getFormattedTime = (milliseconds) => {
|
23011
|
+
if (!milliseconds)
|
23012
|
+
return "-";
|
23013
|
+
const totalSeconds = milliseconds / 1e3;
|
23014
|
+
const minutes = Math.floor(totalSeconds / 60);
|
23015
|
+
const seconds = totalSeconds % 60;
|
23016
|
+
let formattedSeconds = "";
|
23017
|
+
if (Number.isInteger(seconds) || minutes) {
|
23018
|
+
formattedSeconds = seconds.toFixed(0);
|
23019
|
+
} else {
|
23020
|
+
formattedSeconds = seconds.toFixed(1);
|
23021
|
+
}
|
23022
|
+
return `${minutes ? `${minutes}m ` : ""}${formattedSeconds}s`;
|
23023
|
+
};
|
23024
|
+
}
|
23025
|
+
});
|
23026
|
+
|
22983
23027
|
// src/Prebuilt/components/Polls/Voting/LeaderboardEntry.tsx
|
22984
23028
|
var import_react109, import_react_icons55, positionColorMap, LeaderboardEntry;
|
22985
23029
|
var init_LeaderboardEntry = __esm({
|
@@ -22990,6 +23034,7 @@ var init_LeaderboardEntry = __esm({
|
|
22990
23034
|
import_react_icons55 = require("@100mslive/react-icons");
|
22991
23035
|
init_Layout();
|
22992
23036
|
init_Text2();
|
23037
|
+
init_utils4();
|
22993
23038
|
positionColorMap = { 1: "#D69516", 2: "#3E3E3E", 3: "#583B0F" };
|
22994
23039
|
LeaderboardEntry = ({
|
22995
23040
|
position,
|
@@ -23000,7 +23045,7 @@ var init_LeaderboardEntry = __esm({
|
|
23000
23045
|
maxPossibleScore,
|
23001
23046
|
duration
|
23002
23047
|
}) => {
|
23003
|
-
return /* @__PURE__ */ import_react109.default.createElement(Flex, { align: "center", justify: "between", css: { my: "$
|
23048
|
+
return /* @__PURE__ */ import_react109.default.createElement(Flex, { align: "center", justify: "between", css: { my: "$8" } }, /* @__PURE__ */ import_react109.default.createElement(Flex, { align: "center", css: { gap: "$6" } }, /* @__PURE__ */ import_react109.default.createElement(
|
23004
23049
|
Flex,
|
23005
23050
|
{
|
23006
23051
|
align: "center",
|
@@ -23016,7 +23061,7 @@ var init_LeaderboardEntry = __esm({
|
|
23016
23061
|
}
|
23017
23062
|
},
|
23018
23063
|
position
|
23019
|
-
), /* @__PURE__ */ import_react109.default.createElement(Box, null, /* @__PURE__ */ import_react109.default.createElement(Text, { variant: "sm", css: { fontWeight: "$semiBold", color: "$on_surface_high" } }, userName), /* @__PURE__ */ import_react109.default.createElement(Text, { variant: "sm", css: { mt: "$1" } }, score, " / ", maxPossibleScore, " points"))), /* @__PURE__ */ import_react109.default.createElement(Flex, { align: "center", css: { gap: "$4", color: "$on_surface_medium" } }, position === 1 ? /* @__PURE__ */ import_react109.default.createElement(import_react_icons55.TrophyFilledIcon, { height: 16, width: 16 }) : null, questionCount ? /* @__PURE__ */ import_react109.default.createElement(import_react109.default.Fragment, null, /* @__PURE__ */ import_react109.default.createElement(import_react_icons55.CheckCircleIcon, { height: 16, width: 16 }), /* @__PURE__ */ import_react109.default.createElement(Text, { variant: "xs" }, correctResponses, "/", questionCount)) : null, duration ? /* @__PURE__ */ import_react109.default.createElement(Flex, { align: "center", css: { gap: "$2", color: "$on_surface_medium" } }, /* @__PURE__ */ import_react109.default.createElement(import_react_icons55.ClockIcon, { height: 16, width: 16 }), /* @__PURE__ */ import_react109.default.createElement(Text, { variant: "xs" }, (duration
|
23064
|
+
), /* @__PURE__ */ import_react109.default.createElement(Box, null, /* @__PURE__ */ import_react109.default.createElement(Text, { variant: "sm", css: { fontWeight: "$semiBold", color: "$on_surface_high" } }, userName), /* @__PURE__ */ import_react109.default.createElement(Text, { variant: "sm", css: { mt: "$1" } }, score, " / ", maxPossibleScore, " points"))), /* @__PURE__ */ import_react109.default.createElement(Flex, { align: "center", css: { gap: "$4", color: "$on_surface_medium" } }, position === 1 ? /* @__PURE__ */ import_react109.default.createElement(import_react_icons55.TrophyFilledIcon, { height: 16, width: 16 }) : null, questionCount ? /* @__PURE__ */ import_react109.default.createElement(import_react109.default.Fragment, null, /* @__PURE__ */ import_react109.default.createElement(import_react_icons55.CheckCircleIcon, { height: 16, width: 16 }), /* @__PURE__ */ import_react109.default.createElement(Text, { variant: "xs" }, correctResponses, "/", questionCount)) : null, duration ? /* @__PURE__ */ import_react109.default.createElement(Flex, { align: "center", css: { gap: "$2", color: "$on_surface_medium" } }, /* @__PURE__ */ import_react109.default.createElement(import_react_icons55.ClockIcon, { height: 16, width: 16 }), /* @__PURE__ */ import_react109.default.createElement(Text, { variant: "xs" }, getFormattedTime(duration))) : null));
|
23020
23065
|
};
|
23021
23066
|
}
|
23022
23067
|
});
|
@@ -23031,7 +23076,7 @@ var init_StatisticBox = __esm({
|
|
23031
23076
|
init_Layout();
|
23032
23077
|
init_Text2();
|
23033
23078
|
StatisticBox = ({ title, value = 0 }) => {
|
23034
|
-
if (!value) {
|
23079
|
+
if (!value && !(typeof value === "number")) {
|
23035
23080
|
return /* @__PURE__ */ import_react110.default.createElement(import_react110.default.Fragment, null);
|
23036
23081
|
}
|
23037
23082
|
return /* @__PURE__ */ import_react110.default.createElement(Box, { css: { p: "$8", background: "$surface_default", borderRadius: "$1", w: "100%" } }, /* @__PURE__ */ import_react110.default.createElement(
|
@@ -23105,6 +23150,7 @@ var init_PeerParticipationSummary = __esm({
|
|
23105
23150
|
init_Text2();
|
23106
23151
|
init_StatisticBox();
|
23107
23152
|
init_useQuizSummary();
|
23153
|
+
init_utils4();
|
23108
23154
|
PeerParticipationSummary = ({ quiz }) => {
|
23109
23155
|
const localPeerId = (0, import_react_sdk50.useHMSStore)(import_react_sdk50.selectLocalPeerID);
|
23110
23156
|
const { quizLeaderboard, summary } = useQuizSummary(quiz.id);
|
@@ -23126,16 +23172,16 @@ var init_PeerParticipationSummary = __esm({
|
|
23126
23172
|
value: `${summary.totalUsers ? (100 * summary.correctUsers / summary.totalUsers).toFixed(0) : 0}% (${summary.correctUsers}/${summary.totalUsers})`
|
23127
23173
|
},
|
23128
23174
|
// Time in ms
|
23129
|
-
{ title: "Avg. Time Taken", value:
|
23175
|
+
{ title: "Avg. Time Taken", value: getFormattedTime(summary.avgTime) },
|
23130
23176
|
{
|
23131
23177
|
title: "Avg. Score",
|
23132
23178
|
value: Number.isInteger(summary.avgScore) ? summary.avgScore : summary.avgScore.toFixed(2)
|
23133
23179
|
}
|
23134
23180
|
] : [
|
23135
23181
|
{ title: "Your rank", value: (peerEntry == null ? void 0 : peerEntry.position) || "-" },
|
23136
|
-
{ title: "Points", value: peerEntry == null ? void 0 : peerEntry.score },
|
23182
|
+
{ title: "Points", value: (peerEntry == null ? void 0 : peerEntry.score) || 0 },
|
23137
23183
|
// Time in ms
|
23138
|
-
{ title: "Time Taken", value:
|
23184
|
+
{ title: "Time Taken", value: getFormattedTime(peerEntry == null ? void 0 : peerEntry.duration) },
|
23139
23185
|
{
|
23140
23186
|
title: "Correct Answers",
|
23141
23187
|
value: (peerEntry == null ? void 0 : peerEntry.totalResponses) ? `${peerEntry == null ? void 0 : peerEntry.correctResponses}/${peerEntry.totalResponses}` : "-"
|
@@ -23309,10 +23355,6 @@ var init_QuestionCard = __esm({
|
|
23309
23355
|
}
|
23310
23356
|
]);
|
23311
23357
|
startTime.current = Date.now();
|
23312
|
-
if (isQuiz && index !== totalQuestions) {
|
23313
|
-
setSingleOptionAnswer(void 0);
|
23314
|
-
setMultipleOptionAnswer(/* @__PURE__ */ new Set());
|
23315
|
-
}
|
23316
23358
|
}), [
|
23317
23359
|
isValidVote,
|
23318
23360
|
actions.interactivityCenter,
|
@@ -23346,8 +23388,8 @@ var init_QuestionCard = __esm({
|
|
23346
23388
|
gap: "$4"
|
23347
23389
|
}
|
23348
23390
|
},
|
23349
|
-
respondedToQuiz && isCorrectAnswer && pollEnded ? /* @__PURE__ */ import_react114.default.createElement(import_react_icons57.CheckCircleIcon, { height:
|
23350
|
-
respondedToQuiz && !isCorrectAnswer && pollEnded ? /* @__PURE__ */ import_react114.default.createElement(import_react_icons57.CrossCircleIcon, { height:
|
23391
|
+
respondedToQuiz && isCorrectAnswer && pollEnded ? /* @__PURE__ */ import_react114.default.createElement(import_react_icons57.CheckCircleIcon, { height: 16, width: 16 }) : null,
|
23392
|
+
respondedToQuiz && !isCorrectAnswer && pollEnded ? /* @__PURE__ */ import_react114.default.createElement(import_react_icons57.CrossCircleIcon, { height: 16, width: 16 }) : null,
|
23351
23393
|
"QUESTION ",
|
23352
23394
|
index,
|
23353
23395
|
" OF ",
|
@@ -23368,38 +23410,45 @@ var init_QuestionCard = __esm({
|
|
23368
23410
|
}
|
23369
23411
|
)
|
23370
23412
|
)),
|
23371
|
-
/* @__PURE__ */ import_react114.default.createElement(
|
23372
|
-
|
23373
|
-
{
|
23374
|
-
key: index,
|
23375
|
-
questionIndex: index,
|
23376
|
-
isQuiz,
|
23377
|
-
canRespond,
|
23378
|
-
correctOptionIndex: answer == null ? void 0 : answer.option,
|
23379
|
-
options,
|
23380
|
-
setAnswer: setSingleOptionAnswer,
|
23381
|
-
totalResponses: result == null ? void 0 : result.totalResponses,
|
23382
|
-
showVoteCount,
|
23383
|
-
localPeerResponse,
|
23384
|
-
isStopped: pollState === "stopped",
|
23385
|
-
answer: singleOptionAnswer
|
23386
|
-
}
|
23387
|
-
) : null, type === "multiple-choice" /* MULTIPLE_CHOICE */ ? /* @__PURE__ */ import_react114.default.createElement(
|
23388
|
-
MultipleChoiceOptions,
|
23413
|
+
/* @__PURE__ */ import_react114.default.createElement(
|
23414
|
+
Box,
|
23389
23415
|
{
|
23390
|
-
|
23391
|
-
|
23392
|
-
|
23393
|
-
|
23394
|
-
|
23395
|
-
|
23396
|
-
|
23397
|
-
|
23398
|
-
|
23399
|
-
|
23400
|
-
|
23401
|
-
|
23402
|
-
|
23416
|
+
css: { maxHeight: showOptions ? "$80" : "0", transition: "max-height 0.3s ease", overflowY: "auto", mb: "$4" }
|
23417
|
+
},
|
23418
|
+
type === "single-choice" /* SINGLE_CHOICE */ ? /* @__PURE__ */ import_react114.default.createElement(
|
23419
|
+
SingleChoiceOptions,
|
23420
|
+
{
|
23421
|
+
key: index,
|
23422
|
+
questionIndex: index,
|
23423
|
+
isQuiz,
|
23424
|
+
canRespond,
|
23425
|
+
correctOptionIndex: answer == null ? void 0 : answer.option,
|
23426
|
+
options,
|
23427
|
+
setAnswer: setSingleOptionAnswer,
|
23428
|
+
totalResponses: result == null ? void 0 : result.totalResponses,
|
23429
|
+
showVoteCount,
|
23430
|
+
localPeerResponse,
|
23431
|
+
isStopped: pollState === "stopped"
|
23432
|
+
}
|
23433
|
+
) : null,
|
23434
|
+
type === "multiple-choice" /* MULTIPLE_CHOICE */ ? /* @__PURE__ */ import_react114.default.createElement(
|
23435
|
+
MultipleChoiceOptions,
|
23436
|
+
{
|
23437
|
+
questionIndex: index,
|
23438
|
+
isQuiz,
|
23439
|
+
canRespond,
|
23440
|
+
correctOptionIndexes: answer == null ? void 0 : answer.options,
|
23441
|
+
options,
|
23442
|
+
selectedOptions: multipleOptionAnswer,
|
23443
|
+
setSelectedOptions: setMultipleOptionAnswer,
|
23444
|
+
totalResponses: result == null ? void 0 : result.totalResponses,
|
23445
|
+
showVoteCount,
|
23446
|
+
localPeerResponse,
|
23447
|
+
isStopped: pollState === "stopped"
|
23448
|
+
}
|
23449
|
+
) : null
|
23450
|
+
),
|
23451
|
+
isLive && /* @__PURE__ */ import_react114.default.createElement(
|
23403
23452
|
QuestionActions,
|
23404
23453
|
{
|
23405
23454
|
isValidVote,
|
@@ -23410,7 +23459,7 @@ var init_QuestionCard = __esm({
|
|
23410
23459
|
setCurrentIndex((curr) => Math.min(totalQuestions, curr + 1));
|
23411
23460
|
}
|
23412
23461
|
}
|
23413
|
-
)
|
23462
|
+
)
|
23414
23463
|
);
|
23415
23464
|
};
|
23416
23465
|
QuestionActions = ({ isValidVote, response, isQuiz, onVote, incrementIndex }) => {
|
@@ -23476,51 +23525,60 @@ var init_StandardVoting = __esm({
|
|
23476
23525
|
});
|
23477
23526
|
|
23478
23527
|
// src/Prebuilt/components/Polls/Voting/TimedVoting.tsx
|
23479
|
-
var import_react116, TimedView;
|
23528
|
+
var import_react116, import_react_sdk53, TimedView;
|
23480
23529
|
var init_TimedVoting = __esm({
|
23481
23530
|
"src/Prebuilt/components/Polls/Voting/TimedVoting.tsx"() {
|
23482
23531
|
"use strict";
|
23483
23532
|
init_define_process_env();
|
23484
23533
|
import_react116 = __toESM(require("react"));
|
23534
|
+
import_react_sdk53 = require("@100mslive/react-sdk");
|
23485
23535
|
init_QuestionCard();
|
23536
|
+
init_utils3();
|
23486
23537
|
TimedView = ({ poll }) => {
|
23487
|
-
var _a8, _b7;
|
23488
|
-
const
|
23538
|
+
var _a8, _b7, _c;
|
23539
|
+
const localPeerId = (0, import_react_sdk53.useHMSStore)(import_react_sdk53.selectLocalPeerID);
|
23540
|
+
const lastAttemptedIndex = getLastAttemptedIndex(poll.questions, localPeerId, "");
|
23541
|
+
const [currentIndex, setCurrentIndex] = (0, import_react116.useState)(lastAttemptedIndex);
|
23489
23542
|
const activeQuestion = (_a8 = poll.questions) == null ? void 0 : _a8.find((question) => question.index === currentIndex);
|
23490
|
-
|
23543
|
+
const attemptedAll = ((_b7 = poll.questions) == null ? void 0 : _b7.length) === lastAttemptedIndex - 1;
|
23544
|
+
if (!activeQuestion || !((_c = poll.questions) == null ? void 0 : _c.length)) {
|
23491
23545
|
return null;
|
23492
23546
|
}
|
23493
|
-
return /* @__PURE__ */ import_react116.default.createElement(
|
23494
|
-
|
23495
|
-
|
23496
|
-
|
23497
|
-
|
23498
|
-
|
23499
|
-
|
23500
|
-
|
23501
|
-
|
23502
|
-
|
23503
|
-
|
23504
|
-
|
23505
|
-
|
23506
|
-
|
23507
|
-
|
23508
|
-
|
23509
|
-
|
23510
|
-
|
23511
|
-
|
23547
|
+
return /* @__PURE__ */ import_react116.default.createElement(import_react116.default.Fragment, null, poll.questions.map((question) => {
|
23548
|
+
var _a9;
|
23549
|
+
return attemptedAll || activeQuestion.index === question.index ? /* @__PURE__ */ import_react116.default.createElement(
|
23550
|
+
QuestionCard2,
|
23551
|
+
{
|
23552
|
+
key: question.index,
|
23553
|
+
pollID: poll.id,
|
23554
|
+
isQuiz: poll.type === "quiz",
|
23555
|
+
startedBy: poll.startedBy,
|
23556
|
+
pollState: poll.state,
|
23557
|
+
index: question.index,
|
23558
|
+
text: question.text,
|
23559
|
+
type: question.type,
|
23560
|
+
result: question == null ? void 0 : question.result,
|
23561
|
+
totalQuestions: ((_a9 = poll.questions) == null ? void 0 : _a9.length) || 0,
|
23562
|
+
options: question.options,
|
23563
|
+
responses: question.responses,
|
23564
|
+
answer: question.answer,
|
23565
|
+
setCurrentIndex,
|
23566
|
+
rolesThatCanViewResponses: poll.rolesThatCanViewResponses
|
23567
|
+
}
|
23568
|
+
) : null;
|
23569
|
+
}));
|
23512
23570
|
};
|
23513
23571
|
}
|
23514
23572
|
});
|
23515
23573
|
|
23516
23574
|
// src/Prebuilt/components/Polls/Voting/Voting.tsx
|
23517
|
-
var import_react117,
|
23575
|
+
var import_react117, import_react_sdk54, import_react_icons58, Voting;
|
23518
23576
|
var init_Voting = __esm({
|
23519
23577
|
"src/Prebuilt/components/Polls/Voting/Voting.tsx"() {
|
23520
23578
|
"use strict";
|
23521
23579
|
init_define_process_env();
|
23522
23580
|
import_react117 = __toESM(require("react"));
|
23523
|
-
|
23581
|
+
import_react_sdk54 = require("@100mslive/react-sdk");
|
23524
23582
|
import_react_icons58 = require("@100mslive/react-icons");
|
23525
23583
|
init_src();
|
23526
23584
|
init_Common();
|
@@ -23530,10 +23588,10 @@ var init_Voting = __esm({
|
|
23530
23588
|
init_StatusIndicator();
|
23531
23589
|
init_constants();
|
23532
23590
|
Voting = ({ id, toggleVoting }) => {
|
23533
|
-
const actions = (0,
|
23534
|
-
const poll = (0,
|
23535
|
-
const pollCreatorName = (0,
|
23536
|
-
const permissions = (0,
|
23591
|
+
const actions = (0, import_react_sdk54.useHMSActions)();
|
23592
|
+
const poll = (0, import_react_sdk54.useHMSStore)((0, import_react_sdk54.selectPollByID)(id));
|
23593
|
+
const pollCreatorName = (0, import_react_sdk54.useHMSStore)((0, import_react_sdk54.selectPeerNameByID)(poll == null ? void 0 : poll.createdBy));
|
23594
|
+
const permissions = (0, import_react_sdk54.useHMSStore)(import_react_sdk54.selectPermissions);
|
23537
23595
|
const canEndActivity = !!(permissions == null ? void 0 : permissions.pollWrite);
|
23538
23596
|
const { setPollView } = usePollViewState();
|
23539
23597
|
const showSingleView = (poll == null ? void 0 : poll.type) === "quiz" && poll.state === "started";
|
@@ -23577,23 +23635,23 @@ var init_Voting = __esm({
|
|
23577
23635
|
},
|
23578
23636
|
/* @__PURE__ */ import_react117.default.createElement(import_react_icons58.CrossIcon, { onClick: toggleVoting })
|
23579
23637
|
)
|
23580
|
-
), /* @__PURE__ */ import_react117.default.createElement(Flex, { direction: "column", css: { p: "$8 $10", overflowY: "auto" } }, poll.state === "started" ? /* @__PURE__ */ import_react117.default.createElement(Text, { css: { color: "$on_surface_medium", fontWeight: "$semiBold" } }, pollCreatorName || "Participant", " started a ", poll.type) : null, showSingleView ? /* @__PURE__ */ import_react117.default.createElement(TimedView, { poll }) : /* @__PURE__ */ import_react117.default.createElement(StandardView, { poll }),
|
23581
|
-
|
23582
|
-
{
|
23583
|
-
variant: "danger",
|
23584
|
-
css: { fontWeight: "$semiBold", w: "max-content", ml: "auto", mt: "$8" },
|
23585
|
-
onClick: () => actions.interactivityCenter.stopPoll(id)
|
23586
|
-
},
|
23587
|
-
"End ",
|
23588
|
-
poll.type
|
23589
|
-
), canViewLeaderboard ? /* @__PURE__ */ import_react117.default.createElement(
|
23590
|
-
Button,
|
23638
|
+
), /* @__PURE__ */ import_react117.default.createElement(Flex, { direction: "column", css: { p: "$8 $10", flex: "1 1 0", overflowY: "auto" } }, poll.state === "started" ? /* @__PURE__ */ import_react117.default.createElement(Text, { css: { color: "$on_surface_medium", fontWeight: "$semiBold" } }, pollCreatorName || "Participant", " started a ", poll.type) : null, showSingleView ? /* @__PURE__ */ import_react117.default.createElement(TimedView, { poll }) : /* @__PURE__ */ import_react117.default.createElement(StandardView, { poll })), /* @__PURE__ */ import_react117.default.createElement(
|
23639
|
+
Flex,
|
23591
23640
|
{
|
23592
|
-
css: {
|
23593
|
-
onClick: () => setPollView(POLL_VIEWS.RESULTS)
|
23641
|
+
css: { w: "100%", justifyContent: "end", alignItems: "center", p: "$8", borderTop: "1px solid $border_bright" }
|
23594
23642
|
},
|
23595
|
-
"
|
23596
|
-
|
23643
|
+
poll.state === "started" && canEndActivity && /* @__PURE__ */ import_react117.default.createElement(
|
23644
|
+
Button,
|
23645
|
+
{
|
23646
|
+
variant: "danger",
|
23647
|
+
css: { fontWeight: "$semiBold", w: "max-content" },
|
23648
|
+
onClick: () => actions.interactivityCenter.stopPoll(id)
|
23649
|
+
},
|
23650
|
+
"End ",
|
23651
|
+
poll.type
|
23652
|
+
),
|
23653
|
+
canViewLeaderboard ? /* @__PURE__ */ import_react117.default.createElement(Button, { css: { fontWeight: "$semiBold", w: "max-content" }, onClick: () => setPollView(POLL_VIEWS.RESULTS) }, "View Leaderboard") : null
|
23654
|
+
));
|
23597
23655
|
};
|
23598
23656
|
}
|
23599
23657
|
});
|
@@ -23651,17 +23709,17 @@ var init_MwebChatOption = __esm({
|
|
23651
23709
|
});
|
23652
23710
|
|
23653
23711
|
// src/Prebuilt/components/hooks/useChatBlacklist.ts
|
23654
|
-
var import_react120,
|
23712
|
+
var import_react120, import_react_sdk55, useChatBlacklist, useIsPeerBlacklisted;
|
23655
23713
|
var init_useChatBlacklist = __esm({
|
23656
23714
|
"src/Prebuilt/components/hooks/useChatBlacklist.ts"() {
|
23657
23715
|
"use strict";
|
23658
23716
|
init_define_process_env();
|
23659
23717
|
import_react120 = require("react");
|
23660
|
-
|
23718
|
+
import_react_sdk55 = require("@100mslive/react-sdk");
|
23661
23719
|
init_ToastManager();
|
23662
23720
|
useChatBlacklist = (sessionStoreKey) => {
|
23663
|
-
const hmsActions = (0,
|
23664
|
-
const blacklistedIDs = (0,
|
23721
|
+
const hmsActions = (0, import_react_sdk55.useHMSActions)();
|
23722
|
+
const blacklistedIDs = (0, import_react_sdk55.useHMSStore)((0, import_react_sdk55.selectSessionStore)(sessionStoreKey));
|
23665
23723
|
const blacklistItem = (0, import_react120.useCallback)(
|
23666
23724
|
(blacklistID) => __async(void 0, null, function* () {
|
23667
23725
|
yield hmsActions.sessionStore.set(sessionStoreKey, [...blacklistedIDs || [], blacklistID]).catch((err) => ToastManager.addToast({ title: err.description }));
|
@@ -23671,35 +23729,35 @@ var init_useChatBlacklist = __esm({
|
|
23671
23729
|
return { blacklistItem, blacklistedIDs };
|
23672
23730
|
};
|
23673
23731
|
useIsPeerBlacklisted = ({ local = false, peerCustomerUserId = "" }) => {
|
23674
|
-
const localPeer = (0,
|
23675
|
-
const blacklistedPeerIDs = (0,
|
23732
|
+
const localPeer = (0, import_react_sdk55.useHMSStore)(import_react_sdk55.selectLocalPeer);
|
23733
|
+
const blacklistedPeerIDs = (0, import_react_sdk55.useHMSStore)((0, import_react_sdk55.selectSessionStore)("chatPeerBlacklist" /* CHAT_PEER_BLACKLIST */)) || [];
|
23676
23734
|
return blacklistedPeerIDs == null ? void 0 : blacklistedPeerIDs.includes(local ? localPeer == null ? void 0 : localPeer.customerUserId : peerCustomerUserId);
|
23677
23735
|
};
|
23678
23736
|
}
|
23679
23737
|
});
|
23680
23738
|
|
23681
23739
|
// src/Prebuilt/components/hooks/usePinnedMessages.ts
|
23682
|
-
var import_react121,
|
23740
|
+
var import_react121, import_react_sdk56, usePinnedMessages;
|
23683
23741
|
var init_usePinnedMessages = __esm({
|
23684
23742
|
"src/Prebuilt/components/hooks/usePinnedMessages.ts"() {
|
23685
23743
|
"use strict";
|
23686
23744
|
init_define_process_env();
|
23687
23745
|
import_react121 = require("react");
|
23688
|
-
|
23746
|
+
import_react_sdk56 = require("@100mslive/react-sdk");
|
23689
23747
|
init_ToastManager();
|
23690
23748
|
usePinnedMessages = () => {
|
23691
|
-
const hmsActions = (0,
|
23692
|
-
const vanillaStore = (0,
|
23749
|
+
const hmsActions = (0, import_react_sdk56.useHMSActions)();
|
23750
|
+
const vanillaStore = (0, import_react_sdk56.useHMSVanillaStore)();
|
23693
23751
|
const setPinnedMessages = (0, import_react121.useCallback)(
|
23694
23752
|
(message, pinnedBy) => __async(void 0, null, function* () {
|
23695
|
-
const peerName = vanillaStore.getState((0,
|
23753
|
+
const peerName = vanillaStore.getState((0, import_react_sdk56.selectPeerNameByID)(message == null ? void 0 : message.sender)) || (message == null ? void 0 : message.senderName);
|
23696
23754
|
const newPinnedMessage = { text: "", id: message.id, pinnedBy };
|
23697
23755
|
if (message && peerName) {
|
23698
23756
|
newPinnedMessage["text"] = `${peerName}: ${message.message}`;
|
23699
23757
|
} else if (message) {
|
23700
23758
|
newPinnedMessage["text"] = message.message;
|
23701
23759
|
}
|
23702
|
-
const pinnedMessages = vanillaStore.getState((0,
|
23760
|
+
const pinnedMessages = vanillaStore.getState((0, import_react_sdk56.selectSessionStore)("pinnedMessages" /* PINNED_MESSAGES */)) || [];
|
23703
23761
|
if (!(pinnedMessages == null ? void 0 : pinnedMessages.find((pinnedMessage) => pinnedMessage.id === newPinnedMessage.id))) {
|
23704
23762
|
yield hmsActions.sessionStore.set("pinnedMessages" /* PINNED_MESSAGES */, [...pinnedMessages, newPinnedMessage].slice(-3)).catch((err) => ToastManager.addToast({ title: err.description }));
|
23705
23763
|
}
|
@@ -23708,7 +23766,7 @@ var init_usePinnedMessages = __esm({
|
|
23708
23766
|
);
|
23709
23767
|
const removePinnedMessage = (0, import_react121.useCallback)(
|
23710
23768
|
(indexToRemove) => __async(void 0, null, function* () {
|
23711
|
-
const pinnedMessages = vanillaStore.getState((0,
|
23769
|
+
const pinnedMessages = vanillaStore.getState((0, import_react_sdk56.selectSessionStore)("pinnedMessages" /* PINNED_MESSAGES */)) || [];
|
23712
23770
|
if (pinnedMessages[indexToRemove]) {
|
23713
23771
|
yield hmsActions.sessionStore.set(
|
23714
23772
|
"pinnedMessages" /* PINNED_MESSAGES */,
|
@@ -23720,7 +23778,7 @@ var init_usePinnedMessages = __esm({
|
|
23720
23778
|
);
|
23721
23779
|
const unpinBlacklistedMessages = (0, import_react121.useCallback)(
|
23722
23780
|
(blacklistedMessageIDSet) => __async(void 0, null, function* () {
|
23723
|
-
const pinnedMessages = vanillaStore.getState((0,
|
23781
|
+
const pinnedMessages = vanillaStore.getState((0, import_react_sdk56.selectSessionStore)("pinnedMessages" /* PINNED_MESSAGES */)) || [];
|
23724
23782
|
const filteredPinnedMessages = pinnedMessages == null ? void 0 : pinnedMessages.filter(
|
23725
23783
|
(pinnedMessage) => !(blacklistedMessageIDSet == null ? void 0 : blacklistedMessageIDSet.has(pinnedMessage.id))
|
23726
23784
|
);
|
@@ -23734,13 +23792,13 @@ var init_usePinnedMessages = __esm({
|
|
23734
23792
|
});
|
23735
23793
|
|
23736
23794
|
// src/Prebuilt/components/Chat/ChatActions.tsx
|
23737
|
-
var import_react122,
|
23795
|
+
var import_react122, import_react_sdk57, import_react_icons59, iconStyle, tooltipBoxCSS, ChatActions;
|
23738
23796
|
var init_ChatActions = __esm({
|
23739
23797
|
"src/Prebuilt/components/Chat/ChatActions.tsx"() {
|
23740
23798
|
"use strict";
|
23741
23799
|
init_define_process_env();
|
23742
23800
|
import_react122 = __toESM(require("react"));
|
23743
|
-
|
23801
|
+
import_react_sdk57 = require("@100mslive/react-sdk");
|
23744
23802
|
import_react_icons59 = require("@100mslive/react-icons");
|
23745
23803
|
init_Dropdown2();
|
23746
23804
|
init_IconButton2();
|
@@ -23777,10 +23835,10 @@ var init_ChatActions = __esm({
|
|
23777
23835
|
const { can_hide_message = false, can_block_user = false } = ((_a8 = elements == null ? void 0 : elements.chat) == null ? void 0 : _a8.real_time_controls) || {};
|
23778
23836
|
const { roles_whitelist = [] } = (elements == null ? void 0 : elements.chat) || {};
|
23779
23837
|
const [open, setOpen] = (0, import_react122.useState)(false);
|
23780
|
-
const actions = (0,
|
23781
|
-
const canRemoveOthers = (_b7 = (0,
|
23838
|
+
const actions = (0, import_react_sdk57.useHMSActions)();
|
23839
|
+
const canRemoveOthers = (_b7 = (0, import_react_sdk57.useHMSStore)(import_react_sdk57.selectPermissions)) == null ? void 0 : _b7.removeOthers;
|
23782
23840
|
const { blacklistItem: blacklistPeer } = useChatBlacklist("chatPeerBlacklist" /* CHAT_PEER_BLACKLIST */);
|
23783
|
-
const localPeerName = (0,
|
23841
|
+
const localPeerName = (0, import_react_sdk57.useHMSStore)(import_react_sdk57.selectLocalPeerName);
|
23784
23842
|
const { setPinnedMessages, unpinBlacklistedMessages } = usePinnedMessages();
|
23785
23843
|
const { blacklistItem: blacklistMessage, blacklistedIDs: blacklistedMessageIDs } = useChatBlacklist(
|
23786
23844
|
"chatMessageBlacklist" /* CHAT_MESSAGE_BLACKLIST */
|
@@ -23873,7 +23931,7 @@ var init_ChatActions = __esm({
|
|
23873
23931
|
}
|
23874
23932
|
};
|
23875
23933
|
if (isMobile) {
|
23876
|
-
return /* @__PURE__ */ import_react122.default.createElement(Sheet.Root, { open: openSheet, onOpenChange: setOpenSheet }, /* @__PURE__ */ import_react122.default.createElement(Sheet.Content, { css: { bg: "$surface_default", pb: "$14" }, onClick: () => setOpenSheet(false) }, /* @__PURE__ */ import_react122.default.createElement(
|
23934
|
+
return /* @__PURE__ */ import_react122.default.createElement(Sheet.Root, { open: openSheet, onOpenChange: setOpenSheet }, /* @__PURE__ */ import_react122.default.createElement(Sheet.Content, { css: { bg: "$surface_default", pb: "$14" }, onClick: (e) => setOpenSheet(false, e) }, /* @__PURE__ */ import_react122.default.createElement(
|
23877
23935
|
Sheet.Title,
|
23878
23936
|
{
|
23879
23937
|
css: {
|
@@ -23890,7 +23948,7 @@ var init_ChatActions = __esm({
|
|
23890
23948
|
}
|
23891
23949
|
},
|
23892
23950
|
"Message options",
|
23893
|
-
/* @__PURE__ */ import_react122.default.createElement(Sheet.Close, { css: { color: "$on_surface_high" }, onClick: () => setOpenSheet(false) }, /* @__PURE__ */ import_react122.default.createElement(import_react_icons59.CrossIcon, null))
|
23951
|
+
/* @__PURE__ */ import_react122.default.createElement(Sheet.Close, { css: { color: "$on_surface_high" }, onClick: (e) => setOpenSheet(false, e) }, /* @__PURE__ */ import_react122.default.createElement(import_react_icons59.CrossIcon, null))
|
23894
23952
|
), Object.keys(options).map((optionKey) => {
|
23895
23953
|
const option = options[optionKey];
|
23896
23954
|
return option.show ? /* @__PURE__ */ import_react122.default.createElement(
|
@@ -24015,15 +24073,15 @@ var init_EmptyChat = __esm({
|
|
24015
24073
|
});
|
24016
24074
|
|
24017
24075
|
// src/Prebuilt/components/hooks/usePinnedBy.tsx
|
24018
|
-
var import_react124,
|
24076
|
+
var import_react124, import_react_sdk58, usePinnedBy;
|
24019
24077
|
var init_usePinnedBy = __esm({
|
24020
24078
|
"src/Prebuilt/components/hooks/usePinnedBy.tsx"() {
|
24021
24079
|
"use strict";
|
24022
24080
|
init_define_process_env();
|
24023
24081
|
import_react124 = require("react");
|
24024
|
-
|
24082
|
+
import_react_sdk58 = require("@100mslive/react-sdk");
|
24025
24083
|
usePinnedBy = (messageId) => {
|
24026
|
-
const pinnedMessages = (0,
|
24084
|
+
const pinnedMessages = (0, import_react_sdk58.useHMSStore)((0, import_react_sdk58.selectSessionStore)("pinnedMessages" /* PINNED_MESSAGES */));
|
24027
24085
|
const [pinnedBy, setPinnedBy] = (0, import_react124.useState)("");
|
24028
24086
|
(0, import_react124.useEffect)(() => {
|
24029
24087
|
let match = "";
|
@@ -24044,7 +24102,7 @@ function getRowHeight(index) {
|
|
24044
24102
|
var _a8;
|
24045
24103
|
return ((_a8 = rowHeights[index]) == null ? void 0 : _a8.size) || 72;
|
24046
24104
|
}
|
24047
|
-
var import_react125, import_react_use15, import_react_virtualized_auto_sizer, import_react_window2,
|
24105
|
+
var import_react125, import_react_use15, import_react_virtualized_auto_sizer, import_react_window2, import_react_sdk59, import_react_icons60, formatTime2, rowHeights, listInstance, setRowHeight, getMessageBackgroundColor, MessageTypeContainer, MessageType, URL_REGEX, Link3, AnnotisedMessage, getMessageType, SenderName, ChatMessage, MessageWrapper, VirtualizedChatMessages, ChatBody, PinnedBy;
|
24048
24106
|
var init_ChatBody = __esm({
|
24049
24107
|
"src/Prebuilt/components/Chat/ChatBody.tsx"() {
|
24050
24108
|
"use strict";
|
@@ -24053,7 +24111,7 @@ var init_ChatBody = __esm({
|
|
24053
24111
|
import_react_use15 = require("react-use");
|
24054
24112
|
import_react_virtualized_auto_sizer = __toESM(require("react-virtualized-auto-sizer"));
|
24055
24113
|
import_react_window2 = require("react-window");
|
24056
|
-
|
24114
|
+
import_react_sdk59 = require("@100mslive/react-sdk");
|
24057
24115
|
import_react_icons60 = require("@100mslive/react-icons");
|
24058
24116
|
init_Layout();
|
24059
24117
|
init_Text2();
|
@@ -24129,8 +24187,8 @@ var init_ChatBody = __esm({
|
|
24129
24187
|
hasCurrentUserSent,
|
24130
24188
|
receiver
|
24131
24189
|
}) => {
|
24132
|
-
const peerName = (0,
|
24133
|
-
const localPeerRoleName = (0,
|
24190
|
+
const peerName = (0, import_react_sdk59.useHMSStore)((0, import_react_sdk59.selectPeerNameByID)(receiver));
|
24191
|
+
const localPeerRoleName = (0, import_react_sdk59.useHMSStore)(import_react_sdk59.selectLocalPeerRoleName);
|
24134
24192
|
if (receiver) {
|
24135
24193
|
return /* @__PURE__ */ import_react125.default.createElement(MessageTypeContainer, { left: hasCurrentUserSent ? `${peerName ? `to ${peerName}` : ""}` : "to You", right: "(DM)" });
|
24136
24194
|
}
|
@@ -24178,14 +24236,14 @@ var init_ChatBody = __esm({
|
|
24178
24236
|
const isMobile = (0, import_react_use15.useMedia)(config.media.md);
|
24179
24237
|
const isPrivateChatEnabled = !!((_a8 = elements == null ? void 0 : elements.chat) == null ? void 0 : _a8.private_chat_enabled);
|
24180
24238
|
const isOverlay = ((_b7 = elements == null ? void 0 : elements.chat) == null ? void 0 : _b7.is_overlay) && isMobile;
|
24181
|
-
const localPeerId = (0,
|
24239
|
+
const localPeerId = (0, import_react_sdk59.useHMSStore)(import_react_sdk59.selectLocalPeerID);
|
24182
24240
|
const [selectedRole, setRoleSelector] = useSetSubscribedChatSelector(CHAT_SELECTOR.ROLE);
|
24183
24241
|
const [selectedPeer, setPeerSelector] = useSetSubscribedChatSelector(CHAT_SELECTOR.PEER);
|
24184
24242
|
const messageType = getMessageType({
|
24185
24243
|
roles: message.recipientRoles,
|
24186
24244
|
receiver: message.recipientPeer
|
24187
24245
|
});
|
24188
|
-
const [openSheet,
|
24246
|
+
const [openSheet, setOpenSheetBare] = (0, import_react125.useState)(false);
|
24189
24247
|
const showPinAction = !!((_c = elements == null ? void 0 : elements.chat) == null ? void 0 : _c.allow_pinning_messages);
|
24190
24248
|
const showReply = message.sender !== selectedPeer.id && message.sender !== localPeerId && isPrivateChatEnabled;
|
24191
24249
|
(0, import_react125.useLayoutEffect)(() => {
|
@@ -24193,6 +24251,10 @@ var init_ChatBody = __esm({
|
|
24193
24251
|
setRowHeight(index, message.id, rowRef.current.clientHeight);
|
24194
24252
|
}
|
24195
24253
|
}, [index, message.id]);
|
24254
|
+
const setOpenSheet = (value, e) => {
|
24255
|
+
e == null ? void 0 : e.stopPropagation();
|
24256
|
+
setOpenSheetBare(value);
|
24257
|
+
};
|
24196
24258
|
return /* @__PURE__ */ import_react125.default.createElement(
|
24197
24259
|
Box,
|
24198
24260
|
{
|
@@ -24226,9 +24288,9 @@ var init_ChatBody = __esm({
|
|
24226
24288
|
}
|
24227
24289
|
},
|
24228
24290
|
"data-testid": "chat_msg",
|
24229
|
-
onClick: () => {
|
24291
|
+
onClick: (e) => {
|
24230
24292
|
if (isMobile) {
|
24231
|
-
setOpenSheet(true);
|
24293
|
+
setOpenSheet(true, e);
|
24232
24294
|
}
|
24233
24295
|
}
|
24234
24296
|
},
|
@@ -24323,8 +24385,7 @@ var init_ChatBody = __esm({
|
|
24323
24385
|
color: isOverlay ? "#FFF" : "$on_surface_high"
|
24324
24386
|
},
|
24325
24387
|
onClick: (e) => {
|
24326
|
-
e
|
24327
|
-
setOpenSheet(true);
|
24388
|
+
setOpenSheet(true, e);
|
24328
24389
|
}
|
24329
24390
|
},
|
24330
24391
|
/* @__PURE__ */ import_react125.default.createElement(AnnotisedMessage, { message: message.message })
|
@@ -24339,7 +24400,7 @@ var init_ChatBody = __esm({
|
|
24339
24400
|
}
|
24340
24401
|
);
|
24341
24402
|
VirtualizedChatMessages = import_react125.default.forwardRef(({ messages, scrollToBottom }, listRef) => {
|
24342
|
-
const hmsActions = (0,
|
24403
|
+
const hmsActions = (0, import_react_sdk59.useHMSActions)();
|
24343
24404
|
const itemKey2 = (0, import_react125.useCallback)((index, data3) => {
|
24344
24405
|
return data3[index].id;
|
24345
24406
|
}, []);
|
@@ -24394,13 +24455,13 @@ var init_ChatBody = __esm({
|
|
24394
24455
|
});
|
24395
24456
|
ChatBody = import_react125.default.forwardRef(
|
24396
24457
|
({ scrollToBottom }, listRef) => {
|
24397
|
-
const messages = (0,
|
24398
|
-
const blacklistedMessageIDs = (0,
|
24458
|
+
const messages = (0, import_react_sdk59.useHMSStore)(import_react_sdk59.selectHMSMessages);
|
24459
|
+
const blacklistedMessageIDs = (0, import_react_sdk59.useHMSStore)((0, import_react_sdk59.selectSessionStore)("chatMessageBlacklist" /* CHAT_MESSAGE_BLACKLIST */));
|
24399
24460
|
const filteredMessages = (0, import_react125.useMemo)(() => {
|
24400
24461
|
const blacklistedMessageIDSet = new Set(blacklistedMessageIDs || []);
|
24401
24462
|
return (messages == null ? void 0 : messages.filter((message) => message.type === "chat" && !blacklistedMessageIDSet.has(message.id))) || [];
|
24402
24463
|
}, [blacklistedMessageIDs, messages]);
|
24403
|
-
const vanillaStore = (0,
|
24464
|
+
const vanillaStore = (0, import_react_sdk59.useHMSVanillaStore)();
|
24404
24465
|
(0, import_react125.useEffect)(() => {
|
24405
24466
|
const unsubscribe = vanillaStore.subscribe(() => {
|
24406
24467
|
if (!listRef.current) {
|
@@ -24410,7 +24471,7 @@ var init_ChatBody = __esm({
|
|
24410
24471
|
if (outerElement.clientHeight + outerElement.scrollTop + outerElement.offsetTop >= outerElement.scrollHeight) {
|
24411
24472
|
requestAnimationFrame(() => scrollToBottom(1));
|
24412
24473
|
}
|
24413
|
-
},
|
24474
|
+
}, import_react_sdk59.selectUnreadHMSMessagesCount);
|
24414
24475
|
return unsubscribe;
|
24415
24476
|
}, [vanillaStore, listRef, scrollToBottom]);
|
24416
24477
|
if (filteredMessages.length === 0) {
|
@@ -24425,7 +24486,7 @@ var init_ChatBody = __esm({
|
|
24425
24486
|
rowRef
|
24426
24487
|
}) => {
|
24427
24488
|
const pinnedBy = usePinnedBy(messageId);
|
24428
|
-
const localPeerName = (0,
|
24489
|
+
const localPeerName = (0, import_react_sdk59.useHMSStore)(import_react_sdk59.selectLocalPeerName);
|
24429
24490
|
(0, import_react125.useLayoutEffect)(() => {
|
24430
24491
|
if (rowRef == null ? void 0 : rowRef.current) {
|
24431
24492
|
if (pinnedBy) {
|
@@ -24445,14 +24506,14 @@ var init_ChatBody = __esm({
|
|
24445
24506
|
});
|
24446
24507
|
|
24447
24508
|
// src/Prebuilt/components/Chat/ChatSelector.tsx
|
24448
|
-
var import_react126, import_react_use16,
|
24509
|
+
var import_react126, import_react_use16, import_react_sdk60, import_react_icons61, ChatDotIcon, SelectorItem, SelectorHeader, Everyone, RoleItem, PeerItem, VirtualizedSelectItemList, ChatSelector;
|
24449
24510
|
var init_ChatSelector = __esm({
|
24450
24511
|
"src/Prebuilt/components/Chat/ChatSelector.tsx"() {
|
24451
24512
|
"use strict";
|
24452
24513
|
init_define_process_env();
|
24453
24514
|
import_react126 = __toESM(require("react"));
|
24454
24515
|
import_react_use16 = require("react-use");
|
24455
|
-
|
24516
|
+
import_react_sdk60 = require("@100mslive/react-sdk");
|
24456
24517
|
import_react_icons61 = require("@100mslive/react-icons");
|
24457
24518
|
init_src();
|
24458
24519
|
init_Theme();
|
@@ -24508,7 +24569,7 @@ var init_ChatSelector = __esm({
|
|
24508
24569
|
}
|
24509
24570
|
);
|
24510
24571
|
Everyone = import_react126.default.memo(({ active }) => {
|
24511
|
-
const unreadCount = (0,
|
24572
|
+
const unreadCount = (0, import_react_sdk60.useHMSStore)(import_react_sdk60.selectUnreadHMSMessagesCount);
|
24512
24573
|
const [, setPeerSelector] = useSetSubscribedChatSelector(CHAT_SELECTOR.PEER);
|
24513
24574
|
const [, setRoleSelector] = useSetSubscribedChatSelector(CHAT_SELECTOR.ROLE);
|
24514
24575
|
return /* @__PURE__ */ import_react126.default.createElement(
|
@@ -24526,7 +24587,7 @@ var init_ChatSelector = __esm({
|
|
24526
24587
|
);
|
24527
24588
|
});
|
24528
24589
|
RoleItem = import_react126.default.memo(({ role, active }) => {
|
24529
|
-
const unreadCount = (0,
|
24590
|
+
const unreadCount = (0, import_react_sdk60.useHMSStore)((0, import_react_sdk60.selectMessagesUnreadCountByRole)(role));
|
24530
24591
|
const [, setPeerSelector] = useSetSubscribedChatSelector(CHAT_SELECTOR.PEER);
|
24531
24592
|
const [, setRoleSelector] = useSetSubscribedChatSelector(CHAT_SELECTOR.ROLE);
|
24532
24593
|
return /* @__PURE__ */ import_react126.default.createElement(
|
@@ -24543,7 +24604,7 @@ var init_ChatSelector = __esm({
|
|
24543
24604
|
);
|
24544
24605
|
});
|
24545
24606
|
PeerItem = ({ peerId, name, active }) => {
|
24546
|
-
const unreadCount = (0,
|
24607
|
+
const unreadCount = (0, import_react_sdk60.useHMSStore)((0, import_react_sdk60.selectMessagesUnreadCountByPeerID)(peerId));
|
24547
24608
|
const [, setPeerSelector] = useSetSubscribedChatSelector(CHAT_SELECTOR.PEER);
|
24548
24609
|
const [, setRoleSelector] = useSetSubscribedChatSelector(CHAT_SELECTOR.ROLE);
|
24549
24610
|
return /* @__PURE__ */ import_react126.default.createElement(
|
@@ -24602,7 +24663,7 @@ var init_ChatSelector = __esm({
|
|
24602
24663
|
ChatSelector = ({ role, peerId }) => {
|
24603
24664
|
var _a8, _b7;
|
24604
24665
|
const { elements } = useRoomLayoutConferencingScreen();
|
24605
|
-
const peers = (0,
|
24666
|
+
const peers = (0, import_react_sdk60.useHMSStore)(import_react_sdk60.selectRemotePeers);
|
24606
24667
|
const [search, setSearch] = (0, import_react126.useState)("");
|
24607
24668
|
const isPrivateChatEnabled = !!((_a8 = elements == null ? void 0 : elements.chat) == null ? void 0 : _a8.private_chat_enabled);
|
24608
24669
|
const isPublicChatEnabled = !!((_b7 = elements == null ? void 0 : elements.chat) == null ? void 0 : _b7.public_chat_enabled);
|
@@ -24760,17 +24821,17 @@ var init_ChatSelectorContainer = __esm({
|
|
24760
24821
|
});
|
24761
24822
|
|
24762
24823
|
// src/Prebuilt/components/AppData/useChatState.js
|
24763
|
-
var import_react128,
|
24824
|
+
var import_react128, import_react_sdk61, useChatDraftMessage;
|
24764
24825
|
var init_useChatState = __esm({
|
24765
24826
|
"src/Prebuilt/components/AppData/useChatState.js"() {
|
24766
24827
|
"use strict";
|
24767
24828
|
init_define_process_env();
|
24768
24829
|
import_react128 = require("react");
|
24769
|
-
|
24830
|
+
import_react_sdk61 = require("@100mslive/react-sdk");
|
24770
24831
|
init_constants();
|
24771
24832
|
useChatDraftMessage = () => {
|
24772
|
-
const hmsActions = (0,
|
24773
|
-
let chatDraftMessage = (0,
|
24833
|
+
const hmsActions = (0, import_react_sdk61.useHMSActions)();
|
24834
|
+
let chatDraftMessage = (0, import_react_sdk61.useHMSStore)((0, import_react_sdk61.selectAppData)(APP_DATA.chatDraft));
|
24774
24835
|
if (chatDraftMessage === void 0 || chatDraftMessage === null) {
|
24775
24836
|
chatDraftMessage = "";
|
24776
24837
|
}
|
@@ -24852,7 +24913,7 @@ function EmojiPicker({ onSelect }) {
|
|
24852
24913
|
)
|
24853
24914
|
)));
|
24854
24915
|
}
|
24855
|
-
var import_react130, import_react_use18, import_data, import_react131,
|
24916
|
+
var import_react130, import_react_use18, import_data, import_react131, import_react_sdk62, import_react_icons63, TextArea2, ChatFooter;
|
24856
24917
|
var init_ChatFooter = __esm({
|
24857
24918
|
"src/Prebuilt/components/Chat/ChatFooter.tsx"() {
|
24858
24919
|
"use strict";
|
@@ -24861,7 +24922,7 @@ var init_ChatFooter = __esm({
|
|
24861
24922
|
import_react_use18 = require("react-use");
|
24862
24923
|
import_data = __toESM(require("@emoji-mart/data"));
|
24863
24924
|
import_react131 = __toESM(require("@emoji-mart/react"));
|
24864
|
-
|
24925
|
+
import_react_sdk62 = require("@100mslive/react-sdk");
|
24865
24926
|
import_react_icons63 = require("@100mslive/react-icons");
|
24866
24927
|
init_src();
|
24867
24928
|
init_IconButton2();
|
@@ -24893,13 +24954,13 @@ var init_ChatFooter = __esm({
|
|
24893
24954
|
});
|
24894
24955
|
ChatFooter = ({ onSend, children }) => {
|
24895
24956
|
var _a8, _b7, _c, _d;
|
24896
|
-
const hmsActions = (0,
|
24957
|
+
const hmsActions = (0, import_react_sdk62.useHMSActions)();
|
24897
24958
|
const inputRef = (0, import_react130.useRef)(null);
|
24898
24959
|
const [draftMessage, setDraftMessage] = useChatDraftMessage();
|
24899
24960
|
const isMobile = (0, import_react_use18.useMedia)(config.media.md);
|
24900
24961
|
const { elements } = useRoomLayoutConferencingScreen();
|
24901
24962
|
const message_placeholder = ((_a8 = elements == null ? void 0 : elements.chat) == null ? void 0 : _a8.message_placeholder) || "Send a message";
|
24902
|
-
const localPeer = (0,
|
24963
|
+
const localPeer = (0, import_react_sdk62.useHMSStore)(import_react_sdk62.selectLocalPeer);
|
24903
24964
|
const isOverlayChat = (_b7 = elements == null ? void 0 : elements.chat) == null ? void 0 : _b7.is_overlay;
|
24904
24965
|
const canDisableChat = !!((_d = (_c = elements == null ? void 0 : elements.chat) == null ? void 0 : _c.real_time_controls) == null ? void 0 : _d.can_disable_chat);
|
24905
24966
|
const selectedPeer = useSubscribeChatSelector(CHAT_SELECTOR.PEER);
|
@@ -25066,13 +25127,13 @@ var init_ChatFooter = __esm({
|
|
25066
25127
|
});
|
25067
25128
|
|
25068
25129
|
// src/Prebuilt/components/Chat/ChatStates.tsx
|
25069
|
-
var import_react132,
|
25130
|
+
var import_react132, import_react_sdk63, ChatPaused, ChatBlocked;
|
25070
25131
|
var init_ChatStates = __esm({
|
25071
25132
|
"src/Prebuilt/components/Chat/ChatStates.tsx"() {
|
25072
25133
|
"use strict";
|
25073
25134
|
init_define_process_env();
|
25074
25135
|
import_react132 = __toESM(require("react"));
|
25075
|
-
|
25136
|
+
import_react_sdk63 = require("@100mslive/react-sdk");
|
25076
25137
|
init_Button2();
|
25077
25138
|
init_Layout();
|
25078
25139
|
init_Text2();
|
@@ -25080,11 +25141,11 @@ var init_ChatStates = __esm({
|
|
25080
25141
|
init_useChatBlacklist();
|
25081
25142
|
ChatPaused = () => {
|
25082
25143
|
var _a8, _b7;
|
25083
|
-
const hmsActions = (0,
|
25144
|
+
const hmsActions = (0, import_react_sdk63.useHMSActions)();
|
25084
25145
|
const { elements } = useRoomLayoutConferencingScreen();
|
25085
25146
|
const can_disable_chat = !!((_b7 = (_a8 = elements == null ? void 0 : elements.chat) == null ? void 0 : _a8.real_time_controls) == null ? void 0 : _b7.can_disable_chat);
|
25086
|
-
const { enabled: isChatEnabled = true, updatedBy: chatStateUpdatedBy = "" } = (0,
|
25087
|
-
const localPeer = (0,
|
25147
|
+
const { enabled: isChatEnabled = true, updatedBy: chatStateUpdatedBy = "" } = (0, import_react_sdk63.useHMSStore)((0, import_react_sdk63.selectSessionStore)("chatState" /* CHAT_STATE */)) || {};
|
25148
|
+
const localPeer = (0, import_react_sdk63.useHMSStore)(import_react_sdk63.selectLocalPeer);
|
25088
25149
|
const unPauseChat = (0, import_react132.useCallback)(
|
25089
25150
|
() => __async(void 0, null, function* () {
|
25090
25151
|
return yield hmsActions.sessionStore.set("chatState" /* CHAT_STATE */, {
|
@@ -25197,7 +25258,7 @@ var init_StickIndicator = __esm({
|
|
25197
25258
|
});
|
25198
25259
|
|
25199
25260
|
// src/Prebuilt/components/Chat/PinnedMessage.tsx
|
25200
|
-
var import_react135, import_react_swipeable, import_react_use19,
|
25261
|
+
var import_react135, import_react_swipeable, import_react_use19, import_react_sdk64, import_react_icons65, PINNED_MESSAGE_LENGTH, PinnedMessage;
|
25201
25262
|
var init_PinnedMessage = __esm({
|
25202
25263
|
"src/Prebuilt/components/Chat/PinnedMessage.tsx"() {
|
25203
25264
|
"use strict";
|
@@ -25205,7 +25266,7 @@ var init_PinnedMessage = __esm({
|
|
25205
25266
|
import_react135 = __toESM(require("react"));
|
25206
25267
|
import_react_swipeable = require("react-swipeable");
|
25207
25268
|
import_react_use19 = require("react-use");
|
25208
|
-
|
25269
|
+
import_react_sdk64 = require("@100mslive/react-sdk");
|
25209
25270
|
import_react_icons65 = require("@100mslive/react-icons");
|
25210
25271
|
init_Layout();
|
25211
25272
|
init_Text2();
|
@@ -25218,7 +25279,7 @@ var init_PinnedMessage = __esm({
|
|
25218
25279
|
PINNED_MESSAGE_LENGTH = 75;
|
25219
25280
|
PinnedMessage = () => {
|
25220
25281
|
var _a8, _b7, _c;
|
25221
|
-
const pinnedMessages = (0,
|
25282
|
+
const pinnedMessages = (0, import_react_sdk64.useHMSStore)((0, import_react_sdk64.selectSessionStore)("pinnedMessages" /* PINNED_MESSAGES */));
|
25222
25283
|
const [pinnedMessageIndex, setPinnedMessageIndex] = (0, import_react135.useState)(0);
|
25223
25284
|
const { removePinnedMessage } = usePinnedMessages();
|
25224
25285
|
const isMobile = (0, import_react_use19.useMedia)(config.media.md);
|
@@ -25334,7 +25395,7 @@ var init_PinnedMessage = __esm({
|
|
25334
25395
|
});
|
25335
25396
|
|
25336
25397
|
// src/Prebuilt/components/Chat/Chat.tsx
|
25337
|
-
var import_react136, import_react_use20,
|
25398
|
+
var import_react136, import_react_use20, import_react_sdk65, import_react_icons66, Chat, NewMessageIndicator;
|
25338
25399
|
var init_Chat = __esm({
|
25339
25400
|
"src/Prebuilt/components/Chat/Chat.tsx"() {
|
25340
25401
|
"use strict";
|
@@ -25342,7 +25403,7 @@ var init_Chat = __esm({
|
|
25342
25403
|
import_react136 = __toESM(require("react"));
|
25343
25404
|
import_react_use20 = require("react-use");
|
25344
25405
|
init_dist();
|
25345
|
-
|
25406
|
+
import_react_sdk65 = require("@100mslive/react-sdk");
|
25346
25407
|
import_react_icons66 = require("@100mslive/react-icons");
|
25347
25408
|
init_Button2();
|
25348
25409
|
init_Layout();
|
@@ -25356,15 +25417,15 @@ var init_Chat = __esm({
|
|
25356
25417
|
var _a8, _b7;
|
25357
25418
|
const { elements } = useRoomLayoutConferencingScreen();
|
25358
25419
|
const listRef = (0, import_react136.useRef)(null);
|
25359
|
-
const hmsActions = (0,
|
25360
|
-
const vanillaStore = (0,
|
25361
|
-
const { enabled: isChatEnabled = true } = (0,
|
25420
|
+
const hmsActions = (0, import_react_sdk65.useHMSActions)();
|
25421
|
+
const vanillaStore = (0, import_react_sdk65.useHMSVanillaStore)();
|
25422
|
+
const { enabled: isChatEnabled = true } = (0, import_react_sdk65.useHMSStore)(qh("chatState" /* CHAT_STATE */)) || {};
|
25362
25423
|
const isMobile = (0, import_react_use20.useMedia)(config.media.md);
|
25363
25424
|
const scrollToBottom = (0, import_react136.useCallback)(
|
25364
25425
|
(unreadCount = 0) => {
|
25365
25426
|
var _a9;
|
25366
25427
|
if (listRef.current && listRef.current.scrollToItem && unreadCount > 0) {
|
25367
|
-
const messagesCount = vanillaStore.getState(
|
25428
|
+
const messagesCount = vanillaStore.getState(import_react_sdk65.selectHMSMessagesCount);
|
25368
25429
|
(_a9 = listRef.current) == null ? void 0 : _a9.scrollToItem(messagesCount, "end");
|
25369
25430
|
requestAnimationFrame(() => {
|
25370
25431
|
var _a10;
|
@@ -25396,7 +25457,7 @@ var init_Chat = __esm({
|
|
25396
25457
|
scrollToBottom,
|
25397
25458
|
listRef
|
25398
25459
|
}) => {
|
25399
|
-
const unreadCount = (0,
|
25460
|
+
const unreadCount = (0, import_react_sdk65.useHMSStore)(Un);
|
25400
25461
|
if (!unreadCount || !listRef.current) {
|
25401
25462
|
return null;
|
25402
25463
|
}
|
@@ -25443,7 +25504,7 @@ var init_Chat = __esm({
|
|
25443
25504
|
});
|
25444
25505
|
|
25445
25506
|
// src/Prebuilt/components/Footer/PaginatedParticipants.tsx
|
25446
|
-
var import_react137, import_react_intersection_observer, import_react_use21, import_react_window3,
|
25507
|
+
var import_react137, import_react_intersection_observer, import_react_use21, import_react_window3, import_react_sdk66, import_react_icons67, LoadMoreParticipants, VirtualizedParticipantItem2, PaginatedParticipants;
|
25447
25508
|
var init_PaginatedParticipants = __esm({
|
25448
25509
|
"src/Prebuilt/components/Footer/PaginatedParticipants.tsx"() {
|
25449
25510
|
"use strict";
|
@@ -25452,7 +25513,7 @@ var init_PaginatedParticipants = __esm({
|
|
25452
25513
|
import_react_intersection_observer = require("react-intersection-observer");
|
25453
25514
|
import_react_use21 = require("react-use");
|
25454
25515
|
import_react_window3 = require("react-window");
|
25455
|
-
|
25516
|
+
import_react_sdk66 = require("@100mslive/react-sdk");
|
25456
25517
|
import_react_icons67 = require("@100mslive/react-icons");
|
25457
25518
|
init_IconButton2();
|
25458
25519
|
init_Layout();
|
@@ -25498,13 +25559,13 @@ var init_PaginatedParticipants = __esm({
|
|
25498
25559
|
}
|
25499
25560
|
);
|
25500
25561
|
PaginatedParticipants = ({ roleName, onBack }) => {
|
25501
|
-
const { peers, total, hasNext, loadPeers, loadMorePeers } = (0,
|
25562
|
+
const { peers, total, hasNext, loadPeers, loadMorePeers } = (0, import_react_sdk66.usePaginatedParticipants)({ role: roleName, limit: 20 });
|
25502
25563
|
const [search, setSearch] = (0, import_react137.useState)("");
|
25503
25564
|
const filteredPeers = peers.filter((p) => {
|
25504
25565
|
var _a8;
|
25505
25566
|
return (_a8 = p.name) == null ? void 0 : _a8.toLowerCase().includes(search == null ? void 0 : search.toLowerCase());
|
25506
25567
|
});
|
25507
|
-
const isConnected = (0,
|
25568
|
+
const isConnected = (0, import_react_sdk66.useHMSStore)(import_react_sdk66.selectIsConnectedToRoom);
|
25508
25569
|
const [ref, { width }] = (0, import_react_use21.useMeasure)();
|
25509
25570
|
const height = ROW_HEIGHT * (filteredPeers.length + 1);
|
25510
25571
|
const resetSidePane = useSidepaneReset();
|
@@ -25538,13 +25599,13 @@ var init_PaginatedParticipants = __esm({
|
|
25538
25599
|
});
|
25539
25600
|
|
25540
25601
|
// src/Prebuilt/components/ChatSettings.tsx
|
25541
|
-
var import_react138,
|
25602
|
+
var import_react138, import_react_sdk67, import_react_icons68, ChatSettings;
|
25542
25603
|
var init_ChatSettings = __esm({
|
25543
25604
|
"src/Prebuilt/components/ChatSettings.tsx"() {
|
25544
25605
|
"use strict";
|
25545
25606
|
init_define_process_env();
|
25546
25607
|
import_react138 = __toESM(require("react"));
|
25547
|
-
|
25608
|
+
import_react_sdk67 = require("@100mslive/react-sdk");
|
25548
25609
|
import_react_icons68 = require("@100mslive/react-icons");
|
25549
25610
|
init_Layout();
|
25550
25611
|
init_Popover();
|
@@ -25552,11 +25613,11 @@ var init_ChatSettings = __esm({
|
|
25552
25613
|
init_useRoomLayoutScreen();
|
25553
25614
|
ChatSettings = () => {
|
25554
25615
|
var _a8, _b7;
|
25555
|
-
const hmsActions = (0,
|
25556
|
-
const localPeer = (0,
|
25616
|
+
const hmsActions = (0, import_react_sdk67.useHMSActions)();
|
25617
|
+
const localPeer = (0, import_react_sdk67.useHMSStore)(import_react_sdk67.selectLocalPeer);
|
25557
25618
|
const { elements } = useRoomLayoutConferencingScreen();
|
25558
25619
|
const canPauseChat = !!((_b7 = (_a8 = elements == null ? void 0 : elements.chat) == null ? void 0 : _a8.real_time_controls) == null ? void 0 : _b7.can_disable_chat);
|
25559
|
-
const { enabled: isChatEnabled = true } = (0,
|
25620
|
+
const { enabled: isChatEnabled = true } = (0, import_react_sdk67.useHMSStore)((0, import_react_sdk67.selectSessionStore)("chatState" /* CHAT_STATE */)) || {};
|
25560
25621
|
const showPause = canPauseChat && isChatEnabled;
|
25561
25622
|
if (!showPause) {
|
25562
25623
|
return null;
|
@@ -25605,14 +25666,14 @@ var init_ChatSettings = __esm({
|
|
25605
25666
|
});
|
25606
25667
|
|
25607
25668
|
// src/Prebuilt/components/SidePaneTabs.tsx
|
25608
|
-
var import_react139, import_react_use22,
|
25669
|
+
var import_react139, import_react_use22, import_react_sdk68, import_react_icons69, tabTriggerCSS, ParticipantCount2, SidePaneTabs;
|
25609
25670
|
var init_SidePaneTabs = __esm({
|
25610
25671
|
"src/Prebuilt/components/SidePaneTabs.tsx"() {
|
25611
25672
|
"use strict";
|
25612
25673
|
init_define_process_env();
|
25613
25674
|
import_react139 = __toESM(require("react"));
|
25614
25675
|
import_react_use22 = require("react-use");
|
25615
|
-
|
25676
|
+
import_react_sdk68 = require("@100mslive/react-sdk");
|
25616
25677
|
import_react_icons69 = require("@100mslive/react-icons");
|
25617
25678
|
init_Chat();
|
25618
25679
|
init_PaginatedParticipants();
|
@@ -25642,7 +25703,7 @@ var init_SidePaneTabs = __esm({
|
|
25642
25703
|
const resetSidePane = useSidepaneReset();
|
25643
25704
|
const [activeTab, setActiveTab] = (0, import_react139.useState)(active);
|
25644
25705
|
const [activeRole, setActiveRole] = (0, import_react139.useState)("");
|
25645
|
-
const peerCount = (0,
|
25706
|
+
const peerCount = (0, import_react_sdk68.useHMSStore)(import_react_sdk68.selectPeerCount);
|
25646
25707
|
const { elements } = useRoomLayoutConferencingScreen();
|
25647
25708
|
const chat_title = ((_a8 = elements == null ? void 0 : elements.chat) == null ? void 0 : _a8.chat_title) || "Chat";
|
25648
25709
|
const showChat = !!(elements == null ? void 0 : elements.chat);
|
@@ -25813,7 +25874,7 @@ var init_TileConnection = __esm({
|
|
25813
25874
|
|
25814
25875
|
// src/Prebuilt/components/TileMenu/utils.ts
|
25815
25876
|
var getDragClassName;
|
25816
|
-
var
|
25877
|
+
var init_utils5 = __esm({
|
25817
25878
|
"src/Prebuilt/components/TileMenu/utils.ts"() {
|
25818
25879
|
"use strict";
|
25819
25880
|
init_define_process_env();
|
@@ -25824,14 +25885,14 @@ var init_utils4 = __esm({
|
|
25824
25885
|
});
|
25825
25886
|
|
25826
25887
|
// src/Prebuilt/components/TileMenu/TileMenuContent.tsx
|
25827
|
-
var import_react141, import_react_use23,
|
25888
|
+
var import_react141, import_react_use23, import_react_sdk69, import_react_icons71, isSameTile, spacingCSS, SpotlightActions, PinActions, MinimiseInset, SimulcastLayers, TileMenuContent;
|
25828
25889
|
var init_TileMenuContent = __esm({
|
25829
25890
|
"src/Prebuilt/components/TileMenu/TileMenuContent.tsx"() {
|
25830
25891
|
"use strict";
|
25831
25892
|
init_define_process_env();
|
25832
25893
|
import_react141 = __toESM(require("react"));
|
25833
25894
|
import_react_use23 = require("react-use");
|
25834
|
-
|
25895
|
+
import_react_sdk69 = require("@100mslive/react-sdk");
|
25835
25896
|
import_react_icons71 = require("@100mslive/react-icons");
|
25836
25897
|
init_Layout();
|
25837
25898
|
init_Slider2();
|
@@ -25842,7 +25903,7 @@ var init_TileMenuContent = __esm({
|
|
25842
25903
|
init_ToastManager();
|
25843
25904
|
init_useUISettings();
|
25844
25905
|
init_useDropdownSelection();
|
25845
|
-
|
25906
|
+
init_utils5();
|
25846
25907
|
init_constants();
|
25847
25908
|
isSameTile = ({
|
25848
25909
|
trackId,
|
@@ -25856,8 +25917,8 @@ var init_TileMenuContent = __esm({
|
|
25856
25917
|
return;
|
25857
25918
|
}
|
25858
25919
|
}) => {
|
25859
|
-
const hmsActions = (0,
|
25860
|
-
const spotlightPeerId = (0,
|
25920
|
+
const hmsActions = (0, import_react_sdk69.useHMSActions)();
|
25921
|
+
const spotlightPeerId = (0, import_react_sdk69.useHMSStore)((0, import_react_sdk69.selectSessionStore)("spotlight" /* SPOTLIGHT */));
|
25861
25922
|
const isTileSpotlighted = spotlightPeerId === peerId;
|
25862
25923
|
const dragClassName = getDragClassName();
|
25863
25924
|
const setSpotlightPeerId = (peerIdToSpotlight) => hmsActions.sessionStore.set("spotlight" /* SPOTLIGHT */, peerIdToSpotlight).catch((err) => ToastManager.addToast({ title: err.description }));
|
@@ -25905,8 +25966,8 @@ var init_TileMenuContent = __esm({
|
|
25905
25966
|
};
|
25906
25967
|
SimulcastLayers = ({ trackId }) => {
|
25907
25968
|
var _a8;
|
25908
|
-
const track = (0,
|
25909
|
-
const actions = (0,
|
25969
|
+
const track = (0, import_react_sdk69.useHMSStore)((0, import_react_sdk69.selectTrackByID)(trackId));
|
25970
|
+
const actions = (0, import_react_sdk69.useHMSActions)();
|
25910
25971
|
const bg = useDropdownSelection();
|
25911
25972
|
if (!((_a8 = track == null ? void 0 : track.layerDefinitions) == null ? void 0 : _a8.length) || track.degraded || !track.enabled) {
|
25912
25973
|
return null;
|
@@ -25989,15 +26050,15 @@ var init_TileMenuContent = __esm({
|
|
25989
26050
|
}
|
25990
26051
|
}) => {
|
25991
26052
|
var _a8;
|
25992
|
-
const actions = (0,
|
26053
|
+
const actions = (0, import_react_sdk69.useHMSActions)();
|
25993
26054
|
const dragClassName = getDragClassName();
|
25994
|
-
const removeOthers = (_a8 = (0,
|
26055
|
+
const removeOthers = (_a8 = (0, import_react_sdk69.useHMSStore)(import_react_sdk69.selectPermissions)) == null ? void 0 : _a8.removeOthers;
|
25995
26056
|
const { userName } = useHMSPrebuiltContext();
|
25996
|
-
const { isAudioEnabled, isVideoEnabled, setVolume, toggleAudio, toggleVideo, volume } = (0,
|
26057
|
+
const { isAudioEnabled, isVideoEnabled, setVolume, toggleAudio, toggleVideo, volume } = (0, import_react_sdk69.useRemoteAVToggle)(
|
25997
26058
|
audioTrackID,
|
25998
26059
|
videoTrackID
|
25999
26060
|
);
|
26000
|
-
const { sendEvent } = (0,
|
26061
|
+
const { sendEvent } = (0, import_react_sdk69.useCustomEvent)({
|
26001
26062
|
type: REMOTE_STOP_SCREENSHARE_TYPE
|
26002
26063
|
});
|
26003
26064
|
const isMobile = (0, import_react_use23.useMedia)(config.media.md);
|
@@ -26078,14 +26139,14 @@ var init_TileMenuContent = __esm({
|
|
26078
26139
|
});
|
26079
26140
|
|
26080
26141
|
// src/Prebuilt/components/TileMenu/TileMenu.jsx
|
26081
|
-
var import_react142, import_react_use24,
|
26142
|
+
var import_react142, import_react_use24, import_react_sdk70, import_react_icons72, TileMenu, TileMenu_default;
|
26082
26143
|
var init_TileMenu2 = __esm({
|
26083
26144
|
"src/Prebuilt/components/TileMenu/TileMenu.jsx"() {
|
26084
26145
|
"use strict";
|
26085
26146
|
init_define_process_env();
|
26086
26147
|
import_react142 = __toESM(require("react"));
|
26087
26148
|
import_react_use24 = require("react-use");
|
26088
|
-
|
26149
|
+
import_react_sdk70 = require("@100mslive/react-sdk");
|
26089
26150
|
import_react_icons72 = require("@100mslive/react-icons");
|
26090
26151
|
init_Layout();
|
26091
26152
|
init_Sheet2();
|
@@ -26095,7 +26156,7 @@ var init_TileMenu2 = __esm({
|
|
26095
26156
|
init_ChangeNameModal();
|
26096
26157
|
init_TileMenuContent();
|
26097
26158
|
init_useDropdownList();
|
26098
|
-
|
26159
|
+
init_utils5();
|
26099
26160
|
init_TileMenuContent();
|
26100
26161
|
TileMenu = ({
|
26101
26162
|
audioTrackID,
|
@@ -26108,17 +26169,17 @@ var init_TileMenu2 = __esm({
|
|
26108
26169
|
var _a8, _b7;
|
26109
26170
|
const [open, setOpen] = (0, import_react142.useState)(false);
|
26110
26171
|
const { theme: theme2 } = useTheme();
|
26111
|
-
const localPeerID = (0,
|
26172
|
+
const localPeerID = (0, import_react_sdk70.useHMSStore)(import_react_sdk70.selectLocalPeerID);
|
26112
26173
|
const isLocal = localPeerID === peerID;
|
26113
|
-
const { removeOthers } = (0,
|
26114
|
-
const { setVolume, toggleAudio, toggleVideo } = (0,
|
26174
|
+
const { removeOthers } = (0, import_react_sdk70.useHMSStore)(import_react_sdk70.selectPermissions);
|
26175
|
+
const { setVolume, toggleAudio, toggleVideo } = (0, import_react_sdk70.useRemoteAVToggle)(audioTrackID, videoTrackID);
|
26115
26176
|
const showSpotlight = enableSpotlightingPeer;
|
26116
|
-
const isPrimaryVideoTrack = ((_a8 = (0,
|
26177
|
+
const isPrimaryVideoTrack = ((_a8 = (0, import_react_sdk70.useHMSStore)((0, import_react_sdk70.selectVideoTrackByPeerID)(peerID))) == null ? void 0 : _a8.id) === videoTrackID;
|
26117
26178
|
const showPinAction = audioTrackID || videoTrackID && isPrimaryVideoTrack;
|
26118
|
-
const track = (0,
|
26179
|
+
const track = (0, import_react_sdk70.useHMSStore)((0, import_react_sdk70.selectTrackByID)(videoTrackID));
|
26119
26180
|
const hideSimulcastLayers = !((_b7 = track == null ? void 0 : track.layerDefinitions) == null ? void 0 : _b7.length) || track.degraded || !track.enabled;
|
26120
26181
|
const isMobile = (0, import_react_use24.useMedia)(config.media.md);
|
26121
|
-
const peer = (0,
|
26182
|
+
const peer = (0, import_react_sdk70.useHMSStore)((0, import_react_sdk70.selectPeerByID)(peerID));
|
26122
26183
|
const [showNameChangeModal, setShowNameChangeModal] = (0, import_react142.useState)(false);
|
26123
26184
|
useDropdownList({ open, name: "TileMenu" });
|
26124
26185
|
const dragClassName = getDragClassName();
|
@@ -26202,14 +26263,14 @@ var init_peerTileUtils = __esm({
|
|
26202
26263
|
});
|
26203
26264
|
|
26204
26265
|
// src/Prebuilt/components/VideoTile.jsx
|
26205
|
-
var import_react143, import_react_use25,
|
26266
|
+
var import_react143, import_react_use25, import_react_sdk71, import_react_icons73, Tile, PeerMetadata, VideoTile, VideoTile_default;
|
26206
26267
|
var init_VideoTile2 = __esm({
|
26207
26268
|
"src/Prebuilt/components/VideoTile.jsx"() {
|
26208
26269
|
"use strict";
|
26209
26270
|
init_define_process_env();
|
26210
26271
|
import_react143 = __toESM(require("react"));
|
26211
26272
|
import_react_use25 = require("react-use");
|
26212
|
-
|
26273
|
+
import_react_sdk71 = require("@100mslive/react-sdk");
|
26213
26274
|
import_react_icons73 = require("@100mslive/react-icons");
|
26214
26275
|
init_TileConnection();
|
26215
26276
|
init_TileMenu2();
|
@@ -26238,15 +26299,15 @@ var init_VideoTile2 = __esm({
|
|
26238
26299
|
hideAudioMuteOnTile = false,
|
26239
26300
|
hideMetadataOnTile = false
|
26240
26301
|
}) => {
|
26241
|
-
const trackSelector = trackId ? (0,
|
26242
|
-
const track = (0,
|
26243
|
-
const peerName = (0,
|
26244
|
-
const audioTrack = (0,
|
26245
|
-
const localPeerID = (0,
|
26302
|
+
const trackSelector = trackId ? (0, import_react_sdk71.selectVideoTrackByID)(trackId) : (0, import_react_sdk71.selectVideoTrackByPeerID)(peerId);
|
26303
|
+
const track = (0, import_react_sdk71.useHMSStore)(trackSelector);
|
26304
|
+
const peerName = (0, import_react_sdk71.useHMSStore)((0, import_react_sdk71.selectPeerNameByID)(peerId));
|
26305
|
+
const audioTrack = (0, import_react_sdk71.useHMSStore)((0, import_react_sdk71.selectAudioTrackByPeerID)(peerId));
|
26306
|
+
const localPeerID = (0, import_react_sdk71.useHMSStore)(import_react_sdk71.selectLocalPeerID);
|
26246
26307
|
const isAudioOnly = useUISettings(UI_SETTINGS.isAudioOnly);
|
26247
26308
|
const mirrorLocalVideo = useUISettings(UI_SETTINGS.mirrorLocalVideo);
|
26248
26309
|
const showStatsOnTiles = useUISettings(UI_SETTINGS.showStatsOnTiles);
|
26249
|
-
const isAudioMuted = !(0,
|
26310
|
+
const isAudioMuted = !(0, import_react_sdk71.useHMSStore)((0, import_react_sdk71.selectIsPeerAudioEnabled)(peerId));
|
26250
26311
|
const isVideoMuted = !(track == null ? void 0 : track.enabled);
|
26251
26312
|
const [isMouseHovered, setIsMouseHovered] = (0, import_react143.useState)(false);
|
26252
26313
|
const isVideoDegraded = track == null ? void 0 : track.degraded;
|
@@ -26257,7 +26318,7 @@ var init_VideoTile2 = __esm({
|
|
26257
26318
|
videoTrackID: track == null ? void 0 : track.id,
|
26258
26319
|
audioTrackID: audioTrack == null ? void 0 : audioTrack.id
|
26259
26320
|
});
|
26260
|
-
const spotlighted = (0,
|
26321
|
+
const spotlighted = (0, import_react_sdk71.useHMSStore)((0, import_react_sdk71.selectSessionStore)("spotlight" /* SPOTLIGHT */)) === peerId;
|
26261
26322
|
const label = getVideoTileLabel({
|
26262
26323
|
peerName,
|
26263
26324
|
track,
|
@@ -26333,9 +26394,9 @@ var init_VideoTile2 = __esm({
|
|
26333
26394
|
);
|
26334
26395
|
};
|
26335
26396
|
PeerMetadata = ({ peerId, size }) => {
|
26336
|
-
const metaData = (0,
|
26397
|
+
const metaData = (0, import_react_sdk71.useHMSStore)((0, import_react_sdk71.selectPeerMetadata)(peerId));
|
26337
26398
|
const isBRB = (metaData == null ? void 0 : metaData.isBRBOn) || false;
|
26338
|
-
const isHandRaised = (0,
|
26399
|
+
const isHandRaised = (0, import_react_sdk71.useHMSStore)((0, import_react_sdk71.selectHasPeerHandRaised)(peerId));
|
26339
26400
|
return /* @__PURE__ */ import_react143.default.createElement(import_react143.Fragment, null, isHandRaised ? /* @__PURE__ */ import_react143.default.createElement(StyledVideoTile.AttributeBox, { size, "data-testid": "raiseHand_icon_onTile" }, /* @__PURE__ */ import_react143.default.createElement(import_react_icons73.HandIcon, { width: 24, height: 24 })) : null, isBRB ? /* @__PURE__ */ import_react143.default.createElement(StyledVideoTile.AttributeBox, { size, "data-testid": "brb_icon_onTile" }, /* @__PURE__ */ import_react143.default.createElement(import_react_icons73.BrbTileIcon, { width: 22, height: 22 })) : null);
|
26340
26401
|
};
|
26341
26402
|
VideoTile = import_react143.default.memo(Tile);
|
@@ -26539,7 +26600,7 @@ var init_constants3 = __esm({
|
|
26539
26600
|
});
|
26540
26601
|
|
26541
26602
|
// src/Prebuilt/components/VirtualBackground/VBPicker.tsx
|
26542
|
-
var import_react146, import_hms_virtual_background3,
|
26603
|
+
var import_react146, import_hms_virtual_background3, import_react_sdk72, import_react_icons74, iconDims, VBPicker;
|
26543
26604
|
var init_VBPicker = __esm({
|
26544
26605
|
"src/Prebuilt/components/VirtualBackground/VBPicker.tsx"() {
|
26545
26606
|
"use strict";
|
@@ -26547,7 +26608,7 @@ var init_VBPicker = __esm({
|
|
26547
26608
|
import_react146 = __toESM(require("react"));
|
26548
26609
|
init_dist();
|
26549
26610
|
import_hms_virtual_background3 = require("@100mslive/hms-virtual-background");
|
26550
|
-
|
26611
|
+
import_react_sdk72 = require("@100mslive/react-sdk");
|
26551
26612
|
import_react_icons74 = require("@100mslive/react-icons");
|
26552
26613
|
init_src();
|
26553
26614
|
init_Text2();
|
@@ -26561,24 +26622,24 @@ var init_VBPicker = __esm({
|
|
26561
26622
|
VBPicker = ({ backgroundMedia = [] }) => {
|
26562
26623
|
var _a8, _b7;
|
26563
26624
|
const toggleVB = useSidepaneToggle(SIDE_PANE_OPTIONS.VB);
|
26564
|
-
const hmsActions = (0,
|
26565
|
-
const localPeer = (0,
|
26566
|
-
const role = (0,
|
26567
|
-
const isVideoOn = (0,
|
26625
|
+
const hmsActions = (0, import_react_sdk72.useHMSActions)();
|
26626
|
+
const localPeer = (0, import_react_sdk72.useHMSStore)(import_react_sdk72.selectLocalPeer);
|
26627
|
+
const role = (0, import_react_sdk72.useHMSStore)(Ft);
|
26628
|
+
const isVideoOn = (0, import_react_sdk72.useHMSStore)(import_react_sdk72.selectIsLocalVideoEnabled);
|
26568
26629
|
const mirrorLocalVideo = useUISettings(UI_SETTINGS.mirrorLocalVideo);
|
26569
|
-
const trackSelector = (0,
|
26570
|
-
const track = (0,
|
26630
|
+
const trackSelector = (0, import_react_sdk72.selectVideoTrackByID)(localPeer == null ? void 0 : localPeer.videoTrack);
|
26631
|
+
const track = (0, import_react_sdk72.useHMSStore)(trackSelector);
|
26571
26632
|
const [blurAmount, setBlurAmount] = (0, import_react146.useState)(VBHandler.getBlurAmount() || 0.5);
|
26572
|
-
const roomState = (0,
|
26573
|
-
const isLargeRoom = (0,
|
26574
|
-
const isEffectsEnabled = (0,
|
26575
|
-
const effectsKey = (0,
|
26576
|
-
const isPluginAdded = (0,
|
26633
|
+
const roomState = (0, import_react_sdk72.useHMSStore)(import_react_sdk72.selectRoomState);
|
26634
|
+
const isLargeRoom = (0, import_react_sdk72.useHMSStore)(import_react_sdk72.selectIsLargeRoom);
|
26635
|
+
const isEffectsEnabled = (0, import_react_sdk72.useHMSStore)(Qn);
|
26636
|
+
const effectsKey = (0, import_react_sdk72.useHMSStore)(zn);
|
26637
|
+
const isPluginAdded = (0, import_react_sdk72.useHMSStore)((0, import_react_sdk72.selectIsLocalVideoPluginPresent)(((_a8 = VBHandler) == null ? void 0 : _a8.getName()) || ""));
|
26577
26638
|
const [activeBackground, setActiveBackground] = (0, import_react146.useState)(
|
26578
26639
|
((_b7 = VBHandler) == null ? void 0 : _b7.getBackground()) || import_hms_virtual_background3.HMSVirtualBackgroundTypes.NONE
|
26579
26640
|
);
|
26580
26641
|
const mediaList = backgroundMedia.length ? backgroundMedia.map((media) => media.url || "") : defaultMedia2;
|
26581
|
-
const inPreview = roomState ===
|
26642
|
+
const inPreview = roomState === import_react_sdk72.HMSRoomState.Preview;
|
26582
26643
|
const showVideoTile = isVideoOn && isLargeRoom && !inPreview;
|
26583
26644
|
(0, import_react146.useEffect)(() => {
|
26584
26645
|
if (!(track == null ? void 0 : track.id)) {
|
@@ -26694,14 +26755,14 @@ var init_VBPicker = __esm({
|
|
26694
26755
|
});
|
26695
26756
|
|
26696
26757
|
// src/Prebuilt/layouts/SidePane.tsx
|
26697
|
-
var import_react147, import_react_use26,
|
26758
|
+
var import_react147, import_react_use26, import_react_sdk73, SidePane, SidePane_default;
|
26698
26759
|
var init_SidePane = __esm({
|
26699
26760
|
"src/Prebuilt/layouts/SidePane.tsx"() {
|
26700
26761
|
"use strict";
|
26701
26762
|
init_define_process_env();
|
26702
26763
|
import_react147 = __toESM(require("react"));
|
26703
26764
|
import_react_use26 = require("react-use");
|
26704
|
-
|
26765
|
+
import_react_sdk73 = require("@100mslive/react-sdk");
|
26705
26766
|
init_Polls();
|
26706
26767
|
init_SidePaneTabs();
|
26707
26768
|
init_VideoTile2();
|
@@ -26718,9 +26779,9 @@ var init_SidePane = __esm({
|
|
26718
26779
|
}) => {
|
26719
26780
|
var _a8, _b7, _c, _d, _e, _f;
|
26720
26781
|
const isMobile = (0, import_react_use26.useMedia)(config.media.md);
|
26721
|
-
const sidepane = (0,
|
26722
|
-
const activeScreensharePeerId = (0,
|
26723
|
-
const trackId = (_a8 = (0,
|
26782
|
+
const sidepane = (0, import_react_sdk73.useHMSStore)((0, import_react_sdk73.selectAppData)(APP_DATA.sidePane));
|
26783
|
+
const activeScreensharePeerId = (0, import_react_sdk73.useHMSStore)((0, import_react_sdk73.selectAppData)(APP_DATA.activeScreensharePeerId));
|
26784
|
+
const trackId = (_a8 = (0, import_react_sdk73.useHMSStore)((0, import_react_sdk73.selectVideoTrackByPeerID)(activeScreensharePeerId))) == null ? void 0 : _a8.id;
|
26724
26785
|
const { elements } = useRoomLayoutConferencingScreen();
|
26725
26786
|
const { elements: preview_elements } = useRoomLayoutPreviewScreen();
|
26726
26787
|
const backgroundMedia = ((_c = (_b7 = preview_elements == null ? void 0 : preview_elements.virtual_background) == null ? void 0 : _b7.background_media) == null ? void 0 : _c.length) ? (_d = preview_elements == null ? void 0 : preview_elements.virtual_background) == null ? void 0 : _d.background_media : ((_e = elements == null ? void 0 : elements.virtual_background) == null ? void 0 : _e.background_media) || [];
|
@@ -26868,18 +26929,18 @@ var init_FullPageProgress = __esm({
|
|
26868
26929
|
});
|
26869
26930
|
|
26870
26931
|
// src/Prebuilt/components/Header/HeaderComponents.jsx
|
26871
|
-
var import_react150,
|
26932
|
+
var import_react150, import_react_sdk74, import_react_icons75, SpeakerTag, LogoImg, Logo;
|
26872
26933
|
var init_HeaderComponents = __esm({
|
26873
26934
|
"src/Prebuilt/components/Header/HeaderComponents.jsx"() {
|
26874
26935
|
"use strict";
|
26875
26936
|
init_define_process_env();
|
26876
26937
|
import_react150 = __toESM(require("react"));
|
26877
|
-
|
26938
|
+
import_react_sdk74 = require("@100mslive/react-sdk");
|
26878
26939
|
import_react_icons75 = require("@100mslive/react-icons");
|
26879
26940
|
init_src();
|
26880
26941
|
init_roomLayoutProvider();
|
26881
26942
|
SpeakerTag = () => {
|
26882
|
-
const dominantSpeaker = (0,
|
26943
|
+
const dominantSpeaker = (0, import_react_sdk74.useHMSStore)(import_react_sdk74.selectDominantSpeaker);
|
26883
26944
|
return dominantSpeaker && dominantSpeaker.name && /* @__PURE__ */ import_react150.default.createElement(
|
26884
26945
|
Flex,
|
26885
26946
|
{
|
@@ -26926,7 +26987,7 @@ var init_HeaderComponents = __esm({
|
|
26926
26987
|
});
|
26927
26988
|
|
26928
26989
|
// src/Prebuilt/components/Preview/PreviewForm.tsx
|
26929
|
-
var import_react151, import_react_use27, import_join_form3,
|
26990
|
+
var import_react151, import_react_use27, import_join_form3, import_react_sdk75, import_react_icons76, PreviewForm, Form, PreviewForm_default;
|
26930
26991
|
var init_PreviewForm = __esm({
|
26931
26992
|
"src/Prebuilt/components/Preview/PreviewForm.tsx"() {
|
26932
26993
|
"use strict";
|
@@ -26934,7 +26995,7 @@ var init_PreviewForm = __esm({
|
|
26934
26995
|
import_react151 = __toESM(require("react"));
|
26935
26996
|
import_react_use27 = require("react-use");
|
26936
26997
|
import_join_form3 = require("@100mslive/types-prebuilt/elements/join_form");
|
26937
|
-
|
26998
|
+
import_react_sdk75 = require("@100mslive/react-sdk");
|
26938
26999
|
import_react_icons76 = require("@100mslive/react-icons");
|
26939
27000
|
init_src();
|
26940
27001
|
init_roomLayoutProvider();
|
@@ -26953,7 +27014,7 @@ var init_PreviewForm = __esm({
|
|
26953
27014
|
e.preventDefault();
|
26954
27015
|
};
|
26955
27016
|
const isMobile = (0, import_react_use27.useMedia)(config.media.md);
|
26956
|
-
const { isHLSRunning, isRTMPRunning, isHLSRecordingOn, isBrowserRecordingOn } = (0,
|
27017
|
+
const { isHLSRunning, isRTMPRunning, isHLSRecordingOn, isBrowserRecordingOn } = (0, import_react_sdk75.useRecordingStreaming)();
|
26957
27018
|
const layout = useRoomLayout();
|
26958
27019
|
const { join_form: joinForm = {} } = ((_c = (_b7 = (_a8 = layout == null ? void 0 : layout.screens) == null ? void 0 : _a8.preview) == null ? void 0 : _b7.default) == null ? void 0 : _c.elements) || {};
|
26959
27020
|
const showGoLive = (joinForm == null ? void 0 : joinForm.join_btn_type) === import_join_form3.JoinForm_JoinBtnType.JOIN_BTN_TYPE_JOIN_AND_GO_LIVE && !isHLSRunning && !isRTMPRunning && !isHLSRecordingOn && !isBrowserRecordingOn;
|
@@ -27005,14 +27066,14 @@ var init_PreviewForm = __esm({
|
|
27005
27066
|
});
|
27006
27067
|
|
27007
27068
|
// src/Prebuilt/components/Preview/PreviewJoin.tsx
|
27008
|
-
var import_react152, import_react_use28,
|
27069
|
+
var import_react152, import_react_use28, import_react_sdk76, import_react_icons77, getParticipantChipContent, useLocalTileAspectRatio, PreviewJoin, Container4, PreviewTile, PreviewControls, PreviewSettings, PreviewJoin_default;
|
27009
27070
|
var init_PreviewJoin = __esm({
|
27010
27071
|
"src/Prebuilt/components/Preview/PreviewJoin.tsx"() {
|
27011
27072
|
"use strict";
|
27012
27073
|
init_define_process_env();
|
27013
27074
|
import_react152 = __toESM(require("react"));
|
27014
27075
|
import_react_use28 = require("react-use");
|
27015
|
-
|
27076
|
+
import_react_sdk76 = require("@100mslive/react-sdk");
|
27016
27077
|
import_react_icons77 = require("@100mslive/react-icons");
|
27017
27078
|
init_src();
|
27018
27079
|
init_AudioLevel2();
|
@@ -27040,8 +27101,8 @@ var init_PreviewJoin = __esm({
|
|
27040
27101
|
return `${formattedNum} other${parseInt(formattedNum) === 1 ? "" : "s"} in the session`;
|
27041
27102
|
};
|
27042
27103
|
useLocalTileAspectRatio = () => {
|
27043
|
-
const localPeer = (0,
|
27044
|
-
const videoTrack = (0,
|
27104
|
+
const localPeer = (0, import_react_sdk76.useHMSStore)(import_react_sdk76.selectLocalPeer);
|
27105
|
+
const videoTrack = (0, import_react_sdk76.useHMSStore)((0, import_react_sdk76.selectVideoTrackByID)(localPeer == null ? void 0 : localPeer.videoTrack));
|
27045
27106
|
const isMobile = (0, import_react_use28.useMedia)(config.media.md);
|
27046
27107
|
let aspectRatio = 0;
|
27047
27108
|
if ((videoTrack == null ? void 0 : videoTrack.width) && (videoTrack == null ? void 0 : videoTrack.height)) {
|
@@ -27060,14 +27121,14 @@ var init_PreviewJoin = __esm({
|
|
27060
27121
|
UserPreferencesKeys.PREVIEW,
|
27061
27122
|
defaultPreviewPreference
|
27062
27123
|
);
|
27063
|
-
const { isStreamingOn } = (0,
|
27124
|
+
const { isStreamingOn } = (0, import_react_sdk76.useRecordingStreaming)();
|
27064
27125
|
const authToken = useAuthToken();
|
27065
27126
|
const [name, setName] = (0, import_react152.useState)(initialName || previewPreference.name);
|
27066
|
-
const { toggleAudio, toggleVideo } = (0,
|
27127
|
+
const { toggleAudio, toggleVideo } = (0, import_react_sdk76.useAVToggle)();
|
27067
27128
|
const [previewError, setPreviewError] = (0, import_react152.useState)(false);
|
27068
27129
|
const { endpoints } = useHMSPrebuiltContext();
|
27069
|
-
const { peerCount } = (0,
|
27070
|
-
const { enableJoin, preview, join } = (0,
|
27130
|
+
const { peerCount } = (0, import_react_sdk76.useParticipants)();
|
27131
|
+
const { enableJoin, preview, join } = (0, import_react_sdk76.usePreviewJoin)({
|
27071
27132
|
name,
|
27072
27133
|
token: authToken,
|
27073
27134
|
initEndpoint: endpoints == null ? void 0 : endpoints.init,
|
@@ -27084,7 +27145,7 @@ var init_PreviewJoin = __esm({
|
|
27084
27145
|
},
|
27085
27146
|
asRole
|
27086
27147
|
});
|
27087
|
-
const roomState = (0,
|
27148
|
+
const roomState = (0, import_react_sdk76.useHMSStore)(import_react_sdk76.selectRoomState);
|
27088
27149
|
const savePreferenceAndJoin = (0, import_react152.useCallback)(() => {
|
27089
27150
|
setPreviewPreference({
|
27090
27151
|
name
|
@@ -27108,7 +27169,7 @@ var init_PreviewJoin = __esm({
|
|
27108
27169
|
setName(initialName);
|
27109
27170
|
}
|
27110
27171
|
}, [initialName]);
|
27111
|
-
return roomState ===
|
27172
|
+
return roomState === import_react_sdk76.HMSRoomState.Preview ? /* @__PURE__ */ import_react152.default.createElement(Flex, { justify: "center", css: { size: "100%", position: "relative" } }, /* @__PURE__ */ import_react152.default.createElement(Container4, { css: { h: "100%", pt: "$10", "@md": { justifyContent: "space-between" } } }, toggleVideo ? null : /* @__PURE__ */ import_react152.default.createElement(Box, null), /* @__PURE__ */ import_react152.default.createElement(Flex, { direction: "column", justify: "center", css: { w: "100%", maxWidth: "640px" } }, /* @__PURE__ */ import_react152.default.createElement(Logo, null), /* @__PURE__ */ import_react152.default.createElement(
|
27112
27173
|
Text,
|
27113
27174
|
{
|
27114
27175
|
variant: "h4",
|
@@ -27150,12 +27211,12 @@ var init_PreviewJoin = __esm({
|
|
27150
27211
|
px: "$10"
|
27151
27212
|
}));
|
27152
27213
|
PreviewTile = ({ name, error }) => {
|
27153
|
-
const localPeer = (0,
|
27154
|
-
const { isLocalAudioEnabled, toggleAudio } = (0,
|
27155
|
-
const isVideoOn = (0,
|
27214
|
+
const localPeer = (0, import_react_sdk76.useHMSStore)(import_react_sdk76.selectLocalPeer);
|
27215
|
+
const { isLocalAudioEnabled, toggleAudio } = (0, import_react_sdk76.useAVToggle)();
|
27216
|
+
const isVideoOn = (0, import_react_sdk76.useHMSStore)(import_react_sdk76.selectIsLocalVideoEnabled);
|
27156
27217
|
const mirrorLocalVideo = useUISettings(UI_SETTINGS.mirrorLocalVideo);
|
27157
|
-
const trackSelector = (0,
|
27158
|
-
const track = (0,
|
27218
|
+
const trackSelector = (0, import_react_sdk76.selectVideoTrackByID)(localPeer == null ? void 0 : localPeer.videoTrack);
|
27219
|
+
const track = (0, import_react_sdk76.useHMSStore)(trackSelector);
|
27159
27220
|
const showMuteIcon = !isLocalAudioEnabled || !toggleAudio;
|
27160
27221
|
const aspectRatio = useLocalTileAspectRatio();
|
27161
27222
|
const [ref, { width: calculatedWidth, height: calculatedHeight }] = (0, import_react_use28.useMeasure)();
|
@@ -27252,13 +27313,13 @@ var init_RequestPrompt = __esm({
|
|
27252
27313
|
});
|
27253
27314
|
|
27254
27315
|
// src/Prebuilt/components/RoleChangeRequest/RoleChangeRequestModal.tsx
|
27255
|
-
var import_react154,
|
27316
|
+
var import_react154, import_react_sdk77, RoleChangeRequestModal;
|
27256
27317
|
var init_RoleChangeRequestModal = __esm({
|
27257
27318
|
"src/Prebuilt/components/RoleChangeRequest/RoleChangeRequestModal.tsx"() {
|
27258
27319
|
"use strict";
|
27259
27320
|
init_define_process_env();
|
27260
27321
|
import_react154 = __toESM(require("react"));
|
27261
|
-
|
27322
|
+
import_react_sdk77 = require("@100mslive/react-sdk");
|
27262
27323
|
init_src();
|
27263
27324
|
init_PreviewJoin();
|
27264
27325
|
init_RequestPrompt();
|
@@ -27266,13 +27327,13 @@ var init_RoleChangeRequestModal = __esm({
|
|
27266
27327
|
init_useMetadata();
|
27267
27328
|
init_constants();
|
27268
27329
|
RoleChangeRequestModal = () => {
|
27269
|
-
const hmsActions = (0,
|
27330
|
+
const hmsActions = (0, import_react_sdk77.useHMSActions)();
|
27270
27331
|
const { updateMetaData } = useMyMetadata();
|
27271
|
-
const isPreview = (0,
|
27272
|
-
const currentRole = (0,
|
27273
|
-
const roleChangeRequest = (0,
|
27274
|
-
const name = (0,
|
27275
|
-
const { sendEvent } = (0,
|
27332
|
+
const isPreview = (0, import_react_sdk77.useHMSStore)(import_react_sdk77.selectIsInPreview);
|
27333
|
+
const currentRole = (0, import_react_sdk77.useHMSStore)(import_react_sdk77.selectLocalPeerRoleName);
|
27334
|
+
const roleChangeRequest = (0, import_react_sdk77.useHMSStore)(import_react_sdk77.selectRoleChangeRequest);
|
27335
|
+
const name = (0, import_react_sdk77.useHMSStore)(import_react_sdk77.selectLocalPeerName);
|
27336
|
+
const { sendEvent } = (0, import_react_sdk77.useCustomEvent)({ type: ROLE_CHANGE_DECLINED });
|
27276
27337
|
const { elements = {} } = useRoomLayoutPreviewScreen();
|
27277
27338
|
const { virtual_background } = elements || {};
|
27278
27339
|
(0, import_react154.useEffect)(() => {
|
@@ -27363,7 +27424,7 @@ var init_useVideoTileLayout = __esm({
|
|
27363
27424
|
});
|
27364
27425
|
|
27365
27426
|
// src/Prebuilt/components/InsetTile.tsx
|
27366
|
-
var import_react156, import_react_draggable, import_react_use30,
|
27427
|
+
var import_react156, import_react_draggable, import_react_use30, import_react_sdk78, import_react_icons78, MinimisedTile, insetHeightPx, insetMaxWidthPx, defaultMobileAspectRatio, desktopAspectRatio, InsetTile;
|
27367
27428
|
var init_InsetTile = __esm({
|
27368
27429
|
"src/Prebuilt/components/InsetTile.tsx"() {
|
27369
27430
|
"use strict";
|
@@ -27371,7 +27432,7 @@ var init_InsetTile = __esm({
|
|
27371
27432
|
import_react156 = __toESM(require("react"));
|
27372
27433
|
import_react_draggable = __toESM(require("react-draggable"));
|
27373
27434
|
import_react_use30 = require("react-use");
|
27374
|
-
|
27435
|
+
import_react_sdk78 = require("@100mslive/react-sdk");
|
27375
27436
|
import_react_icons78 = require("@100mslive/react-icons");
|
27376
27437
|
init_Layout();
|
27377
27438
|
init_Text2();
|
@@ -27400,10 +27461,10 @@ var init_InsetTile = __esm({
|
|
27400
27461
|
InsetTile = () => {
|
27401
27462
|
const isMobile = (0, import_react_use30.useMedia)(config.media.md);
|
27402
27463
|
const isLandscape = (0, import_react_use30.useMedia)(config.media.ls);
|
27403
|
-
const localPeer = (0,
|
27464
|
+
const localPeer = (0, import_react_sdk78.useHMSStore)(import_react_sdk78.selectLocalPeer);
|
27404
27465
|
const [minimised, setMinimised] = useSetAppDataByKey(APP_DATA.minimiseInset);
|
27405
|
-
const videoTrack = (0,
|
27406
|
-
const isAllowedToPublish = (0,
|
27466
|
+
const videoTrack = (0, import_react_sdk78.useHMSStore)((0, import_react_sdk78.selectVideoTrackByID)(localPeer == null ? void 0 : localPeer.videoTrack));
|
27467
|
+
const isAllowedToPublish = (0, import_react_sdk78.useHMSStore)(import_react_sdk78.selectIsAllowedToPublish);
|
27407
27468
|
const videoTileProps = useVideoTileContext();
|
27408
27469
|
let aspectRatio = isMobile ? defaultMobileAspectRatio : desktopAspectRatio;
|
27409
27470
|
if ((videoTrack == null ? void 0 : videoTrack.width) && (videoTrack == null ? void 0 : videoTrack.height) && !isMobile) {
|
@@ -27574,21 +27635,21 @@ var init_Grid = __esm({
|
|
27574
27635
|
});
|
27575
27636
|
|
27576
27637
|
// src/Prebuilt/components/hooks/useTileLayout.tsx
|
27577
|
-
var import_react159, import_react_use31,
|
27638
|
+
var import_react159, import_react_use31, import_react_sdk79, aspectRatioConfig, usePagesWithTiles, useTileLayout;
|
27578
27639
|
var init_useTileLayout = __esm({
|
27579
27640
|
"src/Prebuilt/components/hooks/useTileLayout.tsx"() {
|
27580
27641
|
"use strict";
|
27581
27642
|
init_define_process_env();
|
27582
27643
|
import_react159 = require("react");
|
27583
27644
|
import_react_use31 = require("react-use");
|
27584
|
-
|
27645
|
+
import_react_sdk79 = require("@100mslive/react-sdk");
|
27585
27646
|
init_Theme();
|
27586
27647
|
aspectRatioConfig = { default: [1 / 1, 4 / 3, 16 / 9], mobile: [1 / 1, 3 / 4, 9 / 16] };
|
27587
27648
|
usePagesWithTiles = ({ peers, maxTileCount }) => {
|
27588
|
-
const vanillaStore = (0,
|
27589
|
-
const tracksMap = vanillaStore.getState(
|
27649
|
+
const vanillaStore = (0, import_react_sdk79.useHMSVanillaStore)();
|
27650
|
+
const tracksMap = vanillaStore.getState(import_react_sdk79.selectTracksMap);
|
27590
27651
|
const peersWithTiles = (0, import_react159.useMemo)(
|
27591
|
-
() => (0,
|
27652
|
+
() => (0, import_react_sdk79.getPeersWithTiles)(peers, tracksMap, () => false),
|
27592
27653
|
[peers, tracksMap]
|
27593
27654
|
);
|
27594
27655
|
const noOfPages = Math.ceil(peersWithTiles.length / maxTileCount);
|
@@ -27611,7 +27672,7 @@ var init_useTileLayout = __esm({
|
|
27611
27672
|
maxTileCount,
|
27612
27673
|
edgeToEdge = false
|
27613
27674
|
}) => {
|
27614
|
-
const vanillaStore = (0,
|
27675
|
+
const vanillaStore = (0, import_react_sdk79.useHMSVanillaStore)();
|
27615
27676
|
const [ref, { width, height }] = (0, import_react_use31.useMeasure)();
|
27616
27677
|
const isMobile = (0, import_react_use31.useMedia)(config.media.lg);
|
27617
27678
|
const [pagesWithTiles, setPagesWithTiles] = (0, import_react159.useState)([]);
|
@@ -27684,7 +27745,7 @@ var init_useTileLayout = __esm({
|
|
27684
27745
|
// src/Prebuilt/components/VideoLayouts/EqualProminence.tsx
|
27685
27746
|
function EqualProminence({ isInsetEnabled = false, peers, onPageChange, onPageSize, edgeToEdge }) {
|
27686
27747
|
var _a8;
|
27687
|
-
const localPeer = (0,
|
27748
|
+
const localPeer = (0, import_react_sdk80.useHMSStore)(import_react_sdk80.selectLocalPeer);
|
27688
27749
|
const isMobile = (0, import_react_use32.useMedia)(config.media.md);
|
27689
27750
|
let maxTileCount = useUISettings(UI_SETTINGS.maxTileCount);
|
27690
27751
|
maxTileCount = isMobile ? Math.min(maxTileCount, 6) : maxTileCount;
|
@@ -27726,14 +27787,14 @@ function EqualProminence({ isInsetEnabled = false, peers, onPageChange, onPageSi
|
|
27726
27787
|
}
|
27727
27788
|
), isInsetEnabled && pageList.length > 0 && pageList[0][0].peer.id !== (localPeer == null ? void 0 : localPeer.id) && /* @__PURE__ */ import_react160.default.createElement(InsetTile, null));
|
27728
27789
|
}
|
27729
|
-
var import_react160, import_react_use32,
|
27790
|
+
var import_react160, import_react_use32, import_react_sdk80;
|
27730
27791
|
var init_EqualProminence = __esm({
|
27731
27792
|
"src/Prebuilt/components/VideoLayouts/EqualProminence.tsx"() {
|
27732
27793
|
"use strict";
|
27733
27794
|
init_define_process_env();
|
27734
27795
|
import_react160 = __toESM(require("react"));
|
27735
27796
|
import_react_use32 = require("react-use");
|
27736
|
-
|
27797
|
+
import_react_sdk80 = require("@100mslive/react-sdk");
|
27737
27798
|
init_Layout();
|
27738
27799
|
init_Theme();
|
27739
27800
|
init_InsetTile();
|
@@ -27910,7 +27971,7 @@ function RoleProminence({
|
|
27910
27971
|
}) {
|
27911
27972
|
var _a8;
|
27912
27973
|
const { prominentPeers, secondaryPeers } = useRoleProminencePeers(prominentRoles, peers, isInsetEnabled);
|
27913
|
-
const localPeer = (0,
|
27974
|
+
const localPeer = (0, import_react_sdk81.useHMSStore)(import_react_sdk81.selectLocalPeer);
|
27914
27975
|
const maxTileCount = 4;
|
27915
27976
|
const pageList = usePagesWithTiles({
|
27916
27977
|
peers: prominentPeers,
|
@@ -27939,13 +28000,13 @@ function RoleProminence({
|
|
27939
28000
|
}
|
27940
28001
|
), /* @__PURE__ */ import_react164.default.createElement(SecondaryTiles, { peers: secondaryPeers, isInsetEnabled, edgeToEdge }), isInsetEnabled && localPeer && !prominentPeers.includes(localPeer) && /* @__PURE__ */ import_react164.default.createElement(InsetTile, null));
|
27941
28002
|
}
|
27942
|
-
var import_react164,
|
28003
|
+
var import_react164, import_react_sdk81;
|
27943
28004
|
var init_RoleProminence = __esm({
|
27944
28005
|
"src/Prebuilt/components/VideoLayouts/RoleProminence.tsx"() {
|
27945
28006
|
"use strict";
|
27946
28007
|
init_define_process_env();
|
27947
28008
|
import_react164 = __toESM(require("react"));
|
27948
|
-
|
28009
|
+
import_react_sdk81 = require("@100mslive/react-sdk");
|
27949
28010
|
init_InsetTile();
|
27950
28011
|
init_Pagination2();
|
27951
28012
|
init_SecondaryTiles();
|
@@ -27957,19 +28018,19 @@ var init_RoleProminence = __esm({
|
|
27957
28018
|
});
|
27958
28019
|
|
27959
28020
|
// src/Prebuilt/components/ScreenshareDisplay.jsx
|
27960
|
-
var import_react165,
|
28021
|
+
var import_react165, import_react_sdk82, import_react_icons80, ScreenshareDisplay;
|
27961
28022
|
var init_ScreenshareDisplay = __esm({
|
27962
28023
|
"src/Prebuilt/components/ScreenshareDisplay.jsx"() {
|
27963
28024
|
"use strict";
|
27964
28025
|
init_define_process_env();
|
27965
28026
|
import_react165 = __toESM(require("react"));
|
27966
|
-
|
28027
|
+
import_react_sdk82 = require("@100mslive/react-sdk");
|
27967
28028
|
import_react_icons80 = require("@100mslive/react-icons");
|
27968
28029
|
init_Button2();
|
27969
28030
|
init_Layout();
|
27970
28031
|
init_Text2();
|
27971
28032
|
ScreenshareDisplay = () => {
|
27972
|
-
const hmsActions = (0,
|
28033
|
+
const hmsActions = (0, import_react_sdk82.useHMSActions)();
|
27973
28034
|
return /* @__PURE__ */ import_react165.default.createElement(
|
27974
28035
|
Flex,
|
27975
28036
|
{
|
@@ -28003,7 +28064,7 @@ var init_ScreenshareDisplay = __esm({
|
|
28003
28064
|
});
|
28004
28065
|
|
28005
28066
|
// src/Prebuilt/components/ScreenshareTile.jsx
|
28006
|
-
var import_react166, import_react_use34, import_screenfull2,
|
28067
|
+
var import_react166, import_react_use34, import_screenfull2, import_react_sdk83, import_react_icons81, labelStyles, Tile2, ScreenshareTile, ScreenshareTile_default;
|
28007
28068
|
var init_ScreenshareTile = __esm({
|
28008
28069
|
"src/Prebuilt/components/ScreenshareTile.jsx"() {
|
28009
28070
|
"use strict";
|
@@ -28011,7 +28072,7 @@ var init_ScreenshareTile = __esm({
|
|
28011
28072
|
import_react166 = __toESM(require("react"));
|
28012
28073
|
import_react_use34 = require("react-use");
|
28013
28074
|
import_screenfull2 = __toESM(require("screenfull"));
|
28014
|
-
|
28075
|
+
import_react_sdk83 = require("@100mslive/react-sdk");
|
28015
28076
|
import_react_icons81 = require("@100mslive/react-icons");
|
28016
28077
|
init_TileMenu2();
|
28017
28078
|
init_Stats2();
|
@@ -28030,9 +28091,9 @@ var init_ScreenshareTile = __esm({
|
|
28030
28091
|
flexShrink: 0
|
28031
28092
|
};
|
28032
28093
|
Tile2 = ({ peerId, width = "100%", height = "100%" }) => {
|
28033
|
-
const isLocal = (0,
|
28034
|
-
const track = (0,
|
28035
|
-
const peer = (0,
|
28094
|
+
const isLocal = (0, import_react_sdk83.useHMSStore)(import_react_sdk83.selectLocalPeerID) === peerId;
|
28095
|
+
const track = (0, import_react_sdk83.useHMSStore)((0, import_react_sdk83.selectScreenShareByPeerID)(peerId));
|
28096
|
+
const peer = (0, import_react_sdk83.useHMSStore)((0, import_react_sdk83.selectPeerByID)(peerId));
|
28036
28097
|
const isAudioOnly = useUISettings(UI_SETTINGS.isAudioOnly);
|
28037
28098
|
const [isMouseHovered, setIsMouseHovered] = (0, import_react166.useState)(false);
|
28038
28099
|
const showStatsOnTiles = useUISettings(UI_SETTINGS.showStatsOnTiles);
|
@@ -28042,7 +28103,7 @@ var init_ScreenshareTile = __esm({
|
|
28042
28103
|
onClose: () => setFullscreen(false)
|
28043
28104
|
});
|
28044
28105
|
const isFullScreenSupported = import_screenfull2.default.isEnabled;
|
28045
|
-
const audioTrack = (0,
|
28106
|
+
const audioTrack = (0, import_react_sdk83.useHMSStore)((0, import_react_sdk83.selectScreenShareAudioByPeerID)(peer == null ? void 0 : peer.id));
|
28046
28107
|
if (isLocal && !["browser", "window", "application"].includes(track == null ? void 0 : track.displaySurface)) {
|
28047
28108
|
return /* @__PURE__ */ import_react166.default.createElement(ScreenshareDisplay, null);
|
28048
28109
|
}
|
@@ -28096,14 +28157,14 @@ var init_ScreenshareTile = __esm({
|
|
28096
28157
|
});
|
28097
28158
|
|
28098
28159
|
// src/Prebuilt/components/VideoLayouts/ScreenshareLayout.tsx
|
28099
|
-
var import_react167, import_react_use35,
|
28160
|
+
var import_react167, import_react_use35, import_react_sdk84, ScreenshareLayout;
|
28100
28161
|
var init_ScreenshareLayout = __esm({
|
28101
28162
|
"src/Prebuilt/components/VideoLayouts/ScreenshareLayout.tsx"() {
|
28102
28163
|
"use strict";
|
28103
28164
|
init_define_process_env();
|
28104
28165
|
import_react167 = __toESM(require("react"));
|
28105
28166
|
import_react_use35 = require("react-use");
|
28106
|
-
|
28167
|
+
import_react_sdk84 = require("@100mslive/react-sdk");
|
28107
28168
|
init_Theme();
|
28108
28169
|
init_Pagination2();
|
28109
28170
|
init_ScreenshareTile();
|
@@ -28113,7 +28174,7 @@ var init_ScreenshareLayout = __esm({
|
|
28113
28174
|
init_constants();
|
28114
28175
|
ScreenshareLayout = ({ peers, onPageChange, onPageSize, edgeToEdge }) => {
|
28115
28176
|
var _a8;
|
28116
|
-
const peersSharing = (0,
|
28177
|
+
const peersSharing = (0, import_react_sdk84.useHMSStore)(import_react_sdk84.selectPeersScreenSharing);
|
28117
28178
|
const [, setActiveScreenSharePeer] = useSetAppDataByKey(APP_DATA.activeScreensharePeerId);
|
28118
28179
|
const [page, setPage] = (0, import_react167.useState)(0);
|
28119
28180
|
const activeSharePeer = peersSharing[page];
|
@@ -28144,12 +28205,12 @@ var init_ScreenshareLayout = __esm({
|
|
28144
28205
|
});
|
28145
28206
|
|
28146
28207
|
// src/Prebuilt/common/PeersSorter.ts
|
28147
|
-
var
|
28208
|
+
var import_react_sdk85, PeersSorter, PeersSorter_default;
|
28148
28209
|
var init_PeersSorter = __esm({
|
28149
28210
|
"src/Prebuilt/common/PeersSorter.ts"() {
|
28150
28211
|
"use strict";
|
28151
28212
|
init_define_process_env();
|
28152
|
-
|
28213
|
+
import_react_sdk85 = require("@100mslive/react-sdk");
|
28153
28214
|
PeersSorter = class {
|
28154
28215
|
constructor(store) {
|
28155
28216
|
this.storeUnsubscribe = void 0;
|
@@ -28171,7 +28232,7 @@ var init_PeersSorter = __esm({
|
|
28171
28232
|
}
|
28172
28233
|
});
|
28173
28234
|
if (!this.storeUnsubscribe) {
|
28174
|
-
this.storeUnsubscribe = this.store.subscribe(this.onDominantSpeakerChange,
|
28235
|
+
this.storeUnsubscribe = this.store.subscribe(this.onDominantSpeakerChange, import_react_sdk85.selectDominantSpeaker);
|
28175
28236
|
}
|
28176
28237
|
this.moveSpeakerToFront(this.speaker);
|
28177
28238
|
};
|
@@ -28245,13 +28306,13 @@ var init_PeersSorter = __esm({
|
|
28245
28306
|
});
|
28246
28307
|
|
28247
28308
|
// src/Prebuilt/components/VideoLayouts/GridLayout.tsx
|
28248
|
-
var import_react168,
|
28309
|
+
var import_react168, import_react_sdk86, GridLayout;
|
28249
28310
|
var init_GridLayout = __esm({
|
28250
28311
|
"src/Prebuilt/components/VideoLayouts/GridLayout.tsx"() {
|
28251
28312
|
"use strict";
|
28252
28313
|
init_define_process_env();
|
28253
28314
|
import_react168 = __toESM(require("react"));
|
28254
|
-
|
28315
|
+
import_react_sdk86 = require("@100mslive/react-sdk");
|
28255
28316
|
init_EqualProminence();
|
28256
28317
|
init_RoleProminence();
|
28257
28318
|
init_ScreenshareLayout();
|
@@ -28270,11 +28331,11 @@ var init_GridLayout = __esm({
|
|
28270
28331
|
edge_to_edge = false,
|
28271
28332
|
hide_metadata_on_tile = false
|
28272
28333
|
}) => {
|
28273
|
-
const peerSharing = (0,
|
28334
|
+
const peerSharing = (0, import_react_sdk86.useHMSStore)(import_react_sdk86.selectPeerScreenSharing);
|
28274
28335
|
const pinnedTrack = usePinnedTrack();
|
28275
|
-
const peers = (0,
|
28276
|
-
const localPeerRole = (0,
|
28277
|
-
const localPeerID = (0,
|
28336
|
+
const peers = (0, import_react_sdk86.useHMSStore)(import_react_sdk86.selectPeers);
|
28337
|
+
const localPeerRole = (0, import_react_sdk86.useHMSStore)(import_react_sdk86.selectLocalPeerRoleName);
|
28338
|
+
const localPeerID = (0, import_react_sdk86.useHMSStore)(import_react_sdk86.selectLocalPeerID);
|
28278
28339
|
const [activeScreensharePeerId] = useSetAppDataByKey(APP_DATA.activeScreensharePeerId);
|
28279
28340
|
const isRoleProminence = prominentRoles.length && peers.some(
|
28280
28341
|
(peer) => peer.roleName && prominentRoles.includes(peer.roleName) && (peer.videoTrack || peer.audioTrack)
|
@@ -28293,7 +28354,7 @@ var init_GridLayout = __esm({
|
|
28293
28354
|
}
|
28294
28355
|
return peers;
|
28295
28356
|
}, [isInsetEnabled, activeScreensharePeerId, localPeerRole, localPeerID, prominentRoles, peers, pinnedTrack]);
|
28296
|
-
const vanillaStore = (0,
|
28357
|
+
const vanillaStore = (0, import_react_sdk86.useHMSVanillaStore)();
|
28297
28358
|
const [sortedPeers, setSortedPeers] = (0, import_react168.useState)(updatedPeers);
|
28298
28359
|
const peersSorter = (0, import_react168.useMemo)(() => new PeersSorter_default(vanillaStore), [vanillaStore]);
|
28299
28360
|
const [pageSize, setPageSize] = (0, import_react168.useState)(0);
|
@@ -28354,13 +28415,13 @@ var init_GridLayout = __esm({
|
|
28354
28415
|
});
|
28355
28416
|
|
28356
28417
|
// src/Prebuilt/layouts/EmbedView.jsx
|
28357
|
-
var import_react169,
|
28418
|
+
var import_react169, import_react_sdk87, EmbedView, EmbedScreenShareView, EmbedComponent;
|
28358
28419
|
var init_EmbedView = __esm({
|
28359
28420
|
"src/Prebuilt/layouts/EmbedView.jsx"() {
|
28360
28421
|
"use strict";
|
28361
28422
|
init_define_process_env();
|
28362
28423
|
import_react169 = __toESM(require("react"));
|
28363
|
-
|
28424
|
+
import_react_sdk87 = require("@100mslive/react-sdk");
|
28364
28425
|
init_SecondaryTiles();
|
28365
28426
|
init_ToastManager();
|
28366
28427
|
init_ProminenceLayout();
|
@@ -28371,8 +28432,8 @@ var init_EmbedView = __esm({
|
|
28371
28432
|
return /* @__PURE__ */ import_react169.default.createElement(EmbedScreenShareView, null, /* @__PURE__ */ import_react169.default.createElement(EmbedComponent, null));
|
28372
28433
|
};
|
28373
28434
|
EmbedScreenShareView = ({ children }) => {
|
28374
|
-
const peers = (0,
|
28375
|
-
const peerPresenting = (0,
|
28435
|
+
const peers = (0, import_react_sdk87.useHMSStore)(import_react_sdk87.selectPeers);
|
28436
|
+
const peerPresenting = (0, import_react_sdk87.useHMSStore)(import_react_sdk87.selectPeerScreenSharing);
|
28376
28437
|
const [, setActiveScreenSharePeer] = useSetAppDataByKey(APP_DATA.activeScreensharePeerId);
|
28377
28438
|
const smallTilePeers = (0, import_react169.useMemo)(() => {
|
28378
28439
|
const smallTilePeers2 = peers.filter((peer) => peer.id !== (peerPresenting == null ? void 0 : peerPresenting.id));
|
@@ -28387,9 +28448,9 @@ var init_EmbedView = __esm({
|
|
28387
28448
|
return /* @__PURE__ */ import_react169.default.createElement(ProminenceLayout.Root, null, /* @__PURE__ */ import_react169.default.createElement(ProminenceLayout.ProminentSection, null, children), /* @__PURE__ */ import_react169.default.createElement(SecondaryTiles, { peers: smallTilePeers }));
|
28388
28449
|
};
|
28389
28450
|
EmbedComponent = () => {
|
28390
|
-
const embedConfig = (0,
|
28451
|
+
const embedConfig = (0, import_react_sdk87.useHMSStore)((0, import_react_sdk87.selectAppData)(APP_DATA.embedConfig));
|
28391
28452
|
const resetConfig = useResetEmbedConfig();
|
28392
|
-
const { iframeRef, startEmbedShare, isEmbedShareInProgress } = (0,
|
28453
|
+
const { iframeRef, startEmbedShare, isEmbedShareInProgress } = (0, import_react_sdk87.useEmbedShare)(resetConfig);
|
28393
28454
|
(0, import_react169.useEffect)(() => {
|
28394
28455
|
(() => __async(void 0, null, function* () {
|
28395
28456
|
if (embedConfig && !isEmbedShareInProgress) {
|
@@ -28439,13 +28500,13 @@ var init_EmbedView = __esm({
|
|
28439
28500
|
});
|
28440
28501
|
|
28441
28502
|
// src/Prebuilt/layouts/PDFView.jsx
|
28442
|
-
var import_react170,
|
28503
|
+
var import_react170, import_react_sdk88, PDFView;
|
28443
28504
|
var init_PDFView = __esm({
|
28444
28505
|
"src/Prebuilt/layouts/PDFView.jsx"() {
|
28445
28506
|
"use strict";
|
28446
28507
|
init_define_process_env();
|
28447
28508
|
import_react170 = __toESM(require("react"));
|
28448
|
-
|
28509
|
+
import_react_sdk88 = require("@100mslive/react-sdk");
|
28449
28510
|
init_ToastManager();
|
28450
28511
|
init_Layout();
|
28451
28512
|
init_EmbedView();
|
@@ -28453,7 +28514,7 @@ var init_PDFView = __esm({
|
|
28453
28514
|
PDFView = () => {
|
28454
28515
|
const pdfConfig = usePDFConfig();
|
28455
28516
|
const resetConfig = useResetPDFConfig();
|
28456
|
-
const { iframeRef, startPDFShare, isPDFShareInProgress } = (0,
|
28517
|
+
const { iframeRef, startPDFShare, isPDFShareInProgress } = (0, import_react_sdk88.usePDFShare)(resetConfig);
|
28457
28518
|
(0, import_react170.useEffect)(() => {
|
28458
28519
|
(() => __async(void 0, null, function* () {
|
28459
28520
|
try {
|
@@ -28562,14 +28623,14 @@ var init_WaitingView = __esm({
|
|
28562
28623
|
});
|
28563
28624
|
|
28564
28625
|
// src/Prebuilt/layouts/WhiteboardView.tsx
|
28565
|
-
var import_react172, import_react_use36,
|
28626
|
+
var import_react172, import_react_use36, import_react_sdk89, EmbedComponent2, WhiteboardView;
|
28566
28627
|
var init_WhiteboardView = __esm({
|
28567
28628
|
"src/Prebuilt/layouts/WhiteboardView.tsx"() {
|
28568
28629
|
"use strict";
|
28569
28630
|
init_define_process_env();
|
28570
28631
|
import_react172 = __toESM(require("react"));
|
28571
28632
|
import_react_use36 = require("react-use");
|
28572
|
-
|
28633
|
+
import_react_sdk89 = require("@100mslive/react-sdk");
|
28573
28634
|
init_SecondaryTiles();
|
28574
28635
|
init_ProminenceLayout();
|
28575
28636
|
init_src();
|
@@ -28578,7 +28639,7 @@ var init_WhiteboardView = __esm({
|
|
28578
28639
|
init_constants();
|
28579
28640
|
EmbedComponent2 = () => {
|
28580
28641
|
const isMobile = (0, import_react_use36.useMedia)(config.media.md);
|
28581
|
-
const { iframeRef } = (0,
|
28642
|
+
const { iframeRef } = (0, import_react_sdk89.useWhiteboard)(isMobile);
|
28582
28643
|
return /* @__PURE__ */ import_react172.default.createElement(
|
28583
28644
|
Box,
|
28584
28645
|
{
|
@@ -28610,8 +28671,8 @@ var init_WhiteboardView = __esm({
|
|
28610
28671
|
);
|
28611
28672
|
};
|
28612
28673
|
WhiteboardView = () => {
|
28613
|
-
const peers = (0,
|
28614
|
-
const whiteboard = (0,
|
28674
|
+
const peers = (0, import_react_sdk89.useHMSStore)(import_react_sdk89.selectPeers);
|
28675
|
+
const whiteboard = (0, import_react_sdk89.useHMSStore)(import_react_sdk89.selectWhiteboard);
|
28615
28676
|
const [, setActiveScreenSharePeer] = useSetAppDataByKey(APP_DATA.activeScreensharePeerId);
|
28616
28677
|
const smallTilePeers = (0, import_react172.useMemo)(() => {
|
28617
28678
|
const smallTilePeers2 = peers.filter((peer) => peer.id !== (whiteboard == null ? void 0 : whiteboard.owner));
|
@@ -28629,17 +28690,17 @@ var init_WhiteboardView = __esm({
|
|
28629
28690
|
});
|
28630
28691
|
|
28631
28692
|
// src/Prebuilt/components/hooks/useCloseScreenshareWhiteboard.tsx
|
28632
|
-
var import_react173, import_react_use37,
|
28693
|
+
var import_react173, import_react_use37, import_react_sdk90, useCloseScreenshareWhiteboard;
|
28633
28694
|
var init_useCloseScreenshareWhiteboard = __esm({
|
28634
28695
|
"src/Prebuilt/components/hooks/useCloseScreenshareWhiteboard.tsx"() {
|
28635
28696
|
"use strict";
|
28636
28697
|
init_define_process_env();
|
28637
28698
|
import_react173 = require("react");
|
28638
28699
|
import_react_use37 = require("react-use");
|
28639
|
-
|
28700
|
+
import_react_sdk90 = require("@100mslive/react-sdk");
|
28640
28701
|
useCloseScreenshareWhiteboard = () => {
|
28641
|
-
const { amIScreenSharing, toggleScreenShare } = (0,
|
28642
|
-
const { isOwner: isWhiteboardOwner, toggle: toggleWhiteboard } = (0,
|
28702
|
+
const { amIScreenSharing, toggleScreenShare } = (0, import_react_sdk90.useScreenShare)();
|
28703
|
+
const { isOwner: isWhiteboardOwner, toggle: toggleWhiteboard } = (0, import_react_sdk90.useWhiteboard)();
|
28643
28704
|
const prevScreenSharer = (0, import_react_use37.usePrevious)(amIScreenSharing);
|
28644
28705
|
const prevWhiteboardOwner = (0, import_react_use37.usePrevious)(isWhiteboardOwner);
|
28645
28706
|
(0, import_react173.useEffect)(() => {
|
@@ -29298,7 +29359,7 @@ var HLSView_exports = {};
|
|
29298
29359
|
__export(HLSView_exports, {
|
29299
29360
|
default: () => HLSView_default
|
29300
29361
|
});
|
29301
|
-
var import_react184, import_react_use38, import_hls_player3, import_screenfull3,
|
29362
|
+
var import_react184, import_react_use38, import_hls_player3, import_screenfull3, import_react_sdk91, import_react_icons88, hlsPlayer, toastMap, HLSView, HLSView_default;
|
29302
29363
|
var init_HLSView = __esm({
|
29303
29364
|
"src/Prebuilt/layouts/HLSView.jsx"() {
|
29304
29365
|
"use strict";
|
@@ -29307,7 +29368,7 @@ var init_HLSView = __esm({
|
|
29307
29368
|
import_react_use38 = require("react-use");
|
29308
29369
|
import_hls_player3 = require("@100mslive/hls-player");
|
29309
29370
|
import_screenfull3 = __toESM(require("screenfull"));
|
29310
|
-
|
29371
|
+
import_react_sdk91 = require("@100mslive/react-sdk");
|
29311
29372
|
import_react_icons88 = require("@100mslive/react-icons");
|
29312
29373
|
init_HlsStatsOverlay();
|
29313
29374
|
init_HMSVideo2();
|
@@ -29330,10 +29391,10 @@ var init_HLSView = __esm({
|
|
29330
29391
|
var _a8;
|
29331
29392
|
const videoRef = (0, import_react184.useRef)(null);
|
29332
29393
|
const hlsViewRef = (0, import_react184.useRef)(null);
|
29333
|
-
const hlsState = (0,
|
29334
|
-
const enablHlsStats = (0,
|
29335
|
-
const notification = (0,
|
29336
|
-
const hmsActions = (0,
|
29394
|
+
const hlsState = (0, import_react_sdk91.useHMSStore)(import_react_sdk91.selectHLSState);
|
29395
|
+
const enablHlsStats = (0, import_react_sdk91.useHMSStore)((0, import_react_sdk91.selectAppData)(APP_DATA.hlsStats));
|
29396
|
+
const notification = (0, import_react_sdk91.useHMSNotifications)(import_react_sdk91.HMSNotificationTypes.POLL_STOPPED);
|
29397
|
+
const hmsActions = (0, import_react_sdk91.useHMSActions)();
|
29337
29398
|
const { themeType, theme: theme2 } = useTheme();
|
29338
29399
|
const [streamEnded, setStreamEnded] = (0, import_react184.useState)(false);
|
29339
29400
|
let [hlsStatsState, setHlsStatsState] = (0, import_react184.useState)(null);
|
@@ -29354,7 +29415,7 @@ var init_HLSView = __esm({
|
|
29354
29415
|
const [qualityDropDownOpen, setQualityDropDownOpen] = (0, import_react184.useState)(false);
|
29355
29416
|
const lastHlsUrl = (0, import_react_use38.usePrevious)(hlsUrl);
|
29356
29417
|
const togglePollView = usePollViewToggle();
|
29357
|
-
const vanillaStore = (0,
|
29418
|
+
const vanillaStore = (0, import_react_sdk91.useHMSVanillaStore)();
|
29358
29419
|
const isMobile = (0, import_react_use38.useMedia)(config.media.md);
|
29359
29420
|
const isFullScreen = (0, import_react_use38.useFullscreen)(hlsViewRef, show, {
|
29360
29421
|
onClose: () => toggle(false)
|
@@ -29419,8 +29480,8 @@ var init_HLSView = __esm({
|
|
29419
29480
|
const parsedPayload = parsePayload(payload);
|
29420
29481
|
if (parsedPayload.startsWith("poll:")) {
|
29421
29482
|
const pollId = parsedPayload.substr(parsedPayload.indexOf(":") + 1);
|
29422
|
-
const poll = vanillaStore.getState((0,
|
29423
|
-
const pollStartedBy = vanillaStore.getState((0,
|
29483
|
+
const poll = vanillaStore.getState((0, import_react_sdk91.selectPollByID)(pollId));
|
29484
|
+
const pollStartedBy = vanillaStore.getState((0, import_react_sdk91.selectPeerNameByID)(poll.startedBy)) || "Participant";
|
29424
29485
|
const toastID = ToastManager.addToast({
|
29425
29486
|
title: `${pollStartedBy} started a ${poll.type}: ${poll.title}`,
|
29426
29487
|
action: /* @__PURE__ */ import_react184.default.createElement(
|
@@ -29721,13 +29782,13 @@ var init_HLSView = __esm({
|
|
29721
29782
|
});
|
29722
29783
|
|
29723
29784
|
// src/Prebuilt/layouts/VideoStreamingSection.tsx
|
29724
|
-
var import_react185,
|
29785
|
+
var import_react185, import_react_sdk92, HLSView2, VideoStreamingSection;
|
29725
29786
|
var init_VideoStreamingSection = __esm({
|
29726
29787
|
"src/Prebuilt/layouts/VideoStreamingSection.tsx"() {
|
29727
29788
|
"use strict";
|
29728
29789
|
init_define_process_env();
|
29729
29790
|
import_react185 = __toESM(require("react"));
|
29730
|
-
|
29791
|
+
import_react_sdk92 = require("@100mslive/react-sdk");
|
29731
29792
|
init_FullPageProgress();
|
29732
29793
|
init_GridLayout();
|
29733
29794
|
init_Layout();
|
@@ -29745,11 +29806,11 @@ var init_VideoStreamingSection = __esm({
|
|
29745
29806
|
hideControls = false
|
29746
29807
|
}) => {
|
29747
29808
|
var _a8, _b7, _c, _d;
|
29748
|
-
const localPeerRole = (0,
|
29749
|
-
const isConnected = (0,
|
29750
|
-
const peerSharing = (0,
|
29751
|
-
const isWhiteboardOpen = (_a8 = (0,
|
29752
|
-
const hmsActions = (0,
|
29809
|
+
const localPeerRole = (0, import_react_sdk92.useHMSStore)(import_react_sdk92.selectLocalPeerRoleName);
|
29810
|
+
const isConnected = (0, import_react_sdk92.useHMSStore)(import_react_sdk92.selectIsConnectedToRoom);
|
29811
|
+
const peerSharing = (0, import_react_sdk92.useHMSStore)(import_react_sdk92.selectPeerScreenSharing);
|
29812
|
+
const isWhiteboardOpen = (_a8 = (0, import_react_sdk92.useHMSStore)(import_react_sdk92.selectWhiteboard)) == null ? void 0 : _a8.open;
|
29813
|
+
const hmsActions = (0, import_react_sdk92.useHMSActions)();
|
29753
29814
|
const waitingViewerRole = useWaitingViewerRole();
|
29754
29815
|
const urlToIframe = useUrlToEmbed();
|
29755
29816
|
const pdfAnnotatorActive = usePDFConfig();
|
@@ -29809,13 +29870,13 @@ var init_VideoStreamingSection = __esm({
|
|
29809
29870
|
});
|
29810
29871
|
|
29811
29872
|
// src/Prebuilt/components/Header/common.jsx
|
29812
|
-
var import_react186,
|
29873
|
+
var import_react186, import_react_sdk93, import_react_icons89, CamaraFlipActions, AudioActions, AudioSelectionSheet, SelectWithLabel;
|
29813
29874
|
var init_common2 = __esm({
|
29814
29875
|
"src/Prebuilt/components/Header/common.jsx"() {
|
29815
29876
|
"use strict";
|
29816
29877
|
init_define_process_env();
|
29817
29878
|
import_react186 = __toESM(require("react"));
|
29818
|
-
|
29879
|
+
import_react_sdk93 = require("@100mslive/react-sdk");
|
29819
29880
|
import_react_icons89 = require("@100mslive/react-icons");
|
29820
29881
|
init_Divider2();
|
29821
29882
|
init_Label2();
|
@@ -29825,12 +29886,12 @@ var init_common2 = __esm({
|
|
29825
29886
|
init_IconButton3();
|
29826
29887
|
init_ToastManager();
|
29827
29888
|
CamaraFlipActions = () => {
|
29828
|
-
const actions = (0,
|
29829
|
-
const { allDevices } = (0,
|
29889
|
+
const actions = (0, import_react_sdk93.useHMSActions)();
|
29890
|
+
const { allDevices } = (0, import_react_sdk93.useDevices)();
|
29830
29891
|
const { videoInput } = allDevices;
|
29831
|
-
const isVideoOn = (0,
|
29832
|
-
const videoTrackId = (0,
|
29833
|
-
const localVideoTrack = (0,
|
29892
|
+
const isVideoOn = (0, import_react_sdk93.useHMSStore)(import_react_sdk93.selectIsLocalVideoEnabled);
|
29893
|
+
const videoTrackId = (0, import_react_sdk93.useHMSStore)(import_react_sdk93.selectLocalVideoTrackID);
|
29894
|
+
const localVideoTrack = (0, import_react_sdk93.useHMSStore)((0, import_react_sdk93.selectVideoTrackByID)(videoTrackId));
|
29834
29895
|
if (!videoInput || !(videoInput == null ? void 0 : videoInput.length) || !(localVideoTrack == null ? void 0 : localVideoTrack.facingMode)) {
|
29835
29896
|
return null;
|
29836
29897
|
}
|
@@ -29853,7 +29914,7 @@ var init_common2 = __esm({
|
|
29853
29914
|
));
|
29854
29915
|
};
|
29855
29916
|
AudioActions = () => {
|
29856
|
-
const { allDevices, selectedDeviceIDs, updateDevice } = (0,
|
29917
|
+
const { allDevices, selectedDeviceIDs, updateDevice } = (0, import_react_sdk93.useDevices)();
|
29857
29918
|
const shouldShowAudioOutput = "setSinkId" in HTMLMediaElement.prototype;
|
29858
29919
|
const { audioInput, audioOutput } = allDevices;
|
29859
29920
|
let availableAudioDevices = audioInput;
|
@@ -29862,7 +29923,7 @@ var init_common2 = __esm({
|
|
29862
29923
|
availableAudioDevices = audioOutput;
|
29863
29924
|
selectedAudio = selectedDeviceIDs.audioOutput;
|
29864
29925
|
}
|
29865
|
-
const hmsActions = (0,
|
29926
|
+
const hmsActions = (0, import_react_sdk93.useHMSActions)();
|
29866
29927
|
const audioFiltered = availableAudioDevices == null ? void 0 : availableAudioDevices.find((item) => !!item.label);
|
29867
29928
|
const currentSelection = availableAudioDevices == null ? void 0 : availableAudioDevices.find((item) => item.deviceId === selectedAudio);
|
29868
29929
|
if (!audioFiltered) {
|
@@ -29883,7 +29944,7 @@ var init_common2 = __esm({
|
|
29883
29944
|
try {
|
29884
29945
|
yield updateDevice({
|
29885
29946
|
deviceId,
|
29886
|
-
deviceType: shouldShowAudioOutput ?
|
29947
|
+
deviceType: shouldShowAudioOutput ? import_react_sdk93.DeviceType.audioOutput : import_react_sdk93.DeviceType.audioInput
|
29887
29948
|
});
|
29888
29949
|
} catch (e) {
|
29889
29950
|
ToastManager.addToast({
|
@@ -29967,22 +30028,22 @@ var init_common2 = __esm({
|
|
29967
30028
|
});
|
29968
30029
|
|
29969
30030
|
// src/Prebuilt/components/Header/Header.tsx
|
29970
|
-
var import_react187, import_react_use39,
|
30031
|
+
var import_react187, import_react_use39, import_react_sdk94, Header2;
|
29971
30032
|
var init_Header = __esm({
|
29972
30033
|
"src/Prebuilt/components/Header/Header.tsx"() {
|
29973
30034
|
"use strict";
|
29974
30035
|
init_define_process_env();
|
29975
30036
|
import_react187 = __toESM(require("react"));
|
29976
30037
|
import_react_use39 = require("react-use");
|
29977
|
-
|
30038
|
+
import_react_sdk94 = require("@100mslive/react-sdk");
|
29978
30039
|
init_src();
|
29979
30040
|
init_HeaderComponents();
|
29980
30041
|
init_StreamActions();
|
29981
30042
|
init_common2();
|
29982
30043
|
Header2 = () => {
|
29983
|
-
const roomState = (0,
|
30044
|
+
const roomState = (0, import_react_sdk94.useHMSStore)(import_react_sdk94.selectRoomState);
|
29984
30045
|
const isMobile = (0, import_react_use39.useMedia)(config.media.md);
|
29985
|
-
if (roomState !==
|
30046
|
+
if (roomState !== import_react_sdk94.HMSRoomState.Connected) {
|
29986
30047
|
return /* @__PURE__ */ import_react187.default.createElement(import_react187.default.Fragment, null);
|
29987
30048
|
}
|
29988
30049
|
return /* @__PURE__ */ import_react187.default.createElement(Flex, { justify: "between", align: "center", css: { position: "relative", height: "100%" } }, /* @__PURE__ */ import_react187.default.createElement(Flex, { align: "center", gap: "2", css: { position: "absolute", left: "$10" } }, /* @__PURE__ */ import_react187.default.createElement(Logo, null), /* @__PURE__ */ import_react187.default.createElement(SpeakerTag, null), isMobile && /* @__PURE__ */ import_react187.default.createElement(Flex, { align: "center", css: { gap: "$4" } }, /* @__PURE__ */ import_react187.default.createElement(LiveStatus, null), /* @__PURE__ */ import_react187.default.createElement(RecordingStatus, null), /* @__PURE__ */ import_react187.default.createElement(RecordingPauseStatus, null))), /* @__PURE__ */ import_react187.default.createElement(
|
@@ -30012,25 +30073,25 @@ var init_Header2 = __esm({
|
|
30012
30073
|
});
|
30013
30074
|
|
30014
30075
|
// src/Prebuilt/components/PreviousRoleInMetadata.tsx
|
30015
|
-
var import_react188,
|
30076
|
+
var import_react188, import_react_sdk95, PreviousRoleInMetadata;
|
30016
30077
|
var init_PreviousRoleInMetadata = __esm({
|
30017
30078
|
"src/Prebuilt/components/PreviousRoleInMetadata.tsx"() {
|
30018
30079
|
"use strict";
|
30019
30080
|
init_define_process_env();
|
30020
30081
|
import_react188 = require("react");
|
30021
|
-
|
30082
|
+
import_react_sdk95 = require("@100mslive/react-sdk");
|
30022
30083
|
init_useMetadata();
|
30023
30084
|
PreviousRoleInMetadata = () => {
|
30024
|
-
const vanillaStore = (0,
|
30085
|
+
const vanillaStore = (0, import_react_sdk95.useHMSVanillaStore)();
|
30025
30086
|
const { updateMetaData } = useMyMetadata();
|
30026
30087
|
(0, import_react188.useEffect)(() => {
|
30027
|
-
let previousRole = vanillaStore.getState(
|
30088
|
+
let previousRole = vanillaStore.getState(import_react_sdk95.selectLocalPeerRoleName);
|
30028
30089
|
const unsubscribe = vanillaStore.subscribe((currentRole) => {
|
30029
30090
|
if (previousRole !== currentRole) {
|
30030
30091
|
updateMetaData({ prevRole: previousRole });
|
30031
30092
|
previousRole = currentRole;
|
30032
30093
|
}
|
30033
|
-
},
|
30094
|
+
}, import_react_sdk95.selectLocalPeerRoleName);
|
30034
30095
|
return unsubscribe;
|
30035
30096
|
}, [vanillaStore]);
|
30036
30097
|
return null;
|
@@ -30039,13 +30100,13 @@ var init_PreviousRoleInMetadata = __esm({
|
|
30039
30100
|
});
|
30040
30101
|
|
30041
30102
|
// src/Prebuilt/components/ConferenceScreen.tsx
|
30042
|
-
var import_react189,
|
30103
|
+
var import_react189, import_react_sdk96, ConferenceScreen;
|
30043
30104
|
var init_ConferenceScreen = __esm({
|
30044
30105
|
"src/Prebuilt/components/ConferenceScreen.tsx"() {
|
30045
30106
|
"use strict";
|
30046
30107
|
init_define_process_env();
|
30047
30108
|
import_react189 = __toESM(require("react"));
|
30048
|
-
|
30109
|
+
import_react_sdk96 = require("@100mslive/react-sdk");
|
30049
30110
|
init_Footer3();
|
30050
30111
|
init_HLSFailureModal();
|
30051
30112
|
init_PIPComponent();
|
@@ -30065,11 +30126,11 @@ var init_ConferenceScreen = __esm({
|
|
30065
30126
|
const { userName, endpoints, onJoin: onJoinFunc } = useHMSPrebuiltContext();
|
30066
30127
|
const screenProps = useRoomLayoutConferencingScreen();
|
30067
30128
|
const { isPreviewScreenEnabled } = useRoomLayoutPreviewScreen();
|
30068
|
-
const roomState = (0,
|
30069
|
-
const isConnectedToRoom = (0,
|
30070
|
-
const hmsActions = (0,
|
30129
|
+
const roomState = (0, import_react_sdk96.useHMSStore)(import_react_sdk96.selectRoomState);
|
30130
|
+
const isConnectedToRoom = (0, import_react_sdk96.useHMSStore)(import_react_sdk96.selectIsConnectedToRoom);
|
30131
|
+
const hmsActions = (0, import_react_sdk96.useHMSActions)();
|
30071
30132
|
const [hideControls, setHideControls] = (0, import_react189.useState)(false);
|
30072
|
-
const dropdownList = (0,
|
30133
|
+
const dropdownList = (0, import_react_sdk96.useHMSStore)((0, import_react_sdk96.selectAppData)(APP_DATA.dropdownList));
|
30073
30134
|
const authTokenInAppData = useAuthToken();
|
30074
30135
|
const headerRef = (0, import_react189.useRef)(null);
|
30075
30136
|
const footerRef = (0, import_react189.useRef)(null);
|
@@ -30099,7 +30160,7 @@ var init_ConferenceScreen = __esm({
|
|
30099
30160
|
};
|
30100
30161
|
}, [dropdownList, hideControls, isMobileDevice]);
|
30101
30162
|
(0, import_react189.useEffect)(() => {
|
30102
|
-
if (authTokenInAppData && !isConnectedToRoom && !isPreviewScreenEnabled && roomState !==
|
30163
|
+
if (authTokenInAppData && !isConnectedToRoom && !isPreviewScreenEnabled && roomState !== import_react_sdk96.HMSRoomState.Connecting && !autoRoomJoined.current) {
|
30103
30164
|
hmsActions.join({
|
30104
30165
|
userName: userName || "",
|
30105
30166
|
authToken: authTokenInAppData,
|
@@ -30119,8 +30180,8 @@ var init_ConferenceScreen = __esm({
|
|
30119
30180
|
PictureInPicture.stop().catch((error) => console.error("stopping pip", error.message));
|
30120
30181
|
};
|
30121
30182
|
}, [onJoinFunc]);
|
30122
|
-
if (!isConnectedToRoom && ![
|
30123
|
-
return /* @__PURE__ */ import_react189.default.createElement(FullPageProgress_default, { text: roomState ===
|
30183
|
+
if (!isConnectedToRoom && ![import_react_sdk96.HMSRoomState.Reconnecting, import_react_sdk96.HMSRoomState.Disconnected].includes(roomState)) {
|
30184
|
+
return /* @__PURE__ */ import_react189.default.createElement(FullPageProgress_default, { text: roomState === import_react_sdk96.HMSRoomState.Connecting ? "Joining..." : "" });
|
30124
30185
|
}
|
30125
30186
|
return /* @__PURE__ */ import_react189.default.createElement(import_react189.default.Fragment, null, isHLSStarted ? /* @__PURE__ */ import_react189.default.createElement(Box, { css: { position: "fixed", zIndex: 100, w: "100%", h: "100%", left: 0, top: 0 } }, /* @__PURE__ */ import_react189.default.createElement(FullPageProgress_default, { text: "Starting live stream...", css: { opacity: 0.8, bg: "$background_dim" } })) : null, /* @__PURE__ */ import_react189.default.createElement(Flex, { css: { size: "100%", overflow: "hidden" }, direction: "column" }, !screenProps.hideSections.includes("header") && /* @__PURE__ */ import_react189.default.createElement(
|
30126
30187
|
Box,
|
@@ -30281,7 +30342,7 @@ var init_ErrorBoundary = __esm({
|
|
30281
30342
|
|
30282
30343
|
// src/Prebuilt/services/FeatureFlags.jsx
|
30283
30344
|
function FeatureFlagsInit() {
|
30284
|
-
const roomId = (0,
|
30345
|
+
const roomId = (0, import_react_sdk97.useHMSStore)(import_react_sdk97.selectRoomID);
|
30285
30346
|
(0, import_react191.useEffect)(() => {
|
30286
30347
|
if (roomId) {
|
30287
30348
|
FeatureFlags.init(roomId);
|
@@ -30289,13 +30350,13 @@ function FeatureFlagsInit() {
|
|
30289
30350
|
}, [roomId]);
|
30290
30351
|
return null;
|
30291
30352
|
}
|
30292
|
-
var import_react191,
|
30353
|
+
var import_react191, import_react_sdk97, FeatureFlags;
|
30293
30354
|
var init_FeatureFlags = __esm({
|
30294
30355
|
"src/Prebuilt/services/FeatureFlags.jsx"() {
|
30295
30356
|
"use strict";
|
30296
30357
|
init_define_process_env();
|
30297
30358
|
import_react191 = require("react");
|
30298
|
-
|
30359
|
+
import_react_sdk97 = require("@100mslive/react-sdk");
|
30299
30360
|
FeatureFlags = class {
|
30300
30361
|
static init(roomId) {
|
30301
30362
|
if (!window.HMS) {
|
@@ -30353,13 +30414,13 @@ var init_Init = __esm({
|
|
30353
30414
|
});
|
30354
30415
|
|
30355
30416
|
// src/Prebuilt/components/Input/KeyboardInputManager.js
|
30356
|
-
var import_react193,
|
30417
|
+
var import_react193, import_react_sdk98, isEvenListenersAttached, _actions, _store, _toggleAudio, _toggleVideo, _hideSidepane, _toggleStatsForNerds, _toggleHlsStats, _keyDownHandler, _bind, _unbind, KeyboardInputManager, KeyboardHandler;
|
30357
30418
|
var init_KeyboardInputManager = __esm({
|
30358
30419
|
"src/Prebuilt/components/Input/KeyboardInputManager.js"() {
|
30359
30420
|
"use strict";
|
30360
30421
|
init_define_process_env();
|
30361
30422
|
import_react193 = require("react");
|
30362
|
-
|
30423
|
+
import_react_sdk98 = require("@100mslive/react-sdk");
|
30363
30424
|
init_constants();
|
30364
30425
|
isEvenListenersAttached = false;
|
30365
30426
|
KeyboardInputManager = class {
|
@@ -30367,27 +30428,27 @@ var init_KeyboardInputManager = __esm({
|
|
30367
30428
|
__privateAdd(this, _actions, void 0);
|
30368
30429
|
__privateAdd(this, _store, void 0);
|
30369
30430
|
__privateAdd(this, _toggleAudio, () => __async(this, null, function* () {
|
30370
|
-
const enabled = __privateGet(this, _store).getState(
|
30431
|
+
const enabled = __privateGet(this, _store).getState(import_react_sdk98.selectIsLocalAudioEnabled);
|
30371
30432
|
yield __privateGet(this, _actions).setLocalAudioEnabled(!enabled);
|
30372
30433
|
}));
|
30373
30434
|
__privateAdd(this, _toggleVideo, () => __async(this, null, function* () {
|
30374
|
-
const enabled = __privateGet(this, _store).getState(
|
30435
|
+
const enabled = __privateGet(this, _store).getState(import_react_sdk98.selectIsLocalVideoEnabled);
|
30375
30436
|
yield __privateGet(this, _actions).setLocalVideoEnabled(!enabled);
|
30376
30437
|
}));
|
30377
30438
|
__privateAdd(this, _hideSidepane, () => {
|
30378
|
-
if (__privateGet(this, _store).getState((0,
|
30439
|
+
if (__privateGet(this, _store).getState((0, import_react_sdk98.selectAppData)(APP_DATA.sidePane))) {
|
30379
30440
|
__privateGet(this, _actions).setAppData(APP_DATA.sidePane, "");
|
30380
30441
|
}
|
30381
30442
|
});
|
30382
30443
|
__privateAdd(this, _toggleStatsForNerds, () => {
|
30383
|
-
const uiSettings = __privateGet(this, _store).getState((0,
|
30444
|
+
const uiSettings = __privateGet(this, _store).getState((0, import_react_sdk98.selectAppData)(APP_DATA.uiSettings));
|
30384
30445
|
const statsEnabled = uiSettings.showStatsOnTiles;
|
30385
30446
|
__privateGet(this, _actions).setAppData(APP_DATA.uiSettings, __spreadProps(__spreadValues({}, uiSettings), {
|
30386
30447
|
showStatsOnTiles: !statsEnabled
|
30387
30448
|
}));
|
30388
30449
|
});
|
30389
30450
|
__privateAdd(this, _toggleHlsStats, () => {
|
30390
|
-
__privateGet(this, _actions).setAppData(APP_DATA.hlsStats, !__privateGet(this, _store).getState((0,
|
30451
|
+
__privateGet(this, _actions).setAppData(APP_DATA.hlsStats, !__privateGet(this, _store).getState((0, import_react_sdk98.selectAppData)(APP_DATA.hlsStats)));
|
30391
30452
|
});
|
30392
30453
|
// eslint-disable-next-line complexity
|
30393
30454
|
__privateAdd(this, _keyDownHandler, (e) => __async(this, null, function* () {
|
@@ -30445,8 +30506,8 @@ var init_KeyboardInputManager = __esm({
|
|
30445
30506
|
_bind = new WeakMap();
|
30446
30507
|
_unbind = new WeakMap();
|
30447
30508
|
KeyboardHandler = () => {
|
30448
|
-
const store = (0,
|
30449
|
-
const actions = (0,
|
30509
|
+
const store = (0, import_react_sdk98.useHMSVanillaStore)();
|
30510
|
+
const actions = (0, import_react_sdk98.useHMSActions)();
|
30450
30511
|
(0, import_react193.useEffect)(() => {
|
30451
30512
|
const keyboardManager = new KeyboardInputManager(store, actions);
|
30452
30513
|
keyboardManager.bindAllShortcuts();
|
@@ -30485,14 +30546,14 @@ var init_useRedirectToLeave = __esm({
|
|
30485
30546
|
});
|
30486
30547
|
|
30487
30548
|
// src/Prebuilt/AppStateContext.tsx
|
30488
|
-
var import_react195, import_react_use40,
|
30549
|
+
var import_react195, import_react_use40, import_react_sdk99, AppStateContext, useHMSAppStateContext, useAppStateManager;
|
30489
30550
|
var init_AppStateContext = __esm({
|
30490
30551
|
"src/Prebuilt/AppStateContext.tsx"() {
|
30491
30552
|
"use strict";
|
30492
30553
|
init_define_process_env();
|
30493
30554
|
import_react195 = __toESM(require("react"));
|
30494
30555
|
import_react_use40 = require("react-use");
|
30495
|
-
|
30556
|
+
import_react_sdk99 = require("@100mslive/react-sdk");
|
30496
30557
|
init_VBHandler();
|
30497
30558
|
init_roomLayoutProvider();
|
30498
30559
|
init_useRedirectToLeave();
|
@@ -30513,7 +30574,7 @@ var init_AppStateContext = __esm({
|
|
30513
30574
|
useAppStateManager = () => {
|
30514
30575
|
const roomLayout = useRoomLayout();
|
30515
30576
|
const [activeState, setActiveState] = import_react195.default.useState();
|
30516
|
-
const roomState = (0,
|
30577
|
+
const roomState = (0, import_react_sdk99.useHMSStore)(import_react_sdk99.selectRoomState);
|
30517
30578
|
const prevRoomState = (0, import_react_use40.usePreviousDistinct)(roomState);
|
30518
30579
|
const { isLeaveScreenEnabled } = useRoomLayoutLeaveScreen();
|
30519
30580
|
const { isPreviewScreenEnabled } = useRoomLayoutPreviewScreen();
|
@@ -30525,14 +30586,14 @@ var init_AppStateContext = __esm({
|
|
30525
30586
|
if (!roomLayout) {
|
30526
30587
|
return;
|
30527
30588
|
}
|
30528
|
-
if (roomState ===
|
30589
|
+
if (roomState === import_react_sdk99.HMSRoomState.Connected) {
|
30529
30590
|
setActiveState("meeting" /* MEETING */);
|
30530
|
-
} else if (prevRoomState && [
|
30591
|
+
} else if (prevRoomState && [import_react_sdk99.HMSRoomState.Reconnecting, import_react_sdk99.HMSRoomState.Connected, import_react_sdk99.HMSRoomState.Connecting].includes(prevRoomState) && [import_react_sdk99.HMSRoomState.Disconnecting, import_react_sdk99.HMSRoomState.Disconnected].includes(roomState)) {
|
30531
30592
|
const goTo = isPreviewScreenEnabled ? "preview" /* PREVIEW */ : "meeting" /* MEETING */;
|
30532
30593
|
setActiveState(isLeaveScreenEnabled ? "leave" /* LEAVE */ : goTo);
|
30533
30594
|
VBHandler.reset();
|
30534
30595
|
redirectToLeave(1e3);
|
30535
|
-
} else if (!prevRoomState && roomState ===
|
30596
|
+
} else if (!prevRoomState && roomState === import_react_sdk99.HMSRoomState.Disconnected) {
|
30536
30597
|
setActiveState(isPreviewScreenEnabled ? "preview" /* PREVIEW */ : "meeting" /* MEETING */);
|
30537
30598
|
}
|
30538
30599
|
}, [roomLayout, roomState, isLeaveScreenEnabled, isPreviewScreenEnabled, prevRoomState, redirectToLeave]);
|
@@ -30658,13 +30719,13 @@ var init_MwebLandscapePrompt = __esm({
|
|
30658
30719
|
});
|
30659
30720
|
|
30660
30721
|
// src/Prebuilt/components/Toast/ToastConfig.jsx
|
30661
|
-
var import_react198,
|
30722
|
+
var import_react198, import_react_sdk100, import_react_icons93, ChatAction, HandRaiseAction, ToastConfig;
|
30662
30723
|
var init_ToastConfig = __esm({
|
30663
30724
|
"src/Prebuilt/components/Toast/ToastConfig.jsx"() {
|
30664
30725
|
"use strict";
|
30665
30726
|
init_define_process_env();
|
30666
30727
|
import_react198 = __toESM(require("react"));
|
30667
|
-
|
30728
|
+
import_react_sdk100 = require("@100mslive/react-sdk");
|
30668
30729
|
import_react_icons93 = require("@100mslive/react-icons");
|
30669
30730
|
init_Button2();
|
30670
30731
|
init_roomLayoutProvider();
|
@@ -30680,10 +30741,10 @@ var init_ToastConfig = __esm({
|
|
30680
30741
|
});
|
30681
30742
|
HandRaiseAction = import_react198.default.forwardRef(({ id = "", isSingleHandRaise = true }, ref) => {
|
30682
30743
|
var _a8, _b7, _c;
|
30683
|
-
const hmsActions = (0,
|
30744
|
+
const hmsActions = (0, import_react_sdk100.useHMSActions)();
|
30684
30745
|
const toggleSidepane = useSidepaneToggle(SIDE_PANE_OPTIONS.PARTICIPANTS);
|
30685
30746
|
const isParticipantsOpen = useIsSidepaneTypeOpen(SIDE_PANE_OPTIONS.PARTICIPANTS);
|
30686
|
-
const peer = (0,
|
30747
|
+
const peer = (0, import_react_sdk100.useHMSStore)((0, import_react_sdk100.selectPeerByID)(id));
|
30687
30748
|
const layout = useRoomLayout();
|
30688
30749
|
const {
|
30689
30750
|
bring_to_stage_label,
|
@@ -30895,7 +30956,7 @@ var init_ToastBatcher = __esm({
|
|
30895
30956
|
|
30896
30957
|
// src/Prebuilt/components/Notifications/AutoplayBlockedModal.tsx
|
30897
30958
|
function AutoplayBlockedModal() {
|
30898
|
-
const { error, resetError, unblockAudio } = (0,
|
30959
|
+
const { error, resetError, unblockAudio } = (0, import_react_sdk101.useAutoplayError)();
|
30899
30960
|
return /* @__PURE__ */ import_react199.default.createElement(
|
30900
30961
|
Dialog.Root,
|
30901
30962
|
{
|
@@ -30920,33 +30981,33 @@ function AutoplayBlockedModal() {
|
|
30920
30981
|
)))
|
30921
30982
|
);
|
30922
30983
|
}
|
30923
|
-
var import_react199,
|
30984
|
+
var import_react199, import_react_sdk101;
|
30924
30985
|
var init_AutoplayBlockedModal = __esm({
|
30925
30986
|
"src/Prebuilt/components/Notifications/AutoplayBlockedModal.tsx"() {
|
30926
30987
|
"use strict";
|
30927
30988
|
init_define_process_env();
|
30928
30989
|
import_react199 = __toESM(require("react"));
|
30929
|
-
|
30990
|
+
import_react_sdk101 = require("@100mslive/react-sdk");
|
30930
30991
|
init_src();
|
30931
30992
|
init_DialogContent2();
|
30932
30993
|
}
|
30933
30994
|
});
|
30934
30995
|
|
30935
30996
|
// src/Prebuilt/components/Notifications/ChatNotifications.tsx
|
30936
|
-
var import_react200, import_uuid12,
|
30997
|
+
var import_react200, import_uuid12, import_react_sdk102, import_react_icons94, NOTIFICATION_TIME_DIFFERENCE, ChatNotifications;
|
30937
30998
|
var init_ChatNotifications = __esm({
|
30938
30999
|
"src/Prebuilt/components/Notifications/ChatNotifications.tsx"() {
|
30939
31000
|
"use strict";
|
30940
31001
|
init_define_process_env();
|
30941
31002
|
import_react200 = __toESM(require("react"));
|
30942
31003
|
import_uuid12 = require("uuid");
|
30943
|
-
|
31004
|
+
import_react_sdk102 = require("@100mslive/react-sdk");
|
30944
31005
|
import_react_icons94 = require("@100mslive/react-icons");
|
30945
31006
|
init_ToastManager();
|
30946
31007
|
NOTIFICATION_TIME_DIFFERENCE = 5e3;
|
30947
31008
|
ChatNotifications = () => {
|
30948
|
-
const chatState = (0,
|
30949
|
-
const localPeerId = (0,
|
31009
|
+
const chatState = (0, import_react_sdk102.useHMSStore)((0, import_react_sdk102.selectSessionStore)("chatState" /* CHAT_STATE */));
|
31010
|
+
const localPeerId = (0, import_react_sdk102.useHMSStore)(import_react_sdk102.selectLocalPeerID);
|
30950
31011
|
(0, import_react200.useEffect)(() => {
|
30951
31012
|
var _a8, _b7;
|
30952
31013
|
if (!chatState || ((_a8 = chatState.updatedBy) == null ? void 0 : _a8.peerId) === localPeerId) {
|
@@ -30969,28 +31030,28 @@ var init_ChatNotifications = __esm({
|
|
30969
31030
|
});
|
30970
31031
|
|
30971
31032
|
// src/Prebuilt/components/Notifications/HandRaisedNotifications.tsx
|
30972
|
-
var import_react201,
|
31033
|
+
var import_react201, import_react_sdk103, HandRaisedNotifications;
|
30973
31034
|
var init_HandRaisedNotifications = __esm({
|
30974
31035
|
"src/Prebuilt/components/Notifications/HandRaisedNotifications.tsx"() {
|
30975
31036
|
"use strict";
|
30976
31037
|
init_define_process_env();
|
30977
31038
|
import_react201 = require("react");
|
30978
|
-
|
31039
|
+
import_react_sdk103 = require("@100mslive/react-sdk");
|
30979
31040
|
init_ToastBatcher();
|
30980
31041
|
init_useRoomLayoutScreen();
|
30981
31042
|
HandRaisedNotifications = () => {
|
30982
|
-
const notification = (0,
|
30983
|
-
const roomState = (0,
|
30984
|
-
const vanillaStore = (0,
|
31043
|
+
const notification = (0, import_react_sdk103.useHMSNotifications)(import_react_sdk103.HMSNotificationTypes.HAND_RAISE_CHANGED);
|
31044
|
+
const roomState = (0, import_react_sdk103.useHMSStore)(import_react_sdk103.selectRoomState);
|
31045
|
+
const vanillaStore = (0, import_react_sdk103.useHMSVanillaStore)();
|
30985
31046
|
const { on_stage_exp } = useRoomLayoutConferencingScreen().elements || {};
|
30986
31047
|
(0, import_react201.useEffect)(() => {
|
30987
31048
|
if (!(notification == null ? void 0 : notification.data)) {
|
30988
31049
|
return;
|
30989
31050
|
}
|
30990
|
-
if (roomState !==
|
31051
|
+
if (roomState !== import_react_sdk103.HMSRoomState.Connected || notification.data.isLocal || !on_stage_exp) {
|
30991
31052
|
return;
|
30992
31053
|
}
|
30993
|
-
const hasPeerHandRaised = vanillaStore.getState((0,
|
31054
|
+
const hasPeerHandRaised = vanillaStore.getState((0, import_react_sdk103.selectHasPeerHandRaised)(notification.data.id));
|
30994
31055
|
if (hasPeerHandRaised) {
|
30995
31056
|
ToastBatcher.showToast({ notification, type: "RAISE_HAND" });
|
30996
31057
|
}
|
@@ -31001,17 +31062,17 @@ var init_HandRaisedNotifications = __esm({
|
|
31001
31062
|
});
|
31002
31063
|
|
31003
31064
|
// src/Prebuilt/components/Notifications/InitErrorModal.tsx
|
31004
|
-
var import_react202,
|
31065
|
+
var import_react202, import_react_sdk104, InitErrorModal;
|
31005
31066
|
var init_InitErrorModal = __esm({
|
31006
31067
|
"src/Prebuilt/components/Notifications/InitErrorModal.tsx"() {
|
31007
31068
|
"use strict";
|
31008
31069
|
init_define_process_env();
|
31009
31070
|
import_react202 = __toESM(require("react"));
|
31010
|
-
|
31071
|
+
import_react_sdk104 = require("@100mslive/react-sdk");
|
31011
31072
|
init_src();
|
31012
31073
|
init_DialogContent2();
|
31013
31074
|
InitErrorModal = () => {
|
31014
|
-
const notification = (0,
|
31075
|
+
const notification = (0, import_react_sdk104.useHMSNotifications)(import_react_sdk104.HMSNotificationTypes.ERROR);
|
31015
31076
|
const [showModal, setShowModal] = (0, import_react202.useState)(false);
|
31016
31077
|
const [info, setInfo] = (0, import_react202.useState)({ title: "Init Error", description: "" });
|
31017
31078
|
(0, import_react202.useEffect)(() => {
|
@@ -31040,23 +31101,23 @@ var init_InitErrorModal = __esm({
|
|
31040
31101
|
});
|
31041
31102
|
|
31042
31103
|
// src/Prebuilt/components/Notifications/PeerNotifications.tsx
|
31043
|
-
var import_react203,
|
31104
|
+
var import_react203, import_react_sdk105, notificationTypes, PeerNotifications;
|
31044
31105
|
var init_PeerNotifications = __esm({
|
31045
31106
|
"src/Prebuilt/components/Notifications/PeerNotifications.tsx"() {
|
31046
31107
|
"use strict";
|
31047
31108
|
init_define_process_env();
|
31048
31109
|
import_react203 = require("react");
|
31049
|
-
|
31110
|
+
import_react_sdk105 = require("@100mslive/react-sdk");
|
31050
31111
|
init_ToastBatcher();
|
31051
31112
|
init_useUISettings();
|
31052
31113
|
init_constants();
|
31053
31114
|
notificationTypes = [
|
31054
|
-
|
31055
|
-
|
31056
|
-
|
31115
|
+
import_react_sdk105.HMSNotificationTypes.PEER_LIST,
|
31116
|
+
import_react_sdk105.HMSNotificationTypes.PEER_JOINED,
|
31117
|
+
import_react_sdk105.HMSNotificationTypes.PEER_LEFT
|
31057
31118
|
];
|
31058
31119
|
PeerNotifications = () => {
|
31059
|
-
const notification = (0,
|
31120
|
+
const notification = (0, import_react_sdk105.useHMSNotifications)(notificationTypes);
|
31060
31121
|
const isPeerJoinSubscribed = useSubscribedNotifications(SUBSCRIBED_NOTIFICATIONS.PEER_JOINED);
|
31061
31122
|
const isPeerLeftSubscribed = useSubscribedNotifications(SUBSCRIBED_NOTIFICATIONS.PEER_LEFT);
|
31062
31123
|
const [selectedPeer, setPeerSelector] = useSetSubscribedChatSelector(CHAT_SELECTOR.PEER);
|
@@ -31066,17 +31127,17 @@ var init_PeerNotifications = __esm({
|
|
31066
31127
|
}
|
31067
31128
|
console.debug(`[${notification.type}]`, notification);
|
31068
31129
|
switch (notification.type) {
|
31069
|
-
case
|
31130
|
+
case import_react_sdk105.HMSNotificationTypes.PEER_LIST:
|
31070
31131
|
if (!isPeerJoinSubscribed || notification.data.length === 0) {
|
31071
31132
|
return;
|
31072
31133
|
}
|
31073
31134
|
break;
|
31074
|
-
case
|
31135
|
+
case import_react_sdk105.HMSNotificationTypes.PEER_JOINED:
|
31075
31136
|
if (!isPeerJoinSubscribed) {
|
31076
31137
|
return;
|
31077
31138
|
}
|
31078
31139
|
break;
|
31079
|
-
case
|
31140
|
+
case import_react_sdk105.HMSNotificationTypes.PEER_LEFT:
|
31080
31141
|
if (selectedPeer.id === notification.data.id) {
|
31081
31142
|
setPeerSelector({});
|
31082
31143
|
}
|
@@ -31112,7 +31173,7 @@ var init_ios_perm_0 = __esm({
|
|
31112
31173
|
|
31113
31174
|
// src/Prebuilt/components/Notifications/PermissionErrorModal.tsx
|
31114
31175
|
function PermissionErrorModal() {
|
31115
|
-
const notification = (0,
|
31176
|
+
const notification = (0, import_react_sdk106.useHMSNotifications)(import_react_sdk106.HMSNotificationTypes.ERROR);
|
31116
31177
|
const [deviceType, setDeviceType] = (0, import_react204.useState)("");
|
31117
31178
|
const [isSystemError, setIsSystemError] = (0, import_react204.useState)(false);
|
31118
31179
|
const isMobile = (0, import_react_use42.useMedia)(config.media.md);
|
@@ -31171,14 +31232,14 @@ function PermissionErrorModal() {
|
|
31171
31232
|
!isMobile ? /* @__PURE__ */ import_react204.default.createElement(Flex, { justify: "end", css: { w: "100%" } }, /* @__PURE__ */ import_react204.default.createElement(Button, { outlined: true, variant: "standard", onClick: () => setDeviceType("") }, "Dismiss")) : null
|
31172
31233
|
))) : null;
|
31173
31234
|
}
|
31174
|
-
var import_react204, import_react_use42,
|
31235
|
+
var import_react204, import_react_use42, import_react_sdk106;
|
31175
31236
|
var init_PermissionErrorModal = __esm({
|
31176
31237
|
"src/Prebuilt/components/Notifications/PermissionErrorModal.tsx"() {
|
31177
31238
|
"use strict";
|
31178
31239
|
init_define_process_env();
|
31179
31240
|
import_react204 = __toESM(require("react"));
|
31180
31241
|
import_react_use42 = require("react-use");
|
31181
|
-
|
31242
|
+
import_react_sdk106 = require("@100mslive/react-sdk");
|
31182
31243
|
init_src();
|
31183
31244
|
init_android_perm_1();
|
31184
31245
|
init_ios_perm_0();
|
@@ -31187,36 +31248,36 @@ var init_PermissionErrorModal = __esm({
|
|
31187
31248
|
});
|
31188
31249
|
|
31189
31250
|
// src/Prebuilt/components/Notifications/ReconnectNotifications.tsx
|
31190
|
-
var import_react205,
|
31251
|
+
var import_react205, import_react_sdk107, notificationTypes2, notificationId, ReconnectNotifications;
|
31191
31252
|
var init_ReconnectNotifications = __esm({
|
31192
31253
|
"src/Prebuilt/components/Notifications/ReconnectNotifications.tsx"() {
|
31193
31254
|
"use strict";
|
31194
31255
|
init_define_process_env();
|
31195
31256
|
import_react205 = __toESM(require("react"));
|
31196
|
-
|
31257
|
+
import_react_sdk107 = require("@100mslive/react-sdk");
|
31197
31258
|
init_src();
|
31198
31259
|
init_ToastConfig();
|
31199
31260
|
init_ToastManager();
|
31200
31261
|
notificationTypes2 = [
|
31201
|
-
|
31202
|
-
|
31203
|
-
|
31262
|
+
import_react_sdk107.HMSNotificationTypes.RECONNECTED,
|
31263
|
+
import_react_sdk107.HMSNotificationTypes.RECONNECTING,
|
31264
|
+
import_react_sdk107.HMSNotificationTypes.ERROR
|
31204
31265
|
];
|
31205
31266
|
notificationId = null;
|
31206
31267
|
ReconnectNotifications = () => {
|
31207
|
-
const notification = (0,
|
31268
|
+
const notification = (0, import_react_sdk107.useHMSNotifications)(notificationTypes2);
|
31208
31269
|
const [open, setOpen] = (0, import_react205.useState)(false);
|
31209
31270
|
(0, import_react205.useEffect)(() => {
|
31210
31271
|
var _a8, _b7;
|
31211
31272
|
if (!notification) {
|
31212
31273
|
return;
|
31213
31274
|
}
|
31214
|
-
if (notification.type ===
|
31275
|
+
if (notification.type === import_react_sdk107.HMSNotificationTypes.ERROR && ((_a8 = notification.data) == null ? void 0 : _a8.isTerminal)) {
|
31215
31276
|
setOpen(false);
|
31216
|
-
} else if (notification.type ===
|
31277
|
+
} else if (notification.type === import_react_sdk107.HMSNotificationTypes.RECONNECTED) {
|
31217
31278
|
notificationId = ToastManager.replaceToast(notificationId, ToastConfig.RECONNECTED.single());
|
31218
31279
|
setOpen(false);
|
31219
|
-
} else if (notification.type ===
|
31280
|
+
} else if (notification.type === import_react_sdk107.HMSNotificationTypes.RECONNECTING) {
|
31220
31281
|
notificationId = ToastManager.replaceToast(
|
31221
31282
|
notificationId,
|
31222
31283
|
ToastConfig.RECONNECTING.single((_b7 = notification.data) == null ? void 0 : _b7.message)
|
@@ -31246,30 +31307,30 @@ var init_ReconnectNotifications = __esm({
|
|
31246
31307
|
});
|
31247
31308
|
|
31248
31309
|
// src/Prebuilt/components/Notifications/TrackBulkUnmuteModal.tsx
|
31249
|
-
var import_react206,
|
31310
|
+
var import_react206, import_react_sdk108, import_react_icons95, TrackBulkUnmuteModal;
|
31250
31311
|
var init_TrackBulkUnmuteModal = __esm({
|
31251
31312
|
"src/Prebuilt/components/Notifications/TrackBulkUnmuteModal.tsx"() {
|
31252
31313
|
"use strict";
|
31253
31314
|
init_define_process_env();
|
31254
31315
|
import_react206 = __toESM(require("react"));
|
31255
|
-
|
31316
|
+
import_react_sdk108 = require("@100mslive/react-sdk");
|
31256
31317
|
import_react_icons95 = require("@100mslive/react-icons");
|
31257
31318
|
init_DialogContent2();
|
31258
31319
|
TrackBulkUnmuteModal = () => {
|
31259
|
-
const hmsActions = (0,
|
31320
|
+
const hmsActions = (0, import_react_sdk108.useHMSActions)();
|
31260
31321
|
const [muteNotification, setMuteNotification] = (0, import_react206.useState)(null);
|
31261
|
-
const notification = (0,
|
31262
|
-
|
31263
|
-
|
31264
|
-
|
31322
|
+
const notification = (0, import_react_sdk108.useHMSNotifications)([
|
31323
|
+
import_react_sdk108.HMSNotificationTypes.CHANGE_MULTI_TRACK_STATE_REQUEST,
|
31324
|
+
import_react_sdk108.HMSNotificationTypes.ROOM_ENDED,
|
31325
|
+
import_react_sdk108.HMSNotificationTypes.REMOVED_FROM_ROOM
|
31265
31326
|
]);
|
31266
31327
|
(0, import_react206.useEffect)(() => {
|
31267
31328
|
switch (notification == null ? void 0 : notification.type) {
|
31268
|
-
case
|
31269
|
-
case
|
31329
|
+
case import_react_sdk108.HMSNotificationTypes.REMOVED_FROM_ROOM:
|
31330
|
+
case import_react_sdk108.HMSNotificationTypes.ROOM_ENDED:
|
31270
31331
|
setMuteNotification(null);
|
31271
31332
|
break;
|
31272
|
-
case
|
31333
|
+
case import_react_sdk108.HMSNotificationTypes.CHANGE_MULTI_TRACK_STATE_REQUEST:
|
31273
31334
|
if (notification == null ? void 0 : notification.data.enabled) {
|
31274
31335
|
setMuteNotification(notification.data);
|
31275
31336
|
}
|
@@ -31302,21 +31363,21 @@ var init_TrackBulkUnmuteModal = __esm({
|
|
31302
31363
|
});
|
31303
31364
|
|
31304
31365
|
// src/Prebuilt/components/Notifications/TrackNotifications.tsx
|
31305
|
-
var import_react207,
|
31366
|
+
var import_react207, import_react_sdk109, notificationTypes3, TrackNotifications;
|
31306
31367
|
var init_TrackNotifications = __esm({
|
31307
31368
|
"src/Prebuilt/components/Notifications/TrackNotifications.tsx"() {
|
31308
31369
|
"use strict";
|
31309
31370
|
init_define_process_env();
|
31310
31371
|
import_react207 = require("react");
|
31311
|
-
|
31372
|
+
import_react_sdk109 = require("@100mslive/react-sdk");
|
31312
31373
|
notificationTypes3 = [
|
31313
|
-
|
31314
|
-
|
31315
|
-
|
31316
|
-
|
31374
|
+
import_react_sdk109.HMSNotificationTypes.TRACK_ADDED,
|
31375
|
+
import_react_sdk109.HMSNotificationTypes.TRACK_REMOVED,
|
31376
|
+
import_react_sdk109.HMSNotificationTypes.TRACK_MUTED,
|
31377
|
+
import_react_sdk109.HMSNotificationTypes.TRACK_UNMUTED
|
31317
31378
|
];
|
31318
31379
|
TrackNotifications = () => {
|
31319
|
-
const notification = (0,
|
31380
|
+
const notification = (0, import_react_sdk109.useHMSNotifications)(notificationTypes3);
|
31320
31381
|
(0, import_react207.useEffect)(() => {
|
31321
31382
|
if (notification) {
|
31322
31383
|
console.debug(`[${notification.type}]`, notification);
|
@@ -31328,30 +31389,30 @@ var init_TrackNotifications = __esm({
|
|
31328
31389
|
});
|
31329
31390
|
|
31330
31391
|
// src/Prebuilt/components/Notifications/TrackUnmuteModal.tsx
|
31331
|
-
var import_react208,
|
31392
|
+
var import_react208, import_react_sdk110, import_react_icons96, TrackUnmuteModal;
|
31332
31393
|
var init_TrackUnmuteModal = __esm({
|
31333
31394
|
"src/Prebuilt/components/Notifications/TrackUnmuteModal.tsx"() {
|
31334
31395
|
"use strict";
|
31335
31396
|
init_define_process_env();
|
31336
31397
|
import_react208 = __toESM(require("react"));
|
31337
|
-
|
31398
|
+
import_react_sdk110 = require("@100mslive/react-sdk");
|
31338
31399
|
import_react_icons96 = require("@100mslive/react-icons");
|
31339
31400
|
init_DialogContent2();
|
31340
31401
|
TrackUnmuteModal = () => {
|
31341
|
-
const hmsActions = (0,
|
31342
|
-
const notification = (0,
|
31343
|
-
|
31344
|
-
|
31345
|
-
|
31402
|
+
const hmsActions = (0, import_react_sdk110.useHMSActions)();
|
31403
|
+
const notification = (0, import_react_sdk110.useHMSNotifications)([
|
31404
|
+
import_react_sdk110.HMSNotificationTypes.CHANGE_TRACK_STATE_REQUEST,
|
31405
|
+
import_react_sdk110.HMSNotificationTypes.ROOM_ENDED,
|
31406
|
+
import_react_sdk110.HMSNotificationTypes.REMOVED_FROM_ROOM
|
31346
31407
|
]);
|
31347
31408
|
const [muteNotification, setMuteNotification] = (0, import_react208.useState)(null);
|
31348
31409
|
(0, import_react208.useEffect)(() => {
|
31349
31410
|
switch (notification == null ? void 0 : notification.type) {
|
31350
|
-
case
|
31351
|
-
case
|
31411
|
+
case import_react_sdk110.HMSNotificationTypes.REMOVED_FROM_ROOM:
|
31412
|
+
case import_react_sdk110.HMSNotificationTypes.ROOM_ENDED:
|
31352
31413
|
setMuteNotification(null);
|
31353
31414
|
break;
|
31354
|
-
case
|
31415
|
+
case import_react_sdk110.HMSNotificationTypes.CHANGE_TRACK_STATE_REQUEST:
|
31355
31416
|
if (notification == null ? void 0 : notification.data.enabled) {
|
31356
31417
|
setMuteNotification(notification.data);
|
31357
31418
|
}
|
@@ -31383,14 +31444,14 @@ var init_TrackUnmuteModal = __esm({
|
|
31383
31444
|
|
31384
31445
|
// src/Prebuilt/components/Notifications/Notifications.tsx
|
31385
31446
|
function Notifications() {
|
31386
|
-
const localPeerID = (0,
|
31387
|
-
const notification = (0,
|
31447
|
+
const localPeerID = (0, import_react_sdk111.useHMSStore)(import_react_sdk111.selectLocalPeerID);
|
31448
|
+
const notification = (0, import_react_sdk111.useHMSNotifications)();
|
31388
31449
|
const subscribedNotifications = useSubscribedNotifications() || {};
|
31389
|
-
const roomState = (0,
|
31450
|
+
const roomState = (0, import_react_sdk111.useHMSStore)(import_react_sdk111.selectRoomState);
|
31390
31451
|
const updateRoomLayoutForRole = useUpdateRoomLayout();
|
31391
31452
|
const isNotificationDisabled = useIsNotificationDisabled();
|
31392
31453
|
const screenProps = useRoomLayoutConferencingScreen();
|
31393
|
-
const vanillaStore = (0,
|
31454
|
+
const vanillaStore = (0, import_react_sdk111.useHMSVanillaStore)();
|
31394
31455
|
const togglePollView = usePollViewToggle();
|
31395
31456
|
const handleRoleChangeDenied = (0, import_react209.useCallback)((request) => {
|
31396
31457
|
ToastManager.addToast({
|
@@ -31398,15 +31459,15 @@ function Notifications() {
|
|
31398
31459
|
variant: "error"
|
31399
31460
|
});
|
31400
31461
|
}, []);
|
31401
|
-
(0,
|
31462
|
+
(0, import_react_sdk111.useCustomEvent)({ type: ROLE_CHANGE_DECLINED, onEvent: handleRoleChangeDenied });
|
31402
31463
|
(0, import_react209.useEffect)(() => {
|
31403
31464
|
var _a8, _b7, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n2, _o, _p, _q;
|
31404
31465
|
if (!notification || isNotificationDisabled) {
|
31405
31466
|
return;
|
31406
31467
|
}
|
31407
31468
|
switch (notification.type) {
|
31408
|
-
case
|
31409
|
-
if (roomState !==
|
31469
|
+
case import_react_sdk111.HMSNotificationTypes.METADATA_UPDATED:
|
31470
|
+
if (roomState !== import_react_sdk111.HMSRoomState.Connected) {
|
31410
31471
|
return;
|
31411
31472
|
}
|
31412
31473
|
const metadata = getMetadata((_a8 = notification.data) == null ? void 0 : _a8.metadata);
|
@@ -31417,10 +31478,10 @@ function Notifications() {
|
|
31417
31478
|
return;
|
31418
31479
|
ToastBatcher.showToast({ notification, type: "RAISE_HAND" });
|
31419
31480
|
break;
|
31420
|
-
case
|
31481
|
+
case import_react_sdk111.HMSNotificationTypes.NAME_UPDATED:
|
31421
31482
|
console.log(notification.data.id + " changed their name to " + notification.data.name);
|
31422
31483
|
break;
|
31423
|
-
case
|
31484
|
+
case import_react_sdk111.HMSNotificationTypes.ERROR:
|
31424
31485
|
if (((_b7 = notification.data) == null ? void 0 : _b7.isTerminal) && ((_c = notification.data) == null ? void 0 : _c.action) !== "INIT") {
|
31425
31486
|
if ([500, 6008].includes((_d = notification.data) == null ? void 0 : _d.code)) {
|
31426
31487
|
ToastManager.addToast({
|
@@ -31452,7 +31513,7 @@ function Notifications() {
|
|
31452
31513
|
title: `Error: ${(_l = notification.data) == null ? void 0 : _l.message} - ${(_m = notification.data) == null ? void 0 : _m.description}`
|
31453
31514
|
});
|
31454
31515
|
break;
|
31455
|
-
case
|
31516
|
+
case import_react_sdk111.HMSNotificationTypes.ROLE_UPDATED: {
|
31456
31517
|
if (((_n2 = notification.data) == null ? void 0 : _n2.isLocal) && ((_o = notification.data) == null ? void 0 : _o.roleName)) {
|
31457
31518
|
ToastManager.addToast({
|
31458
31519
|
title: `You are now a ${notification.data.roleName}`
|
@@ -31461,7 +31522,7 @@ function Notifications() {
|
|
31461
31522
|
}
|
31462
31523
|
break;
|
31463
31524
|
}
|
31464
|
-
case
|
31525
|
+
case import_react_sdk111.HMSNotificationTypes.CHANGE_TRACK_STATE_REQUEST:
|
31465
31526
|
const track = (_p = notification.data) == null ? void 0 : _p.track;
|
31466
31527
|
if (!notification.data.enabled) {
|
31467
31528
|
ToastManager.addToast({
|
@@ -31470,21 +31531,21 @@ function Notifications() {
|
|
31470
31531
|
});
|
31471
31532
|
}
|
31472
31533
|
break;
|
31473
|
-
case
|
31474
|
-
case
|
31534
|
+
case import_react_sdk111.HMSNotificationTypes.REMOVED_FROM_ROOM:
|
31535
|
+
case import_react_sdk111.HMSNotificationTypes.ROOM_ENDED:
|
31475
31536
|
ToastManager.addToast({
|
31476
31537
|
title: `${notification.message}.
|
31477
31538
|
${notification.data.reason && `Reason: ${notification.data.reason}`}`
|
31478
31539
|
});
|
31479
31540
|
break;
|
31480
|
-
case
|
31541
|
+
case import_react_sdk111.HMSNotificationTypes.DEVICE_CHANGE_UPDATE:
|
31481
31542
|
ToastManager.addToast({
|
31482
31543
|
title: notification.message
|
31483
31544
|
});
|
31484
31545
|
break;
|
31485
|
-
case
|
31546
|
+
case import_react_sdk111.HMSNotificationTypes.POLL_STARTED:
|
31486
31547
|
if (notification.data.startedBy !== localPeerID && screenProps.screenType !== "hls_live_streaming") {
|
31487
|
-
const pollStartedBy = vanillaStore.getState((0,
|
31548
|
+
const pollStartedBy = vanillaStore.getState((0, import_react_sdk111.selectPeerNameByID)(notification.data.startedBy)) || "Participant";
|
31488
31549
|
const pollToastID = ToastManager.addToast({
|
31489
31550
|
title: `${pollStartedBy} started a ${notification.data.type}: ${notification.data.title}`,
|
31490
31551
|
action: /* @__PURE__ */ import_react209.default.createElement(
|
@@ -31506,7 +31567,7 @@ function Notifications() {
|
|
31506
31567
|
pollToastKey[notification.data.id] = pollToastID;
|
31507
31568
|
}
|
31508
31569
|
break;
|
31509
|
-
case
|
31570
|
+
case import_react_sdk111.HMSNotificationTypes.POLL_STOPPED:
|
31510
31571
|
const pollID = notification == null ? void 0 : notification.data.id;
|
31511
31572
|
if (pollID && (pollToastKey == null ? void 0 : pollToastKey[pollID])) {
|
31512
31573
|
ToastManager.removeToast(pollToastKey == null ? void 0 : pollToastKey[notification.data.id]);
|
@@ -31520,15 +31581,15 @@ function Notifications() {
|
|
31520
31581
|
if (isNotificationDisabled) {
|
31521
31582
|
return null;
|
31522
31583
|
}
|
31523
|
-
return /* @__PURE__ */ import_react209.default.createElement(import_react209.default.Fragment, null, /* @__PURE__ */ import_react209.default.createElement(TrackUnmuteModal, null), /* @__PURE__ */ import_react209.default.createElement(TrackBulkUnmuteModal, null), /* @__PURE__ */ import_react209.default.createElement(TrackNotifications, null), roomState ===
|
31584
|
+
return /* @__PURE__ */ import_react209.default.createElement(import_react209.default.Fragment, null, /* @__PURE__ */ import_react209.default.createElement(TrackUnmuteModal, null), /* @__PURE__ */ import_react209.default.createElement(TrackBulkUnmuteModal, null), /* @__PURE__ */ import_react209.default.createElement(TrackNotifications, null), roomState === import_react_sdk111.HMSRoomState.Connected ? /* @__PURE__ */ import_react209.default.createElement(PeerNotifications, null) : null, /* @__PURE__ */ import_react209.default.createElement(ReconnectNotifications, null), /* @__PURE__ */ import_react209.default.createElement(AutoplayBlockedModal, null), /* @__PURE__ */ import_react209.default.createElement(PermissionErrorModal, null), /* @__PURE__ */ import_react209.default.createElement(InitErrorModal, null), /* @__PURE__ */ import_react209.default.createElement(ChatNotifications, null), /* @__PURE__ */ import_react209.default.createElement(HandRaisedNotifications, null));
|
31524
31585
|
}
|
31525
|
-
var import_react209,
|
31586
|
+
var import_react209, import_react_sdk111, import_react_icons97, pollToastKey;
|
31526
31587
|
var init_Notifications = __esm({
|
31527
31588
|
"src/Prebuilt/components/Notifications/Notifications.tsx"() {
|
31528
31589
|
"use strict";
|
31529
31590
|
init_define_process_env();
|
31530
31591
|
import_react209 = __toESM(require("react"));
|
31531
|
-
|
31592
|
+
import_react_sdk111 = require("@100mslive/react-sdk");
|
31532
31593
|
import_react_icons97 = require("@100mslive/react-icons");
|
31533
31594
|
init_src();
|
31534
31595
|
init_roomLayoutProvider();
|
@@ -31628,19 +31689,19 @@ var init_Toast3 = __esm({
|
|
31628
31689
|
});
|
31629
31690
|
|
31630
31691
|
// src/Prebuilt/components/Toast/ToastContainer.jsx
|
31631
|
-
var import_react212,
|
31692
|
+
var import_react212, import_react_sdk112, ToastContainer;
|
31632
31693
|
var init_ToastContainer = __esm({
|
31633
31694
|
"src/Prebuilt/components/Toast/ToastContainer.jsx"() {
|
31634
31695
|
"use strict";
|
31635
31696
|
init_define_process_env();
|
31636
31697
|
import_react212 = __toESM(require("react"));
|
31637
|
-
|
31698
|
+
import_react_sdk112 = require("@100mslive/react-sdk");
|
31638
31699
|
init_Toast2();
|
31639
31700
|
init_Toast3();
|
31640
31701
|
init_ToastManager();
|
31641
31702
|
init_constants();
|
31642
31703
|
ToastContainer = () => {
|
31643
|
-
const isConnected = (0,
|
31704
|
+
const isConnected = (0, import_react_sdk112.useHMSStore)(import_react_sdk112.selectIsConnectedToRoom);
|
31644
31705
|
const [toasts, setToast] = (0, import_react212.useState)([]);
|
31645
31706
|
(0, import_react212.useEffect)(() => {
|
31646
31707
|
ToastManager.addListener(setToast);
|
@@ -31664,8 +31725,8 @@ var init_ToastContainer = __esm({
|
|
31664
31725
|
|
31665
31726
|
// src/Prebuilt/plugins/FlyingEmoji.jsx
|
31666
31727
|
function FlyingEmoji() {
|
31667
|
-
const localPeerId = (0,
|
31668
|
-
const vanillaStore = (0,
|
31728
|
+
const localPeerId = (0, import_react_sdk113.useHMSStore)(import_react_sdk113.selectLocalPeerID);
|
31729
|
+
const vanillaStore = (0, import_react_sdk113.useHMSVanillaStore)();
|
31669
31730
|
const [emojis, setEmojis] = (0, import_react213.useState)([]);
|
31670
31731
|
const isMobile = (0, import_react_use44.useMedia)(config.media.md);
|
31671
31732
|
const startingPoints = (0, import_react213.useMemo)(() => getStartingPoints(isMobile), [isMobile]);
|
@@ -31674,7 +31735,7 @@ function FlyingEmoji() {
|
|
31674
31735
|
if (!emojiId || !senderId || document.hidden) {
|
31675
31736
|
return;
|
31676
31737
|
}
|
31677
|
-
const senderPeerName = vanillaStore.getState((0,
|
31738
|
+
const senderPeerName = vanillaStore.getState((0, import_react_sdk113.selectPeerNameByID)(senderId));
|
31678
31739
|
const nameToShow = localPeerId === senderId ? "You" : senderPeerName;
|
31679
31740
|
const startingPoint = startingPoints[emojiCount % startingPoints.length];
|
31680
31741
|
const id = emojiCount++;
|
@@ -31693,7 +31754,7 @@ function FlyingEmoji() {
|
|
31693
31754
|
},
|
31694
31755
|
[localPeerId, vanillaStore, startingPoints]
|
31695
31756
|
);
|
31696
|
-
(0,
|
31757
|
+
(0, import_react_sdk113.useCustomEvent)({
|
31697
31758
|
type: EMOJI_REACTION_TYPE,
|
31698
31759
|
onEvent: showFlyingEmoji
|
31699
31760
|
});
|
@@ -31759,14 +31820,14 @@ function FlyingEmoji() {
|
|
31759
31820
|
})
|
31760
31821
|
);
|
31761
31822
|
}
|
31762
|
-
var import_react213, import_react_use44,
|
31823
|
+
var import_react213, import_react_use44, import_react_sdk113, emojiCount, flyAndFade, wiggleLeftRight, wiggleRightLeft, getStartingPoints;
|
31763
31824
|
var init_FlyingEmoji = __esm({
|
31764
31825
|
"src/Prebuilt/plugins/FlyingEmoji.jsx"() {
|
31765
31826
|
"use strict";
|
31766
31827
|
init_define_process_env();
|
31767
31828
|
import_react213 = __toESM(require("react"));
|
31768
31829
|
import_react_use44 = require("react-use");
|
31769
|
-
|
31830
|
+
import_react_sdk113 = require("@100mslive/react-sdk");
|
31770
31831
|
init_Layout();
|
31771
31832
|
init_Text2();
|
31772
31833
|
init_Theme();
|
@@ -31799,45 +31860,45 @@ var init_FlyingEmoji = __esm({
|
|
31799
31860
|
|
31800
31861
|
// src/Prebuilt/plugins/RemoteStopScreenshare.jsx
|
31801
31862
|
function RemoteStopScreenshare() {
|
31802
|
-
const actions = (0,
|
31863
|
+
const actions = (0, import_react_sdk114.useHMSActions)();
|
31803
31864
|
const onRemoteStopScreenshare = (0, import_react214.useCallback)(() => __async(this, null, function* () {
|
31804
31865
|
yield actions.setScreenShareEnabled(false);
|
31805
31866
|
}), [actions]);
|
31806
|
-
(0,
|
31867
|
+
(0, import_react_sdk114.useCustomEvent)({
|
31807
31868
|
type: REMOTE_STOP_SCREENSHARE_TYPE,
|
31808
31869
|
onEvent: onRemoteStopScreenshare
|
31809
31870
|
});
|
31810
31871
|
return /* @__PURE__ */ import_react214.default.createElement(import_react214.default.Fragment, null);
|
31811
31872
|
}
|
31812
|
-
var import_react214,
|
31873
|
+
var import_react214, import_react_sdk114;
|
31813
31874
|
var init_RemoteStopScreenshare = __esm({
|
31814
31875
|
"src/Prebuilt/plugins/RemoteStopScreenshare.jsx"() {
|
31815
31876
|
"use strict";
|
31816
31877
|
init_define_process_env();
|
31817
31878
|
import_react214 = __toESM(require("react"));
|
31818
|
-
|
31879
|
+
import_react_sdk114 = require("@100mslive/react-sdk");
|
31819
31880
|
init_constants();
|
31820
31881
|
}
|
31821
31882
|
});
|
31822
31883
|
|
31823
31884
|
// src/Prebuilt/components/hooks/useAutoStartStreaming.tsx
|
31824
|
-
var import_react215,
|
31885
|
+
var import_react215, import_react_sdk115, useAutoStartStreaming;
|
31825
31886
|
var init_useAutoStartStreaming = __esm({
|
31826
31887
|
"src/Prebuilt/components/hooks/useAutoStartStreaming.tsx"() {
|
31827
31888
|
"use strict";
|
31828
31889
|
init_define_process_env();
|
31829
31890
|
import_react215 = require("react");
|
31830
|
-
|
31891
|
+
import_react_sdk115 = require("@100mslive/react-sdk");
|
31831
31892
|
init_useUISettings();
|
31832
31893
|
init_hooks();
|
31833
31894
|
init_constants();
|
31834
31895
|
useAutoStartStreaming = () => {
|
31835
31896
|
const [isHLSStarted, setHLSStarted] = useSetAppDataByKey(APP_DATA.hlsStarted);
|
31836
|
-
const permissions = (0,
|
31897
|
+
const permissions = (0, import_react_sdk115.useHMSStore)(import_react_sdk115.selectPermissions);
|
31837
31898
|
const showStreamingUI = useShowStreamingUI();
|
31838
|
-
const hmsActions = (0,
|
31839
|
-
const isConnected = (0,
|
31840
|
-
const { isHLSRunning, isRTMPRunning, isHLSRecordingOn, isBrowserRecordingOn } = (0,
|
31899
|
+
const hmsActions = (0, import_react_sdk115.useHMSActions)();
|
31900
|
+
const isConnected = (0, import_react_sdk115.useHMSStore)(import_react_sdk115.selectIsConnectedToRoom);
|
31901
|
+
const { isHLSRunning, isRTMPRunning, isHLSRecordingOn, isBrowserRecordingOn } = (0, import_react_sdk115.useRecordingStreaming)();
|
31841
31902
|
const streamStartedRef = (0, import_react215.useRef)(false);
|
31842
31903
|
const startHLS = (0, import_react215.useCallback)(() => __async(void 0, null, function* () {
|
31843
31904
|
try {
|
@@ -31887,13 +31948,13 @@ function AppRoutes({
|
|
31887
31948
|
const { activeState, rejoin } = useAppStateManager();
|
31888
31949
|
return /* @__PURE__ */ import_react216.default.createElement(AppStateContext.Provider, { value: { rejoin } }, /* @__PURE__ */ import_react216.default.createElement(import_react216.default.Fragment, null, /* @__PURE__ */ import_react216.default.createElement(ToastContainer, null), /* @__PURE__ */ import_react216.default.createElement(Notifications, null), /* @__PURE__ */ import_react216.default.createElement(MwebLandscapePrompt, null), /* @__PURE__ */ import_react216.default.createElement(BackSwipe, null), !isNotificationsDisabled && /* @__PURE__ */ import_react216.default.createElement(FlyingEmoji, null), /* @__PURE__ */ import_react216.default.createElement(RemoteStopScreenshare, null), /* @__PURE__ */ import_react216.default.createElement(KeyboardHandler, null), /* @__PURE__ */ import_react216.default.createElement(AuthToken_default, { authTokenByRoomCodeEndpoint, defaultAuthToken }), roomLayout && activeState && /* @__PURE__ */ import_react216.default.createElement(AppStates, { activeState })));
|
31889
31950
|
}
|
31890
|
-
var import_react216,
|
31951
|
+
var import_react216, import_react_sdk116, HMSPrebuilt, AppStates, BackSwipe;
|
31891
31952
|
var init_App = __esm({
|
31892
31953
|
"src/Prebuilt/App.tsx"() {
|
31893
31954
|
"use strict";
|
31894
31955
|
init_define_process_env();
|
31895
31956
|
import_react216 = __toESM(require("react"));
|
31896
|
-
|
31957
|
+
import_react_sdk116 = require("@100mslive/react-sdk");
|
31897
31958
|
init_AppData();
|
31898
31959
|
init_AuthToken();
|
31899
31960
|
init_ConferenceScreen();
|
@@ -31937,7 +31998,7 @@ var init_App = __esm({
|
|
31937
31998
|
const [hydrated, setHydrated] = import_react216.default.useState(false);
|
31938
31999
|
(0, import_react216.useEffect)(() => {
|
31939
32000
|
setHydrated(true);
|
31940
|
-
const hms = new
|
32001
|
+
const hms = new import_react_sdk116.HMSReactiveStore();
|
31941
32002
|
const hmsStore = hms.getStore();
|
31942
32003
|
const hmsActions = hms.getActions();
|
31943
32004
|
const hmsNotifications = hms.getNotifications();
|
@@ -32004,7 +32065,7 @@ var init_App = __esm({
|
|
32004
32065
|
}
|
32005
32066
|
},
|
32006
32067
|
/* @__PURE__ */ import_react216.default.createElement(
|
32007
|
-
|
32068
|
+
import_react_sdk116.HMSRoomProvider,
|
32008
32069
|
{
|
32009
32070
|
isHMSStatsOn: FeatureFlags.enableStatsForNerds,
|
32010
32071
|
actions: (_a8 = reactiveStore.current) == null ? void 0 : _a8.hmsActions,
|
@@ -32075,8 +32136,8 @@ var init_App = __esm({
|
|
32075
32136
|
return /* @__PURE__ */ import_react216.default.createElement(ConferenceScreen, null);
|
32076
32137
|
};
|
32077
32138
|
BackSwipe = () => {
|
32078
|
-
const isConnectedToRoom = (0,
|
32079
|
-
const hmsActions = (0,
|
32139
|
+
const isConnectedToRoom = (0, import_react_sdk116.useHMSStore)(import_react_sdk116.selectIsConnectedToRoom);
|
32140
|
+
const hmsActions = (0, import_react_sdk116.useHMSActions)();
|
32080
32141
|
(0, import_react216.useEffect)(() => {
|
32081
32142
|
const onRouteLeave = () => __async(void 0, null, function* () {
|
32082
32143
|
if (isConnectedToRoom) {
|