@cardenelabs/cdl 0.62.0 → 0.64.0
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/CHANGELOG.md +39 -1
- package/dist/index.cjs +17 -17
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.js +17 -17
- package/dist/index.js.map +1 -1
- package/dist/react.cjs +8 -11
- package/dist/react.cjs.map +1 -1
- package/dist/react.d.cts +1 -1
- package/dist/react.d.ts +1 -1
- package/dist/react.js +8 -11
- package/dist/react.js.map +1 -1
- package/dist/{render-Dk8_6ua6.d.cts → render-DfXCs3Eh.d.cts} +4 -1
- package/dist/{render-Dk8_6ua6.d.ts → render-DfXCs3Eh.d.ts} +4 -1
- package/package.json +12 -9
- package/src/presets.ts +13 -6
- package/src/render/interactive-panel.tsx +14 -10
- package/src/types.ts +4 -1
package/dist/react.d.cts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import 'react';
|
|
2
|
-
export { s as CdlDiagramView, o as CdlDiagramViewProps } from './render-
|
|
2
|
+
export { s as CdlDiagramView, o as CdlDiagramViewProps } from './render-DfXCs3Eh.cjs';
|
package/dist/react.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import 'react';
|
|
2
|
-
export { s as CdlDiagramView, o as CdlDiagramViewProps } from './render-
|
|
2
|
+
export { s as CdlDiagramView, o as CdlDiagramViewProps } from './render-DfXCs3Eh.js';
|
package/dist/react.js
CHANGED
|
@@ -21184,16 +21184,12 @@ function ReadoutWidget({
|
|
|
21184
21184
|
colors: readout.colors ?? ["#e0e6ef", "#2d6a8f"]
|
|
21185
21185
|
}
|
|
21186
21186
|
);
|
|
21187
|
-
case "badge":
|
|
21188
|
-
|
|
21189
|
-
|
|
21190
|
-
|
|
21191
|
-
|
|
21192
|
-
|
|
21193
|
-
value: typeof rawValue === "string" ? rawValue : String(rawValue ?? ""),
|
|
21194
|
-
map: readout.map
|
|
21195
|
-
}
|
|
21196
|
-
);
|
|
21187
|
+
case "badge": {
|
|
21188
|
+
const value = typeof rawValue === "string" ? rawValue : String(rawValue ?? "");
|
|
21189
|
+
const colorRaw = readout.colorSource === void 0 ? void 0 : stateOverrides[readout.colorSource];
|
|
21190
|
+
const colorKey = readout.colorSource === void 0 ? value : colorRaw === void 0 ? void 0 : String(colorRaw);
|
|
21191
|
+
return /* @__PURE__ */ jsx(BadgeReadout, { id: readout.id, label, value, colorKey, map: readout.map });
|
|
21192
|
+
}
|
|
21197
21193
|
case "status-dot":
|
|
21198
21194
|
return /* @__PURE__ */ jsx(
|
|
21199
21195
|
StatusDotReadout,
|
|
@@ -22915,9 +22911,10 @@ function BadgeReadout({
|
|
|
22915
22911
|
id,
|
|
22916
22912
|
label,
|
|
22917
22913
|
value,
|
|
22914
|
+
colorKey,
|
|
22918
22915
|
map
|
|
22919
22916
|
}) {
|
|
22920
|
-
const entry = map?.find((m) => m.value ===
|
|
22917
|
+
const entry = colorKey === void 0 ? void 0 : map?.find((m) => m.value === colorKey);
|
|
22921
22918
|
const color = entry?.color;
|
|
22922
22919
|
return /* @__PURE__ */ jsxs("div", { className: "cdl-ip-item cdl-ip-readout-badge", "data-cdl-readout": id, children: [
|
|
22923
22920
|
/* @__PURE__ */ jsx("span", { className: "cdl-ip-label", children: label }),
|