@liujitcn/kratos-admin-system 0.0.26 → 0.0.27
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/dist/package/declarations/src/api/system/base_i18n.d.ts +10 -0
- package/dist/package/declarations/src/api/system/code_gen_i18n.d.ts +1 -1
- package/dist/package/declarations/src/components/DynamicTranslationCell.vue.d.ts +3 -3
- package/dist/package/declarations/src/components/dynamicTranslation.d.ts +1 -1
- package/dist/package/declarations/src/locales/generated.d.ts +941 -0
- package/dist/package/declarations/src/rpc/common/v1/enum.d.ts +15 -6
- package/dist/package/declarations/src/rpc/system/admin/v1/base_api.d.ts +10 -1
- package/dist/package/declarations/src/rpc/system/admin/v1/base_config.d.ts +4 -4
- package/dist/package/declarations/src/rpc/system/admin/v1/base_dict.d.ts +5 -5
- package/dist/package/declarations/src/rpc/system/admin/v1/{base_translation.d.ts → base_i18n.d.ts} +3 -3
- package/dist/package/declarations/src/rpc/system/admin/v1/base_menu.d.ts +3 -3
- package/dist/package/declarations/src/rpc/system/admin/v1/code_gen_column.d.ts +1 -1
- package/dist/package/declarations/src/rpc/system/admin/v1/code_gen_table.d.ts +1 -1
- package/dist/package/declarations/src/rpc/system/admin/v1/project_document.d.ts +8 -0
- package/dist/package/declarations/src/views/tool/code-gen/components/CodeGenLocaleEditor.vue.d.ts +1 -1
- package/dist/package/src/api/base/sse.ts +3 -2
- package/dist/package/src/api/system/{base_translation.ts → base_i18n.ts} +5 -5
- package/dist/package/src/api/system/code_gen_i18n.ts +1 -1
- package/dist/package/src/components/Ai.vue +9 -2
- package/dist/package/src/components/DynamicTranslationCell.vue +9 -9
- package/dist/package/src/components/DynamicTranslationEditor.vue +3 -3
- package/dist/package/src/components/dynamicTranslation.ts +1 -1
- package/dist/package/src/locales/en-US.json +2 -0
- package/dist/package/src/locales/generated.ts +2 -0
- package/dist/package/src/locales/ja-JP.json +935 -0
- package/dist/package/src/locales/zh-CN.json +2 -0
- package/dist/package/src/locales/zh-TW.json +2 -0
- package/dist/package/src/rpc/common/v1/enum.ts +16 -6
- package/dist/package/src/rpc/system/admin/v1/base_api.ts +11 -1
- package/dist/package/src/rpc/system/admin/v1/base_config.ts +4 -4
- package/dist/package/src/rpc/system/admin/v1/base_dict.ts +5 -5
- package/dist/package/src/rpc/system/admin/v1/{base_translation.ts → base_i18n.ts} +4 -4
- package/dist/package/src/rpc/system/admin/v1/base_menu.ts +3 -3
- package/dist/package/src/rpc/system/admin/v1/code_gen_column.ts +1 -1
- package/dist/package/src/rpc/system/admin/v1/code_gen_table.ts +1 -1
- package/dist/package/src/rpc/system/admin/v1/project_document.ts +9 -0
- package/dist/package/src/views/ai/chat/message.ts +12 -2
- package/dist/package/src/views/base/api/index.vue +20 -20
- package/dist/package/src/views/base/config/index.vue +11 -11
- package/dist/package/src/views/base/dept/index.vue +8 -8
- package/dist/package/src/views/base/dict/index.vue +9 -9
- package/dist/package/src/views/base/dict/item.vue +9 -9
- package/dist/package/src/views/base/job/index.vue +11 -11
- package/dist/package/src/views/base/language/index.vue +9 -9
- package/dist/package/src/views/base/menu/index.vue +14 -9
- package/dist/package/src/views/base/post/index.vue +8 -8
- package/dist/package/src/views/base/role/index.vue +8 -8
- package/dist/package/src/views/base/tenant/index.vue +8 -8
- package/dist/package/src/views/base/user/index.vue +8 -8
- package/dist/package/src/views/tool/code-gen/columns/index.vue +8 -53
- package/dist/package/src/views/tool/code-gen/components/CodeGenLocaleEditor.vue +1 -1
- package/dist/package/src/views/tool/code-gen/components/CodeGenProgressDialog.vue +3 -12
- package/dist/package/src/views/tool/code-gen/preview/index.vue +3 -6
- package/dist/package/src/views/tool/code-gen/proto/index.vue +7 -8
- package/dist/package/src/views/tool/code-gen/table/index.vue +2 -2
- package/dist/package/src/views/tool/ops-monitoring/index.vue +23 -25
- package/package.json +2 -2
- package/dist/package/declarations/src/api/system/base_translation.d.ts +0 -10
|
@@ -272,7 +272,7 @@
|
|
|
272
272
|
<ProDialog
|
|
273
273
|
v-model="optionDialog.visible"
|
|
274
274
|
:title="optionDialogTitle"
|
|
275
|
-
width="
|
|
275
|
+
width="560px"
|
|
276
276
|
destroy-on-close
|
|
277
277
|
:show-close="false"
|
|
278
278
|
:close-on-click-modal="false"
|
|
@@ -1287,7 +1287,6 @@ onBeforeUnmount(() => {
|
|
|
1287
1287
|
border-radius: var(--admin-page-radius);
|
|
1288
1288
|
box-shadow: var(--admin-page-shadow);
|
|
1289
1289
|
}
|
|
1290
|
-
|
|
1291
1290
|
:deep(.code-gen-toolbar) {
|
|
1292
1291
|
display: flex;
|
|
1293
1292
|
flex-wrap: wrap;
|
|
@@ -1296,13 +1295,11 @@ onBeforeUnmount(() => {
|
|
|
1296
1295
|
justify-content: flex-end;
|
|
1297
1296
|
margin-bottom: 14px;
|
|
1298
1297
|
}
|
|
1299
|
-
|
|
1300
1298
|
.code-gen-column-pane {
|
|
1301
1299
|
display: flex;
|
|
1302
1300
|
flex-direction: column;
|
|
1303
1301
|
gap: 14px;
|
|
1304
1302
|
}
|
|
1305
|
-
|
|
1306
1303
|
.code-gen-column-toolbar {
|
|
1307
1304
|
justify-content: space-between;
|
|
1308
1305
|
padding: 12px 14px;
|
|
@@ -1310,7 +1307,6 @@ onBeforeUnmount(() => {
|
|
|
1310
1307
|
border: 1px solid var(--admin-page-card-border-soft);
|
|
1311
1308
|
border-radius: var(--admin-page-radius);
|
|
1312
1309
|
}
|
|
1313
|
-
|
|
1314
1310
|
.code-gen-column-toolbar__meta {
|
|
1315
1311
|
display: flex;
|
|
1316
1312
|
flex-wrap: wrap;
|
|
@@ -1319,54 +1315,45 @@ onBeforeUnmount(() => {
|
|
|
1319
1315
|
min-width: 0;
|
|
1320
1316
|
color: var(--admin-page-text-secondary);
|
|
1321
1317
|
}
|
|
1322
|
-
|
|
1323
1318
|
.code-gen-column-toolbar__meta strong {
|
|
1324
1319
|
font-size: 14px;
|
|
1325
1320
|
color: var(--admin-page-text-primary);
|
|
1326
1321
|
}
|
|
1327
|
-
|
|
1328
1322
|
.code-gen-column-toolbar__meta span {
|
|
1329
1323
|
padding: 3px 8px;
|
|
1330
1324
|
overflow: hidden;
|
|
1325
|
+
text-overflow: ellipsis;
|
|
1331
1326
|
font-size: 12px;
|
|
1332
1327
|
line-height: 18px;
|
|
1333
|
-
text-overflow: ellipsis;
|
|
1334
1328
|
white-space: nowrap;
|
|
1335
1329
|
background: var(--admin-page-card-bg);
|
|
1336
1330
|
border: 1px solid var(--admin-page-card-border-soft);
|
|
1337
1331
|
border-radius: 999px;
|
|
1338
1332
|
}
|
|
1339
|
-
|
|
1340
1333
|
.code-gen-column-toolbar__table-name {
|
|
1341
1334
|
max-width: 220px;
|
|
1342
1335
|
}
|
|
1343
|
-
|
|
1344
1336
|
.code-gen-column-toolbar__table-comment {
|
|
1345
1337
|
max-width: 280px;
|
|
1346
1338
|
}
|
|
1347
|
-
|
|
1348
1339
|
.code-gen-column-toolbar__actions {
|
|
1349
1340
|
display: flex;
|
|
1350
|
-
gap: 8px;
|
|
1351
1341
|
flex-shrink: 0;
|
|
1342
|
+
gap: 8px;
|
|
1352
1343
|
margin-left: auto;
|
|
1353
1344
|
}
|
|
1354
|
-
|
|
1355
1345
|
.code-gen-column-table {
|
|
1356
1346
|
overflow: hidden;
|
|
1357
1347
|
border-radius: var(--admin-page-radius);
|
|
1358
1348
|
}
|
|
1359
|
-
|
|
1360
1349
|
:deep(.code-gen-column-table .el-table__header th) {
|
|
1361
1350
|
color: var(--admin-page-text-secondary);
|
|
1362
1351
|
background: var(--admin-page-card-bg-soft);
|
|
1363
1352
|
}
|
|
1364
|
-
|
|
1365
1353
|
:deep(.code-gen-column-table .el-table__cell) {
|
|
1366
1354
|
padding: 8px 0;
|
|
1367
1355
|
vertical-align: middle;
|
|
1368
1356
|
}
|
|
1369
|
-
|
|
1370
1357
|
.code-gen-field-cell,
|
|
1371
1358
|
.code-gen-field-trigger,
|
|
1372
1359
|
.code-gen-field-order {
|
|
@@ -1375,48 +1362,39 @@ onBeforeUnmount(() => {
|
|
|
1375
1362
|
align-items: center;
|
|
1376
1363
|
min-width: 0;
|
|
1377
1364
|
}
|
|
1378
|
-
|
|
1379
1365
|
.code-gen-field-cell {
|
|
1380
1366
|
justify-content: space-between;
|
|
1381
1367
|
}
|
|
1382
|
-
|
|
1383
1368
|
.code-gen-field-trigger {
|
|
1384
1369
|
flex: 1;
|
|
1385
1370
|
min-height: 28px;
|
|
1386
1371
|
cursor: help;
|
|
1387
1372
|
}
|
|
1388
|
-
|
|
1389
1373
|
.code-gen-field-order {
|
|
1390
|
-
gap: 4px;
|
|
1391
1374
|
flex-shrink: 0;
|
|
1375
|
+
gap: 4px;
|
|
1392
1376
|
}
|
|
1393
|
-
|
|
1394
1377
|
.code-gen-field-order__index {
|
|
1395
1378
|
min-width: 18px;
|
|
1396
1379
|
font-size: 12px;
|
|
1397
1380
|
color: var(--admin-page-text-secondary);
|
|
1398
1381
|
text-align: right;
|
|
1399
1382
|
}
|
|
1400
|
-
|
|
1401
1383
|
.code-gen-field-order__drag {
|
|
1402
1384
|
width: 24px;
|
|
1403
1385
|
height: 24px;
|
|
1404
1386
|
padding: 0;
|
|
1405
1387
|
cursor: grab;
|
|
1406
1388
|
}
|
|
1407
|
-
|
|
1408
1389
|
.code-gen-field-order__drag:active {
|
|
1409
1390
|
cursor: grabbing;
|
|
1410
1391
|
}
|
|
1411
|
-
|
|
1412
1392
|
:deep(.code-gen-column-sortable-ghost > td) {
|
|
1413
1393
|
background: var(--admin-page-card-bg-soft);
|
|
1414
1394
|
}
|
|
1415
|
-
|
|
1416
1395
|
:deep(.code-gen-column-sortable-chosen > td) {
|
|
1417
1396
|
background: var(--admin-page-card-bg-soft);
|
|
1418
1397
|
}
|
|
1419
|
-
|
|
1420
1398
|
.code-gen-config-cell,
|
|
1421
1399
|
.code-gen-comment-editor,
|
|
1422
1400
|
.code-gen-static-options__header,
|
|
@@ -1426,54 +1404,45 @@ onBeforeUnmount(() => {
|
|
|
1426
1404
|
gap: 8px;
|
|
1427
1405
|
align-items: center;
|
|
1428
1406
|
}
|
|
1429
|
-
|
|
1430
1407
|
.code-gen-comment-editor {
|
|
1431
1408
|
flex-wrap: nowrap;
|
|
1432
1409
|
}
|
|
1433
|
-
|
|
1434
1410
|
.code-gen-comment-editor .el-input {
|
|
1435
1411
|
min-width: 0;
|
|
1436
1412
|
}
|
|
1437
|
-
|
|
1438
1413
|
.code-gen-field-trigger__name {
|
|
1439
1414
|
flex-shrink: 0;
|
|
1440
1415
|
max-width: 135px;
|
|
1441
1416
|
overflow: hidden;
|
|
1417
|
+
text-overflow: ellipsis;
|
|
1442
1418
|
font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
|
|
1443
1419
|
font-size: 13px;
|
|
1444
1420
|
font-weight: 700;
|
|
1445
1421
|
color: var(--admin-page-text-primary);
|
|
1446
|
-
text-overflow: ellipsis;
|
|
1447
1422
|
white-space: nowrap;
|
|
1448
1423
|
}
|
|
1449
|
-
|
|
1450
1424
|
.code-gen-field-popover {
|
|
1451
1425
|
display: grid;
|
|
1452
1426
|
gap: 12px;
|
|
1453
1427
|
}
|
|
1454
|
-
|
|
1455
1428
|
.code-gen-field-popover__header {
|
|
1456
1429
|
display: grid;
|
|
1457
1430
|
gap: 3px;
|
|
1458
1431
|
}
|
|
1459
|
-
|
|
1460
1432
|
.code-gen-field-popover__header strong,
|
|
1461
1433
|
.code-gen-field-popover__types b {
|
|
1462
1434
|
font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
|
|
1463
1435
|
color: var(--admin-page-text-primary);
|
|
1464
1436
|
}
|
|
1465
|
-
|
|
1466
1437
|
.code-gen-field-popover__header span {
|
|
1467
1438
|
font-size: 12px;
|
|
1468
1439
|
color: var(--admin-page-text-secondary);
|
|
1469
1440
|
}
|
|
1470
|
-
|
|
1471
1441
|
.code-gen-field-popover__types {
|
|
1472
1442
|
display: grid;
|
|
1473
1443
|
grid-template-columns: repeat(2, minmax(0, 1fr));
|
|
1474
1444
|
gap: 7px 12px;
|
|
1475
1445
|
}
|
|
1476
|
-
|
|
1477
1446
|
.code-gen-field-popover__types div {
|
|
1478
1447
|
display: grid;
|
|
1479
1448
|
grid-template-columns: 52px minmax(0, 1fr);
|
|
@@ -1482,40 +1451,33 @@ onBeforeUnmount(() => {
|
|
|
1482
1451
|
min-width: 0;
|
|
1483
1452
|
font-size: 12px;
|
|
1484
1453
|
}
|
|
1485
|
-
|
|
1486
1454
|
.code-gen-field-popover__types span {
|
|
1487
1455
|
color: var(--admin-page-text-secondary);
|
|
1488
1456
|
}
|
|
1489
|
-
|
|
1490
1457
|
.code-gen-field-popover__types b {
|
|
1491
1458
|
overflow: hidden;
|
|
1492
|
-
font-size: 12px;
|
|
1493
1459
|
text-overflow: ellipsis;
|
|
1460
|
+
font-size: 12px;
|
|
1494
1461
|
white-space: nowrap;
|
|
1495
1462
|
}
|
|
1496
|
-
|
|
1497
1463
|
.code-gen-field-popover__flags {
|
|
1498
1464
|
display: flex;
|
|
1465
|
+
flex-wrap: wrap;
|
|
1499
1466
|
gap: 6px;
|
|
1500
1467
|
align-items: center;
|
|
1501
|
-
flex-wrap: wrap;
|
|
1502
1468
|
}
|
|
1503
|
-
|
|
1504
1469
|
.code-gen-config-cell .el-select {
|
|
1505
1470
|
width: 124px;
|
|
1506
1471
|
}
|
|
1507
|
-
|
|
1508
1472
|
.code-gen-config-cell .el-checkbox {
|
|
1509
1473
|
margin-right: 0;
|
|
1510
1474
|
}
|
|
1511
|
-
|
|
1512
1475
|
.code-gen-option-dialog,
|
|
1513
1476
|
.code-gen-static-options,
|
|
1514
1477
|
.code-gen-static-options__list {
|
|
1515
1478
|
display: grid;
|
|
1516
1479
|
gap: 10px;
|
|
1517
1480
|
}
|
|
1518
|
-
|
|
1519
1481
|
.code-gen-config-dialog__header {
|
|
1520
1482
|
display: flex;
|
|
1521
1483
|
gap: 12px;
|
|
@@ -1523,41 +1485,34 @@ onBeforeUnmount(() => {
|
|
|
1523
1485
|
justify-content: space-between;
|
|
1524
1486
|
width: 100%;
|
|
1525
1487
|
}
|
|
1526
|
-
|
|
1527
1488
|
.code-gen-popover-form__row {
|
|
1528
1489
|
display: grid;
|
|
1529
1490
|
grid-template-columns: 92px minmax(0, 1fr);
|
|
1530
1491
|
gap: 10px;
|
|
1531
1492
|
align-items: center;
|
|
1532
1493
|
}
|
|
1533
|
-
|
|
1534
1494
|
.code-gen-popover-form__label {
|
|
1535
1495
|
font-size: 12px;
|
|
1536
1496
|
color: var(--admin-page-text-secondary);
|
|
1537
1497
|
}
|
|
1538
|
-
|
|
1539
1498
|
.code-gen-static-options {
|
|
1540
1499
|
padding-top: 2px;
|
|
1541
1500
|
}
|
|
1542
|
-
|
|
1543
1501
|
.code-gen-static-options__header {
|
|
1544
1502
|
justify-content: space-between;
|
|
1545
1503
|
}
|
|
1546
|
-
|
|
1547
1504
|
.code-gen-static-options__item {
|
|
1548
1505
|
flex-wrap: nowrap;
|
|
1549
1506
|
}
|
|
1550
|
-
|
|
1551
1507
|
.code-gen-static-options__item .el-input {
|
|
1552
1508
|
min-width: 0;
|
|
1553
1509
|
}
|
|
1554
1510
|
|
|
1555
1511
|
@media (width <= 900px) {
|
|
1556
1512
|
.code-gen-column-toolbar {
|
|
1557
|
-
align-items: flex-start;
|
|
1558
1513
|
flex-direction: column;
|
|
1514
|
+
align-items: flex-start;
|
|
1559
1515
|
}
|
|
1560
|
-
|
|
1561
1516
|
.code-gen-column-toolbar__actions {
|
|
1562
1517
|
margin-left: 0;
|
|
1563
1518
|
}
|
|
@@ -38,7 +38,7 @@
|
|
|
38
38
|
import { computed } from "vue";
|
|
39
39
|
import { t } from "@liujitcn/kratos-admin-core";
|
|
40
40
|
import { loadEnabledBaseLanguages, useEnabledBaseLanguages } from "@liujitcn/kratos-admin-system/api/system/base_language";
|
|
41
|
-
import type { CodeGenLocaleConfig } from "@liujitcn/kratos-admin-system/rpc/system/admin/v1/
|
|
41
|
+
import type { CodeGenLocaleConfig } from "@liujitcn/kratos-admin-system/rpc/system/admin/v1/base_i18n";
|
|
42
42
|
|
|
43
43
|
/** 代码生成多语言编辑器属性。 */
|
|
44
44
|
interface CodeGenLocaleEditorProps {
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
<ProDialog
|
|
3
3
|
:model-value="modelValue"
|
|
4
4
|
:title="t('system.code.gen.progress.title')"
|
|
5
|
-
width="
|
|
5
|
+
width="1080px"
|
|
6
6
|
top="4vh"
|
|
7
7
|
:close-on-click-modal="false"
|
|
8
8
|
:show-footer="false"
|
|
@@ -287,7 +287,6 @@ onBeforeUnmount(stopTracking);
|
|
|
287
287
|
.progress-dialog {
|
|
288
288
|
min-height: 220px;
|
|
289
289
|
}
|
|
290
|
-
|
|
291
290
|
.task-heading,
|
|
292
291
|
.table-heading,
|
|
293
292
|
.task-meta {
|
|
@@ -295,40 +294,33 @@ onBeforeUnmount(stopTracking);
|
|
|
295
294
|
gap: 12px;
|
|
296
295
|
align-items: center;
|
|
297
296
|
}
|
|
298
|
-
|
|
299
297
|
.task-heading {
|
|
300
298
|
justify-content: space-between;
|
|
301
299
|
margin-bottom: 14px;
|
|
302
300
|
}
|
|
303
|
-
|
|
304
301
|
.task-heading > div {
|
|
305
302
|
display: flex;
|
|
306
303
|
gap: 12px;
|
|
307
304
|
align-items: baseline;
|
|
308
305
|
}
|
|
309
|
-
|
|
310
306
|
.task-meta {
|
|
311
307
|
flex-wrap: wrap;
|
|
312
308
|
justify-content: space-between;
|
|
313
309
|
margin: 10px 0 18px;
|
|
314
|
-
color: var(--el-text-color-secondary);
|
|
315
310
|
font-size: 13px;
|
|
311
|
+
color: var(--el-text-color-secondary);
|
|
316
312
|
}
|
|
317
|
-
|
|
318
313
|
.table-progress-list {
|
|
319
314
|
max-height: 54vh;
|
|
320
315
|
overflow: auto;
|
|
321
316
|
}
|
|
322
|
-
|
|
323
317
|
.table-heading {
|
|
324
318
|
width: 100%;
|
|
325
319
|
padding-right: 16px;
|
|
326
320
|
}
|
|
327
|
-
|
|
328
321
|
.table-heading strong {
|
|
329
322
|
margin-right: auto;
|
|
330
323
|
}
|
|
331
|
-
|
|
332
324
|
.table-message {
|
|
333
325
|
display: flex;
|
|
334
326
|
gap: 6px;
|
|
@@ -336,11 +328,10 @@ onBeforeUnmount(stopTracking);
|
|
|
336
328
|
margin: 0 0 10px;
|
|
337
329
|
color: var(--el-text-color-secondary);
|
|
338
330
|
}
|
|
339
|
-
|
|
340
331
|
.table-message span {
|
|
341
332
|
min-width: 0;
|
|
333
|
+
overflow-wrap: break-word;
|
|
342
334
|
white-space: pre-wrap;
|
|
343
|
-
word-break: break-word;
|
|
344
335
|
}
|
|
345
336
|
</style>
|
|
346
337
|
|
|
@@ -54,7 +54,7 @@
|
|
|
54
54
|
v-model="dialog.visible"
|
|
55
55
|
ref="formDialogRef"
|
|
56
56
|
:title="dialogTitle"
|
|
57
|
-
width="
|
|
57
|
+
width="920px"
|
|
58
58
|
top="4vh"
|
|
59
59
|
:model="previewFormModel"
|
|
60
60
|
:fields="formFields"
|
|
@@ -837,32 +837,29 @@ onMounted(() => {
|
|
|
837
837
|
display: flex;
|
|
838
838
|
flex-direction: column;
|
|
839
839
|
width: 100%;
|
|
840
|
-
height: 100%;
|
|
841
840
|
min-width: 0;
|
|
841
|
+
height: 100%;
|
|
842
842
|
min-height: 0;
|
|
843
843
|
overflow: hidden;
|
|
844
844
|
}
|
|
845
|
-
|
|
846
845
|
.code-gen-page-preview__table,
|
|
847
846
|
.code-gen-left-tree-preview {
|
|
848
847
|
min-width: 0;
|
|
849
848
|
min-height: 0;
|
|
850
849
|
overflow: hidden;
|
|
851
850
|
}
|
|
852
|
-
|
|
853
851
|
.code-gen-left-tree-preview__table {
|
|
854
852
|
min-width: 0;
|
|
855
853
|
min-height: 0;
|
|
856
854
|
}
|
|
857
|
-
|
|
858
855
|
:deep(.code-gen-page-preview-table) {
|
|
859
856
|
--el-table-header-bg-color: var(--el-fill-color-light);
|
|
860
857
|
}
|
|
861
858
|
|
|
862
859
|
@media (width <= 768px) {
|
|
863
860
|
:deep(.el-dialog .el-col-12) {
|
|
864
|
-
max-width: 100%;
|
|
865
861
|
flex: 0 0 100%;
|
|
862
|
+
max-width: 100%;
|
|
866
863
|
}
|
|
867
864
|
}
|
|
868
865
|
</style>
|
|
@@ -87,7 +87,7 @@
|
|
|
87
87
|
<ProDialog
|
|
88
88
|
v-model="configDialog.visible"
|
|
89
89
|
:title="configDialogTitle"
|
|
90
|
-
width="
|
|
90
|
+
width="520px"
|
|
91
91
|
destroy-on-close
|
|
92
92
|
:show-close="false"
|
|
93
93
|
:close-on-click-modal="false"
|
|
@@ -599,7 +599,6 @@ onMounted(() => {
|
|
|
599
599
|
border-radius: var(--admin-page-radius);
|
|
600
600
|
box-shadow: var(--admin-page-shadow);
|
|
601
601
|
}
|
|
602
|
-
|
|
603
602
|
.code-gen-config-dialog__header {
|
|
604
603
|
display: flex;
|
|
605
604
|
gap: 12px;
|
|
@@ -607,7 +606,6 @@ onMounted(() => {
|
|
|
607
606
|
justify-content: space-between;
|
|
608
607
|
width: 100%;
|
|
609
608
|
}
|
|
610
|
-
|
|
611
609
|
:deep(.code-gen-toolbar) {
|
|
612
610
|
display: flex;
|
|
613
611
|
flex-wrap: wrap;
|
|
@@ -667,6 +665,7 @@ onMounted(() => {
|
|
|
667
665
|
flex-wrap: wrap;
|
|
668
666
|
gap: 8px;
|
|
669
667
|
align-items: center;
|
|
668
|
+
|
|
670
669
|
/* 多行单元格与列标题保持居中,避免文本继承居中而 Flex 子项贴左。 */
|
|
671
670
|
justify-content: center;
|
|
672
671
|
min-width: 0;
|
|
@@ -693,14 +692,14 @@ onMounted(() => {
|
|
|
693
692
|
flex-direction: column;
|
|
694
693
|
gap: 2px;
|
|
695
694
|
min-width: 0;
|
|
696
|
-
cursor: pointer;
|
|
697
695
|
text-align: left;
|
|
696
|
+
cursor: pointer;
|
|
698
697
|
}
|
|
699
698
|
.code-gen-proto-capability-trigger__comment {
|
|
700
699
|
overflow: hidden;
|
|
701
700
|
text-overflow: ellipsis;
|
|
702
|
-
white-space: nowrap;
|
|
703
701
|
color: var(--admin-page-text-primary);
|
|
702
|
+
white-space: nowrap;
|
|
704
703
|
}
|
|
705
704
|
.code-gen-proto-capability-popover {
|
|
706
705
|
display: flex;
|
|
@@ -709,8 +708,8 @@ onMounted(() => {
|
|
|
709
708
|
}
|
|
710
709
|
.code-gen-proto-capability-popover__preview {
|
|
711
710
|
max-width: 100%;
|
|
712
|
-
margin: 0;
|
|
713
711
|
padding: 10px;
|
|
712
|
+
margin: 0;
|
|
714
713
|
overflow-x: auto;
|
|
715
714
|
font-size: 12px;
|
|
716
715
|
line-height: 18px;
|
|
@@ -730,8 +729,8 @@ onMounted(() => {
|
|
|
730
729
|
}
|
|
731
730
|
.code-gen-proto-capability-popover__item code {
|
|
732
731
|
min-width: 0;
|
|
733
|
-
overflow-wrap: anywhere;
|
|
734
732
|
color: var(--admin-page-text-primary);
|
|
733
|
+
overflow-wrap: anywhere;
|
|
735
734
|
}
|
|
736
735
|
.code-gen-proto-capability-popover__item .code-gen-proto-capability-popover__path {
|
|
737
736
|
display: block;
|
|
@@ -742,8 +741,8 @@ onMounted(() => {
|
|
|
742
741
|
}
|
|
743
742
|
.code-gen-proto-capability-popover__value {
|
|
744
743
|
min-width: 0;
|
|
745
|
-
overflow-wrap: anywhere;
|
|
746
744
|
color: var(--admin-page-text-primary);
|
|
745
|
+
overflow-wrap: anywhere;
|
|
747
746
|
}
|
|
748
747
|
.code-gen-proto-config-form :deep(.el-select) {
|
|
749
748
|
width: 100%;
|
|
@@ -15,7 +15,8 @@
|
|
|
15
15
|
v-model="dialog.visible"
|
|
16
16
|
ref="formDialogRef"
|
|
17
17
|
:title="dialogTitle"
|
|
18
|
-
width="
|
|
18
|
+
width="920px"
|
|
19
|
+
label-width="240px"
|
|
19
20
|
top="4vh"
|
|
20
21
|
:model="formData"
|
|
21
22
|
:fields="formFields"
|
|
@@ -936,7 +937,6 @@ function ensureLeftTreeConfig() {
|
|
|
936
937
|
/* 固定操作列表头与普通表头使用同一主题背景,并保持行内操作单行展示。 */
|
|
937
938
|
:deep(.code-gen-table) {
|
|
938
939
|
--el-table-header-bg-color: var(--el-fill-color-light);
|
|
939
|
-
|
|
940
940
|
td.el-table-fixed-column--right .cell {
|
|
941
941
|
white-space: nowrap;
|
|
942
942
|
}
|
|
@@ -225,15 +225,8 @@
|
|
|
225
225
|
</template>
|
|
226
226
|
|
|
227
227
|
<script setup lang="ts">
|
|
228
|
-
import { computed, onBeforeUnmount, onMounted, ref } from "vue";
|
|
228
|
+
import { computed, onActivated, onBeforeUnmount, onDeactivated, onMounted, ref } from "vue";
|
|
229
229
|
import { defOpsMonitoringService } from "@liujitcn/kratos-admin-system/api/system/ops_monitoring";
|
|
230
|
-
import {
|
|
231
|
-
subscribeOpsMonitoringNodes,
|
|
232
|
-
subscribeOpsMonitoringServices,
|
|
233
|
-
subscribeOpsMonitoringStorage,
|
|
234
|
-
subscribeOpsMonitoringTraffic,
|
|
235
|
-
type OpsMonitoringSseStop
|
|
236
|
-
} from "@liujitcn/kratos-admin-system/api/system/ops_monitoring_sse";
|
|
237
230
|
import { getCurrentLocale, t } from "@liujitcn/kratos-admin-core";
|
|
238
231
|
import type {
|
|
239
232
|
OpsAlert,
|
|
@@ -438,7 +431,9 @@ const alertItems = computed(() => (alerts.value?.alerts ?? []).map(mapAlert));
|
|
|
438
431
|
const serviceCount = computed(() => availabilityItems.value.length);
|
|
439
432
|
const onlineCount = computed(() => availabilityItems.value.filter(item => item.tone === "ok").length);
|
|
440
433
|
|
|
441
|
-
let
|
|
434
|
+
let monitoringTimer: number | undefined;
|
|
435
|
+
let monitoringActive = false;
|
|
436
|
+
let monitoringRun = 0;
|
|
442
437
|
|
|
443
438
|
async function loadMonitoring() {
|
|
444
439
|
loading.value = true;
|
|
@@ -495,18 +490,23 @@ function updateCollectedAt(value?: string) {
|
|
|
495
490
|
if (value) lastCollectedAt.value = value;
|
|
496
491
|
}
|
|
497
492
|
|
|
498
|
-
function
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
|
|
504
|
-
|
|
493
|
+
async function startMonitoring() {
|
|
494
|
+
if (monitoringActive) return;
|
|
495
|
+
monitoringActive = true;
|
|
496
|
+
const run = ++monitoringRun;
|
|
497
|
+
await loadMonitoring();
|
|
498
|
+
if (!monitoringActive || run !== monitoringRun) return;
|
|
499
|
+
monitoringTimer = window.setInterval(() => {
|
|
500
|
+
if (!loading.value) void loadMonitoring();
|
|
501
|
+
}, 5000);
|
|
505
502
|
}
|
|
506
503
|
|
|
507
|
-
function
|
|
508
|
-
|
|
509
|
-
|
|
504
|
+
function stopMonitoring() {
|
|
505
|
+
monitoringActive = false;
|
|
506
|
+
monitoringRun += 1;
|
|
507
|
+
if (monitoringTimer === undefined) return;
|
|
508
|
+
window.clearInterval(monitoringTimer);
|
|
509
|
+
monitoringTimer = undefined;
|
|
510
510
|
}
|
|
511
511
|
|
|
512
512
|
function formatNumber(value?: number) {
|
|
@@ -596,12 +596,10 @@ function mapAlert(alert: OpsAlert) {
|
|
|
596
596
|
};
|
|
597
597
|
}
|
|
598
598
|
|
|
599
|
-
onMounted(
|
|
600
|
-
|
|
601
|
-
|
|
602
|
-
|
|
603
|
-
|
|
604
|
-
onBeforeUnmount(stopRealtime);
|
|
599
|
+
onMounted(startMonitoring);
|
|
600
|
+
onActivated(startMonitoring);
|
|
601
|
+
onDeactivated(stopMonitoring);
|
|
602
|
+
onBeforeUnmount(stopMonitoring);
|
|
605
603
|
</script>
|
|
606
604
|
|
|
607
605
|
<style scoped lang="scss">
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@liujitcn/kratos-admin-system",
|
|
3
3
|
"private": false,
|
|
4
|
-
"version": "0.0.
|
|
4
|
+
"version": "0.0.27",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"description": "kratos-admin system management module",
|
|
7
7
|
"license": "MIT",
|
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
"sortablejs": "^1.15.2",
|
|
16
16
|
"swagger-ui-dist": "^5.32.9",
|
|
17
17
|
"vue-element-plus-x": "^2.0.3",
|
|
18
|
-
"@liujitcn/kratos-admin-core": "0.0.
|
|
18
|
+
"@liujitcn/kratos-admin-core": "0.0.27"
|
|
19
19
|
},
|
|
20
20
|
"peerDependencies": {
|
|
21
21
|
"@element-plus/icons-vue": "^2.3.1",
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import type { Empty } from "@liujitcn/kratos-admin-system/rpc/google/protobuf/empty";
|
|
2
|
-
import type { BaseTranslationService, DraftBaseTranslationRequest, DraftBaseTranslationResponse, UpdateBaseTranslationRequest } from "@liujitcn/kratos-admin-system/rpc/system/admin/v1/base_translation";
|
|
3
|
-
/** BaseTranslationServiceImpl Admin 单条动态翻译服务。 */
|
|
4
|
-
export declare class BaseTranslationServiceImpl implements BaseTranslationService {
|
|
5
|
-
/** DraftBaseTranslation 翻译请求中的单个文本。 */
|
|
6
|
-
DraftBaseTranslation(request: DraftBaseTranslationRequest): Promise<DraftBaseTranslationResponse>;
|
|
7
|
-
/** UpdateBaseTranslation 修改或新增单条翻译信息。 */
|
|
8
|
-
UpdateBaseTranslation(request: UpdateBaseTranslationRequest): Promise<Empty>;
|
|
9
|
-
}
|
|
10
|
-
export declare const defBaseTranslationService: BaseTranslationServiceImpl;
|