refactor: view shared link (#23766)

This commit is contained in:
Jason Rasmussen
2025-11-10 12:21:26 -05:00
committed by GitHub
parent a4e65a7ea8
commit 45304f1211
13 changed files with 74 additions and 76 deletions

View File

@@ -1,7 +1,6 @@
import { defaultLang, langs, locales } from '$lib/constants';
import { authManager } from '$lib/managers/auth-manager.svelte';
import { lang } from '$lib/stores/preferences.store';
import { serverConfig } from '$lib/stores/server-config.store';
import { handleError } from '$lib/utils/handle-error';
import {
AssetJobName,
@@ -269,11 +268,6 @@ export const copyToClipboard = async (secret: string) => {
}
};
export const makeSharedLinkUrl = (sharedLink: SharedLinkResponseDto) => {
const path = sharedLink.slug ? `s/${sharedLink.slug}` : `share/${sharedLink.key}`;
return new URL(path, get(serverConfig).externalDomain || globalThis.location.origin).href;
};
export const oauth = {
isCallback: (location: Location) => {
const search = location.search;