@wowyuarm/dsh-agent-team 0.1.3 → 0.1.5
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 +7 -1
- package/README.zh.md +12 -3
- package/package.json +1 -1
- package/packages/agent-team/README.md +3 -3
- package/packages/agent-team/README.zh.md +3 -3
- package/packages/agent-team/lib/auto-compaction.js +39 -1
- package/packages/agent-team/lib/index.js +123 -14
- package/packages/agent-team/lib/ledger.js +355 -110
- package/packages/agent-team/lib/spec.js +39 -11
- package/packages/agent-team/lib/typert.host.js +257 -86
- package/packages/agent-team/lib/typert.remote-client.d.ts +5 -1
- package/packages/agent-team/lib/typert.remote-client.d.ts.map +1 -1
- package/packages/agent-team/lib/typert.remote-client.js +196 -59
- package/packages/agent-team/lib/types/auto-compaction.d.ts +9 -0
- package/packages/agent-team/lib/types/auto-compaction.d.ts.map +1 -1
- package/packages/agent-team/lib/types/index.d.ts +24 -7
- package/packages/agent-team/lib/types/index.d.ts.map +1 -1
- package/packages/agent-team/lib/types/ledger.d.ts +36 -2
- package/packages/agent-team/lib/types/ledger.d.ts.map +1 -1
- package/packages/agent-team/lib/types/spec.d.ts.map +1 -1
- package/packages/agent-team/lib/types/types.d.ts +109 -30
- package/packages/agent-team/lib/types/types.d.ts.map +1 -1
- package/packages/agent-team/preset/team-member/agent.cordis.yml +1 -1
- package/packages/client-agent-team/README.md +2 -1
- package/packages/client-agent-team/README.zh.md +2 -1
- package/packages/client-agent-team/lib/client.js +1082 -380
- package/packages/client-agent-team/lib/client.js.map +1 -1
- package/packages/client-agent-team/lib/types/client/TeamAgentsPanel.d.ts +2 -1
- package/packages/client-agent-team/lib/types/client/TeamAgentsPanel.d.ts.map +1 -1
- package/packages/client-agent-team/lib/types/client/TeamAgentsPanel.js +73 -15
- package/packages/client-agent-team/lib/types/client/TeamChannelPage.d.ts.map +1 -1
- package/packages/client-agent-team/lib/types/client/TeamChannelPage.js +34 -10
- package/packages/client-agent-team/lib/types/client/TeamChannelsPanel.d.ts.map +1 -1
- package/packages/client-agent-team/lib/types/client/TeamChannelsPanel.js +3 -1
- package/packages/client-agent-team/lib/types/client/TeamComposer.d.ts +6 -1
- package/packages/client-agent-team/lib/types/client/TeamComposer.d.ts.map +1 -1
- package/packages/client-agent-team/lib/types/client/TeamComposer.js +76 -20
- package/packages/client-agent-team/lib/types/client/TeamConversation.d.ts +1 -1
- package/packages/client-agent-team/lib/types/client/TeamConversation.d.ts.map +1 -1
- package/packages/client-agent-team/lib/types/client/TeamConversation.js +3 -3
- package/packages/client-agent-team/lib/types/client/TeamMemberSessionComposer.d.ts.map +1 -1
- package/packages/client-agent-team/lib/types/client/TeamMemberSessionComposer.js +16 -1
- package/packages/client-agent-team/lib/types/client/TeamMessage.d.ts +4 -1
- package/packages/client-agent-team/lib/types/client/TeamMessage.d.ts.map +1 -1
- package/packages/client-agent-team/lib/types/client/TeamMessage.js +62 -25
- package/packages/client-agent-team/lib/types/client/TeamRowMenu.d.ts +3 -2
- package/packages/client-agent-team/lib/types/client/TeamRowMenu.d.ts.map +1 -1
- package/packages/client-agent-team/lib/types/client/TeamSidebarSection.d.ts +5 -2
- package/packages/client-agent-team/lib/types/client/TeamSidebarSection.d.ts.map +1 -1
- package/packages/client-agent-team/lib/types/client/TeamSidebarSection.js +2 -4
- package/packages/client-agent-team/lib/types/client/TeamThreadPage.d.ts +2 -1
- package/packages/client-agent-team/lib/types/client/TeamThreadPage.d.ts.map +1 -1
- package/packages/client-agent-team/lib/types/client/TeamThreadPage.js +92 -18
- package/packages/client-agent-team/lib/types/client/TeamWorkspaceBrowser.d.ts +1 -1
- package/packages/client-agent-team/lib/types/client/TeamWorkspaceBrowser.d.ts.map +1 -1
- package/packages/client-agent-team/lib/types/client/TeamWorkspaceBrowser.js +5 -2
- package/packages/client-agent-team/lib/types/client/index.d.ts.map +1 -1
- package/packages/client-agent-team/lib/types/client/index.js +16 -13
- package/packages/client-agent-team/lib/types/client/locales.d.ts +40 -0
- package/packages/client-agent-team/lib/types/client/locales.d.ts.map +1 -1
- package/packages/client-agent-team/lib/types/client/locales.js +40 -0
- package/packages/client-agent-team/lib/types/client/navigation.d.ts +1 -1
- package/packages/client-agent-team/lib/types/client/navigation.d.ts.map +1 -1
- package/packages/client-agent-team/lib/types/client/navigation.js +12 -6
- package/packages/client-agent-team/lib/types/client/sidebar-sections.d.ts +16 -0
- package/packages/client-agent-team/lib/types/client/sidebar-sections.d.ts.map +1 -0
- package/packages/client-agent-team/lib/types/client/sidebar-sections.js +102 -0
- package/packages/client-agent-team/lib/types/client/slots.d.ts +3 -1
- package/packages/client-agent-team/lib/types/client/slots.d.ts.map +1 -1
- package/packages/client-agent-team/lib/types/client/task-refs.d.ts +1 -1
- package/packages/client-agent-team/lib/types/client/task-refs.d.ts.map +1 -1
- package/packages/client-agent-team/lib/types/client/task-refs.js +1 -1
- package/packages/client-agent-team/lib/types/client/team-formatters.d.ts +9 -0
- package/packages/client-agent-team/lib/types/client/team-formatters.d.ts.map +1 -1
- package/packages/client-agent-team/lib/types/client/team-formatters.js +22 -2
- package/packages/tool-agent-team/README.md +7 -7
- package/packages/tool-agent-team/README.zh.md +7 -7
- package/packages/tool-agent-team/lib/index.js +38 -28
- package/packages/tool-agent-team/lib/types/index.d.ts.map +1 -1
|
@@ -4138,7 +4138,8 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
4138
4138
|
const _wowyuarm_dsh_agent_team_agentTeam_changeAttention_parameter_0$schema = object({
|
|
4139
4139
|
"requestId": intersection(string(), unknown()).readonly(),
|
|
4140
4140
|
"workspaceId": intersection(string(), unknown()).readonly(),
|
|
4141
|
-
"
|
|
4141
|
+
"threadRef": intersection(string(), unknown()).readonly().optional(),
|
|
4142
|
+
"taskRef": intersection(string(), unknown()).readonly().optional(),
|
|
4142
4143
|
"action": union([literal("follow"), literal("unfollow")]).readonly()
|
|
4143
4144
|
});
|
|
4144
4145
|
const _wowyuarm_dsh_agent_team_agentTeam_changeAttention_result$schema = object({
|
|
@@ -4163,10 +4164,10 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
4163
4164
|
literal("open"),
|
|
4164
4165
|
literal("accepted")
|
|
4165
4166
|
]).readonly()
|
|
4166
|
-
}).readonly(),
|
|
4167
|
+
}).readonly().optional(),
|
|
4167
4168
|
"thread": object({
|
|
4168
4169
|
"threadRef": intersection(string(), unknown()).readonly(),
|
|
4169
|
-
"taskRef": intersection(string(), unknown()).readonly(),
|
|
4170
|
+
"taskRef": intersection(string(), unknown()).readonly().optional(),
|
|
4170
4171
|
"revision": number().readonly()
|
|
4171
4172
|
}).readonly(),
|
|
4172
4173
|
"attention": object({
|
|
@@ -4217,7 +4218,8 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
4217
4218
|
"kind": union([
|
|
4218
4219
|
literal("accept"),
|
|
4219
4220
|
literal("close"),
|
|
4220
|
-
literal("reopen")
|
|
4221
|
+
literal("reopen"),
|
|
4222
|
+
literal("promote")
|
|
4221
4223
|
]).readonly(),
|
|
4222
4224
|
"releasedClaimRefs": union([_undefined(), array(intersection(string(), unknown()))]).readonly().optional(),
|
|
4223
4225
|
"completedClaimRefs": union([_undefined(), array(intersection(string(), unknown()))]).readonly().optional(),
|
|
@@ -4246,7 +4248,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
4246
4248
|
}).readonly(),
|
|
4247
4249
|
"thread": object({
|
|
4248
4250
|
"threadRef": intersection(string(), unknown()).readonly(),
|
|
4249
|
-
"taskRef": intersection(string(), unknown()).readonly(),
|
|
4251
|
+
"taskRef": intersection(string(), unknown()).readonly().optional(),
|
|
4250
4252
|
"revision": number().readonly()
|
|
4251
4253
|
}).readonly(),
|
|
4252
4254
|
"claims": array(object({
|
|
@@ -4265,7 +4267,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
4265
4267
|
}),
|
|
4266
4268
|
object({
|
|
4267
4269
|
"kind": literal("unread_required").readonly(),
|
|
4268
|
-
"taskRef": intersection(string(), unknown()).readonly(),
|
|
4270
|
+
"taskRef": intersection(string(), unknown()).readonly().optional(),
|
|
4269
4271
|
"threadRef": intersection(string(), unknown()).readonly(),
|
|
4270
4272
|
"revision": number().readonly(),
|
|
4271
4273
|
"unreadCount": number().readonly(),
|
|
@@ -4273,12 +4275,58 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
4273
4275
|
}),
|
|
4274
4276
|
object({
|
|
4275
4277
|
"kind": literal("stale_revision").readonly(),
|
|
4276
|
-
"taskRef": intersection(string(), unknown()).readonly(),
|
|
4278
|
+
"taskRef": intersection(string(), unknown()).readonly().optional(),
|
|
4277
4279
|
"threadRef": intersection(string(), unknown()).readonly(),
|
|
4278
4280
|
"expectedRevision": number().readonly(),
|
|
4279
4281
|
"revision": number().readonly()
|
|
4280
4282
|
})
|
|
4281
4283
|
]);
|
|
4284
|
+
const _wowyuarm_dsh_agent_team_agentTeam_clearMemberContext_parameter_0$schema = object({
|
|
4285
|
+
"requestId": intersection(string(), unknown()).readonly(),
|
|
4286
|
+
"workspaceId": intersection(string(), unknown()).readonly(),
|
|
4287
|
+
"memberId": intersection(string(), unknown()).readonly()
|
|
4288
|
+
});
|
|
4289
|
+
const _wowyuarm_dsh_agent_team_agentTeam_clearMemberContext_result$schema = object({
|
|
4290
|
+
"receipt": object({
|
|
4291
|
+
"operationId": intersection(string(), unknown()).readonly(),
|
|
4292
|
+
"requestId": intersection(string(), unknown()).readonly(),
|
|
4293
|
+
"sequence": number().readonly()
|
|
4294
|
+
}).readonly(),
|
|
4295
|
+
"status": object({
|
|
4296
|
+
"member": object({
|
|
4297
|
+
"memberId": intersection(string(), unknown()).readonly(),
|
|
4298
|
+
"sessionId": intersection(string(), unknown()).readonly(),
|
|
4299
|
+
"workspaceId": intersection(string(), unknown()).readonly(),
|
|
4300
|
+
"handle": string().readonly(),
|
|
4301
|
+
"description": string().readonly(),
|
|
4302
|
+
"presetId": string().readonly(),
|
|
4303
|
+
"model": union([_undefined(), object({
|
|
4304
|
+
"provider": string().readonly(),
|
|
4305
|
+
"model": string().readonly(),
|
|
4306
|
+
"reasoningEffort": intersection(string(), unknown()).readonly().optional()
|
|
4307
|
+
})]).readonly().optional(),
|
|
4308
|
+
"privateMemoryPath": string().readonly(),
|
|
4309
|
+
"state": union([
|
|
4310
|
+
literal("enabled"),
|
|
4311
|
+
literal("suspended"),
|
|
4312
|
+
literal("inactive")
|
|
4313
|
+
]).readonly()
|
|
4314
|
+
}).readonly(),
|
|
4315
|
+
"availability": union([
|
|
4316
|
+
literal("suspended"),
|
|
4317
|
+
literal("inactive"),
|
|
4318
|
+
literal("active"),
|
|
4319
|
+
literal("unavailable")
|
|
4320
|
+
]).readonly(),
|
|
4321
|
+
"presence": union([
|
|
4322
|
+
literal("unavailable"),
|
|
4323
|
+
literal("available"),
|
|
4324
|
+
literal("working"),
|
|
4325
|
+
literal("error")
|
|
4326
|
+
]).readonly(),
|
|
4327
|
+
"diagnostic": string().readonly().optional()
|
|
4328
|
+
}).readonly()
|
|
4329
|
+
});
|
|
4282
4330
|
const _wowyuarm_dsh_agent_team_agentTeam_createChannel_parameter_0$schema = object({
|
|
4283
4331
|
"requestId": intersection(string(), unknown()).readonly(),
|
|
4284
4332
|
"workspaceId": intersection(string(), unknown()).readonly(),
|
|
@@ -4331,10 +4379,10 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
4331
4379
|
literal("open"),
|
|
4332
4380
|
literal("accepted")
|
|
4333
4381
|
]).readonly()
|
|
4334
|
-
}).readonly(),
|
|
4382
|
+
}).readonly().optional(),
|
|
4335
4383
|
"thread": object({
|
|
4336
4384
|
"threadRef": intersection(string(), unknown()).readonly(),
|
|
4337
|
-
"taskRef": intersection(string(), unknown()).readonly(),
|
|
4385
|
+
"taskRef": intersection(string(), unknown()).readonly().optional(),
|
|
4338
4386
|
"revision": number().readonly()
|
|
4339
4387
|
}).readonly(),
|
|
4340
4388
|
"unreadCount": number().readonly(),
|
|
@@ -4399,6 +4447,74 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
4399
4447
|
]).readonly(),
|
|
4400
4448
|
"diagnostic": string().readonly().optional()
|
|
4401
4449
|
}));
|
|
4450
|
+
const _wowyuarm_dsh_agent_team_agentTeam_promoteThread_parameter_0$schema = object({
|
|
4451
|
+
"requestId": intersection(string(), unknown()).readonly(),
|
|
4452
|
+
"workspaceId": intersection(string(), unknown()).readonly(),
|
|
4453
|
+
"threadRef": intersection(string(), unknown()).readonly(),
|
|
4454
|
+
"baseRevision": number().readonly()
|
|
4455
|
+
});
|
|
4456
|
+
const _wowyuarm_dsh_agent_team_agentTeam_promoteThread_result$schema = union([
|
|
4457
|
+
object({
|
|
4458
|
+
"kind": literal("unread_required").readonly(),
|
|
4459
|
+
"taskRef": intersection(string(), unknown()).readonly().optional(),
|
|
4460
|
+
"threadRef": intersection(string(), unknown()).readonly(),
|
|
4461
|
+
"revision": number().readonly(),
|
|
4462
|
+
"unreadCount": number().readonly(),
|
|
4463
|
+
"directCount": number().readonly()
|
|
4464
|
+
}),
|
|
4465
|
+
object({
|
|
4466
|
+
"kind": literal("stale_revision").readonly(),
|
|
4467
|
+
"taskRef": intersection(string(), unknown()).readonly().optional(),
|
|
4468
|
+
"threadRef": intersection(string(), unknown()).readonly(),
|
|
4469
|
+
"expectedRevision": number().readonly(),
|
|
4470
|
+
"revision": number().readonly()
|
|
4471
|
+
}),
|
|
4472
|
+
object({
|
|
4473
|
+
"kind": literal("committed").readonly(),
|
|
4474
|
+
"receipt": object({
|
|
4475
|
+
"operationId": intersection(string(), unknown()).readonly(),
|
|
4476
|
+
"requestId": intersection(string(), unknown()).readonly(),
|
|
4477
|
+
"sequence": number().readonly()
|
|
4478
|
+
}).readonly(),
|
|
4479
|
+
"activity": object({
|
|
4480
|
+
"kind": union([
|
|
4481
|
+
literal("accept"),
|
|
4482
|
+
literal("close"),
|
|
4483
|
+
literal("reopen"),
|
|
4484
|
+
literal("promote")
|
|
4485
|
+
]).readonly(),
|
|
4486
|
+
"releasedClaimRefs": union([_undefined(), array(intersection(string(), unknown()))]).readonly().optional(),
|
|
4487
|
+
"completedClaimRefs": union([_undefined(), array(intersection(string(), unknown()))]).readonly().optional(),
|
|
4488
|
+
"activityRef": intersection(string(), unknown()).readonly(),
|
|
4489
|
+
"taskRef": intersection(string(), unknown()).readonly(),
|
|
4490
|
+
"threadRef": intersection(string(), unknown()).readonly(),
|
|
4491
|
+
"actor": intersection(string(), unknown()).readonly(),
|
|
4492
|
+
"sequence": number().readonly()
|
|
4493
|
+
}).readonly(),
|
|
4494
|
+
"task": object({
|
|
4495
|
+
"taskRef": intersection(string(), unknown()).readonly(),
|
|
4496
|
+
"channelRef": intersection(string(), unknown()).readonly(),
|
|
4497
|
+
"threadRef": intersection(string(), unknown()).readonly(),
|
|
4498
|
+
"status": union([
|
|
4499
|
+
literal("todo"),
|
|
4500
|
+
literal("in_progress"),
|
|
4501
|
+
literal("in_review"),
|
|
4502
|
+
literal("done"),
|
|
4503
|
+
literal("closed")
|
|
4504
|
+
]).readonly(),
|
|
4505
|
+
"resolution": union([
|
|
4506
|
+
literal("closed"),
|
|
4507
|
+
literal("open"),
|
|
4508
|
+
literal("accepted")
|
|
4509
|
+
]).readonly()
|
|
4510
|
+
}).readonly(),
|
|
4511
|
+
"thread": object({
|
|
4512
|
+
"threadRef": intersection(string(), unknown()).readonly(),
|
|
4513
|
+
"taskRef": intersection(string(), unknown()).readonly().optional(),
|
|
4514
|
+
"revision": number().readonly()
|
|
4515
|
+
}).readonly()
|
|
4516
|
+
})
|
|
4517
|
+
]);
|
|
4402
4518
|
const _wowyuarm_dsh_agent_team_agentTeam_putAttachment_parameter_0$schema = object({
|
|
4403
4519
|
"requestId": intersection(string(), unknown()).readonly(),
|
|
4404
4520
|
"workspaceId": intersection(string(), unknown()).readonly(),
|
|
@@ -4416,7 +4532,8 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
4416
4532
|
const _wowyuarm_dsh_agent_team_agentTeam_readThread_parameter_0$schema = object({
|
|
4417
4533
|
"requestId": intersection(string(), unknown()).readonly(),
|
|
4418
4534
|
"workspaceId": intersection(string(), unknown()).readonly(),
|
|
4419
|
-
"
|
|
4535
|
+
"threadRef": intersection(string(), unknown()).readonly().optional(),
|
|
4536
|
+
"taskRef": intersection(string(), unknown()).readonly().optional()
|
|
4420
4537
|
});
|
|
4421
4538
|
const _wowyuarm_dsh_agent_team_agentTeam_readThread_result$schema = object({
|
|
4422
4539
|
"receipt": object({
|
|
@@ -4440,10 +4557,10 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
4440
4557
|
literal("open"),
|
|
4441
4558
|
literal("accepted")
|
|
4442
4559
|
]).readonly()
|
|
4443
|
-
}).readonly(),
|
|
4560
|
+
}).readonly().optional(),
|
|
4444
4561
|
"thread": object({
|
|
4445
4562
|
"threadRef": intersection(string(), unknown()).readonly(),
|
|
4446
|
-
"taskRef": intersection(string(), unknown()).readonly(),
|
|
4563
|
+
"taskRef": intersection(string(), unknown()).readonly().optional(),
|
|
4447
4564
|
"revision": number().readonly()
|
|
4448
4565
|
}).readonly(),
|
|
4449
4566
|
"claims": array(object({
|
|
@@ -4463,7 +4580,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
4463
4580
|
"messageRef": intersection(string(), unknown()).readonly(),
|
|
4464
4581
|
"channelRef": intersection(string(), unknown()).readonly(),
|
|
4465
4582
|
"threadRef": intersection(string(), unknown()).readonly(),
|
|
4466
|
-
"taskRef": intersection(string(), unknown()).readonly(),
|
|
4583
|
+
"taskRef": intersection(string(), unknown()).readonly().optional(),
|
|
4467
4584
|
"sender": intersection(string(), unknown()).readonly(),
|
|
4468
4585
|
"body": string().readonly(),
|
|
4469
4586
|
"attachments": union([_undefined(), array(object({
|
|
@@ -4485,7 +4602,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
4485
4602
|
"messageRef": intersection(string(), unknown()).readonly(),
|
|
4486
4603
|
"channelRef": intersection(string(), unknown()).readonly(),
|
|
4487
4604
|
"threadRef": intersection(string(), unknown()).readonly(),
|
|
4488
|
-
"taskRef": intersection(string(), unknown()).readonly(),
|
|
4605
|
+
"taskRef": intersection(string(), unknown()).readonly().optional(),
|
|
4489
4606
|
"sender": intersection(string(), unknown()).readonly(),
|
|
4490
4607
|
"body": string().readonly(),
|
|
4491
4608
|
"attachments": union([_undefined(), array(object({
|
|
@@ -4507,7 +4624,8 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
4507
4624
|
"kind": union([
|
|
4508
4625
|
literal("accept"),
|
|
4509
4626
|
literal("close"),
|
|
4510
|
-
literal("reopen")
|
|
4627
|
+
literal("reopen"),
|
|
4628
|
+
literal("promote")
|
|
4511
4629
|
]).readonly(),
|
|
4512
4630
|
"releasedClaimRefs": union([_undefined(), array(intersection(string(), unknown()))]).readonly().optional(),
|
|
4513
4631
|
"completedClaimRefs": union([_undefined(), array(intersection(string(), unknown()))]).readonly().optional(),
|
|
@@ -4633,7 +4751,8 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
4633
4751
|
const _wowyuarm_dsh_agent_team_agentTeam_reply_parameter_0$schema = object({
|
|
4634
4752
|
"requestId": intersection(string(), unknown()).readonly(),
|
|
4635
4753
|
"workspaceId": intersection(string(), unknown()).readonly(),
|
|
4636
|
-
"
|
|
4754
|
+
"threadRef": intersection(string(), unknown()).readonly().optional(),
|
|
4755
|
+
"taskRef": intersection(string(), unknown()).readonly().optional(),
|
|
4637
4756
|
"body": string().readonly(),
|
|
4638
4757
|
"baseRevision": number().readonly(),
|
|
4639
4758
|
"recipients": array(intersection(string(), unknown())).readonly().optional(),
|
|
@@ -4644,7 +4763,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
4644
4763
|
const _wowyuarm_dsh_agent_team_agentTeam_reply_result$schema = union([
|
|
4645
4764
|
object({
|
|
4646
4765
|
"kind": literal("unread_required").readonly(),
|
|
4647
|
-
"taskRef": intersection(string(), unknown()).readonly(),
|
|
4766
|
+
"taskRef": intersection(string(), unknown()).readonly().optional(),
|
|
4648
4767
|
"threadRef": intersection(string(), unknown()).readonly(),
|
|
4649
4768
|
"revision": number().readonly(),
|
|
4650
4769
|
"unreadCount": number().readonly(),
|
|
@@ -4652,7 +4771,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
4652
4771
|
}),
|
|
4653
4772
|
object({
|
|
4654
4773
|
"kind": literal("stale_revision").readonly(),
|
|
4655
|
-
"taskRef": intersection(string(), unknown()).readonly(),
|
|
4774
|
+
"taskRef": intersection(string(), unknown()).readonly().optional(),
|
|
4656
4775
|
"threadRef": intersection(string(), unknown()).readonly(),
|
|
4657
4776
|
"expectedRevision": number().readonly(),
|
|
4658
4777
|
"revision": number().readonly()
|
|
@@ -4687,7 +4806,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
4687
4806
|
"messageRef": intersection(string(), unknown()).readonly(),
|
|
4688
4807
|
"channelRef": intersection(string(), unknown()).readonly(),
|
|
4689
4808
|
"threadRef": intersection(string(), unknown()).readonly(),
|
|
4690
|
-
"taskRef": intersection(string(), unknown()).readonly(),
|
|
4809
|
+
"taskRef": intersection(string(), unknown()).readonly().optional(),
|
|
4691
4810
|
"sender": intersection(string(), unknown()).readonly(),
|
|
4692
4811
|
"body": string().readonly(),
|
|
4693
4812
|
"attachments": union([_undefined(), array(object({
|
|
@@ -4716,10 +4835,10 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
4716
4835
|
literal("open"),
|
|
4717
4836
|
literal("accepted")
|
|
4718
4837
|
]).readonly()
|
|
4719
|
-
}).readonly(),
|
|
4838
|
+
}).readonly().optional(),
|
|
4720
4839
|
"thread": object({
|
|
4721
4840
|
"threadRef": intersection(string(), unknown()).readonly(),
|
|
4722
|
-
"taskRef": intersection(string(), unknown()).readonly(),
|
|
4841
|
+
"taskRef": intersection(string(), unknown()).readonly().optional(),
|
|
4723
4842
|
"revision": number().readonly()
|
|
4724
4843
|
}).readonly(),
|
|
4725
4844
|
"attention": array(object({
|
|
@@ -4754,7 +4873,8 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
4754
4873
|
"recipients": array(intersection(string(), unknown())).readonly().optional(),
|
|
4755
4874
|
"attachments": union([_undefined(), array(intersection(string(), unknown()))]).readonly().optional(),
|
|
4756
4875
|
"attachmentPaths": union([_undefined(), array(string())]).readonly().optional(),
|
|
4757
|
-
"confirmationToken": intersection(string(), unknown()).readonly().optional()
|
|
4876
|
+
"confirmationToken": intersection(string(), unknown()).readonly().optional(),
|
|
4877
|
+
"asTask": boolean().readonly().optional()
|
|
4758
4878
|
});
|
|
4759
4879
|
const _wowyuarm_dsh_agent_team_agentTeam_sendMessage_result$schema = union([
|
|
4760
4880
|
object({
|
|
@@ -4768,7 +4888,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
4768
4888
|
"messageRef": intersection(string(), unknown()).readonly(),
|
|
4769
4889
|
"channelRef": intersection(string(), unknown()).readonly(),
|
|
4770
4890
|
"threadRef": intersection(string(), unknown()).readonly(),
|
|
4771
|
-
"taskRef": intersection(string(), unknown()).readonly(),
|
|
4891
|
+
"taskRef": intersection(string(), unknown()).readonly().optional(),
|
|
4772
4892
|
"sender": intersection(string(), unknown()).readonly(),
|
|
4773
4893
|
"body": string().readonly(),
|
|
4774
4894
|
"attachments": union([_undefined(), array(object({
|
|
@@ -4797,10 +4917,10 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
4797
4917
|
literal("open"),
|
|
4798
4918
|
literal("accepted")
|
|
4799
4919
|
]).readonly()
|
|
4800
|
-
}).readonly(),
|
|
4920
|
+
}).readonly().optional(),
|
|
4801
4921
|
"thread": object({
|
|
4802
4922
|
"threadRef": intersection(string(), unknown()).readonly(),
|
|
4803
|
-
"taskRef": intersection(string(), unknown()).readonly(),
|
|
4923
|
+
"taskRef": intersection(string(), unknown()).readonly().optional(),
|
|
4804
4924
|
"revision": number().readonly()
|
|
4805
4925
|
}).readonly(),
|
|
4806
4926
|
"attention": array(object({
|
|
@@ -4838,7 +4958,8 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
4838
4958
|
]);
|
|
4839
4959
|
const _wowyuarm_dsh_agent_team_agentTeam_threadHistory_parameter_0$schema = object({
|
|
4840
4960
|
"workspaceId": intersection(string(), unknown()).readonly(),
|
|
4841
|
-
"
|
|
4961
|
+
"threadRef": intersection(string(), unknown()).readonly().optional(),
|
|
4962
|
+
"taskRef": intersection(string(), unknown()).readonly().optional(),
|
|
4842
4963
|
"beforeSequence": number().readonly().optional(),
|
|
4843
4964
|
"limit": number().readonly().optional()
|
|
4844
4965
|
});
|
|
@@ -4859,17 +4980,17 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
4859
4980
|
literal("open"),
|
|
4860
4981
|
literal("accepted")
|
|
4861
4982
|
]).readonly()
|
|
4862
|
-
}).readonly(),
|
|
4983
|
+
}).readonly().optional(),
|
|
4863
4984
|
"thread": object({
|
|
4864
4985
|
"threadRef": intersection(string(), unknown()).readonly(),
|
|
4865
|
-
"taskRef": intersection(string(), unknown()).readonly(),
|
|
4986
|
+
"taskRef": intersection(string(), unknown()).readonly().optional(),
|
|
4866
4987
|
"revision": number().readonly()
|
|
4867
4988
|
}).readonly(),
|
|
4868
4989
|
"anchor": object({
|
|
4869
4990
|
"messageRef": intersection(string(), unknown()).readonly(),
|
|
4870
4991
|
"channelRef": intersection(string(), unknown()).readonly(),
|
|
4871
4992
|
"threadRef": intersection(string(), unknown()).readonly(),
|
|
4872
|
-
"taskRef": intersection(string(), unknown()).readonly(),
|
|
4993
|
+
"taskRef": intersection(string(), unknown()).readonly().optional(),
|
|
4873
4994
|
"sender": intersection(string(), unknown()).readonly(),
|
|
4874
4995
|
"body": string().readonly(),
|
|
4875
4996
|
"attachments": union([_undefined(), array(object({
|
|
@@ -4903,7 +5024,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
4903
5024
|
"messageRef": intersection(string(), unknown()).readonly(),
|
|
4904
5025
|
"channelRef": intersection(string(), unknown()).readonly(),
|
|
4905
5026
|
"threadRef": intersection(string(), unknown()).readonly(),
|
|
4906
|
-
"taskRef": intersection(string(), unknown()).readonly(),
|
|
5027
|
+
"taskRef": intersection(string(), unknown()).readonly().optional(),
|
|
4907
5028
|
"sender": intersection(string(), unknown()).readonly(),
|
|
4908
5029
|
"body": string().readonly(),
|
|
4909
5030
|
"attachments": union([_undefined(), array(object({
|
|
@@ -4925,7 +5046,8 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
4925
5046
|
"kind": union([
|
|
4926
5047
|
literal("accept"),
|
|
4927
5048
|
literal("close"),
|
|
4928
|
-
literal("reopen")
|
|
5049
|
+
literal("reopen"),
|
|
5050
|
+
literal("promote")
|
|
4929
5051
|
]).readonly(),
|
|
4930
5052
|
"releasedClaimRefs": union([_undefined(), array(intersection(string(), unknown()))]).readonly().optional(),
|
|
4931
5053
|
"completedClaimRefs": union([_undefined(), array(intersection(string(), unknown()))]).readonly().optional(),
|
|
@@ -4964,13 +5086,14 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
4964
5086
|
});
|
|
4965
5087
|
const _wowyuarm_dsh_agent_team_agentTeam_threadObservations_parameter_0$schema = object({
|
|
4966
5088
|
"workspaceId": intersection(string(), unknown()).readonly(),
|
|
4967
|
-
"
|
|
5089
|
+
"threadRef": intersection(string(), unknown()).readonly().optional(),
|
|
5090
|
+
"taskRef": intersection(string(), unknown()).readonly().optional(),
|
|
4968
5091
|
"limit": number().readonly().optional()
|
|
4969
5092
|
});
|
|
4970
5093
|
const _wowyuarm_dsh_agent_team_agentTeam_threadObservations_result$schema = object({ "items": array(object({
|
|
4971
5094
|
"sequence": number().readonly(),
|
|
4972
5095
|
"threadRef": intersection(string(), unknown()).readonly(),
|
|
4973
|
-
"taskRef": intersection(string(), unknown()).readonly(),
|
|
5096
|
+
"taskRef": intersection(string(), unknown()).readonly().optional(),
|
|
4974
5097
|
"memberId": intersection(string(), unknown()).readonly(),
|
|
4975
5098
|
"action": union([literal("follow"), literal("unfollow")]).readonly()
|
|
4976
5099
|
})).readonly() });
|
|
@@ -5089,7 +5212,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
5089
5212
|
})).readonly(),
|
|
5090
5213
|
"threads": array(object({
|
|
5091
5214
|
"threadRef": intersection(string(), unknown()).readonly(),
|
|
5092
|
-
"taskRef": intersection(string(), unknown()).readonly(),
|
|
5215
|
+
"taskRef": intersection(string(), unknown()).readonly().optional(),
|
|
5093
5216
|
"revision": number().readonly()
|
|
5094
5217
|
})).readonly(),
|
|
5095
5218
|
"taskNumbers": array(object({
|
|
@@ -5101,7 +5224,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
5101
5224
|
"messageRef": intersection(string(), unknown()).readonly(),
|
|
5102
5225
|
"channelRef": intersection(string(), unknown()).readonly(),
|
|
5103
5226
|
"threadRef": intersection(string(), unknown()).readonly(),
|
|
5104
|
-
"taskRef": intersection(string(), unknown()).readonly(),
|
|
5227
|
+
"taskRef": intersection(string(), unknown()).readonly().optional(),
|
|
5105
5228
|
"sender": intersection(string(), unknown()).readonly(),
|
|
5106
5229
|
"body": string().readonly(),
|
|
5107
5230
|
"attachments": union([_undefined(), array(object({
|
|
@@ -5131,13 +5254,13 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
5131
5254
|
literal("open"),
|
|
5132
5255
|
literal("accepted")
|
|
5133
5256
|
]).readonly()
|
|
5134
|
-
}).readonly(),
|
|
5257
|
+
}).readonly().optional(),
|
|
5135
5258
|
"thread": object({
|
|
5136
5259
|
"threadRef": intersection(string(), unknown()).readonly(),
|
|
5137
|
-
"taskRef": intersection(string(), unknown()).readonly(),
|
|
5260
|
+
"taskRef": intersection(string(), unknown()).readonly().optional(),
|
|
5138
5261
|
"revision": number().readonly()
|
|
5139
5262
|
}).readonly(),
|
|
5140
|
-
"taskNumber": number().readonly(),
|
|
5263
|
+
"taskNumber": number().readonly().optional(),
|
|
5141
5264
|
"messageCount": number().readonly()
|
|
5142
5265
|
})).readonly(),
|
|
5143
5266
|
"claims": array(object({
|
|
@@ -5158,7 +5281,8 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
5158
5281
|
"kind": union([
|
|
5159
5282
|
literal("accept"),
|
|
5160
5283
|
literal("close"),
|
|
5161
|
-
literal("reopen")
|
|
5284
|
+
literal("reopen"),
|
|
5285
|
+
literal("promote")
|
|
5162
5286
|
]).readonly(),
|
|
5163
5287
|
"releasedClaimRefs": union([_undefined(), array(intersection(string(), unknown()))]).readonly().optional(),
|
|
5164
5288
|
"completedClaimRefs": union([_undefined(), array(intersection(string(), unknown()))]).readonly().optional(),
|
|
@@ -5220,7 +5344,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
5220
5344
|
},
|
|
5221
5345
|
sourceLocation: {
|
|
5222
5346
|
"file": "packages/agent-team/src/index.ts",
|
|
5223
|
-
"line":
|
|
5347
|
+
"line": 397,
|
|
5224
5348
|
"column": 9
|
|
5225
5349
|
}
|
|
5226
5350
|
},
|
|
@@ -5247,7 +5371,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
5247
5371
|
},
|
|
5248
5372
|
sourceLocation: {
|
|
5249
5373
|
"file": "packages/agent-team/src/index.ts",
|
|
5250
|
-
"line":
|
|
5374
|
+
"line": 738,
|
|
5251
5375
|
"column": 9
|
|
5252
5376
|
}
|
|
5253
5377
|
},
|
|
@@ -5275,7 +5399,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
5275
5399
|
},
|
|
5276
5400
|
sourceLocation: {
|
|
5277
5401
|
"file": "packages/agent-team/src/index.ts",
|
|
5278
|
-
"line":
|
|
5402
|
+
"line": 334,
|
|
5279
5403
|
"column": 9
|
|
5280
5404
|
}
|
|
5281
5405
|
},
|
|
@@ -5302,7 +5426,34 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
5302
5426
|
},
|
|
5303
5427
|
sourceLocation: {
|
|
5304
5428
|
"file": "packages/agent-team/src/index.ts",
|
|
5305
|
-
"line":
|
|
5429
|
+
"line": 628,
|
|
5430
|
+
"column": 9
|
|
5431
|
+
}
|
|
5432
|
+
},
|
|
5433
|
+
{
|
|
5434
|
+
id: "@wowyuarm/dsh-agent-team#agentTeam/clearMemberContext",
|
|
5435
|
+
service: "agentTeam",
|
|
5436
|
+
namespace: "agentTeam",
|
|
5437
|
+
method: "clearMemberContext",
|
|
5438
|
+
invocation: { kind: "direct" },
|
|
5439
|
+
parameters: [{
|
|
5440
|
+
name: "request",
|
|
5441
|
+
wire: "request",
|
|
5442
|
+
source: "json",
|
|
5443
|
+
codec: {
|
|
5444
|
+
mode: "strict",
|
|
5445
|
+
typeSymbol: "@wowyuarm/dsh-agent-team/types#AgentTeamClearMemberContextRequest",
|
|
5446
|
+
schema: _wowyuarm_dsh_agent_team_agentTeam_clearMemberContext_parameter_0$schema
|
|
5447
|
+
}
|
|
5448
|
+
}],
|
|
5449
|
+
result: {
|
|
5450
|
+
mode: "strict",
|
|
5451
|
+
typeSymbol: "@wowyuarm/dsh-agent-team/types#AgentTeamClearMemberContextResult",
|
|
5452
|
+
schema: _wowyuarm_dsh_agent_team_agentTeam_clearMemberContext_result$schema
|
|
5453
|
+
},
|
|
5454
|
+
sourceLocation: {
|
|
5455
|
+
"file": "packages/agent-team/src/index.ts",
|
|
5456
|
+
"line": 489,
|
|
5306
5457
|
"column": 9
|
|
5307
5458
|
}
|
|
5308
5459
|
},
|
|
@@ -5329,7 +5480,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
5329
5480
|
},
|
|
5330
5481
|
sourceLocation: {
|
|
5331
5482
|
"file": "packages/agent-team/src/index.ts",
|
|
5332
|
-
"line":
|
|
5483
|
+
"line": 375,
|
|
5333
5484
|
"column": 9
|
|
5334
5485
|
}
|
|
5335
5486
|
},
|
|
@@ -5356,7 +5507,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
5356
5507
|
},
|
|
5357
5508
|
sourceLocation: {
|
|
5358
5509
|
"file": "packages/agent-team/src/index.ts",
|
|
5359
|
-
"line":
|
|
5510
|
+
"line": 724,
|
|
5360
5511
|
"column": 9
|
|
5361
5512
|
}
|
|
5362
5513
|
},
|
|
@@ -5383,7 +5534,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
5383
5534
|
},
|
|
5384
5535
|
sourceLocation: {
|
|
5385
5536
|
"file": "packages/agent-team/src/index.ts",
|
|
5386
|
-
"line":
|
|
5537
|
+
"line": 747,
|
|
5387
5538
|
"column": 3
|
|
5388
5539
|
}
|
|
5389
5540
|
},
|
|
@@ -5410,7 +5561,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
5410
5561
|
},
|
|
5411
5562
|
sourceLocation: {
|
|
5412
5563
|
"file": "packages/agent-team/src/index.ts",
|
|
5413
|
-
"line":
|
|
5564
|
+
"line": 648,
|
|
5414
5565
|
"column": 9
|
|
5415
5566
|
}
|
|
5416
5567
|
},
|
|
@@ -5438,10 +5589,37 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
5438
5589
|
},
|
|
5439
5590
|
sourceLocation: {
|
|
5440
5591
|
"file": "packages/agent-team/src/index.ts",
|
|
5441
|
-
"line":
|
|
5592
|
+
"line": 325,
|
|
5442
5593
|
"column": 3
|
|
5443
5594
|
}
|
|
5444
5595
|
},
|
|
5596
|
+
{
|
|
5597
|
+
id: "@wowyuarm/dsh-agent-team#agentTeam/promoteThread",
|
|
5598
|
+
service: "agentTeam",
|
|
5599
|
+
namespace: "agentTeam",
|
|
5600
|
+
method: "promoteThread",
|
|
5601
|
+
invocation: { kind: "direct" },
|
|
5602
|
+
parameters: [{
|
|
5603
|
+
name: "request",
|
|
5604
|
+
wire: "request",
|
|
5605
|
+
source: "json",
|
|
5606
|
+
codec: {
|
|
5607
|
+
mode: "strict",
|
|
5608
|
+
typeSymbol: "@wowyuarm/dsh-agent-team/types#AgentTeamPromoteThreadRequest",
|
|
5609
|
+
schema: _wowyuarm_dsh_agent_team_agentTeam_promoteThread_parameter_0$schema
|
|
5610
|
+
}
|
|
5611
|
+
}],
|
|
5612
|
+
result: {
|
|
5613
|
+
mode: "strict",
|
|
5614
|
+
typeSymbol: "@wowyuarm/dsh-agent-team/types#AgentTeamPromoteThreadResult",
|
|
5615
|
+
schema: _wowyuarm_dsh_agent_team_agentTeam_promoteThread_result$schema
|
|
5616
|
+
},
|
|
5617
|
+
sourceLocation: {
|
|
5618
|
+
"file": "packages/agent-team/src/index.ts",
|
|
5619
|
+
"line": 638,
|
|
5620
|
+
"column": 9
|
|
5621
|
+
}
|
|
5622
|
+
},
|
|
5445
5623
|
{
|
|
5446
5624
|
id: "@wowyuarm/dsh-agent-team#agentTeam/putAttachment",
|
|
5447
5625
|
service: "agentTeam",
|
|
@@ -5465,7 +5643,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
5465
5643
|
},
|
|
5466
5644
|
sourceLocation: {
|
|
5467
5645
|
"file": "packages/agent-team/src/index.ts",
|
|
5468
|
-
"line":
|
|
5646
|
+
"line": 711,
|
|
5469
5647
|
"column": 9
|
|
5470
5648
|
}
|
|
5471
5649
|
},
|
|
@@ -5492,7 +5670,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
5492
5670
|
},
|
|
5493
5671
|
sourceLocation: {
|
|
5494
5672
|
"file": "packages/agent-team/src/index.ts",
|
|
5495
|
-
"line":
|
|
5673
|
+
"line": 754,
|
|
5496
5674
|
"column": 9
|
|
5497
5675
|
}
|
|
5498
5676
|
},
|
|
@@ -5519,7 +5697,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
5519
5697
|
},
|
|
5520
5698
|
sourceLocation: {
|
|
5521
5699
|
"file": "packages/agent-team/src/index.ts",
|
|
5522
|
-
"line":
|
|
5700
|
+
"line": 450,
|
|
5523
5701
|
"column": 9
|
|
5524
5702
|
}
|
|
5525
5703
|
},
|
|
@@ -5546,7 +5724,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
5546
5724
|
},
|
|
5547
5725
|
sourceLocation: {
|
|
5548
5726
|
"file": "packages/agent-team/src/index.ts",
|
|
5549
|
-
"line":
|
|
5727
|
+
"line": 659,
|
|
5550
5728
|
"column": 9
|
|
5551
5729
|
}
|
|
5552
5730
|
},
|
|
@@ -5573,7 +5751,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
5573
5751
|
},
|
|
5574
5752
|
sourceLocation: {
|
|
5575
5753
|
"file": "packages/agent-team/src/index.ts",
|
|
5576
|
-
"line":
|
|
5754
|
+
"line": 732,
|
|
5577
5755
|
"column": 9
|
|
5578
5756
|
}
|
|
5579
5757
|
},
|
|
@@ -5600,7 +5778,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
5600
5778
|
},
|
|
5601
5779
|
sourceLocation: {
|
|
5602
5780
|
"file": "packages/agent-team/src/index.ts",
|
|
5603
|
-
"line":
|
|
5781
|
+
"line": 312,
|
|
5604
5782
|
"column": 3
|
|
5605
5783
|
}
|
|
5606
5784
|
},
|
|
@@ -5627,7 +5805,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
5627
5805
|
},
|
|
5628
5806
|
sourceLocation: {
|
|
5629
5807
|
"file": "packages/agent-team/src/index.ts",
|
|
5630
|
-
"line":
|
|
5808
|
+
"line": 668,
|
|
5631
5809
|
"column": 9
|
|
5632
5810
|
}
|
|
5633
5811
|
},
|
|
@@ -5654,7 +5832,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
5654
5832
|
},
|
|
5655
5833
|
sourceLocation: {
|
|
5656
5834
|
"file": "packages/agent-team/src/index.ts",
|
|
5657
|
-
"line":
|
|
5835
|
+
"line": 770,
|
|
5658
5836
|
"column": 3
|
|
5659
5837
|
}
|
|
5660
5838
|
},
|
|
@@ -5681,7 +5859,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
5681
5859
|
},
|
|
5682
5860
|
sourceLocation: {
|
|
5683
5861
|
"file": "packages/agent-team/src/index.ts",
|
|
5684
|
-
"line":
|
|
5862
|
+
"line": 763,
|
|
5685
5863
|
"column": 3
|
|
5686
5864
|
}
|
|
5687
5865
|
},
|
|
@@ -5708,7 +5886,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
5708
5886
|
},
|
|
5709
5887
|
sourceLocation: {
|
|
5710
5888
|
"file": "packages/agent-team/src/index.ts",
|
|
5711
|
-
"line":
|
|
5889
|
+
"line": 387,
|
|
5712
5890
|
"column": 9
|
|
5713
5891
|
}
|
|
5714
5892
|
},
|
|
@@ -5735,7 +5913,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
5735
5913
|
},
|
|
5736
5914
|
sourceLocation: {
|
|
5737
5915
|
"file": "packages/agent-team/src/index.ts",
|
|
5738
|
-
"line":
|
|
5916
|
+
"line": 598,
|
|
5739
5917
|
"column": 9
|
|
5740
5918
|
}
|
|
5741
5919
|
},
|
|
@@ -5762,7 +5940,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
5762
5940
|
},
|
|
5763
5941
|
sourceLocation: {
|
|
5764
5942
|
"file": "packages/agent-team/src/index.ts",
|
|
5765
|
-
"line":
|
|
5943
|
+
"line": 777,
|
|
5766
5944
|
"column": 3
|
|
5767
5945
|
}
|
|
5768
5946
|
}
|
|
@@ -5770,19 +5948,19 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
5770
5948
|
};
|
|
5771
5949
|
//#endregion
|
|
5772
5950
|
//#region src/client/navigation.ts
|
|
5773
|
-
const STORAGE_KEY$
|
|
5951
|
+
const STORAGE_KEY$3 = "dsh.agent-team.navigation";
|
|
5774
5952
|
function readSnapshot() {
|
|
5775
5953
|
if (typeof localStorage === "undefined") return { mode: "conversation" };
|
|
5776
5954
|
try {
|
|
5777
5955
|
const parsed = JSON.parse(localStorage.getItem("dsh.agent-team.navigation") ?? "");
|
|
5778
|
-
const hasThread = typeof parsed.
|
|
5956
|
+
const hasThread = typeof parsed.threadRef === "string";
|
|
5779
5957
|
return {
|
|
5780
5958
|
mode: parsed.mode === "team" ? "team" : "conversation",
|
|
5781
5959
|
...typeof parsed.workspaceId === "string" ? { workspaceId: parsed.workspaceId } : {},
|
|
5782
5960
|
...typeof parsed.channelRef === "string" ? { channelRef: parsed.channelRef } : {},
|
|
5783
5961
|
...hasThread ? {
|
|
5784
|
-
taskRef: parsed.taskRef,
|
|
5785
5962
|
threadRef: parsed.threadRef,
|
|
5963
|
+
...typeof parsed.taskRef === "string" ? { taskRef: parsed.taskRef } : {},
|
|
5786
5964
|
...typeof parsed.taskNumber === "number" && Number.isInteger(parsed.taskNumber) && parsed.taskNumber > 0 ? { taskNumber: parsed.taskNumber } : {}
|
|
5787
5965
|
} : {}
|
|
5788
5966
|
};
|
|
@@ -5794,7 +5972,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
5794
5972
|
if (typeof localStorage === "undefined") return;
|
|
5795
5973
|
try {
|
|
5796
5974
|
const { mode, workspaceId, channelRef, taskRef, threadRef, taskNumber } = snapshot;
|
|
5797
|
-
localStorage.setItem(STORAGE_KEY$
|
|
5975
|
+
localStorage.setItem(STORAGE_KEY$3, JSON.stringify({
|
|
5798
5976
|
mode,
|
|
5799
5977
|
...workspaceId === void 0 ? {} : { workspaceId },
|
|
5800
5978
|
...channelRef === void 0 ? {} : { channelRef },
|
|
@@ -5832,9 +6010,9 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
5832
6010
|
this.clearMemberSession();
|
|
5833
6011
|
this.setChannel(channelRef);
|
|
5834
6012
|
},
|
|
5835
|
-
selectThread: (
|
|
6013
|
+
selectThread: (threadRef, channelRef, taskRef, taskNumber) => {
|
|
5836
6014
|
this.clearMemberSession();
|
|
5837
|
-
this.setThread(
|
|
6015
|
+
this.setThread(threadRef, channelRef, taskRef, taskNumber);
|
|
5838
6016
|
},
|
|
5839
6017
|
backToWorkspace: () => {
|
|
5840
6018
|
this.clearMemberSession();
|
|
@@ -5905,18 +6083,18 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
5905
6083
|
this.snapshot = base;
|
|
5906
6084
|
this.commit();
|
|
5907
6085
|
}
|
|
5908
|
-
setThread(
|
|
6086
|
+
setThread(threadRef, channelRef, taskRef, taskNumber) {
|
|
5909
6087
|
if (this.snapshot.threadRef === threadRef && this.snapshot.taskRef === taskRef && this.snapshot.channelRef === channelRef && this.snapshot.taskNumber === taskNumber) return;
|
|
5910
|
-
if (threadRef === void 0
|
|
6088
|
+
if (threadRef === void 0) {
|
|
5911
6089
|
const { taskRef: _taskRef, threadRef: _threadRef, taskNumber: _taskNumber, ...base } = this.snapshot;
|
|
5912
6090
|
this.snapshot = base;
|
|
5913
6091
|
} else {
|
|
5914
6092
|
const { channelRef: _channelRef, taskRef: _taskRef, threadRef: _threadRef, taskNumber: _taskNumber, ...base } = this.snapshot;
|
|
5915
6093
|
this.snapshot = {
|
|
5916
6094
|
...base,
|
|
5917
|
-
taskRef,
|
|
5918
6095
|
threadRef,
|
|
5919
6096
|
...channelRef === void 0 ? {} : { channelRef },
|
|
6097
|
+
...taskRef === void 0 ? {} : { taskRef },
|
|
5920
6098
|
...taskNumber === void 0 ? {} : { taskNumber }
|
|
5921
6099
|
};
|
|
5922
6100
|
}
|
|
@@ -6005,7 +6183,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
6005
6183
|
};
|
|
6006
6184
|
//#endregion
|
|
6007
6185
|
//#region src/client/drafts.ts
|
|
6008
|
-
const STORAGE_KEY$
|
|
6186
|
+
const STORAGE_KEY$2 = "dsh.agent-team.drafts.v1";
|
|
6009
6187
|
/** Retention ceiling; the oldest savedAt entries fall out first. */
|
|
6010
6188
|
const LIMIT = 50;
|
|
6011
6189
|
const EMPTY = Object.freeze({
|
|
@@ -6040,7 +6218,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
6040
6218
|
if (typeof localStorage === "undefined") return;
|
|
6041
6219
|
try {
|
|
6042
6220
|
const payload = Object.fromEntries([...entries].map(([key, entry]) => [key, entry]));
|
|
6043
|
-
localStorage.setItem(STORAGE_KEY$
|
|
6221
|
+
localStorage.setItem(STORAGE_KEY$2, JSON.stringify(payload));
|
|
6044
6222
|
} catch {}
|
|
6045
6223
|
}
|
|
6046
6224
|
/**
|
|
@@ -6092,7 +6270,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
6092
6270
|
reset() {
|
|
6093
6271
|
this.entries = /* @__PURE__ */ new Map();
|
|
6094
6272
|
this.snapshots.clear();
|
|
6095
|
-
if (typeof localStorage !== "undefined") localStorage.removeItem(STORAGE_KEY$
|
|
6273
|
+
if (typeof localStorage !== "undefined") localStorage.removeItem(STORAGE_KEY$2);
|
|
6096
6274
|
for (const listener of this.listeners) listener();
|
|
6097
6275
|
}
|
|
6098
6276
|
/** Re-read persisted content — what a fresh page load starts from. */
|
|
@@ -6382,7 +6560,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
6382
6560
|
const mintRequestId = () => crypto.randomUUID();
|
|
6383
6561
|
//#endregion
|
|
6384
6562
|
//#region \0dsh-css:/home/yu/projects/dsh-agent-team/packages/client-agent-team/src/client/composer.module.css.mjs
|
|
6385
|
-
const css$5 = ".x9jGQq_root{padding:0 var(--dsh-composer-side-clearance,16px) 8px;flex-direction:column;align-items:center;display:flex}.x9jGQq_card{box-sizing:border-box;width:100%;max-width:var(--dsh-composer-card-max-width,780px);border:1px solid var(--dsw-alias-border-l2-darkmode-thin);background:var(--dsw-specific-input-major,var(--dsw-alias-bg-layer-1));box-shadow:var(--dsw-shadow-lv2);border-radius:22px;flex-direction:column;gap:6px;padding:10px 0 0;display:flex;position:relative}.x9jGQq_inputArea{min-height:28px;position:relative}.x9jGQq_inputArea textarea{box-sizing:border-box;resize:none;width:100%;min-height:28px;max-height:336px;color:var(--dsw-alias-label-primary,var(--dsw-alias-label-primary));font:inherit;white-space:pre-wrap;overflow-wrap:anywhere;background:0 0;border:0;outline:0;padding:4px 12px 0 16px;font-size:15px;line-height:24px;display:block;overflow-y:auto}.x9jGQq_inputArea textarea::placeholder{color:var(--dsw-alias-label-caption,var(--dsw-alias-label-tertiary))}.x9jGQq_memberSessionRoot{padding:0 var(--dsh-composer-side-clearance) 8px}.x9jGQq_memberSessionCard{font-family:var(--dsw-font-family);gap:6px;padding-top:10px;font-size:16px;line-height:24px}.x9jGQq_memberSessionInputArea textarea{min-height:28px;color:var(--dsw-alias-label-primary);caret-color:var(--dsw-alias-state-business-primary);font-family:var(--dsw-font-family);font-size:inherit;line-height:inherit;padding:4px 12px 0 16px}.x9jGQq_memberSessionStatus{width:100%;max-width:var(--dsh-composer-card-max-width);background:var(--dsw-alias-interactive-bg-hover);color:var(--dsw-alias-state-error-primary);border-radius:8px;margin:0 0 6px;padding:4px 8px;font-size:12px;line-height:18px}.x9jGQq_memberSessionToolbar{min-width:0;padding:2px 8px 6px}.x9jGQq_memberSessionPrimary{background:var(--dsw-alias-button-info-fill);border-radius:999px;place-items:center;display:grid;transform:translateY(-2px)}.x9jGQq_memberSessionPrimary:hover:not(:disabled){background:var(--dsw-alias-button-info-hover)}.x9jGQq_memberSessionPrimary:focus-visible{outline:2px solid var(--dsw-alias-state-business-primary);outline-offset:2px}.x9jGQq_memberSessionPrimary:disabled{cursor:default;opacity:.4}.x9jGQq_inputArea textarea:disabled{cursor:not-allowed;opacity:.55}.x9jGQq_mentionMenu{z-index:10;border:1px solid var(--dsw-alias-border-inverted);background:var(--dsw-specific-menu);max-height:min(320px,40vh);box-shadow:var(--dsw-shadow-lv3);border-radius:12px;padding:4px;position:absolute;bottom:calc(100% + 12px);left:0;right:0;overflow-y:auto}.x9jGQq_mentionOption{width:100%;min-height:40px;color:var(--dsw-alias-label-primary,var(--dsw-alias-label-primary));cursor:pointer;text-align:left;background:0 0;border:0;border-radius:10px;grid-template-columns:16px minmax(0,auto) minmax(0,1fr);align-items:center;gap:8px;padding:8px 10px;font-size:14px;line-height:22px;display:grid}.x9jGQq_mentionOption:hover,.x9jGQq_mentionOption[aria-selected=true]{background:var(--dsw-alias-interactive-bg-hover)}.x9jGQq_mentionName{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.x9jGQq_mentionDescription{min-width:0;color:var(--dsw-alias-label-tertiary,var(--dsw-alias-label-tertiary));text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.x9jGQq_toolbar{justify-content:flex-end;align-items:center;gap:6px;min-height:34px;padding:2px 8px 6px;display:flex}.x9jGQq_attachButton{background:var(--dsw-specific-selector);color:var(--dsw-alias-label-primary);cursor:pointer;border:0;border-radius:999px;flex:none;place-items:center;width:28px;height:28px;margin-right:auto;display:grid}.x9jGQq_attachButton:hover:not(:disabled){background:var(--dsw-alias-interactive-bg-hover-solid)}.x9jGQq_attachButton:disabled{cursor:default;opacity:.5}.x9jGQq_attachButton:focus-visible{outline:2px solid var(--dsw-alias-state-business-primary,var(--dsw-specific-selector));outline-offset:1px}.x9jGQq_fileInput{display:none}.x9jGQq_fileChips{flex-wrap:wrap;gap:4px;margin:0;padding:4px 8px 0;list-style:none;display:flex}.x9jGQq_fileChip{background:var(--dsw-alias-interactive-bg-hover);border-radius:6px;align-items:center;gap:4px;max-width:100%;padding:2px 4px 2px 8px;display:inline-flex}.x9jGQq_fileChipSize{color:var(--dsw-alias-label-tertiary);margin-left:6px}.x9jGQq_imageChip{align-items:center;display:flex}.x9jGQq_imageChipPreview{border:1px solid var(--dsw-alias-border-l2);object-fit:cover;border-radius:4px;width:56px;height:40px}.x9jGQq_fileChipName{text-overflow:ellipsis;white-space:nowrap;max-width:220px;font-size:11px;line-height:16px;overflow:hidden}.x9jGQq_fileChipRemove{color:var(--dsw-alias-label-tertiary);cursor:pointer;background:0 0;border:0;border-radius:4px;justify-content:center;align-items:center;width:16px;height:16px;padding:0;font-size:12px;display:inline-flex}.x9jGQq_fileChipRemove:hover,.x9jGQq_fileChipRemove:focus-visible{color:var(--dsw-alias-label-primary);outline:none}.x9jGQq_sendButton{background:var(--dsw-alias-button-info-fill,var(--dsw-alias-button-primary-fill));color:#fff;cursor:pointer;border:0;border-radius:50%;justify-content:center;align-items:center;width:34px;height:34px;padding:0;transition:background-color .1s,opacity .1s;display:inline-flex}.x9jGQq_sendButton:hover:not(:disabled){background:var(--dsw-alias-button-info-hover,var(--dsw-alias-button-primary-hover))}.x9jGQq_sendButton:focus-visible{outline:2px solid var(--dsw-alias-state-business-primary);outline-offset:2px}.x9jGQq_sendButton:disabled{cursor:not-allowed;opacity:.4}.x9jGQq_confirmation{color:var(--dsw-alias-label-tertiary);align-self:stretch;margin:0;padding:0 16px;font-size:12px;line-height:18px}.x9jGQq_notifyRow{color:var(--dsw-alias-label-tertiary,var(--dsw-alias-label-tertiary));overflow-wrap:anywhere;margin:0;padding:0 16px;font-size:12px;line-height:18px}.x9jGQq_error{color:var(--dsw-alias-state-error-primary);align-self:stretch;margin:0;padding:0 4px 2px;font-size:12px;line-height:18px}@media (width<=600px){.x9jGQq_mentionOption{grid-template-columns:16px minmax(0,1fr);min-height:36px;padding-block:6px}.x9jGQq_mentionDescription{display:none}}@media (prefers-reduced-motion:reduce){.x9jGQq_sendButton{transition:none}}";
|
|
6563
|
+
const css$5 = ".x9jGQq_root{padding:0 var(--dsh-composer-side-clearance,16px) 8px;flex-direction:column;align-items:center;display:flex}.x9jGQq_card{box-sizing:border-box;width:100%;max-width:var(--dsh-composer-card-max-width,780px);border:1px solid var(--dsw-alias-border-l2-darkmode-thin);background:var(--dsw-specific-input-major,var(--dsw-alias-bg-layer-1));box-shadow:var(--dsw-shadow-lv2);border-radius:22px;flex-direction:column;gap:6px;padding:10px 0 0;display:flex;position:relative}.x9jGQq_inputArea{min-height:28px;position:relative}.x9jGQq_inputArea textarea{box-sizing:border-box;resize:none;width:100%;min-height:28px;max-height:336px;color:var(--dsw-alias-label-primary,var(--dsw-alias-label-primary));font:inherit;white-space:pre-wrap;overflow-wrap:anywhere;background:0 0;border:0;outline:0;padding:4px 12px 0 16px;font-size:15px;line-height:24px;display:block;overflow-y:auto}.x9jGQq_inputArea textarea::placeholder{color:var(--dsw-alias-label-caption,var(--dsw-alias-label-tertiary))}.x9jGQq_memberSessionRoot{padding:0 var(--dsh-composer-side-clearance) 8px}.x9jGQq_memberSessionCard{font-family:var(--dsw-font-family);gap:6px;padding-top:10px;font-size:16px;line-height:24px}.x9jGQq_memberSessionInputArea textarea{min-height:28px;color:var(--dsw-alias-label-primary);caret-color:var(--dsw-alias-state-business-primary);font-family:var(--dsw-font-family);font-size:inherit;line-height:inherit;padding:4px 12px 0 16px}.x9jGQq_memberSessionStatus{width:100%;max-width:var(--dsh-composer-card-max-width);background:var(--dsw-alias-interactive-bg-hover);color:var(--dsw-alias-state-error-primary);border-radius:8px;margin:0 0 6px;padding:4px 8px;font-size:12px;line-height:18px}.x9jGQq_memberSessionToolbar{min-width:0;padding:2px 8px 6px}.x9jGQq_memberSessionPrimary{background:var(--dsw-alias-button-info-fill);border-radius:999px;place-items:center;display:grid;transform:translateY(-2px)}.x9jGQq_memberSessionPrimary:hover:not(:disabled){background:var(--dsw-alias-button-info-hover)}.x9jGQq_memberSessionPrimary:focus-visible{outline:2px solid var(--dsw-alias-state-business-primary);outline-offset:2px}.x9jGQq_memberSessionPrimary:disabled{cursor:default;opacity:.4}.x9jGQq_inputArea textarea:disabled{cursor:not-allowed;opacity:.55}.x9jGQq_mentionMenu{z-index:10;border:1px solid var(--dsw-alias-border-inverted);background:var(--dsw-specific-menu);max-height:min(320px,40vh);box-shadow:var(--dsw-shadow-lv3);border-radius:12px;padding:4px;position:absolute;bottom:calc(100% + 12px);left:0;right:0;overflow-y:auto}.x9jGQq_mentionOption{width:100%;min-height:40px;color:var(--dsw-alias-label-primary,var(--dsw-alias-label-primary));cursor:pointer;text-align:left;background:0 0;border:0;border-radius:10px;grid-template-columns:16px minmax(0,auto) minmax(0,1fr);align-items:center;gap:8px;padding:8px 10px;font-size:14px;line-height:22px;display:grid}.x9jGQq_mentionOption:hover,.x9jGQq_mentionOption[aria-selected=true]{background:var(--dsw-alias-interactive-bg-hover)}.x9jGQq_mentionName{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.x9jGQq_mentionAllDot{background:var(--dsw-alias-label-primary);border-radius:50%;justify-self:center;width:8px;height:8px}.x9jGQq_mentionDescription{min-width:0;color:var(--dsw-alias-label-tertiary,var(--dsw-alias-label-tertiary));text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.x9jGQq_toolbar{justify-content:flex-end;align-items:center;gap:6px;min-height:34px;padding:2px 8px 6px;display:flex}.x9jGQq_asTaskOn[aria-pressed=true],.x9jGQq_asTaskOn[aria-pressed=true]:hover:not(:disabled){background:var(--dsw-alias-button-primary-fill);border-color:var(--dsw-alias-button-primary-fill);color:var(--dsw-alias-label-primary-foreground)}.x9jGQq_attachButton{background:var(--dsw-specific-selector);color:var(--dsw-alias-label-primary);cursor:pointer;border:0;border-radius:999px;flex:none;place-items:center;width:28px;height:28px;margin-right:auto;display:grid}.x9jGQq_attachButton:hover:not(:disabled){background:var(--dsw-alias-interactive-bg-hover-solid)}.x9jGQq_attachButton:disabled{cursor:default;opacity:.5}.x9jGQq_attachButton:focus-visible{outline:2px solid var(--dsw-alias-state-business-primary,var(--dsw-specific-selector));outline-offset:1px}.x9jGQq_fileInput{display:none}.x9jGQq_fileChips{flex-wrap:wrap;gap:4px;margin:0;padding:4px 8px 0;list-style:none;display:flex}.x9jGQq_fileChip{background:var(--dsw-alias-interactive-bg-hover);border-radius:6px;align-items:center;gap:4px;max-width:100%;padding:2px 4px 2px 8px;display:inline-flex}.x9jGQq_fileChipSize{color:var(--dsw-alias-label-tertiary);margin-left:6px}.x9jGQq_imageChip{align-items:center;display:flex}.x9jGQq_imageChipPreview{border:1px solid var(--dsw-alias-border-l2);object-fit:cover;border-radius:4px;width:56px;height:40px}.x9jGQq_fileChipName{text-overflow:ellipsis;white-space:nowrap;max-width:220px;font-size:11px;line-height:16px;overflow:hidden}.x9jGQq_fileChipRemove{color:var(--dsw-alias-label-tertiary);cursor:pointer;background:0 0;border:0;border-radius:4px;justify-content:center;align-items:center;width:16px;height:16px;padding:0;font-size:12px;display:inline-flex}.x9jGQq_fileChipRemove:hover,.x9jGQq_fileChipRemove:focus-visible{color:var(--dsw-alias-label-primary);outline:none}.x9jGQq_sendButton{background:var(--dsw-alias-button-info-fill,var(--dsw-alias-button-primary-fill));color:#fff;cursor:pointer;border:0;border-radius:50%;justify-content:center;align-items:center;width:34px;height:34px;padding:0;transition:background-color .1s,opacity .1s;display:inline-flex}.x9jGQq_sendButton:hover:not(:disabled){background:var(--dsw-alias-button-info-hover,var(--dsw-alias-button-primary-hover))}.x9jGQq_sendButton:focus-visible{outline:2px solid var(--dsw-alias-state-business-primary);outline-offset:2px}.x9jGQq_sendButton:disabled{cursor:not-allowed;opacity:.4}.x9jGQq_confirmation{color:var(--dsw-alias-label-tertiary);align-self:stretch;margin:0;padding:0 16px;font-size:12px;line-height:18px}.x9jGQq_notifyRow{color:var(--dsw-alias-label-tertiary,var(--dsw-alias-label-tertiary));overflow-wrap:anywhere;margin:0;padding:0 16px;font-size:12px;line-height:18px}.x9jGQq_error{color:var(--dsw-alias-state-error-primary);align-self:stretch;margin:0;padding:0 4px 2px;font-size:12px;line-height:18px}@media (width<=600px){.x9jGQq_mentionOption{grid-template-columns:16px minmax(0,1fr);min-height:36px;padding-block:6px}.x9jGQq_mentionDescription{display:none}}@media (prefers-reduced-motion:reduce){.x9jGQq_sendButton{transition:none}}";
|
|
6386
6564
|
const tagId$5 = "@wowyuarm/dsh-agent-team/composer.module.css";
|
|
6387
6565
|
if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=" + JSON.stringify(tagId$5) + "]") === null) {
|
|
6388
6566
|
const tag = document.createElement("style");
|
|
@@ -6392,6 +6570,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
6392
6570
|
document.head.appendChild(tag);
|
|
6393
6571
|
}
|
|
6394
6572
|
var composer_module_css_default = {
|
|
6573
|
+
"asTaskOn": "x9jGQq_asTaskOn",
|
|
6395
6574
|
"attachButton": "x9jGQq_attachButton",
|
|
6396
6575
|
"card": "x9jGQq_card",
|
|
6397
6576
|
"confirmation": "x9jGQq_confirmation",
|
|
@@ -6411,6 +6590,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
6411
6590
|
"memberSessionRoot": "x9jGQq_memberSessionRoot",
|
|
6412
6591
|
"memberSessionStatus": "x9jGQq_memberSessionStatus",
|
|
6413
6592
|
"memberSessionToolbar": "x9jGQq_memberSessionToolbar",
|
|
6593
|
+
"mentionAllDot": "x9jGQq_mentionAllDot",
|
|
6414
6594
|
"mentionDescription": "x9jGQq_mentionDescription",
|
|
6415
6595
|
"mentionMenu": "x9jGQq_mentionMenu",
|
|
6416
6596
|
"mentionName": "x9jGQq_mentionName",
|
|
@@ -6446,6 +6626,13 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
6446
6626
|
const normalized = query.toLocaleLowerCase();
|
|
6447
6627
|
return members.filter((status) => status.presence !== "unavailable" && status.member.state !== "inactive" && status.member.handle.toLocaleLowerCase().startsWith(normalized));
|
|
6448
6628
|
}
|
|
6629
|
+
/** Every member a manual handle pick could reach: the @all expansion snapshot. */
|
|
6630
|
+
function allMentionMembers(members) {
|
|
6631
|
+
return members.filter((status) => status.presence !== "unavailable" && status.member.state !== "inactive");
|
|
6632
|
+
}
|
|
6633
|
+
function containsAllMention(draft) {
|
|
6634
|
+
return /(?:^|[^\p{L}\p{N}_])@all(?=$|[^\p{L}\p{N}_])/u.test(draft);
|
|
6635
|
+
}
|
|
6449
6636
|
/** One object URL per draft file; revoked when the draft is removed. */
|
|
6450
6637
|
const draftPreviewUrls = /* @__PURE__ */ new WeakMap();
|
|
6451
6638
|
function draftPreviewUrl(file) {
|
|
@@ -6457,7 +6644,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
6457
6644
|
}
|
|
6458
6645
|
return url;
|
|
6459
6646
|
}
|
|
6460
|
-
function TeamComposer({ members, recipients, draft, pending, confirmation, error, onDraftChange, onRecipientsChange, onSubmit, pendingFiles, onFilesChange, t }) {
|
|
6647
|
+
function TeamComposer({ members, recipients, draft, pending, confirmation, error, onDraftChange, onRecipientsChange, onSubmit, placeholder, pendingFiles, onFilesChange, asTask, onAsTaskChange, t }) {
|
|
6461
6648
|
const inputRef = (0, react.useRef)(null);
|
|
6462
6649
|
const fileInputRef = (0, react.useRef)(null);
|
|
6463
6650
|
const rootRef = (0, react.useRef)(null);
|
|
@@ -6465,9 +6652,17 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
6465
6652
|
const composingRef = (0, react.useRef)(false);
|
|
6466
6653
|
const [mention, setMention] = (0, react.useState)();
|
|
6467
6654
|
const [highlight, setHighlight] = (0, react.useState)(0);
|
|
6468
|
-
const
|
|
6469
|
-
const
|
|
6470
|
-
|
|
6655
|
+
const memberCandidates = mention === void 0 ? [] : mentionCandidates(members, mention.query);
|
|
6656
|
+
const options = mention !== void 0 && "all".startsWith(mention.query.toLocaleLowerCase()) ? [{ kind: "all" }, ...memberCandidates.map((status) => ({
|
|
6657
|
+
kind: "member",
|
|
6658
|
+
status
|
|
6659
|
+
}))] : memberCandidates.map((status) => ({
|
|
6660
|
+
kind: "member",
|
|
6661
|
+
status
|
|
6662
|
+
}));
|
|
6663
|
+
const menuOpen = mention !== void 0 && options.length > 0;
|
|
6664
|
+
const activeOption = options[highlight];
|
|
6665
|
+
const allCount = allMentionMembers(members).length;
|
|
6471
6666
|
const listId = "team-mention-suggestions";
|
|
6472
6667
|
const menuMaxHeight = (0, _deepseek_ai_dsh_client_ui_primitives.useAnchoredMaxHeight)(menuRef, 320, menuOpen ? draft : null);
|
|
6473
6668
|
(0, _deepseek_ai_dsh_client_ui_primitives.useDismissOnOutsidePointer)(rootRef, menuOpen, (open) => {
|
|
@@ -6480,12 +6675,12 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
6480
6675
|
input.style.height = `${Math.min(input.scrollHeight, 180)}px`;
|
|
6481
6676
|
}, [draft]);
|
|
6482
6677
|
(0, react.useEffect)(() => {
|
|
6483
|
-
if (mention === void 0 ||
|
|
6678
|
+
if (mention === void 0 || options.length === 0) {
|
|
6484
6679
|
setHighlight(0);
|
|
6485
6680
|
return;
|
|
6486
6681
|
}
|
|
6487
|
-
setHighlight((current) => Math.min(current,
|
|
6488
|
-
}, [mention,
|
|
6682
|
+
setHighlight((current) => Math.min(current, options.length - 1));
|
|
6683
|
+
}, [mention, options.length]);
|
|
6489
6684
|
(0, react.useEffect)(() => {
|
|
6490
6685
|
const active = document.activeElement;
|
|
6491
6686
|
if (active !== document.body && active?.closest("[aria-current=\"page\"]") === null) return;
|
|
@@ -6496,6 +6691,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
6496
6691
|
inputRef.current?.focus({ preventScroll: true });
|
|
6497
6692
|
}, [confirmation, pending]);
|
|
6498
6693
|
const pruneRecipients = (nextDraft) => {
|
|
6694
|
+
if (containsAllMention(nextDraft)) return;
|
|
6499
6695
|
const knownMembers = new Map(members.map((status) => [status.member.memberId, status.member]));
|
|
6500
6696
|
const next = new Set([...recipients].filter((memberId) => {
|
|
6501
6697
|
const member = knownMembers.get(memberId);
|
|
@@ -6522,8 +6718,26 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
6522
6718
|
pruneRecipients(nextDraft);
|
|
6523
6719
|
updateMention(nextDraft, event.target.selectionStart ?? nextDraft.length);
|
|
6524
6720
|
};
|
|
6525
|
-
const
|
|
6721
|
+
const selectOption = (option) => {
|
|
6526
6722
|
if (mention === void 0) return;
|
|
6723
|
+
if (option.kind === "all") {
|
|
6724
|
+
const nextDraft = `${draft.slice(0, mention.start)}@all ${draft.slice(mention.end)}`;
|
|
6725
|
+
const nextCaret = mention.start + 5;
|
|
6726
|
+
const nextRecipients = new Set(recipients);
|
|
6727
|
+
for (const status of allMentionMembers(members)) nextRecipients.add(status.member.memberId);
|
|
6728
|
+
onDraftChange(nextDraft);
|
|
6729
|
+
onRecipientsChange(nextRecipients);
|
|
6730
|
+
setMention(void 0);
|
|
6731
|
+
setHighlight(0);
|
|
6732
|
+
requestAnimationFrame(() => {
|
|
6733
|
+
const input = inputRef.current;
|
|
6734
|
+
if (input === null) return;
|
|
6735
|
+
input.focus({ preventScroll: true });
|
|
6736
|
+
input.setSelectionRange(nextCaret, nextCaret);
|
|
6737
|
+
});
|
|
6738
|
+
return;
|
|
6739
|
+
}
|
|
6740
|
+
const member = option.status;
|
|
6527
6741
|
const inserted = `@${member.member.handle} `;
|
|
6528
6742
|
const nextDraft = `${draft.slice(0, mention.start)}${inserted}${draft.slice(mention.end)}`;
|
|
6529
6743
|
const nextCaret = mention.start + inserted.length;
|
|
@@ -6539,16 +6753,23 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
6539
6753
|
input.setSelectionRange(nextCaret, nextCaret);
|
|
6540
6754
|
});
|
|
6541
6755
|
};
|
|
6756
|
+
const onPaste = (event) => {
|
|
6757
|
+
if (pending || onFilesChange === void 0 || pendingFiles === void 0) return;
|
|
6758
|
+
const files = Array.from(event.clipboardData.items).filter((item) => item.kind === "file").map((item) => item.getAsFile()).filter((file) => file !== null);
|
|
6759
|
+
if (files.length === 0) return;
|
|
6760
|
+
event.preventDefault();
|
|
6761
|
+
onFilesChange([...pendingFiles, ...files]);
|
|
6762
|
+
};
|
|
6542
6763
|
const onKeyDown = (event) => {
|
|
6543
6764
|
const composing = composingRef.current || event.nativeEvent.isComposing || event.nativeEvent.keyCode === 229;
|
|
6544
6765
|
if (menuOpen && event.key === "ArrowDown") {
|
|
6545
6766
|
event.preventDefault();
|
|
6546
|
-
setHighlight((current) => (current + 1) %
|
|
6767
|
+
setHighlight((current) => (current + 1) % options.length);
|
|
6547
6768
|
return;
|
|
6548
6769
|
}
|
|
6549
6770
|
if (menuOpen && event.key === "ArrowUp") {
|
|
6550
6771
|
event.preventDefault();
|
|
6551
|
-
setHighlight((current) => (current - 1 +
|
|
6772
|
+
setHighlight((current) => (current - 1 + options.length) % options.length);
|
|
6552
6773
|
return;
|
|
6553
6774
|
}
|
|
6554
6775
|
if (event.key === "Escape" && menuOpen) {
|
|
@@ -6558,13 +6779,13 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
6558
6779
|
}
|
|
6559
6780
|
if (menuOpen && event.key === "Tab" && !event.shiftKey) {
|
|
6560
6781
|
event.preventDefault();
|
|
6561
|
-
if (
|
|
6782
|
+
if (activeOption !== void 0) selectOption(activeOption);
|
|
6562
6783
|
return;
|
|
6563
6784
|
}
|
|
6564
6785
|
if (event.key !== "Enter" || event.shiftKey || composing || event.repeat) return;
|
|
6565
|
-
if (menuOpen &&
|
|
6786
|
+
if (menuOpen && activeOption !== void 0) {
|
|
6566
6787
|
event.preventDefault();
|
|
6567
|
-
|
|
6788
|
+
selectOption(activeOption);
|
|
6568
6789
|
return;
|
|
6569
6790
|
}
|
|
6570
6791
|
event.preventDefault();
|
|
@@ -6595,47 +6816,76 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
6595
6816
|
role: "listbox",
|
|
6596
6817
|
"aria-label": t("mentionSuggestions"),
|
|
6597
6818
|
style: { maxHeight: menuMaxHeight },
|
|
6598
|
-
children:
|
|
6599
|
-
|
|
6600
|
-
|
|
6819
|
+
children: options.map((option, index) => {
|
|
6820
|
+
const optionId = option.kind === "all" ? `${listId}-all` : `${listId}-${option.status.member.memberId}`;
|
|
6821
|
+
const selected = index === highlight;
|
|
6822
|
+
return option.kind === "all" ? /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("button", {
|
|
6823
|
+
id: optionId,
|
|
6824
|
+
type: "button",
|
|
6825
|
+
role: "option",
|
|
6826
|
+
"aria-selected": selected,
|
|
6827
|
+
className: composer_module_css_default.mentionOption,
|
|
6828
|
+
onMouseDown: (event) => {
|
|
6829
|
+
event.preventDefault();
|
|
6830
|
+
},
|
|
6831
|
+
onClick: () => {
|
|
6832
|
+
selectOption(option);
|
|
6833
|
+
},
|
|
6834
|
+
children: [
|
|
6835
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
|
|
6836
|
+
className: composer_module_css_default.mentionAllDot,
|
|
6837
|
+
"aria-hidden": "true"
|
|
6838
|
+
}),
|
|
6839
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
|
|
6840
|
+
className: composer_module_css_default.mentionName,
|
|
6841
|
+
children: "@all"
|
|
6842
|
+
}),
|
|
6843
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
|
|
6844
|
+
className: composer_module_css_default.mentionDescription,
|
|
6845
|
+
children: t("mentionAll", { count: allCount })
|
|
6846
|
+
})
|
|
6847
|
+
]
|
|
6848
|
+
}, "all") : /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("button", {
|
|
6849
|
+
id: optionId,
|
|
6601
6850
|
type: "button",
|
|
6602
6851
|
role: "option",
|
|
6603
|
-
"aria-selected":
|
|
6852
|
+
"aria-selected": selected,
|
|
6604
6853
|
className: composer_module_css_default.mentionOption,
|
|
6605
6854
|
onMouseDown: (event) => {
|
|
6606
6855
|
event.preventDefault();
|
|
6607
6856
|
},
|
|
6608
6857
|
onClick: () => {
|
|
6609
|
-
|
|
6858
|
+
selectOption(option);
|
|
6610
6859
|
},
|
|
6611
6860
|
children: [
|
|
6612
6861
|
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TeamPresenceDot, {
|
|
6613
|
-
status,
|
|
6862
|
+
status: option.status,
|
|
6614
6863
|
t
|
|
6615
6864
|
}),
|
|
6616
6865
|
/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("span", {
|
|
6617
6866
|
className: composer_module_css_default.mentionName,
|
|
6618
|
-
children: ["@", status.member.handle]
|
|
6867
|
+
children: ["@", option.status.member.handle]
|
|
6619
6868
|
}),
|
|
6620
6869
|
/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
|
|
6621
6870
|
className: composer_module_css_default.mentionDescription,
|
|
6622
|
-
children: status.member.description
|
|
6871
|
+
children: option.status.member.description
|
|
6623
6872
|
})
|
|
6624
6873
|
]
|
|
6625
|
-
}, status.member.memberId);
|
|
6874
|
+
}, option.status.member.memberId);
|
|
6626
6875
|
})
|
|
6627
6876
|
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("textarea", {
|
|
6628
6877
|
ref: inputRef,
|
|
6629
6878
|
"aria-label": t("messageDraft"),
|
|
6630
6879
|
"aria-autocomplete": "list",
|
|
6631
6880
|
"aria-controls": menuOpen ? listId : void 0,
|
|
6632
|
-
"aria-activedescendant": menuOpen &&
|
|
6881
|
+
"aria-activedescendant": menuOpen && activeOption !== void 0 ? activeOption.kind === "all" ? `${listId}-all` : `${listId}-${activeOption.status.member.memberId}` : void 0,
|
|
6633
6882
|
"aria-expanded": menuOpen,
|
|
6634
6883
|
value: draft,
|
|
6635
6884
|
readOnly: pending,
|
|
6636
|
-
placeholder: t("messagePlaceholder"),
|
|
6885
|
+
placeholder: placeholder ?? t("messagePlaceholder"),
|
|
6637
6886
|
rows: 1,
|
|
6638
6887
|
onChange,
|
|
6888
|
+
onPaste,
|
|
6639
6889
|
onKeyDown,
|
|
6640
6890
|
onSelect: (event) => {
|
|
6641
6891
|
updateMention(event.currentTarget.value, event.currentTarget.selectionStart ?? event.currentTarget.value.length);
|
|
@@ -6694,39 +6944,53 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
6694
6944
|
}),
|
|
6695
6945
|
/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
|
|
6696
6946
|
className: composer_module_css_default.toolbar,
|
|
6697
|
-
children: [
|
|
6698
|
-
|
|
6699
|
-
|
|
6700
|
-
|
|
6701
|
-
|
|
6702
|
-
|
|
6703
|
-
|
|
6704
|
-
|
|
6705
|
-
|
|
6706
|
-
|
|
6707
|
-
|
|
6708
|
-
}
|
|
6709
|
-
|
|
6710
|
-
|
|
6711
|
-
|
|
6712
|
-
|
|
6713
|
-
|
|
6714
|
-
|
|
6715
|
-
|
|
6716
|
-
|
|
6717
|
-
|
|
6718
|
-
|
|
6719
|
-
|
|
6720
|
-
|
|
6721
|
-
|
|
6722
|
-
|
|
6723
|
-
|
|
6724
|
-
|
|
6725
|
-
|
|
6726
|
-
|
|
6727
|
-
|
|
6728
|
-
|
|
6729
|
-
|
|
6947
|
+
children: [
|
|
6948
|
+
onAsTaskChange !== void 0 && /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Button, {
|
|
6949
|
+
size: "sm",
|
|
6950
|
+
variant: "outline",
|
|
6951
|
+
className: asTask === true ? composer_module_css_default.asTaskOn : void 0,
|
|
6952
|
+
"aria-pressed": asTask === true,
|
|
6953
|
+
disabled: pending,
|
|
6954
|
+
onClick: () => {
|
|
6955
|
+
onAsTaskChange(asTask !== true);
|
|
6956
|
+
},
|
|
6957
|
+
children: t("asTask")
|
|
6958
|
+
}),
|
|
6959
|
+
onFilesChange !== void 0 && /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("input", {
|
|
6960
|
+
ref: fileInputRef,
|
|
6961
|
+
type: "file",
|
|
6962
|
+
multiple: true,
|
|
6963
|
+
className: composer_module_css_default.fileInput,
|
|
6964
|
+
"aria-hidden": "true",
|
|
6965
|
+
tabIndex: -1,
|
|
6966
|
+
onChange: (event) => {
|
|
6967
|
+
const chosen = [...event.target.files ?? []];
|
|
6968
|
+
if (chosen.length > 0 && pendingFiles !== void 0) onFilesChange([...pendingFiles, ...chosen]);
|
|
6969
|
+
event.target.value = "";
|
|
6970
|
+
}
|
|
6971
|
+
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
|
|
6972
|
+
type: "button",
|
|
6973
|
+
className: composer_module_css_default.attachButton,
|
|
6974
|
+
"aria-label": t("attachFiles"),
|
|
6975
|
+
title: t("attachFiles"),
|
|
6976
|
+
disabled: pending,
|
|
6977
|
+
onClick: () => {
|
|
6978
|
+
fileInputRef.current?.click();
|
|
6979
|
+
},
|
|
6980
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.IconPlusOutline16, { size: 14 })
|
|
6981
|
+
})] }),
|
|
6982
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
|
|
6983
|
+
type: "submit",
|
|
6984
|
+
className: composer_module_css_default.sendButton,
|
|
6985
|
+
"aria-label": pending ? t("sendingMessage") : t("sendMessage"),
|
|
6986
|
+
disabled: pending || draft.trim() === "",
|
|
6987
|
+
onMouseDown: (event) => {
|
|
6988
|
+
event.preventDefault();
|
|
6989
|
+
inputRef.current?.focus({ preventScroll: true });
|
|
6990
|
+
},
|
|
6991
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.IconSendOutline16, { size: 16 })
|
|
6992
|
+
})
|
|
6993
|
+
]
|
|
6730
6994
|
})
|
|
6731
6995
|
]
|
|
6732
6996
|
}), error !== void 0 && /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
|
|
@@ -6742,16 +7006,16 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
6742
7006
|
const pending = /* @__PURE__ */ new Set();
|
|
6743
7007
|
/** Refs the Host did not recognize; never re-queried (no retry loops). */
|
|
6744
7008
|
const unresolvable = /* @__PURE__ */ new Set();
|
|
6745
|
-
const listeners$
|
|
7009
|
+
const listeners$2 = /* @__PURE__ */ new Set();
|
|
6746
7010
|
let version = 0;
|
|
6747
7011
|
const emit = () => {
|
|
6748
7012
|
version += 1;
|
|
6749
|
-
for (const listener of listeners$
|
|
7013
|
+
for (const listener of listeners$2) listener();
|
|
6750
7014
|
};
|
|
6751
7015
|
const subscribe = (listener) => {
|
|
6752
|
-
listeners$
|
|
7016
|
+
listeners$2.add(listener);
|
|
6753
7017
|
return () => {
|
|
6754
|
-
listeners$
|
|
7018
|
+
listeners$2.delete(listener);
|
|
6755
7019
|
};
|
|
6756
7020
|
};
|
|
6757
7021
|
/** Stable snapshot token; the map is read directly after this changes. */
|
|
@@ -6783,7 +7047,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
6783
7047
|
}).then((result) => {
|
|
6784
7048
|
if (!result.ok) return;
|
|
6785
7049
|
const hit = result.value.resolved[0];
|
|
6786
|
-
if (hit !== void 0) selectThread(hit.
|
|
7050
|
+
if (hit !== void 0) selectThread(hit.threadRef, hit.channelRef, hit.taskRef, hit.taskNumber);
|
|
6787
7051
|
});
|
|
6788
7052
|
};
|
|
6789
7053
|
/**
|
|
@@ -6944,7 +7208,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
6944
7208
|
}
|
|
6945
7209
|
/** Canonical chip handles for one Message's structured mention refs. */
|
|
6946
7210
|
function mentionNamesOf(mentions, handles) {
|
|
6947
|
-
return mentions.map((memberId) => handles.get(memberId)).filter((name) => name !== void 0);
|
|
7211
|
+
return mentions.map((memberId) => memberId === "member:human" ? "human" : handles.get(memberId)).filter((name) => name !== void 0);
|
|
6948
7212
|
}
|
|
6949
7213
|
const MARKDOWN_BLOCK_CONSTRUCT = /(^|\n)[ \t]{0,3}(?:#{1,6}[ \t]|>[ \t]|[-*+][ \t]|\d+[.)][ \t])|^[ \t]*\|.+\|/m;
|
|
6950
7214
|
const MARKDOWN_INLINE_CONSTRUCT = /[`*_[\]!]|~~~|```/;
|
|
@@ -6978,6 +7242,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
6978
7242
|
actor,
|
|
6979
7243
|
count: activity.completedClaimRefs.length
|
|
6980
7244
|
}) : options.t("activityAccepted", { actor });
|
|
7245
|
+
if (activity.kind === "promote") return options.t("activityPromoted", { actor });
|
|
6981
7246
|
if (activity.kind === "close") return options.t("activityClosed", { actor });
|
|
6982
7247
|
if (activity.kind === "reopen") return options.t("activityReopened", { actor });
|
|
6983
7248
|
const direction = "claimRef" in activity ? options.claims.find((claim) => claim.claimRef === activity.claimRef)?.direction ?? options.t("claims") : options.t("claims");
|
|
@@ -7003,6 +7268,10 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
7003
7268
|
function stripAttachmentLines(body) {
|
|
7004
7269
|
return body.replaceAll(/^\[attachment\] .*$(\n)?/gm, "").replace(/\n+$/, "");
|
|
7005
7270
|
}
|
|
7271
|
+
/** Whether one displayed Message body starts clamped behind the expand control. */
|
|
7272
|
+
function shouldClampMessage(displayBody) {
|
|
7273
|
+
return displayBody.length > 600;
|
|
7274
|
+
}
|
|
7006
7275
|
/**
|
|
7007
7276
|
* Decide how one Message body renders. Human input and plain-prose Agent
|
|
7008
7277
|
* bodies stay literal, with structured mention chips inline where possible;
|
|
@@ -7024,13 +7293,13 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
7024
7293
|
render: inline !== void 0 ? "inline" : options.human || options.canOpenRefs && !richAgentBody && refs.length > 0 ? "literal" : "markdown",
|
|
7025
7294
|
...inline === void 0 ? {} : { inline },
|
|
7026
7295
|
fallbackNames,
|
|
7027
|
-
fallbackRefs: richAgentBody && options.canOpenRefs ? refs
|
|
7296
|
+
fallbackRefs: richAgentBody && !options.canOpenRefs ? refs : [],
|
|
7028
7297
|
taskRefs: options.canOpenRefs && !richAgentBody ? refs.filter((ref) => ref.startsWith("task:")).map((ref) => ref) : []
|
|
7029
7298
|
};
|
|
7030
7299
|
}
|
|
7031
7300
|
//#endregion
|
|
7032
7301
|
//#region \0dsh-css:/home/yu/projects/dsh-agent-team/packages/client-agent-team/src/client/conversation.module.css.mjs
|
|
7033
|
-
const css$4 = ".omcBaG_surface{grid-template-rows:auto minmax(0,1fr) auto;min-width:0;height:100%;min-height:0;display:grid;overflow:hidden}.omcBaG_surfaceHeader{border-bottom:1px solid var(--dsw-alias-border-l2);min-width:0;padding:14px clamp(18px,3vw,36px) 12px}.omcBaG_headerRow{justify-content:space-between;align-items:flex-start;gap:16px;min-width:0;max-width:880px;margin:0 auto;display:flex}.omcBaG_headerCopy{min-width:0}.omcBaG_headerCopy h1{color:var(--dsw-alias-label-primary);overflow-wrap:anywhere;margin:0;font-size:20px;font-weight:600;line-height:28px}.omcBaG_headerCopy p{color:var(--dsw-alias-label-secondary);margin:3px 0 0;font-size:13px;line-height:20px}.omcBaG_headerActions{flex:none;align-items:center;gap:6px;display:flex}.omcBaG_backRow{max-width:880px;margin:0 auto 8px}.omcBaG_timeline{overscroll-behavior:contain;scrollbar-gutter:stable;min-height:0;padding:12px clamp(18px,3vw,36px) 24px;overflow:hidden auto}.omcBaG_timelineContent{flex-direction:column;min-width:0;max-width:880px;min-height:100%;margin:0 auto;display:flex}.omcBaG_emptySurface{margin:auto;padding:32px 0}.omcBaG_emptySurface .omcBaG_emptyState{text-align:center;justify-items:center}.omcBaG_timelineAction{justify-content:center;padding:2px 0 8px;display:flex}.omcBaG_messageRow{gap:10px;padding:10px 0;display:flex}.omcBaG_messageRow[data-grouped]{padding-top:2px}.omcBaG_messageRow[data-grouped] .omcBaG_messageBody>:first-child{margin-top:0}.omcBaG_messageIdentity{background:hsl(var(--team-avatar-hue,212) 42% 46%);color:#fff;border-radius:50%;flex:0 0 28px;justify-content:center;align-items:center;height:28px;font-size:12px;font-weight:600;display:flex}.omcBaG_messageRow[data-human] .omcBaG_messageIdentity{background:var(--dsw-alias-state-business-primary)}.omcBaG_messageRow[data-grouped] .omcBaG_messageIdentity{visibility:hidden}.omcBaG_messageBody{min-width:0}.omcBaG_nameRow{flex-wrap:wrap;align-items:baseline;gap:8px;display:flex}.omcBaG_nameRow strong{color:var(--dsw-alias-label-primary);font-size:13px;font-weight:600;line-height:20px}.omcBaG_messageTime{color:var(--dsw-alias-label-tertiary);font-size:11px;line-height:20px}.omcBaG_messageText{white-space:pre-wrap;word-break:break-word;margin:6px 0;font-size:14px;line-height:22px}.omcBaG_messageBody .omcBaG_messageMarkdown{font-size:14px;line-height:22px}.omcBaG_messageBody
|
|
7302
|
+
const css$4 = ".omcBaG_surface{grid-template-rows:auto minmax(0,1fr) auto;min-width:0;height:100%;min-height:0;display:grid;overflow:hidden}.omcBaG_surfaceHeader{border-bottom:1px solid var(--dsw-alias-border-l2);min-width:0;padding:14px clamp(18px,3vw,36px) 12px}.omcBaG_headerRow{justify-content:space-between;align-items:flex-start;gap:16px;min-width:0;max-width:880px;margin:0 auto;display:flex}.omcBaG_headerCopy{min-width:0}.omcBaG_headerCopy h1{color:var(--dsw-alias-label-primary);overflow-wrap:anywhere;margin:0;font-size:20px;font-weight:600;line-height:28px}.omcBaG_headerCopy p{color:var(--dsw-alias-label-secondary);margin:3px 0 0;font-size:13px;line-height:20px}.omcBaG_headerActions{flex:none;align-items:center;gap:6px;display:flex}.omcBaG_backRow{max-width:880px;margin:0 auto 8px}.omcBaG_timeline{overscroll-behavior:contain;scrollbar-gutter:stable;min-height:0;padding:12px clamp(18px,3vw,36px) 24px;overflow:hidden auto}.omcBaG_timelineContent{flex-direction:column;min-width:0;max-width:880px;min-height:100%;margin:0 auto;display:flex}.omcBaG_emptySurface{margin:auto;padding:32px 0}.omcBaG_emptySurface .omcBaG_emptyState{text-align:center;justify-items:center}.omcBaG_timelineAction{justify-content:center;padding:2px 0 8px;display:flex}.omcBaG_messageRow{gap:10px;padding:10px 0;display:flex}.omcBaG_messageRow[data-grouped]{padding-top:2px}.omcBaG_messageRow[data-grouped] .omcBaG_messageBody>:first-child,.omcBaG_messageRow[data-grouped] .omcBaG_messageBody>:first-child>:first-child{margin-top:0}.omcBaG_messageIdentity{background:hsl(var(--team-avatar-hue,212) 42% 46%);color:#fff;border-radius:50%;flex:0 0 28px;justify-content:center;align-items:center;height:28px;font-size:12px;font-weight:600;display:flex}.omcBaG_messageRow[data-human] .omcBaG_messageIdentity{background:var(--dsw-alias-state-business-primary)}.omcBaG_messageRow[data-grouped] .omcBaG_messageIdentity{visibility:hidden}.omcBaG_messageBody{min-width:0}.omcBaG_nameRow{flex-wrap:wrap;align-items:baseline;gap:8px;display:flex}.omcBaG_nameRow strong{color:var(--dsw-alias-label-primary);font-size:13px;font-weight:600;line-height:20px}.omcBaG_messageTime{color:var(--dsw-alias-label-tertiary);font-size:11px;line-height:20px}.omcBaG_messageText{white-space:pre-wrap;word-break:break-word;margin:6px 0;font-size:14px;line-height:22px}.omcBaG_messageClamp{max-height:176px;overflow:hidden;-webkit-mask-image:linear-gradient(#000 72%,#0000 100%);mask-image:linear-gradient(#000 72%,#0000 100%)}.omcBaG_messageExpand{color:var(--dsw-alias-label-tertiary);cursor:pointer;background:0 0;border:0;width:fit-content;margin-top:4px;padding:0;font-size:12px;line-height:20px;display:block}.omcBaG_messageExpand:hover,.omcBaG_messageExpand:focus-visible{color:var(--dsw-alias-label-primary);text-underline-offset:2px;outline:none;text-decoration:underline}.omcBaG_messageBody .omcBaG_messageMarkdown{font-size:14px;line-height:22px}.omcBaG_messageBody .omcBaG_messageMarkdown>div:first-child{color:var(--dsw-alias-label-primary);font:inherit}.omcBaG_messageBody .omcBaG_messageMarkdown p{margin:6px 0}.omcBaG_messageBody .omcBaG_messageMarkdown :where(ul,ol){margin:6px 0;padding-left:22px}.omcBaG_messageBody .omcBaG_messageMarkdown li+li{margin-top:2px}.omcBaG_messageBody .omcBaG_messageMarkdown strong{font-weight:600}.omcBaG_messageBody .omcBaG_messageMarkdown :where(h1,h2,h3,h4,h5,h6){margin:12px 0 4px}.omcBaG_messageBody .omcBaG_messageMarkdown :where(h1){font-size:17px;line-height:26px}.omcBaG_messageBody .omcBaG_messageMarkdown :where(h2){font-size:16px;line-height:24px}.omcBaG_messageBody .omcBaG_messageMarkdown :where(h3,h4,h5,h6){font-size:15px;line-height:22px}.omcBaG_messageBody .omcBaG_messageMarkdown pre{margin:8px 0;padding:10px 12px;font-size:13px}.omcBaG_messageBody .omcBaG_messageMarkdown blockquote{margin:6px 0}.omcBaG_messageBody .omcBaG_messageMarkdown :where(th,td){padding-block:5px}.omcBaG_emptyState,.omcBaG_loadingState{color:var(--dsw-alias-label-tertiary);margin:0;padding:14px 0;font-size:13px;line-height:20px}.omcBaG_emptyState{gap:3px;display:grid}.omcBaG_emptyState strong{color:var(--dsw-alias-label-secondary);font-weight:500}.omcBaG_emptyState span{font-size:12px}.omcBaG_loadingState{align-items:center;gap:8px;display:flex}.omcBaG_loadingMark{background:var(--dsw-alias-bg-skeleton);border-radius:50%;width:8px;height:8px;animation:1.2s ease-in-out infinite omcBaG_pulse}.omcBaG_error,.omcBaG_errorState{color:var(--dsw-alias-state-error-primary);max-width:880px;margin:0 auto;padding-top:6px;font-size:12px;line-height:18px}.omcBaG_errorState{justify-content:space-between;align-items:center;gap:8px;display:flex}.omcBaG_welcomeSurface{justify-content:center;align-items:center;min-width:0;height:100%;padding:32px;display:flex}.omcBaG_welcome{text-align:center;max-width:420px}.omcBaG_welcomeEyebrow{color:var(--dsw-alias-label-tertiary);text-transform:uppercase;font-size:12px;line-height:18px}.omcBaG_welcome h1{color:var(--dsw-alias-label-primary);margin:8px 0;font-size:24px;font-weight:600;line-height:32px}.omcBaG_welcome p{color:var(--dsw-alias-label-secondary);margin:0;font-size:13px;line-height:20px}@keyframes omcBaG_pulse{0%,to{opacity:.35}50%{opacity:1}}@media (width<=600px){.omcBaG_surfaceHeader{padding:12px 12px 10px}.omcBaG_headerRow{flex-direction:column;align-items:stretch;gap:8px}.omcBaG_headerActions{flex-wrap:wrap}.omcBaG_backRow{margin-bottom:6px}.omcBaG_timeline{scrollbar-gutter:auto;padding:8px 12px 16px}.omcBaG_messageRow{padding:8px 0}}@media (prefers-reduced-motion:reduce){.omcBaG_loadingMark{animation:none}}.omcBaG_messageRun{margin:2px 0;padding:3px 0}.omcBaG_messageRow[data-grouped]:has(.omcBaG_messageBody>button:not([data-message-expand])){margin-top:3px;padding-top:7px;position:relative}.omcBaG_messageRow[data-grouped]:has(.omcBaG_messageBody>button:not([data-message-expand])):before{background:var(--dsw-alias-border-l2);content:\"\";height:1px;position:absolute;inset:0 0 auto 38px}.omcBaG_runDivider{border-top:1px solid var(--dsw-alias-border-l2);color:var(--dsw-alias-label-tertiary);margin:2px 0 0 38px;padding:5px 0 0;font-size:11px;line-height:16px}.omcBaG_runDivider+.omcBaG_messageRow[data-grouped]:has(.omcBaG_messageBody>button:not([data-message-expand])){margin-top:0}.omcBaG_runDivider+.omcBaG_messageRow[data-grouped]:has(.omcBaG_messageBody>button:not([data-message-expand])):before{content:none}.omcBaG_mention{background:color-mix(in srgb, var(--dsw-alias-state-business-primary) 12%, transparent);color:var(--dsw-alias-state-business-primary);border-radius:5px;padding:0 4px;font-weight:500;box-shadow:0 1px 2px #00000014}.omcBaG_mentionsRow{gap:4px;width:fit-content;margin-top:3px;font-size:.85em;display:flex}.omcBaG_attachmentStrip{flex-wrap:wrap;gap:6px;margin-top:4px;display:flex}.omcBaG_attachmentThumb{cursor:zoom-in;border:0;border-radius:8px;padding:0}.omcBaG_attachmentThumb img{object-fit:cover;border-radius:8px;width:128px;height:96px;display:block}.omcBaG_attachmentThumb:focus-visible{outline:2px solid var(--dsw-alias-state-business-primary,currentColor);outline-offset:1px}.omcBaG_confirmBody{margin:0 0 8px}.omcBaG_confirmList{gap:6px;margin:0;padding-left:18px;display:grid}.omcBaG_refLink{color:var(--dsw-alias-state-business-primary);cursor:pointer;font:inherit;text-align:left;text-underline-offset:3px;background:0 0;border:none;border-radius:4px;padding:0;text-decoration:underline}.omcBaG_refLink:hover{text-decoration-thickness:2px}.omcBaG_refLink:focus-visible{outline:2px solid var(--dsw-alias-state-business-primary);outline-offset:1px}.omcBaG_attachmentModal{width:min(1100px,92vw)}.omcBaG_attachmentZoom{object-fit:contain;border-radius:12px;max-width:100%;max-height:78vh;margin:0 auto;display:block}.omcBaG_attachmentChip{background:var(--dsw-alias-interactive-bg-hover);border-radius:6px;align-items:baseline;gap:6px;max-width:100%;padding:3px 8px;display:inline-flex}.omcBaG_attachmentChipName{text-overflow:ellipsis;white-space:nowrap;font-size:12px;line-height:17px;overflow:hidden}.omcBaG_attachmentChipSize{color:var(--dsw-alias-label-tertiary);white-space:nowrap;font-size:11px;line-height:17px}";
|
|
7034
7303
|
const tagId$4 = "@wowyuarm/dsh-agent-team/conversation.module.css";
|
|
7035
7304
|
if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=" + JSON.stringify(tagId$4) + "]") === null) {
|
|
7036
7305
|
const tag = document.createElement("style");
|
|
@@ -7062,6 +7331,8 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
7062
7331
|
"mention": "omcBaG_mention",
|
|
7063
7332
|
"mentionsRow": "omcBaG_mentionsRow",
|
|
7064
7333
|
"messageBody": "omcBaG_messageBody",
|
|
7334
|
+
"messageClamp": "omcBaG_messageClamp",
|
|
7335
|
+
"messageExpand": "omcBaG_messageExpand",
|
|
7065
7336
|
"messageIdentity": "omcBaG_messageIdentity",
|
|
7066
7337
|
"messageMarkdown": "omcBaG_messageMarkdown",
|
|
7067
7338
|
"messageRow": "omcBaG_messageRow",
|
|
@@ -7084,7 +7355,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
7084
7355
|
//#endregion
|
|
7085
7356
|
//#region src/client/TeamMessage.tsx
|
|
7086
7357
|
/** One chat message row with identity chrome and sender-appropriate rendering. */
|
|
7087
|
-
function TeamMessage({ senderName, memberId, human, body, occurredAt, mentionNames, senderTitle, grouped, attachments, loadAttachment, t, onOpenRef, onResolveTaskRefs, children }) {
|
|
7358
|
+
function TeamMessage({ senderName, memberId, human, body, occurredAt, mentionNames, senderTitle, grouped, showGroupedTime, attachments, loadAttachment, t, onOpenRef, onResolveTaskRefs, children }) {
|
|
7088
7359
|
const avatarStyle = human ? void 0 : { "--team-avatar-hue": memberHue(memberId) };
|
|
7089
7360
|
const plan = planMessageBody(body, {
|
|
7090
7361
|
human,
|
|
@@ -7105,6 +7376,10 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
7105
7376
|
refVersion
|
|
7106
7377
|
]);
|
|
7107
7378
|
const taskLabel = (0, react.useCallback)((taskNumber) => t?.("taskLabel", { number: taskNumber }) ?? `Task #${taskNumber}`, [t]);
|
|
7379
|
+
const refLabel = (0, react.useCallback)((ref) => ref.startsWith("thread:") ? t?.("threadLabel") ?? "Thread" : ref.startsWith("channel:") ? t?.("channels") ?? "Channels" : ref, [t]);
|
|
7380
|
+
const [expanded, setExpanded] = (0, react.useState)(false);
|
|
7381
|
+
const clampable = shouldClampMessage(displayBody);
|
|
7382
|
+
const clamped = clampable && !expanded;
|
|
7108
7383
|
const markdownRef = (0, react.useRef)(null);
|
|
7109
7384
|
(0, react.useLayoutEffect)(() => {
|
|
7110
7385
|
const root = markdownRef.current;
|
|
@@ -7113,8 +7388,8 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
7113
7388
|
const styledRefCodes = markdownStyledRefCodeElements(root);
|
|
7114
7389
|
const taskRefs = [...new Set([...textNodes.map((node) => node.data), ...styledRefCodes.map((code) => code.textContent ?? "")].flatMap((text) => splitBrandedRefs(text).filter((segment) => segment.ref?.startsWith("task:") === true).map((segment) => segment.ref)))];
|
|
7115
7390
|
if (onResolveTaskRefs !== void 0 && taskRefs.length > 0) resolveUnknownTaskRefs(taskRefs, onResolveTaskRefs);
|
|
7116
|
-
for (const code of styledRefCodes) renderResolvedMarkdownCodeRef(code, taskLabel);
|
|
7117
|
-
for (const node of textNodes) renderResolvedMarkdownText(node, mentionNames ?? [], taskLabel);
|
|
7391
|
+
for (const code of styledRefCodes) renderResolvedMarkdownCodeRef(code, taskLabel, refLabel);
|
|
7392
|
+
for (const node of textNodes) renderResolvedMarkdownText(node, mentionNames ?? [], taskLabel, refLabel);
|
|
7118
7393
|
for (const button of root.querySelectorAll("button[data-task-ref]")) {
|
|
7119
7394
|
const taskRef = button.dataset.taskRef;
|
|
7120
7395
|
const hit = taskRef === void 0 ? void 0 : cachedResolvedTaskRef(taskRef);
|
|
@@ -7126,6 +7401,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
7126
7401
|
onResolveTaskRefs,
|
|
7127
7402
|
refVersion,
|
|
7128
7403
|
taskLabel,
|
|
7404
|
+
refLabel,
|
|
7129
7405
|
mentionNames
|
|
7130
7406
|
]);
|
|
7131
7407
|
(0, react.useEffect)(() => {
|
|
@@ -7134,16 +7410,30 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
7134
7410
|
const openTask = (event) => {
|
|
7135
7411
|
const target = event.target;
|
|
7136
7412
|
if (!(target instanceof Element)) return;
|
|
7137
|
-
const button = target.closest("button[data-task-ref]");
|
|
7413
|
+
const button = target.closest("button[data-ref], button[data-task-ref]");
|
|
7138
7414
|
if (button === null || !root.contains(button)) return;
|
|
7139
|
-
const
|
|
7140
|
-
if (
|
|
7415
|
+
const ref = button instanceof HTMLElement ? button.dataset.ref ?? button.dataset.taskRef : void 0;
|
|
7416
|
+
if (ref !== void 0) onOpenRef(ref);
|
|
7141
7417
|
};
|
|
7142
7418
|
root.addEventListener("click", openTask);
|
|
7143
7419
|
return () => {
|
|
7144
7420
|
root.removeEventListener("click", openTask);
|
|
7145
7421
|
};
|
|
7146
7422
|
}, [richAgentBody, onOpenRef]);
|
|
7423
|
+
const bodyNode = plan.render === "inline" && plan.inline !== void 0 ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
7424
|
+
className: conversation_module_css_default.messageText,
|
|
7425
|
+
children: plan.inline.segments.map((segment, index) => segment.mention ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
|
|
7426
|
+
className: conversation_module_css_default.mention,
|
|
7427
|
+
children: segment.text
|
|
7428
|
+
}, index) : /* @__PURE__ */ (0, react_jsx_runtime.jsx)(react.Fragment, { children: renderRefs(segment.text, onOpenRef, taskLabel, refLabel) }, index))
|
|
7429
|
+
}) : plan.render === "literal" ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
7430
|
+
className: conversation_module_css_default.messageText,
|
|
7431
|
+
children: onOpenRef === void 0 ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.MessageText, { text: displayBody }) : renderRefs(displayBody, onOpenRef, taskLabel, refLabel)
|
|
7432
|
+
}) : /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
7433
|
+
ref: markdownRef,
|
|
7434
|
+
className: conversation_module_css_default.messageMarkdown,
|
|
7435
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.MarkdownText, { text: displayBody }, `${displayBody}:${onOpenRef === void 0 ? "literal" : "refs"}`)
|
|
7436
|
+
});
|
|
7147
7437
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("article", {
|
|
7148
7438
|
className: conversation_module_css_default.messageRow,
|
|
7149
7439
|
"data-human": human || void 0,
|
|
@@ -7156,9 +7446,9 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
7156
7446
|
}), /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
|
|
7157
7447
|
className: conversation_module_css_default.messageBody,
|
|
7158
7448
|
children: [
|
|
7159
|
-
!grouped && /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
|
|
7449
|
+
(!grouped || showGroupedTime === true) && /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
|
|
7160
7450
|
className: conversation_module_css_default.nameRow,
|
|
7161
|
-
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("strong", {
|
|
7451
|
+
children: [!grouped && /* @__PURE__ */ (0, react_jsx_runtime.jsx)("strong", {
|
|
7162
7452
|
...senderTitle === void 0 ? {} : { title: senderTitle },
|
|
7163
7453
|
children: senderName
|
|
7164
7454
|
}), occurredAt !== void 0 && /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
|
|
@@ -7166,19 +7456,19 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
7166
7456
|
children: formatMessageTime(occurredAt)
|
|
7167
7457
|
})]
|
|
7168
7458
|
}),
|
|
7169
|
-
|
|
7170
|
-
className: conversation_module_css_default.
|
|
7171
|
-
children:
|
|
7172
|
-
|
|
7173
|
-
|
|
7174
|
-
|
|
7175
|
-
|
|
7176
|
-
|
|
7177
|
-
|
|
7178
|
-
|
|
7179
|
-
|
|
7180
|
-
|
|
7181
|
-
children:
|
|
7459
|
+
clampable ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
7460
|
+
className: clamped ? conversation_module_css_default.messageClamp : void 0,
|
|
7461
|
+
children: bodyNode
|
|
7462
|
+
}) : bodyNode,
|
|
7463
|
+
clampable && /* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
|
|
7464
|
+
type: "button",
|
|
7465
|
+
className: conversation_module_css_default.messageExpand,
|
|
7466
|
+
"data-message-expand": "true",
|
|
7467
|
+
"aria-expanded": expanded,
|
|
7468
|
+
onClick: () => {
|
|
7469
|
+
setExpanded((value) => !value);
|
|
7470
|
+
},
|
|
7471
|
+
children: expanded ? t?.("collapseMessage") ?? "Show less" : t?.("expandMessage") ?? "Show more"
|
|
7182
7472
|
}),
|
|
7183
7473
|
(plan.fallbackNames.length > 0 || plan.fallbackRefs.length > 0) && /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
|
|
7184
7474
|
className: conversation_module_css_default.mentionsRow,
|
|
@@ -7243,16 +7533,27 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
7243
7533
|
return button;
|
|
7244
7534
|
}
|
|
7245
7535
|
/** Replace a whole-ref code span with its resolved Task chip once known. */
|
|
7246
|
-
function renderResolvedMarkdownCodeRef(code, taskLabel) {
|
|
7536
|
+
function renderResolvedMarkdownCodeRef(code, taskLabel, refLabel) {
|
|
7247
7537
|
const segments = splitBrandedRefs((code.textContent ?? "").trim());
|
|
7248
|
-
const
|
|
7249
|
-
|
|
7538
|
+
const ref = (segments.length === 1 ? segments[0] : void 0)?.ref;
|
|
7539
|
+
if (ref === void 0) return;
|
|
7540
|
+
const taskRef = ref.startsWith("task:") === true ? ref : void 0;
|
|
7250
7541
|
const resolved = taskRef === void 0 ? void 0 : cachedResolvedTaskRef(taskRef);
|
|
7251
|
-
if (taskRef
|
|
7252
|
-
|
|
7253
|
-
|
|
7254
|
-
|
|
7255
|
-
|
|
7542
|
+
if (taskRef !== void 0 && resolved === void 0) return;
|
|
7543
|
+
if (taskRef !== void 0) {
|
|
7544
|
+
code.replaceWith(resolvedTaskRefButton(taskRef, taskLabel(resolved.taskNumber)));
|
|
7545
|
+
return;
|
|
7546
|
+
}
|
|
7547
|
+
const button = document.createElement("button");
|
|
7548
|
+
button.type = "button";
|
|
7549
|
+
if (conversation_module_css_default.refLink !== void 0) button.className = conversation_module_css_default.refLink;
|
|
7550
|
+
button.dataset.ref = ref;
|
|
7551
|
+
button.title = ref;
|
|
7552
|
+
button.textContent = refLabel(ref);
|
|
7553
|
+
code.replaceWith(button);
|
|
7554
|
+
}
|
|
7555
|
+
/** Replace resolved Task refs and structured mention handles in one prose text node without changing Markdown structure. */
|
|
7556
|
+
function renderResolvedMarkdownText(node, mentionNames, taskLabel, refLabel) {
|
|
7256
7557
|
let changed = false;
|
|
7257
7558
|
const fragment = document.createDocumentFragment();
|
|
7258
7559
|
for (const refSegment of splitBrandedRefs(node.data)) {
|
|
@@ -7272,22 +7573,31 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
7272
7573
|
}
|
|
7273
7574
|
const taskRef = refSegment.ref.startsWith("task:") === true ? refSegment.ref : void 0;
|
|
7274
7575
|
const resolved = taskRef === void 0 ? void 0 : cachedResolvedTaskRef(taskRef);
|
|
7275
|
-
if (resolved === void 0) {
|
|
7576
|
+
if (taskRef !== void 0 && resolved === void 0) {
|
|
7276
7577
|
fragment.append(refSegment.text);
|
|
7277
7578
|
continue;
|
|
7278
7579
|
}
|
|
7279
7580
|
changed = true;
|
|
7280
|
-
fragment.append(resolvedTaskRefButton(taskRef, taskLabel(resolved.taskNumber)));
|
|
7581
|
+
if (taskRef !== void 0) fragment.append(resolvedTaskRefButton(taskRef, taskLabel(resolved.taskNumber)));
|
|
7582
|
+
else {
|
|
7583
|
+
const button = document.createElement("button");
|
|
7584
|
+
button.type = "button";
|
|
7585
|
+
if (conversation_module_css_default.refLink !== void 0) button.className = conversation_module_css_default.refLink;
|
|
7586
|
+
button.dataset.ref = refSegment.ref;
|
|
7587
|
+
button.title = refSegment.ref;
|
|
7588
|
+
button.textContent = refLabel(refSegment.ref);
|
|
7589
|
+
fragment.append(button);
|
|
7590
|
+
}
|
|
7281
7591
|
}
|
|
7282
7592
|
if (changed) node.replaceWith(fragment);
|
|
7283
7593
|
}
|
|
7284
7594
|
/** Render one literal text run, linkifying branded refs when navigation is available. */
|
|
7285
|
-
function renderRefs(text, onOpenRef, taskLabel) {
|
|
7595
|
+
function renderRefs(text, onOpenRef, taskLabel, refLabel) {
|
|
7286
7596
|
if (onOpenRef === void 0) return text;
|
|
7287
7597
|
return splitBrandedRefs(text).map((segment, index) => {
|
|
7288
7598
|
if (segment.ref === void 0) return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(react.Fragment, { children: segment.text }, index);
|
|
7289
7599
|
const resolved = cachedResolvedTaskRef(segment.ref);
|
|
7290
|
-
const label = resolved !== void 0 && segment.ref.startsWith("task:") ? taskLabel(resolved.taskNumber) : segment.ref;
|
|
7600
|
+
const label = resolved !== void 0 && segment.ref.startsWith("task:") ? taskLabel(resolved.taskNumber) : refLabel(segment.ref);
|
|
7291
7601
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
|
|
7292
7602
|
type: "button",
|
|
7293
7603
|
className: conversation_module_css_default.refLink,
|
|
@@ -7563,7 +7873,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
7563
7873
|
}
|
|
7564
7874
|
//#endregion
|
|
7565
7875
|
//#region \0dsh-css:/home/yu/projects/dsh-agent-team/packages/client-agent-team/src/client/channel.module.css.mjs
|
|
7566
|
-
const css$3 = ".MYaRJa_headerMeta{color:var(--dsw-alias-label-tertiary);flex-wrap:wrap;align-items:center;gap:6px;margin-top:7px;font-size:12px;line-height:18px;display:flex}.MYaRJa_headerMeta span+span:before{content:\"·\";margin-right:6px}.MYaRJa_taskFooter{border:1px solid var(--dsw-alias-border-l2);color:var(--dsw-alias-label-secondary);cursor:pointer;text-align:left;background:0 0;border-radius:999px;align-items:center;gap:6px;max-width:100%;margin:6px 0 0;padding:2px 10px;transition:background-color .12s,border-color .12s,color .12s;display:inline-flex}.MYaRJa_taskFooter:hover,.MYaRJa_taskFooter:focus-visible{background:var(--dsw-alias-interactive-bg-hover);border-color:var(--dsw-alias-border-l3);color:var(--dsw-alias-label-primary)}.MYaRJa_taskFooter:focus-visible{outline:2px solid var(--dsw-alias-state-business-primary);outline-offset:2px}.MYaRJa_taskNumber{color:var(--dsw-alias-label-primary);font-size:12px;font-weight:600;line-height:18px}.MYaRJa_taskStatus,.MYaRJa_taskCount{color:var(--dsw-alias-label-tertiary);font-size:11px;line-height:18px}.MYaRJa_taskDot{flex:none;align-items:center;width:8px;display:inline-flex}.MYaRJa_taskDotQuiet{border-radius:50%;flex:none;width:8px;height:8px;position:relative}.MYaRJa_taskDotQuiet[data-variant=todo]{border:1px solid var(--dsw-alias-label-tertiary)}.MYaRJa_taskDotQuiet[data-variant=closed]{color:var(--dsw-alias-label-tertiary)}.MYaRJa_taskDotQuiet[data-variant=closed]:before{content:\"\";opacity:.1;background:currentColor;border-radius:50%;position:absolute;inset:0}.MYaRJa_taskDotQuiet[data-variant=closed]:after{content:\"\";background:currentColor;border-radius:50%;position:absolute;inset:20%}.MYaRJa_taskArrow{color:var(--dsw-alias-label-tertiary);align-items:center;transition:transform .12s;display:inline-flex}.MYaRJa_taskFooter:hover .MYaRJa_taskArrow,.MYaRJa_taskFooter:focus-visible .MYaRJa_taskArrow{transform:translate(2px)}.MYaRJa_memberList{gap:3px;display:grid}.MYaRJa_memberRow{border-radius:6px;grid-template-columns:14px minmax(0,1fr) auto;align-items:center;gap:0 8px;min-height:40px;padding:4px 6px;display:grid}.MYaRJa_memberRow:hover{background:var(--dsw-alias-interactive-bg-hover)}.MYaRJa_memberCopy{min-width:0;display:grid}.MYaRJa_memberCopy strong{color:var(--dsw-alias-label-primary);text-overflow:ellipsis;white-space:nowrap;font-size:12px;font-weight:500;line-height:18px;overflow:hidden}.MYaRJa_memberCopy small{color:var(--dsw-alias-label-tertiary);text-overflow:ellipsis;white-space:nowrap;font-size:10px;line-height:14px;overflow:hidden}.MYaRJa_memberAction{min-width:60px}.MYaRJa_memberError{color:var(--dsw-alias-state-error-primary);grid-column:2/-1;margin:2px 0;font-size:11px;line-height:16px}.MYaRJa_modalBody{max-height:min(65vh,520px);overflow-y:auto}@media (width<=600px){.
|
|
7876
|
+
const css$3 = ".MYaRJa_headerMeta{color:var(--dsw-alias-label-tertiary);flex-wrap:wrap;align-items:center;gap:6px;margin-top:7px;font-size:12px;line-height:18px;display:flex}.MYaRJa_headerMeta span+span:before{content:\"·\";margin-right:6px}.MYaRJa_taskFooter{border:1px solid var(--dsw-alias-border-l2);color:var(--dsw-alias-label-secondary);cursor:pointer;text-align:left;background:0 0;border-radius:999px;align-items:center;gap:6px;max-width:100%;margin:6px 0 0;padding:2px 10px;transition:background-color .12s,border-color .12s,color .12s;display:inline-flex}.MYaRJa_taskFooter:hover,.MYaRJa_taskFooter:focus-visible{background:var(--dsw-alias-interactive-bg-hover);border-color:var(--dsw-alias-border-l3);color:var(--dsw-alias-label-primary)}.MYaRJa_taskFooter:focus-visible{outline:2px solid var(--dsw-alias-state-business-primary);outline-offset:2px}.MYaRJa_taskNumber{color:var(--dsw-alias-label-primary);font-size:12px;font-weight:600;line-height:18px}.MYaRJa_taskStatus,.MYaRJa_taskCount{color:var(--dsw-alias-label-tertiary);font-size:11px;line-height:18px}.MYaRJa_taskDot{flex:none;align-items:center;width:8px;display:inline-flex}.MYaRJa_taskDotQuiet{border-radius:50%;flex:none;width:8px;height:8px;position:relative}.MYaRJa_taskDotQuiet[data-variant=todo]{border:1px solid var(--dsw-alias-label-tertiary)}.MYaRJa_taskDotQuiet[data-variant=closed]{color:var(--dsw-alias-label-tertiary)}.MYaRJa_taskDotQuiet[data-variant=closed]:before{content:\"\";opacity:.1;background:currentColor;border-radius:50%;position:absolute;inset:0}.MYaRJa_taskDotQuiet[data-variant=closed]:after{content:\"\";background:currentColor;border-radius:50%;position:absolute;inset:20%}.MYaRJa_taskArrow{color:var(--dsw-alias-label-tertiary);align-items:center;transition:transform .12s;display:inline-flex}.MYaRJa_taskFooter:hover .MYaRJa_taskArrow,.MYaRJa_taskFooter:focus-visible .MYaRJa_taskArrow{transform:translate(2px)}.MYaRJa_memberList{gap:3px;display:grid}.MYaRJa_memberRow{border-radius:6px;grid-template-columns:14px minmax(0,1fr) auto;align-items:center;gap:0 8px;min-height:40px;padding:4px 6px;display:grid}.MYaRJa_memberRow:hover{background:var(--dsw-alias-interactive-bg-hover)}.MYaRJa_memberCopy{min-width:0;display:grid}.MYaRJa_memberCopy strong{color:var(--dsw-alias-label-primary);text-overflow:ellipsis;white-space:nowrap;font-size:12px;font-weight:500;line-height:18px;overflow:hidden}.MYaRJa_memberCopy small{color:var(--dsw-alias-label-tertiary);text-overflow:ellipsis;white-space:nowrap;font-size:10px;line-height:14px;overflow:hidden}.MYaRJa_memberAction{min-width:60px}.MYaRJa_memberError{color:var(--dsw-alias-state-error-primary);grid-column:2/-1;margin:2px 0;font-size:11px;line-height:16px}.MYaRJa_modalBody{max-height:min(65vh,520px);overflow-y:auto}@media (width<=600px){.MYaRJa_memberRow{grid-template-columns:14px minmax(0,1fr)}.MYaRJa_memberAction{grid-column:2;justify-self:start;margin-top:3px}}@media (prefers-reduced-motion:reduce){.MYaRJa_taskFooter,.MYaRJa_taskArrow{transition:none}.MYaRJa_taskFooter:hover .MYaRJa_taskArrow,.MYaRJa_taskFooter:focus-visible .MYaRJa_taskArrow{transform:none}}";
|
|
7567
7877
|
const tagId$3 = "@wowyuarm/dsh-agent-team/channel.module.css";
|
|
7568
7878
|
if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=" + JSON.stringify(tagId$3) + "]") === null) {
|
|
7569
7879
|
const tag = document.createElement("style");
|
|
@@ -7590,7 +7900,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
7590
7900
|
};
|
|
7591
7901
|
//#endregion
|
|
7592
7902
|
//#region \0dsh-css:/home/yu/projects/dsh-agent-team/packages/client-agent-team/src/client/thread.module.css.mjs
|
|
7593
|
-
const css$2 = ".-Qiwua_titleLine{flex-wrap:wrap;align-items:center;gap:10px;display:flex}.-Qiwua_titleLine h1{margin:0}.-Qiwua_workSection{border-top:1px solid var(--dsw-alias-border-l2);max-width:880px;margin:12px auto 0;padding-top:8px}.-Qiwua_riskSection{border-top:1px solid var(--dsw-alias-border-l2);max-width:880px;margin:12px auto 0;padding-top:10px}.-Qiwua_riskSection h2{color:var(--dsw-alias-state-error-primary);margin:0 0 5px;font-size:12px;font-weight:600;line-height:18px}.-Qiwua_riskRow{color:var(--dsw-alias-label-secondary);align-items:center;gap:8px;margin:3px 0;font-size:12px;line-height:18px;display:flex}.-Qiwua_claimList{gap:4px;padding:4px 0 2px 22px;display:grid}.-Qiwua_claimRow{border-radius:6px;grid-template-columns:14px minmax(96px,auto) minmax(0,1fr) auto auto;align-items:center;gap:4px 8px;min-height:36px;padding:4px 6px;display:grid}.-Qiwua_claimRow:hover{background:var(--dsw-alias-interactive-bg-hover)}.-Qiwua_claimOwner{color:var(--dsw-alias-label-secondary);text-overflow:ellipsis;white-space:nowrap;font-size:11px;font-weight:500;line-height:18px;overflow:hidden}.-Qiwua_claimDirection{color:var(--dsw-alias-label-primary);overflow-wrap:anywhere;min-width:0;font-size:12px;line-height:18px}.-Qiwua_claimState{color:var(--dsw-alias-label-tertiary);white-space:nowrap;font-size:11px;line-height:18px}.-Qiwua_emptyClaims{color:var(--dsw-alias-label-tertiary);margin:0;padding:5px 6px;font-size:11px;line-height:18px}.-Qiwua_activityRow{color:var(--dsw-alias-label-tertiary);text-align:center;justify-content:center;align-items:center;gap:8px;max-width:100%;margin:4px auto;padding:5px 12px;font-size:11px;line-height:18px;display:flex}.-Qiwua_activityText{overflow-wrap:anywhere;min-width:0}.-Qiwua_activityMark{background:var(--dsw-alias-border-l3);border-radius:50%;flex:0 0 5px;width:5px;height:5px}.-Qiwua_historySection{border-bottom:1px solid var(--dsw-alias-border-l2);max-width:100%;margin:0 auto 12px;padding-bottom:10px}.-Qiwua_historySection h2{color:var(--dsw-alias-label-tertiary);letter-spacing:.02em;text-transform:uppercase;margin:0 0 4px;font-size:11px;font-weight:600;line-height:16px}.-Qiwua_publicSection{min-width:0}.-Qiwua_unreadBoundary{color:var(--dsw-alias-label-tertiary);align-items:center;gap:10px;margin:10px 0 6px;font-size:11px;line-height:16px;display:flex}.-Qiwua_unreadBoundary:before,.-Qiwua_unreadBoundary:after{background:var(--dsw-alias-border-l3);content:\"\";flex:1;height:1px}.-Qiwua_unreadBoundary span{flex:none}.-Qiwua_daySeparator{color:var(--dsw-alias-label-tertiary);letter-spacing:.02em;align-items:center;gap:10px;margin:12px 0 4px;font-size:11px;line-height:16px;display:flex}.-Qiwua_daySeparator:before,.-Qiwua_daySeparator:after{background:var(--dsw-alias-border-l2);content:\"\";flex:1;height:1px}.-Qiwua_daySeparator span{flex:none}.-Qiwua_newUpdates{background:var(--dsw-specific-input-major,var(--dsw-alias-bg-layer-1));border:1px solid var(--dsw-alias-border-l2-darkmode-thin);box-shadow:var(--dsw-shadow-lv2);color:var(--dsw-alias-label-secondary);z-index:2;border-radius:999px;justify-content:center;align-items:center;gap:8px;width:fit-content;margin:8px auto;padding:4px 6px 4px 12px;font-size:12px;line-height:18px;display:flex;position:sticky;bottom:8px}.-Qiwua_taskTitle{color:var(--dsw-alias-label-secondary)
|
|
7903
|
+
const css$2 = ".-Qiwua_titleLine{flex-wrap:wrap;align-items:center;gap:10px;display:flex}.-Qiwua_titleLine h1{margin:0}.-Qiwua_workSection{border-top:1px solid var(--dsw-alias-border-l2);max-width:880px;margin:12px auto 0;padding-top:8px}.-Qiwua_riskSection{border-top:1px solid var(--dsw-alias-border-l2);max-width:880px;margin:12px auto 0;padding-top:10px}.-Qiwua_riskSection h2{color:var(--dsw-alias-state-error-primary);margin:0 0 5px;font-size:12px;font-weight:600;line-height:18px}.-Qiwua_riskRow{color:var(--dsw-alias-label-secondary);align-items:center;gap:8px;margin:3px 0;font-size:12px;line-height:18px;display:flex}.-Qiwua_claimList{gap:4px;padding:4px 0 2px 22px;display:grid}.-Qiwua_claimRow{border-radius:6px;grid-template-columns:14px minmax(96px,auto) minmax(0,1fr) auto auto;align-items:center;gap:4px 8px;min-height:36px;padding:4px 6px;display:grid}.-Qiwua_claimRow:hover{background:var(--dsw-alias-interactive-bg-hover)}.-Qiwua_claimOwner{color:var(--dsw-alias-label-secondary);text-overflow:ellipsis;white-space:nowrap;font-size:11px;font-weight:500;line-height:18px;overflow:hidden}.-Qiwua_claimDirection{color:var(--dsw-alias-label-primary);overflow-wrap:anywhere;min-width:0;font-size:12px;line-height:18px}.-Qiwua_claimState{color:var(--dsw-alias-label-tertiary);white-space:nowrap;font-size:11px;line-height:18px}.-Qiwua_emptyClaims{color:var(--dsw-alias-label-tertiary);margin:0;padding:5px 6px;font-size:11px;line-height:18px}.-Qiwua_activityRow{color:var(--dsw-alias-label-tertiary);text-align:center;justify-content:center;align-items:center;gap:8px;max-width:100%;margin:4px auto;padding:5px 12px;font-size:11px;line-height:18px;display:flex}.-Qiwua_activityText{overflow-wrap:anywhere;min-width:0}.-Qiwua_activityMark{background:var(--dsw-alias-border-l3);border-radius:50%;flex:0 0 5px;width:5px;height:5px}.-Qiwua_activityRow:has(+.-Qiwua_activityRow),.-Qiwua_activityRow+.-Qiwua_activityRow{text-align:left;justify-content:flex-start;padding-left:38px}.-Qiwua_historySection{border-bottom:1px solid var(--dsw-alias-border-l2);max-width:100%;margin:0 auto 12px;padding-bottom:10px}.-Qiwua_historySection h2{color:var(--dsw-alias-label-tertiary);letter-spacing:.02em;text-transform:uppercase;margin:0 0 4px;font-size:11px;font-weight:600;line-height:16px}.-Qiwua_publicSection{min-width:0}.-Qiwua_unreadBoundary{color:var(--dsw-alias-label-tertiary);align-items:center;gap:10px;margin:10px 0 6px;font-size:11px;line-height:16px;display:flex}.-Qiwua_unreadBoundary:before,.-Qiwua_unreadBoundary:after{background:var(--dsw-alias-border-l3);content:\"\";flex:1;height:1px}.-Qiwua_unreadBoundary span{flex:none}.-Qiwua_daySeparator{color:var(--dsw-alias-label-tertiary);letter-spacing:.02em;align-items:center;gap:10px;margin:12px 0 4px;font-size:11px;line-height:16px;display:flex}.-Qiwua_daySeparator:before,.-Qiwua_daySeparator:after{background:var(--dsw-alias-border-l2);content:\"\";flex:1;height:1px}.-Qiwua_daySeparator span{flex:none}.-Qiwua_newUpdates{background:var(--dsw-specific-input-major,var(--dsw-alias-bg-layer-1));border:1px solid var(--dsw-alias-border-l2-darkmode-thin);box-shadow:var(--dsw-shadow-lv2);color:var(--dsw-alias-label-secondary);z-index:2;border-radius:999px;justify-content:center;align-items:center;gap:8px;width:fit-content;margin:8px auto;padding:4px 6px 4px 12px;font-size:12px;line-height:18px;display:flex;position:sticky;bottom:8px}.-Qiwua_taskTitle{color:var(--dsw-alias-label-secondary);-webkit-line-clamp:2;overflow-wrap:anywhere;-webkit-box-orient:vertical;margin:2px 0 0;font-size:13px;line-height:20px;display:-webkit-box;overflow:hidden}.-Qiwua_closedBar{flex-direction:column;align-items:center;display:flex}.-Qiwua_closedNotice{color:var(--dsw-alias-label-tertiary);flex-wrap:wrap;justify-content:center;align-items:center;gap:12px;padding:10px 16px 14px;font-size:13px;line-height:20px;display:flex}@media (width<=600px){.-Qiwua_claimRow{grid-template-columns:14px minmax(0,1fr) auto;align-items:start}.-Qiwua_claimState{grid-area:1/3;justify-self:end}.-Qiwua_claimDirection{grid-column:2/-1}.-Qiwua_activityRow{padding-inline:0}.-Qiwua_newUpdates{max-width:calc(100% - 16px)}}";
|
|
7594
7904
|
const tagId$2 = "@wowyuarm/dsh-agent-team/thread.module.css";
|
|
7595
7905
|
if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=" + JSON.stringify(tagId$2) + "]") === null) {
|
|
7596
7906
|
const tag = document.createElement("style");
|
|
@@ -7646,6 +7956,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
7646
7956
|
const [statusMessage, setStatusMessage] = (0, react.useState)();
|
|
7647
7957
|
const [loading, setLoading] = (0, react.useState)(true);
|
|
7648
7958
|
const [pending, setPending] = (0, react.useState)(false);
|
|
7959
|
+
const [asTask, setAsTask] = (0, react.useState)(false);
|
|
7649
7960
|
const [loadingOlder, setLoadingOlder] = (0, react.useState)(false);
|
|
7650
7961
|
const [managingMembers, setManagingMembers] = (0, react.useState)(false);
|
|
7651
7962
|
const draftKey = `channel:${channelRef}`;
|
|
@@ -7660,10 +7971,31 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
7660
7971
|
if (ref !== channelRef) selectChannel(ref);
|
|
7661
7972
|
return;
|
|
7662
7973
|
}
|
|
7974
|
+
if (ref.startsWith("thread:")) {
|
|
7975
|
+
const match = view?.items.find((item) => item.thread.threadRef === ref);
|
|
7976
|
+
if (match !== void 0) {
|
|
7977
|
+
selectThread(match.thread.threadRef, channelRef, match.task?.taskRef, match.taskNumber);
|
|
7978
|
+
return;
|
|
7979
|
+
}
|
|
7980
|
+
loadChannels({
|
|
7981
|
+
workspaceId,
|
|
7982
|
+
threadRef: ref,
|
|
7983
|
+
includeActivities: false,
|
|
7984
|
+
limit: 1
|
|
7985
|
+
}).then((result) => {
|
|
7986
|
+
if (!result.ok) return;
|
|
7987
|
+
const target = result.value.items[0];
|
|
7988
|
+
if (target !== void 0) {
|
|
7989
|
+
const targetChannel = result.value.channels.find((channel) => channel.channelRef === target.message.channelRef);
|
|
7990
|
+
if (targetChannel !== void 0) selectThread(target.thread.threadRef, targetChannel.channelRef, target.task?.taskRef, target.taskNumber);
|
|
7991
|
+
}
|
|
7992
|
+
});
|
|
7993
|
+
return;
|
|
7994
|
+
}
|
|
7663
7995
|
if (ref.startsWith("task:")) {
|
|
7664
|
-
const match = view?.items.find((item) => item.task
|
|
7996
|
+
const match = view?.items.find((item) => item.task?.taskRef === ref);
|
|
7665
7997
|
if (match !== void 0) {
|
|
7666
|
-
selectThread(match.
|
|
7998
|
+
selectThread(match.thread.threadRef, channelRef, match.task?.taskRef, match.taskNumber);
|
|
7667
7999
|
return;
|
|
7668
8000
|
}
|
|
7669
8001
|
jumpToTaskThread(resolveTaskRefs, workspaceId, ref, selectThread);
|
|
@@ -7828,6 +8160,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
7828
8160
|
channelRef,
|
|
7829
8161
|
body: draft.trim(),
|
|
7830
8162
|
recipients: recipientIds,
|
|
8163
|
+
asTask,
|
|
7831
8164
|
...attachmentIds.length === 0 ? {} : { attachments: attachmentIds }
|
|
7832
8165
|
});
|
|
7833
8166
|
if (!result.ok) {
|
|
@@ -7835,6 +8168,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
7835
8168
|
setError(result.error.message);
|
|
7836
8169
|
} else if (result.value.kind === "committed") {
|
|
7837
8170
|
pendingSendId.current = void 0;
|
|
8171
|
+
setAsTask(false);
|
|
7838
8172
|
await refresh();
|
|
7839
8173
|
drafts.clear(draftKey);
|
|
7840
8174
|
setPendingFiles([]);
|
|
@@ -8004,7 +8338,8 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
8004
8338
|
const senderStatus = members.find((member) => member.member.memberId === item.message.sender);
|
|
8005
8339
|
const human = item.message.sender === view.humanMemberId;
|
|
8006
8340
|
const sender = human ? t("human") : senderStatus?.member.handle ?? item.message.sender;
|
|
8007
|
-
|
|
8341
|
+
const turnGap = isRunGap(index > 0 ? block.items[index - 1].message.occurredAt : void 0, item.message.occurredAt);
|
|
8342
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react.Fragment, { children: [turnGap && /* @__PURE__ */ (0, react_jsx_runtime.jsx)(TeamRunDivider, { occurredAt: item.message.occurredAt }), /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(TeamMessage, {
|
|
8008
8343
|
senderName: sender,
|
|
8009
8344
|
memberId: item.message.sender,
|
|
8010
8345
|
human,
|
|
@@ -8017,13 +8352,14 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
8017
8352
|
onOpenRef: openRef,
|
|
8018
8353
|
onResolveTaskRefs: lookupTaskRefs,
|
|
8019
8354
|
grouped: index > 0,
|
|
8355
|
+
showGroupedTime: item.message.topLevel === true && !turnGap,
|
|
8020
8356
|
...senderStatus === void 0 ? {} : { senderTitle: senderStatus.member.description },
|
|
8021
|
-
children: item.message.topLevel && /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("button", {
|
|
8357
|
+
children: [item.message.topLevel && item.task !== void 0 && item.taskNumber !== void 0 && /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("button", {
|
|
8022
8358
|
type: "button",
|
|
8023
8359
|
className: channel_module_css_default.taskFooter,
|
|
8024
8360
|
"aria-label": t("openTask", { number: item.taskNumber }),
|
|
8025
8361
|
onClick: () => {
|
|
8026
|
-
selectThread(item.
|
|
8362
|
+
selectThread(item.thread.threadRef, channelRef, item.task?.taskRef, item.taskNumber);
|
|
8027
8363
|
},
|
|
8028
8364
|
children: [
|
|
8029
8365
|
/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
|
|
@@ -8057,7 +8393,29 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
8057
8393
|
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.IconChevronRightOutline14, { size: 12 })
|
|
8058
8394
|
})
|
|
8059
8395
|
]
|
|
8060
|
-
})
|
|
8396
|
+
}), item.message.topLevel && item.task === void 0 && /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("button", {
|
|
8397
|
+
type: "button",
|
|
8398
|
+
className: channel_module_css_default.taskFooter,
|
|
8399
|
+
"aria-label": t("openThread"),
|
|
8400
|
+
onClick: () => {
|
|
8401
|
+
selectThread(item.thread.threadRef, channelRef);
|
|
8402
|
+
},
|
|
8403
|
+
children: [
|
|
8404
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
|
|
8405
|
+
className: channel_module_css_default.taskNumber,
|
|
8406
|
+
children: t("threadLabel")
|
|
8407
|
+
}),
|
|
8408
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
|
|
8409
|
+
className: channel_module_css_default.taskCount,
|
|
8410
|
+
children: t("taskMessageCount", { count: item.messageCount })
|
|
8411
|
+
}),
|
|
8412
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
|
|
8413
|
+
className: channel_module_css_default.taskArrow,
|
|
8414
|
+
"aria-hidden": "true",
|
|
8415
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.IconChevronRightOutline14, { size: 12 })
|
|
8416
|
+
})
|
|
8417
|
+
]
|
|
8418
|
+
})]
|
|
8061
8419
|
})] }, item.message.messageRef);
|
|
8062
8420
|
})
|
|
8063
8421
|
}, `run-${block.items[0].message.messageRef}`))
|
|
@@ -8084,6 +8442,8 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
8084
8442
|
},
|
|
8085
8443
|
pendingFiles,
|
|
8086
8444
|
onFilesChange: setPendingFiles,
|
|
8445
|
+
asTask,
|
|
8446
|
+
onAsTaskChange: setAsTask,
|
|
8087
8447
|
t
|
|
8088
8448
|
}, draftKey) : /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {})
|
|
8089
8449
|
]
|
|
@@ -8114,7 +8474,11 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
8114
8474
|
return new Map(facts.map((fact) => [factKey(fact.fact), fact]));
|
|
8115
8475
|
}
|
|
8116
8476
|
function TeamThreadPage(props) {
|
|
8117
|
-
const { workspaceId, channelRef, taskRef, threadRef, taskNumber, backToWorkspace, selectChannel, selectThread, resolveTaskRefs, putAttachment, loadChannels, readThread, loadThreadHistory, subscribeChanges, loadMembers, drafts, getAttachment, reply, changeTask, t } = props;
|
|
8477
|
+
const { workspaceId, channelRef, taskRef, threadRef, taskNumber, backToWorkspace, selectChannel, selectThread, resolveTaskRefs, putAttachment, loadChannels, readThread, loadThreadHistory, subscribeChanges, loadMembers, drafts, getAttachment, reply, changeTask, promoteThread, t } = props;
|
|
8478
|
+
const threadRequest = {
|
|
8479
|
+
threadRef,
|
|
8480
|
+
...taskRef === void 0 ? {} : { taskRef }
|
|
8481
|
+
};
|
|
8118
8482
|
const [projection, setProjection] = (0, react.useState)();
|
|
8119
8483
|
const [channelView, setChannelView] = (0, react.useState)();
|
|
8120
8484
|
const [members, setMembers] = (0, react.useState)([]);
|
|
@@ -8130,12 +8494,13 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
8130
8494
|
const [claimsOpen, setClaimsOpen] = (0, react.useState)(false);
|
|
8131
8495
|
const [confirmingAccept, setConfirmingAccept] = (0, react.useState)(false);
|
|
8132
8496
|
(0, react.useEffect)(() => {
|
|
8133
|
-
if (confirmingAccept && projection?.task
|
|
8134
|
-
}, [confirmingAccept, projection?.task
|
|
8497
|
+
if (confirmingAccept && projection?.task?.resolution === "accepted") setConfirmingAccept(false);
|
|
8498
|
+
}, [confirmingAccept, projection?.task?.resolution]);
|
|
8135
8499
|
const [replyRequestId, setReplyRequestId] = (0, react.useState)();
|
|
8136
8500
|
const [confirmation, setConfirmation] = (0, react.useState)();
|
|
8137
8501
|
const [statusMessage, setStatusMessage] = (0, react.useState)();
|
|
8138
8502
|
const [pending, setPending] = (0, react.useState)(false);
|
|
8503
|
+
const [mutating, setMutating] = (0, react.useState)();
|
|
8139
8504
|
const [loading, setLoading] = (0, react.useState)(true);
|
|
8140
8505
|
const [error, setError] = (0, react.useState)();
|
|
8141
8506
|
const mountedRef = (0, react.useRef)(false);
|
|
@@ -8167,7 +8532,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
8167
8532
|
const result = await readThread({
|
|
8168
8533
|
requestId: readRequestIdRef.current,
|
|
8169
8534
|
workspaceId,
|
|
8170
|
-
|
|
8535
|
+
...threadRequest
|
|
8171
8536
|
});
|
|
8172
8537
|
if (!mountedRef.current || sequence !== sequenceRef.current) return false;
|
|
8173
8538
|
if (!result.ok) {
|
|
@@ -8206,7 +8571,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
8206
8571
|
try {
|
|
8207
8572
|
const result = await loadThreadHistory({
|
|
8208
8573
|
workspaceId,
|
|
8209
|
-
|
|
8574
|
+
...threadRequest,
|
|
8210
8575
|
limit: 100
|
|
8211
8576
|
});
|
|
8212
8577
|
if (!mountedRef.current || !result.ok) return;
|
|
@@ -8223,7 +8588,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
8223
8588
|
});
|
|
8224
8589
|
setProjection((current) => current === void 0 ? current : {
|
|
8225
8590
|
...current,
|
|
8226
|
-
task: result.value.task,
|
|
8591
|
+
...result.value.task === void 0 ? {} : { task: result.value.task },
|
|
8227
8592
|
thread: result.value.thread,
|
|
8228
8593
|
claims: result.value.claims
|
|
8229
8594
|
});
|
|
@@ -8260,10 +8625,10 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
8260
8625
|
const [read, history] = await Promise.all([readThread({
|
|
8261
8626
|
requestId: readRequestIdRef.current,
|
|
8262
8627
|
workspaceId,
|
|
8263
|
-
|
|
8628
|
+
...threadRequest
|
|
8264
8629
|
}), loadThreadHistory({
|
|
8265
8630
|
workspaceId,
|
|
8266
|
-
|
|
8631
|
+
...threadRequest,
|
|
8267
8632
|
limit: 20
|
|
8268
8633
|
}).catch(() => void 0)]);
|
|
8269
8634
|
if (!mountedRef.current || sequence !== sequenceRef.current) return;
|
|
@@ -8326,7 +8691,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
8326
8691
|
try {
|
|
8327
8692
|
const result = await loadThreadHistory({
|
|
8328
8693
|
workspaceId,
|
|
8329
|
-
|
|
8694
|
+
...threadRequest,
|
|
8330
8695
|
beforeSequence,
|
|
8331
8696
|
limit: 20
|
|
8332
8697
|
});
|
|
@@ -8348,6 +8713,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
8348
8713
|
const activeProjection = projection;
|
|
8349
8714
|
const task = activeProjection?.task;
|
|
8350
8715
|
const thread = activeProjection?.thread;
|
|
8716
|
+
const resolvedTaskNumber = taskNumber ?? channelView?.taskNumbers.find((entry) => entry.taskRef === task?.taskRef)?.taskNumber;
|
|
8351
8717
|
const taskTitle = activeProjection === void 0 ? void 0 : formatTaskTitle(activeProjection.anchor.body);
|
|
8352
8718
|
const taskClaims = activeProjection?.claims ?? [];
|
|
8353
8719
|
const effectiveChannelRef = task?.channelRef ?? channelRef;
|
|
@@ -8371,7 +8737,25 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
8371
8737
|
const messageSender = (fact) => fact.kind === "message" ? fact.message.sender : void 0;
|
|
8372
8738
|
const [pendingFiles, setPendingFiles] = (0, react.useState)([]);
|
|
8373
8739
|
const openRef = (ref) => {
|
|
8374
|
-
if (ref.startsWith("channel:") && ref !== channelRef)
|
|
8740
|
+
if (ref.startsWith("channel:") && ref !== channelRef) {
|
|
8741
|
+
selectChannel(ref);
|
|
8742
|
+
return;
|
|
8743
|
+
}
|
|
8744
|
+
if (ref.startsWith("thread:") && ref !== threadRef) {
|
|
8745
|
+
loadChannels({
|
|
8746
|
+
workspaceId,
|
|
8747
|
+
threadRef: ref,
|
|
8748
|
+
includeActivities: false,
|
|
8749
|
+
limit: 1
|
|
8750
|
+
}).then((result) => {
|
|
8751
|
+
if (!result.ok) return;
|
|
8752
|
+
const target = result.value.items[0];
|
|
8753
|
+
if (target === void 0) return;
|
|
8754
|
+
const targetChannel = result.value.channels.find((channel) => channel.channelRef === target.message.channelRef);
|
|
8755
|
+
if (targetChannel !== void 0) selectThread(target.thread.threadRef, targetChannel.channelRef, target.task?.taskRef, target.taskNumber);
|
|
8756
|
+
});
|
|
8757
|
+
return;
|
|
8758
|
+
}
|
|
8375
8759
|
if (ref.startsWith("task:") && ref !== taskRef) jumpToTaskThread(resolveTaskRefs, workspaceId, ref, selectThread);
|
|
8376
8760
|
};
|
|
8377
8761
|
const lookupTaskRefs = hostTaskRefLookup(resolveTaskRefs, workspaceId);
|
|
@@ -8461,9 +8845,64 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
8461
8845
|
await readCurrent(true);
|
|
8462
8846
|
await refreshSupplemental();
|
|
8463
8847
|
};
|
|
8848
|
+
const convertToTask = async () => {
|
|
8849
|
+
if (pending || thread === void 0 || task !== void 0) return;
|
|
8850
|
+
setPending(true);
|
|
8851
|
+
setMutating("promote");
|
|
8852
|
+
setError(void 0);
|
|
8853
|
+
const key = "promote";
|
|
8854
|
+
const requestId = mutationRequests.current.get(key) ?? mintRequestId();
|
|
8855
|
+
mutationRequests.current.set(key, requestId);
|
|
8856
|
+
try {
|
|
8857
|
+
const result = await promoteThread({
|
|
8858
|
+
requestId,
|
|
8859
|
+
workspaceId,
|
|
8860
|
+
threadRef,
|
|
8861
|
+
baseRevision: thread.revision
|
|
8862
|
+
});
|
|
8863
|
+
if (!result.ok) {
|
|
8864
|
+
setError(result.error.message);
|
|
8865
|
+
return;
|
|
8866
|
+
}
|
|
8867
|
+
if (result.value.kind === "committed") {
|
|
8868
|
+
mutationRequests.current.delete(key);
|
|
8869
|
+
const committed = result.value;
|
|
8870
|
+
setProjection((current) => current === void 0 ? current : {
|
|
8871
|
+
...current,
|
|
8872
|
+
task: committed.task,
|
|
8873
|
+
thread: committed.thread
|
|
8874
|
+
});
|
|
8875
|
+
setCurrentFacts((current) => {
|
|
8876
|
+
const merged = mergeFacts(current, [{
|
|
8877
|
+
kind: "activity",
|
|
8878
|
+
sequence: committed.activity.sequence,
|
|
8879
|
+
activity: committed.activity
|
|
8880
|
+
}]);
|
|
8881
|
+
currentFactsRef.current = merged;
|
|
8882
|
+
return merged;
|
|
8883
|
+
});
|
|
8884
|
+
await readCurrent(true);
|
|
8885
|
+
await refreshSupplemental();
|
|
8886
|
+
} else if (result.value.kind === "unread_required") {
|
|
8887
|
+
setError(t("unreadRequired", { count: result.value.unreadCount }));
|
|
8888
|
+
mutationRequests.current.delete(key);
|
|
8889
|
+
await refreshAfterFence();
|
|
8890
|
+
} else {
|
|
8891
|
+
setError(t("staleRevision"));
|
|
8892
|
+
mutationRequests.current.delete(key);
|
|
8893
|
+
await refreshPassiveFacts();
|
|
8894
|
+
}
|
|
8895
|
+
} catch (cause) {
|
|
8896
|
+
setError(cause instanceof Error ? cause.message : String(cause));
|
|
8897
|
+
} finally {
|
|
8898
|
+
setPending(false);
|
|
8899
|
+
setMutating(void 0);
|
|
8900
|
+
}
|
|
8901
|
+
};
|
|
8464
8902
|
const mutateTask = async (action) => {
|
|
8465
8903
|
if (pending || task === void 0 || thread === void 0) return;
|
|
8466
8904
|
setPending(true);
|
|
8905
|
+
if (action === "accept") setMutating("accept");
|
|
8467
8906
|
setError(void 0);
|
|
8468
8907
|
const key = `task:${action}`;
|
|
8469
8908
|
const requestId = mutationRequests.current.get(key) ?? mintRequestId();
|
|
@@ -8513,10 +8952,11 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
8513
8952
|
setError(cause instanceof Error ? cause.message : String(cause));
|
|
8514
8953
|
} finally {
|
|
8515
8954
|
setPending(false);
|
|
8955
|
+
setMutating(void 0);
|
|
8516
8956
|
}
|
|
8517
8957
|
};
|
|
8518
8958
|
const sendReply = async () => {
|
|
8519
|
-
if (pending ||
|
|
8959
|
+
if (pending || thread === void 0 || draft.trim() === "") return;
|
|
8520
8960
|
const id = replyRequestId ?? mintRequestId();
|
|
8521
8961
|
setReplyRequestId(id);
|
|
8522
8962
|
setPending(true);
|
|
@@ -8540,7 +8980,8 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
8540
8980
|
const result = await reply({
|
|
8541
8981
|
requestId: id,
|
|
8542
8982
|
workspaceId,
|
|
8543
|
-
|
|
8983
|
+
threadRef,
|
|
8984
|
+
...task === void 0 ? {} : { taskRef: task.taskRef },
|
|
8544
8985
|
body: draft.trim(),
|
|
8545
8986
|
baseRevision: thread.revision,
|
|
8546
8987
|
recipients: [...recipients].sort(),
|
|
@@ -8565,7 +9006,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
8565
9006
|
});
|
|
8566
9007
|
setProjection((current) => current === void 0 ? current : {
|
|
8567
9008
|
...current,
|
|
8568
|
-
task: committed.task,
|
|
9009
|
+
...committed.task === void 0 ? {} : { task: committed.task },
|
|
8569
9010
|
thread: committed.thread
|
|
8570
9011
|
});
|
|
8571
9012
|
drafts.clear(draftKey);
|
|
@@ -8629,49 +9070,65 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
8629
9070
|
}),
|
|
8630
9071
|
/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("header", {
|
|
8631
9072
|
className: conversation_module_css_default.headerRow,
|
|
8632
|
-
children: [
|
|
8633
|
-
|
|
8634
|
-
|
|
8635
|
-
|
|
8636
|
-
|
|
8637
|
-
|
|
8638
|
-
|
|
8639
|
-
|
|
8640
|
-
|
|
8641
|
-
|
|
8642
|
-
|
|
8643
|
-
|
|
8644
|
-
|
|
8645
|
-
|
|
8646
|
-
|
|
8647
|
-
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Button, {
|
|
9073
|
+
children: [
|
|
9074
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
|
|
9075
|
+
className: conversation_module_css_default.headerCopy,
|
|
9076
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
|
|
9077
|
+
className: thread_module_css_default.titleLine,
|
|
9078
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("h1", { children: task === void 0 ? t("threadLabel") : t("taskLabel", { number: resolvedTaskNumber ?? "…" }) }), task !== void 0 && /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Pill, { children: formatTaskStatus(task.status, t) })]
|
|
9079
|
+
}), taskTitle !== void 0 && taskTitle !== "" && /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
|
|
9080
|
+
className: thread_module_css_default.taskTitle,
|
|
9081
|
+
title: taskTitle,
|
|
9082
|
+
children: taskTitle
|
|
9083
|
+
})]
|
|
9084
|
+
}),
|
|
9085
|
+
task === void 0 && thread !== void 0 && /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
9086
|
+
className: conversation_module_css_default.headerActions,
|
|
9087
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Button, {
|
|
8648
9088
|
size: "sm",
|
|
8649
9089
|
variant: "primary",
|
|
8650
9090
|
disabled: pending,
|
|
8651
9091
|
onClick: () => {
|
|
8652
|
-
|
|
8653
|
-
else mutateTask("accept");
|
|
9092
|
+
convertToTask();
|
|
8654
9093
|
},
|
|
8655
|
-
children: t("
|
|
8656
|
-
})
|
|
8657
|
-
})
|
|
8658
|
-
|
|
8659
|
-
|
|
8660
|
-
|
|
8661
|
-
|
|
8662
|
-
|
|
8663
|
-
|
|
8664
|
-
|
|
8665
|
-
|
|
8666
|
-
|
|
8667
|
-
|
|
8668
|
-
|
|
8669
|
-
|
|
8670
|
-
|
|
8671
|
-
|
|
8672
|
-
|
|
8673
|
-
|
|
8674
|
-
|
|
9094
|
+
children: mutating === "promote" ? t("promotingTask") : t("promoteToTask")
|
|
9095
|
+
})
|
|
9096
|
+
}),
|
|
9097
|
+
task !== void 0 && thread !== void 0 && task.resolution !== "closed" && /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
|
|
9098
|
+
className: conversation_module_css_default.headerActions,
|
|
9099
|
+
children: [(() => {
|
|
9100
|
+
const activeClaims = projection?.claims.filter((claim) => claim.taskRef === task.taskRef && claim.state === "active") ?? [];
|
|
9101
|
+
const earlyAccept = task.resolution === "open" && task.status === "in_progress" && activeClaims.length > 0;
|
|
9102
|
+
if (!(task.status === "in_review" || task.status === "todo" || earlyAccept) || task.resolution !== "open") return null;
|
|
9103
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Button, {
|
|
9104
|
+
size: "sm",
|
|
9105
|
+
variant: "primary",
|
|
9106
|
+
disabled: pending,
|
|
9107
|
+
onClick: () => {
|
|
9108
|
+
if (earlyAccept) setConfirmingAccept(true);
|
|
9109
|
+
else mutateTask("accept");
|
|
9110
|
+
},
|
|
9111
|
+
children: t("acceptTask")
|
|
9112
|
+
});
|
|
9113
|
+
})(), task.resolution === "open" ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Button, {
|
|
9114
|
+
size: "sm",
|
|
9115
|
+
variant: "outline",
|
|
9116
|
+
disabled: pending,
|
|
9117
|
+
onClick: () => {
|
|
9118
|
+
mutateTask("close");
|
|
9119
|
+
},
|
|
9120
|
+
children: t("closeTask")
|
|
9121
|
+
}) : /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Button, {
|
|
9122
|
+
size: "sm",
|
|
9123
|
+
variant: "primary",
|
|
9124
|
+
disabled: pending,
|
|
9125
|
+
onClick: () => {
|
|
9126
|
+
mutateTask("reopen");
|
|
9127
|
+
},
|
|
9128
|
+
children: t("reopenTask")
|
|
9129
|
+
})]
|
|
9130
|
+
})
|
|
9131
|
+
]
|
|
8675
9132
|
}),
|
|
8676
9133
|
risks.length > 0 && /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("section", {
|
|
8677
9134
|
className: thread_module_css_default.riskSection,
|
|
@@ -8713,7 +9170,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
8713
9170
|
onClick: () => {
|
|
8714
9171
|
mutateTask("accept");
|
|
8715
9172
|
},
|
|
8716
|
-
children:
|
|
9173
|
+
children: mutating === "accept" ? t("acceptingTask") : t("acceptTask")
|
|
8717
9174
|
})] }),
|
|
8718
9175
|
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
|
|
8719
9176
|
className: conversation_module_css_default.confirmBody,
|
|
@@ -8853,7 +9310,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
8853
9310
|
]
|
|
8854
9311
|
})
|
|
8855
9312
|
}),
|
|
8856
|
-
projection !== void 0 &&
|
|
9313
|
+
projection !== void 0 && thread !== void 0 ? task?.resolution === "closed" ? /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
|
|
8857
9314
|
className: thread_module_css_default.closedBar,
|
|
8858
9315
|
"data-team-closed": true,
|
|
8859
9316
|
children: [error !== void 0 && /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
|
|
@@ -8894,6 +9351,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
8894
9351
|
onSubmit: () => {
|
|
8895
9352
|
sendReply();
|
|
8896
9353
|
},
|
|
9354
|
+
placeholder: t("replyPlaceholder"),
|
|
8897
9355
|
pendingFiles,
|
|
8898
9356
|
onFilesChange: setPendingFiles,
|
|
8899
9357
|
t
|
|
@@ -8903,19 +9361,19 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
8903
9361
|
}
|
|
8904
9362
|
//#endregion
|
|
8905
9363
|
//#region src/client/TeamConversation.tsx
|
|
8906
|
-
function TeamConversation({ t, useWorkspaces, navigation, drafts, putAttachment, getAttachment, loadChannels, readThread, loadThreadHistory, subscribeChanges, loadMembers, sendMessage, joinChannel, removeChannelMember, reply, changeTask, selectThread, selectChannel, backToWorkspace, backToChannels, resolveTaskRefs }) {
|
|
9364
|
+
function TeamConversation({ t, useWorkspaces, navigation, drafts, putAttachment, getAttachment, loadChannels, readThread, loadThreadHistory, subscribeChanges, loadMembers, sendMessage, joinChannel, removeChannelMember, reply, changeTask, promoteThread, selectThread, selectChannel, backToWorkspace, backToChannels, resolveTaskRefs }) {
|
|
8907
9365
|
const navigationState = (0, react.useSyncExternalStore)(navigation.subscribe, navigation.getSnapshot, navigation.getSnapshot);
|
|
8908
9366
|
const current = useWorkspaces((state) => state.items).find((workspace) => workspace.workspaceId === navigationState.workspaceId);
|
|
8909
|
-
if (current !== void 0 && navigationState.
|
|
9367
|
+
if (current !== void 0 && navigationState.threadRef !== void 0) return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(TeamThreadPage, {
|
|
8910
9368
|
workspaceId: current.workspaceId,
|
|
8911
9369
|
putAttachment,
|
|
8912
|
-
taskRef: navigationState.taskRef,
|
|
8913
9370
|
threadRef: navigationState.threadRef,
|
|
8914
9371
|
backToWorkspace,
|
|
8915
9372
|
selectChannel,
|
|
8916
9373
|
selectThread,
|
|
8917
9374
|
resolveTaskRefs,
|
|
8918
9375
|
...navigationState.channelRef === void 0 ? {} : { channelRef: navigationState.channelRef },
|
|
9376
|
+
...navigationState.taskRef === void 0 ? {} : { taskRef: navigationState.taskRef },
|
|
8919
9377
|
...navigationState.taskNumber === void 0 ? {} : { taskNumber: navigationState.taskNumber },
|
|
8920
9378
|
drafts,
|
|
8921
9379
|
getAttachment,
|
|
@@ -8926,6 +9384,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
8926
9384
|
loadMembers,
|
|
8927
9385
|
reply,
|
|
8928
9386
|
changeTask,
|
|
9387
|
+
promoteThread,
|
|
8929
9388
|
t
|
|
8930
9389
|
}, navigationState.threadRef);
|
|
8931
9390
|
if (current !== void 0 && navigationState.channelRef !== void 0) return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(TeamChannelPage, {
|
|
@@ -8973,7 +9432,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
8973
9432
|
}
|
|
8974
9433
|
//#endregion
|
|
8975
9434
|
//#region \0dsh-css:/home/yu/projects/dsh-agent-team/packages/client-agent-team/src/client/sidebar.module.css.mjs
|
|
8976
|
-
const css$1 = "html[data-agent-team-mode=team] button[class*=newSession]{display:none}.d0xfxa_workspaceBrowser{flex-direction:column;height:100%;min-height:0;padding:0 8px 8px;display:flex}.
|
|
9435
|
+
const css$1 = "html[data-agent-team-mode=team] button[class*=newSession]{display:none}.d0xfxa_workspaceBrowser{flex-direction:column;height:100%;min-height:0;padding:0 8px 8px;display:flex}.d0xfxa_railButton{color:var(--dsw-alias-label-secondary);cursor:pointer;background:0 0;border:0;justify-content:center;align-items:center;padding:0;display:inline-flex}.d0xfxa_railButton:hover,.d0xfxa_railButton:focus-visible{background:var(--dsw-alias-interactive-bg-hover);color:var(--dsw-alias-label-primary);outline:none}.d0xfxa_workspaceList{flex-direction:column;gap:2px;padding-bottom:2px;display:flex}.d0xfxa_workspaceRow{color:var(--dsw-alias-label-primary);cursor:pointer;text-align:left;background:0 0;border:0;border-radius:8px;align-items:center;gap:6px;width:100%;height:34px;padding:0 8px;display:flex}.d0xfxa_workspaceRow:hover,.d0xfxa_workspaceRow:focus-visible,.d0xfxa_workspaceRow[aria-current=page]{background:var(--dsw-alias-interactive-bg-hover);outline:none}.d0xfxa_workspaceRow:focus-visible{box-shadow:inset 0 0 0 1px var(--dsw-alias-border-l3)}.d0xfxa_workspaceIcon{color:var(--dsw-alias-label-tertiary);flex:0 0 16px;justify-content:center;align-items:center;height:20px;display:inline-flex}.d0xfxa_workspaceRow[data-selected] .d0xfxa_workspaceIcon{color:var(--dsw-alias-state-business-primary)}.d0xfxa_workspaceCopy{min-width:0;display:flex}.d0xfxa_workspaceCopy strong{text-overflow:ellipsis;white-space:nowrap;font-size:14px;font-weight:400;line-height:20px;overflow:hidden}.d0xfxa_emptyState{color:var(--dsw-alias-label-tertiary);margin:8px;font-size:12px;line-height:18px}.d0xfxa_railWorkspace{flex-direction:column;align-items:center;gap:8px;padding-top:8px;display:flex}.d0xfxa_railButton{border-radius:50%;width:36px;height:36px}.d0xfxa_railButton[data-active]{background:var(--dsw-alias-interactive-bg-hover);color:var(--dsw-alias-label-primary)}.d0xfxa_workspaceSection{flex-direction:column;flex:1;gap:4px;min-height:0;margin-top:2px;display:flex;overflow-y:auto}.d0xfxa_section{flex-direction:column;display:flex}.d0xfxa_sectionHeader{align-items:center;min-height:26px;padding-right:2px;display:flex}.d0xfxa_sectionToggle{color:var(--dsw-alias-label-tertiary);cursor:pointer;background:0 0;border:0;align-items:center;gap:4px;min-width:0;min-height:24px;padding:0 6px;font-size:12px;line-height:18px;display:inline-flex}.d0xfxa_sectionToggle:focus-visible{outline:none}.d0xfxa_sectionToggle:hover .d0xfxa_sectionChevron,.d0xfxa_sectionToggle:focus-visible .d0xfxa_sectionChevron{color:var(--dsw-alias-label-primary)}.d0xfxa_sectionChevron{color:var(--dsw-alias-label-tertiary);flex:none;transition:transform .12s,color .12s}.d0xfxa_sectionToggle[aria-expanded=false] .d0xfxa_sectionChevron{transform:rotate(-90deg)}.d0xfxa_sectionTitle{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.d0xfxa_sectionActions{align-items:center;margin-left:auto;display:inline-flex}.d0xfxa_panel{flex-direction:column;display:flex}.d0xfxa_iconButton{color:var(--dsw-alias-label-secondary);cursor:pointer;background:0 0;border:0;border-radius:50%;justify-content:center;align-items:center;width:24px;height:24px;padding:0;display:inline-flex}.d0xfxa_iconButton:hover,.d0xfxa_iconButton:focus-visible{background:var(--dsw-alias-interactive-bg-hover);color:var(--dsw-alias-label-primary);outline:none}.d0xfxa_textButton{color:var(--dsw-alias-label-secondary);cursor:pointer;background:0 0;border:0;border-radius:5px;padding:2px 5px;font-size:11px;line-height:18px}.d0xfxa_textButton:hover,.d0xfxa_textButton:focus-visible{background:var(--dsw-alias-interactive-bg-hover);color:var(--dsw-alias-label-primary);outline:none}.d0xfxa_textButton:disabled{cursor:not-allowed;opacity:.4}.d0xfxa_channelList,.d0xfxa_agentList{flex-direction:column;gap:1px;padding:0 4px 4px;display:flex}.d0xfxa_sidebarRowDragging{opacity:.5}.d0xfxa_sidebarRowDropBefore,.d0xfxa_sidebarRowDropAfter{position:relative}.d0xfxa_sidebarRowDropBefore:before,.d0xfxa_sidebarRowDropAfter:after{content:\"\";z-index:1;background:linear-gradient(55deg, transparent calc(50% - 1px), var(--dsw-alias-state-business-primary) calc(50% - 1px) calc(50% + 1px), transparent calc(50% + 1px)) 0 0 / 5px 7px no-repeat, linear-gradient(125deg, transparent calc(50% - 1px), var(--dsw-alias-state-business-primary) calc(50% - 1px) calc(50% + 1px), transparent calc(50% + 1px)) 0 5px / 5px 7px no-repeat, linear-gradient(var(--dsw-alias-state-business-primary) 0 0) 4px 5px / calc(100% - 4px) 2px no-repeat;pointer-events:none;height:12px;position:absolute;left:0;right:4px}.d0xfxa_sidebarRowDropBefore:before{top:-7px}.d0xfxa_sidebarRowDropAfter:after{bottom:-7px}.d0xfxa_channelRow{color:var(--dsw-alias-label-primary);border-radius:8px;align-items:center;min-height:30px;display:flex;position:relative}.d0xfxa_channelSelect{box-sizing:border-box;color:inherit;cursor:pointer;text-align:left;background:0 0;border:0;flex:1;align-items:center;min-width:0;min-height:30px;padding:3px 4px 3px 8px;display:flex}.d0xfxa_channelSelect:focus-visible{outline:none}.d0xfxa_channelName{text-overflow:ellipsis;white-space:nowrap;font-size:13px;font-weight:400;line-height:18px;overflow:hidden}.d0xfxa_agentRow{color:var(--dsw-alias-label-primary);border-radius:8px;align-items:center;min-height:38px;display:flex;position:relative}.d0xfxa_agentSelect{box-sizing:border-box;color:inherit;cursor:pointer;text-align:left;background:0 0;border:0;flex:1;grid-template-columns:24px minmax(0,1fr);align-items:center;gap:0 8px;min-width:0;min-height:38px;padding:3px 4px 3px 8px;display:grid}.d0xfxa_agentSelect:focus-visible{outline:none}.d0xfxa_agentSelect[aria-current=page]{background:var(--dsw-alias-interactive-bg-hover);border-radius:8px}.d0xfxa_agentRow:hover .d0xfxa_agentSelect[aria-current=page],.d0xfxa_agentRow:focus-within .d0xfxa_agentSelect[aria-current=page],.d0xfxa_agentRow[data-menu-open] .d0xfxa_agentSelect[aria-current=page]{background:0 0}.d0xfxa_agentAvatar{background:hsl(var(--team-avatar-hue,212) 42% 46%);color:#fff;cursor:default;border-radius:50%;flex:0 0 24px;justify-content:center;align-items:center;width:24px;height:24px;font-size:11px;font-weight:600;display:inline-flex;position:relative}.d0xfxa_agentAvatarBadge{background:var(--dsw-specific-sidebar-fill);box-shadow:0 0 0 1px var(--dsw-specific-sidebar-fill);border-radius:50%;justify-content:center;align-items:center;width:12px;height:12px;padding:1px;line-height:0;display:inline-flex;position:absolute;bottom:-3px;right:-3px}.d0xfxa_agentCopy{flex-direction:column;min-width:0;display:flex}.d0xfxa_agentCopy strong{text-overflow:ellipsis;white-space:nowrap;font-size:13px;font-weight:400;line-height:17px;overflow:hidden}.d0xfxa_agentCopy small{color:var(--dsw-alias-label-tertiary);text-overflow:ellipsis;white-space:nowrap;font-size:10px;line-height:13px;overflow:hidden}.d0xfxa_unavailableDot{background:var(--dsw-alias-label-tertiary);border-radius:50%;width:7px;height:7px;display:inline-block}.d0xfxa_rowMenu{flex:none;align-items:center;padding-right:4px;display:none}.d0xfxa_channelRow:hover .d0xfxa_rowMenu,.d0xfxa_channelRow:focus-within .d0xfxa_rowMenu,.d0xfxa_channelRow[data-menu-open] .d0xfxa_rowMenu,.d0xfxa_agentRow:hover .d0xfxa_rowMenu,.d0xfxa_agentRow:focus-within .d0xfxa_rowMenu,.d0xfxa_agentRow[data-menu-open] .d0xfxa_rowMenu{display:inline-flex}.d0xfxa_channelRow[data-menu-open],.d0xfxa_agentRow[data-menu-open],.d0xfxa_channelRow:hover,.d0xfxa_agentRow:hover,.d0xfxa_channelRow:focus-within,.d0xfxa_agentRow:focus-within,.d0xfxa_channelRow[aria-current=page]{background:var(--dsw-alias-interactive-bg-hover)}.d0xfxa_rowMenuButton{color:var(--dsw-alias-label-tertiary);cursor:pointer;background:0 0;border:0;border-radius:4px;justify-content:center;align-items:center;width:20px;height:20px;padding:0;display:inline-flex}.d0xfxa_rowMenuButton:hover,.d0xfxa_rowMenuButton:focus-visible{color:var(--dsw-alias-label-primary);outline:none}.d0xfxa_retryError{color:var(--dsw-alias-state-error-primary);justify-content:space-between;align-items:center;gap:8px;padding:8px;font-size:11px;display:flex}.d0xfxa_rowAlert{color:var(--dsw-alias-state-error-primary);overflow-wrap:anywhere;padding:2px 8px 6px;font-size:11px}.d0xfxa_editDescription{color:var(--dsw-alias-label-secondary);margin:0 0 10px;font-size:12px;line-height:18px}.d0xfxa_editMemberList{gap:3px;display:grid}.d0xfxa_editMemberRow{border-radius:6px;grid-template-columns:14px minmax(0,1fr) auto;align-items:center;gap:0 8px;min-height:40px;padding:3px 6px;display:grid}.d0xfxa_editMemberRowChannels{grid-template-columns:minmax(0,1fr) auto}.d0xfxa_editMemberRow:hover{background:var(--dsw-alias-interactive-bg-hover)}.d0xfxa_editMemberCopy{min-width:0;display:grid}.d0xfxa_editMemberCopy strong{color:var(--dsw-alias-label-primary);text-overflow:ellipsis;white-space:nowrap;font-size:12px;font-weight:500;line-height:18px;overflow:hidden}.d0xfxa_editMemberCopy small{color:var(--dsw-alias-label-tertiary);text-overflow:ellipsis;white-space:nowrap;font-size:10px;line-height:14px;overflow:hidden}.d0xfxa_editChannelName{text-overflow:ellipsis;white-space:nowrap;font-size:13px;font-weight:400;line-height:18px;overflow:hidden}.d0xfxa_editMemberRow button{min-width:60px}.d0xfxa_editHint{color:var(--dsw-alias-label-tertiary);margin:0;font-size:11px;line-height:16px}.d0xfxa_menuHint{color:var(--dsw-alias-label-tertiary);margin-left:4px;font-size:10px;line-height:14px}.d0xfxa_rowError{color:var(--dsw-alias-state-error-primary);grid-column:1/-1;margin:2px 0;font-size:11px;line-height:16px}";
|
|
8977
9436
|
const tagId$1 = "@wowyuarm/dsh-agent-team/sidebar.module.css";
|
|
8978
9437
|
if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=" + JSON.stringify(tagId$1) + "]") === null) {
|
|
8979
9438
|
const tag = document.createElement("style");
|
|
@@ -9007,6 +9466,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
9007
9466
|
"railButton": "d0xfxa_railButton",
|
|
9008
9467
|
"railWorkspace": "d0xfxa_railWorkspace",
|
|
9009
9468
|
"retryError": "d0xfxa_retryError",
|
|
9469
|
+
"rowAlert": "d0xfxa_rowAlert",
|
|
9010
9470
|
"rowError": "d0xfxa_rowError",
|
|
9011
9471
|
"rowMenu": "d0xfxa_rowMenu",
|
|
9012
9472
|
"rowMenuButton": "d0xfxa_rowMenuButton",
|
|
@@ -9023,7 +9483,6 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
9023
9483
|
"unavailableDot": "d0xfxa_unavailableDot",
|
|
9024
9484
|
"workspaceBrowser": "d0xfxa_workspaceBrowser",
|
|
9025
9485
|
"workspaceCopy": "d0xfxa_workspaceCopy",
|
|
9026
|
-
"workspaceHeader": "d0xfxa_workspaceHeader",
|
|
9027
9486
|
"workspaceIcon": "d0xfxa_workspaceIcon",
|
|
9028
9487
|
"workspaceList": "d0xfxa_workspaceList",
|
|
9029
9488
|
"workspaceRow": "d0xfxa_workspaceRow",
|
|
@@ -9052,6 +9511,118 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
9052
9511
|
});
|
|
9053
9512
|
}
|
|
9054
9513
|
//#endregion
|
|
9514
|
+
//#region src/client/TeamSidebarSection.tsx
|
|
9515
|
+
/** Collapsible sidebar section header: disclosure toggle plus trailing actions. */
|
|
9516
|
+
function TeamSidebarSection({ title, actions, open, onToggle, children }) {
|
|
9517
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("section", {
|
|
9518
|
+
className: sidebar_module_css_default.section,
|
|
9519
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
|
|
9520
|
+
className: sidebar_module_css_default.sectionHeader,
|
|
9521
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("button", {
|
|
9522
|
+
type: "button",
|
|
9523
|
+
className: sidebar_module_css_default.sectionToggle,
|
|
9524
|
+
"aria-expanded": open,
|
|
9525
|
+
onClick: () => {
|
|
9526
|
+
onToggle(!open);
|
|
9527
|
+
},
|
|
9528
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.IconChevronDownOutline14, { className: sidebar_module_css_default.sectionChevron }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
|
|
9529
|
+
className: sidebar_module_css_default.sectionTitle,
|
|
9530
|
+
children: title
|
|
9531
|
+
})]
|
|
9532
|
+
}), actions !== void 0 && /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
|
|
9533
|
+
className: sidebar_module_css_default.sectionActions,
|
|
9534
|
+
children: actions
|
|
9535
|
+
})]
|
|
9536
|
+
}), open && children]
|
|
9537
|
+
});
|
|
9538
|
+
}
|
|
9539
|
+
//#endregion
|
|
9540
|
+
//#region src/client/sidebar-sections.ts
|
|
9541
|
+
/**
|
|
9542
|
+
* Human presentation preference for the Team sidebar: whether each disclosure
|
|
9543
|
+
* section (workspaces / channels / agents) is expanded. The state lives in
|
|
9544
|
+
* this browser only — it is UI taste, never a shared Team fact, so nothing
|
|
9545
|
+
* here touches the ledger. Same storage discipline as `sidebar-order.ts`: one
|
|
9546
|
+
* localStorage key, defensive parsing, a read-through cache over the raw
|
|
9547
|
+
* payload so writes from other tabs are picked up, and an in-memory fallback
|
|
9548
|
+
* when storage is unavailable.
|
|
9549
|
+
*/
|
|
9550
|
+
const STORAGE_KEY$1 = "dsh.agent-team.sidebar-sections";
|
|
9551
|
+
function sectionKey(workspaceId, kind) {
|
|
9552
|
+
return workspaceId === void 0 ? kind === "workspaces" ? kind : void 0 : `${workspaceId}|${kind}`;
|
|
9553
|
+
}
|
|
9554
|
+
const MEMORY_ONLY$1 = Symbol("sidebar-sections.memory");
|
|
9555
|
+
/** Read-through parse cache over the raw persisted payload; see `sidebar-order.ts`. */
|
|
9556
|
+
let cachedRaw$1;
|
|
9557
|
+
let cachedCollapsed = /* @__PURE__ */ new Set();
|
|
9558
|
+
function storedCollapsed() {
|
|
9559
|
+
let raw = null;
|
|
9560
|
+
try {
|
|
9561
|
+
raw = typeof localStorage === "undefined" ? null : localStorage.getItem(STORAGE_KEY$1);
|
|
9562
|
+
} catch {
|
|
9563
|
+
raw = null;
|
|
9564
|
+
}
|
|
9565
|
+
if (cachedRaw$1 !== void 0 && raw !== null && raw === cachedRaw$1) return cachedCollapsed;
|
|
9566
|
+
if (raw === null) {
|
|
9567
|
+
if (cachedRaw$1 === MEMORY_ONLY$1) return cachedCollapsed;
|
|
9568
|
+
cachedRaw$1 = raw;
|
|
9569
|
+
cachedCollapsed = /* @__PURE__ */ new Set();
|
|
9570
|
+
return cachedCollapsed;
|
|
9571
|
+
}
|
|
9572
|
+
try {
|
|
9573
|
+
const parsed = JSON.parse(raw);
|
|
9574
|
+
if (parsed === null || typeof parsed !== "object" || Array.isArray(parsed)) throw new Error("not an object");
|
|
9575
|
+
const keys = parsed.collapsed;
|
|
9576
|
+
if (!Array.isArray(keys) || !keys.every((key) => typeof key === "string")) throw new Error("bad shape");
|
|
9577
|
+
cachedRaw$1 = raw;
|
|
9578
|
+
cachedCollapsed = new Set(keys);
|
|
9579
|
+
return cachedCollapsed;
|
|
9580
|
+
} catch {
|
|
9581
|
+
return /* @__PURE__ */ new Set();
|
|
9582
|
+
}
|
|
9583
|
+
}
|
|
9584
|
+
function writeCollapsed(collapsed) {
|
|
9585
|
+
cachedCollapsed = collapsed;
|
|
9586
|
+
try {
|
|
9587
|
+
if (typeof localStorage === "undefined") throw new Error("no localStorage");
|
|
9588
|
+
const raw = JSON.stringify({ collapsed: [...collapsed] });
|
|
9589
|
+
localStorage.setItem(STORAGE_KEY$1, raw);
|
|
9590
|
+
cachedRaw$1 = raw;
|
|
9591
|
+
return;
|
|
9592
|
+
} catch {
|
|
9593
|
+
cachedRaw$1 = MEMORY_ONLY$1;
|
|
9594
|
+
}
|
|
9595
|
+
}
|
|
9596
|
+
const listeners$1 = /* @__PURE__ */ new Set();
|
|
9597
|
+
/**
|
|
9598
|
+
* Effective expanded state for one sidebar section: `false` only when this
|
|
9599
|
+
* browser explicitly collapsed it. Booleans are primitives, so the snapshot
|
|
9600
|
+
* is naturally identity-stable for `useSyncExternalStore`.
|
|
9601
|
+
*/
|
|
9602
|
+
function useSidebarSectionOpen(workspaceId, kind) {
|
|
9603
|
+
const key = sectionKey(workspaceId, kind);
|
|
9604
|
+
return (0, react.useSyncExternalStore)((0, react.useCallback)((listener) => {
|
|
9605
|
+
listeners$1.add(listener);
|
|
9606
|
+
return () => {
|
|
9607
|
+
listeners$1.delete(listener);
|
|
9608
|
+
};
|
|
9609
|
+
}, []), () => key === void 0 ? true : !storedCollapsed().has(key), () => key === void 0 ? true : !storedCollapsed().has(key));
|
|
9610
|
+
}
|
|
9611
|
+
/**
|
|
9612
|
+
* The only mutation path: record one section's expanded state for this
|
|
9613
|
+
* browser. Unknown keys (missing workspace) no-op so an unloaded workspace
|
|
9614
|
+
* never persists a phantom preference.
|
|
9615
|
+
*/
|
|
9616
|
+
function setSidebarSectionOpen(workspaceId, kind, open) {
|
|
9617
|
+
const key = sectionKey(workspaceId, kind);
|
|
9618
|
+
if (key === void 0) return;
|
|
9619
|
+
const next = new Set(storedCollapsed());
|
|
9620
|
+
if (open) next.delete(key);
|
|
9621
|
+
else next.add(key);
|
|
9622
|
+
writeCollapsed(next);
|
|
9623
|
+
for (const listener of listeners$1) listener();
|
|
9624
|
+
}
|
|
9625
|
+
//#endregion
|
|
9055
9626
|
//#region src/client/TeamMemberAvatar.tsx
|
|
9056
9627
|
/**
|
|
9057
9628
|
* Sidebar Member avatar reusing the conversation identity language: the
|
|
@@ -9355,33 +9926,6 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
9355
9926
|
});
|
|
9356
9927
|
}
|
|
9357
9928
|
//#endregion
|
|
9358
|
-
//#region src/client/TeamSidebarSection.tsx
|
|
9359
|
-
/** Collapsible sidebar section header: disclosure toggle plus trailing actions. */
|
|
9360
|
-
function TeamSidebarSection({ title, actions, children }) {
|
|
9361
|
-
const [open, setOpen] = (0, react.useState)(true);
|
|
9362
|
-
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("section", {
|
|
9363
|
-
className: sidebar_module_css_default.section,
|
|
9364
|
-
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
|
|
9365
|
-
className: sidebar_module_css_default.sectionHeader,
|
|
9366
|
-
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("button", {
|
|
9367
|
-
type: "button",
|
|
9368
|
-
className: sidebar_module_css_default.sectionToggle,
|
|
9369
|
-
"aria-expanded": open,
|
|
9370
|
-
onClick: () => {
|
|
9371
|
-
setOpen((value) => !value);
|
|
9372
|
-
},
|
|
9373
|
-
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.IconChevronDownOutline14, { className: sidebar_module_css_default.sectionChevron }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
|
|
9374
|
-
className: sidebar_module_css_default.sectionTitle,
|
|
9375
|
-
children: title
|
|
9376
|
-
})]
|
|
9377
|
-
}), actions !== void 0 && /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
|
|
9378
|
-
className: sidebar_module_css_default.sectionActions,
|
|
9379
|
-
children: actions
|
|
9380
|
-
})]
|
|
9381
|
-
}), open && children]
|
|
9382
|
-
});
|
|
9383
|
-
}
|
|
9384
|
-
//#endregion
|
|
9385
9929
|
//#region \0dsh-css:/home/yu/projects/dsh-agent-team/packages/client-agent-team/src/client/create.module.css.mjs
|
|
9386
9930
|
const css = "._1henIG_form{gap:16px;display:grid}._1henIG_field{color:var(--dsw-alias-label-secondary);gap:6px;font-size:12px;line-height:18px;display:grid}._1henIG_input{box-sizing:border-box;width:100%}._1henIG_menuCap{max-height:min(320px,56vh)}._1henIG_selectTrigger{background:var(--dsw-alias-bg-layer-1);border:1px solid var(--dsw-alias-border-l2);box-sizing:border-box;color:var(--dsw-alias-label-primary);cursor:pointer;text-align:left;border-radius:8px;justify-content:space-between;align-items:center;gap:8px;min-height:32px;padding:4px 10px;font-size:14px;line-height:22px;display:flex}._1henIG_selectTrigger:disabled{cursor:default;opacity:.6}._1henIG_selectTrigger:focus-visible{border-color:var(--dsw-alias-brand-primary);outline:none}._1henIG_selectValue{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}._1henIG_chevron{color:var(--dsw-alias-label-tertiary);flex:none;transition:transform .12s;display:inline-flex}._1henIG_chevronOpen{transform:rotate(180deg)}._1henIG_memberPicker{border:0;gap:4px;max-height:220px;margin:0;padding:0;display:grid;overflow-y:auto}._1henIG_memberPicker legend{color:var(--dsw-alias-label-secondary);padding:0 0 6px;font-size:12px;line-height:18px}._1henIG_memberOption{color:var(--dsw-alias-label-primary);border-radius:6px;grid-template-columns:auto 14px minmax(0,1fr);align-items:center;gap:0 7px;min-height:32px;padding:3px 6px;display:grid}._1henIG_memberOption:hover{background:var(--dsw-alias-interactive-bg-hover)}._1henIG_memberOption input{margin:0}._1henIG_memberOption small{color:var(--dsw-alias-label-tertiary);grid-column:3;font-size:10px;line-height:14px}._1henIG_unavailableDot{background:var(--dsw-alias-label-tertiary);border-radius:50%;justify-self:center;width:7px;height:7px;display:inline-block}._1henIG_error{color:var(--dsw-alias-state-error-primary);margin:0;font-size:12px;line-height:18px}._1henIG_dialogContent{max-height:min(70vh,560px);overflow-y:auto}@media (width<=600px){._1henIG_dialogContent{max-height:calc(100vh - 180px)}._1henIG_memberPicker{max-height:180px}}";
|
|
9387
9931
|
const tagId = "@wowyuarm/dsh-agent-team/create.module.css";
|
|
@@ -9832,7 +10376,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
9832
10376
|
}
|
|
9833
10377
|
//#endregion
|
|
9834
10378
|
//#region src/client/TeamAgentsPanel.tsx
|
|
9835
|
-
function TeamAgentsPanel({ workspaceId, loadMembers, subscribeChanges, loadChannels, addMember, updateMember, recoverMember, joinChannel, removeChannelMember, loadModels, memberSessionId, openMemberSession, onCreatingChange, t }) {
|
|
10379
|
+
function TeamAgentsPanel({ workspaceId, loadMembers, subscribeChanges, loadChannels, addMember, updateMember, recoverMember, clearMemberContext, joinChannel, removeChannelMember, loadModels, memberSessionId, openMemberSession, onCreatingChange, t }) {
|
|
9836
10380
|
const [members, setMembers] = (0, react.useState)([]);
|
|
9837
10381
|
const [channels, setChannels] = (0, react.useState)([]);
|
|
9838
10382
|
const [channelRefs, setChannelRefs] = (0, react.useState)([]);
|
|
@@ -9857,6 +10401,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
9857
10401
|
refs: orderedAgentRefs,
|
|
9858
10402
|
onCommit: applyMove
|
|
9859
10403
|
});
|
|
10404
|
+
const sectionOpen = useSidebarSectionOpen(workspaceId, "agents");
|
|
9860
10405
|
const refresh = (0, react.useCallback)(async () => {
|
|
9861
10406
|
setLoading(true);
|
|
9862
10407
|
const result = await loadMembers({ workspaceId });
|
|
@@ -10039,6 +10584,10 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
10039
10584
|
}),
|
|
10040
10585
|
/* @__PURE__ */ (0, react_jsx_runtime.jsxs)(TeamSidebarSection, {
|
|
10041
10586
|
title: t("agents"),
|
|
10587
|
+
open: sectionOpen,
|
|
10588
|
+
onToggle: (open) => {
|
|
10589
|
+
setSidebarSectionOpen(workspaceId, "agents", open);
|
|
10590
|
+
},
|
|
10042
10591
|
actions: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Tooltip, {
|
|
10043
10592
|
label: t("addAgent"),
|
|
10044
10593
|
delayMs: 500,
|
|
@@ -10075,6 +10624,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
10075
10624
|
loadChannels,
|
|
10076
10625
|
updateMember,
|
|
10077
10626
|
recoverMember,
|
|
10627
|
+
clearMemberContext,
|
|
10078
10628
|
joinChannel,
|
|
10079
10629
|
removeChannelMember,
|
|
10080
10630
|
loadModels,
|
|
@@ -10109,70 +10659,161 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
10109
10659
|
* conversation page, the avatar carries identity plus the presence badge, and
|
|
10110
10660
|
* the row menu opens the editor.
|
|
10111
10661
|
*/
|
|
10112
|
-
function AgentRow({ status, current, channels, loadChannels, updateMember, recoverMember, joinChannel, removeChannelMember, loadModels, openMemberSession, onUpdated, t }) {
|
|
10662
|
+
function AgentRow({ status, current, channels, loadChannels, updateMember, recoverMember, clearMemberContext, joinChannel, removeChannelMember, loadModels, openMemberSession, onUpdated, t }) {
|
|
10113
10663
|
const [menuOpen, setMenuOpen] = (0, react.useState)(false);
|
|
10114
10664
|
const [editing, setEditing] = (0, react.useState)(false);
|
|
10115
|
-
const
|
|
10116
|
-
|
|
10117
|
-
|
|
10118
|
-
|
|
10119
|
-
|
|
10120
|
-
|
|
10121
|
-
|
|
10665
|
+
const [clearing, setClearing] = (0, react.useState)(false);
|
|
10666
|
+
const [rowAlert, setRowAlert] = (0, react.useState)();
|
|
10667
|
+
const recover = async () => {
|
|
10668
|
+
try {
|
|
10669
|
+
const result = await recoverMember({
|
|
10670
|
+
requestId: mintRequestId(),
|
|
10671
|
+
workspaceId: status.member.workspaceId,
|
|
10672
|
+
memberId: status.member.memberId
|
|
10673
|
+
});
|
|
10674
|
+
await onUpdated();
|
|
10675
|
+
if (!result.ok) {
|
|
10676
|
+
setRowAlert(t("restartFailed", { message: result.error.message }));
|
|
10677
|
+
return;
|
|
10678
|
+
}
|
|
10679
|
+
if (result.value.status.availability === "unavailable") {
|
|
10680
|
+
setRowAlert(t("restartStillUnavailable", { diagnostic: result.value.status.diagnostic ?? t("statusUnavailable") }));
|
|
10681
|
+
return;
|
|
10682
|
+
}
|
|
10683
|
+
setRowAlert(void 0);
|
|
10684
|
+
if (current === true) openMemberSession(status.member.sessionId);
|
|
10685
|
+
} catch (cause) {
|
|
10686
|
+
setRowAlert(t("restartFailed", { message: cause instanceof Error ? cause.message : String(cause) }));
|
|
10687
|
+
}
|
|
10122
10688
|
};
|
|
10123
|
-
|
|
10124
|
-
|
|
10125
|
-
|
|
10126
|
-
|
|
10127
|
-
|
|
10128
|
-
|
|
10129
|
-
|
|
10130
|
-
|
|
10131
|
-
|
|
10132
|
-
|
|
10133
|
-
|
|
10134
|
-
}
|
|
10135
|
-
|
|
10136
|
-
|
|
10137
|
-
|
|
10138
|
-
|
|
10139
|
-
|
|
10140
|
-
|
|
10689
|
+
const clearContext = async () => {
|
|
10690
|
+
try {
|
|
10691
|
+
const result = await clearMemberContext({
|
|
10692
|
+
requestId: mintRequestId(),
|
|
10693
|
+
workspaceId: status.member.workspaceId,
|
|
10694
|
+
memberId: status.member.memberId
|
|
10695
|
+
});
|
|
10696
|
+
await onUpdated();
|
|
10697
|
+
if (!result.ok) {
|
|
10698
|
+
setRowAlert(t("clearContextFailed", { message: result.error.message }));
|
|
10699
|
+
return;
|
|
10700
|
+
}
|
|
10701
|
+
setRowAlert(void 0);
|
|
10702
|
+
if (current === true) openMemberSession(result.value.status.member.sessionId);
|
|
10703
|
+
} catch (cause) {
|
|
10704
|
+
setRowAlert(t("clearContextFailed", { message: cause instanceof Error ? cause.message : String(cause) }));
|
|
10705
|
+
}
|
|
10706
|
+
};
|
|
10707
|
+
const contextClearable = status.presence === "available" || status.presence === "error";
|
|
10708
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [
|
|
10709
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
|
|
10710
|
+
className: sidebar_module_css_default.agentRow,
|
|
10711
|
+
"data-menu-open": menuOpen || void 0,
|
|
10712
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("button", {
|
|
10713
|
+
type: "button",
|
|
10714
|
+
className: sidebar_module_css_default.agentSelect,
|
|
10715
|
+
"aria-label": t("openAgentSession", { name: status.member.handle }),
|
|
10716
|
+
"aria-current": current ? "page" : void 0,
|
|
10717
|
+
disabled: status.availability !== "active",
|
|
10718
|
+
onClick: () => {
|
|
10719
|
+
openMemberSession(status.member.sessionId);
|
|
10720
|
+
},
|
|
10721
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TeamMemberAvatar, {
|
|
10722
|
+
status,
|
|
10723
|
+
t
|
|
10724
|
+
}), /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("span", {
|
|
10725
|
+
className: sidebar_module_css_default.agentCopy,
|
|
10726
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("strong", { children: status.member.handle }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("small", { children: status.member.description })]
|
|
10727
|
+
})]
|
|
10728
|
+
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
|
|
10729
|
+
className: sidebar_module_css_default.rowMenu,
|
|
10730
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(TeamRowMenu, {
|
|
10731
|
+
label: t("actionsAgent", { name: status.member.handle }),
|
|
10732
|
+
items: [
|
|
10733
|
+
{
|
|
10734
|
+
id: "edit",
|
|
10735
|
+
label: t("editAgent"),
|
|
10736
|
+
icon: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.IconEditOutline16, {})
|
|
10737
|
+
},
|
|
10738
|
+
...status.presence === "error" ? [{
|
|
10739
|
+
id: "resume",
|
|
10740
|
+
label: t("resumeAgent"),
|
|
10741
|
+
icon: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.IconPlayOutline16, {})
|
|
10742
|
+
}] : [],
|
|
10743
|
+
...status.availability === "unavailable" ? [{
|
|
10744
|
+
id: "restart",
|
|
10745
|
+
label: t("restartAgent"),
|
|
10746
|
+
icon: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.IconRefreshOutline16, {})
|
|
10747
|
+
}] : [],
|
|
10748
|
+
{
|
|
10749
|
+
id: "clear-context",
|
|
10750
|
+
label: t("clearContextAgent"),
|
|
10751
|
+
icon: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.IconNewChatOutline16, {}),
|
|
10752
|
+
danger: true,
|
|
10753
|
+
disabled: !contextClearable
|
|
10754
|
+
},
|
|
10755
|
+
...!contextClearable ? [{
|
|
10756
|
+
type: "label",
|
|
10757
|
+
id: "clear-context-reason",
|
|
10758
|
+
text: status.presence === "working" ? t("clearContextWorkingReason") : t("clearContextUnavailableReason")
|
|
10759
|
+
}] : []
|
|
10760
|
+
],
|
|
10761
|
+
onSelect: (id) => {
|
|
10762
|
+
if (id === "edit") setEditing(true);
|
|
10763
|
+
else if (id === "clear-context") setClearing(true);
|
|
10764
|
+
else recover();
|
|
10765
|
+
},
|
|
10766
|
+
onOpenChange: setMenuOpen
|
|
10767
|
+
})
|
|
10141
10768
|
})]
|
|
10142
|
-
}),
|
|
10143
|
-
|
|
10144
|
-
|
|
10145
|
-
|
|
10146
|
-
|
|
10147
|
-
|
|
10148
|
-
|
|
10149
|
-
|
|
10150
|
-
|
|
10151
|
-
|
|
10152
|
-
|
|
10153
|
-
|
|
10154
|
-
|
|
10155
|
-
|
|
10156
|
-
|
|
10157
|
-
|
|
10769
|
+
}),
|
|
10770
|
+
rowAlert !== void 0 && /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
10771
|
+
className: sidebar_module_css_default.rowAlert,
|
|
10772
|
+
role: "alert",
|
|
10773
|
+
children: rowAlert
|
|
10774
|
+
}),
|
|
10775
|
+
clearing && /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Modal, {
|
|
10776
|
+
open: true,
|
|
10777
|
+
onClose: () => {
|
|
10778
|
+
setClearing(false);
|
|
10779
|
+
},
|
|
10780
|
+
title: t("clearContextTitle", { name: status.member.handle }),
|
|
10781
|
+
closeLabel: t("close"),
|
|
10782
|
+
contentClassName: create_module_css_default.dialogContent,
|
|
10783
|
+
footer: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Button, {
|
|
10784
|
+
variant: "outline",
|
|
10785
|
+
onClick: () => {
|
|
10786
|
+
setClearing(false);
|
|
10158
10787
|
},
|
|
10159
|
-
|
|
10788
|
+
children: t("cancel")
|
|
10789
|
+
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Button, {
|
|
10790
|
+
variant: "primary",
|
|
10791
|
+
onClick: () => {
|
|
10792
|
+
setClearing(false);
|
|
10793
|
+
clearContext();
|
|
10794
|
+
},
|
|
10795
|
+
children: t("clearContextConfirm")
|
|
10796
|
+
})] }),
|
|
10797
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
|
|
10798
|
+
className: create_module_css_default.error,
|
|
10799
|
+
children: t("clearContextNotice", { name: status.member.handle })
|
|
10160
10800
|
})
|
|
10161
|
-
})
|
|
10162
|
-
|
|
10163
|
-
|
|
10164
|
-
|
|
10165
|
-
|
|
10166
|
-
|
|
10167
|
-
|
|
10168
|
-
|
|
10169
|
-
|
|
10170
|
-
|
|
10171
|
-
|
|
10172
|
-
|
|
10173
|
-
|
|
10174
|
-
|
|
10175
|
-
|
|
10801
|
+
}),
|
|
10802
|
+
editing && /* @__PURE__ */ (0, react_jsx_runtime.jsx)(AgentEditorDialog, {
|
|
10803
|
+
status,
|
|
10804
|
+
channels,
|
|
10805
|
+
loadChannels,
|
|
10806
|
+
updateMember,
|
|
10807
|
+
joinChannel,
|
|
10808
|
+
removeChannelMember,
|
|
10809
|
+
loadModels,
|
|
10810
|
+
onCommitted: onUpdated,
|
|
10811
|
+
onClose: () => {
|
|
10812
|
+
setEditing(false);
|
|
10813
|
+
},
|
|
10814
|
+
t
|
|
10815
|
+
})
|
|
10816
|
+
] });
|
|
10176
10817
|
}
|
|
10177
10818
|
//#endregion
|
|
10178
10819
|
//#region src/client/TeamChannelsPanel.tsx
|
|
@@ -10202,6 +10843,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
10202
10843
|
refs: orderedChannelRefs,
|
|
10203
10844
|
onCommit: applyMove
|
|
10204
10845
|
});
|
|
10846
|
+
const sectionOpen = useSidebarSectionOpen(workspaceId, "channels");
|
|
10205
10847
|
const refresh = (0, react.useCallback)(async () => {
|
|
10206
10848
|
setLoading(true);
|
|
10207
10849
|
const [channelResult, memberResult] = await Promise.all([loadChannels({
|
|
@@ -10394,6 +11036,10 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
10394
11036
|
}),
|
|
10395
11037
|
/* @__PURE__ */ (0, react_jsx_runtime.jsxs)(TeamSidebarSection, {
|
|
10396
11038
|
title: t("channels"),
|
|
11039
|
+
open: sectionOpen,
|
|
11040
|
+
onToggle: (open) => {
|
|
11041
|
+
setSidebarSectionOpen(workspaceId, "channels", open);
|
|
11042
|
+
},
|
|
10397
11043
|
actions: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Tooltip, {
|
|
10398
11044
|
label: t("addChannel"),
|
|
10399
11045
|
delayMs: 500,
|
|
@@ -10653,7 +11299,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
10653
11299
|
}
|
|
10654
11300
|
//#endregion
|
|
10655
11301
|
//#region src/client/TeamWorkspaceBrowser.tsx
|
|
10656
|
-
function TeamWorkspaceBrowser({ wide, expandSidebar, navigation, selectWorkspace, selectChannel, t, useWorkspaces, loadMembers, subscribeChanges, addMember, loadChannels, createChannel, updateChannel, updateMember, recoverMember, joinChannel, removeChannelMember, loadModels, openMemberSession }) {
|
|
11302
|
+
function TeamWorkspaceBrowser({ wide, expandSidebar, navigation, selectWorkspace, selectChannel, t, useWorkspaces, loadMembers, subscribeChanges, addMember, loadChannels, createChannel, updateChannel, updateMember, recoverMember, clearMemberContext, joinChannel, removeChannelMember, loadModels, openMemberSession }) {
|
|
10657
11303
|
const navigationState = (0, react.useSyncExternalStore)(navigation.subscribe, navigation.getSnapshot, navigation.getSnapshot);
|
|
10658
11304
|
const workspaces = useWorkspaces((state) => state.items);
|
|
10659
11305
|
const selected = navigationState.workspaceId;
|
|
@@ -10663,6 +11309,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
10663
11309
|
const [pendingSection, setPendingSection] = (0, react.useState)();
|
|
10664
11310
|
const channelsRef = (0, react.useRef)(null);
|
|
10665
11311
|
const agentsRef = (0, react.useRef)(null);
|
|
11312
|
+
const workspacesOpen = useSidebarSectionOpen(void 0, "workspaces");
|
|
10666
11313
|
(0, react.useEffect)(() => {
|
|
10667
11314
|
if (navigationState.mode === "team" && selectedId !== void 0 && selectedId !== selected) selectWorkspace(selectedId);
|
|
10668
11315
|
}, [
|
|
@@ -10713,12 +11360,13 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
10713
11360
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("section", {
|
|
10714
11361
|
className: sidebar_module_css_default.workspaceBrowser,
|
|
10715
11362
|
"aria-label": t("workspaces"),
|
|
10716
|
-
children: [
|
|
10717
|
-
|
|
10718
|
-
|
|
10719
|
-
|
|
10720
|
-
|
|
10721
|
-
|
|
11363
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(TeamSidebarSection, {
|
|
11364
|
+
title: t("workspaces"),
|
|
11365
|
+
open: workspacesOpen,
|
|
11366
|
+
onToggle: (open) => {
|
|
11367
|
+
setSidebarSectionOpen(void 0, "workspaces", open);
|
|
11368
|
+
},
|
|
11369
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
|
|
10722
11370
|
className: sidebar_module_css_default.workspaceList,
|
|
10723
11371
|
children: [workspaces.map((workspace) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)(TeamWorkspaceRow, {
|
|
10724
11372
|
workspaceId: workspace.workspaceId,
|
|
@@ -10731,48 +11379,48 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
10731
11379
|
className: sidebar_module_css_default.emptyState,
|
|
10732
11380
|
children: t("empty")
|
|
10733
11381
|
})]
|
|
10734
|
-
}),
|
|
10735
|
-
selectedId !== void 0 && /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
|
|
10736
|
-
className: sidebar_module_css_default.workspaceSection,
|
|
10737
|
-
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
10738
|
-
ref: channelsRef,
|
|
10739
|
-
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(TeamChannelsPanel, {
|
|
10740
|
-
workspaceId: selectedId,
|
|
10741
|
-
loadMembers,
|
|
10742
|
-
loadChannels,
|
|
10743
|
-
subscribeChanges,
|
|
10744
|
-
createChannel,
|
|
10745
|
-
updateChannel,
|
|
10746
|
-
joinChannel,
|
|
10747
|
-
removeChannelMember,
|
|
10748
|
-
creatingAgents: creatingAgents.filter((request) => request.workspaceId === selectedId),
|
|
10749
|
-
...navigationState.memberSessionId !== void 0 || navigationState.channelRef === void 0 ? {} : { selectedChannelRef: navigationState.channelRef },
|
|
10750
|
-
selectChannel,
|
|
10751
|
-
t
|
|
10752
|
-
}, selectedId)
|
|
10753
|
-
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
10754
|
-
ref: agentsRef,
|
|
10755
|
-
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(TeamAgentsPanel, {
|
|
10756
|
-
workspaceId: selectedId,
|
|
10757
|
-
loadMembers,
|
|
10758
|
-
subscribeChanges,
|
|
10759
|
-
loadChannels,
|
|
10760
|
-
addMember,
|
|
10761
|
-
updateMember,
|
|
10762
|
-
recoverMember,
|
|
10763
|
-
joinChannel,
|
|
10764
|
-
removeChannelMember,
|
|
10765
|
-
loadModels,
|
|
10766
|
-
...navigationState.memberSessionId === void 0 ? {} : { memberSessionId: navigationState.memberSessionId },
|
|
10767
|
-
openMemberSession,
|
|
10768
|
-
onCreatingChange: (request, creating) => {
|
|
10769
|
-
setCreatingAgents((current) => creating ? [...current.filter((item) => item.requestId !== request.requestId), request] : current.filter((item) => item.requestId !== request.requestId));
|
|
10770
|
-
},
|
|
10771
|
-
t
|
|
10772
|
-
}, selectedId)
|
|
10773
|
-
})]
|
|
10774
11382
|
})
|
|
10775
|
-
|
|
11383
|
+
}), selectedId !== void 0 && /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
|
|
11384
|
+
className: sidebar_module_css_default.workspaceSection,
|
|
11385
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
11386
|
+
ref: channelsRef,
|
|
11387
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(TeamChannelsPanel, {
|
|
11388
|
+
workspaceId: selectedId,
|
|
11389
|
+
loadMembers,
|
|
11390
|
+
loadChannels,
|
|
11391
|
+
subscribeChanges,
|
|
11392
|
+
createChannel,
|
|
11393
|
+
updateChannel,
|
|
11394
|
+
joinChannel,
|
|
11395
|
+
removeChannelMember,
|
|
11396
|
+
creatingAgents: creatingAgents.filter((request) => request.workspaceId === selectedId),
|
|
11397
|
+
...navigationState.memberSessionId !== void 0 || navigationState.channelRef === void 0 ? {} : { selectedChannelRef: navigationState.channelRef },
|
|
11398
|
+
selectChannel,
|
|
11399
|
+
t
|
|
11400
|
+
}, selectedId)
|
|
11401
|
+
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
11402
|
+
ref: agentsRef,
|
|
11403
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(TeamAgentsPanel, {
|
|
11404
|
+
workspaceId: selectedId,
|
|
11405
|
+
loadMembers,
|
|
11406
|
+
subscribeChanges,
|
|
11407
|
+
loadChannels,
|
|
11408
|
+
addMember,
|
|
11409
|
+
updateMember,
|
|
11410
|
+
recoverMember,
|
|
11411
|
+
clearMemberContext,
|
|
11412
|
+
joinChannel,
|
|
11413
|
+
removeChannelMember,
|
|
11414
|
+
loadModels,
|
|
11415
|
+
...navigationState.memberSessionId === void 0 ? {} : { memberSessionId: navigationState.memberSessionId },
|
|
11416
|
+
openMemberSession,
|
|
11417
|
+
onCreatingChange: (request, creating) => {
|
|
11418
|
+
setCreatingAgents((current) => creating ? [...current.filter((item) => item.requestId !== request.requestId), request] : current.filter((item) => item.requestId !== request.requestId));
|
|
11419
|
+
},
|
|
11420
|
+
t
|
|
11421
|
+
}, selectedId)
|
|
11422
|
+
})]
|
|
11423
|
+
})]
|
|
10776
11424
|
});
|
|
10777
11425
|
}
|
|
10778
11426
|
//#endregion
|
|
@@ -10905,7 +11553,10 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
10905
11553
|
setSubmissionNotice("Compact 未执行,请重试。");
|
|
10906
11554
|
return;
|
|
10907
11555
|
}
|
|
10908
|
-
if (input.phase === "plain")
|
|
11556
|
+
if (input.phase === "plain") {
|
|
11557
|
+
if (compactWasSubmitting.current) setSubmissionNotice(void 0);
|
|
11558
|
+
compactWasSubmitting.current = false;
|
|
11559
|
+
}
|
|
10909
11560
|
}, [input?.claim?.token, input?.phase]);
|
|
10910
11561
|
(0, react.useEffect)(() => {
|
|
10911
11562
|
if (input === void 0) return;
|
|
@@ -10941,6 +11592,14 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
10941
11592
|
const onKeyDown = (event) => {
|
|
10942
11593
|
if (event.key === "Enter" && event.shiftKey) return;
|
|
10943
11594
|
if (event.repeat || composing.current || event.nativeEvent.isComposing || event.nativeEvent.keyCode === 229) return;
|
|
11595
|
+
if (event.key === "Tab" && !event.shiftKey) {
|
|
11596
|
+
const highlight = controller.menu.getSnapshot().highlight;
|
|
11597
|
+
if (highlight !== null) {
|
|
11598
|
+
event.preventDefault();
|
|
11599
|
+
controller.pick(highlight.source, highlight.index);
|
|
11600
|
+
}
|
|
11601
|
+
return;
|
|
11602
|
+
}
|
|
10944
11603
|
const key = event.key === "ArrowUp" ? "up" : event.key === "ArrowDown" ? "down" : event.key === "Escape" ? "escape" : event.key === "Enter" ? "enter" : void 0;
|
|
10945
11604
|
if (key !== void 0) {
|
|
10946
11605
|
if (controller.arbitrate(key, false) !== "pass") {
|
|
@@ -11070,6 +11729,16 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
11070
11729
|
editChannel: "编辑频道",
|
|
11071
11730
|
editAgent: "编辑 Agent",
|
|
11072
11731
|
resumeAgent: "恢复",
|
|
11732
|
+
restartAgent: "重启",
|
|
11733
|
+
restartStillUnavailable: "重启已执行,成员仍不可用:{diagnostic}",
|
|
11734
|
+
restartFailed: "重启执行失败:{message}",
|
|
11735
|
+
clearContextAgent: "从全新上下文开始",
|
|
11736
|
+
clearContextWorkingReason: "成员正在工作中,完成后才能清空上下文",
|
|
11737
|
+
clearContextUnavailableReason: "成员当前不可用,恢复在线且空闲后才能清空上下文",
|
|
11738
|
+
clearContextTitle: "从全新上下文开始:{name}",
|
|
11739
|
+
clearContextNotice: "将结束 {name} 当前的会话上下文并从空白开始:旧对话会归档保留在会话记录中。{name} 的身份、私有记忆与 notes、频道和会话绑定都保持不变,后续协作从新上下文继续累积。",
|
|
11740
|
+
clearContextConfirm: "开始全新上下文",
|
|
11741
|
+
clearContextFailed: "清空上下文失败:{message}",
|
|
11073
11742
|
optionalSuffix: "(可选)",
|
|
11074
11743
|
agentDescriptionPlaceholder: "留空则暂无描述",
|
|
11075
11744
|
channelsPickerEmpty: "选择初始频道",
|
|
@@ -11082,6 +11751,8 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
11082
11751
|
removeFile: "移除 {name}",
|
|
11083
11752
|
attachmentExpired: "文件已过期清理",
|
|
11084
11753
|
viewImage: "查看大图 {name}",
|
|
11754
|
+
expandMessage: "展开全文",
|
|
11755
|
+
collapseMessage: "收起",
|
|
11085
11756
|
actionsChannel: "{name} 的操作",
|
|
11086
11757
|
actionsAgent: "{name} 的操作",
|
|
11087
11758
|
editSave: "保存",
|
|
@@ -11114,10 +11785,17 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
11114
11785
|
taskLabel: "Task #{number}",
|
|
11115
11786
|
taskPending: "Task …",
|
|
11116
11787
|
openTask: "打开 Task #{number}",
|
|
11788
|
+
openThread: "打开讨论",
|
|
11789
|
+
threadLabel: "讨论",
|
|
11790
|
+
asTask: "作为任务",
|
|
11791
|
+
promoteToTask: "转为 Task",
|
|
11792
|
+
promotingTask: "正在转为 Task…",
|
|
11117
11793
|
mentionSuggestions: "提及成员建议",
|
|
11794
|
+
mentionAll: "通知所有成员({count})",
|
|
11118
11795
|
messageDraft: "消息内容",
|
|
11119
11796
|
composerNotify: "将通知:{ids}",
|
|
11120
11797
|
messagePlaceholder: "写一条消息…",
|
|
11798
|
+
replyPlaceholder: "回复此 Thread…",
|
|
11121
11799
|
sendMessage: "发送",
|
|
11122
11800
|
sendingMessage: "发送中…",
|
|
11123
11801
|
loadOlder: "加载更早消息",
|
|
@@ -11148,6 +11826,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
11148
11826
|
activityClaimsReleased: "{actor} 因成员权限变化释放了 {count} 个 Claim",
|
|
11149
11827
|
activityAccepted: "{actor} 验收了此 Task",
|
|
11150
11828
|
activityAcceptedWithClaims: "{actor} 验收了此 Task,并一并完成了 {count} 个未完成 Claim",
|
|
11829
|
+
activityPromoted: "{actor} 为此讨论创建了 Task",
|
|
11151
11830
|
acceptEarlyTitle: "提前验收任务",
|
|
11152
11831
|
acceptEarlyBody: "将验收本 Task,并把以下 {count} 个未完成的 Claim 一并标记为完成:",
|
|
11153
11832
|
acceptingTask: "验收中…",
|
|
@@ -11198,6 +11877,16 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
11198
11877
|
editChannel: "Edit Channel",
|
|
11199
11878
|
editAgent: "Edit Agent",
|
|
11200
11879
|
resumeAgent: "Resume",
|
|
11880
|
+
restartAgent: "Restart",
|
|
11881
|
+
restartStillUnavailable: "Restart ran, but the Member is still unavailable: {diagnostic}",
|
|
11882
|
+
restartFailed: "Restart failed: {message}",
|
|
11883
|
+
clearContextAgent: "Start from new context",
|
|
11884
|
+
clearContextWorkingReason: "The Member is working; clear once the current turn ends",
|
|
11885
|
+
clearContextUnavailableReason: "The Member is unavailable; only an idle available Member can start from a new context",
|
|
11886
|
+
clearContextTitle: "Start from new context: {name}",
|
|
11887
|
+
clearContextNotice: "This ends {name}'s current session context and starts blank: the previous conversation is archived and stays in the session history. {name}'s identity, private memory and notes, channel and session bindings are untouched, and future collaboration accumulates from the new context.",
|
|
11888
|
+
clearContextConfirm: "Start from new context",
|
|
11889
|
+
clearContextFailed: "Failed to clear context: {message}",
|
|
11201
11890
|
optionalSuffix: " (optional)",
|
|
11202
11891
|
agentDescriptionPlaceholder: "Leave empty if not needed",
|
|
11203
11892
|
channelsPickerEmpty: "Choose initial channels",
|
|
@@ -11210,6 +11899,8 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
11210
11899
|
removeFile: "Remove {name}",
|
|
11211
11900
|
attachmentExpired: "File expired and cleaned up",
|
|
11212
11901
|
viewImage: "View image {name}",
|
|
11902
|
+
expandMessage: "Show more",
|
|
11903
|
+
collapseMessage: "Show less",
|
|
11213
11904
|
actionsChannel: "{name} actions",
|
|
11214
11905
|
actionsAgent: "{name} actions",
|
|
11215
11906
|
editSave: "Save",
|
|
@@ -11242,10 +11933,17 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
11242
11933
|
taskLabel: "Task #{number}",
|
|
11243
11934
|
taskPending: "Task …",
|
|
11244
11935
|
openTask: "Open Task #{number}",
|
|
11936
|
+
openThread: "Open thread",
|
|
11937
|
+
threadLabel: "Thread",
|
|
11938
|
+
asTask: "As task",
|
|
11939
|
+
promoteToTask: "Convert to Task",
|
|
11940
|
+
promotingTask: "Converting to Task…",
|
|
11245
11941
|
mentionSuggestions: "Mention suggestions",
|
|
11942
|
+
mentionAll: "Notify all members ({count})",
|
|
11246
11943
|
messageDraft: "Message",
|
|
11247
11944
|
composerNotify: "Will notify: {ids}",
|
|
11248
11945
|
messagePlaceholder: "Write a message…",
|
|
11946
|
+
replyPlaceholder: "Reply on this Thread…",
|
|
11249
11947
|
sendMessage: "Send",
|
|
11250
11948
|
sendingMessage: "Sending…",
|
|
11251
11949
|
loadOlder: "Load older messages",
|
|
@@ -11276,6 +11974,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
11276
11974
|
activityClaimsReleased: "{actor} released {count} Claim(s) after a membership change",
|
|
11277
11975
|
activityAccepted: "{actor} accepted this Task",
|
|
11278
11976
|
activityAcceptedWithClaims: "{actor} accepted this Task and completed {count} unfinished Claims with it",
|
|
11977
|
+
activityPromoted: "{actor} created a Task for this Thread",
|
|
11279
11978
|
acceptEarlyTitle: "Accept Task early",
|
|
11280
11979
|
acceptEarlyBody: "This accepts the Task and marks the following {count} unfinished Claims as done:",
|
|
11281
11980
|
acceptingTask: "Accepting…",
|
|
@@ -11301,6 +12000,14 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
11301
12000
|
"inputTriggers"
|
|
11302
12001
|
];
|
|
11303
12002
|
function registerModeShadow(ctx, navigation, changes, drafts, name, component, extraInject) {
|
|
12003
|
+
const openMemberSessionImpl = (sessionId) => {
|
|
12004
|
+
const sessions = ctx.sessions;
|
|
12005
|
+
const snapshot = navigation.getSnapshot();
|
|
12006
|
+
const current = sessions.list.getSnapshot().current;
|
|
12007
|
+
const returnTo = snapshot.memberSessionId === void 0 && current !== void 0 && current !== sessionId ? current : void 0;
|
|
12008
|
+
navigation.actions().enterMemberSession(sessionId, returnTo);
|
|
12009
|
+
sessions.open(sessionId);
|
|
12010
|
+
};
|
|
11304
12011
|
const sharedRemotes = {
|
|
11305
12012
|
loadChannels: (request) => ctx.remote.agentTeam.view(request),
|
|
11306
12013
|
subscribeChanges: (scope, listener) => changes.subscribe(scope, listener),
|
|
@@ -11311,17 +12018,11 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
11311
12018
|
updateChannel: (request) => ctx.remote.agentTeam.updateChannel(request),
|
|
11312
12019
|
updateMember: (request) => ctx.remote.agentTeam.updateMember(request),
|
|
11313
12020
|
recoverMember: (request) => ctx.remote.agentTeam.recoverMember(request),
|
|
12021
|
+
clearMemberContext: (request) => ctx.remote.agentTeam.clearMemberContext(request),
|
|
11314
12022
|
loadModels: async () => {
|
|
11315
12023
|
return (await ctx.get("connection").api.llm.models({})).result;
|
|
11316
12024
|
},
|
|
11317
|
-
openMemberSession:
|
|
11318
|
-
const sessions = ctx.sessions;
|
|
11319
|
-
const snapshot = navigation.getSnapshot();
|
|
11320
|
-
const current = sessions.list.getSnapshot().current;
|
|
11321
|
-
const returnTo = snapshot.memberSessionId === void 0 && current !== void 0 && current !== sessionId ? current : void 0;
|
|
11322
|
-
navigation.actions().enterMemberSession(sessionId, returnTo);
|
|
11323
|
-
sessions.open(sessionId);
|
|
11324
|
-
}
|
|
12025
|
+
openMemberSession: openMemberSessionImpl
|
|
11325
12026
|
};
|
|
11326
12027
|
ctx.slots.inject(name, () => {
|
|
11327
12028
|
let dispose;
|
|
@@ -11345,6 +12046,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
11345
12046
|
getAttachment: (request) => ctx.remote.agentTeam.getAttachment(request),
|
|
11346
12047
|
reply: (request) => ctx.remote.agentTeam.reply(request),
|
|
11347
12048
|
changeTask: (request) => ctx.remote.agentTeam.changeTask(request),
|
|
12049
|
+
promoteThread: (request) => ctx.remote.agentTeam.promoteThread(request),
|
|
11348
12050
|
resolveTaskRefs: (request) => ctx.remote.agentTeam.resolveTaskRefs(request)
|
|
11349
12051
|
} : {},
|
|
11350
12052
|
...name === "sidebar.workspaces" ? {
|