@yoobic/yobi 8.5.0-64 → 8.5.0-66

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 (65) hide show
  1. package/dist/cjs/design-system.cjs.js +1 -1
  2. package/dist/cjs/{grid-renderers-6afebea7.js → grid-renderers-df979c2c.js} +4 -15
  3. package/dist/cjs/loader.cjs.js +1 -1
  4. package/dist/cjs/{missions-helpers-a4e1a383.js → missions-helpers-cb88152f.js} +27 -23
  5. package/dist/cjs/yoo-ag-grid.cjs.entry.js +2 -2
  6. package/dist/cjs/yoo-announcement-heading.cjs.entry.js +1 -1
  7. package/dist/cjs/yoo-chart.cjs.entry.js +1814 -1807
  8. package/dist/cjs/yoo-entity-query-builder.cjs.entry.js +5 -10
  9. package/dist/cjs/yoo-entity.cjs.entry.js +1 -1
  10. package/dist/cjs/yoo-form-autocomplete-dialog.cjs.entry.js +1 -0
  11. package/dist/cjs/yoo-form-autocomplete.cjs.entry.js +7 -7
  12. package/dist/cjs/yoo-form-input.cjs.entry.js +2 -2
  13. package/dist/cjs/yoo-grid.cjs.entry.js +14 -31
  14. package/dist/cjs/yoo-mission-details.cjs.entry.js +1 -1
  15. package/dist/cjs/yoo-mission-heading.cjs.entry.js +1 -1
  16. package/dist/cjs/yoo-pivot-table.cjs.entry.js +2 -2
  17. package/dist/collection/components/entities/entity-query-builder/entity-query-builder.js +5 -10
  18. package/dist/collection/components/form/form-autocomplete/form-autocomplete.js +9 -9
  19. package/dist/collection/components/form/form-autocomplete-dialog/form-autocomplete-dialog.js +11 -5
  20. package/dist/collection/components/grid/ag-grid/grid-renderers.js +4 -15
  21. package/dist/collection/components/grid/grid/grid.js +22 -34
  22. package/dist/collection/feature-operate/mission/helpers/missions-helpers.js +26 -23
  23. package/dist/collection/feature-platform/insight/chart/highcharts/index.js +0 -4
  24. package/dist/collection/interfaces/ui/index.js +0 -1
  25. package/dist/design-system/design-system.esm.js +1 -1
  26. package/dist/{esm/grid-renderers-eea95bb8.js → design-system/grid-renderers-63114b98.js} +4 -15
  27. package/dist/design-system/{missions-helpers-2903cdac.js → missions-helpers-1863d0d4.js} +27 -24
  28. package/dist/design-system/yoo-ag-grid.entry.js +2 -2
  29. package/dist/design-system/yoo-announcement-heading.entry.js +1 -1
  30. package/dist/design-system/yoo-chart.entry.js +1814 -1807
  31. package/dist/design-system/yoo-entity-query-builder.entry.js +5 -10
  32. package/dist/design-system/yoo-entity.entry.js +1 -1
  33. package/dist/design-system/yoo-form-autocomplete-dialog.entry.js +1 -0
  34. package/dist/design-system/yoo-form-autocomplete.entry.js +8 -8
  35. package/dist/design-system/yoo-form-input.entry.js +2 -2
  36. package/dist/design-system/yoo-grid.entry.js +15 -32
  37. package/dist/design-system/yoo-mission-details.entry.js +1 -1
  38. package/dist/design-system/yoo-mission-heading.entry.js +1 -1
  39. package/dist/design-system/yoo-pivot-table.entry.js +2 -2
  40. package/dist/esm/design-system.js +1 -1
  41. package/dist/{design-system/grid-renderers-eea95bb8.js → esm/grid-renderers-63114b98.js} +4 -15
  42. package/dist/esm/loader.js +1 -1
  43. package/dist/esm/{missions-helpers-2903cdac.js → missions-helpers-1863d0d4.js} +27 -24
  44. package/dist/esm/yoo-ag-grid.entry.js +2 -2
  45. package/dist/esm/yoo-announcement-heading.entry.js +1 -1
  46. package/dist/esm/yoo-chart.entry.js +1814 -1807
  47. package/dist/esm/yoo-entity-query-builder.entry.js +5 -10
  48. package/dist/esm/yoo-entity.entry.js +1 -1
  49. package/dist/esm/yoo-form-autocomplete-dialog.entry.js +1 -0
  50. package/dist/esm/yoo-form-autocomplete.entry.js +8 -8
  51. package/dist/esm/yoo-form-input.entry.js +2 -2
  52. package/dist/esm/yoo-grid.entry.js +15 -32
  53. package/dist/esm/yoo-mission-details.entry.js +1 -1
  54. package/dist/esm/yoo-mission-heading.entry.js +1 -1
  55. package/dist/esm/yoo-pivot-table.entry.js +2 -2
  56. package/dist/types/components/form/form-autocomplete/form-autocomplete.d.ts +1 -1
  57. package/dist/types/components/form/form-autocomplete-dialog/form-autocomplete-dialog.d.ts +1 -1
  58. package/dist/types/components/form/image-cropper-dialog/pintura/pintura.d.ts +1236 -0
  59. package/dist/types/components/grid/grid/grid.d.ts +2 -3
  60. package/dist/types/components.d.ts +4 -4
  61. package/dist/types/feature-operate/mission/helpers/missions-helpers.d.ts +1 -0
  62. package/dist/types/interfaces/ui/index.d.ts +0 -1
  63. package/package.json +1 -1
  64. package/dist/collection/interfaces/ui/form-filter.interface.js +0 -1
  65. package/dist/types/interfaces/ui/form-filter.interface.d.ts +0 -5
