remoraid 2.45.0 → 3.3.2

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.
@@ -0,0 +1,529 @@
1
+ import { OrdinalColorScaleConfig } from "@nivo/colors";
2
+ import { PartialTheme as PartialNivoTheme } from "@nivo/theming";
3
+ import { MantineColor as MantineColor2, MantineColorScheme as MantineColorScheme3, MantineTheme as MantineTheme2 } from "@mantine/core";
4
+ import { MantineBreakpoint, MantineSize, ScrollerProps } from "@mantine/core";
5
+ import { IconProps as IconProps2 } from "@tabler/icons-react";
6
+ import { PartialDeep } from "type-fest";
7
+ import { AlertProps, TransitionProps } from "@mantine/core";
8
+ import { PropsWithChildren, ReactNode } from "react";
9
+ import { Icon, IconProps } from "@tabler/icons-react";
10
+ interface AlertMinimalProps {
11
+ category: AlertCategory;
12
+ title?: AlertProps["title"];
13
+ color?: AlertProps["color"];
14
+ onClose?: AlertProps["onClose"];
15
+ text?: string;
16
+ icon?: Icon;
17
+ iconSize?: RemoraidIconSize;
18
+ mounted?: TransitionProps["mounted"];
19
+ componentsProps?: {
20
+ icon?: Partial<IconProps>
21
+ alert?: Partial<AlertProps>
22
+ transition?: Omit<TransitionProps, "mounted">
23
+ };
24
+ }
25
+ declare function AlertMinimal({ category, children,...props }: PropsWithChildren<AlertMinimalProps>): ReactNode;
26
+ type PrimitiveUserExperience = string | number | boolean;
27
+ type UserExperience = Partial<Record<string, any>> | PrimitiveUserExperience | PrimitiveUserExperience[];
28
+ type UserExperienceProviderProps<T extends UserExperience> = {
29
+ initialValue?: T extends PrimitiveUserExperience | PrimitiveUserExperience[] ? never : PartialDeep<T>
30
+ cookieName?: string
31
+ };
32
+ interface UserExperienceContext<T extends UserExperience> {
33
+ userExperience: T;
34
+ updateUserExperience: (p: T | ((prev: T) => T)) => void;
35
+ processedCookie: boolean;
36
+ initialUserExperience: T;
37
+ }
38
+ interface WidgetContext {
39
+ name: string;
40
+ selected: boolean;
41
+ hidden: boolean;
42
+ }
43
+ declare enum AlertCategory {
44
+ Negative = "negative",
45
+ Neutral = "neutral",
46
+ Positive = "positive"
47
+ }
48
+ declare enum TransitionDuration {
49
+ Short = "short",
50
+ Medium = "medium",
51
+ Long = "long"
52
+ }
53
+ declare enum RemoraidBreakpoint {
54
+ ButtonCollapse = "buttonCollapse",
55
+ BadgeGroupCollapse = "badgeGroupCollapse",
56
+ NavbarStaticElementsCollapse = "navbarStaticElementsCollapse"
57
+ }
58
+ declare enum RemoraidIconSize {
59
+ Tiny = "tiny",
60
+ ExtraSmall = "extraSmall",
61
+ Small = "small",
62
+ Medium = "medium",
63
+ Large = "large",
64
+ Huge = "huge"
65
+ }
66
+ interface RemoraidTheme {
67
+ bodyColor: string;
68
+ containerSize: MantineSize | number;
69
+ jsonStringifySpace: string | number;
70
+ primaryGutter: MantineSize | number;
71
+ transitionDurations: Record<TransitionDuration, number>;
72
+ breakpoints: Record<RemoraidBreakpoint, MantineBreakpoint>;
73
+ transparentBackground?: string;
74
+ spacingPx?: Record<MantineSize, number>;
75
+ componentsProps: {
76
+ icons: Record<RemoraidIconSize, Partial<IconProps2> & Required<Pick<IconProps2, "size" | "stroke">>>
77
+ alerts: Record<AlertCategory, Omit<Partial<AlertMinimalProps>, "category">>
78
+ Scroller: Partial<ScrollerProps>
79
+ };
80
+ }
81
+ interface WidgetConfiguration {
82
+ widgetId: string;
83
+ initialValues?: PartialDeep<Omit<WidgetContext, "hidden">>;
84
+ allowUnregisteredPageUsage?: boolean;
85
+ }
86
+ declare enum LayoutType {
87
+ Frame = "frame"
88
+ }
89
+ declare enum FrameLayoutSection {
90
+ Top = "top",
91
+ Bottom = "bottom",
92
+ Left = "left",
93
+ Right = "right",
94
+ Content = "content"
95
+ }
96
+ type LayoutSection<T extends LayoutType> = T extends LayoutType.Frame ? FrameLayoutSection : string;
97
+ declare enum ClickTransformation {
98
+ Default = "default",
99
+ None = "none",
100
+ TiltDown = "tiltDown",
101
+ TiltUp = "tiltUp",
102
+ TiltRight = "tiltRight",
103
+ TiltLeft = "tiltLeft",
104
+ Scale = "scale"
105
+ }
106
+ import { ActionIconProps, ActionIconVariant, ButtonProps, ButtonVariant, MantineBreakpoint as MantineBreakpoint2, MantineColor, MantineSize as MantineSize3, TooltipProps, TransitionProps as TransitionProps3 } from "@mantine/core";
107
+ import { Icon as Icon4, IconProps as IconProps3 } from "@tabler/icons-react";
108
+ import { MouseEventHandler as MouseEventHandler2, ReactElement as ReactElement4, ReactNode as ReactNode10 } from "react";
109
+ import { ComponentProps, ElementType, ReactElement as ReactElement3 } from "react";
110
+ type Common<
111
+ A,
112
+ B
113
+ > = Pick<A & B, keyof A & keyof B>;
114
+ type Optional<
115
+ T,
116
+ K extends keyof T
117
+ > = Omit<T, K> & Partial<Pick<T, K>>;
118
+ type OptionalIfExtends<
119
+ T,
120
+ K extends keyof T,
121
+ V1,
122
+ V2
123
+ > = [V1] extends [V2] ? Optional<T, K> : T;
124
+ type ElementOfType<
125
+ T extends ElementType,
126
+ P = ComponentProps<T>
127
+ > = ReactElement3<P, T>;
128
+ type ChildrenOfType<T extends ElementType> = ElementOfType<T> | undefined | null | ReadonlyArray<ChildrenOfType<T>>;
129
+ type PropsWithChildrenOfType<
130
+ T extends ElementType,
131
+ P = {}
132
+ > = P & {
133
+ children?: ChildrenOfType<T>
134
+ };
135
+ type ElementOrPropsOfType<
136
+ T extends ElementType,
137
+ P = ComponentProps<T>
138
+ > = ElementOfType<T, P> | P;
139
+ type RemoraidButtonDefaultResponsivity = true;
140
+ interface ExplicitRemoraidButtonProps<Responsive extends boolean> {
141
+ responsive: Responsive;
142
+ label: string;
143
+ size?: MantineSize3;
144
+ color?: MantineColor;
145
+ breakpoint?: true extends Responsive ? MantineBreakpoint2 : never;
146
+ collapsed?: false extends Responsive ? boolean : never;
147
+ icon?: Icon4 | ReactElement4;
148
+ iconSize?: RemoraidIconSize;
149
+ onClick?: MouseEventHandler2;
150
+ loading?: boolean;
151
+ variant?: Extract<ButtonVariant, ActionIconVariant>;
152
+ mounted?: TransitionProps3["mounted"];
153
+ clickTransformation?: ClickTransformation;
154
+ componentsProps?: {
155
+ tooltip?: Partial<TooltipProps>
156
+ icon?: Partial<IconProps3>
157
+ button?: Omit<Partial<Common<ButtonProps, ActionIconProps>>, "variant" | "onClick" | "size" | "color" | "loading">
158
+ transition?: Partial<Omit<TransitionProps3, "mounted">>
159
+ Button?: Partial<ButtonProps>
160
+ ActionIcon?: Partial<ActionIconProps>
161
+ };
162
+ }
163
+ type RemoraidButtonProps<Responsive extends boolean = RemoraidButtonDefaultResponsivity> = OptionalIfExtends<ExplicitRemoraidButtonProps<Responsive>, "responsive", true, Responsive>;
164
+ declare function RemoraidButton<Responsive extends boolean = RemoraidButtonDefaultResponsivity>({ label, responsive: responsiveProp, breakpoint: breakpointProp, collapsed: collapsedProp, size, color, onClick, loading, variant, mounted, icon: iconProp, iconSize: iconSizeProp, clickTransformation, componentsProps }: RemoraidButtonProps<Responsive>): ReactNode10;
165
+ import { ContainerProps, MantineSize as MantineSize4 } from "@mantine/core";
166
+ interface PageContainerProps {
167
+ p?: MantineSize4 | number;
168
+ hidden?: boolean;
169
+ componentsProps?: {
170
+ container?: ContainerProps
171
+ };
172
+ }
173
+ import { BoxProps as BoxProps2 } from "@mantine/core";
174
+ interface FrameLayoutElementProps {
175
+ section: FrameLayoutSection;
176
+ includeContainer?: boolean;
177
+ includePageContainer?: boolean;
178
+ layoutId?: string;
179
+ hidden?: boolean;
180
+ componentsProps?: {
181
+ container?: Partial<BoxProps2>
182
+ PageContainer?: Partial<PageContainerProps>
183
+ };
184
+ }
185
+ import { ComponentProps as ComponentProps3 } from "react";
186
+ import { Box } from "@mantine/core";
187
+ import { ActionIcon as ActionIcon2, ActionIconProps as ActionIconProps2, TooltipProps as TooltipProps2, TransitionProps as TransitionProps4 } from "@mantine/core";
188
+ import { Icon as Icon5, IconProps as IconProps4 } from "@tabler/icons-react";
189
+ import { ComponentProps as ComponentProps2, ReactNode as ReactNode14 } from "react";
190
+ interface ControlButtonProps {
191
+ icon: Icon5;
192
+ mounted?: boolean;
193
+ tooltip?: string;
194
+ size?: ActionIconProps2["size"];
195
+ iconSize?: RemoraidIconSize;
196
+ color?: ActionIconProps2["color"];
197
+ onClick?: ComponentProps2<typeof ActionIcon2<"button">>["onClick"];
198
+ order?: number;
199
+ componentsProps?: {
200
+ transition?: Partial<TransitionProps4>
201
+ tooltip?: Partial<TooltipProps2>
202
+ button?: Partial<ActionIconProps2>
203
+ icon?: Partial<IconProps4>
204
+ };
205
+ }
206
+ declare function ControlButton({ icon: Icon5, mounted, size, iconSize, onClick, order, color, tooltip, componentsProps }: ControlButtonProps): ReactNode14;
207
+ import { Ref, RefObject } from "react";
208
+ import { GroupProps, MantineSize as MantineSize5, PaperProps as PaperProps2, TransitionProps as TransitionProps5 } from "@mantine/core";
209
+ import { IconProps as IconProps5 } from "@tabler/icons-react";
210
+ interface ControlsProps {
211
+ dragContainerRef: RefObject<HTMLDivElement | null>;
212
+ mounted?: boolean;
213
+ groupRef?: Ref<HTMLDivElement>;
214
+ gutter?: MantineSize5 | number;
215
+ iconSize?: RemoraidIconSize;
216
+ additionalButtons?: ElementOrPropsOfType<typeof ControlButton>[];
217
+ componentsProps?: {
218
+ group?: Partial<GroupProps>
219
+ container?: Partial<PaperProps2>
220
+ transition?: Partial<TransitionProps5>
221
+ gripIcon?: Partial<IconProps5>
222
+ };
223
+ }
224
+ type PinnableDefaultLayoutType = LayoutType.Frame;
225
+ interface ExplicitPinnableProps<T extends LayoutType> {
226
+ layoutType: T;
227
+ section: LayoutSection<T>;
228
+ initialValue?: boolean;
229
+ layoutId?: string;
230
+ controlsContainer?: HTMLDivElement | null;
231
+ hidden?: boolean;
232
+ onPinnedValueChange?: (newValue: boolean) => void;
233
+ componentsProps?: {
234
+ controls?: Partial<ControlsProps>
235
+ button?: Partial<ControlButtonProps>
236
+ container?: Partial<ComponentProps3<typeof Box<"div">>>
237
+ layoutElement?: Partial<FrameLayoutElementProps>
238
+ };
239
+ }
240
+ type PinnableProps<T extends LayoutType = PinnableDefaultLayoutType> = OptionalIfExtends<ExplicitPinnableProps<T>, "layoutType", PinnableDefaultLayoutType, T>;
241
+ import { BadgeProps as BadgeProps2, GroupProps as GroupProps3, HoverCardProps, MantineBreakpoint as MantineBreakpoint4, MantineSize as MantineSize8, StackProps as StackProps2, TransitionProps as TransitionProps7 } from "@mantine/core";
242
+ import { BadgeProps, TooltipProps as TooltipProps3, TransitionProps as TransitionProps6 } from "@mantine/core";
243
+ import { ReactNode as ReactNode28 } from "react";
244
+ interface BadgeMinimalProps {
245
+ label: string;
246
+ tooltip?: string;
247
+ mounted?: TransitionProps6["mounted"];
248
+ componentsProps?: {
249
+ badge?: BadgeProps
250
+ transition?: Partial<Omit<TransitionProps6, "mounted">>
251
+ tooltip?: TooltipProps3
252
+ };
253
+ }
254
+ declare function BadgeMinimal({ label, tooltip, mounted, componentsProps }: BadgeMinimalProps): ReactNode28;
255
+ interface BadgeGroupProps {
256
+ badges: ElementOrPropsOfType<typeof BadgeMinimal>[];
257
+ gap?: MantineSize8 | number;
258
+ breakpoint?: MantineBreakpoint4;
259
+ componentsProps?: {
260
+ container?: Partial<Omit<GroupProps3, "visibleFrom">>
261
+ HoverCard?: Partial<HoverCardProps>
262
+ hoverContainer?: Partial<StackProps2>
263
+ cumulativeBadge?: Partial<Omit<BadgeProps2, "hiddenFrom">>
264
+ cumulativeBadgeTransition?: Partial<TransitionProps7>
265
+ };
266
+ }
267
+ import { MantineSize as MantineSize9, Paper, TransitionProps as TransitionProps8 } from "@mantine/core";
268
+ import { ComponentProps as ComponentProps8 } from "react";
269
+ interface WidgetWrapperProps {
270
+ config: WidgetConfiguration;
271
+ mt?: MantineSize9 | number;
272
+ withCloseButton?: boolean;
273
+ pinnableSection?: Exclude<FrameLayoutSection, FrameLayoutSection.Content>;
274
+ componentsProps?: {
275
+ container?: Partial<ComponentProps8<typeof Paper<"div">>>
276
+ transition?: Partial<TransitionProps8>
277
+ controls?: Partial<ControlsProps>
278
+ closeButton?: Partial<ControlButtonProps>
279
+ Pinnable?: Partial<PinnableProps>
280
+ };
281
+ }
282
+ import { MantineSize as MantineSize10, LoaderProps, DividerProps as DividerProps2, StackProps as StackProps3, TitleProps, ScrollAreaAutosizeProps, TextProps as TextProps2 } from "@mantine/core";
283
+ interface WidgetProps {
284
+ id: string;
285
+ title?: string;
286
+ description?: string;
287
+ config?: Partial<Omit<WidgetConfiguration, "widgetId">>;
288
+ badges?: ElementOrPropsOfType<typeof BadgeMinimal>[];
289
+ buttons?: ElementOrPropsOfType<typeof RemoraidButton, RemoraidButtonProps<true> | RemoraidButtonProps<false>>[];
290
+ alerts?: ElementOrPropsOfType<typeof AlertMinimal>[];
291
+ gaps?: MantineSize10 | number | {
292
+ badges?: MantineSize10 | number
293
+ buttons?: MantineSize10 | number
294
+ alerts?: MantineSize10 | number
295
+ };
296
+ loading?: boolean;
297
+ mt?: MantineSize10 | number;
298
+ pinnableSection?: WidgetWrapperProps["pinnableSection"];
299
+ componentsProps?: {
300
+ wrapper?: Partial<Omit<WidgetWrapperProps, "config">>
301
+ contentContainer?: Partial<StackProps3>
302
+ childrenContainer?: Partial<ScrollAreaAutosizeProps>
303
+ loader?: Partial<LoaderProps>
304
+ title?: Partial<TitleProps>
305
+ description?: Partial<TextProps2>
306
+ badgeGroup?: Partial<BadgeGroupProps>
307
+ divider?: Partial<DividerProps2>
308
+ alertsContainer?: Partial<StackProps3>
309
+ };
310
+ }
311
+ import { BoxProps as BoxProps4, InputWrapperProps, ScrollAreaProps as ScrollAreaProps2 } from "@mantine/core";
312
+ import { ReactNode as ReactNode42 } from "react";
313
+ interface InputWrapperScrollAreaProps {
314
+ label?: string;
315
+ mah?: number;
316
+ description?: string;
317
+ error?: ReactNode42;
318
+ required?: boolean;
319
+ componentsProps?: {
320
+ container?: Partial<InputWrapperProps>
321
+ ScrollArea?: Partial<ScrollAreaProps2>
322
+ childrenContainer?: Partial<BoxProps4>
323
+ };
324
+ }
325
+ import { Icon as Icon7 } from "@tabler/icons-react";
326
+ interface ChartsUserExperience {
327
+ colors: string[];
328
+ }
329
+ interface NivoConfiguration {
330
+ theme?: PartialNivoTheme;
331
+ colors?: OrdinalColorScaleConfig;
332
+ }
333
+ interface NivoConfigurationDependencies {
334
+ remoraidTheme: RemoraidTheme;
335
+ userExperience: ChartsUserExperience;
336
+ mantineTheme: MantineTheme2;
337
+ colorScheme: MantineColorScheme3;
338
+ }
339
+ type NivoConfigurationCallback = (dependencies: Partial<NivoConfigurationDependencies>) => Partial<NivoConfiguration>;
340
+ interface TimeSeriesValue<
341
+ EntityName extends string,
342
+ Dimension extends string
343
+ > {
344
+ date: Date;
345
+ entities: Record<EntityName, Record<Dimension, number | number[]>>;
346
+ }
347
+ interface TimeSeriesData<
348
+ EntityName extends string,
349
+ Dimension extends string
350
+ > {
351
+ values: TimeSeriesValue<EntityName, Dimension>[];
352
+ units: Record<Dimension, string>;
353
+ }
354
+ declare enum ChartType {
355
+ TimeSeriesStackedAreas = "timeSeriesStackedAreas",
356
+ TimeSeriesRingSummary = "timeSeriesRingSummary"
357
+ }
358
+ type ChartData<T extends ChartType> = T extends ChartType.TimeSeriesStackedAreas ? TimeSeriesData<string, string> : T extends ChartType.TimeSeriesRingSummary ? TimeSeriesData<string, string> : never;
359
+ type ChartOptions<T extends ChartType> = T extends ChartType.TimeSeriesStackedAreas ? {
360
+ dimension: string
361
+ axisLeftLegend?: string
362
+ axisBottomLegend?: string
363
+ includeEntityChips?: boolean
364
+ includeLegend?: boolean
365
+ enableDots?: boolean
366
+ includeWindowControl?: boolean
367
+ colors?: NivoConfiguration["colors"]
368
+ valueFormat?: (value: number) => number | string
369
+ } : T extends ChartType.TimeSeriesRingSummary ? {
370
+ entity: string
371
+ dimension: string
372
+ color?: MantineColor2
373
+ icon?: Icon7
374
+ valueFormat?: (value: number) => number | string
375
+ } : never;
376
+ declare enum TimeSeriesStackedAreasChartWindow {
377
+ OneHour = "oneHour",
378
+ TwoHours = "twoHours",
379
+ FourHours = "fourHours",
380
+ TwelveHours = "twelveHours",
381
+ OneDay = "oneDay"
382
+ }
383
+ import { BoxProps as BoxProps5, MantineSize as MantineSize12, PaperProps as PaperProps4 } from "@mantine/core";
384
+ import { ReactNode as ReactNode45 } from "react";
385
+ import { ResponsiveProps } from "@nivo/core";
386
+ import { StreamDatum, StreamSvgProps } from "@nivo/stream";
387
+ import { MantineSize as MantineSize11, PaperProps as PaperProps3, TextProps as TextProps3 } from "@mantine/core";
388
+ interface TooltipProps4 {
389
+ payload: Record<string, {
390
+ value: number | string
391
+ color?: string
392
+ unit?: string
393
+ }>;
394
+ label?: string;
395
+ valueFormat?: (value: number | string) => number | string;
396
+ maxItems?: number | null;
397
+ gaps?: MantineSize11 | number | {
398
+ valuesHorizontal?: MantineSize11 | number
399
+ valuesVertical?: MantineSize11 | number
400
+ };
401
+ componentsProps?: {
402
+ container?: Partial<PaperProps3>
403
+ label?: Partial<TextProps3>
404
+ valueText?: Partial<TextProps3>
405
+ };
406
+ }
407
+ import { MantineColor as MantineColor3, RingProgressProps, StackProps as StackProps5, TextProps as TextProps4 } from "@mantine/core";
408
+ import { SparklineProps } from "@mantine/charts";
409
+ import { Icon as Icon8 } from "@tabler/icons-react";
410
+ interface RingSummaryProps {
411
+ label: string;
412
+ value: string;
413
+ progress: number;
414
+ sparklineData: number[];
415
+ color?: MantineColor3;
416
+ icon?: Icon8;
417
+ componentsProps?: {
418
+ container?: Partial<StackProps5>
419
+ label?: Partial<TextProps4>
420
+ valueText?: Partial<TextProps4>
421
+ RingProgress?: Partial<RingProgressProps>
422
+ Sparkline?: Partial<SparklineProps>
423
+ };
424
+ }
425
+ type ChartComponentProps<T extends ChartType> = T extends ChartType.TimeSeriesStackedAreas ? ResponsiveProps<StreamSvgProps<StreamDatum>> : T extends ChartType.TimeSeriesRingSummary ? RingSummaryProps : never;
426
+ interface ChartPropsGeneric<T extends ChartType> {
427
+ type: T;
428
+ data: ChartData<T>;
429
+ options: ChartOptions<T>;
430
+ additionalControls?: ReactNode45[];
431
+ h?: BoxProps5["h"];
432
+ mt?: MantineSize12 | number;
433
+ mounted?: boolean;
434
+ componentsProps?: {
435
+ chart?: Partial<ChartComponentProps<T>>
436
+ tooltip?: Partial<TooltipProps4>
437
+ container?: Partial<PaperProps4>
438
+ };
439
+ }
440
+ type ChartProps = { [K in ChartType] : ChartPropsGeneric<K> }[ChartType];
441
+ declare function Chart({ type, data, options, additionalControls, h, mt, mounted, componentsProps }: ChartProps): ReactNode45;
442
+ import { ReactNode as ReactNode46 } from "react";
443
+ declare const defaultChartsSettingsWidgetId = "charts-settings";
444
+ interface ChartsSettingsProps {
445
+ widgetProps?: Partial<WidgetProps>;
446
+ }
447
+ declare function ChartsSettings({ widgetProps }: ChartsSettingsProps): ReactNode46;
448
+ import { JsonInputProps } from "@mantine/core";
449
+ import { ReactNode as ReactNode47 } from "react";
450
+ declare const defaultJsonWidgetId = "json";
451
+ interface JSONWidgetProps {
452
+ value: any;
453
+ widgetProps?: Partial<WidgetProps>;
454
+ componentsProps?: {
455
+ inputWrapper?: Partial<InputWrapperScrollAreaProps>
456
+ jsonInput?: Partial<JsonInputProps>
457
+ };
458
+ }
459
+ declare function JSONWidget({ value, widgetProps, componentsProps }: JSONWidgetProps): ReactNode47;
460
+ import { PropsWithChildren as PropsWithChildren28, ReactNode as ReactNode49 } from "react";
461
+ declare const createNivoConfiguration: (customConfiguration?: Partial<NivoConfiguration>, dependencies?: Partial<NivoConfigurationDependencies>) => NivoConfiguration;
462
+ declare const useNivoConfiguration: () => NivoConfiguration;
463
+ interface NivoConfigurationProviderProps {
464
+ configuration?: Partial<NivoConfiguration> | NivoConfigurationCallback;
465
+ }
466
+ interface RemoraidDataVisualizationProviderProps {
467
+ initialUserExperience?: UserExperienceProviderProps<ChartsUserExperience>["initialValue"];
468
+ nivoConfiguration?: NivoConfigurationProviderProps["configuration"];
469
+ componentsProps?: {
470
+ ChartsUserExperienceProvider?: Partial<UserExperienceProviderProps<ChartsUserExperience>>
471
+ NivoConfigurationProvider?: Partial<NivoConfigurationProviderProps>
472
+ };
473
+ }
474
+ declare function RemoraidDataVisualizationProvider({ children, initialUserExperience, nivoConfiguration, componentsProps }: PropsWithChildren28<RemoraidDataVisualizationProviderProps>): ReactNode49;
475
+ declare const defaultUserExperience2: ChartsUserExperience;
476
+ declare const defaultUserExperienceCookieName2 = "remoraid-data-visualization-user-experience";
477
+ declare const useChartsUserExperience: () => UserExperienceContext<ChartsUserExperience>;
478
+ import { ReactNode as ReactNode51 } from "react";
479
+ declare const defaultSingleChartWidgetId = "single-chart";
480
+ interface SingleChartWidgetProps {
481
+ chart: ElementOrPropsOfType<typeof Chart>;
482
+ widgetProps?: Partial<WidgetProps>;
483
+ }
484
+ declare function SingleChartWidget({ chart, widgetProps }: SingleChartWidgetProps): ReactNode51;
485
+ import { SimpleGridProps, StackProps as StackProps6 } from "@mantine/core";
486
+ import { ReactNode as ReactNode52 } from "react";
487
+ declare const defaultTimeseriesExplorerWidgetId = "timeseries-explorer";
488
+ type PartialChartProps = Omit<Partial<ChartPropsGeneric<ChartType.TimeSeriesStackedAreas>>, "options"> & {
489
+ options?: Partial<ChartOptions<ChartType.TimeSeriesStackedAreas>>
490
+ };
491
+ interface TimeSeriesExplorerWidgetProps {
492
+ data?: TimeSeriesData<string, string>;
493
+ isLoadingData?: boolean;
494
+ widgetProps?: Partial<WidgetProps>;
495
+ componentsProps?: {
496
+ contentContainer?: Partial<StackProps6>
497
+ entitiesGrid?: Partial<SimpleGridProps>
498
+ chart?: PartialChartProps
499
+ primaryChart?: PartialChartProps
500
+ entityChart?: PartialChartProps
501
+ missingDataAlert?: Partial<AlertMinimalProps>
502
+ };
503
+ }
504
+ declare function TimeSeriesExplorerWidget({ data, isLoadingData, widgetProps, componentsProps }: TimeSeriesExplorerWidgetProps): ReactNode52;
505
+ import { ReactNode as ReactNode53 } from "react";
506
+ declare const defaultVerticalChartsWidgetId = "vertical-charts";
507
+ interface VerticalChartsWidgetProps {
508
+ additionalCharts?: ElementOrPropsOfType<typeof Chart>[];
509
+ widgetProps?: Partial<WidgetProps>;
510
+ }
511
+ declare function VerticalChartsWidget({ widgetProps, additionalCharts: additionalChartsProp, children: childrenProp }: PropsWithChildrenOfType<typeof Chart, VerticalChartsWidgetProps>): ReactNode53;
512
+ import { BoxProps as BoxProps6 } from "@mantine/core";
513
+ declare const getChartTypeName: (type: ChartType) => string;
514
+ declare const defaultChartHeights: Record<ChartType, BoxProps6["h"]>;
515
+ declare const mergeTimeSeries: <
516
+ const S extends readonly TimeSeriesData<any, any>[],
517
+ E extends string = S[number] extends infer T ? T extends TimeSeriesData<infer E, any> ? E : never : never,
518
+ D extends string = S[number] extends infer T ? T extends TimeSeriesData<any, infer D> ? D : never : never
519
+ >(series: S) => TimeSeriesData<E, D>;
520
+ declare const reduceTimeSeriesEntities: <
521
+ EIn extends string,
522
+ EOut extends string,
523
+ D extends string
524
+ >({ values, units }: TimeSeriesData<EIn, D>, reducer: (previousValue: Record<EOut, Record<D, number | number[]>>, currentValue: [EIn, Record<D, number | number[]>], currentIndex: number, array: [EIn, Record<D, number | number[]>][]) => Record<EOut, Record<D, number | number[]>>, initial: Record<EOut, Record<D, number | number[]>>) => TimeSeriesData<EOut, D>;
525
+ declare const emptyTimeSeriesData: TimeSeriesData<string, string>;
526
+ declare const missingDataAlertProps: (props?: Partial<AlertMinimalProps>) => AlertMinimalProps;
527
+ declare const downloadJson: (data: any, filename?: string) => void;
528
+ declare const copyToClipboard: (value: string) => Promise<void>;
529
+ export { useNivoConfiguration, useChartsUserExperience, reduceTimeSeriesEntities, missingDataAlertProps, mergeTimeSeries, getChartTypeName, emptyTimeSeriesData, downloadJson, defaultVerticalChartsWidgetId, defaultUserExperienceCookieName2 as defaultUserExperienceCookieName, defaultUserExperience2 as defaultUserExperience, defaultTimeseriesExplorerWidgetId, defaultSingleChartWidgetId, defaultJsonWidgetId, defaultChartsSettingsWidgetId, defaultChartHeights, createNivoConfiguration, copyToClipboard, VerticalChartsWidgetProps, VerticalChartsWidget, TimeSeriesValue, TimeSeriesStackedAreasChartWindow, TimeSeriesExplorerWidgetProps, TimeSeriesExplorerWidget, TimeSeriesData, SingleChartWidgetProps, SingleChartWidget, RemoraidDataVisualizationProviderProps, RemoraidDataVisualizationProvider, NivoConfigurationProviderProps, NivoConfigurationDependencies, NivoConfigurationCallback, NivoConfiguration, JSONWidgetProps, JSONWidget, ChartsUserExperience, ChartsSettingsProps, ChartsSettings, ChartType, ChartPropsGeneric, ChartProps, ChartOptions, ChartData, Chart };