Skip to content

Composables ​

All composables live in app/composables/ and are auto-imported — no import statement needed in components or pages. Files follow the useFeatureName.ts naming convention.

Directory Structure ​

composables/
├── api/              # Raw HTTP wrappers ($api calls), one file per resource
├── auth/             # Authentication state and login flow
├── branding/         # White-label branding resolution and application
├── core/
│   ├── common/       # General-purpose, reusable logic
│   ├── components/   # Logic extracted from specific components
│   ├── dialogs/      # Dialog business logic and action dispatchers
│   ├── layouts/      # Layout-level composables
│   └── pages/        # Page-level business logic
├── queries/          # TanStack Vue Query wrappers (cache + mutations)
└── useOrigin.ts      # SSR-safe request origin helper

Two-Layer Pattern ​

API composables own the request shape and expose isLoading / error. Query composables own caching via TanStack Vue Query and are the layer that components should call.

ts
// api/useFolderApi.ts — owns the $api call
export const useFolderApi = () => {
  const { isLoading, error, track } = useApiRequestState()
  const fetchFolders = async (params) => { ... }
  return { fetchFolders: track(fetchFolders), isLoading, error }
}

// queries/useFoldersQuery.ts — owns the TanStack cache
export const useFoldersQuery = (options) => {
  const { fetchFolders } = useFolderApi()
  const query = useQuery({ queryKey: [...], queryFn: () => fetchFolders(params) })
  return { query }
}

// FolderList.vue — calls the queries layer, never api/ directly
const { query } = useFoldersQuery({ sortValue, sortBy })

Some composables follow a cache-aside variant of this pattern: the query composable wraps queryClient.fetchQuery / fetchInfiniteQuery and stores results into a plain writable ref. This is intentional for cases where the UI needs to mutate the local list (drag-reorder, inline edits) without round-tripping the cache.


api/ — HTTP composables ​

Every api/ composable uses useApiRequestState() internally, which provides a shared isLoading computed and error ref, and a track wrapper that manages the pending counter. All returned methods are wrapped with track unless noted.

useApiRequestState.ts ​

Foundation composable consumed by every useXxxApi. Not called directly from components.

ProvidesDescription
isLoadingComputedRef<boolean> — true while any tracked call is in flight
errorRef<unknown> — last caught error, reset on each new call
track(fn)Wraps an async function with loading/error state; rethrows so callers keep their try/catch

Resource API composables ​

