@datorama/core 22.2.6 → 22.5.1

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 (29) hide show
  1. package/bundle.scss +22 -0
  2. package/bundles/datorama-core.umd.js +17 -11
  3. package/bundles/datorama-core.umd.js.map +1 -1
  4. package/bundles/datorama-core.umd.min.js +3 -3
  5. package/bundles/datorama-core.umd.min.js.map +1 -1
  6. package/datorama-core.metadata.json +1 -1
  7. package/esm2015/lib/date-picker/date-picker-container/date-picker-container.component.js +5 -5
  8. package/esm2015/lib/grid-v2/grid-controller/grid-controller.component.js +1 -1
  9. package/esm2015/lib/grid-v2/grid-filter/grid-filter.component.js +1 -1
  10. package/esm2015/lib/grid-v2/grid-filter/grid-filter.types.js +1 -1
  11. package/esm2015/lib/grid-v2/grid-store/grid.service.js +1 -1
  12. package/esm2015/lib/grid-v2/grid-toolbar/grid-toolbar.component.js +1 -1
  13. package/esm2015/lib/select/select.component.js +12 -7
  14. package/esm2015/lib/version.js +2 -2
  15. package/esm5/lib/date-picker/date-picker-container/date-picker-container.component.js +5 -5
  16. package/esm5/lib/grid-v2/grid-controller/grid-controller.component.js +1 -1
  17. package/esm5/lib/grid-v2/grid-filter/grid-filter.component.js +1 -1
  18. package/esm5/lib/grid-v2/grid-filter/grid-filter.types.js +1 -1
  19. package/esm5/lib/grid-v2/grid-store/grid.service.js +1 -1
  20. package/esm5/lib/grid-v2/grid-toolbar/grid-toolbar.component.js +1 -1
  21. package/esm5/lib/select/select.component.js +13 -7
  22. package/esm5/lib/version.js +2 -2
  23. package/fesm2015/datorama-core.js +16 -11
  24. package/fesm2015/datorama-core.js.map +1 -1
  25. package/fesm5/datorama-core.js +17 -11
  26. package/fesm5/datorama-core.js.map +1 -1
  27. package/lib/date-picker/date-picker-container/date-picker-container.component.d.ts +1 -1
  28. package/lib/select/select.component.d.ts +1 -0
  29. package/package.json +1 -1
package/bundle.scss CHANGED
@@ -11199,8 +11199,30 @@ dato-date-picker .icon-text-border {
11199
11199
  border-radius: 2px;
11200
11200
  }
11201
11201
 
11202
+ .dato-date-picker-trigger {
11203
+ font-weight: 600;
11204
+ color: themify(primary-300);
11205
+ }
11206
+
11202
11207
  .dato-date-picker-trigger dato-icon {
11203
11208
  margin-right: 7px;
11209
+ color: themify(primary-300);
11210
+ }
11211
+
11212
+ .dato-date-picker-trigger:hover {
11213
+ color: themify(primary-400);
11214
+ }
11215
+
11216
+ .dato-date-picker-trigger:hover dato-icon {
11217
+ color: themify(primary-400);
11218
+ }
11219
+
11220
+ .dato-date-picker-trigger.open {
11221
+ color: themify(accent-400);
11222
+ }
11223
+
11224
+ .dato-date-picker-trigger.open dato-icon {
11225
+ color: themify(accent-400);
11204
11226
  }
11205
11227
 
11206
11228
  .date-picker-months-0 [datoicon="up"] {
@@ -8748,8 +8748,8 @@
8748
8748
  }
8749
8749
  }
8750
8750
  this.onChange(this._model);
8751
- this.datoOverlay.scheduleUpdate();
8752
8751
  this.cdr.markForCheck();
8752
+ this.asyncUpdateDropdownPosition();
8753
8753
  };
8754
8754
  DatoSelectComponent.prototype.reorderOptions = function (newOrder) {
8755
8755
  this._model = newOrder;
@@ -8770,9 +8770,7 @@
8770
8770
  updateDisabled && this.updateDisabledState();
8771
8771
  this.onChange(this._model);
8772
8772
  this.cdr.markForCheck();
8773
- if (this.datoOverlay.attached) {
8774
- this.datoOverlay.scheduleUpdate();
8775
- }
8773
+ this.asyncUpdateDropdownPosition();
8776
8774
  };
8777
8775
  DatoSelectComponent.prototype.preventBodyScroll = function (event) {
8778
8776
  if (isArrowUpDown(event)) {
@@ -9027,7 +9025,7 @@
9027
9025
  _this.searchTerm = value;
9028
9026
  _this.keyManager.setActiveItem(-1);
9029
9027
  _this.cdr.markForCheck();
9030
- _this.datoOverlay && _this.datoOverlay.scheduleUpdate();
9028
+ _this.asyncUpdateDropdownPosition();
9031
9029
  });
9032
9030
  };
