Migrate frontend to shadcn/ui + add Gitea branch panel in endpoint editor

shadcn/ui migration:
- Installed shadcn components: Button, Input, Label, Card, Badge, Checkbox,
  Switch, Tabs, Dialog, Select, Tooltip, Toaster (sonner)
- Migrated all pages: Login, Dashboard, Settings, Endpoints, EndpointEditor,
  Folders, ApiKeys, Logs
- Replaced react-hot-toast with sonner
- Added CSS variables for theming
- Updated tailwind.config.js for shadcn

Gitea branch panel in EndpointEditor:
- GiteaBranchPanel component: branch selector, save to branch, compare
  with main, create PR, merge, commit history
- New backend endpoints: getEndpointFileContent, commitEndpoint,
  getEndpointCommits, getEndpointFromBranch, commitEndpointToBranch
- Frontend giteaApi: extended with endpoint-specific methods

Fixes:
- Fixed sync-all PostgreSQL-compatible UPDATE LIMIT
- .gitignore: added tmp/

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-05-24 00:16:15 +03:00
parent 59ea0eb9c2
commit 44e4b45f50
45 changed files with 4442 additions and 1752 deletions

View File

@@ -1,5 +1,6 @@
/** @type {import('tailwindcss').Config} */
export default {
darkMode: ["class"],
content: [
"./index.html",
"./src/**/*.{js,ts,jsx,tsx}",
@@ -18,6 +19,8 @@ export default {
700: '#1d4ed8',
800: '#1e40af',
900: '#1e3a8a',
DEFAULT: "hsl(var(--primary))",
foreground: "hsl(var(--primary-foreground))",
},
dark: {
50: '#f8fafc',
@@ -31,8 +34,56 @@ export default {
800: '#1e293b',
900: '#0f172a',
},
background: "hsl(var(--background))",
foreground: "hsl(var(--foreground))",
card: {
DEFAULT: "hsl(var(--card))",
foreground: "hsl(var(--card-foreground))",
},
popover: {
DEFAULT: "hsl(var(--popover))",
foreground: "hsl(var(--popover-foreground))",
},
secondary: {
DEFAULT: "hsl(var(--secondary))",
foreground: "hsl(var(--secondary-foreground))",
},
muted: {
DEFAULT: "hsl(var(--muted))",
foreground: "hsl(var(--muted-foreground))",
},
accent: {
DEFAULT: "hsl(var(--accent))",
foreground: "hsl(var(--accent-foreground))",
},
destructive: {
DEFAULT: "hsl(var(--destructive))",
foreground: "hsl(var(--destructive-foreground))",
},
border: "hsl(var(--border))",
input: "hsl(var(--input))",
ring: "hsl(var(--ring))",
},
borderRadius: {
lg: "var(--radius)",
md: "calc(var(--radius) - 2px)",
sm: "calc(var(--radius) - 4px)",
},
keyframes: {
"accordion-down": {
from: { height: "0" },
to: { height: "var(--radix-accordion-content-height)" },
},
"accordion-up": {
from: { height: "var(--radix-accordion-content-height)" },
to: { height: "0" },
},
},
animation: {
"accordion-down": "accordion-down 0.2s ease-out",
"accordion-up": "accordion-up 0.2s ease-out",
},
},
},
plugins: [],
plugins: [require("tailwindcss-animate")],
}