spine-framework 0.1.61 → 0.2.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 (246) hide show
  1. package/.framework/cli/commands/create-app.ts +1 -1
  2. package/.framework/cli/commands/dev.ts +215 -33
  3. package/.framework/cli/index.ts +37 -63
  4. package/.framework/functions/_shared/app-manifest.ts +8 -15
  5. package/.framework/functions/_shared/db.ts +11 -15
  6. package/.framework/functions/_shared/index.ts +0 -9
  7. package/.framework/functions/_shared/principal.ts +4 -62
  8. package/.framework/functions/_shared/resolve-ids.ts +6 -6
  9. package/.framework/functions/_shared/webhook-registry.ts +1 -1
  10. package/.framework/functions/admin-funnel.ts +104 -0
  11. package/.framework/functions/admin-install-funnel.ts +225 -0
  12. package/.framework/functions/admin-signals.ts +241 -0
  13. package/.framework/migrations/001_schema.sql +406 -0
  14. package/.framework/migrations/002_rls_and_functions.sql +710 -0
  15. package/.framework/migrations/003_system_data.sql +520 -0
  16. package/.framework/migrations/004_enhancements.sql +43 -0
  17. package/.framework/public/_redirects +3 -0
  18. package/.framework/public/spine-logo.jpg +0 -0
  19. package/.framework/public/spine-logo.svg +3 -0
  20. package/{scripts → .framework/scripts}/assemble-frontend.sh +1 -1
  21. package/{scripts → .framework/scripts}/assemble-functions.sh +1 -1
  22. package/{scripts → .framework/scripts}/assemble.sh +2 -8
  23. package/{scripts → .framework/scripts}/check-core-integrity.sh +0 -0
  24. package/.framework/seeds/link_types/account_cli_instances.json +9 -0
  25. package/.framework/seeds/types/funnel_signal_use.json +98 -0
  26. package/.framework/seeds/types/spine_instance.json +109 -0
  27. package/.framework/src/App.tsx +6 -4
  28. package/.framework/src/components/ui/accordion.tsx +1 -1
  29. package/.framework/src/components/ui/alert-dialog.tsx +1 -1
  30. package/.framework/src/components/ui/aspect-ratio.tsx +1 -1
  31. package/.framework/src/components/ui/avatar.tsx +1 -1
  32. package/.framework/src/components/ui/badge.tsx +2 -2
  33. package/.framework/src/components/ui/breadcrumb.tsx +2 -2
  34. package/.framework/src/components/ui/button-group.tsx +2 -2
  35. package/.framework/src/components/ui/button.tsx +2 -2
  36. package/.framework/src/components/ui/chart.tsx +6 -1
  37. package/.framework/src/components/ui/checkbox.tsx +1 -1
  38. package/.framework/src/components/ui/collapsible.tsx +1 -1
  39. package/.framework/src/components/ui/context-menu.tsx +1 -1
  40. package/.framework/src/components/ui/dialog.tsx +1 -1
  41. package/.framework/src/components/ui/direction.tsx +17 -1
  42. package/.framework/src/components/ui/dropdown-menu.tsx +1 -1
  43. package/.framework/src/components/ui/hover-card.tsx +1 -1
  44. package/.framework/src/components/ui/item.tsx +2 -2
  45. package/.framework/src/components/ui/label.tsx +1 -1
  46. package/.framework/src/components/ui/menubar.tsx +1 -1
  47. package/.framework/src/components/ui/navigation-menu.tsx +1 -1
  48. package/.framework/src/components/ui/popover.tsx +1 -1
  49. package/.framework/src/components/ui/progress.tsx +1 -1
  50. package/.framework/src/components/ui/radio-group.tsx +1 -1
  51. package/.framework/src/components/ui/scroll-area.tsx +1 -1
  52. package/.framework/src/components/ui/select.tsx +1 -1
  53. package/.framework/src/components/ui/separator.tsx +1 -1
  54. package/.framework/src/components/ui/sheet.tsx +1 -1
  55. package/.framework/src/components/ui/sidebar.tsx +6 -6
  56. package/.framework/src/components/ui/slider.tsx +1 -1
  57. package/.framework/src/components/ui/switch.tsx +1 -1
  58. package/.framework/src/components/ui/tabs.tsx +1 -1
  59. package/.framework/src/components/ui/toggle-group.tsx +1 -1
  60. package/.framework/src/components/ui/toggle.tsx +1 -1
  61. package/.framework/src/components/ui/tooltip.tsx +1 -1
  62. package/.framework/src/pages/auth/LoginPage.tsx +10 -9
  63. package/LICENSE.md +193 -0
  64. package/README.md +254 -0
  65. package/custom/.devin/skills/install-app/SKILL.md +39 -0
  66. package/custom/.devin/workflows/app-install.yaml +83 -0
  67. package/custom/README.md +79 -0
  68. package/docs/APPS.md +232 -0
  69. package/docs/ARCHITECTURE.md +246 -0
  70. package/docs/INSTALL.md +155 -0
  71. package/docs/README.md +170 -0
  72. package/docs/design-schema-spec.md +1837 -0
  73. package/docs/dev-guides/01-create-an-app.md +183 -0
  74. package/docs/dev-guides/02-create-a-function.md +178 -0
  75. package/docs/dev-guides/03-create-a-component.md +178 -0
  76. package/docs/dev-guides/04-webhook-handlers.md +129 -0
  77. package/docs/dev-guides/05-testing.md +168 -0
  78. package/docs/dev-guides/README.md +40 -0
  79. package/docs/npm-packages-plan.md +288 -0
  80. package/docs/spine-core--api-reference.md +822 -0
  81. package/package.json +78 -144
  82. package/.framework/cli/bin.cjs +0 -14
  83. package/.framework/cli/commands/init.ts +0 -186
  84. package/.framework/cli/commands/install-app.ts +0 -565
  85. package/.framework/cli/commands/migrate.ts +0 -139
  86. package/.framework/cli/commands/status.ts +0 -197
  87. package/.framework/cli/commands/uninstall-app.ts +0 -166
  88. package/.framework/cli/welcome.cjs +0 -45
  89. package/.framework/docs/STABILITY.md +0 -52
  90. package/.framework/docs/examples/custom-app/README.md +0 -77
  91. package/.framework/docs/examples/custom-function/README.md +0 -27
  92. package/.framework/docs/examples/custom-function/handler.ts +0 -48
  93. package/.framework/docs/examples/custom-webhook/README.md +0 -68
  94. package/.framework/migrations/000_foundation.sql +0 -1266
  95. package/.framework/migrations/001_seed.sql +0 -163
  96. package/.framework/migrations/002_seed_constraints.sql +0 -19
  97. package/.framework/migrations/003_auth_user_trigger.sql +0 -67
  98. package/.framework/src/pages/auth/RegisterPage.tsx +0 -163
  99. package/STRUCTURE.md +0 -150
  100. package/bin/spine-framework.cjs +0 -62
  101. package/bin/welcome.cjs +0 -45
  102. package/bin/ws-shim.cjs +0 -8
  103. package/bin/ws-shim.ts +0 -10
  104. package/config/components.json +0 -25
  105. package/config/deno.lock +0 -108
  106. package/config/package-lock.json +0 -17183
  107. package/config/postcss.config.cjs +0 -10
  108. package/config/tailwind.config.cjs +0 -78
  109. package/config/tsconfig.build.json +0 -32
  110. package/config/tsconfig.cli.json +0 -18
  111. package/config/tsconfig.json +0 -41
  112. package/config/tsconfig.node.json +0 -17
  113. package/config/tsconfig.node.tsbuildinfo +0 -1
  114. package/config/tsconfig.tsbuildinfo +0 -1
  115. package/config/typedoc.json +0 -16
  116. package/config/vite.config.d.ts +0 -2
  117. package/config/vite.config.ts +0 -72
  118. package/dist/cli/commands/agents.d.ts +0 -39
  119. package/dist/cli/commands/agents.d.ts.map +0 -1
  120. package/dist/cli/commands/auth.d.ts +0 -36
  121. package/dist/cli/commands/auth.d.ts.map +0 -1
  122. package/dist/cli/commands/create-app.d.ts +0 -23
  123. package/dist/cli/commands/create-app.d.ts.map +0 -1
  124. package/dist/cli/commands/dev.d.ts +0 -24
  125. package/dist/cli/commands/dev.d.ts.map +0 -1
  126. package/dist/cli/commands/doctor.d.ts +0 -42
  127. package/dist/cli/commands/doctor.d.ts.map +0 -1
  128. package/dist/cli/commands/generate.d.ts +0 -36
  129. package/dist/cli/commands/generate.d.ts.map +0 -1
  130. package/dist/cli/commands/init.d.ts +0 -20
  131. package/dist/cli/commands/init.d.ts.map +0 -1
  132. package/dist/cli/commands/install-app.d.ts +0 -30
  133. package/dist/cli/commands/install-app.d.ts.map +0 -1
  134. package/dist/cli/commands/items.d.ts +0 -45
  135. package/dist/cli/commands/items.d.ts.map +0 -1
  136. package/dist/cli/commands/migrate.d.ts +0 -21
  137. package/dist/cli/commands/migrate.d.ts.map +0 -1
  138. package/dist/cli/commands/migrations.d.ts +0 -41
  139. package/dist/cli/commands/migrations.d.ts.map +0 -1
  140. package/dist/cli/commands/pipelines.d.ts +0 -40
  141. package/dist/cli/commands/pipelines.d.ts.map +0 -1
  142. package/dist/cli/commands/status.d.ts +0 -23
  143. package/dist/cli/commands/status.d.ts.map +0 -1
  144. package/dist/cli/commands/system.d.ts +0 -29
  145. package/dist/cli/commands/system.d.ts.map +0 -1
  146. package/dist/cli/commands/test.d.ts +0 -46
  147. package/dist/cli/commands/test.d.ts.map +0 -1
  148. package/dist/cli/commands/uninstall-app.d.ts +0 -23
  149. package/dist/cli/commands/uninstall-app.d.ts.map +0 -1
  150. package/dist/cli/context.d.ts +0 -88
  151. package/dist/cli/context.d.ts.map +0 -1
  152. package/dist/cli/env-loader.d.ts +0 -14
  153. package/dist/cli/env-loader.d.ts.map +0 -1
  154. package/dist/cli/index.d.ts +0 -41
  155. package/dist/cli/index.d.ts.map +0 -1
  156. package/dist/functions/_shared/agent-runner.d.ts +0 -156
  157. package/dist/functions/_shared/agent-runner.d.ts.map +0 -1
  158. package/dist/functions/_shared/app-manifest.d.ts +0 -68
  159. package/dist/functions/_shared/app-manifest.d.ts.map +0 -1
  160. package/dist/functions/_shared/audit.d.ts +0 -91
  161. package/dist/functions/_shared/audit.d.ts.map +0 -1
  162. package/dist/functions/_shared/db.d.ts +0 -125
  163. package/dist/functions/_shared/db.d.ts.map +0 -1
  164. package/dist/functions/_shared/index.d.ts +0 -299
  165. package/dist/functions/_shared/index.d.ts.map +0 -1
  166. package/dist/functions/_shared/middleware.d.ts +0 -315
  167. package/dist/functions/_shared/middleware.d.ts.map +0 -1
  168. package/dist/functions/_shared/permissions.d.ts +0 -626
  169. package/dist/functions/_shared/permissions.d.ts.map +0 -1
  170. package/dist/functions/_shared/pipeline-runner.d.ts +0 -124
  171. package/dist/functions/_shared/pipeline-runner.d.ts.map +0 -1
  172. package/dist/functions/_shared/principal.d.ts +0 -284
  173. package/dist/functions/_shared/principal.d.ts.map +0 -1
  174. package/dist/functions/_shared/resolve-ids.d.ts +0 -10
  175. package/dist/functions/_shared/resolve-ids.d.ts.map +0 -1
  176. package/dist/functions/_shared/schema-utils.d.ts +0 -181
  177. package/dist/functions/_shared/schema-utils.d.ts.map +0 -1
  178. package/dist/functions/_shared/testing.d.ts +0 -172
  179. package/dist/functions/_shared/testing.d.ts.map +0 -1
  180. package/dist/functions/_shared/trigger-engine.d.ts +0 -140
  181. package/dist/functions/_shared/trigger-engine.d.ts.map +0 -1
  182. package/dist/functions/_shared/webhook-registration.d.ts +0 -81
  183. package/dist/functions/_shared/webhook-registration.d.ts.map +0 -1
  184. package/dist/functions/_shared/webhook-registry.d.ts +0 -57
  185. package/dist/functions/_shared/webhook-registry.d.ts.map +0 -1
  186. package/dist/functions/account-nodes.d.ts +0 -48
  187. package/dist/functions/account-nodes.d.ts.map +0 -1
  188. package/dist/functions/admin-data.d.ts +0 -178
  189. package/dist/functions/admin-data.d.ts.map +0 -1
  190. package/dist/functions/ai-agents.d.ts +0 -125
  191. package/dist/functions/ai-agents.d.ts.map +0 -1
  192. package/dist/functions/api-keys.d.ts +0 -140
  193. package/dist/functions/api-keys.d.ts.map +0 -1
  194. package/dist/functions/apps.d.ts +0 -163
  195. package/dist/functions/apps.d.ts.map +0 -1
  196. package/dist/functions/auth.d.ts +0 -74
  197. package/dist/functions/auth.d.ts.map +0 -1
  198. package/dist/functions/debug-auth.d.ts +0 -33
  199. package/dist/functions/debug-auth.d.ts.map +0 -1
  200. package/dist/functions/embeddings.d.ts +0 -205
  201. package/dist/functions/embeddings.d.ts.map +0 -1
  202. package/dist/functions/integration-routes.d.ts +0 -45
  203. package/dist/functions/integration-routes.d.ts.map +0 -1
  204. package/dist/functions/integrations.d.ts +0 -124
  205. package/dist/functions/integrations.d.ts.map +0 -1
  206. package/dist/functions/item-progress.d.ts +0 -41
  207. package/dist/functions/item-progress.d.ts.map +0 -1
  208. package/dist/functions/logs.d.ts +0 -162
  209. package/dist/functions/logs.d.ts.map +0 -1
  210. package/dist/functions/observability.d.ts +0 -123
  211. package/dist/functions/observability.d.ts.map +0 -1
  212. package/dist/functions/pipeline-executions.d.ts +0 -190
  213. package/dist/functions/pipeline-executions.d.ts.map +0 -1
  214. package/dist/functions/pipelines.d.ts +0 -171
  215. package/dist/functions/pipelines.d.ts.map +0 -1
  216. package/dist/functions/prompt-configs.d.ts +0 -125
  217. package/dist/functions/prompt-configs.d.ts.map +0 -1
  218. package/dist/functions/roles.d.ts +0 -118
  219. package/dist/functions/roles.d.ts.map +0 -1
  220. package/dist/functions/system-cron.d.ts +0 -65
  221. package/dist/functions/system-cron.d.ts.map +0 -1
  222. package/dist/functions/system.d.ts +0 -29
  223. package/dist/functions/system.d.ts.map +0 -1
  224. package/dist/functions/tests.d.ts +0 -28
  225. package/dist/functions/tests.d.ts.map +0 -1
  226. package/dist/functions/timers.d.ts +0 -139
  227. package/dist/functions/timers.d.ts.map +0 -1
  228. package/dist/functions/triggers.d.ts +0 -203
  229. package/dist/functions/triggers.d.ts.map +0 -1
  230. package/dist/functions/types.d.ts +0 -151
  231. package/dist/functions/types.d.ts.map +0 -1
  232. package/dist/src/types/types.d.ts +0 -364
  233. package/dist/src/types/types.d.ts.map +0 -1
  234. package/index.html +0 -13
  235. package/netlify.toml +0 -36
  236. package/package-project.json +0 -64
  237. package/scripts/ingest-chunks.cjs +0 -202
  238. package/scripts/kb-chunk-parser.cjs +0 -312
  239. package/scripts/kb-chunk-parser.ts +0 -330
  240. package/scripts/load-test-app-install.ts +0 -484
  241. package/scripts/netlify-dev-wrapper.sh +0 -22
  242. package/vitest.config.ts +0 -45
  243. /package/{scripts → .framework/scripts}/app-install-cli.ts +0 -0
  244. /package/{scripts → .framework/scripts}/boundary-check.sh +0 -0
  245. /package/{scripts → .framework/scripts}/build-manifest.sh +0 -0
  246. /package/{scripts → .framework/scripts}/verify-integrity.sh +0 -0
