upfynai-code 0.1.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 (65) hide show
  1. package/LICENSE +22 -0
  2. package/bin/cli.js +86 -0
  3. package/dist/assets/CanvasPanel-B48gAKVY.js +538 -0
  4. package/dist/assets/CanvasPanel-B48gAKVY.js.map +1 -0
  5. package/dist/assets/CanvasPanel-BsOG3EVs.css +1 -0
  6. package/dist/assets/index-CEhTwG68.css +1 -0
  7. package/dist/assets/index-GqAGWpJI.js +70 -0
  8. package/dist/assets/index-GqAGWpJI.js.map +1 -0
  9. package/dist/index.html +18 -0
  10. package/index.html +17 -0
  11. package/package.json +67 -0
  12. package/src/App.tsx +226 -0
  13. package/src/components/canvas/CanvasPanel.tsx +62 -0
  14. package/src/components/canvas/layout/graph-builder.ts +136 -0
  15. package/src/components/canvas/shapes/CompactionNodeShape.tsx +76 -0
  16. package/src/components/canvas/shapes/SessionNodeShape.tsx +93 -0
  17. package/src/components/canvas/shapes/StatuslineWidgetShape.tsx +125 -0
  18. package/src/components/canvas/shapes/TextResponseNodeShape.tsx +86 -0
  19. package/src/components/canvas/shapes/ToolCallNodeShape.tsx +107 -0
  20. package/src/components/canvas/shapes/ToolResultNodeShape.tsx +87 -0
  21. package/src/components/canvas/shapes/shared-styles.ts +35 -0
  22. package/src/components/chat/ChatPanel.tsx +96 -0
  23. package/src/components/chat/InputBar.tsx +81 -0
  24. package/src/components/chat/MessageList.tsx +130 -0
  25. package/src/components/chat/PermissionDialog.tsx +70 -0
  26. package/src/components/layout/FolderSelector.tsx +152 -0
  27. package/src/components/layout/ModelSelector.tsx +65 -0
  28. package/src/components/layout/SessionManager.tsx +115 -0
  29. package/src/components/statusline/StatuslineBar.tsx +114 -0
  30. package/src/main.tsx +10 -0
  31. package/src/server/claude-session.ts +156 -0
  32. package/src/server/index.ts +149 -0
  33. package/src/services/stream-consumer.ts +330 -0
  34. package/src/statusline-core/bin/statusline.sh +121 -0
  35. package/src/statusline-core/commands/sls-config.md +42 -0
  36. package/src/statusline-core/commands/sls-doctor.md +35 -0
  37. package/src/statusline-core/commands/sls-help.md +48 -0
  38. package/src/statusline-core/commands/sls-layout.md +38 -0
  39. package/src/statusline-core/commands/sls-preview.md +34 -0
  40. package/src/statusline-core/commands/sls-theme.md +40 -0
  41. package/src/statusline-core/installer.js +228 -0
  42. package/src/statusline-core/layouts/compact.sh +21 -0
  43. package/src/statusline-core/layouts/full.sh +62 -0
  44. package/src/statusline-core/layouts/standard.sh +39 -0
  45. package/src/statusline-core/lib/core.sh +389 -0
  46. package/src/statusline-core/lib/helpers.sh +81 -0
  47. package/src/statusline-core/lib/json-parser.sh +71 -0
  48. package/src/statusline-core/themes/catppuccin.sh +32 -0
  49. package/src/statusline-core/themes/default.sh +37 -0
  50. package/src/statusline-core/themes/gruvbox.sh +32 -0
  51. package/src/statusline-core/themes/nord.sh +32 -0
  52. package/src/statusline-core/themes/tokyo-night.sh +32 -0
  53. package/src/store/canvas-store.ts +50 -0
  54. package/src/store/chat-store.ts +60 -0
  55. package/src/store/permission-store.ts +29 -0
  56. package/src/store/session-store.ts +52 -0
  57. package/src/store/statusline-store.ts +160 -0
  58. package/src/styles/global.css +117 -0
  59. package/src/themes/index.ts +149 -0
  60. package/src/types/canvas-graph.ts +24 -0
  61. package/src/types/sdk-messages.ts +156 -0
  62. package/src/types/statusline-fields.ts +67 -0
  63. package/src/vite-env.d.ts +1 -0
  64. package/tsconfig.json +26 -0
  65. package/vite.config.ts +24 -0
