@taiga-ui/addon-doc 3.26.0 → 3.27.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/bundles/taiga-ui-addon-doc-components.umd.js +5 -5
- package/bundles/taiga-ui-addon-doc-components.umd.js.map +1 -1
- package/bundles/taiga-ui-addon-doc-directives.umd.js +39 -0
- package/bundles/taiga-ui-addon-doc-directives.umd.js.map +1 -1
- package/components/documentation/documentation.component.d.ts +1 -1
- package/components/documentation/documentation.module.d.ts +1 -1
- package/directives/index.d.ts +2 -0
- package/directives/text-code/text-code.directive.d.ts +6 -0
- package/directives/text-code/text-code.module.d.ts +7 -0
- package/esm2015/components/documentation/documentation.component.js +3 -3
- package/esm2015/components/documentation/documentation.module.js +5 -5
- package/esm2015/directives/index.js +3 -1
- package/esm2015/directives/text-code/text-code.directive.js +22 -0
- package/esm2015/directives/text-code/text-code.module.js +16 -0
- package/fesm2015/taiga-ui-addon-doc-components.js +6 -6
- package/fesm2015/taiga-ui-addon-doc-components.js.map +1 -1
- package/fesm2015/taiga-ui-addon-doc-directives.js +35 -2
- package/fesm2015/taiga-ui-addon-doc-directives.js.map +1 -1
- package/package.json +5 -5
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import { ElementRef, Directive, Self, Inject, Input, NgModule } from '@angular/core';
|
|
2
|
+
import { ElementRef, Directive, Self, Inject, Input, NgModule, HostBinding } from '@angular/core';
|
|
3
3
|
import { TUI_DOC_PAGE_LOADED } from '@taiga-ui/addon-doc/tokens';
|
|
4
4
|
import * as i1 from '@taiga-ui/cdk';
|
|
5
5
|
import { tuiGetElementObscures, TuiDestroyService } from '@taiga-ui/cdk';
|
|
@@ -57,9 +57,42 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImpo
|
|
|
57
57
|
}]
|
|
58
58
|
}] });
|
|
59
59
|
|
|
60
|
+
class TuiTextCodeDirective {
|
|
61
|
+
constructor() {
|
|
62
|
+
this.code = '';
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
TuiTextCodeDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: TuiTextCodeDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
66
|
+
TuiTextCodeDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.2.17", type: TuiTextCodeDirective, selector: "code[tuiText]", inputs: { code: ["tuiText", "code"] }, host: { properties: { "textContent": "this.code" } }, ngImport: i0 });
|
|
67
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: TuiTextCodeDirective, decorators: [{
|
|
68
|
+
type: Directive,
|
|
69
|
+
args: [{
|
|
70
|
+
selector: 'code[tuiText]',
|
|
71
|
+
}]
|
|
72
|
+
}], propDecorators: { code: [{
|
|
73
|
+
type: Input,
|
|
74
|
+
args: ['tuiText']
|
|
75
|
+
}, {
|
|
76
|
+
type: HostBinding,
|
|
77
|
+
args: ['textContent']
|
|
78
|
+
}] } });
|
|
79
|
+
|
|
80
|
+
class TuiTextCodeModule {
|
|
81
|
+
}
|
|
82
|
+
TuiTextCodeModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: TuiTextCodeModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
83
|
+
TuiTextCodeModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: TuiTextCodeModule, declarations: [TuiTextCodeDirective], exports: [TuiTextCodeDirective] });
|
|
84
|
+
TuiTextCodeModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: TuiTextCodeModule });
|
|
85
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: TuiTextCodeModule, decorators: [{
|
|
86
|
+
type: NgModule,
|
|
87
|
+
args: [{
|
|
88
|
+
declarations: [TuiTextCodeDirective],
|
|
89
|
+
exports: [TuiTextCodeDirective],
|
|
90
|
+
}]
|
|
91
|
+
}] });
|
|
92
|
+
|
|
60
93
|
/**
|
|
61
94
|
* Generated bundle index. Do not edit.
|
|
62
95
|
*/
|
|
63
96
|
|
|
64
|
-
export { TuiScrollIntoViewLinkDirective, TuiScrollIntoViewLinkModule };
|
|
97
|
+
export { TuiScrollIntoViewLinkDirective, TuiScrollIntoViewLinkModule, TuiTextCodeDirective, TuiTextCodeModule };
|
|
65
98
|
//# sourceMappingURL=taiga-ui-addon-doc-directives.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"taiga-ui-addon-doc-directives.js","sources":["../../../projects/addon-doc/directives/scroll-into-view/scroll-into-view.directive.ts","../../../projects/addon-doc/directives/scroll-into-view/scroll-into-view.module.ts","../../../projects/addon-doc/directives/taiga-ui-addon-doc-directives.ts"],"sourcesContent":["import {Directive, ElementRef, Inject, Input, Self} from '@angular/core';\nimport {TUI_DOC_PAGE_LOADED} from '@taiga-ui/addon-doc/tokens';\nimport {TuiDestroyService, tuiGetElementObscures} from '@taiga-ui/cdk';\nimport {Observable, ReplaySubject} from 'rxjs';\nimport {debounceTime, filter, switchMap, takeUntil} from 'rxjs/operators';\n\n@Directive({\n selector: '[tuiScrollIntoViewLink]',\n providers: [TuiDestroyService],\n})\nexport class TuiScrollIntoViewLinkDirective {\n @Input()\n set tuiScrollIntoViewLink(shallWe: boolean) {\n this.scroll$.next(shallWe);\n }\n\n private readonly scroll$ = new ReplaySubject<boolean>(1);\n\n constructor(\n @Self() @Inject(TuiDestroyService) destroy$: TuiDestroyService,\n @Inject(ElementRef) {nativeElement}: ElementRef<HTMLElement>,\n @Inject(TUI_DOC_PAGE_LOADED)\n readonly readyToScroll$: Observable<boolean>,\n ) {\n this.readyToScroll$\n .pipe(\n filter(Boolean),\n switchMap(() => this.scroll$),\n debounceTime(750),\n filter(shallWe => shallWe && !!tuiGetElementObscures(nativeElement)),\n takeUntil(destroy$),\n )\n .subscribe(() => {\n nativeElement.scrollIntoView();\n });\n }\n}\n","import {NgModule} from '@angular/core';\n\nimport {TuiScrollIntoViewLinkDirective} from './scroll-into-view.directive';\n\n@NgModule({\n declarations: [TuiScrollIntoViewLinkDirective],\n exports: [TuiScrollIntoViewLinkDirective],\n})\nexport class TuiScrollIntoViewLinkModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;MAUa,8BAA8B,CAAA;AAQvC,IAAA,WAAA,CACuC,QAA2B,EAC1C,EAAC,aAAa,EAA0B,EAEnD,cAAmC,EAAA;QAAnC,IAAc,CAAA,cAAA,GAAd,cAAc,CAAqB;AAN/B,QAAA,IAAA,CAAA,OAAO,GAAG,IAAI,aAAa,CAAU,CAAC,CAAC,CAAC;AAQrD,QAAA,IAAI,CAAC,cAAc;AACd,aAAA,IAAI,CACD,MAAM,CAAC,OAAO,CAAC,EACf,SAAS,CAAC,MAAM,IAAI,CAAC,OAAO,CAAC,EAC7B,YAAY,CAAC,GAAG,CAAC,EACjB,MAAM,CAAC,OAAO,IAAI,OAAO,IAAI,CAAC,CAAC,qBAAqB,CAAC,aAAa,CAAC,CAAC,EACpE,SAAS,CAAC,QAAQ,CAAC,CACtB;aACA,SAAS,CAAC,MAAK;YACZ,aAAa,CAAC,cAAc,EAAE,CAAC;AACnC,SAAC,CAAC,CAAC;KACV;IAxBD,IACI,qBAAqB,CAAC,OAAgB,EAAA;AACtC,QAAA,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;KAC9B;;AAJQ,8BAAA,CAAA,IAAA,GAAA,EAAA,CAAA,kBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EA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"version":3,"file":"taiga-ui-addon-doc-directives.js","sources":["../../../projects/addon-doc/directives/scroll-into-view/scroll-into-view.directive.ts","../../../projects/addon-doc/directives/scroll-into-view/scroll-into-view.module.ts","../../../projects/addon-doc/directives/text-code/text-code.directive.ts","../../../projects/addon-doc/directives/text-code/text-code.module.ts","../../../projects/addon-doc/directives/taiga-ui-addon-doc-directives.ts"],"sourcesContent":["import {Directive, ElementRef, Inject, Input, Self} from '@angular/core';\nimport {TUI_DOC_PAGE_LOADED} from '@taiga-ui/addon-doc/tokens';\nimport {TuiDestroyService, tuiGetElementObscures} from '@taiga-ui/cdk';\nimport {Observable, ReplaySubject} from 'rxjs';\nimport {debounceTime, filter, switchMap, takeUntil} from 'rxjs/operators';\n\n@Directive({\n selector: '[tuiScrollIntoViewLink]',\n providers: [TuiDestroyService],\n})\nexport class TuiScrollIntoViewLinkDirective {\n @Input()\n set tuiScrollIntoViewLink(shallWe: boolean) {\n this.scroll$.next(shallWe);\n }\n\n private readonly scroll$ = new ReplaySubject<boolean>(1);\n\n constructor(\n @Self() @Inject(TuiDestroyService) destroy$: TuiDestroyService,\n @Inject(ElementRef) {nativeElement}: ElementRef<HTMLElement>,\n @Inject(TUI_DOC_PAGE_LOADED)\n readonly readyToScroll$: Observable<boolean>,\n ) {\n this.readyToScroll$\n .pipe(\n filter(Boolean),\n switchMap(() => this.scroll$),\n debounceTime(750),\n filter(shallWe => shallWe && !!tuiGetElementObscures(nativeElement)),\n takeUntil(destroy$),\n )\n .subscribe(() => {\n nativeElement.scrollIntoView();\n });\n }\n}\n","import {NgModule} from '@angular/core';\n\nimport {TuiScrollIntoViewLinkDirective} from './scroll-into-view.directive';\n\n@NgModule({\n declarations: [TuiScrollIntoViewLinkDirective],\n exports: [TuiScrollIntoViewLinkDirective],\n})\nexport class TuiScrollIntoViewLinkModule {}\n","import {Directive, HostBinding, Input} from '@angular/core';\n\n@Directive({\n selector: 'code[tuiText]',\n})\nexport class TuiTextCodeDirective {\n @Input('tuiText')\n @HostBinding('textContent')\n code = '';\n}\n","import {NgModule} from '@angular/core';\n\nimport {TuiTextCodeDirective} from './text-code.directive';\n\n@NgModule({\n declarations: [TuiTextCodeDirective],\n exports: [TuiTextCodeDirective],\n})\nexport class TuiTextCodeModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;MAUa,8BAA8B,CAAA;AAQvC,IAAA,WAAA,CACuC,QAA2B,EAC1C,EAAC,aAAa,EAA0B,EAEnD,cAAmC,EAAA;QAAnC,IAAc,CAAA,cAAA,GAAd,cAAc,CAAqB;AAN/B,QAAA,IAAA,CAAA,OAAO,GAAG,IAAI,aAAa,CAAU,CAAC,CAAC,CAAC;AAQrD,QAAA,IAAI,CAAC,cAAc;AACd,aAAA,IAAI,CACD,MAAM,CAAC,OAAO,CAAC,EACf,SAAS,CAAC,MAAM,IAAI,CAAC,OAAO,CAAC,EAC7B,YAAY,CAAC,GAAG,CAAC,EACjB,MAAM,CAAC,OAAO,IAAI,OAAO,IAAI,CAAC,CAAC,qBAAqB,CAAC,aAAa,CAAC,CAAC,EACpE,SAAS,CAAC,QAAQ,CAAC,CACtB;aACA,SAAS,CAAC,MAAK;YACZ,aAAa,CAAC,cAAc,EAAE,CAAC;AACnC,SAAC,CAAC,CAAC;KACV;IAxBD,IACI,qBAAqB,CAAC,OAAgB,EAAA;AACtC,QAAA,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;KAC9B;;AAJQ,8BAAA,CAAA,IAAA,GAAA,EAAA,CAAA,kBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,8BAA8B,EASnB,IAAA,EAAA,CAAA,EAAA,KAAA,EAAA,iBAAiB,EACzB,IAAA,EAAA,IAAA,EAAA,EAAA,EAAA,KAAA,EAAA,UAAU,aACV,mBAAmB,EAAA,CAAA,EAAA,M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AAA,CAAA,CAAA;sGAApB,oBAAoB,EAAA,QAAA,EAAA,eAAA,EAAA,MAAA,EAAA,EAAA,IAAA,EAAA,CAAA,SAAA,EAAA,MAAA,CAAA,EAAA,EAAA,IAAA,EAAA,EAAA,UAAA,EAAA,EAAA,aAAA,EAAA,WAAA,EAAA,EAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA,CAAA;4FAApB,oBAAoB,EAAA,UAAA,EAAA,CAAA;kBAHhC,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACP,oBAAA,QAAQ,EAAE,eAAe;AAC5B,iBAAA,CAAA;8BAIG,IAAI,EAAA,CAAA;sBAFH,KAAK;uBAAC,SAAS,CAAA;;sBACf,WAAW;uBAAC,aAAa,CAAA;;;MCCjB,iBAAiB,CAAA;;+GAAjB,iBAAiB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA,CAAA;gHAAjB,iBAAiB,EAAA,YAAA,EAAA,CAHX,oBAAoB,CAAA,EAAA,OAAA,EAAA,CACzB,oBAAoB,CAAA,EAAA,CAAA,CAAA;gHAErB,iBAAiB,EAAA,CAAA,CAAA;4FAAjB,iBAAiB,EAAA,UAAA,EAAA,CAAA;kBAJ7B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;oBACN,YAAY,EAAE,CAAC,oBAAoB,CAAC;oBACpC,OAAO,EAAE,CAAC,oBAAoB,CAAC;AAClC,iBAAA,CAAA;;;ACPD;;AAEG;;;;"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@taiga-ui/addon-doc",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.27.0",
|
|
4
4
|
"description": "Taiga UI based library for developing documentation portals for Angular libraries.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"angular",
|
|
@@ -27,10 +27,10 @@
|
|
|
27
27
|
"@angular/forms": ">=12.0.0",
|
|
28
28
|
"@angular/router": ">=12.0.0",
|
|
29
29
|
"@ng-web-apis/common": ">=2.0.0",
|
|
30
|
-
"@taiga-ui/addon-mobile": ">=3.
|
|
31
|
-
"@taiga-ui/cdk": ">=3.
|
|
32
|
-
"@taiga-ui/core": ">=3.
|
|
33
|
-
"@taiga-ui/kit": ">=3.
|
|
30
|
+
"@taiga-ui/addon-mobile": ">=3.27.0",
|
|
31
|
+
"@taiga-ui/cdk": ">=3.27.0",
|
|
32
|
+
"@taiga-ui/core": ">=3.27.0",
|
|
33
|
+
"@taiga-ui/kit": ">=3.27.0",
|
|
34
34
|
"@tinkoff/ng-polymorpheus": ">=4.0.0"
|
|
35
35
|
},
|
|
36
36
|
"main": "bundles/taiga-ui-addon-doc.umd.js",
|