9033
9031
  /**
@@ -9131,7 +9129,7 @@
9131
9129
  updateDisabled && this.updateDisabledState();
9132
9130
  this.onChange(this._model);
9133
9131
  this.cdr.markForCheck();
9134
- this.datoOverlay.scheduleUpdate();
9132
+ this.asyncUpdateDropdownPosition();
9135
9133
  };
9136
9134
  DatoSelectComponent.prototype.activateInfiniteScroll = function () {
9137
9135
  var _this = this;
@@ -9184,6 +9182,14 @@
9184
9182
  finally { if (e_9) throw e_9.error; }
9185
9183
  }
9186
9184
  };
9185
+ // Make sure the overlay will be update AFTER Change Detection was done
9186
+ // So the items in the input (and its height) is update
9187
+ DatoSelectComponent.prototype.asyncUpdateDropdownPosition = function () {
9188
+ var _this = this;
9189
+ if (this.datoOverlay && this.datoOverlay.attached) {
9190
+ setTimeout(function () { return _this.datoOverlay.scheduleUpdate(); }, 0);
9191
+ }
9192
+ };
9187
9193
  DatoSelectComponent.ctorParameters = function () { return [
9188
9194
  { type: core.ChangeDetectorRef },
9189
9195
  { type: DatoTranslateService },
@@ -18470,9 +18476,11 @@
18470
18476
  .subscribe(function (event) {
18471
18477
  _this.toggle.emit(event);
18472
18478
  _this.open = false;
18479
+ _this.cdr.detectChanges();
18473
18480
  _this.input && _this.setInputValue();
18474
18481
  });
18475
18482
  this.open = true;
18483
+ this.cdr.detectChanges();
18476
18484
  this.input && this.handleEnter();
18477
18485
  }
18478
18486
  };
@@ -18526,9 +18534,7 @@
18526
18534
  };
18527
18535
  DatoDatePickerContainerComponent.prototype.handleEnter = function () {
18528
18536
  var _this = this;
18529
- this.input.keydown$
18530
- .pipe(operators.filter(isEnter), operators.takeUntil(this.toggle))
18531
- .subscribe(function () {
18537
+ this.input.keydown$.pipe(operators.filter(isEnter), operators.takeUntil(this.toggle)).subscribe(function () {
18532
18538
  _this.setInputValue();
18533
18539
  _this.popover.closeById(DATE_PICKER_POPOVER_ID);
18534
18540
  _this.input.blur();
@@ -18593,7 +18599,7 @@
18593
18599
  DatoDatePickerContainerComponent = __decorate([
18594
18600
  core.Component({
18595
18601
  selector: 'dato-date-picker',
18596
- template: "<div class=\"d-flex {{ triggerStyle }} items-center dato-date-picker-trigger\" (click)=\"openDatepicker(origin)\" #origin\n [class.pointer]=\"!viewMode\">\n <ng-template #defaultView>\n <dato-icon datoIcon=\"calendarcore\" width=\"16px\" class=\"primary-400-color\"></dato-icon>\n <div class=\"ellipsis\"\n [datoTooltip]=\"dateLabel + ' ' + dateRange\"\n [datoTooltipPosition]=\"labelTooltipPosition\"\n [datoTooltipOnTextOverflow]=\"true\">\n <span class=\"dato-note date-label\" *ngIf=\"dateLabel\">{{dateLabel | translate}}&nbsp;</span>\n <span class=\"dato-note date-range\">{{dateRange}}</span>\n </div>\n </ng-template>\n\n <ng-template [ngTemplateOutlet]=\"triggerTpl ? triggerTpl : defaultView\"\n [ngTemplateOutletContext]=\"{label: dateLabel, range: dateRange, icon: 'calendar'}\"></ng-template>\n </div>\n",
18602
+ template: "<div class=\"d-flex {{ triggerStyle }} items-center dato-date-picker-trigger\" [class.open]=\"open\" (click)=\"openDatepicker(origin)\" #origin\n [class.pointer]=\"!viewMode\">\n <ng-template #defaultView>\n <dato-icon datoIcon=\"calendarcore\" width=\"16px\" class=\"primary-400-color\"></dato-icon>\n <div class=\"ellipsis\"\n [datoTooltip]=\"dateLabel + ' ' + dateRange\"\n [datoTooltipPosition]=\"labelTooltipPosition\"\n [datoTooltipOnTextOverflow]=\"true\">\n <span class=\"dato-note date-label\" *ngIf=\"dateLabel\">{{dateLabel | translate}}&nbsp;</span>\n <span class=\"dato-note date-range\">{{dateRange}}</span>\n </div>\n </ng-template>\n\n <ng-template [ngTemplateOutlet]=\"triggerTpl ? triggerTpl : defaultView\"\n [ngTemplateOutletContext]=\"{label: dateLabel, range: dateRange, icon: 'calendar'}\"></ng-template>\n </div>\n",
18597
18603
  changeDetection: core.ChangeDetectionStrategy.OnPush
18598
18604
  }),
18599
18605
  __param(0, core.Self()), __param(0, core.Optional()),
@@ -25386,7 +25392,7 @@
25386
25392
  };
25387
25393
  }
25388
25394
 
25389
- window.coreVersion = '22.2.6';
25395
+ window.coreVersion = '22.5.1';
25390
25396
 
25391
25397
  exports.APP_TRANSLATE = APP_TRANSLATE;
25392
25398
  exports.AceService = AceService;