@@ -0,0 +1,98 @@
1
+ {
2
+ "slug": "funnel_signal_use",
3
+ "kind": "item",
4
+ "name": "Usage Signal",
5
+ "description": "Tracks CLI and app usage signals from npm installations",
6
+ "design_schema": {
7
+ "fields": {
8
+ "title": {
9
+ "data_type": "text",
10
+ "label": "Title",
11
+ "required": true,
12
+ "system": true
13
+ },
14
+ "source": {
15
+ "data_type": "select",
16
+ "label": "Source",
17
+ "required": true,
18
+ "options": ["use"]
19
+ },
20
+ "stage": {
21
+ "data_type": "select",
22
+ "label": "Stage",
23
+ "required": true,
24
+ "options": ["installed", "claimed", "active"]
25
+ },
26
+ "action_type": {
27
+ "data_type": "text",
28
+ "label": "Action Type",
29
+ "required": true
30
+ },
31
+ "action_value": {
32
+ "data_type": "number",
33
+ "label": "Action Value",
34
+ "required": true
35
+ },
36
+ "serial": {
37
+ "data_type": "text",
38
+ "label": "Install Serial",
39
+ "required": true
40
+ },
41
+ "app_slug": {
42
+ "data_type": "select",
43
+ "label": "App",
44
+ "required": false,
45
+ "options": ["framework", "cortex", "portal"]
46
+ },
47
+ "app_version": {
48
+ "data_type": "text",
49
+ "label": "App Version",
50
+ "required": false
51
+ }
52
+ },
53
+ "views": {
54
+ "default_list": {
55
+ "type": "list",
56
+ "display": "table",
57
+ "label": "Usage Signals",
58
+ "fields": {
59
+ "title": { "sortable": true, "display_type": "text" },
60
+ "action_type": { "sortable": true, "display_type": "badge" },
61
+ "stage": { "sortable": true, "display_type": "badge" },
62
+ "serial": { "sortable": true, "display_type": "text" },
63
+ "created_at": { "sortable": true, "display_type": "timestamp" }
64
+ }
65
+ },
66
+ "default_detail": {
67
+ "type": "detail",
68
+ "label": "Signal Detail",
69
+ "sections": [
70
+ {
71
+ "title": "Signal",
72
+ "fields": {
73
+ "action_type": { "display_type": "input" },
74
+ "action_value": { "display_type": "input" },
75
+ "stage": { "display_type": "select" }
76
+ }
77
+ },
78
+ {
79
+ "title": "Instance",
80
+ "fields": {
81
+ "serial": { "display_type": "input" },
82
+ "app_slug": { "display_type": "select" },
83
+ "app_version": { "display_type": "input" }
84
+ }
85
+ }
86
+ ]
87
+ }
88
+ },
89
+ "record_permissions": {
90
+ "system-admin": ["create", "read", "update", "delete"],
91
+ "support": ["create", "read", "update"],
92
+ "member": ["create", "read"]
93
+ }
94
+ },
95
+ "validation_schema": {},
96
+ "ownership": "pack",
97
+ "is_active": true
98
+ }
@@ -0,0 +1,109 @@
1
+ {
2
+ "slug": "spine_instance",
3
+ "kind": "item",
4
+ "name": "CLI Instance",
5
+ "description": "Tracks npm package installations per device",
6
+ "design_schema": {
7
+ "fields": {
8
+ "title": {
9
+ "data_type": "text",
10
+ "label": "Title",
11
+ "required": true,
12
+ "system": true
13
+ },
14
+ "serial": {
15
+ "data_type": "text",
16
+ "label": "Install Serial",
17
+ "required": true,
18
+ "validation": {
19
+ "pattern": "^sf_inst_[a-z0-9-]+$"
20
+ }
21
+ },
22
+ "app_slug": {
23
+ "data_type": "select",
24
+ "label": "App",
25
+ "required": true,
26
+ "options": ["framework", "cortex", "portal"]
27
+ },
28
+ "version": {
29
+ "data_type": "text",
30
+ "label": "Version",
31
+ "required": true
32
+ },
33
+ "claimed_by_person_id": {
34
+ "data_type": "reference",
35
+ "label": "Claimed By",
36
+ "required": false,
37
+ "validation": {
38
+ "reference_kind": "person"
39
+ }
40
+ },
41
+ "claimed_at": {
42
+ "data_type": "datetime",
43
+ "label": "Claimed At",
44
+ "required": false
45
+ },
46
+ "first_seen_at": {
47
+ "data_type": "datetime",
48
+ "label": "First Seen",
49
+ "required": true
50
+ },
51
+ "last_signal_at": {
52
+ "data_type": "datetime",
53
+ "label": "Last Signal",
54
+ "required": false
55
+ }
56
+ },
57
+ "views": {
58
+ "default_list": {
59
+ "type": "list",
60
+ "display": "table",
61
+ "label": "CLI Instances",
62
+ "fields": {
63
+ "title": { "sortable": true, "display_type": "text" },
64
+ "app_slug": { "sortable": true, "display_type": "badge" },
65
+ "version": { "sortable": true, "display_type": "text" },
66
+ "claimed_at": { "sortable": true, "display_type": "timestamp" },
67
+ "last_signal_at": { "sortable": true, "display_type": "timestamp" }
68
+ },
69
+ "default_sort": { "field": "created_at", "direction": "desc" }
70
+ },
71
+ "default_detail": {
72
+ "type": "detail",
73
+ "label": "Instance Detail",
74
+ "sections": [
75
+ {
76
+ "title": "Instance",
77
+ "fields": {
78
+ "serial": { "display_type": "input" },
79
+ "app_slug": { "display_type": "select" },
80
+ "version": { "display_type": "input" }
81
+ }
82
+ },
83
+ {
84
+ "title": "Claim",
85
+ "fields": {
86
+ "claimed_by_person_id": { "display_type": "reference_picker" },
87
+ "claimed_at": { "display_type": "timestamp" }
88
+ }
89
+ },
90
+ {
91
+ "title": "Activity",
92
+ "fields": {
93
+ "first_seen_at": { "display_type": "timestamp" },
94
+ "last_signal_at": { "display_type": "timestamp" }
95
+ }
96
+ }
97
+ ]
98
+ }
99
+ },
100
+ "record_permissions": {
101
+ "system-admin": ["create", "read", "update", "delete"],
102
+ "support": ["create", "read", "update"],
103
+ "member": ["create", "read", "update"]
104
+ }
105
+ },
106
+ "validation_schema": {},
107
+ "ownership": "pack",
108
+ "is_active": true
109
+ }
@@ -3,7 +3,6 @@ import { Routes, Route, Navigate } from 'react-router-dom'
3
3
  import { useAuth } from './contexts/AuthContext'