package/LICENSE ADDED
@@ -0,0 +1,22 @@
1
+ UC UpfynAI-Code — Proprietary License
2
+
3
+ Copyright (c) 2024-2026 Thinqmesh Technologies
4
+ Developed by Anit Chaudhary
5
+
6
+ All Rights Reserved.
7
+
8
+ This software and associated documentation files (the "Software") are the
9
+ proprietary property of Thinqmesh Technologies. Unauthorized copying,
10
+ modification, distribution, or use of this Software, via any medium, is
11
+ strictly prohibited without express written permission from Thinqmesh
12
+ Technologies.
13
+
14
+ The Software is provided "AS IS", without warranty of any kind, express or
15
+ implied. In no event shall the authors or copyright holders be liable for
16
+ any claim, damages, or other liability arising from the use of the Software.
17
+
18
+ The statusline component included in this Software is an integral,
19
+ non-removable part of the application. Attempting to remove, disable, or
20
+ circumvent the statusline component is a violation of this license.
21
+
22
+ For licensing inquiries: https://upfyn.ai
package/bin/cli.js ADDED
@@ -0,0 +1,86 @@
1
+ #!/usr/bin/env node
2
+
3
+ import { createServer } from 'node:http';
4
+ import { fileURLToPath } from 'node:url';
5
+ import path from 'node:path';
6
+ import { spawn } from 'node:child_process';
7
+ import { ensureStatuslineInstalled } from '../src/statusline-core/installer.js';
8
+
9
+ const __dirname = path.dirname(fileURLToPath(import.meta.url));
10
+ const ROOT = path.resolve(__dirname, '..');
11
+ const API_PORT = 3210;
12
+ const VITE_PORT = 5179;
13
+
14
+ async function main() {
15
+ const args = process.argv.slice(2);
16
+ const cwd = args[0] || process.cwd();
17
+
18
+ console.log('\n \x1b[38;2;168;85;247m╔══════════════════════════════════════════════════════╗\x1b[0m');
19
+ console.log(' \x1b[38;2;168;85;247m║\x1b[0m \x1b[38;2;168;85;247m║\x1b[0m');
20
+ console.log(' \x1b[38;2;168;85;247m║\x1b[0m \x1b[1m\x1b[38;2;236;72;153mUC\x1b[0m \x1b[1m\x1b[38;2;168;85;247mUpfynAI-Code\x1b[0m \x1b[38;2;168;85;247m║\x1b[0m');
21
+ console.log(' \x1b[38;2;168;85;247m║\x1b[0m Visual AI Coding Interface with Built-in Statusline\x1b[38;2;168;85;247m║\x1b[0m');
22
+ console.log(' \x1b[38;2;168;85;247m║\x1b[0m \x1b[38;2;168;85;247m║\x1b[0m');
23
+ console.log(' \x1b[38;2;168;85;247m║\x1b[0m \x1b[38;2;6;182;212mThinqmesh Technologies\x1b[0m \x1b[38;2;168;85;247m║\x1b[0m');
24
+ console.log(' \x1b[38;2;168;85;247m║\x1b[0m \x1b[38;2;120;120;130mDeveloped by Anit Chaudhary\x1b[0m \x1b[38;2;168;85;247m║\x1b[0m');
25
+ console.log(' \x1b[38;2;168;85;247m║\x1b[0m \x1b[38;2;168;85;247m║\x1b[0m');
26
+ console.log(' \x1b[38;2;168;85;247m╚══════════════════════════════════════════════════════╝\x1b[0m\n');
27
+
28
+ // Auto-configure statusline (idempotent — only installs on first run)
29
+ try {
30
+ const result = ensureStatuslineInstalled();
31
+ if (result.installed) {
32
+ console.log(' \x1b[38;2;6;182;212m→\x1b[0m Statusline configured (first run setup complete)');
33
+ } else {
34
+ console.log(' \x1b[38;2;34;197;94m✓\x1b[0m Statusline ready');
35
+ }
36
+ } catch (err) {
37
+ console.warn(' \x1b[33m⚠\x1b[0m Statusline auto-install skipped:', err.message);
38
+ }
39
+
40
+ // Start the API server
41
+ console.log(` \x1b[38;2;6;182;212m→\x1b[0m Starting API server on port ${API_PORT}...`);
42
+ const apiServer = spawn('node', ['--loader', 'tsx/esm', path.join(ROOT, 'src/server/index.ts')], {
43
+ cwd: ROOT,
44
+ stdio: 'inherit',
45
+ env: {
46
+ ...process.env,
47
+ UPFYN_PORT: String(API_PORT),
48
+ UPFYN_CWD: cwd,
49
+ },
50
+ });
51
+
52
+ apiServer.on('error', (err) => {
53
+ console.error(' \x1b[31m✗\x1b[0m API server failed:', err.message);
54
+ // Fallback: try without tsx loader
55
+ console.log(' \x1b[33m→\x1b[0m Trying Vite dev mode instead...');
56
+ startViteDev(cwd);
57
+ });
58
+
59
+ // Start Vite dev server
60
+ console.log(` \x1b[38;2;6;182;212m→\x1b[0m Starting Vite dev server on port ${VITE_PORT}...`);
61
+ startViteDev(cwd);
62
+ }
63
+
64
+ function startViteDev(cwd) {
65
+ const vite = spawn('npx', ['vite', '--port', String(VITE_PORT), '--open'], {
66
+ cwd: ROOT,
67
+ stdio: 'inherit',
68
+ shell: true,
69
+ env: {
70
+ ...process.env,
71
+ UPFYN_CWD: cwd,
72
+ },
73
+ });
74
+
75
+ vite.on('error', (err) => {
76
+ console.error(' \x1b[31m✗\x1b[0m Vite failed:', err.message);
77
+ process.exit(1);
78
+ });
79
+
80
+ process.on('SIGINT', () => {
81
+ vite.kill();
82
+ process.exit(0);
83
+ });
84
+ }
85
+
86
+ main().catch(console.error);