mario-education 2.5.10-release → 2.5.12-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.
@@ -111,6 +111,7 @@ export declare type TotalCardItem = {
111
111
  value: number;
112
112
  lastMonthValue: number;
113
113
  totalStudent?: number;
114
+ percent?: number;
114
115
  };
115
116
  export interface IGeneralTip {
116
117
  id: number;
@@ -19,12 +19,14 @@ declare const useHome: () => {
19
19
  value: number;
20
20
  lastMonthValue: number;
21
21
  totalStudent: number;
22
+ percent: number;
22
23
  } | {
23
24
  id: string;
24
25
  title: string;
25
26
  value: number;
26
27
  lastMonthValue: number;
27
28
  totalStudent?: undefined;
29
+ percent?: undefined;
28
30
  })[];
29
31
  schoolInfo: import("../common/interface").ISchoolInfo;
30
32
  avgQuestionLastMonth: import("../common/interface").IQuestionResponseLastMonth[];
@@ -6,12 +6,14 @@ declare const useSchoolUsage: () => {
6
6
  value: number;
7
7
  lastMonthValue: number;
8
8
  totalStudent: number;
9
+ percent: number;
9
10
  } | {
10
11
  id: string;
11
12
  title: string;
12
13
  value: number;
13
14
  lastMonthValue: number;
14
15
  totalStudent?: undefined;
16
+ percent?: undefined;
15
17
  })[];
16
18
  schoolInfo: ISchoolInfo;
17
19
  getTotalTime: () => Promise<void>;
@@ -2,8 +2,8 @@ import { ICardAI, IOptionDate } from "./type";
2
2
  export declare const CALENDAR_OPTIONS: IOptionDate[];
3
3
  export declare const timeKeywords: string[];
4
4
  export declare enum IDataType {
5
- QuestionAnswer = 0,
6
- Total = 1
5
+ QuestionAnswer = "QuestionAnswer",
6
+ Total = "Total"
7
7
  }
8
8
  export declare const promptIcons: (() => JSX.Element)[];
9
9
  export declare const CARD_AI_HEADER: ICardAI[];
@@ -0,0 +1,2 @@
1
+ declare const OneRosterClever: () => JSX.Element;
2
+ export default OneRosterClever;
package/dist/index.js CHANGED
@@ -72370,7 +72370,7 @@ var getConvertMinuteToHour$1 = function getConvertMinuteToHour(time, usingText)
72370
72370
  var timeSecond = time * 60;
72371
72371
  var hours = Math.floor(timeSecond / 3600);
72372
72372
  var minutes = Math.floor(timeSecond % 3600 / 60);
72373
- var remainingSeconds = timeSecond % 60;
72373
+ var remainingSeconds = Math.floor(timeSecond % 60);
72374
72374
  var formattedHours = String(hours).padStart(2, '0');
72375
72375
  var formattedMinutes = String(minutes).padStart(2, '0');
72376
72376
  var formattedSeconds = String(remainingSeconds).padStart(2, '0');
@@ -72576,6 +72576,8 @@ var getAllTotalStatic = function getAllTotalStatic(filter) {
72576
72576
  };
72577
72577
 
72578
72578
  var useSchoolUsage = function useSchoolUsage() {
72579
+ var _listTotalTime$totalC, _listTotalTime$totalS;
72580
+
72579
72581
  var dispatch = reactRedux.useDispatch();
72580
72582
 
72581
72583
  var _useState = React.useState(INITIAl_HOMEPAGE_STATIC),
@@ -72635,7 +72637,8 @@ var useSchoolUsage = function useSchoolUsage() {
72635
72637
  title: 'Total Check-ins',
72636
72638
  value: listTotalTime === null || listTotalTime === void 0 ? void 0 : listTotalTime.totalCheckIn,
72637
72639
  lastMonthValue: listTotalTime.totalCheckInLastMonth,
72638
- totalStudent: listTotalTime.totalStudent
72640
+ totalStudent: listTotalTime.totalStudent,
72641
+ percent: ((_listTotalTime$totalC = listTotalTime === null || listTotalTime === void 0 ? void 0 : listTotalTime.totalCheckIn) != null ? _listTotalTime$totalC : 0) / ((_listTotalTime$totalS = listTotalTime.totalStudent) != null ? _listTotalTime$totalS : 0) * 100
72639
72642
  }, {
72640
72643
  id: "total_conversations_time",
72641
72644
  title: 'Total Conversation time',
@@ -74308,6 +74311,8 @@ var BorderLinearProgress = core$1.withStyles(function (theme) {
74308
74311
  })(core$1.LinearProgress);
74309
74312
 
74310
74313
  var TotalCard$2 = function TotalCard(_ref) {
74314
+ var _card$percent;
74315
+
74311
74316
  var card = _ref.card;
74312
74317
  var id = card.id;
74313
74318
 
@@ -74362,7 +74367,7 @@ var TotalCard$2 = function TotalCard(_ref) {
74362
74367
  className: "" + styles$b["title-card"]
74363
74368
  }, t(id)), renderIcon(id)), card.id === 'total_check_ins' ? React__default.createElement(BorderLinearProgress, {
74364
74369
  variant: "determinate",
74365
- value: 50
74370
+ value: (_card$percent = card === null || card === void 0 ? void 0 : card.percent) != null ? _card$percent : 0
74366
74371
  }) : null, React__default.createElement("div", {
74367
74372
  className: "d-flex align-items-center w-100"
74368
74373
  }, React__default.createElement("p", {
@@ -74410,7 +74415,7 @@ var SchoolUsage = function SchoolUsage(_ref) {
74410
74415
  variant: "h4",
74411
74416
  component: "h4",
74412
74417
  className: classes.title
74413
- }, t('school_usage')), totalCardData.map(function (item) {
74418
+ }, t('school_monthly_usage')), totalCardData.map(function (item) {
74414
74419
  return React__default.createElement(TotalCard$2, {
74415
74420
  key: item.id,
74416
74421
  card: item
@@ -78797,8 +78802,8 @@ var timeKeywords = ["this month", "this week", "this year", "last month", "last
78797
78802
  var IDataType;
78798
78803
 
78799
78804
  (function (IDataType) {
78800
- IDataType[IDataType["QuestionAnswer"] = 0] = "QuestionAnswer";
78801
- IDataType[IDataType["Total"] = 1] = "Total";
78805
+ IDataType["QuestionAnswer"] = "QuestionAnswer";
78806
+ IDataType["Total"] = "Total";
78802
78807
  })(IDataType || (IDataType = {}));
78803
78808
  var THEME = {
78804
78809
  LIGHT: 'light',