@seniorsistemas/angular-components 17.18.4 → 17.18.5

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.
@@ -9709,6 +9709,7 @@
9709
9709
  console.warn("Unable to find frozen element from table. Is the table configured with frozen template?");
9710
9710
  return;
9711
9711
  }
9712
+ frozenTable.style.width = 'min-content';
9712
9713
  frozenTable.style.order = "1";
9713
9714
  frozenTable.style.borderRight = "none";
9714
9715
  frozenTable.style.borderLeft = "1px solid #dddddd";
@@ -9719,6 +9720,7 @@
9719
9720
  return;
9720
9721
  }
9721
9722
  unfrozenTable.style.position = "unset";
9723
+ unfrozenTable.style.overflow = 'auto';
9722
9724
  };
9723
9725
  TableFrozenPositionDirective.prototype.handleWindowResize = function () {
9724
9726
  this.synchronizeRowHeight();
@@ -19775,6 +19777,7 @@
19775
19777
  var ThumbnailsComponent = /** @class */ (function () {
19776
19778
  function ThumbnailsComponent() {
19777
19779
  this.selectable = true;
19780
+ this.combineCheckboxEvent = true;
19778
19781
  this.selectionChange = new core.EventEmitter();
19779
19782
  this.itemOpened = new core.EventEmitter();
19780
19783
  this._selection = [];
@@ -19789,12 +19792,12 @@
19789
19792
  ThumbnailsComponent.prototype.onItemOpened = function (item) {
19790
19793
  this.itemOpened.emit(item);
19791
19794
  };
19792
- ThumbnailsComponent.prototype.onItemSelected = function (items) {
19793
- if (items.selected) {
19794
- this._selection.push(items.item);
19795
+ ThumbnailsComponent.prototype.onItemSelected = function (item) {
19796
+ if (item.selected) {
19797
+ this._selection.push(item.item);
19795
19798
  }
19796
19799
  else {
19797
- this._selection.splice(this._selection.findIndex(function (item) { return item === items.item; }), 1);
19800
+ this._selection.splice(this._selection.findIndex(function (_item) { return _item === item.item; }), 1);
19798
19801
  }
19799
19802
  this.selectionChange.emit(this._selection);
19800
19803
  };
@@ -19807,6 +19810,9 @@
19807
19810
  __decorate([
19808
19811
  core.Input()
19809
19812
  ], ThumbnailsComponent.prototype, "selectable", void 0);
19813
+ __decorate([
19814
+ core.Input()
19815
+ ], ThumbnailsComponent.prototype, "combineCheckboxEvent", void 0);
19810
19816
  __decorate([
19811
19817
  core.Input()
19812
19818
  ], ThumbnailsComponent.prototype, "selection", null);
@@ -19819,7 +19825,7 @@
19819
19825
  ThumbnailsComponent = __decorate([
19820
19826
  core.Component({
19821
19827
  selector: "s-thumbnails",
19822
- template: "<div class=\"thumbnails\">\n <s-thumbnail-item\n *ngFor=\"let item of items\"\n [itemData]=\"item\"\n [isCheckable]=\"selectable\"\n [isChecked]=\"isSelected(item)\"\n (checked)=\"onItemSelected($event)\"\n (opened)=\"onItemOpened($event)\">\n </s-thumbnail-item>\n</div>\n",
19828
+ template: "<div class=\"thumbnails\">\n <s-thumbnail-item\n *ngFor=\"let item of items\"\n [combineCheckboxEvent]=\"combineCheckboxEvent\"\n [itemData]=\"item\"\n [isCheckable]=\"selectable\"\n [isChecked]=\"isSelected(item)\"\n (checked)=\"onItemSelected($event)\"\n (opened)=\"onItemOpened($event)\">\n </s-thumbnail-item>\n</div>\n",
19823
19829
  styles: [".thumbnails{display:-ms-flexbox;display:flex;-ms-flex-wrap:wrap;flex-wrap:wrap;gap:12px}"]
19824
19830
  })
19825
19831
  ], ThumbnailsComponent);
@@ -19830,6 +19836,7 @@
19830
19836
  function ThumbnailItemComponent() {
19831
19837
  this.isCheckable = true;
19832
19838
  this.isChecked = false;
19839
+ this.combineCheckboxEvent = true;
19833
19840
  this.checked = new core.EventEmitter();
19834
19841
  this.opened = new core.EventEmitter();
19835
19842
  }
@@ -19840,13 +19847,19 @@
19840
19847
  ThumbnailItemComponent.prototype.onClick = function () {
19841
19848
  this.opened.emit(this.itemData);
19842
19849
  };
19850
+ ThumbnailItemComponent.prototype.checkboxClick = function (event) {
19851
+ if (this.combineCheckboxEvent) {
19852
+ return;
19853
+ }
19854
+ event.stopPropagation();
19855
+ };
19843
19856
  ThumbnailItemComponent.prototype._createFormGroup = function () {
19844
19857
  var _this = this;
19845
19858
  this.checkboxFormGroup = new forms.FormGroup({
19846
19859
  checkbox: new forms.FormControl({ checked: this.isChecked }),
19847
19860
  });
19848
19861
  this.checkboxFormGroup.get("checkbox").valueChanges.subscribe(function (value) {
19849
- _this.checked.emit({ item: _this.itemData, checked: value.checked });
19862
+ _this.checked.emit({ item: _this.itemData, selected: value.checked });
19850
19863
  });
19851
19864
  };
19852
19865
  ThumbnailItemComponent.prototype._validateItemData = function () {
@@ -19863,6 +19876,9 @@
19863
19876
  __decorate([
19864
19877
  core.Input()
19865
19878
  ], ThumbnailItemComponent.prototype, "isChecked", void 0);
19879
+ __decorate([
19880
+ core.Input()
19881
+ ], ThumbnailItemComponent.prototype, "combineCheckboxEvent", void 0);
19866
19882
  __decorate([
19867
19883
  core.Output()
19868
19884
  ], ThumbnailItemComponent.prototype, "checked", void 0);
@@ -19872,7 +19888,7 @@
19872
19888
  ThumbnailItemComponent = __decorate([
19873
19889
  core.Component({
19874
19890
  selector: "s-thumbnail-item",
19875
- template: "<button *ngIf=\"itemData\" class=\"thumbnail-item\" (click)=\"onClick()\">\n <div class=\"thumbnail-item-content\">\n <div class=\"content\">\n <ng-container *ngIf=\"itemData.type === 'video'\">\n <s-thumbnail-item-video\n [imageUrl]=\"itemData.imageUrl\"\n [videoUrl]=\"itemData.videoUrl\">\n </s-thumbnail-item-video>\n </ng-container>\n <ng-container *ngIf=\"itemData.type === 'image'\">\n <s-thumbnail-item-image [imageUrl]=\"itemData.imageUrl\"></s-thumbnail-item-image>\n </ng-container>\n <ng-container *ngIf=\"itemData.type === 'audio'\">\n <i class=\"icon fas fa-volume-down\"></i>\n <span class=\"label\">{{ \"platform.angular_components.listen\" | translate }}</span>\n </ng-container>\n <ng-container *ngIf=\"itemData.type === 'file'\">\n <i class=\"icon fas fa-file-alt\"></i>\n <span class=\"label\">{{ \"platform.angular_components.view\" | translate }}</span>\n </ng-container>\n </div>\n <form *ngIf=\"isCheckable\" [formGroup]=\"checkboxFormGroup\" class=\"checkbox\">\n <s-checkbox [data]=\"{ label: '' }\" formControlName=\"checkbox\"> </s-checkbox>\n </form>\n </div>\n <span class=\"file-name-label\">{{ itemData.fileName }}</span>\n</button>\n",
19891
+ template: "<button *ngIf=\"itemData\" class=\"thumbnail-item\" (click)=\"onClick()\">\n <div class=\"thumbnail-item-content\">\n <div class=\"content\">\n <ng-container *ngIf=\"itemData.type === 'video'\">\n <s-thumbnail-item-video\n [imageUrl]=\"itemData.imageUrl\"\n [videoUrl]=\"itemData.videoUrl\">\n </s-thumbnail-item-video>\n </ng-container>\n <ng-container *ngIf=\"itemData.type === 'image'\">\n <s-thumbnail-item-image [imageUrl]=\"itemData.imageUrl\"></s-thumbnail-item-image>\n </ng-container>\n <ng-container *ngIf=\"itemData.type === 'audio'\">\n <i class=\"icon fas fa-volume-down\"></i>\n <span class=\"label\">{{ \"platform.angular_components.listen\" | translate }}</span>\n </ng-container>\n <ng-container *ngIf=\"itemData.type === 'file'\">\n <i class=\"icon fas fa-file-alt\"></i>\n <span class=\"label\">{{ \"platform.angular_components.view\" | translate }}</span>\n </ng-container>\n </div>\n <form *ngIf=\"isCheckable\" [formGroup]=\"checkboxFormGroup\" class=\"checkbox\">\n <s-checkbox [data]=\"{ label: '' }\" formControlName=\"checkbox\" (click)=\"checkboxClick($event)\"></s-checkbox>\n </form>\n </div>\n <span class=\"file-name-label\">{{ itemData.fileName }}</span>\n</button>\n",
19876
19892
  styles: [".thumbnail-item{-ms-flex-align:center;align-items:center;background:0 0;border:none;cursor:pointer;display:-ms-inline-flexbox;display:inline-flex;-ms-flex-direction:column;flex-direction:column;-ms-flex-pack:center;justify-content:center;overflow:hidden;width:100px}.thumbnail-item-content{-ms-flex-align:center;align-items:center;background-image:linear-gradient(to top right,#5288b6,#00c89a);border-radius:8px;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;height:100px;-ms-flex-pack:center;justify-content:center;position:relative;-webkit-user-select:none;-ms-user-select:none;user-select:none;width:100%;overflow:hidden}.thumbnail-item-content .checkbox{position:absolute;right:8px;top:8px}.thumbnail-item-content .content{-ms-flex-align:center;align-items:center;color:#fff;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;gap:4px;overflow:hidden;width:100%}.thumbnail-item-content .content .icon{font-size:24px}.thumbnail-item-content .content .label{font-size:12px;width:100%;padding:0 8px;overflow:hidden;text-overflow:ellipsis}.thumbnail-item:hover{transform:scale(1.05);transition:.2s ease-in-out}.thumbnail-item .file-name-label{color:#525966;font-family:\"Open Sans\",sans-serif;font-size:12px;overflow:hidden;text-align:center;text-overflow:ellipsis;text-wrap:nowrap;-webkit-user-select:none;-ms-user-select:none;user-select:none;width:100%}"]
19877
19893
  })
19878
19894
  ], ThumbnailItemComponent);