@xxmachina/components 19.145.0 → 19.150.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/fesm2022/xxmachina-components-molecules-user-avatar-menu.mjs +10 -5
- package/fesm2022/xxmachina-components-molecules-weekly-header.mjs +2 -2
- package/fesm2022/xxmachina-components-organisms-calendar-section.mjs +2 -2
- package/fesm2022/xxmachina-components-organisms-xterm.mjs +282 -44
- package/fesm2022/xxmachina-components-pages-command.mjs +2 -2
- package/fesm2022/xxmachina-components-pages-query.mjs +2 -2
- package/fesm2022/xxmachina-components-pages-thread.mjs +2 -2
- package/fesm2022/xxmachina-components-templates-agent.mjs +2 -2
- package/fesm2022/xxmachina-components-templates-machina-icon-button-menu.mjs +2 -2
- package/fesm2022/xxmachina-components-templates-machina-menu.mjs +89 -0
- package/fesm2022/xxmachina-components.mjs +2 -2
- package/package.json +5 -1
- package/types/xxmachina-components-molecules-user-avatar-menu.d.ts +3 -1
- package/types/xxmachina-components-organisms-xterm.d.ts +76 -6
- package/types/xxmachina-components-templates-machina-menu.d.ts +19 -0
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import { inject, input, signal, computed, ChangeDetectionStrategy, Component } from '@angular/core';
|
|
2
|
+
import { inject, input, output, signal, computed, ChangeDetectionStrategy, Component } from '@angular/core';
|
|
3
3
|
import * as i1 from '@angular/material/button';
|
|
4
4
|
import { MatButtonModule } from '@angular/material/button';
|
|
5
5
|
import * as i2 from '@angular/material/divider';
|
|
@@ -18,7 +18,12 @@ class UserAvatarMenuMolecule extends NgAtomicComponent {
|
|
|
18
18
|
auth = inject(AuthService);
|
|
19
19
|
switcher = inject(WorkspaceSwitcherService, { optional: true });
|
|
20
20
|
signOutAction = input.required(...(ngDevMode ? [{ debugName: "signOutAction" }] : []));
|
|
21
|
+
workspaceSwitch = output();
|
|
21
22
|
imgError = signal(false, ...(ngDevMode ? [{ debugName: "imgError" }] : []));
|
|
23
|
+
switchTo(workspaceId) {
|
|
24
|
+
this.switcher?.switchTo(workspaceId);
|
|
25
|
+
this.workspaceSwitch.emit(workspaceId);
|
|
26
|
+
}
|
|
22
27
|
photoURL = computed(() => this.imgError() ? null : this.auth.auth()?.photoURL ?? null, ...(ngDevMode ? [{ debugName: "photoURL" }] : []));
|
|
23
28
|
email = computed(() => this.auth.auth()?.email ?? null, ...(ngDevMode ? [{ debugName: "email" }] : []));
|
|
24
29
|
initial = computed(() => {
|
|
@@ -27,7 +32,7 @@ class UserAvatarMenuMolecule extends NgAtomicComponent {
|
|
|
27
32
|
return source.charAt(0).toUpperCase();
|
|
28
33
|
}, ...(ngDevMode ? [{ debugName: "initial" }] : []));
|
|
29
34
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: UserAvatarMenuMolecule, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
30
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.1.6", type: UserAvatarMenuMolecule, isStandalone: true, selector: "molecules-user-avatar-menu", inputs: { signOutAction: { classPropertyName: "signOutAction", publicName: "signOutAction", isSignal: true, isRequired: true, transformFunction: null } }, usesInheritance: true, ngImport: i0, template: `
|
|
35
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.1.6", type: UserAvatarMenuMolecule, isStandalone: true, selector: "molecules-user-avatar-menu", inputs: { signOutAction: { classPropertyName: "signOutAction", publicName: "signOutAction", isSignal: true, isRequired: true, transformFunction: null } }, outputs: { workspaceSwitch: "workspaceSwitch" }, usesInheritance: true, ngImport: i0, template: `
|
|
31
36
|
<button mat-icon-button class="avatar-button" [matMenuTriggerFor]="menu" [matTooltip]="email() ?? ''">
|
|
32
37
|
@if (photoURL(); as url) {
|
|
33
38
|
<!-- crossorigin="anonymous": app は COEP: require-corp で cross-origin isolation しており、
|
|
@@ -43,7 +48,7 @@ class UserAvatarMenuMolecule extends NgAtomicComponent {
|
|
|
43
48
|
<div class="menu-header" mat-menu-item disabled>{{ email() }}</div>
|
|
44
49
|
<mat-divider/>
|
|
45
50
|
@for (workspace of switcher?.workspaces() ?? []; track workspace.id) {
|
|
46
|
-
<button mat-menu-item class="workspace-option" (click)="
|
|
51
|
+
<button mat-menu-item class="workspace-option" (click)="switchTo(workspace.id)">
|
|
47
52
|
<mat-icon>{{ workspace.id === switcher?.currentWorkspaceId() ? 'check' : '' }}</mat-icon>
|
|
48
53
|
{{ workspace.name }}
|
|
49
54
|
</button>
|
|
@@ -74,7 +79,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.6", ngImpor
|
|
|
74
79
|
<div class="menu-header" mat-menu-item disabled>{{ email() }}</div>
|
|
75
80
|
<mat-divider/>
|
|
76
81
|
@for (workspace of switcher?.workspaces() ?? []; track workspace.id) {
|
|
77
|
-
<button mat-menu-item class="workspace-option" (click)="
|
|
82
|
+
<button mat-menu-item class="workspace-option" (click)="switchTo(workspace.id)">
|
|
78
83
|
<mat-icon>{{ workspace.id === switcher?.currentWorkspaceId() ? 'check' : '' }}</mat-icon>
|
|
79
84
|
{{ workspace.name }}
|
|
80
85
|
</button>
|
|
@@ -86,7 +91,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.6", ngImpor
|
|
|
86
91
|
</button>
|
|
87
92
|
</mat-menu>
|
|
88
93
|
`, changeDetection: ChangeDetectionStrategy.OnPush, styles: [":host{display:inline-flex}.avatar-button{display:inline-flex;align-items:center;justify-content:center;overflow:hidden}.avatar-image{width:28px;height:28px;border-radius:50%;object-fit:cover}.avatar-initial{display:inline-flex;align-items:center;justify-content:center;width:28px;height:28px;border-radius:50%;background-color:var(--primary-color, #404040);color:var(--on-primary-color, #f0f0f0);font-size:14px;font-weight:500}\n"] }]
|
|
89
|
-
}], propDecorators: { signOutAction: [{ type: i0.Input, args: [{ isSignal: true, alias: "signOutAction", required: true }] }] } });
|
|
94
|
+
}], propDecorators: { signOutAction: [{ type: i0.Input, args: [{ isSignal: true, alias: "signOutAction", required: true }] }], workspaceSwitch: [{ type: i0.Output, args: ["workspaceSwitch"] }] } });
|
|
90
95
|
|
|
91
96
|
/**
|
|
92
97
|
* Generated bundle index. Do not edit.
|
|
@@ -12,7 +12,7 @@ class WeeklyHeaderMolecule {
|
|
|
12
12
|
<span>{{ day }}</span>
|
|
13
13
|
</div>
|
|
14
14
|
}
|
|
15
|
-
`, isInline: true, styles: [":host{display:block;--primary-color: #404040;--primary-color-SCOPED-IN-
|
|
15
|
+
`, isInline: true, styles: [":host{display:block;--primary-color: #404040;--primary-color-SCOPED-IN-i1MapsD8: var(--primary-color);--secondary-color: #B0B0B0;--secondary-color-SCOPED-IN-i1MapsD8: var(--secondary-color)}:host{display:grid;width:100%;grid-template-columns:repeat(7,1fr);background-color:var(--primary-color-SCOPED-IN-i1MapsD8)}:host .day-container{display:flex;justify-content:center;align-items:center;color:#fff;font-weight:700;width:calc(hvar(--width) / 7)}\n"] });
|
|
16
16
|
}
|
|
17
17
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: WeeklyHeaderMolecule, decorators: [{
|
|
18
18
|
type: Component,
|
|
@@ -22,7 +22,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.6", ngImpor
|
|
|
22
22
|
<span>{{ day }}</span>
|
|
23
23
|
</div>
|
|
24
24
|
}
|
|
25
|
-
`, styles: [":host{display:block;--primary-color: #404040;--primary-color-SCOPED-IN-
|
|
25
|
+
`, styles: [":host{display:block;--primary-color: #404040;--primary-color-SCOPED-IN-i1MapsD8: var(--primary-color);--secondary-color: #B0B0B0;--secondary-color-SCOPED-IN-i1MapsD8: var(--secondary-color)}:host{display:grid;width:100%;grid-template-columns:repeat(7,1fr);background-color:var(--primary-color-SCOPED-IN-i1MapsD8)}:host .day-container{display:flex;justify-content:center;align-items:center;color:#fff;font-weight:700;width:calc(hvar(--width) / 7)}\n"] }]
|
|
26
26
|
}], ctorParameters: () => [] });
|
|
27
27
|
|
|
28
28
|
/**
|
|
@@ -56,7 +56,7 @@ class CalendarSectionOrganism {
|
|
|
56
56
|
}
|
|
57
57
|
}
|
|
58
58
|
</div>
|
|
59
|
-
`, isInline: true, styles: [":host{display:block;--row: 80px;--row-SCOPED-IN-
|
|
59
|
+
`, isInline: true, styles: [":host{display:block;--row: 80px;--row-SCOPED-IN-6762F9mc: var(--row);--row-num: 0;--row-num-SCOPED-IN-6762F9mc: var(--row-num);--border-color: #9E9E9E;--border-color-SCOPED-IN-6762F9mc: var(--border-color);--primary-color: #404040;--primary-color-SCOPED-IN-6762F9mc: var(--primary-color);--secondary-color: #B0B0B0;--secondary-color-SCOPED-IN-6762F9mc: var(--secondary-color)}:host{width:100%;height:auto}:host .calendar.header molecules-weekly-header{--height: 32px}:host .calendar.contents{display:grid;width:var(--width);border:1px solid var(--border-color-SCOPED-IN-6762F9mc);grid-gap:1px;grid-template-columns:repeat(7,1fr);grid-template-rows:repeat(var(--row-num-SCOPED-IN-6762F9mc),var(--row-SCOPED-IN-6762F9mc));box-sizing:border-box;background-color:var(--border-color-SCOPED-IN-6762F9mc)}:host .calendar.contents molecules-daily-cell{--width: calc((var(--width) - 8px) / 7);--height: var(--row-SCOPED-IN-6762F9mc);background-color:#fff}:host .calendar.description{display:flex;justify-content:flex-end;width:var(--width);height:32px;padding-right:16px}:host .calendar.description .description.container{display:flex;flex-direction:row;justify-content:flex-end;align-items:center;font-size:12px}:host .calendar.description .description.container .circle{display:flex;width:20px;height:20px;justify-content:center;align-items:center;border-radius:50%;color:#fff;background:#00f}:host .calendar.description .description.container label{padding-left:4px;padding-right:8px}\n"], dependencies: [{ kind: "component", type: DailyCellMolecule, selector: "molecules-daily-cell", inputs: ["date", "schedules", "displayDate", "noSchedulesText", "toolTipText", "marked", "markingColor"] }, { kind: "component", type: WeeklyHeaderMolecule, selector: "molecules-weekly-header" }, { kind: "ngmodule", type: MatRippleModule }, { kind: "directive", type: i1.MatRipple, selector: "[mat-ripple], [matRipple]", inputs: ["matRippleColor", "matRippleUnbounded", "matRippleCentered", "matRippleRadius", "matRippleAnimation", "matRippleDisabled", "matRippleTrigger"], exportAs: ["matRipple"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
60
60
|
}
|
|
61
61
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: CalendarSectionOrganism, decorators: [{
|
|
62
62
|
type: Component,
|
|
@@ -90,7 +90,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.6", ngImpor
|
|
|
90
90
|
}
|
|
91
91
|
}
|
|
92
92
|
</div>
|
|
93
|
-
`, changeDetection: ChangeDetectionStrategy.OnPush, styles: [":host{display:block;--row: 80px;--row-SCOPED-IN-
|
|
93
|
+
`, changeDetection: ChangeDetectionStrategy.OnPush, styles: [":host{display:block;--row: 80px;--row-SCOPED-IN-6762F9mc: var(--row);--row-num: 0;--row-num-SCOPED-IN-6762F9mc: var(--row-num);--border-color: #9E9E9E;--border-color-SCOPED-IN-6762F9mc: var(--border-color);--primary-color: #404040;--primary-color-SCOPED-IN-6762F9mc: var(--primary-color);--secondary-color: #B0B0B0;--secondary-color-SCOPED-IN-6762F9mc: var(--secondary-color)}:host{width:100%;height:auto}:host .calendar.header molecules-weekly-header{--height: 32px}:host .calendar.contents{display:grid;width:var(--width);border:1px solid var(--border-color-SCOPED-IN-6762F9mc);grid-gap:1px;grid-template-columns:repeat(7,1fr);grid-template-rows:repeat(var(--row-num-SCOPED-IN-6762F9mc),var(--row-SCOPED-IN-6762F9mc));box-sizing:border-box;background-color:var(--border-color-SCOPED-IN-6762F9mc)}:host .calendar.contents molecules-daily-cell{--width: calc((var(--width) - 8px) / 7);--height: var(--row-SCOPED-IN-6762F9mc);background-color:#fff}:host .calendar.description{display:flex;justify-content:flex-end;width:var(--width);height:32px;padding-right:16px}:host .calendar.description .description.container{display:flex;flex-direction:row;justify-content:flex-end;align-items:center;font-size:12px}:host .calendar.description .description.container .circle{display:flex;width:20px;height:20px;justify-content:center;align-items:center;border-radius:50%;color:#fff;background:#00f}:host .calendar.description .description.container label{padding-left:4px;padding-right:8px}\n"] }]
|
|
94
94
|
}], propDecorators: { label: [{
|
|
95
95
|
type: Input
|
|
96
96
|
}], displayDays: [{
|
|
@@ -11,9 +11,7 @@ const MAX_SCAN_LINES = 30;
|
|
|
11
11
|
class WebLinkProvider {
|
|
12
12
|
_terminal;
|
|
13
13
|
_handler;
|
|
14
|
-
constructor(_terminal, _handler
|
|
15
|
-
window.open(uri, '_blank', 'noopener');
|
|
16
|
-
}) {
|
|
14
|
+
constructor(_terminal, _handler) {
|
|
17
15
|
this._terminal = _terminal;
|
|
18
16
|
this._handler = _handler;
|
|
19
17
|
}
|
|
@@ -53,7 +51,7 @@ class WebLinkProvider {
|
|
|
53
51
|
start: { x: startPos.x + 1, y: startPos.y + 1 },
|
|
54
52
|
end: { x: endPos.x + 1, y: endPos.y + 1 },
|
|
55
53
|
},
|
|
56
|
-
activate: (event, text) => this._handler(event, text),
|
|
54
|
+
activate: (event, text) => this._handler?.(event, text),
|
|
57
55
|
});
|
|
58
56
|
}
|
|
59
57
|
callback(links.length > 0 ? links : undefined);
|
|
@@ -290,6 +288,12 @@ class FileLinksAddon {
|
|
|
290
288
|
}
|
|
291
289
|
}
|
|
292
290
|
|
|
291
|
+
function createFileLinkActivateHandler(dispatch) {
|
|
292
|
+
return (_event, filePath, line, column) => {
|
|
293
|
+
dispatch({ filePath, line, column });
|
|
294
|
+
};
|
|
295
|
+
}
|
|
296
|
+
|
|
293
297
|
const SESSION_MENTION_REGEX = /(?:^|[\s((『「])@([a-z][a-z0-9]*(?:-[a-z0-9]+)*)(?![\w/-])(?!\.[a-z0-9])/g;
|
|
294
298
|
function extractSessionMentions(text) {
|
|
295
299
|
const mentions = [];
|
|
@@ -442,9 +446,7 @@ class ProxyLinkProvider {
|
|
|
442
446
|
_getEndpoints;
|
|
443
447
|
_onMissingToken;
|
|
444
448
|
_getEnv;
|
|
445
|
-
constructor(_terminal, _getServerUUID, _getToken, _handler
|
|
446
|
-
window.open(url, '_blank', 'noopener');
|
|
447
|
-
}, _getDeployVersion, _getEndpoints, _onMissingToken, _getEnv) {
|
|
449
|
+
constructor(_terminal, _getServerUUID, _getToken, _handler, _getDeployVersion, _getEndpoints, _onMissingToken, _getEnv) {
|
|
448
450
|
this._terminal = _terminal;
|
|
449
451
|
this._getServerUUID = _getServerUUID;
|
|
450
452
|
this._getToken = _getToken;
|
|
@@ -479,6 +481,10 @@ class ProxyLinkProvider {
|
|
|
479
481
|
end: { x: endX, y: bufferLineNumber },
|
|
480
482
|
},
|
|
481
483
|
activate: (event) => {
|
|
484
|
+
if (this._handler) {
|
|
485
|
+
this._handler(event, matchedUrl);
|
|
486
|
+
return;
|
|
487
|
+
}
|
|
482
488
|
const uuid = this._getServerUUID();
|
|
483
489
|
if (!uuid) {
|
|
484
490
|
console.warn('[ProxyLinkProvider] serverUUID undefined, opening localhost URL as-is (no proxy):', {
|
|
@@ -486,7 +492,7 @@ class ProxyLinkProvider {
|
|
|
486
492
|
hasGetToken: !!this._getToken,
|
|
487
493
|
hasGetEndpoints: !!this._getEndpoints,
|
|
488
494
|
});
|
|
489
|
-
|
|
495
|
+
window.open(matchedUrl, '_blank', 'noopener');
|
|
490
496
|
return;
|
|
491
497
|
}
|
|
492
498
|
const token = this._getToken?.();
|
|
@@ -503,7 +509,6 @@ class ProxyLinkProvider {
|
|
|
503
509
|
endpoints,
|
|
504
510
|
env: this._getEnv?.(),
|
|
505
511
|
deployVersion: this._getDeployVersion?.(),
|
|
506
|
-
handler: (_e, url) => this._handler(event, url),
|
|
507
512
|
});
|
|
508
513
|
},
|
|
509
514
|
});
|
|
@@ -538,13 +543,83 @@ class ProxyLinksAddon {
|
|
|
538
543
|
}
|
|
539
544
|
}
|
|
540
545
|
|
|
546
|
+
const PORTS_SECTION_TITLE = 'PORTS';
|
|
547
|
+
const SECTION_TITLE = /^[A-Z][A-Z ]*$/;
|
|
548
|
+
const PORT_TOKEN = /(?<![\d.])(\d{1,5})(?![\d.])/g;
|
|
549
|
+
function portTokensOf(text) {
|
|
550
|
+
const out = [];
|
|
551
|
+
PORT_TOKEN.lastIndex = 0;
|
|
552
|
+
let m;
|
|
553
|
+
while ((m = PORT_TOKEN.exec(text)) !== null) {
|
|
554
|
+
const port = Number(m[1]);
|
|
555
|
+
if (port >= 1 && port <= 65535)
|
|
556
|
+
out.push({ port, start: m.index, end: m.index + m[1].length });
|
|
557
|
+
}
|
|
558
|
+
return out;
|
|
559
|
+
}
|
|
560
|
+
function isPortsSectionRow(textAt, lineIndex) {
|
|
561
|
+
const own = textAt(lineIndex)?.trim();
|
|
562
|
+
if (own === undefined || own === '' || SECTION_TITLE.test(own))
|
|
563
|
+
return false;
|
|
564
|
+
for (let i = lineIndex - 1; i >= 0; i--) {
|
|
565
|
+
const t = textAt(i)?.trim();
|
|
566
|
+
if (t === undefined || t === '')
|
|
567
|
+
return false;
|
|
568
|
+
if (t === PORTS_SECTION_TITLE)
|
|
569
|
+
return true;
|
|
570
|
+
if (SECTION_TITLE.test(t))
|
|
571
|
+
return false;
|
|
572
|
+
}
|
|
573
|
+
return false;
|
|
574
|
+
}
|
|
575
|
+
class PortLinkProvider {
|
|
576
|
+
_terminal;
|
|
577
|
+
_handler;
|
|
578
|
+
constructor(_terminal, _handler) {
|
|
579
|
+
this._terminal = _terminal;
|
|
580
|
+
this._handler = _handler;
|
|
581
|
+
}
|
|
582
|
+
provideLinks(bufferLineNumber, callback) {
|
|
583
|
+
const buf = this._terminal.buffer.active;
|
|
584
|
+
const textAt = (i) => buf.getLine(i)?.translateToString(true);
|
|
585
|
+
const lineIndex = bufferLineNumber - 1;
|
|
586
|
+
const text = textAt(lineIndex);
|
|
587
|
+
if (text === undefined || !isPortsSectionRow(textAt, lineIndex)) {
|
|
588
|
+
callback(undefined);
|
|
589
|
+
return;
|
|
590
|
+
}
|
|
591
|
+
const links = portTokensOf(text).map(({ port, start, end }) => ({
|
|
592
|
+
text: String(port),
|
|
593
|
+
range: { start: { x: start + 1, y: bufferLineNumber }, end: { x: end, y: bufferLineNumber } },
|
|
594
|
+
activate: (event) => this._handler(event, port),
|
|
595
|
+
}));
|
|
596
|
+
callback(links.length > 0 ? links : undefined);
|
|
597
|
+
}
|
|
598
|
+
}
|
|
599
|
+
|
|
600
|
+
class PortLinksAddon {
|
|
601
|
+
_handler;
|
|
602
|
+
_linkProvider;
|
|
603
|
+
constructor(_handler) {
|
|
604
|
+
this._handler = _handler;
|
|
605
|
+
}
|
|
606
|
+
activate(terminal) {
|
|
607
|
+
this._linkProvider = terminal.registerLinkProvider(new PortLinkProvider(terminal, this._handler));
|
|
608
|
+
}
|
|
609
|
+
dispose() {
|
|
610
|
+
this._linkProvider?.dispose();
|
|
611
|
+
}
|
|
612
|
+
}
|
|
613
|
+
|
|
541
614
|
var XtermActionId;
|
|
542
615
|
(function (XtermActionId) {
|
|
543
616
|
XtermActionId["DATA_INPUT"] = "xterm:data-input";
|
|
544
617
|
XtermActionId["RESIZED"] = "xterm:resized";
|
|
545
618
|
XtermActionId["GITHUB_LINK_CLICK"] = "xterm:github-link-click";
|
|
619
|
+
XtermActionId["WEB_LINK_CLICK"] = "xterm:web-link-click";
|
|
546
620
|
XtermActionId["FILE_LINK_CLICK"] = "xterm:file-link-click";
|
|
547
621
|
XtermActionId["SESSION_MENTION_CLICK"] = "xterm:session-mention-click";
|
|
622
|
+
XtermActionId["PORT_LINK_CLICK"] = "xterm:port-link-click";
|
|
548
623
|
XtermActionId["FOCUS_INPUT_REQUEST"] = "xterm:focus-input-request";
|
|
549
624
|
})(XtermActionId || (XtermActionId = {}));
|
|
550
625
|
const XTERM_SESSION_CONTEXT = new InjectionToken('XTERM_SESSION_CONTEXT');
|
|
@@ -561,18 +636,19 @@ class XtermOrganismStore extends InjectableComponent {
|
|
|
561
636
|
queryResult = input('', ...(ngDevMode ? [{ debugName: "queryResult" }] : []));
|
|
562
637
|
useInteractiveTheme = input(false, ...(ngDevMode ? [{ debugName: "useInteractiveTheme" }] : []));
|
|
563
638
|
totalWritten = input(0, ...(ngDevMode ? [{ debugName: "totalWritten" }] : []));
|
|
639
|
+
staticScreen = input(false, ...(ngDevMode ? [{ debugName: "staticScreen" }] : []));
|
|
564
640
|
sessionContext = inject(XTERM_SESSION_CONTEXT, { optional: true });
|
|
565
641
|
constructor() {
|
|
566
642
|
super();
|
|
567
643
|
XtermOrganismStore.DI.initialize(this);
|
|
568
644
|
}
|
|
569
645
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: XtermOrganismStore, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
570
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "21.1.6", type: XtermOrganismStore, isStandalone: true, selector: "organisms-xterm", inputs: { data: { classPropertyName: "data", publicName: "data", isSignal: true, isRequired: false, transformFunction: null }, interactive: { classPropertyName: "interactive", publicName: "interactive", isSignal: true, isRequired: false, transformFunction: null }, queryResult: { classPropertyName: "queryResult", publicName: "queryResult", isSignal: true, isRequired: false, transformFunction: null }, useInteractiveTheme: { classPropertyName: "useInteractiveTheme", publicName: "useInteractiveTheme", isSignal: true, isRequired: false, transformFunction: null }, totalWritten: { classPropertyName: "totalWritten", publicName: "totalWritten", isSignal: true, isRequired: false, transformFunction: null } }, usesInheritance: true, ngImport: i0 });
|
|
646
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "21.1.6", type: XtermOrganismStore, isStandalone: true, selector: "organisms-xterm", inputs: { data: { classPropertyName: "data", publicName: "data", isSignal: true, isRequired: false, transformFunction: null }, interactive: { classPropertyName: "interactive", publicName: "interactive", isSignal: true, isRequired: false, transformFunction: null }, queryResult: { classPropertyName: "queryResult", publicName: "queryResult", isSignal: true, isRequired: false, transformFunction: null }, useInteractiveTheme: { classPropertyName: "useInteractiveTheme", publicName: "useInteractiveTheme", isSignal: true, isRequired: false, transformFunction: null }, totalWritten: { classPropertyName: "totalWritten", publicName: "totalWritten", isSignal: true, isRequired: false, transformFunction: null }, staticScreen: { classPropertyName: "staticScreen", publicName: "staticScreen", isSignal: true, isRequired: false, transformFunction: null } }, usesInheritance: true, ngImport: i0 });
|
|
571
647
|
}
|
|
572
648
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: XtermOrganismStore, decorators: [{
|
|
573
649
|
type: Directive,
|
|
574
650
|
args: [{ standalone: true, selector: 'organisms-xterm' }]
|
|
575
|
-
}], ctorParameters: () => [], propDecorators: { data: [{ type: i0.Input, args: [{ isSignal: true, alias: "data", required: false }] }], interactive: [{ type: i0.Input, args: [{ isSignal: true, alias: "interactive", required: false }] }], queryResult: [{ type: i0.Input, args: [{ isSignal: true, alias: "queryResult", required: false }] }], useInteractiveTheme: [{ type: i0.Input, args: [{ isSignal: true, alias: "useInteractiveTheme", required: false }] }], totalWritten: [{ type: i0.Input, args: [{ isSignal: true, alias: "totalWritten", required: false }] }] } });
|
|
651
|
+
}], ctorParameters: () => [], propDecorators: { data: [{ type: i0.Input, args: [{ isSignal: true, alias: "data", required: false }] }], interactive: [{ type: i0.Input, args: [{ isSignal: true, alias: "interactive", required: false }] }], queryResult: [{ type: i0.Input, args: [{ isSignal: true, alias: "queryResult", required: false }] }], useInteractiveTheme: [{ type: i0.Input, args: [{ isSignal: true, alias: "useInteractiveTheme", required: false }] }], totalWritten: [{ type: i0.Input, args: [{ isSignal: true, alias: "totalWritten", required: false }] }], staticScreen: [{ type: i0.Input, args: [{ isSignal: true, alias: "staticScreen", required: false }] }] } });
|
|
576
652
|
|
|
577
653
|
const MIN_VIEWPORT_COLS = 2;
|
|
578
654
|
const MIN_VIEWPORT_ROWS = 1;
|
|
@@ -583,13 +659,16 @@ const CANONICAL_FONT_SIZE_PX = 14;
|
|
|
583
659
|
const CANONICAL_CELL_WIDTH_RATIO = 0.615;
|
|
584
660
|
const CANONICAL_CELL_HEIGHT_RATIO = 1.43;
|
|
585
661
|
const CANONICAL_LINE_HEIGHT = 1.2;
|
|
662
|
+
const CANONICAL_FONT_FACES = [
|
|
663
|
+
{ family: 'FiraCode Nerd Font', url: 'https://cdn.jsdelivr.net/gh/ryanoasis/nerd-fonts@v3.2.1/patched-fonts/FiraCode/Regular/FiraCodeNerdFont-Regular.ttf' },
|
|
664
|
+
];
|
|
586
665
|
const DEFAULT_CELL_WIDTH = CANONICAL_FONT_SIZE_PX * CANONICAL_CELL_WIDTH_RATIO;
|
|
587
666
|
const DEFAULT_CELL_HEIGHT = CANONICAL_FONT_SIZE_PX * CANONICAL_CELL_HEIGHT_RATIO;
|
|
588
|
-
function
|
|
667
|
+
function probeCanonicalCellRect() {
|
|
589
668
|
try {
|
|
590
669
|
const doc = document;
|
|
591
670
|
if (!doc?.body)
|
|
592
|
-
return
|
|
671
|
+
return null;
|
|
593
672
|
const probe = doc.createElement('span');
|
|
594
673
|
probe.textContent = 'M';
|
|
595
674
|
probe.style.position = 'absolute';
|
|
@@ -603,14 +682,20 @@ function measureCellMetric() {
|
|
|
603
682
|
doc.body.appendChild(probe);
|
|
604
683
|
const rect = probe.getBoundingClientRect();
|
|
605
684
|
doc.body.removeChild(probe);
|
|
606
|
-
|
|
607
|
-
const cellHeight = rect.height >= 8 ? rect.height : DEFAULT_CELL_HEIGHT;
|
|
608
|
-
return { cellWidth, cellHeight };
|
|
685
|
+
return { width: rect.width, height: rect.height };
|
|
609
686
|
}
|
|
610
687
|
catch {
|
|
611
|
-
return
|
|
688
|
+
return null;
|
|
612
689
|
}
|
|
613
690
|
}
|
|
691
|
+
function measureCellMetric() {
|
|
692
|
+
const rect = probeCanonicalCellRect();
|
|
693
|
+
if (!rect)
|
|
694
|
+
return { cellWidth: DEFAULT_CELL_WIDTH, cellHeight: DEFAULT_CELL_HEIGHT };
|
|
695
|
+
const cellWidth = rect.width >= 3 ? rect.width : DEFAULT_CELL_WIDTH;
|
|
696
|
+
const cellHeight = rect.height >= 8 ? rect.height : DEFAULT_CELL_HEIGHT;
|
|
697
|
+
return { cellWidth, cellHeight };
|
|
698
|
+
}
|
|
614
699
|
function computeFitToViewport(input) {
|
|
615
700
|
const { viewportElement, cellWidth, cellHeight } = input;
|
|
616
701
|
if (!cellWidth || !cellHeight || cellWidth <= 0 || cellHeight <= 0)
|
|
@@ -638,13 +723,22 @@ function recordCanvasCellMetric(metric) {
|
|
|
638
723
|
}
|
|
639
724
|
const CELL_WIDTH_RATIO = CANONICAL_CELL_WIDTH_RATIO;
|
|
640
725
|
const CELL_HEIGHT_RATIO = CANONICAL_CELL_HEIGHT_RATIO;
|
|
641
|
-
function
|
|
642
|
-
|
|
643
|
-
return cached;
|
|
644
|
-
cached = {
|
|
726
|
+
function canonicalCellMetric(fontSize) {
|
|
727
|
+
return {
|
|
645
728
|
cellWidth: fontSize * CELL_WIDTH_RATIO,
|
|
646
729
|
cellHeight: Math.round(fontSize * CELL_HEIGHT_RATIO),
|
|
647
730
|
};
|
|
731
|
+
}
|
|
732
|
+
function getCanvasCellMetric(fontSize = CANONICAL_FONT_SIZE_PX) {
|
|
733
|
+
if (cached)
|
|
734
|
+
return cached;
|
|
735
|
+
cached = canonicalCellMetric(fontSize);
|
|
736
|
+
return cached;
|
|
737
|
+
}
|
|
738
|
+
function primeCanvasCellMetric(measured, fontSize = CANONICAL_FONT_SIZE_PX) {
|
|
739
|
+
const base = canonicalCellMetric(fontSize);
|
|
740
|
+
const width = measured.cellWidth;
|
|
741
|
+
cached = Number.isFinite(width) && width > 0 ? { cellWidth: width, cellHeight: base.cellHeight } : base;
|
|
648
742
|
return cached;
|
|
649
743
|
}
|
|
650
744
|
function _legacyMeasureViaTempTerminal(fontSize = CANONICAL_FONT_SIZE_PX) {
|
|
@@ -805,6 +899,133 @@ function installQueryReplySuppression(terminal) {
|
|
|
805
899
|
terminal.parser.registerEscHandler({ final: 'Z' }, () => true);
|
|
806
900
|
}
|
|
807
901
|
|
|
902
|
+
function focusTerminalTextarea(container, terminal) {
|
|
903
|
+
const textarea = container.querySelector('.xterm-helper-textarea');
|
|
904
|
+
if (textarea) {
|
|
905
|
+
textarea.focus({ preventScroll: true });
|
|
906
|
+
return;
|
|
907
|
+
}
|
|
908
|
+
terminal?.focus();
|
|
909
|
+
}
|
|
910
|
+
|
|
911
|
+
const VIEWPORT_CLASS = 'xterm-viewport';
|
|
912
|
+
const FOLLOW_BOTTOM_GESTURE_WINDOW_MS = 500;
|
|
913
|
+
function isScrollUpKey(e) {
|
|
914
|
+
return e.shiftKey && (e.key === 'PageUp' || e.key === 'Home');
|
|
915
|
+
}
|
|
916
|
+
function attachFollowBottom(terminal, root, options = {}) {
|
|
917
|
+
const now = options.now ?? (() => Date.now());
|
|
918
|
+
let following = true;
|
|
919
|
+
let dragging = false;
|
|
920
|
+
let restoring = false;
|
|
921
|
+
let gestureAt = Number.NEGATIVE_INFINITY;
|
|
922
|
+
let lastViewportY = terminal.buffer.active.viewportY;
|
|
923
|
+
let lastFollowing = true;
|
|
924
|
+
const gesture = () => { gestureAt = now(); };
|
|
925
|
+
const free = () => { following = false; gesture(); };
|
|
926
|
+
const report = () => {
|
|
927
|
+
const { viewportY, baseY } = terminal.buffer.active;
|
|
928
|
+
const movedByUser = viewportY !== lastViewportY;
|
|
929
|
+
const modeChanged = following !== lastFollowing;
|
|
930
|
+
lastViewportY = viewportY;
|
|
931
|
+
lastFollowing = following;
|
|
932
|
+
if (restoring)
|
|
933
|
+
return;
|
|
934
|
+
if (following) {
|
|
935
|
+
if (modeChanged)
|
|
936
|
+
options.onChange?.(0);
|
|
937
|
+
return;
|
|
938
|
+
}
|
|
939
|
+
if (movedByUser || modeChanged)
|
|
940
|
+
options.onChange?.(baseY - viewportY);
|
|
941
|
+
};
|
|
942
|
+
const onMouseDown = (e) => {
|
|
943
|
+
dragging = true;
|
|
944
|
+
gesture();
|
|
945
|
+
if (e.target instanceof HTMLElement && e.target.classList.contains(VIEWPORT_CLASS))
|
|
946
|
+
free();
|
|
947
|
+
};
|
|
948
|
+
const onMouseUp = () => { dragging = false; };
|
|
949
|
+
const onKeyDown = (e) => { if (e instanceof KeyboardEvent && isScrollUpKey(e))
|
|
950
|
+
free(); };
|
|
951
|
+
const opts = { capture: true, passive: true };
|
|
952
|
+
root.addEventListener('wheel', free, opts);
|
|
953
|
+
root.addEventListener('touchstart', free, opts);
|
|
954
|
+
root.addEventListener('mousedown', onMouseDown, opts);
|
|
955
|
+
root.addEventListener('keydown', onKeyDown, opts);
|
|
956
|
+
window.addEventListener('mouseup', onMouseUp, opts);
|
|
957
|
+
const onScrolled = (intended) => {
|
|
958
|
+
const { viewportY, baseY } = terminal.buffer.active;
|
|
959
|
+
const atBottom = viewportY === baseY;
|
|
960
|
+
if (!intended) {
|
|
961
|
+
if (following) {
|
|
962
|
+
if (!atBottom)
|
|
963
|
+
terminal.scrollToBottom();
|
|
964
|
+
}
|
|
965
|
+
else if (viewportY !== lastViewportY)
|
|
966
|
+
terminal.scrollLines(lastViewportY - viewportY);
|
|
967
|
+
lastViewportY = terminal.buffer.active.viewportY;
|
|
968
|
+
return;
|
|
969
|
+
}
|
|
970
|
+
if (!following) {
|
|
971
|
+
if (atBottom)
|
|
972
|
+
following = true;
|
|
973
|
+
report();
|
|
974
|
+
return;
|
|
975
|
+
}
|
|
976
|
+
if (atBottom) {
|
|
977
|
+
report();
|
|
978
|
+
return;
|
|
979
|
+
}
|
|
980
|
+
free();
|
|
981
|
+
report();
|
|
982
|
+
};
|
|
983
|
+
const onApiScroll = () => onScrolled(true);
|
|
984
|
+
const onDomScroll = () => onScrolled(dragging || now() - gestureAt < FOLLOW_BOTTOM_GESTURE_WINDOW_MS);
|
|
985
|
+
const scroll = terminal.onScroll(onApiScroll);
|
|
986
|
+
const viewport = root.querySelector(`.${VIEWPORT_CLASS}`);
|
|
987
|
+
viewport?.addEventListener('scroll', onDomScroll, { passive: true });
|
|
988
|
+
return {
|
|
989
|
+
get following() { return following; },
|
|
990
|
+
restore(fromBottom) {
|
|
991
|
+
const n = Math.max(0, Math.floor(fromBottom));
|
|
992
|
+
restoring = true;
|
|
993
|
+
try {
|
|
994
|
+
terminal.scrollToBottom();
|
|
995
|
+
following = n === 0;
|
|
996
|
+
if (n > 0)
|
|
997
|
+
terminal.scrollLines(-n);
|
|
998
|
+
}
|
|
999
|
+
finally {
|
|
1000
|
+
lastViewportY = terminal.buffer.active.viewportY;
|
|
1001
|
+
lastFollowing = following;
|
|
1002
|
+
restoring = false;
|
|
1003
|
+
}
|
|
1004
|
+
},
|
|
1005
|
+
dispose() {
|
|
1006
|
+
scroll.dispose();
|
|
1007
|
+
viewport?.removeEventListener('scroll', onDomScroll);
|
|
1008
|
+
root.removeEventListener('wheel', free, opts);
|
|
1009
|
+
root.removeEventListener('touchstart', free, opts);
|
|
1010
|
+
root.removeEventListener('mousedown', onMouseDown, opts);
|
|
1011
|
+
root.removeEventListener('keydown', onKeyDown, opts);
|
|
1012
|
+
window.removeEventListener('mouseup', onMouseUp, opts);
|
|
1013
|
+
},
|
|
1014
|
+
};
|
|
1015
|
+
}
|
|
1016
|
+
|
|
1017
|
+
function planDataWrite(o) {
|
|
1018
|
+
const { lastDataLength, data, mode } = o;
|
|
1019
|
+
if (data === '')
|
|
1020
|
+
return { text: '', reset: false, scrollToTop: false, nextDataLength: lastDataLength };
|
|
1021
|
+
if (mode === 'screen')
|
|
1022
|
+
return { text: data, reset: true, scrollToTop: true, nextDataLength: data.length };
|
|
1023
|
+
if (data.length >= lastDataLength) {
|
|
1024
|
+
return { text: data.slice(lastDataLength), reset: false, scrollToTop: false, nextDataLength: data.length };
|
|
1025
|
+
}
|
|
1026
|
+
return { text: data, reset: true, scrollToTop: false, nextDataLength: data.length };
|
|
1027
|
+
}
|
|
1028
|
+
|
|
808
1029
|
const MIN_CONTAINER_SIZE = 10;
|
|
809
1030
|
class XtermOrganism extends NgAtomicComponent {
|
|
810
1031
|
container = viewChild.required('container');
|
|
@@ -828,6 +1049,8 @@ class XtermOrganism extends NgAtomicComponent {
|
|
|
828
1049
|
fitScheduled = signal(0, ...(ngDevMode ? [{ debugName: "fitScheduled" }] : []));
|
|
829
1050
|
initSkippedDueToSize = false;
|
|
830
1051
|
disposables = [];
|
|
1052
|
+
followBottom = null;
|
|
1053
|
+
scrollFromBottom = signal(null, ...(ngDevMode ? [{ debugName: "scrollFromBottom" }] : []));
|
|
831
1054
|
stableTimer = null;
|
|
832
1055
|
resizeTimer = null;
|
|
833
1056
|
fallbackTimer = null;
|
|
@@ -869,18 +1092,20 @@ class XtermOrganism extends NgAtomicComponent {
|
|
|
869
1092
|
if (data === undefined || data === null || data === '') {
|
|
870
1093
|
return;
|
|
871
1094
|
}
|
|
872
|
-
|
|
873
|
-
|
|
874
|
-
|
|
875
|
-
|
|
876
|
-
|
|
877
|
-
|
|
878
|
-
}
|
|
879
|
-
else {
|
|
1095
|
+
const plan = planDataWrite({
|
|
1096
|
+
lastDataLength: this.lastDataLength,
|
|
1097
|
+
data,
|
|
1098
|
+
mode: this.store.staticScreen() ? 'screen' : 'stream',
|
|
1099
|
+
});
|
|
1100
|
+
if (plan.reset)
|
|
880
1101
|
this.terminal.reset();
|
|
881
|
-
|
|
882
|
-
|
|
1102
|
+
if (plan.text) {
|
|
1103
|
+
if (plan.scrollToTop)
|
|
1104
|
+
this.terminal.write(plan.text, () => this.terminal.scrollToTop());
|
|
1105
|
+
else
|
|
1106
|
+
this.terminal.write(plan.text);
|
|
883
1107
|
}
|
|
1108
|
+
this.lastDataLength = plan.nextDataLength;
|
|
884
1109
|
}
|
|
885
1110
|
writeDataWithTotalWritten(data, totalWritten) {
|
|
886
1111
|
const isStreamRestart = totalWritten < this.lastProcessedLength;
|
|
@@ -925,25 +1150,34 @@ class XtermOrganism extends NgAtomicComponent {
|
|
|
925
1150
|
installQueryReplySuppression(this.terminal);
|
|
926
1151
|
this.fitAddon = new FitAddon();
|
|
927
1152
|
this.terminal.loadAddon(this.fitAddon);
|
|
928
|
-
this.terminal.loadAddon(new WebLinksAddon()
|
|
1153
|
+
this.terminal.loadAddon(new WebLinksAddon((event, uri) => {
|
|
1154
|
+
this.dispatch({ id: XtermActionId.WEB_LINK_CLICK, payload: { url: uri } });
|
|
1155
|
+
}));
|
|
929
1156
|
this.loadImageAddon();
|
|
930
1157
|
this.githubLinksAddon = new GitHubLinksAddon((event, issueNumber) => {
|
|
931
1158
|
this.dispatch({ id: XtermActionId.GITHUB_LINK_CLICK, payload: issueNumber });
|
|
932
1159
|
});
|
|
933
1160
|
this.terminal.loadAddon(this.githubLinksAddon);
|
|
934
|
-
this.fileLinksAddon = new FileLinksAddon((
|
|
935
|
-
|
|
936
|
-
|
|
937
|
-
}
|
|
938
|
-
});
|
|
1161
|
+
this.fileLinksAddon = new FileLinksAddon(createFileLinkActivateHandler((payload) => {
|
|
1162
|
+
this.dispatch({ id: XtermActionId.FILE_LINK_CLICK, payload });
|
|
1163
|
+
}));
|
|
939
1164
|
this.terminal.loadAddon(this.fileLinksAddon);
|
|
940
1165
|
this.sessionMentionLinksAddon = new SessionMentionLinksAddon((event, name) => {
|
|
941
1166
|
this.dispatch({ id: XtermActionId.SESSION_MENTION_CLICK, payload: { name } });
|
|
942
1167
|
});
|
|
943
1168
|
this.terminal.loadAddon(this.sessionMentionLinksAddon);
|
|
944
1169
|
const ctx = this.store.sessionContext;
|
|
945
|
-
this.terminal.loadAddon(new ProxyLinksAddon(ctx?.getServerUUID ?? (() => undefined), ctx?.getProxyToken,
|
|
1170
|
+
this.terminal.loadAddon(new ProxyLinksAddon(ctx?.getServerUUID ?? (() => undefined), ctx?.getProxyToken, (event, url) => {
|
|
1171
|
+
this.dispatch({ id: XtermActionId.WEB_LINK_CLICK, payload: { url } });
|
|
1172
|
+
}, ctx?.getDeployVersion, ctx?.getProxyEndpoints, ctx?.onMissingToken, ctx?.getProxyEnv));
|
|
1173
|
+
if (this.store.staticScreen()) {
|
|
1174
|
+
this.terminal.loadAddon(new PortLinksAddon((event, port) => {
|
|
1175
|
+
this.dispatch({ id: XtermActionId.PORT_LINK_CLICK, payload: { port } });
|
|
1176
|
+
}));
|
|
1177
|
+
}
|
|
946
1178
|
this.terminal.open(containerElement);
|
|
1179
|
+
this.followBottom = attachFollowBottom(this.terminal, containerElement, { onChange: (n) => this.scrollFromBottom.set(n) });
|
|
1180
|
+
this.disposables.push(this.followBottom);
|
|
947
1181
|
const core = this.terminal._core;
|
|
948
1182
|
const charSizeChange = core?._charSizeService?.onCharSizeChange;
|
|
949
1183
|
if (typeof charSizeChange === 'function') {
|
|
@@ -1106,6 +1340,12 @@ class XtermOrganism extends NgAtomicComponent {
|
|
|
1106
1340
|
scrollToBottom() {
|
|
1107
1341
|
this.terminal?.scrollToBottom();
|
|
1108
1342
|
}
|
|
1343
|
+
get followingBottom() {
|
|
1344
|
+
return this.followBottom?.following ?? true;
|
|
1345
|
+
}
|
|
1346
|
+
restoreScroll(fromBottom) {
|
|
1347
|
+
this.terminal?.write('', () => this.followBottom?.restore(fromBottom));
|
|
1348
|
+
}
|
|
1109
1349
|
scrollToTop() {
|
|
1110
1350
|
this.terminal?.scrollToTop();
|
|
1111
1351
|
}
|
|
@@ -1113,9 +1353,7 @@ class XtermOrganism extends NgAtomicComponent {
|
|
|
1113
1353
|
this.terminal?.scrollLines(lines);
|
|
1114
1354
|
}
|
|
1115
1355
|
focus() {
|
|
1116
|
-
this.
|
|
1117
|
-
const helperTextarea = this.container().nativeElement.querySelector('.xterm-helper-textarea');
|
|
1118
|
-
helperTextarea?.focus();
|
|
1356
|
+
focusTerminalTextarea(this.container().nativeElement, this.terminal ?? undefined);
|
|
1119
1357
|
}
|
|
1120
1358
|
clearSelection() {
|
|
1121
1359
|
this.terminal?.clearSelection();
|
|
@@ -1158,13 +1396,13 @@ class XtermOrganism extends NgAtomicComponent {
|
|
|
1158
1396
|
return this.imageAddon;
|
|
1159
1397
|
}
|
|
1160
1398
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: XtermOrganism, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1161
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.2.0", version: "21.1.6", type: XtermOrganism, isStandalone: true, selector: "organisms-xterm", outputs: { terminalReady: "terminalReady", githubLinkClick: "githubLinkClick" }, viewQueries: [{ propertyName: "container", first: true, predicate: ["container"], descendants: true, isSignal: true }], usesInheritance: true, hostDirectives: [{ directive: XtermOrganismStore, inputs: ["data", "data", "interactive", "interactive", "useInteractiveTheme", "useInteractiveTheme", "totalWritten", "totalWritten"] }], ngImport: i0, template: `<div #container class="terminal-viewport xterm-wrapper"></div>`, isInline: true, styles: ["", "@import\"https://unpkg.com/@xterm/xterm@5.5.0/css/xterm.css\";:host{display:block;width:100%;height:100%}:host .terminal-viewport,:host .xterm-wrapper{width:100%;height:100%;background:#0a0a0a;position:relative;overflow:hidden}:host:not(.interactive) .xterm-wrapper ::ng-deep .xterm-cursor-layer{display:none!important}:host:not(.interactive) .xterm-wrapper ::ng-deep .xterm-cursor,:host:not(.interactive) .xterm-wrapper ::ng-deep .xterm-cursor-outline{opacity:0!important}:host ::ng-deep .xterm-screen canvas{pointer-events:none}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
1399
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.2.0", version: "21.1.6", type: XtermOrganism, isStandalone: true, selector: "organisms-xterm", outputs: { terminalReady: "terminalReady", githubLinkClick: "githubLinkClick" }, viewQueries: [{ propertyName: "container", first: true, predicate: ["container"], descendants: true, isSignal: true }], usesInheritance: true, hostDirectives: [{ directive: XtermOrganismStore, inputs: ["data", "data", "interactive", "interactive", "useInteractiveTheme", "useInteractiveTheme", "totalWritten", "totalWritten", "staticScreen", "staticScreen"] }], ngImport: i0, template: `<div #container class="terminal-viewport xterm-wrapper"></div>`, isInline: true, styles: ["", "@import\"https://unpkg.com/@xterm/xterm@5.5.0/css/xterm.css\";:host{display:block;width:100%;height:100%}:host .terminal-viewport,:host .xterm-wrapper{width:100%;height:100%;background:#0a0a0a;position:relative;overflow:hidden}:host:not(.interactive) .xterm-wrapper ::ng-deep .xterm-cursor-layer{display:none!important}:host:not(.interactive) .xterm-wrapper ::ng-deep .xterm-cursor,:host:not(.interactive) .xterm-wrapper ::ng-deep .xterm-cursor-outline{opacity:0!important}:host ::ng-deep .xterm-screen canvas{pointer-events:none}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
1162
1400
|
}
|
|
1163
1401
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: XtermOrganism, decorators: [{
|
|
1164
1402
|
type: Component,
|
|
1165
1403
|
args: [{ selector: 'organisms-xterm', standalone: true, imports: [], template: `<div #container class="terminal-viewport xterm-wrapper"></div>`, changeDetection: ChangeDetectionStrategy.OnPush, hostDirectives: [{
|
|
1166
1404
|
directive: XtermOrganismStore,
|
|
1167
|
-
inputs: ['data', 'interactive', 'useInteractiveTheme', 'totalWritten'],
|
|
1405
|
+
inputs: ['data', 'interactive', 'useInteractiveTheme', 'totalWritten', 'staticScreen'],
|
|
1168
1406
|
}], styles: ["@import\"https://unpkg.com/@xterm/xterm@5.5.0/css/xterm.css\";:host{display:block;width:100%;height:100%}:host .terminal-viewport,:host .xterm-wrapper{width:100%;height:100%;background:#0a0a0a;position:relative;overflow:hidden}:host:not(.interactive) .xterm-wrapper ::ng-deep .xterm-cursor-layer{display:none!important}:host:not(.interactive) .xterm-wrapper ::ng-deep .xterm-cursor,:host:not(.interactive) .xterm-wrapper ::ng-deep .xterm-cursor-outline{opacity:0!important}:host ::ng-deep .xterm-screen canvas{pointer-events:none}\n"] }]
|
|
1169
1407
|
}], ctorParameters: () => [], propDecorators: { container: [{ type: i0.ViewChild, args: ['container', { isSignal: true }] }], terminalReady: [{ type: i0.Output, args: ["terminalReady"] }], githubLinkClick: [{ type: i0.Output, args: ["githubLinkClick"] }] } });
|
|
1170
1408
|
function hasDisplayClearWithoutScrollbackClear(s) {
|
|
@@ -1378,4 +1616,4 @@ function applyScrollbackForFocus(terminal, { isInteractive, focused }) {
|
|
|
1378
1616
|
* Generated bundle index. Do not edit.
|
|
1379
1617
|
*/
|
|
1380
1618
|
|
|
1381
|
-
export { CANONICAL_CELL_HEIGHT_RATIO, CANONICAL_CELL_WIDTH_RATIO, CANONICAL_FONT_FAMILY, CANONICAL_FONT_SIZE_PX, CANONICAL_LINE_HEIGHT, DISPLAY_THEME, GitHubLinkProvider, GitHubLinksAddon, INTERACTIVE_THEME, MAX_VIEWPORT_COLS, MAX_VIEWPORT_ROWS, MIN_VIEWPORT_COLS, MIN_VIEWPORT_ROWS, ProxyLinkProvider, ProxyLinksAddon, SessionMentionLinkProvider, SessionMentionLinksAddon, USER_CONTENT_DOMAIN, WebLinksAddon, XTERM_SESSION_CONTEXT, XtermActionId, XtermOrganism, XtermOrganismStore, appendUrlHandoff, applyScrollbackForFocus, asciiArtToSvg, buildTerminalOptions, buildUserContentOrigin, clearCanvasCellMetricCache, computeFitToViewport, decideTerminalWrite, deployVersionToHostSuffix, encodeUrlHandoff, extractSessionMentions, generateAsciiArt, getCanvasCellMetric, getMachinaAsciiArtSixel, hasVisibleContent, measureCellMetric, openWebProxyForPort, recordCanvasCellMetric, svgToSixel, toProxyUrl };
|
|
1619
|
+
export { CANONICAL_CELL_HEIGHT_RATIO, CANONICAL_CELL_WIDTH_RATIO, CANONICAL_FONT_FACES, CANONICAL_FONT_FAMILY, CANONICAL_FONT_SIZE_PX, CANONICAL_LINE_HEIGHT, DISPLAY_THEME, FOLLOW_BOTTOM_GESTURE_WINDOW_MS, GitHubLinkProvider, GitHubLinksAddon, INTERACTIVE_THEME, MAX_VIEWPORT_COLS, MAX_VIEWPORT_ROWS, MIN_VIEWPORT_COLS, MIN_VIEWPORT_ROWS, PORTS_SECTION_TITLE, PortLinkProvider, PortLinksAddon, ProxyLinkProvider, ProxyLinksAddon, SessionMentionLinkProvider, SessionMentionLinksAddon, USER_CONTENT_DOMAIN, WebLinksAddon, XTERM_SESSION_CONTEXT, XtermActionId, XtermOrganism, XtermOrganismStore, appendUrlHandoff, applyScrollbackForFocus, asciiArtToSvg, attachFollowBottom, buildTerminalOptions, buildUserContentOrigin, clearCanvasCellMetricCache, computeFitToViewport, decideTerminalWrite, deployVersionToHostSuffix, encodeUrlHandoff, extractSessionMentions, generateAsciiArt, getCanvasCellMetric, getMachinaAsciiArtSixel, hasVisibleContent, isPortsSectionRow, measureCellMetric, openWebProxyForPort, portTokensOf, primeCanvasCellMetric, probeCanonicalCellRect, recordCanvasCellMetric, svgToSixel, toProxyUrl };
|
|
@@ -422,7 +422,7 @@ class CommandPage extends NgAtomicComponent {
|
|
|
422
422
|
</frames-tabs>
|
|
423
423
|
</templates-form>
|
|
424
424
|
</frames-router-outlet>
|
|
425
|
-
`, isInline: true, styles: [":host{width:100%;height:100%;display:block;--page-width-lv1-SCOPED-IN-command-
|
|
425
|
+
`, isInline: true, styles: [":host{width:100%;height:100%;display:block;--page-width-lv1-SCOPED-IN-command-NWbS: var(--page-width-lv1);--primary-color-SCOPED-IN-command-NWbS: var(--primary-color);--on-primary-color-SCOPED-IN-command-NWbS: var(--on-primary-color);--background-color-SCOPED-IN-command-NWbS: var(--background-color);--on-background-color-SCOPED-IN-command-NWbS: var(--on-background-color)}:host templates-form{padding-left:0;box-sizing:border-box;transition:padding-left .3s}:host .template{--first-content-height: 0px;width:var(--page-width-lv1-SCOPED-IN-command-NWbS)}:host .template div[dashboard]{padding:0;box-sizing:border-box}:host *{--primary-color: var(--primary-color-SCOPED-IN-command-NWbS);--on-primary-color: var(--on-primary-color-SCOPED-IN-command-NWbS);--background-color: var(--background-color-SCOPED-IN-command-NWbS);--on-background-color: var(--on-background-color-SCOPED-IN-command-NWbS)}\n"], dependencies: [{ kind: "component", type: RouterOutletFrame, selector: "frames-router-outlet", outputs: ["events"] }, { kind: "component", type: FormTemplate, selector: "templates-form" }, { kind: "component", type: TabsFrame, selector: "frames-tabs", inputs: ["labels"], outputs: ["selectedTabIndexChange"] }, { kind: "component", type: CommandFormGroup, selector: "groups-command-form", inputs: ["apiJsonUrls"] }, { kind: "component", type: QueryFormGroup, selector: "groups-query-form", inputs: ["form", "keyActions"] }] });
|
|
426
426
|
}
|
|
427
427
|
__decorate([
|
|
428
428
|
Effect(FormTemplateStore.ActionId.FILE_SELECTED),
|
|
@@ -485,7 +485,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.6", ngImpor
|
|
|
485
485
|
'actions',
|
|
486
486
|
]
|
|
487
487
|
},
|
|
488
|
-
], styles: [":host{width:100%;height:100%;display:block;--page-width-lv1-SCOPED-IN-command-
|
|
488
|
+
], styles: [":host{width:100%;height:100%;display:block;--page-width-lv1-SCOPED-IN-command-NWbS: var(--page-width-lv1);--primary-color-SCOPED-IN-command-NWbS: var(--primary-color);--on-primary-color-SCOPED-IN-command-NWbS: var(--on-primary-color);--background-color-SCOPED-IN-command-NWbS: var(--background-color);--on-background-color-SCOPED-IN-command-NWbS: var(--on-background-color)}:host templates-form{padding-left:0;box-sizing:border-box;transition:padding-left .3s}:host .template{--first-content-height: 0px;width:var(--page-width-lv1-SCOPED-IN-command-NWbS)}:host .template div[dashboard]{padding:0;box-sizing:border-box}:host *{--primary-color: var(--primary-color-SCOPED-IN-command-NWbS);--on-primary-color: var(--on-primary-color-SCOPED-IN-command-NWbS);--background-color: var(--background-color-SCOPED-IN-command-NWbS);--on-background-color: var(--on-background-color-SCOPED-IN-command-NWbS)}\n"] }]
|
|
489
489
|
}], propDecorators: { onFileSelected: [] } });
|
|
490
490
|
|
|
491
491
|
/**
|
|
@@ -688,7 +688,7 @@ class QueryPage extends NgAtomicComponent {
|
|
|
688
688
|
<groups-query-form dashboard (action)="dispatch($event)" />
|
|
689
689
|
</templates-index>
|
|
690
690
|
</frames-router-outlet>
|
|
691
|
-
`, isInline: true, styles: ["@charset \"UTF-8\";:host{width:100%;height:100%;display:block;--page-width-lv1-SCOPED-IN-query-
|
|
691
|
+
`, isInline: true, styles: ["@charset \"UTF-8\";:host{width:100%;height:100%;display:block;--page-width-lv1-SCOPED-IN-query-nTtQ: var(--page-width-lv1);--page-width-lv3-SCOPED-IN-query-nTtQ: var(--page-width-lv3);--primary-color-SCOPED-IN-query-nTtQ: var(--primary-color);--on-primary-color-SCOPED-IN-query-nTtQ: var(--on-primary-color);--surface-color-SCOPED-IN-query-nTtQ: var(--surface-color);--on-surface-color-SCOPED-IN-query-nTtQ: var(--on-surface-color);--on-background-color-SCOPED-IN-query-nTtQ: var(--on-background-color);--background-color-SCOPED-IN-query-nTtQ: var(--background-color);--navigator-background-color-SCOPED-IN-query-nTtQ: var(--navigator-background-color);--navigator-on-background-color-SCOPED-IN-query-nTtQ: var(--navigator-on-background-color);--table-background-color-SCOPED-IN-query-nTtQ: var(--table-background-color);--table-on-background-color-SCOPED-IN-query-nTtQ: var(--table-on-background-color);--is-debug: 1;--is-debug-SCOPED-IN-query-nTtQ: var(--is-debug)}:host *{--primary-color: var(--primary-color-SCOPED-IN-query-nTtQ);--on-primary-color: var(--on-primary-color-SCOPED-IN-query-nTtQ);--surface-color: var(--surface-color-SCOPED-IN-query-nTtQ);--on-surface-color: var(--on-surface-color-SCOPED-IN-query-nTtQ);--background-color: var(--background-color-SCOPED-IN-query-nTtQ);--on-background-color: var(--on-background-color-SCOPED-IN-query-nTtQ);--navigator-background-color: var(--navigator-background-color-SCOPED-IN-query-nTtQ);--navigator-on-background-color: var(--navigator-on-background-color-SCOPED-IN-query-nTtQ);--table-background-color: var(--table-background-color-SCOPED-IN-query-nTtQ);--table-on-background-color: var(--table-on-background-color-SCOPED-IN-query-nTtQ);--is-debug: var(--is-debug-SCOPED-IN-query-nTtQ)}:host templates-index{padding-left:0;box-sizing:border-box;--first-content-height: calc(var(--is-debug-SCOPED-IN-query-nTtQ) * 300px);transition:padding-left .3s}:host templates-index div[navDashboard]{display:grid;grid-template-columns:repeat(auto-fit,minmax(240px,1fr));gap:16px;padding:16px;box-sizing:border-box}:host templates-index div[navDashboard] ng-atomic-form-section-builder{--horizontal-padding: 0}\n"], dependencies: [{ kind: "component", type: IndexTemplate, selector: "templates-index" }, { kind: "component", type: RouterOutletFrame, selector: "frames-router-outlet", outputs: ["events"] }, { kind: "component", type: NgAtomicFormSectionBuilder, selector: "ng-atomic-form-section-builder", inputs: ["form", "formFlatExcludes", "fieldMap", "fieldKeys"] }, { kind: "component", type: QueryFormGroup, selector: "groups-query-form", inputs: ["form", "keyActions"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
692
692
|
}
|
|
693
693
|
__decorate([
|
|
694
694
|
Effect(IndexTemplateStore.ActionId.BACK),
|
|
@@ -769,7 +769,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.6", ngImpor
|
|
|
769
769
|
'pageSizeOptions'
|
|
770
770
|
]
|
|
771
771
|
},
|
|
772
|
-
], styles: ["@charset \"UTF-8\";:host{width:100%;height:100%;display:block;--page-width-lv1-SCOPED-IN-query-
|
|
772
|
+
], styles: ["@charset \"UTF-8\";:host{width:100%;height:100%;display:block;--page-width-lv1-SCOPED-IN-query-nTtQ: var(--page-width-lv1);--page-width-lv3-SCOPED-IN-query-nTtQ: var(--page-width-lv3);--primary-color-SCOPED-IN-query-nTtQ: var(--primary-color);--on-primary-color-SCOPED-IN-query-nTtQ: var(--on-primary-color);--surface-color-SCOPED-IN-query-nTtQ: var(--surface-color);--on-surface-color-SCOPED-IN-query-nTtQ: var(--on-surface-color);--on-background-color-SCOPED-IN-query-nTtQ: var(--on-background-color);--background-color-SCOPED-IN-query-nTtQ: var(--background-color);--navigator-background-color-SCOPED-IN-query-nTtQ: var(--navigator-background-color);--navigator-on-background-color-SCOPED-IN-query-nTtQ: var(--navigator-on-background-color);--table-background-color-SCOPED-IN-query-nTtQ: var(--table-background-color);--table-on-background-color-SCOPED-IN-query-nTtQ: var(--table-on-background-color);--is-debug: 1;--is-debug-SCOPED-IN-query-nTtQ: var(--is-debug)}:host *{--primary-color: var(--primary-color-SCOPED-IN-query-nTtQ);--on-primary-color: var(--on-primary-color-SCOPED-IN-query-nTtQ);--surface-color: var(--surface-color-SCOPED-IN-query-nTtQ);--on-surface-color: var(--on-surface-color-SCOPED-IN-query-nTtQ);--background-color: var(--background-color-SCOPED-IN-query-nTtQ);--on-background-color: var(--on-background-color-SCOPED-IN-query-nTtQ);--navigator-background-color: var(--navigator-background-color-SCOPED-IN-query-nTtQ);--navigator-on-background-color: var(--navigator-on-background-color-SCOPED-IN-query-nTtQ);--table-background-color: var(--table-background-color-SCOPED-IN-query-nTtQ);--table-on-background-color: var(--table-on-background-color-SCOPED-IN-query-nTtQ);--is-debug: var(--is-debug-SCOPED-IN-query-nTtQ)}:host templates-index{padding-left:0;box-sizing:border-box;--first-content-height: calc(var(--is-debug-SCOPED-IN-query-nTtQ) * 300px);transition:padding-left .3s}:host templates-index div[navDashboard]{display:grid;grid-template-columns:repeat(auto-fit,minmax(240px,1fr));gap:16px;padding:16px;box-sizing:border-box}:host templates-index div[navDashboard] ng-atomic-form-section-builder{--horizontal-padding: 0}\n"] }]
|
|
773
773
|
}], ctorParameters: () => [], propDecorators: { template: [{ type: i0.ViewChild, args: [i0.forwardRef(() => IndexTemplate), { isSignal: true }] }], title: [{ type: i0.Input, args: [{ isSignal: true, alias: "title", required: false }] }], back: [], navigateToIframe: [], expandPage: [], itemClick: [] } });
|
|
774
774
|
|
|
775
775
|
/**
|
|
@@ -104,7 +104,7 @@ class ThreadPage extends NgAtomicComponent {
|
|
|
104
104
|
(action)="dispatch($event)"
|
|
105
105
|
/>
|
|
106
106
|
</frames-router-outlet>
|
|
107
|
-
`, isInline: true, styles: [":host{width:100%;height:100%;display:block;--page-width-lv1-SCOPED-IN-thread-
|
|
107
|
+
`, isInline: true, styles: [":host{width:100%;height:100%;display:block;--page-width-lv1-SCOPED-IN-thread-4zSx: var(--page-width-lv1);--page-width-lv3-SCOPED-IN-thread-4zSx: var(--page-width-lv3);--primary-color-SCOPED-IN-thread-4zSx: var(--primary-color);--on-primary-color-SCOPED-IN-thread-4zSx: var(--on-primary-color);--surface-color-SCOPED-IN-thread-4zSx: var(--surface-color);--on-surface-color-SCOPED-IN-thread-4zSx: var(--on-surface-color);--on-background-color-SCOPED-IN-thread-4zSx: var(--on-background-color);--background-color-SCOPED-IN-thread-4zSx: var(--background-color);--navigator-background-color-SCOPED-IN-thread-4zSx: var(--navigator-background-color);--navigator-on-background-color-SCOPED-IN-thread-4zSx: var(--navigator-on-background-color);--table-background-color-SCOPED-IN-thread-4zSx: var(--table-background-color);--table-on-background-color-SCOPED-IN-thread-4zSx: var(--table-on-background-color)}:host .template{width:var(--page-width-lv1-SCOPED-IN-thread-4zSx)}:host .chat-container{display:flex;flex-direction:column;height:100%}:host .message{padding:10px;border-bottom:1px solid #ccc}\n"], dependencies: [{ kind: "component", type: RouterOutletFrame, selector: "frames-router-outlet", outputs: ["events"] }, { kind: "component", type: ThreadTemplate, selector: "templates-messages" }] });
|
|
108
108
|
}
|
|
109
109
|
__decorate([
|
|
110
110
|
Effect(ActionId.SEND_MESSAGE),
|
|
@@ -137,7 +137,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.6", ngImpor
|
|
|
137
137
|
'messages',
|
|
138
138
|
]
|
|
139
139
|
},
|
|
140
|
-
], styles: [":host{width:100%;height:100%;display:block;--page-width-lv1-SCOPED-IN-thread-
|
|
140
|
+
], styles: [":host{width:100%;height:100%;display:block;--page-width-lv1-SCOPED-IN-thread-4zSx: var(--page-width-lv1);--page-width-lv3-SCOPED-IN-thread-4zSx: var(--page-width-lv3);--primary-color-SCOPED-IN-thread-4zSx: var(--primary-color);--on-primary-color-SCOPED-IN-thread-4zSx: var(--on-primary-color);--surface-color-SCOPED-IN-thread-4zSx: var(--surface-color);--on-surface-color-SCOPED-IN-thread-4zSx: var(--on-surface-color);--on-background-color-SCOPED-IN-thread-4zSx: var(--on-background-color);--background-color-SCOPED-IN-thread-4zSx: var(--background-color);--navigator-background-color-SCOPED-IN-thread-4zSx: var(--navigator-background-color);--navigator-on-background-color-SCOPED-IN-thread-4zSx: var(--navigator-on-background-color);--table-background-color-SCOPED-IN-thread-4zSx: var(--table-background-color);--table-on-background-color-SCOPED-IN-thread-4zSx: var(--table-on-background-color)}:host .template{width:var(--page-width-lv1-SCOPED-IN-thread-4zSx)}:host .chat-container{display:flex;flex-direction:column;height:100%}:host .message{padding:10px;border-bottom:1px solid #ccc}\n"] }]
|
|
141
141
|
}], propDecorators: { onCompositionStart: [{
|
|
142
142
|
type: HostListener,
|
|
143
143
|
args: ['compositionstart', ['$event']]
|
|
@@ -420,7 +420,7 @@ class AgentTemplate extends NgAtomicComponent {
|
|
|
420
420
|
</div>
|
|
421
421
|
}
|
|
422
422
|
</frames-scroll>
|
|
423
|
-
`, isInline: true, styles: [":host{--text: #e0e0e0;--text-SCOPED-IN-entrance-
|
|
423
|
+
`, isInline: true, styles: [":host{--text: #e0e0e0;--text-SCOPED-IN-entrance-yWfj: var(--text);--user: #33ff33;--user-SCOPED-IN-entrance-yWfj: var(--user);--sys: #888;--sys-SCOPED-IN-entrance-yWfj: var(--sys);--accent: #ff79c6;--accent-SCOPED-IN-entrance-yWfj: var(--accent);--border: rgba(51, 51, 51, .5);--border-SCOPED-IN-entrance-yWfj: var(--border)}@keyframes fadeIn{0%{opacity:0;transform:translateY(10px)}to{opacity:1;transform:translateY(0)}}:host{display:flex;justify-content:center;align-items:center;width:100%;height:100%;background:transparent;font-family:SF Mono,Monaco,monospace;container-type:inline-size;container-name:agent-container;transition:all .3s ease}.terminal-window{--height: 100%;--contents-gap: 0;width:100%;max-width:900px;height:600px;background:#0a0a0a;border:1px solid var(--border-SCOPED-IN-entrance-yWfj);border-radius:8px;box-shadow:0 20px 40px #0000004d;animation:fadeIn .3s;transition:all .3s ease}.terminal-header{display:flex;justify-content:space-between;align-items:center;height:56px;min-height:56px;flex-shrink:0;padding:0;background:#1a1a1a99;border-bottom:1px solid var(--border-SCOPED-IN-entrance-yWfj);transition:all .3s ease;position:relative}.terminal-header .close-button{color:var(--sys-SCOPED-IN-entrance-yWfj);margin-right:.5rem;opacity:.7}.terminal-header .close-button:hover{color:var(--text-SCOPED-IN-entrance-yWfj);opacity:1}.terminal-header .terminal-title{font-size:13px;color:var(--text-SCOPED-IN-entrance-yWfj);font-weight:500;flex:1}.terminal-header .terminal-status{font-size:12px;color:var(--sys-SCOPED-IN-entrance-yWfj);opacity:.7}.terminal-display{width:100%;height:100%;background:#0a0a0a}.input-area{background:#000000e6;border-top:1px solid var(--border-SCOPED-IN-entrance-yWfj);backdrop-filter:blur(10px);-webkit-backdrop-filter:blur(10px);transition:all .3s ease;padding:16px 20px}.input-line{display:block;position:relative}.input-line .input-prefix{display:none}.input-line .textarea-wrapper{display:flex;align-items:flex-start;position:relative;border:1px solid rgba(255,255,255,.2);border-radius:4px;transition:border-color .2s ease}.input-line .textarea-wrapper:focus-within{border-color:#fff6}.input-line .textarea-wrapper .arrow-prefix{color:#e0e0e0;font-family:SF Mono,Monaco,monospace;font-size:14px;font-weight:400;padding:12px 0 12px 16px;flex-shrink:0;pointer-events:none}.input-line .textarea-wrapper .input-container{flex:1;position:relative;overflow:hidden}.input-line .textarea-wrapper .terminal-input{width:100%;background:transparent;border:none;outline:none;color:#e0e0e0;font-family:SF Mono,Monaco,monospace;font-size:14px;font-weight:400;caret-color:transparent;padding:12px 16px 12px 8px;transition:none;resize:none;height:44px;min-height:44px;max-height:200px;overflow-y:auto;overflow-x:hidden;line-height:20px;box-sizing:border-box;white-space:pre-wrap;word-wrap:break-word}.input-line .textarea-wrapper .terminal-input::selection{background:#ffffff4d}.input-line .textarea-wrapper .terminal-input{caret-shape:block}.input-line .textarea-wrapper .terminal-input:disabled{opacity:.5;cursor:not-allowed}.input-line .textarea-wrapper .terminal-input:-webkit-autofill{-webkit-text-fill-color:#e0e0e0;-webkit-box-shadow:0 0 0 1000px rgba(0,0,0,.9) inset}.input-line .textarea-wrapper .terminal-input::placeholder{color:#ffffff4d;opacity:1}.input-line .textarea-wrapper .block-cursor{position:absolute;width:10px;height:20px;background:#e0e0e0;opacity:0;pointer-events:none}.input-line .textarea-wrapper .block-cursor.visible{animation:blink 1s infinite}@keyframes blink{0%,50%{opacity:.8}51%,to{opacity:0}}:host:has(.terminal-window){height:100vh;height:100dvh;overflow-y:auto}@container agent-container (max-width: 600px){:host{padding:0;padding-top:env(safe-area-inset-top)}.terminal-window{height:100%;max-height:100vh;max-height:100dvh;max-width:100%;border-radius:0;border:none;box-shadow:none}.terminal-header{height:56px;padding:0}.terminal-header .terminal-title{font-size:12px}.terminal-header .terminal-status{font-size:11px}.terminal-header .close-button{margin-right:.25rem}}@container agent-container (min-width: 601px) and (max-width: 900px){.terminal-window{max-width:100%;height:100%;border-radius:0}}@container agent-container (max-width: 400px){.terminal-header{height:56px;padding:0}.terminal-header .close-button{margin-right:.2rem}.input-area{padding:12px 16px}.textarea-wrapper .arrow-prefix{font-size:13px;padding:10px 0 10px 12px}.textarea-wrapper .terminal-input{font-size:12px;padding:10px 12px 10px 6px;height:40px;min-height:40px;line-height:20px}}.ascii-art{font-family:Consolas,Monaco,Liberation Mono,Menlo,Courier New,monospace!important;font-size:10px!important;line-height:1.1!important;letter-spacing:0!important;font-weight:400!important;margin:1em 0!important;padding:1em!important;white-space:pre!important;overflow-x:auto!important;overflow-y:hidden!important;display:block!important;width:fit-content!important;background:#ffffff08;border:1px solid var(--border-SCOPED-IN-entrance-yWfj);border-radius:4px;color:var(--accent-SCOPED-IN-entrance-yWfj)!important;opacity:.9;text-shadow:0 0 10px var(--accent-SCOPED-IN-entrance-yWfj),0 0 20px var(--accent-SCOPED-IN-entrance-yWfj);-webkit-font-smoothing:none!important;-moz-osx-font-smoothing:unset!important;font-variant-ligatures:none!important;text-rendering:optimizeLegibility!important}\n"], dependencies: [{ kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i2.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: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: ScrollFrame, selector: "frames-scroll" }, { kind: "ngmodule", type: MatButtonModule }, { kind: "ngmodule", type: MatIconModule }, { kind: "ngmodule", type: MatTooltipModule }, { kind: "component", type: XtermOrganism, selector: "organisms-xterm", outputs: ["terminalReady", "githubLinkClick"] }, { kind: "directive", type: NavigatorOrganismStore, selector: "organisms-navigator", inputs: ["startActions", "endActions", "title"] }], changeDetection: i0.ChangeDetectionStrategy.Default });
|
|
424
424
|
}
|
|
425
425
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: AgentTemplate, decorators: [{
|
|
426
426
|
type: Component,
|
|
@@ -505,7 +505,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.6", ngImpor
|
|
|
505
505
|
'fieldMap',
|
|
506
506
|
],
|
|
507
507
|
},
|
|
508
|
-
], styles: [":host{--text: #e0e0e0;--text-SCOPED-IN-entrance-
|
|
508
|
+
], styles: [":host{--text: #e0e0e0;--text-SCOPED-IN-entrance-yWfj: var(--text);--user: #33ff33;--user-SCOPED-IN-entrance-yWfj: var(--user);--sys: #888;--sys-SCOPED-IN-entrance-yWfj: var(--sys);--accent: #ff79c6;--accent-SCOPED-IN-entrance-yWfj: var(--accent);--border: rgba(51, 51, 51, .5);--border-SCOPED-IN-entrance-yWfj: var(--border)}@keyframes fadeIn{0%{opacity:0;transform:translateY(10px)}to{opacity:1;transform:translateY(0)}}:host{display:flex;justify-content:center;align-items:center;width:100%;height:100%;background:transparent;font-family:SF Mono,Monaco,monospace;container-type:inline-size;container-name:agent-container;transition:all .3s ease}.terminal-window{--height: 100%;--contents-gap: 0;width:100%;max-width:900px;height:600px;background:#0a0a0a;border:1px solid var(--border-SCOPED-IN-entrance-yWfj);border-radius:8px;box-shadow:0 20px 40px #0000004d;animation:fadeIn .3s;transition:all .3s ease}.terminal-header{display:flex;justify-content:space-between;align-items:center;height:56px;min-height:56px;flex-shrink:0;padding:0;background:#1a1a1a99;border-bottom:1px solid var(--border-SCOPED-IN-entrance-yWfj);transition:all .3s ease;position:relative}.terminal-header .close-button{color:var(--sys-SCOPED-IN-entrance-yWfj);margin-right:.5rem;opacity:.7}.terminal-header .close-button:hover{color:var(--text-SCOPED-IN-entrance-yWfj);opacity:1}.terminal-header .terminal-title{font-size:13px;color:var(--text-SCOPED-IN-entrance-yWfj);font-weight:500;flex:1}.terminal-header .terminal-status{font-size:12px;color:var(--sys-SCOPED-IN-entrance-yWfj);opacity:.7}.terminal-display{width:100%;height:100%;background:#0a0a0a}.input-area{background:#000000e6;border-top:1px solid var(--border-SCOPED-IN-entrance-yWfj);backdrop-filter:blur(10px);-webkit-backdrop-filter:blur(10px);transition:all .3s ease;padding:16px 20px}.input-line{display:block;position:relative}.input-line .input-prefix{display:none}.input-line .textarea-wrapper{display:flex;align-items:flex-start;position:relative;border:1px solid rgba(255,255,255,.2);border-radius:4px;transition:border-color .2s ease}.input-line .textarea-wrapper:focus-within{border-color:#fff6}.input-line .textarea-wrapper .arrow-prefix{color:#e0e0e0;font-family:SF Mono,Monaco,monospace;font-size:14px;font-weight:400;padding:12px 0 12px 16px;flex-shrink:0;pointer-events:none}.input-line .textarea-wrapper .input-container{flex:1;position:relative;overflow:hidden}.input-line .textarea-wrapper .terminal-input{width:100%;background:transparent;border:none;outline:none;color:#e0e0e0;font-family:SF Mono,Monaco,monospace;font-size:14px;font-weight:400;caret-color:transparent;padding:12px 16px 12px 8px;transition:none;resize:none;height:44px;min-height:44px;max-height:200px;overflow-y:auto;overflow-x:hidden;line-height:20px;box-sizing:border-box;white-space:pre-wrap;word-wrap:break-word}.input-line .textarea-wrapper .terminal-input::selection{background:#ffffff4d}.input-line .textarea-wrapper .terminal-input{caret-shape:block}.input-line .textarea-wrapper .terminal-input:disabled{opacity:.5;cursor:not-allowed}.input-line .textarea-wrapper .terminal-input:-webkit-autofill{-webkit-text-fill-color:#e0e0e0;-webkit-box-shadow:0 0 0 1000px rgba(0,0,0,.9) inset}.input-line .textarea-wrapper .terminal-input::placeholder{color:#ffffff4d;opacity:1}.input-line .textarea-wrapper .block-cursor{position:absolute;width:10px;height:20px;background:#e0e0e0;opacity:0;pointer-events:none}.input-line .textarea-wrapper .block-cursor.visible{animation:blink 1s infinite}@keyframes blink{0%,50%{opacity:.8}51%,to{opacity:0}}:host:has(.terminal-window){height:100vh;height:100dvh;overflow-y:auto}@container agent-container (max-width: 600px){:host{padding:0;padding-top:env(safe-area-inset-top)}.terminal-window{height:100%;max-height:100vh;max-height:100dvh;max-width:100%;border-radius:0;border:none;box-shadow:none}.terminal-header{height:56px;padding:0}.terminal-header .terminal-title{font-size:12px}.terminal-header .terminal-status{font-size:11px}.terminal-header .close-button{margin-right:.25rem}}@container agent-container (min-width: 601px) and (max-width: 900px){.terminal-window{max-width:100%;height:100%;border-radius:0}}@container agent-container (max-width: 400px){.terminal-header{height:56px;padding:0}.terminal-header .close-button{margin-right:.2rem}.input-area{padding:12px 16px}.textarea-wrapper .arrow-prefix{font-size:13px;padding:10px 0 10px 12px}.textarea-wrapper .terminal-input{font-size:12px;padding:10px 12px 10px 6px;height:40px;min-height:40px;line-height:20px}}.ascii-art{font-family:Consolas,Monaco,Liberation Mono,Menlo,Courier New,monospace!important;font-size:10px!important;line-height:1.1!important;letter-spacing:0!important;font-weight:400!important;margin:1em 0!important;padding:1em!important;white-space:pre!important;overflow-x:auto!important;overflow-y:hidden!important;display:block!important;width:fit-content!important;background:#ffffff08;border:1px solid var(--border-SCOPED-IN-entrance-yWfj);border-radius:4px;color:var(--accent-SCOPED-IN-entrance-yWfj)!important;opacity:.9;text-shadow:0 0 10px var(--accent-SCOPED-IN-entrance-yWfj),0 0 20px var(--accent-SCOPED-IN-entrance-yWfj);-webkit-font-smoothing:none!important;-moz-osx-font-smoothing:unset!important;font-variant-ligatures:none!important;text-rendering:optimizeLegibility!important}\n"] }]
|
|
509
509
|
}], propDecorators: { endActions: [{ type: i0.Input, args: [{ isSignal: true, alias: "endActions", required: false }] }], hideInputArea: [{ type: i0.Input, args: [{ isSignal: true, alias: "hideInputArea", required: false }] }], xtermComponent: [{ type: i0.ViewChild, args: ['xtermComponent', { isSignal: true }] }], inputField: [{ type: i0.ViewChild, args: ['inputField', { isSignal: true }] }], onWindowResize: [{
|
|
510
510
|
type: HostListener,
|
|
511
511
|
args: ['window:resize']
|
|
@@ -38,7 +38,7 @@ class MachinaIconButtonMenuTemplate extends NgAtomicComponent {
|
|
|
38
38
|
</button>
|
|
39
39
|
}
|
|
40
40
|
</div>
|
|
41
|
-
`, isInline: true, styles: [":host{width:100%;height:100%;background:#fff;display:block;--primary-color: #404040;--primary-color-SCOPED-IN-icon-button-menu-
|
|
41
|
+
`, isInline: true, styles: [":host{width:100%;height:100%;background:#fff;display:block;--primary-color: #404040;--primary-color-SCOPED-IN-icon-button-menu-YKIS: var(--primary-color);--on-primary-color: #f0f0f0;--on-primary-color-SCOPED-IN-icon-button-menu-YKIS: var(--on-primary-color);--secondary-color: #B0B0B0;--secondary-color-SCOPED-IN-icon-button-menu-YKIS: var(--secondary-color);--background-color: #000000;--background-color-SCOPED-IN-icon-button-menu-YKIS: var(--background-color);--on-background-color: #ffffff;--on-background-color-SCOPED-IN-icon-button-menu-YKIS: var(--on-background-color);--mat-icon-button-icon-color: #FEFEFE;--mat-icon-button-icon-color-SCOPED-IN-icon-button-menu-YKIS: var(--mat-icon-button-icon-color)}:host{display:flex;flex-direction:column;justify-content:space-between;align-items:center;width:100%;height:100%;background-color:var(--background-color-SCOPED-IN-icon-button-menu-YKIS);color:var(--on-background-color-SCOPED-IN-icon-button-menu-YKIS)}:host .top,:host .bottom{display:flex;flex-direction:column;justify-content:center;align-items:center}:host button{--mat-icon-color: var(--on-primary-color-SCOPED-IN-icon-button-menu-YKIS);cursor:pointer}\n"], dependencies: [{ kind: "ngmodule", type: MatButtonModule }, { kind: "component", type: i2.MatIconButton, selector: "button[mat-icon-button], a[mat-icon-button], button[matIconButton], a[matIconButton]", exportAs: ["matButton", "matAnchor"] }, { kind: "ngmodule", type: MatIconModule }, { kind: "component", type: i3.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "ngmodule", type: MatTooltipModule }, { kind: "directive", type: i4.MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "component", type: UserAvatarMenuMolecule, selector: "molecules-user-avatar-menu", inputs: ["signOutAction"], outputs: ["workspaceSwitch"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
42
42
|
}
|
|
43
43
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: MachinaIconButtonMenuTemplate, decorators: [{
|
|
44
44
|
type: Component,
|
|
@@ -67,7 +67,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.6", ngImpor
|
|
|
67
67
|
directive: IconButtonMenuTemplateStore,
|
|
68
68
|
inputs: ['actions', 'bottomActions', 'topPadding'],
|
|
69
69
|
},
|
|
70
|
-
], styles: [":host{width:100%;height:100%;background:#fff;display:block;--primary-color: #404040;--primary-color-SCOPED-IN-icon-button-menu-
|
|
70
|
+
], styles: [":host{width:100%;height:100%;background:#fff;display:block;--primary-color: #404040;--primary-color-SCOPED-IN-icon-button-menu-YKIS: var(--primary-color);--on-primary-color: #f0f0f0;--on-primary-color-SCOPED-IN-icon-button-menu-YKIS: var(--on-primary-color);--secondary-color: #B0B0B0;--secondary-color-SCOPED-IN-icon-button-menu-YKIS: var(--secondary-color);--background-color: #000000;--background-color-SCOPED-IN-icon-button-menu-YKIS: var(--background-color);--on-background-color: #ffffff;--on-background-color-SCOPED-IN-icon-button-menu-YKIS: var(--on-background-color);--mat-icon-button-icon-color: #FEFEFE;--mat-icon-button-icon-color-SCOPED-IN-icon-button-menu-YKIS: var(--mat-icon-button-icon-color)}:host{display:flex;flex-direction:column;justify-content:space-between;align-items:center;width:100%;height:100%;background-color:var(--background-color-SCOPED-IN-icon-button-menu-YKIS);color:var(--on-background-color-SCOPED-IN-icon-button-menu-YKIS)}:host .top,:host .bottom{display:flex;flex-direction:column;justify-content:center;align-items:center}:host button{--mat-icon-color: var(--on-primary-color-SCOPED-IN-icon-button-menu-YKIS);cursor:pointer}\n"] }]
|
|
71
71
|
}] });
|
|
72
72
|
|
|
73
73
|
/**
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
import * as i0 from '@angular/core';
|
|
2
|
+
import { inject, computed, ChangeDetectionStrategy, Component } from '@angular/core';
|
|
3
|
+
import { NgAtomicComponent } from '@ng-atomic/core';
|
|
4
|
+
import { AuthService } from '@ng-atomic/common/services/auth';
|
|
5
|
+
import { SideNavModeService } from '@ng-atomic/common/services/side-nav-mode';
|
|
6
|
+
import * as i1 from '@ng-atomic/components/templates/menu';
|
|
7
|
+
import { MenuTemplateStore } from '@ng-atomic/components/templates/menu';
|
|
8
|
+
import { NavigationListOrganismStore } from '@ng-atomic/components/organisms/navigation-list';
|
|
9
|
+
import { MenuFooterOrganismStore } from '@ng-atomic/components/organisms/menu-footer';
|
|
10
|
+
import { MenuHeaderOrganismStore } from '@ng-atomic/components/organisms/menu-header';
|
|
11
|
+
import { UserAvatarMenuMolecule } from '@xxmachina/components/molecules/user-avatar-menu';
|
|
12
|
+
|
|
13
|
+
class MachinaMenuTemplate extends NgAtomicComponent {
|
|
14
|
+
store = inject(MenuTemplateStore);
|
|
15
|
+
auth = inject(AuthService);
|
|
16
|
+
sideNav = inject(SideNavModeService);
|
|
17
|
+
signOutAction = computed(() => this.auth.auth() ? this.store.bottomActions()[0] ?? null : null, ...(ngDevMode ? [{ debugName: "signOutAction" }] : []));
|
|
18
|
+
restBottomActions = computed(() => this.signOutAction() ? this.store.bottomActions().slice(1) : this.store.bottomActions(), ...(ngDevMode ? [{ debugName: "restBottomActions" }] : []));
|
|
19
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: MachinaMenuTemplate, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
20
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.1.6", type: MachinaMenuTemplate, isStandalone: true, selector: "templates-menu", usesInheritance: true, hostDirectives: [{ directive: i1.MenuTemplateStore, inputs: ["actions", "actions", "bottomActions", "bottomActions", "title", "title"] }], ngImport: i0, template: `
|
|
21
|
+
<div class="top">
|
|
22
|
+
<organisms-menu-header [title]="store.title()" injectable/>
|
|
23
|
+
<organisms-navigation-list injectable
|
|
24
|
+
[actions]="store.actions()"
|
|
25
|
+
(action)="dispatch($event)"
|
|
26
|
+
/>
|
|
27
|
+
</div>
|
|
28
|
+
<div class="bottom">
|
|
29
|
+
@if (signOutAction(); as signOut) {
|
|
30
|
+
<molecules-user-avatar-menu
|
|
31
|
+
[signOutAction]="signOut"
|
|
32
|
+
(workspaceSwitch)="sideNav.collapse()"
|
|
33
|
+
(action)="dispatch($event)"
|
|
34
|
+
/>
|
|
35
|
+
}
|
|
36
|
+
@if (restBottomActions().length > 0) {
|
|
37
|
+
<organisms-navigation-list injectable
|
|
38
|
+
[actions]="restBottomActions()"
|
|
39
|
+
(action)="dispatch($event)"
|
|
40
|
+
/>
|
|
41
|
+
}
|
|
42
|
+
<organisms-menu-footer injectable/>
|
|
43
|
+
</div>
|
|
44
|
+
`, isInline: true, styles: [":host{--primary-color: #404040;--primary-color-SCOPED-IN-menu-fhFz: var(--primary-color);--background-color: #f0f0f0;--background-color-SCOPED-IN-menu-fhFz: var(--background-color);--secondary-color: #f0f0f0;--secondary-color-SCOPED-IN-menu-fhFz: var(--secondary-color);--surface-color: #f0f0f0;--surface-color-SCOPED-IN-menu-fhFz: var(--surface-color);--on-primary-color: #f0f0f0;--on-primary-color-SCOPED-IN-menu-fhFz: var(--on-primary-color);--on-background-color: #404040;--on-background-color-SCOPED-IN-menu-fhFz: var(--on-background-color);--on-surface-color: #404040;--on-surface-color-SCOPED-IN-menu-fhFz: var(--on-surface-color);--width: 100%;--width-SCOPED-IN-menu-fhFz: var(--width);--height: 100%;--height-SCOPED-IN-menu-fhFz: var(--height)}:host{display:flex;flex-direction:column;justify-content:space-between;width:var(--width-SCOPED-IN-menu-fhFz);height:var(--height-SCOPED-IN-menu-fhFz);color:var(--on-background-color-SCOPED-IN-menu-fhFz);background-color:var(--background-color-SCOPED-IN-menu-fhFz)}:host *{--primary-color: var(--primary-color-SCOPED-IN-menu-fhFz);--background-color: var(--background-color-SCOPED-IN-menu-fhFz);--surface-color: var(--surface-color-SCOPED-IN-menu-fhFz);--on-primary-color: var(--on-primary-color-SCOPED-IN-menu-fhFz);--on-background-color: var(--on-background-color-SCOPED-IN-menu-fhFz);--on-surface-color: var(--on-surface-color-SCOPED-IN-menu-fhFz)}:host .bottom{display:flex;flex-wrap:wrap;align-items:center;gap:4px;padding-left:4px}:host .bottom organisms-navigation-list{flex-basis:100%;order:-1}:host .bottom organisms-menu-footer{flex:1}\n"], dependencies: [{ kind: "directive", type: MenuHeaderOrganismStore, selector: "organisms-menu-header", inputs: ["title"] }, { kind: "directive", type: NavigationListOrganismStore, selector: "organisms-navigation-list", inputs: ["actions", "type"] }, { kind: "directive", type: MenuFooterOrganismStore, selector: "organisms-menu-footer" }, { kind: "component", type: UserAvatarMenuMolecule, selector: "molecules-user-avatar-menu", inputs: ["signOutAction"], outputs: ["workspaceSwitch"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
45
|
+
}
|
|
46
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: MachinaMenuTemplate, decorators: [{
|
|
47
|
+
type: Component,
|
|
48
|
+
args: [{ selector: 'templates-menu', standalone: true, imports: [
|
|
49
|
+
MenuHeaderOrganismStore,
|
|
50
|
+
NavigationListOrganismStore,
|
|
51
|
+
MenuFooterOrganismStore,
|
|
52
|
+
UserAvatarMenuMolecule,
|
|
53
|
+
], template: `
|
|
54
|
+
<div class="top">
|
|
55
|
+
<organisms-menu-header [title]="store.title()" injectable/>
|
|
56
|
+
<organisms-navigation-list injectable
|
|
57
|
+
[actions]="store.actions()"
|
|
58
|
+
(action)="dispatch($event)"
|
|
59
|
+
/>
|
|
60
|
+
</div>
|
|
61
|
+
<div class="bottom">
|
|
62
|
+
@if (signOutAction(); as signOut) {
|
|
63
|
+
<molecules-user-avatar-menu
|
|
64
|
+
[signOutAction]="signOut"
|
|
65
|
+
(workspaceSwitch)="sideNav.collapse()"
|
|
66
|
+
(action)="dispatch($event)"
|
|
67
|
+
/>
|
|
68
|
+
}
|
|
69
|
+
@if (restBottomActions().length > 0) {
|
|
70
|
+
<organisms-navigation-list injectable
|
|
71
|
+
[actions]="restBottomActions()"
|
|
72
|
+
(action)="dispatch($event)"
|
|
73
|
+
/>
|
|
74
|
+
}
|
|
75
|
+
<organisms-menu-footer injectable/>
|
|
76
|
+
</div>
|
|
77
|
+
`, changeDetection: ChangeDetectionStrategy.OnPush, hostDirectives: [
|
|
78
|
+
{
|
|
79
|
+
directive: MenuTemplateStore,
|
|
80
|
+
inputs: ['actions', 'bottomActions', 'title'],
|
|
81
|
+
},
|
|
82
|
+
], styles: [":host{--primary-color: #404040;--primary-color-SCOPED-IN-menu-fhFz: var(--primary-color);--background-color: #f0f0f0;--background-color-SCOPED-IN-menu-fhFz: var(--background-color);--secondary-color: #f0f0f0;--secondary-color-SCOPED-IN-menu-fhFz: var(--secondary-color);--surface-color: #f0f0f0;--surface-color-SCOPED-IN-menu-fhFz: var(--surface-color);--on-primary-color: #f0f0f0;--on-primary-color-SCOPED-IN-menu-fhFz: var(--on-primary-color);--on-background-color: #404040;--on-background-color-SCOPED-IN-menu-fhFz: var(--on-background-color);--on-surface-color: #404040;--on-surface-color-SCOPED-IN-menu-fhFz: var(--on-surface-color);--width: 100%;--width-SCOPED-IN-menu-fhFz: var(--width);--height: 100%;--height-SCOPED-IN-menu-fhFz: var(--height)}:host{display:flex;flex-direction:column;justify-content:space-between;width:var(--width-SCOPED-IN-menu-fhFz);height:var(--height-SCOPED-IN-menu-fhFz);color:var(--on-background-color-SCOPED-IN-menu-fhFz);background-color:var(--background-color-SCOPED-IN-menu-fhFz)}:host *{--primary-color: var(--primary-color-SCOPED-IN-menu-fhFz);--background-color: var(--background-color-SCOPED-IN-menu-fhFz);--surface-color: var(--surface-color-SCOPED-IN-menu-fhFz);--on-primary-color: var(--on-primary-color-SCOPED-IN-menu-fhFz);--on-background-color: var(--on-background-color-SCOPED-IN-menu-fhFz);--on-surface-color: var(--on-surface-color-SCOPED-IN-menu-fhFz)}:host .bottom{display:flex;flex-wrap:wrap;align-items:center;gap:4px;padding-left:4px}:host .bottom organisms-navigation-list{flex-basis:100%;order:-1}:host .bottom organisms-menu-footer{flex:1}\n"] }]
|
|
83
|
+
}] });
|
|
84
|
+
|
|
85
|
+
/**
|
|
86
|
+
* Generated bundle index. Do not edit.
|
|
87
|
+
*/
|
|
88
|
+
|
|
89
|
+
export { MachinaMenuTemplate };
|
|
@@ -232,7 +232,7 @@ class SessionNavigatorOrganism extends NgAtomicComponent {
|
|
|
232
232
|
}
|
|
233
233
|
</div>
|
|
234
234
|
</mat-toolbar>
|
|
235
|
-
`, isInline: true, styles: [":host{display:block;--text: #e0e0e0;--text-SCOPED-IN-session-navigator-
|
|
235
|
+
`, isInline: true, styles: [":host{display:block;--text: #e0e0e0;--text-SCOPED-IN-session-navigator-jcsD: var(--text);--sys: #888;--sys-SCOPED-IN-session-navigator-jcsD: var(--sys);--border: rgba(51, 51, 51, .5);--border-SCOPED-IN-session-navigator-jcsD: var(--border);--primary-color: #0f0f11;--primary-color-SCOPED-IN-session-navigator-jcsD: var(--primary-color);--on-primary-color: #e0e0e0;--on-primary-color-SCOPED-IN-session-navigator-jcsD: var(--on-primary-color);--secondary-color: #888;--secondary-color-SCOPED-IN-session-navigator-jcsD: var(--secondary-color);--on-secondary-color: #f0f0f0;--on-secondary-color-SCOPED-IN-session-navigator-jcsD: var(--on-secondary-color);--background-color: #0f0f11;--background-color-SCOPED-IN-session-navigator-jcsD: var(--background-color);--on-background-color: #e0e0e0;--on-background-color-SCOPED-IN-session-navigator-jcsD: var(--on-background-color)}:host{display:block;width:100%;height:56px}:host mat-toolbar{display:flex;width:100%;height:100%;padding:0!important;justify-content:space-between;align-items:center;overflow:hidden;transition:background .5s ease-in-out;background-color:var(--primary-color-SCOPED-IN-session-navigator-jcsD);color:var(--on-primary-color-SCOPED-IN-session-navigator-jcsD);border-bottom:1px solid var(--border-SCOPED-IN-session-navigator-jcsD)!important;font-family:SF Mono,Monaco,monospace!important;font-size:12px!important;--mat-toolbar-title-text-size: 12px !important;--mat-sys-title-large-size: 12px !important}:host mat-toolbar>div:first-child,:host mat-toolbar>div:last-child{flex:0 0 auto}:host mat-toolbar>div:nth-child(2){flex:1 1 auto;display:flex;justify-content:flex-start;white-space:nowrap;text-overflow:ellipsis;overflow:hidden}:host mat-toolbar *:not(.mat-icon){font-family:SF Mono,Monaco,monospace!important}:host mat-toolbar span,:host mat-toolbar div,:host mat-toolbar h1,:host mat-toolbar h2,:host mat-toolbar h3,:host mat-toolbar h4,:host mat-toolbar h5,:host mat-toolbar h6{font-size:12px!important;font-family:SF Mono,Monaco,monospace!important;color:var(--text-SCOPED-IN-session-navigator-jcsD)!important}:host mat-toolbar .mat-button{color:var(--sys-SCOPED-IN-session-navigator-jcsD)!important;font-family:SF Mono,Monaco,monospace!important}:host mat-toolbar .mat-button:hover{color:var(--text-SCOPED-IN-session-navigator-jcsD)!important}:host mat-toolbar .mat-icon-button{color:var(--sys-SCOPED-IN-session-navigator-jcsD)!important;opacity:.7}:host mat-toolbar .mat-icon-button:hover{color:var(--text-SCOPED-IN-session-navigator-jcsD)!important;opacity:1}:host mat-toolbar .mat-icon-button .mat-icon{font-family:Material Icons!important;font-size:24px!important}:host div{display:flex;justify-content:center;align-items:center;line-height:1}:host atoms-menu-button{display:flex;align-items:center;line-height:1}@media(prefers-color-scheme:light){:host{--text: #333;--text-SCOPED-IN-session-navigator-jcsD: var(--text);--sys: #666;--sys-SCOPED-IN-session-navigator-jcsD: var(--sys);--border: #ddd;--border-SCOPED-IN-session-navigator-jcsD: var(--border)}}@media(max-width:600px){:host mat-toolbar span{font-size:11px!important}}\n"], dependencies: [{ kind: "ngmodule", type: MatButtonModule }, { kind: "ngmodule", type: MatIconModule }, { kind: "ngmodule", type: MatToolbarModule }, { kind: "component", type: i1$1.MatToolbar, selector: "mat-toolbar", inputs: ["color"], exportAs: ["matToolbar"] }, { kind: "directive", type: MenuButtonAtomStore, selector: "atoms-menu-button, atoms-smart-menu-button", inputs: ["actions", "type", "action"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
236
236
|
}
|
|
237
237
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.6", ngImport: i0, type: SessionNavigatorOrganism, decorators: [{
|
|
238
238
|
type: Component,
|
|
@@ -266,7 +266,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.6", ngImpor
|
|
|
266
266
|
directive: SessionNavigatorOrganismStore,
|
|
267
267
|
inputs: ['startActions', 'endActions', 'title'],
|
|
268
268
|
}
|
|
269
|
-
], styles: [":host{display:block;--text: #e0e0e0;--text-SCOPED-IN-session-navigator-
|
|
269
|
+
], styles: [":host{display:block;--text: #e0e0e0;--text-SCOPED-IN-session-navigator-jcsD: var(--text);--sys: #888;--sys-SCOPED-IN-session-navigator-jcsD: var(--sys);--border: rgba(51, 51, 51, .5);--border-SCOPED-IN-session-navigator-jcsD: var(--border);--primary-color: #0f0f11;--primary-color-SCOPED-IN-session-navigator-jcsD: var(--primary-color);--on-primary-color: #e0e0e0;--on-primary-color-SCOPED-IN-session-navigator-jcsD: var(--on-primary-color);--secondary-color: #888;--secondary-color-SCOPED-IN-session-navigator-jcsD: var(--secondary-color);--on-secondary-color: #f0f0f0;--on-secondary-color-SCOPED-IN-session-navigator-jcsD: var(--on-secondary-color);--background-color: #0f0f11;--background-color-SCOPED-IN-session-navigator-jcsD: var(--background-color);--on-background-color: #e0e0e0;--on-background-color-SCOPED-IN-session-navigator-jcsD: var(--on-background-color)}:host{display:block;width:100%;height:56px}:host mat-toolbar{display:flex;width:100%;height:100%;padding:0!important;justify-content:space-between;align-items:center;overflow:hidden;transition:background .5s ease-in-out;background-color:var(--primary-color-SCOPED-IN-session-navigator-jcsD);color:var(--on-primary-color-SCOPED-IN-session-navigator-jcsD);border-bottom:1px solid var(--border-SCOPED-IN-session-navigator-jcsD)!important;font-family:SF Mono,Monaco,monospace!important;font-size:12px!important;--mat-toolbar-title-text-size: 12px !important;--mat-sys-title-large-size: 12px !important}:host mat-toolbar>div:first-child,:host mat-toolbar>div:last-child{flex:0 0 auto}:host mat-toolbar>div:nth-child(2){flex:1 1 auto;display:flex;justify-content:flex-start;white-space:nowrap;text-overflow:ellipsis;overflow:hidden}:host mat-toolbar *:not(.mat-icon){font-family:SF Mono,Monaco,monospace!important}:host mat-toolbar span,:host mat-toolbar div,:host mat-toolbar h1,:host mat-toolbar h2,:host mat-toolbar h3,:host mat-toolbar h4,:host mat-toolbar h5,:host mat-toolbar h6{font-size:12px!important;font-family:SF Mono,Monaco,monospace!important;color:var(--text-SCOPED-IN-session-navigator-jcsD)!important}:host mat-toolbar .mat-button{color:var(--sys-SCOPED-IN-session-navigator-jcsD)!important;font-family:SF Mono,Monaco,monospace!important}:host mat-toolbar .mat-button:hover{color:var(--text-SCOPED-IN-session-navigator-jcsD)!important}:host mat-toolbar .mat-icon-button{color:var(--sys-SCOPED-IN-session-navigator-jcsD)!important;opacity:.7}:host mat-toolbar .mat-icon-button:hover{color:var(--text-SCOPED-IN-session-navigator-jcsD)!important;opacity:1}:host mat-toolbar .mat-icon-button .mat-icon{font-family:Material Icons!important;font-size:24px!important}:host div{display:flex;justify-content:center;align-items:center;line-height:1}:host atoms-menu-button{display:flex;align-items:center;line-height:1}@media(prefers-color-scheme:light){:host{--text: #333;--text-SCOPED-IN-session-navigator-jcsD: var(--text);--sys: #666;--sys-SCOPED-IN-session-navigator-jcsD: var(--sys);--border: #ddd;--border-SCOPED-IN-session-navigator-jcsD: var(--border)}}@media(max-width:600px){:host mat-toolbar span{font-size:11px!important}}\n"] }]
|
|
270
270
|
}] });
|
|
271
271
|
|
|
272
272
|
var InvoiceAppActionId;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@xxmachina/components",
|
|
3
|
-
"version": "19.
|
|
3
|
+
"version": "19.150.0",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"main": "./index.js",
|
|
6
6
|
"types": "./index.d.ts",
|
|
@@ -286,6 +286,10 @@
|
|
|
286
286
|
"types": "./types/xxmachina-components-templates-machina-icon-button-menu.d.ts",
|
|
287
287
|
"default": "./fesm2022/xxmachina-components-templates-machina-icon-button-menu.mjs"
|
|
288
288
|
},
|
|
289
|
+
"./templates/machina-menu": {
|
|
290
|
+
"types": "./types/xxmachina-components-templates-machina-menu.d.ts",
|
|
291
|
+
"default": "./fesm2022/xxmachina-components-templates-machina-menu.mjs"
|
|
292
|
+
},
|
|
289
293
|
"./templates/scheduler": {
|
|
290
294
|
"types": "./types/xxmachina-components-templates-scheduler.d.ts",
|
|
291
295
|
"default": "./fesm2022/xxmachina-components-templates-scheduler.mjs"
|
|
@@ -7,12 +7,14 @@ declare class UserAvatarMenuMolecule extends NgAtomicComponent {
|
|
|
7
7
|
protected readonly auth: AuthService;
|
|
8
8
|
protected readonly switcher: WorkspaceSwitcherService | null;
|
|
9
9
|
readonly signOutAction: _angular_core.InputSignal<Action<any>>;
|
|
10
|
+
readonly workspaceSwitch: _angular_core.OutputEmitterRef<string>;
|
|
10
11
|
protected readonly imgError: _angular_core.WritableSignal<boolean>;
|
|
12
|
+
protected switchTo(workspaceId: string): void;
|
|
11
13
|
protected readonly photoURL: _angular_core.Signal<string | null>;
|
|
12
14
|
protected readonly email: _angular_core.Signal<string | null>;
|
|
13
15
|
protected readonly initial: _angular_core.Signal<string>;
|
|
14
16
|
static ɵfac: _angular_core.ɵɵFactoryDeclaration<UserAvatarMenuMolecule, never>;
|
|
15
|
-
static ɵcmp: _angular_core.ɵɵComponentDeclaration<UserAvatarMenuMolecule, "molecules-user-avatar-menu", never, { "signOutAction": { "alias": "signOutAction"; "required": true; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
17
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<UserAvatarMenuMolecule, "molecules-user-avatar-menu", never, { "signOutAction": { "alias": "signOutAction"; "required": true; "isSignal": true; }; }, { "workspaceSwitch": "workspaceSwitch"; }, never, never, true, never>;
|
|
16
18
|
}
|
|
17
19
|
|
|
18
20
|
export { UserAvatarMenuMolecule };
|
|
@@ -39,12 +39,12 @@ declare class ProxyLinkProvider implements ILinkProvider {
|
|
|
39
39
|
private readonly _terminal;
|
|
40
40
|
private readonly _getServerUUID;
|
|
41
41
|
private readonly _getToken?;
|
|
42
|
-
private readonly _handler
|
|
42
|
+
private readonly _handler?;
|
|
43
43
|
private readonly _getDeployVersion?;
|
|
44
44
|
private readonly _getEndpoints?;
|
|
45
45
|
private readonly _onMissingToken?;
|
|
46
46
|
private readonly _getEnv?;
|
|
47
|
-
constructor(_terminal: Terminal, _getServerUUID: ServerUUIDGetter, _getToken?: TokenGetter | undefined, _handler?: (event: MouseEvent,
|
|
47
|
+
constructor(_terminal: Terminal, _getServerUUID: ServerUUIDGetter, _getToken?: TokenGetter | undefined, _handler?: ((event: MouseEvent, url: string) => void) | undefined, _getDeployVersion?: DeployVersionGetter | undefined, _getEndpoints?: EndpointsGetter | undefined, _onMissingToken?: (() => void) | undefined, _getEnv?: (() => "dev" | "stg" | "prod" | undefined) | undefined);
|
|
48
48
|
provideLinks(bufferLineNumber: number, callback: (links: ILink[] | undefined) => void): void;
|
|
49
49
|
}
|
|
50
50
|
|
|
@@ -52,8 +52,10 @@ declare enum XtermActionId {
|
|
|
52
52
|
DATA_INPUT = "xterm:data-input",
|
|
53
53
|
RESIZED = "xterm:resized",
|
|
54
54
|
GITHUB_LINK_CLICK = "xterm:github-link-click",
|
|
55
|
+
WEB_LINK_CLICK = "xterm:web-link-click",
|
|
55
56
|
FILE_LINK_CLICK = "xterm:file-link-click",
|
|
56
57
|
SESSION_MENTION_CLICK = "xterm:session-mention-click",
|
|
58
|
+
PORT_LINK_CLICK = "xterm:port-link-click",
|
|
57
59
|
FOCUS_INPUT_REQUEST = "xterm:focus-input-request"
|
|
58
60
|
}
|
|
59
61
|
interface XtermSessionContext {
|
|
@@ -138,10 +140,11 @@ declare class XtermOrganismStore extends InjectableComponent {
|
|
|
138
140
|
readonly queryResult: _angular_core.InputSignal<string>;
|
|
139
141
|
readonly useInteractiveTheme: _angular_core.InputSignal<boolean>;
|
|
140
142
|
readonly totalWritten: _angular_core.InputSignal<number>;
|
|
143
|
+
readonly staticScreen: _angular_core.InputSignal<boolean>;
|
|
141
144
|
readonly sessionContext: XtermSessionContext | null;
|
|
142
145
|
constructor();
|
|
143
146
|
static ɵfac: _angular_core.ɵɵFactoryDeclaration<XtermOrganismStore, never>;
|
|
144
|
-
static ɵdir: _angular_core.ɵɵDirectiveDeclaration<XtermOrganismStore, "organisms-xterm", never, { "data": { "alias": "data"; "required": false; "isSignal": true; }; "interactive": { "alias": "interactive"; "required": false; "isSignal": true; }; "queryResult": { "alias": "queryResult"; "required": false; "isSignal": true; }; "useInteractiveTheme": { "alias": "useInteractiveTheme"; "required": false; "isSignal": true; }; "totalWritten": { "alias": "totalWritten"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
147
|
+
static ɵdir: _angular_core.ɵɵDirectiveDeclaration<XtermOrganismStore, "organisms-xterm", never, { "data": { "alias": "data"; "required": false; "isSignal": true; }; "interactive": { "alias": "interactive"; "required": false; "isSignal": true; }; "queryResult": { "alias": "queryResult"; "required": false; "isSignal": true; }; "useInteractiveTheme": { "alias": "useInteractiveTheme"; "required": false; "isSignal": true; }; "totalWritten": { "alias": "totalWritten"; "required": false; "isSignal": true; }; "staticScreen": { "alias": "staticScreen"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
145
148
|
}
|
|
146
149
|
|
|
147
150
|
declare const DISPLAY_THEME: {
|
|
@@ -205,6 +208,8 @@ declare class XtermOrganism extends NgAtomicComponent implements AfterViewInit,
|
|
|
205
208
|
readonly fitScheduled: _angular_core.WritableSignal<number>;
|
|
206
209
|
private initSkippedDueToSize;
|
|
207
210
|
private readonly disposables;
|
|
211
|
+
private followBottom;
|
|
212
|
+
readonly scrollFromBottom: _angular_core.WritableSignal<number | null>;
|
|
208
213
|
private stableTimer;
|
|
209
214
|
private resizeTimer;
|
|
210
215
|
private fallbackTimer;
|
|
@@ -223,6 +228,8 @@ declare class XtermOrganism extends NgAtomicComponent implements AfterViewInit,
|
|
|
223
228
|
writeln(text: string): void;
|
|
224
229
|
clear(): void;
|
|
225
230
|
scrollToBottom(): void;
|
|
231
|
+
get followingBottom(): boolean;
|
|
232
|
+
restoreScroll(fromBottom: number): void;
|
|
226
233
|
scrollToTop(): void;
|
|
227
234
|
scrollLines(lines: number): void;
|
|
228
235
|
focus(): void;
|
|
@@ -239,7 +246,7 @@ declare class XtermOrganism extends NgAtomicComponent implements AfterViewInit,
|
|
|
239
246
|
}): void;
|
|
240
247
|
getImageAddon(): ImageAddon | undefined;
|
|
241
248
|
static ɵfac: _angular_core.ɵɵFactoryDeclaration<XtermOrganism, never>;
|
|
242
|
-
static ɵcmp: _angular_core.ɵɵComponentDeclaration<XtermOrganism, "organisms-xterm", never, {}, { "terminalReady": "terminalReady"; "githubLinkClick": "githubLinkClick"; }, never, never, true, [{ directive: typeof XtermOrganismStore; inputs: { "data": "data"; "interactive": "interactive"; "useInteractiveTheme": "useInteractiveTheme"; "totalWritten": "totalWritten"; }; outputs: {}; }]>;
|
|
249
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<XtermOrganism, "organisms-xterm", never, {}, { "terminalReady": "terminalReady"; "githubLinkClick": "githubLinkClick"; }, never, never, true, [{ directive: typeof XtermOrganismStore; inputs: { "data": "data"; "interactive": "interactive"; "useInteractiveTheme": "useInteractiveTheme"; "totalWritten": "totalWritten"; "staticScreen": "staticScreen"; }; outputs: {}; }]>;
|
|
243
250
|
}
|
|
244
251
|
|
|
245
252
|
interface GitHubLinkActivateHandler {
|
|
@@ -310,6 +317,32 @@ declare class ProxyLinksAddon implements ITerminalAddon {
|
|
|
310
317
|
dispose(): void;
|
|
311
318
|
}
|
|
312
319
|
|
|
320
|
+
interface PortLinkActivateHandler {
|
|
321
|
+
(event: MouseEvent, port: number): void;
|
|
322
|
+
}
|
|
323
|
+
interface PortToken {
|
|
324
|
+
port: number;
|
|
325
|
+
start: number;
|
|
326
|
+
end: number;
|
|
327
|
+
}
|
|
328
|
+
declare const PORTS_SECTION_TITLE = "PORTS";
|
|
329
|
+
declare function portTokensOf(text: string): PortToken[];
|
|
330
|
+
declare function isPortsSectionRow(textAt: (lineIndex: number) => string | undefined, lineIndex: number): boolean;
|
|
331
|
+
declare class PortLinkProvider implements ILinkProvider {
|
|
332
|
+
private readonly _terminal;
|
|
333
|
+
private readonly _handler;
|
|
334
|
+
constructor(_terminal: Terminal, _handler: PortLinkActivateHandler);
|
|
335
|
+
provideLinks(bufferLineNumber: number, callback: (links: ILink[] | undefined) => void): void;
|
|
336
|
+
}
|
|
337
|
+
|
|
338
|
+
declare class PortLinksAddon implements ITerminalAddon {
|
|
339
|
+
private readonly _handler;
|
|
340
|
+
private _linkProvider?;
|
|
341
|
+
constructor(_handler: PortLinkActivateHandler);
|
|
342
|
+
activate(terminal: Terminal): void;
|
|
343
|
+
dispose(): void;
|
|
344
|
+
}
|
|
345
|
+
|
|
313
346
|
declare const USER_CONTENT_DOMAIN = "10p.io";
|
|
314
347
|
declare function buildUserContentOrigin(serverUUID: string, portOrService: number | string, deployVersion?: string | null, domain?: string): string;
|
|
315
348
|
|
|
@@ -345,6 +378,15 @@ declare const CANONICAL_FONT_SIZE_PX = 14;
|
|
|
345
378
|
declare const CANONICAL_CELL_WIDTH_RATIO = 0.615;
|
|
346
379
|
declare const CANONICAL_CELL_HEIGHT_RATIO = 1.43;
|
|
347
380
|
declare const CANONICAL_LINE_HEIGHT = 1.2;
|
|
381
|
+
interface FontFaceSource {
|
|
382
|
+
family: string;
|
|
383
|
+
url: string;
|
|
384
|
+
}
|
|
385
|
+
declare const CANONICAL_FONT_FACES: readonly FontFaceSource[];
|
|
386
|
+
declare function probeCanonicalCellRect(): {
|
|
387
|
+
width: number;
|
|
388
|
+
height: number;
|
|
389
|
+
} | null;
|
|
348
390
|
declare function measureCellMetric(): {
|
|
349
391
|
cellWidth: number;
|
|
350
392
|
cellHeight: number;
|
|
@@ -361,6 +403,9 @@ declare function recordCanvasCellMetric(metric: {
|
|
|
361
403
|
cellHeight: number;
|
|
362
404
|
}): void;
|
|
363
405
|
declare function getCanvasCellMetric(fontSize?: number): CanvasCellMetric;
|
|
406
|
+
declare function primeCanvasCellMetric(measured: {
|
|
407
|
+
cellWidth: number;
|
|
408
|
+
}, fontSize?: number): CanvasCellMetric;
|
|
364
409
|
|
|
365
410
|
interface TerminalWriteState {
|
|
366
411
|
readonly lastData: string | null;
|
|
@@ -393,5 +438,30 @@ declare function applyScrollbackForFocus(terminal: ScrollbackFocusTarget, { isIn
|
|
|
393
438
|
focused: boolean;
|
|
394
439
|
}): void;
|
|
395
440
|
|
|
396
|
-
|
|
397
|
-
|
|
441
|
+
interface FollowBottomTerminal {
|
|
442
|
+
readonly buffer: {
|
|
443
|
+
readonly active: {
|
|
444
|
+
readonly viewportY: number;
|
|
445
|
+
readonly baseY: number;
|
|
446
|
+
};
|
|
447
|
+
};
|
|
448
|
+
onScroll(listener: (ydisp: number) => void): {
|
|
449
|
+
dispose(): void;
|
|
450
|
+
};
|
|
451
|
+
scrollToBottom(): void;
|
|
452
|
+
scrollLines(amount: number): void;
|
|
453
|
+
}
|
|
454
|
+
interface FollowBottomOptions {
|
|
455
|
+
onChange?: (fromBottom: number) => void;
|
|
456
|
+
now?: () => number;
|
|
457
|
+
}
|
|
458
|
+
interface FollowBottomHandle {
|
|
459
|
+
readonly following: boolean;
|
|
460
|
+
restore(fromBottom: number): void;
|
|
461
|
+
dispose(): void;
|
|
462
|
+
}
|
|
463
|
+
declare const FOLLOW_BOTTOM_GESTURE_WINDOW_MS = 500;
|
|
464
|
+
declare function attachFollowBottom(terminal: FollowBottomTerminal, root: HTMLElement, options?: FollowBottomOptions): FollowBottomHandle;
|
|
465
|
+
|
|
466
|
+
export { CANONICAL_CELL_HEIGHT_RATIO, CANONICAL_CELL_WIDTH_RATIO, CANONICAL_FONT_FACES, CANONICAL_FONT_FAMILY, CANONICAL_FONT_SIZE_PX, CANONICAL_LINE_HEIGHT, DISPLAY_THEME, FOLLOW_BOTTOM_GESTURE_WINDOW_MS, GitHubLinkProvider, GitHubLinksAddon, INTERACTIVE_THEME, MAX_VIEWPORT_COLS, MAX_VIEWPORT_ROWS, MIN_VIEWPORT_COLS, MIN_VIEWPORT_ROWS, PORTS_SECTION_TITLE, PortLinkProvider, PortLinksAddon, ProxyLinkProvider, ProxyLinksAddon, SessionMentionLinkProvider, SessionMentionLinksAddon, USER_CONTENT_DOMAIN, WebLinksAddon, XTERM_SESSION_CONTEXT, XtermActionId, XtermOrganism, XtermOrganismStore, appendUrlHandoff, applyScrollbackForFocus, asciiArtToSvg, attachFollowBottom, buildTerminalOptions, buildUserContentOrigin, clearCanvasCellMetricCache, computeFitToViewport, decideTerminalWrite, deployVersionToHostSuffix, encodeUrlHandoff, extractSessionMentions, generateAsciiArt, getCanvasCellMetric, getMachinaAsciiArtSixel, hasVisibleContent, isPortsSectionRow, measureCellMetric, openWebProxyForPort, portTokensOf, primeCanvasCellMetric, probeCanonicalCellRect, recordCanvasCellMetric, svgToSixel, toProxyUrl };
|
|
467
|
+
export type { DeployVersionGetter, EndpointsGetter, FitToViewportInput, FitToViewportResult, FollowBottomHandle, FollowBottomOptions, FollowBottomTerminal, FontFaceSource, GitHubLinkActivateHandler, OpenWebProxyOptions, PortLinkActivateHandler, PortToken, ProxyEndpoints, ProxyEnvGetter, ProxyEnvName, ScrollbackFocusTarget, ServerUUIDGetter, SessionMention, SessionMentionActivateHandler, SvgToSixelOptions, TerminalOptionsInput, TerminalWriteDecision, TerminalWriteState, TokenGetter, XtermSessionContext };
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import * as _angular_core from '@angular/core';
|
|
2
|
+
import * as _ng_atomic_core from '@ng-atomic/core';
|
|
3
|
+
import { NgAtomicComponent } from '@ng-atomic/core';
|
|
4
|
+
import { AuthService } from '@ng-atomic/common/services/auth';
|
|
5
|
+
import { SideNavModeService } from '@ng-atomic/common/services/side-nav-mode';
|
|
6
|
+
import * as i1 from '@ng-atomic/components/templates/menu';
|
|
7
|
+
import { MenuTemplateStore } from '@ng-atomic/components/templates/menu';
|
|
8
|
+
|
|
9
|
+
declare class MachinaMenuTemplate extends NgAtomicComponent {
|
|
10
|
+
protected readonly store: MenuTemplateStore;
|
|
11
|
+
protected readonly auth: AuthService;
|
|
12
|
+
protected readonly sideNav: SideNavModeService;
|
|
13
|
+
protected readonly signOutAction: _angular_core.Signal<_ng_atomic_core.Action<any> | null>;
|
|
14
|
+
protected readonly restBottomActions: _angular_core.Signal<_ng_atomic_core.Action<any>[]>;
|
|
15
|
+
static ɵfac: _angular_core.ɵɵFactoryDeclaration<MachinaMenuTemplate, never>;
|
|
16
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<MachinaMenuTemplate, "templates-menu", never, {}, {}, never, never, true, [{ directive: typeof i1.MenuTemplateStore; inputs: { "actions": "actions"; "bottomActions": "bottomActions"; "title": "title"; }; outputs: {}; }]>;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
export { MachinaMenuTemplate };
|