@procaaso/alphinity-ui-components 1.0.8 → 1.0.9

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.d.cts CHANGED
@@ -246,6 +246,26 @@ interface NodeControlsPanelProps extends react__default.HTMLAttributes<HTMLDivEl
246
246
  */
247
247
  declare const NodeControlsPanel: react__default.FC<NodeControlsPanelProps>;
248
248
 
249
+ /**
250
+ * Device control capabilities and commands
251
+ */
252
+ interface ControlCapabilities {
253
+ /** Can the device be started? */
254
+ canStart?: boolean;
255
+ /** Can the device be stopped? */
256
+ canStop?: boolean;
257
+ /** Can the device be paused? */
258
+ canPause?: boolean;
259
+ /** Can the device be reset? */
260
+ canReset?: boolean;
261
+ /** Custom actions available */
262
+ customActions?: Array<{
263
+ id: string;
264
+ label: string;
265
+ icon?: string;
266
+ variant?: 'primary' | 'secondary' | 'alarm' | 'warning';
267
+ }>;
268
+ }
249
269
  /**
250
270
  * Device control mode option
251
271
  */
@@ -292,26 +312,8 @@ interface ControlParameter {
292
312
  }>;
293
313
  /** Custom validation function */
294
314
  validate?: (value: any) => boolean | string;
295
- }
296
- /**
297
- * Device control capabilities and commands
298
- */
299
- interface ControlCapabilities {
300
- /** Can the device be started? */
301
- canStart?: boolean;
302
- /** Can the device be stopped? */
303
- canStop?: boolean;
304
- /** Can the device be paused? */
305
- canPause?: boolean;
306
- /** Can the device be reset? */
307
- canReset?: boolean;
308
- /** Custom actions available */
309
- customActions?: Array<{
310
- id: string;
311
- label: string;
312
- icon?: string;
313
- variant?: 'primary' | 'secondary' | 'alarm' | 'warning';
314
- }>;
315
+ /** Modes where this parameter is visible (if empty/undefined, visible in all modes) */
316
+ modes?: string[];
315
317
  }
316
318
  /**
317
319
  * Device control state
@@ -462,6 +464,10 @@ interface DeviceControlPanelProps {
462
464
  position?: 'bottom' | 'side';
463
465
  /** Optimize for touch (larger targets) */
464
466
  touchOptimized?: boolean;
467
+ /** Maximum height for bottom position (default: 70vh) */
468
+ maxHeight?: string;
469
+ /** Maximum width for bottom position (default: none) */
470
+ maxWidth?: string;
465
471
  /** Called when mode changes */
466
472
  onModeChange?: (mode: string) => void;
467
473
  /** Called when parameter changes */
@@ -473,7 +479,7 @@ interface DeviceControlPanelProps {
473
479
  /** Called when custom action clicked */
474
480
  onCustomAction?: (actionId: string) => void;
475
481
  }
476
- declare function DeviceControlPanel({ binding, onClose, position, touchOptimized, onModeChange, onParameterChange, onStart, onStop, onCustomAction, }: DeviceControlPanelProps): react_jsx_runtime.JSX.Element | null;
482
+ declare function DeviceControlPanel({ binding, onClose, position, touchOptimized, maxHeight, maxWidth, onModeChange, onParameterChange, onStart, onStop, onCustomAction, }: DeviceControlPanelProps): react_jsx_runtime.JSX.Element | null;
477
483
 
478
484
  type DisplayMode = 'standard' | 'dashboard';
