Commit Graph
47 Commits
Author SHA1 Message Date
Gabriel20xx 0783b74da7 feat: assign custom roles in user management 2026-10-13 18:08:42 +00:00
Gabriel20xx e1805c8fc3 fix: remove excess top padding on small screens 2026-10-09 14:29:31 +00:00
Gabriel20xx 52316e99a2 refactor(web-ui)!: remove PageHeader and AppShell integration 2026-10-08 12:57:31 +00:00
Gabriel20xx c7a3796f26 fix: improve notification stacking and text wrapping 2026-10-03 10:39:08 +00:00
Gabriel20xx 58b40fa340 style: stack section titles and tighten subtitle spacing 2026-10-02 08:43:16 +00:00
Gabriel20xx db14c02558 Adjust shared media player controls 2026-09-25 11:28:19 +02:00
Gabriel20xx 44518b955e Fix shared media controls auto-hide 2026-09-24 20:14:21 +02:00
Gabriel20xx 356b43b59e Share custom media player controls 2026-09-23 06:00:15 +02:00
Gabriel20xx 764593254e feat: add shared media player components 2026-09-23 05:35:28 +02:00
Gabriel20xx c743ee7f5b fix-wide-header 2026-09-23 15:41:46 +02:00
Gabriel20xx 87cb39c04c feat: allow project selection when creating users 2026-09-17 00:15:19 +02:00
Gabriel20xx 78067cc890 feat: use dropdown for primary color setting 2026-09-16 23:58:00 +02:00
Gabriel20xx 94a5c0b9ae fix: make wide page preference affect shared shell 2026-09-16 23:38:03 +02:00
Gabriel20xx 0e450d53de feat: migrate project secrets and user-scoped colors 2026-09-15 13:23:17 +02:00
Gabriel20xxandClaude Sonnet 5 663d498a03 Add per-user project-access restriction; generalize mediaauth into a unified auth proxy
shared/backend/auth: adds SchemaOptions.ProjectScoping and Store methods
(SetUserProjects/UserProjects/UserProjectsByUser/IsProjectAllowed,
SetKnownProjects/KnownProjects) backing AuthGuard's new per-user
project-access restriction.

shared/backend/authclient: Client can now identify its calling project to
AuthServer via WithProjectKey (sent as X-Project-Key on every request), so
AuthServer can enforce the restriction above per project.

shared/backend/mediaauth: generalized from a media-family-only package
into the one shared auth-proxy engine every AuthGuard-integrated project
should use. New accepts a projectKey; the login-required/setup-claim
storage it needs is now expressed as a small Store interface
(NewWithStore lets any project's own storage satisfy it, not just the
media family's shared `settings` table, which pgSettingsStore still backs
for existing callers). ManagedUpdateUser/ManagedDeleteUser now resolve
their {id} path param via chi.URLParam OR the stdlib 1.22+ ServeMux's
PathValue, so non-chi consumers work unchanged.

packages/web-ui: UserManagement gains an optional `projects` prop (a
per-account project-access picker), used only by AuthGuard's own admin UI.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-13 12:16:17 +02:00
Gabriel20xx 6ac2fcefeb Normalize all button/input/select/dropdown heights to 2.5rem
Button size variants (sm 2rem, lg 2.875rem), sc-input/sc-select (2.6rem),
and the pagination controls (2.1rem/2.25rem) each rendered at a different
height, so any row mixing them (a select next to a button, a page-size
dropdown next to pagination buttons) was visibly misaligned. Textarea
keeps its own min-height since it's multi-line by design.
2026-09-13 10:47:00 +02:00
Gabriel20xxandClaude Sonnet 5 d4d2c49538 Fix mobile header menu button jumping position on toggle
The button's top offset was unset, so its absolute-position static
position was recomputed from the flex-wrap layout whenever .sc-nav
wrapped onto its own row on open, causing a visible vertical jump.
Pinning top to the header's mobile padding keeps it stationary.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-12 23:03:36 +02:00
Gabriel20xxandClaude Sonnet 5 9f64bdc591 Fix pagination page-size dropdown showing blank on load
The select's value was coerced to a string via String(pageSize) while
the <option> values are numbers. Svelte 5 matches a non-bound <select>
value against each option's stored value with Object.is, so "24"
never matched 24 and the dropdown rendered with no option selected.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-12 16:29:25 +02:00
Gabriel20xxandClaude Sonnet 5 a998844c11 Add missing sc-pagination styles for the shared Pagination component
The component's markup used sc-pagination* classes that had no
matching rules anywhere in the shared stylesheet, so it rendered
unstyled in every consumer.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-11 23:40:08 +02:00
Gabriel20xxandClaude Sonnet 5 965910eecc Add pagination controls to UserManagement
Uses the shared Pagination component instead of rendering every
fetched user in one unpaginated list.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-11 23:25:25 +02:00
Gabriel20xxandClaude Sonnet 5 87ac5ed25a Fix header profile dropdown About link showing default anchor color
The About item falls back to an <a> when no onAbout handler is wired.
The :visited fix only covered post-click state; the unvisited a:link
pseudo-class still beat the .sc-profile-menu-item class in specificity,
making the item look lighter/whiter than the button-based items until
clicked once.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-11 09:16:11 +02:00
Gabriel20xxandClaude Sonnet 5 56e2f60531 Make the auth screen's password field optional; catch up UserManagement drift
AuthPage's password (and, in setup mode, confirm-password) field no
longer forces a non-empty value client-side -- the server already
enforces the real rules (a correct password to log in, >=8 chars to
register/bootstrap), so this only replaces a native browser validation
popup with the server's own error message.

