@transferwise/components 43.13.40 → 43.13.44

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.
Files changed (34) hide show
  1. package/build/es/no-polyfill/body/Body.js +3 -1
  2. package/build/es/no-polyfill/decision/Decision.js +5 -5
  3. package/build/es/no-polyfill/dimmer/Dimmer.js +2 -2
  4. package/build/es/no-polyfill/dropFade/DropFade.js +3 -3
  5. package/build/es/no-polyfill/dropFade/DropFade.story.js +1 -1
  6. package/build/es/no-polyfill/index.js +1 -1
  7. package/build/es/no-polyfill/modal/Modal.js +1 -1
  8. package/build/es/no-polyfill/slidingPanel/SlidingPanel.js +2 -2
  9. package/build/es/no-polyfill/snackbar/Snackbar.js +1 -1
  10. package/build/es/polyfill/body/Body.js +3 -1
  11. package/build/es/polyfill/decision/Decision.js +5 -5
  12. package/build/es/polyfill/dimmer/Dimmer.js +2 -2
  13. package/build/es/polyfill/dropFade/DropFade.js +3 -3
  14. package/build/es/polyfill/dropFade/DropFade.story.js +1 -1
  15. package/build/es/polyfill/index.js +1 -1
  16. package/build/es/polyfill/modal/Modal.js +1 -1
  17. package/build/es/polyfill/slidingPanel/SlidingPanel.js +2 -2
  18. package/build/es/polyfill/snackbar/Snackbar.js +1 -1
  19. package/build/main.css +1 -1
  20. package/build/styles/dimmer/Dimmer.css +1 -1
  21. package/build/styles/main.css +1 -1
  22. package/build/types/body/Body.d.ts +4 -5
  23. package/build/types/body/Body.story.d.ts +4 -2
  24. package/build/types/common/panel/Panel.d.ts +1 -1
  25. package/build/types/common/responsivePanel/ResponsivePanel.d.ts +1 -1
  26. package/build/types/decision/Decision.d.ts +4 -0
  27. package/build/types/dimmer/Dimmer.d.ts +4 -2
  28. package/build/types/dimmer/Dimmer.story.d.ts +1 -0
  29. package/build/types/index.d.ts +1 -1
  30. package/build/types/test-utils/index.d.ts +1 -1
  31. package/build/types/tooltip/Tooltip.story.d.ts +1 -1
  32. package/build/umd/no-polyfill/main.js +1 -1
  33. package/build/umd/polyfill/main.js +1 -1
  34. package/package.json +9 -5
@@ -1,14 +1,13 @@
1
1
  import { HTMLAttributes } from 'react';
2
2
  import { BodyTypes } from '../common/propsValues/typography';
3
- type Props = HTMLAttributes<HTMLSpanElement | HTMLParagraphElement> & {
3
+ declare const Body: import("react").ForwardRefExoticComponent<HTMLAttributes<HTMLParagraphElement | HTMLSpanElement> & {
4
4
  /**
5
5
  * Default value: {@link DEFAULT_TYPE}
6
6
  */
7
- type?: BodyTypes;
7
+ type?: BodyTypes | undefined;
8
8
  /**
9
9
  * Default value: `div`
10
10
  */
11
- as?: 'span' | 'p' | 'div';
12
- };
13
- declare function Body({ as: Element, type, className, ...props }: Props): JSX.Element;
11
+ as?: "div" | "p" | "span" | undefined;
12
+ } & import("react").RefAttributes<HTMLDivElement | HTMLParagraphElement | HTMLSpanElement>>;
14
13
  export default Body;
@@ -1,7 +1,9 @@
1
1
  /// <reference types="react" />
2
- import Body from './Body';
3
2
  declare const _default: {
4
- component: typeof Body;
3
+ component: import("react").ForwardRefExoticComponent<import("react").HTMLAttributes<HTMLParagraphElement | HTMLSpanElement> & {
4
+ type?: import("../common/propsValues/typography").BodyTypes | undefined;
5
+ as?: "div" | "p" | "span" | undefined;
6
+ } & import("react").RefAttributes<HTMLDivElement | HTMLParagraphElement | HTMLSpanElement>>;
5
7
  title: string;
6
8
  };
7
9
  export default _default;