FileWhat it providesKey methods
useAnnouncementsApi.tsWorkspace announcements CRUDlistAnnouncements, getAnnouncementUsers, addAnnouncement, updateAnnouncement, deleteAnnouncement
useAssetDetailApi.tsFull detail, metadata, versions, and conversion for a single assetgetAssetDetail, getCustomFields, updateAssetField, updateCustomFields, convertResolution, convertFormat, makeCurrentVersion, deleteVersion
useAssetsApi.tsAsset library operations across the workspacegetRecentUploaded, updateWithField, deleteFile, viewAssetsCountApi, archiveAsset, convertAsset, recordDownloadHistory, makeCurrentVersion, deleteVersion
useBrowserOsApi.tsWraps the /api/browser-os Nitro route for geo + user-agent info (used by the login page)getBrowserOs
useCollageDetailsApi.tsInner search and popular filter data for a collage detail pagefetchInnerSearchData, performSearch
useCollectionApi.tsCollage (collection) CRUD — create, rename, delete, paginate, share, asset managementgetRecentsCollages, updateCollectionName, deleteCollection, getCollectionsByPage, shareCollection, getCollageDetails, loadCollageAssets, addAssetsToCollection, removeAssetsFromCollection, getCollections
useCommonApis.tsShared endpoints used across pagesgetOverviewData, getS3Resource, fetchSubscription, setBranding, checkBranding, getInnerSearchData, getUserProfile, updateUserProfile, getNotificationList
useCustomFieldsApi.tsCustom field definition managementlistCustomFields, createCustomField, updateCustomField, deleteCustomField, reorderCustomFields, toggleCustomFieldStatus
useDamApi.tsLow-level DAM endpoints: storage analytics, recent uploads, ZIP generation, notificationsgetStorageAnalytics, getRecentUploads, generateZip, generateSharedZip, getNotifications
useDamInstanceApi.tsFetches and normalizes the current DAM instance (company name, portal list, storage usage)fetchDamInstance (standalone export, not a composable)
useDamInstanceSettingsApi.tsDAM instance creation and settings — branding, password flows, invitation detailsupdateDamBranding, getWorkspaceDetail, getInstanceDetail, createDamInstance, forgotPassword, generatePassword, generateCommonPassword, getInvitationDetails, getPasswordDetails, resetPassword
useExternalUsersApi.tsExternal user managementlistExternalUsers, addExternalUser, editExternalUser, toggleExternalUserStatus
useFiltersApi.tsFetches and normalizes the full search filter universe into FilterCategory[] and PopularSearchDatagetSearchData, getInnerSearchData
useFolderApi.tsFolder/category CRUD and navigationgetRecentsFolders, createFolder, deleteFolder, fetchFolders, fetchFolderContent, fetchAssetsWithThrottle, renameFolder, moveFiles, copyFile, moveMultiple
useMembersApi.tsWorkspace member management — list, roles, invite, deletelistMembers, getRoleModules, getUserDetails, checkEmail, deleteUser, revokeUser, resendInvitation, activateUser, resetUserPassword
useNotificationApi.tsUser and org notification preferencesgetUserNotifications, updateUserNotification, getOrgNotifications, updateOrgNotification, pauseWorkspaceNotification
usePasskeyApi.tsWebAuthn passkey management for profile settingsgetPasskeys, getRegisterOptions, registerPasskey, deletePasskey
usePermissionApi.tsContent permission managementfetchPortals, changePermission
usePortalApi.tsPortal (brand portal) CRUD — list, create, update settings and brandinglistPortals, createPortal, updatePortalSettings, updatePortalVisibility, updatePortalBranding, getSubscription, getInstanceList, getBranding
usePortalBannerApi.tsPortal banner managementlistBanners, upsertBanner, deleteBanner, updateBannerOrdering
usePortalTileApi.tsPortal tile managementlistTiles, createTile, upsertTile, deleteTile, updateTileOrder, updateSliderConfig
usePortalUsersApi.tsPortal user lifecycle on the portal detail pageresendInvitation, revokeInvitation, deleteUser, deleteRestoreUser, dealerActivate, updateUser, createUser
usePortalUsersSettingsApi.tsPaginated portal user list and write ops for the settings pagegetPortalUsers, resendInvitation, revokeInvitation, deleteUser, deleteRestoreUser, dealerActivate, updateUser
useRecentSearchApi.tsServer-backed recent search history per usergetRecentSearches, saveRecentSearch
useSearchApi.tsTypesense search via in-app proxy routessearchAssets, searchFolders, searchCollages, searchTags, multiSearch, getPopularSearchData, getSearchResults
useSharedAssetsApi.tsPublic shared asset viewing — authenticate, list, browseshowShareAssets, viewShareFilesWithCategory, getFolderCount, trackShareLinkView, authenticationCheck, searchShareData
useSharingApi.tsShare URL and embed code managementfetchShareUrlsApi, fetchEmbeddedUrlsApi, deleteShareUrlsApi, removeEmbedCodeApi, generateShareAssetsUrl, generateEmbedCode, generateCollectionShareUrl, updateShareUrl
useTagsApi.tsTag operations on single or multiple assetsaddTagsToFilesApi, deleteTagFromFilesApi, getSuggestedTagsApi, getCommonTagListApi
useTrashApi.tsTrash managementfetchTrashItems, permanentDeleteItems, restoreTrashItems
useTypesenseApi.tsLow-level Typesense proxy calls (prefer useSearchApi for typed searches)multiSearch, searchCollection, searchIds
useWorkspaceSettingsApi.tsWorkspace settings CRUDgetWorkspaceDetail, getWorkspaceUsers, updateWorkspaceSettings, updateWorkspaceFavicon, updateWorkspaceLogo, updateDomain, verifyDomain, getSubscription, updateWorkspaceOwner
useZipDownloadApi.tsStreams a zip archive from the external zip-worker service via native fetch (returns raw Response)fetchZipStream

