windcode 0.1.0__py3-none-any.whl

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 (143) hide show
  1. windcode/__init__.py +6 -0
  2. windcode/__main__.py +4 -0
  3. windcode/auth/__init__.py +11 -0
  4. windcode/auth/store.py +90 -0
  5. windcode/cli.py +181 -0
  6. windcode/config/__init__.py +41 -0
  7. windcode/config/loader.py +117 -0
  8. windcode/config/models.py +203 -0
  9. windcode/config/writer.py +74 -0
  10. windcode/context/__init__.py +18 -0
  11. windcode/context/compactor.py +72 -0
  12. windcode/context/estimator.py +89 -0
  13. windcode/context/truncation.py +87 -0
  14. windcode/domain/__init__.py +1 -0
  15. windcode/domain/errors.py +33 -0
  16. windcode/domain/events.py +597 -0
  17. windcode/domain/messages.py +226 -0
  18. windcode/domain/models.py +73 -0
  19. windcode/domain/subagents.py +263 -0
  20. windcode/domain/tools.py +55 -0
  21. windcode/extensions/__init__.py +27 -0
  22. windcode/extensions/commands.py +25 -0
  23. windcode/extensions/discovery.py +139 -0
  24. windcode/extensions/events.py +58 -0
  25. windcode/extensions/hooks/__init__.py +4 -0
  26. windcode/extensions/hooks/dispatcher.py +107 -0
  27. windcode/extensions/hooks/executor.py +49 -0
  28. windcode/extensions/hooks/loader.py +101 -0
  29. windcode/extensions/hooks/models.py +109 -0
  30. windcode/extensions/mcp/__init__.py +10 -0
  31. windcode/extensions/mcp/adapter.py +101 -0
  32. windcode/extensions/mcp/catalog.py +153 -0
  33. windcode/extensions/mcp/client.py +273 -0
  34. windcode/extensions/mcp/runtime.py +144 -0
  35. windcode/extensions/mcp/tools.py +570 -0
  36. windcode/extensions/models.py +168 -0
  37. windcode/extensions/paths.py +71 -0
  38. windcode/extensions/plugins/__init__.py +3 -0
  39. windcode/extensions/plugins/installer.py +93 -0
  40. windcode/extensions/plugins/manifest.py +166 -0
  41. windcode/extensions/runtime.py +366 -0
  42. windcode/extensions/service.py +437 -0
  43. windcode/extensions/skills/__init__.py +3 -0
  44. windcode/extensions/skills/loader.py +67 -0
  45. windcode/extensions/skills/parser.py +57 -0
  46. windcode/extensions/skills/tools.py +213 -0
  47. windcode/extensions/snapshot.py +57 -0
  48. windcode/extensions/state.py +158 -0
  49. windcode/instructions/__init__.py +8 -0
  50. windcode/instructions/loader.py +50 -0
  51. windcode/memory/__init__.py +57 -0
  52. windcode/memory/extraction.py +83 -0
  53. windcode/memory/models.py +218 -0
  54. windcode/memory/refiner.py +189 -0
  55. windcode/memory/security.py +23 -0
  56. windcode/memory/service.py +179 -0
  57. windcode/memory/store.py +362 -0
  58. windcode/observability/__init__.py +4 -0
  59. windcode/observability/redaction.py +95 -0
  60. windcode/observability/trace.py +115 -0
  61. windcode/policy/__init__.py +22 -0
  62. windcode/policy/engine.py +137 -0
  63. windcode/policy/models.py +69 -0
  64. windcode/providers/__init__.py +29 -0
  65. windcode/providers/_utils.py +19 -0
  66. windcode/providers/anthropic.py +215 -0
  67. windcode/providers/base.py +46 -0
  68. windcode/providers/catalog.py +119 -0
  69. windcode/providers/errors.py +96 -0
  70. windcode/providers/openai_compat.py +231 -0
  71. windcode/providers/openai_responses.py +189 -0
  72. windcode/providers/registry.py +105 -0
  73. windcode/runtime/__init__.py +15 -0
  74. windcode/runtime/control.py +89 -0
  75. windcode/runtime/event_bus.py +67 -0
  76. windcode/runtime/loop.py +510 -0
  77. windcode/runtime/prompts.py +132 -0
  78. windcode/runtime/report.py +64 -0
  79. windcode/runtime/retry.py +73 -0
  80. windcode/runtime/scheduler.py +194 -0
  81. windcode/runtime/subagents/__init__.py +28 -0
  82. windcode/runtime/subagents/approvals.py +88 -0
  83. windcode/runtime/subagents/budgets.py +79 -0
  84. windcode/runtime/subagents/coordinator.py +714 -0
  85. windcode/runtime/subagents/factory.py +311 -0
  86. windcode/runtime/subagents/roles.py +74 -0
  87. windcode/runtime/subagents/verification.py +53 -0
  88. windcode/sandbox/__init__.py +3 -0
  89. windcode/sandbox/bwrap.py +79 -0
  90. windcode/sdk.py +1259 -0
  91. windcode/sessions/__init__.py +23 -0
  92. windcode/sessions/artifacts.py +69 -0
  93. windcode/sessions/models.py +104 -0
  94. windcode/sessions/store.py +167 -0
  95. windcode/sessions/tree.py +35 -0
  96. windcode/tools/__init__.py +10 -0
  97. windcode/tools/apply_patch.py +191 -0
  98. windcode/tools/ask_user.py +58 -0
  99. windcode/tools/builtins.py +44 -0
  100. windcode/tools/edit_file.py +54 -0
  101. windcode/tools/filesystem.py +77 -0
  102. windcode/tools/glob.py +35 -0
  103. windcode/tools/grep.py +66 -0
  104. windcode/tools/memory.py +400 -0
  105. windcode/tools/read_file.py +54 -0
  106. windcode/tools/registry.py +120 -0
  107. windcode/tools/shell.py +159 -0
  108. windcode/tools/subagents/__init__.py +31 -0
  109. windcode/tools/subagents/cancel.py +35 -0
  110. windcode/tools/subagents/integrate.py +54 -0
  111. windcode/tools/subagents/list.py +46 -0
  112. windcode/tools/subagents/spawn.py +86 -0
  113. windcode/tools/subagents/wait.py +74 -0
  114. windcode/tools/write_file.py +61 -0
  115. windcode/tui/__init__.py +3 -0
  116. windcode/tui/app.py +1015 -0
  117. windcode/tui/commands.py +90 -0
  118. windcode/tui/permission_display.py +24 -0
  119. windcode/tui/styles.tcss +591 -0
  120. windcode/tui/widgets/__init__.py +31 -0
  121. windcode/tui/widgets/approval.py +98 -0
  122. windcode/tui/widgets/command_menu.py +90 -0
  123. windcode/tui/widgets/extensions.py +48 -0
  124. windcode/tui/widgets/input.py +110 -0
  125. windcode/tui/widgets/memory.py +143 -0
  126. windcode/tui/widgets/messages.py +299 -0
  127. windcode/tui/widgets/models.py +565 -0
  128. windcode/tui/widgets/question.py +46 -0
  129. windcode/tui/widgets/sessions.py +68 -0
  130. windcode/tui/widgets/status.py +46 -0
  131. windcode/tui/widgets/subagents.py +195 -0
  132. windcode/tui/widgets/tools.py +66 -0
  133. windcode/tui/widgets/welcome.py +149 -0
  134. windcode/types.py +80 -0
  135. windcode/worktrees/__init__.py +24 -0
  136. windcode/worktrees/git.py +92 -0
  137. windcode/worktrees/manager.py +265 -0
  138. windcode/worktrees/models.py +62 -0
  139. windcode-0.1.0.dist-info/METADATA +207 -0
  140. windcode-0.1.0.dist-info/RECORD +143 -0
  141. windcode-0.1.0.dist-info/WHEEL +4 -0
  142. windcode-0.1.0.dist-info/entry_points.txt +2 -0
  143. windcode-0.1.0.dist-info/licenses/LICENSE +201 -0
