Skip to content

Commit

Permalink
feat: add opt in handling for teams v2 (#1160)
Browse files Browse the repository at this point in the history
* feat: add opt in handling for teams v2

* add support for changing idle (away) state in Teams2 (#1157)

* add support for changing idle (away) state in Teams2

* package.json: bump version to 1.4.16

* feat: add opt in handling for teams v2

* fix: handle both cases and avoid unnecessary reloads

* chore: version bump

* Update app/config/index.js

wording change - accepted

Co-authored-by: IsmaelMartinez <ISMAELMARTINEZ@GMAIL.COM>

* chore: updated README

fix: fix some codeBeat failures

* fix: missing passed option object

* Update app/config/index.js

---------

Co-authored-by: Marcel S. Henselin <marcel.henselin@mmmake.com>
Co-authored-by: Sebastian Hiebl <bastidest@mailbox.org>
Co-authored-by: IsmaelMartinez <ISMAELMARTINEZ@GMAIL.COM>
  • Loading branch information
4 people committed Mar 31, 2024
1 parent 82f480b commit 134d579
Show file tree
Hide file tree
Showing 6 changed files with 474 additions and 439 deletions.
3 changes: 2 additions & 1 deletion app/appConfiguration/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,8 @@ let _AppConfiguration_settingsStore = new WeakMap();

class AppConfiguration {
/**
* @param {string} configPath
* @param {string} configPath
* @param appVersion
*/
constructor(configPath, appVersion) {
_AppConfiguration_configPath.set(this, configPath);
Expand Down
89 changes: 45 additions & 44 deletions app/config/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,50 +8,51 @@ The application uses [yargs](https://www.npmjs.com/package/yargs) to allow comma

Here is the list of available arguments and its usage:

| Option | Usage | Default Value |
|:-:|:-:|:-:|
| appActiveCheckInterval | A numeric value in seconds as poll interval to check if the system is active from being idle | 2 |
| appIcon | Teams app icon to show in the tray | |
| appIconType | Type of tray icon to be used default/light/dark | default |
| appIdleTimeout | A numeric value in seconds as duration before app considers the system as idle | 300 |
| appIdleTimeoutCheckInterval | A numeric value in seconds as poll interval to check if the appIdleTimeout is reached | 10 |
| appLogLevels | Comma separated list of log levels (error,warn,info,debug) | error,warn |
| appTitle | A text to be suffixed with page title | Microsoft Teams |
| authServerWhitelist | set auth-server-whitelist value | * |
| chromeUserAgent | user agent string for chrome | Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/77.0.3831.6 Safari/537.36 |
| customBGServiceBaseUrl | Base URL of the server which provides custom background images | http://localhost |
| customBGServiceConfigFetchInterval | A numeric value in seconds as poll interval to download custom background service configuration. If 0, it will be downloaded only at application start | 0 |
| customBGServiceIgnoreMSDefaults | A flag indicates whether to ignore Microsoft provided images or not | false |
| customCACertsFingerprints | custom CA Certs Fingerprints to allow SSL unrecognized signer or self signed certificate (see below) | [] |
| customCSSName | Custom CSS name for the packaged available css files. Currently those are: "compactDark", "compactLight", "tweaks", "condensedDark" and "condensedLight" | |
| customCSSLocation | Location for custom CSS styles | |
| customUserDir | Custom User Directory so that you can have multiple profiles | |
| clearStorage | Whether to clear the storage before creating the window or not | false |
| clientCertPath clientCertPassword | custom Client Certs for corporate authentication (certificate must be in pkcs12 format) | [] |
| closeAppOnCross | Close the app when clicking the close (X) cross | false |
| config | config file location | ~/.config/teams-for-linux/config.json |
| defaultURLHandler | Default application to be used to open the HTTP URLs | |
| disableAutogain | A flag indicates whether to disable mic auto gain or not | false |
| disableGpu | A flag to disable GPU and hardware acceleration (can be useful if the window remains blank) | false |
| disableMeetingNotifications | Whether to disable meeting notifications or not | false |
| disableNotifications | A flag to disable all notifications | false |
| disableNotificationSound | Disable chat/meeting start notification sound | false |
| disableNotificationSoundIfNotAvailable | Disable chat/meeting start notification sound if status is not Available (e.g. busy, in a call) | true |
| disableNotificationWindowFlash | A flag indicates whether to disable window flashing when there is a notification | false |
| followSystemTheme | A flag to enable automatic app theme switching (Default vs Dark) based on the current system theme | false |
| help | show the available commands | false |
| onlineCheckMethod | Type of network test for checking online status, can be: https, dns, native, none | https |
| partition | [BrowserWindow](https://electronjs.org/docs/api/browser-window) webpreferences partition | persist:teams-4-linux |
| proxyServer | Proxy Server with format address:port | None |
| menubar | A value controls the menu bar behaviour (auto/visible/hidden) | auto |
| minimized | Start the application minimized | false |
| ntlmV2enabled | set enable-ntlm-v2 value | true |
| screenLockInhibitionMethod | Screen lock inhibition method to be used (Electron/WakeLockSentinel) | Electron |
| spellCheckerLanguages | Language codes to use with Electron\'s spell checker (experimental) | [] |
| url | url to open | [https://teams.microsoft.com/](https://teams.microsoft.com/) |
| version | show the version number | false |
| webDebug | Start with the browser developer tools open | false |
| incomingCallCommand | Command to execute on an incoming call | |
| Option | Usage | Default Value |
|:--------------------------------------:|:--------------------------------------------------------------------------------------------------------------------------------------------------------:|:-------------------------------------------------------------------------------------------------------:|
| appActiveCheckInterval | A numeric value in seconds as poll interval to check if the system is active from being idle | 2 |
| appIcon | Teams app icon to show in the tray | |
| appIconType | Type of tray icon to be used default/light/dark | default |
| appIdleTimeout | A numeric value in seconds as duration before app considers the system as idle | 300 |
| appIdleTimeoutCheckInterval | A numeric value in seconds as poll interval to check if the appIdleTimeout is reached | 10 |
| appLogLevels | Comma separated list of log levels (error,warn,info,debug) | error,warn |
| appTitle | A text to be suffixed with page title | Microsoft Teams |
| authServerWhitelist | set auth-server-whitelist value | * |
| chromeUserAgent | user agent string for chrome | Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/77.0.3831.6 Safari/537.36 |
| customBGServiceBaseUrl | Base URL of the server which provides custom background images | http://localhost |
| customBGServiceConfigFetchInterval | A numeric value in seconds as poll interval to download custom background service configuration. If 0, it will be downloaded only at application start | 0 |
| customBGServiceIgnoreMSDefaults | A flag indicates whether to ignore Microsoft provided images or not | false |
| customCACertsFingerprints | custom CA Certs Fingerprints to allow SSL unrecognized signer or self signed certificate (see below) | [] |
| customCSSName | Custom CSS name for the packaged available css files. Currently those are: "compactDark", "compactLight", "tweaks", "condensedDark" and "condensedLight" | |
| customCSSLocation | Location for custom CSS styles | |
| customUserDir | Custom User Directory so that you can have multiple profiles | |
| clearStorage | Whether to clear the storage before creating the window or not | false |
| clientCertPath clientCertPassword | custom Client Certs for corporate authentication (certificate must be in pkcs12 format) | [] |
| closeAppOnCross | Close the app when clicking the close (X) cross | false |
| config | config file location | ~/.config/teams-for-linux/config.json |
| defaultURLHandler | Default application to be used to open the HTTP URLs | |
| disableAutogain | A flag indicates whether to disable mic auto gain or not | false |
| disableGpu | A flag to disable GPU and hardware acceleration (can be useful if the window remains blank) | false |
| disableMeetingNotifications | Whether to disable meeting notifications or not | false |
| disableNotifications | A flag to disable all notifications | false |
| disableNotificationSound | Disable chat/meeting start notification sound | false |
| disableNotificationSoundIfNotAvailable | Disable chat/meeting start notification sound if status is not Available (e.g. busy, in a call) | true |
| disableNotificationWindowFlash | A flag indicates whether to disable window flashing when there is a notification | false |
| followSystemTheme | A flag to enable automatic app theme switching (Default vs Dark) based on the current system theme | false |
| help | show the available commands | false |
| optInTeamsV2 | Set this option to use MS Teams V2 | false |
| onlineCheckMethod | Type of network test for checking online status, can be: https, dns, native, none | https |
| partition | [BrowserWindow](https://electronjs.org/docs/api/browser-window) webpreferences partition | persist:teams-4-linux |
| proxyServer | Proxy Server with format address:port | None |
| menubar | A value controls the menu bar behaviour (auto/visible/hidden) | auto |
| minimized | Start the application minimized | false |
| ntlmV2enabled | set enable-ntlm-v2 value | true |
| screenLockInhibitionMethod | Screen lock inhibition method to be used (Electron/WakeLockSentinel) | Electron |
| spellCheckerLanguages | Language codes to use with Electron\'s spell checker (experimental) | [] |
| url | url to open (will be overridden, if opted in to use Teams V2) | [https://teams.microsoft.com/](https://teams.microsoft.com/) |
| version | show the version number | false |
| webDebug | Start with the browser developer tools open | false |
| incomingCallCommand | Command to execute on an incoming call | |


As an example, to disable the persistence, you can run the following command:
Expand Down
5 changes: 5 additions & 0 deletions app/config/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -172,6 +172,11 @@ function argv(configPath, appVersion) {
describe: 'BrowserWindow webpreferences partition',
type: 'string'
},
optInTeamsV2: {
default: false,
describe: 'Opt in to use Teams V2',
type: 'boolean'
},
proxyServer: {
default: null,
describe: 'Proxy Server with format address:port',
Expand Down

0 comments on commit 134d579

Please sign in to comment.