queries/ — TanStack Vue Query composables ​

Query composables sit between the API layer and the UI. They manage caching, invalidation, and pagination. Components call these, not api/ directly.

FileWhat it provides
useAnnouncementsQuery.tsInfinite query for the announcements list
useAssetDetailQuery.tsCache-aside fetch for asset detail and custom fields
useAssetMutations.tsAsset write ops (update field, delete) with cache invalidation for the uncategorized/uploads page
useCollageContentsQuery.tsCache-aside fetch for collage/collection contents
useCollageListMutations.tsCollage list write ops (rename, delete) with cache invalidation
useCollageListQuery.tsInfinite query for the collages library list
useCustomFieldsMutations.tsCustom field write ops (delete, reorder, toggle status) with cache invalidation
useCustomFieldsQuery.tsReactive query for custom field definitions
useDashboardQuery.tsBatched queries for the dashboard — recent collages, recent folders, overview stats, weekly insights
useExternalUsersQuery.tsReactive query for the external users list per workspace and type
useFolderContentsQuery.tsCache-aside fetch for paginated folder contents
useFolderMutations.tsFolder write ops (delete, rename) with cache invalidation
useFoldersQuery.tsReactive query for the folders library list and overview data
useMembersMutations.tsMember write ops (delete, revoke, resend invitation, activate)
useMembersQuery.tsInfinite query for members list; reactive query for role modules and instances
useNotificationsMutations.tsNotification preference write ops (user, org, pause workspace)
useNotificationsQuery.tsCache-aside fetch for user and org notification settings
usePermissionPortalsQuery.tsCache-aside fetch for the portal list used by the permission dialog
usePortalBannersQuery.tsCache-aside fetch for portal banners (writable ref for drag-reorder)
usePortalDetailUsersQuery.tsInfinite query for portal users on the portal detail page
usePortalTilesQuery.tsCache-aside fetch for portal tiles (writable ref for drag-reorder)
usePortalUsersSettingsMutations.tsPortal users write ops (resend, revoke, delete, restore, activate, update)
usePortalUsersSettingsQuery.tsInfinite query for the portal users settings list
usePortalsListQuery.tsReactive query for the portals list
useProfileQuery.tsCache-aside fetch for the user profile; reactive query for timezones
useSearchFiltersQuery.tsCache-aside fetch for global, folder-scoped, and collage-scoped filter data
useSharingMutations.tsSharing write ops (delete share URLs, remove embed codes, update share URL)
useSharingQuery.tsInfinite queries for share URLs and embed codes (separate queries, each with sort/filter in the key)
useSubscriptionQuery.tsReactive query for workspace subscription data; shared cache key across all pages that need it
useTrashMutations.tsTrash write ops (permanent delete, restore)
useTrashQuery.tsInfinite query for trash contents (assets + folders per page)
useWorkspaceSettingsQuery.tsCache-aside fetch for workspace detail (page spreads result into mutable form refs)

auth/ — Authentication ​

FileWhat it provides
useAuth.tsCore auth state — user, authToken, isAuthenticated, login, logout, fetchUser. SSR-safe; uses useState keyed by NuxtApp instance to prevent race conditions between concurrent middleware.
useAuthCookies.tsCentralised cookie read/write layer for the auth session. Exports AUTH_TOKEN_COOKIE, AUTH_STRATEGY_COOKIE, CURRENT_WORKSPACE_COOKIE constants and a composable with: readToken, readStoredToken (cookie → localStorage fallback), readStrategy, readWorkspace, writeSession (writes token + strategy with correct max-age per strategy), writeWorkspace (merges into stored value to preserve module data), clearSessionCookies (nulls workspace and all stale-session cookies on logout/401).

