@reltio/components 1.4.731 → 1.4.732

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,16 @@
1
+ "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ exports.ProfileBandNavigation = void 0;
7
+ var react_1 = __importDefault(require("react"));
8
+ var ProfileBandNavigationWidget_1 = require("./ProfileBandNavigationWidget");
9
+ var useSearchNavigation_1 = require("./hooks/useSearchNavigation");
10
+ var useSearchNavigationVisibility_1 = require("./hooks/useSearchNavigationVisibility");
11
+ var ProfileBandNavigation = function () {
12
+ var _a = useSearchNavigation_1.useSearchNavigation(), total = _a.total, onPrev = _a.onPrev, onNext = _a.onNext, onSearchResultsClick = _a.onSearchResultsClick, isPrevDisabled = _a.isPrevDisabled, isNextDisabled = _a.isNextDisabled;
13
+ var isVisible = useSearchNavigationVisibility_1.useSearchNavigationVisibility();
14
+ return isVisible ? (react_1.default.createElement(ProfileBandNavigationWidget_1.ProfileBandNavigationWidget, { total: total, onPrev: onPrev, onNext: onNext, onSearchResultsClick: onSearchResultsClick, isPrevDisabled: isPrevDisabled, isNextDisabled: isNextDisabled })) : null;
15
+ };
16
+ exports.ProfileBandNavigation = ProfileBandNavigation;
@@ -0,0 +1,29 @@
1
+ "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ exports.LinkWithTooltip = exports.ProfileBandNavigationWidget = void 0;
7
+ var react_1 = __importDefault(require("react"));
8
+ var ui_i18n_1 = __importDefault(require("ui-i18n"));
9
+ var Link_1 = __importDefault(require("@material-ui/core/Link"));
10
+ var HOCs_1 = require("../../HOCs");
11
+ var SmallIconButton_1 = require("../SmallIconButton");
12
+ var KeyboardArrowLeft_1 = __importDefault(require("@material-ui/icons/KeyboardArrowLeft"));
13
+ var KeyboardArrowRight_1 = __importDefault(require("@material-ui/icons/KeyboardArrowRight"));
14
+ var mdm_sdk_1 = require("@reltio/mdm-sdk");
15
+ var styles_1 = require("./styles");
16
+ var LinkWithTooltip = HOCs_1.withTooltip(Link_1.default);
17
+ exports.LinkWithTooltip = LinkWithTooltip;
18
+ var ProfileBandNavigationWidget = function (_a) {
19
+ var _b = _a.total, total = _b === void 0 ? 0 : _b, onPrev = _a.onPrev, onNext = _a.onNext, onSearchResultsClick = _a.onSearchResultsClick, isPrevDisabled = _a.isPrevDisabled, isNextDisabled = _a.isNextDisabled;
20
+ var styles = styles_1.useStyles();
21
+ return (react_1.default.createElement("div", { className: styles.container },
22
+ react_1.default.createElement(LinkWithTooltip, { className: styles.link, component: "button", variant: "caption", onClick: onSearchResultsClick, underline: "none", tooltipTitle: ui_i18n_1.default.text('Go to search results') },
23
+ mdm_sdk_1.formatNumberAsMetric(total, 1000000),
24
+ ' ',
25
+ total === 1 ? ui_i18n_1.default.text('Search result') : ui_i18n_1.default.text('Search results')),
26
+ react_1.default.createElement(SmallIconButton_1.SmallIconButtonWithTooltip, { size: "L", icon: KeyboardArrowLeft_1.default, tooltipTitle: ui_i18n_1.default.text('Go to previous profile'), onClick: onPrev, disabled: isPrevDisabled, showForDisabled: true }),
27
+ react_1.default.createElement(SmallIconButton_1.SmallIconButtonWithTooltip, { size: "L", icon: KeyboardArrowRight_1.default, tooltipTitle: ui_i18n_1.default.text('Go to next profile'), onClick: onNext, disabled: isNextDisabled, showForDisabled: true })));
28
+ };
29
+ exports.ProfileBandNavigationWidget = ProfileBandNavigationWidget;
@@ -0,0 +1,232 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
5
+ }) : (function(o, m, k, k2) {
6
+ if (k2 === undefined) k2 = k;
7
+ o[k2] = m[k];
8
+ }));
9
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
10
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
11
+ }) : function(o, v) {
12
+ o["default"] = v;
13
+ });
14
+ var __importStar = (this && this.__importStar) || function (mod) {
15
+ if (mod && mod.__esModule) return mod;
16
+ var result = {};
17
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
18
+ __setModuleDefault(result, mod);
19
+ return result;
20
+ };
21
+ var __spreadArray = (this && this.__spreadArray) || function (to, from) {
22
+ for (var i = 0, il = from.length, j = to.length; i < il; i++, j++)
23
+ to[j] = from[i];
24
+ return to;
25
+ };
26
+ Object.defineProperty(exports, "__esModule", { value: true });
27
+ exports.useSearchNavigation = exports.REQUEST_PAGE_SIZE = void 0;
28
+ var react_1 = require("react");
29
+ var react_redux_1 = require("react-redux");
30
+ var mdm_module_1 = __importStar(require("@reltio/mdm-module"));
31
+ var mdm_sdk_1 = require("@reltio/mdm-sdk");
32
+ var ramda_1 = require("ramda");
33
+ var contexts_1 = require("../../../contexts");
34
+ var hooks_1 = require("../../../hooks");
35
+ var SearchProviderFactory_1 = require("../searchProviders/SearchProviderFactory");
36
+ exports.REQUEST_PAGE_SIZE = 15;
37
+ var getNewUris = function (entities, cache) {
38
+ return ramda_1.pipe(ramda_1.map(ramda_1.prop('uri')), ramda_1.reject(function (uri) { return cache.includes(uri); }))(entities);
39
+ };
40
+ var useSearchNavigation = function () {
41
+ var safeCheckEntityPromise = hooks_1.useSafePromise();
42
+ var safeRequestTotalPromise = hooks_1.useSafePromise();
43
+ var safeRequestEntitiesPromise = hooks_1.useSafePromise();
44
+ var _a = react_redux_1.useSelector(mdm_module_1.default.selectors.getSearchNavigationData) || {}, uri = _a.uri, index = _a.index, total = _a.total, searchTenant = _a.tenant, cache = _a.cache;
45
+ var _b = react_redux_1.useSelector(mdm_module_1.default.selectors.getSearchProviderData) || {}, type = _b.type, data = _b.data;
46
+ var tenant = react_redux_1.useSelector(mdm_module_1.default.selectors.getTenant);
47
+ var apiPath = react_redux_1.useSelector(mdm_module_1.default.selectors.getApiPath);
48
+ var dtssPath = react_redux_1.useSelector(mdm_module_1.default.selectors.getDtssPath);
49
+ var globalSearchRequestOptions = react_redux_1.useSelector(function (state) {
50
+ return mdm_module_1.default.selectors.getGlobalSearchRequestOptions(state, ['ovOnly']);
51
+ });
52
+ var viewId = react_1.useContext(contexts_1.ViewIdContext);
53
+ var dispatch = react_redux_1.useDispatch();
54
+ var _c = react_1.useState(false), loading = _c[0], setLoading = _c[1];
55
+ var searchProvider = react_1.useMemo(function () { return SearchProviderFactory_1.getSearchProvider(type, { data: data, tenant: tenant, searchTenant: searchTenant, apiPath: apiPath, dtssPath: dtssPath, globalSearchRequestOptions: globalSearchRequestOptions }); }, [type, data, tenant, searchTenant, apiPath, dtssPath, globalSearchRequestOptions]);
56
+ var updateNavigationData = react_1.useCallback(function (data) {
57
+ dispatch(mdm_module_1.search.actions.updateSearchNavigationDataFields(data));
58
+ }, [dispatch]);
59
+ var openEntity = react_1.useCallback(function (uri) {
60
+ var preparedUri = tenant !== searchTenant ? mdm_sdk_1.getEntityUriForLink({ uri: uri, dataTenant: searchTenant }) : uri;
61
+ dispatch(mdm_module_1.ui.actions.openEntity({ uri: preparedUri, viewId: viewId, source: 'navigation' }));
62
+ }, [dispatch, viewId, tenant, searchTenant]);
63
+ var onSearchResultsClick = react_1.useCallback(function () {
64
+ dispatch(mdm_module_1.ui.actions.openPerspective({ perspectiveId: type, viewId: viewId }));
65
+ }, [dispatch, type, viewId]);
66
+ react_1.useEffect(function () {
67
+ if (index >= total) {
68
+ updateNavigationData({
69
+ index: total - 1
70
+ });
71
+ }
72
+ else if (index < 0) {
73
+ updateNavigationData({
74
+ index: 0
75
+ });
76
+ }
77
+ }, [total, index, updateNavigationData]);
78
+ var requestNextPage = react_1.useCallback(function (cache, total, index) {
79
+ setLoading(true);
80
+ safeRequestTotalPromise(searchProvider.requestTotal()).then(function (total) { return updateNavigationData({ total: total }); });
81
+ var newIndex = index + 1;
82
+ return safeRequestEntitiesPromise(searchProvider.requestEntities(exports.REQUEST_PAGE_SIZE, newIndex))
83
+ .then(function (entities) {
84
+ if (!entities) {
85
+ return;
86
+ }
87
+ if (entities.length) {
88
+ var newUris = getNewUris(entities, cache);
89
+ if (newUris.length > 0) {
90
+ updateNavigationData({
91
+ cache: cache.concat(newUris),
92
+ uri: newUris[0],
93
+ index: newIndex + entities.length - newUris.length
94
+ });
95
+ openEntity(newUris[0]);
96
+ return;
97
+ }
98
+ else if (index + entities.length < total - 1) {
99
+ return requestNextPage(cache, total - entities.length, index + entities.length);
100
+ }
101
+ }
102
+ updateNavigationData({
103
+ index: newIndex
104
+ });
105
+ })
106
+ .finally(function () {
107
+ setLoading(false);
108
+ });
109
+ }, [searchProvider, updateNavigationData, openEntity]);
110
+ var requestPrevPage = react_1.useCallback(function (cache, index) {
111
+ setLoading(true);
112
+ safeRequestTotalPromise(searchProvider.requestTotal()).then(function (total) { return updateNavigationData({ total: total }); });
113
+ var newIndex = index - 1;
114
+ var offset = Math.max(0, index - exports.REQUEST_PAGE_SIZE);
115
+ var max = exports.REQUEST_PAGE_SIZE + Math.min(0, index - exports.REQUEST_PAGE_SIZE);
116
+ return safeRequestEntitiesPromise(searchProvider.requestEntities(max, offset))
117
+ .then(function (entities) {
118
+ if (!entities) {
119
+ return;
120
+ }
121
+ if (entities.length) {
122
+ var newUris = getNewUris(entities, cache);
123
+ if (newUris.length > 0) {
124
+ updateNavigationData({
125
+ cache: newUris.concat(cache),
126
+ uri: newUris[newUris.length - 1],
127
+ index: newIndex - (entities.length - newUris.length)
128
+ });
129
+ openEntity(newUris[newUris.length - 1]);
130
+ return;
131
+ }
132
+ else if (index - entities.length > 0) {
133
+ return requestPrevPage(cache, index - entities.length);
134
+ }
135
+ }
136
+ updateNavigationData({
137
+ index: 0
138
+ });
139
+ })
140
+ .finally(function () {
141
+ setLoading(false);
142
+ });
143
+ }, [searchProvider, updateNavigationData, openEntity]);
144
+ var stepForwardWithCheck = react_1.useCallback(function (cache, cacheIndex, total, index) {
145
+ if (cacheIndex < cache.length) {
146
+ var uri_1 = cache[cacheIndex];
147
+ setLoading(true);
148
+ return safeCheckEntityPromise(searchProvider.checkEntity(uri_1))
149
+ .then(function (isExists) {
150
+ if (isExists) {
151
+ updateNavigationData({
152
+ index: index + 1,
153
+ uri: uri_1,
154
+ cache: cache,
155
+ total: total
156
+ });
157
+ openEntity(uri_1);
158
+ }
159
+ else {
160
+ var clearedCache = __spreadArray([], cache);
161
+ clearedCache.splice(cacheIndex, 1);
162
+ return stepForwardWithCheck(clearedCache, cacheIndex, total - 1, index);
163
+ }
164
+ })
165
+ .finally(function () {
166
+ setLoading(false);
167
+ });
168
+ }
169
+ else if (index >= total - 1) {
170
+ updateNavigationData({
171
+ cache: cache,
172
+ total: total,
173
+ index: total - 1
174
+ });
175
+ }
176
+ else {
177
+ return requestNextPage(cache, total, index);
178
+ }
179
+ }, [searchProvider, updateNavigationData, openEntity, requestNextPage]);
180
+ var stepBackWithCheck = react_1.useCallback(function (cache, cacheIndex, total, index) {
181
+ if (cacheIndex > -1) {
182
+ var uri_2 = cache[cacheIndex];
183
+ setLoading(true);
184
+ return safeCheckEntityPromise(searchProvider.checkEntity(uri_2))
185
+ .then(function (isExists) {
186
+ if (isExists) {
187
+ updateNavigationData({
188
+ index: index - 1,
189
+ uri: uri_2,
190
+ cache: cache,
191
+ total: total
192
+ });
193
+ openEntity(uri_2);
194
+ }
195
+ else {
196
+ var clearedCache = __spreadArray([], cache);
197
+ clearedCache.splice(cacheIndex, 1);
198
+ return stepBackWithCheck(clearedCache, cacheIndex - 1, total - 1, index - 1);
199
+ }
200
+ })
201
+ .finally(function () {
202
+ setLoading(false);
203
+ });
204
+ }
205
+ else if (index <= 0) {
206
+ updateNavigationData({
207
+ index: 0,
208
+ cache: cache,
209
+ total: total
210
+ });
211
+ }
212
+ else {
213
+ return requestPrevPage(cache, index);
214
+ }
215
+ }, [searchProvider, updateNavigationData, openEntity, requestPrevPage]);
216
+ var onPrev = react_1.useCallback(function () {
217
+ if (cache && uri) {
218
+ var cacheIndex = cache.indexOf(uri) - 1;
219
+ stepBackWithCheck(cache, cacheIndex, total, index);
220
+ }
221
+ }, [stepBackWithCheck, cache, uri, total, index]);
222
+ var onNext = react_1.useCallback(function () {
223
+ if (cache && uri) {
224
+ var cacheIndex = cache.indexOf(uri) + 1;
225
+ stepForwardWithCheck(cache, cacheIndex, total, index);
226
+ }
227
+ }, [stepForwardWithCheck, cache, uri, total, index]);
228
+ var isPrevDisabled = loading || index <= 0;
229
+ var isNextDisabled = loading || index >= total - 1;
230
+ return { total: total, onPrev: onPrev, onNext: onNext, onSearchResultsClick: onSearchResultsClick, isPrevDisabled: isPrevDisabled, isNextDisabled: isNextDisabled };
231
+ };
232
+ exports.useSearchNavigation = useSearchNavigation;
@@ -0,0 +1,16 @@
1
+ "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ exports.useSearchNavigationVisibility = void 0;
7
+ var react_redux_1 = require("react-redux");
8
+ var mdm_module_1 = __importDefault(require("@reltio/mdm-module"));
9
+ var mdm_sdk_1 = require("@reltio/mdm-sdk");
10
+ var useSearchNavigationVisibility = function () {
11
+ var cache = (react_redux_1.useSelector(mdm_module_1.default.selectors.getSearchNavigationData) || {}).cache;
12
+ var mode = react_redux_1.useSelector(mdm_module_1.default.selectors.getMode);
13
+ var entity = react_redux_1.useSelector(mdm_module_1.default.selectors.getEntity);
14
+ return mdm_sdk_1.isViewMode(mode) && (cache === null || cache === void 0 ? void 0 : cache.includes(entity === null || entity === void 0 ? void 0 : entity.uri));
15
+ };
16
+ exports.useSearchNavigationVisibility = useSearchNavigationVisibility;
@@ -0,0 +1,5 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.ProfileBandNavigation = void 0;
4
+ var ProfileBandNavigation_1 = require("./ProfileBandNavigation");
5
+ Object.defineProperty(exports, "ProfileBandNavigation", { enumerable: true, get: function () { return ProfileBandNavigation_1.ProfileBandNavigation; } });
@@ -0,0 +1,67 @@
1
+ "use strict";
2
+ var __assign = (this && this.__assign) || function () {
3
+ __assign = Object.assign || function(t) {
4
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
5
+ s = arguments[i];
6
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
7
+ t[p] = s[p];
8
+ }
9
+ return t;
10
+ };
11
+ return __assign.apply(this, arguments);
12
+ };
13
+ var __spreadArray = (this && this.__spreadArray) || function (to, from) {
14
+ for (var i = 0, il = from.length, j = to.length; i < il; i++, j++)
15
+ to[j] = from[i];
16
+ return to;
17
+ };
18
+ Object.defineProperty(exports, "__esModule", { value: true });
19
+ exports.GraphSearchProvider = void 0;
20
+ var mdm_sdk_1 = require("@reltio/mdm-sdk");
21
+ var GraphSearchProvider = /** @class */ (function () {
22
+ function GraphSearchProvider(_a) {
23
+ var _this = this;
24
+ var data = _a.data, tenant = _a.tenant, apiPath = _a.apiPath;
25
+ this.getEntities = function (filters, options) {
26
+ if (filters === void 0) { filters = []; }
27
+ if (options === void 0) { options = {}; }
28
+ var allFilters = __spreadArray([
29
+ {
30
+ rawFilter: _this.searchBody.filter
31
+ }
32
+ ], filters);
33
+ return mdm_sdk_1.getGraphSearchEntities({
34
+ apiPath: _this.apiPath,
35
+ tenant: _this.tenant,
36
+ searchBody: __assign(__assign({}, _this.searchBody), { filter: filters.length ? mdm_sdk_1.buildFilterQueryString()(allFilters) : _this.searchBody.filter }),
37
+ options: options
38
+ });
39
+ };
40
+ this.checkEntity = function (uri) {
41
+ return _this.getEntities([
42
+ {
43
+ filter: 'equals',
44
+ fieldName: 'id',
45
+ values: [mdm_sdk_1.getEntityId({ uri: uri })]
46
+ }
47
+ ], { from: 0, max: 1 }).then(function (entities) {
48
+ return entities && entities.length > 0 && entities[0].uri === uri;
49
+ });
50
+ };
51
+ this.requestEntities = function (max, from) {
52
+ return _this.getEntities([], { from: from, max: max });
53
+ };
54
+ this.requestTotal = function () {
55
+ return mdm_sdk_1.getGraphSearchCount({
56
+ apiPath: _this.apiPath,
57
+ tenant: _this.tenant,
58
+ searchBody: _this.searchBody
59
+ }).then(function (json) { return json.count; });
60
+ };
61
+ this.searchBody = data;
62
+ this.tenant = tenant;
63
+ this.apiPath = apiPath;
64
+ }
65
+ return GraphSearchProvider;
66
+ }());
67
+ exports.GraphSearchProvider = GraphSearchProvider;
@@ -0,0 +1,80 @@
1
+ "use strict";
2
+ var __assign = (this && this.__assign) || function () {
3
+ __assign = Object.assign || function(t) {
4
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
5
+ s = arguments[i];
6
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
7
+ t[p] = s[p];
8
+ }
9
+ return t;
10
+ };
11
+ return __assign.apply(this, arguments);
12
+ };
13
+ var __spreadArray = (this && this.__spreadArray) || function (to, from) {
14
+ for (var i = 0, il = from.length, j = to.length; i < il; i++, j++)
15
+ to[j] = from[i];
16
+ return to;
17
+ };
18
+ Object.defineProperty(exports, "__esModule", { value: true });
19
+ exports.MainSearchProvider = void 0;
20
+ var mdm_sdk_1 = require("@reltio/mdm-sdk");
21
+ var MainSearchProvider = /** @class */ (function () {
22
+ function MainSearchProvider(_a) {
23
+ var _this = this;
24
+ var _b = _a.data, query = _b.query, sortField = _b.sortField, sortOrder = _b.sortOrder, tenant = _a.tenant, searchTenant = _a.searchTenant, apiPath = _a.apiPath, dtssPath = _a.dtssPath, globalSearchRequestOptions = _a.globalSearchRequestOptions;
25
+ this.isDT = function () { return _this.tenant !== _this.searchTenant; };
26
+ this.getQueryFilter = function () { return ({ rawFilter: _this.query }); };
27
+ this.getEntities = function (filters, options) {
28
+ if (filters === void 0) { filters = []; }
29
+ if (options === void 0) { options = {}; }
30
+ var requestFilters = __spreadArray([_this.getQueryFilter()], filters);
31
+ var requestOptions = __assign(__assign(__assign({}, _this.globalSearchRequestOptions), { sort: _this.sortField, order: _this.sortOrder, select: 'uri,label,type', scoreEnabled: false }), options);
32
+ return _this.isDT()
33
+ ? mdm_sdk_1.getFilteredEntitiesFromDataTenant({
34
+ filters: requestFilters,
35
+ options: requestOptions,
36
+ customerTenant: _this.tenant,
37
+ dataTenant: _this.searchTenant,
38
+ dtssPath: _this.dtssPath
39
+ })
40
+ : mdm_sdk_1.getFilteredEntities(requestFilters, requestOptions);
41
+ };
42
+ this.checkEntity = function (uri) {
43
+ return _this.getEntities([
44
+ {
45
+ filter: 'equals',
46
+ fieldName: 'uri',
47
+ values: [uri]
48
+ }
49
+ ], { offset: 0, max: 1 }).then(function (entities) {
50
+ return entities && entities.length > 0 && entities[0].uri === uri;
51
+ });
52
+ };
53
+ this.requestEntities = function (max, offset) {
54
+ return _this.getEntities([], { offset: offset, max: max });
55
+ };
56
+ this.requestTotal = function () {
57
+ var filters = [_this.getQueryFilter()];
58
+ var options = _this.globalSearchRequestOptions;
59
+ return (_this.isDT()
60
+ ? mdm_sdk_1.getTotalFromDataTenant({
61
+ filters: filters,
62
+ options: options,
63
+ customerTenant: _this.tenant,
64
+ dataTenant: _this.searchTenant,
65
+ dtssPath: _this.dtssPath
66
+ })
67
+ : mdm_sdk_1.getTotals(filters, options)).then(function (json) { return json.total; });
68
+ };
69
+ this.query = query;
70
+ this.sortField = sortField;
71
+ this.sortOrder = sortOrder;
72
+ this.tenant = tenant;
73
+ this.searchTenant = searchTenant;
74
+ this.apiPath = apiPath;
75
+ this.dtssPath = dtssPath;
76
+ this.globalSearchRequestOptions = globalSearchRequestOptions;
77
+ }
78
+ return MainSearchProvider;
79
+ }());
80
+ exports.MainSearchProvider = MainSearchProvider;
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,14 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.getSearchProvider = void 0;
4
+ var MainSearchProvider_1 = require("./MainSearchProvider");
5
+ var GraphSearchProvider_1 = require("./GraphSearchProvider");
6
+ var getSearchProvider = function (type, options) {
7
+ switch (type) {
8
+ case 'search':
9
+ return new MainSearchProvider_1.MainSearchProvider(options);
10
+ case 'graphsearch':
11
+ return new GraphSearchProvider_1.GraphSearchProvider(options);
12
+ }
13
+ };
14
+ exports.getSearchProvider = getSearchProvider;
@@ -0,0 +1,14 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.useStyles = void 0;
4
+ var styles_1 = require("@material-ui/core/styles");
5
+ exports.useStyles = styles_1.makeStyles({
6
+ container: {
7
+ display: 'flex',
8
+ alignItems: 'center'
9
+ },
10
+ link: {
11
+ whiteSpace: 'nowrap',
12
+ marginRight: '9px'
13
+ }
14
+ });
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -13,9 +13,9 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
13
13
  return (mod && mod.__esModule) ? mod : { "default": mod };
