Main Content Area
-This content will shrink when the sidebar opens, creating a two-pane layout.
-All sidebars have a standard width of 420px for consistency.
-On mobile devices, the sidebar will overlay the main content instead of shrinking it.
-diff --git a/.gitignore b/.gitignore index 9bc13a56..3697825b 100644 --- a/.gitignore +++ b/.gitignore @@ -6,6 +6,7 @@ node_modules .netlify .wrangler /.svelte-kit +/.next /build # OS @@ -35,4 +36,4 @@ static/ project.inlang/cache/ # Documentation -docs/ \ No newline at end of file +docs/ diff --git a/src/lib/api/adapters/base.adapter.ts b/src/lib/api/adapters/base.adapter.ts index 0b43c556..c9d4b63d 100644 --- a/src/lib/api/adapters/base.adapter.ts +++ b/src/lib/api/adapters/base.adapter.ts @@ -8,7 +8,7 @@ * @module adapters/base */ -import { snakeToCamel, camelToSnake, transformResponse, transformRequest } from '../schemas/transforms' +import { transformResponse, transformRequest } from '../schemas/transforms' import type { AdapterOptions, RequestOptions, AdapterError } from './types' import { createErrorFromStatus, diff --git a/src/lib/auth/map.ts b/src/lib/auth/map.ts index 6f352091..af1fd604 100644 --- a/src/lib/auth/map.ts +++ b/src/lib/auth/map.ts @@ -1,5 +1,4 @@ -import type { OAuthLoginResponse } from './oauth' -import type { UserInfoResponse } from '$lib/api/resources/users' +import type { OAuthLoginResponse, UserInfoResponse } from './oauth' import type { AccountCookie } from '$lib/types/AccountCookie' import type { UserCookie } from '$lib/types/UserCookie' diff --git a/src/lib/auth/oauth.ts b/src/lib/auth/oauth.ts index a55ba86d..a9a4c16c 100644 --- a/src/lib/auth/oauth.ts +++ b/src/lib/auth/oauth.ts @@ -13,6 +13,20 @@ export interface OAuthLoginResponse { } } +// Response from user info endpoint used during auth flow +export interface UserInfoResponse { + id: string + username: string + role: number + avatar: { + picture: string | null + element: string | null + } + language: string | null + gender: number | null + theme: string | null +} + export async function passwordGrantLogin( fetchFn: typeof fetch, body: { email: string; password: string; grant_type: 'password' } diff --git a/src/lib/components/examples/SearchExample.svelte b/src/lib/components/examples/SearchExample.svelte deleted file mode 100644 index c825b971..00000000 --- a/src/lib/components/examples/SearchExample.svelte +++ /dev/null @@ -1,430 +0,0 @@ - - - - -
Searching...
-β Error: {currentSearch.error.message}
-Code: {currentSearch.error.code}
-No results found
-Found {currentSearch.data.total || currentSearch.data.results.length} results
- {#if currentSearch.data.totalPages && currentSearch.data.totalPages > 1} -- Page {currentSearch.data.page || 1} of {currentSearch.data.totalPages} -
- {/if} -Enter a search term to begin
-Click the buttons below to test different sidebar configurations:
- - - - {#if selectedItems.length > 0} -This content will shrink when the sidebar opens, creating a two-pane layout.
-All sidebars have a standard width of 420px for consistency.
-On mobile devices, the sidebar will overlay the main content instead of shrinking it.
-{JSON.stringify(operations, null, 2)}
-