@zhama/tego-ui 0.0.0-stage → 1.36.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.
Files changed (57) hide show
  1. package/LICENSE +172 -0
  2. package/assets/styles/tokens.css +1 -0
  3. package/dist/animations-FAPO43TO.css +1 -0
  4. package/dist/chunk-4MXE2PSC.js +1 -0
  5. package/dist/chunk-6HRT65AA.cjs +1 -0
  6. package/dist/chunk-6Z2BWV6F.js +1 -0
  7. package/dist/chunk-CRTE56HI.js +1 -0
  8. package/dist/chunk-ERURJLNK.cjs +1 -0
  9. package/dist/chunk-GZXKQ2K6.cjs +1 -0
  10. package/dist/chunk-H7AHFBEU.js +1 -0
  11. package/dist/chunk-M2GCF4FZ.cjs +1 -0
  12. package/dist/chunk-MTA2XHQG.cjs +1 -0
  13. package/dist/chunk-MVPRTW7Z.js +1 -0
  14. package/dist/chunk-NA5M3B4G.js +1 -0
  15. package/dist/chunk-ON32SVTM.cjs +1 -0
  16. package/dist/chunk-OS64HXLJ.js +1 -0
  17. package/dist/chunk-QPXIAUJD.js +1 -0
  18. package/dist/chunk-RWEJPTVG.cjs +1 -0
  19. package/dist/chunk-SHFR7LZH.js +1 -0
  20. package/dist/chunk-SLTTRXOU.cjs +1 -0
  21. package/dist/chunk-ULCTAAJ2.js +1 -0
  22. package/dist/chunk-UQZZ6WIZ.cjs +1 -0
  23. package/dist/chunk-YWPIPAUQ.cjs +1 -0
  24. package/dist/command-palette.cjs +1 -0
  25. package/dist/command-palette.d.cts +44 -0
  26. package/dist/command-palette.d.ts +44 -0
  27. package/dist/command-palette.js +1 -0
  28. package/dist/config-form/index.cjs +1 -0
  29. package/dist/config-form/index.d.cts +99 -0
  30. package/dist/config-form/index.d.ts +99 -0
  31. package/dist/config-form/index.js +1 -0
  32. package/dist/design-system/index.cjs +1 -0
  33. package/dist/design-system/index.d.cts +629 -0
  34. package/dist/design-system/index.d.ts +629 -0
  35. package/dist/design-system/index.js +1 -0
  36. package/dist/editors.cjs +1 -0
  37. package/dist/editors.d.cts +68 -0
  38. package/dist/editors.d.ts +68 -0
  39. package/dist/editors.js +1 -0
  40. package/dist/highlight-IORKDKTB.css +1 -0
  41. package/dist/index.cjs +2 -0
  42. package/dist/index.d.cts +3157 -0
  43. package/dist/index.d.ts +3157 -0
  44. package/dist/index.js +2 -0
  45. package/dist/styles-447PVICJ.css +1 -0
  46. package/dist/styles-FZ7XXKJP.css +1 -0
  47. package/dist/summary-charts.cjs +1 -0
  48. package/dist/summary-charts.d.cts +45 -0
  49. package/dist/summary-charts.d.ts +45 -0
  50. package/dist/summary-charts.js +1 -0
  51. package/dist/tag-input.cjs +1 -0
  52. package/dist/tag-input.d.cts +15 -0
  53. package/dist/tag-input.d.ts +15 -0
  54. package/dist/tag-input.js +1 -0
  55. package/package.json +122 -4
  56. package/tailwind-preset.cjs +1 -0
  57. package/README.md +0 -3
