@kupola/kupola 1.4.3 → 1.4.4
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 +28 -3
- package/css/components-ext.css +1 -1
- package/dist/css/components-ext.css +158 -1
- package/dist/css/components.css +93 -1
- package/dist/css/kupola.css +13 -12
- package/dist/css/table.css +74 -0
- package/dist/css/theme-dark.css +5 -5
- package/dist/css/utilities.css +159 -1
- package/dist/kupola.cjs.js +214 -15600
- package/dist/kupola.cjs.js.map +1 -1
- package/dist/kupola.css +1 -1
- package/dist/kupola.esm.js +8195 -15405
- package/dist/kupola.esm.js.map +1 -1
- package/dist/kupola.min.css +1 -1
- package/dist/kupola.umd.js +214 -15606
- package/dist/kupola.umd.js.map +1 -1
- package/js/theme.js +10 -4
- package/package.json +3 -3
- package/dist/css/kupola.min.css +0 -1
- package/dist/icons.svg +0 -284
- package/dist/kupola.min.js +0 -2
- package/dist/kupola.min.js.map +0 -1
- /package/dist/css/{colors_and_type.css → colors-and-type.css} +0 -0
package/README.md
CHANGED
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
|
|
7
7
|
[](https://github.com/kupola-cn/kupola/blob/main/LICENSE)
|
|
8
8
|
[](https://www.npmjs.com/package/@kupola/kupola)
|
|
9
|
-
[](https://img.shields.io/badge/gzip-75%20KB-blue)](https://bundlephobia.com/package/@kupola/kupola)
|
|
10
10
|
[](https://github.com/kupola-cn/kupola/stargazers)
|
|
11
11
|
|
|
12
12
|
**HTMX** (data fetching) + **Alpine.js** (declarative interaction) + **Bootstrap** (component richness) — in one zero-dependency package.
|
|
@@ -18,6 +18,11 @@
|
|
|
18
18
|
- [English](#english)
|
|
19
19
|
- [中文](#中文)
|
|
20
20
|
|
|
21
|
+
## 📖 Documentation
|
|
22
|
+
|
|
23
|
+
- [**用户文档**](https://kupola-cn.github.io/kupola/docs/index.html) — 安装、组件速查、核心 API、主题、后端集成
|
|
24
|
+
- [**架构文档**](https://kupola-cn.github.io/kupola/docs/architecture.html) — 内部引擎、模块依赖、构建管线、贡献指南
|
|
25
|
+
|
|
21
26
|
---
|
|
22
27
|
|
|
23
28
|
<a id="english"></a>
|
|
@@ -32,7 +37,7 @@
|
|
|
32
37
|
- **Responsive** — PC, Pad, and Phone
|
|
33
38
|
- **Accessible** — WCAG AA compliant
|
|
34
39
|
- **Form Validation** — Built-in validation with custom rules
|
|
35
|
-
- **Zero Dependencies** — Pure HTML/CSS/JavaScript, ~
|
|
40
|
+
- **Zero Dependencies** — Pure HTML/CSS/JavaScript, ~75 KB minified gzipped
|
|
36
41
|
- **Backend Agnostic** — Works with Flask, Django, FastAPI, Gin, Spring Boot, ASP.NET, Express, Rails, Actix-web, and any backend that outputs HTML
|
|
37
42
|
- **TypeScript Ready** — Full type definitions included
|
|
38
43
|
|
|
@@ -40,6 +45,16 @@
|
|
|
40
45
|
|
|
41
46
|
## 🚀 Quick Start
|
|
42
47
|
|
|
48
|
+
### Scaffold (recommended)
|
|
49
|
+
|
|
50
|
+
Create a fully configured Kupola project in seconds:
|
|
51
|
+
|
|
52
|
+
```bash
|
|
53
|
+
npx @kupola/create-kupola
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
Choose from **Static**, **Flask**, **FastAPI**, or **Gin** — with dark theme, brand colors, and example pages out of the box.
|
|
57
|
+
|
|
43
58
|
### npm
|
|
44
59
|
|
|
45
60
|
```bash
|
|
@@ -181,7 +196,7 @@ Chrome, Firefox, Safari, Edge (latest)
|
|
|
181
196
|
- **响应式** — 适配 PC、平板、手机
|
|
182
197
|
- **无障碍** — 符合 WCAG AA 标准
|
|
183
198
|
- **表单验证** — 内置验证系统,支持自定义规则
|
|
184
|
-
- **零依赖** — 纯 HTML/CSS/JavaScript,gzip
|
|
199
|
+
- **零依赖** — 纯 HTML/CSS/JavaScript,minified gzip 约 75 KB
|
|
185
200
|
- **后端无关** — 支持 Flask、Django、FastAPI、Gin、Spring Boot、ASP.NET、Express、Rails、Actix-web 等任何输出 HTML 的后端
|
|
186
201
|
- **TypeScript 支持** — 完整类型定义
|
|
187
202
|
|
|
@@ -189,6 +204,16 @@ Chrome, Firefox, Safari, Edge (latest)
|
|
|
189
204
|
|
|
190
205
|
## 🚀 快速开始
|
|
191
206
|
|
|
207
|
+
### 脚手架(推荐)
|
|
208
|
+
|
|
209
|
+
一行命令创建配置好的 Kupola 项目:
|
|
210
|
+
|
|
211
|
+
```bash
|
|
212
|
+
npx @kupola/create-kupola
|
|
213
|
+
```
|
|
214
|
+
|
|
215
|
+
支持 **Static**、**Flask**、**FastAPI**、**Gin** 四种后端模板,自带暗色主题、品牌色和示例页面。
|
|
216
|
+
|
|
192
217
|
### npm 安装
|
|
193
218
|
|
|
194
219
|
```bash
|
package/css/components-ext.css
CHANGED
|
@@ -1403,6 +1403,42 @@
|
|
|
1403
1403
|
border-radius: 50%;
|
|
1404
1404
|
}
|
|
1405
1405
|
|
|
1406
|
+
/* IMP-009: Skeleton size variants */
|
|
1407
|
+
.ds-skeleton--text {
|
|
1408
|
+
height: 14px;
|
|
1409
|
+
margin-bottom: var(--spacer-8);
|
|
1410
|
+
}
|
|
1411
|
+
|
|
1412
|
+
.ds-skeleton--heading {
|
|
1413
|
+
height: 24px;
|
|
1414
|
+
width: 40%;
|
|
1415
|
+
margin-bottom: var(--spacer-12);
|
|
1416
|
+
}
|
|
1417
|
+
|
|
1418
|
+
.ds-skeleton--block {
|
|
1419
|
+
height: 200px;
|
|
1420
|
+
}
|
|
1421
|
+
|
|
1422
|
+
.ds-skeleton--avatar {
|
|
1423
|
+
width: 40px;
|
|
1424
|
+
height: 40px;
|
|
1425
|
+
}
|
|
1426
|
+
|
|
1427
|
+
.ds-skeleton--button {
|
|
1428
|
+
height: 28px;
|
|
1429
|
+
width: 80px;
|
|
1430
|
+
}
|
|
1431
|
+
|
|
1432
|
+
.ds-skeleton--input {
|
|
1433
|
+
height: 28px;
|
|
1434
|
+
width: 100%;
|
|
1435
|
+
}
|
|
1436
|
+
|
|
1437
|
+
.ds-skeleton--table {
|
|
1438
|
+
height: 200px;
|
|
1439
|
+
width: 100%;
|
|
1440
|
+
}
|
|
1441
|
+
|
|
1406
1442
|
@keyframes ds-skeleton-pulse {
|
|
1407
1443
|
0%, 100% { opacity: 1; }
|
|
1408
1444
|
50% { opacity: 0.5; }
|
|
@@ -2661,6 +2697,17 @@
|
|
|
2661
2697
|
right: 2px;
|
|
2662
2698
|
}
|
|
2663
2699
|
|
|
2700
|
+
/* IMP-006: Badge info variant */
|
|
2701
|
+
.ds-badge--info {
|
|
2702
|
+
background: var(--status-info-surface-l1);
|
|
2703
|
+
color: var(--status-info-default);
|
|
2704
|
+
}
|
|
2705
|
+
|
|
2706
|
+
.ds-badge--neutral {
|
|
2707
|
+
background: var(--bg-overlay-l2);
|
|
2708
|
+
color: var(--text-tertiary);
|
|
2709
|
+
}
|
|
2710
|
+
|
|
2664
2711
|
/* ── Tooltip ──────────────────────────────────────────────── */
|
|
2665
2712
|
[data-tooltip] {
|
|
2666
2713
|
position: relative;
|
|
@@ -3359,7 +3406,7 @@
|
|
|
3359
3406
|
justify-content: center;
|
|
3360
3407
|
}
|
|
3361
3408
|
|
|
3362
|
-
.ds-image-list__item.is-selected::after
|
|
3409
|
+
.ds-image-list__item.is-selected::after {
|
|
3363
3410
|
content: '';
|
|
3364
3411
|
width: 6px;
|
|
3365
3412
|
height: 3px;
|
|
@@ -4162,4 +4209,114 @@
|
|
|
4162
4209
|
|
|
4163
4210
|
.ds-virtual-list--horizontal .ds-virtual-list__item:last-child {
|
|
4164
4211
|
border-right: none;
|
|
4212
|
+
}
|
|
4213
|
+
|
|
4214
|
+
/* ── Tree (IMP-008) ──────────────────────────────────────── */
|
|
4215
|
+
.ds-tree {
|
|
4216
|
+
list-style: none;
|
|
4217
|
+
padding: 0;
|
|
4218
|
+
margin: 0;
|
|
4219
|
+
font-size: var(--body-sm-font-size, 13px);
|
|
4220
|
+
}
|
|
4221
|
+
|
|
4222
|
+
.ds-tree ul {
|
|
4223
|
+
list-style: none;
|
|
4224
|
+
padding: 0;
|
|
4225
|
+
margin: 0;
|
|
4226
|
+
}
|
|
4227
|
+
|
|
4228
|
+
.ds-tree__item {
|
|
4229
|
+
display: flex;
|
|
4230
|
+
align-items: center;
|
|
4231
|
+
gap: var(--spacer-6);
|
|
4232
|
+
padding: var(--spacer-4) var(--spacer-8);
|
|
4233
|
+
border-radius: var(--radius-4);
|
|
4234
|
+
cursor: default;
|
|
4235
|
+
transition: background-color 0.12s ease;
|
|
4236
|
+
user-select: none;
|
|
4237
|
+
}
|
|
4238
|
+
|
|
4239
|
+
.ds-tree__item:hover {
|
|
4240
|
+
background-color: var(--bg-overlay-l1);
|
|
4241
|
+
}
|
|
4242
|
+
|
|
4243
|
+
.ds-tree__item.is-selected {
|
|
4244
|
+
background-color: var(--bg-brand-popup);
|
|
4245
|
+
}
|
|
4246
|
+
|
|
4247
|
+
.ds-tree__toggle {
|
|
4248
|
+
display: inline-flex;
|
|
4249
|
+
align-items: center;
|
|
4250
|
+
justify-content: center;
|
|
4251
|
+
width: 16px;
|
|
4252
|
+
height: 16px;
|
|
4253
|
+
flex-shrink: 0;
|
|
4254
|
+
cursor: pointer;
|
|
4255
|
+
color: var(--icon-secondary);
|
|
4256
|
+
transition: transform 0.15s ease;
|
|
4257
|
+
background: none;
|
|
4258
|
+
border: none;
|
|
4259
|
+
padding: 0;
|
|
4260
|
+
}
|
|
4261
|
+
|
|
4262
|
+
.ds-tree__toggle::before {
|
|
4263
|
+
content: '';
|
|
4264
|
+
display: block;
|
|
4265
|
+
width: 0;
|
|
4266
|
+
height: 0;
|
|
4267
|
+
border-left: 5px solid currentColor;
|
|
4268
|
+
border-top: 3.5px solid transparent;
|
|
4269
|
+
border-bottom: 3.5px solid transparent;
|
|
4270
|
+
}
|
|
4271
|
+
|
|
4272
|
+
.ds-tree__toggle.is-open {
|
|
4273
|
+
transform: rotate(90deg);
|
|
4274
|
+
}
|
|
4275
|
+
|
|
4276
|
+
.ds-tree__toggle.is-leaf {
|
|
4277
|
+
visibility: hidden;
|
|
4278
|
+
}
|
|
4279
|
+
|
|
4280
|
+
.ds-tree__checkbox {
|
|
4281
|
+
width: 14px;
|
|
4282
|
+
height: 14px;
|
|
4283
|
+
flex-shrink: 0;
|
|
4284
|
+
accent-color: var(--bg-brand);
|
|
4285
|
+
cursor: pointer;
|
|
4286
|
+
}
|
|
4287
|
+
|
|
4288
|
+
.ds-tree__icon {
|
|
4289
|
+
width: 16px;
|
|
4290
|
+
height: 16px;
|
|
4291
|
+
flex-shrink: 0;
|
|
4292
|
+
color: var(--icon-secondary);
|
|
4293
|
+
}
|
|
4294
|
+
|
|
4295
|
+
.ds-tree__label {
|
|
4296
|
+
flex: 1;
|
|
4297
|
+
color: var(--text-default);
|
|
4298
|
+
overflow: hidden;
|
|
4299
|
+
text-overflow: ellipsis;
|
|
4300
|
+
white-space: nowrap;
|
|
4301
|
+
}
|
|
4302
|
+
|
|
4303
|
+
.ds-tree__badge {
|
|
4304
|
+
font-size: var(--body-xs-font-size, 10px);
|
|
4305
|
+
color: var(--text-tertiary);
|
|
4306
|
+
margin-left: auto;
|
|
4307
|
+
}
|
|
4308
|
+
|
|
4309
|
+
.ds-tree__children {
|
|
4310
|
+
padding-left: var(--spacer-20);
|
|
4311
|
+
border-left: 1px solid var(--border-neutral-l1);
|
|
4312
|
+
margin-left: 7px;
|
|
4313
|
+
}
|
|
4314
|
+
|
|
4315
|
+
/* Tree line guides */
|
|
4316
|
+
.ds-tree--lined .ds-tree__children {
|
|
4317
|
+
border-left-color: var(--border-neutral-l1);
|
|
4318
|
+
}
|
|
4319
|
+
|
|
4320
|
+
.ds-tree--compact .ds-tree__item {
|
|
4321
|
+
padding: var(--spacer-2) var(--spacer-8);
|
|
4165
4322
|
}
|
package/dist/css/components.css
CHANGED
|
@@ -540,6 +540,45 @@
|
|
|
540
540
|
.ds-input.is-error { border-color: var(--bg-error-default); }
|
|
541
541
|
.ds-input.is-success { border-color: var(--bg-success-default); }
|
|
542
542
|
|
|
543
|
+
/* BUG-003 fix: ensure <select class="ds-input"> matches <input> height/padding */
|
|
544
|
+
select.ds-input,
|
|
545
|
+
.ds-input select {
|
|
546
|
+
height: 36px;
|
|
547
|
+
padding: 0 var(--spacer-24) 0 var(--spacer-12);
|
|
548
|
+
appearance: none;
|
|
549
|
+
-webkit-appearance: none;
|
|
550
|
+
-moz-appearance: none;
|
|
551
|
+
background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%239599A6' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><polyline points='6 9 12 15 18 9'></polyline></svg>");
|
|
552
|
+
background-repeat: no-repeat;
|
|
553
|
+
background-position: right 8px center;
|
|
554
|
+
background-size: 12px;
|
|
555
|
+
cursor: pointer;
|
|
556
|
+
font: inherit;
|
|
557
|
+
color: var(--text-default);
|
|
558
|
+
background-color: var(--bg-overlay-l1);
|
|
559
|
+
line-height: 36px;
|
|
560
|
+
font-size: 14px;
|
|
561
|
+
}
|
|
562
|
+
select.ds-input::-ms-expand { display: none; }
|
|
563
|
+
|
|
564
|
+
/* Fix dropdown options background color - Note: limited browser support */
|
|
565
|
+
select.ds-input option,
|
|
566
|
+
.ds-input select option {
|
|
567
|
+
background-color: var(--bg-base-secondary);
|
|
568
|
+
color: var(--text-default);
|
|
569
|
+
padding: 10px 12px;
|
|
570
|
+
line-height: 1.8;
|
|
571
|
+
min-height: 36px;
|
|
572
|
+
}
|
|
573
|
+
|
|
574
|
+
select.ds-input optgroup,
|
|
575
|
+
.ds-input select optgroup {
|
|
576
|
+
background-color: var(--bg-base-secondary);
|
|
577
|
+
color: var(--text-default);
|
|
578
|
+
padding: 8px 12px;
|
|
579
|
+
line-height: 1.6;
|
|
580
|
+
}
|
|
581
|
+
|
|
543
582
|
.ds-input__status-icon {
|
|
544
583
|
position: absolute;
|
|
545
584
|
right: 12px;
|
|
@@ -980,6 +1019,18 @@
|
|
|
980
1019
|
}
|
|
981
1020
|
.ds-table__pagination { display: flex; align-items: center; gap: var(--spacer-8); }
|
|
982
1021
|
|
|
1022
|
+
/* Table variants (IMP-001) */
|
|
1023
|
+
.ds-table--striped tbody tr:nth-child(even) { background: var(--bg-base-secondary); }
|
|
1024
|
+
.ds-table--hover tbody tr:hover { background: var(--bg-overlay-l1); cursor: default; }
|
|
1025
|
+
.ds-table--compact th,
|
|
1026
|
+
.ds-table--compact td { padding: var(--spacer-6) var(--spacer-8); font-size: var(--body-xs-font-size); }
|
|
1027
|
+
|
|
1028
|
+
/* Table cell utilities */
|
|
1029
|
+
.ds-td--strong { font-weight: 500; color: var(--text-default); }
|
|
1030
|
+
.ds-td--actions { display: flex; gap: var(--spacer-4); align-items: center; }
|
|
1031
|
+
.ds-td--mono { font-family: var(--code-editor-font-family); font-variant-numeric: tabular-nums; }
|
|
1032
|
+
.ds-td--truncate { max-width: 200px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
|
|
1033
|
+
|
|
983
1034
|
/* ── Tabs ──────────────────────────────────────────────────── */
|
|
984
1035
|
/* ===== Tabs ===== */
|
|
985
1036
|
.ds-tabs { display: flex; gap: var(--spacer-24); border-bottom: 1px solid var(--border-neutral-l1); }
|
|
@@ -1311,6 +1362,45 @@
|
|
|
1311
1362
|
margin-top: var(--spacer-16);
|
|
1312
1363
|
}
|
|
1313
1364
|
|
|
1365
|
+
/* IMP-004: Flat aliases — use these without BEM __ nesting */
|
|
1366
|
+
.ds-form-group {
|
|
1367
|
+
display: flex;
|
|
1368
|
+
flex-direction: column;
|
|
1369
|
+
gap: var(--spacer-6);
|
|
1370
|
+
margin-bottom: var(--spacer-12);
|
|
1371
|
+
}
|
|
1372
|
+
|
|
1373
|
+
.ds-form-label {
|
|
1374
|
+
display: block;
|
|
1375
|
+
font-size: var(--body-sm-font-size);
|
|
1376
|
+
font-weight: var(--font-weight-medium);
|
|
1377
|
+
color: var(--text-default);
|
|
1378
|
+
margin-bottom: var(--spacer-4);
|
|
1379
|
+
}
|
|
1380
|
+
|
|
1381
|
+
.ds-form-row {
|
|
1382
|
+
display: grid;
|
|
1383
|
+
grid-template-columns: repeat(2, 1fr);
|
|
1384
|
+
gap: var(--spacer-12);
|
|
1385
|
+
}
|
|
1386
|
+
|
|
1387
|
+
.ds-form-row--3 {
|
|
1388
|
+
grid-template-columns: repeat(3, 1fr);
|
|
1389
|
+
}
|
|
1390
|
+
|
|
1391
|
+
.ds-form-actions {
|
|
1392
|
+
display: flex;
|
|
1393
|
+
justify-content: flex-end;
|
|
1394
|
+
gap: var(--spacer-8);
|
|
1395
|
+
margin-top: var(--spacer-16);
|
|
1396
|
+
}
|
|
1397
|
+
|
|
1398
|
+
.ds-form-hint {
|
|
1399
|
+
font-size: var(--body-xs-font-size);
|
|
1400
|
+
color: var(--text-tertiary);
|
|
1401
|
+
margin-top: var(--spacer-2);
|
|
1402
|
+
}
|
|
1403
|
+
|
|
1314
1404
|
.ds-radio-group {
|
|
1315
1405
|
display: flex;
|
|
1316
1406
|
gap: var(--spacer-16);
|
|
@@ -1391,12 +1481,14 @@
|
|
|
1391
1481
|
display: flex;
|
|
1392
1482
|
align-items: center;
|
|
1393
1483
|
width: 100%;
|
|
1394
|
-
padding:
|
|
1484
|
+
padding: 12px var(--spacer-12);
|
|
1485
|
+
min-height: 40px;
|
|
1395
1486
|
background: none;
|
|
1396
1487
|
border: none;
|
|
1397
1488
|
border-radius: var(--radius-2);
|
|
1398
1489
|
color: var(--text-default);
|
|
1399
1490
|
font-size: var(--body-sm-font-size);
|
|
1491
|
+
line-height: 1.6;
|
|
1400
1492
|
cursor: pointer;
|
|
1401
1493
|
text-align: left;
|
|
1402
1494
|
}
|
package/dist/css/kupola.css
CHANGED
|
@@ -1,12 +1,13 @@
|
|
|
1
|
-
@import '
|
|
2
|
-
@import '
|
|
3
|
-
@import '
|
|
4
|
-
@import '
|
|
5
|
-
@import '
|
|
6
|
-
@import '
|
|
7
|
-
@import '
|
|
8
|
-
@import '
|
|
9
|
-
@import '
|
|
10
|
-
@import '
|
|
11
|
-
@import '
|
|
12
|
-
@import '
|
|
1
|
+
@import url('colors-and-type.css');
|
|
2
|
+
@import url('theme-light.css');
|
|
3
|
+
@import url('theme-dark.css');
|
|
4
|
+
@import url('brand-themes.css');
|
|
5
|
+
@import url('scaffold.css');
|
|
6
|
+
@import url('components.css');
|
|
7
|
+
@import url('components-ext.css');
|
|
8
|
+
@import url('states.css');
|
|
9
|
+
@import url('utilities.css');
|
|
10
|
+
@import url('responsive.css');
|
|
11
|
+
@import url('accessibility.css');
|
|
12
|
+
@import url('animations.css');
|
|
13
|
+
@import url('table.css');
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
/* ================================================================
|
|
2
|
+
KupolaTable Styles
|
|
3
|
+
================================================================ */
|
|
4
|
+
|
|
5
|
+
.kupola-table-wrapper { width: 100%; }
|
|
6
|
+
.kupola-table-container { overflow-x: auto; }
|
|
7
|
+
.kupola-table { width: 100%; border-collapse: collapse; font-size: 14px; }
|
|
8
|
+
.kupola-table th, .kupola-table td { padding: 12px 16px; text-align: left; border-bottom: 1px solid #e8e8e8; }
|
|
9
|
+
.kupola-table th { background: #fafafa; font-weight: 600; color: #333; white-space: nowrap; }
|
|
10
|
+
.kupola-table-striped tbody tr:nth-child(even) { background: #fafafa; }
|
|
11
|
+
.kupola-table-hover tbody tr:hover { background: #f0f7ff; }
|
|
12
|
+
.kupola-table-bordered { border: 1px solid #e8e8e8; }
|
|
13
|
+
.kupola-table-bordered th, .kupola-table-bordered td { border: 1px solid #e8e8e8; }
|
|
14
|
+
.kupola-table-compact th, .kupola-table-compact td { padding: 8px 12px; }
|
|
15
|
+
.kupola-table-sortable { cursor: pointer; user-select: none; position: relative; }
|
|
16
|
+
.kupola-table-sortable:hover { background: #f0f0f0; }
|
|
17
|
+
.kupola-table-sort-icon { font-size: 12px; opacity: 0.5; margin-left: 4px; }
|
|
18
|
+
.kupola-table-sort-asc .kupola-table-sort-icon,
|
|
19
|
+
.kupola-table-sort-desc .kupola-table-sort-icon { opacity: 1; color: #1890ff; }
|
|
20
|
+
.kupola-table-empty, .kupola-table-loading { text-align: center; padding: 40px 16px !important; color: #999; }
|
|
21
|
+
.kupola-table-toolbar { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; flex-wrap: wrap; gap: 8px; }
|
|
22
|
+
.kupola-table-toolbar-right { display: flex; align-items: center; gap: 8px; }
|
|
23
|
+
.kupola-table-filter-input { padding: 6px 12px; border: 1px solid #d9d9d9; border-radius: 4px; font-size: 14px; width: 240px; }
|
|
24
|
+
.kupola-table-filter-input:focus { outline: none; border-color: #1890ff; box-shadow: 0 0 0 2px rgba(24,144,255,0.1); }
|
|
25
|
+
.kupola-table-info { color: #999; font-size: 13px; }
|
|
26
|
+
.kupola-table-selection-info { color: #1890ff; font-size: 13px; font-weight: 500; }
|
|
27
|
+
.kupola-table-col-selection { width: 40px; text-align: center; }
|
|
28
|
+
.kupola-table-col-expand { width: 40px; text-align: center; }
|
|
29
|
+
.kupola-table-expand-btn { background: none; border: none; cursor: pointer; font-size: 12px; padding: 2px 6px; color: #666; }
|
|
30
|
+
.kupola-table-expand-btn:hover { color: #1890ff; }
|
|
31
|
+
.kupola-table-expand-row td { background: #fafafa; padding: 16px; }
|
|
32
|
+
.kupola-table-row-selected { background: #e6f7ff !important; }
|
|
33
|
+
.kupola-table-row-selected:hover { background: #bae7ff !important; }
|
|
34
|
+
|
|
35
|
+
/* Resize */
|
|
36
|
+
.kupola-table-resize-handle { position: absolute; right: 0; top: 0; bottom: 0; width: 6px; cursor: col-resize; background: transparent; }
|
|
37
|
+
.kupola-table-resize-handle:hover { background: #1890ff; opacity: 0.3; }
|
|
38
|
+
|
|
39
|
+
/* Drag */
|
|
40
|
+
.kupola-table-draggable { transition: opacity 0.2s; }
|
|
41
|
+
.kupola-table-dragging { opacity: 0.4; }
|
|
42
|
+
.kupola-table-drag-over { border-top: 2px solid #1890ff !important; }
|
|
43
|
+
|
|
44
|
+
/* Edit */
|
|
45
|
+
.kupola-table-editable-cell { cursor: text; }
|
|
46
|
+
.kupola-table-editable-cell:hover { background: #e6f7ff; }
|
|
47
|
+
.kupola-table-edit-cell { display: flex; gap: 4px; align-items: center; }
|
|
48
|
+
.kupola-table-edit-input { flex: 1; padding: 2px 6px; font-size: 13px; }
|
|
49
|
+
.kupola-table-edit-actions { display: flex; gap: 2px; }
|
|
50
|
+
.kupola-table-edit-save, .kupola-table-edit-cancel { background: none; border: 1px solid #d9d9d9; border-radius: 3px; cursor: pointer; padding: 2px 6px; font-size: 12px; }
|
|
51
|
+
.kupola-table-edit-save { color: #52c41a; border-color: #52c41a; }
|
|
52
|
+
.kupola-table-edit-cancel { color: #ff4d4f; border-color: #ff4d4f; }
|
|
53
|
+
.kupola-table-edit-save:hover { background: #f6ffed; }
|
|
54
|
+
.kupola-table-edit-cancel:hover { background: #fff2f0; }
|
|
55
|
+
|
|
56
|
+
/* Tree */
|
|
57
|
+
.kupola-table-tree-indent { display: inline-block; }
|
|
58
|
+
.kupola-table-tree-toggle { background: none; border: none; cursor: pointer; font-size: 10px; padding: 0 4px; color: #666; }
|
|
59
|
+
.kupola-table-tree-toggle:hover { color: #1890ff; }
|
|
60
|
+
.kupola-table-tree-toggle-placeholder { display: inline-block; width: 18px; }
|
|
61
|
+
|
|
62
|
+
/* Virtual */
|
|
63
|
+
.kupola-table-virtual-wrapper .kupola-table-container { overflow-y: auto; }
|
|
64
|
+
|
|
65
|
+
/* Pagination */
|
|
66
|
+
.kupola-table-pagination { display: flex; justify-content: flex-end; align-items: center; gap: 12px; margin-top: 16px; padding: 8px 0; }
|
|
67
|
+
.kupola-table-pages { display: flex; gap: 4px; align-items: center; }
|
|
68
|
+
.kupola-table-page-btn { min-width: 32px; height: 32px; border: 1px solid #d9d9d9; border-radius: 4px; background: #fff; cursor: pointer; font-size: 14px; display: flex; align-items: center; justify-content: center; }
|
|
69
|
+
.kupola-table-page-btn:hover:not(:disabled):not(.active) { border-color: #1890ff; color: #1890ff; }
|
|
70
|
+
.kupola-table-page-btn.active { background: #1890ff; color: #fff; border-color: #1890ff; }
|
|
71
|
+
.kupola-table-page-btn:disabled { opacity: 0.4; cursor: not-allowed; }
|
|
72
|
+
.kupola-table-page-ellipsis { padding: 0 4px; color: #999; }
|
|
73
|
+
.kupola-table-page-size { padding: 4px 8px; border: 1px solid #d9d9d9; border-radius: 4px; font-size: 13px; }
|
|
74
|
+
.kupola-table-page-info { color: #999; font-size: 13px; }
|
package/dist/css/theme-dark.css
CHANGED
|
@@ -18,11 +18,11 @@
|
|
|
18
18
|
--text-default: #D1D3DB;
|
|
19
19
|
--text-default-hover: #FFFFFF;
|
|
20
20
|
--text-default-active: #FFFFFF;
|
|
21
|
-
--text-secondary: #
|
|
21
|
+
--text-secondary: #A0A5B2;
|
|
22
22
|
--text-secondary-hover: #D1D3DB;
|
|
23
23
|
--text-secondary-active: #D1D3DB;
|
|
24
|
-
--text-tertiary: #
|
|
25
|
-
--text-disabled: #
|
|
24
|
+
--text-tertiary: #7D8493;
|
|
25
|
+
--text-disabled: #7D8493;
|
|
26
26
|
--text-onbrand: #FFFFFF;
|
|
27
27
|
--text-onaccent: #FFFFFF;
|
|
28
28
|
|
|
@@ -32,8 +32,8 @@
|
|
|
32
32
|
--icon-secondary: #9599A6;
|
|
33
33
|
--icon-secondary-hover: #D1D3DB;
|
|
34
34
|
--icon-secondary-active: #D1D3DB;
|
|
35
|
-
--icon-tertiary: #
|
|
36
|
-
--icon-disabled: #
|
|
35
|
+
--icon-tertiary: #7D8493;
|
|
36
|
+
--icon-disabled: #7D8493;
|
|
37
37
|
--icon-onbrand: #FFFFFF;
|
|
38
38
|
--icon-onaccent: #FFFFFF;
|
|
39
39
|
|
package/dist/css/utilities.css
CHANGED
|
@@ -168,4 +168,162 @@
|
|
|
168
168
|
@keyframes pulse {
|
|
169
169
|
0%, 100% { opacity: 1; }
|
|
170
170
|
50% { opacity: 0.5; }
|
|
171
|
-
}
|
|
171
|
+
}
|
|
172
|
+
|
|
173
|
+
/* ===== ds- prefixed utility classes (IMP-002) =====
|
|
174
|
+
* Canonical ds-* aliases for all utility classes.
|
|
175
|
+
* Both prefixed and unprefixed versions are supported.
|
|
176
|
+
*/
|
|
177
|
+
|
|
178
|
+
/* Flexbox */
|
|
179
|
+
.ds-flex { display: flex; }
|
|
180
|
+
.ds-flex-col { display: flex; flex-direction: column; }
|
|
181
|
+
.ds-flex--col { flex-direction: column; }
|
|
182
|
+
.ds-flex--wrap { flex-wrap: wrap; }
|
|
183
|
+
.ds-flex-1 { flex: 1; }
|
|
184
|
+
.ds-flex-none { flex: none; }
|
|
185
|
+
.ds-items-center { align-items: center; }
|
|
186
|
+
.ds-items-start { align-items: flex-start; }
|
|
187
|
+
.ds-items-end { align-items: flex-end; }
|
|
188
|
+
.ds-items-stretch { align-items: stretch; }
|
|
189
|
+
.ds-justify-center { justify-content: center; }
|
|
190
|
+
.ds-justify-between { justify-content: space-between; }
|
|
191
|
+
.ds-justify-end { justify-content: flex-end; }
|
|
192
|
+
.ds-justify-start { justify-content: flex-start; }
|
|
193
|
+
|
|
194
|
+
/* Gap */
|
|
195
|
+
.ds-gap-2 { gap: var(--spacer-2); }
|
|
196
|
+
.ds-gap-4 { gap: var(--spacer-4); }
|
|
197
|
+
.ds-gap-6 { gap: var(--spacer-6); }
|
|
198
|
+
.ds-gap-8 { gap: var(--spacer-8); }
|
|
199
|
+
.ds-gap-12 { gap: var(--spacer-12); }
|
|
200
|
+
.ds-gap-16 { gap: var(--spacer-16); }
|
|
201
|
+
.ds-gap-24 { gap: var(--spacer-24); }
|
|
202
|
+
.ds-gap-32 { gap: var(--spacer-32); }
|
|
203
|
+
|
|
204
|
+
/* Grid */
|
|
205
|
+
.ds-grid { display: grid; }
|
|
206
|
+
.ds-grid--2 { grid-template-columns: repeat(2, 1fr); }
|
|
207
|
+
.ds-grid--3 { grid-template-columns: repeat(3, 1fr); }
|
|
208
|
+
.ds-grid--4 { grid-template-columns: repeat(4, 1fr); }
|
|
209
|
+
.ds-grid--5 { grid-template-columns: repeat(5, 1fr); }
|
|
210
|
+
.ds-grid--6 { grid-template-columns: repeat(6, 1fr); }
|
|
211
|
+
.ds-grid-cols-2 { grid-template-columns: repeat(2, 1fr); }
|
|
212
|
+
.ds-grid-cols-3 { grid-template-columns: repeat(3, 1fr); }
|
|
213
|
+
.ds-grid-cols-4 { grid-template-columns: repeat(4, 1fr); }
|
|
214
|
+
|
|
215
|
+
/* Display */
|
|
216
|
+
.ds-block { display: block; }
|
|
217
|
+
.ds-inline-block { display: inline-block; }
|
|
218
|
+
.ds-inline { display: inline; }
|
|
219
|
+
.ds-hidden { display: none; }
|
|
220
|
+
|
|
221
|
+
/* Text */
|
|
222
|
+
.ds-text-left { text-align: left; }
|
|
223
|
+
.ds-text-center { text-align: center; }
|
|
224
|
+
.ds-text-right { text-align: right; }
|
|
225
|
+
.ds-text-xs { font-size: var(--body-xs-font-size); }
|
|
226
|
+
.ds-text-sm { font-size: var(--body-sm-font-size); }
|
|
227
|
+
.ds-text-md { font-size: var(--body-md-font-size); }
|
|
228
|
+
.ds-text-base { font-size: var(--body-base-font-size); }
|
|
229
|
+
.ds-font-medium { font-weight: var(--font-weight-medium); }
|
|
230
|
+
.ds-font-strong { font-weight: var(--font-weight-strong); }
|
|
231
|
+
.ds-text-default { color: var(--text-default); }
|
|
232
|
+
.ds-text-secondary { color: var(--text-secondary); }
|
|
233
|
+
.ds-text-tertiary { color: var(--text-tertiary); }
|
|
234
|
+
.ds-text-brand { color: var(--text-brand); }
|
|
235
|
+
.ds-text-success { color: var(--status-success-default); }
|
|
236
|
+
.ds-text-warning { color: var(--status-warning-default); }
|
|
237
|
+
.ds-text-error { color: var(--status-error-default); }
|
|
238
|
+
|
|
239
|
+
/* Width */
|
|
240
|
+
.ds-w-full { width: 100%; }
|
|
241
|
+
.ds-w-auto { width: auto; }
|
|
242
|
+
.ds-max-w-md { max-width: 480px; }
|
|
243
|
+
.ds-max-w-lg { max-width: 640px; }
|
|
244
|
+
.ds-max-w-xl { max-width: 960px; }
|
|
245
|
+
|
|
246
|
+
/* Spacing (ds- prefixed margin/padding) */
|
|
247
|
+
.ds-m-0 { margin: var(--spacer-0); }
|
|
248
|
+
.ds-m-4 { margin: var(--spacer-4); }
|
|
249
|
+
.ds-m-8 { margin: var(--spacer-8); }
|
|
250
|
+
.ds-m-12 { margin: var(--spacer-12); }
|
|
251
|
+
.ds-m-16 { margin: var(--spacer-16); }
|
|
252
|
+
.ds-m-auto { margin: auto; }
|
|
253
|
+
.ds-mt-0 { margin-top: var(--spacer-0); }
|
|
254
|
+
.ds-mt-4 { margin-top: var(--spacer-4); }
|
|
255
|
+
.ds-mt-8 { margin-top: var(--spacer-8); }
|
|
256
|
+
.ds-mt-12 { margin-top: var(--spacer-12); }
|
|
257
|
+
.ds-mt-16 { margin-top: var(--spacer-16); }
|
|
258
|
+
.ds-mb-0 { margin-bottom: var(--spacer-0); }
|
|
259
|
+
.ds-mb-4 { margin-bottom: var(--spacer-4); }
|
|
260
|
+
.ds-mb-8 { margin-bottom: var(--spacer-8); }
|
|
261
|
+
.ds-mb-12 { margin-bottom: var(--spacer-12); }
|
|
262
|
+
.ds-mb-16 { margin-bottom: var(--spacer-16); }
|
|
263
|
+
.ds-p-0 { padding: var(--spacer-0); }
|
|
264
|
+
.ds-p-4 { padding: var(--spacer-4); }
|
|
265
|
+
.ds-p-8 { padding: var(--spacer-8); }
|
|
266
|
+
.ds-p-12 { padding: var(--spacer-12); }
|
|
267
|
+
.ds-p-16 { padding: var(--spacer-16); }
|
|
268
|
+
.ds-p-24 { padding: var(--spacer-24); }
|
|
269
|
+
.ds-p-32 { padding: var(--spacer-32); }
|
|
270
|
+
.ds-mb-24 { margin-bottom: var(--spacer-24); }
|
|
271
|
+
.ds-mb-32 { margin-bottom: var(--spacer-32); }
|
|
272
|
+
.ds-mt-24 { margin-top: var(--spacer-24); }
|
|
273
|
+
.ds-mt-16 { margin-top: var(--spacer-16); }
|
|
274
|
+
|
|
275
|
+
/* Width extras */
|
|
276
|
+
.ds-w-200 { width: 200px; }
|
|
277
|
+
.ds-w-400 { width: 400px; }
|
|
278
|
+
.ds-w-440 { width: 440px; }
|
|
279
|
+
.ds-w-480 { width: 480px; }
|
|
280
|
+
.ds-w-500 { width: 500px; }
|
|
281
|
+
.ds-w-520 { width: 520px; }
|
|
282
|
+
.ds-w-560 { width: 560px; }
|
|
283
|
+
.ds-w-640 { width: 640px; }
|
|
284
|
+
|
|
285
|
+
/* Overflow extras */
|
|
286
|
+
.ds-overflow-x-auto { overflow-x: auto; }
|
|
287
|
+
.ds-overflow-y-auto { overflow-y: auto; }
|
|
288
|
+
|
|
289
|
+
/* Max height */
|
|
290
|
+
.ds-max-h-80vh { max-height: 80vh; }
|
|
291
|
+
.ds-max-h-85vh { max-height: 85vh; }
|
|
292
|
+
|
|
293
|
+
/* Rounded */
|
|
294
|
+
.ds-rounded-2 { border-radius: var(--radius-2); }
|
|
295
|
+
.ds-rounded-4 { border-radius: var(--radius-4); }
|
|
296
|
+
.ds-rounded-6 { border-radius: var(--radius-6); }
|
|
297
|
+
.ds-rounded-8 { border-radius: var(--radius-8); }
|
|
298
|
+
.ds-rounded-full { border-radius: var(--radius-full); }
|
|
299
|
+
|
|
300
|
+
/* Position */
|
|
301
|
+
.ds-relative { position: relative; }
|
|
302
|
+
.ds-absolute { position: absolute; }
|
|
303
|
+
.ds-fixed { position: fixed; }
|
|
304
|
+
.ds-sticky { position: sticky; }
|
|
305
|
+
|
|
306
|
+
/* Overflow */
|
|
307
|
+
.ds-overflow-hidden { overflow: hidden; }
|
|
308
|
+
.ds-overflow-auto { overflow: auto; }
|
|
309
|
+
|
|
310
|
+
/* Cursor */
|
|
311
|
+
.ds-cursor-pointer { cursor: pointer; }
|
|
312
|
+
.ds-cursor-not-allowed { cursor: not-allowed; }
|
|
313
|
+
|
|
314
|
+
/* Inset (for modals) */
|
|
315
|
+
.ds-inset-0 { inset: 0; }
|
|
316
|
+
|
|
317
|
+
/* Text heading */
|
|
318
|
+
.ds-text-heading-sm { font-size: var(--heading-sm-font-size); }
|
|
319
|
+
.ds-text-heading-md { font-size: var(--heading-md-font-size); }
|
|
320
|
+
|
|
321
|
+
/* Text semantic colors */
|
|
322
|
+
.ds-text-info { color: var(--status-info-default); }
|
|
323
|
+
|
|
324
|
+
/* Background */
|
|
325
|
+
.ds-bg-overlay { background: rgba(0,0,0,.5); }
|
|
326
|
+
.ds-bg-base { background: var(--bg-base-secondary); }
|
|
327
|
+
|
|
328
|
+
/* Z-index */
|
|
329
|
+
.ds-z-modal { z-index: 1000; }
|