@kb-labs/studio-app 0.7.0 → 2.8.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 (175) hide show
  1. package/dist/index.html +1 -0
  2. package/dist/main.1d68e922.js +522 -0
  3. package/dist/main.1d68e922.js.map +1 -0
  4. package/dist/main.80b70197.css +2 -0
  5. package/dist/main.80b70197.css.map +1 -0
  6. package/dist/mf-manifest.json +241 -0
  7. package/dist/mf-stats.json +271 -0
  8. package/package.json +56 -39
  9. package/server.js +68 -0
  10. package/.env.example +0 -10
  11. package/UI-KIT-COMPONENTS.md +0 -783
  12. package/UI-KIT-PLAN.md +0 -326
  13. package/eslint-rules/no-direct-antd-import.js +0 -151
  14. package/eslint.config.ts +0 -27
  15. package/index.html +0 -17
  16. package/postcss.config.js +0 -7
  17. package/public/favicon.ico +0 -0
  18. package/rspack.config.mjs +0 -118
  19. package/src/App.tsx +0 -46
  20. package/src/components/devtools/devtools-log-feed.module.css +0 -165
  21. package/src/components/devtools/devtools-log-feed.tsx +0 -300
  22. package/src/components/devtools/devtools-panel.module.css +0 -121
  23. package/src/components/devtools/devtools-panel.tsx +0 -115
  24. package/src/components/empty-state.tsx +0 -28
  25. package/src/components/error-boundary.tsx +0 -210
  26. package/src/components/health-banner.module.css +0 -103
  27. package/src/components/health-banner.tsx +0 -134
  28. package/src/components/health-indicator.tsx +0 -12
  29. package/src/components/page-header.tsx +0 -49
  30. package/src/components/page-transition.tsx +0 -24
  31. package/src/components/role-switcher.tsx +0 -148
  32. package/src/components/run-badge.tsx +0 -13
  33. package/src/components/ui/icons.tsx +0 -509
  34. package/src/components/ui/index.ts +0 -25
  35. package/src/components/ui/kb-config-provider.tsx +0 -130
  36. package/src/components/ui/kb-header.module.css +0 -51
  37. package/src/components/ui/kb-header.tsx +0 -112
  38. package/src/components/ui/kb-notification-bell.module.css +0 -103
  39. package/src/components/ui/kb-notification-bell.tsx +0 -199
  40. package/src/components/ui/kb-page-layout.tsx +0 -66
  41. package/src/components/ui/kb-quick-search.module.css +0 -86
  42. package/src/components/ui/kb-quick-search.tsx +0 -196
  43. package/src/components/ui/kb-sidebar.module.css +0 -47
  44. package/src/components/ui/kb-sidebar.tsx +0 -196
  45. package/src/components/ui/kb-stat-card.module.css +0 -21
  46. package/src/components/ui/kb-stat-card.tsx +0 -22
  47. package/src/components/ui/kb-stat-grid.tsx +0 -22
  48. package/src/components/ui/kb-status-bar.module.css +0 -49
  49. package/src/components/ui/kb-status-bar.tsx +0 -145
  50. package/src/components/ui/kb-system-health-indicator.tsx +0 -229
  51. package/src/components/ui/kb-theme-toggle.tsx +0 -42
  52. package/src/components/ui/theme-adapter.ts +0 -812
  53. package/src/components/ui/theme-transition-overlay.tsx +0 -70
  54. package/src/components/ui/utils.ts +0 -6
  55. package/src/components/widget-error-boundary.tsx +0 -172
  56. package/src/config/env.ts +0 -5
  57. package/src/config/feature-flags.ts +0 -482
  58. package/src/config/studio.config.schema.ts +0 -88
  59. package/src/config/studio.config.ts +0 -84
  60. package/src/env.d.ts +0 -23
  61. package/src/hooks/use-command-palette.ts +0 -6
  62. package/src/hooks/use-devtools-store.ts +0 -25
  63. package/src/hooks/use-feature-flags.ts +0 -101
  64. package/src/index.css +0 -10
  65. package/src/layouts/dashboard-grid.tsx +0 -122
  66. package/src/layouts/index.ts +0 -12
  67. package/src/layouts/two-pane.tsx +0 -134
  68. package/src/main.tsx +0 -15
  69. package/src/modules/analytics/components/analytics-daily-stats-chart.tsx +0 -257
  70. package/src/modules/analytics/components/analytics-date-range-picker.tsx +0 -121
  71. package/src/modules/analytics/pages/analytics-cache-page.tsx +0 -285
  72. package/src/modules/analytics/pages/analytics-embeddings-page.tsx +0 -274
  73. package/src/modules/analytics/pages/analytics-events-page.tsx +0 -425
  74. package/src/modules/analytics/pages/analytics-llm-page.tsx +0 -434
  75. package/src/modules/analytics/pages/analytics-overview-page.tsx +0 -336
  76. package/src/modules/analytics/pages/analytics-page.tsx +0 -20
  77. package/src/modules/analytics/pages/analytics-storage-page.tsx +0 -344
  78. package/src/modules/analytics/pages/analytics-vectorstore-page.tsx +0 -279
  79. package/src/modules/analytics/routes/index.tsx +0 -133
  80. package/src/modules/analytics/utils/formatters.test.ts +0 -148
  81. package/src/modules/analytics/utils/formatters.ts +0 -100
  82. package/src/modules/auth/pages/login-page.module.css +0 -113
  83. package/src/modules/auth/pages/login-page.tsx +0 -80
  84. package/src/modules/auth/routes/index.tsx +0 -24
  85. package/src/modules/dashboard/components/ActivityTimelineWidget.tsx +0 -199
  86. package/src/modules/dashboard/components/AiInsightsWidget.tsx +0 -358
  87. package/src/modules/dashboard/components/AnimatedMetricCard.css +0 -88
  88. package/src/modules/dashboard/components/AnimatedMetricCard.tsx +0 -125
  89. package/src/modules/dashboard/components/HeroMetricCard.css +0 -114
  90. package/src/modules/dashboard/components/HeroMetricCard.tsx +0 -152
  91. package/src/modules/dashboard/components/HeroMetricsWidget.tsx +0 -146
  92. package/src/modules/dashboard/components/SystemResourcesWidget.tsx +0 -197
  93. package/src/modules/dashboard/components/dashboard-empty.tsx +0 -22
  94. package/src/modules/dashboard/components/dashboard-kpis-widget.tsx +0 -59
  95. package/src/modules/dashboard/components/dashboard-kpis.tsx +0 -13
  96. package/src/modules/dashboard/components/dashboard-latency-percentiles-widget.tsx +0 -85
  97. package/src/modules/dashboard/components/dashboard-metrics-widget.tsx +0 -78
  98. package/src/modules/dashboard/components/dashboard-plugins-widget.tsx +0 -67
  99. package/src/modules/dashboard/components/dashboard-requests-widget.tsx +0 -62
  100. package/src/modules/dashboard/layouts/dashboard-layout.tsx +0 -16
  101. package/src/modules/dashboard/pages/ai-insights-page.tsx +0 -563
  102. package/src/modules/dashboard/pages/dashboard-animations.css +0 -317
  103. package/src/modules/dashboard/pages/dashboard-page.tsx +0 -13
  104. package/src/modules/dashboard/routes/index.tsx +0 -70
  105. package/src/modules/observability/pages/devkit-page.tsx +0 -263
  106. package/src/modules/observability/pages/incident-detail-page.tsx +0 -571
  107. package/src/modules/observability/pages/incidents-page.tsx +0 -370
  108. package/src/modules/observability/pages/log-detail-page.tsx +0 -508
  109. package/src/modules/observability/pages/logs-page.tsx +0 -1129
  110. package/src/modules/observability/pages/prometheus-metrics-page.tsx +0 -486
  111. package/src/modules/observability/pages/state-broker-page.tsx +0 -229
  112. package/src/modules/observability/pages/system-events-page.tsx +0 -255
  113. package/src/modules/observability/routes/index.tsx +0 -133
  114. package/src/modules/plugins/components/marketplace-card.tsx +0 -153
  115. package/src/modules/plugins/components/plugin-ai-assistant-modal.tsx +0 -374
  116. package/src/modules/plugins/components/plugin-card.tsx +0 -136
  117. package/src/modules/plugins/components/plugin-detail/capabilities-summary.tsx +0 -101
  118. package/src/modules/plugins/components/plugin-detail/cli-commands-table.tsx +0 -101
  119. package/src/modules/plugins/components/plugin-detail/index.ts +0 -7
  120. package/src/modules/plugins/components/plugin-detail/jobs-table.tsx +0 -64
  121. package/src/modules/plugins/components/plugin-detail/permissions/env-permissions.tsx +0 -30
  122. package/src/modules/plugins/components/plugin-detail/permissions/filesystem-permissions.tsx +0 -68
  123. package/src/modules/plugins/components/plugin-detail/permissions/index.ts +0 -6
  124. package/src/modules/plugins/components/plugin-detail/permissions/network-permissions.tsx +0 -43
  125. package/src/modules/plugins/components/plugin-detail/permissions/platform-services.tsx +0 -242
  126. package/src/modules/plugins/components/plugin-detail/permissions/resource-quotas.tsx +0 -96
  127. package/src/modules/plugins/components/plugin-detail/permissions/shell-permissions.tsx +0 -55
  128. package/src/modules/plugins/components/plugin-detail/permissions-view.tsx +0 -47
  129. package/src/modules/plugins/components/plugin-detail/plugin-header.tsx +0 -169
  130. package/src/modules/plugins/components/plugin-detail/rest-routes-table.tsx +0 -159
  131. package/src/modules/plugins/components/plugin-detail/workflows-table.tsx +0 -40
  132. package/src/modules/plugins/components/plugin-grid.tsx +0 -20
  133. package/src/modules/plugins/components/plugin-table.tsx +0 -178
  134. package/src/modules/plugins/pages/marketplace-page.tsx +0 -200
  135. package/src/modules/plugins/pages/plugin-detail-page.tsx +0 -1145
  136. package/src/modules/plugins/routes/index.tsx +0 -48
  137. package/src/modules/plugins/utils/index.ts +0 -1
  138. package/src/modules/plugins/utils/schema-helpers.ts +0 -21
  139. package/src/modules/settings/components/api-routes-viewer.tsx +0 -415
  140. package/src/modules/settings/components/appearance-settings.tsx +0 -200
  141. package/src/modules/settings/components/configuration-settings.tsx +0 -321
  142. package/src/modules/settings/components/data-privacy-settings.tsx +0 -111
  143. package/src/modules/settings/components/experimental-settings.tsx +0 -243
  144. package/src/modules/settings/components/navigation-settings.tsx +0 -198
  145. package/src/modules/settings/components/notifications-settings.tsx +0 -40
  146. package/src/modules/settings/pages/settings-page.tsx +0 -298
  147. package/src/modules/settings/routes/index.tsx +0 -47
  148. package/src/pages/README-assistant.md +0 -91
  149. package/src/pages/login-page.tsx +0 -177
  150. package/src/pages/not-found-page.tsx +0 -85
  151. package/src/providers/auth-provider.tsx +0 -40
  152. package/src/providers/command-palette-provider.tsx +0 -193
  153. package/src/providers/data-sources-provider.tsx +0 -27
  154. package/src/providers/devtools-provider.tsx +0 -72
  155. package/src/providers/navigation-items-provider.tsx +0 -38
  156. package/src/providers/registry-v2-provider.tsx +0 -93
  157. package/src/providers/settings-provider.tsx +0 -158
  158. package/src/router.tsx +0 -302
  159. package/src/routes/helpers.tsx +0 -25
  160. package/src/routes/plugin-page-v2.tsx +0 -52
  161. package/src/routes/types.ts +0 -18
  162. package/src/styles/antd-overrides.css +0 -211
  163. package/src/styles/base.css +0 -190
  164. package/src/styles/settings.css +0 -75
  165. package/src/styles/variables.css +0 -94
  166. package/src/utils/analytics.ts +0 -183
  167. package/src/utils/apply-navigation-categories.ts +0 -83
  168. package/src/utils/commands.ts +0 -252
  169. package/src/utils/export.ts +0 -174
  170. package/src/utils/format-date.ts +0 -166
  171. package/src/utils/logger.ts +0 -110
  172. package/tailwind.config.ts +0 -13
  173. package/tsconfig.json +0 -13
  174. package/vitest-setup.ts +0 -1
  175. /package/{public → dist}/favicon.svg +0 -0
