@solace-health/ui 0.9.68 → 0.10.0

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.ts CHANGED
@@ -2,14 +2,17 @@ import * as react_jsx_runtime from 'react/jsx-runtime';
2
2
  import * as react from 'react';
3
3
  import { CSSProperties } from 'react';
4
4
  import dayjs from 'dayjs';
5
- import * as contentful from 'contentful';
6
- import { FunctionalComponent } from 'preact';
7
- import { TabsProps, MenuProps as MenuProps$1, DropDownProps, SubMenuProps } from 'antd';
8
- import { MenuProps } from '@szhsin/react-menu';
9
5
  import * as _emotion_styled from '@emotion/styled';
10
6
  export { default as styled } from '@emotion/styled';
11
- import * as _emotion_react from '@emotion/react';
12
7
  import * as preact_hooks from 'preact/hooks';
8
+ import * as _emotion_react from '@emotion/react';
9
+ import * as antd from 'antd';
10
+ import { MenuProps, DropDownProps, TabsProps, SubMenuProps } from 'antd';
11
+ import * as contentful from 'contentful';
12
+ import { MenuProps as MenuProps$1 } from '@szhsin/react-menu';
13
+ import { FunctionalComponent } from 'preact';
14
+ import * as antd_es_upload_interface from 'antd/es/upload/interface';
15
+ import * as antd_es_upload from 'antd/es/upload';
13
16
  import * as react_hook_form from 'react-hook-form';
14
17
  import { UseFormReturn } from 'react-hook-form';
15
18
  export { Controller, FormProvider, useFieldArray, useForm, useFormContext } from 'react-hook-form';
@@ -37,7 +40,7 @@ declare type Props$c = {
37
40
  };
38
41
  [extraProps: string]: unknown;
39
42
  };
