@simon_he/vue-tui 0.0.7 → 1.0.0-rc.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/README.md +222 -444
- package/dist/TSelect-BmSkar0D.js +8697 -0
- package/dist/ansi-palette-Bv5Vqr4k.js +1499 -0
- package/dist/ansi-styles.d.ts +200 -0
- package/dist/cli/headless-renderer.d.ts +29 -0
- package/dist/cli/input.d.ts +49 -0
- package/dist/cli/node-file-writers.d.ts +12 -0
- package/dist/cli/node-module.d.ts +2 -0
- package/dist/cli/parse-kitty.d.ts +2 -0
- package/dist/cli/parse-mouse.d.ts +2 -0
- package/dist/cli/parse-utils.d.ts +14 -0
- package/dist/cli/parse-xterm.d.ts +2 -0
- package/dist/cli/path-provider-types.d.ts +1 -0
- package/dist/cli/path-provider.d.ts +4 -0
- package/dist/cli/path-suggest-core.d.ts +1 -0
- package/dist/cli/path-suggest.d.ts +15 -0
- package/dist/cli/recording.d.ts +4 -0
- package/dist/cli/stdin-buffer.d.ts +33 -0
- package/dist/cli.cjs +10664 -0
- package/dist/cli.d.cts +22 -0
- package/dist/cli.d.ts +22 -0
- package/dist/cli.js +9521 -0
- package/dist/core/ansi/capability.d.ts +20 -0
- package/dist/core/ansi/colors.d.ts +41 -0
- package/dist/core/ansi/sgr.d.ts +7 -0
- package/dist/core/ansi/theme.d.ts +6 -0
- package/dist/core/ansi-palette.d.ts +14 -0
- package/dist/core/buffer/buffer.d.ts +54 -0
- package/dist/core/buffer/width.d.ts +4 -0
- package/dist/core/debug-logger.d.ts +18 -0
- package/dist/core/hyperlink.d.ts +9 -0
- package/dist/core/index.d.ts +4 -0
- package/dist/core/path-provider-types.d.ts +24 -0
- package/dist/core/path-suggest.d.ts +35 -0
- package/dist/core/render-plane.d.ts +3 -0
- package/dist/core/terminal/create-terminal.d.ts +7 -0
- package/dist/core/terminal/emitter.d.ts +7 -0
- package/dist/core/types.d.ts +107 -0
- package/dist/core.cjs +3072 -0
- package/dist/core.d.cts +14 -0
- package/dist/core.d.ts +14 -0
- package/dist/core.js +422 -0
- package/dist/create-terminal-app.d.ts +34 -0
- package/dist/dom-renderer-CDVQIcIL.js +1172 -0
- package/dist/events/index.d.ts +6 -0
- package/dist/events/manager/cli-event-manager.d.ts +22 -0
- package/dist/events/manager/event-manager.d.ts +30 -0
- package/dist/events/manager/selection-suppression.d.ts +3 -0
- package/dist/events/manager/types.d.ts +108 -0
- package/dist/events/recording.d.ts +44 -0
- package/dist/experimental.cjs +9380 -0
- package/dist/experimental.d.cts +39 -0
- package/dist/experimental.d.ts +39 -0
- package/dist/experimental.js +7624 -0
- package/dist/frame-perf-C-w8mjJL.js +98 -0
- package/dist/hyperlink-B5PD7a3Q.js +331 -0
- package/dist/index.cjs +12037 -16507
- package/dist/index.d.cts +13 -0
- package/dist/index.d.ts +13 -1353
- package/dist/index.js +13 -18738
- package/dist/markdown.cjs +21929 -0
- package/dist/markdown.d.cts +10 -0
- package/dist/markdown.d.ts +10 -0
- package/dist/markdown.js +1649 -0
- package/dist/observability/cli-latency-node.d.ts +3 -0
- package/dist/observability/cli-latency-types.d.ts +41 -0
- package/dist/observability/cli-latency.d.ts +3 -0
- package/dist/observability/frame-perf-store.d.ts +13 -0
- package/dist/observability/frame-perf.d.ts +40 -0
- package/dist/observability/trace.d.ts +40 -0
- package/dist/observability/tui-profiler.d.ts +33 -0
- package/dist/observability.cjs +99 -0
- package/dist/observability.d.cts +6 -0
- package/dist/observability.d.ts +6 -0
- package/dist/observability.js +3 -0
- package/dist/path-DDiSCXrQ.js +99 -0
- package/dist/path-suggest-0Q2BDsuj.js +274 -0
- package/dist/path-suggest-Dk9TRLh5.js +3 -0
- package/dist/{path-suggest-CZQYJIIg.js → path-suggest-bvR9SY6Q.js} +86 -18
- package/dist/renderer/capabilities.d.ts +13 -0
- package/dist/renderer/cli/index.d.ts +2 -0
- package/dist/renderer/cli/stdout-metrics.d.ts +18 -0
- package/dist/renderer/cli/stdout-renderer.d.ts +48 -0
- package/dist/renderer/dom/dom-renderer.d.ts +157 -0
- package/dist/renderer/dom/index.d.ts +2 -0
- package/dist/renderer/index.d.ts +2 -0
- package/dist/renderer-dom.cjs +1511 -0
- package/dist/renderer-dom.d.cts +4 -0
- package/dist/renderer-dom.d.ts +4 -0
- package/dist/renderer-dom.js +6 -0
- package/dist/runtime/index.d.ts +36 -0
- package/dist/runtime/osc52.d.ts +9 -0
- package/dist/runtime-DtrcQidD.js +1197 -0
- package/dist/runtime.cjs +1697 -0
- package/dist/runtime.d.cts +9 -0
- package/dist/runtime.d.ts +9 -0
- package/dist/runtime.js +4 -0
- package/dist/selection/terminal-selection.d.ts +122 -0
- package/dist/sgr-DMK2AvuT.js +304 -0
- package/dist/style-cache-i0ZABZRq.js +178 -0
- package/dist/terminal-selection-BCOh9jsL.js +329 -0
- package/dist/utils/env.d.ts +3 -0
- package/dist/utils/newlines.d.ts +1 -0
- package/dist/utils/path.d.ts +7 -0
- package/dist/utils/url-safety.d.ts +2 -0
- package/dist/vue/components/TAnchor.d.ts +108 -0
- package/dist/vue/components/TBox.d.ts +144 -0
- package/dist/vue/components/TDebugOverlay.d.ts +43 -0
- package/dist/vue/components/TDialog.d.ts +256 -0
- package/dist/vue/components/TFlow.d.ts +85 -0
- package/dist/vue/components/TInput.d.ts +554 -0
- package/dist/vue/components/TInputBox.d.ts +158 -0
- package/dist/vue/components/TJsonEditor.d.ts +165 -0
- package/dist/vue/components/TList.d.ts +119 -0
- package/dist/vue/components/TLogLinksPanel.d.ts +238 -0
- package/dist/vue/components/TLogMinimap.d.ts +263 -0
- package/dist/vue/components/TLogScrollbar.d.ts +236 -0
- package/dist/vue/components/TLogSearchBar.d.ts +267 -0
- package/dist/vue/components/TLogSearchPager.d.ts +162 -0
- package/dist/vue/components/TLogSearchResults.d.ts +200 -0
- package/dist/vue/components/TLogView.d.ts +502 -0
- package/dist/vue/components/TLogVirtualLinksPanel.d.ts +141 -0
- package/dist/vue/components/TLogVirtualSearchResults.d.ts +146 -0
- package/dist/vue/components/TMarkdownText.d.ts +134 -0
- package/dist/vue/components/TMultilineModal.d.ts +62 -0
- package/dist/vue/components/TPathPicker.d.ts +213 -0
- package/dist/vue/components/TRenderLayer.d.ts +16 -0
- package/dist/vue/components/TRenderPlane.d.ts +17 -0
- package/dist/vue/components/TSelect.d.ts +215 -0
- package/dist/vue/components/TText.d.ts +116 -0
- package/dist/vue/components/TTransition.d.ts +83 -0
- package/dist/vue/components/TView.d.ts +127 -0
- package/dist/vue/components/TVirtualList.d.ts +182 -0
- package/dist/vue/components/TVirtualMarkdown.d.ts +168 -0
- package/dist/vue/components/TerminalProvider.d.ts +195 -0
- package/dist/vue/components/input/host.d.ts +17 -0
- package/dist/vue/components/input/plugins/hostPlugin.d.ts +7 -0
- package/dist/vue/components/input/plugins/hostPlugin.node.d.ts +15 -0
- package/dist/vue/components/input/plugins/mentionUtils.d.ts +17 -0
- package/dist/vue/components/input/plugins/nodeMentionPathProvider.d.ts +2 -0
- package/dist/vue/components/input/plugins/promptMentionPlugin.d.ts +8 -0
- package/dist/vue/components/input/plugins/promptMentionState.d.ts +98 -0
- package/dist/vue/components/input/plugins/restrictText.d.ts +27 -0
- package/dist/vue/components/input/plugins/types.d.ts +90 -0
- package/dist/vue/components/input/utils/inlineText.d.ts +57 -0
- package/dist/vue/components/input/utils/inlineTextTokens.d.ts +34 -0
- package/dist/vue/components/input/utils/primitives.d.ts +3 -0
- package/dist/vue/components/input/utils/wordNavigation.d.ts +6 -0
- package/dist/vue/components/list/list-geometry.d.ts +16 -0
- package/dist/vue/components/list/list-paint.d.ts +1 -0
- package/dist/vue/components/list/scroll-state.d.ts +25 -0
- package/dist/vue/components/list/selection-state.d.ts +6 -0
- package/dist/vue/components/terminal-provider/copy-toast.d.ts +6 -0
- package/dist/vue/components/terminal-provider/portals.d.ts +17 -0
- package/dist/vue/components/terminal-provider/scheduler.d.ts +29 -0
- package/dist/vue/components/terminal-provider/selection-config.d.ts +15 -0
- package/dist/vue/components/terminal-provider/utils.d.ts +5 -0
- package/dist/vue/composables/use-layout.d.ts +2 -0
- package/dist/vue/composables/use-render-node.d.ts +19 -0
- package/dist/vue/composables/use-render-stack.d.ts +3 -0
- package/dist/vue/composables/use-runtime.d.ts +5 -0
- package/dist/vue/composables/use-terminal-node.d.ts +14 -0
- package/dist/vue/composables/use-terminal.d.ts +2 -0
- package/dist/vue/composables/use-visibility.d.ts +12 -0
- package/dist/vue/context.d.ts +153 -0
- package/dist/vue/index.d.ts +39 -0
- package/dist/vue/injection-key.d.ts +2 -0
- package/dist/vue/log/append-only-log-store.d.ts +2 -0
- package/dist/vue/log/tlog-keymap.d.ts +28 -0
- package/dist/vue/log/tlog-plugins.d.ts +144 -0
- package/dist/vue/log/tlog-session.d.ts +81 -0
- package/dist/vue/log/tlog-theme.d.ts +68 -0
- package/dist/vue/log/types.d.ts +43 -0
- package/dist/vue/log/use-tlog-link-controller.d.ts +31 -0
- package/dist/vue/log/use-tlog-retained-index.d.ts +26 -0
- package/dist/vue/log/use-tlog-search-controller.d.ts +51 -0
- package/dist/vue/log/use-tlog-search-results-page.d.ts +31 -0
- package/dist/vue/log/use-tlog-virtual-search-results.d.ts +22 -0
- package/dist/vue/markdown/ast.d.ts +3 -0
- package/dist/vue/markdown/block-source.d.ts +22 -0
- package/dist/vue/markdown/document.d.ts +18 -0
- package/dist/vue/markdown/layout.d.ts +16 -0
- package/dist/vue/markdown/parser.d.ts +11 -0
- package/dist/vue/markdown/render.d.ts +10 -0
- package/dist/vue/markdown/theme.d.ts +186 -0
- package/dist/vue/markdown/types.d.ts +47 -0
- package/dist/vue/render/context.d.ts +3 -0
- package/dist/vue/render/render-manager.d.ts +94 -0
- package/dist/vue/router/RouterView.d.ts +25 -0
- package/dist/vue/router/composables.d.ts +4 -0
- package/dist/vue/router/context.d.ts +4 -0
- package/dist/vue/router/router.d.ts +7 -0
- package/dist/vue/router/types.d.ts +29 -0
- package/dist/vue/scheduler/frame-mailbox.d.ts +55 -0
- package/dist/vue/scheduler/frame-scheduler.d.ts +51 -0
- package/dist/vue/utils/frame-task.d.ts +6 -0
- package/dist/vue/utils/rect.d.ts +4 -0
- package/dist/vue/utils/style-cache.d.ts +3 -0
- package/dist/vue/utils/text.d.ts +26 -0
- package/dist/vue/utils/wheel-scroll.d.ts +18 -0
- package/dist/vue.cjs +18882 -0
- package/dist/vue.d.cts +3 -0
- package/dist/vue.d.ts +3 -0
- package/dist/vue.js +3066 -0
- package/dist/wheel-scroll-B-WlFuNB.js +819 -0
- package/package.json +226 -58
- package/dist/path-suggest-DIMby3r0.js +0 -3
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import type { FramePerfReason } from "../../observability/frame-perf.js";
|
|
2
|
+
import type { TerminalFrameTask, TerminalSchedulerConfig, TerminalSchedulerInvalidateOptions } from "../context.js";
|
|
3
|
+
export type SchedulerFrameMailboxDeliveryAttempt = Readonly<{
|
|
4
|
+
id: string;
|
|
5
|
+
queued: number;
|
|
6
|
+
dropped: number;
|
|
7
|
+
}>;
|
|
8
|
+
export type SchedulerFrameTaskRunStats = Readonly<{
|
|
9
|
+
frameTaskCount: number;
|
|
10
|
+
/**
|
|
11
|
+
* Number of scheduler-level tasks merged by task id before execution.
|
|
12
|
+
*/
|
|
13
|
+
coalescedFrameTasks: number;
|
|
14
|
+
frameTaskQueueDepthBeforeRun: number;
|
|
15
|
+
frameTaskQueueDepthAfterRun: number;
|
|
16
|
+
remainingFrameTasks: number;
|
|
17
|
+
/**
|
|
18
|
+
* Number of producer-level values that were not applied individually.
|
|
19
|
+
* For latest-only mailboxes these are dropped intermediate states.
|
|
20
|
+
* For merge mailboxes they may be folded into the applied payload.
|
|
21
|
+
*/
|
|
22
|
+
droppedUpdates: number;
|
|
23
|
+
reason: FramePerfReason;
|
|
24
|
+
sync: boolean;
|
|
25
|
+
requestMore: boolean;
|
|
26
|
+
error?: unknown;
|
|
27
|
+
mailboxFailure?: SchedulerFrameMailboxDeliveryAttempt;
|
|
28
|
+
}>;
|
|
29
|
+
export declare const EMPTY_FRAME_TASK_RUN_STATS: SchedulerFrameTaskRunStats;
|
|
30
|
+
type SchedulerFrameTasksOptions = Readonly<{
|
|
31
|
+
isActive: () => boolean;
|
|
32
|
+
invalidate: (options?: TerminalSchedulerInvalidateOptions) => void;
|
|
33
|
+
flushFrame: (stats: SchedulerFrameTaskRunStats) => void;
|
|
34
|
+
}>;
|
|
35
|
+
export declare function createSchedulerFrameTasks(options: SchedulerFrameTasksOptions): {
|
|
36
|
+
readonly configure: (config: TerminalSchedulerConfig) => void;
|
|
37
|
+
readonly queueFrameTask: (task: TerminalFrameTask) => boolean;
|
|
38
|
+
readonly cancelFrameTask: (id: string) => boolean;
|
|
39
|
+
readonly requestLive: (reason: string) => () => void;
|
|
40
|
+
readonly dropLive: (reason: string) => void;
|
|
41
|
+
readonly isInsideFrame: () => boolean;
|
|
42
|
+
readonly cancelScheduledFrame: () => void;
|
|
43
|
+
readonly runPendingFrameTasks: (optionsForRun?: Readonly<{
|
|
44
|
+
force?: boolean;
|
|
45
|
+
}>) => SchedulerFrameTaskRunStats;
|
|
46
|
+
readonly scheduleIfNeeded: (requestMore?: boolean) => void;
|
|
47
|
+
readonly remainingFrameTasks: () => number;
|
|
48
|
+
readonly liveReasonList: () => string[];
|
|
49
|
+
readonly queueDepth: () => 1 | 0;
|
|
50
|
+
};
|
|
51
|
+
export {};
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import type { Rect } from "../../events/manager/types.js";
|
|
2
|
+
export declare function intersectRect(a: Rect, b: Rect): Rect | null;
|
|
3
|
+
export declare function translateRect(rect: Rect, dx: number, dy: number): Rect;
|
|
4
|
+
export declare function normalizeCellRect(rect: Rect): Rect;
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { type WidthProvider } from "../../core/buffer/width.js";
|
|
2
|
+
export interface TextCellSegment {
|
|
3
|
+
text: string;
|
|
4
|
+
cells: number;
|
|
5
|
+
start: number;
|
|
6
|
+
end: number;
|
|
7
|
+
}
|
|
8
|
+
export declare function hasTextWidthAsciiFastPath(): boolean;
|
|
9
|
+
export declare function withTextWidthProvider<T>(provider: WidthProvider | undefined, fn: () => T): T;
|
|
10
|
+
export declare function withTextRenderPass<T>(fn: () => T, provider?: WidthProvider): T;
|
|
11
|
+
export declare function forEachTextCellSegment(text: string, cb: (segment: TextCellSegment) => void | false, provider?: WidthProvider): void;
|
|
12
|
+
export declare function graphemeRangeAt(text: string, index: number): {
|
|
13
|
+
start: number;
|
|
14
|
+
end: number;
|
|
15
|
+
} | null;
|
|
16
|
+
export declare function sanitizeInlineText(text: string): string;
|
|
17
|
+
export declare function sanitizeTextBlock(text: string): string;
|
|
18
|
+
export declare function textCellWidth(text: string, provider?: WidthProvider): number;
|
|
19
|
+
export declare function spaces(count: number): string;
|
|
20
|
+
export declare function repeatChar(ch: string, count: number): string;
|
|
21
|
+
export declare function sliceByCells(text: string, maxCells: number, provider?: WidthProvider): string;
|
|
22
|
+
export declare function sliceByCellsRange(text: string, startCells: number, endCells: number, provider?: WidthProvider): string;
|
|
23
|
+
export declare function padEndByCells(text: string, width: number, provider?: WidthProvider): string;
|
|
24
|
+
export declare function formatInlineCellLine(text: string, width: number, provider?: WidthProvider): string;
|
|
25
|
+
export declare function clearTextCaches(): void;
|
|
26
|
+
export declare function wrapByCells(text: string, width: number, provider?: WidthProvider): readonly string[];
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
export interface WheelScrollState {
|
|
2
|
+
accumulator: number;
|
|
3
|
+
lastAt: number;
|
|
4
|
+
lastEdgeDir: number;
|
|
5
|
+
lastEdgeAt: number;
|
|
6
|
+
}
|
|
7
|
+
export interface WheelScrollResult {
|
|
8
|
+
nextTop: number;
|
|
9
|
+
dir: -1 | 0 | 1;
|
|
10
|
+
lines: number;
|
|
11
|
+
}
|
|
12
|
+
export type WheelDeltaMode = "auto" | "line" | "pixel";
|
|
13
|
+
export interface WheelScrollOptions {
|
|
14
|
+
disableAcceleration?: boolean;
|
|
15
|
+
}
|
|
16
|
+
export declare function createWheelScrollState(): WheelScrollState;
|
|
17
|
+
export declare function resetWheelScrollState(state: WheelScrollState): void;
|
|
18
|
+
export declare function applyWheelScroll(state: WheelScrollState, deltaY: number, scrollTop: number, maxTop: number, now?: number, deltaMode?: WheelDeltaMode, options?: WheelScrollOptions): WheelScrollResult;
|