@devtron-labs/devtron-fe-common-lib 0.0.75-beta-33 → 0.0.75-beta-34

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.
@@ -6,4 +6,6 @@ export type Entity = {
6
6
  export interface SegmentedBarChartProps {
7
7
  entities: NonNullable<Entity[]>;
8
8
  rootClassName?: string;
9
+ countClassName?: string;
10
+ labelClassName?: string;
9
11
  }
package/dist/index.js CHANGED
@@ -18653,21 +18653,26 @@ const S9 = ({ value: e, isSelected: t, selectPage: n }) => {
18653
18653
  label: "-",
18654
18654
  value: 0
18655
18655
  };
18656
- const j9 = ({ entities: e = [D9], rootClassName: t }) => {
18657
- const n = e.reduce((a, s) => s.value + a, 0), r = (a) => a.value ? `${a.value / n * 100}%` : "100%";
18656
+ const j9 = ({
18657
+ entities: e = [D9],
18658
+ rootClassName: t,
18659
+ countClassName: n,
18660
+ labelClassName: r
18661
+ }) => {
18662
+ const a = e.reduce((i, o) => o.value + i, 0), s = (i) => i.value ? `${i.value / a * 100}%` : "100%";
18658
18663
  return /* @__PURE__ */ l.jsxs("div", { className: `flexbox-col w-100 dc__gap-12 ${t}`, children: [
18659
- /* @__PURE__ */ l.jsx("div", { className: "flexbox dc__gap-16", children: e?.map((a) => /* @__PURE__ */ l.jsxs("div", { className: "flexbox dc__gap-4 dc__align-items-center", children: [
18660
- /* @__PURE__ */ l.jsx("div", { className: "dot", style: { backgroundColor: a.color, width: "10px", height: "10px" } }),
18661
- /* @__PURE__ */ l.jsx("span", { children: a.value }),
18662
- /* @__PURE__ */ l.jsx("span", { children: a.label })
18664
+ /* @__PURE__ */ l.jsx("div", { className: "flexbox dc__gap-16", children: e?.map((i) => /* @__PURE__ */ l.jsxs("div", { className: "flexbox dc__gap-4 dc__align-items-center", children: [
18665
+ /* @__PURE__ */ l.jsx("div", { className: "dot", style: { backgroundColor: i.color, width: "10px", height: "10px" } }),
18666
+ /* @__PURE__ */ l.jsx("span", { className: n, children: i.value }),
18667
+ /* @__PURE__ */ l.jsx("span", { className: r, children: i.label })
18663
18668
  ] })) }),
18664
- /* @__PURE__ */ l.jsx("div", { className: "flexbox dc__gap-2", children: e?.map((a, s, i) => /* @__PURE__ */ l.jsx(
18669
+ /* @__PURE__ */ l.jsx("div", { className: "flexbox dc__gap-2", children: e?.map((i, o, c) => /* @__PURE__ */ l.jsx(
18665
18670
  "div",
18666
18671
  {
18667
- className: `h-8 ${s === 0 ? "dc__left-radius-4" : ""} ${s === i.length - 1 ? "dc__right-radius-4" : ""}`,
18668
- style: { backgroundColor: a.color, width: r(a) }
18672
+ className: `h-8 ${o === 0 ? "dc__left-radius-4" : ""} ${o === c.length - 1 ? "dc__right-radius-4" : ""}`,
18673
+ style: { backgroundColor: i.color, width: s(i) }
18669
18674
  },
18670
- a.label
18675
+ i.label
18671
18676
  )) })
18672
18677
  ] });
18673
18678
  }, mj = j9, L9 = (e) => /* @__PURE__ */ N.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", width: 20, height: 20, viewBox: "0 0 20 20", fill: "none", ...e }, /* @__PURE__ */ N.createElement("path", { d: "M12.5 5.625H7.5M12.5 8.125H7.5M15.625 3.125V16.875C15.625 17.2202 15.3452 17.5 15 17.5H5C4.65482 17.5 4.375 17.2202 4.375 16.875V3.125C4.375 2.77982 4.65482 2.5 5 2.5H15C15.3452 2.5 15.625 2.77982 15.625 3.125Z", stroke: "#596168", strokeWidth: 1.5, strokeLinecap: "round", strokeLinejoin: "round" }), /* @__PURE__ */ N.createElement("path", { d: "M10 15C10.5178 15 10.9375 14.5803 10.9375 14.0625C10.9375 13.5447 10.5178 13.125 10 13.125C9.48223 13.125 9.0625 13.5447 9.0625 14.0625C9.0625 14.5803 9.48223 15 10 15Z", fill: "#596168" })), P9 = (e) => /* @__PURE__ */ N.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", width: 20, height: 20, viewBox: "0 0 20 20", fill: "none", ...e }, /* @__PURE__ */ N.createElement("path", { d: "M16.25 8.125H18.125M16.25 11.875H18.125M1.875 8.125H3.75M1.875 11.875H3.75M11.875 16.25V18.125M8.125 16.25V18.125M11.875 1.875V3.75M8.125 1.875V3.75M7.8125 7.8125H12.1875V12.1875H7.8125V7.8125ZM4.375 3.75H15.625C15.9702 3.75 16.25 4.02982 16.25 4.375V15.625C16.25 15.9702 15.9702 16.25 15.625 16.25H4.375C4.02982 16.25 3.75 15.9702 3.75 15.625V4.375C3.75 4.02982 4.02982 3.75 4.375 3.75Z", stroke: "#596168", strokeWidth: 1.5, strokeLinecap: "round", strokeLinejoin: "round" })), B9 = (e) => /* @__PURE__ */ N.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", width: 20, height: 20, viewBox: "0 0 20 20", fill: "none", ...e }, /* @__PURE__ */ N.createElement("path", { d: "M10 11.0415L13.0936 7.94791M8.125 1.6665H11.875M16.875 11.0415C16.875 14.8385 13.797 17.9165 10 17.9165C6.20304 17.9165 3.125 14.8385 3.125 11.0415C3.125 7.24455 6.20304 4.1665 10 4.1665C13.797 4.1665 16.875 7.24455 16.875 11.0415Z", stroke: "#596168", strokeWidth: 1.5, strokeLinecap: "round", strokeLinejoin: "round" }));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@devtron-labs/devtron-fe-common-lib",
3
- "version": "0.0.75-beta-33",
3
+ "version": "0.0.75-beta-34",
4
4
  "description": "Supporting common component library",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",