@rlucan/ui 14.2.6 → 16.2.2
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/README.md +24 -24
- package/esm2022/lib/action-button/action-button.component.mjs +99 -99
- package/esm2022/lib/action-icon/action-icon.component.mjs +36 -36
- package/esm2022/lib/autocomplete/autocomplete.component.mjs +390 -390
- package/esm2022/lib/avatar/avatar.component.mjs +34 -34
- package/esm2022/lib/button/button.component.mjs +56 -56
- package/esm2022/lib/checkbox/checkbox.component.mjs +38 -38
- package/esm2022/lib/checkbox-group/checkbox-group.component.mjs +90 -90
- package/esm2022/lib/currency/currency.component.mjs +150 -150
- package/esm2022/lib/date/date.component.mjs +67 -67
- package/esm2022/lib/dialog/dialog.component.mjs +36 -36
- package/esm2022/lib/directives/force-visibility/force-visibility.directive.mjs +104 -104
- package/esm2022/lib/editor/editor.component.mjs +118 -118
- package/esm2022/lib/elements/burger/burger.component.mjs +20 -20
- package/esm2022/lib/elements/expander/expander.component.mjs +27 -27
- package/esm2022/lib/elements/validation-message/validation-message.component.mjs +46 -46
- package/esm2022/lib/file/file.component.mjs +144 -144
- package/esm2022/lib/file-uploader/ui-file-uploader.component.mjs +404 -404
- package/esm2022/lib/input/input.component.mjs +264 -264
- package/esm2022/lib/input-autocomplete/input-autocomplete.component.mjs +276 -276
- package/esm2022/lib/layouts/base/ui-base-layout.component.mjs +21 -21
- package/esm2022/lib/layouts/base/ui-base.component.mjs +73 -73
- package/esm2022/lib/layouts/simple/ui-simple-layout.component.mjs +17 -17
- package/esm2022/lib/layouts/simple/ui-simple.component.mjs +165 -165
- package/esm2022/lib/radio/radio.component.mjs +20 -20
- package/esm2022/lib/radio-group/radio-group.component.mjs +53 -53
- package/esm2022/lib/select/select.component.mjs +126 -115
- package/esm2022/lib/services/message-box.service.mjs +110 -110
- package/esm2022/lib/services/toast.service.mjs +23 -23
- package/esm2022/lib/services/ui-file.service.mjs +70 -70
- package/esm2022/lib/services/ui-translate.service.mjs +31 -31
- package/esm2022/lib/submit-button/submit-button.component.mjs +71 -71
- package/esm2022/lib/table/table.component.mjs +97 -97
- package/esm2022/lib/text-area/text-area.component.mjs +45 -45
- package/esm2022/lib/ui.model.mjs +1 -1
- package/esm2022/lib/ui.module.mjs +268 -268
- package/esm2022/public-api.mjs +34 -34
- package/esm2022/rlucan-ui.mjs +4 -4
- package/fesm2022/rlucan-ui.mjs +3285 -3274
- package/fesm2022/rlucan-ui.mjs.map +1 -1
- package/index.d.ts +5 -5
- package/lib/action-button/action-button.component.d.ts +28 -32
- package/lib/action-icon/action-icon.component.d.ts +15 -15
- package/lib/autocomplete/autocomplete.component.d.ts +57 -57
- package/lib/avatar/avatar.component.d.ts +14 -14
- package/lib/button/button.component.d.ts +18 -18
- package/lib/checkbox/checkbox.component.d.ts +15 -15
- package/lib/checkbox-group/checkbox-group.component.d.ts +18 -18
- package/lib/currency/currency.component.d.ts +31 -31
- package/lib/date/date.component.d.ts +24 -24
- package/lib/dialog/dialog.component.d.ts +13 -13
- package/lib/directives/force-visibility/force-visibility.directive.d.ts +22 -22
- package/lib/editor/editor.component.d.ts +24 -24
- package/lib/elements/burger/burger.component.d.ts +9 -9
- package/lib/elements/expander/expander.component.d.ts +10 -10
- package/lib/elements/validation-message/validation-message.component.d.ts +12 -12
- package/lib/file/file.component.d.ts +35 -35
- package/lib/file-uploader/ui-file-uploader.component.d.ts +102 -102
- package/lib/input/input.component.d.ts +42 -42
- package/lib/input-autocomplete/input-autocomplete.component.d.ts +44 -44
- package/lib/layouts/base/ui-base-layout.component.d.ts +8 -8
- package/lib/layouts/base/ui-base.component.d.ts +23 -23
- package/lib/layouts/simple/ui-simple-layout.component.d.ts +8 -8
- package/lib/layouts/simple/ui-simple.component.d.ts +40 -40
- package/lib/radio/radio.component.d.ts +8 -8
- package/lib/radio-group/radio-group.component.d.ts +18 -18
- package/lib/select/select.component.d.ts +37 -35
- package/lib/services/message-box.service.d.ts +58 -58
- package/lib/services/toast.service.d.ts +13 -13
- package/lib/services/ui-file.service.d.ts +33 -33
- package/lib/services/ui-translate.service.d.ts +11 -11
- package/lib/submit-button/submit-button.component.d.ts +21 -21
- package/lib/table/table.component.d.ts +36 -36
- package/lib/text-area/text-area.component.d.ts +18 -18
- package/lib/ui.model.d.ts +2 -2
- package/lib/ui.module.d.ts +59 -59
- package/package.json +1 -1
- package/public-api.d.ts +29 -29
- package/src/js/editorjs.mjs +9634 -9634
|
@@ -1,37 +1,37 @@
|
|
|
1
|
-
import { Component, Input } from '@angular/core';
|
|
2
|
-
import * as i0 from "@angular/core";
|
|
3
|
-
import * as i1 from "@angular/material/dialog";
|
|
4
|
-
import * as i2 from "@angular/common";
|
|
5
|
-
import * as i3 from "@angular/cdk/drag-drop";
|
|
6
|
-
import * as i4 from "../action-icon/action-icon.component";
|
|
7
|
-
export class DialogComponent {
|
|
8
|
-
constructor(dialogRef) {
|
|
9
|
-
this.dialogRef = dialogRef;
|
|
10
|
-
this.title = '';
|
|
11
|
-
this.draggable = false; // true;
|
|
12
|
-
this.hideCloseButton = false;
|
|
13
|
-
}
|
|
14
|
-
clickClose() {
|
|
15
|
-
if (!this.close) {
|
|
16
|
-
this.dialogRef.close();
|
|
17
|
-
}
|
|
18
|
-
else {
|
|
19
|
-
this.close();
|
|
20
|
-
}
|
|
21
|
-
}
|
|
22
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.11", ngImport: i0, type: DialogComponent, deps: [{ token: i1.MatDialogRef }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
23
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.11", type: DialogComponent, selector: "ui-dialog", inputs: { title: "title", draggable: "draggable", hideCloseButton: "hideCloseButton", close: "close" }, ngImport: i0, template: "<ui-action-icon *ngIf=\"title && !hideCloseButton\" (click)=\"clickClose()\" class=\"close-icon\" [matIcon]=\"'close'\" [color]=\"'warn'\"></ui-action-icon>\r\n\r\n<ng-container *ngIf=\"title\">\r\n <h1 class=\"draggable\" cdkDrag cdkDragRootElement=\".cdk-overlay-pane\" cdkDragHandle mat-dialog-title *ngIf=\"draggable\">\r\n {{title}}\r\n </h1>\r\n <h1 mat-dialog-title *ngIf=\"!draggable\">\r\n {{title}}\r\n </h1>\r\n</ng-container>\r\n\r\n<ng-content></ng-content>\r\n", styles: [":host{height:100%;display:flex;flex-direction:column}::ng-deep .mat-mdc-dialog-container{position:relative;overflow:visible!important}::ng-deep .mat-mdc-dialog-container .mdc-dialog__content{line-height:unset!important;letter-spacing:unset!important;color:unset!important}::ng-deep .mat-mdc-dialog-container .mat-mdc-dialog-title{font-size:24px;margin:0 0 5px;padding:12px 16px;border-bottom:1px solid transparent}::ng-deep .mat-mdc-dialog-container .mat-mdc-dialog-title.draggable{cursor:move}::ng-deep .mat-mdc-dialog-container h1{display:flex;align-items:center}::ng-deep .mat-mdc-dialog-container .close-icon{position:absolute;right:16px;top:16px;z-index:1}::ng-deep .mat-mdc-dialog-container .mat-mdc-dialog-actions{display:flex;flex-direction:column;border-top:1px solid transparent;margin-top:5px;padding:0}::ng-deep .mat-mdc-dialog-container .mat-mdc-dialog-actions.mat-dialog-actions{margin:0 -12px -16px}::ng-deep .mat-mdc-dialog-container .mat-mdc-dialog-actions .buttons{display:flex;flex:1 1 auto;justify-content:flex-end;align-items:center;width:100%;padding:8px}::ng-deep .mat-mdc-dialog-container .mat-mdc-dialog-actions .message{flex:1 1 auto;display:flex;flex-wrap:wrap;font-weight:500;font-size:90%;width:100%;padding:6px 8px}::ng-deep .mat-mdc-dialog-container [mat-dialog-content]{position:relative;max-height:calc(100vh - 150px);overflow:auto;scroll-behavior:smooth;display:flex;flex-direction:column;padding:0 6px;outline:none;flex:1}::ng-deep .mat-mdc-dialog-container [mat-dialog-content].mat-dialog-content{margin:0 -12px}\n"], dependencies: [{ kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1.MatDialogTitle, selector: "[mat-dialog-title], [matDialogTitle]", inputs: ["id"], exportAs: ["matDialogTitle"] }, { kind: "directive", type: i3.CdkDrag, selector: "[cdkDrag]", inputs: ["cdkDragData", "cdkDragLockAxis", "cdkDragRootElement", "cdkDragBoundary", "cdkDragStartDelay", "cdkDragFreeDragPosition", "cdkDragDisabled", "cdkDragConstrainPosition", "cdkDragPreviewClass", "cdkDragPreviewContainer"], outputs: ["cdkDragStarted", "cdkDragReleased", "cdkDragEnded", "cdkDragEntered", "cdkDragExited", "cdkDragDropped", "cdkDragMoved"], exportAs: ["cdkDrag"] }, { kind: "directive", type: i3.CdkDragHandle, selector: "[cdkDragHandle]", inputs: ["cdkDragHandleDisabled"] }, { kind: "component", type: i4.ActionIconComponent, selector: "ui-action-icon", inputs: ["size", "color", "disabled", "busy", "matIcon"] }] }); }
|
|
24
|
-
}
|
|
25
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.11", ngImport: i0, type: DialogComponent, decorators: [{
|
|
26
|
-
type: Component,
|
|
27
|
-
args: [{ selector: 'ui-dialog', template: "<ui-action-icon *ngIf=\"title && !hideCloseButton\" (click)=\"clickClose()\" class=\"close-icon\" [matIcon]=\"'close'\" [color]=\"'warn'\"></ui-action-icon>\r\n\r\n<ng-container *ngIf=\"title\">\r\n <h1 class=\"draggable\" cdkDrag cdkDragRootElement=\".cdk-overlay-pane\" cdkDragHandle mat-dialog-title *ngIf=\"draggable\">\r\n {{title}}\r\n </h1>\r\n <h1 mat-dialog-title *ngIf=\"!draggable\">\r\n {{title}}\r\n </h1>\r\n</ng-container>\r\n\r\n<ng-content></ng-content>\r\n", styles: [":host{height:100%;display:flex;flex-direction:column}::ng-deep .mat-mdc-dialog-container{position:relative;overflow:visible!important}::ng-deep .mat-mdc-dialog-container .mdc-dialog__content{line-height:unset!important;letter-spacing:unset!important;color:unset!important}::ng-deep .mat-mdc-dialog-container .mat-mdc-dialog-title{font-size:24px;margin:0 0 5px;padding:12px 16px;border-bottom:1px solid transparent}::ng-deep .mat-mdc-dialog-container .mat-mdc-dialog-title.draggable{cursor:move}::ng-deep .mat-mdc-dialog-container h1{display:flex;align-items:center}::ng-deep .mat-mdc-dialog-container .close-icon{position:absolute;right:16px;top:16px;z-index:1}::ng-deep .mat-mdc-dialog-container .mat-mdc-dialog-actions{display:flex;flex-direction:column;border-top:1px solid transparent;margin-top:5px;padding:0}::ng-deep .mat-mdc-dialog-container .mat-mdc-dialog-actions.mat-dialog-actions{margin:0 -12px -16px}::ng-deep .mat-mdc-dialog-container .mat-mdc-dialog-actions .buttons{display:flex;flex:1 1 auto;justify-content:flex-end;align-items:center;width:100%;padding:8px}::ng-deep .mat-mdc-dialog-container .mat-mdc-dialog-actions .message{flex:1 1 auto;display:flex;flex-wrap:wrap;font-weight:500;font-size:90%;width:100%;padding:6px 8px}::ng-deep .mat-mdc-dialog-container [mat-dialog-content]{position:relative;max-height:calc(100vh - 150px);overflow:auto;scroll-behavior:smooth;display:flex;flex-direction:column;padding:0 6px;outline:none;flex:1}::ng-deep .mat-mdc-dialog-container [mat-dialog-content].mat-dialog-content{margin:0 -12px}\n"] }]
|
|
28
|
-
}], ctorParameters: function () { return [{ type: i1.MatDialogRef }]; }, propDecorators: { title: [{
|
|
29
|
-
type: Input
|
|
30
|
-
}], draggable: [{
|
|
31
|
-
type: Input
|
|
32
|
-
}], hideCloseButton: [{
|
|
33
|
-
type: Input
|
|
34
|
-
}], close: [{
|
|
35
|
-
type: Input
|
|
36
|
-
}] } });
|
|
1
|
+
import { Component, Input } from '@angular/core';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
3
|
+
import * as i1 from "@angular/material/dialog";
|
|
4
|
+
import * as i2 from "@angular/common";
|
|
5
|
+
import * as i3 from "@angular/cdk/drag-drop";
|
|
6
|
+
import * as i4 from "../action-icon/action-icon.component";
|
|
7
|
+
export class DialogComponent {
|
|
8
|
+
constructor(dialogRef) {
|
|
9
|
+
this.dialogRef = dialogRef;
|
|
10
|
+
this.title = '';
|
|
11
|
+
this.draggable = false; // true;
|
|
12
|
+
this.hideCloseButton = false;
|
|
13
|
+
}
|
|
14
|
+
clickClose() {
|
|
15
|
+
if (!this.close) {
|
|
16
|
+
this.dialogRef.close();
|
|
17
|
+
}
|
|
18
|
+
else {
|
|
19
|
+
this.close();
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.11", ngImport: i0, type: DialogComponent, deps: [{ token: i1.MatDialogRef }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
23
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.11", type: DialogComponent, selector: "ui-dialog", inputs: { title: "title", draggable: "draggable", hideCloseButton: "hideCloseButton", close: "close" }, ngImport: i0, template: "<ui-action-icon *ngIf=\"title && !hideCloseButton\" (click)=\"clickClose()\" class=\"close-icon\" [matIcon]=\"'close'\" [color]=\"'warn'\"></ui-action-icon>\r\n\r\n<ng-container *ngIf=\"title\">\r\n <h1 class=\"draggable\" cdkDrag cdkDragRootElement=\".cdk-overlay-pane\" cdkDragHandle mat-dialog-title *ngIf=\"draggable\">\r\n {{title}}\r\n </h1>\r\n <h1 mat-dialog-title *ngIf=\"!draggable\">\r\n {{title}}\r\n </h1>\r\n</ng-container>\r\n\r\n<ng-content></ng-content>\r\n", styles: [":host{height:100%;display:flex;flex-direction:column}::ng-deep .mat-mdc-dialog-container{position:relative;overflow:visible!important}::ng-deep .mat-mdc-dialog-container .mdc-dialog__content{line-height:unset!important;letter-spacing:unset!important;color:unset!important}::ng-deep .mat-mdc-dialog-container .mat-mdc-dialog-title{font-size:24px;margin:0 0 5px;padding:12px 16px;border-bottom:1px solid transparent}::ng-deep .mat-mdc-dialog-container .mat-mdc-dialog-title.draggable{cursor:move}::ng-deep .mat-mdc-dialog-container h1{display:flex;align-items:center}::ng-deep .mat-mdc-dialog-container .close-icon{position:absolute;right:16px;top:16px;z-index:1}::ng-deep .mat-mdc-dialog-container .mat-mdc-dialog-actions{display:flex;flex-direction:column;border-top:1px solid transparent;margin-top:5px;padding:0}::ng-deep .mat-mdc-dialog-container .mat-mdc-dialog-actions.mat-dialog-actions{margin:0 -12px -16px}::ng-deep .mat-mdc-dialog-container .mat-mdc-dialog-actions .buttons{display:flex;flex:1 1 auto;justify-content:flex-end;align-items:center;width:100%;padding:8px}::ng-deep .mat-mdc-dialog-container .mat-mdc-dialog-actions .message{flex:1 1 auto;display:flex;flex-wrap:wrap;font-weight:500;font-size:90%;width:100%;padding:6px 8px}::ng-deep .mat-mdc-dialog-container [mat-dialog-content]{position:relative;max-height:calc(100vh - 150px);overflow:auto;scroll-behavior:smooth;display:flex;flex-direction:column;padding:0 6px;outline:none;flex:1}::ng-deep .mat-mdc-dialog-container [mat-dialog-content].mat-dialog-content{margin:0 -12px}\n"], dependencies: [{ kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1.MatDialogTitle, selector: "[mat-dialog-title], [matDialogTitle]", inputs: ["id"], exportAs: ["matDialogTitle"] }, { kind: "directive", type: i3.CdkDrag, selector: "[cdkDrag]", inputs: ["cdkDragData", "cdkDragLockAxis", "cdkDragRootElement", "cdkDragBoundary", "cdkDragStartDelay", "cdkDragFreeDragPosition", "cdkDragDisabled", "cdkDragConstrainPosition", "cdkDragPreviewClass", "cdkDragPreviewContainer"], outputs: ["cdkDragStarted", "cdkDragReleased", "cdkDragEnded", "cdkDragEntered", "cdkDragExited", "cdkDragDropped", "cdkDragMoved"], exportAs: ["cdkDrag"] }, { kind: "directive", type: i3.CdkDragHandle, selector: "[cdkDragHandle]", inputs: ["cdkDragHandleDisabled"] }, { kind: "component", type: i4.ActionIconComponent, selector: "ui-action-icon", inputs: ["size", "color", "disabled", "busy", "matIcon"] }] }); }
|
|
24
|
+
}
|
|
25
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.11", ngImport: i0, type: DialogComponent, decorators: [{
|
|
26
|
+
type: Component,
|
|
27
|
+
args: [{ selector: 'ui-dialog', template: "<ui-action-icon *ngIf=\"title && !hideCloseButton\" (click)=\"clickClose()\" class=\"close-icon\" [matIcon]=\"'close'\" [color]=\"'warn'\"></ui-action-icon>\r\n\r\n<ng-container *ngIf=\"title\">\r\n <h1 class=\"draggable\" cdkDrag cdkDragRootElement=\".cdk-overlay-pane\" cdkDragHandle mat-dialog-title *ngIf=\"draggable\">\r\n {{title}}\r\n </h1>\r\n <h1 mat-dialog-title *ngIf=\"!draggable\">\r\n {{title}}\r\n </h1>\r\n</ng-container>\r\n\r\n<ng-content></ng-content>\r\n", styles: [":host{height:100%;display:flex;flex-direction:column}::ng-deep .mat-mdc-dialog-container{position:relative;overflow:visible!important}::ng-deep .mat-mdc-dialog-container .mdc-dialog__content{line-height:unset!important;letter-spacing:unset!important;color:unset!important}::ng-deep .mat-mdc-dialog-container .mat-mdc-dialog-title{font-size:24px;margin:0 0 5px;padding:12px 16px;border-bottom:1px solid transparent}::ng-deep .mat-mdc-dialog-container .mat-mdc-dialog-title.draggable{cursor:move}::ng-deep .mat-mdc-dialog-container h1{display:flex;align-items:center}::ng-deep .mat-mdc-dialog-container .close-icon{position:absolute;right:16px;top:16px;z-index:1}::ng-deep .mat-mdc-dialog-container .mat-mdc-dialog-actions{display:flex;flex-direction:column;border-top:1px solid transparent;margin-top:5px;padding:0}::ng-deep .mat-mdc-dialog-container .mat-mdc-dialog-actions.mat-dialog-actions{margin:0 -12px -16px}::ng-deep .mat-mdc-dialog-container .mat-mdc-dialog-actions .buttons{display:flex;flex:1 1 auto;justify-content:flex-end;align-items:center;width:100%;padding:8px}::ng-deep .mat-mdc-dialog-container .mat-mdc-dialog-actions .message{flex:1 1 auto;display:flex;flex-wrap:wrap;font-weight:500;font-size:90%;width:100%;padding:6px 8px}::ng-deep .mat-mdc-dialog-container [mat-dialog-content]{position:relative;max-height:calc(100vh - 150px);overflow:auto;scroll-behavior:smooth;display:flex;flex-direction:column;padding:0 6px;outline:none;flex:1}::ng-deep .mat-mdc-dialog-container [mat-dialog-content].mat-dialog-content{margin:0 -12px}\n"] }]
|
|
28
|
+
}], ctorParameters: function () { return [{ type: i1.MatDialogRef }]; }, propDecorators: { title: [{
|
|
29
|
+
type: Input
|
|
30
|
+
}], draggable: [{
|
|
31
|
+
type: Input
|
|
32
|
+
}], hideCloseButton: [{
|
|
33
|
+
type: Input
|
|
34
|
+
}], close: [{
|
|
35
|
+
type: Input
|
|
36
|
+
}] } });
|
|
37
37
|
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZGlhbG9nLmNvbXBvbmVudC5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uL3Byb2plY3RzL3VpL3NyYy9saWIvZGlhbG9nL2RpYWxvZy5jb21wb25lbnQudHMiLCIuLi8uLi8uLi8uLi8uLi9wcm9qZWN0cy91aS9zcmMvbGliL2RpYWxvZy9kaWFsb2cuY29tcG9uZW50Lmh0bWwiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQ0EsT0FBTyxFQUFDLFNBQVMsRUFBRSxLQUFLLEVBQUMsTUFBTSxlQUFlLENBQUM7Ozs7OztBQU8vQyxNQUFNLE9BQU8sZUFBZTtJQVExQixZQUFtQixTQUF3QztRQUF4QyxjQUFTLEdBQVQsU0FBUyxDQUErQjtRQU5sRCxVQUFLLEdBQUcsRUFBRSxDQUFDO1FBQ1gsY0FBUyxHQUFHLEtBQUssQ0FBQyxDQUFDLFFBQVE7UUFDM0Isb0JBQWUsR0FBRyxLQUFLLENBQUM7SUFLakMsQ0FBQztJQUVELFVBQVU7UUFDUixJQUFJLENBQUMsSUFBSSxDQUFDLEtBQUssRUFBRTtZQUNmLElBQUksQ0FBQyxTQUFTLENBQUMsS0FBSy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vaWQge1xyXG4gICAgaWYgKCF0aGlzLmNsb3NlKSB7XHJcbiAgICAgIHRoaXMuZGlhbG9nUmVmLmNsb3NlKCk7XHJcbiAgICB9IGVsc2Uge1xyXG4gICAgICB0aGlzLmNsb3NlKCk7XHJcbiAgICB9XHJcbiAgfVxyXG5cclxufVxyXG4iLCI8dWktYWN0aW9uLWljb24gKm5nSWY9XCJ0aXRsZSAmJiAhaGlkZUNsb3NlQnV0dG9uXCIgKGNsaWNrKT1cImNsaWNrQ2xvc2UoKVwiIGNsYXNzPVwiY2xvc2UtaWNvblwiIFttYXRJY29uXT1cIidjbG9zZSdcIiBbY29sb3JdPVwiJ3dhcm4nXCI+PC91aS1hY3Rpb24taWNvbj5cclxuXHJcbjxuZy1jb250YWluZXIgKm5nSWY9XCJ0aXRsZVwiPlxyXG4gIDxoMSBjbGFzcz1cImRyYWdnYWJsZVwiIGNka0RyYWcgY2RrRHJhZ1Jvb3RFbGVtZW50PVwiLmNkay1vdmVybGF5LXBhbmVcIiBjZGtEcmFnSGFuZGxlIG1hdC1kaWFsb2ctdGl0bGUgKm5nSWY9XCJkcmFnZ2FibGVcIj5cclxuICAgIHt7dGl0bGV9fVxyXG4gIDwvaDE+XHJcbiAgPGgxIG1hdC1kaWFsb2ctdGl0bGUgKm5nSWY9XCIhZHJhZ2dhYmxlXCI+XHJcbiAgICB7e3RpdGxlfX1cclxuICA8L2gxPlxyXG48L25nLWNvbnRhaW5lcj5cclxuXHJcbjxuZy1jb250ZW50PjwvbmctY29udGVudD5cclxuIl19
|
|
@@ -1,104 +1,104 @@
|
|
|
1
|
-
import { Directive, EventEmitter, Input, Output } from '@angular/core';
|
|
2
|
-
import * as i0 from "@angular/core";
|
|
3
|
-
export class ForceVisibilityDirective {
|
|
4
|
-
static { this.disabled = false; }
|
|
5
|
-
constructor(el) {
|
|
6
|
-
this.el = el;
|
|
7
|
-
this.visibilityPadding = 15;
|
|
8
|
-
this.visibilityOnRequestOnly = false;
|
|
9
|
-
this.visibilityEmitChange = false;
|
|
10
|
-
this.visibilityFromTop = 0;
|
|
11
|
-
this.visibilityCheckEnabled = true;
|
|
12
|
-
this.visibilityChanged = new EventEmitter();
|
|
13
|
-
}
|
|
14
|
-
static disableFor(timeoutMs) {
|
|
15
|
-
this.disabled = true;
|
|
16
|
-
setTimeout(() => this.disabled = false, timeoutMs);
|
|
17
|
-
}
|
|
18
|
-
ngOnInit() {
|
|
19
|
-
if (!this.visibilityOnRequestOnly && !this.visibilityEmitChange) {
|
|
20
|
-
setTimeout(() => {
|
|
21
|
-
this.forceVisibility();
|
|
22
|
-
}, 125);
|
|
23
|
-
}
|
|
24
|
-
if (this.visibilityEmitChange) {
|
|
25
|
-
if (!this.visibilityWithin) {
|
|
26
|
-
throw Error('traceVisibilityChanged requires visibilityWithin');
|
|
27
|
-
}
|
|
28
|
-
else {
|
|
29
|
-
this.visible = this.isVisible();
|
|
30
|
-
this.visibilityWithin.onscroll = () => {
|
|
31
|
-
const v = this.isVisible();
|
|
32
|
-
if (v !== this.visible) {
|
|
33
|
-
this.visible = v;
|
|
34
|
-
this.visibilityChanged.emit(v);
|
|
35
|
-
}
|
|
36
|
-
};
|
|
37
|
-
}
|
|
38
|
-
}
|
|
39
|
-
}
|
|
40
|
-
ngOnChanges(changes) {
|
|
41
|
-
if (changes.visibilityCheckEnabled && changes.visibilityCheckEnabled.currentValue !== changes.visibilityCheckEnabled.previousValue) {
|
|
42
|
-
this.forceVisibility();
|
|
43
|
-
}
|
|
44
|
-
}
|
|
45
|
-
isVisible() {
|
|
46
|
-
const rect = this.el.nativeElement.getBoundingClientRect();
|
|
47
|
-
const rectIn = this.visibilityWithin.getBoundingClientRect();
|
|
48
|
-
return rect.top + +this.visibilityPadding - rectIn.bottom < 0;
|
|
49
|
-
}
|
|
50
|
-
forceVisibility() {
|
|
51
|
-
if (ForceVisibilityDirective.disabled || !this.visibilityCheckEnabled) {
|
|
52
|
-
return;
|
|
53
|
-
}
|
|
54
|
-
const rect = this.el.nativeElement.getBoundingClientRect();
|
|
55
|
-
const padding = +this.visibilityPadding;
|
|
56
|
-
if (this.visibilityWithin) {
|
|
57
|
-
const rectIn = this.visibilityWithin.getBoundingClientRect();
|
|
58
|
-
let diff = rect.top + rect.height + padding - rectIn.bottom;
|
|
59
|
-
if (diff > 0) {
|
|
60
|
-
this.visibilityWithin.scrollBy(0, diff);
|
|
61
|
-
}
|
|
62
|
-
else {
|
|
63
|
-
diff = rect.top - rectIn.top - padding;
|
|
64
|
-
if (diff < 0) {
|
|
65
|
-
this.visibilityWithin.scrollBy(0, diff);
|
|
66
|
-
}
|
|
67
|
-
}
|
|
68
|
-
}
|
|
69
|
-
else {
|
|
70
|
-
if (this.visibilityFromTop !== 0) {
|
|
71
|
-
document.getElementsByTagName('app-root')[0].scrollTo(0, rect.top - +this.visibilityFromTop);
|
|
72
|
-
}
|
|
73
|
-
else {
|
|
74
|
-
if (rect.bottom > window.innerHeight) {
|
|
75
|
-
document.getElementsByTagName('app-root')[0].scrollBy(0, rect.bottom - window.innerHeight + 15);
|
|
76
|
-
}
|
|
77
|
-
}
|
|
78
|
-
}
|
|
79
|
-
}
|
|
80
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.11", ngImport: i0, type: ForceVisibilityDirective, deps: [{ token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
81
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.2.11", type: ForceVisibilityDirective, selector: "[uiForceVisibility]", inputs: { visibilityWithin: "visibilityWithin", visibilityPadding: "visibilityPadding", visibilityOnRequestOnly: "visibilityOnRequestOnly", visibilityEmitChange: "visibilityEmitChange", visibilityFromTop: "visibilityFromTop", visibilityCheckEnabled: "visibilityCheckEnabled" }, outputs: { visibilityChanged: "visibilityChanged" }, exportAs: ["ForceVisibilityDirective"], usesOnChanges: true, ngImport: i0 }); }
|
|
82
|
-
}
|
|
83
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.11", ngImport: i0, type: ForceVisibilityDirective, decorators: [{
|
|
84
|
-
type: Directive,
|
|
85
|
-
args: [{
|
|
86
|
-
selector: '[uiForceVisibility]',
|
|
87
|
-
exportAs: 'ForceVisibilityDirective'
|
|
88
|
-
}]
|
|
89
|
-
}], ctorParameters: function () { return [{ type: i0.ElementRef }]; }, propDecorators: { visibilityWithin: [{
|
|
90
|
-
type: Input
|
|
91
|
-
}], visibilityPadding: [{
|
|
92
|
-
type: Input
|
|
93
|
-
}], visibilityOnRequestOnly: [{
|
|
94
|
-
type: Input
|
|
95
|
-
}], visibilityEmitChange: [{
|
|
96
|
-
type: Input
|
|
97
|
-
}], visibilityFromTop: [{
|
|
98
|
-
type: Input
|
|
99
|
-
}], visibilityCheckEnabled: [{
|
|
100
|
-
type: Input
|
|
101
|
-
}], visibilityChanged: [{
|
|
102
|
-
type: Output
|
|
103
|
-
}] } });
|
|
104
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
1
|
+
import { Directive, EventEmitter, Input, Output } from '@angular/core';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
3
|
+
export class ForceVisibilityDirective {
|
|
4
|
+
static { this.disabled = false; }
|
|
5
|
+
constructor(el) {
|
|
6
|
+
this.el = el;
|
|
7
|
+
this.visibilityPadding = 15;
|
|
8
|
+
this.visibilityOnRequestOnly = false;
|
|
9
|
+
this.visibilityEmitChange = false;
|
|
10
|
+
this.visibilityFromTop = 0;
|
|
11
|
+
this.visibilityCheckEnabled = true;
|
|
12
|
+
this.visibilityChanged = new EventEmitter();
|
|
13
|
+
}
|
|
14
|
+
static disableFor(timeoutMs) {
|
|
15
|
+
this.disabled = true;
|
|
16
|
+
setTimeout(() => this.disabled = false, timeoutMs);
|
|
17
|
+
}
|
|
18
|
+
ngOnInit() {
|
|
19
|
+
if (!this.visibilityOnRequestOnly && !this.visibilityEmitChange) {
|
|
20
|
+
setTimeout(() => {
|
|
21
|
+
this.forceVisibility();
|
|
22
|
+
}, 125);
|
|
23
|
+
}
|
|
24
|
+
if (this.visibilityEmitChange) {
|
|
25
|
+
if (!this.visibilityWithin) {
|
|
26
|
+
throw Error('traceVisibilityChanged requires visibilityWithin');
|
|
27
|
+
}
|
|
28
|
+
else {
|
|
29
|
+
this.visible = this.isVisible();
|
|
30
|
+
this.visibilityWithin.onscroll = () => {
|
|
31
|
+
const v = this.isVisible();
|
|
32
|
+
if (v !== this.visible) {
|
|
33
|
+
this.visible = v;
|
|
34
|
+
this.visibilityChanged.emit(v);
|
|
35
|
+
}
|
|
36
|
+
};
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
ngOnChanges(changes) {
|
|
41
|
+
if (changes.visibilityCheckEnabled && changes.visibilityCheckEnabled.currentValue !== changes.visibilityCheckEnabled.previousValue) {
|
|
42
|
+
this.forceVisibility();
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
isVisible() {
|
|
46
|
+
const rect = this.el.nativeElement.getBoundingClientRect();
|
|
47
|
+
const rectIn = this.visibilityWithin.getBoundingClientRect();
|
|
48
|
+
return rect.top + +this.visibilityPadding - rectIn.bottom < 0;
|
|
49
|
+
}
|
|
50
|
+
forceVisibility() {
|
|
51
|
+
if (ForceVisibilityDirective.disabled || !this.visibilityCheckEnabled) {
|
|
52
|
+
return;
|
|
53
|
+
}
|
|
54
|
+
const rect = this.el.nativeElement.getBoundingClientRect();
|
|
55
|
+
const padding = +this.visibilityPadding;
|
|
56
|
+
if (this.visibilityWithin) {
|
|
57
|
+
const rectIn = this.visibilityWithin.getBoundingClientRect();
|
|
58
|
+
let diff = rect.top + rect.height + padding - rectIn.bottom;
|
|
59
|
+
if (diff > 0) {
|
|
60
|
+
this.visibilityWithin.scrollBy(0, diff);
|
|
61
|
+
}
|
|
62
|
+
else {
|
|
63
|
+
diff = rect.top - rectIn.top - padding;
|
|
64
|
+
if (diff < 0) {
|
|
65
|
+
this.visibilityWithin.scrollBy(0, diff);
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
else {
|
|
70
|
+
if (this.visibilityFromTop !== 0) {
|
|
71
|
+
document.getElementsByTagName('app-root')[0].scrollTo(0, rect.top - +this.visibilityFromTop);
|
|
72
|
+
}
|
|
73
|
+
else {
|
|
74
|
+
if (rect.bottom > window.innerHeight) {
|
|
75
|
+
document.getElementsByTagName('app-root')[0].scrollBy(0, rect.bottom - window.innerHeight + 15);
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.11", ngImport: i0, type: ForceVisibilityDirective, deps: [{ token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
81
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.2.11", type: ForceVisibilityDirective, selector: "[uiForceVisibility]", inputs: { visibilityWithin: "visibilityWithin", visibilityPadding: "visibilityPadding", visibilityOnRequestOnly: "visibilityOnRequestOnly", visibilityEmitChange: "visibilityEmitChange", visibilityFromTop: "visibilityFromTop", visibilityCheckEnabled: "visibilityCheckEnabled" }, outputs: { visibilityChanged: "visibilityChanged" }, exportAs: ["ForceVisibilityDirective"], usesOnChanges: true, ngImport: i0 }); }
|
|
82
|
+
}
|
|
83
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.11", ngImport: i0, type: ForceVisibilityDirective, decorators: [{
|
|
84
|
+
type: Directive,
|
|
85
|
+
args: [{
|
|
86
|
+
selector: '[uiForceVisibility]',
|
|
87
|
+
exportAs: 'ForceVisibilityDirective'
|
|
88
|
+
}]
|
|
89
|
+
}], ctorParameters: function () { return [{ type: i0.ElementRef }]; }, propDecorators: { visibilityWithin: [{
|
|
90
|
+
type: Input
|
|
91
|
+
}], visibilityPadding: [{
|
|
92
|
+
type: Input
|
|
93
|
+
}], visibilityOnRequestOnly: [{
|
|
94
|
+
type: Input
|
|
95
|
+
}], visibilityEmitChange: [{
|
|
96
|
+
type: Input
|
|
97
|
+
}], visibilityFromTop: [{
|
|
98
|
+
type: Input
|
|
99
|
+
}], visibilityCheckEnabled: [{
|
|
100
|
+
type: Input
|
|
101
|
+
}], visibilityChanged: [{
|
|
102
|
+
type: Output
|
|
103
|
+
}] } });
|
|
104
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZm9yY2UtdmlzaWJpbGl0eS5kaXJlY3RpdmUuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi9wcm9qZWN0cy91aS9zcmMvbGliL2RpcmVjdGl2ZXMvZm9yY2UtdmlzaWJpbGl0eS9mb3JjZS12aXNpYmlsaXR5LmRpcmVjdGl2ZS50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxPQUFPLEVBQUUsU0FBUyxFQUFjLFlBQVksRUFBRSxLQUFLLEVBQXFCLE1BQU0sRUFBK0IsTUFBTSxlQUFlLENBQUM7O0FBTW5JLE1BQU0sT0FBTyx3QkFBd0I7YUFFcEIsYUFBUSxHQUFHLEtBQUssQ0FBQztJQWFoQyxZQUFvQixFQUFjO1FBQWQsT0FBRSxHQUFGLEVBQUUsQ0FBWTtRQVZ6QixzQkFBaUIsR0FBRyxFQUFFLENBQUM7UUFDdkIsNEJBQXVCLEdBQUcsS0FBSyxDQUFDO1FBQ2hDLHlCQUFvQixHQUFHLEtBQUssQ0FBQztRQUM3QixzQkFBaUIsR0FBRyxDQUFDLENBQUM7UUFDdEIsMkJBQXNCLEdBQUcsSUFBSSxDQUFDO1FBRTdCLHNCQUFpQixHQUFHLElBQUksWUFBWSxFQUFXLENBQUM7SUFLMUQsQ0FBQztJQUdNLE1BQU0sQ0FBQyxVQUFVLENBQUMsU0FBaUI7UUFDeEMsSUFBSSxDQUFDLFFBQV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