@colijnit/sharedcomponents 261.20.1 → 262.1.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.
package/index.d.ts CHANGED
@@ -56,7 +56,7 @@ import { Form } from '@colijnit/mainapi/build/model/form.bo';
56
56
  import { FormResponse } from '@colijnit/mainapi/build/model/form-response.bo';
57
57
  import { SafeHtml, DomSanitizer } from '@angular/platform-browser';
58
58
  import * as i3 from '@colijnit/corecomponents_v12';
59
- import { BaseModuleScreenConfigService, CoreDialogService, OverlayService, ScreenConfigAdapterComponent, FormComponent, PromptService, FormMasterService, IconCacheService as IconCacheService$1, ColorSequenceService, IconListItem } from '@colijnit/corecomponents_v12';
59
+ import { BaseModuleScreenConfigService, SimpleGridColumnTemplateType, CoreDialogService, OverlayService, ScreenConfigAdapterComponent, FormComponent, PromptService, FormMasterService, IconCacheService as IconCacheService$1, ColorSequenceService, IconListItem } from '@colijnit/corecomponents_v12';
60
60
  import { SendMethodType } from '@colijnit/mainapi/build/enum/send-method-type.enum';
61
61
  import { PrintStockStickers as PrintStockStickers$1 } from '@colijnit/articleapi/build/model/print-stock-stickers';
62
62
  import { PrintPriceStickers } from '@colijnit/sharedapi/build/model/print-price-stickers.bo';