branding/ — White-label branding ​

FileWhat it provides
useBrand.tsResolves the white-label brand for the current host — logo, favicon, brand name, tagline, colors, support email. Returns a brand computed ref. Handles SSR origin detection via X-Forwarded-Proto/Host.
useBrandingHead.tsDrives document <head> (title, Open Graph meta, favicon) reactively from the resolved brand. Suppresses host-brand assets on /shared-assets routes to avoid leaking the host workspace's logo onto shared links.
useBrandingTheme.tsApplies white-label primary_color / secondary_color to the active Vuetify light theme at runtime. Call once from the main layout setup. Only writes valid hex values.

core/common/ — General-purpose utilities ​

FileWhat it provides
useAmplitude.tsAmplitude analytics — trackActivity, trackViewModeChange, selectionMethodFor, cascadeSize. Manages shared selection-method and last-sent-view-mode state.
useAmplitudeAssetTracking.tsAsset-specific Amplitude events — trackImageEditor, trackCustomFieldChange.
useAmplitudeSearchTracking.tsSearch-specific Amplitude events — trackSearchPerformed, trackSearchResultClicked, trackFilterApplied. Debounces duplicate search events.
useAssetFile.tsReactive computeds from a file ref — fileExt, fileUrl, fileThumb, isImage, isVideo, isPdf, isAudio, isDoc, fileTypeIconUrl.
useCommonFunction.tsDeprecated. Shim that delegates to useTransactionActivity. Use useTransactionActivity in new code.
useCsrf.tsCSRF token management — fetches the XSRF-TOKEN cookie from /api/csrf-token and exposes csrfToken.
useDamNavigation.tsCentralized DAM route navigation with analytics dispatch and new-tab support. Accepts NavigationOptions including analytics context, query params, and hash.
useDayjs.tsReturns the dayjs instance.
useDragReorder.tsGeneric drag-to-reorder for any list or grid. Exposes draggingIndex, dragOverIndex, startDrag, bindRow.
useDraggableBar.tsDrag-to-reposition for the floating bulk-action bar. Clamps to viewport; ignores drags starting on .v-btn / .v-chip.
useErrorHandler.tsCentralized error handler — handleError(e, options). Sanitizes messages, logs, optionally shows snackbar, optionally rethrows.
useHelpers.tsLarge utility bag consumed across the app. Includes workspace access checks, role/permission helpers, file-type predicates (isImage, isVideo, etc.), formatting helpers, and getWorkspaceId.
useImageStyle.tsAsset display helpers — getFileTypeIconUrl, getThumbnailStyle, getObjectFit, dimension computeds. Exports DEFAULT_ICON_TYPES set.
useInsightsChart.tsShared Chart.js config and bar_data builder for the "Last 7 Days" weekly-insights bar chart. Used by the dashboard and asset detail pages so both charts stay identical.
useMarqueeSelection.tsMouse marquee (rubber-band) selection for asset grids. Supports grid, list, and mosaic selectors.
useMittBus.tsReturns the global mitt EventBus instance from the Nuxt plugin.
usePwaSettings.tsReturns the PWA settings from runtimeConfig.public.pwa as a typed PwaSettings object. Not reactive — returns the static config value at call time. Used by PWA-aware components and layouts to read manifest and service-worker config.
useSearchEventBus.tsTyped search EventBus (mitt) with auto-cleanup on component unmount. Exposes typed on, off, emit for SearchEvents.
useSearchExecution.tsGeneric pagination/loading state machine for in-page Typesense searches. Accepts buildPayload, runSearch, mapHits, getTotal.
useSearchFilterEnrich.tsResolves and validates URL-restored filters against loaded filter pools. Strips invalid entries; resolves name stubs and custom-field label slugs to IDs.
useSearchFilterPool.tsReorders a filter pool to pin selected items to the top without mutating the input array.
useSearchFilterUrl.tsSerializes and deserializes applied filters to/from URL query params. Returns ParsedFilterQuery.
useSearchMethods.tsStateless filter-builder helpers for constructing Typesense filter_by strings.
useSnackbar.tsSnackbar facade over the client-only $snackbar plugin. Methods are no-ops on the server. Exposes success(message, timeout?), error(message, timeout?), info, warning.
useSortPreference.tsPersists sort field and direction per context identifier to cookies (sortValue_<id> / sortDirection_<id>). SSR-safe via useCookie. Exposes: getCachedSort() → CachedSortPreference | null, setCachedSort(field, direction) to write, and getCachedSortWithDefault(defaultField, defaultDirection) which falls back to provided defaults when no cached value exists.
useThumbnailSize.tsPersists grid thumbnail size (xsmall–xlarge) per context identifier in a cookie. SSR-safe.
useToggleSelection.tsShift-click range selection and select-all for asset lists. Operates on the caller's reactive list ref.
useTransactionActivity.tsCentralized analytics/transaction dispatch. Provides trackAsset, trackFolder, trackCollage, and generic dispatchTransaction. Fetches browser OS and location once per session.
useTypesenseClient.tsTypesense collection names (COLLECTION_NAMES), default search params (DEFAULT_COMMON_PARAMS), and sort-field mapping (SORT_FIELD_MAP).
useUploadCommon.tsShared upload logic — file chunking, S3 multipart via Nitro routes, auto-tag trigger, transaction dispatch on completion.
useUploadQueue.tsConcurrency-limited upload task queue. Module-scoped singleton (default 5 concurrent). Exposes scheduleUploadTask, processQueue, resetQueue.
useViewMode.tsPersists grid / list / mosaic view mode per context identifier in a cookie. SSR-safe via useState.
useViewportFill.tsInfinite scroll helper — calls loadMore repeatedly until the scroll container is taller than the viewport or a max-attempts limit is hit.
useWorkspaceId.tsResolves the current workspace ID from route params, the currentWorkspace cookie, or the auth user. Exposes workspaceId, getWorkspaceId, isValidWorkspaceId, hasWorkspaceAccess.
useWorkspaceUniqueId.tsResolves the workspace_unique_id (Typesense tenant key) for the current workspace from the user's accessible workspaces list.
useZipShot.tsGenerates a PNG preview thumbnail of a ZIP archive's contents via the /api/zip-viewer/extract Nitro route.