@@ -101,14 +101,8 @@ const YooEntityQueryBuilderComponent = class {
101
101
  return ((_b = (_a = this.values) === null || _a === void 0 ? void 0 : _a.filters) === null || _b === void 0 ? void 0 : _b.length) > 0 || ((_d = (_c = this.values) === null || _c === void 0 ? void 0 : _c.advancedFilters) === null || _d === void 0 ? void 0 : _d.length) > 0;
102
102
  }
103
103
  getActiveFiltersCount() {
104
- var _a, _b, _c, _d;
105
- if (((_b = (_a = this.values) === null || _a === void 0 ? void 0 : _a.advancedFilters) === null || _b === void 0 ? void 0 : _b.length) > 0) {
106
- return sum(this.values.advancedFilters.map((f) => (f === null || f === void 0 ? void 0 : f.length) || 0));
107
- }
108
- else if (((_d = (_c = this.values) === null || _c === void 0 ? void 0 : _c.filters) === null || _d === void 0 ? void 0 : _d.length) > 0) {
109
- return this.values.filters.length;
110
- }
111
- return 0;
104
+ const { advancedFilters, filters } = this.values || {};
105
+ return ((advancedFilters === null || advancedFilters === void 0 ? void 0 : advancedFilters.length) ? sum(advancedFilters.map((filter) => (filter === null || filter === void 0 ? void 0 : filter.length) || 0)) : filters === null || filters === void 0 ? void 0 : filters.length) || 0;
112
106
  }
