@quillsql/react 2.16.18 → 2.16.20

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.cjs CHANGED
@@ -19976,6 +19976,7 @@ async function cleanDashboardItem({
19976
19976
  pivotRows: pivotTable ? pivotTable.rows : void 0,
19977
19977
  pivotColumns: pivotTable ? pivotTable.columns : void 0,
19978
19978
  compareRows: item.compareRows,
19979
+ showLegend: item.showLegend ?? false,
19979
19980
  columns: processedColumns.map((column) => {
19980
19981
  return {
19981
19982
  field: column.field,
@@ -20242,6 +20243,7 @@ function createInitialFormData(columns) {
20242
20243
  ],
20243
20244
  xAxisLabel: "",
20244
20245
  chartType: firstNumberColumn ? "line" : "table",
20246
+ showLegend: false,
20245
20247
  pivot: null,
20246
20248
  template: true,
20247
20249
  referenceLines: []
@@ -20329,7 +20331,8 @@ function extractAllReportValuesFromQuillInternalReport(reportInternal) {
20329
20331
  pivotRows: reportInternal.pivotRows,
20330
20332
  pivotColumns: reportInternal.pivotColumns,
20331
20333
  pivotRowCount: reportInternal.pivotRowCount,
20332
- filterMap: reportInternal.filterMap
20334
+ filterMap: reportInternal.filterMap,
20335
+ showLegend: reportInternal.showLegend
20333
20336
  };
20334
20337
  }
20335
20338
  async function fetchReportRows({
@@ -25507,7 +25510,7 @@ var BarList = import_react4.default.forwardRef((props, ref) => {
25507
25510
  var BarList_default = BarList;
25508
25511
 
25509
25512
  // src/components/Chart/PieChart.tsx
25510
- var import_react5 = __toESM(require("react"), 1);
25513
+ var import_react13 = __toESM(require("react"), 1);
25511
25514
  var import_recharts = require("recharts");
25512
25515
 
25513
25516
  // src/utils/color.ts
@@ -25867,529 +25870,62 @@ function HSLtoRGB(h, s, l) {
25867
25870
  // src/components/Chart/PieChart.tsx
25868
25871
  init_util();
25869
25872
  init_valueFormatter();
25870
- var import_jsx_runtime4 = require("react/jsx-runtime");
25871
- var defaultValueFormatter = (value) => (value * 1).toFixed(1) + "%";
25872
- var parseData2 = (data, colors, categoryKey, valueKey) => {
25873
- const maxItems = 20;
25874
- const slicedData = deepCopy(data).slice(0, maxItems);
25875
- const totalValue = slicedData.reduce(
25876
- (acc, dataPoint) => (
25877
- // Big(acc)
25878
- // .add(Big(Number(dataPoint[valueKey]) ?? 0))
25879
- // .toNumber(),
25880
- acc + parseFloat(dataPoint[valueKey] ?? "0")
25881
- ),
25882
- 0
25883
- );
25884
- slicedData.forEach((dataPoint) => {
25885
- const rawValue = parseFloat(dataPoint[valueKey] ?? "0");
25886
- dataPoint[valueKey] = totalValue ? rawValue * 100 / totalValue : data.length > maxItems ? 100 / (maxItems + 1) : 100 / slicedData.length;
25887
- dataPoint[`raw_${valueKey}`] = parseFloat(rawValue.toFixed(2));
25888
- });
25889
- const parsedData = slicedData.map((dataPoint, idx) => {
25890
- const baseColor = colors.length > 0 ? idx < colors.length ? colors[idx] : colors[colors.length - 1] : "#808080";
25891
- return {
25892
- ...dataPoint,
25893
- color: baseColor,
25894
- fill: baseColor
25895
- };
25896
- });
25897
- if (data.length > maxItems) {
25898
- const otherData = data.slice(maxItems);
25899
- const otherSum = otherData.reduce(
25900
- (acc, dataPoint) => (
25901
- // Big(acc)
25902
- // .add(Big(Number(dataPoint[valueKey])) ?? 0)
25903
- // .toNumber(),
25904
- acc + parseFloat(dataPoint[valueKey] ?? "0")
25905
- ),
25906
- 0
25907
- );
25908
- const otherColor = colors.length > 0 ? colors[colors.length - 1] : "#808080";
25909
- const normalizedOtherSum = totalValue ? otherSum * 100 / totalValue : 100 / (maxItems + 1);
25910
- parsedData.push({
25911
- [categoryKey]: "Other",
25912
- [valueKey]: normalizedOtherSum,
25913
- [`raw_${valueKey}`]: parseFloat(otherSum.toFixed(2)),
25914
- color: otherColor,
25915
- fill: otherColor
25916
- });
25917
- }
25918
- return parsedData;
25919
- };
25920
- var ChartTooltipFrame = ({
25921
- children,
25922
- theme
25923
- }) => /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
25924
- "div",
25925
- {
25926
- style: {
25927
- borderStyle: "solid",
25928
- borderColor: theme?.borderColor || "#E5E7EB",
25929
- borderWidth: 1,
25930
- background: theme?.backgroundColor || "#ffffff",
25931
- fontSize: theme?.fontSize || "14px",
25932
- borderRadius: "6px",
25933
- boxShadow: "0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05)"
25934
- },
25935
- children
25936
- }
25937
- );
25938
- var ChartTooltipRow = ({
25939
- value,
25940
- rawValue,
25941
- valueKey,
25942
- valueKeyLabel,
25943
- name: name2,
25944
- // color,
25945
- theme
25946
- }) => /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(
25947
- "div",
25948
- {
25949
- style: {
25950
- display: "flex",
25951
- flexDirection: "column",
25952
- gap: 2,
25953
- minWidth: 150,
25954
- position: "relative"
25955
- },
25956
- children: [
25957
- /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
25958
- "div",
25959
- {
25960
- style: {
25961
- display: "flex",
25962
- alignItems: "center",
25963
- width: "100%"
25964
- // paddingLeft: '24px',
25965
- },
25966
- children: /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(
25967
- "span",
25968
- {
25969
- style: {
25970
- flex: 1,
25971
- display: "flex",
25972
- alignItems: "center",
25973
- justifyContent: "space-between"
25974
- },
25975
- children: [
25976
- /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
25977
- "p",
25978
- {
25979
- style: {
25980
- marginTop: 0,
25981
- marginBottom: 0,
25982
- marginRight: "24px",
25983
- fontFamily: theme?.fontFamily,
25984
- color: theme?.primaryTextColor,
25985
- fontSize: theme?.fontSizeSmall || "14px",
25986
- fontWeight: theme?.fontWeightMedium || "500",
25987
- minWidth: "60px"
25988
- },
25989
- children: name2
25990
- }
25991
- ),
25992
- /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
25993
- "p",
25994
- {
25995
- style: {
25996
- marginTop: 0,
25997
- marginBottom: 0,
25998
- fontFamily: theme?.fontFamily,
25999
- color: theme?.primaryTextColor,
26000
- fontSize: theme?.fontSizeSmall || "14px",
26001
- fontWeight: theme?.fontWeightMedium || "500",
26002
- minWidth: "40px",
26003
- textAlign: "right"
26004
- },
26005
- children: value
26006
- }
26007
- )
26008
- ]
26009
- }
26010
- )
26011
- }
26012
- ),
26013
- (rawValue || valueKey) && /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
26014
- "div",
26015
- {
26016
- style: {
26017
- display: "flex",
26018
- alignItems: "center",
26019
- width: "100%",
26020
- // paddingLeft: '24px',
26021
- justifyContent: "space-between"
26022
- },
26023
- children: /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(
26024
- "span",
26025
- {
26026
- style: {
26027
- flex: 1,
26028
- display: "flex",
26029
- alignItems: "center",
26030
- justifyContent: "space-between"
26031
- },
26032
- children: [
26033
- /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
26034
- "p",
26035
- {
26036
- style: {
26037
- marginTop: 0,
26038
- marginBottom: 0,
26039
- marginRight: "24px",
26040
- fontFamily: theme?.fontFamily,
26041
- color: theme?.primaryTextColor,
26042
- fontSize: theme?.fontSizeSmall || "14px",
26043
- fontWeight: theme?.fontWeightMedium || "500",
26044
- minWidth: "60px"
26045
- },
26046
- children: valueKeyLabel || valueKey
26047
- }
26048
- ),
26049
- /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
26050
- "p",
26051
- {
26052
- style: {
26053
- marginTop: 0,
26054
- marginBottom: 0,
26055
- fontFamily: theme?.fontFamily,
26056
- color: theme?.primaryTextColor,
26057
- fontSize: theme?.fontSizeSmall || "14px",
26058
- fontWeight: theme?.fontWeightMedium || "500",
26059
- minWidth: "40px",
26060
- textAlign: "right"
26061
- },
26062
- children: rawValue
26063
- }
26064
- )
26065
- ]
26066
- }
26067
- )
26068
- }
26069
- )
26070
- ]
26071
- }
26072
- );
26073
- var DonutChartTooltip = ({
26074
- active,
26075
- payload,
26076
- valueFormatter: valueFormatter2,
26077
- theme,
26078
- yAxisFields
26079
- }) => {
26080
- if (active && payload[0]) {
26081
- const payloadRow = payload[0];
26082
- const rawValue = payloadRow.payload[`raw_${payloadRow.dataKey}`];
26083
- const field = yAxisFields?.find((f) => f.field === payloadRow.dataKey);
26084
- const formattedRawValue = quillFormat({
26085
- value: rawValue?.toString() || "",
26086
- format: field?.format || "string"
26087
- });
26088
- return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(ChartTooltipFrame, { theme, children: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
26089
- "div",
26090
- {
26091
- style: {
26092
- paddingLeft: "1rem",
26093
- paddingRight: "1rem",
26094
- paddingTop: "8px",
26095
- paddingBottom: "8px"
26096
- },
26097
- children: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
26098
- ChartTooltipRow,
26099
- {
26100
- value: valueFormatter2(payloadRow.value),
26101
- rawValue: rawValue ? formattedRawValue : void 0,
26102
- valueKey: payloadRow.dataKey,
26103
- valueKeyLabel: field?.label,
26104
- name: payloadRow.name,
26105
- color: payloadRow.payload.color,
26106
- theme
26107
- }
26108
- )
26109
- }
26110
- ) });
26111
- }
26112
- return null;
26113
- };
26114
- var renderCustomizedLabel = ({
26115
- cx,
26116
- cy,
26117
- name: name2,
26118
- midAngle,
26119
- outerRadius,
26120
- percent,
26121
- tooltipPayload,
26122
- theme,
26123
- yAxisFields
26124
- }) => {
26125
- const RADIAN = Math.PI / 180;
26126
- const radius = outerRadius + 25;
26127
- const x = cx + radius * Math.cos(-midAngle * RADIAN);
26128
- const y = cy + radius * Math.sin(-midAngle * RADIAN);
26129
- const category = tooltipPayload?.[0]?.dataKey;
26130
- const rawValue = tooltipPayload?.[0]?.payload?.[`raw_${category}`];
26131
- const displayValue = rawValue ? `${rawValue}` : `${(percent * 100).toFixed(0)}%`;
26132
- const isRightSide = x > cx;
26133
- const isTopSide = y < cy;
26134
- const field = yAxisFields?.find(
26135
- (f) => f.field === tooltipPayload?.[0]?.dataKey
26136
- );
26137
- const formattedDisplayValue = quillFormat({
26138
- value: displayValue?.toString() || "",
26139
- format: field?.format || "string"
26140
- });
26141
- const padding = 10;
26142
- let textX;
26143
- if (isRightSide) {
26144
- textX = x + padding;
26145
- } else {
26146
- const longestText = name2.length > displayValue.length ? name2 : displayValue;
26147
- const estimatedTextWidth = longestText.length * 7;
26148
- textX = x - padding - estimatedTextWidth;
26149
- }
26150
- return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("g", { children: isTopSide ? /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(import_jsx_runtime4.Fragment, { children: [
26151
- /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
26152
- "text",
26153
- {
26154
- x: textX,
26155
- y: y - 8,
26156
- fill: theme?.secondaryTextColor,
26157
- textAnchor: "start",
26158
- dominantBaseline: "central",
26159
- fontSize: theme?.fontSize || "14px",
26160
- fontWeight: "500",
26161
- fontFamily: theme?.fontFamily,
26162
- children: name2
26163
- }
26164
- ),
26165
- /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
26166
- "text",
26167
- {
26168
- x: textX,
26169
- y: y + 8,
26170
- fill: theme?.secondaryTextColor,
26171
- textAnchor: "start",
26172
- dominantBaseline: "central",
26173
- fontSize: theme?.fontSize || "14px",
26174
- fontWeight: "400",
26175
- fontFamily: theme?.fontFamily,
26176
- children: formattedDisplayValue
26177
- }
26178
- )
26179
- ] }) : /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(import_jsx_runtime4.Fragment, { children: [
26180
- /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
26181
- "text",
26182
- {
26183
- x: textX,
26184
- y: y + 8,
26185
- fill: theme?.secondaryTextColor,
26186
- textAnchor: "start",
26187
- dominantBaseline: "central",
26188
- fontSize: theme?.fontSize || "14px",
26189
- fontWeight: "400",
26190
- fontFamily: theme?.fontFamily,
26191
- children: formattedDisplayValue
26192
- }
26193
- ),
26194
- /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
26195
- "text",
26196
- {
26197
- x: textX,
26198
- y: y - 8,
26199
- fill: theme?.secondaryTextColor,
26200
- textAnchor: "start",
26201
- dominantBaseline: "central",
26202
- fontSize: theme?.fontSize || "14px",
26203
- fontWeight: "500",
26204
- fontFamily: theme?.fontFamily,
26205
- children: name2
26206
- }
26207
- )
26208
- ] }) });
26209
- };
26210
- var PieChartWrapper = import_react5.default.forwardRef(
26211
- (props, ref) => {
26212
- const {
26213
- category = "pct_of_the_total",
26214
- index = "status",
26215
- data,
26216
- colors = [],
26217
- colorMap = {},
26218
- variant = "donut",
26219
- valueFormatter: valueFormatter2 = defaultValueFormatter,
26220
- className,
26221
- containerStyle,
26222
- theme,
26223
- onClickChartElement,
26224
- yAxisFields,
26225
- showLegend = false,
26226
- ...other
26227
- } = props;
26228
- const isDonut = variant == "donut";
26229
- if (!data || data.length === 0) {
26230
- return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
26231
- "div",
26232
- {
26233
- style: {
26234
- display: "flex",
26235
- flex: "1 0 auto",
26236
- // height: '100%',
26237
- margin: "auto",
26238
- justifyContent: "center",
26239
- alignItems: "center",
26240
- fontSize: 13,
26241
- fontFamily: theme?.fontFamily,
26242
- color: theme.secondaryTextColor,
26243
- ...containerStyle
26244
- },
26245
- className,
26246
- children: "No results"
26247
- }
26248
- );
26249
- }
26250
- return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
26251
- "div",
26252
- {
26253
- ref,
26254
- className,
26255
- style: {
26256
- width: "100%",
26257
- display: "flex",
26258
- flexDirection: "row",
26259
- alignItems: "center",
26260
- justifyContent: "center",
26261
- boxSizing: "content-box",
26262
- ...containerStyle
26263
- },
26264
- ...other,
26265
- children: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
26266
- import_recharts.ResponsiveContainer,
26267
- {
26268
- width: "100%",
26269
- height: "100%",
26270
- minWidth: 0,
26271
- minHeight: 0,
26272
- children: /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(import_recharts.PieChart, { children: [
26273
- /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
26274
- import_recharts.Pie,
26275
- {
26276
- data: parseData2(
26277
- data,
26278
- (() => {
26279
- const colorArray = colorMap[category] && colorMap[category]["primary"] && colorMap[category]["primary"] || colors;
26280
- const containsCssVars = colorArray.some(
26281
- (color2) => typeof color2 === "string" && color2.includes("var(")
26282
- );
26283
- if (containsCssVars) {
26284
- return Array.from({ length: data.length }).map(
26285
- (_, idx) => colorArray[idx % colorArray.length] ?? colorArray[colorArray.length - 1] ?? "#808080"
26286
- );
26287
- }
26288
- return colorArray.length >= data.length ? colorArray.slice(0, data.length) : generateArrayFromColor(colorArray, data.length);
26289
- })(),
26290
- index,
26291
- category
26292
- ),
26293
- cx: "50%",
26294
- cy: "50%",
26295
- startAngle: 90,
26296
- endAngle: -270,
26297
- innerRadius: isDonut ? showLegend ? "50%" : "70%" : "0%",
26298
- outerRadius: showLegend ? "70%" : "100%",
26299
- paddingAngle: 0,
26300
- dataKey: category,
26301
- nameKey: index,
26302
- isAnimationActive: true,
26303
- onClick: onClickChartElement,
26304
- labelLine: false,
26305
- label: showLegend ? (props2) => renderCustomizedLabel({ ...props2, theme, yAxisFields }) : void 0
26306
- }
26307
- ),
26308
- /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
26309
- import_recharts.Tooltip,
26310
- {
26311
- wrapperStyle: {
26312
- outline: "none"
26313
- },
26314
- content: ({ active, payload }) => {
26315
- return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
26316
- DonutChartTooltip,
26317
- {
26318
- active,
26319
- payload,
26320
- valueFormatter: valueFormatter2,
26321
- theme,
26322
- yAxisFields
26323
- }
26324
- );
26325
- }
26326
- }
26327
- )
26328
- ] })
26329
- }
26330
- )
26331
- }
26332
- );
26333
- }
26334
- );
26335
- var PieChart_default = PieChartWrapper;
26336
25873
 
