made system changes

This commit is contained in:
SinachPat
2026-04-23 09:39:01 +01:00
parent 71296f82af
commit dc177c7689
49 changed files with 6256 additions and 0 deletions
+21
View File
@@ -0,0 +1,21 @@
{
"name": "@originmain/agent-bridge",
"version": "0.0.1",
"private": true,
"type": "module",
"exports": {
".": "./src/index.ts"
},
"scripts": {
"typecheck": "tsc --noEmit"
},
"dependencies": {
"@originmain/diff-engine": "workspace:*",
"@originmain/origin-graph": "workspace:*",
"@originmain/ai-layer": "workspace:*",
"zod": "^3.0.0"
},
"devDependencies": {
"typescript": "^5.5.0"
}
}
+1
View File
@@ -0,0 +1 @@
export {};
+8
View File
@@ -0,0 +1,8 @@
{
"extends": "../../tsconfig.base.json",
"compilerOptions": {
"noEmit": true
},
"include": ["src"],
"exclude": ["node_modules"]
}
+19
View File
@@ -0,0 +1,19 @@
{
"name": "@originmain/ai-layer",
"version": "0.0.1",
"private": true,
"type": "module",
"exports": {
".": "./src/index.ts"
},
"scripts": {
"typecheck": "tsc --noEmit"
},
"dependencies": {
"@originmain/diff-engine": "workspace:*",
"zod": "^3.0.0"
},
"devDependencies": {
"typescript": "^5.5.0"
}
}
+1
View File
@@ -0,0 +1 @@
export {};
+8
View File
@@ -0,0 +1,8 @@
{
"extends": "../../tsconfig.base.json",
"compilerOptions": {
"noEmit": true
},
"include": ["src"],
"exclude": ["node_modules"]
}
+6
View File
@@ -0,0 +1,6 @@
/// <reference types="next" />
/// <reference types="next/image-types/global" />
/// <reference path="./.next/types/routes.d.ts" />
// NOTE: This file should not be edited
// see https://nextjs.org/docs/app/api-reference/config/typescript for more information.
+10
View File
@@ -0,0 +1,10 @@
import type { NextConfig } from 'next';
const nextConfig: NextConfig = {
transpilePackages: ['@originmain/ui', '@fluentui/react-components'],
experimental: {
optimizePackageImports: ['@fluentui/react-components'],
},
};
export default nextConfig;
+29
View File
@@ -0,0 +1,29 @@
{
"name": "@originmain/app",
"version": "0.0.1",
"private": true,
"scripts": {
"dev": "next dev",
"build": "next build",
"start": "next start",
"typecheck": "tsc --noEmit"
},
"dependencies": {
"@originmain/ui": "workspace:*",
"@originmain/diff-engine": "workspace:*",
"@originmain/origin-graph": "workspace:*",
"@originmain/renderer": "workspace:*",
"@fluentui/react-components": "^9.54.0",
"next": "^15.1.0",
"react": "^19.0.0",
"react-dom": "^19.0.0",
"zustand": "^5.0.0",
"@tanstack/react-query": "^5.62.0"
},
"devDependencies": {
"@types/node": "^22.0.0",
"@types/react": "^19.0.0",
"@types/react-dom": "^19.0.0",
"typescript": "^5.5.0"
}
}
+15
View File
@@ -0,0 +1,15 @@
*, *::before, *::after {
box-sizing: border-box;
margin: 0;
padding: 0;
}
html, body, #__next {
height: 100%;
overflow: hidden;
}
body {
font-family: 'Segoe UI Variable', 'Segoe UI', system-ui, -apple-system, sans-serif;
background: #f5f5f5;
}
+18
View File
@@ -0,0 +1,18 @@
import type { ReactNode } from 'react';
import { Providers } from './providers';
import './globals.css';
export const metadata = {
title: 'Originmain',
description: 'AI-Native Design Engineering Platform',
};
export default function RootLayout({ children }: { children: ReactNode }) {
return (
<html lang="en">
<body>
<Providers>{children}</Providers>
</body>
</html>
);
}
+9
View File
@@ -0,0 +1,9 @@
export default function Home() {
return (
<main style={{ display: 'flex', alignItems: 'center', justifyContent: 'center', height: '100%' }}>
<p style={{ fontFamily: 'system-ui, sans-serif', color: '#888', fontSize: '0.875rem' }}>
Originmain coming soon
</p>
</main>
);
}
+13
View File
@@ -0,0 +1,13 @@
'use client';
import type { ReactNode } from 'react';
import { FluentProvider } from '@fluentui/react-components';
import { originmainLightTheme } from '@originmain/ui';
export function Providers({ children }: { children: ReactNode }) {
return (
<FluentProvider theme={originmainLightTheme} style={{ height: '100%' }}>
{children}
</FluentProvider>
);
}
+1
View File
@@ -0,0 +1 @@
export {};
+31
View File
@@ -0,0 +1,31 @@
import { create } from 'zustand';
interface ViewportState {
panX: number;
panY: number;
zoom: number;
setPan: (x: number, y: number) => void;
setZoom: (zoom: number, originX?: number, originY?: number) => void;
reset: () => void;
}
export const useViewport = create<ViewportState>((set, get) => ({
panX: 0,
panY: 0,
zoom: 1,
setPan: (x, y) => set({ panX: x, panY: y }),
setZoom: (zoom, originX = 0, originY = 0) => {
const prev = get();
const clampedZoom = Math.min(Math.max(zoom, 0.1), 8);
const scale = clampedZoom / prev.zoom;
set({
zoom: clampedZoom,
panX: originX - (originX - prev.panX) * scale,
panY: originY - (originY - prev.panY) * scale,
});
},
reset: () => set({ panX: 0, panY: 0, zoom: 1 }),
}));
+25
View File
@@ -0,0 +1,25 @@
{
"extends": "../../tsconfig.base.json",
"compilerOptions": {
"plugins": [
{
"name": "next"
}
],
"noEmit": true,
"allowJs": true,
"incremental": true,
"esModuleInterop": true,
"resolveJsonModule": true,
"jsx": "preserve"
},
"include": [
"next.config.ts",
"src",
".next/types/**/*.ts"
],
"exclude": [
"node_modules",
".next"
]
}
+21
View File
@@ -0,0 +1,21 @@
{
"name": "@originmain/diff-engine",
"version": "0.0.1",
"private": true,
"type": "module",
"exports": {
".": "./src/index.ts"
},
"scripts": {
"typecheck": "tsc --noEmit",
"test": "vitest run --coverage"
},
"dependencies": {
"zod": "^3.0.0"
},
"devDependencies": {
"typescript": "^5.5.0",
"vitest": "^2.0.0",
"@vitest/coverage-v8": "^2.0.0"
}
}
+1
View File
@@ -0,0 +1 @@
export {};
+8
View File
@@ -0,0 +1,8 @@
{
"extends": "../../tsconfig.base.json",
"compilerOptions": {
"noEmit": true
},
"include": ["src", "__tests__"],
"exclude": ["node_modules"]
}
+14
View File
@@ -0,0 +1,14 @@
{
"name": "@originmain/e2e",
"version": "0.0.1",
"private": true,
"type": "module",
"scripts": {
"test": "playwright test",
"typecheck": "tsc --noEmit"
},
"devDependencies": {
"@playwright/test": "^1.40.0",
"typescript": "^5.5.0"
}
}
+1
View File
@@ -0,0 +1 @@
// placeholder — Playwright tests added in Layer 11
+8
View File
@@ -0,0 +1,8 @@
{
"extends": "../../tsconfig.base.json",
"compilerOptions": {
"noEmit": true
},
"include": ["**/*.ts", "**/*.tsx"],
"exclude": ["node_modules"]
}
+19
View File
@@ -0,0 +1,19 @@
{
"name": "@originmain/integrations",
"version": "0.0.1",
"private": true,
"type": "module",
"exports": {
".": "./src/index.ts"
},
"scripts": {
"typecheck": "tsc --noEmit"
},
"dependencies": {
"@originmain/origin-graph": "workspace:*",
"zod": "^3.0.0"
},
"devDependencies": {
"typescript": "^5.5.0"
}
}
+1
View File
@@ -0,0 +1 @@
export {};
+8
View File
@@ -0,0 +1,8 @@
{
"extends": "../../tsconfig.base.json",
"compilerOptions": {
"noEmit": true
},
"include": ["src"],
"exclude": ["node_modules"]
}
+22
View File
@@ -0,0 +1,22 @@
{
"name": "@originmain/origin-graph",
"version": "0.0.1",
"private": true,
"type": "module",
"exports": {
".": "./src/index.ts"
},
"scripts": {
"typecheck": "tsc --noEmit",
"test": "vitest run --coverage"
},
"dependencies": {
"@originmain/diff-engine": "workspace:*",
"zod": "^3.0.0"
},
"devDependencies": {
"typescript": "^5.5.0",
"vitest": "^2.0.0",
"@vitest/coverage-v8": "^2.0.0"
}
}
+1
View File
@@ -0,0 +1 @@
export {};
+8
View File
@@ -0,0 +1,8 @@
{
"extends": "../../tsconfig.base.json",
"compilerOptions": {
"noEmit": true
},
"include": ["src", "__tests__"],
"exclude": ["node_modules"]
}
+16
View File
@@ -0,0 +1,16 @@
{
"name": "@originmain/renderer",
"version": "0.0.1",
"private": true,
"type": "module",
"exports": {
".": "./src/index.ts"
},
"scripts": {
"typecheck": "tsc --noEmit"
},
"devDependencies": {
"typescript": "^5.5.0",
"zod": "^3.0.0"
}
}
+1
View File
@@ -0,0 +1 @@
export {};
+8
View File
@@ -0,0 +1,8 @@
{
"extends": "../../tsconfig.base.json",
"compilerOptions": {
"noEmit": true
},
"include": ["src"],
"exclude": ["node_modules"]
}
+20
View File
@@ -0,0 +1,20 @@
{
"name": "@originmain/ui",
"version": "0.0.1",
"private": true,
"type": "module",
"exports": {
".": "./src/index.ts"
},
"scripts": {
"typecheck": "tsc --noEmit"
},
"dependencies": {
"@fluentui/react-components": "^9.54.0",
"react": "^19.0.0"
},
"devDependencies": {
"@types/react": "^19.0.0",
"typescript": "^5.5.0"
}
}
+1
View File
@@ -0,0 +1 @@
export { originmainLightTheme, originmainDarkTheme } from './themes/originmain-theme';
@@ -0,0 +1,23 @@
import { createLightTheme, createDarkTheme, type BrandVariants } from '@fluentui/react-components';
const cobaltBrand: BrandVariants = {
10: '#020B1A',
20: '#041630',
30: '#062246',
40: '#083060',
50: '#0A3E7A',
60: '#0C4C94',
70: '#0F52BA',
80: '#2A6CD4',
90: '#4C86E0',
100: '#70A0E8',
110: '#94BAEF',
120: '#B4CEF5',
130: '#CEE0F9',
140: '#E4EEFB',
150: '#F0F6FD',
160: '#F8FAFF',
};
export const originmainLightTheme = createLightTheme(cobaltBrand);
export const originmainDarkTheme = createDarkTheme(cobaltBrand);
+8
View File
@@ -0,0 +1,8 @@
{
"extends": "../../tsconfig.base.json",
"compilerOptions": {
"noEmit": true
},
"include": ["src"],
"exclude": ["node_modules"]
}