core/components/ — Component-level logic ​

These composables are extracted from components that had enough logic to warrant separation. Each is tied to a specific component.

FileWhat it provides
useAccountSettingsLeftMenu.tsAccount settings sidebar — menu items, active route detection, navigation helpers.
useAssetCard.tsAsset grid/list card — context menu, selection, download, analytics dispatch.
useAssetContainer.tsAsset preview container — resolves display file, handles image editor integration, manages preview state.
useAssetImageOverlay.tsImage card overlay — selection checkbox state, screen-size breakpoints (isLargeScreen, isSmallScreen).
useAssetMenu.tsAsset context-menu builder for the search results "Assets" tab. Returns a DamMenuItem[] array.
useAssetVersionItem.tsAsset version list item — download, make-current, delete version actions.
useAssetVideoOverlay.tsVideo card overlay — selection checkbox state, screen-size breakpoints.
useBreadCrumbs.tsBreadcrumb trail navigation for folders and collages. Handles share-link context and loading state.
useCollageCard.tsCollage grid card — inline rename, context menu, permission check, download.
useCollageMenu.tsCollage context-menu builder shared by the Collages page and search "Collages" tab.
useDamListRow.tsDAM list-view row — exports DAM_LIST_DEFAULT_COLUMNS, thumbnail size constant, and row display helpers.
useDamNotification.tsIn-app notification panel — badge count, notification list, Laravel Echo event handling.
useEmbedTableListItem.tsEmbed code table row — thumbnail resolution, copy-to-clipboard action.
useFolderCard.tsFolder grid card — context menu, permission check, selection.
useFolderMenu.tsFolder context-menu builder shared by the Folders page and search "Folders" tab.
useHeaderSearch.tsTop-bar header search dropdown — multi-collection preview (assets/folders/collages/tags), debounced query, navigate to search page on submit.
useImageEditActions.tsAsset detail image editor sidebar — crop preset groups, export format selection, apply/cancel crop.
usePortalBanners.tsPortal banner list management in the portal detail page — fetch, upsert, delete, drag-reorder.
usePortalBrandingTab.tsPortal branding form — brand name, colors, domain URL, public portal toggle, CNAME management.
usePortalTiles.tsPortal tile list management in the portal detail page — fetch, upsert, delete, drag-reorder, slider config.
useRecentSearches.tsServer-backed recent search history. Module-scoped singleton so the header bar and search page share one list.
useSearchAssets.tsAssets tab — Typesense search with infinite scroll, per-page windowing, scope support (global / folder / collage / shared).
useSearchBar.tsSearch bar input — debounced query ref, debouncedQuery, isFocused, browse history helpers.
useSearchCollages.tsCollages tab — Typesense search with independent pagination from the assets tab.
useSearchFilter.tsFilter state machine — loads categories and popular data, manages appliedFilters, syncs with URL query params.
useSearchFolders.tsFolders tab — Typesense search with independent pagination from the assets tab.
useSearchSelection.tsShared selection state across search tabs — shift-select, select-all-pages, resolveTargetIds() for bulk actions.
useShareTableListItem.tsShare URL table row — custom domain resolution, thumbnail, copy-to-clipboard.
useTagsBox.tsAsset tags input — tag suggestions via API, common tags list, add/remove tag operations.

