@trops/dash-core 0.1.270 → 0.1.272
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.esm.js +15 -35
- package/dist/index.esm.js.map +1 -1
- package/dist/index.js +15 -35
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -23933,20 +23933,21 @@ var ExternalWidget = function ExternalWidget(_ref) {
|
|
|
23933
23933
|
description = _ref.description,
|
|
23934
23934
|
icon = _ref.icon;
|
|
23935
23935
|
_objectWithoutProperties(_ref, _excluded$3);
|
|
23936
|
-
return /*#__PURE__*/jsxRuntime.
|
|
23937
|
-
|
|
23938
|
-
|
|
23939
|
-
|
|
23940
|
-
|
|
23941
|
-
|
|
23942
|
-
|
|
23943
|
-
|
|
23944
|
-
|
|
23945
|
-
|
|
23946
|
-
|
|
23947
|
-
|
|
23948
|
-
|
|
23949
|
-
|
|
23936
|
+
return /*#__PURE__*/jsxRuntime.jsxs("div", {
|
|
23937
|
+
className: "flex flex-col h-full justify-center items-center w-full gap-2 p-4 text-center",
|
|
23938
|
+
children: [/*#__PURE__*/jsxRuntime.jsx(DashReact.FontAwesomeIcon, {
|
|
23939
|
+
icon: icon || "triangle-exclamation",
|
|
23940
|
+
className: "h-5 w-5 text-amber-500"
|
|
23941
|
+
}), /*#__PURE__*/jsxRuntime.jsx("div", {
|
|
23942
|
+
className: "text-sm font-semibold text-gray-300",
|
|
23943
|
+
children: "Widget Unavailable"
|
|
23944
|
+
}), title && /*#__PURE__*/jsxRuntime.jsx("div", {
|
|
23945
|
+
className: "text-xs text-gray-500 font-mono",
|
|
23946
|
+
children: title
|
|
23947
|
+
}), /*#__PURE__*/jsxRuntime.jsx("div", {
|
|
23948
|
+
className: "text-xs text-gray-600 mt-1",
|
|
23949
|
+
children: description || "Check widget configuration or reinstall from the registry."
|
|
23950
|
+
})]
|
|
23950
23951
|
});
|
|
23951
23952
|
};
|
|
23952
23953
|
|
|
@@ -26625,13 +26626,6 @@ function isWidgetResolvable(componentKey) {
|
|
|
26625
26626
|
if (m[componentKey] && typeof m[componentKey].component === "function") {
|
|
26626
26627
|
return true;
|
|
26627
26628
|
}
|
|
26628
|
-
// Fallback: match by config.name (mirrors getComponent's name fallback)
|
|
26629
|
-
for (var _i = 0, _Object$keys = Object.keys(m); _i < _Object$keys.length; _i++) {
|
|
26630
|
-
var key = _Object$keys[_i];
|
|
26631
|
-
if (m[key].name === componentKey && typeof m[key].component === "function") {
|
|
26632
|
-
return true;
|
|
26633
|
-
}
|
|
26634
|
-
}
|
|
26635
26629
|
return false;
|
|
26636
26630
|
}
|
|
26637
26631
|
|
|
@@ -29504,20 +29498,6 @@ var ComponentManager = {
|
|
|
29504
29498
|
var m = this.componentMap();
|
|
29505
29499
|
// Try exact match first (works for both scoped ids and legacy names)
|
|
29506
29500
|
var cmp = component in m ? m[component] : null;
|
|
29507
|
-
|
|
29508
|
-
// Fallback: scan by config.name for backward compatibility
|
|
29509
|
-
// Handles saved layouts that reference old-style names (e.g., "AnalogClockWidget")
|
|
29510
|
-
// when the widget is now registered under a scoped id (e.g., "trops.clock.AnalogClockWidget")
|
|
29511
|
-
if (cmp === null) {
|
|
29512
|
-
for (var _i = 0, _Object$keys = Object.keys(m); _i < _Object$keys.length; _i++) {
|
|
29513
|
-
var key = _Object$keys[_i];
|
|
29514
|
-
if (m[key].name === component) {
|
|
29515
|
-
cmp = m[key];
|
|
29516
|
-
cmp["componentName"] = key;
|
|
29517
|
-
return cmp;
|
|
29518
|
-
}
|
|
29519
|
-
}
|
|
29520
|
-
}
|
|
29521
29501
|
if (cmp !== null) {
|
|
29522
29502
|
cmp["componentName"] = component;
|
|
29523
29503
|
return cmp;
|