From 2e0d1e019cf9c58af82d00f085550fed00cd0d34 Mon Sep 17 00:00:00 2001 From: Samuel Bodin <1637651+bodinsamuel@users.noreply.github.com> Date: Tue, 17 Sep 2024 15:32:25 +0200 Subject: [PATCH] connect ui --- .eslintrc | 2 +- Dockerfile | 4 +- package-lock.json | 350 +++++++++--------- package.json | 2 +- packages/{ui-connect => connect-ui}/README.md | 0 .../components.json | 0 .../{ui-connect => connect-ui}/index.html | 0 .../{ui-connect => connect-ui}/package.json | 2 +- .../postcss.config.js | 0 .../{ui-connect => connect-ui}/src/App.tsx | 0 .../src/components/ui/button.tsx | 0 .../{ui-connect => connect-ui}/src/index.css | 0 .../src/lib/utils.ts | 0 .../{ui-connect => connect-ui}/src/main.tsx | 0 .../src/vite-env.d.ts | 0 .../tailwind.config.js | 0 .../{ui-connect => connect-ui}/tsconfig.json | 0 .../{ui-connect => connect-ui}/vite.config.ts | 0 tsconfig.build.json | 2 +- 19 files changed, 181 insertions(+), 181 deletions(-) rename packages/{ui-connect => connect-ui}/README.md (100%) rename packages/{ui-connect => connect-ui}/components.json (100%) rename packages/{ui-connect => connect-ui}/index.html (100%) rename packages/{ui-connect => connect-ui}/package.json (95%) rename packages/{ui-connect => connect-ui}/postcss.config.js (100%) rename packages/{ui-connect => connect-ui}/src/App.tsx (100%) rename packages/{ui-connect => connect-ui}/src/components/ui/button.tsx (100%) rename packages/{ui-connect => connect-ui}/src/index.css (100%) rename packages/{ui-connect => connect-ui}/src/lib/utils.ts (100%) rename packages/{ui-connect => connect-ui}/src/main.tsx (100%) rename packages/{ui-connect => connect-ui}/src/vite-env.d.ts (100%) rename packages/{ui-connect => connect-ui}/tailwind.config.js (100%) rename packages/{ui-connect => connect-ui}/tsconfig.json (100%) rename packages/{ui-connect => connect-ui}/vite.config.ts (100%) diff --git a/.eslintrc b/.eslintrc index 9baf664c71e..c06106f86cc 100644 --- a/.eslintrc +++ b/.eslintrc @@ -196,7 +196,7 @@ }, { "files": [ - "packages/ui-connect/**/*.tsx" + "packages/connect-ui/**/*.tsx" ], "plugins": [ "react", diff --git a/Dockerfile b/Dockerfile index f355b00b9e4..9ccea9ac551 100644 --- a/Dockerfile +++ b/Dockerfile @@ -32,7 +32,7 @@ COPY packages/scheduler/package.json ./packages/scheduler/package.json COPY packages/server/package.json ./packages/server/package.json COPY packages/shared/package.json ./packages/shared/package.json COPY packages/types/package.json ./packages/types/package.json -COPY packages/ui-connect/package.json ./packages/ui-connect/package.json +COPY packages/connect-ui/package.json ./packages/connect-ui/package.json COPY packages/utils/package.json ./packages/utils/package.json COPY packages/webapp/package.json ./packages/webapp/package.json COPY packages/webhooks/package.json ./packages/webhooks/package.json @@ -65,7 +65,7 @@ ENV REACT_APP_PUBLIC_SENTRY_KEY $sentry_key # Build the frontend RUN true \ && npm run -w @nangohq/webapp build \ - && npm run -w @nangohq/ui-connect build + && npm run -w @nangohq/connect-ui build # Clean src RUN true \ diff --git a/package-lock.json b/package-lock.json index 96cad9555e4..2bb4d9fa520 100644 --- a/package-lock.json +++ b/package-lock.json @@ -5398,6 +5398,10 @@ "react": ">=16.8.0" } }, + "node_modules/@nangohq/connect-ui": { + "resolved": "packages/connect-ui", + "link": true + }, "node_modules/@nangohq/data-ingestion": { "resolved": "packages/data-ingestion", "link": true @@ -5466,10 +5470,6 @@ "resolved": "packages/types", "link": true }, - "node_modules/@nangohq/ui-connect": { - "resolved": "packages/ui-connect", - "link": true - }, "node_modules/@nangohq/utils": { "resolved": "packages/utils", "link": true @@ -32753,6 +32753,177 @@ "url": "https://github.com/chalk/strip-ansi?sponsor=1" } }, + "packages/connect-ui": { + "name": "@nangohq/connect-ui", + "version": "0.0.0", + "devDependencies": { + "@radix-ui/react-slot": "1.1.0", + "@types/react": "18.3.3", + "@types/react-dom": "18.3.0", + "@vitejs/plugin-react-swc": "3.5.0", + "autoprefixer": "10.4.20", + "class-variance-authority": "0.7.0", + "clsx": "2.1.1", + "globals": "15.9.0", + "lucide-react": "0.441.0", + "postcss": "8.4.45", + "react": "18.3.1", + "react-dom": "18.3.1", + "tailwind-merge": "2.5.2", + "tailwindcss": "3.4.11", + "tailwindcss-animate": "1.0.7", + "typescript": "5.5.3", + "vite": "5.4.1" + } + }, + "packages/connect-ui/node_modules/@radix-ui/react-compose-refs": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@radix-ui/react-compose-refs/-/react-compose-refs-1.1.0.tgz", + "integrity": "sha512-b4inOtiaOnYf9KWyO3jAeeCG6FeyfY6ldiEPanbUjWd+xIk5wZeHa8yVwmrJ2vderhu/BQvzCrJI0lHd+wIiqw==", + "dev": true, + "peerDependencies": { + "@types/react": "*", + "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + } + } + }, + "packages/connect-ui/node_modules/@radix-ui/react-slot": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@radix-ui/react-slot/-/react-slot-1.1.0.tgz", + "integrity": "sha512-FUCf5XMfmW4dtYl69pdS4DbxKy8nj4M7SafBgPllysxmdachynNflAdp/gCsnYWNDnge6tI9onzMp5ARYc1KNw==", + "dev": true, + "dependencies": { + "@radix-ui/react-compose-refs": "1.1.0" + }, + "peerDependencies": { + "@types/react": "*", + "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + } + } + }, + "packages/connect-ui/node_modules/@types/react": { + "version": "18.3.3", + "resolved": "https://registry.npmjs.org/@types/react/-/react-18.3.3.tgz", + "integrity": "sha512-hti/R0pS0q1/xx+TsI73XIqk26eBsISZ2R0wUijXIngRK9R/e7Xw/cXVxQK7R5JjW+SV4zGcn5hXjudkN/pLIw==", + "dev": true, + "dependencies": { + "@types/prop-types": "*", + "csstype": "^3.0.2" + } + }, + "packages/connect-ui/node_modules/arg": { + "version": "5.0.2", + "resolved": "https://registry.npmjs.org/arg/-/arg-5.0.2.tgz", + "integrity": "sha512-PYjyFOLKQ9y57JvQ6QLo8dAgNqswh8M1RMJYdQduT6xbWSgK36P/Z/v+p888pM69jMMfS8Xd8F6I1kQ/I9HUGg==", + "dev": true + }, + "packages/connect-ui/node_modules/clsx": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/clsx/-/clsx-2.1.1.tgz", + "integrity": "sha512-eYm0QWBtUrBWZWG0d386OGAw16Z995PiOVo2B7bjWSbHedGl5e0ZWaq65kOGgUSNesEIDkB9ISbTg/JK9dhCZA==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "packages/connect-ui/node_modules/globals": { + "version": "15.9.0", + "resolved": "https://registry.npmjs.org/globals/-/globals-15.9.0.tgz", + "integrity": "sha512-SmSKyLLKFbSr6rptvP8izbyxJL4ILwqO9Jg23UA0sDlGlu58V59D1//I3vlc0KJphVdUR7vMjHIplYnzBxorQA==", + "dev": true, + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "packages/connect-ui/node_modules/postcss": { + "version": "8.4.45", + "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.4.45.tgz", + "integrity": "sha512-7KTLTdzdZZYscUc65XmjFiB73vBhBfbPztCYdUNvlaso9PrzjzcmjqBPR0lNGkcVlcO4BjiO5rK/qNz+XAen1Q==", + "dev": true, + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/postcss" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "dependencies": { + "nanoid": "^3.3.7", + "picocolors": "^1.0.1", + "source-map-js": "^1.2.0" + }, + "engines": { + "node": "^10 || ^12 || >=14" + } + }, + "packages/connect-ui/node_modules/tailwindcss": { + "version": "3.4.11", + "resolved": "https://registry.npmjs.org/tailwindcss/-/tailwindcss-3.4.11.tgz", + "integrity": "sha512-qhEuBcLemjSJk5ajccN9xJFtM/h0AVCPaA6C92jNP+M2J8kX+eMJHI7R2HFKUvvAsMpcfLILMCFYSeDwpMmlUg==", + "dev": true, + "dependencies": { + "@alloc/quick-lru": "^5.2.0", + "arg": "^5.0.2", + "chokidar": "^3.5.3", + "didyoumean": "^1.2.2", + "dlv": "^1.1.3", + "fast-glob": "^3.3.0", + "glob-parent": "^6.0.2", + "is-glob": "^4.0.3", + "jiti": "^1.21.0", + "lilconfig": "^2.1.0", + "micromatch": "^4.0.5", + "normalize-path": "^3.0.0", + "object-hash": "^3.0.0", + "picocolors": "^1.0.0", + "postcss": "^8.4.23", + "postcss-import": "^15.1.0", + "postcss-js": "^4.0.1", + "postcss-load-config": "^4.0.1", + "postcss-nested": "^6.0.1", + "postcss-selector-parser": "^6.0.11", + "resolve": "^1.22.2", + "sucrase": "^3.32.0" + }, + "bin": { + "tailwind": "lib/cli.js", + "tailwindcss": "lib/cli.js" + }, + "engines": { + "node": ">=14.0.0" + } + }, + "packages/connect-ui/node_modules/typescript": { + "version": "5.5.3", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.5.3.tgz", + "integrity": "sha512-/hreyEujaB0w76zKo6717l3L0o/qEUtRgdvUBvlkhoWeOVMjMuHNHk0BRBzikzuGDqNmPQbg5ifMEqsHLiIUcQ==", + "dev": true, + "bin": { + "tsc": "bin/tsc", + "tsserver": "bin/tsserver" + }, + "engines": { + "node": ">=14.17" + } + }, "packages/data-ingestion": { "name": "@nangohq/data-ingestion", "version": "1.0.0", @@ -35749,177 +35920,6 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "packages/ui-connect": { - "name": "@nangohq/ui-connect", - "version": "0.0.0", - "devDependencies": { - "@radix-ui/react-slot": "1.1.0", - "@types/react": "18.3.3", - "@types/react-dom": "18.3.0", - "@vitejs/plugin-react-swc": "3.5.0", - "autoprefixer": "10.4.20", - "class-variance-authority": "0.7.0", - "clsx": "2.1.1", - "globals": "15.9.0", - "lucide-react": "0.441.0", - "postcss": "8.4.45", - "react": "18.3.1", - "react-dom": "18.3.1", - "tailwind-merge": "2.5.2", - "tailwindcss": "3.4.11", - "tailwindcss-animate": "1.0.7", - "typescript": "5.5.3", - "vite": "5.4.1" - } - }, - "packages/ui-connect/node_modules/@radix-ui/react-compose-refs": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@radix-ui/react-compose-refs/-/react-compose-refs-1.1.0.tgz", - "integrity": "sha512-b4inOtiaOnYf9KWyO3jAeeCG6FeyfY6ldiEPanbUjWd+xIk5wZeHa8yVwmrJ2vderhu/BQvzCrJI0lHd+wIiqw==", - "dev": true, - "peerDependencies": { - "@types/react": "*", - "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" - }, - "peerDependenciesMeta": { - "@types/react": { - "optional": true - } - } - }, - "packages/ui-connect/node_modules/@radix-ui/react-slot": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/@radix-ui/react-slot/-/react-slot-1.1.0.tgz", - "integrity": "sha512-FUCf5XMfmW4dtYl69pdS4DbxKy8nj4M7SafBgPllysxmdachynNflAdp/gCsnYWNDnge6tI9onzMp5ARYc1KNw==", - "dev": true, - "dependencies": { - "@radix-ui/react-compose-refs": "1.1.0" - }, - "peerDependencies": { - "@types/react": "*", - "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" - }, - "peerDependenciesMeta": { - "@types/react": { - "optional": true - } - } - }, - "packages/ui-connect/node_modules/@types/react": { - "version": "18.3.3", - "resolved": "https://registry.npmjs.org/@types/react/-/react-18.3.3.tgz", - "integrity": "sha512-hti/R0pS0q1/xx+TsI73XIqk26eBsISZ2R0wUijXIngRK9R/e7Xw/cXVxQK7R5JjW+SV4zGcn5hXjudkN/pLIw==", - "dev": true, - "dependencies": { - "@types/prop-types": "*", - "csstype": "^3.0.2" - } - }, - "packages/ui-connect/node_modules/arg": { - "version": "5.0.2", - "resolved": "https://registry.npmjs.org/arg/-/arg-5.0.2.tgz", - "integrity": "sha512-PYjyFOLKQ9y57JvQ6QLo8dAgNqswh8M1RMJYdQduT6xbWSgK36P/Z/v+p888pM69jMMfS8Xd8F6I1kQ/I9HUGg==", - "dev": true - }, - "packages/ui-connect/node_modules/clsx": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/clsx/-/clsx-2.1.1.tgz", - "integrity": "sha512-eYm0QWBtUrBWZWG0d386OGAw16Z995PiOVo2B7bjWSbHedGl5e0ZWaq65kOGgUSNesEIDkB9ISbTg/JK9dhCZA==", - "dev": true, - "engines": { - "node": ">=6" - } - }, - "packages/ui-connect/node_modules/globals": { - "version": "15.9.0", - "resolved": "https://registry.npmjs.org/globals/-/globals-15.9.0.tgz", - "integrity": "sha512-SmSKyLLKFbSr6rptvP8izbyxJL4ILwqO9Jg23UA0sDlGlu58V59D1//I3vlc0KJphVdUR7vMjHIplYnzBxorQA==", - "dev": true, - "engines": { - "node": ">=18" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "packages/ui-connect/node_modules/postcss": { - "version": "8.4.45", - "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.4.45.tgz", - "integrity": "sha512-7KTLTdzdZZYscUc65XmjFiB73vBhBfbPztCYdUNvlaso9PrzjzcmjqBPR0lNGkcVlcO4BjiO5rK/qNz+XAen1Q==", - "dev": true, - "funding": [ - { - "type": "opencollective", - "url": "https://opencollective.com/postcss/" - }, - { - "type": "tidelift", - "url": "https://tidelift.com/funding/github/npm/postcss" - }, - { - "type": "github", - "url": "https://github.com/sponsors/ai" - } - ], - "dependencies": { - "nanoid": "^3.3.7", - "picocolors": "^1.0.1", - "source-map-js": "^1.2.0" - }, - "engines": { - "node": "^10 || ^12 || >=14" - } - }, - "packages/ui-connect/node_modules/tailwindcss": { - "version": "3.4.11", - "resolved": "https://registry.npmjs.org/tailwindcss/-/tailwindcss-3.4.11.tgz", - "integrity": "sha512-qhEuBcLemjSJk5ajccN9xJFtM/h0AVCPaA6C92jNP+M2J8kX+eMJHI7R2HFKUvvAsMpcfLILMCFYSeDwpMmlUg==", - "dev": true, - "dependencies": { - "@alloc/quick-lru": "^5.2.0", - "arg": "^5.0.2", - "chokidar": "^3.5.3", - "didyoumean": "^1.2.2", - "dlv": "^1.1.3", - "fast-glob": "^3.3.0", - "glob-parent": "^6.0.2", - "is-glob": "^4.0.3", - "jiti": "^1.21.0", - "lilconfig": "^2.1.0", - "micromatch": "^4.0.5", - "normalize-path": "^3.0.0", - "object-hash": "^3.0.0", - "picocolors": "^1.0.0", - "postcss": "^8.4.23", - "postcss-import": "^15.1.0", - "postcss-js": "^4.0.1", - "postcss-load-config": "^4.0.1", - "postcss-nested": "^6.0.1", - "postcss-selector-parser": "^6.0.11", - "resolve": "^1.22.2", - "sucrase": "^3.32.0" - }, - "bin": { - "tailwind": "lib/cli.js", - "tailwindcss": "lib/cli.js" - }, - "engines": { - "node": ">=14.0.0" - } - }, - "packages/ui-connect/node_modules/typescript": { - "version": "5.5.3", - "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.5.3.tgz", - "integrity": "sha512-/hreyEujaB0w76zKo6717l3L0o/qEUtRgdvUBvlkhoWeOVMjMuHNHk0BRBzikzuGDqNmPQbg5ifMEqsHLiIUcQ==", - "dev": true, - "bin": { - "tsc": "bin/tsc", - "tsserver": "bin/tsserver" - }, - "engines": { - "node": ">=14.17" - } - }, "packages/utils": { "name": "@nangohq/utils", "version": "1.0.0", diff --git a/package.json b/package.json index 4750b07789c..8a700ece016 100644 --- a/package.json +++ b/package.json @@ -31,7 +31,7 @@ "persist:dev:watch": "npm run dev -w @nangohq/nango-persist", "orchestrator:dev:watch": "npm run dev -w @nangohq/nango-orchestrator", "webapp:dev:watch": "cd ./packages/webapp && npm run start:local", - "ui-connect:dev:watch": "cd ./packages/ui-connect && npm run dev", + "connect-ui:dev:watch": "cd ./packages/connect-ui && npm run dev", "prepare": "husky install", "build:watch": "tsc -b -w --preserveWatchOutput tsconfig.build.json", "dev:watch": "npm run -w nango copy:files && npm run build:watch", diff --git a/packages/ui-connect/README.md b/packages/connect-ui/README.md similarity index 100% rename from packages/ui-connect/README.md rename to packages/connect-ui/README.md diff --git a/packages/ui-connect/components.json b/packages/connect-ui/components.json similarity index 100% rename from packages/ui-connect/components.json rename to packages/connect-ui/components.json diff --git a/packages/ui-connect/index.html b/packages/connect-ui/index.html similarity index 100% rename from packages/ui-connect/index.html rename to packages/connect-ui/index.html diff --git a/packages/ui-connect/package.json b/packages/connect-ui/package.json similarity index 95% rename from packages/ui-connect/package.json rename to packages/connect-ui/package.json index 257b0866a51..18c11b29ffc 100644 --- a/packages/ui-connect/package.json +++ b/packages/connect-ui/package.json @@ -1,5 +1,5 @@ { - "name": "@nangohq/ui-connect", + "name": "@nangohq/connect-ui", "private": true, "version": "0.0.0", "type": "module", diff --git a/packages/ui-connect/postcss.config.js b/packages/connect-ui/postcss.config.js similarity index 100% rename from packages/ui-connect/postcss.config.js rename to packages/connect-ui/postcss.config.js diff --git a/packages/ui-connect/src/App.tsx b/packages/connect-ui/src/App.tsx similarity index 100% rename from packages/ui-connect/src/App.tsx rename to packages/connect-ui/src/App.tsx diff --git a/packages/ui-connect/src/components/ui/button.tsx b/packages/connect-ui/src/components/ui/button.tsx similarity index 100% rename from packages/ui-connect/src/components/ui/button.tsx rename to packages/connect-ui/src/components/ui/button.tsx diff --git a/packages/ui-connect/src/index.css b/packages/connect-ui/src/index.css similarity index 100% rename from packages/ui-connect/src/index.css rename to packages/connect-ui/src/index.css diff --git a/packages/ui-connect/src/lib/utils.ts b/packages/connect-ui/src/lib/utils.ts similarity index 100% rename from packages/ui-connect/src/lib/utils.ts rename to packages/connect-ui/src/lib/utils.ts diff --git a/packages/ui-connect/src/main.tsx b/packages/connect-ui/src/main.tsx similarity index 100% rename from packages/ui-connect/src/main.tsx rename to packages/connect-ui/src/main.tsx diff --git a/packages/ui-connect/src/vite-env.d.ts b/packages/connect-ui/src/vite-env.d.ts similarity index 100% rename from packages/ui-connect/src/vite-env.d.ts rename to packages/connect-ui/src/vite-env.d.ts diff --git a/packages/ui-connect/tailwind.config.js b/packages/connect-ui/tailwind.config.js similarity index 100% rename from packages/ui-connect/tailwind.config.js rename to packages/connect-ui/tailwind.config.js diff --git a/packages/ui-connect/tsconfig.json b/packages/connect-ui/tsconfig.json similarity index 100% rename from packages/ui-connect/tsconfig.json rename to packages/connect-ui/tsconfig.json diff --git a/packages/ui-connect/vite.config.ts b/packages/connect-ui/vite.config.ts similarity index 100% rename from packages/ui-connect/vite.config.ts rename to packages/connect-ui/vite.config.ts diff --git a/tsconfig.build.json b/tsconfig.build.json index c66df888606..5ead13a7954 100644 --- a/tsconfig.build.json +++ b/tsconfig.build.json @@ -50,7 +50,7 @@ "path": "packages/shared" }, { - "path": "packages/ui-connect" + "path": "packages/connect-ui" }, { "path": "packages/webapp"