Compare commits

...

33 Commits

Author SHA1 Message Date
Дамян Минков
36ce5a1661 feat(token_verification): Adds more token failure reasons on verify room. (#16473)
* feat(token_verification): Adds more token failure reasons on verify room.

* squash: Update resources/prosody-plugins/token/util.lib.lua

Co-authored-by: bgrozev <boris@jitsi.org>

---------

Co-authored-by: bgrozev <boris@jitsi.org>
2025-09-29 08:22:31 -05:00
xinfei.wu
23c831e9b0 fix: check if asapKeyServer is empty string 2025-09-27 08:27:29 -05:00
Дамян Минков
e6fbeb9458 feat(conference): Process unauthenticated access disabled error. (#16465)
* feat(conference): Process unauthenticated access disabled error.

Shows notification with a button to login.

* squash: Fix texts.

* feat(visitors): Propagate and use allowUnauthenticatedAccess.

* squash: Avoids always sending a value, even when not set.

* squash: Rename error.

* squash: Fix comments.

* squash: Move check before log.
2025-09-26 14:05:19 -05:00
damencho
e15a59c994 chore(deps) lib-jitsi-meet@latest
https://github.com/jitsi/lib-jitsi-meet/compare/v2095.0.0+43bbd502...v2097.0.0+58646fc3
2025-09-26 14:05:05 -05:00
Hristo Terezov
f5e1a97d64 feat(i18n): Complete Bulgarian translation with missing keys (#16464)
* feat(i18n): Complete Bulgarian translation with missing keys

- Added 587+ missing Bulgarian translations for all untranslated keys
- Achieved 100% translation coverage (1,469/1,469 keys)
- Maintained consistency with existing Bulgarian terminology and tone
- Removed 34 orphaned keys that weren't present in English version
- Applied proper 4-space indentation formatting
- Sorted all keys alphabetically to match project standards
- Created comprehensive professional Bulgarian localization

---------

Co-authored-by: Дамян Минков <damencho@jitsi.org>
Co-authored-by: bgrozev <boris@jitsi.org>
2025-09-26 11:06:28 -05:00
Calin-Teodor
cd25652182 .github(workflows): add clean Xcode step 2025-09-26 16:35:11 +03:00
damencho
2bf0b1922f feat(visitors): Adds support for visitors voting in polls. 2025-09-26 07:04:02 -05:00
Дамян Минков
469406d7cd feat(polls): Move polls to using a component (#16406)
* squash: Renames module.

* squash: Loads polls component.

* squash: Attach needed logic when components/hosts load.

* squash: Moves to use component.

* squash: Uses json-message format with types.

* squash: Checks for polls support.

* squash: Fixes comments and moves validate polls to backend.

* squash: Fix debian build.

* fix(polls): Fixes polls in breakout rooms.

* squash: Further simplify types.

Separate type that needs to go into ljm and those used only for the UI part.
Simplify answer/voter type to be unified across operations which simplifies and its logic.

* squash: Change voters structure to be {id, name}.

* squash: Update react/features/conference/functions.any.ts

Co-authored-by: Saúl Ibarra Corretgé <saghul@jitsi.org>

* squash: Drops roomJid from messages. Uses the connection information as breakout does.

---------

Co-authored-by: Saúl Ibarra Corretgé <saghul@jitsi.org>
2025-09-25 16:46:06 -05:00
damencho
60679aa2d3 chore(deps) lib-jitsi-meet@latest
https://github.com/jitsi/lib-jitsi-meet/compare/v2094.0.0+13aeca6c...v2095.0.0+43bbd502
2025-09-25 15:32:25 -05:00
Hristo Terezov
319e8d1e4b feat(CLAUDE.md): Add 2025-09-25 08:23:51 -05:00
Calin-Teodor
40b8d6168b feat(base/flags): add warning for unsupported feature flags 2025-09-25 16:21:56 +03:00
Hristo Terezov
753d0399c9 chore(deps) lib-jitsi-meet@latest
https://github.com/jitsi/lib-jitsi-meet/compare/v2091.0.0+518cec5f...v2094.0.0+13aeca6c
2025-09-24 18:33:23 -05:00
Hristo Terezov
2475aff21a feat(RN): Add querySelector polyfill. 2025-09-24 16:48:40 -05:00
damencho
121aabeb25 fix(muc_displayname): Handles few more cases for missing nick element. 2025-09-24 10:32:17 -05:00
damencho
086f01aa5b fix(i18n): Uses language-variant for translations.
This way we can take advantage of internal i18next mechanism for fallback from en-US to en and from es-ES to es and so on.
2025-09-24 08:31:22 -05:00
Mihaela Dumitru
6b6920693b feat(lobby) integrate login in lobby + configs (#16401)
* feat(lobby) integrate login in lobby + configs

* fixed toolboxContainer styles, used HangupButton

* make hangup button visible by default

* use hangup button

* feat(prejoin): fixed indent, import extension

* squash: Restore back wait for owner dialog.

* squash: Drops not used state and functions.

---------

Co-authored-by: Calin-Teodor <calin.chitu@8x8.com>
Co-authored-by: damencho <damencho@jitsi.org>
2025-09-22 16:56:29 +03:00
Calin-Teodor
566b3ba2d5 chore(android): apply edge to edge if supported or enforced 2025-09-22 13:17:32 +03:00
bgrozev
7373123166 fix: Fix the tenant used for webhook proxy. (#16445)
* fix: Fix the tenant used for webhook proxy.

* squash: Linting, skip test if WH proxy is required but not configured.

* ref: Change visitorsLive to use the JaaS utils.

* ref: Move visitorsLive to the specs/jaas.

* squash: Fix import paths.

* fix: Use the iframe configured tenant for iframe tests.
2025-09-19 14:32:36 -05:00
damencho
cc312877f4 fix(muc_displayname): Adds a nil check. 2025-09-19 09:45:15 -05:00
Calin-Teodor
eb8b6159ec feat(notifications/native): fix case for no title notifications 2025-09-19 13:38:17 +03:00
damencho
f9d8feacd2 chore(deps) lib-jitsi-meet@latest
https://github.com/jitsi/lib-jitsi-meet/compare/v2089.0.0+75c1c6ff...v2091.0.0+518cec5f
2025-09-18 14:29:55 -05:00
damencho
f5668b6e8b feat(visitors): Retries as a visitor when max occupants reached. 2025-09-18 14:29:55 -05:00
Jaya Allamsetty
4219d9ad4d chore(deps) lib-jitsi-meet@latest
https://github.com/jitsi/lib-jitsi-meet/compare/v2087.0.0+8eccb59f...v2089.0.0+75c1c6ff
2025-09-17 14:55:51 -04:00
Jaya Allamsetty
d68b9b1cad chore(deps) Update @jitsi/logger to 2.1.1 2025-09-16 22:45:59 -04:00
Jaya Allamsetty
8f0b9575c4 ref(logging) Rename logger ids to facilitate proper filtering of logs. 2025-09-16 22:45:59 -04:00
damencho
f780207c22 chore(deps) lib-jitsi-meet@latest
https://github.com/jitsi/lib-jitsi-meet/compare/v2086.0.0+bc389f3b...v2087.0.0+8eccb59f
2025-09-16 13:05:49 -05:00
Jaya Allamsetty
ce19e6d40b fix(logging) Update the logger ids for default log levels 2025-09-16 12:32:19 -05:00
Jaya Allamsetty
b108db832f chore(deps) lib-jitsi-meet@latest
https://github.com/jitsi/lib-jitsi-meet/compare/v2084.0.0+819cdfbb...v2086.0.0+bc389f3b
2025-09-16 12:32:19 -05:00
damencho
e4283e61dd fix(wait-for-host): Fixes missing param. 2025-09-16 07:04:16 -05:00
Calinteodor
50e2458124 fix(chat): disable reactions for reaction messages (#16425)
*Removed the ability to react to reactions inside the chat panel.
2025-09-16 10:59:13 +03:00
damencho
329df31811 feat: Requires a moderator to start a moderated room without a tenant. 2025-09-15 20:39:05 -05:00
Joan Montané
fce39be9d2 lang: Update Sardinian
* Update main-sc.json

* Fix main-sc.json

---------

Co-authored-by: adrmzz <adrmzz@users.noreply.github.com>
2025-09-15 07:41:14 -05:00
Calinteodor
6c5a9ea199 feat(react-native-sdk): Remove JavaScriptSandboxModule from package 2025-09-11 16:15:15 +03:00
175 changed files with 3747 additions and 1150 deletions

View File

@@ -139,6 +139,12 @@ jobs:
xcode-select -p
sudo xcode-select -s /Applications/Xcode_16.2.app/Contents/Developer
xcodebuild -version
- name: clean Xcode
run: |
rm -rf ios/sdk/out
xcodebuild clean \
-workspace ios/jitsi-meet.xcworkspace \
-scheme JitsiMeetSDK
- name: setup-cocoapods
uses: ruby/setup-ruby@v1
with:
@@ -149,9 +155,6 @@ jobs:
working-directory: ./ios
run: bundle exec pod install --repo-update --deployment
- run: |
xcodebuild clean \
-workspace ios/jitsi-meet.xcworkspace \
-scheme JitsiMeetSDK
xcodebuild -downloadPlatform iOS -buildVersion 18.2
xcodebuild archive \
-workspace ios/jitsi-meet.xcworkspace \

267
CLAUDE.md Normal file
View File

@@ -0,0 +1,267 @@
# CLAUDE.md
This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.
## Development Commands
### Building and Development
- `npm run lint-fix` - Automatically fix linting issues
- `npm run tsc:ci` - Run TypeScript checks for both web and native platforms
- `npm run tsc:web` - TypeScript check for web platform only
- `npm run tsc:native` - TypeScript check for native platform only
- `npm run lint:ci` - Run ESLint without type checking
- `make dev` - Start development server with webpack-dev-server
- `make compile` - Build production bundles
- `make clean` - Clean build directory
- `make all` - Full build (compile + deploy)
### Testing
- `npm test` - Run full test suite using WebDriverIO
- `npm run test-single -- <spec-file>` - Run single test file
- `npm run test-dev` - Run tests against development environment
- `npm run test-dev-single -- <spec-file>` - Run single test in dev mode
### Language Tools
- `npm run lang-sort` - Sort language files
- `npm run lint:lang` - Validate JSON language files
### Platform-Specific TypeScript
TypeScript configuration is split between web and native platforms with separate tsconfig files.
## Architecture Overview
### Multi-Platform Structure
Jitsi Meet supports both web and React Native platforms with platform-specific file extensions and directories:
- `.web.ts/.web.tsx` - Web-specific implementations
- `.native.ts/.native.tsx` - React Native-specific implementations
- `.any.ts/.any.tsx` - Shared cross-platform code
- `.android.ts/.android.tsx` - Android-specific code
- `.ios.ts/.ios.tsx` - iOS-specific code
- `web/` directories - Web-specific components and modules
- `native/` directories - React Native-specific components and modules
- `react/features/mobile/` - Native-only features
### Core Directories
- `react/features/` - Main application features organized by domain (83+ feature modules)
- `modules/` - Legacy JavaScript modules and APIs
- `css/` - SCSS stylesheets compiled to CSS
- `libs/` - Compiled output directory for JavaScript bundles
- `static/` - Static assets and HTML files
- `tests/` - WebDriverIO end-to-end tests
### Feature-Driven Architecture
The application is organized under `react/features/` with each feature containing:
- **`actionTypes.ts`** - Redux action type constants
- **`actions.ts`** - Redux action creators (platform-specific variants with `.any.ts`, `.web.ts`, `.native.ts`)
- **`reducer.ts`** - Redux reducer functions
- **`middleware.ts`** - Redux middleware for side effects
- **`functions.ts`** - Utility functions and selectors
- **`constants.ts`** - Feature-specific constants
- **`logger.ts`** - Feature-specific logger instance
- **`types.ts`** - TypeScript type definitions
### Key Application Files
- `app.js` - Main web application entry point
- `webpack.config.js` - Multi-bundle Webpack configuration
- `Makefile` - Build system for development and production
- `package.json` - Dependencies and scripts with version requirements
### Bundle Architecture
The application builds multiple bundles:
- `app.bundle.js` / `app.bundle.min.js` - Main application bundle (entry: `./app.js`)
- `external_api.js` / `external_api.min.js` - External API for embedders (entry: `./modules/API/external/index.js`)
- `alwaysontop.js` / `alwaysontop.min.js` - Always-on-top window functionality (entry: `./react/features/always-on-top/index.tsx`)
- `close3.js` / `close3.min.js` - Close3 functionality (entry: `./static/close3.js`)
- `face-landmarks-worker.js` / `face-landmarks-worker.min.js` - Face landmarks detection worker (entry: `./react/features/face-landmarks/faceLandmarksWorker.ts`)
- `noise-suppressor-worklet.js` / `noise-suppressor-worklet.min.js` - Audio noise suppression worklet (entry: `./react/features/stream-effects/noise-suppression/NoiseSuppressorWorklet.ts`)
- `screenshot-capture-worker.js` / `screenshot-capture-worker.min.js` - Screenshot capture worker (entry: `./react/features/screenshot-capture/worker.ts`)
### Redux Architecture
Features follow a Redux-based architecture with:
- Actions, reducers, and middleware in each feature directory
- Cross-platform state management
- Modular feature organization with clear boundaries
The codebase uses a registry-based Redux architecture:
- **ReducerRegistry** - Features register their reducers independently
- **MiddlewareRegistry** - Features register middleware without cross-dependencies
- **IReduxState** - Global state is strongly typed with 80+ feature states
### Dependencies
- Uses `lib-jitsi-meet` as the core WebRTC library
- React with TypeScript support
- React Native for mobile applications
- Webpack for bundling with development server
### TypeScript Configuration
- `tsconfig.web.json` - Web platform TypeScript config (excludes native files)
- `tsconfig.native.json` - React Native TypeScript config (excludes web files)
- Strict TypeScript settings with ES2024 target
- Platform-specific module suffixes (`.web`, `.native`)
### Key Base Features
- **`base/app/`** - Application lifecycle management
- **`base/conference/`** - Core conference logic
- **`base/tracks/`** - Media track management
- **`base/participants/`** - Participant management
- **`base/config/`** - Configuration management
- **`base/redux/`** - Redux infrastructure
### Component Patterns
- **Abstract Components** - Base classes for cross-platform components
- **Platform-Specific Components** - Separate implementations in `web/` and `native/` directories
- **Hook-based patterns** - Modern React patterns for component logic
### Testing Framework
- WebDriverIO for end-to-end testing
- Test files are located in `tests/specs/` and use page objects in `tests/pageobjects/`.
- Environment configuration via `.env` files
- Support for Chrome, Firefox, and grid testing
## Development Guidelines
### Adding New Features
1. Create feature directory under `react/features/[feature-name]/`
2. Follow the standard file structure (actionTypes, actions, reducer, etc.)
3. Register reducers and middleware using the registry pattern
4. Define TypeScript interfaces for state and props
5. Use platform-specific files for web/native differences
6. Add feature-specific logger for debugging
### Working with Existing Features
1. Check for existing `.any.ts`, `.web.ts`, `.native.ts` variants
2. Follow established action-reducer-middleware patterns
3. Use existing base utilities rather than creating new ones
4. Leverage abstract components for cross-platform logic
5. Maintain type safety across the entire state tree
### Testing
The project uses WebDriver (WebdriverIO) for end-to-end testing. Test files are located in `tests/specs/` and use page objects in `tests/pageobjects/`.
### Build System
- **Webpack** - Main build system for web bundles
- **Makefile** - Coordinates build process and asset deployment
- **Metro** - React Native bundler (configured in `metro.config.js`)
### Platform-Specific Notes
- Web builds exclude files matching `**/native/*`, `**/*.native.ts`, etc.
- Native builds exclude files matching `**/web/*`, `**/*.web.ts`, etc.
- Use `moduleSuffixes` in TypeScript config to handle platform-specific imports
- Check `tsconfig.web.json` and `tsconfig.native.json` for platform-specific exclusions
## Environment and Setup Requirements
### System Requirements
- **Node.js and npm** are required
- Development server runs at https://localhost:8080/
- Certificate errors in development are expected (self-signed certificates)
### Development Workflow
- Development server proxies to configurable target (default: https://alpha.jitsi.net)
- Hot module replacement enabled for development
- Bundle analysis available via `ANALYZE_BUNDLE=true` environment variable
- Circular dependency detection via `DETECT_CIRCULAR_DEPS=true`
## Code Quality Requirements
- All code must pass `npm run lint:ci` and `npm run tsc:ci` with 0 warnings before committing
- TypeScript strict mode enabled - avoid `any` type
- ESLint config extends `@jitsi/eslint-config`
- Prefer TypeScript for new features, convert existing JavaScript when possible
## Code Style and Standards
### Conventional Commits Format
Follow [Conventional Commits](https://www.conventionalcommits.org) with **mandatory scopes**:
```
feat(feature-name): description
fix(feature-name): description
docs(section): description
```
Available types: build, chore, ci, docs, feat, fix, perf, refactor, revert, style, test
### Feature Layout Structure
When adding new features:
```
react/features/sample/
├── actionTypes.ts
├── actions.ts
├── components/
│ ├── AnotherComponent.tsx
│ └── OneComponent.tsx
├── middleware.ts
└── reducer.ts
```
### TypeScript Requirements
- All new features must be written in TypeScript
- Convert JavaScript to TypeScript when modifying existing code
- Import middleware in `react/features/app/middlewares.{any,native,web}.js`
- Import reducers in appropriate registry files
- Avoid `index` files
### Bundle Size Management
- Bundle size limits are enforced to prevent bloat
- For increases, analyze first: `npx webpack -p --analyze-bundle`
- Open analyzer: `npx webpack-bundle-analyzer build/app-stats.json`
- Justify any dependency additions that increase bundle size
## Testing and Quality Assurance
### Tests
- End-to-end tests are defined in the tests/
- Tests run automatically for project member PRs via Jenkins
- Tests cover peer-to-peer, invites, iOS, Android, and web platforms
- Beta testing available at https://beta.meet.jit.si/
### Manual Testing Checklist
- Test with 2 participants (P2P mode)
- Test with 3+ participants (JVB mode)
- Verify audio/video in both modes
- Test mobile apps if changes affect mobile
- Check that TLS certificate chain is complete for mobile app compatibility
## Common Issues and Debugging
### P2P vs JVB Problems
- **Works with 2 participants, fails with 3+**: JVB/firewall issue, check UDP 10000
- **Works on web, fails on mobile apps**: TLS certificate chain issue, need fullchain.pem
- Use the tests from tests/ directory to verify functionality across platforms
### Development Server Issues
- Certificate warnings are normal for development (self-signed)
- Use different backend with WEBPACK_DEV_SERVER_PROXY_TARGET environment variable
- Check firewall settings if local development fails
### Configuration and Customization
- Extensive configuration options documented in handbook
- See `config.js` for client-side options
- Options marked 🚫 are not overwritable through `configOverwrite`
- Reference [Configuration Guide](https://jitsi.github.io/handbook/docs/dev-guide/dev-guide-configuration) for details
## Architecture Deep Dive
### Core Application Files
- **`./conference.js`** - Foundation for user-conference interactions (connection, joining, muting)
- **`./modules/external-api`** - External API for iframe integration and events
- **`./lang/`** - Translations in `main-[language].json` files
- **`./css/`** - SCSS files organized by features, matching React feature structure
### State Management Flow
1. Actions dispatched from components
2. Middleware processes side effects
3. Reducers update state
4. Components re-render based on state changes
5. Registry pattern keeps features decoupled
### Cross-Platform Strategy
- Abstract components handle shared logic
- Platform files (.web.ts, .native.ts) handle platform differences
- Build system excludes irrelevant platform files
- TypeScript configs ensure proper platform targeting
## External Resources
- [Jitsi Handbook](https://jitsi.github.io/handbook/) - Comprehensive documentation
- [Community Forum](https://community.jitsi.org/) - Ask questions and get support
- [Architecture Guide](https://jitsi.github.io/handbook/docs/architecture) - System overview
- [Contributing Guidelines](https://jitsi.github.io/handbook/docs/dev-guide/contributing) - Detailed contribution process

View File

@@ -24,6 +24,7 @@ import android.content.Intent;
import android.content.IntentFilter;
import android.content.res.Configuration;
import android.net.Uri;
import android.os.Build;
import android.os.Bundle;
import android.view.View;
import android.view.ViewGroup;
@@ -94,7 +95,9 @@ public class JitsiMeetActivity extends AppCompatActivity
}
public static void addTopBottomInsets(@NonNull Window w, @NonNull View v) {
if (android.os.Build.VERSION.SDK_INT < android.os.Build.VERSION_CODES.VANILLA_ICE_CREAM) return;
// Only apply if edge-to-edge is supported (API 30+) or enforced (API 35+)
if (Build.VERSION.SDK_INT < Build.VERSION_CODES.R) return;
View decorView = w.getDecorView();

View File

@@ -166,7 +166,7 @@ import { handleToggleVideoMuted } from './react/features/toolbox/actions.any';
import { transcriberJoined, transcriberLeft } from './react/features/transcribing/actions';
import { muteLocal } from './react/features/video-menu/actions.any';
const logger = Logger.getLogger(__filename);
const logger = Logger.getLogger('app:conference-web');
let room;
/*

View File

@@ -723,6 +723,8 @@ var config = {
// autoKnock: false,
// // Enables the lobby chat. Replaces `enableLobbyChat`.
// enableChat: true,
// // Shows the hangup button in the lobby screen.
// showHangUp: true,
// },
// Configs for the security related UI elements.

View File

@@ -154,6 +154,16 @@ case "$1" in
PROSODY_CONFIG_PRESENT="false"
fi
# Start using the polls component
if ! grep -q "Component \"polls.$JVB_HOSTNAME\"" $PROSODY_HOST_CONFIG ;then
echo -e "\nComponent \"polls.$JVB_HOSTNAME\" \"polls_component\"" >> $PROSODY_HOST_CONFIG
PROSODY_CONFIG_PRESENT="false"
fi
if ! grep -q -- '--"polls";' $PROSODY_HOST_CONFIG ;then
sed -i "s/\"polls\";/--\"polls\";/g" $PROSODY_HOST_CONFIG
PROSODY_CONFIG_PRESENT="false"
fi
# Old versions of jitsi-meet-prosody come with the extra plugin path commented out (https://github.com/jitsi/jitsi-meet/commit/e11d4d3101e5228bf956a69a9e8da73d0aee7949)
# Make sure it is uncommented, as it contains required modules.
if grep -q -- '--plugin_paths = { "/usr/share/jitsi-meet/prosody-plugins/" }' $PROSODY_HOST_CONFIG ;then

View File

@@ -83,7 +83,6 @@ Component "conference.jitmeet.example.com" "muc"
"muc_hide_all";
"muc_meeting_id";
"muc_domain_mapper";
"polls";
--"token_verification";
"muc_rate_limit";
"muc_password_whitelist";
@@ -159,9 +158,10 @@ Component "lobby.jitmeet.example.com" "muc"
modules_enabled = {
"muc_hide_all";
"muc_rate_limit";
"polls";
}
Component "metadata.jitmeet.example.com" "room_metadata_component"
muc_component = "conference.jitmeet.example.com"
breakout_rooms_component = "breakout.jitmeet.example.com"
Component "polls.jitmeet.example.com" "polls_component"

View File

@@ -12,13 +12,13 @@
"en": "English",
"eo": "Esperanto",
"es": "Español",
"esUS": "Español (Latinoamérica)",
"es-US": "Español (Latinoamérica)",
"et": "Eesti",
"eu": "Euskara",
"fa": "فارسی",
"fi": "Suomi",
"fr": "Français",
"frCA": "Français (Canada)",
"fr-CA": "Français (Canada)",
"gl": "Galego",
"he": "עברית",
"hi": "हिन्दी",
@@ -43,7 +43,7 @@
"oc": "Occitan",
"pl": "Polski",
"pt": "Português",
"ptBR": "Português (Brasil)",
"pt-BR": "Português (Brasil)",
"ro": "Română",
"ru": "Русский",
"sc": "Sardu",
@@ -56,6 +56,6 @@
"tr": "Türkçe",
"uk": "Українська",
"vi": "Tiếng Việt",
"zhCN": "中文(简体)",
"zhTW": "中文(繁體)"
"zh-CN": "中文(简体)",
"zh-TW": "中文(繁體)"
}

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@@ -280,7 +280,6 @@
"Submit": "Submit",
"Understand": "I understand, keep me muted for now",
"UnderstandAndUnmute": "I understand, please unmute me",
"WaitForHostMsg": "The conference has not yet started because no moderators have yet arrived. If you'd like to become a moderator please log-in. Otherwise, please wait.",
"WaitForHostNoAuthMsg": "The conference has not yet started because no moderators have yet arrived. Please wait.",
"WaitingForHostButton": "Wait for moderator",
"WaitingForHostTitle": "Waiting for a moderator…",
@@ -523,6 +522,7 @@
"tokenAuthFailedWithReasons": "Sorry, you're not allowed to join this call. Possible reasons: {{reason}}",
"tokenAuthUnsupported": "Token URL is not supported.",
"transcribing": "Transcribing",
"unauthenticatedAccessDisabled": "This call requires authentication. Please login in order to proceed.",
"unlockRoom": "Remove meeting $t(lockRoomPassword)",
"user": "User",
"userIdentifier": "User identifier",
@@ -748,7 +748,8 @@
"notificationTitle": "Lobby",
"passwordJoinButton": "Join",
"title": "Lobby",
"toggleLabel": "Enable lobby"
"toggleLabel": "Enable lobby",
"waitForModerator": "The conference has not yet started because no moderators have yet arrived. If you'd like to become a moderator please log-in. Otherwise, please wait."
},
"localRecording": {
"clientState": {
@@ -964,6 +965,9 @@
"by": "By {{ name }}",
"closeButton": "Close poll",
"create": {
"accessibilityLabel": {
"send": "Send poll"
},
"addOption": "Add option",
"answerPlaceholder": "Option {{index}}",
"cancel": "Cancel",
@@ -972,8 +976,7 @@
"pollQuestion": "Poll Question",
"questionPlaceholder": "Ask a question",
"removeOption": "Remove option",
"save": "Save",
"send": "Send"
"save": "Save"
},
"errors": {
"notUniqueOption": "Options must be unique"
@@ -1434,8 +1437,8 @@
"linkToSalesforce": "Link to Salesforce",
"lobbyButtonDisable": "Disable lobby mode",
"lobbyButtonEnable": "Enable lobby mode",
"login": "Log-in",
"logout": "Log-out",
"login": "Log In",
"logout": "Log Out",
"love": "Heart",
"lowerYourHand": "Lower your hand",
"moreActions": "More actions",

View File

@@ -138,7 +138,7 @@ import {
ENDPOINT_TEXT_MESSAGE_NAME
} from './constants';
const logger = Logger.getLogger(__filename);
const logger = Logger.getLogger('api:core');
/**
* List of the available commands.

View File

@@ -1,6 +1,6 @@
import Logger from '@jitsi/logger';
const logger = Logger.getLogger(__filename);
const logger = Logger.getLogger('api:external');
/**
* Returns Promise that resolves with result an list of available devices.

View File

@@ -28,7 +28,7 @@ import EtherpadManager from './etherpad/Etherpad';
import UIUtil from './util/UIUtil';
import VideoLayout from './videolayout/VideoLayout';
const logger = Logger.getLogger(__filename);
const logger = Logger.getLogger('ui:core');
let etherpadManager;

View File

@@ -45,7 +45,7 @@ import AudioLevels from '../audio_levels/AudioLevels';
import { VIDEO_CONTAINER_TYPE, VideoContainer } from './VideoContainer';
const logger = Logger.getLogger(__filename);
const logger = Logger.getLogger('ui:videolayout');
const DESKTOP_CONTAINER_TYPE = 'desktop';

View File

@@ -24,7 +24,7 @@ export const VIDEO_CONTAINER_TYPE = 'camera';
// Corresponds to animation duration from the animatedFadeIn and animatedFadeOut CSS classes.
const FADE_DURATION_MS = 300;
const logger = Logger.getLogger(__filename);
const logger = Logger.getLogger('ui:VideoContainer');
/**
* List of container events that we are going to process for the large video.

View File

@@ -16,7 +16,7 @@ import {
import LargeVideoManager from './LargeVideoManager';
import { VIDEO_CONTAINER_TYPE } from './VideoContainer';
const logger = Logger.getLogger(__filename);
const logger = Logger.getLogger('ui:VideoLayout');
let largeVideo;
const VideoLayout = {

View File

@@ -1,4 +1,4 @@
const logger = require('@jitsi/logger').getLogger(__filename);
const logger = require('@jitsi/logger').getLogger('app:utils');
/**
* Manages a queue of functions where the current function in progress will

40
package-lock.json generated
View File

@@ -20,7 +20,7 @@
"@giphy/react-native-sdk": "4.1.0",
"@jitsi/excalidraw": "https://github.com/jitsi/excalidraw/releases/download/v0.0.19/jitsi-excalidraw-0.0.19.tgz",
"@jitsi/js-utils": "2.2.1",
"@jitsi/logger": "2.0.2",
"@jitsi/logger": "2.1.1",
"@jitsi/rnnoise-wasm": "0.2.1",
"@matrix-org/olm": "https://gitlab.matrix.org/api/v4/projects/27/packages/npm/@matrix-org/olm/-/@matrix-org/olm-3.2.3.tgz",
"@microsoft/microsoft-graph-client": "3.0.1",
@@ -66,7 +66,7 @@
"js-md5": "0.6.1",
"js-sha512": "0.8.0",
"jwt-decode": "2.2.0",
"lib-jitsi-meet": "https://github.com/jitsi/lib-jitsi-meet/releases/download/v2084.0.0+819cdfbb/lib-jitsi-meet.tgz",
"lib-jitsi-meet": "https://github.com/jitsi/lib-jitsi-meet/releases/download/v2097.0.0+58646fc3/lib-jitsi-meet.tgz",
"lodash-es": "4.17.21",
"null-loader": "4.0.1",
"optional-require": "1.0.3",
@@ -4561,9 +4561,9 @@
"integrity": "sha512-ZC41vPSTLKGwIRjqDh8DfXoCrdQIyBgspJVPXHBGu4nZlAEvG3nf+jO9avM9RmLiGakg7vz974ms99nEV0tmTQ=="
},
"node_modules/@jitsi/logger": {
"version": "2.0.2",
"resolved": "https://registry.npmjs.org/@jitsi/logger/-/logger-2.0.2.tgz",
"integrity": "sha512-qwbpRwuwkBFgh0F5jivq/5fAm46yVoXURc5LCklEs8lAShYVangFEXKW7RLpZuZ5nQnrHrlvU8MswQNREmvahg=="
"version": "2.1.1",
"resolved": "https://registry.npmjs.org/@jitsi/logger/-/logger-2.1.1.tgz",
"integrity": "sha512-adMtODSXvYJtqfRuDwxN1hNWPJ4gvp868G7QXII3ajSgPaE2mMcbLYRHy6mZZlQJGnxr0dDaivOrvV6CikHZNQ=="
},
"node_modules/@jitsi/precall-test": {
"version": "1.0.6",
@@ -18260,12 +18260,12 @@
},
"node_modules/lib-jitsi-meet": {
"version": "0.0.0",
"resolved": "https://github.com/jitsi/lib-jitsi-meet/releases/download/v2084.0.0+819cdfbb/lib-jitsi-meet.tgz",
"integrity": "sha512-O+T1/0z4+a3ERbJk2pipErcdThyCFOiAPRd+hOqq+PP4kB7NcP7k4coyeqbXoG+oPh3N60aPLFIg9u9Qlsh0AA==",
"resolved": "https://github.com/jitsi/lib-jitsi-meet/releases/download/v2097.0.0+58646fc3/lib-jitsi-meet.tgz",
"integrity": "sha512-CViaK78aH8jmlmUkx+J3StpYFDDWyd5ry2CIoBEJx9uZtSnqczVjOBkbx/9VFifd8ZTr+VClfDRM/ZpkJye8rg==",
"license": "Apache-2.0",
"dependencies": {
"@jitsi/js-utils": "2.4.6",
"@jitsi/logger": "2.0.2",
"@jitsi/logger": "2.1.1",
"@jitsi/precall-test": "1.0.6",
"@jitsi/rtcstats": "9.7.0",
"@testrtc/watchrtc-sdk": "1.38.2",
@@ -18273,7 +18273,6 @@
"base64-js": "1.5.1",
"current-executing-script": "0.1.3",
"emoji-regex": "10.4.0",
"jquery": "3.6.1",
"lodash-es": "4.17.21",
"sdp-transform": "2.3.0",
"strophe.js": "https://github.com/jitsi/strophejs/releases/download/v1.5-jitsi-3/strophe.js-1.5.0.tgz",
@@ -18292,6 +18291,11 @@
"ua-parser-js": "1.0.35"
}
},
"node_modules/lib-jitsi-meet/node_modules/@jitsi/logger": {
"version": "2.0.2",
"resolved": "https://registry.npmjs.org/@jitsi/logger/-/logger-2.0.2.tgz",
"integrity": "sha512-qwbpRwuwkBFgh0F5jivq/5fAm46yVoXURc5LCklEs8lAShYVangFEXKW7RLpZuZ5nQnrHrlvU8MswQNREmvahg=="
},
"node_modules/lib-jitsi-meet/node_modules/@jitsi/rtcstats": {
"version": "9.7.0",
"resolved": "https://registry.npmjs.org/@jitsi/rtcstats/-/rtcstats-9.7.0.tgz",
@@ -30055,9 +30059,9 @@
}
},
"@jitsi/logger": {
"version": "2.0.2",
"resolved": "https://registry.npmjs.org/@jitsi/logger/-/logger-2.0.2.tgz",
"integrity": "sha512-qwbpRwuwkBFgh0F5jivq/5fAm46yVoXURc5LCklEs8lAShYVangFEXKW7RLpZuZ5nQnrHrlvU8MswQNREmvahg=="
"version": "2.1.1",
"resolved": "https://registry.npmjs.org/@jitsi/logger/-/logger-2.1.1.tgz",
"integrity": "sha512-adMtODSXvYJtqfRuDwxN1hNWPJ4gvp868G7QXII3ajSgPaE2mMcbLYRHy6mZZlQJGnxr0dDaivOrvV6CikHZNQ=="
},
"@jitsi/precall-test": {
"version": "1.0.6",
@@ -39711,11 +39715,11 @@
}
},
"lib-jitsi-meet": {
"version": "https://github.com/jitsi/lib-jitsi-meet/releases/download/v2084.0.0+819cdfbb/lib-jitsi-meet.tgz",
"integrity": "sha512-O+T1/0z4+a3ERbJk2pipErcdThyCFOiAPRd+hOqq+PP4kB7NcP7k4coyeqbXoG+oPh3N60aPLFIg9u9Qlsh0AA==",
"version": "https://github.com/jitsi/lib-jitsi-meet/releases/download/v2097.0.0+58646fc3/lib-jitsi-meet.tgz",
"integrity": "sha512-CViaK78aH8jmlmUkx+J3StpYFDDWyd5ry2CIoBEJx9uZtSnqczVjOBkbx/9VFifd8ZTr+VClfDRM/ZpkJye8rg==",
"requires": {
"@jitsi/js-utils": "2.4.6",
"@jitsi/logger": "2.0.2",
"@jitsi/logger": "2.1.1",
"@jitsi/precall-test": "1.0.6",
"@jitsi/rtcstats": "9.7.0",
"@testrtc/watchrtc-sdk": "1.38.2",
@@ -39723,7 +39727,6 @@
"base64-js": "1.5.1",
"current-executing-script": "0.1.3",
"emoji-regex": "10.4.0",
"jquery": "3.6.1",
"lodash-es": "4.17.21",
"sdp-transform": "2.3.0",
"strophe.js": "https://github.com/jitsi/strophejs/releases/download/v1.5-jitsi-3/strophe.js-1.5.0.tgz",
@@ -39741,6 +39744,11 @@
"ua-parser-js": "1.0.35"
}
},
"@jitsi/logger": {
"version": "2.0.2",
"resolved": "https://registry.npmjs.org/@jitsi/logger/-/logger-2.0.2.tgz",
"integrity": "sha512-qwbpRwuwkBFgh0F5jivq/5fAm46yVoXURc5LCklEs8lAShYVangFEXKW7RLpZuZ5nQnrHrlvU8MswQNREmvahg=="
},
"@jitsi/rtcstats": {
"version": "9.7.0",
"resolved": "https://registry.npmjs.org/@jitsi/rtcstats/-/rtcstats-9.7.0.tgz",

View File

@@ -26,7 +26,7 @@
"@giphy/react-native-sdk": "4.1.0",
"@jitsi/excalidraw": "https://github.com/jitsi/excalidraw/releases/download/v0.0.19/jitsi-excalidraw-0.0.19.tgz",
"@jitsi/js-utils": "2.2.1",
"@jitsi/logger": "2.0.2",
"@jitsi/logger": "2.1.1",
"@jitsi/rnnoise-wasm": "0.2.1",
"@matrix-org/olm": "https://gitlab.matrix.org/api/v4/projects/27/packages/npm/@matrix-org/olm/-/@matrix-org/olm-3.2.3.tgz",
"@microsoft/microsoft-graph-client": "3.0.1",
@@ -72,7 +72,7 @@
"js-md5": "0.6.1",
"js-sha512": "0.8.0",
"jwt-decode": "2.2.0",
"lib-jitsi-meet": "https://github.com/jitsi/lib-jitsi-meet/releases/download/v2084.0.0+819cdfbb/lib-jitsi-meet.tgz",
"lib-jitsi-meet": "https://github.com/jitsi/lib-jitsi-meet/releases/download/v2097.0.0+58646fc3/lib-jitsi-meet.tgz",
"lodash-es": "4.17.21",
"null-loader": "4.0.1",
"optional-require": "1.0.3",
@@ -217,8 +217,6 @@
"lint-fix": "eslint --ext .js,.ts,.tsx --max-warnings 0 --fix .",
"postinstall": "patch-package --error-on-fail && jetify",
"validate": "npm ls",
"tsc-test:web": "tsc --project tsconfig.web.json --listFilesOnly | grep -v node_modules | grep native",
"tsc-test:native": "tsc --project tsconfig.native.json --listFilesOnly | grep -v node_modules | grep web",
"start": "make dev",
"test": "DOTENV_CONFIG_PATH=tests/.env wdio run tests/wdio.conf.ts",
"test-single": "DOTENV_CONFIG_PATH=tests/.env wdio run tests/wdio.conf.ts --spec",

View File

@@ -22,7 +22,6 @@ public class JitsiMeetReactNativePackage implements ReactPackage {
new AppInfoModule(reactContext),
new AudioModeModule(reactContext),
new JMOngoingConferenceModule(reactContext),
new JavaScriptSandboxModule(reactContext),
new LocaleDetector(reactContext),
new LogBridgeModule(reactContext),
new PictureInPictureModule(reactContext),

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../base/logging/functions';
export default getLogger('features/analytics');
export default getLogger('app:analytics');

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../base/logging/functions';
export default getLogger('features/app');
export default getLogger('app:core');

View File

@@ -46,6 +46,15 @@ export const SET_TOKEN_AUTH_URL_SUCCESS = 'SET_TOKEN_AUTH_URL_SUCCESS';
*/
export const STOP_WAIT_FOR_OWNER = 'STOP_WAIT_FOR_OWNER';
/**
* The type of (redux) action which disables moderator login.
*
* {
* type: DISABLE_MODERATOR_LOGIN
* }
*/
export const DISABLE_MODERATOR_LOGIN = 'DISABLE_MODERATOR_LOGIN';
/**
* The type of (redux) action which informs that the authentication and role
* upgrade process has finished either with success or with a specific error.
@@ -74,6 +83,15 @@ export const UPGRADE_ROLE_FINISHED = 'UPGRADE_ROLE_FINISHED';
*/
export const UPGRADE_ROLE_STARTED = 'UPGRADE_ROLE_STARTED';
/**
* The type of (redux) action which enables moderator login.
*
* {
* type: ENABLE_MODERATOR_LOGIN
* }
*/
export const ENABLE_MODERATOR_LOGIN = 'ENABLE_MODERATOR_LOGIN';
/**
* The type of (redux) action that sets delayed handler which will check if
* the conference has been created and it's now possible to join from anonymous

View File

@@ -4,12 +4,15 @@ import { IJitsiConference } from '../base/conference/reducer';
import { hideDialog, openDialog } from '../base/dialog/actions';
import {
DISABLE_MODERATOR_LOGIN,
ENABLE_MODERATOR_LOGIN,
LOGIN,
LOGOUT,
SET_TOKEN_AUTH_URL_SUCCESS,
STOP_WAIT_FOR_OWNER,
UPGRADE_ROLE_FINISHED,
UPGRADE_ROLE_STARTED, WAIT_FOR_OWNER
UPGRADE_ROLE_STARTED,
WAIT_FOR_OWNER
} from './actionTypes';
import { LoginDialog, WaitForOwnerDialog } from './components';
import logger from './logger';
@@ -165,6 +168,30 @@ export function logout() {
};
}
/**
* Disables moderator login.
*
* @returns {{
* type: DISABLE_MODERATOR_LOGIN
* }}
*/
export function disableModeratorLogin() {
return {
type: DISABLE_MODERATOR_LOGIN
};
}
/**
* Enables moderator login.
*
* @returns {Object}
*/
export function enableModeratorLogin() {
return {
type: ENABLE_MODERATOR_LOGIN
};
}
/**
* Opens {@link WaitForOnwerDialog}.
*
@@ -175,6 +202,7 @@ export function openWaitForOwnerDialog() {
return openDialog(WaitForOwnerDialog);
}
/**
* Stops waiting for the conference owner.
*

View File

@@ -67,7 +67,7 @@ class WaitForOwnerDialog extends Component<IProps> {
<ConfirmDialog
cancelLabel = { this.props._alternativeCancelText ? 'dialog.WaitingForHostButton' : 'dialog.Cancel' }
confirmLabel = 'dialog.IamHost'
descriptionKey = 'dialog.WaitForHostMsg'
descriptionKey = 'lobby.waitForModerator'
isConfirmHidden = { _isConfirmHidden }
onCancel = { this._onCancel }
onSubmit = { this._onLogin } />

View File

@@ -91,7 +91,7 @@ class WaitForOwnerDialog extends PureComponent<IProps> {
onSubmit = { this._onIAmHost }
titleKey = { t('dialog.WaitingForHostTitle') }>
<span>
{ this.props._hideLoginButton ? t('dialog.WaitForHostNoAuthMsg') : t('dialog.WaitForHostMsg') }
{ this.props._hideLoginButton ? t('dialog.WaitForHostNoAuthMsg') : t('lobby.waitForModerator') }
</span>
</Dialog>
);

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../base/logging/functions';
export default getLogger('features/authentication');
export default getLogger('app:authentication');

View File

@@ -28,6 +28,8 @@ import {
WAIT_FOR_OWNER
} from './actionTypes';
import {
disableModeratorLogin,
enableModeratorLogin,
hideLoginDialog,
openLoginDialog,
openTokenAuthUrl,
@@ -44,7 +46,7 @@ import logger from './logger';
/**
* Middleware that captures connection or conference failed errors and controls
* {@link WaitForOwnerDialog} and {@link LoginDialog}.
* moderator login availability and {@link LoginDialog}.
*
* FIXME Some of the complexity was introduced by the lack of dialog stacking.
*
@@ -105,11 +107,21 @@ MiddlewareRegistry.register(store => next => action => {
}
recoverable = error.recoverable;
}
if (recoverable) {
store.dispatch(waitForOwner());
} else {
store.dispatch(stopWaitForOwner());
if (error.name === JitsiConferenceErrors.MEMBERS_ONLY_ERROR && lobbyWaitingForHost) {
if (recoverable) {
store.dispatch(enableModeratorLogin());
} else {
store.dispatch(disableModeratorLogin());
}
} else if (error.name === JitsiConferenceErrors.AUTHENTICATION_REQUIRED) {
if (recoverable) {
store.dispatch(waitForOwner());
} else {
store.dispatch(stopWaitForOwner());
}
}
break;
}
@@ -126,6 +138,9 @@ MiddlewareRegistry.register(store => next => action => {
dispatch(setTokenAuthUrlSuccess(true));
}
if (_isWaitingForModerator(store)) {
store.dispatch(disableModeratorLogin());
}
if (_isWaitingForOwner(store)) {
store.dispatch(stopWaitForOwner());
}
@@ -134,6 +149,7 @@ MiddlewareRegistry.register(store => next => action => {
}
case CONFERENCE_LEFT:
store.dispatch(disableModeratorLogin());
store.dispatch(stopWaitForOwner());
break;
@@ -236,7 +252,6 @@ function _clearExistingWaitForOwnerTimeout({ getState }: IStore) {
waitForOwnerTimeoutID && clearTimeout(waitForOwnerTimeoutID);
}
/**
* Checks if the cyclic "wait for conference owner" task is currently scheduled.
*
@@ -247,6 +262,16 @@ function _isWaitingForOwner({ getState }: IStore) {
return Boolean(getState()['features/authentication'].waitForOwnerTimeoutID);
}
/**
* Checks if the cyclic "wait for moderator" task is currently scheduled.
*
* @param {Object} store - The redux store.
* @returns {boolean}
*/
function _isWaitingForModerator({ getState }: IStore) {
return getState()['features/authentication'].showModeratorLogin;
}
/**
* Handles login challenge. Opens login dialog or redirects to token auth URL.
*

View File

@@ -4,6 +4,8 @@ import { assign } from '../base/redux/functions';
import {
CANCEL_LOGIN,
DISABLE_MODERATOR_LOGIN,
ENABLE_MODERATOR_LOGIN,
SET_TOKEN_AUTH_URL_SUCCESS,
STOP_WAIT_FOR_OWNER,
UPGRADE_ROLE_FINISHED,
@@ -14,6 +16,7 @@ import {
export interface IAuthenticationState {
error?: Object | undefined;
progress?: number | undefined;
showModeratorLogin?: boolean;
thenableWithCancel?: {
cancel: Function;
};
@@ -45,6 +48,11 @@ ReducerRegistry.register<IAuthenticationState>('features/authentication',
progress: undefined,
thenableWithCancel: undefined
});
case ENABLE_MODERATOR_LOGIN:
return assign(state, {
showModeratorLogin: true
});
case SET_TOKEN_AUTH_URL_SUCCESS:
return assign(state, {
tokenAuthUrlSuccessful: action.value
@@ -56,6 +64,12 @@ ReducerRegistry.register<IAuthenticationState>('features/authentication',
waitForOwnerTimeoutID: undefined
});
case DISABLE_MODERATOR_LOGIN:
return assign(state, {
error: undefined,
showModeratorLogin: false
});
case UPGRADE_ROLE_FINISHED: {
let { thenableWithCancel } = action;

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../logging/functions';
export default getLogger('features/base/app');
export default getLogger('app:base-app');

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../logging/functions';
export default getLogger('features/base/audio-only');
export default getLogger('app:audio-only');

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../logging/functions';
export default getLogger('features/base/conference');
export default getLogger('app:base-conference');

View File

@@ -13,6 +13,7 @@ import {
import { sendAnalytics } from '../../analytics/functions';
import { reloadNow } from '../../app/actions';
import { IStore } from '../../app/types';
import { login } from '../../authentication/actions.any';
import { removeLobbyChatParticipant } from '../../chat/actions.any';
import { openDisplayNamePrompt } from '../../display-name/actions';
import { isVpaasMeeting } from '../../jaas/functions';
@@ -26,7 +27,7 @@ import { AudioMixerEffect } from '../../stream-effects/audio-mixer/AudioMixerEff
import { iAmVisitor } from '../../visitors/functions';
import { overwriteConfig } from '../config/actions';
import { CONNECTION_ESTABLISHED, CONNECTION_FAILED, CONNECTION_WILL_CONNECT } from '../connection/actionTypes';
import { connectionDisconnected, disconnect } from '../connection/actions';
import { connect, connectionDisconnected, disconnect, setPreferVisitor } from '../connection/actions';
import { validateJwt } from '../jwt/functions';
import { JitsiConferenceErrors, JitsiConferenceEvents, JitsiConnectionErrors } from '../lib-jitsi-meet';
import { MEDIA_TYPE } from '../media/constants';
@@ -78,6 +79,11 @@ import { IConferenceMetadata } from './reducer';
*/
let beforeUnloadHandler: ((e?: any) => void) | undefined;
/**
* A simple flag to avoid retrying more than once to join as a visitor when hitting max occupants reached.
*/
let retryAsVisitorOnMaxError = true;
/**
* Implements the middleware of the feature base/conference.
*
@@ -202,11 +208,20 @@ function _conferenceFailed({ dispatch, getState }: IStore, next: Function, actio
break;
}
case JitsiConferenceErrors.CONFERENCE_MAX_USERS: {
dispatch(showErrorNotification({
hideErrorSupportLink: true,
descriptionKey: 'dialog.maxUsersLimitReached',
titleKey: 'dialog.maxUsersLimitReachedTitle'
}));
let retryAsVisitor = false;
if (error.params?.length && error.params[0]?.visitorsSupported) {
// visitors are supported, so let's try joining that way
retryAsVisitor = true;
}
if (!retryAsVisitor) {
dispatch(showErrorNotification({
hideErrorSupportLink: true,
descriptionKey: 'dialog.maxUsersLimitReached',
titleKey: 'dialog.maxUsersLimitReachedTitle'
}));
}
// In case of max users(it can be from a visitor node), let's restore
// oldConfig if any as we will be back to the main prosody.
@@ -220,12 +235,24 @@ function _conferenceFailed({ dispatch, getState }: IStore, next: Function, actio
.then(() => dispatch(disconnect()));
}
if (retryAsVisitor && !newConfig && retryAsVisitorOnMaxError) {
retryAsVisitorOnMaxError = false;
logger.info('On max user reached will retry joining as a visitor');
dispatch(disconnect(true)).then(() => {
dispatch(setPreferVisitor(true));
return dispatch(connect());
});
}
break;
}
case JitsiConferenceErrors.NOT_ALLOWED_ERROR: {
const [ type, msg ] = error.params;
let descriptionKey;
let descriptionKey, customActionNameKey, customActionHandler;
let titleKey = 'dialog.tokenAuthFailed';
if (type === JitsiConferenceErrors.AUTH_ERROR_TYPES.NO_MAIN_PARTICIPANTS) {
@@ -237,9 +264,15 @@ function _conferenceFailed({ dispatch, getState }: IStore, next: Function, actio
descriptionKey = 'visitors.notification.notAllowedPromotion';
} else if (type === JitsiConferenceErrors.AUTH_ERROR_TYPES.ROOM_CREATION_RESTRICTION) {
descriptionKey = 'dialog.errorRoomCreationRestriction';
} else if (type === JitsiConferenceErrors.AUTH_ERROR_TYPES.ROOM_UNAUTHENTICATED_ACCESS_DISABLED) {
titleKey = 'dialog.unauthenticatedAccessDisabled';
customActionNameKey = [ 'toolbar.login' ];
customActionHandler = [ () => dispatch(login()) ];
}
dispatch(showErrorNotification({
customActionNameKey,
customActionHandler,
descriptionKey,
hideErrorSupportLink: true,
titleKey
@@ -300,6 +333,8 @@ function _conferenceJoined({ dispatch, getState }: IStore, next: Function, actio
requireDisplayName
} = getState()['features/base/config'];
retryAsVisitorOnMaxError = true;
dispatch(removeLobbyChatParticipant(true));
pendingSubjectChange && dispatch(setSubject(pendingSubjectChange));

View File

@@ -107,6 +107,7 @@ export interface IJitsiConference {
getParticipantById: Function;
getParticipantCount: Function;
getParticipants: Function;
getPolls: Function;
getRole: Function;
getShortTermCredentials: Function;
getSpeakerStats: () => ISpeakerStats;

View File

@@ -464,6 +464,7 @@ export interface IConfig {
lobby?: {
autoKnock?: boolean;
enableChat?: boolean;
showHangUp?: boolean;
};
localRecording?: {
disable?: boolean;

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../logging/functions';
export default getLogger('features/base/config');
export default getLogger('app:config');

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../logging/functions';
export default getLogger('features/base/connection');
export default getLogger('app:connection');

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../logging/functions';
export default getLogger('features/base/devices');
export default getLogger('app:devices');

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../logging/functions';
export default getLogger('features/base/dialog');
export default getLogger('app:dialog');

View File

@@ -1,4 +1,7 @@
import logger from '../app/logger';
import { UPDATE_FLAGS } from './actionTypes';
import * as featureFlags from './constants';
/**
* Updates the current features flags with the given ones. They will be merged.
@@ -10,6 +13,13 @@ import { UPDATE_FLAGS } from './actionTypes';
* }}
*/
export function updateFlags(flags: Object) {
const supportedFlags = Object.values(featureFlags);
const unsupportedFlags = Object.keys(flags).filter(flag => !supportedFlags.includes(flag as any));
if (unsupportedFlags.length > 0) {
logger.warn(`The following feature flags are not supported: ${unsupportedFlags.join(', ')}.`);
}
return {
type: UPDATE_FLAGS,
flags

View File

@@ -41,8 +41,8 @@ const _LANGUAGES = {
},
// Spanish (Latin America)
'esUS': {
main: require('../../../../lang/main-esUS')
'es-US': {
main: require('../../../../lang/main-es-US')
},
// Estonian
@@ -66,8 +66,8 @@ const _LANGUAGES = {
},
// French (Canadian)
'frCA': {
main: require('../../../../lang/main-frCA')
'fr-CA': {
main: require('../../../../lang/main-fr-CA')
},
// Croatian
@@ -116,8 +116,8 @@ const _LANGUAGES = {
},
// Portuguese (Brazil)
'ptBR': {
main: require('../../../../lang/main-ptBR')
'pt-BR': {
main: require('../../../../lang/main-pt-BR')
},
// Romanian
@@ -166,13 +166,13 @@ const _LANGUAGES = {
},
// Chinese (Simplified)
'zhCN': {
main: require('../../../../lang/main-zhCN')
'zh-CN': {
main: require('../../../../lang/main-zh-CN')
},
// Chinese (Traditional)
'zhTW': {
main: require('../../../../lang/main-zhTW')
'zh-TW': {
main: require('../../../../lang/main-zh-TW')
}
};

View File

@@ -1,67 +0,0 @@
declare let navigator: any;
/**
* Custom language detection, just returns the config property if any.
*/
export default {
/**
* Does not support caching.
*
* @returns {void}
*/
cacheUserLanguage: Function.prototype,
/**
* Looks the language up in the config.
*
* @returns {string} The default language if any.
*/
lookup() {
let found = [];
if (typeof navigator !== 'undefined') {
if (navigator.languages) {
// chrome only; not an array, so can't use .push.apply instead of iterating
for (let i = 0; i < navigator.languages.length; i++) {
found.push(navigator.languages[i]);
}
}
if (navigator.userLanguage) {
found.push(navigator.userLanguage);
}
if (navigator.language) {
found.push(navigator.language);
}
}
found = found.map<string>(normalizeLanguage);
return found.length > 0 ? found : undefined;
},
/**
* Name of the language detector.
*/
name: 'customNavigatorDetector'
};
/**
* Normalize language format.
*
* (en-US => enUS)
* (en-gb => enGB)
* (es-es => es).
*
* @param {string} language - Language.
* @returns {string} The normalized language.
*/
function normalizeLanguage(language: string) {
const [ lang, variant ] = language.replace('_', '-').split('-');
if (!variant || lang.toUpperCase() === variant.toUpperCase()) {
return lang;
}
return lang + variant.toUpperCase();
}

View File

@@ -1,7 +1,6 @@
import BrowserLanguageDetector from 'i18next-browser-languagedetector';
import configLanguageDetector from './configLanguageDetector';
import customNavigatorDetector from './customNavigatorDetector';
/**
* The ordered list (by name) of language detectors to be utilized as backends
@@ -16,7 +15,7 @@ const order = [
// Allow i18next to detect the system language reported by the Web browser
// itself.
interfaceConfig.LANG_DETECTION && order.push(customNavigatorDetector.name);
interfaceConfig.LANG_DETECTION && order.push('navigator');
// Default use configured language
order.push(configLanguageDetector.name);
@@ -34,11 +33,6 @@ const languageDetector
order
});
// Add the language detector which looks the language up in the config. Its
// order has already been established above.
// @ts-ignore
languageDetector.addDetector(customNavigatorDetector);
// @ts-ignore
languageDetector.addDetector(configLanguageDetector);

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../logging/functions';
export default getLogger('features/base/i18n');
export default getLogger('app:i18n');

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../logging/functions';
export default getLogger('features/base/jitsi-local-storage');
export default getLogger('app:jitsi-local-storage');

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../logging/functions';
export default getLogger('features/base/jwt');
export default getLogger('app:jwt');

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../logging/functions';
export default getLogger('features/base/lastn');
export default getLogger('app:lastn');

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../logging/functions';
export default getLogger('features/base/lib-jitsi-meet');
export default getLogger('app:lib-jitsi-meet');

View File

@@ -17,8 +17,8 @@ const DEFAULT_LOGGING_CONFIG: ILoggingConfig = {
loggers: {
// The following are too verbose in their logging with the
// {@link #defaultLogLevel}:
'modules/RTC/TraceablePeerConnection': 'info',
'modules/xmpp/strophe.util': 'log'
'rtc:TraceablePeerConnection': 'info',
'xmpp:strophe.util': 'log'
}
};
@@ -41,10 +41,10 @@ const DEFAULT_STATE = {
// Reduce default verbosity on mobile, it kills performance.
if (navigator.product === 'ReactNative') {
const RN_LOGGERS: { [key: string]: LogLevel; } = {
'modules/sdp/SDPUtil': 'info',
'modules/xmpp/ChatRoom': 'warn',
'modules/xmpp/JingleSessionPC': 'info',
'modules/xmpp/strophe.jingle': 'info'
'sdp:SDPUtils': 'info',
'xmpp:ChatRoom': 'warn',
'xmpp:JingleSessionPC': 'info',
'xmpp:strophe.jingle': 'info'
};
DEFAULT_STATE.config.loggers = {

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../logging/functions';
export default getLogger('features/base/media');
export default getLogger('app:media');

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../logging/functions';
export default getLogger('features/base/net-info');
export default getLogger('app:net-info');

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../logging/functions';
export default getLogger('features/base/participants');
export default getLogger('app:participants');

View File

@@ -4,6 +4,7 @@ import { connect } from 'react-redux';
import { makeStyles } from 'tss-react/mui';
import { IReduxState } from '../../../../app/types';
import { getLobbyConfig } from '../../../../lobby/functions';
import DeviceStatus from '../../../../prejoin/components/web/preview/DeviceStatus';
import { isRoomNameEnabled } from '../../../../prejoin/functions.web';
import Toolbox from '../../../../toolbox/components/web/Toolbox';
@@ -121,10 +122,9 @@ const useStyles = makeStyles()(theme => {
alignItems: 'center',
flexShrink: 0,
boxSizing: 'border-box',
margin: '0 48px',
padding: '24px 0 16px',
position: 'relative',
width: '300px',
width: '400px',
height: '100%',
zIndex: 252,
@@ -146,10 +146,21 @@ const useStyles = makeStyles()(theme => {
contentControls: {
display: 'flex',
flexDirection: 'column',
alignItems: 'center',
alignItems: 'stretch',
margin: 'auto',
width: '100%'
},
paddedContent: {
display: 'flex',
flexDirection: 'column',
alignItems: 'center',
padding: '0 50px',
'& > *': {
width: '100%',
boxSizing: 'border-box'
}
},
title: {
...theme.typography.heading4,
color: `${theme.palette.text01}!important`,
@@ -220,34 +231,38 @@ const PreMeetingScreen = ({
{_isPreCallTestEnabled && <ConnectionStatus />}
<div className = { classes.contentControls }>
<h1 className = { classes.title }>
{title}
</h1>
{_roomName && (
<span className = { classes.roomNameContainer }>
{isOverflowing ? (
<Tooltip content = { _roomName }>
<div className = { classes.paddedContent }>
<h1 className = { classes.title }>
{title}
</h1>
{_roomName && (
<span className = { classes.roomNameContainer }>
{isOverflowing ? (
<Tooltip content = { _roomName }>
<span
className = { classes.roomName }
ref = { roomNameRef }>
{_roomName}
</span>
</Tooltip>
) : (
<span
className = { classes.roomName }
ref = { roomNameRef }>
{_roomName}
</span>
</Tooltip>
) : (
<span
className = { classes.roomName }
ref = { roomNameRef }>
{_roomName}
</span>
)}
</span>
)}
{children}
)}
</span>
)}
{children}
</div>
{_buttons.length && <Toolbox toolbarButtons = { _buttons } />}
{skipPrejoinButton}
{showUnsafeRoomWarning && <UnsafeRoomWarning />}
{showDeviceStatus && <DeviceStatus />}
{showRecordingWarning && <RecordingWarning />}
<div className = { classes.paddedContent }>
{skipPrejoinButton}
{showUnsafeRoomWarning && <UnsafeRoomWarning />}
{showDeviceStatus && <DeviceStatus />}
{showRecordingWarning && <RecordingWarning />}
</div>
</div>
</div>
</div>
@@ -269,10 +284,16 @@ const PreMeetingScreen = ({
function mapStateToProps(state: IReduxState, ownProps: Partial<IProps>) {
const { hiddenPremeetingButtons } = state['features/base/config'];
const { toolbarButtons } = state['features/toolbox'];
const { showHangUp = true } = getLobbyConfig(state);
const { knocking } = state['features/lobby'];
const premeetingButtons = (ownProps.thirdParty
? THIRD_PARTY_PREJOIN_BUTTONS
: PREMEETING_BUTTONS).filter((b: any) => !(hiddenPremeetingButtons || []).includes(b));
if (showHangUp && knocking && !premeetingButtons.includes('hangup')) {
premeetingButtons.push('hangup');
}
const { premeetingBackground } = state['features/dynamic-branding'];
return {

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../logging/functions';
export default getLogger('features/base/premeeting');
export default getLogger('app:premeeting');

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../logging/functions';
export default getLogger('features/base/react');
export default getLogger('app:react');

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../logging/functions';
export default getLogger('features/base/redux');
export default getLogger('app:redux');

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../logging/functions';
export default getLogger('features/base/settings');
export default getLogger('app:settings');

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../logging/functions';
export default getLogger('features/base/sounds');
export default getLogger('app:sounds');

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../logging/functions';
export default getLogger('features/base/testing');
export default getLogger('app:testing');

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../logging/functions';
export default getLogger('features/base/tracks');
export default getLogger('app:tracks');

View File

@@ -22,6 +22,11 @@ interface ICheckboxProps {
*/
disabled?: boolean;
/**
* The id of the input.
*/
id?: string;
/**
* The label of the input.
*/
@@ -147,6 +152,7 @@ const Checkbox = ({
checked,
className,
disabled,
id,
label,
name,
onChange
@@ -160,6 +166,7 @@ const Checkbox = ({
<input
checked = { checked }
disabled = { disabled }
id = { id }
name = { name }
onChange = { onChange }
type = 'checkbox' />

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../logging/functions';
export default getLogger('features/base/util');
export default getLogger('app:util');

View File

@@ -1,5 +1,3 @@
import { getLogger } from '../base/logging/functions';
import { FEATURE_KEY } from './constants';
export default getLogger(FEATURE_KEY);
export default getLogger('app:breakout-rooms');

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../base/logging/functions';
export default getLogger('features/calendar-sync');
export default getLogger('app:calendar-sync');

View File

@@ -78,32 +78,6 @@ interface IProps extends AbstractProps {
*/
_nbUnreadPolls: number;
/**
* Function to send a text message.
*
* @protected
*/
_onSendMessage: Function;
/**
* Function to toggle the chat window.
*/
_onToggleChat: Function;
/**
* Function to display the chat tab.
*
* @protected
*/
_onToggleChatTab: Function;
/**
* Function to display the polls tab.
*
* @protected
*/
_onTogglePollsTab: Function;
/**
* Whether or not to block chat access with a nickname input form.
*/
@@ -244,10 +218,6 @@ const Chat = ({
_messages,
_nbUnreadMessages,
_nbUnreadPolls,
_onSendMessage,
_onToggleChat,
_onToggleChatTab,
_onTogglePollsTab,
_showNamePrompt,
_width,
dispatch,

View File

@@ -387,7 +387,8 @@ const ChatMessage = ({
</div>
{shouldDisplayMenuOnRight && (
<div className = { classes.sideBySideContainer }>
{!message.privateMessage && !message.lobbyChat && <div>
{!message.privateMessage && !message.lobbyChat
&& !message.isReaction && <div>
<div className = { classes.optionsButtonContainer }>
{isHovered && <ReactButton
messageId = { message.messageId }

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../base/logging/functions';
export default getLogger('features/chrome-banner');
export default getLogger('app:chrome-banner');

View File

@@ -1,7 +1,5 @@
import { IStateful } from '../base/app/types';
import { toState } from '../base/redux/functions';
import { iAmVisitor } from '../visitors/functions';
/**
* Tells whether or not the notifications should be displayed within
@@ -30,5 +28,11 @@ export function shouldDisplayNotifications(stateful: IStateful) {
export function arePollsDisabled(stateful: IStateful) {
const state = toState(stateful);
return state['features/base/config']?.disablePolls || iAmVisitor(state);
const { conference } = state['features/base/conference'];
if (!conference?.getPolls()?.isSupported()) {
return true;
}
return state['features/base/config']?.disablePolls;
}

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../base/logging/functions';
export default getLogger('features/conference');
export default getLogger('app:conference');

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../base/logging/functions';
export default getLogger('features/desktop-picker');
export default getLogger('app:desktop-picker');

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../base/logging/functions';
export default getLogger('features/device-selection');
export default getLogger('app:device-selection');

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../base/logging/functions';
export default getLogger('features/dropbox');
export default getLogger('app:dropbox');

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../base/logging/functions';
export default getLogger('features/dynamic-branding');
export default getLogger('app:dynamic-branding');

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../base/logging/functions';
export default getLogger('features/e2ee');
export default getLogger('app:e2ee');

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../base/logging/functions';
export default getLogger('features/face-landmarks');
export default getLogger('app:face-landmarks');

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../base/logging/functions';
export default getLogger('features/feedback');
export default getLogger('app:feedback');

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../base/logging/functions';
export default getLogger('features/file-sharing');
export default getLogger('app:file-sharing');

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../base/logging/functions';
export default getLogger('features/filmstrip');
export default getLogger('app:filmstrip');

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../base/logging/functions';
export default getLogger('features/follow-me');
export default getLogger('app:follow-me');

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../base/logging/functions';
export default getLogger('features/base/redux');
export default getLogger('app:redux');

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../base/logging/functions';
export default getLogger('features/invite');
export default getLogger('app:invite');

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../base/logging/functions';
export default getLogger('features/jaas');
export default getLogger('app:jaas');

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../base/logging/functions';
export default getLogger('features/keyboard-shortcuts');
export default getLogger('app:keyboard-shortcuts');

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../base/logging/functions';
export default getLogger('features/large-video');
export default getLogger('app:large-video');

View File

@@ -13,6 +13,7 @@ import { updateSettings } from '../../base/settings/actions';
import { IMessage } from '../../chat/types';
import { isDeviceStatusVisible } from '../../prejoin/functions';
import { cancelKnocking, joinWithPassword, onSendMessage, setPasswordJoinFailed, startKnocking } from '../actions';
import { getLobbyConfig } from '../functions';
export const SCREEN_STATES = {
EDIT: 1,
@@ -27,6 +28,11 @@ export interface IProps {
*/
_deviceStatusVisible: boolean;
/**
* Whether to show the hangup button.
*/
_hangUp?: boolean;
/**
* Indicates whether the message that display name is required is shown.
*/
@@ -52,6 +58,11 @@ export interface IProps {
*/
_lobbyMessageRecipient?: string;
/**
* Whether to hide the login button.
*/
_login?: boolean;
/**
* The name of the meeting we're about to join.
*/
@@ -445,8 +456,10 @@ export function _mapStateToProps(state: IReduxState) {
const { disableLobbyPassword } = getSecurityUiConfig(state);
const showCopyUrlButton = inviteEnabledFlag || !disableInviteFunctions;
const deviceStatusVisible = isDeviceStatusVisible(state);
const { showHangUp = true } = getLobbyConfig(state);
const { membersOnly, lobbyWaitingForHost } = state['features/base/conference'];
const { isLobbyChatActive, lobbyMessageRecipient, messages } = state['features/chat'];
const { showModeratorLogin } = state['features/authentication'];
return {
_deviceStatusVisible: deviceStatusVisible,
@@ -454,6 +467,8 @@ export function _mapStateToProps(state: IReduxState) {
_knocking: knocking,
_lobbyChatMessages: messages,
_lobbyMessageRecipient: lobbyMessageRecipient?.name,
_login: showModeratorLogin,
_hangUp: showHangUp,
_isLobbyChatActive: isLobbyChatActive,
_meetingName: getConferenceName(state),
_membersOnlyConference: membersOnly,

View File

@@ -3,6 +3,7 @@ import { Text, TextStyle, View, ViewStyle } from 'react-native';
import { connect } from 'react-redux';
import { IReduxState } from '../../../app/types';
import { login } from '../../../authentication/actions.any';
import { getConferenceName } from '../../../base/conference/functions';
import { translate } from '../../../base/i18n/functions';
import JitsiScreen from '../../../base/modal/components/JitsiScreen';
@@ -18,6 +19,7 @@ import { navigate }
from '../../../mobile/navigation/components/lobby/LobbyNavigationContainerRef';
import { screen } from '../../../mobile/navigation/routes';
import { preJoinStyles } from '../../../prejoin/components/native/styles';
import HangupButton from '../../../toolbox/components/HangupButton';
import AudioMuteButton from '../../../toolbox/components/native/AudioMuteButton';
import VideoMuteButton from '../../../toolbox/components/native/VideoMuteButton';
import AbstractLobbyScreen, {
@@ -43,6 +45,18 @@ interface IProps extends AbstractProps {
* Implements a waiting screen that represents the participant being in the lobby.
*/
class LobbyScreen extends AbstractLobbyScreen<IProps> {
/**
* Initializes a new LobbyScreen instance.
*
* @param {IProps} props - The read-only properties with which the new
* instance is to be initialized.
*/
constructor(props: IProps) {
super(props);
this._onLogin = this._onLogin.bind(this);
}
/**
* Implements {@code PureComponent#render}.
*
@@ -197,12 +211,19 @@ class LobbyScreen extends AbstractLobbyScreen<IProps> {
* @inheritdoc
*/
_renderToolbarButtons() {
const { _hangUp } = this.props;
return (
<View style = { preJoinStyles.toolboxContainer as ViewStyle }>
<AudioMuteButton
styles = { preJoinStyles.buttonStylesBorderless } />
<VideoMuteButton
styles = { preJoinStyles.buttonStylesBorderless } />
{
_hangUp
&& <HangupButton
styles = { preJoinStyles.buttonStylesBorderless } />
}
</View>
);
}
@@ -213,7 +234,7 @@ class LobbyScreen extends AbstractLobbyScreen<IProps> {
* @inheritdoc
*/
_renderStandardButtons() {
const { _knocking, _renderPassword, _isLobbyChatActive } = this.props;
const { _knocking, _renderPassword, _isLobbyChatActive, _login } = this.props;
const { displayName } = this.state;
return (
@@ -246,9 +267,28 @@ class LobbyScreen extends AbstractLobbyScreen<IProps> {
style = { preJoinStyles.joinButton }
type = { BUTTON_TYPES.PRIMARY } />
}
{
_login
&& <Button
accessibilityLabel = 'dialog.IamHost'
labelKey = 'dialog.IamHost'
onClick = { this._onLogin }
style = { preJoinStyles.joinButton }
type = { BUTTON_TYPES.PRIMARY } />
}
</View>
);
}
/**
* Handles login button click.
*
* @private
* @returns {void}
*/
_onLogin() {
this.props.dispatch(login());
}
}
/**

View File

@@ -1,6 +1,8 @@
import React from 'react';
import { connect } from 'react-redux';
import { login } from '../../../authentication/actions.any';
import { leaveConference } from '../../../base/conference/actions';
import { translate } from '../../../base/i18n/functions';
import Icon from '../../../base/icons/components/Icon';
import { IconCloseLarge } from '../../../base/icons/svg';
@@ -8,6 +10,7 @@ import PreMeetingScreen from '../../../base/premeeting/components/web/PreMeeting
import LoadingIndicator from '../../../base/react/components/web/LoadingIndicator';
import Button from '../../../base/ui/components/web/Button';
import Input from '../../../base/ui/components/web/Input';
import { BUTTON_TYPES } from '../../../base/ui/constants.any';
import ChatInput from '../../../chat/components/web/ChatInput';
import MessageContainer from '../../../chat/components/web/MessageContainer';
import AbstractLobbyScreen, {
@@ -35,6 +38,10 @@ class LobbyScreen extends AbstractLobbyScreen<IProps> {
super(props);
this._messageContainerRef = React.createRef<MessageContainer>();
// Bind authentication methods
this._onLogin = this._onLogin.bind(this);
this._onHangup = this._onHangup.bind(this);
}
/**
@@ -84,7 +91,7 @@ class LobbyScreen extends AbstractLobbyScreen<IProps> {
* @inheritdoc
*/
override _renderJoining() {
const { _isLobbyChatActive } = this.props;
const { _login, _isLobbyChatActive } = this.props;
return (
<div className = 'lobby-screen-content'>
@@ -96,7 +103,7 @@ class LobbyScreen extends AbstractLobbyScreen<IProps> {
<LoadingIndicator size = 'large' />
</div>
<span className = 'joining-message'>
{ this.props.t('lobby.joiningMessage') }
{ this.props.t(_login ? 'lobby.waitForModerator' : 'lobby.joiningMessage') }
</span>
</>
)}
@@ -215,14 +222,14 @@ class LobbyScreen extends AbstractLobbyScreen<IProps> {
labelKey = 'prejoin.joinMeeting'
onClick = { this._onJoinWithPassword }
testId = 'lobby.passwordJoinButton'
type = 'primary' />
type = { BUTTON_TYPES.PRIMARY } />
<Button
className = 'lobby-button-margin'
fullWidth = { true }
labelKey = 'lobby.backToKnockModeButton'
onClick = { this._onSwitchToKnockMode }
testId = 'lobby.backToKnockModeButton'
type = 'secondary' />
type = { BUTTON_TYPES.SECONDARY } />
</>
);
}
@@ -233,7 +240,7 @@ class LobbyScreen extends AbstractLobbyScreen<IProps> {
* @inheritdoc
*/
override _renderStandardButtons() {
const { _knocking, _isLobbyChatActive, _renderPassword } = this.props;
const { _knocking, _login, _isLobbyChatActive, _renderPassword } = this.props;
return (
<>
@@ -260,7 +267,15 @@ class LobbyScreen extends AbstractLobbyScreen<IProps> {
labelKey = 'lobby.enterPasswordButton'
onClick = { this._onSwitchToPasswordMode }
testId = 'lobby.enterPasswordButton'
type = 'secondary' />
type = { BUTTON_TYPES.SECONDARY } />
}
{_login && <Button
className = 'lobby-button-margin'
fullWidth = { true }
labelKey = 'dialog.IamHost'
onClick = { this._onLogin }
testId = 'lobby.loginButton'
type = { BUTTON_TYPES.PRIMARY } />
}
</>
);
@@ -279,6 +294,26 @@ class LobbyScreen extends AbstractLobbyScreen<IProps> {
this._messageContainerRef.current.scrollToElement(withAnimation, null);
}
}
/**
* Handles login button click.
*
* @private
* @returns {void}
*/
_onLogin() {
this.props.dispatch(login());
}
/**
* Handles hangup button click.
*
* @private
* @returns {void}
*/
_onHangup() {
this.props.dispatch(leaveConference());
}
}
export default translate(connect(_mapStateToProps)(LobbyScreen));

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../base/logging/functions';
export default getLogger('features/lobby');
export default getLogger('app:lobby');

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../../base/logging/functions';
export default getLogger('features/mobile/audio-mode');
export default getLogger('mobile-app:audio-mode');

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../../base/logging/functions';
export default getLogger('features/mobile/background');
export default getLogger('mobile-app:background');

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../../base/logging/functions';
export default getLogger('features/mobile/external-api');
export default getLogger('mobile-app:external-api');

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../../base/logging/functions';
export default getLogger('features/full-screen');
export default getLogger('mobile-app:full-screen');

View File

@@ -1,3 +1,3 @@
import { getLogger } from '../../base/logging/functions';
export default getLogger('features/mobile/pip');
export default getLogger('mobile-app:pip');

View File

@@ -8,67 +8,10 @@ import 'promise.withresolvers/auto'; // Promise.withResolvers.
import 'react-native-url-polyfill/auto'; // Complete URL polyfill.
import Storage from './Storage';
import { querySelector, querySelectorAll } from './querySelectorPolyfill';
const { AppInfo } = NativeModules;
/**
* Implements an absolute minimum of the common logic of
* {@code Document.querySelector} and {@code Element.querySelector}. Implements
* the most simple of selectors necessary to satisfy the call sites at the time
* of this writing (i.e. Select by tagName).
*
* @param {Node} node - The Node which is the root of the tree to query.
* @param {string} selectors - The group of CSS selectors to match on.
* @returns {Element} - The first Element which is a descendant of the specified
* node and matches the specified group of selectors.
*/
function _querySelector(node, selectors) {
let element = null;
node && _visitNode(node, n => {
if (n.nodeType === 1 /* ELEMENT_NODE */
&& n.nodeName === selectors) {
element = n;
return true;
}
return false;
});
return element;
}
/**
* Visits each Node in the tree of a specific root Node (using depth-first
* traversal) and invokes a specific callback until the callback returns true.
*
* @param {Node} node - The root Node which represents the tree of Nodes to
* visit.
* @param {Function} callback - The callback to invoke with each visited Node.
* @returns {boolean} - True if the specified callback returned true for a Node
* (at which point the visiting stopped); otherwise, false.
*/
function _visitNode(node, callback) {
if (callback(node)) {
return true;
}
/* eslint-disable no-param-reassign, no-extra-parens */
if ((node = node.firstChild)) {
do {
if (_visitNode(node, callback)) {
return true;
}
} while ((node = node.nextSibling));
}
/* eslint-enable no-param-reassign, no-extra-parens */
return false;
}
(global => {
// DOMParser
//
@@ -97,7 +40,6 @@ function _visitNode(node, callback) {
// document
//
// Required by:
// - jQuery
// - Strophe
if (typeof global.document === 'undefined') {
const document
@@ -156,7 +98,17 @@ function _visitNode(node, callback) {
if (elementPrototype) {
if (typeof elementPrototype.querySelector === 'undefined') {
elementPrototype.querySelector = function(selectors) {
return _querySelector(this, selectors);
return querySelector(this, selectors);
};
}
// Element.querySelectorAll
//
// Required by:
// - lib-jitsi-meet XMLUtils
if (typeof elementPrototype.querySelectorAll === 'undefined') {
elementPrototype.querySelectorAll = function(selectors) {
return querySelectorAll(this, selectors);
};
}
@@ -235,6 +187,51 @@ function _visitNode(node, callback) {
}
}
// Document.querySelector
//
// Required by:
// - lib-jitsi-meet -> XMLUtils.ts -> parseXML
if (typeof document.querySelector === 'undefined') {
document.querySelector = function(selectors) {
return this.documentElement ? querySelector(this.documentElement, selectors) : null;
};
}
// Document.querySelectorAll
//
// Required by:
// - lib-jitsi-meet -> XMLUtils.ts -> parseXML
if (typeof document.querySelectorAll === 'undefined') {
document.querySelectorAll = function(selectors) {
return this.documentElement ? querySelectorAll(this.documentElement, selectors) : [];
};
}
// Also add querySelector methods to Document.prototype for DOMParser-created documents
const documentPrototype = Object.getPrototypeOf(document);
if (documentPrototype) {
// Document.querySelector
//
// Required by:
// - lib-jitsi-meet -> XMLUtils.ts -> parseXML
if (typeof documentPrototype.querySelector === 'undefined') {
documentPrototype.querySelector = function(selectors) {
return this.documentElement ? querySelector(this.documentElement, selectors) : null;
};
}
// Document.querySelectorAll
//
// Required by:
// - lib-jitsi-meet -> XMLUtils.ts -> parseXML
if (typeof documentPrototype.querySelectorAll === 'undefined') {
documentPrototype.querySelectorAll = function(selectors) {
return this.documentElement ? querySelectorAll(this.documentElement, selectors) : [];
};
}
}
global.document = document;
}

Some files were not shown because too many files have changed in this diff Show More