@trops/dash-core 0.1.396 → 0.1.397
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 +42 -5
- package/dist/index.esm.js.map +1 -1
- package/dist/index.js +42 -5
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -55519,7 +55519,11 @@ var DashboardStageInner = function DashboardStageInner(_ref3) {
|
|
|
55519
55519
|
sidebarEnabled: sidebarEnabled,
|
|
55520
55520
|
onSidebarChange: popout ? null : handleSidebarToggle,
|
|
55521
55521
|
scrollableEnabled: workspacePages.length <= 1 ? getRootScrollable() : undefined,
|
|
55522
|
-
onScrollableChange: workspacePages.length <= 1 && !popout ? handleScrollableChange : null
|
|
55522
|
+
onScrollableChange: workspacePages.length <= 1 && !popout ? handleScrollableChange : null,
|
|
55523
|
+
onOpenConfig: popout ? null : function () {
|
|
55524
|
+
return setIsConfigModalOpen(true);
|
|
55525
|
+
},
|
|
55526
|
+
configUnresolvedCount: unresolvedCount
|
|
55523
55527
|
}), /*#__PURE__*/jsxRuntime.jsxs(DashboardThemeProvider, {
|
|
55524
55528
|
themeKey: workspaceSelected === null || workspaceSelected === void 0 ? void 0 : workspaceSelected.themeKey,
|
|
55525
55529
|
children: [hasMissing && missingComponents.length >= 2 && !dismissedMissingForWorkspace.has(workspaceSelected === null || workspaceSelected === void 0 ? void 0 : workspaceSelected.id) && /*#__PURE__*/jsxRuntime.jsxs("div", {
|
|
@@ -55959,7 +55963,11 @@ var DashboardHeader = function DashboardHeader(_ref) {
|
|
|
55959
55963
|
_ref$sidebarEnabled = _ref.sidebarEnabled,
|
|
55960
55964
|
sidebarEnabled = _ref$sidebarEnabled === void 0 ? false : _ref$sidebarEnabled,
|
|
55961
55965
|
_ref$onSidebarChange = _ref.onSidebarChange,
|
|
55962
|
-
onSidebarChange = _ref$onSidebarChange === void 0 ? null : _ref$onSidebarChange
|
|
55966
|
+
onSidebarChange = _ref$onSidebarChange === void 0 ? null : _ref$onSidebarChange,
|
|
55967
|
+
_ref$onOpenConfig = _ref.onOpenConfig,
|
|
55968
|
+
onOpenConfig = _ref$onOpenConfig === void 0 ? null : _ref$onOpenConfig,
|
|
55969
|
+
_ref$configUnresolved = _ref.configUnresolvedCount,
|
|
55970
|
+
configUnresolvedCount = _ref$configUnresolved === void 0 ? 0 : _ref$configUnresolved;
|
|
55963
55971
|
var _useState = React.useState(workspace),
|
|
55964
55972
|
_useState2 = _slicedToArray(_useState, 2),
|
|
55965
55973
|
workspaceSelected = _useState2[0],
|
|
@@ -55986,7 +55994,10 @@ var DashboardHeader = function DashboardHeader(_ref) {
|
|
|
55986
55994
|
className: "font-bold text-base"
|
|
55987
55995
|
}), /*#__PURE__*/jsxRuntime.jsxs("div", {
|
|
55988
55996
|
className: "flex flex-row items-center gap-1",
|
|
55989
|
-
children: [
|
|
55997
|
+
children: [onOpenConfig !== null && /*#__PURE__*/jsxRuntime.jsx(DashboardConfigButton, {
|
|
55998
|
+
onClick: onOpenConfig,
|
|
55999
|
+
unresolvedCount: configUnresolvedCount
|
|
56000
|
+
}), onPopout !== null && /*#__PURE__*/jsxRuntime.jsx(DashReact.ButtonIcon, {
|
|
55990
56001
|
icon: "arrow-up-right-from-square",
|
|
55991
56002
|
onClick: onPopout,
|
|
55992
56003
|
hoverBackgroundColor: "hover:bg-indigo-700"
|
|
@@ -56079,8 +56090,11 @@ var DashboardHeader = function DashboardHeader(_ref) {
|
|
|
56079
56090
|
setEnabled: onSidebarChange
|
|
56080
56091
|
})]
|
|
56081
56092
|
}), /*#__PURE__*/jsxRuntime.jsxs("div", {
|
|
56082
|
-
className: "flex flex-row space-x-1 shrink-0",
|
|
56083
|
-
children: [
|
|
56093
|
+
className: "flex flex-row space-x-1 shrink-0 items-center",
|
|
56094
|
+
children: [onOpenConfig !== null && /*#__PURE__*/jsxRuntime.jsx(DashboardConfigButton, {
|
|
56095
|
+
onClick: onOpenConfig,
|
|
56096
|
+
unresolvedCount: configUnresolvedCount
|
|
56097
|
+
}), onClickEdit !== null && /*#__PURE__*/jsxRuntime.jsx(DashReact.ButtonIcon2, {
|
|
56084
56098
|
icon: "xmark",
|
|
56085
56099
|
text: "Cancel",
|
|
56086
56100
|
onClick: onClickEdit,
|
|
@@ -56097,6 +56111,29 @@ var DashboardHeader = function DashboardHeader(_ref) {
|
|
|
56097
56111
|
});
|
|
56098
56112
|
};
|
|
56099
56113
|
|
|
56114
|
+
/**
|
|
56115
|
+
* DashboardConfigButton — gear icon with an optional amber dot when the
|
|
56116
|
+
* current dashboard has unresolved provider bindings. Opens the
|
|
56117
|
+
* Dashboard Config modal. Kept local to DashboardHeader because no
|
|
56118
|
+
* other caller needs it.
|
|
56119
|
+
*/
|
|
56120
|
+
function DashboardConfigButton(_ref8) {
|
|
56121
|
+
var onClick = _ref8.onClick,
|
|
56122
|
+
_ref8$unresolvedCount = _ref8.unresolvedCount,
|
|
56123
|
+
unresolvedCount = _ref8$unresolvedCount === void 0 ? 0 : _ref8$unresolvedCount;
|
|
56124
|
+
return /*#__PURE__*/jsxRuntime.jsxs("div", {
|
|
56125
|
+
className: "relative inline-flex",
|
|
56126
|
+
children: [/*#__PURE__*/jsxRuntime.jsx(DashReact.ButtonIcon, {
|
|
56127
|
+
icon: "sliders",
|
|
56128
|
+
onClick: onClick,
|
|
56129
|
+
hoverBackgroundColor: "hover:bg-indigo-700"
|
|
56130
|
+
}), unresolvedCount > 0 && /*#__PURE__*/jsxRuntime.jsx("span", {
|
|
56131
|
+
className: "absolute top-1 right-1 h-2 w-2 rounded-full bg-amber-400 border border-black/40 pointer-events-none",
|
|
56132
|
+
title: "".concat(unresolvedCount, " unresolved provider").concat(unresolvedCount === 1 ? "" : "s")
|
|
56133
|
+
})]
|
|
56134
|
+
});
|
|
56135
|
+
}
|
|
56136
|
+
|
|
56100
56137
|
function ownKeys$4(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
56101
56138
|
function _objectSpread$4(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$4(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$4(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
56102
56139
|
var MAX_LOG_ENTRIES = 200;
|