@pepperi-addons/ngx-composite-lib 0.0.16-beta.4 → 0.0.16-beta.40
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-composite-lib-color-settings.umd.js +10 -1
- package/bundles/pepperi-addons-ngx-composite-lib-color-settings.umd.js.map +1 -1
- package/bundles/pepperi-addons-ngx-composite-lib-data-view-builder.umd.js +393 -0
- package/bundles/pepperi-addons-ngx-composite-lib-data-view-builder.umd.js.map +1 -0
- package/bundles/pepperi-addons-ngx-composite-lib-file-status-panel.umd.js +15 -10
- package/bundles/pepperi-addons-ngx-composite-lib-file-status-panel.umd.js.map +1 -1
- package/bundles/pepperi-addons-ngx-composite-lib-generic-form.umd.js +91 -58
- package/bundles/pepperi-addons-ngx-composite-lib-generic-form.umd.js.map +1 -1
- package/bundles/pepperi-addons-ngx-composite-lib-generic-list.umd.js +118 -73
- package/bundles/pepperi-addons-ngx-composite-lib-generic-list.umd.js.map +1 -1
- package/bundles/pepperi-addons-ngx-composite-lib-group-buttons-settings.umd.js +5 -2
- package/bundles/pepperi-addons-ngx-composite-lib-group-buttons-settings.umd.js.map +1 -1
- package/bundles/pepperi-addons-ngx-composite-lib.umd.js +114 -50
- package/bundles/pepperi-addons-ngx-composite-lib.umd.js.map +1 -1
- package/color-settings/color-settings.component.d.ts +4 -1
- package/core/common/directives/reset-configuration-field.directive.d.ts +1 -0
- package/core/common/services/dimx.service.d.ts +32 -0
- package/core/common/services/public-api.d.ts +1 -0
- package/data-view-builder/data-view-builder.component.d.ts +35 -0
- package/data-view-builder/data-view-builder.model.d.ts +1 -0
- package/data-view-builder/data-view-builder.module.d.ts +23 -0
- package/data-view-builder/data-view-builder.service.d.ts +14 -0
- package/data-view-builder/menu-data-view/menu-data-view.component.d.ts +36 -0
- package/data-view-builder/package.json +10 -0
- package/{dimx-export/pepperi-addons-ngx-composite-lib-dimx-export.d.ts → data-view-builder/pepperi-addons-ngx-composite-lib-data-view-builder.d.ts} +1 -1
- package/data-view-builder/public-api.d.ts +3 -0
- package/esm2015/color-settings/color-settings.component.js +11 -2
- package/esm2015/core/common/directives/reset-configuration-field.directive.js +26 -22
- package/esm2015/core/common/services/dimx.service.js +50 -0
- package/esm2015/core/common/services/public-api.js +2 -1
- package/esm2015/data-view-builder/data-view-builder.component.js +122 -0
- package/esm2015/data-view-builder/data-view-builder.model.js +2 -0
- package/esm2015/data-view-builder/data-view-builder.module.js +82 -0
- package/esm2015/data-view-builder/data-view-builder.service.js +39 -0
- package/esm2015/data-view-builder/menu-data-view/menu-data-view.component.js +122 -0
- package/esm2015/data-view-builder/pepperi-addons-ngx-composite-lib-data-view-builder.js +5 -0
- package/esm2015/data-view-builder/public-api.js +7 -0
- package/esm2015/file-status-panel/file-status-panel.module.js +12 -4
- package/esm2015/generic-form/generic-form.component.js +86 -55
- package/esm2015/generic-form/generic-form.model.js +1 -1
- package/esm2015/generic-form/index.js +5 -0
- package/esm2015/generic-list/generic-list.component.js +65 -36
- package/esm2015/generic-list/generic-list.model.js +1 -1
- package/esm2015/generic-list/generic-list.module.js +7 -4
- package/esm2015/generic-list/generic-list.service.js +22 -9
- package/esm2015/group-buttons-settings/group-buttons-settings.component.js +2 -2
- package/esm2015/group-buttons-settings/group-buttons-settings.module.js +6 -3
- package/esm2015/ngx-composite-lib.module.js +19 -8
- package/fesm2015/pepperi-addons-ngx-composite-lib-color-settings.js +10 -1
- package/fesm2015/pepperi-addons-ngx-composite-lib-color-settings.js.map +1 -1
- package/fesm2015/pepperi-addons-ngx-composite-lib-data-view-builder.js +360 -0
- package/fesm2015/pepperi-addons-ngx-composite-lib-data-view-builder.js.map +1 -0
- package/fesm2015/pepperi-addons-ngx-composite-lib-file-status-panel.js +12 -5
- package/fesm2015/pepperi-addons-ngx-composite-lib-file-status-panel.js.map +1 -1
- package/fesm2015/pepperi-addons-ngx-composite-lib-generic-form.js +85 -55
- package/fesm2015/pepperi-addons-ngx-composite-lib-generic-form.js.map +1 -1
- package/fesm2015/pepperi-addons-ngx-composite-lib-generic-list.js +87 -43
- package/fesm2015/pepperi-addons-ngx-composite-lib-generic-list.js.map +1 -1
- package/fesm2015/pepperi-addons-ngx-composite-lib-group-buttons-settings.js +6 -3
- package/fesm2015/pepperi-addons-ngx-composite-lib-group-buttons-settings.js.map +1 -1
- package/fesm2015/pepperi-addons-ngx-composite-lib.js +117 -54
- package/fesm2015/pepperi-addons-ngx-composite-lib.js.map +1 -1
- package/file-status-panel/file-status-panel.module.d.ts +3 -0
- package/generic-form/generic-form.component.d.ts +12 -12
- package/generic-form/generic-form.model.d.ts +12 -13
- package/{dimx-export → generic-form}/index.d.ts +0 -0
- package/generic-list/generic-list.component.d.ts +11 -9
- package/generic-list/generic-list.model.d.ts +7 -6
- package/generic-list/generic-list.service.d.ts +2 -1
- package/group-buttons-settings/group-buttons-settings.module.d.ts +2 -1
- package/ngx-composite-lib.module.d.ts +4 -2
- package/package.json +2 -2
- package/src/assets/i18n/en.ngx-composite-lib.json +24 -1
- package/src/core/style/components/data-view-builder.scss +65 -0
- package/styling.scss +5 -1
- package/bundles/pepperi-addons-ngx-composite-lib-dimx-export.umd.js +0 -890
- package/bundles/pepperi-addons-ngx-composite-lib-dimx-export.umd.js.map +0 -1
- package/dimx-export/dimx.component.d.ts +0 -86
- package/dimx-export/dimx.model.d.ts +0 -5
- package/dimx-export/dimx.module.d.ts +0 -16
- package/dimx-export/dimx.service.d.ts +0 -21
- package/dimx-export/package.json +0 -16
- package/dimx-export/public-api.d.ts +0 -3
- package/esm2015/dimx-export/dimx.component.js +0 -335
- package/esm2015/dimx-export/dimx.model.js +0 -8
- package/esm2015/dimx-export/dimx.module.js +0 -53
- package/esm2015/dimx-export/dimx.service.js +0 -50
- package/esm2015/dimx-export/index.js +0 -5
- package/esm2015/dimx-export/pepperi-addons-ngx-composite-lib-dimx-export.js +0 -5
- package/esm2015/dimx-export/public-api.js +0 -7
- package/fesm2015/pepperi-addons-ngx-composite-lib-dimx-export.js +0 -446
- package/fesm2015/pepperi-addons-ngx-composite-lib-dimx-export.js.map +0 -1
|
@@ -43,6 +43,8 @@
|
|
|
43
43
|
function ColorSettingsComponent(pepColorService) {
|
|
44
44
|
this.pepColorService = pepColorService;
|
|
45
45
|
this.title = '';
|
|
46
|
+
this.checkAAComplient = true;
|
|
47
|
+
this.showAAComplient = true;
|
|
46
48
|
this._color = new PepColorSettings();
|
|
47
49
|
this.colorChange = new i0.EventEmitter();
|
|
48
50
|
}
|
|
@@ -96,6 +98,9 @@
|
|
|
96
98
|
this.color.value = value;
|
|
97
99
|
this.raiseColorChange();
|
|
98
100
|
};
|
|
101
|
+
ColorSettingsComponent.prototype.onSliderInputChanged = function (value) {
|
|
102
|
+
this.color.opacity = value;
|
|
103
|
+
};
|
|
99
104
|
ColorSettingsComponent.prototype.onSliderValueChanged = function (value) {
|
|
100
105
|
this.color.opacity = value;
|
|
101
106
|
this.raiseColorChange();
|
|
@@ -103,7 +108,7 @@
|
|
|
103
108
|
return ColorSettingsComponent;
|
|
104
109
|
}());
|
|
105
110
|
ColorSettingsComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0__namespace, type: ColorSettingsComponent, deps: [{ token: i1__namespace.PepColorService }], target: i0__namespace.ɵɵFactoryTarget.Component });
|
|
106
|
-
ColorSettingsComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.0.5", type: ColorSettingsComponent, selector: "pep-color-settings", inputs: { title: "title", color: "color" }, outputs: { colorChange: "colorChange" }, ngImport: i0__namespace, template: "<pep-checkbox class=\"checkbox-as-title\" [label]=\"title\" [renderTitle]=\"false\" [value]=\"color.use\"
|
|
111
|
+
ColorSettingsComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.0.5", type: ColorSettingsComponent, selector: "pep-color-settings", inputs: { title: "title", checkAAComplient: "checkAAComplient", showAAComplient: "showAAComplient", color: "color" }, outputs: { colorChange: "colorChange" }, ngImport: i0__namespace, template: "<pep-checkbox class=\"checkbox-as-title\" [label]=\"title\" [renderTitle]=\"false\" [value]=\"color.use\"\n (valueChange)=\"onUseChanged($event)\"></pep-checkbox>\n<pep-color [value]=\"color.value\" [label]=\"title + ' ' + ('COLOR_SETTINGS.COLOR' | translate)\" [disabled]=\"!color.use\"\n [checkAAComplient]=\"checkAAComplient\" [showAAComplient]=\"showAAComplient\" (valueChange)=\"onColorChanged($event)\">\n</pep-color>\n<pep-slider [label]=\"title + ' ' + ('COLOR_SETTINGS.OPACITY' | translate)\" [hint]=\"color.opacity.toString() || ''\"\n [minValue]=\"0\" [maxValue]=\"100\" [disabled]=\"!color.use\" [value]=\"color.opacity\" [background]=\"getSliderBackground()\"\n (inputChange)=\"onSliderInputChanged($event)\" (valueChange)=\"onSliderValueChanged($event)\">\n</pep-slider>", styles: [":host{width:100%}\n"], components: [{ type: i2__namespace.PepCheckboxComponent, selector: "pep-checkbox", inputs: ["key", "value", "label", "mandatory", "disabled", "readonly", "xAlignment", "rowSpan", "form", "isActive", "showTitle", "renderTitle", "layoutType", "type", "additionalValue", "visible"], outputs: ["valueChange"] }, { type: i3__namespace.PepColorComponent, selector: "pep-color", inputs: ["key", "value", "label", "disabled", "xAlignment", "rowSpan", "type", "showTitle", "renderTitle", "showAAComplient", "checkAAComplient", "layoutType"], outputs: ["valueChange"] }, { type: i4__namespace.PepSliderComponent, selector: "pep-slider", inputs: ["label", "disabled", "hint", "step", "minValue", "maxValue", "background", "value"], outputs: ["valueChange", "inputChange"] }], pipes: { "translate": i5__namespace.TranslatePipe } });
|
|
107
112
|
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0__namespace, type: ColorSettingsComponent, decorators: [{
|
|
108
113
|
type: i0.Component,
|
|
109
114
|
args: [{
|
|
@@ -113,6 +118,10 @@
|
|
|
113
118
|
}]
|
|
114
119
|
}], ctorParameters: function () { return [{ type: i1__namespace.PepColorService }]; }, propDecorators: { title: [{
|
|
115
120
|
type: i0.Input
|
|
121
|
+
}], checkAAComplient: [{
|
|
122
|
+
type: i0.Input
|
|
123
|
+
}], showAAComplient: [{
|
|
124
|
+
type: i0.Input
|
|
116
125
|
}], color: [{
|
|
117
126
|
type: i0.Input
|
|
118
127
|
}], colorChange: [{
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pepperi-addons-ngx-composite-lib-color-settings.umd.js","sources":["../../../projects/ngx-composite-lib/color-settings/color-settings.model.ts","../../../projects/ngx-composite-lib/color-settings/color-settings.component.ts","../../../projects/ngx-composite-lib/color-settings/color-settings.component.html","../../../projects/ngx-composite-lib/color-settings/color-settings.module.ts","../../../projects/ngx-composite-lib/color-settings/public-api.ts","../../../projects/ngx-composite-lib/color-settings/pepperi-addons-ngx-composite-lib-color-settings.ts"],"sourcesContent":["export class PepColorSettings {\r\n use = false;\r\n value = 'hsl(0, 0%, 57%)';\r\n opacity = 50;\r\n // useGradientOverlay?: boolean = true;\r\n}","import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core';\nimport { PepColorService } from '@pepperi-addons/ngx-lib';\nimport { PepColorSettings } from './color-settings.model';\n\n@Component({\n selector: 'pep-color-settings',\n templateUrl: './color-settings.component.html',\n styleUrls: ['./color-settings.component.scss']\n})\nexport class ColorSettingsComponent implements OnInit {\n
|
|
1
|
+
{"version":3,"file":"pepperi-addons-ngx-composite-lib-color-settings.umd.js","sources":["../../../projects/ngx-composite-lib/color-settings/color-settings.model.ts","../../../projects/ngx-composite-lib/color-settings/color-settings.component.ts","../../../projects/ngx-composite-lib/color-settings/color-settings.component.html","../../../projects/ngx-composite-lib/color-settings/color-settings.module.ts","../../../projects/ngx-composite-lib/color-settings/public-api.ts","../../../projects/ngx-composite-lib/color-settings/pepperi-addons-ngx-composite-lib-color-settings.ts"],"sourcesContent":["export class PepColorSettings {\r\n use = false;\r\n value = 'hsl(0, 0%, 57%)';\r\n opacity = 50;\r\n // useGradientOverlay?: boolean = true;\r\n}","import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core';\nimport { PepColorService } from '@pepperi-addons/ngx-lib';\nimport { PepColorSettings } from './color-settings.model';\n\n@Component({\n selector: 'pep-color-settings',\n templateUrl: './color-settings.component.html',\n styleUrls: ['./color-settings.component.scss']\n})\nexport class ColorSettingsComponent implements OnInit {\n @Input() title = '';\n @Input() checkAAComplient = true;\n @Input() showAAComplient = true;\n\n private _color: PepColorSettings = new PepColorSettings();\n @Input()\n set color(value: PepColorSettings) {\n if (!value) {\n this._color = new PepColorSettings();\n } else {\n this._color = value;\n }\n }\n get color(): PepColorSettings {\n return this._color;\n }\n\n @Output()\n colorChange: EventEmitter<PepColorSettings> = new EventEmitter<PepColorSettings>();\n \n constructor(private pepColorService: PepColorService) { }\n\n ngOnInit() {\n //\n }\n\n private getRGBAcolor(colorObj: PepColorSettings, opac: number | null = null) {\n let rgba = 'rgba(255,255,255,0)';\n\n if (colorObj) {\n const color = colorObj.value;\n let opacity = opac != null ? opac : colorObj.opacity;\n\n opacity = opacity > 0 ? opacity / 100 : 0;\n\n const hsl = this.pepColorService.hslString2hsl(color);\n const rgb = this.pepColorService.hsl2rgb(hsl);\n rgba = 'rgba(' + rgb.r + ',' + rgb.g + ',' + rgb.b + ',' + opacity + ')';\n }\n\n return rgba;\n }\n\n private raiseColorChange() {\n this.colorChange.emit(this.color);\n }\n\n getSliderBackground() {\n const alignTo = 'right';\n \n const colorObj = new PepColorSettings();\n \n colorObj.value = this.color.value;\n colorObj.opacity = 100;\n \n const gradStr = this.getRGBAcolor(colorObj, 0) + ' , ' + this.getRGBAcolor(colorObj);\n \n return 'linear-gradient(to ' + alignTo + ', ' + gradStr + ')';\n }\n\n onUseChanged(value: boolean) {\n this.color.use = value;\n this.raiseColorChange();\n }\n\n onColorChanged(value: string) {\n this.color.value = value;\n this.raiseColorChange();\n }\n \n onSliderInputChanged(value: number) {\n this.color.opacity = value;\n }\n\n onSliderValueChanged(value: number) {\n this.color.opacity = value;\n this.raiseColorChange();\n }\n}\n","<pep-checkbox class=\"checkbox-as-title\" [label]=\"title\" [renderTitle]=\"false\" [value]=\"color.use\"\n (valueChange)=\"onUseChanged($event)\"></pep-checkbox>\n<pep-color [value]=\"color.value\" [label]=\"title + ' ' + ('COLOR_SETTINGS.COLOR' | translate)\" [disabled]=\"!color.use\"\n [checkAAComplient]=\"checkAAComplient\" [showAAComplient]=\"showAAComplient\" (valueChange)=\"onColorChanged($event)\">\n</pep-color>\n<pep-slider [label]=\"title + ' ' + ('COLOR_SETTINGS.OPACITY' | translate)\" [hint]=\"color.opacity.toString() || ''\"\n [minValue]=\"0\" [maxValue]=\"100\" [disabled]=\"!color.use\" [value]=\"color.opacity\" [background]=\"getSliderBackground()\"\n (inputChange)=\"onSliderInputChanged($event)\" (valueChange)=\"onSliderValueChanged($event)\">\n</pep-slider>","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { PepNgxLibModule } from '@pepperi-addons/ngx-lib';\nimport { PepColorModule } from '@pepperi-addons/ngx-lib/color';\nimport { PepCheckboxModule } from '@pepperi-addons/ngx-lib/checkbox';\nimport { PepSliderModule } from '@pepperi-addons/ngx-lib/slider';\n\nimport { ColorSettingsComponent } from './color-settings.component';\n\n@NgModule({\n declarations: [\n ColorSettingsComponent\n ],\n imports: [\n CommonModule,\n PepNgxLibModule,\n PepCheckboxModule,\n PepColorModule,\n PepSliderModule\n ],\n exports: [ColorSettingsComponent],\n})\nexport class PepColorSettingsModule { }\n","/*\n * Public API Surface of ngx-composite-lib/color-settings\n */\nexport * from './color-settings.module';\nexport * from './color-settings.component';\nexport * from './color-settings.model';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":["EventEmitter","Component","Input","Output","CommonModule","PepNgxLibModule","PepCheckboxModule","PepColorModule","PepSliderModule","NgModule"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;QAAA;Y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ALlCC,YAAS;uBAAC;wBACP,QAAQ,EAAE,oBAAoB;wBAC9B,WAAW,EAAE,iCAAiC;wBAC9C,SAAS,EAAE,CAAC,iCAAiC,CAAC;qBACjD;qHAEY,KAAK;0BAAbC,QAAK;oBACG,gBAAgB;0BAAxBA,QAAK;oBACG,eAAe;0BAAvBA,QAAK;oBAIF,KAAK;0BADRA,QAAK;oBAaN,WAAW;0BADVC,SAAM;;;;QELX;;;;6IAAa,sBAAsB;8IAAtB,sBAAsB,iBAX3B,sBAAsB,aAGtBC,mBAAY;YACZC,kBAAe;YACfC,oBAAiB;YACjBC,iBAAc;YACdC,kBAAe,aAET,sBAAsB;8IAEvB,sBAAsB,YATtB;gBACLJ,mBAAY;gBACZC,kBAAe;gBACfC,oBAAiB;gBACjBC,iBAAc;gBACdC,kBAAe;aAClB;qHAGQ,sBAAsB;sBAblCC,WAAQ;uBAAC;wBACN,YAAY,EAAE;4BACV,sBAAsB;yBACzB;wBACD,OAAO,EAAE;4BACLL,mBAAY;4BACZC,kBAAe;4BACfC,oBAAiB;4BACjBC,iBAAc;4BACdC,kBAAe;yBAClB;wBACD,OAAO,EAAE,CAAC,sBAAsB,CAAC;qBACpC;;;ICrBD;;;;ICAA;;;;;;;;;;;;;;"}
|
|
@@ -0,0 +1,393 @@
|
|
|
1
|
+
(function (global, factory) {
|
|
2
|
+
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@angular/core'), require('@angular/common'), require('@angular/cdk/drag-drop'), require('@angular/material/icon'), require('@pepperi-addons/ngx-lib'), require('@pepperi-addons/ngx-lib/button'), require('@pepperi-addons/ngx-lib/dialog'), require('@pepperi-addons/ngx-lib/menu'), require('@pepperi-addons/ngx-lib/page-layout'), require('@pepperi-addons/ngx-lib/textbox'), require('@pepperi-addons/ngx-lib/top-bar'), require('@pepperi-addons/ngx-lib/draggable-items'), require('@pepperi-addons/ngx-lib/icon'), require('rxjs'), require('rxjs/operators'), require('@ngx-translate/core')) :
|
|
3
|
+
typeof define === 'function' && define.amd ? define('@pepperi-addons/ngx-composite-lib/data-view-builder', ['exports', '@angular/core', '@angular/common', '@angular/cdk/drag-drop', '@angular/material/icon', '@pepperi-addons/ngx-lib', '@pepperi-addons/ngx-lib/button', '@pepperi-addons/ngx-lib/dialog', '@pepperi-addons/ngx-lib/menu', '@pepperi-addons/ngx-lib/page-layout', '@pepperi-addons/ngx-lib/textbox', '@pepperi-addons/ngx-lib/top-bar', '@pepperi-addons/ngx-lib/draggable-items', '@pepperi-addons/ngx-lib/icon', 'rxjs', 'rxjs/operators', '@ngx-translate/core'], factory) :
|
|
4
|
+
(global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory((global["pepperi-addons"] = global["pepperi-addons"] || {}, global["pepperi-addons"]["ngx-composite-lib"] = global["pepperi-addons"]["ngx-composite-lib"] || {}, global["pepperi-addons"]["ngx-composite-lib"]["data-view-builder"] = {}), global.ng.core, global.ng.common, global.ng.cdk.dragDrop, global.ng.material.icon, global["ngx-lib"], global["ngx-lib/button"], global["ngx-lib/dialog"], global["ngx-lib/menu"], global["ngx-lib/page-layout"], global["ngx-lib/textbox"], global["ngx-lib/top-bar"], global["ngx-lib/draggable-items"], global["ngx-lib/icon"], global.rxjs, global.rxjs.operators, global.translate));
|
|
5
|
+
})(this, (function (exports, i0, i7, i8, i3, ngxLib, i5, i1, menu, i2, i6, topBar, i3$1, i1$1, rxjs, operators, i9) { 'use strict';
|
|
6
|
+
|
|
7
|
+
function _interopNamespace(e) {
|
|
8
|
+
if (e && e.__esModule) return e;
|
|
9
|
+
var n = Object.create(null);
|
|
10
|
+
if (e) {
|
|
11
|
+
Object.keys(e).forEach(function (k) {
|
|
12
|
+
if (k !== 'default') {
|
|
13
|
+
var d = Object.getOwnPropertyDescriptor(e, k);
|
|
14
|
+
Object.defineProperty(n, k, d.get ? d : {
|
|
15
|
+
enumerable: true,
|
|
16
|
+
get: function () { return e[k]; }
|
|
17
|
+
});
|
|
18
|
+
}
|
|
19
|
+
});
|
|
20
|
+
}
|
|
21
|
+
n["default"] = e;
|
|
22
|
+
return Object.freeze(n);
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
var i0__namespace = /*#__PURE__*/_interopNamespace(i0);
|
|
26
|
+
var i7__namespace = /*#__PURE__*/_interopNamespace(i7);
|
|
27
|
+
var i8__namespace = /*#__PURE__*/_interopNamespace(i8);
|
|
28
|
+
var i3__namespace = /*#__PURE__*/_interopNamespace(i3);
|
|
29
|
+
var i5__namespace = /*#__PURE__*/_interopNamespace(i5);
|
|
30
|
+
var i1__namespace = /*#__PURE__*/_interopNamespace(i1);
|
|
31
|
+
var i2__namespace = /*#__PURE__*/_interopNamespace(i2);
|
|
32
|
+
var i6__namespace = /*#__PURE__*/_interopNamespace(i6);
|
|
33
|
+
var i3__namespace$1 = /*#__PURE__*/_interopNamespace(i3$1);
|
|
34
|
+
var i1__namespace$1 = /*#__PURE__*/_interopNamespace(i1$1);
|
|
35
|
+
var i9__namespace = /*#__PURE__*/_interopNamespace(i9);
|
|
36
|
+
|
|
37
|
+
var DataViewBuilderService = /** @class */ (function () {
|
|
38
|
+
function DataViewBuilderService() {
|
|
39
|
+
// This subject is for is grabbing mode.
|
|
40
|
+
this._isGrabbingSubject = new rxjs.BehaviorSubject(false);
|
|
41
|
+
//
|
|
42
|
+
}
|
|
43
|
+
Object.defineProperty(DataViewBuilderService.prototype, "isGrabbingChange$", {
|
|
44
|
+
get: function () {
|
|
45
|
+
return this._isGrabbingSubject.asObservable().pipe(operators.distinctUntilChanged());
|
|
46
|
+
},
|
|
47
|
+
enumerable: false,
|
|
48
|
+
configurable: true
|
|
49
|
+
});
|
|
50
|
+
DataViewBuilderService.prototype.changeCursorOnDragStart = function () {
|
|
51
|
+
document.body.classList.add('inheritCursors');
|
|
52
|
+
document.body.style.cursor = 'grabbing';
|
|
53
|
+
this._isGrabbingSubject.next(true);
|
|
54
|
+
};
|
|
55
|
+
DataViewBuilderService.prototype.changeCursorOnDragEnd = function () {
|
|
56
|
+
document.body.classList.remove('inheritCursors');
|
|
57
|
+
document.body.style.cursor = 'unset';
|
|
58
|
+
this._isGrabbingSubject.next(false);
|
|
59
|
+
};
|
|
60
|
+
DataViewBuilderService.prototype.onDragStart = function (event) {
|
|
61
|
+
this.changeCursorOnDragStart();
|
|
62
|
+
};
|
|
63
|
+
DataViewBuilderService.prototype.onDragEnd = function (event) {
|
|
64
|
+
this.changeCursorOnDragEnd();
|
|
65
|
+
};
|
|
66
|
+
return DataViewBuilderService;
|
|
67
|
+
}());
|
|
68
|
+
DataViewBuilderService.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0__namespace, type: DataViewBuilderService, deps: [], target: i0__namespace.ɵɵFactoryTarget.Injectable });
|
|
69
|
+
DataViewBuilderService.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0__namespace, type: DataViewBuilderService, providedIn: 'root' });
|
|
70
|
+
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0__namespace, type: DataViewBuilderService, decorators: [{
|
|
71
|
+
type: i0.Injectable,
|
|
72
|
+
args: [{
|
|
73
|
+
providedIn: 'root'
|
|
74
|
+
}]
|
|
75
|
+
}], ctorParameters: function () { return []; } });
|
|
76
|
+
|
|
77
|
+
var MenuDataViewComponent = /** @class */ (function () {
|
|
78
|
+
function MenuDataViewComponent(dialogService, dataViewBuilderService) {
|
|
79
|
+
var _this = this;
|
|
80
|
+
this.dialogService = dialogService;
|
|
81
|
+
this.dataViewBuilderService = dataViewBuilderService;
|
|
82
|
+
this.fields = []; // The data view fields.
|
|
83
|
+
this.availableFieldsTitles = new Map(); // <FieldID, Original Title> from the available fields.
|
|
84
|
+
this.emptyDropAreaId = '';
|
|
85
|
+
this.mappedFieldsId = '';
|
|
86
|
+
this.fieldsChange = new i0.EventEmitter();
|
|
87
|
+
this.isGrabbing = false;
|
|
88
|
+
this.dialogRef = null;
|
|
89
|
+
this.dataViewBuilderService.isGrabbingChange$.subscribe(function (value) {
|
|
90
|
+
_this.isGrabbing = value;
|
|
91
|
+
});
|
|
92
|
+
}
|
|
93
|
+
MenuDataViewComponent.prototype.addNewField = function (draggableItem, index) {
|
|
94
|
+
// Add new menuField to the mappedFields.
|
|
95
|
+
var menuField = { FieldID: draggableItem.data.key, Title: draggableItem.title };
|
|
96
|
+
this.spliceMappedFields(index, 0, menuField);
|
|
97
|
+
};
|
|
98
|
+
MenuDataViewComponent.prototype.spliceMappedFields = function (start, deleteCount, item) {
|
|
99
|
+
if (item) {
|
|
100
|
+
this.fields.splice(start, deleteCount, item);
|
|
101
|
+
}
|
|
102
|
+
else {
|
|
103
|
+
this.fields.splice(start, deleteCount);
|
|
104
|
+
}
|
|
105
|
+
this.notifyFieldsChange();
|
|
106
|
+
};
|
|
107
|
+
MenuDataViewComponent.prototype.changeTitle = function (menuField, title) {
|
|
108
|
+
menuField.Title = title;
|
|
109
|
+
this.notifyFieldsChange();
|
|
110
|
+
};
|
|
111
|
+
MenuDataViewComponent.prototype.notifyFieldsChange = function () {
|
|
112
|
+
this.fieldsChange.emit(this.fields);
|
|
113
|
+
};
|
|
114
|
+
MenuDataViewComponent.prototype.ngOnInit = function () {
|
|
115
|
+
//
|
|
116
|
+
};
|
|
117
|
+
MenuDataViewComponent.prototype.addSeparator = function (index) {
|
|
118
|
+
var menuField = { FieldID: '', Title: '' };
|
|
119
|
+
this.spliceMappedFields(index, 0, menuField);
|
|
120
|
+
};
|
|
121
|
+
MenuDataViewComponent.prototype.onDragStart = function (event) {
|
|
122
|
+
this.dataViewBuilderService.onDragStart(event);
|
|
123
|
+
};
|
|
124
|
+
MenuDataViewComponent.prototype.onDragEnd = function (event) {
|
|
125
|
+
this.dataViewBuilderService.onDragEnd(event);
|
|
126
|
+
};
|
|
127
|
+
MenuDataViewComponent.prototype.onDropField = function (event) {
|
|
128
|
+
if (event.previousContainer === event.container) {
|
|
129
|
+
i8.moveItemInArray(event.container.data, event.previousIndex, event.currentIndex);
|
|
130
|
+
this.notifyFieldsChange();
|
|
131
|
+
}
|
|
132
|
+
else if (event.container.id === 'emptyDropArea') {
|
|
133
|
+
this.addNewField(event.previousContainer.data[event.previousIndex], this.fields.length);
|
|
134
|
+
}
|
|
135
|
+
else {
|
|
136
|
+
this.addNewField(event.previousContainer.data[event.previousIndex], event.currentIndex);
|
|
137
|
+
}
|
|
138
|
+
};
|
|
139
|
+
MenuDataViewComponent.prototype.onTitleChanged = function (event, menuField) {
|
|
140
|
+
this.changeTitle(menuField, event);
|
|
141
|
+
};
|
|
142
|
+
MenuDataViewComponent.prototype.onDeleteMappedField = function (event, menuField) {
|
|
143
|
+
var index = this.fields.findIndex(function (ms) { return ms === menuField; });
|
|
144
|
+
if (index > -1) {
|
|
145
|
+
this.spliceMappedFields(index, 1);
|
|
146
|
+
}
|
|
147
|
+
};
|
|
148
|
+
MenuDataViewComponent.prototype.onEditSeparatorField = function (event, menuField) {
|
|
149
|
+
var _this = this;
|
|
150
|
+
this.dialogRef = this.dialogService.openDialog(this.separatorTitleModalTemplate, { value: menuField.Title });
|
|
151
|
+
this.dialogRef.afterClosed().subscribe(function (titleValue) {
|
|
152
|
+
if (titleValue !== undefined) {
|
|
153
|
+
_this.changeTitle(menuField, titleValue);
|
|
154
|
+
}
|
|
155
|
+
});
|
|
156
|
+
};
|
|
157
|
+
MenuDataViewComponent.prototype.setDialogValue = function (value) {
|
|
158
|
+
this.closeDialog(value);
|
|
159
|
+
};
|
|
160
|
+
MenuDataViewComponent.prototype.closeDialog = function (value) {
|
|
161
|
+
if (value === void 0) { value = undefined; }
|
|
162
|
+
var _a;
|
|
163
|
+
(_a = this.dialogRef) === null || _a === void 0 ? void 0 : _a.close(value);
|
|
164
|
+
};
|
|
165
|
+
return MenuDataViewComponent;
|
|
166
|
+
}());
|
|
167
|
+
MenuDataViewComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0__namespace, type: MenuDataViewComponent, deps: [{ token: i1__namespace.PepDialogService }, { token: DataViewBuilderService }], target: i0__namespace.ɵɵFactoryTarget.Component });
|
|
168
|
+
MenuDataViewComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.0.5", type: MenuDataViewComponent, selector: "menu-data-view", inputs: { fields: "fields", availableFieldsTitles: "availableFieldsTitles", emptyDropAreaId: "emptyDropAreaId", mappedFieldsId: "mappedFieldsId" }, outputs: { fieldsChange: "fieldsChange" }, viewQueries: [{ propertyName: "separatorTitleModalTemplate", first: true, predicate: ["separatorTitleModalTemplate"], descendants: true, read: i0.TemplateRef }], ngImport: i0__namespace, template: "<ng-container *ngIf=\"fields === null || fields.length === 0; then emptyTemplate; else notEmptyTemplate\"></ng-container>\n<ng-template #emptyTemplate>\n <div [id]=\"emptyDropAreaId\" class=\"drop-field-here-area\" cdkDropList (cdkDropListDropped)=\"onDropField($event)\">\n <mat-icon class=\"pep-spacing-element\">\n <pep-icon name=\"arrow_down_alt\"></pep-icon>\n </mat-icon>\n <span class=\"body-sm ellipsis\">\n {{ 'DATA_VIEW_BUILDER.EMPTY_DROP_AREA_TEXT' | translate }}\n </span> \n </div>\n</ng-template>\n<ng-template #notEmptyTemplate>\n <div [id]=\"mappedFieldsId\" class=\"mapped-fields-area\" [ngClass]=\"{ 'no-row-gap': !isGrabbing }\"\n cdkDropList [cdkDropListData]=\"fields\" (cdkDropListDropped)=\"onDropField($event)\">\n <ng-container *ngFor=\"let menuField of fields; let i = index\" >\n <div class=\"mapped-field-container\" [ngClass]=\"{ 'separator-container': menuField.FieldID === '' }\" \n cdkDrag (cdkDragStarted)=\"onDragStart($event)\" (cdkDragEnded)=\"onDragEnd($event)\">\n <ng-container *ngTemplateOutlet=\"mappedFieldTemplate; context: { menuField: menuField }\"></ng-container>\n </div>\n <div *ngIf=\"!isGrabbing\" class=\"add-separator-container\">\n <pep-button class=\"add-separator\" styleType=\"regular\" sizeType=\"sm\" iconName=\"number_plus\" \n [value]=\"'DATA_VIEW_BUILDER.ADD_SEPARATOR' | translate\" (buttonClick)=\"addSeparator(i+1)\"></pep-button>\n </div>\n </ng-container>\n </div>\n</ng-template>\n\n<ng-template #mappedFieldTemplate let-menuField=\"menuField\">\n <ng-container *ngIf=\"menuField.FieldID !== ''; then menuItemTemplate; else separatorTemplate\"></ng-container>\n\n <ng-template #menuItemTemplate>\n <div class=\"fields-wrapper\">\n <pep-textbox [label]=\"'DATA_VIEW_BUILDER.MENU_ITEM_KEY_TITLE' | translate\" [value]=\"menuField.FieldID\" [disabled]=\"true\">\n </pep-textbox>\n \n <pep-textbox [label]=\"'DATA_VIEW_BUILDER.MENU_ITEM_VALUE_TITLE' | translate\" [hint]=\"'(' + (availableFieldsTitles.get(menuField.FieldID) || '') + ')'\"\n [value]=\"menuField.Title\" (valueChange)=\"onTitleChanged($event, menuField)\">\n </pep-textbox>\n \n <pep-button class=\"center-button\" iconName=\"system_bin\" [title]=\"'ACTIONS.DELETE' | translate\" (buttonClick)=\"onDeleteMappedField($event, menuField)\"></pep-button>\n </div>\n </ng-template>\n <ng-template #separatorTemplate>\n <div class=\"separator-wrapper \">\n <div class=\"pep-spacing-element title title-md color-dimmed\">\n <span [title]=\"menuField.Title\">{{ menuField.Title }}</span>\n </div>\n <div class=\"list-actions\">\n <pep-button iconName=\"system_edit\" [title]=\"'ACTIONS.EDIT' | translate\" sizeType=\"xs\" styleType=\"regular\" (buttonClick)=\"onEditSeparatorField($event, menuField)\"></pep-button>\n <pep-button iconName=\"system_bin\" [title]=\"'ACTIONS.DELETE' | translate\" sizeType=\"xs\" styleType=\"regular\" (buttonClick)=\"onDeleteMappedField($event, menuField)\"></pep-button>\n </div>\n </div>\n </ng-template>\n</ng-template>\n\n<ng-template #separatorTitleModalTemplate let-data>\n <pep-dialog [title]=\"'DATA_VIEW_BUILDER.SEPARATOR_TITLE' | translate\">\n <ng-container pep-dialog-content>\n <pep-textbox #txt [label]=\"'DATA_VIEW_BUILDER.ADD_A_TITLE' | translate\" [(value)]=\"data.value\">\n </pep-textbox>\n </ng-container>\n <ng-container pep-dialog-actions>\n <div class=\"pep-spacing-element-negative\">\n <button mat-button class=\"pep-spacing-element pep-button md weak\"\n (click)=\"closeDialog()\">\n {{'Cancel' | translate}}\n </button>\n <button mat-button class=\"pep-spacing-element pep-button md strong\"\n (click)=\"setDialogValue(txt.value)\">\n {{ 'Save' | translate}}\n </button>\n </div>\n </ng-container>\n </pep-dialog>\n</ng-template>", styles: ["html body.inheritCursors *{cursor:inherit!important}.cdk-drag-preview.mapped-field-container{max-width:600px;display:flex;justify-content:center;align-items:center;border-radius:var(--pep-border-radius-md, .25rem)}.cdk-drag-preview.mapped-field-container:not(.separator-container){padding-inline:var(--pep-spacing-lg, 1rem)}.cdk-drag-preview.mapped-field-container:not(.separator-container){grid-gap:calc(var(--pep-spacing-lg, 1rem) * 2);gap:calc(var(--pep-spacing-lg, 1rem) * 2);background:hsl(var(--pep-color-regular-h, 0),var(--pep-color-regular-s, 0%),98%);box-shadow:var(--pep-shadow-xs-offset, 0 .125rem .25rem 0) hsla(var(--pep-color-system-primary-h, 0),var(--pep-color-system-primary-s, 0%),var(--pep-color-system-primary-l, 10%),.08);border:1px solid hsl(var(--pep-color-regular-h, 0),var(--pep-color-regular-s, 0%),calc(var(--pep-color-regular-l, 10%) + 30%))}.cdk-drag-preview.mapped-field-container .fields-wrapper{display:grid;width:100%;grid-template-columns:1fr 1fr auto;grid-gap:.5rem;gap:.5rem;padding-top:.5rem}.cdk-drag-preview.mapped-field-container .fields-wrapper .center-button{margin-top:var(--pep-form-field-title-height, 1.5rem)}.cdk-drag-preview.mapped-field-container .separator-wrapper{display:grid;width:100%;grid-template-columns:1fr auto;padding-bottom:var(--pep-spacing-xs, .25rem);border-bottom:1px solid hsl(var(--pep-color-regular-h, 0),var(--pep-color-regular-s, 0%),calc(var(--pep-color-regular-l, 10%) + 30%))}.cdk-drag-preview.mapped-field-container .separator-wrapper .list-actions{display:flex;grid-gap:var(--pep-spacing-xs, .25rem);gap:var(--pep-spacing-xs, .25rem)}.drop-field-here-area{min-height:5rem;max-width:600px;display:flex;justify-content:center;align-items:center;border-radius:var(--pep-border-radius-md, .25rem);background:hsla(var(--pep-color-weak-h, 0),var(--pep-color-weak-s, 0%),var(--pep-color-weak-l, 10%),.12);position:relative}.drop-field-here-area:not(.separator-container){padding-inline:var(--pep-spacing-lg, 1rem)}.drop-field-here-area:after{z-index:0;content:\"\";transition:all .25s;display:block;position:absolute;top:0;bottom:0;left:0;right:0;border-radius:inherit;border:1px dashed hsl(var(--pep-color-system-primary-h, 0),var(--pep-color-system-primary-s, 0%),calc(var(--pep-color-system-primary-l, 10%) + 30%))}.drop-field-here-area.cdk-drop-list-dragging{box-shadow:0 0 0 var(--pep-spacing-xs, .25rem) hsla(var(--pep-color-text-link-h, 207),var(--pep-color-text-link-s, 76%),var(--pep-color-text-link-l, 37%),.5)}.drop-field-here-area.cdk-drop-list-dragging:hover{background:hsl(var(--pep-color-regular-h, 0),var(--pep-color-regular-s, 0%),98%);box-shadow:var(--pep-shadow-xs-offset, 0 .125rem .25rem 0) hsla(var(--pep-color-system-primary-h, 0),var(--pep-color-system-primary-s, 0%),var(--pep-color-system-primary-l, 10%),.16);border:1px solid hsl(var(--pep-color-regular-h, 0),var(--pep-color-regular-s, 0%),calc(var(--pep-color-regular-l, 10%) + 20%));box-shadow:0 0 0 var(--pep-spacing-xs, .25rem) hsla(var(--pep-color-text-link-h, 207),var(--pep-color-text-link-s, 76%),var(--pep-color-text-link-l, 37%),.5)}.drop-field-here-area.cdk-drop-list-dragging ::ng-deep .placeholder-item{display:none}.mapped-fields-area{display:flex;flex-direction:column;grid-column-gap:var(--pep-spacing-lg, 1rem);column-gap:var(--pep-spacing-lg, 1rem)}.mapped-fields-area:not(.no-row-gap){grid-row-gap:var(--pep-spacing-lg, 1rem);row-gap:var(--pep-spacing-lg, 1rem)}.mapped-fields-area.cdk-drop-list-dragging ::ng-deep .placeholder-item{max-width:600px;display:flex;justify-content:center;align-items:center;border-radius:var(--pep-border-radius-md, .25rem);background:hsl(var(--pep-color-regular-h, 0),var(--pep-color-regular-s, 0%),98%);box-shadow:var(--pep-shadow-xs-offset, 0 .125rem .25rem 0) hsla(var(--pep-color-system-primary-h, 0),var(--pep-color-system-primary-s, 0%),var(--pep-color-system-primary-l, 10%),.08);border:1px solid hsl(var(--pep-color-regular-h, 0),var(--pep-color-regular-s, 0%),calc(var(--pep-color-regular-l, 10%) + 30%));box-shadow:0 0 0 var(--pep-spacing-xs, .25rem) hsla(var(--pep-color-text-link-h, 207),var(--pep-color-text-link-s, 76%),var(--pep-color-text-link-l, 37%),.5);height:2.5rem}.mapped-fields-area.cdk-drop-list-dragging ::ng-deep .placeholder-item:not(.separator-container){padding-inline:var(--pep-spacing-lg, 1rem)}.mapped-fields-area .mapped-field-container{cursor:grab;max-width:600px;display:flex;justify-content:center;align-items:center;border-radius:var(--pep-border-radius-md, .25rem)}.mapped-fields-area .mapped-field-container:not(.separator-container){padding-inline:var(--pep-spacing-lg, 1rem)}.mapped-fields-area .mapped-field-container:not(.separator-container){grid-gap:calc(var(--pep-spacing-lg, 1rem) * 2);gap:calc(var(--pep-spacing-lg, 1rem) * 2);background:hsl(var(--pep-color-regular-h, 0),var(--pep-color-regular-s, 0%),98%);box-shadow:var(--pep-shadow-xs-offset, 0 .125rem .25rem 0) hsla(var(--pep-color-system-primary-h, 0),var(--pep-color-system-primary-s, 0%),var(--pep-color-system-primary-l, 10%),.08);border:1px solid hsl(var(--pep-color-regular-h, 0),var(--pep-color-regular-s, 0%),calc(var(--pep-color-regular-l, 10%) + 30%))}.mapped-fields-area .mapped-field-container .fields-wrapper{display:grid;width:100%;grid-template-columns:1fr 1fr auto;grid-gap:.5rem;gap:.5rem;padding-top:.5rem}.mapped-fields-area .mapped-field-container .fields-wrapper .center-button{margin-top:var(--pep-form-field-title-height, 1.5rem)}.mapped-fields-area .mapped-field-container .separator-wrapper{display:grid;width:100%;grid-template-columns:1fr auto;padding-bottom:var(--pep-spacing-xs, .25rem);border-bottom:1px solid hsl(var(--pep-color-regular-h, 0),var(--pep-color-regular-s, 0%),calc(var(--pep-color-regular-l, 10%) + 30%))}.mapped-fields-area .mapped-field-container .separator-wrapper .list-actions{display:flex;grid-gap:var(--pep-spacing-xs, .25rem);gap:var(--pep-spacing-xs, .25rem)}.mapped-fields-area .mapped-field-container.cdk-drag-placeholder{box-shadow:0 0 0 var(--pep-spacing-xs, .25rem) hsla(var(--pep-color-text-link-h, 207),var(--pep-color-text-link-s, 76%),var(--pep-color-text-link-l, 37%),.5)}.mapped-fields-area .mapped-field-container.cdk-drag-placeholder .fields-wrapper,.mapped-fields-area .mapped-field-container.cdk-drag-placeholder .separator-wrapper{opacity:0}.mapped-fields-area .add-separator-container{max-width:600px;display:flex;justify-content:center;align-items:center;border-radius:var(--pep-border-radius-md, .25rem);height:var(--pep-spacing-lg, 1rem)}.mapped-fields-area .add-separator-container:not(.separator-container){padding-inline:var(--pep-spacing-lg, 1rem)}.mapped-fields-area .add-separator-container .add-separator{position:relative;display:none}.mapped-fields-area .add-separator-container:hover .add-separator{display:block}\n"], components: [{ type: i3__namespace.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { type: i1__namespace$1.PepIconComponent, selector: "pep-icon", inputs: ["spin", "name", "fill"] }, { type: i5__namespace.PepButtonComponent, selector: "pep-button", inputs: ["styleType", "styleStateType", "sizeType", "classNames", "disabled", "iconPosition", "visible", "key", "value", "iconName"], outputs: ["buttonClick"] }, { type: i6__namespace.PepTextboxComponent, selector: "pep-textbox", inputs: ["accessory", "label", "placeholder", "mandatory", "disabled", "readonly", "textColor", "xAlignment", "rowSpan", "minValue", "maxValue", "form", "isActive", "showTitle", "renderTitle", "renderError", "renderSymbol", "layoutType", "parentFieldKey", "key", "value", "formattedValue", "type", "visible", "maxFieldCharacters", "hint"], outputs: ["valueChange", "formValidationChange"] }, { type: i1__namespace.PepDialogComponent, selector: "pep-dialog", inputs: ["showClose", "showHeader", "showFooter", "title"], outputs: ["close"] }], directives: [{ type: i7__namespace.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i8__namespace.CdkDropList, selector: "[cdkDropList], cdk-drop-list", inputs: ["cdkDropListConnectedTo", "id", "cdkDropListEnterPredicate", "cdkDropListSortPredicate", "cdkDropListDisabled", "cdkDropListSortingDisabled", "cdkDropListAutoScrollDisabled", "cdkDropListOrientation", "cdkDropListLockAxis", "cdkDropListData", "cdkDropListAutoScrollStep"], outputs: ["cdkDropListDropped", "cdkDropListEntered", "cdkDropListExited", "cdkDropListSorted"], exportAs: ["cdkDropList"] }, { type: i7__namespace.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { type: i7__namespace.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i8__namespace.CdkDrag, selector: "[cdkDrag]", inputs: ["cdkDragDisabled", "cdkDragStartDelay", "cdkDragLockAxis", "cdkDragConstrainPosition", "cdkDragPreviewClass", "cdkDragBoundary", "cdkDragRootElement", "cdkDragPreviewContainer", "cdkDragData", "cdkDragFreeDragPosition"], outputs: ["cdkDragStarted", "cdkDragReleased", "cdkDragEnded", "cdkDragEntered", "cdkDragExited", "cdkDragDropped", "cdkDragMoved"], exportAs: ["cdkDrag"] }, { type: i7__namespace.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet"] }], pipes: { "translate": i9__namespace.TranslatePipe } });
|
|
169
|
+
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0__namespace, type: MenuDataViewComponent, decorators: [{
|
|
170
|
+
type: i0.Component,
|
|
171
|
+
args: [{
|
|
172
|
+
selector: 'menu-data-view',
|
|
173
|
+
templateUrl: './menu-data-view.component.html',
|
|
174
|
+
styleUrls: ['./menu-data-view.component.scss']
|
|
175
|
+
}]
|
|
176
|
+
}], ctorParameters: function () { return [{ type: i1__namespace.PepDialogService }, { type: DataViewBuilderService }]; }, propDecorators: { separatorTitleModalTemplate: [{
|
|
177
|
+
type: i0.ViewChild,
|
|
178
|
+
args: ['separatorTitleModalTemplate', { read: i0.TemplateRef }]
|
|
179
|
+
}], fields: [{
|
|
180
|
+
type: i0.Input
|
|
181
|
+
}], availableFieldsTitles: [{
|
|
182
|
+
type: i0.Input
|
|
183
|
+
}], emptyDropAreaId: [{
|
|
184
|
+
type: i0.Input
|
|
185
|
+
}], mappedFieldsId: [{
|
|
186
|
+
type: i0.Input
|
|
187
|
+
}], fieldsChange: [{
|
|
188
|
+
type: i0.Output
|
|
189
|
+
}] } });
|
|
190
|
+
|
|
191
|
+
var DataViewBuilderComponent = /** @class */ (function () {
|
|
192
|
+
function DataViewBuilderComponent(dataViewBuilderService) {
|
|
193
|
+
this.dataViewBuilderService = dataViewBuilderService;
|
|
194
|
+
// @Input() title: string = '';
|
|
195
|
+
this.builderTitle = '';
|
|
196
|
+
this.builderTitleHint = '';
|
|
197
|
+
this._availableFields = [];
|
|
198
|
+
this.dataViewChange = new i0.EventEmitter();
|
|
199
|
+
this.type = 'not-supported';
|
|
200
|
+
this.emptyDropAreaId = 'emptyDropArea';
|
|
201
|
+
this.mappedFieldsId = 'mappedFields';
|
|
202
|
+
this.availableFieldsTitles = new Map();
|
|
203
|
+
//
|
|
204
|
+
}
|
|
205
|
+
Object.defineProperty(DataViewBuilderComponent.prototype, "availableFields", {
|
|
206
|
+
get: function () {
|
|
207
|
+
return this._availableFields;
|
|
208
|
+
},
|
|
209
|
+
set: function (value) {
|
|
210
|
+
this._availableFields = value;
|
|
211
|
+
this.setTitlesMap();
|
|
212
|
+
},
|
|
213
|
+
enumerable: false,
|
|
214
|
+
configurable: true
|
|
215
|
+
});
|
|
216
|
+
Object.defineProperty(DataViewBuilderComponent.prototype, "dataView", {
|
|
217
|
+
get: function () {
|
|
218
|
+
return this._dataView;
|
|
219
|
+
},
|
|
220
|
+
set: function (value) {
|
|
221
|
+
this._dataView = value;
|
|
222
|
+
this.setType();
|
|
223
|
+
this.refreshAvailableFields();
|
|
224
|
+
},
|
|
225
|
+
enumerable: false,
|
|
226
|
+
configurable: true
|
|
227
|
+
});
|
|
228
|
+
DataViewBuilderComponent.prototype.setType = function () {
|
|
229
|
+
if (this._dataView.Type === 'Menu') {
|
|
230
|
+
this.type = 'menu';
|
|
231
|
+
}
|
|
232
|
+
else if (this._dataView.Type === 'Grid') {
|
|
233
|
+
this.type = 'list';
|
|
234
|
+
}
|
|
235
|
+
else if ((this._dataView.Type === 'Card') ||
|
|
236
|
+
(this._dataView.Type === 'Form') ||
|
|
237
|
+
(this._dataView.Type === 'Large') ||
|
|
238
|
+
(this._dataView.Type === 'Line')) {
|
|
239
|
+
this.type = 'card';
|
|
240
|
+
}
|
|
241
|
+
else {
|
|
242
|
+
this.type = 'not-supported';
|
|
243
|
+
}
|
|
244
|
+
};
|
|
245
|
+
DataViewBuilderComponent.prototype.setAvailableFieldPermission = function (field, disable) {
|
|
246
|
+
// Find the item in the available fields
|
|
247
|
+
var item = this.availableFields.find(function (as) { return as.data.key === field; });
|
|
248
|
+
// If exist disable or enable it.
|
|
249
|
+
if (item) {
|
|
250
|
+
item.disabled = disable;
|
|
251
|
+
}
|
|
252
|
+
};
|
|
253
|
+
DataViewBuilderComponent.prototype.refreshAvailableFields = function () {
|
|
254
|
+
this.availableFields.forEach(function (af) { return af.disabled = false; });
|
|
255
|
+
if (this.dataView && this.dataView.Fields) {
|
|
256
|
+
for (var index = 0; index < this.dataView.Fields.length; index++) {
|
|
257
|
+
this.setAvailableFieldPermission(this.dataView.Fields[index].FieldID, true);
|
|
258
|
+
}
|
|
259
|
+
}
|
|
260
|
+
};
|
|
261
|
+
DataViewBuilderComponent.prototype.setTitlesMap = function () {
|
|
262
|
+
var _a, _b;
|
|
263
|
+
this.availableFieldsTitles.clear();
|
|
264
|
+
if (((_a = this.availableFields) === null || _a === void 0 ? void 0 : _a.length) > 0) {
|
|
265
|
+
for (var index = 0; index < this.availableFields.length; index++) {
|
|
266
|
+
var availableField = this.availableFields[index];
|
|
267
|
+
if (((_b = availableField === null || availableField === void 0 ? void 0 : availableField.data) === null || _b === void 0 ? void 0 : _b.key.length) > 0) {
|
|
268
|
+
this.availableFieldsTitles.set(availableField.data.key, availableField.title);
|
|
269
|
+
}
|
|
270
|
+
}
|
|
271
|
+
}
|
|
272
|
+
};
|
|
273
|
+
DataViewBuilderComponent.prototype.notifyDataViewChange = function () {
|
|
274
|
+
this.dataViewChange.emit(this.dataView);
|
|
275
|
+
// console.log(this.dataView);
|
|
276
|
+
};
|
|
277
|
+
DataViewBuilderComponent.prototype.ngOnInit = function () {
|
|
278
|
+
//
|
|
279
|
+
};
|
|
280
|
+
DataViewBuilderComponent.prototype.onDragStart = function (event) {
|
|
281
|
+
this.dataViewBuilderService.onDragStart(event);
|
|
282
|
+
};
|
|
283
|
+
DataViewBuilderComponent.prototype.onDragEnd = function (event) {
|
|
284
|
+
this.dataViewBuilderService.onDragEnd(event);
|
|
285
|
+
};
|
|
286
|
+
DataViewBuilderComponent.prototype.onFieldsChanged = function (fields) {
|
|
287
|
+
this.dataView.Fields = fields;
|
|
288
|
+
this.refreshAvailableFields();
|
|
289
|
+
this.notifyDataViewChange();
|
|
290
|
+
};
|
|
291
|
+
return DataViewBuilderComponent;
|
|
292
|
+
}());
|
|
293
|
+
DataViewBuilderComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0__namespace, type: DataViewBuilderComponent, deps: [{ token: DataViewBuilderService }], target: i0__namespace.ɵɵFactoryTarget.Component });
|
|
294
|
+
DataViewBuilderComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.0.5", type: DataViewBuilderComponent, selector: "pep-data-view-builder", inputs: { builderTitle: "builderTitle", builderTitleHint: "builderTitleHint", availableFields: "availableFields", dataView: "dataView" }, outputs: { dataViewChange: "dataViewChange" }, ngImport: i0__namespace, template: "<pep-page-layout >\n <!-- <ng-container pep-top-area>\n <pep-top-bar [title]=\"title\">\n <div header-end-content>\n </div>\n </pep-top-bar>\n </ng-container> -->\n <ng-container pep-main-area>\n <ng-container *ngIf=\"type === 'not-supported' ; then notSupportedTemplate; else supportedTemplate\"></ng-container>\n <ng-template #notSupportedTemplate>\n <span class=\"body-sm ellipsis\">\n {{ 'DATA_VIEW_BUILDER.TYPE_NOT_SUPPORTED' | translate }}\n </span> \n </ng-template>\n <ng-template #supportedTemplate>\n <div *ngIf=\"dataView && availableFields\" class=\"mapped-fields-container\">\n <div class=\"available-fields-side-area\">\n <pep-draggable-items [items]=\"availableFields\" [title]=\"'DATA_VIEW_BUILDER.AVAILABLE_FIELDS' | translate\" titleType=\"with-bottom-border\" titleSizeType=\"md\"\n itemPlaceholderType=\"weak\" [showSearch]=\"true\" [dropAreaIds]=\"['emptyDropArea', 'mappedFields']\" (itemDragStarted)=\"onDragStart($event)\" (itemDragEnded)=\"onDragEnd($event)\">\n </pep-draggable-items>\n </div>\n <div pep-main-area class=\"mapped-fields-main-area\">\n <div class=\"mapped-fields-top-area pep-border-bottom\"\n [title]=\"builderTitle + ' ' + (builderTitleHint ? ('(' + builderTitleHint + ')') : '')\">\n <span class=\"title-md\">{{ builderTitle }} </span>\n <span *ngIf=\"builderTitleHint\" class=\"color-dimmed\">({{ builderTitleHint }})</span>\n </div>\n \n <div class=\"data-view-by-type-area\" [ngSwitch]=\"type\">\n <ng-container *ngSwitchCase=\"'menu'\">\n <menu-data-view [fields]=\"dataView?.Fields || []\" [availableFieldsTitles]=\"availableFieldsTitles\" [emptyDropAreaId]=\"emptyDropAreaId\"\n [mappedFieldsId]=\"mappedFieldsId\" (fieldsChange)=\"onFieldsChanged($event)\">\n </menu-data-view>\n </ng-container>\n <!-- <ng-container *ngSwitchDefault>\n </ng-container> -->\n </div>\n </div>\n </div>\n </ng-template>\n </ng-container>\n</pep-page-layout>\n\n", styles: [".mapped-fields-container{display:grid;height:100%;grid-template-columns:auto 1fr;grid-template-areas:\"side-area main-area\"}.mapped-fields-container .available-fields-side-area{grid-area:side-area;width:240px;max-width:240px;overflow:auto;height:inherit;padding-top:var(--pep-spacing-2xl, 2rem);margin-inline-end:calc(var(--pep-spacing-lg, 1rem) * 2)}.mapped-fields-container .mapped-fields-main-area{display:grid;grid-template-rows:auto 1fr;grid-area:main-area;padding-top:var(--pep-spacing-2xl, 2rem);overflow:auto;height:inherit}.mapped-fields-container .mapped-fields-main-area .mapped-fields-top-area{height:var(--pep-top-bar-field-height, 2.5rem);display:flex;align-items:center}.mapped-fields-container .mapped-fields-main-area .data-view-by-type-area{overflow:auto;height:inherit;padding-top:var(--pep-spacing-lg, 1rem);padding-bottom:var(--pep-spacing-lg, 1rem);padding-inline:var(--pep-spacing-xs, .25rem)}\n"], components: [{ type: i2__namespace.PepPageLayoutComponent, selector: "pep-page-layout", inputs: ["addPadding", "showShadow"] }, { type: i3__namespace$1.DraggableItemsComponent, selector: "pep-draggable-items", inputs: ["containerId", "showSearch", "title", "titleType", "titleSizeType", "itemPlaceholderType", "dropAreaIds", "items"], outputs: ["itemDragStarted", "itemDragEnded"] }, { type: MenuDataViewComponent, selector: "menu-data-view", inputs: ["fields", "availableFieldsTitles", "emptyDropAreaId", "mappedFieldsId"], outputs: ["fieldsChange"] }], directives: [{ type: i7__namespace.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i7__namespace.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { type: i7__namespace.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }], pipes: { "translate": i9__namespace.TranslatePipe } });
|
|
295
|
+
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0__namespace, type: DataViewBuilderComponent, decorators: [{
|
|
296
|
+
type: i0.Component,
|
|
297
|
+
args: [{
|
|
298
|
+
selector: 'pep-data-view-builder',
|
|
299
|
+
templateUrl: './data-view-builder.component.html',
|
|
300
|
+
styleUrls: ['./data-view-builder.component.scss']
|
|
301
|
+
}]
|
|
302
|
+
}], ctorParameters: function () { return [{ type: DataViewBuilderService }]; }, propDecorators: { builderTitle: [{
|
|
303
|
+
type: i0.Input
|
|
304
|
+
}], builderTitleHint: [{
|
|
305
|
+
type: i0.Input
|
|
306
|
+
}], availableFields: [{
|
|
307
|
+
type: i0.Input
|
|
308
|
+
}], dataView: [{
|
|
309
|
+
type: i0.Input
|
|
310
|
+
}], dataViewChange: [{
|
|
311
|
+
type: i0.Output
|
|
312
|
+
}] } });
|
|
313
|
+
|
|
314
|
+
var pepIcons = [
|
|
315
|
+
i1$1.pepIconSystemClose,
|
|
316
|
+
i1$1.pepIconArrowDownAlt,
|
|
317
|
+
i1$1.pepIconSystemBin,
|
|
318
|
+
i1$1.pepIconNumberPlus
|
|
319
|
+
];
|
|
320
|
+
var PepDataViewBuilderModule = /** @class */ (function () {
|
|
321
|
+
function PepDataViewBuilderModule(pepIconRegistry) {
|
|
322
|
+
this.pepIconRegistry = pepIconRegistry;
|
|
323
|
+
this.pepIconRegistry.registerIcons(pepIcons);
|
|
324
|
+
}
|
|
325
|
+
return PepDataViewBuilderModule;
|
|
326
|
+
}());
|
|
327
|
+
PepDataViewBuilderModule.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0__namespace, type: PepDataViewBuilderModule, deps: [{ token: i1__namespace$1.PepIconRegistry }], target: i0__namespace.ɵɵFactoryTarget.NgModule });
|
|
328
|
+
PepDataViewBuilderModule.ɵmod = i0__namespace.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0__namespace, type: PepDataViewBuilderModule, declarations: [DataViewBuilderComponent, MenuDataViewComponent], imports: [i7.CommonModule,
|
|
329
|
+
i8.DragDropModule,
|
|
330
|
+
i3.MatIconModule,
|
|
331
|
+
ngxLib.PepNgxLibModule,
|
|
332
|
+
i5.PepButtonModule,
|
|
333
|
+
i1.PepDialogModule,
|
|
334
|
+
i1$1.PepIconModule,
|
|
335
|
+
menu.PepMenuModule,
|
|
336
|
+
i2.PepPageLayoutModule,
|
|
337
|
+
i6.PepTextboxModule,
|
|
338
|
+
topBar.PepTopBarModule,
|
|
339
|
+
i3$1.PepDraggableItemsModule], exports: [DataViewBuilderComponent] });
|
|
340
|
+
PepDataViewBuilderModule.ɵinj = i0__namespace.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0__namespace, type: PepDataViewBuilderModule, providers: [DataViewBuilderService], imports: [[
|
|
341
|
+
i7.CommonModule,
|
|
342
|
+
i8.DragDropModule,
|
|
343
|
+
i3.MatIconModule,
|
|
344
|
+
ngxLib.PepNgxLibModule,
|
|
345
|
+
i5.PepButtonModule,
|
|
346
|
+
i1.PepDialogModule,
|
|
347
|
+
i1$1.PepIconModule,
|
|
348
|
+
menu.PepMenuModule,
|
|
349
|
+
i2.PepPageLayoutModule,
|
|
350
|
+
i6.PepTextboxModule,
|
|
351
|
+
topBar.PepTopBarModule,
|
|
352
|
+
i3$1.PepDraggableItemsModule,
|
|
353
|
+
]] });
|
|
354
|
+
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0__namespace, type: PepDataViewBuilderModule, decorators: [{
|
|
355
|
+
type: i0.NgModule,
|
|
356
|
+
args: [{
|
|
357
|
+
declarations: [
|
|
358
|
+
DataViewBuilderComponent, MenuDataViewComponent
|
|
359
|
+
],
|
|
360
|
+
imports: [
|
|
361
|
+
i7.CommonModule,
|
|
362
|
+
i8.DragDropModule,
|
|
363
|
+
i3.MatIconModule,
|
|
364
|
+
ngxLib.PepNgxLibModule,
|
|
365
|
+
i5.PepButtonModule,
|
|
366
|
+
i1.PepDialogModule,
|
|
367
|
+
i1$1.PepIconModule,
|
|
368
|
+
menu.PepMenuModule,
|
|
369
|
+
i2.PepPageLayoutModule,
|
|
370
|
+
i6.PepTextboxModule,
|
|
371
|
+
topBar.PepTopBarModule,
|
|
372
|
+
i3$1.PepDraggableItemsModule,
|
|
373
|
+
],
|
|
374
|
+
exports: [DataViewBuilderComponent],
|
|
375
|
+
providers: [DataViewBuilderService]
|
|
376
|
+
}]
|
|
377
|
+
}], ctorParameters: function () { return [{ type: i1__namespace$1.PepIconRegistry }]; } });
|
|
378
|
+
|
|
379
|
+
/*
|
|
380
|
+
* Public API Surface of ngx-composite-lib/data-view-builder
|
|
381
|
+
*/
|
|
382
|
+
|
|
383
|
+
/**
|
|
384
|
+
* Generated bundle index. Do not edit.
|
|
385
|
+
*/
|
|
386
|
+
|
|
387
|
+
exports.DataViewBuilderComponent = DataViewBuilderComponent;
|
|
388
|
+
exports.PepDataViewBuilderModule = PepDataViewBuilderModule;
|
|
389
|
+
|
|
390
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
391
|
+
|
|
392
|
+
}));
|
|
393
|
+
//# sourceMappingURL=pepperi-addons-ngx-composite-lib-data-view-builder.umd.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"pepperi-addons-ngx-composite-lib-data-view-builder.umd.js","sources":["../../../projects/ngx-composite-lib/data-view-builder/data-view-builder.service.ts","../../../projects/ngx-composite-lib/data-view-builder/menu-data-view/menu-data-view.component.ts","../../../projects/ngx-composite-lib/data-view-builder/menu-data-view/menu-data-view.component.html","../../../projects/ngx-composite-lib/data-view-builder/data-view-builder.component.ts","../../../projects/ngx-composite-lib/data-view-builder/data-view-builder.component.html","../../../projects/ngx-composite-lib/data-view-builder/data-view-builder.module.ts","../../../projects/ngx-composite-lib/data-view-builder/public-api.ts","../../../projects/ngx-composite-lib/data-view-builder/pepperi-addons-ngx-composite-lib-data-view-builder.ts"],"sourcesContent":["import { CdkDragEnd, CdkDragStart } from '@angular/cdk/drag-drop';\nimport { Injectable } from '@angular/core';\nimport { BehaviorSubject, Observable } from 'rxjs';\nimport { distinctUntilChanged, filter } from 'rxjs/operators';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class DataViewBuilderService {\n \n // This subject is for is grabbing mode.\n private _isGrabbingSubject: BehaviorSubject<boolean> = new BehaviorSubject<boolean>(false);\n get isGrabbingChange$(): Observable<boolean> {\n return this._isGrabbingSubject.asObservable().pipe(distinctUntilChanged());\n }\n\n constructor() { \n //\n }\n\n private changeCursorOnDragStart() {\n document.body.classList.add('inheritCursors');\n document.body.style.cursor = 'grabbing';\n this._isGrabbingSubject.next(true);\n }\n\n private changeCursorOnDragEnd() {\n document.body.classList.remove('inheritCursors');\n document.body.style.cursor = 'unset';\n this._isGrabbingSubject.next(false);\n }\n \n onDragStart(event: CdkDragStart) {\n this.changeCursorOnDragStart();\n }\n\n onDragEnd(event: CdkDragEnd) {\n this.changeCursorOnDragEnd();\n }\n}\n","import { CdkDragDrop, CdkDragEnd, CdkDragStart, moveItemInArray } from '@angular/cdk/drag-drop';\nimport { Component, EventEmitter, Input, OnInit, Output, TemplateRef, ViewChild } from '@angular/core';\nimport { MatDialogRef } from '@angular/material/dialog';\nimport { TranslateService } from '@ngx-translate/core';\nimport { IPepButtonClickEvent } from '@pepperi-addons/ngx-lib/button';\nimport { PepDialogService } from '@pepperi-addons/ngx-lib/dialog';\nimport { IPepDraggableItem } from '@pepperi-addons/ngx-lib/draggable-items';\nimport { DataViewField, MenuDataViewField } from '@pepperi-addons/papi-sdk';\nimport { DataViewBuilderService } from '../data-view-builder.service';\n\n@Component({\n selector: 'menu-data-view',\n templateUrl: './menu-data-view.component.html',\n styleUrls: ['./menu-data-view.component.scss']\n})\nexport class MenuDataViewComponent implements OnInit {\n @ViewChild('separatorTitleModalTemplate', { read: TemplateRef }) separatorTitleModalTemplate!: TemplateRef<any>;\n\n @Input() \n fields: Array<DataViewField> = []; // The data view fields.\n\n @Input()\n availableFieldsTitles: Map<string, string> = new Map<string, string>(); // <FieldID, Original Title> from the available fields.\n\n @Input() \n emptyDropAreaId = '';\n\n @Input() \n mappedFieldsId = '';\n\n @Output()\n fieldsChange: EventEmitter<DataViewField[]> = new EventEmitter<DataViewField[]>();\n \n isGrabbing = false;\n private dialogRef: MatDialogRef<any> | null = null;\n \n constructor(\n private dialogService: PepDialogService,\n private dataViewBuilderService: DataViewBuilderService\n ) { \n this.dataViewBuilderService.isGrabbingChange$.subscribe((value) => {\n this.isGrabbing = value;\n });\n }\n \n private addNewField(draggableItem: IPepDraggableItem, index: number) {\n // Add new menuField to the mappedFields.\n const menuField: MenuDataViewField = { FieldID: draggableItem.data.key, Title: draggableItem.title };\n this.spliceMappedFields(index, 0, menuField);\n }\n \n private spliceMappedFields(start: number, deleteCount: number, item?: MenuDataViewField) {\n if (item) {\n this.fields.splice(start, deleteCount, item);\n } else {\n this.fields.splice(start, deleteCount);\n }\n\n this.notifyFieldsChange();\n }\n\n private changeTitle(menuField: MenuDataViewField, title: string) {\n menuField.Title = title;\n this.notifyFieldsChange();\n }\n\n private notifyFieldsChange() {\n this.fieldsChange.emit(this.fields);\n }\n\n ngOnInit() {\n //\n }\n\n addSeparator(index: number) {\n const menuField: MenuDataViewField = { FieldID: '', Title: '' };\n this.spliceMappedFields(index, 0, menuField);\n }\n\n onDragStart(event: CdkDragStart) {\n this.dataViewBuilderService.onDragStart(event);\n }\n\n onDragEnd(event: CdkDragEnd) {\n this.dataViewBuilderService.onDragEnd(event);\n }\n \n onDropField(event: CdkDragDrop<any[]>) {\n if (event.previousContainer === event.container) {\n moveItemInArray(event.container.data, event.previousIndex, event.currentIndex);\n this.notifyFieldsChange();\n } else if (event.container.id === 'emptyDropArea') {\n this.addNewField(event.previousContainer.data[event.previousIndex], this.fields.length);\n } else {\n this.addNewField(event.previousContainer.data[event.previousIndex], event.currentIndex);\n }\n }\n\n onTitleChanged(event: string, menuField: MenuDataViewField) {\n this.changeTitle(menuField, event);\n }\n\n onDeleteMappedField(event: IPepButtonClickEvent, menuField: MenuDataViewField) {\n const index = this.fields.findIndex(ms => ms === menuField);\n if (index > -1) {\n this.spliceMappedFields(index, 1);\n }\n }\n\n onEditSeparatorField(event: IPepButtonClickEvent, menuField: MenuDataViewField) {\n this.dialogRef = this.dialogService.openDialog(this.separatorTitleModalTemplate, { value: menuField.Title });\n this.dialogRef.afterClosed().subscribe((titleValue) => {\n if (titleValue !== undefined) {\n this.changeTitle(menuField, titleValue);\n }\n });\n }\n\n setDialogValue(value: string) {\n this.closeDialog(value);\n }\n\n closeDialog(value: string | undefined = undefined) {\n this.dialogRef?.close(value);\n }\n}\n","<ng-container *ngIf=\"fields === null || fields.length === 0; then emptyTemplate; else notEmptyTemplate\"></ng-container>\n<ng-template #emptyTemplate>\n <div [id]=\"emptyDropAreaId\" class=\"drop-field-here-area\" cdkDropList (cdkDropListDropped)=\"onDropField($event)\">\n <mat-icon class=\"pep-spacing-element\">\n <pep-icon name=\"arrow_down_alt\"></pep-icon>\n </mat-icon>\n <span class=\"body-sm ellipsis\">\n {{ 'DATA_VIEW_BUILDER.EMPTY_DROP_AREA_TEXT' | translate }}\n </span> \n </div>\n</ng-template>\n<ng-template #notEmptyTemplate>\n <div [id]=\"mappedFieldsId\" class=\"mapped-fields-area\" [ngClass]=\"{ 'no-row-gap': !isGrabbing }\"\n cdkDropList [cdkDropListData]=\"fields\" (cdkDropListDropped)=\"onDropField($event)\">\n <ng-container *ngFor=\"let menuField of fields; let i = index\" >\n <div class=\"mapped-field-container\" [ngClass]=\"{ 'separator-container': menuField.FieldID === '' }\" \n cdkDrag (cdkDragStarted)=\"onDragStart($event)\" (cdkDragEnded)=\"onDragEnd($event)\">\n <ng-container *ngTemplateOutlet=\"mappedFieldTemplate; context: { menuField: menuField }\"></ng-container>\n </div>\n <div *ngIf=\"!isGrabbing\" class=\"add-separator-container\">\n <pep-button class=\"add-separator\" styleType=\"regular\" sizeType=\"sm\" iconName=\"number_plus\" \n [value]=\"'DATA_VIEW_BUILDER.ADD_SEPARATOR' | translate\" (buttonClick)=\"addSeparator(i+1)\"></pep-button>\n </div>\n </ng-container>\n </div>\n</ng-template>\n\n<ng-template #mappedFieldTemplate let-menuField=\"menuField\">\n <ng-container *ngIf=\"menuField.FieldID !== ''; then menuItemTemplate; else separatorTemplate\"></ng-container>\n\n <ng-template #menuItemTemplate>\n <div class=\"fields-wrapper\">\n <pep-textbox [label]=\"'DATA_VIEW_BUILDER.MENU_ITEM_KEY_TITLE' | translate\" [value]=\"menuField.FieldID\" [disabled]=\"true\">\n </pep-textbox>\n \n <pep-textbox [label]=\"'DATA_VIEW_BUILDER.MENU_ITEM_VALUE_TITLE' | translate\" [hint]=\"'(' + (availableFieldsTitles.get(menuField.FieldID) || '') + ')'\"\n [value]=\"menuField.Title\" (valueChange)=\"onTitleChanged($event, menuField)\">\n </pep-textbox>\n \n <pep-button class=\"center-button\" iconName=\"system_bin\" [title]=\"'ACTIONS.DELETE' | translate\" (buttonClick)=\"onDeleteMappedField($event, menuField)\"></pep-button>\n </div>\n </ng-template>\n <ng-template #separatorTemplate>\n <div class=\"separator-wrapper \">\n <div class=\"pep-spacing-element title title-md color-dimmed\">\n <span [title]=\"menuField.Title\">{{ menuField.Title }}</span>\n </div>\n <div class=\"list-actions\">\n <pep-button iconName=\"system_edit\" [title]=\"'ACTIONS.EDIT' | translate\" sizeType=\"xs\" styleType=\"regular\" (buttonClick)=\"onEditSeparatorField($event, menuField)\"></pep-button>\n <pep-button iconName=\"system_bin\" [title]=\"'ACTIONS.DELETE' | translate\" sizeType=\"xs\" styleType=\"regular\" (buttonClick)=\"onDeleteMappedField($event, menuField)\"></pep-button>\n </div>\n </div>\n </ng-template>\n</ng-template>\n\n<ng-template #separatorTitleModalTemplate let-data>\n <pep-dialog [title]=\"'DATA_VIEW_BUILDER.SEPARATOR_TITLE' | translate\">\n <ng-container pep-dialog-content>\n <pep-textbox #txt [label]=\"'DATA_VIEW_BUILDER.ADD_A_TITLE' | translate\" [(value)]=\"data.value\">\n </pep-textbox>\n </ng-container>\n <ng-container pep-dialog-actions>\n <div class=\"pep-spacing-element-negative\">\n <button mat-button class=\"pep-spacing-element pep-button md weak\"\n (click)=\"closeDialog()\">\n {{'Cancel' | translate}}\n </button>\n <button mat-button class=\"pep-spacing-element pep-button md strong\"\n (click)=\"setDialogValue(txt.value)\">\n {{ 'Save' | translate}}\n </button>\n </div>\n </ng-container>\n </pep-dialog>\n</ng-template>","import { CdkDragEnd, CdkDragStart } from '@angular/cdk/drag-drop';\nimport { Component, EventEmitter, Input, OnInit, Output, TemplateRef, ViewChild } from '@angular/core';\nimport { IPepDraggableItem } from '@pepperi-addons/ngx-lib/draggable-items';\nimport { BaseDataView, DataViewField } from '@pepperi-addons/papi-sdk';\nimport { PepDataViewBuilderType } from './data-view-builder.model';\nimport { DataViewBuilderService } from './data-view-builder.service';\n\n@Component({\n selector: 'pep-data-view-builder',\n templateUrl: './data-view-builder.component.html',\n styleUrls: ['./data-view-builder.component.scss']\n})\nexport class DataViewBuilderComponent implements OnInit {\n // @Input() title: string = '';\n @Input() builderTitle = '';\n @Input() builderTitleHint = '';\n \n private _availableFields: Array<IPepDraggableItem> = [];\n @Input()\n set availableFields(value: Array<IPepDraggableItem>) {\n this._availableFields = value;\n this.setTitlesMap();\n }\n get availableFields(): Array<IPepDraggableItem> {\n return this._availableFields;\n }\n \n private _dataView!: BaseDataView;\n @Input()\n set dataView(value: BaseDataView) {\n this._dataView = value;\n this.setType();\n this.refreshAvailableFields();\n }\n get dataView() : BaseDataView {\n return this._dataView;\n }\n\n @Output()\n dataViewChange: EventEmitter<BaseDataView> = new EventEmitter<BaseDataView>();\n \n type: PepDataViewBuilderType = 'not-supported';\n \n emptyDropAreaId = 'emptyDropArea';\n mappedFieldsId = 'mappedFields';\n\n availableFieldsTitles: Map<string, string> = new Map<string, string>();\n\n constructor(\n private dataViewBuilderService: DataViewBuilderService\n ) {\n //\n }\n\n private setType() {\n if (this._dataView.Type === 'Menu') {\n this.type = 'menu';\n } else if (this._dataView.Type === 'Grid') {\n this.type = 'list';\n } else if ((this._dataView.Type === 'Card') || \n (this._dataView.Type === 'Form') || \n (this._dataView.Type === 'Large') || \n (this._dataView.Type === 'Line')) {\n this.type = 'card';\n } else {\n this.type = 'not-supported';\n }\n }\n\n private setAvailableFieldPermission(field: string, disable: boolean) {\n // Find the item in the available fields\n const item = this.availableFields.find(as => as.data.key === field);\n \n // If exist disable or enable it.\n if (item) {\n item.disabled = disable;\n }\n }\n\n private refreshAvailableFields() {\n this.availableFields.forEach(af => af.disabled = false);\n \n if (this.dataView && this.dataView.Fields) {\n for (let index = 0; index < this.dataView.Fields.length; index++) {\n this.setAvailableFieldPermission(this.dataView.Fields[index].FieldID, true);\n }\n }\n }\n\n private setTitlesMap() {\n this.availableFieldsTitles.clear();\n\n if (this.availableFields?.length > 0) {\n for (let index = 0; index < this.availableFields.length; index++) {\n const availableField = this.availableFields[index];\n\n if (availableField?.data?.key.length > 0) {\n this.availableFieldsTitles.set(availableField.data.key, availableField.title);\n }\n }\n }\n }\n\n private notifyDataViewChange() {\n this.dataViewChange.emit(this.dataView);\n // console.log(this.dataView);\n }\n\n ngOnInit() {\n //\n }\n\n onDragStart(event: CdkDragStart) {\n this.dataViewBuilderService.onDragStart(event);\n }\n\n onDragEnd(event: CdkDragEnd) {\n this.dataViewBuilderService.onDragEnd(event);\n }\n \n onFieldsChanged(fields: Array<DataViewField>) {\n this.dataView.Fields = fields;\n this.refreshAvailableFields();\n this.notifyDataViewChange();\n }\n}\n","<pep-page-layout >\n <!-- <ng-container pep-top-area>\n <pep-top-bar [title]=\"title\">\n <div header-end-content>\n </div>\n </pep-top-bar>\n </ng-container> -->\n <ng-container pep-main-area>\n <ng-container *ngIf=\"type === 'not-supported' ; then notSupportedTemplate; else supportedTemplate\"></ng-container>\n <ng-template #notSupportedTemplate>\n <span class=\"body-sm ellipsis\">\n {{ 'DATA_VIEW_BUILDER.TYPE_NOT_SUPPORTED' | translate }}\n </span> \n </ng-template>\n <ng-template #supportedTemplate>\n <div *ngIf=\"dataView && availableFields\" class=\"mapped-fields-container\">\n <div class=\"available-fields-side-area\">\n <pep-draggable-items [items]=\"availableFields\" [title]=\"'DATA_VIEW_BUILDER.AVAILABLE_FIELDS' | translate\" titleType=\"with-bottom-border\" titleSizeType=\"md\"\n itemPlaceholderType=\"weak\" [showSearch]=\"true\" [dropAreaIds]=\"['emptyDropArea', 'mappedFields']\" (itemDragStarted)=\"onDragStart($event)\" (itemDragEnded)=\"onDragEnd($event)\">\n </pep-draggable-items>\n </div>\n <div pep-main-area class=\"mapped-fields-main-area\">\n <div class=\"mapped-fields-top-area pep-border-bottom\"\n [title]=\"builderTitle + ' ' + (builderTitleHint ? ('(' + builderTitleHint + ')') : '')\">\n <span class=\"title-md\">{{ builderTitle }} </span>\n <span *ngIf=\"builderTitleHint\" class=\"color-dimmed\">({{ builderTitleHint }})</span>\n </div>\n \n <div class=\"data-view-by-type-area\" [ngSwitch]=\"type\">\n <ng-container *ngSwitchCase=\"'menu'\">\n <menu-data-view [fields]=\"dataView?.Fields || []\" [availableFieldsTitles]=\"availableFieldsTitles\" [emptyDropAreaId]=\"emptyDropAreaId\"\n [mappedFieldsId]=\"mappedFieldsId\" (fieldsChange)=\"onFieldsChanged($event)\">\n </menu-data-view>\n </ng-container>\n <!-- <ng-container *ngSwitchDefault>\n </ng-container> -->\n </div>\n </div>\n </div>\n </ng-template>\n </ng-container>\n</pep-page-layout>\n\n","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\n\nimport { DragDropModule } from '@angular/cdk/drag-drop';\n\nimport { MatIconModule } from '@angular/material/icon';\n\nimport { PepNgxLibModule } from '@pepperi-addons/ngx-lib';\nimport { PepButtonModule } from '@pepperi-addons/ngx-lib/button';\nimport { PepDialogModule } from '@pepperi-addons/ngx-lib/dialog';\nimport { PepMenuModule } from '@pepperi-addons/ngx-lib/menu';\nimport { PepPageLayoutModule } from '@pepperi-addons/ngx-lib/page-layout';\nimport { PepTextboxModule } from '@pepperi-addons/ngx-lib/textbox';\nimport { PepTopBarModule } from '@pepperi-addons/ngx-lib/top-bar';\nimport { PepDraggableItemsModule } from '@pepperi-addons/ngx-lib/draggable-items';\nimport { PepIconRegistry, PepIconModule, pepIconSystemClose, pepIconArrowDownAlt, pepIconSystemBin, pepIconNumberPlus } from '@pepperi-addons/ngx-lib/icon';\n\nimport { DataViewBuilderService } from './data-view-builder.service';\n\nimport { DataViewBuilderComponent } from './data-view-builder.component';\nimport { MenuDataViewComponent } from './menu-data-view/menu-data-view.component';\n\nconst pepIcons = [\n pepIconSystemClose,\n pepIconArrowDownAlt,\n pepIconSystemBin,\n pepIconNumberPlus\n];\n\n@NgModule({\n declarations: [\n DataViewBuilderComponent, MenuDataViewComponent\n ],\n imports: [\n CommonModule,\n DragDropModule,\n MatIconModule,\n PepNgxLibModule,\n PepButtonModule,\n PepDialogModule,\n PepIconModule,\n PepMenuModule,\n PepPageLayoutModule,\n PepTextboxModule,\n PepTopBarModule,\n PepDraggableItemsModule,\n ],\n exports: [DataViewBuilderComponent],\n providers: [DataViewBuilderService]\n})\nexport class PepDataViewBuilderModule {\n constructor(\n private pepIconRegistry: PepIconRegistry,\n ) {\n this.pepIconRegistry.registerIcons(pepIcons);\n }\n}\n","/*\n * Public API Surface of ngx-composite-lib/data-view-builder\n */\nexport * from './data-view-builder.module';\nexport * from './data-view-builder.component';\nexport * from './data-view-builder.model';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":["BehaviorSubject","distinctUntilChanged","Injectable","EventEmitter","moveItemInArray","TemplateRef","Component","ViewChild","Input","Output","pepIconSystemClose","pepIconArrowDownAlt","pepIconSystemBin","pepIconNumberPlus","CommonModule","DragDropModule","MatIconModule","PepNgxLibModule","PepButtonModule","PepDialogModule","PepIconModule","PepMenuModule","PepPageLayoutModule","PepTextboxModule","PepTopBarModule","PepDraggableItemsModule","NgModule"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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