@100mslive/roomkit-react 0.1.13-alpha.0 → 0.1.13
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/{HLSView-AIPLCDXY.js → HLSView-IENE4HRP.js} +2 -2
- package/dist/Prebuilt/components/Notifications/ChatNotifications.d.ts +2 -0
- package/dist/{chunk-5DCII2TP.js → chunk-U4AB6X6M.js} +945 -911
- package/dist/chunk-U4AB6X6M.js.map +7 -0
- package/dist/index.cjs.js +1450 -1400
- package/dist/index.cjs.js.map +4 -4
- package/dist/index.js +1 -1
- package/dist/meta.cjs.json +227 -148
- package/dist/meta.esbuild.json +232 -153
- package/package.json +6 -6
- package/src/Prebuilt/components/AuthToken.jsx +12 -2
- package/src/Prebuilt/components/Chat/Chat.jsx +5 -7
- package/src/Prebuilt/components/Chat/ChatBody.jsx +53 -34
- package/src/Prebuilt/components/Chat/ChatFooter.tsx +13 -7
- package/src/Prebuilt/components/Chat/ChatStates.jsx +8 -6
- package/src/Prebuilt/components/Chat/Navigation.tsx +1 -1
- package/src/Prebuilt/components/Chat/PinnedMessage.tsx +15 -17
- package/src/Prebuilt/components/Notifications/ChatNotifications.tsx +34 -0
- package/src/Prebuilt/components/Notifications/Notifications.tsx +2 -0
- package/src/Prebuilt/components/Polls/Voting/QuestionCard.jsx +6 -4
- package/src/Prebuilt/components/Polls/Voting/TimedVoting.jsx +3 -2
- package/src/Prebuilt/components/Polls/common/VoteCount.jsx +6 -4
- package/src/Prebuilt/components/Preview/PreviewJoin.tsx +1 -1
- package/src/Prebuilt/components/Toast/ToastConfig.jsx +0 -19
- package/src/Prebuilt/components/VirtualBackground/VBPicker.tsx +46 -35
- package/src/Prebuilt/components/hooks/useSetPinnedMessages.ts +1 -2
- package/src/Prebuilt/components/hooks/useUserPreferences.jsx +1 -0
- package/src/Prebuilt/layouts/VideoStreamingSection.tsx +10 -30
- package/dist/chunk-5DCII2TP.js.map +0 -7
- /package/dist/{HLSView-AIPLCDXY.js.map → HLSView-IENE4HRP.js.map} +0 -0
@@ -9,18 +9,18 @@ var __getProtoOf = Object.getPrototypeOf;
|
|
9
9
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
10
10
|
var __propIsEnum = Object.prototype.propertyIsEnumerable;
|
11
11
|
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
12
|
-
var __spreadValues = (a,
|
13
|
-
for (var prop in
|
14
|
-
if (__hasOwnProp.call(
|
15
|
-
__defNormalProp(a, prop,
|
12
|
+
var __spreadValues = (a, b2) => {
|
13
|
+
for (var prop in b2 || (b2 = {}))
|
14
|
+
if (__hasOwnProp.call(b2, prop))
|
15
|
+
__defNormalProp(a, prop, b2[prop]);
|
16
16
|
if (__getOwnPropSymbols)
|
17
|
-
for (var prop of __getOwnPropSymbols(
|
18
|
-
if (__propIsEnum.call(
|
19
|
-
__defNormalProp(a, prop,
|
17
|
+
for (var prop of __getOwnPropSymbols(b2)) {
|
18
|
+
if (__propIsEnum.call(b2, prop))
|
19
|
+
__defNormalProp(a, prop, b2[prop]);
|
20
20
|
}
|
21
21
|
return a;
|
22
22
|
};
|
23
|
-
var __spreadProps = (a,
|
23
|
+
var __spreadProps = (a, b2) => __defProps(a, __getOwnPropDescs(b2));
|
24
24
|
var __objRest = (source, exclude) => {
|
25
25
|
var target = {};
|
26
26
|
for (var prop in source)
|
@@ -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_1507171e-af23-403f-be40-f193741a1cfa", 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.18.2 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.8.22-alpha.0", RUNNER_ENVIRONMENT: "github-hosted", GITHUB_ENV: "/home/runner/work/_temp/_runner_file_commands/set_env_1507171e-af23-403f-be40-f193741a1cfa", PIPX_HOME: "/opt/pipx", npm_node_execpath: "/opt/hostedtoolcache/node/18.18.2/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.11.22-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.4", 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.4", 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: "568", 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.7", 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.11/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.4/x64", JAVA_HOME_17_X64: "/usr/lib/jvm/temurin-17-jdk-amd64", ImageVersion: "20231115.7.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:17505", 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_sdk: "cd packages/hms-video-web && yarn start", 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.1.22-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: "6943367684", 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: "b12ee3cc718d94936eb45de704bd29f823a5cad9", 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: "c6acd957d60a56a41071e813c5b24ea368d489e098ed570cac666c7b2b364cf2", npm_package_exports___import: "./dist/index.js", STATS_BLT: "true", GITHUB_WORKFLOW_REF: "100mslive/web-sdks/.github/workflows/publish.yml@refs/heads/main", PERFLOG_LOCATION_SETTING: "RUNNER_PERFLOG", GITHUB_ACTION_REPOSITORY: "", npm_package_workspaces_2: "playwright/*", npm_package_devDependencies_postcss_loader: "^6.2.1", PATH: "/tmp/yarn--1700567606115-0.15531052822785396:/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.18.2/x64/libexec/lib/node_modules/npm/bin/node-gyp-bin:/opt/hostedtoolcache/node/18.18.2/x64/lib/node_modules/npm/bin/node-gyp-bin:/opt/hostedtoolcache/node/18.18.2/x64/bin/node_modules/npm/bin/node-gyp-bin:/tmp/yarn--1700567605836-0.6332561245046708:/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.18.2/x64/libexec/lib/node_modules/npm/bin/node-gyp-bin:/opt/hostedtoolcache/node/18.18.2/x64/lib/node_modules/npm/bin/node-gyp-bin:/opt/hostedtoolcache/node/18.18.2/x64/bin/node_modules/npm/bin/node-gyp-bin:/tmp/yarn--1700567563445-0.5035632782182475:/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.18.2/x64/libexec/lib/node_modules/npm/bin/node-gyp-bin:/opt/hostedtoolcache/node/18.18.2/x64/lib/node_modules/npm/bin/node-gyp-bin:/opt/hostedtoolcache/node/18.18.2/x64/bin/node_modules/npm/bin/node-gyp-bin:/tmp/yarn--1700567563195-0.28601361957438254:/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.18.2/x64/libexec/lib/node_modules/npm/bin/node-gyp-bin:/opt/hostedtoolcache/node/18.18.2/x64/lib/node_modules/npm/bin/node-gyp-bin:/opt/hostedtoolcache/node/18.18.2/x64/bin/node_modules/npm/bin/node-gyp-bin:/opt/hostedtoolcache/node/18.18.2/x64/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:/snap/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin", NODE: "/opt/hostedtoolcache/node/18.18.2/x64/bin/node", ANT_HOME: "/usr/share/ant", DOTNET_MULTILEVEL_LOOKUP: "0", RUNNER_TRACKING_ID: "github_5b8a6d09-49c4-402c-ad8f-f11cbd825cc0", INVOCATION_ID: "af7fe0975e4a44959b70163722e37ae7", 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: "387", 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_pusher_js: "^7.0.3", npm_package_dependencies__radix_ui_react_select: "1.0.0", npm_package_size_limit_0_limit: "80 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: "80 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 4", XDG_CONFIG_HOME: "/home/runner/.config", STATS_VMD: "true", GITHUB_REF_NAME: "main", GITHUB_REPOSITORY: "100mslive/web-sdks", npm_lifecycle_script: "rm -rf dist && node ../../scripts/build-webapp", npm_package_size_limit_2_limit: "20 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-web/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.8.22-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.1.13-alpha.0", npm_package_size_limit_4_limit: "400 KB", npm_package_size_limit_1_path: "packages/hms-video-web/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: "true", npm_config_argv: '{"remain":[],"cooked":["run","test"],"original":["test"]}', npm_package_size_limit_5_limit: "20 KB", npm_package_size_limit_2_path: "packages/hms-video-store/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: "20 KB", npm_package_size_limit_3_path: "packages/hms-video-store/dist/index.js", npm_package_devDependencies_cypress: "^9.5.2", npm_package_devDependencies_rollup_plugin_esbuild: "^5.0.0", GITHUB_SHA: "b12ee3cc718d94936eb45de704bd29f823a5cad9", GITHUB_RUN_ATTEMPT: "1", npm_package_size_limit_7_limit: "20 KB", npm_package_size_limit_4_path: "packages/roomkit-react/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/main", GITHUB_ACTOR: "KaustubhKumar05", ANDROID_SDK_ROOT: "/usr/local/lib/android/sdk", npm_package_size_limit_8_limit: "100 KB", npm_package_size_limit_5_path: "packages/roomkit-react/dist/index.js", npm_config_strict_ssl: "true", npm_package_license: "MIT", LEIN_HOME: "/usr/local/lib/lein", npm_package_size_limit_9_limit: "100 KB", npm_package_size_limit_6_path: "packages/hms-virtual-background/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_1507171e-af23-403f-be40-f193741a1cfa", 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/hms-virtual-background/dist/index.js", npm_package_scripts_ybys: "yarn && yarn build && 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_1507171e-af23-403f-be40-f193741a1cfa", npm_package_size_limit_8_path: "packages/react-icons/dist/index.cjs.js", 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_size_limit_9_path: "packages/react-icons/dist/index.js", 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_1507171e-af23-403f-be40-f193741a1cfa" };
|
109
|
+
define_process_env_default = { GITHUB_STATE: "/home/runner/work/_temp/_runner_file_commands/save_state_01c3e10a-a29c-4c6a-b900-d583806c1adc", 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.18.2 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.8.22", RUNNER_ENVIRONMENT: "github-hosted", GITHUB_ENV: "/home/runner/work/_temp/_runner_file_commands/set_env_01c3e10a-a29c-4c6a-b900-d583806c1adc", PIPX_HOME: "/opt/pipx", npm_node_execpath: "/opt/hostedtoolcache/node/18.18.2/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.11.22", 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.4", 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.4", 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: "565", 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.7", 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.11/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.4/x64", JAVA_HOME_17_X64: "/usr/lib/jvm/temurin-17-jdk-amd64", ImageVersion: "20231115.7.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:17339", 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_sdk: "cd packages/hms-video-web && yarn start", 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.1.22", 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: "7017255758", 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: "543b9152024ee7e4554701f1387b1af32906b58a", 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: "333fe669253d80c0e7b664252041be08e126f3d86595fcace0d06236678a1f99", npm_package_exports___import: "./dist/index.js", STATS_BLT: "true", GITHUB_WORKFLOW_REF: "100mslive/web-sdks/.github/workflows/publish.yml@refs/heads/main", PERFLOG_LOCATION_SETTING: "RUNNER_PERFLOG", GITHUB_ACTION_REPOSITORY: "", npm_package_workspaces_2: "playwright/*", npm_package_devDependencies_postcss_loader: "^6.2.1", PATH: "/tmp/yarn--1701166633022-0.6115980651650976:/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.18.2/x64/libexec/lib/node_modules/npm/bin/node-gyp-bin:/opt/hostedtoolcache/node/18.18.2/x64/lib/node_modules/npm/bin/node-gyp-bin:/opt/hostedtoolcache/node/18.18.2/x64/bin/node_modules/npm/bin/node-gyp-bin:/tmp/yarn--1701166632780-0.6572625836808592:/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.18.2/x64/libexec/lib/node_modules/npm/bin/node-gyp-bin:/opt/hostedtoolcache/node/18.18.2/x64/lib/node_modules/npm/bin/node-gyp-bin:/opt/hostedtoolcache/node/18.18.2/x64/bin/node_modules/npm/bin/node-gyp-bin:/tmp/yarn--1701166593503-0.857170625864504:/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.18.2/x64/libexec/lib/node_modules/npm/bin/node-gyp-bin:/opt/hostedtoolcache/node/18.18.2/x64/lib/node_modules/npm/bin/node-gyp-bin:/opt/hostedtoolcache/node/18.18.2/x64/bin/node_modules/npm/bin/node-gyp-bin:/tmp/yarn--1701166593262-0.43174274543206836:/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.18.2/x64/libexec/lib/node_modules/npm/bin/node-gyp-bin:/opt/hostedtoolcache/node/18.18.2/x64/lib/node_modules/npm/bin/node-gyp-bin:/opt/hostedtoolcache/node/18.18.2/x64/bin/node_modules/npm/bin/node-gyp-bin:/opt/hostedtoolcache/node/18.18.2/x64/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:/snap/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin", NODE: "/opt/hostedtoolcache/node/18.18.2/x64/bin/node", ANT_HOME: "/usr/share/ant", DOTNET_MULTILEVEL_LOOKUP: "0", RUNNER_TRACKING_ID: "github_ed1d28b1-c8ec-4187-979e-0b481bca50c1", INVOCATION_ID: "381071a175cf453cabbb96d4077b224e", 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: "389", GITHUB_TRIGGERING_ACTOR: "raviteja83", 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_pusher_js: "^7.0.3", npm_package_dependencies__radix_ui_react_select: "1.0.0", npm_package_size_limit_0_limit: "80 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: "80 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: "main", GITHUB_REPOSITORY: "100mslive/web-sdks", npm_lifecycle_script: "rm -rf dist && node ../../scripts/build-webapp", npm_package_size_limit_2_limit: "20 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-web/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.8.22", npm_package_scripts_types: "tsc -w", GITHUB_REPOSITORY_ID: "429826515", GITHUB_ACTIONS: "true", npm_lifecycle_event: "build:only", npm_package_version: "0.1.13", npm_package_size_limit_4_limit: "400 KB", npm_package_size_limit_1_path: "packages/hms-video-web/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: "true", npm_config_argv: '{"remain":[],"cooked":["run","test"],"original":["test"]}', npm_package_size_limit_5_limit: "20 KB", npm_package_size_limit_2_path: "packages/hms-video-store/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: "20 KB", npm_package_size_limit_3_path: "packages/hms-video-store/dist/index.js", npm_package_devDependencies_cypress: "^9.5.2", npm_package_devDependencies_rollup_plugin_esbuild: "^5.0.0", GITHUB_SHA: "543b9152024ee7e4554701f1387b1af32906b58a", GITHUB_RUN_ATTEMPT: "1", npm_package_size_limit_7_limit: "20 KB", npm_package_size_limit_4_path: "packages/roomkit-react/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/main", GITHUB_ACTOR: "raviteja83", ANDROID_SDK_ROOT: "/usr/local/lib/android/sdk", npm_package_size_limit_8_limit: "100 KB", npm_package_size_limit_5_path: "packages/roomkit-react/dist/index.js", npm_config_strict_ssl: "true", npm_package_license: "MIT", LEIN_HOME: "/usr/local/lib/lein", npm_package_size_limit_9_limit: "100 KB", npm_package_size_limit_6_path: "packages/hms-virtual-background/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_01c3e10a-a29c-4c6a-b900-d583806c1adc", JAVA_HOME: "/usr/lib/jvm/temurin-11-jdk-amd64", PWD: "/home/runner/work/web-sdks/web-sdks/packages/roomkit-react", GITHUB_ACTOR_ID: "6763261", 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/hms-virtual-background/dist/index.js", npm_package_scripts_ybys: "yarn && yarn build && 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_01c3e10a-a29c-4c6a-b900-d583806c1adc", npm_package_size_limit_8_path: "packages/react-icons/dist/index.cjs.js", 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_size_limit_9_path: "packages/react-icons/dist/index.js", 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_01c3e10a-a29c-4c6a-b900-d583806c1adc" };
|
110
110
|
}
|
111
111
|
});
|
112
112
|
|
@@ -5612,13 +5612,13 @@ var Collapsible = {
|
|
5612
5612
|
|
5613
5613
|
// src/Prebuilt/App.tsx
|
5614
5614
|
init_define_process_env();
|
5615
|
-
import
|
5615
|
+
import React156, { useEffect as useEffect59, useRef as useRef25 } from "react";
|
5616
5616
|
import {
|
5617
5617
|
HMSReactiveStore,
|
5618
5618
|
HMSRoomProvider,
|
5619
5619
|
selectIsConnectedToRoom as selectIsConnectedToRoom13,
|
5620
5620
|
useHMSActions as useHMSActions48,
|
5621
|
-
useHMSStore as
|
5621
|
+
useHMSStore as useHMSStore75
|
5622
5622
|
} from "@100mslive/react-sdk";
|
5623
5623
|
|
5624
5624
|
// src/Prebuilt/components/AppData/AppData.tsx
|
@@ -5691,7 +5691,8 @@ var UserPreferencesKeys = {
|
|
5691
5691
|
PREVIEW: "preview",
|
5692
5692
|
NOTIFICATIONS: "notifications",
|
5693
5693
|
UI_SETTINGS: "uiSettings",
|
5694
|
-
RTMP_URLS: "rtmpUrls"
|
5694
|
+
RTMP_URLS: "rtmpUrls",
|
5695
|
+
USER_ID: "userId"
|
5695
5696
|
};
|
5696
5697
|
var defaultPreviewPreference = {
|
5697
5698
|
name: "",
|
@@ -6139,6 +6140,8 @@ var ResetStreamingStart = () => {
|
|
6139
6140
|
// src/Prebuilt/components/AuthToken.jsx
|
6140
6141
|
init_define_process_env();
|
6141
6142
|
import React23, { useEffect as useEffect5, useState as useState5 } from "react";
|
6143
|
+
import { useSessionStorage } from "react-use";
|
6144
|
+
import { v4 } from "uuid";
|
6142
6145
|
import { useHMSActions as useHMSActions4 } from "@100mslive/react-sdk";
|
6143
6146
|
|
6144
6147
|
// src/Prebuilt/AppContext.tsx
|
@@ -6325,6 +6328,12 @@ var AuthToken = React23.memo(({ authTokenByRoomCodeEndpoint, defaultAuthToken })
|
|
6325
6328
|
const [error, setError] = useState5({ title: "", body: "" });
|
6326
6329
|
let authToken = defaultAuthToken;
|
6327
6330
|
const [, setAuthTokenInAppData] = useSetAppDataByKey(APP_DATA.authToken);
|
6331
|
+
const [savedUserId, setSavedUserId] = useSessionStorage(UserPreferencesKeys.USER_ID);
|
6332
|
+
useEffect5(() => {
|
6333
|
+
if (!savedUserId && !userId) {
|
6334
|
+
setSavedUserId(v4());
|
6335
|
+
}
|
6336
|
+
}, [savedUserId, setSavedUserId, userId]);
|
6328
6337
|
useEffect5(() => {
|
6329
6338
|
if (authToken) {
|
6330
6339
|
setAuthTokenInAppData(authToken);
|
@@ -6333,8 +6342,8 @@ var AuthToken = React23.memo(({ authTokenByRoomCodeEndpoint, defaultAuthToken })
|
|
6333
6342
|
if (!roomCode) {
|
6334
6343
|
return;
|
6335
6344
|
}
|
6336
|
-
hmsActions.getAuthTokenByRoomCode({ roomCode, userId }, { endpoint: authTokenByRoomCodeEndpoint }).then((token) => setAuthTokenInAppData(token)).catch((error2) => setError(convertError(error2)));
|
6337
|
-
}, [hmsActions, authToken, authTokenByRoomCodeEndpoint, setAuthTokenInAppData, roomCode, userId]);
|
6345
|
+
hmsActions.getAuthTokenByRoomCode({ roomCode, userId: userId || savedUserId }, { endpoint: authTokenByRoomCodeEndpoint }).then((token) => setAuthTokenInAppData(token)).catch((error2) => setError(convertError(error2)));
|
6346
|
+
}, [hmsActions, authToken, authTokenByRoomCodeEndpoint, setAuthTokenInAppData, roomCode, userId, savedUserId]);
|
6338
6347
|
if (error.title) {
|
6339
6348
|
return /* @__PURE__ */ React23.createElement(ErrorDialog, { title: error.title }, error.body);
|
6340
6349
|
}
|
@@ -6385,14 +6394,14 @@ var AuthToken_default = AuthToken;
|
|
6385
6394
|
|
6386
6395
|
// src/Prebuilt/components/ConferenceScreen.tsx
|
6387
6396
|
init_define_process_env();
|
6388
|
-
import
|
6397
|
+
import React136, { useEffect as useEffect42, useRef as useRef23, useState as useState55 } from "react";
|
6389
6398
|
import {
|
6390
6399
|
HMSRoomState as HMSRoomState7,
|
6391
6400
|
selectAppData as selectAppData7,
|
6392
6401
|
selectIsConnectedToRoom as selectIsConnectedToRoom10,
|
6393
6402
|
selectRoomState as selectRoomState7,
|
6394
|
-
useHMSActions as
|
6395
|
-
useHMSStore as
|
6403
|
+
useHMSActions as useHMSActions41,
|
6404
|
+
useHMSStore as useHMSStore67
|
6396
6405
|
} from "@100mslive/react-sdk";
|
6397
6406
|
|
6398
6407
|
// src/Prebuilt/components/Footer/Footer.tsx
|
@@ -6549,12 +6558,12 @@ var IconButtonWithOptions = ({
|
|
6549
6558
|
|
6550
6559
|
// src/Prebuilt/components/Toast/ToastManager.js
|
6551
6560
|
init_define_process_env();
|
6552
|
-
import { v4 } from "uuid";
|
6561
|
+
import { v4 as v42 } from "uuid";
|
6553
6562
|
var ToastManager = {
|
6554
6563
|
toasts: /* @__PURE__ */ new Map(),
|
6555
6564
|
listeners: /* @__PURE__ */ new Map(),
|
6556
6565
|
addToast(toast) {
|
6557
|
-
const id = toast.id ? toast.id :
|
6566
|
+
const id = toast.id ? toast.id : v42();
|
6558
6567
|
this.toasts.set(id, __spreadProps(__spreadValues({}, toast), { id }));
|
6559
6568
|
this.onChange();
|
6560
6569
|
return id;
|
@@ -9047,7 +9056,7 @@ var useTracksWithLabel = () => {
|
|
9047
9056
|
return tracksWithLabels;
|
9048
9057
|
};
|
9049
9058
|
var LocalPeerStats = () => {
|
9050
|
-
var _a7, _b7, _c, _d, _e, _f, _g, _h,
|
9059
|
+
var _a7, _b7, _c, _d, _e, _f, _g, _h, _i2;
|
9051
9060
|
const stats = useHMSStatsStore2(selectHMSStats2.localPeerStats);
|
9052
9061
|
if (!stats) {
|
9053
9062
|
return null;
|
@@ -9062,7 +9071,7 @@ var LocalPeerStats = () => {
|
|
9062
9071
|
StatsRow2,
|
9063
9072
|
{
|
9064
9073
|
label: "Round Trip Time",
|
9065
|
-
value: `${(((((_h = stats.publish) == null ? void 0 : _h.currentRoundTripTime) || 0) + (((
|
9074
|
+
value: `${(((((_h = stats.publish) == null ? void 0 : _h.currentRoundTripTime) || 0) + (((_i2 = stats.subscribe) == null ? void 0 : _i2.currentRoundTripTime) || 0)) / 2).toFixed(3) * 1e3} ms`
|
9066
9075
|
}
|
9067
9076
|
));
|
9068
9077
|
};
|
@@ -9566,10 +9575,10 @@ import { useMedia as useMedia5 } from "react-use";
|
|
9566
9575
|
// ../hms-video-web/dist/index.js
|
9567
9576
|
init_define_process_env();
|
9568
9577
|
var import_ua_parser_js = __toESM(require_ua_parser());
|
9569
|
-
import { v4 as
|
9570
|
-
import { v4 as
|
9571
|
-
import { v4 as
|
9572
|
-
import { v4 as
|
9578
|
+
import { v4 as Lr } from "uuid";
|
9579
|
+
import { v4 as ls } from "uuid";
|
9580
|
+
import { v4 as Vr } from "uuid";
|
9581
|
+
import { v4 as Gr } from "uuid";
|
9573
9582
|
|
9574
9583
|
// ../../node_modules/webrtc-adapter/src/js/adapter_core.js
|
9575
9584
|
init_define_process_env();
|
@@ -9859,9 +9868,9 @@ function shimGetUserMedia(window2, browserDetails) {
|
|
9859
9868
|
}
|
9860
9869
|
constraints = JSON.parse(JSON.stringify(constraints));
|
9861
9870
|
if (constraints && typeof constraints.audio === "object") {
|
9862
|
-
const remap = function(obj, a,
|
9863
|
-
if (a in obj && !(
|
9864
|
-
obj[
|
9871
|
+
const remap = function(obj, a, b2) {
|
9872
|
+
if (a in obj && !(b2 in obj)) {
|
9873
|
+
obj[b2] = obj[a];
|
9865
9874
|
delete obj[a];
|
9866
9875
|
}
|
9867
9876
|
};
|
@@ -9940,8 +9949,8 @@ function shimGetUserMedia(window2, browserDetails) {
|
|
9940
9949
|
navigator2.getUserMedia = getUserMedia_.bind(navigator2);
|
9941
9950
|
if (navigator2.mediaDevices.getUserMedia) {
|
9942
9951
|
const origGetUserMedia = navigator2.mediaDevices.getUserMedia.bind(navigator2.mediaDevices);
|
9943
|
-
navigator2.mediaDevices.getUserMedia = function(
|
9944
|
-
return shimConstraints_(
|
9952
|
+
navigator2.mediaDevices.getUserMedia = function(cs2) {
|
9953
|
+
return shimConstraints_(cs2, (c2) => origGetUserMedia(c2).then((stream) => {
|
9945
9954
|
if (c2.audio && !stream.getAudioTracks().length || c2.video && !stream.getVideoTracks().length) {
|
9946
9955
|
stream.getTracks().forEach((track) => {
|
9947
9956
|
track.stop();
|
@@ -10603,9 +10612,9 @@ function shimGetUserMedia2(window2, browserDetails) {
|
|
10603
10612
|
navigator2.mediaDevices.getUserMedia(constraints).then(onSuccess, onError);
|
10604
10613
|
};
|
10605
10614
|
if (!(browserDetails.version > 55 && "autoGainControl" in navigator2.mediaDevices.getSupportedConstraints())) {
|
10606
|
-
const remap = function(obj, a,
|
10607
|
-
if (a in obj && !(
|
10608
|
-
obj[
|
10615
|
+
const remap = function(obj, a, b2) {
|
10616
|
+
if (a in obj && !(b2 in obj)) {
|
10617
|
+
obj[b2] = obj[a];
|
10609
10618
|
delete obj[a];
|
10610
10619
|
}
|
10611
10620
|
};
|
@@ -11667,64 +11676,64 @@ var adapter_core_default = adapter;
|
|
11667
11676
|
|
11668
11677
|
// ../hms-video-web/dist/index.js
|
11669
11678
|
var it = __toESM(require_lib());
|
11670
|
-
import { v4 as
|
11671
|
-
import { v4 as
|
11672
|
-
import { EventEmitter2 as ps } from "eventemitter2";
|
11679
|
+
import { v4 as ts } from "uuid";
|
11680
|
+
import { v4 as ps } from "uuid";
|
11673
11681
|
import { EventEmitter2 as hs } from "eventemitter2";
|
11674
|
-
import
|
11675
|
-
import
|
11682
|
+
import { EventEmitter2 as ms } from "eventemitter2";
|
11683
|
+
import Ss from "eventemitter2";
|
11684
|
+
import { v4 as Ts } from "uuid";
|
11676
11685
|
import { v4 as ys } from "uuid";
|
11677
|
-
var
|
11678
|
-
var
|
11679
|
-
var
|
11686
|
+
var Mr = Object.defineProperty;
|
11687
|
+
var Ar = Object.defineProperties;
|
11688
|
+
var Ir = Object.getOwnPropertyDescriptors;
|
11680
11689
|
var dt = Object.getOwnPropertySymbols;
|
11681
|
-
var
|
11682
|
-
var
|
11683
|
-
var
|
11684
|
-
var
|
11690
|
+
var Hi = Object.prototype.hasOwnProperty;
|
11691
|
+
var Di = Object.prototype.propertyIsEnumerable;
|
11692
|
+
var wi = (n2, e, t) => e in n2 ? Mr(n2, e, { enumerable: true, configurable: true, writable: true, value: t }) : n2[e] = t;
|
11693
|
+
var m = (n2, e) => {
|
11685
11694
|
for (var t in e || (e = {}))
|
11686
|
-
|
11695
|
+
Hi.call(e, t) && wi(n2, t, e[t]);
|
11687
11696
|
if (dt)
|
11688
11697
|
for (var t of dt(e))
|
11689
|
-
|
11698
|
+
Di.call(e, t) && wi(n2, t, e[t]);
|
11690
11699
|
return n2;
|
11691
11700
|
};
|
11692
|
-
var k = (n2, e) =>
|
11693
|
-
var
|
11701
|
+
var k = (n2, e) => Ar(n2, Ir(e));
|
11702
|
+
var si = (n2, e) => {
|
11694
11703
|
var t = {};
|
11695
11704
|
for (var i in n2)
|
11696
|
-
|
11705
|
+
Hi.call(n2, i) && e.indexOf(i) < 0 && (t[i] = n2[i]);
|
11697
11706
|
if (n2 != null && dt)
|
11698
11707
|
for (var i of dt(n2))
|
11699
|
-
e.indexOf(i) < 0 &&
|
11708
|
+
e.indexOf(i) < 0 && Di.call(n2, i) && (t[i] = n2[i]);
|
11700
11709
|
return t;
|
11701
11710
|
};
|
11702
|
-
var
|
11703
|
-
var
|
11704
|
-
|
11711
|
+
var Cr = (n2, e) => () => (e || n2((e = { exports: {} }).exports, e), e.exports);
|
11712
|
+
var li = Cr((wa, Ur2) => {
|
11713
|
+
Ur2.exports = { name: "@100mslive/hms-video", version: "0.9.22", license: "MIT", main: "dist/index.cjs.js", typings: "dist/index.d.ts", module: "dist/index.js", files: ["dist", "src"], engines: { node: ">=10" }, exports: { ".": { require: "./dist/index.cjs.js", import: "./dist/index.js", default: "./dist/index.js" } }, 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", test: "jest --maxWorkers=1", lint: "eslint -c ../../.eslintrc .", "lint:fix": "yarn lint --fix", prepare: "yarn build", size: "size-limit", analyze: "size-limit --why", format: "prettier --write src/**/*.ts" }, author: "100ms <tech-common@100ms.live>", 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" }, dependencies: { eventemitter2: "^6.4.7", "sdp-transform": "^2.14.1", "ua-parser-js": "^1.0.1", uuid: "^8.3.2", "webrtc-adapter": "^8.0.0" } };
|
11705
11714
|
});
|
11706
|
-
var
|
11707
|
-
var
|
11715
|
+
var Oi = "https://event.100ms.live/v2/client/report";
|
11716
|
+
var Ni = "https://event-nonprod.100ms.live/v2/client/report";
|
11708
11717
|
var Pe = class {
|
11709
11718
|
};
|
11710
|
-
Pe.makePeerId = () =>
|
11719
|
+
Pe.makePeerId = () => Lr();
|
11711
11720
|
var le = new import_ua_parser_js.UAParser();
|
11712
11721
|
var L = typeof window != "undefined";
|
11713
|
-
var
|
11714
|
-
var ue = typeof window == "undefined" && !((
|
11722
|
+
var Gi;
|
11723
|
+
var ue = typeof window == "undefined" && !((Gi = le.getBrowser().name) != null && Gi.toLowerCase().includes("electron"));
|
11715
11724
|
var pt = ((i) => (i.PROD = "prod", i.QA = "qa", i.DEV = "dev", i))(pt || {});
|
11716
|
-
var
|
11717
|
-
var
|
11718
|
-
function
|
11725
|
+
var wr = () => !ue;
|
11726
|
+
var ta = wr();
|
11727
|
+
function Dr() {
|
11719
11728
|
if (L && window) {
|
11720
11729
|
let n2 = window.location.hostname;
|
11721
11730
|
return n2 === "localhost" || n2 === "127.0.0.1" ? "LOCAL" : n2.includes("app.100ms.live") ? "HMS" : "CUSTOM";
|
11722
11731
|
}
|
11723
11732
|
return "CUSTOM";
|
11724
11733
|
}
|
11725
|
-
var
|
11726
|
-
var
|
11727
|
-
var
|
11734
|
+
var ke = Dr();
|
11735
|
+
var Or = ((l2) => (l2[l2.VERBOSE = 0] = "VERBOSE", l2[l2.DEBUG = 1] = "DEBUG", l2[l2.INFO = 2] = "INFO", l2[l2.WARN = 3] = "WARN", l2[l2.TIME = 4] = "TIME", l2[l2.TIMEEND = 5] = "TIMEEND", l2[l2.ERROR = 6] = "ERROR", l2[l2.NONE = 7] = "NONE", l2))(Or || {});
|
11736
|
+
var Nr = typeof window != "undefined" && typeof window.expect != "undefined";
|
11728
11737
|
var c = class {
|
11729
11738
|
static v(e, ...t) {
|
11730
11739
|
this.log(0, e, ...t);
|
@@ -11790,7 +11799,7 @@ var c = class {
|
|
11790
11799
|
}
|
11791
11800
|
}
|
11792
11801
|
};
|
11793
|
-
c.level =
|
11802
|
+
c.level = Nr ? 7 : 0;
|
11794
11803
|
var E = { WebSocketConnectionErrors: { FAILED_TO_CONNECT: 1e3, WEBSOCKET_CONNECTION_LOST: 1003, ABNORMAL_CLOSE: 1006 }, APIErrors: { SERVER_ERRORS: 2e3, INIT_CONFIG_NOT_AVAILABLE: 2002, ENDPOINT_UNREACHABLE: 2003, INVALID_TOKEN_FORMAT: 2004 }, TracksErrors: { GENERIC_TRACK: 3e3, CANT_ACCESS_CAPTURE_DEVICE: 3001, DEVICE_NOT_AVAILABLE: 3002, DEVICE_IN_USE: 3003, DEVICE_LOST_MIDWAY: 3004, NOTHING_TO_RETURN: 3005, INVALID_VIDEO_SETTINGS: 3006, CODEC_CHANGE_NOT_PERMITTED: 3007, AUTOPLAY_ERROR: 3008, OVER_CONSTRAINED: 3009, NO_AUDIO_DETECTED: 3010, SYSTEM_DENIED_PERMISSION: 3011, CURRENT_TAB_NOT_SHARED: 3012, AUDIO_PLAYBACK_ERROR: 3013, SELECTED_DEVICE_MISSING: 3014 }, WebrtcErrors: { CREATE_OFFER_FAILED: 4001, CREATE_ANSWER_FAILED: 4002, SET_LOCAL_DESCRIPTION_FAILED: 4003, SET_REMOTE_DESCRIPTION_FAILED: 4004, ICE_FAILURE: 4005, ICE_DISCONNECTED: 4006, STATS_FAILED: 4007 }, WebsocketMethodErrors: { SERVER_ERRORS: 5e3, ALREADY_JOINED: 5001, CANNOT_JOIN_PREVIEW_IN_PROGRESS: 5002 }, GenericErrors: { NOT_CONNECTED: 6e3, SIGNALLING: 6001, UNKNOWN: 6002, NOT_READY: 6003, JSON_PARSING_FAILED: 6004, TRACK_METADATA_MISSING: 6005, RTC_TRACK_MISSING: 6006, PEER_METADATA_MISSING: 6007, INVALID_ROLE: 6008, PREVIEW_IN_PROGRESS: 6009, MISSING_MEDIADEVICES: 6010, MISSING_RTCPEERCONNECTION: 6011, LOCAL_STORAGE_ACCESS_DENIED: 6012 }, PlaylistErrors: { NO_ENTRY_TO_PLAY: 8001, NO_ENTRY_IS_PLAYING: 8002 } };
|
11795
11804
|
var S = class n extends Error {
|
11796
11805
|
constructor(t, i, r, s, a, o = false) {
|
@@ -11821,7 +11830,7 @@ var S = class n extends Error {
|
|
11821
11830
|
}`;
|
11822
11831
|
}
|
11823
11832
|
};
|
11824
|
-
var
|
11833
|
+
var Fr = ["join", "offer", "answer", "trickle", "on-error", "JOIN"];
|
11825
11834
|
var h = { WebSocketConnectionErrors: { FailedToConnect(n2, e = "") {
|
11826
11835
|
return new S(E.WebSocketConnectionErrors.FAILED_TO_CONNECT, "WebsocketFailedToConnect", n2, `[WS]: ${e}`, `[WS]: ${e}`);
|
11827
11836
|
}, WebSocketConnectionLost(n2, e = "") {
|
@@ -11881,7 +11890,7 @@ var h = { WebSocketConnectionErrors: { FailedToConnect(n2, e = "") {
|
|
11881
11890
|
}, StatsFailed(n2, e = "") {
|
11882
11891
|
return new S(E.WebrtcErrors.STATS_FAILED, "StatsFailed", n2, `Failed to WebRTC get stats - ${e}`, e);
|
11883
11892
|
} }, WebsocketMethodErrors: { ServerErrors(n2, e, t) {
|
11884
|
-
return new S(n2, "ServerErrors", e, t, t,
|
11893
|
+
return new S(n2, "ServerErrors", e, t, t, Fr.includes(e));
|
11885
11894
|
}, AlreadyJoined(n2, e = "") {
|
11886
11895
|
return new S(E.WebsocketMethodErrors.ALREADY_JOINED, "AlreadyJoined", n2, "[JOIN]: You have already joined this room.", e);
|
11887
11896
|
}, CannotJoinPreviewInProgress(n2, e = "") {
|
@@ -11929,7 +11938,7 @@ var h = { WebSocketConnectionErrors: { FailedToConnect(n2, e = "") {
|
|
11929
11938
|
}, NoEntryPlaying(n2, e) {
|
11930
11939
|
return new S(E.PlaylistErrors.NO_ENTRY_IS_PLAYING, "NoEntryIsPlaying", n2, "No entry is playing at this time", e);
|
11931
11940
|
} } };
|
11932
|
-
var
|
11941
|
+
var oi = class {
|
11933
11942
|
constructor() {
|
11934
11943
|
this.valuesMap = /* @__PURE__ */ new Map();
|
11935
11944
|
}
|
@@ -11954,9 +11963,9 @@ var ni = class {
|
|
11954
11963
|
return this.valuesMap.size;
|
11955
11964
|
}
|
11956
11965
|
};
|
11957
|
-
var
|
11966
|
+
var Vi = () => {
|
11958
11967
|
try {
|
11959
|
-
L && !localStorage && (window.localStorage = new
|
11968
|
+
L && !localStorage && (window.localStorage = new oi());
|
11960
11969
|
} catch (n2) {
|
11961
11970
|
c.e("Error initialising localStorage", h.GenericErrors.LocalStorageAccessDenied());
|
11962
11971
|
}
|
@@ -11968,7 +11977,7 @@ var V = class {
|
|
11968
11977
|
}
|
11969
11978
|
getStorage() {
|
11970
11979
|
try {
|
11971
|
-
return L && !this.storage && (
|
11980
|
+
return L && !this.storage && (Vi(), this.storage = window.localStorage), this.storage;
|
11972
11981
|
} catch (e) {
|
11973
11982
|
return c.e("Error initialising localStorage", h.GenericErrors.LocalStorageAccessDenied()), null;
|
11974
11983
|
}
|
@@ -11988,116 +11997,116 @@ var V = class {
|
|
11988
11997
|
(e = this.getStorage()) == null || e.removeItem(this.key);
|
11989
11998
|
}
|
11990
11999
|
};
|
11991
|
-
var
|
12000
|
+
var Bi = () => {
|
11992
12001
|
let n2, e = new V("hms-analytics-deviceId"), t = e.get();
|
11993
|
-
return t ? n2 = t : (n2 =
|
12002
|
+
return t ? n2 = t : (n2 = Gr(), e.set(n2)), n2;
|
11994
12003
|
};
|
11995
12004
|
function U(n2) {
|
11996
12005
|
return n2 != null;
|
11997
12006
|
}
|
11998
|
-
var
|
12007
|
+
var Wi = li().version;
|
11999
12008
|
function xe(n2 = "prod", e) {
|
12000
|
-
let t = "web", i =
|
12009
|
+
let t = "web", i = ke !== "LOCAL" && n2 === "prod" ? "prod" : "debug";
|
12001
12010
|
if (ue)
|
12002
|
-
return
|
12003
|
-
let r = le.getOS(), s = le.getDevice(), a = le.getBrowser(), o =
|
12004
|
-
return s.type && (u2 = `${
|
12011
|
+
return qi({ os: "web_nodejs", os_version: process.version, sdk: t, sdk_version: Wi, env: i, domain: ke, is_prebuilt: !!(e != null && e.isPrebuilt), framework: "node", framework_version: process.version, framework_sdk_version: e == null ? void 0 : e.sdkVersion });
|
12012
|
+
let r = le.getOS(), s = le.getDevice(), a = le.getBrowser(), o = ui(`web_${r.name}`), l2 = r.version || "", p = ui(`${a.name}_${a.version}`), u2 = p;
|
12013
|
+
return s.type && (u2 = `${ui(`${s.vendor}_${s.type}`)}/${p}`), qi({ os: o, os_version: l2, sdk: t, sdk_version: Wi, device_model: u2, env: i, domain: ke, is_prebuilt: !!(e != null && e.isPrebuilt), framework: e == null ? void 0 : e.type, framework_version: e == null ? void 0 : e.version, framework_sdk_version: e == null ? void 0 : e.sdkVersion });
|
12005
12014
|
}
|
12006
|
-
function
|
12015
|
+
function ui(n2) {
|
12007
12016
|
return n2.replace(/ /g, "_");
|
12008
12017
|
}
|
12009
|
-
var
|
12010
|
-
var
|
12018
|
+
var qi = (n2, e = ",") => Object.keys(n2).filter((t) => U(n2[t])).map((t) => `${t}:${n2[t]}`).join(e);
|
12019
|
+
var M = class {
|
12011
12020
|
constructor({ name: e, level: t, properties: i, includesPII: r, timestamp: s }) {
|
12012
12021
|
this.metadata = { peer: {}, userAgent: xe() };
|
12013
|
-
this.name = e, this.level = t, this.includesPII = r || false, this.properties = i || {}, this.timestamp = s || (/* @__PURE__ */ new Date()).getTime(), this.event_id =
|
12022
|
+
this.name = e, this.level = t, this.includesPII = r || false, this.properties = i || {}, this.timestamp = s || (/* @__PURE__ */ new Date()).getTime(), this.event_id = Vr(), this.device_id = Bi();
|
12014
12023
|
}
|
12015
12024
|
toSignalParams() {
|
12016
|
-
return { name: this.name, info: k(
|
12025
|
+
return { name: this.name, info: k(m({}, this.properties), { timestamp: this.timestamp, domain: ke }), timestamp: (/* @__PURE__ */ new Date()).getTime() };
|
12017
12026
|
}
|
12018
12027
|
};
|
12019
12028
|
var P = class {
|
12020
12029
|
static connect(e, t, i = /* @__PURE__ */ new Date(), r = /* @__PURE__ */ new Date(), s) {
|
12021
|
-
let a = this.eventNameFor("connect", e === void 0), o = e ? 2 : 1, l2 = this.getPropertiesWithError(k(
|
12022
|
-
return new
|
12030
|
+
let a = this.eventNameFor("connect", e === void 0), o = e ? 2 : 1, l2 = this.getPropertiesWithError(k(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);
|
12031
|
+
return new M({ name: a, level: o, properties: l2 });
|
12023
12032
|
}
|
12024
12033
|
static disconnect(e, t) {
|
12025
12034
|
let i = "disconnected", r = e ? 2 : 1, s = this.getPropertiesWithError(t, e);
|
12026
|
-
return new
|
12035
|
+
return new M({ name: i, level: r, properties: s });
|
12027
12036
|
}
|
12028
12037
|
static preview(i) {
|
12029
|
-
var r = i, { error: e } = r, t =
|
12038
|
+
var r = i, { error: e } = r, t = si(r, ["error"]);
|
12030
12039
|
let s = this.eventNameFor("preview", e === void 0), a = e ? 2 : 1, o = this.getPropertiesWithError(t, e);
|
12031
|
-
return new
|
12040
|
+
return new M({ name: s, level: a, properties: o });
|
12032
12041
|
}
|
12033
12042
|
static join(i) {
|
12034
|
-
var r = i, { error: e } = r, t =
|
12035
|
-
let s = this.eventNameFor("join", e === void 0), a = e ? 2 : 1, o = this.getPropertiesWithError(k(
|
12036
|
-
return new
|
12043
|
+
var r = i, { error: e } = r, t = si(r, ["error"]);
|
12044
|
+
let s = this.eventNameFor("join", e === void 0), a = e ? 2 : 1, o = this.getPropertiesWithError(k(m({}, t), { is_preview_called: !!t.is_preview_called }), e);
|
12045
|
+
return new M({ name: s, level: a, properties: o });
|
12037
12046
|
}
|
12038
12047
|
static publish({ devices: e, settings: t, error: i }) {
|
12039
12048
|
let r = this.eventNameFor("publish", i === void 0), s = i ? 2 : 1, a = this.getPropertiesWithError({ devices: e, audio: t == null ? void 0 : t.audio, video: t == null ? void 0 : t.video }, i);
|
12040
|
-
return new
|
12049
|
+
return new M({ name: r, level: s, properties: a });
|
12041
12050
|
}
|
12042
12051
|
static hlsPlayerError(e) {
|
12043
|
-
return new
|
12052
|
+
return new M({ name: "hlsPlayerError", level: 2, properties: this.getErrorProperties(e) });
|
12044
12053
|
}
|
12045
12054
|
static subscribeFail(e) {
|
12046
12055
|
let t = this.eventNameFor("subscribe", false), i = 2, r = this.getErrorProperties(e);
|
12047
|
-
return new
|
12056
|
+
return new M({ name: t, level: i, properties: r });
|
12048
12057
|
}
|
12049
12058
|
static leave() {
|
12050
|
-
return new
|
12059
|
+
return new M({ name: "leave", level: 1 });
|
12051
12060
|
}
|
12052
12061
|
static autoplayError() {
|
12053
|
-
return new
|
12062
|
+
return new M({ name: "autoplayError", level: 2 });
|
12054
12063
|
}
|
12055
12064
|
static audioPlaybackError(e) {
|
12056
|
-
return new
|
12065
|
+
return new M({ name: "audioPlaybackError", level: 2, properties: this.getErrorProperties(e) });
|
12057
12066
|
}
|
12058
12067
|
static deviceChange({ selection: e, type: t, devices: i, error: r }) {
|
12059
12068
|
let s = this.eventNameFor(r ? "publish" : `device.${t}`, r === void 0), a = r ? 2 : 1, o = this.getPropertiesWithError({ selection: e, devices: i }, r);
|
12060
|
-
return new
|
12069
|
+
return new M({ name: s, level: a, properties: o });
|
12061
12070
|
}
|
12062
12071
|
static performance(e) {
|
12063
12072
|
let t = "perf.stats", i = 1, r = e.toAnalyticsProperties();
|
12064
|
-
return new
|
12073
|
+
return new M({ name: t, level: i, properties: r });
|
12065
12074
|
}
|
12066
12075
|
static rtcStats(e) {
|
12067
12076
|
let t = "rtc.stats", i = 1, r = e.toAnalyticsProperties();
|
12068
|
-
return new
|
12077
|
+
return new M({ name: t, level: i, properties: r });
|
12069
12078
|
}
|
12070
12079
|
static rtcStatsFailed(e) {
|
12071
12080
|
let t = "rtc.stats.failed", i = 2;
|
12072
|
-
return new
|
12081
|
+
return new M({ name: t, level: i, properties: this.getErrorProperties(e) });
|
12073
12082
|
}
|
12074
12083
|
static degradationStats(e, t) {
|
12075
12084
|
let i = "video.degradation.stats", r = 1, s = { degradedAt: e.degradedAt, trackId: e.trackId };
|
12076
12085
|
if (!t && e.degradedAt instanceof Date) {
|
12077
12086
|
let a = /* @__PURE__ */ new Date(), o = a.valueOf() - e.degradedAt.valueOf();
|
12078
|
-
s = k(
|
12087
|
+
s = k(m({}, s), { duration: o, restoredAt: a });
|
12079
12088
|
}
|
12080
|
-
return new
|
12089
|
+
return new M({ name: i, level: r, properties: s });
|
12081
12090
|
}
|
12082
12091
|
static audioDetectionFail(e, t) {
|
12083
12092
|
let i = this.getPropertiesWithError({ device: t }, e), r = 2, s = "audiopresence.failed";
|
12084
|
-
return new
|
12093
|
+
return new M({ name: s, level: r, properties: i });
|
12085
12094
|
}
|
12086
12095
|
static previewNetworkQuality(e) {
|
12087
|
-
return new
|
12096
|
+
return new M({ name: "perf.networkquality.preview", level: e.error ? 2 : 1, properties: e });
|
12088
12097
|
}
|
12089
12098
|
static publishStats(e) {
|
12090
|
-
return new
|
12099
|
+
return new M({ name: "publisher.stats", level: 1, properties: e });
|
12091
12100
|
}
|
12092
12101
|
static subscribeStats(e) {
|
12093
|
-
return new
|
12102
|
+
return new M({ name: "subscriber.stats", level: 1, properties: e });
|
12094
12103
|
}
|
12095
12104
|
static eventNameFor(e, t) {
|
12096
12105
|
return `${e}.${t ? "success" : "failed"}`;
|
12097
12106
|
}
|
12098
12107
|
static getPropertiesWithError(e, t) {
|
12099
12108
|
let i = this.getErrorProperties(t);
|
12100
|
-
return e =
|
12109
|
+
return e = m(m({}, i), e), e;
|
12101
12110
|
}
|
12102
12111
|
static getErrorProperties(e) {
|
12103
12112
|
return e ? e instanceof S ? e.toAnalyticsProperties() : { error_name: e.name, error_message: e.message, error_description: e.cause } : {};
|
@@ -12105,7 +12114,7 @@ var P = class {
|
|
12105
12114
|
};
|
12106
12115
|
P.KEY_REQUESTED_AT = "requested_at", P.KEY_RESPONDED_AT = "responded_at";
|
12107
12116
|
var he = ((t) => (t.AUDIO = "audio", t.VIDEO = "video", t))(he || {});
|
12108
|
-
var
|
12117
|
+
var pi = class {
|
12109
12118
|
constructor() {
|
12110
12119
|
this.storage = new V("hms-device-selection");
|
12111
12120
|
this.remember = false;
|
@@ -12139,8 +12148,8 @@ var ui = class {
|
|
12139
12148
|
return e.deviceId === t.deviceId && (e.groupId === t.groupId || !e.groupId);
|
12140
12149
|
}
|
12141
12150
|
};
|
12142
|
-
var D = new
|
12143
|
-
var
|
12151
|
+
var D = new pi();
|
12152
|
+
var ji = ((t) => (t.TRANSFORM = "TRANSFORM", t.ANALYZE = "ANALYZE", t))(ji || {});
|
12144
12153
|
var gt = ((t) => (t.PLATFORM_NOT_SUPPORTED = "PLATFORM_NOT_SUPPORTED", t.DEVICE_NOT_SUPPORTED = "DEVICE_NOT_SUPPORTED", t))(gt || {});
|
12145
12154
|
function ft(n2, e = 300) {
|
12146
12155
|
let t;
|
@@ -12152,20 +12161,20 @@ function ft(n2, e = 300) {
|
|
12152
12161
|
}, e);
|
12153
12162
|
};
|
12154
12163
|
}
|
12155
|
-
var
|
12164
|
+
var zi = ((a) => (a.RECORDING_STATE_UPDATED = "RECORDING_STATE_UPDATED", a.BROWSER_RECORDING_STATE_UPDATED = "BROWSER_RECORDING_STATE_UPDATED", a.SERVER_RECORDING_STATE_UPDATED = "SERVER_RECORDING_STATE_UPDATED", a.RTMP_STREAMING_STATE_UPDATED = "RTMP_STREAMING_STATE_UPDATED", a.HLS_STREAMING_STATE_UPDATED = "HLS_STREAMING_STATE_UPDATED", a.ROOM_PEER_COUNT_UPDATED = "ROOM_PEER_COUNT_UPDATED", a))(zi || {});
|
12156
12165
|
var Ge = ((f) => (f[f.PEER_JOINED = 0] = "PEER_JOINED", f[f.PEER_LEFT = 1] = "PEER_LEFT", f[f.AUDIO_TOGGLED = 2] = "AUDIO_TOGGLED", f[f.VIDEO_TOGGLED = 3] = "VIDEO_TOGGLED", f[f.BECAME_DOMINANT_SPEAKER = 4] = "BECAME_DOMINANT_SPEAKER", f[f.RESIGNED_DOMINANT_SPEAKER = 5] = "RESIGNED_DOMINANT_SPEAKER", f[f.STARTED_SPEAKING = 6] = "STARTED_SPEAKING", f[f.STOPPED_SPEAKING = 7] = "STOPPED_SPEAKING", f[f.ROLE_UPDATED = 8] = "ROLE_UPDATED", f[f.PEER_LIST = 9] = "PEER_LIST", f[f.NAME_UPDATED = 10] = "NAME_UPDATED", f[f.METADATA_UPDATED = 11] = "METADATA_UPDATED", f[f.HAND_RAISE_CHANGED = 12] = "HAND_RAISE_CHANGED", f[f.PEER_REMOVED = 13] = "PEER_REMOVED", f[f.PEER_ADDED = 14] = "PEER_ADDED", f))(Ge || {});
|
12157
12166
|
var se = ((o) => (o[o.TRACK_ADDED = 0] = "TRACK_ADDED", o[o.TRACK_REMOVED = 1] = "TRACK_REMOVED", o[o.TRACK_MUTED = 2] = "TRACK_MUTED", o[o.TRACK_UNMUTED = 3] = "TRACK_UNMUTED", o[o.TRACK_DESCRIPTION_CHANGED = 4] = "TRACK_DESCRIPTION_CHANGED", o[o.TRACK_DEGRADED = 5] = "TRACK_DEGRADED", o[o.TRACK_RESTORED = 6] = "TRACK_RESTORED", o))(se || {});
|
12158
|
-
var
|
12159
|
-
var
|
12160
|
-
var
|
12167
|
+
var hi = ((r) => (r[r.POLL_CREATED = 0] = "POLL_CREATED", r[r.POLL_STARTED = 1] = "POLL_STARTED", r[r.POLL_STOPPED = 2] = "POLL_STOPPED", r[r.POLL_STATS_UPDATED = 3] = "POLL_STATS_UPDATED", r))(hi || {});
|
12168
|
+
var Yr = ((o) => (o.NONE = "none", o.INITIALISED = "initialised", o.STARTED = "started", o.PAUSED = "paused", o.RESUMED = "resumed", o.STOPPED = "stopped", o.FAILED = "failed", o))(Yr || {});
|
12169
|
+
var Xr = ((s) => (s.NONE = "none", s.INITIALISED = "initialised", s.STARTED = "started", s.STOPPED = "stopped", s.FAILED = "failed", s))(Xr || {});
|
12161
12170
|
var Me = ((r) => (r.NONE = "none", r.LOW = "low", r.MEDIUM = "medium", r.HIGH = "high", r))(Me || {});
|
12162
|
-
var
|
12163
|
-
var
|
12164
|
-
var
|
12165
|
-
var
|
12166
|
-
var
|
12167
|
-
var
|
12168
|
-
var
|
12171
|
+
var Yi = ((i) => (i.VP8 = "vp8", i.VP9 = "vp9", i.H264 = "h264", i))(Yi || {});
|
12172
|
+
var Xi = ((e) => (e.OPUS = "opus", e))(Xi || {});
|
12173
|
+
var Zi = ((r) => (r.USER = "user", r.ENVIRONMENT = "environment", r.LEFT = "left", r.RIGHT = "right", r))(Zi || {});
|
12174
|
+
var Zr = ((i) => (i.videoInput = "videoInput", i.audioInput = "audioInput", i.audioOutput = "audioOutput", i))(Zr || {});
|
12175
|
+
var gi = ((t) => (t.audio = "audio", t.video = "video", t))(gi || {});
|
12176
|
+
var er = ((r) => (r.SINGLE_CHOICE = "single-choice", r.MULTIPLE_CHOICE = "multiple-choice", r.SHORT_ANSWER = "short-answer", r.LONG_ANSWER = "long-answer", r))(er || {});
|
12177
|
+
var Si = class {
|
12169
12178
|
constructor() {
|
12170
12179
|
this.TAG = "[HMSIntersectionObserverWrapper]";
|
12171
12180
|
this.listeners = /* @__PURE__ */ new WeakMap();
|
@@ -12192,8 +12201,8 @@ var gi = class {
|
|
12192
12201
|
return e || c.w(this.TAG, "IntersectionObserver is not supported, fallback will be used instead"), e;
|
12193
12202
|
}
|
12194
12203
|
};
|
12195
|
-
var
|
12196
|
-
var
|
12204
|
+
var rr = new Si();
|
12205
|
+
var Ti = class {
|
12197
12206
|
constructor() {
|
12198
12207
|
this.TAG = "[HMSResizeObserverWrapper]";
|
12199
12208
|
this.listeners = /* @__PURE__ */ new WeakMap();
|
@@ -12220,13 +12229,13 @@ var Si = class {
|
|
12220
12229
|
return e || c.w(this.TAG, "Resize Observer is not supported"), e;
|
12221
12230
|
}
|
12222
12231
|
};
|
12223
|
-
var
|
12224
|
-
var
|
12225
|
-
var
|
12226
|
-
var
|
12232
|
+
var sr = new Ti();
|
12233
|
+
var vi = ((t) => (t.TRANSFORM = "TRANSFORM", t.ANALYZE = "ANALYZE", t))(vi || {});
|
12234
|
+
var fi = ((t) => (t["2D"] = "2d", t.WEBGL = "webgl", t.WEBGL2 = "webgl2", t))(fi || {});
|
12235
|
+
var ds = li().version;
|
12227
12236
|
c.d("adapter", `${adapter_core_default.browserDetails.browser} v${adapter_core_default.browserDetails.version}`);
|
12228
|
-
c.d("sdk version",
|
12229
|
-
var
|
12237
|
+
c.d("sdk version", ds);
|
12238
|
+
var Ii = class {
|
12230
12239
|
constructor() {
|
12231
12240
|
this.TAG = "[HTTPAnalyticsTransport]";
|
12232
12241
|
this.failedEvents = new V("client-events");
|
@@ -12245,7 +12254,7 @@ var Ai = class {
|
|
12245
12254
|
this.addEventToStorage(e);
|
12246
12255
|
return;
|
12247
12256
|
}
|
12248
|
-
let t = { event: e.name, payload: e.properties, event_id: String(e.timestamp), peer: e.metadata.peer, timestamp: e.timestamp, device_id: e.device_id, cluster: { websocket_url: this.websocketURL } }, i = this.env === "prod" ?
|
12257
|
+
let t = { event: e.name, payload: e.properties, event_id: String(e.timestamp), peer: e.metadata.peer, timestamp: e.timestamp, device_id: e.device_id, cluster: { websocket_url: this.websocketURL } }, i = this.env === "prod" ? Oi : Ni;
|
12249
12258
|
fetch(i, { method: "POST", headers: { "Content-Type": "application/json", Authorization: `Bearer ${e.metadata.token}`, user_agent_v2: e.metadata.userAgent }, body: JSON.stringify(t) }).then((r) => {
|
12250
12259
|
if (r.status === 401) {
|
12251
12260
|
this.removeFromStorage(e);
|
@@ -12271,7 +12280,7 @@ var Ai = class {
|
|
12271
12280
|
i > -1 && (t.splice(i, 1), this.failedEvents.set(t));
|
12272
12281
|
}
|
12273
12282
|
};
|
12274
|
-
var z = new
|
12283
|
+
var z = new Ii();
|
12275
12284
|
var w = ((s) => (s[s.ConnectFailed = 0] = "ConnectFailed", s[s.SignalDisconnect = 1] = "SignalDisconnect", s[s.JoinWSMessageFailed = 2] = "JoinWSMessageFailed", s[s.PublishIceConnectionFailed = 3] = "PublishIceConnectionFailed", s[s.SubscribeIceConnectionFailed = 4] = "SubscribeIceConnectionFailed", s))(w || {});
|
12276
12285
|
var Le = ((o) => (o.Disconnected = "Disconnected", o.Connecting = "Connecting", o.Joined = "Joined", o.Preview = "Preview", o.Failed = "Failed", o.Reconnecting = "Reconnecting", o.Leaving = "Leaving", o))(Le || {});
|
12277
12286
|
var Te = ((t) => (t[t.Publish = 0] = "Publish", t[t.Subscribe = 1] = "Subscribe", t))(Te || {});
|
@@ -12334,12 +12343,12 @@ var formatTime = (timeInSeconds) => {
|
|
12334
12343
|
const hour = hours !== 0 ? `${hours < 10 ? "0" : ""}${hours}:` : "";
|
12335
12344
|
return `${hour}${minutes < 10 ? "0" : ""}${minutes}:${seconds < 10 ? "0" : ""}${seconds}`;
|
12336
12345
|
};
|
12337
|
-
var compareArrays = (a,
|
12338
|
-
if (a.length !==
|
12346
|
+
var compareArrays = (a, b2) => {
|
12347
|
+
if (a.length !== b2.length)
|
12339
12348
|
return false;
|
12340
12349
|
else {
|
12341
12350
|
for (var i = 0; i < a.length; i++) {
|
12342
|
-
if (a[i] !==
|
12351
|
+
if (a[i] !== b2[i]) {
|
12343
12352
|
return false;
|
12344
12353
|
}
|
12345
12354
|
}
|
@@ -12747,7 +12756,7 @@ var RecordingStatus = () => {
|
|
12747
12756
|
};
|
12748
12757
|
var RecordingPauseStatus = () => {
|
12749
12758
|
const recording = useHMSStore24(selectRecordingState);
|
12750
|
-
if (recording.hls && recording.hls.state ===
|
12759
|
+
if (recording.hls && recording.hls.state === Yr.PAUSED) {
|
12751
12760
|
return /* @__PURE__ */ React54.createElement(
|
12752
12761
|
Tooltip,
|
12753
12762
|
{
|
@@ -14641,7 +14650,7 @@ function HLSFailureModal() {
|
|
14641
14650
|
init_define_process_env();
|
14642
14651
|
import React117, { useEffect as useEffect30 } from "react";
|
14643
14652
|
import {
|
14644
|
-
selectLocalPeerName as
|
14653
|
+
selectLocalPeerName as selectLocalPeerName3,
|
14645
14654
|
selectLocalPeerRoleName as selectLocalPeerRoleName5,
|
14646
14655
|
selectRoleChangeRequest,
|
14647
14656
|
useCustomEvent as useCustomEvent3,
|
@@ -14656,7 +14665,7 @@ import { useMeasure as useMeasure4, useMedia as useMedia20 } from "react-use";
|
|
14656
14665
|
import {
|
14657
14666
|
HMSRoomState as HMSRoomState5,
|
14658
14667
|
selectIsLocalVideoEnabled as selectIsLocalVideoEnabled6,
|
14659
|
-
selectLocalPeer as
|
14668
|
+
selectLocalPeer as selectLocalPeer5,
|
14660
14669
|
selectRoomState as selectRoomState5,
|
14661
14670
|
selectVideoTrackByID as selectVideoTrackByID5,
|
14662
14671
|
useAVToggle as useAVToggle4,
|
@@ -14917,10 +14926,10 @@ var AddMenu = () => {
|
|
14917
14926
|
};
|
14918
14927
|
var PrevMenu = () => {
|
14919
14928
|
var _a7;
|
14920
|
-
const polls = (_a7 = useHMSStore36(selectPolls2)) == null ? void 0 : _a7.filter((poll) => poll.state === "started" || poll.state === "stopped").sort((a,
|
14929
|
+
const polls = (_a7 = useHMSStore36(selectPolls2)) == null ? void 0 : _a7.filter((poll) => poll.state === "started" || poll.state === "stopped").sort((a, b2) => {
|
14921
14930
|
var _a8, _b7;
|
14922
|
-
return (((_a8 =
|
14923
|
-
}).sort((a,
|
14931
|
+
return (((_a8 = b2.createdAt) == null ? void 0 : _a8.getTime()) || 0) - (((_b7 = a.createdAt) == null ? void 0 : _b7.getTime()) || 0);
|
14932
|
+
}).sort((a, b2) => (b2.state === "started" ? 1 : 0) - (a.state === "started" ? 1 : 0));
|
14924
14933
|
return (polls == null ? void 0 : polls.length) ? /* @__PURE__ */ React79.createElement(
|
14925
14934
|
Flex,
|
14926
14935
|
{
|
@@ -15059,7 +15068,7 @@ var VoteCount = ({ isQuiz, voteCount, isCorrectAnswer }) => {
|
|
15059
15068
|
}
|
15060
15069
|
},
|
15061
15070
|
isCorrectAnswer ? "Correct" : "Incorrect"
|
15062
|
-
), /* @__PURE__ */ React82.createElement(Text, { variant: "sm", css: { color: "$on_surface_medium" } }, voteCount, "\xA0", voteCount === 1 ? "vote" : "votes"));
|
15071
|
+
), voteCount ? /* @__PURE__ */ React82.createElement(Text, { variant: "sm", css: { color: "$on_surface_medium" } }, voteCount, "\xA0", voteCount === 1 ? "vote" : "votes") : null);
|
15063
15072
|
};
|
15064
15073
|
|
15065
15074
|
// src/Prebuilt/components/Polls/common/VoteProgress.jsx
|
@@ -15564,7 +15573,7 @@ var QuestionCard = ({ question, onSave, index, length, removeQuestion, isQuiz, c
|
|
15564
15573
|
init_define_process_env();
|
15565
15574
|
import React92 from "react";
|
15566
15575
|
import {
|
15567
|
-
selectLocalPeerID as
|
15576
|
+
selectLocalPeerID as selectLocalPeerID8,
|
15568
15577
|
selectPeerNameByID,
|
15569
15578
|
selectPollByID as selectPollByID2,
|
15570
15579
|
useHMSActions as useHMSActions27,
|
@@ -15579,7 +15588,7 @@ import React90 from "react";
|
|
15579
15588
|
// src/Prebuilt/components/Polls/Voting/QuestionCard.jsx
|
15580
15589
|
init_define_process_env();
|
15581
15590
|
import React89, { useCallback as useCallback21, useMemo as useMemo7, useState as useState35 } from "react";
|
15582
|
-
import {
|
15591
|
+
import { selectLocalPeer, selectLocalPeerRoleName as selectLocalPeerRoleName3, useHMSActions as useHMSActions26, useHMSStore as useHMSStore38 } from "@100mslive/react-sdk";
|
15583
15592
|
import { ChevronLeftIcon as ChevronLeftIcon4, ChevronRightIcon as ChevronRightIcon3 } from "@100mslive/react-icons";
|
15584
15593
|
var TextArea = styled("textarea", {
|
15585
15594
|
backgroundColor: "$surface_brighter",
|
@@ -15610,12 +15619,14 @@ var QuestionCard2 = ({
|
|
15610
15619
|
rolesThatCanViewResponses
|
15611
15620
|
}) => {
|
15612
15621
|
const actions = useHMSActions26();
|
15613
|
-
const
|
15614
|
-
const localPeerResponse = responses == null ? void 0 : responses.find(
|
15615
|
-
|
15616
|
-
|
15617
|
-
|
15618
|
-
|
15622
|
+
const localPeer = useHMSStore38(selectLocalPeer);
|
15623
|
+
const localPeerResponse = responses == null ? void 0 : responses.find(
|
15624
|
+
(response) => {
|
15625
|
+
var _a7, _b7;
|
15626
|
+
return ((_a7 = response.peer) == null ? void 0 : _a7.peerid) === (localPeer == null ? void 0 : localPeer.id) || ((_b7 = response.peer) == null ? void 0 : _b7.userid) === (localPeer == null ? void 0 : localPeer.customerUserId);
|
15627
|
+
}
|
15628
|
+
);
|
15629
|
+
const isLocalPeerCreator = (localPeer == null ? void 0 : localPeer.id) === startedBy;
|
15619
15630
|
const localPeerRoleName = useHMSStore38(selectLocalPeerRoleName3);
|
15620
15631
|
const roleCanViewResponse = !rolesThatCanViewResponses || rolesThatCanViewResponses.length === 0 || rolesThatCanViewResponses.includes(localPeerRoleName || "");
|
15621
15632
|
const showVoteCount = roleCanViewResponse && (localPeerResponse || isLocalPeerCreator && pollState === "stopped");
|
@@ -15808,8 +15819,8 @@ init_define_process_env();
|
|
15808
15819
|
import React91, { useState as useState36 } from "react";
|
15809
15820
|
var TimedView = ({ poll }) => {
|
15810
15821
|
var _a7, _b7;
|
15811
|
-
const [currentIndex, setCurrentIndex] = useState36(
|
15812
|
-
const activeQuestion = (_a7 = poll.questions) == null ? void 0 : _a7
|
15822
|
+
const [currentIndex, setCurrentIndex] = useState36(1);
|
15823
|
+
const activeQuestion = (_a7 = poll.questions) == null ? void 0 : _a7.find((question) => question.index === currentIndex);
|
15813
15824
|
if (!activeQuestion) {
|
15814
15825
|
return null;
|
15815
15826
|
}
|
@@ -15842,7 +15853,7 @@ var Voting = ({ id, toggleVoting }) => {
|
|
15842
15853
|
const actions = useHMSActions27();
|
15843
15854
|
const poll = useHMSStore39(selectPollByID2(id));
|
15844
15855
|
const pollCreatorName = useHMSStore39(selectPeerNameByID(poll == null ? void 0 : poll.createdBy));
|
15845
|
-
const isLocalPeerCreator = useHMSStore39(
|
15856
|
+
const isLocalPeerCreator = useHMSStore39(selectLocalPeerID8) === (poll == null ? void 0 : poll.createdBy);
|
15846
15857
|
const { setPollView } = usePollViewState();
|
15847
15858
|
if (!poll) {
|
15848
15859
|
return null;
|
@@ -15928,8 +15939,8 @@ init_define_process_env();
|
|
15928
15939
|
|
15929
15940
|
// ../../node_modules/reselect/es/index.js
|
15930
15941
|
init_define_process_env();
|
15931
|
-
function defaultEqualityCheck(a,
|
15932
|
-
return a ===
|
15942
|
+
function defaultEqualityCheck(a, b2) {
|
15943
|
+
return a === b2;
|
15933
15944
|
}
|
15934
15945
|
function areArgumentsShallowlyEqual(equalityCheck, prev, next) {
|
15935
15946
|
if (prev === null || next === null || prev.length !== next.length) {
|
@@ -16007,12 +16018,12 @@ var createSelector = createSelectorCreator(defaultMemoize);
|
|
16007
16018
|
import { EventEmitter2 as Ps } from "eventemitter2";
|
16008
16019
|
var Kt = (s, e) => () => (e || s((e = { exports: {} }).exports, e), e.exports);
|
16009
16020
|
var Nt = Kt(($n, bs) => {
|
16010
|
-
bs.exports = { version: "0.10.22
|
16021
|
+
bs.exports = { version: "0.10.22", license: "MIT", 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" } }, 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", sideEffects: false, dependencies: { "@100mslive/hms-video": "0.9.22", eventemitter2: "^6.4.7", immer: "^9.0.6", reselect: "4.0.0", zustand: "3.5.7" }, devDependencies: { "jsdom-worker": "^0.3.0", "ts-node": "^10.4.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"] };
|
16011
16022
|
});
|
16012
16023
|
var Ie = ((n2) => (n2.Disconnected = "Disconnected", n2.Preview = "Preview", n2.Connecting = "Connecting", n2.Connected = "Connected", n2.Reconnecting = "Reconnecting", n2.Disconnecting = "Disconnecting", n2.Failed = "Failed", n2))(Ie || {});
|
16013
16024
|
var Bt = ((e) => (e.CHAT = "chat", e))(Bt || {});
|
16014
16025
|
var Ge2 = ((t) => (t.INFO = "info", t.ERROR = "error", t))(Ge2 || {});
|
16015
|
-
var ve = ((
|
16026
|
+
var ve = ((M2) => (M2.PEER_JOINED = "PEER_JOINED", M2.PEER_LEFT = "PEER_LEFT", M2.PEER_LIST = "PEER_LIST", M2.NEW_MESSAGE = "NEW_MESSAGE", M2.ERROR = "ERROR", M2.RECONNECTING = "RECONNECTING", M2.RECONNECTED = "RECONNECTED", M2.TRACK_ADDED = "TRACK_ADDED", M2.TRACK_REMOVED = "TRACK_REMOVED", M2.TRACK_MUTED = "TRACK_MUTED", M2.TRACK_UNMUTED = "TRACK_UNMUTED", M2.TRACK_DEGRADED = "TRACK_DEGRADED", M2.TRACK_RESTORED = "TRACK_RESTORED", M2.TRACK_DESCRIPTION_CHANGED = "TRACK_DESCRIPTION_CHANGED", M2.ROLE_UPDATED = "ROLE_UPDATED", M2.CHANGE_TRACK_STATE_REQUEST = "CHANGE_TRACK_STATE_REQUEST", M2.CHANGE_MULTI_TRACK_STATE_REQUEST = "CHANGE_MULTI_TRACK_STATE_REQUEST", M2.ROOM_ENDED = "ROOM_ENDED", M2.REMOVED_FROM_ROOM = "REMOVED_FROM_ROOM", M2.DEVICE_CHANGE_UPDATE = "DEVICE_CHANGE_UPDATE", M2.PLAYLIST_TRACK_ENDED = "PLAYLIST_TRACK_ENDED", M2.NAME_UPDATED = "NAME_UPDATED", M2.METADATA_UPDATED = "METADATA_UPDATED", M2.POLL_CREATED = "POLL_CREATED", M2.POLL_STARTED = "POLL_STARTED", M2.POLL_STOPPED = "POLL_STOPPED", M2.POLL_VOTES_UPDATED = "POLL_VOTES_UPDATED", M2.HAND_RAISE_CHANGED = "HAND_RAISE_CHANGED", M2))(ve || {});
|
16016
16027
|
var Fe = ((t) => (t.audio = "audio", t.video = "video", t))(Fe || {});
|
16017
16028
|
function G(s, e) {
|
16018
16029
|
let t, i;
|
@@ -16060,7 +16071,7 @@ var T = (s) => s.tracks;
|
|
16060
16071
|
var Ee = (s) => s.appData;
|
16061
16072
|
var Gt = (s) => s.speakers;
|
16062
16073
|
var q = createSelector([P2], (s) => s && s.isConnected);
|
16063
|
-
var
|
16074
|
+
var fi2 = createSelector([q, P2], (s, e) => s ? e.peerCount !== void 0 ? e.peerCount || 1 : e.peers.length : Math.max(e.peerCount !== void 0 ? e.peerCount : e.peers.length - 1, 0));
|
16064
16075
|
var Ft = (s) => s.hideLocalPeer;
|
16065
16076
|
var _2 = createSelector([P2, R, Ft], (s, e, t) => t ? s.peers.filter((i) => s.localPeer !== i).map((i) => e[i]) : s.peers.map((i) => e[i]));
|
16066
16077
|
var Qt = createSelector(T, (s) => Object.values(s));
|
@@ -16069,9 +16080,9 @@ var F2 = createSelector(P2, (s) => s.localPeer);
|
|
16069
16080
|
var yi = createSelector(E2, (s) => s == null ? void 0 : s.name);
|
16070
16081
|
var mi2 = createSelector(E2, (s) => s == null ? void 0 : s.roleName);
|
16071
16082
|
var N = createSelector(E2, (s) => s == null ? void 0 : s.audioTrack);
|
16072
|
-
var
|
16083
|
+
var b = createSelector(E2, (s) => s == null ? void 0 : s.videoTrack);
|
16073
16084
|
var $t = createSelector(E2, (s) => s == null ? void 0 : s.auxiliaryTracks);
|
16074
|
-
var Ye = createSelector([N,
|
16085
|
+
var Ye = createSelector([N, b, $t], (s, e, t) => {
|
16075
16086
|
let i = t ? [...t] : [];
|
16076
16087
|
return s && i.unshift(s), e && i.unshift(e), i;
|
16077
16088
|
});
|
@@ -16119,7 +16130,7 @@ var Di2 = createSelector(R, T, (s, e) => {
|
|
16119
16130
|
}
|
16120
16131
|
return t.concat(i);
|
16121
16132
|
});
|
16122
|
-
var
|
16133
|
+
var Ii2 = createSelector(R, T, (s, e) => {
|
16123
16134
|
for (let t in e) {
|
16124
16135
|
let i = e[t];
|
16125
16136
|
if (Y(i) && J(i) && i.peerId)
|
@@ -16135,7 +16146,7 @@ var vi2 = createSelector(R, T, (s, e) => {
|
|
16135
16146
|
});
|
16136
16147
|
var Ei = createSelector(Qt, (s) => s.filter(Qe));
|
16137
16148
|
var bi = createSelector(We, (s) => s.length);
|
16138
|
-
var
|
16149
|
+
var Ai = createSelector(le2, (s) => Object.values(s).filter((e) => !e.read).length);
|
16139
16150
|
var de = createSelector(We, le2, (s, e) => {
|
16140
16151
|
let t = [];
|
16141
16152
|
return s.forEach((i) => {
|
@@ -16146,7 +16157,7 @@ var A = createSelector([P2], (s) => s && s.roomState);
|
|
16146
16157
|
var Xe = createSelector(A, (s) => s === "Preview");
|
16147
16158
|
var Ci = createSelector(P2, (s) => s.roomState !== "Disconnected");
|
16148
16159
|
var w2 = (s) => s.roles;
|
16149
|
-
var
|
16160
|
+
var Ni2 = createSelector([w2], (s) => Object.keys(s));
|
16150
16161
|
var ue2 = createSelector([E2, w2], (s, e) => s != null && s.roleName ? e[s.roleName] : null);
|
16151
16162
|
var Jt = (s) => {
|
16152
16163
|
var e;
|
@@ -16160,12 +16171,12 @@ var Li = createSelector([ue2], (s) => {
|
|
16160
16171
|
var et = createSelector(ue2, (s) => s == null ? void 0 : s.permissions);
|
16161
16172
|
var xi = createSelector(P2, (s) => s.recording);
|
16162
16173
|
var Oi2 = createSelector(P2, (s) => s.rtmp);
|
16163
|
-
var
|
16174
|
+
var _i = createSelector(P2, (s) => s.hls);
|
16164
16175
|
var wi2 = createSelector(P2, (s) => s.sessionId);
|
16165
|
-
var
|
16176
|
+
var Ui = createSelector(P2, (s) => s.startedAt);
|
16166
16177
|
var Vi2 = createSelector(P2, (s) => !!s.isLargeRoom);
|
16167
16178
|
var tt = (s) => s.polls;
|
16168
|
-
var
|
16179
|
+
var ji2 = createSelector(_2, (s) => s.filter((e) => e.isHandRaised));
|
16169
16180
|
var it2 = (s = "audio") => (e) => e.playlist[s].list;
|
16170
16181
|
var Ce = (s = "audio") => (e) => e.playlist[s].selection;
|
16171
16182
|
var ot = (s = "audio") => (e) => e.playlist[s].progress;
|
@@ -16185,25 +16196,25 @@ function u(s) {
|
|
16185
16196
|
var Z = "HMS-Store:";
|
16186
16197
|
var l = class {
|
16187
16198
|
static v(e, ...t) {
|
16188
|
-
this.log(
|
16199
|
+
this.log(Or.VERBOSE, e, ...t);
|
16189
16200
|
}
|
16190
16201
|
static d(...e) {
|
16191
|
-
this.log(
|
16202
|
+
this.log(Or.DEBUG, ...e);
|
16192
16203
|
}
|
16193
16204
|
static i(...e) {
|
16194
|
-
this.log(
|
16205
|
+
this.log(Or.INFO, ...e);
|
16195
16206
|
}
|
16196
16207
|
static w(...e) {
|
16197
|
-
this.log(
|
16208
|
+
this.log(Or.WARN, ...e);
|
16198
16209
|
}
|
16199
16210
|
static e(...e) {
|
16200
|
-
this.log(
|
16211
|
+
this.log(Or.ERROR, ...e);
|
16201
16212
|
}
|
16202
16213
|
static time(e) {
|
16203
|
-
this.log(
|
16214
|
+
this.log(Or.TIME, "[HMSPerformanceTiming]", e);
|
16204
16215
|
}
|
16205
16216
|
static timeEnd(e) {
|
16206
|
-
this.log(
|
16217
|
+
this.log(Or.TIMEEND, "[HMSPerformanceTiming]", e, e);
|
16207
16218
|
}
|
16208
16219
|
static cleanup() {
|
16209
16220
|
performance.clearMarks(), performance.clearMeasures();
|
@@ -16211,48 +16222,48 @@ var l = class {
|
|
16211
16222
|
static log(e, ...t) {
|
16212
16223
|
if (!(this.level.valueOf() > e.valueOf()))
|
16213
16224
|
switch (e) {
|
16214
|
-
case
|
16225
|
+
case Or.VERBOSE: {
|
16215
16226
|
console.log(Z, ...t);
|
16216
16227
|
break;
|
16217
16228
|
}
|
16218
|
-
case
|
16229
|
+
case Or.DEBUG: {
|
16219
16230
|
console.debug(Z, ...t);
|
16220
16231
|
break;
|
16221
16232
|
}
|
16222
|
-
case
|
16233
|
+
case Or.INFO: {
|
16223
16234
|
console.info(Z, ...t);
|
16224
16235
|
break;
|
16225
16236
|
}
|
16226
|
-
case
|
16237
|
+
case Or.WARN: {
|
16227
16238
|
console.warn(Z, ...t);
|
16228
16239
|
break;
|
16229
16240
|
}
|
16230
|
-
case
|
16241
|
+
case Or.ERROR: {
|
16231
16242
|
console.error(Z, ...t);
|
16232
16243
|
break;
|
16233
16244
|
}
|
16234
|
-
case
|
16245
|
+
case Or.TIME: {
|
16235
16246
|
performance.mark(t[1]);
|
16236
16247
|
break;
|
16237
16248
|
}
|
16238
|
-
case
|
16249
|
+
case Or.TIMEEND: {
|
16239
16250
|
let i = t[0], o = t[1];
|
16240
16251
|
try {
|
16241
16252
|
let r = performance.measure(o, o);
|
16242
|
-
this.log(
|
16253
|
+
this.log(Or.DEBUG, i, o, r == null ? void 0 : r.duration), performance.clearMarks(o), performance.clearMeasures(o);
|
16243
16254
|
} catch (r) {
|
16244
|
-
this.log(
|
16255
|
+
this.log(Or.DEBUG, i, o, r);
|
16245
16256
|
}
|
16246
16257
|
break;
|
16247
16258
|
}
|
16248
16259
|
}
|
16249
16260
|
}
|
16250
16261
|
};
|
16251
|
-
l.level =
|
16262
|
+
l.level = Or.VERBOSE;
|
16252
16263
|
var Ne = (s, e) => e;
|
16253
16264
|
var ee = (s, e) => e;
|
16254
16265
|
var pt2 = (s, e) => e;
|
16255
|
-
var
|
16266
|
+
var ts2 = (s, e) => e;
|
16256
16267
|
var ss = (s, e) => e;
|
16257
16268
|
var I = createSelector([R, Ne], (s, e) => e ? s[e] : null);
|
16258
16269
|
var Le2 = createSelector([T, ee], (s, e) => e ? s[e] : null);
|
@@ -16282,23 +16293,23 @@ var as = createSelector([T, ee], (s, e) => {
|
|
16282
16293
|
});
|
16283
16294
|
var ns = createSelector([tt, ss], (s, e) => e ? s[e] : null);
|
16284
16295
|
var v = u(I);
|
16285
|
-
var Zo = u(createSelector([Ee,
|
16296
|
+
var Zo = u(createSelector([Ee, ts2], (s, e) => {
|
16286
16297
|
if (s)
|
16287
16298
|
return e ? s[e] : s;
|
16288
16299
|
}));
|
16289
|
-
function
|
16300
|
+
function er2(s) {
|
16290
16301
|
return (e) => {
|
16291
16302
|
if (e.sessionStore)
|
16292
16303
|
return s ? e.sessionStore[s] : e.sessionStore;
|
16293
16304
|
};
|
16294
16305
|
}
|
16295
|
-
var
|
16306
|
+
var sr2 = u(createSelector(I, (s) => s == null ? void 0 : s.name));
|
16296
16307
|
var Me2 = u(Le2);
|
16297
16308
|
var Mt = u(is);
|
16298
|
-
var
|
16309
|
+
var ir = u(os);
|
16299
16310
|
var or = u(rs);
|
16300
16311
|
var rr2 = u(as);
|
16301
|
-
var
|
16312
|
+
var cs = u((s, e) => {
|
16302
16313
|
let t = I(s, e);
|
16303
16314
|
if (t && t.videoTrack && t.videoTrack !== "")
|
16304
16315
|
return s.tracks[t.videoTrack];
|
@@ -16314,11 +16325,11 @@ var nr = u((s, e) => {
|
|
16314
16325
|
});
|
16315
16326
|
var Tt = (s, e) => e ? s.speakers[e] : null;
|
16316
16327
|
var cr = u(createSelector(Tt, (s) => (s == null ? void 0 : s.audioLevel) || 0));
|
16317
|
-
var
|
16328
|
+
var ls2 = (s, e) => {
|
16318
16329
|
let t = Ss2(e)(s);
|
16319
16330
|
return Tt(s, t == null ? void 0 : t.id);
|
16320
16331
|
};
|
16321
|
-
var Sr = u(createSelector(
|
16332
|
+
var Sr = u(createSelector(ls2, (s) => (s == null ? void 0 : s.audioLevel) || 0));
|
16322
16333
|
var lr = u((s, e) => {
|
16323
16334
|
if (e)
|
16324
16335
|
return s.connectionQualities[e];
|
@@ -16353,7 +16364,7 @@ var Mr2 = u(createSelector(T, I, (s, e) => {
|
|
16353
16364
|
}));
|
16354
16365
|
var Ht = u(createSelector(T, I, (s, e) => G(s, e)));
|
16355
16366
|
var ft2 = (s) => createSelector(Ht(s), (e) => e.audio);
|
16356
|
-
var
|
16367
|
+
var Hr = u((s, e) => {
|
16357
16368
|
let t = I(s, e);
|
16358
16369
|
return $(s, t == null ? void 0 : t.audioTrack);
|
16359
16370
|
});
|
@@ -16419,23 +16430,23 @@ var ds2 = createSelector(de, (s) => s.filter((e) => {
|
|
16419
16430
|
var t;
|
16420
16431
|
return !e.recipientPeer && !((t = e.recipientRoles) != null && t.length);
|
16421
16432
|
}));
|
16422
|
-
var
|
16433
|
+
var us = createSelector([ht, pt2], (s) => s ? s.filter((e) => !e.read).length : 0);
|
16423
16434
|
var ps2 = createSelector([gt2, Ne], (s) => s ? s.filter((e) => !e.read).length : 0);
|
16424
|
-
var
|
16425
|
-
var
|
16435
|
+
var kr = createSelector(ds2, (s) => s.filter((e) => !e.read).length);
|
16436
|
+
var Rr = u(gt2);
|
16426
16437
|
var Dr2 = u(ht);
|
16427
|
-
var
|
16438
|
+
var Ir2 = u(us);
|
16428
16439
|
var vr = u(ps2);
|
16429
16440
|
var Pt = u(ns);
|
16430
|
-
var
|
16441
|
+
var Ur = createSelector([R, T], (s, e) => Object.values(s).map((i) => {
|
16431
16442
|
var o;
|
16432
16443
|
return { peer: i, isAudioEnabled: i.audioTrack ? (o = e[i.audioTrack]) == null ? void 0 : o.enabled : false };
|
16433
16444
|
}));
|
16434
16445
|
var Ms = (s) => s.roleChangeRequests[0] || null;
|
16435
|
-
var
|
16446
|
+
var Vr2 = createSelector([Ms, R, w2], (s, e, t) => s ? { requestedBy: s.requestedBy ? e[s.requestedBy] : void 0, role: t[s.roleName], token: s.token } : null);
|
16436
16447
|
var Kr = createSelector([ue2], (s) => z2(s));
|
16437
16448
|
var Br = createSelector([Ze], (s) => z2(s));
|
16438
|
-
var Hs = createSelector([
|
16449
|
+
var Hs = createSelector([b, T], (s, e) => {
|
16439
16450
|
let t = null;
|
16440
16451
|
return s && (t = e[s]), (t == null ? void 0 : t.plugins) || [];
|
16441
16452
|
});
|
@@ -16445,7 +16456,7 @@ var fs = createSelector([N, T], (s, e) => {
|
|
16445
16456
|
});
|
16446
16457
|
var ye2 = { [Ge.PEER_JOINED]: "PEER_JOINED", [Ge.PEER_LEFT]: "PEER_LEFT", [Ge.ROLE_UPDATED]: "ROLE_UPDATED", [Ge.NAME_UPDATED]: "NAME_UPDATED", [Ge.METADATA_UPDATED]: "METADATA_UPDATED", [Ge.HAND_RAISE_CHANGED]: "HAND_RAISE_CHANGED" };
|
16447
16458
|
var se2 = { [se.TRACK_ADDED]: "TRACK_ADDED", [se.TRACK_REMOVED]: "TRACK_REMOVED", [se.TRACK_MUTED]: "TRACK_MUTED", [se.TRACK_UNMUTED]: "TRACK_UNMUTED", [se.TRACK_DEGRADED]: "TRACK_DEGRADED", [se.TRACK_RESTORED]: "TRACK_RESTORED", [se.TRACK_DESCRIPTION_CHANGED]: "TRACK_DESCRIPTION_CHANGED" };
|
16448
|
-
var me = { [
|
16459
|
+
var me = { [hi.POLL_CREATED]: "POLL_CREATED", [hi.POLL_STARTED]: "POLL_STARTED", [hi.POLL_STOPPED]: "POLL_STOPPED", [hi.POLL_STATS_UPDATED]: "POLL_VOTES_UPDATED" };
|
16449
16460
|
var Os = (s) => s.localPeer.id;
|
16450
16461
|
var _s = (s) => s.localPeer.audioTrack;
|
16451
16462
|
var ws = (s) => s.localPeer.videoTrack;
|
@@ -16523,7 +16534,7 @@ import AutoSizer from "react-virtualized-auto-sizer";
|
|
16523
16534
|
import { VariableSizeList } from "react-window";
|
16524
16535
|
import {
|
16525
16536
|
selectHMSMessages,
|
16526
|
-
selectLocalPeerID as
|
16537
|
+
selectLocalPeerID as selectLocalPeerID9,
|
16527
16538
|
selectLocalPeerName as selectLocalPeerName2,
|
16528
16539
|
selectLocalPeerRoleName as selectLocalPeerRoleName4,
|
16529
16540
|
selectMessagesByPeerID,
|
@@ -16576,7 +16587,7 @@ var useSetPinnedMessages = () => {
|
|
16576
16587
|
const setPinnedMessages = useCallback23(
|
16577
16588
|
(..._0) => __async(void 0, [..._0], function* (pinnedMessages = [], message, pinnedBy) {
|
16578
16589
|
const peerName = vanillaStore.getState(selectPeerNameByID2(message == null ? void 0 : message.sender)) || (message == null ? void 0 : message.senderName);
|
16579
|
-
const newPinnedMessage = { text: "", id: message.id, pinnedBy, authorId: (message == null ? void 0 : message.
|
16590
|
+
const newPinnedMessage = { text: "", id: message.id, pinnedBy, authorId: (message == null ? void 0 : message.senderUserId) || "" };
|
16580
16591
|
if (message && peerName) {
|
16581
16592
|
newPinnedMessage["text"] = `${peerName}: ${message.message}`;
|
16582
16593
|
} else if (message) {
|
@@ -16627,6 +16638,13 @@ var useUnreadCount = ({ role, peerId }) => {
|
|
16627
16638
|
|
16628
16639
|
// src/Prebuilt/components/Chat/ChatBody.jsx
|
16629
16640
|
var iconStyle = { height: "1.125rem", width: "1.125rem" };
|
16641
|
+
var tooltipBoxCSS = {
|
16642
|
+
fontSize: "$xs",
|
16643
|
+
backgroundColor: "$surface_default",
|
16644
|
+
p: "$1 $5",
|
16645
|
+
fontWeight: "$regular",
|
16646
|
+
borderRadius: "$3"
|
16647
|
+
};
|
16630
16648
|
var formatTime2 = (date) => {
|
16631
16649
|
if (!(date instanceof Date)) {
|
16632
16650
|
return "";
|
@@ -16699,7 +16717,7 @@ var getMessageType = ({ roles, receiver }) => {
|
|
16699
16717
|
}
|
16700
16718
|
return receiver ? "private" : "";
|
16701
16719
|
};
|
16702
|
-
var ChatActions = ({ onPin, showPinAction, message,
|
16720
|
+
var ChatActions = ({ onPin, showPinAction, message, sentByLocalPeer, isMobile, openSheet, setOpenSheet }) => {
|
16703
16721
|
var _a7;
|
16704
16722
|
const { elements } = useRoomLayoutConferencingScreen();
|
16705
16723
|
const { can_hide_message, can_block_user } = ((_a7 = elements == null ? void 0 : elements.chat) == null ? void 0 : _a7.real_time_controls) || {
|
@@ -16708,19 +16726,19 @@ var ChatActions = ({ onPin, showPinAction, message, peerId, sentByLocalPeer, isM
|
|
16708
16726
|
};
|
16709
16727
|
const [open, setOpen] = useState37(false);
|
16710
16728
|
const blacklistedPeerIDs = useHMSStore41(selectSessionStore2("chatPeerBlacklist" /* CHAT_PEER_BLACKLIST */)) || [];
|
16711
|
-
const { blacklistItem: blacklistMessage } = useChatBlacklist("chatMessageBlacklist" /* CHAT_MESSAGE_BLACKLIST */);
|
16712
|
-
const blacklistedMessageIDs = useHMSStore41(selectSessionStore2("chatMessageBlacklist" /* CHAT_MESSAGE_BLACKLIST */)) || [];
|
16713
16729
|
const { blacklistItem: blacklistPeer } = useChatBlacklist("chatPeerBlacklist" /* CHAT_PEER_BLACKLIST */);
|
16730
|
+
const blacklistedMessageIDs = useHMSStore41(selectSessionStore2("chatMessageBlacklist" /* CHAT_MESSAGE_BLACKLIST */)) || [];
|
16731
|
+
const { blacklistItem: blacklistMessage } = useChatBlacklist("chatMessageBlacklist" /* CHAT_MESSAGE_BLACKLIST */);
|
16714
16732
|
const { unpinBlacklistedMessages } = useSetPinnedMessages();
|
16715
16733
|
const pinnedMessages = useHMSStore41(selectSessionStore2("pinnedMessages" /* PINNED_MESSAGES */)) || [];
|
16716
|
-
|
16717
|
-
|
16718
|
-
|
16719
|
-
|
16720
|
-
|
16721
|
-
|
16722
|
-
|
16723
|
-
|
16734
|
+
const updatePinnedMessages = useCallback24(
|
16735
|
+
({ messageID = "", peerID = "" }) => {
|
16736
|
+
const blacklistedMessageIDSet = /* @__PURE__ */ new Set([...blacklistedMessageIDs, messageID]);
|
16737
|
+
const blacklistedPeerIDSet = /* @__PURE__ */ new Set([...blacklistedPeerIDs, peerID]);
|
16738
|
+
unpinBlacklistedMessages(pinnedMessages, blacklistedPeerIDSet, blacklistedMessageIDSet);
|
16739
|
+
},
|
16740
|
+
[pinnedMessages, blacklistedMessageIDs, blacklistedPeerIDs]
|
16741
|
+
);
|
16724
16742
|
const copyMessageContent = useCallback24(() => {
|
16725
16743
|
try {
|
16726
16744
|
navigator == null ? void 0 : navigator.clipboard.writeText(message.message);
|
@@ -16737,12 +16755,14 @@ var ChatActions = ({ onPin, showPinAction, message, peerId, sentByLocalPeer, isM
|
|
16737
16755
|
const options = {
|
16738
16756
|
pin: {
|
16739
16757
|
text: "Pin message",
|
16758
|
+
tooltipText: "Pin",
|
16740
16759
|
icon: /* @__PURE__ */ React95.createElement(PinIcon, { style: iconStyle }),
|
16741
16760
|
onClick: onPin,
|
16742
16761
|
show: showPinAction
|
16743
16762
|
},
|
16744
16763
|
copy: {
|
16745
16764
|
text: "Copy text",
|
16765
|
+
tooltipText: "Copy",
|
16746
16766
|
icon: /* @__PURE__ */ React95.createElement(CopyIcon2, { style: iconStyle }),
|
16747
16767
|
onClick: copyMessageContent,
|
16748
16768
|
show: true
|
@@ -16751,7 +16771,8 @@ var ChatActions = ({ onPin, showPinAction, message, peerId, sentByLocalPeer, isM
|
|
16751
16771
|
text: "Hide for everyone",
|
16752
16772
|
icon: /* @__PURE__ */ React95.createElement(EyeCloseIcon2, { style: iconStyle }),
|
16753
16773
|
onClick: () => __async(void 0, null, function* () {
|
16754
|
-
|
16774
|
+
blacklistMessage(blacklistedMessageIDs, message.id);
|
16775
|
+
updatePinnedMessages({ messageID: message.id });
|
16755
16776
|
}),
|
16756
16777
|
show: can_hide_message
|
16757
16778
|
},
|
@@ -16759,7 +16780,8 @@ var ChatActions = ({ onPin, showPinAction, message, peerId, sentByLocalPeer, isM
|
|
16759
16780
|
text: "Block from chat",
|
16760
16781
|
icon: /* @__PURE__ */ React95.createElement(CrossCircleIcon, { style: iconStyle }),
|
16761
16782
|
onClick: () => __async(void 0, null, function* () {
|
16762
|
-
|
16783
|
+
blacklistPeer(blacklistedPeerIDs, message == null ? void 0 : message.senderUserId);
|
16784
|
+
updatePinnedMessages({ peerID: message == null ? void 0 : message.senderUserId });
|
16763
16785
|
}),
|
16764
16786
|
color: "$alert_error_default",
|
16765
16787
|
show: can_block_user && !sentByLocalPeer
|
@@ -16810,9 +16832,9 @@ var ChatActions = ({ onPin, showPinAction, message, peerId, sentByLocalPeer, isM
|
|
16810
16832
|
"@md": { opacity: 1 }
|
16811
16833
|
}
|
16812
16834
|
},
|
16813
|
-
options.pin.show ? /* @__PURE__ */ React95.createElement(IconButton, { "data-testid": "pin_message_btn", onClick: options.pin.onClick }, options.pin.icon) : null,
|
16814
|
-
options.copy.show ? /* @__PURE__ */ React95.createElement(IconButton, { onClick: options.copy.onClick, "data-testid": "copy_message_btn" }, /* @__PURE__ */ React95.createElement(CopyIcon2, { style: iconStyle })) : null,
|
16815
|
-
options.block.show || options.hide.show ? /* @__PURE__ */ React95.createElement(
|
16835
|
+
options.pin.show ? /* @__PURE__ */ React95.createElement(Tooltip, { boxCss: tooltipBoxCSS, title: options.pin.tooltipText }, /* @__PURE__ */ React95.createElement(IconButton, { "data-testid": "pin_message_btn", onClick: options.pin.onClick }, options.pin.icon)) : null,
|
16836
|
+
options.copy.show ? /* @__PURE__ */ React95.createElement(Tooltip, { boxCss: tooltipBoxCSS, title: options.copy.tooltipText }, /* @__PURE__ */ React95.createElement(IconButton, { onClick: options.copy.onClick, "data-testid": "copy_message_btn" }, /* @__PURE__ */ React95.createElement(CopyIcon2, { style: iconStyle }))) : null,
|
16837
|
+
options.block.show || options.hide.show ? /* @__PURE__ */ React95.createElement(Tooltip, { boxCss: tooltipBoxCSS, title: "More actions" }, /* @__PURE__ */ React95.createElement(Dropdown.Trigger, { asChild: true }, /* @__PURE__ */ React95.createElement(IconButton, null, /* @__PURE__ */ React95.createElement(VerticalMenuIcon6, { style: iconStyle })))) : null
|
16816
16838
|
), /* @__PURE__ */ React95.createElement(Dropdown.Portal, null, /* @__PURE__ */ React95.createElement(
|
16817
16839
|
Dropdown.Content,
|
16818
16840
|
{
|
@@ -16856,7 +16878,7 @@ var ChatMessage = React95.memo(
|
|
16856
16878
|
const { elements } = useRoomLayoutConferencingScreen();
|
16857
16879
|
const isOverlay = ((_a7 = elements == null ? void 0 : elements.chat) == null ? void 0 : _a7.is_overlay) && isMobile;
|
16858
16880
|
const hmsActions = useHMSActions30();
|
16859
|
-
const localPeerId = useHMSStore41(
|
16881
|
+
const localPeerId = useHMSStore41(selectLocalPeerID9);
|
16860
16882
|
const permissions = useHMSStore41(selectPermissions12);
|
16861
16883
|
const messageType = getMessageType({
|
16862
16884
|
roles: message.recipientRoles,
|
@@ -16880,9 +16902,9 @@ var ChatMessage = React95.memo(
|
|
16880
16902
|
ref,
|
16881
16903
|
as: "div",
|
16882
16904
|
css: {
|
16883
|
-
mb: "$
|
16905
|
+
mb: "$5",
|
16884
16906
|
pr: "$10",
|
16885
|
-
mt: "$
|
16907
|
+
mt: "$4",
|
16886
16908
|
"&:hover .chat_actions": { opacity: 1 }
|
16887
16909
|
},
|
16888
16910
|
style
|
@@ -16896,12 +16918,14 @@ var ChatMessage = React95.memo(
|
|
16896
16918
|
flexWrap: "wrap",
|
16897
16919
|
// Theme independent color, token should not be used for transparent chat
|
16898
16920
|
bg: messageType ? isOverlay ? "rgba(0, 0, 0, 0.64)" : "$surface_default" : void 0,
|
16899
|
-
r:
|
16900
|
-
|
16901
|
-
py: messageType ? "$4" : 0,
|
16921
|
+
r: "$1",
|
16922
|
+
p: "$1 $2",
|
16902
16923
|
userSelect: "none",
|
16903
16924
|
"@md": {
|
16904
16925
|
cursor: "pointer"
|
16926
|
+
},
|
16927
|
+
"&:hover": {
|
16928
|
+
background: "linear-gradient(277deg, $surface_default 0%, $surface_dim 60.87%)"
|
16905
16929
|
}
|
16906
16930
|
},
|
16907
16931
|
key: message.time,
|
@@ -16952,7 +16976,6 @@ var ChatMessage = React95.memo(
|
|
16952
16976
|
onPin,
|
16953
16977
|
showPinAction,
|
16954
16978
|
message,
|
16955
|
-
peerId: message.sender,
|
16956
16979
|
sentByLocalPeer: message.sender === localPeerId,
|
16957
16980
|
isMobile,
|
16958
16981
|
openSheet,
|
@@ -17075,7 +17098,7 @@ var ChatBody = React95.forwardRef(({ role, peerId, scrollToBottom, blacklistedPe
|
|
17075
17098
|
const blacklistedMessageIDSet = new Set(blacklistedMessageIDs);
|
17076
17099
|
const blacklistedPeerIDSet = new Set(blacklistedPeerIDs);
|
17077
17100
|
return (messages == null ? void 0 : messages.filter(
|
17078
|
-
(message) => message.type === "chat" && !blacklistedMessageIDSet.has(message.id) && !blacklistedPeerIDSet.has(message.
|
17101
|
+
(message) => message.type === "chat" && !blacklistedMessageIDSet.has(message.id) && !blacklistedPeerIDSet.has(message == null ? void 0 : message.senderUserId)
|
17079
17102
|
)) || [];
|
17080
17103
|
};
|
17081
17104
|
const isMobile = useMedia10(config.media.md);
|
@@ -17121,7 +17144,7 @@ import React96, { useCallback as useCallback26, useEffect as useEffect21, useRef
|
|
17121
17144
|
import { useMedia as useMedia11 } from "react-use";
|
17122
17145
|
import data2 from "@emoji-mart/data";
|
17123
17146
|
import Picker from "@emoji-mart/react";
|
17124
|
-
import {
|
17147
|
+
import { selectLocalPeer as selectLocalPeer2, useHMSActions as useHMSActions32, useHMSStore as useHMSStore43 } from "@100mslive/react-sdk";
|
17125
17148
|
import { EmojiIcon as EmojiIcon3, PauseCircleIcon as PauseCircleIcon2, SendIcon, VerticalMenuIcon as VerticalMenuIcon7 } from "@100mslive/react-icons";
|
17126
17149
|
|
17127
17150
|
// src/Prebuilt/components/AppData/useChatState.js
|
@@ -17234,9 +17257,9 @@ var ChatFooter = ({
|
|
17234
17257
|
const isMobile = useMedia11(config.media.md);
|
17235
17258
|
const { elements } = useRoomLayoutConferencingScreen();
|
17236
17259
|
const message_placeholder = ((_a7 = elements == null ? void 0 : elements.chat) == null ? void 0 : _a7.message_placeholder) || "Send a message";
|
17237
|
-
const
|
17260
|
+
const localPeer = useHMSStore43(selectLocalPeer2);
|
17238
17261
|
const isOverlayChat = (_b7 = elements == null ? void 0 : elements.chat) == null ? void 0 : _b7.is_overlay;
|
17239
|
-
const
|
17262
|
+
const canDisableChat = !!((_d = (_c = elements == null ? void 0 : elements.chat) == null ? void 0 : _c.real_time_controls) == null ? void 0 : _d.can_disable_chat);
|
17240
17263
|
const sendMessage = useCallback26(() => __async(void 0, null, function* () {
|
17241
17264
|
var _a8;
|
17242
17265
|
const message = (_a8 = inputRef == null ? void 0 : inputRef.current) == null ? void 0 : _a8.value;
|
@@ -17272,16 +17295,22 @@ var ChatFooter = ({
|
|
17272
17295
|
setDraftMessage((messageElement == null ? void 0 : messageElement.value) || "");
|
17273
17296
|
};
|
17274
17297
|
}, [setDraftMessage]);
|
17275
|
-
return /* @__PURE__ */ React96.createElement(Box, null,
|
17298
|
+
return /* @__PURE__ */ React96.createElement(Box, null, canDisableChat ? /* @__PURE__ */ React96.createElement(Flex, { align: "center", justify: "end", css: { w: "100%", mb: "$4" } }, /* @__PURE__ */ React96.createElement(Popover2.Root, null, /* @__PURE__ */ React96.createElement(Popover2.Trigger, { asChild: true }, /* @__PURE__ */ React96.createElement(IconButton, { css: { border: "1px solid $border_bright" } }, /* @__PURE__ */ React96.createElement(VerticalMenuIcon7, { height: "16", width: "16" }))), /* @__PURE__ */ React96.createElement(Popover2.Portal, null, /* @__PURE__ */ React96.createElement(
|
17276
17299
|
Popover2.Content,
|
17277
17300
|
{
|
17278
17301
|
align: "end",
|
17279
17302
|
side: "top",
|
17280
17303
|
onClick: () => {
|
17281
|
-
|
17304
|
+
const chatState = {
|
17282
17305
|
enabled: false,
|
17283
|
-
updatedBy:
|
17284
|
-
|
17306
|
+
updatedBy: {
|
17307
|
+
peerId: localPeer == null ? void 0 : localPeer.id,
|
17308
|
+
userId: localPeer == null ? void 0 : localPeer.customerUserId,
|
17309
|
+
userName: localPeer == null ? void 0 : localPeer.name
|
17310
|
+
},
|
17311
|
+
updatedAt: Date.now()
|
17312
|
+
};
|
17313
|
+
hmsActions.sessionStore.set("chatState" /* CHAT_STATE */, chatState);
|
17285
17314
|
},
|
17286
17315
|
css: {
|
17287
17316
|
backgroundColor: "$surface_default",
|
@@ -17376,21 +17405,22 @@ var ChatFooter = ({
|
|
17376
17405
|
// src/Prebuilt/components/Chat/ChatStates.jsx
|
17377
17406
|
init_define_process_env();
|
17378
17407
|
import React97, { useCallback as useCallback27 } from "react";
|
17379
|
-
import {
|
17408
|
+
import { selectLocalPeer as selectLocalPeer3, selectSessionStore as selectSessionStore3, useHMSActions as useHMSActions33, useHMSStore as useHMSStore44 } from "@100mslive/react-sdk";
|
17380
17409
|
var ChatPaused = () => {
|
17381
17410
|
const hmsActions = useHMSActions33();
|
17382
17411
|
const { elements } = useRoomLayoutConferencingScreen();
|
17383
17412
|
const { can_disable_chat } = (elements == null ? void 0 : elements.chat.real_time_controls) || false;
|
17384
|
-
const { enabled: isChatEnabled = true, updatedBy: chatStateUpdatedBy
|
17385
|
-
const
|
17413
|
+
const { enabled: isChatEnabled = true, updatedBy: chatStateUpdatedBy } = useHMSStore44(selectSessionStore3("chatState" /* CHAT_STATE */)) || {};
|
17414
|
+
const localPeer = useHMSStore44(selectLocalPeer3);
|
17386
17415
|
const unPauseChat = useCallback27(
|
17387
17416
|
() => __async(void 0, null, function* () {
|
17388
17417
|
return yield hmsActions.sessionStore.set("chatState" /* CHAT_STATE */, {
|
17389
17418
|
enabled: true,
|
17390
|
-
updatedBy:
|
17419
|
+
updatedBy: { userName: localPeer.name, userId: localPeer == null ? void 0 : localPeer.customerUserId, peerId: localPeer.id },
|
17420
|
+
updatedAt: Date.now()
|
17391
17421
|
});
|
17392
17422
|
}),
|
17393
|
-
[hmsActions,
|
17423
|
+
[hmsActions, localPeer]
|
17394
17424
|
);
|
17395
17425
|
return isChatEnabled ? null : /* @__PURE__ */ React97.createElement(
|
17396
17426
|
Flex,
|
@@ -17406,7 +17436,7 @@ var ChatPaused = () => {
|
|
17406
17436
|
css: { color: "$on_surface_medium", maxWidth: "100%", overflow: "hidden", textOverflow: "ellipsis" }
|
17407
17437
|
},
|
17408
17438
|
"Chat has been paused by ",
|
17409
|
-
chatStateUpdatedBy
|
17439
|
+
(chatStateUpdatedBy == null ? void 0 : chatStateUpdatedBy.peerId) === localPeer.id ? "you" : chatStateUpdatedBy == null ? void 0 : chatStateUpdatedBy.userName
|
17410
17440
|
)),
|
17411
17441
|
can_disable_chat ? /* @__PURE__ */ React97.createElement(Button, { css: { fontWeight: "$semiBold", fontSize: "$sm", borderRadius: "$2" }, onClick: unPauseChat }, "Resume") : /* @__PURE__ */ React97.createElement(React97.Fragment, null)
|
17412
17442
|
);
|
@@ -17428,7 +17458,7 @@ init_define_process_env();
|
|
17428
17458
|
import React99, { useEffect as useEffect22, useRef as useRef18, useState as useState39 } from "react";
|
17429
17459
|
import { useSwipeable } from "react-swipeable";
|
17430
17460
|
import { useMedia as useMedia12 } from "react-use";
|
17431
|
-
import {
|
17461
|
+
import { selectSessionStore as selectSessionStore4, useHMSStore as useHMSStore45 } from "@100mslive/react-sdk";
|
17432
17462
|
import { CrossIcon as CrossIcon14, PinIcon as PinIcon2 } from "@100mslive/react-icons";
|
17433
17463
|
|
17434
17464
|
// src/Prebuilt/components/Chat/Navigation.tsx
|
@@ -17451,7 +17481,7 @@ var Navigation = ({
|
|
17451
17481
|
{
|
17452
17482
|
css: {
|
17453
17483
|
borderLeft: "2px solid",
|
17454
|
-
height: "$
|
17484
|
+
height: "$4",
|
17455
17485
|
borderColor: i === index ? "$on_surface_high" : "$on_surface_low"
|
17456
17486
|
}
|
17457
17487
|
}
|
@@ -17475,13 +17505,13 @@ var Navigation = ({
|
|
17475
17505
|
// src/Prebuilt/components/Chat/PinnedMessage.tsx
|
17476
17506
|
var PINNED_MESSAGE_LENGTH = 75;
|
17477
17507
|
var PinnedMessage = ({ clearPinnedMessage }) => {
|
17478
|
-
var _a7, _b7, _c;
|
17479
|
-
const permissions = useHMSStore45(selectPermissions13);
|
17508
|
+
var _a7, _b7, _c, _d, _e;
|
17480
17509
|
const pinnedMessages = useHMSStore45(selectSessionStore4("pinnedMessages" /* PINNED_MESSAGES */)) || [];
|
17481
17510
|
const [pinnedMessageIndex, setPinnedMessageIndex] = useState39(0);
|
17482
17511
|
const isMobile = useMedia12(config.media.md);
|
17483
17512
|
const [hideOverflow, setHideOverflow] = useState39(false);
|
17484
|
-
const
|
17513
|
+
const canOverflow = ((_b7 = (_a7 = pinnedMessages == null ? void 0 : pinnedMessages[pinnedMessageIndex]) == null ? void 0 : _a7.text) == null ? void 0 : _b7.length) > PINNED_MESSAGE_LENGTH || false;
|
17514
|
+
const formattedPinnedMessage = hideOverflow ? `${(_c = pinnedMessages == null ? void 0 : pinnedMessages[pinnedMessageIndex]) == null ? void 0 : _c.text.slice(0, PINNED_MESSAGE_LENGTH)}... ` : (_d = pinnedMessages == null ? void 0 : pinnedMessages[pinnedMessageIndex]) == null ? void 0 : _d.text;
|
17485
17515
|
const pinnedMessageRef = useRef18(null);
|
17486
17516
|
const showPreviousPinnedMessage = () => {
|
17487
17517
|
const previousIndex = Math.max(pinnedMessageIndex - 1, 0);
|
@@ -17503,7 +17533,7 @@ var PinnedMessage = ({ clearPinnedMessage }) => {
|
|
17503
17533
|
!!(((_b8 = (_a8 = pinnedMessages == null ? void 0 : pinnedMessages[pinnedMessageIndex]) == null ? void 0 : _a8.text) == null ? void 0 : _b8.length) && ((_c2 = pinnedMessages == null ? void 0 : pinnedMessages[pinnedMessageIndex]) == null ? void 0 : _c2.text.length) > PINNED_MESSAGE_LENGTH)
|
17504
17534
|
);
|
17505
17535
|
}, [pinnedMessageIndex, pinnedMessages]);
|
17506
|
-
return ((
|
17536
|
+
return ((_e = pinnedMessages == null ? void 0 : pinnedMessages[pinnedMessageIndex]) == null ? void 0 : _e.text) ? /* @__PURE__ */ React99.createElement(Flex, { ref: pinnedMessageRef, align: "center", css: { w: "100%", gap: "$4" } }, /* @__PURE__ */ React99.createElement(
|
17507
17537
|
Flex,
|
17508
17538
|
{
|
17509
17539
|
title: pinnedMessages[pinnedMessageIndex].text,
|
@@ -17545,9 +17575,9 @@ var PinnedMessage = ({ clearPinnedMessage }) => {
|
|
17545
17575
|
}
|
17546
17576
|
}
|
17547
17577
|
},
|
17548
|
-
/* @__PURE__ */ React99.createElement(Text, __spreadValues({ variant: "sm", css: { color: "$on_surface_medium" } }, swipeHandlers), /* @__PURE__ */ React99.createElement(AnnotisedMessage, { message: formattedPinnedMessage }),
|
17578
|
+
/* @__PURE__ */ React99.createElement(Text, __spreadValues({ variant: "sm", css: { color: "$on_surface_medium" } }, swipeHandlers), /* @__PURE__ */ React99.createElement(AnnotisedMessage, { message: formattedPinnedMessage }), canOverflow ? /* @__PURE__ */ React99.createElement("span", { style: { cursor: "pointer" }, onClick: () => setHideOverflow((prev) => !prev) }, "$nbsp;", hideOverflow ? "See more" : "Collapse") : null)
|
17549
17579
|
),
|
17550
|
-
|
17580
|
+
/* @__PURE__ */ React99.createElement(
|
17551
17581
|
Flex,
|
17552
17582
|
{
|
17553
17583
|
onClick: () => {
|
@@ -17563,12 +17593,12 @@ var PinnedMessage = ({ clearPinnedMessage }) => {
|
|
17563
17593
|
|
17564
17594
|
// src/Prebuilt/components/Chat/Chat.jsx
|
17565
17595
|
var Chat = ({ screenType }) => {
|
17566
|
-
var _a7, _b7
|
17596
|
+
var _a7, _b7;
|
17567
17597
|
const notification = useHMSNotifications(HMSNotificationTypes.PEER_LEFT);
|
17568
17598
|
const [peerSelector, setPeerSelector] = useSetSubscribedChatSelector(CHAT_SELECTOR.PEER_ID);
|
17569
17599
|
const [roleSelector, setRoleSelector] = useSetSubscribedChatSelector(CHAT_SELECTOR.ROLE);
|
17570
17600
|
const peerName = useHMSStore46(selectPeerNameByID4(peerSelector));
|
17571
|
-
const
|
17601
|
+
const localPeer = useHMSStore46(E2);
|
17572
17602
|
const [chatOptions, setChatOptions] = useState40({
|
17573
17603
|
role: roleSelector || "",
|
17574
17604
|
peerId: peerSelector && peerName ? peerSelector : "",
|
@@ -17578,7 +17608,7 @@ var Chat = ({ screenType }) => {
|
|
17578
17608
|
const listRef = useRef19(null);
|
17579
17609
|
const hmsActions = useHMSActions34();
|
17580
17610
|
const { removePinnedMessage } = useSetPinnedMessages();
|
17581
|
-
const pinnedMessages = useHMSStore46(
|
17611
|
+
const pinnedMessages = useHMSStore46(er2("pinnedMessages" /* PINNED_MESSAGES */)) || [];
|
17582
17612
|
useEffect23(() => {
|
17583
17613
|
if (notification && notification.data && peerSelector === notification.data.id) {
|
17584
17614
|
setPeerSelector("");
|
@@ -17589,12 +17619,12 @@ var Chat = ({ screenType }) => {
|
|
17589
17619
|
});
|
17590
17620
|
}
|
17591
17621
|
}, [notification, peerSelector, setPeerSelector]);
|
17592
|
-
const blacklistedPeerIDs = useHMSStore46(
|
17622
|
+
const blacklistedPeerIDs = useHMSStore46(er2("chatPeerBlacklist" /* CHAT_PEER_BLACKLIST */)) || [];
|
17593
17623
|
const blacklistedPeerIDSet = new Set(blacklistedPeerIDs);
|
17594
|
-
const isLocalPeerBlacklisted = blacklistedPeerIDSet.has(
|
17624
|
+
const isLocalPeerBlacklisted = blacklistedPeerIDSet.has(localPeer == null ? void 0 : localPeer.customerUserId);
|
17595
17625
|
const storeMessageSelector = selectHMSMessagesCount;
|
17596
17626
|
const { elements } = useRoomLayoutConferencingScreen();
|
17597
|
-
const { enabled: isChatEnabled = true } = useHMSStore46(
|
17627
|
+
const { enabled: isChatEnabled = true } = useHMSStore46(er2("chatState" /* CHAT_STATE */)) || {};
|
17598
17628
|
const isMobile = useMedia13(config.media.md);
|
17599
17629
|
let isScrolledToBottom = false;
|
17600
17630
|
if (listRef.current) {
|
@@ -17625,7 +17655,7 @@ var Chat = ({ screenType }) => {
|
|
17625
17655
|
gap: "$4"
|
17626
17656
|
}
|
17627
17657
|
},
|
17628
|
-
isMobile && ((_a7 = elements == null ? void 0 : elements.chat) == null ? void 0 : _a7.is_overlay) ? null : /* @__PURE__ */ React100.createElement(React100.Fragment, null,
|
17658
|
+
isMobile && ((_a7 = elements == null ? void 0 : elements.chat) == null ? void 0 : _a7.is_overlay) ? null : /* @__PURE__ */ React100.createElement(React100.Fragment, null, /* @__PURE__ */ React100.createElement(PinnedMessage, { clearPinnedMessage: (index) => removePinnedMessage(pinnedMessages, index) })),
|
17629
17659
|
/* @__PURE__ */ React100.createElement(
|
17630
17660
|
ChatBody,
|
17631
17661
|
{
|
@@ -17639,7 +17669,7 @@ var Chat = ({ screenType }) => {
|
|
17639
17669
|
),
|
17640
17670
|
/* @__PURE__ */ React100.createElement(ChatPaused, null),
|
17641
17671
|
isLocalPeerBlacklisted ? /* @__PURE__ */ React100.createElement(ChatBlocked, null) : null,
|
17642
|
-
isMobile && ((
|
17672
|
+
isMobile && ((_b7 = elements == null ? void 0 : elements.chat) == null ? void 0 : _b7.is_overlay) ? /* @__PURE__ */ React100.createElement(PinnedMessage, { clearPinnedMessage: (index) => removePinnedMessage(pinnedMessages, index) }) : null,
|
17643
17673
|
isChatEnabled && !isLocalPeerBlacklisted ? /* @__PURE__ */ React100.createElement(
|
17644
17674
|
ChatFooter,
|
17645
17675
|
{
|
@@ -17917,7 +17947,7 @@ import {
|
|
17917
17947
|
selectAudioTrackByPeerID as selectAudioTrackByPeerID2,
|
17918
17948
|
selectHasPeerHandRaised as selectHasPeerHandRaised3,
|
17919
17949
|
selectIsPeerAudioEnabled as selectIsPeerAudioEnabled2,
|
17920
|
-
selectLocalPeerID as
|
17950
|
+
selectLocalPeerID as selectLocalPeerID11,
|
17921
17951
|
selectPeerMetadata as selectPeerMetadata4,
|
17922
17952
|
selectPeerNameByID as selectPeerNameByID5,
|
17923
17953
|
selectSessionStore as selectSessionStore6,
|
@@ -17973,9 +18003,9 @@ init_define_process_env();
|
|
17973
18003
|
import React105, { useState as useState43 } from "react";
|
17974
18004
|
import { useMedia as useMedia16 } from "react-use";
|
17975
18005
|
import {
|
17976
|
-
selectLocalPeerID as
|
18006
|
+
selectLocalPeerID as selectLocalPeerID10,
|
17977
18007
|
selectPeerByID as selectPeerByID2,
|
17978
|
-
selectPermissions as
|
18008
|
+
selectPermissions as selectPermissions14,
|
17979
18009
|
selectTrackByID as selectTrackByID3,
|
17980
18010
|
selectVideoTrackByPeerID as selectVideoTrackByPeerID2,
|
17981
18011
|
useHMSStore as useHMSStore50,
|
@@ -17988,7 +18018,7 @@ init_define_process_env();
|
|
17988
18018
|
import React104, { Fragment as Fragment12 } from "react";
|
17989
18019
|
import { useMedia as useMedia15 } from "react-use";
|
17990
18020
|
import {
|
17991
|
-
selectPermissions as
|
18021
|
+
selectPermissions as selectPermissions13,
|
17992
18022
|
selectSessionStore as selectSessionStore5,
|
17993
18023
|
selectTrackByID as selectTrackByID2,
|
17994
18024
|
useCustomEvent as useCustomEvent2,
|
@@ -18128,7 +18158,7 @@ var SimulcastLayers = ({ trackId }) => {
|
|
18128
18158
|
};
|
18129
18159
|
var TileMenuContent = (props) => {
|
18130
18160
|
const actions = useHMSActions35();
|
18131
|
-
const { removeOthers } = useHMSStore49(
|
18161
|
+
const { removeOthers } = useHMSStore49(selectPermissions13);
|
18132
18162
|
const {
|
18133
18163
|
videoTrackID,
|
18134
18164
|
audioTrackID,
|
@@ -18228,9 +18258,9 @@ var TileMenu = ({
|
|
18228
18258
|
var _a7, _b7;
|
18229
18259
|
const [open, setOpen] = useState43(false);
|
18230
18260
|
const { theme: theme2 } = useTheme();
|
18231
|
-
const localPeerID = useHMSStore50(
|
18261
|
+
const localPeerID = useHMSStore50(selectLocalPeerID10);
|
18232
18262
|
const isLocal = localPeerID === peerID;
|
18233
|
-
const { removeOthers } = useHMSStore50(
|
18263
|
+
const { removeOthers } = useHMSStore50(selectPermissions14);
|
18234
18264
|
const { setVolume, toggleAudio, toggleVideo } = useRemoteAVToggle2(audioTrackID, videoTrackID);
|
18235
18265
|
const showSpotlight = enableSpotlightingPeer;
|
18236
18266
|
const isPrimaryVideoTrack = ((_a7 = useHMSStore50(selectVideoTrackByPeerID2(peerID))) == null ? void 0 : _a7.id) === videoTrackID;
|
@@ -18334,7 +18364,7 @@ var Tile = ({
|
|
18334
18364
|
const isMobile = useMedia17(config.media.md);
|
18335
18365
|
const peerName = useHMSStore51(selectPeerNameByID5(peerId));
|
18336
18366
|
const audioTrack = useHMSStore51(selectAudioTrackByPeerID2(peerId));
|
18337
|
-
const localPeerID = useHMSStore51(
|
18367
|
+
const localPeerID = useHMSStore51(selectLocalPeerID11);
|
18338
18368
|
const isAudioOnly = useUISettings(UI_SETTINGS.isAudioOnly);
|
18339
18369
|
const mirrorLocalVideo = useUISettings(UI_SETTINGS.mirrorLocalVideo);
|
18340
18370
|
const showStatsOnTiles = useUISettings(UI_SETTINGS.showStatsOnTiles);
|
@@ -18441,7 +18471,7 @@ import {
|
|
18441
18471
|
HMSRoomState as HMSRoomState4,
|
18442
18472
|
selectIsLargeRoom as selectIsLargeRoom3,
|
18443
18473
|
selectIsLocalVideoEnabled as selectIsLocalVideoEnabled5,
|
18444
|
-
selectLocalPeer,
|
18474
|
+
selectLocalPeer as selectLocalPeer4,
|
18445
18475
|
selectLocalPeerRole,
|
18446
18476
|
selectLocalVideoTrackID as selectLocalVideoTrackID3,
|
18447
18477
|
selectRoomState as selectRoomState4,
|
@@ -18546,7 +18576,7 @@ var VBPicker = ({ background_media = [] } = {}) => {
|
|
18546
18576
|
const role = useHMSStore52(selectLocalPeerRole);
|
18547
18577
|
const [isVBSupported, setIsVBSupported] = useState45(false);
|
18548
18578
|
const localPeerVideoTrackID = useHMSStore52(selectLocalVideoTrackID3);
|
18549
|
-
const localPeer = useHMSStore52(
|
18579
|
+
const localPeer = useHMSStore52(selectLocalPeer4);
|
18550
18580
|
const [background, setBackground] = useState45(vbPlugin.background);
|
18551
18581
|
const [backgroundType, setBackgroundType] = useState45(vbPlugin.backgroundType);
|
18552
18582
|
const isVideoOn = useHMSStore52(selectIsLocalVideoEnabled5);
|
@@ -18557,7 +18587,8 @@ var VBPicker = ({ background_media = [] } = {}) => {
|
|
18557
18587
|
const isLargeRoom = useHMSStore52(selectIsLargeRoom3);
|
18558
18588
|
const addedPluginToVideoTrack = useRef20(false);
|
18559
18589
|
const mediaList = [...background_media.map((media) => media == null ? void 0 : media.url), ...defaultMedia2];
|
18560
|
-
const
|
18590
|
+
const inPreview = roomState === HMSRoomState4.Preview;
|
18591
|
+
const showVideoTile = isVideoOn && isLargeRoom && !inPreview;
|
18561
18592
|
const clearVBState = () => {
|
18562
18593
|
setBackground(HMSVirtualBackgroundTypes3.NONE);
|
18563
18594
|
setBackgroundType(HMSVirtualBackgroundTypes3.NONE);
|
@@ -18618,7 +18649,7 @@ var VBPicker = ({ background_media = [] } = {}) => {
|
|
18618
18649
|
if (!isVBSupported) {
|
18619
18650
|
return null;
|
18620
18651
|
}
|
18621
|
-
return /* @__PURE__ */ React109.createElement(
|
18652
|
+
return /* @__PURE__ */ React109.createElement(Flex, { css: { pr: "$6", size: "100%" }, direction: "column" }, /* @__PURE__ */ React109.createElement(Flex, { align: "center", justify: "between", css: { w: "100%", background: "$surface_dim", pb: "$4" } }, /* @__PURE__ */ React109.createElement(Text, { variant: "h6", css: { color: "$on_surface_high" } }, "Virtual Background"), /* @__PURE__ */ React109.createElement(
|
18622
18653
|
Box,
|
18623
18654
|
{
|
18624
18655
|
css: { color: "$on_surface_high", "&:hover": { color: "$on_surface_medium" }, cursor: "pointer" },
|
@@ -18631,47 +18662,60 @@ var VBPicker = ({ background_media = [] } = {}) => {
|
|
18631
18662
|
mirror: (track == null ? void 0 : track.facingMode) !== "environment" && mirrorLocalVideo,
|
18632
18663
|
trackId: localPeer == null ? void 0 : localPeer.videoTrack,
|
18633
18664
|
"data-testid": "preview_tile",
|
18634
|
-
css: { width: "100%", height: "16rem"
|
18665
|
+
css: { width: "100%", height: "16rem" }
|
18635
18666
|
}
|
18636
18667
|
) : null, /* @__PURE__ */ React109.createElement(
|
18637
|
-
|
18668
|
+
Box,
|
18638
18669
|
{
|
18639
|
-
|
18640
|
-
|
18641
|
-
|
18642
|
-
|
18643
|
-
|
18644
|
-
|
18645
|
-
|
18646
|
-
|
18647
|
-
|
18648
|
-
|
18649
|
-
|
18650
|
-
|
18651
|
-
|
18652
|
-
|
18670
|
+
css: {
|
18671
|
+
mt: "$4",
|
18672
|
+
overflowY: "auto",
|
18673
|
+
flex: "1 1 0",
|
18674
|
+
mr: "-$10",
|
18675
|
+
pr: "$10"
|
18676
|
+
}
|
18677
|
+
},
|
18678
|
+
/* @__PURE__ */ React109.createElement(
|
18679
|
+
VBCollection,
|
18680
|
+
{
|
18681
|
+
title: "Effects",
|
18682
|
+
options: [
|
18683
|
+
{
|
18684
|
+
title: "No effect",
|
18685
|
+
icon: /* @__PURE__ */ React109.createElement(CrossCircleIcon2, { style: iconDims }),
|
18686
|
+
type: HMSVirtualBackgroundTypes3.NONE,
|
18687
|
+
onClick: () => __async(void 0, null, function* () {
|
18688
|
+
return yield disableEffects();
|
18689
|
+
})
|
18690
|
+
},
|
18691
|
+
{
|
18692
|
+
title: "Blur",
|
18693
|
+
icon: /* @__PURE__ */ React109.createElement(BlurPersonHighIcon, { style: iconDims }),
|
18694
|
+
type: HMSVirtualBackgroundTypes3.BLUR,
|
18695
|
+
onClick: () => __async(void 0, null, function* () {
|
18696
|
+
return yield addPlugin({ blurPower: 0.5 });
|
18697
|
+
})
|
18698
|
+
}
|
18699
|
+
],
|
18700
|
+
activeBackgroundType: backgroundType || HMSVirtualBackgroundTypes3.NONE,
|
18701
|
+
activeBackground: ((_a7 = vbPlugin.background) == null ? void 0 : _a7.src) || vbPlugin.background || HMSVirtualBackgroundTypes3.NONE
|
18702
|
+
}
|
18703
|
+
),
|
18704
|
+
/* @__PURE__ */ React109.createElement(
|
18705
|
+
VBCollection,
|
18706
|
+
{
|
18707
|
+
title: "Backgrounds",
|
18708
|
+
options: mediaList.map((mediaURL) => ({
|
18709
|
+
type: HMSVirtualBackgroundTypes3.IMAGE,
|
18710
|
+
mediaURL,
|
18653
18711
|
onClick: () => __async(void 0, null, function* () {
|
18654
|
-
return yield addPlugin({
|
18712
|
+
return yield addPlugin({ mediaURL });
|
18655
18713
|
})
|
18656
|
-
}
|
18657
|
-
|
18658
|
-
|
18659
|
-
|
18660
|
-
|
18661
|
-
), /* @__PURE__ */ React109.createElement(
|
18662
|
-
VBCollection,
|
18663
|
-
{
|
18664
|
-
title: "Backgrounds",
|
18665
|
-
options: mediaList.map((mediaURL) => ({
|
18666
|
-
type: HMSVirtualBackgroundTypes3.IMAGE,
|
18667
|
-
mediaURL,
|
18668
|
-
onClick: () => __async(void 0, null, function* () {
|
18669
|
-
return yield addPlugin({ mediaURL });
|
18670
|
-
})
|
18671
|
-
})),
|
18672
|
-
activeBackgroundType: backgroundType || HMSVirtualBackgroundTypes3.NONE,
|
18673
|
-
activeBackground: (background == null ? void 0 : background.src) || background || HMSVirtualBackgroundTypes3.NONE
|
18674
|
-
}
|
18714
|
+
})),
|
18715
|
+
activeBackgroundType: backgroundType || HMSVirtualBackgroundTypes3.NONE,
|
18716
|
+
activeBackground: (background == null ? void 0 : background.src) || background || HMSVirtualBackgroundTypes3.NONE
|
18717
|
+
}
|
18718
|
+
)
|
18675
18719
|
));
|
18676
18720
|
};
|
18677
18721
|
|
@@ -18938,7 +18982,7 @@ var getParticipantChipContent = (peerCount = 0) => {
|
|
18938
18982
|
return `${formattedNum} other${parseInt(formattedNum) === 1 ? "" : "s"} in the session`;
|
18939
18983
|
};
|
18940
18984
|
var useLocalTileAspectRatio = () => {
|
18941
|
-
const localPeer = useHMSStore55(
|
18985
|
+
const localPeer = useHMSStore55(selectLocalPeer5);
|
18942
18986
|
const videoTrack = useHMSStore55(selectVideoTrackByID5(localPeer == null ? void 0 : localPeer.videoTrack));
|
18943
18987
|
const isMobile = useMedia20(config.media.md);
|
18944
18988
|
let aspectRatio = 0;
|
@@ -19051,7 +19095,7 @@ var PreviewJoin = ({
|
|
19051
19095
|
cannotPublishVideo: !toggleVideo,
|
19052
19096
|
cannotPublishAudio: !toggleAudio
|
19053
19097
|
}
|
19054
|
-
))), /* @__PURE__ */ React115.createElement(Box, { css: { position: "absolute", right: "0", top: 0, height: "100%" } }, /* @__PURE__ */ React115.createElement(SidePane_default, { screenType: "default" }))) : /* @__PURE__ */ React115.createElement(FullPageProgress_default, null);
|
19098
|
+
))), /* @__PURE__ */ React115.createElement(Box, { css: { position: "absolute", right: "0", top: 0, height: "100%", overflow: "hidden" } }, /* @__PURE__ */ React115.createElement(SidePane_default, { screenType: "default" }))) : /* @__PURE__ */ React115.createElement(FullPageProgress_default, null);
|
19055
19099
|
};
|
19056
19100
|
var Container4 = styled("div", __spreadProps(__spreadValues({
|
19057
19101
|
width: "100%"
|
@@ -19060,7 +19104,7 @@ var Container4 = styled("div", __spreadProps(__spreadValues({
|
|
19060
19104
|
px: "$10"
|
19061
19105
|
}));
|
19062
19106
|
var PreviewTile = ({ name, error }) => {
|
19063
|
-
const localPeer = useHMSStore55(
|
19107
|
+
const localPeer = useHMSStore55(selectLocalPeer5);
|
19064
19108
|
const { isLocalAudioEnabled, toggleAudio } = useAVToggle4();
|
19065
19109
|
const isVideoOn = useHMSStore55(selectIsLocalVideoEnabled6);
|
19066
19110
|
const mirrorLocalVideo = useUISettings(UI_SETTINGS.mirrorLocalVideo);
|
@@ -19149,7 +19193,7 @@ var RoleChangeRequestModal = () => {
|
|
19149
19193
|
const { updateMetaData } = useMyMetadata();
|
19150
19194
|
const currentRole = useHMSStore56(selectLocalPeerRoleName5);
|
19151
19195
|
const roleChangeRequest = useHMSStore56(selectRoleChangeRequest);
|
19152
|
-
const name = useHMSStore56(
|
19196
|
+
const name = useHMSStore56(selectLocalPeerName3);
|
19153
19197
|
const { sendEvent } = useCustomEvent3({ type: ROLE_CHANGE_DECLINED });
|
19154
19198
|
const { elements = {} } = useRoomLayoutPreviewScreen();
|
19155
19199
|
const { virtual_background } = elements || {};
|
@@ -19216,362 +19260,118 @@ var RoleChangeRequestModal = () => {
|
|
19216
19260
|
|
19217
19261
|
// src/Prebuilt/layouts/VideoStreamingSection.tsx
|
19218
19262
|
init_define_process_env();
|
19219
|
-
import
|
19220
|
-
import {
|
19221
|
-
import {
|
19222
|
-
selectIsConnectedToRoom as selectIsConnectedToRoom9,
|
19223
|
-
selectLocalPeerName as selectLocalPeerName6,
|
19224
|
-
selectLocalPeerRoleName as selectLocalPeerRoleName6,
|
19225
|
-
selectSessionStore as selectSessionStore7,
|
19226
|
-
useHMSActions as useHMSActions40,
|
19227
|
-
useHMSStore as useHMSStore65
|
19228
|
-
} from "@100mslive/react-sdk";
|
19263
|
+
import React133, { Suspense, useEffect as useEffect41 } from "react";
|
19264
|
+
import { selectIsConnectedToRoom as selectIsConnectedToRoom9, selectLocalPeerRoleName as selectLocalPeerRoleName6, useHMSActions as useHMSActions39, useHMSStore as useHMSStore64 } from "@100mslive/react-sdk";
|
19229
19265
|
|
19230
|
-
// src/Prebuilt/components/
|
19266
|
+
// src/Prebuilt/components/VideoLayouts/GridLayout.tsx
|
19231
19267
|
init_define_process_env();
|
19268
|
+
import React129, { useEffect as useEffect38, useMemo as useMemo14, useState as useState54 } from "react";
|
19269
|
+
import { selectPeers as selectPeers3, selectPeerScreenSharing, useHMSStore as useHMSStore62, useHMSVanillaStore as useHMSVanillaStore10 } from "@100mslive/react-sdk";
|
19232
19270
|
|
19233
|
-
// src/Prebuilt/components/
|
19271
|
+
// src/Prebuilt/components/VideoLayouts/EqualProminence.tsx
|
19234
19272
|
init_define_process_env();
|
19235
|
-
import
|
19236
|
-
import {
|
19237
|
-
import {
|
19238
|
-
|
19239
|
-
|
19240
|
-
|
19241
|
-
|
19242
|
-
|
19243
|
-
|
19244
|
-
|
19245
|
-
} from "@100mslive/react-icons";
|
19246
|
-
|
19247
|
-
|
19248
|
-
|
19249
|
-
|
19250
|
-
|
19251
|
-
|
19252
|
-
|
19273
|
+
import React122, { useEffect as useEffect34, useMemo as useMemo11, useState as useState49 } from "react";
|
19274
|
+
import { useMedia as useMedia24 } from "react-use";
|
19275
|
+
import { selectLocalPeer as selectLocalPeer7, useHMSStore as useHMSStore58 } from "@100mslive/react-sdk";
|
19276
|
+
|
19277
|
+
// src/Prebuilt/components/InsetTile.tsx
|
19278
|
+
init_define_process_env();
|
19279
|
+
import React119, { useEffect as useEffect31, useRef as useRef21 } from "react";
|
19280
|
+
import Draggable from "react-draggable";
|
19281
|
+
import { useMedia as useMedia22 } from "react-use";
|
19282
|
+
import { selectIsAllowedToPublish as selectIsAllowedToPublish2, selectLocalPeer as selectLocalPeer6, selectVideoTrackByID as selectVideoTrackByID6, useHMSStore as useHMSStore57 } from "@100mslive/react-sdk";
|
19283
|
+
import { ExpandIcon as ExpandIcon2 } from "@100mslive/react-icons";
|
19284
|
+
|
19285
|
+
// src/Prebuilt/components/hooks/useVideoTileLayout.ts
|
19286
|
+
init_define_process_env();
|
19287
|
+
import React118, { useContext as useContext3 } from "react";
|
19288
|
+
var VideoTileContext = React118.createContext({
|
19289
|
+
enableSpotlightingPeer: true,
|
19290
|
+
hideParticipantNameOnTile: false,
|
19291
|
+
roundedVideoTile: true,
|
19292
|
+
hideAudioMuteOnTile: false,
|
19293
|
+
hideAudioLevelOnTile: false,
|
19294
|
+
objectFit: "contain",
|
19295
|
+
hideMetadataOnTile: false
|
19253
19296
|
});
|
19254
|
-
var
|
19255
|
-
|
19256
|
-
|
19257
|
-
|
19258
|
-
|
19259
|
-
|
19260
|
-
|
19261
|
-
|
19262
|
-
|
19263
|
-
|
19264
|
-
|
19265
|
-
|
19266
|
-
|
19267
|
-
|
19268
|
-
|
19269
|
-
|
19270
|
-
|
19297
|
+
var useVideoTileContext = () => {
|
19298
|
+
const context = useContext3(VideoTileContext);
|
19299
|
+
return context;
|
19300
|
+
};
|
19301
|
+
|
19302
|
+
// src/Prebuilt/components/InsetTile.tsx
|
19303
|
+
var MinimisedTile = ({ setMinimised }) => {
|
19304
|
+
return /* @__PURE__ */ React119.createElement(Flex, { align: "center", css: { gap: "$6", r: "$1", bg: "$surface_default", p: "$4", color: "$on_surface_high" } }, /* @__PURE__ */ React119.createElement(AudioVideoToggle, { hideOptions: true }), /* @__PURE__ */ React119.createElement(Text, null, "You"), /* @__PURE__ */ React119.createElement(
|
19305
|
+
IconButton_default,
|
19306
|
+
{
|
19307
|
+
className: "__cancel-drag-event",
|
19308
|
+
onClick: () => setMinimised(false),
|
19309
|
+
css: { bg: "transparent", border: "transparent" }
|
19310
|
+
},
|
19311
|
+
/* @__PURE__ */ React119.createElement(ExpandIcon2, null)
|
19312
|
+
));
|
19313
|
+
};
|
19314
|
+
var insetHeightPx = 180;
|
19315
|
+
var insetMaxWidthPx = 240;
|
19316
|
+
var defaultMobileAspectRatio = 9 / 16;
|
19317
|
+
var desktopAspectRatio = 1 / defaultMobileAspectRatio;
|
19318
|
+
var InsetTile = () => {
|
19319
|
+
const isMobile = useMedia22(config.media.md);
|
19320
|
+
const isLandscape = useMedia22(config.media.ls);
|
19321
|
+
const localPeer = useHMSStore57(selectLocalPeer6);
|
19322
|
+
const [minimised, setMinimised] = useSetAppDataByKey(APP_DATA.minimiseInset);
|
19323
|
+
const videoTrack = useHMSStore57(selectVideoTrackByID6(localPeer == null ? void 0 : localPeer.videoTrack));
|
19324
|
+
const isAllowedToPublish = useHMSStore57(selectIsAllowedToPublish2);
|
19325
|
+
const videoTileProps = useVideoTileContext();
|
19326
|
+
let aspectRatio = isMobile ? defaultMobileAspectRatio : desktopAspectRatio;
|
19327
|
+
if ((videoTrack == null ? void 0 : videoTrack.width) && (videoTrack == null ? void 0 : videoTrack.height) && !isMobile) {
|
19328
|
+
aspectRatio = videoTrack.width / videoTrack.height;
|
19329
|
+
}
|
19330
|
+
let height = insetHeightPx;
|
19331
|
+
let width = height * aspectRatio;
|
19332
|
+
if (isLandscape && width > insetMaxWidthPx) {
|
19333
|
+
width = 240;
|
19334
|
+
height = width / aspectRatio;
|
19335
|
+
}
|
19336
|
+
const nodeRef = useRef21(null);
|
19337
|
+
useEffect31(() => {
|
19338
|
+
const node = nodeRef.current;
|
19339
|
+
if (!node || !window.ResizeObserver) {
|
19340
|
+
return;
|
19271
19341
|
}
|
19272
|
-
|
19273
|
-
|
19342
|
+
const resizeObserver = new ResizeObserver((entries) => {
|
19343
|
+
entries.forEach((entry) => {
|
19344
|
+
if (entry.target === node.parentElement) {
|
19345
|
+
node.style.transform = `translate(0,0)`;
|
19346
|
+
}
|
19347
|
+
});
|
19348
|
+
});
|
19349
|
+
node.parentElement && resizeObserver.observe(node.parentElement);
|
19350
|
+
return () => {
|
19351
|
+
(node == null ? void 0 : node.parentElement) && (resizeObserver == null ? void 0 : resizeObserver.unobserve(node.parentElement));
|
19352
|
+
resizeObserver == null ? void 0 : resizeObserver.disconnect();
|
19353
|
+
};
|
19354
|
+
}, []);
|
19355
|
+
if (!isAllowedToPublish.video && !isAllowedToPublish.audio) {
|
19274
19356
|
return null;
|
19275
19357
|
}
|
19276
|
-
return /* @__PURE__ */
|
19277
|
-
|
19278
|
-
|
19279
|
-
|
19280
|
-
|
19281
|
-
|
19282
|
-
|
19283
|
-
|
19284
|
-
|
19285
|
-
|
19286
|
-
|
19287
|
-
}
|
19288
|
-
|
19289
|
-
|
19290
|
-
|
19291
|
-
};
|
19292
|
-
},
|
19293
|
-
multiple: (notifications) => {
|
19294
|
-
return {
|
19295
|
-
title: `${notifications[0].data.name} and ${notifications.length - 1} others joined`,
|
19296
|
-
icon: /* @__PURE__ */ React118.createElement(PeopleAddIcon2, null)
|
19297
|
-
};
|
19298
|
-
}
|
19299
|
-
},
|
19300
|
-
PEER_JOINED: {
|
19301
|
-
single: function(notification) {
|
19302
|
-
var _a7;
|
19303
|
-
return {
|
19304
|
-
title: `${(_a7 = notification.data) == null ? void 0 : _a7.name} joined`,
|
19305
|
-
icon: /* @__PURE__ */ React118.createElement(PeopleAddIcon2, null)
|
19306
|
-
};
|
19307
|
-
},
|
19308
|
-
multiple: function(notifications) {
|
19309
|
-
return {
|
19310
|
-
title: `${notifications[notifications.length - 1].data.name} and ${notifications.length - 1} others joined`,
|
19311
|
-
icon: /* @__PURE__ */ React118.createElement(PeopleAddIcon2, null)
|
19312
|
-
};
|
19313
|
-
}
|
19314
|
-
},
|
19315
|
-
PEER_LEFT: {
|
19316
|
-
single: function(notification) {
|
19317
|
-
var _a7;
|
19318
|
-
return {
|
19319
|
-
title: `${(_a7 = notification.data) == null ? void 0 : _a7.name} left`,
|
19320
|
-
icon: /* @__PURE__ */ React118.createElement(PeopleRemoveIcon3, null)
|
19321
|
-
};
|
19358
|
+
return /* @__PURE__ */ React119.createElement(Draggable, { bounds: "parent", nodeRef, cancel: ".__cancel-drag-event" }, /* @__PURE__ */ React119.createElement(
|
19359
|
+
Box,
|
19360
|
+
{
|
19361
|
+
ref: nodeRef,
|
19362
|
+
css: __spreadValues({
|
19363
|
+
position: "absolute",
|
19364
|
+
bottom: 0,
|
19365
|
+
right: 0,
|
19366
|
+
zIndex: 11,
|
19367
|
+
boxShadow: "0 0 8px 0 rgba(0,0,0,0.3)",
|
19368
|
+
r: "$2"
|
19369
|
+
}, !minimised ? {
|
19370
|
+
aspectRatio,
|
19371
|
+
h: height
|
19372
|
+
} : {})
|
19322
19373
|
},
|
19323
|
-
|
19324
|
-
return {
|
19325
|
-
title: `${notifications[notifications.length - 1].data.name} and ${notifications.length - 1} others left`,
|
19326
|
-
icon: /* @__PURE__ */ React118.createElement(PeopleRemoveIcon3, null)
|
19327
|
-
};
|
19328
|
-
}
|
19329
|
-
},
|
19330
|
-
RAISE_HAND: {
|
19331
|
-
single: (notification) => {
|
19332
|
-
var _a7, _b7;
|
19333
|
-
return {
|
19334
|
-
title: `${(_a7 = notification.data) == null ? void 0 : _a7.name} raised hand`,
|
19335
|
-
icon: /* @__PURE__ */ React118.createElement(HandIcon6, null),
|
19336
|
-
action: /* @__PURE__ */ React118.createElement(HandRaiseAction, { id: (_b7 = notification.data) == null ? void 0 : _b7.id })
|
19337
|
-
};
|
19338
|
-
},
|
19339
|
-
multiple: (notifications) => {
|
19340
|
-
var _a7;
|
19341
|
-
const count = new Set(notifications.map((notification) => {
|
19342
|
-
var _a8;
|
19343
|
-
return (_a8 = notification.data) == null ? void 0 : _a8.id;
|
19344
|
-
})).size;
|
19345
|
-
return {
|
19346
|
-
title: `${(_a7 = notifications[notifications.length - 1].data) == null ? void 0 : _a7.name} ${count > 1 ? `${count} and others` : ""} raised hand`,
|
19347
|
-
icon: /* @__PURE__ */ React118.createElement(HandIcon6, null),
|
19348
|
-
action: /* @__PURE__ */ React118.createElement(HandRaiseAction, { isSingleHandRaise: false })
|
19349
|
-
};
|
19350
|
-
}
|
19351
|
-
},
|
19352
|
-
NEW_MESSAGE: {
|
19353
|
-
single: (notification) => {
|
19354
|
-
var _a7;
|
19355
|
-
return {
|
19356
|
-
title: `New message from ${(_a7 = notification.data) == null ? void 0 : _a7.senderName}`,
|
19357
|
-
icon: /* @__PURE__ */ React118.createElement(ChatUnreadIcon2, null),
|
19358
|
-
action: /* @__PURE__ */ React118.createElement(ChatAction, null)
|
19359
|
-
};
|
19360
|
-
},
|
19361
|
-
multiple: (notifications) => {
|
19362
|
-
return {
|
19363
|
-
title: `${notifications.length} new messages`,
|
19364
|
-
icon: /* @__PURE__ */ React118.createElement(ChatUnreadIcon2, null),
|
19365
|
-
action: /* @__PURE__ */ React118.createElement(ChatAction, null)
|
19366
|
-
};
|
19367
|
-
}
|
19368
|
-
},
|
19369
|
-
CHAT_PAUSED: {
|
19370
|
-
single: (notification) => {
|
19371
|
-
var _a7;
|
19372
|
-
return {
|
19373
|
-
title: `Chat paused by ${(_a7 = notification.data) == null ? void 0 : _a7.name}`,
|
19374
|
-
icon: /* @__PURE__ */ React118.createElement(ChatIcon2, null),
|
19375
|
-
action: /* @__PURE__ */ React118.createElement(ChatAction, null)
|
19376
|
-
};
|
19377
|
-
}
|
19378
|
-
},
|
19379
|
-
CHAT_RESUMED: {
|
19380
|
-
single: (notification) => {
|
19381
|
-
var _a7;
|
19382
|
-
return {
|
19383
|
-
title: `Chat resumed by ${(_a7 = notification.data) == null ? void 0 : _a7.name}`,
|
19384
|
-
icon: /* @__PURE__ */ React118.createElement(ChatUnreadIcon2, null),
|
19385
|
-
action: /* @__PURE__ */ React118.createElement(ChatAction, null)
|
19386
|
-
};
|
19387
|
-
}
|
19388
|
-
},
|
19389
|
-
RECONNECTED: {
|
19390
|
-
single: () => {
|
19391
|
-
return {
|
19392
|
-
title: `You are now connected`,
|
19393
|
-
icon: /* @__PURE__ */ React118.createElement(ConnectivityIcon, null),
|
19394
|
-
variant: "success",
|
19395
|
-
duration: 3e3
|
19396
|
-
};
|
19397
|
-
}
|
19398
|
-
},
|
19399
|
-
RECONNECTING: {
|
19400
|
-
single: (message) => {
|
19401
|
-
return {
|
19402
|
-
title: `You are offline for now. while we try to reconnect, please check
|
19403
|
-
your internet connection. ${message}.
|
19404
|
-
`,
|
19405
|
-
icon: /* @__PURE__ */ React118.createElement(PoorConnectivityIcon2, null),
|
19406
|
-
variant: "warning",
|
19407
|
-
duration: 3e4
|
19408
|
-
};
|
19409
|
-
}
|
19410
|
-
}
|
19411
|
-
};
|
19412
|
-
|
19413
|
-
// src/Prebuilt/components/Toast/ToastBatcher.js
|
19414
|
-
var ToastBatcher = {
|
19415
|
-
toastsType: /* @__PURE__ */ new Map(),
|
19416
|
-
showToastInternal({ notification, duration, type }) {
|
19417
|
-
let notificationType = type;
|
19418
|
-
if (!type) {
|
19419
|
-
notificationType = notification.type;
|
19420
|
-
}
|
19421
|
-
const toastType = this.toastsType.has(notificationType);
|
19422
|
-
if (toastType) {
|
19423
|
-
let { notifications } = this.toastsType.get(notificationType);
|
19424
|
-
const { id } = this.toastsType.get(notificationType);
|
19425
|
-
notifications.push(notification);
|
19426
|
-
const toastObject = ToastConfig[notificationType].multiple(notifications);
|
19427
|
-
const toastId = ToastManager.replaceToast(id, __spreadProps(__spreadValues({}, toastObject), {
|
19428
|
-
duration
|
19429
|
-
}));
|
19430
|
-
this.toastsType.set(notificationType, {
|
19431
|
-
id: toastId,
|
19432
|
-
notifications,
|
19433
|
-
duration
|
19434
|
-
});
|
19435
|
-
} else {
|
19436
|
-
const toastObject = ToastConfig[notificationType].single(notification);
|
19437
|
-
const toastId = ToastManager.addToast(__spreadProps(__spreadValues({}, toastObject), {
|
19438
|
-
duration
|
19439
|
-
}));
|
19440
|
-
let notifications = [];
|
19441
|
-
notifications.push(notification);
|
19442
|
-
this.toastsType.set(notificationType, {
|
19443
|
-
id: toastId,
|
19444
|
-
notifications: [...notifications],
|
19445
|
-
duration
|
19446
|
-
});
|
19447
|
-
}
|
19448
|
-
},
|
19449
|
-
showToast({ notification, duration = 3e3, type }) {
|
19450
|
-
try {
|
19451
|
-
this.showToastInternal({ notification, duration, type });
|
19452
|
-
} catch (err) {
|
19453
|
-
console.debug("Notifications", err);
|
19454
|
-
}
|
19455
|
-
},
|
19456
|
-
syncUItoast(toastsDisplaying) {
|
19457
|
-
for (const [toastType, toastInfo] of this.toastsType.entries()) {
|
19458
|
-
if (!toastsDisplaying.find((toast) => toast.id === toastInfo.id)) {
|
19459
|
-
this.toastsType.delete(toastType);
|
19460
|
-
}
|
19461
|
-
}
|
19462
|
-
}
|
19463
|
-
};
|
19464
|
-
ToastManager.addListener(ToastBatcher.syncUItoast.bind(ToastBatcher));
|
19465
|
-
|
19466
|
-
// src/Prebuilt/components/VideoLayouts/GridLayout.tsx
|
19467
|
-
init_define_process_env();
|
19468
|
-
import React130, { useEffect as useEffect38, useMemo as useMemo14, useState as useState54 } from "react";
|
19469
|
-
import { selectPeers as selectPeers3, selectPeerScreenSharing, useHMSStore as useHMSStore63, useHMSVanillaStore as useHMSVanillaStore10 } from "@100mslive/react-sdk";
|
19470
|
-
|
19471
|
-
// src/Prebuilt/components/VideoLayouts/EqualProminence.tsx
|
19472
|
-
init_define_process_env();
|
19473
|
-
import React123, { useEffect as useEffect34, useMemo as useMemo11, useState as useState49 } from "react";
|
19474
|
-
import { useMedia as useMedia24 } from "react-use";
|
19475
|
-
import { selectLocalPeer as selectLocalPeer4, useHMSStore as useHMSStore59 } from "@100mslive/react-sdk";
|
19476
|
-
|
19477
|
-
// src/Prebuilt/components/InsetTile.tsx
|
19478
|
-
init_define_process_env();
|
19479
|
-
import React120, { useEffect as useEffect31, useRef as useRef21 } from "react";
|
19480
|
-
import Draggable from "react-draggable";
|
19481
|
-
import { useMedia as useMedia22 } from "react-use";
|
19482
|
-
import { selectIsAllowedToPublish as selectIsAllowedToPublish2, selectLocalPeer as selectLocalPeer3, selectVideoTrackByID as selectVideoTrackByID6, useHMSStore as useHMSStore58 } from "@100mslive/react-sdk";
|
19483
|
-
import { ExpandIcon as ExpandIcon2 } from "@100mslive/react-icons";
|
19484
|
-
|
19485
|
-
// src/Prebuilt/components/hooks/useVideoTileLayout.ts
|
19486
|
-
init_define_process_env();
|
19487
|
-
import React119, { useContext as useContext3 } from "react";
|
19488
|
-
var VideoTileContext = React119.createContext({
|
19489
|
-
enableSpotlightingPeer: true,
|
19490
|
-
hideParticipantNameOnTile: false,
|
19491
|
-
roundedVideoTile: true,
|
19492
|
-
hideAudioMuteOnTile: false,
|
19493
|
-
hideAudioLevelOnTile: false,
|
19494
|
-
objectFit: "contain",
|
19495
|
-
hideMetadataOnTile: false
|
19496
|
-
});
|
19497
|
-
var useVideoTileContext = () => {
|
19498
|
-
const context = useContext3(VideoTileContext);
|
19499
|
-
return context;
|
19500
|
-
};
|
19501
|
-
|
19502
|
-
// src/Prebuilt/components/InsetTile.tsx
|
19503
|
-
var MinimisedTile = ({ setMinimised }) => {
|
19504
|
-
return /* @__PURE__ */ React120.createElement(Flex, { align: "center", css: { gap: "$6", r: "$1", bg: "$surface_default", p: "$4", color: "$on_surface_high" } }, /* @__PURE__ */ React120.createElement(AudioVideoToggle, { hideOptions: true }), /* @__PURE__ */ React120.createElement(Text, null, "You"), /* @__PURE__ */ React120.createElement(
|
19505
|
-
IconButton_default,
|
19506
|
-
{
|
19507
|
-
className: "__cancel-drag-event",
|
19508
|
-
onClick: () => setMinimised(false),
|
19509
|
-
css: { bg: "transparent", border: "transparent" }
|
19510
|
-
},
|
19511
|
-
/* @__PURE__ */ React120.createElement(ExpandIcon2, null)
|
19512
|
-
));
|
19513
|
-
};
|
19514
|
-
var insetHeightPx = 180;
|
19515
|
-
var insetMaxWidthPx = 240;
|
19516
|
-
var defaultMobileAspectRatio = 9 / 16;
|
19517
|
-
var desktopAspectRatio = 1 / defaultMobileAspectRatio;
|
19518
|
-
var InsetTile = () => {
|
19519
|
-
const isMobile = useMedia22(config.media.md);
|
19520
|
-
const isLandscape = useMedia22(config.media.ls);
|
19521
|
-
const localPeer = useHMSStore58(selectLocalPeer3);
|
19522
|
-
const [minimised, setMinimised] = useSetAppDataByKey(APP_DATA.minimiseInset);
|
19523
|
-
const videoTrack = useHMSStore58(selectVideoTrackByID6(localPeer == null ? void 0 : localPeer.videoTrack));
|
19524
|
-
const isAllowedToPublish = useHMSStore58(selectIsAllowedToPublish2);
|
19525
|
-
const videoTileProps = useVideoTileContext();
|
19526
|
-
let aspectRatio = isMobile ? defaultMobileAspectRatio : desktopAspectRatio;
|
19527
|
-
if ((videoTrack == null ? void 0 : videoTrack.width) && (videoTrack == null ? void 0 : videoTrack.height) && !isMobile) {
|
19528
|
-
aspectRatio = videoTrack.width / videoTrack.height;
|
19529
|
-
}
|
19530
|
-
let height = insetHeightPx;
|
19531
|
-
let width = height * aspectRatio;
|
19532
|
-
if (isLandscape && width > insetMaxWidthPx) {
|
19533
|
-
width = 240;
|
19534
|
-
height = width / aspectRatio;
|
19535
|
-
}
|
19536
|
-
const nodeRef = useRef21(null);
|
19537
|
-
useEffect31(() => {
|
19538
|
-
const node = nodeRef.current;
|
19539
|
-
if (!node || !window.ResizeObserver) {
|
19540
|
-
return;
|
19541
|
-
}
|
19542
|
-
const resizeObserver = new ResizeObserver((entries) => {
|
19543
|
-
entries.forEach((entry) => {
|
19544
|
-
if (entry.target === node.parentElement) {
|
19545
|
-
node.style.transform = `translate(0,0)`;
|
19546
|
-
}
|
19547
|
-
});
|
19548
|
-
});
|
19549
|
-
node.parentElement && resizeObserver.observe(node.parentElement);
|
19550
|
-
return () => {
|
19551
|
-
(node == null ? void 0 : node.parentElement) && (resizeObserver == null ? void 0 : resizeObserver.unobserve(node.parentElement));
|
19552
|
-
resizeObserver == null ? void 0 : resizeObserver.disconnect();
|
19553
|
-
};
|
19554
|
-
}, []);
|
19555
|
-
if (!isAllowedToPublish.video && !isAllowedToPublish.audio) {
|
19556
|
-
return null;
|
19557
|
-
}
|
19558
|
-
return /* @__PURE__ */ React120.createElement(Draggable, { bounds: "parent", nodeRef, cancel: ".__cancel-drag-event" }, /* @__PURE__ */ React120.createElement(
|
19559
|
-
Box,
|
19560
|
-
{
|
19561
|
-
ref: nodeRef,
|
19562
|
-
css: __spreadValues({
|
19563
|
-
position: "absolute",
|
19564
|
-
bottom: 0,
|
19565
|
-
right: 0,
|
19566
|
-
zIndex: 11,
|
19567
|
-
boxShadow: "0 0 8px 0 rgba(0,0,0,0.3)",
|
19568
|
-
r: "$2"
|
19569
|
-
}, !minimised ? {
|
19570
|
-
aspectRatio,
|
19571
|
-
h: height
|
19572
|
-
} : {})
|
19573
|
-
},
|
19574
|
-
minimised ? /* @__PURE__ */ React120.createElement(MinimisedTile, { setMinimised }) : /* @__PURE__ */ React120.createElement(
|
19374
|
+
minimised ? /* @__PURE__ */ React119.createElement(MinimisedTile, { setMinimised }) : /* @__PURE__ */ React119.createElement(
|
19575
19375
|
VideoTile_default,
|
19576
19376
|
__spreadProps(__spreadValues({
|
19577
19377
|
peerId: localPeer == null ? void 0 : localPeer.id,
|
@@ -19594,7 +19394,7 @@ var InsetTile = () => {
|
|
19594
19394
|
|
19595
19395
|
// src/Prebuilt/components/Pagination.tsx
|
19596
19396
|
init_define_process_env();
|
19597
|
-
import
|
19397
|
+
import React120, { useEffect as useEffect32 } from "react";
|
19598
19398
|
import { ChevronLeftIcon as ChevronLeftIcon7, ChevronRightIcon as ChevronRightIcon4 } from "@100mslive/react-icons";
|
19599
19399
|
var Pagination = ({
|
19600
19400
|
page,
|
@@ -19619,7 +19419,7 @@ var Pagination = ({
|
|
19619
19419
|
if (numPages <= 1) {
|
19620
19420
|
return null;
|
19621
19421
|
}
|
19622
|
-
return /* @__PURE__ */
|
19422
|
+
return /* @__PURE__ */ React120.createElement(StyledPagination.Root, { css: { flexShrink: 0 } }, /* @__PURE__ */ React120.createElement(StyledPagination.Chevron, { disabled: disableLeft, onClick: prevPage }, /* @__PURE__ */ React120.createElement(ChevronLeftIcon7, { width: 16, height: 16, style: { cursor: disableLeft ? "not-allowed" : "pointer" } })), numPages <= 5 ? /* @__PURE__ */ React120.createElement(StyledPagination.Dots, null, [...Array(numPages)].map((_3, i) => /* @__PURE__ */ React120.createElement(
|
19623
19423
|
StyledPagination.Dot,
|
19624
19424
|
{
|
19625
19425
|
key: i,
|
@@ -19629,16 +19429,16 @@ var Pagination = ({
|
|
19629
19429
|
onPageChange(i);
|
19630
19430
|
}
|
19631
19431
|
}
|
19632
|
-
))) : null, /* @__PURE__ */
|
19432
|
+
))) : null, /* @__PURE__ */ React120.createElement(StyledPagination.Chevron, { disabled: disableRight, onClick: nextPage }, /* @__PURE__ */ React120.createElement(ChevronRightIcon4, { width: 16, height: 16, style: { cursor: disableRight ? "not-allowed" : "pointer" } })));
|
19633
19433
|
};
|
19634
19434
|
|
19635
19435
|
// src/Prebuilt/components/VideoLayouts/Grid.tsx
|
19636
19436
|
init_define_process_env();
|
19637
|
-
import
|
19638
|
-
var Grid =
|
19437
|
+
import React121 from "react";
|
19438
|
+
var Grid = React121.forwardRef(
|
19639
19439
|
({ tiles, edgeToEdge }, ref) => {
|
19640
19440
|
const videoTileProps = useVideoTileContext();
|
19641
|
-
return /* @__PURE__ */
|
19441
|
+
return /* @__PURE__ */ React121.createElement(
|
19642
19442
|
Box,
|
19643
19443
|
{
|
19644
19444
|
ref,
|
@@ -19656,7 +19456,7 @@ var Grid = React122.forwardRef(
|
|
19656
19456
|
},
|
19657
19457
|
tiles == null ? void 0 : tiles.map((tile) => {
|
19658
19458
|
var _a7, _b7, _c, _d;
|
19659
|
-
return /* @__PURE__ */
|
19459
|
+
return /* @__PURE__ */ React121.createElement(
|
19660
19460
|
VideoTile_default,
|
19661
19461
|
__spreadValues({
|
19662
19462
|
key: ((_a7 = tile.track) == null ? void 0 : _a7.id) || ((_b7 = tile.peer) == null ? void 0 : _b7.id),
|
@@ -19781,7 +19581,7 @@ var useTileLayout = ({
|
|
19781
19581
|
// src/Prebuilt/components/VideoLayouts/EqualProminence.tsx
|
19782
19582
|
function EqualProminence({ isInsetEnabled = false, peers, onPageChange, onPageSize, edgeToEdge }) {
|
19783
19583
|
var _a7;
|
19784
|
-
const localPeer =
|
19584
|
+
const localPeer = useHMSStore58(selectLocalPeer7);
|
19785
19585
|
const isMobile = useMedia24(config.media.md);
|
19786
19586
|
let maxTileCount = useUISettings(UI_SETTINGS.maxTileCount);
|
19787
19587
|
maxTileCount = isMobile ? Math.min(maxTileCount, 6) : maxTileCount;
|
@@ -19809,7 +19609,7 @@ function EqualProminence({ isInsetEnabled = false, peers, onPageChange, onPageSi
|
|
19809
19609
|
onPageSize == null ? void 0 : onPageSize(pageSize);
|
19810
19610
|
}
|
19811
19611
|
}, [pageSize, onPageSize]);
|
19812
|
-
return /* @__PURE__ */
|
19612
|
+
return /* @__PURE__ */ React122.createElement(Flex, { direction: "column", css: { flex: "1 1 0", h: "100%", position: "relative", minWidth: 0 } }, /* @__PURE__ */ React122.createElement(Grid, { tiles: pagesWithTiles[page], ref, edgeToEdge }), !edgeToEdge && /* @__PURE__ */ React122.createElement(
|
19813
19613
|
Pagination,
|
19814
19614
|
{
|
19815
19615
|
page,
|
@@ -19819,23 +19619,23 @@ function EqualProminence({ isInsetEnabled = false, peers, onPageChange, onPageSi
|
|
19819
19619
|
},
|
19820
19620
|
numPages: pagesWithTiles.length
|
19821
19621
|
}
|
19822
|
-
), isInsetEnabled && pageList.length > 0 && pageList[0][0].peer.id !== (localPeer == null ? void 0 : localPeer.id) && /* @__PURE__ */
|
19622
|
+
), isInsetEnabled && pageList.length > 0 && pageList[0][0].peer.id !== (localPeer == null ? void 0 : localPeer.id) && /* @__PURE__ */ React122.createElement(InsetTile, null));
|
19823
19623
|
}
|
19824
19624
|
|
19825
19625
|
// src/Prebuilt/components/VideoLayouts/RoleProminence.tsx
|
19826
19626
|
init_define_process_env();
|
19827
|
-
import
|
19828
|
-
import { selectLocalPeer as
|
19627
|
+
import React125, { useEffect as useEffect36, useState as useState51 } from "react";
|
19628
|
+
import { selectLocalPeer as selectLocalPeer8, useHMSStore as useHMSStore59 } from "@100mslive/react-sdk";
|
19829
19629
|
|
19830
19630
|
// src/Prebuilt/components/SecondaryTiles.tsx
|
19831
19631
|
init_define_process_env();
|
19832
|
-
import
|
19632
|
+
import React124, { useEffect as useEffect35, useState as useState50 } from "react";
|
19833
19633
|
import { useMedia as useMedia25 } from "react-use";
|
19834
19634
|
|
19835
19635
|
// src/Prebuilt/components/VideoLayouts/ProminenceLayout.tsx
|
19836
19636
|
init_define_process_env();
|
19837
|
-
import
|
19838
|
-
var Root26 = ({ children, edgeToEdge }) => /* @__PURE__ */
|
19637
|
+
import React123 from "react";
|
19638
|
+
var Root26 = ({ children, edgeToEdge }) => /* @__PURE__ */ React123.createElement(
|
19839
19639
|
Flex,
|
19840
19640
|
{
|
19841
19641
|
direction: "column",
|
@@ -19844,7 +19644,7 @@ var Root26 = ({ children, edgeToEdge }) => /* @__PURE__ */ React124.createElemen
|
|
19844
19644
|
children
|
19845
19645
|
);
|
19846
19646
|
var ProminentSection = ({ children, css: css2 = {} }) => {
|
19847
|
-
return /* @__PURE__ */
|
19647
|
+
return /* @__PURE__ */ React123.createElement(Flex, { direction: "column", css: __spreadValues({ flex: "1 1 0", gap: "$2", minHeight: 0 }, css2) }, children);
|
19848
19648
|
};
|
19849
19649
|
var SecondarySection = ({
|
19850
19650
|
tiles,
|
@@ -19855,12 +19655,12 @@ var SecondarySection = ({
|
|
19855
19655
|
if (!(tiles == null ? void 0 : tiles.length)) {
|
19856
19656
|
return null;
|
19857
19657
|
}
|
19858
|
-
return /* @__PURE__ */
|
19658
|
+
return /* @__PURE__ */ React123.createElement(
|
19859
19659
|
Box,
|
19860
19660
|
{
|
19861
19661
|
css: {
|
19862
19662
|
display: "grid",
|
19863
|
-
gridTemplateRows:
|
19663
|
+
gridTemplateRows: React123.Children.count(children) > 0 ? "136px auto" : "154px",
|
19864
19664
|
gridTemplateColumns: `repeat(${tiles.length}, minmax(0, 1fr))`,
|
19865
19665
|
margin: "0 auto",
|
19866
19666
|
gap: "$2 $4",
|
@@ -19870,7 +19670,7 @@ var SecondarySection = ({
|
|
19870
19670
|
},
|
19871
19671
|
tiles.map((tile) => {
|
19872
19672
|
var _a7, _b7, _c, _d;
|
19873
|
-
return /* @__PURE__ */
|
19673
|
+
return /* @__PURE__ */ React123.createElement(
|
19874
19674
|
VideoTile_default,
|
19875
19675
|
__spreadValues({
|
19876
19676
|
key: ((_a7 = tile.track) == null ? void 0 : _a7.id) || ((_b7 = tile.peer) == null ? void 0 : _b7.id),
|
@@ -19887,7 +19687,7 @@ var SecondarySection = ({
|
|
19887
19687
|
}, tileLayoutProps)
|
19888
19688
|
);
|
19889
19689
|
}),
|
19890
|
-
/* @__PURE__ */
|
19690
|
+
/* @__PURE__ */ React123.createElement(Box, { css: { gridColumn: `1/span ${tiles.length}` } }, children)
|
19891
19691
|
);
|
19892
19692
|
};
|
19893
19693
|
var ProminenceLayout = {
|
@@ -19909,7 +19709,7 @@ var SecondaryTiles = ({ peers, onPageChange, onPageSize, edgeToEdge }) => {
|
|
19909
19709
|
onPageSize == null ? void 0 : onPageSize(pageSize);
|
19910
19710
|
}
|
19911
19711
|
}, [pageSize, onPageSize]);
|
19912
|
-
return /* @__PURE__ */
|
19712
|
+
return /* @__PURE__ */ React124.createElement(ProminenceLayout.SecondarySection, { tiles: pagesWithTiles[page], edgeToEdge }, !edgeToEdge && /* @__PURE__ */ React124.createElement(
|
19913
19713
|
Pagination,
|
19914
19714
|
{
|
19915
19715
|
page,
|
@@ -19968,7 +19768,7 @@ function RoleProminence({
|
|
19968
19768
|
}) {
|
19969
19769
|
var _a7;
|
19970
19770
|
const { prominentPeers, secondaryPeers } = useRoleProminencePeers(prominentRoles, peers, isInsetEnabled);
|
19971
|
-
const localPeer =
|
19771
|
+
const localPeer = useHMSStore59(selectLocalPeer8);
|
19972
19772
|
const maxTileCount = 4;
|
19973
19773
|
const pageList = usePagesWithTiles({
|
19974
19774
|
peers: prominentPeers,
|
@@ -19985,7 +19785,7 @@ function RoleProminence({
|
|
19985
19785
|
onPageSize == null ? void 0 : onPageSize(pageSize);
|
19986
19786
|
}
|
19987
19787
|
}, [pageSize, onPageSize]);
|
19988
|
-
return /* @__PURE__ */
|
19788
|
+
return /* @__PURE__ */ React125.createElement(ProminenceLayout.Root, null, /* @__PURE__ */ React125.createElement(ProminenceLayout.ProminentSection, null, /* @__PURE__ */ React125.createElement(Grid, { ref, tiles: pagesWithTiles[page] })), !edgeToEdge && /* @__PURE__ */ React125.createElement(
|
19989
19789
|
Pagination,
|
19990
19790
|
{
|
19991
19791
|
page,
|
@@ -19995,37 +19795,37 @@ function RoleProminence({
|
|
19995
19795
|
},
|
19996
19796
|
numPages: pagesWithTiles.length
|
19997
19797
|
}
|
19998
|
-
), /* @__PURE__ */
|
19798
|
+
), /* @__PURE__ */ React125.createElement(SecondaryTiles, { peers: secondaryPeers, isInsetEnabled, edgeToEdge }), isInsetEnabled && localPeer && !prominentPeers.includes(localPeer) && /* @__PURE__ */ React125.createElement(InsetTile, null));
|
19999
19799
|
}
|
20000
19800
|
|
20001
19801
|
// src/Prebuilt/components/VideoLayouts/ScreenshareLayout.tsx
|
20002
19802
|
init_define_process_env();
|
20003
|
-
import
|
19803
|
+
import React128, { useEffect as useEffect37, useMemo as useMemo13, useState as useState53 } from "react";
|
20004
19804
|
import { useMedia as useMedia26 } from "react-use";
|
20005
|
-
import { selectPeersScreenSharing, useHMSStore as
|
19805
|
+
import { selectPeersScreenSharing, useHMSStore as useHMSStore61 } from "@100mslive/react-sdk";
|
20006
19806
|
|
20007
19807
|
// src/Prebuilt/components/ScreenshareTile.jsx
|
20008
19808
|
init_define_process_env();
|
20009
|
-
import
|
19809
|
+
import React127, { useRef as useRef22, useState as useState52 } from "react";
|
20010
19810
|
import { useFullscreen as useFullscreen2 } from "react-use";
|
20011
19811
|
import screenfull2 from "screenfull";
|
20012
19812
|
import {
|
20013
|
-
selectLocalPeerID as
|
20014
|
-
selectPeerByID as
|
19813
|
+
selectLocalPeerID as selectLocalPeerID12,
|
19814
|
+
selectPeerByID as selectPeerByID3,
|
20015
19815
|
selectScreenShareAudioByPeerID as selectScreenShareAudioByPeerID2,
|
20016
19816
|
selectScreenShareByPeerID,
|
20017
|
-
useHMSStore as
|
19817
|
+
useHMSStore as useHMSStore60
|
20018
19818
|
} from "@100mslive/react-sdk";
|
20019
19819
|
import { ExpandIcon as ExpandIcon3, ShrinkIcon as ShrinkIcon2 } from "@100mslive/react-icons";
|
20020
19820
|
|
20021
19821
|
// src/Prebuilt/components/ScreenshareDisplay.jsx
|
20022
19822
|
init_define_process_env();
|
20023
|
-
import
|
20024
|
-
import { useHMSActions as
|
19823
|
+
import React126 from "react";
|
19824
|
+
import { useHMSActions as useHMSActions38 } from "@100mslive/react-sdk";
|
20025
19825
|
import { CrossIcon as CrossIcon18, ShareScreenIcon as ShareScreenIcon4 } from "@100mslive/react-icons";
|
20026
19826
|
var ScreenshareDisplay = () => {
|
20027
|
-
const hmsActions =
|
20028
|
-
return /* @__PURE__ */
|
19827
|
+
const hmsActions = useHMSActions38();
|
19828
|
+
return /* @__PURE__ */ React126.createElement(
|
20029
19829
|
Flex,
|
20030
19830
|
{
|
20031
19831
|
direction: "column",
|
@@ -20037,9 +19837,9 @@ var ScreenshareDisplay = () => {
|
|
20037
19837
|
color: "$on_surface_high"
|
20038
19838
|
}
|
20039
19839
|
},
|
20040
|
-
/* @__PURE__ */
|
20041
|
-
/* @__PURE__ */
|
20042
|
-
/* @__PURE__ */
|
19840
|
+
/* @__PURE__ */ React126.createElement(ShareScreenIcon4, { width: 48, height: 48 }),
|
19841
|
+
/* @__PURE__ */ React126.createElement(Text, { variant: "h5", css: { m: "$8 0" } }, "You are sharing your screen"),
|
19842
|
+
/* @__PURE__ */ React126.createElement(
|
20043
19843
|
Button,
|
20044
19844
|
{
|
20045
19845
|
variant: "danger",
|
@@ -20049,7 +19849,7 @@ var ScreenshareDisplay = () => {
|
|
20049
19849
|
}),
|
20050
19850
|
"data-testid": "stop_screen_share_btn"
|
20051
19851
|
},
|
20052
|
-
/* @__PURE__ */
|
19852
|
+
/* @__PURE__ */ React126.createElement(CrossIcon18, { width: 18, height: 18 }),
|
20053
19853
|
"\xA0 Stop screen share"
|
20054
19854
|
)
|
20055
19855
|
);
|
@@ -20065,9 +19865,9 @@ var labelStyles = {
|
|
20065
19865
|
flexShrink: 0
|
20066
19866
|
};
|
20067
19867
|
var Tile2 = ({ peerId, width = "100%", height = "100%" }) => {
|
20068
|
-
const isLocal =
|
20069
|
-
const track =
|
20070
|
-
const peer =
|
19868
|
+
const isLocal = useHMSStore60(selectLocalPeerID12) === peerId;
|
19869
|
+
const track = useHMSStore60(selectScreenShareByPeerID(peerId));
|
19870
|
+
const peer = useHMSStore60(selectPeerByID3(peerId));
|
20071
19871
|
const isAudioOnly = useUISettings(UI_SETTINGS.isAudioOnly);
|
20072
19872
|
const [isMouseHovered, setIsMouseHovered] = useState52(false);
|
20073
19873
|
const showStatsOnTiles = useUISettings(UI_SETTINGS.showStatsOnTiles);
|
@@ -20077,9 +19877,9 @@ var Tile2 = ({ peerId, width = "100%", height = "100%" }) => {
|
|
20077
19877
|
onClose: () => setFullscreen(false)
|
20078
19878
|
});
|
20079
19879
|
const isFullScreenSupported = screenfull2.isEnabled;
|
20080
|
-
const audioTrack =
|
19880
|
+
const audioTrack = useHMSStore60(selectScreenShareAudioByPeerID2(peer == null ? void 0 : peer.id));
|
20081
19881
|
if (isLocal && !["browser", "window", "application"].includes(track == null ? void 0 : track.displaySurface)) {
|
20082
|
-
return /* @__PURE__ */
|
19882
|
+
return /* @__PURE__ */ React127.createElement(ScreenshareDisplay, null);
|
20083
19883
|
}
|
20084
19884
|
if (!peer) {
|
20085
19885
|
return null;
|
@@ -20089,7 +19889,7 @@ var Tile2 = ({ peerId, width = "100%", height = "100%" }) => {
|
|
20089
19889
|
isLocal: false,
|
20090
19890
|
track
|
20091
19891
|
});
|
20092
|
-
return /* @__PURE__ */
|
19892
|
+
return /* @__PURE__ */ React127.createElement(StyledVideoTile.Root, { css: { width, height, p: 0, minHeight: 0 }, "data-testid": "screenshare_tile" }, /* @__PURE__ */ React127.createElement(
|
20093
19893
|
StyledVideoTile.Container,
|
20094
19894
|
{
|
20095
19895
|
transparentBg: true,
|
@@ -20100,9 +19900,9 @@ var Tile2 = ({ peerId, width = "100%", height = "100%" }) => {
|
|
20100
19900
|
setIsMouseHovered(false);
|
20101
19901
|
}
|
20102
19902
|
},
|
20103
|
-
showStatsOnTiles ? /* @__PURE__ */
|
20104
|
-
isFullScreenSupported && isMouseHovered ? /* @__PURE__ */
|
20105
|
-
track ? /* @__PURE__ */
|
19903
|
+
showStatsOnTiles ? /* @__PURE__ */ React127.createElement(VideoTileStats, { audioTrackID: audioTrack == null ? void 0 : audioTrack.id, videoTrackID: track == null ? void 0 : track.id, peerID: peerId, isLocal }) : null,
|
19904
|
+
isFullScreenSupported && isMouseHovered ? /* @__PURE__ */ React127.createElement(StyledVideoTile.FullScreenButton, { onClick: () => setFullscreen(!fullscreen) }, isFullscreen ? /* @__PURE__ */ React127.createElement(ShrinkIcon2, null) : /* @__PURE__ */ React127.createElement(ExpandIcon3, null)) : null,
|
19905
|
+
track ? /* @__PURE__ */ React127.createElement(
|
20106
19906
|
Video,
|
20107
19907
|
{
|
20108
19908
|
screenShare: true,
|
@@ -20112,8 +19912,8 @@ var Tile2 = ({ peerId, width = "100%", height = "100%" }) => {
|
|
20112
19912
|
css: { minHeight: 0 }
|
20113
19913
|
}
|
20114
19914
|
) : null,
|
20115
|
-
/* @__PURE__ */
|
20116
|
-
isMouseHovered && !peer.isLocal ? /* @__PURE__ */
|
19915
|
+
/* @__PURE__ */ React127.createElement(StyledVideoTile.Info, { css: labelStyles }, label),
|
19916
|
+
isMouseHovered && !peer.isLocal ? /* @__PURE__ */ React127.createElement(
|
20117
19917
|
TileMenu_default,
|
20118
19918
|
{
|
20119
19919
|
isScreenshare: true,
|
@@ -20125,13 +19925,13 @@ var Tile2 = ({ peerId, width = "100%", height = "100%" }) => {
|
|
20125
19925
|
) : null
|
20126
19926
|
));
|
20127
19927
|
};
|
20128
|
-
var ScreenshareTile =
|
19928
|
+
var ScreenshareTile = React127.memo(Tile2);
|
20129
19929
|
var ScreenshareTile_default = ScreenshareTile;
|
20130
19930
|
|
20131
19931
|
// src/Prebuilt/components/VideoLayouts/ScreenshareLayout.tsx
|
20132
19932
|
var ScreenshareLayout = ({ peers, onPageChange, onPageSize, edgeToEdge }) => {
|
20133
19933
|
var _a7;
|
20134
|
-
const peersSharing =
|
19934
|
+
const peersSharing = useHMSStore61(selectPeersScreenSharing);
|
20135
19935
|
const [, setActiveScreenSharePeer] = useSetAppDataByKey(APP_DATA.activeScreensharePeerId);
|
20136
19936
|
const [page, setPage] = useState53(0);
|
20137
19937
|
const activeSharePeer = peersSharing[page];
|
@@ -20148,7 +19948,7 @@ var ScreenshareLayout = ({ peers, onPageChange, onPageSize, edgeToEdge }) => {
|
|
20148
19948
|
setActiveScreenSharePeer("");
|
20149
19949
|
};
|
20150
19950
|
}, [activeSharePeer == null ? void 0 : activeSharePeer.id, isMobile, setActiveScreenSharePeer]);
|
20151
|
-
return /* @__PURE__ */
|
19951
|
+
return /* @__PURE__ */ React128.createElement(ProminenceLayout.Root, { edgeToEdge }, /* @__PURE__ */ React128.createElement(ProminenceLayout.ProminentSection, null, /* @__PURE__ */ React128.createElement(ScreenshareTile_default, { peerId: (_a7 = peersSharing[page]) == null ? void 0 : _a7.id }), !edgeToEdge && /* @__PURE__ */ React128.createElement(Pagination, { page, onPageChange: setPage, numPages: peersSharing.length })), /* @__PURE__ */ React128.createElement(
|
20152
19952
|
SecondaryTiles,
|
20153
19953
|
{
|
20154
19954
|
peers: secondaryPeers,
|
@@ -20254,9 +20054,9 @@ var GridLayout = ({
|
|
20254
20054
|
edge_to_edge = false,
|
20255
20055
|
hide_metadata_on_tile = false
|
20256
20056
|
}) => {
|
20257
|
-
const peerSharing =
|
20057
|
+
const peerSharing = useHMSStore62(selectPeerScreenSharing);
|
20258
20058
|
const pinnedTrack = usePinnedTrack();
|
20259
|
-
const peers =
|
20059
|
+
const peers = useHMSStore62(selectPeers3);
|
20260
20060
|
const isRoleProminence = prominentRoles.length && peers.some(
|
20261
20061
|
(peer) => peer.roleName && prominentRoles.includes(peer.roleName) && (peer.videoTrack || peer.audioTrack)
|
20262
20062
|
) || pinnedTrack;
|
@@ -20290,7 +20090,7 @@ var GridLayout = ({
|
|
20290
20090
|
peersSorter.onUpdate(setSortedPeers);
|
20291
20091
|
}, [mainPage, peersSorter, updatedPeers, pageSize]);
|
20292
20092
|
if (peerSharing) {
|
20293
|
-
return /* @__PURE__ */
|
20093
|
+
return /* @__PURE__ */ React129.createElement(VideoTileContext.Provider, { value: tileLayout }, /* @__PURE__ */ React129.createElement(
|
20294
20094
|
ScreenshareLayout,
|
20295
20095
|
{
|
20296
20096
|
peers: sortedPeers,
|
@@ -20300,7 +20100,7 @@ var GridLayout = ({
|
|
20300
20100
|
}
|
20301
20101
|
));
|
20302
20102
|
} else if (isRoleProminence) {
|
20303
|
-
return /* @__PURE__ */
|
20103
|
+
return /* @__PURE__ */ React129.createElement(VideoTileContext.Provider, { value: tileLayout }, /* @__PURE__ */ React129.createElement(
|
20304
20104
|
RoleProminence,
|
20305
20105
|
{
|
20306
20106
|
peers: sortedPeers,
|
@@ -20312,7 +20112,7 @@ var GridLayout = ({
|
|
20312
20112
|
}
|
20313
20113
|
));
|
20314
20114
|
}
|
20315
|
-
return /* @__PURE__ */
|
20115
|
+
return /* @__PURE__ */ React129.createElement(VideoTileContext.Provider, { value: tileLayout }, /* @__PURE__ */ React129.createElement(
|
20316
20116
|
EqualProminence,
|
20317
20117
|
{
|
20318
20118
|
peers: sortedPeers,
|
@@ -20326,14 +20126,14 @@ var GridLayout = ({
|
|
20326
20126
|
|
20327
20127
|
// src/Prebuilt/layouts/EmbedView.jsx
|
20328
20128
|
init_define_process_env();
|
20329
|
-
import
|
20330
|
-
import { selectAppData as selectAppData6, selectPeers as selectPeers4, selectPeerScreenSharing as selectPeerScreenSharing2, useEmbedShare, useHMSStore as
|
20129
|
+
import React130, { useEffect as useEffect39, useMemo as useMemo15 } from "react";
|
20130
|
+
import { selectAppData as selectAppData6, selectPeers as selectPeers4, selectPeerScreenSharing as selectPeerScreenSharing2, useEmbedShare, useHMSStore as useHMSStore63 } from "@100mslive/react-sdk";
|
20331
20131
|
var EmbedView = () => {
|
20332
|
-
return /* @__PURE__ */
|
20132
|
+
return /* @__PURE__ */ React130.createElement(EmbedScreenShareView, null, /* @__PURE__ */ React130.createElement(EmbedComponent, null));
|
20333
20133
|
};
|
20334
20134
|
var EmbedScreenShareView = ({ children }) => {
|
20335
|
-
const peers =
|
20336
|
-
const peerPresenting =
|
20135
|
+
const peers = useHMSStore63(selectPeers4);
|
20136
|
+
const peerPresenting = useHMSStore63(selectPeerScreenSharing2);
|
20337
20137
|
const [, setActiveScreenSharePeer] = useSetAppDataByKey(APP_DATA.activeScreensharePeerId);
|
20338
20138
|
const smallTilePeers = useMemo15(() => {
|
20339
20139
|
const smallTilePeers2 = peers.filter((peer) => peer.id !== (peerPresenting == null ? void 0 : peerPresenting.id));
|
@@ -20345,10 +20145,10 @@ var EmbedScreenShareView = ({ children }) => {
|
|
20345
20145
|
setActiveScreenSharePeer("");
|
20346
20146
|
};
|
20347
20147
|
}, [peerPresenting == null ? void 0 : peerPresenting.id, setActiveScreenSharePeer]);
|
20348
|
-
return /* @__PURE__ */
|
20148
|
+
return /* @__PURE__ */ React130.createElement(ProminenceLayout.Root, null, /* @__PURE__ */ React130.createElement(ProminenceLayout.ProminentSection, null, children), /* @__PURE__ */ React130.createElement(SecondaryTiles, { peers: smallTilePeers }));
|
20349
20149
|
};
|
20350
20150
|
var EmbedComponent = () => {
|
20351
|
-
const embedConfig =
|
20151
|
+
const embedConfig = useHMSStore63(selectAppData6(APP_DATA.embedConfig));
|
20352
20152
|
const resetConfig = useResetEmbedConfig();
|
20353
20153
|
const { iframeRef, startEmbedShare, isEmbedShareInProgress } = useEmbedShare(resetConfig);
|
20354
20154
|
useEffect39(() => {
|
@@ -20366,7 +20166,7 @@ var EmbedComponent = () => {
|
|
20366
20166
|
}
|
20367
20167
|
}))();
|
20368
20168
|
}, [isEmbedShareInProgress, embedConfig, startEmbedShare, resetConfig]);
|
20369
|
-
return /* @__PURE__ */
|
20169
|
+
return /* @__PURE__ */ React130.createElement(
|
20370
20170
|
Box,
|
20371
20171
|
{
|
20372
20172
|
css: {
|
@@ -20379,7 +20179,7 @@ var EmbedComponent = () => {
|
|
20379
20179
|
}
|
20380
20180
|
}
|
20381
20181
|
},
|
20382
|
-
/* @__PURE__ */
|
20182
|
+
/* @__PURE__ */ React130.createElement(
|
20383
20183
|
"iframe",
|
20384
20184
|
{
|
20385
20185
|
title: "Embed View",
|
@@ -20399,7 +20199,7 @@ var EmbedComponent = () => {
|
|
20399
20199
|
|
20400
20200
|
// src/Prebuilt/layouts/PDFView.jsx
|
20401
20201
|
init_define_process_env();
|
20402
|
-
import
|
20202
|
+
import React131, { useEffect as useEffect40 } from "react";
|
20403
20203
|
import { usePDFShare } from "@100mslive/react-sdk";
|
20404
20204
|
var PDFView = () => {
|
20405
20205
|
const pdfConfig = usePDFConfig();
|
@@ -20420,7 +20220,7 @@ var PDFView = () => {
|
|
20420
20220
|
}
|
20421
20221
|
}))();
|
20422
20222
|
}, [isPDFShareInProgress, pdfConfig, resetConfig, startPDFShare]);
|
20423
|
-
return /* @__PURE__ */
|
20223
|
+
return /* @__PURE__ */ React131.createElement(EmbedScreenShareView, null, /* @__PURE__ */ React131.createElement(
|
20424
20224
|
Box,
|
20425
20225
|
{
|
20426
20226
|
css: {
|
@@ -20433,7 +20233,7 @@ var PDFView = () => {
|
|
20433
20233
|
}
|
20434
20234
|
}
|
20435
20235
|
},
|
20436
|
-
/* @__PURE__ */
|
20236
|
+
/* @__PURE__ */ React131.createElement(
|
20437
20237
|
"iframe",
|
20438
20238
|
{
|
20439
20239
|
title: "Embed View",
|
@@ -20453,10 +20253,10 @@ var PDFView = () => {
|
|
20453
20253
|
|
20454
20254
|
// src/Prebuilt/layouts/WaitingView.jsx
|
20455
20255
|
init_define_process_env();
|
20456
|
-
import
|
20256
|
+
import React132 from "react";
|
20457
20257
|
import { ColoredTimeIcon } from "@100mslive/react-icons";
|
20458
|
-
var WaitingView =
|
20459
|
-
return /* @__PURE__ */
|
20258
|
+
var WaitingView = React132.memo(() => {
|
20259
|
+
return /* @__PURE__ */ React132.createElement(
|
20460
20260
|
Box,
|
20461
20261
|
{
|
20462
20262
|
css: {
|
@@ -20470,7 +20270,7 @@ var WaitingView = React133.memo(() => {
|
|
20470
20270
|
},
|
20471
20271
|
"data-testid": "waiting_view"
|
20472
20272
|
},
|
20473
|
-
/* @__PURE__ */
|
20273
|
+
/* @__PURE__ */ React132.createElement(
|
20474
20274
|
Flex,
|
20475
20275
|
{
|
20476
20276
|
align: "center",
|
@@ -20484,8 +20284,8 @@ var WaitingView = React133.memo(() => {
|
|
20484
20284
|
gap: "$8"
|
20485
20285
|
}
|
20486
20286
|
},
|
20487
|
-
/* @__PURE__ */
|
20488
|
-
/* @__PURE__ */
|
20287
|
+
/* @__PURE__ */ React132.createElement(ColoredTimeIcon, { width: "80px", height: "80px" }),
|
20288
|
+
/* @__PURE__ */ React132.createElement(
|
20489
20289
|
Flex,
|
20490
20290
|
{
|
20491
20291
|
direction: "column",
|
@@ -20495,29 +20295,27 @@ var WaitingView = React133.memo(() => {
|
|
20495
20295
|
gap: "$4"
|
20496
20296
|
}
|
20497
20297
|
},
|
20498
|
-
/* @__PURE__ */
|
20499
|
-
/* @__PURE__ */
|
20298
|
+
/* @__PURE__ */ React132.createElement(Text, { color: "white", variant: "h6", css: { "@md": { fontSize: "$md" } } }, "Please wait"),
|
20299
|
+
/* @__PURE__ */ React132.createElement(Text, { color: "$on_surface_medium", css: { mt: "$4", "@md": { fontSize: "$sm" } } }, "Sit back and relax till others let you join.")
|
20500
20300
|
)
|
20501
20301
|
)
|
20502
20302
|
);
|
20503
20303
|
});
|
20504
20304
|
|
20505
20305
|
// src/Prebuilt/layouts/VideoStreamingSection.tsx
|
20506
|
-
var HLSView =
|
20306
|
+
var HLSView = React133.lazy(() => import("./HLSView-IENE4HRP.js"));
|
20507
20307
|
var VideoStreamingSection = ({
|
20508
20308
|
screenType,
|
20509
20309
|
elements,
|
20510
20310
|
hideControls = false
|
20511
20311
|
}) => {
|
20512
20312
|
var _a7, _b7;
|
20513
|
-
const localPeerRole =
|
20514
|
-
const isConnected =
|
20515
|
-
const hmsActions =
|
20313
|
+
const localPeerRole = useHMSStore64(selectLocalPeerRoleName6);
|
20314
|
+
const isConnected = useHMSStore64(selectIsConnectedToRoom9);
|
20315
|
+
const hmsActions = useHMSActions39();
|
20516
20316
|
const waitingViewerRole = useWaitingViewerRole();
|
20517
20317
|
const urlToIframe = useUrlToEmbed();
|
20518
20318
|
const pdfAnnotatorActive = usePDFConfig();
|
20519
|
-
const localPeerName = useHMSStore65(selectLocalPeerName6);
|
20520
|
-
const { enabled: isChatEnabled = true, updatedBy: chatStateUpdatedBy = "" } = useHMSStore65(selectSessionStore7("chatState" /* CHAT_STATE */)) || {};
|
20521
20319
|
useEffect41(() => {
|
20522
20320
|
if (!isConnected) {
|
20523
20321
|
return;
|
@@ -20530,30 +20328,22 @@ var VideoStreamingSection = ({
|
|
20530
20328
|
"chatPeerBlacklist" /* CHAT_PEER_BLACKLIST */
|
20531
20329
|
]);
|
20532
20330
|
}, [isConnected, hmsActions]);
|
20533
|
-
useEffect41(() => {
|
20534
|
-
if (!chatStateUpdatedBy || chatStateUpdatedBy === localPeerName) {
|
20535
|
-
return;
|
20536
|
-
}
|
20537
|
-
const type = isChatEnabled ? "CHAT_RESUMED" : "CHAT_PAUSED";
|
20538
|
-
const notification = { id: uuid2(), message: "", type, data: { name: localPeerName } };
|
20539
|
-
ToastBatcher.showToast({ notification, type });
|
20540
|
-
}, [isChatEnabled, chatStateUpdatedBy, localPeerName]);
|
20541
20331
|
if (!localPeerRole) {
|
20542
20332
|
return null;
|
20543
20333
|
}
|
20544
20334
|
let ViewComponent;
|
20545
20335
|
if (screenType === "hls_live_streaming") {
|
20546
|
-
ViewComponent = /* @__PURE__ */
|
20336
|
+
ViewComponent = /* @__PURE__ */ React133.createElement(HLSView, null);
|
20547
20337
|
} else if (localPeerRole === waitingViewerRole) {
|
20548
|
-
ViewComponent = /* @__PURE__ */
|
20338
|
+
ViewComponent = /* @__PURE__ */ React133.createElement(WaitingView, null);
|
20549
20339
|
} else if (pdfAnnotatorActive) {
|
20550
|
-
ViewComponent = /* @__PURE__ */
|
20340
|
+
ViewComponent = /* @__PURE__ */ React133.createElement(PDFView, null);
|
20551
20341
|
} else if (urlToIframe) {
|
20552
|
-
ViewComponent = /* @__PURE__ */
|
20342
|
+
ViewComponent = /* @__PURE__ */ React133.createElement(EmbedView, null);
|
20553
20343
|
} else {
|
20554
|
-
ViewComponent = /* @__PURE__ */
|
20344
|
+
ViewComponent = /* @__PURE__ */ React133.createElement(GridLayout, __spreadValues({}, (_a7 = elements == null ? void 0 : elements.video_tile_layout) == null ? void 0 : _a7.grid));
|
20555
20345
|
}
|
20556
|
-
return /* @__PURE__ */
|
20346
|
+
return /* @__PURE__ */ React133.createElement(Suspense, { fallback: /* @__PURE__ */ React133.createElement(FullPageProgress_default, null) }, /* @__PURE__ */ React133.createElement(
|
20557
20347
|
Flex,
|
20558
20348
|
{
|
20559
20349
|
css: {
|
@@ -20563,14 +20353,14 @@ var VideoStreamingSection = ({
|
|
20563
20353
|
}
|
20564
20354
|
},
|
20565
20355
|
ViewComponent,
|
20566
|
-
/* @__PURE__ */
|
20356
|
+
/* @__PURE__ */ React133.createElement(Box, { css: { height: "100%", maxHeight: "100%", overflowY: "clip" } }, /* @__PURE__ */ React133.createElement(
|
20567
20357
|
SidePane_default,
|
20568
20358
|
{
|
20569
20359
|
screenType,
|
20570
20360
|
tileProps: (_b7 = elements == null ? void 0 : elements.video_tile_layout) == null ? void 0 : _b7.grid,
|
20571
20361
|
hideControls
|
20572
20362
|
}
|
20573
|
-
)
|
20363
|
+
))
|
20574
20364
|
));
|
20575
20365
|
};
|
20576
20366
|
|
@@ -20579,21 +20369,21 @@ init_define_process_env();
|
|
20579
20369
|
|
20580
20370
|
// src/Prebuilt/components/Header/Header.tsx
|
20581
20371
|
init_define_process_env();
|
20582
|
-
import
|
20372
|
+
import React135 from "react";
|
20583
20373
|
import { useMedia as useMedia27 } from "react-use";
|
20584
|
-
import { HMSRoomState as HMSRoomState6, selectRoomState as selectRoomState6, useHMSStore as
|
20374
|
+
import { HMSRoomState as HMSRoomState6, selectRoomState as selectRoomState6, useHMSStore as useHMSStore66 } from "@100mslive/react-sdk";
|
20585
20375
|
|
20586
20376
|
// src/Prebuilt/components/Header/common.jsx
|
20587
20377
|
init_define_process_env();
|
20588
|
-
import
|
20378
|
+
import React134 from "react";
|
20589
20379
|
import {
|
20590
20380
|
DeviceType as DeviceType3,
|
20591
20381
|
selectIsLocalVideoEnabled as selectIsLocalVideoEnabled7,
|
20592
20382
|
selectLocalVideoTrackID as selectLocalVideoTrackID4,
|
20593
20383
|
selectVideoTrackByID as selectVideoTrackByID7,
|
20594
20384
|
useDevices as useDevices3,
|
20595
|
-
useHMSActions as
|
20596
|
-
useHMSStore as
|
20385
|
+
useHMSActions as useHMSActions40,
|
20386
|
+
useHMSStore as useHMSStore65
|
20597
20387
|
} from "@100mslive/react-sdk";
|
20598
20388
|
import {
|
20599
20389
|
BluetoothIcon,
|
@@ -20604,16 +20394,16 @@ import {
|
|
20604
20394
|
SpeakerIcon as SpeakerIcon3
|
20605
20395
|
} from "@100mslive/react-icons";
|
20606
20396
|
var CamaraFlipActions = () => {
|
20607
|
-
const actions =
|
20397
|
+
const actions = useHMSActions40();
|
20608
20398
|
const { allDevices } = useDevices3();
|
20609
20399
|
const { videoInput } = allDevices;
|
20610
|
-
const isVideoOn =
|
20611
|
-
const videoTrackId =
|
20612
|
-
const localVideoTrack =
|
20400
|
+
const isVideoOn = useHMSStore65(selectIsLocalVideoEnabled7);
|
20401
|
+
const videoTrackId = useHMSStore65(selectLocalVideoTrackID4);
|
20402
|
+
const localVideoTrack = useHMSStore65(selectVideoTrackByID7(videoTrackId));
|
20613
20403
|
if (!videoInput || !(videoInput == null ? void 0 : videoInput.length) || !(localVideoTrack == null ? void 0 : localVideoTrack.facingMode)) {
|
20614
20404
|
return null;
|
20615
20405
|
}
|
20616
|
-
return /* @__PURE__ */
|
20406
|
+
return /* @__PURE__ */ React134.createElement(Box, null, /* @__PURE__ */ React134.createElement(
|
20617
20407
|
IconButton_default,
|
20618
20408
|
{
|
20619
20409
|
disabled: !isVideoOn,
|
@@ -20628,7 +20418,7 @@ var CamaraFlipActions = () => {
|
|
20628
20418
|
}
|
20629
20419
|
})
|
20630
20420
|
},
|
20631
|
-
/* @__PURE__ */
|
20421
|
+
/* @__PURE__ */ React134.createElement(CameraFlipIcon2, null)
|
20632
20422
|
));
|
20633
20423
|
};
|
20634
20424
|
var AudioActions = () => {
|
@@ -20641,19 +20431,19 @@ var AudioActions = () => {
|
|
20641
20431
|
availableAudioDevices = audioOutput;
|
20642
20432
|
selectedAudio = selectedDeviceIDs.audioOutput;
|
20643
20433
|
}
|
20644
|
-
const hmsActions =
|
20434
|
+
const hmsActions = useHMSActions40();
|
20645
20435
|
const audioFiltered = availableAudioDevices == null ? void 0 : availableAudioDevices.find((item) => !!item.label);
|
20646
20436
|
const currentSelection = availableAudioDevices == null ? void 0 : availableAudioDevices.find((item) => item.deviceId === selectedAudio);
|
20647
20437
|
if (!audioFiltered) {
|
20648
20438
|
return null;
|
20649
20439
|
}
|
20650
|
-
let AudioIcon = /* @__PURE__ */
|
20440
|
+
let AudioIcon = /* @__PURE__ */ React134.createElement(SpeakerIcon3, null);
|
20651
20441
|
if (currentSelection && currentSelection.label.toLowerCase().includes("bluetooth")) {
|
20652
|
-
AudioIcon = /* @__PURE__ */
|
20442
|
+
AudioIcon = /* @__PURE__ */ React134.createElement(BluetoothIcon, null);
|
20653
20443
|
} else if (currentSelection && currentSelection.label.toLowerCase().includes("wired")) {
|
20654
|
-
AudioIcon = /* @__PURE__ */
|
20444
|
+
AudioIcon = /* @__PURE__ */ React134.createElement(HeadphonesIcon, null);
|
20655
20445
|
}
|
20656
|
-
return /* @__PURE__ */
|
20446
|
+
return /* @__PURE__ */ React134.createElement(
|
20657
20447
|
AudioSelectionSheet,
|
20658
20448
|
{
|
20659
20449
|
audioDevices: availableAudioDevices,
|
@@ -20672,19 +20462,19 @@ var AudioActions = () => {
|
|
20672
20462
|
}
|
20673
20463
|
})
|
20674
20464
|
},
|
20675
|
-
/* @__PURE__ */
|
20465
|
+
/* @__PURE__ */ React134.createElement(
|
20676
20466
|
Box,
|
20677
20467
|
{
|
20678
20468
|
onClick: () => __async(void 0, null, function* () {
|
20679
20469
|
yield hmsActions.refreshDevices();
|
20680
20470
|
})
|
20681
20471
|
},
|
20682
|
-
/* @__PURE__ */
|
20472
|
+
/* @__PURE__ */ React134.createElement(IconButton_default, null, AudioIcon, " ")
|
20683
20473
|
)
|
20684
20474
|
);
|
20685
20475
|
};
|
20686
20476
|
var AudioSelectionSheet = ({ audioDevices, audioSelected, onChange, children }) => {
|
20687
|
-
return /* @__PURE__ */
|
20477
|
+
return /* @__PURE__ */ React134.createElement(Sheet.Root, null, /* @__PURE__ */ React134.createElement(Sheet.Trigger, { asChild: true }, children), /* @__PURE__ */ React134.createElement(Sheet.Content, null, /* @__PURE__ */ React134.createElement(Sheet.Title, { css: { py: "$10", px: "$8", alignItems: "center" } }, /* @__PURE__ */ React134.createElement(Flex, { direction: "row", justify: "between", css: { w: "100%" } }, /* @__PURE__ */ React134.createElement(Text, { variant: "h6", css: { display: "flex" } }, "Audio"), /* @__PURE__ */ React134.createElement(Sheet.Close, null, /* @__PURE__ */ React134.createElement(IconButton_default, { as: "div", "data-testid": "dialog_cross_icon" }, /* @__PURE__ */ React134.createElement(CrossIcon19, null))))), /* @__PURE__ */ React134.createElement(HorizontalDivider, null), /* @__PURE__ */ React134.createElement(
|
20688
20478
|
Flex,
|
20689
20479
|
{
|
20690
20480
|
direction: "column",
|
@@ -20695,7 +20485,7 @@ var AudioSelectionSheet = ({ audioDevices, audioSelected, onChange, children })
|
|
20695
20485
|
}
|
20696
20486
|
},
|
20697
20487
|
audioDevices.map((audioDevice) => {
|
20698
|
-
return /* @__PURE__ */
|
20488
|
+
return /* @__PURE__ */ React134.createElement(
|
20699
20489
|
SelectWithLabel,
|
20700
20490
|
{
|
20701
20491
|
key: audioDevice.deviceId,
|
@@ -20708,8 +20498,8 @@ var AudioSelectionSheet = ({ audioDevices, audioSelected, onChange, children })
|
|
20708
20498
|
})
|
20709
20499
|
)));
|
20710
20500
|
};
|
20711
|
-
var SelectWithLabel = ({ label, icon = /* @__PURE__ */
|
20712
|
-
return /* @__PURE__ */
|
20501
|
+
var SelectWithLabel = ({ label, icon = /* @__PURE__ */ React134.createElement(React134.Fragment, null), checked, id, onChange }) => {
|
20502
|
+
return /* @__PURE__ */ React134.createElement(
|
20713
20503
|
Flex,
|
20714
20504
|
{
|
20715
20505
|
align: "center",
|
@@ -20721,7 +20511,7 @@ var SelectWithLabel = ({ label, icon = /* @__PURE__ */ React135.createElement(Re
|
|
20721
20511
|
},
|
20722
20512
|
onClick: onChange
|
20723
20513
|
},
|
20724
|
-
/* @__PURE__ */
|
20514
|
+
/* @__PURE__ */ React134.createElement(
|
20725
20515
|
Label3,
|
20726
20516
|
{
|
20727
20517
|
htmlFor: id,
|
@@ -20739,18 +20529,18 @@ var SelectWithLabel = ({ label, icon = /* @__PURE__ */ React135.createElement(Re
|
|
20739
20529
|
icon,
|
20740
20530
|
label
|
20741
20531
|
),
|
20742
|
-
checked && /* @__PURE__ */
|
20532
|
+
checked && /* @__PURE__ */ React134.createElement(CheckIcon6, { width: 24, height: 24 })
|
20743
20533
|
);
|
20744
20534
|
};
|
20745
20535
|
|
20746
20536
|
// src/Prebuilt/components/Header/Header.tsx
|
20747
20537
|
var Header2 = () => {
|
20748
|
-
const roomState =
|
20538
|
+
const roomState = useHMSStore66(selectRoomState6);
|
20749
20539
|
const isMobile = useMedia27(config.media.md);
|
20750
20540
|
if (roomState !== HMSRoomState6.Connected) {
|
20751
|
-
return /* @__PURE__ */
|
20541
|
+
return /* @__PURE__ */ React135.createElement(React135.Fragment, null);
|
20752
20542
|
}
|
20753
|
-
return /* @__PURE__ */
|
20543
|
+
return /* @__PURE__ */ React135.createElement(Flex, { justify: "between", align: "center", css: { position: "relative", height: "100%" } }, /* @__PURE__ */ React135.createElement(Flex, { align: "center", gap: "2", css: { position: "absolute", left: "$10" } }, /* @__PURE__ */ React135.createElement(Logo, null), /* @__PURE__ */ React135.createElement(SpeakerTag, null), isMobile && /* @__PURE__ */ React135.createElement(Flex, { align: "center", css: { gap: "$4" } }, /* @__PURE__ */ React135.createElement(LiveStatus, null), /* @__PURE__ */ React135.createElement(RecordingStatus, null), /* @__PURE__ */ React135.createElement(RecordingPauseStatus, null))), /* @__PURE__ */ React135.createElement(
|
20754
20544
|
Flex,
|
20755
20545
|
{
|
20756
20546
|
align: "center",
|
@@ -20760,8 +20550,8 @@ var Header2 = () => {
|
|
20760
20550
|
gap: "$4"
|
20761
20551
|
}
|
20762
20552
|
},
|
20763
|
-
/* @__PURE__ */
|
20764
|
-
isMobile ? /* @__PURE__ */
|
20553
|
+
/* @__PURE__ */ React135.createElement(StreamActions, null),
|
20554
|
+
isMobile ? /* @__PURE__ */ React135.createElement(React135.Fragment, null, /* @__PURE__ */ React135.createElement(CamaraFlipActions, null), /* @__PURE__ */ React135.createElement(AudioActions, null)) : null
|
20765
20555
|
));
|
20766
20556
|
};
|
20767
20557
|
|
@@ -20771,11 +20561,11 @@ var ConferenceScreen = () => {
|
|
20771
20561
|
const { userName, endpoints, onJoin: onJoinFunc } = useHMSPrebuiltContext();
|
20772
20562
|
const screenProps = useRoomLayoutConferencingScreen();
|
20773
20563
|
const { isPreviewScreenEnabled } = useRoomLayoutPreviewScreen();
|
20774
|
-
const roomState =
|
20775
|
-
const isConnectedToRoom =
|
20776
|
-
const hmsActions =
|
20564
|
+
const roomState = useHMSStore67(selectRoomState7);
|
20565
|
+
const isConnectedToRoom = useHMSStore67(selectIsConnectedToRoom10);
|
20566
|
+
const hmsActions = useHMSActions41();
|
20777
20567
|
const [hideControls, setHideControls] = useState55(false);
|
20778
|
-
const dropdownList =
|
20568
|
+
const dropdownList = useHMSStore67(selectAppData7(APP_DATA.dropdownList));
|
20779
20569
|
const authTokenInAppData = useAuthToken();
|
20780
20570
|
const headerRef = useRef23(null);
|
20781
20571
|
const footerRef = useRef23(null);
|
@@ -20826,9 +20616,9 @@ var ConferenceScreen = () => {
|
|
20826
20616
|
};
|
20827
20617
|
}, [onJoinFunc]);
|
20828
20618
|
if (!isConnectedToRoom && ![HMSRoomState7.Reconnecting, HMSRoomState7.Disconnected].includes(roomState)) {
|
20829
|
-
return /* @__PURE__ */
|
20619
|
+
return /* @__PURE__ */ React136.createElement(FullPageProgress_default, { text: roomState === HMSRoomState7.Connecting ? "Joining..." : "" });
|
20830
20620
|
}
|
20831
|
-
return /* @__PURE__ */
|
20621
|
+
return /* @__PURE__ */ React136.createElement(React136.Fragment, null, isHLSStarted ? /* @__PURE__ */ React136.createElement(Box, { css: { position: "fixed", zIndex: 100, w: "100%", h: "100%", left: 0, top: 0 } }, /* @__PURE__ */ React136.createElement(FullPageProgress_default, { text: "Starting live stream...", css: { opacity: 0.8, bg: "$background_dim" } })) : null, /* @__PURE__ */ React136.createElement(Flex, { css: { size: "100%", overflow: "hidden" }, direction: "column" }, !screenProps.hideSections.includes("header") && /* @__PURE__ */ React136.createElement(
|
20832
20622
|
Box,
|
20833
20623
|
{
|
20834
20624
|
ref: headerRef,
|
@@ -20842,8 +20632,8 @@ var ConferenceScreen = () => {
|
|
20842
20632
|
},
|
20843
20633
|
"data-testid": "header"
|
20844
20634
|
},
|
20845
|
-
/* @__PURE__ */
|
20846
|
-
), /* @__PURE__ */
|
20635
|
+
/* @__PURE__ */ React136.createElement(Header2, null)
|
20636
|
+
), /* @__PURE__ */ React136.createElement(
|
20847
20637
|
Box,
|
20848
20638
|
{
|
20849
20639
|
css: {
|
@@ -20862,7 +20652,7 @@ var ConferenceScreen = () => {
|
|
20862
20652
|
"data-testid": "conferencing",
|
20863
20653
|
onClick: toggleControls
|
20864
20654
|
},
|
20865
|
-
screenProps.elements ? /* @__PURE__ */
|
20655
|
+
screenProps.elements ? /* @__PURE__ */ React136.createElement(
|
20866
20656
|
VideoStreamingSection,
|
20867
20657
|
{
|
20868
20658
|
screenType: screenProps.screenType,
|
@@ -20870,7 +20660,7 @@ var ConferenceScreen = () => {
|
|
20870
20660
|
hideControls
|
20871
20661
|
}
|
20872
20662
|
) : null
|
20873
|
-
), !screenProps.hideSections.includes("footer") && screenProps.elements && /* @__PURE__ */
|
20663
|
+
), !screenProps.hideSections.includes("footer") && screenProps.elements && /* @__PURE__ */ React136.createElement(
|
20874
20664
|
Box,
|
20875
20665
|
{
|
20876
20666
|
ref: footerRef,
|
@@ -20887,13 +20677,13 @@ var ConferenceScreen = () => {
|
|
20887
20677
|
},
|
20888
20678
|
"data-testid": "footer"
|
20889
20679
|
},
|
20890
|
-
/* @__PURE__ */
|
20891
|
-
), /* @__PURE__ */
|
20680
|
+
/* @__PURE__ */ React136.createElement(Footer2, { elements: screenProps.elements, screenType: screenProps.screenType })
|
20681
|
+
), /* @__PURE__ */ React136.createElement(RoleChangeRequestModal, null), /* @__PURE__ */ React136.createElement(HLSFailureModal, null), /* @__PURE__ */ React136.createElement(ActivatedPIP, null)));
|
20892
20682
|
};
|
20893
20683
|
|
20894
20684
|
// src/Prebuilt/components/ErrorBoundary.jsx
|
20895
20685
|
init_define_process_env();
|
20896
|
-
import
|
20686
|
+
import React137, { Component } from "react";
|
20897
20687
|
import { CopyIcon as CopyIcon3 } from "@100mslive/react-icons";
|
20898
20688
|
var ErrorBoundary = class extends Component {
|
20899
20689
|
constructor(props) {
|
@@ -20909,7 +20699,7 @@ var ErrorBoundary = class extends Component {
|
|
20909
20699
|
}
|
20910
20700
|
render() {
|
20911
20701
|
if (this.state.errorInfo) {
|
20912
|
-
return /* @__PURE__ */
|
20702
|
+
return /* @__PURE__ */ React137.createElement(
|
20913
20703
|
Flex,
|
20914
20704
|
{
|
20915
20705
|
align: "center",
|
@@ -20922,7 +20712,7 @@ var ErrorBoundary = class extends Component {
|
|
20922
20712
|
backgroundColor: "$background_default"
|
20923
20713
|
}
|
20924
20714
|
},
|
20925
|
-
/* @__PURE__ */
|
20715
|
+
/* @__PURE__ */ React137.createElement(Box, { css: { position: "relative", overflow: "hidden", r: "$3", height: "100%", width: "100%" } }, /* @__PURE__ */ React137.createElement(
|
20926
20716
|
Flex,
|
20927
20717
|
{
|
20928
20718
|
direction: "column",
|
@@ -20933,8 +20723,8 @@ var ErrorBoundary = class extends Component {
|
|
20933
20723
|
left: 0
|
20934
20724
|
}
|
20935
20725
|
},
|
20936
|
-
/* @__PURE__ */
|
20937
|
-
/* @__PURE__ */
|
20726
|
+
/* @__PURE__ */ React137.createElement("div", { style: { margin: "1.5rem", width: "100%" } }, /* @__PURE__ */ React137.createElement(Text, null, "Something went wrong"), /* @__PURE__ */ React137.createElement(Text, null, "Message: $", this.state.error), /* @__PURE__ */ React137.createElement("br", null), ErrorWithSupportLink(`Please reload to see if it works.`)),
|
20727
|
+
/* @__PURE__ */ React137.createElement(Flex, null, /* @__PURE__ */ React137.createElement(Tooltip, { title: "Reload page" }, /* @__PURE__ */ React137.createElement(
|
20938
20728
|
Button,
|
20939
20729
|
{
|
20940
20730
|
onClick: () => {
|
@@ -20944,7 +20734,7 @@ var ErrorBoundary = class extends Component {
|
|
20944
20734
|
"data-testid": "join_again_btn"
|
20945
20735
|
},
|
20946
20736
|
"Reload"
|
20947
|
-
)), /* @__PURE__ */
|
20737
|
+
)), /* @__PURE__ */ React137.createElement(Tooltip, { title: "Copy error details to clipboard" }, /* @__PURE__ */ React137.createElement(
|
20948
20738
|
Button,
|
20949
20739
|
{
|
20950
20740
|
onClick: () => {
|
@@ -20960,11 +20750,11 @@ var ErrorBoundary = class extends Component {
|
|
20960
20750
|
css: { mx: "$8" },
|
20961
20751
|
"data-testid": "join_again_btn"
|
20962
20752
|
},
|
20963
|
-
/* @__PURE__ */
|
20753
|
+
/* @__PURE__ */ React137.createElement(CopyIcon3, null),
|
20964
20754
|
" ",
|
20965
20755
|
this.state.isErrorCopied ? "Copied" : "Copy Details"
|
20966
20756
|
))),
|
20967
|
-
/* @__PURE__ */
|
20757
|
+
/* @__PURE__ */ React137.createElement("details", { style: { whiteSpace: "pre-wrap", margin: "1.5rem" } }, /* @__PURE__ */ React137.createElement(Text, null, this.state.error && this.state.error.toString()), /* @__PURE__ */ React137.createElement("br", null), /* @__PURE__ */ React137.createElement(Text, null, JSON.stringify(this.state.errorInfo)))
|
20968
20758
|
))
|
20969
20759
|
);
|
20970
20760
|
}
|
@@ -20974,7 +20764,7 @@ var ErrorBoundary = class extends Component {
|
|
20974
20764
|
|
20975
20765
|
// src/Prebuilt/components/init/Init.jsx
|
20976
20766
|
init_define_process_env();
|
20977
|
-
import
|
20767
|
+
import React138, { useEffect as useEffect43 } from "react";
|
20978
20768
|
var Init = () => {
|
20979
20769
|
const { toggleTheme } = useTheme();
|
20980
20770
|
useEffect43(() => {
|
@@ -20991,7 +20781,7 @@ var Init = () => {
|
|
20991
20781
|
window.removeEventListener("resize", resetHeight);
|
20992
20782
|
};
|
20993
20783
|
}, []);
|
20994
|
-
return /* @__PURE__ */
|
20784
|
+
return /* @__PURE__ */ React138.createElement(FeatureFlagsInit, null);
|
20995
20785
|
};
|
20996
20786
|
|
20997
20787
|
// src/Prebuilt/components/Input/KeyboardInputManager.js
|
@@ -21001,7 +20791,7 @@ import {
|
|
21001
20791
|
selectAppData as selectAppData8,
|
21002
20792
|
selectIsLocalAudioEnabled as selectIsLocalAudioEnabled2,
|
21003
20793
|
selectIsLocalVideoEnabled as selectIsLocalVideoEnabled8,
|
21004
|
-
useHMSActions as
|
20794
|
+
useHMSActions as useHMSActions42,
|
21005
20795
|
useHMSVanillaStore as useHMSVanillaStore11
|
21006
20796
|
} from "@100mslive/react-sdk";
|
21007
20797
|
var isEvenListenersAttached = false;
|
@@ -21090,7 +20880,7 @@ _bind = new WeakMap();
|
|
21090
20880
|
_unbind = new WeakMap();
|
21091
20881
|
var KeyboardHandler = () => {
|
21092
20882
|
const store = useHMSVanillaStore11();
|
21093
|
-
const actions =
|
20883
|
+
const actions = useHMSActions42();
|
21094
20884
|
useEffect44(() => {
|
21095
20885
|
const keyboardManager = new KeyboardInputManager(store, actions);
|
21096
20886
|
keyboardManager.bindAllShortcuts();
|
@@ -21101,21 +20891,21 @@ var KeyboardHandler = () => {
|
|
21101
20891
|
|
21102
20892
|
// src/Prebuilt/components/LeaveScreen.tsx
|
21103
20893
|
init_define_process_env();
|
21104
|
-
import
|
20894
|
+
import React140 from "react";
|
21105
20895
|
import { ExitIcon as ExitIcon3 } from "@100mslive/react-icons";
|
21106
20896
|
|
21107
20897
|
// src/Prebuilt/AppStateContext.tsx
|
21108
20898
|
init_define_process_env();
|
21109
|
-
import
|
20899
|
+
import React139, { useContext as useContext4, useEffect as useEffect45 } from "react";
|
21110
20900
|
import { usePreviousDistinct } from "react-use";
|
21111
|
-
import { HMSRoomState as HMSRoomState8, selectRoomState as selectRoomState8, useHMSStore as
|
20901
|
+
import { HMSRoomState as HMSRoomState8, selectRoomState as selectRoomState8, useHMSStore as useHMSStore68 } from "@100mslive/react-sdk";
|
21112
20902
|
|
21113
20903
|
// src/Prebuilt/components/hooks/useRedirectToLeave.tsx
|
21114
20904
|
init_define_process_env();
|
21115
|
-
import { useCallback as
|
20905
|
+
import { useCallback as useCallback31 } from "react";
|
21116
20906
|
var useRedirectToLeave = () => {
|
21117
20907
|
const { onLeave } = useHMSPrebuiltContext();
|
21118
|
-
const redirect =
|
20908
|
+
const redirect = useCallback31(
|
21119
20909
|
(timeout = 0) => {
|
21120
20910
|
setTimeout(() => {
|
21121
20911
|
PictureInPicture.stop().catch(() => console.error("stopping pip"));
|
@@ -21129,7 +20919,7 @@ var useRedirectToLeave = () => {
|
|
21129
20919
|
};
|
21130
20920
|
|
21131
20921
|
// src/Prebuilt/AppStateContext.tsx
|
21132
|
-
var AppStateContext =
|
20922
|
+
var AppStateContext = React139.createContext({
|
21133
20923
|
rejoin: () => {
|
21134
20924
|
console.log("Rejoin");
|
21135
20925
|
}
|
@@ -21144,8 +20934,8 @@ var useHMSAppStateContext = () => {
|
|
21144
20934
|
};
|
21145
20935
|
var useAppStateManager = () => {
|
21146
20936
|
const roomLayout = useRoomLayout();
|
21147
|
-
const [activeState, setActiveState] =
|
21148
|
-
const roomState =
|
20937
|
+
const [activeState, setActiveState] = React139.useState();
|
20938
|
+
const roomState = useHMSStore68(selectRoomState8);
|
21149
20939
|
const prevRoomState = usePreviousDistinct(roomState);
|
21150
20940
|
const { isLeaveScreenEnabled } = useRoomLayoutLeaveScreen();
|
21151
20941
|
const { isPreviewScreenEnabled } = useRoomLayoutPreviewScreen();
|
@@ -21174,7 +20964,7 @@ var useAppStateManager = () => {
|
|
21174
20964
|
var LeaveScreen = () => {
|
21175
20965
|
const { rejoin } = useHMSAppStateContext();
|
21176
20966
|
const [previewPreference] = useUserPreferences(UserPreferencesKeys.PREVIEW, defaultPreviewPreference);
|
21177
|
-
return /* @__PURE__ */
|
20967
|
+
return /* @__PURE__ */ React140.createElement(Flex, { direction: "column", css: { size: "100%" } }, /* @__PURE__ */ React140.createElement(Box, { css: { h: "$18", "@md": { h: "$17" } }, "data-testid": "header" }, /* @__PURE__ */ React140.createElement(Header2, null)), /* @__PURE__ */ React140.createElement(
|
21178
20968
|
Flex,
|
21179
20969
|
{
|
21180
20970
|
justify: "center",
|
@@ -21182,9 +20972,9 @@ var LeaveScreen = () => {
|
|
21182
20972
|
align: "center",
|
21183
20973
|
css: { bg: "$background_dim", flex: "1 1 0", position: "relative" }
|
21184
20974
|
},
|
21185
|
-
/* @__PURE__ */
|
21186
|
-
/* @__PURE__ */
|
21187
|
-
/* @__PURE__ */
|
20975
|
+
/* @__PURE__ */ React140.createElement(Text, { variant: "h2", css: { fontWeight: "$semiBold" } }, "\u{1F44B}"),
|
20976
|
+
/* @__PURE__ */ React140.createElement(Text, { variant: "h4", css: { color: "$on_surface_high", fontWeight: "$semiBold", mt: "$12" } }, "You left the room"),
|
20977
|
+
/* @__PURE__ */ React140.createElement(
|
21188
20978
|
Text,
|
21189
20979
|
{
|
21190
20980
|
variant: "body1",
|
@@ -21196,10 +20986,10 @@ var LeaveScreen = () => {
|
|
21196
20986
|
}
|
21197
20987
|
},
|
21198
20988
|
"Have a nice day",
|
21199
|
-
previewPreference.name && /* @__PURE__ */
|
20989
|
+
previewPreference.name && /* @__PURE__ */ React140.createElement(Box, { as: "span", css: __spreadValues({}, textEllipsis(100)) }, ", ", previewPreference.name),
|
21200
20990
|
"!"
|
21201
20991
|
),
|
21202
|
-
/* @__PURE__ */
|
20992
|
+
/* @__PURE__ */ React140.createElement(Flex, { css: { mt: "$14", gap: "$10", alignItems: "center" } }, /* @__PURE__ */ React140.createElement(Text, { variant: "body1", css: { color: "$on_surface_medium", fontWeight: "$regular" } }, "Left by mistake?"), /* @__PURE__ */ React140.createElement(
|
21203
20993
|
Button,
|
21204
20994
|
{
|
21205
20995
|
onClick: () => {
|
@@ -21208,15 +20998,15 @@ var LeaveScreen = () => {
|
|
21208
20998
|
},
|
21209
20999
|
"data-testid": "join_again_btn"
|
21210
21000
|
},
|
21211
|
-
/* @__PURE__ */
|
21212
|
-
/* @__PURE__ */
|
21001
|
+
/* @__PURE__ */ React140.createElement(ExitIcon3, null),
|
21002
|
+
/* @__PURE__ */ React140.createElement(Text, { css: { ml: "$3", fontWeight: "$semiBold", color: "inherit" } }, "Rejoin")
|
21213
21003
|
))
|
21214
21004
|
));
|
21215
21005
|
};
|
21216
21006
|
|
21217
21007
|
// src/Prebuilt/components/MwebLandscapePrompt.tsx
|
21218
21008
|
init_define_process_env();
|
21219
|
-
import
|
21009
|
+
import React141, { useEffect as useEffect46, useState as useState56 } from "react";
|
21220
21010
|
import { useMedia as useMedia28 } from "react-use";
|
21221
21011
|
import { RefreshIcon } from "@100mslive/react-icons";
|
21222
21012
|
var MwebLandscapePrompt = () => {
|
@@ -21243,7 +21033,7 @@ var MwebLandscapePrompt = () => {
|
|
21243
21033
|
window.screen.orientation.removeEventListener("change", handleRotation);
|
21244
21034
|
};
|
21245
21035
|
}, [isLandscape]);
|
21246
|
-
return /* @__PURE__ */
|
21036
|
+
return /* @__PURE__ */ React141.createElement(Dialog.Root, { open: showMwebLandscapePrompt, onOpenChange: setShowMwebLandscapePrompt }, /* @__PURE__ */ React141.createElement(Dialog.Portal, null, /* @__PURE__ */ React141.createElement(Dialog.Overlay, null), /* @__PURE__ */ React141.createElement(Dialog.Content, { css: { w: "min(420px, 90%)", p: "$8", bg: "$surface_dim" } }, /* @__PURE__ */ React141.createElement(Box, null, /* @__PURE__ */ React141.createElement(
|
21247
21037
|
Flex,
|
21248
21038
|
{
|
21249
21039
|
css: {
|
@@ -21252,9 +21042,9 @@ var MwebLandscapePrompt = () => {
|
|
21252
21042
|
alignItems: "center"
|
21253
21043
|
}
|
21254
21044
|
},
|
21255
|
-
/* @__PURE__ */
|
21256
|
-
/* @__PURE__ */
|
21257
|
-
), /* @__PURE__ */
|
21045
|
+
/* @__PURE__ */ React141.createElement(RefreshIcon, { style: { marginRight: "0.5rem" } }),
|
21046
|
+
/* @__PURE__ */ React141.createElement(Text, { variant: "lg", css: { color: "$on_surface_high", fontWeight: "$semiBold" } }, "Please rotate your device")
|
21047
|
+
), /* @__PURE__ */ React141.createElement(Text, { variant: "sm", css: { color: "$on_surface_medium", mb: "$8", mt: "$4" } }, "We do not support landscape mode as of now, please use the app in portrait mode for the best experience."), /* @__PURE__ */ React141.createElement(Flex, { align: "center", justify: "between", css: { w: "100%", gap: "$8" } }, /* @__PURE__ */ React141.createElement(Button, { outlined: true, variant: "standard", css: { w: "100%" }, onClick: () => setShowMwebLandscapePrompt(false) }, "Continue anyway"))))));
|
21258
21048
|
};
|
21259
21049
|
|
21260
21050
|
// src/Prebuilt/components/Notifications/index.tsx
|
@@ -21262,7 +21052,7 @@ init_define_process_env();
|
|
21262
21052
|
|
21263
21053
|
// src/Prebuilt/components/Notifications/Notifications.tsx
|
21264
21054
|
init_define_process_env();
|
21265
|
-
import
|
21055
|
+
import React150, { useCallback as useCallback33, useEffect as useEffect55 } from "react";
|
21266
21056
|
import {
|
21267
21057
|
HMSNotificationTypes as HMSNotificationTypes9,
|
21268
21058
|
HMSRoomState as HMSRoomState9,
|
@@ -21272,10 +21062,225 @@ import {
|
|
21272
21062
|
selectRoomState as selectRoomState9,
|
21273
21063
|
useCustomEvent as useCustomEvent4,
|
21274
21064
|
useHMSNotifications as useHMSNotifications9,
|
21275
|
-
useHMSStore as
|
21065
|
+
useHMSStore as useHMSStore71,
|
21276
21066
|
useHMSVanillaStore as useHMSVanillaStore12
|
21277
21067
|
} from "@100mslive/react-sdk";
|
21278
21068
|
|
21069
|
+
// src/Prebuilt/components/Toast/ToastBatcher.js
|
21070
|
+
init_define_process_env();
|
21071
|
+
|
21072
|
+
// src/Prebuilt/components/Toast/ToastConfig.jsx
|
21073
|
+
init_define_process_env();
|
21074
|
+
import React142, { useCallback as useCallback32 } from "react";
|
21075
|
+
import { selectPeerByID as selectPeerByID4, useHMSActions as useHMSActions43, useHMSStore as useHMSStore69 } from "@100mslive/react-sdk";
|
21076
|
+
import {
|
21077
|
+
ChatUnreadIcon as ChatUnreadIcon2,
|
21078
|
+
ConnectivityIcon,
|
21079
|
+
HandIcon as HandIcon6,
|
21080
|
+
PeopleAddIcon as PeopleAddIcon2,
|
21081
|
+
PeopleRemoveIcon as PeopleRemoveIcon3,
|
21082
|
+
PoorConnectivityIcon as PoorConnectivityIcon2
|
21083
|
+
} from "@100mslive/react-icons";
|
21084
|
+
var ChatAction = React142.forwardRef((_3, ref) => {
|
21085
|
+
const toggleChat = useSidepaneToggle(SIDE_PANE_OPTIONS.CHAT);
|
21086
|
+
const isChatOpen = useIsSidepaneTypeOpen(SIDE_PANE_OPTIONS.CHAT);
|
21087
|
+
if (isChatOpen) {
|
21088
|
+
return null;
|
21089
|
+
}
|
21090
|
+
return /* @__PURE__ */ React142.createElement(Button, { outlined: true, as: "div", variant: "standard", css: { w: "max-content" }, onClick: toggleChat, ref }, "Open Chat");
|
21091
|
+
});
|
21092
|
+
var HandRaiseAction = React142.forwardRef(({ id = "", isSingleHandRaise = true }, ref) => {
|
21093
|
+
var _a7, _b7, _c;
|
21094
|
+
const hmsActions = useHMSActions43();
|
21095
|
+
const toggleSidepane = useSidepaneToggle(SIDE_PANE_OPTIONS.PARTICIPANTS);
|
21096
|
+
const isParticipantsOpen = useIsSidepaneTypeOpen(SIDE_PANE_OPTIONS.PARTICIPANTS);
|
21097
|
+
const peer = useHMSStore69(selectPeerByID4(id));
|
21098
|
+
const layout = useRoomLayout();
|
21099
|
+
const {
|
21100
|
+
bring_to_stage_label,
|
21101
|
+
on_stage_role,
|
21102
|
+
off_stage_roles = []
|
21103
|
+
} = ((_c = (_b7 = (_a7 = layout == null ? void 0 : layout.screens) == null ? void 0 : _a7.conferencing) == null ? void 0 : _b7.default) == null ? void 0 : _c.elements.on_stage_exp) || {};
|
21104
|
+
const onClickHandler = useCallback32(() => {
|
21105
|
+
if (isSingleHandRaise) {
|
21106
|
+
hmsActions.changeRoleOfPeer(id, on_stage_role);
|
21107
|
+
} else {
|
21108
|
+
!isParticipantsOpen && toggleSidepane();
|
21109
|
+
}
|
21110
|
+
}, [hmsActions, id, isParticipantsOpen, isSingleHandRaise, on_stage_role, toggleSidepane]);
|
21111
|
+
if (isSingleHandRaise && (!peer || !off_stage_roles.includes(peer.roleName))) {
|
21112
|
+
return null;
|
21113
|
+
}
|
21114
|
+
return /* @__PURE__ */ React142.createElement(Button, { outlined: true, as: "div", variant: "standard", css: { w: "max-content" }, onClick: onClickHandler, ref }, isSingleHandRaise ? bring_to_stage_label : "View");
|
21115
|
+
});
|
21116
|
+
var ToastConfig = {
|
21117
|
+
PEER_LIST: {
|
21118
|
+
single: function(notification) {
|
21119
|
+
var _a7, _b7;
|
21120
|
+
if (notification.data.length === 1) {
|
21121
|
+
return {
|
21122
|
+
title: `${(_a7 = notification.data[0]) == null ? void 0 : _a7.name} joined`,
|
21123
|
+
icon: /* @__PURE__ */ React142.createElement(PeopleAddIcon2, null)
|
21124
|
+
};
|
21125
|
+
}
|
21126
|
+
return {
|
21127
|
+
title: `${(_b7 = notification.data[notification.data.length - 1]) == null ? void 0 : _b7.name} and ${notification.data.length - 1} others joined`,
|
21128
|
+
icon: /* @__PURE__ */ React142.createElement(PeopleAddIcon2, null)
|
21129
|
+
};
|
21130
|
+
},
|
21131
|
+
multiple: (notifications) => {
|
21132
|
+
return {
|
21133
|
+
title: `${notifications[0].data.name} and ${notifications.length - 1} others joined`,
|
21134
|
+
icon: /* @__PURE__ */ React142.createElement(PeopleAddIcon2, null)
|
21135
|
+
};
|
21136
|
+
}
|
21137
|
+
},
|
21138
|
+
PEER_JOINED: {
|
21139
|
+
single: function(notification) {
|
21140
|
+
var _a7;
|
21141
|
+
return {
|
21142
|
+
title: `${(_a7 = notification.data) == null ? void 0 : _a7.name} joined`,
|
21143
|
+
icon: /* @__PURE__ */ React142.createElement(PeopleAddIcon2, null)
|
21144
|
+
};
|
21145
|
+
},
|
21146
|
+
multiple: function(notifications) {
|
21147
|
+
return {
|
21148
|
+
title: `${notifications[notifications.length - 1].data.name} and ${notifications.length - 1} others joined`,
|
21149
|
+
icon: /* @__PURE__ */ React142.createElement(PeopleAddIcon2, null)
|
21150
|
+
};
|
21151
|
+
}
|
21152
|
+
},
|
21153
|
+
PEER_LEFT: {
|
21154
|
+
single: function(notification) {
|
21155
|
+
var _a7;
|
21156
|
+
return {
|
21157
|
+
title: `${(_a7 = notification.data) == null ? void 0 : _a7.name} left`,
|
21158
|
+
icon: /* @__PURE__ */ React142.createElement(PeopleRemoveIcon3, null)
|
21159
|
+
};
|
21160
|
+
},
|
21161
|
+
multiple: function(notifications) {
|
21162
|
+
return {
|
21163
|
+
title: `${notifications[notifications.length - 1].data.name} and ${notifications.length - 1} others left`,
|
21164
|
+
icon: /* @__PURE__ */ React142.createElement(PeopleRemoveIcon3, null)
|
21165
|
+
};
|
21166
|
+
}
|
21167
|
+
},
|
21168
|
+
RAISE_HAND: {
|
21169
|
+
single: (notification) => {
|
21170
|
+
var _a7, _b7;
|
21171
|
+
return {
|
21172
|
+
title: `${(_a7 = notification.data) == null ? void 0 : _a7.name} raised hand`,
|
21173
|
+
icon: /* @__PURE__ */ React142.createElement(HandIcon6, null),
|
21174
|
+
action: /* @__PURE__ */ React142.createElement(HandRaiseAction, { id: (_b7 = notification.data) == null ? void 0 : _b7.id })
|
21175
|
+
};
|
21176
|
+
},
|
21177
|
+
multiple: (notifications) => {
|
21178
|
+
var _a7;
|
21179
|
+
const count = new Set(notifications.map((notification) => {
|
21180
|
+
var _a8;
|
21181
|
+
return (_a8 = notification.data) == null ? void 0 : _a8.id;
|
21182
|
+
})).size;
|
21183
|
+
return {
|
21184
|
+
title: `${(_a7 = notifications[notifications.length - 1].data) == null ? void 0 : _a7.name} ${count > 1 ? `${count} and others` : ""} raised hand`,
|
21185
|
+
icon: /* @__PURE__ */ React142.createElement(HandIcon6, null),
|
21186
|
+
action: /* @__PURE__ */ React142.createElement(HandRaiseAction, { isSingleHandRaise: false })
|
21187
|
+
};
|
21188
|
+
}
|
21189
|
+
},
|
21190
|
+
NEW_MESSAGE: {
|
21191
|
+
single: (notification) => {
|
21192
|
+
var _a7;
|
21193
|
+
return {
|
21194
|
+
title: `New message from ${(_a7 = notification.data) == null ? void 0 : _a7.senderName}`,
|
21195
|
+
icon: /* @__PURE__ */ React142.createElement(ChatUnreadIcon2, null),
|
21196
|
+
action: /* @__PURE__ */ React142.createElement(ChatAction, null)
|
21197
|
+
};
|
21198
|
+
},
|
21199
|
+
multiple: (notifications) => {
|
21200
|
+
return {
|
21201
|
+
title: `${notifications.length} new messages`,
|
21202
|
+
icon: /* @__PURE__ */ React142.createElement(ChatUnreadIcon2, null),
|
21203
|
+
action: /* @__PURE__ */ React142.createElement(ChatAction, null)
|
21204
|
+
};
|
21205
|
+
}
|
21206
|
+
},
|
21207
|
+
RECONNECTED: {
|
21208
|
+
single: () => {
|
21209
|
+
return {
|
21210
|
+
title: `You are now connected`,
|
21211
|
+
icon: /* @__PURE__ */ React142.createElement(ConnectivityIcon, null),
|
21212
|
+
variant: "success",
|
21213
|
+
duration: 3e3
|
21214
|
+
};
|
21215
|
+
}
|
21216
|
+
},
|
21217
|
+
RECONNECTING: {
|
21218
|
+
single: (message) => {
|
21219
|
+
return {
|
21220
|
+
title: `You are offline for now. while we try to reconnect, please check
|
21221
|
+
your internet connection. ${message}.
|
21222
|
+
`,
|
21223
|
+
icon: /* @__PURE__ */ React142.createElement(PoorConnectivityIcon2, null),
|
21224
|
+
variant: "warning",
|
21225
|
+
duration: 3e4
|
21226
|
+
};
|
21227
|
+
}
|
21228
|
+
}
|
21229
|
+
};
|
21230
|
+
|
21231
|
+
// src/Prebuilt/components/Toast/ToastBatcher.js
|
21232
|
+
var ToastBatcher = {
|
21233
|
+
toastsType: /* @__PURE__ */ new Map(),
|
21234
|
+
showToastInternal({ notification, duration, type }) {
|
21235
|
+
let notificationType = type;
|
21236
|
+
if (!type) {
|
21237
|
+
notificationType = notification.type;
|
21238
|
+
}
|
21239
|
+
const toastType = this.toastsType.has(notificationType);
|
21240
|
+
if (toastType) {
|
21241
|
+
let { notifications } = this.toastsType.get(notificationType);
|
21242
|
+
const { id } = this.toastsType.get(notificationType);
|
21243
|
+
notifications.push(notification);
|
21244
|
+
const toastObject = ToastConfig[notificationType].multiple(notifications);
|
21245
|
+
const toastId = ToastManager.replaceToast(id, __spreadProps(__spreadValues({}, toastObject), {
|
21246
|
+
duration
|
21247
|
+
}));
|
21248
|
+
this.toastsType.set(notificationType, {
|
21249
|
+
id: toastId,
|
21250
|
+
notifications,
|
21251
|
+
duration
|
21252
|
+
});
|
21253
|
+
} else {
|
21254
|
+
const toastObject = ToastConfig[notificationType].single(notification);
|
21255
|
+
const toastId = ToastManager.addToast(__spreadProps(__spreadValues({}, toastObject), {
|
21256
|
+
duration
|
21257
|
+
}));
|
21258
|
+
let notifications = [];
|
21259
|
+
notifications.push(notification);
|
21260
|
+
this.toastsType.set(notificationType, {
|
21261
|
+
id: toastId,
|
21262
|
+
notifications: [...notifications],
|
21263
|
+
duration
|
21264
|
+
});
|
21265
|
+
}
|
21266
|
+
},
|
21267
|
+
showToast({ notification, duration = 3e3, type }) {
|
21268
|
+
try {
|
21269
|
+
this.showToastInternal({ notification, duration, type });
|
21270
|
+
} catch (err) {
|
21271
|
+
console.debug("Notifications", err);
|
21272
|
+
}
|
21273
|
+
},
|
21274
|
+
syncUItoast(toastsDisplaying) {
|
21275
|
+
for (const [toastType, toastInfo] of this.toastsType.entries()) {
|
21276
|
+
if (!toastsDisplaying.find((toast) => toast.id === toastInfo.id)) {
|
21277
|
+
this.toastsType.delete(toastType);
|
21278
|
+
}
|
21279
|
+
}
|
21280
|
+
}
|
21281
|
+
};
|
21282
|
+
ToastManager.addListener(ToastBatcher.syncUItoast.bind(ToastBatcher));
|
21283
|
+
|
21279
21284
|
// src/Prebuilt/components/Notifications/AutoplayBlockedModal.tsx
|
21280
21285
|
init_define_process_env();
|
21281
21286
|
import React143 from "react";
|
@@ -21307,15 +21312,44 @@ function AutoplayBlockedModal() {
|
|
21307
21312
|
);
|
21308
21313
|
}
|
21309
21314
|
|
21315
|
+
// src/Prebuilt/components/Notifications/ChatNotifications.tsx
|
21316
|
+
init_define_process_env();
|
21317
|
+
import React144, { useEffect as useEffect47 } from "react";
|
21318
|
+
import { v4 as uuid2 } from "uuid";
|
21319
|
+
import { selectLocalPeerID as selectLocalPeerID13, selectSessionStore as selectSessionStore7, useHMSStore as useHMSStore70 } from "@100mslive/react-sdk";
|
21320
|
+
import { ChatIcon as ChatIcon2, ChatUnreadIcon as ChatUnreadIcon3 } from "@100mslive/react-icons";
|
21321
|
+
var NOTIFICATION_TIME_DIFFERENCE = 5e3;
|
21322
|
+
var ChatNotifications = () => {
|
21323
|
+
const chatState = useHMSStore70(selectSessionStore7("chatState" /* CHAT_STATE */));
|
21324
|
+
const localPeerId = useHMSStore70(selectLocalPeerID13);
|
21325
|
+
useEffect47(() => {
|
21326
|
+
var _a7, _b7;
|
21327
|
+
if (!chatState || ((_a7 = chatState.updatedBy) == null ? void 0 : _a7.peerId) === localPeerId) {
|
21328
|
+
return;
|
21329
|
+
}
|
21330
|
+
const showToast = Date.now() - chatState.updatedAt < NOTIFICATION_TIME_DIFFERENCE;
|
21331
|
+
if (!showToast) {
|
21332
|
+
return;
|
21333
|
+
}
|
21334
|
+
const notification = {
|
21335
|
+
id: uuid2(),
|
21336
|
+
icon: chatState.enabled ? /* @__PURE__ */ React144.createElement(ChatUnreadIcon3, null) : /* @__PURE__ */ React144.createElement(ChatIcon2, null),
|
21337
|
+
title: `Chat ${chatState.enabled ? "resumed" : "paused"} by ${(_b7 = chatState.updatedBy) == null ? void 0 : _b7.userName}`
|
21338
|
+
};
|
21339
|
+
ToastManager.addToast(notification);
|
21340
|
+
}, [chatState]);
|
21341
|
+
return /* @__PURE__ */ React144.createElement(React144.Fragment, null);
|
21342
|
+
};
|
21343
|
+
|
21310
21344
|
// src/Prebuilt/components/Notifications/InitErrorModal.tsx
|
21311
21345
|
init_define_process_env();
|
21312
|
-
import
|
21346
|
+
import React145, { useEffect as useEffect48, useState as useState57 } from "react";
|
21313
21347
|
import { HMSNotificationTypes as HMSNotificationTypes2, useHMSNotifications as useHMSNotifications2 } from "@100mslive/react-sdk";
|
21314
21348
|
var InitErrorModal = () => {
|
21315
21349
|
const notification = useHMSNotifications2(HMSNotificationTypes2.ERROR);
|
21316
21350
|
const [showModal, setShowModal] = useState57(false);
|
21317
21351
|
const [info, setInfo] = useState57({ title: "Init Error", description: "" });
|
21318
|
-
|
21352
|
+
useEffect48(() => {
|
21319
21353
|
const data3 = notification == null ? void 0 : notification.data;
|
21320
21354
|
if (!data3 || data3.action !== "INIT") {
|
21321
21355
|
return;
|
@@ -21335,12 +21369,12 @@ var InitErrorModal = () => {
|
|
21335
21369
|
setInfo({ title, description });
|
21336
21370
|
setShowModal(true);
|
21337
21371
|
}, [notification]);
|
21338
|
-
return /* @__PURE__ */
|
21372
|
+
return /* @__PURE__ */ React145.createElement(ErrorDialog, { open: showModal, onOpenChange: setShowModal, title: info.title }, /* @__PURE__ */ React145.createElement(Text, { variant: "sm", css: { wordBreak: "break-word" } }, info.description, " ", /* @__PURE__ */ React145.createElement("br", null), "Current URL - ", window.location.href));
|
21339
21373
|
};
|
21340
21374
|
|
21341
21375
|
// src/Prebuilt/components/Notifications/PeerNotifications.tsx
|
21342
21376
|
init_define_process_env();
|
21343
|
-
import { useEffect as
|
21377
|
+
import { useEffect as useEffect49 } from "react";
|
21344
21378
|
import { HMSNotificationTypes as HMSNotificationTypes3, useHMSNotifications as useHMSNotifications3 } from "@100mslive/react-sdk";
|
21345
21379
|
var notificationTypes = [
|
21346
21380
|
HMSNotificationTypes3.PEER_LIST,
|
@@ -21351,7 +21385,7 @@ var PeerNotifications = () => {
|
|
21351
21385
|
const notification = useHMSNotifications3(notificationTypes);
|
21352
21386
|
const isPeerJoinSubscribed = useSubscribedNotifications(SUBSCRIBED_NOTIFICATIONS.PEER_JOINED);
|
21353
21387
|
const isPeerLeftSubscribed = useSubscribedNotifications(SUBSCRIBED_NOTIFICATIONS.PEER_LEFT);
|
21354
|
-
|
21388
|
+
useEffect49(() => {
|
21355
21389
|
if (!(notification == null ? void 0 : notification.data)) {
|
21356
21390
|
return;
|
21357
21391
|
}
|
@@ -21382,7 +21416,7 @@ var PeerNotifications = () => {
|
|
21382
21416
|
|
21383
21417
|
// src/Prebuilt/components/Notifications/PermissionErrorModal.tsx
|
21384
21418
|
init_define_process_env();
|
21385
|
-
import
|
21419
|
+
import React146, { useEffect as useEffect50, useState as useState58 } from "react";
|
21386
21420
|
import { useMedia as useMedia29 } from "react-use";
|
21387
21421
|
import { HMSNotificationTypes as HMSNotificationTypes4, useHMSNotifications as useHMSNotifications4 } from "@100mslive/react-sdk";
|
21388
21422
|
|
@@ -21398,7 +21432,7 @@ function PermissionErrorModal() {
|
|
21398
21432
|
const [deviceType, setDeviceType] = useState58("");
|
21399
21433
|
const [isSystemError, setIsSystemError] = useState58(false);
|
21400
21434
|
const isMobile = useMedia29(config.media.md);
|
21401
|
-
|
21435
|
+
useEffect50(() => {
|
21402
21436
|
var _a7, _b7, _c, _d, _e;
|
21403
21437
|
if (!notification || ((_a7 = notification.data) == null ? void 0 : _a7.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"))) {
|
21404
21438
|
return;
|
@@ -21419,15 +21453,15 @@ function PermissionErrorModal() {
|
|
21419
21453
|
}
|
21420
21454
|
setIsSystemError(notification.data.code === 3011);
|
21421
21455
|
}, [notification]);
|
21422
|
-
return deviceType ? /* @__PURE__ */
|
21456
|
+
return deviceType ? /* @__PURE__ */ React146.createElement(Dialog.Root, { open: !!deviceType }, /* @__PURE__ */ React146.createElement(Dialog.Portal, null, /* @__PURE__ */ React146.createElement(Dialog.Overlay, null), /* @__PURE__ */ React146.createElement(Dialog.Content, { css: { w: "min(380px, 90%)", p: "$8" } }, /* @__PURE__ */ React146.createElement(
|
21423
21457
|
Dialog.Title,
|
21424
21458
|
{
|
21425
21459
|
css: {
|
21426
21460
|
borderBottom: "1px solid $border_default"
|
21427
21461
|
}
|
21428
21462
|
},
|
21429
|
-
isMobile && isIOS ? /* @__PURE__ */
|
21430
|
-
isMobile && isAndroid ? /* @__PURE__ */
|
21463
|
+
isMobile && isIOS ? /* @__PURE__ */ React146.createElement("img", { style: { maxWidth: "100%", maxHeight: "100%" }, src: ios_perm_0_default, alt: "iOS Permission flow" }) : null,
|
21464
|
+
isMobile && isAndroid ? /* @__PURE__ */ React146.createElement(
|
21431
21465
|
"img",
|
21432
21466
|
{
|
21433
21467
|
src: android_perm_1_default,
|
@@ -21435,13 +21469,13 @@ function PermissionErrorModal() {
|
|
21435
21469
|
alt: "Android Permission flow "
|
21436
21470
|
}
|
21437
21471
|
) : null,
|
21438
|
-
/* @__PURE__ */
|
21439
|
-
), /* @__PURE__ */
|
21472
|
+
/* @__PURE__ */ React146.createElement(Text, { variant: "h6" }, "We can't access your ", deviceType)
|
21473
|
+
), /* @__PURE__ */ React146.createElement(Text, { variant: "sm", css: { pt: "$4", pb: "$10", color: "$on_surface_medium" } }, isMobile && isIOS ? 'Enable permissions by reloading this page and clicking "Allow" on the pop-up, or change settings from the address bar.' : null, isMobile && isAndroid ? `To allow other users to see and hear you, click the blocked camera icon in your browser's address bar.` : null, !isMobile ? `Access to ${deviceType} is required. ` : null, isSystemError && !isMobile ? `Enable permissions for ${deviceType}${deviceType === "screen" ? "share" : ""} from sytem settings` : null, !isSystemError && !isMobile ? `Enable permissions for ${deviceType}${deviceType === "screen" ? "share" : ""} from address bar or browser settings.` : null), isMobile && isIOS ? /* @__PURE__ */ React146.createElement(React146.Fragment, null, /* @__PURE__ */ React146.createElement(Button, { onClick: () => window.location.reload(), css: { w: "100%", mb: "$6" } }, "Reload"), /* @__PURE__ */ React146.createElement(Button, { outlined: true, variant: "standard", onClick: () => setDeviceType(""), css: { w: "100%" } }, "Continue anyway")) : null, isMobile && isAndroid ? /* @__PURE__ */ React146.createElement(React146.Fragment, null, /* @__PURE__ */ React146.createElement(Button, { onClick: () => setDeviceType(""), css: { w: "100%", mb: "$6" } }, "I've allowed access"), /* @__PURE__ */ React146.createElement(Button, { outlined: true, variant: "standard", onClick: () => setDeviceType(""), css: { w: "100%" } }, "Continue anyway")) : null, !isMobile ? /* @__PURE__ */ React146.createElement(Flex, { justify: "end", css: { w: "100%" } }, /* @__PURE__ */ React146.createElement(Button, { outlined: true, variant: "standard", onClick: () => setDeviceType("") }, "Dismiss")) : null))) : null;
|
21440
21474
|
}
|
21441
21475
|
|
21442
21476
|
// src/Prebuilt/components/Notifications/ReconnectNotifications.tsx
|
21443
21477
|
init_define_process_env();
|
21444
|
-
import
|
21478
|
+
import React147, { useEffect as useEffect51, useState as useState59 } from "react";
|
21445
21479
|
import { HMSNotificationTypes as HMSNotificationTypes5, useHMSNotifications as useHMSNotifications5 } from "@100mslive/react-sdk";
|
21446
21480
|
var notificationTypes2 = [
|
21447
21481
|
HMSNotificationTypes5.RECONNECTED,
|
@@ -21452,7 +21486,7 @@ var notificationId = null;
|
|
21452
21486
|
var ReconnectNotifications = () => {
|
21453
21487
|
const notification = useHMSNotifications5(notificationTypes2);
|
21454
21488
|
const [open, setOpen] = useState59(false);
|
21455
|
-
|
21489
|
+
useEffect51(() => {
|
21456
21490
|
var _a7, _b7;
|
21457
21491
|
if (!notification) {
|
21458
21492
|
return;
|
@@ -21471,7 +21505,7 @@ var ReconnectNotifications = () => {
|
|
21471
21505
|
}, [notification]);
|
21472
21506
|
if (!open)
|
21473
21507
|
return null;
|
21474
|
-
return /* @__PURE__ */
|
21508
|
+
return /* @__PURE__ */ React147.createElement(Dialog.Root, { open, modal: true }, /* @__PURE__ */ React147.createElement(Dialog.Portal, { container: document.getElementById("conferencing") }, /* @__PURE__ */ React147.createElement(Dialog.Overlay, null), /* @__PURE__ */ React147.createElement(
|
21475
21509
|
Dialog.Content,
|
21476
21510
|
{
|
21477
21511
|
css: {
|
@@ -21485,13 +21519,13 @@ var ReconnectNotifications = () => {
|
|
21485
21519
|
animation: "none !important"
|
21486
21520
|
}
|
21487
21521
|
},
|
21488
|
-
/* @__PURE__ */
|
21522
|
+
/* @__PURE__ */ React147.createElement(Flex, { align: "center" }, /* @__PURE__ */ React147.createElement("div", { style: { display: "inline", margin: "0.25rem" } }, /* @__PURE__ */ React147.createElement(Loading, { size: 16 })), /* @__PURE__ */ React147.createElement(Text, { css: { fontSize: "$space$8", color: "$on_surface_high" } }, "You lost your network connection. Trying to reconnect."))
|
21489
21523
|
)));
|
21490
21524
|
};
|
21491
21525
|
|
21492
21526
|
// src/Prebuilt/components/Notifications/TrackBulkUnmuteModal.tsx
|
21493
21527
|
init_define_process_env();
|
21494
|
-
import
|
21528
|
+
import React148, { useEffect as useEffect52, useState as useState60 } from "react";
|
21495
21529
|
import {
|
21496
21530
|
HMSNotificationTypes as HMSNotificationTypes6,
|
21497
21531
|
useHMSActions as useHMSActions44,
|
@@ -21506,7 +21540,7 @@ var TrackBulkUnmuteModal = () => {
|
|
21506
21540
|
HMSNotificationTypes6.ROOM_ENDED,
|
21507
21541
|
HMSNotificationTypes6.REMOVED_FROM_ROOM
|
21508
21542
|
]);
|
21509
|
-
|
21543
|
+
useEffect52(() => {
|
21510
21544
|
switch (notification == null ? void 0 : notification.type) {
|
21511
21545
|
case HMSNotificationTypes6.REMOVED_FROM_ROOM:
|
21512
21546
|
case HMSNotificationTypes6.ROOM_ENDED:
|
@@ -21525,7 +21559,7 @@ var TrackBulkUnmuteModal = () => {
|
|
21525
21559
|
return null;
|
21526
21560
|
}
|
21527
21561
|
const { requestedBy: peer, tracks, enabled } = muteNotification;
|
21528
|
-
return /* @__PURE__ */
|
21562
|
+
return /* @__PURE__ */ React148.createElement(
|
21529
21563
|
RequestDialog,
|
21530
21564
|
{
|
21531
21565
|
title: "Track Unmute Request",
|
@@ -21544,7 +21578,7 @@ var TrackBulkUnmuteModal = () => {
|
|
21544
21578
|
|
21545
21579
|
// src/Prebuilt/components/Notifications/TrackNotifications.tsx
|
21546
21580
|
init_define_process_env();
|
21547
|
-
import { useEffect as
|
21581
|
+
import { useEffect as useEffect53 } from "react";
|
21548
21582
|
import { HMSNotificationTypes as HMSNotificationTypes7, useHMSNotifications as useHMSNotifications7 } from "@100mslive/react-sdk";
|
21549
21583
|
var notificationTypes3 = [
|
21550
21584
|
HMSNotificationTypes7.TRACK_ADDED,
|
@@ -21554,7 +21588,7 @@ var notificationTypes3 = [
|
|
21554
21588
|
];
|
21555
21589
|
var TrackNotifications = () => {
|
21556
21590
|
const notification = useHMSNotifications7(notificationTypes3);
|
21557
|
-
|
21591
|
+
useEffect53(() => {
|
21558
21592
|
if (notification) {
|
21559
21593
|
console.debug(`[${notification.type}]`, notification);
|
21560
21594
|
}
|
@@ -21564,7 +21598,7 @@ var TrackNotifications = () => {
|
|
21564
21598
|
|
21565
21599
|
// src/Prebuilt/components/Notifications/TrackUnmuteModal.tsx
|
21566
21600
|
init_define_process_env();
|
21567
|
-
import
|
21601
|
+
import React149, { useEffect as useEffect54, useState as useState61 } from "react";
|
21568
21602
|
import {
|
21569
21603
|
HMSNotificationTypes as HMSNotificationTypes8,
|
21570
21604
|
useHMSActions as useHMSActions45,
|
@@ -21579,7 +21613,7 @@ var TrackUnmuteModal = () => {
|
|
21579
21613
|
HMSNotificationTypes8.REMOVED_FROM_ROOM
|
21580
21614
|
]);
|
21581
21615
|
const [muteNotification, setMuteNotification] = useState61(null);
|
21582
|
-
|
21616
|
+
useEffect54(() => {
|
21583
21617
|
switch (notification == null ? void 0 : notification.type) {
|
21584
21618
|
case HMSNotificationTypes8.REMOVED_FROM_ROOM:
|
21585
21619
|
case HMSNotificationTypes8.ROOM_ENDED:
|
@@ -21598,7 +21632,7 @@ var TrackUnmuteModal = () => {
|
|
21598
21632
|
return null;
|
21599
21633
|
}
|
21600
21634
|
const { requestedBy: peer, track, enabled } = muteNotification;
|
21601
|
-
return /* @__PURE__ */
|
21635
|
+
return /* @__PURE__ */ React149.createElement(
|
21602
21636
|
RequestDialog,
|
21603
21637
|
{
|
21604
21638
|
title: "Track Unmute Request",
|
@@ -21615,10 +21649,10 @@ var TrackUnmuteModal = () => {
|
|
21615
21649
|
|
21616
21650
|
// src/Prebuilt/components/Notifications/Notifications.tsx
|
21617
21651
|
function Notifications() {
|
21618
|
-
const localPeerID =
|
21652
|
+
const localPeerID = useHMSStore71(selectLocalPeerID14);
|
21619
21653
|
const notification = useHMSNotifications9();
|
21620
21654
|
const subscribedNotifications = useSubscribedNotifications() || {};
|
21621
|
-
const roomState =
|
21655
|
+
const roomState = useHMSStore71(selectRoomState9);
|
21622
21656
|
const updateRoomLayoutForRole = useUpdateRoomLayout();
|
21623
21657
|
const isNotificationDisabled = useIsNotificationDisabled();
|
21624
21658
|
const vanillaStore = useHMSVanillaStore12();
|
@@ -21630,8 +21664,8 @@ function Notifications() {
|
|
21630
21664
|
});
|
21631
21665
|
}, []);
|
21632
21666
|
useCustomEvent4({ type: ROLE_CHANGE_DECLINED, onEvent: handleRoleChangeDenied });
|
21633
|
-
|
21634
|
-
var _a7, _b7, _c, _d, _e, _f, _g, _h,
|
21667
|
+
useEffect55(() => {
|
21668
|
+
var _a7, _b7, _c, _d, _e, _f, _g, _h, _i2, _j, _k, _l, _m, _n, _o, _p;
|
21635
21669
|
if (!notification || isNotificationDisabled) {
|
21636
21670
|
return;
|
21637
21671
|
}
|
@@ -21675,7 +21709,7 @@ function Notifications() {
|
|
21675
21709
|
}
|
21676
21710
|
return;
|
21677
21711
|
}
|
21678
|
-
if (((_g = notification.data) == null ? void 0 : _g.code) === 3008 || ((_h = notification.data) == null ? void 0 : _h.code) === 3001 || ((
|
21712
|
+
if (((_g = notification.data) == null ? void 0 : _g.code) === 3008 || ((_h = notification.data) == null ? void 0 : _h.code) === 3001 || ((_i2 = notification.data) == null ? void 0 : _i2.code) === 3011) {
|
21679
21713
|
return;
|
21680
21714
|
}
|
21681
21715
|
if (((_j = notification.data) == null ? void 0 : _j.action) === "INIT") {
|
@@ -21722,7 +21756,7 @@ function Notifications() {
|
|
21722
21756
|
const pollStartedBy = vanillaStore.getState(selectPeerNameByID6(notification.data.startedBy)) || "Participant";
|
21723
21757
|
ToastManager.addToast({
|
21724
21758
|
title: `${pollStartedBy} started a ${notification.data.type}: ${notification.data.title}`,
|
21725
|
-
action: /* @__PURE__ */
|
21759
|
+
action: /* @__PURE__ */ React150.createElement(
|
21726
21760
|
Button,
|
21727
21761
|
{
|
21728
21762
|
onClick: () => togglePollView(notification.data.id),
|
@@ -21746,12 +21780,12 @@ function Notifications() {
|
|
21746
21780
|
if (isNotificationDisabled) {
|
21747
21781
|
return null;
|
21748
21782
|
}
|
21749
|
-
return /* @__PURE__ */
|
21783
|
+
return /* @__PURE__ */ React150.createElement(React150.Fragment, null, /* @__PURE__ */ React150.createElement(TrackUnmuteModal, null), /* @__PURE__ */ React150.createElement(TrackBulkUnmuteModal, null), /* @__PURE__ */ React150.createElement(TrackNotifications, null), roomState === HMSRoomState9.Connected ? /* @__PURE__ */ React150.createElement(PeerNotifications, null) : null, /* @__PURE__ */ React150.createElement(ReconnectNotifications, null), /* @__PURE__ */ React150.createElement(AutoplayBlockedModal, null), /* @__PURE__ */ React150.createElement(PermissionErrorModal, null), /* @__PURE__ */ React150.createElement(InitErrorModal, null), /* @__PURE__ */ React150.createElement(ChatNotifications, null));
|
21750
21784
|
}
|
21751
21785
|
|
21752
21786
|
// src/Prebuilt/components/Preview/PreviewScreen.tsx
|
21753
21787
|
init_define_process_env();
|
21754
|
-
import
|
21788
|
+
import React151 from "react";
|
21755
21789
|
import { useSearchParam } from "react-use";
|
21756
21790
|
var PreviewScreen = () => {
|
21757
21791
|
var _a7, _b7, _c;
|
@@ -21763,28 +21797,28 @@ var PreviewScreen = () => {
|
|
21763
21797
|
const authToken = useAuthToken();
|
21764
21798
|
const roomLayout = useRoomLayout();
|
21765
21799
|
const { preview_header: previewHeader = {} } = ((_c = (_b7 = (_a7 = roomLayout == null ? void 0 : roomLayout.screens) == null ? void 0 : _a7.preview) == null ? void 0 : _b7.default) == null ? void 0 : _c.elements) || {};
|
21766
|
-
return /* @__PURE__ */
|
21800
|
+
return /* @__PURE__ */ React151.createElement(Flex, { direction: "column", css: { size: "100%" } }, /* @__PURE__ */ React151.createElement(
|
21767
21801
|
Flex,
|
21768
21802
|
{
|
21769
21803
|
css: { flex: "1 1 0", position: "relative", overflowY: "auto", color: "$primary_default" },
|
21770
21804
|
justify: "center",
|
21771
21805
|
align: "center"
|
21772
21806
|
},
|
21773
|
-
authToken && Object.keys(previewHeader).length > 0 ? /* @__PURE__ */
|
21807
|
+
authToken && Object.keys(previewHeader).length > 0 ? /* @__PURE__ */ React151.createElement(PreviewJoin_default, { initialName, skipPreview, asRole: previewAsRole != null ? previewAsRole : void 0 }) : /* @__PURE__ */ React151.createElement(FullPageProgress_default, null)
|
21774
21808
|
));
|
21775
21809
|
};
|
21776
21810
|
|
21777
21811
|
// src/Prebuilt/components/Toast/ToastContainer.jsx
|
21778
21812
|
init_define_process_env();
|
21779
|
-
import
|
21780
|
-
import { selectIsConnectedToRoom as selectIsConnectedToRoom11, useHMSStore as
|
21813
|
+
import React153, { useEffect as useEffect56, useState as useState62 } from "react";
|
21814
|
+
import { selectIsConnectedToRoom as selectIsConnectedToRoom11, useHMSStore as useHMSStore72 } from "@100mslive/react-sdk";
|
21781
21815
|
|
21782
21816
|
// src/Prebuilt/components/Toast/Toast.jsx
|
21783
21817
|
init_define_process_env();
|
21784
|
-
import
|
21818
|
+
import React152 from "react";
|
21785
21819
|
var Toast2 = (_a7) => {
|
21786
21820
|
var _b7 = _a7, { title, description, close = true, open, duration, onOpenChange, icon } = _b7, props = __objRest(_b7, ["title", "description", "close", "open", "duration", "onOpenChange", "icon"]);
|
21787
|
-
return /* @__PURE__ */
|
21821
|
+
return /* @__PURE__ */ React152.createElement(
|
21788
21822
|
Toast.HMSToast,
|
21789
21823
|
__spreadValues({
|
21790
21824
|
title,
|
@@ -21800,17 +21834,17 @@ var Toast2 = (_a7) => {
|
|
21800
21834
|
|
21801
21835
|
// src/Prebuilt/components/Toast/ToastContainer.jsx
|
21802
21836
|
var ToastContainer = () => {
|
21803
|
-
const isConnected =
|
21837
|
+
const isConnected = useHMSStore72(selectIsConnectedToRoom11);
|
21804
21838
|
const [toasts, setToast] = useState62([]);
|
21805
|
-
|
21839
|
+
useEffect56(() => {
|
21806
21840
|
ToastManager.addListener(setToast);
|
21807
21841
|
return () => {
|
21808
21842
|
ToastManager.removeListener(setToast);
|
21809
21843
|
};
|
21810
21844
|
}, []);
|
21811
|
-
return /* @__PURE__ */
|
21812
|
-
return /* @__PURE__ */
|
21813
|
-
}), /* @__PURE__ */
|
21845
|
+
return /* @__PURE__ */ React153.createElement(Toast.Provider, { swipeDirection: "left", duration: 3e3 }, toasts.slice(0, MAX_TOASTS).map((toast) => {
|
21846
|
+
return /* @__PURE__ */ React153.createElement(Toast2, __spreadProps(__spreadValues({ key: toast.id }, toast), { onOpenChange: (value) => !value && ToastManager.removeToast(toast.id) }));
|
21847
|
+
}), /* @__PURE__ */ React153.createElement(
|
21814
21848
|
Toast.Viewport,
|
21815
21849
|
{
|
21816
21850
|
css: __spreadValues({
|
@@ -21822,13 +21856,13 @@ var ToastContainer = () => {
|
|
21822
21856
|
|
21823
21857
|
// src/Prebuilt/plugins/FlyingEmoji.jsx
|
21824
21858
|
init_define_process_env();
|
21825
|
-
import
|
21859
|
+
import React154, { useCallback as useCallback34, useEffect as useEffect57, useMemo as useMemo16, useState as useState63 } from "react";
|
21826
21860
|
import { useMedia as useMedia30 } from "react-use";
|
21827
21861
|
import {
|
21828
21862
|
selectLocalPeerID as selectLocalPeerID15,
|
21829
21863
|
selectPeerNameByID as selectPeerNameByID7,
|
21830
21864
|
useCustomEvent as useCustomEvent5,
|
21831
|
-
useHMSStore as
|
21865
|
+
useHMSStore as useHMSStore73,
|
21832
21866
|
useHMSVanillaStore as useHMSVanillaStore13
|
21833
21867
|
} from "@100mslive/react-sdk";
|
21834
21868
|
var emojiCount = 1;
|
@@ -21855,7 +21889,7 @@ var getStartingPoints = (isMobile) => {
|
|
21855
21889
|
return arr;
|
21856
21890
|
};
|
21857
21891
|
function FlyingEmoji() {
|
21858
|
-
const localPeerId =
|
21892
|
+
const localPeerId = useHMSStore73(selectLocalPeerID15);
|
21859
21893
|
const vanillaStore = useHMSVanillaStore13();
|
21860
21894
|
const [emojis, setEmojis] = useState63([]);
|
21861
21895
|
const isMobile = useMedia30(config.media.md);
|
@@ -21888,10 +21922,10 @@ function FlyingEmoji() {
|
|
21888
21922
|
type: EMOJI_REACTION_TYPE,
|
21889
21923
|
onEvent: showFlyingEmoji
|
21890
21924
|
});
|
21891
|
-
|
21925
|
+
useEffect57(() => {
|
21892
21926
|
window.showFlyingEmoji = showFlyingEmoji;
|
21893
21927
|
}, [showFlyingEmoji]);
|
21894
|
-
return /* @__PURE__ */
|
21928
|
+
return /* @__PURE__ */ React154.createElement(
|
21895
21929
|
Box,
|
21896
21930
|
{
|
21897
21931
|
css: {
|
@@ -21907,7 +21941,7 @@ function FlyingEmoji() {
|
|
21907
21941
|
}
|
21908
21942
|
},
|
21909
21943
|
emojis.map((emoji) => {
|
21910
|
-
return /* @__PURE__ */
|
21944
|
+
return /* @__PURE__ */ React154.createElement(
|
21911
21945
|
Flex,
|
21912
21946
|
{
|
21913
21947
|
key: emoji.id,
|
@@ -21923,8 +21957,8 @@ function FlyingEmoji() {
|
|
21923
21957
|
setEmojis(emojis.filter((item) => item.id !== emoji.id));
|
21924
21958
|
}
|
21925
21959
|
},
|
21926
|
-
/* @__PURE__ */
|
21927
|
-
/* @__PURE__ */
|
21960
|
+
/* @__PURE__ */ React154.createElement(Box, null, /* @__PURE__ */ React154.createElement("em-emoji", { id: emoji.emojiId, size: "48px", set: "apple" })),
|
21961
|
+
/* @__PURE__ */ React154.createElement(
|
21928
21962
|
Box,
|
21929
21963
|
{
|
21930
21964
|
css: {
|
@@ -21934,7 +21968,7 @@ function FlyingEmoji() {
|
|
21934
21968
|
borderRadius: "$1"
|
21935
21969
|
}
|
21936
21970
|
},
|
21937
|
-
/* @__PURE__ */
|
21971
|
+
/* @__PURE__ */ React154.createElement(
|
21938
21972
|
Text,
|
21939
21973
|
{
|
21940
21974
|
css: {
|
@@ -21953,7 +21987,7 @@ function FlyingEmoji() {
|
|
21953
21987
|
|
21954
21988
|
// src/Prebuilt/plugins/RemoteStopScreenshare.jsx
|
21955
21989
|
init_define_process_env();
|
21956
|
-
import
|
21990
|
+
import React155, { useCallback as useCallback35 } from "react";
|
21957
21991
|
import { useCustomEvent as useCustomEvent6, useHMSActions as useHMSActions46 } from "@100mslive/react-sdk";
|
21958
21992
|
function RemoteStopScreenshare() {
|
21959
21993
|
const actions = useHMSActions46();
|
@@ -21964,25 +21998,25 @@ function RemoteStopScreenshare() {
|
|
21964
21998
|
type: REMOTE_STOP_SCREENSHARE_TYPE,
|
21965
21999
|
onEvent: onRemoteStopScreenshare
|
21966
22000
|
});
|
21967
|
-
return /* @__PURE__ */
|
22001
|
+
return /* @__PURE__ */ React155.createElement(React155.Fragment, null);
|
21968
22002
|
}
|
21969
22003
|
|
21970
22004
|
// src/Prebuilt/components/hooks/useAutoStartStreaming.tsx
|
21971
22005
|
init_define_process_env();
|
21972
|
-
import { useCallback as useCallback36, useEffect as
|
22006
|
+
import { useCallback as useCallback36, useEffect as useEffect58, useRef as useRef24 } from "react";
|
21973
22007
|
import {
|
21974
22008
|
selectIsConnectedToRoom as selectIsConnectedToRoom12,
|
21975
|
-
selectPermissions as
|
22009
|
+
selectPermissions as selectPermissions15,
|
21976
22010
|
useHMSActions as useHMSActions47,
|
21977
|
-
useHMSStore as
|
22011
|
+
useHMSStore as useHMSStore74,
|
21978
22012
|
useRecordingStreaming as useRecordingStreaming10
|
21979
22013
|
} from "@100mslive/react-sdk";
|
21980
22014
|
var useAutoStartStreaming = () => {
|
21981
22015
|
const [isHLSStarted, setHLSStarted] = useSetAppDataByKey(APP_DATA.hlsStarted);
|
21982
|
-
const permissions =
|
22016
|
+
const permissions = useHMSStore74(selectPermissions15);
|
21983
22017
|
const showStreamingUI = useShowStreamingUI();
|
21984
22018
|
const hmsActions = useHMSActions47();
|
21985
|
-
const isConnected =
|
22019
|
+
const isConnected = useHMSStore74(selectIsConnectedToRoom12);
|
21986
22020
|
const { isHLSRunning, isRTMPRunning, isHLSRecordingOn, isBrowserRecordingOn } = useRecordingStreaming10();
|
21987
22021
|
const streamStartedRef = useRef24(false);
|
21988
22022
|
const startHLS = useCallback36(() => __async(void 0, null, function* () {
|
@@ -22008,12 +22042,12 @@ var useAutoStartStreaming = () => {
|
|
22008
22042
|
isHLSRecordingOn,
|
22009
22043
|
isBrowserRecordingOn
|
22010
22044
|
]);
|
22011
|
-
|
22045
|
+
useEffect58(() => {
|
22012
22046
|
if (!isHLSStarted && !isHLSRunning) {
|
22013
22047
|
streamStartedRef.current = false;
|
22014
22048
|
}
|
22015
22049
|
}, [isHLSStarted, isHLSRunning]);
|
22016
|
-
|
22050
|
+
useEffect58(() => {
|
22017
22051
|
if (!isConnected || streamStartedRef.current || !(permissions == null ? void 0 : permissions.hlsStreaming)) {
|
22018
22052
|
return;
|
22019
22053
|
}
|
@@ -22022,7 +22056,7 @@ var useAutoStartStreaming = () => {
|
|
22022
22056
|
};
|
22023
22057
|
|
22024
22058
|
// src/Prebuilt/App.tsx
|
22025
|
-
var HMSPrebuilt =
|
22059
|
+
var HMSPrebuilt = React156.forwardRef(
|
22026
22060
|
({
|
22027
22061
|
roomCode = "",
|
22028
22062
|
authToken = "",
|
@@ -22037,8 +22071,8 @@ var HMSPrebuilt = React155.forwardRef(
|
|
22037
22071
|
}, ref) => {
|
22038
22072
|
var _a7, _b7, _c, _d;
|
22039
22073
|
const reactiveStore = useRef25();
|
22040
|
-
const [hydrated, setHydrated] =
|
22041
|
-
|
22074
|
+
const [hydrated, setHydrated] = React156.useState(false);
|
22075
|
+
useEffect59(() => {
|
22042
22076
|
setHydrated(true);
|
22043
22077
|
const hms = new HMSReactiveStore();
|
22044
22078
|
const hmsStore = hms.getStore();
|
@@ -22053,13 +22087,13 @@ var HMSPrebuilt = React155.forwardRef(
|
|
22053
22087
|
hmsNotifications
|
22054
22088
|
};
|
22055
22089
|
}, []);
|
22056
|
-
|
22090
|
+
useEffect59(() => {
|
22057
22091
|
if (!ref || !reactiveStore.current) {
|
22058
22092
|
return;
|
22059
22093
|
}
|
22060
22094
|
ref.current = __spreadValues({}, reactiveStore.current);
|
22061
22095
|
}, [ref]);
|
22062
|
-
|
22096
|
+
useEffect59(
|
22063
22097
|
() => () => {
|
22064
22098
|
var _a8;
|
22065
22099
|
(_a8 = reactiveStore == null ? void 0 : reactiveStore.current) == null ? void 0 : _a8.hmsActions.leave();
|
@@ -22088,7 +22122,7 @@ var HMSPrebuilt = React155.forwardRef(
|
|
22088
22122
|
return null;
|
22089
22123
|
}
|
22090
22124
|
globalStyles();
|
22091
|
-
return /* @__PURE__ */
|
22125
|
+
return /* @__PURE__ */ React156.createElement(ErrorBoundary, null, /* @__PURE__ */ React156.createElement(
|
22092
22126
|
HMSPrebuiltContext.Provider,
|
22093
22127
|
{
|
22094
22128
|
value: {
|
@@ -22105,7 +22139,7 @@ var HMSPrebuilt = React155.forwardRef(
|
|
22105
22139
|
}
|
22106
22140
|
}
|
22107
22141
|
},
|
22108
|
-
/* @__PURE__ */
|
22142
|
+
/* @__PURE__ */ React156.createElement(
|
22109
22143
|
HMSRoomProvider,
|
22110
22144
|
{
|
22111
22145
|
isHMSStatsOn: FeatureFlags.enableStatsForNerds,
|
@@ -22114,7 +22148,7 @@ var HMSPrebuilt = React155.forwardRef(
|
|
22114
22148
|
notifications: (_c = reactiveStore.current) == null ? void 0 : _c.hmsNotifications,
|
22115
22149
|
stats: (_d = reactiveStore.current) == null ? void 0 : _d.hmsStats
|
22116
22150
|
},
|
22117
|
-
/* @__PURE__ */
|
22151
|
+
/* @__PURE__ */ React156.createElement(RoomLayoutProvider, { roomLayoutEndpoint, overrideLayout }, /* @__PURE__ */ React156.createElement(RoomLayoutContext.Consumer, null, (data3) => {
|
22118
22152
|
var _a8;
|
22119
22153
|
const layout = data3 == null ? void 0 : data3.layout;
|
22120
22154
|
const theme2 = ((_a8 = layout == null ? void 0 : layout.themes) == null ? void 0 : _a8[0]) || {};
|
@@ -22123,7 +22157,7 @@ var HMSPrebuilt = React155.forwardRef(
|
|
22123
22157
|
if (typography2 == null ? void 0 : typography2.font_family) {
|
22124
22158
|
fontFamily = [`${typography2 == null ? void 0 : typography2.font_family}`, ...fontFamily];
|
22125
22159
|
}
|
22126
|
-
return /* @__PURE__ */
|
22160
|
+
return /* @__PURE__ */ React156.createElement(
|
22127
22161
|
HMSThemeProvider,
|
22128
22162
|
{
|
22129
22163
|
themeType: `${theme2.name}-${Date.now()}`,
|
@@ -22136,9 +22170,9 @@ var HMSPrebuilt = React155.forwardRef(
|
|
22136
22170
|
}
|
22137
22171
|
}
|
22138
22172
|
},
|
22139
|
-
/* @__PURE__ */
|
22140
|
-
/* @__PURE__ */
|
22141
|
-
/* @__PURE__ */
|
22173
|
+
/* @__PURE__ */ React156.createElement(AppData, null),
|
22174
|
+
/* @__PURE__ */ React156.createElement(Init, null),
|
22175
|
+
/* @__PURE__ */ React156.createElement(DialogContainerProvider, { dialogContainerSelector: containerSelector }, /* @__PURE__ */ React156.createElement(
|
22142
22176
|
Box,
|
22143
22177
|
{
|
22144
22178
|
id: DEFAULT_PORTAL_CONTAINER.slice(1),
|
@@ -22150,7 +22184,7 @@ var HMSPrebuilt = React155.forwardRef(
|
|
22150
22184
|
position: "relative"
|
22151
22185
|
}
|
22152
22186
|
},
|
22153
|
-
/* @__PURE__ */
|
22187
|
+
/* @__PURE__ */ React156.createElement(
|
22154
22188
|
AppRoutes,
|
22155
22189
|
{
|
22156
22190
|
authTokenByRoomCodeEndpoint: tokenByRoomCodeEndpoint,
|
@@ -22170,16 +22204,16 @@ var AppStates = ({ activeState }) => {
|
|
22170
22204
|
const { isLeaveScreenEnabled } = useRoomLayoutLeaveScreen();
|
22171
22205
|
useAutoStartStreaming();
|
22172
22206
|
if (activeState === "preview" /* PREVIEW */ && isPreviewScreenEnabled) {
|
22173
|
-
return /* @__PURE__ */
|
22207
|
+
return /* @__PURE__ */ React156.createElement(PreviewScreen, null);
|
22174
22208
|
} else if (activeState === "leave" /* LEAVE */ && isLeaveScreenEnabled) {
|
22175
|
-
return /* @__PURE__ */
|
22209
|
+
return /* @__PURE__ */ React156.createElement(LeaveScreen, null);
|
22176
22210
|
}
|
22177
|
-
return /* @__PURE__ */
|
22211
|
+
return /* @__PURE__ */ React156.createElement(ConferenceScreen, null);
|
22178
22212
|
};
|
22179
22213
|
var BackSwipe = () => {
|
22180
|
-
const isConnectedToRoom =
|
22214
|
+
const isConnectedToRoom = useHMSStore75(selectIsConnectedToRoom13);
|
22181
22215
|
const hmsActions = useHMSActions48();
|
22182
|
-
|
22216
|
+
useEffect59(() => {
|
22183
22217
|
const onRouteLeave = () => __async(void 0, null, function* () {
|
22184
22218
|
if (isConnectedToRoom) {
|
22185
22219
|
yield hmsActions.leave();
|
@@ -22199,7 +22233,7 @@ function AppRoutes({
|
|
22199
22233
|
const roomLayout = useRoomLayout();
|
22200
22234
|
const isNotificationsDisabled = useIsNotificationDisabled();
|
22201
22235
|
const { activeState, rejoin } = useAppStateManager();
|
22202
|
-
return /* @__PURE__ */
|
22236
|
+
return /* @__PURE__ */ React156.createElement(AppStateContext.Provider, { value: { rejoin } }, /* @__PURE__ */ React156.createElement(React156.Fragment, null, /* @__PURE__ */ React156.createElement(ToastContainer, null), /* @__PURE__ */ React156.createElement(Notifications, null), /* @__PURE__ */ React156.createElement(MwebLandscapePrompt, null), /* @__PURE__ */ React156.createElement(BackSwipe, null), !isNotificationsDisabled && /* @__PURE__ */ React156.createElement(FlyingEmoji, null), /* @__PURE__ */ React156.createElement(RemoteStopScreenshare, null), /* @__PURE__ */ React156.createElement(KeyboardHandler, null), /* @__PURE__ */ React156.createElement(AuthToken_default, { authTokenByRoomCodeEndpoint, defaultAuthToken }), roomLayout && activeState && /* @__PURE__ */ React156.createElement(AppStates, { activeState })));
|
22203
22237
|
}
|
22204
22238
|
|
22205
22239
|
// src/Progress/index.tsx
|
@@ -22292,4 +22326,4 @@ export {
|
|
22292
22326
|
HMSPrebuilt,
|
22293
22327
|
Progress
|
22294
22328
|
};
|
22295
|
-
//# sourceMappingURL=chunk-
|
22329
|
+
//# sourceMappingURL=chunk-U4AB6X6M.js.map
|