113
107
  isFilterField(f) {
114
108
  return filterIsRadio(f) || filterIsAutocomplete(f) || filterIsSegement(f) || filterIsAutocompleteLocal(f) || filterIsBoolean(f) || filterIsDate(f) || filterIsText(f) || filterIsNumber(f);
@@ -183,6 +177,7 @@ const YooEntityQueryBuilderComponent = class {
183
177
  if (values.length > 0 || (values && field.type === FormFieldType.missionfield)) {
184
178
  this.values.filters.push(filterFromFormField(field, values, this.filterAutocompleteOperator));
185
179
  }
180
+ this.values = cloneDeep(this.values);
186
181
  this.onEmitValues();
187
182
  }
188
183
  onAutocompleteChangeAdvanced(ev, index) {
@@ -318,7 +313,7 @@ const YooEntityQueryBuilderComponent = class {
318
313
  }
319
314
  renderFiltersHeader() {
320
315
  const count = this.getActiveFiltersCount();
321
- return h("div", { class: "filters-header" }, h("div", { class: "counter" }, translate('YOOBICFILTERSAPPLIED', { smart_count: count })), h("div", { class: "clear-all" }, count > 0 && h("yoo-button", { size: this.size, color: count > 0 ? 'app-color' : 'stable', fill: "transparent", onClick: () => this.onClear() }, translate('CLEARALL'))));
316
+ return h("div", { class: "filters-header" }, h("div", { class: "counter" }, translate('YOOBICFILTERSAPPLIED', { smart_count: count })), h("div", { class: "clear-all" }, h("yoo-button", { size: this.size, color: "app-color", disabled: !count, fill: "transparent", onClick: () => this.onClear() }, translate('CLEARALL'))));
322
317
  }
323
318
  renderFilters() {
324
319
  var _a, _b;
@@ -402,7 +397,7 @@ const YooEntityQueryBuilderComponent = class {
402
397
  const count = this.getActiveFiltersCount();
403
398
  return [
404
399
  (customViewsButtons === null || customViewsButtons === void 0 ? void 0 : customViewsButtons.length) > 0 && (h("yoo-context-menu", { contentButtons: customViewsButtons, placement: "right", class: "customview-menu width-unset" }, h("div", { class: "header width-auto" }, h("div", { class: { title: true, 'app-color': !!this.customView } }, translate('SAVEDFILTERS')), h("yoo-icon", { name: "right-web", color: "stable", size: "medium" })))),
405
- h("div", { class: "header" }, h("div", { class: "title" }, translate('FILTERS', { count })), h("yoo-button", { size: this.size, color: count > 0 ? 'app-color' : 'stable', fill: "transparent", disabled: !this.isDirty && !(count > 0), onClick: () => this.onClear() }, translate('CLEARALL')))
400
+ h("div", { class: "header" }, h("div", { class: "title" }, translate('FILTERS', { count })), h("yoo-button", { size: this.size, color: "app-color", fill: "transparent", disabled: !count, onClick: () => this.onClear() }, translate('CLEARALL')))
406
401
  ];
407
402
  }
408
403
  renderDialogFooter() {
@@ -4,7 +4,7 @@ import './index-8ba1a121.js';
4
4
  import { k as keys, a as isNumber, n as compact, i as isArray, N as size, H as isNil, p as isString, ae as partition, C as get, b as isFunction } from './lodash-777f91de.js';
5
5
  import { e as getIncentiveStatusBadgeSettings } from './incentive-helpers-d0b35789.js';
6
6
  import { d as getCampaignStateTags, e as getCampaignTemplateTags, f as getMissionDataStateTags, h as getWaitlistVisitTags, g as getProductBatchDateTag, i as getProductBatchProgressColor } from './operation-helpers-754b31cf.js';
7
- import { h as getMissionStateTags, d as getMissionUniqueKey, g as getMissionAddress, m as mapMissionToCardInboxEntry } from './missions-helpers-2903cdac.js';
7
+ import { i as getMissionStateTags, d as getMissionUniqueKey, g as getMissionAddress, m as mapMissionToCardInboxEntry } from './missions-helpers-1863d0d4.js';
8
8
  import { g as getButton } from './button.factory-42e6d7c8.js';
9
9
  import { t as getNotificationIcon, h as execHandlerAndStopEvent, g as getAppContext } from './common-helpers-3b193836.js';
10
10
  import { a as getCalendarCourseDueDate, p as parseEntityForCardChat, o as onUserClick, b as parseFolderForCardList, c as parseEntityCommentsForCardList, d as getFolderIcon, e as parseEntityForCardMedia } from './entities-helpers-a50f68ec.js';
@@ -276,6 +276,7 @@ const YooFormAutocompleteDialogComponent = class {
276
276
  }
277
277
  onFilterRadioToggled(ev) {
278
278
  ev.stopPropagation();
279
+ this.selectedFilterOperator = ev.detail;
279
280
  this.filterRadioToggled.emit(ev.detail);
280
281
  }
281
282
  getEntityType() {
@@ -1,5 +1,5 @@
1
1
  import { r as registerInstance, i as createEvent, h, e as Host, g as getElement } from './index-a6a92b3d.js';
2
- import { c as FormFieldType } from './index-604330b3.js';
2
+ import { a3 as FormFilterAutocompleteOperator, c as FormFieldType } from './index-604330b3.js';
3
3
  import './index-8ba1a121.js';
4
4
  import { i as isArray, n as compact, l as uniq, p as isString, a as isNumber } from './lodash-777f91de.js';
5
5
  import { i as showImageCropper, h as execHandlerAndStopEvent, g as getAppContext } from './common-helpers-3b193836.js';
@@ -221,6 +221,7 @@ const YooFormAutocompleteComponent = class {
221
221
  }
222
222
  componentWillLoad() {
223
223
  var _a, _b;
224
+ this.isFilter && !this.filterOperator && this.selectFilterOperator(FormFilterAutocompleteOperator.is);
224
225
  this.updateSelection(true);
225
226
  if (this.showDropdownOnLoad) {
226
227
  this.showDropdownContent = this.showDropdownOnLoad;
@@ -646,7 +647,7 @@ const YooFormAutocompleteComponent = class {
646
647
  });
647
648
  this.dialog.addEventListener('filterRadioToggled', (ev) => {
648
649
  ev.stopPropagation();
649
- this.onFilterRadioToggled(ev.detail);
650
+ this.selectFilterOperator(ev.detail);
650
651
  });
651
652
  let modalOptions = { half: !isWeb(this.host) };
652
653
  if (isExpanding) {
@@ -700,7 +701,8 @@ const YooFormAutocompleteComponent = class {
700
701
  this.currentSelectedTags = ev.detail;
701
702
  await this.fetch();
702
703
  }
703
- onFilterRadioToggled(operator) {
704
+ selectFilterOperator(operator) {
705
+ this.filterOperator = operator;
704
706
  this.extraDataChanged.emit(operator);
705
707
  }
706
708
  async onFileChanges(ev) {
@@ -909,7 +911,6 @@ const YooFormAutocompleteComponent = class {
909
911
  var _a, _b, _c, _d, _e, _f, _g;
910
912
  const isPopulatedQuery = isArray(this.value) ? ((_a = this.value.find((v) => v === null || v === void 0 ? void 0 : v.total)) === null || _a === void 0 ? void 0 : _a.total) > 0 : ((_b = this.value) === null || _b === void 0 ? void 0 : _b.total) > 0;
911
913
  const valueTotal = isArray(this.value) ? (_c = this.value.find((v) => v === null || v === void 0 ? void 0 : v.total)) === null || _c === void 0 ? void 0 : _c.total : (_d = this.value) === null || _d === void 0 ? void 0 : _d.total;
912
- const selectedOperator = this.filterOperator || 'in';
913
914
  if (this.idOnly && ((_e = this.value) === null || _e === void 0 ? void 0 : _e.length) > 0 && isString(this.value[0]) && !this.idOnlyInitialSelection) {
914
915
  this.forceSelectedContentIdOnlyReload = true;
915
916
  }
@@ -921,7 +922,7 @@ const YooFormAutocompleteComponent = class {
921
922
  if (this.entityType === 'groups' && !this.returnQuery) {
922
923
  groupSelection = (_f = this.selection) === null || _f === void 0 ? void 0 : _f.filter((value) => { var _a, _b; return (value === null || value === void 0 ? void 0 : value.title) ? !((_a = value === null || value === void 0 ? void 0 : value.title) === null || _a === void 0 ? void 0 : _a.match(MONGODB_ID_REGEX)) : (value === null || value === void 0 ? void 0 : value._id) && !(value === null || value === void 0 ? void 0 : value.title) ? !((_b = value === null || value === void 0 ? void 0 : value._id) === null || _b === void 0 ? void 0 : _b.match(MONGODB_ID_REGEX)) : !(value === null || value === void 0 ? void 0 : value.match(MONGODB_ID_REGEX)); });
923
924
  }
924
- return (h("div", { class: { 'entity-content': true, selected: true, 'icon-prefix': hasIconPrefix } }, `${this.isFilter ? selectedOperator : ''} ${this.entityType !== 'groups' ? (_g = this.selection) === null || _g === void 0 ? void 0 : _g.length : groupSelection === null || groupSelection === void 0 ? void 0 : groupSelection.length} ${translate(this.setPrefixedEntityType(entityType).toUpperCase())} ${translate(this.multipleSelectionSuffix)}`));
925
+ return (h("div", { class: { 'entity-content': true, selected: true, 'icon-prefix': hasIconPrefix } }, `${this.isFilter ? this.filterOperator : ''} ${this.entityType !== 'groups' ? (_g = this.selection) === null || _g === void 0 ? void 0 : _g.length : groupSelection === null || groupSelection === void 0 ? void 0 : groupSelection.length} ${translate(this.setPrefixedEntityType(entityType).toUpperCase())} ${translate(this.multipleSelectionSuffix)}`));
925
926
  }
926
927
  renderUnselectedEntites(entityType, hasIconPrefix) {
927
928
  const filesPlaceholder = isWeb(this.host) ? translate('FORMFIELDDEFINITIONDOCUMENTPLACEHOLDER') : translate('SELECTFILES');
@@ -939,7 +940,6 @@ const YooFormAutocompleteComponent = class {
939
940
  }
940
941
  renderEntities(hasIconPrefix, cardTagSingle = false) {
941
942
  var _a;
942
- const selectedOperator = this.filterOperator || 'in';
943
943
  return (h("div", { class: { 'entity-container': true, empty: !this.selection || this.selection.length <= 0, prefix: hasIconPrefix } }, (_a = this.selection) === null || _a === void 0 ? void 0 : _a.map((selection, i) => {
944
944
  var _a, _b;
945
945
  let entitySelection = selection;
@@ -961,7 +961,7 @@ const YooFormAutocompleteComponent = class {
961
961
  }
962
962
  const title = (entitySelection === null || entitySelection === void 0 ? void 0 : entitySelection.title) || entitySelection;
963
963
  return (entitySelection && [
964
- h("div", { class: { 'single-entity-container': this.isFilter } }, h("div", { class: "operator-container" }, `${this.isFilter ? selectedOperator : ''}`), h("yoo-entity", { class: {
964
+ h("div", { class: { 'single-entity-container': this.isFilter } }, h("div", { class: "operator-container" }, `${this.isFilter ? this.filterOperator : ''}`), h("yoo-entity", { class: {
965
965
  'autocomplete autocomplete-selected': true,
966
966
  last: i === this.selection.length - 1,
967
967
  bold: this.color === 'transparent',
@@ -1006,7 +1006,7 @@ const YooFormAutocompleteComponent = class {
1006
1006
  await this.fetch(ev.detail);
1007
1007
  }, onFieldFetchData: (ev) => this.onFetchFieldFilterData(ev), onSortsAndFiltersChange: (ev) => this.onSortsAndFiltersChange(ev), onCurrentPageChanged: (ev) => this.onCurrentPageChange(ev === null || ev === void 0 ? void 0 : ev.detail), hideHeader: isNullOrUndefined(this.hideHeader) ? false : this.hideHeader, showSearch: !this.forceHideSearch && (this.initialValueLength > minValuesForSearch || this.allowCustomTag || this.allowCustomValue || this.entityType === 'googlemaps'), isLocal: this.isLocal, onGridExpanded: () => this.onExpandGrid(), useTranslate: this.useTranslate, initialSelection: this.returnQuery ? null : [].concat(isPresent(this.value) ? this.value : []), idOnly: this.idOnly || this.allowCustomTag, idAttributeName: this.idAttributeName || '_id', emptyState: this.emptyState, allowCustomTag: (this.allowCustomTag || this.tag || this.allowCustomValue) && !this.forceDisableCustomTags, searchBarPlaceholder: (this.allowCustomTag || this.allowCustomValue) && !this.forceDisableCustomTags
1008
1008
  ? translate(this.isLocal ? 'AUTOCOMPLETESEARCHADD' : 'SEARCHORADD')
1009
- : translate('SEARCH'), tags: this.tags, forceHideSearch: this.forceHideSearch, maxSelectionNumber: this.max, customModel: this.customModel, addNewTagText: this.entityType === 'emails' ? translate('ADDNEWEMAIL') : this.searchText, model: this.model, hideAdvancedFilters: !this.model, hideRefreshButton: true, showFilters: false, onTagsSelect: (ev) => this.onTagsSelect(ev), isCollapsible: false, onAddNewTagPressed: (ev) => this.onCustomTagCreated(ev), disableSingleDeselection: this.disableSingleDeselection, idOnlyInitialSelection: this.idOnlyInitialSelection, isLoading: this.isLoading, valuesColor: this.valuesColor, total: this.total, returnQuery: this.returnQuery, showSelectAll: this.returnQuery, initialQuery: this.returnQuery ? this.value : null, sortsAndFilters: this.returnQuery ? (_c = this.value) === null || _c === void 0 ? void 0 : _c.sortsAndFilters : null, onFileUpload: () => { var _a; return (_a = this.inputElement) === null || _a === void 0 ? void 0 : _a.click(); }, isUploading: this.isUploading, showFormRadio: this.isFilter, selectedFilterOperator: this.filterOperator, onFormRadioToggled: (ev) => this.onFilterRadioToggled(ev.detail), onMaxPageCountChanged: (ev) => (this.maxPage = Math.max(ev.detail, this.maxPage)), onSearchedItemSelected: (ev) => this.updateSearchedItemSelection(ev), onValidityChanged: (ev) => this.onValidityChanged(ev), infiniteScrollDisabled: this.infiniteScrollDisabled }))))))));
1009
+ : translate('SEARCH'), tags: this.tags, forceHideSearch: this.forceHideSearch, maxSelectionNumber: this.max, customModel: this.customModel, addNewTagText: this.entityType === 'emails' ? translate('ADDNEWEMAIL') : this.searchText, model: this.model, hideAdvancedFilters: !this.model, hideRefreshButton: true, showFilters: false, onTagsSelect: (ev) => this.onTagsSelect(ev), isCollapsible: false, onAddNewTagPressed: (ev) => this.onCustomTagCreated(ev), disableSingleDeselection: this.disableSingleDeselection, idOnlyInitialSelection: this.idOnlyInitialSelection, isLoading: this.isLoading, valuesColor: this.valuesColor, total: this.total, returnQuery: this.returnQuery, showSelectAll: this.returnQuery, initialQuery: this.returnQuery ? this.value : null, sortsAndFilters: this.returnQuery ? (_c = this.value) === null || _c === void 0 ? void 0 : _c.sortsAndFilters : null, onFileUpload: () => { var _a; return (_a = this.inputElement) === null || _a === void 0 ? void 0 : _a.click(); }, isUploading: this.isUploading, showFormRadio: this.isFilter, selectedFilterOperator: this.filterOperator, onFormRadioToggled: (ev) => this.selectFilterOperator(ev.detail), onMaxPageCountChanged: (ev) => (this.maxPage = Math.max(ev.detail, this.maxPage)), onSearchedItemSelected: (ev) => this.updateSearchedItemSelection(ev), onValidityChanged: (ev) => this.onValidityChanged(ev), infiniteScrollDisabled: this.infiniteScrollDisabled }))))))));
1010
1010
  }
1011
1011
  renderReadonly() {
1012
1012
  if (this.selection && this.selection.length > 0) {
@@ -3,11 +3,11 @@ import { r as resizeObserve } from './index-8ba1a121.js';
3
3
  import { p as isString, b as isFunction, a as isNumber } from './lodash-777f91de.js';
4
4
  import { g as getAppContext } from './common-helpers-3b193836.js';
5
5
  import { v as validate, i as initNumber, a as setValueAndValidateInput, s as setValidator, c as convertValueForInputType, h as onIconClicked, o as onInputClear, b as onInputBlurred, d as onInputFocused, j as clearFocused } from './form-input-helpers-df22e2a8.js';
6
- import { g as getRenderer } from './grid-renderers-eea95bb8.js';
6
+ import { g as getRenderer } from './grid-renderers-63114b98.js';
7
7
  import { H as isWeb, k as isNullOrUndefined, I as debounce, o as isNativeMobile, N as isIOS, ag as enableKeyboardResize, bX as isSafari, p as isAndroid, dJ as isHTML, fL as extractTextFromStringHTML, aw as copyToClipboard, b9 as showToast, t as translate, dm as isAnimationsDisabled } from './index-9e87cea3.js';
8
8
  import './index-604330b3.js';
9
9
  import './incentive-helpers-d0b35789.js';
10
- import './missions-helpers-2903cdac.js';
10
+ import './missions-helpers-1863d0d4.js';
11
11
  import './form-helpers-4d69b46e.js';
12
12
  import './geolocation-helpers-32aa6208.js';
13
13
  import './_commonjsHelpers-f4d11124.js';
@@ -1,5 +1,5 @@
1
1
  import { r as registerInstance, i as createEvent, f as forceUpdate, h, e as Host, g as getElement } from './index-a6a92b3d.js';
2
- import { a3 as FormFilterAutocompleteOperator, c as FormFieldType, a4 as EMPTYSTATE_TITLE_MAP, a5 as EMPTYSTATE_TEXT_MAP, a6 as CALENDAR_VIEW_IDS } from './index-604330b3.js';
2
+ import { c as FormFieldType, a3 as FormFilterAutocompleteOperator, a4 as EMPTYSTATE_TITLE_MAP, a5 as EMPTYSTATE_TEXT_MAP, a6 as CALENDAR_VIEW_IDS } from './index-604330b3.js';
3
3
  import './index-8ba1a121.js';
4
4
  import { $ as debounce, A as isEqual, h as map, B as sortBy, i as isArray, y as isEmpty, n as compact, C as get, p as isString, a as isNumber, G as isBoolean, S as findIndex, aa as sum, a7 as range, v as isObject, b as isFunction } from './lodash-777f91de.js';
5
5
  import { S as Sortable } from './sortable.esm-f788d1ca.js';
@@ -9,14 +9,14 @@ import { a as assignPressActions } from './index-321ff220.js';
9
9
  import { c as querySelectorAllDeep, n as hideShowSearchBar, p as getNextValueInArray, g as getAppContext } from './common-helpers-3b193836.js';
10
10
  import { m as mapCustomViewToButton, l as isKanbanColumnField } from './filters-helpers-753cda2a.js';
11
11
  import { s as setValidator, a as setValueAndValidateInput } from './form-input-helpers-df22e2a8.js';
12
- import { g as getRenderer } from './grid-renderers-eea95bb8.js';
12
+ import { g as getRenderer } from './grid-renderers-63114b98.js';
13
13
  import { eB as HorizontalSlidesAnimation, H as isWeb, av as pipes, aM as isPresent, e0 as safeScrollIntoView, W as getAsyncExtraData, eC as MONGODB_ID_REGEX, bM as filterListByText, a8 as getSession, dm as isAnimationsDisabled, eD as isMapField, k as isNullOrUndefined, t as translate, G as showModal, a3 as translateMulti, aE as toButton, d1 as getAuthentication, cp as showActionSheet, br as isOffline, bJ as isDateTimeField, eE as isAutocompleteLocalField, eF as isNumberField, eG as isEmail, ap as dispatchCustomEvent, dZ as isFirefox, eH as isForceScrollbar } from './index-9e87cea3.js';
14
14
  import { I as ItemSlidingType } from './item-sliding.interface-85f6790e.js';
15
15
  import './workflow.interface-79064a52.js';
16
16
  import './form-field.instance-9dc4d638.js';
17
17
  import './card-video.interface-5572358c.js';
18
18
  import './incentive-helpers-d0b35789.js';
19
- import './missions-helpers-2903cdac.js';
19
+ import './missions-helpers-1863d0d4.js';
20
20
  import './form-helpers-4d69b46e.js';
21
21
  import './geolocation-helpers-32aa6208.js';
22
22
  import './_commonjsHelpers-f4d11124.js';
@@ -168,16 +168,6 @@ const YooGridComponent = class {
168
168
  }, 500);
169
169
  this.itemsHaveBeenReordered = false;
170
170
  this.filtersUpdated = false;
171
- this.filterOptions = [
172
- {
173
- type: FormFilterAutocompleteOperator.is,
174
- active: true
175
- },
176
- {
177
- type: FormFilterAutocompleteOperator.isNot,
178
- active: false
179
- }
180
- ];
181
171
  this.renderVirtualItem = (item, index) => {
182
172
  if (this.hasSecondaryActions || (this.keepSelection && isWeb(this.host))) {
183
173
  if (this.showActionsAsMore) {
@@ -588,6 +578,7 @@ const YooGridComponent = class {
588
578
  if (this.isFormField) {
589
579
  setValidator(this);
590
580
  }
581
+ this.showFormRadio && !this.selectedFilterOperator && this.selectFilterOperator(FormFilterAutocompleteOperator.is);
591
582
  this.isSelectionMode = this.multiple && !this.blockSelectionMode;
592
583
  this.areItemsDisabled = (_a = this.extraClass) === null || _a === void 0 ? void 0 : _a.includes('item-disabled');
593
584
  this.searchText = this.search || '';
@@ -1473,18 +1464,6 @@ const YooGridComponent = class {
1473
1464
  }
1474
1465
  return false;
1475
1466
  }
1476
- onToggleFormRadio(ev) {
1477
- var _a;
1478
- const selectedOption = (_a = this.filterOptions) === null || _a === void 0 ? void 0 : _a.find((option) => (option === null || option === void 0 ? void 0 : option.type) === (ev === null || ev === void 0 ? void 0 : ev.detail));
1479
- if (selectedOption) {
1480
- selectedOption.active = true;
1481
- }
1482
- if (!selectedOption) {
1483
- this.formRadioToggled.emit(null);
1484
- return;
1485
- }
1486
- this.formRadioToggled.emit(selectedOption.type);
1487
- }
1488
1467
  updateSelectAll(selectAll) {
1489
1468
  this.isSelectAll = selectAll;
1490
1469
  if (!this.isSelectAll && this.isAgGrid() && this.gridApi) {
@@ -1971,12 +1950,16 @@ const YooGridComponent = class {
1971
1950
  }
1972
1951
  return 0;
1973
1952
  }
1953
+ selectFilterOperator(operator) {
1954
+ this.selectedFilterOperator = operator;
1955
+ this.formRadioToggled.emit(operator);
1956
+ }
1974
1957
  renderDropdownFormRadio() {
1975
- var _a;
1976
- const formOptions = this.filterOptions.map((filterOption) => filterOption.type);
1977
- if (isWeb(this.host) && ((_a = this.items) === null || _a === void 0 ? void 0 : _a.length)) {
1978
- return (h("div", { class: "form-radio-container" }, h("yoo-form-radio", { options: formOptions, flow: "column", size: "medium", value: this.selectedFilterOperator || formOptions[0], onInputChanged: (ev) => this.onToggleFormRadio(ev) }, formOptions.map((option, index) => (h("span", { slot: index.toString() }, option))))));
1979
- }
1958
+ const operators = [FormFilterAutocompleteOperator.is, FormFilterAutocompleteOperator.isNot];
1959
+ return (h("div", { class: "form-radio-container" }, h("yoo-form-radio", { options: operators, flow: "column", size: "medium", value: this.selectedFilterOperator, onInputChanged: (event) => {
1960
+ event.stopPropagation();
1961
+ this.selectFilterOperator(event.detail);
1962
+ } }, operators.map((operator, index) => h("span", { slot: index.toString() }, operator)))));
1980
1963
  }
1981
1964
  renderSearchInput() {
1982
1965
  var _a, _b, _c;
@@ -3141,14 +3124,14 @@ const YooGridComponent = class {
3141
3124
  return (this.mainProgressValue >= 0 && (h("div", { class: "grid-progress" }, h("yoo-progress-bar", { animated: this.animated, metric: "percentage", percentValueColorScheme: false, value: this.total > 0 ? (this.mainProgressValue * 100) / this.total : 0 }))));
3142
3125
  }
3143
3126
  renderBase() {
3144
- var _a, _b, _c, _d, _e;
3127
+ var _a, _b, _c, _d, _e, _f;
3145
3128
  const renderEntityTags = (!isWeb(this.host) || (this.gridIsExpanded && (((_a = this.tags) === null || _a === void 0 ? void 0 : _a.length) > 0 || ((_c = (_b = this.model) === null || _b === void 0 ? void 0 : _b.fields) === null || _c === void 0 ? void 0 : _c.length) > 0))) &&
3146
3129
  this.isTagsVisible() &&
3147
3130
  ((this.items && this.items.length > 0) || this.hasSortsAndFilters() || this.alwaysRenderTagsAndFilters() || this.isAgGrid()) &&
3148
3131
  !this.host.classList.contains('learning-manager') && !this.host.classList.contains('course-info');
3149
3132
  return [
3150
3133
  this.showProgress && this.progressHandler && this.renderProgress(),
3151
- h("div", { ref: (el) => (this.containerBase = el), class: this.getClassList() }, this.showAutocompleteHeader ? (h("div", { class: { 'dropdown-header': true, 'no-tags': !renderEntityTags || ((_d = this.tags) === null || _d === void 0 ? void 0 : _d.length) === 0, 'form-radio-operators': this.showFormRadio } }, this.showFormRadio && this.renderDropdownFormRadio(), this.renderHeader(renderEntityTags), this.renderDynamicOrderingHeader(), this.renderFilesIcons())) : ([this.renderHeader(renderEntityTags), this.renderFilesIcons()]), this.isKanban() && h("slot", { name: "header" }), (((_e = this.columns) === null || _e === void 0 ? void 0 : _e.length) || this.mainColumnHeader) && !this.isAgGrid() && !this.isCalendar() && isWeb(this.host) && !this.isMap() ? (h("div", { class: "horizontal-scroll-parent" }, h("div", { class: "horizontal-scroll", ref: (el) => (this.horizontalScroll = el) }, h("div", { class: { 'horizontal-content': true, 'with-header': this.hasColumnsHeader() } }, this.renderColumnsHeader(), this.renderBaseContent())))) : (this.renderBaseContent())),
3134
+ h("div", { ref: (el) => (this.containerBase = el), class: this.getClassList() }, this.showAutocompleteHeader ? (h("div", { class: { 'dropdown-header': true, 'no-tags': !renderEntityTags || ((_d = this.tags) === null || _d === void 0 ? void 0 : _d.length) === 0, 'form-radio-operators': this.showFormRadio } }, this.showFormRadio && isWeb(this.host) && !!((_e = this.items) === null || _e === void 0 ? void 0 : _e.length) && this.renderDropdownFormRadio(), this.renderHeader(renderEntityTags), this.renderDynamicOrderingHeader(), this.renderFilesIcons())) : ([this.renderHeader(renderEntityTags), this.renderFilesIcons()]), this.isKanban() && h("slot", { name: "header" }), (((_f = this.columns) === null || _f === void 0 ? void 0 : _f.length) || this.mainColumnHeader) && !this.isAgGrid() && !this.isCalendar() && isWeb(this.host) && !this.isMap() ? (h("div", { class: "horizontal-scroll-parent" }, h("div", { class: "horizontal-scroll", ref: (el) => (this.horizontalScroll = el) }, h("div", { class: { 'horizontal-content': true, 'with-header': this.hasColumnsHeader() } }, this.renderColumnsHeader(), this.renderBaseContent())))) : (this.renderBaseContent())),
3152
3135
  isWeb(this.host) && this.showGlobalActions && this.isSelectionMode && this.renderGlobalActions()
3153
3136
  ];
3154
3137
  }
@@ -1,7 +1,7 @@
1
1
  import { h, r as registerInstance, i as createEvent, e as Host, g as getElement } from './index-a6a92b3d.js';
2
2
  import './index-8ba1a121.js';
3
3
  import { c as cloneDeep, l as uniq, n as compact } from './lodash-777f91de.js';
4
- import { g as getMissionAddress, a as getMissionPriority, b as getMissionDueDate, m as mapMissionToCardInboxEntry, c as getMissionTags, d as getMissionUniqueKey } from './missions-helpers-2903cdac.js';
4
+ import { g as getMissionAddress, a as getMissionPriority, b as getMissionDueDate, m as mapMissionToCardInboxEntry, c as getMissionTags, d as getMissionUniqueKey } from './missions-helpers-1863d0d4.js';
5
5
  import { g as getAppContext } from './common-helpers-3b193836.js';
6
6
  import { a8 as getSession, W as getAsyncExtraData, H as isWeb, t as translate, cC as isIonic, aM as isPresent, Q as getCssColor, cV as isToday, cW as fromToday, ao as dateFormat, cX as getMissionPublicationDate, cY as isDateSame, V as isDateAfter, a3 as translateMulti, av as pipes } from './index-9e87cea3.js';
7
7
  import './index-604330b3.js';
@@ -1,6 +1,6 @@
1
1
  import { r as registerInstance, f as forceUpdate, h, e as Host, g as getElement } from './index-a6a92b3d.js';
2
2
  import './index-8ba1a121.js';
3
- import { e as getMissionProgress, c as getMissionTags, d as getMissionUniqueKey } from './missions-helpers-2903cdac.js';
3
+ import { e as getMissionProgress, c as getMissionTags, d as getMissionUniqueKey } from './missions-helpers-1863d0d4.js';
4
4
  import { g as getAppContext } from './common-helpers-3b193836.js';
5
5
  import { M as MissionLockedBanner } from './mission-locked-banner-1e823065.js';
6
6
  import { cC as isIonic, t as translate, a3 as translateMulti } from './index-9e87cea3.js';
@@ -2,11 +2,11 @@ import { r as registerInstance, i as createEvent, h, g as getElement } from './i
2
2
  import './index-8ba1a121.js';
3
3
  import { a as createCommonjsModule, c as commonjsGlobal } from './_commonjsHelpers-f4d11124.js';
4
4
  import { $ as debounce, c as cloneDeep, s as assign, B as sortBy, A as isEqual } from './lodash-777f91de.js';
5
- import { g as getRenderer } from './grid-renderers-eea95bb8.js';
5
+ import { g as getRenderer } from './grid-renderers-63114b98.js';
6
6
  import { t as translate } from './index-9e87cea3.js';
7
7
  import './index-604330b3.js';
8
8
  import './incentive-helpers-d0b35789.js';
9
- import './missions-helpers-2903cdac.js';
9
+ import './missions-helpers-1863d0d4.js';
10
10
  import './common-helpers-3b193836.js';
11
11
  import './form-helpers-4d69b46e.js';
12
12
  import './geolocation-helpers-32aa6208.js';
@@ -189,7 +189,7 @@ export declare class YooFormAutocompleteComponent implements IFormAutocomplete<a
189
189
  onCustomTagCreated(ev: CustomEvent<string>): Promise<void>;
190
190
  onSelectionRemoved(selection: IEntity): Promise<void>;
191
191
  onTagsSelect(ev: CustomEvent<IEntitySearchTags[]>): Promise<void>;
192
- onFilterRadioToggled(operator: FormFilterAutocompleteOperator): void;
192
+ selectFilterOperator(operator: FormFilterAutocompleteOperator): void;
193
193
  onFileChanges(ev: CustomEvent<any>): Promise<void>;
194
194
  onFileSelect(ev: Event): Promise<void>;
195
195
  uploadFiles(fileList: File[]): Promise<void>;
@@ -17,7 +17,7 @@ export declare class YooFormAutocompleteDialogComponent {
17
17
  tag: boolean;
18
18
  tags: IEntitySearchTags[];
19
19
  hideTags: boolean;
20
- selectedFilterOperator: string;
20
+ selectedFilterOperator?: FormFilterAutocompleteOperator;
21
21
  max: number;
22
22
  isLoading: boolean;
23
23
  customModel: ICustomModel;