mirror of
https://github.com/dream-pep/koring-launcher.git
synced 2026-09-12 05:45:18 +08:00
Add Koring auth flow and settings UI refactor
Implements Koring OIDC device-auth flow and integrates it into the app: core auth (TS/JS), IPC handlers, renderer API, KoringLogin React component, and a zustand koringAuth store. Handlers support device-code request, polling, refresh, get-user and logout and persist user info to existing auth/config. Also refactors many settings pages to use shared Setting components (SettingCard, SettingRow, SectionTitle, PageHeader) and replaces custom controls with @heroui/react primitives (Avatar, Button, Switch, RadioGroup, Slider, Input, TextArea, EmptyState). Adds OOBE login/welcome pages, a setting login route, installer header generator script, and a sample koring-auth.json for development.
This commit is contained in:
@@ -0,0 +1,12 @@
|
||||
export function PageHeader({ title, desc }: { title: string; desc: string }) {
|
||||
return (
|
||||
<>
|
||||
<h2 className="text-xl font-bold text-foreground mb-1">{title}</h2>
|
||||
<p className="text-sm text-muted-foreground mb-6">{desc}</p>
|
||||
</>
|
||||
);
|
||||
}
|
||||
|
||||
export function SectionTitle({ children }: { children: React.ReactNode }) {
|
||||
return <h3 className="text-lg font-bold text-foreground mb-3">{children}</h3>;
|
||||
}
|
||||
Reference in New Issue
Block a user