{#snippet styledPath(fullPath: string)} {fullPath.match(/^.*\/|/)?.values().next().value}{fullPath.split("/").slice(-1)} {/snippet} {#snippet leftHeader()} {#if (headerBadgeCaption === "moved" || headerBadgeCaption === "copied") && oldFilePath} {@render styledPath(filePath)} → {@render styledPath(filePath)} {:else} {@render styledPath(filePath)} {/if} {#if headerBadgeCaption === "added"} added {:else if headerBadgeCaption === "deleted"} deleted {:else if headerBadgeCaption === "moved"} moved {:else if headerBadgeCaption === "copied"} copied {/if} {/snippet} {#snippet children()}
{#if fileDiff.type === "plain"} {#if fileDiff.hunks.length > 0} {#each fileDiff.hunks as hunk, hunkIdx} {#each hunk.lines as line, lineIdx} {/each} {/each}
{hunk.header}
{lineNumberL(line)}
{lineNumberR(line)} {lineSign(line)} {#if line.highlight?.items.length === 0 || line.line === ""}
{:else if line.highlight} {@html line.highlight.items .map( s => `${escape(s.item)}`, ) .join("")} {:else} {line.line} {/if}
{:else}
Empty file
{/if} {:else}
Empty file
{/if}
{/snippet}