14
14
  };
15
15
  Object.defineProperty(exports, "__esModule", { value: true });
16
- exports.ErrorBoundary = exports.EntityUriLink = exports.EntityTypesSelector = exports.EntityTypeIcon = exports.EntityTypeBadge = exports.EntityAvatar = exports.EMPTY_STATE_VARIANTS = exports.EMPTY_STATE_ICONS = exports.EmptyState = exports.NoResults = exports.NoData = exports.DropDownSelector = exports.DropDownMenuButton = exports.Drawer = exports.DataTypeValue = exports.ConnectionRelationTypeSelector = exports.ConfigureColumnsPopup = exports.MenuWithPopper = exports.DropdownIndicatorWithIconButton = exports.DropdownIndicator = exports.CommentsContainer = exports.ColorBar = exports.CollapseButton = exports.CollaborationItem = exports.ClickAwayProvider = exports.BasicViewHeader = exports.BasicViewContent = exports.BasicView = exports.AvatarWithFallback = exports.AutoSizeList = exports.ReadOnlyAttributesPager = exports.SimpleAttribute = exports.ReferenceAttribute = exports.NestedAttribute = exports.ImageAttributesLine = exports.ReadOnlyAttributesList = exports.ReadOnlyAttributeValuesBlock = exports.ReadOnlyAttribute = exports.AttributesPager = exports.SimpleAttributeEditor = exports.RelationTypeSelector = exports.ReferenceAttributeEditor = exports.NestedAttributeEditor = exports.MoreAttributesButton = exports.EntitySelector = exports.EntityCreator = exports.AttributesList = exports.BranchDecorator = exports.AttributesView = exports.AttributeListItem = void 0;
17
- exports.SourceIcon = exports.SmallIconButtonWithTooltip = exports.SmallIconButton = exports.SimpleDropDownSelector = exports.SidePanelContentHeader = exports.SidePanel = exports.SideButtonsPanel = exports.SelectorWithOnlyOptionAutoSelect = exports.SelectionPopupPopper = exports.SelectionPopup = exports.useKeyboardNavigation = exports.WhiteSearchInput = exports.SearchInput = exports.ScoreLabel = exports.Score = exports.ResizablePanes = exports.ReltioGridLayout = exports.ReactSortableTreeUtils = exports.ReactSortableTreeHandlers = exports.ReactSortableTree = exports.ReactSelectOptionFilters = exports.MultiSelect = exports.QueryBuilderRowsGroup = exports.QueryBuilderRow = exports.ProfileCard = exports.ProfileBand = exports.PotentialMatchReviewCard = exports.PopupWithArrow = exports.Popper = exports.MultipleInput = exports.ModeSwitcherSelect = exports.ModeSwitcher = exports.TransitiveMatchBlock = exports.SimpleMatchRulesBuilder = exports.SimpleMatchRulesBlock = exports.MatchRulesBlock = exports.LoadingSpinner = exports.Link = exports.LinearLoadIndicator = exports.ImportModes = exports.ImportButton = exports.ImageGalleryDialog = exports.Highlighter = exports.HierarchicalAttributeTooltip = exports.HideOnShrink = exports.FlipCard = exports.FacetViewHeader = exports.ExpandedValueTooltip = exports.ErrorWrapper = exports.ErrorPopup = void 0;
18
- exports.ConfirmationDialog = exports.Marginator = exports.LightArrowTooltip = exports.ArrowExpandButton = exports.ScrollableTabs = exports.ExpandableSearchInput = exports.VirtualGroupedList = exports.ViewMoreToggle = exports.VerticalHeadingsTable = exports.VerticalDivider = exports.AttributeTitle = exports.Spacer = void 0;
16
+ exports.EntityUriLink = exports.EntityTypesSelector = exports.EntityTypeIcon = exports.EntityTypeBadge = exports.EntityAvatar = exports.EMPTY_STATE_VARIANTS = exports.EMPTY_STATE_ICONS = exports.EmptyState = exports.NoResults = exports.NoData = exports.DropDownSelector = exports.DropDownMenuButton = exports.Drawer = exports.DataTypeValue = exports.ConnectionRelationTypeSelector = exports.ConfigureColumnsPopup = exports.MenuWithPopper = exports.DropdownIndicatorWithIconButton = exports.DropdownIndicator = exports.CommentsContainer = exports.ColorBar = exports.CollapseButton = exports.CollaborationItem = exports.ClickAwayProvider = exports.BasicViewHeader = exports.BasicViewContent = exports.BasicView = exports.ProfileBandNavigation = exports.AvatarWithFallback = exports.AutoSizeList = exports.ReadOnlyAttributesPager = exports.SimpleAttribute = exports.ReferenceAttribute = exports.NestedAttribute = exports.ImageAttributesLine = exports.ReadOnlyAttributesList = exports.ReadOnlyAttributeValuesBlock = exports.ReadOnlyAttribute = exports.AttributesPager = exports.SimpleAttributeEditor = exports.RelationTypeSelector = exports.ReferenceAttributeEditor = exports.NestedAttributeEditor = exports.MoreAttributesButton = exports.EntitySelector = exports.EntityCreator = exports.AttributesList = exports.BranchDecorator = exports.AttributesView = exports.AttributeListItem = void 0;
17
+ exports.SmallIconButtonWithTooltip = exports.SmallIconButton = exports.SimpleDropDownSelector = exports.SidePanelContentHeader = exports.SidePanel = exports.SideButtonsPanel = exports.SelectorWithOnlyOptionAutoSelect = exports.SelectionPopupPopper = exports.SelectionPopup = exports.useKeyboardNavigation = exports.WhiteSearchInput = exports.SearchInput = exports.ScoreLabel = exports.Score = exports.ResizablePanes = exports.ReltioGridLayout = exports.ReactSortableTreeUtils = exports.ReactSortableTreeHandlers = exports.ReactSortableTree = exports.ReactSelectOptionFilters = exports.MultiSelect = exports.QueryBuilderRowsGroup = exports.QueryBuilderRow = exports.ProfileCard = exports.ProfileBand = exports.PotentialMatchReviewCard = exports.PopupWithArrow = exports.Popper = exports.MultipleInput = exports.ModeSwitcherSelect = exports.ModeSwitcher = exports.TransitiveMatchBlock = exports.SimpleMatchRulesBuilder = exports.SimpleMatchRulesBlock = exports.MatchRulesBlock = exports.LoadingSpinner = exports.Link = exports.LinearLoadIndicator = exports.ImportModes = exports.ImportButton = exports.ImageGalleryDialog = exports.Highlighter = exports.HierarchicalAttributeTooltip = exports.HideOnShrink = exports.FlipCard = exports.FacetViewHeader = exports.ExpandedValueTooltip = exports.ErrorWrapper = exports.ErrorPopup = exports.ErrorBoundary = void 0;
18
+ exports.ConfirmationDialog = exports.Marginator = exports.LightArrowTooltip = exports.ArrowExpandButton = exports.ScrollableTabs = exports.ExpandableSearchInput = exports.VirtualGroupedList = exports.ViewMoreToggle = exports.VerticalHeadingsTable = exports.VerticalDivider = exports.AttributeTitle = exports.Spacer = exports.SourceIcon = void 0;
19
19
  __exportStar(require("./activityLog"), exports);
