@wandelbots/wandelbots-js-react-components 2.32.0-pr.feature-robot-precondition-list.372.5d8a86e → 2.32.0-pr.feature-robot-precondition-list.372.82f340f
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/RobotCard.d.ts +12 -1
- package/dist/components/RobotCard.d.ts.map +1 -1
- package/dist/components/SearchableDataGrid.d.ts +66 -0
- package/dist/components/SearchableDataGrid.d.ts.map +1 -0
- package/dist/index.cjs +49 -49
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +6387 -6123
- package/dist/index.js.map +1 -1
- package/package.json +2 -1
- package/src/components/RobotCard.tsx +39 -31
- package/src/components/SearchableDataGrid.tsx +461 -0
- package/src/index.ts +1 -0
|
@@ -40,6 +40,17 @@ export interface RobotCardProps {
|
|
|
40
40
|
autoStart?: boolean;
|
|
41
41
|
className?: string;
|
|
42
42
|
}>;
|
|
43
|
+
/** Callback to receive cycle timer controls for external timer management */
|
|
44
|
+
onCycleTimerReady?: (controls: {
|
|
45
|
+
startNewCycle: (maxTimeSeconds: number, elapsedSeconds?: number) => void;
|
|
46
|
+
pause: () => void;
|
|
47
|
+
resume: () => void;
|
|
48
|
+
isPaused: () => boolean;
|
|
49
|
+
}) => void;
|
|
50
|
+
/** Callback fired when a cycle completes (reaches zero) */
|
|
51
|
+
onCycleEnd?: () => void;
|
|
52
|
+
/** Whether the cycle timer should auto-start when a new cycle is set */
|
|
53
|
+
cycleTimerAutoStart?: boolean;
|
|
43
54
|
/** Additional CSS class name */
|
|
44
55
|
className?: string;
|
|
45
56
|
}
|
|
@@ -67,7 +78,7 @@ export interface RobotCardProps {
|
|
|
67
78
|
* - Localization support via react-i18next
|
|
68
79
|
* - Material-UI theming integration
|
|
69
80
|
*/
|
|
70
|
-
export declare const RobotCard: (({ robotName, programState, safetyState, operationMode, driveToHomeEnabled, onDriveToHomePress, onDriveToHomeRelease, connectedMotionGroup, robotComponent: RobotComponent, cycleTimerComponent: CycleTimerComponent, className, }: RobotCardProps) => import("react/jsx-runtime").JSX.Element) & {
|
|
81
|
+
export declare const RobotCard: (({ robotName, programState, safetyState, operationMode, driveToHomeEnabled, onDriveToHomePress, onDriveToHomeRelease, connectedMotionGroup, robotComponent: RobotComponent, cycleTimerComponent: CycleTimerComponent, onCycleTimerReady, onCycleEnd, cycleTimerAutoStart, className, }: RobotCardProps) => import("react/jsx-runtime").JSX.Element) & {
|
|
71
82
|
displayName: string;
|
|
72
83
|
};
|
|
73
84
|
//# sourceMappingURL=RobotCard.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"RobotCard.d.ts","sourceRoot":"","sources":["../../src/components/RobotCard.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"RobotCard.d.ts","sourceRoot":"","sources":["../../src/components/RobotCard.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EACV,oBAAoB,EACpB,qCAAqC,EACrC,mCAAmC,EACpC,MAAM,wBAAwB,CAAA;AAI/B,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,OAAO,CAAA;AAIlC,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAA;AAuBpD,MAAM,WAAW,cAAc;IAC7B,6CAA6C;IAC7C,SAAS,EAAE,MAAM,CAAA;IACjB,4BAA4B;IAC5B,YAAY,EAAE,YAAY,CAAA;IAC1B,mDAAmD;IACnD,WAAW,EAAE,mCAAmC,CAAA;IAChD,qDAAqD;IACrD,aAAa,EAAE,qCAAqC,CAAA;IACpD,2DAA2D;IAC3D,kBAAkB,CAAC,EAAE,OAAO,CAAA;IAC5B,4DAA4D;IAC5D,kBAAkB,CAAC,EAAE,MAAM,IAAI,CAAA;IAC/B,6DAA6D;IAC7D,oBAAoB,CAAC,EAAE,MAAM,IAAI,CAAA;IACjC,2CAA2C;IAC3C,oBAAoB,EAAE,oBAAoB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B,wEAAwE;IACxE,mBAAmB,CAAC,EAAE,OAAO,CAAA;IAC7B,gCAAgC;IAChC,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB;AAED;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AACH,eAAO,MAAM,SAAS,2RAiBf,cAAc;;CA0bpB,CAAA"}
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
import { type DataGridProps, type GridColDef, type GridRowParams } from "@mui/x-data-grid";
|
|
2
|
+
export interface SearchableDataGridProps<T = Record<string, unknown>> {
|
|
3
|
+
/**
|
|
4
|
+
* Array of data items to display in the grid
|
|
5
|
+
*/
|
|
6
|
+
data: T[];
|
|
7
|
+
/**
|
|
8
|
+
* Column definitions for the DataGrid
|
|
9
|
+
*/
|
|
10
|
+
columns: GridColDef[];
|
|
11
|
+
/**
|
|
12
|
+
* Function to transform data items into DataGrid rows
|
|
13
|
+
* Should return an object with an 'id' field and other fields matching column definitions
|
|
14
|
+
*/
|
|
15
|
+
getRowData: (item: T) => Record<string, unknown> & {
|
|
16
|
+
id: string | number;
|
|
17
|
+
};
|
|
18
|
+
/**
|
|
19
|
+
* Callback when a row is clicked
|
|
20
|
+
*/
|
|
21
|
+
onRowClick?: (item: T, params: GridRowParams) => void;
|
|
22
|
+
/**
|
|
23
|
+
* Currently selected item (for highlighting)
|
|
24
|
+
*/
|
|
25
|
+
selectedItem?: T | null;
|
|
26
|
+
/**
|
|
27
|
+
* Function to get the ID of an item (used for selection highlighting)
|
|
28
|
+
*/
|
|
29
|
+
getItemId?: (item: T) => string | number;
|
|
30
|
+
/**
|
|
31
|
+
* Title displayed in the toolbar
|
|
32
|
+
*/
|
|
33
|
+
title?: string;
|
|
34
|
+
/**
|
|
35
|
+
* Show item count in title
|
|
36
|
+
* @default true
|
|
37
|
+
*/
|
|
38
|
+
showCount?: boolean;
|
|
39
|
+
/**
|
|
40
|
+
* Placeholder text for the search input
|
|
41
|
+
* @default "Search"
|
|
42
|
+
*/
|
|
43
|
+
searchPlaceholder?: string;
|
|
44
|
+
/**
|
|
45
|
+
* Additional DataGrid props to pass through
|
|
46
|
+
*/
|
|
47
|
+
dataGridProps?: Partial<DataGridProps>;
|
|
48
|
+
/**
|
|
49
|
+
* Custom toolbar component to replace the default one
|
|
50
|
+
*/
|
|
51
|
+
CustomToolbar?: React.ComponentType;
|
|
52
|
+
/**
|
|
53
|
+
* Background color for the component
|
|
54
|
+
* @default "transparent"
|
|
55
|
+
*/
|
|
56
|
+
backgroundColor?: string;
|
|
57
|
+
/**
|
|
58
|
+
* Select the first item by default
|
|
59
|
+
* @default false
|
|
60
|
+
*/
|
|
61
|
+
selectFirstByDefault?: boolean;
|
|
62
|
+
}
|
|
63
|
+
export declare const SearchableDataGrid: (<T>({ data, columns, getRowData, onRowClick, selectedItem, getItemId, title, showCount, searchPlaceholder, dataGridProps, CustomToolbar, backgroundColor, selectFirstByDefault, }: SearchableDataGridProps<T>) => import("react/jsx-runtime").JSX.Element) & {
|
|
64
|
+
displayName: string;
|
|
65
|
+
};
|
|
66
|
+
//# sourceMappingURL=SearchableDataGrid.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SearchableDataGrid.d.ts","sourceRoot":"","sources":["../../src/components/SearchableDataGrid.tsx"],"names":[],"mappings":"AAIA,OAAO,EAEL,KAAK,aAAa,EAElB,KAAK,UAAU,EACf,KAAK,aAAa,EAOnB,MAAM,kBAAkB,CAAA;AAKzB,MAAM,WAAW,uBAAuB,CAAC,CAAC,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;IAClE;;OAEG;IACH,IAAI,EAAE,CAAC,EAAE,CAAA;IAET;;OAEG;IACH,OAAO,EAAE,UAAU,EAAE,CAAA;IAErB;;;OAGG;IACH,UAAU,EAAE,CAAC,IAAI,EAAE,CAAC,KAAK,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG;QAAE,EAAE,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,CAAA;IAE1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