26337
- // src/components/QuillTable.tsx
26338
- var import_react13 = require("react");
26339
- init_valueFormatter();
25874
+ // src/components/Chart/CustomLegend.tsx
25875
+ var import_react12 = require("react");
26340
25876
 
26341
25877
  // src/components/UiComponents.tsx
26342
- var import_react12 = require("react");
25878
+ var import_react11 = require("react");
26343
25879
 
26344
25880
  // src/assets/ArrowDownHeadIcon.tsx
26345
- var import_jsx_runtime5 = require("react/jsx-runtime");
25881
+ var import_jsx_runtime4 = require("react/jsx-runtime");
26346
25882
 
26347
25883
  // src/assets/ArrowDownRightIcon.tsx
26348
- var import_jsx_runtime6 = require("react/jsx-runtime");
25884
+ var import_jsx_runtime5 = require("react/jsx-runtime");
26349
25885
 
26350
25886
  // src/assets/ArrowDownIcon.tsx
26351
- var import_jsx_runtime7 = require("react/jsx-runtime");
25887
+ var import_jsx_runtime6 = require("react/jsx-runtime");
26352
25888
 
26353
25889
  // src/assets/ArrowRightIcon.tsx
26354
- var import_jsx_runtime8 = require("react/jsx-runtime");
25890
+ var import_jsx_runtime7 = require("react/jsx-runtime");
26355
25891
 
26356
25892
  // src/assets/ArrowRightHeadIcon.tsx
26357
- var import_jsx_runtime9 = require("react/jsx-runtime");
25893
+ var import_jsx_runtime8 = require("react/jsx-runtime");
26358
25894
 
26359
25895
  // src/assets/ArrowLeftHeadIcon.tsx
26360
- var import_jsx_runtime10 = require("react/jsx-runtime");
25896
+ var import_jsx_runtime9 = require("react/jsx-runtime");
26361
25897
 
26362
25898
  // src/assets/DoubleArrowLeftHeadIcon.tsx
26363
- var import_jsx_runtime11 = require("react/jsx-runtime");
25899
+ var import_jsx_runtime10 = require("react/jsx-runtime");
26364
25900
 
26365
25901
  // src/assets/DoubleArrowRightHeadIcon.tsx
26366
- var import_jsx_runtime12 = require("react/jsx-runtime");
25902
+ var import_jsx_runtime11 = require("react/jsx-runtime");
26367
25903
 
26368
25904
  // src/assets/ArrowUpHeadIcon.tsx
26369
- var import_jsx_runtime13 = require("react/jsx-runtime");
25905
+ var import_jsx_runtime12 = require("react/jsx-runtime");
26370
25906
 
26371
25907
  // src/assets/ArrowUpIcon.tsx
26372
- var import_jsx_runtime14 = require("react/jsx-runtime");
25908
+ var import_jsx_runtime13 = require("react/jsx-runtime");
26373
25909
 
26374
25910
  // src/assets/ArrowUpRightIcon.tsx
26375
- var import_jsx_runtime15 = require("react/jsx-runtime");
25911
+ var import_jsx_runtime14 = require("react/jsx-runtime");
26376
25912
 
26377
25913
  // src/assets/CalendarIcon.tsx
26378
- var import_jsx_runtime16 = require("react/jsx-runtime");
25914
+ var import_jsx_runtime15 = require("react/jsx-runtime");
26379
25915
 
26380
25916
  // src/assets/CalendarNormalIcon.tsx
26381
- var import_jsx_runtime17 = require("react/jsx-runtime");
25917
+ var import_jsx_runtime16 = require("react/jsx-runtime");
26382
25918
 
26383
25919
  // src/assets/ExclamationFilledIcon.tsx