@@ -0,0 +1,90 @@
1
+ from __future__ import annotations
2
+
3
+ from dataclasses import dataclass
4
+
5
+
6
+ @dataclass(frozen=True, slots=True)
7
+ class CommandDefinition:
8
+ name: str
9
+ description: str
10
+ argument_hint: str = ""
11
+
12
+ @property
13
+ def value(self) -> str:
14
+ return f"/{self.name}"
15
+
16
+
17
+ @dataclass(frozen=True, slots=True)
18
+ class SkillDefinition:
19
+ name: str
20
+ description: str
21
+ argument_hint: str = ""
22
+
23
+ @property
24
+ def value(self) -> str:
25
+ return f"${self.name}"
26
+
27
+
28
+ CompletionDefinition = CommandDefinition | SkillDefinition
29
+
30
+
31
+ COMMAND_CATALOG = (
32
+ CommandDefinition("new", "新建会话"),
33
+ CommandDefinition("resume", "恢复已有会话", "[会话ID]"),
34
+ CommandDefinition("history", "显示当前会话历史节点"),
35
+ CommandDefinition("rewind", "回退到历史记录", "<记录ID>"),
36
+ CommandDefinition("mode", "切换权限模式", "<模式>"),
37
+ CommandDefinition("model", "配置或切换当前模型", "[配置别名]"),
38
+ CommandDefinition("compact", "压缩当前上下文"),
39
+ CommandDefinition("clear", "清空当前消息显示"),
40
+ CommandDefinition("status", "显示会话状态"),
41
+ CommandDefinition("agents", "显示子智能体状态"),
42
+ CommandDefinition(
43
+ "extensions",
44
+ "管理扩展",
45
+ "[目标]",
46
+ ),
47
+ CommandDefinition(
48
+ "memory",
49
+ "管理长期记忆",
50
+ ),
51
+ CommandDefinition("help", "显示可用命令"),
52
+ CommandDefinition("quit", "退出 Windcode"),
53
+ )
54
+
55
+ COMMANDS = frozenset(command.name for command in COMMAND_CATALOG)
56
+
57
+
58
+ @dataclass(frozen=True, slots=True)
59
+ class SlashCommand:
60
+ name: str
61
+ arguments: tuple[str, ...] = ()
62
+
63
+
64
+ def complete_commands(
65
+ prefix: str, extra: tuple[CommandDefinition, ...] = ()
66
+ ) -> tuple[CommandDefinition, ...]:
67
+ if prefix != prefix.strip() or not prefix.startswith("/") or " " in prefix or "\n" in prefix:
68
+ return ()
69
+ name_prefix = prefix[1:].casefold()
70
+ catalog = (*COMMAND_CATALOG, *extra)
71
+ return tuple(command for command in catalog if command.name.startswith(name_prefix))
72
+
73
+
74
+ def complete_skills(
75
+ prefix: str, skills: tuple[SkillDefinition, ...]
76
+ ) -> tuple[SkillDefinition, ...]:
77
+ if prefix != prefix.strip() or not prefix.startswith("$") or " " in prefix or "\n" in prefix:
78
+ return ()
79
+ name_prefix = prefix[1:].casefold()
80
+ return tuple(skill for skill in skills if skill.name.casefold().startswith(name_prefix))
81
+
82
+
83
+ def parse_command(value: str, extra_names: frozenset[str] = frozenset()) -> SlashCommand:
84
+ parts = value.strip().split()
85
+ if not parts or not parts[0].startswith("/"):
86
+ raise ValueError("命令必须以 / 开头")
87
+ name = parts[0][1:].casefold()
88
+ if name not in COMMANDS and name not in extra_names:
89
+ raise ValueError(f"未知命令: /{name}")
90
+ return SlashCommand(name, tuple(parts[1:]))
@@ -0,0 +1,24 @@
1
+ from __future__ import annotations
2
+
3
+ PERMISSION_LABELS = {
4
+ "plan": "计划",
5
+ "default": "默认",
6
+ "accept_edits": "自动编辑",
7
+ "full_access": "完全授权",
8
+ }
9
+
10
+ # Keep permission modes visually consistent with MewCode.
11
+ PERMISSION_STYLES = {
12
+ "plan": "yellow",
13
+ "default": "dim",
14
+ "accept_edits": "green",
15
+ "full_access": "red",
16
+ }
17
+
18
+
19
+ def permission_label(permission: str) -> str:
20
+ return PERMISSION_LABELS.get(permission, permission)
21
+
22
+
23
+ def permission_style(permission: str) -> str:
24
+ return PERMISSION_STYLES.get(permission, "dim")
@@ -0,0 +1,591 @@
1
+ Screen {
2
+ background: #151719;
3
+ color: #d7dde2;
4
+ }
5
+
6
+ #title-bar {
7
+ dock: top;
8
+ width: 100%;
9
+ height: 1;
10
+ padding: 0 2;
11
+ background: #151719;
12
+ color: #aab3ba;
13
+ }
14
+
15
+ #content-shell {
16
+ width: 100%;
17
+ height: 1fr;
18
+ }
19
+
20
+ #welcome-view {
21
+ height: auto;
22
+ width: 100%;
23
+ align: center middle;
24
+ padding: 0 4;
25
+ background: #151719;
26
+ }
27
+
28
+ .welcome-mode #content-shell {
29
+ align: center middle;
30
+ }
31
+
32
+ #welcome-logo {
33
+ width: 100%;
34
+ height: 5;
35
+ content-align: center middle;
36
+ color: #5fa8e8;
37
+ }
38
+
39
+ #welcome-subtitle {
40
+ display: none;
41
+ }
42
+
43
+ #welcome-context {
44
+ display: none;
45
+ }
46
+
47
+ #welcome-notice {
48
+ width: 100%;
49
+ height: auto;
50
+ min-height: 1;
51
+ margin-top: 1;
52
+ text-align: center;
53
+ color: #d9a557;
54
+ }
55
+
56
+ #welcome-notice.welcome-notice-error {
57
+ color: #e36d6d;
58
+ }
59
+
60
+ #chat-area {
61
+ height: 1fr;
62
+ min-height: 10;
63
+ padding: 1 2 0 2;
64
+ scrollbar-color: #39434a;
65
+ scrollbar-color-hover: #5fa8e8;
66
+ scrollbar-size: 1 1;
67
+ }
68
+
69
+ .message {
70
+ width: 100%;
71
+ height: auto;
72
+ padding: 0 2;
73
+ margin: 0;
74
+ }
75
+
76
+ .user-row {
77
+ width: 100%;
78
+ height: auto;
79
+ margin: 1 0 0 0;
80
+ border-left: thick #5fa8e8;
81
+ background: #1b2024;
82
+ }
83
+
84
+ .user-message {
85
+ color: #e4e9ed;
86
+ padding: 1 2;
87
+ }
88
+
89
+ .ai-row {
90
+ width: 100%;
91
+ height: auto;
92
+ margin: 1 0 0 0;
93
+ }
94
+
95
+ .ai-message {
96
+ color: #d7dde2;
97
+ padding: 0 2;
98
+ }
99
+
100
+ .ai-segment {
101
+ width: 100%;
102
+ height: auto;
103
+ padding: 0 2;
104
+ }
105
+
106
+ .ai-segment .ai-prefix {
107
+ width: 2;
108
+ height: auto;
109
+ color: #876fff;
110
+ }
111
+
112
+ .ai-segment .ai-message {
113
+ width: 1fr;
114
+ padding: 0;
115
+ }
116
+
117
+ .ai-message MarkdownFence {
118
+ background: #1b2024;
119
+ }
120
+
121
+ .error-message {
122
+ color: #e36d6d;
123
+ padding: 0 2;
124
+ }
125
+
126
+ .system-message {
127
+ color: #88939b;
128
+ padding: 0 2;
129
+ }
130
+
131
+ .tool-block {
132
+ width: 100%;
133
+ height: auto;
134
+ padding: 0 2;
135
+ color: #aab3ba;
136
+ }
137
+
138
+ .tool-block-loading {
139
+ color: #88939b;
140
+ }
141
+
142
+ .tool-block-error {
143
+ color: #e36d6d;
144
+ }
145
+
146
+ .thinking-done {
147
+ color: #d9a557;
148
+ text-style: italic;
149
+ }
150
+
151
+ #spinner-live {
152
+ height: 1;
153
+ padding: 0 2;
154
+ color: #d9a557;
155
+ }
156
+
157
+ #input-dock {
158
+ dock: bottom;
159
+ width: 100%;
160
+ height: auto;
161
+ max-height: 24;
162
+ padding: 1 2 1 2;
163
+ background: #151719;
164
+ }
165
+
166
+ #input-area {
167
+ width: 100%;
168
+ height: auto;
169
+ max-height: 23;
170
+ padding: 0 2;
171
+ background: #1b2024;
172
+ border-left: thick #5fa8e8;
173
+ }
174
+
175
+ .welcome-mode #input-area {
176
+ width: 68%;
177
+ offset-x: 0;
178
+ padding: 0 1;
179
+ }
180
+
181
+ .welcome-mode #chat-input {
182
+ min-height: 5;
183
+ }
184
+
185
+ .welcome-mode #input-dock {
186
+ dock: none;
187
+ align-horizontal: center;
188
+ padding: 1 2 0 2;
189
+ }
190
+
191
+ .narrow #input-dock {
192
+ padding: 0;
193
+ }
194
+
195
+ .narrow.welcome-mode #input-area {
196
+ width: 100%;
197
+ offset-x: 0;
198
+ }
199
+
200
+ #command-menu {
201
+ width: 100%;
202
+ height: auto;
203
+ max-height: 9;
204
+ padding: 0 1;
205
+ background: #20262b;
206
+ color: #cbd3d8;
207
+ overflow-y: auto;
208
+ scrollbar-size: 1 1;
209
+ scrollbar-color: #4a555d;
210
+ }
211
+
212
+ #chat-input {
213
+ width: 100%;
214
+ height: auto;
215
+ min-height: 3;
216
+ max-height: 10;
217
+ padding: 1 2 0 2;
218
+ border: none;
219
+ background: #1b2024;
220
+ color: #e4e9ed;
221
+ }
222
+
223
+ #chat-input:focus {
224
+ border: none;
225
+ }
226
+
227
+ #status-bar {
228
+ width: 100%;
229
+ height: 1;
230
+ min-height: 1;
231
+ padding: 0 2;
232
+ background: #1b2024;
233
+ color: #88939b;
234
+ }
235
+
236
+ #mode-label {
237
+ width: auto;
238
+ height: 1;
239
+ color: #5fa8e8;
240
+ padding: 0 1 0 0;
241
+ }
242
+
243
+ #sandbox-label {
244
+ width: auto;
245
+ height: 1;
246
+ color: #88939b;
247
+ padding: 0 1;
248
+ }
249
+
250
+ #model-label {
251
+ width: 1fr;
252
+ height: 1;
253
+ text-align: right;
254
+ color: #aab3ba;
255
+ }
256
+
257
+ #sessions {
258
+ width: 100%;
259
+ height: 3;
260
+ background: #20262b;
261
+ }
262
+
263
+ ModelManager,
264
+ ProviderManager {
265
+ align: center middle;
266
+ background: #151719 80%;
267
+ }
268
+
269
+ MemoryManager {
270
+ align: center middle;
271
+ background: #151719 80%;
272
+ }
273
+
274
+ #memory-dialog {
275
+ width: 76;
276
+ max-width: 96%;
277
+ height: 90%;
278
+ min-height: 18;
279
+ max-height: 92%;
280
+ padding: 1 2;
281
+ background: #20262b;
282
+ border: round #39434a;
283
+ }
284
+
285
+ #memory-manager-title {
286
+ height: 2;
287
+ color: #e4e9ed;
288
+ text-style: bold;
289
+ }
290
+
291
+ #memory-enabled-row {
292
+ height: 3;
293
+ align-vertical: middle;
294
+ }
295
+
296
+ #memory-enabled-label {
297
+ width: 1fr;
298
+ }
299
+
300
+ #memory-policy {
301
+ height: 2;
302
+ color: #88939b;
303
+ }
304
+
305
+ #memory-list {
306
+ height: 1fr;
307
+ min-height: 4;
308
+ background: #1b2024;
309
+ }
310
+
311
+ #memory-details {
312
+ height: 6;
313
+ padding: 1;
314
+ overflow-y: auto;
315
+ color: #aab3ba;
316
+ }
317
+
318
+ #memory-actions {
319
+ dock: bottom;
320
+ height: 3;
321
+ background: #20262b;
322
+ }
323
+
324
+ .narrow #memory-dialog {
325
+ width: 100%;
326
+ height: 96%;
327
+ max-height: 96%;
328
+ padding: 1;
329
+ }
330
+
331
+ .narrow #memory-details {
332
+ height: 5;
333
+ }
334
+
335
+ #model-dialog,
336
+ #provider-dialog {
337
+ width: 76;
338
+ max-width: 92%;
339
+ height: auto;
340
+ padding: 1 2;
341
+ background: #20262b;
342
+ border: round #4a555d;
343
+ }
344
+
345
+ #provider-dialog {
346
+ width: 92;
347
+ max-height: 94%;
348
+ }
349
+
350
+ #model-manager-title,
351
+ #provider-manager-title {
352
+ width: 100%;
353
+ height: 2;
354
+ color: #e4e9ed;
355
+ text-style: bold;
356
+ }
357
+
358
+ #model-search,
359
+ #provider-preset,
360
+ #provider-editor Input,
361
+ #provider-editor Select {
362
+ height: 3;
363
+ border: none;
364
+ background: #1b2024;
365
+ }
366
+
367
+ #model-list {
368
+ width: 100%;
369
+ height: 12;
370
+ margin-top: 1;
371
+ background: #1b2024;
372
+ border: none;
373
+ }
374
+
375
+ #model-provider-tabs {
376
+ width: 100%;
377
+ height: 2;
378
+ padding: 1 1 0 1;
379
+ color: #88939b;
380
+ overflow-x: auto;
381
+ scrollbar-size-horizontal: 0;
382
+ }
383
+
384
+ #provider-list {
385
+ width: 100%;
386
+ height: 10;
387
+ background: #1b2024;
388
+ border: none;
389
+ }
390
+
391
+ #model-picker-status,
392
+ #provider-details,
393
+ #provider-editor-error {
394
+ width: 100%;
395
+ height: 2;
396
+ padding: 0 1;
397
+ color: #88939b;
398
+ }
399
+
400
+ #provider-editor-error {
401
+ color: #e36d6d;
402
+ }
403
+
404
+ .dialog-actions {
405
+ width: 100%;
406
+ height: 3;
407
+ layout: grid;
408
+ grid-size: 3 1;
409
+ grid-gutter: 0 1;
410
+ }
411
+
412
+ .dialog-actions Button {
413
+ width: 1fr;
414
+ min-width: 0;
415
+ }
416
+
417
+ #provider-actions {
418
+ width: 100%;
419
+ height: 6;
420
+ layout: grid;
421
+ grid-size: 3 2;
422
+ grid-gutter: 0 1;
423
+ }
424
+
425
+ #provider-actions Button {
426
+ width: 1fr;
427
+ min-width: 0;
428
+ }
429
+
430
+ #provider-editor {
431
+ width: 100%;
432
+ height: auto;
433
+ max-height: 1fr;
434
+ overflow-y: auto;
435
+ scrollbar-size-vertical: 1;
436
+ }
437
+
438
+ .provider-field {
439
+ width: 100%;
440
+ height: 3;
441
+ }
442
+
443
+ .provider-field-label {
444
+ width: 26;
445
+ height: 3;
446
+ padding: 0 1;
447
+ color: #aab3ba;
448
+ }
449
+
450
+ .provider-field Input,
451
+ .provider-field Select {
452
+ width: 1fr;
453
+ }
454
+
455
+ .interaction {
456
+ width: 100%;
457
+ height: auto;
458
+ padding: 0 2;
459
+ margin: 1 0 0 0;
460
+ border-left: thick #d9a557;
461
+ }
462
+
463
+ .interaction Horizontal {
464
+ height: 3;
465
+ }
466
+
467
+ .interaction Button {
468
+ margin-right: 1;
469
+ }
470
+
471
+ .subagent-group {
472
+ width: 100%;
473
+ height: auto;
474
+ margin: 1 0 0 0;
475
+ padding: 0 2;
476
+ border-left: thick #5fa8e8;
477
+ }
478
+
479
+ .subagent-group-title {
480
+ width: 100%;
481
+ height: 1;
482
+ color: #aab3ba;
483
+ text-style: bold;
484
+ }
485
+
486
+ .subagent-row {
487
+ width: 100%;
488
+ height: auto;
489
+ min-height: 2;
490
+ padding: 0 1;
491
+ color: #aab3ba;
492
+ }
493
+
494
+ .subagent-row:focus {
495
+ background: #20262b;
496
+ }
497
+
498
+ .subagent-summary,
499
+ .subagent-details {
500
+ width: 100%;
501
+ height: auto;
502
+ }
503
+
504
+ .subagent-details {
505
+ padding: 0 0 0 2;
506
+ color: #88939b;
507
+ }
508
+
509
+ .subagent-status-running,
510
+ .subagent-status-completed,
511
+ .subagent-status-integrated {
512
+ color: #70b892;
513
+ }
514
+
515
+ .subagent-status-queued {
516
+ color: #d9a557;
517
+ }
518
+
519
+ .subagent-status-blocked,
520
+ .subagent-status-failed,
521
+ .subagent-status-conflict,
522
+ .subagent-status-cancelled {
523
+ color: #e36d6d;
524
+ }
525
+
526
+ .narrow #welcome-view {
527
+ padding: 0 1;
528
+ }
529
+
530
+ .narrow #welcome-subtitle {
531
+ margin-top: 0;
532
+ }
533
+
534
+ .narrow #welcome-context {
535
+ margin-top: 0;
536
+ }
537
+
538
+ .narrow #input-area,
539
+ .narrow.welcome-mode #input-area {
540
+ width: 100%;
541
+ offset-x: 0;
542
+ margin-bottom: 0;
543
+ padding: 0;
544
+ }
545
+
546
+ .narrow #model-dialog,
547
+ .narrow #provider-dialog {
548
+ width: 100%;
549
+ max-width: 100%;
550
+ padding: 1;
551
+ }
552
+
553
+ .narrow #provider-actions {
554
+ height: 9;
555
+ grid-size: 2 3;
556
+ }
557
+
558
+ .narrow .provider-field-label {
559
+ width: 15;
560
+ padding-left: 0;
561
+ }
562
+
563
+ .narrow .provider-field Input,
564
+ .narrow .provider-field Select {
565
+ width: 1fr;
566
+ }
567
+
568
+ .narrow #chat-area {
569
+ padding: 0;
570
+ }
571
+
572
+ .narrow #title-bar {
573
+ padding: 0 1;
574
+ }
575
+
576
+ .narrow #sandbox-label {
577
+ display: none;
578
+ }
579
+
580
+ .narrow .message {
581
+ padding-left: 1;
582
+ padding-right: 1;
583
+ }
584
+
585
+ .narrow .subagent-group {
586
+ padding: 0 1;
587
+ }
588
+
589
+ .narrow .subagent-row {
590
+ padding: 0;
591
+ }
@@ -0,0 +1,31 @@
1
+ from windcode.tui.widgets.approval import ApprovalWidget
2
+ from windcode.tui.widgets.command_menu import CommandMenu
3
+ from windcode.tui.widgets.extensions import ExtensionList
4
+ from windcode.tui.widgets.input import ChatInput
5
+ from windcode.tui.widgets.memory import MemoryManager
6
+ from windcode.tui.widgets.messages import MessageStream
7
+ from windcode.tui.widgets.models import ModelManager, ProviderManager
8
+ from windcode.tui.widgets.question import QuestionWidget
9
+ from windcode.tui.widgets.sessions import SessionSelector
10
+ from windcode.tui.widgets.status import StatusBar
11
+ from windcode.tui.widgets.subagents import SubagentGroup, SubagentRow
12
+ from windcode.tui.widgets.tools import ToolBlock
13
+ from windcode.tui.widgets.welcome import WelcomeView
14
+
15
+ __all__ = [
16
+ "ApprovalWidget",
17
+ "ChatInput",
18
+ "CommandMenu",
19
+ "ExtensionList",
20
+ "MemoryManager",
21
+ "MessageStream",
22
+ "ModelManager",
23
+ "ProviderManager",
24
+ "QuestionWidget",
25
+ "SessionSelector",
26
+ "StatusBar",
27
+ "SubagentGroup",
28
+ "SubagentRow",
29
+ "ToolBlock",
30
+ "WelcomeView",
31
+ ]