Bump svelte 5.28 -> 5.55

This commit is contained in:
Rūdolfs Ošiņš
2026-05-13 13:58:07 +02:00
parent be72541272
commit ab0bbfb94a
13 changed files with 105 additions and 64 deletions
+4
View File
@@ -25,7 +25,11 @@
let hideChanges = $state(false);
let filesExpanded = $state(true);
let selectedCommit = $state<string>();
// Parent reuses this component across patch revisions; a sibling $effect
// resets base and head when patchId changes.
// svelte-ignore state_referenced_locally
let base = $state(revision.base);
// svelte-ignore state_referenced_locally
let head = $state(revision.head);
$effect(() => {
+3
View File
@@ -328,6 +328,7 @@
class:context={line.type === "context"}
class:selected={!thread &&
isSelected(filePath(file, "left"), hunkIdx, lineIdx)}>
<!-- svelte-ignore a11y_no_static_element_interactions -->
<div
class="left"
class:selection-disabled={!codeComments || thread}
@@ -341,6 +342,7 @@
{lineNumber(line, "left")}
</div>
<!-- svelte-ignore a11y_no_static_element_interactions -->
<div
class="right"
class:selection-disabled={!codeComments || thread}
@@ -447,6 +449,7 @@
{/if}
{#if codeComments && selection?.hunkIdx === hunkIdx && selection?.lineIdx === lineIdx}
<!-- svelte-ignore a11y_no_static_element_interactions -->
<div
class="comment-form"
onpointerdown={e => {
+3 -6
View File
@@ -50,22 +50,19 @@
}: Props = $props();
/* eslint-enable prefer-const */
let previousCobId = cobId;
let previousCobId: string | undefined;
let focusReply: boolean = $state(false);
let commentFormKey = $state(0);
let hideDiscussion = $state(false);
$effect(() => {
// eslint-disable-next-line @typescript-eslint/no-unused-expressions
cobId;
if (cobId !== previousCobId) {
previousCobId = cobId;
if (previousCobId !== undefined && cobId !== previousCobId) {
hideDiscussion = false;
focusReply = false;
commentFormKey += 1;
}
previousCobId = cobId;
});
</script>
+3
View File
@@ -96,6 +96,9 @@
}, [])) as Thread<CodeLocation>[]) || [],
);
// The verdict prop seeds a local working copy that the form mutates until
// submit; later prop updates intentionally do not overwrite it.
// svelte-ignore state_referenced_locally
let verdict: Review["verdict"] = $state(review.verdict);
async function editReview(
+8 -6
View File
@@ -41,13 +41,15 @@
return el.scrollTop + el.clientHeight >= el.scrollHeight - threshold;
}
const scrollHalfHandler = onScrollHalf
? (instance: Parameters<typeof shouldLoadMore>[0]) => {
if (shouldLoadMore(instance)) {
onScrollHalf();
const scrollHalfHandler = $derived(
onScrollHalf
? (instance: Parameters<typeof shouldLoadMore>[0]) => {
if (shouldLoadMore(instance)) {
onScrollHalf();
}
}
}
: undefined;
: undefined,
);
</script>
<OverlayScrollbarsComponent