Skip to content

Commit

Permalink
Svelte 5 Migration 15: Migrate Admin UI core components to Svelte 5 +…
Browse files Browse the repository at this point in the history
… TS + all new features (#715)

* migrate `<SearchBar>`

* rework `<Events>`

* create `<InputTime>`

* update i18n

* fix OpenAPI `/events` request and response types

* reworked `<EventsArchive>` (skipped `SearchBar`)

* reworked `<OrderBy>`

* additional i18n

* rework `<OrderSearchBar>`

* migrate `<EventsArchive>` with all new components

* rebuild ui
  • Loading branch information
sebadob authored Feb 6, 2025
1 parent bd5af14 commit e4cbaf3
Show file tree
Hide file tree
Showing 844 changed files with 3,418 additions and 2,109 deletions.
5 changes: 4 additions & 1 deletion dev_notes.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,12 @@
- `t.common.changeTheme`
- `t.common.details`
- `t.common.expandContent`
- `t.common.selectI18n`
- `t.common.hours`
- `t.common.legend`
- `t.common.minutes`
- `t.common.month`
- `t.common.months`
- `t.common.selectI18n`
- `t.common.summary`
- `t.common.weekDaysShort`
- `t.common.year`
Expand Down
35 changes: 35 additions & 0 deletions frontend/src/api/types/events.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
export type EventLevel = 'info' | 'notice' | 'warning' | 'critical';
export type EventType = 'InvalidLogins'
| 'IpBlacklisted'
| 'IpBlacklistRemoved'
| 'JwksRotated'
| 'NewUserRegistered'
| 'NewRauthyAdmin'
| 'NewRauthyVersion'
| 'PossibleBruteForce'
| 'RauthyStarted'
| 'RauthyHealthy'
| 'RauthyUnhealthy'
| 'SecretsMigrated'
| 'UserEmailChange'
| 'UserPasswordReset'
| 'Test';

export interface EventsRequest {
/// Unix timestamp in seconds
from: number,
/// Unix timestamp in seconds
until?: number,
level: EventLevel,
typ?: EventType,
}

export interface EventResponse {
id: string,
timestamp: number,
level: EventLevel,
typ: EventType,
ip?: string,
data?: number,
text?: string,
}
4 changes: 2 additions & 2 deletions frontend/src/components/admin/AdminMain.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -24,12 +24,12 @@
import Documentation from "./documentation/Documentation.svelte";
import IconBookOpen from "$lib/icons/IconBookOpen.svelte";
import {onMount} from "svelte";
import Events from "./events/Events.svelte";
import Events from "$lib5/admin/events/Events.svelte";
import IconStop from "$lib/icons/IconStop.svelte";
import Blacklist from "./blacklist/Blacklist.svelte";
import IconKey from "$lib/icons/IconKey.svelte";
import ApiKeys from "./api_keys/ApiKeys.svelte";
import EventsArchive from "./events/EventsArchive.svelte";
import EventsArchive from "$lib5/admin/events/EventsArchive.svelte";
import IconBellAlert from "$lib/icons/IconBellAlert.svelte";
import IconCloud from "$lib/icons/IconCloud.svelte";
import Providers from "./providers/Providers.svelte";
Expand Down
198 changes: 0 additions & 198 deletions frontend/src/components/admin/events/Event.svelte

This file was deleted.

Loading

0 comments on commit e4cbaf3

Please sign in to comment.