mario-education 2.4.170-level → 2.4.172-level

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.js CHANGED
@@ -28429,9 +28429,9 @@ var INITIAl_STUDENT_DASHBOARD = {
28429
28429
  totalOneToOne: 0,
28430
28430
  totalTimeConference: 0,
28431
28431
  totalTimeOneToOne: 0,
28432
- totalCheckIn: 0
28432
+ totalCheckIn: 0,
28433
+ schoolName: ""
28433
28434
  };
28434
- var COLOR_CHART_AND_PERCENTS = ["#73C8E5", "#97AFB9", "#FFB04F", "#FF7670", "#00B8B2", "#00B8FF", "#C6A762", "#C94645", "#006E60", "#336DDA", "#994700"];
28435
28435
  var COLOR_CHART_BUBBLE = ["#169490", "#316CD9", "#FFB04F", "#0F9655"];
28436
28436
  var PERCENT = [100, 80, 60, 40, 20, 0];
28437
28437
  var GENDER_OPTION = [{
@@ -29871,7 +29871,8 @@ var useChartDatas = function useChartDatas() {
29871
29871
  avgQuestionLastMonth: avgQuestionLastMonth,
29872
29872
  studentPressure: studentPressure,
29873
29873
  dataOverallReadyToLearn: dataOverallReadyToLearn,
29874
- readinessToLearning: readinessToLearning
29874
+ readinessToLearning: readinessToLearning,
29875
+ listTotalTime: listTotalTime
29875
29876
  };
29876
29877
  };
29877
29878
 
@@ -30688,13 +30689,17 @@ var LineChart = function LineChart(_ref) {
30688
30689
  var OverallDonutChart = function OverallDonutChart(_ref) {
30689
30690
  var series = _ref.series,
30690
30691
  colors = _ref.colors,
30691
- label = _ref.label;
30692
+ label = _ref.label,
30693
+ _ref$width = _ref.width,
30694
+ width = _ref$width === void 0 ? "100%" : _ref$width,
30695
+ _ref$height = _ref.height,
30696
+ height = _ref$height === void 0 ? 250 : _ref$height;
30692
30697
  return React__default.createElement(Chart, {
30693
30698
  options: overallDonutCHartOptions(label, colors),
30694
30699
  series: series,
30695
30700
  type: "donut",
30696
- width: "100%",
30697
- height: 250
30701
+ width: width,
30702
+ height: height
30698
30703
  });
30699
30704
  };
30700
30705
 
@@ -30711,7 +30716,10 @@ var GenerateChartData = function GenerateChartData(_ref) {
30711
30716
  avgQuestionLastMonth = _ref.avgQuestionLastMonth,
30712
30717
  isShowExpandIcon = _ref.isShowExpandIcon,
30713
30718
  onExpand = _ref.onExpand,
30714
- timeOfDay = _ref.timeOfDay;
30719
+ timeOfDay = _ref.timeOfDay,
30720
+ isPrint = _ref.isPrint,
30721
+ width = _ref.width,
30722
+ height = _ref.height;
30715
30723
  var avgs = [];
30716
30724
 
30717
30725
  var _loop = function _loop(i) {
@@ -30748,7 +30756,7 @@ var GenerateChartData = function GenerateChartData(_ref) {
30748
30756
  return React__default.createElement("div", {
30749
30757
  key: name,
30750
30758
  className: "w-100 h-100 " + styles$1["column-chart-percent"]
30751
- }, React__default.createElement("div", {
30759
+ }, !isPrint && React__default.createElement("div", {
30752
30760
  className: "" + styles$1["header-chart-generate"]
30753
30761
  }, React__default.createElement("p", {
30754
30762
  className: "" + styles$1["title-chart-generate"]
@@ -30767,6 +30775,7 @@ var GenerateChartData = function GenerateChartData(_ref) {
30767
30775
  var isStressQuestion = item.name.toLocaleLowerCase().includes("stress");
30768
30776
  var classArrowUp = !isStressQuestion ? "arrow-up" : "arrow-down";
30769
30777
  var classArrowDown = !isStressQuestion ? "arrow-down" : "arrow-up";
30778
+ if (isPrint && !activeColumn[index]) return null;
30770
30779
  return React__default.createElement("div", {
30771
30780
  hidden: !item.name,
30772
30781
  className: "" + styles$1["item-checkbox"],
@@ -30820,7 +30829,7 @@ var GenerateChartData = function GenerateChartData(_ref) {
30820
30829
  className: "" + styles$1["month-text"]
30821
30830
  }, "vs last " + timeOfDay))));
30822
30831
  })), React__default.createElement("div", {
30823
- className: "w-100"
30832
+ className: "w-100 " + (isPrint && typeChart === TYPECHART.DONUT ? "d-flex justify-content-center" : "")
30824
30833
  }, typeChart === TYPECHART.AREA && React__default.createElement(AreaChart, {
30825
30834
  months: months,
30826
30835
  activeColumn: activeColumn,
@@ -30842,7 +30851,9 @@ var GenerateChartData = function GenerateChartData(_ref) {
30842
30851
  }), typeChart === TYPECHART.DONUT && React__default.createElement(OverallDonutChart, {
30843
30852
  series: seriesDonut,
30844
30853
  colors: colors,
30845
- label: label
30854
+ label: label,
30855
+ width: width,
30856
+ height: height
30846
30857
  })));
30847
30858
  };
30848
30859
 
@@ -30927,7 +30938,9 @@ var CustomArcLabel = function CustomArcLabel(_ref) {
30927
30938
  var TopLearningStrategy = function TopLearningStrategy(_ref2) {
30928
30939
  var _data$learningStrateg, _learningStrategies$f, _learningStrategies$f2;
30929
30940
 
30930
- var data = _ref2.data;
30941
+ var data = _ref2.data,
30942
+ learningStrategyId = _ref2.learningStrategyId,
30943
+ topLearningStrategyId = _ref2.topLearningStrategyId;
30931
30944
  if (!data) return React__default.createElement(Loading, null);
30932
30945
  var screenWidth = window.innerWidth || document.documentElement.clientWidth || document.body.clientWidth;
30933
30946
  var isMobileScreen = screenWidth < 576;
@@ -31048,7 +31061,10 @@ var TopLearningStrategy = function TopLearningStrategy(_ref2) {
31048
31061
  className: "" + styles$1["title-chart"]
31049
31062
  }, t(topLearningStrategyName)), React__default.createElement("p", {
31050
31063
  className: "" + styles$1["description-chart"]
31051
- }, "The Effectiveness of Learning Strategies by Student's feedback"))), seriesLearningStrategy.some(function (i) {
31064
+ }, "The Effectiveness of Learning Strategies by Student's feedback"))), React__default.createElement("div", {
31065
+ className: "w-100 h-100",
31066
+ id: learningStrategyId
31067
+ }, seriesLearningStrategy.some(function (i) {
31052
31068
  return i.data;
31053
31069
  }) ? React__default.createElement("div", {
31054
31070
  style: {
@@ -31065,7 +31081,7 @@ var TopLearningStrategy = function TopLearningStrategy(_ref2) {
31065
31081
  src: "images/chart-top-learning.png"
31066
31082
  }), React__default.createElement("p", {
31067
31083
  className: "" + styles$1["name-chart"]
31068
- }, "Perceived Usefulness")), React__default.createElement(reactstrap.Col, {
31084
+ }, "Perceived Usefulness"))), React__default.createElement(reactstrap.Col, {
31069
31085
  md: 5,
31070
31086
  className: "" + styles$1["box-top-5-most"]
31071
31087
  }, React__default.createElement("div", {
@@ -31076,7 +31092,10 @@ var TopLearningStrategy = function TopLearningStrategy(_ref2) {
31076
31092
  className: "" + styles$1["title-chart"]
31077
31093
  }, t(topMostUsedStrategiesName)), React__default.createElement("p", {
31078
31094
  className: "" + styles$1["description-chart"]
31079
- }, "How many times a strategy has been chosen"))), dataConvert.length > 0 ? React__default.createElement(pie.ResponsivePie, {
31095
+ }, "How many times a strategy has been chosen"))), React__default.createElement("div", {
31096
+ className: "w-100 h-100",
31097
+ id: topLearningStrategyId
31098
+ }, dataConvert.length > 0 ? React__default.createElement(pie.ResponsivePie, {
31080
31099
  data: dataConvert,
31081
31100
  margin: screenWidth > 550 ? largeMarginChart : smallMarginChart,
31082
31101
  innerRadius: 0.5,
@@ -31091,7 +31110,7 @@ var TopLearningStrategy = function TopLearningStrategy(_ref2) {
31091
31110
  style: {
31092
31111
  fontSize: "14px"
31093
31112
  }
31094
- }, t("no_data"))))));
31113
+ }, t("no_data")))))));
31095
31114
  };
