touchstudy-core 0.1.176 → 0.1.178
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/containers/Classes/components/TeacherSelector.d.ts +1 -1
- package/dist/containers/Classes/configs/types.d.ts +4 -0
- package/dist/containers/Notes/components/NoteItemList.d.ts +1 -0
- package/dist/containers/Notes/views/NoteList.d.ts +1 -0
- package/dist/containers/Notes/views/NoteTabs.d.ts +1 -0
- package/dist/index.js +103 -54
- package/dist/index.js.map +1 -1
- package/dist/index.modern.js +103 -54
- package/dist/index.modern.js.map +1 -1
- package/package.json +1 -1
package/dist/index.modern.js
CHANGED
@@ -6062,6 +6062,7 @@ var customStyles = {
|
|
6062
6062
|
|
6063
6063
|
var _excluded = ["isDefault", "defaultValue", "options", "isDisabled", "scrollBottom", "value", "isMulti"];
|
6064
6064
|
var CustomAsyncSelect = function CustomAsyncSelect(_ref) {
|
6065
|
+
var _value$;
|
6065
6066
|
var isDefault = _ref.isDefault,
|
6066
6067
|
options = _ref.options,
|
6067
6068
|
isDisabled = _ref.isDisabled,
|
@@ -6069,7 +6070,8 @@ var CustomAsyncSelect = function CustomAsyncSelect(_ref) {
|
|
6069
6070
|
value = _ref.value,
|
6070
6071
|
isMulti = _ref.isMulti,
|
6071
6072
|
rest = _objectWithoutPropertiesLoose(_ref, _excluded);
|
6072
|
-
var
|
6073
|
+
var isOptionValue = (value === null || value === void 0 ? void 0 : value.value) || (value === null || value === void 0 ? void 0 : (_value$ = value[0]) === null || _value$ === void 0 ? void 0 : _value$.value);
|
6074
|
+
var initialValues = isOptionValue ? value : Array.isArray(value) ? options.filter(function (i) {
|
6073
6075
|
return value.includes(i.value);
|
6074
6076
|
}) : isMulti ? options.filter(function (i) {
|
6075
6077
|
return i.value == value;
|
@@ -13225,7 +13227,7 @@ var DefaultLessonFilter = {
|
|
13225
13227
|
};
|
13226
13228
|
var DefaultTeacherFilter = {
|
13227
13229
|
currentPage: 1,
|
13228
|
-
pageSize:
|
13230
|
+
pageSize: 100,
|
13229
13231
|
sortColumnDirection: OrderBy$2.DESC,
|
13230
13232
|
sortColumnName: TeacherSortBy.Name,
|
13231
13233
|
textSearch: ""
|
@@ -13381,16 +13383,18 @@ var DEFAULT_USER_FILTERS = {
|
|
13381
13383
|
|
13382
13384
|
var styles$3 = {"avatar":"_2rJkZ","date-picker":"_1iqE2","time-picker":"_20xtc","teacher-selector-wrapper":"_3L1Oj"};
|
13383
13385
|
|
13386
|
+
var _excluded$7 = ["teachers", "value"];
|
13384
13387
|
var TeacherSelector = function TeacherSelector(_ref) {
|
13385
13388
|
var teachers = _ref.teachers,
|
13386
|
-
value = _ref.value
|
13389
|
+
value = _ref.value,
|
13390
|
+
rest = _objectWithoutPropertiesLoose(_ref, _excluded$7);
|
13387
13391
|
var teacherOptions = teachers.map(function (i) {
|
13388
13392
|
return {
|
13389
13393
|
label: i.teacherName + "/" + i.teacherEmail,
|
13390
13394
|
value: i.id
|
13391
13395
|
};
|
13392
13396
|
});
|
13393
|
-
return React__default.createElement(CustomAsyncSelect, {
|
13397
|
+
return React__default.createElement(CustomAsyncSelect, Object.assign({
|
13394
13398
|
options: teacherOptions,
|
13395
13399
|
value: value,
|
13396
13400
|
menuPlacement: "bottom",
|
@@ -13403,7 +13407,7 @@ var TeacherSelector = function TeacherSelector(_ref) {
|
|
13403
13407
|
},
|
13404
13408
|
menuPortalTarget: document.body,
|
13405
13409
|
isClearable: true
|
13406
|
-
});
|
13410
|
+
}, rest));
|
13407
13411
|
};
|
13408
13412
|
|
13409
13413
|
var ErrorHandler = function ErrorHandler(_ref) {
|
@@ -13488,6 +13492,7 @@ var ClassForm = function ClassForm(_ref) {
|
|
13488
13492
|
};
|
13489
13493
|
var handleChangeTeacher = function handleChangeTeacher(val) {
|
13490
13494
|
formikProp.setFieldValue("mainTeacherId", val === null || val === void 0 ? void 0 : val.value);
|
13495
|
+
formikProp.setFieldValue("mainTeacher", val);
|
13491
13496
|
};
|
13492
13497
|
var handleChangeWeeklyDayTime = function handleChangeWeeklyDayTime(key, newValue, currentValue) {
|
13493
13498
|
var _extends2;
|
@@ -13653,7 +13658,7 @@ var ClassForm = function ClassForm(_ref) {
|
|
13653
13658
|
}, "*")), React__default.createElement("div", {
|
13654
13659
|
className: "" + styles$3["teacher-selector-wrapper"]
|
13655
13660
|
}, React__default.createElement(TeacherSelector, {
|
13656
|
-
value: formikProp.values.
|
13661
|
+
value: formikProp.values.mainTeacher,
|
13657
13662
|
teachers: teachers,
|
13658
13663
|
onInputChange: onSearchTeachers,
|
13659
13664
|
onChange: handleChangeTeacher,
|
@@ -16043,14 +16048,15 @@ var getNoteType = function getNoteType(t, type) {
|
|
16043
16048
|
};
|
16044
16049
|
|
16045
16050
|
var NoteItemList = function NoteItemList(_ref) {
|
16046
|
-
var _data$reciever, _data$
|
16051
|
+
var _data$reciever, _data$recievers;
|
16047
16052
|
var data = _ref.data,
|
16048
16053
|
index = _ref.index,
|
16049
16054
|
role = _ref.role,
|
16050
16055
|
calcOrderNumber = _ref.calcOrderNumber,
|
16051
16056
|
onDelete = _ref.onDelete,
|
16052
16057
|
onUpdate = _ref.onUpdate,
|
16053
|
-
onView = _ref.onView
|
16058
|
+
onView = _ref.onView,
|
16059
|
+
onViewStudentInfo = _ref.onViewStudentInfo;
|
16054
16060
|
var isAdminUser = useSelector(function (state) {
|
16055
16061
|
var _state$common, _state$common$user, _state$common$user$ro;
|
16056
16062
|
return state === null || state === void 0 ? void 0 : (_state$common = state.common) === null || _state$common === void 0 ? void 0 : (_state$common$user = _state$common.user) === null || _state$common$user === void 0 ? void 0 : (_state$common$user$ro = _state$common$user.roles) === null || _state$common$user$ro === void 0 ? void 0 : _state$common$user$ro.includes(Role.Admin);
|
@@ -16073,6 +16079,9 @@ var NoteItemList = function NoteItemList(_ref) {
|
|
16073
16079
|
var handleView = function handleView() {
|
16074
16080
|
onView(data);
|
16075
16081
|
};
|
16082
|
+
var handleViewStudentInfo = function handleViewStudentInfo() {
|
16083
|
+
onViewStudentInfo(data);
|
16084
|
+
};
|
16076
16085
|
var disabled = !data.isOwned && (!isAdminUser || data.type == undefined || data.type == NoteType.TeacherToAllAdmin || data.type == NoteType.TeacherToTeachers);
|
16077
16086
|
var cleanedRichText = useMemo(function () {
|
16078
16087
|
return cleanRichText(data.content);
|
@@ -16094,10 +16103,15 @@ var NoteItemList = function NoteItemList(_ref) {
|
|
16094
16103
|
display: "inline-block",
|
16095
16104
|
color: grey$1[600],
|
16096
16105
|
fontWeight: 600
|
16097
|
-
}, "(", " " + t("me"), ")")), React__default.createElement(Typography, null, data.sender.email))), data.type === NoteType.ToAcademy || data.type === NoteType.ToStudent ? React__default.createElement(TableCell$1, null, React__default.createElement(
|
16098
|
-
|
16099
|
-
|
16100
|
-
|
16106
|
+
}, "(", " " + t("me"), ")")), React__default.createElement(Typography, null, data.sender.email))), data.type === NoteType.ToAcademy || data.type === NoteType.ToStudent ? React__default.createElement(TableCell$1, null, React__default.createElement(Button, {
|
16107
|
+
variant: "text",
|
16108
|
+
color: "success",
|
16109
|
+
sx: {
|
16110
|
+
color: blue[700],
|
16111
|
+
fontWeight: 600
|
16112
|
+
},
|
16113
|
+
onClick: handleViewStudentInfo
|
16114
|
+
}, (_data$reciever = data.reciever) === null || _data$reciever === void 0 ? void 0 : _data$reciever.fullName)) : data.type === NoteType.TeacherToTeachers ? React__default.createElement(TableCell$1, null, React__default.createElement(Stack, {
|
16101
16115
|
direction: "column"
|
16102
16116
|
}, (_data$recievers = data.recievers) === null || _data$recievers === void 0 ? void 0 : _data$recievers.slice(0, 2).map(function (i) {
|
16103
16117
|
return React__default.createElement(Typography, null, i.fullName, " - ", i.email);
|
@@ -16735,10 +16749,12 @@ var GeneralNoteDialog = function GeneralNoteDialog(_ref) {
|
|
16735
16749
|
};
|
16736
16750
|
|
16737
16751
|
var NoteList = function NoteList(_ref) {
|
16752
|
+
var _selectedStudentNote$;
|
16738
16753
|
var defaultFilter = _ref.defaultFilter,
|
16739
16754
|
role = _ref.role,
|
16740
16755
|
headers = _ref.headers,
|
16741
|
-
isAdmin = _ref.isAdmin
|
16756
|
+
isAdmin = _ref.isAdmin,
|
16757
|
+
onViewQA = _ref.onViewQA;
|
16742
16758
|
var _useTranslation = useTranslation(),
|
16743
16759
|
t = _useTranslation.t;
|
16744
16760
|
var _useList = useList(function (filter) {
|
@@ -16772,6 +16788,16 @@ var NoteList = function NoteList(_ref) {
|
|
16772
16788
|
var _useState5 = useState(false),
|
16773
16789
|
openDeleteNoteDialog = _useState5[0],
|
16774
16790
|
setOpenDeleteNoteDialog = _useState5[1];
|
16791
|
+
var _useState6 = useState(),
|
16792
|
+
selectedStudentNote = _useState6[0],
|
16793
|
+
setSelectedStudentNote = _useState6[1];
|
16794
|
+
var handleChangeSelectedStudentNote = function handleChangeSelectedStudentNote(note) {
|
16795
|
+
if (note.type !== NoteType.ToAcademy && note.type !== NoteType.ToStudent) return;
|
16796
|
+
setSelectedStudentNote(note);
|
16797
|
+
};
|
16798
|
+
var handleCloseStudentInfo = function handleCloseStudentInfo() {
|
16799
|
+
setSelectedStudentNote(undefined);
|
16800
|
+
};
|
16775
16801
|
var handleOpenCreateNoteDialog = function handleOpenCreateNoteDialog() {
|
16776
16802
|
var _defaultFilter$types;
|
16777
16803
|
if (((_defaultFilter$types = defaultFilter.types) === null || _defaultFilter$types === void 0 ? void 0 : _defaultFilter$types.length) === 1) setOpenNoteDialog(defaultFilter.types[0]);else if (defaultFilter.types && defaultFilter.types.length > 1) {
|
@@ -16925,7 +16951,8 @@ var NoteList = function NoteList(_ref) {
|
|
16925
16951
|
role: role,
|
16926
16952
|
onDelete: handleOpenDeleteNoteDialog,
|
16927
16953
|
onUpdate: handleOpenNoteDialog,
|
16928
|
-
onView: handleOpenNoteDrawer
|
16954
|
+
onView: handleOpenNoteDrawer,
|
16955
|
+
onViewStudentInfo: handleChangeSelectedStudentNote
|
16929
16956
|
});
|
16930
16957
|
}
|
16931
16958
|
}), !data.length && !isLoading && React__default.createElement(TableRow, null, React__default.createElement(TableCell, {
|
@@ -16973,6 +17000,16 @@ var NoteList = function NoteList(_ref) {
|
|
16973
17000
|
title: t("delete_note"),
|
16974
17001
|
okText: t("delete_note"),
|
16975
17002
|
cancelText: t("cancel")
|
17003
|
+
}), React__default.createElement(StudentInfoDrawer, {
|
17004
|
+
role: role,
|
17005
|
+
open: !!selectedStudentNote,
|
17006
|
+
studentId: (selectedStudentNote === null || selectedStudentNote === void 0 ? void 0 : (_selectedStudentNote$ = selectedStudentNote.reciever) === null || _selectedStudentNote$ === void 0 ? void 0 : _selectedStudentNote$.id) || 0,
|
17007
|
+
onClose: handleCloseStudentInfo,
|
17008
|
+
anchor: "right",
|
17009
|
+
width: "80dvw",
|
17010
|
+
history: history,
|
17011
|
+
inert: true,
|
17012
|
+
onViewQA: onViewQA
|
16976
17013
|
}));
|
16977
17014
|
};
|
16978
17015
|
|
@@ -17081,7 +17118,8 @@ var TEACHER_NOTE_FILTER = {
|
|
17081
17118
|
};
|
17082
17119
|
|
17083
17120
|
var NoteTabs = function NoteTabs(_ref) {
|
17084
|
-
var role = _ref.role
|
17121
|
+
var role = _ref.role,
|
17122
|
+
onViewQA = _ref.onViewQA;
|
17085
17123
|
var roles = useSelector(function (state) {
|
17086
17124
|
var _state$common$user$ro, _state$common, _state$common$user;
|
17087
17125
|
return (_state$common$user$ro = state === null || state === void 0 ? void 0 : (_state$common = state.common) === null || _state$common === void 0 ? void 0 : (_state$common$user = _state$common.user) === null || _state$common$user === void 0 ? void 0 : _state$common$user.roles) != null ? _state$common$user$ro : [];
|
@@ -17128,7 +17166,8 @@ var NoteTabs = function NoteTabs(_ref) {
|
|
17128
17166
|
role: role,
|
17129
17167
|
isAdmin: isAdmin,
|
17130
17168
|
defaultFilter: ACADEMY_NOTE_FILTER,
|
17131
|
-
headers: NOTE_STUDENT_HEADERS
|
17169
|
+
headers: NOTE_STUDENT_HEADERS,
|
17170
|
+
onViewQA: onViewQA
|
17132
17171
|
})), React__default.createElement(NotetabPanel, {
|
17133
17172
|
value: value,
|
17134
17173
|
index: 1
|
@@ -17136,7 +17175,8 @@ var NoteTabs = function NoteTabs(_ref) {
|
|
17136
17175
|
role: role,
|
17137
17176
|
isAdmin: isAdmin,
|
17138
17177
|
defaultFilter: STUDENT_PARENTS_NOTE_FILTER,
|
17139
|
-
headers: NOTE_STUDENT_HEADERS
|
17178
|
+
headers: NOTE_STUDENT_HEADERS,
|
17179
|
+
onViewQA: onViewQA
|
17140
17180
|
})), React__default.createElement(NotetabPanel, {
|
17141
17181
|
value: value,
|
17142
17182
|
index: 2
|
@@ -20371,12 +20411,12 @@ function CreateNewQuestionDialog(_ref) {
|
|
20371
20411
|
});
|
20372
20412
|
}
|
20373
20413
|
|
20374
|
-
var _excluded$
|
20414
|
+
var _excluded$8 = ["children", "value", "index"];
|
20375
20415
|
var CustomTabPanel = function CustomTabPanel(props) {
|
20376
20416
|
var children = props.children,
|
20377
20417
|
value = props.value,
|
20378
20418
|
index = props.index,
|
20379
|
-
other = _objectWithoutPropertiesLoose(props, _excluded$
|
20419
|
+
other = _objectWithoutPropertiesLoose(props, _excluded$8);
|
20380
20420
|
return React__default.createElement("div", Object.assign({
|
20381
20421
|
role: "tabpanel",
|
20382
20422
|
hidden: value !== index,
|
@@ -24433,7 +24473,7 @@ var ChapterProblemSolvingResultsDialog = function ChapterProblemSolvingResultsDi
|
|
24433
24473
|
}, t("cancel"))))));
|
24434
24474
|
};
|
24435
24475
|
|
24436
|
-
var _excluded$
|
24476
|
+
var _excluded$9 = ["onChange"];
|
24437
24477
|
var StartPageDialog = function StartPageDialog(_ref) {
|
24438
24478
|
var t = _ref.t,
|
24439
24479
|
onClose = _ref.onClose,
|
@@ -24499,7 +24539,7 @@ var StartPageDialog = function StartPageDialog(_ref) {
|
|
24499
24539
|
}, t("page_to_start_with")), React__default.createElement(Field, {
|
24500
24540
|
name: "startPage",
|
24501
24541
|
render: function render(_ref3) {
|
24502
|
-
var field = _objectWithoutPropertiesLoose(_ref3, _excluded$
|
24542
|
+
var field = _objectWithoutPropertiesLoose(_ref3, _excluded$9);
|
24503
24543
|
return React__default.createElement(CustomSelectOption, Object.assign({
|
24504
24544
|
maxMenuHeight: 150,
|
24505
24545
|
menuPosition: "fixed",
|
@@ -26131,10 +26171,10 @@ var DrawerTextbookResultTab = function DrawerTextbookResultTab(_ref) {
|
|
26131
26171
|
};
|
26132
26172
|
|
26133
26173
|
var _styled$1;
|
26134
|
-
var _excluded$
|
26174
|
+
var _excluded$a = ["className"];
|
26135
26175
|
var CustomTooltip$1 = styled(function (_ref) {
|
26136
26176
|
var className = _ref.className,
|
26137
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
26177
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$a);
|
26138
26178
|
return React__default.createElement(Tooltip, Object.assign({}, props, {
|
26139
26179
|
classes: {
|
26140
26180
|
popper: className
|
@@ -27615,7 +27655,7 @@ var useTeacherList = function useTeacherList() {
|
|
27615
27655
|
};
|
27616
27656
|
};
|
27617
27657
|
|
27618
|
-
var _excluded$
|
27658
|
+
var _excluded$b = ["getStudents"],
|
27619
27659
|
_excluded2 = ["getTeachers"],
|
27620
27660
|
_excluded3 = ["getLessons"];
|
27621
27661
|
var PAGE_TITLE$4 = "classes";
|
@@ -27666,7 +27706,7 @@ var useClassDetail = function useClassDetail(_ref) {
|
|
27666
27706
|
};
|
27667
27707
|
var _useStudentClassList = useStudentClassList(classId),
|
27668
27708
|
getStudents = _useStudentClassList.getStudents,
|
27669
|
-
studentListProps = _objectWithoutPropertiesLoose(_useStudentClassList, _excluded$
|
27709
|
+
studentListProps = _objectWithoutPropertiesLoose(_useStudentClassList, _excluded$b);
|
27670
27710
|
var _useTeacherClassList = useTeacherClassList(classId),
|
27671
27711
|
getTeachers = _useTeacherClassList.getTeachers,
|
27672
27712
|
teacherListProps = _objectWithoutPropertiesLoose(_useTeacherClassList, _excluded2);
|
@@ -27726,7 +27766,11 @@ var useClassDetail = function useClassDetail(_ref) {
|
|
27726
27766
|
startTime: timeSpanToLocalMoment(i.startTime, course.startDate),
|
27727
27767
|
endTime: timeSpanToLocalMoment(i.endTime, course.startDate)
|
27728
27768
|
});
|
27729
|
-
})
|
27769
|
+
}),
|
27770
|
+
mainTeacher: course.mainTeacherId ? {
|
27771
|
+
label: course.mainTeacherName + "/" + course.mainTeacherEmail,
|
27772
|
+
value: course.mainTeacherId
|
27773
|
+
} : null
|
27730
27774
|
});
|
27731
27775
|
}, [JSON.stringify(course)]);
|
27732
27776
|
var convertToRequestBody = function convertToRequestBody(request) {
|
@@ -28112,6 +28156,7 @@ var LessonFormBody = function LessonFormBody(_ref) {
|
|
28112
28156
|
setOpenPicker = _useState[1];
|
28113
28157
|
var handleChangeTeacher = function handleChangeTeacher(val) {
|
28114
28158
|
formikProp.setFieldValue("mainTeacherId", val === null || val === void 0 ? void 0 : val.value);
|
28159
|
+
formikProp.setFieldValue("mainTeacher", val);
|
28115
28160
|
};
|
28116
28161
|
useEffect(function () {
|
28117
28162
|
if (open && data) formikProp.setValues(data);else formikProp.setValues(DEFAULT_LESSON_REQUEST);
|
@@ -28155,7 +28200,7 @@ var LessonFormBody = function LessonFormBody(_ref) {
|
|
28155
28200
|
}, "*")), React__default.createElement("div", {
|
28156
28201
|
className: "" + styles$3["teacher-selector-wrapper"]
|
28157
28202
|
}, React__default.createElement(TeacherSelector, {
|
28158
|
-
value: formikProp.values.
|
28203
|
+
value: formikProp.values.mainTeacher,
|
28159
28204
|
teachers: teachers,
|
28160
28205
|
onInputChange: onSearchTeachers,
|
28161
28206
|
onChange: handleChangeTeacher
|
@@ -28263,7 +28308,11 @@ var LessonFormDialog = function LessonFormDialog(_ref) {
|
|
28263
28308
|
return _extends({}, data, {
|
28264
28309
|
date: moment.utc(data.date).local(),
|
28265
28310
|
startTime: timeSpanToLocalMoment(data.startTime, data.date),
|
28266
|
-
endTime: timeSpanToLocalMoment(data.endTime, data.date)
|
28311
|
+
endTime: timeSpanToLocalMoment(data.endTime, data.date),
|
28312
|
+
mainTeacher: data.mainTeacherId ? {
|
28313
|
+
label: data.mainTeacherName + "/" + data.mainTeacherEmail,
|
28314
|
+
value: data.mainTeacherId
|
28315
|
+
} : null
|
28267
28316
|
});
|
28268
28317
|
};
|
28269
28318
|
var lessonRequest = useMemo(convertLessonRequest, [JSON.stringify(data)]);
|
@@ -29054,14 +29103,14 @@ var CSV_PREFIX = "data:text/csv;charset=utf-8,";
|
|
29054
29103
|
|
29055
29104
|
var styles$8 = {"action-btn":"_1jXbz","action-btn--pencil":"_at4xP","icon-rotate-180":"_12gv9","drop-area":"_R4bn5"};
|
29056
29105
|
|
29057
|
-
var _excluded$
|
29106
|
+
var _excluded$c = ["text", "isRequired", "className"];
|
29058
29107
|
var LabelRequired = function LabelRequired(_ref) {
|
29059
29108
|
var text = _ref.text,
|
29060
29109
|
_ref$isRequired = _ref.isRequired,
|
29061
29110
|
isRequired = _ref$isRequired === void 0 ? true : _ref$isRequired,
|
29062
29111
|
_ref$className = _ref.className,
|
29063
29112
|
className = _ref$className === void 0 ? "" : _ref$className,
|
29064
|
-
rest = _objectWithoutPropertiesLoose(_ref, _excluded$
|
29113
|
+
rest = _objectWithoutPropertiesLoose(_ref, _excluded$c);
|
29065
29114
|
return React__default.createElement(FormLabel, Object.assign({
|
29066
29115
|
className: "fw-medium mb-1 " + className
|
29067
29116
|
}, rest), text, isRequired && React__default.createElement("span", {
|
@@ -29115,7 +29164,7 @@ var deleteUserApi = function deleteUserApi(id) {
|
|
29115
29164
|
return api["delete"](USER_URL$1 + "/delete/" + id);
|
29116
29165
|
};
|
29117
29166
|
|
29118
|
-
var _excluded$
|
29167
|
+
var _excluded$d = ["ref"],
|
29119
29168
|
_excluded2$1 = ["ref"],
|
29120
29169
|
_excluded3$1 = ["ref"],
|
29121
29170
|
_excluded4 = ["ref"],
|
@@ -29145,7 +29194,7 @@ var UserDialog = function UserDialog(_ref) {
|
|
29145
29194
|
t = _useTranslation.t;
|
29146
29195
|
var _register = register("fullName"),
|
29147
29196
|
fullNameRef = _register.ref,
|
29148
|
-
fullNameBio = _objectWithoutPropertiesLoose(_register, _excluded$
|
29197
|
+
fullNameBio = _objectWithoutPropertiesLoose(_register, _excluded$d);
|
29149
29198
|
var _register2 = register("email"),
|
29150
29199
|
emailRef = _register2.ref,
|
29151
29200
|
emailBio = _objectWithoutPropertiesLoose(_register2, _excluded2$1);
|
@@ -33216,12 +33265,12 @@ var ArticleDialog = function ArticleDialog(_ref) {
|
|
33216
33265
|
|
33217
33266
|
var styles$a = {"drawer":"_11aYm","open":"_3Ydwm","drawer-overlay":"_3SQDf","drawer-header":"_2BwOx","drawer-form":"_2Zo7R","dropdown-content-academy":"_1lzjD","dropdown-change":"_1y7K9","dropdown-academy-item":"_1Y-55","dropdown-content-language":"_1fBXY","dropdown-item-language":"_3Szun","dropdown-item-language-active":"_2HhLb","item-address":"_3WYHC","item-logout":"_2-9ix","title-address":"_1r4pn","image-academy":"_2ZozT"};
|
33218
33267
|
|
33219
|
-
var _excluded$
|
33268
|
+
var _excluded$e = ["isOpen", "onClose", "handleSaveExam"];
|
33220
33269
|
var CreateExamDrawer = function CreateExamDrawer(props) {
|
33221
33270
|
var isOpen = props.isOpen,
|
33222
33271
|
onClose = props.onClose,
|
33223
33272
|
handleSaveExam = props.handleSaveExam,
|
33224
|
-
examDetailViewProps = _objectWithoutPropertiesLoose(props, _excluded$
|
33273
|
+
examDetailViewProps = _objectWithoutPropertiesLoose(props, _excluded$e);
|
33225
33274
|
var _useTranslation = useTranslation(),
|
33226
33275
|
t = _useTranslation.t;
|
33227
33276
|
var theme = useTheme();
|
@@ -34374,12 +34423,12 @@ var useNotificationDetail = function useNotificationDetail(_ref) {
|
|
34374
34423
|
|
34375
34424
|
var styles$b = {"avatar":"_8niRT"};
|
34376
34425
|
|
34377
|
-
var _excluded$
|
34426
|
+
var _excluded$f = ["value", "disabled", "optionTypeNotification"];
|
34378
34427
|
var TypeSelector = function TypeSelector(_ref) {
|
34379
34428
|
var value = _ref.value,
|
34380
34429
|
disabled = _ref.disabled,
|
34381
34430
|
optionTypeNotification = _ref.optionTypeNotification,
|
34382
|
-
rest = _objectWithoutPropertiesLoose(_ref, _excluded$
|
34431
|
+
rest = _objectWithoutPropertiesLoose(_ref, _excluded$f);
|
34383
34432
|
return React__default.createElement(CustomAsyncSelect, Object.assign({
|
34384
34433
|
options: optionTypeNotification,
|
34385
34434
|
value: value
|
@@ -34772,11 +34821,11 @@ var useNotificationList = function useNotificationList(_ref) {
|
|
34772
34821
|
};
|
34773
34822
|
};
|
34774
34823
|
|
34775
|
-
var _excluded$
|
34824
|
+
var _excluded$g = ["value", "optionTypeNotification"];
|
34776
34825
|
var SelectFilterType = function SelectFilterType(_ref) {
|
34777
34826
|
var value = _ref.value,
|
34778
34827
|
optionTypeNotification = _ref.optionTypeNotification,
|
34779
|
-
rest = _objectWithoutPropertiesLoose(_ref, _excluded$
|
34828
|
+
rest = _objectWithoutPropertiesLoose(_ref, _excluded$g);
|
34780
34829
|
return React__default.createElement(CustomAsyncSelect, Object.assign({
|
34781
34830
|
options: optionTypeNotification,
|
34782
34831
|
value: value
|
@@ -36053,7 +36102,7 @@ var isEqual$1 = function isEqual(prev, next) {
|
|
36053
36102
|
};
|
36054
36103
|
var QuestionShortInput$1 = memo(QuestionShortInput, isEqual$1);
|
36055
36104
|
|
36056
|
-
var _excluded$
|
36105
|
+
var _excluded$h = ["onChange"];
|
36057
36106
|
var _$2 = _$8;
|
36058
36107
|
var BpIcon$1 = styled("span")(function (_ref) {
|
36059
36108
|
var theme = _ref.theme;
|
@@ -36364,7 +36413,7 @@ var QuestionBlock = function QuestionBlock(_ref2) {
|
|
36364
36413
|
name: path + ".questionTypeId",
|
36365
36414
|
render: function render(_ref5) {
|
36366
36415
|
var _ref5$field = _ref5.field,
|
36367
|
-
field = _objectWithoutPropertiesLoose(_ref5$field, _excluded$
|
36416
|
+
field = _objectWithoutPropertiesLoose(_ref5$field, _excluded$h);
|
36368
36417
|
return React__default.createElement(CustomSelectOption, Object.assign({}, field, {
|
36369
36418
|
isDisabled: disabled,
|
36370
36419
|
value: data.questionType,
|
@@ -36413,7 +36462,7 @@ var isEqual$2 = function isEqual(prev, next) {
|
|
36413
36462
|
};
|
36414
36463
|
var QuestionBlock$1 = memo(QuestionBlock, isEqual$2);
|
36415
36464
|
|
36416
|
-
var _excluded$
|
36465
|
+
var _excluded$i = ["data", "path", "isMath", "open", "isLoadingCategories", "isLoadingQuestionTypes", "optionKey", "categories", "questionTypes", "disabled", "onQuestioStartOrderChange", "onDelete", "onOpenSubCategoryMenu", "onOpenCategoryMenu", "onCloseCategoryMenu", "onCloseQuestionTypeMenu", "onOpenQuestionTypeMenu"];
|
36417
36466
|
var _$3 = _$8;
|
36418
36467
|
var QuestionGroupBlockBody = function QuestionGroupBlockBody(_ref) {
|
36419
36468
|
var _data$articles$3, _data$articles$3$cate, _data$articles$4, _data$articles$4$cate, _questions$2;
|
@@ -36434,7 +36483,7 @@ var QuestionGroupBlockBody = function QuestionGroupBlockBody(_ref) {
|
|
36434
36483
|
onCloseCategoryMenu = _ref.onCloseCategoryMenu,
|
36435
36484
|
onCloseQuestionTypeMenu = _ref.onCloseQuestionTypeMenu,
|
36436
36485
|
onOpenQuestionTypeMenu = _ref.onOpenQuestionTypeMenu,
|
36437
|
-
formikProps = _objectWithoutPropertiesLoose(_ref, _excluded$
|
36486
|
+
formikProps = _objectWithoutPropertiesLoose(_ref, _excluded$i);
|
36438
36487
|
var errors = formikProps.errors;
|
36439
36488
|
var startOrderRef = useRef(null);
|
36440
36489
|
var articles = data.articles,
|
@@ -36577,7 +36626,7 @@ var isEqual$3 = function isEqual(prev, next) {
|
|
36577
36626
|
};
|
36578
36627
|
var QuestionGroupBlockBody$1 = memo(QuestionGroupBlockBody, isEqual$3);
|
36579
36628
|
|
36580
|
-
var _excluded$
|
36629
|
+
var _excluded$j = ["expandedIndex", "open", "paths", "path", "isMath", "data", "categories", "isLoadingCategories", "isLoadingQuestionTypes", "questionTypes", "optionKey", "disabled", "onToggle", "onQuestionCountChange", "onDelete", "onOpenSubCategoryMenu", "onOpenCategoryMenu", "onCloseCategoryMenu", "onCopiedPrevQuestionGroup", "onCloseQuestionTypeMenu", "onOpenQuestionTypeMenu"];
|
36581
36630
|
var _$4 = _$8;
|
36582
36631
|
var QuestionGroupBlock = function QuestionGroupBlock(_ref) {
|
36583
36632
|
var _data$articles$3, _data$articles$3$cate, _data$articles$3$cate2, _data$articles$4, _data$articles$4$cate, _data$articles$4$cate2;
|
@@ -36602,7 +36651,7 @@ var QuestionGroupBlock = function QuestionGroupBlock(_ref) {
|
|
36602
36651
|
onCopiedPrevQuestionGroup = _ref.onCopiedPrevQuestionGroup,
|
36603
36652
|
onCloseQuestionTypeMenu = _ref.onCloseQuestionTypeMenu,
|
36604
36653
|
onOpenQuestionTypeMenu = _ref.onOpenQuestionTypeMenu,
|
36605
|
-
formikProps = _objectWithoutPropertiesLoose(_ref, _excluded$
|
36654
|
+
formikProps = _objectWithoutPropertiesLoose(_ref, _excluded$j);
|
36606
36655
|
var errors = formikProps.errors,
|
36607
36656
|
setFieldValue = formikProps.setFieldValue;
|
36608
36657
|
var _useTranslation = useTranslation(),
|
@@ -37065,7 +37114,7 @@ var QuestionGroupBlock = function QuestionGroupBlock(_ref) {
|
|
37065
37114
|
}, formikProps)))));
|
37066
37115
|
};
|
37067
37116
|
|
37068
|
-
var _excluded$
|
37117
|
+
var _excluded$k = ["path", "paths", "isMath", "isLoadingCategories", "isLoadingQuestionTypes", "optionKey", "questionGroups", "subChapters", "categories", "questionTypes", "disabled", "onDelete", "onOpenSubCategoryMenu", "onOpenCategoryMenu", "onCloseCategoryMenu", "onCopiedPrevQuestionGroup", "onCloseQuestionTypeMenu", "onOpenQuestionTypeMenu"];
|
37069
37118
|
var ChapterBlockBody = function ChapterBlockBody(_ref) {
|
37070
37119
|
var path = _ref.path,
|
37071
37120
|
paths = _ref.paths,
|
@@ -37085,7 +37134,7 @@ var ChapterBlockBody = function ChapterBlockBody(_ref) {
|
|
37085
37134
|
onCopiedPrevQuestionGroup = _ref.onCopiedPrevQuestionGroup,
|
37086
37135
|
onCloseQuestionTypeMenu = _ref.onCloseQuestionTypeMenu,
|
37087
37136
|
onOpenQuestionTypeMenu = _ref.onOpenQuestionTypeMenu,
|
37088
|
-
formikProps = _objectWithoutPropertiesLoose(_ref, _excluded$
|
37137
|
+
formikProps = _objectWithoutPropertiesLoose(_ref, _excluded$k);
|
37089
37138
|
var _useTranslation = useTranslation(),
|
37090
37139
|
t = _useTranslation.t;
|
37091
37140
|
var setFieldValue = formikProps.setFieldValue;
|
@@ -37264,7 +37313,7 @@ var ChapterBlockBody = function ChapterBlockBody(_ref) {
|
|
37264
37313
|
}));
|
37265
37314
|
};
|
37266
37315
|
|
37267
|
-
var _excluded$
|
37316
|
+
var _excluded$l = ["data", "expandedIndex", "open", "path", "paths", "isMath", "isLoadingCategories", "isLoadingQuestionTypes", "categories", "questionTypes", "optionKey", "disabled", "onToggle", "onDelete", "onCopiedPrevQuestionGroup", "onCloseCategoryMenu", "onOpenCategoryMenu", "onOpenSubCategoryMenu", "onOpenQuestionTypeMenu", "onCloseQuestionTypeMenu"];
|
37268
37317
|
var _$5 = _$8;
|
37269
37318
|
var ChapterBlock = function ChapterBlock(_ref) {
|
37270
37319
|
var data = _ref.data,
|
@@ -37287,7 +37336,7 @@ var ChapterBlock = function ChapterBlock(_ref) {
|
|
37287
37336
|
onOpenSubCategoryMenu = _ref.onOpenSubCategoryMenu,
|
37288
37337
|
onOpenQuestionTypeMenu = _ref.onOpenQuestionTypeMenu,
|
37289
37338
|
onCloseQuestionTypeMenu = _ref.onCloseQuestionTypeMenu,
|
37290
|
-
formikProps = _objectWithoutPropertiesLoose(_ref, _excluded$
|
37339
|
+
formikProps = _objectWithoutPropertiesLoose(_ref, _excluded$l);
|
37291
37340
|
var errors = formikProps.errors;
|
37292
37341
|
var _useTranslation = useTranslation(),
|
37293
37342
|
t = _useTranslation.t;
|
@@ -37978,7 +38027,7 @@ var TextbookContentsTab = function TextbookContentsTab(props) {
|
|
37978
38027
|
}));
|
37979
38028
|
};
|
37980
38029
|
|
37981
|
-
var _excluded$
|
38030
|
+
var _excluded$m = ["value"];
|
37982
38031
|
var VisuallyHiddenInput = styled("input")({
|
37983
38032
|
clip: "rect(0 0 0 0)",
|
37984
38033
|
clipPath: "inset(50%)",
|
@@ -38146,7 +38195,7 @@ var TextbookInfoTab = function TextbookInfoTab(_ref) {
|
|
38146
38195
|
render: function render(_ref4) {
|
38147
38196
|
var _ref4$field = _ref4.field,
|
38148
38197
|
value = _ref4$field.value,
|
38149
|
-
action = _objectWithoutPropertiesLoose(_ref4$field, _excluded$
|
38198
|
+
action = _objectWithoutPropertiesLoose(_ref4$field, _excluded$m);
|
38150
38199
|
return React__default.createElement(LocalizationProvider$1, {
|
38151
38200
|
dateAdapter: AdapterMoment
|
38152
38201
|
}, React__default.createElement(DatePicker$1, Object.assign({}, action, {
|
@@ -38620,7 +38669,7 @@ var TextbookOwnersTab = function TextbookOwnersTab(_ref) {
|
|
38620
38669
|
}));
|
38621
38670
|
};
|
38622
38671
|
|
38623
|
-
var _excluded$
|
38672
|
+
var _excluded$n = ["isCreatedByAdmin", "isSuperAdminUser", "isSuperAdmin", "isAdmin", "textbookId", "selected", "coverImage", "disabled", "ownersDisabled", "selectedTextbook", "handleSaveData", "onChangeTab", "onUploadImage"];
|
38624
38673
|
var PreparedTextbookForm = function PreparedTextbookForm(_ref) {
|
38625
38674
|
var _valuesTextbook$curre;
|
38626
38675
|
var isCreatedByAdmin = _ref.isCreatedByAdmin,
|
@@ -38636,7 +38685,7 @@ var PreparedTextbookForm = function PreparedTextbookForm(_ref) {
|
|
38636
38685
|
handleSaveData = _ref.handleSaveData,
|
38637
38686
|
onChangeTab = _ref.onChangeTab,
|
38638
38687
|
onUploadImage = _ref.onUploadImage,
|
38639
|
-
formikProps = _objectWithoutPropertiesLoose(_ref, _excluded$
|
38688
|
+
formikProps = _objectWithoutPropertiesLoose(_ref, _excluded$n);
|
38640
38689
|
var values = formikProps.values,
|
38641
38690
|
errors = formikProps.errors,
|
38642
38691
|
dirty = formikProps.dirty,
|
@@ -38859,7 +38908,7 @@ var PreparedTextbookForm = function PreparedTextbookForm(_ref) {
|
|
38859
38908
|
}, t$1("math"))))), React__default.createElement(Stack, {
|
38860
38909
|
flexDirection: "row",
|
38861
38910
|
gap: "8px"
|
38862
|
-
}, React__default.createElement(Stack, {
|
38911
|
+
}, !!(selectedTextbook !== null && selectedTextbook !== void 0 && selectedTextbook.id) && React__default.createElement(Stack, {
|
38863
38912
|
padding: "6px 12px",
|
38864
38913
|
sx: {
|
38865
38914
|
transition: "opacity 0.3s ease",
|
@@ -38894,7 +38943,7 @@ var PreparedTextbookForm = function PreparedTextbookForm(_ref) {
|
|
38894
38943
|
}
|
38895
38944
|
}
|
38896
38945
|
}
|
38897
|
-
}, saveStatus === PrintStatus.Saving && t$1("saving"), saveStatus === PrintStatus.Saved && isSaved && t$1("all_changes_saved"), saveStatus !== PrintStatus.Saving &&
|
38946
|
+
}, saveStatus === PrintStatus.Saving && t$1("saving"), saveStatus === PrintStatus.Saved && isSaved && t$1("all_changes_saved"), saveStatus !== PrintStatus.Saving && !isSaved && t$1("all_changes_are_not_saved_yet"))), React__default.createElement(Button, {
|
38898
38947
|
type: "submit",
|
38899
38948
|
sx: {
|
38900
38949
|
width: "fit-content"
|