40
- declare const _default$6: {
43
+ declare const _default$7: {
41
44
  Primary: ({ children, isSubmitting, toolTip, ...extraProps }: Props$c) => react_jsx_runtime.JSX.Element;
42
45
  Outline: ({ children, isSubmitting, toolTip, ...extraProps }: Props$c) => react_jsx_runtime.JSX.Element;
43
46
  Unstyled: ({ children, isSubmitting, toolTip, ...extraProps }: Props$c) => react_jsx_runtime.JSX.Element;
@@ -82,6 +85,16 @@ declare type Props$9 = {
82
85
  };
83
86
  declare const Drawer: ({ isOpen, onClose, children, title, placement, headerStyle, ...extraProps }: Props$9) => react_jsx_runtime.JSX.Element;
84
87
 
88
+ declare const Dropdown: _emotion_styled.StyledComponent<{
89
+ items: MenuProps["items"];
90
+ children: React.ReactNode;
91
+ className?: string | undefined;
92
+ } & DropDownProps & {
93
+ theme?: _emotion_react.Theme | undefined;
94
+ }, {}, {
95
+ ref?: preact_hooks.Ref<any> | undefined;
96
+ }>;
97
+
85
98
  declare const ErrorTypography: ({ children, text, includeIcon, marginBottom, }: {
86
99
  children?: React.ReactNode;
87
100
  text?: string | undefined;
@@ -89,6 +102,30 @@ declare const ErrorTypography: ({ children, text, includeIcon, marginBottom, }:
89
102
  marginBottom?: number | undefined;
90
103
  }) => react_jsx_runtime.JSX.Element;
91
104
 
105
+ declare type File = {
106
+ id: string;
107
+ name: string;
108
+ };
109
+ declare enum FileDisplay {
110
+ Card = "card",
111
+ List = "list"
112
+ }
113
+ declare type FileProps = {
114
+ file: File;
115
+ display?: FileDisplay;
116
+ handleDownload: (file: File) => void;
117
+ className?: string;
118
+ };
119
+ declare type GroupProps = {
120
+ files: File[];
121
+ handleDownload: (file: File) => void;
122
+ className?: string;
123
+ };
124
+ declare const _default$6: {
125
+ Group: ({ files, handleDownload, className }: GroupProps) => react_jsx_runtime.JSX.Element;
126
+ Display: ({ file, display, handleDownload, className, }: FileProps) => react_jsx_runtime.JSX.Element | null;
127
+ };
128
+
92
129
  declare const _default$5: {
93
130
  AddCircle: ({ color }: {
94
131
  color?: string | undefined;
@@ -129,6 +166,9 @@ declare const _default$5: {
129
166
  color?: string | undefined;
130
167
  }) => react_jsx_runtime.JSX.Element;
131
168
  Draggable: () => react_jsx_runtime.JSX.Element;
169
+ DownloadArrow: ({ fill }: {
170
+ fill?: string | undefined;
171
+ }) => react_jsx_runtime.JSX.Element;
132
172
  Invoice: ({ active, color }: {
133
173
  active?: boolean | undefined;
134
174
  color?: string | undefined;
@@ -172,6 +212,9 @@ declare const _default$5: {
172
212
  }) => react_jsx_runtime.JSX.Element;
173
213
  HeartPulse: () => JSX.Element;
174
214
  IdBadge: () => react_jsx_runtime.JSX.Element;
215
+ Image: ({ color }: {
216
+ color?: string | undefined;
217
+ }) => react_jsx_runtime.JSX.Element;
175
218
  Key: ({ active, color }: {
176
219
  active?: boolean | undefined;
177
220
  color?: string | undefined;
@@ -226,21 +269,6 @@ declare const _default$5: {
226
269
  Filter: () => react_jsx_runtime.JSX.Element;
227
270
  };
228
271
 
229
- declare enum PillStatus {
230
- Success = "success",
231
- Error = "error",
232
- Warning = "warning",
233
- Processing = "processing",
234
- Label = "label",
235
- Default = "default"
236
- }
237
- declare type Props$8 = {
238
- children: React.ReactNode;
239
- status?: PillStatus | string;
240
- icon?: React.ReactNode | null;
241
- };
242
- declare const Pill: ({ children, status, icon, }: Props$8) => react_jsx_runtime.JSX.Element;
243
-
244
272
  declare enum Size {
245
273
  XL = "xl",
246
274
  LG = "lg",
@@ -249,11 +277,11 @@ declare enum Size {
249
277
  XS = "xs"
250
278
  }
251
279
 
252
- declare type Props$7 = {
280
+ declare type Props$8 = {
253
281
  color?: string;
254
282
  size?: Size;
255
283
  };
256
- declare const LoadingSpinner: ({ color, size, }: Props$7) => react_jsx_runtime.JSX.Element;
284
+ declare const LoadingSpinner: ({ color, size, }: Props$8) => react_jsx_runtime.JSX.Element;
257
285
 
258
286
  declare enum ContentfulLottieFileSlug {
259
287
  LOADING_LISTINGS = "loadingListings",
@@ -273,7 +301,7 @@ declare class Contentful {
273
301
  getImage(slug: string): Promise<any>;
274
302
  }
275
303
 
276
- declare type Props$6 = {
304
+ declare type Props$7 = {
277
305
  height: number | string;
278
306
  width: number | string;
279
307
  loop: boolean;
@@ -283,49 +311,7 @@ declare type Props$6 = {
283
311
  accessToken: string;
284
312
  };
285
313
  };
286
- declare const LottieAnimation: ({ height, width, loop, slug, contentfulConfig, }: Props$6) => react_jsx_runtime.JSX.Element | null;
287
-
288
- declare type Props$5 = {
289
- children: React.ReactNode;
290
- isOpen: boolean;
291
- onClose?: () => void;
292
- width?: number;
293
- style?: any;
294
- bodyStyle?: any;
295
- };
296
- declare const Modal: ({ children, isOpen, onClose, width, style, bodyStyle, ...props }: Props$5) => react_jsx_runtime.JSX.Element;
297
-
298
- declare const Progress: ({ percent, size, }: {
299
- percent?: number | undefined;
300
- size?: number | undefined;
301
- }) => react_jsx_runtime.JSX.Element;
302
-
303
- declare type Props$4 = {
304
- onChange: (value: string) => void;
305
- options: string[] | number[] | Array<{
306
- label: FunctionalComponent;
307
- value: string;
308
- icon?: FunctionalComponent;
309
- disabled?: boolean;
310
- className?: string;
311
- }>;
312
- size: "small" | "middle" | "large";
313
- defaultValue: string;
314
- block: boolean;
315
- };
316
- declare const Segmented: ({ onChange, options, size, defaultValue, block, }: Props$4) => react_jsx_runtime.JSX.Element;
317
-
318
- declare type Props$3 = {
319
- color: string;
320
- };
321
- declare const SolaceLogo: ({ color }: Props$3) => react_jsx_runtime.JSX.Element;
322
-
323
- declare type Props$2 = {
324
- className?: string;
325
- navigate?: (url: string) => void;
326
- pathname?: string;
327
- } & TabsProps;
328
- declare const Tabs: ({ className, items, navigate, activeKey, pathname, ...otherProps }: Props$2) => react_jsx_runtime.JSX.Element;
314
+ declare const LottieAnimation: ({ height, width, loop, slug, contentfulConfig, }: Props$7) => react_jsx_runtime.JSX.Element | null;
329
315
 
330
316
  declare type ContainerProps = {
331
317
  cta: string | JSX.Element;
@@ -333,7 +319,7 @@ declare type ContainerProps = {
333
319
  onItemClick?: (e: any) => void;
334
320
  onMenuChange?: (e: any) => void;
335
321
  className?: string;
336
- menuProps?: MenuProps;
322
+ menuProps?: MenuProps$1;
337
323
  caretColor?: string;
338
324
  borderColor?: string;
339
325
  };
@@ -370,6 +356,78 @@ declare const _default$4: {
370
356
  Item: ({ label, value, selected, onClick, disabled, linkTo, className, }: ItemProps) => react_jsx_runtime.JSX.Element;
371
357
  };
372
358
 
359
+ declare type Props$6 = {
360
+ children: React.ReactNode;
361
+ isOpen: boolean;
362
+ onClose?: () => void;
363
+ width?: number;
364
+ style?: any;
365
+ bodyStyle?: any;
366
+ };
367
+ declare const Modal: ({ children, isOpen, onClose, width, style, bodyStyle, ...props }: Props$6) => react_jsx_runtime.JSX.Element;
368
+
369
+ interface Step {
370
+ title: string;
371
+ description: string;
372
+ }
373
+
374
+ declare const _default$3: {
375
+ Horizontal: ({ currentStep, steps, }: {
376
+ currentStep: number;
377
+ steps: string[];
378
+ }) => react_jsx_runtime.JSX.Element;
379
+ Vertical: ({ steps }: {
380
+ steps: Step[];
381
+ }) => react_jsx_runtime.JSX.Element;
382
+ };
383
+
384
+ declare enum PillStatus {
385
+ Success = "success",
386
+ Error = "error",
387
+ Warning = "warning",
388
+ Processing = "processing",
389
+ Label = "label",
390
+ Default = "default"
391
+ }
392
+ declare type Props$5 = {
393
+ children: React.ReactNode;
394
+ status?: PillStatus | string;
395
+ icon?: React.ReactNode | null;
396
+ };
397
+ declare const Pill: ({ children, status, icon, }: Props$5) => react_jsx_runtime.JSX.Element;
398
+
399
+ declare const Progress: ({ percent, size, }: {
400
+ percent?: number | undefined;
401
+ size?: number | undefined;
402
+ }) => react_jsx_runtime.JSX.Element;
403
+
404
+ declare type Props$4 = {
405
+ onChange: (value: string) => void;
406
+ options: string[] | number[] | Array<{
407
+ label: FunctionalComponent;
408
+ value: string;
409
+ icon?: FunctionalComponent;
410
+ disabled?: boolean;
411
+ className?: string;
412
+ }>;
413
+ size: "small" | "middle" | "large";
414
+ defaultValue: string;
415
+ block: boolean;
416
+ };
417
+ declare const Segmented: ({ onChange, options, size, defaultValue, block, }: Props$4) => react_jsx_runtime.JSX.Element;
418
+
419
+ declare type Props$3 = {
420
+ color: string;
421
+ };
422
+ declare const SolaceLogo: ({ color }: Props$3) => react_jsx_runtime.JSX.Element;
423
+
424
+ declare type Props$2 = {
425
+ className?: string;
426
+ navigate?: (url: string) => void;
427
+ pathname?: string;
428
+ } & TabsProps;
429
+ declare const Tabs: ({ className, items, navigate, activeKey, pathname, ...otherProps }: Props$2) => react_jsx_runtime.JSX.Element;
430
+
373
431
  declare type Props$1 = {
374
432
  startTime?: string;
375
433
  endTime?: string;
@@ -410,31 +468,6 @@ declare type ProviderProps = {
410
468
  };
411
469
  declare const SolaceThemeProvider: ({ children, theme, }: ProviderProps) => react_jsx_runtime.JSX.Element;
412
470
 
413
- interface Step {
414
- title: string;
415
- description: string;
416
- }
417
-
418
- declare const _default$3: {
419
- Horizontal: ({ currentStep, steps, }: {
420
- currentStep: number;
421
- steps: string[];
422
- }) => react_jsx_runtime.JSX.Element;
423
- Vertical: ({ steps }: {
424
- steps: Step[];
425
- }) => react_jsx_runtime.JSX.Element;
426
- };
427
-
428
- declare const Dropdown: _emotion_styled.StyledComponent<{
429
- items: MenuProps$1["items"];
430
- children: React.ReactNode;
431
- className?: string | undefined;
432
- } & DropDownProps & {
433
- theme?: _emotion_react.Theme | undefined;
434
- }, {}, {
435
- ref?: preact_hooks.Ref<any> | undefined;
436
- }>;
437
-
438
471
  declare const _default$2: {
439
472
  Container: ({ formMethods, formOptions, onSubmit, children, className, }: {
440
473
  formMethods?: UseFormReturn<any, any> | null | undefined;
@@ -501,6 +534,11 @@ declare const _default$2: {
501
534
  value: string;
502
535
  }[];
503
536
  }) => react_jsx_runtime.JSX.Element;
537
+ InputLabel: ({ label, isLabelBold, required, }: {
538
+ label: string | JSX.Element | null;
539
+ isLabelBold?: boolean | undefined;
540
+ required?: boolean | undefined;
541
+ }) => react_jsx_runtime.JSX.Element;
504
542
  DateSelect: ({ label, isLabelBold, name, required, disabled, defaultValue, options, ...inputProps }: {
505
543
  [inputProps: string]: unknown;
506
544
  label?: string | JSX.Element | null | undefined;
@@ -667,21 +705,42 @@ declare const _default$2: {
667
705
  disabled?: boolean | undefined;
668
706
  loading?: boolean | undefined;
669
707
  }) => react_jsx_runtime.JSX.Element;
670
- FileUpload: ({ label, name, disabled, description, isLabelBold, formOptions, onChange, defaultValue, containerStyle, errorMessage, }: {
708
+ FileUpload: ({ label, name, disabled, description, isLabelBold, formOptions, onChange, onRemove, onDownload, defaultValue, containerStyle, errorMessage, action, headers, uploadData, defaultFileList, }: {
671
709
  label?: string | JSX.Element | undefined;
672
710
  name: string;
673
711
  formOptions?: react_hook_form.RegisterOptions<react_hook_form.FieldValues, string> | undefined;
674
712
  disabled?: boolean | undefined;
675
713
  isLabelBold?: boolean | undefined;
676
714
  description?: string | JSX.Element | undefined;
677
- onChange?: (() => void) | undefined;
715
+ onChange?: ((uploadChange: antd_es_upload.UploadChangeParam<antd.UploadFile<any>>) => void) | undefined;
716
+ onRemove?: ((file: antd.UploadFile<any>) => void) | undefined;
717
+ onDownload?: ((file: antd.UploadFile<any>) => void) | undefined;
678
718
  containerStyle?: react.CSSProperties | undefined;
679
719
  errorMessage?: string | undefined;
680
720
  defaultValue?: string | undefined;
721
+ action: string;
722
+ headers?: antd_es_upload_interface.HttpRequestHeader | undefined;
723
+ uploadData?: Record<string, unknown> | undefined;
724
+ defaultFileList?: antd.UploadFile<any>[] | undefined;
681
725
  }) => react_jsx_runtime.JSX.Element;
682
726
  };
683
727
 
728
+ declare type NavigationMenuProps = {
729
+ children: React.ReactNode;
730
+ } & Omit<MenuProps, "ref" | "theme">;
684
731
  declare const _default$1: {
732
+ Container: ({ children, ...rest }: NavigationMenuProps) => react_jsx_runtime.JSX.Element;
733
+ MenuDivider: (props: MenuDividerProps) => react_jsx_runtime.JSX.Element;
734
+ MenuItem: ({ children, ...rest }: {
735
+ children: react.ReactNode;
736
+ } & MenuItemType) => react_jsx_runtime.JSX.Element;
737
+ SubMenuContainer: ({ children, ...rest }: {
738
+ children: react.ReactNode;
739
+ hideExpandIcon?: boolean | undefined;
740
+ } & SubMenuProps) => react_jsx_runtime.JSX.Element;
741
+ };
742
+
743
+ declare const _default: {
685
744
  Body: ({ className, children, size, color, center, }: {
686
745
  className?: string | undefined;
687
746
  size?: Size | undefined;
@@ -717,19 +776,4 @@ declare const VantaLogo: ({ contentfulConfig, size, }: {
717
776
  size?: number | undefined;
718
777
  }) => react_jsx_runtime.JSX.Element | null;
719
778
 
720
- declare type NavigationMenuProps = {
721
- children: React.ReactNode;
722
- } & Omit<MenuProps$1, "ref" | "theme">;
723
- declare const _default: {
724
- Container: ({ children, ...rest }: NavigationMenuProps) => react_jsx_runtime.JSX.Element;
725
- MenuDivider: (props: MenuDividerProps) => react_jsx_runtime.JSX.Element;
726
- MenuItem: ({ children, ...rest }: {
727
- children: react.ReactNode;
728
- } & MenuItemType) => react_jsx_runtime.JSX.Element;
729
- SubMenuContainer: ({ children, ...rest }: {
730
- children: react.ReactNode;
731
- hideExpandIcon?: boolean | undefined;
732
- } & SubMenuProps) => react_jsx_runtime.JSX.Element;
733
- };
734
-
735
- export { Avatar, _default$6 as Button, Collapse, Contentful, ContentfulLottieFileSlug, DateSelect, Drawer, Dropdown, ErrorTypography, _default$2 as Form, _default$5 as Icons, LoadingSpinner, LottieAnimation, _default$4 as Menu, Modal, _default as NavigationMenu, _default$3 as NumberedProgressSteps, Pill, Progress, Segmented, Size, SolaceLogo, SolaceThemeProvider, Tabs, TimeSelect, Toggle, Tooltip, _default$1 as Typography, VantaLogo };
779
+ export { Avatar, _default$7 as Button, Collapse, Contentful, ContentfulLottieFileSlug, DateSelect, Drawer, Dropdown, ErrorTypography, _default$6 as File, _default$2 as Form, _default$5 as Icons, LoadingSpinner, LottieAnimation, _default$4 as Menu, Modal, _default$1 as NavigationMenu, _default$3 as NumberedProgressSteps, Pill, Progress, Segmented, Size, SolaceLogo, SolaceThemeProvider, Tabs, TimeSelect, Toggle, Tooltip, _default as Typography, VantaLogo };