@salutejs/plasma-new-hope 0.340.0-canary.2314.19163733637.0 → 0.340.0-canary.2314.19170036078.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.
Files changed (48) hide show
  1. package/cjs/components/Combobox/ComboboxNew/Combobox.js +16 -14
  2. package/cjs/components/Combobox/ComboboxNew/Combobox.js.map +1 -1
  3. package/cjs/components/Combobox/ComboboxNew/reducers/treePathReducer.js +43 -17
  4. package/cjs/components/Combobox/ComboboxNew/reducers/treePathReducer.js.map +1 -1
  5. package/cjs/components/Combobox/ComboboxNew/utils/filterItems.js +4 -3
  6. package/cjs/components/Combobox/ComboboxNew/utils/filterItems.js.map +1 -1
  7. package/cjs/components/DatePicker/RangeDate/RangeDate.js +24 -4
  8. package/cjs/components/DatePicker/RangeDate/RangeDate.js.map +1 -1
  9. package/emotion/cjs/components/Combobox/ComboboxNew/Combobox.js +16 -13
  10. package/emotion/cjs/components/Combobox/ComboboxNew/reducers/treePathReducer.js +39 -17
  11. package/emotion/cjs/components/Combobox/ComboboxNew/utils/filterItems.js +14 -6
  12. package/emotion/cjs/components/Combobox/ComboboxNew/utils/index.js +3 -0
  13. package/emotion/cjs/components/DatePicker/RangeDate/RangeDate.js +21 -4
  14. package/emotion/cjs/examples/components/Combobox/Combobox.js +0 -15
  15. package/emotion/es/components/Combobox/ComboboxNew/Combobox.js +17 -14
  16. package/emotion/es/components/Combobox/ComboboxNew/reducers/treePathReducer.js +39 -17
  17. package/emotion/es/components/Combobox/ComboboxNew/utils/filterItems.js +3 -3
  18. package/emotion/es/components/Combobox/ComboboxNew/utils/index.js +1 -1
  19. package/emotion/es/components/DatePicker/RangeDate/RangeDate.js +21 -4
  20. package/emotion/es/examples/components/Combobox/Combobox.js +7 -0
  21. package/es/components/Combobox/ComboboxNew/Combobox.js +17 -15
  22. package/es/components/Combobox/ComboboxNew/Combobox.js.map +1 -1
  23. package/es/components/Combobox/ComboboxNew/reducers/treePathReducer.js +43 -17
  24. package/es/components/Combobox/ComboboxNew/reducers/treePathReducer.js.map +1 -1
  25. package/es/components/Combobox/ComboboxNew/utils/filterItems.js +4 -4
  26. package/es/components/Combobox/ComboboxNew/utils/filterItems.js.map +1 -1
  27. package/es/components/DatePicker/RangeDate/RangeDate.js +24 -4
  28. package/es/components/DatePicker/RangeDate/RangeDate.js.map +1 -1
  29. package/package.json +2 -2
  30. package/styled-components/cjs/components/Combobox/ComboboxNew/Combobox.js +16 -13
  31. package/styled-components/cjs/components/Combobox/ComboboxNew/reducers/treePathReducer.js +39 -17
  32. package/styled-components/cjs/components/Combobox/ComboboxNew/utils/filterItems.js +14 -6
  33. package/styled-components/cjs/components/Combobox/ComboboxNew/utils/index.js +3 -0
  34. package/styled-components/cjs/components/DatePicker/RangeDate/RangeDate.js +21 -4
  35. package/styled-components/cjs/examples/components/Combobox/Combobox.js +0 -15
  36. package/styled-components/es/components/Combobox/ComboboxNew/Combobox.js +17 -14
  37. package/styled-components/es/components/Combobox/ComboboxNew/reducers/treePathReducer.js +39 -17
  38. package/styled-components/es/components/Combobox/ComboboxNew/utils/filterItems.js +3 -3
  39. package/styled-components/es/components/Combobox/ComboboxNew/utils/index.js +1 -1
  40. package/styled-components/es/components/DatePicker/RangeDate/RangeDate.js +21 -4
  41. package/types/components/Combobox/ComboboxNew/Combobox.d.ts.map +1 -1
  42. package/types/components/Combobox/ComboboxNew/reducers/treePathReducer.d.ts +6 -2
  43. package/types/components/Combobox/ComboboxNew/reducers/treePathReducer.d.ts.map +1 -1
  44. package/types/components/Combobox/ComboboxNew/utils/filterItems.d.ts +1 -0
  45. package/types/components/Combobox/ComboboxNew/utils/filterItems.d.ts.map +1 -1
  46. package/types/components/Combobox/ComboboxNew/utils/index.d.ts +1 -1
  47. package/types/components/Combobox/ComboboxNew/utils/index.d.ts.map +1 -1
  48. package/types/components/DatePicker/RangeDate/RangeDate.d.ts.map +1 -1
