@ng-doc/ui-kit 19.1.0 → 19.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/components/dialog-outlet/dialog-outlet.component.d.ts +2 -1
- package/components/option-group/option-group.component.d.ts +1 -0
- package/components/selection/selection.component.d.ts +1 -0
- package/components/tab-group/tab-group.component.d.ts +1 -0
- package/directives/event-switcher/event-switcher.directive.d.ts +1 -0
- package/directives/tooltip/tooltip.directive.d.ts +1 -0
- package/fesm2022/ng-doc-ui-kit-animations.mjs.map +1 -1
- package/fesm2022/ng-doc-ui-kit-cdk-combobox-host.mjs +4 -9
- package/fesm2022/ng-doc-ui-kit-cdk-combobox-host.mjs.map +1 -1
- package/fesm2022/ng-doc-ui-kit-components-blockquote.mjs +1 -2
- package/fesm2022/ng-doc-ui-kit-components-blockquote.mjs.map +1 -1
- package/fesm2022/ng-doc-ui-kit-components-clear-control.mjs +4 -9
- package/fesm2022/ng-doc-ui-kit-components-clear-control.mjs.map +1 -1
- package/fesm2022/ng-doc-ui-kit-components-dialog-outlet.mjs +15 -18
- package/fesm2022/ng-doc-ui-kit-components-dialog-outlet.mjs.map +1 -1
- package/fesm2022/ng-doc-ui-kit-components-dropdown.mjs +3 -13
- package/fesm2022/ng-doc-ui-kit-components-dropdown.mjs.map +1 -1
- package/fesm2022/ng-doc-ui-kit-components-expander.mjs +3 -3
- package/fesm2022/ng-doc-ui-kit-components-expander.mjs.map +1 -1
- package/fesm2022/ng-doc-ui-kit-components-input-wrapper.mjs +3 -11
- package/fesm2022/ng-doc-ui-kit-components-input-wrapper.mjs.map +1 -1
- package/fesm2022/ng-doc-ui-kit-components-list.mjs +5 -12
- package/fesm2022/ng-doc-ui-kit-components-list.mjs.map +1 -1
- package/fesm2022/ng-doc-ui-kit-components-option-group.mjs +6 -10
- package/fesm2022/ng-doc-ui-kit-components-option-group.mjs.map +1 -1
- package/fesm2022/ng-doc-ui-kit-components-option.mjs.map +1 -1
- package/fesm2022/ng-doc-ui-kit-components-pane.mjs +7 -14
- package/fesm2022/ng-doc-ui-kit-components-pane.mjs.map +1 -1
- package/fesm2022/ng-doc-ui-kit-components-selection.mjs +6 -11
- package/fesm2022/ng-doc-ui-kit-components-selection.mjs.map +1 -1
- package/fesm2022/ng-doc-ui-kit-components-sidenav.mjs +1 -3
- package/fesm2022/ng-doc-ui-kit-components-sidenav.mjs.map +1 -1
- package/fesm2022/ng-doc-ui-kit-components-smooth-resize.mjs.map +1 -1
- package/fesm2022/ng-doc-ui-kit-components-tab-group.mjs +9 -11
- package/fesm2022/ng-doc-ui-kit-components-tab-group.mjs.map +1 -1
- package/fesm2022/ng-doc-ui-kit-components-tab-routes-group.mjs +1 -1
- package/fesm2022/ng-doc-ui-kit-components-tab-routes-group.mjs.map +1 -1
- package/fesm2022/ng-doc-ui-kit-components-text.mjs.map +1 -1
- package/fesm2022/ng-doc-ui-kit-components-toggle.mjs +4 -9
- package/fesm2022/ng-doc-ui-kit-components-toggle.mjs.map +1 -1
- package/fesm2022/ng-doc-ui-kit-directives-checked-change.mjs.map +1 -1
- package/fesm2022/ng-doc-ui-kit-directives-event-switcher.mjs +6 -10
- package/fesm2022/ng-doc-ui-kit-directives-event-switcher.mjs.map +1 -1
- package/fesm2022/ng-doc-ui-kit-directives-focus-catcher.mjs +6 -15
- package/fesm2022/ng-doc-ui-kit-directives-focus-catcher.mjs.map +1 -1
- package/fesm2022/ng-doc-ui-kit-directives-hotkey.mjs +6 -10
- package/fesm2022/ng-doc-ui-kit-directives-hotkey.mjs.map +1 -1
- package/fesm2022/ng-doc-ui-kit-directives-input-number.mjs +2 -8
- package/fesm2022/ng-doc-ui-kit-directives-input-number.mjs.map +1 -1
- package/fesm2022/ng-doc-ui-kit-directives-input-string.mjs +2 -8
- package/fesm2022/ng-doc-ui-kit-directives-input-string.mjs.map +1 -1
- package/fesm2022/ng-doc-ui-kit-directives-tooltip.mjs +7 -18
- package/fesm2022/ng-doc-ui-kit-directives-tooltip.mjs.map +1 -1
- package/fesm2022/ng-doc-ui-kit-helpers.mjs.map +1 -1
- package/fesm2022/ng-doc-ui-kit-interceptors.mjs.map +1 -1
- package/fesm2022/ng-doc-ui-kit-observables.mjs.map +1 -1
- package/fesm2022/ng-doc-ui-kit-services-notify.mjs +4 -10
- package/fesm2022/ng-doc-ui-kit-services-notify.mjs.map +1 -1
- package/fesm2022/ng-doc-ui-kit-types.mjs.map +1 -1
- package/fesm2022/ng-doc-ui-kit-utils.mjs.map +1 -1
- package/package.json +30 -31
|
@@ -1,19 +1,17 @@
|
|
|
1
1
|
import { __decorate, __metadata } from 'tslib';
|
|
2
2
|
import { NgIf } from '@angular/common';
|
|
3
3
|
import * as i0 from '@angular/core';
|
|
4
|
-
import {
|
|
4
|
+
import { Component, ChangeDetectionStrategy, Input, HostBinding, ContentChild, ViewChild } from '@angular/core';
|
|
5
5
|
import { NgDocBaseInput } from '@ng-doc/ui-kit/classes/base-input';
|
|
6
6
|
import { NgDocInputHost } from '@ng-doc/ui-kit/classes/input-host';
|
|
7
7
|
import { NgDocFloatedBorderComponent } from '@ng-doc/ui-kit/components/floated-border';
|
|
8
|
-
import { NgDocFloatedContentComponent } from '@ng-doc/ui-kit/components/floated-content';
|
|
9
8
|
import { NgDocWrapperComponent } from '@ng-doc/ui-kit/components/wrapper';
|
|
10
9
|
import { ngDocMakePure } from '@ng-doc/ui-kit/decorators';
|
|
11
10
|
import { NgDocFocusCatcherDirective } from '@ng-doc/ui-kit/directives/focus-catcher';
|
|
12
|
-
import { UntilDestroy } from '@ngneat/until-destroy';
|
|
13
11
|
import * as i1 from '@tinkoff/ng-polymorpheus';
|
|
14
12
|
import { PolymorpheusModule } from '@tinkoff/ng-polymorpheus';
|
|
15
13
|
|
|
16
|
-
|
|
14
|
+
class NgDocInputWrapperComponent {
|
|
17
15
|
constructor(elementRef, changeDetectorRef) {
|
|
18
16
|
this.elementRef = elementRef;
|
|
19
17
|
this.changeDetectorRef = changeDetectorRef;
|
|
@@ -45,18 +43,13 @@ let NgDocInputWrapperComponent = class NgDocInputWrapperComponent {
|
|
|
45
43
|
useExisting: NgDocInputWrapperComponent,
|
|
46
44
|
},
|
|
47
45
|
], queries: [{ propertyName: "input", first: true, predicate: NgDocBaseInput, descendants: true }, { propertyName: "inputControl", first: true, predicate: NgDocBaseInput, descendants: true }], viewQueries: [{ propertyName: "focusCatcher", first: true, predicate: NgDocFocusCatcherDirective, descendants: true, static: true }], ngImport: i0, template: "<ng-doc-wrapper ngDocFocusCatcher>\n <ng-doc-floated-border>\n <label\n class=\"ng-doc-input-container\"\n (focusin)=\"emptyEvent()\"\n (focusout)=\"emptyEvent()\"\n [class.-input-hidden]=\"blurContentIsVisible\">\n <ng-content select=\"[ngDocInputWrapperLeft]\"></ng-content>\n <div class=\"ng-doc-original-input\">\n <ng-content></ng-content>\n <div class=\"ng-doc-blur-container ng-doc-input\" *ngIf=\"blurContentIsVisible\">\n <div class=\"ng-doc-blur-content\">\n <ng-container\n *polymorpheusOutlet=\"blurContent as text; context: getBlurContext(blurContext)\">\n {{ text }}\n </ng-container>\n </div>\n </div>\n </div>\n <ng-content select=\"[ngDocInputWrapperRight]\"></ng-content>\n </label>\n </ng-doc-floated-border>\n</ng-doc-wrapper>\n", styles: [":host{position:relative;display:block;width:var(--ng-doc-input-width);height:var(--ng-doc-input-height);--ng-doc-icon-width: 40px;--ng-doc-icon-height: var(--ng-doc-input-height)}:host:hover:not([data-ng-doc-input-disabled=true]){--ng-doc-input-border: var(--ng-doc-input-border-hover)}:host:not([data-ng-doc-input-disabled=true]) ::ng-deep .ng-doc-input:read-only{--ng-doc-input-cursor: pointer}:host[data-ng-doc-align=left]{--ng-doc-input-text-align: left}:host[data-ng-doc-align=center]{--ng-doc-input-text-align: center}:host[data-ng-doc-align=right]{--ng-doc-input-text-align: right}:host .ng-doc-input-container{font-family:var(--ng-doc-font-family);font-variant:no-contextual;color:var(--ng-doc-text);line-height:var(--ng-doc-line-height);font-size:var(--ng-doc-font-size);font-weight:var(--ng-doc-font-weight);position:relative;display:flex;align-items:center;box-sizing:border-box;width:var(--ng-doc-input-width);height:var(--ng-doc-input-height);background-color:var(--ng-doc-input-background-color);border-radius:var(--ng-doc-floated-border-radius);--ng-doc-line-height: 22px}:host .ng-doc-input-container:after{position:absolute;content:\"\";left:0;top:0;z-index:2;width:100%;height:100%;border:var(--ng-doc-input-border);border-radius:var(--ng-doc-floated-border-radius);pointer-events:none}:host .ng-doc-input-container.-input-hidden ::ng-deep input{opacity:0}:host .ng-doc-input-container .ng-doc-original-input{width:100%;padding:var(--ng-doc-base-gutter) var(--ng-doc-input-padding-right) var(--ng-doc-base-gutter) var(--ng-doc-input-padding-left)}:host .ng-doc-input-container .ng-doc-original-input:first-child{padding-left:var(--ng-doc-input-padding-left, calc(var(--ng-doc-base-gutter) * 2))}:host .ng-doc-input-container .ng-doc-original-input:last-child{padding-right:var(--ng-doc-input-padding-right, calc(var(--ng-doc-base-gutter) * 2))}:host .ng-doc-input-container .ng-doc-input,:host .ng-doc-input-container ::ng-deep .ng-doc-input{width:100%;height:100%;overflow:hidden;box-sizing:border-box;outline:none;text-align:var(--ng-doc-input-text-align);border:0;border-radius:var(--ng-doc-floated-border-radius);background-color:transparent;cursor:var(--ng-doc-input-cursor);color:var(--ng-doc-input-color, var(--ng-doc-text));font-family:var(--ng-doc-input-font-family, var(--ng-doc-font-family));font-size:var(--ng-doc-input-font-size, var(--ng-doc-font-size));font-weight:var(--ng-doc-input-font-weight, var(--ng-doc-font-weight))}:host .ng-doc-input-container .ng-doc-input::placeholder,:host .ng-doc-input-container ::ng-deep .ng-doc-input::placeholder{color:var(--ng-doc-text-muted)}:host .ng-doc-input-container .ng-doc-input.-blink,:host .ng-doc-input-container ::ng-deep .ng-doc-input.-blink{animation:blink-animation .3s}@keyframes blink-animation{0%{background-color:rgba(var(--ng-doc-primary-rgb),.1)}to{background-color:initial}}:host .ng-doc-input-container .ng-doc-input[type=number]::-webkit-inner-spin-button,:host .ng-doc-input-container .ng-doc-input[type=number]::-webkit-outer-spin-button,:host .ng-doc-input-container ::ng-deep .ng-doc-input[type=number]::-webkit-inner-spin-button,:host .ng-doc-input-container ::ng-deep .ng-doc-input[type=number]::-webkit-outer-spin-button{-webkit-appearance:none;-moz-appearance:none;appearance:none}:host .ng-doc-content{--ng-doc-icon-width: 40px;--ng-doc-icon-height: 40px}ng-doc-floated-border{width:var(--ng-doc-input-width);height:var(--ng-doc-input-height)}.ng-doc-button-content{display:flex}.ng-doc-blur-container{position:absolute;left:0;top:0;display:flex;align-items:center;pointer-events:none}.ng-doc-blur-container .ng-doc-blur-content{width:100%;white-space:nowrap;overflow:hidden;padding-left:var(--ng-doc-input-padding-left, calc(var(--ng-doc-base-gutter) * 2));padding-right:var(--ng-doc-input-padding-right, calc(var(--ng-doc-base-gutter) * 2))}\n"], dependencies: [{ kind: "component", type: NgDocWrapperComponent, selector: "ng-doc-wrapper" }, { kind: "directive", type: NgDocFocusCatcherDirective, selector: "[ngDocFocusCatcher]", outputs: ["focusEvent", "blurEvent"], exportAs: ["ngDocFocusCatcher"] }, { kind: "component", type: NgDocFloatedBorderComponent, selector: "ng-doc-floated-border" }, { kind: "directive", type: NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "ngmodule", type: PolymorpheusModule }, { kind: "directive", type: i1.PolymorpheusOutletDirective, selector: "[polymorpheusOutlet]", inputs: ["polymorpheusOutlet", "polymorpheusOutletContext"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
48
|
-
}
|
|
46
|
+
}
|
|
49
47
|
__decorate([
|
|
50
48
|
ngDocMakePure,
|
|
51
49
|
__metadata("design:type", Function),
|
|
52
50
|
__metadata("design:paramtypes", [Object]),
|
|
53
51
|
__metadata("design:returntype", Object)
|
|
54
52
|
], NgDocInputWrapperComponent.prototype, "getBlurContext", null);
|
|
55
|
-
NgDocInputWrapperComponent = __decorate([
|
|
56
|
-
UntilDestroy(),
|
|
57
|
-
__metadata("design:paramtypes", [ElementRef,
|
|
58
|
-
ChangeDetectorRef])
|
|
59
|
-
], NgDocInputWrapperComponent);
|
|
60
53
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.3", ngImport: i0, type: NgDocInputWrapperComponent, decorators: [{
|
|
61
54
|
type: Component,
|
|
62
55
|
args: [{ selector: 'ng-doc-input-wrapper', providers: [
|
|
@@ -70,7 +63,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.3", ngImpor
|
|
|
70
63
|
NgDocFloatedBorderComponent,
|
|
71
64
|
NgIf,
|
|
72
65
|
PolymorpheusModule,
|
|
73
|
-
NgDocFloatedContentComponent,
|
|
74
66
|
], template: "<ng-doc-wrapper ngDocFocusCatcher>\n <ng-doc-floated-border>\n <label\n class=\"ng-doc-input-container\"\n (focusin)=\"emptyEvent()\"\n (focusout)=\"emptyEvent()\"\n [class.-input-hidden]=\"blurContentIsVisible\">\n <ng-content select=\"[ngDocInputWrapperLeft]\"></ng-content>\n <div class=\"ng-doc-original-input\">\n <ng-content></ng-content>\n <div class=\"ng-doc-blur-container ng-doc-input\" *ngIf=\"blurContentIsVisible\">\n <div class=\"ng-doc-blur-content\">\n <ng-container\n *polymorpheusOutlet=\"blurContent as text; context: getBlurContext(blurContext)\">\n {{ text }}\n </ng-container>\n </div>\n </div>\n </div>\n <ng-content select=\"[ngDocInputWrapperRight]\"></ng-content>\n </label>\n </ng-doc-floated-border>\n</ng-doc-wrapper>\n", styles: [":host{position:relative;display:block;width:var(--ng-doc-input-width);height:var(--ng-doc-input-height);--ng-doc-icon-width: 40px;--ng-doc-icon-height: var(--ng-doc-input-height)}:host:hover:not([data-ng-doc-input-disabled=true]){--ng-doc-input-border: var(--ng-doc-input-border-hover)}:host:not([data-ng-doc-input-disabled=true]) ::ng-deep .ng-doc-input:read-only{--ng-doc-input-cursor: pointer}:host[data-ng-doc-align=left]{--ng-doc-input-text-align: left}:host[data-ng-doc-align=center]{--ng-doc-input-text-align: center}:host[data-ng-doc-align=right]{--ng-doc-input-text-align: right}:host .ng-doc-input-container{font-family:var(--ng-doc-font-family);font-variant:no-contextual;color:var(--ng-doc-text);line-height:var(--ng-doc-line-height);font-size:var(--ng-doc-font-size);font-weight:var(--ng-doc-font-weight);position:relative;display:flex;align-items:center;box-sizing:border-box;width:var(--ng-doc-input-width);height:var(--ng-doc-input-height);background-color:var(--ng-doc-input-background-color);border-radius:var(--ng-doc-floated-border-radius);--ng-doc-line-height: 22px}:host .ng-doc-input-container:after{position:absolute;content:\"\";left:0;top:0;z-index:2;width:100%;height:100%;border:var(--ng-doc-input-border);border-radius:var(--ng-doc-floated-border-radius);pointer-events:none}:host .ng-doc-input-container.-input-hidden ::ng-deep input{opacity:0}:host .ng-doc-input-container .ng-doc-original-input{width:100%;padding:var(--ng-doc-base-gutter) var(--ng-doc-input-padding-right) var(--ng-doc-base-gutter) var(--ng-doc-input-padding-left)}:host .ng-doc-input-container .ng-doc-original-input:first-child{padding-left:var(--ng-doc-input-padding-left, calc(var(--ng-doc-base-gutter) * 2))}:host .ng-doc-input-container .ng-doc-original-input:last-child{padding-right:var(--ng-doc-input-padding-right, calc(var(--ng-doc-base-gutter) * 2))}:host .ng-doc-input-container .ng-doc-input,:host .ng-doc-input-container ::ng-deep .ng-doc-input{width:100%;height:100%;overflow:hidden;box-sizing:border-box;outline:none;text-align:var(--ng-doc-input-text-align);border:0;border-radius:var(--ng-doc-floated-border-radius);background-color:transparent;cursor:var(--ng-doc-input-cursor);color:var(--ng-doc-input-color, var(--ng-doc-text));font-family:var(--ng-doc-input-font-family, var(--ng-doc-font-family));font-size:var(--ng-doc-input-font-size, var(--ng-doc-font-size));font-weight:var(--ng-doc-input-font-weight, var(--ng-doc-font-weight))}:host .ng-doc-input-container .ng-doc-input::placeholder,:host .ng-doc-input-container ::ng-deep .ng-doc-input::placeholder{color:var(--ng-doc-text-muted)}:host .ng-doc-input-container .ng-doc-input.-blink,:host .ng-doc-input-container ::ng-deep .ng-doc-input.-blink{animation:blink-animation .3s}@keyframes blink-animation{0%{background-color:rgba(var(--ng-doc-primary-rgb),.1)}to{background-color:initial}}:host .ng-doc-input-container .ng-doc-input[type=number]::-webkit-inner-spin-button,:host .ng-doc-input-container .ng-doc-input[type=number]::-webkit-outer-spin-button,:host .ng-doc-input-container ::ng-deep .ng-doc-input[type=number]::-webkit-inner-spin-button,:host .ng-doc-input-container ::ng-deep .ng-doc-input[type=number]::-webkit-outer-spin-button{-webkit-appearance:none;-moz-appearance:none;appearance:none}:host .ng-doc-content{--ng-doc-icon-width: 40px;--ng-doc-icon-height: 40px}ng-doc-floated-border{width:var(--ng-doc-input-width);height:var(--ng-doc-input-height)}.ng-doc-button-content{display:flex}.ng-doc-blur-container{position:absolute;left:0;top:0;display:flex;align-items:center;pointer-events:none}.ng-doc-blur-container .ng-doc-blur-content{width:100%;white-space:nowrap;overflow:hidden;padding-left:var(--ng-doc-input-padding-left, calc(var(--ng-doc-base-gutter) * 2));padding-right:var(--ng-doc-input-padding-right, calc(var(--ng-doc-base-gutter) * 2))}\n"] }]
|
|
75
67
|
}], ctorParameters: () => [{ type: i0.ElementRef }, { type: i0.ChangeDetectorRef }], propDecorators: { blurContent: [{
|
|
76
68
|
type: Input
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ng-doc-ui-kit-components-input-wrapper.mjs","sources":["../../../../libs/ui-kit/components/input-wrapper/input-wrapper.component.ts","../../../../libs/ui-kit/components/input-wrapper/input-wrapper.component.html","../../../../libs/ui-kit/components/input-wrapper/ng-doc-ui-kit-components-input-wrapper.ts"],"sourcesContent":["import { NgIf } from '@angular/common';\nimport {\n AfterViewChecked,\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n ContentChild,\n ElementRef,\n HostBinding,\n Input,\n ViewChild,\n} from '@angular/core';\nimport { NgDocBaseInput } from '@ng-doc/ui-kit/classes/base-input';\nimport { NgDocInputHost } from '@ng-doc/ui-kit/classes/input-host';\nimport { NgDocFloatedBorderComponent } from '@ng-doc/ui-kit/components/floated-border';\nimport {
|
|
1
|
+
{"version":3,"file":"ng-doc-ui-kit-components-input-wrapper.mjs","sources":["../../../../libs/ui-kit/components/input-wrapper/input-wrapper.component.ts","../../../../libs/ui-kit/components/input-wrapper/input-wrapper.component.html","../../../../libs/ui-kit/components/input-wrapper/ng-doc-ui-kit-components-input-wrapper.ts"],"sourcesContent":["import { NgIf } from '@angular/common';\nimport {\n AfterViewChecked,\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n ContentChild,\n ElementRef,\n HostBinding,\n Input,\n ViewChild,\n} from '@angular/core';\nimport { NgDocBaseInput } from '@ng-doc/ui-kit/classes/base-input';\nimport { NgDocInputHost } from '@ng-doc/ui-kit/classes/input-host';\nimport { NgDocFloatedBorderComponent } from '@ng-doc/ui-kit/components/floated-border';\nimport { NgDocWrapperComponent } from '@ng-doc/ui-kit/components/wrapper';\nimport { ngDocMakePure } from '@ng-doc/ui-kit/decorators';\nimport { NgDocFocusCatcherDirective } from '@ng-doc/ui-kit/directives/focus-catcher';\nimport { NgDocContextWithImplicit } from '@ng-doc/ui-kit/interfaces';\nimport { NgDocContent, NgDocTextAlign } from '@ng-doc/ui-kit/types';\nimport { PolymorpheusModule } from '@tinkoff/ng-polymorpheus';\n\n@Component({\n selector: 'ng-doc-input-wrapper',\n templateUrl: './input-wrapper.component.html',\n styleUrls: ['./input-wrapper.component.scss'],\n providers: [\n {\n provide: NgDocInputHost,\n useExisting: NgDocInputWrapperComponent,\n },\n ],\n changeDetection: ChangeDetectionStrategy.OnPush,\n imports: [\n NgDocWrapperComponent,\n NgDocFocusCatcherDirective,\n NgDocFloatedBorderComponent,\n NgIf,\n PolymorpheusModule,\n ],\n})\nexport class NgDocInputWrapperComponent<T, B = unknown>\n implements AfterViewChecked, NgDocInputHost<T>\n{\n @Input()\n blurContent: NgDocContent<NgDocContextWithImplicit<B | null>> = '';\n\n @Input()\n blurContext: B | null = null;\n\n @Input()\n @HostBinding('attr.data-ng-doc-align')\n align: NgDocTextAlign = 'left';\n\n @ContentChild(NgDocBaseInput)\n input?: NgDocBaseInput<T>;\n\n @ContentChild(NgDocBaseInput)\n inputControl?: NgDocBaseInput<T>;\n\n @ViewChild(NgDocFocusCatcherDirective, { static: true })\n focusCatcher?: NgDocFocusCatcherDirective;\n\n constructor(\n public elementRef: ElementRef<HTMLElement>,\n protected changeDetectorRef: ChangeDetectorRef,\n ) {}\n\n ngAfterViewChecked(): void {\n this.changeDetectorRef.markForCheck();\n }\n\n @ngDocMakePure\n getBlurContext($implicit: B | null): NgDocContextWithImplicit<B | null> {\n return { $implicit };\n }\n\n @HostBinding('attr.data-ng-doc-input-disabled')\n get disabled(): boolean {\n return !!this.inputControl?.disabled;\n }\n\n inputHasValue(): boolean {\n return !!this.inputControl?.hasValue;\n }\n\n get blurContentIsVisible(): boolean {\n return !!this.blurContent && (!this.input?.isFocused || this.input?.isReadonly);\n }\n\n // eslint-disable-next-line @typescript-eslint/no-empty-function\n emptyEvent(): void {}\n}\n","<ng-doc-wrapper ngDocFocusCatcher>\n <ng-doc-floated-border>\n <label\n class=\"ng-doc-input-container\"\n (focusin)=\"emptyEvent()\"\n (focusout)=\"emptyEvent()\"\n [class.-input-hidden]=\"blurContentIsVisible\">\n <ng-content select=\"[ngDocInputWrapperLeft]\"></ng-content>\n <div class=\"ng-doc-original-input\">\n <ng-content></ng-content>\n <div class=\"ng-doc-blur-container ng-doc-input\" *ngIf=\"blurContentIsVisible\">\n <div class=\"ng-doc-blur-content\">\n <ng-container\n *polymorpheusOutlet=\"blurContent as text; context: getBlurContext(blurContext)\">\n {{ text }}\n </ng-container>\n </div>\n </div>\n </div>\n <ng-content select=\"[ngDocInputWrapperRight]\"></ng-content>\n </label>\n </ng-doc-floated-border>\n</ng-doc-wrapper>\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;;MAyCa,0BAA0B,CAA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AA,EAAA,CAAA,uBAAA,CAAA,MAAA,EAAA,CAAA,CAAA;;AAmCpB,UAAA,CAAA;IADC,aAAa;;;;AAGb,CAAA,EAAA,0BAAA,CAAA,SAAA,EAAA,gBAAA,EAAA,IAAA,CAAA;2FAlCU,0BAA0B,EAAA,UAAA,EAAA,CAAA;kBAnBtC,SAAS;AACE,YAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,sBAAsB,EAGrB,SAAA,EAAA;AACT,wBAAA;AACE,4BAAA,OAAO,EAAE,cAAc;AACvB,4BAAA,WAAW,EAA4B,0BAAA;AACxC,yBAAA;qBACF,EACgB,eAAA,EAAA,uBAAuB,CAAC,MAAM,EACtC,OAAA,EAAA;wBACP,qBAAqB;wBACrB,0BAA0B;wBAC1B,2BAA2B;wBAC3B,IAAI;wBACJ,kBAAkB;AACnB,qBAAA,EAAA,QAAA,EAAA,q3BAAA,EAAA,MAAA,EAAA,CAAA,ywHAAA,CAAA,EAAA;+GAMD,WAAW,EAAA,CAAA;sBADV;gBAID,WAAW,EAAA,CAAA;sBADV;gBAKD,KAAK,EAAA,CAAA;sBAFJ;;sBACA,WAAW;uBAAC,wBAAwB;gBAIrC,KAAK,EAAA,CAAA;sBADJ,YAAY;uBAAC,cAAc;gBAI5B,YAAY,EAAA,CAAA;sBADX,YAAY;uBAAC,cAAc;gBAI5B,YAAY,EAAA,CAAA;sBADX,SAAS;AAAC,gBAAA,IAAA,EAAA,CAAA,0BAA0B,EAAE,EAAE,MAAM,EAAE,IAAI,EAAE;AAavD,aAAA,CAAA,EAAA,cAAc,MAKV,QAAQ,EAAA,CAAA;sBADX,WAAW;uBAAC,iCAAiC;;;AE7EhD;;AAEG;;;;"}
|
|
@@ -1,16 +1,15 @@
|
|
|
1
|
-
import { __decorate, __metadata } from 'tslib';
|
|
2
1
|
import { ListKeyManager } from '@angular/cdk/a11y';
|
|
3
2
|
import * as i0 from '@angular/core';
|
|
4
|
-
import {
|
|
3
|
+
import { Component, ChangeDetectionStrategy, Inject, Optional } from '@angular/core';
|
|
4
|
+
import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
|
|
5
5
|
import { asArray } from '@ng-doc/core/helpers/as-array';
|
|
6
6
|
import * as i1 from '@ng-doc/ui-kit/classes/list-host';
|
|
7
7
|
import { NgDocListHost } from '@ng-doc/ui-kit/classes/list-host';
|
|
8
8
|
import { toElement } from '@ng-doc/ui-kit/helpers';
|
|
9
|
-
import { untilDestroyed, UntilDestroy } from '@ngneat/until-destroy';
|
|
10
9
|
import { merge, fromEvent, NEVER } from 'rxjs';
|
|
11
10
|
import { takeUntil, delayWhen, repeat, filter } from 'rxjs/operators';
|
|
12
11
|
|
|
13
|
-
|
|
12
|
+
class NgDocListComponent {
|
|
14
13
|
constructor(elementRef, ngZone, listHost) {
|
|
15
14
|
this.elementRef = elementRef;
|
|
16
15
|
this.ngZone = ngZone;
|
|
@@ -24,7 +23,7 @@ let NgDocListComponent = class NgDocListComponent {
|
|
|
24
23
|
merge(fromEvent(list, 'keydown'), origin
|
|
25
24
|
? fromEvent(origin, 'keydown').pipe(takeUntil(fromEvent(list, 'keydown')), delayWhen(() => this.ngZone.onStable), repeat())
|
|
26
25
|
: NEVER)
|
|
27
|
-
.pipe(filter((event) => !event.defaultPrevented),
|
|
26
|
+
.pipe(filter((event) => !event.defaultPrevented), takeUntilDestroyed())
|
|
28
27
|
.subscribe((event) => {
|
|
29
28
|
const typedEvent = event;
|
|
30
29
|
switch (typedEvent.key) {
|
|
@@ -50,13 +49,7 @@ let NgDocListComponent = class NgDocListComponent {
|
|
|
50
49
|
}
|
|
51
50
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.0.3", ngImport: i0, type: NgDocListComponent, deps: [{ token: i0.ElementRef }, { token: i0.NgZone }, { token: NgDocListHost, optional: true }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
52
51
|
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.0.3", type: NgDocListComponent, isStandalone: true, selector: "ng-doc-list", ngImport: i0, template: "<ng-content></ng-content>\n", styles: [":host{display:block}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
53
|
-
}
|
|
54
|
-
NgDocListComponent = __decorate([
|
|
55
|
-
UntilDestroy(),
|
|
56
|
-
__metadata("design:paramtypes", [ElementRef,
|
|
57
|
-
NgZone,
|
|
58
|
-
NgDocListHost])
|
|
59
|
-
], NgDocListComponent);
|
|
52
|
+
}
|
|
60
53
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.3", ngImport: i0, type: NgDocListComponent, decorators: [{
|
|
61
54
|
type: Component,
|
|
62
55
|
args: [{ selector: 'ng-doc-list', changeDetection: ChangeDetectionStrategy.OnPush, standalone: true, template: "<ng-content></ng-content>\n", styles: [":host{display:block}\n"] }]
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ng-doc-ui-kit-components-list.mjs","sources":["../../../../libs/ui-kit/components/list/list.component.ts","../../../../libs/ui-kit/components/list/list.component.html","../../../../libs/ui-kit/components/list/ng-doc-ui-kit-components-list.ts"],"sourcesContent":["import { ListKeyManager } from '@angular/cdk/a11y';\nimport {\n
|
|
1
|
+
{"version":3,"file":"ng-doc-ui-kit-components-list.mjs","sources":["../../../../libs/ui-kit/components/list/list.component.ts","../../../../libs/ui-kit/components/list/list.component.html","../../../../libs/ui-kit/components/list/ng-doc-ui-kit-components-list.ts"],"sourcesContent":["import { ListKeyManager } from '@angular/cdk/a11y';\nimport {\n ChangeDetectionStrategy,\n Component,\n ElementRef,\n Inject,\n NgZone,\n Optional,\n} from '@angular/core';\nimport { takeUntilDestroyed } from '@angular/core/rxjs-interop';\nimport { asArray } from '@ng-doc/core/helpers/as-array';\nimport { NgDocListHost } from '@ng-doc/ui-kit/classes/list-host';\nimport { NgDocListItem } from '@ng-doc/ui-kit/classes/list-item';\nimport { toElement } from '@ng-doc/ui-kit/helpers';\nimport { fromEvent, merge, NEVER } from 'rxjs';\nimport { delayWhen, filter, repeat, takeUntil } from 'rxjs/operators';\n\n@Component({\n selector: 'ng-doc-list',\n templateUrl: './list.component.html',\n styleUrls: ['./list.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n standalone: true,\n})\nexport class NgDocListComponent {\n private keyManager: ListKeyManager<NgDocListItem> | null = null;\n private readonly items: Set<NgDocListItem> = new Set<NgDocListItem>();\n\n constructor(\n private elementRef: ElementRef<HTMLElement>,\n private ngZone: NgZone,\n @Inject(NgDocListHost) @Optional() private listHost?: NgDocListHost,\n ) {\n const origin: HTMLElement | null = this.listHost?.listHostOrigin\n ? toElement(this.listHost?.listHostOrigin)\n : null;\n const list: HTMLElement = toElement(this.elementRef);\n\n merge(\n fromEvent(list, 'keydown'),\n origin\n ? fromEvent(origin, 'keydown').pipe(\n takeUntil(fromEvent(list, 'keydown')),\n delayWhen(() => this.ngZone.onStable),\n repeat(),\n )\n : NEVER,\n )\n .pipe(\n filter((event: Event) => !event.defaultPrevented),\n takeUntilDestroyed(),\n )\n .subscribe((event: Event) => {\n const typedEvent: KeyboardEvent = event as KeyboardEvent;\n\n switch (typedEvent.key) {\n case 'Enter':\n this.keyManager?.activeItem?.selectByUser();\n\n typedEvent.preventDefault();\n break;\n }\n\n this.keyManager?.activeItem?.setInactiveStyles();\n this.keyManager?.onKeydown(typedEvent);\n this.keyManager?.activeItem?.setActiveStyles();\n\n if (this.keyManager?.activeItem)\n toElement(this.keyManager?.activeItem.elementRef).scrollIntoView({ block: 'nearest' });\n });\n }\n\n registerItem(item: NgDocListItem): void {\n this.items.add(item);\n\n this.keyManager?.activeItem?.setInactiveStyles();\n this.keyManager = new ListKeyManager(asArray(this.items)).withVerticalOrientation(true);\n }\n\n unregisterItem(item: NgDocListItem): void {\n this.items.delete(item);\n }\n}\n","<ng-content></ng-content>\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;MAwBa,kBAA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AA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,aAAa,EAGN,eAAA,EAAA,uBAAuB,CAAC,MAAM,cACnC,IAAI,EAAA,QAAA,EAAA,6BAAA,EAAA,MAAA,EAAA,CAAA,wBAAA,CAAA,EAAA;;0BASb,MAAM;2BAAC,aAAa;;0BAAG;;;AE/B5B;;AAEG;;;;"}
|
|
@@ -1,10 +1,9 @@
|
|
|
1
|
-
import { __decorate, __metadata } from 'tslib';
|
|
2
1
|
import { NgIf } from '@angular/common';
|
|
3
2
|
import * as i0 from '@angular/core';
|
|
4
|
-
import { Directive, QueryList,
|
|
3
|
+
import { Directive, QueryList, inject, DestroyRef, Component, ChangeDetectionStrategy, ContentChildren } from '@angular/core';
|
|
4
|
+
import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
|
|
5
5
|
import { NgDocOptionComponent } from '@ng-doc/ui-kit/components/option';
|
|
6
6
|
import { NgDocTextComponent } from '@ng-doc/ui-kit/components/text';
|
|
7
|
-
import { untilDestroyed, UntilDestroy } from '@ngneat/until-destroy';
|
|
8
7
|
import { startWith } from 'rxjs/operators';
|
|
9
8
|
|
|
10
9
|
class NgDocOptionGroupHeaderDirective {
|
|
@@ -18,15 +17,16 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.3", ngImpor
|
|
|
18
17
|
standalone: true,
|
|
19
18
|
}]
|
|
20
19
|
}] });
|
|
21
|
-
|
|
20
|
+
class NgDocOptionGroupComponent {
|
|
22
21
|
constructor(changeDetectorRef) {
|
|
23
22
|
this.changeDetectorRef = changeDetectorRef;
|
|
24
23
|
this.options = new QueryList();
|
|
25
24
|
this.hasHeader = false;
|
|
25
|
+
this.destroyRef = inject(DestroyRef);
|
|
26
26
|
}
|
|
27
27
|
ngAfterContentInit() {
|
|
28
28
|
this.options.changes
|
|
29
|
-
.pipe(startWith(this.options),
|
|
29
|
+
.pipe(startWith(this.options), takeUntilDestroyed(this.destroyRef))
|
|
30
30
|
.subscribe((options) => {
|
|
31
31
|
this.hasHeader = !!options.length;
|
|
32
32
|
this.changeDetectorRef.markForCheck();
|
|
@@ -34,11 +34,7 @@ let NgDocOptionGroupComponent = class NgDocOptionGroupComponent {
|
|
|
34
34
|
}
|
|
35
35
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.0.3", ngImport: i0, type: NgDocOptionGroupComponent, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
36
36
|
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.0.3", type: NgDocOptionGroupComponent, isStandalone: true, selector: "ng-doc-option-group", queries: [{ propertyName: "options", predicate: NgDocOptionComponent, descendants: true }], ngImport: i0, template: "<div class=\"ng-doc-option-group-wrapper\">\n\t<div *ngIf=\"hasHeader\" class=\"ng-doc-option-group-header\" ng-doc-text>\n\t\t<ng-content select=\"[ngDocOptionGroupHeader]\"></ng-content>\n\t</div>\n\t<div class=\"ng-doc-option-group\">\n\t\t<ng-content></ng-content>\n\t</div>\n</div>\n", styles: [":host{display:block}.ng-doc-option-group-header{position:sticky;top:0;display:flex;background-color:var(--ng-doc-base-1);padding:var(--ng-doc-base-gutter) calc(var(--ng-doc-base-gutter) * 2);z-index:1;--ng-doc-font-size: 13px;--ng-doc-font-weight: 700;--ng-doc-font-line-height: 18px;--ng-doc-text: var(--ng-doc-base-9)}.ng-doc-option-group ::ng-deep ng-doc-option .ng-doc-option-wrapper{padding-left:calc(var(--ng-doc-base-gutter) * 2)}\n"], dependencies: [{ kind: "directive", type: NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: NgDocTextComponent, selector: "[ng-doc-text]", inputs: ["size", "color", "align", "absoluteContent"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
37
|
-
}
|
|
38
|
-
NgDocOptionGroupComponent = __decorate([
|
|
39
|
-
UntilDestroy(),
|
|
40
|
-
__metadata("design:paramtypes", [ChangeDetectorRef])
|
|
41
|
-
], NgDocOptionGroupComponent);
|
|
37
|
+
}
|
|
42
38
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.3", ngImport: i0, type: NgDocOptionGroupComponent, decorators: [{
|
|
43
39
|
type: Component,
|
|
44
40
|
args: [{ selector: 'ng-doc-option-group', changeDetection: ChangeDetectionStrategy.OnPush, imports: [NgIf, NgDocTextComponent], template: "<div class=\"ng-doc-option-group-wrapper\">\n\t<div *ngIf=\"hasHeader\" class=\"ng-doc-option-group-header\" ng-doc-text>\n\t\t<ng-content select=\"[ngDocOptionGroupHeader]\"></ng-content>\n\t</div>\n\t<div class=\"ng-doc-option-group\">\n\t\t<ng-content></ng-content>\n\t</div>\n</div>\n", styles: [":host{display:block}.ng-doc-option-group-header{position:sticky;top:0;display:flex;background-color:var(--ng-doc-base-1);padding:var(--ng-doc-base-gutter) calc(var(--ng-doc-base-gutter) * 2);z-index:1;--ng-doc-font-size: 13px;--ng-doc-font-weight: 700;--ng-doc-font-line-height: 18px;--ng-doc-text: var(--ng-doc-base-9)}.ng-doc-option-group ::ng-deep ng-doc-option .ng-doc-option-wrapper{padding-left:calc(var(--ng-doc-base-gutter) * 2)}\n"] }]
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ng-doc-ui-kit-components-option-group.mjs","sources":["../../../../libs/ui-kit/components/option-group/option-group.component.ts","../../../../libs/ui-kit/components/option-group/option-group.component.html","../../../../libs/ui-kit/components/option-group/ng-doc-ui-kit-components-option-group.ts"],"sourcesContent":["import { NgIf } from '@angular/common';\nimport {\n AfterContentInit,\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n ContentChildren,\n Directive,\n QueryList,\n} from '@angular/core';\nimport {
|
|
1
|
+
{"version":3,"file":"ng-doc-ui-kit-components-option-group.mjs","sources":["../../../../libs/ui-kit/components/option-group/option-group.component.ts","../../../../libs/ui-kit/components/option-group/option-group.component.html","../../../../libs/ui-kit/components/option-group/ng-doc-ui-kit-components-option-group.ts"],"sourcesContent":["import { NgIf } from '@angular/common';\nimport {\n AfterContentInit,\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n ContentChildren,\n DestroyRef,\n Directive,\n inject,\n QueryList,\n} from '@angular/core';\nimport { takeUntilDestroyed } from '@angular/core/rxjs-interop';\nimport { NgDocOptionComponent } from '@ng-doc/ui-kit/components/option';\nimport { NgDocTextComponent } from '@ng-doc/ui-kit/components/text';\nimport { startWith } from 'rxjs/operators';\n\n@Directive({\n selector: '[ngDocOptionGroupHeader]',\n standalone: true,\n})\nexport class NgDocOptionGroupHeaderDirective {}\n\n@Component({\n selector: 'ng-doc-option-group',\n templateUrl: './option-group.component.html',\n styleUrls: ['./option-group.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n imports: [NgIf, NgDocTextComponent],\n})\nexport class NgDocOptionGroupComponent<T> implements AfterContentInit {\n @ContentChildren(NgDocOptionComponent, { descendants: true })\n options: QueryList<NgDocOptionComponent<T>> = new QueryList<NgDocOptionComponent<T>>();\n hasHeader: boolean = false;\n\n private readonly destroyRef = inject(DestroyRef);\n\n constructor(private changeDetectorRef: ChangeDetectorRef) {}\n\n ngAfterContentInit(): void {\n this.options.changes\n .pipe(startWith(this.options), takeUntilDestroyed(this.destroyRef))\n .subscribe((options: QueryList<NgDocOptionComponent<T>>) => {\n this.hasHeader = !!options.length;\n this.changeDetectorRef.markForCheck();\n });\n }\n}\n","<div class=\"ng-doc-option-group-wrapper\">\n\t<div *ngIf=\"hasHeader\" class=\"ng-doc-option-group-header\" ng-doc-text>\n\t\t<ng-content select=\"[ngDocOptionGroupHeader]\"></ng-content>\n\t</div>\n\t<div class=\"ng-doc-option-group\">\n\t\t<ng-content></ng-content>\n\t</div>\n</div>\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;MAqBa,+BAA+B,CAAA;8GAA/B,+BAA+B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AA,EAAA,yBAAyB,uGACnB,oBAAoB,EAAA,WAAA,EAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,EAAA,EAAA,QAAA,EC/BvC,kSAQA,EDoBY,MAAA,EAAA,CAAA,ybAAA,CAAA,EAAA,YAAA,EAAA,CAAA,EAAA,IAAA,EAAA,WAAA,EAAA,IAAA,EAAA,IAAI,6FAAE,kBAAkB,EAAA,QAAA,EAAA,eAAA,EAAA,MAAA,EAAA,CAAA,MAAA,EAAA,OAAA,EAAA,OAAA,EAAA,iBAAA,CAAA,EAAA,CAAA,EAAA,eAAA,EAAA,EAAA,CAAA,uBAAA,CAAA,MAAA,EAAA,CAAA,CAAA;;2FAEvB,yBAAyB,EAAA,UAAA,EAAA,CAAA;kBAPrC,SAAS;+BACE,qBAAqB,EAAA,eAAA,EAGd,uBAAuB,CAAC,MAAM,WACtC,CAAC,IAAI,EAAE,kBAAkB,CAAC,EAAA,QAAA,EAAA,kSAAA,EAAA,MAAA,EAAA,CAAA,ybAAA,CAAA,EAAA;sFAInC,OAAO,EAAA,CAAA;sBADN,eAAe;AAAC,gBAAA,IAAA,EAAA,CAAA,oBAAoB,EAAE,EAAE,WAAW,EAAE,IAAI,EAAE;;;AE/B9D;;AAEG;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ng-doc-ui-kit-components-option.mjs","sources":["../../../../libs/ui-kit/components/option/option.component.ts","../../../../libs/ui-kit/components/option/ng-doc-ui-kit-components-option.ts"],"sourcesContent":["import {\n
|
|
1
|
+
{"version":3,"file":"ng-doc-ui-kit-components-option.mjs","sources":["../../../../libs/ui-kit/components/option/option.component.ts","../../../../libs/ui-kit/components/option/ng-doc-ui-kit-components-option.ts"],"sourcesContent":["import {\n ChangeDetectionStrategy,\n Component,\n ElementRef,\n HostBinding,\n HostListener,\n inject,\n OnDestroy,\n} from '@angular/core';\nimport { NgDocListItem } from '@ng-doc/ui-kit/classes/list-item';\nimport { NgDocListComponent } from '@ng-doc/ui-kit/components/list';\nimport { DICompareHost, DIStateControl, injectHostControl } from 'di-controls';\n\n@Component({\n selector: 'ng-doc-option',\n template: '<ng-content></ng-content>',\n styleUrls: ['./option.component.scss'],\n providers: [\n {\n provide: NgDocListItem,\n useExisting: NgDocOptionComponent,\n },\n ],\n changeDetection: ChangeDetectionStrategy.OnPush,\n standalone: true,\n})\nexport class NgDocOptionComponent<T> extends DIStateControl<T> implements NgDocListItem, OnDestroy {\n @HostBinding('attr.data-ng-doc-hover')\n protected hovered: boolean = false;\n\n override readonly elementRef: ElementRef<HTMLElement> = inject(ElementRef);\n protected readonly list: NgDocListComponent | null = inject(NgDocListComponent, {\n optional: true,\n });\n\n constructor() {\n super({\n host: injectHostControl({ optional: true }),\n compareHost: inject(DICompareHost, { optional: true }),\n });\n\n this.list?.registerItem(this);\n }\n\n @HostListener('click')\n clickEvent(): void {\n this.check();\n }\n\n selectByUser(): void {\n const anchor: HTMLAnchorElement | null = this.elementRef.nativeElement.querySelector('a');\n\n anchor ? anchor.click() : this.check();\n }\n\n setActiveStyles(): void {\n this.hovered = true;\n this.changeDetectorRef.markForCheck();\n }\n\n setInactiveStyles(): void {\n this.hovered = false;\n this.changeDetectorRef.markForCheck();\n }\n\n ngOnDestroy(): void {\n this.list?.unregisterItem(this);\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;AA0BM,MAAO,oBAAwB,SAAQ,cAAiB,CAAA;AAS5D,IAAA,WAAA,GAAA;AACE,QAAA,KAAK,CAAC;YACJ,IAAI,EAAE,iBAAiB,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;YAC3C,WAAW,EAAE,MAAM,CAAC,aAAa,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;AACvD,SAAA,CAAC;QAXM,IAAO,CAAA,OAAA,GAAY,KAAK;AAEhB,QAAA,IAAA,CAAA,UAAU,GAA4B,MAAM,CAAC,UAAU,CAAC;A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ClC,aAAA;AACF,SAAA,EAAA,eAAA,EAAA,IAAA,EAAA,QAAA,EAAA,EAAA,EAAA,QAAA,EAPS,2BAA2B,EAAA,QAAA,EAAA,IAAA,EAAA,MAAA,EAAA,CAAA,wiBAAA,CAAA,EAAA,eAAA,EAAA,EAAA,CAAA,uBAAA,CAAA,MAAA,EAAA,CAAA,CAAA;;2FAW1B,oBAAoB,EAAA,UAAA,EAAA,CAAA;kBAbhC,SAAS;+BACE,eAAe,EAAA,QAAA,EACf,2BAA2B,EAE1B,SAAA,EAAA;AACT,wBAAA;AACE,4BAAA,OAAO,EAAE,aAAa;AACtB,4BAAA,WAAW,EAAsB,oBAAA;AAClC,yBAAA;AACF,qBAAA,EAAA,eAAA,EACgB,uBAAuB,CAAC,MAAM,EAAA,UAAA,EACnC,IAAI,EAAA,MAAA,EAAA,CAAA,wiBAAA,CAAA,EAAA;wDAIN,OAAO,EAAA,CAAA;sBADhB,WAAW;uBAAC,wBAAwB;gBAkBrC,UAAU,EAAA,CAAA;sBADT,YAAY;uBAAC,OAAO;;;AC5CvB;;AAEG;;;;"}
|
|
@@ -1,9 +1,8 @@
|
|
|
1
|
-
import { __decorate, __metadata } from 'tslib';
|
|
2
1
|
import { DOCUMENT } from '@angular/common';
|
|
3
2
|
import * as i0 from '@angular/core';
|
|
4
|
-
import { Directive,
|
|
3
|
+
import { Directive, inject, DestroyRef, afterNextRender, Component, ChangeDetectionStrategy, Inject, Input, ViewChild, HostBinding } from '@angular/core';
|
|
4
|
+
import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
|
|
5
5
|
import { ngDocZoneOptimize } from '@ng-doc/ui-kit/observables';
|
|
6
|
-
import { untilDestroyed, UntilDestroy } from '@ngneat/until-destroy';
|
|
7
6
|
import { fromEvent, merge } from 'rxjs';
|
|
8
7
|
import { tap, map, pairwise, switchMap, takeUntil, take, filter, debounceTime } from 'rxjs/operators';
|
|
9
8
|
|
|
@@ -29,7 +28,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.3", ngImpor
|
|
|
29
28
|
standalone: true,
|
|
30
29
|
}]
|
|
31
30
|
}] });
|
|
32
|
-
|
|
31
|
+
class NgDocPaneComponent {
|
|
33
32
|
constructor(document, changeDetectorRef, elementRef, ngZone) {
|
|
34
33
|
this.document = document;
|
|
35
34
|
this.changeDetectorRef = changeDetectorRef;
|
|
@@ -38,6 +37,7 @@ let NgDocPaneComponent = class NgDocPaneComponent {
|
|
|
38
37
|
this.expanded = false;
|
|
39
38
|
this.width = '0%';
|
|
40
39
|
this.dragging = false;
|
|
40
|
+
const destroyRef = inject(DestroyRef);
|
|
41
41
|
afterNextRender(() => {
|
|
42
42
|
if (this.resizer) {
|
|
43
43
|
const mouseDown$ = fromEvent(this.resizer.nativeElement, 'mousedown').pipe(tap(() => {
|
|
@@ -54,13 +54,13 @@ let NgDocPaneComponent = class NgDocPaneComponent {
|
|
|
54
54
|
const dragEvent$ = mouseMove$.pipe(takeUntil(mouseUp$));
|
|
55
55
|
const clickEvent$ = mouseUp$.pipe(map(() => null), takeUntil(mouseMove$), take(1));
|
|
56
56
|
return merge(dragEvent$, clickEvent$);
|
|
57
|
-
}), filter((delta) => delta !== 0), ngDocZoneOptimize(this.ngZone),
|
|
57
|
+
}), filter((delta) => delta !== 0), ngDocZoneOptimize(this.ngZone), takeUntilDestroyed(destroyRef))
|
|
58
58
|
.subscribe((delta) => {
|
|
59
59
|
delta === null ? this.toggle() : this.addDelta(delta);
|
|
60
60
|
});
|
|
61
61
|
}
|
|
62
62
|
fromEvent(window, 'resize')
|
|
63
|
-
.pipe(debounceTime(100),
|
|
63
|
+
.pipe(debounceTime(100), ngDocZoneOptimize(this.ngZone), takeUntilDestroyed(destroyRef))
|
|
64
64
|
.subscribe(() => this.addDelta(0));
|
|
65
65
|
});
|
|
66
66
|
this.addDelta(0);
|
|
@@ -92,14 +92,7 @@ let NgDocPaneComponent = class NgDocPaneComponent {
|
|
|
92
92
|
}
|
|
93
93
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.0.3", ngImport: i0, type: NgDocPaneComponent, deps: [{ token: DOCUMENT }, { token: i0.ChangeDetectorRef }, { token: i0.ElementRef }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
94
94
|
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.0.3", type: NgDocPaneComponent, isStandalone: true, selector: "ng-doc-pane", inputs: { expanded: "expanded" }, host: { properties: { "attr.data-ng-doc-dragging": "this.dragging" } }, viewQueries: [{ propertyName: "resizer", first: true, predicate: ["resizer"], descendants: true, static: true }], usesOnChanges: true, ngImport: i0, template: "<div class=\"ng-doc-pane-back\" [style.width]=\"width\">\n\t<div class=\"ng-doc-pane-content\">\n\t\t<ng-content select=\"[ngDocPaneBack]\"></ng-content>\n\t</div>\n</div>\n<div class=\"ng-doc-pane-resizer\" #resizer></div>\n<div class=\"ng-doc-pane-front\">\n\t<div class=\"ng-doc-pane-content\">\n\t\t<ng-content select=\"[ngDocPaneFront]\"></ng-content>\n\t</div>\n</div>\n", styles: [":host{position:relative;display:flex;width:100%;border-radius:var(--ng-doc-pane-border-radius, var(--ng-doc-base-gutter));border:var(--ng-doc-pane-border, 1px solid var(--ng-doc-border-color));overflow:hidden}:host[data-ng-doc-dragging=false] .ng-doc-pane-back{transition:var(--ng-doc-transition) width}:host .ng-doc-pane-front{position:relative;display:flex;width:100%;background-color:var(--ng-doc-pane-front-background, var(--ng-doc-pane-background, var(--ng-doc-base-1)));overflow:hidden;border-top-right-radius:var(--ng-doc-base-gutter);border-bottom-right-radius:var(--ng-doc-base-gutter);border:var(--ng-doc-pane-front-border, var(--ng-doc-pane-border))}:host .ng-doc-pane-back{position:relative;display:flex;flex-shrink:0;width:100%;background-color:var(--ng-doc-pane-back-background, var(--ng-doc-pane-background, var(--ng-doc-base-1)));overflow:hidden;border-top-left-radius:var(--ng-doc-base-gutter);border-bottom-left-radius:var(--ng-doc-base-gutter);border:var(--ng-doc-pane-back-border, var(--ng-doc-pane-border))}:host .ng-doc-pane-resizer{position:relative;flex-shrink:0;transform:translateZ(0);background-color:var(--ng-doc-base-3);width:16px;display:block;cursor:ew-resize}:host .ng-doc-pane-resizer:after{content:\"\";display:flex;background:var(--ng-doc-base-10);border-radius:50px;position:absolute;width:4px;height:20%;top:50%;left:50%;transform:translateY(-50%) translate(-50%);opacity:1;transition:var(--ng-doc-transition) height}:host .ng-doc-pane-content{display:flex;align-items:center;justify-content:center;flex-shrink:0;width:100%;height:100%;min-width:var(--ng-doc-pane-content-min-width, 200px)}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
95
|
-
}
|
|
96
|
-
NgDocPaneComponent = __decorate([
|
|
97
|
-
UntilDestroy(),
|
|
98
|
-
__metadata("design:paramtypes", [Document,
|
|
99
|
-
ChangeDetectorRef,
|
|
100
|
-
ElementRef,
|
|
101
|
-
NgZone])
|
|
102
|
-
], NgDocPaneComponent);
|
|
95
|
+
}
|
|
103
96
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.3", ngImport: i0, type: NgDocPaneComponent, decorators: [{
|
|
104
97
|
type: Component,
|
|
105
98
|
args: [{ selector: 'ng-doc-pane', changeDetection: ChangeDetectionStrategy.OnPush, standalone: true, template: "<div class=\"ng-doc-pane-back\" [style.width]=\"width\">\n\t<div class=\"ng-doc-pane-content\">\n\t\t<ng-content select=\"[ngDocPaneBack]\"></ng-content>\n\t</div>\n</div>\n<div class=\"ng-doc-pane-resizer\" #resizer></div>\n<div class=\"ng-doc-pane-front\">\n\t<div class=\"ng-doc-pane-content\">\n\t\t<ng-content select=\"[ngDocPaneFront]\"></ng-content>\n\t</div>\n</div>\n", styles: [":host{position:relative;display:flex;width:100%;border-radius:var(--ng-doc-pane-border-radius, var(--ng-doc-base-gutter));border:var(--ng-doc-pane-border, 1px solid var(--ng-doc-border-color));overflow:hidden}:host[data-ng-doc-dragging=false] .ng-doc-pane-back{transition:var(--ng-doc-transition) width}:host .ng-doc-pane-front{position:relative;display:flex;width:100%;background-color:var(--ng-doc-pane-front-background, var(--ng-doc-pane-background, var(--ng-doc-base-1)));overflow:hidden;border-top-right-radius:var(--ng-doc-base-gutter);border-bottom-right-radius:var(--ng-doc-base-gutter);border:var(--ng-doc-pane-front-border, var(--ng-doc-pane-border))}:host .ng-doc-pane-back{position:relative;display:flex;flex-shrink:0;width:100%;background-color:var(--ng-doc-pane-back-background, var(--ng-doc-pane-background, var(--ng-doc-base-1)));overflow:hidden;border-top-left-radius:var(--ng-doc-base-gutter);border-bottom-left-radius:var(--ng-doc-base-gutter);border:var(--ng-doc-pane-back-border, var(--ng-doc-pane-border))}:host .ng-doc-pane-resizer{position:relative;flex-shrink:0;transform:translateZ(0);background-color:var(--ng-doc-base-3);width:16px;display:block;cursor:ew-resize}:host .ng-doc-pane-resizer:after{content:\"\";display:flex;background:var(--ng-doc-base-10);border-radius:50px;position:absolute;width:4px;height:20%;top:50%;left:50%;transform:translateY(-50%) translate(-50%);opacity:1;transition:var(--ng-doc-transition) height}:host .ng-doc-pane-content{display:flex;align-items:center;justify-content:center;flex-shrink:0;width:100%;height:100%;min-width:var(--ng-doc-pane-content-min-width, 200px)}\n"] }]
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ng-doc-ui-kit-components-pane.mjs","sources":["../../../../libs/ui-kit/components/pane/pane.component.ts","../../../../libs/ui-kit/components/pane/pane.component.html","../../../../libs/ui-kit/components/pane/ng-doc-ui-kit-components-pane.ts"],"sourcesContent":["import { DOCUMENT } from '@angular/common';\nimport {\n
|
|
1
|
+
{"version":3,"file":"ng-doc-ui-kit-components-pane.mjs","sources":["../../../../libs/ui-kit/components/pane/pane.component.ts","../../../../libs/ui-kit/components/pane/pane.component.html","../../../../libs/ui-kit/components/pane/ng-doc-ui-kit-components-pane.ts"],"sourcesContent":["import { DOCUMENT } from '@angular/common';\nimport {\n afterNextRender,\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n DestroyRef,\n Directive,\n ElementRef,\n HostBinding,\n Inject,\n inject,\n Input,\n NgZone,\n OnChanges,\n SimpleChanges,\n ViewChild,\n} from '@angular/core';\nimport { takeUntilDestroyed } from '@angular/core/rxjs-interop';\nimport { ngDocZoneOptimize } from '@ng-doc/ui-kit/observables';\nimport { fromEvent, merge, Observable } from 'rxjs';\nimport {\n debounceTime,\n filter,\n map,\n pairwise,\n switchMap,\n take,\n takeUntil,\n tap,\n} from 'rxjs/operators';\n\n@Directive({\n selector: '[ngDocPaneFront]',\n standalone: true,\n})\nexport class NgDocPaneFrontDirective {}\n\n@Directive({\n selector: '[ngDocPaneBack]',\n standalone: true,\n})\nexport class NgDocPaneBackDirective {}\n\n@Component({\n selector: 'ng-doc-pane',\n templateUrl: './pane.component.html',\n styleUrls: ['./pane.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n standalone: true,\n})\nexport class NgDocPaneComponent implements OnChanges {\n @Input()\n expanded: boolean = false;\n\n @ViewChild('resizer', { static: true })\n resizer?: ElementRef<HTMLElement>;\n\n width: string = '0%';\n\n @HostBinding('attr.data-ng-doc-dragging')\n dragging: boolean = false;\n\n constructor(\n @Inject(DOCUMENT)\n private readonly document: Document,\n private readonly changeDetectorRef: ChangeDetectorRef,\n private readonly elementRef: ElementRef<HTMLElement>,\n private readonly ngZone: NgZone,\n ) {\n const destroyRef = inject(DestroyRef);\n\n afterNextRender(() => {\n if (this.resizer) {\n const mouseDown$ = fromEvent(this.resizer.nativeElement, 'mousedown').pipe(\n tap(() => {\n this.dragging = true;\n this.changeDetectorRef.markForCheck();\n }),\n );\n\n const mouseUp$ = fromEvent(this.document, 'mouseup').pipe(\n tap(() => {\n this.dragging = false;\n this.changeDetectorRef.markForCheck();\n }),\n );\n\n const mouseMove$ = (fromEvent(this.document, 'mousemove') as Observable<MouseEvent>).pipe(\n map((event: MouseEvent) => event.clientX),\n pairwise(),\n map(([prev, next]: [number, number]) => next - prev),\n );\n\n mouseDown$\n .pipe(\n switchMap(() => {\n const dragEvent$ = mouseMove$.pipe(takeUntil(mouseUp$));\n\n const clickEvent$ = mouseUp$.pipe(\n map(() => null),\n takeUntil(mouseMove$),\n take(1),\n );\n\n return merge(dragEvent$, clickEvent$);\n }),\n filter((delta: number | null) => delta !== 0),\n ngDocZoneOptimize(this.ngZone),\n takeUntilDestroyed(destroyRef),\n )\n .subscribe((delta: number | null) => {\n delta === null ? this.toggle() : this.addDelta(delta);\n });\n }\n\n fromEvent(window, 'resize')\n .pipe(debounceTime(100), ngDocZoneOptimize(this.ngZone), takeUntilDestroyed(destroyRef))\n .subscribe(() => this.addDelta(0));\n });\n\n this.addDelta(0);\n }\n\n ngOnChanges({ expanded }: SimpleChanges): void {\n if (expanded) {\n expanded.currentValue\n ? this.addDelta(this.elementRef.nativeElement.offsetWidth)\n : this.addDelta(-this.elementRef.nativeElement.offsetWidth);\n }\n }\n\n toggle(): void {\n if (this.resizer) {\n const middle = this.elementRef.nativeElement.offsetWidth / 2;\n\n if (this.resizer.nativeElement.offsetLeft < middle) {\n this.addDelta(this.elementRef.nativeElement.offsetWidth);\n } else {\n this.addDelta(-this.elementRef.nativeElement.offsetWidth);\n }\n }\n }\n\n private addDelta(delta: number): void {\n if (this.resizer) {\n const maxWidth =\n this.elementRef.nativeElement.offsetWidth - this.resizer.nativeElement.offsetWidth;\n\n this.width = `${Math.min(\n maxWidth,\n Math.max(0, this.resizer.nativeElement.offsetLeft + delta),\n )}px`;\n\n this.changeDetectorRef.detectChanges();\n }\n }\n}\n","<div class=\"ng-doc-pane-back\" [style.width]=\"width\">\n\t<div class=\"ng-doc-pane-content\">\n\t\t<ng-content select=\"[ngDocPaneBack]\"></ng-content>\n\t</div>\n</div>\n<div class=\"ng-doc-pane-resizer\" #resizer></div>\n<div class=\"ng-doc-pane-front\">\n\t<div class=\"ng-doc-pane-content\">\n\t\t<ng-content select=\"[ngDocPaneFront]\"></ng-content>\n\t</div>\n</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AA,CAAA,EAAA,QAAA,EAAA,aAAa,EAGN,eAAA,EAAA,uBAAuB,CAAC,MAAM,cACnC,IAAI,EAAA,QAAA,EAAA,0XAAA,EAAA,MAAA,EAAA,CAAA,+lDAAA,CAAA,EAAA;;0BAeb,MAAM;2BAAC,QAAQ;uHAXlB,QAAQ,EAAA,CAAA;sBADP;gBAID,OAAO,EAAA,CAAA;sBADN,SAAS;AAAC,gBAAA,IAAA,EAAA,CAAA,SAAS,EAAE,EAAE,MAAM,EAAE,IAAI,EAAE;gBAMtC,QAAQ,EAAA,CAAA;sBADP,WAAW;uBAAC,2BAA2B;;;AE5D1C;;AAEG;;;;"}
|
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
import { __decorate, __metadata } from 'tslib';
|
|
2
1
|
import * as i0 from '@angular/core';
|
|
3
|
-
import { Directive,
|
|
4
|
-
import {
|
|
2
|
+
import { Directive, inject, DestroyRef, Component, ChangeDetectionStrategy, Input, HostBinding } from '@angular/core';
|
|
3
|
+
import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
|
|
5
4
|
import { distinctUntilChanged, debounceTime } from 'rxjs/operators';
|
|
6
5
|
import { ReplaySubject } from 'rxjs';
|
|
7
6
|
|
|
@@ -38,15 +37,16 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.3", ngImpor
|
|
|
38
37
|
}]
|
|
39
38
|
}] });
|
|
40
39
|
|
|
41
|
-
|
|
40
|
+
class NgDocSelectionComponent {
|
|
42
41
|
constructor(elementRef, selectionHost) {
|
|
43
42
|
this.elementRef = elementRef;
|
|
44
43
|
this.selectionHost = selectionHost;
|
|
45
44
|
this.align = 'bottom';
|
|
45
|
+
this.destroyRef = inject(DestroyRef);
|
|
46
46
|
}
|
|
47
47
|
ngAfterViewInit() {
|
|
48
48
|
this.selectionHost.selectedChange$
|
|
49
|
-
.pipe(debounceTime(0),
|
|
49
|
+
.pipe(debounceTime(0), takeUntilDestroyed(this.destroyRef))
|
|
50
50
|
.subscribe((selected) => this.setStyles(selected));
|
|
51
51
|
}
|
|
52
52
|
setStyles(element) {
|
|
@@ -74,12 +74,7 @@ let NgDocSelectionComponent = class NgDocSelectionComponent {
|
|
|
74
74
|
}
|
|
75
75
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.0.3", ngImport: i0, type: NgDocSelectionComponent, deps: [{ token: i0.ElementRef }, { token: NgDocSelectionHostDirective }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
76
76
|
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.0.3", type: NgDocSelectionComponent, isStandalone: true, selector: "ng-doc-selection", inputs: { align: "align" }, host: { properties: { "attr.data-ng-doc-align": "this.align" } }, ngImport: i0, template: '', isInline: true, styles: [":host{position:absolute;transition:var(--ng-doc-transition);pointer-events:none;background:var(--ng-doc-selection-background)}:host[data-ng-doc-align=left]{left:0;border-left:var(--ng-doc-selection-border)}:host[data-ng-doc-align=right]{right:0;border-right:var(--ng-doc-selection-border)}:host[data-ng-doc-align=bottom]{bottom:0;border-bottom:var(--ng-doc-selection-border)}:host[data-ng-doc-align=top]{top:0;border-top:var(--ng-doc-selection-border)}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
77
|
-
}
|
|
78
|
-
NgDocSelectionComponent = __decorate([
|
|
79
|
-
UntilDestroy(),
|
|
80
|
-
__metadata("design:paramtypes", [ElementRef,
|
|
81
|
-
NgDocSelectionHostDirective])
|
|
82
|
-
], NgDocSelectionComponent);
|
|
77
|
+
}
|
|
83
78
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.3", ngImport: i0, type: NgDocSelectionComponent, decorators: [{
|
|
84
79
|
type: Component,
|
|
85
80
|
args: [{ selector: 'ng-doc-selection', template: '', changeDetection: ChangeDetectionStrategy.OnPush, standalone: true, styles: [":host{position:absolute;transition:var(--ng-doc-transition);pointer-events:none;background:var(--ng-doc-selection-background)}:host[data-ng-doc-align=left]{left:0;border-left:var(--ng-doc-selection-border)}:host[data-ng-doc-align=right]{right:0;border-right:var(--ng-doc-selection-border)}:host[data-ng-doc-align=bottom]{bottom:0;border-bottom:var(--ng-doc-selection-border)}:host[data-ng-doc-align=top]{top:0;border-top:var(--ng-doc-selection-border)}\n"] }]
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ng-doc-ui-kit-components-selection.mjs","sources":["../../../../libs/ui-kit/components/selection/selection-host.directive.ts","../../../../libs/ui-kit/components/selection/selection.component.ts","../../../../libs/ui-kit/components/selection/selection-origin.directive.ts","../../../../libs/ui-kit/components/selection/ng-doc-ui-kit-components-selection.ts"],"sourcesContent":["import { Directive } from '@angular/core';\nimport { Observable, ReplaySubject } from 'rxjs';\nimport { distinctUntilChanged } from 'rxjs/operators';\n\nimport { NgDocSelectionOriginDirective } from './selection-origin.directive';\n\n@Directive({\n\tselector: '[ngDocSelectionHost]',\n\tstandalone: true,\n})\nexport class NgDocSelectionHostDirective {\n\tprivate origins: Set<NgDocSelectionOriginDirective> = new Set<NgDocSelectionOriginDirective>();\n\tprivate selected?: NgDocSelectionOriginDirective;\n\tprivate selectedChange: ReplaySubject<HTMLElement | undefined> = new ReplaySubject<\n\t\tHTMLElement | undefined\n\t>();\n\n\tget selectedChange$(): Observable<HTMLElement | undefined> {\n\t\treturn this.selectedChange.pipe(distinctUntilChanged());\n\t}\n\n\taddOrigin(origin: NgDocSelectionOriginDirective): void {\n\t\tthis.origins.add(origin);\n\t}\n\n\tremoveOrigin(origin: NgDocSelectionOriginDirective): void {\n\t\tthis.origins.delete(origin);\n\n\t\tif (this.selected === origin) {\n\t\t\tthis.changeSelected(origin, false);\n\t\t}\n\t}\n\n\tchangeSelected(origin: NgDocSelectionOriginDirective, selected: boolean): void {\n\t\tthis.selected =\n\t\t\tthis.selected === origin || selected ? (selected ? origin : undefined) : this.selected;\n\t\tthis.selectedChange.next(this.selected?.elementRef?.nativeElement ?? undefined);\n\t}\n}\n","import {\n AfterViewInit,\n ChangeDetectionStrategy,\n Component,\n ElementRef,\n HostBinding,\n Input,\n} from '@angular/core';\nimport {
|
|
1
|
+
{"version":3,"file":"ng-doc-ui-kit-components-selection.mjs","sources":["../../../../libs/ui-kit/components/selection/selection-host.directive.ts","../../../../libs/ui-kit/components/selection/selection.component.ts","../../../../libs/ui-kit/components/selection/selection-origin.directive.ts","../../../../libs/ui-kit/components/selection/ng-doc-ui-kit-components-selection.ts"],"sourcesContent":["import { Directive } from '@angular/core';\nimport { Observable, ReplaySubject } from 'rxjs';\nimport { distinctUntilChanged } from 'rxjs/operators';\n\nimport { NgDocSelectionOriginDirective } from './selection-origin.directive';\n\n@Directive({\n\tselector: '[ngDocSelectionHost]',\n\tstandalone: true,\n})\nexport class NgDocSelectionHostDirective {\n\tprivate origins: Set<NgDocSelectionOriginDirective> = new Set<NgDocSelectionOriginDirective>();\n\tprivate selected?: NgDocSelectionOriginDirective;\n\tprivate selectedChange: ReplaySubject<HTMLElement | undefined> = new ReplaySubject<\n\t\tHTMLElement | undefined\n\t>();\n\n\tget selectedChange$(): Observable<HTMLElement | undefined> {\n\t\treturn this.selectedChange.pipe(distinctUntilChanged());\n\t}\n\n\taddOrigin(origin: NgDocSelectionOriginDirective): void {\n\t\tthis.origins.add(origin);\n\t}\n\n\tremoveOrigin(origin: NgDocSelectionOriginDirective): void {\n\t\tthis.origins.delete(origin);\n\n\t\tif (this.selected === origin) {\n\t\t\tthis.changeSelected(origin, false);\n\t\t}\n\t}\n\n\tchangeSelected(origin: NgDocSelectionOriginDirective, selected: boolean): void {\n\t\tthis.selected =\n\t\t\tthis.selected === origin || selected ? (selected ? origin : undefined) : this.selected;\n\t\tthis.selectedChange.next(this.selected?.elementRef?.nativeElement ?? undefined);\n\t}\n}\n","import {\n AfterViewInit,\n ChangeDetectionStrategy,\n Component,\n DestroyRef,\n ElementRef,\n HostBinding,\n inject,\n Input,\n} from '@angular/core';\nimport { takeUntilDestroyed } from '@angular/core/rxjs-interop';\nimport { NgDocHorizontalAlign, NgDocPosition, NgDocVerticalAlign } from '@ng-doc/ui-kit/types';\nimport { debounceTime } from 'rxjs/operators';\n\nimport { NgDocSelectionHostDirective } from './selection-host.directive';\n\n@Component({\n selector: 'ng-doc-selection',\n template: '',\n styleUrls: ['./selection.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n standalone: true,\n})\nexport class NgDocSelectionComponent implements AfterViewInit {\n @Input()\n @HostBinding('attr.data-ng-doc-align')\n align: NgDocHorizontalAlign | NgDocVerticalAlign = 'bottom';\n\n private readonly destroyRef = inject(DestroyRef);\n\n constructor(\n private readonly elementRef: ElementRef<HTMLElement>,\n private readonly selectionHost: NgDocSelectionHostDirective,\n ) {}\n\n ngAfterViewInit(): void {\n this.selectionHost.selectedChange$\n .pipe(debounceTime(0), takeUntilDestroyed(this.destroyRef))\n .subscribe((selected: HTMLElement | undefined) => this.setStyles(selected));\n }\n\n private setStyles(element?: HTMLElement): void {\n this.elementRef.nativeElement.style.visibility = 'hidden';\n if (element) {\n const position: NgDocPosition = this.getPosition(element);\n\n if (this.align === 'left' || this.align === 'right') {\n this.elementRef.nativeElement.style.top = position.top;\n } else {\n this.elementRef.nativeElement.style.left = position.left;\n }\n\n this.elementRef.nativeElement.style.height = position.height;\n this.elementRef.nativeElement.style.width = position.width;\n this.elementRef.nativeElement.style.visibility = 'visible';\n }\n }\n\n private getPosition(element: HTMLElement): NgDocPosition {\n return {\n top: element ? `${element.offsetTop || 0}px` : '0',\n left: element ? `${element.offsetLeft || 0}px` : '0',\n width: element ? `${element.offsetWidth || 0}px` : '0',\n height: element ? `${element.offsetHeight || 0}px` : '0',\n };\n }\n}\n","import { Directive, ElementRef, Input, OnChanges, OnDestroy, SimpleChanges } from '@angular/core';\n\nimport { NgDocSelectionHostDirective } from './selection-host.directive';\n\n@Directive({\n\tselector: '[ngDocSelectionOrigin]',\n\tstandalone: true,\n})\nexport class NgDocSelectionOriginDirective implements OnChanges, OnDestroy {\n\t@Input('ngDocSelectionOrigin')\n\tselected: boolean = false;\n\n\tconstructor(\n\t\treadonly elementRef: ElementRef<HTMLElement>,\n\t\tprivate readonly selectionHost: NgDocSelectionHostDirective,\n\t) {\n\t\tthis.selectionHost.addOrigin(this);\n\t}\n\n\tngOnChanges({ selected }: SimpleChanges): void {\n\t\tif (selected) {\n\t\t\tthis.selectionHost.changeSelected(this, this.selected);\n\t\t}\n\t}\n\n\tngOnDestroy(): void {\n\t\tthis.selectionHost.removeOrigin(this);\n\t}\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["i1.NgDocSelectionHostDirective"],"mappings":";;;;;;MAUa,2BAA2B,CAAA;AAJxC,IAAA,WAAA,GAAA;AAKS,QAAA,IAAA,CAAA,OAAO,GAAuC,IAAI,GAAG,EAAiC;AAEtF,QAAA,IAAA,CAAA,cAAc,GAA2C,IAAI,aAAa,EAE/E;AAuBH;AArBA,IAAA,IAAI,eAAe,GAAA;QAClB,OAAO,IAAI,CAAC,cAAc,CAAC,IAAI,CAAC,oBAAoB,EAAE,CAAC;;AAGxD,IAAA,SAAS,CAAC,MAAqC,EAAA;AAC9C,QAAA,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,MAAM,CAAC;;AAGzB,IAAA,YAAY,CAAC,MAAqC,EAAA;AACjD,QAAA,IAAI,CAAC,OAAO,CAAC,MAAM,CAAC,MAAM,CAAC;AAE3B,QAAA,IAAI,IAAI,CAAC,QAAQ,KAAK,MAAM,EAAE;AAC7B,YAAA,IAAI,CAAC,cAAc,CAAC,MAAM,EAAE,KAAK,CAAC;;;IAIpC,cAAc,CAAC,MAAqC,EAAE,QAAiB,EAAA;AACtE,QAAA,IAAI,CAAC,QAAQ;YACZ,IAAI,CAAC,QAAQ,KAAK,MAAM,IAAI,QAAQ,IAAI,QAAQ,GAAG,MAAM,GAAG,SAAS,IAAI,IAAI,CAAC,QAAQ;AACvF,QAAA,IAAI,CAAC,cAAc,CAAC,I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sBAAA,EAAA,UAAA,CAAA,EAAA,EAAA,aAAA,EAAA,IAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA,CAAA;;2FAA7B,6BAA6B,EAAA,UAAA,EAAA,CAAA;kBAJzC,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACV,oBAAA,QAAQ,EAAE,wBAAwB;AAClC,oBAAA,UAAU,EAAE,IAAI;AAChB,iBAAA;sHAGA,QAAQ,EAAA,CAAA;sBADP,KAAK;uBAAC,sBAAsB;;;ACT9B;;AAEG;;;;"}
|
|
@@ -1,8 +1,6 @@
|
|
|
1
1
|
import { trigger, transition, style, animate } from '@angular/animations';
|
|
2
|
-
import { NgIf, AsyncPipe } from '@angular/common';
|
|
3
2
|
import * as i0 from '@angular/core';
|
|
4
3
|
import { EventEmitter, Component, ChangeDetectionStrategy, Input, HostBinding, Output } from '@angular/core';
|
|
5
|
-
import { NgDocLetDirective } from '@ng-doc/ui-kit/directives';
|
|
6
4
|
import * as i1 from '@tinkoff/ng-polymorpheus';
|
|
7
5
|
import { PolymorpheusModule } from '@tinkoff/ng-polymorpheus';
|
|
8
6
|
|
|
@@ -42,7 +40,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.3", ngImpor
|
|
|
42
40
|
animate('220ms cubic-bezier(0.25, 0.8, 0.25, 1)', style({ opacity: 1 })),
|
|
43
41
|
]),
|
|
44
42
|
]),
|
|
45
|
-
], selector: 'ng-doc-sidenav', changeDetection: ChangeDetectionStrategy.OnPush, imports: [PolymorpheusModule
|
|
43
|
+
], selector: 'ng-doc-sidenav', changeDetection: ChangeDetectionStrategy.OnPush, imports: [PolymorpheusModule], host: {
|
|
46
44
|
'[attr.data-ng-doc-sidebar]': '!!sidebar',
|
|
47
45
|
}, template: "<div class=\"ng-doc-sidenav-wrapper\">\n <div class=\"ng-doc-sidenav\">\n <ng-container *polymorpheusOutlet=\"sidebar\"></ng-container>\n </div>\n <div class=\"ng-doc-sidenav-content\">\n @if (opened && hasBackdrop) {\n <div class=\"ng-doc-backdrop\" @backdropFade (click)=\"closeEvent.emit()\"></div>\n }\n\n <ng-content></ng-content>\n </div>\n</div>\n", styles: [":host{width:100%}:host[data-ng-doc-sidebar=false] .ng-doc-sidenav-content{margin-left:0;width:100%}:host .ng-doc-sidenav-wrapper{position:relative;display:flex;width:100%}:host .ng-doc-sidenav{position:fixed;top:var(--ng-doc-navbar-height);width:var(--ng-doc-sidenav-width);flex-shrink:0;z-index:10;transition:left var(--ng-doc-transition)}:host .ng-doc-sidenav-content{margin-left:var(--ng-doc-sidenav-width);width:calc(100% - var(--ng-doc-sidenav-width));padding:var(--ng-doc-sidenav-content-padding);transition:margin-left var(--ng-doc-transition)}:host .ng-doc-backdrop{position:fixed!important;left:0;top:0;width:100%;height:100%;z-index:9}:host .ng-doc-backdrop:not(nothing){background:color-mix(in srgb,rgba(0,0,0,.2) 60%,transparent);-webkit-backdrop-filter:blur(20px);backdrop-filter:blur(20px)}@supports not ((-webkit-backdrop-filter: none) or (backdrop-filter: none)){:host .ng-doc-backdrop{background-color:#0003}}:host .ng-doc-backdropnothing{background-color:#0003}@media (max-width: 1024px){:host[data-ng-doc-opened=true] .ng-doc-sidenav{right:0;transition:right var(--ng-doc-transition);--ng-doc-sidebar-shadow: var(--ng-doc-shadow-color) -5px 5px 20px -5px}:host .ng-doc-sidenav{transition:unset;left:unset;right:calc(var(--ng-doc-sidenav-width) * -1);top:var(--ng-doc-navbar-height)}:host .ng-doc-sidenav-content{margin-left:0;width:100%}}\n"] }]
|
|
48
46
|
}], propDecorators: { sidebar: [{
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ng-doc-ui-kit-components-sidenav.mjs","sources":["../../../../libs/ui-kit/components/sidenav/sidenav.component.ts","../../../../libs/ui-kit/components/sidenav/sidenav.component.html","../../../../libs/ui-kit/components/sidenav/ng-doc-ui-kit-components-sidenav.ts"],"sourcesContent":["import { animate, style, transition, trigger } from '@angular/animations';\nimport {
|
|
1
|
+
{"version":3,"file":"ng-doc-ui-kit-components-sidenav.mjs","sources":["../../../../libs/ui-kit/components/sidenav/sidenav.component.ts","../../../../libs/ui-kit/components/sidenav/sidenav.component.html","../../../../libs/ui-kit/components/sidenav/ng-doc-ui-kit-components-sidenav.ts"],"sourcesContent":["import { animate, style, transition, trigger } from '@angular/animations';\nimport {\n ChangeDetectionStrategy,\n Component,\n EventEmitter,\n HostBinding,\n Input,\n Output,\n} from '@angular/core';\nimport { NgDocContent } from '@ng-doc/ui-kit/types';\nimport { PolymorpheusModule } from '@tinkoff/ng-polymorpheus';\n\n@Component({\n animations: [\n trigger('backdropFade', [\n transition(':enter', [\n style({ opacity: 0 }),\n animate('220ms cubic-bezier(0.25, 0.8, 0.25, 1)', style({ opacity: 1 })),\n ]),\n ]),\n ],\n selector: 'ng-doc-sidenav',\n templateUrl: './sidenav.component.html',\n styleUrls: ['./sidenav.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n imports: [PolymorpheusModule],\n host: {\n '[attr.data-ng-doc-sidebar]': '!!sidebar',\n },\n})\nexport class NgDocSidenavComponent {\n /**\n * Content of the sidenav.\n */\n @Input()\n sidebar: NgDocContent = '';\n\n /**\n * Indicates whether the sidenav is opened or not.\n * This is used to trigger the animation.\n */\n @Input()\n @HostBinding('attr.data-ng-doc-opened')\n opened: boolean = true;\n\n /**\n * Indicates whether the sidenav has a backdrop or not.\n */\n @Input()\n hasBackdrop: boolean = true;\n\n @Output()\n closeEvent: EventEmitter<void> = new EventEmitter<void>();\n}\n","<div class=\"ng-doc-sidenav-wrapper\">\n <div class=\"ng-doc-sidenav\">\n <ng-container *polymorpheusOutlet=\"sidebar\"></ng-container>\n </div>\n <div class=\"ng-doc-sidenav-content\">\n @if (opened && hasBackdrop) {\n <div class=\"ng-doc-backdrop\" @backdropFade (click)=\"closeEvent.emit()\"></div>\n }\n\n <ng-content></ng-content>\n </div>\n</div>\n","/**\n * Generated bundle index. Do not edit.\n */\n\nex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C,QAAQ,EAAE;AACnB,oBAAA,KAAK,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE,CAAC;oBACrB,OAAO,CAAC,wCAAwC,EAAE,KAAK,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE,CAAC,CAAC;iBACzE,CAAC;aACH,CAAC;AACH,SAAA,EAAA,eAAA,EAAA,EAAA,CAAA,uBAAA,CAAA,MAAA,EAAA,CAAA,CAAA;;2FAUU,qBAAqB,EAAA,UAAA,EAAA,CAAA;kBAlBjC,SAAS;AACI,YAAA,IAAA,EAAA,CAAA,EAAA,UAAA,EAAA;wBACV,OAAO,CAAC,cAAc,EAAE;4BACtB,UAAU,CAAC,QAAQ,EAAE;AACnB,gCAAA,KAAK,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE,CAAC;gCACrB,OAAO,CAAC,wCAAwC,EAAE,KAAK,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE,CAAC,CAAC;6BACzE,CAAC;yBACH,CAAC;qBACH,EACS,QAAA,EAAA,gBAAgB,mBAGT,uBAAuB,CAAC,MAAM,EACtC,OAAA,EAAA,CAAC,kBAAkB,CAAC,EACvB,IAAA,EAAA;AACJ,wBAAA,4BAA4B,EAAE,WAAW;AAC1C,qBAAA,EAAA,QAAA,EAAA,yXAAA,EAAA,MAAA,EAAA,CAAA,i1CAAA,CAAA,EAAA;8BAOD,OAAO,EAAA,CAAA;sBADN;gBASD,MAAM,EAAA,CAAA;sBAFL;;sBACA,WAAW;uBAAC,yBAAyB;gBAOtC,WAAW,EAAA,CAAA;sBADV;gBAID,UAAU,EAAA,CAAA;sBADT;;;AEnDH;;AAEG;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ng-doc-ui-kit-components-smooth-resize.mjs","sources":["../../../../libs/ui-kit/components/smooth-resize/smooth-resize.component.ts","../../../../libs/ui-kit/components/smooth-resize/ng-doc-ui-kit-components-smooth-resize.ts"],"sourcesContent":["import { animate, style, transition, trigger } from '@angular/animations';\nimport {\n
|
|
1
|
+
{"version":3,"file":"ng-doc-ui-kit-components-smooth-resize.mjs","sources":["../../../../libs/ui-kit/components/smooth-resize/smooth-resize.component.ts","../../../../libs/ui-kit/components/smooth-resize/ng-doc-ui-kit-components-smooth-resize.ts"],"sourcesContent":["import { animate, style, transition, trigger } from '@angular/animations';\nimport {\n ChangeDetectionStrategy,\n Component,\n ElementRef,\n HostBinding,\n Input,\n OnChanges,\n} from '@angular/core';\n\n@Component({\n animations: [\n trigger('resizeAnimation', [\n transition('void <=> *', []),\n transition('* <=> *', [\n style({ height: '{{startHeight}}px', width: '{{startWidth}}px' }),\n animate('.225s ease-in-out'),\n ]),\n ]),\n ],\n selector: 'ng-doc-smooth-resize',\n template: ` <ng-content></ng-content>`,\n styles: [\n `\n :host {\n display: block;\n overflow: hidden;\n height: var(--ng-doc-smooth-resize-height);\n max-height: var(--ng-doc-smooth-resize-max-height);\n }\n `,\n ],\n changeDetection: ChangeDetectionStrategy.OnPush,\n standalone: true,\n})\nexport class NgDocSmoothResizeComponent implements OnChanges {\n @Input({ required: true })\n trigger: unknown;\n\n @Input()\n animateOpacity: boolean = true;\n\n @HostBinding('@resizeAnimation')\n resizeAnimation?: {\n value: unknown;\n params: { startHeight: number; startWidth: number };\n } = {\n value: 0,\n params: { startHeight: 0, startWidth: 0 },\n };\n\n constructor(private readonly element: ElementRef<HTMLElement>) {}\n\n ngOnChanges(): void {\n this.resizeAnimation = {\n value: this.trigger,\n params: {\n startHeight: this.element.nativeElement.clientHeight || 0,\n startWidth: this.element.nativeElement.clientWidth || 0,\n },\n };\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;MAmCa,0BAA0B,CAAA;AAgBrC,IAAA,WAAA,CAA6B,OAAgC,EAAA;QAAhC,IAAO,CAAA,OAAA,GAAP,OAAO;QAXpC,IAAc,CAAA,cAAA,GAAY,IAAI;AAG9B,QAAA,IAAA,CAAA,eAAe,GAGX;A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