package/LICENSE ADDED
@@ -0,0 +1,172 @@
1
+ Tego 插件开发套件许可协议 / Tego Plugin SDK License
2
+ 版本 1.0
3
+
4
+ Copyright (c) 2026 zhama. 保留所有权利。All rights reserved.
5
+
6
+ 本协议以中文和英文书就,两种文本如有不一致,以中文文本为准。
7
+ This license is written in Chinese and English. If the two versions differ,
8
+ the Chinese version prevails.
9
+
10
+ ============================================================================
11
+ 中文文本
12
+ ============================================================================
13
+
14
+ 一、定义
15
+
16
+ 1.1 “许可方”指 zhama。
17
+ 1.2 “本软件”指许可方以 @zhama/tego-* 名称发布的软件包,包括其中的源代码、
18
+ 编译产物、类型声明、配置文件与文档,以及许可方提供的更新版本。
19
+ 1.3 “Tego 平台”指许可方或其授权方提供、部署或运营的 Tego OS 及相关产品与服务。
20
+ 1.4 “插件”指为在 Tego 平台中加载与运行而开发的软件扩展,包括其前端、后端与
21
+ 智能体组件。
22
+ 1.5 “您”指使用本软件的个人或组织。
23
+
24
+ 二、许可授予
25
+
26
+ 在您遵守本协议的前提下,许可方授予您一项全球范围、非独占、免许可费、不可转让、
27
+ 不可再许可的许可,仅为开发、测试、构建、打包和分发插件之目的:
28
+ (a) 安装、使用和复制本软件;
29
+ (b) 为上述目的修改本软件;
30
+ (c) 将本软件中由构建工具打包进插件产物的部分,作为插件的组成部分随插件分发。
31
+
32
+ 三、限制
33
+
34
+ 除本协议明确允许的以外,您不得:
35
+ (a) 将本软件或其任何部分用于开发、运行或支持不在 Tego 平台中运行的产品或服务;
36
+ (b) 单独分发、出售、出租、再许可、发布或以其他方式提供本软件或其修改版本,
37
+ 包括以独立软件包形式发布到任何软件仓库;
38
+ (c) 使用本软件开发与 Tego 平台竞争或用以替代 Tego 平台的产品或服务;
39
+ (d) 删除、遮盖或修改本软件中的版权声明、本协议文本或其他权利声明;
40
+ (e) 规避、绕过或篡改 Tego 平台对插件实施的版本兼容、权限或安全校验。
41
+
42
+ 四、您的插件
43
+
44
+ 您开发的插件中由您编写的部分归您或相应权利人所有。本协议不授予许可方对您插件
45
+ 代码的任何权利,也不限制您按自行选择的条款许可您自己的代码;但插件中包含的本
46
+ 软件部分仍受本协议约束。
47
+
48
+ 五、权利保留
49
+
50
+ 本软件的所有权、著作权及其他知识产权归许可方所有。本协议未明确授予的权利均由
51
+ 许可方保留。本协议不授予您使用许可方商号、商标或标识的权利,但为如实说明插件
52
+ 适用于 Tego 平台而作的合理提及除外。
53
+
54
+ 六、第三方组件
55
+
56
+ 本软件依赖的第三方开源组件不属于本软件,受其各自许可证约束。
57
+
58
+ 七、免责声明
59
+
60
+ 本软件按“现状”提供,不附带任何明示或默示的保证,包括但不限于适销性、特定用途
61
+ 适用性和不侵权的保证。
62
+
63
+ 八、责任限制
64
+
65
+ 在适用法律允许的最大范围内,许可方对因本软件或本协议产生或与之相关的任何间接、
66
+ 附带、特殊、惩罚性或后果性损害,或利润、数据、业务的损失,不承担责任;许可方
67
+ 就本协议承担的全部责任以人民币一百元为限。
68
+
69
+ 九、终止
70
+
71
+ 您违反本协议任何条款的,本协议授予的许可自动终止。许可终止后,您应停止使用并
72
+ 删除本软件的全部副本。终止前已合法分发给最终用户的插件,最终用户可继续在 Tego
73
+ 平台中使用。第四条至第八条及第十条在本协议终止后继续有效。
74
+
75
+ 十、适用法律与争议解决
76
+
77
+ 本协议适用中华人民共和国法律(为本协议之目的,不包括香港、澳门特别行政区和
78
+ 台湾地区法律)。因本协议产生的争议,双方应友好协商;协商不成的,提交许可方
79
+ 住所地有管辖权的人民法院诉讼解决。
80
+
81
+ ============================================================================
82
+ English text
83
+ ============================================================================
84
+
85
+ 1. Definitions
86
+
87
+ 1.1 "Licensor" means zhama.
88
+ 1.2 "Software" means the packages the Licensor publishes under the names
89
+ @zhama/tego-*, including their source code, compiled output, type
90
+ declarations, configuration files and documentation, and any updates the
91
+ Licensor provides.
92
+ 1.3 "Tego Platform" means Tego OS and the related products and services
93
+ provided, deployed or operated by the Licensor or its authorized parties.
94
+ 1.4 "Plugin" means a software extension developed to be loaded and run in the
95
+ Tego Platform, including its frontend, backend and agent parts.
96
+ 1.5 "You" means the individual or organization using the Software.
97
+
98
+ 2. License grant
99
+
100
+ Subject to your compliance with this license, the Licensor grants you a
101
+ worldwide, non-exclusive, royalty-free, non-transferable, non-sublicensable
102
+ license, solely to develop, test, build, package and distribute Plugins, to:
103
+ (a) install, use and copy the Software;
104
+ (b) modify the Software for that purpose; and
105
+ (c) distribute those portions of the Software that the build tools include
106
+ in a Plugin's build output, as part of that Plugin.
107
+
108
+ 3. Restrictions
109
+
110
+ Except as expressly permitted by this license, you may not:
111
+ (a) use the Software, or any part of it, to develop, run or support any
112
+ product or service that does not run in the Tego Platform;
113
+ (b) distribute, sell, rent, sublicense, publish or otherwise make available
114
+ the Software or a modified version of it on its own, including as a
115
+ standalone package in any package registry;
116
+ (c) use the Software to develop a product or service that competes with or
117
+ substitutes for the Tego Platform;
118
+ (d) remove, obscure or alter any copyright notice, this license text or any
119
+ other proprietary notice in the Software; or
120
+ (e) circumvent, bypass or tamper with the version-compatibility, permission
121
+ or security checks the Tego Platform applies to Plugins.
122
+
123
+ 4. Your Plugins
124
+
125
+ The parts of your Plugins that you write belong to you or the respective
126
+ rights holders. This license gives the Licensor no rights in your Plugin code
127
+ and does not restrict you from licensing your own code on terms of your
128
+ choosing; portions of the Software included in a Plugin remain subject to this
129
+ license.
130
+
131
+ 5. Reservation of rights
132
+
133
+ The Software and all copyright and other intellectual property rights in it
134
+ belong to the Licensor. All rights not expressly granted are reserved. This
135
+ license grants no right to use the Licensor's trade names, trademarks or
136
+ logos, except for reasonable reference to state accurately that a Plugin is
137
+ built for the Tego Platform.
138
+
139
+ 6. Third-party components
140
+
141
+ Third-party open-source components the Software depends on are not part of
142
+ the Software and are governed by their own licenses.
143
+
144
+ 7. Disclaimer of warranty
145
+
146
+ The Software is provided "as is", without warranty of any kind, express or
147
+ implied, including without limitation the warranties of merchantability,
148
+ fitness for a particular purpose and non-infringement.
149
+
150
+ 8. Limitation of liability
151
+
152
+ To the maximum extent permitted by applicable law, the Licensor is not liable
153
+ for any indirect, incidental, special, punitive or consequential damages, or
154
+ for any loss of profits, data or business, arising out of or relating to the
155
+ Software or this license; the Licensor's total liability under this license
156
+ is limited to RMB 100.
157
+
158
+ 9. Termination
159
+
160
+ This license terminates automatically if you breach any of its terms. On
161
+ termination you must stop using and delete all copies of the Software. End
162
+ users may continue to use, in the Tego Platform, Plugins lawfully distributed
163
+ to them before termination. Sections 4 to 8 and 10 survive termination.
164
+
165
+ 10. Governing law and disputes
166
+
167
+ This license is governed by the laws of the People's Republic of China
168
+ (excluding, for this purpose, the laws of the Hong Kong and Macao Special
169
+ Administrative Regions and Taiwan). The parties shall first seek to resolve
170
+ any dispute arising from this license through friendly negotiation; failing
171
+ that, the dispute shall be submitted to the competent people's court at the
172
+ Licensor's domicile.
@@ -0,0 +1 @@
1
+ :root{--ease-out-expo: cubic-bezier(.16, 1, .3, 1);--ease-spring: cubic-bezier(.34, 1.56, .64, 1);--ease-standard: cubic-bezier(.2, 0, 0, 1);--ease-emphasized: cubic-bezier(.05, .7, .1, 1);--duration-hover: .12s;--duration-enter: .2s;--duration-overlay: .26s;--stagger-step: 30ms;--font-sans: "Inter Variable", ui-sans-serif, system-ui, -apple-system, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;--font-mono: "JetBrains Mono Variable", ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;--icon-stroke: 1.75}@supports (transition-timing-function: linear(0,1)){:root{--ease-spring: linear( 0, .0663 4.2%, .2183 8.3%, .4016 12.5%, .5808 16.7%, .7358 20.8%, .8579 25%, .9461 29.2%, 1.0039 33.3%, 1.037 37.5%, 1.054 45.8%, 1.0397 54.2%, 1.0203 62.5%, 1.0062 70.8%, .9977 83.3%, 1 )}}html.platform-linux{--font-sans: "Inter Variable", Cantarell, "Noto Sans CJK SC", sans-serif}html.platform-linux *,html.platform-linux *:before,html.platform-linux *:after{-webkit-backdrop-filter:none!important;backdrop-filter:none!important}:root{color-scheme:light;--background: 220 20% 98.6%;--foreground: 222 22% 11%;--card: 0 0% 100%;--card-foreground: 222 22% 11%;--popover: 0 0% 100%;--popover-foreground: 222 22% 11%;--primary: 234 70% 55%;--primary-foreground: 0 0% 100%;--primary-soft: 234 80% 96.5%;--signal: 189 94% 28%;--signal-foreground: 0 0% 100%;--signal-soft: 188 70% 94%;--secondary: 220 14% 95%;--secondary-foreground: 222 22% 13%;--muted: 220 14% 95%;--muted-foreground: 220 9% 40%;--skeleton: 220 14% 92.5%;--skeleton-highlight: 220 14% 96.5%;--accent: 234 70% 96.5%;--accent-foreground: 234 60% 44%;--destructive: 0 72% 46%;--destructive-foreground: 0 0% 100%;--destructive-soft: 0 80% 97%;--success: 154 64% 29%;--success-foreground: 0 0% 100%;--success-soft: 150 50% 95%;--warning: 30 92% 34.5%;--warning-foreground: 0 0% 100%;--warning-soft: 40 90% 95%;--info: 206 82% 40%;--info-foreground: 0 0% 100%;--info-soft: 206 80% 96%;--border: 220 13% 90%;--border-strong: 220 10% 80%;--input: 220 12% 86%;--ring: 234 70% 55%;--sidebar: 220 14% 95.5%;--sidebar-foreground: 222 16% 17%;--sidebar-border: 220 13% 90%;--sidebar-accent: 220 13% 90.5%;--sidebar-accent-foreground: 222 22% 11%;--overlay: 222 16% 10%;--chart-1: 234 70% 55%;--chart-2: 189 94% 30%;--chart-3: 154 56% 36%;--chart-4: 36 92% 46%;--chart-5: 346 68% 52%;--chart-6: 262 50% 58%;--chart-7: 84 56% 36%;--chart-8: 220 8% 56%;--radius: .5rem;--radius-control: .375rem;--radius-card: .5rem;--radius-container: .75rem;--surface-raised: 0 0% 100%;--surface-sunken: 220 14% 96%;--surface-inset: 220 16% 97%;--hairline: 220 13% 91%;--highlight-inner: inset 0 1px 0 hsl(0 0% 100% / .7);--shadow-card: 0 0 0 1px hsl(222 20% 12% / .07), 0 1px 2px hsl(222 20% 12% / .05), 0 6px 16px -10px hsl(224 30% 20% / .16);--shadow-lift: 0 0 0 1px hsl(222 20% 12% / .09), 0 4px 8px -2px hsl(222 20% 12% / .06), 0 18px 36px -14px hsl(224 30% 20% / .26);--elevation-1: var(--shadow-card);--elevation-2: 0 1px 2px hsl(222 20% 10% / .04), 0 8px 24px -12px hsl(222 20% 10% / .18);--elevation-3: 0 2px 4px hsl(222 20% 10% / .05), 0 20px 48px -16px hsl(222 20% 10% / .26);--elevation-4: 0 4px 8px hsl(222 20% 10% / .06), 0 28px 64px -20px hsl(222 20% 10% / .32);--glow-focus: 0 0 0 3px hsl(var(--ring) / .2);--glow-signal: 0 0 0 3px hsl(var(--signal) / .18);--texture-grid: radial-gradient(hsl(220 8% 60% / .16) 1px, transparent 1px);--gradient-hero: radial-gradient( 60% 50% at 50% 0%, hsl(var(--primary) / .14), transparent 70% )}.dark{color-scheme:dark;--background: 225 12% 7.5%;--foreground: 220 10% 92%;--card: 225 11% 10.5%;--card-foreground: 220 10% 92%;--popover: 225 11% 12%;--popover-foreground: 220 10% 92%;--primary: 234 92% 72%;--primary-foreground: 230 30% 8%;--primary-soft: 234 40% 17%;--signal: 186 90% 56%;--signal-foreground: 190 60% 6%;--signal-soft: 186 60% 14%;--secondary: 225 10% 13.5%;--secondary-foreground: 220 10% 90%;--muted: 225 10% 13%;--muted-foreground: 222 10% 64%;--skeleton: 225 9% 14.5%;--skeleton-highlight: 225 9% 19%;--accent: 234 40% 18%;--accent-foreground: 234 95% 85%;--destructive: 0 76% 64%;--destructive-foreground: 0 30% 8%;--destructive-soft: 0 40% 14%;--success: 152 52% 52%;--success-foreground: 152 50% 6%;--success-soft: 152 36% 12%;--warning: 38 88% 60%;--warning-foreground: 38 60% 8%;--warning-soft: 38 50% 12%;--info: 206 82% 64%;--info-foreground: 206 60% 8%;--info-soft: 206 50% 14%;--border: 225 9% 17%;--border-strong: 225 8% 26%;--input: 225 9% 20%;--ring: 234 92% 72%;--sidebar: 225 14% 4.5%;--sidebar-foreground: 220 8% 80%;--sidebar-border: 225 10% 11%;--sidebar-accent: 225 10% 12.5%;--sidebar-accent-foreground: 220 10% 94%;--overlay: 220 10% 2%;--chart-1: 234 92% 72%;--chart-2: 186 90% 56%;--chart-3: 152 52% 52%;--chart-4: 38 88% 60%;--chart-5: 346 76% 68%;--chart-6: 262 70% 74%;--chart-7: 84 54% 54%;--chart-8: 220 6% 56%;--surface-raised: 225 11% 10.5%;--surface-sunken: 225 13% 5.8%;--surface-inset: 225 12% 6.5%;--hairline: 225 9% 15%;--highlight-inner: inset 0 1px 0 hsl(0 0% 100% / .05);--shadow-card: 0 0 0 1px hsl(0 0% 100% / .06), 0 1px 2px hsl(0 0% 0% / .4), 0 8px 20px -12px hsl(0 0% 0% / .6);--shadow-lift: 0 0 0 1px hsl(0 0% 100% / .09), 0 12px 32px -12px hsl(0 0% 0% / .7);--elevation-1: var(--shadow-card);--elevation-2: 0 12px 32px -12px hsl(0 0% 0% / .6);--elevation-3: 0 24px 56px -16px hsl(0 0% 0% / .7);--elevation-4: 0 32px 80px -20px hsl(0 0% 0% / .8);--texture-grid: radial-gradient(hsl(220 10% 70% / .06) 1px, transparent 1px)}.identity-surface{--identity-band: hsl(var(--identity-hue) 32% 50%);--identity-soft: hsl(var(--identity-hue) 32% 50% / .1);--identity-text: hsl(var(--identity-hue) 30% 32%)}.dark .identity-surface{--identity-band: hsl(var(--identity-hue) 30% 60%);--identity-soft: hsl(var(--identity-hue) 30% 62% / .14);--identity-text: hsl(var(--identity-hue) 40% 78%)}:root{--action: var(--primary);--action-foreground: var(--primary-foreground);--shadow-subtle: 0 1px 2px hsl(222 20% 12% / .05);--shadow-card-hover: 0 6px 16px -8px hsl(224 30% 20% / .18);--table-head-bg: hsl(var(--surface-sunken));--panel-head-bg: hsl(220 16% 97.5%)}.dark{--action: var(--primary);--action-foreground: var(--primary-foreground);--table-head-bg: hsl(var(--surface-sunken));--panel-head-bg: hsl(225 11% 9%);--tint-bg: hsl(var(--surface-inset));--tint-border: hsl(var(--border))}:root{--shell-sidebar-bg: hsl(var(--sidebar));--shell-sidebar-border: hsl(var(--sidebar-border));--shell-titlebar-bg: hsl(var(--sidebar));--nav-active-bg: hsl(var(--primary) / .09);--nav-child-active-bg: hsl(var(--primary) / .09);--nav-active-fg: hsl(var(--primary));--nav-indicator: hsl(var(--primary))}:root{--tint-bg: hsl(var(--surface-inset));--tint-border: hsl(var(--border));--action-glow: transparent;--brand-glow: 220 10% 10%;--login-brand-bg: radial-gradient( ellipse 80% 60% at 30% 15%, hsl(var(--primary) / .45), transparent 70% ), linear-gradient(160deg, hsl(222 18% 13%), hsl(222 22% 6%));--login-brand-grid: linear-gradient(hsl(0 0% 100% / .06) 1px, transparent 1px), linear-gradient(90deg, hsl(0 0% 100% / .06) 1px, transparent 1px)}:root{--file-pdf: 0 62% 48%;--file-doc: 214 68% 46%;--file-sheet: 152 52% 32%;--file-slide: 24 78% 44%;--file-text: 220 7% 46%;--file-code: 262 40% 52%;--file-image: 292 32% 48%;--file-audio: 330 48% 48%;--file-video: 346 52% 48%;--file-archive: 36 70% 38%}.dark{--file-pdf: 0 70% 66%;--file-doc: 214 76% 68%;--file-sheet: 152 46% 56%;--file-slide: 24 80% 62%;--file-text: 220 6% 62%;--file-code: 262 60% 74%;--file-image: 292 40% 70%;--file-audio: 330 56% 70%;--file-video: 346 62% 70%;--file-archive: 36 76% 60%}:root{--font-code: var(--font-mono);--code-fg: hsl(var(--foreground));--code-bg: hsl(var(--surface-inset));--code-comment: hsl(220 7% 46%);--code-keyword: hsl(234 56% 48%);--code-number: hsl(189 94% 28%);--code-string: hsl(154 52% 30%);--code-title: hsl(262 48% 50%);--code-type: hsl(30 82% 36%);--code-tag: hsl(234 56% 44%);--code-regexp: hsl(346 62% 44%);--code-symbol: hsl(346 62% 44%);--code-builtin: hsl(206 82% 38%);--code-meta: hsl(220 7% 46%);--code-deletion-bg: hsl(var(--destructive-soft));--code-deletion-fg: hsl(var(--destructive));--code-addition-bg: hsl(var(--success-soft));--code-addition-fg: hsl(var(--success));--markdown-th: hsl(var(--surface-sunken));--terminal-font: var(--font-mono);--terminal-bg: #0b0c0e;--terminal-fg: #e3e5e8;--terminal-cursor: #2ae0f4;--terminal-selection: #2a2e35}.dark{--code-fg: hsl(var(--foreground));--code-bg: hsl(var(--surface-inset));--code-comment: hsl(220 6% 54%);--code-keyword: hsl(234 82% 78%);--code-number: hsl(186 80% 62%);--code-string: hsl(152 48% 62%);--code-title: hsl(262 70% 80%);--code-type: hsl(38 85% 66%);--code-tag: hsl(234 82% 78%);--code-regexp: hsl(346 76% 74%);--code-symbol: hsl(346 76% 74%);--code-builtin: hsl(206 82% 72%);--code-meta: hsl(220 6% 54%);--code-deletion-bg: hsl(var(--destructive-soft));--code-deletion-fg: hsl(var(--destructive));--code-addition-bg: hsl(var(--success-soft));--code-addition-fg: hsl(var(--success));--markdown-th: hsl(var(--surface-sunken))}
@@ -0,0 +1 @@
1
+ .animate-smooth{transition:all .2s cubic-bezier(.4,0,.2,1)}@keyframes fadeIn{0%{opacity:0;transform:translateY(8px)}to{opacity:1;transform:translateY(0)}}@keyframes fadeInScale{0%{opacity:0;transform:scale(.95)}to{opacity:1;transform:scale(1)}}.animate-fade-in{animation:fadeIn .3s ease-out}.animate-fade-in-scale{animation:fadeInScale .2s ease-out}.hover-lift{transition:transform .2s ease,box-shadow .2s ease}.hover-lift:hover{transform:translateY(-2px);box-shadow:var(--elevation-2)}.focus-ring{transition:all .2s ease}.focus-ring:focus{outline:none;ring:2px;ring-color:hsl(var(--ring) / .3);ring-offset:2px}@keyframes pulse-subtle{0%,to{opacity:1}50%{opacity:.7}}.animate-pulse-subtle{animation:pulse-subtle 2s ease-in-out infinite}@keyframes status-pulse{0%,to{transform:scale(1);opacity:1}50%{transform:scale(1.1);opacity:.8}}.animate-status-pulse{animation:status-pulse 2s ease-in-out infinite}@keyframes slideInFromRight{0%{transform:translate(100%);opacity:0}to{transform:translate(0);opacity:1}}@keyframes slideInFromLeft{0%{transform:translate(-100%);opacity:0}to{transform:translate(0);opacity:1}}.animate-slide-in-right{animation:slideInFromRight .3s ease-out}.animate-slide-in-left{animation:slideInFromLeft .3s ease-out}@keyframes bounceIn{0%{transform:scale(.3);opacity:0}50%{transform:scale(1.05)}70%{transform:scale(.9)}to{transform:scale(1);opacity:1}}.animate-bounce-in{animation:bounceIn .6s ease}.stagger-delay-1{animation-delay:.1s}.stagger-delay-2{animation-delay:.2s}.stagger-delay-3{animation-delay:.3s}.stagger-delay-4{animation-delay:.4s}.smooth-scroll{scroll-behavior:smooth}.card-hover{transition:all .3s ease}.card-hover:hover{transform:translateY(-4px);box-shadow:var(--elevation-3)}.glass-effect{backdrop-filter:blur(16px);background:hsl(var(--background) / .8);border:1px solid hsl(var(--border) / .2)}@keyframes shimmer{0%{background-position:-468px 0}to{background-position:468px 0}}.animate-shimmer{background-color:hsl(var(--skeleton, 220 15% 92%));background-image:linear-gradient(90deg,hsl(var(--skeleton, 220 15% 92%)) 25%,hsl(var(--skeleton-highlight, 220 15% 96.5%)),hsl(var(--skeleton, 220 15% 92%)) 75%);background-size:400% 100%;animation:shimmer 1.5s infinite}@media(prefers-reduced-motion:reduce){.animate-shimmer{background-image:none;animation:none}}.interactive{cursor:pointer;transition:all .2s ease}.interactive:hover{opacity:.8}.interactive:active{transform:scale(.98)}.text-gradient{background:linear-gradient(135deg,hsl(var(--primary)),hsl(var(--chart-6)));background-clip:text;-webkit-background-clip:text;-webkit-text-fill-color:transparent}@keyframes progress{0%{width:0%}to{width:100%}}.animate-progress{animation:progress 1s ease-out}@keyframes slideInDown{0%{transform:translateY(-100%);opacity:0}to{transform:translateY(0);opacity:1}}.animate-notification{animation:slideInDown .3s ease-out}@keyframes avatar-connecting-spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}@keyframes avatar-connecting-breathe{0%,to{opacity:.75;transform:scale(1)}50%{opacity:1;transform:scale(1.06)}}.animate-avatar-connecting-spin{animation:avatar-connecting-spin 1.8s linear infinite}.animate-avatar-connecting-breathe{animation:avatar-connecting-breathe 2.4s ease-in-out infinite}
@@ -0,0 +1 @@
1
+ var X=Object.defineProperty;var r=(l,i)=>X(l,"name",{value:i,configurable:!0});import{cn as R}from"./chunk-ULCTAAJ2.js";import*as v from"@radix-ui/react-popover";import{X as $,Check as G}from"lucide-react";import*as o from"react";import{jsxs as h,jsx as s}from"react/jsx-runtime";var y=r(l=>l.trim().replace(/\s+/g," "),"normalizeTag"),S=r(l=>{const i=new Set,u=[];for(const x of l){const c=y(x);!c||i.has(c)||(i.add(c),u.push(c))}return u},"dedupeTags"),z=o.forwardRef(({className:l,value:i,onChange:u,suggestions:x=[],maxTags:c,maxTagLength:N=50,allowCustomValue:w=!0,placeholder:M,disabled:d,emptyText:E="No suggestions",customValueHint:I="Press Enter to add a custom tag",onFocus:A,onBlur:O,...j},F)=>{const[f,m]=o.useState(""),[B,a]=o.useState(!1),[k,C]=o.useState(!1),p=o.useRef(null),D=o.useRef(null);o.useImperativeHandle(F,()=>p.current);const n=o.useMemo(()=>S(i),[i]),T=o.useMemo(()=>S(x),[x]),b=o.useMemo(()=>{const e=y(f).toLowerCase();return T.filter(t=>e?t.toLowerCase().includes(e):!0)},[f,T]),g=c===void 0||n.length<c,P=o.useCallback(e=>{const t=y(e).slice(0,N);return!w||!t||!g?!1:n.includes(t)?(m(""),a(!1),!1):(u([...n,t]),m(""),a(!1),!0)},[w,g,N,n,u]),K=o.useCallback(e=>{u(n.filter(t=>t!==e)),p.current?.focus(),a(!0)},[n,u]),q=o.useCallback(e=>{n.includes(e)?u(n.filter(t=>t!==e)):g&&u([...n,e]),m(""),p.current?.focus(),a(!0)},[g,n,u]),H=o.useCallback(e=>{if(!d&&!(k||e.nativeEvent.isComposing)){if(e.key==="Escape"){e.preventDefault(),e.stopPropagation(),a(!1);return}(e.key==="Enter"||e.key===","||e.key==="Tab")&&f.trim()&&(e.preventDefault(),e.stopPropagation(),P(f))}},[P,d,f,k]),L=B&&!d&&b.length>0;return h(v.Root,{open:L,onOpenChange:a,children:[s(v.Anchor,{asChild:!0,children:s("div",{className:"relative",children:h("div",{className:R("flex min-h-11 w-full flex-wrap items-center gap-2 rounded-md border border-input bg-background px-3 py-2 text-sm ring-offset-background transition-colors duration-100 focus-within:ring-1 focus-within:ring-ring",d&&"cursor-not-allowed opacity-50",l),onClick:r(()=>{d||(p.current?.focus(),a(!0))},"onClick"),children:[n.map(e=>h("span",{className:"inline-flex h-7 max-w-full items-center gap-1 rounded-md bg-muted px-2 text-xs font-medium text-foreground",children:[s("span",{className:"truncate",children:e}),!d&&s("button",{type:"button",className:"rounded-sm text-muted-foreground transition-colors hover:text-foreground",onMouseDown:r(t=>t.preventDefault(),"onMouseDown"),onClick:r(t=>{t.stopPropagation(),K(e)},"onClick"),"aria-label":`Remove ${e}`,children:s($,{className:"h-3.5 w-3.5"})})]},e)),g&&s("input",{ref:p,value:f,disabled:d,className:"min-w-[120px] flex-1 bg-transparent text-sm outline-none placeholder:text-muted-foreground",placeholder:n.length===0?M:void 0,onFocus:r(e=>{a(!0),A?.(e)},"onFocus"),onBlur:r(e=>{D.current?.contains(e.relatedTarget)||a(!1),O?.(e)},"onBlur"),onCompositionStart:r(()=>C(!0),"onCompositionStart"),onCompositionEnd:r(e=>{C(!1),m(e.currentTarget.value),a(!0)},"onCompositionEnd"),onChange:r(e=>{m(e.target.value),a(!0)},"onChange"),onKeyDown:H,...j})]})})}),s(v.Portal,{children:s(v.Content,{ref:D,onBlur:r(e=>{!e.currentTarget.contains(e.relatedTarget)&&e.relatedTarget!==p.current&&a(!1)},"onBlur"),align:"start",sideOffset:6,onOpenAutoFocus:r(e=>e.preventDefault(),"onOpenAutoFocus"),onCloseAutoFocus:r(e=>e.preventDefault(),"onCloseAutoFocus"),className:"z-50 overflow-hidden rounded-md border border-border bg-popover text-popover-foreground shadow-elevation-2",style:{width:"var(--radix-popover-trigger-width)"},children:h("div",{className:"max-h-64 overflow-y-auto p-1",children:[w&&s("div",{className:"border-b border-border px-3 py-2 text-xs text-muted-foreground",children:I}),b.length>0?b.map(e=>{const t=n.includes(e);return h("button",{type:"button",className:"flex w-full items-center gap-2 rounded-sm px-3 py-2 text-left text-sm transition-colors hover:bg-accent hover:text-accent-foreground",onMouseDown:r(V=>V.preventDefault(),"onMouseDown"),onClick:r(()=>q(e),"onClick"),children:[s("span",{className:R("flex h-4 w-4 items-center justify-center text-muted-foreground",t&&"text-foreground"),children:t&&s(G,{className:"h-4 w-4"})}),s("span",{className:"truncate",children:e})]},e)}):s("div",{className:"px-3 py-2 text-sm text-muted-foreground",children:E})]})})})]})});z.displayName="TagPickerInput";export{z as TagPickerInput};
@@ -0,0 +1 @@
1
+ "use strict";var l=Object.defineProperty;var i=(e,r)=>l(e,"name",{value:r,configurable:!0});var __defProp=Object.defineProperty,__defNormalProp=i((e,r,t)=>r in e?__defProp(e,r,{enumerable:!0,configurable:!0,writable:!0,value:t}):e[r]=t,"__defNormalProp"),__publicField=i((e,r,t)=>__defNormalProp(e,typeof r!="symbol"?r+"":r,t),"__publicField");exports.__publicField=__publicField;
@@ -0,0 +1 @@
1
+ var B=Object.defineProperty;var e=(t,o)=>B(t,"name",{value:o,configurable:!0});import{clsx as I}from"clsx";import{twMerge as F}from"tailwind-merge";var u={heading1:"text-lg font-semibold tracking-tight",heading2:"text-[15px] font-medium leading-tight",body:"text-sm",bodyMedium:"text-sm font-medium",bodyBold:"text-sm font-semibold",small:"text-[13px]",smallMedium:"text-[13px] font-medium",caption:"text-xs",captionMuted:"text-xs text-muted-foreground"},d={xs:{y:"space-y-1.5",x:"space-x-1.5",gap:"gap-1.5",p:"p-1.5",px:"px-2",py:"py-1.5",pt:"pt-1.5",pb:"pb-1.5",pl:"pl-1.5",pr:"pr-1.5",mx:"mx-1.5",my:"my-1.5",ml:"ml-1.5",mr:"mr-1.5",mt:"mt-1.5",mb:"mb-1.5",left:"left-1.5",right:"right-1.5",top:"top-1.5",bottom:"bottom-1.5"},sm:{y:"space-y-3",x:"space-x-3",gap:"gap-3",p:"p-3",px:"px-3",py:"py-2",pt:"pt-3",pb:"pb-3",pl:"pl-3",pr:"pr-3",mx:"mx-3",my:"my-3",ml:"ml-3",mr:"mr-3",mt:"mt-3",mb:"mb-3",left:"left-3",right:"right-3",top:"top-3",bottom:"bottom-3"},md:{y:"space-y-4",x:"space-x-4",gap:"gap-4",p:"p-4",px:"px-4",py:"py-3",pt:"pt-4",pb:"pb-4",pl:"pl-4",pr:"pr-4",mx:"mx-4",my:"my-4",ml:"ml-4",mr:"mr-4",mt:"mt-4",mb:"mb-4",left:"left-4",right:"right-4",top:"top-4",bottom:"bottom-4"},lg:{y:"space-y-5",x:"space-x-5",gap:"gap-5",p:"p-5",px:"px-5",py:"py-4",pt:"pt-5",pb:"pb-5",pl:"pl-5",pr:"pr-5",mx:"mx-5",my:"my-5",ml:"ml-5",mr:"mr-5",mt:"mt-5",mb:"mb-5",left:"left-5",right:"right-5",top:"top-5",bottom:"bottom-5"},xl:{y:"space-y-6",x:"space-x-6",gap:"gap-6",p:"p-6",px:"px-6",py:"py-5",pt:"pt-6",pb:"pb-6",pl:"pl-6",pr:"pr-6",mx:"mx-6",my:"my-6",ml:"ml-6",mr:"mr-6",mt:"mt-6",mb:"mb-6",left:"left-6",right:"right-6",top:"top-6",bottom:"bottom-6"}},c={none:"rounded-none",sm:"rounded",md:"rounded-md",lg:"rounded-lg",full:"rounded-full"},x={none:"",sm:"shadow",md:"shadow-md",lg:"shadow-lg"},p={primary:"bg-primary text-primary-foreground",primaryHover:"hover:bg-primary/90",primaryMuted:"bg-primary/10 text-primary",secondary:"bg-secondary text-secondary-foreground",secondaryHover:"hover:bg-secondary/80",success:"bg-success text-success-foreground",successHover:"hover:bg-success/90",successMuted:"bg-success/10 text-success",warning:"bg-warning text-warning-foreground",warningHover:"hover:bg-warning/90",warningMuted:"bg-warning/10 text-warning",destructive:"bg-destructive text-destructive-foreground",destructiveHover:"hover:bg-destructive/90",destructiveMuted:"bg-destructive/10 text-destructive",muted:"bg-muted text-muted-foreground",mutedHover:"hover:bg-muted/80",accent:"bg-accent text-accent-foreground",accentHover:"hover:bg-accent/80"},f={base:"bg-background",raised:"bg-muted/30",hover:"hover:bg-muted/50",selected:"bg-muted/60",border:"border-border/60",divider:"bg-border/40"},v={user:"border border-primary/20 bg-primary-soft text-foreground shadow-[0_10px_28px_-24px_hsl(var(--primary)/0.65)]"},m={fast:"transition-colors duration-100 ease-out",normal:"transition-all duration-150 ease-out",slow:"transition-all duration-200 ease-out"},g={hoverHighlight:"hover:bg-accent/50 transition-colors duration-100 ease-out",hoverShadow:"hover:shadow-sm transition-shadow duration-150 ease-out",clickable:"cursor-pointer active:scale-[0.98] active:opacity-90 transition-all duration-100 ease-out",cardHover:"hover:border-border/80 hover:shadow-sm transition-all duration-150 ease-out"},b={container:"layout-responsive container-responsive",grid:{stats:"stats-grid",actions:"actions-grid",agents:"agents-grid",default:"grid-responsive"},card:"card-responsive"},y={disabled:"opacity-50 cursor-not-allowed",loading:"opacity-70 cursor-wait",error:"border-destructive bg-destructive/10",success:"border-success bg-success/10"};function a(...t){return t.filter(Boolean).join(" ")}e(a,"combineTokens");var h={sm:"640px",md:"768px",lg:"1024px",xl:"1280px","2xl":"1536px"},w={pageTitle:a(u.heading1,d.sm.y),sectionTitle:a(u.heading2,d.xs.y),cardTitle:a(u.bodyMedium),buttonPrimary:a(p.primary,p.primaryHover,m.fast),interactiveCard:a(b.card,g.cardHover,c.md),input:a("border border-input bg-background",c.sm,d.sm.px,d.xs.py,m.fast)},r={typography:u,spacing:d,radius:c,shadows:x,colors:p,surfaces:f,chatBubbles:v,transitions:m,interactions:g,layout:b,states:y,presets:w,breakpoints:h};function n(...t){return F(I(t))}e(n,"cn");function N(t,o){return r.spacing[t][o]}e(N,"getSpacing");function z(t){return r.typography[t]}e(z,"getTypography");function _(t){return r.states[t]}e(_,"getStateStyle");function L(t){const{interactive:o=!1,shadow:s="sm",radius:i="lg",className:l}=t;return n("border bg-card text-card-foreground",r.radius[i],r.shadows[s],o&&r.interactions.cardHover,l)}e(L,"buildCardClass");function j(t){const{variant:o="primary",size:s="md",className:i}=t,l="inline-flex items-center justify-center font-medium rounded-md",S={primary:r.colors.primary+" "+r.colors.primaryHover,secondary:r.colors.secondary+" "+r.colors.secondaryHover,destructive:r.colors.destructive+" "+r.colors.destructiveHover,ghost:"hover:bg-accent hover:text-accent-foreground",outline:"border border-input bg-background hover:bg-accent hover:text-accent-foreground"},T={sm:"h-7 px-2.5 text-xs",md:"h-8 px-3 py-1.5 text-[13px]",lg:"h-9 px-4"};return n(l,S[o],T[s],r.transitions.fast,i)}e(j,"buildButtonClass");function R(t){const{error:o=!1,disabled:s=!1,className:i}=t;return n("flex h-8 w-full rounded-md border border-input bg-background px-2.5 py-1.5","text-[13px] ring-offset-background","placeholder:text-muted-foreground","focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring","disabled:cursor-not-allowed disabled:opacity-50",r.transitions.fast,o&&"border-destructive focus-visible:ring-destructive",s&&r.states.disabled,i)}e(R,"buildInputClass");function A(t){const{variant:o="default",className:s}=t;return n("inline-flex items-center rounded px-1.5 py-0.5 text-[11px] font-medium",{default:"bg-primary text-primary-foreground",secondary:"bg-secondary text-secondary-foreground",success:"bg-success/10 text-success",warning:"bg-warning/10 text-warning",destructive:"bg-destructive text-destructive-foreground",outline:"border border-border bg-background"}[o],s)}e(A,"buildBadgeClass");function G(t){return r.layout.grid[t]}e(G,"buildGridClass");function O(){return r.layout.container}e(O,"getContainerClass");var C={xs:"h-3 w-3",sm:"h-4 w-4",md:"h-5 w-5",lg:"h-6 w-6",xl:"h-8 w-8","2xl":"h-10 w-10"};function P(t){return C[t]}e(P,"getIconSize");function V(t){return{success:"text-success",active:"text-success",warning:"text-warning",pending:"text-warning",error:"text-destructive",inactive:"text-muted-foreground",disabled:"text-muted-foreground/60"}[t.toLowerCase()]??"text-muted-foreground"}e(V,"getStatusColor");function q(t){return{success:"success",active:"success",warning:"warning",pending:"warning",error:"destructive",inactive:"secondary",disabled:"secondary"}[t.toLowerCase()]??"default"}e(q,"getStatusBadgeVariant");function D(t){return n("w-full caption-bottom text-sm",t?.className)}e(D,"buildTableClass");var H={single:"truncate",double:"line-clamp-2",triple:"line-clamp-3"};function E(t){return H[t]}e(E,"getTruncateClass");var M={fadeIn:"animate-in fade-in duration-200",fadeOut:"animate-out fade-out duration-200",slideInFromRight:"animate-in slide-in-from-right duration-300",slideInFromLeft:"animate-in slide-in-from-left duration-300",slideInFromTop:"animate-in slide-in-from-top duration-300",slideInFromBottom:"animate-in slide-in-from-bottom duration-300",spin:"animate-spin",pulse:"animate-pulse"};function J(t){return M[t]}e(J,"getAnimation");var k="focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2";function K(t){return n(k,t)}e(K,"buildFocusableClass");function Q(t){return n("animate-pulse rounded-md bg-muted",t)}e(Q,"buildSkeletonClass");export{M as animations,h as breakpoints,A as buildBadgeClass,j as buildButtonClass,L as buildCardClass,K as buildFocusableClass,G as buildGridClass,R as buildInputClass,Q as buildSkeletonClass,D as buildTableClass,v as chatBubbles,n as cn,p as colors,a as combineTokens,r as designTokens,k as focusRing,J as getAnimation,O as getContainerClass,P as getIconSize,N as getSpacing,_ as getStateStyle,q as getStatusBadgeVariant,V as getStatusColor,E as getTruncateClass,z as getTypography,C as iconSizes,g as interactions,b as layout,w as presets,c as radius,x as shadows,d as spacing,y as states,f as surfaces,m as transitions,H as truncate,u as typography};
@@ -0,0 +1 @@
1
+ import{cn as m}from"./chunk-ULCTAAJ2.js";import*as o from"@radix-ui/react-tooltip";import*as s from"react";import{jsx as t}from"react/jsx-runtime";var l=o.Provider,n=o.Root,p=o.Trigger,e=s.forwardRef(({className:a,sideOffset:i=4,...r},d)=>t(o.Portal,{children:t(o.Content,{ref:d,sideOffset:i,className:m("z-50 overflow-hidden rounded border bg-popover px-2 py-1 text-[11px] text-popover-foreground shadow-elevation-2 animate-in fade-in-0 zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",a),...r})}));e.displayName=o.Content.displayName;export{n as Tooltip,e as TooltipContent,l as TooltipProvider,p as TooltipTrigger};
@@ -0,0 +1 @@
1
+ "use strict";var a=Object.defineProperty;var i=(e,t)=>a(e,"name",{value:t,configurable:!0});var chunkYWPIPAUQ_cjs=require("./chunk-YWPIPAUQ.cjs"),TooltipPrimitive=require("@radix-ui/react-tooltip"),React=require("react"),jsxRuntime=require("react/jsx-runtime");function _interopNamespace(e){if(e&&e.__esModule)return e;var t=Object.create(null);return e&&Object.keys(e).forEach(function(r){if(r!=="default"){var o=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(t,r,o.get?o:{enumerable:!0,get:i(function(){return e[r]},"get")})}}),t.default=e,Object.freeze(t)}i(_interopNamespace,"_interopNamespace");var TooltipPrimitive__namespace=_interopNamespace(TooltipPrimitive),React__namespace=_interopNamespace(React),TooltipProvider=TooltipPrimitive__namespace.Provider,Tooltip=TooltipPrimitive__namespace.Root,TooltipTrigger=TooltipPrimitive__namespace.Trigger,TooltipContent=React__namespace.forwardRef(({className:e,sideOffset:t=4,...r},o)=>jsxRuntime.jsx(TooltipPrimitive__namespace.Portal,{children:jsxRuntime.jsx(TooltipPrimitive__namespace.Content,{ref:o,sideOffset:t,className:chunkYWPIPAUQ_cjs.cn("z-50 overflow-hidden rounded border bg-popover px-2 py-1 text-[11px] text-popover-foreground shadow-elevation-2 animate-in fade-in-0 zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",e),...r})}));TooltipContent.displayName=TooltipPrimitive__namespace.Content.displayName,exports.Tooltip=Tooltip,exports.TooltipContent=TooltipContent,exports.TooltipProvider=TooltipProvider,exports.TooltipTrigger=TooltipTrigger;
@@ -0,0 +1 @@
1
+ "use strict";var i=Object.defineProperty;var s=(e,t)=>i(e,"name",{value:t,configurable:!0});var chunkYWPIPAUQ_cjs=require("./chunk-YWPIPAUQ.cjs"),classVarianceAuthority=require("class-variance-authority"),React=require("react"),jsxRuntime=require("react/jsx-runtime");function _interopNamespace(e){if(e&&e.__esModule)return e;var t=Object.create(null);return e&&Object.keys(e).forEach(function(r){if(r!=="default"){var a=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(t,r,a.get?a:{enumerable:!0,get:s(function(){return e[r]},"get")})}}),t.default=e,Object.freeze(t)}s(_interopNamespace,"_interopNamespace");var React__namespace=_interopNamespace(React),alertVariants=classVarianceAuthority.cva("relative w-full rounded-md border px-3 py-2.5 text-[13px] [&>svg+div]:translate-y-[-2px] [&>svg]:absolute [&>svg]:left-3 [&>svg]:top-3 [&>svg]:h-3.5 [&>svg]:w-3.5 [&>svg]:text-foreground [&>svg~*]:pl-6",{variants:{variant:{default:"bg-background text-foreground",destructive:"border-destructive/50 text-destructive [&>svg]:text-destructive",warning:"border-warning/50 text-warning [&>svg]:text-warning",info:"border-info/50 text-info [&>svg]:text-info",success:"border-success/50 text-success [&>svg]:text-success"}},defaultVariants:{variant:"default"}}),Alert=React__namespace.forwardRef(({className:e,variant:t,...r},a)=>jsxRuntime.jsx("div",{ref:a,role:"alert",className:chunkYWPIPAUQ_cjs.cn(alertVariants({variant:t}),e),...r}));Alert.displayName="Alert";var AlertTitle=React__namespace.forwardRef(({className:e,...t},r)=>jsxRuntime.jsx("h5",{ref:r,className:chunkYWPIPAUQ_cjs.cn("mb-1 font-medium leading-none tracking-tight",e),...t}));AlertTitle.displayName="AlertTitle";var AlertDescription=React__namespace.forwardRef(({className:e,...t},r)=>jsxRuntime.jsx("div",{ref:r,className:chunkYWPIPAUQ_cjs.cn("text-[13px] [&_p]:leading-relaxed",e),...t}));AlertDescription.displayName="AlertDescription",exports.Alert=Alert,exports.AlertDescription=AlertDescription,exports.AlertTitle=AlertTitle;
@@ -0,0 +1 @@
1
+ var v=Object.defineProperty;var p=(r,i)=>v(r,"name",{value:i,configurable:!0});import{TooltipProvider as N,Tooltip as k,TooltipTrigger as w,TooltipContent as M}from"./chunk-CRTE56HI.js";import{cn as f}from"./chunk-ULCTAAJ2.js";import{jsxs as s,jsx as e,Fragment as $}from"react/jsx-runtime";function S({data:r,label:i,className:u}){const d=Math.max(1,...r.flatMap(l=>l.values)),n=p(l=>35+l*530/Math.max(1,r.length-1),"x"),c=p(l=>180-l/d*150,"y");return s("figure",{className:f("w-full",u),"aria-label":i,children:[s("svg",{viewBox:"0 0 600 225",role:"img","aria-label":i,className:"h-auto w-full text-primary",children:[[0,.5,1].map(l=>e("line",{x1:"35",x2:"565",y1:c(l*d),y2:c(l*d),className:"stroke-border"},l)),[0,1].map(l=>e("polyline",{fill:"none",stroke:"currentColor",strokeWidth:"2.5",strokeDasharray:l?"6 4":void 0,opacity:l?.55:1,points:r.map((o,a)=>`${n(a)},${c(o.values[l]??0)}`).join(" ")},l)),r.map((l,o)=>e("text",{x:n(o),y:"210",textAnchor:"middle",fontSize:"12",className:"fill-muted-foreground",children:l.label},l.label))]}),e("ul",{className:"sr-only",children:r.map(l=>s("li",{children:[l.label,": ",l.values.join(" / ")]},l.label))})]})}p(S,"SummaryTrendChart");function y({data:r,label:i}){const u=r.reduce((n,c)=>n+c.value,0);let d=0;return s("svg",{viewBox:"0 0 120 120",role:"img","aria-label":i,className:"mx-auto h-40 w-40 text-primary",children:[e("circle",{cx:"60",cy:"60",r:"42",fill:"none",strokeWidth:"16",className:"stroke-muted"}),r.map((n,c)=>{const l=u?n.value/u*264:0,o=d;return d+=l,e("circle",{cx:"60",cy:"60",r:"42",fill:"none",stroke:"currentColor",strokeWidth:"16",opacity:1-c/Math.max(r.length,1)*.65,strokeDasharray:`${l} ${264-l}`,strokeDashoffset:-o,transform:"rotate(-90 60 60)",children:s("title",{children:[n.label,": ",n.value]})},n.label)})]})}p(y,"SummaryDistributionChart");var b={primary:"bg-primary",success:"bg-success",warning:"bg-warning",destructive:"bg-destructive",accent:"bg-chart-6"};function C({data:r,series:i,label:u,maximum:d,unit:n="",missingLabel:c,className:l}){const o=d??Math.max(1,...r.flatMap(t=>t.values.map(m=>m??0))),a=p(t=>t===null?c:`${t.toLocaleString()}${n}`,"format");return e(N,{children:s("figure",{"aria-label":u,className:f("space-y-4",l),children:[e("figcaption",{className:"sr-only",children:u}),e("ul",{className:"flex flex-wrap gap-x-4 gap-y-2 text-xs text-muted-foreground",children:i.map(t=>s("li",{className:"flex items-center gap-1.5",children:[e("span",{"aria-hidden":!0,className:f("size-2.5 rounded-sm",b[t.tone])}),t.label]},t.key))}),e("div",{className:"grid gap-5 lg:grid-cols-2",children:r.map(t=>s("div",{className:"min-w-0 space-y-2",children:[e("p",{className:"break-words text-sm font-medium",children:t.label}),i.map((m,g)=>{const h=t.values[g]??null,x=`${t.label} \xB7 ${m.label}: ${a(h)}`;return s("div",{className:"grid grid-cols-[7rem_minmax(0,1fr)_3.5rem] items-center gap-2 text-xs",children:[e("span",{className:"text-muted-foreground",children:m.label}),s(k,{children:[e(w,{asChild:!0,children:s("div",{tabIndex:0,role:"img","aria-label":x,className:"relative h-4 rounded bg-muted/60 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",children:[h!==null&&h>0&&e("div",{"aria-hidden":!0,className:f("h-full rounded",b[m.tone]),style:{width:`${Math.min(100,Math.max(0,h/o*100))}%`}}),h===null&&e("span",{"aria-hidden":!0,className:"absolute inset-0 text-center text-muted-foreground",children:"\u2014"})]})}),e(M,{children:x})]}),e("span",{className:"text-right tabular-nums",children:a(h)})]},m.key)}),s("div",{"aria-hidden":!0,className:"ml-[7.5rem] mr-[4rem] flex justify-between text-[10px] text-muted-foreground",children:[s("span",{children:["0",n]}),s("span",{children:[o.toLocaleString(),n]})]})]},t.key))})]})})}p(C,"SummaryBarChart");function B({data:r,label:i,emptyLabel:u}){const d=r.reduce((n,c)=>n+c.value,0);return s("figure",{"aria-label":i,className:"space-y-4",children:[e("figcaption",{className:"sr-only",children:i}),d>0?s($,{children:[e(y,{data:r,label:i}),e("ul",{className:"space-y-2 text-sm",children:r.map((n,c)=>s("li",{className:"flex items-center gap-2",children:[e("span",{"aria-hidden":!0,className:"size-2.5 rounded-sm bg-primary",style:{opacity:1-c/r.length*.65}}),e("span",{className:"flex-1",children:n.label}),s("span",{className:"tabular-nums",children:[n.value.toLocaleString()," \xB7"," ",(n.value/d*100).toFixed(1),"%"]})]},n.label))})]}):e("p",{className:"py-16 text-center text-sm text-muted-foreground",children:u})]})}p(B,"SummaryPieChart");var j={primary:"stroke-primary",success:"stroke-success",warning:"stroke-warning",destructive:"stroke-destructive",accent:"stroke-chart-6"},z={primary:"bg-primary",success:"bg-success",warning:"bg-warning",destructive:"bg-destructive",accent:"bg-chart-6"};function T({data:r,series:i,label:u,missingLabel:d}){const n=Math.max(0,...r.flatMap(a=>a.values.map(t=>t??0))),c=Math.max(2,Math.ceil(n/2)*2),l=p(a=>55+a*530/Math.max(1,r.length-1),"x"),o=p(a=>200-a/c*165,"y");return s("figure",{"aria-label":u,className:"space-y-3",children:[e("figcaption",{className:"sr-only",children:u}),e("ul",{className:"flex flex-wrap gap-4 text-xs text-muted-foreground",children:i.map(a=>s("li",{className:"flex items-center gap-1.5",children:[e("span",{"aria-hidden":!0,className:`size-2.5 rounded-sm ${z[a.tone]}`}),a.label]},a.key))}),s("svg",{viewBox:"0 0 640 250",role:"img","aria-label":u,className:"h-auto w-full",children:[[0,.5,1].map(a=>s("g",{children:[e("line",{x1:"55",x2:"585",y1:o(c*a),y2:o(c*a),className:"stroke-border"}),e("text",{x:"45",y:o(c*a)+6,textAnchor:"end",fontSize:"18",className:"fill-muted-foreground",children:(c*a).toLocaleString()})]},a)),i.map((a,t)=>e("g",{className:j[a.tone],children:r.map((m,g)=>{const h=m.values[t]??null,x=r[g-1]?.values[t]??null;return h===null?null:s("g",{children:[x!==null&&e("line",{x1:l(g-1),y1:o(x),x2:l(g),y2:o(h),strokeWidth:"3"}),e("circle",{cx:l(g),cy:o(h),r:"4.5",className:"fill-background",strokeWidth:"3",children:s("title",{children:[m.detail??m.label," \xB7 ",a.label,": ",h]})})]},m.label)})},a.key)),r.map((a,t)=>e("text",{x:l(t),y:"236",textAnchor:"middle",fontSize:"18",className:"fill-muted-foreground",children:a.label},a.label))]}),e("ul",{className:"sr-only",children:r.map(a=>s("li",{children:[a.label,":"," ",i.map((t,m)=>`${t.label} ${a.values[m]??d}`).join("; ")]},a.label))})]})}p(T,"SummaryLineChart");export{C as SummaryBarChart,y as SummaryDistributionChart,T as SummaryLineChart,B as SummaryPieChart,S as SummaryTrendChart};
@@ -0,0 +1 @@
1
+ "use strict";var s=Object.defineProperty;var i=(e,t)=>s(e,"name",{value:t,configurable:!0});var chunkYWPIPAUQ_cjs=require("./chunk-YWPIPAUQ.cjs"),reactSlot=require("@radix-ui/react-slot"),classVarianceAuthority=require("class-variance-authority"),React=require("react"),jsxRuntime=require("react/jsx-runtime");function _interopNamespace(e){if(e&&e.__esModule)return e;var t=Object.create(null);return e&&Object.keys(e).forEach(function(r){if(r!=="default"){var n=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(t,r,n.get?n:{enumerable:!0,get:i(function(){return e[r]},"get")})}}),t.default=e,Object.freeze(t)}i(_interopNamespace,"_interopNamespace");var React__namespace=_interopNamespace(React),buttonVariants=classVarianceAuthority.cva("inline-flex items-center justify-center whitespace-nowrap rounded-md text-[13px] font-medium ring-offset-background transition-colors duration-100 focus-visible:outline-none focus-visible:ring-[3px] focus-visible:ring-ring/20 disabled:pointer-events-none disabled:opacity-50",{variants:{variant:{default:"bg-action text-action-foreground hover:bg-action/90 active:bg-action/80",destructive:"bg-destructive text-destructive-foreground hover:bg-destructive/90 active:bg-destructive/80",outline:"border border-input bg-background hover:bg-accent hover:text-accent-foreground active:bg-accent/80",secondary:"bg-secondary text-secondary-foreground hover:bg-secondary/80 active:bg-secondary/70",ghost:"hover:bg-accent hover:text-accent-foreground active:bg-accent/80 focus-visible:bg-accent focus-visible:text-accent-foreground focus-visible:ring-0",link:"text-primary underline-offset-4 hover:underline focus-visible:underline focus-visible:ring-0",gradient:"bg-action text-action-foreground hover:bg-action/90 active:bg-action/80",success:"bg-success text-success-foreground hover:bg-success/90 active:bg-success/80",warning:"bg-warning text-warning-foreground hover:bg-warning/90 active:bg-warning/80"},size:{default:"h-9 px-4 py-2",sm:"h-8 rounded px-3 text-xs",lg:"h-10 rounded-md px-5",icon:"h-9 w-9",xs:"h-7 px-2.5 text-xs rounded"}},defaultVariants:{variant:"default",size:"default"}}),Button=React__namespace.forwardRef(({className:e,variant:t,size:r,asChild:n=!1,...a},c)=>{const o=n?reactSlot.Slot:"button";return jsxRuntime.jsx(o,{className:chunkYWPIPAUQ_cjs.cn(buttonVariants({variant:t,size:r,className:e})),ref:c,...a})});Button.displayName="Button",exports.Button=Button,exports.buttonVariants=buttonVariants;
@@ -0,0 +1 @@
1
+ "use strict";var n=Object.defineProperty;var o=(e,t)=>n(e,"name",{value:t,configurable:!0});var chunkYWPIPAUQ_cjs=require("./chunk-YWPIPAUQ.cjs"),classVarianceAuthority=require("class-variance-authority"),React4=require("react"),jsxRuntime=require("react/jsx-runtime"),LabelPrimitive=require("@radix-ui/react-label"),SelectPrimitive=require("@radix-ui/react-select"),lucideReact=require("lucide-react"),SwitchPrimitive=require("@radix-ui/react-switch");function _interopNamespace(e){if(e&&e.__esModule)return e;var t=Object.create(null);return e&&Object.keys(e).forEach(function(r){if(r!=="default"){var a=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(t,r,a.get?a:{enumerable:!0,get:o(function(){return e[r]},"get")})}}),t.default=e,Object.freeze(t)}o(_interopNamespace,"_interopNamespace");var React4__namespace=_interopNamespace(React4),LabelPrimitive__namespace=_interopNamespace(LabelPrimitive),SelectPrimitive__namespace=_interopNamespace(SelectPrimitive),SwitchPrimitive__namespace=_interopNamespace(SwitchPrimitive),badgeVariants=classVarianceAuthority.cva("inline-flex items-center rounded px-1.5 py-0.5 text-[11px] font-medium transition-colors focus:outline-none focus:ring-1 focus:ring-ring",{variants:{variant:{default:"border-transparent bg-primary text-primary-foreground",secondary:"border-transparent bg-secondary text-secondary-foreground",destructive:"border-transparent bg-destructive text-destructive-foreground",outline:"border border-border text-foreground",success:"border-transparent bg-success/10 text-success",warning:"border-transparent bg-warning/10 text-warning"}},defaultVariants:{variant:"default"}});function Badge({className:e,variant:t,...r}){return jsxRuntime.jsx("div",{className:chunkYWPIPAUQ_cjs.cn(badgeVariants({variant:t}),e),...r})}o(Badge,"Badge");var Input=React4__namespace.forwardRef(({className:e,type:t,...r},a)=>jsxRuntime.jsx("input",{type:t,className:chunkYWPIPAUQ_cjs.cn("flex h-9 w-full rounded-md border border-input bg-background px-3 py-2 text-sm ring-offset-background transition-colors duration-100 file:border-0 file:bg-transparent file:text-sm file:font-medium placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50",e),ref:a,...r}));Input.displayName="Input";var labelVariants=classVarianceAuthority.cva("text-[13px] font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"),Label=React4__namespace.forwardRef(({className:e,...t},r)=>jsxRuntime.jsx(LabelPrimitive__namespace.Root,{ref:r,className:chunkYWPIPAUQ_cjs.cn(labelVariants(),e),...t}));Label.displayName=LabelPrimitive__namespace.Root.displayName;var Select=SelectPrimitive__namespace.Root,SelectGroup=SelectPrimitive__namespace.Group,SelectValue=SelectPrimitive__namespace.Value,SelectTrigger=React4__namespace.forwardRef(({className:e,children:t,...r},a)=>jsxRuntime.jsxs(SelectPrimitive__namespace.Trigger,{ref:a,className:chunkYWPIPAUQ_cjs.cn("flex h-8 w-full items-center justify-between rounded-md border border-input bg-background px-2.5 py-1.5 text-[13px] ring-offset-background transition-colors duration-100 placeholder:text-muted-foreground focus:outline-none focus:ring-1 focus:ring-ring disabled:cursor-not-allowed disabled:opacity-50 [&>span]:line-clamp-1",e),...r,children:[t,jsxRuntime.jsx(SelectPrimitive__namespace.Icon,{asChild:!0,children:jsxRuntime.jsx(lucideReact.ChevronDown,{className:"h-3.5 w-3.5 opacity-50"})})]}));SelectTrigger.displayName=SelectPrimitive__namespace.Trigger.displayName;var SelectScrollUpButton=React4__namespace.forwardRef(({className:e,...t},r)=>jsxRuntime.jsx(SelectPrimitive__namespace.ScrollUpButton,{ref:r,className:chunkYWPIPAUQ_cjs.cn("flex cursor-default items-center justify-center py-1",e),...t,children:jsxRuntime.jsx(lucideReact.ChevronUp,{className:"h-4 w-4"})}));SelectScrollUpButton.displayName=SelectPrimitive__namespace.ScrollUpButton.displayName;var SelectScrollDownButton=React4__namespace.forwardRef(({className:e,...t},r)=>jsxRuntime.jsx(SelectPrimitive__namespace.ScrollDownButton,{ref:r,className:chunkYWPIPAUQ_cjs.cn("flex cursor-default items-center justify-center py-1",e),...t,children:jsxRuntime.jsx(lucideReact.ChevronDown,{className:"h-4 w-4"})}));SelectScrollDownButton.displayName=SelectPrimitive__namespace.ScrollDownButton.displayName;var SelectContent=React4__namespace.forwardRef(({className:e,children:t,position:r="popper",...a},s)=>jsxRuntime.jsx(SelectPrimitive__namespace.Portal,{children:jsxRuntime.jsxs(SelectPrimitive__namespace.Content,{ref:s,className:chunkYWPIPAUQ_cjs.cn("relative z-50 max-h-96 min-w-[8rem] overflow-hidden rounded-md border border-border bg-popover text-popover-foreground shadow-elevation-2 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",r==="popper"&&"data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1",e),position:r,...a,children:[jsxRuntime.jsx(SelectScrollUpButton,{}),jsxRuntime.jsx(SelectPrimitive__namespace.Viewport,{className:chunkYWPIPAUQ_cjs.cn("p-1",r==="popper"&&"h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)]"),children:t}),jsxRuntime.jsx(SelectScrollDownButton,{})]})}));SelectContent.displayName=SelectPrimitive__namespace.Content.displayName;var SelectLabel=React4__namespace.forwardRef(({className:e,...t},r)=>jsxRuntime.jsx(SelectPrimitive__namespace.Label,{ref:r,className:chunkYWPIPAUQ_cjs.cn("py-1.5 pl-8 pr-2 text-sm font-semibold",e),...t}));SelectLabel.displayName=SelectPrimitive__namespace.Label.displayName;var SelectItem=React4__namespace.forwardRef(({className:e,children:t,...r},a)=>jsxRuntime.jsxs(SelectPrimitive__namespace.Item,{ref:a,className:chunkYWPIPAUQ_cjs.cn("relative flex w-full cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),...r,children:[jsxRuntime.jsx("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center",children:jsxRuntime.jsx(SelectPrimitive__namespace.ItemIndicator,{children:jsxRuntime.jsx(lucideReact.Check,{className:"h-4 w-4"})})}),jsxRuntime.jsx(SelectPrimitive__namespace.ItemText,{children:t})]}));SelectItem.displayName=SelectPrimitive__namespace.Item.displayName;var SelectSeparator=React4__namespace.forwardRef(({className:e,...t},r)=>jsxRuntime.jsx(SelectPrimitive__namespace.Separator,{ref:r,className:chunkYWPIPAUQ_cjs.cn("-mx-1 my-1 h-px bg-muted",e),...t}));SelectSeparator.displayName=SelectPrimitive__namespace.Separator.displayName;var Switch=React4__namespace.forwardRef(({className:e,...t},r)=>jsxRuntime.jsx(SwitchPrimitive__namespace.Root,{className:chunkYWPIPAUQ_cjs.cn("peer inline-flex h-5 w-9 shrink-0 cursor-pointer items-center rounded-full border-2 border-transparent transition-colors duration-100 focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-primary data-[state=unchecked]:bg-input",e),...t,ref:r,children:jsxRuntime.jsx(SwitchPrimitive__namespace.Thumb,{className:chunkYWPIPAUQ_cjs.cn("pointer-events-none block h-4 w-4 rounded-full bg-background shadow-sm ring-0 transition-transform data-[state=checked]:translate-x-4 data-[state=unchecked]:translate-x-0")})}));Switch.displayName=SwitchPrimitive__namespace.Root.displayName;var Textarea=React4__namespace.forwardRef(({className:e,...t},r)=>jsxRuntime.jsx("textarea",{className:chunkYWPIPAUQ_cjs.cn("flex min-h-[72px] w-full rounded-md border border-input bg-background px-2.5 py-2 text-[13px] ring-offset-background transition-colors duration-100 placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50",e),ref:r,...t}));Textarea.displayName="Textarea",exports.Badge=Badge,exports.Input=Input,exports.Label=Label,exports.Select=Select,exports.SelectContent=SelectContent,exports.SelectGroup=SelectGroup,exports.SelectItem=SelectItem,exports.SelectLabel=SelectLabel,exports.SelectTrigger=SelectTrigger,exports.SelectValue=SelectValue,exports.Switch=Switch,exports.Textarea=Textarea;
@@ -0,0 +1 @@
1
+ var k=Object.defineProperty;var c=(e,r)=>k(e,"name",{value:r,configurable:!0});import{cn as i}from"./chunk-ULCTAAJ2.js";import{cva as u}from"class-variance-authority";import*as n from"react";import{jsx as t,jsxs as d}from"react/jsx-runtime";import*as m from"@radix-ui/react-label";import*as o from"@radix-ui/react-select";import{ChevronDown as p,ChevronUp as I,Check as B}from"lucide-react";import*as l from"@radix-ui/react-switch";var C=u("inline-flex items-center rounded px-1.5 py-0.5 text-[11px] font-medium transition-colors focus:outline-none focus:ring-1 focus:ring-ring",{variants:{variant:{default:"border-transparent bg-primary text-primary-foreground",secondary:"border-transparent bg-secondary text-secondary-foreground",destructive:"border-transparent bg-destructive text-destructive-foreground",outline:"border border-border text-foreground",success:"border-transparent bg-success/10 text-success",warning:"border-transparent bg-warning/10 text-warning"}},defaultVariants:{variant:"default"}});function T({className:e,variant:r,...a}){return t("div",{className:i(C({variant:r}),e),...a})}c(T,"Badge");var f=n.forwardRef(({className:e,type:r,...a},s)=>t("input",{type:r,className:i("flex h-9 w-full rounded-md border border-input bg-background px-3 py-2 text-sm ring-offset-background transition-colors duration-100 file:border-0 file:bg-transparent file:text-sm file:font-medium placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50",e),ref:s,...a}));f.displayName="Input";var j=u("text-[13px] font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"),b=n.forwardRef(({className:e,...r},a)=>t(m.Root,{ref:a,className:i(j(),e),...r}));b.displayName=m.Root.displayName;var V=o.Root,L=o.Group,D=o.Value,g=n.forwardRef(({className:e,children:r,...a},s)=>d(o.Trigger,{ref:s,className:i("flex h-8 w-full items-center justify-between rounded-md border border-input bg-background px-2.5 py-1.5 text-[13px] ring-offset-background transition-colors duration-100 placeholder:text-muted-foreground focus:outline-none focus:ring-1 focus:ring-ring disabled:cursor-not-allowed disabled:opacity-50 [&>span]:line-clamp-1",e),...a,children:[r,t(o.Icon,{asChild:!0,children:t(p,{className:"h-3.5 w-3.5 opacity-50"})})]}));g.displayName=o.Trigger.displayName;var x=n.forwardRef(({className:e,...r},a)=>t(o.ScrollUpButton,{ref:a,className:i("flex cursor-default items-center justify-center py-1",e),...r,children:t(I,{className:"h-4 w-4"})}));x.displayName=o.ScrollUpButton.displayName;var v=n.forwardRef(({className:e,...r},a)=>t(o.ScrollDownButton,{ref:a,className:i("flex cursor-default items-center justify-center py-1",e),...r,children:t(p,{className:"h-4 w-4"})}));v.displayName=o.ScrollDownButton.displayName;var y=n.forwardRef(({className:e,children:r,position:a="popper",...s},R)=>t(o.Portal,{children:d(o.Content,{ref:R,className:i("relative z-50 max-h-96 min-w-[8rem] overflow-hidden rounded-md border border-border bg-popover text-popover-foreground shadow-elevation-2 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",a==="popper"&&"data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1",e),position:a,...s,children:[t(x,{}),t(o.Viewport,{className:i("p-1",a==="popper"&&"h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)]"),children:r}),t(v,{})]})}));y.displayName=o.Content.displayName;var h=n.forwardRef(({className:e,...r},a)=>t(o.Label,{ref:a,className:i("py-1.5 pl-8 pr-2 text-sm font-semibold",e),...r}));h.displayName=o.Label.displayName;var w=n.forwardRef(({className:e,children:r,...a},s)=>d(o.Item,{ref:s,className:i("relative flex w-full cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),...a,children:[t("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center",children:t(o.ItemIndicator,{children:t(B,{className:"h-4 w-4"})})}),t(o.ItemText,{children:r})]}));w.displayName=o.Item.displayName;var P=n.forwardRef(({className:e,...r},a)=>t(o.Separator,{ref:a,className:i("-mx-1 my-1 h-px bg-muted",e),...r}));P.displayName=o.Separator.displayName;var N=n.forwardRef(({className:e,...r},a)=>t(l.Root,{className:i("peer inline-flex h-5 w-9 shrink-0 cursor-pointer items-center rounded-full border-2 border-transparent transition-colors duration-100 focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-primary data-[state=unchecked]:bg-input",e),...r,ref:a,children:t(l.Thumb,{className:i("pointer-events-none block h-4 w-4 rounded-full bg-background shadow-sm ring-0 transition-transform data-[state=checked]:translate-x-4 data-[state=unchecked]:translate-x-0")})}));N.displayName=l.Root.displayName;var S=n.forwardRef(({className:e,...r},a)=>t("textarea",{className:i("flex min-h-[72px] w-full rounded-md border border-input bg-background px-2.5 py-2 text-[13px] ring-offset-background transition-colors duration-100 placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50",e),ref:a,...r}));S.displayName="Textarea";export{T as Badge,f as Input,b as Label,V as Select,y as SelectContent,L as SelectGroup,w as SelectItem,h as SelectLabel,g as SelectTrigger,D as SelectValue,N as Switch,S as Textarea};
@@ -0,0 +1 @@
1
+ import{cn as d}from"./chunk-ULCTAAJ2.js";import*as n from"react";import{jsx as m}from"react/jsx-runtime";var e=n.forwardRef(({className:r,...o},t)=>m("kbd",{ref:t,className:d("inline-flex h-5 min-w-5 items-center justify-center rounded border border-border bg-foreground/[0.08] px-1.5 font-sans text-[11px] font-medium leading-none text-muted-foreground",r),...o}));e.displayName="Kbd";export{e as Kbd};
@@ -0,0 +1 @@
1
+ "use strict";var q=Object.defineProperty;var r=(t,u)=>q(t,"name",{value:u,configurable:!0});var chunkYWPIPAUQ_cjs=require("./chunk-YWPIPAUQ.cjs"),PopoverPrimitive=require("@radix-ui/react-popover"),lucideReact=require("lucide-react"),React=require("react"),jsxRuntime=require("react/jsx-runtime");function _interopNamespace(t){if(t&&t.__esModule)return t;var u=Object.create(null);return t&&Object.keys(t).forEach(function(o){if(o!=="default"){var c=Object.getOwnPropertyDescriptor(t,o);Object.defineProperty(u,o,c.get?c:{enumerable:!0,get:r(function(){return t[o]},"get")})}}),u.default=t,Object.freeze(u)}r(_interopNamespace,"_interopNamespace");var PopoverPrimitive__namespace=_interopNamespace(PopoverPrimitive),React__namespace=_interopNamespace(React),normalizeTag=r(t=>t.trim().replace(/\s+/g," "),"normalizeTag"),dedupeTags=r(t=>{const u=new Set,o=[];for(const c of t){const i=normalizeTag(c);!i||u.has(i)||(u.add(i),o.push(i))}return o},"dedupeTags"),TagPickerInput=React__namespace.forwardRef(({className:t,value:u,onChange:o,suggestions:c=[],maxTags:i,maxTagLength:h=50,allowCustomValue:x=!0,placeholder:N,disabled:l,emptyText:P="No suggestions",customValueHint:k="Press Enter to add a custom tag",onFocus:C,onBlur:D,...R},T)=>{const[d,p]=React__namespace.useState(""),[O,a]=React__namespace.useState(!1),[v,j]=React__namespace.useState(!1),f=React__namespace.useRef(null),b=React__namespace.useRef(null);React__namespace.useImperativeHandle(T,()=>f.current);const s=React__namespace.useMemo(()=>dedupeTags(u),[u]),w=React__namespace.useMemo(()=>dedupeTags(c),[c]),g=React__namespace.useMemo(()=>{const e=normalizeTag(d).toLowerCase();return w.filter(n=>e?n.toLowerCase().includes(e):!0)},[d,w]),m=i===void 0||s.length<i,y=React__namespace.useCallback(e=>{const n=normalizeTag(e).slice(0,h);return!x||!n||!m?!1:s.includes(n)?(p(""),a(!1),!1):(o([...s,n]),p(""),a(!1),!0)},[x,m,h,s,o]),S=React__namespace.useCallback(e=>{o(s.filter(n=>n!==e)),f.current?.focus(),a(!0)},[s,o]),I=React__namespace.useCallback(e=>{s.includes(e)?o(s.filter(n=>n!==e)):m&&o([...s,e]),p(""),f.current?.focus(),a(!0)},[m,s,o]),_=React__namespace.useCallback(e=>{if(!l&&!(v||e.nativeEvent.isComposing)){if(e.key==="Escape"){e.preventDefault(),e.stopPropagation(),a(!1);return}(e.key==="Enter"||e.key===","||e.key==="Tab")&&d.trim()&&(e.preventDefault(),e.stopPropagation(),y(d))}},[y,l,d,v]),z=O&&!l&&g.length>0;return jsxRuntime.jsxs(PopoverPrimitive__namespace.Root,{open:z,onOpenChange:a,children:[jsxRuntime.jsx(PopoverPrimitive__namespace.Anchor,{asChild:!0,children:jsxRuntime.jsx("div",{className:"relative",children:jsxRuntime.jsxs("div",{className:chunkYWPIPAUQ_cjs.cn("flex min-h-11 w-full flex-wrap items-center gap-2 rounded-md border border-input bg-background px-3 py-2 text-sm ring-offset-background transition-colors duration-100 focus-within:ring-1 focus-within:ring-ring",l&&"cursor-not-allowed opacity-50",t),onClick:r(()=>{l||(f.current?.focus(),a(!0))},"onClick"),children:[s.map(e=>jsxRuntime.jsxs("span",{className:"inline-flex h-7 max-w-full items-center gap-1 rounded-md bg-muted px-2 text-xs font-medium text-foreground",children:[jsxRuntime.jsx("span",{className:"truncate",children:e}),!l&&jsxRuntime.jsx("button",{type:"button",className:"rounded-sm text-muted-foreground transition-colors hover:text-foreground",onMouseDown:r(n=>n.preventDefault(),"onMouseDown"),onClick:r(n=>{n.stopPropagation(),S(e)},"onClick"),"aria-label":`Remove ${e}`,children:jsxRuntime.jsx(lucideReact.X,{className:"h-3.5 w-3.5"})})]},e)),m&&jsxRuntime.jsx("input",{ref:f,value:d,disabled:l,className:"min-w-[120px] flex-1 bg-transparent text-sm outline-none placeholder:text-muted-foreground",placeholder:s.length===0?N:void 0,onFocus:r(e=>{a(!0),C?.(e)},"onFocus"),onBlur:r(e=>{b.current?.contains(e.relatedTarget)||a(!1),D?.(e)},"onBlur"),onCompositionStart:r(()=>j(!0),"onCompositionStart"),onCompositionEnd:r(e=>{j(!1),p(e.currentTarget.value),a(!0)},"onCompositionEnd"),onChange:r(e=>{p(e.target.value),a(!0)},"onChange"),onKeyDown:_,...R})]})})}),jsxRuntime.jsx(PopoverPrimitive__namespace.Portal,{children:jsxRuntime.jsx(PopoverPrimitive__namespace.Content,{ref:b,onBlur:r(e=>{!e.currentTarget.contains(e.relatedTarget)&&e.relatedTarget!==f.current&&a(!1)},"onBlur"),align:"start",sideOffset:6,onOpenAutoFocus:r(e=>e.preventDefault(),"onOpenAutoFocus"),onCloseAutoFocus:r(e=>e.preventDefault(),"onCloseAutoFocus"),className:"z-50 overflow-hidden rounded-md border border-border bg-popover text-popover-foreground shadow-elevation-2",style:{width:"var(--radix-popover-trigger-width)"},children:jsxRuntime.jsxs("div",{className:"max-h-64 overflow-y-auto p-1",children:[x&&jsxRuntime.jsx("div",{className:"border-b border-border px-3 py-2 text-xs text-muted-foreground",children:k}),g.length>0?g.map(e=>{const n=s.includes(e);return jsxRuntime.jsxs("button",{type:"button",className:"flex w-full items-center gap-2 rounded-sm px-3 py-2 text-left text-sm transition-colors hover:bg-accent hover:text-accent-foreground",onMouseDown:r(M=>M.preventDefault(),"onMouseDown"),onClick:r(()=>I(e),"onClick"),children:[jsxRuntime.jsx("span",{className:chunkYWPIPAUQ_cjs.cn("flex h-4 w-4 items-center justify-center text-muted-foreground",n&&"text-foreground"),children:n&&jsxRuntime.jsx(lucideReact.Check,{className:"h-4 w-4"})}),jsxRuntime.jsx("span",{className:"truncate",children:e})]},e)}):jsxRuntime.jsx("div",{className:"px-3 py-2 text-sm text-muted-foreground",children:P})]})})})]})});TagPickerInput.displayName="TagPickerInput",exports.TagPickerInput=TagPickerInput;
@@ -0,0 +1 @@
1
+ import{cn as s}from"./chunk-ULCTAAJ2.js";import{Slot as u}from"@radix-ui/react-slot";import{cva as d}from"class-variance-authority";import*as g from"react";import{jsx as b}from"react/jsx-runtime";var e=d("inline-flex items-center justify-center whitespace-nowrap rounded-md text-[13px] font-medium ring-offset-background transition-colors duration-100 focus-visible:outline-none focus-visible:ring-[3px] focus-visible:ring-ring/20 disabled:pointer-events-none disabled:opacity-50",{variants:{variant:{default:"bg-action text-action-foreground hover:bg-action/90 active:bg-action/80",destructive:"bg-destructive text-destructive-foreground hover:bg-destructive/90 active:bg-destructive/80",outline:"border border-input bg-background hover:bg-accent hover:text-accent-foreground active:bg-accent/80",secondary:"bg-secondary text-secondary-foreground hover:bg-secondary/80 active:bg-secondary/70",ghost:"hover:bg-accent hover:text-accent-foreground active:bg-accent/80 focus-visible:bg-accent focus-visible:text-accent-foreground focus-visible:ring-0",link:"text-primary underline-offset-4 hover:underline focus-visible:underline focus-visible:ring-0",gradient:"bg-action text-action-foreground hover:bg-action/90 active:bg-action/80",success:"bg-success text-success-foreground hover:bg-success/90 active:bg-success/80",warning:"bg-warning text-warning-foreground hover:bg-warning/90 active:bg-warning/80"},size:{default:"h-9 px-4 py-2",sm:"h-8 rounded px-3 text-xs",lg:"h-10 rounded-md px-5",icon:"h-9 w-9",xs:"h-7 px-2.5 text-xs rounded"}},defaultVariants:{variant:"default",size:"default"}}),t=g.forwardRef(({className:r,variant:o,size:n,asChild:i=!1,...c},a)=>b(i?u:"button",{className:s(e({variant:o,size:n,className:r})),ref:a,...c}));t.displayName="Button";export{t as Button,e as buttonVariants};
@@ -0,0 +1 @@
1
+ var i=Object.defineProperty;var a=(e,r)=>i(e,"name",{value:r,configurable:!0});var l=Object.defineProperty,o=a((e,r,t)=>r in e?l(e,r,{enumerable:!0,configurable:!0,writable:!0,value:t}):e[r]=t,"__defNormalProp"),p=a((e,r,t)=>o(e,typeof r!="symbol"?r+"":r,t),"__publicField");export{p as __publicField};
@@ -0,0 +1 @@
1
+ "use strict";var c=Object.defineProperty;var n=(e,r)=>c(e,"name",{value:r,configurable:!0});var chunkYWPIPAUQ_cjs=require("./chunk-YWPIPAUQ.cjs"),React=require("react"),jsxRuntime=require("react/jsx-runtime");function _interopNamespace(e){if(e&&e.__esModule)return e;var r=Object.create(null);return e&&Object.keys(e).forEach(function(t){if(t!=="default"){var a=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(r,t,a.get?a:{enumerable:!0,get:n(function(){return e[t]},"get")})}}),r.default=e,Object.freeze(r)}n(_interopNamespace,"_interopNamespace");var React__namespace=_interopNamespace(React),Kbd=React__namespace.forwardRef(({className:e,...r},t)=>jsxRuntime.jsx("kbd",{ref:t,className:chunkYWPIPAUQ_cjs.cn("inline-flex h-5 min-w-5 items-center justify-center rounded border border-border bg-foreground/[0.08] px-1.5 font-sans text-[11px] font-medium leading-none text-muted-foreground",e),...r}));Kbd.displayName="Kbd",exports.Kbd=Kbd;
@@ -0,0 +1 @@
1
+ import{cn as a}from"./chunk-ULCTAAJ2.js";import{cva as v}from"class-variance-authority";import*as s from"react";import{jsx as i}from"react/jsx-runtime";var g=v("relative w-full rounded-md border px-3 py-2.5 text-[13px] [&>svg+div]:translate-y-[-2px] [&>svg]:absolute [&>svg]:left-3 [&>svg]:top-3 [&>svg]:h-3.5 [&>svg]:w-3.5 [&>svg]:text-foreground [&>svg~*]:pl-6",{variants:{variant:{default:"bg-background text-foreground",destructive:"border-destructive/50 text-destructive [&>svg]:text-destructive",warning:"border-warning/50 text-warning [&>svg]:text-warning",info:"border-info/50 text-info [&>svg]:text-info",success:"border-success/50 text-success [&>svg]:text-success"}},defaultVariants:{variant:"default"}}),o=s.forwardRef(({className:e,variant:t,...r},l)=>i("div",{ref:l,role:"alert",className:a(g({variant:t}),e),...r}));o.displayName="Alert";var d=s.forwardRef(({className:e,...t},r)=>i("h5",{ref:r,className:a("mb-1 font-medium leading-none tracking-tight",e),...t}));d.displayName="AlertTitle";var n=s.forwardRef(({className:e,...t},r)=>i("div",{ref:r,className:a("text-[13px] [&_p]:leading-relaxed",e),...t}));n.displayName="AlertDescription";export{o as Alert,n as AlertDescription,d as AlertTitle};
@@ -0,0 +1 @@
1
+ "use strict";var p=Object.defineProperty;var m=(l,t)=>p(l,"name",{value:t,configurable:!0});var chunkERURJLNK_cjs=require("./chunk-ERURJLNK.cjs"),chunkYWPIPAUQ_cjs=require("./chunk-YWPIPAUQ.cjs"),jsxRuntime=require("react/jsx-runtime");function SummaryTrendChart({data:l,label:t,className:i}){const o=Math.max(1,...l.flatMap(e=>e.values)),a=m(e=>35+e*530/Math.max(1,l.length-1),"x"),n=m(e=>180-e/o*150,"y");return jsxRuntime.jsxs("figure",{className:chunkYWPIPAUQ_cjs.cn("w-full",i),"aria-label":t,children:[jsxRuntime.jsxs("svg",{viewBox:"0 0 600 225",role:"img","aria-label":t,className:"h-auto w-full text-primary",children:[[0,.5,1].map(e=>jsxRuntime.jsx("line",{x1:"35",x2:"565",y1:n(e*o),y2:n(e*o),className:"stroke-border"},e)),[0,1].map(e=>jsxRuntime.jsx("polyline",{fill:"none",stroke:"currentColor",strokeWidth:"2.5",strokeDasharray:e?"6 4":void 0,opacity:e?.55:1,points:l.map((c,s)=>`${a(s)},${n(c.values[e]??0)}`).join(" ")},e)),l.map((e,c)=>jsxRuntime.jsx("text",{x:a(c),y:"210",textAnchor:"middle",fontSize:"12",className:"fill-muted-foreground",children:e.label},e.label))]}),jsxRuntime.jsx("ul",{className:"sr-only",children:l.map(e=>jsxRuntime.jsxs("li",{children:[e.label,": ",e.values.join(" / ")]},e.label))})]})}m(SummaryTrendChart,"SummaryTrendChart");function SummaryDistributionChart({data:l,label:t}){const i=l.reduce((a,n)=>a+n.value,0);let o=0;return jsxRuntime.jsxs("svg",{viewBox:"0 0 120 120",role:"img","aria-label":t,className:"mx-auto h-40 w-40 text-primary",children:[jsxRuntime.jsx("circle",{cx:"60",cy:"60",r:"42",fill:"none",strokeWidth:"16",className:"stroke-muted"}),l.map((a,n)=>{const e=i?a.value/i*264:0,c=o;return o+=e,jsxRuntime.jsx("circle",{cx:"60",cy:"60",r:"42",fill:"none",stroke:"currentColor",strokeWidth:"16",opacity:1-n/Math.max(l.length,1)*.65,strokeDasharray:`${e} ${264-e}`,strokeDashoffset:-c,transform:"rotate(-90 60 60)",children:jsxRuntime.jsxs("title",{children:[a.label,": ",a.value]})},a.label)})]})}m(SummaryDistributionChart,"SummaryDistributionChart");var tones={primary:"bg-primary",success:"bg-success",warning:"bg-warning",destructive:"bg-destructive",accent:"bg-chart-6"};function SummaryBarChart({data:l,series:t,label:i,maximum:o,unit:a="",missingLabel:n,className:e}){const c=o??Math.max(1,...l.flatMap(r=>r.values.map(u=>u??0))),s=m(r=>r===null?n:`${r.toLocaleString()}${a}`,"format");return jsxRuntime.jsx(chunkERURJLNK_cjs.TooltipProvider,{children:jsxRuntime.jsxs("figure",{"aria-label":i,className:chunkYWPIPAUQ_cjs.cn("space-y-4",e),children:[jsxRuntime.jsx("figcaption",{className:"sr-only",children:i}),jsxRuntime.jsx("ul",{className:"flex flex-wrap gap-x-4 gap-y-2 text-xs text-muted-foreground",children:t.map(r=>jsxRuntime.jsxs("li",{className:"flex items-center gap-1.5",children:[jsxRuntime.jsx("span",{"aria-hidden":!0,className:chunkYWPIPAUQ_cjs.cn("size-2.5 rounded-sm",tones[r.tone])}),r.label]},r.key))}),jsxRuntime.jsx("div",{className:"grid gap-5 lg:grid-cols-2",children:l.map(r=>jsxRuntime.jsxs("div",{className:"min-w-0 space-y-2",children:[jsxRuntime.jsx("p",{className:"break-words text-sm font-medium",children:r.label}),t.map((u,d)=>{const x=r.values[d]??null,h=`${r.label} \xB7 ${u.label}: ${s(x)}`;return jsxRuntime.jsxs("div",{className:"grid grid-cols-[7rem_minmax(0,1fr)_3.5rem] items-center gap-2 text-xs",children:[jsxRuntime.jsx("span",{className:"text-muted-foreground",children:u.label}),jsxRuntime.jsxs(chunkERURJLNK_cjs.Tooltip,{children:[jsxRuntime.jsx(chunkERURJLNK_cjs.TooltipTrigger,{asChild:!0,children:jsxRuntime.jsxs("div",{tabIndex:0,role:"img","aria-label":h,className:"relative h-4 rounded bg-muted/60 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",children:[x!==null&&x>0&&jsxRuntime.jsx("div",{"aria-hidden":!0,className:chunkYWPIPAUQ_cjs.cn("h-full rounded",tones[u.tone]),style:{width:`${Math.min(100,Math.max(0,x/c*100))}%`}}),x===null&&jsxRuntime.jsx("span",{"aria-hidden":!0,className:"absolute inset-0 text-center text-muted-foreground",children:"\u2014"})]})}),jsxRuntime.jsx(chunkERURJLNK_cjs.TooltipContent,{children:h})]}),jsxRuntime.jsx("span",{className:"text-right tabular-nums",children:s(x)})]},u.key)}),jsxRuntime.jsxs("div",{"aria-hidden":!0,className:"ml-[7.5rem] mr-[4rem] flex justify-between text-[10px] text-muted-foreground",children:[jsxRuntime.jsxs("span",{children:["0",a]}),jsxRuntime.jsxs("span",{children:[c.toLocaleString(),a]})]})]},r.key))})]})})}m(SummaryBarChart,"SummaryBarChart");function SummaryPieChart({data:l,label:t,emptyLabel:i}){const o=l.reduce((a,n)=>a+n.value,0);return jsxRuntime.jsxs("figure",{"aria-label":t,className:"space-y-4",children:[jsxRuntime.jsx("figcaption",{className:"sr-only",children:t}),o>0?jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(SummaryDistributionChart,{data:l,label:t}),jsxRuntime.jsx("ul",{className:"space-y-2 text-sm",children:l.map((a,n)=>jsxRuntime.jsxs("li",{className:"flex items-center gap-2",children:[jsxRuntime.jsx("span",{"aria-hidden":!0,className:"size-2.5 rounded-sm bg-primary",style:{opacity:1-n/l.length*.65}}),jsxRuntime.jsx("span",{className:"flex-1",children:a.label}),jsxRuntime.jsxs("span",{className:"tabular-nums",children:[a.value.toLocaleString()," \xB7"," ",(a.value/o*100).toFixed(1),"%"]})]},a.label))})]}):jsxRuntime.jsx("p",{className:"py-16 text-center text-sm text-muted-foreground",children:i})]})}m(SummaryPieChart,"SummaryPieChart");var colors={primary:"stroke-primary",success:"stroke-success",warning:"stroke-warning",destructive:"stroke-destructive",accent:"stroke-chart-6"},fills={primary:"bg-primary",success:"bg-success",warning:"bg-warning",destructive:"bg-destructive",accent:"bg-chart-6"};function SummaryLineChart({data:l,series:t,label:i,missingLabel:o}){const a=Math.max(0,...l.flatMap(s=>s.values.map(r=>r??0))),n=Math.max(2,Math.ceil(a/2)*2),e=m(s=>55+s*530/Math.max(1,l.length-1),"x"),c=m(s=>200-s/n*165,"y");return jsxRuntime.jsxs("figure",{"aria-label":i,className:"space-y-3",children:[jsxRuntime.jsx("figcaption",{className:"sr-only",children:i}),jsxRuntime.jsx("ul",{className:"flex flex-wrap gap-4 text-xs text-muted-foreground",children:t.map(s=>jsxRuntime.jsxs("li",{className:"flex items-center gap-1.5",children:[jsxRuntime.jsx("span",{"aria-hidden":!0,className:`size-2.5 rounded-sm ${fills[s.tone]}`}),s.label]},s.key))}),jsxRuntime.jsxs("svg",{viewBox:"0 0 640 250",role:"img","aria-label":i,className:"h-auto w-full",children:[[0,.5,1].map(s=>jsxRuntime.jsxs("g",{children:[jsxRuntime.jsx("line",{x1:"55",x2:"585",y1:c(n*s),y2:c(n*s),className:"stroke-border"}),jsxRuntime.jsx("text",{x:"45",y:c(n*s)+6,textAnchor:"end",fontSize:"18",className:"fill-muted-foreground",children:(n*s).toLocaleString()})]},s)),t.map((s,r)=>jsxRuntime.jsx("g",{className:colors[s.tone],children:l.map((u,d)=>{const x=u.values[r]??null,h=l[d-1]?.values[r]??null;return x===null?null:jsxRuntime.jsxs("g",{children:[h!==null&&jsxRuntime.jsx("line",{x1:e(d-1),y1:c(h),x2:e(d),y2:c(x),strokeWidth:"3"}),jsxRuntime.jsx("circle",{cx:e(d),cy:c(x),r:"4.5",className:"fill-background",strokeWidth:"3",children:jsxRuntime.jsxs("title",{children:[u.detail??u.label," \xB7 ",s.label,": ",x]})})]},u.label)})},s.key)),l.map((s,r)=>jsxRuntime.jsx("text",{x:e(r),y:"236",textAnchor:"middle",fontSize:"18",className:"fill-muted-foreground",children:s.label},s.label))]}),jsxRuntime.jsx("ul",{className:"sr-only",children:l.map(s=>jsxRuntime.jsxs("li",{children:[s.label,":"," ",t.map((r,u)=>`${r.label} ${s.values[u]??o}`).join("; ")]},s.label))})]})}m(SummaryLineChart,"SummaryLineChart"),exports.SummaryBarChart=SummaryBarChart,exports.SummaryDistributionChart=SummaryDistributionChart,exports.SummaryLineChart=SummaryLineChart,exports.SummaryPieChart=SummaryPieChart,exports.SummaryTrendChart=SummaryTrendChart;
@@ -0,0 +1 @@
1
+ var e=Object.defineProperty;var o=(r,t)=>e(r,"name",{value:t,configurable:!0});import{clsx as m}from"clsx";import{twMerge as n}from"tailwind-merge";function c(...r){return n(m(r))}o(c,"cn");export{c as cn};
@@ -0,0 +1 @@
1
+ "use strict";var d=Object.defineProperty;var e=(t,r)=>d(t,"name",{value:r,configurable:!0});var clsx=require("clsx"),tailwindMerge=require("tailwind-merge"),typography={heading1:"text-lg font-semibold tracking-tight",heading2:"text-[15px] font-medium leading-tight",body:"text-sm",bodyMedium:"text-sm font-medium",bodyBold:"text-sm font-semibold",small:"text-[13px]",smallMedium:"text-[13px] font-medium",caption:"text-xs",captionMuted:"text-xs text-muted-foreground"},spacing={xs:{y:"space-y-1.5",x:"space-x-1.5",gap:"gap-1.5",p:"p-1.5",px:"px-2",py:"py-1.5",pt:"pt-1.5",pb:"pb-1.5",pl:"pl-1.5",pr:"pr-1.5",mx:"mx-1.5",my:"my-1.5",ml:"ml-1.5",mr:"mr-1.5",mt:"mt-1.5",mb:"mb-1.5",left:"left-1.5",right:"right-1.5",top:"top-1.5",bottom:"bottom-1.5"},sm:{y:"space-y-3",x:"space-x-3",gap:"gap-3",p:"p-3",px:"px-3",py:"py-2",pt:"pt-3",pb:"pb-3",pl:"pl-3",pr:"pr-3",mx:"mx-3",my:"my-3",ml:"ml-3",mr:"mr-3",mt:"mt-3",mb:"mb-3",left:"left-3",right:"right-3",top:"top-3",bottom:"bottom-3"},md:{y:"space-y-4",x:"space-x-4",gap:"gap-4",p:"p-4",px:"px-4",py:"py-3",pt:"pt-4",pb:"pb-4",pl:"pl-4",pr:"pr-4",mx:"mx-4",my:"my-4",ml:"ml-4",mr:"mr-4",mt:"mt-4",mb:"mb-4",left:"left-4",right:"right-4",top:"top-4",bottom:"bottom-4"},lg:{y:"space-y-5",x:"space-x-5",gap:"gap-5",p:"p-5",px:"px-5",py:"py-4",pt:"pt-5",pb:"pb-5",pl:"pl-5",pr:"pr-5",mx:"mx-5",my:"my-5",ml:"ml-5",mr:"mr-5",mt:"mt-5",mb:"mb-5",left:"left-5",right:"right-5",top:"top-5",bottom:"bottom-5"},xl:{y:"space-y-6",x:"space-x-6",gap:"gap-6",p:"p-6",px:"px-6",py:"py-5",pt:"pt-6",pb:"pb-6",pl:"pl-6",pr:"pr-6",mx:"mx-6",my:"my-6",ml:"ml-6",mr:"mr-6",mt:"mt-6",mb:"mb-6",left:"left-6",right:"right-6",top:"top-6",bottom:"bottom-6"}},radius={none:"rounded-none",sm:"rounded",md:"rounded-md",lg:"rounded-lg",full:"rounded-full"},shadows={none:"",sm:"shadow",md:"shadow-md",lg:"shadow-lg"},colors={primary:"bg-primary text-primary-foreground",primaryHover:"hover:bg-primary/90",primaryMuted:"bg-primary/10 text-primary",secondary:"bg-secondary text-secondary-foreground",secondaryHover:"hover:bg-secondary/80",success:"bg-success text-success-foreground",successHover:"hover:bg-success/90",successMuted:"bg-success/10 text-success",warning:"bg-warning text-warning-foreground",warningHover:"hover:bg-warning/90",warningMuted:"bg-warning/10 text-warning",destructive:"bg-destructive text-destructive-foreground",destructiveHover:"hover:bg-destructive/90",destructiveMuted:"bg-destructive/10 text-destructive",muted:"bg-muted text-muted-foreground",mutedHover:"hover:bg-muted/80",accent:"bg-accent text-accent-foreground",accentHover:"hover:bg-accent/80"},surfaces={base:"bg-background",raised:"bg-muted/30",hover:"hover:bg-muted/50",selected:"bg-muted/60",border:"border-border/60",divider:"bg-border/40"},chatBubbles={user:"border border-primary/20 bg-primary-soft text-foreground shadow-[0_10px_28px_-24px_hsl(var(--primary)/0.65)]"},transitions={fast:"transition-colors duration-100 ease-out",normal:"transition-all duration-150 ease-out",slow:"transition-all duration-200 ease-out"},interactions={hoverHighlight:"hover:bg-accent/50 transition-colors duration-100 ease-out",hoverShadow:"hover:shadow-sm transition-shadow duration-150 ease-out",clickable:"cursor-pointer active:scale-[0.98] active:opacity-90 transition-all duration-100 ease-out",cardHover:"hover:border-border/80 hover:shadow-sm transition-all duration-150 ease-out"},layout={container:"layout-responsive container-responsive",grid:{stats:"stats-grid",actions:"actions-grid",agents:"agents-grid",default:"grid-responsive"},card:"card-responsive"},states={disabled:"opacity-50 cursor-not-allowed",loading:"opacity-70 cursor-wait",error:"border-destructive bg-destructive/10",success:"border-success bg-success/10"};function combineTokens(...t){return t.filter(Boolean).join(" ")}e(combineTokens,"combineTokens");var breakpoints={sm:"640px",md:"768px",lg:"1024px",xl:"1280px","2xl":"1536px"},presets={pageTitle:combineTokens(typography.heading1,spacing.sm.y),sectionTitle:combineTokens(typography.heading2,spacing.xs.y),cardTitle:combineTokens(typography.bodyMedium),buttonPrimary:combineTokens(colors.primary,colors.primaryHover,transitions.fast),interactiveCard:combineTokens(layout.card,interactions.cardHover,radius.md),input:combineTokens("border border-input bg-background",radius.sm,spacing.sm.px,spacing.xs.py,transitions.fast)},designTokens={typography,spacing,radius,shadows,colors,surfaces,chatBubbles,transitions,interactions,layout,states,presets,breakpoints};function cn(...t){return tailwindMerge.twMerge(clsx.clsx(t))}e(cn,"cn");function getSpacing(t,r){return designTokens.spacing[t][r]}e(getSpacing,"getSpacing");function getTypography(t){return designTokens.typography[t]}e(getTypography,"getTypography");function getStateStyle(t){return designTokens.states[t]}e(getStateStyle,"getStateStyle");function buildCardClass(t){const{interactive:r=!1,shadow:s="sm",radius:o="lg",className:a}=t;return cn("border bg-card text-card-foreground",designTokens.radius[o],designTokens.shadows[s],r&&designTokens.interactions.cardHover,a)}e(buildCardClass,"buildCardClass");function buildButtonClass(t){const{variant:r="primary",size:s="md",className:o}=t,a="inline-flex items-center justify-center font-medium rounded-md",n={primary:designTokens.colors.primary+" "+designTokens.colors.primaryHover,secondary:designTokens.colors.secondary+" "+designTokens.colors.secondaryHover,destructive:designTokens.colors.destructive+" "+designTokens.colors.destructiveHover,ghost:"hover:bg-accent hover:text-accent-foreground",outline:"border border-input bg-background hover:bg-accent hover:text-accent-foreground"},i={sm:"h-7 px-2.5 text-xs",md:"h-8 px-3 py-1.5 text-[13px]",lg:"h-9 px-4"};return cn(a,n[r],i[s],designTokens.transitions.fast,o)}e(buildButtonClass,"buildButtonClass");function buildInputClass(t){const{error:r=!1,disabled:s=!1,className:o}=t;return cn("flex h-8 w-full rounded-md border border-input bg-background px-2.5 py-1.5","text-[13px] ring-offset-background","placeholder:text-muted-foreground","focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring","disabled:cursor-not-allowed disabled:opacity-50",designTokens.transitions.fast,r&&"border-destructive focus-visible:ring-destructive",s&&designTokens.states.disabled,o)}e(buildInputClass,"buildInputClass");function buildBadgeClass(t){const{variant:r="default",className:s}=t;return cn("inline-flex items-center rounded px-1.5 py-0.5 text-[11px] font-medium",{default:"bg-primary text-primary-foreground",secondary:"bg-secondary text-secondary-foreground",success:"bg-success/10 text-success",warning:"bg-warning/10 text-warning",destructive:"bg-destructive text-destructive-foreground",outline:"border border-border bg-background"}[r],s)}e(buildBadgeClass,"buildBadgeClass");function buildGridClass(t){return designTokens.layout.grid[t]}e(buildGridClass,"buildGridClass");function getContainerClass(){return designTokens.layout.container}e(getContainerClass,"getContainerClass");var iconSizes={xs:"h-3 w-3",sm:"h-4 w-4",md:"h-5 w-5",lg:"h-6 w-6",xl:"h-8 w-8","2xl":"h-10 w-10"};function getIconSize(t){return iconSizes[t]}e(getIconSize,"getIconSize");function getStatusColor(t){return{success:"text-success",active:"text-success",warning:"text-warning",pending:"text-warning",error:"text-destructive",inactive:"text-muted-foreground",disabled:"text-muted-foreground/60"}[t.toLowerCase()]??"text-muted-foreground"}e(getStatusColor,"getStatusColor");function getStatusBadgeVariant(t){return{success:"success",active:"success",warning:"warning",pending:"warning",error:"destructive",inactive:"secondary",disabled:"secondary"}[t.toLowerCase()]??"default"}e(getStatusBadgeVariant,"getStatusBadgeVariant");function buildTableClass(t){return cn("w-full caption-bottom text-sm",t?.className)}e(buildTableClass,"buildTableClass");var truncate={single:"truncate",double:"line-clamp-2",triple:"line-clamp-3"};function getTruncateClass(t){return truncate[t]}e(getTruncateClass,"getTruncateClass");var animations={fadeIn:"animate-in fade-in duration-200",fadeOut:"animate-out fade-out duration-200",slideInFromRight:"animate-in slide-in-from-right duration-300",slideInFromLeft:"animate-in slide-in-from-left duration-300",slideInFromTop:"animate-in slide-in-from-top duration-300",slideInFromBottom:"animate-in slide-in-from-bottom duration-300",spin:"animate-spin",pulse:"animate-pulse"};function getAnimation(t){return animations[t]}e(getAnimation,"getAnimation");var focusRing="focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2";function buildFocusableClass(t){return cn(focusRing,t)}e(buildFocusableClass,"buildFocusableClass");function buildSkeletonClass(t){return cn("animate-pulse rounded-md bg-muted",t)}e(buildSkeletonClass,"buildSkeletonClass"),exports.animations=animations,exports.breakpoints=breakpoints,exports.buildBadgeClass=buildBadgeClass,exports.buildButtonClass=buildButtonClass,exports.buildCardClass=buildCardClass,exports.buildFocusableClass=buildFocusableClass,exports.buildGridClass=buildGridClass,exports.buildInputClass=buildInputClass,exports.buildSkeletonClass=buildSkeletonClass,exports.buildTableClass=buildTableClass,exports.chatBubbles=chatBubbles,exports.cn=cn,exports.colors=colors,exports.combineTokens=combineTokens,exports.designTokens=designTokens,exports.focusRing=focusRing,exports.getAnimation=getAnimation,exports.getContainerClass=getContainerClass,exports.getIconSize=getIconSize,exports.getSpacing=getSpacing,exports.getStateStyle=getStateStyle,exports.getStatusBadgeVariant=getStatusBadgeVariant,exports.getStatusColor=getStatusColor,exports.getTruncateClass=getTruncateClass,exports.getTypography=getTypography,exports.iconSizes=iconSizes,exports.interactions=interactions,exports.layout=layout,exports.presets=presets,exports.radius=radius,exports.shadows=shadows,exports.spacing=spacing,exports.states=states,exports.surfaces=surfaces,exports.transitions=transitions,exports.truncate=truncate,exports.typography=typography;
@@ -0,0 +1 @@
1
+ "use strict";var t=Object.defineProperty;var r=(e,i)=>t(e,"name",{value:i,configurable:!0});var clsx=require("clsx"),tailwindMerge=require("tailwind-merge");function cn(...e){return tailwindMerge.twMerge(clsx.clsx(e))}r(cn,"cn"),exports.cn=cn;
@@ -0,0 +1 @@
1
+ "use strict";var x=Object.defineProperty;var d=(e,r)=>x(e,"name",{value:r,configurable:!0});var chunkRWEJPTVG_cjs=require("./chunk-RWEJPTVG.cjs"),chunkYWPIPAUQ_cjs=require("./chunk-YWPIPAUQ.cjs");require("./chunk-6HRT65AA.cjs");var DialogPrimitive=require("@radix-ui/react-dialog"),cmdk=require("cmdk"),lucideReact=require("lucide-react");require("react");var jsxRuntime=require("react/jsx-runtime");function _interopNamespace(e){if(e&&e.__esModule)return e;var r=Object.create(null);return e&&Object.keys(e).forEach(function(n){if(n!=="default"){var s=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(r,n,s.get?s:{enumerable:!0,get:d(function(){return e[n]},"get")})}}),r.default=e,Object.freeze(r)}d(_interopNamespace,"_interopNamespace");var DialogPrimitive__namespace=_interopNamespace(DialogPrimitive);function CommandPalette({open:e,onOpenChange:r,groups:n,title:s,placeholder:l,emptyText:u,footerHints:o,search:i,onSearchChange:c}){const m=n.filter(t=>t.items.length>0);return jsxRuntime.jsx(DialogPrimitive__namespace.Root,{open:e,onOpenChange:r,children:jsxRuntime.jsxs(DialogPrimitive__namespace.Portal,{children:[jsxRuntime.jsx(DialogPrimitive__namespace.Overlay,{className:"fixed inset-0 z-50 bg-overlay/30 backdrop-blur-[2px] data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0"}),jsxRuntime.jsxs(DialogPrimitive__namespace.Content,{"aria-describedby":void 0,className:"fixed left-1/2 top-[14vh] z-50 w-[min(620px,calc(100vw-2rem))] -translate-x-1/2 overflow-hidden rounded-container border border-hairline bg-popover text-popover-foreground shadow-elevation-4 duration-overlay data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-[0.98] data-[state=open]:zoom-in-[0.98]",children:[jsxRuntime.jsx(DialogPrimitive__namespace.Title,{className:"sr-only",children:s}),jsxRuntime.jsxs(cmdk.Command,{label:s,loop:!0,children:[jsxRuntime.jsxs("div",{className:"flex h-12 items-center gap-3 border-b border-hairline px-4",children:[jsxRuntime.jsx(lucideReact.Search,{className:"h-4 w-4 shrink-0 text-muted-foreground","aria-hidden":!0}),jsxRuntime.jsx(cmdk.Command.Input,{...i!==void 0&&{value:i},...c&&{onValueChange:c},placeholder:l,className:"h-full min-w-0 flex-1 bg-transparent text-sm outline-none placeholder:text-muted-foreground"}),jsxRuntime.jsx(chunkRWEJPTVG_cjs.Kbd,{children:"Esc"})]}),jsxRuntime.jsxs(cmdk.Command.List,{className:"max-h-[min(420px,60vh)] overflow-y-auto overscroll-contain p-1.5",children:[jsxRuntime.jsx(cmdk.Command.Empty,{className:"px-3 py-8 text-center text-sm text-muted-foreground",children:u}),m.map(t=>jsxRuntime.jsx(cmdk.Command.Group,{heading:t.heading,className:"py-1 [&_[cmdk-group-heading]]:px-2.5 [&_[cmdk-group-heading]]:pb-1 [&_[cmdk-group-heading]]:pt-1.5 [&_[cmdk-group-heading]]:text-[11px] [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:text-muted-foreground",children:t.items.map(a=>jsxRuntime.jsxs(cmdk.Command.Item,{value:`${t.id}:${a.id}`,keywords:[a.label,...a.keywords??[]],onSelect:d(()=>{r(!1),a.onSelect()},"onSelect"),className:chunkYWPIPAUQ_cjs.cn("flex h-9 cursor-pointer select-none items-center gap-3 rounded-control px-2.5 text-[13px] outline-none","data-[selected=true]:bg-accent data-[selected=true]:text-accent-foreground"),children:[jsxRuntime.jsx("span",{className:"flex w-4 shrink-0 justify-center text-muted-foreground [&>svg]:size-4","aria-hidden":!0,children:a.icon}),jsxRuntime.jsx("span",{className:"min-w-0 flex-1 truncate",children:a.label}),a.hint&&jsxRuntime.jsx("span",{className:"flex shrink-0 items-center gap-1 text-xs text-muted-foreground",children:a.hint})]},a.id))},t.id))]}),o&&o.length>0&&jsxRuntime.jsx("div",{className:"flex h-9 items-center gap-4 border-t border-hairline bg-sunken px-4 text-[11px] text-muted-foreground",children:o.map(t=>jsxRuntime.jsxs("span",{className:"flex items-center gap-1",children:[t.keys.map(a=>jsxRuntime.jsx(chunkRWEJPTVG_cjs.Kbd,{children:a},a)),t.label]},t.label))})]})]})]})})}d(CommandPalette,"CommandPalette"),exports.CommandPalette=CommandPalette;
@@ -0,0 +1,44 @@
1
+ import * as React from 'react';
2
+
3
+ interface CommandPaletteItem {
4
+ id: string;
5
+ label: string;
6
+ icon?: React.ReactNode;
7
+ /** Right side of the row: a shortcut, a status, a timestamp. */
8
+ hint?: React.ReactNode;
9
+ /** Extra words the filter matches on (pinyin, English name, id). */
10
+ keywords?: string[];
11
+ onSelect: () => void;
12
+ }
13
+ interface CommandPaletteGroup {
14
+ id: string;
15
+ heading: string;
16
+ items: CommandPaletteItem[];
17
+ }
18
+ interface CommandPaletteProps {
19
+ open: boolean;
20
+ onOpenChange: (open: boolean) => void;
21
+ groups: CommandPaletteGroup[];
22
+ /** Accessible name of the dialog. */
23
+ title: string;
24
+ placeholder: string;
25
+ emptyText: string;
26
+ /** Key hints in the footer, e.g. `[{ keys: ['↑', '↓'], label: 'Select' }]`. */
27
+ footerHints?: {
28
+ keys: string[];
29
+ label: string;
30
+ }[];
31
+ /** Controlled search text, for callers that query as the user types. */
32
+ search?: string;
33
+ onSearchChange?: (search: string) => void;
34
+ }
35
+ /**
36
+ * The ⌘K launcher: a search box over grouped actions, driven by the keyboard.
37
+ *
38
+ * Its own entry (`@tego/ui/command-palette`), not in the barrel: the host
39
+ * hands the barrel to plugins whole, so anything in it ships in the first
40
+ * paint, and the palette only loads when someone opens it.
41
+ */
42
+ declare function CommandPalette({ open, onOpenChange, groups, title, placeholder, emptyText, footerHints, search, onSearchChange, }: CommandPaletteProps): React.JSX.Element;
43
+
44
+ export { CommandPalette, type CommandPaletteGroup, type CommandPaletteItem, type CommandPaletteProps };
@@ -0,0 +1,44 @@
1
+ import * as React from 'react';
2
+
3
+ interface CommandPaletteItem {
4
+ id: string;
5
+ label: string;
6
+ icon?: React.ReactNode;
7
+ /** Right side of the row: a shortcut, a status, a timestamp. */
8
+ hint?: React.ReactNode;
9
+ /** Extra words the filter matches on (pinyin, English name, id). */
10
+ keywords?: string[];
11
+ onSelect: () => void;
12
+ }
13
+ interface CommandPaletteGroup {
14
+ id: string;
15
+ heading: string;
16
+ items: CommandPaletteItem[];
17
+ }
18
+ interface CommandPaletteProps {
19
+ open: boolean;
20
+ onOpenChange: (open: boolean) => void;
21
+ groups: CommandPaletteGroup[];
22
+ /** Accessible name of the dialog. */
23
+ title: string;
24
+ placeholder: string;
25
+ emptyText: string;
26
+ /** Key hints in the footer, e.g. `[{ keys: ['↑', '↓'], label: 'Select' }]`. */
27
+ footerHints?: {
28
+ keys: string[];
29
+ label: string;
30
+ }[];
31
+ /** Controlled search text, for callers that query as the user types. */
32
+ search?: string;
33
+ onSearchChange?: (search: string) => void;
34
+ }
35
+ /**
36
+ * The ⌘K launcher: a search box over grouped actions, driven by the keyboard.
37
+ *
38
+ * Its own entry (`@tego/ui/command-palette`), not in the barrel: the host
39
+ * hands the barrel to plugins whole, so anything in it ships in the first
40
+ * paint, and the palette only loads when someone opens it.
41
+ */
42
+ declare function CommandPalette({ open, onOpenChange, groups, title, placeholder, emptyText, footerHints, search, onSearchChange, }: CommandPaletteProps): React.JSX.Element;
43
+
44
+ export { CommandPalette, type CommandPaletteGroup, type CommandPaletteItem, type CommandPaletteProps };
@@ -0,0 +1 @@
1
+ var b=Object.defineProperty;var s=(l,d)=>b(l,"name",{value:d,configurable:!0});import{Kbd as u}from"./chunk-NA5M3B4G.js";import{cn as v}from"./chunk-ULCTAAJ2.js";import"./chunk-QPXIAUJD.js";import*as o from"@radix-ui/react-dialog";import{Command as n}from"cmdk";import{Search as N}from"lucide-react";import"react";import{jsx as e,jsxs as r}from"react/jsx-runtime";function k({open:l,onOpenChange:d,groups:h,title:c,placeholder:x,emptyText:f,footerHints:i,search:m,onSearchChange:p}){const g=h.filter(a=>a.items.length>0);return e(o.Root,{open:l,onOpenChange:d,children:r(o.Portal,{children:[e(o.Overlay,{className:"fixed inset-0 z-50 bg-overlay/30 backdrop-blur-[2px] data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0"}),r(o.Content,{"aria-describedby":void 0,className:"fixed left-1/2 top-[14vh] z-50 w-[min(620px,calc(100vw-2rem))] -translate-x-1/2 overflow-hidden rounded-container border border-hairline bg-popover text-popover-foreground shadow-elevation-4 duration-overlay data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-[0.98] data-[state=open]:zoom-in-[0.98]",children:[e(o.Title,{className:"sr-only",children:c}),r(n,{label:c,loop:!0,children:[r("div",{className:"flex h-12 items-center gap-3 border-b border-hairline px-4",children:[e(N,{className:"h-4 w-4 shrink-0 text-muted-foreground","aria-hidden":!0}),e(n.Input,{...m!==void 0&&{value:m},...p&&{onValueChange:p},placeholder:x,className:"h-full min-w-0 flex-1 bg-transparent text-sm outline-none placeholder:text-muted-foreground"}),e(u,{children:"Esc"})]}),r(n.List,{className:"max-h-[min(420px,60vh)] overflow-y-auto overscroll-contain p-1.5",children:[e(n.Empty,{className:"px-3 py-8 text-center text-sm text-muted-foreground",children:f}),g.map(a=>e(n.Group,{heading:a.heading,className:"py-1 [&_[cmdk-group-heading]]:px-2.5 [&_[cmdk-group-heading]]:pb-1 [&_[cmdk-group-heading]]:pt-1.5 [&_[cmdk-group-heading]]:text-[11px] [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:text-muted-foreground",children:a.items.map(t=>r(n.Item,{value:`${a.id}:${t.id}`,keywords:[t.label,...t.keywords??[]],onSelect:s(()=>{d(!1),t.onSelect()},"onSelect"),className:v("flex h-9 cursor-pointer select-none items-center gap-3 rounded-control px-2.5 text-[13px] outline-none","data-[selected=true]:bg-accent data-[selected=true]:text-accent-foreground"),children:[e("span",{className:"flex w-4 shrink-0 justify-center text-muted-foreground [&>svg]:size-4","aria-hidden":!0,children:t.icon}),e("span",{className:"min-w-0 flex-1 truncate",children:t.label}),t.hint&&e("span",{className:"flex shrink-0 items-center gap-1 text-xs text-muted-foreground",children:t.hint})]},t.id))},a.id))]}),i&&i.length>0&&e("div",{className:"flex h-9 items-center gap-4 border-t border-hairline bg-sunken px-4 text-[11px] text-muted-foreground",children:i.map(a=>r("span",{className:"flex items-center gap-1",children:[a.keys.map(t=>e(u,{children:t},t)),a.label]},a.label))})]})]})]})})}s(k,"CommandPalette");export{k as CommandPalette};
@@ -0,0 +1 @@
1
+ "use strict";var y=Object.defineProperty;var c=(r,s)=>y(r,"name",{value:s,configurable:!0});var chunkMTA2XHQG_cjs=require("../chunk-MTA2XHQG.cjs"),chunkM2GCF4FZ_cjs=require("../chunk-M2GCF4FZ.cjs"),chunkYWPIPAUQ_cjs=require("../chunk-YWPIPAUQ.cjs");require("../chunk-6HRT65AA.cjs");var lucideReact=require("lucide-react"),react=require("react"),jsxRuntime=require("react/jsx-runtime"),CONFIG_FORM_SECRET_SENTINEL="__OPENCLAW_REDACTED__",DEFAULT_LABELS={advanced:"Advanced",empty:"This section has no settings.",required:"Required",secretStored:"A value is stored. Leave this untouched to keep it.",addItem:"Add",rawJson:"This field is edited as JSON.",invalidJson:"Not valid JSON \u2014 the last valid value is kept."};function orderFields(r,s){const l=new Set(r.required??[]);return Object.entries(r.properties??{}).map(([a,e],i)=>{const t=s[a]??{};return{name:a,schema:e,hint:t,required:l.has(a),advanced:t.advanced===!0,sortKey:[t.order??Number.MAX_SAFE_INTEGER,i]}}).sort((a,e)=>a.sortKey[0]-e.sortKey[0]||a.sortKey[1]-e.sortKey[1]).map(({sortKey:a,...e})=>e)}c(orderFields,"orderFields");function isRenderable(r){if(r.enum)return!0;switch(r.type){case"string":case"number":case"integer":case"boolean":return!0;case"array":return r.items?.type==="string";default:return!1}}c(isRenderable,"isRenderable");function ConfigForm({schema:r,hints:s={},values:l,onChange:u,disabled:a=!1,errors:e={},labels:i,renderFieldAction:t,className:d}){const o={...DEFAULT_LABELS,...i},[x,p]=react.useState(!1),n=react.useMemo(()=>r?orderFields(r,s):[],[r,s]);if(n.length===0)return jsxRuntime.jsx("p",{className:chunkYWPIPAUQ_cjs.cn("py-6 text-center text-sm text-muted-foreground",d),children:o.empty});const h=n.filter(m=>!m.advanced),f=n.filter(m=>m.advanced),g=c((m,j)=>{const v={...l};j===void 0?delete v[m]:v[m]=j,u(v)},"patch"),N=c(m=>jsxRuntime.jsx(ConfigField,{field:m,value:l[m.name],error:e[m.name],disabled:a,labels:o,action:t?.(m.name),onChange:c(j=>g(m.name,j),"onChange")},m.name),"renderField");return jsxRuntime.jsxs("div",{className:chunkYWPIPAUQ_cjs.cn("space-y-1",d),children:[h.map(N),f.length>0&&jsxRuntime.jsxs("div",{className:"pt-2",children:[jsxRuntime.jsxs("button",{type:"button",className:"flex items-center gap-1.5 text-xs text-muted-foreground transition-colors hover:text-foreground",onClick:c(()=>p(m=>!m),"onClick"),children:[jsxRuntime.jsx(lucideReact.ChevronDown,{className:chunkYWPIPAUQ_cjs.cn("h-3.5 w-3.5 transition-transform",x&&"rotate-180")}),o.advanced,jsxRuntime.jsxs("span",{className:"opacity-60",children:["(",f.length,")"]})]}),x&&jsxRuntime.jsx("div",{className:"mt-1 space-y-1",children:f.map(N)})]})]})}c(ConfigForm,"ConfigForm");function ConfigField({field:r,value:s,error:l,disabled:u,labels:a,action:e,onChange:i}){const{name:t,schema:d,hint:o,required:x}=r,p=o.label??d.title??t,n=o.help??d.description;return jsxRuntime.jsxs("div",{className:"space-y-1.5 py-2",children:[jsxRuntime.jsxs("div",{className:"flex items-center gap-2",children:[jsxRuntime.jsx(chunkMTA2XHQG_cjs.Label,{className:"text-sm font-medium",children:p}),x&&jsxRuntime.jsx(chunkMTA2XHQG_cjs.Badge,{variant:"outline",className:"h-4 px-1 text-[10px] font-normal",children:a.required}),jsxRuntime.jsx("code",{className:"text-[11px] text-muted-foreground/70",children:t}),e&&jsxRuntime.jsx("div",{className:"ml-auto",children:e})]}),n&&jsxRuntime.jsx("p",{className:"text-xs text-muted-foreground",children:n}),jsxRuntime.jsx(ConfigInput,{field:r,value:s,disabled:u,labels:a,onChange:i}),l&&jsxRuntime.jsx("p",{className:"text-xs text-destructive",children:l})]})}c(ConfigField,"ConfigField");function ConfigInput({field:r,value:s,disabled:l,labels:u,onChange:a}){const{schema:e,hint:i}=r;if(!isRenderable(e))return jsxRuntime.jsx(JsonField,{value:s,disabled:l,labels:u,onChange:a});if(e.enum)return jsxRuntime.jsxs(chunkMTA2XHQG_cjs.Select,{value:s==null?"":String(s),disabled:l,onValueChange:c(t=>a(e.type==="number"||e.type==="integer"?Number(t):t),"onValueChange"),children:[jsxRuntime.jsx(chunkMTA2XHQG_cjs.SelectTrigger,{className:"h-8 text-sm",children:jsxRuntime.jsx(chunkMTA2XHQG_cjs.SelectValue,{placeholder:i.placeholder??""})}),jsxRuntime.jsx(chunkMTA2XHQG_cjs.SelectContent,{children:e.enum.map(t=>jsxRuntime.jsx(chunkMTA2XHQG_cjs.SelectItem,{value:String(t),children:String(t)},String(t)))})]});if(e.type==="boolean"){const t=typeof s=="boolean"?s:typeof e.default=="boolean"?e.default:!1;return jsxRuntime.jsx(chunkMTA2XHQG_cjs.Switch,{checked:t,disabled:l,onCheckedChange:c(d=>a(d),"onCheckedChange")})}return e.type==="number"||e.type==="integer"?jsxRuntime.jsx(chunkMTA2XHQG_cjs.Input,{type:"number",className:"h-8 text-sm",disabled:l,placeholder:i.placeholder??defaultPlaceholder(e),value:s==null?"":String(s),min:e.minimum,max:e.maximum,onChange:c(t=>{const d=t.target.value;if(d===""){a(void 0);return}const o=Number(d);a(Number.isNaN(o)?d:o)},"onChange")}):e.type==="array"?jsxRuntime.jsx(StringListField,{value:s,disabled:l,labels:u,options:e.items?.enum,maxItems:e.maxItems,onChange:a}):i.sensitive?jsxRuntime.jsx(SecretField,{value:s,disabled:l,labels:u,placeholder:i.placeholder,onChange:a}):jsxRuntime.jsx(chunkMTA2XHQG_cjs.Input,{type:e.format==="email"?"email":"text",className:"h-8 text-sm",disabled:l,placeholder:i.placeholder??defaultPlaceholder(e),value:s==null?"":String(s),onChange:c(t=>a(t.target.value===""?void 0:t.target.value),"onChange")})}c(ConfigInput,"ConfigInput");function defaultPlaceholder(r){return r.default===void 0?"":String(r.default)}c(defaultPlaceholder,"defaultPlaceholder");function SecretField({value:r,disabled:s,labels:l,placeholder:u,onChange:a}){const[e,i]=react.useState(!1),t=r===CONFIG_FORM_SECRET_SENTINEL,d=r==null?"":String(r);return jsxRuntime.jsxs("div",{className:"space-y-1",children:[jsxRuntime.jsxs("div",{className:"flex items-center gap-2",children:[jsxRuntime.jsx(chunkMTA2XHQG_cjs.Input,{type:e&&!t?"text":"password",className:"h-8 text-sm",disabled:s,placeholder:u??"\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022",value:d,onFocus:c(()=>{t&&a(void 0)},"onFocus"),onChange:c(o=>a(o.target.value===""?void 0:o.target.value),"onChange")}),jsxRuntime.jsx(chunkM2GCF4FZ_cjs.Button,{type:"button",variant:"outline",size:"icon",className:"h-8 w-8 shrink-0 text-muted-foreground",disabled:s||t,onClick:c(()=>i(o=>!o),"onClick"),children:e?jsxRuntime.jsx(lucideReact.EyeOff,{className:"h-3.5 w-3.5"}):jsxRuntime.jsx(lucideReact.Eye,{className:"h-3.5 w-3.5"})})]}),t&&jsxRuntime.jsx("p",{className:"text-xs text-muted-foreground",children:l.secretStored})]})}c(SecretField,"SecretField");function StringListField({value:r,disabled:s,labels:l,options:u,maxItems:a,onChange:e}){const i=Array.isArray(r)?r.filter(n=>typeof n=="string"):[],[t,d]=react.useState(""),o=a!==void 0&&i.length>=a,x=c(n=>e(n.length===0?void 0:n),"commit");if(u)return jsxRuntime.jsx("div",{className:"flex flex-wrap gap-1.5",children:u.map(n=>{const h=i.includes(n);return jsxRuntime.jsx(chunkM2GCF4FZ_cjs.Button,{type:"button",size:"sm",variant:h?"default":"outline",className:"h-7 text-xs",disabled:s||!h&&o,onClick:c(()=>x(h?i.filter(f=>f!==n):[...i,n]),"onClick"),children:n},n)})});const p=c(()=>{const n=t.trim();n===""||i.includes(n)||(x([...i,n]),d(""))},"add");return jsxRuntime.jsxs("div",{className:"space-y-1.5",children:[i.length>0&&jsxRuntime.jsx("div",{className:"flex flex-wrap gap-1.5",children:i.map(n=>jsxRuntime.jsxs("span",{className:"inline-flex items-center gap-1 rounded-md bg-muted px-2 py-1 text-xs",children:[n,jsxRuntime.jsx("button",{type:"button",disabled:s,className:"text-muted-foreground transition-colors hover:text-destructive",onClick:c(()=>x(i.filter(h=>h!==n)),"onClick"),children:jsxRuntime.jsx(lucideReact.X,{className:"h-3 w-3"})})]},n))}),jsxRuntime.jsxs("div",{className:"flex items-center gap-2",children:[jsxRuntime.jsx(chunkMTA2XHQG_cjs.Input,{className:"h-8 text-sm",disabled:s||o,value:t,onChange:c(n=>d(n.target.value),"onChange"),onKeyDown:c(n=>{n.key==="Enter"&&(n.preventDefault(),p())},"onKeyDown")}),jsxRuntime.jsxs(chunkM2GCF4FZ_cjs.Button,{type:"button",variant:"outline",size:"sm",className:"h-8 shrink-0 text-xs",disabled:s||o||t.trim()==="",onClick:p,children:[jsxRuntime.jsx(lucideReact.Plus,{className:"mr-1 h-3.5 w-3.5"}),l.addItem]})]})]})}c(StringListField,"StringListField");function JsonField({value:r,disabled:s,labels:l,onChange:u}){const[a,e]=react.useState(()=>r===void 0?"":JSON.stringify(r,null,2)),[i,t]=react.useState(!0);return jsxRuntime.jsxs("div",{className:"space-y-1",children:[jsxRuntime.jsx(chunkMTA2XHQG_cjs.Textarea,{rows:4,spellCheck:!1,disabled:s,className:"font-mono text-xs",value:a,onChange:c(d=>{const o=d.target.value;if(e(o),o.trim()===""){t(!0),u(void 0);return}try{u(JSON.parse(o)),t(!0)}catch{t(!1)}},"onChange")}),jsxRuntime.jsx("p",{className:chunkYWPIPAUQ_cjs.cn("text-xs",i?"text-muted-foreground":"text-destructive"),children:i?l.rawJson:l.invalidJson})]})}c(JsonField,"JsonField"),exports.CONFIG_FORM_SECRET_SENTINEL=CONFIG_FORM_SECRET_SENTINEL,exports.ConfigForm=ConfigForm;