@@ -2,9 +2,17 @@
2
2
  Object.defineProperty(exports, "__esModule", {
3
3
  value: true
4
4
  });
5
- Object.defineProperty(exports, "filterItems", {
6
- enumerable: true,
7
- get: function() {
5
+ function _export(target, all) {
6
+ for(var name in all)Object.defineProperty(target, name, {
7
+ enumerable: true,
8
+ get: Object.getOwnPropertyDescriptor(all, name).get
9
+ });
10
+ }
11
+ _export(exports, {
12
+ get defaultFilter () {
13
+ return defaultFilter;
14
+ },
15
+ get filterItems () {
8
16
  return filterItems;
9
17
  }
10
18
  });
@@ -62,9 +70,6 @@ function _object_spread_props(target, source) {
62
70
  }
63
71
  var filterItems = function(items, textValue, currentLabel, customFilter) {
64
72
  if (!textValue && !customFilter || textValue === currentLabel) return items;
65
- var defaultFilter = function(item, value) {
66
- return item.label.toLowerCase().includes(value.toLowerCase());
67
- };
68
73
  var filter = customFilter || defaultFilter;
69
74
  var dfs = function(items) {
70
75
  var newItems = [];
@@ -88,3 +93,6 @@ var filterItems = function(items, textValue, currentLabel, customFilter) {
88
93
  };
89
94
  return dfs(items);
90
95
  };
96
+ var defaultFilter = function(item, textValue) {
97
+ return item.label.toLowerCase().includes(textValue.toLowerCase());
98
+ };
@@ -9,6 +9,9 @@ function _export(target, all) {
9
9
  });
10
10
  }
11
11
  _export(exports, {
12
+ get defaultFilter () {
13
+ return _filterItems.defaultFilter;
14
+ },
12
15
  get filterItems () {
13
16
  return _filterItems.filterItems;
14
17
  },
@@ -19,6 +19,7 @@ _export(exports, {
19
19
  var _react = /*#__PURE__*/ _interop_require_wildcard(require("react"));
20
20
  var _classnames = /*#__PURE__*/ _interop_require_default(require("classnames"));
21
21
  var _utils = require("../../../utils");
22
+ var _datejs = require("../../../utils/datejs");
22
23
  var _dateHelper = require("../utils/dateHelper");
23
24
  var _useDatePicker = require("../hooks/useDatePicker");
24
25
  var _DatePickertokens = require("../DatePicker.tokens");
@@ -486,18 +487,34 @@ var datePickerRangeRoot = function(Root) {
486
487
  prevValue,
487
488
  chosenDate
488
489
  ]), 2), first = _getSortedValues[0], second = _getSortedValues[1];
489
- handleFirstCalendarPick(first, dateInfo);
490
- handleSecondCalendarPick(second, dateInfo);
490
+ /**
491
+ * NOTE: проверяем совпадает ли новая дата с предыдущей
492
+ * Если нет, то вызываем handle{First,Second}CalendarPick
493
+ */ _datejs.customDayjs.locale(lang);
494
+ var firstFormatted = first ? (0, _datejs.customDayjs)(first).format(format) : '';
495
+ var secondFormatted = second ? (0, _datejs.customDayjs)(second).format(format) : '';
496
+ if (firstFormatted !== inputFirstValue) {
497
+ handleFirstCalendarPick(first, dateInfo);
498
+ }
499
+ if (secondFormatted !== inputSecondValue) {
500
+ handleSecondCalendarPick(second, dateInfo);
501
+ }
491
502
  if (!firstValueError && !secondValueError && closeAfterDateSelect) {
492
503
  handleToggle(false);
493
504
  }
494
505
  };
495
506
  var handleChangeCalendarValue = function(param, dateInfo) {
496
507
  var _$_param = _sliced_to_array(param, 2), firstDate = _$_param[0], secondDate = _$_param[1];
497
- if (firstDate) {
508
+ /**
509
+ * NOTE: проверяем совпадает ли новая дата с предыдущей
510
+ * Если нет, то вызываем handle{First,Second}CalendarPick
511
+ */ _datejs.customDayjs.locale(lang);
512
+ var firstFormatted = firstDate ? (0, _datejs.customDayjs)(firstDate).format(format) : '';
513
+ var secondFormatted = secondDate ? (0, _datejs.customDayjs)(secondDate).format(format) : '';
514
+ if (firstFormatted !== inputFirstValue) {
498
515
  handleFirstCalendarPick(firstDate, dateInfo);
499
516
  }
500
- if (secondDate) {
517
+ if (secondFormatted !== inputSecondValue) {
501
518
  handleSecondCalendarPick(secondDate, dateInfo);
502
519
  }
503
520
  if (firstDate && secondDate && !firstValueError && !secondValueError && closeAfterDateSelect) {
@@ -1,16 +1 @@
1
1
  "use strict";
2
- Object.defineProperty(exports, "__esModule", {
3
- value: true
4
- });
5
- Object.defineProperty(exports, "Combobox", {
6
- enumerable: true,
7
- get: function() {
8
- return Combobox;
9
- }
10
- });
11
- var _engines = require("../../../engines");
12
- var _ = require("../../..");
13
- var _Comboboxconfig = require("./Combobox.config");
14
- var mergedConfig = (0, _engines.mergeConfig)(_.comboboxNewConfig, _Comboboxconfig.config);
15
- var ComboboxComponent = (0, _engines.component)(mergedConfig);
16
- var Combobox = ComboboxComponent;
@@ -135,7 +135,7 @@ import { sizeToIconSize } from "../../Select/utils";
135
135
  import { classes } from "./Combobox.tokens";
136
136
  import { FloatingPopover } from "./FloatingPopover";
137
137
  import { useKeyNavigation, getItemByFocused } from "./hooks/useKeyboardNavigation";
138
- import { initialItemsTransform, updateAncestors, updateDescendants, updateSingleAncestors, filterItems, getItemId, getTextValue } from "./utils";
138
+ import { initialItemsTransform, updateAncestors, updateDescendants, updateSingleAncestors, filterItems, getItemId, getTextValue, defaultFilter } from "./utils";
139
139
  import { Inner, StyledTextField, VirtualList, SelectAll, TreeList } from "./ui";
140
140
  import { pathReducer, focusedPathReducer, treePathReducer } from "./reducers";
141
141
  import { getPathMap, getTreeMaps } from "./hooks/getPathMaps";
@@ -221,12 +221,14 @@ import { Context } from "./Combobox.context";
221
221
  var inputForkRef = useForkRef(inputRef, ref);
222
222
  var listWrapperRef = useRef(null);
223
223
  var treeId = safeUseId();
224
+ var filterCb = filter || defaultFilter;
224
225
  var filteredItems = useMemo(function() {
225
226
  return filterItems(transformedItems, textValue, getTextValue(multiple, value, valueToItemMap, renderValue), filter);
226
227
  }, [
227
228
  transformedItems,
228
229
  textValue,
229
- filter
230
+ filter,
231
+ value
230
232
  ]);
231
233
  var _useMemo1 = _sliced_to_array(useMemo(function() {
232
234
  return getPathMap(filteredItems);
@@ -567,22 +569,23 @@ import { Context } from "./Combobox.context";
567
569
  // Эффект для раскрытия дерева при поиске.
568
570
  useLayoutEffect(function() {
569
571
  if (treeView) {
570
- // Если пользователь выбирает элемент, то выходим из эффекта.
571
- if (textValue === getTextValue(multiple, value, valueToItemMap, renderValue)) {
572
- return;
573
- }
574
- // Если поле ввода стало пустым, то скрывает все узлы дерева.
575
- if (textValue === '') {
572
+ // Если поле ввода стало пустым или если пользователь выбирает элемент,
573
+ // то скрываем все узлы дерева и выходим из эффекта.
574
+ if (textValue === '' || textValue === getTextValue(multiple, value, valueToItemMap, renderValue)) {
576
575
  dispatchTreePath({
577
576
  type: 'reset'
578
577
  });
579
- } else {
580
- // Иначе раскрываем все узлы, когда пользователь начинает вводить текст в поле ввода.
581
- dispatchTreePath({
582
- type: 'expand_all',
583
- value: filteredItems
584
- });
578
+ return;
585
579
  }
580
+ // Иначе раскрываем все узлы, когда пользователь начинает вводить текст в поле ввода.
581
+ dispatchTreePath({
582
+ type: 'expand_by_key',
583
+ value: {
584
+ filteredItems: filteredItems,
585
+ filterCb: filterCb,
586
+ textValue: textValue
587
+ }
588
+ });
586
589
  }
587
590
  }, [
588
591
  textValue
@@ -54,23 +54,44 @@ function removeObjectAtPath(obj, path) {
54
54
  }
55
55
  return obj;
56
56
  }
57
- // Утилита, которая получает на вход список отфильтрованных элементов
58
- // и возвращает объект путей раскрытых элементов дерева.
59
- function generateNestedTreePathFromFilteredItems(items) {
57
+ /**
58
+ * Утилита, которая получает на вход список отфильтрованных элементов и
59
+ * callback, с помощью которого эти элементы были отфильтрованы.
60
+ * Возвращает TreePathState, т.е. список раскрытых групп.
61
+ * По умолчанию группа не раскрывается, если в ней не было найдено ни одного элемента.
62
+ * Но т.к. поиск может осуществляться как по элементам, так и по группам,
63
+ * то может возникнуть ситуация, когда будет найдена как группа с определенным названием,
64
+ * так и элемент с таким же названием внутри нее, и в таком случае мы должны частично раскрыть группу,
65
+ * вплоть то найденного элемента.
66
+ * Если найдена только группа, без элементов внутри нее, то саму эту группу
67
+ * раскрывать не нужно. Нужно раскрыть только родителя этой группы.
68
+ */ function generateNestedTreePathFromFilteredItems(filteredItems, filterCb, textValue) {
60
69
  var result = {};
61
- var buildTree = function(currentItems, currentLevel) {
62
- if (!currentItems || !Array.isArray(currentItems)) return;
70
+ function traverse(items, currentPath) {
71
+ var hasFoundItems = false;
63
72
  var _iteratorNormalCompletion = true, _didIteratorError = false, _iteratorError = undefined;
64
73
  try {
65
- for(var _iterator = currentItems[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true){
74
+ for(var _iterator = items[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true){
66
75
  var item = _step.value;
67
- if ((item === null || item === void 0 ? void 0 : item.value) && (item === null || item === void 0 ? void 0 : item.items)) {
68
- // Создаем новый уровень для текущего значения
69
- currentLevel[item === null || item === void 0 ? void 0 : item.value] = {};
70
- // Рекурсивно обрабатываем дочерние элементы
71
- if ((item === null || item === void 0 ? void 0 : item.items) && (item === null || item === void 0 ? void 0 : item.items.length) > 0) {
72
- buildTree(item === null || item === void 0 ? void 0 : item.items, currentLevel[item === null || item === void 0 ? void 0 : item.value]);
76
+ var isFound = filterCb(item, textValue);
77
+ if (item.items && item.items.length > 0) {
78
+ // Обрабатываем детей
79
+ var childPath = {};
80
+ var foundInChildren = traverse(item.items, childPath);
81
+ if (foundInChildren) {
82
+ // Если в детях найдены элементы - добавляем путь
83
+ currentPath[item.value] = childPath;
84
+ hasFoundItems = true;
73
85
  }
86
+ // Если сама группа найдена, но в детях ничего нет - НЕ добавляем путь
87
+ // Просто отмечаем что что-то найдено на этом уровне
88
+ if (isFound && !foundInChildren) {
89
+ hasFoundItems = true;
90
+ }
91
+ } else if (isFound) {
92
+ // Для конечного элемента не добавляем путь в currentPath,
93
+ // но отмечаем что на этом уровне есть найденные элементы
94
+ hasFoundItems = true;
74
95
  }
75
96
  }
76
97
  } catch (err) {
@@ -87,8 +108,9 @@ function generateNestedTreePathFromFilteredItems(items) {
87
108
  }
88
109
  }
89
110
  }
90
- };
91
- buildTree(items, result);
111
+ return hasFoundItems;
112
+ }
113
+ traverse(filteredItems, result);
92
114
  return result;
93
115
  }
94
116
  export function treePathReducer(state, action) {
@@ -110,10 +132,10 @@ export function treePathReducer(state, action) {
110
132
  }
111
133
  return stateCopy;
112
134
  }
113
- case 'expand_all':
135
+ case 'expand_by_key':
114
136
  {
115
- var filteredItem = action.value;
116
- return generateNestedTreePathFromFilteredItems(filteredItem);
137
+ var _action_value = action.value, filteredItems = _action_value.filteredItems, filterCb = _action_value.filterCb, textValue = _action_value.textValue;
138
+ return generateNestedTreePathFromFilteredItems(filteredItems, filterCb, textValue);
117
139
  }
118
140
  case 'open_level':
119
141
  {
@@ -59,9 +59,6 @@ function _object_spread_props(target, source) {
59
59
  // Не мутирует исходные данные.
60
60
  export var filterItems = function(items, textValue, currentLabel, customFilter) {
61
61
  if (!textValue && !customFilter || textValue === currentLabel) return items;
62
- var defaultFilter = function(item, value) {
63
- return item.label.toLowerCase().includes(value.toLowerCase());
64
- };
65
62
  var filter = customFilter || defaultFilter;
66
63
  var dfs = function(items) {
67
64
  var newItems = [];
@@ -85,3 +82,6 @@ export var filterItems = function(items, textValue, currentLabel, customFilter)
85
82
  };
86
83
  return dfs(items);
87
84
  };
85
+ export var defaultFilter = function(item, textValue) {
86
+ return item.label.toLowerCase().includes(textValue.toLowerCase());
87
+ };
@@ -3,6 +3,6 @@ export { updateDescendants } from "./updateDescendants";
3
3
  export { updateAncestors } from "./updateAncestors";
4
4
  export { updateSingleAncestors } from "./updateSingleAncestors";
5
5
  export { sizeToIconSize } from "./sizeToIconSize";
6
- export { filterItems } from "./filterItems";
6
+ export { filterItems, defaultFilter } from "./filterItems";
7
7
  export { getItemId } from "./getItemId";
8
8
  export { getTextValue } from "./getTextValue";
@@ -126,6 +126,7 @@ function _unsupported_iterable_to_array(o, minLen) {
126
126
  import React, { createRef, forwardRef, useCallback, useEffect, useLayoutEffect, useRef, useState } from "react";
127
127
  import cls from "classnames";
128
128
  import { noop } from "../../../utils";
129
+ import { customDayjs } from "../../../utils/datejs";
129
130
  import { getDateFormatDelimiter } from "../utils/dateHelper";
130
131
  import { useDatePicker } from "../hooks/useDatePicker";
131
132
  import { classes } from "../DatePicker.tokens";
@@ -422,18 +423,34 @@ export var datePickerRangeRoot = function(Root) {
422
423
  prevValue,
423
424
  chosenDate
424
425
  ]), 2), first = _getSortedValues[0], second = _getSortedValues[1];
425
- handleFirstCalendarPick(first, dateInfo);
426
- handleSecondCalendarPick(second, dateInfo);
426
+ /**
427
+ * NOTE: проверяем совпадает ли новая дата с предыдущей
428
+ * Если нет, то вызываем handle{First,Second}CalendarPick
429
+ */ customDayjs.locale(lang);
430
+ var firstFormatted = first ? customDayjs(first).format(format) : '';
431
+ var secondFormatted = second ? customDayjs(second).format(format) : '';
432
+ if (firstFormatted !== inputFirstValue) {
433
+ handleFirstCalendarPick(first, dateInfo);
434
+ }
435
+ if (secondFormatted !== inputSecondValue) {
436
+ handleSecondCalendarPick(second, dateInfo);
437
+ }
427
438
  if (!firstValueError && !secondValueError && closeAfterDateSelect) {
428
439
  handleToggle(false);
429
440
  }
430
441
  };
431
442
  var handleChangeCalendarValue = function(param, dateInfo) {
432
443
  var _$_param = _sliced_to_array(param, 2), firstDate = _$_param[0], secondDate = _$_param[1];
433
- if (firstDate) {
444
+ /**
445
+ * NOTE: проверяем совпадает ли новая дата с предыдущей
446
+ * Если нет, то вызываем handle{First,Second}CalendarPick
447
+ */ customDayjs.locale(lang);
448
+ var firstFormatted = firstDate ? customDayjs(firstDate).format(format) : '';
449
+ var secondFormatted = secondDate ? customDayjs(secondDate).format(format) : '';
450
+ if (firstFormatted !== inputFirstValue) {
434
451
  handleFirstCalendarPick(firstDate, dateInfo);
435
452
  }
436
- if (secondDate) {
453
+ if (secondFormatted !== inputSecondValue) {
437
454
  handleSecondCalendarPick(secondDate, dateInfo);
438
455
  }
439
456
  if (firstDate && secondDate && !firstValueError && !secondValueError && closeAfterDateSelect) {
@@ -1 +1 @@
1
- {"version":3,"file":"Combobox.d.ts","sourceRoot":"","sources":["../../../../src/components/Combobox/ComboboxNew/Combobox.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA6E,MAAM,OAAO,CAAC;AAIlG,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AA6BxC,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AAOtD;;GAEG;AAEH,eAAO,MAAM,YAAY,SAAU,SAAS,CAAC,gBAAgB,EAAE,IAAI,CAAC,aAAa,EAAE,OAAO,GAAG,eAAe,CAAC,CAAC,2FA4nBxG,CAAC;AAEP,eAAO,MAAM,cAAc;;;mBA9nBQ,SAAS,CAAC,gBAAgB,EAAE,IAAI,CAAC,aAAa,EAAE,OAAO,GAAG,eAAe,CAAC,CAAC;;;;;;;;;;;;;;;;;;CAmpB7G,CAAC"}
1
+ {"version":3,"file":"Combobox.d.ts","sourceRoot":"","sources":["../../../../src/components/Combobox/ComboboxNew/Combobox.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA6E,MAAM,OAAO,CAAC;AAIlG,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AA8BxC,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AAOtD;;GAEG;AAEH,eAAO,MAAM,YAAY,SAAU,SAAS,CAAC,gBAAgB,EAAE,IAAI,CAAC,aAAa,EAAE,OAAO,GAAG,eAAe,CAAC,CAAC,2FA2nBxG,CAAC;AAEP,eAAO,MAAM,cAAc;;;mBA7nBQ,SAAS,CAAC,gBAAgB,EAAE,IAAI,CAAC,aAAa,EAAE,OAAO,GAAG,eAAe,CAAC,CAAC;;;;;;;;;;;;;;;;;;CAkpB7G,CAAC"}
@@ -9,8 +9,12 @@ export type TreePathAction = {
9
9
  type: 'toggled_level';
10
10
  value: string[];
11
11
  } | {
12
- type: 'expand_all';
13
- value: ItemOption[];
12
+ type: 'expand_by_key';
13
+ value: {
14
+ filteredItems: ItemOption[];
15
+ filterCb: (item: ItemOption, textValue: string) => boolean;
16
+ textValue: string;
17
+ };
14
18
  } | {
15
19
  type: 'open_level';
16
20
  value: string[];
@@ -1 +1 @@
1
- {"version":3,"file":"treePathReducer.d.ts","sourceRoot":"","sources":["../../../../../src/components/Combobox/ComboboxNew/reducers/treePathReducer.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAE/C,KAAK,cAAc,GAAG;IAClB,CAAC,GAAG,EAAE,MAAM,GAAG,EAAE,GAAG,cAAc,CAAC;CACtC,CAAC;AAEF,MAAM,MAAM,aAAa,GAAG,cAAc,CAAC;AAE3C,MAAM,MAAM,cAAc,GACpB;IAAE,IAAI,EAAE,OAAO,CAAA;CAAE,GACjB;IAAE,IAAI,EAAE,eAAe,CAAC;IAAC,KAAK,EAAE,MAAM,EAAE,CAAA;CAAE,GAC1C;IAAE,IAAI,EAAE,YAAY,CAAC;IAAC,KAAK,EAAE,UAAU,EAAE,CAAA;CAAE,GAC3C;IAAE,IAAI,EAAE,YAAY,CAAC;IAAC,KAAK,EAAE,MAAM,EAAE,CAAA;CAAE,GACvC;IAAE,IAAI,EAAE,aAAa,CAAC;IAAC,KAAK,EAAE,MAAM,EAAE,CAAA;CAAE,CAAC;AAG/C,eAAO,MAAM,SAAS,QAAS,cAAc,QAAQ,MAAM,EAAE,YAkB5D,CAAC;AA8EF,wBAAgB,eAAe,CAAC,KAAK,EAAE,aAAa,EAAE,MAAM,EAAE,cAAc,GAAG,aAAa,CAgD3F"}
1
+ {"version":3,"file":"treePathReducer.d.ts","sourceRoot":"","sources":["../../../../../src/components/Combobox/ComboboxNew/reducers/treePathReducer.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAE/C,KAAK,cAAc,GAAG;IAClB,CAAC,GAAG,EAAE,MAAM,GAAG,EAAE,GAAG,cAAc,CAAC;CACtC,CAAC;AAEF,MAAM,MAAM,aAAa,GAAG,cAAc,CAAC;AAE3C,MAAM,MAAM,cAAc,GACpB;IAAE,IAAI,EAAE,OAAO,CAAA;CAAE,GACjB;IAAE,IAAI,EAAE,eAAe,CAAC;IAAC,KAAK,EAAE,MAAM,EAAE,CAAA;CAAE,GAC1C;IACI,IAAI,EAAE,eAAe,CAAC;IACtB,KAAK,EAAE;QACH,aAAa,EAAE,UAAU,EAAE,CAAC;QAC5B,QAAQ,EAAE,CAAC,IAAI,EAAE,UAAU,EAAE,SAAS,EAAE,MAAM,KAAK,OAAO,CAAC;QAC3D,SAAS,EAAE,MAAM,CAAC;KACrB,CAAC;CACL,GACD;IAAE,IAAI,EAAE,YAAY,CAAC;IAAC,KAAK,EAAE,MAAM,EAAE,CAAA;CAAE,GACvC;IAAE,IAAI,EAAE,aAAa,CAAC;IAAC,KAAK,EAAE,MAAM,EAAE,CAAA;CAAE,CAAC;AAG/C,eAAO,MAAM,SAAS,QAAS,cAAc,QAAQ,MAAM,EAAE,YAkB5D,CAAC;AA4GF,wBAAgB,eAAe,CAAC,KAAK,EAAE,aAAa,EAAE,MAAM,EAAE,cAAc,GAAG,aAAa,CAgD3F"}
@@ -1,3 +1,4 @@
1
1
  import { ItemOptionTransformed, ItemOption } from '../ui/Inner/ui/Item/Item.types';
2
2
  export declare const filterItems: (items: Array<ItemOptionTransformed>, textValue: string, currentLabel: string, customFilter?: (item: ItemOption, value: string) => boolean) => Array<ItemOptionTransformed>;
3
+ export declare const defaultFilter: (item: ItemOption, textValue: string) => boolean;
3
4
  //# sourceMappingURL=filterItems.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"filterItems.d.ts","sourceRoot":"","sources":["../../../../../src/components/Combobox/ComboboxNew/utils/filterItems.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,qBAAqB,EAAE,UAAU,EAAE,MAAM,gCAAgC,CAAC;AASnF,eAAO,MAAM,WAAW,UACb,KAAK,CAAC,qBAAqB,CAAC,aACxB,MAAM,gBACH,MAAM,iBACL,CAAC,IAAI,EAAE,UAAU,EAAE,KAAK,EAAE,MAAM,KAAK,OAAO,KAC5D,KAAK,CAAC,qBAAqB,CA+B7B,CAAC"}
1
+ {"version":3,"file":"filterItems.d.ts","sourceRoot":"","sources":["../../../../../src/components/Combobox/ComboboxNew/utils/filterItems.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,qBAAqB,EAAE,UAAU,EAAE,MAAM,gCAAgC,CAAC;AASnF,eAAO,MAAM,WAAW,UACb,KAAK,CAAC,qBAAqB,CAAC,aACxB,MAAM,gBACH,MAAM,iBACL,CAAC,IAAI,EAAE,UAAU,EAAE,KAAK,EAAE,MAAM,KAAK,OAAO,KAC5D,KAAK,CAAC,qBAAqB,CA6B7B,CAAC;AAEF,eAAO,MAAM,aAAa,SAAU,UAAU,aAAa,MAAM,YACH,CAAC"}
@@ -3,7 +3,7 @@ export { updateDescendants } from './updateDescendants';
3
3
  export { updateAncestors } from './updateAncestors';
4
4
  export { updateSingleAncestors } from './updateSingleAncestors';
5
5
  export { sizeToIconSize } from './sizeToIconSize';
6
- export { filterItems } from './filterItems';
6
+ export { filterItems, defaultFilter } from './filterItems';
7
7
  export { getItemId } from './getItemId';
8
8
  export { getTextValue } from './getTextValue';
9
9
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/components/Combobox/ComboboxNew/utils/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,qBAAqB,EAAE,MAAM,yBAAyB,CAAC;AAChE,OAAO,EAAE,iBAAiB,EAAE,MAAM,qBAAqB,CAAC;AACxD,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AACpD,OAAO,EAAE,qBAAqB,EAAE,MAAM,yBAAyB,CAAC;AAChE,OAAO,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AAClD,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAC5C,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AACxC,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/components/Combobox/ComboboxNew/utils/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,qBAAqB,EAAE,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