@kb-labs/studio-ui-kit 2.94.0 → 2.98.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 +5 -4
- package/dist/index.css +45 -1
- package/dist/index.css.map +1 -1
- package/dist/index.d.ts +19 -47
- package/dist/index.js +155 -122
- package/dist/index.js.map +1 -1
- package/package.json +6 -5
package/README.md
CHANGED
|
@@ -46,13 +46,13 @@ function MyComponent() {
|
|
|
46
46
|
|
|
47
47
|
## 📊 Component Stats
|
|
48
48
|
|
|
49
|
-
- **Total Components:**
|
|
50
|
-
- **With Tests:** 4/
|
|
49
|
+
- **Total Components:** 52
|
|
50
|
+
- **With Tests:** 4/52 (8%)
|
|
51
51
|
|
|
52
52
|
**By Category:**
|
|
53
53
|
|
|
54
54
|
- Primitives: 4
|
|
55
|
-
- Core:
|
|
55
|
+
- Core: 9
|
|
56
56
|
- Layout: 4
|
|
57
57
|
- Form: 10
|
|
58
58
|
- Navigation: 7
|
|
@@ -84,6 +84,7 @@ Essential UI components
|
|
|
84
84
|
| **UIBadge** | Badge component - Status indicator with semantic colors | ❌ |
|
|
85
85
|
| **UIButton** | UIButton component - Action button with semantic variants | ✅ |
|
|
86
86
|
| **UICard** | UICard component - Card container with header/footer | ❌ |
|
|
87
|
+
| **UICopyButton** | UICopyButton — one-click copy with built-in visual feedback. | ❌ |
|
|
87
88
|
| **UIIcon** | UIIcon component - Icon wrapper with proper theming | ❌ |
|
|
88
89
|
| **UIShimmerText** | UIShimmerText - Animated gradient shimmer on text | ❌ |
|
|
89
90
|
| **UITag** | UITag component - Label/category tag with semantic colors | ❌ |
|
|
@@ -175,7 +176,7 @@ Content display components
|
|
|
175
176
|
|-----------|-------------|-------|
|
|
176
177
|
| **UIDiffViewer** | UIDiffViewer | ❌ |
|
|
177
178
|
| **UIJsonViewer** | UIJsonViewer component - JSON content viewer | ❌ |
|
|
178
|
-
| **UIMarkdownViewer** | UIMarkdownViewer
|
|
179
|
+
| **UIMarkdownViewer** | UIMarkdownViewer | ❌ |
|
|
179
180
|
|
|
180
181
|
<!-- AUTO-GENERATED:END -->
|
|
181
182
|
|
package/dist/index.css
CHANGED
|
@@ -32,6 +32,16 @@
|
|
|
32
32
|
vertical-align: middle;
|
|
33
33
|
display: block;
|
|
34
34
|
}
|
|
35
|
+
.uiButton {
|
|
36
|
+
transition:
|
|
37
|
+
transform 100ms ease,
|
|
38
|
+
box-shadow 150ms ease,
|
|
39
|
+
opacity 100ms ease;
|
|
40
|
+
}
|
|
41
|
+
.uiButton:active:not(:disabled):not(.ant-btn-disabled) {
|
|
42
|
+
transform: scale(0.96);
|
|
43
|
+
transition: transform 60ms ease;
|
|
44
|
+
}
|
|
35
45
|
.uiButton.ant-btn-primary {
|
|
36
46
|
transition: transform 150ms ease, box-shadow 150ms ease;
|
|
37
47
|
}
|
|
@@ -40,12 +50,33 @@
|
|
|
40
50
|
box-shadow: 0 4px 12px rgba(12, 102, 255, 0.3);
|
|
41
51
|
}
|
|
42
52
|
.uiButton.ant-btn-primary:active:not(:disabled):not(.ant-btn-disabled) {
|
|
43
|
-
transform:
|
|
53
|
+
transform: scale(0.97);
|
|
54
|
+
box-shadow: none;
|
|
55
|
+
transition: transform 60ms ease;
|
|
56
|
+
}
|
|
57
|
+
.uiButton.ant-btn-default:active:not(:disabled):not(.ant-btn-disabled),
|
|
58
|
+
.uiButton.ant-btn-dashed:active:not(:disabled):not(.ant-btn-disabled) {
|
|
59
|
+
opacity: 0.75;
|
|
60
|
+
}
|
|
61
|
+
.uiButton.ant-btn-text:active:not(:disabled):not(.ant-btn-disabled),
|
|
62
|
+
.uiButton.ant-btn-link:active:not(:disabled):not(.ant-btn-disabled) {
|
|
63
|
+
background: rgba(0, 0, 0, 0.06) !important;
|
|
64
|
+
transform: scale(0.95);
|
|
44
65
|
}
|
|
45
66
|
[dir=rtl] .uiButton .ant-btn-icon {
|
|
46
67
|
transform: scaleX(-1);
|
|
47
68
|
}
|
|
48
69
|
|
|
70
|
+
/* src/core/UITag.module.css */
|
|
71
|
+
.kb-ui-tag {
|
|
72
|
+
transition: opacity 100ms ease, transform 100ms ease;
|
|
73
|
+
}
|
|
74
|
+
.kb-ui-tag:not([disabled]):active {
|
|
75
|
+
opacity: 0.7;
|
|
76
|
+
transform: scale(0.94);
|
|
77
|
+
transition: opacity 50ms ease, transform 50ms ease;
|
|
78
|
+
}
|
|
79
|
+
|
|
49
80
|
/* src/core/UIIcon.module.css */
|
|
50
81
|
.uiIcon {
|
|
51
82
|
display: inline-flex;
|
|
@@ -166,4 +197,17 @@
|
|
|
166
197
|
background-position: -100% 0;
|
|
167
198
|
}
|
|
168
199
|
}
|
|
200
|
+
|
|
201
|
+
/* src/feedback/UISkeleton.module.css */
|
|
202
|
+
@keyframes skeletonLoading {
|
|
203
|
+
0% {
|
|
204
|
+
background-position: 100% 50%;
|
|
205
|
+
}
|
|
206
|
+
100% {
|
|
207
|
+
background-position: 0% 50%;
|
|
208
|
+
}
|
|
209
|
+
}
|
|
210
|
+
.skeletonText {
|
|
211
|
+
animation: skeletonLoading 1.4s ease infinite;
|
|
212
|
+
}
|
|
169
213
|
/*# sourceMappingURL=index.css.map */
|
package/dist/index.css.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/core/UIButton.module.css","../src/core/UIIcon.module.css","../src/core/UIShimmerText.module.css"],"sourcesContent":["/**\n * UIButton styles - Proper SVG icon theming\n *\n * This ensures all SVG icons (lucide-react, etc.) inherit colors from CSS variables\n * and work correctly in both light and dark themes.\n */\n\n.uiButton {\n /* Button inherits theme colors from Ant Design tokens */\n}\n\n/*\n * CRITICAL: SVG icon color inheritance\n *\n * Force all SVG icons to inherit button text color automatically\n * Works for lucide-react, heroicons, and any other icon libraries\n */\n.uiButton svg {\n color: inherit !important;\n stroke: currentColor !important;\n fill: currentColor !important;\n}\n\n/*\n * Disabled state - reduce opacity\n */\n.uiButton:disabled svg,\n.uiButton.ant-btn-disabled svg {\n opacity: 0.4;\n}\n\n/*\n * Size variants - ensure SVG scales properly\n */\n.uiButton.ant-btn-sm svg {\n /* Small button icons */\n width: 14px;\n height: 14px;\n}\n\n.uiButton svg {\n /* Default (middle) button icons */\n width: 16px;\n height: 16px;\n}\n\n.uiButton.ant-btn-lg svg {\n /* Large button icons */\n width: 18px;\n height: 18px;\n}\n\n/*\n * Icon positioning within button\n * Ensures proper spacing between icon and text\n */\n.uiButton .ant-btn-icon {\n /* Icon wrapper - CRITICAL: must inherit color for SVG to get correct color */\n color: inherit !important;\n display: inline-flex;\n align-items: center;\n justify-content: center;\n}\n\n.uiButton .ant-btn-icon svg {\n /* SVG inside icon wrapper */\n vertical-align: middle;\n display: block; /* Remove inline spacing */\n}\n\n/*\n * Primary button — subtle lift effect\n */\n.uiButton.ant-btn-primary {\n transition: transform 150ms ease, box-shadow 150ms ease;\n}\n\n.uiButton.ant-btn-primary:hover:not(:disabled):not(.ant-btn-disabled) {\n transform: translateY(-1px);\n box-shadow: 0 4px 12px rgba(12, 102, 255, 0.3);\n}\n\n.uiButton.ant-btn-primary:active:not(:disabled):not(.ant-btn-disabled) {\n transform: translateY(0);\n}\n\n/*\n * RTL (Right-to-Left) support\n */\n[dir='rtl'] .uiButton .ant-btn-icon {\n /* Mirror icon position in RTL */\n transform: scaleX(-1);\n}\n","/**\n * UIIcon styles - Proper SVG and icon font theming\n *\n * Ensures all icons (Ant Design icons, lucide-react, custom SVG)\n * inherit colors from CSS variables and work in both light and dark themes.\n */\n\n.uiIcon {\n display: inline-flex;\n align-items: center;\n justify-content: center;\n vertical-align: middle;\n}\n\n/*\n * SVG icons (lucide-react, custom SVG)\n * Use currentColor to inherit from parent color\n */\n.uiIcon svg {\n color: currentColor;\n stroke: currentColor;\n fill: none; /* Most icon libraries use stroke, not fill */\n display: block; /* Remove inline spacing */\n}\n\n/*\n * Ant Design icons (icon fonts)\n * Already use currentColor by default, but ensure it's explicit\n */\n.uiIcon .anticon {\n color: currentColor;\n}\n\n/*\n * Clickable icons (icon buttons)\n */\n.uiIcon.clickable {\n cursor: pointer;\n transition: opacity 0.2s ease, transform 0.1s ease;\n}\n\n.uiIcon.clickable:hover {\n opacity: 0.8;\n}\n\n.uiIcon.clickable:active {\n transform: scale(0.95);\n}\n\n/*\n * Size variants\n */\n.uiIcon.size-xs {\n font-size: 12px;\n width: 12px;\n height: 12px;\n}\n\n.uiIcon.size-sm {\n font-size: 14px;\n width: 14px;\n height: 14px;\n}\n\n.uiIcon.size-base {\n font-size: 16px;\n width: 16px;\n height: 16px;\n}\n\n.uiIcon.size-lg {\n font-size: 20px;\n width: 20px;\n height: 20px;\n}\n\n.uiIcon.size-xl {\n font-size: 24px;\n width: 24px;\n height: 24px;\n}\n\n.uiIcon.size-2xl {\n font-size: 32px;\n width: 32px;\n height: 32px;\n}\n\n/*\n * Color variants using CSS variables\n */\n.uiIcon.color-primary {\n color: var(--link, #2563EB);\n}\n\n.uiIcon.color-secondary {\n color: var(--text-secondary, #6B7280);\n}\n\n.uiIcon.color-success {\n color: var(--success, #16A34A);\n}\n\n.uiIcon.color-warning {\n color: var(--warning, #F59E0B);\n}\n\n.uiIcon.color-error {\n color: var(--error, #DC2626);\n}\n\n.uiIcon.color-info {\n color: var(--info, #0EA5E9);\n}\n\n.uiIcon.color-inherit {\n color: inherit;\n}\n\n/*\n * Spin animation\n */\n.uiIcon.spin {\n animation: uiIconSpin 1s linear infinite;\n}\n\n@keyframes uiIconSpin {\n from {\n transform: rotate(0deg);\n }\n to {\n transform: rotate(360deg);\n }\n}\n\n/*\n * Disabled state\n */\n.uiIcon.disabled {\n opacity: 0.4;\n cursor: not-allowed;\n pointer-events: none;\n}\n","/**\n * UIShimmerText - Animated gradient shimmer on text\n * Classic \"Cursor / ClickUp\" loading text effect.\n */\n\n.shimmer {\n background: linear-gradient(\n 90deg,\n var(--shimmer-color-1, #888) 0%,\n var(--shimmer-color-2, #888) 25%,\n var(--shimmer-highlight, #fff) 50%,\n var(--shimmer-color-2, #888) 75%,\n var(--shimmer-color-1, #888) 100%\n );\n background-size: 200% 100%;\n -webkit-background-clip: text;\n background-clip: text;\n -webkit-text-fill-color: transparent;\n color: transparent;\n animation: shimmerMove var(--shimmer-duration, 2s) linear infinite;\n display: inline-block;\n}\n\n@keyframes shimmerMove {\n 0% { background-position: 100% 0; }\n 100% { background-position: -100% 0; }\n}\n"],"mappings":";AAOA,CAAC;AAED;AAQA,CAVC,SAUS;AACR,SAAO;AACP,UAAQ;AACR,QAAM;AACR;AAKA,CAnBC,QAmBQ,UAAU;AACnB,CApBC,QAoBQ,CAAC,iBAAiB;AACzB,WAAS;AACX;AAKA,CA3BC,QA2BQ,CAAC,WAAW;AAEnB,SAAO;AACP,UAAQ;AACV;AAEA,CAjCC,SAiCS;AAER,SAAO;AACP,UAAQ;AACV;AAEA,CAvCC,QAuCQ,CAAC,WAAW;AAEnB,SAAO;AACP,UAAQ;AACV;AAMA,CAjDC,SAiDS,CAAC;AAET,SAAO;AACP,WAAS;AACT,eAAa;AACb,mBAAiB;AACnB;AAEA,CAzDC,SAyDS,CARC,aAQa;AAEtB,kBAAgB;AAChB,WAAS;AACX;AAKA,CAlEC,QAkEQ,CAAC;AACR,cAAY,UAAU,MAAM,IAAI,EAAE,WAAW,MAAM;AACrD;AAEA,CAtEC,QAsEQ,CAJC,eAIe,MAAM,KAAK,UAAU,KAAK,CAlDzC;AAmDR,aAAW,WAAW;AACtB,cAAY,EAAE,IAAI,KAAK,KAAK,EAAE,EAAE,GAAG,EAAE,GAAG,EAAE;AAC5C;AAEA,CA3EC,QA2EQ,CATC,eASe,OAAO,KAAK,UAAU,KAAK,CAvD1C;AAwDR,aAAW,WAAW;AACxB;AAKA,CAAC,SAAW,CAlFX,SAkFqB,CAjCX;AAmCT,aAAW,OAAO;AACpB;;;ACrFA,CAAC;AACC,WAAS;AACT,eAAa;AACb,mBAAiB;AACjB,kBAAgB;AAClB;AAMA,CAXC,OAWO;AACN,SAAO;AACP,UAAQ;AACR,QAAM;AAC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AACR,kBAAgB;AAClB;;;ACzIA,CAAC;AACC;AAAA,IAAY;AAAA,MACV,KAAK;AAAA,MACL,IAAI,iBAAiB,EAAE,MAAM,EAAE;AAAA,MAC/B,IAAI,iBAAiB,EAAE,MAAM,GAAG;AAAA,MAChC,IAAI,mBAAmB,EAAE,MAAM,GAAG;AAAA,MAClC,IAAI,iBAAiB,EAAE,MAAM,GAAG;AAAA,MAChC,IAAI,iBAAiB,EAAE,MAAM;AAE/B,mBAAiB,KAAK;AACtB,2BAAyB;AACzB,mBAAiB;AACjB,2BAAyB;AACzB,SAAO;AACP,aAAW,YAAY,IAAI,kBAAkB,EAAE,IAAI,OAAO;AAC1D,WAAS;AACX;AAEA,WAJa;AAKX;AAAO,yBAAqB,KAAK;AAAG;AACpC;AAAO,yBAAqB,MAAM;AAAG;AACvC;","names":[]}
|
|
1
|
+
{"version":3,"sources":["../src/core/UIButton.module.css","../src/core/UITag.module.css","../src/core/UIIcon.module.css","../src/core/UIShimmerText.module.css","../src/feedback/UISkeleton.module.css"],"sourcesContent":["/**\n * UIButton styles - Proper SVG icon theming\n *\n * This ensures all SVG icons (lucide-react, etc.) inherit colors from CSS variables\n * and work correctly in both light and dark themes.\n */\n\n.uiButton {\n /* Button inherits theme colors from Ant Design tokens */\n}\n\n/*\n * CRITICAL: SVG icon color inheritance\n *\n * Force all SVG icons to inherit button text color automatically\n * Works for lucide-react, heroicons, and any other icon libraries\n */\n.uiButton svg {\n color: inherit !important;\n stroke: currentColor !important;\n fill: currentColor !important;\n}\n\n/*\n * Disabled state - reduce opacity\n */\n.uiButton:disabled svg,\n.uiButton.ant-btn-disabled svg {\n opacity: 0.4;\n}\n\n/*\n * Size variants - ensure SVG scales properly\n */\n.uiButton.ant-btn-sm svg {\n /* Small button icons */\n width: 14px;\n height: 14px;\n}\n\n.uiButton svg {\n /* Default (middle) button icons */\n width: 16px;\n height: 16px;\n}\n\n.uiButton.ant-btn-lg svg {\n /* Large button icons */\n width: 18px;\n height: 18px;\n}\n\n/*\n * Icon positioning within button\n * Ensures proper spacing between icon and text\n */\n.uiButton .ant-btn-icon {\n /* Icon wrapper - CRITICAL: must inherit color for SVG to get correct color */\n color: inherit !important;\n display: inline-flex;\n align-items: center;\n justify-content: center;\n}\n\n.uiButton .ant-btn-icon svg {\n /* SVG inside icon wrapper */\n vertical-align: middle;\n display: block; /* Remove inline spacing */\n}\n\n/*\n * All buttons — base transition and press feedback\n */\n.uiButton {\n transition: transform 100ms ease, box-shadow 150ms ease, opacity 100ms ease;\n}\n\n.uiButton:active:not(:disabled):not(.ant-btn-disabled) {\n transform: scale(0.96);\n transition: transform 60ms ease;\n}\n\n/*\n * Primary button — subtle lift on hover, snap back on press\n */\n.uiButton.ant-btn-primary {\n transition: transform 150ms ease, box-shadow 150ms ease;\n}\n\n.uiButton.ant-btn-primary:hover:not(:disabled):not(.ant-btn-disabled) {\n transform: translateY(-1px);\n box-shadow: 0 4px 12px rgba(12, 102, 255, 0.3);\n}\n\n.uiButton.ant-btn-primary:active:not(:disabled):not(.ant-btn-disabled) {\n transform: scale(0.97);\n box-shadow: none;\n transition: transform 60ms ease;\n}\n\n/*\n * Default / dashed — dim on press\n */\n.uiButton.ant-btn-default:active:not(:disabled):not(.ant-btn-disabled),\n.uiButton.ant-btn-dashed:active:not(:disabled):not(.ant-btn-disabled) {\n opacity: 0.75;\n}\n\n/*\n * Text / link — background flash on press for clear tactile signal\n */\n.uiButton.ant-btn-text:active:not(:disabled):not(.ant-btn-disabled),\n.uiButton.ant-btn-link:active:not(:disabled):not(.ant-btn-disabled) {\n background: rgba(0, 0, 0, 0.06) !important;\n transform: scale(0.95);\n}\n\n/*\n * RTL (Right-to-Left) support\n */\n[dir='rtl'] .uiButton .ant-btn-icon {\n /* Mirror icon position in RTL */\n transform: scaleX(-1);\n}\n","/*\n * UITag styles — interactive feedback for clickable tags\n *\n * Class name is hardcoded ('kb-ui-tag') because tsup doesn't map\n * CSS module class names in the dist bundle — styles.className is always {}.\n */\n\n.kb-ui-tag {\n transition: opacity 100ms ease, transform 100ms ease;\n}\n\n.kb-ui-tag:not([disabled]):active {\n opacity: 0.7;\n transform: scale(0.94);\n transition: opacity 50ms ease, transform 50ms ease;\n}\n","/**\n * UIIcon styles - Proper SVG and icon font theming\n *\n * Ensures all icons (Ant Design icons, lucide-react, custom SVG)\n * inherit colors from CSS variables and work in both light and dark themes.\n */\n\n.uiIcon {\n display: inline-flex;\n align-items: center;\n justify-content: center;\n vertical-align: middle;\n}\n\n/*\n * SVG icons (lucide-react, custom SVG)\n * Use currentColor to inherit from parent color\n */\n.uiIcon svg {\n color: currentColor;\n stroke: currentColor;\n fill: none; /* Most icon libraries use stroke, not fill */\n display: block; /* Remove inline spacing */\n}\n\n/*\n * Ant Design icons (icon fonts)\n * Already use currentColor by default, but ensure it's explicit\n */\n.uiIcon .anticon {\n color: currentColor;\n}\n\n/*\n * Clickable icons (icon buttons)\n */\n.uiIcon.clickable {\n cursor: pointer;\n transition: opacity 0.2s ease, transform 0.1s ease;\n}\n\n.uiIcon.clickable:hover {\n opacity: 0.8;\n}\n\n.uiIcon.clickable:active {\n transform: scale(0.95);\n}\n\n/*\n * Size variants\n */\n.uiIcon.size-xs {\n font-size: 12px;\n width: 12px;\n height: 12px;\n}\n\n.uiIcon.size-sm {\n font-size: 14px;\n width: 14px;\n height: 14px;\n}\n\n.uiIcon.size-base {\n font-size: 16px;\n width: 16px;\n height: 16px;\n}\n\n.uiIcon.size-lg {\n font-size: 20px;\n width: 20px;\n height: 20px;\n}\n\n.uiIcon.size-xl {\n font-size: 24px;\n width: 24px;\n height: 24px;\n}\n\n.uiIcon.size-2xl {\n font-size: 32px;\n width: 32px;\n height: 32px;\n}\n\n/*\n * Color variants using CSS variables\n */\n.uiIcon.color-primary {\n color: var(--link, #2563EB);\n}\n\n.uiIcon.color-secondary {\n color: var(--text-secondary, #6B7280);\n}\n\n.uiIcon.color-success {\n color: var(--success, #16A34A);\n}\n\n.uiIcon.color-warning {\n color: var(--warning, #F59E0B);\n}\n\n.uiIcon.color-error {\n color: var(--error, #DC2626);\n}\n\n.uiIcon.color-info {\n color: var(--info, #0EA5E9);\n}\n\n.uiIcon.color-inherit {\n color: inherit;\n}\n\n/*\n * Spin animation\n */\n.uiIcon.spin {\n animation: uiIconSpin 1s linear infinite;\n}\n\n@keyframes uiIconSpin {\n from {\n transform: rotate(0deg);\n }\n to {\n transform: rotate(360deg);\n }\n}\n\n/*\n * Disabled state\n */\n.uiIcon.disabled {\n opacity: 0.4;\n cursor: not-allowed;\n pointer-events: none;\n}\n","/**\n * UIShimmerText - Animated gradient shimmer on text\n * Classic \"Cursor / ClickUp\" loading text effect.\n */\n\n.shimmer {\n background: linear-gradient(\n 90deg,\n var(--shimmer-color-1, #888) 0%,\n var(--shimmer-color-2, #888) 25%,\n var(--shimmer-highlight, #fff) 50%,\n var(--shimmer-color-2, #888) 75%,\n var(--shimmer-color-1, #888) 100%\n );\n background-size: 200% 100%;\n -webkit-background-clip: text;\n background-clip: text;\n -webkit-text-fill-color: transparent;\n color: transparent;\n animation: shimmerMove var(--shimmer-duration, 2s) linear infinite;\n display: inline-block;\n}\n\n@keyframes shimmerMove {\n 0% { background-position: 100% 0; }\n 100% { background-position: -100% 0; }\n}\n","@keyframes skeletonLoading {\n 0% { background-position: 100% 50%; }\n 100% { background-position: 0% 50%; }\n}\n\n.skeletonText {\n animation: skeletonLoading 1.4s ease infinite;\n}\n"],"mappings":";AAOA,CAAC;AAED;AAQA,CAVC,SAUS;AACR,SAAO;AACP,UAAQ;AACR,QAAM;AACR;AAKA,CAnBC,QAmBQ,UAAU;AACnB,CApBC,QAoBQ,CAAC,iBAAiB;AACzB,WAAS;AACX;AAKA,CA3BC,QA2BQ,CAAC,WAAW;AAEnB,SAAO;AACP,UAAQ;AACV;AAEA,CAjCC,SAiCS;AAER,SAAO;AACP,UAAQ;AACV;AAEA,CAvCC,QAuCQ,CAAC,WAAW;AAEnB,SAAO;AACP,UAAQ;AACV;AAMA,CAjDC,SAiD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,CA5GC,MA4GM,CAAC;AACN,SAAO;AACT;AAKA,CAnHC,MAmHM,CAAC;AACN,aAAW,WAAW,GAAG,OAAO;AAClC;AAEA,WAHa;AAIX;AACE,eAAW,OAAO;AACpB;AACA;AACE,eAAW,OAAO;AACpB;AACF;AAKA,CAnIC,MAmIM,CAAC;AACN,WAAS;AACT,UAAQ;AACR,kBAAgB;AAClB;;;ACzIA,CAAC;AACC;AAAA,IAAY;AAAA,MACV,KAAK;AAAA,MACL,IAAI,iBAAiB,EAAE,MAAM,EAAE;AAAA,MAC/B,IAAI,iBAAiB,EAAE,MAAM,GAAG;AAAA,MAChC,IAAI,mBAAmB,EAAE,MAAM,GAAG;AAAA,MAClC,IAAI,iBAAiB,EAAE,MAAM,GAAG;AAAA,MAChC,IAAI,iBAAiB,EAAE,MAAM;AAE/B,mBAAiB,KAAK;AACtB,2BAAyB;AACzB,mBAAiB;AACjB,2BAAyB;AACzB,SAAO;AACP,aAAW,YAAY,IAAI,kBAAkB,EAAE,IAAI,OAAO;AAC1D,WAAS;AACX;AAEA,WAJa;AAKX;AAAO,yBAAqB,KAAK;AAAG;AACpC;AAAO,yBAAqB,MAAM;AAAG;AACvC;;;AC1BA,WAAW;AACT;AAAO,yBAAqB,KAAK;AAAK;AACtC;AAAO,yBAAqB,GAAK;AAAK;AACxC;AAEA,CAAC;AACC,aAAW,gBAAgB,KAAK,KAAK;AACvC;","names":[]}
|
package/dist/index.d.ts
CHANGED
|
@@ -303,7 +303,7 @@ interface UITagProps extends Omit<TagProps, 'color'> {
|
|
|
303
303
|
* <UITag variant="info" icon={<InfoIcon />}>Info</UITag>
|
|
304
304
|
* ```
|
|
305
305
|
*/
|
|
306
|
-
declare function UITag({ variant, color, children, closable, onClose, icon, ...rest }: UITagProps): react_jsx_runtime.JSX.Element;
|
|
306
|
+
declare function UITag({ variant, color, children, closable, onClose, icon, className, onClick, ...rest }: UITagProps): react_jsx_runtime.JSX.Element;
|
|
307
307
|
|
|
308
308
|
type UITitleLevel = 1 | 2 | 3 | 4 | 5;
|
|
309
309
|
interface UITitleProps {
|
|
@@ -458,20 +458,28 @@ interface UIShimmerTextProps {
|
|
|
458
458
|
*/
|
|
459
459
|
declare function UIShimmerText({ children, color, highlight, duration, className, style, }: UIShimmerTextProps): react_jsx_runtime.JSX.Element;
|
|
460
460
|
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
*/
|
|
461
|
+
interface UICopyButtonProps extends Omit<UIButtonProps, 'onClick' | 'icon' | 'children' | 'variant'> {
|
|
462
|
+
/** Text to copy */
|
|
463
|
+
value: string;
|
|
464
|
+
/** Button size */
|
|
465
|
+
size?: 'small' | 'middle' | 'large';
|
|
466
|
+
/** Show label next to icon */
|
|
467
|
+
label?: string;
|
|
468
|
+
}
|
|
469
|
+
declare function UICopyButton({ value, size, label, style, ...rest }: UICopyButtonProps): react_jsx_runtime.JSX.Element;
|
|
470
|
+
|
|
467
471
|
interface UIMetricCardProps {
|
|
468
472
|
/** Metric label */
|
|
469
473
|
label: string;
|
|
470
474
|
/** Metric value */
|
|
471
475
|
value: string | number;
|
|
476
|
+
/** Icon shown in colored badge */
|
|
477
|
+
icon?: React$1.ReactNode;
|
|
478
|
+
/** Color theme for the icon badge */
|
|
479
|
+
status?: 'default' | 'info' | 'success' | 'warning' | 'error';
|
|
472
480
|
/** Trend direction */
|
|
473
481
|
trend?: 'up' | 'down' | 'neutral';
|
|
474
|
-
/** Change delta (percentage
|
|
482
|
+
/** Change delta (percentage) */
|
|
475
483
|
delta?: number;
|
|
476
484
|
/** Value unit (e.g., '%', 'ms', '$') */
|
|
477
485
|
unit?: string;
|
|
@@ -482,23 +490,7 @@ interface UIMetricCardProps {
|
|
|
482
490
|
/** Loading state */
|
|
483
491
|
loading?: boolean;
|
|
484
492
|
}
|
|
485
|
-
|
|
486
|
-
* MetricCard - Display single metric with optional trend indicator
|
|
487
|
-
*
|
|
488
|
-
* Uses Ant Design tokens for all colors.
|
|
489
|
-
*
|
|
490
|
-
* @example
|
|
491
|
-
* ```tsx
|
|
492
|
-
* <MetricCard
|
|
493
|
-
* label="Active Users"
|
|
494
|
-
* value={1234}
|
|
495
|
-
* trend="up"
|
|
496
|
-
* delta={15.3}
|
|
497
|
-
* unit="users"
|
|
498
|
-
* />
|
|
499
|
-
* ```
|
|
500
|
-
*/
|
|
501
|
-
declare function UIMetricCard({ label, value, trend, delta, unit, size, showDelta, loading, }: UIMetricCardProps): react_jsx_runtime.JSX.Element;
|
|
493
|
+
declare function UIMetricCard({ label, value, icon, status, trend, delta, unit, size, showDelta, loading, }: UIMetricCardProps): react_jsx_runtime.JSX.Element;
|
|
502
494
|
|
|
503
495
|
interface UITableColumn<T = any> extends ColumnType<T> {
|
|
504
496
|
/** Column key */
|
|
@@ -2116,31 +2108,11 @@ interface UIPopoverProps extends PopoverProps {
|
|
|
2116
2108
|
declare function UIPopover(props: UIPopoverProps): react_jsx_runtime.JSX.Element;
|
|
2117
2109
|
|
|
2118
2110
|
interface UIMarkdownViewerProps {
|
|
2119
|
-
/** Markdown content */
|
|
2120
2111
|
content: string;
|
|
2121
|
-
/** Additional CSS class */
|
|
2122
2112
|
className?: string;
|
|
2123
|
-
/** Additional styles */
|
|
2124
2113
|
style?: React$1.CSSProperties;
|
|
2125
2114
|
}
|
|
2126
|
-
|
|
2127
|
-
* UIMarkdownViewer - Markdown content viewer
|
|
2128
|
-
*
|
|
2129
|
-
* Note: This is a basic implementation. For production use, consider:
|
|
2130
|
-
* - react-markdown for full markdown parsing
|
|
2131
|
-
* - rehype-highlight for syntax highlighting
|
|
2132
|
-
* - rehype-sanitize for XSS protection
|
|
2133
|
-
*
|
|
2134
|
-
* @example
|
|
2135
|
-
* ```tsx
|
|
2136
|
-
* <UIMarkdownViewer content={markdownText} />
|
|
2137
|
-
*
|
|
2138
|
-
* <UIMarkdownViewer
|
|
2139
|
-
* content="# Hello World\n\nThis is **bold** text"
|
|
2140
|
-
* />
|
|
2141
|
-
* ```
|
|
2142
|
-
*/
|
|
2143
|
-
declare function UIMarkdownViewer({ content, className, style: customStyle, }: UIMarkdownViewerProps): react_jsx_runtime.JSX.Element;
|
|
2115
|
+
declare function UIMarkdownViewer({ content, className, style: customStyle }: UIMarkdownViewerProps): react_jsx_runtime.JSX.Element;
|
|
2144
2116
|
|
|
2145
2117
|
interface UIJsonViewerProps {
|
|
2146
2118
|
/** JSON data to display */
|
|
@@ -2247,4 +2219,4 @@ interface ListData {
|
|
|
2247
2219
|
total?: number;
|
|
2248
2220
|
}
|
|
2249
2221
|
|
|
2250
|
-
export { type ChartColorPalette, type ChartMetricConfig, type ListData, type ListItem, type MetricData, type SelectData, type SelectOptionItem, type TableData, type TableRow, UIAccordion, type UIAccordionItem, type UIAccordionProps, UIAlert, type UIAlertProps, type UIAlertVariant, UIAreaChart, type UIAreaChartProps, UIAvatar, UIAvatarGroup, type UIAvatarProps, UIBadge, type UIBadgeProps, type UIBadgeVariant, UIBarChart, type UIBarChartProps, UIBox, type UIBoxProps, type UIBoxSpacingValue, UIBreadcrumb, type UIBreadcrumbItem, type UIBreadcrumbProps, UIButton, type UIButtonProps, type UIButtonVariant, UICard, type UICardProps, type UICardVariant, UICheckbox, UICheckboxGroup, type UICheckboxGroupProps, type UICheckboxOption, type UICheckboxProps, UICol, type UIColProps, UIColumnChart, type UIColumnChartProps, UIDatePicker, type UIDatePickerProps, UIDescriptions, UIDescriptionsItem, type UIDescriptionsProps, UIDiffViewer, type UIDiffViewerProps, UIDivider, type UIDividerProps, UIDrawer, type UIDrawerProps, UIDropdown, UIDropdownButton, type UIDropdownProps, UIEmptyState, type UIEmptyStateProps, UIErrorState, type UIErrorStateProps, UIFlex, type UIFlexProps, type UIFlexSpacingValue, UIForm, UIFormItem, type UIFormLayout, UIFormList, type UIFormProps, UIHeader, type UIHeaderProps, UIIcon, UIIconButton, type UIIconColor, type UIIconProps, type UIIconSize, UIInput, UIInputNumber, type UIInputNumberProps, UIInputPassword, type UIInputProps, UIInputSearch, UIInputTextArea, UIJsonViewer, type UIJsonViewerProps, UILineChart, type UILineChartProps, UIList, UIListItem, UIListItemMeta, type UIListProps, UIMarkdownViewer, type UIMarkdownViewerProps, UIMenu, type UIMenuProps, UIMessage, type UIMessageAPI, UIMetricCard, type UIMetricCardProps, UIModal, UIModalConfirm, UIModalError, UIModalInfo, type UIModalProps, UIModalSuccess, UIModalWarning, type UIModalWidth, UINotification, type UINotificationAPI, type UINotificationArgs, UIPage, type UIPageBreadcrumbItem, UIPageHeader, type UIPageHeaderProps, type UIPageProps, UIPageSection, type UIPageSectionProps, type UIPageWidth, UIPieChart, type UIPieChartProps, UIPopconfirm, type UIPopconfirmProps, UIPopover, type UIPopoverProps, UIProgress, type UIProgressProps, UIRadio, UIRadioGroup, type UIRadioGroupProps, type UIRadioProps, UIRangePicker, UIResult, type UIResultProps, UIRow, type UIRowProps, UISegmented, type UISegmentedProps, UISelect, type UISelectOption, type UISelectProps, UIShimmerText, type UIShimmerTextProps, UISkeleton, UISkeletonButton, UISkeletonImage, UISkeletonInput, UISkeletonNode, type UISkeletonProps, UISkeletonText, type UISkeletonTextProps, UISlider, type UISliderProps, UISpace, UISpaceCompact, type UISpaceProps, UISpin, type UISpinProps, UIStack, type UIStackAlign, type UIStackDirection, type UIStackProps, type UIStackSpacing, UIStatistic, UIStatisticCountdown, type UIStatisticProps, UIStatisticsChart, type UIStatisticsChartProps, UISteps, type UIStepsProps, UISwitch, type UISwitchLabelPosition, type UISwitchProps, type UISwitchSize, type UITabItem, UITable, type UITableColumn, type UITableProps, UITabs, type UITabsProps, UITag, type UITagProps, type UITagVariant, UIText, type UITextColor, type UITextProps, type UITextSize, type UITextWeight, type UIThemeResult, UITimePicker, type UITimePickerProps, UITimeline, UITimelineItem, type UITimelineProps, UITitle, type UITitleLevel, type UITitleProps, UITooltip, type UITooltipPlacement, type UITooltipProps, UITree, UITreeDirectoryTree, UITreeNode, type UITreeProps, UITypographyLink, type UITypographyLinkProps, UITypographyParagraph, type UITypographyParagraphProps, UITypographyText, type UITypographyTextProps, UIUpload, UIUploadDragger, type UIUploadProps, createFillFunction, registerIconRenderer, useChartColors, useUIForm, useUIMessage, useUINotification, useUITheme };
|
|
2222
|
+
export { type ChartColorPalette, type ChartMetricConfig, type ListData, type ListItem, type MetricData, type SelectData, type SelectOptionItem, type TableData, type TableRow, UIAccordion, type UIAccordionItem, type UIAccordionProps, UIAlert, type UIAlertProps, type UIAlertVariant, UIAreaChart, type UIAreaChartProps, UIAvatar, UIAvatarGroup, type UIAvatarProps, UIBadge, type UIBadgeProps, type UIBadgeVariant, UIBarChart, type UIBarChartProps, UIBox, type UIBoxProps, type UIBoxSpacingValue, UIBreadcrumb, type UIBreadcrumbItem, type UIBreadcrumbProps, UIButton, type UIButtonProps, type UIButtonVariant, UICard, type UICardProps, type UICardVariant, UICheckbox, UICheckboxGroup, type UICheckboxGroupProps, type UICheckboxOption, type UICheckboxProps, UICol, type UIColProps, UIColumnChart, type UIColumnChartProps, UICopyButton, type UICopyButtonProps, UIDatePicker, type UIDatePickerProps, UIDescriptions, UIDescriptionsItem, type UIDescriptionsProps, UIDiffViewer, type UIDiffViewerProps, UIDivider, type UIDividerProps, UIDrawer, type UIDrawerProps, UIDropdown, UIDropdownButton, type UIDropdownProps, UIEmptyState, type UIEmptyStateProps, UIErrorState, type UIErrorStateProps, UIFlex, type UIFlexProps, type UIFlexSpacingValue, UIForm, UIFormItem, type UIFormLayout, UIFormList, type UIFormProps, UIHeader, type UIHeaderProps, UIIcon, UIIconButton, type UIIconColor, type UIIconProps, type UIIconSize, UIInput, UIInputNumber, type UIInputNumberProps, UIInputPassword, type UIInputProps, UIInputSearch, UIInputTextArea, UIJsonViewer, type UIJsonViewerProps, UILineChart, type UILineChartProps, UIList, UIListItem, UIListItemMeta, type UIListProps, UIMarkdownViewer, type UIMarkdownViewerProps, UIMenu, type UIMenuProps, UIMessage, type UIMessageAPI, UIMetricCard, type UIMetricCardProps, UIModal, UIModalConfirm, UIModalError, UIModalInfo, type UIModalProps, UIModalSuccess, UIModalWarning, type UIModalWidth, UINotification, type UINotificationAPI, type UINotificationArgs, UIPage, type UIPageBreadcrumbItem, UIPageHeader, type UIPageHeaderProps, type UIPageProps, UIPageSection, type UIPageSectionProps, type UIPageWidth, UIPieChart, type UIPieChartProps, UIPopconfirm, type UIPopconfirmProps, UIPopover, type UIPopoverProps, UIProgress, type UIProgressProps, UIRadio, UIRadioGroup, type UIRadioGroupProps, type UIRadioProps, UIRangePicker, UIResult, type UIResultProps, UIRow, type UIRowProps, UISegmented, type UISegmentedProps, UISelect, type UISelectOption, type UISelectProps, UIShimmerText, type UIShimmerTextProps, UISkeleton, UISkeletonButton, UISkeletonImage, UISkeletonInput, UISkeletonNode, type UISkeletonProps, UISkeletonText, type UISkeletonTextProps, UISlider, type UISliderProps, UISpace, UISpaceCompact, type UISpaceProps, UISpin, type UISpinProps, UIStack, type UIStackAlign, type UIStackDirection, type UIStackProps, type UIStackSpacing, UIStatistic, UIStatisticCountdown, type UIStatisticProps, UIStatisticsChart, type UIStatisticsChartProps, UISteps, type UIStepsProps, UISwitch, type UISwitchLabelPosition, type UISwitchProps, type UISwitchSize, type UITabItem, UITable, type UITableColumn, type UITableProps, UITabs, type UITabsProps, UITag, type UITagProps, type UITagVariant, UIText, type UITextColor, type UITextProps, type UITextSize, type UITextWeight, type UIThemeResult, UITimePicker, type UITimePickerProps, UITimeline, UITimelineItem, type UITimelineProps, UITitle, type UITitleLevel, type UITitleProps, UITooltip, type UITooltipPlacement, type UITooltipProps, UITree, UITreeDirectoryTree, UITreeNode, type UITreeProps, UITypographyLink, type UITypographyLinkProps, UITypographyParagraph, type UITypographyParagraphProps, UITypographyText, type UITypographyTextProps, UIUpload, UIUploadDragger, type UIUploadProps, createFillFunction, registerIconRenderer, useChartColors, useUIForm, useUIMessage, useUINotification, useUITheme };
|