im-agent 0.1.0 → 0.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/package.json +1 -1
- package/src/agents/claude/account.ts +100 -0
- package/src/agents/claude/driver.ts +47 -2
- package/src/agents/claude/permissions.ts +35 -2
- package/src/agents/claude/probe.ts +54 -0
- package/src/agents/claude/session.ts +19 -9
- package/src/agents/codex/driver.ts +4 -0
- package/src/channels/feishu/bot.ts +60 -0
- package/src/channels/feishu/cards.ts +50 -0
- package/src/channels/feishu/envelope.ts +6 -1
- package/src/channels/feishu/index.ts +11 -1
- package/src/channels/feishu/slash-sync.ts +192 -0
- package/src/channels/web/api.ts +54 -0
- package/src/channels/web/server.ts +12 -0
- package/src/core/command-catalog.ts +112 -0
- package/src/core/commands.ts +21 -16
- package/src/core/config.ts +5 -0
- package/src/core/hub.ts +55 -0
- package/src/core/store.ts +2 -0
- package/src/core/types.ts +9 -0
- package/web/app.js +541 -15
- package/web/style.css +147 -0
package/web/style.css
CHANGED
|
@@ -133,6 +133,13 @@ select {
|
|
|
133
133
|
color: var(--fg-soft);
|
|
134
134
|
}
|
|
135
135
|
|
|
136
|
+
/* 设置页的模型 / 思考程度下拉:读取失败时里面会换成文本框 + 提示 */
|
|
137
|
+
.picker {
|
|
138
|
+
display: flex;
|
|
139
|
+
flex-direction: column;
|
|
140
|
+
gap: 6px;
|
|
141
|
+
}
|
|
142
|
+
|
|
136
143
|
.field small {
|
|
137
144
|
color: var(--fg-faint);
|
|
138
145
|
font-size: 12px;
|
|
@@ -1265,3 +1272,143 @@ button.list-item:hover {
|
|
|
1265
1272
|
white-space: nowrap;
|
|
1266
1273
|
}
|
|
1267
1274
|
}
|
|
1275
|
+
|
|
1276
|
+
/* ---------- 斜杠命令补全 ---------- */
|
|
1277
|
+
|
|
1278
|
+
.composer {
|
|
1279
|
+
position: relative;
|
|
1280
|
+
}
|
|
1281
|
+
|
|
1282
|
+
.slash-menu {
|
|
1283
|
+
position: absolute;
|
|
1284
|
+
left: 0;
|
|
1285
|
+
right: 0;
|
|
1286
|
+
bottom: calc(100% + 8px);
|
|
1287
|
+
max-height: min(360px, 50vh);
|
|
1288
|
+
overflow-y: auto;
|
|
1289
|
+
background: var(--bg-input);
|
|
1290
|
+
border: 1px solid var(--border);
|
|
1291
|
+
border-radius: var(--radius);
|
|
1292
|
+
box-shadow: var(--shadow);
|
|
1293
|
+
padding: 6px;
|
|
1294
|
+
z-index: 20;
|
|
1295
|
+
}
|
|
1296
|
+
|
|
1297
|
+
.slash-menu[hidden] {
|
|
1298
|
+
display: none;
|
|
1299
|
+
}
|
|
1300
|
+
|
|
1301
|
+
.slash-item {
|
|
1302
|
+
display: block;
|
|
1303
|
+
width: 100%;
|
|
1304
|
+
text-align: left;
|
|
1305
|
+
padding: 8px 10px;
|
|
1306
|
+
border-radius: 8px;
|
|
1307
|
+
}
|
|
1308
|
+
|
|
1309
|
+
.slash-item.on {
|
|
1310
|
+
background: var(--bg-hover);
|
|
1311
|
+
}
|
|
1312
|
+
|
|
1313
|
+
.slash-head {
|
|
1314
|
+
display: flex;
|
|
1315
|
+
align-items: baseline;
|
|
1316
|
+
gap: 8px;
|
|
1317
|
+
min-width: 0;
|
|
1318
|
+
}
|
|
1319
|
+
|
|
1320
|
+
.slash-name {
|
|
1321
|
+
font-family: var(--mono);
|
|
1322
|
+
font-weight: 600;
|
|
1323
|
+
}
|
|
1324
|
+
|
|
1325
|
+
.slash-args {
|
|
1326
|
+
font-family: var(--mono);
|
|
1327
|
+
font-size: 12px;
|
|
1328
|
+
color: var(--fg-soft);
|
|
1329
|
+
white-space: nowrap;
|
|
1330
|
+
overflow: hidden;
|
|
1331
|
+
text-overflow: ellipsis;
|
|
1332
|
+
}
|
|
1333
|
+
|
|
1334
|
+
.slash-desc {
|
|
1335
|
+
font-size: 12px;
|
|
1336
|
+
color: var(--fg-faint);
|
|
1337
|
+
overflow: hidden;
|
|
1338
|
+
text-overflow: ellipsis;
|
|
1339
|
+
white-space: nowrap;
|
|
1340
|
+
}
|
|
1341
|
+
|
|
1342
|
+
.slash-empty {
|
|
1343
|
+
padding: 10px;
|
|
1344
|
+
color: var(--fg-faint);
|
|
1345
|
+
font-size: 13px;
|
|
1346
|
+
}
|
|
1347
|
+
|
|
1348
|
+
.slash-item .badge,
|
|
1349
|
+
.cmd-row .badge {
|
|
1350
|
+
font-size: 11px;
|
|
1351
|
+
padding: 1px 6px;
|
|
1352
|
+
border-radius: 6px;
|
|
1353
|
+
background: var(--bg-soft);
|
|
1354
|
+
color: var(--fg-soft);
|
|
1355
|
+
margin-left: 6px;
|
|
1356
|
+
}
|
|
1357
|
+
|
|
1358
|
+
/* ---------- 设置 → 命令 ---------- */
|
|
1359
|
+
|
|
1360
|
+
.cmd-list {
|
|
1361
|
+
display: flex;
|
|
1362
|
+
flex-direction: column;
|
|
1363
|
+
gap: 6px;
|
|
1364
|
+
max-height: 50vh;
|
|
1365
|
+
overflow-y: auto;
|
|
1366
|
+
}
|
|
1367
|
+
|
|
1368
|
+
.cmd-row {
|
|
1369
|
+
display: flex;
|
|
1370
|
+
align-items: center;
|
|
1371
|
+
gap: 8px;
|
|
1372
|
+
padding: 6px 8px;
|
|
1373
|
+
border: 1px solid var(--border);
|
|
1374
|
+
border-radius: 10px;
|
|
1375
|
+
background: var(--bg-input);
|
|
1376
|
+
}
|
|
1377
|
+
|
|
1378
|
+
.cmd-row.off {
|
|
1379
|
+
opacity: 0.5;
|
|
1380
|
+
}
|
|
1381
|
+
|
|
1382
|
+
.cmd-row.dragging {
|
|
1383
|
+
border-color: var(--accent);
|
|
1384
|
+
}
|
|
1385
|
+
|
|
1386
|
+
.cmd-row .grow {
|
|
1387
|
+
flex: 1;
|
|
1388
|
+
min-width: 0;
|
|
1389
|
+
}
|
|
1390
|
+
|
|
1391
|
+
.cmd-row .t {
|
|
1392
|
+
overflow: hidden;
|
|
1393
|
+
text-overflow: ellipsis;
|
|
1394
|
+
white-space: nowrap;
|
|
1395
|
+
}
|
|
1396
|
+
|
|
1397
|
+
.cmd-row .s {
|
|
1398
|
+
font-size: 12px;
|
|
1399
|
+
color: var(--fg-faint);
|
|
1400
|
+
overflow: hidden;
|
|
1401
|
+
text-overflow: ellipsis;
|
|
1402
|
+
white-space: nowrap;
|
|
1403
|
+
}
|
|
1404
|
+
|
|
1405
|
+
.cmd-grip {
|
|
1406
|
+
cursor: grab;
|
|
1407
|
+
color: var(--fg-faint);
|
|
1408
|
+
user-select: none;
|
|
1409
|
+
letter-spacing: -2px;
|
|
1410
|
+
}
|
|
1411
|
+
|
|
1412
|
+
.cmd-row input[type="checkbox"] {
|
|
1413
|
+
width: auto;
|
|
1414
|
+
}
|