4
4
  import { LoadingSpinner } from './components/ui/LoadingSpinner'
5
5
  import { LoginPage } from './pages/auth/LoginPage'
6
- import { RegisterPage } from './pages/auth/RegisterPage'
7
6
  import { NotFoundPage } from './pages/NotFoundPage'
8
7
  import { DashboardPage } from './pages/DashboardPage'
9
8
  import { AppWrapper } from './components/AppWrapper'
@@ -34,7 +33,6 @@ function App() {
34
33
  {!user ? (
35
34
  <Routes>
36
35
  <Route path="/login" element={<LoginPage />} />
37
- <Route path="/register" element={<RegisterPage />} />
38
36
  <Route path="*" element={<Navigate to="/login" replace />} />
39
37
  </Routes>
40
38
  ) : (
@@ -67,11 +65,15 @@ function AuthenticatedRouter() {
67
65
  return (b.route_prefix?.length || 0) - (a.route_prefix?.length || 0)
68
66
  })
69
67
 
68
+ // Determine default redirect: first app with a route_prefix, or fall back to dashboard
69
+ const defaultApp = sorted.find(app => app.route_prefix && app.route_prefix !== '/')
70
+ const defaultRedirect = defaultApp?.route_prefix || '/dashboard'
71
+
70
72
  return (
71
73
  <Suspense fallback={<div className="min-h-screen flex items-center justify-center"><LoadingSpinner /></div>}>
72
74
  <Routes>
73
- {/* Default redirect */}
74
- <Route path="/" element={<Navigate to="/dashboard" replace />} />
75
+ {/* Default redirect to first available app, or dashboard if no apps */}
76
+ <Route path="/" element={<Navigate to={defaultRedirect} replace />} />
75
77
  <Route path="/dashboard" element={<DashboardPage />} />
76
78
 
77
79
  {/* Login route for authenticated users (redirects to qualified app) */}
@@ -1,5 +1,5 @@
1
1
  import * as React from "react"
2
- import * as AccordionPrimitive from "@radix-ui/react-accordion"
2
+ import { Accordion as AccordionPrimitive } from "radix-ui"
3
3
 
4
4
  import { cn } from "@/lib/utils"
5
5
  import { ChevronDownIcon, ChevronUpIcon } from "lucide-react"
@@ -1,5 +1,5 @@
1
1
  import * as React from "react"
2
- import * as AlertDialogPrimitive from "@radix-ui/react-alert-dialog"
2
+ import { AlertDialog as AlertDialogPrimitive } from "radix-ui"
3
3
 
4
4
  import { cn } from "@/lib/utils"
5
5
  import { Button } from "@/components/ui/button"
@@ -1,6 +1,6 @@
1
1
  "use client"
2
2
 
3
- import * as AspectRatioPrimitive from "@radix-ui/react-aspect-ratio"
3
+ import { AspectRatio as AspectRatioPrimitive } from "radix-ui"
4
4
 
5
5
  function AspectRatio({
6
6
  ...props
@@ -1,5 +1,5 @@
1
1
  import * as React from "react"
2
- import * as AvatarPrimitive from "@radix-ui/react-avatar"
2
+ import { Avatar as AvatarPrimitive } from "radix-ui"
3
3
 
4
4
  import { cn } from "@/lib/utils"
5
5
 
@@ -1,6 +1,6 @@
1
1
  import * as React from "react"
2
2
  import { cva, type VariantProps } from "class-variance-authority"
3
- import { Slot } from "@radix-ui/react-slot"
3
+ import { Slot } from "radix-ui"
4
4
 
5
5
  import { cn } from "@/lib/utils"
6
6
 
@@ -34,7 +34,7 @@ function Badge({
34
34
  ...props
35
35
  }: React.ComponentProps<"span"> &
36
36
  VariantProps<typeof badgeVariants> & { asChild?: boolean }) {
37
- const Comp = asChild ? Slot : "span"
37
+ const Comp = asChild ? Slot.Root : "span"
38
38
 
39
39
  return (
40
40
  <Comp
@@ -1,5 +1,5 @@
1
1
  import * as React from "react"
2
- import { Slot } from "@radix-ui/react-slot"
2
+ import { Slot } from "radix-ui"
3
3
 
4
4
  import { cn } from "@/lib/utils"
5
5
  import { ChevronRightIcon, MoreHorizontalIcon } from "lucide-react"
@@ -45,7 +45,7 @@ function BreadcrumbLink({
45
45
  }: React.ComponentProps<"a"> & {
46
46
  asChild?: boolean
47
47
  }) {
48
- const Comp = asChild ? Slot : "a"
48
+ const Comp = asChild ? Slot.Root : "a"
49
49
 
50
50
  return (
51
51
  <Comp
@@ -1,5 +1,5 @@
1
1
  import { cva, type VariantProps } from "class-variance-authority"
2
- import { Slot } from "@radix-ui/react-slot"
2
+ import { Slot } from "radix-ui"
3
3
 
4
4
  import { cn } from "@/lib/utils"
5
5
  import { Separator } from "@/components/ui/separator"
@@ -44,7 +44,7 @@ function ButtonGroupText({
44
44
  }: React.ComponentProps<"div"> & {
45
45
  asChild?: boolean
46
46
  }) {
47
- const Comp = asChild ? Slot : "div"
47
+ const Comp = asChild ? Slot.Root : "div"
48
48
 
49
49
  return (
50
50
  <Comp
@@ -1,6 +1,6 @@
1
1
  import * as React from "react"
2
2
  import { cva, type VariantProps } from "class-variance-authority"
3
- import { Slot } from "@radix-ui/react-slot"
3
+ import { Slot } from "radix-ui"
4
4
 
5
5
  import { cn } from "@/lib/utils"
6
6
 
@@ -49,7 +49,7 @@ function Button({
49
49
  VariantProps<typeof buttonVariants> & {
50
50
  asChild?: boolean
51
51
  }) {
52
- const Comp = asChild ? Slot : "button"
52
+ const Comp = asChild ? Slot.Root : "button"
53
53
 
54
54
  return (
55
55
  <Comp
@@ -2,6 +2,7 @@
2
2
 
3
3
  import * as React from "react"
4
4
  import * as RechartsPrimitive from "recharts"
5
+ import type { TooltipValueType } from "recharts"
5
6
 
6
7
  import { cn } from "@/lib/utils"
7
8
 
@@ -9,6 +10,7 @@ import { cn } from "@/lib/utils"
9
10
  const THEMES = { light: "", dark: ".dark" } as const
10
11
 
11
12
  const INITIAL_DIMENSION = { width: 320, height: 200 } as const
13
+ type TooltipNameType = number | string
12
14
 
13
15
  export type ChartConfig = Record<
14
16
  string,
@@ -136,7 +138,10 @@ function ChartTooltipContent({
136
138
  nameKey?: string
137
139
  labelKey?: string
138
140
  } & Omit<
139
- RechartsPrimitive.TooltipContentProps,
141
+ RechartsPrimitive.DefaultTooltipContentProps<
142
+ TooltipValueType,
143
+ TooltipNameType
144
+ >,
140
145
  "accessibilityLayer"
141
146
  >) {
142
147
  const { config } = useChart()
@@ -1,5 +1,5 @@
1
1
  import * as React from "react"
2
- import * as CheckboxPrimitive from "@radix-ui/react-checkbox"
2
+ import { Checkbox as CheckboxPrimitive } from "radix-ui"
3
3
 
4
4
  import { cn } from "@/lib/utils"
5
5
  import { CheckIcon } from "lucide-react"
@@ -1,6 +1,6 @@
1
1
  "use client"
2
2
 
3
- import * as CollapsiblePrimitive from "@radix-ui/react-collapsible"
3
+ import { Collapsible as CollapsiblePrimitive } from "radix-ui"
4
4
 
5
5
  function Collapsible({
6
6
  ...props
@@ -1,5 +1,5 @@
1
1
  import * as React from "react"
2
- import * as ContextMenuPrimitive from "@radix-ui/react-context-menu"
2
+ import { ContextMenu as ContextMenuPrimitive } from "radix-ui"
3
3
 
4
4
  import { cn } from "@/lib/utils"
5
5
  import { ChevronRightIcon, CheckIcon } from "lucide-react"
@@ -1,7 +1,7 @@
1
1
  "use client"
2
2
 
3
3
  import * as React from "react"
4
- import * as DialogPrimitive from "@radix-ui/react-dialog"
4
+ import { Dialog as DialogPrimitive } from "radix-ui"
5
5
 
6
6
  import { cn } from "@/lib/utils"
7
7
  import { Button } from "@/components/ui/button"
@@ -1,6 +1,22 @@
1
1
  "use client"
2
2
 
3
3
  import * as React from "react"
4
- import { DirectionProvider, useDirection } from "@radix-ui/react-direction"
4
+ import { Direction } from "radix-ui"
5
+
6
+ function DirectionProvider({
7
+ dir,
8
+ direction,
9
+ children,
10
+ }: React.ComponentProps<typeof Direction.DirectionProvider> & {
11
+ direction?: React.ComponentProps<typeof Direction.DirectionProvider>["dir"]
12
+ }) {
13
+ return (
14
+ <Direction.DirectionProvider dir={direction ?? dir}>
15
+ {children}
16
+ </Direction.DirectionProvider>
17
+ )
18
+ }
19
+
20
+ const useDirection = Direction.useDirection
5
21
 
6
22
  export { DirectionProvider, useDirection }
@@ -1,7 +1,7 @@
1
1
  "use client"
2
2
 
3
3
  import * as React from "react"
4
- import * as DropdownMenuPrimitive from "@radix-ui/react-dropdown-menu"
4
+ import { DropdownMenu as DropdownMenuPrimitive } from "radix-ui"
5
5
 
6
6
  import { cn } from "@/lib/utils"
7
7
  import { CheckIcon, ChevronRightIcon } from "lucide-react"
@@ -1,5 +1,5 @@
1
1
  import * as React from "react"
2
- import * as HoverCardPrimitive from "@radix-ui/react-hover-card"
2
+ import { HoverCard as HoverCardPrimitive } from "radix-ui"
3
3
 
4
4
  import { cn } from "@/lib/utils"
5
5
 
@@ -1,6 +1,6 @@
1
1
  import * as React from "react"
2
2
  import { cva, type VariantProps } from "class-variance-authority"
3
- import { Slot } from "@radix-ui/react-slot"
3
+ import { Slot } from "radix-ui"
4
4
 
5
5
  import { cn } from "@/lib/utils"
6
6
  import { Separator } from "@/components/ui/separator"
@@ -63,7 +63,7 @@ function Item({
63
63
  ...props
64
64
  }: React.ComponentProps<"div"> &
65
65
  VariantProps<typeof itemVariants> & { asChild?: boolean }) {
66
- const Comp = asChild ? Slot : "div"
66
+ const Comp = asChild ? Slot.Root : "div"
67
67
  return (
68
68
  <Comp
69
69
  data-slot="item"
@@ -1,5 +1,5 @@
1
1
  import * as React from "react"
2
- import * as LabelPrimitive from "@radix-ui/react-label"
2
+ import { Label as LabelPrimitive } from "radix-ui"
3
3
 
4
4
  import { cn } from "@/lib/utils"
5
5
 
@@ -1,7 +1,7 @@
1
1
  "use client"
2
2
 
3
3
  import * as React from "react"
4
- import * as MenubarPrimitive from "@radix-ui/react-menubar"
4
+ import { Menubar as MenubarPrimitive } from "radix-ui"
5
5
 
6
6
  import { cn } from "@/lib/utils"
7
7
  import { CheckIcon, ChevronRightIcon } from "lucide-react"
@@ -1,6 +1,6 @@
1
1
  import * as React from "react"
2
2
  import { cva } from "class-variance-authority"
3
- import * as NavigationMenuPrimitive from "@radix-ui/react-navigation-menu"
3
+ import { NavigationMenu as NavigationMenuPrimitive } from "radix-ui"
4
4
 
5
5
  import { cn } from "@/lib/utils"
6
6
  import { ChevronDownIcon } from "lucide-react"
@@ -1,5 +1,5 @@
1
1
  import * as React from "react"
2
- import * as PopoverPrimitive from "@radix-ui/react-popover"
2
+ import { Popover as PopoverPrimitive } from "radix-ui"
3
3
 
4
4
  import { cn } from "@/lib/utils"
5
5
 
@@ -1,7 +1,7 @@
1
1
  "use client"
2
2
 
3
3
  import * as React from "react"
4
- import * as ProgressPrimitive from "@radix-ui/react-progress"
4
+ import { Progress as ProgressPrimitive } from "radix-ui"
5
5
 
6
6
  import { cn } from "@/lib/utils"
7
7
 
@@ -1,5 +1,5 @@
1
1
  import * as React from "react"
2
- import * as RadioGroupPrimitive from "@radix-ui/react-radio-group"
2
+ import { RadioGroup as RadioGroupPrimitive } from "radix-ui"
3
3
 
4
4
  import { cn } from "@/lib/utils"
5
5
 
@@ -1,5 +1,5 @@
1
1
  import * as React from "react"
2
- import * as ScrollAreaPrimitive from "@radix-ui/react-scroll-area"
2
+ import { ScrollArea as ScrollAreaPrimitive } from "radix-ui"
3
3
 
4
4
  import { cn } from "@/lib/utils"
5
5
 
@@ -1,7 +1,7 @@
1
1
  "use client"
2
2
 
3
3
  import * as React from "react"
4
- import * as SelectPrimitive from "@radix-ui/react-select"
4
+ import { Select as SelectPrimitive } from "radix-ui"
5
5
 
6
6
  import { cn } from "@/lib/utils"
7
7
  import { ChevronDownIcon, CheckIcon, ChevronUpIcon } from "lucide-react"
@@ -1,5 +1,5 @@
1
1
  import * as React from "react"
2
- import * as SeparatorPrimitive from "@radix-ui/react-separator"
2
+ import { Separator as SeparatorPrimitive } from "radix-ui"
3
3
 
4
4
  import { cn } from "@/lib/utils"
5
5
 
@@ -1,5 +1,5 @@
1
1
  import * as React from "react"
2
- import * as SheetPrimitive from "@radix-ui/react-dialog"
2
+ import { Dialog as SheetPrimitive } from "radix-ui"
3
3
 
4
4
  import { cn } from "@/lib/utils"
5
5
  import { Button } from "@/components/ui/button"
@@ -1,6 +1,6 @@
1
1
  import * as React from "react"
2
2
  import { cva, type VariantProps } from "class-variance-authority"
3
- import { Slot } from "@radix-ui/react-slot"
3
+ import { Slot } from "radix-ui"
4
4
 
5
5
  import { useIsMobile } from "@/hooks/use-mobile"
6
6
  import { cn } from "@/lib/utils"
@@ -398,7 +398,7 @@ function SidebarGroupLabel({
398
398
  asChild = false,
399
399
  ...props
400
400
  }: React.ComponentProps<"div"> & { asChild?: boolean }) {
401
- const Comp = asChild ? Slot : "div"
401
+ const Comp = asChild ? Slot.Root : "div"
402
402
 
403
403
  return (
404
404
  <Comp
@@ -418,7 +418,7 @@ function SidebarGroupAction({
418
418
  asChild = false,
419
419
  ...props
420
420
  }: React.ComponentProps<"button"> & { asChild?: boolean }) {
421
- const Comp = asChild ? Slot : "button"
421
+ const Comp = asChild ? Slot.Root : "button"
422
422
 
423
423
  return (
424
424
  <Comp
@@ -504,7 +504,7 @@ function SidebarMenuButton({
504
504
  isActive?: boolean
505
505
  tooltip?: string | React.ComponentProps<typeof TooltipContent>
506
506
  } & VariantProps<typeof sidebarMenuButtonVariants>) {
507
- const Comp = asChild ? Slot : "button"
507
+ const Comp = asChild ? Slot.Root : "button"
508
508
  const { isMobile, state } = useSidebar()
509
509
 
510
510
  const button = (
@@ -550,7 +550,7 @@ function SidebarMenuAction({
550
550
  asChild?: boolean
551
551
  showOnHover?: boolean
552
552
  }) {
553
- const Comp = asChild ? Slot : "button"
553
+ const Comp = asChild ? Slot.Root : "button"
554
554
 
555
555
  return (
556
556
  <Comp
@@ -661,7 +661,7 @@ function SidebarMenuSubButton({
661
661
  size?: "sm" | "md"
662
662
  isActive?: boolean
663
663
  }) {
664
- const Comp = asChild ? Slot : "a"
664
+ const Comp = asChild ? Slot.Root : "a"
665
665
 
666
666
  return (
667
667
  <Comp
@@ -1,7 +1,7 @@
1
1
  "use client"
2
2
 
3
3
  import * as React from "react"
4
- import * as SliderPrimitive from "@radix-ui/react-slider"
4
+ import { Slider as SliderPrimitive } from "radix-ui"
5
5
 
6
6
  import { cn } from "@/lib/utils"
7
7
 
@@ -1,7 +1,7 @@
1
1
  "use client"
2
2
 
3
3
  import * as React from "react"
4
- import * as SwitchPrimitive from "@radix-ui/react-switch"
4
+ import { Switch as SwitchPrimitive } from "radix-ui"
5
5
 
6
6
  import { cn } from "@/lib/utils"
7
7
 
@@ -2,7 +2,7 @@
2
2
 
3
3
  import * as React from "react"
4
4
  import { cva, type VariantProps } from "class-variance-authority"
5
- import * as TabsPrimitive from "@radix-ui/react-tabs"
5
+ import { Tabs as TabsPrimitive } from "radix-ui"
6
6
 
7
7
  import { cn } from "@/lib/utils"
8
8
 
@@ -2,7 +2,7 @@
2
2
 
3
3
  import * as React from "react"
4
4
  import { type VariantProps } from "class-variance-authority"
5
- import * as ToggleGroupPrimitive from "@radix-ui/react-toggle-group"
5
+ import { ToggleGroup as ToggleGroupPrimitive } from "radix-ui"
6
6
 
7
7
  import { cn } from "@/lib/utils"
8
8
  import { toggleVariants } from "@/components/ui/toggle"