@reltio/components 1.4.2217 → 1.4.2219

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 (27) hide show
  1. package/AttributeListItem/AttributeListItem.d.ts +1 -0
  2. package/FacetContainer/FacetContainer.d.ts +1 -0
  3. package/FacetContainer/components/ChipsCount/ChipsCount.d.ts +1 -0
  4. package/HOCs/withTooltip/withTooltip.d.ts +1 -0
  5. package/HOCs/withTooltip/withTooltip.js +3 -2
  6. package/InfoIcon/InfoIcon.d.ts +1 -0
  7. package/OvIcon/OvIcon.d.ts +1 -0
  8. package/ReltioMap/components/TopRightMapControls/TopRightMapControls.d.ts +1 -0
  9. package/SimpleMatchRulesBlock/SimpleMatchRulesBlock.d.ts +1 -0
  10. package/SmallIconButton/index.d.ts +1 -0
  11. package/TransitiveMatchBlock/TransitiveMatchBlock.d.ts +1 -0
  12. package/cjs/AttributeListItem/AttributeListItem.d.ts +1 -0
  13. package/cjs/FacetContainer/FacetContainer.d.ts +1 -0
  14. package/cjs/FacetContainer/components/ChipsCount/ChipsCount.d.ts +1 -0
  15. package/cjs/HOCs/withTooltip/withTooltip.d.ts +1 -0
  16. package/cjs/HOCs/withTooltip/withTooltip.js +3 -2
  17. package/cjs/InfoIcon/InfoIcon.d.ts +1 -0
  18. package/cjs/OvIcon/OvIcon.d.ts +1 -0
  19. package/cjs/ReltioMap/components/TopRightMapControls/TopRightMapControls.d.ts +1 -0
  20. package/cjs/SimpleMatchRulesBlock/SimpleMatchRulesBlock.d.ts +1 -0
  21. package/cjs/SmallIconButton/index.d.ts +1 -0
  22. package/cjs/TransitiveMatchBlock/TransitiveMatchBlock.d.ts +1 -0
  23. package/cjs/features/activity-log/ActivityLog/components/ActivityItem/ActivityItem.js +12 -4
  24. package/cjs/features/history/HistoryGraph/HistoryGraph.d.ts +1 -0
  25. package/features/activity-log/ActivityLog/components/ActivityItem/ActivityItem.js +12 -4
  26. package/features/history/HistoryGraph/HistoryGraph.d.ts +1 -0
  27. package/package.json +2 -2
@@ -5,6 +5,7 @@ export declare const RecommendedIconWithTooltip: React.ForwardRefExoticComponent
5
5
  tooltipTitle?: import("@mui/material").TooltipProps["title"];
6
6
  tooltipPlacement?: import("@mui/material").TooltipProps["placement"];
7
7
  showForDisabled?: boolean;
8
+ tooltipClassName?: string;
8
9
  } & React.SVGProps<SVGSVGElement>, "ref"> & React.RefAttributes<HTMLElement>>;
9
10
  type Data = Record<string, unknown> & {
10
11
  attrType?: AttributeType;
@@ -3,6 +3,7 @@ export declare const RecommendedIconWithTooltip: React.ForwardRefExoticComponent
3
3
  tooltipTitle?: import("@mui/material").TooltipProps["title"];
4
4
  tooltipPlacement?: import("@mui/material").TooltipProps["placement"];
5
5
  showForDisabled?: boolean;
6
+ tooltipClassName?: string;
6
7
  } & React.SVGProps<SVGSVGElement>, "ref"> & React.RefAttributes<HTMLElement>>;
