mario-education 2.4.145-level → 2.4.147-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
@@ -14868,7 +14868,7 @@ var QuestionDetail = function QuestionDetail() {
14868
14868
  setFieldValue("isBeforeSession", !values.isBeforeSession);
14869
14869
  setEditedTrue();
14870
14870
  }
14871
- })), values.isDefaultQuestionSurvey == true && React__default.createElement(reactstrap.Col, {
14871
+ })), parseInt(type) == TYPE_QUESTION.Default && React__default.createElement(reactstrap.Col, {
14872
14872
  md: 12
14873
14873
  }, React__default.createElement(reactstrap.CustomInput, {
14874
14874
  type: "checkbox",
@@ -31568,15 +31568,16 @@ var StudentPressureChart = function StudentPressureChart(_ref) {
31568
31568
  }, [chartWidth, studentPressure]);
31569
31569
  var lineHeight = 20;
31570
31570
  var tooltipHeight = tooltipStudents.length * lineHeight;
31571
+ var maxHeightTooltip = tooltipHeight + 30 > chartHeight - 50 ? chartHeight - 50 : tooltipHeight + 30;
31571
31572
  return React__default.createElement("svg", {
31572
31573
  ref: svgRef,
31573
31574
  width: chartWidth,
31574
31575
  height: chartHeight + 50
31575
31576
  }, !!tooltipVisible && React__default.createElement("g", {
31576
- transform: "translate(" + (tooltipX - 100) + "," + (tooltipY - tooltipHeight - 80) + ")"
31577
+ transform: "translate(" + (tooltipX - 100) + "," + Math.max(0, tooltipY - tooltipHeight - 80) + ")"
31577
31578
  }, React__default.createElement("rect", {
31578
31579
  width: "200",
31579
- height: tooltipHeight + 30,
31580
+ height: maxHeightTooltip + 10,
31580
31581
  fill: "rgba(36, 36, 36, 0.8)",
31581
31582
  rx: "5"
31582
31583
  }), React__default.createElement("text", {
@@ -31585,25 +31586,33 @@ var StudentPressureChart = function StudentPressureChart(_ref) {
31585
31586
  fill: "#fff",
31586
31587
  fontSize: "12px",
31587
31588
  textAnchor: "start"
31588
- }, tooltipStudents.length + " students are " + tooltipVisible), tooltipStudents.map(function (label, index) {
31589
- return React__default.createElement("g", {
31589
+ }, tooltipStudents.length + " students are " + tooltipVisible), React__default.createElement("foreignObject", {
31590
+ x: "0",
31591
+ y: "30",
31592
+ width: "200",
31593
+ height: maxHeightTooltip
31594
+ }, React__default.createElement("div", {
31595
+ style: {
31596
+ overflowY: "auto",
31597
+ maxHeight: maxHeightTooltip - 20 + "px",
31598
+ padding: "5px 5px 5px 10px",
31599
+ color: "#fff",
31600
+ fontSize: "12px"
31601
+ }
31602
+ }, tooltipStudents.map(function (label, index) {
31603
+ return React__default.createElement("div", {
31590
31604
  key: index
31591
- }, React__default.createElement("rect", {
31592
- x: "10",
31593
- y: lineHeight * (index + 1) - 12 + 20,
31594
- width: "4",
31595
- height: "14",
31596
- fill: colorTooltip,
31597
- rx: "10",
31598
- ry: "1"
31599
- }), React__default.createElement("text", {
31600
- x: "25",
31601
- y: lineHeight * (index + 1) + 20,
31602
- fill: "#fff",
31603
- fontSize: "12px",
31604
- textAnchor: "start"
31605
- }, label));
31606
- })));
31605
+ }, React__default.createElement("span", {
31606
+ style: {
31607
+ display: "inline-block",
31608
+ width: "4px",
31609
+ height: "14px",
31610
+ backgroundColor: colorTooltip,
31611
+ borderRadius: "10px",
31612
+ marginRight: "10px"
31613
+ }
31614
+ }), React__default.createElement("span", null, label));
31615
+ })))));
31607
31616
  };
31608
31617
 
31609
31618
  var Dashboard = function Dashboard() {
@@ -31852,7 +31861,15 @@ var Dashboard = function Dashboard() {
31852
31861
  dayOfWeek: dayOfWeekOneToOne,
31853
31862
  timeOfDay: filter.optionDate,
31854
31863
  colors: ["#73C8E5", "#F9F871", "#D7B0DE", "#E56362", "#5A7F05", "#D3D3D3"]
31855
- }))), React__default.createElement("div", {
31864
+ }), React__default.createElement("div", {
31865
+ className: "" + styles$1["mt-15"]
31866
+ }, React__default.createElement("p", {
31867
+ className: "" + styles$1["title-chart"]
31868
+ }, "Student Stress by Zone"), React__default.createElement("div", {
31869
+ className: "" + styles$1["box-chart-pressure"]
31870
+ }, React__default.createElement(StudentPressureChart, {
31871
+ studentPressure: studentPressure
31872
+ }))))), React__default.createElement("div", {
31856
31873
  className: "shadow-lg mb-3 " + styles$1["chart-header-wrapper"]
31857
31874
  }, React__default.createElement(HeaderChart, {
31858
31875
  title: "Learning Progress",
@@ -31874,15 +31891,7 @@ var Dashboard = function Dashboard() {
31874
31891
  avgQuestionLastMonth: []
31875
31892
  }), React__default.createElement(TopLearningStrategy$1, {
31876
31893
  data: topLearningStrategies
31877
- }), React__default.createElement("div", {
31878
- className: "" + styles$1["mt-15"]
31879
- }, React__default.createElement("p", {
31880
- className: "" + styles$1["title-chart"]
31881
- }, t(studentPressureName)), React__default.createElement("div", {
31882
- className: "" + styles$1["box-chart-pressure"]
31883
- }, React__default.createElement(StudentPressureChart, {
31884
- studentPressure: studentPressure
31885
- }))))));
31894
+ }))));
31886
31895
  };
31887
31896
 
31888
31897
  var TypeEnumTemplate;