31096
31115
 
31097
31116
  var propsAreEqual = function propsAreEqual(preProps, nextProps) {
@@ -31101,7 +31120,8 @@ var propsAreEqual = function propsAreEqual(preProps, nextProps) {
31101
31120
  var TopLearningStrategy$1 = React__default.memo(TopLearningStrategy, propsAreEqual);
31102
31121
 
31103
31122
  var BubbleChartCustom = function BubbleChartCustom(_ref) {
31104
- var data = _ref.data;
31123
+ var data = _ref.data,
31124
+ isPrint = _ref.isPrint;
31105
31125
 
31106
31126
  var _useTranslation = marioCore.useTranslation(),
31107
31127
  t = _useTranslation.t;
@@ -31115,7 +31135,7 @@ var BubbleChartCustom = function BubbleChartCustom(_ref) {
31115
31135
  var seriesName = seriesNameBubbleChartCustom(data);
31116
31136
  return React__default.createElement("div", {
31117
31137
  className: "" + styles$1["size-100"]
31118
- }, React__default.createElement("div", {
31138
+ }, !isPrint && React__default.createElement("div", {
31119
31139
  className: "" + styles$1["block-header-chart"]
31120
31140
  }, React__default.createElement("p", {
31121
31141
  className: styles$1["title-chart"] + " " + styles$1["ml-10"]
@@ -31439,88 +31459,240 @@ var DashboardToPDF = function DashboardToPDF(props) {
31439
31459
  dayOfWeekConference = props.dayOfWeekConference,
31440
31460
  avgConferenceLastMonth = props.avgConferenceLastMonth,
31441
31461
  readinessToLearning = props.readinessToLearning,
31442
- studentPressure = props.studentPressure;
31462
+ studentPressure = props.studentPressure,
31463
+ dataOverallReadyToLearn = props.dataOverallReadyToLearn,
31464
+ schoolName = props.schoolName;
31443
31465
 
31444
31466
  var _useTranslation = marioCore.useTranslation(),
31445
31467
  t = _useTranslation.t;
31446
31468
 
31447
31469
  var dispatch = reactRedux.useDispatch();
31448
31470
 
31471
+ var getWidthOfWord = function getWidthOfWord(character, fontSize, fontWeight) {
31472
+ var dummyElement = document.createElement("span");
31473
+ dummyElement.style.visibility = "hidden";
31474
+ dummyElement.style.position = "absolute";
31475
+ dummyElement.style.whiteSpace = "nowrap";
31476
+ dummyElement.style.fontSize = fontSize;
31477
+ dummyElement.style.fontWeight = fontWeight;
31478
+ dummyElement.innerHTML = character;
31479
+ document.body.appendChild(dummyElement);
31480
+ var width = dummyElement.offsetWidth;
31481
+ document.body.removeChild(dummyElement);
31482
+ return width;
31483
+ };
31484
+
31449
31485
  var generatePDF = function generatePDF() {
31450
31486
  try {
31451
- var _temp42 = function _temp42() {
31487
+ var _temp40 = function _temp40() {
31452
31488
  dispatch(marioCore.setLoading(false));
31453
31489
  };
31454
31490
 
31455
31491
  dispatch(marioCore.setLoading(true));
31456
31492
 
31457
- var _temp43 = _catch(function () {
31458
- function _temp39() {
31459
- function _temp37() {
31460
- function _temp35() {
31461
- function _temp33() {
31462
- function _temp31() {
31463
- function _temp29() {
31464
- function _temp27() {
31465
- function _temp25() {
31466
- doc.save("DashBoard.pdf");
31493
+ var _temp41 = _catch(function () {
31494
+ function _temp37() {
31495
+ function _temp35() {
31496
+ function _temp33() {
31497
+ function _temp31() {
31498
+ function _temp29() {
31499
+ function _temp27() {
31500
+ function _temp25() {
31501
+ function _temp23() {
31502
+ function _temp21() {
31503
+ doc.save("DashBoard.pdf");
31504
+ }
31505
+
31506
+ var _temp20 = function () {
31507
+ if (selectedToPDF.includes(topLearningStrategyName)) {
31508
+ return Promise.resolve(createImageHeader()).then(function () {
31509
+ doc.setFontSize(14);
31510
+ doc.setTextColor("#000");
31511
+ doc.setFont("Helvetica", "normal", "bold");
31512
+ doc.text(t(topLearningStrategyName), left, 70);
31513
+ doc.setFontSize(12);
31514
+ doc.setTextColor("#3D3D3D");
31515
+ doc.setFont("Helvetica", "normal", "normal");
31516
+ doc.text("The Effectiveness of Learning Strategies by Student's feedback", left, line + 4);
31517
+ var chart = document.getElementById(topLearningStrategyName);
31518
+ return Promise.resolve(html2canvas(chart)).then(function (canvas) {
31519
+ line += 12;
31520
+ left = 20;
31521
+ var chartWidth = 420;
31522
+ var chartHeight = chart && chart.clientWidth ? chartWidth * chart.clientHeight / chart.clientWidth : heightChart;
31523
+ doc.addImage(canvas.toDataURL("image/png"), 10, line, chartWidth, chartHeight);
31524
+ doc.addPage();
31525
+ line = 80;
31526
+ left = 20;
31527
+ return Promise.resolve(createImageHeader()).then(function () {
31528
+ doc.setFontSize(14);
31529
+ doc.setFont("Helvetica", "normal", "bold");
31530
+ doc.setTextColor("#000");
31531
+ doc.text(t(topMostUsedStrategiesName), left, 70);
31532
+ doc.setFontSize(12);
31533
+ doc.setTextColor("#3D3D3D");
31534
+ doc.setFont("Helvetica", "normal", "normal");
31535
+ doc.text("How many times a strategy has been chosen", left, line + 4);
31536
+ var topChart = document.getElementById(topMostUsedStrategiesName);
31537
+ return Promise.resolve(html2canvas(topChart)).then(function (topCanvas) {
31538
+ doc.setFontSize(8);
31539
+ line += 16;
31540
+ var topChartWidth = 420;
31541
+ var topChartHeight = topChart && topChart.clientWidth ? topChartWidth * topChart.clientHeight / topChart.clientWidth : heightChart;
31542
+ doc.addImage(topCanvas.toDataURL("image/png"), 10, line + 20, topChartWidth, topChartHeight);
31543
+ });
31544
+ });
31545
+ });
31546
+ });
31547
+ }
31548
+ }();
31549
+
31550
+ return _temp20 && _temp20.then ? _temp20.then(_temp21) : _temp21(_temp20);
31467
31551
  }
31468
31552
 
31469
- var _temp24 = function () {
31470
- if (selectedToPDF.includes(topLearningStrategyName)) {
31471
- var chart = document.getElementById("learning_strategy");
31472
- return Promise.resolve(html2canvas(chart)).then(function (canvas) {
31473
- doc.setFontSize(8);
31474
- left = 20;
31475
- doc.addImage(canvas.toDataURL("image/png"), 10, line + 20, 450, 150);
31476
- doc.setFontSize(8);
31553
+ var _temp22 = function () {
31554
+ if (selectedToPDF.includes(learningProcessName)) {
31555
+ return Promise.resolve(createImageHeader()).then(function () {
31556
+ doc.setFontSize(14);
31557
+ doc.setFont("Helvetica", "normal", "bold");
31558
+ doc.text(t(learningProcessName), left, 70);
31559
+ line += 20;
31560
+ var chart = document.getElementById("learning_progress");
31561
+ return Promise.resolve(html2canvas(chart)).then(function (canvas) {
31562
+ function _temp19() {
31563
+ left = 20;
31564
+ line += questions.length * 10;
31565
+ var chartWidth = 420;
31566
+ var chartHeight = chart && chart.clientWidth ? chartWidth * chart.clientHeight / chart.clientWidth : heightChart;
31567
+ doc.addImage(canvas.toDataURL("image/png"), 10, line + 20, chartWidth, chartHeight);
31568
+ chartCount++;
31569
+
31570
+ if (chartCount < selectedToPDF.length) {
31571
+ doc.addPage();
31572
+ line = 80;
31573
+ left = 20;
31574
+ }
31575
+ }
31576
+
31577
+ var lineOptionPrecess = line;
31578
+ doc.setFontSize(8);
31579
+ var questions = seriesConference.map(function (r) {
31580
+ return r.name;
31581
+ });
31582
+ var COLORS = ["#73C8E5", "#F9F871", "#D7B0DE", "#E56362", "#5A7F05", "#D3D3D3"];
31583
+
31584
+ var _temp18 = _forTo(monthsConference, function (index) {
31585
+ var _line = line;
31586
+ doc.setFontSize(12);
31587
+ doc.setFont("Helvetica", "normal", "bold");
31588
+ doc.text(monthsConference[index], left, _line);
31589
+ doc.setFontSize(8);
31590
+
31591
+ for (var indexResult = 0; indexResult < (seriesConference === null || seriesConference === void 0 ? void 0 : seriesConference.length); indexResult++) {
31592
+ var avg = seriesConference[indexResult].data[index];
31593
+
31594
+ if (avg != 0) {
31595
+ var questionText = questions[indexResult];
31596
+
31597
+ if (questionText != "") {
31598
+ doc.setDrawColor(0);
31599
+ doc.setFillColor(COLORS[indexResult]);
31600
+ doc.roundedRect(left, _line + 5, 5, 5, 1, 1, "F");
31601
+ doc.setFont("Helvetica", "normal", "bold");
31602
+ doc.text(questionText + ":", left + 8, _line + 10);
31603
+ doc.setFont("Helvetica", "normal", "normal");
31604
+ doc.text((avg === null || avg === void 0 ? void 0 : avg.toFixed(2)) + "%", left + (questionText === null || questionText === void 0 ? void 0 : questionText.length) * 2.5 + 20.5, _line + 10);
31605
+ }
31606
+
31607
+ _line += 10;
31608
+
31609
+ if (_line > lineOptionPrecess) {
31610
+ lineOptionPrecess = _line;
31611
+ }
31612
+ }
31613
+ }
31614
+
31615
+ left += 100;
31616
+
31617
+ if (left + 105 > WIDTH_PAPER) {
31618
+ left = 20;
31619
+ line = lineOptionPrecess + 25;
31620
+ }
31621
+
31622
+ var _temp17 = function () {
31623
+ if (line + 150 > HEIGHT_PAPER) {
31624
+ doc.addPage();
31625
+ return Promise.resolve(createImageHeader()).then(function () {
31626
+ line = 80;
31627
+ left = 20;
31628
+ });
31629
+ }
31630
+ }();
31631
+
31632
+ if (_temp17 && _temp17.then) return _temp17.then(function () {});
31633
+ });
31634
+
31635
+ return _temp18 && _temp18.then ? _temp18.then(_temp19) : _temp19(_temp18);
31636
+ });
31477
31637
  });
31478
31638
  }
31479
31639
  }();
31480
31640
 
31481
- return _temp24 && _temp24.then ? _temp24.then(_temp25) : _temp25(_temp24);
31641
+ return _temp22 && _temp22.then ? _temp22.then(_temp23) : _temp23(_temp22);
31482
31642
  }
31483
31643
 
31484
- var _temp26 = function () {
31485
- if (selectedToPDF.includes(learningProcessName)) {
31486
- var _temp44 = function _temp44() {
31644
+ var _temp24 = function () {
31645
+ if (selectedToPDF.includes(successIndicatorsName)) {
31646
+ return Promise.resolve(createImageHeader()).then(function () {
31487
31647
  doc.setFontSize(14);
31488
31648
  doc.setFont("Helvetica", "normal", "bold");
31489
- doc.text(t(learningProcessName), left, line);
31490
- line += 20;
31491
- var chart = document.getElementById("learning_progress");
31649
+ doc.text(t(successIndicatorsName), left, line);
31650
+ line += 40;
31651
+ var chart = document.getElementById("success_indicators");
31492
31652
  return Promise.resolve(html2canvas(chart)).then(function (canvas) {
31493
- function _temp21() {
31494
- left = 20;
31495
- doc.addImage(canvas.toDataURL("image/png"), 10, line + 70, 420, heightChart);
31496
- doc.setFontSize(8);
31497
- doc.addPage();
31498
- line = 80;
31653
+ function _temp16() {
31499
31654
  left = 20;
31655
+ line += questions.length * 10;
31656
+ var chartWidth = 420;
31657
+ var chartHeight = chart && chart.clientWidth ? chartWidth * chart.clientHeight / chart.clientWidth : heightChart;
31658
+ doc.addImage(canvas.toDataURL("image/png"), 10, line + 20, chartWidth, chartHeight);
31659
+ chartCount++;
31660
+
31661
+ if (chartCount < selectedToPDF.length) {
31662
+ doc.addPage();
31663
+ line = 80;
31664
+ left = 20;
31665
+ }
31500
31666
  }
31501
31667
 
31502
- var lineOptionPrecess = line;
31668
+ var lineOptionCheckIn = line;
31503
31669
  doc.setFontSize(8);
31504
- var questions = seriesConference.map(function (r) {
31670
+ var questions = successIndicatorsData.map(function (r) {
31505
31671
  return r.name;
31506
31672
  });
31507
-
31508
- var _temp20 = _forTo(monthsConference, function (index) {
31673
+ var COLORS = ["#73C8E5", "#FFB04F", "#D7B0DE", "#E56362", "#5A7F05", "#D3D3D3"];
31674
+ var indexCheckIn = 0;
31675
+
31676
+ var _temp15 = _for(function () {
31677
+ return indexCheckIn < monthsOneToOne.length;
31678
+ }, function () {
31679
+ return indexCheckIn++;
31680
+ }, function () {
31509
31681
  var _line = line;
31510
31682
  doc.setFontSize(12);
31511
31683
  doc.setFont("Helvetica", "normal", "bold");
31512
- doc.text(monthsConference[index], left, _line);
31684
+ doc.text(monthsOneToOne[indexCheckIn], left, _line);
31513
31685
  doc.setFontSize(8);
31514
31686
 
31515
- for (var indexResult = 0; indexResult < (seriesConference === null || seriesConference === void 0 ? void 0 : seriesConference.length); indexResult++) {
31516
- var avg = seriesConference[indexResult].data[index];
31687
+ for (var indexResult = 0; indexResult < (successIndicatorsData === null || successIndicatorsData === void 0 ? void 0 : successIndicatorsData.length); indexResult++) {
31688
+ var avg = successIndicatorsData[indexResult].data[indexCheckIn];
31517
31689
 
31518
31690
  if (avg != 0) {
31519
31691
  var questionText = questions[indexResult];
31520
31692
 
31521
31693
  if (questionText != "") {
31522
31694
  doc.setDrawColor(0);
31523
- doc.setFillColor(COLOR_CHART_AND_PERCENTS[indexResult]);
31695
+ doc.setFillColor(COLORS[indexResult]);
31524
31696
  doc.roundedRect(left, _line + 5, 5, 5, 1, 1, "F");
31525
31697
  doc.setFont("Helvetica", "normal", "bold");
31526
31698
  doc.text(questionText + ":", left + 8, _line + 10);
@@ -31530,8 +31702,8 @@ var DashboardToPDF = function DashboardToPDF(props) {
31530
31702
 
31531
31703
  _line += 10;
31532
31704
 
31533
- if (_line > lineOptionPrecess) {
31534
- lineOptionPrecess = _line;
31705
+ if (_line > lineOptionCheckIn) {
31706
+ lineOptionCheckIn = _line;
31535
31707
  }
31536
31708
  }
31537
31709
  }
@@ -31540,10 +31712,10 @@ var DashboardToPDF = function DashboardToPDF(props) {
31540
31712
 
31541
31713
  if (left + 105 > WIDTH_PAPER) {
31542
31714
  left = 20;
31543
- line = lineOptionPrecess + 25;
31715
+ line = lineOptionCheckIn + 25;
31544
31716
  }
31545
31717
 
31546
- var _temp19 = function () {
31718
+ var _temp14 = function () {
31547
31719
  if (line + 150 > HEIGHT_PAPER) {
31548
31720
  doc.addPage();
31549
31721
  return Promise.resolve(createImageHeader()).then(function () {
@@ -31553,185 +31725,124 @@ var DashboardToPDF = function DashboardToPDF(props) {
31553
31725
  }
31554
31726
  }();
31555
31727
 
31556
- if (_temp19 && _temp19.then) return _temp19.then(function () {});
31728
+ if (_temp14 && _temp14.then) return _temp14.then(function () {});
31557
31729
  });
31558
31730
 
31559
- return _temp20 && _temp20.then ? _temp20.then(_temp21) : _temp21(_temp20);
31731
+ return _temp15 && _temp15.then ? _temp15.then(_temp16) : _temp16(_temp15);
31560
31732
  });
31561
- };
31562
-
31563
- var _temp45 = function () {
31564
- if (line > HEIGHT_PAPER / 2) {
31565
- line = 80;
31566
- left = 20;
31567
- doc.addPage();
31568
- return Promise.resolve(createImageHeader()).then(function () {});
31569
- }
31570
- }();
31571
-
31572
- return _temp45 && _temp45.then ? _temp45.then(_temp44) : _temp44(_temp45);
31733
+ });
31573
31734
  }
31574
31735
  }();
31575
31736
 
31576
- return _temp26 && _temp26.then ? _temp26.then(_temp27) : _temp27(_temp26);
31737
+ return _temp24 && _temp24.then ? _temp24.then(_temp25) : _temp25(_temp24);
31577
31738
  }
31578
31739
 
31579
- var _temp28 = function () {
31740
+ var _temp26 = function () {
31580
31741
  if (selectedToPDF.includes(studentStressByZone)) {
31581
- var _temp46 = function _temp46() {
31742
+ var _temp42 = function _temp42() {
31582
31743
  doc.setFontSize(14);
31583
31744
  doc.setFont("Helvetica", "normal", "bold");
31584
- doc.text(t(studentStressByZone), left, line);
31745
+ doc.text(t(studentStressByZone), left, line <= 85 ? 70 : line);
31585
31746
  line += 20;
31586
31747
  var chart = document.getElementById("student_stress_by_zone");
31587
31748
  return Promise.resolve(html2canvas(chart)).then(function (canvas) {
31588
- doc.addImage(canvas.toDataURL("image/png"), 10, line, 420, heightChart);
31589
- line += heightChart + 20;
31749
+ var chartWidth = 460;
31750
+ var chartHeight = chart && chart.clientWidth ? chartWidth * chart.clientHeight / chart.clientWidth : heightChart;
31751
+ doc.addImage(canvas.toDataURL("image/png"), 10, line, chartWidth, chartHeight);
31752
+ chartCount++;
31753
+
31754
+ if (chartCount < selectedToPDF.length) {
31755
+ doc.addPage();
31756
+ line = 80;
31757
+ left = 20;
31758
+ }
31590
31759
  });
31591
31760
  };
31592
31761
 
31593
- var _temp47 = function () {
31594
- if (line > HEIGHT_PAPER / 2) {
31595
- line = 80;
31596
- left = 20;
31597
- doc.addPage();
31762
+ if (line > HEIGHT_PAPER / 2) {
31763
+ line = 80;
31764
+ left = 20;
31765
+ doc.addPage();
31766
+ }
31767
+
31768
+ var _temp43 = function () {
31769
+ if (line <= 85) {
31598
31770
  return Promise.resolve(createImageHeader()).then(function () {});
31599
31771
  }
31600
31772
  }();
31601
31773
 
31602
- return _temp47 && _temp47.then ? _temp47.then(_temp46) : _temp46(_temp47);
31774
+ return _temp43 && _temp43.then ? _temp43.then(_temp42) : _temp42(_temp43);
31603
31775
  }
31604
31776
  }();
31605
31777
 
31606
- return _temp28 && _temp28.then ? _temp28.then(_temp29) : _temp29(_temp28);
31778
+ return _temp26 && _temp26.then ? _temp26.then(_temp27) : _temp27(_temp26);
31607
31779
  }
31608
31780
 
31609
- var _temp30 = function () {
31781
+ var _temp28 = function () {
31610
31782
  if (selectedToPDF.includes(studentDistribution)) {
31611
- var _temp48 = function _temp48() {
31612
- var chart = document.getElementById("student_distribution");
31783
+ var _temp44 = function _temp44() {
31784
+ doc.setFontSize(14);
31785
+ doc.setFont("Helvetica", "normal", "bold");
31786
+ doc.text(t(studentDistribution), left, line <= 85 ? 70 : line);
31787
+ var chart = document.getElementById(studentDistribution);
31613
31788
  return Promise.resolve(html2canvas(chart)).then(function (canvas) {
31614
- doc.addImage(canvas.toDataURL("image/png"), 10, line, 420, heightChart);
31615
- line += heightChart + 20;
31789
+ var chartWidth = 420;
31790
+ line += 20;
31791
+ var chartHeight = chart && chart.clientWidth ? chartWidth * chart.clientHeight / chart.clientWidth : heightChart;
31792
+ doc.addImage(canvas.toDataURL("image/png"), 10, line, chartWidth, chartHeight);
31793
+ chartCount++;
31794
+ line += heightChart;
31795
+
31796
+ if (chartCount < selectedToPDF.length && !selectedToPDF.includes(studentStressByZone)) {
31797
+ doc.addPage();
31798
+ line = 80;
31799
+ left = 20;
31800
+ }
31616
31801
  });
31617
31802
  };
31618
31803
 
31619
- var _temp49 = function () {
31620
- if (line > HEIGHT_PAPER / 2) {
31621
- line = 80;
31622
- left = 20;
31623
- doc.addPage();
31804
+ if (line > HEIGHT_PAPER / 2) {
31805
+ line = 80;
31806
+ left = 20;
31807
+ doc.addPage();
31808
+ }
31809
+
31810
+ var _temp45 = function () {
31811
+ if (line <= 85) {
31624
31812
  return Promise.resolve(createImageHeader()).then(function () {});
31625
31813
  }
31626
31814
  }();
31627
31815
 
31628
- return _temp49 && _temp49.then ? _temp49.then(_temp48) : _temp48(_temp49);
31816
+ return _temp45 && _temp45.then ? _temp45.then(_temp44) : _temp44(_temp45);
31629
31817
  }
31630
31818
  }();
31631
31819
 
31632
- return _temp30 && _temp30.then ? _temp30.then(_temp31) : _temp31(_temp30);
31820
+ return _temp28 && _temp28.then ? _temp28.then(_temp29) : _temp29(_temp28);
31633
31821
  }
31634
31822
 
31635
- var _temp32 = function () {
31636
- if (selectedToPDF.includes(successIndicatorsName)) {
31637
- var _temp50 = function _temp50() {
31823
+ var _temp30 = function () {
31824
+ if (selectedToPDF.includes(overallReadinessToLearn)) {
31825
+ return Promise.resolve(createImageHeader()).then(function () {
31638
31826
  doc.setFontSize(14);
31639
31827
  doc.setFont("Helvetica", "normal", "bold");
31640
- doc.text(t(successIndicatorsName), left, line);
31641
- line += 20;
31642
- var chart = document.getElementById("success_indicators");
31828
+ doc.text(t(overallReadinessToLearn), left, 70);
31829
+ var chart = document.getElementById(overallReadinessToLearn);
31643
31830
  return Promise.resolve(html2canvas(chart)).then(function (canvas) {
31644
- function _temp12() {
31645
- left = 20;
31646
- line += questions.length * 10;
31647
- doc.addImage(canvas.toDataURL("image/png"), 10, line + 20, 420, heightChart);
31648
- doc.setFontSize(8);
31649
- line += heightChart + 20;
31650
- }
31651
-
31652
- var lineOptionCheckIn = line;
31653
- doc.setFontSize(8);
31654
- var questions = successIndicatorsData.map(function (r) {
31655
- return r.name;
31656
- });
31657
- var indexCheckIn = 0;
31658
-
31659
- var _temp11 = _for(function () {
31660
- return indexCheckIn < monthsOneToOne.length;
31661
- }, function () {
31662
- return indexCheckIn++;
31663
- }, function () {
31664
- var _line = line;
31665
- doc.setFontSize(12);
31666
- doc.setFont("Helvetica", "normal", "bold");
31667
- doc.text(monthsOneToOne[indexCheckIn], left, _line);
31668
- doc.setFontSize(8);
31669
-
31670
- for (var indexResult = 0; indexResult < (successIndicatorsData === null || successIndicatorsData === void 0 ? void 0 : successIndicatorsData.length); indexResult++) {
31671
- var avg = successIndicatorsData[indexResult].data[indexCheckIn];
31672
-
31673
- if (avg != 0) {
31674
- var questionText = questions[indexResult];
31675
-
31676
- if (questionText != "") {
31677
- doc.setDrawColor(0);
31678
- doc.setFillColor(COLOR_CHART_AND_PERCENTS[indexResult]);
31679
- doc.roundedRect(left, _line + 5, 5, 5, 1, 1, "F");
31680
- doc.setFont("Helvetica", "normal", "bold");
31681
- doc.text(questionText + ":", left + 8, _line + 10);
31682
- doc.setFont("Helvetica", "normal", "normal");
31683
- doc.text((avg === null || avg === void 0 ? void 0 : avg.toFixed(2)) + "%", left + (questionText === null || questionText === void 0 ? void 0 : questionText.length) * 2.5 + 20.5, _line + 10);
31684
- }
31685
-
31686
- _line += 10;
31687
-
31688
- if (_line > lineOptionCheckIn) {
31689
- lineOptionCheckIn = _line;
31690
- }
31691
- }
31692
- }
31693
-
31694
- left += 100;
31695
-
31696
- if (left + 105 > WIDTH_PAPER) {
31697
- left = 20;
31698
- line = lineOptionCheckIn + 25;
31699
- }
31700
-
31701
- var _temp10 = function () {
31702
- if (line + 150 > HEIGHT_PAPER) {
31703
- doc.addPage();
31704
- return Promise.resolve(createImageHeader()).then(function () {
31705
- line = 80;
31706
- left = 20;
31707
- });
31708
- }
31709
- }();
31710
-
31711
- if (_temp10 && _temp10.then) return _temp10.then(function () {});
31712
- });
31713
-
31714
- return _temp11 && _temp11.then ? _temp11.then(_temp12) : _temp12(_temp11);
31715
- });
31716
- };
31717
-
31718
- var _temp51 = function () {
31719
- if (line > HEIGHT_PAPER / 2) {
31720
- line = 80;
31721
31831
  left = 20;
31722
- doc.addPage();
31723
- return Promise.resolve(createImageHeader()).then(function () {});
31724
- }
31725
- }();
31726
-
31727
- return _temp51 && _temp51.then ? _temp51.then(_temp50) : _temp50(_temp51);
31832
+ var chartWidth = 420;
31833
+ var chartHeight = chart && chart.clientWidth ? chartWidth * chart.clientHeight / chart.clientWidth : heightChart;
31834
+ doc.addImage(canvas.toDataURL("image/png"), 10, line, chartWidth, chartHeight);
31835
+ chartCount++;
31836
+ line += heightChart + 20;
31837
+ });
31838
+ });
31728
31839
  }
31729
31840
  }();
31730
31841
 
31731
- return _temp32 && _temp32.then ? _temp32.then(_temp33) : _temp33(_temp32);
31842
+ return _temp30 && _temp30.then ? _temp30.then(_temp31) : _temp31(_temp30);
31732
31843
  }
31733
31844
 
31734
- var _temp34 = function () {
31845
+ var _temp32 = function () {
31735
31846
  if (selectedToPDF.includes(preparednessChartName)) {
31736
31847
  return Promise.resolve(createImageHeader()).then(function () {
31737
31848
  doc.setFontSize(14);
@@ -31743,11 +31854,19 @@ var DashboardToPDF = function DashboardToPDF(props) {
31743
31854
  function _temp9() {
31744
31855
  left = 20;
31745
31856
  line += questions.length * 10;
31746
- doc.addImage(canvas.toDataURL("image/png"), 10, line + 20, 420, heightChart);
31747
- doc.setFontSize(8);
31748
- line += heightChart + 20;
31857
+ var chartWidth = 420;
31858
+ var chartHeight = chart && chart.clientWidth ? chartWidth * chart.clientHeight / chart.clientWidth : heightChart;
31859
+ doc.addImage(canvas.toDataURL("image/png"), 10, line + 20, chartWidth, chartHeight);
31860
+ chartCount++;
31861
+
31862
+ if (chartCount < selectedToPDF.length) {
31863
+ doc.addPage();
31864
+ line = 80;
31865
+ left = 20;
31866
+ }
31749
31867
  }
31750
31868
 
31869
+ line += 20;
31751
31870
  var lineOptionCheckIn = line;
31752
31871
  doc.setFontSize(8);
31753
31872
  var questions = preparednessData.map(function (r) {
@@ -31765,6 +31884,7 @@ var DashboardToPDF = function DashboardToPDF(props) {
31765
31884
  doc.setFont("Helvetica", "normal", "bold");
31766
31885
  doc.text(monthsOneToOne[indexCheckIn], left, _line);
31767
31886
  doc.setFontSize(8);
31887
+ var COLORS = ["#169490", "#316CD9", "#FFB04F"];
31768
31888
 
31769
31889
  for (var indexResult = 0; indexResult < (preparednessData === null || preparednessData === void 0 ? void 0 : preparednessData.length); indexResult++) {
31770
31890
  var avg = preparednessData[indexResult].data[indexCheckIn];
@@ -31774,7 +31894,7 @@ var DashboardToPDF = function DashboardToPDF(props) {
31774
31894
 
31775
31895
  if (questionText != "") {
31776
31896
  doc.setDrawColor(0);
31777
- doc.setFillColor(COLOR_CHART_AND_PERCENTS[indexResult]);
31897
+ doc.setFillColor(COLORS[indexResult]);
31778
31898
  doc.roundedRect(left, _line + 5, 5, 5, 1, 1, "F");
31779
31899
  doc.setFont("Helvetica", "normal", "bold");
31780
31900
  doc.text(questionText + ":", left + 8, _line + 10);
@@ -31816,10 +31936,10 @@ var DashboardToPDF = function DashboardToPDF(props) {
31816
31936
  }
31817
31937
  }();
31818
31938
 
31819
- return _temp34 && _temp34.then ? _temp34.then(_temp35) : _temp35(_temp34);
31939
+ return _temp32 && _temp32.then ? _temp32.then(_temp33) : _temp33(_temp32);
31820
31940
  }
31821
31941
 
31822
- var _temp36 = function () {
31942
+ var _temp34 = function () {
31823
31943
  if (selectedToPDF.includes(averageStudentStressName)) {
31824
31944
  return Promise.resolve(createImageHeader()).then(function () {
31825
31945
  doc.setFontSize(14);
@@ -31830,13 +31950,19 @@ var DashboardToPDF = function DashboardToPDF(props) {
31830
31950
  return Promise.resolve(html2canvas(chart)).then(function (canvas) {
31831
31951
  function _temp6() {
31832
31952
  left = 20;
31833
- doc.addImage(canvas.toDataURL("image/png"), 10, line + 20, 420, heightChart);
31834
- doc.setFontSize(8);
31835
- doc.addPage();
31836
- line = 80;
31837
- left = 20;
31953
+ var chartWidth = 420;
31954
+ var chartHeight = chart && chart.clientWidth ? chartWidth * chart.clientHeight / chart.clientWidth : heightChart;
31955
+ doc.addImage(canvas.toDataURL("image/png"), 10, line + 20, chartWidth, chartHeight);
31956
+ chartCount++;
31957
+
31958
+ if (chartCount < selectedToPDF.length) {
31959
+ doc.addPage();
31960
+ line = 80;
31961
+ left = 20;
31962
+ }
31838
31963
  }
31839
31964
 
31965
+ line += 20;
31840
31966
  var lineOptionCheckIn = line;
31841
31967
  doc.setFontSize(8);
31842
31968
  var questions = stressData.map(function (r) {
@@ -31863,7 +31989,7 @@ var DashboardToPDF = function DashboardToPDF(props) {
31863
31989
 
31864
31990
  if (questionText != "") {
31865
31991
  doc.setDrawColor(0);
31866
- doc.setFillColor(COLOR_CHART_AND_PERCENTS[indexResult]);
31992
+ doc.setFillColor("#C44140");
31867
31993
  doc.roundedRect(left, _line + 5, 5, 5, 1, 1, "F");
31868
31994
  doc.setFont("Helvetica", "normal", "bold");
31869
31995
  doc.text(questionText + ":", left + 8, _line + 10);
@@ -31905,7 +32031,7 @@ var DashboardToPDF = function DashboardToPDF(props) {
31905
32031
  }
31906
32032
  }();
31907
32033
 
31908
- return _temp36 && _temp36.then ? _temp36.then(_temp37) : _temp37(_temp36);
32034
+ return _temp34 && _temp34.then ? _temp34.then(_temp35) : _temp35(_temp34);
31909
32035
  }
31910
32036
 
31911
32037
  var doc = new jsPDF({
@@ -31916,12 +32042,18 @@ var DashboardToPDF = function DashboardToPDF(props) {
31916
32042
  var WIDTH_PAPER = doc.internal.pageSize.width;
31917
32043
  var HEIGHT_PAPER = doc.internal.pageSize.height;
31918
32044
  var heightChart = 200;
32045
+ var splitShoolName = doc.splitTextToSize(schoolName, 120);
32046
+ var chartCount = 0;
32047
+ var schoolWidth = schoolName.length <= 18 ? getWidthOfWord(schoolName, "18px", "bold") : getWidthOfWord(splitShoolName.join(""), "18px", "bold");
31919
32048
 
31920
32049
  var createImageHeader = function createImageHeader() {
31921
32050
  try {
31922
32051
  var imageLogo = document.getElementById("header-logo");
31923
32052
  return Promise.resolve(html2canvas(imageLogo)).then(function (imageLogoCanvas) {
31924
32053
  doc.addImage(imageLogoCanvas.toDataURL("image/png", 1.0), "png", 20, 20, 90, 25);
32054
+ doc.setFontSize(18);
32055
+ doc.setFont("Helvetica", "normal", "bold");
32056
+ doc.text(schoolName.length <= 18 ? schoolName : splitShoolName[0] + "...", (WIDTH_PAPER - schoolWidth) / 2 + 15, 40);
31925
32057
  doc.setFontSize(10);
31926
32058
  doc.setFont("Helvetica", "italic", "normal");
31927
32059
  doc.text("From: " + moment(startTime).format("DD/MM/YYYY"), 310, 40);
@@ -31938,7 +32070,7 @@ var DashboardToPDF = function DashboardToPDF(props) {
31938
32070
  var line = 85;
31939
32071
  var left = 20;
31940
32072
 
31941
- var _temp38 = function () {
32073
+ var _temp36 = function () {
31942
32074
  if (selectedToPDF.includes(averageStudentSafetyName)) {
31943
32075
  return Promise.resolve(createImageHeader()).then(function () {
31944
32076
  doc.setFontSize(14);
@@ -31948,16 +32080,19 @@ var DashboardToPDF = function DashboardToPDF(props) {
31948
32080
  return Promise.resolve(html2canvas(chart)).then(function (canvas) {
31949
32081
  function _temp3() {
31950
32082
  left = 20;
31951
- doc.addImage(canvas.toDataURL("image/png"), 10, line + 20, 420, heightChart);
31952
- line = line + heightChart + 30;
32083
+ var chartWidth = 420;
32084
+ var chartHeight = chart && chart.clientWidth ? chartWidth * chart.clientHeight / chart.clientWidth : heightChart;
32085
+ doc.addImage(canvas.toDataURL("image/png"), 10, line + 20, chartWidth, chartHeight);
32086
+ chartCount++;
31953
32087
 
31954
- if (line + 150 > HEIGHT_PAPER) {
32088
+ if (chartCount < selectedToPDF.length) {
31955
32089
  doc.addPage();
31956
32090
  line = 80;
31957
32091
  left = 20;
31958
32092
  }
31959
32093
  }
31960
32094
 
32095
+ line += 20;
31961
32096
  var lineOptionCheckIn = line;
31962
32097
  doc.setFontSize(8);
31963
32098
  var questions = safetyData.map(function (r) {
@@ -31984,7 +32119,7 @@ var DashboardToPDF = function DashboardToPDF(props) {
31984
32119
 
31985
32120
  if (questionText != "") {
31986
32121
  doc.setDrawColor(0);
31987
- doc.setFillColor(COLOR_CHART_AND_PERCENTS[indexResult]);
32122
+ doc.setFillColor("#0F9655");
31988
32123
  doc.roundedRect(left, _line + 5, 5, 5, 1, 1, "F");
31989
32124
  doc.setFont("Helvetica", "normal", "bold");
31990
32125
  doc.text(questionText + ":", left + 8, _line + 10);
@@ -32026,7 +32161,7 @@ var DashboardToPDF = function DashboardToPDF(props) {
32026
32161
  }
32027
32162
  }();
32028
32163
 
32029
- return _temp38 && _temp38.then ? _temp38.then(_temp39) : _temp39(_temp38);
32164
+ return _temp36 && _temp36.then ? _temp36.then(_temp37) : _temp37(_temp36);
32030
32165
  }, function (err) {
32031
32166
  console.log(err);
32032
32167
  dispatch(marioCore.setAlert({
@@ -32035,7 +32170,7 @@ var DashboardToPDF = function DashboardToPDF(props) {
32035
32170
  }));
32036
32171
  });
32037
32172
 
32038
- return Promise.resolve(_temp43 && _temp43.then ? _temp43.then(_temp42) : _temp42(_temp43));
32173
+ return Promise.resolve(_temp41 && _temp41.then ? _temp41.then(_temp40) : _temp40(_temp41));
32039
32174
  } catch (e) {
32040
32175
  return Promise.reject(e);
32041
32176
  }
@@ -32087,7 +32222,8 @@ var DashboardToPDF = function DashboardToPDF(props) {
32087
32222
  months: monthsOneToOne,
32088
32223
  dayOfWeek: dayOfWeekOneToOne,
32089
32224
  avgQuestionLastMonth: avgQuestionLastMonth,
32090
- timeOfDay: timeOfDay
32225
+ timeOfDay: timeOfDay,
32226
+ isPrint: true
32091
32227
  })), React__default.createElement("div", {
32092
32228
  id: "success_indicators",
32093
32229
  style: {
@@ -32102,21 +32238,38 @@ var DashboardToPDF = function DashboardToPDF(props) {
32102
32238
  months: monthsOneToOne,
32103
32239
  dayOfWeek: dayOfWeekOneToOne,
32104
32240
  timeOfDay: timeOfDay,
32105
- colors: ["#73C8E5", "#FFB04F", "#D7B0DE", "#E56362", "#5A7F05", "#D3D3D3"]
32241
+ colors: ["#73C8E5", "#FFB04F", "#D7B0DE", "#E56362", "#5A7F05", "#D3D3D3"],
32242
+ isPrint: true
32106
32243
  })), React__default.createElement("div", {
32107
- id: "student_distribution",
32244
+ id: overallReadinessToLearn,
32108
32245
  style: {
32109
32246
  display: "block",
32110
32247
  width: "45%"
32111
32248
  }
32112
- }, React__default.createElement(BubbleChartCustom$1, {
32113
- data: readinessToLearning
32249
+ }, React__default.createElement(GenerateChartData, {
32250
+ isPrint: true,
32251
+ colors: ["#D9EEE4", "#FAF0F0"],
32252
+ name: t(overallReadinessToLearn),
32253
+ typeChart: TYPECHART.DONUT,
32254
+ months: [],
32255
+ activeColumn: [true, true],
32256
+ avgQuestionLastMonth: dataOverallReadyToLearn.overViewQuestionLastMonth,
32257
+ series: dataOverallReadyToLearn.resultQuestion,
32258
+ timeOfDay: timeOfDay,
32259
+ dayOfWeek: [],
32260
+ width: 320,
32261
+ height: 320
32114
32262
  })), React__default.createElement("div", {
32115
- id: "student_stress_by_zone",
32263
+ id: studentDistribution,
32116
32264
  style: {
32117
32265
  display: "block",
32118
32266
  width: "45%"
32119
32267
  }
32268
+ }, React__default.createElement(BubbleChartCustom$1, {
32269
+ data: readinessToLearning,
32270
+ isPrint: true
32271
+ })), React__default.createElement("div", {
32272
+ id: "student_stress_by_zone"
32120
32273
  }, React__default.createElement(StudentPressureChart, {
32121
32274
  studentPressure: studentPressure
32122
32275
  })), React__default.createElement("div", {
@@ -32133,11 +32286,19 @@ var DashboardToPDF = function DashboardToPDF(props) {
32133
32286
  months: monthsConference,
32134
32287
  dayOfWeek: dayOfWeekConference,
32135
32288
  avgQuestionLastMonth: avgConferenceLastMonth,
32136
- timeOfDay: timeOfDay
32289
+ timeOfDay: timeOfDay,
32290
+ isPrint: true
32137
32291
  })), React__default.createElement("div", {
32138
- id: "learning_strategy"
32292
+ style: {
32293
+ display: "block",
32294
+ width: "75%"
32295
+ }
32139
32296
  }, React__default.createElement(TopLearningStrategy$1, {
32140
- data: topLearningStrategiesData
32297
+ data: topLearningStrategiesData,
32298
+ learningStrategyId: topLearningStrategyName
32299
+ })), React__default.createElement("div", null, React__default.createElement(TopLearningStrategy$1, {
32300
+ data: topLearningStrategiesData,
32301
+ topLearningStrategyId: topMostUsedStrategiesName
32141
32302
  }))), React__default.createElement("div", {
32142
32303
  className: "" + styles$1["image-logo"],
32143
32304
  id: "header-logo"
@@ -32314,7 +32475,8 @@ var Dashboard = function Dashboard() {
32314
32475
  avgQuestionLastMonth = _useChartDatas.avgQuestionLastMonth,
32315
32476
  studentPressure = _useChartDatas.studentPressure,
32316
32477
  dataOverallReadyToLearn = _useChartDatas.dataOverallReadyToLearn,
32317
- readinessToLearning = _useChartDatas.readinessToLearning;
32478
+ readinessToLearning = _useChartDatas.readinessToLearning,
32479
+ listTotalTime = _useChartDatas.listTotalTime;
32318
32480
 
32319
32481
  var _useBehavior = useBehavior(),
32320
32482
  chartIsOpened = _useBehavior.chartIsOpened,
@@ -32403,7 +32565,9 @@ var Dashboard = function Dashboard() {
32403
32565
  dayOfWeekConference: dayOfWeekConference,
32404
32566
  avgConferenceLastMonth: avgConferenceLastMonth,
32405
32567
  readinessToLearning: readinessToLearning,
32406
- studentPressure: studentPressure
32568
+ studentPressure: studentPressure,
32569
+ dataOverallReadyToLearn: dataOverallReadyToLearn,
32570
+ schoolName: listTotalTime.schoolName
32407
32571
  }))), React__default.createElement("div", {
32408
32572
  className: "d-flex align-items-center justify-content-between"
32409
32573
  }, React__default.createElement("div", {
@@ -33905,7 +34069,7 @@ var TYPECHART$1;
33905
34069
  TYPECHART[TYPECHART["BOTH"] = 3] = "BOTH";
33906
34070
  })(TYPECHART$1 || (TYPECHART$1 = {}));
33907
34071
 
33908
- var COLOR_CHART_AND_PERCENTS$1 = ["#73C8E5", "#97AFB9", "#FFB04F", "#FF7670", "#00B8B2", "#00B8FF", "#C6A762", "#C94645", "#006E60", "#336DDA", "#994700"];
34072
+ var COLOR_CHART_AND_PERCENTS = ["#73C8E5", "#97AFB9", "#FFB04F", "#FF7670", "#00B8B2", "#00B8FF", "#C6A762", "#C94645", "#006E60", "#336DDA", "#994700"];
33909
34073
 
33910
34074
  var COLOR_CHART_AND_PIE = ["#5A7F05", "#C94645", "#FFB04F"];
33911
34075
  var COLOR_LABEL_PIE = ["#006E60", "#FF7670", "#994700"];
@@ -33920,7 +34084,7 @@ var INIT_TOP_MOST_SURVEY_USED = {
33920
34084
  sendDateSurvey: new Date(),
33921
34085
  percentSurvey: 0
33922
34086
  };
33923
- var COLOR_CHART_AND_PERCENTS$2 = ["#73C8E5", "#97AFB9", "#FFB04F", "#FF7670", "#00B8B2", "#00B8FF", "#C6A762", "#C94645", "#006E60", "#336DDA", "#994700"];
34087
+ var COLOR_CHART_AND_PERCENTS$1 = ["#73C8E5", "#97AFB9", "#FFB04F", "#FF7670", "#00B8B2", "#00B8FF", "#C6A762", "#C94645", "#006E60", "#336DDA", "#994700"];
33924
34088
  var DEFAULT_START_DATE$1 = moment().subtract(2, 'months').startOf("day").valueOf();
33925
34089
  var DEFAULT_END_DATE$1 = moment().endOf("day").valueOf();
33926
34090
  var CALENDAR_OPTIONS$1 = [{
@@ -34757,13 +34921,13 @@ var optionColumnChartAndPercents$1 = function optionColumnChartAndPercents(month
34757
34921
  fill: {
34758
34922
  opacity: isRidgeCharts ? 0.2 : 1
34759
34923
  },
34760
- colors: COLOR_CHART_AND_PERCENTS$2.filter(function (_, index) {
34924
+ colors: COLOR_CHART_AND_PERCENTS$1.filter(function (_, index) {
34761
34925
  return activeData[index];
34762
34926
  }),
34763
34927
  stroke: {
34764
34928
  curve: "smooth",
34765
34929
  show: true,
34766
- colors: isRidgeCharts ? COLOR_CHART_AND_PERCENTS$2.filter(function (_, index) {
34930
+ colors: isRidgeCharts ? COLOR_CHART_AND_PERCENTS$1.filter(function (_, index) {
34767
34931
  return activeData[index];
34768
34932
  }) : ["#fff"],
34769
34933
  width: 3,
@@ -34853,13 +35017,13 @@ var optionBarChartAndArea = function optionBarChartAndArea(months, activeData, n
34853
35017
  return 0.6;
34854
35018
  })
34855
35019
  },
34856
- colors: COLOR_CHART_AND_PERCENTS$2.filter(function (_, index) {
35020
+ colors: COLOR_CHART_AND_PERCENTS$1.filter(function (_, index) {
34857
35021
  return activeData[index];
34858
35022
  }),
34859
35023
  stroke: {
34860
35024
  curve: "smooth",
34861
35025
  show: true,
34862
- colors: COLOR_CHART_AND_PERCENTS$2.filter(function (_, index) {
35026
+ colors: COLOR_CHART_AND_PERCENTS$1.filter(function (_, index) {
34863
35027
  return activeData[index];
34864
35028
  }),
34865
35029
  width: newseries === null || newseries === void 0 ? void 0 : newseries.map(function (item) {
@@ -35248,7 +35412,7 @@ var ChartViewDashboard = function ChartViewDashboard(_ref) {
35248
35412
  className: "" + styles$2["item-checkbox"],
35249
35413
  key: index
35250
35414
  }, React__default.createElement(CheckboxCustom$1, {
35251
- background: COLOR_CHART_AND_PERCENTS$1[index],
35415
+ background: COLOR_CHART_AND_PERCENTS[index],
35252
35416
  width: 16,
35253
35417
  height: 16,
35254
35418
  isActive: activeColumn[index],
@@ -35298,7 +35462,7 @@ var ChartViewDashboard = function ChartViewDashboard(_ref) {
35298
35462
  }, React__default.createElement("div", {
35299
35463
  className: "" + styles$2["mark-custom"],
35300
35464
  style: {
35301
- backgroundColor: COLOR_CHART_AND_PERCENTS$1[index]
35465
+ backgroundColor: COLOR_CHART_AND_PERCENTS[index]
35302
35466
  }
35303
35467
  }), React__default.createElement("label", {
35304
35468
  className: "" + styles$2["label-legend-custom"]