core/dialogs/ — Dialog business logic ​

These composables power dialog components and action dispatchers that open dialogs via the dialog store.

FileWhat it provides
useAddEditBannerDialog.tsAdd/edit portal banner dialog — form state, image crop via getCropBlob, submit to usePortalBannerApi.
useAddEditTileDialog.tsAdd/edit portal tile dialog — form state, image crop, submit to usePortalTileApi.
useAddMultipleTags.tsBulk tag dialog — tag suggestions, add tags to multiple selected assets.
useAdvanceShareDialog.tsAdvanced share settings dialog — expiry date, password protection, link management.
useAssetActions.tsAsset action dispatcher — opens rename/delete dialogs via dialog store, emits mitt bus events for list updates.
useAssetQuickViewDialog.tsAsset quick-view dialog — inline preview, download, add-to-collage, tag editing.
useCollageActions.tsCollage action dispatcher — opens rename/delete dialogs via dialog store, emits collage events.
useCreateOrRenameDialog.tsCreate/rename folder or collage dialog — form state, validation, API call.
useCreatePortalDialog.tsCreate new portal dialog — form state, domain/subdomain toggle, validation, submit.
useFileConversionDialog.tsDownload / format conversion dialog — resolution options, format selector. Pure UI; API calls emitted to parent.
useFolderActions.tsFolder action dispatcher — opens create/rename/delete dialogs, emits mitt bus events.
useFolderDialog.tsFolder tree picker dialog — Typesense-backed folder search, select destination for move/copy.
useInvitePortalUserDialog.tsInvite/edit portal user dialog — form state, role selection, submit to usePortalUsersApi.
usePermissionDialog.tsAsset/folder/collage permission dialog — portal visibility assignment via usePermissionApi.
useSaveToCollage.ts"Save to Collage" dialog — debounced collage search, queued add operations, emits update event.
useShareAssetDialog.tsShare asset/folder/collage dialog — generates share URLs and embed codes, copy helpers.
useUserDialog.tsWorkspace member dialog — create/edit member with workspace and role assignment.

