mario-core 2.9.371-prod → 2.9.372-release
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.
- package/dist/index.css +3 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.js +13 -19
- package/dist/index.js.map +1 -1
- package/dist/index.modern.js +14 -19
- package/dist/index.modern.js.map +1 -1
- package/package.json +2 -3
package/dist/index.css
CHANGED
package/dist/index.d.ts
CHANGED
|
@@ -111,7 +111,7 @@ import { setBandScoreList } from "./redux/bandScores/action";
|
|
|
111
111
|
import { setStudentIdSelectedByTeacher } from "./redux/navMobile/action";
|
|
112
112
|
import { setEnableIEP, setEnableSurvey, setConversationOneToOne, setLanguage, setSandboxMode } from "./redux/commons/action";
|
|
113
113
|
import useFilters from "./hooks/useFilters";
|
|
114
|
-
import amplitude from "amplitude-
|
|
114
|
+
import * as amplitude from "@amplitude/analytics-browser";
|
|
115
115
|
import { setWeeklyQuestList, setOpenModelCongratulation } from "./redux/weeklyQuests/action";
|
|
116
|
-
declare const amplitudeClient: amplitude
|
|
116
|
+
declare const amplitudeClient: typeof amplitude;
|
|
117
117
|
export { Login, Dashboard, TheLayout, TheContent, NotFound, EmailTemplateList, EmailTemplateDetail, FaqList, SkillList, UserList, UserContainer, UserDetail, Loading, NotificationModal, CommonHeader, CommonModal, NotificationLogoutModal, AddButton, DeleteButtonIcon, EditButtonIcon, LinkEditButton, ToggleButton, EmptyDataAlert, SandboxAlert, CreatableSelector, CustomPagination, SearchBox, FileInput, QuitPrompt, QuestionTypeSelector, QuestionCategorySelector, SuggestionCategorySelector, CategorySelector, ErrorHandler, DetailActionButtons, RequiredLabel, StarRatingSelector, ReactNotification, NotificationList, CustomSelector, UploadFileButton, SearchBoxContainer, CustomTab, CommonAlert, GalleryList, MediaList, useGalleryList, AcademicClassSelector, SchoolList, store, showMenuBar, showFontSize, setLoading, setModal, setAlert, setClassList, setConferenceRubricList, setSuggestionList, setStrategyList, setSubjectList, setLearningSupportCategoryList, setQuestionList, setUserList, setStudentList, setBadgeList, setGoalExampleList, setSemesterList, setFeedbackList, setAssessmentList, setQuestionByCategory, setSelectQuestion, setMoveItemQuestion, setReflectionList, setReflectionResultList, setEditItemQuesion, setResetQuestionList, setMailCategory, setUser, setAssignmentList, setAssistantList, setSessionTemplateList, setTutorialScreenList, setSessionTemplateGeneralClassList, setCustomAlertList, setCertificateList, closeTab, addTab, editTab, clearTab, changeNote, changeTags, answerQuestion, setSessionPlayer, setStartTime, setTurnOffPassWhenChangeMode, reset, setImproveMyClass, setSchoolBlankDayList, setEnableIEP, setEnableSurvey, setConversationOneToOne, setLanguage, setWeeklyQuestList, setOpenModelCongratulation, setSandboxMode, i18n, useTranslation, I18nextProvider, api, apiUpload, uploadFile, systemStudentBadge, systemCertificateUpload, BASE_URL, DEFAULT_FILTER, LICENSE_AGGRID, TINY_MCE_API_KEY, QUESTION_TYPES, QUESTION_TYPES_OPTIONS, ANSWER_EDITOR_HEIGHT, CHAT_CHANNEL, NOTIFICATION_CHANNEL, DATE_RESULT, DATE_FORMAT, FULL_DATE_RESULT, ACCESS_TOKEN, NOTIFICATION_ALERT_KEY, GOOGLE_RECAPTCHA_KEY, DEFAULT_LANGUAGE_CODE, LANGUAGES, SUPPORTED_LANGUAGES_CODE, EMOTIONS, TAB_COLORS, SANDBOX_NOTIFICATION, Filter, Conversation, Message, ConversationMember, NavbarTab, editorConfig, generateRandomString, isInViewport, debounce, firstCheckToken, canAccessRoute, getFileUrl, getTextFromHTML, utcToLocalTime, getInfo, Images, setQuestionCateList, setMyStudent, setDataPlayer, answerQuestionDataPlayer, setCurrentStudentUserId, setCurrentStudentId, setCurrentStudentName, setFilterWidget, setBandScoreList, setStudentIdSelectedByTeacher, useFilters, ScrollToTop, initAmplitude, amplitudeClient, INIT_AMPLITUDE_KEY_STAGE, INIT_AMPLITUDE_KEY_PROD, isLocalhost, getStaticFileUrl, IS_USER_SESSION_BROWSER, getCookieValue };
|
package/dist/index.js
CHANGED
|
@@ -14,7 +14,7 @@ var reactGoogleRecaptchaV3 = require('react-google-recaptcha-v3');
|
|
|
14
14
|
var GoogleLogin = _interopDefault(require('react-google-login'));
|
|
15
15
|
var toolkit = require('@reduxjs/toolkit');
|
|
16
16
|
var axios = _interopDefault(require('axios'));
|
|
17
|
-
var amplitude =
|
|
17
|
+
var amplitude = require('@amplitude/analytics-browser');
|
|
18
18
|
var moment = _interopDefault(require('moment'));
|
|
19
19
|
var msalBrowser = require('@azure/msal-browser');
|
|
20
20
|
var gi = require('react-icons/gi');
|
|
@@ -38213,12 +38213,12 @@ var apiUpload = axios.create({
|
|
|
38213
38213
|
var hostName = window.location.hostname;
|
|
38214
38214
|
|
|
38215
38215
|
if (userEmail) {
|
|
38216
|
-
amplitude.
|
|
38216
|
+
amplitude.track("general: session end", {
|
|
38217
38217
|
user_id: userEmail,
|
|
38218
38218
|
domain: hostName,
|
|
38219
38219
|
roles: roles
|
|
38220
38220
|
});
|
|
38221
|
-
amplitude.
|
|
38221
|
+
amplitude.setSessionId(-1);
|
|
38222
38222
|
}
|
|
38223
38223
|
|
|
38224
38224
|
localStorage.removeItem(ACCESS_TOKEN);
|
|
@@ -38729,13 +38729,12 @@ var getCookieValue = function getCookieValue(name) {
|
|
|
38729
38729
|
return ((_document$cookie$matc = document.cookie.match('(^|;)\\s*' + name + '\\s*=\\s*([^;]+)')) === null || _document$cookie$matc === void 0 ? void 0 : _document$cookie$matc.pop()) || '';
|
|
38730
38730
|
};
|
|
38731
38731
|
|
|
38732
|
-
var _sessionStorage$getIt;
|
|
38733
38732
|
var defaultInfo$1 = {
|
|
38734
38733
|
email: "",
|
|
38735
38734
|
password: "",
|
|
38736
38735
|
captcha: "",
|
|
38737
38736
|
rememberMe: false,
|
|
38738
|
-
isSessionUserBrowser:
|
|
38737
|
+
isSessionUserBrowser: !!sessionStorage.getItem(IS_USER_SESSION_BROWSER)
|
|
38739
38738
|
};
|
|
38740
38739
|
var HOMEPAGE_TEACHER = "/home";
|
|
38741
38740
|
var HOMEPAGE_STUDENT = "/home";
|
|
@@ -38969,17 +38968,14 @@ var useLogin = function useLogin() {
|
|
|
38969
38968
|
if (data !== null && data !== void 0 && data.email && !roles.includes("Admin")) {
|
|
38970
38969
|
var _data$roles;
|
|
38971
38970
|
|
|
38972
|
-
amplitude.
|
|
38973
|
-
|
|
38974
|
-
includeUtm: false,
|
|
38975
|
-
includeGclid: false,
|
|
38976
|
-
includeFbclid: false
|
|
38971
|
+
amplitude.init(!isLocalhost ? INIT_AMPLITUDE_KEY_PROD : INIT_AMPLITUDE_KEY_STAGE, data.email, {
|
|
38972
|
+
defaultTracking: false
|
|
38977
38973
|
});
|
|
38978
38974
|
var hostName = window.location.hostname;
|
|
38979
|
-
amplitude.
|
|
38980
|
-
|
|
38981
|
-
|
|
38982
|
-
amplitude.
|
|
38975
|
+
var identify = new amplitude.Identify();
|
|
38976
|
+
identify.set("domain", hostName);
|
|
38977
|
+
amplitude.identify(identify);
|
|
38978
|
+
amplitude.track("general: session start", {
|
|
38983
38979
|
user_id: data.email,
|
|
38984
38980
|
domain: hostName,
|
|
38985
38981
|
roles: data === null || data === void 0 ? void 0 : (_data$roles = data.roles) === null || _data$roles === void 0 ? void 0 : _data$roles.toString()
|
|
@@ -38989,7 +38985,7 @@ var useLogin = function useLogin() {
|
|
|
38989
38985
|
if (isLoginFirst) {
|
|
38990
38986
|
var _data$roles2;
|
|
38991
38987
|
|
|
38992
|
-
amplitude.
|
|
38988
|
+
amplitude.track("general: first login", {
|
|
38993
38989
|
user_id: data.email,
|
|
38994
38990
|
domain: hostName,
|
|
38995
38991
|
roles: data === null || data === void 0 ? void 0 : (_data$roles2 = data.roles) === null || _data$roles2 === void 0 ? void 0 : _data$roles2.toString()
|
|
@@ -49215,8 +49211,6 @@ var generateRandomString = (function () {
|
|
|
49215
49211
|
return (Math.random() + 1).toString(36).substring(7);
|
|
49216
49212
|
});
|
|
49217
49213
|
|
|
49218
|
-
var amplitudeClient = amplitude.getInstance();
|
|
49219
|
-
|
|
49220
49214
|
var apiGetLanguage = function apiGetLanguage() {
|
|
49221
49215
|
return api.get(BASE_URL + "/api/language");
|
|
49222
49216
|
};
|
|
@@ -49621,7 +49615,7 @@ var TheLayout = function TheLayout(_ref) {
|
|
|
49621
49615
|
}));
|
|
49622
49616
|
};
|
|
49623
49617
|
|
|
49624
|
-
var amplitudeClient
|
|
49618
|
+
var amplitudeClient = amplitude;
|
|
49625
49619
|
|
|
49626
49620
|
Object.defineProperty(exports, 'I18nextProvider', {
|
|
49627
49621
|
enumerable: true,
|
|
@@ -49710,7 +49704,7 @@ exports.UserContainer = UserContainer;
|
|
|
49710
49704
|
exports.UserDetail = UserDetail;
|
|
49711
49705
|
exports.UserList = UserList;
|
|
49712
49706
|
exports.addTab = addTab;
|
|
49713
|
-
exports.amplitudeClient = amplitudeClient
|
|
49707
|
+
exports.amplitudeClient = amplitudeClient;
|
|
49714
49708
|
exports.answerQuestion = answerQuestion;
|
|
49715
49709
|
exports.answerQuestionDataPlayer = answerQuestionDataPlayer;
|
|
49716
49710
|
exports.api = api;
|