479
485
  interface FullscreenContainerProps {
package/dist/index.d.ts CHANGED
@@ -246,6 +246,26 @@ interface NodeControlsPanelProps extends react__default.HTMLAttributes<HTMLDivEl
246
246
  */
247
247
  declare const NodeControlsPanel: react__default.FC<NodeControlsPanelProps>;
248
248
 
249
+ /**
250
+ * Device control capabilities and commands
251
+ */
252
+ interface ControlCapabilities {
253
+ /** Can the device be started? */
254
+ canStart?: boolean;
255
+ /** Can the device be stopped? */
256
+ canStop?: boolean;
257
+ /** Can the device be paused? */
258
+ canPause?: boolean;
259
+ /** Can the device be reset? */
260
+ canReset?: boolean;
261
+ /** Custom actions available */
262
+ customActions?: Array<{
263
+ id: string;
264
+ label: string;
265
+ icon?: string;
266
+ variant?: 'primary' | 'secondary' | 'alarm' | 'warning';
267
+ }>;
268
+ }
249
269
  /**
250
270
  * Device control mode option
251
271
  */
@@ -292,26 +312,8 @@ interface ControlParameter {
292
312
  }>;
293
313
  /** Custom validation function */
294
314
  validate?: (value: any) => boolean | string;
295
- }
296
- /**
297
- * Device control capabilities and commands
298
- */
299
- interface ControlCapabilities {
300
- /** Can the device be started? */
301
- canStart?: boolean;
302
- /** Can the device be stopped? */
303
- canStop?: boolean;
304
- /** Can the device be paused? */
305
- canPause?: boolean;
306
- /** Can the device be reset? */
307
- canReset?: boolean;
308
- /** Custom actions available */
309
- customActions?: Array<{
310
- id: string;
311
- label: string;
312
- icon?: string;
313
- variant?: 'primary' | 'secondary' | 'alarm' | 'warning';
314
- }>;
315
+ /** Modes where this parameter is visible (if empty/undefined, visible in all modes) */
316
+ modes?: string[];
315
317
  }
316
318
  /**
317
319
  * Device control state
@@ -462,6 +464,10 @@ interface DeviceControlPanelProps {
462
464
  position?: 'bottom' | 'side';
463
465
  /** Optimize for touch (larger targets) */
464
466
  touchOptimized?: boolean;
467
+ /** Maximum height for bottom position (default: 70vh) */
468
+ maxHeight?: string;
469
+ /** Maximum width for bottom position (default: none) */
470
+ maxWidth?: string;
465
471
  /** Called when mode changes */
466
472
  onModeChange?: (mode: string) => void;
467
473
  /** Called when parameter changes */
@@ -473,7 +479,7 @@ interface DeviceControlPanelProps {
473
479
  /** Called when custom action clicked */
474
480
  onCustomAction?: (actionId: string) => void;
475
481
  }
476
- declare function DeviceControlPanel({ binding, onClose, position, touchOptimized, onModeChange, onParameterChange, onStart, onStop, onCustomAction, }: DeviceControlPanelProps): react_jsx_runtime.JSX.Element | null;
482
+ declare function DeviceControlPanel({ binding, onClose, position, touchOptimized, maxHeight, maxWidth, onModeChange, onParameterChange, onStart, onStop, onCustomAction, }: DeviceControlPanelProps): react_jsx_runtime.JSX.Element | null;
477
483
 
478
484
  type DisplayMode = 'standard' | 'dashboard';
479
485
  interface FullscreenContainerProps {
package/dist/index.js CHANGED
@@ -901,6 +901,8 @@ function DeviceControlPanel({
901
901
  onClose,
902
902
  position = "bottom",
903
903
  touchOptimized = true,
904
+ maxHeight,
905
+ maxWidth,
904
906
  onModeChange,
905
907
  onParameterChange,
906
908
  onStart,
@@ -962,7 +964,10 @@ function DeviceControlPanel({
962
964
  bottom: 0,
963
965
  left: 0,
964
966
  right: 0,
965
- animation: "slideUp 0.3s ease-out"
967
+ animation: "slideUp 0.3s ease-out",
968
+ maxWidth,
969
+ marginLeft: "auto",
970
+ marginRight: "auto"
966
971
  } : {
967
972
  right: 0,
968
973
  top: 0,
@@ -977,7 +982,7 @@ function DeviceControlPanel({
977
982
  border: `2px solid ${borderColor}`,
978
983
  padding: "20px",
979
984
  zIndex: 9999,
980
- maxHeight: position === "bottom" ? "70vh" : "100vh",
985
+ maxHeight: maxHeight || (position === "bottom" ? "70vh" : "100vh"),
981
986
  overflowY: "auto",
982
987
  ...binding.display?.style
983
988
  };