@kya-os/cli 1.0.0-beta.9 → 1.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (78) hide show
  1. package/README.md +7 -2
  2. package/dist/commands/init.d.ts +3 -0
  3. package/dist/commands/init.d.ts.map +1 -1
  4. package/dist/commands/init.js +60 -15
  5. package/dist/commands/init.js.map +1 -1
  6. package/dist/components/agent-card.js +2 -2
  7. package/dist/components/agent-card.js.map +1 -1
  8. package/dist/components/agent-table.js +19 -19
  9. package/dist/components/agent-table.js.map +1 -1
  10. package/dist/components/welcome.js +1 -1
  11. package/dist/effects/cli-integration.js +8 -8
  12. package/dist/effects/cli-integration.js.map +1 -1
  13. package/dist/effects/config.d.ts +10 -86
  14. package/dist/effects/config.d.ts.map +1 -1
  15. package/dist/effects/config.js +18 -201
  16. package/dist/effects/config.js.map +1 -1
  17. package/dist/index.js +1 -1
  18. package/dist/utils/platform-detector.js +3 -3
  19. package/dist/utils/platform-detector.js.map +1 -1
  20. package/dist/utils/screen-manager.js +5 -1
  21. package/dist/utils/screen-manager.js.map +1 -1
  22. package/dist/utils/validation.d.ts +9 -0
  23. package/dist/utils/validation.d.ts.map +1 -1
  24. package/dist/utils/validation.js +3 -0
  25. package/dist/utils/validation.js.map +1 -1
  26. package/package.json +4 -3
  27. package/dist/effects/animation-engine.d.ts +0 -173
  28. package/dist/effects/animation-engine.d.ts.map +0 -1
  29. package/dist/effects/animation-engine.js +0 -254
  30. package/dist/effects/animation-engine.js.map +0 -1
  31. package/dist/effects/effect-runner.d.ts +0 -69
  32. package/dist/effects/effect-runner.d.ts.map +0 -1
  33. package/dist/effects/effect-runner.js +0 -255
  34. package/dist/effects/effect-runner.js.map +0 -1
  35. package/dist/effects/gradient.d.ts +0 -131
  36. package/dist/effects/gradient.d.ts.map +0 -1
  37. package/dist/effects/gradient.js +0 -236
  38. package/dist/effects/gradient.js.map +0 -1
  39. package/dist/effects/implementations/beams.d.ts +0 -80
  40. package/dist/effects/implementations/beams.d.ts.map +0 -1
  41. package/dist/effects/implementations/beams.js +0 -221
  42. package/dist/effects/implementations/beams.js.map +0 -1
  43. package/dist/effects/implementations/blackhole.d.ts +0 -98
  44. package/dist/effects/implementations/blackhole.d.ts.map +0 -1
  45. package/dist/effects/implementations/blackhole.js +0 -421
  46. package/dist/effects/implementations/blackhole.js.map +0 -1
  47. package/dist/effects/implementations/burn.d.ts +0 -74
  48. package/dist/effects/implementations/burn.d.ts.map +0 -1
  49. package/dist/effects/implementations/burn.js +0 -234
  50. package/dist/effects/implementations/burn.js.map +0 -1
  51. package/dist/effects/implementations/decrypt.d.ts +0 -115
  52. package/dist/effects/implementations/decrypt.d.ts.map +0 -1
  53. package/dist/effects/implementations/decrypt.js +0 -394
  54. package/dist/effects/implementations/decrypt.js.map +0 -1
  55. package/dist/effects/implementations/waves.d.ts +0 -78
  56. package/dist/effects/implementations/waves.d.ts.map +0 -1
  57. package/dist/effects/implementations/waves.js +0 -278
  58. package/dist/effects/implementations/waves.js.map +0 -1
  59. package/dist/effects/index.d.ts +0 -34
  60. package/dist/effects/index.d.ts.map +0 -1
  61. package/dist/effects/index.js +0 -114
  62. package/dist/effects/index.js.map +0 -1
  63. package/dist/effects/motion-engine.d.ts +0 -168
  64. package/dist/effects/motion-engine.d.ts.map +0 -1
  65. package/dist/effects/motion-engine.js +0 -353
  66. package/dist/effects/motion-engine.js.map +0 -1
  67. package/dist/effects/safe-executor.d.ts +0 -55
  68. package/dist/effects/safe-executor.d.ts.map +0 -1
  69. package/dist/effects/safe-executor.js +0 -210
  70. package/dist/effects/safe-executor.js.map +0 -1
  71. package/dist/effects/types.d.ts +0 -199
  72. package/dist/effects/types.d.ts.map +0 -1
  73. package/dist/effects/types.js +0 -80
  74. package/dist/effects/types.js.map +0 -1
  75. package/dist/effects/utils.d.ts +0 -104
  76. package/dist/effects/utils.d.ts.map +0 -1
  77. package/dist/effects/utils.js +0 -280
  78. package/dist/effects/utils.js.map +0 -1
