@tooluminati/angular-troubleshooting 0.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.
- package/LICENSE +21 -0
- package/dist/declarative-form.directives.d.ts +14 -0
- package/dist/declarative-form.directives.d.ts.map +1 -0
- package/dist/declarative-form.directives.js +36 -0
- package/dist/index.d.ts +5 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +4 -0
- package/dist/provide-web-mcp-troubleshooting.d.ts +30 -0
- package/dist/provide-web-mcp-troubleshooting.d.ts.map +1 -0
- package/dist/provide-web-mcp-troubleshooting.js +159 -0
- package/dist/troubleshooting-tokens.d.ts +23 -0
- package/dist/troubleshooting-tokens.d.ts.map +1 -0
- package/dist/troubleshooting-tokens.js +27 -0
- package/dist/web-mcp-troubleshooting-panel.component.d.ts +23 -0
- package/dist/web-mcp-troubleshooting-panel.component.d.ts.map +1 -0
- package/dist/web-mcp-troubleshooting-panel.component.js +173 -0
- package/package.json +59 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 jitterbox
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import * as i0 from "@angular/core";
|
|
2
|
+
export declare class WebMcpFormDirective {
|
|
3
|
+
readonly toolName: import("@angular/core").InputSignal<string>;
|
|
4
|
+
readonly toolDescription: import("@angular/core").InputSignal<string>;
|
|
5
|
+
readonly autoSubmit: import("@angular/core").InputSignal<boolean>;
|
|
6
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<WebMcpFormDirective, never>;
|
|
7
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<WebMcpFormDirective, "form[webMcpForm]", never, { "toolName": { "alias": "webMcpForm"; "required": true; "isSignal": true; }; "toolDescription": { "alias": "toolDescription"; "required": true; "isSignal": true; }; "autoSubmit": { "alias": "webMcpAutoSubmit"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
8
|
+
}
|
|
9
|
+
export declare class WebMcpParamDescriptionDirective {
|
|
10
|
+
readonly webMcpParamDescription: import("@angular/core").InputSignal<string>;
|
|
11
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<WebMcpParamDescriptionDirective, never>;
|
|
12
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<WebMcpParamDescriptionDirective, "[webMcpParamDescription]", never, { "webMcpParamDescription": { "alias": "webMcpParamDescription"; "required": true; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
13
|
+
}
|
|
14
|
+
//# sourceMappingURL=declarative-form.directives.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"declarative-form.directives.d.ts","sourceRoot":"","sources":["../src/declarative-form.directives.ts"],"names":[],"mappings":";AAEA,qBASa,mBAAmB;IAC9B,QAAQ,CAAC,QAAQ,8CAAmD;IACpE,QAAQ,CAAC,eAAe,8CAA4B;IACpD,QAAQ,CAAC,UAAU,+CAA+C;yCAHvD,mBAAmB;2CAAnB,mBAAmB;CAI/B;AAED,qBAOa,+BAA+B;IAC1C,QAAQ,CAAC,sBAAsB,8CAA4B;yCADhD,+BAA+B;2CAA/B,+BAA+B;CAE3C"}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import { Directive, input } from '@angular/core';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
3
|
+
export class WebMcpFormDirective {
|
|
4
|
+
toolName = input.required(...(ngDevMode ? [{ debugName: "toolName", alias: 'webMcpForm' }] : [{ alias: 'webMcpForm' }]));
|
|
5
|
+
toolDescription = input.required(...(ngDevMode ? [{ debugName: "toolDescription" }] : []));
|
|
6
|
+
autoSubmit = input(false, ...(ngDevMode ? [{ debugName: "autoSubmit", alias: 'webMcpAutoSubmit' }] : [{ alias: 'webMcpAutoSubmit' }]));
|
|
7
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.25", ngImport: i0, type: WebMcpFormDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
8
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "20.3.25", type: WebMcpFormDirective, isStandalone: true, selector: "form[webMcpForm]", inputs: { toolName: { classPropertyName: "toolName", publicName: "webMcpForm", isSignal: true, isRequired: true, transformFunction: null }, toolDescription: { classPropertyName: "toolDescription", publicName: "toolDescription", isSignal: true, isRequired: true, transformFunction: null }, autoSubmit: { classPropertyName: "autoSubmit", publicName: "webMcpAutoSubmit", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "attr.toolname": "toolName()", "attr.tooldescription": "toolDescription()", "attr.toolautosubmit": "autoSubmit() ? \"\" : null" } }, ngImport: i0 });
|
|
9
|
+
}
|
|
10
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.25", ngImport: i0, type: WebMcpFormDirective, decorators: [{
|
|
11
|
+
type: Directive,
|
|
12
|
+
args: [{
|
|
13
|
+
selector: 'form[webMcpForm]',
|
|
14
|
+
standalone: true,
|
|
15
|
+
host: {
|
|
16
|
+
'[attr.toolname]': 'toolName()',
|
|
17
|
+
'[attr.tooldescription]': 'toolDescription()',
|
|
18
|
+
'[attr.toolautosubmit]': 'autoSubmit() ? "" : null',
|
|
19
|
+
},
|
|
20
|
+
}]
|
|
21
|
+
}], propDecorators: { toolName: [{ type: i0.Input, args: [{ isSignal: true, alias: "webMcpForm", required: true }] }], toolDescription: [{ type: i0.Input, args: [{ isSignal: true, alias: "toolDescription", required: true }] }], autoSubmit: [{ type: i0.Input, args: [{ isSignal: true, alias: "webMcpAutoSubmit", required: false }] }] } });
|
|
22
|
+
export class WebMcpParamDescriptionDirective {
|
|
23
|
+
webMcpParamDescription = input.required(...(ngDevMode ? [{ debugName: "webMcpParamDescription" }] : []));
|
|
24
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.25", ngImport: i0, type: WebMcpParamDescriptionDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
25
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "20.3.25", type: WebMcpParamDescriptionDirective, isStandalone: true, selector: "[webMcpParamDescription]", inputs: { webMcpParamDescription: { classPropertyName: "webMcpParamDescription", publicName: "webMcpParamDescription", isSignal: true, isRequired: true, transformFunction: null } }, host: { properties: { "attr.toolparamdescription": "webMcpParamDescription()" } }, ngImport: i0 });
|
|
26
|
+
}
|
|
27
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.25", ngImport: i0, type: WebMcpParamDescriptionDirective, decorators: [{
|
|
28
|
+
type: Directive,
|
|
29
|
+
args: [{
|
|
30
|
+
selector: '[webMcpParamDescription]',
|
|
31
|
+
standalone: true,
|
|
32
|
+
host: {
|
|
33
|
+
'[attr.toolparamdescription]': 'webMcpParamDescription()',
|
|
34
|
+
},
|
|
35
|
+
}]
|
|
36
|
+
}], propDecorators: { webMcpParamDescription: [{ type: i0.Input, args: [{ isSignal: true, alias: "webMcpParamDescription", required: true }] }] } });
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,mCAAmC,CAAC;AAClD,cAAc,0BAA0B,CAAC;AACzC,cAAc,2CAA2C,CAAC;AAC1D,cAAc,+BAA+B,CAAC"}
|
package/dist/index.js
ADDED
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { EnvironmentProviders, ErrorHandler, type WritableSignal } from '@angular/core';
|
|
2
|
+
import type { WebMcpToolDescriptor } from '@tooluminati/core';
|
|
3
|
+
import { type ActionAvailabilityProvider, type QuerySummary, type TroubleshootingPanelSnapshot } from '@tooluminati/diagnostics';
|
|
4
|
+
import * as i0 from "@angular/core";
|
|
5
|
+
export interface WebMcpTroubleshootingPanelOptions {
|
|
6
|
+
enabled?: boolean | 'auto';
|
|
7
|
+
render?: boolean | 'auto' | boolean;
|
|
8
|
+
position?: 'br' | 'bl' | 'tr' | 'tl';
|
|
9
|
+
startCollapsed?: boolean;
|
|
10
|
+
pollMs?: number | null;
|
|
11
|
+
allowUrlOverride?: boolean;
|
|
12
|
+
eventLimit?: number;
|
|
13
|
+
}
|
|
14
|
+
export interface WebMcpTroubleshootingConfig {
|
|
15
|
+
enabled?: boolean;
|
|
16
|
+
actionProvider?: ActionAvailabilityProvider;
|
|
17
|
+
querySummaries?: () => QuerySummary[];
|
|
18
|
+
trackFetchFailures?: boolean;
|
|
19
|
+
panel?: WebMcpTroubleshootingPanelOptions;
|
|
20
|
+
extraTools?: WebMcpToolDescriptor[];
|
|
21
|
+
}
|
|
22
|
+
export declare class WebMcpTroubleshootingErrorHandler implements ErrorHandler {
|
|
23
|
+
private readonly services;
|
|
24
|
+
handleError(error: unknown): void;
|
|
25
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<WebMcpTroubleshootingErrorHandler, never>;
|
|
26
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<WebMcpTroubleshootingErrorHandler>;
|
|
27
|
+
}
|
|
28
|
+
export declare function provideWebMcpTroubleshooting(config?: WebMcpTroubleshootingConfig): EnvironmentProviders;
|
|
29
|
+
export declare function injectTroubleshootingPanel(): WritableSignal<TroubleshootingPanelSnapshot>;
|
|
30
|
+
//# sourceMappingURL=provide-web-mcp-troubleshooting.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"provide-web-mcp-troubleshooting.d.ts","sourceRoot":"","sources":["../src/provide-web-mcp-troubleshooting.ts"],"names":[],"mappings":"AAAA,OAAO,EAKL,oBAAoB,EACpB,YAAY,EAOZ,KAAK,cAAc,EACpB,MAAM,eAAe,CAAC;AACvB,OAAO,KAAK,EAAkB,oBAAoB,EAAE,MAAM,mBAAmB,CAAC;AAC9E,OAAO,EAsBL,KAAK,0BAA0B,EAC/B,KAAK,YAAY,EACjB,KAAK,4BAA4B,EAClC,MAAM,0BAA0B,CAAC;;AAUlC,MAAM,WAAW,iCAAiC;IAChD,OAAO,CAAC,EAAE,OAAO,GAAG,MAAM,CAAC;IAC3B,MAAM,CAAC,EAAE,OAAO,GAAG,MAAM,GAAG,OAAO,CAAC;IACpC,QAAQ,CAAC,EAAE,IAAI,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,CAAC;IACrC,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB,MAAM,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACvB,gBAAgB,CAAC,EAAE,OAAO,CAAC;IAC3B,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB;AAED,MAAM,WAAW,2BAA2B;IAC1C,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,cAAc,CAAC,EAAE,0BAA0B,CAAC;IAC5C,cAAc,CAAC,EAAE,MAAM,YAAY,EAAE,CAAC;IACtC,kBAAkB,CAAC,EAAE,OAAO,CAAC;IAC7B,KAAK,CAAC,EAAE,iCAAiC,CAAC;IAC1C,UAAU,CAAC,EAAE,oBAAoB,EAAE,CAAC;CACrC;AA+BD,qBACa,iCAAkC,YAAW,YAAY;IACpE,OAAO,CAAC,QAAQ,CAAC,QAAQ,CAAmC;IAE5D,WAAW,CAAC,KAAK,EAAE,OAAO,GAAG,IAAI;yCAHtB,iCAAiC;6CAAjC,iCAAiC;CAa7C;AAED,wBAAgB,4BAA4B,CAC1C,MAAM,GAAE,2BAAgC,GACvC,oBAAoB,CAoItB;AAED,wBAAgB,0BAA0B,iDAEzC"}
|
|
@@ -0,0 +1,159 @@
|
|
|
1
|
+
import { ApplicationRef, createComponent, DestroyRef, EnvironmentInjector, ErrorHandler, inject, Injectable, isDevMode, makeEnvironmentProviders, provideEnvironmentInitializer, signal, } from '@angular/core';
|
|
2
|
+
import { ClientErrorBuffer, TroubleshootingTimelineBuffer, createErrorCollector, createFetchFailureTracker, createActionAvailabilityTool, createListActionsTool, createMountedFormsRegistry, createMountedFormsSummaryTool, createRecentClientErrorsTool, createTimelineFromErrorBuffer, createTroubleshootingPanelViewModel, createTroubleshootingTimelineTool, createWebMcpEnvironmentSummary, createWebMcpEnvironmentTool, createWebMcpLifecycleCollector, createWorkflowBlockersTool, discoverDeclarativeForms, formSummaryFromMounted, isPanelEnabledByDefault, isPanelUrlOverrideEnabled, createTroubleshootingPanelVisibilityController, } from '@tooluminati/diagnostics';
|
|
3
|
+
import { injectWebMcpRegistry, provideWebMcpRegistry } from '@tooluminati/angular';
|
|
4
|
+
import { WEB_MCP_PANEL_VISIBILITY, WEB_MCP_TROUBLESHOOTING, wireAngularPanelVisibilityController, } from './troubleshooting-tokens';
|
|
5
|
+
import { WebMcpTroubleshootingPanelComponent } from './web-mcp-troubleshooting-panel.component';
|
|
6
|
+
import * as i0 from "@angular/core";
|
|
7
|
+
function isAngularPanelEnabled(panel) {
|
|
8
|
+
if (panel?.enabled === true) {
|
|
9
|
+
return true;
|
|
10
|
+
}
|
|
11
|
+
if (panel?.enabled === false) {
|
|
12
|
+
return false;
|
|
13
|
+
}
|
|
14
|
+
return (isPanelEnabledByDefault(panel?.enabled) ||
|
|
15
|
+
isPanelUrlOverrideEnabled(panel?.allowUrlOverride) ||
|
|
16
|
+
(panel?.enabled === 'auto' || panel?.enabled === undefined) && isDevMode());
|
|
17
|
+
}
|
|
18
|
+
function shouldAutoRenderPanel(panel, panelEnabled) {
|
|
19
|
+
return (panelEnabled &&
|
|
20
|
+
panel?.render !== false &&
|
|
21
|
+
(panel?.render === true ||
|
|
22
|
+
panel?.render === 'auto' ||
|
|
23
|
+
panel?.render === undefined));
|
|
24
|
+
}
|
|
25
|
+
export class WebMcpTroubleshootingErrorHandler {
|
|
26
|
+
services = inject(WEB_MCP_TROUBLESHOOTING);
|
|
27
|
+
handleError(error) {
|
|
28
|
+
const err = error instanceof Error ? error : new Error(String(error));
|
|
29
|
+
this.services.errors.push({
|
|
30
|
+
message: err.message,
|
|
31
|
+
source: '@angular/core ErrorHandler',
|
|
32
|
+
timestamp: new Date().toISOString(),
|
|
33
|
+
...(err.stack ? { stack: err.stack } : {}),
|
|
34
|
+
});
|
|
35
|
+
console.error(err);
|
|
36
|
+
}
|
|
37
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.25", ngImport: i0, type: WebMcpTroubleshootingErrorHandler, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
38
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.3.25", ngImport: i0, type: WebMcpTroubleshootingErrorHandler });
|
|
39
|
+
}
|
|
40
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.25", ngImport: i0, type: WebMcpTroubleshootingErrorHandler, decorators: [{
|
|
41
|
+
type: Injectable
|
|
42
|
+
}] });
|
|
43
|
+
export function provideWebMcpTroubleshooting(config = {}) {
|
|
44
|
+
const timeline = new TroubleshootingTimelineBuffer();
|
|
45
|
+
const errors = new ClientErrorBuffer({ includeStacks: true });
|
|
46
|
+
const mountedForms = createMountedFormsRegistry();
|
|
47
|
+
const visibility = createTroubleshootingPanelVisibilityController({
|
|
48
|
+
...(config.panel?.startCollapsed !== undefined
|
|
49
|
+
? { startCollapsed: config.panel.startCollapsed }
|
|
50
|
+
: {}),
|
|
51
|
+
});
|
|
52
|
+
wireAngularPanelVisibilityController(visibility);
|
|
53
|
+
const panelEnabled = isAngularPanelEnabled(config.panel);
|
|
54
|
+
const registryRef = { current: undefined };
|
|
55
|
+
const viewModel = createTroubleshootingPanelViewModel({
|
|
56
|
+
timeline,
|
|
57
|
+
errors,
|
|
58
|
+
environment: () => createWebMcpEnvironmentSummary({ registry: registryRef.current }),
|
|
59
|
+
...(registryRef.current ? { registry: registryRef.current } : {}),
|
|
60
|
+
}, {
|
|
61
|
+
...(config.panel?.eventLimit !== undefined
|
|
62
|
+
? { eventLimit: config.panel.eventLimit }
|
|
63
|
+
: {}),
|
|
64
|
+
pollMs: config.panel?.pollMs ?? 2000,
|
|
65
|
+
});
|
|
66
|
+
const diagnosticTools = [
|
|
67
|
+
createTroubleshootingTimelineTool(timeline),
|
|
68
|
+
createWebMcpEnvironmentTool(() => createWebMcpEnvironmentSummary({ registry: registryRef.current })),
|
|
69
|
+
createRecentClientErrorsTool(errors),
|
|
70
|
+
createMountedFormsSummaryTool(mountedForms),
|
|
71
|
+
createWorkflowBlockersTool({
|
|
72
|
+
...(config.actionProvider ? { actionProvider: config.actionProvider } : {}),
|
|
73
|
+
formSummaries: () => mountedForms.list().map(formSummaryFromMounted),
|
|
74
|
+
declarativeFormSummaries: () => discoverDeclarativeForms(),
|
|
75
|
+
recentErrors: () => errors.list(),
|
|
76
|
+
...(config.querySummaries ? { querySummaries: config.querySummaries } : {}),
|
|
77
|
+
}),
|
|
78
|
+
...(config.actionProvider
|
|
79
|
+
? [
|
|
80
|
+
createActionAvailabilityTool(config.actionProvider),
|
|
81
|
+
createListActionsTool(config.actionProvider),
|
|
82
|
+
]
|
|
83
|
+
: []),
|
|
84
|
+
...(config.extraTools ?? []),
|
|
85
|
+
];
|
|
86
|
+
const panelSnapshot = signal(viewModel.refresh(), ...(ngDevMode ? [{ debugName: "panelSnapshot" }] : []));
|
|
87
|
+
const services = {
|
|
88
|
+
timeline,
|
|
89
|
+
errors,
|
|
90
|
+
mountedForms,
|
|
91
|
+
viewModel,
|
|
92
|
+
visibility,
|
|
93
|
+
isPanelEnabled: panelEnabled,
|
|
94
|
+
panelOptions: config.panel ?? {},
|
|
95
|
+
panelSnapshot,
|
|
96
|
+
};
|
|
97
|
+
viewModel.subscribe(() => {
|
|
98
|
+
panelSnapshot.set(viewModel.refresh());
|
|
99
|
+
});
|
|
100
|
+
visibility.subscribe(() => {
|
|
101
|
+
panelSnapshot.set(viewModel.refresh());
|
|
102
|
+
});
|
|
103
|
+
const providers = [
|
|
104
|
+
provideWebMcpRegistry({
|
|
105
|
+
...(config.enabled !== undefined ? { enabled: config.enabled } : {}),
|
|
106
|
+
tools: diagnosticTools,
|
|
107
|
+
}),
|
|
108
|
+
{ provide: WEB_MCP_TROUBLESHOOTING, useValue: services },
|
|
109
|
+
{ provide: WEB_MCP_PANEL_VISIBILITY, useValue: visibility },
|
|
110
|
+
{ provide: ErrorHandler, useClass: WebMcpTroubleshootingErrorHandler },
|
|
111
|
+
provideEnvironmentInitializer(() => {
|
|
112
|
+
registryRef.current = injectWebMcpRegistry();
|
|
113
|
+
const destroyRef = inject(DestroyRef);
|
|
114
|
+
const cleanups = [
|
|
115
|
+
createErrorCollector({ buffer: errors }),
|
|
116
|
+
createTimelineFromErrorBuffer(errors, timeline),
|
|
117
|
+
createWebMcpLifecycleCollector({ buffer: timeline }),
|
|
118
|
+
];
|
|
119
|
+
if (config.trackFetchFailures !== false) {
|
|
120
|
+
cleanups.push(createFetchFailureTracker({ buffer: timeline }));
|
|
121
|
+
}
|
|
122
|
+
destroyRef.onDestroy(() => {
|
|
123
|
+
for (const cleanup of cleanups) {
|
|
124
|
+
cleanup();
|
|
125
|
+
}
|
|
126
|
+
viewModel.dispose();
|
|
127
|
+
});
|
|
128
|
+
}),
|
|
129
|
+
];
|
|
130
|
+
if (shouldAutoRenderPanel(config.panel, panelEnabled)) {
|
|
131
|
+
providers.push(provideEnvironmentInitializer(() => {
|
|
132
|
+
const appRef = inject(ApplicationRef);
|
|
133
|
+
const envInjector = inject(EnvironmentInjector);
|
|
134
|
+
const host = document.createElement('div');
|
|
135
|
+
document.body.appendChild(host);
|
|
136
|
+
const compRef = createComponent(WebMcpTroubleshootingPanelComponent, {
|
|
137
|
+
environmentInjector: envInjector,
|
|
138
|
+
hostElement: host,
|
|
139
|
+
});
|
|
140
|
+
compRef.setInput('startCollapsed', config.panel?.startCollapsed ?? false);
|
|
141
|
+
if (config.panel?.eventLimit !== undefined) {
|
|
142
|
+
compRef.setInput('eventLimit', config.panel.eventLimit);
|
|
143
|
+
}
|
|
144
|
+
if (config.panel?.position) {
|
|
145
|
+
compRef.setInput('position', config.panel.position);
|
|
146
|
+
}
|
|
147
|
+
appRef.attachView(compRef.hostView);
|
|
148
|
+
inject(DestroyRef).onDestroy(() => {
|
|
149
|
+
appRef.detachView(compRef.hostView);
|
|
150
|
+
compRef.destroy();
|
|
151
|
+
host.remove();
|
|
152
|
+
});
|
|
153
|
+
}));
|
|
154
|
+
}
|
|
155
|
+
return makeEnvironmentProviders(providers);
|
|
156
|
+
}
|
|
157
|
+
export function injectTroubleshootingPanel() {
|
|
158
|
+
return inject(WEB_MCP_TROUBLESHOOTING).panelSnapshot;
|
|
159
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { InjectionToken, type Provider } from '@angular/core';
|
|
2
|
+
import { type ClientErrorBuffer, type MountedFormsRegistry, type TroubleshootingPanelViewModel, type TroubleshootingPanelVisibilityController, type TroubleshootingTimelineBuffer } from '@tooluminati/diagnostics';
|
|
3
|
+
import type { WebMcpTroubleshootingPanelOptions } from './provide-web-mcp-troubleshooting';
|
|
4
|
+
import type { WritableSignal } from '@angular/core';
|
|
5
|
+
import type { TroubleshootingPanelSnapshot } from '@tooluminati/diagnostics';
|
|
6
|
+
export interface WebMcpTroubleshootingServices {
|
|
7
|
+
timeline: TroubleshootingTimelineBuffer;
|
|
8
|
+
errors: ClientErrorBuffer;
|
|
9
|
+
mountedForms: MountedFormsRegistry;
|
|
10
|
+
viewModel: TroubleshootingPanelViewModel;
|
|
11
|
+
visibility: TroubleshootingPanelVisibilityController;
|
|
12
|
+
isPanelEnabled: boolean;
|
|
13
|
+
panelOptions: WebMcpTroubleshootingPanelOptions;
|
|
14
|
+
panelSnapshot: WritableSignal<TroubleshootingPanelSnapshot>;
|
|
15
|
+
}
|
|
16
|
+
export declare const WEB_MCP_TROUBLESHOOTING: InjectionToken<WebMcpTroubleshootingServices>;
|
|
17
|
+
export declare const WEB_MCP_PANEL_VISIBILITY: InjectionToken<TroubleshootingPanelVisibilityController>;
|
|
18
|
+
export declare function wireAngularPanelVisibilityController(controller: TroubleshootingPanelVisibilityController): void;
|
|
19
|
+
export declare function webMcpShowTroubleshootingPanel(): void;
|
|
20
|
+
export declare function webMcpHideTroubleshootingPanel(): void;
|
|
21
|
+
export declare function webMcpToggleTroubleshootingPanel(): void;
|
|
22
|
+
export declare function provideWebMcpTroubleshootingPanel(): Provider[];
|
|
23
|
+
//# sourceMappingURL=troubleshooting-tokens.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"troubleshooting-tokens.d.ts","sourceRoot":"","sources":["../src/troubleshooting-tokens.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,KAAK,QAAQ,EAAE,MAAM,eAAe,CAAC;AAC9D,OAAO,EAEL,KAAK,iBAAiB,EACtB,KAAK,oBAAoB,EACzB,KAAK,6BAA6B,EAClC,KAAK,wCAAwC,EAC7C,KAAK,6BAA6B,EACnC,MAAM,0BAA0B,CAAC;AAClC,OAAO,KAAK,EAAE,iCAAiC,EAAE,MAAM,mCAAmC,CAAC;AAE3F,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,eAAe,CAAC;AACpD,OAAO,KAAK,EAAE,4BAA4B,EAAE,MAAM,0BAA0B,CAAC;AAE7E,MAAM,WAAW,6BAA6B;IAC5C,QAAQ,EAAE,6BAA6B,CAAC;IACxC,MAAM,EAAE,iBAAiB,CAAC;IAC1B,YAAY,EAAE,oBAAoB,CAAC;IACnC,SAAS,EAAE,6BAA6B,CAAC;IACzC,UAAU,EAAE,wCAAwC,CAAC;IACrD,cAAc,EAAE,OAAO,CAAC;IACxB,YAAY,EAAE,iCAAiC,CAAC;IAChD,aAAa,EAAE,cAAc,CAAC,4BAA4B,CAAC,CAAC;CAC7D;AAED,eAAO,MAAM,uBAAuB,+CAGjC,CAAC;AAEJ,eAAO,MAAM,wBAAwB,0DAGlC,CAAC;AAIJ,wBAAgB,oCAAoC,CAClD,UAAU,EAAE,wCAAwC,GACnD,IAAI,CAEN;AASD,wBAAgB,8BAA8B,IAAI,IAAI,CAErD;AAED,wBAAgB,8BAA8B,IAAI,IAAI,CAErD;AAED,wBAAgB,gCAAgC,IAAI,IAAI,CAEvD;AAED,wBAAgB,iCAAiC,IAAI,QAAQ,EAAE,CAE9D"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { InjectionToken } from '@angular/core';
|
|
2
|
+
import { createTroubleshootingPanelVisibilityController, } from '@tooluminati/diagnostics';
|
|
3
|
+
import { WebMcpTroubleshootingPanelComponent } from './web-mcp-troubleshooting-panel.component';
|
|
4
|
+
export const WEB_MCP_TROUBLESHOOTING = new InjectionToken('WEB_MCP_TROUBLESHOOTING');
|
|
5
|
+
export const WEB_MCP_PANEL_VISIBILITY = new InjectionToken('WEB_MCP_PANEL_VISIBILITY');
|
|
6
|
+
let panelVisibilityController;
|
|
7
|
+
export function wireAngularPanelVisibilityController(controller) {
|
|
8
|
+
panelVisibilityController = controller;
|
|
9
|
+
}
|
|
10
|
+
function getAngularPanelVisibilityController() {
|
|
11
|
+
if (!panelVisibilityController) {
|
|
12
|
+
panelVisibilityController = createTroubleshootingPanelVisibilityController();
|
|
13
|
+
}
|
|
14
|
+
return panelVisibilityController;
|
|
15
|
+
}
|
|
16
|
+
export function webMcpShowTroubleshootingPanel() {
|
|
17
|
+
getAngularPanelVisibilityController().show();
|
|
18
|
+
}
|
|
19
|
+
export function webMcpHideTroubleshootingPanel() {
|
|
20
|
+
getAngularPanelVisibilityController().hide();
|
|
21
|
+
}
|
|
22
|
+
export function webMcpToggleTroubleshootingPanel() {
|
|
23
|
+
getAngularPanelVisibilityController().toggle();
|
|
24
|
+
}
|
|
25
|
+
export function provideWebMcpTroubleshootingPanel() {
|
|
26
|
+
return [WebMcpTroubleshootingPanelComponent];
|
|
27
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { type OnDestroy, type OnInit } from '@angular/core';
|
|
2
|
+
import { type TimelineFilterGroup, type TroubleshootingPanelSnapshot } from '@tooluminati/diagnostics';
|
|
3
|
+
import * as i0 from "@angular/core";
|
|
4
|
+
export declare class WebMcpTroubleshootingPanelComponent implements OnInit, OnDestroy {
|
|
5
|
+
readonly services: import("./troubleshooting-tokens").WebMcpTroubleshootingServices;
|
|
6
|
+
private readonly cdr;
|
|
7
|
+
readonly position: import("@angular/core").InputSignal<"br" | "bl" | "tr" | "tl">;
|
|
8
|
+
readonly startCollapsed: import("@angular/core").InputSignal<boolean>;
|
|
9
|
+
readonly eventLimit: import("@angular/core").InputSignal<number>;
|
|
10
|
+
readonly filter: import("@angular/core").WritableSignal<TimelineFilterGroup>;
|
|
11
|
+
readonly chips: readonly ["all", "failures", "blocked", "tools", "nav"];
|
|
12
|
+
private unsubVm?;
|
|
13
|
+
private unsubVis?;
|
|
14
|
+
readonly snapshot: import("@angular/core").WritableSignal<TroubleshootingPanelSnapshot>;
|
|
15
|
+
readonly filteredEvents: import("@angular/core").Signal<import("@tooluminati/diagnostics").TroubleshootingPanelEventView[]>;
|
|
16
|
+
ngOnInit(): void;
|
|
17
|
+
ngOnDestroy(): void;
|
|
18
|
+
refresh(): void;
|
|
19
|
+
copy(): void;
|
|
20
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<WebMcpTroubleshootingPanelComponent, never>;
|
|
21
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<WebMcpTroubleshootingPanelComponent, "webmcp-troubleshooting-panel", never, { "position": { "alias": "position"; "required": false; "isSignal": true; }; "startCollapsed": { "alias": "startCollapsed"; "required": false; "isSignal": true; }; "eventLimit": { "alias": "eventLimit"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
22
|
+
}
|
|
23
|
+
//# sourceMappingURL=web-mcp-troubleshooting-panel.component.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"web-mcp-troubleshooting-panel.component.d.ts","sourceRoot":"","sources":["../src/web-mcp-troubleshooting-panel.component.ts"],"names":[],"mappings":"AAAA,OAAO,EAOL,KAAK,SAAS,EACd,KAAK,MAAM,EACZ,MAAM,eAAe,CAAC;AACvB,OAAO,EAGL,KAAK,mBAAmB,EACxB,KAAK,4BAA4B,EAClC,MAAM,0BAA0B,CAAC;;AAGlC,qBAwGa,mCAAoC,YAAW,MAAM,EAAE,SAAS;IAC3E,QAAQ,CAAC,QAAQ,mEAAmC;IACpD,OAAO,CAAC,QAAQ,CAAC,GAAG,CAA6B;IACjD,QAAQ,CAAC,QAAQ,iEAA0C;IAC3D,QAAQ,CAAC,cAAc,+CAAgB;IACvC,QAAQ,CAAC,UAAU,8CAAa;IAChC,QAAQ,CAAC,MAAM,8DAAsC;IACrD,QAAQ,CAAC,KAAK,0DAA2D;IACzE,OAAO,CAAC,OAAO,CAAC,CAAa;IAC7B,OAAO,CAAC,QAAQ,CAAC,CAAa;IAC9B,QAAQ,CAAC,QAAQ,uEAEf;IACF,QAAQ,CAAC,cAAc,qGAErB;IAEF,QAAQ,IAAI,IAAI;IAahB,WAAW,IAAI,IAAI;IAKnB,OAAO,IAAI,IAAI;IAIf,IAAI,IAAI,IAAI;yCAvCD,mCAAmC;2CAAnC,mCAAmC;CA2C/C"}
|
|
@@ -0,0 +1,173 @@
|
|
|
1
|
+
import { ChangeDetectorRef, Component, computed, inject, input, signal, } from '@angular/core';
|
|
2
|
+
import { filterPanelEvents, serializeTroubleshootingDiagnostics, } from '@tooluminati/diagnostics';
|
|
3
|
+
import { WEB_MCP_TROUBLESHOOTING } from './troubleshooting-tokens';
|
|
4
|
+
import * as i0 from "@angular/core";
|
|
5
|
+
export class WebMcpTroubleshootingPanelComponent {
|
|
6
|
+
services = inject(WEB_MCP_TROUBLESHOOTING);
|
|
7
|
+
cdr = inject(ChangeDetectorRef);
|
|
8
|
+
position = input('br', ...(ngDevMode ? [{ debugName: "position" }] : []));
|
|
9
|
+
startCollapsed = input(false, ...(ngDevMode ? [{ debugName: "startCollapsed" }] : []));
|
|
10
|
+
eventLimit = input(20, ...(ngDevMode ? [{ debugName: "eventLimit" }] : []));
|
|
11
|
+
filter = signal('all', ...(ngDevMode ? [{ debugName: "filter" }] : []));
|
|
12
|
+
chips = ['all', 'failures', 'blocked', 'tools', 'nav'];
|
|
13
|
+
unsubVm;
|
|
14
|
+
unsubVis;
|
|
15
|
+
snapshot = signal(this.services.viewModel.refresh(), ...(ngDevMode ? [{ debugName: "snapshot" }] : []));
|
|
16
|
+
filteredEvents = computed(() => filterPanelEvents(this.snapshot().events, this.filter()), ...(ngDevMode ? [{ debugName: "filteredEvents" }] : []));
|
|
17
|
+
ngOnInit() {
|
|
18
|
+
if (this.startCollapsed()) {
|
|
19
|
+
this.services.visibility.setCollapsed(true);
|
|
20
|
+
}
|
|
21
|
+
this.unsubVm = this.services.viewModel.subscribe(() => {
|
|
22
|
+
this.snapshot.set(this.services.viewModel.refresh());
|
|
23
|
+
this.cdr.markForCheck();
|
|
24
|
+
});
|
|
25
|
+
this.unsubVis = this.services.visibility.subscribe(() => {
|
|
26
|
+
this.cdr.markForCheck();
|
|
27
|
+
});
|
|
28
|
+
}
|
|
29
|
+
ngOnDestroy() {
|
|
30
|
+
this.unsubVm?.();
|
|
31
|
+
this.unsubVis?.();
|
|
32
|
+
}
|
|
33
|
+
refresh() {
|
|
34
|
+
this.snapshot.set(this.services.viewModel.refresh());
|
|
35
|
+
}
|
|
36
|
+
copy() {
|
|
37
|
+
const json = serializeTroubleshootingDiagnostics(this.snapshot());
|
|
38
|
+
void navigator.clipboard?.writeText(json);
|
|
39
|
+
}
|
|
40
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.25", ngImport: i0, type: WebMcpTroubleshootingPanelComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
41
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.25", type: WebMcpTroubleshootingPanelComponent, isStandalone: true, selector: "webmcp-troubleshooting-panel", inputs: { position: { classPropertyName: "position", publicName: "position", isSignal: true, isRequired: false, transformFunction: null }, startCollapsed: { classPropertyName: "startCollapsed", publicName: "startCollapsed", isSignal: true, isRequired: false, transformFunction: null }, eventLimit: { classPropertyName: "eventLimit", publicName: "eventLimit", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "style.position": "\"fixed\"", "style.z-index": "\"99990\"", "style.right.px": "position() === \"br\" || position() === \"tr\" ? 26 : null", "style.left.px": "position() === \"bl\" || position() === \"tl\" ? 26 : null", "style.bottom.px": "position() === \"br\" || position() === \"bl\" ? 26 : null", "style.top.px": "position() === \"tr\" || position() === \"tl\" ? 26 : null" } }, ngImport: i0, template: `
|
|
42
|
+
@if (services.isPanelEnabled && services.visibility.visible) {
|
|
43
|
+
@if (services.visibility.collapsed) {
|
|
44
|
+
<button
|
|
45
|
+
type="button"
|
|
46
|
+
class="tlm-badge"
|
|
47
|
+
data-testid="webmcp-troubleshooting-badge"
|
|
48
|
+
(click)="services.visibility.setCollapsed(false)"
|
|
49
|
+
>
|
|
50
|
+
WebMCP · {{ snapshot().toolCount }} tools
|
|
51
|
+
</button>
|
|
52
|
+
} @else {
|
|
53
|
+
<section
|
|
54
|
+
class="tlm-panel"
|
|
55
|
+
data-testid="webmcp-troubleshooting-panel"
|
|
56
|
+
[attr.data-state]="snapshot().panelState"
|
|
57
|
+
>
|
|
58
|
+
<header class="tlm-header">
|
|
59
|
+
<strong>WebMCP Troubleshooting</strong>
|
|
60
|
+
<button type="button" (click)="refresh()">Refresh</button>
|
|
61
|
+
<button type="button" (click)="copy()">Copy JSON</button>
|
|
62
|
+
<button type="button" (click)="services.visibility.setCollapsed(true)">–</button>
|
|
63
|
+
</header>
|
|
64
|
+
<div class="tlm-stats">
|
|
65
|
+
<span>{{ snapshot().supported ? 'Supported' : 'Unsupported' }}</span>
|
|
66
|
+
<span>{{ snapshot().toolCount }} tools</span>
|
|
67
|
+
<span>{{ snapshot().issueCount }} issues</span>
|
|
68
|
+
</div>
|
|
69
|
+
@if (snapshot().warnings.length) {
|
|
70
|
+
<div class="tlm-section">
|
|
71
|
+
<h3>Warnings</h3>
|
|
72
|
+
@for (warning of snapshot().warnings; track warning) {
|
|
73
|
+
<div class="tlm-row">{{ warning }}</div>
|
|
74
|
+
}
|
|
75
|
+
</div>
|
|
76
|
+
}
|
|
77
|
+
<div class="tlm-section">
|
|
78
|
+
<h3>Environment</h3>
|
|
79
|
+
@for (check of snapshot().checks; track check.id) {
|
|
80
|
+
<div class="tlm-row">{{ check.label }} · {{ check.value }}</div>
|
|
81
|
+
}
|
|
82
|
+
</div>
|
|
83
|
+
<div class="tlm-section">
|
|
84
|
+
<h3>Timeline</h3>
|
|
85
|
+
@for (chip of chips; track chip) {
|
|
86
|
+
<button type="button" (click)="filter.set(chip)">{{ chip }}</button>
|
|
87
|
+
}
|
|
88
|
+
@for (event of filteredEvents(); track event.id) {
|
|
89
|
+
<div class="tlm-row">{{ event.title }} · {{ event.time }}</div>
|
|
90
|
+
}
|
|
91
|
+
</div>
|
|
92
|
+
<div class="tlm-section">
|
|
93
|
+
<h3>Client Errors</h3>
|
|
94
|
+
@for (error of snapshot().errors; track error.id) {
|
|
95
|
+
<div class="tlm-row">{{ error.message }}</div>
|
|
96
|
+
}
|
|
97
|
+
</div>
|
|
98
|
+
</section>
|
|
99
|
+
}
|
|
100
|
+
}
|
|
101
|
+
`, isInline: true, styles: ["\n .tlm-badge,\n .tlm-panel {\n font-family: 'IBM Plex Sans', system-ui, sans-serif;\n }\n .tlm-panel {\n width: 412px;\n max-height: calc(100vh - 52px);\n overflow: auto;\n background: #0a0e1a;\n color: #eef2fa;\n border: 1px solid #1c2438;\n border-radius: 15px;\n padding: 12px;\n }\n .tlm-header {\n display: flex;\n gap: 8px;\n align-items: center;\n }\n .tlm-stats,\n .tlm-section {\n margin-top: 10px;\n }\n .tlm-row {\n font-size: 12px;\n padding: 4px 0;\n }\n "] });
|
|
102
|
+
}
|
|
103
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.25", ngImport: i0, type: WebMcpTroubleshootingPanelComponent, decorators: [{
|
|
104
|
+
type: Component,
|
|
105
|
+
args: [{ selector: 'webmcp-troubleshooting-panel', standalone: true, host: {
|
|
106
|
+
'[style.position]': '"fixed"',
|
|
107
|
+
'[style.z-index]': '"99990"',
|
|
108
|
+
'[style.right.px]': 'position() === "br" || position() === "tr" ? 26 : null',
|
|
109
|
+
'[style.left.px]': 'position() === "bl" || position() === "tl" ? 26 : null',
|
|
110
|
+
'[style.bottom.px]': 'position() === "br" || position() === "bl" ? 26 : null',
|
|
111
|
+
'[style.top.px]': 'position() === "tr" || position() === "tl" ? 26 : null',
|
|
112
|
+
}, template: `
|
|
113
|
+
@if (services.isPanelEnabled && services.visibility.visible) {
|
|
114
|
+
@if (services.visibility.collapsed) {
|
|
115
|
+
<button
|
|
116
|
+
type="button"
|
|
117
|
+
class="tlm-badge"
|
|
118
|
+
data-testid="webmcp-troubleshooting-badge"
|
|
119
|
+
(click)="services.visibility.setCollapsed(false)"
|
|
120
|
+
>
|
|
121
|
+
WebMCP · {{ snapshot().toolCount }} tools
|
|
122
|
+
</button>
|
|
123
|
+
} @else {
|
|
124
|
+
<section
|
|
125
|
+
class="tlm-panel"
|
|
126
|
+
data-testid="webmcp-troubleshooting-panel"
|
|
127
|
+
[attr.data-state]="snapshot().panelState"
|
|
128
|
+
>
|
|
129
|
+
<header class="tlm-header">
|
|
130
|
+
<strong>WebMCP Troubleshooting</strong>
|
|
131
|
+
<button type="button" (click)="refresh()">Refresh</button>
|
|
132
|
+
<button type="button" (click)="copy()">Copy JSON</button>
|
|
133
|
+
<button type="button" (click)="services.visibility.setCollapsed(true)">–</button>
|
|
134
|
+
</header>
|
|
135
|
+
<div class="tlm-stats">
|
|
136
|
+
<span>{{ snapshot().supported ? 'Supported' : 'Unsupported' }}</span>
|
|
137
|
+
<span>{{ snapshot().toolCount }} tools</span>
|
|
138
|
+
<span>{{ snapshot().issueCount }} issues</span>
|
|
139
|
+
</div>
|
|
140
|
+
@if (snapshot().warnings.length) {
|
|
141
|
+
<div class="tlm-section">
|
|
142
|
+
<h3>Warnings</h3>
|
|
143
|
+
@for (warning of snapshot().warnings; track warning) {
|
|
144
|
+
<div class="tlm-row">{{ warning }}</div>
|
|
145
|
+
}
|
|
146
|
+
</div>
|
|
147
|
+
}
|
|
148
|
+
<div class="tlm-section">
|
|
149
|
+
<h3>Environment</h3>
|
|
150
|
+
@for (check of snapshot().checks; track check.id) {
|
|
151
|
+
<div class="tlm-row">{{ check.label }} · {{ check.value }}</div>
|
|
152
|
+
}
|
|
153
|
+
</div>
|
|
154
|
+
<div class="tlm-section">
|
|
155
|
+
<h3>Timeline</h3>
|
|
156
|
+
@for (chip of chips; track chip) {
|
|
157
|
+
<button type="button" (click)="filter.set(chip)">{{ chip }}</button>
|
|
158
|
+
}
|
|
159
|
+
@for (event of filteredEvents(); track event.id) {
|
|
160
|
+
<div class="tlm-row">{{ event.title }} · {{ event.time }}</div>
|
|
161
|
+
}
|
|
162
|
+
</div>
|
|
163
|
+
<div class="tlm-section">
|
|
164
|
+
<h3>Client Errors</h3>
|
|
165
|
+
@for (error of snapshot().errors; track error.id) {
|
|
166
|
+
<div class="tlm-row">{{ error.message }}</div>
|
|
167
|
+
}
|
|
168
|
+
</div>
|
|
169
|
+
</section>
|
|
170
|
+
}
|
|
171
|
+
}
|
|
172
|
+
`, styles: ["\n .tlm-badge,\n .tlm-panel {\n font-family: 'IBM Plex Sans', system-ui, sans-serif;\n }\n .tlm-panel {\n width: 412px;\n max-height: calc(100vh - 52px);\n overflow: auto;\n background: #0a0e1a;\n color: #eef2fa;\n border: 1px solid #1c2438;\n border-radius: 15px;\n padding: 12px;\n }\n .tlm-header {\n display: flex;\n gap: 8px;\n align-items: center;\n }\n .tlm-stats,\n .tlm-section {\n margin-top: 10px;\n }\n .tlm-row {\n font-size: 12px;\n padding: 4px 0;\n }\n "] }]
|
|
173
|
+
}], propDecorators: { position: [{ type: i0.Input, args: [{ isSignal: true, alias: "position", required: false }] }], startCollapsed: [{ type: i0.Input, args: [{ isSignal: true, alias: "startCollapsed", required: false }] }], eventLimit: [{ type: i0.Input, args: [{ isSignal: true, alias: "eventLimit", required: false }] }] } });
|
package/package.json
ADDED
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@tooluminati/angular-troubleshooting",
|
|
3
|
+
"version": "0.1.0",
|
|
4
|
+
"description": "Angular troubleshooting bundle with timeline, blockers, and dev panel.",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"sideEffects": false,
|
|
7
|
+
"main": "./dist/index.js",
|
|
8
|
+
"module": "./dist/index.js",
|
|
9
|
+
"types": "./dist/index.d.ts",
|
|
10
|
+
"exports": {
|
|
11
|
+
".": {
|
|
12
|
+
"types": "./dist/index.d.ts",
|
|
13
|
+
"import": "./dist/index.js",
|
|
14
|
+
"default": "./dist/index.js"
|
|
15
|
+
}
|
|
16
|
+
},
|
|
17
|
+
"dependencies": {
|
|
18
|
+
"tslib": "^2.8.0",
|
|
19
|
+
"@tooluminati/forms": "0.1.0",
|
|
20
|
+
"@tooluminati/diagnostics": "0.1.0",
|
|
21
|
+
"@tooluminati/angular": "0.1.0",
|
|
22
|
+
"@tooluminati/policies": "0.1.0",
|
|
23
|
+
"@tooluminati/core": "0.1.0"
|
|
24
|
+
},
|
|
25
|
+
"peerDependencies": {
|
|
26
|
+
"@angular/core": "^20.0.0",
|
|
27
|
+
"@angular/forms": "^20.0.0"
|
|
28
|
+
},
|
|
29
|
+
"files": [
|
|
30
|
+
"dist"
|
|
31
|
+
],
|
|
32
|
+
"license": "MIT",
|
|
33
|
+
"publishConfig": {
|
|
34
|
+
"access": "public"
|
|
35
|
+
},
|
|
36
|
+
"keywords": [
|
|
37
|
+
"tooluminati",
|
|
38
|
+
"webmcp",
|
|
39
|
+
"angular",
|
|
40
|
+
"troubleshooting",
|
|
41
|
+
"diagnostics"
|
|
42
|
+
],
|
|
43
|
+
"repository": {
|
|
44
|
+
"type": "git",
|
|
45
|
+
"url": "git+https://github.com/jitterbox/Tooluminati.git",
|
|
46
|
+
"directory": "packages/angular-troubleshooting"
|
|
47
|
+
},
|
|
48
|
+
"bugs": {
|
|
49
|
+
"url": "https://github.com/jitterbox/Tooluminati/issues"
|
|
50
|
+
},
|
|
51
|
+
"homepage": "https://github.com/jitterbox/Tooluminati#readme",
|
|
52
|
+
"engines": {
|
|
53
|
+
"node": ">=18"
|
|
54
|
+
},
|
|
55
|
+
"scripts": {
|
|
56
|
+
"build": "ngc -p tsconfig.build.json",
|
|
57
|
+
"typecheck": "ngc -p tsconfig.json --noEmit"
|
|
58
|
+
}
|
|
59
|
+
}
|