mirror of
https://github.com/appwrite/console.git
synced 2026-11-18 20:47:21 +00:00
fix: site image previews
This commit is contained in:
1 parent
3c8ea3b4eb
commit
82e3394175
2 files changed
+4
-3
No files matched your search
@@ -20,8 +20,9 @@
|
||||
import { app } from '$lib/stores/app';
|
||||
import { base } from '$app/paths';
|
||||
import { isCloud } from '$lib/system';
|
||||
import { getApiEndpoint } from '$lib/stores/sdk';
|
||||
import { getApiEndpoint, sdk } from '$lib/stores/sdk';
|
||||
import { capitalize } from '$lib/helpers/string';
|
||||
import { page } from '$app/state';
|
||||
|
||||
export let deployment: Models.Deployment;
|
||||
export let proxyRuleList: Models.ProxyRuleList;
|
||||
@@ -46,7 +47,7 @@
|
||||
|
||||
function getFilePreview(fileId: string) {
|
||||
// TODO: @Meldiron use sdk.forConsole.storage.getFilePreview
|
||||
const endpoint = getApiEndpoint();
|
||||
const endpoint = getApiEndpoint(page.params.region);
|
||||
return endpoint + `/storage/buckets/screenshots/files/${fileId}/view?project=console`;
|
||||
}
|
||||
</script>
|
||||
|
||||
@@ -34,7 +34,7 @@
|
||||
|
||||
function getFilePreview(fileId: string) {
|
||||
// TODO: @Meldiron use sdk.forConsole.storage.getFilePreview
|
||||
const endpoint = getApiEndpoint();
|
||||
const endpoint = getApiEndpoint(page.params.region);
|
||||
return endpoint + `/storage/buckets/screenshots/files/${fileId}/view?project=console`;
|
||||
}
|
||||
</script>
|
||||
|
||||
Reference in new issue
Block a user