core/layouts/ — Layout composables ​

FileWhat it provides
useCollageErrorLayout.tsError layout side-effects: removes stale Vuetify overlays on mount; redirects unauthenticated users while guarding against branding-error redirect loops.
useCollageLayout.tsMain layout computeds — currentWorkspace, canUpload, storageFull. Also exposes upload and drag-drop helpers.
useCollageSidebar.tsSidebar nav — workspace switcher, primary menu items, create-new items, portal links, logout.
useSidebarMiniState.tsShared mini boolean that collapses the sidebar on detail routes (asset, folder, settings pages).

core/useSearchOverlay.ts ​

Module-scoped singleton isSearchOpen ref that controls the fullscreen search overlay. Both the header trigger button and the overlay itself call this composable.


core/pages/ — Page-level business logic ​

These composables are the single source of truth for each page's state, data fetching, and user action handling.

FileWhat it provides
useAddDamInstance.tsAdd DAM instance page — form state, domain/subdomain toggle, validation, submit.
useAnnouncementsPage.tsAnnouncements settings page — TanStack-backed list, delete, type filter, sort.
useAssetDetail.tsAsset detail page — full state management: asset data, versions, tags, custom fields, download, conversion, analytics.
useAssetDetailTags.tsTag management sub-composable for the asset detail page — add/remove tags for a single asset.
useCollage.tsCollages library page — list state, sort, delete/rename/share/permission dialogs.
useCollageDetails.tsCollage detail page — inner search, file list, selection, bulk operations, pagination.
useCustomFieldsPage.tsCustom fields settings page — TanStack-backed list, delete, reorder, toggle status.
useDashboard.tsDashboard page — recent collages/folders, overview stats, weekly insights chart, quick-action routes.
useExternalUsersPage.tsExternal users settings page — TanStack-backed list, add, edit, toggle status.
useFolderDetail.tsFolder detail page — inner search, file list, selection, bulk operations, upload integration.
useFolders.tsFolders library page — folder list, sort, delete/move/rename with analytics.
useMembersPage.tsMembers settings page — TanStack-backed list, roles, invite, delete, revoke.
useNotificationSettings.tsNotification settings page — user and org preference management, subscription feature checks.
usePortalDetail.tsPortal detail page — settings tabs (branding, users, banners, tiles), subscription limits.
usePortalUsersPageSettings.tsPortal users settings page — TanStack-backed list, invite dialog, filter by user type.
usePortalsList.tsPortals list page — TanStack-backed list, create, subscription limit check.
useProfilePage.tsProfile settings page — personal info form, default workspace, passkey (WebAuthn) registration/deletion, timezone.
useSearchResultsPage.tsSearch results page — coordinates useSearchAssets, useSearchFolders, useSearchCollages, useSearchFilter; handles URL sync and Amplitude tracking.
useSharedAssetsPage.tsPublic shared assets page — password authentication, asset browsing, download, breadcrumb navigation.
useSharing.tsSharing page — TanStack-backed share URLs and embed codes lists, sort, filter, bulk delete.
useTrashPage.tsTrash page — TanStack-backed list, bulk select, permanent delete, restore.
useUploadedPage.tsRecent uploads ("Uncategorized") page — paginated list, inline edit, custom fields.
useWorkspaceSettings.tsWorkspace settings page — detail form, domain management, favicon/logo upload, subscription display.

Root level ​

FileWhat it provides
useOrigin.tsReturns the current request origin as a string. SSR-safe — honors X-Forwarded-Proto and X-Forwarded-Host headers so the origin reflects the public-facing URL, not the reverse proxy's internal scheme. Fallback: runtimeConfig.public.baseUrl.