26384
- var import_jsx_runtime18 = require("react/jsx-runtime");
26385
- var ExclamationFilledIcon = ({ ...props }) => /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(
25920
+ var import_jsx_runtime17 = require("react/jsx-runtime");
25921
+ var ExclamationFilledIcon = ({ ...props }) => /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
26386
25922
  "svg",
26387
25923
  {
26388
25924
  ...props,
26389
25925
  xmlns: "http://www.w3.org/2000/svg",
26390
25926
  viewBox: "0 0 24 24",
26391
25927
  fill: "currentColor",
26392
- children: /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(
25928
+ children: /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
26393
25929
  "path",
26394
25930
  {
26395
25931
  fillRule: "evenodd",
@@ -26402,20 +25938,20 @@ var ExclamationFilledIcon = ({ ...props }) => /* @__PURE__ */ (0, import_jsx_run
26402
25938
  var ExclamationFilledIcon_default = ExclamationFilledIcon;
26403
25939
 
26404
25940
  // src/assets/SearchIcon.tsx
26405
- var import_jsx_runtime19 = require("react/jsx-runtime");
25941
+ var import_jsx_runtime18 = require("react/jsx-runtime");
26406
25942
 
26407
25943
  // src/assets/XCircleIcon.tsx
26408
- var import_jsx_runtime20 = require("react/jsx-runtime");
25944
+ var import_jsx_runtime19 = require("react/jsx-runtime");
26409
25945
 
26410
25946
  // src/assets/RefreshIcon.tsx
26411
- var import_jsx_runtime21 = require("react/jsx-runtime");
25947
+ var import_jsx_runtime20 = require("react/jsx-runtime");
26412
25948
 
26413
25949
  // src/assets/FilterIcon.tsx
26414
- var import_jsx_runtime22 = require("react/jsx-runtime");
25950
+ var import_jsx_runtime21 = require("react/jsx-runtime");
26415
25951
 
26416
25952
  // src/assets/MoreIcon.tsx
26417
- var import_jsx_runtime23 = require("react/jsx-runtime");
26418
- var MoreIcon = ({ ...props }) => /* @__PURE__ */ (0, import_jsx_runtime23.jsxs)(
25953
+ var import_jsx_runtime22 = require("react/jsx-runtime");
25954
+ var MoreIcon = ({ ...props }) => /* @__PURE__ */ (0, import_jsx_runtime22.jsxs)(
26419
25955
  "svg",
26420
25956
  {
26421
25957
  width: "24",
@@ -26425,20 +25961,20 @@ var MoreIcon = ({ ...props }) => /* @__PURE__ */ (0, import_jsx_runtime23.jsxs)(
26425
25961
  xmlns: "http://www.w3.org/2000/svg",
26426
25962
  ...props,
26427
25963
  children: [
26428
- /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("circle", { cx: "5", cy: "12", r: "2", fill: "currentColor" }),
26429
- /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("circle", { cx: "12", cy: "12", r: "2", fill: "currentColor" }),
26430
- /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("circle", { cx: "19", cy: "12", r: "2", fill: "currentColor" })
25964
+ /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("circle", { cx: "5", cy: "12", r: "2", fill: "currentColor" }),
25965
+ /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("circle", { cx: "12", cy: "12", r: "2", fill: "currentColor" }),
25966
+ /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("circle", { cx: "19", cy: "12", r: "2", fill: "currentColor" })
26431
25967
  ]
26432
25968
  }
26433
25969
  );
26434
25970
  var MoreIcon_default = MoreIcon;
26435
25971
 
26436
25972
  // src/assets/UpLeftArrowsIcon.tsx
26437
- var import_jsx_runtime24 = require("react/jsx-runtime");
25973
+ var import_jsx_runtime23 = require("react/jsx-runtime");
26438
25974
 
26439
25975
  // src/assets/XIcon.tsx
26440
- var import_jsx_runtime25 = require("react/jsx-runtime");
26441
- var XIcon = ({ ...props }) => /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
25976
+ var import_jsx_runtime24 = require("react/jsx-runtime");
25977
+ var XIcon = ({ ...props }) => /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
26442
25978
  "svg",
26443
25979
  {
26444
25980
  ...props,
@@ -26446,7 +25982,7 @@ var XIcon = ({ ...props }) => /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
26446
25982
  viewBox: "0 0 24 24",
26447
25983
  height: "20",
26448
25984
  width: "20",
26449
- children: /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
25985
+ children: /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
26450
25986
  "path",
26451
25987
  {
26452
25988
  fillRule: "evenodd",
@@ -26459,15 +25995,15 @@ var XIcon = ({ ...props }) => /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
26459
25995
  var XIcon_default = XIcon;
26460
25996
 
26461
25997
  // src/components/Chart/ChartSkeleton.tsx
26462
- var import_react6 = require("react");
26463
- var import_jsx_runtime26 = require("react/jsx-runtime");
26464
- var QuillLoadingSkeleton = () => /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(ChartSkeleton, {});
25998
+ var import_react5 = require("react");
25999
+ var import_jsx_runtime25 = require("react/jsx-runtime");
26000
+ var QuillLoadingSkeleton = () => /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(ChartSkeleton, {});
26465
26001
  function ChartSkeleton({
26466
26002
  className,
26467
26003
  containerStyle
26468
26004
  }) {
26469
- const [theme] = (0, import_react6.useContext)(ThemeContext);
26470
- return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
26005
+ const [theme] = (0, import_react5.useContext)(ThemeContext);
26006
+ return /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
26471
26007
  "div",
26472
26008
  {
26473
26009
  style: {
@@ -26477,7 +26013,7 @@ function ChartSkeleton({
26477
26013
  ...containerStyle
26478
26014
  },
26479
26015
  className,
26480
- children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
26016
+ children: /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
26481
26017
  "div",
26482
26018
  {
26483
26019
  style: {
@@ -26487,7 +26023,7 @@ function ChartSkeleton({
26487
26023
  borderRadius: 8,
26488
26024
  overflow: "hidden"
26489
26025
  },
26490
- children: /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)(
26026
+ children: /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)(
26491
26027
  "svg",
26492
26028
  {
26493
26029
  width: "100%",
@@ -26495,7 +26031,7 @@ function ChartSkeleton({
26495
26031
  xmlns: "http://www.w3.org/2000/svg",
26496
26032
  xmlnsXlink: "http://www.w3.org/1999/xlink",
26497
26033
  children: [
26498
- /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
26034
+ /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
26499
26035
  "rect",
26500
26036
  {
26501
26037
  width: "100%",
@@ -26503,7 +26039,7 @@ function ChartSkeleton({
26503
26039
  fill: theme?.loadingStateBackgroundColor || "#F9F9FA"
26504
26040
  }
26505
26041
  ),
26506
- /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("defs", { fill: theme?.loadingStateBackgroundColor || "#F9F9FA", children: /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)(
26042
+ /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("defs", { fill: theme?.loadingStateBackgroundColor || "#F9F9FA", children: /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)(
26507
26043
  "linearGradient",
26508
26044
  {
26509
26045
  id: "skeletonGradient",
@@ -26513,10 +26049,10 @@ function ChartSkeleton({
26513
26049
  y2: "0%",
26514
26050
  gradientUnits: "userSpaceOnUse",
26515
26051
  children: [
26516
- /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("stop", { offset: "0%", stopColor: "rgba(255,255,255,0)" }),
26517
- /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("stop", { offset: "50%", stopColor: "#FEFEFE" }),
26518
- /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("stop", { offset: "100%", stopColor: "rgba(255,255,255,0)" }),
26519
- /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
26052
+ /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("stop", { offset: "0%", stopColor: "rgba(255,255,255,0)" }),
26053
+ /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("stop", { offset: "50%", stopColor: "#FEFEFE" }),
26054
+ /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("stop", { offset: "100%", stopColor: "rgba(255,255,255,0)" }),
26055
+ /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
26520
26056
  "animate",
26521
26057
  {
26522
26058
  attributeName: "x1",
@@ -26526,7 +26062,7 @@ function ChartSkeleton({
26526
26062
  repeatCount: "indefinite"
26527
26063
  }
26528
26064
  ),
26529
- /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
26065
+ /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
26530
26066
  "animate",
26531
26067
  {
26532
26068
  attributeName: "x2",
@@ -26539,7 +26075,7 @@ function ChartSkeleton({
26539
26075
  ]
26540
26076
  }
26541
26077
  ) }),
26542
- /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("rect", { width: "50%", height: "100%", fill: "url(#skeletonGradient)", children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
26078
+ /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("rect", { width: "50%", height: "100%", fill: "url(#skeletonGradient)", children: /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
26543
26079
  "animate",
26544
26080
  {
26545
26081
  attributeName: "x",
@@ -26559,12 +26095,12 @@ function ChartSkeleton({
26559
26095
  }
26560
26096
 
26561
26097
  // src/hooks/useInternalState.tsx
26562
- var import_react7 = require("react");
26098
+ var import_react6 = require("react");
26563
26099
 
26564
26100
  // src/hooks/useOnClickOutside.tsx
26565
- var import_react8 = require("react");
26101
+ var import_react7 = require("react");
26566
26102
  var useOnClickOutside = (ref, handler, listening) => {
26567
- (0, import_react8.useEffect)(() => {
26103
+ (0, import_react7.useEffect)(() => {
26568
26104
  const listener = (event) => {
26569
26105
  if (!ref.current || ref.current.contains(event.target)) {
26570
26106
  return;
@@ -26605,13 +26141,13 @@ var createsStackingContext = (computedStyle) => {
26605
26141
  var useOnClickOutside_default = useOnClickOutside;
26606
26142
 
26607
26143
  // src/hooks/useOnWindowResize.tsx
26608
- var import_react9 = require("react");
26144
+ var import_react8 = require("react");
26609
26145
 
26610
26146
  // src/hooks/useSelectOnKeyDown.tsx
26611
- var import_react10 = require("react");
26147
+ var import_react9 = require("react");
26612
26148
 
26613
26149
  // src/hooks/useResponsiveFirstChildWidth.ts
26614
- var import_react11 = require("react");
26150
+ var import_react10 = require("react");
26615
26151
  var DEFAULT_MIN_WIDTH = 0;
26616
26152
  var parseNumericValue = (value) => {
26617
26153
  if (!value) {
@@ -26659,7 +26195,7 @@ var calculateFirstChildWidth = (element, options) => {
26659
26195
  const clampedWidth = max2 !== void 0 ? Math.min(Math.max(rawWidth, min2), max2) : Math.max(rawWidth, min2);
26660
26196
  return Math.floor(clampedWidth);
26661
26197
  };
26662
- var useIsomorphicLayoutEffect = typeof window !== "undefined" ? import_react11.useLayoutEffect : import_react11.useEffect;
26198
+ var useIsomorphicLayoutEffect = typeof window !== "undefined" ? import_react10.useLayoutEffect : import_react10.useEffect;
26663
26199
  var useResponsiveFirstChildWidth = (containerRef, options = {}) => {
26664
26200
  const {
26665
26201
  gap,
@@ -26667,8 +26203,8 @@ var useResponsiveFirstChildWidth = (containerRef, options = {}) => {
26667
26203
  minWidth = DEFAULT_MIN_WIDTH,
26668
26204
  maxWidth
26669
26205
  } = options;
26670
- const [width, setWidth] = (0, import_react11.useState)(initialWidth);
26671
- const previousWidthRef = (0, import_react11.useRef)(initialWidth);
26206
+ const [width, setWidth] = (0, import_react10.useState)(initialWidth);
26207
+ const previousWidthRef = (0, import_react10.useRef)(initialWidth);
26672
26208
  useIsomorphicLayoutEffect(() => {
26673
26209
  const element = containerRef?.current ?? null;
26674
26210
  if (!element || typeof window === "undefined") {
@@ -26764,8 +26300,8 @@ var getScrollableParent = (element) => {
26764
26300
  };
26765
26301
 
26766
26302
  // src/components/UiComponents.tsx
26767
- var import_jsx_runtime27 = require("react/jsx-runtime");
26768
- var QuillTextInput = (0, import_react12.forwardRef)(
26303
+ var import_jsx_runtime26 = require("react/jsx-runtime");
26304
+ var QuillTextInput = (0, import_react11.forwardRef)(
26769
26305
  ({
26770
26306
  id: id2,
26771
26307
  value,
@@ -26775,10 +26311,10 @@ var QuillTextInput = (0, import_react12.forwardRef)(
26775
26311
  onChange,
26776
26312
  disabled
26777
26313
  }, ref) => {
26778
- const [theme] = (0, import_react12.useContext)(ThemeContext);
26314
+ const [theme] = (0, import_react11.useContext)(ThemeContext);
26779
26315
  const isNumericWidth = typeof width === "number";
26780
26316
  const resolvedWidth = typeof width === "string" ? width : isNumericWidth ? width : "100%";
26781
- return /* @__PURE__ */ (0, import_jsx_runtime27.jsxs)(
26317
+ return /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)(
26782
26318
  "label",
26783
26319
  {
26784
26320
  style: {
@@ -26791,7 +26327,7 @@ var QuillTextInput = (0, import_react12.forwardRef)(
26791
26327
  flex: isNumericWidth ? "0 0 auto" : "1 1 auto"
26792
26328
  },
26793
26329
  children: [
26794
- label && /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
26330
+ label && /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
26795
26331
  "div",
26796
26332
  {
26797
26333
  style: {
@@ -26804,7 +26340,7 @@ var QuillTextInput = (0, import_react12.forwardRef)(
26804
26340
  children: label
26805
26341
  }
26806
26342
  ),
26807
- /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
26343
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
26808
26344
  "input",
26809
26345
  {
26810
26346
  ref,
@@ -26845,13 +26381,13 @@ var MemoizedButton = ({
26845
26381
  tooltipText,
26846
26382
  isLoading
26847
26383
  }) => {
26848
- const [theme] = (0, import_react12.useContext)(ThemeContext);
26849
- return /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
26384
+ const [theme] = (0, import_react11.useContext)(ThemeContext);
26385
+ return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
26850
26386
  QuillToolTipPortal,
26851
26387
  {
26852
26388
  enabled: !!tooltipText && tooltipText !== "",
26853
26389
  text: tooltipText ?? "",
26854
- children: /* @__PURE__ */ (0, import_jsx_runtime27.jsxs)(
26390
+ children: /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)(
26855
26391
  "button",
26856
26392
  {
26857
26393
  className: disabled ? "quill-button-disabled" : "quill-button",
@@ -26877,7 +26413,7 @@ var MemoizedButton = ({
26877
26413
  justifyContent: "center"
26878
26414
  },
26879
26415
  children: [
26880
- /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("style", { children: `
26416
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("style", { children: `
26881
26417
  .quill-button {
26882
26418
  background-color: ${theme?.primaryButtonColor};
26883
26419
  color: ${theme?.primaryButtonTextColor ?? "white"};
@@ -26891,8 +26427,8 @@ var MemoizedButton = ({
26891
26427
  background-color: ${theme?.hoverPrimaryButtonColor};
26892
26428
  color: ${theme?.hoverPrimaryButtonTextColor ?? "white"};
26893
26429
  }` }),
26894
- isLoading ? /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("div", { style: { position: "absolute" }, children: /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(LoadingSpinner, {}) }) : null,
26895
- /* @__PURE__ */ (0, import_jsx_runtime27.jsxs)(
26430
+ isLoading ? /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("div", { style: { position: "absolute" }, children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(LoadingSpinner, {}) }) : null,
26431
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)(
26896
26432
  "div",
26897
26433
  {
26898
26434
  style: {
@@ -26918,13 +26454,13 @@ var MemoizedSecondaryButton = ({
26918
26454
  tooltipText,
26919
26455
  width
26920
26456
  }) => {
26921
- const [theme] = (0, import_react12.useContext)(ThemeContext);
26922
- return /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
26457
+ const [theme] = (0, import_react11.useContext)(ThemeContext);
26458
+ return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
26923
26459
  QuillToolTip,
26924
26460
  {
26925
26461
  enabled: !!tooltipText && tooltipText !== "",
26926
26462
  text: tooltipText ?? "",
26927
- children: /* @__PURE__ */ (0, import_jsx_runtime27.jsxs)(
26463
+ children: /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)(
26928
26464
  "button",
26929
26465
  {
26930
26466
  className: "quill-secondary-button",
@@ -26951,7 +26487,7 @@ var MemoizedSecondaryButton = ({
26951
26487
  },
26952
26488
  disabled,
26953
26489
  children: [
26954
- /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("style", { children: `
26490
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("style", { children: `
26955
26491
  .quill-secondary-button {
26956
26492
  background-color: white;
26957
26493
  }
@@ -26971,8 +26507,8 @@ var MemoizedSecondaryButton = ({
26971
26507
  flex-shrink: 0;
26972
26508
  }
26973
26509
  ` }),
26974
- icon && /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("div", { className: "icon-container", children: icon }),
26975
- label && /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
26510
+ icon && /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("div", { className: "icon-container", children: icon }),
26511
+ label && /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
26976
26512
  "span",
26977
26513
  {
26978
26514
  style: {
@@ -26992,8 +26528,8 @@ var MemoizedSecondaryButton = ({
26992
26528
  );
26993
26529
  };
26994
26530
  var MemoizedHeader = ({ label }) => {
26995
- const [theme] = (0, import_react12.useContext)(ThemeContext);
26996
- return /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
26531
+ const [theme] = (0, import_react11.useContext)(ThemeContext);
26532
+ return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
26997
26533
  "h1",
26998
26534
  {
26999
26535
  style: {
@@ -27010,8 +26546,8 @@ var MemoizedHeader = ({ label }) => {
27010
26546
  );
27011
26547
  };
27012
26548
  var MemoizedSubHeader = ({ label }) => {
27013
- const [theme] = (0, import_react12.useContext)(ThemeContext);
27014
- return /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
26549
+ const [theme] = (0, import_react11.useContext)(ThemeContext);
26550
+ return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
27015
26551
  "h2",
27016
26552
  {
27017
26553
  style: {
@@ -27029,8 +26565,8 @@ var MemoizedSubHeader = ({ label }) => {
27029
26565
  );
27030
26566
  };
27031
26567
  var MemoizedLabel = ({ label }) => {
27032
- const [theme] = (0, import_react12.useContext)(ThemeContext);
27033
- return /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
26568
+ const [theme] = (0, import_react11.useContext)(ThemeContext);
26569
+ return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
27034
26570
  "h1",
27035
26571
  {
27036
26572
  style: {
@@ -27052,8 +26588,8 @@ var MemoizedCheckbox = ({
27052
26588
  containerStyle,
27053
26589
  disabled
27054
26590
  }) => {
27055
- const [theme] = (0, import_react12.useContext)(ThemeContext);
27056
- return /* @__PURE__ */ (0, import_jsx_runtime27.jsxs)(
26591
+ const [theme] = (0, import_react11.useContext)(ThemeContext);
26592
+ return /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)(
27057
26593
  "label",
27058
26594
  {
27059
26595
  style: {
@@ -27066,7 +26602,7 @@ var MemoizedCheckbox = ({
27066
26602
  ...containerStyle
27067
26603
  },
27068
26604
  children: [
27069
- /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
26605
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
27070
26606
  "input",
27071
26607
  {
27072
26608
  type: "checkbox",
@@ -27081,7 +26617,7 @@ var MemoizedCheckbox = ({
27081
26617
  }
27082
26618
  }
27083
26619
  ),
27084
- /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
26620
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
27085
26621
  "span",
27086
26622
  {
27087
26623
  style: {
@@ -27110,7 +26646,7 @@ var QuillTabs = ({
27110
26646
  options = DEFAULT_TAB_OPTIONS,
27111
26647
  value,
27112
26648
  onChange
27113
- }) => /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
26649
+ }) => /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
27114
26650
  "div",
27115
26651
  {
27116
26652
  style: {
@@ -27121,7 +26657,7 @@ var QuillTabs = ({
27121
26657
  background: "#F9FAFB",
27122
26658
  padding: "5px"
27123
26659
  },
27124
- children: options.map((option, index) => /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
26660
+ children: options.map((option, index) => /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
27125
26661
  "button",
27126
26662
  {
27127
26663
  onClick: () => {
@@ -27161,8 +26697,8 @@ var QuillTabs = ({
27161
26697
  }
27162
26698
  );
27163
26699
  var MemoizedText = ({ label }) => {
27164
- const [theme] = (0, import_react12.useContext)(ThemeContext);
27165
- return /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
26700
+ const [theme] = (0, import_react11.useContext)(ThemeContext);
26701
+ return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
27166
26702
  "p",
27167
26703
  {
27168
26704
  style: {
@@ -27192,11 +26728,11 @@ var MemoizedPopover = ({
27192
26728
  horizontalPadding = 20,
27193
26729
  titlePaddingLeft = 0
27194
26730
  }) => {
27195
- const [theme] = (0, import_react12.useContext)(ThemeContext);
27196
- const [rightAlignment, setRightAlignment] = (0, import_react12.useState)("auto");
27197
- const modalRef = (0, import_react12.useRef)(null);
27198
- const popoverRef = (0, import_react12.useRef)(null);
27199
- (0, import_react12.useEffect)(() => {
26731
+ const [theme] = (0, import_react11.useContext)(ThemeContext);
26732
+ const [rightAlignment, setRightAlignment] = (0, import_react11.useState)("auto");
26733
+ const modalRef = (0, import_react11.useRef)(null);
26734
+ const popoverRef = (0, import_react11.useRef)(null);
26735
+ (0, import_react11.useEffect)(() => {
27200
26736
  const listener = (event) => {
27201
26737
  const target = event.target;
27202
26738
  if (modalRef.current?.contains(target) || target.closest("[data-portal-ignore]") || ignoredRefs?.some(
@@ -27215,7 +26751,7 @@ var MemoizedPopover = ({
27215
26751
  document.removeEventListener("mousedown", listener);
27216
26752
  };
27217
26753
  }, [isOpen, ignoredRefs, setIsOpen, modalRef]);
27218
- (0, import_react12.useEffect)(() => {
26754
+ (0, import_react11.useEffect)(() => {
27219
26755
  updatePopoverPosition();
27220
26756
  window.addEventListener("resize", updatePopoverPosition);
27221
26757
  return () => {
@@ -27233,15 +26769,15 @@ var MemoizedPopover = ({
27233
26769
  }
27234
26770
  }
27235
26771
  };
27236
- return /* @__PURE__ */ (0, import_jsx_runtime27.jsxs)("div", { style: containerStyle, children: [
26772
+ return /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("div", { style: containerStyle, children: [
27237
26773
  triggerLabel,
27238
- !disabled && isOpen && /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
26774
+ !disabled && isOpen && /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
27239
26775
  "div",
27240
26776
  {
27241
26777
  id: "quill-popover-modal",
27242
26778
  ref: modalRef,
27243
26779
  style: { position: "relative" },
27244
- children: /* @__PURE__ */ (0, import_jsx_runtime27.jsxs)(
26780
+ children: /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)(
27245
26781
  "div",
27246
26782
  {
27247
26783
  ref: popoverRef,
@@ -27258,7 +26794,7 @@ var MemoizedPopover = ({
27258
26794
  right: rightAlignment
27259
26795
  },
27260
26796
  children: [
27261
- popoverTitle && /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
26797
+ popoverTitle && /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
27262
26798
  "h1",
27263
26799
  {
27264
26800
  style: {
@@ -27290,12 +26826,12 @@ function MemoizedModal({
27290
26826
  width,
27291
26827
  height
27292
26828
  }) {
27293
- const [theme] = (0, import_react12.useContext)(ThemeContext);
26829
+ const [theme] = (0, import_react11.useContext)(ThemeContext);
27294
26830
  if (!isOpen) {
27295
26831
  return null;
27296
26832
  }
27297
- return /* @__PURE__ */ (0, import_jsx_runtime27.jsxs)(import_jsx_runtime27.Fragment, { children: [
27298
- /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
26833
+ return /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)(import_jsx_runtime26.Fragment, { children: [
26834
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
27299
26835
  "div",
27300
26836
  {
27301
26837
  style: {
@@ -27311,7 +26847,7 @@ function MemoizedModal({
27311
26847
  onClick: () => setIsOpen(false)
27312
26848
  }
27313
26849
  ),
27314
- /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
26850
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
27315
26851
  "div",
27316
26852
  {
27317
26853
  style: {
@@ -27334,7 +26870,7 @@ function MemoizedModal({
27334
26870
  maxWidth: "calc(100vw - 82px)",
27335
26871
  maxHeight: "calc(100vh - 82px)"
27336
26872
  },
27337
- children: /* @__PURE__ */ (0, import_jsx_runtime27.jsxs)(
26873
+ children: /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)(
27338
26874
  "div",
27339
26875
  {
27340
26876
  style: {
@@ -27348,7 +26884,7 @@ function MemoizedModal({
27348
26884
  fontFamily: theme?.fontFamily
27349
26885
  },
27350
26886
  children: [
27351
- /* @__PURE__ */ (0, import_jsx_runtime27.jsxs)(
26887
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)(
27352
26888
  "div",
27353
26889
  {
27354
26890
  id: "quill-modal-header",
@@ -27363,7 +26899,7 @@ function MemoizedModal({
27363
26899
  borderBottom: "1px solid #E7E7E7"
27364
26900
  },
27365
26901
  children: [
27366
- /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
26902
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
27367
26903
  "h2",
27368
26904
  {
27369
26905
  style: {
@@ -27377,11 +26913,11 @@ function MemoizedModal({
27377
26913
  children: title
27378
26914
  }
27379
26915
  ),
27380
- /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(MemoizedDeleteButton, { onClick: () => setIsOpen(false) })
26916
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(MemoizedDeleteButton, { onClick: () => setIsOpen(false) })
27381
26917
  ]
27382
26918
  }
27383
26919
  ),
27384
- /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
26920
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
27385
26921
  "div",
27386
26922
  {
27387
26923
  style: {
@@ -27402,7 +26938,7 @@ function MemoizedModal({
27402
26938
  }
27403
26939
  var MemoizedDeleteButton = ({
27404
26940
  onClick
27405
- }) => /* @__PURE__ */ (0, import_jsx_runtime27.jsxs)(
26941
+ }) => /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)(
27406
26942
  "button",
27407
26943
  {
27408
26944
  className: "quill-delete-button",
@@ -27419,18 +26955,18 @@ var MemoizedDeleteButton = ({
27419
26955
  borderRadius: 6
27420
26956
  },
27421
26957
  children: [
27422
- /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("style", { children: `
26958
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("style", { children: `
27423
26959
  .quill-delete-button {
27424
26960
  background-color: white;
27425
26961
  }
27426
26962
  .quill-delete-button:hover {
27427
26963
  background-color: #F4F4F5;
27428
26964
  }` }),
27429
- /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(XIcon_default, { height: "20", width: "20", fill: "#6C727F" })
26965
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(XIcon_default, { height: "20", width: "20", fill: "#6C727F" })
27430
26966
  ]
27431
26967
  }
27432
26968
  );
27433
- var LoadingSpinner = () => /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
26969
+ var LoadingSpinner = () => /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
27434
26970
  "div",
27435
26971
  {
27436
26972
  style: {
@@ -27441,8 +26977,8 @@ var LoadingSpinner = () => /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
27441
26977
  justifyContent: "center",
27442
26978
  alignItems: "center"
27443
26979
  },
27444
- children: /* @__PURE__ */ (0, import_jsx_runtime27.jsxs)("svg", { width: "24", height: "24", children: [
27445
- /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
26980
+ children: /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("svg", { width: "24", height: "24", children: [
26981
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
27446
26982
  "circle",
27447
26983
  {
27448
26984
  cx: "12",
@@ -27454,7 +26990,7 @@ var LoadingSpinner = () => /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
27454
26990
  stroke: "#364153",
27455
26991
  fill: "none",
27456
26992
  transform: "rotate(-90 12 12)",
27457
- children: /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
26993
+ children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
27458
26994
  "animateTransform",
27459
26995
  {
27460
26996
  attributeName: "transform",
@@ -27468,7 +27004,7 @@ var LoadingSpinner = () => /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
27468
27004
  )
27469
27005
  }
27470
27006
  ),
27471
- /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
27007
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
27472
27008
  "circle",
27473
27009
  {
27474
27010
  cx: "12",
@@ -27480,7 +27016,7 @@ var LoadingSpinner = () => /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
27480
27016
  stroke: "#ADB1B9",
27481
27017
  fill: "none",
27482
27018
  transform: "rotate(90 12 12)",
27483
- children: /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
27019
+ children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
27484
27020
  "animateTransform",
27485
27021
  {
27486
27022
  attributeName: "transform",
@@ -27497,7 +27033,7 @@ var LoadingSpinner = () => /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
27497
27033
  ] })
27498
27034
  }
27499
27035
  );
27500
- var QuillEmptyDashboardComponent = () => /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("div", {});
27036
+ var QuillEmptyDashboardComponent = () => /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("div", {});
27501
27037
  var defaultFilterContainerStyles = {
27502
27038
  display: "flex",
27503
27039
  width: "100%",
@@ -27509,9 +27045,9 @@ var QuillLoadingDashboardComponent = ({
27509
27045
  chartContainerStyle,
27510
27046
  LoadingComponent = QuillLoadingSkeleton
27511
27047
  }) => {
27512
- return /* @__PURE__ */ (0, import_jsx_runtime27.jsxs)("div", { style: { ...containerStyle, overflow: "hidden" }, children: [
27513
- /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("div", { style: defaultFilterContainerStyles, children: /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(LoadingComponent, {}) }),
27514
- /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
27048
+ return /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("div", { style: { ...containerStyle, overflow: "hidden" }, children: [
27049
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("div", { style: defaultFilterContainerStyles, children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(LoadingComponent, {}) }),
27050
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
27515
27051
  "div",
27516
27052
  {
27517
27053
  style: {
@@ -27520,7 +27056,7 @@ var QuillLoadingDashboardComponent = ({
27520
27056
  gridTemplateRows: `repeat(${170}px)`,
27521
27057
  gap: 40
27522
27058
  },
27523
- children: Array.from({ length: 4 }).map((_, index) => /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("div", { style: chartContainerStyle, children: /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(LoadingComponent, {}, index) }, index))
27059
+ children: Array.from({ length: 4 }).map((_, index) => /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("div", { style: chartContainerStyle, children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(LoadingComponent, {}, index) }, index))
27524
27060
  }
27525
27061
  )
27526
27062
  ] });
@@ -27528,7 +27064,7 @@ var QuillLoadingDashboardComponent = ({
27528
27064
  var QuillChartBuilderInputRowContainer = ({
27529
27065
  children
27530
27066
  }) => {
27531
- return /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
27067
+ return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
27532
27068
  "div",
27533
27069
  {
27534
27070
  style: {
@@ -27543,7 +27079,7 @@ var QuillChartBuilderInputRowContainer = ({
27543
27079
  var QuillChartBuilderInputColumnContainer = ({
27544
27080
  children
27545
27081
  }) => {
27546
- return /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
27082
+ return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
27547
27083
  "div",
27548
27084
  {
27549
27085
  style: {
@@ -27558,7 +27094,7 @@ var QuillChartBuilderInputColumnContainer = ({
27558
27094
  var QuillPivotRowContainer = ({
27559
27095
  children
27560
27096
  }) => {
27561
- return /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
27097
+ return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
27562
27098
  "div",
27563
27099
  {
27564
27100
  style: {
@@ -27573,7 +27109,7 @@ var QuillPivotRowContainer = ({
27573
27109
  var QuillPivotColumnContainer = ({
27574
27110
  children
27575
27111
  }) => {
27576
- return /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
27112
+ return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
27577
27113
  "div",
27578
27114
  {
27579
27115
  style: {
@@ -27588,7 +27124,7 @@ var QuillPivotColumnContainer = ({
27588
27124
  var QuillFilterContainerComponent = ({
27589
27125
  children
27590
27126
  }) => {
27591
- return /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
27127
+ return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
27592
27128
  "div",
27593
27129
  {
27594
27130
  style: {
@@ -27611,11 +27147,11 @@ var QuillModalComponent = ({
27611
27147
  triggerLabel,
27612
27148
  title
27613
27149
  }) => {
27614
- const [theme] = (0, import_react12.useContext)(ThemeContext);
27615
- const [rightAlignment, setRightAlignment] = (0, import_react12.useState)("auto");
27616
- const modalRef = (0, import_react12.useRef)(null);
27617
- const popoverRef = (0, import_react12.useRef)(null);
27618
- (0, import_react12.useEffect)(() => {
27150
+ const [theme] = (0, import_react11.useContext)(ThemeContext);
27151
+ const [rightAlignment, setRightAlignment] = (0, import_react11.useState)("auto");
27152
+ const modalRef = (0, import_react11.useRef)(null);
27153
+ const popoverRef = (0, import_react11.useRef)(null);
27154
+ (0, import_react11.useEffect)(() => {
27619
27155
  const listener = (event) => {
27620
27156
  if (modalRef?.current && !modalRef?.current?.contains(event.target)) {
27621
27157
  if (setIsOpen) setIsOpen(false);
@@ -27630,7 +27166,7 @@ var QuillModalComponent = ({
27630
27166
  document.removeEventListener("mousedown", listener);
27631
27167
  };
27632
27168
  }, [modalRef, setIsOpen, isOpen]);
27633
- (0, import_react12.useEffect)(() => {
27169
+ (0, import_react11.useEffect)(() => {
27634
27170
  updatePopoverPosition();
27635
27171
  window.addEventListener("resize", updatePopoverPosition);
27636
27172
  return () => {
@@ -27648,8 +27184,8 @@ var QuillModalComponent = ({
27648
27184
  }
27649
27185
  }
27650
27186
  };
27651
- return /* @__PURE__ */ (0, import_jsx_runtime27.jsxs)("div", { style: { position: "relative" }, ref: modalRef, children: [
27652
- /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
27187
+ return /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("div", { style: { position: "relative" }, ref: modalRef, children: [
27188
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
27653
27189
  MemoizedSecondaryButton,
27654
27190
  {
27655
27191
  onClick: () => {
@@ -27658,12 +27194,12 @@ var QuillModalComponent = ({
27658
27194
  label: triggerLabel || ""
27659
27195
  }
27660
27196
  ),
27661
- title && title === "Filters" ? isOpen && /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
27197
+ title && title === "Filters" ? isOpen && /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
27662
27198
  "div",
27663
27199
  {
27664
27200
  id: "quill-popover-modal",
27665
27201
  style: { position: "relative", top: 10 },
27666
- children: /* @__PURE__ */ (0, import_jsx_runtime27.jsxs)(
27202
+ children: /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)(
27667
27203
  "div",
27668
27204
  {
27669
27205
  ref: popoverRef,
@@ -27680,7 +27216,7 @@ var QuillModalComponent = ({
27680
27216
  right: rightAlignment
27681
27217
  },
27682
27218
  children: [
27683
- /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
27219
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
27684
27220
  "h1",
27685
27221
  {
27686
27222
  style: {
@@ -27700,8 +27236,8 @@ var QuillModalComponent = ({
27700
27236
  }
27701
27237
  )
27702
27238
  }
27703
- ) : isOpen && /* @__PURE__ */ (0, import_jsx_runtime27.jsxs)("div", { children: [
27704
- /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
27239
+ ) : isOpen && /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("div", { children: [
27240
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
27705
27241
  "div",
27706
27242
  {
27707
27243
  style: {
@@ -27719,7 +27255,7 @@ var QuillModalComponent = ({
27719
27255
  }
27720
27256
  }
27721
27257
  ),
27722
- /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
27258
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
27723
27259
  "div",
27724
27260
  {
27725
27261
  style: {
@@ -27740,7 +27276,7 @@ var QuillModalComponent = ({
27740
27276
  padding: 30,
27741
27277
  overflow: "auto"
27742
27278
  },
27743
- children: /* @__PURE__ */ (0, import_jsx_runtime27.jsxs)(
27279
+ children: /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)(
27744
27280
  "div",
27745
27281
  {
27746
27282
  style: {
@@ -27749,7 +27285,7 @@ var QuillModalComponent = ({
27749
27285
  minWidth: "60vw"
27750
27286
  },
27751
27287
  children: [
27752
- /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
27288
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
27753
27289
  "h1",
27754
27290
  {
27755
27291
  style: {
@@ -27776,7 +27312,7 @@ var QuillModalComponent = ({
27776
27312
  var QuillChartBuilderFormContainer = ({
27777
27313
  children
27778
27314
  }) => {
27779
- return /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
27315
+ return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
27780
27316
  "div",
27781
27317
  {
27782
27318
  style: {
@@ -27798,8 +27334,8 @@ var QuillErrorMessageComponent = ({
27798
27334
  errorMessage,
27799
27335
  containerStyle
27800
27336
  }) => {
27801
- const [theme] = (0, import_react12.useContext)(ThemeContext);
27802
- return /* @__PURE__ */ (0, import_jsx_runtime27.jsxs)(
27337
+ const [theme] = (0, import_react11.useContext)(ThemeContext);
27338
+ return /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)(
27803
27339
  "div",
27804
27340
  {
27805
27341
  style: {
@@ -27817,7 +27353,7 @@ var QuillErrorMessageComponent = ({
27817
27353
  ...containerStyle
27818
27354
  },
27819
27355
  children: [
27820
- /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
27356
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
27821
27357
  "svg",
27822
27358
  {
27823
27359
  xmlns: "http://www.w3.org/2000/svg",
@@ -27831,7 +27367,7 @@ var QuillErrorMessageComponent = ({
27831
27367
  marginRight: 8,
27832
27368
  color: "#D32F2F"
27833
27369
  },
27834
- children: /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
27370
+ children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
27835
27371
  "path",
27836
27372
  {
27837
27373
  strokeLinecap: "round",
@@ -27847,12 +27383,12 @@ var QuillErrorMessageComponent = ({
27847
27383
  );
27848
27384
  };
27849
27385
  var QuillColumnSearchEmptyState = () => {
27850
- const [theme] = (0, import_react12.useContext)(ThemeContext);
27851
- return /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("div", { style: { fontFamily: theme?.fontFamily }, children: "No results found" });
27386
+ const [theme] = (0, import_react11.useContext)(ThemeContext);
27387
+ return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("div", { style: { fontFamily: theme?.fontFamily }, children: "No results found" });
27852
27388
  };
27853
27389
  var QuillLoadingComponent = () => {
27854
- const [theme] = (0, import_react12.useContext)(ThemeContext);
27855
- return /* @__PURE__ */ (0, import_jsx_runtime27.jsxs)(
27390
+ const [theme] = (0, import_react11.useContext)(ThemeContext);
27391
+ return /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)(
27856
27392
  "div",
27857
27393
  {
27858
27394
  style: {
@@ -27867,9 +27403,9 @@ var QuillLoadingComponent = () => {
27867
27403
  justifyContent: "center"
27868
27404
  },
27869
27405
  children: [
27870
- /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("div", { style: { height: 100 } }),
27871
- /* @__PURE__ */ (0, import_jsx_runtime27.jsxs)("svg", { width: "24", height: "24", children: [
27872
- /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
27406
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("div", { style: { height: 100 } }),
27407
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("svg", { width: "24", height: "24", children: [
27408
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
27873
27409
  "circle",
27874
27410
  {
27875
27411
  cx: "12",
@@ -27881,7 +27417,7 @@ var QuillLoadingComponent = () => {
27881
27417
  stroke: theme?.primaryTextColor || "#364153",
27882
27418
  fill: "none",
27883
27419
  transform: "rotate(-90 12 12)",
27884
- children: /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
27420
+ children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
27885
27421
  "animateTransform",
27886
27422
  {
27887
27423
  attributeName: "transform",
@@ -27895,7 +27431,7 @@ var QuillLoadingComponent = () => {
27895
27431
  )
27896
27432
  }
27897
27433
  ),
27898
- /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
27434
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
27899
27435
  "circle",
27900
27436
  {
27901
27437
  cx: "12",
@@ -27907,7 +27443,7 @@ var QuillLoadingComponent = () => {
27907
27443
  stroke: "#ADB1B9",
27908
27444
  fill: "none",
27909
27445
  transform: "rotate(90 12 12)",
27910
- children: /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
27446
+ children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
27911
27447
  "animateTransform",
27912
27448
  {
27913
27449
  attributeName: "transform",
@@ -27930,9 +27466,9 @@ var OverflowContainer = ({
27930
27466
  children,
27931
27467
  style: style2
27932
27468
  }) => {
27933
- const containerRef = (0, import_react12.useRef)(null);
27934
- const [showTopShadow, setShowTopShadow] = (0, import_react12.useState)(false);
27935
- const [showBottomShadow, setShowBottomShadow] = (0, import_react12.useState)(false);
27469
+ const containerRef = (0, import_react11.useRef)(null);
27470
+ const [showTopShadow, setShowTopShadow] = (0, import_react11.useState)(false);
27471
+ const [showBottomShadow, setShowBottomShadow] = (0, import_react11.useState)(false);
27936
27472
  const checkOverflow = () => {
27937
27473
  const container = containerRef.current;
27938
27474
  if (container) {
@@ -27943,7 +27479,7 @@ var OverflowContainer = ({
27943
27479
  );
27944
27480
  }
27945
27481
  };
27946
- (0, import_react12.useEffect)(() => {
27482
+ (0, import_react11.useEffect)(() => {
27947
27483
  const container = containerRef.current;
27948
27484
  if (container) {
27949
27485
  checkOverflow();
@@ -27997,7 +27533,7 @@ var OverflowContainer = ({
27997
27533
  opacity: showBottomShadow ? 1 : 0,
27998
27534
  ...shadowStyle
27999
27535
  };
28000
- return /* @__PURE__ */ (0, import_jsx_runtime27.jsxs)(
27536
+ return /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)(
28001
27537
  "div",
28002
27538
  {
28003
27539
  style: containerStyle,
@@ -28006,9 +27542,9 @@ var OverflowContainer = ({
28006
27542
  onTouchMove: checkOverflow,
28007
27543
  onMouseMove: checkOverflow,
28008
27544
  children: [
28009
- /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("div", { style: topShadowStyle }),
27545
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("div", { style: topShadowStyle }),
28010
27546
  children,
28011
- /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("div", { style: bottomShadowStyle })
27547
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("div", { style: bottomShadowStyle })
28012
27548
  ]
28013
27549
  }
28014
27550
  );
@@ -28021,9 +27557,9 @@ var QuillToolTip = ({
28021
27557
  textStyle = {},
28022
27558
  displayBelow = false
28023
27559
  }) => {
28024
- const [theme] = (0, import_react12.useContext)(ThemeContext);
28025
- return enabled ? /* @__PURE__ */ (0, import_jsx_runtime27.jsxs)("div", { className: "tooltip-container", style: { ...containerStyle }, children: [
28026
- /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("style", { children: `
27560
+ const [theme] = (0, import_react11.useContext)(ThemeContext);
27561
+ return enabled ? /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("div", { className: "tooltip-container", style: { ...containerStyle }, children: [
27562
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("style", { children: `
28027
27563
  .tooltip-container {
28028
27564
  position: relative;
28029
27565
  display: inline-block;
@@ -28085,7 +27621,7 @@ var QuillToolTip = ({
28085
27621
  opacity: 1;
28086
27622
  }` }),
28087
27623
  children,
28088
- /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("div", { className: "tooltip-text", style: { ...textStyle }, children: text })
27624
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("div", { className: "tooltip-text", style: { ...textStyle }, children: text })
28089
27625
  ] }) : children;
28090
27626
  };
28091
27627
  var QuillToolTipPortal = ({
@@ -28096,11 +27632,11 @@ var QuillToolTipPortal = ({
28096
27632
  textStyle = {},
28097
27633
  mirror = false
28098
27634
  }) => {
28099
- const [theme] = (0, import_react12.useContext)(ThemeContext);
28100
- const [isOpen, setIsOpen] = (0, import_react12.useState)(false);
28101
- const tooltipRef = (0, import_react12.useRef)(null);
28102
- const triggerRef = (0, import_react12.useRef)(null);
28103
- const [tooltipPosition, setTooltipPosition] = (0, import_react12.useState)(void 0);
27635
+ const [theme] = (0, import_react11.useContext)(ThemeContext);
27636
+ const [isOpen, setIsOpen] = (0, import_react11.useState)(false);
27637
+ const tooltipRef = (0, import_react11.useRef)(null);
27638
+ const triggerRef = (0, import_react11.useRef)(null);
27639
+ const [tooltipPosition, setTooltipPosition] = (0, import_react11.useState)(void 0);
28104
27640
  const updatePosition = () => {
28105
27641
  if (triggerRef.current && tooltipRef.current) {
28106
27642
  const rect = triggerRef.current.getBoundingClientRect();
@@ -28125,7 +27661,7 @@ var QuillToolTipPortal = ({
28125
27661
  setTooltipPosition({ top, left });
28126
27662
  }
28127
27663
  };
28128
- (0, import_react12.useEffect)(() => {
27664
+ (0, import_react11.useEffect)(() => {
28129
27665
  if (isOpen) {
28130
27666
  const timer2 = setTimeout(() => {
28131
27667
  updatePosition();
@@ -28140,9 +27676,9 @@ var QuillToolTipPortal = ({
28140
27676
  }
28141
27677
  }, [isOpen]);
28142
27678
  if (!enabled) {
28143
- return /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(import_jsx_runtime27.Fragment, { children });
27679
+ return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(import_jsx_runtime26.Fragment, { children });
28144
27680
  }
28145
- return /* @__PURE__ */ (0, import_jsx_runtime27.jsxs)(
27681
+ return /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)(
28146
27682
  "div",
28147
27683
  {
28148
27684
  ref: triggerRef,
@@ -28156,7 +27692,7 @@ var QuillToolTipPortal = ({
28156
27692
  children: [
28157
27693
  children,
28158
27694
  isOpen && (0, import_react_dom2.createPortal)(
28159
- /* @__PURE__ */ (0, import_jsx_runtime27.jsxs)(
27695
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)(
28160
27696
  "div",
28161
27697
  {
28162
27698
  ref: tooltipRef,
@@ -28183,7 +27719,7 @@ var QuillToolTipPortal = ({
28183
27719
  },
28184
27720
  children: [
28185
27721
  text,
28186
- /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
27722
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
28187
27723
  "div",
28188
27724
  {
28189
27725
  style: {
@@ -28198,7 +27734,7 @@ var QuillToolTipPortal = ({
28198
27734
  }
28199
27735
  }
28200
27736
  ),
28201
- /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
27737
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
28202
27738
  "div",
28203
27739
  {
28204
27740
  style: {
@@ -28229,8 +27765,8 @@ var QuillChartBuilderCheckboxComponent = ({
28229
27765
  disabled,
28230
27766
  containerStyle
28231
27767
  }) => {
28232
- const [theme] = (0, import_react12.useContext)(ThemeContext);
28233
- return /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
27768
+ const [theme] = (0, import_react11.useContext)(ThemeContext);
27769
+ return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
28234
27770
  "div",
28235
27771
  {
28236
27772
  style: {
@@ -28239,7 +27775,7 @@ var QuillChartBuilderCheckboxComponent = ({
28239
27775
  paddingBottom: 4,
28240
27776
  paddingLeft: 8,
28241
27777
  paddingRight: 8,
28242
- border: "1px solid #E7E7E7",
27778
+ // border: '1px solid #E7E7E7',
28243
27779
  borderRadius: 4,
28244
27780
  display: "flex",
28245
27781
  alignItems: "center",
@@ -28248,7 +27784,7 @@ var QuillChartBuilderCheckboxComponent = ({
28248
27784
  pointerEvents: disabled ? "none" : "auto",
28249
27785
  ...containerStyle
28250
27786
  },
28251
- children: /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
27787
+ children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
28252
27788
  MemoizedCheckbox,
28253
27789
  {
28254
27790
  isChecked,
@@ -28268,10 +27804,10 @@ var QuillPortal = ({
28268
27804
  showModal,
28269
27805
  setShowModal
28270
27806
  }) => {
28271
- const modalRef = (0, import_react12.useRef)(null);
28272
- const [popoverPosition, setPopoverPosition] = (0, import_react12.useState)(void 0);
28273
- const [z, setZ] = (0, import_react12.useState)(10);
28274
- const scrollableParentRef = (0, import_react12.useRef)(document.body);
27807
+ const modalRef = (0, import_react11.useRef)(null);
27808
+ const [popoverPosition, setPopoverPosition] = (0, import_react11.useState)(void 0);
27809
+ const [z, setZ] = (0, import_react11.useState)(10);
27810
+ const scrollableParentRef = (0, import_react11.useRef)(document.body);
28275
27811
  const updatePosition = () => {
28276
27812
  if (anchorRef.current) {
28277
27813
  requestAnimationFrame(() => {
@@ -28289,7 +27825,7 @@ var QuillPortal = ({
28289
27825
  });
28290
27826
  }
28291
27827
  };
28292
- (0, import_react12.useEffect)(() => {
27828
+ (0, import_react11.useEffect)(() => {
28293
27829
  let resizeObserver;
28294
27830
  let mutationObserver;
28295
27831
  if (showModal && anchorRef.current) {
@@ -28328,7 +27864,7 @@ var QuillPortal = ({
28328
27864
  showModal
28329
27865
  );
28330
27866
  return (0, import_react_dom2.createPortal)(
28331
- /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
27867
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
28332
27868
  "div",
28333
27869
  {
28334
27870
  style: {
@@ -28363,8 +27899,645 @@ var QuillPortal = ({
28363
27899
  );
28364
27900
  };
28365
27901
 
28366
- // src/components/QuillTable.tsx
27902
+ // src/components/Chart/CustomLegend.tsx
27903
+ var import_jsx_runtime27 = require("react/jsx-runtime");
27904
+ var getLegendLabel = (entry) => {
27905
+ const label = entry?.payload?.name ?? entry?.value ?? entry?.dataKey ?? "";
27906
+ return typeof label === "string" ? label : String(label ?? "");
27907
+ };
27908
+ var LegendItem = ({
27909
+ entry,
27910
+ index,
27911
+ theme
27912
+ }) => /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
27913
+ "div",
27914
+ {
27915
+ style: {
27916
+ display: "flex",
27917
+ alignItems: "baseline",
27918
+ marginRight: "1rem"
27919
+ },
27920
+ children: /* @__PURE__ */ (0, import_jsx_runtime27.jsxs)("div", { style: { display: "flex", flexDirection: "row", alignItems: "center" }, children: [
27921
+ /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
27922
+ "svg",
27923
+ {
27924
+ style: { marginRight: "0.5rem" },
27925
+ width: "16",
27926
+ height: "16",
27927
+ viewBox: "0 0 16 16",
27928
+ children: /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("rect", { width: "16", height: "16", rx: "3", fill: entry?.color })
27929
+ }
27930
+ ),
27931
+ /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
27932
+ "span",
27933
+ {
27934
+ style: {
27935
+ color: theme?.secondaryTextColor,
27936
+ fontFamily: theme?.fontFamily,
27937
+ fontSize: theme?.fontSizeMedium || "14px",
27938
+ whiteSpace: "nowrap"
27939
+ },
27940
+ children: getLegendLabel(entry)
27941
+ }
27942
+ )
27943
+ ] })
27944
+ },
27945
+ `legend-${index}`
27946
+ );
27947
+ var getOuterWidth = (element) => {
27948
+ if (!element) return 0;
27949
+ const rect = element.getBoundingClientRect();
27950
+ const styles = window.getComputedStyle(element);
27951
+ const marginLeft = Number.parseFloat(styles.marginLeft || "0");
27952
+ const marginRight = Number.parseFloat(styles.marginRight || "0");
27953
+ return rect.width + marginLeft + marginRight;
27954
+ };
27955
+ var RenderLegend = ({
27956
+ payload,
27957
+ limit
27958
+ }) => {
27959
+ const [theme] = (0, import_react12.useContext)(ThemeContext);
27960
+ const [isOpen, setIsOpen] = (0, import_react12.useState)(false);
27961
+ const [showSeeAll, setShowSeeAll] = (0, import_react12.useState)(false);
27962
+ const [visibleCount, setVisibleCount] = (0, import_react12.useState)(null);
27963
+ const containerRef = (0, import_react12.useRef)(null);
27964
+ const seeAllMeasureRef = (0, import_react12.useRef)(null);
27965
+ const seeAllTriggerRef = (0, import_react12.useRef)(null);
27966
+ const itemRefs = (0, import_react12.useRef)([]);
27967
+ if (!payload || payload.length === 0) return null;
27968
+ const maxItems = limit ?? payload.length;
27969
+ const measuredLimit = visibleCount ?? maxItems;
27970
+ const visiblePayload = payload.slice(0, Math.min(maxItems, measuredLimit));
27971
+ const handleOpen = () => setIsOpen(true);
27972
+ const handleClose = () => setIsOpen(false);
27973
+ (0, import_react12.useLayoutEffect)(() => {
27974
+ if (!containerRef.current) return;
27975
+ if (!payload.length) return;
27976
+ const updateVisibleCount = () => {
27977
+ const containerWidth = containerRef.current?.offsetWidth ?? 0;
27978
+ if (!containerWidth) return;
27979
+ const maxCount = Math.min(maxItems, payload.length);
27980
+ const seeAllWidth = getOuterWidth(seeAllMeasureRef.current);
27981
+ const computeCount = (reserveSeeAll) => {
27982
+ const availableWidth = containerWidth - (reserveSeeAll ? seeAllWidth : 0);
27983
+ if (availableWidth <= 0) return 1;
27984
+ let totalWidth = 0;
27985
+ let nextCount = 0;
27986
+ for (let i = 0; i < maxCount; i += 1) {
27987
+ const itemWidth = getOuterWidth(itemRefs.current[i] ?? null);
27988
+ if (totalWidth + itemWidth > availableWidth) break;
27989
+ totalWidth += itemWidth;
27990
+ nextCount = i + 1;
27991
+ }
27992
+ return Math.max(1, nextCount);
27993
+ };
27994
+ const countWithSeeAll = computeCount(true);
27995
+ const shouldShowSeeAll = payload.length > countWithSeeAll;
27996
+ const finalCount = shouldShowSeeAll ? countWithSeeAll : computeCount(false);
27997
+ setShowSeeAll(shouldShowSeeAll);
27998
+ setVisibleCount(finalCount);
27999
+ };
28000
+ updateVisibleCount();
28001
+ const observer = new ResizeObserver(updateVisibleCount);
28002
+ observer.observe(containerRef.current);
28003
+ return () => observer.disconnect();
28004
+ }, [payload.length, maxItems]);
28005
+ return /* @__PURE__ */ (0, import_jsx_runtime27.jsxs)(
28006
+ "div",
28007
+ {
28008
+ ref: containerRef,
28009
+ style: {
28010
+ display: "flex",
28011
+ flexDirection: "row",
28012
+ justifyContent: "space-between",
28013
+ alignItems: "center",
28014
+ flexWrap: "nowrap",
28015
+ width: "100%"
28016
+ },
28017
+ children: [
28018
+ /* @__PURE__ */ (0, import_jsx_runtime27.jsxs)(
28019
+ "div",
28020
+ {
28021
+ style: {
28022
+ position: "absolute",
28023
+ visibility: "hidden",
28024
+ height: 0,
28025
+ overflow: "hidden",
28026
+ pointerEvents: "none",
28027
+ display: "flex",
28028
+ alignItems: "center",
28029
+ flexWrap: "nowrap",
28030
+ justifyContent: "space-between",
28031
+ width: "100%"
28032
+ },
28033
+ children: [
28034
+ /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
28035
+ "div",
28036
+ {
28037
+ style: {
28038
+ display: "flex",
28039
+ flexDirection: "row",
28040
+ alignItems: "center",
28041
+ justifyContent: "flex-start",
28042
+ flexWrap: "nowrap"
28043
+ },
28044
+ children: payload.slice(0, maxItems).map((entry, index) => /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
28045
+ "div",
28046
+ {
28047
+ ref: (element) => {
28048
+ itemRefs.current[index] = element;
28049
+ },
28050
+ children: /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(LegendItem, { entry, index, theme })
28051
+ },
28052
+ `legend-measure-${index}`
28053
+ ))
28054
+ }
28055
+ ),
28056
+ /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
28057
+ "div",
28058
+ {
28059
+ ref: seeAllMeasureRef,
28060
+ style: {
28061
+ color: theme?.secondaryTextColor,
28062
+ fontSize: theme?.fontSizeMedium || "14px",
28063
+ fontFamily: theme?.fontFamily,
28064
+ marginLeft: 10,
28065
+ display: "flex",
28066
+ alignItems: "baseline",
28067
+ flexShrink: 0,
28068
+ whiteSpace: "nowrap"
28069
+ },
28070
+ children: "See all"
28071
+ }
28072
+ )
28073
+ ]
28074
+ }
28075
+ ),
28076
+ /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
28077
+ "div",
28078
+ {
28079
+ style: {
28080
+ display: "flex",
28081
+ flexDirection: "row",
28082
+ alignItems: "center",
28083
+ justifyContent: "flex-start",
28084
+ flexWrap: "nowrap"
28085
+ },
28086
+ children: visiblePayload.map((entry, index) => /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
28087
+ LegendItem,
28088
+ {
28089
+ entry,
28090
+ index,
28091
+ theme
28092
+ },
28093
+ `legend-${index}`
28094
+ ))
28095
+ }
28096
+ ),
28097
+ showSeeAll && /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("div", { onMouseEnter: handleOpen, onMouseLeave: handleClose, children: /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
28098
+ MemoizedPopover,
28099
+ {
28100
+ isOpen,
28101
+ setIsOpen,
28102
+ triggerLabel: /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
28103
+ "div",
28104
+ {
28105
+ ref: seeAllTriggerRef,
28106
+ onClick: handleOpen,
28107
+ onMouseEnter: handleOpen,
28108
+ style: {
28109
+ cursor: "pointer",
28110
+ color: theme?.secondaryTextColor,
28111
+ fontSize: theme?.fontSizeMedium || "14px",
28112
+ fontFamily: theme?.fontFamily,
28113
+ marginLeft: 10,
28114
+ display: "flex",
28115
+ alignItems: "baseline",
28116
+ flexShrink: 0,
28117
+ whiteSpace: "nowrap"
28118
+ },
28119
+ children: "See all"
28120
+ }
28121
+ ),
28122
+ popoverChildren: /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
28123
+ "div",
28124
+ {
28125
+ style: {
28126
+ display: "flex",
28127
+ flexWrap: "wrap",
28128
+ alignItems: "center",
28129
+ minWidth: 260,
28130
+ maxWidth: 520,
28131
+ gap: "0.5rem"
28132
+ },
28133
+ children: payload.map((entry, index) => /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
28134
+ LegendItem,
28135
+ {
28136
+ entry,
28137
+ index,
28138
+ theme
28139
+ },
28140
+ `legend-popover-${index}`
28141
+ ))
28142
+ }
28143
+ )
28144
+ }
28145
+ ) })
28146
+ ]
28147
+ }
28148
+ );
28149
+ };
28150
+
28151
+ // src/components/Chart/PieChart.tsx
28367
28152
  var import_jsx_runtime28 = require("react/jsx-runtime");
28153
+ var defaultValueFormatter = (value) => (value * 1).toFixed(1) + "%";
28154
+ var parseData2 = (data, colors, categoryKey, valueKey) => {
28155
+ const maxItems = 20;
28156
+ const slicedData = deepCopy(data).slice(0, maxItems);
28157
+ const totalValue = slicedData.reduce(
28158
+ (acc, dataPoint) => (
28159
+ // Big(acc)
28160
+ // .add(Big(Number(dataPoint[valueKey]) ?? 0))
28161
+ // .toNumber(),
28162
+ acc + parseFloat(dataPoint[valueKey] ?? "0")
28163
+ ),
28164
+ 0
28165
+ );
28166
+ slicedData.forEach((dataPoint) => {
28167
+ const rawValue = parseFloat(dataPoint[valueKey] ?? "0");
28168
+ dataPoint[valueKey] = totalValue ? rawValue * 100 / totalValue : data.length > maxItems ? 100 / (maxItems + 1) : 100 / slicedData.length;
28169
+ dataPoint[`raw_${valueKey}`] = parseFloat(rawValue.toFixed(2));
28170
+ });
28171
+ const parsedData = slicedData.map((dataPoint, idx) => {
28172
+ const baseColor = colors.length > 0 ? idx < colors.length ? colors[idx] : colors[colors.length - 1] : "#808080";
28173
+ return {
28174
+ ...dataPoint,
28175
+ color: baseColor,
28176
+ fill: baseColor
28177
+ };
28178
+ });
28179
+ if (data.length > maxItems) {
28180
+ const otherData = data.slice(maxItems);
28181
+ const otherSum = otherData.reduce(
28182
+ (acc, dataPoint) => (
28183
+ // Big(acc)
28184
+ // .add(Big(Number(dataPoint[valueKey])) ?? 0)
28185
+ // .toNumber(),
28186
+ acc + parseFloat(dataPoint[valueKey] ?? "0")
28187
+ ),
28188
+ 0
28189
+ );
28190
+ const otherColor = colors.length > 0 ? colors[colors.length - 1] : "#808080";
28191
+ const normalizedOtherSum = totalValue ? otherSum * 100 / totalValue : 100 / (maxItems + 1);
28192
+ parsedData.push({
28193
+ [categoryKey]: "Other",
28194
+ [valueKey]: normalizedOtherSum,
28195
+ [`raw_${valueKey}`]: parseFloat(otherSum.toFixed(2)),
28196
+ color: otherColor,
28197
+ fill: otherColor
28198
+ });
28199
+ }
28200
+ return parsedData;
28201
+ };
28202
+ var ChartTooltipFrame = ({
28203
+ children,
28204
+ theme
28205
+ }) => /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
28206
+ "div",
28207
+ {
28208
+ style: {
28209
+ borderStyle: "solid",
28210
+ borderColor: theme?.borderColor || "#E5E7EB",
28211
+ borderWidth: 1,
28212
+ background: theme?.backgroundColor || "#ffffff",
28213
+ fontSize: theme?.fontSize || "14px",
28214
+ borderRadius: "6px",
28215
+ boxShadow: "0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05)"
28216
+ },
28217
+ children
28218
+ }
28219
+ );
28220
+ var ChartTooltipRow = ({
28221
+ value,
28222
+ rawValue,
28223
+ valueKey,
28224
+ valueKeyLabel,
28225
+ name: name2,
28226
+ // color,
28227
+ theme
28228
+ }) => /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)(
28229
+ "div",
28230
+ {
28231
+ style: {
28232
+ display: "flex",
28233
+ flexDirection: "column",
28234
+ gap: 2,
28235
+ minWidth: 150,
28236
+ position: "relative"
28237
+ },
28238
+ children: [
28239
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
28240
+ "div",
28241
+ {
28242
+ style: {
28243
+ display: "flex",
28244
+ alignItems: "center",
28245
+ width: "100%"
28246
+ // paddingLeft: '24px',
28247
+ },
28248
+ children: /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)(
28249
+ "span",
28250
+ {
28251
+ style: {
28252
+ flex: 1,
28253
+ display: "flex",
28254
+ alignItems: "center",
28255
+ justifyContent: "space-between"
28256
+ },
28257
+ children: [
28258
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
28259
+ "p",
28260
+ {
28261
+ style: {
28262
+ marginTop: 0,
28263
+ marginBottom: 0,
28264
+ marginRight: "24px",
28265
+ fontFamily: theme?.fontFamily,
28266
+ color: theme?.primaryTextColor,
28267
+ fontSize: theme?.fontSizeSmall || "14px",
28268
+ fontWeight: theme?.fontWeightMedium || "500",
28269
+ minWidth: "60px"
28270
+ },
28271
+ children: name2
28272
+ }
28273
+ ),
28274
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
28275
+ "p",
28276
+ {
28277
+ style: {
28278
+ marginTop: 0,
28279
+ marginBottom: 0,
28280
+ fontFamily: theme?.fontFamily,
28281
+ color: theme?.primaryTextColor,
28282
+ fontSize: theme?.fontSizeSmall || "14px",
28283
+ fontWeight: theme?.fontWeightMedium || "500",
28284
+ minWidth: "40px",
28285
+ textAlign: "right"
28286
+ },
28287
+ children: value
28288
+ }
28289
+ )
28290
+ ]
28291
+ }
28292
+ )
28293
+ }
28294
+ ),
28295
+ (rawValue || valueKey) && /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
28296
+ "div",
28297
+ {
28298
+ style: {
28299
+ display: "flex",
28300
+ alignItems: "center",
28301
+ width: "100%",
28302
+ // paddingLeft: '24px',
28303
+ justifyContent: "space-between"
28304
+ },
28305
+ children: /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)(
28306
+ "span",
28307
+ {
28308
+ style: {
28309
+ flex: 1,
28310
+ display: "flex",
28311
+ alignItems: "center",
28312
+ justifyContent: "space-between"
28313
+ },
28314
+ children: [
28315
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
28316
+ "p",
28317
+ {
28318
+ style: {
28319
+ marginTop: 0,
28320
+ marginBottom: 0,
28321
+ marginRight: "24px",
28322
+ fontFamily: theme?.fontFamily,
28323
+ color: theme?.primaryTextColor,
28324
+ fontSize: theme?.fontSizeSmall || "14px",
28325
+ fontWeight: theme?.fontWeightMedium || "500",
28326
+ minWidth: "60px"
28327
+ },
28328
+ children: valueKeyLabel || valueKey
28329
+ }
28330
+ ),
28331
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
28332
+ "p",
28333
+ {
28334
+ style: {
28335
+ marginTop: 0,
28336
+ marginBottom: 0,
28337
+ fontFamily: theme?.fontFamily,
28338
+ color: theme?.primaryTextColor,
28339
+ fontSize: theme?.fontSizeSmall || "14px",
28340
+ fontWeight: theme?.fontWeightMedium || "500",
28341
+ minWidth: "40px",
28342
+ textAlign: "right"
28343
+ },
28344
+ children: rawValue
28345
+ }
28346
+ )
28347
+ ]
28348
+ }
28349
+ )
28350
+ }
28351
+ )
28352
+ ]
28353
+ }
28354
+ );
28355
+ var DonutChartTooltip = ({
28356
+ active,
28357
+ payload,
28358
+ valueFormatter: valueFormatter2,
28359
+ theme,
28360
+ yAxisFields
28361
+ }) => {
28362
+ if (active && payload[0]) {
28363
+ const payloadRow = payload[0];
28364
+ const rawValue = payloadRow.payload[`raw_${payloadRow.dataKey}`];
28365
+ const field = yAxisFields?.find((f) => f.field === payloadRow.dataKey);
28366
+ const formattedRawValue = quillFormat({
28367
+ value: rawValue?.toString() || "",
28368
+ format: field?.format || "string"
28369
+ });
28370
+ return /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(ChartTooltipFrame, { theme, children: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
28371
+ "div",
28372
+ {
28373
+ style: {
28374
+ paddingLeft: "1rem",
28375
+ paddingRight: "1rem",
28376
+ paddingTop: "8px",
28377
+ paddingBottom: "8px"
28378
+ },
28379
+ children: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
28380
+ ChartTooltipRow,
28381
+ {
28382
+ value: valueFormatter2(payloadRow.value),
28383
+ rawValue: rawValue ? formattedRawValue : void 0,
28384
+ valueKey: payloadRow.dataKey,
28385
+ valueKeyLabel: field?.label,
28386
+ name: payloadRow.name,
28387
+ color: payloadRow.payload.color,
28388
+ theme
28389
+ }
28390
+ )
28391
+ }
28392
+ ) });
28393
+ }
28394
+ return null;
28395
+ };
28396
+ var PieChartWrapper = import_react13.default.forwardRef(
28397
+ (props, ref) => {
28398
+ const {
28399
+ category = "pct_of_the_total",
28400
+ index = "status",
28401
+ data,
28402
+ colors = [],
28403
+ colorMap = {},
28404
+ variant = "donut",
28405
+ valueFormatter: valueFormatter2 = defaultValueFormatter,
28406
+ className,
28407
+ containerStyle,
28408
+ theme,
28409
+ onClickChartElement,
28410
+ yAxisFields,
28411
+ showLegend = false,
28412
+ ...other
28413
+ } = props;
28414
+ const isDonut = variant == "donut";
28415
+ if (!data || data.length === 0) {
28416
+ return /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
28417
+ "div",
28418
+ {
28419
+ style: {
28420
+ display: "flex",
28421
+ flex: "1 0 auto",
28422
+ // height: '100%',
28423
+ margin: "auto",
28424
+ justifyContent: "center",
28425
+ alignItems: "center",
28426
+ fontSize: 13,
28427
+ fontFamily: theme?.fontFamily,
28428
+ color: theme.secondaryTextColor,
28429
+ ...containerStyle
28430
+ },
28431
+ className,
28432
+ children: "No results"
28433
+ }
28434
+ );
28435
+ }
28436
+ return /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
28437
+ "div",
28438
+ {
28439
+ ref,
28440
+ className,
28441
+ style: {
28442
+ width: "100%",
28443
+ display: "flex",
28444
+ flexDirection: "row",
28445
+ alignItems: "center",
28446
+ justifyContent: "center",
28447
+ boxSizing: "content-box",
28448
+ ...containerStyle
28449
+ },
28450
+ ...other,
28451
+ children: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
28452
+ import_recharts.ResponsiveContainer,
28453
+ {
28454
+ width: "100%",
28455
+ height: "100%",
28456
+ minWidth: 0,
28457
+ minHeight: 0,
28458
+ children: /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)(import_recharts.PieChart, { children: [
28459
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
28460
+ import_recharts.Pie,
28461
+ {
28462
+ data: parseData2(
28463
+ data,
28464
+ (() => {
28465
+ const colorArray = colorMap[category] && colorMap[category]["primary"] && colorMap[category]["primary"] || colors;
28466
+ const containsCssVars = colorArray.some(
28467
+ (color2) => typeof color2 === "string" && color2.includes("var(")
28468
+ );
28469
+ if (containsCssVars) {
28470
+ return Array.from({ length: data.length }).map(
28471
+ (_, idx) => colorArray[idx % colorArray.length] ?? colorArray[colorArray.length - 1] ?? "#808080"
28472
+ );
28473
+ }
28474
+ return colorArray.length >= data.length ? colorArray.slice(0, data.length) : generateArrayFromColor(colorArray, data.length);
28475
+ })(),
28476
+ index,
28477
+ category
28478
+ ),
28479
+ cx: "50%",
28480
+ cy: "50%",
28481
+ startAngle: 90,
28482
+ endAngle: -270,
28483
+ innerRadius: isDonut ? showLegend ? "50%" : "70%" : "0%",
28484
+ outerRadius: showLegend ? "70%" : "100%",
28485
+ paddingAngle: 0,
28486
+ dataKey: category,
28487
+ nameKey: index,
28488
+ isAnimationActive: true,
28489
+ onClick: onClickChartElement,
28490
+ labelLine: false,
28491
+ label: false
28492
+ }
28493
+ ),
28494
+ showLegend && /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
28495
+ import_recharts.Legend,
28496
+ {
28497
+ verticalAlign: "top",
28498
+ align: "left",
28499
+ fontSize: 11,
28500
+ color: theme.secondaryTextColor,
28501
+ wrapperStyle: {
28502
+ paddingBottom: 20,
28503
+ fontFamily: theme?.fontFamily
28504
+ },
28505
+ content: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(RenderLegend, { limit: 5 })
28506
+ }
28507
+ ),
28508
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
28509
+ import_recharts.Tooltip,
28510
+ {
28511
+ wrapperStyle: {
28512
+ outline: "none"
28513
+ },
28514
+ content: ({ active, payload }) => {
28515
+ return /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
28516
+ DonutChartTooltip,
28517
+ {
28518
+ active,
28519
+ payload,
28520
+ valueFormatter: valueFormatter2,
28521
+ theme,
28522
+ yAxisFields
28523
+ }
28524
+ );
28525
+ }
28526
+ }
28527
+ )
28528
+ ] })
28529
+ }
28530
+ )
28531
+ }
28532
+ );
28533
+ }
28534
+ );
28535
+ var PieChart_default = PieChartWrapper;
28536
+
28537
+ // src/components/QuillTable.tsx
28538
+ var import_react14 = require("react");
28539
+ init_valueFormatter();
28540
+ var import_jsx_runtime29 = require("react/jsx-runtime");
28368
28541
  function QuillTable({
28369
28542
  rows,
28370
28543
  rowCount,
@@ -28393,18 +28566,18 @@ function QuillTable({
28393
28566
  borderTop,
28394
28567
  borderBottom
28395
28568
  }) {
28396
- const [activeRows, setActiveRows] = (0, import_react13.useState)([]);
28397
- const [maxPage, setMaxPage] = (0, import_react13.useState)(1);
28398
- const [sortColumn, setSortColumn] = (0, import_react13.useState)(sort?.field || "");
28399
- const [sortDirection, setSortDirection] = (0, import_react13.useState)(sort?.direction || "desc");
28400
- const [theme] = (0, import_react13.useContext)(ThemeContext);
28401
- const [isPaginating, setIsPaginating] = (0, import_react13.useState)(true);
28402
- const [initialLoad, setInitialLoad] = (0, import_react13.useState)(true);
28403
- (0, import_react13.useEffect)(() => {
28569
+ const [activeRows, setActiveRows] = (0, import_react14.useState)([]);
28570
+ const [maxPage, setMaxPage] = (0, import_react14.useState)(1);
28571
+ const [sortColumn, setSortColumn] = (0, import_react14.useState)(sort?.field || "");
28572
+ const [sortDirection, setSortDirection] = (0, import_react14.useState)(sort?.direction || "desc");
28573
+ const [theme] = (0, import_react14.useContext)(ThemeContext);
28574
+ const [isPaginating, setIsPaginating] = (0, import_react14.useState)(true);
28575
+ const [initialLoad, setInitialLoad] = (0, import_react14.useState)(true);
28576
+ (0, import_react14.useEffect)(() => {
28404
28577
  setSortColumn(sort?.field || "");
28405
28578
  setSortDirection(sort?.direction || "desc");
28406
28579
  }, [sort]);
28407
- (0, import_react13.useEffect)(() => {
28580
+ (0, import_react14.useEffect)(() => {
28408
28581
  if (rows?.length === 0 && isLoading) {
28409
28582
  return;
28410
28583
  }
@@ -28436,7 +28609,7 @@ function QuillTable({
28436
28609
  rowCount,
28437
28610
  isLoading
28438
28611
  ]);
28439
- (0, import_react13.useEffect)(() => {
28612
+ (0, import_react14.useEffect)(() => {
28440
28613
  if (rows.length <= currentPage * rowsPerPage) {
28441
28614
  onPageChange && onPageChange(0);
28442
28615
  setMaxPage(1);
@@ -28480,7 +28653,7 @@ function QuillTable({
28480
28653
  }
28481
28654
  };
28482
28655
  if (initialLoad) {
28483
- return /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
28656
+ return /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
28484
28657
  "div",
28485
28658
  {
28486
28659
  style: {
@@ -28488,11 +28661,11 @@ function QuillTable({
28488
28661
  ...containerStyle
28489
28662
  },
28490
28663
  className,
28491
- children: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(LoadingComponent, {})
28664
+ children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(LoadingComponent, {})
28492
28665
  }
28493
28666
  );
28494
28667
  }
28495
- return /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
28668
+ return /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
28496
28669
  "div",
28497
28670
  {
28498
28671
  style: {
@@ -28505,7 +28678,7 @@ function QuillTable({
28505
28678
  ...containerStyle
28506
28679
  },
28507
28680
  className,
28508
- children: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
28681
+ children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
28509
28682
  "div",
28510
28683
  {
28511
28684
  style: {
@@ -28524,7 +28697,7 @@ function QuillTable({
28524
28697
  outline: "none",
28525
28698
  position: "relative"
28526
28699
  },
28527
- children: /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)(
28700
+ children: /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)(
28528
28701
  "div",
28529
28702
  {
28530
28703
  role: "table",
@@ -28538,8 +28711,8 @@ function QuillTable({
28538
28711
  minHeight: "260px"
28539
28712
  },
28540
28713
  children: [
28541
- /* @__PURE__ */ (0, import_jsx_runtime28.jsx)("div", { style: { overflow: "auto", flexGrow: 1 }, children: /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)("div", { style: { minWidth: "100%", display: "inline-block" }, children: [
28542
- /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
28714
+ /* @__PURE__ */ (0, import_jsx_runtime29.jsx)("div", { style: { overflow: "auto", flexGrow: 1 }, children: /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)("div", { style: { minWidth: "100%", display: "inline-block" }, children: [
28715
+ /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
28543
28716
  "div",
28544
28717
  {
28545
28718
  className: "thead",
@@ -28549,7 +28722,7 @@ function QuillTable({
28549
28722
  zIndex: 1,
28550
28723
  background: headerBackgroundColor ?? "white"
28551
28724
  },
28552
- children: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
28725
+ children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
28553
28726
  "div",
28554
28727
  {
28555
28728
  role: "row",
@@ -28562,7 +28735,7 @@ function QuillTable({
28562
28735
  marginBottom: "-1px"
28563
28736
  // avoid double border
28564
28737
  },
28565
- children: columns && columns.map((column, index) => /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)(
28738
+ children: columns && columns.map((column, index) => /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)(
28566
28739
  "div",
28567
28740
  {
28568
28741
  onClick: (e) => {
@@ -28593,7 +28766,7 @@ function QuillTable({
28593
28766
  justifyContent: "space-between"
28594
28767
  },
28595
28768
  children: [
28596
- /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
28769
+ /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
28597
28770
  "div",
28598
28771
  {
28599
28772
  "aria-haspopup": "dialog",
@@ -28618,7 +28791,7 @@ function QuillTable({
28618
28791
  children: hideLabels || !column.label ? column.field : column.label
28619
28792
  }
28620
28793
  ),
28621
- column.field === sortColumn && /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
28794
+ column.field === sortColumn && /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
28622
28795
  "svg",
28623
28796
  {
28624
28797
  xmlns: "http://www.w3.org/2000/svg",
@@ -28629,7 +28802,7 @@ function QuillTable({
28629
28802
  style: {
28630
28803
  transform: sortDirection === "desc" ? "rotate(180deg)" : void 0
28631
28804
  },
28632
- children: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
28805
+ children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
28633
28806
  "path",
28634
28807
  {
28635
28808
  fillRule: "evenodd",
@@ -28647,15 +28820,15 @@ function QuillTable({
28647
28820
  )
28648
28821
  }
28649
28822
  ),
28650
- (isPaginating || isLoading) && /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
28823
+ (isPaginating || isLoading) && /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
28651
28824
  "div",
28652
28825
  {
28653
28826
  className,
28654
28827
  style: { position: "absolute", width: "100%" },
28655
- children: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(LoadingComponent, {})
28828
+ children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(LoadingComponent, {})
28656
28829
  }
28657
28830
  ),
28658
- activeRows && activeRows.length === 0 || columns && columns.length === 0 ? /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
28831
+ activeRows && activeRows.length === 0 || columns && columns.length === 0 ? /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
28659
28832
  "div",
28660
28833
  {
28661
28834
  style: {
@@ -28673,7 +28846,7 @@ function QuillTable({
28673
28846
  },
28674
28847
  children: emptyStateLabel
28675
28848
  }
28676
- ) : /* @__PURE__ */ (0, import_jsx_runtime28.jsx)("div", { role: "rowgroup", className: "tbody", children: activeRows && activeRows.map((row, rowIndex) => /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
28849
+ ) : /* @__PURE__ */ (0, import_jsx_runtime29.jsx)("div", { role: "rowgroup", className: "tbody", children: activeRows && activeRows.map((row, rowIndex) => /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
28677
28850
  "div",
28678
28851
  {
28679
28852
  role: "row",
@@ -28684,7 +28857,7 @@ function QuillTable({
28684
28857
  minWidth: "100px",
28685
28858
  boxSizing: "border-box"
28686
28859
  },
28687
- children: columns && columns.map((column, columnIndex) => /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
28860
+ children: columns && columns.map((column, columnIndex) => /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
28688
28861
  "div",
28689
28862
  {
28690
28863
  role: "cell",
@@ -28703,7 +28876,7 @@ function QuillTable({
28703
28876
  borderBottom: rowIndex === activeRows?.length - 1 ? "1px solid #E7E7E7" : void 0,
28704
28877
  userSelect: "none"
28705
28878
  },
28706
- children: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
28879
+ children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
28707
28880
  "div",
28708
28881
  {
28709
28882
  style: {
@@ -28715,7 +28888,7 @@ function QuillTable({
28715
28888
  userSelect: "none"
28716
28889
  },
28717
28890
  "data-testid": "static-cell",
28718
- children: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
28891
+ children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
28719
28892
  "div",
28720
28893
  {
28721
28894
  "aria-haspopup": "dialog",
@@ -28747,7 +28920,7 @@ function QuillTable({
28747
28920
  "sqlrow" + rowIndex
28748
28921
  )) })
28749
28922
  ] }) }),
28750
- /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
28923
+ /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
28751
28924
  "div",
28752
28925
  {
28753
28926
  style: {
@@ -28760,7 +28933,7 @@ function QuillTable({
28760
28933
  marginTop: "-1px"
28761
28934
  // avoid double border
28762
28935
  },
28763
- children: /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)(
28936
+ children: /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)(
28764
28937
  "div",
28765
28938
  {
28766
28939
  style: {
@@ -28772,7 +28945,7 @@ function QuillTable({
28772
28945
  height: 37
28773
28946
  },
28774
28947
  children: [
28775
- !hideCSVDownloadButton ? /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
28948
+ !hideCSVDownloadButton ? /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
28776
28949
  "button",
28777
28950
  {
28778
28951
  onClick: downloadCSV2,
@@ -28788,8 +28961,8 @@ function QuillTable({
28788
28961
  },
28789
28962
  children: "Download CSV"
28790
28963
  }
28791
- ) : /* @__PURE__ */ (0, import_jsx_runtime28.jsx)("div", {}),
28792
- rows.length === 0 || isLoading ? null : /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)(
28964
+ ) : /* @__PURE__ */ (0, import_jsx_runtime29.jsx)("div", {}),
28965
+ rows.length === 0 || isLoading ? null : /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)(
28793
28966
  "div",
28794
28967
  {
28795
28968
  style: {
@@ -28798,7 +28971,7 @@ function QuillTable({
28798
28971
  alignItems: "center"
28799
28972
  },
28800
28973
  children: [
28801
- /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)(
28974
+ /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)(
28802
28975
  "div",
28803
28976
  {
28804
28977
  style: {
@@ -28813,8 +28986,8 @@ function QuillTable({
28813
28986
  ]
28814
28987
  }
28815
28988
  ),
28816
- /* @__PURE__ */ (0, import_jsx_runtime28.jsx)("div", { style: { width: 8 } }),
28817
- /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
28989
+ /* @__PURE__ */ (0, import_jsx_runtime29.jsx)("div", { style: { width: 8 } }),
28990
+ /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
28818
28991
  "button",
28819
28992
  {
28820
28993
  onClick: (e) => {
@@ -28826,7 +28999,7 @@ function QuillTable({
28826
28999
  border: "none",
28827
29000
  background: "transparent"
28828
29001
  },
28829
- children: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
29002
+ children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
28830
29003
  "svg",
28831
29004
  {
28832
29005
  xmlns: "http://www.w3.org/2000/svg",
@@ -28834,7 +29007,7 @@ function QuillTable({
28834
29007
  fill: theme?.chartLabelFontFamily || theme?.fontFamily,
28835
29008
  height: "16px",
28836
29009
  width: "16px",
28837
- children: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
29010
+ children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
28838
29011
  "path",
28839
29012
  {
28840
29013
  fillRule: "evenodd",
@@ -28846,7 +29019,7 @@ function QuillTable({
28846
29019
  )
28847
29020
  }
28848
29021
  ),
28849
- /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
29022
+ /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
28850
29023
  "button",
28851
29024
  {
28852
29025
  onClick: (e) => {
@@ -28858,7 +29031,7 @@ function QuillTable({
28858
29031
  border: "none",
28859
29032
  background: "transparent"
28860
29033
  },
28861
- children: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
29034
+ children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
28862
29035
  "svg",
28863
29036
  {
28864
29037
  xmlns: "http://www.w3.org/2000/svg",
@@ -28866,7 +29039,7 @@ function QuillTable({
28866
29039
  fill: theme?.chartLabelFontFamily || theme?.fontFamily,
28867
29040
  height: "16px",
28868
29041
  width: "16px",
28869
- children: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
29042
+ children: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
28870
29043
  "path",
28871
29044
  {
28872
29045
  fillRule: "evenodd",
@@ -28878,7 +29051,7 @@ function QuillTable({
28878
29051
  )
28879
29052
  }
28880
29053
  ),
28881
- /* @__PURE__ */ (0, import_jsx_runtime28.jsx)("div", { style: { width: 12 } })
29054
+ /* @__PURE__ */ (0, import_jsx_runtime29.jsx)("div", { style: { width: 12 } })
28882
29055
  ]
28883
29056
  }
28884
29057
  )
@@ -29055,12 +29228,12 @@ var format_wo_yyyy2 = (value) => {
29055
29228
  var import_date_fns10 = require("date-fns");
29056
29229
 
29057
29230
  // src/components/Chart/ChartTooltipFrame.tsx
29058
- var import_jsx_runtime29 = require("react/jsx-runtime");
29231
+ var import_jsx_runtime30 = require("react/jsx-runtime");
29059
29232
  function ChartTooltipFrame2({
29060
29233
  children,
29061
29234
  theme
29062
29235
  }) {
29063
- return /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(
29236
+ return /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(
29064
29237
  "div",
29065
29238
  {
29066
29239
  style: {
@@ -29080,7 +29253,7 @@ function ChartTooltipFrame2({
29080
29253
  }
29081
29254
 
29082
29255
  // src/components/Chart/ChartTooltipRow.tsx
29083
- var import_jsx_runtime30 = require("react/jsx-runtime");
29256
+ var import_jsx_runtime31 = require("react/jsx-runtime");
29084
29257
  function ChartTooltipRow2({
29085
29258
  value,
29086
29259
  name: name2,
@@ -29088,7 +29261,7 @@ function ChartTooltipRow2({
29088
29261
  theme,
29089
29262
  hideDot = false
29090
29263
  }) {
29091
- return /* @__PURE__ */ (0, import_jsx_runtime30.jsxs)(
29264
+ return /* @__PURE__ */ (0, import_jsx_runtime31.jsxs)(
29092
29265
  "div",
29093
29266
  {
29094
29267
  style: {
@@ -29101,8 +29274,8 @@ function ChartTooltipRow2({
29101
29274
  paddingBottom: 2
29102
29275
  },
29103
29276
  children: [
29104
- /* @__PURE__ */ (0, import_jsx_runtime30.jsxs)("div", { style: { display: "flex", alignItems: "center" }, children: [
29105
- !hideDot && /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(
29277
+ /* @__PURE__ */ (0, import_jsx_runtime31.jsxs)("div", { style: { display: "flex", alignItems: "center" }, children: [
29278
+ !hideDot && /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(
29106
29279
  "span",
29107
29280
  {
29108
29281
  style: {
@@ -29119,7 +29292,7 @@ function ChartTooltipRow2({
29119
29292
  }
29120
29293
  }
29121
29294
  ),
29122
- /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(
29295
+ /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(
29123
29296
  "p",
29124
29297
  {
29125
29298
  style: {
@@ -29134,7 +29307,7 @@ function ChartTooltipRow2({
29134
29307
  }
29135
29308
  )
29136
29309
  ] }),
29137
- /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(
29310
+ /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(
29138
29311
  "p",
29139
29312
  {
29140
29313
  style: {
@@ -29158,14 +29331,14 @@ function ChartTooltipRow2({
29158
29331
  }
29159
29332
 
29160
29333
  // src/components/Chart/ChartTooltipGroup.tsx
29161
- var import_jsx_runtime31 = require("react/jsx-runtime");
29334
+ var import_jsx_runtime32 = require("react/jsx-runtime");
29162
29335
  function ChartTooltipGroup({
29163
29336
  name: name2,
29164
29337
  items,
29165
29338
  theme,
29166
29339
  hideDot = false
29167
29340
  }) {
29168
- return /* @__PURE__ */ (0, import_jsx_runtime31.jsxs)(
29341
+ return /* @__PURE__ */ (0, import_jsx_runtime32.jsxs)(
29169
29342
  "div",
29170
29343
  {
29171
29344
  style: {
@@ -29177,7 +29350,7 @@ function ChartTooltipGroup({
29177
29350
  marginRight: "24px"
29178
29351
  },
29179
29352
  children: [
29180
- /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(
29353
+ /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(
29181
29354
  "p",
29182
29355
  {
29183
29356
  style: {
@@ -29195,7 +29368,7 @@ function ChartTooltipGroup({
29195
29368
  children: name2.replaceAll("_", " ").toLowerCase()
29196
29369
  }
29197
29370
  ),
29198
- items.map(({ color: color2, value, name: name3 }, idx) => /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(
29371
+ items.map(({ color: color2, value, name: name3 }, idx) => /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(
29199
29372
  ChartTooltipRow2,
29200
29373
  {
29201
29374
  value,
@@ -29213,9 +29386,9 @@ function ChartTooltipGroup({
29213
29386
 
29214
29387
  // src/components/Chart/ChartTooltip.tsx
29215
29388
  init_dates();
29216
- var import_jsx_runtime32 = require("react/jsx-runtime");
29217
- var ChartTooltipPrimary = (props) => /* @__PURE__ */ (0, import_jsx_runtime32.jsxs)(ChartTooltipFrame2, { theme: props.theme, children: [
29218
- /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(
29389
+ var import_jsx_runtime33 = require("react/jsx-runtime");
29390
+ var ChartTooltipPrimary = (props) => /* @__PURE__ */ (0, import_jsx_runtime33.jsxs)(ChartTooltipFrame2, { theme: props.theme, children: [
29391
+ /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(
29219
29392
  "div",
29220
29393
  {
29221
29394
  style: {
@@ -29233,7 +29406,7 @@ var ChartTooltipPrimary = (props) => /* @__PURE__ */ (0, import_jsx_runtime32.js
29233
29406
  paddingTop: "8px",
29234
29407
  paddingBottom: "8px"
29235
29408
  },
29236
- children: /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(
29409
+ children: /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(
29237
29410
  "p",
29238
29411
  {
29239
29412
  style: {
@@ -29252,7 +29425,7 @@ var ChartTooltipPrimary = (props) => /* @__PURE__ */ (0, import_jsx_runtime32.js
29252
29425
  )
29253
29426
  }
29254
29427
  ),
29255
- /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(
29428
+ /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(
29256
29429
  "div",
29257
29430
  {
29258
29431
  style: {
@@ -29261,7 +29434,7 @@ var ChartTooltipPrimary = (props) => /* @__PURE__ */ (0, import_jsx_runtime32.js
29261
29434
  paddingTop: "8px",
29262
29435
  paddingBottom: "8px"
29263
29436
  },
29264
- children: props.payload.map(({ color: color2, value, name: name2 }, idx) => /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(
29437
+ children: props.payload.map(({ color: color2, value, name: name2 }, idx) => /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(
29265
29438
  ChartTooltipRow2,
29266
29439
  {
29267
29440
  value: props.valueFormatter(value, name2),
@@ -29342,8 +29515,8 @@ function ChartTooltipComparison(props) {
29342
29515
  presetLabel,
29343
29516
  convertComparisonRange(presetLabel, comparisonLabel)
29344
29517
  ) ?? {};
29345
- return /* @__PURE__ */ (0, import_jsx_runtime32.jsxs)(ChartTooltipFrame2, { theme: props.theme, children: [
29346
- /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(
29518
+ return /* @__PURE__ */ (0, import_jsx_runtime33.jsxs)(ChartTooltipFrame2, { theme: props.theme, children: [
29519
+ /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(
29347
29520
  "div",
29348
29521
  {
29349
29522
  style: {
@@ -29361,7 +29534,7 @@ function ChartTooltipComparison(props) {
29361
29534
  paddingTop: "8px",
29362
29535
  paddingBottom: "8px"
29363
29536
  },
29364
- children: /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(
29537
+ children: /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(
29365
29538
  "p",
29366
29539
  {
29367
29540
  style: {
@@ -29381,7 +29554,7 @@ function ChartTooltipComparison(props) {
29381
29554
  )
29382
29555
  }
29383
29556
  ),
29384
- /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(
29557
+ /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(
29385
29558
  "div",
29386
29559
  {
29387
29560
  style: {
@@ -29393,7 +29566,7 @@ function ChartTooltipComparison(props) {
29393
29566
  flexDirection: "column",
29394
29567
  gap: 4
29395
29568
  },
29396
- children: Object.entries(newRows).map(([key, value], index) => /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(
29569
+ children: Object.entries(newRows).map(([key, value], index) => /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(
29397
29570
  ChartTooltipGroup,
29398
29571
  {
29399
29572
  name: key,
@@ -29409,8 +29582,8 @@ function ChartTooltipComparison(props) {
29409
29582
  }
29410
29583
  function ChartTooltip(props) {
29411
29584
  if (!props.active || !props.payload) return null;
29412
- if (props.comparison) return /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(ChartTooltipComparison, { ...props });
29413
- return /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(ChartTooltipPrimary, { ...props });
29585
+ if (props.comparison) return /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(ChartTooltipComparison, { ...props });
29586
+ return /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(ChartTooltipPrimary, { ...props });
29414
29587
  }
29415
29588
 
29416
29589
  // src/utils/getDomain.ts
@@ -29486,7 +29659,7 @@ var import_react15 = require("react");
29486
29659
 
29487
29660
  // src/components/Chart/CustomReferenceLine.tsx
29488
29661
  init_constants();
29489
- var import_jsx_runtime33 = require("react/jsx-runtime");
29662
+ var import_jsx_runtime34 = require("react/jsx-runtime");
29490
29663
  function CustomReferenceLine({
29491
29664
  xAxisMap,
29492
29665
  yAxisMap,
@@ -29503,8 +29676,8 @@ function CustomReferenceLine({
29503
29676
  const y1 = yScale(referenceLine[0]);
29504
29677
  const y2 = yScale(referenceLine[1]);
29505
29678
  const textY = yScale(referenceLine[referenceLine.length - 1]) - 5;
29506
- return /* @__PURE__ */ (0, import_jsx_runtime33.jsxs)(import_jsx_runtime33.Fragment, { children: [
29507
- referenceLine.length === 2 && /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(
29679
+ return /* @__PURE__ */ (0, import_jsx_runtime34.jsxs)(import_jsx_runtime34.Fragment, { children: [
29680
+ referenceLine.length === 2 && /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(
29508
29681
  "line",
29509
29682
  {
29510
29683
  x1: xMin,
@@ -29520,7 +29693,7 @@ function CustomReferenceLine({
29520
29693
  referenceLine.length > 2 && referenceLine.slice(1).map((point, index) => {
29521
29694
  const x1 = xMin + (xMax - xMin) * (index / (referenceLine.length - 1));
29522
29695
  const x2 = xMin + (xMax - xMin) * ((index + 1) / (referenceLine.length - 1));
29523
- return /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(
29696
+ return /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(
29524
29697
  "line",
29525
29698
  {
29526
29699
  x1,
@@ -29535,7 +29708,7 @@ function CustomReferenceLine({
29535
29708
  index
29536
29709
  );
29537
29710
  }),
29538
- /* @__PURE__ */ (0, import_jsx_runtime33.jsxs)(
29711
+ /* @__PURE__ */ (0, import_jsx_runtime34.jsxs)(
29539
29712
  "text",
29540
29713
  {
29541
29714
  x: xMax - 5,
@@ -29558,56 +29731,6 @@ function CustomReferenceLine({
29558
29731
  ] });
29559
29732
  }
29560
29733
 
29561
- // src/components/Chart/CustomLegend.tsx
29562
- var import_react14 = require("react");
29563
- var import_jsx_runtime34 = require("react/jsx-runtime");
29564
- var RenderLegend = (props) => {
29565
- const { payload } = props;
29566
- const [theme] = (0, import_react14.useContext)(ThemeContext);
29567
- return /* @__PURE__ */ (0, import_jsx_runtime34.jsx)("div", { style: { display: "flex", justifyContent: "flex-start" }, children: payload.map((entry, index) => /* @__PURE__ */ (0, import_jsx_runtime34.jsxs)(
29568
- "div",
29569
- {
29570
- style: {
29571
- display: "flex",
29572
- alignItems: "center",
29573
- marginRight: "1rem"
29574
- },
29575
- children: [
29576
- /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(
29577
- "svg",
29578
- {
29579
- style: { marginRight: "0.5rem" },
29580
- width: "16",
29581
- height: "16",
29582
- viewBox: "0 0 16 16",
29583
- children: /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(
29584
- "rect",
29585
- {
29586
- width: "16",
29587
- height: "16",
29588
- rx: "3",
29589
- fill: payload?.[index]?.color
29590
- }
29591
- )
29592
- }
29593
- ),
29594
- /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(
29595
- "span",
29596
- {
29597
- style: {
29598
- color: theme?.secondaryTextColor,
29599
- fontFamily: theme?.fontFamily,
29600
- fontSize: theme?.fontSizeMedium || "14px"
29601
- },
29602
- children: entry.value
29603
- }
29604
- )
29605
- ]
29606
- },
29607
- `legend-${index}`
29608
- )) });
29609
- };
29610
-
29611
29734
  // src/components/Chart/LineChart.tsx
29612
29735
  var import_jsx_runtime35 = require("react/jsx-runtime");
29613
29736
  function createLineForEmptyChart(yAxisFields, dateFilter, xAxisField, xAxisFormat) {
@@ -32760,6 +32883,7 @@ var constructReportFromItem = (item) => {
32760
32883
  rows: [],
32761
32884
  columns: [],
32762
32885
  chartType: item.chartType,
32886
+ showLegend: item.showLegend,
32763
32887
  dateField: item.dateField,
32764
32888
  pivot: item.pivot,
32765
32889
  xAxisLabel: item.xAxisLabel,
@@ -36522,7 +36646,7 @@ var ChartDisplay = ({
36522
36646
  onClickChartElement,
36523
36647
  overrideTheme,
36524
36648
  referenceLines,
36525
- showLegend = false,
36649
+ showLegend,
36526
36650
  tableRowsLoading = false
36527
36651
  }) => {
36528
36652
  const { downloadCSV: downloadCSV2 } = useExport(reportId);
@@ -36555,6 +36679,7 @@ var ChartDisplay = ({
36555
36679
  }
36556
36680
  return void 0;
36557
36681
  }, [config, specificReportFilters, specificDashboardFilters]);
36682
+ const resolvedShowLegend = showLegend !== void 0 ? showLegend : config?.showLegend ?? false;
36558
36683
  const [page, setPage] = (0, import_react30.useState)(0);
36559
36684
  if (loading) {
36560
36685
  return /* @__PURE__ */ (0, import_jsx_runtime49.jsx)("div", { className, style: containerStyle, children: /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(LoadingComponent, {}) });
@@ -36590,7 +36715,7 @@ var ChartDisplay = ({
36590
36715
  colorMap,
36591
36716
  onClickChartElement,
36592
36717
  yAxisFields: config?.yAxisFields,
36593
- showLegend
36718
+ showLegend: resolvedShowLegend
36594
36719
  }
36595
36720
  );
36596
36721
  }
@@ -36664,7 +36789,7 @@ var ChartDisplay = ({
36664
36789
  onClickChartElement,
36665
36790
  dateFilter: !hideDateRangeFilter ? dateFilter : void 0,
36666
36791
  referenceLines,
36667
- showLegend
36792
+ showLegend: resolvedShowLegend
36668
36793
  }
36669
36794
  );
36670
36795
  }
@@ -36691,7 +36816,7 @@ var ChartDisplay = ({
36691
36816
  onClickChartElement,
36692
36817
  dateFilter: !hideDateRangeFilter ? dateFilter : void 0,
36693
36818
  referenceLines,
36694
- showLegend,
36819
+ showLegend: resolvedShowLegend,
36695
36820
  stackedMode: true
36696
36821
  }
36697
36822
  );
@@ -36835,7 +36960,7 @@ var ChartDisplay = ({
36835
36960
  onClickChartElement,
36836
36961
  dateFilter: !hideDateRangeFilter ? dateFilter : void 0,
36837
36962
  referenceLines,
36838
- showLegend
36963
+ showLegend: resolvedShowLegend
36839
36964
  }
36840
36965
  );
36841
36966
  };
@@ -44186,6 +44311,7 @@ function ChartBuilder({
44186
44311
  ],
44187
44312
  xAxisLabel: "",
44188
44313
  chartType: firstNumberColumn ? "line" : "table",
44314
+ showLegend: report?.showLegend ?? false,
44189
44315
  pivot: null,
44190
44316
  dateField: defaultDateField,
44191
44317
  template: true,
@@ -46151,6 +46277,19 @@ function ChartBuilder({
46151
46277
  ) })
46152
46278
  ] })
46153
46279
  ] }),
46280
+ ["line", "column", "stacked", "pie"].includes(
46281
+ (chartData.chartType ?? "").toLowerCase()
46282
+ ) && /* @__PURE__ */ (0, import_jsx_runtime66.jsxs)("div", { children: [
46283
+ /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(SubHeaderComponent, { label: "Legend" }),
46284
+ /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(ChartBuilderInputRowContainer, { children: /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(
46285
+ CheckboxComponent,
46286
+ {
46287
+ isChecked: !!formData.showLegend,
46288
+ label: "Show legend",
46289
+ onChange: () => handleChange(!formData.showLegend, "showLegend")
46290
+ }
46291
+ ) })
46292
+ ] }),
46154
46293
  client?.featureFlags?.["referenceLines"] && (chartData.chartType === "line" || chartData.chartType === "column") && /* @__PURE__ */ (0, import_jsx_runtime66.jsxs)("div", { children: [
46155
46294
  /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(SubHeaderComponent, { label: "Reference Lines" }),
46156
46295
  /* @__PURE__ */ (0, import_jsx_runtime66.jsxs)(ChartBuilderInputColumnContainer, { children: [
@@ -54108,7 +54247,7 @@ function StaticChart(props) {
54108
54247
  reportId,
54109
54248
  onClickChartElement,
54110
54249
  containerStyle,
54111
- showLegend = false,
54250
+ showLegend,
54112
54251
  className
54113
54252
  } = props;
54114
54253
  const {