7
8
  export type Props = {
8
9
  children?: React.ReactNode;
@@ -4,6 +4,7 @@ export declare const ClearIconWithTooltip: React.ForwardRefExoticComponent<Omit<
4
4
  tooltipTitle?: import("@mui/material").TooltipProps["title"];
5
5
  tooltipPlacement?: import("@mui/material").TooltipProps["placement"];
6
6
  showForDisabled?: boolean;
7
+ tooltipClassName?: string;
7
8
  } & {
8
9
  children?: React.ReactNode;
9
10
  classes?: Partial<import("@mui/material").SvgIconClasses>;
@@ -4,6 +4,7 @@ type WithTooltipProps = {
4
4
  tooltipTitle?: TooltipProps['title'];
5
5
  tooltipPlacement?: TooltipProps['placement'];
6
6
  showForDisabled?: boolean;
7
+ tooltipClassName?: string;
7
8
  };
8
9
  export declare const withTooltip: <Props, AdditionalProps>(Component: React.ComponentType<Props> | React.ElementType) => React.ForwardRefExoticComponent<React.PropsWithoutRef<WithTooltipProps & Props & AdditionalProps> & React.RefAttributes<HTMLElement>>;
9
10
  export {};
@@ -23,15 +23,16 @@ var __rest = (this && this.__rest) || function (s, e) {
23
23
  import React, { forwardRef } from 'react';
24
24
  import Tooltip from '@mui/material/Tooltip';
25
25
  import { useStyles } from './styles';
26
+ import classnames from 'classnames';
26
27
  export var withTooltip = function (Component) {
27
28
  var WithTooltip = forwardRef(function (_a, ref) {
28
- var tooltipTitle = _a.tooltipTitle, tooltipPlacement = _a.tooltipPlacement, _b = _a.showForDisabled, showForDisabled = _b === void 0 ? false : _b, componentProps = __rest(_a, ["tooltipTitle", "tooltipPlacement", "showForDisabled"]);
29
+ var tooltipTitle = _a.tooltipTitle, tooltipPlacement = _a.tooltipPlacement, _b = _a.showForDisabled, showForDisabled = _b === void 0 ? false : _b, tooltipClassName = _a.tooltipClassName, componentProps = __rest(_a, ["tooltipTitle", "tooltipPlacement", "showForDisabled", "tooltipClassName"]);
29
30
  var styles = useStyles();
30
31
  var renderWrappedComponent = function (showForDisabled) {
31
32
  return showForDisabled ? (React.createElement("span", { ref: ref, className: styles.wrapper },
32
33
  React.createElement(Component, __assign({}, componentProps)))) : (React.createElement(Component, __assign({ ref: ref }, componentProps)));
33
34
  };
34
- return tooltipTitle ? (React.createElement(Tooltip, { ref: ref, title: tooltipTitle, placement: tooltipPlacement || 'bottom', disableFocusListener: true, disableTouchListener: true, classes: { tooltip: styles.tooltip }, PopperProps: {
35
+ return tooltipTitle ? (React.createElement(Tooltip, { ref: ref, title: tooltipTitle, placement: tooltipPlacement || 'bottom', disableFocusListener: true, disableTouchListener: true, classes: { tooltip: classnames(styles.tooltip, tooltipClassName) }, PopperProps: {
35
36
  modifiers: [{ name: 'preventOverflow', options: { altAxis: true } }]
36
37
  } }, renderWrappedComponent(showForDisabled))) : (React.createElement(Component, __assign({ ref: ref }, componentProps)));
37
38
  });
@@ -3,4 +3,5 @@ export declare const InfoIcon: React.ForwardRefExoticComponent<Omit<{
3
3
  tooltipTitle?: import("@mui/material").TooltipProps["title"];
4
4
  tooltipPlacement?: import("@mui/material").TooltipProps["placement"];
5
5
  showForDisabled?: boolean;
6
+ tooltipClassName?: string;
6
7
  } & Omit<Record<string, unknown>, "ref"> & React.RefAttributes<HTMLSpanElement>, "ref"> & React.RefAttributes<HTMLElement>>;
@@ -4,6 +4,7 @@ export declare const ChipWithTooltip: React.ForwardRefExoticComponent<Omit<{
4
4
  tooltipTitle?: import("@mui/material").TooltipProps["title"];
5
5
  tooltipPlacement?: import("@mui/material").TooltipProps["placement"];
6
6
  showForDisabled?: boolean;
7
+ tooltipClassName?: string;
7
8
  } & {
8
9
  avatar?: React.ReactElement;
9
10
  children?: null;
@@ -4,6 +4,7 @@ export declare const ButtonWithTooltip: React.ForwardRefExoticComponent<Omit<{
4
4
  tooltipTitle?: import("@mui/material").TooltipProps["title"];
5
5
  tooltipPlacement?: import("@mui/material").TooltipProps["placement"];
6
6
  showForDisabled?: boolean;
7
+ tooltipClassName?: string;
7
8
  } & {
8
9
  children?: React.ReactNode;
9
10
  classes?: Partial<import("@mui/material/Button").ButtonClasses>;
@@ -4,6 +4,7 @@ export declare const MatchRuleBadgeWithTooltip: React.ForwardRefExoticComponent<
4
4
  tooltipTitle?: import("@mui/material").TooltipProps["title"];
5
5
  tooltipPlacement?: import("@mui/material").TooltipProps["placement"];
6
6
  showForDisabled?: boolean;
7
+ tooltipClassName?: string;
7
8
  } & Omit<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref">, "onClick"> & {
8
9
  expanded?: boolean;
9
10
  onExpand?: React.MouseEventHandler<HTMLDivElement>;
@@ -3,6 +3,7 @@ declare const SmallIconButtonWithTooltip: import("react").ForwardRefExoticCompon
3
3
  tooltipTitle?: import("@mui/material").TooltipProps["title"];
4
4
  tooltipPlacement?: import("@mui/material").TooltipProps["placement"];
5
5
  showForDisabled?: boolean;
6
+ tooltipClassName?: string;
6
7
  } & Omit<Omit<import("@mui/material").IconButtonProps, "size"> & {
7
8
  iconClassName?: string;
8
9
  icon?: React.ElementType;
@@ -4,6 +4,7 @@ export declare const MatchRuleBadgeWithTooltip: React.ForwardRefExoticComponent<
4
4
  tooltipTitle?: import("@mui/material").TooltipProps["title"];
5
5
  tooltipPlacement?: import("@mui/material").TooltipProps["placement"];
6
6
  showForDisabled?: boolean;
7
+ tooltipClassName?: string;
7
8
  } & Omit<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref">, "onClick"> & {
8
9
  expanded?: boolean;
9
10
  onExpand?: React.MouseEventHandler<HTMLDivElement>;
@@ -5,6 +5,7 @@ export declare const RecommendedIconWithTooltip: React.ForwardRefExoticComponent
5
5
  tooltipTitle?: import("@mui/material").TooltipProps["title"];
6
6
  tooltipPlacement?: import("@mui/material").TooltipProps["placement"];
7
7
  showForDisabled?: boolean;
8
+ tooltipClassName?: string;
8
9
  } & React.SVGProps<SVGSVGElement>, "ref"> & React.RefAttributes<HTMLElement>>;
9
10
  type Data = Record<string, unknown> & {
10
11
  attrType?: AttributeType;
@@ -3,6 +3,7 @@ export declare const RecommendedIconWithTooltip: React.ForwardRefExoticComponent
3
3
  tooltipTitle?: import("@mui/material").TooltipProps["title"];
4
4
  tooltipPlacement?: import("@mui/material").TooltipProps["placement"];
5
5
  showForDisabled?: boolean;
6
+ tooltipClassName?: string;
6
7
  } & React.SVGProps<SVGSVGElement>, "ref"> & React.RefAttributes<HTMLElement>>;
7
8
  export type Props = {
8
9
  children?: React.ReactNode;
@@ -4,6 +4,7 @@ export declare const ClearIconWithTooltip: React.ForwardRefExoticComponent<Omit<
4
4
  tooltipTitle?: import("@mui/material").TooltipProps["title"];
5
5
  tooltipPlacement?: import("@mui/material").TooltipProps["placement"];
6
6
  showForDisabled?: boolean;
7
+ tooltipClassName?: string;
7
8
  } & {
8
9
  children?: React.ReactNode;
9
10
  classes?: Partial<import("@mui/material").SvgIconClasses>;
@@ -4,6 +4,7 @@ type WithTooltipProps = {
4
4
  tooltipTitle?: TooltipProps['title'];
5
5
  tooltipPlacement?: TooltipProps['placement'];
6
6
  showForDisabled?: boolean;
7
+ tooltipClassName?: string;
7
8
  };
8
9
  export declare const withTooltip: <Props, AdditionalProps>(Component: React.ComponentType<Props> | React.ElementType) => React.ForwardRefExoticComponent<React.PropsWithoutRef<WithTooltipProps & Props & AdditionalProps> & React.RefAttributes<HTMLElement>>;
9
10
  export {};
@@ -52,15 +52,16 @@ exports.withTooltip = void 0;
52
52
  var react_1 = __importStar(require("react"));
53
53
  var Tooltip_1 = __importDefault(require("@mui/material/Tooltip"));
54
54
  var styles_1 = require("./styles");
55
+ var classnames_1 = __importDefault(require("classnames"));
55
56
  var withTooltip = function (Component) {
56
57
  var WithTooltip = (0, react_1.forwardRef)(function (_a, ref) {
57
- var tooltipTitle = _a.tooltipTitle, tooltipPlacement = _a.tooltipPlacement, _b = _a.showForDisabled, showForDisabled = _b === void 0 ? false : _b, componentProps = __rest(_a, ["tooltipTitle", "tooltipPlacement", "showForDisabled"]);
58
+ var tooltipTitle = _a.tooltipTitle, tooltipPlacement = _a.tooltipPlacement, _b = _a.showForDisabled, showForDisabled = _b === void 0 ? false : _b, tooltipClassName = _a.tooltipClassName, componentProps = __rest(_a, ["tooltipTitle", "tooltipPlacement", "showForDisabled", "tooltipClassName"]);
58
59
  var styles = (0, styles_1.useStyles)();
59
60
  var renderWrappedComponent = function (showForDisabled) {
60
61
  return showForDisabled ? (react_1.default.createElement("span", { ref: ref, className: styles.wrapper },
61
62
  react_1.default.createElement(Component, __assign({}, componentProps)))) : (react_1.default.createElement(Component, __assign({ ref: ref }, componentProps)));
62
63
  };
63
- return tooltipTitle ? (react_1.default.createElement(Tooltip_1.default, { ref: ref, title: tooltipTitle, placement: tooltipPlacement || 'bottom', disableFocusListener: true, disableTouchListener: true, classes: { tooltip: styles.tooltip }, PopperProps: {
64
+ return tooltipTitle ? (react_1.default.createElement(Tooltip_1.default, { ref: ref, title: tooltipTitle, placement: tooltipPlacement || 'bottom', disableFocusListener: true, disableTouchListener: true, classes: { tooltip: (0, classnames_1.default)(styles.tooltip, tooltipClassName) }, PopperProps: {
64
65
  modifiers: [{ name: 'preventOverflow', options: { altAxis: true } }]
65
66
  } }, renderWrappedComponent(showForDisabled))) : (react_1.default.createElement(Component, __assign({ ref: ref }, componentProps)));
66
67
  });
@@ -3,4 +3,5 @@ export declare const InfoIcon: React.ForwardRefExoticComponent<Omit<{
3
3
  tooltipTitle?: import("@mui/material").TooltipProps["title"];
4
4
  tooltipPlacement?: import("@mui/material").TooltipProps["placement"];
5
5
  showForDisabled?: boolean;
6
+ tooltipClassName?: string;
6
7
  } & Omit<Record<string, unknown>, "ref"> & React.RefAttributes<HTMLSpanElement>, "ref"> & React.RefAttributes<HTMLElement>>;
@@ -4,6 +4,7 @@ export declare const ChipWithTooltip: React.ForwardRefExoticComponent<Omit<{
4
4
  tooltipTitle?: import("@mui/material").TooltipProps["title"];
5
5
  tooltipPlacement?: import("@mui/material").TooltipProps["placement"];
6
6
  showForDisabled?: boolean;
7
+ tooltipClassName?: string;
7
8
  } & {
8
9
  avatar?: React.ReactElement;
9
10
  children?: null;
@@ -4,6 +4,7 @@ export declare const ButtonWithTooltip: React.ForwardRefExoticComponent<Omit<{
4
4
  tooltipTitle?: import("@mui/material").TooltipProps["title"];
5
5
  tooltipPlacement?: import("@mui/material").TooltipProps["placement"];
6
6
  showForDisabled?: boolean;
7
+ tooltipClassName?: string;
7
8
  } & {
8
9
  children?: React.ReactNode;
9
10
  classes?: Partial<import("@mui/material/Button").ButtonClasses>;
@@ -4,6 +4,7 @@ export declare const MatchRuleBadgeWithTooltip: React.ForwardRefExoticComponent<
4
4
  tooltipTitle?: import("@mui/material").TooltipProps["title"];
5
5
  tooltipPlacement?: import("@mui/material").TooltipProps["placement"];
6
6
  showForDisabled?: boolean;
7
+ tooltipClassName?: string;
7
8
  } & Omit<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref">, "onClick"> & {
8
9
  expanded?: boolean;
9
10
  onExpand?: React.MouseEventHandler<HTMLDivElement>;
@@ -3,6 +3,7 @@ declare const SmallIconButtonWithTooltip: import("react").ForwardRefExoticCompon
3
3
  tooltipTitle?: import("@mui/material").TooltipProps["title"];
4
4
  tooltipPlacement?: import("@mui/material").TooltipProps["placement"];
5
5
  showForDisabled?: boolean;
6
+ tooltipClassName?: string;
6
7
  } & Omit<Omit<import("@mui/material").IconButtonProps, "size"> & {
7
8
  iconClassName?: string;
8
9
  icon?: React.ElementType;
@@ -4,6 +4,7 @@ export declare const MatchRuleBadgeWithTooltip: React.ForwardRefExoticComponent<
4
4
  tooltipTitle?: import("@mui/material").TooltipProps["title"];
5
5
  tooltipPlacement?: import("@mui/material").TooltipProps["placement"];
6
6
  showForDisabled?: boolean;
7
+ tooltipClassName?: string;
7
8
  } & Omit<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref">, "onClick"> & {
8
9
  expanded?: boolean;
9
10
  onExpand?: React.MouseEventHandler<HTMLDivElement>;
@@ -8,6 +8,8 @@ var react_1 = __importDefault(require("react"));
8
8
  var ui_i18n_1 = __importDefault(require("ui-i18n"));
9
9
  var activities_1 = require("../../../utils/activities");
10
10
  var ActivitiesFactory_1 = require("../../../ActivitiesFactory");
11
+ var ErrorBoundary_1 = require("../../../../../ErrorBoundary");
12
+ var ActivityTitle_1 = require("../../../ActivityTitle");
11
13
  var styles_1 = require("./styles");
12
14
  var ActivityItem = function (_a) {
13
15
  var item = _a.item;
@@ -20,9 +22,15 @@ var ActivityItem = function (_a) {
20
22
  react_1.default.createElement("div", { className: styles.userContainer },
21
23
  react_1.default.createElement("span", { className: styles.activityUser }, item.user),
22
24
  react_1.default.createElement("span", { className: styles.date }, ui_i18n_1.default.date(item.timestamp, 'LT'))),
23
- activities.map(function (activity, index) { return (react_1.default.createElement("div", { key: index, className: styles.activityEvent }, ActivitiesFactory_1.ActivitiesFactory.getComponent({
24
- type: (0, activities_1.getActivityType)(activity),
25
- data: activity
26
- }))); }))));
25
+ activities.map(function (activity, index) {
26
+ var activityType = (0, activities_1.getActivityType)(activity);
27
+ return (react_1.default.createElement("div", { key: index, className: styles.activityEvent },
28
+ react_1.default.createElement(ErrorBoundary_1.ErrorBoundary, { error: react_1.default.createElement(react_1.default.Fragment, null,
29
+ react_1.default.createElement(ActivityTitle_1.ActivityTitle, { type: activityType }),
30
+ ui_i18n_1.default.text("Can't render activity")) }, ActivitiesFactory_1.ActivitiesFactory.getComponent({
31
+ type: activityType,
32
+ data: activity
33
+ }))));
34
+ }))));
27
35
  };
28
36
  exports.ActivityItem = ActivityItem;
@@ -4,6 +4,7 @@ export declare const HistoryCircleWithTooltip: React.ForwardRefExoticComponent<O
4
4
  tooltipTitle?: import("@mui/material").TooltipProps["title"];
5
5
  tooltipPlacement?: import("@mui/material").TooltipProps["placement"];
6
6
  showForDisabled?: boolean;
7
+ tooltipClassName?: string;
7
8
  } & Omit<{
8
9
  x: number;
9
10
  y: number;
@@ -2,6 +2,8 @@ import React from 'react';
2
2
  import i18n from 'ui-i18n';
3
3
  import { getActivityType, splitActivityByType } from '../../../utils/activities';
4
4
  import { ActivitiesFactory } from '../../../ActivitiesFactory';
5
+ import { ErrorBoundary } from '../../../../../ErrorBoundary';
6
+ import { ActivityTitle } from '../../../ActivityTitle';
5
7
  import { useStyles } from './styles';
6
8
  export var ActivityItem = function (_a) {
7
9
  var item = _a.item;
@@ -14,8 +16,14 @@ export var ActivityItem = function (_a) {
14
16
  React.createElement("div", { className: styles.userContainer },
15
17
  React.createElement("span", { className: styles.activityUser }, item.user),
16
18
  React.createElement("span", { className: styles.date }, i18n.date(item.timestamp, 'LT'))),
17
- activities.map(function (activity, index) { return (React.createElement("div", { key: index, className: styles.activityEvent }, ActivitiesFactory.getComponent({
18
- type: getActivityType(activity),
19
- data: activity
20
- }))); }))));
19
+ activities.map(function (activity, index) {
20
+ var activityType = getActivityType(activity);
21
+ return (React.createElement("div", { key: index, className: styles.activityEvent },
22
+ React.createElement(ErrorBoundary, { error: React.createElement(React.Fragment, null,
23
+ React.createElement(ActivityTitle, { type: activityType }),
24
+ i18n.text("Can't render activity")) }, ActivitiesFactory.getComponent({
25
+ type: activityType,
26
+ data: activity
27
+ }))));
28
+ }))));
21
29
  };
@@ -4,6 +4,7 @@ export declare const HistoryCircleWithTooltip: React.ForwardRefExoticComponent<O
4
4
  tooltipTitle?: import("@mui/material").TooltipProps["title"];
5
5
  tooltipPlacement?: import("@mui/material").TooltipProps["placement"];
6
6
  showForDisabled?: boolean;
7
+ tooltipClassName?: string;
7
8
  } & Omit<{
8
9
  x: number;
9
10
  y: number;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@reltio/components",
3
- "version": "1.4.2217",
3
+ "version": "1.4.2219",
4
4
  "license": "SEE LICENSE IN LICENSE FILE",
5
5
  "main": "./cjs/index.js",
6
6
  "module": "./index.js",
@@ -11,7 +11,7 @@
11
11
  "@fluentui/react-context-selector": "^9.1.26",
12
12
  "@googlemaps/markerclusterer": "^2.5.3",
13
13
  "@react-sigma/core": "3.4.0",
14
- "@reltio/mdm-sdk": "^1.4.2016",
14
+ "@reltio/mdm-sdk": "^1.4.2017",
15
15
  "@vis.gl/react-google-maps": "^1.3.0",
16
16
  "d3-cloud": "^1.2.5",
17
17
  "d3-geo": "^2.0.1",