@recursyve/nice-ui-kit.v2 14.0.0-beta.112 → 14.0.0-beta.113

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.
@@ -1841,7 +1841,10 @@ class NiceAssetsCarouselComponent {
1841
1841
  this.activeAsset = index;
1842
1842
  }
1843
1843
  async onFilesChange(event) {
1844
- const files = event.target?.files;
1844
+ let files = event.target?.files;
1845
+ if (this.imagesProcessor) {
1846
+ files = await this.getProcessedFiles(files);
1847
+ }
1845
1848
  await this.onFilesDrop(files);
1846
1849
  this.inputElement.nativeElement.value = "";
1847
1850
  }
@@ -1893,9 +1896,15 @@ class NiceAssetsCarouselComponent {
1893
1896
  await this._activeVideoElement.nativeElement.play();
1894
1897
  await this._assetsElement.get(this._active).nativeElement.firstElementChild.play();
1895
1898
  }
1899
+ async getProcessedFiles(files) {
1900
+ try {
1901
+ return await this.imagesProcessor(files);
1902
+ }
1903
+ catch (e) { }
1904
+ }
1896
1905
  }
1897
1906
  NiceAssetsCarouselComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.3", ngImport: i0, type: NiceAssetsCarouselComponent, deps: [{ token: NICE_ASSETS_CAROUSEL_OPTIONS, optional: true }], target: i0.ɵɵFactoryTarget.Component });
1898
- NiceAssetsCarouselComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.3", type: NiceAssetsCarouselComponent, selector: "nice-assets-carousel", inputs: { color: "color", edit: "edit", accept: "accept", customActions: "customActions", multipleUpload: "multipleUpload", visiblePreviewAsset: "visiblePreviewAsset", showAddAssetContainer: "showAddAssetContainer", assets: "assets" }, outputs: { activeChange: "activeChange", removedAsset: "removedAsset" }, providers: [
1907
+ NiceAssetsCarouselComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.3", type: NiceAssetsCarouselComponent, selector: "nice-assets-carousel", inputs: { color: "color", edit: "edit", accept: "accept", customActions: "customActions", imagesProcessor: "imagesProcessor", multipleUpload: "multipleUpload", visiblePreviewAsset: "visiblePreviewAsset", showAddAssetContainer: "showAddAssetContainer", assets: "assets" }, outputs: { activeChange: "activeChange", removedAsset: "removedAsset" }, providers: [
1899
1908
  {
1900
1909
  provide: NG_VALUE_ACCESSOR,
1901
1910
  useExisting: forwardRef(() => NiceAssetsCarouselComponent),
@@ -1927,6 +1936,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.3", ngImpor
1927
1936
  type: Input
1928
1937
  }], customActions: [{
1929
1938
  type: Input
1939
+ }], imagesProcessor: [{
1940
+ type: Input
1930
1941
  }], multipleUpload: [{
1931
1942
  type: Input
1932
1943
  }], visiblePreviewAsset: [{