20
20
  var AttributeListItem_1 = require("./AttributeListItem/AttributeListItem");
21
21
  Object.defineProperty(exports, "AttributeListItem", { enumerable: true, get: function () { return __importDefault(AttributeListItem_1).default; } });
@@ -62,6 +62,8 @@ Object.defineProperty(exports, "AutoSizeList", { enumerable: true, get: function
62
62
  var AvatarWithFallback_1 = require("./AvatarWithFallback/AvatarWithFallback");
63
63
  Object.defineProperty(exports, "AvatarWithFallback", { enumerable: true, get: function () { return __importDefault(AvatarWithFallback_1).default; } });
64
64
  __exportStar(require("./BasicTableView"), exports);
65
+ var ProfileBandNavigation_1 = require("./ProfileBandNavigation");
66
+ Object.defineProperty(exports, "ProfileBandNavigation", { enumerable: true, get: function () { return ProfileBandNavigation_1.ProfileBandNavigation; } });
65
67
  var BasicView_1 = require("./BasicView/BasicView");
66
68
  Object.defineProperty(exports, "BasicView", { enumerable: true, get: function () { return __importDefault(BasicView_1).default; } });
67
69
  var BasicViewContent_1 = require("./BasicViewContent/BasicViewContent");
package/package.json CHANGED
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "name": "@reltio/components",
3
- "version": "1.4.731",
3
+ "version": "1.4.732",
4
4
  "license": "SEE LICENSE IN LICENSE FILE",
5
5
  "main": "index.js",
6
6
  "dependencies": {
7
7
  "@date-io/moment": "^1.3.5",
8
- "@reltio/mdm-module": "^1.4.731",
9
- "@reltio/mdm-sdk": "^1.4.731",
8
+ "@reltio/mdm-module": "^1.4.732",
9
+ "@reltio/mdm-sdk": "^1.4.732",
10
10
  "classnames": "^2.2.5",
11
11
  "frontend-collective-react-dnd-scrollzone": "^1.0.2",
12
12
  "nanoid": "^2.0.0",