@@ -1,178 +0,0 @@
1
- import {
2
- UITable,
3
- UITag,
4
- UISpace,
5
- UITypographyText,
6
- UITooltip,
7
- UIIcon,
8
- } from '@kb-labs/studio-ui-kit';
9
- import type { UITableColumn } from '@kb-labs/studio-ui-kit';
10
- import type { PluginManifestEntry } from '@kb-labs/studio-data-client';
11
-
12
- interface PluginTableProps {
13
- plugins: PluginManifestEntry[];
14
- onPluginClick: (plugin: PluginManifestEntry) => void;
15
- }
16
-
17
- export function PluginTable({ plugins, onPluginClick }: PluginTableProps) {
18
- const columns: UITableColumn<PluginManifestEntry>[] = [
19
- {
20
- title: 'Plugin',
21
- key: 'id',
22
- width: 250,
23
- fixed: 'left',
24
- render: (_value, record) => {
25
- const { display } = record.manifest;
26
- const id = record.manifest.id;
27
- return (
28
- <UISpace>
29
- <span style={{ fontSize: 20 }}>{display?.icon || ''}</span>
30
- <div>
31
- <UITypographyText strong>{display?.name || id}</UITypographyText>
32
- <br />
33
- <UITypographyText type="secondary" style={{ fontSize: 12 }}>
34
- {id}
35
- </UITypographyText>
36
- </div>
37
- </UISpace>
38
- );
39
- },
40
- },
41
- {
42
- title: 'Version',
43
- key: 'version',
44
- width: 100,
45
- render: (_value, record) => (
46
- <UITypographyText code>{record.manifest.version}</UITypographyText>
47
- ),
48
- },
49
- {
50
- title: 'Description',
51
- key: 'description',
52
- ellipsis: true,
53
- render: (_value, record) => {
54
- const desc = record.manifest.display?.description;
55
- return (
56
- <UITooltip title={desc}>
57
- <UITypographyText type="secondary">{desc || '--'}</UITypographyText>
58
- </UITooltip>
59
- );
60
- },
61
- },
62
- {
63
- title: 'CLI',
64
- key: 'cli',
65
- width: 80,
66
- align: 'center',
67
- render: (_, record) => {
68
- const count = record.manifest.cli?.commands.length ?? 0;
69
- return count > 0 ? (
70
- <UITooltip title={`${count} command${count > 1 ? 's' : ''}`}>
71
- <UITag icon={<UIIcon name="CodeOutlined" />} color="blue">
72
- {count}
73
- </UITag>
74
- </UITooltip>
75
- ) : (
76
- <UITypographyText type="secondary">--</UITypographyText>
77
- );
78
- },
79
- },
80
- {
81
- title: 'REST',
82
- key: 'rest',
83
- width: 80,
84
- align: 'center',
85
- render: (_, record) => {
86
- const count = record.manifest.rest?.routes.length ?? 0;
87
- return count > 0 ? (
88
- <UITooltip title={`${count} route${count > 1 ? 's' : ''}`}>
89
- <UITag icon={<UIIcon name="ApiOutlined" />} color="green">
90
- {count}
91
- </UITag>
92
- </UITooltip>
93
- ) : (
94
- <UITypographyText type="secondary">--</UITypographyText>
95
- );
96
- },
97
- },
98
- {
99
- title: 'Workflows',
100
- key: 'workflows',
101
- width: 100,
102
- align: 'center',
103
- render: (_, record) => {
104
- const count = record.manifest.workflows?.handlers.length ?? 0;
105
- return count > 0 ? (
106
- <UITooltip title={`${count} handler${count > 1 ? 's' : ''}`}>
107
- <UITag icon={<UIIcon name="NodeIndexOutlined" />} color="purple">
108
- {count}
109
- </UITag>
110
- </UITooltip>
111
- ) : (
112
- <UITypographyText type="secondary">--</UITypographyText>
113
- );
114
- },
115
- },
116
- {
117
- title: 'Jobs',
118
- key: 'jobs',
119
- width: 80,
120
- align: 'center',
121
- render: (_, record) => {
122
- const count = record.manifest.jobs?.handlers.length ?? 0;
123
- return count > 0 ? (
124
- <UITooltip title={`${count} job${count > 1 ? 's' : ''}`}>
125
- <UITag icon={<UIIcon name="ClockCircleOutlined" />} color="orange">
126
- {count}
127
- </UITag>
128
- </UITooltip>
129
- ) : (
130
- <UITypographyText type="secondary">--</UITypographyText>
131
- );
132
- },
133
- },
134
- {
135
- title: 'Flags',
136
- key: 'flags',
137
- width: 180,
138
- render: (_, record) => (
139
- <UISpace wrap size={4}>
140
- {record.manifest.permissions && (
141
- <UITooltip title="Requires permissions">
142
- <UITag icon={<UIIcon name="WarningOutlined" />} color="gold" style={{ fontSize: 11 }}>
143
- Perms
144
- </UITag>
145
- </UITooltip>
146
- )}
147
- {record.manifest.platform?.requires && record.manifest.platform.requires.length > 0 && (
148
- <UITooltip title={`Requires: ${record.manifest.platform.requires.join(', ')}`}>
149
- <UITag icon={<UIIcon name="CheckCircleOutlined" />} color="cyan" style={{ fontSize: 11 }}>
150
- Platform
151
- </UITag>
152
- </UITooltip>
153
- )}
154
- {record.manifest.display?.tags?.slice(0, 2).map((tag) => (
155
- <UITag key={tag} style={{ fontSize: 11 }}>
156
- {tag}
157
- </UITag>
158
- ))}
159
- </UISpace>
160
- ),
161
- },
162
- ];
163
-
164
- return (
165
- <UITable
166
- columns={columns}
167
- dataSource={plugins}
168
- rowKey="pluginId"
169
- pagination={{
170
- pageSize: 20,
171
- }}
172
- onRow={(record) => ({
173
- onClick: () => onPluginClick(record),
174
- style: { cursor: 'pointer' },
175
- })}
176
- />
177
- );
178
- }
@@ -1,200 +0,0 @@
1
- import { useState, useEffect, useMemo, useCallback } from 'react';
2
- import { useNavigate } from 'react-router-dom';
3
- import {
4
- UIInputSearch,
5
- UISpin,
6
- UIEmptyState,
7
- UIMessage,
8
- UIButton,
9
- UIIcon,
10
- UIRow,
11
- UICol,
12
- UIPage,
13
- UIPageHeader,
14
- } from '@kb-labs/studio-ui-kit';
15
- import { useDataSources } from '@/providers/data-sources-provider';
16
- import type { PluginManifestEntry } from '@kb-labs/studio-data-client';
17
- import { MarketplaceCard } from '../components/marketplace-card';
18
-
19
- type KindFilter = 'all' | 'plugins' | 'adapters';
20
- type SurfaceFilter = 'all' | 'cli' | 'studio' | 'rest';
21
-
22
- export function PluginsPage() {
23
- const navigate = useNavigate();
24
- const { plugins: pluginsSource } = useDataSources();
25
-
26
- const [loading, setLoading] = useState(true);
27
- const [plugins, setPlugins] = useState<PluginManifestEntry[]>([]);
28
- const [search, setSearch] = useState('');
29
- const [kindFilter, setKindFilter] = useState<KindFilter>('all');
30
- const [surfaceFilter, setSurfaceFilter] = useState<SurfaceFilter>('all');
31
-
32
- const loadPlugins = useCallback(async () => {
33
- try {
34
- setLoading(true);
35
- const result = await pluginsSource.getPlugins();
36
- setPlugins(result.manifests);
37
- } catch {
38
- UIMessage.error('Failed to load marketplace');
39
- } finally {
40
- setLoading(false);
41
- }
42
- }, [pluginsSource]);
43
-
44
- useEffect(() => { loadPlugins(); }, [loadPlugins]);
45
-
46
- const counts = useMemo(() => ({
47
- all: plugins.length,
48
- plugins: plugins.length,
49
- adapters: 0,
50
- cli: plugins.filter(p => (p.manifest.cli?.commands?.length ?? 0) > 0).length,
51
- studio: plugins.filter(p => (p.manifest.studio?.pages?.length ?? 0) > 0).length,
52
- rest: plugins.filter(p => (p.manifest.rest?.routes?.length ?? 0) > 0).length,
53
- }), [plugins]);
54
-
55
- const filtered = useMemo(() => {
56
- return plugins.filter(p => {
57
- const m = p.manifest;
58
- if (search) {
59
- const q = search.toLowerCase();
60
- const text = [m.id, m.display?.name, m.display?.description, ...(m.display?.tags ?? [])].join(' ').toLowerCase();
61
- if (!text.includes(q)) {return false;}
62
- }
63
- if (surfaceFilter === 'cli' && !((m.cli?.commands?.length ?? 0) > 0)) {return false;}
64
- if (surfaceFilter === 'studio' && !((m.studio?.pages?.length ?? 0) > 0)) {return false;}
65
- if (surfaceFilter === 'rest' && !((m.rest?.routes?.length ?? 0) > 0)) {return false;}
66
- return true;
67
- });
68
- }, [plugins, search, surfaceFilter]);
69
-
70
- const handleClick = (plugin: PluginManifestEntry) => {
71
- navigate(`/marketplace/${encodeURIComponent(plugin.pluginId)}`);
72
- };
73
-
74
- const kindTabs: { key: KindFilter; label: string; count: number }[] = [
75
- { key: 'all', label: 'All', count: counts.all },
76
- { key: 'plugins', label: 'Extensions', count: counts.plugins },
77
- { key: 'adapters', label: 'Adapters', count: counts.adapters },
78
- ];
79
-
80
- const surfaceChips: { key: SurfaceFilter; label: string; count: number }[] = [
81
- { key: 'cli', label: 'CLI', count: counts.cli },
82
- { key: 'studio', label: 'Studio UI', count: counts.studio },
83
- { key: 'rest', label: 'REST API', count: counts.rest },
84
- ];
85
-
86
- if (loading) {
87
- return (
88
- <UIPage width="full">
89
- <div style={{ textAlign: 'center', padding: '80px 0' }}>
90
- <UISpin size="large" />
91
- </div>
92
- </UIPage>
93
- );
94
- }
95
-
96
- return (
97
- <UIPage width="full">
98
- <UIPageHeader
99
- title="Marketplace"
100
- description={`${counts.all} extension${counts.all !== 1 ? 's' : ''} installed`}
101
- actions={
102
- <UIButton variant="primary" icon={<UIIcon name="PlusOutlined" />}>
103
- Install Extension
104
- </UIButton>
105
- }
106
- />
107
-
108
- {/* Filters bar */}
109
- <div style={{ display: 'flex', alignItems: 'center', gap: 24, marginBottom: 24, flexWrap: 'wrap' }}>
110
-
111
- {/* Kind tabs */}
112
- <div style={{ display: 'flex', gap: 2, background: 'var(--bg-tertiary)', borderRadius: 10, padding: 3 }}>
113
- {kindTabs.map(tab => (
114
- <button
115
- key={tab.key}
116
- onClick={() => setKindFilter(tab.key)}
117
- style={{
118
- display: 'flex', alignItems: 'center', gap: 6,
119
- padding: '5px 12px', borderRadius: 8, border: 'none', cursor: 'pointer',
120
- background: kindFilter === tab.key ? 'var(--bg-secondary)' : 'transparent',
121
- color: kindFilter === tab.key ? 'var(--text-primary)' : 'var(--text-secondary)',
122
- fontSize: 13, fontWeight: kindFilter === tab.key ? 600 : 400,
123
- boxShadow: kindFilter === tab.key ? '0 1px 3px rgba(0,0,0,0.08)' : 'none',
124
- transition: 'all 120ms ease',
125
- }}
126
- >
127
- {tab.label}
128
- <span style={{
129
- fontSize: 11, fontWeight: 600,
130
- color: kindFilter === tab.key ? 'var(--link)' : 'var(--text-tertiary)',
131
- background: kindFilter === tab.key ? 'rgba(12,102,255,0.10)' : 'transparent',
132
- borderRadius: 8, padding: '0 5px',
133
- }}>
134
- {tab.count}
135
- </span>
136
- </button>
137
- ))}
138
- </div>
139
-
140
- {/* Divider */}
141
- <div style={{ width: 1, height: 20, background: 'var(--border-primary)', flexShrink: 0 }} />
142
-
143
- {/* Surface chips */}
144
- <div style={{ display: 'flex', gap: 6 }}>
145
- {surfaceChips.map(chip => {
146
- const active = surfaceFilter === chip.key;
147
- return (
148
- <button
149
- key={chip.key}
150
- onClick={() => setSurfaceFilter(active ? 'all' : chip.key)}
151
- style={{
152
- display: 'flex', alignItems: 'center', gap: 5,
153
- padding: '5px 12px', borderRadius: 20,
154
- border: `1px solid ${active ? 'var(--link)' : 'var(--border-primary)'}`,
155
- cursor: 'pointer',
156
- background: active ? 'rgba(12,102,255,0.08)' : 'transparent',
157
- color: active ? 'var(--link)' : 'var(--text-secondary)',
158
- fontSize: 13, fontWeight: active ? 500 : 400,
159
- transition: 'all 120ms ease',
160
- }}
161
- >
162
- {chip.label}
163
- <span style={{ fontSize: 11, color: active ? 'var(--link)' : 'var(--text-tertiary)' }}>
164
- {chip.count}
165
- </span>
166
- </button>
167
- );
168
- })}
169
- </div>
170
-
171
- {/* Search — pushed to the right */}
172
- <div style={{ marginLeft: 'auto' }}>
173
- <UIInputSearch
174
- placeholder="Search extensions..."
175
- value={search}
176
- onChange={e => setSearch(e.target.value)}
177
- allowClear
178
- style={{ width: 260 }}
179
- />
180
- </div>
181
- </div>
182
-
183
- {/* Grid */}
184
- {filtered.length === 0 ? (
185
- <UIEmptyState
186
- description={search ? 'No extensions match your search' : 'No extensions found'}
187
- style={{ marginTop: 48 }}
188
- />
189
- ) : (
190
- <UIRow gutter={[16, 16]}>
191
- {filtered.map(plugin => (
192
- <UICol key={plugin.pluginId} xs={24} sm={12} xl={8}>
193
- <MarketplaceCard plugin={plugin} onClick={() => handleClick(plugin)} />
194
- </UICol>
195
- ))}
196
- </UIRow>
197
- )}
198
- </UIPage>
199
- );
200
- }