@apexcura/ui-components 0.0.14-Beta81 → 0.0.14-Beta82

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
@@ -1086,9 +1086,61 @@ var OtpElement = (props) => {
1086
1086
 
1087
1087
  // src/Components/Donut.tsx
1088
1088
  var import_react31 = __toESM(require("react"));
1089
+ var import_highcharts = __toESM(require("highcharts"));
1090
+ var import_highcharts_react_official = __toESM(require("highcharts-react-official"));
1089
1091
  var Donut = (props) => {
1090
- console.log(props);
1091
- return /* @__PURE__ */ import_react31.default.createElement("div", null, "Donut");
1092
+ const chartOptions = {
1093
+ title: {
1094
+ text: "Distribution of Students"
1095
+ },
1096
+ plotOptions: {
1097
+ pie: {
1098
+ innerSize: "70%",
1099
+ dataLabels: {
1100
+ enabled: false,
1101
+ format: "<b>{point.name}</b>: {point.percentage:.1f} %"
1102
+ },
1103
+ showInLegend: true
1104
+ }
1105
+ },
1106
+ series: [
1107
+ {
1108
+ type: "pie",
1109
+ name: "Percentage",
1110
+ data: [
1111
+ {
1112
+ name: "Girls",
1113
+ y: 20,
1114
+ color: "#FF6384"
1115
+ // Custom color for Girls
1116
+ },
1117
+ {
1118
+ name: "Boys",
1119
+ y: 40,
1120
+ color: "#36A2EB"
1121
+ // Custom color for Boys
1122
+ },
1123
+ {
1124
+ name: "Students",
1125
+ y: 40,
1126
+ color: "#FFCE56"
1127
+ // Custom color for Students
1128
+ }
1129
+ ]
1130
+ }
1131
+ ],
1132
+ legend: {
1133
+ enabled: true,
1134
+ align: "left",
1135
+ verticalAlign: "middle",
1136
+ layout: "vertical",
1137
+ labelFormatter: function() {
1138
+ const point = this;
1139
+ return `${point.name}: ${point.y?.toFixed(1)}%`;
1140
+ }
1141
+ }
1142
+ };
1143
+ return /* @__PURE__ */ import_react31.default.createElement(import_highcharts_react_official.default, { highcharts: import_highcharts.default, options: chartOptions });
1092
1144
  };
1093
1145
  // Annotate the CommonJS export names for ESM import in node:
1094
1146
  0 && (module.exports = {
package/dist/index.mjs CHANGED
@@ -1025,9 +1025,61 @@ var OtpElement = (props) => {
1025
1025
 
1026
1026
  // src/Components/Donut.tsx
1027
1027
  import React31 from "react";
1028
+ import Highcharts from "highcharts";
1029
+ import HighchartsReact from "highcharts-react-official";
1028
1030
  var Donut = (props) => {
1029
- console.log(props);
1030
- return /* @__PURE__ */ React31.createElement("div", null, "Donut");
1031
+ const chartOptions = {
1032
+ title: {
1033
+ text: "Distribution of Students"
1034
+ },
1035
+ plotOptions: {
1036
+ pie: {
1037
+ innerSize: "70%",
1038
+ dataLabels: {
1039
+ enabled: false,
1040
+ format: "<b>{point.name}</b>: {point.percentage:.1f} %"
1041
+ },
1042
+ showInLegend: true
1043
+ }
1044
+ },
1045
+ series: [
1046
+ {
1047
+ type: "pie",
1048
+ name: "Percentage",
1049
+ data: [
1050
+ {
1051
+ name: "Girls",
1052
+ y: 20,
1053
+ color: "#FF6384"
1054
+ // Custom color for Girls
1055
+ },
1056
+ {
1057
+ name: "Boys",
1058
+ y: 40,
1059
+ color: "#36A2EB"
1060
+ // Custom color for Boys
1061
+ },
1062
+ {
1063
+ name: "Students",
1064
+ y: 40,
1065
+ color: "#FFCE56"
1066
+ // Custom color for Students
1067
+ }
1068
+ ]
1069
+ }
1070
+ ],
1071
+ legend: {
1072
+ enabled: true,
1073
+ align: "left",
1074
+ verticalAlign: "middle",
1075
+ layout: "vertical",
1076
+ labelFormatter: function() {
1077
+ const point = this;
1078
+ return `${point.name}: ${point.y?.toFixed(1)}%`;
1079
+ }
1080
+ }
1081
+ };
1082
+ return /* @__PURE__ */ React31.createElement(HighchartsReact, { highcharts: Highcharts, options: chartOptions });
1031
1083
  };
1032
1084
  export {
1033
1085
  AddMoreTable,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@apexcura/ui-components",
3
- "version": "0.0.14-Beta81",
3
+ "version": "0.0.14-Beta82",
4
4
  "description": "Apex cura React components library",
5
5
  "keywords": [
6
6
  "apex cura",