@@ -699,6 +699,7 @@ declare enum SharedCfgName {
699
699
 
700
700
  declare class StockTabComponent {
701
701
  readonly sharedCfgName: typeof SharedCfgName;
702
+ readonly SimpleGridColumnTemplateType: typeof SimpleGridColumnTemplateType;
702
703
  articleStockInformation: ArticleStock$1[];
703
704
  locationClicked: EventEmitter<string>;
704
705
  onLocationClick(data: ArticleStock$1): void;
@@ -806,6 +807,7 @@ declare class StockLocationComponent extends BaseStockComponent implements OnIni
806
807
  private _stockService;
807
808
  private _changeDetector;
808
809
  readonly icons: typeof Icon;
810
+ readonly SimpleGridColumnTemplateType: typeof SimpleGridColumnTemplateType;
809
811
  set warehouseNo(value: number);
810
812
  get warehouseNo(): number;
811
813
  articleStockInformation: ArticleStock$1[];
@@ -867,6 +869,7 @@ declare class StockHistoryComponent extends BaseStockComponent {
867
869
  iconCacheService: IconCacheService;
868
870
  private _stockService;
869
871
  readonly icons: typeof Icon;
872
+ readonly SimpleGridColumnTemplateType: typeof SimpleGridColumnTemplateType;
870
873
  stockHistoryInformation: StockHistoryBo[];
871
874
  articleGoodId: string;
872
875
  data: StockHistoryBo[];
@@ -879,6 +882,7 @@ declare class StockHistoryComponent extends BaseStockComponent {
879
882
  declare class OrderSupplyStockHistoryComponent extends BaseStockComponent {
880
883
  private _stockService;
881
884
  readonly icons: typeof Icon;
885
+ readonly SimpleGridColumnTemplateType: typeof SimpleGridColumnTemplateType;
882
886
  data: StockHistoryBo[];
883
887
  constructor(_stockService: StockService);
884
888
  protected getData(): Promise<void>;
@@ -889,6 +893,7 @@ declare class OrderSupplyStockHistoryComponent extends BaseStockComponent {
889
893
  declare class OrderCommissionStockHistoryComponent extends BaseStockComponent {
890
894
  private _stockService;
891
895
  readonly icons: typeof Icon;
896
+ readonly SimpleGridColumnTemplateType: typeof SimpleGridColumnTemplateType;
892
897
  data: StockHistoryBo[];
893
898
  constructor(_stockService: StockService);
894
899
  protected getData(): Promise<void>;
@@ -899,6 +904,7 @@ declare class OrderCommissionStockHistoryComponent extends BaseStockComponent {
899
904
  declare class OrderStockHistoryComponent extends BaseStockComponent {
900
905
  private _stockService;
901
906
  readonly icons: typeof Icon;
907
+ readonly SimpleGridColumnTemplateType: typeof SimpleGridColumnTemplateType;
902
908
  data: StockHistoryBo[];
903
909
  constructor(_stockService: StockService);
904
910
  protected getData(): Promise<void>;
@@ -916,6 +922,7 @@ declare class AllocationStockHistoryComponent extends BaseStockComponent {
916
922
  private _stockService;
917
923
  sharedEventService: SharedEventService;
918
924
  readonly icons: typeof Icon;
925
+ readonly SimpleGridColumnTemplateType: typeof SimpleGridColumnTemplateType;
919
926
  data: StockHistoryBo[];
920
927
  constructor(_stockService: StockService, sharedEventService: SharedEventService);
921
928
  protected getData(): Promise<void>;
@@ -961,6 +968,7 @@ declare class StockLocationPopupComponent {
961
968
  stockLocations: StockLocation[];
962
969
  stockStatus: StockStatus[];
963
970
  stockBelow: boolean;
971
+ validationMessage: string;
964
972
  constructor(iconCacheService: IconCacheService, _stockService: StockService, _changeDetector: ChangeDetectorRef);
965
973
  statusForId(id: number): 0 | StockStatus;
966
974
  handleStockStatusChange(status: StockStatus): void;
@@ -974,6 +982,7 @@ declare class StockLocationPopupComponent {
974
982
  locationChanged(event: StockLocation): void;
975
983
  handleStockChange(): void;
976
984
  newDate(): Date;
985
+ private validateForm;
977
986
  static ɵfac: i0.ɵɵFactoryDeclaration<StockLocationPopupComponent, never>;
978
987
  static ɵcmp: i0.ɵɵComponentDeclaration<StockLocationPopupComponent, "co-stock-location-popup", never, { "editingRow": { "alias": "editingRow"; "required": false; }; "showConfirmationDialog": { "alias": "showConfirmationDialog"; "required": false; }; "newStockLine": { "alias": "newStockLine"; "required": false; }; "deleteStockLine": { "alias": "deleteStockLine"; "required": false; }; "selectedArticleDetailsData": { "alias": "selectedArticleDetailsData"; "required": false; }; "articleFlat": { "alias": "articleFlat"; "required": false; }; "articleDetailsInformation": { "alias": "articleDetailsInformation"; "required": false; }; "selectedWarehouse": { "alias": "selectedWarehouse"; "required": false; }; "selectedLocationNo": { "alias": "selectedLocationNo"; "required": false; }; "articleStockInfo": { "alias": "articleStockInfo"; "required": false; }; "stockLocations": { "alias": "stockLocations"; "required": false; }; "stockStatus": { "alias": "stockStatus"; "required": false; }; }, { "togglePopupEvent": "togglePopupEvent"; "saveEvent": "saveEvent"; "updateGridData": "updateGridData"; }, never, never, false, never>;
979
988
  }
@@ -2495,14 +2504,15 @@ declare abstract class BaseFileUploadComponent implements ScreenConfigAdapterCom
2495
2504
  documentChangeEvent: EventEmitter<CoDocument>;
2496
2505
  popupOpenedStateChange: EventEmitter<boolean>;
2497
2506
  hidden: boolean;
2498
- onDrop(event: DragEvent): void;
2499
- onDragEnd(event: DragEvent): void;
2500
- onDragOver(event: DragEvent): void;
2501
- onDragEnter(event: DragEvent): void;
2502
- onDragLeave(event: DragEvent): void;
2503
2507
  documentUnderEdit: CoDocument;
2504
2508
  acceptedUploadFormats: string;
2509
+ uploadFeedbackMessage: string;
2510
+ uploadFeedbackVisible: boolean;
2511
+ showResizeDialog: boolean;
2512
+ resizeDialogMessage: string;
2513
+ resizeDialogCanSave: boolean;
2505
2514
  protected _maxUploadFileSize: number;
2515
+ protected readonly _resizeTargetBytes: number;
2506
2516
  private _dragEnterTarget;
2507
2517
  private _documentKey;
2508
2518
  private _dropZone;
@@ -2510,22 +2520,46 @@ declare abstract class BaseFileUploadComponent implements ScreenConfigAdapterCom
2510
2520
  private _docChangeSub;
2511
2521
  private _popupCloseSub;
2512
2522
  private _readonly;
2523
+ private _uploadFeedbackTimeout;
2524
+ private _pendingResizeResolver;
2513
2525
  constructor(_dictionaryService: SharedComponentsDictionaryService, _container: ViewContainerRef, _factory: ComponentFactoryResolver);
2514
2526
  ngOnDestroy(): void;
2527
+ onDrop(event: DragEvent): Promise<void>;
2528
+ onDragEnd(event: DragEvent): void;
2529
+ onDragOver(event: DragEvent): void;
2530
+ onDragEnter(event: DragEvent): void;
2531
+ onDragLeave(event: DragEvent): void;
2515
2532
  private _showDropzone;
2516
2533
  private _clearDropzone;
2517
2534
  handleDelete(file: CoDocument): Promise<boolean>;
2518
2535
  private _delete;
2519
2536
  handleSortingChange(docs: CoDocument[]): void;
2520
2537
  handleFileChange(event: any): Promise<void>;
2538
+ filesPicked(files: FileList): Promise<void>;
2539
+ private _processIncomingFiles;
2540
+ protected _prepareFilesForUpload(files: File[]): Promise<File[]>;
2521
2541
  handleEditDocumentClick(docToEdit: CoDocument): Promise<void>;
2522
2542
  openPopup(): Promise<void>;
2523
2543
  openPopupToAddDocumentByUrl(): void;
2524
2544
  private _createDocumentToAddByUrl;
2525
2545
  private _createAndFillPopupInstance;
2526
2546
  protected convertFilesIntoCoDocuments(files: FileList): Promise<CoDocument[]>;
2527
- filesPicked(files: FileList): Promise<void>;
2547
+ protected convertFileArrayIntoCoDocuments(files: File[]): Promise<CoDocument[]>;
2528
2548
  handleAcceptedFileTypesLoaded(value: FileType$1): void;
2549
+ protected showUploadFeedback(message: string): void;
2550
+ protected clearUploadFeedback(): void;
2551
+ protected getTooLargeMessage(file: File): string;
2552
+ protected getUnsupportedExtensionMessage(file: File, allowedExtensions?: string[]): string | null;
2553
+ protected getMaxUploadSizeInMb(): string;
2554
+ protected askResizeForImage(file: File): Promise<boolean>;
2555
+ handleResizeDialogSave(): void;
2556
+ handleResizeDialogClose(): void;
2557
+ private closeResizeDialog;
2558
+ protected resizeImageToUploadLimit(file: File): Promise<File>;
2559
+ protected resizeImage(file: File, maxWidth: number, maxHeight: number, quality: number): Promise<File>;
2560
+ protected readFileAsDataUrl(file: File): Promise<string>;
2561
+ protected loadImage(src: string): Promise<HTMLImageElement>;
2562
+ protected getResizedFileName(originalName: string, mimeType: string): string;
2529
2563
  private _getFileAsDocument;
2530
2564
  private _setInternalParamObj;
2531
2565
  private _lockDocument;
@@ -2538,6 +2572,7 @@ declare abstract class BaseFileUploadComponent implements ScreenConfigAdapterCom
2538
2572
  declare class FilesUploadComponent extends BaseFileUploadComponent implements OnDestroy {
2539
2573
  protected _container: ViewContainerRef;
2540
2574
  protected _factory: ComponentFactoryResolver;
2575
+ iconCacheService: IconCacheService;
2541
2576
  icon: typeof Icon;
2542
2577
  set dropzone(value: boolean);
2543
2578
  slideoutTemplate: TemplateRef<any>;
@@ -2558,7 +2593,7 @@ declare class FilesUploadComponent extends BaseFileUploadComponent implements On
2558
2593
  mouseOverAdd: boolean;
2559
2594
  slideoutShown: boolean;
2560
2595
  isDropzone: boolean;
2561
- constructor(dictionaryService: SharedComponentsDictionaryService, _container: ViewContainerRef, _factory: ComponentFactoryResolver);
2596
+ constructor(dictionaryService: SharedComponentsDictionaryService, _container: ViewContainerRef, _factory: ComponentFactoryResolver, iconCacheService: IconCacheService);
2562
2597
  ngOnDestroy(): void;
2563
2598
  openFileBrowser(): Promise<void>;
2564
2599
  handleAddClick(): void;
@@ -2876,7 +2911,7 @@ declare class AppFileDropzoneModule {
2876
2911
 
2877
2912
  declare class FilesUploadModule {
2878
2913
  static ɵfac: i0.ɵɵFactoryDeclaration<FilesUploadModule, never>;
2879
- static ɵmod: i0.ɵɵNgModuleDeclaration<FilesUploadModule, [typeof FilesUploadComponent], [typeof i3.CoDialogModule, typeof i3.FormModule, typeof i3.InputTextModule, typeof i3.ScreenConfigurationModule, typeof i3.ButtonModule, typeof SharedComponentsTranslationModule, typeof i3.IconModule, typeof ImageDisplayModule, typeof i2.CommonModule, typeof i3.InputCheckboxModule, typeof FileUploadModule, typeof FileUploadPopupModule, typeof AppFileDropzoneModule, typeof i3.DragDropModule], [typeof FilesUploadComponent]>;
2914
+ static ɵmod: i0.ɵɵNgModuleDeclaration<FilesUploadModule, [typeof FilesUploadComponent], [typeof i3.CoDialogModule, typeof i3.FormModule, typeof i3.InputTextModule, typeof i3.ScreenConfigurationModule, typeof i3.ButtonModule, typeof SharedComponentsTranslationModule, typeof i3.IconModule, typeof ImageDisplayModule, typeof i2.CommonModule, typeof i3.InputCheckboxModule, typeof FileUploadModule, typeof FileUploadPopupModule, typeof AppFileDropzoneModule, typeof i3.DragDropModule, typeof SimpleTagsFormModule, typeof SimpleTagsRecentModule], [typeof FilesUploadComponent]>;
2880
2915
  static ɵinj: i0.ɵɵInjectorDeclaration<FilesUploadModule>;
2881
2916
  }
2882
2917
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@colijnit/sharedcomponents",
3
- "version": "261.20.1",
3
+ "version": "262.1.0",
4
4
  "private": false,
5
5
  "dependencies": {
6
6
  "chart.js": "4.3.0",
@@ -10,12 +10,12 @@
10
10
  "peerDependencies": {
11
11
  "@angular/common": "^20.3.16",
12
12
  "@angular/core": "^20.3.16",
13
- "@colijnit/articleapi": ">=261.1.0",
14
- "@colijnit/mainapi": ">=261.1.0",
15
- "@colijnit/corecomponents_v12": ">=261.20.0",
16
- "@colijnit/ioneconnector": ">=261.1.0",
13
+ "@colijnit/articleapi": ">=262.1.0",
14
+ "@colijnit/mainapi": ">=262.1.1",
15
+ "@colijnit/corecomponents_v12": ">=262.1.0",
16
+ "@colijnit/ioneconnector": ">=262.1.0",
17
17
  "@colijnit/sharedapi": ">=1.0.20",
18
- "@colijnit/relationapi": ">=261.1.0",
18
+ "@colijnit/relationapi": ">=262.1.0",
19
19
  "html-to-image": "^1.11.11",
20
20
  "jspdf": "^4.0.0",
21
21
  "jspdf-autotable": "5.0.7",