mario-core 2.9.32-beta → 2.9.34-beta

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.
@@ -242,6 +242,7 @@ var reset = createAction("common/reset");
242
242
  var showMenuBar = createAction("common/showMenuBar");
243
243
  var showFontSize = createAction("common/showFontSize");
244
244
  var setEnableIEP = createAction("common/setEnableIEP");
245
+ var setEnableSurvey = createAction("common/setEnableSurvey");
245
246
  var setConversationOneToOne = createAction("common/setConversationOneToOne");
246
247
  var setCurrentStudentId = createAction("common/setCurrentStudentId");
247
248
  var setCurrentStudentUserId = createAction("common/setCurrentStudentUserId");
@@ -301,6 +302,16 @@ var apiUpload = axios.create({
301
302
  Object.keys(localStorage).forEach(function (key) {
302
303
  if (!key.includes('learning-plan')) delete localStorage[key];
303
304
  });
305
+ var userEmail = localStorage.getItem("USER_EMAIL");
306
+
307
+ if (userEmail) {
308
+ amplitude.getInstance().logEvent("general: session end", {
309
+ user_id: userEmail
310
+ });
311
+ amplitude.getInstance().resetSessionId();
312
+ }
313
+
314
+ localStorage.setItem("USER_EMAIL", "");
304
315
  window.location.href = "/login";
305
316
  }
306
317
 
@@ -434,6 +445,7 @@ var useLogin = function useLogin() {
434
445
  amplitude.getInstance().logEvent("general: session start", {
435
446
  user_id: data.email
436
447
  });
448
+ localStorage.setItem("USER_EMAIL", data.email);
437
449
 
438
450
  if (isLoginFirst) {
439
451
  amplitude.getInstance().logEvent("general: first login", {
@@ -7115,6 +7127,7 @@ var initialState = {
7115
7127
  menuBar: true,
7116
7128
  defaultFontSize: 16,
7117
7129
  isEnableIEP: true,
7130
+ isEnableSurvey: false,
7118
7131
  isConversationOneToOne: false,
7119
7132
  amplitude: {
7120
7133
  user_id: "",
@@ -7158,6 +7171,8 @@ var commonReducer = createReducer(initialState, function (builder) {
7158
7171
  state.menuBar = action.payload;
7159
7172
  }).addCase(setEnableIEP, function (state, action) {
7160
7173
  state.isEnableIEP = action.payload;
7174
+ }).addCase(setEnableSurvey, function (state, action) {
7175
+ state.isEnableSurvey = action.payload;
7161
7176
  }).addCase(setConversationOneToOne, function (state, action) {
7162
7177
  state.isConversationOneToOne = action.payload;
7163
7178
  }).addCase(showFontSize, function (state, action) {
@@ -8091,5 +8106,5 @@ var generateRandomString = (function () {
8091
8106
 
8092
8107
  var amplitudeClient = amplitude.getInstance();
8093
8108
 
8094
- export { ACCESS_TOKEN, ANSWER_EDITOR_HEIGHT, AcademicClassSelector, AddButton, BASE_URL, CHAT_CHANNEL, CommonAlert, CommonHeader, CommonModal$1 as CommonModal, CreatableSelector, CustomPagination, CustomSelector, CustomTabs as CustomTab, DATE_FORMAT, DATE_RESULT, DEFAULT_FILTER, Dashboard, DeleteButtonIcon, DetailActionButtons, EMOTIONS, EditButtonIcon, EmailTemplateDetail, EmailTemplateList, EmptyDataAlert, ErrorHandler, FULL_DATE_RESULT, FaqList, InputFile as FileInput, GOOGLE_RECAPTCHA_KEY, GalleryList, INIT_AMPLITUDE_KEY, Images, LICENSE_AGGRID, LinkEditButton, Loading, Login, MediaList, NOTIFICATION_CHANNEL, NotFound, NotificationList, NotificationModal, QUESTION_TYPES, QUESTION_TYPES_OPTIONS, QuestionCategorySelector, QuestionTypeSelector, QuitPrompt, ReactNotification, RequiredLabel$1 as RequiredLabel, SchoolList, ScrollToTop, SearchBox$1 as SearchBox, SearchBoxContainer, SkillList, StarRatingSelector, SuggestionCategorySelector, TAB_COLORS, TINY_MCE_API_KEY, TheContent$1 as TheContent, TheLayout, ToggleButton, UploadFileButton, UserDetail, UserList, addTab, amplitudeClient, answerQuestion, answerQuestionDataPlayer, api, apiUpload, canAccess as canAccessRoute, changeNote, changeTags, clearTab, closeTab, debounce, editTab, editorConfig, firstCheckToken, generateRandomString, getFileUrl, getInfo, getTextFromHTML, initAmplitude, isInViewport, reset, setAlert, setAssessmentList, setAssignmentList, setAssistantList, setBadgeList, setBandScoreList, setCertificateList, setClassList, setConferenceRubricList, setConversationOneToOne, setCurrentStudentId, setCurrentStudentName, setCurrentStudentUserId, setCustomAlertList, setDataPlayer, setEditItemQuesion, setEnableIEP, setFeedbackList, setFilterWidget, setGoalExampleList, setImproveMyClass, setLearningSupportCategoryList, setLoading, setMailCategory, setModal, setMoveItemQuestion, setMyStudent, setQuestionByCategory, setQuestionCateList, setQuestionList, setReflectionList, setReflectionResultList, setResetQuestionList, setSchoolBlankDayList, setSelectQuestion, setSemesterList, setSessionPlayer, setSessionTemplateGeneralClassList, setSessionTemplateList, setStartTime, setStrategyList, setStudentIdSelectedByTeacher, setStudentList, setSubjectList, setSuggestionList, setTurnOffPassWhenChangeMode, setTutorialScreenList, setUser, setUserList, showFontSize, showMenuBar, store, systemCertificateUpload, systemStudentBadge, uploadFile, useFilters, useGalleryList, utcToLocalTime };
8109
+ export { ACCESS_TOKEN, ANSWER_EDITOR_HEIGHT, AcademicClassSelector, AddButton, BASE_URL, CHAT_CHANNEL, CommonAlert, CommonHeader, CommonModal$1 as CommonModal, CreatableSelector, CustomPagination, CustomSelector, CustomTabs as CustomTab, DATE_FORMAT, DATE_RESULT, DEFAULT_FILTER, Dashboard, DeleteButtonIcon, DetailActionButtons, EMOTIONS, EditButtonIcon, EmailTemplateDetail, EmailTemplateList, EmptyDataAlert, ErrorHandler, FULL_DATE_RESULT, FaqList, InputFile as FileInput, GOOGLE_RECAPTCHA_KEY, GalleryList, INIT_AMPLITUDE_KEY, Images, LICENSE_AGGRID, LinkEditButton, Loading, Login, MediaList, NOTIFICATION_CHANNEL, NotFound, NotificationList, NotificationModal, QUESTION_TYPES, QUESTION_TYPES_OPTIONS, QuestionCategorySelector, QuestionTypeSelector, QuitPrompt, ReactNotification, RequiredLabel$1 as RequiredLabel, SchoolList, ScrollToTop, SearchBox$1 as SearchBox, SearchBoxContainer, SkillList, StarRatingSelector, SuggestionCategorySelector, TAB_COLORS, TINY_MCE_API_KEY, TheContent$1 as TheContent, TheLayout, ToggleButton, UploadFileButton, UserDetail, UserList, addTab, amplitudeClient, answerQuestion, answerQuestionDataPlayer, api, apiUpload, canAccess as canAccessRoute, changeNote, changeTags, clearTab, closeTab, debounce, editTab, editorConfig, firstCheckToken, generateRandomString, getFileUrl, getInfo, getTextFromHTML, initAmplitude, isInViewport, reset, setAlert, setAssessmentList, setAssignmentList, setAssistantList, setBadgeList, setBandScoreList, setCertificateList, setClassList, setConferenceRubricList, setConversationOneToOne, setCurrentStudentId, setCurrentStudentName, setCurrentStudentUserId, setCustomAlertList, setDataPlayer, setEditItemQuesion, setEnableIEP, setEnableSurvey, setFeedbackList, setFilterWidget, setGoalExampleList, setImproveMyClass, setLearningSupportCategoryList, setLoading, setMailCategory, setModal, setMoveItemQuestion, setMyStudent, setQuestionByCategory, setQuestionCateList, setQuestionList, setReflectionList, setReflectionResultList, setResetQuestionList, setSchoolBlankDayList, setSelectQuestion, setSemesterList, setSessionPlayer, setSessionTemplateGeneralClassList, setSessionTemplateList, setStartTime, setStrategyList, setStudentIdSelectedByTeacher, setStudentList, setSubjectList, setSuggestionList, setTurnOffPassWhenChangeMode, setTutorialScreenList, setUser, setUserList, showFontSize, showMenuBar, store, systemCertificateUpload, systemStudentBadge, uploadFile, useFilters, useGalleryList, utcToLocalTime };
8095
8110
  //# sourceMappingURL=index.modern.js.map