@@ -16,7 +16,7 @@ declare const Panel: import("react").ForwardRefExoticComponent<{
16
16
  altAxis?: boolean | undefined;
17
17
  open?: boolean | undefined;
18
18
  onClose?: ((event: Event | SyntheticEvent) => void) | undefined;
19
- position?: "left" | "right" | "top" | "bottom" | undefined;
19
+ position?: "top" | "bottom" | "left" | "right" | undefined;
20
20
  anchorRef: RefObject<Element>;
21
21
  anchorWidth?: boolean | undefined;
22
22
  } & {
@@ -5,7 +5,7 @@ declare const ResponsivePanel: import("react").ForwardRefExoticComponent<{
5
5
  altAxis?: boolean | undefined;
6
6
  open?: boolean | undefined;
7
7
  onClose?: ((event: Event | import("react").SyntheticEvent<Element, Event>) => void) | undefined;
8
- position?: "left" | "right" | "top" | "bottom" | undefined;
8
+ position?: "top" | "bottom" | "left" | "right" | undefined;
9
9
  anchorRef: import("react").RefObject<Element>;
10
10
  anchorWidth?: boolean | undefined;
11
11
  } & {
@@ -40,6 +40,10 @@ export interface DecisionProps {
40
40
  * Display media in a circle in list presentation
41
41
  */
42
42
  showMediaCircleInList?: boolean;
43
+ /**
44
+ * Sets navigation options to be aligned with the parent container
45
+ */
46
+ isContainerAligned?: boolean;
43
47
  }
44
48
 
45
49
  declare const Decision: React.FC<DecisionProps>;
@@ -1,9 +1,10 @@
1
1
  import { MouseEvent, ReactElement, ReactNode } from 'react';
2
- import { CommonProps } from '../common';
2
+ import { CommonProps, PositionBottom, PositionCenter, PositionTop } from '../common';
3
3
  export declare const EXIT_ANIMATION = 350;
4
4
  type DimmerProps = CommonProps & {
5
5
  children?: ReactNode;
6
6
  disableClickToClose?: boolean;
7
+ contentPosition?: PositionTop | PositionCenter | PositionBottom;
7
8
  fadeContentOnEnter?: boolean;
8
9
  fadeContentOnExit?: boolean;
9
10
  open?: boolean;
@@ -12,7 +13,7 @@ type DimmerProps = CommonProps & {
12
13
  onClose?: (event: KeyboardEvent | MouseEvent) => void;
13
14
  };
14
15
  export declare const handleTouchMove: (event: Event) => void;
15
- declare const Dimmer: ({ children, className, disableClickToClose, fadeContentOnEnter, fadeContentOnExit, open, scrollable, transparent, onClose, }: DimmerProps) => JSX.Element;
16
+ declare const Dimmer: ({ children, className, disableClickToClose, contentPosition, fadeContentOnEnter, fadeContentOnExit, open, scrollable, transparent, onClose, }: DimmerProps) => JSX.Element;
16
17
  export declare const DimmerContentWrapper: ({ children, scrollBody, }: {
17
18
  children: ReactElement;
18
19
  scrollBody: boolean;
@@ -21,6 +22,7 @@ export { Dimmer };
21
22
  declare const _default: (props: CommonProps & {
22
23
  children?: ReactNode;
23
24
  disableClickToClose?: boolean | undefined;
25
+ contentPosition?: "top" | "center" | "bottom" | undefined;
24
26
  fadeContentOnEnter?: boolean | undefined;
25
27
  fadeContentOnExit?: boolean | undefined;
26
28
  open?: boolean | undefined;
@@ -3,6 +3,7 @@ declare const _default: {
3
3
  component: (props: import("../common").CommonProps & {
4
4
  children?: import("react").ReactNode;
5
5
  disableClickToClose?: boolean | undefined;
6
+ contentPosition?: "top" | "center" | "bottom" | undefined;
6
7
  fadeContentOnEnter?: boolean | undefined;
7
8
  fadeContentOnExit?: boolean | undefined;
8
9
  open?: boolean | undefined;
@@ -101,7 +101,7 @@ export { FileType } from './common';
101
101
  /**
102
102
  * Utils
103
103
  */
104
- export { SUPPORTED_LANGUAGES, RTL_LANGUAGES, DEFAULT_LANG, DEFAULT_LOCALE, adjustLocale, getLangFromLocale, getCountryFromLocale, getDirectionFromLocale, isServerSide, isBrowser, } from './common';
104
+ export { adjustLocale, DEFAULT_LANG, DEFAULT_LOCALE, getCountryFromLocale, getDirectionFromLocale, getLangFromLocale, isBrowser, isServerSide, RTL_LANGUAGES, SUPPORTED_LANGUAGES, } from './common';
105
105
  /**
106
106
  * Translations
107
107
  */
@@ -51,7 +51,7 @@ declare function customRender(ui: any, { locale, messages, ...renderOptions }?:
51
51
  "neptune.UploadItem.uploading": string;
52
52
  "neptune.UploadItem.uploadingFailed": string;
53
53
  } | undefined;
54
- }): import("@testing-library/react").RenderResult<typeof import("@testing-library/react/node_modules/@testing-library/dom/types/queries"), HTMLElement>;
54
+ }): import("@testing-library/react").RenderResult<typeof import("@testing-library/dom/types/queries"), HTMLElement>;
55
55
  /**
56
56
  * Custom `renderHook` function which wraps passed elements in Provider component
57
57
  * For more info: https://react-hooks-testing-library.com/usage/advanced-hooks#context
@@ -1,7 +1,7 @@
1
1
  /// <reference types="react" />
2
2
  declare const _default: {
3
3
  component: ({ position, children, label, className, }: {
4
- position?: "left" | "right" | "top" | "bottom" | undefined;
4
+ position?: "top" | "bottom" | "left" | "right" | undefined;
5
5
  label: import("react").ReactNode;
6
6
  } & {
7
7
  children?: import("react").ReactNode;