@myrmidon/cadmus-graph-ui-ex 16.0.0 → 16.1.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.
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import {
|
|
2
|
+
import { input, output, effect, ViewChild, ChangeDetectionStrategy, Component, model, Pipe, signal } from '@angular/core';
|
|
3
3
|
import { Subject, forkJoin, from, BehaviorSubject, Observable, take as take$1 } from 'rxjs';
|
|
4
4
|
import { takeUntil, take } from 'rxjs/operators';
|
|
5
|
-
import { CommonModule, AsyncPipe } from '@angular/common';
|
|
6
5
|
import * as i1 from '@angular/material/button';
|
|
7
6
|
import { MatButtonModule, MatIconButton } from '@angular/material/button';
|
|
8
7
|
import * as i2 from '@angular/material/icon';
|
|
@@ -13,6 +12,7 @@ import * as ForceGraph from 'force-graph';
|
|
|
13
12
|
import * as ForceGraph3D from '3d-force-graph';
|
|
14
13
|
import * as d3 from 'd3-force';
|
|
15
14
|
import * as THREE from 'three';
|
|
15
|
+
import { AsyncPipe } from '@angular/common';
|
|
16
16
|
import { MatProgressBar } from '@angular/material/progress-bar';
|
|
17
17
|
import { MatTabGroup, MatTab, MatTabLabel } from '@angular/material/tabs';
|
|
18
18
|
import * as i1$1 from '@angular/forms';
|
|
@@ -36,35 +36,41 @@ import * as i1$2 from '@myrmidon/ngx-mat-tools';
|
|
|
36
36
|
*/
|
|
37
37
|
class ForceGraphRendererComponent {
|
|
38
38
|
graphContainer;
|
|
39
|
-
nodes = [];
|
|
40
|
-
edges = [];
|
|
41
|
-
mode = '2d';
|
|
42
|
-
update
|
|
43
|
-
center
|
|
44
|
-
zoomToFit
|
|
45
|
-
nodeSelect =
|
|
46
|
-
nodeDoubleClick =
|
|
47
|
-
modeChange =
|
|
39
|
+
nodes = input([], ...(ngDevMode ? [{ debugName: "nodes" }] : []));
|
|
40
|
+
edges = input([], ...(ngDevMode ? [{ debugName: "edges" }] : []));
|
|
41
|
+
mode = input('2d', ...(ngDevMode ? [{ debugName: "mode" }] : []));
|
|
42
|
+
update$ = input(...(ngDevMode ? [undefined, { debugName: "update$" }] : []));
|
|
43
|
+
center$ = input(...(ngDevMode ? [undefined, { debugName: "center$" }] : []));
|
|
44
|
+
zoomToFit$ = input(...(ngDevMode ? [undefined, { debugName: "zoomToFit$" }] : []));
|
|
45
|
+
nodeSelect = output();
|
|
46
|
+
nodeDoubleClick = output();
|
|
47
|
+
modeChange = output();
|
|
48
48
|
graph = null;
|
|
49
49
|
currentMode = '2d';
|
|
50
50
|
clickTimeout = null;
|
|
51
51
|
resizeObserver;
|
|
52
52
|
destroy$ = new Subject();
|
|
53
|
-
|
|
54
|
-
|
|
53
|
+
constructor() {
|
|
54
|
+
// React to mode changes after graph initialization
|
|
55
|
+
effect(() => {
|
|
56
|
+
const m = this.mode();
|
|
57
|
+
if (!this.graph)
|
|
58
|
+
return;
|
|
59
|
+
this.switchMode(m);
|
|
60
|
+
});
|
|
61
|
+
// React to data changes after graph initialization
|
|
62
|
+
effect(() => {
|
|
63
|
+
// Register signal dependencies
|
|
64
|
+
this.nodes();
|
|
65
|
+
this.edges();
|
|
66
|
+
this.updateGraphData();
|
|
67
|
+
});
|
|
55
68
|
}
|
|
56
69
|
ngAfterViewInit() {
|
|
70
|
+
this.currentMode = this.mode();
|
|
57
71
|
this.initGraph();
|
|
58
72
|
this.setupSubscriptions();
|
|
59
73
|
}
|
|
60
|
-
ngOnChanges(changes) {
|
|
61
|
-
if (changes['mode'] && !changes['mode'].firstChange) {
|
|
62
|
-
this.switchMode(this.mode);
|
|
63
|
-
}
|
|
64
|
-
if ((changes['nodes'] || changes['edges']) && this.graph) {
|
|
65
|
-
this.updateGraphData();
|
|
66
|
-
}
|
|
67
|
-
}
|
|
68
74
|
ngOnDestroy() {
|
|
69
75
|
this.destroy$.next();
|
|
70
76
|
this.destroy$.complete();
|
|
@@ -162,7 +168,7 @@ class ForceGraphRendererComponent {
|
|
|
162
168
|
this.resizeObserver.observe(container);
|
|
163
169
|
}
|
|
164
170
|
convertToForceGraphData() {
|
|
165
|
-
const forceNodes = this.nodes.map((node) => {
|
|
171
|
+
const forceNodes = this.nodes().map((node) => {
|
|
166
172
|
const label = node.label || String(node.id);
|
|
167
173
|
const count = node.data?.count;
|
|
168
174
|
const displayName = count ? `${label} (${count})` : label;
|
|
@@ -175,7 +181,7 @@ class ForceGraphRendererComponent {
|
|
|
175
181
|
__nodeData: node,
|
|
176
182
|
};
|
|
177
183
|
});
|
|
178
|
-
const forceLinks = this.edges.map((edge) => {
|
|
184
|
+
const forceLinks = this.edges().map((edge) => {
|
|
179
185
|
const label = edge.label || edge.data?.label || '';
|
|
180
186
|
return {
|
|
181
187
|
source: edge.source,
|
|
@@ -461,18 +467,21 @@ class ForceGraphRendererComponent {
|
|
|
461
467
|
this.nodeSelect.emit(null);
|
|
462
468
|
}
|
|
463
469
|
setupSubscriptions() {
|
|
464
|
-
|
|
465
|
-
|
|
470
|
+
const update$ = this.update$();
|
|
471
|
+
if (update$) {
|
|
472
|
+
update$.pipe(takeUntil(this.destroy$)).subscribe(() => {
|
|
466
473
|
this.updateGraphData();
|
|
467
474
|
});
|
|
468
475
|
}
|
|
469
|
-
|
|
470
|
-
|
|
476
|
+
const center$ = this.center$();
|
|
477
|
+
if (center$) {
|
|
478
|
+
center$.pipe(takeUntil(this.destroy$)).subscribe(() => {
|
|
471
479
|
this.centerView();
|
|
472
480
|
});
|
|
473
481
|
}
|
|
474
|
-
|
|
475
|
-
|
|
482
|
+
const zoomToFit$ = this.zoomToFit$();
|
|
483
|
+
if (zoomToFit$) {
|
|
484
|
+
zoomToFit$.pipe(takeUntil(this.destroy$)).subscribe(() => {
|
|
476
485
|
this.zoomToFit();
|
|
477
486
|
});
|
|
478
487
|
}
|
|
@@ -532,7 +541,7 @@ class ForceGraphRendererComponent {
|
|
|
532
541
|
const label = nodeData.label || String(nodeData.id);
|
|
533
542
|
const count = nodeData.data?.count;
|
|
534
543
|
// Get incoming link labels
|
|
535
|
-
const incomingLinks = this.edges.filter((edge) => edge.target === nodeData.id);
|
|
544
|
+
const incomingLinks = this.edges().filter((edge) => edge.target === nodeData.id);
|
|
536
545
|
const linkLabels = incomingLinks
|
|
537
546
|
.map((edge) => edge.label || edge.data?.label)
|
|
538
547
|
.filter((label) => label) // Remove empty labels
|
|
@@ -615,17 +624,19 @@ class ForceGraphRendererComponent {
|
|
|
615
624
|
sprite.scale.set(canvas.width / 4, canvas.height / 4, 1);
|
|
616
625
|
return sprite;
|
|
617
626
|
}
|
|
618
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
619
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "
|
|
627
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: ForceGraphRendererComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
628
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "21.2.0", type: ForceGraphRendererComponent, isStandalone: true, selector: "cadmus-force-graph-renderer", inputs: { nodes: { classPropertyName: "nodes", publicName: "nodes", isSignal: true, isRequired: false, transformFunction: null }, edges: { classPropertyName: "edges", publicName: "edges", isSignal: true, isRequired: false, transformFunction: null }, mode: { classPropertyName: "mode", publicName: "mode", isSignal: true, isRequired: false, transformFunction: null }, update$: { classPropertyName: "update$", publicName: "update$", isSignal: true, isRequired: false, transformFunction: null }, center$: { classPropertyName: "center$", publicName: "center$", isSignal: true, isRequired: false, transformFunction: null }, zoomToFit$: { classPropertyName: "zoomToFit$", publicName: "zoomToFit$", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { nodeSelect: "nodeSelect", nodeDoubleClick: "nodeDoubleClick", modeChange: "modeChange" }, viewQueries: [{ propertyName: "graphContainer", first: true, predicate: ["graphContainer"], descendants: true, static: true }], ngImport: i0, template: `
|
|
620
629
|
<div class="renderer-container">
|
|
621
630
|
<div class="controls">
|
|
622
631
|
<button
|
|
623
632
|
type="button"
|
|
624
633
|
mat-icon-button
|
|
625
|
-
matTooltip="Switch to {{ mode === '2d' ? '3D' : '2D' }} view"
|
|
634
|
+
matTooltip="Switch to {{ mode() === '2d' ? '3D' : '2D' }} view"
|
|
626
635
|
(click)="toggleMode()"
|
|
627
636
|
>
|
|
628
|
-
<mat-icon>{{
|
|
637
|
+
<mat-icon>{{
|
|
638
|
+
mode() === '2d' ? 'view_in_ar' : 'view_quilt'
|
|
639
|
+
}}</mat-icon>
|
|
629
640
|
</button>
|
|
630
641
|
<button
|
|
631
642
|
type="button"
|
|
@@ -646,9 +657,9 @@ class ForceGraphRendererComponent {
|
|
|
646
657
|
</div>
|
|
647
658
|
<div #graphContainer class="graph-container"></div>
|
|
648
659
|
</div>
|
|
649
|
-
`, isInline: true, styles: [".renderer-container{width:100%;height:100%;min-height:600px;position:relative;display:flex;flex-direction:column}.controls{position:absolute;top:10px;right:10px;z-index:1000;display:flex;gap:4px;background:#ffffffe6;border-radius:4px;padding:4px;box-shadow:0 2px 4px #0000001a}.graph-container{width:100%;height:100%;min-height:600px;flex:1;position:relative}\n"], dependencies: [{ kind: "ngmodule", type:
|
|
660
|
+
`, isInline: true, styles: [".renderer-container{width:100%;height:100%;min-height:600px;position:relative;display:flex;flex-direction:column}.controls{position:absolute;top:10px;right:10px;z-index:1000;display:flex;gap:4px;background:#ffffffe6;border-radius:4px;padding:4px;box-shadow:0 2px 4px #0000001a}.graph-container{width:100%;height:100%;min-height:600px;flex:1;position:relative}\n"], dependencies: [{ kind: "ngmodule", type: MatButtonModule }, { kind: "component", type: i1.MatIconButton, selector: "button[mat-icon-button], a[mat-icon-button], button[matIconButton], a[matIconButton]", exportAs: ["matButton", "matAnchor"] }, { kind: "ngmodule", type: MatIconModule }, { kind: "component", type: i2.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "ngmodule", type: MatTooltipModule }, { kind: "directive", type: i3.MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
650
661
|
}
|
|
651
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
662
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: ForceGraphRendererComponent, decorators: [{
|
|
652
663
|
type: Component,
|
|
653
664
|
args: [{ selector: 'cadmus-force-graph-renderer', template: `
|
|
654
665
|
<div class="renderer-container">
|
|
@@ -656,10 +667,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.0", ngImpor
|
|
|
656
667
|
<button
|
|
657
668
|
type="button"
|
|
658
669
|
mat-icon-button
|
|
659
|
-
matTooltip="Switch to {{ mode === '2d' ? '3D' : '2D' }} view"
|
|
670
|
+
matTooltip="Switch to {{ mode() === '2d' ? '3D' : '2D' }} view"
|
|
660
671
|
(click)="toggleMode()"
|
|
661
672
|
>
|
|
662
|
-
<mat-icon>{{
|
|
673
|
+
<mat-icon>{{
|
|
674
|
+
mode() === '2d' ? 'view_in_ar' : 'view_quilt'
|
|
675
|
+
}}</mat-icon>
|
|
663
676
|
</button>
|
|
664
677
|
<button
|
|
665
678
|
type="button"
|
|
@@ -680,29 +693,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.0", ngImpor
|
|
|
680
693
|
</div>
|
|
681
694
|
<div #graphContainer class="graph-container"></div>
|
|
682
695
|
</div>
|
|
683
|
-
`, imports: [
|
|
684
|
-
}], propDecorators: { graphContainer: [{
|
|
696
|
+
`, imports: [MatButtonModule, MatIconModule, MatTooltipModule], changeDetection: ChangeDetectionStrategy.OnPush, styles: [".renderer-container{width:100%;height:100%;min-height:600px;position:relative;display:flex;flex-direction:column}.controls{position:absolute;top:10px;right:10px;z-index:1000;display:flex;gap:4px;background:#ffffffe6;border-radius:4px;padding:4px;box-shadow:0 2px 4px #0000001a}.graph-container{width:100%;height:100%;min-height:600px;flex:1;position:relative}\n"] }]
|
|
697
|
+
}], ctorParameters: () => [], propDecorators: { graphContainer: [{
|
|
685
698
|
type: ViewChild,
|
|
686
699
|
args: ['graphContainer', { static: true }]
|
|
687
|
-
}], nodes: [{
|
|
688
|
-
type: Input
|
|
689
|
-
}], edges: [{
|
|
690
|
-
type: Input
|
|
691
|
-
}], mode: [{
|
|
692
|
-
type: Input
|
|
693
|
-
}], update$: [{
|
|
694
|
-
type: Input
|
|
695
|
-
}], center$: [{
|
|
696
|
-
type: Input
|
|
697
|
-
}], zoomToFit$: [{
|
|
698
|
-
type: Input
|
|
699
|
-
}], nodeSelect: [{
|
|
700
|
-
type: Output
|
|
701
|
-
}], nodeDoubleClick: [{
|
|
702
|
-
type: Output
|
|
703
|
-
}], modeChange: [{
|
|
704
|
-
type: Output
|
|
705
|
-
}] } });
|
|
700
|
+
}], nodes: [{ type: i0.Input, args: [{ isSignal: true, alias: "nodes", required: false }] }], edges: [{ type: i0.Input, args: [{ isSignal: true, alias: "edges", required: false }] }], mode: [{ type: i0.Input, args: [{ isSignal: true, alias: "mode", required: false }] }], update$: [{ type: i0.Input, args: [{ isSignal: true, alias: "update$", required: false }] }], center$: [{ type: i0.Input, args: [{ isSignal: true, alias: "center$", required: false }] }], zoomToFit$: [{ type: i0.Input, args: [{ isSignal: true, alias: "zoomToFit$", required: false }] }], nodeSelect: [{ type: i0.Output, args: ["nodeSelect"] }], nodeDoubleClick: [{ type: i0.Output, args: ["nodeDoubleClick"] }], modeChange: [{ type: i0.Output, args: ["modeChange"] }] } });
|
|
706
701
|
|
|
707
702
|
/**
|
|
708
703
|
* Triples filter.
|
|
@@ -907,10 +902,10 @@ class TripleFilterComponent {
|
|
|
907
902
|
this.filter.set(this.getFilter());
|
|
908
903
|
this.form.markAsPristine();
|
|
909
904
|
}
|
|
910
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
911
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.0", type: TripleFilterComponent, isStandalone: true, selector: "cadmus-walker-triple-filter", inputs: { disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, hasPager: { classPropertyName: "hasPager", publicName: "hasPager", isSignal: true, isRequired: false, transformFunction: null }, total: { classPropertyName: "total", publicName: "total", isSignal: true, isRequired: false, transformFunction: null }, filter: { classPropertyName: "filter", publicName: "filter", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { filter: "filterChange" }, ngImport: i0, template: "<form [formGroup]=\"form\" (submit)=\"apply()\" [attr.disabled]=\"disabled()\">\r\n <!-- paginator -->\r\n @if (hasPager()) {\r\n <mat-paginator\r\n [length]=\"total\"\r\n [pageSize]=\"pageSize.value || 10\"\r\n [pageSizeOptions]=\"[5, 10, 20]\"\r\n (page)=\"onPageChange($event)\"\r\n aria-label=\"Select page\"\r\n />\r\n }\r\n <mat-tab-group>\r\n <!-- TRIPLE -->\r\n <mat-tab label=\"triple\">\r\n <!-- subject ID -->\r\n <div>\r\n <cadmus-refs-lookup\r\n label=\"subject\"\r\n [service]=\"lookupService\"\r\n (itemChange)=\"onSubjectNodeChange($event)\"\r\n />\r\n </div>\r\n <!-- predicate IDs -->\r\n <div>\r\n <cadmus-refs-lookup\r\n label=\"predicate\"\r\n [service]=\"lookupService\"\r\n [baseFilter]=\"{ tag: 'property' }\"\r\n (itemChange)=\"onPredicateNodeChange($event)\"\r\n />\r\n <mat-checkbox [formControl]=\"isNotPred\">not</mat-checkbox>\r\n <!-- notPreds -->\r\n @if (isNotPred.value) {\r\n <div>\r\n <mat-list dense>\r\n @for (n of notPreds.value; track n.id) {\r\n <mat-list-item>\r\n <span>{{ n.label }}</span>\r\n <button type=\"button\" mat-icon-button (click)=\"deleteNotPred(n)\">\r\n <mat-icon class=\"mat-warn\">clear</mat-icon>\r\n </button>\r\n </mat-list-item>\r\n }\r\n </mat-list>\r\n </div>\r\n }\r\n <!-- preds -->\r\n @if (!isNotPred.value) {\r\n <div>\r\n <mat-list dense>\r\n @for (n of preds.value; track n.id) {\r\n <mat-list-item>\r\n <span>{{ n.label }}</span>\r\n <button type=\"button\" mat-icon-button (click)=\"deletePred(n)\">\r\n <mat-icon class=\"mat-warn\">clear</mat-icon>\r\n </button>\r\n </mat-list-item>\r\n }\r\n </mat-list>\r\n </div>\r\n }\r\n </div>\r\n <!-- object ID -->\r\n <div>\r\n <cadmus-refs-lookup\r\n label=\"object\"\r\n [service]=\"lookupService\"\r\n (itemChange)=\"onObjectNodeChange($event)\"\r\n />\r\n </div>\r\n <!-- sid -->\r\n <div>\r\n <mat-form-field>\r\n <input\r\n matInput\r\n [formControl]=\"sid\"\r\n placeholder=\"sid\"\r\n maxlength=\"500\"\r\n />\r\n </mat-form-field>\r\n \r\n <mat-checkbox [formControl]=\"isSidPrefix\">prefix</mat-checkbox>\r\n </div>\r\n <!-- tag -->\r\n <div>\r\n <mat-form-field>\r\n <input\r\n matInput\r\n [formControl]=\"tag\"\r\n placeholder=\"tag\"\r\n maxlength=\"50\"\r\n />\r\n </mat-form-field>\r\n </div>\r\n </mat-tab>\r\n <!-- LITERAL -->\r\n <mat-tab label=\"literal\">\r\n <!-- litPattern -->\r\n <div>\r\n <mat-form-field>\r\n <input matInput [formControl]=\"litPattern\" placeholder=\"pattern\" />\r\n </mat-form-field>\r\n </div>\r\n <!-- litType -->\r\n <div>\r\n <mat-form-field>\r\n <input matInput [formControl]=\"litType\" placeholder=\"type\" />\r\n </mat-form-field>\r\n </div>\r\n <!-- litLanguage-->\r\n <div>\r\n <mat-form-field>\r\n <input matInput [formControl]=\"litLanguage\" placeholder=\"language\" />\r\n </mat-form-field>\r\n </div>\r\n <!-- minLitNumber, maxLitNumber -->\r\n <div>\r\n <mat-form-field style=\"width: 4em\">\r\n <input\r\n matInput\r\n type=\"number\"\r\n [formControl]=\"minLitNumber\"\r\n placeholder=\"min.\"\r\n />\r\n </mat-form-field>\r\n -\r\n <mat-form-field style=\"width: 4em\">\r\n <input\r\n matInput\r\n type=\"number\"\r\n [formControl]=\"maxLitNumber\"\r\n placeholder=\"max.\"\r\n />\r\n </mat-form-field>\r\n </div>\r\n </mat-tab>\r\n </mat-tab-group>\r\n <div\r\n class=\"btn-group\"\r\n role=\"group\"\r\n aria-label=\"toolbar\"\r\n style=\"margin-bottom: 10px\"\r\n >\r\n <button\r\n mat-icon-button\r\n type=\"button\"\r\n (click)=\"reset()\"\r\n matTooltip=\"Reset filters\"\r\n [disabled]=\"disabled()\"\r\n >\r\n <mat-icon class=\"mat-warn\">clear</mat-icon>\r\n </button>\r\n <button\r\n type=\"submit\"\r\n mat-icon-button\r\n [disabled]=\"disabled()\"\r\n matTooltip=\"Apply filters\"\r\n >\r\n <mat-icon class=\"mat-primary\">check_circle</mat-icon>\r\n </button>\r\n </div>\r\n</form>\r\n", styles: [""], dependencies: [{ kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1$1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$1.NumberValueAccessor, selector: "input[type=number][formControlName],input[type=number][formControl],input[type=number][ngModel]" }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1$1.MaxLengthValidator, selector: "[maxlength][formControlName],[maxlength][formControl],[maxlength][ngModel]", inputs: ["maxlength"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i1$1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "directive", type: i1$1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "component", type: MatPaginator, selector: "mat-paginator", inputs: ["color", "pageIndex", "length", "pageSize", "pageSizeOptions", "hidePageSize", "showFirstLastButtons", "selectConfig", "disabled"], outputs: ["page"], exportAs: ["matPaginator"] }, { kind: "component", type: MatTabGroup, selector: "mat-tab-group", inputs: ["color", "fitInkBarToContent", "mat-stretch-tabs", "mat-align-tabs", "dynamicHeight", "selectedIndex", "headerPosition", "animationDuration", "contentTabIndex", "disablePagination", "disableRipple", "preserveContent", "backgroundColor", "aria-label", "aria-labelledby"], outputs: ["selectedIndexChange", "focusChange", "animationDone", "selectedTabChange"], exportAs: ["matTabGroup"] }, { kind: "component", type: MatTab, selector: "mat-tab", inputs: ["disabled", "label", "aria-label", "aria-labelledby", "labelClass", "bodyClass", "id"], exportAs: ["matTab"] }, { kind: "component", type: RefLookupComponent, selector: "cadmus-refs-lookup", inputs: ["label", "limit", "baseFilter", "service", "item", "required", "hasMore", "linkTemplate", "optDialog", "options"], outputs: ["itemChange", "optionsChange", "moreRequest"] }, { kind: "component", type: MatCheckbox, selector: "mat-checkbox", inputs: ["aria-label", "aria-labelledby", "aria-describedby", "aria-expanded", "aria-controls", "aria-owns", "id", "required", "labelPosition", "name", "value", "disableRipple", "tabIndex", "color", "disabledInteractive", "checked", "disabled", "indeterminate"], outputs: ["change", "indeterminateChange"], exportAs: ["matCheckbox"] }, { kind: "component", type: MatList, selector: "mat-list", exportAs: ["matList"] }, { kind: "component", type: MatListItem, selector: "mat-list-item, a[mat-list-item], button[mat-list-item]", inputs: ["activated"], exportAs: ["matListItem"] }, { kind: "component", type: MatIconButton, selector: "button[mat-icon-button], a[mat-icon-button], button[matIconButton], a[matIconButton]", exportAs: ["matButton", "matAnchor"] }, { kind: "component", type: MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "component", type: MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly", "disabledInteractive"], exportAs: ["matInput"] }, { kind: "directive", type: MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }] });
|
|
905
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: TripleFilterComponent, deps: [{ token: i1$1.FormBuilder }, { token: i2$1.GraphNodeLookupService }, { token: i3$1.GraphService }], target: i0.ɵɵFactoryTarget.Component });
|
|
906
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.0", type: TripleFilterComponent, isStandalone: true, selector: "cadmus-walker-triple-filter", inputs: { disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, hasPager: { classPropertyName: "hasPager", publicName: "hasPager", isSignal: true, isRequired: false, transformFunction: null }, total: { classPropertyName: "total", publicName: "total", isSignal: true, isRequired: false, transformFunction: null }, filter: { classPropertyName: "filter", publicName: "filter", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { filter: "filterChange" }, ngImport: i0, template: "<form [formGroup]=\"form\" (submit)=\"apply()\" [attr.disabled]=\"disabled()\">\r\n <!-- paginator -->\r\n @if (hasPager()) {\r\n <mat-paginator\r\n [length]=\"total\"\r\n [pageSize]=\"pageSize.value || 10\"\r\n [pageSizeOptions]=\"[5, 10, 20]\"\r\n (page)=\"onPageChange($event)\"\r\n aria-label=\"Select page\"\r\n />\r\n }\r\n <mat-tab-group>\r\n <!-- TRIPLE -->\r\n <mat-tab label=\"triple\">\r\n <!-- subject ID -->\r\n <div>\r\n <cadmus-refs-lookup\r\n label=\"subject\"\r\n [service]=\"lookupService\"\r\n (itemChange)=\"onSubjectNodeChange($event)\"\r\n />\r\n </div>\r\n <!-- predicate IDs -->\r\n <div>\r\n <cadmus-refs-lookup\r\n label=\"predicate\"\r\n [service]=\"lookupService\"\r\n [baseFilter]=\"{ tag: 'property' }\"\r\n (itemChange)=\"onPredicateNodeChange($event)\"\r\n />\r\n <mat-checkbox [formControl]=\"isNotPred\">not</mat-checkbox>\r\n <!-- notPreds -->\r\n @if (isNotPred.value) {\r\n <div>\r\n <mat-list dense>\r\n @for (n of notPreds.value; track n.id) {\r\n <mat-list-item>\r\n <span>{{ n.label }}</span>\r\n <button type=\"button\" mat-icon-button (click)=\"deleteNotPred(n)\">\r\n <mat-icon class=\"mat-warn\">clear</mat-icon>\r\n </button>\r\n </mat-list-item>\r\n }\r\n </mat-list>\r\n </div>\r\n }\r\n <!-- preds -->\r\n @if (!isNotPred.value) {\r\n <div>\r\n <mat-list dense>\r\n @for (n of preds.value; track n.id) {\r\n <mat-list-item>\r\n <span>{{ n.label }}</span>\r\n <button type=\"button\" mat-icon-button (click)=\"deletePred(n)\">\r\n <mat-icon class=\"mat-warn\">clear</mat-icon>\r\n </button>\r\n </mat-list-item>\r\n }\r\n </mat-list>\r\n </div>\r\n }\r\n </div>\r\n <!-- object ID -->\r\n <div>\r\n <cadmus-refs-lookup\r\n label=\"object\"\r\n [service]=\"lookupService\"\r\n (itemChange)=\"onObjectNodeChange($event)\"\r\n />\r\n </div>\r\n <!-- sid -->\r\n <div>\r\n <mat-form-field>\r\n <input\r\n matInput\r\n [formControl]=\"sid\"\r\n placeholder=\"sid\"\r\n maxlength=\"500\"\r\n />\r\n </mat-form-field>\r\n \r\n <mat-checkbox [formControl]=\"isSidPrefix\">prefix</mat-checkbox>\r\n </div>\r\n <!-- tag -->\r\n <div>\r\n <mat-form-field>\r\n <input\r\n matInput\r\n [formControl]=\"tag\"\r\n placeholder=\"tag\"\r\n maxlength=\"50\"\r\n />\r\n </mat-form-field>\r\n </div>\r\n </mat-tab>\r\n <!-- LITERAL -->\r\n <mat-tab label=\"literal\">\r\n <!-- litPattern -->\r\n <div>\r\n <mat-form-field>\r\n <input matInput [formControl]=\"litPattern\" placeholder=\"pattern\" />\r\n </mat-form-field>\r\n </div>\r\n <!-- litType -->\r\n <div>\r\n <mat-form-field>\r\n <input matInput [formControl]=\"litType\" placeholder=\"type\" />\r\n </mat-form-field>\r\n </div>\r\n <!-- litLanguage-->\r\n <div>\r\n <mat-form-field>\r\n <input matInput [formControl]=\"litLanguage\" placeholder=\"language\" />\r\n </mat-form-field>\r\n </div>\r\n <!-- minLitNumber, maxLitNumber -->\r\n <div>\r\n <mat-form-field style=\"width: 4em\">\r\n <input\r\n matInput\r\n type=\"number\"\r\n [formControl]=\"minLitNumber\"\r\n placeholder=\"min.\"\r\n />\r\n </mat-form-field>\r\n -\r\n <mat-form-field style=\"width: 4em\">\r\n <input\r\n matInput\r\n type=\"number\"\r\n [formControl]=\"maxLitNumber\"\r\n placeholder=\"max.\"\r\n />\r\n </mat-form-field>\r\n </div>\r\n </mat-tab>\r\n </mat-tab-group>\r\n <div\r\n class=\"btn-group\"\r\n role=\"group\"\r\n aria-label=\"toolbar\"\r\n style=\"margin-bottom: 10px\"\r\n >\r\n <button\r\n mat-icon-button\r\n type=\"button\"\r\n (click)=\"reset()\"\r\n matTooltip=\"Reset filters\"\r\n [disabled]=\"disabled()\"\r\n >\r\n <mat-icon class=\"mat-warn\">clear</mat-icon>\r\n </button>\r\n <button\r\n type=\"submit\"\r\n mat-icon-button\r\n [disabled]=\"disabled()\"\r\n matTooltip=\"Apply filters\"\r\n >\r\n <mat-icon class=\"mat-primary\">check_circle</mat-icon>\r\n </button>\r\n </div>\r\n</form>\r\n", styles: [""], dependencies: [{ kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1$1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$1.NumberValueAccessor, selector: "input[type=number][formControlName],input[type=number][formControl],input[type=number][ngModel]" }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],[formArray],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1$1.MaxLengthValidator, selector: "[maxlength][formControlName],[maxlength][formControl],[maxlength][ngModel]", inputs: ["maxlength"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i1$1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "directive", type: i1$1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "component", type: MatPaginator, selector: "mat-paginator", inputs: ["color", "pageIndex", "length", "pageSize", "pageSizeOptions", "hidePageSize", "showFirstLastButtons", "selectConfig", "disabled"], outputs: ["page"], exportAs: ["matPaginator"] }, { kind: "component", type: MatTabGroup, selector: "mat-tab-group", inputs: ["color", "fitInkBarToContent", "mat-stretch-tabs", "mat-align-tabs", "dynamicHeight", "selectedIndex", "headerPosition", "animationDuration", "contentTabIndex", "disablePagination", "disableRipple", "preserveContent", "backgroundColor", "aria-label", "aria-labelledby"], outputs: ["selectedIndexChange", "focusChange", "animationDone", "selectedTabChange"], exportAs: ["matTabGroup"] }, { kind: "component", type: MatTab, selector: "mat-tab", inputs: ["disabled", "label", "aria-label", "aria-labelledby", "labelClass", "bodyClass", "id"], exportAs: ["matTab"] }, { kind: "component", type: RefLookupComponent, selector: "cadmus-refs-lookup", inputs: ["label", "limit", "baseFilter", "service", "item", "itemId", "required", "hasMore", "linkTemplate", "optDialog", "options", "lookupProviderOptions"], outputs: ["itemChange", "optionsChange", "moreRequest"] }, { kind: "component", type: MatCheckbox, selector: "mat-checkbox", inputs: ["aria-label", "aria-labelledby", "aria-describedby", "aria-expanded", "aria-controls", "aria-owns", "id", "required", "labelPosition", "name", "value", "disableRipple", "tabIndex", "color", "disabledInteractive", "checked", "disabled", "indeterminate"], outputs: ["change", "indeterminateChange"], exportAs: ["matCheckbox"] }, { kind: "component", type: MatList, selector: "mat-list", exportAs: ["matList"] }, { kind: "component", type: MatListItem, selector: "mat-list-item, a[mat-list-item], button[mat-list-item]", inputs: ["activated"], exportAs: ["matListItem"] }, { kind: "component", type: MatIconButton, selector: "button[mat-icon-button], a[mat-icon-button], button[matIconButton], a[matIconButton]", exportAs: ["matButton", "matAnchor"] }, { kind: "component", type: MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "component", type: MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly", "disabledInteractive"], exportAs: ["matInput"] }, { kind: "directive", type: MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
912
907
|
}
|
|
913
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
908
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: TripleFilterComponent, decorators: [{
|
|
914
909
|
type: Component,
|
|
915
910
|
args: [{ selector: 'cadmus-walker-triple-filter', imports: [
|
|
916
911
|
FormsModule,
|
|
@@ -927,8 +922,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.0", ngImpor
|
|
|
927
922
|
MatFormField,
|
|
928
923
|
MatInput,
|
|
929
924
|
MatTooltip,
|
|
930
|
-
], template: "<form [formGroup]=\"form\" (submit)=\"apply()\" [attr.disabled]=\"disabled()\">\r\n <!-- paginator -->\r\n @if (hasPager()) {\r\n <mat-paginator\r\n [length]=\"total\"\r\n [pageSize]=\"pageSize.value || 10\"\r\n [pageSizeOptions]=\"[5, 10, 20]\"\r\n (page)=\"onPageChange($event)\"\r\n aria-label=\"Select page\"\r\n />\r\n }\r\n <mat-tab-group>\r\n <!-- TRIPLE -->\r\n <mat-tab label=\"triple\">\r\n <!-- subject ID -->\r\n <div>\r\n <cadmus-refs-lookup\r\n label=\"subject\"\r\n [service]=\"lookupService\"\r\n (itemChange)=\"onSubjectNodeChange($event)\"\r\n />\r\n </div>\r\n <!-- predicate IDs -->\r\n <div>\r\n <cadmus-refs-lookup\r\n label=\"predicate\"\r\n [service]=\"lookupService\"\r\n [baseFilter]=\"{ tag: 'property' }\"\r\n (itemChange)=\"onPredicateNodeChange($event)\"\r\n />\r\n <mat-checkbox [formControl]=\"isNotPred\">not</mat-checkbox>\r\n <!-- notPreds -->\r\n @if (isNotPred.value) {\r\n <div>\r\n <mat-list dense>\r\n @for (n of notPreds.value; track n.id) {\r\n <mat-list-item>\r\n <span>{{ n.label }}</span>\r\n <button type=\"button\" mat-icon-button (click)=\"deleteNotPred(n)\">\r\n <mat-icon class=\"mat-warn\">clear</mat-icon>\r\n </button>\r\n </mat-list-item>\r\n }\r\n </mat-list>\r\n </div>\r\n }\r\n <!-- preds -->\r\n @if (!isNotPred.value) {\r\n <div>\r\n <mat-list dense>\r\n @for (n of preds.value; track n.id) {\r\n <mat-list-item>\r\n <span>{{ n.label }}</span>\r\n <button type=\"button\" mat-icon-button (click)=\"deletePred(n)\">\r\n <mat-icon class=\"mat-warn\">clear</mat-icon>\r\n </button>\r\n </mat-list-item>\r\n }\r\n </mat-list>\r\n </div>\r\n }\r\n </div>\r\n <!-- object ID -->\r\n <div>\r\n <cadmus-refs-lookup\r\n label=\"object\"\r\n [service]=\"lookupService\"\r\n (itemChange)=\"onObjectNodeChange($event)\"\r\n />\r\n </div>\r\n <!-- sid -->\r\n <div>\r\n <mat-form-field>\r\n <input\r\n matInput\r\n [formControl]=\"sid\"\r\n placeholder=\"sid\"\r\n maxlength=\"500\"\r\n />\r\n </mat-form-field>\r\n \r\n <mat-checkbox [formControl]=\"isSidPrefix\">prefix</mat-checkbox>\r\n </div>\r\n <!-- tag -->\r\n <div>\r\n <mat-form-field>\r\n <input\r\n matInput\r\n [formControl]=\"tag\"\r\n placeholder=\"tag\"\r\n maxlength=\"50\"\r\n />\r\n </mat-form-field>\r\n </div>\r\n </mat-tab>\r\n <!-- LITERAL -->\r\n <mat-tab label=\"literal\">\r\n <!-- litPattern -->\r\n <div>\r\n <mat-form-field>\r\n <input matInput [formControl]=\"litPattern\" placeholder=\"pattern\" />\r\n </mat-form-field>\r\n </div>\r\n <!-- litType -->\r\n <div>\r\n <mat-form-field>\r\n <input matInput [formControl]=\"litType\" placeholder=\"type\" />\r\n </mat-form-field>\r\n </div>\r\n <!-- litLanguage-->\r\n <div>\r\n <mat-form-field>\r\n <input matInput [formControl]=\"litLanguage\" placeholder=\"language\" />\r\n </mat-form-field>\r\n </div>\r\n <!-- minLitNumber, maxLitNumber -->\r\n <div>\r\n <mat-form-field style=\"width: 4em\">\r\n <input\r\n matInput\r\n type=\"number\"\r\n [formControl]=\"minLitNumber\"\r\n placeholder=\"min.\"\r\n />\r\n </mat-form-field>\r\n -\r\n <mat-form-field style=\"width: 4em\">\r\n <input\r\n matInput\r\n type=\"number\"\r\n [formControl]=\"maxLitNumber\"\r\n placeholder=\"max.\"\r\n />\r\n </mat-form-field>\r\n </div>\r\n </mat-tab>\r\n </mat-tab-group>\r\n <div\r\n class=\"btn-group\"\r\n role=\"group\"\r\n aria-label=\"toolbar\"\r\n style=\"margin-bottom: 10px\"\r\n >\r\n <button\r\n mat-icon-button\r\n type=\"button\"\r\n (click)=\"reset()\"\r\n matTooltip=\"Reset filters\"\r\n [disabled]=\"disabled()\"\r\n >\r\n <mat-icon class=\"mat-warn\">clear</mat-icon>\r\n </button>\r\n <button\r\n type=\"submit\"\r\n mat-icon-button\r\n [disabled]=\"disabled()\"\r\n matTooltip=\"Apply filters\"\r\n >\r\n <mat-icon class=\"mat-primary\">check_circle</mat-icon>\r\n </button>\r\n </div>\r\n</form>\r\n" }]
|
|
931
|
-
}], ctorParameters: () => [{ type: i1$1.FormBuilder }, { type: i2$1.GraphNodeLookupService }, { type: i3$1.GraphService }] });
|
|
925
|
+
], changeDetection: ChangeDetectionStrategy.OnPush, template: "<form [formGroup]=\"form\" (submit)=\"apply()\" [attr.disabled]=\"disabled()\">\r\n <!-- paginator -->\r\n @if (hasPager()) {\r\n <mat-paginator\r\n [length]=\"total\"\r\n [pageSize]=\"pageSize.value || 10\"\r\n [pageSizeOptions]=\"[5, 10, 20]\"\r\n (page)=\"onPageChange($event)\"\r\n aria-label=\"Select page\"\r\n />\r\n }\r\n <mat-tab-group>\r\n <!-- TRIPLE -->\r\n <mat-tab label=\"triple\">\r\n <!-- subject ID -->\r\n <div>\r\n <cadmus-refs-lookup\r\n label=\"subject\"\r\n [service]=\"lookupService\"\r\n (itemChange)=\"onSubjectNodeChange($event)\"\r\n />\r\n </div>\r\n <!-- predicate IDs -->\r\n <div>\r\n <cadmus-refs-lookup\r\n label=\"predicate\"\r\n [service]=\"lookupService\"\r\n [baseFilter]=\"{ tag: 'property' }\"\r\n (itemChange)=\"onPredicateNodeChange($event)\"\r\n />\r\n <mat-checkbox [formControl]=\"isNotPred\">not</mat-checkbox>\r\n <!-- notPreds -->\r\n @if (isNotPred.value) {\r\n <div>\r\n <mat-list dense>\r\n @for (n of notPreds.value; track n.id) {\r\n <mat-list-item>\r\n <span>{{ n.label }}</span>\r\n <button type=\"button\" mat-icon-button (click)=\"deleteNotPred(n)\">\r\n <mat-icon class=\"mat-warn\">clear</mat-icon>\r\n </button>\r\n </mat-list-item>\r\n }\r\n </mat-list>\r\n </div>\r\n }\r\n <!-- preds -->\r\n @if (!isNotPred.value) {\r\n <div>\r\n <mat-list dense>\r\n @for (n of preds.value; track n.id) {\r\n <mat-list-item>\r\n <span>{{ n.label }}</span>\r\n <button type=\"button\" mat-icon-button (click)=\"deletePred(n)\">\r\n <mat-icon class=\"mat-warn\">clear</mat-icon>\r\n </button>\r\n </mat-list-item>\r\n }\r\n </mat-list>\r\n </div>\r\n }\r\n </div>\r\n <!-- object ID -->\r\n <div>\r\n <cadmus-refs-lookup\r\n label=\"object\"\r\n [service]=\"lookupService\"\r\n (itemChange)=\"onObjectNodeChange($event)\"\r\n />\r\n </div>\r\n <!-- sid -->\r\n <div>\r\n <mat-form-field>\r\n <input\r\n matInput\r\n [formControl]=\"sid\"\r\n placeholder=\"sid\"\r\n maxlength=\"500\"\r\n />\r\n </mat-form-field>\r\n \r\n <mat-checkbox [formControl]=\"isSidPrefix\">prefix</mat-checkbox>\r\n </div>\r\n <!-- tag -->\r\n <div>\r\n <mat-form-field>\r\n <input\r\n matInput\r\n [formControl]=\"tag\"\r\n placeholder=\"tag\"\r\n maxlength=\"50\"\r\n />\r\n </mat-form-field>\r\n </div>\r\n </mat-tab>\r\n <!-- LITERAL -->\r\n <mat-tab label=\"literal\">\r\n <!-- litPattern -->\r\n <div>\r\n <mat-form-field>\r\n <input matInput [formControl]=\"litPattern\" placeholder=\"pattern\" />\r\n </mat-form-field>\r\n </div>\r\n <!-- litType -->\r\n <div>\r\n <mat-form-field>\r\n <input matInput [formControl]=\"litType\" placeholder=\"type\" />\r\n </mat-form-field>\r\n </div>\r\n <!-- litLanguage-->\r\n <div>\r\n <mat-form-field>\r\n <input matInput [formControl]=\"litLanguage\" placeholder=\"language\" />\r\n </mat-form-field>\r\n </div>\r\n <!-- minLitNumber, maxLitNumber -->\r\n <div>\r\n <mat-form-field style=\"width: 4em\">\r\n <input\r\n matInput\r\n type=\"number\"\r\n [formControl]=\"minLitNumber\"\r\n placeholder=\"min.\"\r\n />\r\n </mat-form-field>\r\n -\r\n <mat-form-field style=\"width: 4em\">\r\n <input\r\n matInput\r\n type=\"number\"\r\n [formControl]=\"maxLitNumber\"\r\n placeholder=\"max.\"\r\n />\r\n </mat-form-field>\r\n </div>\r\n </mat-tab>\r\n </mat-tab-group>\r\n <div\r\n class=\"btn-group\"\r\n role=\"group\"\r\n aria-label=\"toolbar\"\r\n style=\"margin-bottom: 10px\"\r\n >\r\n <button\r\n mat-icon-button\r\n type=\"button\"\r\n (click)=\"reset()\"\r\n matTooltip=\"Reset filters\"\r\n [disabled]=\"disabled()\"\r\n >\r\n <mat-icon class=\"mat-warn\">clear</mat-icon>\r\n </button>\r\n <button\r\n type=\"submit\"\r\n mat-icon-button\r\n [disabled]=\"disabled()\"\r\n matTooltip=\"Apply filters\"\r\n >\r\n <mat-icon class=\"mat-primary\">check_circle</mat-icon>\r\n </button>\r\n </div>\r\n</form>\r\n" }]
|
|
926
|
+
}], ctorParameters: () => [{ type: i1$1.FormBuilder }, { type: i2$1.GraphNodeLookupService }, { type: i3$1.GraphService }], propDecorators: { disabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabled", required: false }] }], hasPager: [{ type: i0.Input, args: [{ isSignal: true, alias: "hasPager", required: false }] }], total: [{ type: i0.Input, args: [{ isSignal: true, alias: "total", required: false }] }], filter: [{ type: i0.Input, args: [{ isSignal: true, alias: "filter", required: false }] }, { type: i0.Output, args: ["filterChange"] }] } });
|
|
932
927
|
|
|
933
928
|
/**
|
|
934
929
|
* Linked non-literal node filter.
|
|
@@ -1087,10 +1082,10 @@ class LinkedNodeFilterComponent {
|
|
|
1087
1082
|
this.filter.set(this.getFilter());
|
|
1088
1083
|
this.form.markAsPristine();
|
|
1089
1084
|
}
|
|
1090
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1091
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "
|
|
1085
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: LinkedNodeFilterComponent, deps: [{ token: i1$1.FormBuilder }, { token: i2$1.GraphNodeLookupService }, { token: i3$1.GraphService }], target: i0.ɵɵFactoryTarget.Component });
|
|
1086
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.0", type: LinkedNodeFilterComponent, isStandalone: true, selector: "cadmus-walker-linked-node-filter", inputs: { disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, hasPager: { classPropertyName: "hasPager", publicName: "hasPager", isSignal: true, isRequired: false, transformFunction: null }, total: { classPropertyName: "total", publicName: "total", isSignal: true, isRequired: false, transformFunction: null }, filter: { classPropertyName: "filter", publicName: "filter", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { filter: "filterChange" }, ngImport: i0, template: "<form [formGroup]=\"form\" (submit)=\"apply()\" [attr.disabled]=\"disabled()\">\r\n <!-- paginator -->\r\n @if (hasPager()) {\r\n <mat-paginator\r\n [length]=\"total\"\r\n [pageSize]=\"pageSize.value || 10\"\r\n [pageSizeOptions]=\"[5, 10, 20]\"\r\n (page)=\"onPageChange($event)\"\r\n aria-label=\"Select page\"\r\n />\r\n }\r\n\r\n <!-- label -->\r\n <div>\r\n <mat-form-field>\r\n <input matInput [formControl]=\"label\" placeholder=\"label\" />\r\n </mat-form-field>\r\n </div>\r\n <!-- uid -->\r\n <div>\r\n <mat-form-field>\r\n <input matInput [formControl]=\"uid\" placeholder=\"UID\" />\r\n </mat-form-field>\r\n </div>\r\n <!-- isClass -->\r\n <div>\r\n <mat-form-field>\r\n <mat-select [formControl]=\"isClass\" placeholder=\"class\">\r\n <mat-option [value]=\"0\">(any)</mat-option>\r\n <mat-option [value]=\"1\">not-class</mat-option>\r\n <mat-option [value]=\"2\">class</mat-option>\r\n </mat-select>\r\n </mat-form-field>\r\n </div>\r\n <!-- tag -->\r\n <div>\r\n <mat-form-field>\r\n <input matInput [formControl]=\"tag\" placeholder=\"tag\" />\r\n </mat-form-field>\r\n </div>\r\n <!-- sourceType -->\r\n <div>\r\n <mat-form-field>\r\n <mat-select [formControl]=\"sourceType\" placeholder=\"source type\">\r\n <mat-option [value]=\"null\">(any)</mat-option>\r\n <mat-option [value]=\"0\">user</mat-option>\r\n <mat-option [value]=\"1\">item</mat-option>\r\n <mat-option [value]=\"2\">part</mat-option>\r\n <mat-option [value]=\"3\">thesaurus</mat-option>\r\n <mat-option [value]=\"4\">implicit</mat-option>\r\n </mat-select>\r\n </mat-form-field>\r\n </div>\r\n <div>\r\n <!-- sid -->\r\n <div>\r\n <mat-form-field>\r\n <input matInput [formControl]=\"sid\" placeholder=\"SID\" />\r\n </mat-form-field>\r\n\r\n <!-- isSidPrefix -->\r\n <mat-checkbox [formControl]=\"isSidPrefix\">prefix</mat-checkbox>\r\n </div>\r\n </div>\r\n <!-- classes -->\r\n <div>\r\n <fieldset>\r\n <legend>classes</legend>\r\n <cadmus-refs-lookup\r\n label=\"class\"\r\n [service]=\"lookupService\"\r\n [baseFilter]=\"{ isClass: true }\"\r\n (itemChange)=\"onClassAdd($event)\"\r\n />\r\n\r\n @if (classes.value.length) {\r\n <mat-chip-listbox>\r\n @for (node of classes.value; track node.id) {\r\n <mat-chip-option\r\n [removable]=\"true\"\r\n (removed)=\"onClassRemove(node)\"\r\n matTooltip=\"{{ node.uri }}\"\r\n >{{ node.label }}\r\n <button type=\"button\" matChipRemove>\r\n <mat-icon>cancel</mat-icon>\r\n </button>\r\n </mat-chip-option>\r\n }\r\n </mat-chip-listbox>\r\n }\r\n </fieldset>\r\n </div>\r\n\r\n <div\r\n class=\"btn-group\"\r\n role=\"group\"\r\n aria-label=\"toolbar\"\r\n style=\"margin-bottom: 10px\"\r\n >\r\n <button\r\n mat-icon-button\r\n type=\"button\"\r\n (click)=\"reset()\"\r\n matTooltip=\"Reset filters\"\r\n [disabled]=\"disabled()\"\r\n >\r\n <mat-icon class=\"mat-warn\">clear</mat-icon>\r\n </button>\r\n <button\r\n type=\"submit\"\r\n mat-icon-button\r\n [disabled]=\"disabled()\"\r\n matTooltip=\"Apply filters\"\r\n >\r\n <mat-icon class=\"mat-primary\">check_circle</mat-icon>\r\n </button>\r\n </div>\r\n</form>\r\n", styles: ["fieldset{border:1px solid silver;border-radius:4px;padding:4px}\n"], dependencies: [{ kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1$1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],[formArray],form:not([ngNoForm]),[ngForm]" }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i1$1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "directive", type: i1$1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "component", type: MatPaginator, selector: "mat-paginator", inputs: ["color", "pageIndex", "length", "pageSize", "pageSizeOptions", "hidePageSize", "showFirstLastButtons", "selectConfig", "disabled"], outputs: ["page"], exportAs: ["matPaginator"] }, { kind: "component", type: MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly", "disabledInteractive"], exportAs: ["matInput"] }, { kind: "component", type: MatSelect, selector: "mat-select", inputs: ["aria-describedby", "panelClass", "disabled", "disableRipple", "tabIndex", "hideSingleSelectionIndicator", "placeholder", "required", "multiple", "disableOptionCentering", "compareWith", "value", "aria-label", "aria-labelledby", "errorStateMatcher", "typeaheadDebounceInterval", "sortComparator", "id", "panelWidth", "canSelectNullableOptions"], outputs: ["openedChange", "opened", "closed", "selectionChange", "valueChange"], exportAs: ["matSelect"] }, { kind: "component", type: MatOption, selector: "mat-option", inputs: ["value", "id", "disabled"], outputs: ["onSelectionChange"], exportAs: ["matOption"] }, { kind: "component", type: MatCheckbox, selector: "mat-checkbox", inputs: ["aria-label", "aria-labelledby", "aria-describedby", "aria-expanded", "aria-controls", "aria-owns", "id", "required", "labelPosition", "name", "value", "disableRipple", "tabIndex", "color", "disabledInteractive", "checked", "disabled", "indeterminate"], outputs: ["change", "indeterminateChange"], exportAs: ["matCheckbox"] }, { kind: "component", type: RefLookupComponent, selector: "cadmus-refs-lookup", inputs: ["label", "limit", "baseFilter", "service", "item", "itemId", "required", "hasMore", "linkTemplate", "optDialog", "options", "lookupProviderOptions"], outputs: ["itemChange", "optionsChange", "moreRequest"] }, { kind: "component", type: MatChipListbox, selector: "mat-chip-listbox", inputs: ["multiple", "aria-orientation", "selectable", "compareWith", "required", "hideSingleSelectionIndicator", "value"], outputs: ["change"] }, { kind: "component", type: MatChipOption, selector: "mat-basic-chip-option, [mat-basic-chip-option], mat-chip-option, [mat-chip-option]", inputs: ["selectable", "selected"], outputs: ["selectionChange"] }, { kind: "directive", type: MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "directive", type: MatChipRemove, selector: "[matChipRemove]" }, { kind: "component", type: MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "component", type: MatIconButton, selector: "button[mat-icon-button], a[mat-icon-button], button[matIconButton], a[matIconButton]", exportAs: ["matButton", "matAnchor"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
1092
1087
|
}
|
|
1093
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1088
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: LinkedNodeFilterComponent, decorators: [{
|
|
1094
1089
|
type: Component,
|
|
1095
1090
|
args: [{ selector: 'cadmus-walker-linked-node-filter', imports: [
|
|
1096
1091
|
FormsModule,
|
|
@@ -1108,8 +1103,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.0", ngImpor
|
|
|
1108
1103
|
MatChipRemove,
|
|
1109
1104
|
MatIcon,
|
|
1110
1105
|
MatIconButton,
|
|
1111
|
-
], template: "<form [formGroup]=\"form\" (submit)=\"apply()\" [attr.disabled]=\"disabled()\">\r\n <!-- paginator -->\r\n @if (hasPager()) {\r\n <mat-paginator\r\n [length]=\"total\"\r\n [pageSize]=\"pageSize.value || 10\"\r\n [pageSizeOptions]=\"[5, 10, 20]\"\r\n (page)=\"onPageChange($event)\"\r\n aria-label=\"Select page\"\r\n />\r\n }\r\n\r\n <!-- label -->\r\n <div>\r\n <mat-form-field>\r\n <input matInput [formControl]=\"label\" placeholder=\"label\" />\r\n </mat-form-field>\r\n </div>\r\n <!-- uid -->\r\n <div>\r\n <mat-form-field>\r\n <input matInput [formControl]=\"uid\" placeholder=\"UID\" />\r\n </mat-form-field>\r\n </div>\r\n <!-- isClass -->\r\n <div>\r\n <mat-form-field>\r\n <mat-select [formControl]=\"isClass\" placeholder=\"class\">\r\n <mat-option [value]=\"0\">(any)</mat-option>\r\n <mat-option [value]=\"1\">not-class</mat-option>\r\n <mat-option [value]=\"2\">class</mat-option>\r\n </mat-select>\r\n </mat-form-field>\r\n </div>\r\n <!-- tag -->\r\n <div>\r\n <mat-form-field>\r\n <input matInput [formControl]=\"tag\" placeholder=\"tag\" />\r\n </mat-form-field>\r\n </div>\r\n <!-- sourceType -->\r\n <div>\r\n <mat-form-field>\r\n <mat-select [formControl]=\"sourceType\" placeholder=\"source type\">\r\n <mat-option [value]=\"null\">(any)</mat-option>\r\n <mat-option [value]=\"0\">user</mat-option>\r\n <mat-option [value]=\"1\">item</mat-option>\r\n <mat-option [value]=\"2\">part</mat-option>\r\n <mat-option [value]=\"3\">thesaurus</mat-option>\r\n <mat-option [value]=\"4\">implicit</mat-option>\r\n </mat-select>\r\n </mat-form-field>\r\n </div>\r\n <div>\r\n <!-- sid -->\r\n <div>\r\n <mat-form-field>\r\n <input matInput [formControl]=\"sid\" placeholder=\"SID\" />\r\n </mat-form-field>\r\n\r\n <!-- isSidPrefix -->\r\n <mat-checkbox [formControl]=\"isSidPrefix\">prefix</mat-checkbox>\r\n </div>\r\n </div>\r\n <!-- classes -->\r\n <div>\r\n <fieldset>\r\n <legend>classes</legend>\r\n <cadmus-refs-lookup\r\n label=\"class\"\r\n [service]=\"lookupService\"\r\n [baseFilter]=\"{ isClass: true }\"\r\n (itemChange)=\"onClassAdd($event)\"\r\n />\r\n\r\n @if (classes.value.length) {\r\n <mat-chip-listbox>\r\n @for (node of classes.value; track node.id) {\r\n <mat-chip-option\r\n [removable]=\"true\"\r\n (removed)=\"onClassRemove(node)\"\r\n matTooltip=\"{{ node.uri }}\"\r\n >{{ node.label }}\r\n <button type=\"button\" matChipRemove>\r\n <mat-icon>cancel</mat-icon>\r\n </button>\r\n </mat-chip-option>\r\n }\r\n </mat-chip-listbox>\r\n }\r\n </fieldset>\r\n </div>\r\n\r\n <div\r\n class=\"btn-group\"\r\n role=\"group\"\r\n aria-label=\"toolbar\"\r\n style=\"margin-bottom: 10px\"\r\n >\r\n <button\r\n mat-icon-button\r\n type=\"button\"\r\n (click)=\"reset()\"\r\n matTooltip=\"Reset filters\"\r\n [disabled]=\"disabled()\"\r\n >\r\n <mat-icon class=\"mat-warn\">clear</mat-icon>\r\n </button>\r\n <button\r\n type=\"submit\"\r\n mat-icon-button\r\n [disabled]=\"disabled()\"\r\n matTooltip=\"Apply filters\"\r\n >\r\n <mat-icon class=\"mat-primary\">check_circle</mat-icon>\r\n </button>\r\n </div>\r\n</form>\r\n", styles: ["fieldset{border:1px solid silver;border-radius:4px;padding:4px}\n"] }]
|
|
1112
|
-
}], ctorParameters: () => [{ type: i1$1.FormBuilder }, { type: i2$1.GraphNodeLookupService }, { type: i3$1.GraphService }] });
|
|
1106
|
+
], changeDetection: ChangeDetectionStrategy.OnPush, template: "<form [formGroup]=\"form\" (submit)=\"apply()\" [attr.disabled]=\"disabled()\">\r\n <!-- paginator -->\r\n @if (hasPager()) {\r\n <mat-paginator\r\n [length]=\"total\"\r\n [pageSize]=\"pageSize.value || 10\"\r\n [pageSizeOptions]=\"[5, 10, 20]\"\r\n (page)=\"onPageChange($event)\"\r\n aria-label=\"Select page\"\r\n />\r\n }\r\n\r\n <!-- label -->\r\n <div>\r\n <mat-form-field>\r\n <input matInput [formControl]=\"label\" placeholder=\"label\" />\r\n </mat-form-field>\r\n </div>\r\n <!-- uid -->\r\n <div>\r\n <mat-form-field>\r\n <input matInput [formControl]=\"uid\" placeholder=\"UID\" />\r\n </mat-form-field>\r\n </div>\r\n <!-- isClass -->\r\n <div>\r\n <mat-form-field>\r\n <mat-select [formControl]=\"isClass\" placeholder=\"class\">\r\n <mat-option [value]=\"0\">(any)</mat-option>\r\n <mat-option [value]=\"1\">not-class</mat-option>\r\n <mat-option [value]=\"2\">class</mat-option>\r\n </mat-select>\r\n </mat-form-field>\r\n </div>\r\n <!-- tag -->\r\n <div>\r\n <mat-form-field>\r\n <input matInput [formControl]=\"tag\" placeholder=\"tag\" />\r\n </mat-form-field>\r\n </div>\r\n <!-- sourceType -->\r\n <div>\r\n <mat-form-field>\r\n <mat-select [formControl]=\"sourceType\" placeholder=\"source type\">\r\n <mat-option [value]=\"null\">(any)</mat-option>\r\n <mat-option [value]=\"0\">user</mat-option>\r\n <mat-option [value]=\"1\">item</mat-option>\r\n <mat-option [value]=\"2\">part</mat-option>\r\n <mat-option [value]=\"3\">thesaurus</mat-option>\r\n <mat-option [value]=\"4\">implicit</mat-option>\r\n </mat-select>\r\n </mat-form-field>\r\n </div>\r\n <div>\r\n <!-- sid -->\r\n <div>\r\n <mat-form-field>\r\n <input matInput [formControl]=\"sid\" placeholder=\"SID\" />\r\n </mat-form-field>\r\n\r\n <!-- isSidPrefix -->\r\n <mat-checkbox [formControl]=\"isSidPrefix\">prefix</mat-checkbox>\r\n </div>\r\n </div>\r\n <!-- classes -->\r\n <div>\r\n <fieldset>\r\n <legend>classes</legend>\r\n <cadmus-refs-lookup\r\n label=\"class\"\r\n [service]=\"lookupService\"\r\n [baseFilter]=\"{ isClass: true }\"\r\n (itemChange)=\"onClassAdd($event)\"\r\n />\r\n\r\n @if (classes.value.length) {\r\n <mat-chip-listbox>\r\n @for (node of classes.value; track node.id) {\r\n <mat-chip-option\r\n [removable]=\"true\"\r\n (removed)=\"onClassRemove(node)\"\r\n matTooltip=\"{{ node.uri }}\"\r\n >{{ node.label }}\r\n <button type=\"button\" matChipRemove>\r\n <mat-icon>cancel</mat-icon>\r\n </button>\r\n </mat-chip-option>\r\n }\r\n </mat-chip-listbox>\r\n }\r\n </fieldset>\r\n </div>\r\n\r\n <div\r\n class=\"btn-group\"\r\n role=\"group\"\r\n aria-label=\"toolbar\"\r\n style=\"margin-bottom: 10px\"\r\n >\r\n <button\r\n mat-icon-button\r\n type=\"button\"\r\n (click)=\"reset()\"\r\n matTooltip=\"Reset filters\"\r\n [disabled]=\"disabled()\"\r\n >\r\n <mat-icon class=\"mat-warn\">clear</mat-icon>\r\n </button>\r\n <button\r\n type=\"submit\"\r\n mat-icon-button\r\n [disabled]=\"disabled()\"\r\n matTooltip=\"Apply filters\"\r\n >\r\n <mat-icon class=\"mat-primary\">check_circle</mat-icon>\r\n </button>\r\n </div>\r\n</form>\r\n", styles: ["fieldset{border:1px solid silver;border-radius:4px;padding:4px}\n"] }]
|
|
1107
|
+
}], ctorParameters: () => [{ type: i1$1.FormBuilder }, { type: i2$1.GraphNodeLookupService }, { type: i3$1.GraphService }], propDecorators: { disabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabled", required: false }] }], hasPager: [{ type: i0.Input, args: [{ isSignal: true, alias: "hasPager", required: false }] }], total: [{ type: i0.Input, args: [{ isSignal: true, alias: "total", required: false }] }], filter: [{ type: i0.Input, args: [{ isSignal: true, alias: "filter", required: false }] }, { type: i0.Output, args: ["filterChange"] }] } });
|
|
1113
1108
|
|
|
1114
1109
|
/**
|
|
1115
1110
|
* Linked literal filter.
|
|
@@ -1230,10 +1225,10 @@ class LinkedLiteralFilterComponent {
|
|
|
1230
1225
|
this.filter.set(this.getFilter());
|
|
1231
1226
|
this.form.markAsPristine();
|
|
1232
1227
|
}
|
|
1233
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1234
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "
|
|
1228
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: LinkedLiteralFilterComponent, deps: [{ token: i1$1.FormBuilder }, { token: i2$1.GraphNodeLookupService }, { token: i3$1.GraphService }], target: i0.ɵɵFactoryTarget.Component });
|
|
1229
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.0", type: LinkedLiteralFilterComponent, isStandalone: true, selector: "cadmus-walker-linked-literal-filter", inputs: { disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, hasPager: { classPropertyName: "hasPager", publicName: "hasPager", isSignal: true, isRequired: false, transformFunction: null }, total: { classPropertyName: "total", publicName: "total", isSignal: true, isRequired: false, transformFunction: null }, filter: { classPropertyName: "filter", publicName: "filter", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { filter: "filterChange" }, ngImport: i0, template: "<form [formGroup]=\"form\" (submit)=\"apply()\" [attr.disabled]=\"disabled()\">\r\n <!-- paginator -->\r\n @if (hasPager()) {\r\n <mat-paginator\r\n [length]=\"total()\"\r\n [pageSize]=\"pageSize.value || 10\"\r\n [pageSizeOptions]=\"[5, 10, 20]\"\r\n (page)=\"onPageChange($event)\"\r\n aria-label=\"Select page\"\r\n />\r\n }\r\n\r\n <!-- subject ID -->\r\n <div>\r\n <cadmus-refs-lookup\r\n label=\"subject\"\r\n [service]=\"lookupService\"\r\n (itemChange)=\"onSubjectNodeChange($event)\"\r\n />\r\n </div>\r\n\r\n <!-- predicate ID -->\r\n <div>\r\n <cadmus-refs-lookup\r\n label=\"predicate\"\r\n [service]=\"lookupService\"\r\n [baseFilter]=\"{ tag: 'property' }\"\r\n (itemChange)=\"onPredicateNodeChange($event)\"\r\n />\r\n </div>\r\n\r\n <!-- LITERAL -->\r\n <!-- litPattern -->\r\n <div>\r\n <mat-form-field>\r\n <input matInput [formControl]=\"litPattern\" placeholder=\"pattern\" />\r\n </mat-form-field>\r\n </div>\r\n <!-- litType -->\r\n <div>\r\n <mat-form-field>\r\n <input matInput [formControl]=\"litType\" placeholder=\"type\" />\r\n </mat-form-field>\r\n </div>\r\n <!-- litLanguage-->\r\n <div>\r\n <mat-form-field>\r\n <input matInput [formControl]=\"litLanguage\" placeholder=\"language\" />\r\n </mat-form-field>\r\n </div>\r\n <!-- minLitNumber, maxLitNumber -->\r\n <div>\r\n <mat-form-field style=\"width: 5em\">\r\n <input\r\n matInput\r\n type=\"number\"\r\n [formControl]=\"minLitNumber\"\r\n placeholder=\"min.\"\r\n />\r\n </mat-form-field>\r\n -\r\n <mat-form-field style=\"width: 5em\">\r\n <input\r\n matInput\r\n type=\"number\"\r\n [formControl]=\"maxLitNumber\"\r\n placeholder=\"max.\"\r\n />\r\n </mat-form-field>\r\n </div>\r\n <div\r\n class=\"btn-group\"\r\n role=\"group\"\r\n aria-label=\"toolbar\"\r\n style=\"margin-bottom: 10px\"\r\n >\r\n <button\r\n mat-icon-button\r\n type=\"button\"\r\n (click)=\"reset()\"\r\n matTooltip=\"Reset filters\"\r\n [disabled]=\"disabled()\"\r\n >\r\n <mat-icon class=\"mat-warn\">clear</mat-icon>\r\n </button>\r\n <button\r\n type=\"submit\"\r\n mat-icon-button\r\n [disabled]=\"disabled()\"\r\n matTooltip=\"Apply filters\"\r\n >\r\n <mat-icon class=\"mat-primary\">check_circle</mat-icon>\r\n </button>\r\n </div>\r\n</form>\r\n", styles: [""], dependencies: [{ kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1$1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$1.NumberValueAccessor, selector: "input[type=number][formControlName],input[type=number][formControl],input[type=number][ngModel]" }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],[formArray],form:not([ngNoForm]),[ngForm]" }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i1$1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "directive", type: i1$1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "component", type: MatPaginator, selector: "mat-paginator", inputs: ["color", "pageIndex", "length", "pageSize", "pageSizeOptions", "hidePageSize", "showFirstLastButtons", "selectConfig", "disabled"], outputs: ["page"], exportAs: ["matPaginator"] }, { kind: "component", type: RefLookupComponent, selector: "cadmus-refs-lookup", inputs: ["label", "limit", "baseFilter", "service", "item", "itemId", "required", "hasMore", "linkTemplate", "optDialog", "options", "lookupProviderOptions"], outputs: ["itemChange", "optionsChange", "moreRequest"] }, { kind: "component", type: MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly", "disabledInteractive"], exportAs: ["matInput"] }, { kind: "component", type: MatIconButton, selector: "button[mat-icon-button], a[mat-icon-button], button[matIconButton], a[matIconButton]", exportAs: ["matButton", "matAnchor"] }, { kind: "directive", type: MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "component", type: MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
1235
1230
|
}
|
|
1236
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1231
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: LinkedLiteralFilterComponent, decorators: [{
|
|
1237
1232
|
type: Component,
|
|
1238
1233
|
args: [{ selector: 'cadmus-walker-linked-literal-filter', imports: [
|
|
1239
1234
|
FormsModule,
|
|
@@ -1245,8 +1240,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.0", ngImpor
|
|
|
1245
1240
|
MatIconButton,
|
|
1246
1241
|
MatTooltip,
|
|
1247
1242
|
MatIcon,
|
|
1248
|
-
], template: "<form [formGroup]=\"form\" (submit)=\"apply()\" [attr.disabled]=\"disabled()\">\r\n <!-- paginator -->\r\n @if (hasPager()) {\r\n <mat-paginator\r\n [length]=\"total()\"\r\n [pageSize]=\"pageSize.value || 10\"\r\n [pageSizeOptions]=\"[5, 10, 20]\"\r\n (page)=\"onPageChange($event)\"\r\n aria-label=\"Select page\"\r\n />\r\n }\r\n\r\n <!-- subject ID -->\r\n <div>\r\n <cadmus-refs-lookup\r\n label=\"subject\"\r\n [service]=\"lookupService\"\r\n (itemChange)=\"onSubjectNodeChange($event)\"\r\n />\r\n </div>\r\n\r\n <!-- predicate ID -->\r\n <div>\r\n <cadmus-refs-lookup\r\n label=\"predicate\"\r\n [service]=\"lookupService\"\r\n [baseFilter]=\"{ tag: 'property' }\"\r\n (itemChange)=\"onPredicateNodeChange($event)\"\r\n />\r\n </div>\r\n\r\n <!-- LITERAL -->\r\n <!-- litPattern -->\r\n <div>\r\n <mat-form-field>\r\n <input matInput [formControl]=\"litPattern\" placeholder=\"pattern\" />\r\n </mat-form-field>\r\n </div>\r\n <!-- litType -->\r\n <div>\r\n <mat-form-field>\r\n <input matInput [formControl]=\"litType\" placeholder=\"type\" />\r\n </mat-form-field>\r\n </div>\r\n <!-- litLanguage-->\r\n <div>\r\n <mat-form-field>\r\n <input matInput [formControl]=\"litLanguage\" placeholder=\"language\" />\r\n </mat-form-field>\r\n </div>\r\n <!-- minLitNumber, maxLitNumber -->\r\n <div>\r\n <mat-form-field style=\"width: 5em\">\r\n <input\r\n matInput\r\n type=\"number\"\r\n [formControl]=\"minLitNumber\"\r\n placeholder=\"min.\"\r\n />\r\n </mat-form-field>\r\n -\r\n <mat-form-field style=\"width: 5em\">\r\n <input\r\n matInput\r\n type=\"number\"\r\n [formControl]=\"maxLitNumber\"\r\n placeholder=\"max.\"\r\n />\r\n </mat-form-field>\r\n </div>\r\n <div\r\n class=\"btn-group\"\r\n role=\"group\"\r\n aria-label=\"toolbar\"\r\n style=\"margin-bottom: 10px\"\r\n >\r\n <button\r\n mat-icon-button\r\n type=\"button\"\r\n (click)=\"reset()\"\r\n matTooltip=\"Reset filters\"\r\n [disabled]=\"disabled()\"\r\n >\r\n <mat-icon class=\"mat-warn\">clear</mat-icon>\r\n </button>\r\n <button\r\n type=\"submit\"\r\n mat-icon-button\r\n [disabled]=\"disabled()\"\r\n matTooltip=\"Apply filters\"\r\n >\r\n <mat-icon class=\"mat-primary\">check_circle</mat-icon>\r\n </button>\r\n </div>\r\n</form>\r\n" }]
|
|
1249
|
-
}], ctorParameters: () => [{ type: i1$1.FormBuilder }, { type: i2$1.GraphNodeLookupService }, { type: i3$1.GraphService }] });
|
|
1243
|
+
], changeDetection: ChangeDetectionStrategy.OnPush, template: "<form [formGroup]=\"form\" (submit)=\"apply()\" [attr.disabled]=\"disabled()\">\r\n <!-- paginator -->\r\n @if (hasPager()) {\r\n <mat-paginator\r\n [length]=\"total()\"\r\n [pageSize]=\"pageSize.value || 10\"\r\n [pageSizeOptions]=\"[5, 10, 20]\"\r\n (page)=\"onPageChange($event)\"\r\n aria-label=\"Select page\"\r\n />\r\n }\r\n\r\n <!-- subject ID -->\r\n <div>\r\n <cadmus-refs-lookup\r\n label=\"subject\"\r\n [service]=\"lookupService\"\r\n (itemChange)=\"onSubjectNodeChange($event)\"\r\n />\r\n </div>\r\n\r\n <!-- predicate ID -->\r\n <div>\r\n <cadmus-refs-lookup\r\n label=\"predicate\"\r\n [service]=\"lookupService\"\r\n [baseFilter]=\"{ tag: 'property' }\"\r\n (itemChange)=\"onPredicateNodeChange($event)\"\r\n />\r\n </div>\r\n\r\n <!-- LITERAL -->\r\n <!-- litPattern -->\r\n <div>\r\n <mat-form-field>\r\n <input matInput [formControl]=\"litPattern\" placeholder=\"pattern\" />\r\n </mat-form-field>\r\n </div>\r\n <!-- litType -->\r\n <div>\r\n <mat-form-field>\r\n <input matInput [formControl]=\"litType\" placeholder=\"type\" />\r\n </mat-form-field>\r\n </div>\r\n <!-- litLanguage-->\r\n <div>\r\n <mat-form-field>\r\n <input matInput [formControl]=\"litLanguage\" placeholder=\"language\" />\r\n </mat-form-field>\r\n </div>\r\n <!-- minLitNumber, maxLitNumber -->\r\n <div>\r\n <mat-form-field style=\"width: 5em\">\r\n <input\r\n matInput\r\n type=\"number\"\r\n [formControl]=\"minLitNumber\"\r\n placeholder=\"min.\"\r\n />\r\n </mat-form-field>\r\n -\r\n <mat-form-field style=\"width: 5em\">\r\n <input\r\n matInput\r\n type=\"number\"\r\n [formControl]=\"maxLitNumber\"\r\n placeholder=\"max.\"\r\n />\r\n </mat-form-field>\r\n </div>\r\n <div\r\n class=\"btn-group\"\r\n role=\"group\"\r\n aria-label=\"toolbar\"\r\n style=\"margin-bottom: 10px\"\r\n >\r\n <button\r\n mat-icon-button\r\n type=\"button\"\r\n (click)=\"reset()\"\r\n matTooltip=\"Reset filters\"\r\n [disabled]=\"disabled()\"\r\n >\r\n <mat-icon class=\"mat-warn\">clear</mat-icon>\r\n </button>\r\n <button\r\n type=\"submit\"\r\n mat-icon-button\r\n [disabled]=\"disabled()\"\r\n matTooltip=\"Apply filters\"\r\n >\r\n <mat-icon class=\"mat-primary\">check_circle</mat-icon>\r\n </button>\r\n </div>\r\n</form>\r\n" }]
|
|
1244
|
+
}], ctorParameters: () => [{ type: i1$1.FormBuilder }, { type: i2$1.GraphNodeLookupService }, { type: i3$1.GraphService }], propDecorators: { disabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabled", required: false }] }], hasPager: [{ type: i0.Input, args: [{ isSignal: true, alias: "hasPager", required: false }] }], total: [{ type: i0.Input, args: [{ isSignal: true, alias: "total", required: false }] }], filter: [{ type: i0.Input, args: [{ isSignal: true, alias: "filter", required: false }] }, { type: i0.Output, args: ["filterChange"] }] } });
|
|
1250
1245
|
|
|
1251
1246
|
/**
|
|
1252
1247
|
* Get the extended label for the specified graph node. This returns the label
|
|
@@ -1265,10 +1260,10 @@ class GraphNodeLabelPipe {
|
|
|
1265
1260
|
}
|
|
1266
1261
|
return node.label;
|
|
1267
1262
|
}
|
|
1268
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1269
|
-
static ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "
|
|
1263
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: GraphNodeLabelPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
|
|
1264
|
+
static ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "21.2.0", ngImport: i0, type: GraphNodeLabelPipe, isStandalone: true, name: "graphNodeLabel" });
|
|
1270
1265
|
}
|
|
1271
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1266
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: GraphNodeLabelPipe, decorators: [{
|
|
1272
1267
|
type: Pipe,
|
|
1273
1268
|
args: [{ name: 'graphNodeLabel' }]
|
|
1274
1269
|
}] });
|
|
@@ -2044,7 +2039,7 @@ class GraphWalkerComponent {
|
|
|
2044
2039
|
/**
|
|
2045
2040
|
* The graph visualization mode (2D or 3D).
|
|
2046
2041
|
*/
|
|
2047
|
-
graphMode = '2d';
|
|
2042
|
+
graphMode = signal('2d', ...(ngDevMode ? [{ debugName: "graphMode" }] : []));
|
|
2048
2043
|
/**
|
|
2049
2044
|
* Emitted when a graph node is picked by user.
|
|
2050
2045
|
*/
|
|
@@ -2164,7 +2159,7 @@ class GraphWalkerComponent {
|
|
|
2164
2159
|
this._walker?.toggleNode(node);
|
|
2165
2160
|
}
|
|
2166
2161
|
onGraphModeChange(mode) {
|
|
2167
|
-
this.graphMode
|
|
2162
|
+
this.graphMode.set(mode);
|
|
2168
2163
|
}
|
|
2169
2164
|
onPOutFilterChange(filter) {
|
|
2170
2165
|
this._walker?.expandSelectedProperty(filter);
|
|
@@ -2195,10 +2190,10 @@ class GraphWalkerComponent {
|
|
|
2195
2190
|
this.nodePick.emit(node);
|
|
2196
2191
|
}
|
|
2197
2192
|
}
|
|
2198
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
2199
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "
|
|
2193
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: GraphWalkerComponent, deps: [{ token: i1$2.DialogService }], target: i0.ɵɵFactoryTarget.Component });
|
|
2194
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.0", type: GraphWalkerComponent, isStandalone: true, selector: "cadmus-graph-walker", inputs: { nodeId: { classPropertyName: "nodeId", publicName: "nodeId", isSignal: true, isRequired: false, transformFunction: null }, graphService: { classPropertyName: "graphService", publicName: "graphService", isSignal: true, isRequired: false, transformFunction: null }, canPick: { classPropertyName: "canPick", publicName: "canPick", isSignal: true, isRequired: false, transformFunction: null }, canMoveToSource: { classPropertyName: "canMoveToSource", publicName: "canMoveToSource", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { nodePick: "nodePick", moveToSource: "moveToSource" }, ngImport: i0, template: "<div id=\"container\">\r\n <!-- graph -->\r\n <div id=\"graph\">\r\n <cadmus-force-graph-renderer\r\n [nodes]=\"(nodes$ | async) || []\"\r\n [edges]=\"(edges$ | async) || []\"\r\n [mode]=\"graphMode()\"\r\n [update$]=\"update$\"\r\n [center$]=\"center$\"\r\n [zoomToFit$]=\"zoomToFit$\"\r\n (nodeSelect)=\"onNodeSelect($event)\"\r\n (nodeDoubleClick)=\"onNodeDblClick($event)\"\r\n (modeChange)=\"onGraphModeChange($event)\"\r\n />\r\n </div>\r\n\r\n <!-- tools -->\r\n <div id=\"tools\">\r\n <div id=\"bar\">\r\n <button\r\n type=\"button\"\r\n mat-icon-button\r\n matTooltip=\"Center\"\r\n (click)=\"center$.next(true)\"\r\n >\r\n <mat-icon>filter_center_focus</mat-icon>\r\n </button>\r\n <button\r\n type=\"button\"\r\n mat-icon-button\r\n matTooltip=\"Zoom to fit\"\r\n (click)=\"zoomToFit$.next({ force: true })\"\r\n >\r\n <mat-icon>fit_screen</mat-icon>\r\n </button>\r\n <button\r\n type=\"button\"\r\n mat-icon-button\r\n matTooltip=\"Reset\"\r\n (click)=\"update$.next(true)\"\r\n >\r\n <mat-icon class=\"mat-warn\">restart_alt</mat-icon>\r\n </button>\r\n @if (nodes$ | async; as nodes) {\r\n <span class=\"muted\"\r\n >N:{{ nodes.length }} E:{{ (edges$ | async)?.length }}</span\r\n >\r\n } @if (selectedNode$ | async; as selectedNode) {\r\n <button\r\n type=\"button\"\r\n mat-icon-button\r\n matTooltip=\"Toggle the selected node\"\r\n [disabled]=\"!selectedNode\"\r\n (click)=\"onNodeDblClick(selectedNode)\"\r\n >\r\n <mat-icon class=\"mat-primary\">unfold_more</mat-icon>\r\n </button>\r\n } @if (canPick()) {\r\n <button\r\n type=\"button\"\r\n mat-icon-button\r\n [matTooltip]=\"\r\n canMoveToSource()\r\n ? 'Pick selected node or (shift) its source'\r\n : 'Pick the selected node'\r\n \"\r\n [disabled]=\"!(selectedNode$ | async)\"\r\n (click)=\"pickSelectedNode($event)\"\r\n >\r\n <mat-icon class=\"mat-primary\">check_circle</mat-icon>\r\n </button>\r\n }\r\n </div>\r\n <!-- progress -->\r\n <div id=\"progress\">\r\n @if (loading$ | async) {\r\n <mat-progress-bar mode=\"indeterminate\"></mat-progress-bar>\r\n }\r\n </div>\r\n <div id=\"filters\">\r\n @if (selectedNode$ | async; as node) {\r\n <div id=\"filter-head\">\r\n <span [style.color]=\"node.data.color || 'black'\">⬤</span>\r\n <span class=\"node-uri\" matTooltip=\"{{ node.data.uri }}\">{{\r\n node | graphNodeLabel\r\n }}</span>\r\n <span class=\"muted node-id\">{{\r\n node.id\r\n }}</span>\r\n </div>\r\n }\r\n <mat-tab-group>\r\n <!-- N-outs -->\r\n @if (nOutFilter$ | async; as nOutFilter) {\r\n <mat-tab>\r\n <ng-template mat-tab-label>\r\n N<mat-icon>logout</mat-icon>\r\n </ng-template>\r\n <cadmus-walker-triple-filter\r\n [filter]=\"nOutFilter\"\r\n (filterChange)=\"onNOutFilterChange($event)\"\r\n ></cadmus-walker-triple-filter>\r\n </mat-tab>\r\n }\r\n <!-- N-ins -->\r\n @if (nInFilter$ | async; as nInFilter) {\r\n <mat-tab>\r\n <ng-template mat-tab-label> N<mat-icon>login</mat-icon> </ng-template>\r\n <cadmus-walker-triple-filter\r\n [filter]=\"nInFilter\"\r\n (filterChange)=\"onNInFilterChange($event)\"\r\n ></cadmus-walker-triple-filter>\r\n </mat-tab>\r\n }\r\n <!-- P-outs -->\r\n @if (pOutFilter$ | async; as pOutFilter) {\r\n <mat-tab>\r\n <ng-template mat-tab-label>\r\n P<mat-icon>logout</mat-icon>\r\n </ng-template>\r\n <cadmus-walker-linked-node-filter\r\n [filter]=\"pOutFilter\"\r\n (filterChange)=\"onPOutFilterChange($event)\"\r\n />\r\n </mat-tab>\r\n }\r\n <!-- P-ins -->\r\n @if (pInFilter$ | async; as pInFilter) {\r\n <mat-tab>\r\n <ng-template mat-tab-label> P<mat-icon>login</mat-icon> </ng-template>\r\n <cadmus-walker-linked-node-filter\r\n [filter]=\"pInFilter\"\r\n (filterChange)=\"onPInFilterChange($event)\"\r\n />\r\n </mat-tab>\r\n }\r\n <!-- P-lit -->\r\n @if (pLitFilter$ | async; as pLitFilter) {\r\n <mat-tab>\r\n <ng-template mat-tab-label>\r\n P<mat-icon>exit_to_app</mat-icon>\r\n </ng-template>\r\n <cadmus-walker-linked-literal-filter\r\n [filter]=\"pLitFilter\"\r\n (filterChange)=\"onPLitFilterChange($event)\"\r\n />\r\n </mat-tab>\r\n }\r\n </mat-tab-group>\r\n </div>\r\n </div>\r\n</div>\r\n", styles: ["div#filter-head{border:1px solid #f8f1ae;border-radius:4px;padding:4px;margin-bottom:4px;background-color:#f8f1ae;text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.muted{color:silver}.node-uri{margin-left:6px}.node-id{margin-left:8px;font-size:90%}.selected{stroke-width:2px;stroke:#e7d211}#container{width:100%;max-width:100%;height:100vh;max-height:100vh;display:grid;grid-template-rows:1fr;grid-template-columns:324px 1fr;grid-template-areas:\"tools graph\";gap:8px}#graph{grid-area:graph;min-height:500px}#tools{grid-area:tools;padding:8px;border:1px solid silver;height:100%;max-height:100%;min-width:324px;max-width:324px;background-color:#fdfdfd;overflow-y:auto}#tools #bar{display:flex;align-items:center;flex-wrap:wrap}@media only screen and (max-width:959px){#container{height:100vh;grid-template-rows:auto 1fr;grid-template-columns:1fr;grid-template-areas:\"tools\" \"graph\"}#graph{min-height:400px}}\n"], dependencies: [{ kind: "component", type: ForceGraphRendererComponent, selector: "cadmus-force-graph-renderer", inputs: ["nodes", "edges", "mode", "update$", "center$", "zoomToFit$"], outputs: ["nodeSelect", "nodeDoubleClick", "modeChange"] }, { kind: "component", type: MatIconButton, selector: "button[mat-icon-button], a[mat-icon-button], button[matIconButton], a[matIconButton]", exportAs: ["matButton", "matAnchor"] }, { kind: "directive", type: MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "component", type: MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "component", type: MatProgressBar, selector: "mat-progress-bar", inputs: ["color", "value", "bufferValue", "mode"], outputs: ["animationEnd"], exportAs: ["matProgressBar"] }, { kind: "component", type: MatTabGroup, selector: "mat-tab-group", inputs: ["color", "fitInkBarToContent", "mat-stretch-tabs", "mat-align-tabs", "dynamicHeight", "selectedIndex", "headerPosition", "animationDuration", "contentTabIndex", "disablePagination", "disableRipple", "preserveContent", "backgroundColor", "aria-label", "aria-labelledby"], outputs: ["selectedIndexChange", "focusChange", "animationDone", "selectedTabChange"], exportAs: ["matTabGroup"] }, { kind: "component", type: MatTab, selector: "mat-tab", inputs: ["disabled", "label", "aria-label", "aria-labelledby", "labelClass", "bodyClass", "id"], exportAs: ["matTab"] }, { kind: "directive", type: MatTabLabel, selector: "[mat-tab-label], [matTabLabel]" }, { kind: "component", type: TripleFilterComponent, selector: "cadmus-walker-triple-filter", inputs: ["disabled", "hasPager", "total", "filter"], outputs: ["filterChange"] }, { kind: "component", type: LinkedNodeFilterComponent, selector: "cadmus-walker-linked-node-filter", inputs: ["disabled", "hasPager", "total", "filter"], outputs: ["filterChange"] }, { kind: "component", type: LinkedLiteralFilterComponent, selector: "cadmus-walker-linked-literal-filter", inputs: ["disabled", "hasPager", "total", "filter"], outputs: ["filterChange"] }, { kind: "pipe", type: AsyncPipe, name: "async" }, { kind: "pipe", type: GraphNodeLabelPipe, name: "graphNodeLabel" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
2200
2195
|
}
|
|
2201
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
2196
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: GraphWalkerComponent, decorators: [{
|
|
2202
2197
|
type: Component,
|
|
2203
2198
|
args: [{ selector: 'cadmus-graph-walker', imports: [
|
|
2204
2199
|
ForceGraphRendererComponent,
|
|
@@ -2214,8 +2209,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.0", ngImpor
|
|
|
2214
2209
|
LinkedLiteralFilterComponent,
|
|
2215
2210
|
AsyncPipe,
|
|
2216
2211
|
GraphNodeLabelPipe,
|
|
2217
|
-
], template: "<div id=\"container\">\r\n <!-- graph -->\r\n <div id=\"graph\">\r\n <cadmus-force-graph-renderer\r\n [nodes]=\"(nodes$ | async) || []\"\r\n [edges]=\"(edges$ | async) || []\"\r\n [mode]=\"graphMode\"\r\n [update$]=\"update$\"\r\n [center$]=\"center$\"\r\n [zoomToFit$]=\"zoomToFit$\"\r\n (nodeSelect)=\"onNodeSelect($event)\"\r\n (nodeDoubleClick)=\"onNodeDblClick($event)\"\r\n (modeChange)=\"onGraphModeChange($event)\"\r\n />\r\n </div>\r\n\r\n <!-- tools -->\r\n <div id=\"tools\">\r\n <div id=\"bar\">\r\n <button\r\n type=\"button\"\r\n mat-icon-button\r\n matTooltip=\"Center\"\r\n (click)=\"center$.next(true)\"\r\n >\r\n <mat-icon>filter_center_focus</mat-icon>\r\n </button>\r\n <button\r\n type=\"button\"\r\n mat-icon-button\r\n matTooltip=\"Zoom to fit\"\r\n (click)=\"zoomToFit$.next({ force: true })\"\r\n >\r\n <mat-icon>fit_screen</mat-icon>\r\n </button>\r\n <button\r\n type=\"button\"\r\n mat-icon-button\r\n matTooltip=\"Reset\"\r\n (click)=\"update$.next(true)\"\r\n >\r\n <mat-icon class=\"mat-warn\">restart_alt</mat-icon>\r\n </button>\r\n @if (nodes$ | async; as nodes) {\r\n <span class=\"muted\"\r\n >N:{{ nodes.length }} E:{{ (edges$ | async)?.length }}</span\r\n >\r\n } @if (selectedNode$ | async; as selectedNode) {\r\n <button\r\n type=\"button\"\r\n mat-icon-button\r\n matTooltip=\"Toggle the selected node\"\r\n [disabled]=\"!selectedNode\"\r\n (click)=\"onNodeDblClick(selectedNode)\"\r\n >\r\n <mat-icon class=\"mat-primary\">unfold_more</mat-icon>\r\n </button>\r\n } @if (canPick()) {\r\n <button\r\n type=\"button\"\r\n mat-icon-button\r\n [matTooltip]=\"\r\n canMoveToSource()\r\n ? 'Pick selected node or (shift) its source'\r\n : 'Pick the selected node'\r\n \"\r\n [disabled]=\"!(selectedNode$ | async)\"\r\n (click)=\"pickSelectedNode($event)\"\r\n >\r\n <mat-icon class=\"mat-primary\">check_circle</mat-icon>\r\n </button>\r\n }\r\n </div>\r\n <!-- progress -->\r\n <div id=\"progress\">\r\n @if (loading$ | async) {\r\n <mat-progress-bar mode=\"indeterminate\"></mat-progress-bar>\r\n }\r\n </div>\r\n <div id=\"filters\">\r\n @if (selectedNode$ | async; as node) {\r\n <div id=\"filter-head\">\r\n <span [style.color]=\"node.data.color || 'black'\">⬤</span>\r\n <span class=\"node-uri\" matTooltip=\"{{ node.data.uri }}\">{{\r\n node | graphNodeLabel\r\n }}</span>\r\n <span class=\"muted node-id\">{{\r\n node.id\r\n }}</span>\r\n </div>\r\n }\r\n <mat-tab-group>\r\n <!-- N-outs -->\r\n @if (nOutFilter$ | async; as nOutFilter) {\r\n <mat-tab>\r\n <ng-template mat-tab-label>\r\n N<mat-icon>logout</mat-icon>\r\n </ng-template>\r\n <cadmus-walker-triple-filter\r\n [filter]=\"nOutFilter\"\r\n (filterChange)=\"onNOutFilterChange($event)\"\r\n ></cadmus-walker-triple-filter>\r\n </mat-tab>\r\n }\r\n <!-- N-ins -->\r\n @if (nInFilter$ | async; as nInFilter) {\r\n <mat-tab>\r\n <ng-template mat-tab-label> N<mat-icon>login</mat-icon> </ng-template>\r\n <cadmus-walker-triple-filter\r\n [filter]=\"nInFilter\"\r\n (filterChange)=\"onNInFilterChange($event)\"\r\n ></cadmus-walker-triple-filter>\r\n </mat-tab>\r\n }\r\n <!-- P-outs -->\r\n @if (pOutFilter$ | async; as pOutFilter) {\r\n <mat-tab>\r\n <ng-template mat-tab-label>\r\n P<mat-icon>logout</mat-icon>\r\n </ng-template>\r\n <cadmus-walker-linked-node-filter\r\n [filter]=\"pOutFilter\"\r\n (filterChange)=\"onPOutFilterChange($event)\"\r\n />\r\n </mat-tab>\r\n }\r\n <!-- P-ins -->\r\n @if (pInFilter$ | async; as pInFilter) {\r\n <mat-tab>\r\n <ng-template mat-tab-label> P<mat-icon>login</mat-icon> </ng-template>\r\n <cadmus-walker-linked-node-filter\r\n [filter]=\"pInFilter\"\r\n (filterChange)=\"onPInFilterChange($event)\"\r\n />\r\n </mat-tab>\r\n }\r\n <!-- P-lit -->\r\n @if (pLitFilter$ | async; as pLitFilter) {\r\n <mat-tab>\r\n <ng-template mat-tab-label>\r\n P<mat-icon>exit_to_app</mat-icon>\r\n </ng-template>\r\n <cadmus-walker-linked-literal-filter\r\n [filter]=\"pLitFilter\"\r\n (filterChange)=\"onPLitFilterChange($event)\"\r\n />\r\n </mat-tab>\r\n }\r\n </mat-tab-group>\r\n </div>\r\n </div>\r\n</div>\r\n", styles: ["div#filter-head{border:1px solid #f8f1ae;border-radius:4px;padding:4px;margin-bottom:4px;background-color:#f8f1ae;text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.muted{color:silver}.node-uri{margin-left:6px}.node-id{margin-left:8px;font-size:90%}.selected{stroke-width:2px;stroke:#e7d211}#container{width:100%;max-width:100%;height:100vh;max-height:100vh;display:grid;grid-template-rows:1fr;grid-template-columns:324px 1fr;grid-template-areas:\"tools graph\";gap:8px}#graph{grid-area:graph;min-height:500px}#tools{grid-area:tools;padding:8px;border:1px solid silver;height:100%;max-height:100%;min-width:324px;max-width:324px;background-color:#fdfdfd;overflow-y:auto}#tools #bar{display:flex;align-items:center;flex-wrap:wrap}@media only screen and (max-width:
|
|
2218
|
-
}], ctorParameters: () => [{ type: i1$2.DialogService }] });
|
|
2212
|
+
], changeDetection: ChangeDetectionStrategy.OnPush, template: "<div id=\"container\">\r\n <!-- graph -->\r\n <div id=\"graph\">\r\n <cadmus-force-graph-renderer\r\n [nodes]=\"(nodes$ | async) || []\"\r\n [edges]=\"(edges$ | async) || []\"\r\n [mode]=\"graphMode()\"\r\n [update$]=\"update$\"\r\n [center$]=\"center$\"\r\n [zoomToFit$]=\"zoomToFit$\"\r\n (nodeSelect)=\"onNodeSelect($event)\"\r\n (nodeDoubleClick)=\"onNodeDblClick($event)\"\r\n (modeChange)=\"onGraphModeChange($event)\"\r\n />\r\n </div>\r\n\r\n <!-- tools -->\r\n <div id=\"tools\">\r\n <div id=\"bar\">\r\n <button\r\n type=\"button\"\r\n mat-icon-button\r\n matTooltip=\"Center\"\r\n (click)=\"center$.next(true)\"\r\n >\r\n <mat-icon>filter_center_focus</mat-icon>\r\n </button>\r\n <button\r\n type=\"button\"\r\n mat-icon-button\r\n matTooltip=\"Zoom to fit\"\r\n (click)=\"zoomToFit$.next({ force: true })\"\r\n >\r\n <mat-icon>fit_screen</mat-icon>\r\n </button>\r\n <button\r\n type=\"button\"\r\n mat-icon-button\r\n matTooltip=\"Reset\"\r\n (click)=\"update$.next(true)\"\r\n >\r\n <mat-icon class=\"mat-warn\">restart_alt</mat-icon>\r\n </button>\r\n @if (nodes$ | async; as nodes) {\r\n <span class=\"muted\"\r\n >N:{{ nodes.length }} E:{{ (edges$ | async)?.length }}</span\r\n >\r\n } @if (selectedNode$ | async; as selectedNode) {\r\n <button\r\n type=\"button\"\r\n mat-icon-button\r\n matTooltip=\"Toggle the selected node\"\r\n [disabled]=\"!selectedNode\"\r\n (click)=\"onNodeDblClick(selectedNode)\"\r\n >\r\n <mat-icon class=\"mat-primary\">unfold_more</mat-icon>\r\n </button>\r\n } @if (canPick()) {\r\n <button\r\n type=\"button\"\r\n mat-icon-button\r\n [matTooltip]=\"\r\n canMoveToSource()\r\n ? 'Pick selected node or (shift) its source'\r\n : 'Pick the selected node'\r\n \"\r\n [disabled]=\"!(selectedNode$ | async)\"\r\n (click)=\"pickSelectedNode($event)\"\r\n >\r\n <mat-icon class=\"mat-primary\">check_circle</mat-icon>\r\n </button>\r\n }\r\n </div>\r\n <!-- progress -->\r\n <div id=\"progress\">\r\n @if (loading$ | async) {\r\n <mat-progress-bar mode=\"indeterminate\"></mat-progress-bar>\r\n }\r\n </div>\r\n <div id=\"filters\">\r\n @if (selectedNode$ | async; as node) {\r\n <div id=\"filter-head\">\r\n <span [style.color]=\"node.data.color || 'black'\">⬤</span>\r\n <span class=\"node-uri\" matTooltip=\"{{ node.data.uri }}\">{{\r\n node | graphNodeLabel\r\n }}</span>\r\n <span class=\"muted node-id\">{{\r\n node.id\r\n }}</span>\r\n </div>\r\n }\r\n <mat-tab-group>\r\n <!-- N-outs -->\r\n @if (nOutFilter$ | async; as nOutFilter) {\r\n <mat-tab>\r\n <ng-template mat-tab-label>\r\n N<mat-icon>logout</mat-icon>\r\n </ng-template>\r\n <cadmus-walker-triple-filter\r\n [filter]=\"nOutFilter\"\r\n (filterChange)=\"onNOutFilterChange($event)\"\r\n ></cadmus-walker-triple-filter>\r\n </mat-tab>\r\n }\r\n <!-- N-ins -->\r\n @if (nInFilter$ | async; as nInFilter) {\r\n <mat-tab>\r\n <ng-template mat-tab-label> N<mat-icon>login</mat-icon> </ng-template>\r\n <cadmus-walker-triple-filter\r\n [filter]=\"nInFilter\"\r\n (filterChange)=\"onNInFilterChange($event)\"\r\n ></cadmus-walker-triple-filter>\r\n </mat-tab>\r\n }\r\n <!-- P-outs -->\r\n @if (pOutFilter$ | async; as pOutFilter) {\r\n <mat-tab>\r\n <ng-template mat-tab-label>\r\n P<mat-icon>logout</mat-icon>\r\n </ng-template>\r\n <cadmus-walker-linked-node-filter\r\n [filter]=\"pOutFilter\"\r\n (filterChange)=\"onPOutFilterChange($event)\"\r\n />\r\n </mat-tab>\r\n }\r\n <!-- P-ins -->\r\n @if (pInFilter$ | async; as pInFilter) {\r\n <mat-tab>\r\n <ng-template mat-tab-label> P<mat-icon>login</mat-icon> </ng-template>\r\n <cadmus-walker-linked-node-filter\r\n [filter]=\"pInFilter\"\r\n (filterChange)=\"onPInFilterChange($event)\"\r\n />\r\n </mat-tab>\r\n }\r\n <!-- P-lit -->\r\n @if (pLitFilter$ | async; as pLitFilter) {\r\n <mat-tab>\r\n <ng-template mat-tab-label>\r\n P<mat-icon>exit_to_app</mat-icon>\r\n </ng-template>\r\n <cadmus-walker-linked-literal-filter\r\n [filter]=\"pLitFilter\"\r\n (filterChange)=\"onPLitFilterChange($event)\"\r\n />\r\n </mat-tab>\r\n }\r\n </mat-tab-group>\r\n </div>\r\n </div>\r\n</div>\r\n", styles: ["div#filter-head{border:1px solid #f8f1ae;border-radius:4px;padding:4px;margin-bottom:4px;background-color:#f8f1ae;text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.muted{color:silver}.node-uri{margin-left:6px}.node-id{margin-left:8px;font-size:90%}.selected{stroke-width:2px;stroke:#e7d211}#container{width:100%;max-width:100%;height:100vh;max-height:100vh;display:grid;grid-template-rows:1fr;grid-template-columns:324px 1fr;grid-template-areas:\"tools graph\";gap:8px}#graph{grid-area:graph;min-height:500px}#tools{grid-area:tools;padding:8px;border:1px solid silver;height:100%;max-height:100%;min-width:324px;max-width:324px;background-color:#fdfdfd;overflow-y:auto}#tools #bar{display:flex;align-items:center;flex-wrap:wrap}@media only screen and (max-width:959px){#container{height:100vh;grid-template-rows:auto 1fr;grid-template-columns:1fr;grid-template-areas:\"tools\" \"graph\"}#graph{min-height:400px}}\n"] }]
|
|
2213
|
+
}], ctorParameters: () => [{ type: i1$2.DialogService }], propDecorators: { nodeId: [{ type: i0.Input, args: [{ isSignal: true, alias: "nodeId", required: false }] }], graphService: [{ type: i0.Input, args: [{ isSignal: true, alias: "graphService", required: false }] }], canPick: [{ type: i0.Input, args: [{ isSignal: true, alias: "canPick", required: false }] }], canMoveToSource: [{ type: i0.Input, args: [{ isSignal: true, alias: "canMoveToSource", required: false }] }], nodePick: [{ type: i0.Output, args: ["nodePick"] }], moveToSource: [{ type: i0.Output, args: ["moveToSource"] }] } });
|
|
2219
2214
|
|
|
2220
2215
|
/**
|
|
2221
2216
|
* Graph interfaces to replace ngx-graph types
|