@pepperi-addons/ngx-lib 0.3.15-beta.6 → 0.3.15-beta.9
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/bundles/pepperi-addons-ngx-lib-color.umd.js +4 -1
- package/bundles/pepperi-addons-ngx-lib-color.umd.js.map +1 -1
- package/bundles/pepperi-addons-ngx-lib-dialog.umd.js +14 -5
- package/bundles/pepperi-addons-ngx-lib-dialog.umd.js.map +1 -1
- package/bundles/pepperi-addons-ngx-lib-images-filmstrip.umd.js +12 -3
- package/bundles/pepperi-addons-ngx-lib-images-filmstrip.umd.js.map +1 -1
- package/bundles/pepperi-addons-ngx-lib-list.umd.js +1 -1
- package/bundles/pepperi-addons-ngx-lib-list.umd.js.map +1 -1
- package/bundles/pepperi-addons-ngx-lib-profile-data-views-list.umd.js +1 -1
- package/bundles/pepperi-addons-ngx-lib-profile-data-views-list.umd.js.map +1 -1
- package/bundles/pepperi-addons-ngx-lib-remote-loader.umd.js +24 -7
- package/bundles/pepperi-addons-ngx-lib-remote-loader.umd.js.map +1 -1
- package/bundles/pepperi-addons-ngx-lib-signature.umd.js +4 -1
- package/bundles/pepperi-addons-ngx-lib-signature.umd.js.map +1 -1
- package/bundles/pepperi-addons-ngx-lib-textarea.umd.js +1 -1
- package/bundles/pepperi-addons-ngx-lib-textarea.umd.js.map +1 -1
- package/bundles/pepperi-addons-ngx-lib.umd.js +3 -0
- package/bundles/pepperi-addons-ngx-lib.umd.js.map +1 -1
- package/color/color-picker.component.d.ts +1 -0
- package/color/pepperi-addons-ngx-lib-color.metadata.json +1 -1
- package/core/customization/customization.service.d.ts +1 -0
- package/dialog/default-dialog.component.d.ts +1 -0
- package/dialog/dialog.component.d.ts +4 -0
- package/dialog/pepperi-addons-ngx-lib-dialog.metadata.json +1 -1
- package/esm2015/color/color-picker.component.js +5 -2
- package/esm2015/core/customization/customization.service.js +4 -1
- package/esm2015/dialog/default-dialog.component.js +5 -2
- package/esm2015/dialog/dialog.component.js +11 -5
- package/esm2015/dialog/dialog.model.js +2 -2
- package/esm2015/images-filmstrip/images-filmstrip.component.js +13 -4
- package/esm2015/list/list.component.js +2 -2
- package/esm2015/profile-data-views-list/profile-data-views-list.component.js +2 -2
- package/esm2015/remote-loader/addon-block-loader.component.js +16 -4
- package/esm2015/remote-loader/remote-loader.service.js +6 -5
- package/esm2015/signature/signature.component.js +5 -2
- package/esm2015/textarea/textarea.component.js +2 -2
- package/fesm2015/pepperi-addons-ngx-lib-color.js +4 -1
- package/fesm2015/pepperi-addons-ngx-lib-color.js.map +1 -1
- package/fesm2015/pepperi-addons-ngx-lib-dialog.js +15 -6
- package/fesm2015/pepperi-addons-ngx-lib-dialog.js.map +1 -1
- package/fesm2015/pepperi-addons-ngx-lib-images-filmstrip.js +12 -3
- package/fesm2015/pepperi-addons-ngx-lib-images-filmstrip.js.map +1 -1
- package/fesm2015/pepperi-addons-ngx-lib-list.js +1 -1
- package/fesm2015/pepperi-addons-ngx-lib-list.js.map +1 -1
- package/fesm2015/pepperi-addons-ngx-lib-profile-data-views-list.js +1 -1
- package/fesm2015/pepperi-addons-ngx-lib-profile-data-views-list.js.map +1 -1
- package/fesm2015/pepperi-addons-ngx-lib-remote-loader.js +20 -7
- package/fesm2015/pepperi-addons-ngx-lib-remote-loader.js.map +1 -1
- package/fesm2015/pepperi-addons-ngx-lib-signature.js +4 -1
- package/fesm2015/pepperi-addons-ngx-lib-signature.js.map +1 -1
- package/fesm2015/pepperi-addons-ngx-lib-textarea.js +1 -1
- package/fesm2015/pepperi-addons-ngx-lib-textarea.js.map +1 -1
- package/fesm2015/pepperi-addons-ngx-lib.js +3 -0
- package/fesm2015/pepperi-addons-ngx-lib.js.map +1 -1
- package/images-filmstrip/images-filmstrip.component.d.ts +2 -0
- package/images-filmstrip/pepperi-addons-ngx-lib-images-filmstrip.metadata.json +1 -1
- package/list/pepperi-addons-ngx-lib-list.metadata.json +1 -1
- package/package.json +1 -1
- package/pepperi-addons-ngx-lib.metadata.json +1 -1
- package/profile-data-views-list/pepperi-addons-ngx-lib-profile-data-views-list.metadata.json +1 -1
- package/remote-loader/addon-block-loader.component.d.ts +6 -1
- package/remote-loader/pepperi-addons-ngx-lib-remote-loader.metadata.json +1 -1
- package/signature/pepperi-addons-ngx-lib-signature.metadata.json +1 -1
- package/signature/signature.component.d.ts +1 -0
- package/src/core/style/abstracts/variables.scss +1 -0
- package/src/core/style/base/base.scss +2 -0
- package/textarea/pepperi-addons-ngx-lib-textarea.metadata.json +1 -1
|
@@ -173,12 +173,15 @@
|
|
|
173
173
|
// this.notify.emit({ key: this.key, value: color });
|
|
174
174
|
this.dialogRef.close(color);
|
|
175
175
|
};
|
|
176
|
+
PepColorPickerComponent.prototype.closeDialog = function (event) {
|
|
177
|
+
this.dialogRef.close(event);
|
|
178
|
+
};
|
|
176
179
|
return PepColorPickerComponent;
|
|
177
180
|
}());
|
|
178
181
|
PepColorPickerComponent.CURRENT_HUE = '--pep-color-picker-current-hue';
|
|
179
182
|
PepColorPickerComponent.decorators = [
|
|
180
183
|
{ type: core.Component, args: [{
|
|
181
|
-
template: "<div class=\"pep-color-picker-container\">\n <pep-dialog [title]=\"'COLOR.DIALOG_TITLE' | translate\">\n <ng-container pep-dialog-content>\n <div class=\"color-chooser-content\">\n <div class=\"current-color\" [ngStyle]=\"{ 'background': data?.value ? data.value : 'transparent' }\"></div>\n\n <pep-slider class=\"slider-box\" [label]=\"'COLOR.CHANGE_HUE' | translate\" [minValue]=\"currentHueMin\"\n [maxValue]=\"currentHueMax\" [value]=\"currentHue\" [background]=\"currentHueBackground\"\n (valueChange)=\"onHueChange($event)\">\n </pep-slider>\n <pep-slider class=\"slider-box\" [label]=\"'COLOR.CHANGE_SATURATION' | translate\"\n [minValue]=\"currentSaturationMin\" [maxValue]=\"currentSaturationMax\" [value]=\"currentSaturation\"\n [background]=\"currentSaturationBackground\" (valueChange)=\"onSaturationChange($event)\">\n </pep-slider>\n <pep-slider class=\"slider-box\" [label]=\"'COLOR.CHANGE_LIGHTNESS' | translate\"\n [minValue]=\"currentLightnessMin\" [maxValue]=\"currentLightnessMax\"\n [value]=\"currentLightnessMax - currentLightness + currentLightnessMin\"\n [background]=\"currentLightnessBackground\" (valueChange)=\"onLightnessChange($event)\">\n </pep-slider>\n </div>\n <div class=\"color-value-content\">\n <div class=\"color-value\" [ngClass]=\"{ 'with-complient': checkAAComplient }\">\n <pep-textbox [key]=\"'colorValue'\" [label]=\"'COLOR.ADD_VALUE_HERE' | translate \"\n [formattedValue]=\"data?.value\" [value]=\"data?.value\" (valueChange)=\"onColorValueChange($event)\">\n </pep-textbox>\n </div>\n <div *ngIf=\"checkAAComplient\" class=\"color-complient-container\">\n <pep-field-title [label]=\"'COLOR.AA_COMPLIENT' | translate \">\n </pep-field-title>\n <div class=\"color-complient\" [ngStyle]=\"{ 'background': complientColor }\">\n <mat-icon *ngIf=\"isUserChooseAAComplientColor\">\n <pep-icon name=\"system_ok\">\n </pep-icon>\n </mat-icon>\n </div>\n </div>\n </div>\n </ng-container>\n <ng-container pep-dialog-actions>\n <div class=\"color-actions pep-spacing-element-negative\">\n <mat-checkbox *ngIf=\"data.showAAComplient\" class=\"pep-spacing-element\" type=\"checkbox\"\n id=\"checkAAComplient\" (change)=\"checkAAComplient = !checkAAComplient\" [checked]=\"checkAAComplient\">\n <span class=\"body-xs ellipsis\">{{ 'COLOR.AA_COMPLIENT' | translate }}</span>\n </mat-checkbox>\n <div>\n <button mat-button [mat-dialog-close]=\"null\" class=\"pep-spacing-element pep-button md weak\">\n {{'ACTIONS.CANCEL' | translate}}\n </button>\n <button mat-button class=\"pep-spacing-element pep-button md strong\" (click)=\"onSave($event)\">\n {{'ACTIONS.OK' | translate}}\n </button>\n </div>\n </div>\n </ng-container>\n </pep-dialog>\n</div>",
|
|
184
|
+
template: "<div class=\"pep-color-picker-container\">\n <pep-dialog [title]=\"'COLOR.DIALOG_TITLE' | translate\" (close)=\"closeDialog($event)\">\n <ng-container pep-dialog-content>\n <div class=\"color-chooser-content\">\n <div class=\"current-color\" [ngStyle]=\"{ 'background': data?.value ? data.value : 'transparent' }\"></div>\n\n <pep-slider class=\"slider-box\" [label]=\"'COLOR.CHANGE_HUE' | translate\" [minValue]=\"currentHueMin\"\n [maxValue]=\"currentHueMax\" [value]=\"currentHue\" [background]=\"currentHueBackground\"\n (valueChange)=\"onHueChange($event)\">\n </pep-slider>\n <pep-slider class=\"slider-box\" [label]=\"'COLOR.CHANGE_SATURATION' | translate\"\n [minValue]=\"currentSaturationMin\" [maxValue]=\"currentSaturationMax\" [value]=\"currentSaturation\"\n [background]=\"currentSaturationBackground\" (valueChange)=\"onSaturationChange($event)\">\n </pep-slider>\n <pep-slider class=\"slider-box\" [label]=\"'COLOR.CHANGE_LIGHTNESS' | translate\"\n [minValue]=\"currentLightnessMin\" [maxValue]=\"currentLightnessMax\"\n [value]=\"currentLightnessMax - currentLightness + currentLightnessMin\"\n [background]=\"currentLightnessBackground\" (valueChange)=\"onLightnessChange($event)\">\n </pep-slider>\n </div>\n <div class=\"color-value-content\">\n <div class=\"color-value\" [ngClass]=\"{ 'with-complient': checkAAComplient }\">\n <pep-textbox [key]=\"'colorValue'\" [label]=\"'COLOR.ADD_VALUE_HERE' | translate \"\n [formattedValue]=\"data?.value\" [value]=\"data?.value\" (valueChange)=\"onColorValueChange($event)\">\n </pep-textbox>\n </div>\n <div *ngIf=\"checkAAComplient\" class=\"color-complient-container\">\n <pep-field-title [label]=\"'COLOR.AA_COMPLIENT' | translate \">\n </pep-field-title>\n <div class=\"color-complient\" [ngStyle]=\"{ 'background': complientColor }\">\n <mat-icon *ngIf=\"isUserChooseAAComplientColor\">\n <pep-icon name=\"system_ok\">\n </pep-icon>\n </mat-icon>\n </div>\n </div>\n </div>\n </ng-container>\n <ng-container pep-dialog-actions>\n <div class=\"color-actions pep-spacing-element-negative\">\n <mat-checkbox *ngIf=\"data.showAAComplient\" class=\"pep-spacing-element\" type=\"checkbox\"\n id=\"checkAAComplient\" (change)=\"checkAAComplient = !checkAAComplient\" [checked]=\"checkAAComplient\">\n <span class=\"body-xs ellipsis\">{{ 'COLOR.AA_COMPLIENT' | translate }}</span>\n </mat-checkbox>\n <div>\n <button mat-button [mat-dialog-close]=\"null\" class=\"pep-spacing-element pep-button md weak\">\n {{'ACTIONS.CANCEL' | translate}}\n </button>\n <button mat-button class=\"pep-spacing-element pep-button md strong\" (click)=\"onSave($event)\">\n {{'ACTIONS.OK' | translate}}\n </button>\n </div>\n </div>\n </ng-container>\n </pep-dialog>\n</div>",
|
|
182
185
|
styles: [".mat-slider-horizontal .mat-slider-track-fill,.mat-slider-track-background{display:none}.pep-color-picker-container ::ng-deep.mat-dialog-content,.pepperi-color-picker-container ::ng-deep.mat-dialog-content{padding:.5rem .5rem 0;padding:var(--pep-spacing-sm,.5rem) var(--pep-spacing-sm,.5rem) 0}.pep-color-picker-container .color-chooser-content,.pepperi-color-picker-container .color-chooser-content{display:-ms-grid;display:grid;grid-template-columns:repeat(8,1fr);grid-template-rows:repeat(3,1fr);grid-column-gap:1.5rem;grid-column-gap:var(--pep-spacing-xl,1.5rem);grid-row-gap:.5rem;grid-row-gap:var(--pep-spacing-sm,.5rem);margin-top:.5rem;margin-top:var(--pep-spacing-sm,.5rem)}.pep-color-picker-container .color-chooser-content .current-color,.pepperi-color-picker-container .color-chooser-content .current-color{grid-row:1/span 3;grid-column:6/span 4;border-radius:.25rem;border-radius:var(--pep-border-radius-md,.25rem);width:9.25rem;height:9.25rem}.pep-color-picker-container .color-chooser-content .slider-box,.pepperi-color-picker-container .color-chooser-content .slider-box{grid-column:1/span 5}.pep-color-picker-container .color-value-content,.pepperi-color-picker-container .color-value-content{display:-ms-grid;display:grid;grid-template-columns:repeat(8,1fr);grid-template-rows:repeat(1,1fr);grid-column-gap:1.5rem;grid-column-gap:var(--pep-spacing-xl,1.5rem);grid-row-gap:.5rem;grid-row-gap:var(--pep-spacing-sm,.5rem);margin-top:1.5rem}.pep-color-picker-container .color-value-content .color-value,.pepperi-color-picker-container .color-value-content .color-value{grid-row:1/span 1;grid-column:1/span 9}.pep-color-picker-container .color-value-content .color-value.with-complient,.pepperi-color-picker-container .color-value-content .color-value.with-complient{grid-column:1/span 5}.pep-color-picker-container .color-value-content .color-complient-container,.pepperi-color-picker-container .color-value-content .color-complient-container{grid-column:6/span 4}.pep-color-picker-container .color-value-content .color-complient-container .color-complient,.pepperi-color-picker-container .color-value-content .color-complient-container .color-complient{display:flex;justify-content:center;align-items:center;border-radius:.25rem;border-radius:var(--pep-border-radius-md,.25rem);height:2.5rem;height:var(--pep-form-field-height,2.5rem);width:9.25rem}.pep-color-picker-container ::ng-deep.mat-dialog-actions,.pepperi-color-picker-container ::ng-deep.mat-dialog-actions{display:block}.pep-color-picker-container ::ng-deep.mat-dialog-actions .color-actions,.pepperi-color-picker-container ::ng-deep.mat-dialog-actions .color-actions{display:flex;justify-content:space-between;align-items:center}", ".pep-color-picker-container .color-value-content .color-complient-container .color-complient ::ng-deep.mat-icon .svg-icon,.pepperi-color-picker-container .color-value-content .color-complient-container .color-complient ::ng-deep.mat-icon .svg-icon{fill:#fff;fill:hsl(var(--pep-color-system-primary-invert-h,255),var(--pep-color-system-primary-invert-s,100%),var(--pep-color-system-primary-invert-l,100%))}"]
|
|
183
186
|
},] }
|
|
184
187
|
];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pepperi-addons-ngx-lib-color.umd.js","sources":["../../../projects/ngx-lib/color/color-picker.component.ts","../../../projects/ngx-lib/color/color.component.ts","../../../projects/ngx-lib/color/color.module.ts","../../../projects/ngx-lib/color/public-api.ts","../../../projects/ngx-lib/color/pepperi-addons-ngx-lib-color.ts"],"sourcesContent":["import { Component, OnInit, Inject } from '@angular/core';\nimport { MatDialogRef, MAT_DIALOG_DATA } from '@angular/material/dialog';\n// import {\n// hex2hsl,\n// hslString2hsl,\n// rgbString2hsl,\n// IPepHslColor,\n// findClosestAccessibleColor,\n// hsl2hex,\n// convertHslToStringHsl,\n// } from './color-utils';\nimport { PepColorService, IPepHslColor } from '@pepperi-addons/ngx-lib';\n\nimport { PepColorType } from './color.model';\n\nenum PepContrastRatioType {\n AA = 4.5,\n AAA = 7,\n}\n\ninterface IPepColorPickerDialogData {\n value: string;\n type: PepColorType;\n showAAComplient: boolean;\n textColor: string;\n contrastRatio: PepContrastRatioType;\n}\n\n@Component({\n templateUrl: './color-picker.component.html',\n styleUrls: ['./color-picker.component.scss', './color-picker.component.theme.scss'],\n})\nexport class PepColorPickerComponent implements OnInit {\n static CURRENT_HUE = '--pep-color-picker-current-hue';\n private readonly defaultColor = '#ccc';\n\n checkAAComplient = true;\n\n constructor(\n private colorService: PepColorService,\n private dialogRef: MatDialogRef<PepColorPickerComponent>,\n @Inject(MAT_DIALOG_DATA) public data: IPepColorPickerDialogData\n ) {\n this.data.type = data ? data.type : 'any';\n this.data.showAAComplient = !data\n ? false\n : data.showAAComplient ?? true;\n this.data.textColor = data && data.textColor ? data.textColor : '#fff';\n this.data.contrastRatio =\n data && data.contrastRatio\n ? data.contrastRatio\n : PepContrastRatioType.AA;\n }\n\n private defaultHueBackground = `linear-gradient(to right,\n hsl(0, 100%, 50%) 0%,\n hsl(60, 100%, 50%) 17%,\n hsl(120, 100%, 50%) 33%,\n hsl(180, 100%, 50%) 50%,\n hsl(240, 100%, 50%) 67%,\n hsl(300, 100%, 50%) 83%,\n hsl(360, 100%, 50%) 100%)`;\n\n currentHue = 100;\n currentHueMin = 0;\n currentHueMax = 360;\n currentHueBackground = this.defaultHueBackground;\n\n private defaultSaturationBackground = `linear-gradient(to right,\n hsl(var(--pep-color-picker-current-hue), 0.01%, 50%) 0%,\n hsl(var(--pep-color-picker-current-hue), 100%, 50%) 100%)`;\n\n currentSaturation = 50;\n currentSaturationMin = 0;\n currentSaturationMax = 100;\n currentSaturationBackground = this.defaultSaturationBackground;\n\n private defaultLightnessBackground = `linear-gradient(to right,\n hsl(var(--pep-color-picker-current-hue), 100%, 100%) 0%,\n hsl(var(--pep-color-picker-current-hue), 100%, 50%) 50%,\n hsl(var(--pep-color-picker-current-hue), 100%, 0.01%) 100%)`;\n\n currentLightness = 50;\n currentLightnessMin = 0;\n currentLightnessMax = 100;\n currentLightnessBackground = this.defaultLightnessBackground;\n\n complientColor: string;\n isUserChooseAAComplientColor: boolean;\n\n ngOnInit(): void {\n this.initVars();\n this.checkAAComplient = this.data.showAAComplient;\n this.convertValueStringToColor(this.data.value);\n }\n\n initVars(): void {\n if (this.data.type === 'main') {\n this.currentLightnessMax = 10;\n this.currentLightness = 5;\n this.currentHueBackground = this.defaultHueBackground;\n this.currentSaturationBackground = this.defaultSaturationBackground;\n this.currentLightnessBackground = this.defaultLightnessBackground;\n } else if (this.data.type === 'success') {\n this.currentHueMin = 70;\n this.currentHueMax = 150;\n this.currentHue = 100;\n\n this.currentSaturationMin = 50;\n this.currentSaturationMax = 100;\n this.currentSaturation = 50;\n\n this.currentLightnessMin = 10;\n this.currentLightnessMax = 65;\n this.currentLightness = 50;\n\n this.currentHueBackground = `linear-gradient(to right,\n hsl(70, 100%, 50%) 0%,\n hsl(150, 100%, 50%) 100%)`;\n this.currentSaturationBackground = `linear-gradient(to right,\n hsl(var(--pep-color-picker-current-hue), 50%, 50%) 50%,\n hsl(var(--pep-color-picker-current-hue), 100%, 50%) 100%)`;\n this.currentLightnessBackground = `linear-gradient(to right,\n hsl(var(--pep-color-picker-current-hue), 100%, 65%) 10%,\n hsl(var(--pep-color-picker-current-hue), 100%, 35%) 35%,\n hsl(var(--pep-color-picker-current-hue), 100%, 10%) 65%)`;\n\n } else if (this.data.type === 'caution') {\n this.currentHueMin = -20;\n this.currentHueMax = 20;\n this.currentHue = 10;\n\n this.currentSaturationMin = 75;\n this.currentSaturationMax = 100;\n this.currentSaturation = 75;\n\n this.currentLightnessMin = 25;\n this.currentLightnessMax = 75;\n this.currentLightness = 50;\n\n this.currentHueBackground = `linear-gradient(to right,\n hsl(340, 100%, 50%) 0%,\n hsl(20, 100%, 50%) 100%)`;\n this.currentSaturationBackground = `linear-gradient(to right,\n hsl(var(--pep-color-picker-current-hue), 75%, 50%) 75%,\n hsl(var(--pep-color-picker-current-hue), 100%, 50%) 100%)`;\n this.currentLightnessBackground = `linear-gradient(to right,\n hsl(var(--pep-color-picker-current-hue), 100%, 75%) 25%,\n hsl(var(--pep-color-picker-current-hue), 100%, 50%) 50%,\n hsl(var(--pep-color-picker-current-hue), 100%, 25%) 75%)`;\n }\n }\n\n setCurrentHueInCss(): void {\n document.documentElement.style.setProperty(\n PepColorPickerComponent.CURRENT_HUE,\n this.currentHue.toString()\n );\n }\n\n convertValueStringToColor(color): void {\n if (color.indexOf('hsl') === 0) {\n const hsl = this.colorService.hslString2hsl(color);\n this.convertColorToValueString(hsl);\n } else if (color.indexOf('rgb') === 0) {\n const hsl = this.colorService.rgbString2hsl(color);\n this.convertColorToValueString(hsl);\n } else if (color.indexOf('#') === 0) {\n const hsl = this.colorService.hex2hsl(color);\n this.convertColorToValueString(hsl);\n } else {\n // Handle default.\n const hsl = this.colorService.hex2hsl(this.defaultColor);\n this.convertColorToValueString(hsl);\n }\n\n this.setCurrentHueInCss();\n }\n\n convertColorToValueString(hslColor: IPepHslColor): void {\n // Regular hue\n if (\n hslColor.h >= this.currentHueMin &&\n hslColor.h <= this.currentHueMax\n ) {\n this.currentHue = hslColor.h;\n } else if (\n this.currentHueMin < 0 &&\n hslColor.h >= 0 &&\n hslColor.h <= 360\n ) {\n // For min with - (change to the other side of the circle)\n hslColor.h = hslColor.h - 360;\n\n if (\n hslColor.h >= this.currentHueMin &&\n hslColor.h <= this.currentHueMax\n ) {\n this.currentHue = hslColor.h;\n }\n }\n\n this.currentSaturation =\n hslColor.s >= this.currentSaturationMin &&\n hslColor.s <= this.currentSaturationMax\n ? hslColor.s\n : this.currentSaturation;\n\n this.currentLightness =\n hslColor.l >= this.currentLightnessMin &&\n hslColor.l <= this.currentLightnessMax\n ? hslColor.l\n : this.currentLightness;\n\n // Write the value (if hue is changed to the other side of the circle return it back).\n const hsl = {\n h: this.currentHue,\n s: this.currentSaturation,\n l: this.currentLightness,\n };\n this.data.value = this.colorService.convertHslToStringHsl(hsl);\n\n // Check the contrast ratio - set the closest accessible color to complientColor\n // and update isUserChooseAAComplientColor.\n const adjustableColor = this.colorService.hsl2hex(hsl);\n const closestHex = this.colorService.findClosestAccessibleColor(\n adjustableColor,\n this.data.textColor,\n this.data.contrastRatio\n );\n\n this.isUserChooseAAComplientColor = adjustableColor === closestHex;\n this.complientColor = this.colorService.convertHslToStringHsl(\n this.colorService.hex2hsl(closestHex)\n );\n }\n\n onHueChange(value): void {\n this.convertColorToValueString({ h: value });\n this.setCurrentHueInCss();\n }\n\n onSaturationChange(value): void {\n // this.currentSaturation = event.value;\n this.convertColorToValueString({ s: value });\n }\n\n onLightnessChange(value): void {\n // this.currentLightness = event.value;\n this.convertColorToValueString({\n l:\n this.currentLightnessMax -\n value +\n this.currentLightnessMin,\n });\n }\n\n onColorValueChange(event): void {\n this.convertValueStringToColor(event.value);\n }\n\n onSave(event): void {\n const color = this.checkAAComplient\n ? this.complientColor\n : this.data.value;\n\n // this.notify.emit({ key: this.key, value: color });\n this.dialogRef.close(color);\n }\n}\n","import {\n Component,\n OnInit,\n Input,\n Output,\n Renderer2,\n ElementRef,\n EventEmitter,\n OnChanges,\n OnDestroy,\n} from '@angular/core';\nimport {\n PepCustomizationService,\n PepLayoutType,\n PepHorizontalAlignment,\n DEFAULT_HORIZONTAL_ALIGNMENT,\n} from '@pepperi-addons/ngx-lib';\nimport { PepDialogService } from '@pepperi-addons/ngx-lib/dialog';\nimport { PepColorPickerComponent } from './color-picker.component';\nimport { PepColorType } from './color.model';\n\n@Component({\n selector: 'pep-color',\n templateUrl: './color.component.html',\n styleUrls: ['./color.component.scss'],\n})\nexport class PepColorComponent implements OnInit, OnDestroy {\n @Input() key = '';\n @Input() value = '';\n @Input() label = '';\n @Input() disabled = false;\n @Input() xAlignment: PepHorizontalAlignment = DEFAULT_HORIZONTAL_ALIGNMENT;\n @Input() rowSpan = 1;\n @Input() type: PepColorType = 'any';\n\n @Input() showTitle = true;\n @Input() renderTitle = true;\n\n @Input() showAAComplient = true;\n @Input() layoutType: PepLayoutType = 'form';\n\n @Output()\n valueChange: EventEmitter<string> = new EventEmitter<string>();\n\n constructor(\n private dialogService: PepDialogService,\n private renderer: Renderer2,\n private element: ElementRef\n ) { }\n\n ngOnInit(): void {\n this.renderer.addClass(\n this.element.nativeElement,\n PepCustomizationService.STAND_ALONE_FIELD_CLASS_NAME\n );\n\n if (!this.renderTitle) {\n this.renderer.addClass(\n this.element.nativeElement,\n PepCustomizationService.STAND_ALONE_FIELD_NO_SPACING_CLASS_NAME\n );\n }\n }\n\n ngOnDestroy(): void {\n //\n }\n\n changeColor(value: any): void {\n this.value = value;\n this.valueChange.emit(value);\n }\n\n chooseColor(): void {\n const dialogRef = this.dialogService.openDialog(\n PepColorPickerComponent,\n {\n value: this.value,\n type: this.type,\n showAAComplient: this.showAAComplient,\n }\n );\n\n dialogRef.afterClosed().subscribe((value) => {\n if (value !== undefined && value !== null) {\n this.changeColor(value);\n }\n });\n }\n}\n","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { ReactiveFormsModule } from '@angular/forms';\n\nimport { MatCommonModule } from '@angular/material/core';\nimport { MatButtonModule } from '@angular/material/button';\nimport { MatFormFieldModule } from '@angular/material/form-field';\nimport { MatCheckboxModule } from '@angular/material/checkbox';\nimport { MatDialogModule } from '@angular/material/dialog';\nimport { MatIconModule } from '@angular/material/icon';\nimport { MatSliderModule } from '@angular/material/slider';\n\nimport { PepNgxLibModule } from '@pepperi-addons/ngx-lib';\nimport { PepDialogModule } from '@pepperi-addons/ngx-lib/dialog';\nimport { PepSliderModule } from '@pepperi-addons/ngx-lib/slider';\n\nimport {\n PepIconModule,\n PepIconRegistry,\n pepIconSystemEdit,\n pepIconSystemOk,\n pepIconSystemClose,\n} from '@pepperi-addons/ngx-lib/icon';\nimport { PepFieldTitleModule } from '@pepperi-addons/ngx-lib/field-title';\nimport { PepTextboxModule } from '@pepperi-addons/ngx-lib/textbox';\n\nimport { PepColorComponent } from './color.component';\nimport { PepColorPickerComponent } from './color-picker.component';\n\n@NgModule({\n imports: [\n CommonModule,\n ReactiveFormsModule,\n // Material modules\n MatCommonModule,\n MatButtonModule,\n MatFormFieldModule,\n MatCheckboxModule,\n MatDialogModule,\n MatIconModule,\n MatSliderModule,\n // ngx-lib modules\n PepNgxLibModule,\n PepDialogModule,\n PepIconModule,\n PepSliderModule,\n PepFieldTitleModule,\n PepTextboxModule,\n ],\n exports: [PepColorComponent],\n declarations: [PepColorComponent, PepColorPickerComponent],\n entryComponents: [PepColorPickerComponent],\n})\nexport class PepColorModule {\n constructor(private pepIconRegistry: PepIconRegistry) {\n this.pepIconRegistry.registerIcons([\n pepIconSystemEdit,\n pepIconSystemOk,\n pepIconSystemClose,\n ]);\n }\n}\n","/*\n * Public API Surface of ngx-lib/color\n */\nexport * from './color.module';\nexport * from './color.model';\nexport * from './color.component';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n\nexport {PepColorPickerComponent as ɵa} from './color-picker.component';"],"names":["Component","PepColorService","MatDialogRef","Inject","MAT_DIALOG_DATA","DEFAULT_HORIZONTAL_ALIGNMENT","EventEmitter","PepCustomizationService","PepDialogService","Renderer2","ElementRef","Input","Output","pepIconSystemEdit","pepIconSystemOk","pepIconSystemClose","NgModule","CommonModule","ReactiveFormsModule","MatCommonModule","MatButtonModule","MatFormFieldModule","MatCheckboxModule","MatDialogModule","MatIconModule","MatSliderModule","PepNgxLibModule","PepDialogModule","PepIconModule","PepSliderModule","PepFieldTitleModule","PepTextboxModule","PepIconRegistry"],"mappings":";;;;;;IAeA,IAAK,oBAGJ;IAHD,WAAK,oBAAoB;QACrB,6DAAQ,CAAA;QACR,6DAAO,CAAA;IACX,CAAC,EAHI,oBAAoB,KAApB,oBAAoB,QAGxB;;QAoBG,iCACY,YAA6B,EAC7B,SAAg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AAiB;wBACjBC,sBAAe;wBACfC,oBAAa;wBACbC,sBAAe;;wBAEfC,sBAAe;wBACfC,wBAAe;wBACfC,kBAAa;wBACbC,wBAAe;wBACfC,8BAAmB;wBACnBC,wBAAgB;qBACnB;oBACD,OAAO,EAAE,CAAC,iBAAiB,CAAC;oBAC5B,YAAY,EAAE,CAAC,iBAAiB,EAAE,uBAAuB,CAAC;oBAC1D,eAAe,EAAE,CAAC,uBAAuB,CAAC;iBAC7C;;;gBAlCGC,oBAAe;;;IClBnB;;;;ICAA;;;;;;;;;;;;;;"}
|
|
1
|
+
{"version":3,"file":"pepperi-addons-ngx-lib-color.umd.js","sources":["../../../projects/ngx-lib/color/color-picker.component.ts","../../../projects/ngx-lib/color/color.component.ts","../../../projects/ngx-lib/color/color.module.ts","../../../projects/ngx-lib/color/public-api.ts","../../../projects/ngx-lib/color/pepperi-addons-ngx-lib-color.ts"],"sourcesContent":["import { Component, OnInit, Inject } from '@angular/core';\nimport { MatDialogRef, MAT_DIALOG_DATA } from '@angular/material/dialog';\n// import {\n// hex2hsl,\n// hslString2hsl,\n// rgbString2hsl,\n// IPepHslColor,\n// findClosestAccessibleColor,\n// hsl2hex,\n// convertHslToStringHsl,\n// } from './color-utils';\nimport { PepColorService, IPepHslColor } from '@pepperi-addons/ngx-lib';\n\nimport { PepColorType } from './color.model';\n\nenum PepContrastRatioType {\n AA = 4.5,\n AAA = 7,\n}\n\ninterface IPepColorPickerDialogData {\n value: string;\n type: PepColorType;\n showAAComplient: boolean;\n textColor: string;\n contrastRatio: PepContrastRatioType;\n}\n\n@Component({\n templateUrl: './color-picker.component.html',\n styleUrls: ['./color-picker.component.scss', './color-picker.component.theme.scss'],\n})\nexport class PepColorPickerComponent implements OnInit {\n static CURRENT_HUE = '--pep-color-picker-current-hue';\n private readonly defaultColor = '#ccc';\n\n checkAAComplient = true;\n\n constructor(\n private colorService: PepColorService,\n private dialogRef: MatDialogRef<PepColorPickerComponent>,\n @Inject(MAT_DIALOG_DATA) public data: IPepColorPickerDialogData\n ) {\n this.data.type = data ? data.type : 'any';\n this.data.showAAComplient = !data\n ? false\n : data.showAAComplient ?? true;\n this.data.textColor = data && data.textColor ? data.textColor : '#fff';\n this.data.contrastRatio =\n data && data.contrastRatio\n ? data.contrastRatio\n : PepContrastRatioType.AA;\n }\n\n private defaultHueBackground = `linear-gradient(to right,\n hsl(0, 100%, 50%) 0%,\n hsl(60, 100%, 50%) 17%,\n hsl(120, 100%, 50%) 33%,\n hsl(180, 100%, 50%) 50%,\n hsl(240, 100%, 50%) 67%,\n hsl(300, 100%, 50%) 83%,\n hsl(360, 100%, 50%) 100%)`;\n\n currentHue = 100;\n currentHueMin = 0;\n currentHueMax = 360;\n currentHueBackground = this.defaultHueBackground;\n\n private defaultSaturationBackground = `linear-gradient(to right,\n hsl(var(--pep-color-picker-current-hue), 0.01%, 50%) 0%,\n hsl(var(--pep-color-picker-current-hue), 100%, 50%) 100%)`;\n\n currentSaturation = 50;\n currentSaturationMin = 0;\n currentSaturationMax = 100;\n currentSaturationBackground = this.defaultSaturationBackground;\n\n private defaultLightnessBackground = `linear-gradient(to right,\n hsl(var(--pep-color-picker-current-hue), 100%, 100%) 0%,\n hsl(var(--pep-color-picker-current-hue), 100%, 50%) 50%,\n hsl(var(--pep-color-picker-current-hue), 100%, 0.01%) 100%)`;\n\n currentLightness = 50;\n currentLightnessMin = 0;\n currentLightnessMax = 100;\n currentLightnessBackground = this.defaultLightnessBackground;\n\n complientColor: string;\n isUserChooseAAComplientColor: boolean;\n\n ngOnInit(): void {\n this.initVars();\n this.checkAAComplient = this.data.showAAComplient;\n this.convertValueStringToColor(this.data.value);\n }\n\n initVars(): void {\n if (this.data.type === 'main') {\n this.currentLightnessMax = 10;\n this.currentLightness = 5;\n this.currentHueBackground = this.defaultHueBackground;\n this.currentSaturationBackground = this.defaultSaturationBackground;\n this.currentLightnessBackground = this.defaultLightnessBackground;\n } else if (this.data.type === 'success') {\n this.currentHueMin = 70;\n this.currentHueMax = 150;\n this.currentHue = 100;\n\n this.currentSaturationMin = 50;\n this.currentSaturationMax = 100;\n this.currentSaturation = 50;\n\n this.currentLightnessMin = 10;\n this.currentLightnessMax = 65;\n this.currentLightness = 50;\n\n this.currentHueBackground = `linear-gradient(to right,\n hsl(70, 100%, 50%) 0%,\n hsl(150, 100%, 50%) 100%)`;\n this.currentSaturationBackground = `linear-gradient(to right,\n hsl(var(--pep-color-picker-current-hue), 50%, 50%) 50%,\n hsl(var(--pep-color-picker-current-hue), 100%, 50%) 100%)`;\n this.currentLightnessBackground = `linear-gradient(to right,\n hsl(var(--pep-color-picker-current-hue), 100%, 65%) 10%,\n hsl(var(--pep-color-picker-current-hue), 100%, 35%) 35%,\n hsl(var(--pep-color-picker-current-hue), 100%, 10%) 65%)`;\n\n } else if (this.data.type === 'caution') {\n this.currentHueMin = -20;\n this.currentHueMax = 20;\n this.currentHue = 10;\n\n this.currentSaturationMin = 75;\n this.currentSaturationMax = 100;\n this.currentSaturation = 75;\n\n this.currentLightnessMin = 25;\n this.currentLightnessMax = 75;\n this.currentLightness = 50;\n\n this.currentHueBackground = `linear-gradient(to right,\n hsl(340, 100%, 50%) 0%,\n hsl(20, 100%, 50%) 100%)`;\n this.currentSaturationBackground = `linear-gradient(to right,\n hsl(var(--pep-color-picker-current-hue), 75%, 50%) 75%,\n hsl(var(--pep-color-picker-current-hue), 100%, 50%) 100%)`;\n this.currentLightnessBackground = `linear-gradient(to right,\n hsl(var(--pep-color-picker-current-hue), 100%, 75%) 25%,\n hsl(var(--pep-color-picker-current-hue), 100%, 50%) 50%,\n hsl(var(--pep-color-picker-current-hue), 100%, 25%) 75%)`;\n }\n }\n\n setCurrentHueInCss(): void {\n document.documentElement.style.setProperty(\n PepColorPickerComponent.CURRENT_HUE,\n this.currentHue.toString()\n );\n }\n\n convertValueStringToColor(color): void {\n if (color.indexOf('hsl') === 0) {\n const hsl = this.colorService.hslString2hsl(color);\n this.convertColorToValueString(hsl);\n } else if (color.indexOf('rgb') === 0) {\n const hsl = this.colorService.rgbString2hsl(color);\n this.convertColorToValueString(hsl);\n } else if (color.indexOf('#') === 0) {\n const hsl = this.colorService.hex2hsl(color);\n this.convertColorToValueString(hsl);\n } else {\n // Handle default.\n const hsl = this.colorService.hex2hsl(this.defaultColor);\n this.convertColorToValueString(hsl);\n }\n\n this.setCurrentHueInCss();\n }\n\n convertColorToValueString(hslColor: IPepHslColor): void {\n // Regular hue\n if (\n hslColor.h >= this.currentHueMin &&\n hslColor.h <= this.currentHueMax\n ) {\n this.currentHue = hslColor.h;\n } else if (\n this.currentHueMin < 0 &&\n hslColor.h >= 0 &&\n hslColor.h <= 360\n ) {\n // For min with - (change to the other side of the circle)\n hslColor.h = hslColor.h - 360;\n\n if (\n hslColor.h >= this.currentHueMin &&\n hslColor.h <= this.currentHueMax\n ) {\n this.currentHue = hslColor.h;\n }\n }\n\n this.currentSaturation =\n hslColor.s >= this.currentSaturationMin &&\n hslColor.s <= this.currentSaturationMax\n ? hslColor.s\n : this.currentSaturation;\n\n this.currentLightness =\n hslColor.l >= this.currentLightnessMin &&\n hslColor.l <= this.currentLightnessMax\n ? hslColor.l\n : this.currentLightness;\n\n // Write the value (if hue is changed to the other side of the circle return it back).\n const hsl = {\n h: this.currentHue,\n s: this.currentSaturation,\n l: this.currentLightness,\n };\n this.data.value = this.colorService.convertHslToStringHsl(hsl);\n\n // Check the contrast ratio - set the closest accessible color to complientColor\n // and update isUserChooseAAComplientColor.\n const adjustableColor = this.colorService.hsl2hex(hsl);\n const closestHex = this.colorService.findClosestAccessibleColor(\n adjustableColor,\n this.data.textColor,\n this.data.contrastRatio\n );\n\n this.isUserChooseAAComplientColor = adjustableColor === closestHex;\n this.complientColor = this.colorService.convertHslToStringHsl(\n this.colorService.hex2hsl(closestHex)\n );\n }\n\n onHueChange(value): void {\n this.convertColorToValueString({ h: value });\n this.setCurrentHueInCss();\n }\n\n onSaturationChange(value): void {\n // this.currentSaturation = event.value;\n this.convertColorToValueString({ s: value });\n }\n\n onLightnessChange(value): void {\n // this.currentLightness = event.value;\n this.convertColorToValueString({\n l:\n this.currentLightnessMax -\n value +\n this.currentLightnessMin,\n });\n }\n\n onColorValueChange(event): void {\n this.convertValueStringToColor(event.value);\n }\n\n onSave(event): void {\n const color = this.checkAAComplient\n ? this.complientColor\n : this.data.value;\n\n // this.notify.emit({ key: this.key, value: color });\n this.dialogRef.close(color);\n }\n\n closeDialog(event) {\n this.dialogRef.close(event);\n }\n}\n","import {\n Component,\n OnInit,\n Input,\n Output,\n Renderer2,\n ElementRef,\n EventEmitter,\n OnChanges,\n OnDestroy,\n} from '@angular/core';\nimport {\n PepCustomizationService,\n PepLayoutType,\n PepHorizontalAlignment,\n DEFAULT_HORIZONTAL_ALIGNMENT,\n} from '@pepperi-addons/ngx-lib';\nimport { PepDialogService } from '@pepperi-addons/ngx-lib/dialog';\nimport { PepColorPickerComponent } from './color-picker.component';\nimport { PepColorType } from './color.model';\n\n@Component({\n selector: 'pep-color',\n templateUrl: './color.component.html',\n styleUrls: ['./color.component.scss'],\n})\nexport class PepColorComponent implements OnInit, OnDestroy {\n @Input() key = '';\n @Input() value = '';\n @Input() label = '';\n @Input() disabled = false;\n @Input() xAlignment: PepHorizontalAlignment = DEFAULT_HORIZONTAL_ALIGNMENT;\n @Input() rowSpan = 1;\n @Input() type: PepColorType = 'any';\n\n @Input() showTitle = true;\n @Input() renderTitle = true;\n\n @Input() showAAComplient = true;\n @Input() layoutType: PepLayoutType = 'form';\n\n @Output()\n valueChange: EventEmitter<string> = new EventEmitter<string>();\n\n constructor(\n private dialogService: PepDialogService,\n private renderer: Renderer2,\n private element: ElementRef\n ) { }\n\n ngOnInit(): void {\n this.renderer.addClass(\n this.element.nativeElement,\n PepCustomizationService.STAND_ALONE_FIELD_CLASS_NAME\n );\n\n if (!this.renderTitle) {\n this.renderer.addClass(\n this.element.nativeElement,\n PepCustomizationService.STAND_ALONE_FIELD_NO_SPACING_CLASS_NAME\n );\n }\n }\n\n ngOnDestroy(): void {\n //\n }\n\n changeColor(value: any): void {\n this.value = value;\n this.valueChange.emit(value);\n }\n\n chooseColor(): void {\n const dialogRef = this.dialogService.openDialog(\n PepColorPickerComponent,\n {\n value: this.value,\n type: this.type,\n showAAComplient: this.showAAComplient,\n }\n );\n\n dialogRef.afterClosed().subscribe((value) => {\n if (value !== undefined && value !== null) {\n this.changeColor(value);\n }\n });\n }\n}\n","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { ReactiveFormsModule } from '@angular/forms';\n\nimport { MatCommonModule } from '@angular/material/core';\nimport { MatButtonModule } from '@angular/material/button';\nimport { MatFormFieldModule } from '@angular/material/form-field';\nimport { MatCheckboxModule } from '@angular/material/checkbox';\nimport { MatDialogModule } from '@angular/material/dialog';\nimport { MatIconModule } from '@angular/material/icon';\nimport { MatSliderModule } from '@angular/material/slider';\n\nimport { PepNgxLibModule } from '@pepperi-addons/ngx-lib';\nimport { PepDialogModule } from '@pepperi-addons/ngx-lib/dialog';\nimport { PepSliderModule } from '@pepperi-addons/ngx-lib/slider';\n\nimport {\n PepIconModule,\n PepIconRegistry,\n pepIconSystemEdit,\n pepIconSystemOk,\n pepIconSystemClose,\n} from '@pepperi-addons/ngx-lib/icon';\nimport { PepFieldTitleModule } from '@pepperi-addons/ngx-lib/field-title';\nimport { PepTextboxModule } from '@pepperi-addons/ngx-lib/textbox';\n\nimport { PepColorComponent } from './color.component';\nimport { PepColorPickerComponent } from './color-picker.component';\n\n@NgModule({\n imports: [\n CommonModule,\n ReactiveFormsModule,\n // Material modules\n MatCommonModule,\n MatButtonModule,\n MatFormFieldModule,\n MatCheckboxModule,\n MatDialogModule,\n MatIconModule,\n MatSliderModule,\n // ngx-lib modules\n PepNgxLibModule,\n PepDialogModule,\n PepIconModule,\n PepSliderModule,\n PepFieldTitleModule,\n PepTextboxModule,\n ],\n exports: [PepColorComponent],\n declarations: [PepColorComponent, PepColorPickerComponent],\n entryComponents: [PepColorPickerComponent],\n})\nexport class PepColorModule {\n constructor(private pepIconRegistry: PepIconRegistry) {\n this.pepIconRegistry.registerIcons([\n pepIconSystemEdit,\n pepIconSystemOk,\n pepIconSystemClose,\n ]);\n }\n}\n","/*\n * Public API Surface of ngx-lib/color\n */\nexport * from './color.module';\nexport * from './color.model';\nexport * from './color.component';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n\nexport {PepColorPickerComponent as ɵa} from './color-picker.component';"],"names":["Component","PepColorService","MatDialogRef","Inject","MAT_DIALOG_DATA","DEFAULT_HORIZONTAL_ALIGNMENT","EventEmitter","PepCustomizationService","PepDialogService","Renderer2","ElementRef","Input","Output","pepIconSystemEdit","pepIconSystemOk","pepIconSystemClose","NgModule","CommonModule","ReactiveFormsModule","MatCommonModule","MatButtonModule","MatFormFieldModule","MatCheckboxModule","MatDialogModule","MatIconModule","MatSliderModule","PepNgxLibModule","PepDialogModule","PepIconModule","PepSliderModule","PepFieldTitleModule","PepTextboxModule","PepIconRegistry"],"mappings":";;;;;;IAeA,IAAK,oBAGJ;IAHD,WAAK,oBAAoB;QACrB,6DAAQ,CAAA;QACR,6DAAO,CAAA;IACX,CAAC,EAHI,oBAAoB,KAApB,oBAAoB,QAGxB;;QAoBG,iCACY,YAA6B,EAC7B,SAAgD,EACxB,IAA+B;;YAFvD,iBAAY,GAAZ,YAAY,CAAiB;YAC7B,cAAS,GAAT,SAAS,CAAuC;YACxB,SAAI,GAAJ,IAAI,CAA2B;YAPlD,iBAAY,GAAG,MAAM,CAAC;YAEvC,qBAAgB,GAAG,IAAI,CAAC;YAkBhB,yBAAoB,GAAG,sQAOD,CAAC;YAE/B,eAAU,GAAG,GAAG,CAAC;YACjB,kBAAa,GAAG,CAAC,CAAC;YAClB,kBAAa,GAAG,GAAG,CAAC;YACpB,yBAAoB,GAAG,IAAI,CAAC,oBAAoB,CAAC;YAEzC,gCAA2B,GAAG,gKAEwB,CAAC;YAE/D,sBAAiB,GAAG,EAAE,CAAC;YACvB,yBAAoB,GAAG,C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|
@@ -48,7 +48,7 @@
|
|
|
48
48
|
this.title = options.title || '';
|
|
49
49
|
this.actionsType = options.actionsType || 'close';
|
|
50
50
|
this.content = options.content || '';
|
|
51
|
-
this.showClose = (_a = options.showClose) !== null && _a !== void 0 ? _a :
|
|
51
|
+
this.showClose = (_a = options.showClose) !== null && _a !== void 0 ? _a : false;
|
|
52
52
|
this.showHeader = (_b = options.showHeader) !== null && _b !== void 0 ? _b : true;
|
|
53
53
|
this.showFooter = (_c = options.showFooter) !== null && _c !== void 0 ? _c : true;
|
|
54
54
|
this.actionButtons = (_d = options.actionButtons) !== null && _d !== void 0 ? _d : null;
|
|
@@ -69,11 +69,14 @@
|
|
|
69
69
|
}
|
|
70
70
|
});
|
|
71
71
|
};
|
|
72
|
+
PepDefaultDialogComponent.prototype.closeDialog = function (res) {
|
|
73
|
+
this.dialogRef.close(res);
|
|
74
|
+
};
|
|
72
75
|
return PepDefaultDialogComponent;
|
|
73
76
|
}());
|
|
74
77
|
PepDefaultDialogComponent.decorators = [
|
|
75
78
|
{ type: i0.Component, args: [{
|
|
76
|
-
template: "<pep-dialog [showClose]=\"data?.showClose\" [showHeader]=\"data?.showHeader\" [showFooter]=\"data?.showFooter\"\n [title]=\"data?.title\">\n <div pep-dialog-content [innerHtml]=\"data?.content | pepSafeHtml\"></div>\n <div pep-dialog-actions class=\"pep-spacing-element-negative\">\n <ng-container [ngSwitch]=\"data?.actionsType\">\n <ng-container *ngSwitchCase=\"'close'\">\n <button mat-button
|
|
79
|
+
template: "<pep-dialog [showClose]=\"data?.showClose\" [showHeader]=\"data?.showHeader\" [showFooter]=\"data?.showFooter\"\n [title]=\"data?.title\" (close)=\"closeDialog($event)\">\n <div pep-dialog-content [innerHtml]=\"data?.content | pepSafeHtml\"></div>\n <div pep-dialog-actions class=\"pep-spacing-element-negative\">\n <ng-container [ngSwitch]=\"data?.actionsType\">\n <ng-container *ngSwitchCase=\"'close'\">\n <button mat-button (click)=\"closeDialog(true)\" class=\"pep-spacing-element pep-button md weak\">\n {{ 'ACTIONS.CLOSE' | translate }}\n </button>\n </ng-container>\n <ng-container *ngSwitchCase=\"'cancel-continue'\">\n <button mat-button (click)=\"closeDialog(false)\" class=\"pep-spacing-element pep-button md weak\">\n {{ 'ACTIONS.CANCEL' | translate }}\n </button>\n <button mat-button (click)=\"closeDialog(true)\" class=\"pep-spacing-element pep-button md strong\">\n {{ 'ACTIONS.CONTINUE' | translate }}\n </button>\n </ng-container>\n <ng-container *ngSwitchCase=\"'cancel-ok'\">\n <button mat-button (click)=\"closeDialog(false)\" class=\"pep-spacing-element pep-button md weak\">\n {{ 'ACTIONS.CANCEL' | translate }}\n </button>\n <button mat-button (click)=\"closeDialog(true)\" class=\"pep-spacing-element pep-button md strong\">\n {{ 'ACTIONS.OK' | translate }}\n </button>\n </ng-container>\n <ng-container *ngSwitchCase=\"'cancel-delete'\">\n <button mat-button (click)=\"closeDialog(false)\" class=\"pep-spacing-element pep-button md weak\">\n {{ 'ACTIONS.CANCEL' | translate }}\n </button>\n <button mat-button (click)=\"closeDialog(true)\" class=\"pep-spacing-element pep-button md strong caution\">\n {{ 'ACTIONS.DELETE' | translate }}\n </button>\n </ng-container>\n <ng-container *ngSwitchCase=\"'custom'\">\n <ng-container *ngFor=\"let btn of data?.actionButtons\">\n <!-- [mat-dialog-close]=\"btn?.callback ? btn.callback : null\" -->\n <button mat-button (click)=\"onActionButtonClicked(btn)\" class=\"pep-spacing-element pep-button md\"\n [ngClass]=\"btn?.className != '' ? btn?.className : 'weak'\">\n {{ btn?.title }}\n </button>\n </ng-container>\n </ng-container>\n </ng-container>\n </div>\n</pep-dialog>",
|
|
77
80
|
encapsulation: i0.ViewEncapsulation.None,
|
|
78
81
|
styles: [""]
|
|
79
82
|
},] }
|
|
@@ -85,24 +88,30 @@
|
|
|
85
88
|
|
|
86
89
|
var PepDialogComponent = /** @class */ (function () {
|
|
87
90
|
function PepDialogComponent() {
|
|
88
|
-
this.showClose =
|
|
91
|
+
this.showClose = false;
|
|
89
92
|
this.showHeader = true;
|
|
90
93
|
this.showFooter = true;
|
|
94
|
+
this.close = new i0.EventEmitter();
|
|
91
95
|
}
|
|
96
|
+
PepDialogComponent.prototype.closeDialog = function () {
|
|
97
|
+
this.close.emit(null);
|
|
98
|
+
};
|
|
92
99
|
return PepDialogComponent;
|
|
93
100
|
}());
|
|
94
101
|
PepDialogComponent.decorators = [
|
|
95
102
|
{ type: i0.Component, args: [{
|
|
96
103
|
selector: 'pep-dialog',
|
|
97
|
-
template: "<div mat-dialog-title *ngIf=\"showHeader\" class=\"dialog-header-container\">\n <span class=\"dialog-title\" *ngIf=\"title?.length\">\n {{ title }}\n </span>\n <button mat-button *ngIf=\"showClose\"
|
|
104
|
+
template: "<div mat-dialog-title *ngIf=\"showHeader\" class=\"dialog-header-container\">\n <span class=\"dialog-title\" *ngIf=\"title?.length\">\n {{ title }}\n </span>\n <button mat-button *ngIf=\"showClose\" (click)=\"closeDialog()\" class=\"pep-button icon-button md weak dialog-close\">\n <mat-icon>\n <pep-icon name=\"system_close\">\n </pep-icon>\n </mat-icon>\n </button>\n</div>\n<div mat-dialog-content>\n <ng-content select=\"[pep-dialog-content]\"></ng-content>\n</div>\n<div mat-dialog-actions *ngIf=\"showFooter\" class=\"pep-border-top\">\n <ng-content select=\"[pep-dialog-actions]\"></ng-content>\n</div>",
|
|
98
105
|
styles: ["", ".pep-dialog,.pepperi-dialog{box-shadow:0 .25rem .5rem 0 rgba(26,26,26,.32)!important;box-shadow:var(--pep-shadow-sm-offset,0 .25rem .5rem 0) hsla(var(--pep-color-system-primary-h,0),var(--pep-color-system-primary-s,0%),var(--pep-color-system-primary-l,10%),.32)!important}"]
|
|
99
106
|
},] }
|
|
100
107
|
];
|
|
108
|
+
PepDialogComponent.ctorParameters = function () { return []; };
|
|
101
109
|
PepDialogComponent.propDecorators = {
|
|
102
110
|
title: [{ type: i0.Input }],
|
|
103
111
|
showClose: [{ type: i0.Input }],
|
|
104
112
|
showHeader: [{ type: i0.Input }],
|
|
105
|
-
showFooter: [{ type: i0.Input }]
|
|
113
|
+
showFooter: [{ type: i0.Input }],
|
|
114
|
+
close: [{ type: i0.Output }]
|
|
106
115
|
};
|
|
107
116
|
|
|
108
117
|
var PepDialogService = /** @class */ (function () {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pepperi-addons-ngx-lib-dialog.umd.js","sources":["../../../projects/ngx-lib/dialog/dialog.model.ts","../../../projects/ngx-lib/dialog/default-dialog.component.ts","../../../projects/ngx-lib/dialog/dialog.component.ts","../../../projects/ngx-lib/dialog/dialog.service.ts","../../../projects/ngx-lib/dialog/dialog.module.ts","../../../projects/ngx-lib/dialog/public-api.ts","../../../projects/ngx-lib/dialog/pepperi-addons-ngx-lib-dialog.ts"],"sourcesContent":["export type PepDialogSizeType =\n | 'inline'\n | 'small'\n | 'regular'\n | 'large'\n | 'full-screen';\n\nexport type PepDialogActionsType =\n | 'close'\n | 'cancel-continue'\n | 'cancel-ok'\n | 'cancel-delete'\n | 'custom';\n\nexport class PepDialogActionButton {\n title = '';\n className = '';\n callback: () => void;\n\n constructor(title = '', className = '', callback: () => void = null) {\n this.title = title;\n this.className = className;\n this.callback = callback;\n }\n}\n\nexport class PepDialogData {\n title: string;\n actionsType: PepDialogActionsType;\n content: any;\n showClose: boolean;\n showHeader: boolean;\n showFooter: boolean;\n actionButtons: Array<PepDialogActionButton>;\n\n constructor(options: {\n title?: string;\n actionsType?: PepDialogActionsType;\n content?: any;\n contentDisabled?: boolean;\n showClose?: boolean;\n showHeader?: boolean;\n showFooter?: boolean;\n actionButtons?: Array<PepDialogActionButton>;\n }) {\n this.title = options.title || '';\n this.actionsType = options.actionsType || 'close';\n this.content = options.content || '';\n this.showClose = options.showClose ?? true;\n this.showHeader = options.showHeader ?? true;\n this.showFooter = options.showFooter ?? true;\n this.actionButtons = options.actionButtons ?? null;\n }\n}\n","import { Component, Inject, ViewEncapsulation } from '@angular/core';\nimport { MAT_DIALOG_DATA, MatDialogRef } from '@angular/material/dialog';\nimport { PepDialogData, PepDialogActionButton } from './dialog.model';\n\n@Component({\n templateUrl: './default-dialog.component.html',\n styleUrls: ['./default-dialog.component.scss'],\n encapsulation: ViewEncapsulation.None,\n})\nexport class PepDefaultDialogComponent {\n constructor(\n @Inject(MAT_DIALOG_DATA) public data: PepDialogData,\n public dialogRef: MatDialogRef<any>\n ) {}\n\n onActionButtonClicked(button: PepDialogActionButton): void {\n this.dialogRef.close(true);\n this.dialogRef.afterClosed().subscribe((isActionButtonClicked) => {\n if (isActionButtonClicked && button?.callback) {\n button.callback();\n }\n });\n }\n}\n","import { Component, Input } from '@angular/core';\n\n@Component({\n selector: 'pep-dialog',\n styleUrls: ['./dialog.component.scss', './dialog.component.theme.scss'],\n templateUrl: './dialog.component.html',\n})\nexport class PepDialogComponent {\n @Input() title: string;\n @Input() showClose = true;\n @Input() showHeader = true;\n @Input() showFooter = true;\n}\n","import { Injectable, TemplateRef } from '@angular/core';\nimport {\n MatDialog,\n MatDialogConfig,\n MatDialogRef,\n} from '@angular/material/dialog';\nimport { PepLayoutService } from '@pepperi-addons/ngx-lib';\nimport { Overlay } from '@angular/cdk/overlay';\nimport { ComponentType } from '@angular/cdk/portal';\nimport { PepDialogSizeType, PepDialogData } from './dialog.model';\nimport { PepDefaultDialogComponent } from './default-dialog.component';\n\n@Injectable({\n providedIn: 'root',\n})\nexport class PepDialogService {\n constructor(\n private dialog: MatDialog,\n private layoutService: PepLayoutService,\n private overlay: Overlay\n ) { }\n\n private fixConfigIfNeeded(data: PepDialogData, config: MatDialogConfig) {\n if (config.disableClose) {\n if (\n (((data.showClose !== undefined && !data.showClose) || (data.showHeader !== undefined && !data.showHeader)) && (data.showFooter !== undefined && !data.showFooter)) ||\n (data.actionsType === 'custom' &&\n (data.actionButtons === null ||\n data.actionButtons.length === 0))\n ) {\n config.disableClose = false;\n }\n }\n }\n\n getDialogConfig(\n options: {\n disableClose?: boolean;\n height?: string;\n minWidth?: string;\n maxWidth?: string;\n maxHeight?: string;\n panelClass?: string;\n } = {},\n size: PepDialogSizeType = 'regular'\n ): MatDialogConfig {\n const dialogConfig = new MatDialogConfig();\n\n dialogConfig.autoFocus = false;\n dialogConfig.direction = this.layoutService.isRtl() ? 'rtl' : 'ltr';\n dialogConfig.disableClose = options.disableClose ?? true;\n \n dialogConfig.panelClass = ['pep-dialog'];\n if (options.panelClass) {\n dialogConfig.panelClass.push(options.panelClass);\n }\n\n if (size === 'inline') {\n dialogConfig.height = options.height || 'auto';\n dialogConfig.maxWidth = options.maxWidth || '100vw';\n dialogConfig.maxHeight = options.maxHeight || '100vh';\n dialogConfig.minWidth = options.minWidth || '300px';\n }\n\n dialogConfig.panelClass.push(size);\n\n dialogConfig.scrollStrategy = this.overlay.scrollStrategies.noop();\n // dialogConfig.scrollStrategy = this.overlay.scrollStrategies.block();\n\n return dialogConfig;\n }\n\n openDefaultDialog(\n data: PepDialogData,\n config: MatDialogConfig = null\n ): MatDialogRef<PepDefaultDialogComponent> {\n if (!config) {\n config = this.getDialogConfig();\n }\n this.fixConfigIfNeeded(data, config);\n\n config.data = data;\n const dialogRef = this.dialog.open(PepDefaultDialogComponent, config);\n return dialogRef;\n }\n\n openDialog<T>(\n componentOrTemplateRef: ComponentType<T> | TemplateRef<T>,\n data: any = {},\n config: MatDialogConfig = null\n ): MatDialogRef<T> {\n if (!config) {\n config = this.getDialogConfig();\n }\n this.fixConfigIfNeeded(data, config);\n\n config.data = data;\n const dialogRef = this.dialog.open(componentOrTemplateRef, config);\n return dialogRef;\n }\n}\n","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\n\nimport { MatCommonModule } from '@angular/material/core';\nimport { MatButtonModule } from '@angular/material/button';\nimport { MatIconModule } from '@angular/material/icon';\nimport { MatDialogModule } from '@angular/material/dialog';\n\nimport { PepNgxLibModule } from '@pepperi-addons/ngx-lib';\nimport {\n PepIconModule,\n PepIconRegistry,\n pepIconSystemClose,\n} from '@pepperi-addons/ngx-lib/icon';\n\nimport { PepDefaultDialogComponent } from './default-dialog.component';\nimport { PepDialogComponent } from './dialog.component';\nimport { PepDialogService } from './dialog.service';\n\n@NgModule({\n imports: [\n CommonModule,\n // Material modules,\n MatCommonModule,\n MatButtonModule,\n MatIconModule,\n MatDialogModule,\n // ngx-lib modules\n PepNgxLibModule,\n PepIconModule,\n ],\n exports: [PepDialogComponent],\n declarations: [PepDefaultDialogComponent, PepDialogComponent],\n entryComponents: [PepDefaultDialogComponent],\n providers: [PepDialogService]\n})\nexport class PepDialogModule {\n constructor(private pepIconRegistry: PepIconRegistry) {\n this.pepIconRegistry.registerIcons([pepIconSystemClose]);\n }\n}\n","/*\n * Public API Surface of ngx-lib/dialog\n */\nexport * from './dialog.module';\nexport * from './dialog.model';\nexport * from './dialog.component';\nexport * from './dialog.service';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n\nexport {PepDefaultDialogComponent as ɵa} from './default-dialog.component';"],"names":["Component","ViewEncapsulation","Inject","MAT_DIALOG_DATA","MatDialogRef","Input","MatDialogConfig","Injectable","MatDialog","PepLayoutService","Overlay","pepIconSystemClose","NgModule","CommonModule","MatCommonModule","MatButtonModule","MatIconModule","MatDialogModule","PepNgxLibModule","PepIconModule","PepIconRegistry"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;QAmBI,+BAAY,KAAU,EAAE,SAAc,EAAE,QAA2B;YAAvD,sBAAA,EAAA,UAAU;YAAE,0BAAA,EAAA,cAAc;YAAE,yBAAA,EAAA,eAA2B;YAJnE,UAAK,GAAG,EAAE,CAAC;YACX,cAAS,GAAG,EAAE,CAAC;YAIX,IAAI,CAAC,KAAK,GAAG,KAAK,CAAC;YACnB,IAAI,CAAC,SAAS,GAAG,SAAS,CAAC;YAC3B,IAAI,CAAC,QAAQ,GAAG,QAAQ,CAAC;SAC5B;oCACJ;KAAA,IAAA;;QAWG,uBAAY,OASX;;YACG,IAAI,CAAC,KAAK,GAAG,OAAO,CAAC,KAAK,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GAAG,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,sBAAsB,EAAE,MAAM,CAAC,CAAC;YACnE,OAAO,SAAS,CAAC;SACpB;;;;;gBAvFJC,aAAU,SAAC;oBACR,UAAU,EAAE,MAAM;iBACrB;;;gBAZGC,YAAS;gBAIJC,mBAAgB;gBAChBC,UAAO;;;;QC8BZ,yBAAoB,eAAgC;YAAhC,oBAAe,GAAf,eAAe,CAAiB;YAChD,IAAI,CAAC,eAAe,CAAC,aAAa,CAAC,CAACC,uBAAkB,CAAC,CAAC,CAAC;SAC5D;;;;gBApBJC,WAAQ,SAAC;oBACN,OAAO,EAAE;wBACLC,mBAAY;;wBAEZC,oBAAe;wBACfC,sBAAe;wBACfC,oBAAa;wBACbC,kBAAe;;wBAEfC,kBAAe;wBACfC,kBAAa;qBAChB;oBACD,OAAO,EAAE,CAAC,kBAAkB,CAAC;oBAC7B,YAAY,EAAE,CAAC,yBAAyB,EAAE,kBAAkB,CAAC;oBAC7D,eAAe,EAAE,CAAC,yBAAyB,CAAC;oBAC5C,SAAS,EAAE,CAAC,gBAAgB,CAAC;iBAChC;;;gBAxBGC,oBAAe;;;ICXnB;;;;ICAA;;;;;;;;;;;;;;;;;"}
|
|
1
|
+
{"version":3,"file":"pepperi-addons-ngx-lib-dialog.umd.js","sources":["../../../projects/ngx-lib/dialog/dialog.model.ts","../../../projects/ngx-lib/dialog/default-dialog.component.ts","../../../projects/ngx-lib/dialog/dialog.component.ts","../../../projects/ngx-lib/dialog/dialog.service.ts","../../../projects/ngx-lib/dialog/dialog.module.ts","../../../projects/ngx-lib/dialog/public-api.ts","../../../projects/ngx-lib/dialog/pepperi-addons-ngx-lib-dialog.ts"],"sourcesContent":["export type PepDialogSizeType =\n | 'inline'\n | 'small'\n | 'regular'\n | 'large'\n | 'full-screen';\n\nexport type PepDialogActionsType =\n | 'close'\n | 'cancel-continue'\n | 'cancel-ok'\n | 'cancel-delete'\n | 'custom';\n\nexport class PepDialogActionButton {\n title = '';\n className = '';\n callback: () => void;\n\n constructor(title = '', className = '', callback: () => void = null) {\n this.title = title;\n this.className = className;\n this.callback = callback;\n }\n}\n\nexport class PepDialogData {\n title: string;\n actionsType: PepDialogActionsType;\n content: any;\n showClose: boolean;\n showHeader: boolean;\n showFooter: boolean;\n actionButtons: Array<PepDialogActionButton>;\n\n constructor(options: {\n title?: string;\n actionsType?: PepDialogActionsType;\n content?: any;\n contentDisabled?: boolean;\n showClose?: boolean;\n showHeader?: boolean;\n showFooter?: boolean;\n actionButtons?: Array<PepDialogActionButton>;\n }) {\n this.title = options.title || '';\n this.actionsType = options.actionsType || 'close';\n this.content = options.content || '';\n this.showClose = options.showClose ?? false;\n this.showHeader = options.showHeader ?? true;\n this.showFooter = options.showFooter ?? true;\n this.actionButtons = options.actionButtons ?? null;\n }\n}\n","import { Component, Inject, ViewEncapsulation } from '@angular/core';\nimport { MAT_DIALOG_DATA, MatDialogRef } from '@angular/material/dialog';\nimport { PepDialogData, PepDialogActionButton } from './dialog.model';\n\n@Component({\n templateUrl: './default-dialog.component.html',\n styleUrls: ['./default-dialog.component.scss'],\n encapsulation: ViewEncapsulation.None,\n})\nexport class PepDefaultDialogComponent {\n constructor(\n @Inject(MAT_DIALOG_DATA) public data: PepDialogData,\n public dialogRef: MatDialogRef<any>\n ) {}\n\n onActionButtonClicked(button: PepDialogActionButton): void {\n this.dialogRef.close(true);\n this.dialogRef.afterClosed().subscribe((isActionButtonClicked) => {\n if (isActionButtonClicked && button?.callback) {\n button.callback();\n }\n });\n }\n\n closeDialog(res) {\n this.dialogRef.close(res);\n }\n}\n","import { Component, EventEmitter, Input, Output } from '@angular/core';\nimport { MatDialogRef } from '@angular/material/dialog';\n\n@Component({\n selector: 'pep-dialog',\n styleUrls: ['./dialog.component.scss', './dialog.component.theme.scss'],\n templateUrl: './dialog.component.html',\n})\nexport class PepDialogComponent {\n @Input() title: string;\n @Input() showClose = false;\n @Input() showHeader = true;\n @Input() showFooter = true;\n\n @Output() close: EventEmitter<any> = new EventEmitter<any>();\n\n constructor() {}\n \n closeDialog() {\n this.close.emit(null);\n }\n}\n","import { Injectable, TemplateRef } from '@angular/core';\nimport {\n MatDialog,\n MatDialogConfig,\n MatDialogRef,\n} from '@angular/material/dialog';\nimport { PepLayoutService } from '@pepperi-addons/ngx-lib';\nimport { Overlay } from '@angular/cdk/overlay';\nimport { ComponentType } from '@angular/cdk/portal';\nimport { PepDialogSizeType, PepDialogData } from './dialog.model';\nimport { PepDefaultDialogComponent } from './default-dialog.component';\n\n@Injectable({\n providedIn: 'root',\n})\nexport class PepDialogService {\n constructor(\n private dialog: MatDialog,\n private layoutService: PepLayoutService,\n private overlay: Overlay\n ) { }\n\n private fixConfigIfNeeded(data: PepDialogData, config: MatDialogConfig) {\n if (config.disableClose) {\n if (\n (((data.showClose !== undefined && !data.showClose) || (data.showHeader !== undefined && !data.showHeader)) && (data.showFooter !== undefined && !data.showFooter)) ||\n (data.actionsType === 'custom' &&\n (data.actionButtons === null ||\n data.actionButtons.length === 0))\n ) {\n config.disableClose = false;\n }\n }\n }\n\n getDialogConfig(\n options: {\n disableClose?: boolean;\n height?: string;\n minWidth?: string;\n maxWidth?: string;\n maxHeight?: string;\n panelClass?: string;\n } = {},\n size: PepDialogSizeType = 'regular'\n ): MatDialogConfig {\n const dialogConfig = new MatDialogConfig();\n\n dialogConfig.autoFocus = false;\n dialogConfig.direction = this.layoutService.isRtl() ? 'rtl' : 'ltr';\n dialogConfig.disableClose = options.disableClose ?? true;\n \n dialogConfig.panelClass = ['pep-dialog'];\n if (options.panelClass) {\n dialogConfig.panelClass.push(options.panelClass);\n }\n\n if (size === 'inline') {\n dialogConfig.height = options.height || 'auto';\n dialogConfig.maxWidth = options.maxWidth || '100vw';\n dialogConfig.maxHeight = options.maxHeight || '100vh';\n dialogConfig.minWidth = options.minWidth || '300px';\n }\n\n dialogConfig.panelClass.push(size);\n\n dialogConfig.scrollStrategy = this.overlay.scrollStrategies.noop();\n // dialogConfig.scrollStrategy = this.overlay.scrollStrategies.block();\n\n return dialogConfig;\n }\n\n openDefaultDialog(\n data: PepDialogData,\n config: MatDialogConfig = null\n ): MatDialogRef<PepDefaultDialogComponent> {\n if (!config) {\n config = this.getDialogConfig();\n }\n this.fixConfigIfNeeded(data, config);\n\n config.data = data;\n const dialogRef = this.dialog.open(PepDefaultDialogComponent, config);\n return dialogRef;\n }\n\n openDialog<T>(\n componentOrTemplateRef: ComponentType<T> | TemplateRef<T>,\n data: any = {},\n config: MatDialogConfig = null\n ): MatDialogRef<T> {\n if (!config) {\n config = this.getDialogConfig();\n }\n this.fixConfigIfNeeded(data, config);\n\n config.data = data;\n const dialogRef = this.dialog.open(componentOrTemplateRef, config);\n return dialogRef;\n }\n}\n","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\n\nimport { MatCommonModule } from '@angular/material/core';\nimport { MatButtonModule } from '@angular/material/button';\nimport { MatIconModule } from '@angular/material/icon';\nimport { MatDialogModule } from '@angular/material/dialog';\n\nimport { PepNgxLibModule } from '@pepperi-addons/ngx-lib';\nimport {\n PepIconModule,\n PepIconRegistry,\n pepIconSystemClose,\n} from '@pepperi-addons/ngx-lib/icon';\n\nimport { PepDefaultDialogComponent } from './default-dialog.component';\nimport { PepDialogComponent } from './dialog.component';\nimport { PepDialogService } from './dialog.service';\n\n@NgModule({\n imports: [\n CommonModule,\n // Material modules,\n MatCommonModule,\n MatButtonModule,\n MatIconModule,\n MatDialogModule,\n // ngx-lib modules\n PepNgxLibModule,\n PepIconModule,\n ],\n exports: [PepDialogComponent],\n declarations: [PepDefaultDialogComponent, PepDialogComponent],\n entryComponents: [PepDefaultDialogComponent],\n providers: [PepDialogService]\n})\nexport class PepDialogModule {\n constructor(private pepIconRegistry: PepIconRegistry) {\n this.pepIconRegistry.registerIcons([pepIconSystemClose]);\n }\n}\n","/*\n * Public API Surface of ngx-lib/dialog\n */\nexport * from './dialog.module';\nexport * from './dialog.model';\nexport * from './dialog.component';\nexport * from './dialog.service';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n\nexport {PepDefaultDialogComponent as ɵa} from './default-dialog.component';"],"names":["Component","ViewEncapsulation","Inject","MAT_DIALOG_DATA","MatDialogRef","EventEmitter","Input","Output","MatDialogConfig","Injectable","MatDialog","PepLayoutService","Overlay","pepIconSystemClose","NgModule","CommonModule","MatCommonModule","MatButtonModule","MatIconModule","MatDialogModule","PepNgxLibModule","PepIconModule","PepIconRegistry"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;QAmBI,+BAAY,KAAU,EAAE,SAAc,EAAE,QAA2B;YAAvD,sBAAA,EAAA,UAAU;YAAE,0BAAA,EAAA,cAAc;YAAE,yBAAA,EAAA,eAA2B;YAJnE,UAAK,GAAG,EAAE,CAAC;YACX,cAAS,GAAG,EAAE,CAAC;YAIX,IAAI,CAAC,KAAK,GAAG,KAAK,CAAC;YACnB,IAAI,CAAC,SAAS,GAAG,SAAS,CAAC;YAC3B,IAAI,CAAC,QAAQ,GAAG,QAAQ,CAAC;SAC5B;oCACJ;KAAA,IAAA;;QAWG,uBAAY,OASX;;YACG,IAAI,CAAC,KAAK,GAAG,OAAO,CAAC,KAAK,IAAI,EAAE,CAAC;YACjC,IAAI,CAAC,WAAW,GAAG,OAAO,CAAC,WAAW,IAAI,OAAO,CAAC;YAClD,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC,OAAO,IAAI,EAAE,CAAC;YACrC,IAAI,CAAC,SAAS,GAAG,MAAA,OAAO,CAAC,SAAS,mCAAI,KAAK,CAAC;YAC5C,IAAI,CAAC,UAAU,GAAG,MAAA,OAAO,CAAC,UAAU,mCAAI,IAAI,CAAC;YAC7C,IAAI,CAAC,UAAU,GAAG,MAAA,OAAO,CAAC,UAAU,mCAAI,IAAI,CAAC;YAC7C,IAAI,CAAC,aAAa,GAAG,MAAA,OAAO,CAAC,aAAa,mCAAI,IAAI,CAAC;SACtD;4BACJ;KAAA;;;QC3CG,mCACoC,IAAmB,EAC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Af,eAAe,CAAiB;YAChD,IAAI,CAAC,eAAe,CAAC,aAAa,CAAC,CAACC,uBAAkB,CAAC,CAAC,CAAC;SAC5D;;;;gBApBJC,WAAQ,SAAC;oBACN,OAAO,EAAE;wBACLC,mBAAY;;wBAEZC,oBAAe;wBACfC,sBAAe;wBACfC,oBAAa;wBACbC,kBAAe;;wBAEfC,kBAAe;wBACfC,kBAAa;qBAChB;oBACD,OAAO,EAAE,CAAC,kBAAkB,CAAC;oBAC7B,YAAY,EAAE,CAAC,yBAAyB,EAAE,kBAAkB,CAAC;oBAC7D,eAAe,EAAE,CAAC,yBAAyB,CAAC;oBAC5C,SAAS,EAAE,CAAC,gBAAgB,CAAC;iBAChC;;;gBAxBGC,oBAAe;;;ICXnB;;;;ICAA;;;;;;;;;;;;;;;;;"}
|
|
@@ -250,10 +250,10 @@
|
|
|
250
250
|
var config = this.dialogService.getDialogConfig({}, 'inline');
|
|
251
251
|
config.maxWidth = '75vw';
|
|
252
252
|
config.height = '95vh';
|
|
253
|
-
|
|
253
|
+
this.enlargeImageDialogRef = this.dialogService.openDialog(this.galleryDialogTemplate, {
|
|
254
254
|
currIndex: this.currIndex,
|
|
255
255
|
}, config);
|
|
256
|
-
|
|
256
|
+
this.enlargeImageDialogRef.afterOpened().subscribe(function () {
|
|
257
257
|
_this.afterDialogOpened();
|
|
258
258
|
});
|
|
259
259
|
// Update currentIndex in galleryRef
|
|
@@ -265,6 +265,15 @@
|
|
|
265
265
|
this.dialogGalleryRef = this.gallery.ref(this.guid + "-dlgGallery");
|
|
266
266
|
this.initGalleryStyle(this.galleryDialogCont, this.dialogGalleryRef);
|
|
267
267
|
};
|
|
268
|
+
PepImagesFilmstripComponent.prototype.closeDialog = function (event) {
|
|
269
|
+
var _a, _b;
|
|
270
|
+
if (this.inDialog) {
|
|
271
|
+
(_a = this.dialogRef) === null || _a === void 0 ? void 0 : _a.close(event);
|
|
272
|
+
}
|
|
273
|
+
else {
|
|
274
|
+
(_b = this.enlargeImageDialogRef) === null || _b === void 0 ? void 0 : _b.close(event);
|
|
275
|
+
}
|
|
276
|
+
};
|
|
268
277
|
PepImagesFilmstripComponent.prototype.setThumbnailDimension = function (galleryContainer) {
|
|
269
278
|
this.galleryWidth = galleryContainer.nativeElement.clientWidth;
|
|
270
279
|
// this.galleryHeight = galleryContainer.nativeElement.clientHeight - 32; // TODO - TALK WITH TOMER
|
|
@@ -314,7 +323,7 @@
|
|
|
314
323
|
PepImagesFilmstripComponent.decorators = [
|
|
315
324
|
{ type: core.Component, args: [{
|
|
316
325
|
selector: 'pep-images-filmstrip',
|
|
317
|
-
template: "<ng-container *ngIf=\"inDialog; then galleryDialogTemplate; else regularTemplate\"></ng-container>\n<ng-template #regularTemplate>\n <ng-container [formGroup]=\"form\">\n <div class=\"images-filmstrip-container\">\n <pep-field-title *ngIf=\"renderTitle\" [label]=\"label\" [xAlignment]=\"xAlignment\" [showTitle]=\"showTitle\">\n </pep-field-title>\n <div #galleryCont class=\"img-wrapper\" [ngClass]=\"isVertical ? 'vertical-gallery' : 'horizontal-gallery'\"\n [style.height]=\"fieldHeight\">\n <pep-button *ngIf=\"items?.length > 1\" iconName=\"arrow_left_alt\" styleType=\"weak-invert\" sizeType=\"sm\"\n (click)=\"formGallery.prev()\" class=\"gallery-arrow start-arrow\">\n </pep-button>\n <gallery #formGallery id=\"{{guid}}-gallery\" (itemClick)=\"enlargeImage($event);\" [imageSize]=\"'contain'\"\n (indexChange)=\"indexChange($event)\" (error)=\"onError($event)\">\n </gallery>\n <pep-button *ngIf=\"items?.length > 1\" iconName=\"arrow_right_alt\" styleType=\"weak-invert\" sizeType=\"sm\"\n (click)=\"formGallery.next()\" class=\"gallery-arrow end-arrow\">\n </pep-button>\n </div>\n </div>\n </ng-container>\n</ng-template>\n\n<ng-template #galleryDialogTemplate>\n <div class=\"gallery-dialog\">\n <pep-dialog [title]=\"label\" [showFooter]=\"false\">\n <div pep-dialog-content #galleryDialogCont class=\"gallery-dialog-content\"\n [ngClass]=\"isVertical ? 'vertical-gallery' : 'horizontal-gallery'\">\n <pep-button *ngIf=\"items?.length > 1\" iconName=\"arrow_left_alt\" styleType=\"weak-invert\"\n (click)=\"dialogGallery.prev()\" class=\"gallery-arrow start-arrow\">\n </pep-button>\n <gallery #dialogGallery id=\"{{guid}}-dlgGallery\" [imageSize]=\"'contain'\"\n (indexChange)=\"indexChange($event)\" (error)=\"onError($event)\">\n </gallery>\n <pep-button *ngIf=\"items?.length > 1\" iconName=\"arrow_right_alt\" styleType=\"weak-invert\"\n (click)=\"dialogGallery.next()\" class=\"gallery-arrow end-arrow\">\n </pep-button>\n </div>\n </pep-dialog>\n </div>\n</ng-template>\n\n<!-- Add custom template to image items -->\n<ng-template #itemTemplate let-index=\"index\" let-type=\"type\" let-data=\"data\" let-currIndex=\"currIndex\">\n <ng-container *ngIf=\"index === currIndex\">\n <ngx-imageviewer [src]=\"data.src\">\n </ngx-imageviewer>\n </ng-container>\n</ng-template>",
|
|
326
|
+
template: "<ng-container *ngIf=\"inDialog; then galleryDialogTemplate; else regularTemplate\"></ng-container>\n<ng-template #regularTemplate>\n <ng-container [formGroup]=\"form\">\n <div class=\"images-filmstrip-container\">\n <pep-field-title *ngIf=\"renderTitle\" [label]=\"label\" [xAlignment]=\"xAlignment\" [showTitle]=\"showTitle\">\n </pep-field-title>\n <div #galleryCont class=\"img-wrapper\" [ngClass]=\"isVertical ? 'vertical-gallery' : 'horizontal-gallery'\"\n [style.height]=\"fieldHeight\">\n <pep-button *ngIf=\"items?.length > 1\" iconName=\"arrow_left_alt\" styleType=\"weak-invert\" sizeType=\"sm\"\n (click)=\"formGallery.prev()\" class=\"gallery-arrow start-arrow\">\n </pep-button>\n <gallery #formGallery id=\"{{guid}}-gallery\" (itemClick)=\"enlargeImage($event);\" [imageSize]=\"'contain'\"\n (indexChange)=\"indexChange($event)\" (error)=\"onError($event)\">\n </gallery>\n <pep-button *ngIf=\"items?.length > 1\" iconName=\"arrow_right_alt\" styleType=\"weak-invert\" sizeType=\"sm\"\n (click)=\"formGallery.next()\" class=\"gallery-arrow end-arrow\">\n </pep-button>\n </div>\n </div>\n </ng-container>\n</ng-template>\n\n<ng-template #galleryDialogTemplate>\n <div class=\"gallery-dialog\">\n <pep-dialog [title]=\"label\" [showFooter]=\"false\" (close)=\"closeDialog($event)\">\n <div pep-dialog-content #galleryDialogCont class=\"gallery-dialog-content\"\n [ngClass]=\"isVertical ? 'vertical-gallery' : 'horizontal-gallery'\">\n <pep-button *ngIf=\"items?.length > 1\" iconName=\"arrow_left_alt\" styleType=\"weak-invert\"\n (click)=\"dialogGallery.prev()\" class=\"gallery-arrow start-arrow\">\n </pep-button>\n <gallery #dialogGallery id=\"{{guid}}-dlgGallery\" [imageSize]=\"'contain'\"\n (indexChange)=\"indexChange($event)\" (error)=\"onError($event)\">\n </gallery>\n <pep-button *ngIf=\"items?.length > 1\" iconName=\"arrow_right_alt\" styleType=\"weak-invert\"\n (click)=\"dialogGallery.next()\" class=\"gallery-arrow end-arrow\">\n </pep-button>\n </div>\n </pep-dialog>\n </div>\n</ng-template>\n\n<!-- Add custom template to image items -->\n<ng-template #itemTemplate let-index=\"index\" let-type=\"type\" let-data=\"data\" let-currIndex=\"currIndex\">\n <ng-container *ngIf=\"index === currIndex\">\n <ngx-imageviewer [src]=\"data.src\">\n </ngx-imageviewer>\n </ng-container>\n</ng-template>",
|
|
318
327
|
// animations: [slideInAnimation],
|
|
319
328
|
providers: [
|
|
320
329
|
{
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pepperi-addons-ngx-lib-images-filmstrip.umd.js","sources":["../../../projects/ngx-lib/images-filmstrip/images-filmstrip.component.ts","../../../projects/ngx-lib/images-filmstrip/images-filmstrip.module.ts","../../../projects/ngx-lib/images-filmstrip/public-api.ts","../../../projects/ngx-lib/images-filmstrip/pepperi-addons-ngx-lib-images-filmstrip.ts"],"sourcesContent":["import {\n Component,\n ViewChild,\n OnInit,\n OnDestroy,\n AfterViewInit,\n ElementRef,\n Input,\n TemplateRef,\n Renderer2,\n ChangeDetectorRef,\n Inject,\n Optional,\n ViewContainerRef,\n OnChanges,\n} from '@angular/core';\nimport {\n trigger,\n state,\n style,\n transition,\n animate,\n} from '@angular/animations';\nimport { FormGroup } from '@angular/forms';\nimport { MAT_DIALOG_DATA, MatDialogRef } from '@angular/material/dialog';\nimport { TranslateService } from '@ngx-translate/core';\nimport {\n Gallery,\n GalleryConfig,\n LoadingStrategy,\n SlidingDirection,\n ThumbnailsPosition,\n GalleryItem,\n ImageItem,\n GalleryRef,\n} from 'ng-gallery';\nimport {\n PepCustomizationService,\n PepLayoutType,\n PepLayoutService,\n PepFileService,\n PepHorizontalAlignment,\n DEFAULT_HORIZONTAL_ALIGNMENT,\n PepImagesField,\n PepUtilitiesService,\n PepGuid\n} from '@pepperi-addons/ngx-lib';\nimport { PepDialogService } from '@pepperi-addons/ngx-lib/dialog';\nimport { pepIconArrowRightAlt, pepIconArrowLeftAlt, PepIconRegistry, pepIconNoImage2 } from '@pepperi-addons/ngx-lib/icon';\n\nimport 'hammerjs';\n\ninterface IPepImagesFilmstripDialogData {\n currIndex: number;\n key: string;\n value: string;\n label: string;\n uid: string;\n showThumbnails: boolean;\n}\n\n// export const slideInAnimation = trigger('slideAnimation', [\n// state('in', style({ transform: 'translateY(0)', opacity: 1 })),\n// transition(':enter', [\n// style({ transform: 'translateY(-100%)', opacity: 0 }),\n// animate(400)\n// ]),\n// transition(':leave', [\n// animate(400, style({ transform: 'translateY(-100%)', opacity: 0 }))\n// ])\n// ]);\n\nimport {\n IMAGEVIEWER_CONFIG,\n ImageViewerConfig,\n createButtonConfig,\n} from '@hallysonh/ngx-imageviewer';\nimport { DOCUMENT } from '@angular/common';\n\nexport function createViewerConfig(\n translate: TranslateService\n): ImageViewerConfig {\n return {\n // width: 850,\n // height: 150,\n bgStyle: '#FFF', // component background style\n // scaleStep: 0.1, // zoom scale step (using the zoom in/out buttons)\n // rotateStepper: false, // touch rotate should rotate only 90 to 90 degrees\n loadingMessage: translate.instant('MESSAGES.INFO_LOADING_FILE'), // 'Loading...',\n // buttonStyle: {\n // iconFontFamily: 'Material Icons', // font used to render the button icons\n // alpha: 0.5, // buttons' transparence value\n // hoverAlpha: 0.7, // buttons' transparence value when mouse is over\n // bgStyle: '#000000', // buttons' background style\n // iconStyle: '#ffffff', // buttons' icon colors\n // borderStyle: '#000000', // buttons' border style\n // borderWidth: 0, // buttons' border width (0 == disabled)\n // },\n // tooltips: {\n // enabled: true, // enable or disable tooltips for buttons\n // bgStyle: '#000000', // tooltip background style\n // bgAlpha: 0.5, // tooltip background transparence\n // textStyle: '#ffffff', // tooltip's text style\n // textAlpha: 0.9, // tooltip's text transparence\n // padding: 15, // tooltip padding\n // radius: 20, // tooltip border radius\n // },\n // shorter button configuration style\n nextPageButton: createButtonConfig(\n 'navigate_next',\n 'Next page',\n 0,\n false\n ),\n beforePageButton: createButtonConfig(\n 'navigate_before',\n 'Previous page',\n 1,\n false\n ),\n zoomOutButton: createButtonConfig('zoom_out', 'Zoom out', 0, false),\n zoomInButton: createButtonConfig('zoom_in', 'Zoom in', 1, false),\n rotateLeftButton: createButtonConfig(\n 'rotate_left',\n 'Rotate left',\n 2,\n false\n ),\n rotateRightButton: createButtonConfig(\n 'rotate_right',\n 'Rotate right',\n 3,\n false\n ),\n resetButton: createButtonConfig('autorenew', 'Reset', 4, false),\n };\n}\n\n@Component({\n selector: 'pep-images-filmstrip',\n templateUrl: './images-filmstrip.component.html',\n styleUrls: ['./images-filmstrip.component.scss', './images-filmstrip.component.theme.scss'],\n // animations: [slideInAnimation],\n providers: [\n {\n provide: IMAGEVIEWER_CONFIG,\n // useValue: IMAGEVIEWER_CONFIG_DEFAULT,\n useFactory: createViewerConfig,\n deps: [TranslateService],\n },\n ],\n})\nexport class PepImagesFilmstripComponent\n implements OnInit, OnChanges, AfterViewInit, OnDestroy {\n // @ViewChild('ngxViewerImage') ngxViewerImage: any; // TODO: Check if we need to use this??\n @Input() key = '';\n @Input() value = '';\n @Input() label = '';\n @Input() xAlignment: PepHorizontalAlignment = DEFAULT_HORIZONTAL_ALIGNMENT;\n\n private _rowSpan = 1;\n @Input()\n set rowSpan(value) {\n this._rowSpan = value;\n this.setFieldHeight();\n }\n get rowSpan(): number {\n return this._rowSpan;\n }\n\n controlType = 'images';\n\n @Input() form: FormGroup = null;\n @Input() uid = '0';\n @Input() showTitle = false;\n @Input() renderTitle = true;\n\n private _layoutType: PepLayoutType = 'form';\n @Input()\n set layoutType(value: PepLayoutType) {\n this._layoutType = value;\n this.setFieldHeight();\n }\n get layoutType(): PepLayoutType {\n return this._layoutType;\n }\n\n @Input() currIndex = 0;\n @Input() showThumbnails = false;\n\n @ViewChild('galleryCont') galleryCont: ElementRef;\n @ViewChild('galleryDialogTemplate', { read: TemplateRef })\n galleryDialogTemplate: TemplateRef<any>;\n @ViewChild('galleryDialogCont') galleryDialogCont: ElementRef;\n\n config: GalleryConfig;\n items: GalleryItem[] = null;\n inDialog = false;\n\n mandatory = false;\n readonly = false;\n disabled = false;\n fieldHeight = '';\n standAlone = false;\n\n galleryWidth = 0;\n galleryHeight;\n isVertical = false;\n galleryRef: GalleryRef;\n dialogGalleryRef: GalleryRef;\n guid: string;\n\n constructor(\n private customizationService: PepCustomizationService,\n private dialogService: PepDialogService,\n private layoutService: PepLayoutService,\n private fileService: PepFileService,\n private iconRegistry: PepIconRegistry,\n private utilitiesService: PepUtilitiesService,\n private gallery: Gallery,\n private renderer: Renderer2,\n private element: ElementRef,\n private cd: ChangeDetectorRef,\n @Optional() @Inject(DOCUMENT) private document: any,\n @Optional()\n private dialogRef: MatDialogRef<PepImagesFilmstripComponent>,\n @Optional()\n @Inject(MAT_DIALOG_DATA)\n private data: IPepImagesFilmstripDialogData\n ) {\n // If data exist copy all data properties into this.\n if (dialogRef && data) {\n this.inDialog = true;\n\n Object.keys(data).forEach((key) => {\n if (key in this) {\n this[key] = data[key];\n }\n });\n }\n\n this.config = {\n nav: false, // Show navigation buttons\n // navIcon: pepIconArrowRightAlt.data,\n // loop: true,\n // zoomOut: 0,\n // dots: false,\n // dotsPosition: 'bottom',\n // counterPosition: 'top',\n // thumb: true,\n counter: false, // Show counter\n gestures: true, // Use touch events (requires hammer.js)\n // autoPlay: false,\n // thumbWidth: 120,\n // thumbHeight: 90,\n imageSize: 'contain',\n // panSensitivity: 25,\n // disableThumb: false,\n // playerInterval: 3000,\n // thumbMode: ThumbnailsMode.Free,\n // thumbPosition: ThumbnailsPosition.Bottom,\n loadingStrategy: LoadingStrategy.Preload,\n // slidingDirection: SlidingDirection.Horizontal,\n };\n\n this.guid = PepGuid.newGuid();\n }\n\n private setFieldHeight(): void {\n this.fieldHeight = this.customizationService.calculateFieldHeight(\n this.layoutType,\n this.rowSpan,\n this.standAlone\n );\n }\n\n private setDefaultForm(): void {\n const pepField = new PepImagesField({\n key: this.key,\n value: this.value,\n mandatory: this.mandatory,\n readonly: this.readonly,\n disabled: this.disabled,\n });\n this.form = this.customizationService.getDefaultFromGroup(pepField);\n }\n\n // private renderNavIcon(galleryContainer, isLeft: boolean) {\n // let iconName = isLeft ? pepIconArrowLeftAlt.name : pepIconArrowRightAlt.name;\n // const svgData = this.iconRegistry.getIcon(iconName);\n // const svgIcon = this.utilitiesService.getSvgElementFromString(\n // this.document,\n // svgData\n // );\n\n // const elementNameToFind = isLeft ? 'g-nav-prev' : 'g-nav-next'\n\n // const elementArr = galleryContainer.nativeElement.querySelectorAll(`.${elementNameToFind}`);\n // if (elementArr && elementArr.length > 0) {\n // elementArr[0].appendChild(svgIcon);\n // this.renderer.addClass(svgIcon, 'svg-icon');\n // }\n // }\n\n ngOnInit(): void {\n if (!this.inDialog) {\n if (this.form === null) {\n this.standAlone = true;\n this.setFieldHeight();\n this.setDefaultForm();\n\n this.renderer.addClass(\n this.element.nativeElement,\n PepCustomizationService.STAND_ALONE_FIELD_CLASS_NAME\n );\n\n if (!this.renderTitle) {\n this.renderer.addClass(\n this.element.nativeElement,\n PepCustomizationService.STAND_ALONE_FIELD_NO_SPACING_CLASS_NAME\n );\n }\n }\n }\n\n if (this.items === null) {\n const imgArr = this.value ? this.value.split(';') : [];\n // add No image image when there is no images\n if (imgArr.length === 0) {\n const noImageSrc = this.fileService.getSvgAsImageSrc(\n pepIconNoImage2.data\n );\n imgArr.push(noImageSrc);\n }\n\n this.items = imgArr.map(\n (img) => new ImageItem({ src: img, thumb: img })\n );\n }\n\n this.config.dots = this.config.nav = this.items.length > 1;\n this.config.thumb =\n (this.key === 'ItemFilmstripImages' || this.showThumbnails) &&\n this.items.length > 1\n ? true\n : false;\n this.currIndex =\n this.key === 'ItemFilmstripImages' &&\n this.currIndex === 0 &&\n this.items.length > 1\n ? Math.floor(this.items.length / 2) - 1\n : this.currIndex;\n }\n\n ngAfterViewInit(): void {\n if (this.inDialog) {\n this.afterDialogOpened();\n } else {\n this.galleryRef = this.gallery.ref(\n `${this.guid}-gallery`\n );\n this.initGalleryStyle(this.galleryCont, this.galleryRef);\n }\n }\n\n ngOnChanges(): void {\n if (this.standAlone) {\n this.setDefaultForm();\n }\n }\n\n ngOnDestroy(): void {\n if (this.galleryRef) {\n this.galleryRef.destroy();\n }\n if (this.dialogGalleryRef) {\n this.dialogGalleryRef.destroy();\n }\n // if (this.myPinch) { this.myPinch.destroy(); }\n }\n\n initGalleryStyle(galleryContainer, galleryRef): void {\n setTimeout(() => {\n // Set thumbnails position and sliding direction\n this.setThumbnailDimension(galleryContainer);\n galleryRef.setConfig(this.config);\n // this.renderNavIcon(galleryContainer, true);\n // this.renderNavIcon(galleryContainer, false);\n }, 0);\n\n const currentIndex = this.currIndex;\n if (currentIndex > 0) {\n setTimeout(() => {\n galleryRef.load(this.items);\n galleryRef.set(currentIndex);\n }, 0);\n // galleryRef.set(currentIndex);\n } else {\n galleryRef.load(this.items);\n }\n }\n\n onError(e): void {\n const noImageSrc = this.fileService.getSvgAsImageSrc(\n pepIconNoImage2.data\n );\n const noimg = new ImageItem({ src: noImageSrc, thumb: noImageSrc });\n this.items.splice(e.itemIndex, 1, noimg);\n }\n\n enlargeImage(event: any): void {\n const config = this.dialogService.getDialogConfig({}, 'inline');\n config.maxWidth = '75vw';\n config.height = '95vh';\n\n const dialogRef = this.dialogService.openDialog(\n this.galleryDialogTemplate,\n {\n currIndex: this.currIndex,\n },\n config\n );\n\n dialogRef.afterOpened().subscribe(() => {\n this.afterDialogOpened();\n });\n\n // Update currentIndex in galleryRef\n // dialogRef.afterClosed().subscribe(value => {\n // this.galleryRef.set(this.currIndex);\n // });\n }\n\n afterDialogOpened(): void {\n this.dialogGalleryRef = this.gallery.ref(\n `${this.guid}-dlgGallery`\n );\n this.initGalleryStyle(this.galleryDialogCont, this.dialogGalleryRef);\n }\n\n setThumbnailDimension(galleryContainer): void {\n this.galleryWidth = galleryContainer.nativeElement.clientWidth;\n // this.galleryHeight = galleryContainer.nativeElement.clientHeight - 32; // TODO - TALK WITH TOMER\n this.galleryHeight = this.inDialog\n ? galleryContainer.nativeElement.clientHeight - 32\n : galleryContainer.nativeElement.clientHeight;\n // this.galleryHeight = galleryContainer.nativeElement.clientHeight - 32;\n this.cd.detectChanges();\n\n this.isVertical = this.galleryWidth < this.galleryHeight;\n this.cd.detectChanges();\n if (this.isVertical) {\n let width =\n (this.galleryWidth - (this.items.length - 1) * 16) /\n this.items.length;\n width = Math.min(Math.max(width, 24), 96);\n\n this.config.thumbHeight = width;\n this.config.thumbWidth = width + 16;\n } else {\n let height =\n (this.galleryHeight - (this.items.length - 1) * 16) /\n this.items.length;\n height = Math.min(Math.max(height, 24), 96);\n\n this.config.thumbHeight = height + 16;\n this.config.thumbWidth = height;\n }\n\n this.config.thumbPosition = this.isVertical\n ? ThumbnailsPosition.Bottom\n : this.layoutService.isRtl()\n ? ThumbnailsPosition.Right\n : ThumbnailsPosition.Left;\n this.config.slidingDirection =\n this.key !== 'ItemFilmstripImages'\n ? SlidingDirection.Horizontal\n : this.isVertical\n ? SlidingDirection.Horizontal\n : SlidingDirection.Vertical;\n\n this.config.imageSize = 'contain';\n }\n\n indexChange(item: any): void {\n this.currIndex = item.currIndex;\n // if (this.ngxViewerImage && this.ngxViewerImage.scale) {\n // this.ngxViewerImage.scale = 1;\n // this.updateStyle();\n // }\n }\n\n // scrollFunction(e: any): boolean {\n // e.deltaY > 0 ? this.zoomOut() : this.zoomIn();\n // return false;\n // }\n\n // zoomIn(): void {\n // if (this.ngxViewerImage.scale < 2) {\n // this.ngxViewerImage.scale *= (1 + this.ngxViewerImage.config.zoomFactor);\n // } else {\n // this.ngxViewerImage.scale = 2;\n // }\n // this.updateStyle();\n // }\n\n // zoomOut(): void {\n // if (this.ngxViewerImage.scale > this.ngxViewerImage.config.zoomFactor) {\n // this.ngxViewerImage.scale /= (1 + this.ngxViewerImage.config.zoomFactor);\n // }\n // this.updateStyle();\n // }\n\n // private updateStyle(): void {\n // this.ngxViewerImage.style.transform = `translate(${this.ngxViewerImage.translateX}px,\n // ${this.ngxViewerImage.translateY}px) rotate(${this.ngxViewerImage.rotation}deg) scale(${this.ngxViewerImage.scale})`;\n\n // this.cd.detectChanges();\n // }\n}\n","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { ReactiveFormsModule } from '@angular/forms';\n\nimport { MatCommonModule } from '@angular/material/core';\nimport { MatFormFieldModule } from '@angular/material/form-field';\nimport { MatDialogModule } from '@angular/material/dialog';\nimport { MatIconModule } from '@angular/material/icon';\n\nimport { PepNgxLibModule } from '@pepperi-addons/ngx-lib';\nimport { PepFieldTitleModule } from '@pepperi-addons/ngx-lib/field-title';\nimport { PepButtonModule } from '@pepperi-addons/ngx-lib/button';\nimport {\n PepIconModule,\n PepIconRegistry,\n pepIconSystemEdit,\n pepIconSystemClose,\n pepIconArrowRightAlt,\n pepIconArrowLeftAlt,\n} from '@pepperi-addons/ngx-lib/icon';\nimport { PepDialogModule } from '@pepperi-addons/ngx-lib/dialog';\n\nimport { GalleryModule } from 'ng-gallery';\nimport { ImageViewerModule } from '@hallysonh/ngx-imageviewer';\n\nimport { PepImagesFilmstripComponent } from './images-filmstrip.component';\n\n@NgModule({\n imports: [\n CommonModule,\n ReactiveFormsModule,\n // Material modules,\n MatCommonModule,\n MatFormFieldModule,\n MatDialogModule,\n MatIconModule,\n // External modules\n GalleryModule,\n ImageViewerModule,\n // ImageViewerModule.forRoot({\n // btnClass: 'default', // The CSS class(es) that will apply to the buttons\n // zoomFactor: 0.1, // The amount that the scale will be increased by\n // containerBackgroundColor: 'transparent', // The color to use for the background. This can provided in hex, or rgb(a).\n // wheelZoom: true, // If true, the mouse wheel can be used to zoom in\n // allowFullscreen: false, // If true, the fullscreen button will be shown, allowing the user to entr fullscreen mode\n // btnIcons: {\n // // The icon classes that will apply to the buttons. By default, font-awesome is used.\n // zoomIn: 'fa fa-plus',\n // zoomOut: 'fa fa-minus',\n // rotateClockwise: 'fa fa-repeat',\n // rotateCounterClockwise: 'fa fa-undo',\n // next: 'fa fa-arrow-right',\n // prev: 'fa fa-arrow-left',\n // fullscreen: 'fa fa-arrows-alt'\n // }\n // }),\n // ngx-lib modules\n PepNgxLibModule,\n PepButtonModule,\n PepIconModule,\n PepFieldTitleModule,\n PepDialogModule,\n ],\n exports: [PepImagesFilmstripComponent],\n declarations: [PepImagesFilmstripComponent],\n})\nexport class PepImagesFilmstripModule {\n constructor(private pepIconRegistry: PepIconRegistry) {\n this.pepIconRegistry.registerIcons([\n pepIconSystemEdit,\n pepIconSystemClose,\n pepIconArrowRightAlt,\n pepIconArrowLeftAlt,\n ]);\n }\n}\n","/*\n * Public API Surface of ngx-lib/images-filmstrip\n */\nexport * from './images-filmstrip.module';\nexport * from './images-filmstrip.component';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":["createButtonConfig","DEFAULT_HORIZONTAL_ALIGNMENT","LoadingStrategy","PepGuid","PepImagesField","PepCustomizationService","pepIconNoImage2","ImageItem","ThumbnailsPosition","SlidingDirection","Component","IMAGEVIEWER_CONFIG","TranslateService","PepDialogService","PepLayoutService","PepFileService","PepIconRegistry","PepUtilitiesService","Gallery","Renderer2","ElementRef","ChangeDetectorRef","Optional","Inject","DOCUMENT","MatDialogRef","MAT_DIALOG_DATA","Input","ViewChild","TemplateRef","pepIconSystemEdit","pepIconSystemClose","pepIconArrowRightAlt","pepIconArrowLeftAlt","NgModule","CommonModule","ReactiveFormsModule","MatCommonModule","MatFormFieldModule","MatDialogModule","MatIconModule","GalleryModule","ImageViewerModule","PepNgxLibModule","PepButtonModule","PepIconModule","PepFieldTitleModule","PepDialogModule"],"mappings":";;;;;;aA+EgB,kBAAkB,CAC9B,SAA2B;QAE3B,OAAO;;;YAGH,OAAO,EAAE,MAAM;;;YAGf,cAAc,EAAE,SAAS,CAAC,OAAO,CAAC,4BAA4B,CAAC;;;;;;;;;;;;;;;;;;;;YAoB/D,cAAc,EAAEA,iCAAkB,CAC9B,eAAe,EACf,WAAW,EACX,CAAC,EACD,KAAK,CACR;YACD,gBAAgB,EAAEA,iCAAkB,CAChC,iBAAiB,EACjB,eAAe,EACf,CAAC,EACD,KAAK,CACR;YACD,aAAa,EAAEA,iCAAkB,CAAC,UAAU,EAAE,UAAU,EAAE,CAAC,EAAE,KAAK,CAAC;YACnE,YAAY,EAAEA,iCAAkB,CAAC,SAAS,EAAE,SAAS,EAAE,CAAC,EAAE,KAAK,CAAC;YAChE,gBAAgB,EAAEA,iCAAkB,CAChC,aAAa,EACb,aAAa,EACb,CAAC,EACD,KAAK,CACR;YACD,iBAAiB,EAAEA,iCAAkB,CACjC,cAAc,EACd,cAAc,EACd,CAAC,EACD,KAAK,CACR;YACD,WAAW,EAAEA,iCAAkB,CAAC,WAAW,EAAE,OAAO,EAAE,CAAC,EAAE,KAAK,CAAC;SAClE,CAAC;IACN,CAAC;;QA4EG,qCACY,oBAA6C,EAC7C,aAA+B,EAC/B,aAA+B,EAC/B,WAA2B,EAC3B,YAA6B,EAC7B,gBAAqC,EACrC,OAAgB,EAChB,QAAmB,EACnB,OAAmB,EACnB,EAAqB,EACS,QAA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":"pepperi-addons-ngx-lib-images-filmstrip.umd.js","sources":["../../../projects/ngx-lib/images-filmstrip/images-filmstrip.component.ts","../../../projects/ngx-lib/images-filmstrip/images-filmstrip.module.ts","../../../projects/ngx-lib/images-filmstrip/public-api.ts","../../../projects/ngx-lib/images-filmstrip/pepperi-addons-ngx-lib-images-filmstrip.ts"],"sourcesContent":["import {\n Component,\n ViewChild,\n OnInit,\n OnDestroy,\n AfterViewInit,\n ElementRef,\n Input,\n TemplateRef,\n Renderer2,\n ChangeDetectorRef,\n Inject,\n Optional,\n ViewContainerRef,\n OnChanges,\n} from '@angular/core';\nimport {\n trigger,\n state,\n style,\n transition,\n animate,\n} from '@angular/animations';\nimport { FormGroup } from '@angular/forms';\nimport { MAT_DIALOG_DATA, MatDialogRef } from '@angular/material/dialog';\nimport { TranslateService } from '@ngx-translate/core';\nimport {\n Gallery,\n GalleryConfig,\n LoadingStrategy,\n SlidingDirection,\n ThumbnailsPosition,\n GalleryItem,\n ImageItem,\n GalleryRef,\n} from 'ng-gallery';\nimport {\n PepCustomizationService,\n PepLayoutType,\n PepLayoutService,\n PepFileService,\n PepHorizontalAlignment,\n DEFAULT_HORIZONTAL_ALIGNMENT,\n PepImagesField,\n PepUtilitiesService,\n PepGuid\n} from '@pepperi-addons/ngx-lib';\nimport { PepDialogService } from '@pepperi-addons/ngx-lib/dialog';\nimport { pepIconArrowRightAlt, pepIconArrowLeftAlt, PepIconRegistry, pepIconNoImage2 } from '@pepperi-addons/ngx-lib/icon';\n\nimport 'hammerjs';\n\ninterface IPepImagesFilmstripDialogData {\n currIndex: number;\n key: string;\n value: string;\n label: string;\n uid: string;\n showThumbnails: boolean;\n}\n\n// export const slideInAnimation = trigger('slideAnimation', [\n// state('in', style({ transform: 'translateY(0)', opacity: 1 })),\n// transition(':enter', [\n// style({ transform: 'translateY(-100%)', opacity: 0 }),\n// animate(400)\n// ]),\n// transition(':leave', [\n// animate(400, style({ transform: 'translateY(-100%)', opacity: 0 }))\n// ])\n// ]);\n\nimport {\n IMAGEVIEWER_CONFIG,\n ImageViewerConfig,\n createButtonConfig,\n} from '@hallysonh/ngx-imageviewer';\nimport { DOCUMENT } from '@angular/common';\n\nexport function createViewerConfig(\n translate: TranslateService\n): ImageViewerConfig {\n return {\n // width: 850,\n // height: 150,\n bgStyle: '#FFF', // component background style\n // scaleStep: 0.1, // zoom scale step (using the zoom in/out buttons)\n // rotateStepper: false, // touch rotate should rotate only 90 to 90 degrees\n loadingMessage: translate.instant('MESSAGES.INFO_LOADING_FILE'), // 'Loading...',\n // buttonStyle: {\n // iconFontFamily: 'Material Icons', // font used to render the button icons\n // alpha: 0.5, // buttons' transparence value\n // hoverAlpha: 0.7, // buttons' transparence value when mouse is over\n // bgStyle: '#000000', // buttons' background style\n // iconStyle: '#ffffff', // buttons' icon colors\n // borderStyle: '#000000', // buttons' border style\n // borderWidth: 0, // buttons' border width (0 == disabled)\n // },\n // tooltips: {\n // enabled: true, // enable or disable tooltips for buttons\n // bgStyle: '#000000', // tooltip background style\n // bgAlpha: 0.5, // tooltip background transparence\n // textStyle: '#ffffff', // tooltip's text style\n // textAlpha: 0.9, // tooltip's text transparence\n // padding: 15, // tooltip padding\n // radius: 20, // tooltip border radius\n // },\n // shorter button configuration style\n nextPageButton: createButtonConfig(\n 'navigate_next',\n 'Next page',\n 0,\n false\n ),\n beforePageButton: createButtonConfig(\n 'navigate_before',\n 'Previous page',\n 1,\n false\n ),\n zoomOutButton: createButtonConfig('zoom_out', 'Zoom out', 0, false),\n zoomInButton: createButtonConfig('zoom_in', 'Zoom in', 1, false),\n rotateLeftButton: createButtonConfig(\n 'rotate_left',\n 'Rotate left',\n 2,\n false\n ),\n rotateRightButton: createButtonConfig(\n 'rotate_right',\n 'Rotate right',\n 3,\n false\n ),\n resetButton: createButtonConfig('autorenew', 'Reset', 4, false),\n };\n}\n\n@Component({\n selector: 'pep-images-filmstrip',\n templateUrl: './images-filmstrip.component.html',\n styleUrls: ['./images-filmstrip.component.scss', './images-filmstrip.component.theme.scss'],\n // animations: [slideInAnimation],\n providers: [\n {\n provide: IMAGEVIEWER_CONFIG,\n // useValue: IMAGEVIEWER_CONFIG_DEFAULT,\n useFactory: createViewerConfig,\n deps: [TranslateService],\n },\n ],\n})\nexport class PepImagesFilmstripComponent\n implements OnInit, OnChanges, AfterViewInit, OnDestroy {\n // @ViewChild('ngxViewerImage') ngxViewerImage: any; // TODO: Check if we need to use this??\n @Input() key = '';\n @Input() value = '';\n @Input() label = '';\n @Input() xAlignment: PepHorizontalAlignment = DEFAULT_HORIZONTAL_ALIGNMENT;\n\n private _rowSpan = 1;\n @Input()\n set rowSpan(value) {\n this._rowSpan = value;\n this.setFieldHeight();\n }\n get rowSpan(): number {\n return this._rowSpan;\n }\n\n controlType = 'images';\n\n @Input() form: FormGroup = null;\n @Input() uid = '0';\n @Input() showTitle = false;\n @Input() renderTitle = true;\n\n private _layoutType: PepLayoutType = 'form';\n @Input()\n set layoutType(value: PepLayoutType) {\n this._layoutType = value;\n this.setFieldHeight();\n }\n get layoutType(): PepLayoutType {\n return this._layoutType;\n }\n\n @Input() currIndex = 0;\n @Input() showThumbnails = false;\n\n @ViewChild('galleryCont') galleryCont: ElementRef;\n @ViewChild('galleryDialogTemplate', { read: TemplateRef })\n galleryDialogTemplate: TemplateRef<any>;\n @ViewChild('galleryDialogCont') galleryDialogCont: ElementRef;\n\n config: GalleryConfig;\n items: GalleryItem[] = null;\n inDialog = false;\n\n mandatory = false;\n readonly = false;\n disabled = false;\n fieldHeight = '';\n standAlone = false;\n\n galleryWidth = 0;\n galleryHeight;\n isVertical = false;\n galleryRef: GalleryRef;\n dialogGalleryRef: GalleryRef;\n guid: string;\n\n private enlargeImageDialogRef: MatDialogRef<any>;\n\n constructor(\n private customizationService: PepCustomizationService,\n private dialogService: PepDialogService,\n private layoutService: PepLayoutService,\n private fileService: PepFileService,\n private iconRegistry: PepIconRegistry,\n private utilitiesService: PepUtilitiesService,\n private gallery: Gallery,\n private renderer: Renderer2,\n private element: ElementRef,\n private cd: ChangeDetectorRef,\n @Optional() @Inject(DOCUMENT) private document: any,\n @Optional()\n private dialogRef: MatDialogRef<PepImagesFilmstripComponent>,\n @Optional()\n @Inject(MAT_DIALOG_DATA)\n private data: IPepImagesFilmstripDialogData\n ) {\n // If data exist copy all data properties into this.\n if (dialogRef && data) {\n this.inDialog = true;\n\n Object.keys(data).forEach((key) => {\n if (key in this) {\n this[key] = data[key];\n }\n });\n }\n\n this.config = {\n nav: false, // Show navigation buttons\n // navIcon: pepIconArrowRightAlt.data,\n // loop: true,\n // zoomOut: 0,\n // dots: false,\n // dotsPosition: 'bottom',\n // counterPosition: 'top',\n // thumb: true,\n counter: false, // Show counter\n gestures: true, // Use touch events (requires hammer.js)\n // autoPlay: false,\n // thumbWidth: 120,\n // thumbHeight: 90,\n imageSize: 'contain',\n // panSensitivity: 25,\n // disableThumb: false,\n // playerInterval: 3000,\n // thumbMode: ThumbnailsMode.Free,\n // thumbPosition: ThumbnailsPosition.Bottom,\n loadingStrategy: LoadingStrategy.Preload,\n // slidingDirection: SlidingDirection.Horizontal,\n };\n\n this.guid = PepGuid.newGuid();\n }\n\n private setFieldHeight(): void {\n this.fieldHeight = this.customizationService.calculateFieldHeight(\n this.layoutType,\n this.rowSpan,\n this.standAlone\n );\n }\n\n private setDefaultForm(): void {\n const pepField = new PepImagesField({\n key: this.key,\n value: this.value,\n mandatory: this.mandatory,\n readonly: this.readonly,\n disabled: this.disabled,\n });\n this.form = this.customizationService.getDefaultFromGroup(pepField);\n }\n\n // private renderNavIcon(galleryContainer, isLeft: boolean) {\n // let iconName = isLeft ? pepIconArrowLeftAlt.name : pepIconArrowRightAlt.name;\n // const svgData = this.iconRegistry.getIcon(iconName);\n // const svgIcon = this.utilitiesService.getSvgElementFromString(\n // this.document,\n // svgData\n // );\n\n // const elementNameToFind = isLeft ? 'g-nav-prev' : 'g-nav-next'\n\n // const elementArr = galleryContainer.nativeElement.querySelectorAll(`.${elementNameToFind}`);\n // if (elementArr && elementArr.length > 0) {\n // elementArr[0].appendChild(svgIcon);\n // this.renderer.addClass(svgIcon, 'svg-icon');\n // }\n // }\n\n ngOnInit(): void {\n if (!this.inDialog) {\n if (this.form === null) {\n this.standAlone = true;\n this.setFieldHeight();\n this.setDefaultForm();\n\n this.renderer.addClass(\n this.element.nativeElement,\n PepCustomizationService.STAND_ALONE_FIELD_CLASS_NAME\n );\n\n if (!this.renderTitle) {\n this.renderer.addClass(\n this.element.nativeElement,\n PepCustomizationService.STAND_ALONE_FIELD_NO_SPACING_CLASS_NAME\n );\n }\n }\n }\n\n if (this.items === null) {\n const imgArr = this.value ? this.value.split(';') : [];\n // add No image image when there is no images\n if (imgArr.length === 0) {\n const noImageSrc = this.fileService.getSvgAsImageSrc(\n pepIconNoImage2.data\n );\n imgArr.push(noImageSrc);\n }\n\n this.items = imgArr.map(\n (img) => new ImageItem({ src: img, thumb: img })\n );\n }\n\n this.config.dots = this.config.nav = this.items.length > 1;\n this.config.thumb =\n (this.key === 'ItemFilmstripImages' || this.showThumbnails) &&\n this.items.length > 1\n ? true\n : false;\n this.currIndex =\n this.key === 'ItemFilmstripImages' &&\n this.currIndex === 0 &&\n this.items.length > 1\n ? Math.floor(this.items.length / 2) - 1\n : this.currIndex;\n }\n\n ngAfterViewInit(): void {\n if (this.inDialog) {\n this.afterDialogOpened();\n } else {\n this.galleryRef = this.gallery.ref(\n `${this.guid}-gallery`\n );\n this.initGalleryStyle(this.galleryCont, this.galleryRef);\n }\n }\n\n ngOnChanges(): void {\n if (this.standAlone) {\n this.setDefaultForm();\n }\n }\n\n ngOnDestroy(): void {\n if (this.galleryRef) {\n this.galleryRef.destroy();\n }\n if (this.dialogGalleryRef) {\n this.dialogGalleryRef.destroy();\n }\n // if (this.myPinch) { this.myPinch.destroy(); }\n }\n\n initGalleryStyle(galleryContainer, galleryRef): void {\n setTimeout(() => {\n // Set thumbnails position and sliding direction\n this.setThumbnailDimension(galleryContainer);\n galleryRef.setConfig(this.config);\n // this.renderNavIcon(galleryContainer, true);\n // this.renderNavIcon(galleryContainer, false);\n }, 0);\n\n const currentIndex = this.currIndex;\n if (currentIndex > 0) {\n setTimeout(() => {\n galleryRef.load(this.items);\n galleryRef.set(currentIndex);\n }, 0);\n // galleryRef.set(currentIndex);\n } else {\n galleryRef.load(this.items);\n }\n }\n\n onError(e): void {\n const noImageSrc = this.fileService.getSvgAsImageSrc(\n pepIconNoImage2.data\n );\n const noimg = new ImageItem({ src: noImageSrc, thumb: noImageSrc });\n this.items.splice(e.itemIndex, 1, noimg);\n }\n\n enlargeImage(event: any): void {\n const config = this.dialogService.getDialogConfig({}, 'inline');\n config.maxWidth = '75vw';\n config.height = '95vh';\n\n this.enlargeImageDialogRef = this.dialogService.openDialog(\n this.galleryDialogTemplate,\n {\n currIndex: this.currIndex,\n },\n config\n );\n\n this.enlargeImageDialogRef.afterOpened().subscribe(() => {\n this.afterDialogOpened();\n });\n\n // Update currentIndex in galleryRef\n // dialogRef.afterClosed().subscribe(value => {\n // this.galleryRef.set(this.currIndex);\n // });\n }\n\n afterDialogOpened(): void {\n this.dialogGalleryRef = this.gallery.ref(\n `${this.guid}-dlgGallery`\n );\n this.initGalleryStyle(this.galleryDialogCont, this.dialogGalleryRef);\n }\n\n closeDialog(event) {\n if (this.inDialog) {\n this.dialogRef?.close(event);\n } else {\n this.enlargeImageDialogRef?.close(event);\n }\n }\n\n setThumbnailDimension(galleryContainer): void {\n this.galleryWidth = galleryContainer.nativeElement.clientWidth;\n // this.galleryHeight = galleryContainer.nativeElement.clientHeight - 32; // TODO - TALK WITH TOMER\n this.galleryHeight = this.inDialog\n ? galleryContainer.nativeElement.clientHeight - 32\n : galleryContainer.nativeElement.clientHeight;\n // this.galleryHeight = galleryContainer.nativeElement.clientHeight - 32;\n this.cd.detectChanges();\n\n this.isVertical = this.galleryWidth < this.galleryHeight;\n this.cd.detectChanges();\n if (this.isVertical) {\n let width =\n (this.galleryWidth - (this.items.length - 1) * 16) /\n this.items.length;\n width = Math.min(Math.max(width, 24), 96);\n\n this.config.thumbHeight = width;\n this.config.thumbWidth = width + 16;\n } else {\n let height =\n (this.galleryHeight - (this.items.length - 1) * 16) /\n this.items.length;\n height = Math.min(Math.max(height, 24), 96);\n\n this.config.thumbHeight = height + 16;\n this.config.thumbWidth = height;\n }\n\n this.config.thumbPosition = this.isVertical\n ? ThumbnailsPosition.Bottom\n : this.layoutService.isRtl()\n ? ThumbnailsPosition.Right\n : ThumbnailsPosition.Left;\n this.config.slidingDirection =\n this.key !== 'ItemFilmstripImages'\n ? SlidingDirection.Horizontal\n : this.isVertical\n ? SlidingDirection.Horizontal\n : SlidingDirection.Vertical;\n\n this.config.imageSize = 'contain';\n }\n\n indexChange(item: any): void {\n this.currIndex = item.currIndex;\n // if (this.ngxViewerImage && this.ngxViewerImage.scale) {\n // this.ngxViewerImage.scale = 1;\n // this.updateStyle();\n // }\n }\n\n\n // scrollFunction(e: any): boolean {\n // e.deltaY > 0 ? this.zoomOut() : this.zoomIn();\n // return false;\n // }\n\n // zoomIn(): void {\n // if (this.ngxViewerImage.scale < 2) {\n // this.ngxViewerImage.scale *= (1 + this.ngxViewerImage.config.zoomFactor);\n // } else {\n // this.ngxViewerImage.scale = 2;\n // }\n // this.updateStyle();\n // }\n\n // zoomOut(): void {\n // if (this.ngxViewerImage.scale > this.ngxViewerImage.config.zoomFactor) {\n // this.ngxViewerImage.scale /= (1 + this.ngxViewerImage.config.zoomFactor);\n // }\n // this.updateStyle();\n // }\n\n // private updateStyle(): void {\n // this.ngxViewerImage.style.transform = `translate(${this.ngxViewerImage.translateX}px,\n // ${this.ngxViewerImage.translateY}px) rotate(${this.ngxViewerImage.rotation}deg) scale(${this.ngxViewerImage.scale})`;\n\n // this.cd.detectChanges();\n // }\n}\n","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { ReactiveFormsModule } from '@angular/forms';\n\nimport { MatCommonModule } from '@angular/material/core';\nimport { MatFormFieldModule } from '@angular/material/form-field';\nimport { MatDialogModule } from '@angular/material/dialog';\nimport { MatIconModule } from '@angular/material/icon';\n\nimport { PepNgxLibModule } from '@pepperi-addons/ngx-lib';\nimport { PepFieldTitleModule } from '@pepperi-addons/ngx-lib/field-title';\nimport { PepButtonModule } from '@pepperi-addons/ngx-lib/button';\nimport {\n PepIconModule,\n PepIconRegistry,\n pepIconSystemEdit,\n pepIconSystemClose,\n pepIconArrowRightAlt,\n pepIconArrowLeftAlt,\n} from '@pepperi-addons/ngx-lib/icon';\nimport { PepDialogModule } from '@pepperi-addons/ngx-lib/dialog';\n\nimport { GalleryModule } from 'ng-gallery';\nimport { ImageViewerModule } from '@hallysonh/ngx-imageviewer';\n\nimport { PepImagesFilmstripComponent } from './images-filmstrip.component';\n\n@NgModule({\n imports: [\n CommonModule,\n ReactiveFormsModule,\n // Material modules,\n MatCommonModule,\n MatFormFieldModule,\n MatDialogModule,\n MatIconModule,\n // External modules\n GalleryModule,\n ImageViewerModule,\n // ImageViewerModule.forRoot({\n // btnClass: 'default', // The CSS class(es) that will apply to the buttons\n // zoomFactor: 0.1, // The amount that the scale will be increased by\n // containerBackgroundColor: 'transparent', // The color to use for the background. This can provided in hex, or rgb(a).\n // wheelZoom: true, // If true, the mouse wheel can be used to zoom in\n // allowFullscreen: false, // If true, the fullscreen button will be shown, allowing the user to entr fullscreen mode\n // btnIcons: {\n // // The icon classes that will apply to the buttons. By default, font-awesome is used.\n // zoomIn: 'fa fa-plus',\n // zoomOut: 'fa fa-minus',\n // rotateClockwise: 'fa fa-repeat',\n // rotateCounterClockwise: 'fa fa-undo',\n // next: 'fa fa-arrow-right',\n // prev: 'fa fa-arrow-left',\n // fullscreen: 'fa fa-arrows-alt'\n // }\n // }),\n // ngx-lib modules\n PepNgxLibModule,\n PepButtonModule,\n PepIconModule,\n PepFieldTitleModule,\n PepDialogModule,\n ],\n exports: [PepImagesFilmstripComponent],\n declarations: [PepImagesFilmstripComponent],\n})\nexport class PepImagesFilmstripModule {\n constructor(private pepIconRegistry: PepIconRegistry) {\n this.pepIconRegistry.registerIcons([\n pepIconSystemEdit,\n pepIconSystemClose,\n pepIconArrowRightAlt,\n pepIconArrowLeftAlt,\n ]);\n }\n}\n","/*\n * Public API Surface of ngx-lib/images-filmstrip\n */\nexport * from './images-filmstrip.module';\nexport * from './images-filmstrip.component';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":["createButtonConfig","DEFAULT_HORIZONTAL_ALIGNMENT","LoadingStrategy","PepGuid","PepImagesField","PepCustomizationService","pepIconNoImage2","ImageItem","ThumbnailsPosition","SlidingDirection","Component","IMAGEVIEWER_CONFIG","TranslateService","PepDialogService","PepLayoutService","PepFileService","PepIconRegistry","PepUtilitiesService","Gallery","Renderer2","ElementRef","ChangeDetectorRef","Optional","Inject","DOCUMENT","MatDialogRef","MAT_DIALOG_DATA","Input","ViewChild","TemplateRef","pepIconSystemEdit","pepIconSystemClose","pepIconArrowRightAlt","pepIconArrowLeftAlt","NgModule","CommonModule","ReactiveFormsModule","MatCommonModule","MatFormFieldModule","MatDialogModule","MatIconModule","GalleryModule","ImageViewerModule","PepNgxLibModule","PepButtonModule","PepIconModule","PepFieldTitleModule","PepDialogModule"],"mappings":";;;;;;aA+EgB,kBAAkB,CAC9B,SAA2B;QAE3B,OAAO;;;YAGH,OAAO,EAAE,MAAM;;;YAGf,cAAc,EAAE,SAAS,CAAC,OAAO,CAAC,4BAA4B,CAAC;;;;;;;;;;;;;;;;;;;;YAoB/D,cAAc,EAAEA,iCAAkB,CAC9B,eAAe,EACf,WAAW,EACX,CAAC,EACD,KAAK,CACR;YACD,gBAAgB,EAAEA,iCAAkB,CAChC,iBAAiB,EACjB,eAAe,EACf,CAAC,EACD,KAAK,CACR;YACD,aAAa,EAAEA,iCAAkB,CAAC,UAAU,EAAE,UAAU,EAAE,CAAC,EAAE,KAAK,CAAC;YACnE,YAAY,EAAEA,iCAAkB,CAAC,SAAS,EAAE,SAAS,EAAE,CAAC,EAAE,KAAK,CA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