Skip to content

Commit 42c6f5c

Browse files
committed
🐛 Fixed issue with InTeams
1 parent bd9ae86 commit 42c6f5c

File tree

3 files changed

+7
-31
lines changed

3 files changed

+7
-31
lines changed

package-lock.json

Lines changed: 5 additions & 22 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "msteams-react-base-component",
3-
"version": "4.0.0-preview2",
3+
"version": "4.0.0-preview3",
44
"description": "React helper components for Microsoft Teams apps",
55
"main": "lib/cjs/index.js",
66
"module": "lib/esm/index.js",
@@ -55,7 +55,7 @@
5555
"eslint-plugin-react": "^7.26.0",
5656
"eslint-plugin-react-hooks": "^4.2.0",
5757
"jest": "^27.2.3",
58-
"jest-junit": "^12.3.0",
58+
"jest-junit": "^13.0.0",
5959
"mocha": "^9.1.2",
6060
"react": "^16.8.6",
6161
"react-dom": "^16.8.6",

src/useTeams.ts

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -8,13 +8,6 @@ import { app, pages } from "@microsoft/teams-js";
88
import { teamsDarkTheme, teamsHighContrastTheme, teamsTheme, ThemePrepared } from "@fluentui/react-northstar";
99

1010
export const checkInTeams = (): boolean => {
11-
// eslint-disable-next-line dot-notation
12-
const microsoftTeamsLib = window["microsoftTeams"];
13-
14-
if (!microsoftTeamsLib) {
15-
return false; // the Microsoft Teams library is for some reason not loaded
16-
}
17-
1811
if ((window.parent === window.self && (window as any).nativeInterface) ||
1912
window.navigator.userAgent.includes("Teams/") ||
2013
window.name === "embedded-page-container" ||

0 commit comments

Comments
 (0)