@inf-monkeys-tech/monkeys-design 2.0.0 → 2.0.1
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/navigation-sidebar/index.d.mts +28 -4
- package/dist/components/navigation-sidebar/index.d.ts +28 -4
- package/dist/components/navigation-sidebar/index.js +585 -118
- package/dist/components/navigation-sidebar/index.js.map +1 -1
- package/dist/components/navigation-sidebar/index.mjs +586 -119
- package/dist/components/navigation-sidebar/index.mjs.map +1 -1
- package/dist/components/workbench/index.js +585 -118
- package/dist/components/workbench/index.js.map +1 -1
- package/dist/components/workbench/index.mjs +585 -118
- package/dist/components/workbench/index.mjs.map +1 -1
- package/dist/index.d.mts +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +585 -118
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +585 -118
- package/dist/index.mjs.map +1 -1
- package/dist/styles.css +1 -1
- package/package.json +1 -1
|
@@ -51,9 +51,11 @@ interface NavigationSidebarClassNames {
|
|
|
51
51
|
itemDescription?: string;
|
|
52
52
|
itemMeta?: string;
|
|
53
53
|
itemEndContent?: string;
|
|
54
|
+
itemActions?: string;
|
|
54
55
|
childList?: string;
|
|
55
56
|
childItem?: string;
|
|
56
57
|
childItemActive?: string;
|
|
58
|
+
childActions?: string;
|
|
57
59
|
childMenuTrigger?: string;
|
|
58
60
|
childMenuContent?: string;
|
|
59
61
|
mobileNav?: string;
|
|
@@ -153,34 +155,56 @@ interface NavigationSidebarRouteChild {
|
|
|
153
155
|
id: string;
|
|
154
156
|
label: ReactNode;
|
|
155
157
|
icon?: ReactNode;
|
|
158
|
+
actions?: ReactNode;
|
|
156
159
|
disabled?: boolean;
|
|
157
160
|
title?: string;
|
|
158
161
|
className?: string;
|
|
159
162
|
domProps?: NavigationSidebarEntryDomProps;
|
|
160
163
|
}
|
|
161
|
-
interface
|
|
164
|
+
interface NavigationSidebarRouteItemBase {
|
|
162
165
|
id: string;
|
|
163
166
|
label: ReactNode;
|
|
164
167
|
icon?: ReactNode;
|
|
165
168
|
description?: ReactNode;
|
|
166
169
|
meta?: ReactNode;
|
|
167
170
|
endContent?: ReactNode;
|
|
171
|
+
actions?: ReactNode;
|
|
168
172
|
disabled?: boolean;
|
|
169
|
-
href?: string;
|
|
170
|
-
to?: string;
|
|
171
173
|
title?: string;
|
|
172
174
|
className?: string;
|
|
173
175
|
domProps?: NavigationSidebarEntryDomProps;
|
|
176
|
+
}
|
|
177
|
+
interface NavigationSidebarSelectableRouteItem extends NavigationSidebarRouteItemBase {
|
|
178
|
+
interaction?: "select";
|
|
179
|
+
href?: string;
|
|
180
|
+
to?: string;
|
|
174
181
|
onClick?: (event: MouseEvent<HTMLElement>) => void;
|
|
175
182
|
children?: NavigationSidebarRouteChild[];
|
|
183
|
+
childrenPresentation?: "always" | "collapsible";
|
|
184
|
+
}
|
|
185
|
+
interface NavigationSidebarDisclosureRouteItem extends NavigationSidebarRouteItemBase {
|
|
186
|
+
interaction: "disclosure";
|
|
187
|
+
children: [
|
|
188
|
+
NavigationSidebarRouteChild,
|
|
189
|
+
...NavigationSidebarRouteChild[]
|
|
190
|
+
];
|
|
191
|
+
childrenPresentation?: "collapsible";
|
|
192
|
+
href?: never;
|
|
193
|
+
to?: never;
|
|
194
|
+
onClick?: never;
|
|
176
195
|
}
|
|
196
|
+
type NavigationSidebarRouteItem = NavigationSidebarDisclosureRouteItem | NavigationSidebarSelectableRouteItem;
|
|
177
197
|
interface NavigationSidebarRouteProps extends NavigationSidebarCommonProps {
|
|
178
198
|
kind: "route";
|
|
179
199
|
routeItems: NavigationSidebarRouteItem[];
|
|
180
200
|
activeItemId?: string;
|
|
181
201
|
activeChildId?: string;
|
|
202
|
+
expandedItemIds?: string[];
|
|
203
|
+
defaultExpandedItemIds?: string[];
|
|
182
204
|
itemAs?: ElementType;
|
|
183
205
|
collapsedChildMenuLabel?: string;
|
|
206
|
+
disclosureLabel?: string;
|
|
207
|
+
onExpandedItemIdsChange?: (itemIds: string[]) => void;
|
|
184
208
|
onItemSelect?: (item: NavigationSidebarRouteItem) => void;
|
|
185
209
|
onChildSelect?: (child: NavigationSidebarRouteChild, parent: NavigationSidebarRouteItem) => void;
|
|
186
210
|
mobile?: NavigationSidebarMobileConfig;
|
|
@@ -201,4 +225,4 @@ interface NavigationSidebarTreeProps<TNodeSource = unknown, TGroupSource = unkno
|
|
|
201
225
|
type NavigationSidebarProps<TNodeSource = unknown, TGroupSource = unknown, TContext = unknown> = NavigationSidebarCatalogProps | NavigationSidebarRouteProps | NavigationSidebarTreeProps<TNodeSource, TGroupSource, TContext>;
|
|
202
226
|
type NavigationSidebarComponent = <TNodeSource = unknown, TGroupSource = unknown, TContext = unknown>(props: NavigationSidebarProps<TNodeSource, TGroupSource, TContext> & RefAttributes<HTMLElement>) => null | ReactElement;
|
|
203
227
|
declare const NavigationSidebar: NavigationSidebarComponent;
|
|
204
|
-
export { NavigationSidebar, type NavigationSidebarActiveVariant, type NavigationSidebarAppearance, type NavigationSidebarCatalogFilter, type NavigationSidebarCatalogItem, type NavigationSidebarCatalogProps, type NavigationSidebarCatalogSection, type NavigationSidebarClassNames, type NavigationSidebarCollapsePlacement, type NavigationSidebarCommonProps, type NavigationSidebarComponent, type NavigationSidebarDensity, type NavigationSidebarEntryDomProps, type NavigationSidebarKind, type NavigationSidebarMobileConfig, type NavigationSidebarProps, type NavigationSidebarRouteChild, type NavigationSidebarRouteItem, type NavigationSidebarRouteProps, type NavigationSidebarSearchConfig, type NavigationSidebarStorage, type NavigationSidebarSurface, type NavigationSidebarTreeProps };
|
|
228
|
+
export { NavigationSidebar, type NavigationSidebarActiveVariant, type NavigationSidebarAppearance, type NavigationSidebarCatalogFilter, type NavigationSidebarCatalogItem, type NavigationSidebarCatalogProps, type NavigationSidebarCatalogSection, type NavigationSidebarClassNames, type NavigationSidebarCollapsePlacement, type NavigationSidebarCommonProps, type NavigationSidebarComponent, type NavigationSidebarDensity, type NavigationSidebarDisclosureRouteItem, type NavigationSidebarEntryDomProps, type NavigationSidebarKind, type NavigationSidebarMobileConfig, type NavigationSidebarProps, type NavigationSidebarRouteChild, type NavigationSidebarRouteItem, type NavigationSidebarRouteItemBase, type NavigationSidebarRouteProps, type NavigationSidebarSearchConfig, type NavigationSidebarSelectableRouteItem, type NavigationSidebarStorage, type NavigationSidebarSurface, type NavigationSidebarTreeProps };
|
|
@@ -51,9 +51,11 @@ interface NavigationSidebarClassNames {
|
|
|
51
51
|
itemDescription?: string;
|
|
52
52
|
itemMeta?: string;
|
|
53
53
|
itemEndContent?: string;
|
|
54
|
+
itemActions?: string;
|
|
54
55
|
childList?: string;
|
|
55
56
|
childItem?: string;
|
|
56
57
|
childItemActive?: string;
|
|
58
|
+
childActions?: string;
|
|
57
59
|
childMenuTrigger?: string;
|
|
58
60
|
childMenuContent?: string;
|
|
59
61
|
mobileNav?: string;
|
|
@@ -153,34 +155,56 @@ interface NavigationSidebarRouteChild {
|
|
|
153
155
|
id: string;
|
|
154
156
|
label: ReactNode;
|
|
155
157
|
icon?: ReactNode;
|
|
158
|
+
actions?: ReactNode;
|
|
156
159
|
disabled?: boolean;
|
|
157
160
|
title?: string;
|
|
158
161
|
className?: string;
|
|
159
162
|
domProps?: NavigationSidebarEntryDomProps;
|
|
160
163
|
}
|
|
161
|
-
interface
|
|
164
|
+
interface NavigationSidebarRouteItemBase {
|
|
162
165
|
id: string;
|
|
163
166
|
label: ReactNode;
|
|
164
167
|
icon?: ReactNode;
|
|
165
168
|
description?: ReactNode;
|
|
166
169
|
meta?: ReactNode;
|
|
167
170
|
endContent?: ReactNode;
|
|
171
|
+
actions?: ReactNode;
|
|
168
172
|
disabled?: boolean;
|
|
169
|
-
href?: string;
|
|
170
|
-
to?: string;
|
|
171
173
|
title?: string;
|
|
172
174
|
className?: string;
|
|
173
175
|
domProps?: NavigationSidebarEntryDomProps;
|
|
176
|
+
}
|
|
177
|
+
interface NavigationSidebarSelectableRouteItem extends NavigationSidebarRouteItemBase {
|
|
178
|
+
interaction?: "select";
|
|
179
|
+
href?: string;
|
|
180
|
+
to?: string;
|
|
174
181
|
onClick?: (event: MouseEvent<HTMLElement>) => void;
|
|
175
182
|
children?: NavigationSidebarRouteChild[];
|
|
183
|
+
childrenPresentation?: "always" | "collapsible";
|
|
184
|
+
}
|
|
185
|
+
interface NavigationSidebarDisclosureRouteItem extends NavigationSidebarRouteItemBase {
|
|
186
|
+
interaction: "disclosure";
|
|
187
|
+
children: [
|
|
188
|
+
NavigationSidebarRouteChild,
|
|
189
|
+
...NavigationSidebarRouteChild[]
|
|
190
|
+
];
|
|
191
|
+
childrenPresentation?: "collapsible";
|
|
192
|
+
href?: never;
|
|
193
|
+
to?: never;
|
|
194
|
+
onClick?: never;
|
|
176
195
|
}
|
|
196
|
+
type NavigationSidebarRouteItem = NavigationSidebarDisclosureRouteItem | NavigationSidebarSelectableRouteItem;
|
|
177
197
|
interface NavigationSidebarRouteProps extends NavigationSidebarCommonProps {
|
|
178
198
|
kind: "route";
|
|
179
199
|
routeItems: NavigationSidebarRouteItem[];
|
|
180
200
|
activeItemId?: string;
|
|
181
201
|
activeChildId?: string;
|
|
202
|
+
expandedItemIds?: string[];
|
|
203
|
+
defaultExpandedItemIds?: string[];
|
|
182
204
|
itemAs?: ElementType;
|
|
183
205
|
collapsedChildMenuLabel?: string;
|
|
206
|
+
disclosureLabel?: string;
|
|
207
|
+
onExpandedItemIdsChange?: (itemIds: string[]) => void;
|
|
184
208
|
onItemSelect?: (item: NavigationSidebarRouteItem) => void;
|
|
185
209
|
onChildSelect?: (child: NavigationSidebarRouteChild, parent: NavigationSidebarRouteItem) => void;
|
|
186
210
|
mobile?: NavigationSidebarMobileConfig;
|
|
@@ -201,4 +225,4 @@ interface NavigationSidebarTreeProps<TNodeSource = unknown, TGroupSource = unkno
|
|
|
201
225
|
type NavigationSidebarProps<TNodeSource = unknown, TGroupSource = unknown, TContext = unknown> = NavigationSidebarCatalogProps | NavigationSidebarRouteProps | NavigationSidebarTreeProps<TNodeSource, TGroupSource, TContext>;
|
|
202
226
|
type NavigationSidebarComponent = <TNodeSource = unknown, TGroupSource = unknown, TContext = unknown>(props: NavigationSidebarProps<TNodeSource, TGroupSource, TContext> & RefAttributes<HTMLElement>) => null | ReactElement;
|
|
203
227
|
declare const NavigationSidebar: NavigationSidebarComponent;
|
|
204
|
-
export { NavigationSidebar, type NavigationSidebarActiveVariant, type NavigationSidebarAppearance, type NavigationSidebarCatalogFilter, type NavigationSidebarCatalogItem, type NavigationSidebarCatalogProps, type NavigationSidebarCatalogSection, type NavigationSidebarClassNames, type NavigationSidebarCollapsePlacement, type NavigationSidebarCommonProps, type NavigationSidebarComponent, type NavigationSidebarDensity, type NavigationSidebarEntryDomProps, type NavigationSidebarKind, type NavigationSidebarMobileConfig, type NavigationSidebarProps, type NavigationSidebarRouteChild, type NavigationSidebarRouteItem, type NavigationSidebarRouteProps, type NavigationSidebarSearchConfig, type NavigationSidebarStorage, type NavigationSidebarSurface, type NavigationSidebarTreeProps };
|
|
228
|
+
export { NavigationSidebar, type NavigationSidebarActiveVariant, type NavigationSidebarAppearance, type NavigationSidebarCatalogFilter, type NavigationSidebarCatalogItem, type NavigationSidebarCatalogProps, type NavigationSidebarCatalogSection, type NavigationSidebarClassNames, type NavigationSidebarCollapsePlacement, type NavigationSidebarCommonProps, type NavigationSidebarComponent, type NavigationSidebarDensity, type NavigationSidebarDisclosureRouteItem, type NavigationSidebarEntryDomProps, type NavigationSidebarKind, type NavigationSidebarMobileConfig, type NavigationSidebarProps, type NavigationSidebarRouteChild, type NavigationSidebarRouteItem, type NavigationSidebarRouteItemBase, type NavigationSidebarRouteProps, type NavigationSidebarSearchConfig, type NavigationSidebarSelectableRouteItem, type NavigationSidebarStorage, type NavigationSidebarSurface, type NavigationSidebarTreeProps };
|