@@ -1,173 +0,0 @@
1
- /**
2
- * Scene-Based Animation Engine for Terminal Effects
3
- * Provides sophisticated animation capabilities with scenes, frames, and events
4
- */
5
- import { CharacterVisual, ColorPair, Color, EasingFunction } from "./types.js";
6
- import { Gradient, GradientDirection } from "./gradient.js";
7
- /**
8
- * Single frame in an animation scene
9
- */
10
- export interface AnimationFrame {
11
- /** Symbol to display */
12
- symbol: string;
13
- /** Frame duration in milliseconds */
14
- duration: number;
15
- /** Colors for this frame */
16
- colors?: ColorPair;
17
- /** Text effects (bold, italic, etc.) */
18
- textEffects?: string[];
19
- }
20
- /**
21
- * Sync metric for scene timing
22
- */
23
- export declare enum SyncMetric {
24
- /** Sync to time */
25
- TIME = "time",
26
- /** Sync to motion distance */
27
- DISTANCE = "distance",
28
- /** Sync to motion steps */
29
- STEP = "step"
30
- }
31
- /**
32
- * Animation scene - a sequence of frames
33
- */
34
- export declare class Scene {
35
- readonly id: string;
36
- private frames;
37
- private currentFrameIndex;
38
- private frameStartTime;
39
- private _isLooping;
40
- private _isComplete;
41
- /** Sync metric for timing */
42
- syncMetric: SyncMetric;
43
- /** Easing function for frame transitions */
44
- easingFn?: EasingFunction;
45
- constructor(id: string);
46
- /**
47
- * Add a frame to the scene
48
- */
49
- addFrame(symbol: string, duration: number, colors?: ColorPair): void;
50
- /**
51
- * Apply gradient to symbols across multiple frames
52
- */
53
- applyGradientToSymbols(symbol: string, duration: number, gradient: Gradient, _direction?: GradientDirection): void;
54
- /**
55
- * Set looping behavior
56
- */
57
- setLooping(isLooping: boolean): void;
58
- /**
59
- * Get current frame based on elapsed time
60
- */
61
- getCurrentFrame(elapsedTime: number): AnimationFrame | null;
62
- /**
63
- * Reset the scene
64
- */
65
- reset(): void;
66
- /**
67
- * Check if scene is complete
68
- */
69
- isComplete(): boolean;
70
- /**
71
- * Get total duration of the scene
72
- */
73
- getTotalDuration(): number;
74
- /**
75
- * Get frame count
76
- */
77
- getFrameCount(): number;
78
- /**
79
- * Get current frame index
80
- */
81
- getCurrentFrameIndex(): number;
82
- }
83
- /**
84
- * Event types for character animation
85
- */
86
- export declare enum AnimationEvent {
87
- SCENE_COMPLETE = "scene_complete",
88
- SCENE_ACTIVATED = "scene_activated",
89
- FRAME_CHANGE = "frame_change"
90
- }
91
- /**
92
- * Event handler for animation events
93
- */
94
- export interface AnimationEventHandler {
95
- event: AnimationEvent;
96
- sceneId?: string;
97
- callback: () => void;
98
- }
99
- /**
100
- * Character animation manager
101
- */
102
- export declare class CharacterAnimation {
103
- private scenes;
104
- private activeScene;
105
- private sceneStartTime;
106
- private eventHandlers;
107
- /** Original character colors */
108
- inputFgColor?: Color;
109
- inputBgColor?: Color;
110
- constructor(inputColors?: {
111
- fg?: Color;
112
- bg?: Color;
113
- });
114
- /**
115
- * Create a new scene
116
- */
117
- newScene(sceneId: string): Scene;
118
- /**
119
- * Get a scene by ID
120
- */
121
- queryScene(sceneId: string): Scene | undefined;
122
- /**
123
- * Activate a scene
124
- */
125
- activateScene(scene: Scene): void;
126
- /**
127
- * Update animation and get current visual
128
- */
129
- update(): CharacterVisual | null;
130
- /**
131
- * Register an event handler
132
- */
133
- registerEvent(event: AnimationEvent, sceneId: string, callback: () => void): void;
134
- /**
135
- * Trigger an event
136
- */
137
- private triggerEvent;
138
- /**
139
- * Reset all scenes
140
- */
141
- reset(): void;
142
- }
143
- /**
144
- * Enhanced character with animation capabilities
145
- */
146
- export declare class AnimatedCharacter {
147
- readonly id: string;
148
- readonly originalSymbol: string;
149
- readonly animation: CharacterAnimation;
150
- /** Current visual state */
151
- visual: CharacterVisual;
152
- /** Layer for z-ordering (higher = on top) */
153
- layer: number;
154
- /** Visibility flag */
155
- isVisible: boolean;
156
- constructor(id: string, symbol: string, inputColors?: {
157
- fg?: Color;
158
- bg?: Color;
159
- });
160
- /**
161
- * Update character animation
162
- */
163
- update(): void;
164
- /**
165
- * Set character layer
166
- */
167
- setLayer(layer: number): void;
168
- /**
169
- * Set visibility
170
- */
171
- setVisibility(isVisible: boolean): void;
172
- }
173
- //# sourceMappingURL=animation-engine.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"animation-engine.d.ts","sourceRoot":"","sources":["../../src/effects/animation-engine.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,eAAe,EAAE,SAAS,EAAE,KAAK,EAAE,cAAc,EAAE,MAAM,YAAY,CAAC;AAC/E,OAAO,EAAE,QAAQ,EAAE,iBAAiB,EAAE,MAAM,eAAe,CAAC;AAE5D;;GAEG;AACH,MAAM,WAAW,cAAc;IAC7B,wBAAwB;IACxB,MAAM,EAAE,MAAM,CAAC;IACf,qCAAqC;IACrC,QAAQ,EAAE,MAAM,CAAC;IACjB,4BAA4B;IAC5B,MAAM,CAAC,EAAE,SAAS,CAAC;IACnB,wCAAwC;IACxC,WAAW,CAAC,EAAE,MAAM,EAAE,CAAC;CACxB;AAED;;GAEG;AACH,oBAAY,UAAU;IACpB,mBAAmB;IACnB,IAAI,SAAS;IACb,8BAA8B;IAC9B,QAAQ,aAAa;IACrB,2BAA2B;IAC3B,IAAI,SAAS;CACd;AAED;;GAEG;AACH,qBAAa,KAAK;IAChB,QAAQ,CAAC,EAAE,EAAE,MAAM,CAAC;IACpB,OAAO,CAAC,MAAM,CAAwB;IAEtC,OAAO,CAAC,iBAAiB,CAAa;IAEtC,OAAO,CAAC,cAAc,CAAa;IACnC,OAAO,CAAC,UAAU,CAAkB;IACpC,OAAO,CAAC,WAAW,CAAkB;IAErC,6BAA6B;IAC7B,UAAU,EAAE,UAAU,CAAmB;IACzC,4CAA4C;IAC5C,QAAQ,CAAC,EAAE,cAAc,CAAC;gBAEd,EAAE,EAAE,MAAM;IAItB;;OAEG;IACH,QAAQ,CAAC,MAAM,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,EAAE,MAAM,CAAC,EAAE,SAAS,GAAG,IAAI;IAIpE;;OAEG;IACH,sBAAsB,CACpB,MAAM,EAAE,MAAM,EACd,QAAQ,EAAE,MAAM,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GAAG,IAAI;IAmBhC;;OAEG;IACH,aAAa,CAAC,KAAK,EAAE,cAAc,EAAE,OAAO,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,IAAI,GAAG,IAAI;IAIjF;;OAEG;IACH,OAAO,CAAC,YAAY;IAQpB;;OAEG;IACH,KAAK,IAAI,IAAI;CAKd;AAED;;GAEG;AACH,qBAAa,iBAAiB;IAC5B,QAAQ,CAAC,EAAE,EAAE,MAAM,CAAC;IACpB,QAAQ,CAAC,cAAc,EAAE,MAAM,CAAC;IAChC,QAAQ,CAAC,SAAS,EAAE,kBAAkB,CAAC;IAEvC,2BAA2B;IAC3B,MAAM,EAAE,eAAe,CAAC;IACxB,6CAA6C;IAC7C,KAAK,EAAE,MAAM,CAAK;IAClB,sBAAsB;IACtB,SAAS,EAAE,OAAO,CAAQ;gBAGxB,EAAE,EAAE,MAAM,EACV,MAAM,EAAE,MAAM,EACd,WAAW,CAAC,EAAE;QAAE,EAAE,CAAC,EAAE,KAAK,CAAC;QAAC,EAAE,CAAC,EAAE,KAAK,CAAA;KAAE;IAc1C;;OAEG;IACH,MAAM,IAAI,IAAI;IAOd;;OAEG;IACH,QAAQ,CAAC,KAAK,EAAE,MAAM,GAAG,IAAI;IAI7B;;OAEG;IACH,aAAa,CAAC,SAAS,EAAE,OAAO,GAAG,IAAI;CAGxC"}
@@ -1,254 +0,0 @@
1
- /**
2
- * Scene-Based Animation Engine for Terminal Effects
3
- * Provides sophisticated animation capabilities with scenes, frames, and events
4
- */
5
- /**
6
- * Sync metric for scene timing
7
- */
8
- export var SyncMetric;
9
- (function (SyncMetric) {
10
- /** Sync to time */
11
- SyncMetric["TIME"] = "time";
12
- /** Sync to motion distance */
13
- SyncMetric["DISTANCE"] = "distance";
14
- /** Sync to motion steps */
15
- SyncMetric["STEP"] = "step";
16
- })(SyncMetric || (SyncMetric = {}));
17
- /**
18
- * Animation scene - a sequence of frames
19
- */
20
- export class Scene {
21
- constructor(id) {
22
- this.frames = [];
23
- // @ts-ignore - Used internally
24
- this.currentFrameIndex = 0;
25
- // @ts-ignore - Used internally
26
- this.frameStartTime = 0;
27
- this._isLooping = false;
28
- this._isComplete = false;
29
- /** Sync metric for timing */
30
- this.syncMetric = SyncMetric.TIME;
31
- this.id = id;
32
- }
33
- /**
34
- * Add a frame to the scene
35
- */
36
- addFrame(symbol, duration, colors) {
37
- this.frames.push({ symbol, duration, colors });
38
- }
39
- /**
40
- * Apply gradient to symbols across multiple frames
41
- */
42
- applyGradientToSymbols(symbol, duration, gradient, _direction) {
43
- const spectrum = gradient.getSpectrum();
44
- const frameDuration = Math.floor(duration / spectrum.length);
45
- for (const color of spectrum) {
46
- this.addFrame(symbol, frameDuration, { fg: color, bg: null });
47
- }
48
- }
49
- /**
50
- * Set looping behavior
51
- */
52
- setLooping(isLooping) {
53
- this._isLooping = isLooping;
54
- }
55
- /**
56
- * Get current frame based on elapsed time
57
- */
58
- getCurrentFrame(elapsedTime) {
59
- if (this.frames.length === 0)
60
- return null;
61
- if (this._isComplete && !this._isLooping) {
62
- return this.frames[this.frames.length - 1];
63
- }
64
- let totalDuration = 0;
65
- let targetTime = elapsedTime;
66
- // Handle looping
67
- if (this._isLooping) {
68
- const sceneDuration = this.frames.reduce((sum, frame) => sum + frame.duration, 0);
69
- targetTime = elapsedTime % sceneDuration;
70
- }
71
- // Find the current frame
72
- for (let i = 0; i < this.frames.length; i++) {
73
- totalDuration += this.frames[i].duration;
74
- if (targetTime < totalDuration) {
75
- this.currentFrameIndex = i;
76
- return this.frames[i];
77
- }
78
- }
79
- // Scene complete
80
- this._isComplete = true;
81
- if (this._isLooping) {
82
- this.currentFrameIndex = 0;
83
- this._isComplete = false;
84
- return this.frames[0];
85
- }
86
- return this.frames[this.frames.length - 1];
87
- }
88
- /**
89
- * Reset the scene
90
- */
91
- reset() {
92
- this.currentFrameIndex = 0;
93
- this.frameStartTime = 0;
94
- this._isComplete = false;
95
- }
96
- /**
97
- * Check if scene is complete
98
- */
99
- isComplete() {
100
- return this._isComplete && !this._isLooping;
101
- }
102
- /**
103
- * Get total duration of the scene
104
- */
105
- getTotalDuration() {
106
- return this.frames.reduce((sum, frame) => sum + frame.duration, 0);
107
- }
108
- /**
109
- * Get frame count
110
- */
111
- getFrameCount() {
112
- return this.frames.length;
113
- }
114
- /**
115
- * Get current frame index
116
- */
117
- getCurrentFrameIndex() {
118
- return this.currentFrameIndex;
119
- }
120
- }
121
- /**
122
- * Event types for character animation
123
- */
124
- export var AnimationEvent;
125
- (function (AnimationEvent) {
126
- AnimationEvent["SCENE_COMPLETE"] = "scene_complete";
127
- AnimationEvent["SCENE_ACTIVATED"] = "scene_activated";
128
- AnimationEvent["FRAME_CHANGE"] = "frame_change";
129
- })(AnimationEvent || (AnimationEvent = {}));
130
- /**
131
- * Character animation manager
132
- */
133
- export class CharacterAnimation {
134
- constructor(inputColors) {
135
- this.scenes = new Map();
136
- this.activeScene = null;
137
- this.sceneStartTime = 0;
138
- this.eventHandlers = [];
139
- this.inputFgColor = inputColors?.fg;
140
- this.inputBgColor = inputColors?.bg;
141
- }
142
- /**
143
- * Create a new scene
144
- */
145
- newScene(sceneId) {
146
- const scene = new Scene(sceneId);
147
- this.scenes.set(sceneId, scene);
148
- return scene;
149
- }
150
- /**
151
- * Get a scene by ID
152
- */
153
- queryScene(sceneId) {
154
- return this.scenes.get(sceneId);
155
- }
156
- /**
157
- * Activate a scene
158
- */
159
- activateScene(scene) {
160
- if (this.activeScene && this.activeScene !== scene) {
161
- this.triggerEvent(AnimationEvent.SCENE_COMPLETE, this.activeScene.id);
162
- }
163
- this.activeScene = scene;
164
- this.sceneStartTime = Date.now();
165
- scene.reset();
166
- this.triggerEvent(AnimationEvent.SCENE_ACTIVATED, scene.id);
167
- }
168
- /**
169
- * Update animation and get current visual
170
- */
171
- update() {
172
- if (!this.activeScene)
173
- return null;
174
- const elapsedTime = Date.now() - this.sceneStartTime;
175
- const frame = this.activeScene.getCurrentFrame(elapsedTime);
176
- if (!frame)
177
- return null;
178
- // Check for scene completion
179
- if (this.activeScene.isComplete()) {
180
- this.triggerEvent(AnimationEvent.SCENE_COMPLETE, this.activeScene.id);
181
- }
182
- return {
183
- symbol: frame.symbol,
184
- colors: frame.colors || { fg: this.inputFgColor || null, bg: this.inputBgColor || null },
185
- };
186
- }
187
- /**
188
- * Register an event handler
189
- */
190
- registerEvent(event, sceneId, callback) {
191
- this.eventHandlers.push({ event, sceneId, callback });
192
- }
193
- /**
194
- * Trigger an event
195
- */
196
- triggerEvent(event, sceneId) {
197
- for (const handler of this.eventHandlers) {
198
- if (handler.event === event && handler.sceneId === sceneId) {
199
- handler.callback();
200
- }
201
- }
202
- }
203
- /**
204
- * Reset all scenes
205
- */
206
- reset() {
207
- this.scenes.forEach(scene => scene.reset());
208
- this.activeScene = null;
209
- this.sceneStartTime = 0;
210
- }
211
- }
212
- /**
213
- * Enhanced character with animation capabilities
214
- */
215
- export class AnimatedCharacter {
216
- constructor(id, symbol, inputColors) {
217
- /** Layer for z-ordering (higher = on top) */
218
- this.layer = 0;
219
- /** Visibility flag */
220
- this.isVisible = true;
221
- this.id = id;
222
- this.originalSymbol = symbol;
223
- this.animation = new CharacterAnimation(inputColors);
224
- this.visual = {
225
- symbol,
226
- colors: {
227
- fg: inputColors?.fg || null,
228
- bg: inputColors?.bg || null,
229
- },
230
- };
231
- }
232
- /**
233
- * Update character animation
234
- */
235
- update() {
236
- const newVisual = this.animation.update();
237
- if (newVisual) {
238
- this.visual = newVisual;
239
- }
240
- }
241
- /**
242
- * Set character layer
243
- */
244
- setLayer(layer) {
245
- this.layer = layer;
246
- }
247
- /**
248
- * Set visibility
249
- */
250
- setVisibility(isVisible) {
251
- this.isVisible = isVisible;
252
- }
253
- }
254
- //# sourceMappingURL=animation-engine.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"animation-engine.js","sourceRoot":"","sources":["../../src/effects/animation-engine.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAmBH;;GAEG;AACH,MAAM,CAAN,IAAY,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;YACN,MAAM,EAAE;gBACN,EAAE,EAAE,WAAW,EAAE,EAAE,IAAI,IAAI;gBAC3B,EAAE,EAAE,WAAW,EAAE,EAAE,IAAI,IAAI;aAC5B;SACF,CAAC;IACJ,CAAC;IAED;;OAEG;IACH,MAAM;QACJ,MAAM,SAAS,GAAG,IAAI,CAAC,SAAS,CAAC,MAAM,EAAE,CAAC;QAC1C,IAAI,SAAS,EAAE,CAAC;YACd,IAAI,CAAC,MAAM,GAAG,SAAS,CAAC;QAC1B,CAAC;IACH,CAAC;IAED;;OAEG;IACH,QAAQ,CAAC,KAAa;QACpB,IAAI,CAAC,KAAK,GAAG,KAAK,CAAC;IACrB,CAAC;IAED;;OAEG;IACH,aAAa,CAAC,SAAkB;QAC9B,IAAI,CAAC,SAAS,GAAG,SAAS,CAAC;IAC7B,CAAC;CACF"}
@@ -1,69 +0,0 @@
1
- /**
2
- * Effect Runner
3
- * Orchestrates terminal effects with proper management
4
- */
5
- import { Effect, EffectConfig } from "./types.js";
6
- /**
7
- * Options for running an effect
8
- */
9
- export interface RunEffectOptions {
10
- /** Effect instance to run */
11
- effect: Effect;
12
- /** Text to animate */
13
- text: string;
14
- /** Effect-specific configuration */
15
- config?: Partial<EffectConfig>;
16
- /** Callback when effect completes */
17
- onComplete?: () => void;
18
- /** Callback on error */
19
- onError?: (error: Error) => void;
20
- /** Custom output stream */
21
- outputStream?: NodeJS.WriteStream;
22
- /** Skip the "Press any key to exit" prompt */
23
- skipExitPrompt?: boolean;
24
- /** Keep text visible after effect (no alternate screen buffer) */
25
- persistent?: boolean;
26
- }
27
- /**
28
- * Effect runner for executing terminal effects
29
- */
30
- export declare class EffectRunner {
31
- private terminalState;
32
- private isRunning;
33
- private currentEffect;
34
- private animationHandle;
35
- constructor();
36
- /**
37
- * Run an effect
38
- */
39
- run(options: RunEffectOptions): Promise<void>;
40
- /**
41
- * Stop the currently running effect
42
- */
43
- stop(): Promise<void>;
44
- /**
45
- * Check if terminal supports effects
46
- */
47
- private supportsEffects;
48
- /**
49
- * Setup terminal for effect rendering
50
- */
51
- private setupTerminal;
52
- /**
53
- * Run the animation loop
54
- */
55
- private runAnimation;
56
- /**
57
- * Clean up terminal state
58
- */
59
- private cleanup;
60
- /**
61
- * Check if an effect is currently running
62
- */
63
- isEffectRunning(): boolean;
64
- /**
65
- * Get current effect info
66
- */
67
- getCurrentEffect(): Effect | null;
68
- }
69
- //# sourceMappingURL=effect-runner.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"effect-runner.d.ts","sourceRoot":"","sources":["../../src/effects/effect-runner.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,MAAM,EAAE,YAAY,EAAsB,MAAM,YAAY,CAAC;AAMtE;;GAEG;AACH,MAAM,WAAW,gBAAgB;IAC/B,6BAA6B;IAC7B,MAAM,EAAE,MAAM,CAAC;IACf,sBAAsB;IACtB,IAAI,EAAE,MAAM,CAAC;IACb,oCAAoC;IACpC,MAAM,CAAC,EAAE,OAAO,CAAC,YAAY,CAAC,CAAC;IAC/B,qCAAqC;IACrC,UAAU,CAAC,EAAE,MAAM,IAAI,CAAC;IACxB,wBAAwB;IACxB,OAAO,CAAC,EAAE,CAAC,KAAK,EAAE,KAAK,KAAK,IAAI,CAAC;IACjC,2BAA2B;IAC3B,YAAY,CAAC,EAAE,MAAM,CAAC,WAAW,CAAC;IAClC,8CAA8C;IAC9C,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB,kEAAkE;IAClE,UAAU,CAAC,EAAE,OAAO,CAAC;CACtB;AAWD;;GAEG;AACH,qBAAa,YAAY;IACvB,OAAO,CAAC,aAAa,CAAgB;IACrC,OAAO,CAAC,SAAS,CAAkB;IACnC,OAAO,CAAC,aAAa,CAAuB;IAC5C,OAAO,CAAC,eAAe,CAA+B;;IAUtD;;OAEG;IACG,GAAG,CAAC,OAAO,EAAE,gBAAgB,GAAG,OAAO,CAAC,IAAI,CAAC;IAmEnD;;OAEG;IACG,IAAI,IAAI,OAAO,CAAC,IAAI,CAAC;IAmB3B;;OAEG;IACH,OAAO,CAAC,eAAe;IASvB;;OAEG;YACW,aAAa;IA2D3B;;OAEG;YACW,YAAY;IA+D1B;;OAEG;YACW,OAAO;IAmCrB;;OAEG;IACH,eAAe,IAAI,OAAO;IAI1B;;OAEG;IACH,gBAAgB,IAAI,MAAM,GAAG,IAAI;CAGlC"}