@inf-monkeys-tech/monkeys-design 1.0.111 → 1.0.112
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/components/data-explorer/index.js +7 -1
- package/dist/components/data-explorer/index.js.map +1 -1
- package/dist/components/data-explorer/index.mjs +7 -1
- package/dist/components/data-explorer/index.mjs.map +1 -1
- package/dist/components/navigation-sidebar/index.js +122 -53
- package/dist/components/navigation-sidebar/index.js.map +1 -1
- package/dist/components/navigation-sidebar/index.mjs +122 -53
- package/dist/components/navigation-sidebar/index.mjs.map +1 -1
- package/dist/components/workbench/index.js +122 -53
- package/dist/components/workbench/index.js.map +1 -1
- package/dist/components/workbench/index.mjs +122 -53
- package/dist/components/workbench/index.mjs.map +1 -1
- package/dist/index.js +122 -53
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +122 -53
- package/dist/index.mjs.map +1 -1
- package/dist/styles.css +1 -1
- package/package.json +1 -1
|
@@ -502,7 +502,13 @@ function mergeStyles(...sources) {
|
|
|
502
502
|
);
|
|
503
503
|
}
|
|
504
504
|
function getPresetDefaults(preset) {
|
|
505
|
-
|
|
505
|
+
const defaults = presetDefaults[preset];
|
|
506
|
+
if (!defaults) {
|
|
507
|
+
throw new TypeError(
|
|
508
|
+
`Unknown Data Explorer theme preset "${String(preset)}". Expected one of: ${Object.keys(presetDefaults).join(", ")}.`
|
|
509
|
+
);
|
|
510
|
+
}
|
|
511
|
+
return defaults;
|
|
506
512
|
}
|
|
507
513
|
function resolveDataExplorerAppearance(appearance) {
|
|
508
514
|
const preset = appearance?.preset ?? "default";
|
|
@@ -3228,7 +3234,46 @@ function resolveAppearance(appearance) {
|
|
|
3228
3234
|
surface === "outlined" && "border-border bg-background text-foreground shadow-none"
|
|
3229
3235
|
),
|
|
3230
3236
|
itemHeight: density === "compact" ? "min-h-9" : density === "comfortable" ? "min-h-14" : "min-h-11",
|
|
3231
|
-
itemPadding: density === "compact" ? "px-2 py-1.5" : density === "comfortable" ? "px-3 py-3" : "px-3 py-2"
|
|
3237
|
+
itemPadding: density === "compact" ? "px-2 py-1.5" : density === "comfortable" ? "px-3 py-3" : "px-3 py-2",
|
|
3238
|
+
searchHeight: density === "compact" ? "h-8" : density === "comfortable" ? "h-10" : "h-9"
|
|
3239
|
+
};
|
|
3240
|
+
}
|
|
3241
|
+
var navigationTreeRowHoverClassName = "hover:bg-[var(--monkeys-component-navigation-sidebar-tree-row-hover-background,hsl(var(--muted)))] hover:text-[var(--monkeys-component-navigation-sidebar-tree-row-hover-foreground,hsl(var(--foreground)))]";
|
|
3242
|
+
var navigationTreeRowSelectedClassName = "bg-[var(--monkeys-component-navigation-sidebar-tree-row-selected-background,hsl(var(--accent)))] text-[var(--monkeys-component-navigation-sidebar-tree-row-selected-foreground,hsl(var(--accent-foreground)))] hover:bg-[var(--monkeys-component-navigation-sidebar-tree-row-selected-background,hsl(var(--accent)))] hover:text-[var(--monkeys-component-navigation-sidebar-tree-row-selected-foreground,hsl(var(--accent-foreground)))]";
|
|
3243
|
+
var navigationTreeNestedControlClassName = "hover:!bg-transparent hover:!text-inherit focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring";
|
|
3244
|
+
function resolveNavigationTreeClassNames(classNames) {
|
|
3245
|
+
return {
|
|
3246
|
+
...classNames,
|
|
3247
|
+
groupHeader: cn(navigationTreeRowHoverClassName, classNames?.groupHeader),
|
|
3248
|
+
itemSelected: cn(
|
|
3249
|
+
navigationTreeRowSelectedClassName,
|
|
3250
|
+
classNames?.itemSelected
|
|
3251
|
+
),
|
|
3252
|
+
nodeButton: cn(
|
|
3253
|
+
navigationTreeRowHoverClassName,
|
|
3254
|
+
"aria-selected:bg-[var(--monkeys-component-navigation-sidebar-tree-row-selected-background,hsl(var(--accent)))] aria-selected:text-[var(--monkeys-component-navigation-sidebar-tree-row-selected-foreground,hsl(var(--accent-foreground)))] aria-selected:hover:bg-[var(--monkeys-component-navigation-sidebar-tree-row-selected-background,hsl(var(--accent)))] aria-selected:hover:text-[var(--monkeys-component-navigation-sidebar-tree-row-selected-foreground,hsl(var(--accent-foreground)))]",
|
|
3255
|
+
classNames?.nodeButton
|
|
3256
|
+
),
|
|
3257
|
+
expander: cn(
|
|
3258
|
+
navigationTreeNestedControlClassName,
|
|
3259
|
+
classNames?.expander
|
|
3260
|
+
),
|
|
3261
|
+
nodeToggle: cn(
|
|
3262
|
+
navigationTreeNestedControlClassName,
|
|
3263
|
+
classNames?.nodeToggle
|
|
3264
|
+
),
|
|
3265
|
+
groupActions: cn(
|
|
3266
|
+
navigationTreeNestedControlClassName,
|
|
3267
|
+
classNames?.groupActions
|
|
3268
|
+
),
|
|
3269
|
+
nodeActions: cn(
|
|
3270
|
+
navigationTreeNestedControlClassName,
|
|
3271
|
+
classNames?.nodeActions
|
|
3272
|
+
),
|
|
3273
|
+
nodeDragHandle: cn(
|
|
3274
|
+
navigationTreeNestedControlClassName,
|
|
3275
|
+
classNames?.nodeDragHandle
|
|
3276
|
+
)
|
|
3232
3277
|
};
|
|
3233
3278
|
}
|
|
3234
3279
|
function EntryButton({
|
|
@@ -3851,7 +3896,13 @@ function NavigationSidebarInner(props, ref) {
|
|
|
3851
3896
|
);
|
|
3852
3897
|
}
|
|
3853
3898
|
const treeProps = props.tree;
|
|
3854
|
-
return /* @__PURE__ */ jsx(
|
|
3899
|
+
return /* @__PURE__ */ jsx(
|
|
3900
|
+
DataExplorerViewTree,
|
|
3901
|
+
{
|
|
3902
|
+
...treeProps,
|
|
3903
|
+
classNames: resolveNavigationTreeClassNames(treeProps.classNames)
|
|
3904
|
+
}
|
|
3905
|
+
);
|
|
3855
3906
|
};
|
|
3856
3907
|
return /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
3857
3908
|
/* @__PURE__ */ jsxs(
|
|
@@ -3947,61 +3998,79 @@ function NavigationSidebarInner(props, ref) {
|
|
|
3947
3998
|
]
|
|
3948
3999
|
}
|
|
3949
4000
|
) : null,
|
|
3950
|
-
!resolvedCollapsed && props.search ? /* @__PURE__ */ jsx(
|
|
3951
|
-
|
|
3952
|
-
|
|
3953
|
-
|
|
3954
|
-
|
|
3955
|
-
|
|
3956
|
-
|
|
3957
|
-
|
|
3958
|
-
"
|
|
3959
|
-
|
|
3960
|
-
|
|
3961
|
-
|
|
3962
|
-
|
|
3963
|
-
|
|
3964
|
-
|
|
3965
|
-
|
|
3966
|
-
|
|
3967
|
-
|
|
3968
|
-
|
|
3969
|
-
|
|
3970
|
-
|
|
3971
|
-
|
|
3972
|
-
|
|
3973
|
-
|
|
3974
|
-
|
|
3975
|
-
|
|
3976
|
-
|
|
3977
|
-
|
|
4001
|
+
!resolvedCollapsed && props.search ? /* @__PURE__ */ jsx(
|
|
4002
|
+
"div",
|
|
4003
|
+
{
|
|
4004
|
+
className: cn(
|
|
4005
|
+
"px-[var(--monkeys-component-navigation-sidebar-content-inline-padding,var(--global-spacing,0.75rem))] pb-2 pt-3",
|
|
4006
|
+
props.classNames?.search
|
|
4007
|
+
),
|
|
4008
|
+
children: /* @__PURE__ */ jsxs(
|
|
4009
|
+
"div",
|
|
4010
|
+
{
|
|
4011
|
+
className: cn(
|
|
4012
|
+
"flex items-center gap-2 rounded-md border border-input bg-[var(--monkeys-component-navigation-sidebar-search-background,hsl(var(--monkeys-color-control-surface)))] px-3 text-muted-foreground ring-offset-control-surface focus-within:ring-2 focus-within:ring-ring focus-within:ring-offset-2",
|
|
4013
|
+
appearance.searchHeight
|
|
4014
|
+
),
|
|
4015
|
+
children: [
|
|
4016
|
+
/* @__PURE__ */ jsx(
|
|
4017
|
+
"span",
|
|
4018
|
+
{
|
|
4019
|
+
className: cn(
|
|
4020
|
+
"flex shrink-0",
|
|
4021
|
+
props.classNames?.searchIcon
|
|
4022
|
+
),
|
|
4023
|
+
"aria-hidden": "true",
|
|
4024
|
+
children: props.search.icon ?? /* @__PURE__ */ jsx(SearchIcon, {})
|
|
4025
|
+
}
|
|
4026
|
+
),
|
|
4027
|
+
/* @__PURE__ */ jsx(
|
|
4028
|
+
"input",
|
|
4029
|
+
{
|
|
4030
|
+
type: "search",
|
|
4031
|
+
value: resolvedSearchValue,
|
|
4032
|
+
placeholder: props.search.placeholder,
|
|
4033
|
+
"aria-label": props.search.ariaLabel,
|
|
4034
|
+
className: cn(
|
|
4035
|
+
"min-w-0 flex-1 bg-transparent text-sm text-foreground outline-none placeholder:text-muted-foreground",
|
|
4036
|
+
props.classNames?.searchInput
|
|
4037
|
+
),
|
|
4038
|
+
onChange: (event) => {
|
|
4039
|
+
const nextValue = event.currentTarget.value;
|
|
4040
|
+
if (props.search?.value === void 0)
|
|
4041
|
+
setInternalSearchValue(nextValue);
|
|
4042
|
+
props.search?.onValueChange?.(nextValue);
|
|
4043
|
+
}
|
|
4044
|
+
}
|
|
4045
|
+
),
|
|
4046
|
+
resolvedSearchValue && props.search.clearLabel ? /* @__PURE__ */ jsx(
|
|
4047
|
+
"button",
|
|
4048
|
+
{
|
|
4049
|
+
type: "button",
|
|
4050
|
+
className: cn(
|
|
4051
|
+
"inline-flex h-6 w-6 items-center justify-center rounded text-muted-foreground hover:bg-muted hover:text-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",
|
|
4052
|
+
props.classNames?.searchClear
|
|
4053
|
+
),
|
|
4054
|
+
"aria-label": props.search.clearLabel,
|
|
4055
|
+
title: props.search.clearLabel,
|
|
4056
|
+
onClick: () => {
|
|
4057
|
+
if (props.search?.value === void 0)
|
|
4058
|
+
setInternalSearchValue("");
|
|
4059
|
+
props.search?.onValueChange?.("");
|
|
4060
|
+
},
|
|
4061
|
+
children: /* @__PURE__ */ jsx(ClearIcon, {})
|
|
4062
|
+
}
|
|
4063
|
+
) : null
|
|
4064
|
+
]
|
|
3978
4065
|
}
|
|
3979
|
-
|
|
3980
|
-
|
|
3981
|
-
|
|
3982
|
-
"button",
|
|
3983
|
-
{
|
|
3984
|
-
type: "button",
|
|
3985
|
-
className: cn(
|
|
3986
|
-
"inline-flex h-6 w-6 items-center justify-center rounded text-muted-foreground hover:bg-muted hover:text-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",
|
|
3987
|
-
props.classNames?.searchClear
|
|
3988
|
-
),
|
|
3989
|
-
"aria-label": props.search.clearLabel,
|
|
3990
|
-
title: props.search.clearLabel,
|
|
3991
|
-
onClick: () => {
|
|
3992
|
-
if (props.search?.value === void 0)
|
|
3993
|
-
setInternalSearchValue("");
|
|
3994
|
-
props.search?.onValueChange?.("");
|
|
3995
|
-
},
|
|
3996
|
-
children: /* @__PURE__ */ jsx(ClearIcon, {})
|
|
3997
|
-
}
|
|
3998
|
-
) : null
|
|
3999
|
-
] }) }) : null,
|
|
4066
|
+
)
|
|
4067
|
+
}
|
|
4068
|
+
) : null,
|
|
4000
4069
|
/* @__PURE__ */ jsx(
|
|
4001
4070
|
"div",
|
|
4002
4071
|
{
|
|
4003
4072
|
className: cn(
|
|
4004
|
-
"min-h-0 flex-1 overflow-y-auto
|
|
4073
|
+
"min-h-0 flex-1 overflow-y-auto px-[var(--monkeys-component-navigation-sidebar-content-inline-padding,var(--global-spacing,0.75rem))] py-3",
|
|
4005
4074
|
resolvedCollapsed && "px-1.5",
|
|
4006
4075
|
props.classNames?.content
|
|
4007
4076
|
),
|