Also bring UserManagement in line with an AuthGuard-only edit that had
drifted ahead of this source (username/email/password relaxed to "at
least one of username/email, password optional" for admin-created
users) so the next consumer sync doesn't silently revert it.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-09 16:52:45 +02:00
Gabriel20xxandClaude Sonnet 5 ee59571552 Rename ProjectConfigurator, restructure Projects workspace, retire MediaCollection naming
- Rename MediaConfig -> ProjectConfigurator throughout; drop the Parameters
  tab/page; rename the Mounts tab to Projects and restructure it into three
  sections: Central services, Main services, Third-party services
- Add a self-describe contract (GET /api/info returning name/tabs/mountTypes)
  and a server-side discovery proxy (POST /api/discover-service) so adding a
  main service only requires a URL
- Add ProjectConfigurator HA: multiple instances now sync their settings with
  each other (GET /api/settings/export, POST /api/settings/sync, a periodic
  background puller), last-write-wins per key by updated_at
- Add a generic, project-agnostic file-storage API on CarrierNode
  (GET/POST/DELETE /api/mount/{project}/{type}[/*]) driven by the same
  configured_mounts data the Projects workspace already writes, usable by any
  registered project, not just the media family
- Add last_login_at tracking to the shared auth Store/User (schema, queries,
  UpdateLastLogin) and surface it through the shared web-ui ManagedUser type
  and UserManagement component
- Retire the "MediaCollection" name: Go module -> repos.gfranz.ch/Gabriel20xx/shared/media-backend,
  binary -> mediabackend, session cookie default -> "session", media-webui
  merged into webui, media-shared-assets renamed to legacy-assets and pruned
  to the one file MediaDesktop still uses

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-04 15:02:16 +02:00
Gabriel20xxandClaude Sonnet 5 07cf3308da Remove Admin option from header profile dropdown
User management is now centralized in AuthGuard's webui, so the
per-project Admin dialog (user CRUD + require-login toggle) is
redundant. The require-login toggle will move to ProjectConfigurator
in the future.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-04 09:29:23 +02:00
Gabriel20xx 730bf0463f Double sc-page-header bottom margin 2026-09-03 19:56:56 +02:00
Gabriel20xx 7b5a4e6c2c Merge media-webui/media-backend into the general shared component/backend system
Extracts a new backend/authproxy package for the AuthGuard-proxy helper
functions (session cookie handling, input normalization, error
translation) that Bitmagnet/GameStream/media-backend/AutoCode/
CollabTable/PubliSafe/SimpleCollection/SyncServer/UnraidMonitor/
OutdoorGames were each independently reimplementing, and repoints all
of them onto it.

Extends packages/web-ui's Button/Badge with the variants media-webui
needed (outline, icon size, primary badge) and promotes EmptyState/
SectionTitle/Metric/StatusWidget/StatusDialog into the shared library,
then migrates media-webui off its own diverged ui/{button,card,badge,
metric} components and local duplicates of the promoted components
onto @gabriel20xx/web-ui, so media-webui is a proper consumer of the
same design system every other project already uses instead of a
parallel fork.

Also removes the dead `desktop`/MediaDesktop service variant from
media-backend and media-webui (MediaDesktop is an Electron client that
never actually runs this stack).
2026-09-03 00:14:01 +02:00
Gabriel20xxandClaude Sonnet 5 f164e0d0d2 Halve sc-page-header gap to the content below it
margin-bottom: 1rem left too much empty space between the title card
and the cards/content on the page. Reduce to 0.5rem.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-02 17:35:26 +02:00
Gabriel20xxandClaude Sonnet 5 94af6d7601 feat: support pageHeaderActions in AppShell
Wires a pageHeaderActions snippet prop through to PageHeader's actions
slot, so consumers can render content (e.g. stats, buttons) in the
page title container alongside the title/description.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-31 17:17:52 +02:00
Gabriel20xx fa69e6ef3c feat: add Pagination component to shared web-ui
AutoCode's actions page depends on a Pagination component that only
ever existed in its consumer-side shared/ snapshot, never in this
canonical repo. Every sync-consumers.ps1 run deleted it as stale,
repeatedly breaking AutoCode's lint and Docker builds. Adding it here
makes the sync idempotent instead of destructive.
2026-08-29 12:58:27 +02:00
Gabriel20xx 3f5ff73a49 Standardize AppShell container gaps to 16px
The page title box and the content below it (e.g. a search/filter
panel) were separated by 24px, and main had 32px/48px top/bottom
padding around that stack. Both now use a consistent 16px.
2026-08-29 12:31:15 +02:00
Gabriel20xx fc0e376df8 feat: add NotificationStack component and notify API for toast notifications 2026-08-27 13:32:13 +02:00
Gabriel20xx d005ee6f51 feat: implement notification system with customizable message handling 2026-08-27 13:29:34 +02:00
Gabriel20xx e8a9b25037 fix: update setup handling logic to improve account creation flow 2026-08-23 22:18:20 +02:00
Gabriel20xx 4227293345 fix: adjust visited color for profile menu items to maintain consistency 2026-08-20 17:03:14 +02:00
Gabriel20xxandClaude Sonnet 5 a53bafff3f feat: add admin dialog and move user management out of settings/profile modals
- Add a dedicated admin entry (with icon) to the header profile dropdown, visible only to admins
- Move all user-management settings from SettingsDialog/ProfileDialog into a new AdminDialog
- Export AdminDialog from the package index

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-20 14:02:16 +02:00
Gabriel20xx a90f4eb71f fix: give header brand icon a fixed size
The brand <img> sized itself with width/height:100%, but it isn't
wrapped in a sized container like the fallback letter-mark is, and its
flex-item parent has no definite size for the percentage to resolve
against - so it rendered at whatever intrinsic size the favicon
happened to report instead of a consistent icon size.
2026-08-19 12:06:17 +02:00
Gabriel20xx 6c364623fd feat: add icons to profile menu items
- Simplify brand logo markup
- Add profile, settings, and about icons
2026-08-14 07:33:11 +00:00
Gabriel20xx 5ebaafc113 fix: center mobile menu button in header 2026-08-12 06:57:12 +00:00
Gabriel20xx 81077527ac Add favicon support and loading state to authentication components 2026-08-10 10:42:40 +02:00
Gabriel20xx d0b18a4902 Update shared web UI auth and profile menu 2026-08-09 10:34:06 +02:00
Gabriel20xx e3544617e1 Enhance web-ui components and styles with new features and dependencies
- Added @lucide/svelte as a dependency for icon support in various components.
- Updated AboutDialog, AppShell, AuthPage, Header, SettingsDialog, and styles for improved functionality and UI consistency.
- Introduced new props and state management for better user experience.
- Refactored CSS for cleaner styling and improved layout.
2026-08-07 15:18:50 +02:00
Gabriel20xx ce6db8a457 Bump package versions to 0.1.1 and update npm publish workflow with registry authentication 2026-08-06 21:35:49 +02:00
Gabriel20xx da97fd4fb1 feat(auth): implement TOTP setup and management
Lint / Lint (Node/Svelte) (push) Successful in 24s
Tests / Test (Go) (push) Successful in 25s
Lint / Lint (Go) (push) Successful in 28s
Lint / Lint (Python) (push) Failing after 14s
Tests / Test (Node/Svelte) (push) Successful in 18s
Tests / Test (Python) (push) Successful in 12s
- Added TOTP support for two-factor authentication in the auth module.
- Introduced new types and interfaces for TOTP setup and token actions in the web UI.
- Created backend logic for generating and verifying TOTP secrets and tokens.
- Implemented user management features including role assignments and user CRUD operations.
- Enhanced UI components for managing users and TOTP settings.
- Added styles for optional labels and authentication reset links.
- Implemented reset code generation and validation for admin accounts.
2026-08-05 14:57:01 +02:00
Gabriel20xx 2f57554154 Extend shared UI component customization
Lint / Lint (Go) (push) Successful in 16s
Lint / Lint (Python) (push) Successful in 9s
Lint / Lint (Node/Svelte) (push) Successful in 23s
Tests / Test (Node/Svelte) (push) Successful in 14s
Tests / Test (Go) (push) Successful in 17s
Tests / Test (Python) (push) Successful in 9s
2026-08-04 16:53:36 +02:00
Gabriel20xx c95865dbe2 Expand shared profile and about dialogs
Lint / Lint (Go) (push) Successful in 17s
Lint / Lint (Python) (push) Successful in 9s
Tests / Test (Node/Svelte) (push) Successful in 13s
Tests / Test (Go) (push) Successful in 17s
Tests / Test (Python) (push) Successful in 9s
Lint / Lint (Node/Svelte) (push) Successful in 14s
2026-08-04 16:29:20 +02:00
Gabriel20xx 44c05f5a27 Require password confirmation in shared auth page
Lint / Lint (Node/Svelte) (push) Successful in 12s
Lint / Lint (Go) (push) Successful in 15s
Tests / Test (Go) (push) Successful in 17s
Tests / Test (Python) (push) Successful in 9s
Lint / Lint (Python) (push) Successful in 12s
Tests / Test (Node/Svelte) (push) Successful in 18s
2026-08-04 15:40:46 +02:00
Gabriel20xx 838a97d344 Add initial shared code packages 2026-08-04 15:17:15 +02:00