aboutsummaryrefslogtreecommitdiff
path: root/src/ClientUtils.ts
diff options
context:
space:
mode:
authorSkitty1238 <157652284+Skitty1238@users.noreply.github.com>2025-06-02 14:18:20 -0400
committerSkitty1238 <157652284+Skitty1238@users.noreply.github.com>2025-06-02 14:18:20 -0400
commit83bfca49c38e12dc575b5037c8fac25f3c21d6c5 (patch)
treed3e66b45d0e95e51d2b6f2672fd367776f19db35 /src/ClientUtils.ts
parente4b5aa5e72cca6dd51e9acf28017cde4233b5cc6 (diff)
parent76a21badf70c82388872ec5485858ab06e303bca (diff)
Merge branch 'master' into task_nodes_aarav
Diffstat (limited to 'src/ClientUtils.ts')
-rw-r--r--src/ClientUtils.ts5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/ClientUtils.ts b/src/ClientUtils.ts
index 03ff13924..8eb1a39ec 100644
--- a/src/ClientUtils.ts
+++ b/src/ClientUtils.ts
@@ -194,7 +194,7 @@ export namespace ClientUtils {
}
export function CorsProxy(url: string): string {
- return prepend('/corsProxy/') + encodeURIComponent(url);
+ return prepend('/corsproxy/') + encodeURIComponent(url);
}
export function CopyText(text: string) {
@@ -670,7 +670,8 @@ export function setupMoveUpEvents(
}
export function DivHeight(ele: HTMLElement | null): number {
- return ele ? Number(getComputedStyle(ele).height.replace('px', '')) : 0;
+ const hgt = ele ? Number(getComputedStyle(ele).height.replace('px', '')) : 0;
+ return Number.isNaN(hgt) ? 0 : hgt;
}
export function DivWidth(ele: HTMLElement | null): number {
return ele ? Number(getComputedStyle(ele).width.replace('px', '')) : 0;