@100mslive/roomkit-react 0.2.1-alpha.0 → 0.2.1-alpha.2
Sign up to get free protection for your applications and to get access to all the features.
- package/LICENSE +21 -0
- package/dist/{HLSView-GKCGIZ5F.js → HLSView-S5JHEMWJ.js} +2 -2
- package/dist/Prebuilt/components/Polls/Voting/PeerParticipationSummary.d.ts +2 -2
- package/dist/Prebuilt/components/Polls/Voting/StatisticBox.d.ts +1 -1
- package/dist/Prebuilt/components/Polls/Voting/useQuizSummary.d.ts +7 -0
- package/dist/{chunk-FTOP3RHP.js → chunk-AWWYBQSE.js} +468 -452
- package/dist/chunk-AWWYBQSE.js.map +7 -0
- package/dist/index.cjs.js +1511 -1489
- package/dist/index.cjs.js.map +4 -4
- package/dist/index.js +1 -1
- package/dist/meta.cjs.json +124 -70
- package/dist/meta.esbuild.json +137 -83
- package/package.json +12 -6
- package/src/Introduction/Integrating.stories.mdx +1 -1
- package/src/Prebuilt/components/IconButtonWithOptions/IconButtonWithOptions.jsx +3 -3
- package/src/Prebuilt/components/Notifications/Notifications.tsx +14 -1
- package/src/Prebuilt/components/Polls/CreatePollQuiz/PollsQuizMenu.jsx +3 -4
- package/src/Prebuilt/components/Polls/CreateQuestions/QuestionForm.tsx +6 -5
- package/src/Prebuilt/components/Polls/Voting/LeaderboardSummary.tsx +7 -59
- package/src/Prebuilt/components/Polls/Voting/PeerParticipationSummary.tsx +40 -14
- package/src/Prebuilt/components/Polls/Voting/StandardVoting.tsx +1 -1
- package/src/Prebuilt/components/Polls/Voting/StatisticBox.tsx +16 -11
- package/src/Prebuilt/components/Polls/Voting/Voting.tsx +5 -7
- package/src/Prebuilt/components/Polls/Voting/useQuizSummary.tsx +50 -0
- package/src/Prebuilt/layouts/WhiteboardView.tsx +4 -1
- package/src/Toast/Toast.tsx +1 -0
- package/dist/chunk-FTOP3RHP.js.map +0 -7
- /package/dist/{HLSView-GKCGIZ5F.js.map → HLSView-S5JHEMWJ.js.map} +0 -0
@@ -106,7 +106,7 @@ var __async = (__this, __arguments, generator) => {
|
|
106
106
|
var define_process_env_default;
|
107
107
|
var init_define_process_env = __esm({
|
108
108
|
"<define:process.env>"() {
|
109
|
-
define_process_env_default = { GITHUB_STATE: "/home/runner/work/_temp/_runner_file_commands/save_state_a4f93a1f-1d98-495a-98c8-0f6e6403d9f9", 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_webpack_cli: "^4.9.2", npm_package_devDependencies_webpack_bundle_analyzer: "^4.5.0", 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.1-alpha.0", RUNNER_ENVIRONMENT: "github-hosted", GITHUB_ENV: "/home/runner/work/_temp/_runner_file_commands/set_env_a4f93a1f-1d98-495a-98c8-0f6e6403d9f9", 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.1-alpha.0", 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", 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_webpack_manifest_plugin: "^4.1.1", 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: "575", 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.12/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.5/x64", JAVA_HOME_17_X64: "/usr/lib/jvm/temurin-17-jdk-amd64", ImageVersion: "20240107.1.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:17700", GITHUB_WORKFLOW: "Publish Packages", _: "/usr/local/bin/yarn", npm_package_scripts_app: "cd apps/100ms-web && yarn start", 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.1-alpha.0", 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: "7537740304", 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: "37788eb004f63672aae22043c6ad6b2debaff74c", GITHUB_BASE_REF: "", ImageOS: "ubuntu22", npm_package_workspaces_1: "apps/*", npm_package_scripts_start: 'concurrently "yarn dev" "yarn types"', npm_config_ignore_scripts: "", NX_TASK_HASH: "6ce1787085583fb6cf0372909a361e891596089355bd31b1feb589a748471c8a", npm_package_exports___import: "./dist/index.js", STATS_BLT: "true", GITHUB_WORKFLOW_REF: "100mslive/web-sdks/.github/workflows/publish.yml@refs/heads/WEB-2557-border-fix", PERFLOG_LOCATION_SETTING: "RUNNER_PERFLOG", GITHUB_ACTION_REPOSITORY: "", npm_package_workspaces_2: "playwright/*", npm_package_scripts_prebuilt: "cd packages/roomkit-react && yarn start", npm_package_devDependencies_postcss_loader: "^6.2.1", PATH: "/tmp/yarn--1705385705823-0.4943793670942145:/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--1705385705521-0.8594408744126076:/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--1705385660800-0.3816056696696646:/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--1705385660494-0.274117397141719:/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_0b8b7624-fb1e-44ef-8457-934ab09c0e74", INVOCATION_ID: "4d0d31d6ec1843a9af78f038d52025fc", 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", GITHUB_ACTION: "__run_3", GITHUB_RUN_NUMBER: "411", 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_webpack: "^5.76.0", 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 3", XDG_CONFIG_HOME: "/home/runner/.config", STATS_VMD: "true", GITHUB_REF_NAME: "WEB-2557-border-fix", 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_webpack_dev_server: "^4.7.4", 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.1-alpha.0", npm_package_scripts_types: "tsc -w", GITHUB_REPOSITORY_ID: "429826515", GITHUB_ACTIONS: "true", STATS_NM: "true", npm_lifecycle_event: "build:only", npm_package_version: "0.2.1-alpha.0", 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_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: "37788eb004f63672aae22043c6ad6b2debaff74c", 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/WEB-2557-border-fix", GITHUB_ACTOR: "KaustubhKumar05", ANDROID_SDK_ROOT: "/usr/local/lib/android/sdk", npm_package_size_limit_5_path: "packages/hms-virtual-background/dist/index.js", npm_config_strict_ssl: "true", npm_package_license: "MIT", 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_a4f93a1f-1d98-495a-98c8-0f6e6403d9f9", 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_a4f93a1f-1d98-495a-98c8-0f6e6403d9f9", 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_scripts_app_custom: "cd apps/100ms-custom-app && 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_a4f93a1f-1d98-495a-98c8-0f6e6403d9f9" };
|
109
|
+
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", 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.1-alpha.2", 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.1", 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: "1d39446b045193a1060769172cf5e4d8f371cb30cc83089500d48f5243a66663", npm_package_repository_directory: "packages/roomkit-react", SSH_AUTH_SOCK: "/private/tmp/com.apple.launchd.8tHoKq6Yge/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--1705574182636-0.40094544212351324:/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--1705574182236-0.10136835258993937:/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--1705574157793-0.9903788580668094:/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--1705574182636-0.40094544212351324/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.1-alpha.2", 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.1-alpha.2", 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.1-alpha.2", 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.1-alpha.2", 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" };
|
110
110
|
}
|
111
111
|
});
|
112
112
|
|
@@ -10461,11 +10461,11 @@ var formatBytes = (bytes, unit = "B", decimals = 2) => {
|
|
10461
10461
|
return "-";
|
10462
10462
|
}
|
10463
10463
|
const k2 = 1024;
|
10464
|
-
const
|
10464
|
+
const dm2 = decimals < 0 ? 0 : decimals;
|
10465
10465
|
const sizes = ["", "K", "M", "G", "T", "P", "E", "Z", "Y"].map((size) => size + unit);
|
10466
10466
|
let i = Math.floor(Math.log(bytes) / Math.log(k2));
|
10467
10467
|
i === 0 && i++;
|
10468
|
-
return `${parseFloat((bytes / Math.pow(k2, i)).toFixed(
|
10468
|
+
return `${parseFloat((bytes / Math.pow(k2, i)).toFixed(dm2))} ${sizes[i]}`;
|
10469
10469
|
};
|
10470
10470
|
|
10471
10471
|
// src/Stats/StyledStats.tsx
|
@@ -10790,7 +10790,8 @@ var ToastDescription = styled(ToastPrimitives.Description, {
|
|
10790
10790
|
var ToastClose = styled(ToastPrimitives.Close, {});
|
10791
10791
|
var ToastAction = styled(ToastPrimitives.Action, {
|
10792
10792
|
cursor: "pointer",
|
10793
|
-
background: "none"
|
10793
|
+
background: "none",
|
10794
|
+
border: "none"
|
10794
10795
|
});
|
10795
10796
|
var ToastViewport = styled(ToastPrimitives.Viewport, {
|
10796
10797
|
position: "fixed",
|
@@ -11190,7 +11191,7 @@ import {
|
|
11190
11191
|
HMSRoomProvider,
|
11191
11192
|
selectIsConnectedToRoom as selectIsConnectedToRoom13,
|
11192
11193
|
useHMSActions as useHMSActions52,
|
11193
|
-
useHMSStore as
|
11194
|
+
useHMSStore as useHMSStore85
|
11194
11195
|
} from "@100mslive/react-sdk";
|
11195
11196
|
|
11196
11197
|
// src/Prebuilt/components/AppData/AppData.tsx
|
@@ -11813,14 +11814,14 @@ var AuthToken_default = AuthToken;
|
|
11813
11814
|
|
11814
11815
|
// src/Prebuilt/components/ConferenceScreen.tsx
|
11815
11816
|
init_define_process_env();
|
11816
|
-
import React150, { useEffect as useEffect47, useRef as useRef22, useState as
|
11817
|
+
import React150, { useEffect as useEffect47, useRef as useRef22, useState as useState61 } from "react";
|
11817
11818
|
import {
|
11818
11819
|
HMSRoomState as HMSRoomState7,
|
11819
11820
|
selectAppData as selectAppData7,
|
11820
11821
|
selectIsConnectedToRoom as selectIsConnectedToRoom10,
|
11821
11822
|
selectRoomState as selectRoomState7,
|
11822
11823
|
useHMSActions as useHMSActions45,
|
11823
|
-
useHMSStore as
|
11824
|
+
useHMSStore as useHMSStore75
|
11824
11825
|
} from "@100mslive/react-sdk";
|
11825
11826
|
|
11826
11827
|
// src/Prebuilt/components/Footer/Footer.tsx
|
@@ -11887,7 +11888,7 @@ var IconSection = styled(IconButton_default, {
|
|
11887
11888
|
p: "$4",
|
11888
11889
|
r: "$1",
|
11889
11890
|
borderTopRightRadius: 0,
|
11890
|
-
borderColor: "$
|
11891
|
+
borderColor: "$border_bright",
|
11891
11892
|
borderBottomRightRadius: 0,
|
11892
11893
|
position: "relative",
|
11893
11894
|
"&:not([disabled]):focus-visible": {
|
@@ -11902,10 +11903,10 @@ var IconSection = styled(IconButton_default, {
|
|
11902
11903
|
var OptionsSection = styled(IconButton_default, {
|
11903
11904
|
w: "unset",
|
11904
11905
|
h: "$14",
|
11905
|
-
p: "$4",
|
11906
|
+
p: "$4 $2",
|
11906
11907
|
r: "$1",
|
11907
11908
|
borderTopLeftRadius: 0,
|
11908
|
-
borderColor: "$
|
11909
|
+
borderColor: "$border_bright",
|
11909
11910
|
borderBottomLeftRadius: 0,
|
11910
11911
|
borderLeftWidth: 0,
|
11911
11912
|
position: "relative",
|
@@ -14593,10 +14594,10 @@ var formatBytes2 = (bytes, unit = "B", decimals = 2) => {
|
|
14593
14594
|
if (bytes === 0)
|
14594
14595
|
return "0 " + unit;
|
14595
14596
|
const k2 = 1024;
|
14596
|
-
const
|
14597
|
+
const dm2 = decimals < 0 ? 0 : decimals;
|
14597
14598
|
const sizes = ["", "K", "M", "G", "T", "P", "E", "Z", "Y"].map((size) => size + unit);
|
14598
14599
|
const i = Math.floor(Math.log(bytes) / Math.log(k2));
|
14599
|
-
return parseFloat((bytes / Math.pow(k2, i)).toFixed(
|
14600
|
+
return parseFloat((bytes / Math.pow(k2, i)).toFixed(dm2)) + " " + sizes[i];
|
14600
14601
|
};
|
14601
14602
|
|
14602
14603
|
// src/Prebuilt/components/MoreSettings/BulkRoleChangeModal.jsx
|
@@ -17241,12 +17242,12 @@ import { v4 as eo } from "uuid";
|
|
17241
17242
|
import { v4 as ro } from "uuid";
|
17242
17243
|
import { EventEmitter2 as so } from "eventemitter2";
|
17243
17244
|
var Ht = __toESM(require_lib());
|
17244
|
-
import { EventEmitter2 as
|
17245
|
+
import { EventEmitter2 as Po } from "eventemitter2";
|
17245
17246
|
import { v4 as bo } from "uuid";
|
17246
17247
|
import { EventEmitter2 as Ro } from "eventemitter2";
|
17247
17248
|
import Ho from "eventemitter2";
|
17248
17249
|
import { v4 as Io } from "uuid";
|
17249
|
-
import { v4 as
|
17250
|
+
import { v4 as wo } from "uuid";
|
17250
17251
|
var ga = Object.defineProperty;
|
17251
17252
|
var Ta = Object.defineProperties;
|
17252
17253
|
var fa = Object.getOwnPropertyDescriptors;
|
@@ -17254,7 +17255,7 @@ var Ot = Object.getOwnPropertySymbols;
|
|
17254
17255
|
var Fr = Object.prototype.hasOwnProperty;
|
17255
17256
|
var Gr = Object.prototype.propertyIsEnumerable;
|
17256
17257
|
var Br = (a2, e, t) => e in a2 ? ga(a2, e, { enumerable: true, configurable: true, writable: true, value: t }) : a2[e] = t;
|
17257
|
-
var
|
17258
|
+
var m = (a2, e) => {
|
17258
17259
|
for (var t in e || (e = {}))
|
17259
17260
|
Fr.call(e, t) && Br(a2, t, e[t]);
|
17260
17261
|
if (Ot)
|
@@ -17274,7 +17275,7 @@ var Qi = (a2, e) => {
|
|
17274
17275
|
};
|
17275
17276
|
var ya = (a2, e) => () => (e || a2((e = { exports: {} }).exports, e), e.exports);
|
17276
17277
|
var nr = ya((jc, Va) => {
|
17277
|
-
Va.exports = { version: "0.11.1-alpha.
|
17278
|
+
Va.exports = { version: "0.11.1-alpha.2", 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"] };
|
17278
17279
|
});
|
17279
17280
|
var 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 || {});
|
17280
17281
|
var ka = ((e) => (e.CHAT = "chat", e))(ka || {});
|
@@ -17286,7 +17287,7 @@ function He(a2, e) {
|
|
17286
17287
|
if (e)
|
17287
17288
|
for (let r of e.auxiliaryTracks) {
|
17288
17289
|
let s = a2[r];
|
17289
|
-
|
17290
|
+
Pa(s) && (i = Ze(s) ? s : i, t = et(s) ? s : t);
|
17290
17291
|
}
|
17291
17292
|
return { video: t, audio: i };
|
17292
17293
|
}
|
@@ -17296,7 +17297,7 @@ function Ze(a2) {
|
|
17296
17297
|
function et(a2) {
|
17297
17298
|
return a2 && a2.type === "video";
|
17298
17299
|
}
|
17299
|
-
function
|
17300
|
+
function Pa(a2) {
|
17300
17301
|
return a2 && a2.source === "screen";
|
17301
17302
|
}
|
17302
17303
|
function Vt(a2) {
|
@@ -17317,20 +17318,20 @@ function it(a2) {
|
|
17317
17318
|
return (r = a2 == null ? void 0 : a2.publishParams) != null && r.allowed && (e = a2.publishParams.allowed.includes("video"), t = a2.publishParams.allowed.includes("audio"), i = a2.publishParams.allowed.includes("screen")), { video: e, audio: t, screen: i };
|
17318
17319
|
}
|
17319
17320
|
var U = (a2) => a2.room;
|
17320
|
-
var
|
17321
|
-
var yn = createSelector(
|
17321
|
+
var Ea = (a2) => a2.errors;
|
17322
|
+
var yn = createSelector(Ea, (a2) => a2.length === 0 ? null : a2.at(-1));
|
17322
17323
|
var kn = createSelector(U, (a2) => a2.id);
|
17323
17324
|
var G = (a2) => a2.peers;
|
17324
17325
|
var Bt = (a2) => a2.messages.byID;
|
17325
17326
|
var jr = (a2) => a2.messages.allIDs;
|
17326
|
-
var
|
17327
|
+
var w = (a2) => a2.tracks;
|
17327
17328
|
var Xi = (a2) => a2.appData;
|
17328
17329
|
var Aa = (a2) => a2.speakers;
|
17329
17330
|
var ye = createSelector([U], (a2) => a2 && a2.isConnected);
|
17330
17331
|
var An = createSelector([ye, U], (a2, e) => a2 ? e.peerCount !== void 0 ? e.peerCount || 1 : e.peers.length : Math.max(e.peerCount !== void 0 ? e.peerCount : e.peers.length - 1, 0));
|
17331
17332
|
var ba = (a2) => a2.hideLocalPeer;
|
17332
17333
|
var ae = createSelector([U, G, ba], (a2, e, t) => t ? a2.peers.filter((i) => a2.localPeer !== i).map((i) => e[i]) : a2.peers.map((i) => e[i]));
|
17333
|
-
var Ra = createSelector(
|
17334
|
+
var Ra = createSelector(w, (a2) => Object.values(a2));
|
17334
17335
|
var Q = createSelector(U, G, (a2, e) => e[a2.localPeer]);
|
17335
17336
|
var ue = createSelector(U, (a2) => a2.localPeer);
|
17336
17337
|
var bn = createSelector(Q, (a2) => a2 == null ? void 0 : a2.name);
|
@@ -17356,11 +17357,11 @@ var In = createSelector(G, Aa, (a2, e) => {
|
|
17356
17357
|
}
|
17357
17358
|
return null;
|
17358
17359
|
});
|
17359
|
-
var er = createSelector(Q,
|
17360
|
+
var er = createSelector(Q, w, (a2, e) => {
|
17360
17361
|
let { video: t, audio: i } = He(e, a2);
|
17361
17362
|
return !!(t || i);
|
17362
17363
|
});
|
17363
|
-
var Ia = createSelector(G,
|
17364
|
+
var Ia = createSelector(G, w, (a2, e) => {
|
17364
17365
|
let t;
|
17365
17366
|
for (let i in a2) {
|
17366
17367
|
let r = a2[i], { video: s, audio: o } = He(e, r);
|
@@ -17371,14 +17372,14 @@ var Ia = createSelector(G, D, (a2, e) => {
|
|
17371
17372
|
return t;
|
17372
17373
|
});
|
17373
17374
|
var Ln = createSelector(Ia, (a2) => !!a2);
|
17374
|
-
var
|
17375
|
+
var wn = createSelector(G, w, (a2, e) => {
|
17375
17376
|
for (let t in a2) {
|
17376
17377
|
let i = a2[t], { audio: r, video: s } = He(e, i);
|
17377
17378
|
if (!s && r)
|
17378
17379
|
return i;
|
17379
17380
|
}
|
17380
17381
|
});
|
17381
|
-
var
|
17382
|
+
var Dn = createSelector(G, w, (a2, e) => {
|
17382
17383
|
let t = [], i = [];
|
17383
17384
|
for (let r in a2) {
|
17384
17385
|
let s = a2[r], { video: o, audio: n } = He(e, s);
|
@@ -17386,14 +17387,14 @@ var wn = createSelector(G, D, (a2, e) => {
|
|
17386
17387
|
}
|
17387
17388
|
return t.concat(i);
|
17388
17389
|
});
|
17389
|
-
var _n = createSelector(G,
|
17390
|
+
var _n = createSelector(G, w, (a2, e) => {
|
17390
17391
|
for (let t in e) {
|
17391
17392
|
let i = e[t];
|
17392
17393
|
if (tt(i) && et(i) && i.peerId)
|
17393
17394
|
return a2[i.peerId];
|
17394
17395
|
}
|
17395
17396
|
});
|
17396
|
-
var Nn = createSelector(G,
|
17397
|
+
var Nn = createSelector(G, w, (a2, e) => {
|
17397
17398
|
for (let t in e) {
|
17398
17399
|
let i = e[t];
|
17399
17400
|
if (Vt(i) && i.peerId)
|
@@ -17440,8 +17441,8 @@ var Qn = createSelector(U, (a2) => !!a2.isEffectsEnabled);
|
|
17440
17441
|
var zn = createSelector(U, (a2) => a2.effectsKey);
|
17441
17442
|
var es = (a2) => a2.polls;
|
17442
17443
|
var ec = createSelector(ae, (a2) => a2.filter((e) => e.isHandRaised));
|
17443
|
-
var
|
17444
|
-
var tc = createSelector(
|
17444
|
+
var wa = (a2) => a2.whiteboards;
|
17445
|
+
var tc = createSelector(wa, (a2) => Object.values(a2)[0]);
|
17445
17446
|
var is = (a2 = "audio") => (e) => e.playlist[a2].list;
|
17446
17447
|
var tr = (a2 = "audio") => (e) => e.playlist[a2].selection;
|
17447
17448
|
var rs = (a2 = "audio") => (e) => e.playlist[a2].progress;
|
@@ -17459,7 +17460,7 @@ function A(a2) {
|
|
17459
17460
|
return (e) => (t) => a2(t, e);
|
17460
17461
|
}
|
17461
17462
|
var us = ((l) => (l[l.VERBOSE = 0] = "VERBOSE", l[l.DEBUG = 1] = "DEBUG", l[l.INFO = 2] = "INFO", l[l.WARN = 3] = "WARN", l[l.TIME = 4] = "TIME", l[l.TIMEEND = 5] = "TIMEEND", l[l.ERROR = 6] = "ERROR", l[l.NONE = 7] = "NONE", l))(us || {});
|
17462
|
-
var
|
17463
|
+
var Da = typeof window != "undefined" && typeof window.expect != "undefined";
|
17463
17464
|
var d = class {
|
17464
17465
|
static v(e, ...t) {
|
17465
17466
|
this.log(0, e, ...t);
|
@@ -17525,7 +17526,7 @@ var d = class {
|
|
17525
17526
|
}
|
17526
17527
|
}
|
17527
17528
|
};
|
17528
|
-
d.level =
|
17529
|
+
d.level = Da ? 7 : 0;
|
17529
17530
|
var pe = new import_ua_parser_js.UAParser();
|
17530
17531
|
var N = typeof window != "undefined";
|
17531
17532
|
var ps;
|
@@ -17533,8 +17534,8 @@ var Ie = typeof window == "undefined" && !((ps = pe.getBrowser().name) != null &
|
|
17533
17534
|
var Na = () => !Ie;
|
17534
17535
|
var dc = Na();
|
17535
17536
|
var hs;
|
17536
|
-
var
|
17537
|
-
var gs = ((
|
17537
|
+
var ms;
|
17538
|
+
var gs = ((ms = (hs = pe.getBrowser()) == null ? void 0 : hs.name) == null ? void 0 : ms.toLowerCase()) === "firefox";
|
17538
17539
|
function Oa() {
|
17539
17540
|
if (N && window) {
|
17540
17541
|
let a2 = window.location.hostname;
|
@@ -17765,12 +17766,12 @@ var H = class {
|
|
17765
17766
|
this.name = e, this.level = t, this.includesPII = r || false, this.properties = i || {}, this.timestamp = s || (/* @__PURE__ */ new Date()).getTime(), this.event_id = Ba(), this.device_id = fs();
|
17766
17767
|
}
|
17767
17768
|
toSignalParams() {
|
17768
|
-
return { name: this.name, info: y(
|
17769
|
+
return { name: this.name, info: y(m({}, this.properties), { timestamp: this.timestamp, domain: Ue }), timestamp: (/* @__PURE__ */ new Date()).getTime() };
|
17769
17770
|
}
|
17770
17771
|
};
|
17771
17772
|
var M = class {
|
17772
17773
|
static connect(e, t, i = /* @__PURE__ */ new Date(), r = /* @__PURE__ */ new Date(), s) {
|
17773
|
-
let o = this.eventNameFor("connect", e === void 0), n = e ? 2 : 1, l = this.getPropertiesWithError(y(
|
17774
|
+
let o = this.eventNameFor("connect", e === void 0), n = e ? 2 : 1, l = this.getPropertiesWithError(y(m({}, t), { [this.KEY_REQUESTED_AT]: i == null ? void 0 : i.getTime(), [this.KEY_RESPONDED_AT]: r == null ? void 0 : r.getTime(), endpoint: s }), e);
|
17774
17775
|
return new H({ name: o, level: n, properties: l });
|
17775
17776
|
}
|
17776
17777
|
static disconnect(e, t) {
|
@@ -17784,7 +17785,7 @@ var M = class {
|
|
17784
17785
|
}
|
17785
17786
|
static join(i) {
|
17786
17787
|
var r = i, { error: e } = r, t = Qi(r, ["error"]);
|
17787
|
-
let s = this.eventNameFor("join", e === void 0), o = e ? 2 : 1, n = this.getPropertiesWithError(y(
|
17788
|
+
let s = this.eventNameFor("join", e === void 0), o = e ? 2 : 1, n = this.getPropertiesWithError(y(m({}, t), { is_preview_called: !!t.is_preview_called }), e);
|
17788
17789
|
return new H({ name: s, level: o, properties: n });
|
17789
17790
|
}
|
17790
17791
|
static publish({ devices: e, settings: t, error: i }) {
|
@@ -17827,7 +17828,7 @@ var M = class {
|
|
17827
17828
|
let i = "video.degradation.stats", r = 1, s = { degradedAt: e.degradedAt, trackId: e.trackId };
|
17828
17829
|
if (!t && e.degradedAt instanceof Date) {
|
17829
17830
|
let o = /* @__PURE__ */ new Date(), n = o.valueOf() - e.degradedAt.valueOf();
|
17830
|
-
s = y(
|
17831
|
+
s = y(m({}, s), { duration: n, restoredAt: o });
|
17831
17832
|
}
|
17832
17833
|
return new H({ name: i, level: r, properties: s });
|
17833
17834
|
}
|
@@ -17849,7 +17850,7 @@ var M = class {
|
|
17849
17850
|
}
|
17850
17851
|
static getPropertiesWithError(e, t) {
|
17851
17852
|
let i = this.getErrorProperties(t);
|
17852
|
-
return e =
|
17853
|
+
return e = m(m({}, i), e), e;
|
17853
17854
|
}
|
17854
17855
|
static getErrorProperties(e) {
|
17855
17856
|
return e ? e instanceof T ? e.toAnalyticsProperties() : { error_name: e.name, error_message: e.message, error_description: e.cause } : {};
|
@@ -17961,8 +17962,8 @@ var hr = class {
|
|
17961
17962
|
}
|
17962
17963
|
};
|
17963
17964
|
var Ls = new hr();
|
17964
|
-
var
|
17965
|
-
var
|
17965
|
+
var mr = ((t) => (t.TRANSFORM = "TRANSFORM", t.ANALYZE = "ANALYZE", t))(mr || {});
|
17966
|
+
var Sr = ((t) => (t["2D"] = "2d", t.WEBGL = "webgl", t.WEBGL2 = "webgl2", t))(Sr || {});
|
17966
17967
|
var _s = "https://event.100ms.live/v2/client/report";
|
17967
17968
|
var Ns = "https://event-nonprod.100ms.live/v2/client/report";
|
17968
17969
|
var qe = class {
|
@@ -18036,31 +18037,31 @@ var k = class {
|
|
18036
18037
|
};
|
18037
18038
|
k.level = 0;
|
18038
18039
|
var Ar = (a2, e) => e;
|
18039
|
-
var
|
18040
|
+
var mt = (a2, e) => e;
|
18040
18041
|
var Gs = (a2, e) => e;
|
18041
18042
|
var ao = (a2, e) => e;
|
18042
18043
|
var oo = (a2, e) => e;
|
18043
18044
|
var j = createSelector([G, Ar], (a2, e) => e ? a2[e] : null);
|
18044
|
-
var br = createSelector([
|
18045
|
-
var no = createSelector([
|
18045
|
+
var br = createSelector([w, mt], (a2, e) => e ? a2[e] : null);
|
18046
|
+
var no = createSelector([w, mt], (a2, e) => {
|
18046
18047
|
if (!e)
|
18047
18048
|
return null;
|
18048
18049
|
let t = a2[e];
|
18049
18050
|
return (t == null ? void 0 : t.type) === "video" ? t : null;
|
18050
18051
|
});
|
18051
|
-
var co = createSelector([
|
18052
|
+
var co = createSelector([w, mt], (a2, e) => {
|
18052
18053
|
if (!e)
|
18053
18054
|
return null;
|
18054
18055
|
let t = a2[e];
|
18055
18056
|
return (t == null ? void 0 : t.type) === "audio" ? t : null;
|
18056
18057
|
});
|
18057
|
-
var lo = createSelector([
|
18058
|
+
var lo = createSelector([w, mt], (a2, e) => {
|
18058
18059
|
if (!e)
|
18059
18060
|
return null;
|
18060
18061
|
let t = a2[e];
|
18061
18062
|
return (t == null ? void 0 : t.type) === "audio" && (t == null ? void 0 : t.source) === "screen" ? t : null;
|
18062
18063
|
});
|
18063
|
-
var uo = createSelector([
|
18064
|
+
var uo = createSelector([w, mt], (a2, e) => {
|
18064
18065
|
if (!e)
|
18065
18066
|
return null;
|
18066
18067
|
let t = a2[e];
|
@@ -18089,7 +18090,7 @@ var ho = A((a2, e) => {
|
|
18089
18090
|
if (t && t.videoTrack && t.videoTrack !== "")
|
18090
18091
|
return a2.tracks[t.videoTrack];
|
18091
18092
|
});
|
18092
|
-
var
|
18093
|
+
var mo = A((a2, e) => {
|
18093
18094
|
let t = j(a2, e);
|
18094
18095
|
if (t && t.audioTrack && t.audioTrack !== "")
|
18095
18096
|
return a2.tracks[t.audioTrack];
|
@@ -18099,51 +18100,51 @@ var Zh = A((a2, e) => {
|
|
18099
18100
|
return (t == null ? void 0 : t.auxiliaryTracks.map((i) => a2.tracks[i])) || [];
|
18100
18101
|
});
|
18101
18102
|
var Ws = (a2, e) => e ? a2.speakers[e] : null;
|
18102
|
-
var
|
18103
|
-
var
|
18104
|
-
let t =
|
18103
|
+
var em = A(createSelector(Ws, (a2) => (a2 == null ? void 0 : a2.audioLevel) || 0));
|
18104
|
+
var So = (a2, e) => {
|
18105
|
+
let t = mo(e)(a2);
|
18105
18106
|
return Ws(a2, t == null ? void 0 : t.id);
|
18106
18107
|
};
|
18107
|
-
var
|
18108
|
-
var
|
18108
|
+
var tm = A(createSelector(So, (a2) => (a2 == null ? void 0 : a2.audioLevel) || 0));
|
18109
|
+
var im = A((a2, e) => {
|
18109
18110
|
if (e)
|
18110
18111
|
return a2.connectionQualities[e];
|
18111
18112
|
});
|
18112
|
-
var
|
18113
|
+
var rm = A((a2, e) => {
|
18113
18114
|
let t = j(a2, e);
|
18114
18115
|
if (t) {
|
18115
18116
|
let i = t == null ? void 0 : t.auxiliaryTracks.find((r) => Ze(a2.tracks[r]));
|
18116
18117
|
return i ? a2.tracks[i] : void 0;
|
18117
18118
|
}
|
18118
18119
|
});
|
18119
|
-
var
|
18120
|
+
var sm = A(createSelector(w, j, (a2, e) => {
|
18120
18121
|
let t = e == null ? void 0 : e.auxiliaryTracks.find((i) => {
|
18121
18122
|
let r = a2[i];
|
18122
18123
|
return tt(r) && et(r);
|
18123
18124
|
});
|
18124
18125
|
return t ? a2[t] : void 0;
|
18125
18126
|
}));
|
18126
|
-
var
|
18127
|
+
var am = A(createSelector(w, j, (a2, e) => {
|
18127
18128
|
let t = e == null ? void 0 : e.auxiliaryTracks.find((i) => {
|
18128
18129
|
let r = a2[i];
|
18129
18130
|
return tt(r) && Ze(r);
|
18130
18131
|
});
|
18131
18132
|
return t ? a2[t] : void 0;
|
18132
18133
|
}));
|
18133
|
-
var
|
18134
|
+
var om = A(createSelector(w, j, (a2, e) => {
|
18134
18135
|
let t = e == null ? void 0 : e.auxiliaryTracks.find((i) => {
|
18135
18136
|
let r = a2[i];
|
18136
18137
|
return Vt(r) && Ze(r);
|
18137
18138
|
});
|
18138
18139
|
return t ? a2[t] : void 0;
|
18139
18140
|
}));
|
18140
|
-
var Ks = A(createSelector(
|
18141
|
+
var Ks = A(createSelector(w, j, (a2, e) => He(a2, e)));
|
18141
18142
|
var qs = (a2) => createSelector(Ks(a2), (e) => e.audio);
|
18142
|
-
var
|
18143
|
+
var cm = A((a2, e) => {
|
18143
18144
|
let t = j(a2, e);
|
18144
18145
|
return Oe(a2, t == null ? void 0 : t.audioTrack);
|
18145
18146
|
});
|
18146
|
-
var
|
18147
|
+
var dm = A((a2, e) => {
|
18147
18148
|
let t = j(a2, e);
|
18148
18149
|
return Oe(a2, t == null ? void 0 : t.videoTrack);
|
18149
18150
|
});
|
@@ -18151,11 +18152,11 @@ var js = A((a2, e) => {
|
|
18151
18152
|
if (e && a2.tracks[e])
|
18152
18153
|
return a2.tracks[e].volume === 0;
|
18153
18154
|
});
|
18154
|
-
var
|
18155
|
+
var lm = A((a2, e) => {
|
18155
18156
|
let t = j(a2, e);
|
18156
18157
|
return js(t == null ? void 0 : t.audioTrack)(a2);
|
18157
18158
|
});
|
18158
|
-
var
|
18159
|
+
var um = A((a2, e) => {
|
18159
18160
|
let t = qs(e)(a2);
|
18160
18161
|
return js(t == null ? void 0 : t.id)(a2);
|
18161
18162
|
});
|
@@ -18169,15 +18170,15 @@ var Js = A((a2, e) => {
|
|
18169
18170
|
return t.volume;
|
18170
18171
|
}
|
18171
18172
|
});
|
18172
|
-
var
|
18173
|
+
var pm = A((a2, e) => {
|
18173
18174
|
let t = j(a2, e);
|
18174
18175
|
return Js(t == null ? void 0 : t.audioTrack)(a2);
|
18175
18176
|
});
|
18176
|
-
var
|
18177
|
+
var hm = A((a2, e) => {
|
18177
18178
|
let t = qs(e)(a2);
|
18178
18179
|
return Js(t == null ? void 0 : t.id)(a2);
|
18179
18180
|
});
|
18180
|
-
var
|
18181
|
+
var mm = A((a2, e) => {
|
18181
18182
|
let t = br(a2, e);
|
18182
18183
|
if (t) {
|
18183
18184
|
if (t.type !== "video") {
|
@@ -18207,25 +18208,25 @@ var go = createSelector(rt, (a2) => a2.filter((e) => {
|
|
18207
18208
|
}));
|
18208
18209
|
var To = createSelector([zs, Gs], (a2) => a2 ? a2.filter((e) => !e.read).length : 0);
|
18209
18210
|
var fo = createSelector([Qs, Ar], (a2) => a2 ? a2.filter((e) => !e.read).length : 0);
|
18210
|
-
var
|
18211
|
-
var
|
18212
|
-
var
|
18213
|
-
var
|
18214
|
-
var
|
18211
|
+
var Sm = createSelector(go, (a2) => a2.filter((e) => !e.read).length);
|
18212
|
+
var gm = A(Qs);
|
18213
|
+
var Tm = A(zs);
|
18214
|
+
var fm = A(To);
|
18215
|
+
var vm = A(fo);
|
18215
18216
|
var Ys = A(po);
|
18216
|
-
var
|
18217
|
+
var Cm = createSelector([G, w], (a2, e) => Object.values(a2).map((i) => {
|
18217
18218
|
var r;
|
18218
18219
|
return { peer: i, isAudioEnabled: i.audioTrack ? (r = e[i.audioTrack]) == null ? void 0 : r.enabled : false };
|
18219
18220
|
}));
|
18220
18221
|
var vo = (a2) => a2.roleChangeRequests[0] || null;
|
18221
|
-
var
|
18222
|
-
var
|
18223
|
-
var
|
18224
|
-
var yo = createSelector([K,
|
18222
|
+
var Lm = createSelector([vo, G, oe], (a2, e, t) => a2 ? { requestedBy: a2.requestedBy ? e[a2.requestedBy] : void 0, role: t[a2.roleName], token: a2.token } : null);
|
18223
|
+
var wm = createSelector([Ft], (a2) => it(a2));
|
18224
|
+
var Dm = createSelector([Xr], (a2) => it(a2));
|
18225
|
+
var yo = createSelector([K, w], (a2, e) => {
|
18225
18226
|
let t = null;
|
18226
18227
|
return a2 && (t = e[a2]), (t == null ? void 0 : t.plugins) || [];
|
18227
18228
|
});
|
18228
|
-
var ko = createSelector([Z,
|
18229
|
+
var ko = createSelector([Z, w], (a2, e) => {
|
18229
18230
|
let t = null;
|
18230
18231
|
return a2 && (t = e[a2]), (t == null ? void 0 : t.plugins) || [];
|
18231
18232
|
});
|
@@ -18282,11 +18283,11 @@ var Go = (a2) => a2.localPeer.id;
|
|
18282
18283
|
var $o = (a2) => a2.localPeer.audioTrack;
|
18283
18284
|
var Wo = (a2) => a2.localPeer.videoTrack;
|
18284
18285
|
var Ko = (a2, e) => e;
|
18285
|
-
var
|
18286
|
+
var ma = (a2, e) => e;
|
18286
18287
|
var qo = (a2) => a2.remoteTrackStats;
|
18287
|
-
var
|
18288
|
+
var Sa = (a2) => a2.peerStats;
|
18288
18289
|
var xr = (a2) => a2.localTrackStats;
|
18289
|
-
var Me = createSelector([
|
18290
|
+
var Me = createSelector([Sa, Go], (a2, e) => a2[e]);
|
18290
18291
|
var jo = createSelector(Me, (a2) => {
|
18291
18292
|
var e;
|
18292
18293
|
return (e = a2 == null ? void 0 : a2.subscribe) == null ? void 0 : e.packetsLost;
|
@@ -18319,9 +18320,9 @@ var en = createSelector(Me, (a2) => {
|
|
18319
18320
|
var e;
|
18320
18321
|
return (e = a2 == null ? void 0 : a2.subscribe) == null ? void 0 : e.bytesReceived;
|
18321
18322
|
});
|
18322
|
-
var tn = createSelector([
|
18323
|
-
var rn = createSelector([qo,
|
18324
|
-
var Ur = createSelector([xr,
|
18323
|
+
var tn = createSelector([Sa, Ko], (a2, e) => e ? a2[e] : void 0);
|
18324
|
+
var rn = createSelector([qo, ma], (a2, e) => e ? a2[e] : void 0);
|
18325
|
+
var Ur = createSelector([xr, ma], (a2, e) => e ? a2[e] : void 0);
|
18325
18326
|
var sn = A(tn);
|
18326
18327
|
var an = A(rn);
|
18327
18328
|
var on = createSelector([xr, $o], (a2, e) => {
|
@@ -18582,42 +18583,6 @@ var calculateAvatarAndAttribBoxSize = (calculatedWidth, calculatedHeight) => {
|
|
18582
18583
|
return [avatarSize, attribBoxSize];
|
18583
18584
|
};
|
18584
18585
|
var isMobileUserAgent = /Mobi|Android|iPhone/i.test(navigator.userAgent);
|
18585
|
-
var getPeerResponses = (questions, peerid, userid) => {
|
18586
|
-
return questions.map(
|
18587
|
-
(question) => {
|
18588
|
-
var _a8;
|
18589
|
-
return (_a8 = question.responses) == null ? void 0 : _a8.filter(
|
18590
|
-
(response) => {
|
18591
|
-
var _a9, _b7;
|
18592
|
-
return (response && ((_a9 = response.peer) == null ? void 0 : _a9.peerid) === peerid || ((_b7 = response.peer) == null ? void 0 : _b7.userid) === userid) && !response.skipped;
|
18593
|
-
}
|
18594
|
-
);
|
18595
|
-
}
|
18596
|
-
);
|
18597
|
-
};
|
18598
|
-
var getPeerParticipationSummary = (poll, localPeerID, localCustomerUserID) => {
|
18599
|
-
let correctResponses = 0;
|
18600
|
-
let score = 0;
|
18601
|
-
const questions = poll.questions || [];
|
18602
|
-
const peerResponses = getPeerResponses(questions, localPeerID, localCustomerUserID);
|
18603
|
-
let totalResponses = peerResponses.length || 0;
|
18604
|
-
peerResponses.forEach((peerResponse) => {
|
18605
|
-
var _a8;
|
18606
|
-
if (!(peerResponse == null ? void 0 : peerResponse[0])) {
|
18607
|
-
return;
|
18608
|
-
}
|
18609
|
-
const isCorrect = checkCorrectAnswer(
|
18610
|
-
questions[peerResponse[0].questionIndex - 1].answer,
|
18611
|
-
peerResponse[0],
|
18612
|
-
questions[peerResponse[0].questionIndex - 1].type
|
18613
|
-
);
|
18614
|
-
if (isCorrect) {
|
18615
|
-
score += ((_a8 = questions[peerResponse[0].questionIndex - 1]) == null ? void 0 : _a8.weight) || 0;
|
18616
|
-
correctResponses++;
|
18617
|
-
}
|
18618
|
-
});
|
18619
|
-
return { totalResponses, correctResponses, score };
|
18620
|
-
};
|
18621
18586
|
|
18622
18587
|
// src/Prebuilt/components/Header/StreamActions.tsx
|
18623
18588
|
var LiveStatus = () => {
|
@@ -20753,21 +20718,21 @@ import {
|
|
20753
20718
|
selectRoleChangeRequest,
|
20754
20719
|
useCustomEvent as useCustomEvent3,
|
20755
20720
|
useHMSActions as useHMSActions41,
|
20756
|
-
useHMSStore as
|
20721
|
+
useHMSStore as useHMSStore63
|
20757
20722
|
} from "@100mslive/react-sdk";
|
20758
20723
|
|
20759
20724
|
// src/Prebuilt/components/Preview/PreviewJoin.tsx
|
20760
20725
|
init_define_process_env();
|
20761
|
-
import React128, { Fragment as Fragment14, useCallback as useCallback30, useEffect as useEffect31, useMemo as useMemo10, useState as
|
20726
|
+
import React128, { Fragment as Fragment14, useCallback as useCallback30, useEffect as useEffect31, useMemo as useMemo10, useState as useState53 } from "react";
|
20762
20727
|
import { useMeasure as useMeasure4, useMedia as useMedia22 } from "react-use";
|
20763
20728
|
import {
|
20764
20729
|
HMSRoomState as HMSRoomState5,
|
20765
20730
|
selectIsLocalVideoEnabled as selectIsLocalVideoEnabled6,
|
20766
|
-
selectLocalPeer as
|
20731
|
+
selectLocalPeer as selectLocalPeer7,
|
20767
20732
|
selectRoomState as selectRoomState5,
|
20768
20733
|
selectVideoTrackByID as selectVideoTrackByID5,
|
20769
20734
|
useAVToggle as useAVToggle4,
|
20770
|
-
useHMSStore as
|
20735
|
+
useHMSStore as useHMSStore62,
|
20771
20736
|
useParticipants as useParticipants2,
|
20772
20737
|
usePreviewJoin,
|
20773
20738
|
useRecordingStreaming as useRecordingStreaming10
|
@@ -20778,7 +20743,7 @@ import { MicOffIcon as MicOffIcon7, SettingsIcon as SettingsIcon5 } from "@100ms
|
|
20778
20743
|
init_define_process_env();
|
20779
20744
|
import React123, { useEffect as useEffect29 } from "react";
|
20780
20745
|
import { useMedia as useMedia20 } from "react-use";
|
20781
|
-
import { selectAppData as selectAppData5, selectVideoTrackByPeerID as selectVideoTrackByPeerID4, useHMSStore as
|
20746
|
+
import { selectAppData as selectAppData5, selectVideoTrackByPeerID as selectVideoTrackByPeerID4, useHMSStore as useHMSStore60 } from "@100mslive/react-sdk";
|
20782
20747
|
|
20783
20748
|
// src/Prebuilt/components/Polls/Polls.tsx
|
20784
20749
|
init_define_process_env();
|
@@ -20930,7 +20895,6 @@ var AddMenu = () => {
|
|
20930
20895
|
const actions = useHMSActions25();
|
20931
20896
|
const [title, setTitle] = useState32("");
|
20932
20897
|
const localPeerRoleName = useHMSStore36(selectLocalPeerRoleName);
|
20933
|
-
const [anonymous, setAnonymous] = useState32(false);
|
20934
20898
|
const [hideVoteCount, setHideVoteCount] = useState32(false);
|
20935
20899
|
const [error, setError] = useState32();
|
20936
20900
|
const [titleError, setTitleError] = useState32("");
|
@@ -20988,7 +20952,7 @@ var AddMenu = () => {
|
|
20988
20952
|
border: "1px solid $border_default"
|
20989
20953
|
}
|
20990
20954
|
}
|
20991
|
-
), /* @__PURE__ */ React81.createElement(Flex, { align: "center", css: { mt: "$10" } }, /* @__PURE__ */ React81.createElement(Switch, { onCheckedChange: (value) => setHideVoteCount(value), css: { mr: "$6" } }), /* @__PURE__ */ React81.createElement(Text, { variant: "body2", css: { c: "$on_surface_medium" } }, "Hide Vote Count")), /* @__PURE__ */ React81.createElement(
|
20955
|
+
), /* @__PURE__ */ React81.createElement(Flex, { align: "center", css: { mt: "$10" } }, /* @__PURE__ */ React81.createElement(Switch, { onCheckedChange: (value) => setHideVoteCount(value), css: { mr: "$6" } }), /* @__PURE__ */ React81.createElement(Text, { variant: "body2", css: { c: "$on_surface_medium" } }, "Hide Vote Count")), /* @__PURE__ */ React81.createElement(
|
20992
20956
|
Button,
|
20993
20957
|
{
|
20994
20958
|
variant: "primary",
|
@@ -20999,7 +20963,7 @@ var AddMenu = () => {
|
|
20999
20963
|
yield actions.interactivityCenter.createPoll({
|
21000
20964
|
id,
|
21001
20965
|
title,
|
21002
|
-
anonymous,
|
20966
|
+
anonymous: false,
|
21003
20967
|
rolesThatCanViewResponses: hideVoteCount && localPeerRoleName ? [localPeerRoleName] : void 0,
|
21004
20968
|
type: interactionType.toLowerCase()
|
21005
20969
|
// duration: showTimerDropDown ? timer : undefined,
|
@@ -21353,7 +21317,6 @@ var QuestionForm = ({
|
|
21353
21317
|
{ text: "", isCorrectAnswer: false }
|
21354
21318
|
]
|
21355
21319
|
);
|
21356
|
-
const [skippable, setSkippable] = useState33(false);
|
21357
21320
|
const isValid = isValidQuestion({
|
21358
21321
|
text,
|
21359
21322
|
type,
|
@@ -21495,7 +21458,7 @@ var QuestionForm = ({
|
|
21495
21458
|
maxWidth: "$20"
|
21496
21459
|
}
|
21497
21460
|
}
|
21498
|
-
))
|
21461
|
+
))) : null) : null, /* @__PURE__ */ React89.createElement(Flex, { justify: "end", align: "center", css: { mt: "$12", gap: "$8" } }, /* @__PURE__ */ React89.createElement(IconButton, { css: { border: "1px solid $border_bright" } }, /* @__PURE__ */ React89.createElement(TrashIcon3, { onClick: () => setOpenDelete(!open) })), /* @__PURE__ */ React89.createElement(
|
21499
21462
|
Tooltip,
|
21500
21463
|
{
|
21501
21464
|
disabled: isValid,
|
@@ -21513,7 +21476,7 @@ var QuestionForm = ({
|
|
21513
21476
|
text,
|
21514
21477
|
type,
|
21515
21478
|
options,
|
21516
|
-
skippable,
|
21479
|
+
skippable: false,
|
21517
21480
|
draftID: question.draftID,
|
21518
21481
|
weight
|
21519
21482
|
});
|
@@ -21684,12 +21647,8 @@ var QuestionCard = ({ question, onSave, index, length, removeQuestion, isQuiz, c
|
|
21684
21647
|
|
21685
21648
|
// src/Prebuilt/components/Polls/Voting/LeaderboardSummary.tsx
|
21686
21649
|
init_define_process_env();
|
21687
|
-
import
|
21688
|
-
import {
|
21689
|
-
selectPollByID as selectPollByID2,
|
21690
|
-
useHMSActions as useHMSActions27,
|
21691
|
-
useHMSStore as useHMSStore38
|
21692
|
-
} from "@100mslive/react-sdk";
|
21650
|
+
import React95, { useState as useState37 } from "react";
|
21651
|
+
import { selectPollByID as selectPollByID3, useHMSStore as useHMSStore40 } from "@100mslive/react-sdk";
|
21693
21652
|
import { ChevronLeftIcon as ChevronLeftIcon4, ChevronRightIcon as ChevronRightIcon3, CrossIcon as CrossIcon12 } from "@100mslive/react-icons";
|
21694
21653
|
|
21695
21654
|
// src/Prebuilt/components/Polls/Voting/LeaderboardEntry.tsx
|
@@ -21724,74 +21683,137 @@ var LeaderboardEntry = ({
|
|
21724
21683
|
), /* @__PURE__ */ React92.createElement(Box, null, /* @__PURE__ */ React92.createElement(Text, { variant: "sm", css: { fontWeight: "$semiBold", color: "$on_surface_high" } }, userName), /* @__PURE__ */ React92.createElement(Text, { variant: "sm", css: { mt: "$1" } }, score, " / ", maxPossibleScore, " points"))), /* @__PURE__ */ React92.createElement(Flex, { align: "center", css: { gap: "$4", color: "$on_surface_medium" } }, position === 1 ? /* @__PURE__ */ React92.createElement(TrophyFilledIcon, { height: 16, width: 16 }) : null, /* @__PURE__ */ React92.createElement(CheckCircleIcon4, { height: 16, width: 16 }), questionCount ? /* @__PURE__ */ React92.createElement(Text, { variant: "xs" }, correctResponses, " / ", questionCount) : null));
|
21725
21684
|
};
|
21726
21685
|
|
21686
|
+
// src/Prebuilt/components/Polls/Voting/PeerParticipationSummary.tsx
|
21687
|
+
init_define_process_env();
|
21688
|
+
import React94 from "react";
|
21689
|
+
import { selectLocalPeerID as selectLocalPeerID8, useHMSStore as useHMSStore39 } from "@100mslive/react-sdk";
|
21690
|
+
|
21727
21691
|
// src/Prebuilt/components/Polls/Voting/StatisticBox.tsx
|
21728
21692
|
init_define_process_env();
|
21729
21693
|
import React93 from "react";
|
21730
|
-
var StatisticBox = ({ title, value = 0 }) =>
|
21731
|
-
|
21732
|
-
|
21733
|
-
|
21734
|
-
|
21735
|
-
|
21736
|
-
|
21737
|
-
|
21694
|
+
var StatisticBox = ({ title, value = 0 }) => {
|
21695
|
+
if (!value) {
|
21696
|
+
return /* @__PURE__ */ React93.createElement(React93.Fragment, null);
|
21697
|
+
}
|
21698
|
+
return /* @__PURE__ */ React93.createElement(Box, { css: { p: "$8", background: "$surface_default", borderRadius: "$1", w: "100%" } }, /* @__PURE__ */ React93.createElement(
|
21699
|
+
Text,
|
21700
|
+
{
|
21701
|
+
variant: "tiny",
|
21702
|
+
css: { textTransform: "uppercase", color: "$on_surface_medium", fontWeight: "$semiBold", my: "$4" }
|
21703
|
+
},
|
21704
|
+
title
|
21705
|
+
), /* @__PURE__ */ React93.createElement(Text, { css: { fontWeight: "$semiBold" } }, value));
|
21706
|
+
};
|
21738
21707
|
|
21739
|
-
// src/Prebuilt/components/Polls/Voting/
|
21740
|
-
|
21741
|
-
|
21708
|
+
// src/Prebuilt/components/Polls/Voting/useQuizSummary.tsx
|
21709
|
+
init_define_process_env();
|
21710
|
+
import { useEffect as useEffect20, useState as useState36 } from "react";
|
21711
|
+
import {
|
21712
|
+
selectPollByID as selectPollByID2,
|
21713
|
+
useHMSActions as useHMSActions27,
|
21714
|
+
useHMSStore as useHMSStore38
|
21715
|
+
} from "@100mslive/react-sdk";
|
21716
|
+
var useQuizSummary = (quizID) => {
|
21742
21717
|
const hmsActions = useHMSActions27();
|
21743
|
-
const quiz = useHMSStore38(selectPollByID2(
|
21718
|
+
const quiz = useHMSStore38(selectPollByID2(quizID));
|
21744
21719
|
const [quizLeaderboard, setQuizLeaderboard] = useState36();
|
21745
|
-
const [viewAllEntries, setViewAllEntries] = useState36(false);
|
21746
21720
|
const summary = (quizLeaderboard == null ? void 0 : quizLeaderboard.summary) || {
|
21747
21721
|
totalUsers: 0,
|
21748
21722
|
votedUsers: 0,
|
21749
21723
|
avgScore: 0,
|
21750
21724
|
avgTime: 0,
|
21751
|
-
|
21725
|
+
correctUsers: 0
|
21752
21726
|
};
|
21753
|
-
const {
|
21754
|
-
const toggleSidepane = useSidepaneToggle();
|
21727
|
+
const [calculations, setCalculations] = useState36({ maxPossibleScore: 0, totalResponses: 0 });
|
21755
21728
|
useEffect20(() => {
|
21756
21729
|
const fetchLeaderboardData = () => __async(void 0, null, function* () {
|
21757
|
-
|
21730
|
+
var _a8;
|
21731
|
+
if (!quizLeaderboard && quiz && !(quiz == null ? void 0 : quiz.anonymous) && quiz.state === "stopped") {
|
21758
21732
|
const leaderboardData = yield hmsActions.interactivityCenter.fetchLeaderboard(quiz.id, 0, 50);
|
21733
|
+
const { maxPossibleScore, totalResponses } = ((_a8 = quiz == null ? void 0 : quiz.questions) == null ? void 0 : _a8.reduce((accumulator, question) => {
|
21734
|
+
var _a9;
|
21735
|
+
accumulator.maxPossibleScore += question.weight || 0;
|
21736
|
+
accumulator.totalResponses += ((_a9 = question == null ? void 0 : question.responses) == null ? void 0 : _a9.length) || 0;
|
21737
|
+
return accumulator;
|
21738
|
+
}, calculations)) || calculations;
|
21759
21739
|
setQuizLeaderboard(leaderboardData);
|
21740
|
+
setCalculations({ maxPossibleScore, totalResponses });
|
21760
21741
|
}
|
21761
21742
|
});
|
21762
21743
|
fetchLeaderboardData();
|
21763
|
-
}, [quiz, hmsActions.interactivityCenter, quizLeaderboard]);
|
21744
|
+
}, [quiz, hmsActions.interactivityCenter, quizLeaderboard, calculations]);
|
21745
|
+
return {
|
21746
|
+
quizLeaderboard,
|
21747
|
+
summary,
|
21748
|
+
maxPossibleScore: calculations.maxPossibleScore,
|
21749
|
+
totalResponses: calculations.totalResponses
|
21750
|
+
};
|
21751
|
+
};
|
21752
|
+
|
21753
|
+
// src/Prebuilt/components/Polls/Voting/PeerParticipationSummary.tsx
|
21754
|
+
var PeerParticipationSummary = ({ quiz }) => {
|
21755
|
+
const localPeerId = useHMSStore39(selectLocalPeerID8);
|
21756
|
+
const { quizLeaderboard, summary } = useQuizSummary(quiz.id);
|
21757
|
+
if (quiz.state !== "stopped") {
|
21758
|
+
return /* @__PURE__ */ React94.createElement(React94.Fragment, null);
|
21759
|
+
}
|
21760
|
+
const isLocalPeerQuizCreator = localPeerId === quiz.startedBy;
|
21761
|
+
const peerEntry = quizLeaderboard == null ? void 0 : quizLeaderboard.entries.find((entry) => {
|
21762
|
+
var _a8;
|
21763
|
+
return ((_a8 = entry.peer) == null ? void 0 : _a8.peerid) === localPeerId;
|
21764
|
+
});
|
21765
|
+
const boxes = isLocalPeerQuizCreator ? [
|
21766
|
+
{
|
21767
|
+
title: "Voted",
|
21768
|
+
value: `${summary.totalUsers ? (100 * summary.votedUsers / summary.totalUsers).toFixed(0) : 0}% (${summary.votedUsers}/${summary.totalUsers})`
|
21769
|
+
},
|
21770
|
+
{
|
21771
|
+
title: "Correct Answers",
|
21772
|
+
value: `${summary.totalUsers ? (100 * summary.correctUsers / summary.totalUsers).toFixed(0) : 0}% (${summary.correctUsers}/${summary.totalUsers})`
|
21773
|
+
},
|
21774
|
+
{ title: "Avg. Time Taken", value: summary.avgTime },
|
21775
|
+
{
|
21776
|
+
title: "Avg. Score",
|
21777
|
+
value: Number.isInteger(summary.avgScore) ? summary.avgScore : summary.avgScore.toFixed(2)
|
21778
|
+
}
|
21779
|
+
] : [
|
21780
|
+
{ title: "Your rank", value: (peerEntry == null ? void 0 : peerEntry.position) ? `${peerEntry.position}/${summary.totalUsers}` : "-" },
|
21781
|
+
{ title: "Points", value: peerEntry == null ? void 0 : peerEntry.score },
|
21782
|
+
{ title: "Time Taken", value: peerEntry == null ? void 0 : peerEntry.duration },
|
21783
|
+
{
|
21784
|
+
title: "Correct Answers",
|
21785
|
+
value: (peerEntry == null ? void 0 : peerEntry.totalResponses) ? `${peerEntry == null ? void 0 : peerEntry.correctResponses}/${peerEntry.totalResponses}` : "-"
|
21786
|
+
}
|
21787
|
+
];
|
21788
|
+
return /* @__PURE__ */ React94.createElement(Box, null, /* @__PURE__ */ React94.createElement(Text, { css: { fontWeight: "$semiBold", my: "$8" } }, "Participation Summary"), /* @__PURE__ */ React94.createElement(Box, { css: { display: "grid", gridTemplateColumns: "1fr 1fr", gap: "$4" } }, boxes.map((box) => /* @__PURE__ */ React94.createElement(StatisticBox, { key: box.title, title: box.title, value: box.value }))));
|
21789
|
+
};
|
21790
|
+
|
21791
|
+
// src/Prebuilt/components/Polls/Voting/LeaderboardSummary.tsx
|
21792
|
+
var LeaderboardSummary = ({ pollID }) => {
|
21793
|
+
var _a8, _b7;
|
21794
|
+
const quiz = useHMSStore40(selectPollByID3(pollID));
|
21795
|
+
const { quizLeaderboard, maxPossibleScore } = useQuizSummary(pollID);
|
21796
|
+
const [viewAllEntries, setViewAllEntries] = useState37(false);
|
21797
|
+
const { setPollView } = usePollViewState();
|
21798
|
+
const toggleSidepane = useSidepaneToggle();
|
21764
21799
|
if (!quiz || !quizLeaderboard)
|
21765
|
-
return /* @__PURE__ */
|
21766
|
-
const
|
21767
|
-
|
21768
|
-
var _a9;
|
21769
|
-
accumulator.maxPossibleScore += question.weight || 0;
|
21770
|
-
accumulator.totalResponses += ((_a9 = question == null ? void 0 : question.responses) == null ? void 0 : _a9.length) || 0;
|
21771
|
-
return accumulator;
|
21772
|
-
}, defaultCalculations)) || defaultCalculations;
|
21773
|
-
const questionCount = ((_b7 = quiz.questions) == null ? void 0 : _b7.length) || 0;
|
21774
|
-
return /* @__PURE__ */ React94.createElement(Flex, { direction: "column", css: { size: "100%" } }, /* @__PURE__ */ React94.createElement(Flex, { justify: "between", align: "center", css: { pb: "$6", borderBottom: "1px solid $border_bright", mb: "$8" } }, /* @__PURE__ */ React94.createElement(Flex, { align: "center", css: { gap: "$4" } }, /* @__PURE__ */ React94.createElement(
|
21800
|
+
return /* @__PURE__ */ React95.createElement(Flex, { align: "center", justify: "center", css: { size: "100%" } }, /* @__PURE__ */ React95.createElement(Loading, null));
|
21801
|
+
const questionCount = ((_a8 = quiz.questions) == null ? void 0 : _a8.length) || 0;
|
21802
|
+
return /* @__PURE__ */ React95.createElement(Flex, { direction: "column", css: { size: "100%" } }, /* @__PURE__ */ React95.createElement(Flex, { justify: "between", align: "center", css: { pb: "$6", borderBottom: "1px solid $border_bright", mb: "$8" } }, /* @__PURE__ */ React95.createElement(Flex, { align: "center", css: { gap: "$4" } }, /* @__PURE__ */ React95.createElement(
|
21775
21803
|
Flex,
|
21776
21804
|
{
|
21777
21805
|
css: { color: "$on_surface_medium", "&:hover": { color: "$on_surface_high", cursor: "pointer" } },
|
21778
21806
|
onClick: () => setPollView(POLL_VIEWS.VOTE)
|
21779
21807
|
},
|
21780
|
-
/* @__PURE__ */
|
21781
|
-
), /* @__PURE__ */
|
21808
|
+
/* @__PURE__ */ React95.createElement(ChevronLeftIcon4, null)
|
21809
|
+
), /* @__PURE__ */ React95.createElement(Text, { variant: "lg", css: { fontWeight: "$semiBold" } }, quiz.title), /* @__PURE__ */ React95.createElement(StatusIndicator, { isLive: false })), /* @__PURE__ */ React95.createElement(
|
21782
21810
|
Flex,
|
21783
21811
|
{
|
21784
21812
|
css: { color: "$on_surface_medium", "&:hover": { color: "$on_surface_high", cursor: "pointer" } },
|
21785
21813
|
onClick: toggleSidepane
|
21786
21814
|
},
|
21787
|
-
/* @__PURE__ */
|
21788
|
-
)), !viewAllEntries ? /* @__PURE__ */
|
21789
|
-
StatisticBox,
|
21790
|
-
{
|
21791
|
-
title: "Voted",
|
21792
|
-
value: `${(summary == null ? void 0 : summary.totalUsers) ? 100 * (summary == null ? void 0 : summary.votedUsers) / (summary == null ? void 0 : summary.totalUsers) : 0}%`
|
21793
|
-
}
|
21794
|
-
), /* @__PURE__ */ React94.createElement(StatisticBox, { title: "Correct Answers", value: `${summary == null ? void 0 : summary.correctAnswers}/${totalResponses}` })), /* @__PURE__ */ React94.createElement(Flex, { css: { w: "100%", gap: "$4", mt: "$4" } }, (summary == null ? void 0 : summary.avgTime) > 0 ? /* @__PURE__ */ React94.createElement(StatisticBox, { title: "Avg. Time", value: summary == null ? void 0 : summary.avgTime }) : null, /* @__PURE__ */ React94.createElement(StatisticBox, { title: "Avg. Score", value: summary == null ? void 0 : summary.avgScore })))) : null, /* @__PURE__ */ React94.createElement(Text, { variant: "sm", css: { fontWeight: "$semiBold" } }, "Leaderboard"), /* @__PURE__ */ React94.createElement(Text, { variant: "xs", css: { color: "$on_surface_medium" } }, "Based on score and time taken to cast the correct answer"), /* @__PURE__ */ React94.createElement(
|
21815
|
+
/* @__PURE__ */ React95.createElement(CrossIcon12, null)
|
21816
|
+
)), !viewAllEntries ? /* @__PURE__ */ React95.createElement(PeerParticipationSummary, { quiz }) : null, /* @__PURE__ */ React95.createElement(Text, { variant: "sm", css: { fontWeight: "$semiBold", mt: "$4" } }, "Leaderboard"), /* @__PURE__ */ React95.createElement(Text, { variant: "xs", css: { color: "$on_surface_medium" } }, "Based on score and time taken to cast the correct answer"), /* @__PURE__ */ React95.createElement(
|
21795
21817
|
Box,
|
21796
21818
|
{
|
21797
21819
|
css: {
|
@@ -21805,7 +21827,7 @@ var LeaderboardSummary = ({ pollID }) => {
|
|
21805
21827
|
borderRadius: "$1"
|
21806
21828
|
}
|
21807
21829
|
},
|
21808
|
-
(quizLeaderboard == null ? void 0 : quizLeaderboard.entries) && quizLeaderboard.entries.slice(0, viewAllEntries ? void 0 : 5).map((question) => /* @__PURE__ */
|
21830
|
+
(quizLeaderboard == null ? void 0 : quizLeaderboard.entries) && quizLeaderboard.entries.slice(0, viewAllEntries ? void 0 : 5).map((question) => /* @__PURE__ */ React95.createElement(
|
21809
21831
|
LeaderboardEntry,
|
21810
21832
|
{
|
21811
21833
|
key: question.position,
|
@@ -21817,7 +21839,7 @@ var LeaderboardSummary = ({ pollID }) => {
|
|
21817
21839
|
maxPossibleScore
|
21818
21840
|
}
|
21819
21841
|
)),
|
21820
|
-
((
|
21842
|
+
((_b7 = quizLeaderboard == null ? void 0 : quizLeaderboard.entries) == null ? void 0 : _b7.length) > 5 && !viewAllEntries ? /* @__PURE__ */ React95.createElement(
|
21821
21843
|
Flex,
|
21822
21844
|
{
|
21823
21845
|
align: "center",
|
@@ -21831,9 +21853,9 @@ var LeaderboardSummary = ({ pollID }) => {
|
|
21831
21853
|
},
|
21832
21854
|
onClick: () => setViewAllEntries(true)
|
21833
21855
|
},
|
21834
|
-
/* @__PURE__ */
|
21856
|
+
/* @__PURE__ */ React95.createElement(Text, { variant: "sm" }, "View All"),
|
21835
21857
|
" ",
|
21836
|
-
/* @__PURE__ */
|
21858
|
+
/* @__PURE__ */ React95.createElement(ChevronRightIcon3, null)
|
21837
21859
|
) : null
|
21838
21860
|
));
|
21839
21861
|
};
|
@@ -21842,11 +21864,11 @@ var LeaderboardSummary = ({ pollID }) => {
|
|
21842
21864
|
init_define_process_env();
|
21843
21865
|
import React99 from "react";
|
21844
21866
|
import {
|
21845
|
-
selectLocalPeerID as
|
21867
|
+
selectLocalPeerID as selectLocalPeerID9,
|
21846
21868
|
selectPeerNameByID,
|
21847
|
-
selectPollByID as
|
21869
|
+
selectPollByID as selectPollByID4,
|
21848
21870
|
useHMSActions as useHMSActions29,
|
21849
|
-
useHMSStore as
|
21871
|
+
useHMSStore as useHMSStore42
|
21850
21872
|
} from "@100mslive/react-sdk";
|
21851
21873
|
import { ChevronLeftIcon as ChevronLeftIcon6, CrossIcon as CrossIcon13 } from "@100mslive/react-icons";
|
21852
21874
|
|
@@ -21854,28 +21876,10 @@ import { ChevronLeftIcon as ChevronLeftIcon6, CrossIcon as CrossIcon13 } from "@
|
|
21854
21876
|
init_define_process_env();
|
21855
21877
|
import React97 from "react";
|
21856
21878
|
|
21857
|
-
// src/Prebuilt/components/Polls/Voting/PeerParticipationSummary.tsx
|
21858
|
-
init_define_process_env();
|
21859
|
-
import React95 from "react";
|
21860
|
-
import { selectLocalPeer, useHMSStore as useHMSStore39 } from "@100mslive/react-sdk";
|
21861
|
-
var PeerParticipationSummary = ({ poll }) => {
|
21862
|
-
const localPeer = useHMSStore39(selectLocalPeer);
|
21863
|
-
const { totalResponses, correctResponses, score } = getPeerParticipationSummary(
|
21864
|
-
poll,
|
21865
|
-
localPeer == null ? void 0 : localPeer.id,
|
21866
|
-
localPeer == null ? void 0 : localPeer.customerUserId
|
21867
|
-
);
|
21868
|
-
const boxes = [
|
21869
|
-
{ title: "Points", value: score },
|
21870
|
-
{ title: "Correct Answers", value: `${correctResponses}/${totalResponses}` }
|
21871
|
-
];
|
21872
|
-
return /* @__PURE__ */ React95.createElement(Box, null, /* @__PURE__ */ React95.createElement(Text, { css: { fontWeight: "$semiBold", my: "$8" } }, "Participation Summary"), /* @__PURE__ */ React95.createElement(Box, { css: { display: "grid", gridTemplateColumns: "1fr 1fr", gap: "$4" } }, boxes.map((box) => /* @__PURE__ */ React95.createElement(StatisticBox, { key: box.title, title: box.title, value: box.value }))));
|
21873
|
-
};
|
21874
|
-
|
21875
21879
|
// src/Prebuilt/components/Polls/Voting/QuestionCard.jsx
|
21876
21880
|
init_define_process_env();
|
21877
|
-
import React96, { useCallback as useCallback20, useMemo as useMemo6, useState as
|
21878
|
-
import { selectLocalPeer
|
21881
|
+
import React96, { useCallback as useCallback20, useMemo as useMemo6, useState as useState38 } from "react";
|
21882
|
+
import { selectLocalPeer, selectLocalPeerRoleName as selectLocalPeerRoleName2, useHMSActions as useHMSActions28, useHMSStore as useHMSStore41 } from "@100mslive/react-sdk";
|
21879
21883
|
import {
|
21880
21884
|
CheckCircleIcon as CheckCircleIcon5,
|
21881
21885
|
ChevronDownIcon as ChevronDownIcon5,
|
@@ -21902,7 +21906,7 @@ var QuestionCard2 = ({
|
|
21902
21906
|
rolesThatCanViewResponses
|
21903
21907
|
}) => {
|
21904
21908
|
const actions = useHMSActions28();
|
21905
|
-
const localPeer =
|
21909
|
+
const localPeer = useHMSStore41(selectLocalPeer);
|
21906
21910
|
const localPeerResponse = responses == null ? void 0 : responses.find(
|
21907
21911
|
(response) => {
|
21908
21912
|
var _a8, _b7;
|
@@ -21910,7 +21914,7 @@ var QuestionCard2 = ({
|
|
21910
21914
|
}
|
21911
21915
|
);
|
21912
21916
|
const isLocalPeerCreator = (localPeer == null ? void 0 : localPeer.id) === startedBy;
|
21913
|
-
const localPeerRoleName =
|
21917
|
+
const localPeerRoleName = useHMSStore41(selectLocalPeerRoleName2);
|
21914
21918
|
const roleCanViewResponse = !rolesThatCanViewResponses || rolesThatCanViewResponses.length === 0 || rolesThatCanViewResponses.includes(localPeerRoleName || "");
|
21915
21919
|
const showVoteCount = roleCanViewResponse && (localPeerResponse || isLocalPeerCreator && pollState === "stopped") && !isQuiz;
|
21916
21920
|
const isLive = pollState === "started";
|
@@ -21924,9 +21928,9 @@ var QuestionCard2 = ({
|
|
21924
21928
|
const movePrev = () => {
|
21925
21929
|
setCurrentIndex((curr) => Math.max(1, curr - 1));
|
21926
21930
|
};
|
21927
|
-
const [singleOptionAnswer, setSingleOptionAnswer] =
|
21928
|
-
const [multipleOptionAnswer, setMultipleOptionAnswer] =
|
21929
|
-
const [showOptions, setShowOptions] =
|
21931
|
+
const [singleOptionAnswer, setSingleOptionAnswer] = useState38();
|
21932
|
+
const [multipleOptionAnswer, setMultipleOptionAnswer] = useState38(/* @__PURE__ */ new Set());
|
21933
|
+
const [showOptions, setShowOptions] = useState38(true);
|
21930
21934
|
const respondedToQuiz = isQuiz && localPeerResponse && !localPeerResponse.skipped;
|
21931
21935
|
const isValidVote = useMemo6(() => {
|
21932
21936
|
if (type === "single-choice" /* SINGLE_CHOICE */) {
|
@@ -22079,7 +22083,7 @@ var StandardView = ({ poll }) => {
|
|
22079
22083
|
}
|
22080
22084
|
const isQuiz = poll.type === "quiz";
|
22081
22085
|
const isStopped = poll.state === "stopped";
|
22082
|
-
return /* @__PURE__ */ React97.createElement(React97.Fragment, null, isQuiz && isStopped ? /* @__PURE__ */ React97.createElement(PeerParticipationSummary, { poll }) : null, (_a8 = poll.questions) == null ? void 0 : _a8.map((question, index) => {
|
22086
|
+
return /* @__PURE__ */ React97.createElement(React97.Fragment, null, isQuiz && isStopped ? /* @__PURE__ */ React97.createElement(PeerParticipationSummary, { quiz: poll }) : null, (_a8 = poll.questions) == null ? void 0 : _a8.map((question, index) => {
|
22083
22087
|
var _a9;
|
22084
22088
|
return /* @__PURE__ */ React97.createElement(
|
22085
22089
|
QuestionCard2,
|
@@ -22109,10 +22113,10 @@ var StandardView = ({ poll }) => {
|
|
22109
22113
|
|
22110
22114
|
// src/Prebuilt/components/Polls/Voting/TimedVoting.tsx
|
22111
22115
|
init_define_process_env();
|
22112
|
-
import React98, { useState as
|
22116
|
+
import React98, { useState as useState39 } from "react";
|
22113
22117
|
var TimedView = ({ poll }) => {
|
22114
22118
|
var _a8, _b7;
|
22115
|
-
const [currentIndex, setCurrentIndex] =
|
22119
|
+
const [currentIndex, setCurrentIndex] = useState39(1);
|
22116
22120
|
const activeQuestion = (_a8 = poll.questions) == null ? void 0 : _a8.find((question) => question.index === currentIndex);
|
22117
22121
|
if (!activeQuestion) {
|
22118
22122
|
return null;
|
@@ -22143,9 +22147,9 @@ var TimedView = ({ poll }) => {
|
|
22143
22147
|
// src/Prebuilt/components/Polls/Voting/Voting.tsx
|
22144
22148
|
var Voting = ({ id, toggleVoting }) => {
|
22145
22149
|
const actions = useHMSActions29();
|
22146
|
-
const poll =
|
22147
|
-
const pollCreatorName =
|
22148
|
-
const isLocalPeerCreator =
|
22150
|
+
const poll = useHMSStore42(selectPollByID4(id));
|
22151
|
+
const pollCreatorName = useHMSStore42(selectPeerNameByID(poll == null ? void 0 : poll.createdBy));
|
22152
|
+
const isLocalPeerCreator = useHMSStore42(selectLocalPeerID9) === (poll == null ? void 0 : poll.createdBy);
|
22149
22153
|
const { setPollView } = usePollViewState();
|
22150
22154
|
if (!poll) {
|
22151
22155
|
return null;
|
@@ -22188,7 +22192,7 @@ var Voting = ({ id, toggleVoting }) => {
|
|
22188
22192
|
},
|
22189
22193
|
/* @__PURE__ */ React99.createElement(CrossIcon13, { onClick: toggleVoting })
|
22190
22194
|
)
|
22191
|
-
), /* @__PURE__ */ React99.createElement(Flex, { direction: "column", css: { p: "$8 $10", overflowY: "auto" } },
|
22195
|
+
), /* @__PURE__ */ React99.createElement(Flex, { direction: "column", css: { p: "$8 $10", overflowY: "auto" } }, poll.state === "started" ? /* @__PURE__ */ React99.createElement(Text, { css: { color: "$on_surface_medium", fontWeight: "$semiBold" } }, pollCreatorName || "Participant", " started a ", poll.type) : null, isTimed ? /* @__PURE__ */ React99.createElement(TimedView, { poll }) : /* @__PURE__ */ React99.createElement(StandardView, { poll }), poll.state === "started" && isLocalPeerCreator && /* @__PURE__ */ React99.createElement(
|
22192
22196
|
Button,
|
22193
22197
|
{
|
22194
22198
|
variant: "danger",
|
@@ -22226,42 +22230,42 @@ var Polls = () => {
|
|
22226
22230
|
|
22227
22231
|
// src/Prebuilt/components/SidePaneTabs.tsx
|
22228
22232
|
init_define_process_env();
|
22229
|
-
import React115, { useEffect as useEffect27, useState as
|
22233
|
+
import React115, { useEffect as useEffect27, useState as useState48 } from "react";
|
22230
22234
|
import { useMedia as useMedia17 } from "react-use";
|
22231
|
-
import { selectPeerCount as selectPeerCount4, useHMSStore as
|
22235
|
+
import { selectPeerCount as selectPeerCount4, useHMSStore as useHMSStore55 } from "@100mslive/react-sdk";
|
22232
22236
|
import { CrossIcon as CrossIcon17 } from "@100mslive/react-icons";
|
22233
22237
|
|
22234
22238
|
// src/Prebuilt/components/Chat/Chat.tsx
|
22235
22239
|
init_define_process_env();
|
22236
22240
|
import React112, { useCallback as useCallback28, useRef as useRef19 } from "react";
|
22237
22241
|
import { useMedia as useMedia16 } from "react-use";
|
22238
|
-
import { selectHMSMessagesCount, useHMSActions as useHMSActions37, useHMSStore as
|
22242
|
+
import { selectHMSMessagesCount, useHMSActions as useHMSActions37, useHMSStore as useHMSStore52, useHMSVanillaStore as useHMSVanillaStore10 } from "@100mslive/react-sdk";
|
22239
22243
|
import { ChevronDownIcon as ChevronDownIcon8 } from "@100mslive/react-icons";
|
22240
22244
|
|
22241
22245
|
// src/Prebuilt/components/Chat/ChatBody.tsx
|
22242
22246
|
init_define_process_env();
|
22243
|
-
import React104, { Fragment as Fragment11, useCallback as useCallback24, useEffect as useEffect22, useLayoutEffect, useMemo as useMemo7, useRef as useRef16, useState as
|
22247
|
+
import React104, { Fragment as Fragment11, useCallback as useCallback24, useEffect as useEffect22, useLayoutEffect, useMemo as useMemo7, useRef as useRef16, useState as useState42 } from "react";
|
22244
22248
|
import { useMedia as useMedia11 } from "react-use";
|
22245
22249
|
import AutoSizer from "react-virtualized-auto-sizer";
|
22246
22250
|
import { VariableSizeList } from "react-window";
|
22247
22251
|
import {
|
22248
22252
|
selectHMSMessages,
|
22249
|
-
selectLocalPeerID as
|
22253
|
+
selectLocalPeerID as selectLocalPeerID10,
|
22250
22254
|
selectLocalPeerName as selectLocalPeerName3,
|
22251
22255
|
selectLocalPeerRoleName as selectLocalPeerRoleName3,
|
22252
22256
|
selectPeerNameByID as selectPeerNameByID3,
|
22253
22257
|
selectSessionStore as selectSessionStore5,
|
22254
22258
|
selectUnreadHMSMessagesCount as selectUnreadHMSMessagesCount2,
|
22255
22259
|
useHMSActions as useHMSActions33,
|
22256
|
-
useHMSStore as
|
22260
|
+
useHMSStore as useHMSStore46,
|
22257
22261
|
useHMSVanillaStore as useHMSVanillaStore9
|
22258
22262
|
} from "@100mslive/react-sdk";
|
22259
22263
|
import { SolidPinIcon } from "@100mslive/react-icons";
|
22260
22264
|
|
22261
22265
|
// src/Prebuilt/components/Chat/ChatActions.tsx
|
22262
22266
|
init_define_process_env();
|
22263
|
-
import React102, { useCallback as useCallback23, useState as
|
22264
|
-
import { selectLocalPeerName as selectLocalPeerName2, selectPermissions as selectPermissions13, useHMSActions as useHMSActions32, useHMSStore as
|
22267
|
+
import React102, { useCallback as useCallback23, useState as useState40 } from "react";
|
22268
|
+
import { selectLocalPeerName as selectLocalPeerName2, selectPermissions as selectPermissions13, useHMSActions as useHMSActions32, useHMSStore as useHMSStore44 } from "@100mslive/react-sdk";
|
22265
22269
|
import {
|
22266
22270
|
CopyIcon as CopyIcon2,
|
22267
22271
|
CrossCircleIcon as CrossCircleIcon2,
|
@@ -22289,10 +22293,10 @@ var MwebChatOption = ({
|
|
22289
22293
|
// src/Prebuilt/components/hooks/useChatBlacklist.ts
|
22290
22294
|
init_define_process_env();
|
22291
22295
|
import { useCallback as useCallback21 } from "react";
|
22292
|
-
import { selectLocalPeer as
|
22296
|
+
import { selectLocalPeer as selectLocalPeer2, selectSessionStore as selectSessionStore2, useHMSActions as useHMSActions30, useHMSStore as useHMSStore43 } from "@100mslive/react-sdk";
|
22293
22297
|
var useChatBlacklist = (sessionStoreKey) => {
|
22294
22298
|
const hmsActions = useHMSActions30();
|
22295
|
-
const blacklistedIDs =
|
22299
|
+
const blacklistedIDs = useHMSStore43(selectSessionStore2(sessionStoreKey));
|
22296
22300
|
const blacklistItem = useCallback21(
|
22297
22301
|
(blacklistID) => __async(void 0, null, function* () {
|
22298
22302
|
yield hmsActions.sessionStore.set(sessionStoreKey, [...blacklistedIDs || [], blacklistID]).catch((err) => ToastManager.addToast({ title: err.description }));
|
@@ -22302,8 +22306,8 @@ var useChatBlacklist = (sessionStoreKey) => {
|
|
22302
22306
|
return { blacklistItem, blacklistedIDs };
|
22303
22307
|
};
|
22304
22308
|
var useIsPeerBlacklisted = ({ local = false, peerCustomerUserId = "" }) => {
|
22305
|
-
const localPeer =
|
22306
|
-
const blacklistedPeerIDs =
|
22309
|
+
const localPeer = useHMSStore43(selectLocalPeer2);
|
22310
|
+
const blacklistedPeerIDs = useHMSStore43(selectSessionStore2("chatPeerBlacklist" /* CHAT_PEER_BLACKLIST */)) || [];
|
22307
22311
|
return blacklistedPeerIDs == null ? void 0 : blacklistedPeerIDs.includes(local ? localPeer == null ? void 0 : localPeer.customerUserId : peerCustomerUserId);
|
22308
22312
|
};
|
22309
22313
|
|
@@ -22384,11 +22388,11 @@ var ChatActions = ({
|
|
22384
22388
|
const { elements } = useRoomLayoutConferencingScreen();
|
22385
22389
|
const { can_hide_message = false, can_block_user = false } = ((_a8 = elements == null ? void 0 : elements.chat) == null ? void 0 : _a8.real_time_controls) || {};
|
22386
22390
|
const { roles_whitelist = [] } = (elements == null ? void 0 : elements.chat) || {};
|
22387
|
-
const [open, setOpen] =
|
22391
|
+
const [open, setOpen] = useState40(false);
|
22388
22392
|
const actions = useHMSActions32();
|
22389
|
-
const canRemoveOthers = (_b7 =
|
22393
|
+
const canRemoveOthers = (_b7 = useHMSStore44(selectPermissions13)) == null ? void 0 : _b7.removeOthers;
|
22390
22394
|
const { blacklistItem: blacklistPeer } = useChatBlacklist("chatPeerBlacklist" /* CHAT_PEER_BLACKLIST */);
|
22391
|
-
const localPeerName =
|
22395
|
+
const localPeerName = useHMSStore44(selectLocalPeerName2);
|
22392
22396
|
const { setPinnedMessages, unpinBlacklistedMessages } = usePinnedMessages();
|
22393
22397
|
const { blacklistItem: blacklistMessage, blacklistedIDs: blacklistedMessageIDs } = useChatBlacklist(
|
22394
22398
|
"chatMessageBlacklist" /* CHAT_MESSAGE_BLACKLIST */
|
@@ -22607,11 +22611,11 @@ var EmptyChat = () => {
|
|
22607
22611
|
|
22608
22612
|
// src/Prebuilt/components/hooks/usePinnedBy.tsx
|
22609
22613
|
init_define_process_env();
|
22610
|
-
import { useEffect as useEffect21, useState as
|
22611
|
-
import { selectSessionStore as selectSessionStore4, useHMSStore as
|
22614
|
+
import { useEffect as useEffect21, useState as useState41 } from "react";
|
22615
|
+
import { selectSessionStore as selectSessionStore4, useHMSStore as useHMSStore45 } from "@100mslive/react-sdk";
|
22612
22616
|
var usePinnedBy = (messageId) => {
|
22613
|
-
const pinnedMessages =
|
22614
|
-
const [pinnedBy, setPinnedBy] =
|
22617
|
+
const pinnedMessages = useHMSStore45(selectSessionStore4("pinnedMessages" /* PINNED_MESSAGES */));
|
22618
|
+
const [pinnedBy, setPinnedBy] = useState41("");
|
22615
22619
|
useEffect21(() => {
|
22616
22620
|
let match = "";
|
22617
22621
|
pinnedMessages == null ? void 0 : pinnedMessages.forEach((pinnedMessage) => {
|
@@ -22693,8 +22697,8 @@ var MessageType = ({
|
|
22693
22697
|
hasCurrentUserSent,
|
22694
22698
|
receiver
|
22695
22699
|
}) => {
|
22696
|
-
const peerName =
|
22697
|
-
const localPeerRoleName =
|
22700
|
+
const peerName = useHMSStore46(selectPeerNameByID3(receiver));
|
22701
|
+
const localPeerRoleName = useHMSStore46(selectLocalPeerRoleName3);
|
22698
22702
|
if (receiver) {
|
22699
22703
|
return /* @__PURE__ */ React104.createElement(MessageTypeContainer, { left: hasCurrentUserSent ? `${peerName ? `to ${peerName}` : ""}` : "to You", right: "(DM)" });
|
22700
22704
|
}
|
@@ -22742,14 +22746,14 @@ var ChatMessage = React104.memo(
|
|
22742
22746
|
const isMobile = useMedia11(config.media.md);
|
22743
22747
|
const isPrivateChatEnabled = !!((_a8 = elements == null ? void 0 : elements.chat) == null ? void 0 : _a8.private_chat_enabled);
|
22744
22748
|
const isOverlay = ((_b7 = elements == null ? void 0 : elements.chat) == null ? void 0 : _b7.is_overlay) && isMobile;
|
22745
|
-
const localPeerId =
|
22749
|
+
const localPeerId = useHMSStore46(selectLocalPeerID10);
|
22746
22750
|
const [selectedRole, setRoleSelector] = useSetSubscribedChatSelector(CHAT_SELECTOR.ROLE);
|
22747
22751
|
const [selectedPeer, setPeerSelector] = useSetSubscribedChatSelector(CHAT_SELECTOR.PEER);
|
22748
22752
|
const messageType = getMessageType({
|
22749
22753
|
roles: message.recipientRoles,
|
22750
22754
|
receiver: message.recipientPeer
|
22751
22755
|
});
|
22752
|
-
const [openSheet, setOpenSheet] =
|
22756
|
+
const [openSheet, setOpenSheet] = useState42(false);
|
22753
22757
|
const showPinAction = !!((_c = elements == null ? void 0 : elements.chat) == null ? void 0 : _c.allow_pinning_messages);
|
22754
22758
|
const showReply = message.sender !== selectedPeer.id && message.sender !== localPeerId && isPrivateChatEnabled;
|
22755
22759
|
useLayoutEffect(() => {
|
@@ -22958,8 +22962,8 @@ var VirtualizedChatMessages = React104.forwardRef(({ messages, scrollToBottom },
|
|
22958
22962
|
});
|
22959
22963
|
var ChatBody = React104.forwardRef(
|
22960
22964
|
({ scrollToBottom }, listRef) => {
|
22961
|
-
const messages =
|
22962
|
-
const blacklistedMessageIDs =
|
22965
|
+
const messages = useHMSStore46(selectHMSMessages);
|
22966
|
+
const blacklistedMessageIDs = useHMSStore46(selectSessionStore5("chatMessageBlacklist" /* CHAT_MESSAGE_BLACKLIST */));
|
22963
22967
|
const filteredMessages = useMemo7(() => {
|
22964
22968
|
const blacklistedMessageIDSet = new Set(blacklistedMessageIDs || []);
|
22965
22969
|
return (messages == null ? void 0 : messages.filter((message) => message.type === "chat" && !blacklistedMessageIDSet.has(message.id))) || [];
|
@@ -22989,7 +22993,7 @@ var PinnedBy = ({
|
|
22989
22993
|
rowRef
|
22990
22994
|
}) => {
|
22991
22995
|
const pinnedBy = usePinnedBy(messageId);
|
22992
|
-
const localPeerName =
|
22996
|
+
const localPeerName = useHMSStore46(selectLocalPeerName3);
|
22993
22997
|
useLayoutEffect(() => {
|
22994
22998
|
if (rowRef == null ? void 0 : rowRef.current) {
|
22995
22999
|
if (pinnedBy) {
|
@@ -23008,29 +23012,29 @@ var PinnedBy = ({
|
|
23008
23012
|
|
23009
23013
|
// src/Prebuilt/components/Chat/ChatFooter.tsx
|
23010
23014
|
init_define_process_env();
|
23011
|
-
import React107, { useCallback as useCallback26, useEffect as useEffect24, useRef as useRef18, useState as
|
23015
|
+
import React107, { useCallback as useCallback26, useEffect as useEffect24, useRef as useRef18, useState as useState45 } from "react";
|
23012
23016
|
import { useMedia as useMedia14 } from "react-use";
|
23013
23017
|
import data2 from "@emoji-mart/data";
|
23014
23018
|
import Picker from "@emoji-mart/react";
|
23015
|
-
import { selectLocalPeer as
|
23019
|
+
import { selectLocalPeer as selectLocalPeer3, useHMSActions as useHMSActions35, useHMSStore as useHMSStore49 } from "@100mslive/react-sdk";
|
23016
23020
|
import { EmojiIcon as EmojiIcon3, PauseCircleIcon as PauseCircleIcon2, SendIcon, VerticalMenuIcon as VerticalMenuIcon7 } from "@100mslive/react-icons";
|
23017
23021
|
|
23018
23022
|
// src/Prebuilt/components/Chat/ChatSelectorContainer.tsx
|
23019
23023
|
init_define_process_env();
|
23020
|
-
import React106, { useState as
|
23024
|
+
import React106, { useState as useState44 } from "react";
|
23021
23025
|
import { useMedia as useMedia13 } from "react-use";
|
23022
23026
|
import { ChevronDownIcon as ChevronDownIcon6, ChevronUpIcon as ChevronUpIcon5, CrossIcon as CrossIcon15, GroupIcon, PersonIcon as PersonIcon2 } from "@100mslive/react-icons";
|
23023
23027
|
|
23024
23028
|
// src/Prebuilt/components/Chat/ChatSelector.tsx
|
23025
23029
|
init_define_process_env();
|
23026
|
-
import React105, { useMemo as useMemo8, useState as
|
23030
|
+
import React105, { useMemo as useMemo8, useState as useState43 } from "react";
|
23027
23031
|
import { useMedia as useMedia12 } from "react-use";
|
23028
23032
|
import {
|
23029
23033
|
selectMessagesUnreadCountByPeerID,
|
23030
23034
|
selectMessagesUnreadCountByRole,
|
23031
23035
|
selectRemotePeers as selectRemotePeers2,
|
23032
23036
|
selectUnreadHMSMessagesCount as selectUnreadHMSMessagesCount3,
|
23033
|
-
useHMSStore as
|
23037
|
+
useHMSStore as useHMSStore47
|
23034
23038
|
} from "@100mslive/react-sdk";
|
23035
23039
|
import { CheckIcon as CheckIcon6, PeopleIcon as PeopleIcon3 } from "@100mslive/react-icons";
|
23036
23040
|
var ChatDotIcon = () => {
|
@@ -23080,7 +23084,7 @@ var SelectorHeader = React105.memo(
|
|
23080
23084
|
}
|
23081
23085
|
);
|
23082
23086
|
var Everyone = React105.memo(({ active }) => {
|
23083
|
-
const unreadCount =
|
23087
|
+
const unreadCount = useHMSStore47(selectUnreadHMSMessagesCount3);
|
23084
23088
|
const [, setPeerSelector] = useSetSubscribedChatSelector(CHAT_SELECTOR.PEER);
|
23085
23089
|
const [, setRoleSelector] = useSetSubscribedChatSelector(CHAT_SELECTOR.ROLE);
|
23086
23090
|
return /* @__PURE__ */ React105.createElement(
|
@@ -23098,7 +23102,7 @@ var Everyone = React105.memo(({ active }) => {
|
|
23098
23102
|
);
|
23099
23103
|
});
|
23100
23104
|
var RoleItem = React105.memo(({ role, active }) => {
|
23101
|
-
const unreadCount =
|
23105
|
+
const unreadCount = useHMSStore47(selectMessagesUnreadCountByRole(role));
|
23102
23106
|
const [, setPeerSelector] = useSetSubscribedChatSelector(CHAT_SELECTOR.PEER);
|
23103
23107
|
const [, setRoleSelector] = useSetSubscribedChatSelector(CHAT_SELECTOR.ROLE);
|
23104
23108
|
return /* @__PURE__ */ React105.createElement(
|
@@ -23115,7 +23119,7 @@ var RoleItem = React105.memo(({ role, active }) => {
|
|
23115
23119
|
);
|
23116
23120
|
});
|
23117
23121
|
var PeerItem = ({ peerId, name, active }) => {
|
23118
|
-
const unreadCount =
|
23122
|
+
const unreadCount = useHMSStore47(selectMessagesUnreadCountByPeerID(peerId));
|
23119
23123
|
const [, setPeerSelector] = useSetSubscribedChatSelector(CHAT_SELECTOR.PEER);
|
23120
23124
|
const [, setRoleSelector] = useSetSubscribedChatSelector(CHAT_SELECTOR.ROLE);
|
23121
23125
|
return /* @__PURE__ */ React105.createElement(
|
@@ -23174,8 +23178,8 @@ var VirtualizedSelectItemList = ({
|
|
23174
23178
|
var ChatSelector = ({ role, peerId }) => {
|
23175
23179
|
var _a8, _b7;
|
23176
23180
|
const { elements } = useRoomLayoutConferencingScreen();
|
23177
|
-
const peers =
|
23178
|
-
const [search, setSearch] =
|
23181
|
+
const peers = useHMSStore47(selectRemotePeers2);
|
23182
|
+
const [search, setSearch] = useState43("");
|
23179
23183
|
const isPrivateChatEnabled = !!((_a8 = elements == null ? void 0 : elements.chat) == null ? void 0 : _a8.private_chat_enabled);
|
23180
23184
|
const isPublicChatEnabled = !!((_b7 = elements == null ? void 0 : elements.chat) == null ? void 0 : _b7.public_chat_enabled);
|
23181
23185
|
return /* @__PURE__ */ React105.createElement(React105.Fragment, null, peers.length > 0 && isPrivateChatEnabled && /* @__PURE__ */ React105.createElement(Box, { css: { px: "$4" } }, /* @__PURE__ */ React105.createElement(ParticipantSearch, { onSearch: setSearch, placeholder: "Search for participants" })), /* @__PURE__ */ React105.createElement(
|
@@ -23193,7 +23197,7 @@ var ChatSelector = ({ role, peerId }) => {
|
|
23193
23197
|
// src/Prebuilt/components/Chat/ChatSelectorContainer.tsx
|
23194
23198
|
var ChatSelectorContainer = () => {
|
23195
23199
|
var _a8, _b7;
|
23196
|
-
const [open, setOpen] =
|
23200
|
+
const [open, setOpen] = useState44(false);
|
23197
23201
|
const isMobile = useMedia13(config.media.md);
|
23198
23202
|
const { elements } = useRoomLayoutConferencingScreen();
|
23199
23203
|
const isPrivateChatEnabled = !!((_a8 = elements == null ? void 0 : elements.chat) == null ? void 0 : _a8.private_chat_enabled);
|
@@ -23312,10 +23316,10 @@ var ChatSelectorContainer = () => {
|
|
23312
23316
|
// src/Prebuilt/components/AppData/useChatState.js
|
23313
23317
|
init_define_process_env();
|
23314
23318
|
import { useCallback as useCallback25 } from "react";
|
23315
|
-
import { selectAppData as selectAppData4, useHMSActions as useHMSActions34, useHMSStore as
|
23319
|
+
import { selectAppData as selectAppData4, useHMSActions as useHMSActions34, useHMSStore as useHMSStore48 } from "@100mslive/react-sdk";
|
23316
23320
|
var useChatDraftMessage = () => {
|
23317
23321
|
const hmsActions = useHMSActions34();
|
23318
|
-
let chatDraftMessage =
|
23322
|
+
let chatDraftMessage = useHMSStore48(selectAppData4(APP_DATA.chatDraft));
|
23319
23323
|
if (chatDraftMessage === void 0 || chatDraftMessage === null) {
|
23320
23324
|
chatDraftMessage = "";
|
23321
23325
|
}
|
@@ -23381,7 +23385,7 @@ var TextArea2 = styled("textarea", {
|
|
23381
23385
|
}
|
23382
23386
|
});
|
23383
23387
|
function EmojiPicker({ onSelect }) {
|
23384
|
-
const [showEmoji, setShowEmoji] =
|
23388
|
+
const [showEmoji, setShowEmoji] = useState45(false);
|
23385
23389
|
const ref = useEmojiPickerStyles(showEmoji);
|
23386
23390
|
return /* @__PURE__ */ React107.createElement(Popover2.Root, { open: showEmoji, onOpenChange: setShowEmoji }, /* @__PURE__ */ React107.createElement(Popover2.Trigger, { asChild: true, css: { appearance: "none" } }, /* @__PURE__ */ React107.createElement(IconButton, { as: "div" }, /* @__PURE__ */ React107.createElement(EmojiIcon3, null))), /* @__PURE__ */ React107.createElement(Popover2.Portal, null, /* @__PURE__ */ React107.createElement(
|
23387
23391
|
Popover2.Content,
|
@@ -23414,7 +23418,7 @@ var ChatFooter = ({ onSend, children }) => {
|
|
23414
23418
|
const isMobile = useMedia14(config.media.md);
|
23415
23419
|
const { elements } = useRoomLayoutConferencingScreen();
|
23416
23420
|
const message_placeholder = ((_a8 = elements == null ? void 0 : elements.chat) == null ? void 0 : _a8.message_placeholder) || "Send a message";
|
23417
|
-
const localPeer =
|
23421
|
+
const localPeer = useHMSStore49(selectLocalPeer3);
|
23418
23422
|
const isOverlayChat = (_b7 = elements == null ? void 0 : elements.chat) == null ? void 0 : _b7.is_overlay;
|
23419
23423
|
const canDisableChat = !!((_d = (_c = elements == null ? void 0 : elements.chat) == null ? void 0 : _c.real_time_controls) == null ? void 0 : _d.can_disable_chat);
|
23420
23424
|
const selectedPeer = useSubscribeChatSelector(CHAT_SELECTOR.PEER);
|
@@ -23581,14 +23585,14 @@ var ChatFooter = ({ onSend, children }) => {
|
|
23581
23585
|
// src/Prebuilt/components/Chat/ChatStates.tsx
|
23582
23586
|
init_define_process_env();
|
23583
23587
|
import React108, { useCallback as useCallback27 } from "react";
|
23584
|
-
import { selectLocalPeer as
|
23588
|
+
import { selectLocalPeer as selectLocalPeer4, selectSessionStore as selectSessionStore6, useHMSActions as useHMSActions36, useHMSStore as useHMSStore50 } from "@100mslive/react-sdk";
|
23585
23589
|
var ChatPaused = () => {
|
23586
23590
|
var _a8, _b7;
|
23587
23591
|
const hmsActions = useHMSActions36();
|
23588
23592
|
const { elements } = useRoomLayoutConferencingScreen();
|
23589
23593
|
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);
|
23590
|
-
const { enabled: isChatEnabled = true, updatedBy: chatStateUpdatedBy = "" } =
|
23591
|
-
const localPeer =
|
23594
|
+
const { enabled: isChatEnabled = true, updatedBy: chatStateUpdatedBy = "" } = useHMSStore50(selectSessionStore6("chatState" /* CHAT_STATE */)) || {};
|
23595
|
+
const localPeer = useHMSStore50(selectLocalPeer4);
|
23592
23596
|
const unPauseChat = useCallback27(
|
23593
23597
|
() => __async(void 0, null, function* () {
|
23594
23598
|
return yield hmsActions.sessionStore.set("chatState" /* CHAT_STATE */, {
|
@@ -23636,10 +23640,10 @@ var ChatBlocked = () => {
|
|
23636
23640
|
|
23637
23641
|
// src/Prebuilt/components/Chat/PinnedMessage.tsx
|
23638
23642
|
init_define_process_env();
|
23639
|
-
import React111, { useEffect as useEffect25, useState as
|
23643
|
+
import React111, { useEffect as useEffect25, useState as useState46 } from "react";
|
23640
23644
|
import { useSwipeable } from "react-swipeable";
|
23641
23645
|
import { useMedia as useMedia15 } from "react-use";
|
23642
|
-
import { selectSessionStore as selectSessionStore7, useHMSStore as
|
23646
|
+
import { selectSessionStore as selectSessionStore7, useHMSStore as useHMSStore51 } from "@100mslive/react-sdk";
|
23643
23647
|
import { PinIcon as PinIcon2, UnpinIcon } from "@100mslive/react-icons";
|
23644
23648
|
|
23645
23649
|
// src/Prebuilt/components/Chat/ArrowNavigation.tsx
|
@@ -23696,13 +23700,13 @@ var StickIndicator = ({ total, index }) => {
|
|
23696
23700
|
var PINNED_MESSAGE_LENGTH = 75;
|
23697
23701
|
var PinnedMessage = () => {
|
23698
23702
|
var _a8, _b7, _c;
|
23699
|
-
const pinnedMessages =
|
23700
|
-
const [pinnedMessageIndex, setPinnedMessageIndex] =
|
23703
|
+
const pinnedMessages = useHMSStore51(selectSessionStore7("pinnedMessages" /* PINNED_MESSAGES */));
|
23704
|
+
const [pinnedMessageIndex, setPinnedMessageIndex] = useState46(0);
|
23701
23705
|
const { removePinnedMessage } = usePinnedMessages();
|
23702
23706
|
const isMobile = useMedia15(config.media.md);
|
23703
23707
|
const { elements } = useRoomLayoutConferencingScreen();
|
23704
23708
|
const canUnpinMessage = !!((_a8 = elements == null ? void 0 : elements.chat) == null ? void 0 : _a8.allow_pinning_messages);
|
23705
|
-
const [hideOverflow, setHideOverflow] =
|
23709
|
+
const [hideOverflow, setHideOverflow] = useState46(true);
|
23706
23710
|
const currentPinnedMessage = ((_b7 = pinnedMessages == null ? void 0 : pinnedMessages[pinnedMessageIndex]) == null ? void 0 : _b7.text) || "";
|
23707
23711
|
const canOverflow = currentPinnedMessage.length > PINNED_MESSAGE_LENGTH;
|
23708
23712
|
const showPreviousPinnedMessage = () => {
|
@@ -23816,7 +23820,7 @@ var Chat = () => {
|
|
23816
23820
|
const listRef = useRef19(null);
|
23817
23821
|
const hmsActions = useHMSActions37();
|
23818
23822
|
const vanillaStore = useHMSVanillaStore10();
|
23819
|
-
const { enabled: isChatEnabled = true } =
|
23823
|
+
const { enabled: isChatEnabled = true } = useHMSStore52(qh("chatState" /* CHAT_STATE */)) || {};
|
23820
23824
|
const isMobile = useMedia16(config.media.md);
|
23821
23825
|
const scrollToBottom = useCallback28(
|
23822
23826
|
(unreadCount = 0) => {
|
@@ -23854,7 +23858,7 @@ var NewMessageIndicator = ({
|
|
23854
23858
|
scrollToBottom,
|
23855
23859
|
listRef
|
23856
23860
|
}) => {
|
23857
|
-
const unreadCount =
|
23861
|
+
const unreadCount = useHMSStore52(Un);
|
23858
23862
|
if (!unreadCount || !listRef.current) {
|
23859
23863
|
return null;
|
23860
23864
|
}
|
@@ -23900,11 +23904,11 @@ var NewMessageIndicator = ({
|
|
23900
23904
|
|
23901
23905
|
// src/Prebuilt/components/Footer/PaginatedParticipants.tsx
|
23902
23906
|
init_define_process_env();
|
23903
|
-
import React113, { useEffect as useEffect26, useState as
|
23907
|
+
import React113, { useEffect as useEffect26, useState as useState47 } from "react";
|
23904
23908
|
import { useInView } from "react-intersection-observer";
|
23905
23909
|
import { useMeasure as useMeasure2 } from "react-use";
|
23906
23910
|
import { VariableSizeList as VariableSizeList2 } from "react-window";
|
23907
|
-
import { selectIsConnectedToRoom as selectIsConnectedToRoom8, useHMSStore as
|
23911
|
+
import { selectIsConnectedToRoom as selectIsConnectedToRoom8, useHMSStore as useHMSStore53, usePaginatedParticipants as usePaginatedParticipants2 } from "@100mslive/react-sdk";
|
23908
23912
|
import { ChevronLeftIcon as ChevronLeftIcon7, CrossIcon as CrossIcon16 } from "@100mslive/react-icons";
|
23909
23913
|
var LoadMoreParticipants = ({
|
23910
23914
|
hasNext,
|
@@ -23912,7 +23916,7 @@ var LoadMoreParticipants = ({
|
|
23912
23916
|
style
|
23913
23917
|
}) => {
|
23914
23918
|
const { ref, inView } = useInView();
|
23915
|
-
const [inProgress, setInProgress] =
|
23919
|
+
const [inProgress, setInProgress] = useState47(false);
|
23916
23920
|
useEffect26(() => {
|
23917
23921
|
if (hasNext && inView && !inProgress) {
|
23918
23922
|
setInProgress(true);
|
@@ -23943,12 +23947,12 @@ var VirtualizedParticipantItem2 = React113.memo(
|
|
23943
23947
|
);
|
23944
23948
|
var PaginatedParticipants = ({ roleName, onBack }) => {
|
23945
23949
|
const { peers, total, hasNext, loadPeers, loadMorePeers } = usePaginatedParticipants2({ role: roleName, limit: 20 });
|
23946
|
-
const [search, setSearch] =
|
23950
|
+
const [search, setSearch] = useState47("");
|
23947
23951
|
const filteredPeers = peers.filter((p) => {
|
23948
23952
|
var _a8;
|
23949
23953
|
return (_a8 = p.name) == null ? void 0 : _a8.toLowerCase().includes(search == null ? void 0 : search.toLowerCase());
|
23950
23954
|
});
|
23951
|
-
const isConnected =
|
23955
|
+
const isConnected = useHMSStore53(selectIsConnectedToRoom8);
|
23952
23956
|
const [ref, { width }] = useMeasure2();
|
23953
23957
|
const height = ROW_HEIGHT * (filteredPeers.length + 1);
|
23954
23958
|
const resetSidePane = useSidepaneReset();
|
@@ -23982,15 +23986,15 @@ var PaginatedParticipants = ({ roleName, onBack }) => {
|
|
23982
23986
|
// src/Prebuilt/components/ChatSettings.tsx
|
23983
23987
|
init_define_process_env();
|
23984
23988
|
import React114 from "react";
|
23985
|
-
import { selectLocalPeer as
|
23989
|
+
import { selectLocalPeer as selectLocalPeer5, selectSessionStore as selectSessionStore8, useHMSActions as useHMSActions38, useHMSStore as useHMSStore54 } from "@100mslive/react-sdk";
|
23986
23990
|
import { PauseCircleIcon as PauseCircleIcon3, SettingsIcon as SettingsIcon4 } from "@100mslive/react-icons";
|
23987
23991
|
var ChatSettings = () => {
|
23988
23992
|
var _a8, _b7;
|
23989
23993
|
const hmsActions = useHMSActions38();
|
23990
|
-
const localPeer =
|
23994
|
+
const localPeer = useHMSStore54(selectLocalPeer5);
|
23991
23995
|
const { elements } = useRoomLayoutConferencingScreen();
|
23992
23996
|
const canPauseChat = !!((_b7 = (_a8 = elements == null ? void 0 : elements.chat) == null ? void 0 : _a8.real_time_controls) == null ? void 0 : _b7.can_disable_chat);
|
23993
|
-
const { enabled: isChatEnabled = true } =
|
23997
|
+
const { enabled: isChatEnabled = true } = useHMSStore54(selectSessionStore8("chatState" /* CHAT_STATE */)) || {};
|
23994
23998
|
const showPause = canPauseChat && isChatEnabled;
|
23995
23999
|
if (!showPause) {
|
23996
24000
|
return null;
|
@@ -24053,9 +24057,9 @@ var SidePaneTabs = React115.memo(({ active = SIDE_PANE_OPTIONS.CHAT, hideControl
|
|
24053
24057
|
const toggleChat = useSidepaneToggle(SIDE_PANE_OPTIONS.CHAT);
|
24054
24058
|
const toggleParticipants = useSidepaneToggle(SIDE_PANE_OPTIONS.PARTICIPANTS);
|
24055
24059
|
const resetSidePane = useSidepaneReset();
|
24056
|
-
const [activeTab, setActiveTab] =
|
24057
|
-
const [activeRole, setActiveRole] =
|
24058
|
-
const peerCount =
|
24060
|
+
const [activeTab, setActiveTab] = useState48(active);
|
24061
|
+
const [activeRole, setActiveRole] = useState48("");
|
24062
|
+
const peerCount = useHMSStore55(selectPeerCount4);
|
24059
24063
|
const { elements } = useRoomLayoutConferencingScreen();
|
24060
24064
|
const chat_title = ((_a8 = elements == null ? void 0 : elements.chat) == null ? void 0 : _a8.chat_title) || "Chat";
|
24061
24065
|
const showChat = !!(elements == null ? void 0 : elements.chat);
|
@@ -24175,19 +24179,19 @@ var SidePaneTabs = React115.memo(({ active = SIDE_PANE_OPTIONS.CHAT, hideControl
|
|
24175
24179
|
|
24176
24180
|
// src/Prebuilt/components/VideoTile.jsx
|
24177
24181
|
init_define_process_env();
|
24178
|
-
import React119, { Fragment as Fragment13, useCallback as useCallback29, useMemo as useMemo9, useState as
|
24182
|
+
import React119, { Fragment as Fragment13, useCallback as useCallback29, useMemo as useMemo9, useState as useState50 } from "react";
|
24179
24183
|
import { useMeasure as useMeasure3 } from "react-use";
|
24180
24184
|
import {
|
24181
24185
|
selectAudioTrackByPeerID as selectAudioTrackByPeerID2,
|
24182
24186
|
selectHasPeerHandRaised as selectHasPeerHandRaised3,
|
24183
24187
|
selectIsPeerAudioEnabled as selectIsPeerAudioEnabled2,
|
24184
|
-
selectLocalPeerID as
|
24188
|
+
selectLocalPeerID as selectLocalPeerID12,
|
24185
24189
|
selectPeerMetadata as selectPeerMetadata4,
|
24186
24190
|
selectPeerNameByID as selectPeerNameByID4,
|
24187
24191
|
selectSessionStore as selectSessionStore10,
|
24188
24192
|
selectVideoTrackByID as selectVideoTrackByID3,
|
24189
24193
|
selectVideoTrackByPeerID as selectVideoTrackByPeerID3,
|
24190
|
-
useHMSStore as
|
24194
|
+
useHMSStore as useHMSStore58
|
24191
24195
|
} from "@100mslive/react-sdk";
|
24192
24196
|
import { BrbTileIcon, HandIcon as HandIcon5, MicOffIcon as MicOffIcon6 } from "@100mslive/react-icons";
|
24193
24197
|
|
@@ -24234,15 +24238,15 @@ var TileConnection_default = TileConnection;
|
|
24234
24238
|
|
24235
24239
|
// src/Prebuilt/components/TileMenu/TileMenu.jsx
|
24236
24240
|
init_define_process_env();
|
24237
|
-
import React118, { useState as
|
24241
|
+
import React118, { useState as useState49 } from "react";
|
24238
24242
|
import { useMedia as useMedia19 } from "react-use";
|
24239
24243
|
import {
|
24240
|
-
selectLocalPeerID as
|
24244
|
+
selectLocalPeerID as selectLocalPeerID11,
|
24241
24245
|
selectPeerByID as selectPeerByID2,
|
24242
24246
|
selectPermissions as selectPermissions15,
|
24243
24247
|
selectTrackByID as selectTrackByID3,
|
24244
24248
|
selectVideoTrackByPeerID as selectVideoTrackByPeerID2,
|
24245
|
-
useHMSStore as
|
24249
|
+
useHMSStore as useHMSStore57,
|
24246
24250
|
useRemoteAVToggle as useRemoteAVToggle2
|
24247
24251
|
} from "@100mslive/react-sdk";
|
24248
24252
|
import { CrossIcon as CrossIcon18, VerticalMenuIcon as VerticalMenuIcon8 } from "@100mslive/react-icons";
|
@@ -24257,7 +24261,7 @@ import {
|
|
24257
24261
|
selectTrackByID as selectTrackByID2,
|
24258
24262
|
useCustomEvent as useCustomEvent2,
|
24259
24263
|
useHMSActions as useHMSActions39,
|
24260
|
-
useHMSStore as
|
24264
|
+
useHMSStore as useHMSStore56,
|
24261
24265
|
useRemoteAVToggle
|
24262
24266
|
} from "@100mslive/react-sdk";
|
24263
24267
|
import {
|
@@ -24294,7 +24298,7 @@ var SpotlightActions = ({
|
|
24294
24298
|
}
|
24295
24299
|
}) => {
|
24296
24300
|
const hmsActions = useHMSActions39();
|
24297
|
-
const spotlightPeerId =
|
24301
|
+
const spotlightPeerId = useHMSStore56(selectSessionStore9("spotlight" /* SPOTLIGHT */));
|
24298
24302
|
const isTileSpotlighted = spotlightPeerId === peerId;
|
24299
24303
|
const dragClassName = getDragClassName();
|
24300
24304
|
const setSpotlightPeerId = (peerIdToSpotlight) => hmsActions.sessionStore.set("spotlight" /* SPOTLIGHT */, peerIdToSpotlight).catch((err) => ToastManager.addToast({ title: err.description }));
|
@@ -24342,7 +24346,7 @@ var MinimiseInset = () => {
|
|
24342
24346
|
};
|
24343
24347
|
var SimulcastLayers = ({ trackId }) => {
|
24344
24348
|
var _a8;
|
24345
|
-
const track =
|
24349
|
+
const track = useHMSStore56(selectTrackByID2(trackId));
|
24346
24350
|
const actions = useHMSActions39();
|
24347
24351
|
const bg = useDropdownSelection();
|
24348
24352
|
if (!((_a8 = track == null ? void 0 : track.layerDefinitions) == null ? void 0 : _a8.length) || track.degraded || !track.enabled) {
|
@@ -24428,7 +24432,7 @@ var TileMenuContent = ({
|
|
24428
24432
|
var _a8;
|
24429
24433
|
const actions = useHMSActions39();
|
24430
24434
|
const dragClassName = getDragClassName();
|
24431
|
-
const removeOthers = (_a8 =
|
24435
|
+
const removeOthers = (_a8 = useHMSStore56(selectPermissions14)) == null ? void 0 : _a8.removeOthers;
|
24432
24436
|
const { userName } = useHMSPrebuiltContext();
|
24433
24437
|
const { isAudioEnabled, isVideoEnabled, setVolume, toggleAudio, toggleVideo, volume } = useRemoteAVToggle(
|
24434
24438
|
audioTrackID,
|
@@ -24514,20 +24518,20 @@ var TileMenu = ({
|
|
24514
24518
|
enableSpotlightingPeer = true
|
24515
24519
|
}) => {
|
24516
24520
|
var _a8, _b7;
|
24517
|
-
const [open, setOpen] =
|
24521
|
+
const [open, setOpen] = useState49(false);
|
24518
24522
|
const { theme: theme2 } = useTheme();
|
24519
|
-
const localPeerID =
|
24523
|
+
const localPeerID = useHMSStore57(selectLocalPeerID11);
|
24520
24524
|
const isLocal = localPeerID === peerID;
|
24521
|
-
const { removeOthers } =
|
24525
|
+
const { removeOthers } = useHMSStore57(selectPermissions15);
|
24522
24526
|
const { setVolume, toggleAudio, toggleVideo } = useRemoteAVToggle2(audioTrackID, videoTrackID);
|
24523
24527
|
const showSpotlight = enableSpotlightingPeer;
|
24524
|
-
const isPrimaryVideoTrack = ((_a8 =
|
24528
|
+
const isPrimaryVideoTrack = ((_a8 = useHMSStore57(selectVideoTrackByPeerID2(peerID))) == null ? void 0 : _a8.id) === videoTrackID;
|
24525
24529
|
const showPinAction = audioTrackID || videoTrackID && isPrimaryVideoTrack;
|
24526
|
-
const track =
|
24530
|
+
const track = useHMSStore57(selectTrackByID3(videoTrackID));
|
24527
24531
|
const hideSimulcastLayers = !((_b7 = track == null ? void 0 : track.layerDefinitions) == null ? void 0 : _b7.length) || track.degraded || !track.enabled;
|
24528
24532
|
const isMobile = useMedia19(config.media.md);
|
24529
|
-
const peer =
|
24530
|
-
const [showNameChangeModal, setShowNameChangeModal] =
|
24533
|
+
const peer = useHMSStore57(selectPeerByID2(peerID));
|
24534
|
+
const [showNameChangeModal, setShowNameChangeModal] = useState49(false);
|
24531
24535
|
useDropdownList({ open, name: "TileMenu" });
|
24532
24536
|
const dragClassName = getDragClassName();
|
24533
24537
|
if (!(removeOthers || toggleAudio || toggleVideo || setVolume || showPinAction) && hideSimulcastLayers) {
|
@@ -24619,16 +24623,16 @@ var Tile = ({
|
|
24619
24623
|
hideMetadataOnTile = false
|
24620
24624
|
}) => {
|
24621
24625
|
const trackSelector = trackId ? selectVideoTrackByID3(trackId) : selectVideoTrackByPeerID3(peerId);
|
24622
|
-
const track =
|
24623
|
-
const peerName =
|
24624
|
-
const audioTrack =
|
24625
|
-
const localPeerID =
|
24626
|
+
const track = useHMSStore58(trackSelector);
|
24627
|
+
const peerName = useHMSStore58(selectPeerNameByID4(peerId));
|
24628
|
+
const audioTrack = useHMSStore58(selectAudioTrackByPeerID2(peerId));
|
24629
|
+
const localPeerID = useHMSStore58(selectLocalPeerID12);
|
24626
24630
|
const isAudioOnly = useUISettings(UI_SETTINGS.isAudioOnly);
|
24627
24631
|
const mirrorLocalVideo = useUISettings(UI_SETTINGS.mirrorLocalVideo);
|
24628
24632
|
const showStatsOnTiles = useUISettings(UI_SETTINGS.showStatsOnTiles);
|
24629
|
-
const isAudioMuted = !
|
24633
|
+
const isAudioMuted = !useHMSStore58(selectIsPeerAudioEnabled2(peerId));
|
24630
24634
|
const isVideoMuted = !(track == null ? void 0 : track.enabled);
|
24631
|
-
const [isMouseHovered, setIsMouseHovered] =
|
24635
|
+
const [isMouseHovered, setIsMouseHovered] = useState50(false);
|
24632
24636
|
const isVideoDegraded = track == null ? void 0 : track.degraded;
|
24633
24637
|
const isLocal = localPeerID === peerId;
|
24634
24638
|
const [pinnedTrackId] = useSetAppDataByKey(APP_DATA.pinnedTrackId);
|
@@ -24637,7 +24641,7 @@ var Tile = ({
|
|
24637
24641
|
videoTrackID: track == null ? void 0 : track.id,
|
24638
24642
|
audioTrackID: audioTrack == null ? void 0 : audioTrack.id
|
24639
24643
|
});
|
24640
|
-
const spotlighted =
|
24644
|
+
const spotlighted = useHMSStore58(selectSessionStore10("spotlight" /* SPOTLIGHT */)) === peerId;
|
24641
24645
|
const label = getVideoTileLabel({
|
24642
24646
|
peerName,
|
24643
24647
|
track,
|
@@ -24713,9 +24717,9 @@ var Tile = ({
|
|
24713
24717
|
);
|
24714
24718
|
};
|
24715
24719
|
var PeerMetadata = ({ peerId, size }) => {
|
24716
|
-
const metaData =
|
24720
|
+
const metaData = useHMSStore58(selectPeerMetadata4(peerId));
|
24717
24721
|
const isBRB = (metaData == null ? void 0 : metaData.isBRBOn) || false;
|
24718
|
-
const isHandRaised =
|
24722
|
+
const isHandRaised = useHMSStore58(selectHasPeerHandRaised3(peerId));
|
24719
24723
|
return /* @__PURE__ */ React119.createElement(Fragment13, null, isHandRaised ? /* @__PURE__ */ React119.createElement(StyledVideoTile.AttributeBox, { size, "data-testid": "raiseHand_icon_onTile" }, /* @__PURE__ */ React119.createElement(HandIcon5, { width: 24, height: 24 })) : null, isBRB ? /* @__PURE__ */ React119.createElement(StyledVideoTile.AttributeBox, { size, "data-testid": "brb_icon_onTile" }, /* @__PURE__ */ React119.createElement(BrbTileIcon, { width: 22, height: 22 })) : null);
|
24720
24724
|
};
|
24721
24725
|
var VideoTile = React119.memo(Tile);
|
@@ -24723,18 +24727,18 @@ var VideoTile_default = VideoTile;
|
|
24723
24727
|
|
24724
24728
|
// src/Prebuilt/components/VirtualBackground/VBPicker.tsx
|
24725
24729
|
init_define_process_env();
|
24726
|
-
import React122, { useEffect as useEffect28, useState as
|
24730
|
+
import React122, { useEffect as useEffect28, useState as useState51 } from "react";
|
24727
24731
|
import { HMSVirtualBackgroundTypes as HMSVirtualBackgroundTypes3 } from "@100mslive/hms-virtual-background";
|
24728
24732
|
import {
|
24729
24733
|
HMSRoomState as HMSRoomState4,
|
24730
24734
|
selectIsLargeRoom as selectIsLargeRoom3,
|
24731
24735
|
selectIsLocalVideoEnabled as selectIsLocalVideoEnabled5,
|
24732
24736
|
selectIsLocalVideoPluginPresent,
|
24733
|
-
selectLocalPeer as
|
24737
|
+
selectLocalPeer as selectLocalPeer6,
|
24734
24738
|
selectRoomState as selectRoomState4,
|
24735
24739
|
selectVideoTrackByID as selectVideoTrackByID4,
|
24736
24740
|
useHMSActions as useHMSActions40,
|
24737
|
-
useHMSStore as
|
24741
|
+
useHMSStore as useHMSStore59
|
24738
24742
|
} from "@100mslive/react-sdk";
|
24739
24743
|
import { BlurPersonHighIcon, CloseIcon, CrossCircleIcon as CrossCircleIcon3 } from "@100mslive/react-icons";
|
24740
24744
|
|
@@ -24903,18 +24907,18 @@ var VBPicker = ({ backgroundMedia = [] }) => {
|
|
24903
24907
|
var _a8, _b7;
|
24904
24908
|
const toggleVB = useSidepaneToggle(SIDE_PANE_OPTIONS.VB);
|
24905
24909
|
const hmsActions = useHMSActions40();
|
24906
|
-
const localPeer =
|
24907
|
-
const role =
|
24908
|
-
const isVideoOn =
|
24910
|
+
const localPeer = useHMSStore59(selectLocalPeer6);
|
24911
|
+
const role = useHMSStore59(Ft);
|
24912
|
+
const isVideoOn = useHMSStore59(selectIsLocalVideoEnabled5);
|
24909
24913
|
const mirrorLocalVideo = useUISettings(UI_SETTINGS.mirrorLocalVideo);
|
24910
24914
|
const trackSelector = selectVideoTrackByID4(localPeer == null ? void 0 : localPeer.videoTrack);
|
24911
|
-
const track =
|
24912
|
-
const roomState =
|
24913
|
-
const isLargeRoom =
|
24914
|
-
const isEffectsEnabled =
|
24915
|
-
const effectsKey =
|
24916
|
-
const isPluginAdded =
|
24917
|
-
const [activeBackground, setActiveBackground] =
|
24915
|
+
const track = useHMSStore59(trackSelector);
|
24916
|
+
const roomState = useHMSStore59(selectRoomState4);
|
24917
|
+
const isLargeRoom = useHMSStore59(selectIsLargeRoom3);
|
24918
|
+
const isEffectsEnabled = useHMSStore59(Qn);
|
24919
|
+
const effectsKey = useHMSStore59(zn);
|
24920
|
+
const isPluginAdded = useHMSStore59(selectIsLocalVideoPluginPresent(((_a8 = VBHandler) == null ? void 0 : _a8.getName()) || ""));
|
24921
|
+
const [activeBackground, setActiveBackground] = useState51(
|
24918
24922
|
((_b7 = VBHandler) == null ? void 0 : _b7.getBackground()) || HMSVirtualBackgroundTypes3.NONE
|
24919
24923
|
);
|
24920
24924
|
const mediaList = backgroundMedia.length ? backgroundMedia.map((media) => media.url || "") : defaultMedia2;
|
@@ -25025,9 +25029,9 @@ var SidePane = ({
|
|
25025
25029
|
}) => {
|
25026
25030
|
var _a8, _b7, _c, _d, _e, _f;
|
25027
25031
|
const isMobile = useMedia20(config.media.md);
|
25028
|
-
const sidepane =
|
25029
|
-
const activeScreensharePeerId =
|
25030
|
-
const trackId = (_a8 =
|
25032
|
+
const sidepane = useHMSStore60(selectAppData5(APP_DATA.sidePane));
|
25033
|
+
const activeScreensharePeerId = useHMSStore60(selectAppData5(APP_DATA.activeScreensharePeerId));
|
25034
|
+
const trackId = (_a8 = useHMSStore60(selectVideoTrackByPeerID4(activeScreensharePeerId))) == null ? void 0 : _a8.id;
|
25031
25035
|
const { elements } = useRoomLayoutConferencingScreen();
|
25032
25036
|
const { elements: preview_elements } = useRoomLayoutPreviewScreen();
|
25033
25037
|
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) || [];
|
@@ -25157,11 +25161,11 @@ var FullPageProgress_default = FullPageProgress;
|
|
25157
25161
|
|
25158
25162
|
// src/Prebuilt/components/Header/HeaderComponents.jsx
|
25159
25163
|
init_define_process_env();
|
25160
|
-
import React126, { useEffect as useEffect30, useState as
|
25161
|
-
import { selectDominantSpeaker, useHMSStore as
|
25164
|
+
import React126, { useEffect as useEffect30, useState as useState52 } from "react";
|
25165
|
+
import { selectDominantSpeaker, useHMSStore as useHMSStore61 } from "@100mslive/react-sdk";
|
25162
25166
|
import { VolumeOneIcon } from "@100mslive/react-icons";
|
25163
25167
|
var SpeakerTag = () => {
|
25164
|
-
const dominantSpeaker =
|
25168
|
+
const dominantSpeaker = useHMSStore61(selectDominantSpeaker);
|
25165
25169
|
return dominantSpeaker && dominantSpeaker.name && /* @__PURE__ */ React126.createElement(
|
25166
25170
|
Flex,
|
25167
25171
|
{
|
@@ -25186,7 +25190,7 @@ var Logo = () => {
|
|
25186
25190
|
var _a8;
|
25187
25191
|
const roomLayout = useRoomLayout();
|
25188
25192
|
const logo = (_a8 = roomLayout == null ? void 0 : roomLayout.logo) == null ? void 0 : _a8.url;
|
25189
|
-
const [hideImage, setHideImage] =
|
25193
|
+
const [hideImage, setHideImage] = useState52(false);
|
25190
25194
|
useEffect30(() => {
|
25191
25195
|
if (hideImage) {
|
25192
25196
|
setHideImage(false);
|
@@ -25284,8 +25288,8 @@ var getParticipantChipContent = (peerCount = 0) => {
|
|
25284
25288
|
return `${formattedNum} other${parseInt(formattedNum) === 1 ? "" : "s"} in the session`;
|
25285
25289
|
};
|
25286
25290
|
var useLocalTileAspectRatio = () => {
|
25287
|
-
const localPeer =
|
25288
|
-
const videoTrack =
|
25291
|
+
const localPeer = useHMSStore62(selectLocalPeer7);
|
25292
|
+
const videoTrack = useHMSStore62(selectVideoTrackByID5(localPeer == null ? void 0 : localPeer.videoTrack));
|
25289
25293
|
const isMobile = useMedia22(config.media.md);
|
25290
25294
|
let aspectRatio = 0;
|
25291
25295
|
if ((videoTrack == null ? void 0 : videoTrack.width) && (videoTrack == null ? void 0 : videoTrack.height)) {
|
@@ -25306,9 +25310,9 @@ var PreviewJoin = ({
|
|
25306
25310
|
);
|
25307
25311
|
const { isStreamingOn } = useRecordingStreaming10();
|
25308
25312
|
const authToken = useAuthToken();
|
25309
|
-
const [name, setName] =
|
25313
|
+
const [name, setName] = useState53(initialName || previewPreference.name);
|
25310
25314
|
const { toggleAudio, toggleVideo } = useAVToggle4();
|
25311
|
-
const [previewError, setPreviewError] =
|
25315
|
+
const [previewError, setPreviewError] = useState53(false);
|
25312
25316
|
const { endpoints } = useHMSPrebuiltContext();
|
25313
25317
|
const { peerCount } = useParticipants2();
|
25314
25318
|
const { enableJoin, preview, join } = usePreviewJoin({
|
@@ -25328,7 +25332,7 @@ var PreviewJoin = ({
|
|
25328
25332
|
},
|
25329
25333
|
asRole
|
25330
25334
|
});
|
25331
|
-
const roomState =
|
25335
|
+
const roomState = useHMSStore62(selectRoomState5);
|
25332
25336
|
const savePreferenceAndJoin = useCallback30(() => {
|
25333
25337
|
setPreviewPreference({
|
25334
25338
|
name
|
@@ -25407,12 +25411,12 @@ var Container4 = styled("div", __spreadProps(__spreadValues({
|
|
25407
25411
|
px: "$10"
|
25408
25412
|
}));
|
25409
25413
|
var PreviewTile = ({ name, error }) => {
|
25410
|
-
const localPeer =
|
25414
|
+
const localPeer = useHMSStore62(selectLocalPeer7);
|
25411
25415
|
const { isLocalAudioEnabled, toggleAudio } = useAVToggle4();
|
25412
|
-
const isVideoOn =
|
25416
|
+
const isVideoOn = useHMSStore62(selectIsLocalVideoEnabled6);
|
25413
25417
|
const mirrorLocalVideo = useUISettings(UI_SETTINGS.mirrorLocalVideo);
|
25414
25418
|
const trackSelector = selectVideoTrackByID5(localPeer == null ? void 0 : localPeer.videoTrack);
|
25415
|
-
const track =
|
25419
|
+
const track = useHMSStore62(trackSelector);
|
25416
25420
|
const showMuteIcon = !isLocalAudioEnabled || !toggleAudio;
|
25417
25421
|
const aspectRatio = useLocalTileAspectRatio();
|
25418
25422
|
const [ref, { width: calculatedWidth, height: calculatedHeight }] = useMeasure4();
|
@@ -25465,7 +25469,7 @@ var PreviewControls = ({ hideSettings, vbEnabled }) => {
|
|
25465
25469
|
);
|
25466
25470
|
};
|
25467
25471
|
var PreviewSettings = React128.memo(() => {
|
25468
|
-
const [open, setOpen] =
|
25472
|
+
const [open, setOpen] = useState53(false);
|
25469
25473
|
return /* @__PURE__ */ React128.createElement(Fragment14, null, /* @__PURE__ */ React128.createElement(IconButton_default, { "data-testid": "preview_setting_btn", css: { flexShrink: 0 }, onClick: () => setOpen((value) => !value) }, /* @__PURE__ */ React128.createElement(SettingsIcon5, null)), open && /* @__PURE__ */ React128.createElement(SettingsModal_default, { open, onOpenChange: setOpen }));
|
25470
25474
|
});
|
25471
25475
|
var PreviewJoin_default = PreviewJoin;
|
@@ -25494,9 +25498,9 @@ var RequestActions = ({ onAction, actionText }) => /* @__PURE__ */ React129.crea
|
|
25494
25498
|
var RoleChangeRequestModal = () => {
|
25495
25499
|
const hmsActions = useHMSActions41();
|
25496
25500
|
const { updateMetaData } = useMyMetadata();
|
25497
|
-
const currentRole =
|
25498
|
-
const roleChangeRequest =
|
25499
|
-
const name =
|
25501
|
+
const currentRole = useHMSStore63(selectLocalPeerRoleName4);
|
25502
|
+
const roleChangeRequest = useHMSStore63(selectRoleChangeRequest);
|
25503
|
+
const name = useHMSStore63(selectLocalPeerName4);
|
25500
25504
|
const { sendEvent } = useCustomEvent3({ type: ROLE_CHANGE_DECLINED });
|
25501
25505
|
const { elements = {} } = useRoomLayoutPreviewScreen();
|
25502
25506
|
const { virtual_background } = elements || {};
|
@@ -25570,33 +25574,33 @@ import {
|
|
25570
25574
|
selectPeerScreenSharing as selectPeerScreenSharing3,
|
25571
25575
|
selectWhiteboard as selectWhiteboard2,
|
25572
25576
|
useHMSActions as useHMSActions43,
|
25573
|
-
useHMSStore as
|
25577
|
+
useHMSStore as useHMSStore72
|
25574
25578
|
} from "@100mslive/react-sdk";
|
25575
25579
|
|
25576
25580
|
// src/Prebuilt/components/VideoLayouts/GridLayout.tsx
|
25577
25581
|
init_define_process_env();
|
25578
|
-
import React142, { useEffect as useEffect40, useMemo as useMemo15, useState as
|
25582
|
+
import React142, { useEffect as useEffect40, useMemo as useMemo15, useState as useState60 } from "react";
|
25579
25583
|
import {
|
25580
|
-
selectLocalPeerID as
|
25584
|
+
selectLocalPeerID as selectLocalPeerID14,
|
25581
25585
|
selectLocalPeerRoleName as selectLocalPeerRoleName5,
|
25582
25586
|
selectPeers as selectPeers3,
|
25583
25587
|
selectPeerScreenSharing,
|
25584
|
-
useHMSStore as
|
25588
|
+
useHMSStore as useHMSStore69,
|
25585
25589
|
useHMSVanillaStore as useHMSVanillaStore12
|
25586
25590
|
} from "@100mslive/react-sdk";
|
25587
25591
|
|
25588
25592
|
// src/Prebuilt/components/VideoLayouts/EqualProminence.tsx
|
25589
25593
|
init_define_process_env();
|
25590
|
-
import React135, { useEffect as useEffect36, useMemo as useMemo12, useState as
|
25594
|
+
import React135, { useEffect as useEffect36, useMemo as useMemo12, useState as useState55 } from "react";
|
25591
25595
|
import { useMedia as useMedia26 } from "react-use";
|
25592
|
-
import { selectLocalPeer as
|
25596
|
+
import { selectLocalPeer as selectLocalPeer9, useHMSStore as useHMSStore65 } from "@100mslive/react-sdk";
|
25593
25597
|
|
25594
25598
|
// src/Prebuilt/components/InsetTile.tsx
|
25595
25599
|
init_define_process_env();
|
25596
25600
|
import React132, { useEffect as useEffect33, useRef as useRef20 } from "react";
|
25597
25601
|
import Draggable from "react-draggable";
|
25598
25602
|
import { useMedia as useMedia24 } from "react-use";
|
25599
|
-
import { selectIsAllowedToPublish as selectIsAllowedToPublish2, selectLocalPeer as
|
25603
|
+
import { selectIsAllowedToPublish as selectIsAllowedToPublish2, selectLocalPeer as selectLocalPeer8, selectVideoTrackByID as selectVideoTrackByID6, useHMSStore as useHMSStore64 } from "@100mslive/react-sdk";
|
25600
25604
|
import { ExpandIcon as ExpandIcon2 } from "@100mslive/react-icons";
|
25601
25605
|
|
25602
25606
|
// src/Prebuilt/components/hooks/useVideoTileLayout.ts
|
@@ -25635,10 +25639,10 @@ var desktopAspectRatio = 1 / defaultMobileAspectRatio;
|
|
25635
25639
|
var InsetTile = () => {
|
25636
25640
|
const isMobile = useMedia24(config.media.md);
|
25637
25641
|
const isLandscape = useMedia24(config.media.ls);
|
25638
|
-
const localPeer =
|
25642
|
+
const localPeer = useHMSStore64(selectLocalPeer8);
|
25639
25643
|
const [minimised, setMinimised] = useSetAppDataByKey(APP_DATA.minimiseInset);
|
25640
|
-
const videoTrack =
|
25641
|
-
const isAllowedToPublish =
|
25644
|
+
const videoTrack = useHMSStore64(selectVideoTrackByID6(localPeer == null ? void 0 : localPeer.videoTrack));
|
25645
|
+
const isAllowedToPublish = useHMSStore64(selectIsAllowedToPublish2);
|
25642
25646
|
const videoTileProps = useVideoTileContext();
|
25643
25647
|
let aspectRatio = isMobile ? defaultMobileAspectRatio : desktopAspectRatio;
|
25644
25648
|
if ((videoTrack == null ? void 0 : videoTrack.width) && (videoTrack == null ? void 0 : videoTrack.height) && !isMobile) {
|
@@ -25792,7 +25796,7 @@ var Grid = React134.forwardRef(
|
|
25792
25796
|
|
25793
25797
|
// src/Prebuilt/components/hooks/useTileLayout.tsx
|
25794
25798
|
init_define_process_env();
|
25795
|
-
import { useEffect as useEffect35, useMemo as useMemo11, useState as
|
25799
|
+
import { useEffect as useEffect35, useMemo as useMemo11, useState as useState54 } from "react";
|
25796
25800
|
import { useMeasure as useMeasure5, useMedia as useMedia25 } from "react-use";
|
25797
25801
|
import {
|
25798
25802
|
getPeersWithTiles,
|
@@ -25830,7 +25834,7 @@ var useTileLayout = ({
|
|
25830
25834
|
const vanillaStore = useHMSVanillaStore11();
|
25831
25835
|
const [ref, { width, height }] = useMeasure5();
|
25832
25836
|
const isMobile = useMedia25(config.media.lg);
|
25833
|
-
const [pagesWithTiles, setPagesWithTiles] =
|
25837
|
+
const [pagesWithTiles, setPagesWithTiles] = useState54([]);
|
25834
25838
|
useEffect35(() => {
|
25835
25839
|
if (width === 0 || height === 0) {
|
25836
25840
|
return;
|
@@ -25875,10 +25879,10 @@ var useTileLayout = ({
|
|
25875
25879
|
tileHeight = maxRowHeight;
|
25876
25880
|
const calcWidths = aspectRatios.map((aR) => tileHeight * aR);
|
25877
25881
|
tileWidth = 0;
|
25878
|
-
for (const
|
25879
|
-
if (
|
25880
|
-
if (tileWidth <
|
25881
|
-
tileWidth =
|
25882
|
+
for (const w2 of calcWidths) {
|
25883
|
+
if (w2 < width) {
|
25884
|
+
if (tileWidth < w2) {
|
25885
|
+
tileWidth = w2;
|
25882
25886
|
}
|
25883
25887
|
}
|
25884
25888
|
}
|
@@ -25898,7 +25902,7 @@ var useTileLayout = ({
|
|
25898
25902
|
// src/Prebuilt/components/VideoLayouts/EqualProminence.tsx
|
25899
25903
|
function EqualProminence({ isInsetEnabled = false, peers, onPageChange, onPageSize, edgeToEdge }) {
|
25900
25904
|
var _a8;
|
25901
|
-
const localPeer =
|
25905
|
+
const localPeer = useHMSStore65(selectLocalPeer9);
|
25902
25906
|
const isMobile = useMedia26(config.media.md);
|
25903
25907
|
let maxTileCount = useUISettings(UI_SETTINGS.maxTileCount);
|
25904
25908
|
maxTileCount = isMobile ? Math.min(maxTileCount, 6) : maxTileCount;
|
@@ -25921,7 +25925,7 @@ function EqualProminence({ isInsetEnabled = false, peers, onPageChange, onPageSi
|
|
25921
25925
|
maxTileCount,
|
25922
25926
|
edgeToEdge
|
25923
25927
|
});
|
25924
|
-
const [page, setPage] =
|
25928
|
+
const [page, setPage] = useState55(0);
|
25925
25929
|
const pageSize = ((_a8 = pagesWithTiles[0]) == null ? void 0 : _a8.length) || 0;
|
25926
25930
|
useEffect36(() => {
|
25927
25931
|
if (pageSize > 0) {
|
@@ -25943,12 +25947,12 @@ function EqualProminence({ isInsetEnabled = false, peers, onPageChange, onPageSi
|
|
25943
25947
|
|
25944
25948
|
// src/Prebuilt/components/VideoLayouts/RoleProminence.tsx
|
25945
25949
|
init_define_process_env();
|
25946
|
-
import React138, { useEffect as useEffect38, useState as
|
25947
|
-
import { selectLocalPeer as
|
25950
|
+
import React138, { useEffect as useEffect38, useState as useState57 } from "react";
|
25951
|
+
import { selectLocalPeer as selectLocalPeer10, useHMSStore as useHMSStore66 } from "@100mslive/react-sdk";
|
25948
25952
|
|
25949
25953
|
// src/Prebuilt/components/SecondaryTiles.tsx
|
25950
25954
|
init_define_process_env();
|
25951
|
-
import React137, { useEffect as useEffect37, useState as
|
25955
|
+
import React137, { useEffect as useEffect37, useState as useState56 } from "react";
|
25952
25956
|
import { useMedia as useMedia27 } from "react-use";
|
25953
25957
|
|
25954
25958
|
// src/Prebuilt/components/VideoLayouts/ProminenceLayout.tsx
|
@@ -26021,7 +26025,7 @@ var SecondaryTiles = ({ peers, onPageChange, onPageSize, edgeToEdge }) => {
|
|
26021
26025
|
const isMobile = useMedia27(config.media.md);
|
26022
26026
|
const maxTileCount = isMobile ? 2 : 4;
|
26023
26027
|
const pagesWithTiles = usePagesWithTiles({ peers, maxTileCount });
|
26024
|
-
const [page, setPage] =
|
26028
|
+
const [page, setPage] = useState56(0);
|
26025
26029
|
const pageSize = ((_a8 = pagesWithTiles[0]) == null ? void 0 : _a8.length) || 0;
|
26026
26030
|
useEffect37(() => {
|
26027
26031
|
if (pageSize > 0) {
|
@@ -26087,7 +26091,7 @@ function RoleProminence({
|
|
26087
26091
|
}) {
|
26088
26092
|
var _a8;
|
26089
26093
|
const { prominentPeers, secondaryPeers } = useRoleProminencePeers(prominentRoles, peers, isInsetEnabled);
|
26090
|
-
const localPeer =
|
26094
|
+
const localPeer = useHMSStore66(selectLocalPeer10);
|
26091
26095
|
const maxTileCount = 4;
|
26092
26096
|
const pageList = usePagesWithTiles({
|
26093
26097
|
peers: prominentPeers,
|
@@ -26097,7 +26101,7 @@ function RoleProminence({
|
|
26097
26101
|
pageList,
|
26098
26102
|
maxTileCount
|
26099
26103
|
});
|
26100
|
-
const [page, setPage] =
|
26104
|
+
const [page, setPage] = useState57(0);
|
26101
26105
|
const pageSize = ((_a8 = pagesWithTiles[0]) == null ? void 0 : _a8.length) || 0;
|
26102
26106
|
useEffect38(() => {
|
26103
26107
|
if (pageSize > 0) {
|
@@ -26119,21 +26123,21 @@ function RoleProminence({
|
|
26119
26123
|
|
26120
26124
|
// src/Prebuilt/components/VideoLayouts/ScreenshareLayout.tsx
|
26121
26125
|
init_define_process_env();
|
26122
|
-
import React141, { useEffect as useEffect39, useMemo as useMemo14, useState as
|
26126
|
+
import React141, { useEffect as useEffect39, useMemo as useMemo14, useState as useState59 } from "react";
|
26123
26127
|
import { useMedia as useMedia28 } from "react-use";
|
26124
|
-
import { selectPeersScreenSharing, useHMSStore as
|
26128
|
+
import { selectPeersScreenSharing, useHMSStore as useHMSStore68 } from "@100mslive/react-sdk";
|
26125
26129
|
|
26126
26130
|
// src/Prebuilt/components/ScreenshareTile.jsx
|
26127
26131
|
init_define_process_env();
|
26128
|
-
import React140, { useRef as useRef21, useState as
|
26132
|
+
import React140, { useRef as useRef21, useState as useState58 } from "react";
|
26129
26133
|
import { useFullscreen as useFullscreen2 } from "react-use";
|
26130
26134
|
import screenfull2 from "screenfull";
|
26131
26135
|
import {
|
26132
|
-
selectLocalPeerID as
|
26136
|
+
selectLocalPeerID as selectLocalPeerID13,
|
26133
26137
|
selectPeerByID as selectPeerByID3,
|
26134
26138
|
selectScreenShareAudioByPeerID as selectScreenShareAudioByPeerID2,
|
26135
26139
|
selectScreenShareByPeerID,
|
26136
|
-
useHMSStore as
|
26140
|
+
useHMSStore as useHMSStore67
|
26137
26141
|
} from "@100mslive/react-sdk";
|
26138
26142
|
import { ExpandIcon as ExpandIcon3, ShrinkIcon as ShrinkIcon2 } from "@100mslive/react-icons";
|
26139
26143
|
|
@@ -26184,19 +26188,19 @@ var labelStyles = {
|
|
26184
26188
|
flexShrink: 0
|
26185
26189
|
};
|
26186
26190
|
var Tile2 = ({ peerId, width = "100%", height = "100%" }) => {
|
26187
|
-
const isLocal =
|
26188
|
-
const track =
|
26189
|
-
const peer =
|
26191
|
+
const isLocal = useHMSStore67(selectLocalPeerID13) === peerId;
|
26192
|
+
const track = useHMSStore67(selectScreenShareByPeerID(peerId));
|
26193
|
+
const peer = useHMSStore67(selectPeerByID3(peerId));
|
26190
26194
|
const isAudioOnly = useUISettings(UI_SETTINGS.isAudioOnly);
|
26191
|
-
const [isMouseHovered, setIsMouseHovered] =
|
26195
|
+
const [isMouseHovered, setIsMouseHovered] = useState58(false);
|
26192
26196
|
const showStatsOnTiles = useUISettings(UI_SETTINGS.showStatsOnTiles);
|
26193
26197
|
const fullscreenRef = useRef21(null);
|
26194
|
-
const [fullscreen, setFullscreen] =
|
26198
|
+
const [fullscreen, setFullscreen] = useState58(false);
|
26195
26199
|
const isFullscreen = useFullscreen2(fullscreenRef, fullscreen, {
|
26196
26200
|
onClose: () => setFullscreen(false)
|
26197
26201
|
});
|
26198
26202
|
const isFullScreenSupported = screenfull2.isEnabled;
|
26199
|
-
const audioTrack =
|
26203
|
+
const audioTrack = useHMSStore67(selectScreenShareAudioByPeerID2(peer == null ? void 0 : peer.id));
|
26200
26204
|
if (isLocal && !["browser", "window", "application"].includes(track == null ? void 0 : track.displaySurface)) {
|
26201
26205
|
return /* @__PURE__ */ React140.createElement(ScreenshareDisplay, null);
|
26202
26206
|
}
|
@@ -26250,9 +26254,9 @@ var ScreenshareTile_default = ScreenshareTile;
|
|
26250
26254
|
// src/Prebuilt/components/VideoLayouts/ScreenshareLayout.tsx
|
26251
26255
|
var ScreenshareLayout = ({ peers, onPageChange, onPageSize, edgeToEdge }) => {
|
26252
26256
|
var _a8;
|
26253
|
-
const peersSharing =
|
26257
|
+
const peersSharing = useHMSStore68(selectPeersScreenSharing);
|
26254
26258
|
const [, setActiveScreenSharePeer] = useSetAppDataByKey(APP_DATA.activeScreensharePeerId);
|
26255
|
-
const [page, setPage] =
|
26259
|
+
const [page, setPage] = useState59(0);
|
26256
26260
|
const activeSharePeer = peersSharing[page];
|
26257
26261
|
const isMobile = useMedia28(config.media.md);
|
26258
26262
|
const secondaryPeers = useMemo14(() => {
|
@@ -26385,11 +26389,11 @@ var GridLayout = ({
|
|
26385
26389
|
edge_to_edge = false,
|
26386
26390
|
hide_metadata_on_tile = false
|
26387
26391
|
}) => {
|
26388
|
-
const peerSharing =
|
26392
|
+
const peerSharing = useHMSStore69(selectPeerScreenSharing);
|
26389
26393
|
const pinnedTrack = usePinnedTrack();
|
26390
|
-
const peers =
|
26391
|
-
const localPeerRole =
|
26392
|
-
const localPeerID =
|
26394
|
+
const peers = useHMSStore69(selectPeers3);
|
26395
|
+
const localPeerRole = useHMSStore69(selectLocalPeerRoleName5);
|
26396
|
+
const localPeerID = useHMSStore69(selectLocalPeerID14);
|
26393
26397
|
const [activeScreensharePeerId] = useSetAppDataByKey(APP_DATA.activeScreensharePeerId);
|
26394
26398
|
const isRoleProminence = prominentRoles.length && peers.some(
|
26395
26399
|
(peer) => peer.roleName && prominentRoles.includes(peer.roleName) && (peer.videoTrack || peer.audioTrack)
|
@@ -26409,10 +26413,10 @@ var GridLayout = ({
|
|
26409
26413
|
return peers;
|
26410
26414
|
}, [isInsetEnabled, activeScreensharePeerId, localPeerRole, localPeerID, prominentRoles, peers, pinnedTrack]);
|
26411
26415
|
const vanillaStore = useHMSVanillaStore12();
|
26412
|
-
const [sortedPeers, setSortedPeers] =
|
26416
|
+
const [sortedPeers, setSortedPeers] = useState60(updatedPeers);
|
26413
26417
|
const peersSorter = useMemo15(() => new PeersSorter_default(vanillaStore), [vanillaStore]);
|
26414
|
-
const [pageSize, setPageSize] =
|
26415
|
-
const [mainPage, setMainPage] =
|
26418
|
+
const [pageSize, setPageSize] = useState60(0);
|
26419
|
+
const [mainPage, setMainPage] = useState60(0);
|
26416
26420
|
const tileLayout = {
|
26417
26421
|
enableSpotlightingPeer: enable_spotlighting_peer,
|
26418
26422
|
hideParticipantNameOnTile: hide_participant_name_on_tile,
|
@@ -26469,13 +26473,13 @@ var GridLayout = ({
|
|
26469
26473
|
// src/Prebuilt/layouts/EmbedView.jsx
|
26470
26474
|
init_define_process_env();
|
26471
26475
|
import React143, { useEffect as useEffect41, useMemo as useMemo16 } from "react";
|
26472
|
-
import { selectAppData as selectAppData6, selectPeers as selectPeers4, selectPeerScreenSharing as selectPeerScreenSharing2, useEmbedShare, useHMSStore as
|
26476
|
+
import { selectAppData as selectAppData6, selectPeers as selectPeers4, selectPeerScreenSharing as selectPeerScreenSharing2, useEmbedShare, useHMSStore as useHMSStore70 } from "@100mslive/react-sdk";
|
26473
26477
|
var EmbedView = () => {
|
26474
26478
|
return /* @__PURE__ */ React143.createElement(EmbedScreenShareView, null, /* @__PURE__ */ React143.createElement(EmbedComponent, null));
|
26475
26479
|
};
|
26476
26480
|
var EmbedScreenShareView = ({ children }) => {
|
26477
|
-
const peers =
|
26478
|
-
const peerPresenting =
|
26481
|
+
const peers = useHMSStore70(selectPeers4);
|
26482
|
+
const peerPresenting = useHMSStore70(selectPeerScreenSharing2);
|
26479
26483
|
const [, setActiveScreenSharePeer] = useSetAppDataByKey(APP_DATA.activeScreensharePeerId);
|
26480
26484
|
const smallTilePeers = useMemo16(() => {
|
26481
26485
|
const smallTilePeers2 = peers.filter((peer) => peer.id !== (peerPresenting == null ? void 0 : peerPresenting.id));
|
@@ -26490,7 +26494,7 @@ var EmbedScreenShareView = ({ children }) => {
|
|
26490
26494
|
return /* @__PURE__ */ React143.createElement(ProminenceLayout.Root, null, /* @__PURE__ */ React143.createElement(ProminenceLayout.ProminentSection, null, children), /* @__PURE__ */ React143.createElement(SecondaryTiles, { peers: smallTilePeers }));
|
26491
26495
|
};
|
26492
26496
|
var EmbedComponent = () => {
|
26493
|
-
const embedConfig =
|
26497
|
+
const embedConfig = useHMSStore70(selectAppData6(APP_DATA.embedConfig));
|
26494
26498
|
const resetConfig = useResetEmbedConfig();
|
26495
26499
|
const { iframeRef, startEmbedShare, isEmbedShareInProgress } = useEmbedShare(resetConfig);
|
26496
26500
|
useEffect41(() => {
|
@@ -26647,9 +26651,11 @@ var WaitingView = React145.memo(() => {
|
|
26647
26651
|
// src/Prebuilt/layouts/WhiteboardView.tsx
|
26648
26652
|
init_define_process_env();
|
26649
26653
|
import React146, { useEffect as useEffect43, useMemo as useMemo17 } from "react";
|
26650
|
-
import {
|
26654
|
+
import { useMedia as useMedia29 } from "react-use";
|
26655
|
+
import { selectPeers as selectPeers5, selectWhiteboard, useHMSStore as useHMSStore71, useWhiteboard as useWhiteboard2 } from "@100mslive/react-sdk";
|
26651
26656
|
var EmbedComponent2 = () => {
|
26652
|
-
const
|
26657
|
+
const isMobile = useMedia29(config.media.md);
|
26658
|
+
const { iframeRef } = useWhiteboard2(isMobile);
|
26653
26659
|
return /* @__PURE__ */ React146.createElement(
|
26654
26660
|
Box,
|
26655
26661
|
{
|
@@ -26681,8 +26687,8 @@ var EmbedComponent2 = () => {
|
|
26681
26687
|
);
|
26682
26688
|
};
|
26683
26689
|
var WhiteboardView = () => {
|
26684
|
-
const peers =
|
26685
|
-
const whiteboard =
|
26690
|
+
const peers = useHMSStore71(selectPeers5);
|
26691
|
+
const whiteboard = useHMSStore71(selectWhiteboard);
|
26686
26692
|
const [, setActiveScreenSharePeer] = useSetAppDataByKey(APP_DATA.activeScreensharePeerId);
|
26687
26693
|
const smallTilePeers = useMemo17(() => {
|
26688
26694
|
const smallTilePeers2 = peers.filter((peer) => peer.id !== (whiteboard == null ? void 0 : whiteboard.owner));
|
@@ -26719,17 +26725,17 @@ var useCloseScreenshareWhiteboard = () => {
|
|
26719
26725
|
};
|
26720
26726
|
|
26721
26727
|
// src/Prebuilt/layouts/VideoStreamingSection.tsx
|
26722
|
-
var HLSView = React147.lazy(() => import("./HLSView-
|
26728
|
+
var HLSView = React147.lazy(() => import("./HLSView-S5JHEMWJ.js"));
|
26723
26729
|
var VideoStreamingSection = ({
|
26724
26730
|
screenType,
|
26725
26731
|
elements,
|
26726
26732
|
hideControls = false
|
26727
26733
|
}) => {
|
26728
26734
|
var _a8, _b7, _c, _d;
|
26729
|
-
const localPeerRole =
|
26730
|
-
const isConnected =
|
26731
|
-
const peerSharing =
|
26732
|
-
const isWhiteboardOpen = (_a8 =
|
26735
|
+
const localPeerRole = useHMSStore72(selectLocalPeerRoleName6);
|
26736
|
+
const isConnected = useHMSStore72(selectIsConnectedToRoom9);
|
26737
|
+
const peerSharing = useHMSStore72(selectPeerScreenSharing3);
|
26738
|
+
const isWhiteboardOpen = (_a8 = useHMSStore72(selectWhiteboard2)) == null ? void 0 : _a8.open;
|
26733
26739
|
const hmsActions = useHMSActions43();
|
26734
26740
|
const waitingViewerRole = useWaitingViewerRole();
|
26735
26741
|
const urlToIframe = useUrlToEmbed();
|
@@ -26793,8 +26799,8 @@ init_define_process_env();
|
|
26793
26799
|
// src/Prebuilt/components/Header/Header.tsx
|
26794
26800
|
init_define_process_env();
|
26795
26801
|
import React149 from "react";
|
26796
|
-
import { useMedia as
|
26797
|
-
import { HMSRoomState as HMSRoomState6, selectRoomState as selectRoomState6, useHMSStore as
|
26802
|
+
import { useMedia as useMedia30 } from "react-use";
|
26803
|
+
import { HMSRoomState as HMSRoomState6, selectRoomState as selectRoomState6, useHMSStore as useHMSStore74 } from "@100mslive/react-sdk";
|
26798
26804
|
|
26799
26805
|
// src/Prebuilt/components/Header/common.jsx
|
26800
26806
|
init_define_process_env();
|
@@ -26806,7 +26812,7 @@ import {
|
|
26806
26812
|
selectVideoTrackByID as selectVideoTrackByID7,
|
26807
26813
|
useDevices as useDevices3,
|
26808
26814
|
useHMSActions as useHMSActions44,
|
26809
|
-
useHMSStore as
|
26815
|
+
useHMSStore as useHMSStore73
|
26810
26816
|
} from "@100mslive/react-sdk";
|
26811
26817
|
import {
|
26812
26818
|
BluetoothIcon,
|
@@ -26820,9 +26826,9 @@ var CamaraFlipActions = () => {
|
|
26820
26826
|
const actions = useHMSActions44();
|
26821
26827
|
const { allDevices } = useDevices3();
|
26822
26828
|
const { videoInput } = allDevices;
|
26823
|
-
const isVideoOn =
|
26824
|
-
const videoTrackId =
|
26825
|
-
const localVideoTrack =
|
26829
|
+
const isVideoOn = useHMSStore73(selectIsLocalVideoEnabled7);
|
26830
|
+
const videoTrackId = useHMSStore73(selectLocalVideoTrackID3);
|
26831
|
+
const localVideoTrack = useHMSStore73(selectVideoTrackByID7(videoTrackId));
|
26826
26832
|
if (!videoInput || !(videoInput == null ? void 0 : videoInput.length) || !(localVideoTrack == null ? void 0 : localVideoTrack.facingMode)) {
|
26827
26833
|
return null;
|
26828
26834
|
}
|
@@ -26958,8 +26964,8 @@ var SelectWithLabel = ({ label, icon = /* @__PURE__ */ React148.createElement(Re
|
|
26958
26964
|
|
26959
26965
|
// src/Prebuilt/components/Header/Header.tsx
|
26960
26966
|
var Header2 = () => {
|
26961
|
-
const roomState =
|
26962
|
-
const isMobile =
|
26967
|
+
const roomState = useHMSStore74(selectRoomState6);
|
26968
|
+
const isMobile = useMedia30(config.media.md);
|
26963
26969
|
if (roomState !== HMSRoomState6.Connected) {
|
26964
26970
|
return /* @__PURE__ */ React149.createElement(React149.Fragment, null);
|
26965
26971
|
}
|
@@ -27004,11 +27010,11 @@ var ConferenceScreen = () => {
|
|
27004
27010
|
const { userName, endpoints, onJoin: onJoinFunc } = useHMSPrebuiltContext();
|
27005
27011
|
const screenProps = useRoomLayoutConferencingScreen();
|
27006
27012
|
const { isPreviewScreenEnabled } = useRoomLayoutPreviewScreen();
|
27007
|
-
const roomState =
|
27008
|
-
const isConnectedToRoom =
|
27013
|
+
const roomState = useHMSStore75(selectRoomState7);
|
27014
|
+
const isConnectedToRoom = useHMSStore75(selectIsConnectedToRoom10);
|
27009
27015
|
const hmsActions = useHMSActions45();
|
27010
|
-
const [hideControls, setHideControls] =
|
27011
|
-
const dropdownList =
|
27016
|
+
const [hideControls, setHideControls] = useState61(false);
|
27017
|
+
const dropdownList = useHMSStore75(selectAppData7(APP_DATA.dropdownList));
|
27012
27018
|
const authTokenInAppData = useAuthToken();
|
27013
27019
|
const headerRef = useRef22(null);
|
27014
27020
|
const footerRef = useRef22(null);
|
@@ -27212,7 +27218,7 @@ import React152, { useEffect as useEffect49 } from "react";
|
|
27212
27218
|
// src/Prebuilt/services/FeatureFlags.jsx
|
27213
27219
|
init_define_process_env();
|
27214
27220
|
import { useEffect as useEffect48 } from "react";
|
27215
|
-
import { selectRoomID, useHMSStore as
|
27221
|
+
import { selectRoomID, useHMSStore as useHMSStore76 } from "@100mslive/react-sdk";
|
27216
27222
|
var FeatureFlags = class {
|
27217
27223
|
static init(roomId) {
|
27218
27224
|
if (!window.HMS) {
|
@@ -27237,7 +27243,7 @@ __publicField(FeatureFlags, "enableTranscription", define_process_env_default.RE
|
|
27237
27243
|
__publicField(FeatureFlags, "enableStatsForNerds", define_process_env_default.REACT_APP_ENABLE_STATS_FOR_NERDS === "true");
|
27238
27244
|
__publicField(FeatureFlags, "enableWhiteboard", define_process_env_default.REACT_APP_ENABLE_WHITEBOARD && define_process_env_default.REACT_APP_PUSHER_APP_KEY && define_process_env_default.REACT_APP_PUSHER_AUTHENDPOINT);
|
27239
27245
|
function FeatureFlagsInit() {
|
27240
|
-
const roomId =
|
27246
|
+
const roomId = useHMSStore76(selectRoomID);
|
27241
27247
|
useEffect48(() => {
|
27242
27248
|
if (roomId) {
|
27243
27249
|
FeatureFlags.init(roomId);
|
@@ -27380,7 +27386,7 @@ import { ExitIcon as ExitIcon3 } from "@100mslive/react-icons";
|
|
27380
27386
|
init_define_process_env();
|
27381
27387
|
import React153, { useContext as useContext4, useEffect as useEffect51 } from "react";
|
27382
27388
|
import { usePreviousDistinct } from "react-use";
|
27383
|
-
import { HMSRoomState as HMSRoomState8, selectRoomState as selectRoomState8, useHMSStore as
|
27389
|
+
import { HMSRoomState as HMSRoomState8, selectRoomState as selectRoomState8, useHMSStore as useHMSStore77 } from "@100mslive/react-sdk";
|
27384
27390
|
|
27385
27391
|
// src/Prebuilt/components/hooks/useRedirectToLeave.tsx
|
27386
27392
|
init_define_process_env();
|
@@ -27417,7 +27423,7 @@ var useHMSAppStateContext = () => {
|
|
27417
27423
|
var useAppStateManager = () => {
|
27418
27424
|
const roomLayout = useRoomLayout();
|
27419
27425
|
const [activeState, setActiveState] = React153.useState();
|
27420
|
-
const roomState =
|
27426
|
+
const roomState = useHMSStore77(selectRoomState8);
|
27421
27427
|
const prevRoomState = usePreviousDistinct(roomState);
|
27422
27428
|
const { isLeaveScreenEnabled } = useRoomLayoutLeaveScreen();
|
27423
27429
|
const { isPreviewScreenEnabled } = useRoomLayoutPreviewScreen();
|
@@ -27489,12 +27495,12 @@ var LeaveScreen = () => {
|
|
27489
27495
|
|
27490
27496
|
// src/Prebuilt/components/MwebLandscapePrompt.tsx
|
27491
27497
|
init_define_process_env();
|
27492
|
-
import React155, { useEffect as useEffect52, useState as
|
27493
|
-
import { useMedia as
|
27498
|
+
import React155, { useEffect as useEffect52, useState as useState62 } from "react";
|
27499
|
+
import { useMedia as useMedia31 } from "react-use";
|
27494
27500
|
import { RefreshIcon } from "@100mslive/react-icons";
|
27495
27501
|
var MwebLandscapePrompt = () => {
|
27496
|
-
const [showMwebLandscapePrompt, setShowMwebLandscapePrompt] =
|
27497
|
-
const isLandscape =
|
27502
|
+
const [showMwebLandscapePrompt, setShowMwebLandscapePrompt] = useState62(false);
|
27503
|
+
const isLandscape = useMedia31(config.media.ls);
|
27498
27504
|
useEffect52(() => {
|
27499
27505
|
var _a8;
|
27500
27506
|
if (!isMobileUserAgent) {
|
@@ -27539,12 +27545,12 @@ import React164, { useCallback as useCallback33, useEffect as useEffect62 } from
|
|
27539
27545
|
import {
|
27540
27546
|
HMSNotificationTypes as HMSNotificationTypes10,
|
27541
27547
|
HMSRoomState as HMSRoomState10,
|
27542
|
-
selectLocalPeerID as
|
27548
|
+
selectLocalPeerID as selectLocalPeerID16,
|
27543
27549
|
selectPeerNameByID as selectPeerNameByID5,
|
27544
27550
|
selectRoomState as selectRoomState10,
|
27545
27551
|
useCustomEvent as useCustomEvent4,
|
27546
27552
|
useHMSNotifications as useHMSNotifications10,
|
27547
|
-
useHMSStore as
|
27553
|
+
useHMSStore as useHMSStore81,
|
27548
27554
|
useHMSVanillaStore as useHMSVanillaStore16
|
27549
27555
|
} from "@100mslive/react-sdk";
|
27550
27556
|
import { GroupIcon as GroupIcon2 } from "@100mslive/react-icons";
|
@@ -27555,7 +27561,7 @@ init_define_process_env();
|
|
27555
27561
|
// src/Prebuilt/components/Toast/ToastConfig.jsx
|
27556
27562
|
init_define_process_env();
|
27557
27563
|
import React156, { useCallback as useCallback32 } from "react";
|
27558
|
-
import { selectPeerByID as selectPeerByID4, useHMSActions as useHMSActions47, useHMSStore as
|
27564
|
+
import { selectPeerByID as selectPeerByID4, useHMSActions as useHMSActions47, useHMSStore as useHMSStore78 } from "@100mslive/react-sdk";
|
27559
27565
|
import {
|
27560
27566
|
ChatUnreadIcon,
|
27561
27567
|
ConnectivityIcon,
|
@@ -27577,7 +27583,7 @@ var HandRaiseAction = React156.forwardRef(({ id = "", isSingleHandRaise = true }
|
|
27577
27583
|
const hmsActions = useHMSActions47();
|
27578
27584
|
const toggleSidepane = useSidepaneToggle(SIDE_PANE_OPTIONS.PARTICIPANTS);
|
27579
27585
|
const isParticipantsOpen = useIsSidepaneTypeOpen(SIDE_PANE_OPTIONS.PARTICIPANTS);
|
27580
|
-
const peer =
|
27586
|
+
const peer = useHMSStore78(selectPeerByID4(id));
|
27581
27587
|
const layout = useRoomLayout();
|
27582
27588
|
const {
|
27583
27589
|
bring_to_stage_label,
|
@@ -27811,12 +27817,12 @@ function AutoplayBlockedModal() {
|
|
27811
27817
|
init_define_process_env();
|
27812
27818
|
import React158, { useEffect as useEffect53 } from "react";
|
27813
27819
|
import { v4 as uuid3 } from "uuid";
|
27814
|
-
import { selectLocalPeerID as
|
27820
|
+
import { selectLocalPeerID as selectLocalPeerID15, selectSessionStore as selectSessionStore11, useHMSStore as useHMSStore79 } from "@100mslive/react-sdk";
|
27815
27821
|
import { ChatIcon as ChatIcon2, ChatUnreadIcon as ChatUnreadIcon2 } from "@100mslive/react-icons";
|
27816
27822
|
var NOTIFICATION_TIME_DIFFERENCE = 5e3;
|
27817
27823
|
var ChatNotifications = () => {
|
27818
|
-
const chatState =
|
27819
|
-
const localPeerId =
|
27824
|
+
const chatState = useHMSStore79(selectSessionStore11("chatState" /* CHAT_STATE */));
|
27825
|
+
const localPeerId = useHMSStore79(selectLocalPeerID15);
|
27820
27826
|
useEffect53(() => {
|
27821
27827
|
var _a8, _b7;
|
27822
27828
|
if (!chatState || ((_a8 = chatState.updatedBy) == null ? void 0 : _a8.peerId) === localPeerId) {
|
@@ -27845,12 +27851,12 @@ import {
|
|
27845
27851
|
selectHasPeerHandRaised as selectHasPeerHandRaised4,
|
27846
27852
|
selectRoomState as selectRoomState9,
|
27847
27853
|
useHMSNotifications as useHMSNotifications2,
|
27848
|
-
useHMSStore as
|
27854
|
+
useHMSStore as useHMSStore80,
|
27849
27855
|
useHMSVanillaStore as useHMSVanillaStore15
|
27850
27856
|
} from "@100mslive/react-sdk";
|
27851
27857
|
var HandRaisedNotifications = () => {
|
27852
27858
|
const notification = useHMSNotifications2(HMSNotificationTypes2.HAND_RAISE_CHANGED);
|
27853
|
-
const roomState =
|
27859
|
+
const roomState = useHMSStore80(selectRoomState9);
|
27854
27860
|
const vanillaStore = useHMSVanillaStore15();
|
27855
27861
|
const { on_stage_exp } = useRoomLayoutConferencingScreen().elements || {};
|
27856
27862
|
useEffect54(() => {
|
@@ -27870,12 +27876,12 @@ var HandRaisedNotifications = () => {
|
|
27870
27876
|
|
27871
27877
|
// src/Prebuilt/components/Notifications/InitErrorModal.tsx
|
27872
27878
|
init_define_process_env();
|
27873
|
-
import React159, { useEffect as useEffect55, useState as
|
27879
|
+
import React159, { useEffect as useEffect55, useState as useState63 } from "react";
|
27874
27880
|
import { HMSNotificationTypes as HMSNotificationTypes3, useHMSNotifications as useHMSNotifications3 } from "@100mslive/react-sdk";
|
27875
27881
|
var InitErrorModal = () => {
|
27876
27882
|
const notification = useHMSNotifications3(HMSNotificationTypes3.ERROR);
|
27877
|
-
const [showModal, setShowModal] =
|
27878
|
-
const [info, setInfo] =
|
27883
|
+
const [showModal, setShowModal] = useState63(false);
|
27884
|
+
const [info, setInfo] = useState63({ title: "Init Error", description: "" });
|
27879
27885
|
useEffect55(() => {
|
27880
27886
|
const data3 = notification == null ? void 0 : notification.data;
|
27881
27887
|
if (!data3 || data3.action !== "INIT") {
|
@@ -27947,8 +27953,8 @@ var PeerNotifications = () => {
|
|
27947
27953
|
|
27948
27954
|
// src/Prebuilt/components/Notifications/PermissionErrorModal.tsx
|
27949
27955
|
init_define_process_env();
|
27950
|
-
import React160, { useEffect as useEffect57, useState as
|
27951
|
-
import { useMedia as
|
27956
|
+
import React160, { useEffect as useEffect57, useState as useState64 } from "react";
|
27957
|
+
import { useMedia as useMedia32 } from "react-use";
|
27952
27958
|
import { HMSNotificationTypes as HMSNotificationTypes5, useHMSNotifications as useHMSNotifications5 } from "@100mslive/react-sdk";
|
27953
27959
|
|
27954
27960
|
// src/Prebuilt/images/android-perm-1.png
|
@@ -27960,9 +27966,9 @@ var ios_perm_0_default = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAATwAAACh
|
|
27960
27966
|
// src/Prebuilt/components/Notifications/PermissionErrorModal.tsx
|
27961
27967
|
function PermissionErrorModal() {
|
27962
27968
|
const notification = useHMSNotifications5(HMSNotificationTypes5.ERROR);
|
27963
|
-
const [deviceType, setDeviceType] =
|
27964
|
-
const [isSystemError, setIsSystemError] =
|
27965
|
-
const isMobile =
|
27969
|
+
const [deviceType, setDeviceType] = useState64("");
|
27970
|
+
const [isSystemError, setIsSystemError] = useState64(false);
|
27971
|
+
const isMobile = useMedia32(config.media.md);
|
27966
27972
|
useEffect57(() => {
|
27967
27973
|
var _a8, _b7, _c, _d, _e;
|
27968
27974
|
if (!notification || ((_a8 = notification.data) == null ? void 0 : _a8.code) !== 3001 && ((_b7 = notification.data) == null ? void 0 : _b7.code) !== 3011 || ((_c = notification.data) == null ? void 0 : _c.code) === 3001 && ((_d = notification.data) == null ? void 0 : _d.message.includes("screen"))) {
|
@@ -28006,7 +28012,7 @@ function PermissionErrorModal() {
|
|
28006
28012
|
|
28007
28013
|
// src/Prebuilt/components/Notifications/ReconnectNotifications.tsx
|
28008
28014
|
init_define_process_env();
|
28009
|
-
import React161, { useEffect as useEffect58, useState as
|
28015
|
+
import React161, { useEffect as useEffect58, useState as useState65 } from "react";
|
28010
28016
|
import { HMSNotificationTypes as HMSNotificationTypes6, useHMSNotifications as useHMSNotifications6 } from "@100mslive/react-sdk";
|
28011
28017
|
var notificationTypes2 = [
|
28012
28018
|
HMSNotificationTypes6.RECONNECTED,
|
@@ -28016,7 +28022,7 @@ var notificationTypes2 = [
|
|
28016
28022
|
var notificationId = null;
|
28017
28023
|
var ReconnectNotifications = () => {
|
28018
28024
|
const notification = useHMSNotifications6(notificationTypes2);
|
28019
|
-
const [open, setOpen] =
|
28025
|
+
const [open, setOpen] = useState65(false);
|
28020
28026
|
useEffect58(() => {
|
28021
28027
|
var _a8, _b7;
|
28022
28028
|
if (!notification) {
|
@@ -28056,7 +28062,7 @@ var ReconnectNotifications = () => {
|
|
28056
28062
|
|
28057
28063
|
// src/Prebuilt/components/Notifications/TrackBulkUnmuteModal.tsx
|
28058
28064
|
init_define_process_env();
|
28059
|
-
import React162, { useEffect as useEffect59, useState as
|
28065
|
+
import React162, { useEffect as useEffect59, useState as useState66 } from "react";
|
28060
28066
|
import {
|
28061
28067
|
HMSNotificationTypes as HMSNotificationTypes7,
|
28062
28068
|
useHMSActions as useHMSActions48,
|
@@ -28065,7 +28071,7 @@ import {
|
|
28065
28071
|
import { MicOnIcon as MicOnIcon5 } from "@100mslive/react-icons";
|
28066
28072
|
var TrackBulkUnmuteModal = () => {
|
28067
28073
|
const hmsActions = useHMSActions48();
|
28068
|
-
const [muteNotification, setMuteNotification] =
|
28074
|
+
const [muteNotification, setMuteNotification] = useState66(null);
|
28069
28075
|
const notification = useHMSNotifications7([
|
28070
28076
|
HMSNotificationTypes7.CHANGE_MULTI_TRACK_STATE_REQUEST,
|
28071
28077
|
HMSNotificationTypes7.ROOM_ENDED,
|
@@ -28129,7 +28135,7 @@ var TrackNotifications = () => {
|
|
28129
28135
|
|
28130
28136
|
// src/Prebuilt/components/Notifications/TrackUnmuteModal.tsx
|
28131
28137
|
init_define_process_env();
|
28132
|
-
import React163, { useEffect as useEffect61, useState as
|
28138
|
+
import React163, { useEffect as useEffect61, useState as useState67 } from "react";
|
28133
28139
|
import {
|
28134
28140
|
HMSNotificationTypes as HMSNotificationTypes9,
|
28135
28141
|
useHMSActions as useHMSActions49,
|
@@ -28143,7 +28149,7 @@ var TrackUnmuteModal = () => {
|
|
28143
28149
|
HMSNotificationTypes9.ROOM_ENDED,
|
28144
28150
|
HMSNotificationTypes9.REMOVED_FROM_ROOM
|
28145
28151
|
]);
|
28146
|
-
const [muteNotification, setMuteNotification] =
|
28152
|
+
const [muteNotification, setMuteNotification] = useState67(null);
|
28147
28153
|
useEffect61(() => {
|
28148
28154
|
switch (notification == null ? void 0 : notification.type) {
|
28149
28155
|
case HMSNotificationTypes9.REMOVED_FROM_ROOM:
|
@@ -28179,11 +28185,12 @@ var TrackUnmuteModal = () => {
|
|
28179
28185
|
};
|
28180
28186
|
|
28181
28187
|
// src/Prebuilt/components/Notifications/Notifications.tsx
|
28188
|
+
var pollToastKey = {};
|
28182
28189
|
function Notifications() {
|
28183
|
-
const localPeerID =
|
28190
|
+
const localPeerID = useHMSStore81(selectLocalPeerID16);
|
28184
28191
|
const notification = useHMSNotifications10();
|
28185
28192
|
const subscribedNotifications = useSubscribedNotifications() || {};
|
28186
|
-
const roomState =
|
28193
|
+
const roomState = useHMSStore81(selectRoomState10);
|
28187
28194
|
const updateRoomLayoutForRole = useUpdateRoomLayout();
|
28188
28195
|
const isNotificationDisabled = useIsNotificationDisabled();
|
28189
28196
|
const screenProps = useRoomLayoutConferencingScreen();
|
@@ -28282,7 +28289,7 @@ function Notifications() {
|
|
28282
28289
|
case HMSNotificationTypes10.POLL_STARTED:
|
28283
28290
|
if (notification.data.startedBy !== localPeerID && screenProps.screenType !== "hls_live_streaming") {
|
28284
28291
|
const pollStartedBy = vanillaStore.getState(selectPeerNameByID5(notification.data.startedBy)) || "Participant";
|
28285
|
-
ToastManager.addToast({
|
28292
|
+
const pollToastID = ToastManager.addToast({
|
28286
28293
|
title: `${pollStartedBy} started a ${notification.data.type}: ${notification.data.title}`,
|
28287
28294
|
action: /* @__PURE__ */ React164.createElement(
|
28288
28295
|
Button,
|
@@ -28297,8 +28304,17 @@ function Notifications() {
|
|
28297
28304
|
}
|
28298
28305
|
},
|
28299
28306
|
notification.data.type === "quiz" ? "Answer" : "Vote"
|
28300
|
-
)
|
28307
|
+
),
|
28308
|
+
duration: Infinity
|
28301
28309
|
});
|
28310
|
+
pollToastKey[notification.data.id] = pollToastID;
|
28311
|
+
}
|
28312
|
+
break;
|
28313
|
+
case HMSNotificationTypes10.POLL_STOPPED:
|
28314
|
+
const pollID = notification == null ? void 0 : notification.data.id;
|
28315
|
+
if (pollID && (pollToastKey == null ? void 0 : pollToastKey[pollID])) {
|
28316
|
+
ToastManager.removeToast(pollToastKey == null ? void 0 : pollToastKey[notification.data.id]);
|
28317
|
+
delete pollToastKey[notification == null ? void 0 : notification.data.id];
|
28302
28318
|
}
|
28303
28319
|
break;
|
28304
28320
|
default:
|
@@ -28338,8 +28354,8 @@ var PreviewScreen = () => {
|
|
28338
28354
|
|
28339
28355
|
// src/Prebuilt/components/Toast/ToastContainer.jsx
|
28340
28356
|
init_define_process_env();
|
28341
|
-
import React167, { useEffect as useEffect63, useState as
|
28342
|
-
import { selectIsConnectedToRoom as selectIsConnectedToRoom11, useHMSStore as
|
28357
|
+
import React167, { useEffect as useEffect63, useState as useState68 } from "react";
|
28358
|
+
import { selectIsConnectedToRoom as selectIsConnectedToRoom11, useHMSStore as useHMSStore82 } from "@100mslive/react-sdk";
|
28343
28359
|
|
28344
28360
|
// src/Prebuilt/components/Toast/Toast.jsx
|
28345
28361
|
init_define_process_env();
|
@@ -28362,8 +28378,8 @@ var Toast2 = (_a8) => {
|
|
28362
28378
|
|
28363
28379
|
// src/Prebuilt/components/Toast/ToastContainer.jsx
|
28364
28380
|
var ToastContainer = () => {
|
28365
|
-
const isConnected =
|
28366
|
-
const [toasts, setToast] =
|
28381
|
+
const isConnected = useHMSStore82(selectIsConnectedToRoom11);
|
28382
|
+
const [toasts, setToast] = useState68([]);
|
28367
28383
|
useEffect63(() => {
|
28368
28384
|
ToastManager.addListener(setToast);
|
28369
28385
|
return () => {
|
@@ -28384,13 +28400,13 @@ var ToastContainer = () => {
|
|
28384
28400
|
|
28385
28401
|
// src/Prebuilt/plugins/FlyingEmoji.jsx
|
28386
28402
|
init_define_process_env();
|
28387
|
-
import React168, { useCallback as useCallback34, useEffect as useEffect64, useMemo as useMemo18, useState as
|
28388
|
-
import { useMedia as
|
28403
|
+
import React168, { useCallback as useCallback34, useEffect as useEffect64, useMemo as useMemo18, useState as useState69 } from "react";
|
28404
|
+
import { useMedia as useMedia33 } from "react-use";
|
28389
28405
|
import {
|
28390
|
-
selectLocalPeerID as
|
28406
|
+
selectLocalPeerID as selectLocalPeerID17,
|
28391
28407
|
selectPeerNameByID as selectPeerNameByID6,
|
28392
28408
|
useCustomEvent as useCustomEvent5,
|
28393
|
-
useHMSStore as
|
28409
|
+
useHMSStore as useHMSStore83,
|
28394
28410
|
useHMSVanillaStore as useHMSVanillaStore17
|
28395
28411
|
} from "@100mslive/react-sdk";
|
28396
28412
|
var emojiCount = 1;
|
@@ -28417,10 +28433,10 @@ var getStartingPoints = (isMobile) => {
|
|
28417
28433
|
return arr;
|
28418
28434
|
};
|
28419
28435
|
function FlyingEmoji() {
|
28420
|
-
const localPeerId =
|
28436
|
+
const localPeerId = useHMSStore83(selectLocalPeerID17);
|
28421
28437
|
const vanillaStore = useHMSVanillaStore17();
|
28422
|
-
const [emojis, setEmojis] =
|
28423
|
-
const isMobile =
|
28438
|
+
const [emojis, setEmojis] = useState69([]);
|
28439
|
+
const isMobile = useMedia33(config.media.md);
|
28424
28440
|
const startingPoints = useMemo18(() => getStartingPoints(isMobile), [isMobile]);
|
28425
28441
|
const showFlyingEmoji = useCallback34(
|
28426
28442
|
({ emojiId, senderId }) => {
|
@@ -28536,15 +28552,15 @@ import {
|
|
28536
28552
|
selectIsConnectedToRoom as selectIsConnectedToRoom12,
|
28537
28553
|
selectPermissions as selectPermissions16,
|
28538
28554
|
useHMSActions as useHMSActions51,
|
28539
|
-
useHMSStore as
|
28555
|
+
useHMSStore as useHMSStore84,
|
28540
28556
|
useRecordingStreaming as useRecordingStreaming11
|
28541
28557
|
} from "@100mslive/react-sdk";
|
28542
28558
|
var useAutoStartStreaming = () => {
|
28543
28559
|
const [isHLSStarted, setHLSStarted] = useSetAppDataByKey(APP_DATA.hlsStarted);
|
28544
|
-
const permissions =
|
28560
|
+
const permissions = useHMSStore84(selectPermissions16);
|
28545
28561
|
const showStreamingUI = useShowStreamingUI();
|
28546
28562
|
const hmsActions = useHMSActions51();
|
28547
|
-
const isConnected =
|
28563
|
+
const isConnected = useHMSStore84(selectIsConnectedToRoom12);
|
28548
28564
|
const { isHLSRunning, isRTMPRunning, isHLSRecordingOn, isBrowserRecordingOn } = useRecordingStreaming11();
|
28549
28565
|
const streamStartedRef = useRef23(false);
|
28550
28566
|
const startHLS = useCallback36(() => __async(void 0, null, function* () {
|
@@ -28740,7 +28756,7 @@ var AppStates = ({ activeState }) => {
|
|
28740
28756
|
return /* @__PURE__ */ React170.createElement(ConferenceScreen, null);
|
28741
28757
|
};
|
28742
28758
|
var BackSwipe = () => {
|
28743
|
-
const isConnectedToRoom =
|
28759
|
+
const isConnectedToRoom = useHMSStore85(selectIsConnectedToRoom13);
|
28744
28760
|
const hmsActions = useHMSActions52();
|
28745
28761
|
useEffect66(() => {
|
28746
28762
|
const onRouteLeave = () => __async(void 0, null, function* () {
|
@@ -28903,4 +28919,4 @@ lodash/lodash.js:
|
|
28903
28919
|
* Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
|
28904
28920
|
*)
|
28905
28921
|
*/
|
28906
|
-
//# sourceMappingURL=chunk-
|
28922
|
+
//# sourceMappingURL=chunk-AWWYBQSE.js.map
|