diff --git a/CHANGELOG.md b/CHANGELOG.md index 8b2a2a1..3185f95 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,18 @@ All notable changes to this project will be documented in this file. This project adheres to [Semantic Versioning](http://semver.org/). +## [2.0.4] - Unreleased + +### Added +- New WebUI design with more pizzazz: + - Cleaner generated forms: two-column fields that stack on mobile, simpler nested objects, collapsible list items, segmented variant pickers, a section index on wide screens and a floating save bar. + - Dashboards support a layout with stat, chart, headline and ranking tiles, plus column and row spans, tones and delta polarity, all defined in the schema. +- Custom OAuth scopes can be requested through the `oauth-scopes` meta tag; they are added to the scopes required by the server. + +### Changed + +### Fixed + ## [2.0.3] - 2026-10-29 ### Added diff --git a/index.html b/index.html index c5a0dfd..5d7acc9 100644 --- a/index.html +++ b/index.html @@ -5,6 +5,7 @@ + Portal diff --git a/package-lock.json b/package-lock.json index cf2b24c..f62738b 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,14 +1,17 @@ { "name": "stalwart-webui", - "version": "2.0.3", + "version": "2.0.4", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "stalwart-webui", - "version": "2.0.3", + "version": "2.0.4", "dependencies": { "@daypicker/react": "^10.0.2", + "@fontsource-variable/inter": "^5.3.0", + "@fontsource-variable/jetbrains-mono": "^5.3.0", + "@fontsource-variable/plus-jakarta-sans": "^5.3.0", "@noble/hashes": "^2.4.0", "@radix-ui/react-alert-dialog": "^1.2.1", "@radix-ui/react-checkbox": "^1.4.1", @@ -584,6 +587,33 @@ "integrity": "sha512-HpCo8tmWzLVad5s2d19EhAz5zqrrQ6s69qd6moPMQvkOuSwDT1YgRfWSVuc4ennqrgv3OHppiOGMQ7oC13yIww==", "license": "MIT" }, + "node_modules/@fontsource-variable/inter": { + "version": "5.3.0", + "resolved": "https://registry.npmjs.org/@fontsource-variable/inter/-/inter-5.3.0.tgz", + "integrity": "sha512-OupL48va4JNofb97w6NYeF9S7W/kHNKM0Er8Dem5nqi4jeOLrVJDoE8tZEpnMJmtkvNbB1EIPPwHcdkF6b1oUA==", + "license": "OFL-1.1", + "funding": { + "url": "https://github.com/sponsors/ayuhito" + } + }, + "node_modules/@fontsource-variable/jetbrains-mono": { + "version": "5.3.0", + "resolved": "https://registry.npmjs.org/@fontsource-variable/jetbrains-mono/-/jetbrains-mono-5.3.0.tgz", + "integrity": "sha512-F32xpS2NsGYoQi2ADSkKTgpJj7ozajsGgDJ8woTnqjmIB+dxDIqImjl4pXZVEExu8UFZ2ndhmX18EBS/hdz3Lw==", + "license": "OFL-1.1", + "funding": { + "url": "https://github.com/sponsors/ayuhito" + } + }, + "node_modules/@fontsource-variable/plus-jakarta-sans": { + "version": "5.3.0", + "resolved": "https://registry.npmjs.org/@fontsource-variable/plus-jakarta-sans/-/plus-jakarta-sans-5.3.0.tgz", + "integrity": "sha512-/l/4r0yyWK9JzAlmA0LiYgGgmJe/Gswt4jTJEzr5QhJfwMbvJZDmYWyW0M4X7yCK69BajMVlV/Lx8g7WDc1+sw==", + "license": "OFL-1.1", + "funding": { + "url": "https://github.com/sponsors/ayuhito" + } + }, "node_modules/@humanfs/core": { "version": "0.19.2", "resolved": "https://registry.npmjs.org/@humanfs/core/-/core-0.19.2.tgz", diff --git a/package.json b/package.json index 523f2e9..76b3a4a 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "stalwart-webui", "private": true, - "version": "2.0.3", + "version": "2.0.4", "stalwart": { "minServerVersion": "1.0.0" }, @@ -18,6 +18,9 @@ }, "dependencies": { "@daypicker/react": "^10.0.2", + "@fontsource-variable/inter": "^5.3.0", + "@fontsource-variable/jetbrains-mono": "^5.3.0", + "@fontsource-variable/plus-jakarta-sans": "^5.3.0", "@noble/hashes": "^2.4.0", "@radix-ui/react-alert-dialog": "^1.2.1", "@radix-ui/react-checkbox": "^1.4.1", diff --git a/src/components/bootstrap/BootstrapScreens.tsx b/src/components/bootstrap/BootstrapScreens.tsx index 0a18d9f..05d6d6f 100644 --- a/src/components/bootstrap/BootstrapScreens.tsx +++ b/src/components/bootstrap/BootstrapScreens.tsx @@ -7,18 +7,18 @@ import type { ReactNode } from 'react'; import { useTranslation } from 'react-i18next'; import { Check } from 'lucide-react'; -import { Card, CardContent } from '@/components/ui/card'; +import { cn } from '@/lib/utils'; import { CopyButton } from '@/components/common/CopyButton'; import { DefaultLogo } from '@/components/common/Logo'; import type { Fields } from '@/types/schema'; export function WizardShell({ children }: { children: ReactNode }) { return ( -
-
+
+
-
+
{children}
@@ -29,15 +29,16 @@ export function ProgressIndicator({ total, current }: { total: number; current: const { t } = useTranslation(); return (
{Array.from({ length: total }, (_, i) => (
))}
@@ -62,14 +63,14 @@ export function SuccessScreen({ const hasCredentials = entries.length > 0; return ( -
-
-
- -
+
+
+ +
-

{t('bootstrap.complete', 'Setup complete')}

-

+

{t('bootstrap.complete', 'Setup complete')}

+

{hasCredentials ? t( 'bootstrap.credentialsCreated', @@ -81,26 +82,26 @@ export function SuccessScreen({

{hasCredentials && ( - - - {entries.map(([key, value]) => { - const field = fields.properties[key]; - const label = labelsByName.get(key) ?? field?.description?.split('\n')[0] ?? key; - return ( -
-
{label}
-
- {value} - -
+
+ {entries.map(([key, value]) => { + const field = fields.properties[key]; + const label = labelsByName.get(key) ?? field?.description?.split('\n')[0] ?? key; + return ( +
+
{label}
+
+ + {value} + +
- ); - })} - - +
+ ); + })} +
)} -
+

{t('bootstrap.nextStepLabel', 'Next step:')}{' '} {t( diff --git a/src/components/bootstrap/BootstrapWizard.tsx b/src/components/bootstrap/BootstrapWizard.tsx index 47b333a..08154ed 100644 --- a/src/components/bootstrap/BootstrapWizard.tsx +++ b/src/components/bootstrap/BootstrapWizard.tsx @@ -8,7 +8,7 @@ import { useCallback, useMemo, useState } from 'react'; import { useTranslation } from 'react-i18next'; import { Button } from '@/components/ui/button'; -import { Card, CardContent, CardHeader, CardTitle } from '@/components/ui/card'; +import { cn } from '@/lib/utils'; import { ArrowLeft, ArrowRight, Loader2, Rocket } from 'lucide-react'; import { useSchemaStore } from '@/stores/schemaStore'; @@ -208,8 +208,8 @@ export function BootstrapWizard() { if (!schema || !resolved) { return ( -

- +
+
@@ -219,8 +219,8 @@ export function BootstrapWizard() { if (loading) { return ( -
- +
+
@@ -230,7 +230,7 @@ export function BootstrapWizard() { if (loadError) { return ( -
+

{loadError}

@@ -262,7 +262,7 @@ export function BootstrapWizard() { if (sections.length === 0) { return ( -
+
{t('bootstrap.emptyForm', 'Setup form is empty. The server did not return any bootstrap fields.')}
@@ -273,52 +273,47 @@ export function BootstrapWizard() { return ( -
-
-

{t('bootstrap.welcome', 'Welcome to Stalwart')}

-

- {t('bootstrap.welcomeSubtitle', "Let's get your server set up.")} -

+
+
+
+

{t('bootstrap.welcome', 'Welcome to Stalwart')}

+

+ {t('bootstrap.welcomeSubtitle', "Let's get your server set up.")} +

+
+
- - {generalError && ( -
-

{generalError}

+
+

{generalError}

)} - - {current.title && ( - - {current.title} - - )} - -
- - {current.fields.map(({ formField, field }) => ( - handleFieldChange(formField.name, v)} - error={fieldErrors[formField.name]} - /> - ))} - -
-
-
+
+ {current.title &&

{current.title}

} +
+ + {current.fields.map(({ formField, field }) => ( + handleFieldChange(formField.name, v)} + error={fieldErrors[formField.name]} + /> + ))} + +
+
-
+
-
+
{t('bootstrap.stepOf', 'Step {{current}} of {{total}}', { current: currentPage + 1, total: sections.length, @@ -326,13 +321,13 @@ export function BootstrapWizard() {
{isLastPage ? ( ) : ( )}
diff --git a/src/components/common/CommandPalette.tsx b/src/components/common/CommandPalette.tsx index 71ef05b..b22d144 100644 --- a/src/components/common/CommandPalette.tsx +++ b/src/components/common/CommandPalette.tsx @@ -50,7 +50,7 @@ export function CommandPalette({ open, onOpenChange }: CommandPaletteProps) {