@newtonschool/react_proctoring_library 0.0.123 → 0.0.124-beta.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -13,8 +13,8 @@ const DisableExtendedDisplay = _ref => {
|
|
|
13
13
|
setExtendedDisplayConnected
|
|
14
14
|
} = (0, _react.useContext)(proctoredContext);
|
|
15
15
|
(0, _react.useEffect)(() => {
|
|
16
|
-
setExtendedDisplayConnected(window.screen.isExtended);
|
|
17
|
-
const intervalId = setInterval(() => setExtendedDisplayConnected(window.screen.isExtended), 10000);
|
|
16
|
+
setExtendedDisplayConnected(!!window.screen.isExtended);
|
|
17
|
+
const intervalId = setInterval(() => setExtendedDisplayConnected(!!window.screen.isExtended), 10000);
|
|
18
18
|
return () => clearInterval(intervalId);
|
|
19
19
|
}, []);
|
|
20
20
|
return null;
|
|
@@ -39,7 +39,7 @@ const ProctoredContextApp = _ref => {
|
|
|
39
39
|
const [videoPermission, setVideoPermission] = (0, _react.useState)();
|
|
40
40
|
const [screensharePermission, setScreensharePermission] = (0, _react.useState)();
|
|
41
41
|
const [openHeimdallAppPermission, setOpenHeimdallAppPermission] = (0, _react.useState)(false);
|
|
42
|
-
const [extendedDisplayConnected, setExtendedDisplayConnected] = (0, _react.useState)(
|
|
42
|
+
const [extendedDisplayConnected, setExtendedDisplayConnected] = (0, _react.useState)(false);
|
|
43
43
|
const [shouldShowDownloadHeimdallButton, setShouldShowDownloadHeimdallButton] = (0, _react.useState)(false);
|
|
44
44
|
const [isHeimdallSuccessfullyInstalledByScript, setIsHeimdallSuccessfullyInstalledByScript] = (0, _react.useState)(false);
|
|
45
45
|
const setUpdateId = (0, _react.useState)(0)[1];
|
|
@@ -66,7 +66,7 @@ const ProctoredContextApp = _ref => {
|
|
|
66
66
|
fullscreen: isFullscreen,
|
|
67
67
|
screenshare: screensharePermission,
|
|
68
68
|
openHeimdall: openHeimdallAppPermission,
|
|
69
|
-
extendedDisplayConnected
|
|
69
|
+
singleScreen: !extendedDisplayConnected
|
|
70
70
|
}), [videoPermission, audioPermission, isFullscreen, screensharePermission, openHeimdallAppPermission, extendedDisplayConnected]);
|
|
71
71
|
const proctorParams = (0, _react.useMemo)(() => _objectSpread(_objectSpread({}, _defaults.defaultConfig), config.proctorParams), [config.proctorParams]);
|
|
72
72
|
const Context = contextProvider;
|
|
@@ -12,7 +12,6 @@ const defaultConfig = exports.defaultConfig = {
|
|
|
12
12
|
openHeimdall: true,
|
|
13
13
|
copyPasteProctoring: true,
|
|
14
14
|
pageFocus: true,
|
|
15
|
-
singleScreen: true,
|
|
16
15
|
disableExtendedDisplay: true
|
|
17
16
|
};
|
|
18
17
|
const initialValues = exports.initialValues = {
|
|
@@ -48,7 +47,7 @@ const proctorParamsToPermission = exports.proctorParamsToPermission = {
|
|
|
48
47
|
audio: 'audio',
|
|
49
48
|
openHeimdall: 'openHeimdall',
|
|
50
49
|
downloadHeimdall: 'downloadHeimdall',
|
|
51
|
-
|
|
50
|
+
disableExtendedDisplay: 'singleScreen'
|
|
52
51
|
};
|
|
53
52
|
const evaluateVideoIntervalInSeconds = exports.evaluateVideoIntervalInSeconds = 5;
|
|
54
53
|
const gpuTypes = exports.gpuTypes = ['intel', 'apple', 'amd', 'radeon', 'nvidia', 'geforce'];
|