sag_components 1.0.521 → 1.0.522
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.
|
@@ -39,13 +39,13 @@ const TotalDoughnutChart = props => {
|
|
|
39
39
|
if (!DoughnutChartContainerRef) {
|
|
40
40
|
return;
|
|
41
41
|
}
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
42
|
+
|
|
43
|
+
// let { offsetWidth, offsetHeight } = DoughnutChartContainerRef?.current;
|
|
44
|
+
|
|
45
|
+
// offsetWidth = offsetWidth / 3;
|
|
46
|
+
// offsetHeight = offsetHeight / 3;
|
|
47
|
+
// console.log("DoughnutChartContainerRef 2", offsetWidth, offsetHeight);
|
|
48
|
+
|
|
49
49
|
const {
|
|
50
50
|
current
|
|
51
51
|
} = DoughnutChartContainerRef;
|
|
@@ -147,12 +147,12 @@ const TotalDoughnutChart = props => {
|
|
|
147
147
|
}, /*#__PURE__*/_react.default.createElement(_TotalDoughnutChart.CurrencySign, {
|
|
148
148
|
id: "CurrencySign"
|
|
149
149
|
}, currencySign ? (0, _CommonFunctions.getCurrencySign)(currencyType, value) : ""), dotCut ? (0, _CommonFunctions.getFormattedValue)(value) : (0, _CommonFunctions.getNumberWithCommas)(value), dotCut ? (0, _CommonFunctions.getFormattedUnits)(value) : ""), addingBenchmark && /*#__PURE__*/_react.default.createElement(_Benchmark.Benchmark, null))), /*#__PURE__*/_react.default.createElement(_TotalDoughnutChart.DoughnutChartAndLegendContainer, {
|
|
150
|
-
id: "DoughnutChartAndLegendContainer"
|
|
150
|
+
id: "DoughnutChartAndLegendContainer",
|
|
151
|
+
ref: DoughnutChartContainerRef
|
|
151
152
|
}, /*#__PURE__*/_react.default.createElement(_TotalDoughnutChart.DoughnutChartContainer, {
|
|
152
153
|
id: "DoughnutChartContainer",
|
|
153
154
|
width: width,
|
|
154
|
-
height: height
|
|
155
|
-
ref: DoughnutChartContainerRef
|
|
155
|
+
height: height
|
|
156
156
|
}, /*#__PURE__*/_react.default.createElement(_recharts.ResponsiveContainer, null, /*#__PURE__*/_react.default.createElement(_recharts.PieChart, null, /*#__PURE__*/_react.default.createElement(_recharts.Pie, {
|
|
157
157
|
fill: "#8884d8",
|
|
158
158
|
dataKey: "value",
|
|
@@ -19,7 +19,7 @@ const CurrencySignAndFormattedValueContainer = exports.CurrencySignAndFormattedV
|
|
|
19
19
|
const CurrencySign = exports.CurrencySign = _styledComponents.default.span(_templateObject8 || (_templateObject8 = (0, _taggedTemplateLiteral2.default)(["\n font-weight: 500;\n font-size: 16px;\n @media (max-width: 1536px) {\n font-size: 14px;\n }\n @media (max-width: 1366px) {\n font-size: 11px;\n }\n"])));
|
|
20
20
|
const FormattedValue = exports.FormattedValue = _styledComponents.default.div(_templateObject9 || (_templateObject9 = (0, _taggedTemplateLiteral2.default)(["\n font-weight: 500;\n font-size: 40px;\n @media (max-width: 1536px) {\n font-size: 24px;\n } \n @media (max-width: 1366px) {\n font-size: 20px;\n }\n"])));
|
|
21
21
|
const DoughnutChartAndLegendContainer = exports.DoughnutChartAndLegendContainer = _styledComponents.default.div(_templateObject10 || (_templateObject10 = (0, _taggedTemplateLiteral2.default)(["\n display: flex;\n justify-content: space-between;\n margin-top: auto;\n padding: 0 20px;\n"])));
|
|
22
|
-
const DoughnutChartContainer = exports.DoughnutChartContainer = _styledComponents.default.div(_templateObject11 || (_templateObject11 = (0, _taggedTemplateLiteral2.default)(["\n display: flex;\n //align-items: center;\n position: relative; \n min-width: 45%;\n flex-basis: 45%;\n min-height: 6rem;\n"])));
|
|
22
|
+
const DoughnutChartContainer = exports.DoughnutChartContainer = _styledComponents.default.div(_templateObject11 || (_templateObject11 = (0, _taggedTemplateLiteral2.default)(["\n //display: flex;\n //align-items: center;\n //position: relative; \n min-width: 45%;\n flex-basis: 45%;\n min-height: 6rem;\n"])));
|
|
23
23
|
const LegendContainer = exports.LegendContainer = _styledComponents.default.div(_templateObject12 || (_templateObject12 = (0, _taggedTemplateLiteral2.default)(["\n padding-left: 10px;\n display: flex;\n flex-direction: column;\n justify-content: space-evenly;\n"])));
|
|
24
24
|
const LegendControlsContainer = exports.LegendControlsContainer = _styledComponents.default.div(_templateObject13 || (_templateObject13 = (0, _taggedTemplateLiteral2.default)(["\n display: flex;\n gap: 0.5rem;\n align-items: center;\n margin-bottom: 0.375rem;\n"])));
|
|
25
25
|
const LegendTitleAndFormatedValueContainer = exports.LegendTitleAndFormatedValueContainer = _styledComponents.default.div(_templateObject14 || (_templateObject14 = (0, _taggedTemplateLiteral2.default)(["\n flex-grow: 1;\n"])));
|